@sdata/web-vue 3.18.0 → 3.19.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 (259) hide show
  1. package/dist/sd.css +478 -0
  2. package/dist/sd.min.css +2 -2
  3. package/es/_components/icon-hover.vue.d.ts +1 -1
  4. package/es/_components/input-label/input-label.d.ts +13 -1
  5. package/es/_components/input-label/input-label.js +35 -5
  6. package/es/_components/input-label/style/index.css +6 -0
  7. package/es/_components/input-label/style/input-label.scss +8 -0
  8. package/es/_components/picker/input-range.vue.d.ts +24 -1
  9. package/es/_components/picker/input-range.vue_vue_type_script_setup_true_lang.js +42 -6
  10. package/es/_components/picker/input.vue.d.ts +24 -1
  11. package/es/_components/picker/input.vue_vue_type_script_setup_true_lang.js +31 -4
  12. package/es/_components/picker/style/index.scss +8 -0
  13. package/es/_components/select-view/select-view.d.ts +15 -3
  14. package/es/_components/select-view/select-view.js +10 -1
  15. package/es/_components/select-view/style/index.css +12 -0
  16. package/es/_components/virtual-list/virtual-list.vue.d.ts +6 -6
  17. package/es/_hooks/use-fit-width.d.ts +22 -0
  18. package/es/_hooks/use-fit-width.js +76 -0
  19. package/es/_hooks/use-form-item.d.ts +1 -1
  20. package/es/_hooks/use-size.d.ts +1 -1
  21. package/es/anchor/anchor.vue.d.ts +1 -1
  22. package/es/anchor/index.d.ts +3 -3
  23. package/es/auto-complete/auto-complete.d.ts +20 -2
  24. package/es/auto-complete/auto-complete.js +18 -0
  25. package/es/auto-complete/index.d.ts +36 -6
  26. package/es/basic-crud-table/basic-crud-table.vue.d.ts +2 -2
  27. package/es/basic-crud-table/index.d.ts +5 -5
  28. package/es/button/button.vue.d.ts +2 -2
  29. package/es/button/index.d.ts +6 -6
  30. package/es/card/card.d.ts +3 -3
  31. package/es/card/index.d.ts +6 -6
  32. package/es/carousel/carousel-indicator.vue.d.ts +1 -1
  33. package/es/cascader/base-cascader-panel.d.ts +1 -1
  34. package/es/cascader/cascader-option.d.ts +1 -1
  35. package/es/cascader/cascader-panel.vue.d.ts +1 -1
  36. package/es/cascader/cascader-search-panel.d.ts +1 -1
  37. package/es/cascader/cascader.vue.d.ts +7 -5
  38. package/es/cascader/cascader.vue_vue_type_script_setup_true_lang.js +12 -0
  39. package/es/cascader/types.d.ts +2 -1
  40. package/es/checkbox/checkbox.d.ts +3 -3
  41. package/es/checkbox/index.d.ts +6 -6
  42. package/es/collapse/collapse-item.d.ts +3 -3
  43. package/es/collapse/index.d.ts +3 -3
  44. package/es/color-picker/color-picker.d.ts +2 -2
  45. package/es/color-picker/index.d.ts +6 -6
  46. package/es/components.d.ts +4 -0
  47. package/es/config-provider/config-provider.vue.d.ts +1 -1
  48. package/es/config-provider/index.d.ts +3 -3
  49. package/es/date-picker/index.d.ts +87 -23
  50. package/es/date-picker/interface.d.ts +2 -1
  51. package/es/date-picker/picker-panel.vue.d.ts +1 -1
  52. package/es/date-picker/picker.vue.d.ts +39 -17
  53. package/es/date-picker/picker.vue_vue_type_script_setup_true_lang.js +30 -1
  54. package/es/date-picker/pickers/date-picker.d.ts +18 -0
  55. package/es/date-picker/pickers/date-picker.js +16 -0
  56. package/es/date-picker/range-picker-panel.vue.d.ts +1 -1
  57. package/es/date-picker/range-picker.vue.d.ts +39 -17
  58. package/es/date-picker/range-picker.vue_vue_type_script_setup_true_lang.js +27 -1
  59. package/es/date-picker/style/index.css +6 -0
  60. package/es/descriptions/descriptions.d.ts +3 -3
  61. package/es/descriptions/index.d.ts +9 -9
  62. package/es/divider/divider.d.ts +1 -1
  63. package/es/divider/index.d.ts +3 -3
  64. package/es/drawer/drawer.vue.d.ts +4 -4
  65. package/es/drawer/index.d.ts +11 -11
  66. package/es/dropdown/dropdown-button.vue.d.ts +2 -2
  67. package/es/dropdown/dropdown-option.vue.d.ts +1 -1
  68. package/es/dropdown/dropdown-submenu.vue.d.ts +2 -2
  69. package/es/dropdown/dropdown.vue.d.ts +1 -1
  70. package/es/dropdown/index.d.ts +21 -21
  71. package/es/ellipsis/ellipsis.vue.d.ts +1 -1
  72. package/es/ellipsis/index.d.ts +6 -6
  73. package/es/ellipsis/performant-ellipsis.vue.d.ts +1 -1
  74. package/es/form/form-item.vue.d.ts +1 -1
  75. package/es/form/form.vue.d.ts +1 -1
  76. package/es/form/index.d.ts +9 -9
  77. package/es/grid/grid-row.vue.d.ts +3 -3
  78. package/es/grid/index.d.ts +9 -9
  79. package/es/icon/icon-arrow-up/icon-arrow-up.js +5 -0
  80. package/es/icon/icon-arrow-up/icon-arrow-up.vue_vue_type_script_setup_true_lang.js +52 -0
  81. package/es/icon/icon-arrow-up/index.js +9 -0
  82. package/es/icon/icon-mute/icon-mute.js +5 -0
  83. package/es/icon/icon-mute/icon-mute.vue_vue_type_script_setup_true_lang.js +52 -0
  84. package/es/icon/icon-mute/index.js +9 -0
  85. package/es/icon/icon-voice/icon-voice.js +5 -0
  86. package/es/icon/icon-voice/icon-voice.vue_vue_type_script_setup_true_lang.js +52 -0
  87. package/es/icon/icon-voice/index.js +9 -0
  88. package/es/image/preview-action.d.ts +6 -6
  89. package/es/image/preview-group.vue.d.ts +1 -1
  90. package/es/index.css +478 -0
  91. package/es/index.d.ts +5 -0
  92. package/es/index.js +5 -1
  93. package/es/index.scss +2 -0
  94. package/es/input/index.d.ts +99 -6
  95. package/es/input/input-password.vue.d.ts +18 -0
  96. package/es/input/input-password.vue_vue_type_script_setup_true_lang.js +24 -2
  97. package/es/input/input-search.d.ts +18 -0
  98. package/es/input/input-search.js +20 -2
  99. package/es/input/input.d.ts +29 -2
  100. package/es/input/input.js +45 -3
  101. package/es/input/style/index.css +16 -0
  102. package/es/input/style/index.scss +21 -0
  103. package/es/input-number/index.d.ts +36 -6
  104. package/es/input-number/input-number.d.ts +20 -2
  105. package/es/input-number/input-number.js +19 -0
  106. package/es/input-tag/index.d.ts +36 -6
  107. package/es/input-tag/input-tag.d.ts +20 -2
  108. package/es/input-tag/input-tag.js +35 -4
  109. package/es/input-tag/style/index.css +6 -0
  110. package/es/input-tag/style/input-tag.scss +8 -0
  111. package/es/kv-list/index.d.ts +72 -32
  112. package/es/link/index.d.ts +6 -6
  113. package/es/link/link.vue.d.ts +2 -2
  114. package/es/locale/interface.d.ts +22 -0
  115. package/es/locale/lang/ar-eg.js +21 -1
  116. package/es/locale/lang/de-de.js +21 -1
  117. package/es/locale/lang/en-us.js +21 -1
  118. package/es/locale/lang/es-es.js +21 -1
  119. package/es/locale/lang/fr-fr.js +21 -1
  120. package/es/locale/lang/id-id.js +21 -1
  121. package/es/locale/lang/it-it.js +21 -1
  122. package/es/locale/lang/ja-jp.js +21 -1
  123. package/es/locale/lang/km-kh.js +21 -1
  124. package/es/locale/lang/ko-kr.js +21 -1
  125. package/es/locale/lang/ms-my.js +21 -1
  126. package/es/locale/lang/nl-nl.js +21 -1
  127. package/es/locale/lang/pt-pt.js +21 -1
  128. package/es/locale/lang/ru-ru.js +21 -1
  129. package/es/locale/lang/th-th.js +21 -1
  130. package/es/locale/lang/vi-vn.js +21 -1
  131. package/es/locale/lang/zh-cn.js +21 -1
  132. package/es/locale/lang/zh-tw.js +21 -1
  133. package/es/mention/index.d.ts +39 -9
  134. package/es/mention/mention.d.ts +21 -3
  135. package/es/mention/mention.js +24 -1
  136. package/es/mention/style/index.css +6 -0
  137. package/es/mention/style/index.scss +8 -0
  138. package/es/menu/item.d.ts +1 -1
  139. package/es/message/message-list.d.ts +1 -1
  140. package/es/modal/index.d.ts +9 -9
  141. package/es/modal/modal.vue.d.ts +3 -3
  142. package/es/popconfirm/index.d.ts +3 -3
  143. package/es/popconfirm/popconfirm.vue.d.ts +1 -1
  144. package/es/popover/index.d.ts +6 -6
  145. package/es/popover/popover.vue.d.ts +2 -2
  146. package/es/progress/circle.vue.d.ts +1 -1
  147. package/es/progress/line.vue.d.ts +1 -1
  148. package/es/qr-code/index.d.ts +15 -15
  149. package/es/qr-code/qr-code.vue.d.ts +5 -5
  150. package/es/radio/index.d.ts +6 -6
  151. package/es/radio/radio.d.ts +3 -3
  152. package/es/rate/index.d.ts +3 -3
  153. package/es/rate/rate.d.ts +1 -1
  154. package/es/resize-box/index.d.ts +5 -5
  155. package/es/resize-box/resize-box.vue.d.ts +3 -3
  156. package/es/rich-text-editor/built-in-components.d.ts +5 -0
  157. package/es/rich-text-editor/built-in-components.js +6 -0
  158. package/es/rich-text-editor/index.d.ts +195 -0
  159. package/es/rich-text-editor/index.js +12 -0
  160. package/es/rich-text-editor/nodes/inline-component-node.d.ts +30 -0
  161. package/es/rich-text-editor/nodes/inline-component-node.js +86 -0
  162. package/es/rich-text-editor/rich-text-editor.js +5 -0
  163. package/es/rich-text-editor/rich-text-editor.vue.d.ts +76 -0
  164. package/es/rich-text-editor/rich-text-editor.vue_vue_type_script_setup_true_lang.js +630 -0
  165. package/es/rich-text-editor/rich-text-node-renderer.js +5 -0
  166. package/es/rich-text-editor/rich-text-node-renderer.vue.d.ts +28 -0
  167. package/es/rich-text-editor/rich-text-node-renderer.vue_vue_type_script_setup_true_lang.js +133 -0
  168. package/es/rich-text-editor/style/css.js +2 -0
  169. package/es/rich-text-editor/style/index.css +164 -0
  170. package/es/rich-text-editor/style/index.d.ts +2 -0
  171. package/es/rich-text-editor/style/index.js +2 -0
  172. package/es/rich-text-editor/style/index.scss +193 -0
  173. package/es/rich-text-editor/style/token.scss +36 -0
  174. package/es/rich-text-editor/types.d.ts +148 -0
  175. package/es/sd-vue.js +6 -0
  176. package/es/select/index.d.ts +108 -54
  177. package/es/select/interface.d.ts +2 -1
  178. package/es/select/select.d.ts +55 -25
  179. package/es/select/select.js +18 -0
  180. package/es/sender/context.d.ts +8 -0
  181. package/es/sender/context.js +4 -0
  182. package/es/sender/index.d.ts +119 -0
  183. package/es/sender/index.js +20 -0
  184. package/es/sender/sender-header.js +5 -0
  185. package/es/sender/sender-header.vue.d.ts +28 -0
  186. package/es/sender/sender-header.vue_vue_type_script_setup_true_lang.js +127 -0
  187. package/es/sender/sender-switch.js +5 -0
  188. package/es/sender/sender-switch.vue.d.ts +32 -0
  189. package/es/sender/sender-switch.vue_vue_type_script_setup_true_lang.js +95 -0
  190. package/es/sender/sender.js +5 -0
  191. package/es/sender/sender.vue_vue_type_script_setup_true_lang.js +871 -0
  192. package/es/sender/style/css.js +3 -0
  193. package/es/sender/style/index.css +290 -0
  194. package/es/sender/style/index.d.ts +3 -0
  195. package/es/sender/style/index.js +3 -0
  196. package/es/sender/style/index.scss +346 -0
  197. package/es/sender/style/token.scss +43 -0
  198. package/es/sender/types.d.ts +171 -0
  199. package/es/sender/use-speech.d.ts +9 -0
  200. package/es/sender/use-speech.js +120 -0
  201. package/es/slider/index.d.ts +3 -3
  202. package/es/slider/slider-input.vue.d.ts +1 -1
  203. package/es/slider/slider.vue.d.ts +1 -1
  204. package/es/space/index.d.ts +9 -9
  205. package/es/space/space.d.ts +2 -2
  206. package/es/spin/index.d.ts +3 -3
  207. package/es/spin/spin.d.ts +1 -1
  208. package/es/statistic/index.d.ts +3 -3
  209. package/es/statistic/statistic.vue.d.ts +1 -1
  210. package/es/steps/index.d.ts +5 -5
  211. package/es/steps/step.vue.d.ts +2 -2
  212. package/es/steps/steps.vue.d.ts +1 -1
  213. package/es/table/index.d.ts +17 -17
  214. package/es/table/table-column.d.ts +1 -1
  215. package/es/table/table-operation-td.d.ts +12 -12
  216. package/es/table/table-td.d.ts +2 -2
  217. package/es/table/table.d.ts +5 -5
  218. package/es/tabs/index.d.ts +12 -12
  219. package/es/tabs/tabs-nav.d.ts +1 -1
  220. package/es/tabs/tabs.d.ts +4 -4
  221. package/es/tag/index.d.ts +6 -6
  222. package/es/tag/tag.vue.d.ts +2 -2
  223. package/es/textarea/index.d.ts +38 -8
  224. package/es/textarea/style/index.css +6 -0
  225. package/es/textarea/style/index.scss +8 -0
  226. package/es/textarea/textarea.vue.d.ts +21 -3
  227. package/es/textarea/textarea.vue_vue_type_script_setup_true_lang.js +36 -3
  228. package/es/time-picker/index.d.ts +36 -6
  229. package/es/time-picker/interface.d.ts +2 -1
  230. package/es/time-picker/range-panel.js +58 -0
  231. package/es/time-picker/time-picker.vue.d.ts +20 -2
  232. package/es/time-picker/time-picker.vue_vue_type_script_setup_true_lang.js +30 -1
  233. package/es/timeline/index.d.ts +6 -6
  234. package/es/timeline/timeline.d.ts +3 -3
  235. package/es/tooltip/index.d.ts +6 -6
  236. package/es/tooltip/tooltip.vue.d.ts +2 -2
  237. package/es/tour/index.d.ts +3 -3
  238. package/es/tour/tour.vue.d.ts +1 -1
  239. package/es/transfer/index.d.ts +3 -3
  240. package/es/transfer/transfer.vue.d.ts +1 -1
  241. package/es/tree/tree.vue.d.ts +4 -4
  242. package/es/tree-select/interface.d.ts +2 -1
  243. package/es/tree-select/tree-select.vue.d.ts +25 -7
  244. package/es/tree-select/tree-select.vue_vue_type_script_setup_true_lang.js +20 -0
  245. package/es/trigger/index.d.ts +12 -12
  246. package/es/trigger/trigger.d.ts +4 -4
  247. package/es/typography/base.d.ts +4 -4
  248. package/es/typography/edit-content.vue.d.ts +2 -2
  249. package/es/upload/index.d.ts +6 -6
  250. package/es/upload/upload-button.d.ts +1 -1
  251. package/es/upload/upload.d.ts +2 -2
  252. package/es/verification-code/index.d.ts +3 -3
  253. package/es/verification-code/verification-code.d.ts +1 -1
  254. package/es/watermark/index.d.ts +3 -3
  255. package/es/watermark/watermark.d.ts +1 -1
  256. package/json/vetur-attributes.json +233 -0
  257. package/json/vetur-tags.json +83 -3
  258. package/json/web-types.json +535 -2
  259. package/package.json +10 -1
@@ -46,6 +46,14 @@ declare const InputNumber: {
46
46
  type: FunctionConstructor;
47
47
  };
48
48
  placeholder: StringConstructor;
49
+ fitWidth: {
50
+ type: BooleanConstructor;
51
+ default: boolean;
52
+ };
53
+ maxWFull: {
54
+ type: BooleanConstructor;
55
+ default: boolean;
56
+ };
49
57
  hideButton: {
50
58
  type: BooleanConstructor;
51
59
  default: boolean;
@@ -69,8 +77,8 @@ declare const InputNumber: {
69
77
  type: ObjectConstructor;
70
78
  };
71
79
  }>> & Readonly<{
72
- onFocus?: ((_ev: FocusEvent) => any) | undefined;
73
80
  onClear?: ((_ev: Event) => any) | undefined;
81
+ onFocus?: ((_ev: FocusEvent) => any) | undefined;
74
82
  onBlur?: ((_ev: FocusEvent) => any) | undefined;
75
83
  onChange?: ((_value: string | number | null | undefined, _ev: Event) => any) | undefined;
76
84
  onInput?: ((_value: string | number | null | undefined, _inputValue: string, _ev: Event) => any) | undefined;
@@ -91,10 +99,12 @@ declare const InputNumber: {
91
99
  input: (_value: string | number | null | undefined, _inputValue: string, _ev: Event) => true;
92
100
  keydown: (_ev: KeyboardEvent) => true;
93
101
  }, import("vue").PublicProps, {
102
+ disabled: boolean;
94
103
  error: boolean;
95
104
  readonly: string | boolean;
96
- disabled: boolean;
97
105
  allowClear: boolean;
106
+ fitWidth: boolean;
107
+ maxWFull: boolean;
98
108
  max: number;
99
109
  mode: "embed" | "button";
100
110
  step: number;
@@ -147,6 +157,14 @@ declare const InputNumber: {
147
157
  type: FunctionConstructor;
148
158
  };
149
159
  placeholder: StringConstructor;
160
+ fitWidth: {
161
+ type: BooleanConstructor;
162
+ default: boolean;
163
+ };
164
+ maxWFull: {
165
+ type: BooleanConstructor;
166
+ default: boolean;
167
+ };
150
168
  hideButton: {
151
169
  type: BooleanConstructor;
152
170
  default: boolean;
@@ -170,8 +188,8 @@ declare const InputNumber: {
170
188
  type: ObjectConstructor;
171
189
  };
172
190
  }>> & Readonly<{
173
- onFocus?: ((_ev: FocusEvent) => any) | undefined;
174
191
  onClear?: ((_ev: Event) => any) | undefined;
192
+ onFocus?: ((_ev: FocusEvent) => any) | undefined;
175
193
  onBlur?: ((_ev: FocusEvent) => any) | undefined;
176
194
  onChange?: ((_value: string | number | null | undefined, _ev: Event) => any) | undefined;
177
195
  onInput?: ((_value: string | number | null | undefined, _inputValue: string, _ev: Event) => any) | undefined;
@@ -184,10 +202,12 @@ declare const InputNumber: {
184
202
  focus(): void;
185
203
  blur(): void;
186
204
  }, {
205
+ disabled: boolean;
187
206
  error: boolean;
188
207
  readonly: string | boolean;
189
- disabled: boolean;
190
208
  allowClear: boolean;
209
+ fitWidth: boolean;
210
+ maxWFull: boolean;
191
211
  max: number;
192
212
  mode: "embed" | "button";
193
213
  step: number;
@@ -237,6 +257,14 @@ declare const InputNumber: {
237
257
  type: FunctionConstructor;
238
258
  };
239
259
  placeholder: StringConstructor;
260
+ fitWidth: {
261
+ type: BooleanConstructor;
262
+ default: boolean;
263
+ };
264
+ maxWFull: {
265
+ type: BooleanConstructor;
266
+ default: boolean;
267
+ };
240
268
  hideButton: {
241
269
  type: BooleanConstructor;
242
270
  default: boolean;
@@ -260,8 +288,8 @@ declare const InputNumber: {
260
288
  type: ObjectConstructor;
261
289
  };
262
290
  }>> & Readonly<{
263
- onFocus?: ((_ev: FocusEvent) => any) | undefined;
264
291
  onClear?: ((_ev: Event) => any) | undefined;
292
+ onFocus?: ((_ev: FocusEvent) => any) | undefined;
265
293
  onBlur?: ((_ev: FocusEvent) => any) | undefined;
266
294
  onChange?: ((_value: string | number | null | undefined, _ev: Event) => any) | undefined;
267
295
  onInput?: ((_value: string | number | null | undefined, _inputValue: string, _ev: Event) => any) | undefined;
@@ -282,10 +310,12 @@ declare const InputNumber: {
282
310
  input: (_value: string | number | null | undefined, _inputValue: string, _ev: Event) => true;
283
311
  keydown: (_ev: KeyboardEvent) => true;
284
312
  }, string, {
313
+ disabled: boolean;
285
314
  error: boolean;
286
315
  readonly: string | boolean;
287
- disabled: boolean;
288
316
  allowClear: boolean;
317
+ fitWidth: boolean;
318
+ maxWFull: boolean;
289
319
  max: number;
290
320
  mode: "embed" | "button";
291
321
  step: number;
@@ -40,6 +40,14 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
40
40
  type: FunctionConstructor;
41
41
  };
42
42
  placeholder: StringConstructor;
43
+ fitWidth: {
44
+ type: BooleanConstructor;
45
+ default: boolean;
46
+ };
47
+ maxWFull: {
48
+ type: BooleanConstructor;
49
+ default: boolean;
50
+ };
43
51
  hideButton: {
44
52
  type: BooleanConstructor;
45
53
  default: boolean;
@@ -115,6 +123,14 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
115
123
  type: FunctionConstructor;
116
124
  };
117
125
  placeholder: StringConstructor;
126
+ fitWidth: {
127
+ type: BooleanConstructor;
128
+ default: boolean;
129
+ };
130
+ maxWFull: {
131
+ type: BooleanConstructor;
132
+ default: boolean;
133
+ };
118
134
  hideButton: {
119
135
  type: BooleanConstructor;
120
136
  default: boolean;
@@ -138,18 +154,20 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
138
154
  type: ObjectConstructor;
139
155
  };
140
156
  }>> & Readonly<{
141
- onFocus?: ((_ev: FocusEvent) => any) | undefined;
142
157
  onClear?: ((_ev: Event) => any) | undefined;
158
+ onFocus?: ((_ev: FocusEvent) => any) | undefined;
143
159
  onBlur?: ((_ev: FocusEvent) => any) | undefined;
144
160
  onChange?: ((_value: InputNumberValue, _ev: Event) => any) | undefined;
145
161
  onInput?: ((_value: InputNumberValue, _inputValue: string, _ev: Event) => any) | undefined;
146
162
  onKeydown?: ((_ev: KeyboardEvent) => any) | undefined;
147
163
  "onUpdate:modelValue"?: ((_value: InputNumberValue) => any) | undefined;
148
164
  }>, {
165
+ disabled: boolean;
149
166
  error: boolean;
150
167
  readonly: string | boolean;
151
- disabled: boolean;
152
168
  allowClear: boolean;
169
+ fitWidth: boolean;
170
+ maxWFull: boolean;
153
171
  max: number;
154
172
  mode: "embed" | "button";
155
173
  step: number;
@@ -101,6 +101,22 @@ var input_number_default = /* @__PURE__ */ defineComponent({
101
101
  */
102
102
  placeholder: String,
103
103
  /**
104
+ * @zh 宽度是否适应文字内容
105
+ * @en Whether the width adapts to the text content
106
+ */
107
+ fitWidth: {
108
+ type: Boolean,
109
+ default: false
110
+ },
111
+ /**
112
+ * @zh 最大宽度是否限制为父容器宽度
113
+ * @en Whether the maximum width is limited to the parent container width
114
+ */
115
+ maxWFull: {
116
+ type: Boolean,
117
+ default: true
118
+ },
119
+ /**
104
120
  * @zh 是否隐藏按钮
105
121
  * @en Whether to hide the button
106
122
  */
@@ -463,6 +479,9 @@ var input_number_default = /* @__PURE__ */ defineComponent({
463
479
  "size": mergedSize.value,
464
480
  "modelValue": _value.value,
465
481
  "placeholder": props.placeholder,
482
+ "fitWidth": props.fitWidth,
483
+ "maxWFull": props.maxWFull,
484
+ "fitWidthFallback": "2ch",
466
485
  "disabled": mergedDisabled.value,
467
486
  "readonly": props.readonly,
468
487
  "error": props.error,
@@ -16,6 +16,14 @@ declare const InputTag: {
16
16
  default: string;
17
17
  };
18
18
  placeholder: StringConstructor;
19
+ fitWidth: {
20
+ type: BooleanConstructor;
21
+ default: boolean;
22
+ };
23
+ maxWFull: {
24
+ type: BooleanConstructor;
25
+ default: boolean;
26
+ };
19
27
  disabled: {
20
28
  type: BooleanConstructor;
21
29
  default: boolean;
@@ -66,8 +74,8 @@ declare const InputTag: {
66
74
  uninjectFormItemContext: BooleanConstructor;
67
75
  inputAttrs: import("vue").PropType<Record<string, unknown>>;
68
76
  }>> & Readonly<{
69
- onFocus?: ((_ev: FocusEvent) => any) | undefined;
70
77
  onClear?: ((_ev: MouseEvent) => any) | undefined;
78
+ onFocus?: ((_ev: FocusEvent) => any) | undefined;
71
79
  onBlur?: ((_ev: FocusEvent) => any) | undefined;
72
80
  onChange?: ((_value: (string | number | import("./interface").TagData)[], _ev: Event) => any) | undefined;
73
81
  "onUpdate:modelValue"?: ((_value: (string | number | import("./interface").TagData)[]) => any) | undefined;
@@ -92,11 +100,13 @@ declare const InputTag: {
92
100
  focus: (_ev: FocusEvent) => true;
93
101
  blur: (_ev: FocusEvent) => true;
94
102
  }, import("vue").PublicProps, {
103
+ disabled: boolean;
95
104
  error: boolean;
96
105
  readonly: string | boolean;
97
- disabled: boolean;
98
106
  defaultValue: (string | number | import("./interface").TagData)[];
99
107
  allowClear: boolean;
108
+ fitWidth: boolean;
109
+ maxWFull: boolean;
100
110
  focused: boolean;
101
111
  disabledInput: boolean;
102
112
  uninjectFormItemContext: boolean;
@@ -129,6 +139,14 @@ declare const InputTag: {
129
139
  default: string;
130
140
  };
131
141
  placeholder: StringConstructor;
142
+ fitWidth: {
143
+ type: BooleanConstructor;
144
+ default: boolean;
145
+ };
146
+ maxWFull: {
147
+ type: BooleanConstructor;
148
+ default: boolean;
149
+ };
132
150
  disabled: {
133
151
  type: BooleanConstructor;
134
152
  default: boolean;
@@ -179,8 +197,8 @@ declare const InputTag: {
179
197
  uninjectFormItemContext: BooleanConstructor;
180
198
  inputAttrs: import("vue").PropType<Record<string, unknown>>;
181
199
  }>> & Readonly<{
182
- onFocus?: ((_ev: FocusEvent) => any) | undefined;
183
200
  onClear?: ((_ev: MouseEvent) => any) | undefined;
201
+ onFocus?: ((_ev: FocusEvent) => any) | undefined;
184
202
  onBlur?: ((_ev: FocusEvent) => any) | undefined;
185
203
  onChange?: ((_value: (string | number | import("./interface").TagData)[], _ev: Event) => any) | undefined;
186
204
  "onUpdate:modelValue"?: ((_value: (string | number | import("./interface").TagData)[]) => any) | undefined;
@@ -195,11 +213,13 @@ declare const InputTag: {
195
213
  focus(): void;
196
214
  blur(): void;
197
215
  }, {
216
+ disabled: boolean;
198
217
  error: boolean;
199
218
  readonly: string | boolean;
200
- disabled: boolean;
201
219
  defaultValue: (string | number | import("./interface").TagData)[];
202
220
  allowClear: boolean;
221
+ fitWidth: boolean;
222
+ maxWFull: boolean;
203
223
  focused: boolean;
204
224
  disabledInput: boolean;
205
225
  uninjectFormItemContext: boolean;
@@ -229,6 +249,14 @@ declare const InputTag: {
229
249
  default: string;
230
250
  };
231
251
  placeholder: StringConstructor;
252
+ fitWidth: {
253
+ type: BooleanConstructor;
254
+ default: boolean;
255
+ };
256
+ maxWFull: {
257
+ type: BooleanConstructor;
258
+ default: boolean;
259
+ };
232
260
  disabled: {
233
261
  type: BooleanConstructor;
234
262
  default: boolean;
@@ -279,8 +307,8 @@ declare const InputTag: {
279
307
  uninjectFormItemContext: BooleanConstructor;
280
308
  inputAttrs: import("vue").PropType<Record<string, unknown>>;
281
309
  }>> & Readonly<{
282
- onFocus?: ((_ev: FocusEvent) => any) | undefined;
283
310
  onClear?: ((_ev: MouseEvent) => any) | undefined;
311
+ onFocus?: ((_ev: FocusEvent) => any) | undefined;
284
312
  onBlur?: ((_ev: FocusEvent) => any) | undefined;
285
313
  onChange?: ((_value: (string | number | import("./interface").TagData)[], _ev: Event) => any) | undefined;
286
314
  "onUpdate:modelValue"?: ((_value: (string | number | import("./interface").TagData)[]) => any) | undefined;
@@ -305,11 +333,13 @@ declare const InputTag: {
305
333
  focus: (_ev: FocusEvent) => true;
306
334
  blur: (_ev: FocusEvent) => true;
307
335
  }, string, {
336
+ disabled: boolean;
308
337
  error: boolean;
309
338
  readonly: string | boolean;
310
- disabled: boolean;
311
339
  defaultValue: (string | number | import("./interface").TagData)[];
312
340
  allowClear: boolean;
341
+ fitWidth: boolean;
342
+ maxWFull: boolean;
313
343
  focused: boolean;
314
344
  disabledInput: boolean;
315
345
  uninjectFormItemContext: boolean;
@@ -15,6 +15,14 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
15
15
  default: string;
16
16
  };
17
17
  placeholder: StringConstructor;
18
+ fitWidth: {
19
+ type: BooleanConstructor;
20
+ default: boolean;
21
+ };
22
+ maxWFull: {
23
+ type: BooleanConstructor;
24
+ default: boolean;
25
+ };
18
26
  disabled: {
19
27
  type: BooleanConstructor;
20
28
  default: boolean;
@@ -94,6 +102,14 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
94
102
  default: string;
95
103
  };
96
104
  placeholder: StringConstructor;
105
+ fitWidth: {
106
+ type: BooleanConstructor;
107
+ default: boolean;
108
+ };
109
+ maxWFull: {
110
+ type: BooleanConstructor;
111
+ default: boolean;
112
+ };
97
113
  disabled: {
98
114
  type: BooleanConstructor;
99
115
  default: boolean;
@@ -144,8 +160,8 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
144
160
  uninjectFormItemContext: BooleanConstructor;
145
161
  inputAttrs: PropType<Record<string, unknown>>;
146
162
  }>> & Readonly<{
147
- onFocus?: ((_ev: FocusEvent) => any) | undefined;
148
163
  onClear?: ((_ev: MouseEvent) => any) | undefined;
164
+ onFocus?: ((_ev: FocusEvent) => any) | undefined;
149
165
  onBlur?: ((_ev: FocusEvent) => any) | undefined;
150
166
  onChange?: ((_value: (string | number | TagData)[], _ev: Event) => any) | undefined;
151
167
  "onUpdate:modelValue"?: ((_value: (string | number | TagData)[]) => any) | undefined;
@@ -154,11 +170,13 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
154
170
  onInputValueChange?: ((_inputValue: string, _ev: Event) => any) | undefined;
155
171
  onRemove?: ((_removed: string | number, _ev: Event) => any) | undefined;
156
172
  }>, {
173
+ disabled: boolean;
157
174
  error: boolean;
158
175
  readonly: string | boolean;
159
- disabled: boolean;
160
176
  defaultValue: (string | number | TagData)[];
161
177
  allowClear: boolean;
178
+ fitWidth: boolean;
179
+ maxWFull: boolean;
162
180
  focused: boolean;
163
181
  disabledInput: boolean;
164
182
  uninjectFormItemContext: boolean;
@@ -7,6 +7,7 @@ import icon_hover_default from "../_components/icon-hover.js";
7
7
  import IconClose from "../icon/icon-close/index.js";
8
8
  import { useAllowClear } from "../_hooks/use-allow-clear.js";
9
9
  import feedback_icon_default from "../_components/feedback-icon.js";
10
+ import { useFitWidth } from "../_hooks/use-fit-width.js";
10
11
  import { isReadonlyModificationKey, useReadonlyTip, useReadonlyTipText } from "../_hooks/use-readonly-tip.js";
11
12
  import { useSize } from "../_hooks/use-size.js";
12
13
  import { INPUT_EVENTS } from "../_utils/constant.js";
@@ -66,6 +67,22 @@ var input_tag_default = /* @__PURE__ */ defineComponent({
66
67
  */
67
68
  placeholder: String,
68
69
  /**
70
+ * @zh 宽度是否适应文字内容
71
+ * @en Whether the width adapts to the text content
72
+ */
73
+ fitWidth: {
74
+ type: Boolean,
75
+ default: false
76
+ },
77
+ /**
78
+ * @zh 最大宽度是否限制为父容器宽度
79
+ * @en Whether the maximum width is limited to the parent container width
80
+ */
81
+ maxWFull: {
82
+ type: Boolean,
83
+ default: true
84
+ },
85
+ /**
69
86
  * @zh 是否禁用
70
87
  * @en Whether to disable
71
88
  */
@@ -306,6 +323,13 @@ var input_tag_default = /* @__PURE__ */ defineComponent({
306
323
  }
307
324
  };
308
325
  const valueData = computed(() => getValueData(computedValue.value, mergedFieldNames.value));
326
+ const { fitWidthStyle, fitWidthValue } = useFitWidth({
327
+ fitWidth: () => props.fitWidth,
328
+ text: computed(() => compositionValue.value || computedInputValue.value || (valueData.value.length === 0 ? props.placeholder : void 0)),
329
+ fallbackWidth: () => valueData.value.length > 0 ? "12px" : "4ch",
330
+ target: inputRef,
331
+ additionalWidth: 12
332
+ });
309
333
  const visibleTagCount = computed(() => {
310
334
  if (isResponsiveMaxTagCount.value) {
311
335
  var _responsiveVisibleTag;
@@ -501,10 +525,15 @@ var input_tag_default = /* @__PURE__ */ defineComponent({
501
525
  [`${prefixCls}-has-tag`]: valueData.value.length > 0,
502
526
  [`${prefixCls}-has-prefix`]: Boolean(slots.prefix),
503
527
  [`${prefixCls}-has-suffix`]: Boolean(slots.suffix) || showClearBtn.value || feedback.value,
504
- [`${prefixCls}-has-placeholder`]: !computedValue.value.length
528
+ [`${prefixCls}-has-placeholder`]: !computedValue.value.length,
529
+ [`${prefixCls}-fit-width`]: props.fitWidth,
530
+ [`${prefixCls}-max-w-full`]: props.maxWFull
505
531
  }
506
532
  ]);
507
- const wrapperAttrs = computed(() => omit(attrs, INPUT_EVENTS));
533
+ const wrapperAttrs = computed(() => {
534
+ const wrapperAttrs = omit(attrs, INPUT_EVENTS);
535
+ return _objectSpread2(_objectSpread2({}, wrapperAttrs), {}, { style: [fitWidthStyle.value, wrapperAttrs.style] });
536
+ });
508
537
  const inputAttrs = computed(() => pick(attrs, INPUT_EVENTS));
509
538
  const renderTagContent = (item, index) => {
510
539
  var _ref, _slots$tag, _slots$tag2, _props$formatTag;
@@ -517,10 +546,12 @@ var input_tag_default = /* @__PURE__ */ defineComponent({
517
546
  return { maxWidth: `${responsiveTagMaxWidth.value}px` };
518
547
  };
519
548
  const getInputStyle = computed(() => {
520
- if (!isResponsiveMaxTagCount.value) return inputStyle;
549
+ const width = props.fitWidth ? fitWidthValue : inputStyle.width;
550
+ if (!isResponsiveMaxTagCount.value) return _objectSpread2(_objectSpread2({}, inputStyle), {}, { width });
521
551
  return _objectSpread2(_objectSpread2({}, inputStyle), {}, {
552
+ width,
522
553
  flex: "0 0 auto",
523
- minWidth: inputStyle.width
554
+ minWidth: width
524
555
  });
525
556
  });
526
557
  const isCompressedResponsiveTag = (index, value) => isResponsiveMaxTagCount.value && !isOverflowCounterTag(value) && hiddenTagCount.value > 0 && index === 0 && responsiveTagMaxWidth.value > 0;
@@ -588,6 +588,12 @@
588
588
  max-width: 100%;
589
589
  overflow: hidden;
590
590
  }
591
+ .sd-input-tag.sd-input-tag-fit-width {
592
+ width: fit-content;
593
+ }
594
+ .sd-input-tag.sd-input-tag-max-w-full {
595
+ max-width: 100%;
596
+ }
591
597
  .sd-input-tag.sd-input-tag-has-tag {
592
598
  padding-right: 4px;
593
599
  padding-left: 4px;
@@ -80,6 +80,14 @@
80
80
  max-width: 100%;
81
81
  overflow: hidden;
82
82
 
83
+ &.#{$cls}-fit-width {
84
+ width: fit-content;
85
+ }
86
+
87
+ &.#{$cls}-max-w-full {
88
+ max-width: 100%;
89
+ }
90
+
83
91
  &.#{$cls}-has-tag {
84
92
  padding-right: $input-tag-padding-horizontal;
85
93
  padding-left: $input-tag-padding-horizontal;