@@ -226,6 +232,7 @@ import { mapState, mapGetters } from 'vuex'
import { NcActions, NcActionButton, NcAvatar, NcButton, NcPopover, NcModal } from '@nextcloud/vue'
import labelStyle from '../mixins/labelStyle.js'
import ArchiveIcon from 'vue-material-design-icons/Archive.vue'
+import ImageIcon from 'vue-material-design-icons/ImageMultiple.vue'
import FilterIcon from 'vue-material-design-icons/Filter.vue'
import FilterOffIcon from 'vue-material-design-icons/FilterOff.vue'
import ArrowCollapseVerticalIcon from 'vue-material-design-icons/ArrowCollapseVertical.vue'
@@ -245,6 +252,7 @@ export default {
NcPopover,
NcAvatar,
ArchiveIcon,
+ ImageIcon,
FilterIcon,
FilterOffIcon,
ArrowCollapseVerticalIcon,
@@ -285,6 +293,7 @@ export default {
]),
...mapState({
compactMode: state => state.compactMode,
+ showCardCover: state => state.showCardCover,
searchQuery: state => state.searchQuery,
}),
detailsRoute() {
@@ -339,6 +348,9 @@ export default {
toggleCompactMode() {
this.$store.dispatch('toggleCompactMode')
},
+ toggleShowCardCover() {
+ this.$store.dispatch('toggleShowCardCover')
+ },
toggleShowArchived() {
this.$store.dispatch('toggleShowArchived')
this.showArchived = !this.showArchived
diff --git a/src/components/cards/CardCover.vue b/src/components/cards/CardCover.vue
new file mode 100644
index 000000000..b685aeb59
--- /dev/null
+++ b/src/components/cards/CardCover.vue
@@ -0,0 +1,102 @@
+
+
+
+
+
+
+
+
diff --git a/src/components/cards/CardItem.vue b/src/components/cards/CardItem.vue
index a46ffcc9f..68f1b560c 100644
--- a/src/components/cards/CardItem.vue
+++ b/src/components/cards/CardItem.vue
@@ -34,6 +34,7 @@
{{ board.title }} ยป {{ stack.title }}
+
{{ card.title }}
@@ -92,10 +93,11 @@ import labelStyle from '../../mixins/labelStyle.js'
import AttachmentDragAndDrop from '../AttachmentDragAndDrop.vue'
import CardMenu from './CardMenu.vue'
import DueDate from './badges/DueDate.vue'
+import CardCover from './CardCover.vue'
export default {
name: 'CardItem',
- components: { CardBadges, AttachmentDragAndDrop, CardMenu, DueDate },
+ components: { CardBadges, AttachmentDragAndDrop, CardMenu, DueDate, CardCover },
directives: {
ClickOutside,
},
@@ -129,6 +131,7 @@ export default {
compactMode: state => state.compactMode,
showArchived: state => state.showArchived,
currentBoard: state => state.currentBoard,
+ showCardCover: state => state.showCardCover,
}),
...mapGetters([
'isArchived',
diff --git a/src/store/main.js b/src/store/main.js
index 31b52c84c..3df2e70fa 100644
--- a/src/store/main.js
+++ b/src/store/main.js
@@ -62,6 +62,7 @@ export default new Vuex.Store({
showArchived: false,
navShown: localStorage.getItem('deck.navShown') === null || localStorage.getItem('deck.navShown') === 'true',
compactMode: localStorage.getItem('deck.compactMode') === 'true',
+ showCardCover: localStorage.getItem('deck.showCardCover') === 'true',
sidebarShown: false,
currentBoard: null,
currentCard: null,
@@ -229,6 +230,10 @@ export default new Vuex.Store({
state.compactMode = !state.compactMode
localStorage.setItem('deck.compactMode', state.compactMode)
},
+ toggleShowCardCover(state) {
+ state.showCardCover = !state.showCardCover
+ localStorage.setItem('deck.showCardCover', state.showCardCover)
+ },
setBoards(state, boards) {
state.boards = boards
},
@@ -439,6 +444,9 @@ export default new Vuex.Store({
toggleCompactMode({ commit }) {
commit('toggleCompactMode')
},
+ toggleShowCardCover({ commit }) {
+ commit('toggleShowCardCover')
+ },
setCurrentBoard({ commit }, board) {
commit('setCurrentBoard', board)
},