naive-ui 2.25.2 → 2.25.5

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 (429) hide show
  1. package/es/_internal/clear/src/Clear.d.ts +0 -1
  2. package/es/_internal/clear/src/Clear.js +1 -3
  3. package/es/_internal/icons/replaceable.d.ts +1 -1
  4. package/es/_internal/icons/replaceable.js +5 -4
  5. package/es/_internal/scrollbar/src/ScrollBar.d.ts +13 -1
  6. package/es/_internal/scrollbar/src/ScrollBar.js +35 -16
  7. package/es/_internal/select-menu/src/SelectMenu.d.ts +22 -23
  8. package/es/_internal/select-menu/src/SelectMenu.js +10 -16
  9. package/es/_internal/selection/src/Selection.d.ts +5 -5
  10. package/es/_internal/selection/src/Selection.js +20 -7
  11. package/es/_mixins/index.d.ts +1 -1
  12. package/es/_mixins/index.js +1 -1
  13. package/es/_mixins/use-config.d.ts +6 -3
  14. package/es/_mixins/use-config.js +5 -1
  15. package/es/_mixins/use-css-vars-class.d.ts +1 -4
  16. package/es/_mixins/use-css-vars-class.js +8 -7
  17. package/es/_utils/vue/resolve-slot.d.ts +5 -2
  18. package/es/_utils/vue/resolve-slot.js +4 -3
  19. package/es/alert/src/Alert.d.ts +3 -1
  20. package/es/alert/src/Alert.js +36 -21
  21. package/es/anchor/src/AnchorAdapter.js +9 -3
  22. package/es/auto-complete/src/AutoComplete.d.ts +3 -1
  23. package/es/auto-complete/src/AutoComplete.js +28 -15
  24. package/es/avatar/src/Avatar.d.ts +3 -1
  25. package/es/avatar/src/Avatar.js +70 -35
  26. package/es/back-top/src/BackTop.d.ts +12 -49
  27. package/es/back-top/src/BackTop.js +60 -58
  28. package/es/badge/src/Badge.d.ts +12 -37
  29. package/es/badge/src/Badge.js +41 -31
  30. package/es/breadcrumb/src/Breadcrumb.d.ts +3 -1
  31. package/es/breadcrumb/src/Breadcrumb.js +24 -16
  32. package/es/button/src/Button.d.ts +7 -6
  33. package/es/button/src/Button.js +31 -21
  34. package/es/calendar/src/Calendar.d.ts +3 -1
  35. package/es/calendar/src/Calendar.js +37 -30
  36. package/es/card/src/Card.d.ts +2 -2
  37. package/es/card/src/Card.js +27 -16
  38. package/es/carousel/src/Carousel.d.ts +3 -1
  39. package/es/carousel/src/Carousel.js +29 -20
  40. package/es/cascader/src/Cascader.d.ts +16 -1
  41. package/es/cascader/src/Cascader.js +53 -31
  42. package/es/cascader/src/CascaderMenu.js +7 -6
  43. package/es/cascader/src/CascaderSelectMenu.js +2 -1
  44. package/es/cascader/src/CascaderSubmenu.d.ts +1 -0
  45. package/es/cascader/src/interface.d.ts +1 -0
  46. package/es/checkbox/src/Checkbox.d.ts +6 -4
  47. package/es/checkbox/src/Checkbox.js +41 -32
  48. package/es/checkbox/src/styles/index.cssr.js +7 -7
  49. package/es/code/src/Code.d.ts +3 -1
  50. package/es/code/src/Code.js +33 -27
  51. package/es/collapse/src/Collapse.d.ts +3 -1
  52. package/es/collapse/src/Collapse.js +24 -16
  53. package/es/color-picker/src/ColorPicker.d.ts +3 -1
  54. package/es/color-picker/src/ColorPicker.js +20 -7
  55. package/es/components.d.ts +1 -0
  56. package/es/components.js +1 -0
  57. package/es/config-provider/src/ConfigProvider.d.ts +4 -4
  58. package/es/config-provider/src/ConfigProvider.js +3 -3
  59. package/es/config-provider/src/internal-interface.d.ts +3 -1
  60. package/es/countdown/src/Countdown.d.ts +0 -3
  61. package/es/countdown/src/Countdown.js +0 -1
  62. package/es/data-table/src/DataTable.d.ts +43 -41
  63. package/es/data-table/src/DataTable.js +54 -48
  64. package/es/data-table/src/HeaderButton/FilterButton.js +3 -2
  65. package/es/data-table/src/HeaderButton/SortButton.js +3 -2
  66. package/es/data-table/src/TableParts/Body.d.ts +1 -0
  67. package/es/data-table/src/TableParts/Body.js +4 -2
  68. package/es/data-table/src/interface.d.ts +1 -1
  69. package/es/data-table/src/use-table-data.js +19 -7
  70. package/es/date-picker/src/DatePicker.d.ts +1 -0
  71. package/es/date-picker/src/DatePicker.js +2 -2
  72. package/es/date-picker/src/panel/date.d.ts +2 -0
  73. package/es/date-picker/src/panel/datetime.d.ts +2 -0
  74. package/es/date-picker/src/panel/month.d.ts +2 -0
  75. package/es/date-picker/src/panel/panelHeader.d.ts +4 -0
  76. package/es/date-picker/src/panel/use-calendar.d.ts +2 -0
  77. package/es/descriptions/src/Descriptions.d.ts +14 -1
  78. package/es/descriptions/src/Descriptions.js +45 -28
  79. package/es/descriptions/src/styles/index.cssr.js +2 -1
  80. package/es/descriptions/styles/light.d.ts +1 -0
  81. package/es/descriptions/styles/light.js +2 -2
  82. package/es/dialog/src/Dialog.d.ts +3 -1
  83. package/es/dialog/src/Dialog.js +57 -56
  84. package/es/dialog/src/DialogEnvironment.js +1 -1
  85. package/es/divider/src/Divider.d.ts +3 -1
  86. package/es/divider/src/Divider.js +20 -11
  87. package/es/dynamic-input/src/DynamicInput.d.ts +3 -1
  88. package/es/dynamic-input/src/DynamicInput.js +18 -11
  89. package/es/dynamic-tags/src/DynamicTags.d.ts +3 -1
  90. package/es/dynamic-tags/src/DynamicTags.js +17 -10
  91. package/es/element/src/Element.d.ts +3 -1
  92. package/es/element/src/Element.js +18 -11
  93. package/es/empty/src/Empty.d.ts +3 -1
  94. package/es/empty/src/Empty.js +28 -16
  95. package/es/form/src/FormItem.js +1 -2
  96. package/es/grid/src/Grid.js +2 -2
  97. package/es/icon-wrapper/src/IconWrapper.js +6 -8
  98. package/es/input/src/Input.d.ts +6 -3
  99. package/es/input/src/Input.js +96 -84
  100. package/es/input/src/styles/input.cssr.js +2 -2
  101. package/es/input-number/src/InputNumber.d.ts +6 -17
  102. package/es/input-number/src/InputNumber.js +79 -20
  103. package/es/layout/src/Layout.d.ts +8 -2
  104. package/es/layout/src/Layout.js +17 -10
  105. package/es/layout/src/LayoutContent.d.ts +4 -1
  106. package/es/layout/src/LayoutFooter.d.ts +3 -1
  107. package/es/layout/src/LayoutFooter.js +28 -19
  108. package/es/layout/src/LayoutHeader.d.ts +3 -1
  109. package/es/layout/src/LayoutHeader.js +28 -19
  110. package/es/layout/src/LayoutSider.d.ts +4 -0
  111. package/es/layout/src/LayoutSider.js +37 -29
  112. package/es/legacy-grid/src/styles/index.cssr.js +1 -1
  113. package/es/locales/common/esAR.js +2 -2
  114. package/es/locales/common/frFR.js +8 -9
  115. package/es/locales/common/skSK.d.ts +3 -0
  116. package/es/locales/common/skSK.js +110 -0
  117. package/es/locales/date/skSK.d.ts +3 -0
  118. package/es/locales/date/skSK.js +6 -0
  119. package/es/locales/index.d.ts +2 -0
  120. package/es/locales/index.js +2 -0
  121. package/es/log/src/Log.d.ts +4 -1
  122. package/es/log/src/Log.js +20 -15
  123. package/es/mention/index.d.ts +1 -1
  124. package/es/mention/src/Mention.d.ts +3 -1
  125. package/es/mention/src/Mention.js +20 -10
  126. package/es/mention/src/interface.d.ts +4 -0
  127. package/es/menu/src/Menu.d.ts +3 -1
  128. package/es/menu/src/Menu.js +68 -63
  129. package/es/modal/src/BodyWrapper.d.ts +1 -0
  130. package/es/modal/src/Modal.d.ts +11 -14
  131. package/es/modal/src/Modal.js +41 -32
  132. package/es/notification/src/styles/index.cssr.js +6 -5
  133. package/es/page-header/src/PageHeader.d.ts +3 -1
  134. package/es/page-header/src/PageHeader.js +27 -18
  135. package/es/pagination/src/Pagination.d.ts +13 -1
  136. package/es/pagination/src/Pagination.js +59 -52
  137. package/es/popover/src/PopoverBody.js +10 -4
  138. package/es/progress/src/Progress.d.ts +2 -2
  139. package/es/progress/src/Progress.js +12 -6
  140. package/es/radio/src/Radio.d.ts +3 -1
  141. package/es/radio/src/Radio.js +32 -23
  142. package/es/radio/src/RadioGroup.d.ts +3 -1
  143. package/es/radio/src/RadioGroup.js +31 -22
  144. package/es/rate/src/Rate.d.ts +3 -1
  145. package/es/rate/src/Rate.js +44 -23
  146. package/es/result/src/Result.d.ts +4 -2
  147. package/es/result/src/Result.js +36 -19
  148. package/es/scrollbar/src/ScrollBar.d.ts +12 -1
  149. package/es/scrollbar/src/ScrollBar.js +4 -0
  150. package/es/select/src/Select.d.ts +1 -1
  151. package/es/select/src/Select.js +5 -4
  152. package/es/spin/src/Spin.d.ts +3 -1
  153. package/es/spin/src/Spin.js +31 -21
  154. package/es/statistic/src/Statistic.d.ts +3 -1
  155. package/es/statistic/src/Statistic.js +29 -21
  156. package/es/styles.d.ts +1 -0
  157. package/es/styles.js +1 -0
  158. package/es/switch/src/Switch.d.ts +13 -1
  159. package/es/switch/src/Switch.js +85 -60
  160. package/es/switch/src/styles/index.cssr.js +21 -8
  161. package/es/switch/styles/dark.js +2 -2
  162. package/es/switch/styles/light.d.ts +1 -0
  163. package/es/switch/styles/light.js +2 -2
  164. package/es/table/src/Table.d.ts +3 -1
  165. package/es/table/src/Table.js +40 -29
  166. package/es/table/src/styles/index.cssr.js +1 -1
  167. package/es/tabs/src/Tabs.d.ts +25 -23
  168. package/es/tabs/src/Tabs.js +50 -44
  169. package/es/tabs/src/styles/index.cssr.js +79 -77
  170. package/es/tag/src/Tag.d.ts +2 -2
  171. package/es/tag/src/Tag.js +8 -11
  172. package/es/theme-editor/src/ThemeEditor.js +4 -3
  173. package/es/themes/dark.js +3 -1
  174. package/es/themes/light.js +3 -1
  175. package/es/thing/src/Thing.js +10 -3
  176. package/es/time-picker/src/TimePicker.d.ts +4 -0
  177. package/es/transfer/src/TransferList.d.ts +1 -0
  178. package/es/tree/src/Tree.d.ts +1 -0
  179. package/es/tree/src/Tree.js +8 -4
  180. package/es/tree-select/src/TreeSelect.d.ts +13 -0
  181. package/es/tree-select/src/TreeSelect.js +6 -2
  182. package/es/typography/src/a.d.ts +3 -1
  183. package/es/typography/src/a.js +18 -10
  184. package/es/typography/src/blockquote.d.ts +3 -1
  185. package/es/typography/src/blockquote.js +21 -12
  186. package/es/typography/src/create-header.d.ts +3 -1
  187. package/es/typography/src/create-header.js +25 -16
  188. package/es/typography/src/headers.d.ts +18 -6
  189. package/es/typography/src/hr.d.ts +3 -1
  190. package/es/typography/src/hr.js +18 -10
  191. package/es/typography/src/ol.d.ts +3 -1
  192. package/es/typography/src/ol.js +23 -14
  193. package/es/typography/src/p.d.ts +3 -1
  194. package/es/typography/src/p.js +23 -15
  195. package/es/typography/src/text.d.ts +3 -1
  196. package/es/typography/src/text.js +31 -23
  197. package/es/typography/src/ul.d.ts +3 -1
  198. package/es/typography/src/ul.js +23 -14
  199. package/es/upload/src/interface.d.ts +1 -1
  200. package/es/version.d.ts +1 -1
  201. package/es/version.js +1 -1
  202. package/es/watermark/index.d.ts +2 -0
  203. package/es/watermark/index.js +1 -0
  204. package/es/watermark/src/Watermark.d.ts +285 -0
  205. package/es/watermark/src/Watermark.js +159 -0
  206. package/es/watermark/src/styles/index.cssr.d.ts +2 -0
  207. package/es/watermark/src/styles/index.cssr.js +14 -0
  208. package/es/watermark/styles/dark.d.ts +3 -0
  209. package/es/watermark/styles/dark.js +12 -0
  210. package/es/watermark/styles/index.d.ts +3 -0
  211. package/es/watermark/styles/index.js +2 -0
  212. package/es/watermark/styles/light.d.ts +5 -0
  213. package/es/watermark/styles/light.js +13 -0
  214. package/lib/_internal/clear/src/Clear.d.ts +0 -1
  215. package/lib/_internal/clear/src/Clear.js +0 -2
  216. package/lib/_internal/icons/replaceable.d.ts +1 -1
  217. package/lib/_internal/icons/replaceable.js +4 -3
  218. package/lib/_internal/scrollbar/src/ScrollBar.d.ts +13 -1
  219. package/lib/_internal/scrollbar/src/ScrollBar.js +34 -15
  220. package/lib/_internal/select-menu/src/SelectMenu.d.ts +22 -23
  221. package/lib/_internal/select-menu/src/SelectMenu.js +9 -15
  222. package/lib/_internal/selection/src/Selection.d.ts +5 -5
  223. package/lib/_internal/selection/src/Selection.js +19 -6
  224. package/lib/_mixins/index.d.ts +1 -1
  225. package/lib/_mixins/index.js +1 -2
  226. package/lib/_mixins/use-config.d.ts +6 -3
  227. package/lib/_mixins/use-config.js +5 -1
  228. package/lib/_mixins/use-css-vars-class.d.ts +1 -4
  229. package/lib/_mixins/use-css-vars-class.js +9 -8
  230. package/lib/_utils/vue/resolve-slot.d.ts +5 -2
  231. package/lib/_utils/vue/resolve-slot.js +4 -3
  232. package/lib/alert/src/Alert.d.ts +3 -1
  233. package/lib/alert/src/Alert.js +34 -19
  234. package/lib/anchor/src/AnchorAdapter.js +8 -2
  235. package/lib/auto-complete/src/AutoComplete.d.ts +3 -1
  236. package/lib/auto-complete/src/AutoComplete.js +27 -14
  237. package/lib/avatar/src/Avatar.d.ts +3 -1
  238. package/lib/avatar/src/Avatar.js +68 -33
  239. package/lib/back-top/src/BackTop.d.ts +12 -49
  240. package/lib/back-top/src/BackTop.js +57 -55
  241. package/lib/badge/src/Badge.d.ts +12 -37
  242. package/lib/badge/src/Badge.js +39 -29
  243. package/lib/breadcrumb/src/Breadcrumb.d.ts +3 -1
  244. package/lib/breadcrumb/src/Breadcrumb.js +23 -15
  245. package/lib/button/src/Button.d.ts +7 -6
  246. package/lib/button/src/Button.js +29 -19
  247. package/lib/calendar/src/Calendar.d.ts +3 -1
  248. package/lib/calendar/src/Calendar.js +36 -29
  249. package/lib/card/src/Card.d.ts +2 -2
  250. package/lib/card/src/Card.js +25 -14
  251. package/lib/carousel/src/Carousel.d.ts +3 -1
  252. package/lib/carousel/src/Carousel.js +27 -18
  253. package/lib/cascader/src/Cascader.d.ts +16 -1
  254. package/lib/cascader/src/Cascader.js +52 -30
  255. package/lib/cascader/src/CascaderMenu.js +7 -6
  256. package/lib/cascader/src/CascaderSelectMenu.js +2 -1
  257. package/lib/cascader/src/CascaderSubmenu.d.ts +1 -0
  258. package/lib/cascader/src/interface.d.ts +1 -0
  259. package/lib/checkbox/src/Checkbox.d.ts +6 -4
  260. package/lib/checkbox/src/Checkbox.js +40 -31
  261. package/lib/checkbox/src/styles/index.cssr.js +7 -7
  262. package/lib/code/src/Code.d.ts +3 -1
  263. package/lib/code/src/Code.js +32 -26
  264. package/lib/collapse/src/Collapse.d.ts +3 -1
  265. package/lib/collapse/src/Collapse.js +23 -15
  266. package/lib/color-picker/src/ColorPicker.d.ts +3 -1
  267. package/lib/color-picker/src/ColorPicker.js +19 -6
  268. package/lib/components.d.ts +1 -0
  269. package/lib/components.js +1 -0
  270. package/lib/config-provider/src/ConfigProvider.d.ts +4 -4
  271. package/lib/config-provider/src/ConfigProvider.js +3 -3
  272. package/lib/config-provider/src/internal-interface.d.ts +3 -1
  273. package/lib/countdown/src/Countdown.d.ts +0 -3
  274. package/lib/countdown/src/Countdown.js +0 -1
  275. package/lib/data-table/src/DataTable.d.ts +43 -41
  276. package/lib/data-table/src/DataTable.js +53 -47
  277. package/lib/data-table/src/HeaderButton/FilterButton.js +3 -2
  278. package/lib/data-table/src/HeaderButton/SortButton.js +3 -2
  279. package/lib/data-table/src/TableParts/Body.d.ts +1 -0
  280. package/lib/data-table/src/TableParts/Body.js +3 -1
  281. package/lib/data-table/src/interface.d.ts +1 -1
  282. package/lib/data-table/src/use-table-data.js +19 -7
  283. package/lib/date-picker/src/DatePicker.d.ts +1 -0
  284. package/lib/date-picker/src/DatePicker.js +2 -2
  285. package/lib/date-picker/src/panel/date.d.ts +2 -0
  286. package/lib/date-picker/src/panel/datetime.d.ts +2 -0
  287. package/lib/date-picker/src/panel/month.d.ts +2 -0
  288. package/lib/date-picker/src/panel/panelHeader.d.ts +4 -0
  289. package/lib/date-picker/src/panel/use-calendar.d.ts +2 -0
  290. package/lib/descriptions/src/Descriptions.d.ts +14 -1
  291. package/lib/descriptions/src/Descriptions.js +44 -27
  292. package/lib/descriptions/src/styles/index.cssr.js +2 -1
  293. package/lib/descriptions/styles/light.d.ts +1 -0
  294. package/lib/descriptions/styles/light.js +2 -2
  295. package/lib/dialog/src/Dialog.d.ts +3 -1
  296. package/lib/dialog/src/Dialog.js +55 -54
  297. package/lib/dialog/src/DialogEnvironment.js +1 -1
  298. package/lib/divider/src/Divider.d.ts +3 -1
  299. package/lib/divider/src/Divider.js +19 -10
  300. package/lib/dynamic-input/src/DynamicInput.d.ts +3 -1
  301. package/lib/dynamic-input/src/DynamicInput.js +17 -10
  302. package/lib/dynamic-tags/src/DynamicTags.d.ts +3 -1
  303. package/lib/dynamic-tags/src/DynamicTags.js +16 -9
  304. package/lib/element/src/Element.d.ts +3 -1
  305. package/lib/element/src/Element.js +17 -10
  306. package/lib/empty/src/Empty.d.ts +3 -1
  307. package/lib/empty/src/Empty.js +27 -15
  308. package/lib/form/src/FormItem.js +1 -2
  309. package/lib/grid/src/Grid.js +2 -2
  310. package/lib/icon-wrapper/src/IconWrapper.js +5 -7
  311. package/lib/input/src/Input.d.ts +6 -3
  312. package/lib/input/src/Input.js +95 -83
  313. package/lib/input/src/styles/input.cssr.js +2 -2
  314. package/lib/input-number/src/InputNumber.d.ts +6 -17
  315. package/lib/input-number/src/InputNumber.js +76 -17
  316. package/lib/layout/src/Layout.d.ts +8 -2
  317. package/lib/layout/src/Layout.js +16 -9
  318. package/lib/layout/src/LayoutContent.d.ts +4 -1
  319. package/lib/layout/src/LayoutFooter.d.ts +3 -1
  320. package/lib/layout/src/LayoutFooter.js +27 -18
  321. package/lib/layout/src/LayoutHeader.d.ts +3 -1
  322. package/lib/layout/src/LayoutHeader.js +27 -18
  323. package/lib/layout/src/LayoutSider.d.ts +4 -0
  324. package/lib/layout/src/LayoutSider.js +36 -28
  325. package/lib/legacy-grid/src/styles/index.cssr.js +1 -1
  326. package/lib/locales/common/esAR.js +2 -2
  327. package/lib/locales/common/frFR.js +8 -9
  328. package/lib/locales/common/skSK.d.ts +3 -0
  329. package/lib/locales/common/skSK.js +112 -0
  330. package/lib/locales/date/skSK.d.ts +3 -0
  331. package/lib/locales/date/skSK.js +11 -0
  332. package/lib/locales/index.d.ts +2 -0
  333. package/lib/locales/index.js +5 -1
  334. package/lib/log/src/Log.d.ts +4 -1
  335. package/lib/log/src/Log.js +19 -14
  336. package/lib/mention/index.d.ts +1 -1
  337. package/lib/mention/src/Mention.d.ts +3 -1
  338. package/lib/mention/src/Mention.js +19 -9
  339. package/lib/mention/src/interface.d.ts +4 -0
  340. package/lib/menu/src/Menu.d.ts +3 -1
  341. package/lib/menu/src/Menu.js +67 -62
  342. package/lib/modal/src/BodyWrapper.d.ts +1 -0
  343. package/lib/modal/src/Modal.d.ts +11 -14
  344. package/lib/modal/src/Modal.js +40 -31
  345. package/lib/notification/src/styles/index.cssr.js +6 -5
  346. package/lib/page-header/src/PageHeader.d.ts +3 -1
  347. package/lib/page-header/src/PageHeader.js +26 -17
  348. package/lib/pagination/src/Pagination.d.ts +13 -1
  349. package/lib/pagination/src/Pagination.js +58 -51
  350. package/lib/popover/src/PopoverBody.js +9 -3
  351. package/lib/progress/src/Progress.d.ts +2 -2
  352. package/lib/progress/src/Progress.js +11 -5
  353. package/lib/radio/src/Radio.d.ts +3 -1
  354. package/lib/radio/src/Radio.js +31 -22
  355. package/lib/radio/src/RadioGroup.d.ts +3 -1
  356. package/lib/radio/src/RadioGroup.js +30 -21
  357. package/lib/rate/src/Rate.d.ts +3 -1
  358. package/lib/rate/src/Rate.js +42 -21
  359. package/lib/result/src/Result.d.ts +4 -2
  360. package/lib/result/src/Result.js +35 -18
  361. package/lib/scrollbar/src/ScrollBar.d.ts +12 -1
  362. package/lib/scrollbar/src/ScrollBar.js +4 -0
  363. package/lib/select/src/Select.d.ts +1 -1
  364. package/lib/select/src/Select.js +5 -4
  365. package/lib/spin/src/Spin.d.ts +3 -1
  366. package/lib/spin/src/Spin.js +30 -20
  367. package/lib/statistic/src/Statistic.d.ts +3 -1
  368. package/lib/statistic/src/Statistic.js +28 -20
  369. package/lib/styles.d.ts +1 -0
  370. package/lib/styles.js +9 -7
  371. package/lib/switch/src/Switch.d.ts +13 -1
  372. package/lib/switch/src/Switch.js +81 -56
  373. package/lib/switch/src/styles/index.cssr.js +21 -8
  374. package/lib/switch/styles/dark.js +2 -2
  375. package/lib/switch/styles/light.d.ts +1 -0
  376. package/lib/switch/styles/light.js +2 -2
  377. package/lib/table/src/Table.d.ts +3 -1
  378. package/lib/table/src/Table.js +39 -28
  379. package/lib/table/src/styles/index.cssr.js +1 -1
  380. package/lib/tabs/src/Tabs.d.ts +25 -23
  381. package/lib/tabs/src/Tabs.js +48 -42
  382. package/lib/tabs/src/styles/index.cssr.js +79 -77
  383. package/lib/tag/src/Tag.d.ts +2 -2
  384. package/lib/tag/src/Tag.js +7 -10
  385. package/lib/theme-editor/src/ThemeEditor.js +2 -1
  386. package/lib/themes/dark.js +3 -1
  387. package/lib/themes/light.js +3 -1
  388. package/lib/thing/src/Thing.js +9 -2
  389. package/lib/time-picker/src/TimePicker.d.ts +4 -0
  390. package/lib/transfer/src/TransferList.d.ts +1 -0
  391. package/lib/tree/src/Tree.d.ts +1 -0
  392. package/lib/tree/src/Tree.js +8 -4
  393. package/lib/tree-select/src/TreeSelect.d.ts +13 -0
  394. package/lib/tree-select/src/TreeSelect.js +6 -2
  395. package/lib/typography/src/a.d.ts +3 -1
  396. package/lib/typography/src/a.js +17 -9
  397. package/lib/typography/src/blockquote.d.ts +3 -1
  398. package/lib/typography/src/blockquote.js +20 -11
  399. package/lib/typography/src/create-header.d.ts +3 -1
  400. package/lib/typography/src/create-header.js +24 -15
  401. package/lib/typography/src/headers.d.ts +18 -6
  402. package/lib/typography/src/hr.d.ts +3 -1
  403. package/lib/typography/src/hr.js +17 -9
  404. package/lib/typography/src/ol.d.ts +3 -1
  405. package/lib/typography/src/ol.js +22 -13
  406. package/lib/typography/src/p.d.ts +3 -1
  407. package/lib/typography/src/p.js +22 -14
  408. package/lib/typography/src/text.d.ts +3 -1
  409. package/lib/typography/src/text.js +30 -22
  410. package/lib/typography/src/ul.d.ts +3 -1
  411. package/lib/typography/src/ul.js +22 -13
  412. package/lib/upload/src/interface.d.ts +1 -1
  413. package/lib/version.d.ts +1 -1
  414. package/lib/version.js +1 -1
  415. package/lib/watermark/index.d.ts +2 -0
  416. package/lib/watermark/index.js +8 -0
  417. package/lib/watermark/src/Watermark.d.ts +285 -0
  418. package/lib/watermark/src/Watermark.js +164 -0
  419. package/lib/watermark/src/styles/index.cssr.d.ts +2 -0
  420. package/lib/watermark/src/styles/index.cssr.js +21 -0
  421. package/lib/watermark/styles/dark.d.ts +3 -0
  422. package/lib/watermark/styles/dark.js +14 -0
  423. package/lib/watermark/styles/index.d.ts +3 -0
  424. package/lib/watermark/styles/index.js +10 -0
  425. package/lib/watermark/styles/light.d.ts +5 -0
  426. package/lib/watermark/styles/light.js +15 -0
  427. package/package.json +8 -9
  428. package/volar.d.ts +1 -0
  429. package/web-types.json +252 -29
@@ -15,34 +15,43 @@ exports.default = (0, vue_1.defineComponent)({
15
15
  setup(props) {
16
16
  const radio = (0, use_radio_1.default)(props);
17
17
  const themeRef = (0, _mixins_1.useTheme)('Radio', '-radio', radio_cssr_1.default, styles_1.radioLight, props, radio.mergedClsPrefix);
18
+ const cssVarsRef = (0, vue_1.computed)(() => {
19
+ const { mergedSize: { value: size } } = radio;
20
+ const { common: { cubicBezierEaseInOut }, self: { boxShadow, boxShadowActive, boxShadowDisabled, boxShadowFocus, boxShadowHover, color, colorDisabled, textColor, textColorDisabled, dotColorActive, dotColorDisabled, labelPadding, [(0, _utils_1.createKey)('fontSize', size)]: fontSize, [(0, _utils_1.createKey)('radioSize', size)]: radioSize } } = themeRef.value;
21
+ return {
22
+ '--n-bezier': cubicBezierEaseInOut,
23
+ '--n-box-shadow': boxShadow,
24
+ '--n-box-shadow-active': boxShadowActive,
25
+ '--n-box-shadow-disabled': boxShadowDisabled,
26
+ '--n-box-shadow-focus': boxShadowFocus,
27
+ '--n-box-shadow-hover': boxShadowHover,
28
+ '--n-color': color,
29
+ '--n-color-disabled': colorDisabled,
30
+ '--n-dot-color-active': dotColorActive,
31
+ '--n-dot-color-disabled': dotColorDisabled,
32
+ '--n-font-size': fontSize,
33
+ '--n-radio-size': radioSize,
34
+ '--n-text-color': textColor,
35
+ '--n-text-color-disabled': textColorDisabled,
36
+ '--n-label-padding': labelPadding
37
+ };
38
+ });
39
+ const { inlineThemeDisabled } = (0, _mixins_1.useConfig)(props);
40
+ const themeClassHandle = inlineThemeDisabled
41
+ ? (0, _mixins_1.useThemeClass)('radio', (0, vue_1.computed)(() => radio.mergedSize.value[0]), cssVarsRef, props)
42
+ : undefined;
18
43
  return Object.assign(radio, {
19
- cssVars: (0, vue_1.computed)(() => {
20
- const { mergedSize: { value: size } } = radio;
21
- const { common: { cubicBezierEaseInOut }, self: { boxShadow, boxShadowActive, boxShadowDisabled, boxShadowFocus, boxShadowHover, color, colorDisabled, textColor, textColorDisabled, dotColorActive, dotColorDisabled, labelPadding, [(0, _utils_1.createKey)('fontSize', size)]: fontSize, [(0, _utils_1.createKey)('radioSize', size)]: radioSize } } = themeRef.value;
22
- return {
23
- '--n-bezier': cubicBezierEaseInOut,
24
- '--n-box-shadow': boxShadow,
25
- '--n-box-shadow-active': boxShadowActive,
26
- '--n-box-shadow-disabled': boxShadowDisabled,
27
- '--n-box-shadow-focus': boxShadowFocus,
28
- '--n-box-shadow-hover': boxShadowHover,
29
- '--n-color': color,
30
- '--n-color-disabled': colorDisabled,
31
- '--n-dot-color-active': dotColorActive,
32
- '--n-dot-color-disabled': dotColorDisabled,
33
- '--n-font-size': fontSize,
34
- '--n-radio-size': radioSize,
35
- '--n-text-color': textColor,
36
- '--n-text-color-disabled': textColorDisabled,
37
- '--n-label-padding': labelPadding
38
- };
39
- })
44
+ cssVars: inlineThemeDisabled ? undefined : cssVarsRef,
45
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
46
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
40
47
  });
41
48
  },
42
49
  render() {
43
- const { $slots, mergedClsPrefix } = this;
50
+ const { $slots, mergedClsPrefix, onRender } = this;
51
+ onRender === null || onRender === void 0 ? void 0 : onRender();
44
52
  return ((0, vue_1.h)("label", { class: [
45
53
  `${mergedClsPrefix}-radio`,
54
+ this.themeClass,
46
55
  {
47
56
  [`${mergedClsPrefix}-radio--disabled`]: this.mergedDisabled,
48
57
  [`${mergedClsPrefix}-radio--checked`]: this.renderSafeChecked,
@@ -268,7 +268,9 @@ declare const _default: import("vue").DefineComponent<{
268
268
  '--n-button-text-color-active': string;
269
269
  '--n-height': string;
270
270
  '--n-opacity-disabled': string;
271
- }>;
271
+ }> | undefined;
272
+ themeClass: import("vue").Ref<string> | undefined;
273
+ onRender: (() => void) | undefined;
272
274
  }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
273
275
  readonly name: StringConstructor;
274
276
  readonly value: PropType<string | number | null>;
@@ -80,7 +80,7 @@ exports.default = (0, vue_1.defineComponent)({
80
80
  setup(props) {
81
81
  const selfElRef = (0, vue_1.ref)(null);
82
82
  const { mergedSizeRef, mergedDisabledRef, nTriggerFormChange, nTriggerFormInput, nTriggerFormBlur, nTriggerFormFocus } = (0, _mixins_1.useFormItem)(props);
83
- const { mergedClsPrefixRef } = (0, _mixins_1.useConfig)(props);
83
+ const { mergedClsPrefixRef, inlineThemeDisabled } = (0, _mixins_1.useConfig)(props);
84
84
  const themeRef = (0, _mixins_1.useTheme)('Radio', '-radio-group', radio_group_cssr_1.default, styles_1.radioLight, props, mergedClsPrefixRef);
85
85
  const uncontrolledValueRef = (0, vue_1.ref)(props.defaultValue);
86
86
  const controlledValueRef = (0, vue_1.toRef)(props, 'value');
@@ -121,39 +121,48 @@ exports.default = (0, vue_1.defineComponent)({
121
121
  mergedSizeRef,
122
122
  doUpdateValue
123
123
  });
124
+ const cssVarsRef = (0, vue_1.computed)(() => {
125
+ const { value: size } = mergedSizeRef;
126
+ const { common: { cubicBezierEaseInOut }, self: { buttonBorderColor, buttonBorderColorActive, buttonBorderRadius, buttonBoxShadow, buttonBoxShadowFocus, buttonBoxShadowHover, buttonColorActive, buttonTextColor, buttonTextColorActive, buttonTextColorHover, opacityDisabled, [(0, _utils_1.createKey)('buttonHeight', size)]: height, [(0, _utils_1.createKey)('fontSize', size)]: fontSize } } = themeRef.value;
127
+ return {
128
+ '--n-font-size': fontSize,
129
+ '--n-bezier': cubicBezierEaseInOut,
130
+ '--n-button-border-color': buttonBorderColor,
131
+ '--n-button-border-color-active': buttonBorderColorActive,
132
+ '--n-button-border-radius': buttonBorderRadius,
133
+ '--n-button-box-shadow': buttonBoxShadow,
134
+ '--n-button-box-shadow-focus': buttonBoxShadowFocus,
135
+ '--n-button-box-shadow-hover': buttonBoxShadowHover,
136
+ '--n-button-color-active': buttonColorActive,
137
+ '--n-button-text-color': buttonTextColor,
138
+ '--n-button-text-color-hover': buttonTextColorHover,
139
+ '--n-button-text-color-active': buttonTextColorActive,
140
+ '--n-height': height,
141
+ '--n-opacity-disabled': opacityDisabled
142
+ };
143
+ });
144
+ const themeClassHandle = inlineThemeDisabled
145
+ ? (0, _mixins_1.useThemeClass)('radio-group', (0, vue_1.computed)(() => mergedSizeRef.value[0]), cssVarsRef, props)
146
+ : undefined;
124
147
  return {
125
148
  selfElRef,
126
149
  mergedClsPrefix: mergedClsPrefixRef,
127
150
  mergedValue: mergedValueRef,
128
151
  handleFocusout,
129
152
  handleFocusin,
130
- cssVars: (0, vue_1.computed)(() => {
131
- const { value: size } = mergedSizeRef;
132
- const { common: { cubicBezierEaseInOut }, self: { buttonBorderColor, buttonBorderColorActive, buttonBorderRadius, buttonBoxShadow, buttonBoxShadowFocus, buttonBoxShadowHover, buttonColorActive, buttonTextColor, buttonTextColorActive, buttonTextColorHover, opacityDisabled, [(0, _utils_1.createKey)('buttonHeight', size)]: height, [(0, _utils_1.createKey)('fontSize', size)]: fontSize } } = themeRef.value;
133
- return {
134
- '--n-font-size': fontSize,
135
- '--n-bezier': cubicBezierEaseInOut,
136
- '--n-button-border-color': buttonBorderColor,
137
- '--n-button-border-color-active': buttonBorderColorActive,
138
- '--n-button-border-radius': buttonBorderRadius,
139
- '--n-button-box-shadow': buttonBoxShadow,
140
- '--n-button-box-shadow-focus': buttonBoxShadowFocus,
141
- '--n-button-box-shadow-hover': buttonBoxShadowHover,
142
- '--n-button-color-active': buttonColorActive,
143
- '--n-button-text-color': buttonTextColor,
144
- '--n-button-text-color-hover': buttonTextColorHover,
145
- '--n-button-text-color-active': buttonTextColorActive,
146
- '--n-height': height,
147
- '--n-opacity-disabled': opacityDisabled
148
- };
149
- })
153
+ cssVars: inlineThemeDisabled ? undefined : cssVarsRef,
154
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
155
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
150
156
  };
151
157
  },
152
158
  render() {
159
+ var _a;
153
160
  const { mergedValue, mergedClsPrefix, handleFocusin, handleFocusout } = this;
154
161
  const { children, isButtonGroup } = mapSlot((0, _utils_1.flatten)((0, _utils_1.getSlot)(this)), mergedValue, mergedClsPrefix);
162
+ (_a = this.onRender) === null || _a === void 0 ? void 0 : _a.call(this);
155
163
  return ((0, vue_1.h)("div", { onFocusin: handleFocusin, onFocusout: handleFocusout, ref: "selfElRef", class: [
156
164
  `${mergedClsPrefix}-radio-group`,
165
+ this.themeClass,
157
166
  isButtonGroup && `${mergedClsPrefix}-radio-group--button-group`
158
167
  ], style: this.cssVars }, children));
159
168
  }
@@ -94,7 +94,9 @@ declare const _default: import("vue").DefineComponent<{
94
94
  '--n-item-color': string;
95
95
  '--n-item-color-active': string;
96
96
  '--n-item-size': string;
97
- }>;
97
+ }> | undefined;
98
+ themeClass: import("vue").Ref<string> | undefined;
99
+ onRender: (() => void) | undefined;
98
100
  }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
99
101
  readonly allowHalf: BooleanConstructor;
100
102
  readonly count: {
@@ -25,7 +25,7 @@ exports.default = (0, vue_1.defineComponent)({
25
25
  name: 'Rate',
26
26
  props: rateProps,
27
27
  setup(props) {
28
- const { mergedClsPrefixRef } = (0, _mixins_1.useConfig)(props);
28
+ const { mergedClsPrefixRef, inlineThemeDisabled } = (0, _mixins_1.useConfig)(props);
29
29
  const themeRef = (0, _mixins_1.useTheme)('Rate', '-rate', index_cssr_1.default, styles_1.rateLight, props, mergedClsPrefixRef);
30
30
  const controlledValueRef = (0, vue_1.toRef)(props, 'value');
31
31
  const uncontrolledValueRef = (0, vue_1.ref)(props.defaultValue);
@@ -67,6 +67,40 @@ exports.default = (0, vue_1.defineComponent)({
67
67
  function handleClick(index, e) {
68
68
  doUpdateValue(getDerivedValue(index, e));
69
69
  }
70
+ const mergedSizeRef = (0, vue_1.computed)(() => {
71
+ const { size } = props;
72
+ const { self } = themeRef.value;
73
+ if (typeof size === 'number') {
74
+ return `${size}px`;
75
+ }
76
+ else {
77
+ return self[(0, _utils_1.createKey)('size', size)];
78
+ }
79
+ });
80
+ const cssVarsRef = (0, vue_1.computed)(() => {
81
+ const { common: { cubicBezierEaseInOut }, self } = themeRef.value;
82
+ const { itemColor, itemColorActive } = self;
83
+ return {
84
+ '--n-bezier': cubicBezierEaseInOut,
85
+ '--n-item-color': itemColor,
86
+ '--n-item-color-active': props.color || itemColorActive,
87
+ '--n-item-size': mergedSizeRef.value
88
+ };
89
+ });
90
+ const themeClassHandle = inlineThemeDisabled
91
+ ? (0, _mixins_1.useThemeClass)('rate', (0, vue_1.computed)(() => {
92
+ const size = mergedSizeRef.value;
93
+ const { color } = props;
94
+ let hash = '';
95
+ if (size) {
96
+ hash += size[0];
97
+ }
98
+ if (color) {
99
+ hash += (0, _utils_1.color2Class)(color);
100
+ }
101
+ return hash;
102
+ }), cssVarsRef, props)
103
+ : undefined;
70
104
  return {
71
105
  mergedClsPrefix: mergedClsPrefixRef,
72
106
  mergedValue: (0, vooks_1.useMergedState)(controlledValueRef, uncontrolledValueRef),
@@ -74,33 +108,20 @@ exports.default = (0, vue_1.defineComponent)({
74
108
  handleMouseMove,
75
109
  handleClick,
76
110
  handleMouseLeave,
77
- cssVars: (0, vue_1.computed)(() => {
78
- const { size } = props;
79
- const { common: { cubicBezierEaseInOut }, self } = themeRef.value;
80
- const { itemColor, itemColorActive } = self;
81
- let mergedSize;
82
- if (typeof size === 'number') {
83
- mergedSize = `${size}px`;
84
- }
85
- else {
86
- mergedSize = self[(0, _utils_1.createKey)('size', size)];
87
- }
88
- return {
89
- '--n-bezier': cubicBezierEaseInOut,
90
- '--n-item-color': itemColor,
91
- '--n-item-color-active': props.color || itemColorActive,
92
- '--n-item-size': mergedSize
93
- };
94
- })
111
+ cssVars: inlineThemeDisabled ? undefined : cssVarsRef,
112
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
113
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
95
114
  };
96
115
  },
97
116
  render() {
98
- const { readonly, hoverIndex, mergedValue, mergedClsPrefix, $slots: { default: defaultSlot } } = this;
117
+ const { readonly, hoverIndex, mergedValue, mergedClsPrefix, onRender, $slots: { default: defaultSlot } } = this;
118
+ onRender === null || onRender === void 0 ? void 0 : onRender();
99
119
  return ((0, vue_1.h)("div", { class: [
100
120
  `${mergedClsPrefix}-rate`,
101
121
  {
102
122
  [`${mergedClsPrefix}-rate--readonly`]: readonly
103
- }
123
+ },
124
+ this.themeClass
104
125
  ], style: this.cssVars, onMouseleave: this.handleMouseLeave }, (0, vue_1.renderList)(this.count, (_, index) => {
105
126
  const icon = defaultSlot ? (defaultSlot()) : ((0, vue_1.h)(_internal_1.NBaseIcon, { clsPrefix: mergedClsPrefix }, { default: () => StarIcon_1.default }));
106
127
  const fullStarActive = hoverIndex !== null
@@ -191,8 +191,10 @@ declare const _default: import("vue").DefineComponent<{
191
191
  '--n-title-font-size': string;
192
192
  '--n-title-font-weight': string;
193
193
  '--n-title-text-color': string;
194
- '--n-icon-color': string | undefined;
195
- }>;
194
+ '--n-icon-color': string;
195
+ }> | undefined;
196
+ themeClass: import("vue").Ref<string> | undefined;
197
+ onRender: (() => void) | undefined;
196
198
  }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
197
199
  size: {
198
200
  type: PropType<"small" | "medium" | "large" | "huge">;
@@ -35,31 +35,48 @@ exports.default = (0, vue_1.defineComponent)({
35
35
  name: 'Result',
36
36
  props: resultProps,
37
37
  setup(props) {
38
- const { mergedClsPrefixRef } = (0, _mixins_1.useConfig)(props);
38
+ const { mergedClsPrefixRef, inlineThemeDisabled } = (0, _mixins_1.useConfig)(props);
39
39
  const themeRef = (0, _mixins_1.useTheme)('Result', '-result', index_cssr_1.default, styles_1.resultLight, props, mergedClsPrefixRef);
40
+ const cssVarsRef = (0, vue_1.computed)(() => {
41
+ const { size, status } = props;
42
+ const { common: { cubicBezierEaseInOut }, self: { textColor, lineHeight, titleTextColor, titleFontWeight, [(0, _utils_1.createKey)('iconColor', status)]: iconColor, [(0, _utils_1.createKey)('fontSize', size)]: fontSize, [(0, _utils_1.createKey)('titleFontSize', size)]: titleFontSize, [(0, _utils_1.createKey)('iconSize', size)]: iconSize } } = themeRef.value;
43
+ return {
44
+ '--n-bezier': cubicBezierEaseInOut,
45
+ '--n-font-size': fontSize,
46
+ '--n-icon-size': iconSize,
47
+ '--n-line-height': lineHeight,
48
+ '--n-text-color': textColor,
49
+ '--n-title-font-size': titleFontSize,
50
+ '--n-title-font-weight': titleFontWeight,
51
+ '--n-title-text-color': titleTextColor,
52
+ '--n-icon-color': iconColor || ''
53
+ };
54
+ });
55
+ const themeClassHandle = inlineThemeDisabled
56
+ ? (0, _mixins_1.useThemeClass)('result', (0, vue_1.computed)(() => {
57
+ const { size, status } = props;
58
+ let hash = '';
59
+ if (size) {
60
+ hash += size[0];
61
+ }
62
+ if (status) {
63
+ hash += status[0];
64
+ }
65
+ return hash;
66
+ }), cssVarsRef, props)
67
+ : undefined;
40
68
  return {
41
69
  mergedClsPrefix: mergedClsPrefixRef,
42
- cssVars: (0, vue_1.computed)(() => {
43
- const { size, status } = props;
44
- const { common: { cubicBezierEaseInOut }, self: { textColor, lineHeight, titleTextColor, titleFontWeight, [(0, _utils_1.createKey)('iconColor', status)]: iconColor, [(0, _utils_1.createKey)('fontSize', size)]: fontSize, [(0, _utils_1.createKey)('titleFontSize', size)]: titleFontSize, [(0, _utils_1.createKey)('iconSize', size)]: iconSize } } = themeRef.value;
45
- return {
46
- '--n-bezier': cubicBezierEaseInOut,
47
- '--n-font-size': fontSize,
48
- '--n-icon-size': iconSize,
49
- '--n-line-height': lineHeight,
50
- '--n-text-color': textColor,
51
- '--n-title-font-size': titleFontSize,
52
- '--n-title-font-weight': titleFontWeight,
53
- '--n-title-text-color': titleTextColor,
54
- '--n-icon-color': iconColor
55
- };
56
- })
70
+ cssVars: inlineThemeDisabled ? undefined : cssVarsRef,
71
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
72
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
57
73
  };
58
74
  },
59
75
  render() {
60
76
  var _a;
61
- const { status, $slots, mergedClsPrefix } = this;
62
- return ((0, vue_1.h)("div", { class: `${mergedClsPrefix}-result`, style: this.cssVars },
77
+ const { status, $slots, mergedClsPrefix, onRender } = this;
78
+ onRender === null || onRender === void 0 ? void 0 : onRender();
79
+ return ((0, vue_1.h)("div", { class: [`${mergedClsPrefix}-result`, this.themeClass], style: this.cssVars },
63
80
  (0, vue_1.h)("div", { class: `${mergedClsPrefix}-result-icon` }, ((_a = $slots.icon) === null || _a === void 0 ? void 0 : _a.call($slots)) || ((0, vue_1.h)(_internal_1.NBaseIcon, { clsPrefix: mergedClsPrefix }, { default: () => iconMap[status] }))),
64
81
  (0, vue_1.h)("div", { class: `${mergedClsPrefix}-result-header` },
65
82
  this.title ? ((0, vue_1.h)("div", { class: `${mergedClsPrefix}-result-header__title` }, this.title)) : null,
@@ -8,8 +8,10 @@ export interface ScrollTo {
8
8
  behavior?: ScrollBehavior;
9
9
  }): void;
10
10
  }
11
+ export declare type ScrollBy = ScrollTo;
11
12
  export interface ScrollbarInst {
12
13
  scrollTo: ScrollTo;
14
+ scrollBy: ScrollBy;
13
15
  }
14
16
  declare const scrollbarProps: {
15
17
  readonly xScrollable: BooleanConstructor;
@@ -45,9 +47,18 @@ declare const Scrollbar: import("vue").DefineComponent<{
45
47
  }, any>>>;
46
48
  }, {
47
49
  scrollbarInstRef: import("vue").Ref<{
48
- scrollTo: ScrollTo;
50
+ containerRef: HTMLElement | null;
51
+ contentRef: HTMLElement | null;
52
+ containerScrollTop: number;
53
+ syncUnifiedContainer: () => void;
54
+ scrollTo: import("../../_internal/scrollbar/src/ScrollBar").ScrollTo;
55
+ scrollBy: import("../../_internal/scrollbar/src/ScrollBar").ScrollBy;
56
+ sync: () => void;
57
+ handleMouseEnterWrapper: () => void;
58
+ handleMouseLeaveWrapper: () => void;
49
59
  } | null>;
50
60
  scrollTo: ScrollTo;
61
+ scrollBy: ScrollBy;
51
62
  }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
52
63
  readonly xScrollable: BooleanConstructor;
53
64
  readonly onScroll: PropType<(e: Event) => void>;
@@ -13,6 +13,10 @@ const Scrollbar = (0, vue_1.defineComponent)({
13
13
  scrollTo: (...args) => {
14
14
  var _a;
15
15
  (_a = scrollbarInstRef.value) === null || _a === void 0 ? void 0 : _a.scrollTo(args[0], args[1]);
16
+ },
17
+ scrollBy: (...args) => {
18
+ var _a;
19
+ (_a = scrollbarInstRef.value) === null || _a === void 0 ? void 0 : _a.scrollBy(args[0], args[1]);
16
20
  }
17
21
  };
18
22
  return Object.assign(Object.assign({}, exposedMethods), { scrollbarInstRef });
@@ -998,7 +998,7 @@ declare const _default: import("vue").DefineComponent<{
998
998
  mergedDisabled: import("vue").ComputedRef<boolean>;
999
999
  focused: import("vue").Ref<boolean>;
1000
1000
  activeWithoutMenuOpen: import("vue").Ref<boolean>;
1001
- disableInlineTheme: boolean | undefined;
1001
+ inlineThemeDisabled: boolean | undefined;
1002
1002
  onTriggerInputFocus: () => void;
1003
1003
  onTriggerInputBlur: () => void;
1004
1004
  handleMenuFocus: (e: FocusEvent) => void;
@@ -88,7 +88,7 @@ exports.default = (0, vue_1.defineComponent)({
88
88
  }
89
89
  });
90
90
  }
91
- const { mergedClsPrefixRef, mergedBorderedRef, namespaceRef, NConfigProvider } = (0, _mixins_1.useConfig)(props);
91
+ const { mergedClsPrefixRef, mergedBorderedRef, namespaceRef, inlineThemeDisabled } = (0, _mixins_1.useConfig)(props);
92
92
  const themeRef = (0, _mixins_1.useTheme)('Select', '-select', index_cssr_1.default, styles_1.selectLight, props, mergedClsPrefixRef);
93
93
  const uncontrolledValueRef = (0, vue_1.ref)(props.defaultValue);
94
94
  const controlledValueRef = (0, vue_1.toRef)(props, 'value');
@@ -573,7 +573,8 @@ exports.default = (0, vue_1.defineComponent)({
573
573
  }
574
574
  };
575
575
  return Object.assign(Object.assign({}, exposedMethods), { mergedStatus: mergedStatusRef, mergedClsPrefix: mergedClsPrefixRef, mergedBordered: mergedBorderedRef, namespace: namespaceRef, treeMate: treeMateRef, isMounted: (0, vooks_1.useIsMounted)(), triggerRef,
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,
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, inlineThemeDisabled,
577
+ onTriggerInputFocus,
577
578
  onTriggerInputBlur,
578
579
  handleMenuFocus,
579
580
  handleMenuBlur,
@@ -598,7 +599,7 @@ exports.default = (0, vue_1.defineComponent)({
598
599
  (0, vue_1.h)(vueuc_1.VBinder, null, {
599
600
  default: () => [
600
601
  (0, vue_1.h)(vueuc_1.VTarget, null, {
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 }, {
602
+ default: () => ((0, vue_1.h)(_internal_1.NInternalSelection, { ref: "triggerRef", inlineThemeDisabled: this.inlineThemeDisabled, 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 }, {
602
603
  arrow: () => { var _a, _b; return [(_b = (_a = this.$slots).arrow) === null || _b === void 0 ? void 0 : _b.call(_a)]; }
603
604
  }))
604
605
  }),
@@ -608,7 +609,7 @@ exports.default = (0, vue_1.defineComponent)({
608
609
  var _a, _b;
609
610
  return (this.mergedShow ||
610
611
  this.displayDirective === 'show') &&
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: [
612
+ (0, vue_1.withDirectives)((0, vue_1.h)(_internal_1.NInternalSelectMenu, Object.assign({}, this.menuProps, { ref: "menuRef", inlineThemeDisabled: this.inlineThemeDisabled, virtualScroll: this.consistentMenuWidth && this.virtualScroll, class: [
612
613
  `${this.mergedClsPrefix}-select-menu`,
613
614
  (_a = this.menuProps) === null || _a === void 0 ? void 0 : _a.class
614
615
  ], clsPrefix: this.mergedClsPrefix, focusable: true, autoPending: true, theme: this.mergedTheme.peers.InternalSelectMenu, themeOverrides: this.mergedTheme.peerOverrides
@@ -120,7 +120,9 @@ declare const _default: import("vue").DefineComponent<{
120
120
  '--n-size': string;
121
121
  '--n-color': string;
122
122
  '--n-text-color': string;
123
- }>;
123
+ }> | undefined;
124
+ themeClass: import("vue").Ref<string> | undefined;
125
+ onRender: (() => void) | undefined;
124
126
  }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
125
127
  description: StringConstructor;
126
128
  stroke: StringConstructor;
@@ -43,8 +43,29 @@ exports.default = (0, vue_1.defineComponent)({
43
43
  }
44
44
  });
45
45
  }
46
- const { mergedClsPrefixRef } = (0, _mixins_1.useConfig)(props);
46
+ const { mergedClsPrefixRef, inlineThemeDisabled } = (0, _mixins_1.useConfig)(props);
47
47
  const themeRef = (0, _mixins_1.useTheme)('Spin', '-spin', index_cssr_1.default, styles_1.spinLight, props, mergedClsPrefixRef);
48
+ const cssVarsRef = (0, vue_1.computed)(() => {
49
+ const { size: spinSize } = props;
50
+ const { common: { cubicBezierEaseInOut }, self } = themeRef.value;
51
+ const { opacitySpinning, color, textColor } = self;
52
+ const size = typeof spinSize === 'number'
53
+ ? (0, seemly_1.pxfy)(spinSize)
54
+ : self[(0, _utils_1.createKey)('size', spinSize)];
55
+ return {
56
+ '--n-bezier': cubicBezierEaseInOut,
57
+ '--n-opacity-spinning': opacitySpinning,
58
+ '--n-size': size,
59
+ '--n-color': color,
60
+ '--n-text-color': textColor
61
+ };
62
+ });
63
+ const themeClassHandle = inlineThemeDisabled
64
+ ? (0, _mixins_1.useThemeClass)('spin', (0, vue_1.computed)(() => {
65
+ const { size } = props;
66
+ return typeof size === 'number' ? String(size) : size[0];
67
+ }), cssVarsRef, props)
68
+ : undefined;
48
69
  return {
49
70
  mergedClsPrefix: mergedClsPrefixRef,
50
71
  compitableShow: (0, vooks_1.useCompitable)(props, ['spinning', 'show']),
@@ -55,37 +76,26 @@ exports.default = (0, vue_1.defineComponent)({
55
76
  const { size } = props;
56
77
  return STROKE_WIDTH[typeof size === 'number' ? 'medium' : size];
57
78
  }),
58
- cssVars: (0, vue_1.computed)(() => {
59
- const { size: spinSize } = props;
60
- const { common: { cubicBezierEaseInOut }, self } = themeRef.value;
61
- const { opacitySpinning, color, textColor } = self;
62
- const size = typeof spinSize === 'number'
63
- ? (0, seemly_1.pxfy)(spinSize)
64
- : self[(0, _utils_1.createKey)('size', spinSize)];
65
- return {
66
- '--n-bezier': cubicBezierEaseInOut,
67
- '--n-opacity-spinning': opacitySpinning,
68
- '--n-size': size,
69
- '--n-color': color,
70
- '--n-text-color': textColor
71
- };
72
- })
79
+ cssVars: inlineThemeDisabled ? undefined : cssVarsRef,
80
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
81
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
73
82
  };
74
83
  },
75
84
  render() {
76
- var _a;
85
+ var _a, _b;
77
86
  const { $slots, mergedClsPrefix, description } = this;
78
87
  const rotate = $slots.icon && this.rotate;
79
88
  const descriptionNode = (description || $slots.description) && ((0, vue_1.h)("div", { class: `${mergedClsPrefix}-spin-description` }, description || ((_a = $slots.description) === null || _a === void 0 ? void 0 : _a.call($slots))));
80
- const icon = $slots.icon ? ((0, vue_1.h)("div", { class: `${mergedClsPrefix}-spin-body` },
89
+ const icon = $slots.icon ? ((0, vue_1.h)("div", { class: [`${mergedClsPrefix}-spin-body`, this.themeClass] },
81
90
  (0, vue_1.h)("div", { class: [
82
91
  `${mergedClsPrefix}-spin`,
83
92
  rotate && `${mergedClsPrefix}-spin--rotate`
84
93
  ], style: $slots.default ? '' : this.cssVars }, $slots.icon()),
85
- descriptionNode)) : ((0, vue_1.h)("div", { class: `${mergedClsPrefix}-spin-body` },
94
+ descriptionNode)) : ((0, vue_1.h)("div", { class: [`${mergedClsPrefix}-spin-body`, this.themeClass] },
86
95
  (0, vue_1.h)(_internal_1.NBaseLoading, { clsPrefix: mergedClsPrefix, style: $slots.default ? '' : this.cssVars, stroke: this.stroke, "stroke-width": this.mergedStrokeWidth, class: `${mergedClsPrefix}-spin` }),
87
96
  descriptionNode));
88
- return $slots.default ? ((0, vue_1.h)("div", { class: `${mergedClsPrefix}-spin-container`, style: this.cssVars },
97
+ (_b = this.onRender) === null || _b === void 0 ? void 0 : _b.call(this);
98
+ return $slots.default ? ((0, vue_1.h)("div", { class: [`${mergedClsPrefix}-spin-container`, this.themeClass], style: this.cssVars },
89
99
  (0, vue_1.h)("div", { class: [
90
100
  `${mergedClsPrefix}-spin-content`,
91
101
  this.compitableShow && `${mergedClsPrefix}-spin-content--spinning`
@@ -74,7 +74,9 @@ declare const _default: import("vue").DefineComponent<{
74
74
  '--n-value-prefix-text-color': string;
75
75
  '--n-value-suffix-text-color': string;
76
76
  '--n-value-text-color': string;
77
- }>;
77
+ }> | undefined;
78
+ themeClass: import("vue").Ref<string> | undefined;
79
+ onRender: (() => void) | undefined;
78
80
  }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
79
81
  tabularNums: BooleanConstructor;
80
82
  label: StringConstructor;
@@ -5,6 +5,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  const vue_1 = require("vue");
7
7
  const _mixins_1 = require("../../_mixins");
8
+ const _utils_1 = require("../../_utils");
8
9
  const styles_1 = require("../styles");
9
10
  const index_cssr_1 = __importDefault(require("./styles/index.cssr"));
10
11
  const statisticProps = Object.assign(Object.assign({}, _mixins_1.useTheme.props), { tabularNums: Boolean, label: String, value: [String, Number] });
@@ -12,35 +13,42 @@ exports.default = (0, vue_1.defineComponent)({
12
13
  name: 'Statistic',
13
14
  props: statisticProps,
14
15
  setup(props) {
15
- const { mergedClsPrefixRef } = (0, _mixins_1.useConfig)(props);
16
+ const { mergedClsPrefixRef, inlineThemeDisabled } = (0, _mixins_1.useConfig)(props);
16
17
  const themeRef = (0, _mixins_1.useTheme)('Statistic', '-statistic', index_cssr_1.default, styles_1.statisticLight, props, mergedClsPrefixRef);
18
+ const cssVarsRef = (0, vue_1.computed)(() => {
19
+ const { self: { labelFontWeight, valueFontWeight, valuePrefixTextColor, labelTextColor, valueSuffixTextColor, valueTextColor, labelFontSize }, common: { cubicBezierEaseInOut } } = themeRef.value;
20
+ return {
21
+ '--n-bezier': cubicBezierEaseInOut,
22
+ '--n-label-font-size': labelFontSize,
23
+ '--n-label-font-weight': labelFontWeight,
24
+ '--n-label-text-color': labelTextColor,
25
+ '--n-value-font-weight': valueFontWeight,
26
+ '--n-value-prefix-text-color': valuePrefixTextColor,
27
+ '--n-value-suffix-text-color': valueSuffixTextColor,
28
+ '--n-value-text-color': valueTextColor
29
+ };
30
+ });
31
+ const themeClassHandle = inlineThemeDisabled
32
+ ? (0, _mixins_1.useThemeClass)('statistic', undefined, cssVarsRef, props)
33
+ : undefined;
17
34
  return {
18
35
  mergedClsPrefix: mergedClsPrefixRef,
19
- cssVars: (0, vue_1.computed)(() => {
20
- const { self: { labelFontWeight, valueFontWeight, valuePrefixTextColor, labelTextColor, valueSuffixTextColor, valueTextColor, labelFontSize }, common: { cubicBezierEaseInOut } } = themeRef.value;
21
- return {
22
- '--n-bezier': cubicBezierEaseInOut,
23
- '--n-label-font-size': labelFontSize,
24
- '--n-label-font-weight': labelFontWeight,
25
- '--n-label-text-color': labelTextColor,
26
- '--n-value-font-weight': valueFontWeight,
27
- '--n-value-prefix-text-color': valuePrefixTextColor,
28
- '--n-value-suffix-text-color': valueSuffixTextColor,
29
- '--n-value-text-color': valueTextColor
30
- };
31
- })
36
+ cssVars: inlineThemeDisabled ? undefined : cssVarsRef,
37
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
38
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
32
39
  };
33
40
  },
34
41
  render() {
35
42
  var _a;
36
- const { $slots, mergedClsPrefix } = this;
37
- return ((0, vue_1.h)("div", { class: `${mergedClsPrefix}-statistic`, style: this.cssVars },
38
- (0, vue_1.h)("div", { class: `${mergedClsPrefix}-statistic__label` }, this.label || ((_a = $slots.label) === null || _a === void 0 ? void 0 : _a.call($slots))),
43
+ const { mergedClsPrefix, $slots: { default: defaultSlot, label: labelSlot, prefix: prefixSlot, suffix: suffixSlot } } = this;
44
+ (_a = this.onRender) === null || _a === void 0 ? void 0 : _a.call(this);
45
+ return ((0, vue_1.h)("div", { class: [`${mergedClsPrefix}-statistic`, this.themeClass], style: this.cssVars },
46
+ (0, _utils_1.resolveWrappedSlot)(labelSlot, (children) => ((0, vue_1.h)("div", { class: `${mergedClsPrefix}-statistic__label` }, this.label || children))),
39
47
  (0, vue_1.h)("div", { class: `${mergedClsPrefix}-statistic-value`, style: {
40
48
  fontVariantNumeric: this.tabularNums ? 'tabular-nums' : ''
41
49
  } },
42
- $slots.prefix ? ((0, vue_1.h)("span", { class: `${mergedClsPrefix}-statistic-value__prefix` }, $slots.prefix())) : null,
43
- this.value !== undefined ? ((0, vue_1.h)("span", { class: `${mergedClsPrefix}-statistic-value__content` }, this.value)) : ((0, vue_1.h)("span", { class: `${mergedClsPrefix}-statistic-value__content` }, $slots)),
44
- $slots.suffix ? ((0, vue_1.h)("span", { class: `${mergedClsPrefix}-statistic-value__suffix` }, $slots.suffix())) : null)));
50
+ (0, _utils_1.resolveWrappedSlot)(prefixSlot, (children) => children && ((0, vue_1.h)("span", { class: `${mergedClsPrefix}-statistic-value__prefix` }, children))),
51
+ this.value !== undefined ? ((0, vue_1.h)("span", { class: `${mergedClsPrefix}-statistic-value__content` }, this.value)) : ((0, _utils_1.resolveWrappedSlot)(defaultSlot, (children) => children && ((0, vue_1.h)("span", { class: `${mergedClsPrefix}-statistic-value__content` }, children)))),
52
+ (0, _utils_1.resolveWrappedSlot)(suffixSlot, (children) => children && ((0, vue_1.h)("span", { class: `${mergedClsPrefix}-statistic-value__suffix` }, children))))));
45
53
  }
46
54
  });
package/lib/styles.d.ts CHANGED
@@ -65,6 +65,7 @@ export { treeDark } from './tree/styles';
65
65
  export { treeSelectDark } from './tree-select/styles';
66
66
  export { typographyDark } from './typography/styles';
67
67
  export { uploadDark } from './upload/styles';
68
+ export { watermarkDark } from './watermark/styles';
68
69
  export { scrollbarDark } from './_internal/scrollbar/styles';
69
70
  export { internalSelectMenuDark } from './_internal/select-menu/styles';
70
71
  export { internalSelectionDark } from './_internal/selection/styles';