@duxweb/dvha-elementui 0.0.4 → 0.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/components/menu/TreeMenu.vue.cjs +1 -0
- package/dist/cjs/components/menu/TreeMenu.vue2.cjs +1 -0
- package/dist/cjs/hooks/tab.cjs +1 -0
- package/dist/cjs/index.cjs +1 -0
- package/dist/cjs/node_modules/@vue/reactivity/dist/reactivity.esm-bundler.cjs +5 -0
- package/dist/cjs/node_modules/@vue/runtime-core/dist/runtime-core.esm-bundler.cjs +10 -0
- package/dist/cjs/node_modules/@vue/shared/dist/shared.esm-bundler.cjs +5 -0
- package/dist/cjs/node_modules/vue/dist/vue.runtime.esm-bundler.cjs +5 -0
- package/dist/cjs/node_modules/vue-router/dist/vue-router.cjs +5 -0
- package/dist/esm/components/menu/TreeMenu.vue.js +72 -0
- package/dist/esm/components/menu/TreeMenu.vue2.js +4 -0
- package/dist/esm/hooks/tab.js +26 -0
- package/dist/esm/index.js +6 -0
- package/dist/esm/node_modules/@vue/reactivity/dist/reactivity.esm-bundler.js +721 -0
- package/dist/esm/node_modules/@vue/runtime-core/dist/runtime-core.esm-bundler.js +892 -0
- package/dist/esm/node_modules/@vue/shared/dist/shared.esm-bundler.js +103 -0
- package/dist/esm/node_modules/vue/dist/vue.runtime.esm-bundler.js +40 -0
- package/dist/esm/node_modules/vue-router/dist/vue-router.js +33 -0
- package/dist/types/components/index.d.ts +1 -0
- package/dist/types/components/menu/TreeMenu.vue.d.ts +26 -0
- package/dist/types/components/menu/index.d.ts +1 -0
- package/dist/types/hooks/index.d.ts +1 -0
- package/dist/types/hooks/tab.d.ts +1950 -0
- package/dist/types/index.d.ts +2 -0
- package/package.json +28 -2
- package/CHANGELOG.md +0 -23
- package/src/components/index.ts +0 -1
- package/src/components/menu/TreeMenu.vue +0 -53
- package/src/components/menu/index.ts +0 -1
- package/src/hooks/index.ts +0 -1
- package/src/hooks/tab.ts +0 -29
- package/src/index.ts +0 -2
- package/tsconfig.json +0 -40
package/package.json
CHANGED
|
@@ -1,10 +1,36 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@duxweb/dvha-elementui",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.6",
|
|
5
5
|
"author": "DuxWeb",
|
|
6
6
|
"license": "LGPL-3.0",
|
|
7
|
-
"
|
|
7
|
+
"exports": {
|
|
8
|
+
".": {
|
|
9
|
+
"dvha:development": {
|
|
10
|
+
"types": "./src/index.ts",
|
|
11
|
+
"import": "./src/index.ts"
|
|
12
|
+
},
|
|
13
|
+
"types": "./dist/types/index.d.ts",
|
|
14
|
+
"import": "./dist/esm/index.js",
|
|
15
|
+
"require": "./dist/cjs/index.cjs"
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
"main": "dist/cjs/index.cjs",
|
|
19
|
+
"module": "dist/esm/index.js",
|
|
20
|
+
"types": "dist/types/index.d.ts",
|
|
21
|
+
"files": [
|
|
22
|
+
"LICENSE",
|
|
23
|
+
"README.md",
|
|
24
|
+
"dist"
|
|
25
|
+
],
|
|
26
|
+
"scripts": {
|
|
27
|
+
"clean": "rimraf dist",
|
|
28
|
+
"build": "bun run clean && vite build && bun run build:types",
|
|
29
|
+
"build:types": "vue-tsc --declaration --emitDeclarationOnly --outDir dist/types",
|
|
30
|
+
"prepublishOnly": "bun run build",
|
|
31
|
+
"lint": "eslint .",
|
|
32
|
+
"lint:fix": "eslint . --fix"
|
|
33
|
+
},
|
|
8
34
|
"dependencies": {
|
|
9
35
|
"@duxweb/dvha-core": "latest",
|
|
10
36
|
"element-plus": "^2.9.10"
|
package/CHANGELOG.md
DELETED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
# @duxweb/dvha-elementui
|
|
2
|
-
|
|
3
|
-
## 0.0.4
|
|
4
|
-
|
|
5
|
-
### Patch Changes
|
|
6
|
-
|
|
7
|
-
- update base releases
|
|
8
|
-
|
|
9
|
-
## 0.0.3
|
|
10
|
-
|
|
11
|
-
### Patch Changes
|
|
12
|
-
|
|
13
|
-
- fix: 更新内部依赖
|
|
14
|
-
- Updated dependencies
|
|
15
|
-
- @duxweb/dvha-core@0.0.3
|
|
16
|
-
|
|
17
|
-
## 0.0.2
|
|
18
|
-
|
|
19
|
-
### Patch Changes
|
|
20
|
-
|
|
21
|
-
- init
|
|
22
|
-
- Updated dependencies
|
|
23
|
-
- @duxweb/dvha-core@0.0.2
|
package/src/components/index.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './menu'
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import type { IMenu } from '@duxweb/dvha-core'
|
|
3
|
-
|
|
4
|
-
defineOptions({
|
|
5
|
-
name: 'TreeMenu',
|
|
6
|
-
})
|
|
7
|
-
|
|
8
|
-
defineProps({
|
|
9
|
-
menuItems: {
|
|
10
|
-
type: Array,
|
|
11
|
-
required: true,
|
|
12
|
-
},
|
|
13
|
-
onMenuClick: {
|
|
14
|
-
type: Function as unknown as () => (item: MenuOption) => void,
|
|
15
|
-
default: () => {},
|
|
16
|
-
},
|
|
17
|
-
})
|
|
18
|
-
|
|
19
|
-
export interface MenuOption extends IMenu {
|
|
20
|
-
children?: MenuOption[]
|
|
21
|
-
}
|
|
22
|
-
</script>
|
|
23
|
-
|
|
24
|
-
<template>
|
|
25
|
-
<template v-for="item in menuItems as MenuOption[]" :key="item.name">
|
|
26
|
-
<el-sub-menu v-if="item.children && item.children.length" :index="item.name">
|
|
27
|
-
<el-icon v-if="item.icon">
|
|
28
|
-
<div :class="item.icon" />
|
|
29
|
-
</el-icon>
|
|
30
|
-
<template #title>
|
|
31
|
-
{{ item.label }}
|
|
32
|
-
</template>
|
|
33
|
-
|
|
34
|
-
<TreeMenu
|
|
35
|
-
:menu-items="item.children"
|
|
36
|
-
:on-menu-click="onMenuClick"
|
|
37
|
-
/>
|
|
38
|
-
</el-sub-menu>
|
|
39
|
-
|
|
40
|
-
<el-menu-item
|
|
41
|
-
v-else
|
|
42
|
-
:index="item.name"
|
|
43
|
-
@click="onMenuClick(item)"
|
|
44
|
-
>
|
|
45
|
-
<el-icon v-if="item.icon">
|
|
46
|
-
<div :class="item.icon" />
|
|
47
|
-
</el-icon>
|
|
48
|
-
<template #title>
|
|
49
|
-
{{ item.label }}
|
|
50
|
-
</template>
|
|
51
|
-
</el-menu-item>
|
|
52
|
-
</template>
|
|
53
|
-
</template>
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as TreeMenu } from './TreeMenu.vue'
|
package/src/hooks/index.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './tab'
|
package/src/hooks/tab.ts
DELETED
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import { useTabStore } from '@duxweb/dvha-core'
|
|
2
|
-
import { computed } from 'vue'
|
|
3
|
-
import { useRouter } from 'vue-router'
|
|
4
|
-
|
|
5
|
-
export function useElmTab() {
|
|
6
|
-
const tab = useTabStore()
|
|
7
|
-
const router = useRouter()
|
|
8
|
-
|
|
9
|
-
const props = computed(() => {
|
|
10
|
-
return {
|
|
11
|
-
modelValue: tab.current,
|
|
12
|
-
onTabRemove: (value: string) => {
|
|
13
|
-
tab.delTab(value, (item) => {
|
|
14
|
-
router.push(item.path || '')
|
|
15
|
-
})
|
|
16
|
-
},
|
|
17
|
-
onTabChange: (value: string) => {
|
|
18
|
-
tab.changeTab(value, (item) => {
|
|
19
|
-
router.push(item.path || '')
|
|
20
|
-
})
|
|
21
|
-
},
|
|
22
|
-
}
|
|
23
|
-
})
|
|
24
|
-
|
|
25
|
-
return {
|
|
26
|
-
...tab,
|
|
27
|
-
props,
|
|
28
|
-
}
|
|
29
|
-
}
|
package/src/index.ts
DELETED
package/tsconfig.json
DELETED
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"compilerOptions": {
|
|
3
|
-
"target": "ESNext",
|
|
4
|
-
"jsx": "preserve",
|
|
5
|
-
"jsxImportSource": "vue",
|
|
6
|
-
"lib": [
|
|
7
|
-
"ESNext",
|
|
8
|
-
"DOM"
|
|
9
|
-
],
|
|
10
|
-
"moduleDetection": "force",
|
|
11
|
-
"useDefineForClassFields": true,
|
|
12
|
-
"baseUrl": ".",
|
|
13
|
-
"rootDir": "src",
|
|
14
|
-
"module": "ESNext",
|
|
15
|
-
"moduleResolution": "bundler",
|
|
16
|
-
"resolveJsonModule": true,
|
|
17
|
-
"allowJs": true,
|
|
18
|
-
"strict": true,
|
|
19
|
-
"noFallthroughCasesInSwitch": true,
|
|
20
|
-
"noImplicitAny": false,
|
|
21
|
-
"noUnusedLocals": true,
|
|
22
|
-
"noUnusedParameters": true,
|
|
23
|
-
"declaration": true,
|
|
24
|
-
"noEmit": false,
|
|
25
|
-
"outDir": "dist",
|
|
26
|
-
"allowSyntheticDefaultImports": true,
|
|
27
|
-
"esModuleInterop": true,
|
|
28
|
-
"isolatedModules": true,
|
|
29
|
-
"skipLibCheck": true
|
|
30
|
-
},
|
|
31
|
-
"include": [
|
|
32
|
-
"src/**/*.ts",
|
|
33
|
-
"src/**/*.tsx",
|
|
34
|
-
"src/**/*.vue"
|
|
35
|
-
],
|
|
36
|
-
"exclude": [
|
|
37
|
-
"node_modules",
|
|
38
|
-
"dist"
|
|
39
|
-
]
|
|
40
|
-
}
|