x-next 1.13.0 → 1.15.0

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 (187) hide show
  1. package/AI_CODING.md +6 -5
  2. package/AI_USAGE/catalog.md +108 -105
  3. package/AI_USAGE/components/alert-api.md +48 -0
  4. package/AI_USAGE/components/alert.md +222 -3
  5. package/AI_USAGE/components/bar-chart-api.md +177 -0
  6. package/AI_USAGE/components/bar-chart.md +297 -3
  7. package/AI_USAGE/components/boxicons.md +147 -0
  8. package/AI_USAGE/components/button-api.md +144 -0
  9. package/AI_USAGE/components/button.md +447 -3
  10. package/AI_USAGE/components/charts.md +81 -0
  11. package/AI_USAGE/components/checkbox-api.md +145 -0
  12. package/AI_USAGE/components/checkbox.md +365 -3
  13. package/AI_USAGE/components/color-picker-api.md +52 -0
  14. package/AI_USAGE/components/color-picker.md +211 -3
  15. package/AI_USAGE/components/config-provider-api.md +38 -0
  16. package/AI_USAGE/components/config-provider.md +250 -3
  17. package/AI_USAGE/components/date-picker-api.md +1114 -0
  18. package/AI_USAGE/components/date-picker.md +378 -3
  19. package/AI_USAGE/components/dialog-api.md +142 -0
  20. package/AI_USAGE/components/dialog.md +284 -3
  21. package/AI_USAGE/components/draggable-api.md +146 -0
  22. package/AI_USAGE/components/draggable.md +259 -0
  23. package/AI_USAGE/components/drawer-api.md +78 -0
  24. package/AI_USAGE/components/drawer.md +256 -0
  25. package/AI_USAGE/components/dropdown-api.md +529 -0
  26. package/AI_USAGE/components/dropdown.md +392 -3
  27. package/AI_USAGE/components/empty-api.md +36 -0
  28. package/AI_USAGE/components/empty.md +227 -3
  29. package/AI_USAGE/components/finicon.md +88 -0
  30. package/AI_USAGE/components/form-api.md +524 -0
  31. package/AI_USAGE/components/form.md +454 -0
  32. package/AI_USAGE/components/grid-api.md +527 -0
  33. package/AI_USAGE/components/grid.md +224 -0
  34. package/AI_USAGE/components/heatmap-api.md +122 -0
  35. package/AI_USAGE/components/heatmap.md +220 -0
  36. package/AI_USAGE/components/icon-api.md +4707 -0
  37. package/AI_USAGE/components/icon.md +257 -0
  38. package/AI_USAGE/components/image-api.md +440 -0
  39. package/AI_USAGE/components/image.md +465 -0
  40. package/AI_USAGE/components/input-api.md +184 -0
  41. package/AI_USAGE/components/input-number-api.md +66 -0
  42. package/AI_USAGE/components/input-number.md +294 -0
  43. package/AI_USAGE/components/input-tag-api.md +114 -0
  44. package/AI_USAGE/components/input-tag.md +482 -0
  45. package/AI_USAGE/components/input.md +293 -3
  46. package/AI_USAGE/components/layout-api.md +147 -0
  47. package/AI_USAGE/components/layout.md +230 -0
  48. package/AI_USAGE/components/line-chart-api.md +197 -0
  49. package/AI_USAGE/components/line-chart.md +306 -3
  50. package/AI_USAGE/components/link-api.md +42 -0
  51. package/AI_USAGE/components/link.md +197 -0
  52. package/AI_USAGE/components/menu-api.md +516 -0
  53. package/AI_USAGE/components/menu.md +268 -0
  54. package/AI_USAGE/components/message-api.md +215 -0
  55. package/AI_USAGE/components/message-box-api.md +108 -0
  56. package/AI_USAGE/components/message-box.md +268 -3
  57. package/AI_USAGE/components/message.md +231 -3
  58. package/AI_USAGE/components/network-api.md +91 -0
  59. package/AI_USAGE/components/network.md +378 -0
  60. package/AI_USAGE/components/notification-api.md +236 -0
  61. package/AI_USAGE/components/notification.md +275 -3
  62. package/AI_USAGE/components/pagination-api.md +62 -0
  63. package/AI_USAGE/components/pagination.md +380 -3
  64. package/AI_USAGE/components/pie-chart-api.md +109 -0
  65. package/AI_USAGE/components/pie-chart.md +245 -3
  66. package/AI_USAGE/components/popconfirm-api.md +75 -0
  67. package/AI_USAGE/components/popconfirm.md +231 -3
  68. package/AI_USAGE/components/popover-api.md +75 -0
  69. package/AI_USAGE/components/popover.md +208 -3
  70. package/AI_USAGE/components/popup-api.md +75 -0
  71. package/AI_USAGE/components/popup.md +52 -0
  72. package/AI_USAGE/components/progress-api.md +44 -0
  73. package/AI_USAGE/components/progress.md +248 -3
  74. package/AI_USAGE/components/radio-api.md +165 -0
  75. package/AI_USAGE/components/radio.md +259 -3
  76. package/AI_USAGE/components/rate-api.md +54 -0
  77. package/AI_USAGE/components/rate.md +233 -3
  78. package/AI_USAGE/components/resize-box-api.md +56 -0
  79. package/AI_USAGE/components/resize-box.md +231 -0
  80. package/AI_USAGE/components/scrollbar-api.md +77 -0
  81. package/AI_USAGE/components/scrollbar.md +218 -0
  82. package/AI_USAGE/components/select-api.md +758 -0
  83. package/AI_USAGE/components/select.md +640 -3
  84. package/AI_USAGE/components/skeleton-api.md +85 -0
  85. package/AI_USAGE/components/skeleton.md +150 -0
  86. package/AI_USAGE/components/slider-api.md +51 -0
  87. package/AI_USAGE/components/slider.md +233 -3
  88. package/AI_USAGE/components/space-api.md +38 -0
  89. package/AI_USAGE/components/space.md +145 -0
  90. package/AI_USAGE/components/spin-api.md +43 -0
  91. package/AI_USAGE/components/spin.md +205 -0
  92. package/AI_USAGE/components/steps-api.md +111 -0
  93. package/AI_USAGE/components/steps.md +201 -3
  94. package/AI_USAGE/components/switch-api.md +58 -0
  95. package/AI_USAGE/components/switch.md +290 -3
  96. package/AI_USAGE/components/table-api.md +2919 -0
  97. package/AI_USAGE/components/table.md +1457 -0
  98. package/AI_USAGE/components/tabs-api.md +135 -0
  99. package/AI_USAGE/components/tabs.md +308 -3
  100. package/AI_USAGE/components/tag-api.md +124 -0
  101. package/AI_USAGE/components/tag.md +292 -0
  102. package/AI_USAGE/components/textarea-api.md +55 -0
  103. package/AI_USAGE/components/textarea.md +326 -3
  104. package/AI_USAGE/components/time-picker-api.md +137 -0
  105. package/AI_USAGE/components/time-picker.md +271 -3
  106. package/AI_USAGE/components/time-range-selector-api.md +44 -0
  107. package/AI_USAGE/components/time-range-selector.md +355 -0
  108. package/AI_USAGE/components/timeline-api.md +93 -0
  109. package/AI_USAGE/components/timeline.md +312 -0
  110. package/AI_USAGE/components/tooltip-api.md +77 -0
  111. package/AI_USAGE/components/tooltip.md +182 -0
  112. package/AI_USAGE/components/tree-select-api.md +498 -0
  113. package/AI_USAGE/components/tree-select.md +744 -0
  114. package/AI_USAGE/components/trend-chart-api.md +119 -0
  115. package/AI_USAGE/components/trend-chart.md +335 -0
  116. package/AI_USAGE/components/trigger-api.md +124 -0
  117. package/AI_USAGE/components/trigger.md +185 -0
  118. package/AI_USAGE/components/upload-api.md +200 -0
  119. package/AI_USAGE/components/upload.md +711 -3
  120. package/AI_USAGE/components/watermark-api.md +87 -0
  121. package/AI_USAGE/components/watermark.md +200 -0
  122. package/AI_USAGE/core.md +1 -1
  123. package/AI_USAGE/index.md +36 -7
  124. package/AI_USAGE/recipes/form-on-demand.md +1 -1
  125. package/AI_USAGE.md +34972 -5
  126. package/CHANGELOG.md +39 -0
  127. package/dist/_props/css.d.ts +2 -1
  128. package/dist/_utils/inherit-component-type.d.ts +11 -0
  129. package/dist/components/bar-chart/BarChart.d.ts +1 -1
  130. package/dist/components/bar-chart/index.d.ts +3 -3
  131. package/dist/components/date-picker/index.d.ts +420 -5
  132. package/dist/components/form-input/index.d.ts +617 -2
  133. package/dist/components/index.d.ts +1 -0
  134. package/dist/components/layout/index.d.ts +689 -1
  135. package/dist/components/line-chart/LineChart.d.ts +1 -1
  136. package/dist/components/line-chart/index.d.ts +3 -3
  137. package/dist/components/line-chart/interface.d.ts +2 -2
  138. package/dist/components/menu/index.d.ts +786 -1
  139. package/dist/components/tree-select/TreeNode.vue.d.ts +478 -0
  140. package/dist/components/tree-select/TreeSelect.d.ts +1549 -0
  141. package/dist/components/tree-select/TreeSelectDropdown.vue.d.ts +569 -0
  142. package/dist/components/tree-select/hooks/use-tree-select.d.ts +92 -0
  143. package/dist/components/tree-select/index.d.ts +3321 -0
  144. package/dist/components/tree-select/interface.d.ts +203 -0
  145. package/dist/components/tree-select/utils.d.ts +64 -0
  146. package/dist/es/_styles/palette-aliases.js +3 -0
  147. package/dist/es/_utils/inherit-component-type.js +6 -0
  148. package/dist/es/components/_components/feedback-icon/index.vue2.js +10 -10
  149. package/dist/es/components/button/Button.js +9 -9
  150. package/dist/es/components/date-picker/index.js +18 -17
  151. package/dist/es/components/drawer/src/Drawer.vue.js +6 -6
  152. package/dist/es/components/form-input/index.js +12 -11
  153. package/dist/es/components/form-switch/Switch.vue2.js +18 -18
  154. package/dist/es/components/image/Image.vue2.js +13 -13
  155. package/dist/es/components/image/ImagePreview.vue2.js +33 -33
  156. package/dist/es/components/index.js +55 -52
  157. package/dist/es/components/layout/index.js +10 -9
  158. package/dist/es/components/link/Link.vue2.js +12 -12
  159. package/dist/es/components/menu/hooks/use-level.js +5 -5
  160. package/dist/es/components/menu/index.js +13 -10
  161. package/dist/es/components/message/message.vue2.js +13 -13
  162. package/dist/es/components/spin/Spin.js +28 -28
  163. package/dist/es/components/tag/Tag.vue2.js +22 -22
  164. package/dist/es/components/timeline/src/Timeline.js +7 -7
  165. package/dist/es/components/tree-select/TreeNode.vue.js +91 -0
  166. package/dist/es/components/tree-select/TreeNode.vue2.js +162 -0
  167. package/dist/es/components/tree-select/TreeSelect.js +865 -0
  168. package/dist/es/components/tree-select/TreeSelectDropdown.vue.js +57 -0
  169. package/dist/es/components/tree-select/TreeSelectDropdown.vue2.js +79 -0
  170. package/dist/es/components/tree-select/hooks/use-tree-select.js +376 -0
  171. package/dist/es/components/tree-select/index.js +13 -0
  172. package/dist/es/components/tree-select/utils.js +181 -0
  173. package/dist/es/icons/animation/animation-loading.js +2 -2
  174. package/dist/es/index.js +71 -68
  175. package/dist/es/style.css +1 -1
  176. package/dist/index.cjs +3 -3
  177. package/dist/index.umd.js +3 -3
  178. package/dist/style/base.css +1 -1
  179. package/dist/style/dependencies.json +10 -0
  180. package/dist/style/drawer.css +1 -1
  181. package/dist/style/table.css +1 -1
  182. package/dist/style/tree-select.css +1 -0
  183. package/dist/style/tree-select.js +8 -0
  184. package/dist/style.css +1 -1
  185. package/dist/types.d.ts +2 -0
  186. package/package.json +11 -5
  187. package/volar.d.ts +2 -0
@@ -0,0 +1,203 @@
1
+ import { RenderFunction } from 'vue';
2
+ import { FieldString } from '../../_hooks/_types';
3
+ import { Size } from '../../_utils/constant';
4
+ import { VirtualListProps } from '../virtual-list-v2/interface';
5
+ import { TriggerProps } from '../trigger/interface';
6
+ import { ScrollbarProps } from '../scrollbar-v2';
7
+ /**
8
+ * @zh 树节点键值
9
+ * @en Tree node key
10
+ */
11
+ export type TreeSelectKey = string | number;
12
+ /**
13
+ * @zh 树节点数据
14
+ * @en Tree node data
15
+ */
16
+ export interface TreeSelectNodeData {
17
+ /**
18
+ * @zh 节点键值,全局唯一;不传时按节点路径自动生成
19
+ * @en Node key, unique in the whole tree; generated from the node path when omitted
20
+ */
21
+ key?: TreeSelectKey;
22
+ /**
23
+ * @zh 节点标题
24
+ * @en Node title
25
+ */
26
+ title?: string;
27
+ /**
28
+ * @zh 子节点
29
+ * @en Child nodes
30
+ */
31
+ children?: TreeSelectNodeData[];
32
+ /**
33
+ * @zh 是否禁用,禁用节点不可选中、不可勾选、不参与父子联动
34
+ * @en Whether disabled. Disabled nodes cannot be selected or checked and are excluded from cascade
35
+ */
36
+ disabled?: boolean;
37
+ /**
38
+ * @zh 是否可勾选,仅 `treeCheckable` 时生效
39
+ * @en Whether checkable, only works with `treeCheckable`
40
+ */
41
+ checkable?: boolean;
42
+ /**
43
+ * @zh 是否禁用复选框,仍可被父节点联动勾选
44
+ * @en Whether the checkbox is disabled. The node can still be toggled by its parent
45
+ */
46
+ disableCheckbox?: boolean;
47
+ /**
48
+ * @zh 是否可选中
49
+ * @en Whether selectable
50
+ */
51
+ selectable?: boolean;
52
+ /**
53
+ * @zh 是否为叶子节点,配合 `loadMore` 判断是否需要异步加载子节点
54
+ * @en Whether it is a leaf, used with `loadMore` for lazy loading
55
+ */
56
+ isLeaf?: boolean;
57
+ /**
58
+ * @zh 节点前缀图标
59
+ * @en Node prefix icon
60
+ */
61
+ icon?: RenderFunction;
62
+ [other: string]: any;
63
+ }
64
+ /**
65
+ * @zh 自定义 `TreeSelectNodeData` 中的字段名
66
+ * @en Customize the field names of `TreeSelectNodeData`
67
+ */
68
+ export type TreeSelectFieldNames = FieldString<TreeSelectNodeData>;
69
+ /**
70
+ * @zh 标签模式的选中项
71
+ * @en Selected item in label-in-value mode
72
+ */
73
+ export interface TreeSelectLabelValue {
74
+ /**
75
+ * @zh 选中的键值
76
+ * @en Selected key
77
+ */
78
+ value: TreeSelectKey;
79
+ /**
80
+ * @zh 选中的标题
81
+ * @en Selected title
82
+ */
83
+ label: string;
84
+ /**
85
+ * @zh 节点原始数据
86
+ * @en Raw node data
87
+ */
88
+ raw?: TreeSelectNodeData;
89
+ }
90
+ /**
91
+ * @zh 选中值
92
+ * @en Selected value
93
+ */
94
+ export type TreeSelectValue = TreeSelectKey | TreeSelectLabelValue;
95
+ /**
96
+ * @zh 过滤节点的方法,返回 `true` 表示命中
97
+ * @en Filter node method, returns `true` when the node matches
98
+ */
99
+ export type TreeSelectFilterNode = (inputValue: string, node: TreeSelectNodeData) => boolean;
100
+ /**
101
+ * @zh 节点是否可选中的判定
102
+ * @en Determine whether a node is selectable
103
+ */
104
+ export type TreeSelectSelectable = boolean | 'leaf' | ((node: TreeSelectNodeData, info: {
105
+ isLeaf: boolean;
106
+ level: number;
107
+ }) => boolean);
108
+ export interface TreeSelectInstance {
109
+ /** 聚焦默认触发器 */
110
+ focus: () => void;
111
+ /** 失焦默认触发器 */
112
+ blur: () => void;
113
+ /** 展开 / 收起全部可展开节点,默认展开 */
114
+ expandAll: (expanded?: boolean) => void;
115
+ /** 全选 / 清空勾选,仅勾选模式生效,默认全选 */
116
+ checkAll: (checked?: boolean) => void;
117
+ }
118
+ export interface TreeSelectProps {
119
+ modelValue?: TreeSelectValue | TreeSelectValue[];
120
+ defaultValue?: TreeSelectValue | TreeSelectValue[];
121
+ multiple?: boolean;
122
+ treeCheckable?: boolean;
123
+ treeCheckStrictly?: boolean;
124
+ checkedStrategy?: 'all' | 'parent' | 'child';
125
+ data?: TreeSelectNodeData[];
126
+ fieldNames?: TreeSelectFieldNames;
127
+ labelInValue?: boolean;
128
+ selectable?: TreeSelectSelectable;
129
+ allowSearch?: boolean | {
130
+ retainInputValue?: boolean;
131
+ };
132
+ allowClear?: boolean;
133
+ filterTreeNode?: boolean | TreeSelectFilterNode;
134
+ searchDelay?: number;
135
+ inputValue?: string;
136
+ defaultInputValue?: string;
137
+ size?: Size;
138
+ placeholder?: string;
139
+ loading?: boolean;
140
+ disabled?: boolean;
141
+ error?: boolean;
142
+ bordered?: boolean;
143
+ maxTagCount?: number;
144
+ tagNowrap?: boolean;
145
+ popupVisible?: boolean;
146
+ defaultPopupVisible?: boolean;
147
+ unmountOnClose?: boolean;
148
+ popupContainer?: string | HTMLElement;
149
+ triggerProps?: TriggerProps;
150
+ defaultExpandAll?: boolean;
151
+ expandedKeys?: TreeSelectKey[];
152
+ defaultExpandedKeys?: TreeSelectKey[];
153
+ autoExpandParent?: boolean;
154
+ showLine?: boolean;
155
+ blockNode?: boolean;
156
+ virtualListProps?: VirtualListProps;
157
+ scrollbar?: boolean | ScrollbarProps;
158
+ maxHeight?: number | string;
159
+ loadMore?: (node: TreeSelectNodeData) => Promise<void>;
160
+ fallbackOption?: boolean | ((value: TreeSelectKey) => TreeSelectNodeData);
161
+ formatLabel?: (data: TreeSelectNodeData) => string;
162
+ showHeaderOnEmpty?: boolean;
163
+ showFooterOnEmpty?: boolean;
164
+ }
165
+ /**
166
+ * @zh 内部节点信息
167
+ * @en Internal node info
168
+ */
169
+ export interface TreeSelectNodeInfo {
170
+ key: string;
171
+ value: TreeSelectKey;
172
+ title: string;
173
+ raw: TreeSelectNodeData;
174
+ level: number;
175
+ index: number;
176
+ parentKey?: string;
177
+ pathKeys: string[];
178
+ childrenKeys: string[];
179
+ siblingIndex: number;
180
+ siblingCount: number;
181
+ isLeaf: boolean;
182
+ disabled: boolean;
183
+ checkable: boolean;
184
+ disableCheckbox: boolean;
185
+ selectable: boolean;
186
+ loading: boolean;
187
+ }
188
+ /**
189
+ * @zh 树节点插槽参数
190
+ * @en Tree node slot props
191
+ */
192
+ export interface TreeSelectNodeSlotProps {
193
+ node: TreeSelectNodeData;
194
+ value: TreeSelectKey;
195
+ title: string;
196
+ level: number;
197
+ checked: boolean;
198
+ halfChecked: boolean;
199
+ selected: boolean;
200
+ expanded: boolean;
201
+ disabled: boolean;
202
+ isLeaf: boolean;
203
+ }
@@ -0,0 +1,64 @@
1
+ import { TreeSelectFilterNode, TreeSelectKey, TreeSelectNodeData, TreeSelectNodeInfo, TreeSelectValue } from './interface';
2
+ export declare const DEFAULT_FIELD_NAMES: {
3
+ key: string;
4
+ title: string;
5
+ children: string;
6
+ disabled: string;
7
+ checkable: string;
8
+ disableCheckbox: string;
9
+ selectable: string;
10
+ isLeaf: string;
11
+ icon: string;
12
+ };
13
+ export type MergedFieldNames = typeof DEFAULT_FIELD_NAMES;
14
+ /** 归一化键值:区分数字与字符串键,避免 `1` 和 `'1'` 互相覆盖。 */
15
+ export declare const normalizeKey: (key: TreeSelectKey) => string;
16
+ export declare const getValueFromKey: (key: string) => TreeSelectKey;
17
+ /** 提取选中项中的键值,兼容 labelInValue 对象。 */
18
+ export declare const getKeyFromValue: (value: TreeSelectValue) => TreeSelectKey | undefined;
19
+ export declare const isValidKey: (key: unknown) => key is TreeSelectKey;
20
+ export interface TreeBuildResult {
21
+ nodeMap: Map<string, TreeSelectNodeInfo>;
22
+ orderedNodes: TreeSelectNodeInfo[];
23
+ rootKeys: string[];
24
+ }
25
+ export declare const buildTree: (data: TreeSelectNodeData[], fieldNames: MergedFieldNames) => TreeBuildResult;
26
+ /** 参与父子联动的节点:可勾选且未禁用。 */
27
+ export declare const isCascadeCheckable: (info: TreeSelectNodeInfo) => boolean;
28
+ /** 某个节点下参与级联判定的直接子节点。 */
29
+ export declare const getEligibleChildren: (info: TreeSelectNodeInfo, nodeMap: Map<string, TreeSelectNodeInfo>) => TreeSelectNodeInfo[];
30
+ export declare const getDescendantKeys: (nodeMap: Map<string, TreeSelectNodeInfo>, info: TreeSelectNodeInfo, predicate?: (node: TreeSelectNodeInfo) => boolean) => string[];
31
+ /** 向下联动时的键集合:自身 + 可联动后代。 */
32
+ export declare const getCascadeKeys: (nodeMap: Map<string, TreeSelectNodeInfo>, info: TreeSelectNodeInfo) => string[];
33
+ export interface TreeSelectCheckState {
34
+ checked: Set<string>;
35
+ halfChecked: Set<string>;
36
+ }
37
+ /**
38
+ * 由公开选中值推导完整勾选状态。
39
+ * 非严格模式下,父键会向下补齐可联动后代;随后自底向上重算半选。
40
+ */
41
+ export declare const conductCheckState: (checkedKeys: string[], nodeMap: Map<string, TreeSelectNodeInfo>, orderedNodes: TreeSelectNodeInfo[], strict: boolean) => TreeSelectCheckState;
42
+ /** 切换单个节点的勾选,并向上联动父级状态。 */
43
+ export declare const toggleCheckState: (current: TreeSelectCheckState, info: TreeSelectNodeInfo, nextChecked: boolean, nodeMap: Map<string, TreeSelectNodeInfo>, strict: boolean) => TreeSelectCheckState;
44
+ /** 按选中策略过滤公开值:parent 保留最高层已选节点,child 保留最底层已选节点。 */
45
+ export declare const filterCheckedKeysByStrategy: (state: TreeSelectCheckState, strategy: "all" | "parent" | "child", orderedNodes: TreeSelectNodeInfo[], nodeMap: Map<string, TreeSelectNodeInfo>) => string[];
46
+ export interface TreeFilterResult {
47
+ keptKeys: Set<string>;
48
+ matchedKeys: Set<string>;
49
+ query: string;
50
+ }
51
+ /** 过滤树:命中节点保留自身与全部后代,并保留其所有祖先。 */
52
+ export declare const filterTreeNodes: (orderedNodes: TreeSelectNodeInfo[], nodeMap: Map<string, TreeSelectNodeInfo>, inputValue: string, filterTreeNode: boolean | TreeSelectFilterNode) => TreeFilterResult | null;
53
+ export type TreeSelectFlatNode = TreeSelectNodeInfo & {
54
+ lastChild: boolean;
55
+ };
56
+ /** 展开状态下的可见节点;过滤时展示命中集合及其祖先。 */
57
+ export declare const getVisibleNodes: (orderedNodes: TreeSelectNodeInfo[], expandedKeys: Set<string>, filterResult: TreeFilterResult | null) => TreeSelectFlatNode[];
58
+ /** 把标题按查询词切分为高亮片段。 */
59
+ export declare const splitHighlightText: (title: string, query: string) => {
60
+ text: string;
61
+ match: boolean;
62
+ }[];
63
+ /** 由显示值解析节点键列表。 */
64
+ export declare const getKeysFromValues: (values: TreeSelectValue[]) => TreeSelectKey[];
@@ -104,6 +104,9 @@ const r = {
104
104
  "--x-time-range-selector-color-default": "var(--x-color-primary-6)",
105
105
  "--x-timeline-dot-hollow-shadow": "0 0 0 1px color-mix( in srgb, var(--x-color-primary-solid) 10%, var(--x-color-transparent) )",
106
106
  "--x-timeline-dot-shadow": "0 0 0 1px color-mix(in srgb, var(--x-color-primary-solid) 8%, var(--x-color-transparent))",
107
+ "--x-tree-select-highlight-color-text": "var(--x-color-primary)",
108
+ "--x-tree-select-node-color-bg_selected": "var(--x-color-primary-light-1)",
109
+ "--x-tree-select-node-color-text_selected": "var(--x-color-primary)",
107
110
  "--x-upload-color-border-hover": "var(--x-color-primary)"
108
111
  },
109
112
  success: {
@@ -0,0 +1,6 @@
1
+ function r(e, n, t) {
2
+ return e;
3
+ }
4
+ export {
5
+ r as inheritComponentType
6
+ };
@@ -1,26 +1,26 @@
1
- import { defineComponent as e, computed as c } from "vue";
1
+ import { defineComponent as i, computed as c } from "vue";
2
2
  import l from "../../../icons/animation/animation-loading.js";
3
3
  import t from "../../../icons/default/check-circle-fill.js";
4
- import n from "../../../icons/default/exclamation-circle-fill.js";
5
- import r from "../../../icons/default/close-circle-fill.js";
6
- import { getClassNameMixin as m } from "../../../_utils/config.js";
7
- const k = e({
4
+ import r from "../../../icons/default/exclamation-circle-fill.js";
5
+ import m from "../../../icons/default/close-circle-fill.js";
6
+ import { getClassNameMixin as n } from "../../../_utils/config.js";
7
+ const k = i({
8
8
  name: "FeedbackIcon",
9
9
  components: {
10
10
  IconLoading: l,
11
11
  IconCheckCircleFill: t,
12
- IconExclamationCircleFill: n,
13
- IconCloseCircleFill: r
12
+ IconExclamationCircleFill: r,
13
+ IconCloseCircleFill: m
14
14
  },
15
15
  props: {
16
16
  type: {
17
17
  type: String
18
18
  }
19
19
  },
20
- setup(i) {
21
- const o = m("feedback-icon");
20
+ setup(e) {
21
+ const o = n("feedback-icon");
22
22
  return {
23
- cls: c(() => [o.block, o.modifier(`status-${i.type}`)])
23
+ cls: c(() => [o.block, o.modifier(`status-${e.type}`)])
24
24
  };
25
25
  }
26
26
  });
@@ -26,7 +26,7 @@ const o = (e) => {
26
26
  emits: ["click"],
27
27
  setup(e, {
28
28
  slots: n,
29
- emit: A
29
+ emit: T
30
30
  }) {
31
31
  const v = E(), a = M(_, void 0), {
32
32
  mergedSize: F
@@ -35,24 +35,24 @@ const o = (e) => {
35
35
  }), u = R({
36
36
  clicked: !1,
37
37
  isDebounce: !1
38
- }), i = U("button"), I = (t) => t.replace(/[A-Z]/g, (c) => `-${c.toLowerCase()}`), f = (t) => {
38
+ }), i = U("button"), A = (t) => t.replace(/[A-Z]/g, (c) => `-${c.toLowerCase()}`), f = (t) => {
39
39
  const c = (v == null ? void 0 : v.vnode.props) ?? {};
40
- return Object.prototype.hasOwnProperty.call(c, t) || Object.prototype.hasOwnProperty.call(c, I(t));
41
- }, m = r(() => f("type") ? e.type : (a == null ? void 0 : a.type) ?? e.type), w = r(() => f("size") ? e.size : (a == null ? void 0 : a.size) ?? F.value), D = r(() => f("status") ? e.status : (a == null ? void 0 : a.status) ?? e.status), y = r(() => f("shape") ? e.shape : (a == null ? void 0 : a.shape) ?? e.shape), s = r(() => f("disabled") ? e.disabled : (a == null ? void 0 : a.disabled) ?? e.disabled), L = r(() => [i.block, m.value && m.value !== "default" && i.modifier(m.value), w.value && i.modifier(w.value), D.value && i.modifier(D.value), s.value && i.is("disabled"), e.block && i.modifier("block"), e.plain && i.modifier("plain"), y.value && i.modifier(y.value), e.link && i.modifier("link"), !e.border && i.modifier("hide-border"), l.value && i.modifier("loading"), e.narrow && i.modifier("narrow")]), N = () => {
40
+ return Object.prototype.hasOwnProperty.call(c, t) || Object.prototype.hasOwnProperty.call(c, A(t));
41
+ }, s = r(() => f("type") ? e.type : (a == null ? void 0 : a.type) ?? e.type), w = r(() => f("size") ? e.size : (a == null ? void 0 : a.size) ?? F.value), D = r(() => f("status") ? e.status : (a == null ? void 0 : a.status) ?? e.status), y = r(() => f("shape") ? e.shape : (a == null ? void 0 : a.shape) ?? e.shape), m = r(() => f("disabled") ? e.disabled : (a == null ? void 0 : a.disabled) ?? e.disabled), L = r(() => [i.block, s.value && s.value !== "default" && i.modifier(s.value), w.value && i.modifier(w.value), D.value && i.modifier(D.value), m.value && i.is("disabled"), e.block && i.modifier("block"), e.plain && i.modifier("plain"), y.value && i.modifier(y.value), e.link && i.modifier("link"), !e.border && i.modifier("hide-border"), l.value && i.modifier("loading"), e.narrow && i.modifier("narrow")]), N = () => {
42
42
  e.debounce > 0 && !u.isDebounce && (u.isDebounce = !0, setTimeout(() => {
43
43
  u.isDebounce = !1;
44
44
  }, e.debounce));
45
- }, l = r(() => e.loading || u.clicked || u.isDebounce), V = r(() => s.value || l.value || e.link || m.value === "text"), B = (t) => {
45
+ }, l = r(() => e.loading || u.clicked || u.isDebounce), V = r(() => m.value || l.value || e.link || s.value === "text"), B = (t) => {
46
46
  var c;
47
- t.detail > 0 && ((c = t.currentTarget) == null || c.blur()), !(s.value || l.value) && (N(), A("click", t));
47
+ t.detail > 0 && ((c = t.currentTarget) == null || c.blur()), !(m.value || l.value) && (N(), T("click", t));
48
48
  };
49
49
  return () => {
50
- var P, j, O, T;
51
- const t = (P = n.default) == null ? void 0 : P.call(n), c = (j = n.prefix) == null ? void 0 : j.call(n), S = (O = n.icon) == null ? void 0 : O.call(n), x = (T = n.suffix) == null ? void 0 : T.call(n), b = o(t), g = o(c), h = o(S), p = o(x), z = !b && !g && h && !p, k = e.loadingFill || l.value && (y.value === "circle" || z), K = l.value && !k && (b || g || h || p);
50
+ var P, j, I, O;
51
+ const t = (P = n.default) == null ? void 0 : P.call(n), c = (j = n.prefix) == null ? void 0 : j.call(n), S = (I = n.icon) == null ? void 0 : I.call(n), x = (O = n.suffix) == null ? void 0 : O.call(n), b = o(t), g = o(c), h = o(S), p = o(x), z = !b && !g && h && !p, k = e.loadingFill || l.value && (y.value === "circle" || z), K = l.value && !k && (b || g || h || p);
52
52
  return Z(d("button", {
53
53
  class: [L.value, !b && i.modifier("empty-content"), z && i.modifier("only-icon"), k && i.modifier("loading-fill")],
54
54
  type: e.htmlType,
55
- disabled: s.value || l.value,
55
+ disabled: m.value || l.value,
56
56
  "aria-busy": l.value || void 0,
57
57
  onClick: B
58
58
  }, [d("span", {
@@ -3,25 +3,26 @@ import { defineComponent as c, h as k } from "vue";
3
3
  import { generateComponent as e } from "../../_utils/vue-eco.js";
4
4
  import { getComponentPrefix as r } from "../../_utils/config.js";
5
5
  import { getRangePickerType as s } from "./utils.js";
6
- const l = e(r("DatePicker"), n), i = (t, o) => c({
6
+ import { inheritComponentType as P } from "../../_utils/inherit-component-type.js";
7
+ const R = e(r("DatePicker"), n), i = (t, o) => P(c({
7
8
  name: t,
8
9
  inheritAttrs: !1,
9
- setup(a, { attrs: P, slots: m }) {
10
- return () => k(n, { ...P, type: o }, m);
10
+ setup(a, { attrs: m, slots: p }) {
11
+ return () => k(n, { ...m, type: o }, p);
11
12
  }
12
- }), y = e(
13
+ })), C = e(
13
14
  r("MonthPicker"),
14
15
  i("MonthPicker", "month")
15
- ), R = e(
16
+ ), D = e(
16
17
  r("YearPicker"),
17
18
  i("YearPicker", "year")
18
- ), C = e(
19
+ ), M = e(
19
20
  r("QuarterPicker"),
20
21
  i("QuarterPicker", "quarter")
21
- ), D = e(
22
+ ), Q = e(
22
23
  r("WeekPicker"),
23
24
  i("WeekPicker", "week")
24
- ), p = c({
25
+ ), f = c({
25
26
  name: "RangePicker",
26
27
  inheritAttrs: !1,
27
28
  props: {
@@ -41,16 +42,16 @@ const l = e(r("DatePicker"), n), i = (t, o) => c({
41
42
  a
42
43
  );
43
44
  }
44
- }), M = e(
45
+ }), T = e(
45
46
  r("RangePicker"),
46
- p
47
+ P(f)
47
48
  );
48
49
  export {
49
- l as DatePicker,
50
- y as MonthPicker,
51
- C as QuarterPicker,
52
- M as RangePicker,
53
- D as WeekPicker,
54
- R as YearPicker,
55
- l as default
50
+ R as DatePicker,
51
+ C as MonthPicker,
52
+ M as QuarterPicker,
53
+ T as RangePicker,
54
+ Q as WeekPicker,
55
+ D as YearPicker,
56
+ R as default
56
57
  };
@@ -1,10 +1,10 @@
1
1
  import $ from "./Drawer.vue2.js";
2
- import { resolveComponent as f, openBlock as a, createBlock as b, Teleport as N, withDirectives as k, createElementBlock as d, mergeProps as m, createVNode as t, Transition as g, withCtx as n, withModifiers as S, normalizeClass as s, vShow as u, createCommentVNode as i, createElementVNode as r, renderSlot as p, toDisplayString as y, normalizeStyle as T, createTextVNode as w } from "vue";
2
+ import { resolveComponent as f, openBlock as a, createBlock as g, Teleport as N, withDirectives as k, createElementBlock as d, mergeProps as m, createVNode as t, Transition as b, withCtx as n, withModifiers as S, normalizeClass as s, vShow as u, createCommentVNode as i, createElementVNode as r, renderSlot as p, toDisplayString as y, normalizeStyle as T, createTextVNode as w } from "vue";
3
3
  import B from "../../../_virtual/_plugin-vue_export-helper.js";
4
4
  const V = ["data-theme"], c = ["aria-modal"], O = ["id"], A = ["aria-label"];
5
5
  function K(e, o, M, j, z, E) {
6
6
  const h = f("Scrollbar"), C = f("Button"), v = f("Space");
7
- return a(), b(N, {
7
+ return a(), g(N, {
8
8
  to: e.teleportContainer,
9
9
  disabled: e.disabled || !e.teleportContainer
10
10
  }, [
@@ -15,7 +15,7 @@ function K(e, o, M, j, z, E) {
15
15
  style: [e.drawerStyle, e.$attrs.style],
16
16
  "data-theme": e.popupThemeName
17
17
  }, e.rootAttrs()), [
18
- t(g, {
18
+ t(b, {
19
19
  name: "x-fade-in-standard",
20
20
  appear: ""
21
21
  }, {
@@ -30,7 +30,7 @@ function K(e, o, M, j, z, E) {
30
30
  ]),
31
31
  _: 1
32
32
  }),
33
- t(g, {
33
+ t(b, {
34
34
  name: `x-slide-${e.placement}`,
35
35
  appear: "",
36
36
  onAfterEnter: e.afterEnter,
@@ -62,7 +62,7 @@ function K(e, o, M, j, z, E) {
62
62
  class: s([e.className.element("body"), e.bodyClass]),
63
63
  style: T(e.mergedBodyStyle)
64
64
  }, [
65
- t(h, { style: { overflow: "auto" } }, {
65
+ t(h, { style: { height: "100%", overflow: "auto" } }, {
66
66
  default: n(() => [
67
67
  p(e.$slots, "default")
68
68
  ]),
@@ -90,7 +90,7 @@ function K(e, o, M, j, z, E) {
90
90
  ]),
91
91
  _: 1
92
92
  }, 16, ["loading", "onClick"]),
93
- e.hideCancel ? i("", !0) : (a(), b(C, m({
93
+ e.hideCancel ? i("", !0) : (a(), g(C, m({
94
94
  key: 0,
95
95
  loading: e.loadingObj.cancel,
96
96
  size: "small"
@@ -1,14 +1,15 @@
1
- import p from "./Input.js";
2
- import r from "./InputSearch.js";
3
- import n from "./InputPassword.vue.js";
1
+ import r from "./Input.js";
2
+ import n from "./InputSearch.js";
3
+ import m from "./InputPassword.vue.js";
4
4
  import u from "./InputGroup.vue.js";
5
- import { generateComponent as t } from "../../_utils/vue-eco.js";
6
- import { getComponentPrefix as o } from "../../_utils/config.js";
7
- const c = t(o("Input"), p), i = t(o("InputSearch"), r), d = t(o("InputPassword"), n), P = t(o("InputGroup"), u);
5
+ import { generateComponent as o } from "../../_utils/vue-eco.js";
6
+ import { getComponentPrefix as t } from "../../_utils/config.js";
7
+ import { inheritComponentType as p } from "../../_utils/inherit-component-type.js";
8
+ const d = o(t("Input"), r), h = o(t("InputSearch"), p(n)), P = o(t("InputPassword"), p(m)), w = o(t("InputGroup"), u);
8
9
  export {
9
- c as Input,
10
- P as InputGroup,
11
- d as InputPassword,
12
- i as InputSearch,
13
- c as default
10
+ d as Input,
11
+ w as InputGroup,
12
+ P as InputPassword,
13
+ h as InputSearch,
14
+ d as default
14
15
  };
@@ -176,24 +176,24 @@ const ne = $({
176
176
  * @en The icon on the button when closed
177
177
  * @slot unchecked-icon
178
178
  */
179
- setup(e, { emit: n, expose: b, slots: g, attrs: S }) {
179
+ setup(e, { emit: n, expose: b, slots: y, attrs: S }) {
180
180
  const { disabled: w, size: x, modelValue: B } = q(e), c = Y("switch"), {
181
181
  formItemCtx: z,
182
182
  mergedDisabled: o,
183
- mergedSize: A,
183
+ mergedSize: F,
184
184
  eventHandlers: s
185
185
  } = J({
186
186
  disabled: w,
187
187
  size: x
188
- }), F = O(z, () => S, { required: !1 }), { mergedSize: y } = P(A), d = k(e.defaultChecked ? e.checkedValue : e.uncheckedValue), a = r(
188
+ }), N = O(z, () => S, { required: !1 }), { mergedSize: g } = P(F), d = k(e.defaultChecked ? e.checkedValue : e.uncheckedValue), a = r(
189
189
  () => (e.modelValue ?? d.value) === e.checkedValue
190
190
  ), m = k(!1);
191
191
  let v = !1;
192
192
  H(() => {
193
193
  v = !0;
194
194
  });
195
- const f = r(() => m.value || e.loading), h = k(), N = r(
196
- () => e.type !== "line" && y.value !== "mini" && (!!e.checkedText || !!e.uncheckedText || !!g.checked || !!g.unchecked)
195
+ const f = r(() => m.value || e.loading), h = k(), R = r(
196
+ () => e.type !== "line" && g.value !== "mini" && (!!e.checkedText || !!e.uncheckedText || !!y.checked || !!y.unchecked)
197
197
  ), C = (t, l) => {
198
198
  var u, i;
199
199
  d.value = t ? e.checkedValue : e.uncheckedValue, n("update:modelValue", d.value), n("change", d.value, l), (i = (u = s.value) == null ? void 0 : u.onChange) == null || i.call(u, l);
@@ -211,29 +211,29 @@ const ne = $({
211
211
  }
212
212
  } else
213
213
  C(t, l);
214
- }, R = async (t) => {
214
+ }, T = async (t) => {
215
215
  const l = a.value ? e.uncheckedValue : e.checkedValue;
216
216
  n("click", l, t), await V(!a.value, t);
217
- }, T = async (t) => {
217
+ }, A = async (t) => {
218
218
  if (t.key !== "ArrowLeft" && t.key !== "Left" && t.key !== "ArrowRight" && t.key !== "Right")
219
219
  return;
220
220
  t.preventDefault();
221
221
  const l = t.key === "ArrowRight" || t.key === "Right";
222
222
  l !== a.value && await V(l, t);
223
- }, L = (t) => {
223
+ }, _ = (t) => {
224
224
  var l, u;
225
225
  n("focus", t), (u = (l = s.value) == null ? void 0 : l.onFocus) == null || u.call(l, t);
226
- }, _ = (t) => {
226
+ }, I = (t) => {
227
227
  var l, u;
228
228
  n("blur", t), (u = (l = s.value) == null ? void 0 : l.onBlur) == null || u.call(l, t);
229
229
  };
230
230
  K(B, (t) => {
231
231
  (Q(t) || W(t)) && (d.value = e.uncheckedValue);
232
232
  });
233
- const I = r(() => [
233
+ const L = r(() => [
234
234
  c.block,
235
235
  c.modifier(`type-${e.type}`),
236
- c.modifier(`size-${y.value}`),
236
+ c.modifier(`size-${g.value}`),
237
237
  {
238
238
  [c.modifier("checked")]: a.value,
239
239
  [c.modifier("disabled")]: o.value,
@@ -261,19 +261,19 @@ const ne = $({
261
261
  focus: M,
262
262
  blur: U
263
263
  }), {
264
- formControlAttrs: F,
264
+ formControlAttrs: N,
265
265
  className: c,
266
- cls: I,
266
+ cls: L,
267
267
  switchRef: h,
268
268
  mergedDisabled: o,
269
269
  buttonStyle: D,
270
270
  computedCheck: a,
271
271
  computedLoading: f,
272
- showText: N,
273
- handleClick: R,
274
- handleKeydown: T,
275
- handleFocus: L,
276
- handleBlur: _
272
+ showText: R,
273
+ handleClick: T,
274
+ handleKeydown: A,
275
+ handleFocus: _,
276
+ handleBlur: I
277
277
  };
278
278
  }
279
279
  });