@campus-admin/ui 1.0.0 → 2.0.1

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 (129) hide show
  1. package/README.md +138 -335
  2. package/dist/campus/card/index.d.ts +9 -0
  3. package/dist/campus/index.d.ts +7 -0
  4. package/dist/campus/parent/index.d.ts +9 -0
  5. package/dist/campus/student/index.d.ts +9 -0
  6. package/dist/campus/teacher/index.d.ts +9 -0
  7. package/dist/campus/tel/index.d.ts +9 -0
  8. package/dist/{base/empty/src/empty.vue.d.ts → components/basic/CaIcon.vue.d.ts} +4 -7
  9. package/dist/components/basic/CaPageActions.vue.d.ts +15 -0
  10. package/dist/components/basic/icons.d.ts +48 -0
  11. package/dist/components/basic/index.d.ts +838 -0
  12. package/dist/components/button/index.d.ts +348 -0
  13. package/dist/components/chart/bar-chart/CaBarChart.vue.d.ts +31 -0
  14. package/dist/components/chart/chart-math.d.ts +178 -0
  15. package/dist/components/chart/gauge/CaGauge.vue.d.ts +31 -0
  16. package/dist/components/chart/index.d.ts +195 -0
  17. package/dist/components/chart/line-chart/CaLineChart.vue.d.ts +40 -0
  18. package/dist/components/chart/parts/ChartLegend.vue.d.ts +28 -0
  19. package/dist/{atom/slogan/src/slogan.vue.d.ts → components/chart/parts/ChartStatus.vue.d.ts} +3 -5
  20. package/dist/components/chart/parts/ChartTable.vue.d.ts +19 -0
  21. package/dist/components/chart/parts/ChartTooltip.vue.d.ts +23 -0
  22. package/dist/components/chart/pie-chart/CaPieChart.vue.d.ts +25 -0
  23. package/dist/components/chart/sparkline/CaSparkline.vue.d.ts +20 -0
  24. package/dist/components/chart/use-chart.d.ts +36 -0
  25. package/dist/components/config/CaConfigProvider.vue.d.ts +16 -0
  26. package/dist/components/config/index.d.ts +33 -0
  27. package/dist/components/display/index.d.ts +99 -0
  28. package/dist/{base/copyright/src/copyright.vue.d.ts → components/display/stat-card/CaStatCard.vue.d.ts} +7 -11
  29. package/dist/{base/skeleton/src/skeleton.vue.d.ts → components/display/status-tag/CaStatusTag.vue.d.ts} +4 -7
  30. package/dist/components/display/types.d.ts +7 -0
  31. package/dist/components/form/index.d.ts +112 -0
  32. package/dist/components/form/schema-form/CaSchemaForm.vue.d.ts +31 -0
  33. package/dist/components/form/types.d.ts +17 -0
  34. package/dist/components/index.d.ts +22 -0
  35. package/dist/components/layout/index.d.ts +34 -0
  36. package/dist/components/navigation/CaMenu.vue.d.ts +13 -0
  37. package/dist/components/navigation/index.d.ts +64 -0
  38. package/dist/components/overlay/index.d.ts +1511 -0
  39. package/dist/components/table/data-table/CaDataTable.vue.d.ts +49 -0
  40. package/dist/components/table/index.d.ts +33 -0
  41. package/dist/components/table/types.d.ts +46 -0
  42. package/dist/index.d.ts +21 -1106
  43. package/dist/index.js +2187 -0
  44. package/dist/oms/index.d.ts +3 -0
  45. package/dist/oms/school/index.d.ts +10 -0
  46. package/dist/shared/inject.d.ts +8 -0
  47. package/dist/shared/registry.d.ts +5 -0
  48. package/dist/shared/types.d.ts +9 -0
  49. package/dist/shared/wrap.d.ts +7 -0
  50. package/dist/style.css +2 -0
  51. package/package.json +17 -49
  52. package/dist/atom/attendance-badge/index.d.ts +0 -5
  53. package/dist/atom/attendance-badge/src/attendance-badge.vue.d.ts +0 -13
  54. package/dist/atom/attendance-badge/src/core.d.ts +0 -11
  55. package/dist/atom/avatar/index.d.ts +0 -3
  56. package/dist/atom/avatar/src/avatar.vue.d.ts +0 -14
  57. package/dist/atom/button/index.d.ts +0 -3
  58. package/dist/atom/button/src/button.vue.d.ts +0 -40
  59. package/dist/atom/checkbox/index.d.ts +0 -3
  60. package/dist/atom/checkbox/src/checkbox.vue.d.ts +0 -24
  61. package/dist/atom/icon/index.d.ts +0 -3
  62. package/dist/atom/icon/src/icon.vue.d.ts +0 -27
  63. package/dist/atom/index.d.ts +0 -444
  64. package/dist/atom/input/index.d.ts +0 -3
  65. package/dist/atom/input/src/input.vue.d.ts +0 -43
  66. package/dist/atom/progress/index.d.ts +0 -4
  67. package/dist/atom/progress/src/core.d.ts +0 -9
  68. package/dist/atom/progress/src/progress.vue.d.ts +0 -19
  69. package/dist/atom/select/index.d.ts +0 -5
  70. package/dist/atom/select/src/core.d.ts +0 -9
  71. package/dist/atom/select/src/select.vue.d.ts +0 -22
  72. package/dist/atom/slogan/index.d.ts +0 -3
  73. package/dist/atom/switch/index.d.ts +0 -3
  74. package/dist/atom/switch/src/switch.vue.d.ts +0 -16
  75. package/dist/atom/tag/index.d.ts +0 -3
  76. package/dist/atom/tag/src/tag.vue.d.ts +0 -31
  77. package/dist/atom/textarea/index.d.ts +0 -3
  78. package/dist/atom/textarea/src/textarea.vue.d.ts +0 -19
  79. package/dist/base/breadcrumb/index.d.ts +0 -4
  80. package/dist/base/breadcrumb/src/breadcrumb.vue.d.ts +0 -29
  81. package/dist/base/class-tree/index.d.ts +0 -5
  82. package/dist/base/class-tree/src/class-tree.vue.d.ts +0 -29
  83. package/dist/base/class-tree/src/core.d.ts +0 -30
  84. package/dist/base/copyright/index.d.ts +0 -3
  85. package/dist/base/drawer/index.d.ts +0 -3
  86. package/dist/base/drawer/src/drawer.vue.d.ts +0 -36
  87. package/dist/base/empty/index.d.ts +0 -3
  88. package/dist/base/index.d.ts +0 -651
  89. package/dist/base/menu/core.d.ts +0 -34
  90. package/dist/base/menu/index.d.ts +0 -13
  91. package/dist/base/menu/side-menu/index.d.ts +0 -5
  92. package/dist/base/menu/side-menu/src/side-menu.vue.d.ts +0 -59
  93. package/dist/base/modal/index.d.ts +0 -4
  94. package/dist/base/modal/src/core.d.ts +0 -8
  95. package/dist/base/modal/src/modal.vue.d.ts +0 -46
  96. package/dist/base/page-header/index.d.ts +0 -3
  97. package/dist/base/page-header/src/page-header.vue.d.ts +0 -27
  98. package/dist/base/pagination/index.d.ts +0 -5
  99. package/dist/base/pagination/src/core.d.ts +0 -11
  100. package/dist/base/pagination/src/pagination.vue.d.ts +0 -26
  101. package/dist/base/search-form/index.d.ts +0 -3
  102. package/dist/base/search-form/src/search-form.vue.d.ts +0 -34
  103. package/dist/base/skeleton/index.d.ts +0 -3
  104. package/dist/base/statistic/index.d.ts +0 -3
  105. package/dist/base/statistic/src/statistic.vue.d.ts +0 -16
  106. package/dist/base/table/index.d.ts +0 -5
  107. package/dist/base/table/src/core.d.ts +0 -25
  108. package/dist/base/table/src/table.vue.d.ts +0 -44
  109. package/dist/base/toast/index.d.ts +0 -5
  110. package/dist/base/toast/src/store.d.ts +0 -56
  111. package/dist/base/toast/src/toast-container.vue.d.ts +0 -3
  112. package/dist/campus-ui.css +0 -2
  113. package/dist/campus-ui.js +0 -2229
  114. package/dist/campus-ui.umd.cjs +0 -1
  115. package/dist/core/index.d.ts +0 -4
  116. package/dist/core/namespace.d.ts +0 -16
  117. package/dist/core/theme.d.ts +0 -49
  118. package/dist/feature/daily-agenda/index.d.ts +0 -5
  119. package/dist/feature/daily-agenda/src/core.d.ts +0 -25
  120. package/dist/feature/daily-agenda/src/daily-agenda.vue.d.ts +0 -12
  121. package/dist/feature/daily-agenda/src/data.d.ts +0 -3
  122. package/dist/feature/index.d.ts +0 -61
  123. package/dist/feature/student-picker/index.d.ts +0 -5
  124. package/dist/feature/student-picker/src/core.d.ts +0 -19
  125. package/dist/feature/student-picker/src/student-picker.vue.d.ts +0 -26
  126. package/dist/feature/weekly-timetable/index.d.ts +0 -6
  127. package/dist/feature/weekly-timetable/src/core.d.ts +0 -33
  128. package/dist/feature/weekly-timetable/src/data.d.ts +0 -3
  129. package/dist/feature/weekly-timetable/src/weekly-timetable.vue.d.ts +0 -7
@@ -1,651 +0,0 @@
1
- /**
2
- * 基础类组件。
3
- *
4
- * 判据:区域级、能直接放进页面布局,给一个宽度就能自己撑满并正常运作;
5
- * 与业务无关,不含校园数据模型。
6
- *
7
- * 价值在于"渲染结构"的组件放这里;价值在于"完成一件事"的放到 feature。
8
- */
9
- import { CaBreadcrumb } from './breadcrumb';
10
- import { CaClassTree } from './class-tree';
11
- import { CaCopyright } from './copyright';
12
- import { CaDrawer } from './drawer';
13
- import { CaEmpty } from './empty';
14
- import { CaModal } from './modal';
15
- import { CaPageHeader } from './page-header';
16
- import { CaPagination } from './pagination';
17
- import { CaSearchForm } from './search-form';
18
- import { CaSideMenu } from './menu';
19
- import { CaSkeleton } from './skeleton';
20
- import { CaStatistic } from './statistic';
21
- import { CaTable } from './table';
22
- import { CaToastContainer } from './toast';
23
- export { CaBreadcrumb, CaClassTree, CaCopyright, CaDrawer, CaEmpty, CaModal, CaPageHeader, CaPagination, CaSearchForm, CaSideMenu, CaSkeleton, CaStatistic, CaTable, CaToastContainer, };
24
- export { clearToasts, closeToast, setToasts, toast, toasts } from './toast';
25
- export type { ToastItem, ToastOptions, ToastTone } from './toast';
26
- export type { BreadcrumbItem } from './breadcrumb';
27
- export type { ClassNode as ClassTreeNode, GradeNode as GradeTreeNode } from './class-tree';
28
- export type { FlatSideMenuItem, SideMenuItem } from './menu';
29
- export type { SortOrder, TableColumn } from './table';
30
- /** 基础层注册表,由顶层 index.ts 合并成 builtInComponents */
31
- export declare const baseComponents: {
32
- CaBreadcrumb: {
33
- new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins<Readonly<{
34
- items: import("./breadcrumb").BreadcrumbItem[];
35
- homeIcon?: boolean;
36
- }> & Readonly<{
37
- onNavigate?: ((item: import("./breadcrumb").BreadcrumbItem, index: number) => any) | undefined;
38
- }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
39
- navigate: (item: import("./breadcrumb").BreadcrumbItem, index: number) => any;
40
- }, import("vue").PublicProps, {
41
- homeIcon: boolean;
42
- }, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, {
43
- P: {};
44
- B: {};
45
- D: {};
46
- C: {};
47
- M: {};
48
- Defaults: {};
49
- }, Readonly<{
50
- items: import("./breadcrumb").BreadcrumbItem[];
51
- homeIcon?: boolean;
52
- }> & Readonly<{
53
- onNavigate?: ((item: import("./breadcrumb").BreadcrumbItem, index: number) => any) | undefined;
54
- }>, {}, {}, {}, {}, {
55
- homeIcon: boolean;
56
- }>;
57
- __isFragment?: never;
58
- __isTeleport?: never;
59
- __isSuspense?: never;
60
- } & import("vue").ComponentOptionsBase<Readonly<{
61
- items: import("./breadcrumb").BreadcrumbItem[];
62
- homeIcon?: boolean;
63
- }> & Readonly<{
64
- onNavigate?: ((item: import("./breadcrumb").BreadcrumbItem, index: number) => any) | undefined;
65
- }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
66
- navigate: (item: import("./breadcrumb").BreadcrumbItem, index: number) => any;
67
- }, string, {
68
- homeIcon: boolean;
69
- }, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
70
- $slots: {
71
- extra?: (props: {}) => any;
72
- };
73
- });
74
- CaClassTree: import("vue").DefineComponent<{
75
- modelValue?: string;
76
- grades?: import("./class-tree").GradeNode[];
77
- searchable?: boolean;
78
- expandedKeys?: string[];
79
- }, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
80
- "update:modelValue": (id: string) => any;
81
- change: (id: string, node: {
82
- id: string;
83
- label: string;
84
- }) => any;
85
- "update:expandedKeys": (keys: string[]) => any;
86
- }, string, import("vue").PublicProps, Readonly<{
87
- modelValue?: string;
88
- grades?: import("./class-tree").GradeNode[];
89
- searchable?: boolean;
90
- expandedKeys?: string[];
91
- }> & Readonly<{
92
- "onUpdate:modelValue"?: ((id: string) => any) | undefined;
93
- onChange?: ((id: string, node: {
94
- id: string;
95
- label: string;
96
- }) => any) | undefined;
97
- "onUpdate:expandedKeys"?: ((keys: string[]) => any) | undefined;
98
- }>, {
99
- grades: import("./class-tree").GradeNode[];
100
- searchable: boolean;
101
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
102
- CaCopyright: {
103
- new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins<Readonly<{
104
- name?: string;
105
- displayCopyright?: string;
106
- partner?: string;
107
- }> & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {
108
- name: string;
109
- displayCopyright: string;
110
- partner: string;
111
- }, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, {
112
- P: {};
113
- B: {};
114
- D: {};
115
- C: {};
116
- M: {};
117
- Defaults: {};
118
- }, Readonly<{
119
- name?: string;
120
- displayCopyright?: string;
121
- partner?: string;
122
- }> & Readonly<{}>, {}, {}, {}, {}, {
123
- name: string;
124
- displayCopyright: string;
125
- partner: string;
126
- }>;
127
- __isFragment?: never;
128
- __isTeleport?: never;
129
- __isSuspense?: never;
130
- } & import("vue").ComponentOptionsBase<Readonly<{
131
- name?: string;
132
- displayCopyright?: string;
133
- partner?: string;
134
- }> & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {
135
- name: string;
136
- displayCopyright: string;
137
- partner: string;
138
- }, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
139
- $slots: {
140
- default?: (props: {}) => any;
141
- };
142
- });
143
- CaDrawer: {
144
- new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins<Readonly<{
145
- modelValue?: boolean;
146
- title?: string;
147
- placement?: "right" | "left" | "bottom";
148
- size?: number | string;
149
- maskClosable?: boolean;
150
- escClosable?: boolean;
151
- }> & Readonly<{
152
- "onUpdate:modelValue"?: ((value: boolean) => any) | undefined;
153
- onClosed?: (() => any) | undefined;
154
- }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
155
- "update:modelValue": (value: boolean) => any;
156
- closed: () => any;
157
- }, import("vue").PublicProps, {
158
- size: number | string;
159
- placement: "right" | "left" | "bottom";
160
- maskClosable: boolean;
161
- escClosable: boolean;
162
- }, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, {
163
- P: {};
164
- B: {};
165
- D: {};
166
- C: {};
167
- M: {};
168
- Defaults: {};
169
- }, Readonly<{
170
- modelValue?: boolean;
171
- title?: string;
172
- placement?: "right" | "left" | "bottom";
173
- size?: number | string;
174
- maskClosable?: boolean;
175
- escClosable?: boolean;
176
- }> & Readonly<{
177
- "onUpdate:modelValue"?: ((value: boolean) => any) | undefined;
178
- onClosed?: (() => any) | undefined;
179
- }>, {}, {}, {}, {}, {
180
- size: number | string;
181
- placement: "right" | "left" | "bottom";
182
- maskClosable: boolean;
183
- escClosable: boolean;
184
- }>;
185
- __isFragment?: never;
186
- __isTeleport?: never;
187
- __isSuspense?: never;
188
- } & import("vue").ComponentOptionsBase<Readonly<{
189
- modelValue?: boolean;
190
- title?: string;
191
- placement?: "right" | "left" | "bottom";
192
- size?: number | string;
193
- maskClosable?: boolean;
194
- escClosable?: boolean;
195
- }> & Readonly<{
196
- "onUpdate:modelValue"?: ((value: boolean) => any) | undefined;
197
- onClosed?: (() => any) | undefined;
198
- }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
199
- "update:modelValue": (value: boolean) => any;
200
- closed: () => any;
201
- }, string, {
202
- size: number | string;
203
- placement: "right" | "left" | "bottom";
204
- maskClosable: boolean;
205
- escClosable: boolean;
206
- }, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
207
- $slots: {
208
- title?: (props: {}) => any;
209
- } & {
210
- default?: (props: {}) => any;
211
- } & {
212
- footer?: (props: {}) => any;
213
- };
214
- });
215
- CaEmpty: {
216
- new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins<Readonly<{
217
- title?: string;
218
- description?: string;
219
- size?: "small" | "medium";
220
- }> & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, {
221
- P: {};
222
- B: {};
223
- D: {};
224
- C: {};
225
- M: {};
226
- Defaults: {};
227
- }, Readonly<{
228
- title?: string;
229
- description?: string;
230
- size?: "small" | "medium";
231
- }> & Readonly<{}>, {}, {}, {}, {}, {}>;
232
- __isFragment?: never;
233
- __isTeleport?: never;
234
- __isSuspense?: never;
235
- } & import("vue").ComponentOptionsBase<Readonly<{
236
- title?: string;
237
- description?: string;
238
- size?: "small" | "medium";
239
- }> & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
240
- $slots: {
241
- icon?: (props: {}) => any;
242
- } & {
243
- default?: (props: {}) => any;
244
- };
245
- });
246
- CaModal: {
247
- new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins<Readonly<{
248
- modelValue?: boolean;
249
- title?: string;
250
- width?: number | string;
251
- maskClosable?: boolean;
252
- escClosable?: boolean;
253
- destroyOnClose?: boolean;
254
- showFooter?: boolean;
255
- confirmText?: string;
256
- cancelText?: string;
257
- confirmLoading?: boolean;
258
- }> & Readonly<{
259
- "onUpdate:modelValue"?: ((value: boolean) => any) | undefined;
260
- onClosed?: (() => any) | undefined;
261
- onCancel?: (() => any) | undefined;
262
- onConfirm?: (() => any) | undefined;
263
- }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
264
- "update:modelValue": (value: boolean) => any;
265
- closed: () => any;
266
- cancel: () => any;
267
- confirm: () => any;
268
- }, import("vue").PublicProps, {
269
- maskClosable: boolean;
270
- escClosable: boolean;
271
- showFooter: boolean;
272
- }, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, {
273
- P: {};
274
- B: {};
275
- D: {};
276
- C: {};
277
- M: {};
278
- Defaults: {};
279
- }, Readonly<{
280
- modelValue?: boolean;
281
- title?: string;
282
- width?: number | string;
283
- maskClosable?: boolean;
284
- escClosable?: boolean;
285
- destroyOnClose?: boolean;
286
- showFooter?: boolean;
287
- confirmText?: string;
288
- cancelText?: string;
289
- confirmLoading?: boolean;
290
- }> & Readonly<{
291
- "onUpdate:modelValue"?: ((value: boolean) => any) | undefined;
292
- onClosed?: (() => any) | undefined;
293
- onCancel?: (() => any) | undefined;
294
- onConfirm?: (() => any) | undefined;
295
- }>, {}, {}, {}, {}, {
296
- maskClosable: boolean;
297
- escClosable: boolean;
298
- showFooter: boolean;
299
- }>;
300
- __isFragment?: never;
301
- __isTeleport?: never;
302
- __isSuspense?: never;
303
- } & import("vue").ComponentOptionsBase<Readonly<{
304
- modelValue?: boolean;
305
- title?: string;
306
- width?: number | string;
307
- maskClosable?: boolean;
308
- escClosable?: boolean;
309
- destroyOnClose?: boolean;
310
- showFooter?: boolean;
311
- confirmText?: string;
312
- cancelText?: string;
313
- confirmLoading?: boolean;
314
- }> & Readonly<{
315
- "onUpdate:modelValue"?: ((value: boolean) => any) | undefined;
316
- onClosed?: (() => any) | undefined;
317
- onCancel?: (() => any) | undefined;
318
- onConfirm?: (() => any) | undefined;
319
- }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
320
- "update:modelValue": (value: boolean) => any;
321
- closed: () => any;
322
- cancel: () => any;
323
- confirm: () => any;
324
- }, string, {
325
- maskClosable: boolean;
326
- escClosable: boolean;
327
- showFooter: boolean;
328
- }, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
329
- $slots: {
330
- title?: (props: {}) => any;
331
- } & {
332
- default?: (props: {}) => any;
333
- } & {
334
- footer?: (props: {}) => any;
335
- };
336
- });
337
- CaPageHeader: {
338
- new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins<Readonly<{
339
- title: string;
340
- description?: string;
341
- backable?: boolean;
342
- bordered?: boolean;
343
- }> & Readonly<{
344
- onBack?: (() => any) | undefined;
345
- }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
346
- back: () => any;
347
- }, import("vue").PublicProps, {
348
- bordered: boolean;
349
- }, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, {
350
- P: {};
351
- B: {};
352
- D: {};
353
- C: {};
354
- M: {};
355
- Defaults: {};
356
- }, Readonly<{
357
- title: string;
358
- description?: string;
359
- backable?: boolean;
360
- bordered?: boolean;
361
- }> & Readonly<{
362
- onBack?: (() => any) | undefined;
363
- }>, {}, {}, {}, {}, {
364
- bordered: boolean;
365
- }>;
366
- __isFragment?: never;
367
- __isTeleport?: never;
368
- __isSuspense?: never;
369
- } & import("vue").ComponentOptionsBase<Readonly<{
370
- title: string;
371
- description?: string;
372
- backable?: boolean;
373
- bordered?: boolean;
374
- }> & Readonly<{
375
- onBack?: (() => any) | undefined;
376
- }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
377
- back: () => any;
378
- }, string, {
379
- bordered: boolean;
380
- }, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
381
- $slots: {
382
- default?: (props: {}) => any;
383
- };
384
- });
385
- CaPagination: import("vue").DefineComponent<{
386
- current?: number;
387
- pageSize?: number;
388
- total: number;
389
- disabled?: boolean;
390
- showTotal?: boolean;
391
- }, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
392
- change: (page: number, size: number) => any;
393
- "update:current": (page: number) => any;
394
- "update:pageSize": (size: number) => any;
395
- }, string, import("vue").PublicProps, Readonly<{
396
- current?: number;
397
- pageSize?: number;
398
- total: number;
399
- disabled?: boolean;
400
- showTotal?: boolean;
401
- }> & Readonly<{
402
- onChange?: ((page: number, size: number) => any) | undefined;
403
- "onUpdate:current"?: ((page: number) => any) | undefined;
404
- "onUpdate:pageSize"?: ((size: number) => any) | undefined;
405
- }>, {
406
- disabled: boolean;
407
- current: number;
408
- pageSize: number;
409
- showTotal: boolean;
410
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
411
- CaSearchForm: {
412
- new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins<Readonly<{
413
- loading?: boolean;
414
- columns?: number;
415
- visibleCount?: number;
416
- searchText?: string;
417
- resetText?: string;
418
- }> & Readonly<{
419
- onSearch?: (() => any) | undefined;
420
- onReset?: (() => any) | undefined;
421
- }>, {
422
- expand: () => void;
423
- collapse: () => void;
424
- }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
425
- search: () => any;
426
- reset: () => any;
427
- }, import("vue").PublicProps, {
428
- columns: number;
429
- visibleCount: number;
430
- }, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, {
431
- P: {};
432
- B: {};
433
- D: {};
434
- C: {};
435
- M: {};
436
- Defaults: {};
437
- }, Readonly<{
438
- loading?: boolean;
439
- columns?: number;
440
- visibleCount?: number;
441
- searchText?: string;
442
- resetText?: string;
443
- }> & Readonly<{
444
- onSearch?: (() => any) | undefined;
445
- onReset?: (() => any) | undefined;
446
- }>, {
447
- expand: () => void;
448
- collapse: () => void;
449
- }, {}, {}, {}, {
450
- columns: number;
451
- visibleCount: number;
452
- }>;
453
- __isFragment?: never;
454
- __isTeleport?: never;
455
- __isSuspense?: never;
456
- } & import("vue").ComponentOptionsBase<Readonly<{
457
- loading?: boolean;
458
- columns?: number;
459
- visibleCount?: number;
460
- searchText?: string;
461
- resetText?: string;
462
- }> & Readonly<{
463
- onSearch?: (() => any) | undefined;
464
- onReset?: (() => any) | undefined;
465
- }>, {
466
- expand: () => void;
467
- collapse: () => void;
468
- }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
469
- search: () => any;
470
- reset: () => any;
471
- }, string, {
472
- columns: number;
473
- visibleCount: number;
474
- }, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
475
- $slots: {
476
- default?: (props: {}) => any;
477
- };
478
- });
479
- CaSideMenu: {
480
- new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins<Readonly<{
481
- items: import("./menu").SideMenuItem[];
482
- modelValue?: string;
483
- expandedKeys?: string[];
484
- defaultExpandAll?: boolean;
485
- highlightBranch?: boolean;
486
- ariaLabel?: string;
487
- indent?: number;
488
- indentStep?: number;
489
- levelOffset?: number[];
490
- subIcon?: unknown;
491
- }> & Readonly<{
492
- onSelect?: ((item: import("./menu").SideMenuItem, key: string) => any) | undefined;
493
- "onUpdate:modelValue"?: ((key: string, item: import("./menu").SideMenuItem) => any) | undefined;
494
- "onUpdate:expandedKeys"?: ((keys: string[]) => any) | undefined;
495
- "onExpand-change"?: ((keys: string[], key: string, expanded: boolean) => any) | undefined;
496
- }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
497
- select: (item: import("./menu").SideMenuItem, key: string) => any;
498
- "update:modelValue": (key: string, item: import("./menu").SideMenuItem) => any;
499
- "update:expandedKeys": (keys: string[]) => any;
500
- "expand-change": (keys: string[], key: string, expanded: boolean) => any;
501
- }, import("vue").PublicProps, {
502
- defaultExpandAll: boolean;
503
- highlightBranch: boolean;
504
- indent: number;
505
- indentStep: number;
506
- levelOffset: number[];
507
- }, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, {
508
- P: {};
509
- B: {};
510
- D: {};
511
- C: {};
512
- M: {};
513
- Defaults: {};
514
- }, Readonly<{
515
- items: import("./menu").SideMenuItem[];
516
- modelValue?: string;
517
- expandedKeys?: string[];
518
- defaultExpandAll?: boolean;
519
- highlightBranch?: boolean;
520
- ariaLabel?: string;
521
- indent?: number;
522
- indentStep?: number;
523
- levelOffset?: number[];
524
- subIcon?: unknown;
525
- }> & Readonly<{
526
- onSelect?: ((item: import("./menu").SideMenuItem, key: string) => any) | undefined;
527
- "onUpdate:modelValue"?: ((key: string, item: import("./menu").SideMenuItem) => any) | undefined;
528
- "onUpdate:expandedKeys"?: ((keys: string[]) => any) | undefined;
529
- "onExpand-change"?: ((keys: string[], key: string, expanded: boolean) => any) | undefined;
530
- }>, {}, {}, {}, {}, {
531
- defaultExpandAll: boolean;
532
- highlightBranch: boolean;
533
- indent: number;
534
- indentStep: number;
535
- levelOffset: number[];
536
- }>;
537
- __isFragment?: never;
538
- __isTeleport?: never;
539
- __isSuspense?: never;
540
- } & import("vue").ComponentOptionsBase<Readonly<{
541
- items: import("./menu").SideMenuItem[];
542
- modelValue?: string;
543
- expandedKeys?: string[];
544
- defaultExpandAll?: boolean;
545
- highlightBranch?: boolean;
546
- ariaLabel?: string;
547
- indent?: number;
548
- indentStep?: number;
549
- levelOffset?: number[];
550
- subIcon?: unknown;
551
- }> & Readonly<{
552
- onSelect?: ((item: import("./menu").SideMenuItem, key: string) => any) | undefined;
553
- "onUpdate:modelValue"?: ((key: string, item: import("./menu").SideMenuItem) => any) | undefined;
554
- "onUpdate:expandedKeys"?: ((keys: string[]) => any) | undefined;
555
- "onExpand-change"?: ((keys: string[], key: string, expanded: boolean) => any) | undefined;
556
- }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
557
- select: (item: import("./menu").SideMenuItem, key: string) => any;
558
- "update:modelValue": (key: string, item: import("./menu").SideMenuItem) => any;
559
- "update:expandedKeys": (keys: string[]) => any;
560
- "expand-change": (keys: string[], key: string, expanded: boolean) => any;
561
- }, string, {
562
- defaultExpandAll: boolean;
563
- highlightBranch: boolean;
564
- indent: number;
565
- indentStep: number;
566
- levelOffset: number[];
567
- }, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
568
- $slots: {
569
- icon?: (props: {
570
- item: import("./menu").FlatSideMenuItem;
571
- }) => any;
572
- } & {
573
- default?: (props: {
574
- item: import("./menu").FlatSideMenuItem;
575
- }) => any;
576
- };
577
- });
578
- CaSkeleton: import("vue").DefineComponent<{
579
- rows?: number;
580
- variant?: "text" | "card" | "avatar";
581
- }, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{
582
- rows?: number;
583
- variant?: "text" | "card" | "avatar";
584
- }> & Readonly<{}>, {
585
- variant: "text" | "card" | "avatar";
586
- rows: number;
587
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
588
- CaStatistic: import("vue").DefineComponent<{
589
- label: string;
590
- value: string | number;
591
- unit?: string;
592
- hint?: string;
593
- tone?: import("..").ComponentTone;
594
- card?: boolean;
595
- }, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{
596
- label: string;
597
- value: string | number;
598
- unit?: string;
599
- hint?: string;
600
- tone?: import("..").ComponentTone;
601
- card?: boolean;
602
- }> & Readonly<{}>, {
603
- tone: import("..").ComponentTone;
604
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
605
- CaTable: <T extends object>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: {
606
- attrs: any;
607
- slots: {
608
- [x: `cell-${string}`]: ((props: {
609
- row: T;
610
- index: number;
611
- column: import("./table").TableColumn<T>;
612
- }) => any) | undefined;
613
- } & {
614
- empty?: (props: {}) => any;
615
- };
616
- emit: ((evt: "sort", key: string, order: import("./table").SortOrder) => void) & ((evt: "update:sortKey", key: string) => void) & ((evt: "update:sortOrder", order: import("./table").SortOrder) => void) & ((evt: "row-click", row: T, index: number) => void);
617
- }, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
618
- props: import("vue").PublicProps & {
619
- columns: import("./table").TableColumn<T>[];
620
- data?: T[] | undefined;
621
- rowKey?: string | ((row: T) => string) | undefined;
622
- loading?: boolean | undefined;
623
- stripe?: boolean | undefined;
624
- compact?: boolean | undefined;
625
- sortKey?: string | undefined;
626
- sortOrder?: import("./table").SortOrder | undefined;
627
- emptyText?: string | undefined;
628
- onSort?: ((key: string, order: import("./table").SortOrder) => any) | undefined;
629
- "onUpdate:sortKey"?: ((key: string) => any) | undefined;
630
- "onUpdate:sortOrder"?: ((order: import("./table").SortOrder) => any) | undefined;
631
- "onRow-click"?: ((row: T, index: number) => any) | undefined;
632
- } & (typeof globalThis extends {
633
- __VLS_PROPS_FALLBACK: infer P;
634
- } ? P : {});
635
- expose: (exposed: {}) => void;
636
- attrs: any;
637
- slots: {
638
- [x: `cell-${string}`]: ((props: {
639
- row: T;
640
- index: number;
641
- column: import("./table").TableColumn<T>;
642
- }) => any) | undefined;
643
- } & {
644
- empty?: (props: {}) => any;
645
- };
646
- emit: ((evt: "sort", key: string, order: import("./table").SortOrder) => void) & ((evt: "update:sortKey", key: string) => void) & ((evt: "update:sortOrder", order: import("./table").SortOrder) => void) & ((evt: "row-click", row: T, index: number) => void);
647
- }>) => import("vue").VNode & {
648
- __ctx?: NonNullable<Awaited<typeof __VLS_setup>>;
649
- };
650
- CaToastContainer: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
651
- };
@@ -1,34 +0,0 @@
1
- export interface SideMenuItem {
2
- /** 显示文案 */
3
- label: string;
4
- /**
5
- * 节点标识。
6
- * 不传时依次回退到 value、label,用于展开状态与选中态匹配。
7
- */
8
- key?: string;
9
- /** 业务数据,例如路由地址;组件本身不解释它的含义 */
10
- value?: string;
11
- /** 图标组件,需为可渲染的 Vue 组件 */
12
- icon?: unknown;
13
- /** 右侧角标,通常是待办数量 */
14
- badge?: string;
15
- disabled?: boolean;
16
- children?: SideMenuItem[];
17
- }
18
- export interface FlatSideMenuItem extends SideMenuItem {
19
- level: number;
20
- itemKey: string;
21
- expandable: boolean;
22
- parentKeys: string[];
23
- }
24
- /** 取节点唯一标识 */
25
- export declare function resolveKey(item: SideMenuItem): string;
26
- /**
27
- * 按展开状态把菜单树拍平成可渲染列表。
28
- *
29
- * 拍平后统一渲染,缩进与层级样式由 level 决定,
30
- * 因此扩展到三级及以上菜单不需要改组件结构。
31
- */
32
- export declare function flattenMenu(items: SideMenuItem[], expanded: Set<string>, level?: number, parentKeys?: string[]): FlatSideMenuItem[];
33
- /** 收集所有可展开节点的 key,用于默认全部展开 */
34
- export declare function collectExpandableKeys(items: SideMenuItem[]): Set<string>;