diff --git a/package-lock.json b/package-lock.json index 92cb9bed..f5037526 100644 --- a/package-lock.json +++ b/package-lock.json @@ -23,7 +23,7 @@ "@nextcloud/eslint-config": "^8.4.1", "@nextcloud/stylelint-config": "^3.0.1", "@nextcloud/vite-config": "^2.2.2", - "@vue/tsconfig": "^0.4.0", + "@vue/tsconfig": "^0.6.0", "prettier": "^3.3.3", "stylelint-config-css-modules": "^4.4.0", "typescript": "^5.6.3", @@ -2832,10 +2832,23 @@ "integrity": "sha512-/hnE/qP5ZoGpol0a5mDi45bOd7t3tjYJBjsgCsivow7D48cJeV5l05RD82lPqi7gRiphZM37rnhW1l6ZoCNNnQ==" }, "node_modules/@vue/tsconfig": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/@vue/tsconfig/-/tsconfig-0.4.0.tgz", - "integrity": "sha512-CPuIReonid9+zOG/CGTT05FXrPYATEqoDGNrEaqS4hwcw5BUNM2FguC0mOwJD4Jr16UpRVl9N0pY3P+srIbqmg==", - "dev": true + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/@vue/tsconfig/-/tsconfig-0.6.0.tgz", + "integrity": "sha512-MHXNd6lzugsEHvuA6l1GqrF5jROqUon8sP/HInLPnthJiYvB0VvpHMywg7em1dBZfFZNBSkR68qH37zOdRHmCw==", + "dev": true, + "license": "MIT", + "peerDependencies": { + "typescript": "5.x", + "vue": "^3.3.0" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + }, + "vue": { + "optional": true + } + } }, "node_modules/acorn": { "version": "8.12.1", @@ -10343,6 +10356,7 @@ "version": "3.5.13", "resolved": "https://registry.npmjs.org/vue/-/vue-3.5.13.tgz", "integrity": "sha512-wmeiSMxkZCSc+PM2w2VRsOYAZC8GdipNFRTsLSfodVqI9mbejKeXEGr8SckuLnrQPGe3oJN5c3K0vpoU9q/wCQ==", + "license": "MIT", "dependencies": { "@vue/compiler-dom": "3.5.13", "@vue/compiler-sfc": "3.5.13", diff --git a/package.json b/package.json index db9deaf7..71d08809 100644 --- a/package.json +++ b/package.json @@ -28,7 +28,7 @@ "@nextcloud/eslint-config": "^8.4.1", "@nextcloud/stylelint-config": "^3.0.1", "@nextcloud/vite-config": "^2.2.2", - "@vue/tsconfig": "^0.4.0", + "@vue/tsconfig": "^0.6.0", "prettier": "^3.3.3", "stylelint-config-css-modules": "^4.4.0", "typescript": "^5.6.3", diff --git a/src/main.ts b/src/main.ts index ebb6751e..bea046ea 100644 --- a/src/main.ts +++ b/src/main.ts @@ -3,7 +3,6 @@ * SPDX-License-Identifier: AGPL-3.0-or-later */ -import Vue from 'vue' import { FileAction, type Node, @@ -32,18 +31,18 @@ const switchLock = async (node: Node) => { const state = getLockStateFromAttributes(node) if (!state.isLocked) { const data = await lockFile(node) - Vue.set(node.attributes, 'lock', '1') - Vue.set(node.attributes, 'lock-owner', data.userId) - Vue.set(node.attributes, 'lock-owner-displayname', data.displayName) - Vue.set(node.attributes, 'lock-owner-type', data.type) - Vue.set(node.attributes, 'lock-time', data.creation) + node.attributes.lock = '1' + node.attributes['lock-owner'] = data.userId + node.attributes['lock-owner-displayname'] = data.displayName + node.attributes['lock-owner-type'] = data.type + node.attributes['lock-time'] = data.creation } else { await unlockFile(node) - Vue.set(node.attributes, 'lock', '') - Vue.set(node.attributes, 'lock-owner', '') - Vue.set(node.attributes, 'lock-owner-displayname', '') - Vue.set(node.attributes, 'lock-owner-type', '') - Vue.set(node.attributes, 'lock-time', '') + node.attributes.lock = '' + node.attributes['lock-owner'] = '' + node.attributes['lock-owner-displayname'] = '' + node.attributes['lock-owner-type'] = '' + node.attributes['lock-time'] = '' } emit('files:node:updated', node) return true