naive-ui 2.24.5 → 2.25.1

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 (659) hide show
  1. package/es/_internal/clear/src/Clear.js +3 -2
  2. package/es/_internal/close/src/Close.js +1 -1
  3. package/es/_internal/icon/src/Icon.js +1 -1
  4. package/es/_internal/icons/ArrowUp.d.ts +2 -0
  5. package/es/_internal/icons/ArrowUp.js +9 -0
  6. package/es/_internal/icons/index.d.ts +1 -0
  7. package/es/_internal/icons/index.js +1 -0
  8. package/es/_internal/loading/src/Loading.js +1 -1
  9. package/es/_internal/menu-mask/src/MenuMask.js +1 -1
  10. package/es/_internal/scrollbar/src/ScrollBar.js +1 -1
  11. package/es/_internal/select-menu/src/SelectMenu.d.ts +5 -5
  12. package/es/_internal/select-menu/src/SelectMenu.js +32 -16
  13. package/es/_internal/selection/src/Selection.d.ts +13 -5
  14. package/es/_internal/selection/src/Selection.js +24 -15
  15. package/es/_internal/selection/src/interface.d.ts +2 -2
  16. package/es/_internal/selection/src/styles/index.cssr.js +16 -31
  17. package/es/_internal/slot-machine/src/SlotMachine.js +1 -1
  18. package/es/_internal/wave/src/Wave.js +1 -1
  19. package/es/_mixins/use-config.js +1 -1
  20. package/es/_mixins/use-css-vars-class.d.ts +4 -2
  21. package/es/_mixins/use-css-vars-class.js +26 -11
  22. package/es/_mixins/use-form-item.d.ts +4 -0
  23. package/es/_mixins/use-form-item.js +7 -0
  24. package/es/_mixins/use-hljs.js +1 -1
  25. package/es/_mixins/use-locale.js +1 -1
  26. package/es/_mixins/use-style.js +1 -1
  27. package/es/_mixins/use-theme.d.ts +1 -1
  28. package/es/_mixins/use-theme.js +2 -2
  29. package/es/_utils/cssr/index.d.ts +1 -2
  30. package/es/_utils/cssr/index.js +1 -14
  31. package/es/_utils/index.d.ts +1 -1
  32. package/es/_utils/index.js +1 -1
  33. package/es/_utils/vue/index.d.ts +1 -1
  34. package/es/_utils/vue/index.js +1 -1
  35. package/es/_utils/vue/resolve-slot.d.ts +8 -2
  36. package/es/_utils/vue/resolve-slot.js +18 -1
  37. package/es/affix/src/Affix.js +1 -1
  38. package/es/alert/src/Alert.d.ts +4 -4
  39. package/es/alert/src/Alert.js +1 -1
  40. package/es/anchor/src/AnchorAdapter.js +1 -1
  41. package/es/auto-complete/src/AutoComplete.d.ts +17 -2
  42. package/es/auto-complete/src/AutoComplete.js +9 -5
  43. package/es/avatar/src/Avatar.js +2 -2
  44. package/es/avatar/src/AvatarGroup.d.ts +0 -1
  45. package/es/avatar/src/AvatarGroup.js +2 -3
  46. package/es/avatar/src/context.d.ts +2 -0
  47. package/es/avatar/src/context.js +2 -0
  48. package/es/back-top/src/BackTop.js +1 -1
  49. package/es/badge/src/Badge.d.ts +4 -4
  50. package/es/badge/src/Badge.js +1 -1
  51. package/es/breadcrumb/src/Breadcrumb.js +1 -1
  52. package/es/button/src/Button.d.ts +4 -3
  53. package/es/button/src/Button.js +265 -229
  54. package/es/button/src/ButtonGroup.js +1 -1
  55. package/es/button/src/styles/button.cssr.js +1 -0
  56. package/es/calendar/src/Calendar.js +1 -1
  57. package/es/card/src/Card.d.ts +5 -1
  58. package/es/card/src/Card.js +3 -2
  59. package/es/carousel/src/Carousel.js +4 -1
  60. package/es/carousel/src/CarouselArrow.js +6 -9
  61. package/es/carousel/src/styles/index.cssr.js +59 -48
  62. package/es/carousel/styles/light.js +2 -2
  63. package/es/cascader/src/Cascader.d.ts +6 -4
  64. package/es/cascader/src/Cascader.js +6 -6
  65. package/es/checkbox/src/Checkbox.js +1 -1
  66. package/es/code/src/Code.js +1 -1
  67. package/es/collapse/src/Collapse.js +1 -1
  68. package/es/collapse-transition/src/CollapseTransition.js +1 -1
  69. package/es/color-picker/src/ColorInputUnit.js +1 -1
  70. package/es/color-picker/src/ColorPicker.d.ts +24 -17
  71. package/es/color-picker/src/ColorPicker.js +7 -4
  72. package/es/color-picker/src/ColorPickerTrigger.js +1 -1
  73. package/es/color-picker/src/context.d.ts +9 -0
  74. package/es/color-picker/src/context.js +2 -0
  75. package/es/color-picker/src/styles/index.cssr.js +1 -0
  76. package/es/components.d.ts +2 -1
  77. package/es/components.js +2 -1
  78. package/es/composables/use-theme-vars.js +1 -1
  79. package/es/config-provider/src/ConfigProvider.d.ts +15 -3
  80. package/es/config-provider/src/ConfigProvider.js +29 -3
  81. package/es/config-provider/src/context.d.ts +2 -0
  82. package/es/config-provider/src/context.js +2 -0
  83. package/es/config-provider/src/interface.d.ts +2 -1
  84. package/es/config-provider/src/internal-interface.d.ts +4 -0
  85. package/es/data-table/src/DataTable.d.ts +1 -1
  86. package/es/data-table/src/DataTable.js +1 -1
  87. package/es/data-table/src/interface.d.ts +2 -2
  88. package/es/data-table/src/use-check.d.ts +2 -2
  89. package/es/data-table/src/use-group-header.d.ts +1 -1
  90. package/es/data-table/src/use-scroll.d.ts +1 -1
  91. package/es/data-table/src/use-scroll.js +3 -3
  92. package/es/data-table/src/use-sorter.d.ts +1 -1
  93. package/es/data-table/src/use-table-data.d.ts +1 -1
  94. package/es/data-table/src/utils.d.ts +2 -1
  95. package/es/data-table/src/utils.js +13 -3
  96. package/es/date-picker/src/DatePicker.d.ts +2 -1
  97. package/es/date-picker/src/DatePicker.js +6 -6
  98. package/es/descriptions/src/Descriptions.d.ts +2 -2
  99. package/es/descriptions/src/Descriptions.js +1 -1
  100. package/es/dialog/index.d.ts +3 -3
  101. package/es/dialog/index.js +2 -2
  102. package/es/dialog/src/Dialog.d.ts +28 -61
  103. package/es/dialog/src/Dialog.js +4 -32
  104. package/es/dialog/src/DialogEnvironment.d.ts +12 -13
  105. package/es/dialog/src/DialogEnvironment.js +3 -2
  106. package/es/dialog/src/DialogProvider.d.ts +4 -6
  107. package/es/dialog/src/DialogProvider.js +5 -6
  108. package/es/dialog/src/context.d.ts +3 -0
  109. package/es/dialog/src/context.js +3 -0
  110. package/es/dialog/src/dialogProps.d.ts +32 -0
  111. package/es/dialog/src/dialogProps.js +29 -0
  112. package/es/dialog/src/use-dialog.js +1 -1
  113. package/es/divider/src/Divider.js +1 -1
  114. package/es/drawer/index.d.ts +1 -0
  115. package/es/drawer/src/Drawer.js +1 -1
  116. package/es/dropdown/src/Dropdown.d.ts +17 -5
  117. package/es/dropdown/src/Dropdown.js +6 -5
  118. package/es/dropdown/src/DropdownGroup.js +1 -0
  119. package/es/dropdown/src/DropdownGroupHeader.js +1 -2
  120. package/es/dropdown/src/DropdownMenu.d.ts +0 -1
  121. package/es/dropdown/src/DropdownMenu.js +4 -4
  122. package/es/dropdown/src/DropdownOption.d.ts +3 -0
  123. package/es/dropdown/src/DropdownOption.js +4 -4
  124. package/es/dropdown/src/context.d.ts +6 -0
  125. package/es/dropdown/src/context.js +4 -0
  126. package/es/dropdown/src/interface.d.ts +1 -1
  127. package/es/dynamic-input/src/DynamicInput.d.ts +16 -33
  128. package/es/dynamic-input/src/DynamicInput.js +73 -36
  129. package/es/dynamic-tags/src/DynamicTags.d.ts +11 -20
  130. package/es/dynamic-tags/src/DynamicTags.js +14 -16
  131. package/es/element/src/Element.js +1 -1
  132. package/es/ellipsis/src/Ellipsis.js +1 -1
  133. package/es/empty/src/Empty.js +2 -2
  134. package/es/form/src/Form.d.ts +1 -1
  135. package/es/form/src/Form.js +2 -2
  136. package/es/form/src/FormItem.d.ts +5 -5
  137. package/es/form/src/FormItem.js +3 -2
  138. package/es/form/src/FormItemCol.d.ts +4 -4
  139. package/es/form/src/FormItemGridItem.d.ts +5 -5
  140. package/es/form/src/FormItemRow.d.ts +3 -3
  141. package/es/form/src/context.d.ts +3 -0
  142. package/es/form/src/context.js +3 -0
  143. package/es/form/src/interface.d.ts +4 -3
  144. package/es/form/src/interface.js +1 -3
  145. package/es/form/src/styles/form-item.cssr.js +6 -5
  146. package/es/form/src/utils.d.ts +1 -1
  147. package/es/form/src/utils.js +1 -1
  148. package/es/global-style/src/GlobalStyle.js +1 -1
  149. package/es/gradient-text/src/GradientText.d.ts +5 -5
  150. package/es/gradient-text/src/GradientText.js +1 -1
  151. package/es/grid/src/Grid.d.ts +0 -1
  152. package/es/grid/src/Grid.js +2 -3
  153. package/es/grid/src/GridItem.js +1 -1
  154. package/es/grid/src/config.d.ts +3 -0
  155. package/es/grid/src/config.js +3 -0
  156. package/es/icon/index.d.ts +1 -1
  157. package/es/icon/index.js +1 -1
  158. package/es/icon/src/Icon.d.ts +4 -3
  159. package/es/icon/src/Icon.js +6 -6
  160. package/es/icon-wrapper/index.d.ts +1 -0
  161. package/es/icon-wrapper/index.js +1 -0
  162. package/es/icon-wrapper/src/IconWrapper.d.ts +50 -0
  163. package/es/icon-wrapper/src/IconWrapper.js +48 -0
  164. package/es/icon-wrapper/src/styles/index.cssr.d.ts +2 -0
  165. package/es/icon-wrapper/src/styles/index.cssr.js +16 -0
  166. package/es/icon-wrapper/styles/dark.d.ts +3 -0
  167. package/es/icon-wrapper/styles/dark.js +8 -0
  168. package/es/icon-wrapper/styles/index.d.ts +3 -0
  169. package/es/icon-wrapper/styles/index.js +2 -0
  170. package/es/icon-wrapper/styles/light.d.ts +10 -0
  171. package/es/icon-wrapper/styles/light.js +14 -0
  172. package/es/image/src/ImagePreview.js +1 -1
  173. package/es/input/src/Input.d.ts +7 -2
  174. package/es/input/src/Input.js +21 -17
  175. package/es/input/src/InputGroup.js +1 -1
  176. package/es/input/src/InputGroupLabel.js +1 -1
  177. package/es/input/src/WordCount.js +9 -8
  178. package/es/input/src/styles/input.cssr.js +5 -5
  179. package/es/input-number/src/InputNumber.d.ts +3 -2
  180. package/es/input-number/src/InputNumber.js +23 -21
  181. package/es/layout/src/Layout.js +1 -1
  182. package/es/layout/src/LayoutFooter.js +1 -1
  183. package/es/layout/src/LayoutHeader.js +1 -1
  184. package/es/layout/src/LayoutSider.js +1 -1
  185. package/es/legacy-grid/src/Col.js +0 -3
  186. package/es/legacy-grid/src/Row.js +1 -1
  187. package/es/list/src/List.js +1 -1
  188. package/es/loading-bar/src/LoadingBar.js +2 -2
  189. package/es/loading-bar/src/LoadingBarProvider.d.ts +3 -8
  190. package/es/loading-bar/src/LoadingBarProvider.js +1 -3
  191. package/es/loading-bar/src/context.d.ts +7 -0
  192. package/es/loading-bar/src/context.js +3 -0
  193. package/es/loading-bar/src/use-loading-bar.js +1 -1
  194. package/es/locales/common/deDE.js +13 -15
  195. package/es/locales/common/enGB.d.ts +109 -0
  196. package/es/locales/common/enGB.js +109 -0
  197. package/es/locales/common/jaJP.js +12 -14
  198. package/es/locales/date/enGB.d.ts +3 -0
  199. package/es/locales/date/enGB.js +6 -0
  200. package/es/locales/index.d.ts +2 -0
  201. package/es/locales/index.js +2 -0
  202. package/es/log/index.d.ts +1 -1
  203. package/es/log/src/Log.d.ts +17 -12
  204. package/es/log/src/Log.js +10 -17
  205. package/es/log/src/LogLine.js +1 -1
  206. package/es/log/src/context.d.ts +2 -0
  207. package/es/log/src/context.js +2 -0
  208. package/es/log/src/styles/index.cssr.js +2 -3
  209. package/es/mention/src/Mention.d.ts +17 -2
  210. package/es/mention/src/Mention.js +7 -3
  211. package/es/menu/src/Menu.d.ts +2 -4
  212. package/es/menu/src/Menu.js +3 -3
  213. package/es/menu/src/MenuDivider.js +1 -1
  214. package/es/menu/src/MenuOption.d.ts +1 -2
  215. package/es/menu/src/MenuOption.js +1 -1
  216. package/es/menu/src/MenuOptionContent.js +1 -1
  217. package/es/menu/src/MenuOptionGroup.d.ts +1 -4
  218. package/es/menu/src/MenuOptionGroup.js +4 -5
  219. package/es/menu/src/Submenu.d.ts +1 -4
  220. package/es/menu/src/Submenu.js +3 -4
  221. package/es/menu/src/context.d.ts +4 -0
  222. package/es/menu/src/context.js +4 -0
  223. package/es/menu/src/use-menu-child.js +1 -3
  224. package/es/menu/src/useCheckDeprecated.d.ts +1 -1
  225. package/es/menu/src/utils.d.ts +1 -1
  226. package/es/menu/src/utils.js +5 -3
  227. package/es/message/src/Message.d.ts +2 -158
  228. package/es/message/src/Message.js +2 -2
  229. package/es/message/src/MessageProvider.d.ts +4 -9
  230. package/es/message/src/MessageProvider.js +2 -3
  231. package/es/message/src/context.d.ts +7 -0
  232. package/es/message/src/context.js +3 -0
  233. package/es/message/src/types.d.ts +1 -1
  234. package/es/message/src/use-message.js +1 -1
  235. package/es/modal/src/BodyWrapper.d.ts +6 -4
  236. package/es/modal/src/BodyWrapper.js +2 -2
  237. package/es/modal/src/Modal.d.ts +8 -5
  238. package/es/modal/src/Modal.js +2 -2
  239. package/es/modal/src/presetProps.d.ts +3 -2
  240. package/es/modal/src/presetProps.js +1 -1
  241. package/es/notification/index.d.ts +1 -1
  242. package/es/notification/src/Notification.d.ts +5 -6
  243. package/es/notification/src/Notification.js +3 -5
  244. package/es/notification/src/NotificationContainer.d.ts +1 -2
  245. package/es/notification/src/NotificationContainer.js +2 -2
  246. package/es/notification/src/NotificationEnvironment.d.ts +7 -8
  247. package/es/notification/src/NotificationEnvironment.js +3 -3
  248. package/es/notification/src/NotificationProvider.d.ts +11 -7
  249. package/es/notification/src/NotificationProvider.js +6 -6
  250. package/es/notification/src/context.d.ts +2 -0
  251. package/es/notification/src/context.js +2 -0
  252. package/es/page-header/src/PageHeader.js +1 -1
  253. package/es/pagination/src/Pagination.js +1 -1
  254. package/es/popconfirm/src/Popconfirm.d.ts +21 -8
  255. package/es/popconfirm/src/Popconfirm.js +1 -1
  256. package/es/popover/index.d.ts +1 -0
  257. package/es/popover/src/Popover.d.ts +21 -4
  258. package/es/popover/src/Popover.js +9 -2
  259. package/es/popover/src/PopoverBody.d.ts +4 -0
  260. package/es/popover/src/PopoverBody.js +13 -11
  261. package/es/popover/src/styles/index.cssr.js +2 -2
  262. package/es/popselect/src/Popselect.d.ts +31 -8
  263. package/es/popselect/src/Popselect.js +8 -6
  264. package/es/popselect/src/PopselectPanel.d.ts +2 -5
  265. package/es/popselect/src/PopselectPanel.js +4 -2
  266. package/es/progress/src/Progress.d.ts +1 -1
  267. package/es/progress/src/Progress.js +1 -1
  268. package/es/radio/src/Radio.js +1 -1
  269. package/es/radio/src/RadioGroup.js +1 -1
  270. package/es/rate/src/Rate.js +1 -1
  271. package/es/result/src/Result.d.ts +4 -4
  272. package/es/result/src/Result.js +1 -1
  273. package/es/select/index.d.ts +2 -0
  274. package/es/select/src/Select.d.ts +27 -24
  275. package/es/select/src/Select.js +71 -41
  276. package/es/select/src/interface.d.ts +2 -0
  277. package/es/skeleton/src/Skeleton.js +1 -1
  278. package/es/slider/src/Slider.js +1 -1
  279. package/es/space/src/Space.js +1 -1
  280. package/es/spin/src/Spin.js +1 -1
  281. package/es/statistic/src/Statistic.js +1 -1
  282. package/es/steps/src/Steps.js +1 -1
  283. package/es/switch/src/Switch.js +1 -1
  284. package/es/table/src/Table.js +1 -1
  285. package/es/tabs/src/Tabs.d.ts +7 -4
  286. package/es/tabs/src/Tabs.js +12 -4
  287. package/es/tag/src/Tag.d.ts +4 -4
  288. package/es/tag/src/Tag.js +1 -1
  289. package/es/tag/src/common-props.d.ts +1 -1
  290. package/es/tag/src/styles/index.cssr.js +5 -17
  291. package/es/theme-editor/src/ThemeEditor.js +1 -1
  292. package/es/themes/dark.js +3 -0
  293. package/es/themes/light.js +3 -0
  294. package/es/themes/utils.d.ts +2 -1
  295. package/es/themes/utils.js +16 -4
  296. package/es/thing/src/Thing.js +1 -1
  297. package/es/time-picker/src/TimePicker.d.ts +7 -5
  298. package/es/time-picker/src/TimePicker.js +5 -5
  299. package/es/timeline/src/Timeline.js +1 -1
  300. package/es/timeline/src/TimelineItem.d.ts +4 -4
  301. package/es/tooltip/src/Tooltip.d.ts +20 -7
  302. package/es/tooltip/src/Tooltip.js +1 -1
  303. package/es/transfer/src/Transfer.d.ts +1 -1
  304. package/es/transfer/src/Transfer.js +1 -1
  305. package/es/tree/src/Tree.d.ts +6 -2
  306. package/es/tree/src/Tree.js +15 -8
  307. package/es/tree/src/TreeNode.d.ts +2 -0
  308. package/es/tree/src/TreeNode.js +37 -10
  309. package/es/tree/src/TreeNodeContent.d.ts +3 -1
  310. package/es/tree/src/TreeNodeContent.js +4 -3
  311. package/es/tree/src/interface.d.ts +5 -1
  312. package/es/tree-select/src/TreeSelect.d.ts +16 -14
  313. package/es/tree-select/src/TreeSelect.js +8 -5
  314. package/es/typography/src/a.js +1 -1
  315. package/es/typography/src/blockquote.js +1 -1
  316. package/es/typography/src/create-header.d.ts +4 -4
  317. package/es/typography/src/create-header.js +1 -1
  318. package/es/typography/src/headers.d.ts +18 -18
  319. package/es/typography/src/hr.js +1 -1
  320. package/es/typography/src/ol.js +1 -1
  321. package/es/typography/src/p.js +1 -1
  322. package/es/typography/src/text.js +1 -1
  323. package/es/typography/src/ul.js +1 -1
  324. package/es/upload/src/Upload.js +1 -1
  325. package/es/upload/src/UploadFile.d.ts +1 -1
  326. package/es/upload/src/UploadProgress.d.ts +2 -2
  327. package/es/version.d.ts +1 -1
  328. package/es/version.js +1 -1
  329. package/lib/_internal/clear/src/Clear.js +3 -2
  330. package/lib/_internal/close/src/Close.js +1 -1
  331. package/lib/_internal/icon/src/Icon.js +1 -1
  332. package/lib/_internal/icons/ArrowUp.d.ts +2 -0
  333. package/lib/_internal/icons/ArrowUp.js +11 -0
  334. package/lib/_internal/icons/index.d.ts +1 -0
  335. package/lib/_internal/icons/index.js +3 -1
  336. package/lib/_internal/loading/src/Loading.js +1 -1
  337. package/lib/_internal/menu-mask/src/MenuMask.js +1 -1
  338. package/lib/_internal/scrollbar/src/ScrollBar.js +1 -1
  339. package/lib/_internal/select-menu/src/SelectMenu.d.ts +5 -5
  340. package/lib/_internal/select-menu/src/SelectMenu.js +31 -15
  341. package/lib/_internal/selection/src/Selection.d.ts +13 -5
  342. package/lib/_internal/selection/src/Selection.js +24 -15
  343. package/lib/_internal/selection/src/interface.d.ts +2 -2
  344. package/lib/_internal/selection/src/styles/index.cssr.js +15 -30
  345. package/lib/_internal/slot-machine/src/SlotMachine.js +1 -1
  346. package/lib/_internal/wave/src/Wave.js +1 -1
  347. package/lib/_mixins/use-config.js +2 -2
  348. package/lib/_mixins/use-css-vars-class.d.ts +4 -2
  349. package/lib/_mixins/use-css-vars-class.js +25 -13
  350. package/lib/_mixins/use-form-item.d.ts +4 -0
  351. package/lib/_mixins/use-form-item.js +7 -0
  352. package/lib/_mixins/use-hljs.js +2 -2
  353. package/lib/_mixins/use-locale.js +2 -2
  354. package/lib/_mixins/use-style.js +1 -1
  355. package/lib/_mixins/use-theme.d.ts +1 -1
  356. package/lib/_mixins/use-theme.js +3 -3
  357. package/lib/_utils/cssr/index.d.ts +1 -2
  358. package/lib/_utils/cssr/index.js +1 -15
  359. package/lib/_utils/index.d.ts +1 -1
  360. package/lib/_utils/index.js +5 -1
  361. package/lib/_utils/vue/index.d.ts +1 -1
  362. package/lib/_utils/vue/index.js +4 -1
  363. package/lib/_utils/vue/resolve-slot.d.ts +8 -2
  364. package/lib/_utils/vue/resolve-slot.js +22 -2
  365. package/lib/affix/src/Affix.js +1 -1
  366. package/lib/alert/src/Alert.d.ts +4 -4
  367. package/lib/alert/src/Alert.js +1 -1
  368. package/lib/anchor/src/AnchorAdapter.js +1 -1
  369. package/lib/auto-complete/src/AutoComplete.d.ts +17 -2
  370. package/lib/auto-complete/src/AutoComplete.js +9 -5
  371. package/lib/avatar/src/Avatar.js +3 -3
  372. package/lib/avatar/src/AvatarGroup.d.ts +0 -1
  373. package/lib/avatar/src/AvatarGroup.js +3 -5
  374. package/lib/avatar/src/context.d.ts +2 -0
  375. package/lib/avatar/src/context.js +5 -0
  376. package/lib/back-top/src/BackTop.js +1 -1
  377. package/lib/badge/src/Badge.d.ts +4 -4
  378. package/lib/badge/src/Badge.js +1 -1
  379. package/lib/breadcrumb/src/Breadcrumb.js +1 -1
  380. package/lib/button/src/Button.d.ts +4 -3
  381. package/lib/button/src/Button.js +264 -228
  382. package/lib/button/src/ButtonGroup.js +1 -1
  383. package/lib/button/src/styles/button.cssr.js +1 -0
  384. package/lib/calendar/src/Calendar.js +1 -1
  385. package/lib/card/src/Card.d.ts +5 -1
  386. package/lib/card/src/Card.js +3 -2
  387. package/lib/carousel/src/Carousel.js +4 -1
  388. package/lib/carousel/src/CarouselArrow.js +5 -8
  389. package/lib/carousel/src/styles/index.cssr.js +59 -48
  390. package/lib/carousel/styles/light.js +2 -2
  391. package/lib/cascader/src/Cascader.d.ts +6 -4
  392. package/lib/cascader/src/Cascader.js +6 -6
  393. package/lib/checkbox/src/Checkbox.js +1 -1
  394. package/lib/code/src/Code.js +1 -1
  395. package/lib/collapse/src/Collapse.js +1 -1
  396. package/lib/collapse-transition/src/CollapseTransition.js +1 -1
  397. package/lib/color-picker/src/ColorInputUnit.js +2 -2
  398. package/lib/color-picker/src/ColorPicker.d.ts +24 -17
  399. package/lib/color-picker/src/ColorPicker.js +8 -5
  400. package/lib/color-picker/src/ColorPickerTrigger.js +2 -2
  401. package/lib/color-picker/src/context.d.ts +9 -0
  402. package/lib/color-picker/src/context.js +5 -0
  403. package/lib/color-picker/src/styles/index.cssr.js +1 -0
  404. package/lib/components.d.ts +2 -1
  405. package/lib/components.js +2 -1
  406. package/lib/composables/use-theme-vars.js +2 -2
  407. package/lib/config-provider/src/ConfigProvider.d.ts +15 -3
  408. package/lib/config-provider/src/ConfigProvider.js +31 -5
  409. package/lib/config-provider/src/context.d.ts +2 -0
  410. package/lib/config-provider/src/context.js +5 -0
  411. package/lib/config-provider/src/interface.d.ts +2 -1
  412. package/lib/config-provider/src/internal-interface.d.ts +4 -0
  413. package/lib/data-table/src/DataTable.d.ts +1 -1
  414. package/lib/data-table/src/DataTable.js +1 -1
  415. package/lib/data-table/src/interface.d.ts +2 -2
  416. package/lib/data-table/src/use-check.d.ts +2 -2
  417. package/lib/data-table/src/use-group-header.d.ts +1 -1
  418. package/lib/data-table/src/use-scroll.d.ts +1 -1
  419. package/lib/data-table/src/use-scroll.js +2 -2
  420. package/lib/data-table/src/use-sorter.d.ts +1 -1
  421. package/lib/data-table/src/use-table-data.d.ts +1 -1
  422. package/lib/data-table/src/utils.d.ts +2 -1
  423. package/lib/data-table/src/utils.js +15 -4
  424. package/lib/date-picker/src/DatePicker.d.ts +2 -1
  425. package/lib/date-picker/src/DatePicker.js +6 -6
  426. package/lib/descriptions/src/Descriptions.d.ts +2 -2
  427. package/lib/descriptions/src/Descriptions.js +1 -1
  428. package/lib/dialog/index.d.ts +3 -3
  429. package/lib/dialog/index.js +2 -5
  430. package/lib/dialog/src/Dialog.d.ts +28 -61
  431. package/lib/dialog/src/Dialog.js +5 -33
  432. package/lib/dialog/src/DialogEnvironment.d.ts +12 -13
  433. package/lib/dialog/src/DialogEnvironment.js +6 -24
  434. package/lib/dialog/src/DialogProvider.d.ts +4 -6
  435. package/lib/dialog/src/DialogProvider.js +8 -12
  436. package/lib/dialog/src/context.d.ts +3 -0
  437. package/lib/dialog/src/context.js +6 -0
  438. package/lib/dialog/src/dialogProps.d.ts +32 -0
  439. package/lib/dialog/src/dialogProps.js +32 -0
  440. package/lib/dialog/src/use-dialog.js +2 -2
  441. package/lib/divider/src/Divider.js +1 -1
  442. package/lib/drawer/index.d.ts +1 -0
  443. package/lib/drawer/src/Drawer.js +1 -1
  444. package/lib/dropdown/src/Dropdown.d.ts +17 -5
  445. package/lib/dropdown/src/Dropdown.js +6 -6
  446. package/lib/dropdown/src/DropdownGroup.js +1 -0
  447. package/lib/dropdown/src/DropdownGroupHeader.js +3 -4
  448. package/lib/dropdown/src/DropdownMenu.d.ts +0 -1
  449. package/lib/dropdown/src/DropdownMenu.js +6 -7
  450. package/lib/dropdown/src/DropdownOption.d.ts +3 -0
  451. package/lib/dropdown/src/DropdownOption.js +9 -25
  452. package/lib/dropdown/src/context.d.ts +6 -0
  453. package/lib/dropdown/src/context.js +7 -0
  454. package/lib/dropdown/src/interface.d.ts +1 -1
  455. package/lib/dynamic-input/src/DynamicInput.d.ts +16 -33
  456. package/lib/dynamic-input/src/DynamicInput.js +70 -33
  457. package/lib/dynamic-tags/src/DynamicTags.d.ts +11 -20
  458. package/lib/dynamic-tags/src/DynamicTags.js +12 -14
  459. package/lib/element/src/Element.js +1 -1
  460. package/lib/ellipsis/src/Ellipsis.js +1 -1
  461. package/lib/empty/src/Empty.js +3 -3
  462. package/lib/form/src/Form.d.ts +1 -1
  463. package/lib/form/src/Form.js +4 -4
  464. package/lib/form/src/FormItem.d.ts +5 -5
  465. package/lib/form/src/FormItem.js +5 -4
  466. package/lib/form/src/FormItemCol.d.ts +4 -4
  467. package/lib/form/src/FormItemGridItem.d.ts +5 -5
  468. package/lib/form/src/FormItemRow.d.ts +3 -3
  469. package/lib/form/src/context.d.ts +3 -0
  470. package/lib/form/src/context.js +6 -0
  471. package/lib/form/src/interface.d.ts +4 -3
  472. package/lib/form/src/interface.js +0 -4
  473. package/lib/form/src/styles/form-item.cssr.js +3 -2
  474. package/lib/form/src/utils.d.ts +1 -1
  475. package/lib/form/src/utils.js +4 -4
  476. package/lib/global-style/src/GlobalStyle.js +2 -2
  477. package/lib/gradient-text/src/GradientText.d.ts +5 -5
  478. package/lib/gradient-text/src/GradientText.js +1 -1
  479. package/lib/grid/src/Grid.d.ts +0 -1
  480. package/lib/grid/src/Grid.js +4 -6
  481. package/lib/grid/src/GridItem.js +2 -2
  482. package/lib/grid/src/config.d.ts +3 -0
  483. package/lib/grid/src/config.js +6 -0
  484. package/lib/icon/index.d.ts +1 -1
  485. package/lib/icon/index.js +1 -4
  486. package/lib/icon/src/Icon.d.ts +4 -3
  487. package/lib/icon/src/Icon.js +6 -5
  488. package/lib/icon-wrapper/index.d.ts +1 -0
  489. package/lib/icon-wrapper/index.js +5 -0
  490. package/lib/icon-wrapper/src/IconWrapper.d.ts +50 -0
  491. package/lib/icon-wrapper/src/IconWrapper.js +54 -0
  492. package/lib/icon-wrapper/src/styles/index.cssr.d.ts +2 -0
  493. package/lib/icon-wrapper/src/styles/index.cssr.js +23 -0
  494. package/lib/icon-wrapper/styles/dark.d.ts +3 -0
  495. package/lib/icon-wrapper/styles/dark.js +10 -0
  496. package/lib/icon-wrapper/styles/index.d.ts +3 -0
  497. package/lib/icon-wrapper/styles/index.js +10 -0
  498. package/lib/icon-wrapper/styles/light.d.ts +10 -0
  499. package/lib/icon-wrapper/styles/light.js +18 -0
  500. package/lib/image/src/ImagePreview.js +1 -1
  501. package/lib/input/src/Input.d.ts +7 -2
  502. package/lib/input/src/Input.js +20 -16
  503. package/lib/input/src/InputGroup.js +1 -1
  504. package/lib/input/src/InputGroupLabel.js +1 -1
  505. package/lib/input/src/WordCount.js +9 -8
  506. package/lib/input/src/styles/input.cssr.js +4 -4
  507. package/lib/input-number/src/InputNumber.d.ts +3 -2
  508. package/lib/input-number/src/InputNumber.js +23 -21
  509. package/lib/layout/src/Layout.js +1 -1
  510. package/lib/layout/src/LayoutFooter.js +1 -1
  511. package/lib/layout/src/LayoutHeader.js +1 -1
  512. package/lib/layout/src/LayoutSider.js +1 -1
  513. package/lib/legacy-grid/src/Col.js +0 -6
  514. package/lib/legacy-grid/src/Row.js +1 -1
  515. package/lib/list/src/List.js +1 -1
  516. package/lib/loading-bar/src/LoadingBar.js +3 -3
  517. package/lib/loading-bar/src/LoadingBarProvider.d.ts +3 -8
  518. package/lib/loading-bar/src/LoadingBarProvider.js +3 -6
  519. package/lib/loading-bar/src/context.d.ts +7 -0
  520. package/lib/loading-bar/src/context.js +6 -0
  521. package/lib/loading-bar/src/use-loading-bar.js +2 -2
  522. package/lib/locales/common/deDE.js +13 -15
  523. package/lib/locales/common/enGB.d.ts +109 -0
  524. package/lib/locales/common/enGB.js +111 -0
  525. package/lib/locales/common/jaJP.js +12 -14
  526. package/lib/locales/date/enGB.d.ts +3 -0
  527. package/lib/locales/date/enGB.js +11 -0
  528. package/lib/locales/index.d.ts +2 -0
  529. package/lib/locales/index.js +5 -1
  530. package/lib/log/index.d.ts +1 -1
  531. package/lib/log/src/Log.d.ts +17 -12
  532. package/lib/log/src/Log.js +10 -18
  533. package/lib/log/src/LogLine.js +2 -2
  534. package/lib/log/src/context.d.ts +2 -0
  535. package/lib/log/src/context.js +5 -0
  536. package/lib/log/src/styles/index.cssr.js +2 -3
  537. package/lib/mention/src/Mention.d.ts +17 -2
  538. package/lib/mention/src/Mention.js +7 -3
  539. package/lib/menu/src/Menu.d.ts +2 -4
  540. package/lib/menu/src/Menu.js +3 -4
  541. package/lib/menu/src/MenuDivider.js +2 -2
  542. package/lib/menu/src/MenuOption.d.ts +1 -2
  543. package/lib/menu/src/MenuOption.js +2 -2
  544. package/lib/menu/src/MenuOptionContent.js +2 -2
  545. package/lib/menu/src/MenuOptionGroup.d.ts +1 -4
  546. package/lib/menu/src/MenuOptionGroup.js +7 -8
  547. package/lib/menu/src/Submenu.d.ts +1 -4
  548. package/lib/menu/src/Submenu.js +6 -7
  549. package/lib/menu/src/context.d.ts +4 -0
  550. package/lib/menu/src/context.js +7 -0
  551. package/lib/menu/src/use-menu-child.js +4 -6
  552. package/lib/menu/src/useCheckDeprecated.d.ts +1 -1
  553. package/lib/menu/src/utils.d.ts +1 -1
  554. package/lib/menu/src/utils.js +8 -25
  555. package/lib/message/src/Message.d.ts +2 -158
  556. package/lib/message/src/Message.js +3 -3
  557. package/lib/message/src/MessageProvider.d.ts +4 -9
  558. package/lib/message/src/MessageProvider.js +3 -5
  559. package/lib/message/src/context.d.ts +7 -0
  560. package/lib/message/src/context.js +6 -0
  561. package/lib/message/src/types.d.ts +1 -1
  562. package/lib/message/src/use-message.js +2 -2
  563. package/lib/modal/src/BodyWrapper.d.ts +6 -4
  564. package/lib/modal/src/BodyWrapper.js +3 -3
  565. package/lib/modal/src/Modal.d.ts +8 -5
  566. package/lib/modal/src/Modal.js +3 -3
  567. package/lib/modal/src/presetProps.d.ts +3 -2
  568. package/lib/modal/src/presetProps.js +2 -2
  569. package/lib/notification/index.d.ts +1 -1
  570. package/lib/notification/src/Notification.d.ts +5 -6
  571. package/lib/notification/src/Notification.js +5 -7
  572. package/lib/notification/src/NotificationContainer.d.ts +1 -2
  573. package/lib/notification/src/NotificationContainer.js +4 -3
  574. package/lib/notification/src/NotificationEnvironment.d.ts +7 -8
  575. package/lib/notification/src/NotificationEnvironment.js +4 -23
  576. package/lib/notification/src/NotificationProvider.d.ts +11 -7
  577. package/lib/notification/src/NotificationProvider.js +9 -9
  578. package/lib/notification/src/context.d.ts +2 -0
  579. package/lib/notification/src/context.js +5 -0
  580. package/lib/page-header/src/PageHeader.js +1 -1
  581. package/lib/pagination/src/Pagination.js +1 -1
  582. package/lib/popconfirm/src/Popconfirm.d.ts +21 -8
  583. package/lib/popconfirm/src/Popconfirm.js +1 -1
  584. package/lib/popover/index.d.ts +1 -0
  585. package/lib/popover/src/Popover.d.ts +21 -4
  586. package/lib/popover/src/Popover.js +9 -2
  587. package/lib/popover/src/PopoverBody.d.ts +4 -0
  588. package/lib/popover/src/PopoverBody.js +11 -9
  589. package/lib/popover/src/styles/index.cssr.js +2 -2
  590. package/lib/popselect/src/Popselect.d.ts +31 -8
  591. package/lib/popselect/src/Popselect.js +8 -6
  592. package/lib/popselect/src/PopselectPanel.d.ts +2 -5
  593. package/lib/popselect/src/PopselectPanel.js +4 -2
  594. package/lib/progress/src/Progress.d.ts +1 -1
  595. package/lib/progress/src/Progress.js +1 -1
  596. package/lib/radio/src/Radio.js +1 -1
  597. package/lib/radio/src/RadioGroup.js +1 -1
  598. package/lib/rate/src/Rate.js +1 -1
  599. package/lib/result/src/Result.d.ts +4 -4
  600. package/lib/result/src/Result.js +1 -1
  601. package/lib/select/index.d.ts +2 -0
  602. package/lib/select/src/Select.d.ts +27 -24
  603. package/lib/select/src/Select.js +71 -41
  604. package/lib/select/src/interface.d.ts +2 -0
  605. package/lib/skeleton/src/Skeleton.js +1 -1
  606. package/lib/slider/src/Slider.js +1 -1
  607. package/lib/space/src/Space.js +1 -1
  608. package/lib/spin/src/Spin.js +1 -1
  609. package/lib/statistic/src/Statistic.js +1 -1
  610. package/lib/steps/src/Steps.js +1 -1
  611. package/lib/switch/src/Switch.js +1 -1
  612. package/lib/table/src/Table.js +1 -1
  613. package/lib/tabs/src/Tabs.d.ts +7 -4
  614. package/lib/tabs/src/Tabs.js +12 -4
  615. package/lib/tag/src/Tag.d.ts +4 -4
  616. package/lib/tag/src/Tag.js +1 -1
  617. package/lib/tag/src/common-props.d.ts +1 -1
  618. package/lib/tag/src/styles/index.cssr.js +5 -17
  619. package/lib/theme-editor/src/ThemeEditor.js +1 -1
  620. package/lib/themes/dark.js +87 -84
  621. package/lib/themes/light.js +87 -84
  622. package/lib/themes/utils.d.ts +2 -1
  623. package/lib/themes/utils.js +16 -4
  624. package/lib/thing/src/Thing.js +1 -1
  625. package/lib/time-picker/src/TimePicker.d.ts +7 -5
  626. package/lib/time-picker/src/TimePicker.js +5 -5
  627. package/lib/timeline/src/Timeline.js +1 -1
  628. package/lib/timeline/src/TimelineItem.d.ts +4 -4
  629. package/lib/tooltip/src/Tooltip.d.ts +20 -7
  630. package/lib/tooltip/src/Tooltip.js +1 -1
  631. package/lib/transfer/src/Transfer.d.ts +1 -1
  632. package/lib/transfer/src/Transfer.js +1 -1
  633. package/lib/tree/src/Tree.d.ts +6 -2
  634. package/lib/tree/src/Tree.js +15 -8
  635. package/lib/tree/src/TreeNode.d.ts +2 -0
  636. package/lib/tree/src/TreeNode.js +37 -10
  637. package/lib/tree/src/TreeNodeContent.d.ts +3 -1
  638. package/lib/tree/src/TreeNodeContent.js +4 -3
  639. package/lib/tree/src/interface.d.ts +5 -1
  640. package/lib/tree-select/src/TreeSelect.d.ts +16 -14
  641. package/lib/tree-select/src/TreeSelect.js +8 -5
  642. package/lib/typography/src/a.js +1 -1
  643. package/lib/typography/src/blockquote.js +1 -1
  644. package/lib/typography/src/create-header.d.ts +4 -4
  645. package/lib/typography/src/create-header.js +1 -1
  646. package/lib/typography/src/headers.d.ts +18 -18
  647. package/lib/typography/src/hr.js +1 -1
  648. package/lib/typography/src/ol.js +1 -1
  649. package/lib/typography/src/p.js +1 -1
  650. package/lib/typography/src/text.js +1 -1
  651. package/lib/typography/src/ul.js +1 -1
  652. package/lib/upload/src/Upload.js +1 -1
  653. package/lib/upload/src/UploadFile.d.ts +1 -1
  654. package/lib/upload/src/UploadProgress.d.ts +2 -2
  655. package/lib/version.d.ts +1 -1
  656. package/lib/version.js +1 -1
  657. package/package.json +10 -11
  658. package/volar.d.ts +1 -0
  659. package/web-types.json +434 -220
@@ -1,4 +1,5 @@
1
1
  import { defineComponent, inject, h, computed } from 'vue';
2
+ import { resolveSlotWithProps } from '../../_utils';
2
3
  import { inputInjectionKey } from './interface';
3
4
  import { len } from './utils';
4
5
  export default defineComponent({
@@ -16,15 +17,15 @@ export default defineComponent({
16
17
  return () => {
17
18
  const { value: maxlength } = maxlengthRef;
18
19
  const { value: mergedValue } = mergedValueRef;
19
- return (h("span", { class: `${mergedClsPrefixRef.value}-input-word-count` }, slots.default
20
- ? slots.default({
21
- value: mergedValue === null || Array.isArray(mergedValue)
22
- ? ''
23
- : mergedValue
24
- })
25
- : maxlength === undefined
20
+ return (h("span", { class: `${mergedClsPrefixRef.value}-input-word-count` }, resolveSlotWithProps(slots.default, {
21
+ value: mergedValue === null || Array.isArray(mergedValue)
22
+ ? ''
23
+ : mergedValue
24
+ }, () => [
25
+ maxlength === undefined
26
26
  ? wordCountRef.value
27
- : `${wordCountRef.value} / ${maxlength}`));
27
+ : `${wordCountRef.value} / ${maxlength}`
28
+ ])));
28
29
  };
29
30
  }
30
31
  });
@@ -1,4 +1,4 @@
1
- import { cB, c, cE, cM, cNotM, insideFormItem } from '../../../_utils/cssr'; // vars:
1
+ import { cB, c, cE, cM, cNotM } from '../../../_utils/cssr'; // vars:
2
2
  // --n-bezier
3
3
  // --n-color
4
4
  // --n-font-size
@@ -33,7 +33,7 @@ import { cB, c, cE, cM, cNotM, insideFormItem } from '../../../_utils/cssr'; //
33
33
  // --n-loading-color
34
34
  // ...form item vars
35
35
 
36
- export default c([cB('input', `
36
+ export default cB('input', `
37
37
  max-width: 100%;
38
38
  cursor: text;
39
39
  line-height: 1.5;
@@ -47,7 +47,7 @@ export default c([cB('input', `
47
47
  transition: background-color .3s var(--n-bezier);
48
48
  font-size: var(--n-font-size);
49
49
  --n-padding-vertical: calc((var(--n-height) - 1.5 * var(--n-font-size)) / 2);
50
- `, [// common
50
+ `, [// common
51
51
  cE('input, textarea', `
52
52
  overflow: hidden;
53
53
  flex-grow: 1;
@@ -241,7 +241,7 @@ cM('pair', [cE('input-el, placeholder', 'text-align: center;'), cE('separator',
241
241
  transition: color .3s var(--n-bezier);
242
242
  margin-left: 4px;
243
243
  font-variant: tabular-nums;
244
- `)]), ['warning', 'error'].map(status => insideFormItem(status, cB('input', [cNotM('disabled', [cB('base-loading', `
244
+ `), ['warning', 'error'].map(status => cM(`${status}-status`, [cNotM('disabled', [cB('base-loading', `
245
245
  color: var(--n-loading-color-${status})
246
246
  `), cE('input-el, textarea-el', `
247
247
  caret-color: var(--n-caret-color-${status});
@@ -259,4 +259,4 @@ cM('pair', [cE('input-el, placeholder', 'text-align: center;'), cE('separator',
259
259
  `, [cE('state-border', `
260
260
  box-shadow: var(--n-box-shadow-focus-${status});
261
261
  border: var(--n-border-focus-${status});
262
- `)])])])))]);
262
+ `)])])]))]);
@@ -1,5 +1,5 @@
1
1
  import { PropType } from 'vue';
2
- import { MaybeArray, ExtractPublicPropTypes } from '../../_utils';
2
+ import type { MaybeArray, ExtractPublicPropTypes } from '../../_utils';
3
3
  import type { OnUpdateValue } from './interface';
4
4
  declare const inputNumberProps: {
5
5
  loading: {
@@ -1748,6 +1748,7 @@ declare const _default: import("vue").DefineComponent<{
1748
1748
  displayedValue: import("vue").Ref<string>;
1749
1749
  addable: import("vue").ComputedRef<boolean>;
1750
1750
  minusable: import("vue").ComputedRef<boolean>;
1751
+ mergedStatus: import("vue").ComputedRef<import("../../form/src/interface").FormValidationStatus | undefined>;
1751
1752
  handleFocus: (e: FocusEvent) => void;
1752
1753
  handleBlur: (e: FocusEvent) => void;
1753
1754
  handleClear: (e: MouseEvent) => void;
@@ -3016,8 +3017,8 @@ declare const _default: import("vue").DefineComponent<{
3016
3017
  disabled: boolean | undefined;
3017
3018
  step: string | number;
3018
3019
  onChange: MaybeArray<OnUpdateValue> | undefined;
3019
- loading: boolean;
3020
3020
  bordered: boolean | undefined;
3021
+ loading: boolean;
3021
3022
  clearable: boolean;
3022
3023
  defaultValue: number | null;
3023
3024
  keyboard: {
@@ -51,10 +51,10 @@ export default defineComponent({
51
51
  props: inputNumberProps,
52
52
  setup(props) {
53
53
  const { mergedBorderedRef, mergedClsPrefixRef } = useConfig(props);
54
- const themeRef = useTheme('InputNumber', 'InputNumber', style, inputNumberLight, props, mergedClsPrefixRef);
54
+ const themeRef = useTheme('InputNumber', '-input-number', style, inputNumberLight, props, mergedClsPrefixRef);
55
55
  const { localeRef } = useLocale('InputNumber');
56
56
  const formItem = useFormItem(props);
57
- const { mergedSizeRef, mergedDisabledRef } = formItem;
57
+ const { mergedSizeRef, mergedDisabledRef, mergedStatusRef } = formItem;
58
58
  // dom ref
59
59
  const inputInstRef = ref(null);
60
60
  const minusButtonInstRef = ref(null);
@@ -343,7 +343,7 @@ export default defineComponent({
343
343
  };
344
344
  return Object.assign(Object.assign({}, exposedMethods), { inputInstRef,
345
345
  minusButtonInstRef,
346
- addButtonInstRef, mergedClsPrefix: mergedClsPrefixRef, mergedBordered: mergedBorderedRef, uncontrolledValue: uncontrolledValueRef, mergedValue: mergedValueRef, mergedPlaceholder: mergedPlaceholderRef, displayedValueInvalid: displayedValueInvalidRef, mergedSize: mergedSizeRef, mergedDisabled: mergedDisabledRef, displayedValue: displayedValueRef, addable: addableRef, minusable: minusableRef, handleFocus,
346
+ addButtonInstRef, mergedClsPrefix: mergedClsPrefixRef, mergedBordered: mergedBorderedRef, uncontrolledValue: uncontrolledValueRef, mergedValue: mergedValueRef, mergedPlaceholder: mergedPlaceholderRef, displayedValueInvalid: displayedValueInvalidRef, mergedSize: mergedSizeRef, mergedDisabled: mergedDisabledRef, displayedValue: displayedValueRef, addable: addableRef, minusable: minusableRef, mergedStatus: mergedStatusRef, handleFocus,
347
347
  handleBlur,
348
348
  handleClear,
349
349
  handleMouseDown,
@@ -368,24 +368,26 @@ export default defineComponent({
368
368
  render() {
369
369
  const { mergedClsPrefix } = this;
370
370
  return (h("div", { class: `${mergedClsPrefix}-input-number` },
371
- h(NInput, { ref: "inputInstRef", bordered: this.mergedBordered, loading: this.loading, value: this.displayedValue, onUpdateValue: this.handleUpdateDisplayedValue, theme: this.mergedTheme.peers.Input, themeOverrides: this.mergedTheme.peerOverrides.Input, builtinThemeOverrides: this.inputThemeOverrides, size: this.mergedSize, placeholder: this.mergedPlaceholder, disabled: this.mergedDisabled, readonly: this.readonly, textDecoration: this.displayedValueInvalid ? 'line-through' : undefined, onFocus: this.handleFocus, onBlur: this.handleBlur, onKeydown: this.handleKeyDown, onMousedown: this.handleMouseDown, onClear: this.handleClear, clearable: this.clearable, internalLoadingBeforeSuffix: true }, {
372
- _: 2,
373
- prefix: this.$slots.prefix,
374
- suffix: this.showButton
375
- ? () => [
376
- this.$slots.suffix && (h("span", { class: `${mergedClsPrefix}-input-number-suffix` }, { default: this.$slots.suffix })),
377
- h(NButton, { text: true, disabled: !this.minusable || this.mergedDisabled || this.readonly, focusable: false, builtinThemeOverrides: this.buttonThemeOverrides, onClick: this.handleMinusClick, ref: "minusButtonInstRef" }, {
378
- default: () => (h(NBaseIcon, { clsPrefix: mergedClsPrefix }, {
379
- default: () => h(RemoveIcon, null)
380
- }))
381
- }),
382
- h(NButton, { text: true, disabled: !this.addable || this.mergedDisabled || this.readonly, focusable: false, builtinThemeOverrides: this.buttonThemeOverrides, onClick: this.handleAddClick, ref: "addButtonInstRef" }, {
383
- default: () => (h(NBaseIcon, { clsPrefix: mergedClsPrefix }, {
384
- default: () => h(AddIcon, null)
385
- }))
386
- })
387
- ]
388
- : this.$slots.suffix
371
+ h(NInput, { ref: "inputInstRef", status: this.mergedStatus, bordered: this.mergedBordered, loading: this.loading, value: this.displayedValue, onUpdateValue: this.handleUpdateDisplayedValue, theme: this.mergedTheme.peers.Input, themeOverrides: this.mergedTheme.peerOverrides.Input, builtinThemeOverrides: this.inputThemeOverrides, size: this.mergedSize, placeholder: this.mergedPlaceholder, disabled: this.mergedDisabled, readonly: this.readonly, textDecoration: this.displayedValueInvalid ? 'line-through' : undefined, onFocus: this.handleFocus, onBlur: this.handleBlur, onKeydown: this.handleKeyDown, onMousedown: this.handleMouseDown, onClear: this.handleClear, clearable: this.clearable, internalLoadingBeforeSuffix: true }, {
372
+ prefix: () => { var _a, _b; return (_b = (_a = this.$slots).prefix) === null || _b === void 0 ? void 0 : _b.call(_a); },
373
+ suffix: () => {
374
+ var _a, _b;
375
+ return this.showButton
376
+ ? [
377
+ this.$slots.suffix && (h("span", { class: `${mergedClsPrefix}-input-number-suffix` }, { default: this.$slots.suffix })),
378
+ h(NButton, { text: true, disabled: !this.minusable || this.mergedDisabled || this.readonly, focusable: false, builtinThemeOverrides: this.buttonThemeOverrides, onClick: this.handleMinusClick, ref: "minusButtonInstRef" }, {
379
+ default: () => (h(NBaseIcon, { clsPrefix: mergedClsPrefix }, {
380
+ default: () => h(RemoveIcon, null)
381
+ }))
382
+ }),
383
+ h(NButton, { text: true, disabled: !this.addable || this.mergedDisabled || this.readonly, focusable: false, builtinThemeOverrides: this.buttonThemeOverrides, onClick: this.handleAddClick, ref: "addButtonInstRef" }, {
384
+ default: () => (h(NBaseIcon, { clsPrefix: mergedClsPrefix }, {
385
+ default: () => h(AddIcon, null)
386
+ }))
387
+ })
388
+ ]
389
+ : (_b = (_a = this.$slots).suffix) === null || _b === void 0 ? void 0 : _b.call(_a);
390
+ }
389
391
  })));
390
392
  }
391
393
  });
@@ -34,7 +34,7 @@ export function createLayoutComponent(isContent) {
34
34
  const scrollableElRef = ref(null);
35
35
  const scrollbarInstRef = ref(null);
36
36
  const { mergedClsPrefixRef } = useConfig(props);
37
- const themeRef = useTheme('Layout', 'Layout', style, layoutLight, props, mergedClsPrefixRef);
37
+ const themeRef = useTheme('Layout', '-layout', style, layoutLight, props, mergedClsPrefixRef);
38
38
  function scrollTo(options, y) {
39
39
  if (props.nativeScrollbar) {
40
40
  const { value: scrollableEl } = scrollableElRef;
@@ -9,7 +9,7 @@ export default defineComponent({
9
9
  props: layoutFooterProps,
10
10
  setup(props) {
11
11
  const { mergedClsPrefixRef } = useConfig(props);
12
- const themeRef = useTheme('Layout', 'LayoutFooter', style, layoutLight, props, mergedClsPrefixRef);
12
+ const themeRef = useTheme('Layout', '-layout-footer', style, layoutLight, props, mergedClsPrefixRef);
13
13
  return {
14
14
  mergedClsPrefix: mergedClsPrefixRef,
15
15
  cssVars: computed(() => {
@@ -16,7 +16,7 @@ export default defineComponent({
16
16
  props: Object.assign(Object.assign({}, useTheme.props), headerProps),
17
17
  setup(props) {
18
18
  const { mergedClsPrefixRef } = useConfig(props);
19
- const themeRef = useTheme('Layout', 'LayoutHeader', style, layoutLight, props, mergedClsPrefixRef);
19
+ const themeRef = useTheme('Layout', '-layout-header', style, layoutLight, props, mergedClsPrefixRef);
20
20
  return {
21
21
  mergedClsPrefix: mergedClsPrefixRef,
22
22
  cssVars: computed(() => {
@@ -135,7 +135,7 @@ export default defineComponent({
135
135
  collapseModeRef: toRef(props, 'collapseMode')
136
136
  });
137
137
  const { mergedClsPrefixRef } = useConfig(props);
138
- const themeRef = useTheme('Layout', 'LayoutSider', style, layoutLight, props, mergedClsPrefixRef);
138
+ const themeRef = useTheme('Layout', '-layout-sider', style, layoutLight, props, mergedClsPrefixRef);
139
139
  function handleTransitionend(e) {
140
140
  var _a, _b;
141
141
  if (e.propertyName === 'max-width') {
@@ -1,8 +1,6 @@
1
1
  import { h, computed, defineComponent, inject } from 'vue';
2
2
  import { formatLength, keysOf, throwError } from '../../_utils';
3
- import { useStyle } from '../../_mixins';
4
3
  import { rowInjectionKey } from './Row';
5
- import style from './styles/index.cssr';
6
4
  export const colProps = {
7
5
  span: {
8
6
  type: [String, Number],
@@ -26,7 +24,6 @@ export default defineComponent({
26
24
  name: 'Col',
27
25
  props: colProps,
28
26
  setup(props) {
29
- useStyle('Grid', style);
30
27
  const NRow = inject(rowInjectionKey, null);
31
28
  if (!NRow)
32
29
  throwError('col', '`n-col` must be placed inside `n-row`.');
@@ -18,7 +18,7 @@ export default defineComponent({
18
18
  props: rowProps,
19
19
  setup(props) {
20
20
  const { mergedClsPrefixRef } = useConfig(props);
21
- useStyle('LegacyGrid', style, mergedClsPrefixRef);
21
+ useStyle('-legacy-grid', style, mergedClsPrefixRef);
22
22
  const verticalGutterRef = useMemo(() => {
23
23
  const { gutter } = props;
24
24
  if (Array.isArray(gutter)) {
@@ -16,7 +16,7 @@ export default defineComponent({
16
16
  props: listProps,
17
17
  setup(props) {
18
18
  const { mergedClsPrefixRef } = useConfig(props);
19
- const themeRef = useTheme('List', 'List', style, listLight, props, mergedClsPrefixRef);
19
+ const themeRef = useTheme('List', '-list', style, listLight, props, mergedClsPrefixRef);
20
20
  provide(listInjectionKey, {
21
21
  mergedClsPrefixRef
22
22
  });
@@ -10,7 +10,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
10
10
  import { h, Transition, computed, defineComponent, inject, withDirectives, vShow, ref, nextTick } from 'vue';
11
11
  import { useTheme } from '../../_mixins';
12
12
  import { loadingBarLight } from '../styles';
13
- import { loadingBarProviderInjectionKey } from './LoadingBarProvider';
13
+ import { loadingBarProviderInjectionKey } from './context';
14
14
  import style from './styles/index.cssr';
15
15
  function createClassName(status, clsPrefix) {
16
16
  return `${clsPrefix}-loading-bar ${clsPrefix}-loading-bar--${status}`;
@@ -110,7 +110,7 @@ export default defineComponent({
110
110
  yield init();
111
111
  });
112
112
  }
113
- const themeRef = useTheme('LoadingBar', 'LoadingBar', style, loadingBarLight, providerProps, mergedClsPrefixRef);
113
+ const themeRef = useTheme('LoadingBar', '-loading-bar', style, loadingBarLight, providerProps, mergedClsPrefixRef);
114
114
  return {
115
115
  mergedClsPrefix: mergedClsPrefixRef,
116
116
  loadingBarRef,
@@ -1,6 +1,6 @@
1
- import { PropType, ExtractPropTypes, Ref, CSSProperties } from 'vue';
1
+ import { PropType, ExtractPropTypes, CSSProperties } from 'vue';
2
2
  import { ExtractPublicPropTypes } from '../../_utils';
3
- interface LoadingBarInst {
3
+ export interface LoadingBarInst {
4
4
  start: () => void;
5
5
  error: () => void;
6
6
  finish: () => void;
@@ -36,11 +36,6 @@ declare const loadingBarProps: {
36
36
  };
37
37
  export declare type LoadingBarProviderProps = ExtractPublicPropTypes<typeof loadingBarProps>;
38
38
  export declare type LoadingBarProviderSetupProps = ExtractPropTypes<typeof loadingBarProps>;
39
- export declare const loadingBarProviderInjectionKey: import("vue").InjectionKey<{
40
- props: LoadingBarProviderSetupProps;
41
- mergedClsPrefixRef: Ref<string>;
42
- }>;
43
- export declare const loadingBarApiInjectionKey: import("vue").InjectionKey<LoadingBarInst>;
44
39
  declare const _default: import("vue").DefineComponent<{
45
40
  to: {
46
41
  type: PropType<string | HTMLElement>;
@@ -68,7 +63,7 @@ declare const _default: import("vue").DefineComponent<{
68
63
  height: string;
69
64
  }, any>>>;
70
65
  }, LoadingBarInst & {
71
- loadingBarRef: Ref<{
66
+ loadingBarRef: import("vue").Ref<{
72
67
  start: () => void;
73
68
  error: () => void;
74
69
  finish: () => void;
@@ -2,15 +2,13 @@ import { Fragment, h, ref, Teleport, defineComponent, provide, nextTick } from '
2
2
  import { useIsMounted } from 'vooks';
3
3
  import { useConfig, useTheme } from '../../_mixins';
4
4
  import NLoadingBar from './LoadingBar';
5
- import { createInjectionKey } from '../../_utils';
5
+ import { loadingBarApiInjectionKey, loadingBarProviderInjectionKey } from './context';
6
6
  const loadingBarProps = Object.assign(Object.assign({}, useTheme.props), { to: {
7
7
  type: [String, Object],
8
8
  default: undefined
9
9
  }, loadingBarStyle: {
10
10
  type: Object
11
11
  } });
12
- export const loadingBarProviderInjectionKey = createInjectionKey('n-loading-bar');
13
- export const loadingBarApiInjectionKey = createInjectionKey('n-loading-bar-api');
14
12
  export default defineComponent({
15
13
  name: 'LoadingBarProvider',
16
14
  props: loadingBarProps,
@@ -0,0 +1,7 @@
1
+ import { Ref } from 'vue';
2
+ import type { LoadingBarProviderSetupProps } from './LoadingBarProvider';
3
+ export declare const loadingBarProviderInjectionKey: import("vue").InjectionKey<{
4
+ props: LoadingBarProviderSetupProps;
5
+ mergedClsPrefixRef: Ref<string>;
6
+ }>;
7
+ export declare const loadingBarApiInjectionKey: import("vue").InjectionKey<import("./LoadingBarProvider").LoadingBarInst>;
@@ -0,0 +1,3 @@
1
+ import { createInjectionKey } from '../../_utils';
2
+ export const loadingBarProviderInjectionKey = createInjectionKey('n-loading-bar');
3
+ export const loadingBarApiInjectionKey = createInjectionKey('n-loading-bar-api');
@@ -1,5 +1,5 @@
1
1
  import { inject } from 'vue';
2
- import { loadingBarApiInjectionKey } from './LoadingBarProvider';
2
+ import { loadingBarApiInjectionKey } from './context';
3
3
  import { throwError } from '../../_utils';
4
4
  export function useLoadingBar() {
5
5
  const loadingBar = inject(loadingBarApiInjectionKey, null);
@@ -15,8 +15,8 @@ const deDE = {
15
15
  loadingRequiredMessage: (label) => `Bitte laden Sie alle Unterpunkte von ${label}, bevor Sie es auswählen.`
16
16
  },
17
17
  Time: {
18
- dateFormat: 'dd-MM-yyyy',
19
- dateTimeFormat: 'dd-MM-yyyy HH:mm:ss'
18
+ dateFormat: 'dd.MM.yyyy',
19
+ dateTimeFormat: 'dd.MM.yyyy HH:mm:ss'
20
20
  },
21
21
  DatePicker: {
22
22
  yearFormat: 'yyyy',
@@ -24,8 +24,8 @@ const deDE = {
24
24
  dayFormat: 'eeeeee',
25
25
  yearTypeFormat: 'yyyy',
26
26
  monthTypeFormat: 'MM-yyyy',
27
- dateFormat: 'dd-MM-yyyy',
28
- dateTimeFormat: 'dd-MM-yyyy HH:mm:ss',
27
+ dateFormat: 'dd.MM.yyyy',
28
+ dateTimeFormat: 'dd.MM.yyyy HH:mm:ss',
29
29
  quarterFormat: 'yyyy-qqq',
30
30
  clear: 'Löschen',
31
31
  now: 'Jetzt',
@@ -35,9 +35,8 @@ const deDE = {
35
35
  datePlaceholder: 'Datum auswählen',
36
36
  datetimePlaceholder: 'Datum und Uhrzeit auswählen',
37
37
  monthPlaceholder: 'Monat auswählen',
38
- // FIXME: translation needed
39
- yearPlaceholder: 'Select Year',
40
- quarterPlaceholder: 'Select Quarter',
38
+ yearPlaceholder: 'Jahr auswählen',
39
+ quarterPlaceholder: 'Quartal auswählen',
41
40
  startDatePlaceholder: 'Anfangsdatum',
42
41
  endDatePlaceholder: 'Enddatum',
43
42
  startDatetimePlaceholder: 'Anfangsdatum und Uhrzeit',
@@ -97,15 +96,14 @@ const deDE = {
97
96
  export: 'Exportieren',
98
97
  restore: 'Auf Standard zurücksetzen'
99
98
  },
100
- // TODO: translation
101
99
  Image: {
102
- tipPrevious: 'Previous picture (←)',
103
- tipNext: 'Next picture (→)',
104
- tipCounterclockwise: 'Counterclockwise',
105
- tipClockwise: 'Clockwise',
106
- tipZoomOut: 'Zoom out',
107
- tipZoomIn: 'Zoom in',
108
- tipClose: 'Close (Esc)'
100
+ tipPrevious: 'Vorheriges Bild (←)',
101
+ tipNext: 'Nächstes Bild (→)',
102
+ tipCounterclockwise: 'Gegen Uhrzeigersinn',
103
+ tipClockwise: 'Uhrzeigersinn',
104
+ tipZoomOut: 'Rauszoomen',
105
+ tipZoomIn: 'Reinzoomen',
106
+ tipClose: 'Schließen (Esc)'
109
107
  }
110
108
  };
111
109
  export default deDE;
@@ -0,0 +1,109 @@
1
+ declare const enGB: {
2
+ name: string;
3
+ global: {
4
+ undo: string;
5
+ redo: string;
6
+ confirm: string;
7
+ };
8
+ Popconfirm: {
9
+ positiveText: string;
10
+ negativeText: string;
11
+ };
12
+ Cascader: {
13
+ placeholder: string;
14
+ loading: string;
15
+ loadingRequiredMessage: (label: string) => string;
16
+ };
17
+ Time: {
18
+ dateFormat: string;
19
+ dateTimeFormat: string;
20
+ };
21
+ DatePicker: {
22
+ yearFormat: string;
23
+ monthFormat: string;
24
+ dayFormat: string;
25
+ yearTypeFormat: string;
26
+ monthTypeFormat: string;
27
+ dateFormat: string;
28
+ dateTimeFormat: string;
29
+ quarterFormat: string;
30
+ clear: string;
31
+ now: string;
32
+ confirm: string;
33
+ selectTime: string;
34
+ selectDate: string;
35
+ datePlaceholder: string;
36
+ datetimePlaceholder: string;
37
+ monthPlaceholder: string;
38
+ yearPlaceholder: string;
39
+ quarterPlaceholder: string;
40
+ startDatePlaceholder: string;
41
+ endDatePlaceholder: string;
42
+ startDatetimePlaceholder: string;
43
+ endDatetimePlaceholder: string;
44
+ monthBeforeYear: boolean;
45
+ firstDayOfWeek: 0 | 2 | 1 | 3 | 4 | 5 | 6;
46
+ today: string;
47
+ };
48
+ DataTable: {
49
+ checkTableAll: string;
50
+ uncheckTableAll: string;
51
+ confirm: string;
52
+ clear: string;
53
+ };
54
+ Transfer: {
55
+ sourceTitle: string;
56
+ targetTitle: string;
57
+ };
58
+ Empty: {
59
+ description: string;
60
+ };
61
+ Select: {
62
+ placeholder: string;
63
+ };
64
+ TimePicker: {
65
+ placeholder: string;
66
+ positiveText: string;
67
+ negativeText: string;
68
+ now: string;
69
+ };
70
+ Pagination: {
71
+ goto: string;
72
+ selectionSuffix: string;
73
+ };
74
+ DynamicTags: {
75
+ add: string;
76
+ };
77
+ Log: {
78
+ loading: string;
79
+ };
80
+ Input: {
81
+ placeholder: string;
82
+ };
83
+ InputNumber: {
84
+ placeholder: string;
85
+ };
86
+ DynamicInput: {
87
+ create: string;
88
+ };
89
+ ThemeEditor: {
90
+ title: string;
91
+ clearAllVars: string;
92
+ clearSearch: string;
93
+ filterCompName: string;
94
+ filterVarName: string;
95
+ import: string;
96
+ export: string;
97
+ restore: string;
98
+ };
99
+ Image: {
100
+ tipPrevious: string;
101
+ tipNext: string;
102
+ tipCounterclockwise: string;
103
+ tipClockwise: string;
104
+ tipZoomOut: string;
105
+ tipZoomIn: string;
106
+ tipClose: string;
107
+ };
108
+ };
109
+ export default enGB;
@@ -0,0 +1,109 @@
1
+ const enGB = {
2
+ name: 'en-GB',
3
+ global: {
4
+ undo: 'Undo',
5
+ redo: 'Redo',
6
+ confirm: 'Confirm'
7
+ },
8
+ Popconfirm: {
9
+ positiveText: 'Confirm',
10
+ negativeText: 'Cancel'
11
+ },
12
+ Cascader: {
13
+ placeholder: 'Please Select',
14
+ loading: 'Loading',
15
+ loadingRequiredMessage: (label) => `Please load all ${label}'s descendants before checking it.`
16
+ },
17
+ Time: {
18
+ dateFormat: 'yyyy/MM/dd',
19
+ dateTimeFormat: 'yyyy/MM/dd HH:mm:ss'
20
+ },
21
+ DatePicker: {
22
+ yearFormat: 'yyyy',
23
+ monthFormat: 'MMM',
24
+ dayFormat: 'eeeeee',
25
+ yearTypeFormat: 'yyyy',
26
+ monthTypeFormat: 'yyyy/MM',
27
+ dateFormat: 'yyyy/MM/dd',
28
+ dateTimeFormat: 'yyyy/MM/dd HH:mm:ss',
29
+ quarterFormat: 'yyyy-qqq',
30
+ clear: 'Clear',
31
+ now: 'Now',
32
+ confirm: 'Confirm',
33
+ selectTime: 'Select Time',
34
+ selectDate: 'Select Date',
35
+ datePlaceholder: 'Select Date',
36
+ datetimePlaceholder: 'Select Date and Time',
37
+ monthPlaceholder: 'Select Month',
38
+ yearPlaceholder: 'Select Year',
39
+ quarterPlaceholder: 'Select Quarter',
40
+ startDatePlaceholder: 'Start Date',
41
+ endDatePlaceholder: 'End Date',
42
+ startDatetimePlaceholder: 'Start Date and Time',
43
+ endDatetimePlaceholder: 'End Date and Time',
44
+ monthBeforeYear: true,
45
+ firstDayOfWeek: 0,
46
+ today: 'Today'
47
+ },
48
+ DataTable: {
49
+ checkTableAll: 'Select all in the table',
50
+ uncheckTableAll: 'Unselect all in the table',
51
+ confirm: 'Confirm',
52
+ clear: 'Clear'
53
+ },
54
+ Transfer: {
55
+ sourceTitle: 'Source',
56
+ targetTitle: 'Target'
57
+ },
58
+ Empty: {
59
+ description: 'No Data'
60
+ },
61
+ Select: {
62
+ placeholder: 'Please Select'
63
+ },
64
+ TimePicker: {
65
+ placeholder: 'Select Time',
66
+ positiveText: 'OK',
67
+ negativeText: 'Cancel',
68
+ now: 'Now'
69
+ },
70
+ Pagination: {
71
+ goto: 'Goto',
72
+ selectionSuffix: 'page'
73
+ },
74
+ DynamicTags: {
75
+ add: 'Add'
76
+ },
77
+ Log: {
78
+ loading: 'Loading'
79
+ },
80
+ Input: {
81
+ placeholder: 'Please Input'
82
+ },
83
+ InputNumber: {
84
+ placeholder: 'Please Input'
85
+ },
86
+ DynamicInput: {
87
+ create: 'Create'
88
+ },
89
+ ThemeEditor: {
90
+ title: 'Theme Editor',
91
+ clearAllVars: 'Clear All Variables',
92
+ clearSearch: 'Clear Search',
93
+ filterCompName: 'Filter Component Name',
94
+ filterVarName: 'Filter Variable Name',
95
+ import: 'Import',
96
+ export: 'Export',
97
+ restore: 'Reset to Default'
98
+ },
99
+ Image: {
100
+ tipPrevious: 'Previous picture (←)',
101
+ tipNext: 'Next picture (→)',
102
+ tipCounterclockwise: 'Counterclockwise',
103
+ tipClockwise: 'Clockwise',
104
+ tipZoomOut: 'Zoom out',
105
+ tipZoomIn: 'Zoom in',
106
+ tipClose: 'Close (Esc)'
107
+ }
108
+ };
109
+ export default enGB;