@uzum-tech/ui 1.3.1 → 1.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (759) hide show
  1. package/dist/index.js +83297 -64805
  2. package/dist/index.prod.js +12 -2
  3. package/es/__mocks__/vueuse-core.d.ts +5 -0
  4. package/es/__mocks__/vueuse-core.js +9 -0
  5. package/es/_internal/checkbox/src/use-checkbox.d.ts +4 -4
  6. package/es/_internal/close/src/Close.d.ts +2 -2
  7. package/es/_internal/fade-in-expand-transition/src/FadeInExpandTransition.d.ts +3 -3
  8. package/es/_internal/icons/ContentCopy.d.ts +2 -0
  9. package/es/_internal/icons/ContentCopy.js +8 -0
  10. package/es/_internal/icons/FileHeart.d.ts +2 -0
  11. package/es/_internal/icons/FileHeart.js +8 -0
  12. package/es/_internal/icons/SiderUnionBorder.d.ts +2 -0
  13. package/es/_internal/icons/SiderUnionBorder.js +8 -0
  14. package/es/_internal/icons/index.d.ts +3 -0
  15. package/es/_internal/icons/index.js +3 -0
  16. package/es/_internal/loading/src/Loading.d.ts +2 -2
  17. package/es/_internal/menu-mask/src/MenuMask.d.ts +1 -1
  18. package/es/_internal/radio/src/use-radio.d.ts +2 -2
  19. package/es/_internal/select-menu/src/SelectGroupHeader.d.ts +2 -2
  20. package/es/_internal/select-menu/src/SelectMenu.d.ts +83 -152
  21. package/es/_internal/select-menu/src/SelectOption.d.ts +2 -2
  22. package/es/_internal/select-menu/styles/light.d.ts +11 -5
  23. package/es/_internal/selection/src/Selection.d.ts +13 -124
  24. package/es/_internal/skeleton/src/Skeleton.d.ts +1 -1
  25. package/es/_utils/composable/use-adjusted-to.d.ts +1 -1
  26. package/es/_utils/cssr/index.d.ts +1 -1
  27. package/es/_utils/debounce/index.d.ts +1 -0
  28. package/es/_utils/debounce/index.js +10 -0
  29. package/es/_utils/inject/index.d.ts +1 -1
  30. package/es/_utils/vue/render.d.ts +1 -1
  31. package/es/affix/src/Affix.d.ts +4 -4
  32. package/es/alert/src/Alert.d.ts +8 -120
  33. package/es/anchor/src/AnchorAdapter.d.ts +4 -4
  34. package/es/anchor/src/BaseAnchor.d.ts +2 -2
  35. package/es/auto-complete/src/AutoComplete.d.ts +130 -175
  36. package/es/auto-complete/styles/light.d.ts +11 -5
  37. package/es/avatar/src/Avatar.d.ts +3 -3
  38. package/es/avatar-group/src/AvatarGroup.d.ts +6 -117
  39. package/es/back-top/src/BackTop.d.ts +4 -4
  40. package/es/badge/src/Badge.d.ts +7 -7
  41. package/es/button/src/Button.d.ts +14 -14
  42. package/es/calendar/src/Calendar.d.ts +3 -114
  43. package/es/card/src/Card.d.ts +19 -130
  44. package/es/card-list/index.d.ts +2 -0
  45. package/es/card-list/index.js +1 -0
  46. package/es/card-list/src/CardList.d.ts +259 -0
  47. package/es/card-list/src/CardList.js +69 -0
  48. package/es/card-list/src/CardListItem.d.ts +70 -0
  49. package/es/card-list/src/CardListItem.js +112 -0
  50. package/es/card-list/src/interface.d.ts +12 -0
  51. package/es/card-list/src/interface.js +1 -0
  52. package/es/card-list/src/styles/index.cssr.d.ts +2 -0
  53. package/es/card-list/src/styles/index.cssr.js +101 -0
  54. package/es/card-list/styles/dark.d.ts +3 -0
  55. package/es/card-list/styles/dark.js +8 -0
  56. package/es/card-list/styles/index.d.ts +3 -0
  57. package/es/card-list/styles/index.js +2 -0
  58. package/es/card-list/styles/light.d.ts +22 -0
  59. package/es/card-list/styles/light.js +26 -0
  60. package/es/carousel/src/Carousel.d.ts +23 -25
  61. package/es/carousel/src/CarouselDots.d.ts +5 -5
  62. package/es/cascader/src/Cascader.d.ts +246 -231
  63. package/es/cascader/src/CascaderMenu.d.ts +36 -129
  64. package/es/cascader/src/CascaderOption.d.ts +34 -127
  65. package/es/cascader/src/CascaderSelectMenu.d.ts +35 -128
  66. package/es/cascader/src/CascaderSubmenu.d.ts +34 -127
  67. package/es/cascader/styles/light.d.ts +22 -10
  68. package/es/checkbox/src/Checkbox.d.ts +18 -129
  69. package/es/checkbox/src/CheckboxGroup.d.ts +14 -14
  70. package/es/code/src/Code.d.ts +1 -1
  71. package/es/collapse/src/Collapse.d.ts +10 -121
  72. package/es/collapse/src/CollapseItem.d.ts +3 -3
  73. package/es/collapse/src/CollapseItemContent.d.ts +2 -2
  74. package/es/collapse-transition/src/CollapseTransition.d.ts +1 -1
  75. package/es/color-picker/src/ColorInput.d.ts +2 -2
  76. package/es/color-picker/src/ColorInputUnit.d.ts +3 -114
  77. package/es/color-picker/src/ColorPicker.d.ts +7 -7
  78. package/es/components.d.ts +1 -0
  79. package/es/components.js +1 -0
  80. package/es/config-provider/src/ConfigProvider.d.ts +10 -366
  81. package/es/config-provider/src/config.js +5 -5
  82. package/es/config-provider/src/internal-interface.d.ts +3 -1
  83. package/es/countdown/src/Countdown.d.ts +4 -4
  84. package/es/data-table/src/DataTable.d.ts +308 -255
  85. package/es/data-table/src/DataTable.js +153 -5
  86. package/es/data-table/src/HeaderButton/FilterButton.d.ts +59 -137
  87. package/es/data-table/src/HeaderButton/FilterMenu.d.ts +62 -140
  88. package/es/data-table/src/HeaderButton/RenderFilter.d.ts +1 -1
  89. package/es/data-table/src/MainTable.d.ts +4 -1
  90. package/es/data-table/src/MainTable.js +6 -4
  91. package/es/data-table/src/TableParts/Body.d.ts +68 -142
  92. package/es/data-table/src/TableParts/Body.js +27 -7
  93. package/es/data-table/src/TableParts/Cell.d.ts +8 -2828
  94. package/es/data-table/src/TableParts/Cell.js +64 -6
  95. package/es/data-table/src/TableParts/ExpandTrigger.d.ts +1 -1
  96. package/es/data-table/src/TableParts/Header.d.ts +60 -138
  97. package/es/data-table/src/TableParts/Header.js +7 -5
  98. package/es/data-table/src/interface.d.ts +135 -53
  99. package/es/data-table/src/styles/index.cssr.js +25 -1
  100. package/es/data-table/src/use-check.d.ts +1 -1
  101. package/es/data-table/src/use-expand.d.ts +1 -1
  102. package/es/data-table/src/use-group-header.js +4 -0
  103. package/es/data-table/src/use-mask.d.ts +10 -0
  104. package/es/data-table/src/use-mask.js +58 -0
  105. package/es/data-table/src/utils.d.ts +4 -0
  106. package/es/data-table/src/utils.js +4 -0
  107. package/es/data-table/styles/light.d.ts +39 -15
  108. package/es/data-table/styles/light.js +4 -1
  109. package/es/date-picker/src/DatePicker.d.ts +14 -125
  110. package/es/date-picker/src/panel/date.d.ts +6 -129
  111. package/es/date-picker/src/panel/daterange.d.ts +7 -118
  112. package/es/date-picker/src/panel/datetime.d.ts +6 -117
  113. package/es/date-picker/src/panel/datetimerange.d.ts +7 -118
  114. package/es/date-picker/src/panel/panelMonth.d.ts +41 -299
  115. package/es/date-picker/src/panel/panelMonthContent.d.ts +6 -123
  116. package/es/date-picker/src/panel/panelYear.d.ts +41 -299
  117. package/es/date-picker/src/panel/panelYearContent.d.ts +6 -135
  118. package/es/date-picker/src/panel/use-calendar.d.ts +3 -114
  119. package/es/date-picker/src/panel/use-dual-calendar.d.ts +8 -119
  120. package/es/date-picker/src/panel/use-panel-common.d.ts +2 -113
  121. package/es/date-picker/styles/_common.js +1 -1
  122. package/es/descriptions/src/Descriptions.d.ts +2 -2
  123. package/es/dialog/src/Dialog.d.ts +4 -115
  124. package/es/dialog/src/Dialog.js +1 -1
  125. package/es/dialog/src/DialogEnvironment.d.ts +5 -5
  126. package/es/dialog/src/DialogProvider.d.ts +40 -40
  127. package/es/dialog/src/dialogProps.d.ts +2 -2
  128. package/es/divider/src/Divider.d.ts +4 -4
  129. package/es/drawer/src/Drawer.d.ts +21 -119
  130. package/es/drawer/src/Drawer.js +4 -1
  131. package/es/drawer/src/DrawerBodyWrapper.d.ts +12 -114
  132. package/es/drawer/src/DrawerBodyWrapper.js +6 -0
  133. package/es/drawer/src/DrawerContent.d.ts +1 -112
  134. package/es/drawer/src/styles/index.cssr.js +3 -2
  135. package/es/drawer/styles/_common.js +2 -2
  136. package/es/dropdown/src/Dropdown.d.ts +31 -142
  137. package/es/dropdown/src/DropdownGroup.d.ts +3 -2
  138. package/es/dropdown/src/DropdownMenu.d.ts +3 -2
  139. package/es/dropdown/src/DropdownOption.d.ts +4 -3
  140. package/es/dropdown/src/DropdownRenderOption.d.ts +3 -2
  141. package/es/dynamic-input/src/DynamicInput.d.ts +3 -114
  142. package/es/dynamic-input/src/InputPreset.d.ts +1 -112
  143. package/es/dynamic-input/src/PairPreset.d.ts +1 -112
  144. package/es/dynamic-tags/src/DynamicTags.d.ts +14 -125
  145. package/es/ellipsis/src/Ellipsis.d.ts +4 -115
  146. package/es/ellipsis/src/PerformantEllipsis.d.ts +2 -2
  147. package/es/empty/src/Empty.d.ts +109 -48
  148. package/es/empty/src/Empty.js +27 -9
  149. package/es/empty/src/styles/index.cssr.js +38 -11
  150. package/es/empty/styles/light.d.ts +11 -5
  151. package/es/empty/styles/light.js +17 -11
  152. package/es/equation/src/Equation.d.ts +4 -3
  153. package/es/flex/src/Flex.d.ts +13 -12
  154. package/es/form/src/Form.d.ts +4 -4
  155. package/es/form/src/Form.js +2 -2
  156. package/es/form/src/FormItem.d.ts +23 -10
  157. package/es/form/src/FormItem.js +20 -7
  158. package/es/form/src/FormItemCol.d.ts +22 -9
  159. package/es/form/src/FormItemGridItem.d.ts +24 -11
  160. package/es/form/src/FormItemRow.d.ts +21 -8
  161. package/es/form/src/utils.d.ts +3 -2
  162. package/es/form/src/utils.js +16 -0
  163. package/es/gradient-text/src/GradientText.d.ts +5 -5
  164. package/es/grid/src/Grid.d.ts +18 -18
  165. package/es/grid/src/GridItem.d.ts +2 -2
  166. package/es/icon/src/Icon.d.ts +3 -3
  167. package/es/icon-wrapper/src/IconWrapper.d.ts +1 -1
  168. package/es/image/src/Image.d.ts +5 -5
  169. package/es/image/src/ImageGroup.d.ts +1 -1
  170. package/es/image/src/ImagePreview.d.ts +1 -1
  171. package/es/input/src/Input.d.ts +79 -155
  172. package/es/input/src/Input.js +54 -17
  173. package/es/input/src/InputGroupLabel.d.ts +1 -1
  174. package/es/input/src/use-clipboard.d.ts +9 -0
  175. package/es/input/src/use-clipboard.js +47 -0
  176. package/es/input-number/src/InputNumber.d.ts +14 -125
  177. package/es/layout/src/Layout.d.ts +4 -226
  178. package/es/layout/src/LayoutContent.d.ts +2 -113
  179. package/es/layout/src/LayoutFooter.d.ts +1 -1
  180. package/es/layout/src/LayoutHeader.d.ts +2 -2
  181. package/es/layout/src/LayoutHeader.js +5 -1
  182. package/es/layout/src/LayoutSider.d.ts +10 -121
  183. package/es/layout/src/LayoutSider.js +3 -3
  184. package/es/layout/src/ToggleSidebarButton.d.ts +15 -0
  185. package/es/layout/src/ToggleSidebarButton.js +23 -0
  186. package/es/layout/src/interface.d.ts +1 -1
  187. package/es/layout/src/styles/layout-header.cssr.js +4 -1
  188. package/es/layout/src/styles/layout-sider.cssr.js +64 -6
  189. package/es/layout/src/utils/resolveTriggerComponent.d.ts +51 -0
  190. package/es/layout/src/utils/resolveTriggerComponent.js +13 -0
  191. package/es/legacy-transfer/src/Transfer.d.ts +112 -163
  192. package/es/legacy-transfer/src/TransferFilter.d.ts +12 -117
  193. package/es/legacy-transfer/src/TransferList.d.ts +12 -117
  194. package/es/legacy-transfer/src/TransferListItem.d.ts +13 -118
  195. package/es/legacy-transfer/styles/light.d.ts +11 -5
  196. package/es/list/src/List.d.ts +6 -6
  197. package/es/list/src/ListItem.d.ts +5 -5
  198. package/es/loading-bar/src/LoadingBar.d.ts +1 -1
  199. package/es/loading-bar/src/LoadingBar.js +2 -2
  200. package/es/loading-bar/src/LoadingBarProvider.d.ts +9 -9
  201. package/es/locales/common/arDZ.js +9 -2
  202. package/es/locales/common/deDE.js +9 -2
  203. package/es/locales/common/enGB.js +9 -2
  204. package/es/locales/common/enUS.d.ts +8 -1
  205. package/es/locales/common/enUS.js +9 -2
  206. package/es/locales/common/eo.js +9 -2
  207. package/es/locales/common/esAR.js +9 -2
  208. package/es/locales/common/faIR.js +9 -2
  209. package/es/locales/common/frFR.js +9 -2
  210. package/es/locales/common/idID.js +9 -2
  211. package/es/locales/common/itIT.js +9 -2
  212. package/es/locales/common/jaJP.js +9 -2
  213. package/es/locales/common/koKR.js +9 -2
  214. package/es/locales/common/nbNO.js +9 -2
  215. package/es/locales/common/nlNL.js +9 -2
  216. package/es/locales/common/plPL.js +9 -2
  217. package/es/locales/common/ptBR.js +9 -2
  218. package/es/locales/common/ruRU.js +9 -2
  219. package/es/locales/common/skSK.js +9 -2
  220. package/es/locales/common/svSE.js +9 -2
  221. package/es/locales/common/thTH.js +9 -2
  222. package/es/locales/common/trTR.js +9 -2
  223. package/es/locales/common/ukUA.js +9 -2
  224. package/es/locales/common/viVN.js +9 -2
  225. package/es/locales/common/zhCN.js +9 -2
  226. package/es/locales/common/zhTW.js +9 -2
  227. package/es/log/src/Log.d.ts +8 -120
  228. package/es/mention/src/Mention.d.ts +140 -185
  229. package/es/mention/src/utils.js +4 -4
  230. package/es/mention/styles/light.d.ts +11 -5
  231. package/es/menu/src/Menu.d.ts +16 -127
  232. package/es/menu/src/MenuOption.d.ts +2 -113
  233. package/es/menu/src/MenuOptionGroup.d.ts +1 -1
  234. package/es/menu/src/Submenu.d.ts +2 -113
  235. package/es/message/src/Message.d.ts +1 -1
  236. package/es/message/src/MessageEnvironment.d.ts +1 -1
  237. package/es/message/src/MessageProvider.d.ts +5 -5
  238. package/es/modal/src/BodyWrapper.d.ts +8 -119
  239. package/es/modal/src/Modal.d.ts +17 -17
  240. package/es/modal/src/presetProps.d.ts +2 -2
  241. package/es/notification/src/Notification.d.ts +5 -5
  242. package/es/notification/src/NotificationContainer.d.ts +1 -112
  243. package/es/notification/src/NotificationEnvironment.d.ts +4 -4
  244. package/es/notification/src/NotificationProvider.d.ts +17 -17
  245. package/es/number-animation/src/NumberAnimation.d.ts +1 -1
  246. package/es/pagination/src/Pagination.d.ts +263 -242
  247. package/es/pagination/styles/light.d.ts +22 -10
  248. package/es/popconfirm/src/Popconfirm.d.ts +29 -140
  249. package/es/popconfirm/src/PopconfirmPanel.d.ts +1 -1
  250. package/es/popover/src/Popover.d.ts +30 -30
  251. package/es/popover/src/PopoverBody.d.ts +19 -19
  252. package/es/popselect/src/Popselect.d.ts +195 -240
  253. package/es/popselect/src/PopselectPanel.d.ts +26 -125
  254. package/es/popselect/styles/light.d.ts +11 -5
  255. package/es/preset.d.ts +1 -1
  256. package/es/progress/src/Line.d.ts +1 -1
  257. package/es/progress/src/MultipleCircle.d.ts +2 -2
  258. package/es/progress/src/Progress.d.ts +6 -6
  259. package/es/radio/src/Radio.d.ts +10 -10
  260. package/es/radio/src/RadioButton.d.ts +6 -6
  261. package/es/rate/src/Rate.d.ts +1 -1
  262. package/es/result/src/Result.d.ts +4 -4
  263. package/es/select/src/Select.d.ts +141 -186
  264. package/es/select/styles/light.d.ts +11 -5
  265. package/es/skeleton/src/Skeleton.d.ts +1 -1
  266. package/es/slider/src/Slider.d.ts +9 -9
  267. package/es/space/src/Space.d.ts +5 -5
  268. package/es/spin/src/Spin.d.ts +8 -8
  269. package/es/styles.d.ts +1 -0
  270. package/es/styles.js +1 -0
  271. package/es/switch/src/Switch.d.ts +11 -11
  272. package/es/table/src/Table.d.ts +1 -1
  273. package/es/tabs/src/Tab.d.ts +10 -22
  274. package/es/tabs/src/TabPane.d.ts +9 -21
  275. package/es/tabs/src/Tabs.d.ts +29 -30
  276. package/es/tag/src/Tag.d.ts +11 -11
  277. package/es/tag/src/common-props.d.ts +2 -2
  278. package/es/themes/dark.js +2 -0
  279. package/es/themes/light.js +2 -0
  280. package/es/time/src/Time.d.ts +2 -2
  281. package/es/time-picker/src/Panel.d.ts +3 -114
  282. package/es/time-picker/src/PanelCol.d.ts +4 -4
  283. package/es/time-picker/src/TimePicker.d.ts +17 -128
  284. package/es/timeline/src/TimelineItem.d.ts +4 -4
  285. package/es/toggle-button/src/ToggleButton.d.ts +12 -12
  286. package/es/tooltip/src/Tooltip.d.ts +25 -136
  287. package/es/transfer/src/Transfer.d.ts +112 -163
  288. package/es/transfer/src/TransferFilter.d.ts +12 -117
  289. package/es/transfer/src/TransferList.d.ts +12 -117
  290. package/es/transfer/src/TransferListItem.d.ts +13 -118
  291. package/es/transfer/styles/light.d.ts +11 -5
  292. package/es/tree/src/MotionWrapper.d.ts +2 -2
  293. package/es/tree/src/Tree.d.ts +148 -199
  294. package/es/tree/src/TreeNodeCheckbox.d.ts +13 -118
  295. package/es/tree/src/TreeNodeContent.d.ts +1 -1
  296. package/es/tree/src/TreeNodeSwitcher.d.ts +3 -3
  297. package/es/tree/styles/light.d.ts +11 -5
  298. package/es/tree-select/src/TreeSelect.d.ts +269 -260
  299. package/es/tree-select/styles/light.d.ts +22 -10
  300. package/es/typography/src/create-header.d.ts +5 -5
  301. package/es/typography/src/headers.d.ts +18 -18
  302. package/es/typography/src/p.d.ts +3 -3
  303. package/es/typography/src/text.d.ts +6 -6
  304. package/es/upload/src/Upload.d.ts +137 -137
  305. package/es/upload/src/Upload.js +60 -188
  306. package/es/upload/src/UploadFile.d.ts +17 -115
  307. package/es/upload/src/UploadFile.js +57 -54
  308. package/es/upload/src/UploadFileList.js +2 -2
  309. package/es/upload/src/UploadProgress.d.ts +9 -114
  310. package/es/upload/src/UploadTrigger.js +20 -7
  311. package/es/upload/src/interface.d.ts +42 -0
  312. package/es/upload/src/styles/index.cssr.js +159 -34
  313. package/es/upload/src/useUpload.d.ts +2 -0
  314. package/es/upload/src/useUpload.js +163 -0
  315. package/es/upload/src/useUploadActionsRender.d.ts +26 -0
  316. package/es/upload/src/useUploadActionsRender.js +85 -0
  317. package/es/upload/src/useUploadInternals.d.ts +25 -0
  318. package/es/upload/src/useUploadInternals.js +37 -0
  319. package/es/upload/src/utils.d.ts +2 -1
  320. package/es/upload/src/utils.js +5 -0
  321. package/es/upload/styles/light.d.ts +12 -0
  322. package/es/upload/styles/light.js +8 -2
  323. package/es/version.d.ts +1 -1
  324. package/es/version.js +1 -1
  325. package/es/watermark/src/Watermark.d.ts +6 -6
  326. package/lib/__mocks__/vueuse-core.d.ts +5 -0
  327. package/lib/__mocks__/vueuse-core.js +9 -0
  328. package/lib/_internal/checkbox/src/use-checkbox.d.ts +4 -4
  329. package/lib/_internal/close/src/Close.d.ts +2 -2
  330. package/lib/_internal/fade-in-expand-transition/src/FadeInExpandTransition.d.ts +3 -3
  331. package/lib/_internal/icons/ContentCopy.d.ts +2 -0
  332. package/lib/_internal/icons/ContentCopy.js +10 -0
  333. package/lib/_internal/icons/FileHeart.d.ts +2 -0
  334. package/lib/_internal/icons/FileHeart.js +10 -0
  335. package/lib/_internal/icons/SiderUnionBorder.d.ts +2 -0
  336. package/lib/_internal/icons/SiderUnionBorder.js +10 -0
  337. package/lib/_internal/icons/index.d.ts +3 -0
  338. package/lib/_internal/icons/index.js +8 -1
  339. package/lib/_internal/icons/replaceable.js +1 -2
  340. package/lib/_internal/loading/src/Loading.d.ts +2 -2
  341. package/lib/_internal/menu-mask/src/MenuMask.d.ts +1 -1
  342. package/lib/_internal/radio/src/use-radio.d.ts +2 -2
  343. package/lib/_internal/radio/src/use-radio.js +2 -2
  344. package/lib/_internal/select-menu/src/SelectGroupHeader.d.ts +2 -2
  345. package/lib/_internal/select-menu/src/SelectMenu.d.ts +83 -152
  346. package/lib/_internal/select-menu/src/SelectOption.d.ts +2 -2
  347. package/lib/_internal/select-menu/styles/light.d.ts +11 -5
  348. package/lib/_internal/selection/src/Selection.d.ts +13 -124
  349. package/lib/_internal/skeleton/src/Skeleton.d.ts +1 -1
  350. package/lib/_mixins/use-config.js +3 -3
  351. package/lib/_mixins/use-css-vars-class.js +1 -2
  352. package/lib/_mixins/use-form-item.js +1 -1
  353. package/lib/_mixins/use-hljs.js +1 -1
  354. package/lib/_mixins/use-locale.js +1 -1
  355. package/lib/_mixins/use-rtl.js +1 -2
  356. package/lib/_mixins/use-style.js +1 -1
  357. package/lib/_mixins/use-theme.js +1 -2
  358. package/lib/_resolvers/auto-import/auto-import-resolver.js +1 -2
  359. package/lib/_styles/transitions/fade-down.cssr.js +2 -3
  360. package/lib/_styles/transitions/fade-in-height-expand.cssr.js +2 -3
  361. package/lib/_styles/transitions/fade-in-scale-up.cssr.js +2 -3
  362. package/lib/_styles/transitions/fade-in-width-expand.cssr.js +2 -3
  363. package/lib/_styles/transitions/fade-in.cssr.js +2 -3
  364. package/lib/_styles/transitions/fade-up-width-expand.cssr.js +2 -3
  365. package/lib/_styles/transitions/icon-switch.cssr.js +2 -3
  366. package/lib/_styles/transitions/slide-in-from-bottom.js +1 -2
  367. package/lib/_styles/transitions/slide-in-from-left.js +1 -2
  368. package/lib/_styles/transitions/slide-in-from-right.js +1 -2
  369. package/lib/_styles/transitions/slide-in-from-top.js +1 -2
  370. package/lib/_utils/color/index.js +3 -4
  371. package/lib/_utils/composable/use-adjusted-to.d.ts +1 -1
  372. package/lib/_utils/composable/use-adjusted-to.js +1 -2
  373. package/lib/_utils/composable/use-collection.js +3 -4
  374. package/lib/_utils/composable/use-deferred-true.js +1 -2
  375. package/lib/_utils/composable/use-houdini.js +1 -2
  376. package/lib/_utils/composable/use-lock-html-scroll.js +2 -2
  377. package/lib/_utils/composable/use-reactivated.js +1 -2
  378. package/lib/_utils/composable/use-resize.js +1 -2
  379. package/lib/_utils/css/color-to-class.js +1 -2
  380. package/lib/_utils/css/format-length.js +1 -2
  381. package/lib/_utils/cssr/create-key.js +1 -2
  382. package/lib/_utils/cssr/index.d.ts +1 -1
  383. package/lib/_utils/cssr/index.js +4 -4
  384. package/lib/_utils/debounce/index.d.ts +1 -0
  385. package/lib/_utils/debounce/index.js +13 -0
  386. package/lib/_utils/dom/is-document.js +1 -2
  387. package/lib/_utils/env/is-jsdom.js +1 -2
  388. package/lib/_utils/event/index.js +2 -3
  389. package/lib/_utils/inject/index.d.ts +1 -1
  390. package/lib/_utils/uzum/attribute.js +1 -2
  391. package/lib/_utils/uzum/prop.js +2 -3
  392. package/lib/_utils/uzum/warn.js +3 -4
  393. package/lib/_utils/vue/call.js +1 -2
  394. package/lib/_utils/vue/create-data-key.js +1 -2
  395. package/lib/_utils/vue/create-injection-key.js +1 -2
  396. package/lib/_utils/vue/create-ref-setter.js +1 -2
  397. package/lib/_utils/vue/flatten.js +1 -2
  398. package/lib/_utils/vue/get-first-slot-vnode.js +1 -2
  399. package/lib/_utils/vue/get-slot.js +1 -2
  400. package/lib/_utils/vue/get-v-node-children.js +1 -2
  401. package/lib/_utils/vue/is-node-v-show-false.js +1 -2
  402. package/lib/_utils/vue/keep.js +1 -2
  403. package/lib/_utils/vue/keysOf.js +1 -2
  404. package/lib/_utils/vue/merge-handlers.js +1 -2
  405. package/lib/_utils/vue/omit.js +1 -2
  406. package/lib/_utils/vue/render.d.ts +1 -1
  407. package/lib/_utils/vue/resolve-slot.js +5 -6
  408. package/lib/affix/src/Affix.d.ts +4 -4
  409. package/lib/affix/src/utils.js +2 -3
  410. package/lib/alert/src/Alert.d.ts +8 -120
  411. package/lib/anchor/src/AnchorAdapter.d.ts +4 -4
  412. package/lib/anchor/src/BaseAnchor.d.ts +2 -2
  413. package/lib/anchor/src/utils.js +1 -2
  414. package/lib/auto-complete/src/AutoComplete.d.ts +130 -175
  415. package/lib/auto-complete/src/utils.js +1 -2
  416. package/lib/auto-complete/styles/light.d.ts +11 -5
  417. package/lib/auto-complete/styles/light.js +1 -2
  418. package/lib/avatar/src/Avatar.d.ts +3 -3
  419. package/lib/avatar-group/src/AvatarGroup.d.ts +6 -117
  420. package/lib/back-top/src/BackTop.d.ts +4 -4
  421. package/lib/badge/src/Badge.d.ts +7 -7
  422. package/lib/button/src/Button.d.ts +14 -14
  423. package/lib/calendar/src/Calendar.d.ts +3 -114
  424. package/lib/card/src/Card.d.ts +19 -130
  425. package/lib/card-list/index.d.ts +2 -0
  426. package/lib/card-list/index.js +9 -0
  427. package/lib/card-list/src/CardList.d.ts +259 -0
  428. package/lib/card-list/src/CardList.js +75 -0
  429. package/lib/card-list/src/CardListItem.d.ts +70 -0
  430. package/lib/card-list/src/CardListItem.js +117 -0
  431. package/lib/card-list/src/interface.d.ts +12 -0
  432. package/lib/card-list/src/interface.js +2 -0
  433. package/lib/card-list/src/styles/index.cssr.d.ts +2 -0
  434. package/lib/card-list/src/styles/index.cssr.js +106 -0
  435. package/lib/card-list/styles/dark.d.ts +3 -0
  436. package/lib/card-list/styles/dark.js +10 -0
  437. package/lib/card-list/styles/index.d.ts +3 -0
  438. package/lib/card-list/styles/index.js +10 -0
  439. package/lib/card-list/styles/light.d.ts +22 -0
  440. package/lib/card-list/styles/light.js +30 -0
  441. package/lib/carousel/src/Carousel.d.ts +23 -25
  442. package/lib/carousel/src/CarouselDots.d.ts +5 -5
  443. package/lib/carousel/src/utils/duplicatedLogic.js +6 -7
  444. package/lib/carousel/src/utils/event.js +1 -2
  445. package/lib/carousel/src/utils/index.js +3 -4
  446. package/lib/cascader/src/Cascader.d.ts +246 -231
  447. package/lib/cascader/src/CascaderMenu.d.ts +36 -129
  448. package/lib/cascader/src/CascaderOption.d.ts +34 -127
  449. package/lib/cascader/src/CascaderSelectMenu.d.ts +35 -128
  450. package/lib/cascader/src/CascaderSubmenu.d.ts +34 -127
  451. package/lib/cascader/src/utils.js +3 -4
  452. package/lib/cascader/styles/light.d.ts +22 -10
  453. package/lib/checkbox/src/Checkbox.d.ts +18 -129
  454. package/lib/checkbox/src/CheckboxGroup.d.ts +14 -14
  455. package/lib/code/src/Code.d.ts +1 -1
  456. package/lib/collapse/src/Collapse.d.ts +10 -121
  457. package/lib/collapse/src/CollapseItem.d.ts +3 -3
  458. package/lib/collapse/src/CollapseItemContent.d.ts +2 -2
  459. package/lib/collapse-transition/src/CollapseTransition.d.ts +1 -1
  460. package/lib/color-picker/src/ColorInput.d.ts +2 -2
  461. package/lib/color-picker/src/ColorInputUnit.d.ts +3 -114
  462. package/lib/color-picker/src/ColorPicker.d.ts +7 -7
  463. package/lib/color-picker/src/utils.js +6 -7
  464. package/lib/components.d.ts +1 -0
  465. package/lib/components.js +1 -0
  466. package/lib/composables/use-theme-vars.js +1 -2
  467. package/lib/config-provider/src/ConfigProvider.d.ts +10 -366
  468. package/lib/config-provider/src/config.js +5 -5
  469. package/lib/config-provider/src/internal-interface.d.ts +3 -1
  470. package/lib/countdown/src/Countdown.d.ts +4 -4
  471. package/lib/data-table/src/DataTable.d.ts +308 -255
  472. package/lib/data-table/src/DataTable.js +153 -5
  473. package/lib/data-table/src/HeaderButton/FilterButton.d.ts +59 -137
  474. package/lib/data-table/src/HeaderButton/FilterMenu.d.ts +62 -140
  475. package/lib/data-table/src/HeaderButton/RenderFilter.d.ts +1 -1
  476. package/lib/data-table/src/MainTable.d.ts +4 -1
  477. package/lib/data-table/src/MainTable.js +6 -4
  478. package/lib/data-table/src/TableParts/Body.d.ts +68 -142
  479. package/lib/data-table/src/TableParts/Body.js +27 -7
  480. package/lib/data-table/src/TableParts/Cell.d.ts +8 -2828
  481. package/lib/data-table/src/TableParts/Cell.js +65 -7
  482. package/lib/data-table/src/TableParts/ExpandTrigger.d.ts +1 -1
  483. package/lib/data-table/src/TableParts/Header.d.ts +60 -138
  484. package/lib/data-table/src/TableParts/Header.js +7 -5
  485. package/lib/data-table/src/interface.d.ts +135 -53
  486. package/lib/data-table/src/styles/index.cssr.js +25 -1
  487. package/lib/data-table/src/use-check.d.ts +1 -1
  488. package/lib/data-table/src/use-check.js +1 -2
  489. package/lib/data-table/src/use-expand.d.ts +1 -1
  490. package/lib/data-table/src/use-expand.js +1 -2
  491. package/lib/data-table/src/use-group-header.js +5 -2
  492. package/lib/data-table/src/use-mask.d.ts +10 -0
  493. package/lib/data-table/src/use-mask.js +63 -0
  494. package/lib/data-table/src/use-resizable.js +1 -2
  495. package/lib/data-table/src/use-scroll.js +1 -2
  496. package/lib/data-table/src/use-sorter.js +1 -2
  497. package/lib/data-table/src/use-table-data.js +1 -2
  498. package/lib/data-table/src/utils.d.ts +4 -0
  499. package/lib/data-table/src/utils.js +19 -15
  500. package/lib/data-table/styles/light.d.ts +39 -15
  501. package/lib/data-table/styles/light.js +4 -1
  502. package/lib/date-picker/src/DatePicker.d.ts +14 -125
  503. package/lib/date-picker/src/panel/date.d.ts +6 -129
  504. package/lib/date-picker/src/panel/daterange.d.ts +7 -118
  505. package/lib/date-picker/src/panel/datetime.d.ts +6 -117
  506. package/lib/date-picker/src/panel/datetimerange.d.ts +7 -118
  507. package/lib/date-picker/src/panel/panelMonth.d.ts +41 -299
  508. package/lib/date-picker/src/panel/panelMonthContent.d.ts +6 -123
  509. package/lib/date-picker/src/panel/panelYear.d.ts +41 -299
  510. package/lib/date-picker/src/panel/panelYearContent.d.ts +6 -135
  511. package/lib/date-picker/src/panel/use-calendar.d.ts +3 -114
  512. package/lib/date-picker/src/panel/use-calendar.js +2 -2
  513. package/lib/date-picker/src/panel/use-dual-calendar.d.ts +8 -119
  514. package/lib/date-picker/src/panel/use-dual-calendar.js +2 -2
  515. package/lib/date-picker/src/panel/use-panel-common.d.ts +2 -113
  516. package/lib/date-picker/src/panel/use-panel-common.js +2 -2
  517. package/lib/date-picker/src/utils.js +9 -10
  518. package/lib/date-picker/src/validation-utils.js +2 -3
  519. package/lib/date-picker/styles/_common.js +1 -1
  520. package/lib/descriptions/src/Descriptions.d.ts +2 -2
  521. package/lib/descriptions/src/utils.js +2 -2
  522. package/lib/dialog/src/Dialog.d.ts +4 -115
  523. package/lib/dialog/src/Dialog.js +1 -1
  524. package/lib/dialog/src/DialogEnvironment.d.ts +5 -5
  525. package/lib/dialog/src/DialogProvider.d.ts +40 -40
  526. package/lib/dialog/src/composables.js +2 -3
  527. package/lib/dialog/src/dialogProps.d.ts +2 -2
  528. package/lib/discrete/src/discrete.js +1 -2
  529. package/lib/discrete/src/discreteApp.js +1 -2
  530. package/lib/divider/src/Divider.d.ts +4 -4
  531. package/lib/drawer/src/Drawer.d.ts +21 -119
  532. package/lib/drawer/src/Drawer.js +4 -1
  533. package/lib/drawer/src/DrawerBodyWrapper.d.ts +12 -114
  534. package/lib/drawer/src/DrawerBodyWrapper.js +6 -0
  535. package/lib/drawer/src/DrawerContent.d.ts +1 -112
  536. package/lib/drawer/src/styles/index.cssr.js +3 -2
  537. package/lib/drawer/styles/_common.js +2 -2
  538. package/lib/dropdown/src/Dropdown.d.ts +31 -142
  539. package/lib/dropdown/src/DropdownGroup.d.ts +3 -2
  540. package/lib/dropdown/src/DropdownMenu.d.ts +3 -2
  541. package/lib/dropdown/src/DropdownOption.d.ts +4 -3
  542. package/lib/dropdown/src/DropdownRenderOption.d.ts +3 -2
  543. package/lib/dropdown/src/utils.js +4 -5
  544. package/lib/dynamic-input/src/DynamicInput.d.ts +3 -114
  545. package/lib/dynamic-input/src/InputPreset.d.ts +1 -112
  546. package/lib/dynamic-input/src/PairPreset.d.ts +1 -112
  547. package/lib/dynamic-tags/src/DynamicTags.d.ts +14 -125
  548. package/lib/ellipsis/src/Ellipsis.d.ts +4 -115
  549. package/lib/ellipsis/src/Ellipsis.js +3 -3
  550. package/lib/ellipsis/src/PerformantEllipsis.d.ts +2 -2
  551. package/lib/empty/src/Empty.d.ts +109 -48
  552. package/lib/empty/src/Empty.js +25 -7
  553. package/lib/empty/src/styles/index.cssr.js +37 -10
  554. package/lib/empty/styles/light.d.ts +11 -5
  555. package/lib/empty/styles/light.js +17 -11
  556. package/lib/equation/src/Equation.d.ts +4 -3
  557. package/lib/flex/src/Flex.d.ts +13 -12
  558. package/lib/form/src/Form.d.ts +4 -4
  559. package/lib/form/src/Form.js +2 -2
  560. package/lib/form/src/FormItem.d.ts +23 -10
  561. package/lib/form/src/FormItem.js +19 -6
  562. package/lib/form/src/FormItemCol.d.ts +22 -9
  563. package/lib/form/src/FormItemGridItem.d.ts +24 -11
  564. package/lib/form/src/FormItemRow.d.ts +21 -8
  565. package/lib/form/src/utils.d.ts +3 -2
  566. package/lib/form/src/utils.js +20 -4
  567. package/lib/gradient-text/src/GradientText.d.ts +5 -5
  568. package/lib/grid/src/Grid.d.ts +18 -18
  569. package/lib/grid/src/GridItem.d.ts +2 -2
  570. package/lib/icon/src/Icon.d.ts +3 -3
  571. package/lib/icon-wrapper/src/IconWrapper.d.ts +1 -1
  572. package/lib/image/src/Image.d.ts +5 -5
  573. package/lib/image/src/ImageGroup.d.ts +1 -1
  574. package/lib/image/src/ImagePreview.d.ts +1 -1
  575. package/lib/input/src/Input.d.ts +79 -155
  576. package/lib/input/src/Input.js +54 -17
  577. package/lib/input/src/InputGroupLabel.d.ts +1 -1
  578. package/lib/input/src/use-clipboard.d.ts +9 -0
  579. package/lib/input/src/use-clipboard.js +50 -0
  580. package/lib/input/src/utils.js +3 -4
  581. package/lib/input-number/src/InputNumber.d.ts +14 -125
  582. package/lib/input-number/src/utils.js +5 -6
  583. package/lib/layout/src/Layout.d.ts +4 -226
  584. package/lib/layout/src/Layout.js +2 -2
  585. package/lib/layout/src/LayoutContent.d.ts +2 -113
  586. package/lib/layout/src/LayoutFooter.d.ts +1 -1
  587. package/lib/layout/src/LayoutHeader.d.ts +2 -2
  588. package/lib/layout/src/LayoutHeader.js +5 -1
  589. package/lib/layout/src/LayoutSider.d.ts +10 -121
  590. package/lib/layout/src/LayoutSider.js +3 -3
  591. package/lib/layout/src/ToggleSidebarButton.d.ts +15 -0
  592. package/lib/layout/src/ToggleSidebarButton.js +25 -0
  593. package/lib/layout/src/interface.d.ts +1 -1
  594. package/lib/layout/src/styles/layout-header.cssr.js +3 -0
  595. package/lib/layout/src/styles/layout-sider.cssr.js +64 -6
  596. package/lib/layout/src/utils/resolveTriggerComponent.d.ts +51 -0
  597. package/lib/layout/src/utils/resolveTriggerComponent.js +19 -0
  598. package/lib/legacy-transfer/src/Transfer.d.ts +112 -163
  599. package/lib/legacy-transfer/src/TransferFilter.d.ts +12 -117
  600. package/lib/legacy-transfer/src/TransferList.d.ts +12 -117
  601. package/lib/legacy-transfer/src/TransferListItem.d.ts +13 -118
  602. package/lib/legacy-transfer/src/use-transfer-data.js +1 -2
  603. package/lib/legacy-transfer/styles/light.d.ts +11 -5
  604. package/lib/list/src/List.d.ts +6 -6
  605. package/lib/list/src/ListItem.d.ts +5 -5
  606. package/lib/loading-bar/src/LoadingBar.d.ts +1 -1
  607. package/lib/loading-bar/src/LoadingBar.js +2 -2
  608. package/lib/loading-bar/src/LoadingBarProvider.d.ts +9 -9
  609. package/lib/loading-bar/src/use-loading-bar.js +1 -2
  610. package/lib/locales/common/arDZ.js +9 -2
  611. package/lib/locales/common/deDE.js +9 -2
  612. package/lib/locales/common/enGB.js +9 -2
  613. package/lib/locales/common/enUS.d.ts +8 -1
  614. package/lib/locales/common/enUS.js +9 -2
  615. package/lib/locales/common/eo.js +9 -2
  616. package/lib/locales/common/esAR.js +9 -2
  617. package/lib/locales/common/faIR.js +9 -2
  618. package/lib/locales/common/frFR.js +9 -2
  619. package/lib/locales/common/idID.js +9 -2
  620. package/lib/locales/common/itIT.js +9 -2
  621. package/lib/locales/common/jaJP.js +9 -2
  622. package/lib/locales/common/koKR.js +9 -2
  623. package/lib/locales/common/nbNO.js +9 -2
  624. package/lib/locales/common/nlNL.js +9 -2
  625. package/lib/locales/common/plPL.js +9 -2
  626. package/lib/locales/common/ptBR.js +9 -2
  627. package/lib/locales/common/ruRU.js +9 -2
  628. package/lib/locales/common/skSK.js +9 -2
  629. package/lib/locales/common/svSE.js +9 -2
  630. package/lib/locales/common/thTH.js +9 -2
  631. package/lib/locales/common/trTR.js +9 -2
  632. package/lib/locales/common/ukUA.js +9 -2
  633. package/lib/locales/common/viVN.js +9 -2
  634. package/lib/locales/common/zhCN.js +9 -2
  635. package/lib/locales/common/zhTW.js +9 -2
  636. package/lib/locales/utils/index.js +1 -2
  637. package/lib/log/src/Log.d.ts +8 -120
  638. package/lib/mention/src/Mention.d.ts +140 -185
  639. package/lib/mention/src/utils.js +7 -8
  640. package/lib/mention/styles/light.d.ts +11 -5
  641. package/lib/menu/src/Menu.d.ts +16 -127
  642. package/lib/menu/src/MenuOption.d.ts +2 -113
  643. package/lib/menu/src/MenuOptionGroup.d.ts +1 -1
  644. package/lib/menu/src/Submenu.d.ts +2 -113
  645. package/lib/menu/src/use-menu-child.js +1 -2
  646. package/lib/menu/src/useCheckDeprecated.js +1 -2
  647. package/lib/menu/src/utils.js +3 -4
  648. package/lib/menu/styles/light.js +2 -2
  649. package/lib/message/src/Message.d.ts +1 -1
  650. package/lib/message/src/MessageEnvironment.d.ts +1 -1
  651. package/lib/message/src/MessageProvider.d.ts +5 -5
  652. package/lib/message/src/use-message.js +1 -2
  653. package/lib/modal/src/BodyWrapper.d.ts +8 -119
  654. package/lib/modal/src/Modal.d.ts +17 -17
  655. package/lib/modal/src/presetProps.d.ts +2 -2
  656. package/lib/notification/src/Notification.d.ts +5 -5
  657. package/lib/notification/src/NotificationContainer.d.ts +1 -112
  658. package/lib/notification/src/NotificationEnvironment.d.ts +4 -4
  659. package/lib/notification/src/NotificationProvider.d.ts +17 -17
  660. package/lib/notification/src/use-notification.js +1 -2
  661. package/lib/number-animation/src/NumberAnimation.d.ts +1 -1
  662. package/lib/number-animation/src/utils.js +1 -2
  663. package/lib/page-header/styles/light.js +2 -2
  664. package/lib/pagination/src/Pagination.d.ts +263 -242
  665. package/lib/pagination/src/utils.js +1 -2
  666. package/lib/pagination/styles/light.d.ts +22 -10
  667. package/lib/popconfirm/src/Popconfirm.d.ts +29 -140
  668. package/lib/popconfirm/src/PopconfirmPanel.d.ts +1 -1
  669. package/lib/popover/src/Popover.d.ts +30 -30
  670. package/lib/popover/src/PopoverBody.d.ts +19 -19
  671. package/lib/popselect/src/Popselect.d.ts +195 -240
  672. package/lib/popselect/src/PopselectPanel.d.ts +26 -125
  673. package/lib/popselect/styles/light.d.ts +11 -5
  674. package/lib/popselect/styles/light.js +1 -2
  675. package/lib/preset.d.ts +1 -1
  676. package/lib/progress/src/Line.d.ts +1 -1
  677. package/lib/progress/src/MultipleCircle.d.ts +2 -2
  678. package/lib/progress/src/Progress.d.ts +6 -6
  679. package/lib/radio/src/Radio.d.ts +10 -10
  680. package/lib/radio/src/RadioButton.d.ts +6 -6
  681. package/lib/rate/src/Rate.d.ts +1 -1
  682. package/lib/result/src/Result.d.ts +4 -4
  683. package/lib/select/src/Select.d.ts +141 -186
  684. package/lib/select/src/utils.js +6 -7
  685. package/lib/select/styles/light.d.ts +11 -5
  686. package/lib/select/styles/light.js +1 -2
  687. package/lib/skeleton/src/Skeleton.d.ts +1 -1
  688. package/lib/slider/src/Slider.d.ts +9 -9
  689. package/lib/slider/src/utils.js +2 -3
  690. package/lib/space/src/Space.d.ts +5 -5
  691. package/lib/spin/src/Spin.d.ts +8 -8
  692. package/lib/styles.d.ts +1 -0
  693. package/lib/styles.js +153 -151
  694. package/lib/switch/src/Switch.d.ts +11 -11
  695. package/lib/table/src/Table.d.ts +1 -1
  696. package/lib/tabs/src/Tab.d.ts +10 -22
  697. package/lib/tabs/src/TabPane.d.ts +9 -21
  698. package/lib/tabs/src/Tabs.d.ts +29 -30
  699. package/lib/tag/src/Tag.d.ts +11 -11
  700. package/lib/tag/src/common-props.d.ts +2 -2
  701. package/lib/themes/dark.js +148 -146
  702. package/lib/themes/light.js +148 -146
  703. package/lib/themes/utils.js +1 -2
  704. package/lib/time/src/Time.d.ts +2 -2
  705. package/lib/time-picker/src/Panel.d.ts +3 -114
  706. package/lib/time-picker/src/PanelCol.d.ts +4 -4
  707. package/lib/time-picker/src/TimePicker.d.ts +17 -128
  708. package/lib/time-picker/src/utils.js +6 -6
  709. package/lib/timeline/src/TimelineItem.d.ts +4 -4
  710. package/lib/toggle-button/src/ToggleButton.d.ts +12 -12
  711. package/lib/tooltip/src/Tooltip.d.ts +25 -136
  712. package/lib/transfer/src/Transfer.d.ts +112 -163
  713. package/lib/transfer/src/TransferFilter.d.ts +12 -117
  714. package/lib/transfer/src/TransferList.d.ts +12 -117
  715. package/lib/transfer/src/TransferListItem.d.ts +13 -118
  716. package/lib/transfer/src/use-transfer-data.js +1 -2
  717. package/lib/transfer/styles/light.d.ts +11 -5
  718. package/lib/tree/src/MotionWrapper.d.ts +2 -2
  719. package/lib/tree/src/Tree.d.ts +148 -199
  720. package/lib/tree/src/Tree.js +2 -2
  721. package/lib/tree/src/TreeNodeCheckbox.d.ts +13 -118
  722. package/lib/tree/src/TreeNodeContent.d.ts +1 -1
  723. package/lib/tree/src/TreeNodeSwitcher.d.ts +3 -3
  724. package/lib/tree/src/dnd.js +2 -3
  725. package/lib/tree/src/keyboard.js +1 -2
  726. package/lib/tree/src/utils.js +5 -5
  727. package/lib/tree/styles/light.d.ts +11 -5
  728. package/lib/tree-select/src/TreeSelect.d.ts +269 -260
  729. package/lib/tree-select/src/utils.js +2 -3
  730. package/lib/tree-select/styles/light.d.ts +22 -10
  731. package/lib/typography/src/create-header.d.ts +5 -5
  732. package/lib/typography/src/headers.d.ts +18 -18
  733. package/lib/typography/src/p.d.ts +3 -3
  734. package/lib/typography/src/text.d.ts +6 -6
  735. package/lib/upload/src/Upload.d.ts +137 -137
  736. package/lib/upload/src/Upload.js +58 -209
  737. package/lib/upload/src/UploadFile.d.ts +17 -115
  738. package/lib/upload/src/UploadFile.js +55 -55
  739. package/lib/upload/src/UploadFileList.js +2 -2
  740. package/lib/upload/src/UploadProgress.d.ts +9 -114
  741. package/lib/upload/src/UploadTrigger.js +19 -6
  742. package/lib/upload/src/interface.d.ts +42 -0
  743. package/lib/upload/src/styles/index.cssr.js +159 -34
  744. package/lib/upload/src/useUpload.d.ts +2 -0
  745. package/lib/upload/src/useUpload.js +166 -0
  746. package/lib/upload/src/useUploadActionsRender.d.ts +26 -0
  747. package/lib/upload/src/useUploadActionsRender.js +88 -0
  748. package/lib/upload/src/useUploadInternals.d.ts +25 -0
  749. package/lib/upload/src/useUploadInternals.js +43 -0
  750. package/lib/upload/src/utils.d.ts +2 -1
  751. package/lib/upload/src/utils.js +13 -7
  752. package/lib/upload/styles/light.d.ts +12 -0
  753. package/lib/upload/styles/light.js +8 -2
  754. package/lib/version.d.ts +1 -1
  755. package/lib/version.js +1 -1
  756. package/lib/watermark/src/Watermark.d.ts +6 -6
  757. package/package.json +53 -50
  758. package/volar.d.ts +2 -1
  759. package/web-types.json +259 -9
@@ -10,171 +10,17 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
10
10
  import { h, defineComponent, computed, provide, toRef, ref, Fragment, Teleport, nextTick } from 'vue';
11
11
  import { createId } from 'seemly';
12
12
  import { useMergedState } from 'vooks';
13
- import { useConfig, useTheme, useFormItem, useThemeClass } from '../../_mixins';
14
- import { warn, call, throwError } from '../../_utils';
13
+ import { useConfig, useTheme, useFormItem, useThemeClass, useLocale } from '../../_mixins';
14
+ import { warn, call, throwError, createKey } from '../../_utils';
15
15
  import { uploadLight } from '../styles';
16
16
  import { uploadInjectionKey } from './interface';
17
17
  import { createImageDataUrl, createSettledFileInfo, environmentSupportFile, isImageFile, matchType } from './utils';
18
18
  import UUploadTrigger from './UploadTrigger';
19
19
  import UUploadFileList from './UploadFileList';
20
20
  import style from './styles/index.cssr';
21
- import { UBaseIcon } from '../../_internal';
22
- import UUploadDragger, { uploadDraggerKey } from './UploadDragger';
23
- import { uploadIcon } from './icons';
24
- /**
25
- * fils status ['pending', 'uploading', 'finished', 'removed', 'error']
26
- */
27
- function createXhrHandlers(inst, file, xhr) {
28
- const { doChange, xhrMap } = inst;
29
- let percentage = 0;
30
- function handleXHRError(e) {
31
- var _a;
32
- let fileAfterChange = Object.assign({}, file, {
33
- status: 'error',
34
- percentage
35
- });
36
- xhrMap.delete(file.id);
37
- fileAfterChange = createSettledFileInfo(((_a = inst.onError) === null || _a === void 0 ? void 0 : _a.call(inst, { file: fileAfterChange, event: e })) || fileAfterChange);
38
- doChange(fileAfterChange, e);
39
- }
40
- function handleXHRLoad(e) {
41
- var _a;
42
- if (inst.isErrorState) {
43
- if (inst.isErrorState(xhr)) {
44
- handleXHRError(e);
45
- return;
46
- }
47
- }
48
- else {
49
- if (xhr.status < 200 || xhr.status >= 300) {
50
- handleXHRError(e);
51
- return;
52
- }
53
- }
54
- let fileAfterChange = Object.assign({}, file, {
55
- status: 'finished',
56
- percentage
57
- });
58
- xhrMap.delete(file.id);
59
- fileAfterChange = createSettledFileInfo(((_a = inst.onFinish) === null || _a === void 0 ? void 0 : _a.call(inst, { file: fileAfterChange, event: e })) || fileAfterChange);
60
- doChange(fileAfterChange, e);
61
- }
62
- return {
63
- handleXHRLoad,
64
- handleXHRError,
65
- handleXHRAbort(e) {
66
- const fileAfterChange = Object.assign({}, file, {
67
- status: 'removed',
68
- file: null,
69
- percentage
70
- });
71
- xhrMap.delete(file.id);
72
- doChange(fileAfterChange, e);
73
- },
74
- handleXHRProgress(e) {
75
- const fileAfterChange = Object.assign({}, file, {
76
- status: 'uploading'
77
- });
78
- if (e.lengthComputable) {
79
- const progress = Math.ceil((e.loaded / e.total) * 100);
80
- fileAfterChange.percentage = progress;
81
- percentage = progress;
82
- }
83
- doChange(fileAfterChange, e);
84
- }
85
- };
86
- }
87
- function customSubmitImpl(options) {
88
- const { inst, file, data, headers, withCredentials, action, customRequest } = options;
89
- const { doChange } = options.inst;
90
- let percentage = 0;
91
- customRequest({
92
- file,
93
- data,
94
- headers,
95
- withCredentials,
96
- action,
97
- onProgress(event) {
98
- const fileAfterChange = Object.assign({}, file, {
99
- status: 'uploading'
100
- });
101
- const progress = event.percent;
102
- fileAfterChange.percentage = progress;
103
- percentage = progress;
104
- doChange(fileAfterChange);
105
- },
106
- onFinish() {
107
- var _a;
108
- let fileAfterChange = Object.assign({}, file, {
109
- status: 'finished',
110
- percentage
111
- });
112
- fileAfterChange = createSettledFileInfo(((_a = inst.onFinish) === null || _a === void 0 ? void 0 : _a.call(inst, { file: fileAfterChange })) || fileAfterChange);
113
- doChange(fileAfterChange);
114
- },
115
- onError() {
116
- var _a;
117
- let fileAfterChange = Object.assign({}, file, {
118
- status: 'error',
119
- percentage
120
- });
121
- fileAfterChange = createSettledFileInfo(((_a = inst.onError) === null || _a === void 0 ? void 0 : _a.call(inst, { file: fileAfterChange })) || fileAfterChange);
122
- doChange(fileAfterChange);
123
- }
124
- });
125
- }
126
- function registerHandler(inst, file, request) {
127
- const handlers = createXhrHandlers(inst, file, request);
128
- request.onabort = handlers.handleXHRAbort;
129
- request.onerror = handlers.handleXHRError;
130
- request.onload = handlers.handleXHRLoad;
131
- if (request.upload) {
132
- request.upload.onprogress = handlers.handleXHRProgress;
133
- }
134
- }
135
- function unwrapFunctionValue(data, file) {
136
- if (typeof data === 'function') {
137
- return data({ file });
138
- }
139
- if (data)
140
- return data;
141
- return {};
142
- }
143
- function setHeaders(request, headers, file) {
144
- const headersObject = unwrapFunctionValue(headers, file);
145
- if (!headersObject)
146
- return;
147
- Object.keys(headersObject).forEach((key) => {
148
- request.setRequestHeader(key, headersObject[key]);
149
- });
150
- }
151
- function appendData(formData, data, file) {
152
- const dataObject = unwrapFunctionValue(data, file);
153
- if (!dataObject)
154
- return;
155
- Object.keys(dataObject).forEach((key) => {
156
- formData.append(key, dataObject[key]);
157
- });
158
- }
159
- function submitImpl(inst, fieldName, file, { method, action, withCredentials, responseType, headers, data }) {
160
- const request = new XMLHttpRequest();
161
- request.responseType = responseType;
162
- inst.xhrMap.set(file.id, request);
163
- request.withCredentials = withCredentials;
164
- const formData = new FormData();
165
- appendData(formData, data, file);
166
- formData.append(fieldName, file.file);
167
- registerHandler(inst, file, request);
168
- if (action !== undefined) {
169
- request.open(method.toUpperCase(), action);
170
- setHeaders(request, headers, file);
171
- request.send(formData);
172
- const fileAfterChange = Object.assign({}, file, {
173
- status: 'uploading'
174
- });
175
- inst.doChange(fileAfterChange);
176
- }
177
- }
21
+ import { uploadDraggerKey } from './UploadDragger';
22
+ import { useUpload } from './useUpload';
23
+ import { useUploadInternals } from './useUploadInternals';
178
24
  export const uploadProps = Object.assign(Object.assign({}, useTheme.props), { name: {
179
25
  type: String,
180
26
  default: 'file'
@@ -190,7 +36,10 @@ export const uploadProps = Object.assign(Object.assign({}, useTheme.props), { na
190
36
  }, disabled: {
191
37
  type: Boolean,
192
38
  default: undefined
193
- }, onChange: Function, onRemove: Function, onFinish: Function, onError: Function, onBeforeUpload: Function, isErrorState: Function,
39
+ }, vertical: {
40
+ type: Boolean,
41
+ default: false
42
+ }, icon: Object, onChange: Function, onRemove: Function, onFinish: Function, onError: Function, onBeforeUpload: Function, isErrorState: Function,
194
43
  /** currently not used */
195
44
  onDownload: Function, defaultUpload: {
196
45
  type: Boolean,
@@ -223,11 +72,19 @@ export const uploadProps = Object.assign(Object.assign({}, useTheme.props), { na
223
72
  }, createThumbnailUrl: Function, abstract: Boolean, max: Number, showTrigger: {
224
73
  type: Boolean,
225
74
  default: true
226
- }, imageGroupProps: Object, inputProps: Object, triggerStyle: [String, Object], renderIcon: Function, label: String });
75
+ }, imageGroupProps: Object, inputProps: Object, triggerStyle: [String, Object], renderIcon: Function, label: String, size: {
76
+ type: String,
77
+ default: 'medium'
78
+ }, title: String, subtitle: String, noIcon: {
79
+ type: Boolean,
80
+ default: false
81
+ } });
227
82
  export default defineComponent({
228
83
  name: 'Upload',
229
84
  props: uploadProps,
230
85
  setup(props) {
86
+ const { localeRef } = useLocale('Upload');
87
+ const { submitImpl, customSubmitImpl } = useUpload();
231
88
  if (props.abstract && props.listType === 'image-card') {
232
89
  throwError('upload', 'when the list-type is image-card, abstract is not supported.');
233
90
  }
@@ -296,8 +153,8 @@ export default defineComponent({
296
153
  fileAndEntries = fileAndEntries.slice(0, max - mergedFileListRef.value.length);
297
154
  }
298
155
  const batchId = createId();
299
- void Promise.all(fileAndEntries.map(({ file, entry }) => __awaiter(this, void 0, void 0, function* () {
300
- var _a;
156
+ void Promise.all(fileAndEntries.map((_a) => __awaiter(this, [_a], void 0, function* ({ file, entry }) {
157
+ var _b;
301
158
  const fileInfo = {
302
159
  id: createId(),
303
160
  batchId,
@@ -308,7 +165,7 @@ export default defineComponent({
308
165
  url: null,
309
166
  type: file.type,
310
167
  thumbnailUrl: null,
311
- fullPath: (_a = entry === null || entry === void 0 ? void 0 : entry.fullPath) !== null && _a !== void 0 ? _a : `/${file.webkitRelativePath || file.name}`
168
+ fullPath: (_b = entry === null || entry === void 0 ? void 0 : entry.fullPath) !== null && _b !== void 0 ? _b : `/${file.webkitRelativePath || file.name}`
312
169
  };
313
170
  if (!onBeforeUpload ||
314
171
  (yield onBeforeUpload({
@@ -429,7 +286,8 @@ export default defineComponent({
429
286
  return '';
430
287
  }
431
288
  const cssVarsRef = computed(() => {
432
- const { common: { cubicBezierEaseInOut }, self: { draggerColor, draggerBorder, draggerBorderHover, itemColorHover, itemColorHoverError, itemTextColorError, itemTextColorSuccess, itemTextColor, itemIconColor, itemDisabledOpacity, lineHeight, borderRadius, fontSize, itemBorderImageCardError, itemBorderImageCard, baseColor, draggerIconBgColor, draggerIconColor, draggerTextColor, draggerTitleColor, labelColor } } = themeRef.value;
289
+ const { value: size } = formItem.mergedSizeRef;
290
+ const { common: { cubicBezierEaseInOut }, self: { draggerColor, draggerBorder, draggerBorderHover, itemColorHover, itemColorHoverError, itemTextColorError, itemTextColorSuccess, itemTextColor, itemIconColor, itemDisabledOpacity, lineHeight, borderRadius, fontSize, itemBorderImageCardError, itemBorderImageCard, baseColor, draggerIconBgColor, draggerIconColor, draggerTextColor, draggerTitleColor, labelColor, containerSecondary, brandPrimary300, elementsQuaternary, [createKey('width', size)]: width } } = themeRef.value;
433
291
  return {
434
292
  '--u-bezier': cubicBezierEaseInOut,
435
293
  '--u-border-radius': borderRadius,
@@ -453,11 +311,18 @@ export default defineComponent({
453
311
  '--u-dragger-title-color': draggerTitleColor,
454
312
  '--u-dragger-text-color': draggerTextColor,
455
313
  '--u-label-color': labelColor,
456
- '--u-upload-width': props.listType === 'image-card' ? 'auto' : '100%'
314
+ '--u-upload-width': props.listType === 'image-card' ? 'auto' : '100%',
315
+ '--u-upload-dragger-width': width,
316
+ '--u-upload-info-bg-color': containerSecondary,
317
+ '--u-upload-preview-color': brandPrimary300,
318
+ '--u-upload-empty-border-color': elementsQuaternary
457
319
  };
458
320
  });
459
321
  const themeClassHandle = inlineThemeDisabled
460
- ? useThemeClass('upload', undefined, cssVarsRef, props)
322
+ ? useThemeClass('upload', computed(() => {
323
+ const { value: size } = formItem.mergedSizeRef;
324
+ return size[0];
325
+ }), cssVarsRef, props)
461
326
  : undefined;
462
327
  provide(uploadInjectionKey, {
463
328
  mergedClsPrefixRef,
@@ -485,6 +350,12 @@ export default defineComponent({
485
350
  handleFileAddition,
486
351
  mergedDisabledRef: formItem.mergedDisabledRef,
487
352
  maxReachedRef,
353
+ localeRef,
354
+ iconRef: toRef(props, 'icon'),
355
+ noIconRef: toRef(props, 'noIcon'),
356
+ titleRef: toRef(props, 'title'),
357
+ subtitleRef: toRef(props, 'subtitle'),
358
+ verticalRef: toRef(props, 'vertical'),
488
359
  fileListStyleRef: toRef(props, 'fileListStyle'),
489
360
  abstractRef: toRef(props, 'abstract'),
490
361
  acceptRef: toRef(props, 'accept'),
@@ -505,8 +376,9 @@ export default defineComponent({
505
376
  submit,
506
377
  openFileDialog
507
378
  };
508
- return Object.assign({ mergedClsPrefix: mergedClsPrefixRef, draggerInsideRef,
509
- inputElRef, mergedTheme: themeRef, dragOver: dragOverRef, mergedMultiple: mergedMultipleRef, cssVars: inlineThemeDisabled ? undefined : cssVarsRef, themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass, onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender, handleFileInputChange }, exposedMethods);
379
+ return Object.assign({ mergedClsPrefix: mergedClsPrefixRef, mergedSizeRef: formItem.mergedSizeRef, draggerInsideRef,
380
+ inputElRef,
381
+ localeRef, mergedTheme: themeRef, dragOver: dragOverRef, mergedMultiple: mergedMultipleRef, cssVars: inlineThemeDisabled ? undefined : cssVarsRef, themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass, onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender, handleFileInputChange }, exposedMethods);
510
382
  },
511
383
  render() {
512
384
  var _a, _b;
@@ -517,24 +389,22 @@ export default defineComponent({
517
389
  draggerInsideRef.value = true;
518
390
  }
519
391
  }
520
- const inputNode = (h("input", Object.assign({}, this.inputProps, { ref: "inputElRef", type: "file", class: `${mergedClsPrefix}-upload-file-input`, accept: this.accept, multiple: this.mergedMultiple, onChange: this.handleFileInputChange,
521
- // @ts-expect-error // seems vue-tsc will add the prop, so we can't use expect-error
522
- webkitdirectory: directory || undefined, directory: directory || undefined })));
523
- const renderDefaultTrigger = () => {
524
- const rootClass = `${mergedClsPrefix}-upload-dragger-inner`;
525
- return [
526
- h(Fragment, null,
527
- this.$props.label ? (h("p", { class: `${mergedClsPrefix}-upload__label` }, this.$props.label)) : null,
528
- h(UUploadDragger, null, {
529
- default: () => (h("div", { class: rootClass },
530
- h("div", { class: `${rootClass}__icon` },
531
- h(UBaseIcon, { clsPrefix: mergedClsPrefix }, { default: () => uploadIcon })),
532
- h("div", { class: `${rootClass}__content` },
533
- h("p", { class: `${rootClass}__title` }, "\u0412\u044B\u0431\u0435\u0440\u0438\u0442\u0435 \u0444\u0430\u0439\u043B \u0438\u043B\u0438 \u043F\u0435\u0440\u0435\u0442\u0430\u0449\u0438\u0442\u0435 \u0441\u044E\u0434\u0430"),
534
- h("p", { class: `${rootClass}__subtitle` }, "PDF, PNG, JPEG \u043D\u0435 \u0431\u043E\u043B\u0435\u0435 100 MB"))))
535
- }))
536
- ];
537
- };
392
+ const { inputNode, renderDefaultTrigger } = useUploadInternals({
393
+ mergedClsPrefix: this.mergedClsPrefix,
394
+ accept: this.accept,
395
+ multiple: this.mergedMultiple,
396
+ directory,
397
+ inputProps: this.inputProps,
398
+ onChange: this.handleFileInputChange,
399
+ label: this.label,
400
+ title: this.title,
401
+ subtitle: this.subtitle,
402
+ vertical: this.vertical,
403
+ noIcon: this.noIcon,
404
+ icon: this.icon,
405
+ localeRef: this.localeRef,
406
+ slots: this.$slots
407
+ });
538
408
  const hasDefaulTrigger = !$slots.default;
539
409
  const slots = Object.assign(Object.assign({}, $slots), { default: $slots.default || renderDefaultTrigger });
540
410
  if (this.abstract) {
@@ -550,7 +420,9 @@ export default defineComponent({
550
420
  this.themeClass
551
421
  ], style: this.cssVars },
552
422
  inputNode,
553
- this.showTrigger && this.listType !== 'image-card' && (h(UUploadTrigger, { class: [
423
+ this.showTrigger &&
424
+ this.listType !== 'image-card' &&
425
+ this.listType !== 'image' && (h(UUploadTrigger, { class: [
554
426
  hasDefaulTrigger && `${mergedClsPrefix}-upload-trigger--block`
555
427
  ] }, slots)),
556
428
  this.showFileList && h(UUploadFileList, null, $slots)));
@@ -1,12 +1,12 @@
1
1
  import { type PropType } from 'vue';
2
- import type { ListType } from './interface';
2
+ import type { SettledFileInfo, ListType } from './interface';
3
3
  declare const _default: import("vue").DefineComponent<{
4
4
  clsPrefix: {
5
5
  type: StringConstructor;
6
6
  required: true;
7
7
  };
8
8
  file: {
9
- type: PropType<Required<import("./interface").FileInfo>>;
9
+ type: PropType<SettledFileInfo>;
10
10
  required: true;
11
11
  };
12
12
  listType: {
@@ -15,118 +15,7 @@ declare const _default: import("vue").DefineComponent<{
15
15
  };
16
16
  }, {
17
17
  mergedTheme: import("vue").Ref<{
18
- common: {
19
- scrollbarColor: string;
20
- scrollbarColorHover: string;
21
- scrollbarWidth: string;
22
- scrollbarHeight: string;
23
- scrollbarBorderRadius: string;
24
- opacityDisabled: string;
25
- brandPrimary50: string;
26
- brandPrimary100: string;
27
- brandPrimary200: string;
28
- brandPrimary300: string;
29
- brandPrimary400: string;
30
- brandPrimary500: string;
31
- brandPrimary550: string;
32
- brandPrimary600: string;
33
- brandSecondary500: string;
34
- brandSecondary300: string;
35
- brandSecondary600: string;
36
- brandTertiary500: string;
37
- brandTertiary300: string;
38
- brandTertiary600: string;
39
- brandQuaternary500: string;
40
- brandQuaternary300: string;
41
- brandQuaternary600: string;
42
- brandQuinary500: string;
43
- brandQuinary300: string;
44
- brandQuinary600: string;
45
- brandQuinary100: string;
46
- surfacePrimary: string;
47
- surfaceSecondary: string;
48
- containerPrimary: string;
49
- containerSecondary: string;
50
- textPrimary: string;
51
- textSecondary: string;
52
- textTertiary: string;
53
- textQuaternary: string;
54
- textBrand: string;
55
- elementsPrimary: string;
56
- elementsSecondary: string;
57
- elementsTertiary: string;
58
- elementsQuaternary: string;
59
- elementsQuinary: string;
60
- elementsDarkQuinary: string;
61
- elementsSenary: string;
62
- elementsOnContainer: string;
63
- transparencyPrimary: string;
64
- transparencySecondary: string;
65
- transparencyTertiary: string;
66
- transparencyQuinary: string;
67
- transparencyModal: string;
68
- staticBlack: string;
69
- staticDarkGrey: string;
70
- staticWhite: string;
71
- staticRed: string;
72
- staticOrange: string;
73
- staticGreen: string;
74
- staticDeepBlue: string;
75
- staticErrorAccent: string;
76
- shadowDepth2: string;
77
- shadowDepth: string;
78
- fontFamily: string;
79
- fontFamilyMono: string;
80
- cubicBezierEaseInOut: string;
81
- cubicBezierEaseOut: string;
82
- cubicBezierEaseIn: string;
83
- borderRadiusLarge: string;
84
- borderRadius: string;
85
- borderRadiusMedium: string;
86
- borderRadiusSmall: string;
87
- borderRadiusTiny: string;
88
- heightMini: string;
89
- heightTiny: string;
90
- heightSmall: string;
91
- heightMedium: string;
92
- heightLarge: string;
93
- heightHuge: string;
94
- fontDisplayLarge: string;
95
- fontDisplaySmall: string;
96
- fontHeadingLarge: string;
97
- fontHeadingMedium: string;
98
- fontHeadingSmall: string;
99
- fontTitleLarge: string;
100
- fontTitleMedium: string;
101
- fontTitleSmall: string;
102
- fontBodyLarge: string;
103
- fontBodyMedium: string;
104
- fontBodySmall: string;
105
- lineHeightDisplayLarge: string;
106
- lineHeightDisplaySmall: string;
107
- lineHeightHeadingLarge: string;
108
- lineHeightHeadingMedium: string;
109
- lineHeightHeadingSmall: string;
110
- lineHeightTitleLarge: string;
111
- lineHeightTitleMedium: string;
112
- lineHeightTitleSmall: string;
113
- lineHeightBodyLarge: string;
114
- lineHeightBodyMedium: string;
115
- lineHeightBodySmall: string;
116
- fontWeight: string;
117
- fontWeightStrong: string;
118
- fontWeightBold: string;
119
- iconSmall: string;
120
- iconMedium: string;
121
- iconLarge: string;
122
- iconHuge: string;
123
- closeSmall: string;
124
- closeMedium: string;
125
- closeLarge: string;
126
- closeHuge: string;
127
- closeBorderRadius: string;
128
- name: "common";
129
- };
18
+ common: import("../..").ThemeCommonVars;
130
19
  self: {
131
20
  baseColor: string;
132
21
  fontSize: string;
@@ -149,6 +38,12 @@ declare const _default: import("vue").DefineComponent<{
149
38
  draggerTitleColor: string;
150
39
  draggerTextColor: string;
151
40
  labelColor: string;
41
+ widthSmall: string;
42
+ widthMedium: string;
43
+ widthLarge: string;
44
+ containerSecondary: string;
45
+ brandPrimary300: string;
46
+ elementsQuaternary: string;
152
47
  };
153
48
  peers: {
154
49
  Button: import("../../_mixins/use-theme").Theme<"Button", {
@@ -414,6 +309,13 @@ declare const _default: import("vue").DefineComponent<{
414
309
  imageRef: import("vue").Ref<{
415
310
  click: () => void;
416
311
  } | null>;
312
+ localeRef: import("vue").Ref<{
313
+ title: string;
314
+ subtitle: string;
315
+ uploading: string;
316
+ }>;
317
+ vertical: boolean;
318
+ capitalizeFirstLetter: (str: string) => string;
417
319
  handleRemoveOrCancelClick: (e: MouseEvent) => void;
418
320
  handleDownloadClick: (e: MouseEvent) => void;
419
321
  handleRetryClick: () => void;
@@ -424,7 +326,7 @@ declare const _default: import("vue").DefineComponent<{
424
326
  required: true;
425
327
  };
426
328
  file: {
427
- type: PropType<Required<import("./interface").FileInfo>>;
329
+ type: PropType<SettledFileInfo>;
428
330
  required: true;
429
331
  };
430
332
  listType: {
@@ -7,17 +7,13 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
7
7
  step((generator = generator.apply(thisArg, _arguments || [])).next());
8
8
  });
9
9
  };
10
- import { h, defineComponent, computed, inject, ref, watchEffect } from 'vue';
10
+ import { h, defineComponent, computed, inject, ref, watchEffect, Fragment } from 'vue';
11
11
  import { useMemo } from 'vooks';
12
- import { CancelIcon, TrashIcon, RetryIcon, DownloadIcon, EyeIcon } from '../../_internal/icons';
13
- import { UImage } from '../../image';
14
- import { UButton } from '../../button';
15
- import { UIconSwitchTransition, UBaseIcon } from '../../_internal';
16
12
  import { warn } from '../../_utils';
17
- import UUploadProgress from './UploadProgress';
18
13
  import { uploadInjectionKey } from './interface';
19
- import { imageIcon, documentIcon } from './icons';
20
- import { download, isImageFile } from './utils';
14
+ import { capitalizeFirstLetter, download } from './utils';
15
+ import { USpin } from '../../spin';
16
+ import { useUploadActionsRender } from './useUploadActionsRender';
21
17
  const buttonThemeOverrides = {
22
18
  paddingMedium: '0 3px',
23
19
  heightMedium: '24px',
@@ -189,6 +185,9 @@ export default defineComponent({
189
185
  shouldUseThumbnailUrl: UUpload.shouldUseThumbnailUrlRef,
190
186
  renderIcon: UUpload.renderIconRef,
191
187
  imageRef,
188
+ localeRef: UUpload.localeRef,
189
+ vertical: UUpload.verticalRef.value,
190
+ capitalizeFirstLetter,
192
191
  handleRemoveOrCancelClick,
193
192
  handleDownloadClick,
194
193
  handleRetryClick,
@@ -196,54 +195,58 @@ export default defineComponent({
196
195
  };
197
196
  },
198
197
  render() {
199
- const { clsPrefix, mergedTheme, listType, file, renderIcon } = this;
200
- // if there is text list type, show file icon
201
- let icon;
202
- const isImageType = listType === 'image';
203
- const isImageCardType = listType === 'image-card';
204
- if (isImageType || isImageCardType) {
205
- icon =
206
- !this.shouldUseThumbnailUrl(file) || !this.mergedThumbnailUrl ? (h("span", { class: `${clsPrefix}-upload-file-info__thumbnail ${clsPrefix}-upload-file-info__thumbnail--icon` }, renderIcon ? (renderIcon(file)) : isImageFile(file) ? (h(UBaseIcon, { clsPrefix: clsPrefix }, { default: () => imageIcon })) : (h(UBaseIcon, { clsPrefix: clsPrefix }, { default: () => documentIcon })))) : (h("a", { rel: "noopener noreferer", target: "_blank", href: file.url || undefined, class: `${clsPrefix}-upload-file-info__thumbnail`, onClick: this.handlePreviewClick }, listType === 'image-card' ? (h(UImage, { src: this.mergedThumbnailUrl || undefined, previewSrc: file.url || undefined, alt: file.name, ref: "imageRef" })) : (h("img", { src: this.mergedThumbnailUrl || undefined, alt: file.name }))));
207
- }
208
- else {
209
- icon = (h("span", { class: `${clsPrefix}-upload-file-info__thumbnail ${clsPrefix}-upload-file-info__thumbnail--icon` }, renderIcon ? (renderIcon(file)) : (h(UBaseIcon, { clsPrefix: clsPrefix }, { default: () => imageIcon }))));
210
- }
211
- const progress = (h(UUploadProgress, { show: this.showProgress, percentage: file.percentage || 0, status: this.progressStatus }));
212
- const showName = listType === 'text' || listType === 'image';
213
- return (h("div", { class: [
214
- `${clsPrefix}-upload-file`,
215
- `${clsPrefix}-upload-file--${this.progressStatus}-status`,
216
- file.url &&
217
- file.status !== 'error' &&
218
- listType !== 'image-card' &&
219
- `${clsPrefix}-upload-file--with-url`,
220
- `${clsPrefix}-upload-file--${listType}-type`
198
+ const { clsPrefix, mergedTheme, listType, file } = this;
199
+ const { icon, actionsNode } = useUploadActionsRender({
200
+ clsPrefix,
201
+ listType,
202
+ file,
203
+ disabled: this.disabled,
204
+ showPreviewButton: this.showPreviewButton,
205
+ showRemoveButton: this.showRemoveButton,
206
+ showCancelButton: this.showCancelButton,
207
+ showRetryButton: this.showRetryButton,
208
+ showDownloadButton: this.showDownloadButton,
209
+ buttonType: this.buttonType,
210
+ mergedTheme,
211
+ buttonThemeOverrides,
212
+ handlePreviewClick: this.handlePreviewClick,
213
+ handleRemoveOrCancelClick: this.handleRemoveOrCancelClick,
214
+ handleRetryClick: this.handleRetryClick,
215
+ handleDownloadClick: this.handleDownloadClick,
216
+ capitalizeFirstLetter: this.capitalizeFirstLetter
217
+ });
218
+ const imageCardTypes = ['image-card', 'image'];
219
+ return (h(USpin, { color: "tertiary", description: this.localeRef.uploading, show: this.showProgress, class: [
220
+ !this.vertical &&
221
+ !imageCardTypes.includes(listType) &&
222
+ `${clsPrefix}-upload-file-loader--default`
221
223
  ] },
222
- h("div", { class: `${clsPrefix}-upload-file-info` },
223
- icon,
224
- h("div", { class: `${clsPrefix}-upload-file-info__name` },
225
- showName &&
226
- (file.url && file.status !== 'error' ? (h("a", { rel: "noopener noreferer", target: "_blank", href: file.url || undefined, onClick: this.handlePreviewClick }, file.name)) : (h("span", { onClick: this.handlePreviewClick }, file.name))),
227
- isImageType && progress),
224
+ h("div", { class: [
225
+ `${clsPrefix}-upload-file`,
226
+ `${clsPrefix}-upload-file--${this.progressStatus}-status`,
227
+ file.url &&
228
+ file.status !== 'error' &&
229
+ imageCardTypes.includes(listType) &&
230
+ `${clsPrefix}-upload-file--with-url`,
231
+ `${clsPrefix}-upload-file--${listType === 'image' || listType === 'image-card'
232
+ ? 'image-card'
233
+ : 'text'}-type`
234
+ ] },
228
235
  h("div", { class: [
229
- `${clsPrefix}-upload-file-info__action`,
230
- `${clsPrefix}-upload-file-info__action--${listType}-type`
236
+ `${clsPrefix}-upload-file-info`,
237
+ imageCardTypes.includes(listType) &&
238
+ `${clsPrefix}-upload-file-info--vertical`
231
239
  ] },
232
- this.showPreviewButton ? (h(UButton, { key: "preview", quaternary: true, type: this.buttonType, onClick: this.handlePreviewClick, theme: mergedTheme.peers.Button, themeOverrides: mergedTheme.peerOverrides.Button, builtinThemeOverrides: buttonThemeOverrides }, {
233
- icon: () => (h(UBaseIcon, { clsPrefix: clsPrefix }, { default: () => h(EyeIcon, null) }))
234
- })) : null,
235
- (this.showRemoveButton || this.showCancelButton) &&
236
- !this.disabled && (h(UButton, { key: "cancelOrTrash", theme: mergedTheme.peers.Button, themeOverrides: mergedTheme.peerOverrides.Button, quaternary: true, builtinThemeOverrides: buttonThemeOverrides, type: this.buttonType, onClick: this.handleRemoveOrCancelClick }, {
237
- icon: () => (h(UIconSwitchTransition, null, {
238
- default: () => this.showRemoveButton ? (h(UBaseIcon, { clsPrefix: clsPrefix, key: "trash" }, { default: () => h(TrashIcon, null) })) : (h(UBaseIcon, { clsPrefix: clsPrefix, key: "cancel" }, { default: () => h(CancelIcon, null) }))
239
- }))
240
- })),
241
- this.showRetryButton && !this.disabled && (h(UButton, { key: "retry", quaternary: true, type: this.buttonType, onClick: this.handleRetryClick, theme: mergedTheme.peers.Button, themeOverrides: mergedTheme.peerOverrides.Button, builtinThemeOverrides: buttonThemeOverrides }, {
242
- icon: () => (h(UBaseIcon, { clsPrefix: clsPrefix }, { default: () => h(RetryIcon, null) }))
243
- })),
244
- this.showDownloadButton ? (h(UButton, { key: "download", quaternary: true, type: this.buttonType, onClick: this.handleDownloadClick, theme: mergedTheme.peers.Button, themeOverrides: mergedTheme.peerOverrides.Button, builtinThemeOverrides: buttonThemeOverrides }, {
245
- icon: () => (h(UBaseIcon, { clsPrefix: clsPrefix }, { default: () => h(DownloadIcon, null) }))
246
- })) : null)),
247
- !isImageType && progress));
240
+ icon,
241
+ h("div", { class: `${clsPrefix}-upload-file-info__name` },
242
+ h(Fragment, null,
243
+ h("span", { onClick: this.handlePreviewClick }, this.$slots['upload-file-title']
244
+ ? this.$slots['upload-file-title']({ file })
245
+ : file.name),
246
+ h("span", { onClick: this.handlePreviewClick }, this.$slots['upload-file-subtitle']
247
+ ? this.$slots['upload-file-subtitle']({ file })
248
+ : ''))),
249
+ actionsNode),
250
+ this.showProgress && (h("div", { class: `${clsPrefix}-upload-file-overlay` })))));
248
251
  }
249
252
  });
@@ -13,8 +13,8 @@ export default defineComponent({
13
13
  throwError('upload-file-list', '`u-upload-file-list` must be placed inside `u-upload`.');
14
14
  }
15
15
  const { abstractRef, mergedClsPrefixRef, listTypeRef, mergedFileListRef, fileListStyleRef, cssVarsRef, themeClassRef, maxReachedRef, showTriggerRef, imageGroupPropsRef } = UUpload;
16
- const isImageCardTypeRef = computed(() => listTypeRef.value === 'image-card');
17
- const renderFileList = () => mergedFileListRef.value.map((file) => (h(UUploadFile, { clsPrefix: mergedClsPrefixRef.value, key: file.id, file: file, listType: listTypeRef.value })));
16
+ const isImageCardTypeRef = computed(() => listTypeRef.value === 'image-card' || listTypeRef.value === 'image');
17
+ const renderFileList = () => mergedFileListRef.value.map((file) => (h(UUploadFile, { clsPrefix: mergedClsPrefixRef.value, key: file.id, file: file, listType: listTypeRef.value }, slots)));
18
18
  const renderUploadFileList = () => isImageCardTypeRef.value ? (h(UImageGroup, Object.assign({}, imageGroupPropsRef.value), { default: renderFileList })) : (h(UFadeInExpandTransition, { group: true }, {
19
19
  default: renderFileList
20
20
  }));