@unicom-cloud/ui 0.8.96 → 0.8.98

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 (302) hide show
  1. package/Affix.js +1 -1
  2. package/Carousel.js +1 -1
  3. package/LiquidFill.js +4 -0
  4. package/OverflowEllipsis.js +1 -1
  5. package/PageHeader.js +1 -1
  6. package/QrCode.js +57 -0
  7. package/Tour.js +63 -0
  8. package/Trigger.js +1 -1
  9. package/_virtual/_commonjsHelpers.js +6 -0
  10. package/_virtual/index.js +7 -0
  11. package/_virtual/index2.js +4 -0
  12. package/affix/index.js +70 -72
  13. package/alert/index.js +56 -56
  14. package/anchor/Anchor.js +55 -55
  15. package/anchor/Link.js +34 -34
  16. package/anchor/util.js +5 -5
  17. package/auto-complete/index.js +116 -122
  18. package/avatar/Avatar.js +33 -33
  19. package/avatar/Group.js +26 -26
  20. package/back-top/index.js +58 -61
  21. package/badge/index.js +46 -46
  22. package/breadcrumb/Item.js +42 -43
  23. package/breadcrumb/index.js +47 -47
  24. package/button/Group.js +6 -6
  25. package/button/index.js +91 -91
  26. package/calendar/Month.js +75 -75
  27. package/calendar/Year.js +35 -35
  28. package/calendar/header/index.js +25 -25
  29. package/calendar/index.js +103 -103
  30. package/card/Grid.js +8 -8
  31. package/card/Meta.js +16 -16
  32. package/card/index.js +49 -49
  33. package/carousel/Arrow.js +19 -19
  34. package/carousel/Indicator.js +26 -26
  35. package/carousel/index.js +108 -108
  36. package/cascader/Cascader.js +178 -191
  37. package/cascader/base/node.js +133 -136
  38. package/cascader/base/store.js +82 -85
  39. package/cascader/panel/List.js +125 -129
  40. package/cascader/panel/Search.js +79 -81
  41. package/cascader/util.js +13 -13
  42. package/checkbox/Checkbox.js +94 -96
  43. package/checkbox/Group.js +54 -56
  44. package/checkbox/GroupBlock.js +28 -29
  45. package/collapse/Collapse.js +45 -45
  46. package/collapse/Item.js +53 -55
  47. package/color-picker/ControlBar.js +43 -43
  48. package/color-picker/InputAlpha.js +12 -12
  49. package/color-picker/InputHex.js +30 -31
  50. package/color-picker/InputRgb.js +24 -24
  51. package/color-picker/Palette.js +18 -18
  52. package/color-picker/Panel.js +122 -125
  53. package/color-picker/hooks/useColorPicker.js +85 -88
  54. package/color-picker/hooks/useControlBlock.js +38 -40
  55. package/color-picker/index.js +47 -47
  56. package/comment/index.js +29 -29
  57. package/components/common/higher-order/with-speech-synthesis/index.js +37 -40
  58. package/components/common/hooks/useId.js +8 -8
  59. package/components/common/hooks/useInView.js +16 -16
  60. package/components/common/hooks/useIntersectionObserver.js +1 -1
  61. package/components/common/hooks/useKeyboardEvent.js +9 -10
  62. package/components/common/hooks/useOverflowHidden.js +1 -4
  63. package/components/common/hooks/usePersistCallback.js +7 -7
  64. package/components/common/hooks/useStateCallback.js +9 -10
  65. package/components/common/hooks/useWindowSize.js +8 -8
  66. package/components/common/space/index.js +9 -7
  67. package/components/common/utils/convertToDurationBasedOnTimeUnits.js +6 -0
  68. package/components/common/utils/dom.js +27 -29
  69. package/components/common/utils/findScrollParent.js +17 -0
  70. package/components/common/utils/intersectionObserver.js +21 -0
  71. package/components/common/utils/is.js +99 -109
  72. package/components/common/utils/mutationObserver.js +19 -0
  73. package/components/common/utils/reactDOM.js +34 -34
  74. package/components/common/utils/resizeObserver.js +21 -0
  75. package/copy/index.js +38 -40
  76. package/date-picker/Picker.js +290 -295
  77. package/date-picker/RangePicker.js +367 -372
  78. package/date-picker/index.js +33 -35
  79. package/date-picker/panel/Body.js +46 -47
  80. package/date-picker/panel/Header.js +33 -33
  81. package/date-picker/panel/Shortcut.js +31 -31
  82. package/date-picker/panel/date/index.js +85 -85
  83. package/date-picker/panel/month/index.js +59 -59
  84. package/date-picker/panel/quarter/index.js +67 -70
  85. package/date-picker/panel/range/index.js +101 -101
  86. package/date-picker/panel/year/index.js +39 -39
  87. package/date-picker/util.js +17 -18
  88. package/descriptions/index.js +62 -62
  89. package/details/index.js +53 -55
  90. package/development/index.js +9 -9
  91. package/dist/tinycolor/chunk/BOzCVdr0.js +1 -1
  92. package/dist/validate/src/index.js +5 -5
  93. package/dist/validate/src/util.js +1 -1
  94. package/divider/index.js +21 -21
  95. package/draggable/Item.js +35 -35
  96. package/draggable/index.js +22 -22
  97. package/drawer/Drawer.js +142 -147
  98. package/dropdown/Button.js +48 -48
  99. package/dropdown/index.js +88 -92
  100. package/empty/index.js +16 -16
  101. package/form/Control.js +211 -225
  102. package/form/Form.js +109 -113
  103. package/form/FormItem.js +118 -120
  104. package/form/FormList.js +60 -66
  105. package/form/FormProvider.js +31 -34
  106. package/form/hook/useContext.js +17 -19
  107. package/form/hook/useState.js +22 -23
  108. package/form/hook/useWatch.js +26 -27
  109. package/form/promisify.js +14 -18
  110. package/form/store.js +304 -316
  111. package/form/util.js +14 -15
  112. package/grid/Col.js +64 -64
  113. package/grid/Grid.js +51 -51
  114. package/grid/GridItem.js +48 -48
  115. package/grid/Row.js +39 -39
  116. package/hooks/useVerificationCode.js +41 -43
  117. package/hooks/useWatermark.js +89 -92
  118. package/icon/index.js +23 -24
  119. package/icon-hover/index.js +16 -16
  120. package/icons/file.js +11 -11
  121. package/image/Image.js +140 -141
  122. package/image/ImagePreview.js +252 -255
  123. package/image/ImagePreviewArrow.js +25 -25
  124. package/image/ImagePreviewGroup.js +62 -62
  125. package/image/util/getScale.js +25 -28
  126. package/index.js +684 -675
  127. package/input/Button.js +48 -50
  128. package/input/Group.js +9 -9
  129. package/input/Input.js +145 -154
  130. package/input/InputElement.js +108 -115
  131. package/input/Password.js +38 -38
  132. package/input/Search.js +51 -55
  133. package/input/Textarea.js +80 -81
  134. package/input/useComposition.js +23 -23
  135. package/input-number/decimal.js +59 -62
  136. package/input-number/index.js +139 -141
  137. package/input-tag/InputTag.js +222 -230
  138. package/layout/Content.js +6 -6
  139. package/layout/Footer.js +8 -8
  140. package/layout/Header.js +7 -7
  141. package/layout/Sider.js +88 -90
  142. package/layout/index.js +30 -30
  143. package/link/index.js +45 -46
  144. package/liquid-fill/LiquidFill.js +226 -0
  145. package/liquid-fill/LiquidFill2.js +3 -0
  146. package/liquid-fill/index.js +4 -0
  147. package/list/Item.js +28 -28
  148. package/list/Meta.js +12 -12
  149. package/list/index.js +146 -148
  150. package/mentions/index.js +75 -76
  151. package/menu/Item.js +58 -58
  152. package/menu/Menu.js +125 -127
  153. package/menu/OverflowWrap.js +39 -40
  154. package/menu/sub-menu/Inline.js +45 -45
  155. package/menu/util.js +26 -28
  156. package/message/index.js +96 -99
  157. package/message/useMessage.js +26 -27
  158. package/modal/Confirm.js +47 -49
  159. package/modal/Modal.js +250 -257
  160. package/modal/use-modal/Hook.js +26 -28
  161. package/modal/use-modal/index.js +46 -49
  162. package/notice/index.js +89 -90
  163. package/notification/index.js +60 -65
  164. package/notification/withNotification.js +35 -35
  165. package/overflow-ellipsis/OverflowItem.js +19 -20
  166. package/overflow-ellipsis/index.js +45 -46
  167. package/package.json +1 -1
  168. package/page-header/index.js +45 -45
  169. package/pagination/PageItem.js +87 -91
  170. package/pagination/PageJumper.js +40 -41
  171. package/pagination/PageOption.js +31 -35
  172. package/pagination/Pagination.js +162 -163
  173. package/picker/Input.js +90 -96
  174. package/picker/InputRange.js +115 -122
  175. package/popconfirm/index.js +98 -100
  176. package/popover/index.js +28 -28
  177. package/portal/Portal.js +10 -11
  178. package/progress/index.js +36 -36
  179. package/qr-code/index.js +99 -0
  180. package/qr-code/interface.js +1 -0
  181. package/radio/Group.js +48 -48
  182. package/radio/GroupBlock.js +32 -33
  183. package/radio/Radio.js +62 -64
  184. package/rate/index.js +88 -88
  185. package/resize-box/ResizeTrigger.js +39 -39
  186. package/resize-box/Split.js +92 -96
  187. package/resize-box/SplitGroup.js +116 -122
  188. package/resize-box/index.js +112 -115
  189. package/result/index.js +44 -44
  190. package/select/Option.js +53 -56
  191. package/select/Select.js +365 -381
  192. package/select/util.js +95 -99
  193. package/select-view/Core.js +159 -160
  194. package/skeleton/index.js +23 -23
  195. package/slider/Button.js +84 -92
  196. package/slider/Input.js +47 -49
  197. package/slider/Tick.js +28 -31
  198. package/slider/index.js +107 -107
  199. package/space/index.js +26 -26
  200. package/space-/index.js +51 -51
  201. package/spin/DotLoading.js +8 -8
  202. package/spin/index.js +47 -47
  203. package/statistic/Countdown.js +37 -37
  204. package/statistic/index.js +58 -58
  205. package/steps/Step.js +42 -42
  206. package/steps/index.js +54 -54
  207. package/style.css +1 -1
  208. package/switch/index.js +77 -78
  209. package/table/ColGroup.js +36 -37
  210. package/table/Table.js +447 -450
  211. package/table/hook/useExpand.js +24 -24
  212. package/table/hook/useRowSelection.js +62 -62
  213. package/table/summary/Row.js +16 -17
  214. package/table/tbody/Td.js +119 -118
  215. package/table/tbody/Tr.js +119 -121
  216. package/table/tbody/index.js +62 -63
  217. package/table/th-resizable/index.js +30 -30
  218. package/table/thead/Column.js +148 -148
  219. package/table/thead/index.js +87 -88
  220. package/tabs/Tab.js +55 -55
  221. package/tabs/TabContent.js +8 -8
  222. package/tabs/TabPane.js +15 -15
  223. package/tabs/hook/useHeaderScroll.js +36 -36
  224. package/tabs/tab-header/TabInk.js +31 -33
  225. package/tabs/tab-header/TabNavIcon.js +34 -35
  226. package/tabs/tab-header/index.js +192 -195
  227. package/tag/index.js +94 -97
  228. package/time-picker/Picker.js +167 -172
  229. package/time-picker/RangePicker.js +28 -28
  230. package/time-picker/TimePicker.js +146 -146
  231. package/timeline/Item.js +46 -46
  232. package/timeline/Timeline.js +52 -52
  233. package/tooltip/index.js +89 -95
  234. package/tour/index.js +289 -0
  235. package/transfer/Item.js +54 -54
  236. package/transfer/List.js +134 -136
  237. package/transfer/index.js +91 -91
  238. package/tree/Animation.js +49 -52
  239. package/tree/Node.js +114 -122
  240. package/tree/NodeList.js +51 -51
  241. package/tree/Tree.js +386 -393
  242. package/tree-select/List.js +71 -72
  243. package/tree-select/Select.js +135 -143
  244. package/tree-select/hook/useKeyCache.js +39 -39
  245. package/tree-select/hook/useStateValue.js +12 -12
  246. package/trigger/getPopupStyle.js +60 -61
  247. package/trigger/index.js +337 -346
  248. package/types/common/space/interface.d.ts +1 -1
  249. package/types/common/utils/convertToDurationBasedOnTimeUnits.d.ts +3 -0
  250. package/types/common/utils/findScrollParent.d.ts +2 -0
  251. package/types/common/utils/index.d.ts +5 -0
  252. package/types/common/utils/intersectionObserver.d.ts +2 -0
  253. package/types/common/utils/mutationObserver.d.ts +2 -0
  254. package/types/common/utils/resizeObserver.d.ts +2 -0
  255. package/types/pc/config-provider/interface.d.ts +6 -0
  256. package/types/pc/index.d.ts +3 -0
  257. package/types/pc/liquid-fill/LiquidFill.d.ts +115 -0
  258. package/types/pc/liquid-fill/LiquidFill2.d.ts +1 -0
  259. package/types/pc/liquid-fill/index.d.ts +2 -0
  260. package/types/pc/qr-code/index.d.ts +34 -0
  261. package/types/pc/qr-code/interface.d.ts +39 -0
  262. package/types/pc/table/interface.d.ts +2 -2
  263. package/types/pc/tour/index.d.ts +42 -0
  264. package/types/pc/utils/convertToDurationBasedOnTimeUnits.d.ts +3 -0
  265. package/types/pc/utils/findScrollParent.d.ts +2 -0
  266. package/types/pc/utils/index.d.ts +5 -0
  267. package/types/pc/utils/intersectionObserver.d.ts +2 -0
  268. package/types/pc/utils/mutationObserver.d.ts +2 -0
  269. package/types/pc/utils/names.d.ts +18 -0
  270. package/types/pc/utils/resizeObserver.d.ts +2 -0
  271. package/typography/Base.js +79 -81
  272. package/typography/EditContent.js +30 -33
  273. package/typography/Ellipsis.js +77 -73
  274. package/typography/Operations.js +50 -52
  275. package/typography/Paragraph.js +7 -7
  276. package/typography/Typography.js +7 -7
  277. package/typography/useEllipsis.js +105 -106
  278. package/upload/TriggerNode.js +69 -76
  279. package/upload/Upload.js +84 -87
  280. package/upload/Uploader.js +115 -118
  281. package/upload/list/PictureItem.js +61 -71
  282. package/upload/list/TextItem.js +61 -67
  283. package/upload/list/UploadProgress.js +42 -49
  284. package/upload/list/index.js +48 -49
  285. package/upload/request_.js +37 -38
  286. package/upload/util.js +39 -39
  287. package/utils/convertToDurationBasedOnTimeUnits.js +6 -0
  288. package/utils/findScrollParent.js +4 -0
  289. package/utils/index.js +281 -278
  290. package/utils/intersectionObserver.js +4 -0
  291. package/utils/mutationObserver.js +4 -0
  292. package/utils/names.js +12 -0
  293. package/utils/resizeObserver.js +4 -0
  294. package/verification-code/VerificationCode.js +50 -51
  295. package/version/index.js +1 -1
  296. package/virtual-list/VirtualList.js +243 -244
  297. package/virtual-list/util/item.js +3 -4
  298. package/watermark/Watermark.js +27 -31
  299. package/components/common/utils/resizeObserverEffect.js +0 -23
  300. package/types/common/utils/resizeObserverEffect.d.ts +0 -2
  301. package/types/pc/utils/resizeObserverEffect.d.ts +0 -2
  302. package/utils/resizeObserverEffect.js +0 -4
@@ -1,35 +1,35 @@
1
- import { jsx as P, jsxs as ht, Fragment as gt } from "react/jsx-runtime";
2
- import mo from "@unicom-cloud/icons/IconUiCalendar";
3
- import po from "@unicom-cloud/icons/IconUiCalendarClock";
4
- import { isDayjs as vt } from "dayjs";
5
- import m from "lodash/isArray";
6
- import ho from "lodash/isPlainObject";
7
- import go from "lodash/isUndefined";
8
- import { forwardRef as vo, useContext as So, useRef as E, useImperativeHandle as wo, useState as v, useEffect as ne } from "react";
1
+ import { jsx as P, jsxs as rt, Fragment as at } from "react/jsx-runtime";
2
+ import co from "@unicom-cloud/icons/IconUiCalendar";
3
+ import uo from "@unicom-cloud/icons/IconUiCalendarClock";
4
+ import { isDayjs as st } from "dayjs";
5
+ import f from "lodash/isArray";
6
+ import lo from "lodash/isPlainObject";
7
+ import fo from "lodash/isUndefined";
8
+ import { forwardRef as po, useContext as mo, useRef as A, useImperativeHandle as ho, useState as g, useEffect as oe } from "react";
9
9
  import "../config-provider/ConfigProvider.js";
10
- import Po from "../components/common/hooks/useMergeProps.js";
11
- import St from "../components/common/hooks/usePrevious.js";
12
- import wt from "../components/common/hooks/useUpdateEffect.js";
13
- import yo from "../picker/InputRange.js";
14
- import Do from "../trigger/index.js";
15
- import bo from "@unicom-cloud/utils/class-name";
16
- import { getDayjsValue as y, getNow as T, toTimezone as Pt, toLocal as Re, methods as Y, getValueWithTime as re, getSortedDayjsArray as je, isValidTimeString as Vo, isDayjsArrayChange as xo } from "../components/common/utils/dayjs.js";
17
- import { pickDataAttributes as Io } from "../components/common/utils/pick.js";
18
- import To from "./context.js";
19
- import Yo from "./panel/Footer.js";
20
- import ko from "./panel/Shortcut.js";
10
+ import go from "../components/common/hooks/useMergeProps.js";
11
+ import it from "../components/common/hooks/usePrevious.js";
12
+ import ct from "../components/common/hooks/useUpdateEffect.js";
13
+ import So from "../picker/InputRange.js";
14
+ import vo from "../trigger/index.js";
15
+ import Po from "@unicom-cloud/utils/class-name";
16
+ import { getDayjsValue as w, getNow as C, toTimezone as ut, toLocal as ke, methods as I, getValueWithTime as ne, getSortedDayjsArray as Te, isValidTimeString as wo, isDayjsArrayChange as Vo } from "../components/common/utils/dayjs.js";
17
+ import { pickDataAttributes as yo } from "../components/common/utils/pick.js";
18
+ import Do from "./context.js";
19
+ import bo from "./panel/Footer.js";
20
+ import xo from "./panel/Shortcut.js";
21
21
  import Co from "./panel/range/index.js";
22
- import { getDefaultWeekStart as Ho, getAvailableDayjsLength as yt, getFormatByIndex as L, getLocaleDayjsValue as Ee } from "./util.js";
23
- import Lo from "../config-provider/context.js";
24
- function No(se) {
25
- const { format: $, showTime: D, mode: r } = se;
22
+ import { getDefaultWeekStart as Io, getAvailableDayjsLength as lt, getFormatByIndex as Y, getLocaleDayjsValue as Ye } from "./util.js";
23
+ import ko from "../config-provider/context.js";
24
+ function To(re) {
25
+ const { format: M, showTime: B, mode: V } = re;
26
26
  let S;
27
- if ($)
28
- S = $;
27
+ if (M)
28
+ S = M;
29
29
  else
30
- switch (r) {
30
+ switch (V) {
31
31
  case "date":
32
- S = D ? "YYYY-MM-DD HH:mm:ss" : "YYYY-MM-DD";
32
+ S = B ? "YYYY-MM-DD HH:mm:ss" : "YYYY-MM-DD";
33
33
  break;
34
34
  case "month":
35
35
  S = "YYYY-MM";
@@ -48,263 +48,258 @@ function No(se) {
48
48
  }
49
49
  return S;
50
50
  }
51
- const Dt = {
51
+ const ft = {
52
52
  allowClear: !0,
53
53
  unmountOnExit: !0,
54
54
  position: "bl",
55
55
  editable: !0,
56
56
  mode: "date"
57
- }, Ao = { bottom: 4 }, Ro = (se, $) => {
58
- var ft, mt, pt, dt;
57
+ }, Yo = { bottom: 4 }, Ho = (re, M) => {
59
58
  const {
60
- getPrefixCls: D,
61
- locale: r,
59
+ getPrefixCls: B,
60
+ locale: V,
62
61
  size: S,
63
- componentConfig: ae,
64
- rtl: Fe
65
- } = So(Lo);
66
- Fe && (Dt.position = "br");
67
- const f = Po(
68
- se,
69
- Dt,
70
- ae == null ? void 0 : ae.DatePicker
62
+ componentConfig: pt,
63
+ rtl: He
64
+ } = mo(ko);
65
+ He && (ft.position = "br");
66
+ const l = go(
67
+ re,
68
+ ft,
69
+ pt?.DatePicker
71
70
  ), {
72
- allowClear: bt,
73
- className: Oe,
74
- style: ze,
75
- placeholder: Me,
76
- getPopupContainer: Vt,
77
- disabled: h,
78
- position: xt,
79
- error: It,
80
- status: Tt,
81
- unmountOnExit: Yt,
82
- editable: kt,
83
- triggerProps: Ct,
84
- shortcuts: U,
85
- onSelect: ie,
86
- onVisibleChange: ue,
87
- value: Ht,
88
- onChange: ce,
89
- icons: W,
90
- disabledDate: Be,
91
- disabledTime: Lt,
71
+ allowClear: mt,
72
+ className: je,
73
+ style: Le,
74
+ placeholder: Ne,
75
+ getPopupContainer: dt,
76
+ disabled: d,
77
+ position: ht,
78
+ error: gt,
79
+ status: St,
80
+ unmountOnExit: vt,
81
+ editable: Pt,
82
+ triggerProps: wt,
83
+ shortcuts: $,
84
+ onSelect: Vt,
85
+ onVisibleChange: yt,
86
+ value: Dt,
87
+ onChange: bt,
88
+ icons: U,
89
+ disabledDate: Ae,
90
+ disabledTime: xt,
92
91
  mode: a,
93
- showTime: d,
94
- onSelectShortcut: le,
95
- extra: $e,
96
- shortcutsPlacementLeft: F,
97
- onOk: fe,
98
- defaultPickerValue: Nt,
99
- pickerValue: At,
100
- panelRender: Ue,
101
- onPickerValueChange: me,
102
- triggerElement: q,
103
- clearRangeOnReselect: Rt,
92
+ showTime: m,
93
+ onSelectShortcut: Ct,
94
+ extra: Oe,
95
+ shortcutsPlacementLeft: O,
96
+ onOk: It,
97
+ defaultPickerValue: kt,
98
+ pickerValue: Tt,
99
+ panelRender: Re,
100
+ onPickerValueChange: Yt,
101
+ triggerElement: W,
102
+ clearRangeOnReselect: Ht,
104
103
  separator: jt,
105
- utcOffset: i,
106
- timezone: u,
107
- inputProps: Et
108
- } = f, O = D == null ? void 0 : D("picker-range"), pe = r == null ? void 0 : r.DatePicker, Ft = go(f.dayStartOfWeek) ? Ho(r == null ? void 0 : r.dayjsLocale) : f.dayStartOfWeek, _ = E(null), de = E(null), he = E(null), ge = E(null), ve = E(null);
109
- wo(
110
- $,
104
+ utcOffset: s,
105
+ timezone: i,
106
+ inputProps: Lt
107
+ } = l, R = B?.("picker-range"), ae = V?.DatePicker, Nt = fo(l.dayStartOfWeek) ? Io(V?.dayjsLocale) : l.dayStartOfWeek, q = A(null), se = A(null), ie = A(null), ce = A(null), ue = A(null);
108
+ ho(
109
+ M,
111
110
  () => ({
112
111
  focus(e) {
113
- var t, o;
114
- (o = (t = _.current) == null ? void 0 : t.focus) == null || o.call(t, e);
112
+ q.current?.focus?.(e);
115
113
  },
116
114
  blur() {
117
- Xe();
115
+ We();
118
116
  }
119
117
  }),
120
118
  []
121
119
  );
122
- const c = ((mt = (ft = pe.Calendar) == null ? void 0 : ft[a]) == null ? void 0 : mt.format) || No(f);
123
- function Ot() {
124
- if (m(h)) {
125
- if (h[0] && !h[1])
120
+ const c = ae.Calendar?.[a]?.format || To(l);
121
+ function At() {
122
+ if (f(d)) {
123
+ if (d[0] && !d[1])
126
124
  return 1;
127
- if (h[1] && !h[0])
125
+ if (d[1] && !d[0])
128
126
  return 0;
129
127
  }
130
128
  }
131
- const k = Ot(), w = typeof k == "number", zt = w ? 1 ^ k : void 0, [p, Se] = v(
132
- w ? k : 0
129
+ const k = At(), v = typeof k == "number", Ot = v ? 1 ^ k : void 0, [p, le] = g(
130
+ v ? k : 0
133
131
  );
134
- ne(() => {
135
- w && Se(k);
136
- }, [h]);
137
- const Q = 1 ^ p, [K, C] = v(), [We, G] = v(), [we, Pe] = v(Wt()), [b, N] = v(), [Mt, z] = v(), [qe, ye] = v(), [Bt, $t] = v(() => !!f.popupVisible), [De, be] = v([a, a]), [Ve, _e] = v(!1), V = f.popupVisible ?? Bt, H = y(
138
- Ht,
132
+ oe(() => {
133
+ v && le(k);
134
+ }, [d]);
135
+ const _ = 1 ^ p, [Q, T] = g(), [Ee, K] = g(), [fe, pe] = g(Mt()), [y, H] = g(), [Rt, E] = g(), [Fe, me] = g(), [Et, Ft] = g(() => !!l.popupVisible), [de, he] = g([a, a]), [ge, ze] = g(!1), D = l.popupVisible ?? Et, Se = w(
136
+ Dt,
139
137
  c,
140
- i,
141
- u
142
- ), x = "value" in f ? H : we, l = qe || b || x || [], g = yt(b || x), M = E(!0), xe = T(), Qe = Pt(xe, i, u);
143
- function Ut() {
144
- const e = [], t = ho(d) && d.defaultValue ? y(d.defaultValue, d.format || "HH:mm:ss") : [];
145
- return e[0] = l[0] || t[0] || Qe, e[1] = l[1] || t[1] || Qe, e;
146
- }
147
- const J = Ut(), Ke = w ? (e) => k === 0 ? e.isAfter(l[1], a) : e.isBefore(l[0], a) : void 0, Ie = q !== void 0, Te = Ie || Rt;
148
- function Wt() {
138
+ s,
139
+ i
140
+ ), b = "value" in l ? Se : fe, u = Fe || y || b || [], h = lt(y || b), F = A(!0), ve = C(), Me = ut(ve, s, i);
141
+ function zt() {
142
+ const e = [], t = lo(m) && m.defaultValue ? w(m.defaultValue, m.format || "HH:mm:ss") : [];
143
+ return e[0] = u[0] || t[0] || Me, e[1] = u[1] || t[1] || Me, e;
144
+ }
145
+ const G = zt(), Be = v ? (e) => k === 0 ? e.isAfter(u[1], a) : e.isBefore(u[0], a) : void 0, Pe = W !== void 0, we = Pe || Ht;
146
+ function Mt() {
149
147
  let e;
150
- if (f.value ? e = y(f.value, c, i, u) : e = y(f.defaultValue, c, i, u), w && (!e || e && !e[Q])) {
148
+ if (l.value ? e = w(l.value, c, s, i) : e = w(l.defaultValue, c, s, i), v && (!e || e && !e[_])) {
151
149
  const t = [];
152
- return t[Q] = T(i, u), t;
150
+ return t[_] = C(s, i), t;
153
151
  }
154
152
  return e;
155
153
  }
156
- const Ye = x || y(Nt, c) || [xe, xe], [Ge, X] = v(
157
- A(Ye)
158
- ), Z = A(
159
- y(At, c, i, u)
160
- ) || Ge, ke = St(i), Ce = St(u);
161
- wt(() => {
162
- if (m(we) && (ke !== i || u !== Ce)) {
163
- const t = we.map(
164
- (o, n, s) => Re(o, ke, Ce)
154
+ const Ve = b || w(kt, c) || [ve, ve], [$e, J] = g(
155
+ j(Ve)
156
+ ), X = j(
157
+ w(Tt, c, s, i)
158
+ ) || $e, ye = it(s), De = it(i);
159
+ ct(() => {
160
+ if (f(fe) && (ye !== s || i !== De)) {
161
+ const t = fe.map(
162
+ (o, n, r) => ke(o, ye, De)
165
163
  ).map(
166
- (o, n, s) => Pt(o, i, u)
164
+ (o, n, r) => ut(o, s, i)
167
165
  );
168
- Pe(t);
166
+ pe(t);
169
167
  }
170
- }, [i, ke, u, Ce]), wt(() => {
171
- X(A(Ye));
172
- }, [a]), ne(() => {
173
- be([a, a]);
174
- }, [a]), ne(() => {
175
- if (G(void 0), C(void 0), V) {
176
- const e = A(Ye);
177
- _e(!1), be([a, a]), X(e), He(e), N(x), F && he.current && de.current && (he.current.style.maxHeight = `${de.current.clientHeight}px`);
168
+ }, [s, ye, i, De]), ct(() => {
169
+ J(j(Ve));
170
+ }, [a]), oe(() => {
171
+ he([a, a]);
172
+ }, [a]), oe(() => {
173
+ if (K(void 0), T(void 0), D) {
174
+ const e = j(Ve);
175
+ ze(!1), he([a, a]), J(e), be(e), H(b), O && ie.current && se.current && (ie.current.style.maxHeight = `${se.current.clientHeight}px`);
178
176
  } else
179
- N(void 0), z(void 0), ye(void 0), Xe();
180
- M.current = V;
181
- }, [V]);
182
- const qt = (pt = H == null ? void 0 : H[0]) == null ? void 0 : pt.format(L(c, 0)), _t = (dt = H == null ? void 0 : H[1]) == null ? void 0 : dt.format(L(c, 1));
183
- ne(() => {
184
- N(void 0), z(void 0);
185
- }, [qt, _t]);
186
- function B(e, t = p) {
187
- const o = A(e, t);
188
- X(o), He(o);
189
- }
190
- function He(e) {
191
- Je([e[0], Ge[0]], a) || me == null || me(
192
- m(e) ? e.map((t, o) => t && t.format(L(c, o))) : void 0,
177
+ H(void 0), E(void 0), me(void 0), We();
178
+ F.current = D;
179
+ }, [D]);
180
+ const Bt = Se?.[0]?.format(Y(c, 0)), $t = Se?.[1]?.format(Y(c, 1));
181
+ oe(() => {
182
+ H(void 0), E(void 0);
183
+ }, [Bt, $t]);
184
+ function z(e, t = p) {
185
+ const o = j(e, t);
186
+ J(o), be(o);
187
+ }
188
+ function be(e) {
189
+ Ue([e[0], $e[0]], a) || Yt?.(
190
+ f(e) ? e.map((t, o) => t && t.format(Y(c, o))) : void 0,
193
191
  e
194
192
  );
195
193
  }
196
- function A(e, t = p) {
197
- const o = t === 0 || Je(e, a);
198
- if (m(e) && e.length < 2)
199
- return ee(
200
- e[0] || T(i, u),
194
+ function j(e, t = p) {
195
+ const o = t === 0 || Ue(e, a);
196
+ if (f(e) && e.length < 2)
197
+ return Z(
198
+ e[0] || C(s, i),
201
199
  a,
202
200
  "prev"
203
201
  );
204
- if (m(e) && e.length === 2)
205
- return e[t] ? ee(
202
+ if (f(e) && e.length === 2)
203
+ return e[t] ? Z(
206
204
  e[t],
207
205
  a,
208
206
  o ? "prev" : "next"
209
- ) : ee(
210
- e[t === 0 ? 1 : 0] || T(i, u),
207
+ ) : Z(
208
+ e[t === 0 ? 1 : 0] || C(s, i),
211
209
  a,
212
210
  o && !e[t === 0 ? 1 : 0] ? "prev" : "next"
213
211
  );
214
212
  }
215
- function Je(e, t) {
216
- if ((e == null ? void 0 : e.length) === 2 && at(e))
213
+ function Ue(e, t) {
214
+ if (e?.length === 2 && Ze(e))
217
215
  return (t === "date" || t === "week") && e[0].isSame(e[1], "month") || (t === "month" || t === "quarter") && e[0].isSame(e[1], "year") || t === "year" && Math.floor(e[0].year() / 10) === Math.floor(e[1].year() / 10);
218
216
  }
219
- function ee(e = T(i, u), t = a, o = "prev") {
217
+ function Z(e = C(s, i), t = a, o = "prev") {
220
218
  const n = o === "prev";
221
219
  switch (t) {
222
220
  case "date":
223
221
  case "week":
224
- return n ? [e, Y.add(e, 1, "month")] : [Y.subtract(e, 1, "month"), e];
222
+ return n ? [e, I.add(e, 1, "month")] : [I.subtract(e, 1, "month"), e];
225
223
  case "month":
226
224
  case "quarter":
227
- return n ? [e, Y.add(e, 1, "year")] : [Y.subtract(e, 1, "year"), e];
225
+ return n ? [e, I.add(e, 1, "year")] : [I.subtract(e, 1, "year"), e];
228
226
  case "year":
229
- return n ? [e, Y.add(e, 10, "year")] : [Y.subtract(e, 10, "year"), e];
227
+ return n ? [e, I.add(e, 10, "year")] : [I.subtract(e, 10, "year"), e];
230
228
  default:
231
229
  return [];
232
230
  }
233
231
  }
234
- function Le(e) {
235
- var t, o;
236
- (o = (t = _.current) == null ? void 0 : t.focus) == null || o.call(t, w ? k : e);
232
+ function xe(e) {
233
+ q.current?.focus?.(v ? k : e);
237
234
  }
238
- function Xe() {
239
- var e, t;
240
- (t = (e = _.current) == null ? void 0 : e.blur) == null || t.call(e);
235
+ function We() {
236
+ q.current?.blur?.();
241
237
  }
242
- function te(e) {
243
- ue == null || ue(e), $t(e);
238
+ function ee(e) {
239
+ yt?.(e), Ft(e);
244
240
  }
245
- function Qt(e) {
246
- var o;
241
+ function Ut(e) {
247
242
  e.stopPropagation();
248
- let t = [...l];
249
- w ? t[k] = void 0 : t = void 0, Pe(t), N(t), ot(t), (o = f.onClear) == null || o.call(f);
243
+ let t = [...u];
244
+ v ? t[k] = void 0 : t = void 0, pe(t), H(t), Ke(t), l.onClear?.();
250
245
  }
251
- function Ze(e, t) {
252
- if (Se(e), l && l.length && !t) {
253
- const o = A(l, e);
254
- X(o), He(o);
246
+ function qe(e, t) {
247
+ if (le(e), u && u.length && !t) {
248
+ const o = j(u, e);
249
+ J(o), be(o);
255
250
  }
256
251
  }
257
- function et(e) {
258
- const t = typeof Ke == "function" ? Ke(e) : !1;
259
- return (typeof Be == "function" ? Be(e) : !1) || t;
252
+ function _e(e) {
253
+ const t = typeof Be == "function" ? Be(e) : !1;
254
+ return (typeof Ae == "function" ? Ae(e) : !1) || t;
260
255
  }
261
- function tt(e) {
262
- return Vo(e, c, p) && !et(y(e, c));
256
+ function Qe(e) {
257
+ return wo(e, c, p) && !_e(w(e, c));
263
258
  }
264
- function Kt(e) {
265
- const t = [...l || []], o = e.target.value;
266
- C(o), V || te(!0), tt(o) && (t[p] = y(o, c), N(t), B(t), C(void 0));
259
+ function Wt(e) {
260
+ const t = [...u || []], o = e.target.value;
261
+ T(o), D || ee(!0), Qe(o) && (t[p] = w(o, c), H(t), z(t), T(void 0));
267
262
  }
268
- function Gt() {
269
- K && C(void 0);
263
+ function qt() {
264
+ Q && T(void 0);
270
265
  }
271
- function ot(e) {
272
- if (xo(x, e)) {
273
- const t = m(e) ? e.map(
274
- (o, n, s) => Ee(
275
- Re(o, i, u),
276
- r == null ? void 0 : r.dayjsLocale
266
+ function Ke(e) {
267
+ if (Vo(b, e)) {
268
+ const t = f(e) ? e.map(
269
+ (o, n, r) => Ye(
270
+ ke(o, s, i),
271
+ V?.dayjsLocale
277
272
  )
278
273
  ) : void 0;
279
- ce == null || ce(
280
- m(t) ? t.map((o, n) => o && o.format(L(c, n))) : void 0,
274
+ bt?.(
275
+ f(t) ? t.map((o, n) => o && o.format(Y(c, n))) : void 0,
281
276
  t
282
277
  );
283
278
  }
284
279
  }
285
- function Jt() {
286
- m(b) && b.length ? K && !tt(K) ? C(void 0) : g !== 2 ? oe() : g === 2 && R(b) : V && te(!1);
280
+ function _t() {
281
+ f(y) && y.length ? Q && !Qe(Q) ? T(void 0) : h !== 2 ? te() : h === 2 && L(y) : D && ee(!1);
287
282
  }
288
- function R(e, t) {
289
- const o = e || l;
283
+ function L(e, t) {
284
+ const o = e || u;
290
285
  if (!o || !o[0] || !o[1])
291
286
  return;
292
- const n = je(o);
293
- Pe(n), ot(n), q === null || t || te(!1);
287
+ const n = Te(o);
288
+ pe(n), Ke(n), W === null || t || ee(!1);
294
289
  }
295
- function Xt() {
296
- R();
297
- const e = l.map(
298
- (t, o, n) => Ee(t, r == null ? void 0 : r.dayjsLocale)
290
+ function Qt() {
291
+ L();
292
+ const e = u.map(
293
+ (t, o, n) => Ye(t, V?.dayjsLocale)
299
294
  );
300
- fe == null || fe(
295
+ It?.(
301
296
  e.map(
302
- (t, o) => t && t.format(L(c, o))
297
+ (t, o) => t && t.format(Y(c, o))
303
298
  ),
304
299
  e
305
300
  );
306
301
  }
307
- function nt() {
302
+ function Ge() {
308
303
  switch (a) {
309
304
  case "date":
310
305
  case "week":
@@ -317,270 +312,270 @@ const Dt = {
317
312
  return;
318
313
  }
319
314
  }
320
- function rt(e) {
321
- if (g !== 2)
315
+ function Je(e) {
316
+ if (h !== 2)
322
317
  return !1;
323
- const t = b || x;
324
- return !!(p === 0 && e.isAfter(t[1], nt()) || p === 1 && e.isBefore(t[0], nt()));
325
- }
326
- function Zt(e, t) {
327
- const o = rt(t) && M.current, n = Te && g === 2 && !w ? [] : [...l], s = Ie ? g === 0 || g === 2 ? 0 : 1 : p, j = d ? re(t, J[s]) : t;
328
- o ? (n[s] = j, n[1 ^ s] = void 0) : n[s] = j;
329
- const Ne = je(n);
330
- st(Ne), C(void 0), G(void 0);
331
- const Ae = yt(n);
332
- Te ? g === 0 || g === 2 && !w ? Ie ? Se(1) : oe(!0) : d || R(n) : Ae <= 1 ? oe(!0) : g === 2 && M.current && !w ? (M.current = !1, oe(!0), !d && !o && R(n, !0)) : (M.current = !1, !d && !o && R(n));
333
- }
334
- function eo(e, t, o) {
335
- const n = m(l) ? [...l] : [], s = re(
336
- n[e] || T(i, u),
318
+ const t = y || b;
319
+ return !!(p === 0 && e.isAfter(t[1], Ge()) || p === 1 && e.isBefore(t[0], Ge()));
320
+ }
321
+ function Kt(e, t) {
322
+ const o = Je(t) && F.current, n = we && h === 2 && !v ? [] : [...u], r = Pe ? h === 0 || h === 2 ? 0 : 1 : p, N = m ? ne(t, G[r]) : t;
323
+ o ? (n[r] = N, n[1 ^ r] = void 0) : n[r] = N;
324
+ const Ce = Te(n);
325
+ Xe(Ce), T(void 0), K(void 0);
326
+ const Ie = lt(n);
327
+ we ? h === 0 || h === 2 && !v ? Pe ? le(1) : te(!0) : m || L(n) : Ie <= 1 ? te(!0) : h === 2 && F.current && !v ? (F.current = !1, te(!0), !m && !o && L(n, !0)) : (F.current = !1, !m && !o && L(n));
328
+ }
329
+ function Gt(e, t, o) {
330
+ const n = f(u) ? [...u] : [], r = ne(
331
+ n[e] || C(s, i),
337
332
  o
338
333
  );
339
- n[e] = s, st(n);
340
- }
341
- function st(e) {
342
- N(e), z(void 0);
343
- const o = je(e).map(
344
- (n, s, j) => Ee(
345
- Re(n, i, u),
346
- r == null ? void 0 : r.dayjsLocale
334
+ n[e] = r, Xe(n);
335
+ }
336
+ function Xe(e) {
337
+ H(e), E(void 0);
338
+ const o = Te(e).map(
339
+ (n, r, N) => Ye(
340
+ ke(n, s, i),
341
+ V?.dayjsLocale
347
342
  )
348
343
  );
349
- ie == null || ie(
350
- o.map((n, s) => n && n.format(L(c, s))),
344
+ Vt?.(
345
+ o.map((n, r) => n && n.format(Y(c, r))),
351
346
  o,
352
347
  { type: p === 1 ? "end" : "start" }
353
348
  );
354
349
  }
355
- function oe(e) {
356
- Ze(Q, e), setTimeout(() => Le(Q));
350
+ function te(e) {
351
+ qe(_, e), setTimeout(() => xe(_));
357
352
  }
358
- function to(e, t) {
359
- const o = [...l || []];
360
- if (!t && (Te ? g === 1 : g !== 0) && !rt(e) && (o[p] = re(
353
+ function Jt(e, t) {
354
+ const o = [...u || []];
355
+ if (!t && (we ? h === 1 : h !== 0) && !Je(e) && (o[p] = ne(
361
356
  e,
362
- J[p]
363
- ), z(o), C(void 0)), !t) {
364
- const s = d ? re(e, J[p]) : e;
365
- G(
366
- s.locale(r == null ? void 0 : r.dayjsLocale).format(L(c, p))
357
+ G[p]
358
+ ), E(o), T(void 0)), !t) {
359
+ const r = m ? ne(e, G[p]) : e;
360
+ K(
361
+ r.locale(V?.dayjsLocale).format(Y(c, p))
367
362
  );
368
363
  }
369
364
  }
370
- function oo() {
371
- z(void 0), G(void 0);
365
+ function Xt() {
366
+ E(void 0), K(void 0);
372
367
  }
373
- function at(e) {
374
- return e && m(e) && e.length === 2 && vt(e[0]) && vt(e[1]);
368
+ function Ze(e) {
369
+ return e && f(e) && e.length === 2 && st(e[0]) && st(e[1]);
375
370
  }
376
- function it(e) {
371
+ function et(e) {
377
372
  const t = typeof e.value == "function" && e.value();
378
- return at(t);
373
+ return Ze(t);
379
374
  }
380
- function ut() {
381
- clearTimeout(ge.current), clearTimeout(ve.current), ge.current = null, ve.current = null;
375
+ function tt() {
376
+ clearTimeout(ce.current), clearTimeout(ue.current), ce.current = null, ue.current = null;
382
377
  }
383
- function no(e) {
384
- ut(), ge.current = setTimeout(() => {
385
- if (it(e)) {
386
- const t = y(
378
+ function Zt(e) {
379
+ tt(), ce.current = setTimeout(() => {
380
+ if (et(e)) {
381
+ const t = w(
387
382
  e.value(),
388
383
  c,
389
- i,
390
- u
384
+ s,
385
+ i
391
386
  );
392
- ye(t), B(t);
387
+ me(t), z(t);
393
388
  }
394
389
  }, 50);
395
390
  }
396
- function ro() {
397
- ut(), ve.current = setTimeout(() => {
398
- ye(void 0), B(
399
- b || x || [
400
- T(i, u),
401
- T(i, u)
391
+ function eo() {
392
+ tt(), ue.current = setTimeout(() => {
393
+ me(void 0), z(
394
+ y || b || [
395
+ C(s, i),
396
+ C(s, i)
402
397
  ]
403
398
  );
404
399
  }, 50);
405
400
  }
406
- function so(e) {
407
- if (le == null || le(e), it(e)) {
408
- const t = y(
401
+ function to(e) {
402
+ if (Ct?.(e), et(e)) {
403
+ const t = w(
409
404
  e.value(),
410
405
  c,
411
- i,
412
- u
406
+ s,
407
+ i
413
408
  );
414
- R(t);
409
+ L(t);
415
410
  }
416
411
  }
417
- function I(e, t, o = 1) {
412
+ function x(e, t, o = 1) {
418
413
  const n = e === "prev" ? 0 : 1;
419
- let s = [...Z];
420
- e === "prev" && (s[n] = Y.subtract(
421
- Z[n],
414
+ let r = [...X];
415
+ e === "prev" && (r[n] = I.subtract(
416
+ X[n],
422
417
  o,
423
418
  t
424
- )), e === "next" && (s[n] = Y.add(
425
- Z[n],
419
+ )), e === "next" && (r[n] = I.add(
420
+ X[n],
426
421
  o,
427
422
  t
428
- )), s = ee(
429
- s[n],
423
+ )), r = Z(
424
+ r[n],
430
425
  a,
431
426
  e
432
- ), B(s);
427
+ ), z(r);
433
428
  }
434
- function ct(e = a) {
429
+ function ot(e = a) {
435
430
  if (e === "date" || e === "week")
436
431
  return {
437
- onPrev: () => I("prev", "month"),
438
- onNext: () => I("next", "month"),
439
- onSuperPrev: () => I("prev", "year"),
440
- onSuperNext: () => I("next", "year")
432
+ onPrev: () => x("prev", "month"),
433
+ onNext: () => x("next", "month"),
434
+ onSuperPrev: () => x("prev", "year"),
435
+ onSuperNext: () => x("next", "year")
441
436
  };
442
437
  if (e === "month" || e === "quarter")
443
438
  return {
444
- onSuperPrev: () => I("prev", "year"),
445
- onSuperNext: () => I("next", "year")
439
+ onSuperPrev: () => x("prev", "year"),
440
+ onSuperNext: () => x("next", "year")
446
441
  };
447
442
  if (e === "year")
448
443
  return {
449
- onSuperPrev: () => I("prev", "year", 10),
450
- onSuperNext: () => I("next", "year", 10)
444
+ onSuperPrev: () => x("prev", "year", 10),
445
+ onSuperNext: () => x("next", "year", 10)
451
446
  };
452
447
  }
453
- function ao() {
454
- _e(!Ve);
448
+ function oo() {
449
+ ze(!ge);
455
450
  }
456
- function lt(e) {
457
- const t = bo(
458
- `${O}-container`,
451
+ function nt(e) {
452
+ const t = Po(
453
+ `${R}-container`,
459
454
  {
460
- [`${O}-panel-only`]: e,
461
- [`${O}-container-shortcuts-placement-left`]: m(U) && F,
462
- [`${O}-container-rtl`]: Fe
455
+ [`${R}-panel-only`]: e,
456
+ [`${R}-container-shortcuts-placement-left`]: f($) && O,
457
+ [`${R}-container-rtl`]: He
463
458
  },
464
- e ? Oe : ""
459
+ e ? je : ""
465
460
  ), o = {
466
- prefixCls: D == null ? void 0 : D("picker"),
467
- showTime: d,
468
- shortcuts: U,
469
- onMouseEnterShortcut: no,
470
- onMouseLeaveShortcut: ro,
471
- onSelectShortcut: so
472
- }, n = d && De[0] === "date" && De[1] === "date" || $e || m(U) && U.length && !F, s = /* @__PURE__ */ ht(gt, { children: [
461
+ prefixCls: B?.("picker"),
462
+ showTime: m,
463
+ shortcuts: $,
464
+ onMouseEnterShortcut: Zt,
465
+ onMouseLeaveShortcut: eo,
466
+ onSelectShortcut: to
467
+ }, n = m && de[0] === "date" && de[1] === "date" || Oe || f($) && $.length && !O, r = /* @__PURE__ */ rt(at, { children: [
473
468
  /* @__PURE__ */ P(
474
469
  Co,
475
470
  {
476
- ...f,
477
- ...ct(),
478
- getHeaderOperations: ct,
479
- setRangePageShowDates: B,
480
- pageShowDates: Z,
481
- value: l,
471
+ ...l,
472
+ ...ot(),
473
+ getHeaderOperations: ot,
474
+ setRangePageShowDates: z,
475
+ pageShowDates: X,
476
+ value: u,
482
477
  format: c,
483
- onSelectPanel: Zt,
484
- onMouseEnterCell: to,
485
- onMouseLeaveCell: oo,
486
- disabledDate: (Ae) => et(Ae),
487
- disabledTime: Lt,
478
+ onSelectPanel: Kt,
479
+ onMouseEnterCell: Jt,
480
+ onMouseLeaveCell: Xt,
481
+ disabledDate: (Ie) => _e(Ie),
482
+ disabledTime: xt,
488
483
  mode: a,
489
- localeName: r == null ? void 0 : r.dayjsLocale,
490
- showTime: d,
491
- timeValues: qe || J,
492
- onTimePickerSelect: eo,
493
- popupVisible: V,
494
- disabledTimePickerIndex: zt,
495
- isTimePanel: Ve,
496
- valueShowHover: Mt,
497
- panelModes: De,
498
- setPanelModes: be
484
+ localeName: V?.dayjsLocale,
485
+ showTime: m,
486
+ timeValues: Fe || G,
487
+ onTimePickerSelect: Gt,
488
+ popupVisible: D,
489
+ disabledTimePickerIndex: Ot,
490
+ isTimePanel: ge,
491
+ valueShowHover: Rt,
492
+ panelModes: de,
493
+ setPanelModes: he
499
494
  }
500
495
  ),
501
496
  !!n && /* @__PURE__ */ P(
502
- Yo,
497
+ bo,
503
498
  {
504
499
  ...o,
505
- DATEPICKER_LOCALE: pe,
506
- disabled: !(m(l) && l[0] && l[1]),
507
- onClickConfirmBtn: Xt,
508
- extra: $e,
509
- shortcutsPlacementLeft: F,
510
- onClickSelectTimeBtn: ao,
511
- isTimePanel: Ve
500
+ DATEPICKER_LOCALE: ae,
501
+ disabled: !(f(u) && u[0] && u[1]),
502
+ onClickConfirmBtn: Qt,
503
+ extra: Oe,
504
+ shortcutsPlacementLeft: O,
505
+ onClickSelectTimeBtn: oo,
506
+ isTimePanel: ge
512
507
  }
513
508
  )
514
- ] }), j = F ? /* @__PURE__ */ ht(gt, { children: [
515
- /* @__PURE__ */ P(ko, { ref: he, ...o }),
516
- /* @__PURE__ */ P("div", { ref: de, className: `${O}-panel-wrapper`, children: s })
517
- ] }) : s, Ne = typeof Ue == "function" ? Ue(j) : j;
509
+ ] }), N = O ? /* @__PURE__ */ rt(at, { children: [
510
+ /* @__PURE__ */ P(xo, { ref: ie, ...o }),
511
+ /* @__PURE__ */ P("div", { ref: se, className: `${R}-panel-wrapper`, children: r })
512
+ ] }) : r, Ce = typeof Re == "function" ? Re(N) : N;
518
513
  return /* @__PURE__ */ P(
519
514
  "div",
520
515
  {
521
516
  className: t,
522
- onClick: () => Le(),
523
- style: e ? ze : {},
524
- children: Ne
517
+ onClick: () => xe(),
518
+ style: e ? Le : {},
519
+ children: Ce
525
520
  }
526
521
  );
527
522
  }
528
- const io = f.size || S, uo = m(Me) ? Me : pe.placeholders[a], co = W && W.inputSuffix === null ? null : W && W.inputSuffix || (d ? /* @__PURE__ */ P(po, {}) : /* @__PURE__ */ P(mo, {})), lo = {
529
- style: ze,
530
- className: Oe,
531
- popupVisible: V,
523
+ const no = l.size || S, ro = f(Ne) ? Ne : ae.placeholders[a], ao = U && U.inputSuffix === null ? null : U && U.inputSuffix || (m ? /* @__PURE__ */ P(uo, {}) : /* @__PURE__ */ P(co, {})), so = {
524
+ style: Le,
525
+ className: je,
526
+ popupVisible: D,
532
527
  format: c,
533
- disabled: h,
534
- error: It,
535
- status: Tt,
536
- size: io,
537
- onPressEnter: Jt,
538
- onClear: Qt,
539
- suffixIcon: co,
540
- editable: kt,
541
- allowClear: bt,
542
- prefix: f.prefix
543
- }, fo = m(h) ? h[0] && h[1] : h;
544
- return /* @__PURE__ */ P(To.Provider, { value: { utcOffset: i, timezone: u, weekStart: Ft }, children: q === null ? lt(!0) : /* @__PURE__ */ P(
545
- Do,
528
+ disabled: d,
529
+ error: gt,
530
+ status: St,
531
+ size: no,
532
+ onPressEnter: _t,
533
+ onClear: Ut,
534
+ suffixIcon: ao,
535
+ editable: Pt,
536
+ allowClear: mt,
537
+ prefix: l.prefix
538
+ }, io = f(d) ? d[0] && d[1] : d;
539
+ return /* @__PURE__ */ P(Do.Provider, { value: { utcOffset: s, timezone: i, weekStart: Nt }, children: W === null ? nt(!0) : /* @__PURE__ */ P(
540
+ vo,
546
541
  {
547
- popup: lt,
542
+ popup: nt,
548
543
  trigger: "click",
549
544
  clickToClose: !1,
550
- position: xt,
551
- disabled: fo,
552
- popupAlign: Ao,
553
- getPopupContainer: Vt,
545
+ position: ht,
546
+ disabled: io,
547
+ popupAlign: Yo,
548
+ getPopupContainer: dt,
554
549
  onVisibleChange: (e) => {
555
550
  e && setTimeout(() => {
556
- Le();
557
- }), te(!!e);
551
+ xe();
552
+ }), ee(!!e);
558
553
  },
559
- popupVisible: V,
554
+ popupVisible: D,
560
555
  classNames: "slideDynamicOrigin",
561
- unmountOnExit: Yt,
562
- ...Ct,
563
- children: q || /* @__PURE__ */ P(
564
- yo,
556
+ unmountOnExit: vt,
557
+ ...wt,
558
+ children: W || /* @__PURE__ */ P(
559
+ So,
565
560
  {
566
- ...Io(f),
567
- ...lo,
568
- inputProps: Et,
569
- ref: _,
570
- placeholder: uo,
571
- value: b || x,
572
- onChange: Kt,
573
- inputValue: We || K,
574
- changeFocusedInputIndex: Ze,
561
+ ...yo(l),
562
+ ...so,
563
+ inputProps: Lt,
564
+ ref: q,
565
+ placeholder: ro,
566
+ value: y || b,
567
+ onChange: Wt,
568
+ inputValue: Ee || Q,
569
+ changeFocusedInputIndex: qe,
575
570
  focusedInputIndex: p,
576
- isPlaceholder: !!We,
571
+ isPlaceholder: !!Ee,
577
572
  separator: jt,
578
- onBlur: Gt
573
+ onBlur: qt
579
574
  }
580
575
  )
581
576
  }
582
577
  ) });
583
- }, jo = vo(Ro);
578
+ }, jo = po(Ho);
584
579
  jo.displayName = "RangePicker";
585
580
  export {
586
581
  jo as default