@unicom-cloud/ui 0.8.100 → 0.8.102

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 (301) hide show
  1. package/Badge.js +7 -54
  2. package/Copy.js +5 -4
  3. package/Details.js +13 -2
  4. package/Divider.js +3 -2
  5. package/Flex.js +14 -4
  6. package/LiquidFill.js +5 -4
  7. package/List.js +1 -1
  8. package/Loading.js +16 -3
  9. package/Marquee.js +5 -4
  10. package/QrCode.js +5 -4
  11. package/Space.js +3 -3
  12. package/Splitter.js +4 -3
  13. package/SuspenseFallbackTest.js +2 -4
  14. package/Tooltip.js +3 -4
  15. package/Tour.js +5 -4
  16. package/alert/index.js +60 -62
  17. package/anchor/Anchor.js +12 -12
  18. package/anchor/util.js +10 -10
  19. package/back-top/index.js +33 -34
  20. package/badge/index.js +109 -162
  21. package/calendar/index.js +85 -84
  22. package/card/index.js +63 -43
  23. package/color-picker/InputHex.js +3 -4
  24. package/color-picker/InputRgb.js +7 -8
  25. package/color-picker/Palette.js +3 -4
  26. package/color-picker/Panel.js +3 -4
  27. package/color-picker/colors.js +5 -5
  28. package/color-picker/hooks/useColorPicker.js +3 -4
  29. package/color-picker/utils.js +14 -15
  30. package/components/common/development/index.js +44 -29
  31. package/components/common/empty/index.js +35 -23
  32. package/components/common/flex/index.js +64 -0
  33. package/components/common/flex/interface.js +9 -0
  34. package/components/common/higher-order/with-speech-synthesis/index.js +79 -55
  35. package/components/common/space/index.js +71 -91
  36. package/components/common/suspense-fallback-test/index.js +16 -0
  37. package/components/common/utils/PqbCSSTransition.js +1 -1
  38. package/components/common/utils/constant.js +6 -3
  39. package/components/common/utils/reactDOM.js +6 -4
  40. package/components/common/utils/{scrollIntoView.js → scrollIntoViewIfNeeded.js} +1 -1
  41. package/components/common/utils/setPrimaryColor.js +18 -18
  42. package/components/common/utils/setTheme.js +8 -9
  43. package/components/common/utils/toArray.js +12 -0
  44. package/copy/index.js +3 -2
  45. package/details/index.js +102 -62
  46. package/dist/scroll-into-view-if-needed/compute/index.js +126 -0
  47. package/dist/scroll-into-view-if-needed/smooth/index.js +70 -0
  48. package/dist/scroll-into-view-if-needed/src/index.js +19 -19
  49. package/divider/index.js +27 -21
  50. package/empty/index.js +13 -13
  51. package/flex/index.js +43 -55
  52. package/flex/interface.js +1 -34
  53. package/form/FormItem.js +69 -65
  54. package/form/context.js +6 -7
  55. package/grid/Col-.js +86 -0
  56. package/grid/Col.js +156 -73
  57. package/grid/Grid.js +71 -67
  58. package/grid/Row.js +3 -3
  59. package/grid/index.js +13 -13
  60. package/icon/interface.js +1 -0
  61. package/icon-hover/interface.js +1 -0
  62. package/index.js +641 -663
  63. package/input/Textarea.js +1 -1
  64. package/input/autoSizeTextAreaHeight.js +7 -7
  65. package/liquid-fill/index.js +5 -4
  66. package/list/index.js +1 -1
  67. package/loading/index.js +72 -53
  68. package/loading/interface.js +1 -0
  69. package/marquee/index.js +5 -4
  70. package/menu/Item.js +9 -9
  71. package/modal/Modal.js +73 -74
  72. package/package.json +1 -1
  73. package/portal/interface.js +1 -0
  74. package/qr-code/index.js +5 -4
  75. package/segmented/index.js +47 -47
  76. package/space/index.js +41 -35
  77. package/speech-synthesis/interface.js +1 -0
  78. package/splitter/SplitBar.js +81 -79
  79. package/splitter/Splitter.js +92 -104
  80. package/splitter/hooks/useItems.js +1 -1
  81. package/splitter/hooks/useResizable.js +9 -18
  82. package/splitter/hooks/useResize.js +10 -10
  83. package/splitter/hooks/useSizes.js +28 -28
  84. package/splitter/index.js +5 -4
  85. package/statistic/index.js +10 -10
  86. package/style.css +1 -1
  87. package/suspense-fallback-test/index.js +2 -11
  88. package/suspense-fallback-test/interface.js +1 -0
  89. package/table/Table.js +376 -377
  90. package/table/hook/useThResizable.js +5 -4
  91. package/table/th-resizable/index.js +12 -11
  92. package/time-picker/util.js +8 -8
  93. package/tooltip/index.js +1 -2
  94. package/tour/index.js +5 -4
  95. package/tree/NodeList.js +1 -1
  96. package/trigger/index.js +67 -70
  97. package/types/common/development/index.d.ts +7 -1
  98. package/types/common/development/interface.d.ts +22 -0
  99. package/types/common/empty/index.d.ts +2 -1
  100. package/types/common/flex/index.d.ts +14 -0
  101. package/types/common/flex/interface.d.ts +62 -0
  102. package/types/common/higher-order/with-speech-synthesis/index.d.ts +6 -1
  103. package/types/common/higher-order/with-speech-synthesis/interface.d.ts +13 -0
  104. package/types/common/space/index.d.ts +4 -4
  105. package/types/common/space/interface.d.ts +10 -18
  106. package/types/common/suspense-fallback-test/index.d.ts +7 -0
  107. package/types/common/suspense-fallback-test/interface.d.ts +1 -0
  108. package/types/common/utils/PqbCSSTransition.d.ts +1 -1
  109. package/types/common/utils/constant.d.ts +1 -0
  110. package/types/common/utils/scrollIntoViewIfNeeded.d.ts +4 -0
  111. package/types/common/utils/toArray.d.ts +13 -0
  112. package/types/common/utils/tree.d.ts +1 -0
  113. package/types/common/utils/tween.d.ts +1 -0
  114. package/types/pc/alert/index.d.ts +2 -1
  115. package/types/pc/alert/interface.d.ts +7 -1
  116. package/types/pc/anchor/util.d.ts +1 -1
  117. package/types/pc/badge/Count.d.ts +1 -1
  118. package/types/pc/badge/interface.d.ts +2 -0
  119. package/types/pc/breadcrumb/Item.d.ts +1 -1
  120. package/types/pc/calendar/Month.d.ts +1 -1
  121. package/types/pc/calendar/WeekList.d.ts +1 -1
  122. package/types/pc/calendar/Year.d.ts +1 -1
  123. package/types/pc/calendar/header/Panel.d.ts +1 -1
  124. package/types/pc/calendar/header/index.d.ts +1 -1
  125. package/types/pc/calendar/index.d.ts +1 -1
  126. package/types/pc/calendar/interface.d.ts +2 -1
  127. package/types/pc/card/interface.d.ts +8 -0
  128. package/types/pc/cascader/interface.d.ts +1 -1
  129. package/types/pc/cascader/panel/List.d.ts +1 -1
  130. package/types/pc/cascader/panel/Option.d.ts +1 -1
  131. package/types/pc/cascader/panel/Search.d.ts +1 -1
  132. package/types/pc/checkbox/Group.d.ts +2 -2
  133. package/types/pc/checkbox/GroupBlock.d.ts +1 -1
  134. package/types/pc/checkbox/IconCheck.d.ts +1 -1
  135. package/types/pc/color-picker/InputRgb.d.ts +1 -1
  136. package/types/pc/color-picker/Palette.d.ts +1 -1
  137. package/types/pc/color-picker/hooks/useColorPicker.d.ts +7 -2
  138. package/types/pc/color-picker/utils.d.ts +6 -1
  139. package/types/pc/config-provider/ConfigProvider.d.ts +1 -1
  140. package/types/pc/config-provider/interface.d.ts +4 -0
  141. package/types/pc/copy/index.d.ts +1 -1
  142. package/types/pc/date-picker/panel/Body.d.ts +1 -1
  143. package/types/pc/date-picker/panel/Footer.d.ts +1 -1
  144. package/types/pc/date-picker/panel/Header.d.ts +1 -1
  145. package/types/pc/date-picker/panel/WeekList.d.ts +1 -1
  146. package/types/pc/date-picker/panel/date/index.d.ts +1 -1
  147. package/types/pc/date-picker/panel/month/index.d.ts +1 -1
  148. package/types/pc/date-picker/panel/quarter/index.d.ts +1 -1
  149. package/types/pc/date-picker/panel/range/index.d.ts +1 -1
  150. package/types/pc/date-picker/panel/week/index.d.ts +1 -1
  151. package/types/pc/date-picker/panel/year/index.d.ts +1 -1
  152. package/types/pc/descriptions/index.d.ts +1 -1
  153. package/types/pc/details/index.d.ts +3 -2
  154. package/types/pc/details/interface.d.ts +16 -0
  155. package/types/pc/development/index.d.ts +2 -1
  156. package/types/pc/development/interface.d.ts +15 -0
  157. package/types/pc/divider/index.d.ts +7 -2
  158. package/types/pc/draggable/Item.d.ts +1 -1
  159. package/types/pc/draggable/index.d.ts +1 -1
  160. package/types/pc/flex/index.d.ts +4 -4
  161. package/types/pc/flex/interface.d.ts +8 -53
  162. package/types/pc/form/Control.d.ts +1 -1
  163. package/types/pc/form/FormItem.d.ts +1 -1
  164. package/types/pc/form/FormList.d.ts +1 -1
  165. package/types/pc/form/IconSymbol.d.ts +1 -1
  166. package/types/pc/grid/Col-.d.ts +4 -0
  167. package/types/pc/grid/Col.d.ts +3 -2
  168. package/types/pc/grid/Grid.d.ts +2 -2
  169. package/types/pc/grid/Item.d.ts +3 -3
  170. package/types/pc/grid/Row.d.ts +2 -2
  171. package/types/pc/grid/hook/useResponsiveState.d.ts +2 -2
  172. package/types/pc/grid/interface.d.ts +13 -7
  173. package/types/pc/icon/addFromIconFontCn.d.ts +1 -7
  174. package/types/pc/icon/index.d.ts +2 -7
  175. package/types/pc/icon/interface.d.ts +13 -0
  176. package/types/pc/icon-hover/index.d.ts +2 -8
  177. package/types/pc/icon-hover/interface.d.ts +8 -0
  178. package/types/pc/image/ImageFooter.d.ts +1 -1
  179. package/types/pc/image/ImagePreviewArrow.d.ts +1 -1
  180. package/types/pc/image/TriggerForToolbar.d.ts +1 -1
  181. package/types/pc/index.d.ts +60 -51
  182. package/types/pc/loading/index.d.ts +4 -3
  183. package/types/pc/loading/interface.d.ts +6 -0
  184. package/types/pc/menu/Indent.d.ts +1 -1
  185. package/types/pc/menu/OverflowWrap.d.ts +1 -1
  186. package/types/pc/menu/sub-menu/Inline.d.ts +1 -1
  187. package/types/pc/menu/sub-menu/Pop.d.ts +1 -1
  188. package/types/pc/overflow-ellipsis/OverflowItem.d.ts +1 -1
  189. package/types/pc/overflow-ellipsis/index.d.ts +1 -1
  190. package/types/pc/pagination/PageItem.d.ts +3 -3
  191. package/types/pc/pagination/PageJumper.d.ts +1 -1
  192. package/types/pc/pagination/PageOption.d.ts +1 -1
  193. package/types/pc/portal/Portal.d.ts +2 -6
  194. package/types/pc/portal/index.d.ts +2 -9
  195. package/types/pc/portal/interface.d.ts +14 -0
  196. package/types/pc/progress/CircleProgress.d.ts +1 -1
  197. package/types/pc/progress/LineProgess.d.ts +1 -1
  198. package/types/pc/progress/StepProgress.d.ts +1 -1
  199. package/types/pc/radio/Group.d.ts +2 -2
  200. package/types/pc/radio/GroupBlock.d.ts +1 -1
  201. package/types/pc/radio/Radio.d.ts +1 -1
  202. package/types/pc/resize-box/ResizeTrigger.d.ts +1 -1
  203. package/types/pc/result/403.d.ts +1 -1
  204. package/types/pc/result/404.d.ts +1 -1
  205. package/types/pc/result/500.d.ts +1 -1
  206. package/types/pc/segmented/interface.d.ts +6 -6
  207. package/types/pc/skeleton/Image.d.ts +1 -1
  208. package/types/pc/skeleton/Text.d.ts +2 -1
  209. package/types/pc/slider/Button.d.ts +1 -1
  210. package/types/pc/slider/Input.d.ts +1 -1
  211. package/types/pc/slider/Tick.d.ts +1 -1
  212. package/types/pc/space/index.d.ts +6 -5
  213. package/types/pc/speech-synthesis/index.d.ts +3 -1
  214. package/types/pc/speech-synthesis/interface.d.ts +7 -0
  215. package/types/pc/spin/DotLoading.d.ts +1 -1
  216. package/types/pc/splitter/SplitBar.d.ts +0 -1
  217. package/types/pc/splitter/hooks/useResizable.d.ts +0 -1
  218. package/types/pc/splitter/hooks/useResize.d.ts +1 -2
  219. package/types/pc/splitter/index.d.ts +5 -4
  220. package/types/pc/splitter/interface.d.ts +16 -24
  221. package/types/pc/suspense-fallback-test/index.d.ts +2 -3
  222. package/types/pc/suspense-fallback-test/interface.d.ts +2 -0
  223. package/types/pc/table/ColGroup.d.ts +1 -1
  224. package/types/pc/table/summary/Cell.d.ts +1 -1
  225. package/types/pc/table/summary/Row.d.ts +1 -1
  226. package/types/pc/table/tbody/Td.d.ts +1 -1
  227. package/types/pc/table/tbody/index.d.ts +1 -1
  228. package/types/pc/table/tfoot/index.d.ts +1 -1
  229. package/types/pc/table/th-resizable/index.d.ts +1 -1
  230. package/types/pc/table/thead/Column.d.ts +1 -1
  231. package/types/pc/table/thead/index.d.ts +1 -1
  232. package/types/pc/tabs/TabContent.d.ts +1 -1
  233. package/types/pc/tabs/tab-header/DropdownIcon.d.ts +1 -1
  234. package/types/pc/tabs/tab-header/TabInk.d.ts +1 -1
  235. package/types/pc/tabs/tab-header/TabNavIcon.d.ts +1 -1
  236. package/types/pc/time-picker/Picker.d.ts +1 -1
  237. package/types/pc/time-picker/RangePicker.d.ts +1 -1
  238. package/types/pc/time-picker/TimeColumn.d.ts +1 -1
  239. package/types/pc/time-picker/TimePicker.d.ts +1 -1
  240. package/types/pc/time-picker/index.d.ts +1 -1
  241. package/types/pc/tour/index.d.ts +1 -1
  242. package/types/pc/transfer/Item.d.ts +1 -1
  243. package/types/pc/transfer/List.d.ts +1 -1
  244. package/types/pc/tree/Animation.d.ts +1 -1
  245. package/types/pc/typography/Operations.d.ts +1 -1
  246. package/types/pc/upload/interface.d.ts +1 -0
  247. package/types/pc/upload/list/index.d.ts +1 -1
  248. package/types/pc/utils/constant.d.ts +1 -2
  249. package/types/pc/utils/dayjs.d.ts +2 -1
  250. package/types/pc/utils/index.d.ts +2 -5
  251. package/types/pc/utils/scrollIntoViewIfNeeded.d.ts +3 -0
  252. package/types/pc/utils/toArray.d.ts +1 -5
  253. package/types/pc/utils/tree.d.ts +2 -1
  254. package/types/pc/utils/tween.d.ts +1 -1
  255. package/types/pc/verification-code/VerificationCode.d.ts +1 -1
  256. package/types/pc/virtual-list/VirtualList.d.ts +2 -38
  257. package/types/pc/virtual-list/index.d.ts +2 -1
  258. package/types/pc/virtual-list/interface.d.ts +56 -0
  259. package/types/pc/watermark/Watermark.d.ts +1 -1
  260. package/typography/Ellipsis.js +5 -4
  261. package/typography/Operations.js +5 -4
  262. package/upload/request.js +12 -13
  263. package/upload/request_.js +2 -3
  264. package/utils/constant.js +5 -5
  265. package/utils/dayjs.js +13 -12
  266. package/utils/index.js +261 -284
  267. package/utils/scrollIntoViewIfNeeded.js +12 -0
  268. package/utils/toArray.js +3 -10
  269. package/utils/tree.js +11 -9
  270. package/utils/tween.js +5 -5
  271. package/version/index.js +1 -1
  272. package/virtual-list/interface.js +1 -0
  273. package/components/common/space/toArray.js +0 -11
  274. package/components/common/utils/convertToDurationBasedOnTimeUnits.js +0 -6
  275. package/dist/compute-scroll-into-view/src/index.js +0 -126
  276. package/dist/tinycolor/chunk/BOzCVdr0.js +0 -182
  277. package/dist/tinycolor/customize/index.js +0 -12
  278. package/dist/tinycolor/src/conversion.js +0 -143
  279. package/dist/tinycolor/src/css-color-names.js +0 -153
  280. package/dist/tinycolor/src/format-input.js +0 -77
  281. package/dist/tinycolor/src/index.js +0 -388
  282. package/dist/tinycolor/src/util.js +0 -32
  283. package/flex/utils.js +0 -13
  284. package/loading/style/index.module.less.js +0 -4
  285. package/types/common/space/toArray.d.ts +0 -3
  286. package/types/common/utils/convertToDurationBasedOnTimeUnits.d.ts +0 -3
  287. package/types/common/utils/scrollIntoView.d.ts +0 -4
  288. package/types/common/utils/tinycolor.d.ts +0 -1
  289. package/types/pc/flex/utils.d.ts +0 -9
  290. package/types/pc/suspense-fallback-test/style/index.d.ts +0 -1
  291. package/types/pc/utils/color.d.ts +0 -1
  292. package/types/pc/utils/computeScrollIntoView.d.ts +0 -1
  293. package/types/pc/utils/convertToDurationBasedOnTimeUnits.d.ts +0 -3
  294. package/types/pc/utils/scrollIntoView.d.ts +0 -3
  295. package/types/pc/utils/tinycolor.d.ts +0 -1
  296. package/utils/color.js +0 -4
  297. package/utils/computeScrollIntoView.js +0 -6
  298. package/utils/convertToDurationBasedOnTimeUnits.js +0 -6
  299. package/utils/scrollIntoView.js +0 -6
  300. package/utils/tinycolor.js +0 -29
  301. /package/{suspense-fallback-test/style/index.less.js → development/interface.js} +0 -0
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
2
  import { TransferListProps } from './interface';
3
- export declare const TransferList: (props: TransferListProps, ref: any) => import("react/jsx-dev-runtime").JSX.Element;
3
+ export declare const TransferList: (props: TransferListProps, ref: any) => import("react/jsx-runtime").JSX.Element;
4
4
  declare const TransferListComponent: React.ForwardRefExoticComponent<TransferListProps & React.RefAttributes<unknown>>;
5
5
  export default TransferListComponent;
@@ -1,4 +1,4 @@
1
1
  import { PropsWithChildren } from 'react';
2
2
  import { NodeProps } from './interface';
3
- declare const TreeAnimation: (props: PropsWithChildren<NodeProps>) => import("react/jsx-dev-runtime").JSX.Element;
3
+ declare const TreeAnimation: (props: PropsWithChildren<NodeProps>) => import("react/jsx-runtime").JSX.Element;
4
4
  export default TreeAnimation;
@@ -1,4 +1,4 @@
1
1
  import { PropsWithChildren } from 'react';
2
2
  import { OperationsProps } from './interface';
3
- declare function Operations(props: PropsWithChildren<OperationsProps>): import("react/jsx-dev-runtime").JSX.Element;
3
+ declare function Operations(props: PropsWithChildren<OperationsProps>): import("react/jsx-runtime").JSX.Element;
4
4
  export default Operations;
@@ -256,6 +256,7 @@ export interface UploadListProps {
256
256
  renderUploadItem?: (originNode: ReactNode, file: UploadItem, fileList: UploadItem[]) => ReactNode;
257
257
  renderUploadList?: (fileList: UploadItem[], uploadListProps: Omit<UploadListProps, 'renderUploadList'>) => ReactNode;
258
258
  prefixCls?: string;
259
+ onChange?: (o: object) => void;
259
260
  }
260
261
  /**
261
262
  * @title UploadItem
@@ -1,6 +1,6 @@
1
1
  import { UploadListProps } from '../../upload/interface';
2
2
  export declare const FileList: {
3
- (props: UploadListProps): import("react/jsx-dev-runtime").JSX.Element;
3
+ (props: UploadListProps): import("react/jsx-runtime").JSX.Element;
4
4
  displayName: string;
5
5
  };
6
6
  export default FileList;
@@ -1,4 +1,3 @@
1
- export { UI_PC_KEY, UI_PC_THEME_DARK_CLASS_NAME, } from '@unicom-cloud/utils/constant/ui';
2
- export { NOOP } from '../../common/utils/constant';
1
+ export { NOOP, UI_PC_KEY, UI_PC_THEME_DARK_CLASS_NAME, } from '../../common/utils/constant';
3
2
  export declare function newArray(length: number): any[];
4
3
  export declare function pickTriggerPropsFromRest(rest: object): Pick<object, never>;
@@ -1 +1,2 @@
1
- export { dayjs, getDayjsValue, getNow, getSortedDayjsArray, getTimeFormat, getValueWithTime, isDayjsArrayChange, isDayjsChange, isValidTimeString, methods, timezoneToOffset, toLocal, toTimezone, } from '../../common/utils/dayjs';
1
+ export * from '../../common/utils/dayjs';
2
+ export { default } from '../../common/utils/dayjs';
@@ -1,10 +1,8 @@
1
+ export * from '@unicom-cloud/utils/date';
1
2
  export * from './caseName';
2
3
  export * from './className';
3
- export * from './color';
4
- export * from './computeScrollIntoView';
5
4
  export * from './constant';
6
5
  export * from './contextHolder';
7
- export * from './convertToDurationBasedOnTimeUnits';
8
6
  export * from './copy';
9
7
  export * from './dayjs';
10
8
  export * from './dom';
@@ -33,13 +31,12 @@ export * from './resizeObserver';
33
31
  export * from './responsiveObserve';
34
32
  export * from './saveAs';
35
33
  export * from './screenfull';
36
- export * from './scrollIntoView';
34
+ export * from './scrollIntoViewIfNeeded';
37
35
  export * from './setDarkTheme';
38
36
  export * from './setPrimaryColor';
39
37
  export * from './setTheme';
40
38
  export * from './style';
41
39
  export * from './throttleByRaf';
42
- export * from './tinycolor';
43
40
  export * from './toArray';
44
41
  export * from './tree';
45
42
  export * from './tween';
@@ -0,0 +1,3 @@
1
+ import scrollIntoView, { compute, scrollIntoViewIfNeeded, scrollIntoViewIfNeededSmooth, smoothScrollIntoViewIfNeeded } from '../../common/utils/scrollIntoViewIfNeeded';
2
+ export { compute, scrollIntoView, scrollIntoViewIfNeeded, scrollIntoViewIfNeededSmooth, smoothScrollIntoViewIfNeeded, };
3
+ export default scrollIntoView;
@@ -1,7 +1,3 @@
1
- import React from 'react';
2
- interface ToArrayOptions {
3
- keepEmpty?: boolean;
4
- }
5
- declare function toArray(children: React.ReactNode, options?: ToArrayOptions): React.ReactElement[];
1
+ import toArray from '../../common/utils/toArray';
6
2
  export { toArray };
7
3
  export default toArray;
@@ -1 +1,2 @@
1
- export { default, findNodeBy, getChildWithParentBy, getItemBy, getItemBy2, getItemBy3, getItemByID, getLabelFromDictionaryByValue, } from '@unicom-cloud/utils/tree';
1
+ export * from '../../common/utils/tree';
2
+ export { default } from '../../common/utils/tree';
@@ -1 +1 @@
1
- export { default, easing, default as tween } from '@unicom-cloud/tween';
1
+ export { default, easing, Tween } from '../../common/utils/tween';
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
2
  import { VerificationCodeProps } from './interface';
3
- export declare function VerificationCodeComponent(baseProps: VerificationCodeProps, _: any): import("react/jsx-dev-runtime").JSX.Element;
3
+ export declare function VerificationCodeComponent(baseProps: VerificationCodeProps, _: any): import("react/jsx-runtime").JSX.Element;
4
4
  export declare namespace VerificationCodeComponent {
5
5
  var displayName: string;
6
6
  }
@@ -1,40 +1,4 @@
1
- import { Options as ScrollIntoViewOptions } from '@unicom-cloud/scroll-into-view-if-needed';
2
- import React, { CSSProperties, ReactNode, UIEvent } from 'react';
3
- import { Key } from './util/item';
4
- export type RenderFunc<T> = (item: T, index: number, props: {
5
- style: React.CSSProperties;
6
- itemIndex: number;
7
- }) => ReactNode;
8
- export interface VirtualListProps<T> extends Omit<React.HTMLAttributes<any>, 'children' | 'onScroll'> {
9
- children: RenderFunc<T>;
10
- data: T[];
11
- height?: number | string;
12
- itemHeight?: number;
13
- wrapper?: string | React.FC<any> | React.ComponentClass<any>;
14
- threshold?: number | null;
15
- isStaticItemHeight?: boolean;
16
- itemKey?: Key | ((item: T, index: number) => Key);
17
- measureLongestItem?: boolean;
18
- scrollOptions?: ScrollIntoViewOptions;
19
- needFiller?: boolean;
20
- /** Custom filler outer style */
21
- outerStyle?: CSSProperties;
22
- innerStyle?: CSSProperties;
23
- onScroll?: (event: UIEvent<HTMLElement>, info: {
24
- index: number;
25
- }) => void;
26
- wrapperChild?: string | React.FC<any> | React.ComponentClass<any>;
27
- }
28
- export type AvailableVirtualListProps = Pick<VirtualListProps<any>, 'height' | 'itemHeight' | 'threshold' | 'isStaticItemHeight' | 'scrollOptions' | 'onScroll' | 'wrapperChild'>;
29
- export type VirtualListHandle = {
30
- dom: HTMLElement;
31
- scrollTo: (arg: number | {
32
- index: number;
33
- options?: ScrollIntoViewOptions;
34
- } | {
35
- key: Key;
36
- options?: ScrollIntoViewOptions;
37
- }) => void;
38
- };
1
+ import React from 'react';
2
+ import type { VirtualListHandle, VirtualListProps } from './interface';
39
3
  declare const VirtualList: React.ForwardRefExoticComponent<VirtualListProps<any> & React.RefAttributes<VirtualListHandle>>;
40
4
  export default VirtualList;
@@ -1,3 +1,4 @@
1
1
  import VirtualList from './VirtualList';
2
+ import type { AvailableVirtualListProps, RenderFunc, VirtualListHandle } from './interface';
2
3
  export default VirtualList;
3
- export type { AvailableVirtualListProps, RenderFunc, VirtualListHandle, } from './VirtualList';
4
+ export type { AvailableVirtualListProps, RenderFunc, VirtualListHandle };
@@ -0,0 +1,56 @@
1
+ import { Options as ScrollIntoViewOptions } from '@unicom-cloud/scroll-into-view-if-needed';
2
+ import React, { CSSProperties, ReactNode, UIEvent } from 'react';
3
+ import { Key } from './util/item';
4
+ export type RenderFunc<T> = (item: T, index: number, props: {
5
+ style: React.CSSProperties;
6
+ itemIndex: number;
7
+ }) => ReactNode;
8
+ type Status = 'NONE' | 'MEASURE_START' | 'MEASURE_DONE';
9
+ export interface VirtualListProps<T> extends Omit<React.HTMLAttributes<any>, 'children' | 'onScroll'> {
10
+ children: RenderFunc<T>;
11
+ data: T[];
12
+ height?: number | string;
13
+ itemHeight?: number;
14
+ wrapper?: string | React.FC<any> | React.ComponentClass<any>;
15
+ threshold?: number | null;
16
+ isStaticItemHeight?: boolean;
17
+ itemKey?: Key | ((item: T, index: number) => Key);
18
+ measureLongestItem?: boolean;
19
+ scrollOptions?: ScrollIntoViewOptions;
20
+ needFiller?: boolean;
21
+ /** Custom filler outer style */
22
+ outerStyle?: CSSProperties;
23
+ innerStyle?: CSSProperties;
24
+ onScroll?: (event: UIEvent<HTMLElement>, info: {
25
+ index: number;
26
+ }) => void;
27
+ wrapperChild?: string | React.FC<any> | React.ComponentClass<any>;
28
+ }
29
+ export type AvailableVirtualListProps = Pick<VirtualListProps<any>, 'height' | 'itemHeight' | 'threshold' | 'isStaticItemHeight' | 'scrollOptions' | 'onScroll' | 'wrapperChild'>;
30
+ export interface RelativeScroll {
31
+ itemIndex: number;
32
+ relativeTop: number;
33
+ }
34
+ export interface VirtualListState {
35
+ status: Status;
36
+ startIndex: number;
37
+ endIndex: number;
38
+ itemIndex: number;
39
+ itemOffsetPtg: number;
40
+ startItemTop: number;
41
+ scrollTop: number;
42
+ }
43
+ export type VirtualListHandle = {
44
+ dom: HTMLElement;
45
+ scrollTo: (arg: number | {
46
+ index: number;
47
+ options?: ScrollIntoViewOptions;
48
+ } | {
49
+ key: Key;
50
+ options?: ScrollIntoViewOptions;
51
+ }) => void;
52
+ };
53
+ export type ItemHeightMap = {
54
+ [p: string]: number;
55
+ };
56
+ export {};
@@ -1,4 +1,4 @@
1
1
  import { WatermarkProps } from './interface';
2
- export declare function WatermarkComponent(baseProps: WatermarkProps, _: any): import("react/jsx-dev-runtime").JSX.Element | null;
2
+ export declare function WatermarkComponent(baseProps: WatermarkProps, _: any): import("react/jsx-runtime").JSX.Element | null;
3
3
  declare const Watermark: import("react").ForwardRefExoticComponent<WatermarkProps & import("react").RefAttributes<unknown>>;
4
4
  export default Watermark;
@@ -5,12 +5,11 @@ import Y from "../copy/index.js";
5
5
  import Z from "../components/common/hooks/useMergeProps.js";
6
6
  import tt from "../components/common/hooks/useMergeValue.js";
7
7
  import et from "../tooltip/index.js";
8
+ import "@unicom-cloud/utils/date";
8
9
  import "@unicom-cloud/utils/case-name";
9
10
  import n from "@unicom-cloud/utils/class-name";
10
- import "../dist/tinycolor/chunk/BOzCVdr0.js";
11
11
  import "@unicom-cloud/utils/constant/ui";
12
12
  import "../utils/contextHolder.js";
13
- import "@unicom-cloud/utils/dayjs";
14
13
  import "@unicom-cloud/utils/clipboard-copy";
15
14
  import "../components/common/utils/dayjs.js";
16
15
  import { isServerRendering as rt } from "../components/common/utils/dom.js";
@@ -48,6 +47,8 @@ import "../components/common/utils/reactDOM.js";
48
47
  import { resizeObserver as it } from "../components/common/utils/resizeObserver.js";
49
48
  import "@unicom-cloud/utils/file/saveAs";
50
49
  import "@unicom-cloud/utils/screenfull";
50
+ import "@unicom-cloud/utils/tinycolor";
51
+ import "@unicom-cloud/utils/ui-color";
51
52
  import "@unicom-cloud/utils/constant/ui.js";
52
53
  import "lodash/isPlainObject";
53
54
  import { throttleByRaf as nt } from "../components/common/utils/throttleByRaf.js";
@@ -216,7 +217,7 @@ const pt = {
216
217
  I(),
217
218
  J()
218
219
  ] });
219
- }, $e = Q(at);
220
+ }, ge = Q(at);
220
221
  export {
221
- $e as default
222
+ ge as default
222
223
  };
@@ -6,12 +6,11 @@ import { useEffect as F } from "react";
6
6
  import O from "../copy/index.js";
7
7
  import w from "../components/common/hooks/useKeyboardEvent.js";
8
8
  import A from "../tooltip/index.js";
9
+ import "@unicom-cloud/utils/date";
9
10
  import "@unicom-cloud/utils/case-name";
10
11
  import "@unicom-cloud/utils/class-name";
11
- import "../dist/tinycolor/chunk/BOzCVdr0.js";
12
12
  import "@unicom-cloud/utils/constant/ui";
13
13
  import "../utils/contextHolder.js";
14
- import "@unicom-cloud/utils/dayjs";
15
14
  import "@unicom-cloud/utils/clipboard-copy";
16
15
  import "../components/common/utils/dayjs.js";
17
16
  import "../components/common/utils/dom.js";
@@ -47,6 +46,8 @@ import "../dist/react-transition-group/src/TransitionGroup.js";
47
46
  import "../components/common/utils/reactDOM.js";
48
47
  import "@unicom-cloud/utils/file/saveAs";
49
48
  import "@unicom-cloud/utils/screenfull";
49
+ import "@unicom-cloud/utils/tinycolor";
50
+ import "@unicom-cloud/utils/ui-color";
50
51
  import "@unicom-cloud/utils/constant/ui.js";
51
52
  import "react-is";
52
53
  import "@unicom-cloud/utils/tree";
@@ -54,7 +55,7 @@ import { isFunction as K } from "@unicom-cloud/utils/is";
54
55
  import "uuid";
55
56
  import "../dist/validate/src/index.js";
56
57
  import "@unicom-cloud/utils/constant/keyboardCode";
57
- function zo(u) {
58
+ function Bo(u) {
58
59
  const {
59
60
  children: s,
60
61
  copyable: i,
@@ -120,5 +121,5 @@ function zo(u) {
120
121
  ] });
121
122
  }
122
123
  export {
123
- zo as default
124
+ Bo as default
124
125
  };
package/upload/request.js CHANGED
@@ -1,18 +1,17 @@
1
- import "@unicom-cloud/utils/constant/ui";
2
1
  import { NOOP as c } from "../components/common/utils/constant.js";
3
- function d(n) {
4
- const o = n.responseText || n.response;
5
- if (!o)
6
- return o;
2
+ function d(o) {
3
+ const n = o.responseText || o.response;
4
+ if (!n)
5
+ return n;
7
6
  try {
8
- return JSON.parse(o);
7
+ return JSON.parse(n);
9
8
  } catch {
10
- return o;
9
+ return n;
11
10
  }
12
11
  }
13
- const x = function(n) {
12
+ const q = function(o) {
14
13
  const {
15
- onProgress: o = c,
14
+ onProgress: n = c,
16
15
  onError: s = c,
17
16
  onSuccess: l = c,
18
17
  action: m,
@@ -22,14 +21,14 @@ const x = function(n) {
22
21
  file: f,
23
22
  data: w = {},
24
23
  withCredentials: O = !1
25
- } = n;
24
+ } = o;
26
25
  function p(t) {
27
26
  return typeof t == "function" ? t(f) : t;
28
27
  }
29
28
  const y = p(g), i = p(w), e = new XMLHttpRequest();
30
- o && e.upload && (e.upload.onprogress = function(t) {
29
+ n && e.upload && (e.upload.onprogress = function(t) {
31
30
  let a;
32
- t.total > 0 && (a = t.loaded / t.total * 100), o(parseInt(a, 10), t);
31
+ t.total > 0 && (a = t.loaded / t.total * 100), n(parseInt(a, 10), t);
33
32
  }), e.onerror = function(a) {
34
33
  s(a);
35
34
  }, e.onload = function() {
@@ -48,5 +47,5 @@ const x = function(n) {
48
47
  };
49
48
  };
50
49
  export {
51
- x as default
50
+ q as default
52
51
  };
@@ -1,9 +1,8 @@
1
1
  import P from "axios";
2
- import "@unicom-cloud/utils/constant/ui";
3
2
  import { NOOP as e } from "../components/common/utils/constant.js";
4
3
  import "../components/common/utils/is.js";
5
4
  import { isPlainObject as x, isFunction as y } from "@unicom-cloud/utils/is";
6
- const q = (f) => {
5
+ const N = (f) => {
7
6
  const {
8
7
  onProgress: m = e,
9
8
  onError: n = e,
@@ -59,5 +58,5 @@ const q = (f) => {
59
58
  };
60
59
  };
61
60
  export {
62
- q as default
61
+ N as default
63
62
  };
package/utils/constant.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { pick as r } from "../components/common/utils/pick.js";
2
- import { UI_PC_KEY as p, UI_PC_THEME_DARK_CLASS_NAME as M } from "@unicom-cloud/utils/constant/ui";
3
- import { NOOP as c } from "../components/common/utils/constant.js";
2
+ import { NOOP as p } from "../components/common/utils/constant.js";
3
+ import { UI_PC_KEY as _, UI_PC_THEME_DARK_CLASS_NAME as c } from "@unicom-cloud/utils/constant/ui";
4
4
  function n(o) {
5
5
  return Array.from(new Array(o));
6
6
  }
@@ -17,9 +17,9 @@ function t(o) {
17
17
  ]);
18
18
  }
19
19
  export {
20
- c as NOOP,
21
- p as UI_PC_KEY,
22
- M as UI_PC_THEME_DARK_CLASS_NAME,
20
+ p as NOOP,
21
+ _ as UI_PC_KEY,
22
+ c as UI_PC_THEME_DARK_CLASS_NAME,
23
23
  n as newArray,
24
24
  t as pickTriggerPropsFromRest
25
25
  };
package/utils/dayjs.js CHANGED
@@ -1,16 +1,17 @@
1
- import { dayjs as a, getDayjsValue as o, getNow as i, getSortedDayjsArray as s, getTimeFormat as r, getValueWithTime as g, isDayjsArrayChange as m, isDayjsChange as y, isValidTimeString as j, methods as n, timezoneToOffset as T, toLocal as d, toTimezone as h } from "../components/common/utils/dayjs.js";
1
+ import { dayjs as t, dayjs as o, getDayjsValue as s, getNow as i, getSortedDayjsArray as r, getTimeFormat as g, getValueWithTime as m, isDayjsArrayChange as y, isDayjsChange as d, isValidTimeString as j, methods as l, timezoneToOffset as n, toLocal as T, toTimezone as f } from "../components/common/utils/dayjs.js";
2
2
  export {
3
- a as dayjs,
4
- o as getDayjsValue,
3
+ t as dayjs,
4
+ o as default,
5
+ s as getDayjsValue,
5
6
  i as getNow,
6
- s as getSortedDayjsArray,
7
- r as getTimeFormat,
8
- g as getValueWithTime,
9
- m as isDayjsArrayChange,
10
- y as isDayjsChange,
7
+ r as getSortedDayjsArray,
8
+ g as getTimeFormat,
9
+ m as getValueWithTime,
10
+ y as isDayjsArrayChange,
11
+ d as isDayjsChange,
11
12
  j as isValidTimeString,
12
- n as methods,
13
- T as timezoneToOffset,
14
- d as toLocal,
15
- h as toTimezone
13
+ l as methods,
14
+ n as timezoneToOffset,
15
+ T as toLocal,
16
+ f as toTimezone
16
17
  };