@duxweb/dvha-pro 0.0.6 → 0.0.7

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.
Files changed (121) hide show
  1. package/dist/cjs/component.cjs +1 -1
  2. package/dist/cjs/components/card/card.cjs +1 -1
  3. package/dist/cjs/components/chart/echart.cjs +1 -0
  4. package/dist/cjs/components/dialog/dialog.cjs +1 -1
  5. package/dist/cjs/components/drawer/drawer.cjs +1 -1
  6. package/dist/cjs/components/form/modalForm.cjs +1 -1
  7. package/dist/cjs/components/form/pageForm.cjs +1 -1
  8. package/dist/cjs/components/form/settingForm.cjs +1 -1
  9. package/dist/cjs/components/layout/list.cjs +1 -1
  10. package/dist/cjs/components/layout/table.cjs +1 -1
  11. package/dist/cjs/components/list/card.cjs +1 -1
  12. package/dist/cjs/components/list/list.cjs +1 -1
  13. package/dist/cjs/components/modal/modal.cjs +1 -1
  14. package/dist/cjs/components/modal/modalPage.cjs +1 -1
  15. package/dist/cjs/components/modal/modalTab.cjs +1 -1
  16. package/dist/cjs/components/select/cardSelect.cjs +1 -0
  17. package/dist/cjs/components/table/tablePage.cjs +1 -1
  18. package/dist/cjs/config/echart.cjs +1 -0
  19. package/dist/cjs/dvha-pro.css +1 -1
  20. package/dist/cjs/hooks/action.cjs +1 -1
  21. package/dist/cjs/hooks/dialog.cjs +1 -1
  22. package/dist/cjs/hooks/drawer.cjs +1 -1
  23. package/dist/cjs/hooks/echart.cjs +1 -0
  24. package/dist/cjs/hooks/modal.cjs +1 -1
  25. package/dist/cjs/hooks/table/media.cjs +1 -1
  26. package/dist/cjs/index.cjs +1 -1
  27. package/dist/cjs/main.cjs +1 -1
  28. package/dist/cjs/pages/authLayout.cjs +1 -1
  29. package/dist/cjs/pages/layout/global.cjs +1 -1
  30. package/dist/cjs/pages/layout/page.cjs +1 -1
  31. package/dist/cjs/pages/login.cjs +1 -1
  32. package/dist/cjs/pages/menu/avatar.cjs +1 -1
  33. package/dist/cjs/pages/menu/button.cjs +1 -1
  34. package/dist/cjs/pages/menu/cmd.cjs +1 -1
  35. package/dist/cjs/pages/menu/main.cjs +1 -1
  36. package/dist/cjs/pages/menu/mobile.cjs +1 -1
  37. package/dist/cjs/pages/page.cjs +1 -1
  38. package/dist/cjs/pages/page404.cjs +1 -1
  39. package/dist/cjs/pages/pageStatus.cjs +1 -1
  40. package/dist/cjs/theme/naiveTheme.cjs +1 -1
  41. package/dist/cjs/theme/uno.css.cjs +28 -7
  42. package/dist/esm/component.js +43 -41
  43. package/dist/esm/components/card/card.js +1 -1
  44. package/dist/esm/components/chart/echart.js +75 -0
  45. package/dist/esm/components/dialog/dialog.js +87 -93
  46. package/dist/esm/components/drawer/drawer.js +34 -32
  47. package/dist/esm/components/form/modalForm.js +1 -1
  48. package/dist/esm/components/form/pageForm.js +23 -19
  49. package/dist/esm/components/form/settingForm.js +22 -18
  50. package/dist/esm/components/layout/list.js +203 -142
  51. package/dist/esm/components/layout/table.js +210 -145
  52. package/dist/esm/components/list/card.js +42 -32
  53. package/dist/esm/components/list/list.js +27 -16
  54. package/dist/esm/components/modal/modal.js +46 -86
  55. package/dist/esm/components/modal/modalPage.js +23 -18
  56. package/dist/esm/components/modal/modalTab.js +11 -11
  57. package/dist/esm/components/select/cardSelect.js +103 -0
  58. package/dist/esm/components/table/tablePage.js +21 -18
  59. package/dist/esm/config/echart.js +456 -0
  60. package/dist/esm/dvha-pro.css +1 -1
  61. package/dist/esm/hooks/action.js +46 -45
  62. package/dist/esm/hooks/dialog.js +24 -7
  63. package/dist/esm/hooks/drawer.js +12 -8
  64. package/dist/esm/hooks/echart.js +469 -0
  65. package/dist/esm/hooks/modal.js +25 -9
  66. package/dist/esm/hooks/table/media.js +18 -14
  67. package/dist/esm/index.js +158 -135
  68. package/dist/esm/main.js +11 -8
  69. package/dist/esm/pages/authLayout.js +3 -2
  70. package/dist/esm/pages/layout/global.js +46 -33
  71. package/dist/esm/pages/layout/page.js +13 -9
  72. package/dist/esm/pages/login.js +25 -21
  73. package/dist/esm/pages/menu/avatar.js +14 -14
  74. package/dist/esm/pages/menu/button.js +14 -10
  75. package/dist/esm/pages/menu/cmd.js +26 -22
  76. package/dist/esm/pages/menu/main.js +26 -22
  77. package/dist/esm/pages/menu/mobile.js +11 -7
  78. package/dist/esm/pages/page.js +16 -16
  79. package/dist/esm/pages/page404.js +24 -20
  80. package/dist/esm/pages/pageStatus.js +12 -8
  81. package/dist/esm/theme/naiveTheme.js +57 -51
  82. package/dist/esm/theme/uno.css.js +28 -7
  83. package/dist/types/components/chart/echart.d.ts +284 -0
  84. package/dist/types/components/chart/index.d.ts +1 -0
  85. package/dist/types/components/dialog/dialog.d.ts +1 -20
  86. package/dist/types/components/drawer/drawer.d.ts +14 -4
  87. package/dist/types/components/form/formLayout.d.ts +1 -1
  88. package/dist/types/components/form/modalForm.d.ts +1 -1
  89. package/dist/types/components/index.d.ts +3 -0
  90. package/dist/types/components/layout/list.d.ts +18 -0
  91. package/dist/types/components/layout/table.d.ts +22 -1
  92. package/dist/types/components/list/card.d.ts +38 -0
  93. package/dist/types/components/list/list.d.ts +43 -2
  94. package/dist/types/components/modal/modal.d.ts +13 -31
  95. package/dist/types/components/modal/modalPage.d.ts +3 -6
  96. package/dist/types/components/panel/alert.d.ts +1 -1
  97. package/dist/types/components/select/cardSelect.d.ts +88 -0
  98. package/dist/types/components/select/index.d.ts +1 -0
  99. package/dist/types/components/table/tablePage.d.ts +28 -2
  100. package/dist/types/config/echart.d.ts +4 -0
  101. package/dist/types/config/index.d.ts +1 -0
  102. package/dist/types/hooks/drawer.d.ts +3 -2
  103. package/dist/types/hooks/echart.d.ts +166 -0
  104. package/dist/types/hooks/index.d.ts +2 -0
  105. package/dist/types/hooks/modal.d.ts +10 -5
  106. package/dist/types/hooks/table/types.d.ts +1 -0
  107. package/dist/types/main.d.ts +1 -0
  108. package/dist/types/pages/layout/global.d.ts +1 -0
  109. package/dist/types/pages/menu/avatar.d.ts +3 -3
  110. package/dist/types/pages/menu/button.d.ts +3 -3
  111. package/dist/types/pages/menu/main.d.ts +3 -3
  112. package/dist/types/pages/page.d.ts +1 -1
  113. package/package.json +8 -3
  114. package/dist/cjs/node_modules/.pnpm/@vueuse_integrations@13.3.0_async-validator@4.2.5_axios@1.10.0_focus-trap@7.6.5_vue@3.5.17_typescript@5.8.3_/node_modules/@vueuse/integrations/useFocusTrap.cjs +0 -1
  115. package/dist/cjs/node_modules/.pnpm/@vueuse_shared@13.3.0_vue@3.5.17_typescript@5.8.3_/node_modules/@vueuse/shared/index.cjs +0 -1
  116. package/dist/cjs/node_modules/.pnpm/focus-trap@7.6.5/node_modules/focus-trap/dist/focus-trap.esm.cjs +0 -5
  117. package/dist/cjs/node_modules/.pnpm/tabbable@6.2.0/node_modules/tabbable/dist/index.esm.cjs +0 -4
  118. package/dist/esm/node_modules/.pnpm/@vueuse_integrations@13.3.0_async-validator@4.2.5_axios@1.10.0_focus-trap@7.6.5_vue@3.5.17_typescript@5.8.3_/node_modules/@vueuse/integrations/useFocusTrap.js +0 -43
  119. package/dist/esm/node_modules/.pnpm/@vueuse_shared@13.3.0_vue@3.5.17_typescript@5.8.3_/node_modules/@vueuse/shared/index.js +0 -6
  120. package/dist/esm/node_modules/.pnpm/focus-trap@7.6.5/node_modules/focus-trap/dist/focus-trap.esm.js +0 -473
  121. package/dist/esm/node_modules/.pnpm/tabbable@6.2.0/node_modules/tabbable/dist/index.esm.js +0 -202
@@ -0,0 +1,166 @@
1
+ import type { EChartsOption } from 'echarts';
2
+ export interface EchartCommonProps {
3
+ min?: boolean;
4
+ }
5
+ /**
6
+ * 通用图表配置
7
+ */
8
+ export declare function useEchartCommon(props?: EchartCommonProps): EChartsOption;
9
+ export interface EchartDataItem {
10
+ name: string;
11
+ value: number;
12
+ }
13
+ export interface EchartSeriesItem {
14
+ name: string;
15
+ data: number[];
16
+ stack?: string;
17
+ }
18
+ export interface EchartAxisProps extends EchartCommonProps {
19
+ /** X轴标签 */
20
+ labels?: string[];
21
+ /** 自动判断单/多系列数据 */
22
+ data?: EchartDataItem[] | EchartSeriesItem[] | number[];
23
+ /** 单系列图表的名称 */
24
+ name?: string;
25
+ }
26
+ export interface EchartBarProps extends EchartAxisProps {
27
+ /** 是否为水平柱状图 */
28
+ horizontal?: boolean;
29
+ /** 堆叠分组 */
30
+ stack?: string;
31
+ }
32
+ /**
33
+ * 柱状图
34
+ */
35
+ export declare function useEchartBar(props?: EchartBarProps): {
36
+ option: import("vue").ComputedRef<EChartsOption>;
37
+ };
38
+ export interface EchartLineProps extends EchartAxisProps {
39
+ /** 是否平滑曲线 */
40
+ smooth?: boolean;
41
+ /** 堆叠分组 */
42
+ stack?: string;
43
+ }
44
+ /**
45
+ * 折线图
46
+ */
47
+ export declare function useEchartLine(props?: EchartLineProps): {
48
+ option: import("vue").ComputedRef<EChartsOption>;
49
+ };
50
+ export interface EchartPieProps extends EchartCommonProps {
51
+ data?: EchartDataItem[];
52
+ }
53
+ export declare function useEchartPie(props?: EchartPieProps): {
54
+ option: import("vue").ComputedRef<EChartsOption>;
55
+ legendData: import("vue").Ref<{
56
+ name: string;
57
+ value: number;
58
+ status: boolean;
59
+ }[], (EchartDataItem & {
60
+ status: boolean;
61
+ })[] | {
62
+ name: string;
63
+ value: number;
64
+ status: boolean;
65
+ }[]>;
66
+ };
67
+ export interface EchartRingProps extends EchartPieProps {
68
+ /** 环形图中心标签 */
69
+ ringLabel?: string;
70
+ }
71
+ /**
72
+ * 环形图
73
+ */
74
+ export declare function useEchartRing(props?: EchartRingProps): {
75
+ option: import("vue").ComputedRef<EChartsOption>;
76
+ legendData: import("vue").Ref<{
77
+ name: string;
78
+ value: number;
79
+ status: boolean;
80
+ }[], (EchartDataItem & {
81
+ status: boolean;
82
+ })[] | {
83
+ name: string;
84
+ value: number;
85
+ status: boolean;
86
+ }[]>;
87
+ };
88
+ export declare function useEchartRose(props?: EchartPieProps): {
89
+ option: import("vue").ComputedRef<EChartsOption>;
90
+ legendData: import("vue").Ref<{
91
+ name: string;
92
+ value: number;
93
+ status: boolean;
94
+ }[], (EchartDataItem & {
95
+ status: boolean;
96
+ })[] | {
97
+ name: string;
98
+ value: number;
99
+ status: boolean;
100
+ }[]>;
101
+ };
102
+ export declare function useEchartFunnel(props?: EchartPieProps): {
103
+ option: import("vue").ComputedRef<EChartsOption>;
104
+ legendData: import("vue").Ref<{
105
+ name: string;
106
+ value: number;
107
+ status: boolean;
108
+ }[], (EchartDataItem & {
109
+ status: boolean;
110
+ })[] | {
111
+ name: string;
112
+ value: number;
113
+ status: boolean;
114
+ }[]>;
115
+ };
116
+ export interface EchartRadarDataItem {
117
+ name: string;
118
+ value: number[];
119
+ }
120
+ export interface EchartRadarProps extends EchartCommonProps {
121
+ /** 雷达图指标配置 */
122
+ indicator?: Array<{
123
+ name: string;
124
+ max: number;
125
+ }>;
126
+ data?: EchartRadarDataItem[];
127
+ }
128
+ /**
129
+ * 雷达图
130
+ */
131
+ export declare function useEchartRadar(props?: EchartRadarProps): {
132
+ option: import("vue").ComputedRef<EChartsOption>;
133
+ };
134
+ export interface EchartMapProps extends EchartCommonProps {
135
+ /** 地图名称 */
136
+ mapName?: string;
137
+ data?: EchartDataItem[];
138
+ }
139
+ /**
140
+ * 地图
141
+ */
142
+ export declare function useEchartMap(props?: EchartMapProps): {
143
+ option: import("vue").ComputedRef<EChartsOption>;
144
+ };
145
+ export interface EchartTreeMapDataItem {
146
+ name: string;
147
+ value: number;
148
+ children?: EchartTreeMapDataItem[];
149
+ }
150
+ export interface EchartTreeMapProps extends EchartCommonProps {
151
+ data?: EchartTreeMapDataItem[] | EchartTreeMapDataItem[][];
152
+ /** 树状图名称,支持多个 */
153
+ name?: string | string[];
154
+ }
155
+ /**
156
+ * 矩形树图
157
+ */
158
+ export declare function useEchartTreeMap(props?: EchartTreeMapProps): {
159
+ option: import("vue").ComputedRef<EChartsOption>;
160
+ };
161
+ /**
162
+ * 通用图表类型选择器
163
+ */
164
+ export declare function useEchartType(type: string, props: any): {
165
+ option: import("vue").ComputedRef<EChartsOption>;
166
+ };
@@ -1,5 +1,7 @@
1
1
  export * from './action';
2
2
  export * from './dialog';
3
+ export * from './drawer';
4
+ export * from './echart';
3
5
  export * from './modal';
4
6
  export * from './table';
5
7
  export * from './table/index';
@@ -1,9 +1,14 @@
1
- import type { UseOverlayProps } from '@duxweb/dvha-core';
2
- export interface UseModalProps extends UseOverlayProps {
1
+ import type { ModalProps } from 'naive-ui';
2
+ import type { AsyncComponentLoader, Component } from 'vue';
3
+ export interface UseModalResult {
4
+ show: (props: UseModalProps) => Promise<any>;
5
+ }
6
+ export interface UseModalProps {
3
7
  title?: string;
4
8
  width?: number | string;
9
+ component: AsyncComponentLoader<any> | Component;
10
+ componentProps?: Record<string, any>;
5
11
  draggable?: boolean;
12
+ modalProps?: ModalProps;
6
13
  }
7
- export declare function useModal(): {
8
- show: (props: UseModalProps) => any;
9
- };
14
+ export declare function useModal(): UseModalResult;
@@ -12,6 +12,7 @@ export interface ModalActionItem extends BaseActionItem {
12
12
  component: AsyncComponentLoader<any>;
13
13
  componentProps?: Record<string, any> | ((data: any) => Record<string, any>);
14
14
  width?: number;
15
+ draggable?: boolean;
15
16
  }
16
17
  export interface DrawerActionItem extends BaseActionItem {
17
18
  type: 'drawer';
@@ -1,4 +1,5 @@
1
1
  import type { App } from 'vue';
2
+ import 'echarts';
2
3
  import './theme/style.scss';
3
4
  export declare function createDuxPro(): {
4
5
  install(app: App): void;
@@ -1 +1,2 @@
1
+ import 'echarts';
1
2
  export declare const DuxGlobalLayout: import("vue").DefineComponent<{}, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
@@ -1,14 +1,14 @@
1
1
  declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
2
- open: {
2
+ collapsed: {
3
3
  type: BooleanConstructor;
4
4
  default: boolean;
5
5
  };
6
6
  }>, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
7
- open: {
7
+ collapsed: {
8
8
  type: BooleanConstructor;
9
9
  default: boolean;
10
10
  };
11
11
  }>> & Readonly<{}>, {
12
- open: boolean;
12
+ collapsed: boolean;
13
13
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
14
14
  export default _default;
@@ -7,7 +7,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
7
7
  type: FunctionConstructor;
8
8
  default: () => void;
9
9
  };
10
- open: {
10
+ collapsed: {
11
11
  type: BooleanConstructor;
12
12
  default: boolean;
13
13
  };
@@ -24,7 +24,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
24
24
  type: FunctionConstructor;
25
25
  default: () => void;
26
26
  };
27
- open: {
27
+ collapsed: {
28
28
  type: BooleanConstructor;
29
29
  default: boolean;
30
30
  };
@@ -36,6 +36,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
36
36
  onClick: Function;
37
37
  class: string;
38
38
  inverted: boolean;
39
- open: boolean;
39
+ collapsed: boolean;
40
40
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
41
41
  export default _default;
@@ -1,13 +1,13 @@
1
1
  export declare const DuxMenuMain: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
2
- open: {
2
+ collapsed: {
3
3
  type: BooleanConstructor;
4
4
  default: boolean;
5
5
  };
6
6
  }>, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
7
- open: {
7
+ collapsed: {
8
8
  type: BooleanConstructor;
9
9
  default: boolean;
10
10
  };
11
11
  }>> & Readonly<{}>, {
12
- open: boolean;
12
+ collapsed: boolean;
13
13
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
@@ -35,8 +35,8 @@ export declare const DuxPage: import("vue").DefineComponent<import("vue").Extrac
35
35
  default: boolean;
36
36
  };
37
37
  }>> & Readonly<{}>, {
38
- card: boolean;
39
38
  padding: boolean;
39
+ card: boolean;
40
40
  actions: UseActionItem[];
41
41
  scrollbar: boolean;
42
42
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@duxweb/dvha-pro",
3
3
  "type": "module",
4
- "version": "0.0.6",
4
+ "version": "0.0.7",
5
5
  "author": "DuxWeb",
6
6
  "license": "MIT",
7
7
  "repository": {
@@ -32,8 +32,9 @@
32
32
  "dist"
33
33
  ],
34
34
  "dependencies": {
35
- "@duxweb/dvha-core": "^0.1.22",
36
- "@duxweb/dvha-naiveui": "^1.0.11",
35
+ "@ant-design/colors": "^7.2.1",
36
+ "@duxweb/dvha-core": "^0.1.23",
37
+ "@duxweb/dvha-naiveui": "^1.0.12",
37
38
  "@iconify-json/tabler": "^1.2.18",
38
39
  "@overlastic/vue": "^0.8.1",
39
40
  "@unocss/preset-icons": "^66.2.1",
@@ -45,17 +46,21 @@
45
46
  "@vueuse/integrations": "^13.3.0",
46
47
  "clsx": "^2.1.1",
47
48
  "colorizr": "^3.0.8",
49
+ "echarts": "^5.6.0",
48
50
  "jinrishici": "^1.0.6",
49
51
  "jsep": "^1.4.0",
50
52
  "lodash-es": "^4.17.21",
53
+ "mathjs": "^14.5.2",
51
54
  "naive-ui": "^2.42.0",
52
55
  "pinia": "^3.0.3",
53
56
  "pinia-plugin-persistedstate": "^4.3.0",
54
57
  "sass-embedded": "^1.89.1",
58
+ "tslib": "^2.8.1",
55
59
  "unocss": "^66.2.1",
56
60
  "vee-validate": "^4.15.1",
57
61
  "vue": "^3.5.0",
58
62
  "vue-command-palette": "^0.2.3",
63
+ "vue-echarts": "^7.0.3",
59
64
  "vue-router": "^4.5.1"
60
65
  },
61
66
  "devDependencies": {
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("@vueuse/core"),g=require("../../../../@vueuse_shared@13.3.0_vue@3.5.17_typescript@5.8.3_/node_modules/@vueuse/shared/index.cjs"),T=require("../../../../focus-trap@7.6.5/node_modules/focus-trap/dist/focus-trap.esm.cjs"),a=require("vue");function y(l,s={}){let e;const{immediate:f,...v}=s,u=a.shallowRef(!1),c=a.shallowRef(!1),n=t=>e&&e.activate(t),i=t=>e&&e.deactivate(t),p=()=>{e&&(e.pause(),c.value=!0)},d=()=>{e&&(e.unpause(),c.value=!1)},h=a.computed(()=>{const t=a.toValue(l);return o.toArray(t).map(m=>{const r=a.toValue(m);return typeof r=="string"?r:o.unrefElement(r)}).filter(g.notNullish)});return a.watch(h,t=>{t.length&&(e=T.createFocusTrap(t,{...v,onActivate(){u.value=!0,s.onActivate&&s.onActivate()},onDeactivate(){u.value=!1,s.onDeactivate&&s.onDeactivate()}}),f&&n())},{flush:"post"}),o.tryOnScopeDispose(()=>i()),{hasFocus:u,isPaused:c,activate:n,deactivate:i,pause:p,unpause:d}}exports.useFocusTrap=y;
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("vue");typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const o=e=>e!=null;exports.notNullish=o;
@@ -1,5 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const m=require("../../../../tabbable@6.2.0/node_modules/tabbable/dist/index.esm.cjs");/*!
2
- * focus-trap 7.6.5
3
- * @license MIT, https://github.com/focus-trap/focus-trap/blob/master/LICENSE
4
- */function _(r,t){(t==null||t>r.length)&&(t=r.length);for(var o=0,u=Array(t);o<t;o++)u[o]=r[o];return u}function ee(r){if(Array.isArray(r))return _(r)}function te(r,t,o){return(t=oe(t))in r?Object.defineProperty(r,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):r[t]=o,r}function ae(r){if(typeof Symbol<"u"&&r[Symbol.iterator]!=null||r["@@iterator"]!=null)return Array.from(r)}function ne(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
5
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function z(r,t){var o=Object.keys(r);if(Object.getOwnPropertySymbols){var u=Object.getOwnPropertySymbols(r);t&&(u=u.filter(function(y){return Object.getOwnPropertyDescriptor(r,y).enumerable})),o.push.apply(o,u)}return o}function J(r){for(var t=1;t<arguments.length;t++){var o=arguments[t]!=null?arguments[t]:{};t%2?z(Object(o),!0).forEach(function(u){te(r,u,o[u])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(o)):z(Object(o)).forEach(function(u){Object.defineProperty(r,u,Object.getOwnPropertyDescriptor(o,u))})}return r}function re(r){return ee(r)||ae(r)||ue(r)||ne()}function ie(r,t){if(typeof r!="object"||!r)return r;var o=r[Symbol.toPrimitive];if(o!==void 0){var u=o.call(r,t);if(typeof u!="object")return u;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(r)}function oe(r){var t=ie(r,"string");return typeof t=="symbol"?t:t+""}function ue(r,t){if(r){if(typeof r=="string")return _(r,t);var o={}.toString.call(r).slice(8,-1);return o==="Object"&&r.constructor&&(o=r.constructor.name),o==="Map"||o==="Set"?Array.from(r):o==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o)?_(r,t):void 0}}var Q={activateTrap:function(t,o){if(t.length>0){var u=t[t.length-1];u!==o&&u._setPausedState(!0)}var y=t.indexOf(o);y===-1||t.splice(y,1),t.push(o)},deactivateTrap:function(t,o){var u=t.indexOf(o);u!==-1&&t.splice(u,1),t.length>0&&!t[t.length-1]._isManuallyPaused()&&t[t.length-1]._setPausedState(!1)}},se=function(t){return t.tagName&&t.tagName.toLowerCase()==="input"&&typeof t.select=="function"},ce=function(t){return(t==null?void 0:t.key)==="Escape"||(t==null?void 0:t.key)==="Esc"||(t==null?void 0:t.keyCode)===27},K=function(t){return(t==null?void 0:t.key)==="Tab"||(t==null?void 0:t.keyCode)===9},le=function(t){return K(t)&&!t.shiftKey},fe=function(t){return K(t)&&t.shiftKey},X=function(t){return setTimeout(t,0)},R=function(t){for(var o=arguments.length,u=new Array(o>1?o-1:0),y=1;y<o;y++)u[y-1]=arguments[y];return typeof t=="function"?t.apply(void 0,u):t},j=function(t){return t.target.shadowRoot&&typeof t.composedPath=="function"?t.composedPath()[0]:t.target},de=[],ve=function(t,o){var u=(o==null?void 0:o.document)||document,y=(o==null?void 0:o.trapStack)||de,f=J({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0,isKeyForward:le,isKeyBackward:fe},o),n={containers:[],containerGroups:[],tabbableGroups:[],nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1,manuallyPaused:!1,delayInitialFocusTimer:void 0,recentNavEvent:void 0},g,h=function(e,a,i){return e&&e[a]!==void 0?e[a]:f[i||a]},N=function(e,a){var i=typeof(a==null?void 0:a.composedPath)=="function"?a.composedPath():void 0;return n.containerGroups.findIndex(function(c){var l=c.container,v=c.tabbableNodes;return l.contains(e)||(i==null?void 0:i.includes(l))||v.find(function(s){return s===e})})},k=function(e){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=a.hasFallback,c=i===void 0?!1:i,l=a.params,v=l===void 0?[]:l,s=f[e];if(typeof s=="function"&&(s=s.apply(void 0,re(v))),s===!0&&(s=void 0),!s){if(s===void 0||s===!1)return s;throw new Error("`".concat(e,"` was specified but was not a node, or did not return a node"))}var b=s;if(typeof s=="string"){try{b=u.querySelector(s)}catch(p){throw new Error("`".concat(e,'` appears to be an invalid selector; error="').concat(p.message,'"'))}if(!b&&!c)throw new Error("`".concat(e,"` as selector refers to no known node"))}return b},E=function(){var e=k("initialFocus",{hasFallback:!0});if(e===!1)return!1;if(e===void 0||e&&!m.isFocusable(e,f.tabbableOptions))if(N(u.activeElement)>=0)e=u.activeElement;else{var a=n.tabbableGroups[0],i=a&&a.firstTabbableNode;e=i||k("fallbackFocus")}else e===null&&(e=k("fallbackFocus"));if(!e)throw new Error("Your focus-trap needs to have at least one focusable element");return e},P=function(){if(n.containerGroups=n.containers.map(function(e){var a=m.tabbable(e,f.tabbableOptions),i=m.focusable(e,f.tabbableOptions),c=a.length>0?a[0]:void 0,l=a.length>0?a[a.length-1]:void 0,v=i.find(function(p){return m.isTabbable(p)}),s=i.slice().reverse().find(function(p){return m.isTabbable(p)}),b=!!a.find(function(p){return m.getTabIndex(p)>0});return{container:e,tabbableNodes:a,focusableNodes:i,posTabIndexesFound:b,firstTabbableNode:c,lastTabbableNode:l,firstDomTabbableNode:v,lastDomTabbableNode:s,nextTabbableNode:function(T){var O=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,F=a.indexOf(T);return F<0?O?i.slice(i.indexOf(T)+1).find(function(A){return m.isTabbable(A)}):i.slice(0,i.indexOf(T)).reverse().find(function(A){return m.isTabbable(A)}):a[F+(O?1:-1)]}}}),n.tabbableGroups=n.containerGroups.filter(function(e){return e.tabbableNodes.length>0}),n.tabbableGroups.length<=0&&!k("fallbackFocus"))throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times");if(n.containerGroups.find(function(e){return e.posTabIndexesFound})&&n.containerGroups.length>1)throw new Error("At least one node with a positive tabindex was found in one of your focus-trap's multiple containers. Positive tabindexes are only supported in single-container focus-traps.")},L=function(e){var a=e.activeElement;if(a)return a.shadowRoot&&a.shadowRoot.activeElement!==null?L(a.shadowRoot):a},w=function(e){if(e!==!1&&e!==L(document)){if(!e||!e.focus){w(E());return}e.focus({preventScroll:!!f.preventScroll}),n.mostRecentlyFocusedNode=e,se(e)&&e.select()}},x=function(e){var a=k("setReturnFocus",{params:[e]});return a||(a===!1?!1:e)},G=function(e){var a=e.target,i=e.event,c=e.isBackward,l=c===void 0?!1:c;a=a||j(i),P();var v=null;if(n.tabbableGroups.length>0){var s=N(a,i),b=s>=0?n.containerGroups[s]:void 0;if(s<0)l?v=n.tabbableGroups[n.tabbableGroups.length-1].lastTabbableNode:v=n.tabbableGroups[0].firstTabbableNode;else if(l){var p=n.tabbableGroups.findIndex(function(C){var S=C.firstTabbableNode;return a===S});if(p<0&&(b.container===a||m.isFocusable(a,f.tabbableOptions)&&!m.isTabbable(a,f.tabbableOptions)&&!b.nextTabbableNode(a,!1))&&(p=s),p>=0){var T=p===0?n.tabbableGroups.length-1:p-1,O=n.tabbableGroups[T];v=m.getTabIndex(a)>=0?O.lastTabbableNode:O.lastDomTabbableNode}else K(i)||(v=b.nextTabbableNode(a,!1))}else{var F=n.tabbableGroups.findIndex(function(C){var S=C.lastTabbableNode;return a===S});if(F<0&&(b.container===a||m.isFocusable(a,f.tabbableOptions)&&!m.isTabbable(a,f.tabbableOptions)&&!b.nextTabbableNode(a))&&(F=s),F>=0){var A=F===n.tabbableGroups.length-1?0:F+1,W=n.tabbableGroups[A];v=m.getTabIndex(a)>=0?W.firstTabbableNode:W.firstDomTabbableNode}else K(i)||(v=b.nextTabbableNode(a))}}else v=k("fallbackFocus");return v},I=function(e){var a=j(e);if(!(N(a,e)>=0)){if(R(f.clickOutsideDeactivates,e)){g.deactivate({returnFocus:f.returnFocusOnDeactivate});return}R(f.allowOutsideClick,e)||e.preventDefault()}},M=function(e){var a=j(e),i=N(a,e)>=0;if(i||a instanceof Document)i&&(n.mostRecentlyFocusedNode=a);else{e.stopImmediatePropagation();var c,l=!0;if(n.mostRecentlyFocusedNode)if(m.getTabIndex(n.mostRecentlyFocusedNode)>0){var v=N(n.mostRecentlyFocusedNode),s=n.containerGroups[v].tabbableNodes;if(s.length>0){var b=s.findIndex(function(p){return p===n.mostRecentlyFocusedNode});b>=0&&(f.isKeyForward(n.recentNavEvent)?b+1<s.length&&(c=s[b+1],l=!1):b-1>=0&&(c=s[b-1],l=!1))}}else n.containerGroups.some(function(p){return p.tabbableNodes.some(function(T){return m.getTabIndex(T)>0})})||(l=!1);else l=!1;l&&(c=G({target:n.mostRecentlyFocusedNode,isBackward:f.isKeyBackward(n.recentNavEvent)})),w(c||n.mostRecentlyFocusedNode||E())}n.recentNavEvent=void 0},Z=function(e){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;n.recentNavEvent=e;var i=G({event:e,isBackward:a});i&&(K(e)&&e.preventDefault(),w(i))},$=function(e){(f.isKeyForward(e)||f.isKeyBackward(e))&&Z(e,f.isKeyBackward(e))},q=function(e){ce(e)&&R(f.escapeDeactivates,e)!==!1&&(e.preventDefault(),g.deactivate())},H=function(e){var a=j(e);N(a,e)>=0||R(f.clickOutsideDeactivates,e)||R(f.allowOutsideClick,e)||(e.preventDefault(),e.stopImmediatePropagation())},Y=function(){if(n.active)return Q.activateTrap(y,g),n.delayInitialFocusTimer=f.delayInitialFocus?X(function(){w(E())}):w(E()),u.addEventListener("focusin",M,!0),u.addEventListener("mousedown",I,{capture:!0,passive:!1}),u.addEventListener("touchstart",I,{capture:!0,passive:!1}),u.addEventListener("click",H,{capture:!0,passive:!1}),u.addEventListener("keydown",$,{capture:!0,passive:!1}),u.addEventListener("keydown",q),g},V=function(){if(n.active)return u.removeEventListener("focusin",M,!0),u.removeEventListener("mousedown",I,!0),u.removeEventListener("touchstart",I,!0),u.removeEventListener("click",H,!0),u.removeEventListener("keydown",$,!0),u.removeEventListener("keydown",q),g},U=function(e){var a=e.some(function(i){var c=Array.from(i.removedNodes);return c.some(function(l){return l===n.mostRecentlyFocusedNode})});a&&w(E())},B=typeof window<"u"&&"MutationObserver"in window?new MutationObserver(U):void 0,D=function(){B&&(B.disconnect(),n.active&&!n.paused&&n.containers.map(function(e){B.observe(e,{subtree:!0,childList:!0})}))};return g={get active(){return n.active},get paused(){return n.paused},activate:function(e){if(n.active)return this;var a=h(e,"onActivate"),i=h(e,"onPostActivate"),c=h(e,"checkCanFocusTrap");c||P(),n.active=!0,n.paused=!1,n.nodeFocusedBeforeActivation=L(u),a==null||a();var l=function(){c&&P(),Y(),D(),i==null||i()};return c?(c(n.containers.concat()).then(l,l),this):(l(),this)},deactivate:function(e){if(!n.active)return this;var a=J({onDeactivate:f.onDeactivate,onPostDeactivate:f.onPostDeactivate,checkCanReturnFocus:f.checkCanReturnFocus},e);clearTimeout(n.delayInitialFocusTimer),n.delayInitialFocusTimer=void 0,V(),n.active=!1,n.paused=!1,D(),Q.deactivateTrap(y,g);var i=h(a,"onDeactivate"),c=h(a,"onPostDeactivate"),l=h(a,"checkCanReturnFocus"),v=h(a,"returnFocus","returnFocusOnDeactivate");i==null||i();var s=function(){X(function(){v&&w(x(n.nodeFocusedBeforeActivation)),c==null||c()})};return v&&l?(l(x(n.nodeFocusedBeforeActivation)).then(s,s),this):(s(),this)},pause:function(e){return n.active?(n.manuallyPaused=!0,this._setPausedState(!0,e)):this},unpause:function(e){return n.active?(n.manuallyPaused=!1,y[y.length-1]!==this?this:this._setPausedState(!1,e)):this},updateContainerElements:function(e){var a=[].concat(e).filter(Boolean);return n.containers=a.map(function(i){return typeof i=="string"?u.querySelector(i):i}),n.active&&P(),D(),this}},Object.defineProperties(g,{_isManuallyPaused:{value:function(){return n.manuallyPaused}},_setPausedState:{value:function(e,a){if(n.paused===e)return this;if(n.paused=e,e){var i=h(a,"onPause"),c=h(a,"onPostPause");i==null||i(),V(),D(),c==null||c()}else{var l=h(a,"onUnpause"),v=h(a,"onPostUnpause");l==null||l(),P(),Y(),D(),v==null||v()}return this}}}),g.updateContainerElements(t),g};exports.createFocusTrap=ve;
@@ -1,4 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});/*!
2
- * tabbable 6.2.0
3
- * @license MIT, https://github.com/focus-trap/tabbable/blob/master/LICENSE
4
- */var w=["input:not([inert])","select:not([inert])","textarea:not([inert])","a[href]:not([inert])","button:not([inert])","[tabindex]:not(slot):not([inert])","audio[controls]:not([inert])","video[controls]:not([inert])",'[contenteditable]:not([contenteditable="false"]):not([inert])',"details>summary:first-of-type:not([inert])","details:not([inert])"],v=w.join(","),I=typeof Element>"u",o=I?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,b=!I&&Element.prototype.getRootNode?function(i){var t;return i==null||(t=i.getRootNode)===null||t===void 0?void 0:t.call(i)}:function(i){return i==null?void 0:i.ownerDocument},h=function i(t,e){var r;e===void 0&&(e=!0);var a=t==null||(r=t.getAttribute)===null||r===void 0?void 0:r.call(t,"inert"),l=a===""||a==="true",n=l||e&&t&&i(t.parentNode);return n},A=function(t){var e,r=t==null||(e=t.getAttribute)===null||e===void 0?void 0:e.call(t,"contenteditable");return r===""||r==="true"},m=function(t,e,r){if(h(t))return[];var a=Array.prototype.slice.apply(t.querySelectorAll(v));return e&&o.call(t,v)&&a.unshift(t),a=a.filter(r),a},N=function i(t,e,r){for(var a=[],l=Array.from(t);l.length;){var n=l.shift();if(!h(n,!1))if(n.tagName==="SLOT"){var u=n.assignedElements(),c=u.length?u:n.children,s=i(c,!0,r);r.flatten?a.push.apply(a,s):a.push({scopeParent:n,candidates:s})}else{var f=o.call(n,v);f&&r.filter(n)&&(e||!t.includes(n))&&a.push(n);var d=n.shadowRoot||typeof r.getShadowRoot=="function"&&r.getShadowRoot(n),E=!h(d,!1)&&(!r.shadowRootFilter||r.shadowRootFilter(n));if(d&&E){var p=i(d===!0?n.children:d.children,!0,r);r.flatten?a.push.apply(a,p):a.push({scopeParent:n,candidates:p})}else l.unshift.apply(l,n.children)}}return a},R=function(t){return!isNaN(parseInt(t.getAttribute("tabindex"),10))},y=function(t){if(!t)throw new Error("No node provided");return t.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(t.tagName)||A(t))&&!R(t)?0:t.tabIndex},x=function(t,e){var r=y(t);return r<0&&e&&!R(t)?0:r},O=function(t,e){return t.tabIndex===e.tabIndex?t.documentOrder-e.documentOrder:t.tabIndex-e.tabIndex},C=function(t){return t.tagName==="INPUT"},F=function(t){return C(t)&&t.type==="hidden"},D=function(t){var e=t.tagName==="DETAILS"&&Array.prototype.slice.apply(t.children).some(function(r){return r.tagName==="SUMMARY"});return e},M=function(t,e){for(var r=0;r<t.length;r++)if(t[r].checked&&t[r].form===e)return t[r]},k=function(t){if(!t.name)return!0;var e=t.form||b(t),r=function(u){return e.querySelectorAll('input[type="radio"][name="'+u+'"]')},a;if(typeof window<"u"&&typeof window.CSS<"u"&&typeof window.CSS.escape=="function")a=r(window.CSS.escape(t.name));else try{a=r(t.name)}catch(n){return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",n.message),!1}var l=M(a,t.form);return!l||l===t},L=function(t){return C(t)&&t.type==="radio"},P=function(t){return L(t)&&!k(t)},B=function(t){var e,r=t&&b(t),a=(e=r)===null||e===void 0?void 0:e.host,l=!1;if(r&&r!==t){var n,u,c;for(l=!!((n=a)!==null&&n!==void 0&&(u=n.ownerDocument)!==null&&u!==void 0&&u.contains(a)||t!=null&&(c=t.ownerDocument)!==null&&c!==void 0&&c.contains(t));!l&&a;){var s,f,d;r=b(a),a=(s=r)===null||s===void 0?void 0:s.host,l=!!((f=a)!==null&&f!==void 0&&(d=f.ownerDocument)!==null&&d!==void 0&&d.contains(a))}}return l},T=function(t){var e=t.getBoundingClientRect(),r=e.width,a=e.height;return r===0&&a===0},q=function(t,e){var r=e.displayCheck,a=e.getShadowRoot;if(getComputedStyle(t).visibility==="hidden")return!0;var l=o.call(t,"details>summary:first-of-type"),n=l?t.parentElement:t;if(o.call(n,"details:not([open]) *"))return!0;if(!r||r==="full"||r==="legacy-full"){if(typeof a=="function"){for(var u=t;t;){var c=t.parentElement,s=b(t);if(c&&!c.shadowRoot&&a(c)===!0)return T(t);t.assignedSlot?t=t.assignedSlot:!c&&s!==t.ownerDocument?t=s.host:t=c}t=u}if(B(t))return!t.getClientRects().length;if(r!=="legacy-full")return!0}else if(r==="non-zero-area")return T(t);return!1},U=function(t){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(t.tagName))for(var e=t.parentElement;e;){if(e.tagName==="FIELDSET"&&e.disabled){for(var r=0;r<e.children.length;r++){var a=e.children.item(r);if(a.tagName==="LEGEND")return o.call(e,"fieldset[disabled] *")?!0:!a.contains(t)}return!0}e=e.parentElement}return!1},g=function(t,e){return!(e.disabled||h(e)||F(e)||q(e,t)||D(e)||U(e))},S=function(t,e){return!(P(e)||y(e)<0||!g(t,e))},V=function(t){var e=parseInt(t.getAttribute("tabindex"),10);return!!(isNaN(e)||e>=0)},j=function i(t){var e=[],r=[];return t.forEach(function(a,l){var n=!!a.scopeParent,u=n?a.scopeParent:a,c=x(u,n),s=n?i(a.candidates):u;c===0?n?e.push.apply(e,s):e.push(u):r.push({documentOrder:l,tabIndex:c,item:a,isScope:n,content:s})}),r.sort(O).reduce(function(a,l){return l.isScope?a.push.apply(a,l.content):a.push(l.content),a},[]).concat(e)},W=function(t,e){e=e||{};var r;return e.getShadowRoot?r=N([t],e.includeContainer,{filter:S.bind(null,e),flatten:!1,getShadowRoot:e.getShadowRoot,shadowRootFilter:V}):r=m(t,e.includeContainer,S.bind(null,e)),j(r)},Z=function(t,e){e=e||{};var r;return e.getShadowRoot?r=N([t],e.includeContainer,{filter:g.bind(null,e),flatten:!0,getShadowRoot:e.getShadowRoot}):r=m(t,e.includeContainer,g.bind(null,e)),r},z=function(t,e){if(e=e||{},!t)throw new Error("No node provided");return o.call(t,v)===!1?!1:S(e,t)},G=w.concat("iframe").join(","),X=function(t,e){if(e=e||{},!t)throw new Error("No node provided");return o.call(t,G)===!1?!1:g(e,t)};exports.focusable=Z;exports.getTabIndex=y;exports.isFocusable=X;exports.isTabbable=z;exports.tabbable=W;
@@ -1,43 +0,0 @@
1
- import { toArray as g, unrefElement as A, tryOnScopeDispose as D } from "@vueuse/core";
2
- import { notNullish as y } from "../../../../@vueuse_shared@13.3.0_vue@3.5.17_typescript@5.8.3_/node_modules/@vueuse/shared/index.js";
3
- import { createFocusTrap as F } from "../../../../focus-trap@7.6.5/node_modules/focus-trap/dist/focus-trap.esm.js";
4
- import { shallowRef as n, computed as T, toValue as i, watch as w } from "vue";
5
- function N(f, a = {}) {
6
- let t;
7
- const { immediate: l, ...p } = a, o = n(!1), r = n(!1), c = (e) => t && t.activate(e), u = (e) => t && t.deactivate(e), v = () => {
8
- t && (t.pause(), r.value = !0);
9
- }, m = () => {
10
- t && (t.unpause(), r.value = !1);
11
- }, h = T(() => {
12
- const e = i(f);
13
- return g(e).map((d) => {
14
- const s = i(d);
15
- return typeof s == "string" ? s : A(s);
16
- }).filter(y);
17
- });
18
- return w(
19
- h,
20
- (e) => {
21
- e.length && (t = F(e, {
22
- ...p,
23
- onActivate() {
24
- o.value = !0, a.onActivate && a.onActivate();
25
- },
26
- onDeactivate() {
27
- o.value = !1, a.onDeactivate && a.onDeactivate();
28
- }
29
- }), l && c());
30
- },
31
- { flush: "post" }
32
- ), D(() => u()), {
33
- hasFocus: o,
34
- isPaused: r,
35
- activate: c,
36
- deactivate: u,
37
- pause: v,
38
- unpause: m
39
- };
40
- }
41
- export {
42
- N as useFocusTrap
43
- };
@@ -1,6 +0,0 @@
1
- import "vue";
2
- typeof WorkerGlobalScope < "u" && globalThis instanceof WorkerGlobalScope;
3
- const e = (o) => o != null;
4
- export {
5
- e as notNullish
6
- };