naive-ui 2.23.1 → 2.23.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 (450) hide show
  1. package/es/_internal/clear/src/styles/index.cssr.js +10 -10
  2. package/es/_internal/close/src/styles/index.cssr.js +9 -10
  3. package/es/_internal/icons/Close.js +1 -1
  4. package/es/_internal/scrollbar/src/ScrollBar.d.ts +6 -6
  5. package/es/_internal/scrollbar/src/ScrollBar.js +11 -10
  6. package/es/_internal/scrollbar/src/styles/index.cssr.js +15 -15
  7. package/es/_internal/select-menu/src/SelectMenu.d.ts +21 -21
  8. package/es/_internal/select-menu/src/SelectMenu.js +21 -21
  9. package/es/_internal/select-menu/src/styles/index.cssr.js +35 -35
  10. package/es/_internal/select-menu/styles/_common.js +1 -1
  11. package/es/_internal/selection/src/Selection.d.ts +44 -44
  12. package/es/_internal/selection/src/Selection.js +44 -44
  13. package/es/_internal/selection/src/styles/index.cssr.js +78 -78
  14. package/es/_mixins/common.d.ts +1 -0
  15. package/es/_mixins/common.js +1 -0
  16. package/es/_mixins/index.d.ts +1 -0
  17. package/es/_mixins/index.js +1 -0
  18. package/es/_mixins/use-css-vars-class.d.ts +2 -0
  19. package/es/_mixins/use-css-vars-class.js +22 -0
  20. package/es/_mixins/use-rtl.js +2 -0
  21. package/es/_mixins/use-style.js +3 -0
  22. package/es/_mixins/use-theme.js +3 -0
  23. package/es/_utils/composable/use-houdini.js +2 -2
  24. package/es/alert/src/Alert.d.ts +2 -2
  25. package/es/avatar/index.d.ts +2 -0
  26. package/es/avatar/index.js +1 -0
  27. package/es/avatar/src/Avatar.d.ts +67 -28
  28. package/es/avatar/src/Avatar.js +39 -11
  29. package/es/avatar/src/AvatarGroup.d.ts +52 -0
  30. package/es/avatar/src/AvatarGroup.js +61 -0
  31. package/es/avatar/src/interface.d.ts +2 -0
  32. package/es/avatar/src/interface.js +1 -0
  33. package/es/avatar/src/styles/avatar-group.cssr.d.ts +2 -0
  34. package/es/avatar/src/styles/avatar-group.cssr.js +14 -0
  35. package/es/avatar/src/styles/index.cssr.js +8 -3
  36. package/es/avatar/styles/light.d.ts +3 -0
  37. package/es/avatar/styles/light.js +6 -2
  38. package/es/breadcrumb/src/Breadcrumb.d.ts +8 -8
  39. package/es/breadcrumb/src/Breadcrumb.js +8 -8
  40. package/es/breadcrumb/src/styles/index.cssr.js +23 -23
  41. package/es/calendar/src/Calendar.d.ts +21 -21
  42. package/es/calendar/src/Calendar.js +21 -21
  43. package/es/calendar/src/styles/index.cssr.js +57 -57
  44. package/es/card/src/Card.d.ts +28 -23
  45. package/es/card/src/Card.js +24 -23
  46. package/es/card/src/styles/index.cssr.js +71 -69
  47. package/es/carousel/src/Carousel.d.ts +5 -5
  48. package/es/carousel/src/Carousel.js +5 -5
  49. package/es/carousel/src/styles/index.cssr.js +10 -10
  50. package/es/cascader/src/Cascader.d.ts +25 -17
  51. package/es/cascader/src/Cascader.js +30 -20
  52. package/es/cascader/src/CascaderMenu.js +1 -1
  53. package/es/cascader/src/styles/index.cssr.js +44 -44
  54. package/es/cascader/styles/light.js +1 -1
  55. package/es/checkbox/src/Checkbox.d.ts +23 -23
  56. package/es/checkbox/src/Checkbox.js +23 -23
  57. package/es/checkbox/src/styles/index.cssr.js +58 -58
  58. package/es/code/src/Code.d.ts +14 -14
  59. package/es/code/src/Code.js +26 -17
  60. package/es/code/src/styles/index.cssr.js +28 -28
  61. package/es/collapse/src/Collapse.d.ts +8 -8
  62. package/es/collapse/src/Collapse.js +8 -8
  63. package/es/collapse/src/styles/index.cssr.js +24 -24
  64. package/es/collapse-transition/src/CollapseTransition.d.ts +1 -1
  65. package/es/collapse-transition/src/CollapseTransition.js +1 -1
  66. package/es/color-picker/src/ColorPicker.d.ts +10 -10
  67. package/es/color-picker/src/ColorPicker.js +10 -10
  68. package/es/color-picker/src/styles/index.cssr.js +28 -28
  69. package/es/components.d.ts +2 -0
  70. package/es/components.js +2 -0
  71. package/es/countdown/index.d.ts +2 -0
  72. package/es/countdown/index.js +1 -0
  73. package/es/countdown/src/Countdown.d.ts +72 -0
  74. package/es/countdown/src/Countdown.js +126 -0
  75. package/es/countdown/src/utils.d.ts +0 -0
  76. package/es/countdown/src/utils.js +1 -0
  77. package/es/data-table/src/DataTable.d.ts +39 -39
  78. package/es/data-table/src/DataTable.js +42 -42
  79. package/es/data-table/src/TableParts/Body.js +6 -4
  80. package/es/data-table/src/styles/index.cssr.js +130 -130
  81. package/es/date-picker/src/DatePicker.d.ts +45 -45
  82. package/es/date-picker/src/DatePicker.js +45 -45
  83. package/es/date-picker/src/styles/index.cssr.js +115 -115
  84. package/es/descriptions/src/Descriptions.d.ts +18 -18
  85. package/es/descriptions/src/Descriptions.js +19 -20
  86. package/es/descriptions/src/styles/index.cssr.js +61 -61
  87. package/es/dialog/src/Dialog.d.ts +3 -3
  88. package/es/dialog/src/Dialog.js +3 -3
  89. package/es/dialog/src/DialogEnvironment.d.ts +2 -2
  90. package/es/dialog/src/DialogProvider.d.ts +1 -1
  91. package/es/drawer/src/Drawer.d.ts +19 -19
  92. package/es/drawer/src/Drawer.js +19 -19
  93. package/es/drawer/src/styles/index.cssr.js +41 -40
  94. package/es/dropdown/src/Dropdown.js +34 -32
  95. package/es/dropdown/src/styles/index.cssr.js +59 -59
  96. package/es/empty/src/Empty.d.ts +19 -15
  97. package/es/empty/src/Empty.js +12 -12
  98. package/es/empty/src/styles/index.cssr.js +20 -19
  99. package/es/form/src/FormItem.d.ts +15 -15
  100. package/es/form/src/FormItem.js +15 -15
  101. package/es/form/src/FormItemCol.d.ts +6 -0
  102. package/es/form/src/FormItemCol.js +1 -0
  103. package/es/form/src/FormItemGridItem.d.ts +6 -0
  104. package/es/form/src/FormItemGridItem.js +1 -0
  105. package/es/form/src/FormItemRow.d.ts +6 -0
  106. package/es/form/src/FormItemRow.js +1 -0
  107. package/es/form/src/styles/form-item.cssr.js +37 -37
  108. package/es/gradient-text/src/GradientText.d.ts +5 -5
  109. package/es/gradient-text/src/GradientText.js +5 -5
  110. package/es/gradient-text/src/styles/index.cssr.js +9 -9
  111. package/es/icon/src/Icon.d.ts +6 -6
  112. package/es/icon/src/Icon.js +4 -4
  113. package/es/icon/src/styles/index.cssr.js +7 -7
  114. package/es/image/src/ImagePreview.d.ts +2 -2
  115. package/es/image/src/ImagePreview.js +13 -12
  116. package/es/image/src/styles/index.cssr.js +5 -5
  117. package/es/input/src/Input.d.ts +52 -47
  118. package/es/input/src/Input.js +54 -49
  119. package/es/input/src/InputGroupLabel.d.ts +8 -8
  120. package/es/input/src/InputGroupLabel.js +8 -8
  121. package/es/input/src/styles/input-group-label.cssr.js +18 -18
  122. package/es/input/src/styles/input.cssr.js +108 -109
  123. package/es/input-number/src/InputNumber.d.ts +11 -0
  124. package/es/input-number/src/InputNumber.js +5 -2
  125. package/es/input-number/src/utils.js +2 -1
  126. package/es/layout/src/Layout.d.ts +6 -6
  127. package/es/layout/src/Layout.js +3 -3
  128. package/es/layout/src/LayoutContent.d.ts +3 -3
  129. package/es/layout/src/LayoutFooter.js +7 -7
  130. package/es/layout/src/LayoutHeader.js +7 -7
  131. package/es/layout/src/LayoutSider.js +13 -13
  132. package/es/layout/src/styles/layout-footer.cssr.js +11 -11
  133. package/es/layout/src/styles/layout-header.cssr.js +11 -11
  134. package/es/layout/src/styles/layout-sider.cssr.js +32 -32
  135. package/es/layout/src/styles/layout.cssr.js +8 -8
  136. package/es/list/src/List.d.ts +10 -10
  137. package/es/list/src/List.js +10 -10
  138. package/es/list/src/styles/index.cssr.js +30 -30
  139. package/es/loading-bar/src/LoadingBar.d.ts +3 -3
  140. package/es/loading-bar/src/LoadingBar.js +3 -3
  141. package/es/loading-bar/src/styles/index.cssr.js +7 -7
  142. package/es/locales/common/frFR.js +7 -8
  143. package/es/mention/src/Mention.d.ts +1 -1
  144. package/es/mention/src/Mention.js +1 -1
  145. package/es/mention/src/styles/index.cssr.js +2 -2
  146. package/es/menu/src/Menu.js +43 -40
  147. package/es/menu/src/styles/index.cssr.js +71 -71
  148. package/es/message/src/Message.d.ts +22 -22
  149. package/es/message/src/Message.js +22 -22
  150. package/es/message/src/styles/index.cssr.js +48 -48
  151. package/es/modal/src/BodyWrapper.d.ts +11 -2
  152. package/es/modal/src/BodyWrapper.js +23 -17
  153. package/es/modal/src/Modal.d.ts +14 -8
  154. package/es/modal/src/Modal.js +13 -7
  155. package/es/modal/src/presetProps.d.ts +2 -1
  156. package/es/modal/src/styles/index.cssr.js +8 -8
  157. package/es/notification/src/Notification.d.ts +24 -24
  158. package/es/notification/src/Notification.js +24 -24
  159. package/es/notification/src/styles/index.cssr.js +65 -65
  160. package/es/number-animation/index.d.ts +3 -0
  161. package/es/number-animation/index.js +1 -0
  162. package/es/number-animation/src/NumberAnimation.d.ts +79 -0
  163. package/es/number-animation/src/NumberAnimation.js +81 -0
  164. package/es/number-animation/src/utils.d.ts +8 -0
  165. package/es/number-animation/src/utils.js +17 -0
  166. package/es/page-header/src/PageHeader.d.ts +10 -10
  167. package/es/page-header/src/PageHeader.js +10 -10
  168. package/es/page-header/src/styles/index.cssr.js +23 -23
  169. package/es/pagination/src/Pagination.d.ts +42 -41
  170. package/es/pagination/src/Pagination.js +52 -45
  171. package/es/pagination/src/styles/index.cssr.js +81 -81
  172. package/es/popconfirm/src/Popconfirm.d.ts +2 -2
  173. package/es/popconfirm/src/PopconfirmPanel.d.ts +4 -4
  174. package/es/popconfirm/src/PopconfirmPanel.js +4 -4
  175. package/es/popconfirm/src/styles/index.cssr.js +8 -8
  176. package/es/popover/src/PopoverBody.js +15 -15
  177. package/es/popover/src/styles/index.cssr.js +62 -62
  178. package/es/progress/src/Progress.d.ts +14 -14
  179. package/es/progress/src/Progress.js +14 -14
  180. package/es/progress/src/styles/index.cssr.js +53 -53
  181. package/es/radio/src/Radio.d.ts +15 -15
  182. package/es/radio/src/Radio.js +15 -15
  183. package/es/radio/src/RadioGroup.d.ts +14 -14
  184. package/es/radio/src/RadioGroup.js +14 -14
  185. package/es/radio/src/styles/radio-group.cssr.js +43 -43
  186. package/es/radio/src/styles/radio.cssr.js +36 -36
  187. package/es/rate/src/Rate.d.ts +4 -4
  188. package/es/rate/src/Rate.js +4 -4
  189. package/es/rate/src/styles/index.cssr.js +11 -11
  190. package/es/result/src/Result.d.ts +9 -9
  191. package/es/result/src/Result.js +9 -9
  192. package/es/result/src/styles/index.cssr.js +20 -20
  193. package/es/select/src/Select.d.ts +1 -1
  194. package/es/select/src/Select.js +1 -1
  195. package/es/select/src/styles/index.cssr.js +2 -2
  196. package/es/skeleton/src/Skeleton.d.ts +3 -3
  197. package/es/skeleton/src/Skeleton.js +3 -3
  198. package/es/skeleton/src/styles/index.cssr.js +12 -12
  199. package/es/slider/src/Slider.d.ts +29 -29
  200. package/es/slider/src/Slider.js +29 -29
  201. package/es/slider/src/styles/index.cssr.js +87 -87
  202. package/es/spin/src/Spin.d.ts +5 -5
  203. package/es/spin/src/Spin.js +5 -5
  204. package/es/spin/src/styles/index.cssr.js +15 -15
  205. package/es/statistic/src/Statistic.d.ts +25 -45
  206. package/es/statistic/src/Statistic.js +12 -19
  207. package/es/statistic/src/styles/index.cssr.js +19 -19
  208. package/es/table/src/Table.d.ts +21 -21
  209. package/es/table/src/Table.js +21 -21
  210. package/es/table/src/styles/index.cssr.js +55 -55
  211. package/es/tabs/src/styles/index.cssr.js +4 -1
  212. package/es/tabs/styles/light.js +1 -1
  213. package/es/tag/src/Tag.d.ts +1 -0
  214. package/es/tag/src/Tag.js +1 -0
  215. package/es/thing/src/Thing.js +5 -5
  216. package/es/thing/src/styles/index.cssr.js +11 -11
  217. package/es/time-picker/src/TimePicker.d.ts +2 -2
  218. package/es/transfer/src/Transfer.d.ts +21 -21
  219. package/es/transfer/src/Transfer.js +21 -21
  220. package/es/transfer/src/TransferList.js +5 -7
  221. package/es/transfer/src/styles/index.cssr.js +38 -38
  222. package/es/upload/src/Upload.d.ts +1 -1
  223. package/es/version.d.ts +1 -1
  224. package/es/version.js +1 -1
  225. package/lib/_internal/clear/src/styles/index.cssr.js +10 -10
  226. package/lib/_internal/close/src/styles/index.cssr.js +9 -10
  227. package/lib/_internal/icons/Close.js +1 -1
  228. package/lib/_internal/scrollbar/src/ScrollBar.d.ts +6 -6
  229. package/lib/_internal/scrollbar/src/ScrollBar.js +11 -10
  230. package/lib/_internal/scrollbar/src/styles/index.cssr.js +15 -15
  231. package/lib/_internal/select-menu/src/SelectMenu.d.ts +21 -21
  232. package/lib/_internal/select-menu/src/SelectMenu.js +21 -21
  233. package/lib/_internal/select-menu/src/styles/index.cssr.js +35 -35
  234. package/lib/_internal/select-menu/styles/_common.js +1 -1
  235. package/lib/_internal/selection/src/Selection.d.ts +44 -44
  236. package/lib/_internal/selection/src/Selection.js +44 -44
  237. package/lib/_internal/selection/src/styles/index.cssr.js +78 -78
  238. package/lib/_mixins/common.d.ts +1 -0
  239. package/lib/_mixins/common.js +4 -0
  240. package/lib/_mixins/index.d.ts +1 -0
  241. package/lib/_mixins/index.js +3 -1
  242. package/lib/_mixins/use-css-vars-class.d.ts +2 -0
  243. package/lib/_mixins/use-css-vars-class.js +29 -0
  244. package/lib/_mixins/use-rtl.js +2 -0
  245. package/lib/_mixins/use-style.js +3 -0
  246. package/lib/_mixins/use-theme.js +3 -0
  247. package/lib/_utils/composable/use-houdini.js +2 -2
  248. package/lib/alert/src/Alert.d.ts +2 -2
  249. package/lib/avatar/index.d.ts +2 -0
  250. package/lib/avatar/index.js +3 -1
  251. package/lib/avatar/src/Avatar.d.ts +67 -28
  252. package/lib/avatar/src/Avatar.js +41 -12
  253. package/lib/avatar/src/AvatarGroup.d.ts +52 -0
  254. package/lib/avatar/src/AvatarGroup.js +67 -0
  255. package/lib/avatar/src/interface.d.ts +2 -0
  256. package/lib/avatar/src/interface.js +2 -0
  257. package/lib/avatar/src/styles/avatar-group.cssr.d.ts +2 -0
  258. package/lib/avatar/src/styles/avatar-group.cssr.js +21 -0
  259. package/lib/avatar/src/styles/index.cssr.js +7 -2
  260. package/lib/avatar/styles/light.d.ts +3 -0
  261. package/lib/avatar/styles/light.js +6 -2
  262. package/lib/breadcrumb/src/Breadcrumb.d.ts +8 -8
  263. package/lib/breadcrumb/src/Breadcrumb.js +8 -8
  264. package/lib/breadcrumb/src/styles/index.cssr.js +23 -23
  265. package/lib/calendar/src/Calendar.d.ts +21 -21
  266. package/lib/calendar/src/Calendar.js +21 -21
  267. package/lib/calendar/src/styles/index.cssr.js +57 -57
  268. package/lib/card/src/Card.d.ts +28 -23
  269. package/lib/card/src/Card.js +24 -23
  270. package/lib/card/src/styles/index.cssr.js +71 -69
  271. package/lib/carousel/src/Carousel.d.ts +5 -5
  272. package/lib/carousel/src/Carousel.js +5 -5
  273. package/lib/carousel/src/styles/index.cssr.js +10 -10
  274. package/lib/cascader/src/Cascader.d.ts +25 -17
  275. package/lib/cascader/src/Cascader.js +30 -20
  276. package/lib/cascader/src/CascaderMenu.js +1 -1
  277. package/lib/cascader/src/styles/index.cssr.js +44 -44
  278. package/lib/cascader/styles/light.js +1 -1
  279. package/lib/checkbox/src/Checkbox.d.ts +23 -23
  280. package/lib/checkbox/src/Checkbox.js +23 -23
  281. package/lib/checkbox/src/styles/index.cssr.js +58 -58
  282. package/lib/code/src/Code.d.ts +14 -14
  283. package/lib/code/src/Code.js +26 -17
  284. package/lib/code/src/styles/index.cssr.js +28 -28
  285. package/lib/collapse/src/Collapse.d.ts +8 -8
  286. package/lib/collapse/src/Collapse.js +8 -8
  287. package/lib/collapse/src/styles/index.cssr.js +24 -24
  288. package/lib/collapse-transition/src/CollapseTransition.d.ts +1 -1
  289. package/lib/collapse-transition/src/CollapseTransition.js +1 -1
  290. package/lib/color-picker/src/ColorPicker.d.ts +10 -10
  291. package/lib/color-picker/src/ColorPicker.js +10 -10
  292. package/lib/color-picker/src/styles/index.cssr.js +28 -28
  293. package/lib/components.d.ts +2 -0
  294. package/lib/components.js +2 -0
  295. package/lib/countdown/index.d.ts +2 -0
  296. package/lib/countdown/index.js +8 -0
  297. package/lib/countdown/src/Countdown.d.ts +72 -0
  298. package/lib/countdown/src/Countdown.js +128 -0
  299. package/lib/countdown/src/utils.d.ts +0 -0
  300. package/lib/countdown/src/utils.js +1 -0
  301. package/lib/data-table/src/DataTable.d.ts +39 -39
  302. package/lib/data-table/src/DataTable.js +42 -42
  303. package/lib/data-table/src/TableParts/Body.js +6 -4
  304. package/lib/data-table/src/styles/index.cssr.js +130 -130
  305. package/lib/date-picker/src/DatePicker.d.ts +45 -45
  306. package/lib/date-picker/src/DatePicker.js +45 -45
  307. package/lib/date-picker/src/styles/index.cssr.js +115 -115
  308. package/lib/descriptions/src/Descriptions.d.ts +18 -18
  309. package/lib/descriptions/src/Descriptions.js +19 -20
  310. package/lib/descriptions/src/styles/index.cssr.js +61 -61
  311. package/lib/dialog/src/Dialog.d.ts +3 -3
  312. package/lib/dialog/src/Dialog.js +3 -3
  313. package/lib/dialog/src/DialogEnvironment.d.ts +2 -2
  314. package/lib/dialog/src/DialogProvider.d.ts +1 -1
  315. package/lib/drawer/src/Drawer.d.ts +19 -19
  316. package/lib/drawer/src/Drawer.js +19 -19
  317. package/lib/drawer/src/styles/index.cssr.js +41 -40
  318. package/lib/dropdown/src/Dropdown.js +34 -32
  319. package/lib/dropdown/src/styles/index.cssr.js +59 -59
  320. package/lib/empty/src/Empty.d.ts +19 -15
  321. package/lib/empty/src/Empty.js +12 -12
  322. package/lib/empty/src/styles/index.cssr.js +19 -18
  323. package/lib/form/src/FormItem.d.ts +15 -15
  324. package/lib/form/src/FormItem.js +15 -15
  325. package/lib/form/src/FormItemCol.d.ts +6 -0
  326. package/lib/form/src/FormItemCol.js +1 -0
  327. package/lib/form/src/FormItemGridItem.d.ts +6 -0
  328. package/lib/form/src/FormItemGridItem.js +1 -0
  329. package/lib/form/src/FormItemRow.d.ts +6 -0
  330. package/lib/form/src/FormItemRow.js +1 -0
  331. package/lib/form/src/styles/form-item.cssr.js +37 -37
  332. package/lib/gradient-text/src/GradientText.d.ts +5 -5
  333. package/lib/gradient-text/src/GradientText.js +5 -5
  334. package/lib/gradient-text/src/styles/index.cssr.js +9 -9
  335. package/lib/icon/src/Icon.d.ts +6 -6
  336. package/lib/icon/src/Icon.js +4 -4
  337. package/lib/icon/src/styles/index.cssr.js +7 -7
  338. package/lib/image/src/ImagePreview.d.ts +2 -2
  339. package/lib/image/src/ImagePreview.js +12 -11
  340. package/lib/image/src/styles/index.cssr.js +5 -5
  341. package/lib/input/src/Input.d.ts +52 -47
  342. package/lib/input/src/Input.js +54 -49
  343. package/lib/input/src/InputGroupLabel.d.ts +8 -8
  344. package/lib/input/src/InputGroupLabel.js +8 -8
  345. package/lib/input/src/styles/input-group-label.cssr.js +18 -18
  346. package/lib/input/src/styles/input.cssr.js +108 -109
  347. package/lib/input-number/src/InputNumber.d.ts +11 -0
  348. package/lib/input-number/src/InputNumber.js +5 -2
  349. package/lib/input-number/src/utils.js +2 -1
  350. package/lib/layout/src/Layout.d.ts +6 -6
  351. package/lib/layout/src/Layout.js +3 -3
  352. package/lib/layout/src/LayoutContent.d.ts +3 -3
  353. package/lib/layout/src/LayoutFooter.js +7 -7
  354. package/lib/layout/src/LayoutHeader.js +7 -7
  355. package/lib/layout/src/LayoutSider.js +13 -13
  356. package/lib/layout/src/styles/layout-footer.cssr.js +11 -11
  357. package/lib/layout/src/styles/layout-header.cssr.js +11 -11
  358. package/lib/layout/src/styles/layout-sider.cssr.js +32 -32
  359. package/lib/layout/src/styles/layout.cssr.js +8 -8
  360. package/lib/list/src/List.d.ts +10 -10
  361. package/lib/list/src/List.js +10 -10
  362. package/lib/list/src/styles/index.cssr.js +30 -30
  363. package/lib/loading-bar/src/LoadingBar.d.ts +3 -3
  364. package/lib/loading-bar/src/LoadingBar.js +3 -3
  365. package/lib/loading-bar/src/styles/index.cssr.js +7 -7
  366. package/lib/locales/common/frFR.js +7 -8
  367. package/lib/mention/src/Mention.d.ts +1 -1
  368. package/lib/mention/src/Mention.js +1 -1
  369. package/lib/mention/src/styles/index.cssr.js +2 -2
  370. package/lib/menu/src/Menu.js +43 -40
  371. package/lib/menu/src/styles/index.cssr.js +71 -71
  372. package/lib/message/src/Message.d.ts +22 -22
  373. package/lib/message/src/Message.js +22 -22
  374. package/lib/message/src/styles/index.cssr.js +48 -48
  375. package/lib/modal/src/BodyWrapper.d.ts +11 -2
  376. package/lib/modal/src/BodyWrapper.js +23 -17
  377. package/lib/modal/src/Modal.d.ts +14 -8
  378. package/lib/modal/src/Modal.js +13 -7
  379. package/lib/modal/src/presetProps.d.ts +2 -1
  380. package/lib/modal/src/styles/index.cssr.js +8 -8
  381. package/lib/notification/src/Notification.d.ts +24 -24
  382. package/lib/notification/src/Notification.js +24 -24
  383. package/lib/notification/src/styles/index.cssr.js +65 -65
  384. package/lib/number-animation/index.d.ts +3 -0
  385. package/lib/number-animation/index.js +8 -0
  386. package/lib/number-animation/src/NumberAnimation.d.ts +79 -0
  387. package/lib/number-animation/src/NumberAnimation.js +83 -0
  388. package/lib/number-animation/src/utils.d.ts +8 -0
  389. package/lib/number-animation/src/utils.js +21 -0
  390. package/lib/page-header/src/PageHeader.d.ts +10 -10
  391. package/lib/page-header/src/PageHeader.js +10 -10
  392. package/lib/page-header/src/styles/index.cssr.js +23 -23
  393. package/lib/pagination/src/Pagination.d.ts +42 -41
  394. package/lib/pagination/src/Pagination.js +52 -45
  395. package/lib/pagination/src/styles/index.cssr.js +81 -81
  396. package/lib/popconfirm/src/Popconfirm.d.ts +2 -2
  397. package/lib/popconfirm/src/PopconfirmPanel.d.ts +4 -4
  398. package/lib/popconfirm/src/PopconfirmPanel.js +4 -4
  399. package/lib/popconfirm/src/styles/index.cssr.js +8 -8
  400. package/lib/popover/src/PopoverBody.js +15 -15
  401. package/lib/popover/src/styles/index.cssr.js +62 -62
  402. package/lib/progress/src/Progress.d.ts +14 -14
  403. package/lib/progress/src/Progress.js +14 -14
  404. package/lib/progress/src/styles/index.cssr.js +53 -53
  405. package/lib/radio/src/Radio.d.ts +15 -15
  406. package/lib/radio/src/Radio.js +15 -15
  407. package/lib/radio/src/RadioGroup.d.ts +14 -14
  408. package/lib/radio/src/RadioGroup.js +14 -14
  409. package/lib/radio/src/styles/radio-group.cssr.js +43 -43
  410. package/lib/radio/src/styles/radio.cssr.js +36 -36
  411. package/lib/rate/src/Rate.d.ts +4 -4
  412. package/lib/rate/src/Rate.js +4 -4
  413. package/lib/rate/src/styles/index.cssr.js +11 -11
  414. package/lib/result/src/Result.d.ts +9 -9
  415. package/lib/result/src/Result.js +9 -9
  416. package/lib/result/src/styles/index.cssr.js +20 -20
  417. package/lib/select/src/Select.d.ts +1 -1
  418. package/lib/select/src/Select.js +1 -1
  419. package/lib/select/src/styles/index.cssr.js +2 -2
  420. package/lib/skeleton/src/Skeleton.d.ts +3 -3
  421. package/lib/skeleton/src/Skeleton.js +3 -3
  422. package/lib/skeleton/src/styles/index.cssr.js +12 -12
  423. package/lib/slider/src/Slider.d.ts +29 -29
  424. package/lib/slider/src/Slider.js +29 -29
  425. package/lib/slider/src/styles/index.cssr.js +87 -87
  426. package/lib/spin/src/Spin.d.ts +5 -5
  427. package/lib/spin/src/Spin.js +5 -5
  428. package/lib/spin/src/styles/index.cssr.js +15 -15
  429. package/lib/statistic/src/Statistic.d.ts +25 -45
  430. package/lib/statistic/src/Statistic.js +12 -19
  431. package/lib/statistic/src/styles/index.cssr.js +19 -19
  432. package/lib/table/src/Table.d.ts +21 -21
  433. package/lib/table/src/Table.js +21 -21
  434. package/lib/table/src/styles/index.cssr.js +55 -55
  435. package/lib/tabs/src/styles/index.cssr.js +4 -1
  436. package/lib/tabs/styles/light.js +1 -1
  437. package/lib/tag/src/Tag.d.ts +1 -0
  438. package/lib/tag/src/Tag.js +1 -0
  439. package/lib/thing/src/Thing.js +5 -5
  440. package/lib/thing/src/styles/index.cssr.js +11 -11
  441. package/lib/time-picker/src/TimePicker.d.ts +2 -2
  442. package/lib/transfer/src/Transfer.d.ts +21 -21
  443. package/lib/transfer/src/Transfer.js +21 -21
  444. package/lib/transfer/src/TransferList.js +5 -7
  445. package/lib/transfer/src/styles/index.cssr.js +38 -38
  446. package/lib/upload/src/Upload.d.ts +1 -1
  447. package/lib/version.d.ts +1 -1
  448. package/lib/version.js +1 -1
  449. package/package.json +11 -10
  450. package/web-types.json +230 -7
@@ -0,0 +1,126 @@
1
+ import { defineComponent, onMounted, onBeforeUnmount, watchEffect, reactive } from 'vue';
2
+ const countdownProps = {
3
+ label: String,
4
+ duration: {
5
+ type: Number,
6
+ default: 0
7
+ },
8
+ active: {
9
+ type: Boolean,
10
+ default: true
11
+ },
12
+ precision: {
13
+ type: Number,
14
+ default: 0
15
+ },
16
+ render: Function,
17
+ onFinish: Function
18
+ };
19
+ export default defineComponent({
20
+ name: 'Countdown',
21
+ props: countdownProps,
22
+ setup(props) {
23
+ let timerId = null;
24
+ let rafId = null;
25
+ let elapsed = 0;
26
+ let finished = false;
27
+ const timeInfo = reactive({
28
+ hours: 0,
29
+ minutes: 0,
30
+ seconds: 0,
31
+ milliseconds: 0
32
+ });
33
+ deriveDisplayValue(props.duration);
34
+ let pnow = -1;
35
+ function getDistance(time) {
36
+ return props.duration - elapsed + pnow - time;
37
+ }
38
+ function deriveDisplayValue(distance) {
39
+ const hours = Math.floor(distance / 3600000);
40
+ const minutes = Math.floor((distance % 3600000) / 60000);
41
+ const seconds = Math.floor((distance % 60000) / 1000);
42
+ const milliseconds = Math.floor(distance % 1000);
43
+ timeInfo.hours = hours;
44
+ timeInfo.minutes = minutes;
45
+ timeInfo.seconds = seconds;
46
+ timeInfo.milliseconds = milliseconds;
47
+ }
48
+ function getDisplayValue(info) {
49
+ const { hours, minutes, seconds, milliseconds } = info;
50
+ const { precision } = props;
51
+ switch (precision) {
52
+ case 0:
53
+ return `${String(hours).padStart(2, '0')}:${String(minutes).padStart(2, '0')}:${String(seconds).padStart(2, '0')}`;
54
+ default:
55
+ return `${String(hours).padStart(2, '0')}:${String(minutes).padStart(2, '0')}:${String(seconds).padStart(2, '0')}.${String(Math.floor(milliseconds / (precision === 1 ? 100 : precision === 2 ? 10 : 1))).padStart(precision, '0')}`;
56
+ }
57
+ }
58
+ const frame = () => {
59
+ var _a;
60
+ const { precision } = props;
61
+ const distance = getDistance(performance.now());
62
+ if (distance <= 0) {
63
+ deriveDisplayValue(0);
64
+ stopTimer();
65
+ if (!finished) {
66
+ (_a = props.onFinish) === null || _a === void 0 ? void 0 : _a.call(props);
67
+ finished = true;
68
+ }
69
+ return;
70
+ }
71
+ let leftTime;
72
+ switch (precision) {
73
+ case 3:
74
+ case 2:
75
+ leftTime = distance % 34; // about 30 fps
76
+ break;
77
+ case 1:
78
+ leftTime = distance % 100;
79
+ break;
80
+ default:
81
+ leftTime = distance % 1000;
82
+ }
83
+ deriveDisplayValue(distance);
84
+ timerId = window.setTimeout(() => {
85
+ frame();
86
+ }, leftTime);
87
+ };
88
+ const stopTimer = () => {
89
+ if (timerId !== null) {
90
+ window.clearTimeout(timerId);
91
+ timerId = null;
92
+ }
93
+ if (rafId !== null) {
94
+ window.cancelAnimationFrame(rafId);
95
+ rafId = null;
96
+ }
97
+ };
98
+ onMounted(() => {
99
+ watchEffect(() => {
100
+ if (props.active) {
101
+ pnow = performance.now();
102
+ frame();
103
+ }
104
+ else {
105
+ const now = performance.now();
106
+ if (pnow !== -1) {
107
+ elapsed += now - pnow;
108
+ }
109
+ stopTimer();
110
+ }
111
+ });
112
+ });
113
+ onBeforeUnmount(() => {
114
+ stopTimer();
115
+ });
116
+ return () => {
117
+ const { render } = props;
118
+ if (render) {
119
+ return render(timeInfo);
120
+ }
121
+ else {
122
+ return getDisplayValue(timeInfo);
123
+ }
124
+ };
125
+ }
126
+ });
File without changes
@@ -0,0 +1 @@
1
+ "use strict";
@@ -3817,45 +3817,45 @@ declare const _default: import("vue").DefineComponent<{
3817
3817
  }>>>;
3818
3818
  }, {
3819
3819
  cssVars: import("vue").ComputedRef<{
3820
- '--font-size': string;
3821
- '--th-padding': string;
3822
- '--td-padding': string;
3823
- '--bezier': string;
3824
- '--border-radius': string;
3825
- '--line-height': string;
3826
- '--border-color': string;
3827
- '--border-color-modal': string;
3828
- '--border-color-popover': string;
3829
- '--th-color': string;
3830
- '--th-color-hover': string;
3831
- '--th-color-modal': string;
3832
- '--th-color-hover-modal': string;
3833
- '--th-color-popover': string;
3834
- '--th-color-hover-popover': string;
3835
- '--td-color': string;
3836
- '--td-color-hover': string;
3837
- '--td-color-modal': string;
3838
- '--td-color-hover-modal': string;
3839
- '--td-color-popover': string;
3840
- '--td-color-hover-popover': string;
3841
- '--th-text-color': string;
3842
- '--td-text-color': string;
3843
- '--th-font-weight': string;
3844
- '--th-button-color-hover': string;
3845
- '--th-icon-color': string;
3846
- '--th-icon-color-active': string;
3847
- '--filter-size': string;
3848
- '--pagination-margin': string;
3849
- '--empty-padding': string;
3850
- '--box-shadow-before': string;
3851
- '--box-shadow-after': string;
3852
- '--sorter-size': string;
3853
- '--loading-size': string;
3854
- '--loading-color': string;
3855
- '--opacity-loading': string;
3856
- '--td-color-striped': string;
3857
- '--td-color-striped-modal': string;
3858
- '--td-color-striped-popover': string;
3820
+ '--n-font-size': string;
3821
+ '--n-th-padding': string;
3822
+ '--n-td-padding': string;
3823
+ '--n-bezier': string;
3824
+ '--n-border-radius': string;
3825
+ '--n-line-height': string;
3826
+ '--n-border-color': string;
3827
+ '--n-border-color-modal': string;
3828
+ '--n-border-color-popover': string;
3829
+ '--n-th-color': string;
3830
+ '--n-th-color-hover': string;
3831
+ '--n-th-color-modal': string;
3832
+ '--n-th-color-hover-modal': string;
3833
+ '--n-th-color-popover': string;
3834
+ '--n-th-color-hover-popover': string;
3835
+ '--n-td-color': string;
3836
+ '--n-td-color-hover': string;
3837
+ '--n-td-color-modal': string;
3838
+ '--n-td-color-hover-modal': string;
3839
+ '--n-n-td-color-popover': string;
3840
+ '--n-td-color-hover-popover': string;
3841
+ '--n-th-text-color': string;
3842
+ '--n-td-text-color': string;
3843
+ '--n-th-font-weight': string;
3844
+ '--n-th-button-color-hover': string;
3845
+ '--n-th-icon-color': string;
3846
+ '--n-th-icon-color-active': string;
3847
+ '--n-filter-size': string;
3848
+ '--n-pagination-margin': string;
3849
+ '--n-empty-padding': string;
3850
+ '--n-box-shadow-before': string;
3851
+ '--n-box-shadow-after': string;
3852
+ '--n-sorter-size': string;
3853
+ '--n-loading-size': string;
3854
+ '--n-loading-color': string;
3855
+ '--n-opacity-loading': string;
3856
+ '--n-td-color-striped': string;
3857
+ '--n-td-color-striped-modal': string;
3858
+ '--n-td-color-striped-popover': string;
3859
3859
  }>;
3860
3860
  filter: (filters: import("./interface").FilterState | null) => void;
3861
3861
  filters: (filters: import("./interface").FilterState | null) => void;
@@ -200,9 +200,9 @@ export default defineComponent({
200
200
  const { self: { actionDividerColor, actionPadding, actionButtonMargin } } = themeRef.value;
201
201
  // eslint-disable-next-line @typescript-eslint/consistent-type-assertions
202
202
  return {
203
- '--action-padding': actionPadding,
204
- '--action-button-margin': actionButtonMargin,
205
- '--action-divider-color': actionDividerColor
203
+ '--n-action-padding': actionPadding,
204
+ '--n-action-button-margin': actionButtonMargin,
205
+ '--n-action-divider-color': actionDividerColor
206
206
  };
207
207
  }),
208
208
  mergedTableLayoutRef,
@@ -235,45 +235,45 @@ export default defineComponent({
235
235
  const { size } = props;
236
236
  const { common: { cubicBezierEaseInOut }, self: { borderColor, tdColorHover, thColor, thColorHover, tdColor, tdTextColor, thTextColor, thFontWeight, thButtonColorHover, thIconColor, thIconColorActive, filterSize, borderRadius, lineHeight, tdColorModal, thColorModal, borderColorModal, thColorHoverModal, tdColorHoverModal, borderColorPopover, thColorPopover, tdColorPopover, tdColorHoverPopover, thColorHoverPopover, paginationMargin, emptyPadding, boxShadowAfter, boxShadowBefore, sorterSize, loadingColor, loadingSize, opacityLoading, tdColorStriped, tdColorStripedModal, tdColorStripedPopover, [createKey('fontSize', size)]: fontSize, [createKey('thPadding', size)]: thPadding, [createKey('tdPadding', size)]: tdPadding } } = themeRef.value;
237
237
  return {
238
- '--font-size': fontSize,
239
- '--th-padding': thPadding,
240
- '--td-padding': tdPadding,
241
- '--bezier': cubicBezierEaseInOut,
242
- '--border-radius': borderRadius,
243
- '--line-height': lineHeight,
244
- '--border-color': borderColor,
245
- '--border-color-modal': borderColorModal,
246
- '--border-color-popover': borderColorPopover,
247
- '--th-color': thColor,
248
- '--th-color-hover': thColorHover,
249
- '--th-color-modal': thColorModal,
250
- '--th-color-hover-modal': thColorHoverModal,
251
- '--th-color-popover': thColorPopover,
252
- '--th-color-hover-popover': thColorHoverPopover,
253
- '--td-color': tdColor,
254
- '--td-color-hover': tdColorHover,
255
- '--td-color-modal': tdColorModal,
256
- '--td-color-hover-modal': tdColorHoverModal,
257
- '--td-color-popover': tdColorPopover,
258
- '--td-color-hover-popover': tdColorHoverPopover,
259
- '--th-text-color': thTextColor,
260
- '--td-text-color': tdTextColor,
261
- '--th-font-weight': thFontWeight,
262
- '--th-button-color-hover': thButtonColorHover,
263
- '--th-icon-color': thIconColor,
264
- '--th-icon-color-active': thIconColorActive,
265
- '--filter-size': filterSize,
266
- '--pagination-margin': paginationMargin,
267
- '--empty-padding': emptyPadding,
268
- '--box-shadow-before': boxShadowBefore,
269
- '--box-shadow-after': boxShadowAfter,
270
- '--sorter-size': sorterSize,
271
- '--loading-size': loadingSize,
272
- '--loading-color': loadingColor,
273
- '--opacity-loading': opacityLoading,
274
- '--td-color-striped': tdColorStriped,
275
- '--td-color-striped-modal': tdColorStripedModal,
276
- '--td-color-striped-popover': tdColorStripedPopover
238
+ '--n-font-size': fontSize,
239
+ '--n-th-padding': thPadding,
240
+ '--n-td-padding': tdPadding,
241
+ '--n-bezier': cubicBezierEaseInOut,
242
+ '--n-border-radius': borderRadius,
243
+ '--n-line-height': lineHeight,
244
+ '--n-border-color': borderColor,
245
+ '--n-border-color-modal': borderColorModal,
246
+ '--n-border-color-popover': borderColorPopover,
247
+ '--n-th-color': thColor,
248
+ '--n-th-color-hover': thColorHover,
249
+ '--n-th-color-modal': thColorModal,
250
+ '--n-th-color-hover-modal': thColorHoverModal,
251
+ '--n-th-color-popover': thColorPopover,
252
+ '--n-th-color-hover-popover': thColorHoverPopover,
253
+ '--n-td-color': tdColor,
254
+ '--n-td-color-hover': tdColorHover,
255
+ '--n-td-color-modal': tdColorModal,
256
+ '--n-td-color-hover-modal': tdColorHoverModal,
257
+ '--n-n-td-color-popover': tdColorPopover,
258
+ '--n-td-color-hover-popover': tdColorHoverPopover,
259
+ '--n-th-text-color': thTextColor,
260
+ '--n-td-text-color': tdTextColor,
261
+ '--n-th-font-weight': thFontWeight,
262
+ '--n-th-button-color-hover': thButtonColorHover,
263
+ '--n-th-icon-color': thIconColor,
264
+ '--n-th-icon-color-active': thIconColorActive,
265
+ '--n-filter-size': filterSize,
266
+ '--n-pagination-margin': paginationMargin,
267
+ '--n-empty-padding': emptyPadding,
268
+ '--n-box-shadow-before': boxShadowBefore,
269
+ '--n-box-shadow-after': boxShadowAfter,
270
+ '--n-sorter-size': sorterSize,
271
+ '--n-loading-size': loadingSize,
272
+ '--n-loading-color': loadingColor,
273
+ '--n-opacity-loading': opacityLoading,
274
+ '--n-td-color-striped': tdColorStriped,
275
+ '--n-td-color-striped-modal': tdColorStripedModal,
276
+ '--n-td-color-striped-popover': tdColorStripedPopover
277
277
  };
278
278
  }) });
279
279
  },
@@ -2,6 +2,8 @@
2
2
  import { h, ref, defineComponent, inject, watchEffect, onUnmounted, computed, renderSlot, Fragment } from 'vue';
3
3
  import { pxfy, repeat } from 'seemly';
4
4
  import { VirtualList, VResizeObserver } from 'vueuc';
5
+ import { useMemo } from 'vooks';
6
+ import { cssrAnchorMetaName } from '../../../_mixins/common';
5
7
  import { c } from '../../../_utils/cssr';
6
8
  import { NScrollbar } from '../../../_internal';
7
9
  import { formatLength } from '../../../_utils';
@@ -12,7 +14,6 @@ import Cell from './Cell';
12
14
  import ExpandTrigger from './ExpandTrigger';
13
15
  import RenderSafeCheckbox from './BodyCheckbox';
14
16
  import TableHeader from './Header';
15
- import { useMemo } from 'vooks';
16
17
  function flatten(rowInfos, expandedRowKeys) {
17
18
  const fRows = [];
18
19
  function traverse(rs) {
@@ -190,12 +191,12 @@ export default defineComponent({
190
191
  const createActiveLeftFixedStyle = (leftActiveFixedColKey) => {
191
192
  if (leftActiveFixedColKey === null)
192
193
  return null;
193
- return c(`[data-n-id="${cProps.componentId}"] [data-col-key="${leftActiveFixedColKey}"]::after`, { boxShadow: 'var(--box-shadow-after)' });
194
+ return c(`[data-n-id="${cProps.componentId}"] [data-col-key="${leftActiveFixedColKey}"]::after`, { boxShadow: 'var(--n-box-shadow-after)' });
194
195
  };
195
196
  const createActiveRightFixedStyle = (rightActiveFixedColKey) => {
196
197
  if (rightActiveFixedColKey === null)
197
198
  return null;
198
- return c(`[data-n-id="${cProps.componentId}"] [data-col-key="${rightActiveFixedColKey}"]::before`, { boxShadow: 'var(--box-shadow-before)' });
199
+ return c(`[data-n-id="${cProps.componentId}"] [data-col-key="${rightActiveFixedColKey}"]::before`, { boxShadow: 'var(--n-box-shadow-before)' });
199
200
  };
200
201
  return c([
201
202
  createActiveLeftFixedStyle(cProps.leftActiveFixedColKey),
@@ -226,7 +227,8 @@ export default defineComponent({
226
227
  style.mount({
227
228
  id: `n-${componentId}`,
228
229
  force: true,
229
- props: cProps
230
+ props: cProps,
231
+ anchorMetaName: cssrAnchorMetaName
230
232
  });
231
233
  fixedStyleMounted = true;
232
234
  });