- fileinfodetail renamed to clipboard

This commit is contained in:
Peter Papp
2021-04-19 09:22:50 +02:00
parent b71072ddda
commit b0c81a692c
24 changed files with 382 additions and 353 deletions
+101 -75
View File
@@ -1,77 +1,103 @@
{ {
"/vendors~chunks/admin~chunks/admin-account~chunks/app-appearance~chunks/app-billings~chunks/app-email~2fac28cc.js": "/vendors~chunks/admin~chunks/admin-account~chunks/app-appearance~chunks/app-billings~chunks/app-email~2fac28cc.js?id=d8dac775684711abc6e2", "/js/main.js": "/js/main.js",
"/chunks/admin-account~chunks/app-setup~chunks/billings-detail~chunks/create-new-password~chunks/datab~5f8db287.js": "/chunks/admin-account~chunks/app-setup~chunks/billings-detail~chunks/create-new-password~chunks/datab~5f8db287.js?id=d85e8bc2bb4fc4b9cd7e", "/css/app.css": "/css/app.css",
"/chunks/app-appearance~chunks/app-billings~chunks/app-email~chunks/app-index~chunks/app-others~chunks~8cc7d96f.js": "/chunks/app-appearance~chunks/app-billings~chunks/app-email~chunks/app-index~chunks/app-others~chunks~8cc7d96f.js?id=e5c9ba18c9210405a275", "/chunks/admin.js": "/chunks/admin.js?id=2971d15f4e0bd0662482",
"/chunks/files~chunks/platform~chunks/shared~chunks/shared-files~chunks/shared/file-browser.js": "/chunks/files~chunks/platform~chunks/shared~chunks/shared-files~chunks/shared/file-browser.js?id=497714844cedc7cb410b", "/chunks/admin-account.js": "/chunks/admin-account.js?id=3036df3e72596fabc42e",
"/chunks/files~chunks/shared-files~chunks/shared/file-browser~chunks/shared/single-file.js": "/chunks/files~chunks/shared-files~chunks/shared/file-browser~chunks/shared/single-file.js?id=327ca38670e0284909ea", "/chunks/admin-account~chunks/app-appearance~chunks/app-billings~chunks/app-email~chunks/app-index~chu~c7a13fb0.js": "/chunks/admin-account~chunks/app-appearance~chunks/app-billings~chunks/app-email~chunks/app-index~chu~c7a13fb0.js?id=62b552a0492fe95b2223",
"/chunks/admin~chunks/platform~chunks/shared.js": "/chunks/admin~chunks/platform~chunks/shared.js?id=b1bd58b72c9a10cfa038", "/chunks/admin-account~chunks/app-setup~chunks/billings-detail~chunks/create-new-password~chunks/datab~cf616679.js": "/chunks/admin-account~chunks/app-setup~chunks/billings-detail~chunks/create-new-password~chunks/datab~cf616679.js?id=fd241499c4e3b6a88840",
"/chunks/files~chunks/shared-files~chunks/shared/file-browser.js": "/chunks/files~chunks/shared-files~chunks/shared/file-browser.js?id=cac4aef2888c2488f086", "/chunks/admin~chunks/admin-account~chunks/app-appearance~chunks/app-billings~chunks/app-email~chunks/~eeab5771.js": "/chunks/admin~chunks/admin-account~chunks/app-appearance~chunks/app-billings~chunks/app-email~chunks/~eeab5771.js?id=dc1abd740ef0db3451a2",
"/chunks/not-found.js": "/chunks/not-found.js?id=fc2ff097020968f2d5cd", "/chunks/admin~chunks/files~chunks/platform~chunks/shared~chunks/shared-files~chunks/shared/file-browser.js": "/chunks/admin~chunks/files~chunks/platform~chunks/shared~chunks/shared-files~chunks/shared/file-browser.js?id=96a88b0b70032047b60d",
"/chunks/profile~chunks/settings-password.js": "/chunks/profile~chunks/settings-password.js?id=f8bbbfc34e2ff40112b8", "/chunks/admin~chunks/files~chunks/settings~chunks/shared-files~chunks/shared/file-browser.js": "/chunks/admin~chunks/files~chunks/settings~chunks/shared-files~chunks/shared/file-browser.js?id=9b66c2dab4c6103bb53c",
"/vendors~chunks/platform~chunks/shared.js": "/vendors~chunks/platform~chunks/shared.js?id=4ad4631716535ab7736a", "/chunks/admin~chunks/platform.js": "/chunks/admin~chunks/platform.js?id=7b37d12eb7ff79e1eb53",
"/js/main.js": "/js/main.js?id=6e703d5513bd041806e4", "/chunks/admin~chunks/platform~chunks/shared.js": "/chunks/admin~chunks/platform~chunks/shared.js?id=7e94943976a0aea65e09",
"/css/app.css": "/css/app.css?id=5ef36155a311dd4539c1", "/chunks/app-appearance.js": "/chunks/app-appearance.js?id=b4e2d99a172f06a1d312",
"/chunks/admin.js": "/chunks/admin.js?id=1c330cf4ccdfa2f019db", "/chunks/app-appearance~chunks/app-billings~chunks/app-email~chunks/app-index~chunks/app-others~chunks~605f4c49.js": "/chunks/app-appearance~chunks/app-billings~chunks/app-email~chunks/app-index~chunks/app-others~chunks~605f4c49.js?id=1ae1e65bb6a5ed7c3e10",
"/chunks/admin-account.js": "/chunks/admin-account.js?id=8f980b2f04bf8979e95e", "/chunks/app-appearance~chunks/app-billings~chunks/app-email~chunks/app-index~chunks/app-others~chunks~8cc7d96f.js": "/chunks/app-appearance~chunks/app-billings~chunks/app-email~chunks/app-index~chunks/app-others~chunks~8cc7d96f.js?id=7702f37f277478ad66c6",
"/chunks/app-appearance.js": "/chunks/app-appearance.js?id=f643635457b8e817685f", "/chunks/app-appearance~chunks/app-billings~chunks/app-email~chunks/app-index~chunks/app-others~chunks~b9e5655a.js": "/chunks/app-appearance~chunks/app-billings~chunks/app-email~chunks/app-index~chunks/app-others~chunks~b9e5655a.js?id=04f0cd9719723459b685",
"/chunks/app-billings.js": "/chunks/app-billings.js?id=1e4bbdd483151fb305e2", "/chunks/app-billings.js": "/chunks/app-billings.js?id=82133cc16f55222bbbe6",
"/chunks/app-email.js": "/chunks/app-email.js?id=ea37d998b93d5172cc99", "/chunks/app-email.js": "/chunks/app-email.js?id=c578a85112c6a4b1ed0e",
"/chunks/app-index.js": "/chunks/app-index.js?id=f3b0815e40a5d8f539ea", "/chunks/app-index.js": "/chunks/app-index.js?id=5bf1c4a8df85876205a0",
"/chunks/app-language.js": "/chunks/app-language.js?id=df85ac744481669b19b7", "/chunks/app-language.js": "/chunks/app-language.js?id=ccf2292ad048d4bfad60",
"/chunks/app-others.js": "/chunks/app-others.js?id=9bfeac235166c6de6e91", "/chunks/app-language~chunks/app-settings~chunks/dashboard~chunks/invoices~chunks/page-edit~chunks/pag~824d674f.js": "/chunks/app-language~chunks/app-settings~chunks/dashboard~chunks/invoices~chunks/page-edit~chunks/pag~824d674f.js?id=46d89e7310e4babf1999",
"/chunks/app-payments.js": "/chunks/app-payments.js?id=c5658a753f0f3d785f19", "/chunks/app-language~chunks/dashboard~chunks/files~chunks/invoices~chunks/pages~chunks/plans~chunks/s~38c276fc.js": "/chunks/app-language~chunks/dashboard~chunks/files~chunks/invoices~chunks/pages~chunks/plans~chunks/s~38c276fc.js?id=9a86dcc16affee74e05f",
"/chunks/app-settings.js": "/chunks/app-settings.js?id=59b1c50cf2a010ed9cac", "/chunks/app-others.js": "/chunks/app-others.js?id=9156adba3b1697a8bf3e",
"/chunks/app-setup.js": "/chunks/app-setup.js?id=7c8bab2aac20190c4462", "/chunks/app-payments.js": "/chunks/app-payments.js?id=7e1a982c90174f568fb2",
"/chunks/billings-detail.js": "/chunks/billings-detail.js?id=efc85303b181ab6db677", "/chunks/app-settings.js": "/chunks/app-settings.js?id=acc6ba7a93681f0d5d64",
"/chunks/contact-us.js": "/chunks/contact-us.js?id=e3c45469a83f82938eef", "/chunks/app-setup.js": "/chunks/app-setup.js?id=d0e3e046e147ca928f34",
"/chunks/create-new-password.js": "/chunks/create-new-password.js?id=f67f77d78c62e27feb8d", "/chunks/billings-detail.js": "/chunks/billings-detail.js?id=d0ade32264f71dd7a2af",
"/chunks/dashboard.js": "/chunks/dashboard.js?id=d051536eb00cb36fbb04", "/chunks/contact-us.js": "/chunks/contact-us.js?id=f5276b101b2e0c97d6d1",
"/chunks/database.js": "/chunks/database.js?id=553d4df0e6bb2807045e", "/chunks/contact-us~chunks/dynamic-page~chunks/homepage.js": "/chunks/contact-us~chunks/dynamic-page~chunks/homepage.js?id=22bd5db44c72e8de5f5b",
"/chunks/dynamic-page.js": "/chunks/dynamic-page.js?id=6a4f59eb5a9b27c9bcea", "/chunks/create-new-password.js": "/chunks/create-new-password.js?id=48dc53ccbd502c2739ec",
"/chunks/environment-setup.js": "/chunks/environment-setup.js?id=626151d7ccbf0915188f", "/chunks/dashboard.js": "/chunks/dashboard.js?id=9825336101be68307708",
"/chunks/files.js": "/chunks/files.js?id=92f28aa1d154210ac68b", "/chunks/dashboard~chunks/invoices~chunks/pages~chunks/plan-subscribers~chunks/plans~chunks/settings-i~0e2a0654.js": "/chunks/dashboard~chunks/invoices~chunks/pages~chunks/plan-subscribers~chunks/plans~chunks/settings-i~0e2a0654.js?id=7540af768b1cfda01a13",
"/chunks/forgotten-password.js": "/chunks/forgotten-password.js?id=5760d4df726d6fb823f0", "/chunks/database.js": "/chunks/database.js?id=7374830dc3cbddf41abb",
"/chunks/homepage.js": "/chunks/homepage.js?id=a42a4f84e60f306a9fd8", "/chunks/dynamic-page.js": "/chunks/dynamic-page.js?id=6dccc2158cc6278f683d",
"/chunks/installation-disclaimer.js": "/chunks/installation-disclaimer.js?id=6432e93a69af6a5b81d1", "/chunks/environment-setup.js": "/chunks/environment-setup.js?id=208de84df68177288a2a",
"/chunks/invoices.js": "/chunks/invoices.js?id=c5c5f399d770e90347a4", "/chunks/files.js": "/chunks/files.js?id=26ad1fca7599f4094b4a",
"/chunks/page-edit.js": "/chunks/page-edit.js?id=a8720c13a8c0480ce599", "/chunks/files~chunks/platform~chunks/shared-files~chunks/shared/file-browser.js": "/chunks/files~chunks/platform~chunks/shared-files~chunks/shared/file-browser.js?id=39233d603662ca3738e8",
"/chunks/pages.js": "/chunks/pages.js?id=4ccbb7d82a3756e34a5a", "/chunks/files~chunks/platform~chunks/shared~chunks/shared-files~chunks/shared/file-browser.js": "/chunks/files~chunks/platform~chunks/shared~chunks/shared-files~chunks/shared/file-browser.js?id=7b36e1f9a8327a215083",
"/chunks/plan.js": "/chunks/plan.js?id=1a91b7b670b92913f356", "/chunks/files~chunks/platform~chunks/shared~chunks/shared-files~chunks/shared/file-browser~chunks/sha~8510f6c9.js": "/chunks/files~chunks/platform~chunks/shared~chunks/shared-files~chunks/shared/file-browser~chunks/sha~8510f6c9.js?id=b4ccb4a816e5c72a0b85",
"/chunks/plan-create.js": "/chunks/plan-create.js?id=44a15916faafdad16763", "/chunks/files~chunks/settings-subscription~chunks/shared-files~chunks/shared/file-browser~chunks/user~9058a49f.js": "/chunks/files~chunks/settings-subscription~chunks/shared-files~chunks/shared/file-browser~chunks/user~9058a49f.js?id=31a17ad1d2536342abbe",
"/chunks/plan-delete.js": "/chunks/plan-delete.js?id=9f42b1eb10d062c5b57c", "/chunks/files~chunks/shared-files~chunks/shared/file-browser.js": "/chunks/files~chunks/shared-files~chunks/shared/file-browser.js?id=53cc373faf35904b6e75",
"/chunks/plan-settings.js": "/chunks/plan-settings.js?id=dbc3e7b7278a715e8506", "/chunks/files~chunks/shared-files~chunks/shared/file-browser~chunks/shared/single-file.js": "/chunks/files~chunks/shared-files~chunks/shared/file-browser~chunks/shared/single-file.js?id=3565df0bec142bf6d5d5",
"/chunks/plan-subscribers.js": "/chunks/plan-subscribers.js?id=ffaf480b73226c3d3307", "/chunks/files~chunks/shared/file-browser.js": "/chunks/files~chunks/shared/file-browser.js?id=44899a3c3880630dbcd9",
"/chunks/plans.js": "/chunks/plans.js?id=a812481c0e555a3a780f", "/chunks/forgotten-password.js": "/chunks/forgotten-password.js?id=877a9289b77ac3885042",
"/chunks/platform.js": "/chunks/platform.js?id=66c9641c19b38abbdba9", "/chunks/homepage.js": "/chunks/homepage.js?id=48e0e9b3c870c46218ce",
"/chunks/profile.js": "/chunks/profile.js?id=922506c18798ab70af52", "/chunks/installation-disclaimer.js": "/chunks/installation-disclaimer.js?id=c523e816ae410f52d767",
"/chunks/purchase-code.js": "/chunks/purchase-code.js?id=2670fa01f9ecc4bee62d", "/chunks/invoices.js": "/chunks/invoices.js?id=432dbcaa4cff9f76d093",
"/chunks/settings.js": "/chunks/settings.js?id=3434fbf5ac6e1ab50ad1", "/chunks/not-found.js": "/chunks/not-found.js?id=7204a74c2db0ab70149c",
"/chunks/settings-create-payment-methods.js": "/chunks/settings-create-payment-methods.js?id=bdff596e9c8996bb5810", "/chunks/page-edit.js": "/chunks/page-edit.js?id=4c04e9f1bbecd8d1d9ba",
"/chunks/settings-invoices.js": "/chunks/settings-invoices.js?id=6b36c4ffe79216b9b8b3", "/chunks/pages.js": "/chunks/pages.js?id=99b0fdc98f5a75997fa0",
"/chunks/settings-password.js": "/chunks/settings-password.js?id=af99ddcdc5baac89f34b", "/chunks/plan.js": "/chunks/plan.js?id=ac3046761e9083aa3053",
"/chunks/settings-payment-methods.js": "/chunks/settings-payment-methods.js?id=f8b75a7a32c7e1f69ed0", "/chunks/plan-create.js": "/chunks/plan-create.js?id=b966184a7aa84bdd297e",
"/chunks/settings-storage.js": "/chunks/settings-storage.js?id=e948dcbd9bf687e5cb04", "/chunks/plan-delete.js": "/chunks/plan-delete.js?id=f193816778245ea66d02",
"/chunks/settings-subscription.js": "/chunks/settings-subscription.js?id=bcf42894f83acc3930a2", "/chunks/plan-settings.js": "/chunks/plan-settings.js?id=66123f72696b47a986a2",
"/chunks/setup-wizard.js": "/chunks/setup-wizard.js?id=d60972a2216523642850", "/chunks/plan-subscribers.js": "/chunks/plan-subscribers.js?id=08e2056bc3744b2ea8f9",
"/chunks/shared.js": "/chunks/shared.js?id=271a3bca810187d04928", "/chunks/plans.js": "/chunks/plans.js?id=83fc2cc3cd4b76c8f8f0",
"/chunks/shared-files.js": "/chunks/shared-files.js?id=e5d0ca09b40729218bed", "/chunks/platform.js": "/chunks/platform.js?id=7de76831b9b233a9620c",
"/chunks/shared/authenticate.js": "/chunks/shared/authenticate.js?id=c679dd7737bbad19700a", "/chunks/platform~chunks/shared.js": "/chunks/platform~chunks/shared.js?id=bd77df66c73522ed90a5",
"/chunks/shared/file-browser.js": "/chunks/shared/file-browser.js?id=767c885b024c6b5bf120", "/chunks/profile.js": "/chunks/profile.js?id=1c1c666004fb44b1c404",
"/chunks/shared/single-file.js": "/chunks/shared/single-file.js?id=d57e261a133924a8857f", "/chunks/profile~chunks/settings-password.js": "/chunks/profile~chunks/settings-password.js?id=d0a44ee2cc3e9882c14a",
"/chunks/sign-in.js": "/chunks/sign-in.js?id=6a92a83db12f0d425dff", "/chunks/purchase-code.js": "/chunks/purchase-code.js?id=e00ee12cde704060e15b",
"/chunks/sign-up.js": "/chunks/sign-up.js?id=d9a106720f1b216845ee", "/chunks/settings.js": "/chunks/settings.js?id=fcc97a29894164e2977c",
"/chunks/stripe-credentials.js": "/chunks/stripe-credentials.js?id=7138567e2de4280fc84e", "/chunks/settings-create-payment-methods.js": "/chunks/settings-create-payment-methods.js?id=88849e6ddce9226d49a5",
"/chunks/subscription-plans.js": "/chunks/subscription-plans.js?id=e3b11d7b3e3ca69996b4", "/chunks/settings-invoices.js": "/chunks/settings-invoices.js?id=444b9bbc310647ddd297",
"/chunks/subscription-service.js": "/chunks/subscription-service.js?id=b01f9ac1237e22eba7e5", "/chunks/settings-password.js": "/chunks/settings-password.js?id=46961d5c0fc91f4ad638",
"/chunks/upgrade-billing.js": "/chunks/upgrade-billing.js?id=7829055314854bd7ce70", "/chunks/settings-payment-methods.js": "/chunks/settings-payment-methods.js?id=3bc709a228c0849a6f62",
"/chunks/upgrade-plan.js": "/chunks/upgrade-plan.js?id=e03ab9ef2810015e98bf", "/chunks/settings-storage.js": "/chunks/settings-storage.js?id=0c243c68b17ca976d05a",
"/chunks/user.js": "/chunks/user.js?id=d18afe12be9c588be90d", "/chunks/settings-subscription.js": "/chunks/settings-subscription.js?id=22e5c49d5b0a154e1a28",
"/chunks/user-create.js": "/chunks/user-create.js?id=f00e640be5d3958ca91c", "/chunks/setup-wizard.js": "/chunks/setup-wizard.js?id=c6b88005b133268ed88f",
"/chunks/user-delete.js": "/chunks/user-delete.js?id=0662bae659b479e85f4f", "/chunks/shared.js": "/chunks/shared.js?id=a2c4342bfddd4946cb85",
"/chunks/user-detail.js": "/chunks/user-detail.js?id=595261641625eca9a815", "/chunks/shared-files.js": "/chunks/shared-files.js?id=9560ed081afc308a115a",
"/chunks/user-invoices.js": "/chunks/user-invoices.js?id=1aea8698f90a93ab8f0b", "/chunks/shared/authenticate.js": "/chunks/shared/authenticate.js?id=3d5c7754d438830a4204",
"/chunks/user-password.js": "/chunks/user-password.js?id=9d1c9cdac5b2d51fb905", "/chunks/shared/file-browser.js": "/chunks/shared/file-browser.js?id=3127fab4cfd3d5f00a72",
"/chunks/user-storage.js": "/chunks/user-storage.js?id=eed055b1f60039e33698", "/chunks/shared/single-file.js": "/chunks/shared/single-file.js?id=e8aedb75df7fe227d693",
"/chunks/user-subscription.js": "/chunks/user-subscription.js?id=b313d9afbd2e98d32ac9", "/chunks/sign-in.js": "/chunks/sign-in.js?id=162161aa204ab6931826",
"/chunks/users.js": "/chunks/users.js?id=ac4aef239b49fdba6331" "/chunks/sign-up.js": "/chunks/sign-up.js?id=ce15b1156cf37c0a9703",
"/chunks/stripe-credentials.js": "/chunks/stripe-credentials.js?id=1acdec3a157c8943a88d",
"/chunks/subscription-plans.js": "/chunks/subscription-plans.js?id=a843f8cf90ff1e3168e8",
"/chunks/subscription-service.js": "/chunks/subscription-service.js?id=90c1aa9431689a89eb3d",
"/chunks/upgrade-billing.js": "/chunks/upgrade-billing.js?id=b06efc03a40bcba2bdad",
"/chunks/upgrade-billing~chunks/upgrade-plan.js": "/chunks/upgrade-billing~chunks/upgrade-plan.js?id=0bdf2950a5a73e6e6975",
"/chunks/upgrade-plan.js": "/chunks/upgrade-plan.js?id=35179531a8241da128e9",
"/chunks/user.js": "/chunks/user.js?id=3090bfd5b85dd1b200ec",
"/chunks/user-create.js": "/chunks/user-create.js?id=e1e6127d661c7edf0793",
"/chunks/user-delete.js": "/chunks/user-delete.js?id=8dfec8efd3019616377b",
"/chunks/user-detail.js": "/chunks/user-detail.js?id=b9b70e43cf551a574443",
"/chunks/user-invoices.js": "/chunks/user-invoices.js?id=6c4d0e9e058be11dc1f7",
"/chunks/user-password.js": "/chunks/user-password.js?id=a4b4ab4f4af11533eb4d",
"/chunks/user-storage.js": "/chunks/user-storage.js?id=4aec2d7b60ec0bc35fb9",
"/chunks/user-subscription.js": "/chunks/user-subscription.js?id=99efdd410910267db66e",
"/chunks/users.js": "/chunks/users.js?id=d28a9ac62a41f1ca4af8",
"/vendors~chunks/admin~chunks/admin-account~chunks/app-appearance~chunks/app-billings~chunks/app-email~2fac28cc.js": "/vendors~chunks/admin~chunks/admin-account~chunks/app-appearance~chunks/app-billings~chunks/app-email~2fac28cc.js?id=57c854adb91ed9a9d088",
"/vendors~chunks/admin~chunks/admin-account~chunks/app-appearance~chunks/app-billings~chunks/app-email~d5e36d91.js": "/vendors~chunks/admin~chunks/admin-account~chunks/app-appearance~chunks/app-billings~chunks/app-email~d5e36d91.js?id=170765b4fd923b62195c",
"/vendors~chunks/files~chunks/platform~chunks/shared~chunks/shared-files~chunks/shared/file-browser~ch~52c14f2e.js": "/vendors~chunks/files~chunks/platform~chunks/shared~chunks/shared-files~chunks/shared/file-browser~ch~52c14f2e.js?id=66afa0e341251a68c3d3",
"/vendors~chunks/platform~chunks/shared.js": "/vendors~chunks/platform~chunks/shared.js?id=eb141834bc24b72d8e92",
"/js/main.c735c5b585be594e788e.hot-update.js": "/js/main.c735c5b585be594e788e.hot-update.js",
"/chunks/files.c735c5b585be594e788e.hot-update.js": "/chunks/files.c735c5b585be594e788e.hot-update.js",
"/chunks/files~chunks/shared-files~chunks/shared/file-browser.c735c5b585be594e788e.hot-update.js": "/chunks/files~chunks/shared-files~chunks/shared/file-browser.c735c5b585be594e788e.hot-update.js",
"/chunks/files~chunks/shared-files~chunks/shared/file-browser~chunks/shared/single-file.c735c5b585be594e788e.hot-update.js": "/chunks/files~chunks/shared-files~chunks/shared/file-browser~chunks/shared/single-file.c735c5b585be594e788e.hot-update.js",
"/chunks/files~chunks/shared/file-browser.c735c5b585be594e788e.hot-update.js": "/chunks/files~chunks/shared/file-browser.c735c5b585be594e788e.hot-update.js",
"/chunks/platform~chunks/shared.c735c5b585be594e788e.hot-update.js": "/chunks/platform~chunks/shared.c735c5b585be594e788e.hot-update.js",
"/js/main.a221fcac26c21dc2d62f.hot-update.js": "/js/main.a221fcac26c21dc2d62f.hot-update.js"
} }
@@ -193,21 +193,21 @@ export default {
Option Option
}, },
computed: { computed: {
...mapGetters(['user', 'fileInfoDetail']), ...mapGetters(['user', 'clipboard']),
hasFolder() { hasFolder() {
return this.fileInfoDetail.find(item => item.type === 'folder') return this.clipboard.find(item => item.type === 'folder')
}, },
hasFile() { hasFile() {
return this.fileInfoDetail.find(item => item.type !== 'folder') return this.clipboard.find(item => item.type !== 'folder')
}, },
isMultiSelectContextMenu() { isMultiSelectContextMenu() {
// If is context Menu open on multi selected items open just options for the multi selected items // If is context Menu open on multi selected items open just options for the multi selected items
if (this.fileInfoDetail.length > 1 && this.fileInfoDetail.includes(this.item)) if (this.clipboard.length > 1 && this.clipboard.includes(this.item))
return false return false
// If is context Menu open for the non selected item open options for the single item // If is context Menu open for the non selected item open options for the single item
if (this.fileInfoDetail.length < 2 || !this.fileInfoDetail.includes(this.item)) if (this.clipboard.length < 2 || !this.clipboard.includes(this.item))
return true return true
}, },
favourites() { favourites() {
@@ -250,11 +250,11 @@ export default {
restoreItem() { restoreItem() {
// If is item not in selected items restore just this single item // If is item not in selected items restore just this single item
if (!this.fileInfoDetail.includes(this.item)) if (!this.clipboard.includes(this.item))
this.$store.dispatch('restoreItem', this.item) this.$store.dispatch('restoreItem', this.item)
// If is item in selected items restore all items from fileInfoDetail // If is item in selected items restore all items from clipboard
if (this.fileInfoDetail.includes(this.item)) if (this.clipboard.includes(this.item))
this.$store.dispatch('restoreItem', null) this.$store.dispatch('restoreItem', null)
}, },
shareCancel() { shareCancel() {
@@ -283,12 +283,12 @@ export default {
!this.favourites.find(el => el.id === this.item.id) !this.favourites.find(el => el.id === this.item.id)
) { ) {
// Add to favourite folder that is not selected // Add to favourite folder that is not selected
if (!this.fileInfoDetail.includes(this.item)) { if (!this.clipboard.includes(this.item)) {
this.$store.dispatch('addToFavourites', this.item) this.$store.dispatch('addToFavourites', this.item)
} }
// Add to favourites all selected folders // Add to favourites all selected folders
if (this.fileInfoDetail.includes(this.item)) { if (this.clipboard.includes(this.item)) {
this.$store.dispatch('addToFavourites', null) this.$store.dispatch('addToFavourites', null)
} }
} else { } else {
@@ -296,7 +296,7 @@ export default {
} }
}, },
downloadItem() { downloadItem() {
if (this.fileInfoDetail.length > 1) if (this.clipboard.length > 1)
this.$store.dispatch('downloadFiles') this.$store.dispatch('downloadFiles')
else { else {
this.$downloadFile(this.item.file_url, this.item.name + '.' + this.item.mimetype) this.$downloadFile(this.item.file_url, this.item.name + '.' + this.item.mimetype)
@@ -304,18 +304,18 @@ export default {
}, },
ItemDetail() { ItemDetail() {
// Dispatch load file info detail // Dispatch load file info detail
this.$store.commit('GET_FILEINFO_DETAIL', this.item) this.$store.commit('ADD_ITEM_TO_CLIPBOARD', this.item)
// Show panel if is not open // Show panel if is not open
this.$store.dispatch('fileInfoToggle', true) this.$store.dispatch('fileInfoToggle', true)
}, },
deleteItem() { deleteItem() {
// If is context menu open on non selected item delete this single item // If is context menu open on non selected item delete this single item
if (!this.fileInfoDetail.includes(this.item)) { if (!this.clipboard.includes(this.item)) {
this.$store.dispatch('deleteItem', this.item) this.$store.dispatch('deleteItem', this.item)
} }
// If is context menu open to multi selected items dele this selected items // If is context menu open to multi selected items dele this selected items
if (this.fileInfoDetail.includes(this.item)) { if (this.clipboard.includes(this.item)) {
this.$store.dispatch('deleteItem') this.$store.dispatch('deleteItem')
} }
}, },
@@ -73,7 +73,7 @@ export default {
...mapGetters([ ...mapGetters([
'FilePreviewType', 'FilePreviewType',
'fileInfoVisible', 'fileInfoVisible',
'fileInfoDetail', 'clipboard',
'currentFolder', 'currentFolder',
'browseHistory', 'browseHistory',
'homeDirectory' 'homeDirectory'
@@ -109,7 +109,7 @@ export default {
'shared', 'shared',
'public' 'public'
] ]
return !this.$isThisLocation(locations) || this.fileInfoDetail.length === 0 return !this.$isThisLocation(locations) || this.clipboard.length === 0
}, },
canUploadInView() { canUploadInView() {
return !this.$isThisLocation(['base', 'public']) return !this.$isThisLocation(['base', 'public'])
@@ -122,7 +122,7 @@ export default {
'shared', 'shared',
'public' 'public'
] ]
return !this.$isThisLocation(locations) || this.fileInfoDetail.length === 0 return !this.$isThisLocation(locations) || this.clipboard.length === 0
}, },
canShareInView() { canShareInView() {
@@ -134,7 +134,7 @@ export default {
'public' 'public'
] ]
return !this.$isThisLocation(locations) || this.fileInfoDetail.length > 1 || this.fileInfoDetail.length === 0 return !this.$isThisLocation(locations) || this.clipboard.length > 1 || this.clipboard.length === 0
} }
}, },
data() { data() {
@@ -202,24 +202,24 @@ export default {
events.$emit('folder:actions', this.currentFolder) events.$emit('folder:actions', this.currentFolder)
}, },
deleteItem() { deleteItem() {
if (this.fileInfoDetail.length > 0) if (this.clipboard.length > 0)
this.$store.dispatch('deleteItem') this.$store.dispatch('deleteItem')
}, },
createFolder() { createFolder() {
this.$store.dispatch('createFolder', {name: this.$t('popup_create_folder.folder_default_name')}) this.$store.dispatch('createFolder', {name: this.$t('popup_create_folder.folder_default_name')})
}, },
moveItem() { moveItem() {
if (this.fileInfoDetail.length > 0) if (this.clipboard.length > 0)
events.$emit('popup:open', { name: 'move', item: this.fileInfoDetail }) events.$emit('popup:open', { name: 'move', item: this.clipboard })
}, },
shareItem() { shareItem() {
let event = this.fileInfoDetail[0].shared let event = this.clipboard[0].shared
? 'share-edit' ? 'share-edit'
: 'share-create' : 'share-create'
events.$emit('popup:open', { events.$emit('popup:open', {
name: event, name: event,
item: this.fileInfoDetail[0] item: this.clipboard[0]
}) })
} }
}, },
+5 -5
View File
@@ -11,10 +11,10 @@ export default {
name: 'DragUI', name: 'DragUI',
components: { MultiSelected }, components: { MultiSelected },
computed: { computed: {
...mapGetters(['fileInfoDetail']), ...mapGetters(['clipboard']),
title() { title() {
let filesLength = this.fileInfoDetail.length, let filesLength = this.clipboard.length,
hasDraggedItem = this.fileInfoDetail.includes(this.draggedItem) hasDraggedItem = this.clipboard.includes(this.draggedItem)
// Title for multiple selected items // Title for multiple selected items
if (filesLength > 1 && hasDraggedItem) { if (filesLength > 1 && hasDraggedItem) {
@@ -27,8 +27,8 @@ export default {
} }
}, },
subtitle() { subtitle() {
let filesLength = this.fileInfoDetail.length, let filesLength = this.clipboard.length,
hasDraggedItem = this.fileInfoDetail.includes(this.draggedItem) hasDraggedItem = this.clipboard.includes(this.draggedItem)
// Subtitle for multiple selected items // Subtitle for multiple selected items
if (filesLength > 1 && hasDraggedItem) { if (filesLength > 1 && hasDraggedItem) {
@@ -155,10 +155,10 @@
events.$emit('mobile-menu:show', 'file-filter') events.$emit('mobile-menu:show', 'file-filter')
}, },
selectAll() { selectAll() {
this.$store.commit('SELECT_ALL_FILES') this.$store.commit('ADD_ALL_ITEMS_TO_CLIPBOARD')
}, },
deselectAll() { deselectAll() {
this.$store.commit('CLEAR_FILEINFO_DETAIL') this.$store.commit('CLIPBOARD_CLEAR')
}, },
enableMultiSelectMode() { enableMultiSelectMode() {
this.isSelectMode = true this.isSelectMode = true
@@ -78,15 +78,15 @@
<!--File Info Panel--> <!--File Info Panel-->
<div v-if="! $isMinimalScale()" class="file-info-container" :class="{ 'is-fileinfo-visible': fileInfoVisible }"> <div v-if="! $isMinimalScale()" class="file-info-container" :class="{ 'is-fileinfo-visible': fileInfoVisible }">
<!--File info panel--> <!--File info panel-->
<FileInfoPanel v-if="fileInfoDetail.length === 1" /> <FileInfoPanel v-if="clipboard.length === 1" />
<MultiSelected v-if="fileInfoDetail.length > 1" <MultiSelected v-if="clipboard.length > 1"
:title="$t('file_detail.selected_multiple')" :title="$t('file_detail.selected_multiple')"
:subtitle="this.fileInfoDetail.length + ' ' + $tc('file_detail.items', this.fileInfoDetail.length)" :subtitle="this.clipboard.length + ' ' + $tc('file_detail.items', this.clipboard.length)"
/> />
<!--If file info panel empty show message--> <!--If file info panel empty show message-->
<EmptyMessage v-if="fileInfoDetail.length === 0" :message="$t('messages.nothing_to_preview')" icon="eye-off" /> <EmptyMessage v-if="clipboard.length === 0" :message="$t('messages.nothing_to_preview')" icon="eye-off" />
</div> </div>
</div> </div>
</template> </template>
@@ -123,7 +123,7 @@
'filesInQueueTotal', 'filesInQueueTotal',
'fileInfoVisible', 'fileInfoVisible',
'FilePreviewType', 'FilePreviewType',
'fileInfoDetail', 'clipboard',
'currentFolder', 'currentFolder',
'isSearching', 'isSearching',
'isLoading', 'isLoading',
@@ -141,12 +141,12 @@
draggedItems() { draggedItems() {
//Set opacity for dragged items //Set opacity for dragged items
if (!this.fileInfoDetail.includes(this.draggingId)) { if (!this.clipboard.includes(this.draggingId)) {
return [this.draggingId] return [this.draggingId]
} }
if (this.fileInfoDetail.includes(this.draggingId)) { if (this.clipboard.includes(this.draggingId)) {
return this.fileInfoDetail return this.clipboard
} }
} }
}, },
@@ -183,7 +183,7 @@
}, },
methods: { methods: {
deleteItems() { deleteItems() {
if (this.fileInfoDetail.length > 0 && this.$checkPermission('master') || this.$checkPermission('editor')) { if (this.clipboard.length > 0 && this.$checkPermission('master') || this.$checkPermission('editor')) {
this.$store.dispatch('deleteItem') this.$store.dispatch('deleteItem')
} }
}, },
@@ -216,17 +216,17 @@
if (data.type !== 'folder' || this.draggingId === data) return if (data.type !== 'folder' || this.draggingId === data) return
//Prevent move selected folder to folder if in beteewn selected folders //Prevent move selected folder to folder if in beteewn selected folders
if (this.fileInfoDetail.find(item => item === data && this.fileInfoDetail.length > 1)) return if (this.clipboard.find(item => item === data && this.clipboard.length > 1)) return
// Move folder to new parent // Move folder to new parent
//Move item if is not included in selected items //Move item if is not included in selected items
if (!this.fileInfoDetail.includes(this.draggingId)) { if (!this.clipboard.includes(this.draggingId)) {
this.$store.dispatch('moveItem', {to_item: data, noSelectedItem: this.draggingId}) this.$store.dispatch('moveItem', {to_item: data, noSelectedItem: this.draggingId})
} }
//Move selected items to folder //Move selected items to folder
if (this.fileInfoDetail.length > 0 && this.fileInfoDetail.includes(this.draggingId)) { if (this.clipboard.length > 0 && this.clipboard.includes(this.draggingId)) {
this.$store.dispatch('moveItem', {to_item: data, noSelectedItem: null}) this.$store.dispatch('moveItem', {to_item: data, noSelectedItem: null})
} }
@@ -247,7 +247,7 @@
filesContainerClick() { filesContainerClick() {
// Deselect items clicked by outside // Deselect items clicked by outside
this.$store.commit('CLEAR_FILEINFO_DETAIL') this.$store.commit('CLIPBOARD_CLEAR')
} }
}, },
created() { created() {
@@ -268,7 +268,7 @@
}) })
events.$on('fileItem:deselect', () => { events.$on('fileItem:deselect', () => {
this.$store.commit('CLEAR_FILEINFO_DETAIL') this.$store.commit('CLIPBOARD_CLEAR')
}) })
events.$on('scrollTop', () => { events.$on('scrollTop', () => {
@@ -1,5 +1,5 @@
<template> <template>
<div class="file-info-content" v-if="fileInfoDetail.length === 1"> <div class="file-info-content" v-if="clipboard.length === 1">
<div class="file-headline" spellcheck="false"> <div class="file-headline" spellcheck="false">
<FilePreviewDetail/> <FilePreviewDetail/>
@@ -14,37 +14,37 @@
</div> </div>
</div> </div>
<div class="file-info"> <div class="file-info">
<span ref="name" class="name">{{ fileInfoDetail[0].name }}</span> <span ref="name" class="name">{{ clipboard[0].name }}</span>
<span class="mimetype text-theme" v-if="fileInfoDetail[0].mimetype">.{{ fileInfoDetail[0].mimetype }}</span> <span class="mimetype text-theme" v-if="clipboard[0].mimetype">.{{ clipboard[0].mimetype }}</span>
</div> </div>
</div> </div>
</div> </div>
<!--Info list--> <!--Info list-->
<ListInfo> <ListInfo>
<ListInfoItem v-if="fileInfoDetail[0].filesize" <ListInfoItem v-if="clipboard[0].filesize"
:title="$t('file_detail.size')" :title="$t('file_detail.size')"
:content="fileInfoDetail[0].filesize"> :content="clipboard[0].filesize">
</ListInfoItem> </ListInfoItem>
<ListInfoItem v-if="$checkPermission(['master']) && fileInfoDetail[0].author !== 'user'" <ListInfoItem v-if="$checkPermission(['master']) && clipboard[0].author !== 'user'"
:title="$t('file_detail.author')" :title="$t('file_detail.author')"
:content="$t('file_detail.author_participant')"> :content="$t('file_detail.author_participant')">
</ListInfoItem> </ListInfoItem>
<ListInfoItem <ListInfoItem
:title="$t('file_detail.created_at')" :title="$t('file_detail.created_at')"
:content="fileInfoDetail[0].created_at"> :content="clipboard[0].created_at">
</ListInfoItem> </ListInfoItem>
<ListInfoItem v-if="$checkPermission(['master'])" <ListInfoItem v-if="$checkPermission(['master'])"
:title="$t('file_detail.where')"> :title="$t('file_detail.where')">
<div class="action-button" @click="moveItem"> <div class="action-button" @click="moveItem">
<span>{{ fileInfoDetail[0].parent ? fileInfoDetail[0].parent.name : $t('locations.home') }}</span> <span>{{ clipboard[0].parent ? clipboard[0].parent.name : $t('locations.home') }}</span>
<edit-2-icon size="10" class="edit-icon"></edit-2-icon> <edit-2-icon size="10" class="edit-icon"></edit-2-icon>
</div> </div>
</ListInfoItem> </ListInfoItem>
<ListInfoItem v-if="$checkPermission('master') && fileInfoDetail[0].shared" <ListInfoItem v-if="$checkPermission('master') && clipboard[0].shared"
:title="$t('file_detail.shared')"> :title="$t('file_detail.shared')">
<div class="action-button" @click="shareItemOptions"> <div class="action-button" @click="shareItemOptions">
<span>{{ sharedInfo }}</span> <span>{{ sharedInfo }}</span>
@@ -53,7 +53,7 @@
<div class="sharelink"> <div class="sharelink">
<lock-icon v-if="isLocked" @click="shareItemOptions" class="lock-icon" size="17"></lock-icon> <lock-icon v-if="isLocked" @click="shareItemOptions" class="lock-icon" size="17"></lock-icon>
<unlock-icon v-if="! isLocked" @click="shareItemOptions" class="lock-icon" size="17"></unlock-icon> <unlock-icon v-if="! isLocked" @click="shareItemOptions" class="lock-icon" size="17"></unlock-icon>
<CopyInput class="copy-sharelink" size="small" :item="fileInfoDetail[0]"/> <CopyInput class="copy-sharelink" size="small" :item="clipboard[0]"/>
</div> </div>
</ListInfoItem> </ListInfoItem>
@@ -91,23 +91,23 @@
LockIcon, LockIcon,
}, },
computed: { computed: {
...mapGetters(['fileInfoDetail', 'permissionOptions']), ...mapGetters(['clipboard', 'permissionOptions']),
fileType() { fileType() {
return this.fileInfoDetail[0].type return this.clipboard[0].type
}, },
canShowMetaData() { canShowMetaData() {
return this.fileInfoDetail[0].metadata && this.fileInfoDetail[0].metadata.ExifImageWidth return this.clipboard[0].metadata && this.clipboard[0].metadata.ExifImageWidth
}, },
sharedInfo() { sharedInfo() {
// Get permission title // Get permission title
let title = this.permissionOptions.find(option => { let title = this.permissionOptions.find(option => {
return option.value === this.fileInfoDetail[0].shared.permission return option.value === this.clipboard[0].shared.permission
}) })
return title ? this.$t(title.label) : this.$t('shared.can_download') return title ? this.$t(title.label) : this.$t('shared.can_download')
}, },
sharedIcon() { sharedIcon() {
switch (this.fileInfoDetail[0].shared.permission) { switch (this.clipboard[0].shared.permission) {
case 'editor': case 'editor':
return 'user-edit' return 'user-edit'
break break
@@ -119,17 +119,17 @@
} }
}, },
isLocked() { isLocked() {
return this.fileInfoDetail[0].shared.is_protected return this.clipboard[0].shared.is_protected
} }
}, },
methods: { methods: {
shareItemOptions() { shareItemOptions() {
// Open share item popup // Open share item popup
events.$emit('popup:open', {name: 'share-edit', item: this.fileInfoDetail[0]}) events.$emit('popup:open', {name: 'share-edit', item: this.clipboard[0]})
}, },
moveItem() { moveItem() {
// Move item fire popup // Move item fire popup
events.$emit("popup:open", { name: "move", item: this.fileInfoDetail}); events.$emit("popup:open", { name: "move", item: this.clipboard});
} }
} }
} }
@@ -59,7 +59,7 @@
</div> </div>
<span @mousedown.stop="showItemActions" class="show-actions" v-if="$isMobile() && ! mobileMultiSelect && canShowMobileOptions"> <span @mousedown.stop="showItemActions" class="show-actions" v-if="$isMobile() && ! mobileMultiSelect && canShowMobileOptions">
<MoreHorizontalIcon icon="ellipsis-h" size="16" class="icon-action text-theme"/> <MoreHorizontalIcon icon="ellipsis-h" size="16" class="icon-action text-theme" />
</span> </span>
</div> </div>
</div> </div>
@@ -84,7 +84,7 @@ export default {
}, },
computed: { computed: {
...mapGetters([ ...mapGetters([
'FilePreviewType', 'sharedDetail', 'fileInfoDetail', 'data' 'FilePreviewType', 'sharedDetail', 'clipboard', 'data'
]), ]),
folderEmojiOrColor() { folderEmojiOrColor() {
@@ -102,7 +102,7 @@ export default {
}, },
isClicked() { isClicked() {
return this.fileInfoDetail.some(element => element.id === this.item.id) return this.clipboard.some(element => element.id === this.item.id)
}, },
isFolder() { isFolder() {
return this.item.type === 'folder' return this.item.type === 'folder'
@@ -158,8 +158,8 @@ export default {
}, },
showItemActions() { showItemActions() {
// Load file info detail // Load file info detail
this.$store.commit('CLEAR_FILEINFO_DETAIL') this.$store.commit('CLIPBOARD_CLEAR')
this.$store.commit('GET_FILEINFO_DETAIL', this.item) this.$store.commit('ADD_ITEM_TO_CLIPBOARD', this.item)
events.$emit('mobile-menu:show', 'file-menu') events.$emit('mobile-menu:show', 'file-menu')
}, },
@@ -181,36 +181,36 @@ export default {
if (e.ctrlKey || e.metaKey && !e.shiftKey) { if (e.ctrlKey || e.metaKey && !e.shiftKey) {
// Click + Ctrl // Click + Ctrl
if (this.fileInfoDetail.some(item => item.id === this.item.id)) { if (this.clipboard.some(item => item.id === this.item.id)) {
this.$store.commit('REMOVE_ITEM_FILEINFO_DETAIL', this.item) this.$store.commit('REMOVE_ITEM_FROM_CLIPBOARD', this.item)
} else { } else {
this.$store.commit('GET_FILEINFO_DETAIL', this.item) this.$store.commit('ADD_ITEM_TO_CLIPBOARD', this.item)
} }
} else if (e.shiftKey) { } else if (e.shiftKey) {
// Click + Shift // Click + Shift
let lastItem = this.data.indexOf(this.fileInfoDetail[this.fileInfoDetail.length - 1]) let lastItem = this.data.indexOf(this.clipboard[this.clipboard.length - 1])
let clickedItem = this.data.indexOf(this.item) let clickedItem = this.data.indexOf(this.item)
// If Click + Shift + Ctrl dont remove already selected items // If Click + Shift + Ctrl dont remove already selected items
if (!e.ctrlKey && !e.metaKey) { if (!e.ctrlKey && !e.metaKey) {
this.$store.commit('CLEAR_FILEINFO_DETAIL') this.$store.commit('CLIPBOARD_CLEAR')
} }
//Shift selecting from top to bottom //Shift selecting from top to bottom
if (lastItem < clickedItem) { if (lastItem < clickedItem) {
for (let i = lastItem; i <= clickedItem; i++) { for (let i = lastItem; i <= clickedItem; i++) {
this.$store.commit('GET_FILEINFO_DETAIL', this.data[i]) this.$store.commit('ADD_ITEM_TO_CLIPBOARD', this.data[i])
} }
//Shift selecting from bottom to top //Shift selecting from bottom to top
} else { } else {
for (let i = lastItem; i >= clickedItem; i--) { for (let i = lastItem; i >= clickedItem; i--) {
this.$store.commit('GET_FILEINFO_DETAIL', this.data[i]) this.$store.commit('ADD_ITEM_TO_CLIPBOARD', this.data[i])
} }
} }
} else { } else {
// Click // Click
this.$store.commit('CLEAR_FILEINFO_DETAIL') this.$store.commit('CLIPBOARD_CLEAR')
this.$store.commit('GET_FILEINFO_DETAIL', this.item) this.$store.commit('ADD_ITEM_TO_CLIPBOARD', this.item)
} }
} }
@@ -219,24 +219,27 @@ export default {
if (this.isFolder) { if (this.isFolder) {
if (this.$isThisLocation('public')) { if (this.$isThisLocation('public')) {
this.$store.dispatch('browseShared', [{ folder: this.item, back: false, init: false }]) this.$store.dispatch('browseShared', [{folder: this.item, back: false, init: false}])
} else { } else {
this.$store.dispatch('getFolder', [{ folder: this.item, back: false, init: false }]) this.$store.dispatch('getFolder', [{folder: this.item, back: false, init: false}])
} }
} else { } else {
if (this.isImage || this.isVideo || this.isAudio || this.isPdf) { if (this.isImage || this.isVideo || this.isAudio || this.isPdf) {
this.$store.commit('LOAD_FILEINFO_DETAIL', this.item)
this.$store.commit('CLIPBOARD_CLEAR')
this.$store.commit('ADD_ITEM_TO_CLIPBOARD', this.item)
events.$emit('file-preview:show') events.$emit('file-preview:show')
} }
} }
} }
if (this.mobileMultiSelect && this.$isMobile()) { if (this.mobileMultiSelect && this.$isMobile()) {
if (this.fileInfoDetail.some(item => item.id === this.item.id)) { if (this.clipboard.some(item => item.id === this.item.id)) {
this.$store.commit('REMOVE_ITEM_FILEINFO_DETAIL', this.item) this.$store.commit('REMOVE_ITEM_FROM_CLIPBOARD', this.item)
} else { } else {
this.$store.commit('GET_FILEINFO_DETAIL', this.item) this.$store.commit('ADD_ITEM_TO_CLIPBOARD', this.item)
} }
} }
}, },
@@ -250,7 +253,7 @@ export default {
} else if (this.isFolder) { } else if (this.isFolder) {
//Clear selected data after open another folder //Clear selected data after open another folder
this.$store.commit('CLEAR_FILEINFO_DETAIL') this.$store.commit('CLIPBOARD_CLEAR')
if (this.$isThisLocation('public')) { if (this.$isThisLocation('public')) {
this.$store.dispatch('browseShared', [{folder: this.item, back: false, init: false}]) this.$store.dispatch('browseShared', [{folder: this.item, back: false, init: false}])
@@ -284,12 +287,12 @@ export default {
events.$on('mobileSelecting:start', () => { events.$on('mobileSelecting:start', () => {
this.mobileMultiSelect = true this.mobileMultiSelect = true
this.$store.commit('CLEAR_FILEINFO_DETAIL') this.$store.commit('CLIPBOARD_CLEAR')
}) })
events.$on('mobileSelecting:stop', () => { events.$on('mobileSelecting:stop', () => {
this.mobileMultiSelect = false this.mobileMultiSelect = false
this.$store.commit('CLEAR_FILEINFO_DETAIL') this.$store.commit('CLIPBOARD_CLEAR')
}) })
// Change item name // Change item name
events.$on('change:name', (item) => { events.$on('change:name', (item) => {
@@ -90,9 +90,9 @@ export default {
CheckIcon, CheckIcon,
}, },
computed: { computed: {
...mapGetters(['FilePreviewType', 'fileInfoDetail', 'data']), ...mapGetters(['FilePreviewType', 'clipboard', 'data']),
isClicked() { isClicked() {
return this.fileInfoDetail.some(element => element.id === this.item.id) return this.clipboard.some(element => element.id === this.item.id)
}, },
isFolder() { isFolder() {
return this.item.type === 'folder' return this.item.type === 'folder'
@@ -152,8 +152,8 @@ export default {
}, },
showItemActions() { showItemActions() {
// Load file info detail // Load file info detail
this.$store.commit('CLEAR_FILEINFO_DETAIL') this.$store.commit('CLIPBOARD_CLEAR')
this.$store.commit('GET_FILEINFO_DETAIL', this.item) this.$store.commit('ADD_ITEM_TO_CLIPBOARD', this.item)
events.$emit('mobile-menu:show', 'file-menu') events.$emit('mobile-menu:show', 'file-menu')
}, },
@@ -176,36 +176,36 @@ export default {
if ((e.ctrlKey || e.metaKey) && !e.shiftKey) { if ((e.ctrlKey || e.metaKey) && !e.shiftKey) {
// Click + Ctrl // Click + Ctrl
if (this.fileInfoDetail.some(item => item.id === this.item.id)) { if (this.clipboard.some(item => item.id === this.item.id)) {
this.$store.commit('REMOVE_ITEM_FILEINFO_DETAIL', this.item) this.$store.commit('REMOVE_ITEM_FROM_CLIPBOARD', this.item)
} else { } else {
this.$store.commit('GET_FILEINFO_DETAIL', this.item) this.$store.commit('ADD_ITEM_TO_CLIPBOARD', this.item)
} }
} else if (e.shiftKey) { } else if (e.shiftKey) {
// Click + Shift // Click + Shift
let lastItem = this.data.indexOf(this.fileInfoDetail[this.fileInfoDetail.length - 1]) let lastItem = this.data.indexOf(this.clipboard[this.clipboard.length - 1])
let clickedItem = this.data.indexOf(this.item) let clickedItem = this.data.indexOf(this.item)
// If Click + Shift + Ctrl dont remove already selected items // If Click + Shift + Ctrl dont remove already selected items
if (!e.ctrlKey && !e.metaKey) { if (!e.ctrlKey && !e.metaKey) {
this.$store.commit('CLEAR_FILEINFO_DETAIL') this.$store.commit('CLIPBOARD_CLEAR')
} }
//Shift selecting from top to bottom //Shift selecting from top to bottom
if (lastItem < clickedItem) { if (lastItem < clickedItem) {
for (let i = lastItem; i <= clickedItem; i++) { for (let i = lastItem; i <= clickedItem; i++) {
this.$store.commit('GET_FILEINFO_DETAIL', this.data[i]) this.$store.commit('ADD_ITEM_TO_CLIPBOARD', this.data[i])
} }
//Shift selecting from bottom to top //Shift selecting from bottom to top
} else { } else {
for (let i = lastItem; i >= clickedItem; i--) { for (let i = lastItem; i >= clickedItem; i--) {
this.$store.commit('GET_FILEINFO_DETAIL', this.data[i]) this.$store.commit('ADD_ITEM_TO_CLIPBOARD', this.data[i])
} }
} }
} else { } else {
// Click // Click
this.$store.commit('CLEAR_FILEINFO_DETAIL') this.$store.commit('CLIPBOARD_CLEAR')
this.$store.commit('GET_FILEINFO_DETAIL', this.item) this.$store.commit('ADD_ITEM_TO_CLIPBOARD', this.item)
} }
} }
@@ -221,17 +221,20 @@ export default {
} else { } else {
if (this.isImage || this.isVideo || this.isAudio || this.isPdf) { if (this.isImage || this.isVideo || this.isAudio || this.isPdf) {
this.$store.commit('LOAD_FILEINFO_DETAIL', this.item)
this.$store.commit('CLIPBOARD_CLEAR')
this.$store.commit('ADD_ITEM_TO_CLIPBOARD', this.item)
events.$emit('file-preview:show') events.$emit('file-preview:show')
} }
} }
} }
if (this.mobileMultiSelect && this.$isMobile()) { if (this.mobileMultiSelect && this.$isMobile()) {
if (this.fileInfoDetail.some(item => item.id === this.item.id)) { if (this.clipboard.some(item => item.id === this.item.id)) {
this.$store.commit('REMOVE_ITEM_FILEINFO_DETAIL', this.item) this.$store.commit('REMOVE_ITEM_FROM_CLIPBOARD', this.item)
} else { } else {
this.$store.commit('GET_FILEINFO_DETAIL', this.item) this.$store.commit('ADD_ITEM_TO_CLIPBOARD', this.item)
} }
} }
}, },
@@ -245,7 +248,7 @@ export default {
} else if (this.isFolder) { } else if (this.isFolder) {
// Clear selected items after open another folder // Clear selected items after open another folder
this.$store.commit('CLEAR_FILEINFO_DETAIL') this.$store.commit('CLIPBOARD_CLEAR')
if (this.$isThisLocation('public')) { if (this.$isThisLocation('public')) {
this.$store.dispatch('browseShared', [{ folder: this.item, back: false, init: false }]) this.$store.dispatch('browseShared', [{ folder: this.item, back: false, init: false }])
@@ -279,12 +282,12 @@ export default {
events.$on('mobileSelecting:start', () => { events.$on('mobileSelecting:start', () => {
this.mobileMultiSelect = true this.mobileMultiSelect = true
this.$store.commit('CLEAR_FILEINFO_DETAIL') this.$store.commit('CLIPBOARD_CLEAR')
}) })
events.$on('mobileSelecting:stop', () => { events.$on('mobileSelecting:stop', () => {
this.mobileMultiSelect = false this.mobileMultiSelect = false
this.$store.commit('CLEAR_FILEINFO_DETAIL') this.$store.commit('CLIPBOARD_CLEAR')
}) })
// Change item name // Change item name
@@ -1,10 +1,10 @@
<template> <template>
<MenuMobile name="file-menu"> <MenuMobile name="file-menu">
<ThumbnailItem class="item-thumbnail" :item="fileInfoDetail[0]" info="metadata" /> <ThumbnailItem class="item-thumbnail" :item="clipboard[0]" info="metadata" />
<!--Trash location--> <!--Trash location-->
<MenuMobileGroup v-if="$isThisLocation(['trash', 'trash-root']) && $checkPermission('master')"> <MenuMobileGroup v-if="$isThisLocation(['trash', 'trash-root']) && $checkPermission('master')">
<OptionGroup v-if="fileInfoDetail[0]"> <OptionGroup v-if="clipboard[0]">
<Option @click.native="restoreItem" :title="$t('context_menu.restore')" icon="restore" /> <Option @click.native="restoreItem" :title="$t('context_menu.restore')" icon="restore" />
<Option @click.native="deleteItem" :title="$t('context_menu.delete')" icon="delete" /> <Option @click.native="deleteItem" :title="$t('context_menu.delete')" icon="delete" />
</OptionGroup> </OptionGroup>
@@ -17,13 +17,13 @@
<!--Shared location--> <!--Shared location-->
<MenuMobileGroup v-if="$isThisLocation(['shared']) && $checkPermission('master')"> <MenuMobileGroup v-if="$isThisLocation(['shared']) && $checkPermission('master')">
<OptionGroup v-if="fileInfoDetail[0] && isFolder"> <OptionGroup v-if="clipboard[0] && isFolder">
<Option @click.native="addToFavourites" :title="favouritesTitle" icon="star" /> <Option @click.native="addToFavourites" :title="favouritesTitle" icon="star" />
</OptionGroup> </OptionGroup>
<OptionGroup v-if="fileInfoDetail[0]"> <OptionGroup v-if="clipboard[0]">
<Option @click.native="renameItem" :title="$t('context_menu.rename')" icon="rename" /> <Option @click.native="renameItem" :title="$t('context_menu.rename')" icon="rename" />
<Option @click.native="shareItem" :title="fileInfoDetail[0].shared ? $t('context_menu.share_edit') : $t('context_menu.share')" icon="share" /> <Option @click.native="shareItem" :title="clipboard[0].shared ? $t('context_menu.share_edit') : $t('context_menu.share')" icon="share" />
<Option @click.native="deleteItem" :title="$t('context_menu.delete')" icon="trash" /> <Option @click.native="deleteItem" :title="$t('context_menu.delete')" icon="trash" />
</OptionGroup> </OptionGroup>
@@ -35,14 +35,14 @@
<!--Base location for user--> <!--Base location for user-->
<MenuMobileGroup v-if="$isThisLocation(['base', 'participant_uploads', 'latest']) && $checkPermission('master')"> <MenuMobileGroup v-if="$isThisLocation(['base', 'participant_uploads', 'latest']) && $checkPermission('master')">
<OptionGroup v-if="fileInfoDetail[0] && isFolder"> <OptionGroup v-if="clipboard[0] && isFolder">
<Option @click.native="addToFavourites" :title="favouritesTitle" icon="star" /> <Option @click.native="addToFavourites" :title="favouritesTitle" icon="star" />
</OptionGroup> </OptionGroup>
<OptionGroup v-if="fileInfoDetail[0]"> <OptionGroup v-if="clipboard[0]">
<Option @click.native="renameItem" :title="$t('context_menu.rename')" icon="rename" /> <Option @click.native="renameItem" :title="$t('context_menu.rename')" icon="rename" />
<Option @click.native="moveItem" :title="$t('context_menu.move')" icon="move-item" /> <Option @click.native="moveItem" :title="$t('context_menu.move')" icon="move-item" />
<Option @click.native="shareItem" :title="fileInfoDetail[0].shared ? $t('context_menu.share_edit') : $t('context_menu.share')" icon="share" /> <Option @click.native="shareItem" :title="clipboard[0].shared ? $t('context_menu.share_edit') : $t('context_menu.share')" icon="share" />
<Option @click.native="deleteItem" :title="$t('context_menu.delete')" icon="trash" /> <Option @click.native="deleteItem" :title="$t('context_menu.delete')" icon="trash" />
</OptionGroup> </OptionGroup>
@@ -55,8 +55,8 @@
<!--Base location for guest--> <!--Base location for guest-->
<MenuMobileGroup v-if="$isThisLocation(['base', 'public']) && $checkPermission('editor')"> <MenuMobileGroup v-if="$isThisLocation(['base', 'public']) && $checkPermission('editor')">
<OptionGroup> <OptionGroup>
<Option v-if="fileInfoDetail[0]" @click.native="renameItem" :title="$t('context_menu.rename')" icon="rename" /> <Option v-if="clipboard[0]" @click.native="renameItem" :title="$t('context_menu.rename')" icon="rename" />
<Option v-if="fileInfoDetail[0]" @click.native="moveItem" :title="$t('context_menu.move')" icon="move-item" /> <Option v-if="clipboard[0]" @click.native="moveItem" :title="$t('context_menu.move')" icon="move-item" />
<Option @click.native="deleteItem" :title="$t('context_menu.delete')" icon="trash" /> <Option @click.native="deleteItem" :title="$t('context_menu.delete')" icon="trash" />
</OptionGroup> </OptionGroup>
@@ -96,7 +96,7 @@ export default {
}, },
computed: { computed: {
...mapGetters([ ...mapGetters([
'fileInfoDetail', 'clipboard',
'user', 'user',
]), ]),
favourites() { favourites() {
@@ -108,16 +108,16 @@ export default {
: this.$t('context_menu.add_to_favourites') : this.$t('context_menu.add_to_favourites')
}, },
isInFavourites() { isInFavourites() {
return this.favourites.find(el => el.id === this.fileInfoDetail[0].id) return this.favourites.find(el => el.id === this.clipboard[0].id)
}, },
isFile() { isFile() {
return !this.isImage && !this.isFolder return !this.isImage && !this.isFolder
}, },
isImage() { isImage() {
return this.fileInfoDetail[0] && this.fileInfoDetail[0].type === 'image' return this.clipboard[0] && this.clipboard[0].type === 'image'
}, },
isFolder() { isFolder() {
return this.fileInfoDetail[0] && this.fileInfoDetail[0].type === 'folder' return this.clipboard[0] && this.clipboard[0].type === 'folder'
} }
}, },
data() { data() {
@@ -127,42 +127,42 @@ export default {
}, },
methods: { methods: {
downloadFolder() { downloadFolder() {
this.$store.dispatch('downloadFolder', this.fileInfoDetail[0]) this.$store.dispatch('downloadFolder', this.clipboard[0])
}, },
moveItem() { moveItem() {
events.$emit('popup:open', {name: 'move', item: [this.fileInfoDetail[0]]}) events.$emit('popup:open', {name: 'move', item: [this.clipboard[0]]})
}, },
shareItem() { shareItem() {
let event = this.fileInfoDetail[0].shared let event = this.clipboard[0].shared
? 'share-edit' ? 'share-edit'
: 'share-create' : 'share-create'
events.$emit('popup:open', { events.$emit('popup:open', {
name: event, name: event,
item: this.fileInfoDetail[0] item: this.clipboard[0]
}) })
}, },
addToFavourites() { addToFavourites() {
if (this.favourites && !this.favourites.find(el => el.id === this.fileInfoDetail[0].id)) { if (this.favourites && !this.favourites.find(el => el.id === this.clipboard[0].id)) {
this.$store.dispatch('addToFavourites', this.fileInfoDetail[0]) this.$store.dispatch('addToFavourites', this.clipboard[0])
} else { } else {
this.$store.dispatch('removeFromFavourites', this.fileInfoDetail[0]) this.$store.dispatch('removeFromFavourites', this.clipboard[0])
} }
}, },
downloadItem() { downloadItem() {
this.$downloadFile( this.$downloadFile(
this.fileInfoDetail[0].file_url, this.clipboard[0].file_url,
this.fileInfoDetail[0].name + '.' + this.fileInfoDetail[0].mimetype this.clipboard[0].name + '.' + this.clipboard[0].mimetype
) )
}, },
deleteItem() { deleteItem() {
this.$store.dispatch('deleteItem') this.$store.dispatch('deleteItem')
}, },
restoreItem() { restoreItem() {
this.$store.dispatch('restoreItem', this.fileInfoDetail[0]) this.$store.dispatch('restoreItem', this.clipboard[0])
}, },
renameItem() { renameItem() {
events.$emit('popup:open', {name: 'rename-item', item: this.fileInfoDetail[0]}) events.$emit('popup:open', {name: 'rename-item', item: this.clipboard[0]})
}, },
} }
} }
@@ -1,5 +1,5 @@
<template> <template>
<div class="media-full-preview" id="mediaPreview" v-if="fileInfoDetail[0]"> <div class="media-full-preview" id="mediaPreview" v-if="clipboard[0]">
<!--Arrow navigation--> <!--Arrow navigation-->
<div v-if="files.length > 1" class="navigation-arrows"> <div v-if="files.length > 1" class="navigation-arrows">
@@ -79,23 +79,23 @@ export default {
}, },
computed: { computed: {
...mapGetters([ ...mapGetters([
'fileInfoDetail', 'clipboard',
'data', 'data',
]), ]),
currentFile() { currentFile() {
return this.files[Math.abs(this.currentIndex) % this.files.length] return this.files[Math.abs(this.currentIndex) % this.files.length]
}, },
isPDF() { isPDF() {
return this.fileInfoDetail[0].mimetype === 'pdf' return this.clipboard[0].mimetype === 'pdf'
}, },
isVideo() { isVideo() {
return this.fileInfoDetail[0].type === 'video' return this.clipboard[0].type === 'video'
}, },
isAudio() { isAudio() {
return this.fileInfoDetail[0].type === 'audio' return this.clipboard[0].type === 'audio'
}, },
isImage() { isImage() {
return this.fileInfoDetail[0].type === 'image' return this.clipboard[0].type === 'image'
} }
}, },
data() { data() {
@@ -113,21 +113,21 @@ export default {
events.$emit('file-preview:hide') events.$emit('file-preview:hide')
}, },
currentFile() { currentFile() {
if (this.fileInfoDetail[0]) { if (this.clipboard[0]) {
this.$store.commit('CLEAR_FILEINFO_DETAIL') this.$store.commit('CLIPBOARD_CLEAR')
this.$store.commit('GET_FILEINFO_DETAIL', this.currentFile) this.$store.commit('ADD_ITEM_TO_CLIPBOARD', this.currentFile)
// Init pdf instance // Init pdf instance
if (this.fileInfoDetail[0].mimetype === 'pdf') { if (this.clipboard[0].mimetype === 'pdf') {
this.getPdf() this.getPdf()
} }
} }
}, },
fileInfoDetail() { clipboard() {
if (!this.fileInfoDetail[0]) { if (!this.clipboard[0]) {
this.currentIndex -= 1 this.currentIndex -= 1
this.$store.commit('GET_FILEINFO_DETAIL', this.currentFile) this.$store.commit('ADD_ITEM_TO_CLIPBOARD', this.currentFile)
this.files = [] this.files = []
} }
@@ -172,7 +172,7 @@ export default {
self.pdfdata.then(pdf => self.numPages = pdf.numPages); self.pdfdata.then(pdf => self.numPages = pdf.numPages);
}, },
getFilesForView() { getFilesForView() {
let requestedFile = this.fileInfoDetail[0] let requestedFile = this.clipboard[0]
this.data.map(element => { this.data.map(element => {
@@ -189,7 +189,7 @@ export default {
}) })
this.files.forEach((element, index) => { this.files.forEach((element, index) => {
if (element.id === this.fileInfoDetail[0].id) { if (element.id === this.clipboard[0].id) {
this.currentIndex = index this.currentIndex = index
} }
}) })
@@ -1,9 +1,9 @@
<template> <template>
<div class="navigation-panel" v-if="fileInfoDetail[0]"> <div class="navigation-panel" v-if="clipboard[0]">
<div class="name-wrapper"> <div class="name-wrapper">
<x-icon @click="closeFullPreview" size="22" class="icon-close hover-text-theme" /> <x-icon @click="closeFullPreview" size="22" class="icon-close hover-text-theme" />
<div class="name-count-wrapper"> <div class="name-count-wrapper">
<p class="title">{{ fileInfoDetail[0].name }}</p> <p class="title">{{ clipboard[0].name }}</p>
<span class="file-count"> ({{ showingImageIndex + ' ' + $t('pronouns.of') + ' ' + files.length }}) </span> <span class="file-count"> ({{ showingImageIndex + ' ' + $t('pronouns.of') + ' ' + files.length }}) </span>
</div> </div>
<span @click.stop="menuOpen" id="fast-preview-menu" class="fast-menu-icon group"> <span @click.stop="menuOpen" id="fast-preview-menu" class="fast-menu-icon group">
@@ -12,7 +12,7 @@
</div> </div>
<div class="created-at-wrapper"> <div class="created-at-wrapper">
<p>{{ fileInfoDetail[0].filesize }}, {{ fileInfoDetail[0].created_at }}</p> <p>{{ clipboard[0].filesize }}, {{ clipboard[0].created_at }}</p>
</div> </div>
<div class="navigation-icons"> <div class="navigation-icons">
@@ -44,28 +44,28 @@
}, },
computed: { computed: {
...mapGetters([ ...mapGetters([
'fileInfoDetail', 'clipboard',
'data' 'data'
]), ]),
isImage() { isImage() {
return this.fileInfoDetail[0].type === 'image' return this.clipboard[0].type === 'image'
}, },
isPdf() { isPdf() {
return this.fileInfoDetail[0].mimetype === 'pdf' return this.clipboard[0].mimetype === 'pdf'
}, },
files() { files() {
let files = [] let files = []
this.data.map(element => { this.data.map(element => {
if (this.fileInfoDetail[0].mimetype === 'pdf') { if (this.clipboard[0].mimetype === 'pdf') {
if (element.mimetype === 'pdf') if (element.mimetype === 'pdf')
files.push(element) files.push(element)
} else { } else {
if (element.type === this.fileInfoDetail[0].type) if (element.type === this.clipboard[0].type)
files.push(element) files.push(element)
} }
}) })
@@ -76,7 +76,7 @@
let activeIndex = undefined let activeIndex = undefined
this.files.forEach((element, index) => { this.files.forEach((element, index) => {
if (element.id === this.fileInfoDetail[0].id) { if (element.id === this.clipboard[0].id) {
activeIndex = index + 1 activeIndex = index + 1
} }
}) })
@@ -106,25 +106,25 @@
}, },
downloadItem() { downloadItem() {
this.$downloadFile( this.$downloadFile(
this.fileInfoDetail[0].file_url, this.clipboard[0].file_url,
this.fileInfoDetail[0].name + '.' + this.fileInfoDetail[0].mimetype this.clipboard[0].name + '.' + this.clipboard[0].mimetype
) )
}, },
shareItem() { shareItem() {
let event = this.fileInfoDetail[0].shared let event = this.clipboard[0].shared
? 'share-edit' ? 'share-edit'
: 'share-create' : 'share-create'
events.$emit('popup:open', { events.$emit('popup:open', {
name: event, name: event,
item: this.fileInfoDetail[0] item: this.clipboard[0]
}) })
}, },
menuOpen() { menuOpen() {
if (this.$isMobile()) { if (this.$isMobile()) {
events.$emit('mobile-menu:show', 'file-menu') events.$emit('mobile-menu:show', 'file-menu')
} else { } else {
events.$emit('showContextMenuPreview:show', this.fileInfoDetail[0]) events.$emit('showContextMenuPreview:show', this.clipboard[0])
} }
}, },
closeFullPreview() { closeFullPreview() {
@@ -1,81 +1,81 @@
<template> <template>
<div> <div>
<ul class="meta-data-list"> <ul class="meta-data-list">
<li v-if="fileInfoDetail.metadata.DateTimeOriginal"> <li v-if="clipboard.metadata.DateTimeOriginal">
<span>{{ $t('file_detail_meta.time_data') }}</span> <span>{{ $t('file_detail_meta.time_data') }}</span>
<b>{{ fileInfoDetail.metadata.DateTimeOriginal }}</b> <b>{{ clipboard.metadata.DateTimeOriginal }}</b>
</li> </li>
<li v-if="fileInfoDetail.metadata.Artist"> <li v-if="clipboard.metadata.Artist">
<span>{{ $t('file_detail_meta.author') }}</span> <span>{{ $t('file_detail_meta.author') }}</span>
<b>{{ fileInfoDetail.metadata.Artist }}</b> <b>{{ clipboard.metadata.Artist }}</b>
</li> </li>
<li v-if="fileInfoDetail.metadata.ExifImageWidth && fileInfoDetail.metadata.ExifImageLength"> <li v-if="clipboard.metadata.ExifImageWidth && clipboard.metadata.ExifImageLength">
<span>{{ $t('file_detail_meta.dimension') }}</span> <span>{{ $t('file_detail_meta.dimension') }}</span>
<b>{{ fileInfoDetail.metadata.ExifImageWidth }}x{{ fileInfoDetail.metadata.ExifImageLength }}</b> <b>{{ clipboard.metadata.ExifImageWidth }}x{{ clipboard.metadata.ExifImageLength }}</b>
</li> </li>
<li v-if="fileInfoDetail.metadata.XResolution && fileInfoDetail.metadata.YResolution"> <li v-if="clipboard.metadata.XResolution && clipboard.metadata.YResolution">
<span>{{ $t('file_detail_meta.resolution') }}</span> <span>{{ $t('file_detail_meta.resolution') }}</span>
<b>{{ fileInfoDetail.metadata.XResolution }}x{{ fileInfoDetail.metadata.YResolution }}</b> <b>{{ clipboard.metadata.XResolution }}x{{ clipboard.metadata.YResolution }}</b>
</li> </li>
<li v-if="fileInfoDetail.metadata.ColorSpace"> <li v-if="clipboard.metadata.ColorSpace">
<span> {{ $t('file_detail_meta.color_space') }}</span> <span> {{ $t('file_detail_meta.color_space') }}</span>
<b>{{ fileInfoDetail.metadata.ColorSpace}}</b> <b>{{ clipboard.metadata.ColorSpace}}</b>
</li> </li>
<!--TODO: Colour profile:sRGB IEC61966-2.1--> <!--TODO: Colour profile:sRGB IEC61966-2.1-->
<li v-if="fileInfoDetail.metadata.Make"> <li v-if="clipboard.metadata.Make">
<span>{{ $t('file_detail_meta.make') }}</span> <span>{{ $t('file_detail_meta.make') }}</span>
<b>{{ fileInfoDetail.metadata.Make }}</b> <b>{{ clipboard.metadata.Make }}</b>
</li> </li>
<li v-if="fileInfoDetail.metadata.Model"> <li v-if="clipboard.metadata.Model">
<span>{{ $t('file_detail_meta.model') }}</span> <span>{{ $t('file_detail_meta.model') }}</span>
<b>{{ fileInfoDetail.metadata.Model }}</b> <b>{{ clipboard.metadata.Model }}</b>
</li> </li>
<li v-if="fileInfoDetail.metadata.ApertureValue"> <li v-if="clipboard.metadata.ApertureValue">
<span>{{ $t('file_detail_meta.aperture_value') }}</span> <span>{{ $t('file_detail_meta.aperture_value') }}</span>
<b v-html="parseInt(fileInfoDetail.metadata.ApertureValue) / 100"></b> <b v-html="parseInt(clipboard.metadata.ApertureValue) / 100"></b>
</li> </li>
<li v-if="fileInfoDetail.metadata.ExposureTime"> <li v-if="clipboard.metadata.ExposureTime">
<span>{{ $t('file_detail_meta.exposure') }}</span> <span>{{ $t('file_detail_meta.exposure') }}</span>
<b>{{ fileInfoDetail.metadata.ExposureTime }}</b> <b>{{ clipboard.metadata.ExposureTime }}</b>
</li> </li>
<li v-if="fileInfoDetail.metadata.FocalLength"> <li v-if="clipboard.metadata.FocalLength">
<span>{{ $t('file_detail_meta.focal') }}</span> <span>{{ $t('file_detail_meta.focal') }}</span>
<b>{{ fileInfoDetail.metadata.FocalLength }}</b> <b>{{ clipboard.metadata.FocalLength }}</b>
</li> </li>
<li v-if="fileInfoDetail.metadata.ISOSpeedRatings"> <li v-if="clipboard.metadata.ISOSpeedRatings">
<span>{{ $t('file_detail_meta.iso') }}</span> <span>{{ $t('file_detail_meta.iso') }}</span>
<b>{{ fileInfoDetail.metadata.ISOSpeedRatings }}</b> <b>{{ clipboard.metadata.ISOSpeedRatings }}</b>
</li> </li>
<li v-if="fileInfoDetail.metadata.COMPUTED.ApertureFNumber"> <li v-if="clipboard.metadata.COMPUTED.ApertureFNumber">
<span>{{ $t('file_detail_meta.aperature') }}</span> <span>{{ $t('file_detail_meta.aperature') }}</span>
<b>{{ fileInfoDetail.metadata.COMPUTED.ApertureFNumber }}</b> <b>{{ clipboard.metadata.COMPUTED.ApertureFNumber }}</b>
</li> </li>
<li v-if="fileInfoDetail.metadata.COMPUTED.CCDWidth"> <li v-if="clipboard.metadata.COMPUTED.CCDWidth">
<span>{{ $t('file_detail_meta.camera_lens') }}</span> <span>{{ $t('file_detail_meta.camera_lens') }}</span>
<b>{{ fileInfoDetail.metadata.COMPUTED.CCDWidth }}</b> <b>{{ clipboard.metadata.COMPUTED.CCDWidth }}</b>
</li> </li>
<li v-if="fileInfoDetail.metadata.GPSLongitude"> <li v-if="clipboard.metadata.GPSLongitude">
<span>{{ $t('file_detail_meta.longitude') }}</span> <span>{{ $t('file_detail_meta.longitude') }}</span>
<b>{{ formatGps(fileInfoDetail.metadata.GPSLongitude,fileInfoDetail.metadata.GPSLongitudeRef) }}</b> <b>{{ formatGps(clipboard.metadata.GPSLongitude,clipboard.metadata.GPSLongitudeRef) }}</b>
</li> </li>
<li v-if="fileInfoDetail.metadata.GPSLatitude"> <li v-if="clipboard.metadata.GPSLatitude">
<span>{{ $t('file_detail_meta.latitude') }}</span> <span>{{ $t('file_detail_meta.latitude') }}</span>
<b>{{ formatGps(fileInfoDetail.metadata.GPSLatitude, fileInfoDetail.metadata.GPSLatitudeRef) }}</b> <b>{{ formatGps(clipboard.metadata.GPSLatitude, clipboard.metadata.GPSLatitudeRef) }}</b>
</li> </li>
</ul> </ul>
@@ -89,8 +89,8 @@ import {split} from 'lodash'
export default { export default {
name: 'ImageMetaData', name: 'ImageMetaData',
computed: { computed: {
fileInfoDetail() { clipboard() {
return this.$store.getters.fileInfoDetail[0] return this.$store.getters.clipboard[0]
}, },
}, },
methods: { methods: {
@@ -40,7 +40,6 @@
...mapGetters([ ...mapGetters([
'fileInfoVisible', 'fileInfoVisible',
'FilePreviewType', 'FilePreviewType',
'fileInfoDetail',
'currentFolder', 'currentFolder',
'browseHistory', 'browseHistory',
'homeDirectory', 'homeDirectory',
@@ -1,9 +1,9 @@
<template> <template>
<transition name="context-menu"> <transition name="context-menu">
<div class="multiselect-actions" v-if="mobileMultiSelect"> <div class="multiselect-actions" v-if="mobileMultiSelect">
<ToolbarButton class="action-btn" v-if="!$isThisLocation(['trash', 'trash-root' , 'shared', 'latest']) && $checkPermission('master') || $checkPermission('editor')" source="move" :action="$t('actions.move')" :class="{'is-inactive' : fileInfoDetail.length < 1}" @click.native="moveItem" /> <ToolbarButton class="action-btn" v-if="!$isThisLocation(['trash', 'trash-root' , 'shared', 'latest']) && $checkPermission('master') || $checkPermission('editor')" source="move" :action="$t('actions.move')" :class="{'is-inactive' : clipboard.length < 1}" @click.native="moveItem" />
<ToolbarButton class="action-btn" v-if="!$isThisLocation(['shared']) && $checkPermission('master') || $checkPermission('editor')" source="trash" :class="{'is-inactive' : fileInfoDetail.length < 1}" :action="$t('actions.delete')" @click.native="deleteItem" /> <ToolbarButton class="action-btn" v-if="!$isThisLocation(['shared']) && $checkPermission('master') || $checkPermission('editor')" source="trash" :class="{'is-inactive' : clipboard.length < 1}" :action="$t('actions.delete')" @click.native="deleteItem" />
<ToolbarButton class="action-btn" v-if="!$isThisLocation(['shared'])" source="download" :class="{'is-inactive': canDownloadItems}" :action="$t('actions.delete')" @click.native="downloadItem" /> <ToolbarButton class="action-btn" v-if="!$isThisLocation(['shared'])" source="download" :class="{'is-inactive': canDownloadItems}" :action="$t('actions.delete')" @click.native="downloadItem" />
@@ -23,9 +23,9 @@ export default {
name: 'MultiSelectToolbarMobile', name: 'MultiSelectToolbarMobile',
components: {ToolbarButton}, components: {ToolbarButton},
computed: { computed: {
...mapGetters(['fileInfoDetail']), ...mapGetters(['clipboard']),
canDownloadItems() { canDownloadItems() {
return this.fileInfoDetail.filter(item => item.type === 'folder').length !== 0 return this.clipboard.filter(item => item.type === 'folder').length !== 0
} }
}, },
data() { data() {
@@ -42,16 +42,16 @@ export default {
events.$emit('mobileSelecting:stop') events.$emit('mobileSelecting:stop')
}, },
downloadItem() { downloadItem() {
if (this.fileInfoDetail.length > 1) if (this.clipboard.length > 1)
this.$store.dispatch('downloadFiles') this.$store.dispatch('downloadFiles')
else { else {
this.$downloadFile(this.fileInfoDetail[0].file_url, this.fileInfoDetail[0].name + '.' + this.fileInfoDetail[0].mimetype) this.$downloadFile(this.clipboard[0].file_url, this.clipboard[0].name + '.' + this.clipboard[0].mimetype)
} }
this.closeSelecting() this.closeSelecting()
}, },
moveItem() { moveItem() {
// Open move item popup // Open move item popup
events.$emit('popup:open', {name: 'move', item: [this.fileInfoDetail[0]]}) events.$emit('popup:open', {name: 'move', item: [this.clipboard[0]]})
}, },
deleteItem() { deleteItem() {
//Delete items //Delete items
@@ -1,9 +1,9 @@
<template> <template>
<div v-if="canBePreview" class="preview"> <div v-if="canBePreview" class="preview">
<img v-if="fileInfoDetail[0].type == 'image' && fileInfoDetail[0].thumbnail" :src="fileInfoDetail[0].thumbnail" :alt="fileInfoDetail[0].name" /> <img v-if="clipboard[0].type == 'image' && clipboard[0].thumbnail" :src="clipboard[0].thumbnail" :alt="clipboard[0].name" />
<audio v-else-if="fileInfoDetail[0].type == 'audio'" :src="fileInfoDetail[0].file_url" controlsList="nodownload" controls></audio> <audio v-else-if="clipboard[0].type == 'audio'" :src="clipboard[0].file_url" controlsList="nodownload" controls></audio>
<video v-else-if="fileInfoDetail[0].type == 'video'" controlsList="nodownload" disablePictureInPicture playsinline controls> <video v-else-if="clipboard[0].type == 'video'" controlsList="nodownload" disablePictureInPicture playsinline controls>
<source :src="fileInfoDetail[0].file_url" type="video/mp4"> <source :src="clipboard[0].file_url" type="video/mp4">
</video> </video>
</div> </div>
</template> </template>
@@ -15,11 +15,11 @@
export default { export default {
name: 'FilePreview', name: 'FilePreview',
computed: { computed: {
...mapGetters(['fileInfoDetail']), ...mapGetters(['clipboard']),
canBePreview() { canBePreview() {
return this.fileInfoDetail[0] && ! includes([ return this.clipboard[0] && ! includes([
'folder', 'file' 'folder', 'file'
], this.fileInfoDetail[0].type) ], this.clipboard[0].type)
} }
}, },
} }
@@ -11,12 +11,12 @@
<!--Folder tree--> <!--Folder tree-->
<div v-if="! isLoadingTree && navigation"> <div v-if="! isLoadingTree && navigation">
<ThumbnailItem v-if="fileInfoDetail.length < 2 || isSelectedItem" class="item-thumbnail" :item="pickedItem" info="location" /> <ThumbnailItem v-if="clipboard.length < 2 || isSelectedItem" class="item-thumbnail" :item="pickedItem" info="location" />
<MultiSelected class="multiple-selected" <MultiSelected class="multiple-selected"
:title="$t('file_detail.selected_multiple')" :title="$t('file_detail.selected_multiple')"
:subtitle="this.fileInfoDetail.length + ' ' + $tc('file_detail.items', this.fileInfoDetail.length)" :subtitle="this.clipboard.length + ' ' + $tc('file_detail.items', this.clipboard.length)"
v-if="fileInfoDetail.length > 1 && !isSelectedItem" /> v-if="clipboard.length > 1 && !isSelectedItem" />
<TreeMenu :disabled-by-id="pickedItem" :depth="1" :nodes="items" v-for="items in navigation" :key="items.id" /> <TreeMenu :disabled-by-id="pickedItem" :depth="1" :nodes="items" v-for="items in navigation" :key="items.id" />
</div> </div>
@@ -69,7 +69,7 @@
}, },
computed: { computed: {
...mapGetters([ ...mapGetters([
'fileInfoDetail', 'clipboard',
'navigation', 'navigation',
]), ]),
}, },
@@ -87,7 +87,7 @@
if (!this.selectedFolder) return if (!this.selectedFolder) return
// Prevent to move items to the same parent // Prevent to move items to the same parent
if ( isArray(this.selectedFolder) && this.fileInfoDetail.find(item => item.parent_id === this.selectedFolder.id)) return if ( isArray(this.selectedFolder) && this.clipboard.find(item => item.parent_id === this.selectedFolder.id)) return
// Move item // Move item
if (!this.isSelectedItem) { if (!this.isSelectedItem) {
@@ -134,13 +134,13 @@
}) })
// Store picked item // Store picked item
if (!this.fileInfoDetail.includes(args.item[0])) { if (!this.clipboard.includes(args.item[0])) {
this.pickedItem = args.item[0] this.pickedItem = args.item[0]
this.isSelectedItem = true this.isSelectedItem = true
} }
if (this.fileInfoDetail.includes(args.item[0])) { if (this.clipboard.includes(args.item[0])) {
this.pickedItem = this.fileInfoDetail[0] this.pickedItem = this.clipboard[0]
this.isSelectedItem = false this.isSelectedItem = false
} }
}) })
+3 -3
View File
@@ -31,14 +31,14 @@
TreeMenu, TreeMenu,
}, },
computed: { computed: {
...mapGetters(['fileInfoDetail']), ...mapGetters(['clipboard']),
indent() { indent() {
return { paddingLeft: this.depth * 20 + 'px' } return { paddingLeft: this.depth * 20 + 'px' }
}, },
disableId() { disableId() {
let canBeShow = true let canBeShow = true
if(this.fileInfoDetail.includes(this.disabledById)){ if(this.clipboard.includes(this.disabledById)){
this.fileInfoDetail.map(item => { this.clipboard.map(item => {
if(item.id === this.nodes.id) { if(item.id === this.nodes.id) {
canBeShow = false canBeShow = false
} }
@@ -37,7 +37,7 @@
FolderIcon, FolderIcon,
}, },
computed: { computed: {
...mapGetters(['fileInfoDetail']), ...mapGetters(['clipboard']),
disabledFolder() { disabledFolder() {
let disableFolder = false let disableFolder = false
@@ -84,12 +84,12 @@
methods: { methods: {
dragFinish() { dragFinish() {
// Move no selected item // Move no selected item
if(!this.fileInfoDetail.includes(this.draggedItem[0])) { if(!this.clipboard.includes(this.draggedItem[0])) {
this.$store.dispatch('moveItem', {to_item: this.nodes ,noSelectedItem:this.draggedItem[0]}) this.$store.dispatch('moveItem', {to_item: this.nodes ,noSelectedItem:this.draggedItem[0]})
} }
// Move all selected items // Move all selected items
if(this.fileInfoDetail.includes(this.draggedItem[0])) { if(this.clipboard.includes(this.draggedItem[0])) {
this.$store.dispatch('moveItem', {to_item: this.nodes ,noSelectedItem:null}) this.$store.dispatch('moveItem', {to_item: this.nodes ,noSelectedItem:null})
} }
@@ -127,12 +127,12 @@
//Get dragged item //Get dragged item
events.$on('dragstart' , (data) => { events.$on('dragstart' , (data) => {
//If is dragged item not selected //If is dragged item not selected
if(!this.fileInfoDetail.includes(data)) { if(!this.clipboard.includes(data)) {
this.draggedItem = [data] this.draggedItem = [data]
} }
//If are the dragged items selected //If are the dragged items selected
if(this.fileInfoDetail.includes(data)) { if(this.clipboard.includes(data)) {
this.draggedItem = this.fileInfoDetail this.draggedItem = this.clipboard
} }
}) })
+31 -33
View File
@@ -5,12 +5,14 @@ import router from '@/router'
import i18n from '@/i18n/index' import i18n from '@/i18n/index'
const defaultState = { const defaultState = {
fileInfoDetail: [],
currentFolder: undefined, currentFolder: undefined,
navigation: undefined, navigation: undefined,
isSearching: false, isSearching: false,
browseHistory: [],
isLoading: true, isLoading: true,
browseHistory: [],
clipboard: [],
data: [], data: [],
} }
@@ -30,7 +32,7 @@ const actions = {
// Set folder location // Set folder location
payload.folder.location = payload.folder.deleted_at || payload.folder.location === 'trash' ? 'trash' : 'base' payload.folder.location = payload.folder.deleted_at || payload.folder.location === 'trash' ? 'trash' : 'base'
if (! payload.back && !payload.sorting) if (!payload.back && !payload.sorting)
commit('STORE_PREVIOUS_FOLDER', getters.currentFolder) commit('STORE_PREVIOUS_FOLDER', getters.currentFolder)
let url = payload.folder.location === 'trash' let url = payload.folder.location === 'trash'
@@ -77,7 +79,7 @@ const actions = {
}) })
axios axios
.get(getters.api + '/browse/latest' ) .get(getters.api + '/browse/latest')
.then(response => { .then(response => {
commit('LOADING_STATE', {loading: false, data: response.data}) commit('LOADING_STATE', {loading: false, data: response.data})
events.$emit('scrollTop') events.$emit('scrollTop')
@@ -175,7 +177,6 @@ const actions = {
.catch(() => Vue.prototype.$isSomethingWrong()) .catch(() => Vue.prototype.$isSomethingWrong())
}, },
getFolderTree: ({commit, getters}) => { getFolderTree: ({commit, getters}) => {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
// Get route // Get route
@@ -204,14 +205,14 @@ const actions = {
} }
const mutations = { const mutations = {
UPDATE_FOLDER_TREE(state, tree) {
state.navigation = tree
},
LOADING_STATE(state, payload) { LOADING_STATE(state, payload) {
state.fileInfoDetail= [] state.clipboard = []
state.data = payload.data state.data = payload.data
state.isLoading = payload.loading state.isLoading = payload.loading
}, },
UPDATE_FOLDER_TREE(state, tree) {
state.navigation = tree
},
FLUSH_FOLDER_HISTORY(state) { FLUSH_FOLDER_HISTORY(state) {
state.browseHistory = [] state.browseHistory = []
}, },
@@ -227,9 +228,10 @@ const mutations = {
state.browseHistory.pop() state.browseHistory.pop()
}, },
CHANGE_ITEM_NAME(state, updatedFile) { CHANGE_ITEM_NAME(state, updatedFile) {
// Rename filename in file info detail
if (state.fileInfoDetail && state.fileInfoDetail.id === updatedFile.id) { // Rename filename in clipboard
state.fileInfoDetail = updatedFile if (state.clipboard && state.clipboard.id === updatedFile.id) {
state.clipboard = updatedFile
} }
// Rename item name in data view // Rename item name in data view
@@ -241,26 +243,6 @@ const mutations = {
} }
}) })
}, },
REMOVE_ITEM_FILEINFO_DETAIL(state,item) {
state.fileInfoDetail = state.fileInfoDetail.filter(element => element.id !== item.id)
},
CLEAR_FILEINFO_DETAIL(state) {
state.fileInfoDetail = []
},
LOAD_FILEINFO_DETAIL(state, item) {
state.fileInfoDetail = []
state.fileInfoDetail.push(item)
},
GET_FILEINFO_DETAIL(state, item) {
let selectedItem = state.data.find(el => el.id === item.id)
if(state.fileInfoDetail.includes(selectedItem)) return
state.fileInfoDetail.push(selectedItem ? selectedItem : state.currentFolder)
},
SELECT_ALL_FILES(state){
state.fileInfoDetail = state.data
},
CHANGE_SEARCHING_STATE(state, searchState) { CHANGE_SEARCHING_STATE(state, searchState) {
state.isSearching = searchState state.isSearching = searchState
}, },
@@ -286,10 +268,26 @@ const mutations = {
STORE_CURRENT_FOLDER(state, folder) { STORE_CURRENT_FOLDER(state, folder) {
state.currentFolder = folder state.currentFolder = folder
}, },
REMOVE_ITEM_FROM_CLIPBOARD(state, item) {
state.clipboard = state.clipboard.filter(element => element.id !== item.id)
},
ADD_ALL_ITEMS_TO_CLIPBOARD(state) {
state.clipboard = state.data
},
ADD_ITEM_TO_CLIPBOARD(state, item) {
let selectedItem = state.data.find(el => el.id === item.id)
if (state.clipboard.includes(selectedItem)) return
state.clipboard.push(selectedItem ? selectedItem : state.currentFolder)
},
CLIPBOARD_CLEAR(state) {
state.clipboard = []
},
} }
const getters = { const getters = {
fileInfoDetail: state => state.fileInfoDetail, clipboard: state => state.clipboard,
currentFolder: state => state.currentFolder, currentFolder: state => state.currentFolder,
browseHistory: state => state.browseHistory, browseHistory: state => state.browseHistory,
isSearching: state => state.isSearching, isSearching: state => state.isSearching,
+11 -11
View File
@@ -41,7 +41,7 @@ const actions = {
let files = [] let files = []
// get ids of selected files // get ids of selected files
getters.fileInfoDetail.forEach(file => files.push(file.id)) getters.clipboard.forEach(file => files.push(file.id))
// Get route // Get route
let route = getters.sharedDetail let route = getters.sharedDetail
@@ -71,9 +71,9 @@ const actions = {
let itemsToMove = [] let itemsToMove = []
let items = [noSelectedItem] let items = [noSelectedItem]
// If coming no selected item dont get items to move from fileInfoDetail // If coming no selected item dont get items to move from clipboard
if (!noSelectedItem) if (!noSelectedItem)
items = getters.fileInfoDetail items = getters.clipboard
items.forEach(data => itemsToMove.push({ items.forEach(data => itemsToMove.push({
'id': data.id, 'id': data.id,
@@ -82,7 +82,7 @@ const actions = {
// Remove file preview // Remove file preview
if (!noSelectedItem) if (!noSelectedItem)
commit('CLEAR_FILEINFO_DETAIL') commit('CLIPBOARD_CLEAR')
// Get route // Get route
let route = getters.sharedDetail let route = getters.sharedDetail
@@ -267,9 +267,9 @@ const actions = {
let items = [item] let items = [item]
let restoreToHome = false let restoreToHome = false
// If coming no selected item dont get items to restore from fileInfoDetail // If coming no selected item dont get items to restore from clipboard
if (!item) if (!item)
items = getters.fileInfoDetail items = getters.clipboard
// Check if file can be restored to home directory // Check if file can be restored to home directory
if (getters.currentFolder.location === 'trash') if (getters.currentFolder.location === 'trash')
@@ -281,7 +281,7 @@ const actions = {
})) }))
// Remove file preview // Remove file preview
commit('CLEAR_FILEINFO_DETAIL') commit('CLIPBOARD_CLEAR')
axios axios
.post(getters.api + '/trash/restore', { .post(getters.api + '/trash/restore', {
@@ -299,9 +299,9 @@ const actions = {
let itemsToDelete = [] let itemsToDelete = []
let items = [noSelectedItem] let items = [noSelectedItem]
// If coming no selected item dont get items to move from fileInfoDetail // If coming no selected item dont get items to move from clipboard
if (!noSelectedItem) if (!noSelectedItem)
items = getters.fileInfoDetail items = getters.clipboard
items.forEach(data => { items.forEach(data => {
itemsToDelete.push({ itemsToDelete.push({
@@ -333,7 +333,7 @@ const actions = {
// Remove file preview // Remove file preview
if (!noSelectedItem) { if (!noSelectedItem) {
commit('CLEAR_FILEINFO_DETAIL') commit('CLIPBOARD_CLEAR')
} }
// Get route // Get route
@@ -385,7 +385,7 @@ const actions = {
commit('LOADING_STATE', {loading: false, data: []}) commit('LOADING_STATE', {loading: false, data: []})
events.$emit('scrollTop') events.$emit('scrollTop')
commit('CLEAR_FILEINFO_DETAIL') commit('CLIPBOARD_CLEAR')
}) })
.catch(() => Vue.prototype.$isSomethingWrong()) .catch(() => Vue.prototype.$isSomethingWrong())
} }
+2 -2
View File
@@ -95,7 +95,7 @@ const actions = {
let items = [singleItem] let items = [singleItem]
if(!singleItem) { if(!singleItem) {
items = getters.fileInfoDetail items = getters.clipboard
} }
items.forEach(data => { items.forEach(data => {
@@ -119,7 +119,7 @@ const actions = {
// Flush shared data // Flush shared data
commit('FLUSH_SHARED', item.id) commit('FLUSH_SHARED', item.id)
commit('CLEAR_FILEINFO_DETAIL') commit('CLIPBOARD_CLEAR')
}) })
resolve(true) resolve(true)
+4 -4
View File
@@ -52,9 +52,9 @@ const actions = {
let addFavourites = [] let addFavourites = []
let items = [folder] let items = [folder]
// If dont coming single folder get folders to add to favourites from fileInfoDetail // If dont coming single folder get folders to add to favourites from clipboard
if (!folder) if (!folder)
items = context.getters.fileInfoDetail items = context.getters.clipboard
items.forEach((data) => { items.forEach((data) => {
if (data.type === 'folder') { if (data.type === 'folder') {
@@ -67,9 +67,9 @@ const actions = {
} }
}) })
// If dont coming single folder clear the selected folders in fileInfoDetail // If dont coming single folder clear the selected folders in clipboard
if (!folder) { if (!folder) {
context.commit('CLEAR_FILEINFO_DETAIL') context.commit('CLIPBOARD_CLEAR')
} }
let pushToFavorites = [] let pushToFavorites = []
+5 -5
View File
@@ -104,7 +104,7 @@ export default {
XIcon XIcon
}, },
computed: { computed: {
...mapGetters(['user', 'homeDirectory', 'currentFolder', 'config', 'fileInfoDetail']), ...mapGetters(['user', 'homeDirectory', 'currentFolder', 'config', 'clipboard']),
favourites() { favourites() {
return this.user.data.relationships.favourites.data.attributes.folders return this.user.data.relationships.favourites.data.attributes.folders
}, },
@@ -137,7 +137,7 @@ export default {
dragEnter() { dragEnter() {
if (this.draggedItem && this.draggedItem.type !== 'folder') return if (this.draggedItem && this.draggedItem.type !== 'folder') return
if (this.fileInfoDetail.length > 0 && this.fileInfoDetail.find(item => item.type !== 'folder')) return if (this.clipboard.length > 0 && this.clipboard.find(item => item.type !== 'folder')) return
this.area = true this.area = true
}, },
@@ -156,17 +156,17 @@ export default {
if (this.favourites.find(folder => folder.id == this.draggedItem.id)) return if (this.favourites.find(folder => folder.id == this.draggedItem.id)) return
// Prevent to move folders to self // Prevent to move folders to self
if (this.fileInfoDetail.length > 0 && this.fileInfoDetail.find(item => item.type !== 'folder')) return if (this.clipboard.length > 0 && this.clipboard.find(item => item.type !== 'folder')) return
// Store favourites folder // Store favourites folder
//Add to favourites non selected folder //Add to favourites non selected folder
if (!this.fileInfoDetail.includes(this.draggedItem)) { if (!this.clipboard.includes(this.draggedItem)) {
this.$store.dispatch('addToFavourites', this.draggedItem) this.$store.dispatch('addToFavourites', this.draggedItem)
} }
//Add to favourites selected folders //Add to favourites selected folders
if (this.fileInfoDetail.includes(this.draggedItem)) { if (this.clipboard.includes(this.draggedItem)) {
this.$store.dispatch('addToFavourites', null) this.$store.dispatch('addToFavourites', null)
} }