Added draggable and router
This commit is contained in:
parent
c8f110e490
commit
d1f3cbe0aa
@ -11,9 +11,12 @@
|
|||||||
"preview": "vite preview"
|
"preview": "vite preview"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"vue": "^3.2.25"
|
"install": "^0.13.0",
|
||||||
|
"vue": "^3.2.25",
|
||||||
|
"vue-router": "^4.0.14"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
"@braks/revue-draggable": "^0.4.2",
|
||||||
"@typescript-eslint/eslint-plugin": "^5.18.0",
|
"@typescript-eslint/eslint-plugin": "^5.18.0",
|
||||||
"@typescript-eslint/parser": "^5.18.0",
|
"@typescript-eslint/parser": "^5.18.0",
|
||||||
"@vitejs/plugin-vue": "^2.3.1",
|
"@vitejs/plugin-vue": "^2.3.1",
|
||||||
|
@ -1,20 +1,26 @@
|
|||||||
lockfileVersion: 5.3
|
lockfileVersion: 5.3
|
||||||
|
|
||||||
specifiers:
|
specifiers:
|
||||||
|
'@braks/revue-draggable': ^0.4.2
|
||||||
'@typescript-eslint/eslint-plugin': ^5.18.0
|
'@typescript-eslint/eslint-plugin': ^5.18.0
|
||||||
'@typescript-eslint/parser': ^5.18.0
|
'@typescript-eslint/parser': ^5.18.0
|
||||||
'@vitejs/plugin-vue': ^2.3.1
|
'@vitejs/plugin-vue': ^2.3.1
|
||||||
'@volar/vue-language-service': ^0.33.9
|
'@volar/vue-language-service': ^0.33.9
|
||||||
eslint: ^8.13.0
|
eslint: ^8.13.0
|
||||||
|
install: ^0.13.0
|
||||||
typescript: ^4.5.4
|
typescript: ^4.5.4
|
||||||
vite: ^2.9.0
|
vite: ^2.9.0
|
||||||
vue: ^3.2.25
|
vue: ^3.2.25
|
||||||
|
vue-router: ^4.0.14
|
||||||
vue-tsc: ^0.33.9
|
vue-tsc: ^0.33.9
|
||||||
|
|
||||||
dependencies:
|
dependencies:
|
||||||
|
install: 0.13.0
|
||||||
vue: 3.2.31
|
vue: 3.2.31
|
||||||
|
vue-router: 4.0.14_vue@3.2.31
|
||||||
|
|
||||||
devDependencies:
|
devDependencies:
|
||||||
|
'@braks/revue-draggable': 0.4.2_vue@3.2.31
|
||||||
'@typescript-eslint/eslint-plugin': 5.18.0_0dd9be2ba5ed9805045f3fec8be848f5
|
'@typescript-eslint/eslint-plugin': 5.18.0_0dd9be2ba5ed9805045f3fec8be848f5
|
||||||
'@typescript-eslint/parser': 5.18.0_eslint@8.13.0+typescript@4.6.3
|
'@typescript-eslint/parser': 5.18.0_eslint@8.13.0+typescript@4.6.3
|
||||||
'@vitejs/plugin-vue': 2.3.1_vite@2.9.1+vue@3.2.31
|
'@vitejs/plugin-vue': 2.3.1_vite@2.9.1+vue@3.2.31
|
||||||
@ -60,6 +66,20 @@ packages:
|
|||||||
to-fast-properties: 2.0.0
|
to-fast-properties: 2.0.0
|
||||||
dev: true
|
dev: true
|
||||||
|
|
||||||
|
/@braks/revue-draggable/0.4.2_vue@3.2.31:
|
||||||
|
resolution: {integrity: sha512-PfGYOs+uhyQnY8RmSfJDI5o2ZgUH2UY3OT/eoS1F0echNrVDNyyh6dNW9YX9dZO2boQPVZC3RjcFnCUG9Lj4xw==}
|
||||||
|
peerDependencies:
|
||||||
|
'@vue/composition-api': ^1.0.0-rc.1
|
||||||
|
vue: ^2.0.0 || >=3.0.5
|
||||||
|
peerDependenciesMeta:
|
||||||
|
'@vue/composition-api':
|
||||||
|
optional: true
|
||||||
|
dependencies:
|
||||||
|
'@vueuse/core': 7.7.1_vue@3.2.31
|
||||||
|
vue: 3.2.31
|
||||||
|
vue-demi: 0.12.5_vue@3.2.31
|
||||||
|
dev: true
|
||||||
|
|
||||||
/@emmetio/abbreviation/2.2.3:
|
/@emmetio/abbreviation/2.2.3:
|
||||||
resolution: {integrity: sha512-87pltuCPt99aL+y9xS6GPZ+Wmmyhll2WXH73gG/xpGcQ84DRnptBsI2r0BeIQ0EB/SQTOe2ANPqFqj3Rj5FOGA==}
|
resolution: {integrity: sha512-87pltuCPt99aL+y9xS6GPZ+Wmmyhll2WXH73gG/xpGcQ84DRnptBsI2r0BeIQ0EB/SQTOe2ANPqFqj3Rj5FOGA==}
|
||||||
dependencies:
|
dependencies:
|
||||||
@ -596,6 +616,10 @@ packages:
|
|||||||
'@vue/compiler-dom': 3.2.31
|
'@vue/compiler-dom': 3.2.31
|
||||||
'@vue/shared': 3.2.31
|
'@vue/shared': 3.2.31
|
||||||
|
|
||||||
|
/@vue/devtools-api/6.1.4:
|
||||||
|
resolution: {integrity: sha512-IiA0SvDrJEgXvVxjNkHPFfDx6SXw0b/TUkqMcDZWNg9fnCAHbTpoo59YfJ9QLFkwa3raau5vSlRVzMSLDnfdtQ==}
|
||||||
|
dev: false
|
||||||
|
|
||||||
/@vue/reactivity-transform/3.2.31:
|
/@vue/reactivity-transform/3.2.31:
|
||||||
resolution: {integrity: sha512-uS4l4z/W7wXdI+Va5pgVxBJ345wyGFKvpPYtdSgvfJfX/x2Ymm6ophQlXXB6acqGHtXuBqNyyO3zVp9b1r0MOA==}
|
resolution: {integrity: sha512-uS4l4z/W7wXdI+Va5pgVxBJ345wyGFKvpPYtdSgvfJfX/x2Ymm6ophQlXXB6acqGHtXuBqNyyO3zVp9b1r0MOA==}
|
||||||
dependencies:
|
dependencies:
|
||||||
@ -638,6 +662,37 @@ packages:
|
|||||||
/@vue/shared/3.2.31:
|
/@vue/shared/3.2.31:
|
||||||
resolution: {integrity: sha512-ymN2pj6zEjiKJZbrf98UM2pfDd6F2H7ksKw7NDt/ZZ1fh5Ei39X5tABugtT03ZRlWd9imccoK0hE8hpjpU7irQ==}
|
resolution: {integrity: sha512-ymN2pj6zEjiKJZbrf98UM2pfDd6F2H7ksKw7NDt/ZZ1fh5Ei39X5tABugtT03ZRlWd9imccoK0hE8hpjpU7irQ==}
|
||||||
|
|
||||||
|
/@vueuse/core/7.7.1_vue@3.2.31:
|
||||||
|
resolution: {integrity: sha512-PRRgbATMpoeUmkCEBtUeJgOwtew8s+4UsEd+Pm7MhkjL2ihCNrSqxNVtM6NFE4uP2sWnkGcZpCjPuNSxowJ1Ow==}
|
||||||
|
peerDependencies:
|
||||||
|
'@vue/composition-api': ^1.1.0
|
||||||
|
vue: ^2.6.0 || ^3.2.0
|
||||||
|
peerDependenciesMeta:
|
||||||
|
'@vue/composition-api':
|
||||||
|
optional: true
|
||||||
|
vue:
|
||||||
|
optional: true
|
||||||
|
dependencies:
|
||||||
|
'@vueuse/shared': 7.7.1_vue@3.2.31
|
||||||
|
vue: 3.2.31
|
||||||
|
vue-demi: 0.12.5_vue@3.2.31
|
||||||
|
dev: true
|
||||||
|
|
||||||
|
/@vueuse/shared/7.7.1_vue@3.2.31:
|
||||||
|
resolution: {integrity: sha512-rN2qd22AUl7VdBxihagWyhUNHCyVk9IpvBTTfHoLH9G7rGE552X1f+zeCfehuno0zXif13jPw+icW/wn2a0rnQ==}
|
||||||
|
peerDependencies:
|
||||||
|
'@vue/composition-api': ^1.1.0
|
||||||
|
vue: ^2.6.0 || ^3.2.0
|
||||||
|
peerDependenciesMeta:
|
||||||
|
'@vue/composition-api':
|
||||||
|
optional: true
|
||||||
|
vue:
|
||||||
|
optional: true
|
||||||
|
dependencies:
|
||||||
|
vue: 3.2.31
|
||||||
|
vue-demi: 0.12.5_vue@3.2.31
|
||||||
|
dev: true
|
||||||
|
|
||||||
/acorn-jsx/5.3.2_acorn@8.7.0:
|
/acorn-jsx/5.3.2_acorn@8.7.0:
|
||||||
resolution: {integrity: sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==}
|
resolution: {integrity: sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==}
|
||||||
peerDependencies:
|
peerDependencies:
|
||||||
@ -1897,6 +1952,11 @@ packages:
|
|||||||
resolution: {integrity: sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==}
|
resolution: {integrity: sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==}
|
||||||
dev: true
|
dev: true
|
||||||
|
|
||||||
|
/install/0.13.0:
|
||||||
|
resolution: {integrity: sha512-zDml/jzr2PKU9I8J/xyZBQn8rPCAY//UOYNmR01XwNwyfhEWObo2SWfSl1+0tm1u6PhxLwDnfsT/6jB7OUxqFA==}
|
||||||
|
engines: {node: '>= 0.10'}
|
||||||
|
dev: false
|
||||||
|
|
||||||
/is-alphabetical/1.0.4:
|
/is-alphabetical/1.0.4:
|
||||||
resolution: {integrity: sha512-DwzsA04LQ10FHTZuL0/grVDk4rFoVH1pjAToYwBrHSxcrBIGQuXrQMtD5U1b0U2XVgKZCTLLP8u2Qxqhy3l2Vg==}
|
resolution: {integrity: sha512-DwzsA04LQ10FHTZuL0/grVDk4rFoVH1pjAToYwBrHSxcrBIGQuXrQMtD5U1b0U2XVgKZCTLLP8u2Qxqhy3l2Vg==}
|
||||||
dev: true
|
dev: true
|
||||||
@ -3550,6 +3610,30 @@ packages:
|
|||||||
resolution: {integrity: sha512-EcswR2S8bpR7fD0YPeS7r2xXExrScVMxg4MedACaWHEtx9ftCF/qHG1xGkolzTPcEmjTavCQgbVzHUIdTMzFGA==}
|
resolution: {integrity: sha512-EcswR2S8bpR7fD0YPeS7r2xXExrScVMxg4MedACaWHEtx9ftCF/qHG1xGkolzTPcEmjTavCQgbVzHUIdTMzFGA==}
|
||||||
dev: true
|
dev: true
|
||||||
|
|
||||||
|
/vue-demi/0.12.5_vue@3.2.31:
|
||||||
|
resolution: {integrity: sha512-BREuTgTYlUr0zw0EZn3hnhC3I6gPWv+Kwh4MCih6QcAeaTlaIX0DwOVN0wHej7hSvDPecz4jygy/idsgKfW58Q==}
|
||||||
|
engines: {node: '>=12'}
|
||||||
|
hasBin: true
|
||||||
|
requiresBuild: true
|
||||||
|
peerDependencies:
|
||||||
|
'@vue/composition-api': ^1.0.0-rc.1
|
||||||
|
vue: ^3.0.0-0 || ^2.6.0
|
||||||
|
peerDependenciesMeta:
|
||||||
|
'@vue/composition-api':
|
||||||
|
optional: true
|
||||||
|
dependencies:
|
||||||
|
vue: 3.2.31
|
||||||
|
dev: true
|
||||||
|
|
||||||
|
/vue-router/4.0.14_vue@3.2.31:
|
||||||
|
resolution: {integrity: sha512-wAO6zF9zxA3u+7AkMPqw9LjoUCjSxfFvINQj3E/DceTt6uEz1XZLraDhdg2EYmvVwTBSGlLYsUw8bDmx0754Mw==}
|
||||||
|
peerDependencies:
|
||||||
|
vue: ^3.2.0
|
||||||
|
dependencies:
|
||||||
|
'@vue/devtools-api': 6.1.4
|
||||||
|
vue: 3.2.31
|
||||||
|
dev: false
|
||||||
|
|
||||||
/vue-tsc/0.33.9_typescript@4.6.3:
|
/vue-tsc/0.33.9_typescript@4.6.3:
|
||||||
resolution: {integrity: sha512-s/+r4JNsCh4e3MUdsYrjEA8IgPPDzHL5kEah/OznxIHd1XMlYiIkXGdiyU6JE5J+lzXNOKdOlNliqwwpeETQWw==}
|
resolution: {integrity: sha512-s/+r4JNsCh4e3MUdsYrjEA8IgPPDzHL5kEah/OznxIHd1XMlYiIkXGdiyU6JE5J+lzXNOKdOlNliqwwpeETQWw==}
|
||||||
hasBin: true
|
hasBin: true
|
||||||
|
11
src/App.vue
11
src/App.vue
@ -5,8 +5,16 @@ import HelloWorld from './components/HelloWorld.vue'
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
|
<div id = "sidebar">
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id = "main">
|
||||||
<img alt="Vue logo" src="./assets/logo.png" />
|
<img alt="Vue logo" src="./assets/logo.png" />
|
||||||
<HelloWorld msg="Hello Vue 3 + TypeScript + Vite" />
|
<git msg="Hello Vue 3 + TypeScript + Vite" />
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
@ -18,4 +26,5 @@ import HelloWorld from './components/HelloWorld.vue'
|
|||||||
color: #2c3e50;
|
color: #2c3e50;
|
||||||
margin-top: 60px;
|
margin-top: 60px;
|
||||||
}
|
}
|
||||||
|
|
||||||
</style>
|
</style>
|
||||||
|
10
src/components/Sidebar.vue
Normal file
10
src/components/Sidebar.vue
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
<script setup></script>
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<div
|
||||||
|
v-draggable="/* Pass DraggableProps as binding value here */"
|
||||||
|
class="box"
|
||||||
|
>
|
||||||
|
I use a directive to make myself draggable
|
||||||
|
</div>
|
||||||
|
</template>
|
@ -1,4 +1,9 @@
|
|||||||
import { createApp } from 'vue'
|
import { createApp } from 'vue'
|
||||||
import App from './App.vue'
|
import App from './App.vue'
|
||||||
|
import Draggable, { DraggablePlugin, DraggableDirective } from '@braks/revue-draggable'
|
||||||
|
|
||||||
createApp(App).mount('#app')
|
|
||||||
|
const app = createApp(App)
|
||||||
|
|
||||||
|
app.use(DraggablePlugin)
|
||||||
|
app.mount('#app')
|
||||||
|
Loading…
Reference in New Issue
Block a user