naive-ui 2.25.1 → 2.25.2

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 (228) hide show
  1. package/es/_internal/select-menu/src/SelectMenu.d.ts +6 -1
  2. package/es/_internal/select-menu/src/SelectMenu.js +17 -8
  3. package/es/_internal/selection/src/Selection.d.ts +31 -26
  4. package/es/_internal/selection/src/Selection.js +78 -80
  5. package/es/_internal/selection/styles/dark.js +3 -3
  6. package/es/_internal/selection/styles/light.d.ts +6 -6
  7. package/es/_internal/selection/styles/light.js +3 -3
  8. package/es/_mixins/index.d.ts +1 -1
  9. package/es/_mixins/index.js +1 -1
  10. package/es/_mixins/use-css-vars-class.d.ts +9 -2
  11. package/es/_mixins/use-css-vars-class.js +29 -13
  12. package/es/_mixins/use-form-item.d.ts +1 -1
  13. package/es/_utils/css/color-to-class.d.ts +1 -0
  14. package/es/_utils/css/color-to-class.js +3 -0
  15. package/es/_utils/css/format-length.d.ts +2 -2
  16. package/es/_utils/css/format-length.js +1 -2
  17. package/es/_utils/css/index.d.ts +2 -1
  18. package/es/_utils/css/index.js +2 -1
  19. package/es/_utils/index.d.ts +1 -1
  20. package/es/_utils/index.js +1 -1
  21. package/es/_utils/vue/resolve-slot.js +0 -1
  22. package/es/alert/src/Alert.d.ts +4 -4
  23. package/es/auto-complete/src/AutoComplete.d.ts +1 -1
  24. package/es/badge/src/Badge.d.ts +4 -4
  25. package/es/button/src/Button.d.ts +3 -2
  26. package/es/button/src/Button.js +13 -24
  27. package/es/button/styles/index.d.ts +1 -1
  28. package/es/button/styles/index.js +1 -1
  29. package/es/button/styles/rtl.d.ts +2 -5
  30. package/es/button/styles/rtl.js +1 -1
  31. package/es/card/src/Card.d.ts +3 -1
  32. package/es/card/src/Card.js +41 -38
  33. package/es/card/styles/index.d.ts +1 -1
  34. package/es/card/styles/index.js +1 -1
  35. package/es/card/styles/rtl.d.ts +2 -5
  36. package/es/card/styles/rtl.js +1 -1
  37. package/es/cascader/src/Cascader.d.ts +30 -30
  38. package/es/cascader/src/CascaderMenu.d.ts +3 -3
  39. package/es/cascader/src/CascaderOption.d.ts +3 -3
  40. package/es/cascader/src/CascaderSelectMenu.d.ts +3 -3
  41. package/es/cascader/src/CascaderSubmenu.d.ts +3 -3
  42. package/es/cascader/styles/light.d.ts +3 -3
  43. package/es/checkbox/src/styles/index.cssr.js +12 -12
  44. package/es/data-table/src/DataTable.d.ts +34 -34
  45. package/es/data-table/src/HeaderButton/FilterButton.d.ts +6 -6
  46. package/es/data-table/src/HeaderButton/FilterMenu.d.ts +6 -6
  47. package/es/data-table/src/TableParts/Body.d.ts +6 -6
  48. package/es/data-table/src/TableParts/Cell.d.ts +12 -12
  49. package/es/data-table/src/TableParts/Header.d.ts +6 -6
  50. package/es/data-table/styles/light.d.ts +3 -3
  51. package/es/descriptions/src/Descriptions.d.ts +1 -1
  52. package/es/dialog/src/Dialog.d.ts +4 -4
  53. package/es/dialog/src/DialogEnvironment.d.ts +5 -5
  54. package/es/dialog/src/DialogProvider.d.ts +2 -2
  55. package/es/dialog/src/dialogProps.d.ts +2 -2
  56. package/es/dynamic-tags/src/DynamicTags.d.ts +4 -4
  57. package/es/form/src/FormItem.d.ts +4 -4
  58. package/es/form/src/FormItemCol.d.ts +3 -3
  59. package/es/form/src/FormItemGridItem.d.ts +5 -5
  60. package/es/form/src/FormItemRow.d.ts +3 -3
  61. package/es/form/src/utils.d.ts +1 -1
  62. package/es/gradient-text/src/GradientText.d.ts +5 -5
  63. package/es/icon-wrapper/src/IconWrapper.js +7 -5
  64. package/es/image/src/Image.d.ts +1 -1
  65. package/es/input/src/Input.d.ts +1 -1
  66. package/es/input-number/src/InputNumber.d.ts +1 -1
  67. package/es/locales/common/eo.d.ts +109 -0
  68. package/es/locales/common/eo.js +109 -0
  69. package/es/locales/common/plPL.d.ts +3 -0
  70. package/es/locales/common/plPL.js +109 -0
  71. package/es/locales/date/eo.d.ts +3 -0
  72. package/es/locales/date/eo.js +6 -0
  73. package/es/locales/date/plPL.d.ts +3 -0
  74. package/es/locales/date/plPL.js +6 -0
  75. package/es/locales/index.d.ts +4 -0
  76. package/es/locales/index.js +4 -0
  77. package/es/mention/src/Mention.d.ts +1 -1
  78. package/es/menu/src/Menu.d.ts +1 -1
  79. package/es/modal/src/BodyWrapper.d.ts +6 -6
  80. package/es/modal/src/Modal.d.ts +8 -8
  81. package/es/modal/src/presetProps.d.ts +2 -2
  82. package/es/notification/src/Notification.d.ts +4 -4
  83. package/es/notification/src/NotificationEnvironment.d.ts +4 -4
  84. package/es/notification/src/NotificationProvider.d.ts +1 -1
  85. package/es/pagination/src/Pagination.d.ts +33 -33
  86. package/es/pagination/styles/light.d.ts +3 -3
  87. package/es/progress/src/Circle.d.ts +19 -3
  88. package/es/progress/src/Circle.js +41 -22
  89. package/es/progress/src/Progress.d.ts +14 -5
  90. package/es/progress/src/Progress.js +43 -29
  91. package/es/progress/src/styles/index.cssr.js +1 -1
  92. package/es/result/src/Result.d.ts +4 -4
  93. package/es/select/src/Select.d.ts +45 -31
  94. package/es/select/src/Select.js +13 -8
  95. package/es/select/styles/light.d.ts +3 -3
  96. package/es/tag/src/Tag.d.ts +7 -5
  97. package/es/tag/src/Tag.js +60 -40
  98. package/es/tag/src/common-props.d.ts +1 -1
  99. package/es/tag/src/styles/index.cssr.js +1 -1
  100. package/es/tag/styles/index.d.ts +1 -1
  101. package/es/tag/styles/index.js +1 -1
  102. package/es/tag/styles/rtl.d.ts +2 -5
  103. package/es/tag/styles/rtl.js +1 -1
  104. package/es/timeline/src/TimelineItem.d.ts +4 -4
  105. package/es/tree/src/utils.js +1 -1
  106. package/es/tree-select/src/TreeSelect.d.ts +30 -30
  107. package/es/tree-select/styles/light.d.ts +3 -3
  108. package/es/typography/src/create-header.d.ts +4 -4
  109. package/es/typography/src/headers.d.ts +18 -18
  110. package/es/upload/src/UploadFile.d.ts +1 -1
  111. package/es/upload/src/UploadProgress.d.ts +2 -2
  112. package/es/version.d.ts +1 -1
  113. package/es/version.js +1 -1
  114. package/lib/_internal/select-menu/src/SelectMenu.d.ts +6 -1
  115. package/lib/_internal/select-menu/src/SelectMenu.js +16 -7
  116. package/lib/_internal/selection/src/Selection.d.ts +31 -26
  117. package/lib/_internal/selection/src/Selection.js +77 -79
  118. package/lib/_internal/selection/styles/dark.js +3 -3
  119. package/lib/_internal/selection/styles/light.d.ts +6 -6
  120. package/lib/_internal/selection/styles/light.js +3 -3
  121. package/lib/_mixins/index.d.ts +1 -1
  122. package/lib/_mixins/index.js +3 -2
  123. package/lib/_mixins/use-css-vars-class.d.ts +9 -2
  124. package/lib/_mixins/use-css-vars-class.js +31 -15
  125. package/lib/_mixins/use-form-item.d.ts +1 -1
  126. package/lib/_utils/css/color-to-class.d.ts +1 -0
  127. package/lib/_utils/css/color-to-class.js +7 -0
  128. package/lib/_utils/css/format-length.d.ts +2 -2
  129. package/lib/_utils/css/format-length.js +2 -1
  130. package/lib/_utils/css/index.d.ts +2 -1
  131. package/lib/_utils/css/index.js +4 -5
  132. package/lib/_utils/index.d.ts +1 -1
  133. package/lib/_utils/index.js +2 -1
  134. package/lib/_utils/vue/resolve-slot.js +0 -1
  135. package/lib/alert/src/Alert.d.ts +4 -4
  136. package/lib/auto-complete/src/AutoComplete.d.ts +1 -1
  137. package/lib/badge/src/Badge.d.ts +4 -4
  138. package/lib/button/src/Button.d.ts +3 -2
  139. package/lib/button/src/Button.js +11 -22
  140. package/lib/button/styles/index.d.ts +1 -1
  141. package/lib/button/styles/index.js +1 -1
  142. package/lib/button/styles/rtl.d.ts +2 -5
  143. package/lib/button/styles/rtl.js +2 -1
  144. package/lib/card/src/Card.d.ts +3 -1
  145. package/lib/card/src/Card.js +40 -37
  146. package/lib/card/styles/index.d.ts +1 -1
  147. package/lib/card/styles/index.js +1 -1
  148. package/lib/card/styles/rtl.d.ts +2 -5
  149. package/lib/card/styles/rtl.js +2 -1
  150. package/lib/cascader/src/Cascader.d.ts +30 -30
  151. package/lib/cascader/src/CascaderMenu.d.ts +3 -3
  152. package/lib/cascader/src/CascaderOption.d.ts +3 -3
  153. package/lib/cascader/src/CascaderSelectMenu.d.ts +3 -3
  154. package/lib/cascader/src/CascaderSubmenu.d.ts +3 -3
  155. package/lib/cascader/styles/light.d.ts +3 -3
  156. package/lib/checkbox/src/styles/index.cssr.js +12 -12
  157. package/lib/data-table/src/DataTable.d.ts +34 -34
  158. package/lib/data-table/src/HeaderButton/FilterButton.d.ts +6 -6
  159. package/lib/data-table/src/HeaderButton/FilterMenu.d.ts +6 -6
  160. package/lib/data-table/src/TableParts/Body.d.ts +6 -6
  161. package/lib/data-table/src/TableParts/Cell.d.ts +12 -12
  162. package/lib/data-table/src/TableParts/Header.d.ts +6 -6
  163. package/lib/data-table/styles/light.d.ts +3 -3
  164. package/lib/descriptions/src/Descriptions.d.ts +1 -1
  165. package/lib/dialog/src/Dialog.d.ts +4 -4
  166. package/lib/dialog/src/DialogEnvironment.d.ts +5 -5
  167. package/lib/dialog/src/DialogProvider.d.ts +2 -2
  168. package/lib/dialog/src/dialogProps.d.ts +2 -2
  169. package/lib/dynamic-tags/src/DynamicTags.d.ts +4 -4
  170. package/lib/form/src/FormItem.d.ts +4 -4
  171. package/lib/form/src/FormItemCol.d.ts +3 -3
  172. package/lib/form/src/FormItemGridItem.d.ts +5 -5
  173. package/lib/form/src/FormItemRow.d.ts +3 -3
  174. package/lib/form/src/utils.d.ts +1 -1
  175. package/lib/gradient-text/src/GradientText.d.ts +5 -5
  176. package/lib/icon-wrapper/src/IconWrapper.js +6 -4
  177. package/lib/image/src/Image.d.ts +1 -1
  178. package/lib/input/src/Input.d.ts +1 -1
  179. package/lib/input-number/src/InputNumber.d.ts +1 -1
  180. package/lib/locales/common/eo.d.ts +109 -0
  181. package/lib/locales/common/eo.js +111 -0
  182. package/lib/locales/common/plPL.d.ts +3 -0
  183. package/lib/locales/common/plPL.js +111 -0
  184. package/lib/locales/date/eo.d.ts +3 -0
  185. package/lib/locales/date/eo.js +11 -0
  186. package/lib/locales/date/plPL.d.ts +3 -0
  187. package/lib/locales/date/plPL.js +11 -0
  188. package/lib/locales/index.d.ts +4 -0
  189. package/lib/locales/index.js +9 -1
  190. package/lib/mention/src/Mention.d.ts +1 -1
  191. package/lib/menu/src/Menu.d.ts +1 -1
  192. package/lib/modal/src/BodyWrapper.d.ts +6 -6
  193. package/lib/modal/src/Modal.d.ts +8 -8
  194. package/lib/modal/src/presetProps.d.ts +2 -2
  195. package/lib/notification/src/Notification.d.ts +4 -4
  196. package/lib/notification/src/NotificationEnvironment.d.ts +4 -4
  197. package/lib/notification/src/NotificationProvider.d.ts +1 -1
  198. package/lib/pagination/src/Pagination.d.ts +33 -33
  199. package/lib/pagination/styles/light.d.ts +3 -3
  200. package/lib/progress/src/Circle.d.ts +19 -3
  201. package/lib/progress/src/Circle.js +40 -21
  202. package/lib/progress/src/Progress.d.ts +14 -5
  203. package/lib/progress/src/Progress.js +42 -28
  204. package/lib/progress/src/styles/index.cssr.js +1 -1
  205. package/lib/result/src/Result.d.ts +4 -4
  206. package/lib/select/src/Select.d.ts +45 -31
  207. package/lib/select/src/Select.js +13 -8
  208. package/lib/select/styles/light.d.ts +3 -3
  209. package/lib/tag/src/Tag.d.ts +7 -5
  210. package/lib/tag/src/Tag.js +58 -38
  211. package/lib/tag/src/common-props.d.ts +1 -1
  212. package/lib/tag/src/styles/index.cssr.js +1 -1
  213. package/lib/tag/styles/index.d.ts +1 -1
  214. package/lib/tag/styles/index.js +1 -1
  215. package/lib/tag/styles/rtl.d.ts +2 -5
  216. package/lib/tag/styles/rtl.js +2 -1
  217. package/lib/timeline/src/TimelineItem.d.ts +4 -4
  218. package/lib/tree/src/utils.js +1 -1
  219. package/lib/tree-select/src/TreeSelect.d.ts +30 -30
  220. package/lib/tree-select/styles/light.d.ts +3 -3
  221. package/lib/typography/src/create-header.d.ts +4 -4
  222. package/lib/typography/src/headers.d.ts +18 -18
  223. package/lib/upload/src/UploadFile.d.ts +1 -1
  224. package/lib/upload/src/UploadProgress.d.ts +2 -2
  225. package/lib/version.d.ts +1 -1
  226. package/lib/version.js +1 -1
  227. package/package.json +4 -4
  228. package/web-types.json +28 -1
@@ -6,7 +6,7 @@ declare const resultProps: {
6
6
  default: string;
7
7
  };
8
8
  status: {
9
- type: PropType<"500" | "success" | "error" | "warning" | "info" | "404" | "403" | "418">;
9
+ type: PropType<"500" | "error" | "info" | "success" | "warning" | "404" | "403" | "418">;
10
10
  default: string;
11
11
  };
12
12
  title: StringConstructor;
@@ -97,7 +97,7 @@ declare const _default: import("vue").DefineComponent<{
97
97
  default: string;
98
98
  };
99
99
  status: {
100
- type: PropType<"500" | "success" | "error" | "warning" | "info" | "404" | "403" | "418">;
100
+ type: PropType<"500" | "error" | "info" | "success" | "warning" | "404" | "403" | "418">;
101
101
  default: string;
102
102
  };
103
103
  title: StringConstructor;
@@ -199,7 +199,7 @@ declare const _default: import("vue").DefineComponent<{
199
199
  default: string;
200
200
  };
201
201
  status: {
202
- type: PropType<"500" | "success" | "error" | "warning" | "info" | "404" | "403" | "418">;
202
+ type: PropType<"500" | "error" | "info" | "success" | "warning" | "404" | "403" | "418">;
203
203
  default: string;
204
204
  };
205
205
  title: StringConstructor;
@@ -284,6 +284,6 @@ declare const _default: import("vue").DefineComponent<{
284
284
  }, any>>>;
285
285
  }>>, {
286
286
  size: "small" | "medium" | "large" | "huge";
287
- status: "500" | "success" | "error" | "warning" | "info" | "404" | "403" | "418";
287
+ status: "500" | "error" | "info" | "success" | "warning" | "404" | "403" | "418";
288
288
  }>;
289
289
  export default _default;
@@ -16,6 +16,10 @@ declare const selectProps: {
16
16
  readonly default: undefined;
17
17
  };
18
18
  readonly clearable: BooleanConstructor;
19
+ readonly clearFilterAfterSelect: {
20
+ readonly type: BooleanConstructor;
21
+ readonly default: true;
22
+ };
19
23
  readonly options: {
20
24
  readonly type: PropType<SelectMixedOption[]>;
21
25
  readonly default: () => never[];
@@ -128,7 +132,7 @@ declare const selectProps: {
128
132
  borderHover: string;
129
133
  borderActive: string;
130
134
  borderFocus: string;
131
- boxShadowHover: null;
135
+ boxShadowHover: string;
132
136
  boxShadowActive: string;
133
137
  boxShadowFocus: string;
134
138
  caretColor: string;
@@ -139,7 +143,7 @@ declare const selectProps: {
139
143
  borderHoverWarning: string;
140
144
  borderActiveWarning: string;
141
145
  borderFocusWarning: string;
142
- boxShadowHoverWarning: null;
146
+ boxShadowHoverWarning: string;
143
147
  boxShadowActiveWarning: string;
144
148
  boxShadowFocusWarning: string;
145
149
  colorActiveWarning: string;
@@ -148,7 +152,7 @@ declare const selectProps: {
148
152
  borderHoverError: string;
149
153
  borderActiveError: string;
150
154
  borderFocusError: string;
151
- boxShadowHoverError: null;
155
+ boxShadowHoverError: string;
152
156
  boxShadowActiveError: string;
153
157
  boxShadowFocusError: string;
154
158
  colorActiveError: string;
@@ -253,7 +257,7 @@ declare const selectProps: {
253
257
  borderHover: string;
254
258
  borderActive: string;
255
259
  borderFocus: string;
256
- boxShadowHover: null;
260
+ boxShadowHover: string;
257
261
  boxShadowActive: string;
258
262
  boxShadowFocus: string;
259
263
  caretColor: string;
@@ -264,7 +268,7 @@ declare const selectProps: {
264
268
  borderHoverWarning: string;
265
269
  borderActiveWarning: string;
266
270
  borderFocusWarning: string;
267
- boxShadowHoverWarning: null;
271
+ boxShadowHoverWarning: string;
268
272
  boxShadowActiveWarning: string;
269
273
  boxShadowFocusWarning: string;
270
274
  colorActiveWarning: string;
@@ -273,7 +277,7 @@ declare const selectProps: {
273
277
  borderHoverError: string;
274
278
  borderActiveError: string;
275
279
  borderFocusError: string;
276
- boxShadowHoverError: null;
280
+ boxShadowHoverError: string;
277
281
  boxShadowActiveError: string;
278
282
  boxShadowFocusError: string;
279
283
  colorActiveError: string;
@@ -378,7 +382,7 @@ declare const selectProps: {
378
382
  borderHover: string;
379
383
  borderActive: string;
380
384
  borderFocus: string;
381
- boxShadowHover: null;
385
+ boxShadowHover: string;
382
386
  boxShadowActive: string;
383
387
  boxShadowFocus: string;
384
388
  caretColor: string;
@@ -389,7 +393,7 @@ declare const selectProps: {
389
393
  borderHoverWarning: string;
390
394
  borderActiveWarning: string;
391
395
  borderFocusWarning: string;
392
- boxShadowHoverWarning: null;
396
+ boxShadowHoverWarning: string;
393
397
  boxShadowActiveWarning: string;
394
398
  boxShadowFocusWarning: string;
395
399
  colorActiveWarning: string;
@@ -398,7 +402,7 @@ declare const selectProps: {
398
402
  borderHoverError: string;
399
403
  borderActiveError: string;
400
404
  borderFocusError: string;
401
- boxShadowHoverError: null;
405
+ boxShadowHoverError: string;
402
406
  boxShadowActiveError: string;
403
407
  boxShadowFocusError: string;
404
408
  colorActiveError: string;
@@ -491,6 +495,10 @@ declare const _default: import("vue").DefineComponent<{
491
495
  readonly default: undefined;
492
496
  };
493
497
  readonly clearable: BooleanConstructor;
498
+ readonly clearFilterAfterSelect: {
499
+ readonly type: BooleanConstructor;
500
+ readonly default: true;
501
+ };
494
502
  readonly options: {
495
503
  readonly type: PropType<SelectMixedOption[]>;
496
504
  readonly default: () => never[];
@@ -603,7 +611,7 @@ declare const _default: import("vue").DefineComponent<{
603
611
  borderHover: string;
604
612
  borderActive: string;
605
613
  borderFocus: string;
606
- boxShadowHover: null;
614
+ boxShadowHover: string;
607
615
  boxShadowActive: string;
608
616
  boxShadowFocus: string;
609
617
  caretColor: string;
@@ -614,7 +622,7 @@ declare const _default: import("vue").DefineComponent<{
614
622
  borderHoverWarning: string;
615
623
  borderActiveWarning: string;
616
624
  borderFocusWarning: string;
617
- boxShadowHoverWarning: null;
625
+ boxShadowHoverWarning: string;
618
626
  boxShadowActiveWarning: string;
619
627
  boxShadowFocusWarning: string;
620
628
  colorActiveWarning: string;
@@ -623,7 +631,7 @@ declare const _default: import("vue").DefineComponent<{
623
631
  borderHoverError: string;
624
632
  borderActiveError: string;
625
633
  borderFocusError: string;
626
- boxShadowHoverError: null;
634
+ boxShadowHoverError: string;
627
635
  boxShadowActiveError: string;
628
636
  boxShadowFocusError: string;
629
637
  colorActiveError: string;
@@ -728,7 +736,7 @@ declare const _default: import("vue").DefineComponent<{
728
736
  borderHover: string;
729
737
  borderActive: string;
730
738
  borderFocus: string;
731
- boxShadowHover: null;
739
+ boxShadowHover: string;
732
740
  boxShadowActive: string;
733
741
  boxShadowFocus: string;
734
742
  caretColor: string;
@@ -739,7 +747,7 @@ declare const _default: import("vue").DefineComponent<{
739
747
  borderHoverWarning: string;
740
748
  borderActiveWarning: string;
741
749
  borderFocusWarning: string;
742
- boxShadowHoverWarning: null;
750
+ boxShadowHoverWarning: string;
743
751
  boxShadowActiveWarning: string;
744
752
  boxShadowFocusWarning: string;
745
753
  colorActiveWarning: string;
@@ -748,7 +756,7 @@ declare const _default: import("vue").DefineComponent<{
748
756
  borderHoverError: string;
749
757
  borderActiveError: string;
750
758
  borderFocusError: string;
751
- boxShadowHoverError: null;
759
+ boxShadowHoverError: string;
752
760
  boxShadowActiveError: string;
753
761
  boxShadowFocusError: string;
754
762
  colorActiveError: string;
@@ -853,7 +861,7 @@ declare const _default: import("vue").DefineComponent<{
853
861
  borderHover: string;
854
862
  borderActive: string;
855
863
  borderFocus: string;
856
- boxShadowHover: null;
864
+ boxShadowHover: string;
857
865
  boxShadowActive: string;
858
866
  boxShadowFocus: string;
859
867
  caretColor: string;
@@ -864,7 +872,7 @@ declare const _default: import("vue").DefineComponent<{
864
872
  borderHoverWarning: string;
865
873
  borderActiveWarning: string;
866
874
  borderFocusWarning: string;
867
- boxShadowHoverWarning: null;
875
+ boxShadowHoverWarning: string;
868
876
  boxShadowActiveWarning: string;
869
877
  boxShadowFocusWarning: string;
870
878
  colorActiveWarning: string;
@@ -873,7 +881,7 @@ declare const _default: import("vue").DefineComponent<{
873
881
  borderHoverError: string;
874
882
  borderActiveError: string;
875
883
  borderFocusError: string;
876
- boxShadowHoverError: null;
884
+ boxShadowHoverError: string;
877
885
  boxShadowActiveError: string;
878
886
  boxShadowFocusError: string;
879
887
  colorActiveError: string;
@@ -990,6 +998,7 @@ declare const _default: import("vue").DefineComponent<{
990
998
  mergedDisabled: import("vue").ComputedRef<boolean>;
991
999
  focused: import("vue").Ref<boolean>;
992
1000
  activeWithoutMenuOpen: import("vue").Ref<boolean>;
1001
+ disableInlineTheme: boolean | undefined;
993
1002
  onTriggerInputFocus: () => void;
994
1003
  onTriggerInputBlur: () => void;
995
1004
  handleMenuFocus: (e: FocusEvent) => void;
@@ -1138,7 +1147,7 @@ declare const _default: import("vue").DefineComponent<{
1138
1147
  borderHover: string;
1139
1148
  borderActive: string;
1140
1149
  borderFocus: string;
1141
- boxShadowHover: null;
1150
+ boxShadowHover: string;
1142
1151
  boxShadowActive: string;
1143
1152
  boxShadowFocus: string;
1144
1153
  caretColor: string;
@@ -1149,7 +1158,7 @@ declare const _default: import("vue").DefineComponent<{
1149
1158
  borderHoverWarning: string;
1150
1159
  borderActiveWarning: string;
1151
1160
  borderFocusWarning: string;
1152
- boxShadowHoverWarning: null;
1161
+ boxShadowHoverWarning: string;
1153
1162
  boxShadowActiveWarning: string;
1154
1163
  boxShadowFocusWarning: string;
1155
1164
  colorActiveWarning: string;
@@ -1158,7 +1167,7 @@ declare const _default: import("vue").DefineComponent<{
1158
1167
  borderHoverError: string;
1159
1168
  borderActiveError: string;
1160
1169
  borderFocusError: string;
1161
- boxShadowHoverError: null;
1170
+ boxShadowHoverError: string;
1162
1171
  boxShadowActiveError: string;
1163
1172
  boxShadowFocusError: string;
1164
1173
  colorActiveError: string;
@@ -1296,6 +1305,10 @@ declare const _default: import("vue").DefineComponent<{
1296
1305
  readonly default: undefined;
1297
1306
  };
1298
1307
  readonly clearable: BooleanConstructor;
1308
+ readonly clearFilterAfterSelect: {
1309
+ readonly type: BooleanConstructor;
1310
+ readonly default: true;
1311
+ };
1299
1312
  readonly options: {
1300
1313
  readonly type: PropType<SelectMixedOption[]>;
1301
1314
  readonly default: () => never[];
@@ -1408,7 +1421,7 @@ declare const _default: import("vue").DefineComponent<{
1408
1421
  borderHover: string;
1409
1422
  borderActive: string;
1410
1423
  borderFocus: string;
1411
- boxShadowHover: null;
1424
+ boxShadowHover: string;
1412
1425
  boxShadowActive: string;
1413
1426
  boxShadowFocus: string;
1414
1427
  caretColor: string;
@@ -1419,7 +1432,7 @@ declare const _default: import("vue").DefineComponent<{
1419
1432
  borderHoverWarning: string;
1420
1433
  borderActiveWarning: string;
1421
1434
  borderFocusWarning: string;
1422
- boxShadowHoverWarning: null;
1435
+ boxShadowHoverWarning: string;
1423
1436
  boxShadowActiveWarning: string;
1424
1437
  boxShadowFocusWarning: string;
1425
1438
  colorActiveWarning: string;
@@ -1428,7 +1441,7 @@ declare const _default: import("vue").DefineComponent<{
1428
1441
  borderHoverError: string;
1429
1442
  borderActiveError: string;
1430
1443
  borderFocusError: string;
1431
- boxShadowHoverError: null;
1444
+ boxShadowHoverError: string;
1432
1445
  boxShadowActiveError: string;
1433
1446
  boxShadowFocusError: string;
1434
1447
  colorActiveError: string;
@@ -1533,7 +1546,7 @@ declare const _default: import("vue").DefineComponent<{
1533
1546
  borderHover: string;
1534
1547
  borderActive: string;
1535
1548
  borderFocus: string;
1536
- boxShadowHover: null;
1549
+ boxShadowHover: string;
1537
1550
  boxShadowActive: string;
1538
1551
  boxShadowFocus: string;
1539
1552
  caretColor: string;
@@ -1544,7 +1557,7 @@ declare const _default: import("vue").DefineComponent<{
1544
1557
  borderHoverWarning: string;
1545
1558
  borderActiveWarning: string;
1546
1559
  borderFocusWarning: string;
1547
- boxShadowHoverWarning: null;
1560
+ boxShadowHoverWarning: string;
1548
1561
  boxShadowActiveWarning: string;
1549
1562
  boxShadowFocusWarning: string;
1550
1563
  colorActiveWarning: string;
@@ -1553,7 +1566,7 @@ declare const _default: import("vue").DefineComponent<{
1553
1566
  borderHoverError: string;
1554
1567
  borderActiveError: string;
1555
1568
  borderFocusError: string;
1556
- boxShadowHoverError: null;
1569
+ boxShadowHoverError: string;
1557
1570
  boxShadowActiveError: string;
1558
1571
  boxShadowFocusError: string;
1559
1572
  colorActiveError: string;
@@ -1658,7 +1671,7 @@ declare const _default: import("vue").DefineComponent<{
1658
1671
  borderHover: string;
1659
1672
  borderActive: string;
1660
1673
  borderFocus: string;
1661
- boxShadowHover: null;
1674
+ boxShadowHover: string;
1662
1675
  boxShadowActive: string;
1663
1676
  boxShadowFocus: string;
1664
1677
  caretColor: string;
@@ -1669,7 +1682,7 @@ declare const _default: import("vue").DefineComponent<{
1669
1682
  borderHoverWarning: string;
1670
1683
  borderActiveWarning: string;
1671
1684
  borderFocusWarning: string;
1672
- boxShadowHoverWarning: null;
1685
+ boxShadowHoverWarning: string;
1673
1686
  boxShadowActiveWarning: string;
1674
1687
  boxShadowFocusWarning: string;
1675
1688
  colorActiveWarning: string;
@@ -1678,7 +1691,7 @@ declare const _default: import("vue").DefineComponent<{
1678
1691
  borderHoverError: string;
1679
1692
  borderActiveError: string;
1680
1693
  borderFocusError: string;
1681
- boxShadowHoverError: null;
1694
+ boxShadowHoverError: string;
1682
1695
  boxShadowActiveError: string;
1683
1696
  boxShadowFocusError: string;
1684
1697
  colorActiveError: string;
@@ -1767,8 +1780,8 @@ declare const _default: import("vue").DefineComponent<{
1767
1780
  disabled: boolean | undefined;
1768
1781
  to: string | boolean | HTMLElement;
1769
1782
  options: SelectMixedOption[];
1770
- bordered: boolean | undefined;
1771
1783
  loading: boolean;
1784
+ bordered: boolean | undefined;
1772
1785
  placement: FollowerPlacement;
1773
1786
  virtualScroll: boolean;
1774
1787
  resetMenuOnOptionsChange: boolean;
@@ -1776,6 +1789,7 @@ declare const _default: import("vue").DefineComponent<{
1776
1789
  displayDirective: "show" | "if";
1777
1790
  filterable: boolean;
1778
1791
  clearable: boolean;
1792
+ clearFilterAfterSelect: boolean;
1779
1793
  defaultValue: Value | null;
1780
1794
  remote: boolean;
1781
1795
  widthMode: string;
@@ -18,7 +18,10 @@ const index_cssr_1 = __importDefault(require("./styles/index.cssr"));
18
18
  const selectProps = Object.assign(Object.assign({}, _mixins_1.useTheme.props), { to: _utils_1.useAdjustedTo.propTo, bordered: {
19
19
  type: Boolean,
20
20
  default: undefined
21
- }, clearable: Boolean, options: {
21
+ }, clearable: Boolean, clearFilterAfterSelect: {
22
+ type: Boolean,
23
+ default: true
24
+ }, options: {
22
25
  type: Array,
23
26
  default: () => []
24
27
  }, defaultValue: {
@@ -85,7 +88,7 @@ exports.default = (0, vue_1.defineComponent)({
85
88
  }
86
89
  });
87
90
  }
88
- const { mergedClsPrefixRef, mergedBorderedRef, namespaceRef } = (0, _mixins_1.useConfig)(props);
91
+ const { mergedClsPrefixRef, mergedBorderedRef, namespaceRef, NConfigProvider } = (0, _mixins_1.useConfig)(props);
89
92
  const themeRef = (0, _mixins_1.useTheme)('Select', '-select', index_cssr_1.default, styles_1.selectLight, props, mergedClsPrefixRef);
90
93
  const uncontrolledValueRef = (0, vue_1.ref)(props.defaultValue);
91
94
  const controlledValueRef = (0, vue_1.toRef)(props, 'value');
@@ -361,7 +364,7 @@ exports.default = (0, vue_1.defineComponent)({
361
364
  function handleToggleByOption(option) {
362
365
  if (mergedDisabledRef.value)
363
366
  return;
364
- const { tag, remote } = props;
367
+ const { tag, remote, clearFilterAfterSelect } = props;
365
368
  if (tag && !remote) {
366
369
  const { value: beingCreatedOptions } = beingCreatedOptionsRef;
367
370
  const beingCreatedOption = beingCreatedOptions[0] || null;
@@ -382,13 +385,15 @@ exports.default = (0, vue_1.defineComponent)({
382
385
  const createdOptionIndex = getCreatedOptionIndex(option.value);
383
386
  if (~createdOptionIndex) {
384
387
  createdOptionsRef.value.splice(createdOptionIndex, 1);
385
- patternRef.value = '';
388
+ if (clearFilterAfterSelect)
389
+ patternRef.value = '';
386
390
  }
387
391
  }
388
392
  }
389
393
  else {
390
394
  changedValue.push(option.value);
391
- patternRef.value = '';
395
+ if (clearFilterAfterSelect)
396
+ patternRef.value = '';
392
397
  }
393
398
  doUpdateValue(changedValue, getMergedOptions(changedValue));
394
399
  }
@@ -568,7 +573,7 @@ exports.default = (0, vue_1.defineComponent)({
568
573
  }
569
574
  };
570
575
  return Object.assign(Object.assign({}, exposedMethods), { mergedStatus: mergedStatusRef, mergedClsPrefix: mergedClsPrefixRef, mergedBordered: mergedBorderedRef, namespace: namespaceRef, treeMate: treeMateRef, isMounted: (0, vooks_1.useIsMounted)(), triggerRef,
571
- menuRef, pattern: patternRef, uncontrolledShow: uncontrolledShowRef, mergedShow: mergedShowRef, adjustedTo: (0, _utils_1.useAdjustedTo)(props), uncontrolledValue: uncontrolledValueRef, mergedValue: mergedValueRef, followerRef, localizedPlaceholder: localizedPlaceholderRef, selectedOption: selectedOptionRef, selectedOptions: selectedOptionsRef, mergedSize: mergedSizeRef, mergedDisabled: mergedDisabledRef, focused: focusedRef, activeWithoutMenuOpen: activeWithoutMenuOpenRef, onTriggerInputFocus,
576
+ menuRef, pattern: patternRef, uncontrolledShow: uncontrolledShowRef, mergedShow: mergedShowRef, adjustedTo: (0, _utils_1.useAdjustedTo)(props), uncontrolledValue: uncontrolledValueRef, mergedValue: mergedValueRef, followerRef, localizedPlaceholder: localizedPlaceholderRef, selectedOption: selectedOptionRef, selectedOptions: selectedOptionsRef, mergedSize: mergedSizeRef, mergedDisabled: mergedDisabledRef, focused: focusedRef, activeWithoutMenuOpen: activeWithoutMenuOpenRef, disableInlineTheme: NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.disableInlineTheme, onTriggerInputFocus,
572
577
  onTriggerInputBlur,
573
578
  handleMenuFocus,
574
579
  handleMenuBlur,
@@ -593,7 +598,7 @@ exports.default = (0, vue_1.defineComponent)({
593
598
  (0, vue_1.h)(vueuc_1.VBinder, null, {
594
599
  default: () => [
595
600
  (0, vue_1.h)(vueuc_1.VTarget, null, {
596
- default: () => ((0, vue_1.h)(_internal_1.NInternalSelection, { ref: "triggerRef", status: this.mergedStatus, inputProps: this.inputProps, clsPrefix: this.mergedClsPrefix, showArrow: this.showArrow, maxTagCount: this.maxTagCount, bordered: this.mergedBordered, active: this.activeWithoutMenuOpen || this.mergedShow, pattern: this.pattern, placeholder: this.localizedPlaceholder, selectedOption: this.selectedOption, selectedOptions: this.selectedOptions, multiple: this.multiple, renderTag: this.renderTag, renderLabel: this.renderLabel, filterable: this.filterable, clearable: this.clearable, disabled: this.mergedDisabled, size: this.mergedSize, theme: this.mergedTheme.peers.InternalSelection, themeOverrides: this.mergedTheme.peerOverrides.InternalSelection, loading: this.loading, focused: this.focused, onClick: this.handleTriggerClick, onDeleteOption: this.handleDeleteOption, onPatternInput: this.handlePatternInput, onClear: this.handleClear, onBlur: this.handleTriggerBlur, onFocus: this.handleTriggerFocus, onKeydown: this.handleKeydown, onPatternBlur: this.onTriggerInputBlur, onPatternFocus: this.onTriggerInputFocus }, {
601
+ default: () => ((0, vue_1.h)(_internal_1.NInternalSelection, { ref: "triggerRef", disableInlineTheme: this.disableInlineTheme, status: this.mergedStatus, inputProps: this.inputProps, clsPrefix: this.mergedClsPrefix, showArrow: this.showArrow, maxTagCount: this.maxTagCount, bordered: this.mergedBordered, active: this.activeWithoutMenuOpen || this.mergedShow, pattern: this.pattern, placeholder: this.localizedPlaceholder, selectedOption: this.selectedOption, selectedOptions: this.selectedOptions, multiple: this.multiple, renderTag: this.renderTag, renderLabel: this.renderLabel, filterable: this.filterable, clearable: this.clearable, disabled: this.mergedDisabled, size: this.mergedSize, theme: this.mergedTheme.peers.InternalSelection, themeOverrides: this.mergedTheme.peerOverrides.InternalSelection, loading: this.loading, focused: this.focused, onClick: this.handleTriggerClick, onDeleteOption: this.handleDeleteOption, onPatternInput: this.handlePatternInput, onClear: this.handleClear, onBlur: this.handleTriggerBlur, onFocus: this.handleTriggerFocus, onKeydown: this.handleKeydown, onPatternBlur: this.onTriggerInputBlur, onPatternFocus: this.onTriggerInputFocus }, {
597
602
  arrow: () => { var _a, _b; return [(_b = (_a = this.$slots).arrow) === null || _b === void 0 ? void 0 : _b.call(_a)]; }
598
603
  }))
599
604
  }),
@@ -603,7 +608,7 @@ exports.default = (0, vue_1.defineComponent)({
603
608
  var _a, _b;
604
609
  return (this.mergedShow ||
605
610
  this.displayDirective === 'show') &&
606
- (0, vue_1.withDirectives)((0, vue_1.h)(_internal_1.NInternalSelectMenu, Object.assign({}, this.menuProps, { ref: "menuRef", virtualScroll: this.consistentMenuWidth && this.virtualScroll, class: [
611
+ (0, vue_1.withDirectives)((0, vue_1.h)(_internal_1.NInternalSelectMenu, Object.assign({}, this.menuProps, { ref: "menuRef", disableInlineTheme: this.disableInlineTheme, virtualScroll: this.consistentMenuWidth && this.virtualScroll, class: [
607
612
  `${this.mergedClsPrefix}-select-menu`,
608
613
  (_a = this.menuProps) === null || _a === void 0 ? void 0 : _a.class
609
614
  ], clsPrefix: this.mergedClsPrefix, focusable: true, autoPending: true, theme: this.mergedTheme.peers.InternalSelectMenu, themeOverrides: this.mergedTheme.peerOverrides
@@ -26,7 +26,7 @@ declare const selectLight: import("../../_mixins").Theme<"Select", {
26
26
  borderHover: string;
27
27
  borderActive: string;
28
28
  borderFocus: string;
29
- boxShadowHover: null;
29
+ boxShadowHover: string;
30
30
  boxShadowActive: string;
31
31
  boxShadowFocus: string;
32
32
  caretColor: string;
@@ -37,7 +37,7 @@ declare const selectLight: import("../../_mixins").Theme<"Select", {
37
37
  borderHoverWarning: string;
38
38
  borderActiveWarning: string;
39
39
  borderFocusWarning: string;
40
- boxShadowHoverWarning: null;
40
+ boxShadowHoverWarning: string;
41
41
  boxShadowActiveWarning: string;
42
42
  boxShadowFocusWarning: string;
43
43
  colorActiveWarning: string;
@@ -46,7 +46,7 @@ declare const selectLight: import("../../_mixins").Theme<"Select", {
46
46
  borderHoverError: string;
47
47
  borderActiveError: string;
48
48
  borderFocusError: string;
49
- boxShadowHoverError: null;
49
+ boxShadowHoverError: string;
50
50
  boxShadowActiveError: string;
51
51
  boxShadowFocusError: string;
52
52
  colorActiveError: string;
@@ -26,7 +26,7 @@ declare const tagProps: {
26
26
  };
27
27
  color: PropType<import("./common-props").TagColor>;
28
28
  type: {
29
- readonly type: PropType<"default" | "success" | "error" | "warning" | "info" | "primary">;
29
+ readonly type: PropType<"default" | "error" | "info" | "success" | "warning" | "primary">;
30
30
  readonly default: "default";
31
31
  };
32
32
  round: BooleanConstructor;
@@ -251,7 +251,7 @@ declare const _default: import("vue").DefineComponent<{
251
251
  };
252
252
  color: PropType<import("./common-props").TagColor>;
253
253
  type: {
254
- readonly type: PropType<"default" | "success" | "error" | "warning" | "info" | "primary">;
254
+ readonly type: PropType<"default" | "error" | "info" | "success" | "warning" | "primary">;
255
255
  readonly default: "default";
256
256
  };
257
257
  round: BooleanConstructor;
@@ -451,6 +451,8 @@ declare const _default: import("vue").DefineComponent<{
451
451
  closeMarginRtl: string;
452
452
  }, any>>>;
453
453
  }, {
454
+ themeClass?: Ref<string> | undefined;
455
+ onRender?: (() => void) | undefined;
454
456
  rtlEnabled: Ref<import("../../config-provider/src/internal-interface").RtlItem | undefined> | undefined;
455
457
  mergedClsPrefix: import("vue").ComputedRef<string>;
456
458
  contentRef: Ref<HTMLElement | null>;
@@ -485,7 +487,7 @@ declare const _default: import("vue").DefineComponent<{
485
487
  '--n-text-color-checked': string;
486
488
  '--n-text-color-hover-checkable': string;
487
489
  '--n-text-color-pressed-checkable': string;
488
- }>;
490
+ }> | undefined;
489
491
  setTextContent: (textContent: string) => void;
490
492
  }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
491
493
  bordered: {
@@ -507,7 +509,7 @@ declare const _default: import("vue").DefineComponent<{
507
509
  };
508
510
  color: PropType<import("./common-props").TagColor>;
509
511
  type: {
510
- readonly type: PropType<"default" | "success" | "error" | "warning" | "info" | "primary">;
512
+ readonly type: PropType<"default" | "error" | "info" | "success" | "warning" | "primary">;
511
513
  readonly default: "default";
512
514
  };
513
515
  round: BooleanConstructor;
@@ -707,7 +709,7 @@ declare const _default: import("vue").DefineComponent<{
707
709
  closeMarginRtl: string;
708
710
  }, any>>>;
709
711
  }>>, {
710
- type: "default" | "success" | "error" | "warning" | "info" | "primary";
712
+ type: "default" | "error" | "info" | "success" | "warning" | "primary";
711
713
  round: boolean;
712
714
  size: "small" | "medium" | "large";
713
715
  disabled: boolean | undefined;
@@ -72,45 +72,65 @@ exports.default = (0, vue_1.defineComponent)({
72
72
  }
73
73
  };
74
74
  const rtlEnabledRef = (0, use_rtl_1.default)('Tag', NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedRtlRef, mergedClsPrefixRef);
75
- return Object.assign(Object.assign({}, tagPublicMethods), { rtlEnabled: rtlEnabledRef, mergedClsPrefix: mergedClsPrefixRef, contentRef, mergedBordered: mergedBorderedRef, handleClick,
76
- handleCloseClick, cssVars: (0, vue_1.computed)(() => {
75
+ const disableInlineTheme = NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.disableInlineTheme;
76
+ const cssVarsRef = (0, vue_1.computed)(() => {
77
+ const { type, size, color: { color, textColor } = {} } = props;
78
+ const { common: { cubicBezierEaseInOut }, self: { padding, closeMargin, closeMarginRtl, borderRadius, opacityDisabled, textColorCheckable, textColorHoverCheckable, textColorPressedCheckable, textColorChecked, colorCheckable, colorHoverCheckable, colorPressedCheckable, colorChecked, colorCheckedHover, colorCheckedPressed, [(0, _utils_1.createKey)('closeSize', size)]: closeSize, [(0, _utils_1.createKey)('fontSize', size)]: fontSize, [(0, _utils_1.createKey)('height', size)]: height, [(0, _utils_1.createKey)('color', type)]: typedColor, [(0, _utils_1.createKey)('textColor', type)]: typeTextColor, [(0, _utils_1.createKey)('border', type)]: border, [(0, _utils_1.createKey)('closeColor', type)]: closeColor, [(0, _utils_1.createKey)('closeColorHover', type)]: closeColorHover, [(0, _utils_1.createKey)('closeColorPressed', type)]: closeColorPressed } } = themeRef.value;
79
+ return {
80
+ '--n-avatar-size-override': `calc(${height} - 8px)`,
81
+ '--n-bezier': cubicBezierEaseInOut,
82
+ '--n-border-radius': borderRadius,
83
+ '--n-border': border,
84
+ '--n-close-color': closeColor,
85
+ '--n-close-color-hover': closeColorHover,
86
+ '--n-close-color-pressed': closeColorPressed,
87
+ '--n-close-color-disabled': closeColor,
88
+ '--n-close-margin': closeMargin,
89
+ '--n-close-margin-rtl': closeMarginRtl,
90
+ '--n-close-size': closeSize,
91
+ '--n-color': color || typedColor,
92
+ '--n-color-checkable': colorCheckable,
93
+ '--n-color-checked': colorChecked,
94
+ '--n-color-checked-hover': colorCheckedHover,
95
+ '--n-color-checked-pressed': colorCheckedPressed,
96
+ '--n-color-hover-checkable': colorHoverCheckable,
97
+ '--n-color-pressed-checkable': colorPressedCheckable,
98
+ '--n-font-size': fontSize,
99
+ '--n-height': height,
100
+ '--n-opacity-disabled': opacityDisabled,
101
+ '--n-padding': padding,
102
+ '--n-text-color': textColor || typeTextColor,
103
+ '--n-text-color-checkable': textColorCheckable,
104
+ '--n-text-color-checked': textColorChecked,
105
+ '--n-text-color-hover-checkable': textColorHoverCheckable,
106
+ '--n-text-color-pressed-checkable': textColorPressedCheckable
107
+ };
108
+ });
109
+ const themeClassHandle = disableInlineTheme
110
+ ? (0, _mixins_1.useThemeClass)('tag', (0, vue_1.computed)(() => {
111
+ let hash = '';
77
112
  const { type, size, color: { color, textColor } = {} } = props;
78
- const { common: { cubicBezierEaseInOut }, self: { padding, closeMargin, closeMarginRtl, borderRadius, opacityDisabled, textColorCheckable, textColorHoverCheckable, textColorPressedCheckable, textColorChecked, colorCheckable, colorHoverCheckable, colorPressedCheckable, colorChecked, colorCheckedHover, colorCheckedPressed, [(0, _utils_1.createKey)('closeSize', size)]: closeSize, [(0, _utils_1.createKey)('fontSize', size)]: fontSize, [(0, _utils_1.createKey)('height', size)]: height, [(0, _utils_1.createKey)('color', type)]: typedColor, [(0, _utils_1.createKey)('textColor', type)]: typeTextColor, [(0, _utils_1.createKey)('border', type)]: border, [(0, _utils_1.createKey)('closeColor', type)]: closeColor, [(0, _utils_1.createKey)('closeColorHover', type)]: closeColorHover, [(0, _utils_1.createKey)('closeColorPressed', type)]: closeColorPressed } } = themeRef.value;
79
- return {
80
- '--n-avatar-size-override': `calc(${height} - 8px)`,
81
- '--n-bezier': cubicBezierEaseInOut,
82
- '--n-border-radius': borderRadius,
83
- '--n-border': border,
84
- '--n-close-color': closeColor,
85
- '--n-close-color-hover': closeColorHover,
86
- '--n-close-color-pressed': closeColorPressed,
87
- '--n-close-color-disabled': closeColor,
88
- '--n-close-margin': closeMargin,
89
- '--n-close-margin-rtl': closeMarginRtl,
90
- '--n-close-size': closeSize,
91
- '--n-color': color || typedColor,
92
- '--n-color-checkable': colorCheckable,
93
- '--n-color-checked': colorChecked,
94
- '--n-color-checked-hover': colorCheckedHover,
95
- '--n-color-checked-pressed': colorCheckedPressed,
96
- '--n-color-hover-checkable': colorHoverCheckable,
97
- '--n-color-pressed-checkable': colorPressedCheckable,
98
- '--n-font-size': fontSize,
99
- '--n-height': height,
100
- '--n-opacity-disabled': opacityDisabled,
101
- '--n-padding': padding,
102
- '--n-text-color': textColor || typeTextColor,
103
- '--n-text-color-checkable': textColorCheckable,
104
- '--n-text-color-checked': textColorChecked,
105
- '--n-text-color-hover-checkable': textColorHoverCheckable,
106
- '--n-text-color-pressed-checkable': textColorPressedCheckable
107
- };
108
- }) });
113
+ hash += type[0];
114
+ hash += size[0];
115
+ if (color) {
116
+ hash += `a${(0, _utils_1.color2Class)(color)}`;
117
+ }
118
+ if (textColor) {
119
+ hash += `b${(0, _utils_1.color2Class)(textColor)}`;
120
+ }
121
+ return hash;
122
+ }), cssVarsRef, props)
123
+ : _mixins_1.emptyThemeClassHandle;
124
+ return Object.assign(Object.assign(Object.assign({}, tagPublicMethods), { rtlEnabled: rtlEnabledRef, mergedClsPrefix: mergedClsPrefixRef, contentRef, mergedBordered: mergedBorderedRef, handleClick,
125
+ handleCloseClick, cssVars: disableInlineTheme ? undefined : cssVarsRef }), themeClassHandle);
109
126
  },
110
127
  render() {
111
- const { mergedClsPrefix, rtlEnabled, color: { borderColor } = {}, $slots } = this;
128
+ var _a, _b;
129
+ const { mergedClsPrefix, rtlEnabled, color: { borderColor } = {}, onRender, $slots } = this;
130
+ onRender === null || onRender === void 0 ? void 0 : onRender();
112
131
  return ((0, vue_1.h)("div", { class: [
113
132
  `${mergedClsPrefix}-tag`,
133
+ this.themeClass,
114
134
  {
115
135
  [`${mergedClsPrefix}-tag--rtl`]: rtlEnabled,
116
136
  [`${mergedClsPrefix}-tag--disabled`]: this.disabled,
@@ -119,10 +139,10 @@ exports.default = (0, vue_1.defineComponent)({
119
139
  [`${mergedClsPrefix}-tag--round`]: this.round
120
140
  }
121
141
  ], style: this.cssVars, onClick: this.handleClick, onMouseenter: this.onMouseenter, onMouseleave: this.onMouseleave },
122
- $slots.avatar && ((0, vue_1.h)("div", { class: `${mergedClsPrefix}-tag__avatar` }, {
123
- default: $slots.avatar
124
- })),
125
- (0, vue_1.h)("span", { class: `${mergedClsPrefix}-tag__content`, ref: "contentRef" }, this.$slots),
142
+ (0, _utils_1.resolveWrappedSlot)($slots.avatar, (children) => [
143
+ (0, vue_1.h)("div", { class: `${mergedClsPrefix}-tag__avatar` }, children)
144
+ ]),
145
+ (0, vue_1.h)("span", { class: `${mergedClsPrefix}-tag__content`, ref: "contentRef" }, (_b = (_a = this.$slots).default) === null || _b === void 0 ? void 0 : _b.call(_a)),
126
146
  !this.checkable && this.closable ? ((0, vue_1.h)(_internal_1.NBaseClose, { clsPrefix: mergedClsPrefix, class: `${mergedClsPrefix}-tag__close`, disabled: this.disabled, onClick: this.handleCloseClick })) : null,
127
147
  !this.checkable && this.mergedBordered ? ((0, vue_1.h)("div", { class: `${mergedClsPrefix}-tag__border`, style: { borderColor } })) : null));
128
148
  }
@@ -7,7 +7,7 @@ export interface TagColor {
7
7
  declare const _default: {
8
8
  readonly color: PropType<TagColor>;
9
9
  readonly type: {
10
- readonly type: PropType<"default" | "success" | "error" | "warning" | "info" | "primary">;
10
+ readonly type: PropType<"default" | "error" | "info" | "success" | "warning" | "primary">;
11
11
  readonly default: "default";
12
12
  };
13
13
  readonly round: BooleanConstructor;
@@ -85,5 +85,5 @@ exports.default = (0, cssr_1.cB)('tag', `
85
85
  background-color: var(--n-color-checkable);
86
86
  `, [(0, cssr_1.cNotM)('disabled', [(0, cssr_1.c)('&:hover', 'background-color: var(--n-color-hover-checkable);', [(0, cssr_1.cNotM)('checked', 'color: var(--n-text-color-hover-checkable);')]), (0, cssr_1.c)('&:active', 'background-color: var(--n-color-pressed-checkable);', [(0, cssr_1.cNotM)('checked', 'color: var(--n-text-color-pressed-checkable);')])]), (0, cssr_1.cM)('checked', `
87
87
  color: var(--n-text-color-checked);
88
- background-color: 'var(--n-color-checked);
88
+ background-color: var(--n-color-checked);
89
89
  `, [(0, cssr_1.cNotM)('disabled', [(0, cssr_1.c)('&:hover', 'background-color: var(--n-color-checked-hover);'), (0, cssr_1.c)('&:active', 'background-color: var(--n-color-checked-pressed);')])])])]);