@univerjs/design 0.17.0 → 0.18.0-insiders.20260328-d26c36e

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 (141) hide show
  1. package/lib/cjs/index.js +86 -207
  2. package/lib/cjs/locale/ca-ES.js +1 -1
  3. package/lib/cjs/locale/en-US.js +1 -1
  4. package/lib/cjs/locale/es-ES.js +1 -1
  5. package/lib/cjs/locale/fa-IR.js +1 -1
  6. package/lib/cjs/locale/fr-FR.js +1 -1
  7. package/lib/cjs/locale/ja-JP.js +1 -1
  8. package/lib/cjs/locale/ko-KR.js +1 -1
  9. package/lib/cjs/locale/ru-RU.js +1 -1
  10. package/lib/cjs/locale/sk-SK.js +1 -1
  11. package/lib/cjs/locale/vi-VN.js +1 -1
  12. package/lib/cjs/locale/zh-CN.js +1 -1
  13. package/lib/cjs/locale/zh-TW.js +1 -1
  14. package/lib/es/index.js +84 -15779
  15. package/lib/es/locale/ca-ES.js +1 -50
  16. package/lib/es/locale/en-US.js +1 -50
  17. package/lib/es/locale/es-ES.js +1 -50
  18. package/lib/es/locale/fa-IR.js +1 -50
  19. package/lib/es/locale/fr-FR.js +1 -50
  20. package/lib/es/locale/ja-JP.js +1 -50
  21. package/lib/es/locale/ko-KR.js +1 -50
  22. package/lib/es/locale/ru-RU.js +1 -50
  23. package/lib/es/locale/sk-SK.js +1 -50
  24. package/lib/es/locale/vi-VN.js +1 -50
  25. package/lib/es/locale/zh-CN.js +1 -50
  26. package/lib/es/locale/zh-TW.js +1 -50
  27. package/lib/index.css +2580 -1
  28. package/lib/index.js +84 -15779
  29. package/lib/locale/ca-ES.js +1 -50
  30. package/lib/locale/en-US.js +1 -50
  31. package/lib/locale/es-ES.js +1 -50
  32. package/lib/locale/fa-IR.js +1 -50
  33. package/lib/locale/fr-FR.js +1 -50
  34. package/lib/locale/ja-JP.js +1 -50
  35. package/lib/locale/ko-KR.js +1 -50
  36. package/lib/locale/ru-RU.js +1 -50
  37. package/lib/locale/sk-SK.js +1 -50
  38. package/lib/locale/vi-VN.js +1 -50
  39. package/lib/locale/zh-CN.js +1 -50
  40. package/lib/locale/zh-TW.js +1 -50
  41. package/lib/types/components/accordion/Accordion.d.ts +16 -1
  42. package/lib/types/components/accordion/Accordion.stories.d.ts +16 -1
  43. package/lib/types/components/avatar/Avatar.d.ts +18 -3
  44. package/lib/types/components/avatar/Avatar.stories.d.ts +16 -1
  45. package/lib/types/components/badge/Badge.d.ts +16 -1
  46. package/lib/types/components/badge/Badge.stories.d.ts +16 -1
  47. package/lib/types/components/button/Button.d.ts +19 -4
  48. package/lib/types/components/button/Button.stories.d.ts +16 -1
  49. package/lib/types/components/button/ButtonGroup.d.ts +17 -2
  50. package/lib/types/components/button/ButtonGroup.stories.d.ts +16 -1
  51. package/lib/types/components/calendar/Calendar.stories.d.ts +16 -1
  52. package/lib/types/components/cascader-list/CascaderList.stories.d.ts +16 -1
  53. package/lib/types/components/checkbox/Checkbox.d.ts +16 -1
  54. package/lib/types/components/checkbox/Checkbox.stories.d.ts +16 -1
  55. package/lib/types/components/checkbox-group/CheckboxGroup.d.ts +16 -1
  56. package/lib/types/components/checkbox-group/CheckboxGroup.stories.d.ts +16 -1
  57. package/lib/types/components/color-picker/ColorPicker.stories.d.ts +16 -1
  58. package/lib/types/components/config-provider/ConfigProvider.d.ts +17 -2
  59. package/lib/types/components/config-provider/ConfigProvider.stories.d.ts +16 -1
  60. package/lib/types/components/confirm/Confirm.d.ts +16 -1
  61. package/lib/types/components/confirm/Confirm.stories.d.ts +16 -1
  62. package/lib/types/components/date-picker/DatePicker.stories.d.ts +16 -1
  63. package/lib/types/components/date-range-picker/DateRangePicker.stories.d.ts +16 -1
  64. package/lib/types/components/dialog/Dialog.d.ts +16 -1
  65. package/lib/types/components/dialog/Dialog.stories.d.ts +16 -1
  66. package/lib/types/components/dialog/DialogPrimitive.d.ts +24 -9
  67. package/lib/types/components/draggable-list/DraggableList.d.ts +16 -1
  68. package/lib/types/components/draggable-list/DraggableList.stories.d.ts +16 -1
  69. package/lib/types/components/dropdown/Dropdown.d.ts +16 -1
  70. package/lib/types/components/dropdown/Dropdown.stories.d.ts +16 -1
  71. package/lib/types/components/dropdown/PopoverPrimitive.d.ts +16 -1
  72. package/lib/types/components/dropdown-menu/DropdownMenu.d.ts +16 -1
  73. package/lib/types/components/dropdown-menu/DropdownMenuPrimitive.d.ts +16 -1
  74. package/lib/types/components/form-layout/FormLayout.d.ts +16 -1
  75. package/lib/types/components/form-layout/FormLayout.stories.d.ts +16 -1
  76. package/lib/types/components/gallery/Gallery.d.ts +1 -1
  77. package/lib/types/components/gallery/Gallery.stories.d.ts +16 -1
  78. package/lib/types/components/gradient-color-picker/GradientColorPicker.stories.d.ts +16 -1
  79. package/lib/types/components/hover-card/HoverCard.d.ts +16 -1
  80. package/lib/types/components/hover-card/HoverCard.stories.d.ts +16 -1
  81. package/lib/types/components/hover-card/HoverCardPrimitive.d.ts +4 -4
  82. package/lib/types/components/input/Input.d.ts +19 -4
  83. package/lib/types/components/input/Input.stories.d.ts +16 -1
  84. package/lib/types/components/input-number/InputNumber.d.ts +17 -2
  85. package/lib/types/components/input-number/InputNumber.stories.d.ts +16 -1
  86. package/lib/types/components/kbd/Kbd.stories.d.ts +16 -1
  87. package/lib/types/components/message/Message.d.ts +16 -1
  88. package/lib/types/components/message/Message.stories.d.ts +16 -1
  89. package/lib/types/components/pager/Pager.stories.d.ts +16 -1
  90. package/lib/types/components/popup/Popup.d.ts +17 -2
  91. package/lib/types/components/popup/Popup.stories.d.ts +16 -1
  92. package/lib/types/components/radio/Radio.d.ts +16 -1
  93. package/lib/types/components/radio/Radio.stories.d.ts +16 -1
  94. package/lib/types/components/radio-group/RadioGroup.d.ts +16 -1
  95. package/lib/types/components/radio-group/RadioGroup.stories.d.ts +16 -1
  96. package/lib/types/components/segmented/Segmented.stories.d.ts +16 -1
  97. package/lib/types/components/select/MultipleSelect.d.ts +16 -1
  98. package/lib/types/components/select/Select.d.ts +16 -1
  99. package/lib/types/components/select/Select.stories.d.ts +16 -1
  100. package/lib/types/components/select-list/SelectList.stories.d.ts +16 -1
  101. package/lib/types/components/separator/Separator.d.ts +16 -1
  102. package/lib/types/components/textarea/Textarea.d.ts +17 -2
  103. package/lib/types/components/toaster/Toaster.d.ts +16 -1
  104. package/lib/types/components/tooltip/Tooltip.d.ts +16 -1
  105. package/lib/types/components/tooltip/Tooltip.stories.d.ts +16 -1
  106. package/lib/types/components/tree/Tree.d.ts +16 -1
  107. package/lib/types/components/tree/Tree.stories.d.ts +16 -1
  108. package/lib/types/components/tree/util.d.ts +16 -1
  109. package/lib/types/components/virtual-list/VirtualList.d.ts +16 -1
  110. package/lib/types/helper/clsx.d.ts +16 -1
  111. package/lib/types/index.d.ts +0 -1
  112. package/lib/types/locale/ca-ES.d.ts +16 -1
  113. package/lib/types/locale/es-ES.d.ts +16 -1
  114. package/lib/types/locale/fa-IR.d.ts +16 -1
  115. package/lib/types/locale/fr-FR.d.ts +16 -1
  116. package/lib/types/locale/ja-JP.d.ts +16 -1
  117. package/lib/types/locale/ko-KR.d.ts +16 -1
  118. package/lib/types/locale/ru-RU.d.ts +16 -1
  119. package/lib/types/locale/sk-SK.d.ts +16 -1
  120. package/lib/types/locale/vi-VN.d.ts +16 -1
  121. package/lib/types/locale/zh-CN.d.ts +16 -1
  122. package/lib/types/locale/zh-TW.d.ts +16 -1
  123. package/lib/umd/index.js +39 -208
  124. package/lib/umd/locale/ca-ES.js +1 -1
  125. package/lib/umd/locale/en-US.js +1 -1
  126. package/lib/umd/locale/es-ES.js +1 -1
  127. package/lib/umd/locale/fa-IR.js +1 -1
  128. package/lib/umd/locale/fr-FR.js +1 -1
  129. package/lib/umd/locale/ja-JP.js +1 -1
  130. package/lib/umd/locale/ko-KR.js +1 -1
  131. package/lib/umd/locale/ru-RU.js +1 -1
  132. package/lib/umd/locale/sk-SK.js +1 -1
  133. package/lib/umd/locale/vi-VN.js +1 -1
  134. package/lib/umd/locale/zh-CN.js +1 -1
  135. package/lib/umd/locale/zh-TW.js +1 -1
  136. package/package.json +8 -10
  137. package/LICENSE +0 -176
  138. package/lib/types/components/menu/Menu.d.ts +0 -27
  139. package/lib/types/components/menu/index.d.ts +0 -17
  140. package/lib/types/components/menu/menu.stories.d.ts +0 -27
  141. package/lib/types/type.d.ts +0 -18
package/lib/cjs/index.js CHANGED
@@ -1,12 +1,27 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const v=require("react/jsx-runtime"),y=require("react"),ut=require("react-dom"),uv=require("react-dom/client");function Xu(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const d=Xu(y),Qu=Xu(ut);function Ge({ref:e,...t}){const{icon:n,id:r,className:o,extend:i,...a}=t,s=`univerjs-icon univerjs-icon-${r} ${o||""}`.trim(),c=y.useRef(`_${dv()}`);return Ju(n,`${r}`,{defIds:n.defIds,idSuffix:c.current},{ref:e,className:s,...a},i)}function Ju(e,t,n,r,o){return y.createElement(e.tag,{key:t,...lv(e,n,o),...r},(cv(e,n).children||[]).map((i,a)=>Ju(i,`${t}-${e.tag}-${a}`,n,void 0,o)))}function lv(e,t,n){const r={...e.attrs};n!=null&&n.colorChannel1&&r.fill==="colorChannel1"&&(r.fill=n.colorChannel1),e.tag==="mask"&&r.id&&(r.id=r.id+t.idSuffix),Object.entries(r).forEach(([i,a])=>{i==="mask"&&typeof a=="string"&&(r[i]=a.replace(/url\(#(.*)\)/,`url(#$1${t.idSuffix})`))});const{defIds:o}=t;return!o||o.length===0||(e.tag==="use"&&r["xlink:href"]&&(r["xlink:href"]=r["xlink:href"]+t.idSuffix),Object.entries(r).forEach(([i,a])=>{typeof a=="string"&&(r[i]=a.replace(/url\(#(.*)\)/,`url(#$1${t.idSuffix})`))})),r}function cv(e,t){var r;const{defIds:n}=t;return!n||n.length===0?e:e.tag==="defs"&&((r=e.children)!=null&&r.length)?{...e,children:e.children.map(o=>typeof o.attrs.id=="string"&&n&&n.includes(o.attrs.id)?{...o,attrs:{...o.attrs,id:o.attrs.id+t.idSuffix}}:o)}:e}function dv(){return Math.random().toString(36).substring(2,8)}Ge.displayName="UniverIcon";const fv={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 17 16",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"currentColor",d:"M8.87598 11.8327C8.87598 11.5013 9.14461 11.2327 9.47598 11.2327H11.476C11.8073 11.2327 12.076 11.5013 12.076 11.8327C12.076 12.164 11.8073 12.4327 11.476 12.4327H9.47598C9.14461 12.4327 8.87598 12.164 8.87598 11.8327Z"}},{tag:"path",attrs:{fill:"currentColor",d:"M4.80898 11.2327C4.47761 11.2327 4.20898 11.5013 4.20898 11.8327C4.20898 12.164 4.47761 12.4327 4.80898 12.4327H6.80898C7.14036 12.4327 7.40898 12.164 7.40898 11.8327C7.40898 11.5013 7.14036 11.2327 6.80898 11.2327H4.80898Z"}},{tag:"path",attrs:{fill:"currentColor",d:"M8.87598 9.16592C8.87598 8.83455 9.14461 8.56592 9.47598 8.56592H11.476C11.8073 8.56592 12.076 8.83455 12.076 9.16592C12.076 9.49729 11.8073 9.76592 11.476 9.76592H9.47598C9.14461 9.76592 8.87598 9.49729 8.87598 9.16592Z"}},{tag:"path",attrs:{fill:"currentColor",d:"M4.80898 8.56592C4.47761 8.56592 4.20898 8.83455 4.20898 9.16592C4.20898 9.49729 4.47761 9.76592 4.80898 9.76592H6.80898C7.14036 9.76592 7.40898 9.49729 7.40898 9.16592C7.40898 8.83455 7.14036 8.56592 6.80898 8.56592H4.80898Z"}},{tag:"path",attrs:{fill:"currentColor",d:"M6.00615 1.69985C6.00615 1.36848 5.73752 1.09985 5.40615 1.09985C5.07478 1.09985 4.80615 1.36848 4.80615 1.69985V2.34009H3.64248C2.20654 2.34009 1.04248 3.50415 1.04248 4.94009V12.3C1.04248 13.7359 2.20654 14.9 3.64248 14.9H12.6425C14.0784 14.9 15.2425 13.7359 15.2425 12.3V4.94009C15.2425 3.50415 14.0784 2.34009 12.6425 2.34009H11.4798V1.69985C11.4798 1.36848 11.2112 1.09985 10.8798 1.09985C10.5484 1.09985 10.2798 1.36848 10.2798 1.69985V2.34009H6.00615V1.69985ZM14.0425 5.97021V4.94009C14.0425 4.16689 13.4157 3.54009 12.6425 3.54009H11.4798V4.09985C11.4798 4.43122 11.2112 4.69985 10.8798 4.69985C10.5484 4.69985 10.2798 4.43122 10.2798 4.09985V3.54009H6.00615V4.09985C6.00615 4.43122 5.73752 4.69985 5.40615 4.69985C5.07478 4.69985 4.80615 4.43122 4.80615 4.09985V3.54009H3.64248C2.86928 3.54009 2.24248 4.16689 2.24248 4.94009V5.97021H14.0425ZM2.24248 7.17021H14.0425V12.3C14.0425 13.0731 13.4157 13.7 12.6425 13.7H3.64248C2.86928 13.7 2.24248 13.0732 2.24248 12.3V7.17021Z",fillRule:"evenodd",clipRule:"evenodd"}}]},La=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"calendar-icon",ref:n,icon:fv}))});La.displayName="CalendarIcon";const vv={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"currentColor",d:"M14.1544 3.75557C14.3887 3.98988 14.3887 4.36978 14.1544 4.6041L6.51409 12.2444C6.40157 12.3569 6.24896 12.4201 6.08983 12.4201C5.9307 12.4201 5.77808 12.3569 5.66556 12.2444L1.84541 8.42425C1.6111 8.18993 1.6111 7.81003 1.84541 7.57572C2.07973 7.34141 2.45963 7.34141 2.69394 7.57572L6.08983 10.9716L13.3059 3.75557C13.5402 3.52126 13.9201 3.52126 14.1544 3.75557Z",fillRule:"evenodd",clipRule:"evenodd"}}]},br=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"check-mark-icon",ref:n,icon:vv}))});br.displayName="CheckMarkIcon";const mv={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 17 16",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"currentColor",d:"M8.24483 4.80026C8.24487 4.46889 7.97627 4.20023 7.6449 4.2002C7.31353 4.20016 7.04487 4.46876 7.04483 4.80013L7.04443 8.40306C7.04442 8.56222 7.10763 8.71486 7.22017 8.82739L9.64664 11.2539C9.88095 11.4882 10.2608 11.4882 10.4952 11.2539C10.7295 11.0195 10.7295 10.6396 10.4952 10.4053L8.24446 8.15463L8.24483 4.80026Z"}},{tag:"path",attrs:{fill:"currentColor",d:"M8.14248 0.899902C4.22126 0.899902 1.04248 4.07868 1.04248 7.9999C1.04248 11.9211 4.22126 15.0999 8.14248 15.0999C12.0637 15.0999 15.2425 11.9211 15.2425 7.9999C15.2425 4.07868 12.0637 0.899902 8.14248 0.899902ZM2.24248 7.9999C2.24248 4.74142 4.884 2.0999 8.14248 2.0999C11.401 2.0999 14.0425 4.74142 14.0425 7.9999C14.0425 11.2584 11.401 13.8999 8.14248 13.8999C4.884 13.8999 2.24248 11.2584 2.24248 7.9999Z",fillRule:"evenodd",clipRule:"evenodd"}}]},el=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"clock-icon",ref:n,icon:mv}))});el.displayName="ClockIcon";const pv={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"currentColor",d:"M3.71274 2.86421C3.47843 2.6299 3.09853 2.6299 2.86421 2.86421C2.6299 3.09853 2.6299 3.47843 2.86421 3.71274L7.15154 8.00007L2.86421 12.2874C2.6299 12.5217 2.6299 12.9016 2.86421 13.1359C3.09853 13.3702 3.47843 13.3702 3.71274 13.1359L8.00007 8.84859L12.2874 13.1359C12.5217 13.3702 12.9016 13.3702 13.1359 13.1359C13.3702 12.9016 13.3702 12.5217 13.1359 12.2874L8.84859 8.00007L13.1359 3.71274C13.3702 3.47843 13.3702 3.09853 13.1359 2.86421C12.9016 2.6299 12.5217 2.6299 12.2874 2.86421L8.00007 7.15154L3.71274 2.86421Z"}}]},ii=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"close-icon",ref:n,icon:pv}))});ii.displayName="CloseIcon";const hv={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"currentColor",d:"M5.3313 1.4667C5.3313 1.13533 5.59993 0.866699 5.9313 0.866699H10.069C10.4004 0.866699 10.669 1.13533 10.669 1.4667C10.669 1.79807 10.4004 2.0667 10.069 2.0667H5.9313C5.59993 2.0667 5.3313 1.79807 5.3313 1.4667Z"}},{tag:"path",attrs:{fill:"currentColor",d:"M1.09985 3.64443C1.09985 3.31306 1.36848 3.04443 1.69985 3.04443H14.2999C14.6312 3.04443 14.8999 3.31306 14.8999 3.64443C14.8999 3.9758 14.6312 4.24443 14.2999 4.24443H1.69985C1.36848 4.24443 1.09985 3.9758 1.09985 3.64443Z"}},{tag:"path",attrs:{fill:"currentColor",d:"M6.12398 8.30171C6.35829 8.0674 6.73819 8.0674 6.97251 8.30171L8.00007 9.32928L9.02764 8.30171C9.26195 8.0674 9.64185 8.0674 9.87617 8.30171C10.1105 8.53603 10.1105 8.91593 9.87617 9.15024L8.8486 10.1778L9.87617 11.2054C10.1105 11.4397 10.1105 11.8196 9.87617 12.0539C9.64185 12.2882 9.26195 12.2882 9.02764 12.0539L8.00007 11.0263L6.97251 12.0539C6.73819 12.2882 6.35829 12.2882 6.12398 12.0539C5.88966 11.8196 5.88966 11.4397 6.12398 11.2054L7.15154 10.1778L6.12398 9.15024C5.88966 8.91593 5.88966 8.53603 6.12398 8.30171Z"}},{tag:"path",attrs:{fill:"currentColor",d:"M4.75332 5.22217C3.86966 5.22217 3.15332 5.93851 3.15332 6.82217V12.5331C3.15332 13.9691 4.31738 15.1332 5.75332 15.1332H10.2465C11.6825 15.1332 12.8465 13.9691 12.8465 12.5331V6.82217C12.8465 5.93851 12.1302 5.22217 11.2465 5.22217H4.75332ZM4.35332 6.82217C4.35332 6.60125 4.53241 6.42217 4.75332 6.42217H11.2465C11.4674 6.42217 11.6465 6.60125 11.6465 6.82217V12.5331C11.6465 13.3063 11.0197 13.9332 10.2465 13.9332H5.75332C4.98012 13.9332 4.35332 13.3063 4.35332 12.5331V6.82217Z",fillRule:"evenodd",clipRule:"evenodd"}}]},tl=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"delete-icon",ref:n,icon:hv}))});tl.displayName="DeleteIcon";const gv={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 20 20",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"currentColor",d:"M10.5547 14.1884C10.2599 14.5214 9.74019 14.5214 9.4454 14.1884L3.71321 7.71335C3.29002 7.23532 3.6294 6.48161 4.26784 6.48161L15.7322 6.48161C16.3707 6.48161 16.7101 7.23532 16.2869 7.71335L10.5547 14.1884Z"}}]},nl=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"down-icon",ref:n,icon:gv}))});nl.displayName="DownIcon";const bv={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"currentColor",d:"M8.85869 12.9216C8.38445 13.4708 7.61555 13.4708 7.14131 12.9216L0.358114 5.06726C-0.406895 4.18144 0.134916 2.66683 1.2168 2.66683L14.7832 2.66683C15.8651 2.66683 16.4069 4.18144 15.6419 5.06726L8.85869 12.9216Z"}}]},rl=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"dropdown-icon",ref:n,icon:bv}))});rl.displayName="DropdownIcon";const yv={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"currentColor",d:"M15 8C15 11.866 11.866 15 8 15C4.13401 15 1 11.866 1 8C1 4.13401 4.13401 1 8 1C11.866 1 15 4.13401 15 8ZM10.3097 5.69014C10.544 5.92445 10.544 6.30435 10.3097 6.53867L8.84843 7.9999L10.3099 9.46137C10.5442 9.69569 10.5442 10.0756 10.3099 10.3099C10.0756 10.5442 9.69569 10.5442 9.46137 10.3099L7.9999 8.84843L6.53842 10.3099C6.30411 10.5442 5.92421 10.5442 5.6899 10.3099C5.45558 10.0756 5.45558 9.69569 5.6899 9.46137L7.15137 7.9999L5.69014 6.53867C5.45583 6.30435 5.45583 5.92445 5.69014 5.69014C5.92445 5.45583 6.30435 5.45583 6.53867 5.69014L7.9999 7.15137L9.46113 5.69014C9.69544 5.45583 10.0753 5.45583 10.3097 5.69014Z",fillRule:"evenodd",clipRule:"evenodd"}}]},ol=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"error-icon",ref:n,icon:yv}))});ol.displayName="ErrorIcon";const xv={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"currentColor",d:"M8.00016 1.33203C6.68162 1.33203 5.39269 1.72302 4.29636 2.45557C3.20004 3.18811 2.34555 4.2293 1.84097 5.44747C1.33638 6.66565 1.20436 8.00609 1.4616 9.2993C1.71883 10.5925 2.35377 11.7804 3.28612 12.7127C4.21847 13.6451 5.40636 14.28 6.69956 14.5373C7.99277 14.7945 9.33321 14.6625 10.5514 14.1579C11.7696 13.6533 12.8108 12.7988 13.5433 11.7025C14.2758 10.6062 14.6668 9.31724 14.6668 7.9987C14.6649 6.23118 13.9619 4.53662 12.7121 3.2868C11.4622 2.03697 9.76768 1.33397 8.00016 1.33203ZM7.66683 3.9987C7.86461 3.9987 8.05795 4.05735 8.2224 4.16723C8.38685 4.27711 8.51502 4.43329 8.59071 4.61601C8.6664 4.79874 8.6862 4.99981 8.64762 5.19379C8.60903 5.38777 8.51379 5.56595 8.37394 5.7058C8.23409 5.84566 8.0559 5.9409 7.86192 5.97948C7.66794 6.01807 7.46687 5.99826 7.28415 5.92258C7.10142 5.84689 6.94524 5.71872 6.83536 5.55427C6.72548 5.38982 6.66683 5.19648 6.66683 4.9987C6.66683 4.73348 6.77219 4.47913 6.95972 4.29159C7.14726 4.10405 7.40162 3.9987 7.66683 3.9987ZM9.3335 11.332H6.66683C6.49002 11.332 6.32045 11.2618 6.19543 11.1368C6.0704 11.0117 6.00016 10.8422 6.00016 10.6654C6.00016 10.4886 6.0704 10.319 6.19543 10.194C6.32045 10.0689 6.49002 9.9987 6.66683 9.9987H7.3335V7.9987H6.66683C6.49002 7.9987 6.32045 7.92846 6.19543 7.80343C6.0704 7.67841 6.00016 7.50884 6.00016 7.33203C6.00016 7.15522 6.0704 6.98565 6.19543 6.86063C6.32045 6.7356 6.49002 6.66536 6.66683 6.66536H8.00016C8.17698 6.66536 8.34655 6.7356 8.47157 6.86063C8.59659 6.98565 8.66683 7.15522 8.66683 7.33203V9.9987H9.3335C9.51031 9.9987 9.67988 10.0689 9.8049 10.194C9.92993 10.319 10.0002 10.4886 10.0002 10.6654C10.0002 10.8422 9.92993 11.0117 9.8049 11.1368C9.67988 11.2618 9.51031 11.332 9.3335 11.332Z"}}]},il=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"info-icon",ref:n,icon:xv}))});il.displayName="InfoIcon";const wv={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"currentColor",d:"M11.3536 6.14645C11.5488 6.34171 11.5488 6.65829 11.3536 6.85355L8.35355 9.85355C8.15829 10.0488 7.84171 10.0488 7.64645 9.85355L4.64645 6.85355C4.45118 6.65829 4.45118 6.34171 4.64645 6.14645C4.84171 5.95118 5.15829 5.95118 5.35355 6.14645L8 8.79289L10.6464 6.14645C10.8417 5.95118 11.1583 5.95118 11.3536 6.14645Z",fillRule:"evenodd",clipRule:"evenodd"}}]},$a=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"more-down-icon",ref:n,icon:wv}))});$a.displayName="MoreDownIcon";const Cv={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 17 16",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"currentColor",d:"M10.3536 12.3536C10.1583 12.5488 9.84171 12.5488 9.64645 12.3536L6.64645 9.35355C6.45118 9.15829 6.45118 8.84171 6.64645 8.64645L9.64645 5.64645C9.84171 5.45118 10.1583 5.45118 10.3536 5.64645C10.5488 5.84171 10.5488 6.15829 10.3536 6.35355L7.70711 9L10.3536 11.6464C10.5488 11.8417 10.5488 12.1583 10.3536 12.3536Z",fillRule:"evenodd",clipRule:"evenodd"}}]},al=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"more-left-icon",ref:n,icon:Cv}))});al.displayName="MoreLeftIcon";const Ev={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"currentColor",d:"M6.14645 4.64645C6.34171 4.45118 6.65829 4.45118 6.85355 4.64645L9.85355 7.64645C10.0488 7.84171 10.0488 8.15829 9.85355 8.35355L6.85355 11.3536C6.65829 11.5488 6.34171 11.5488 6.14645 11.3536C5.95118 11.1583 5.95118 10.8417 6.14645 10.6464L8.79289 8L6.14645 5.35355C5.95118 5.15829 5.95118 4.84171 6.14645 4.64645Z",fillRule:"evenodd",clipRule:"evenodd"}}]},Vr=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"more-right-icon",ref:n,icon:Ev}))});Vr.displayName="MoreRightIcon";const Sv={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"currentColor",d:"M4.64645 9.85355C4.45118 9.65829 4.45118 9.34171 4.64645 9.14645L7.64645 6.14645C7.84171 5.95118 8.15829 5.95118 8.35355 6.14645L11.3536 9.14645C11.5488 9.34171 11.5488 9.65829 11.3536 9.85355C11.1583 10.0488 10.8417 10.0488 10.6464 9.85355L8 7.20711L5.35355 9.85355C5.15829 10.0488 4.84171 10.0488 4.64645 9.85355Z",fillRule:"evenodd",clipRule:"evenodd"}}]},sl=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"more-up-icon",ref:n,icon:Sv}))});sl.displayName="MoreUpIcon";const Rv={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"currentColor",d:"M5.65252 5.41446C5.86681 5.53124 6.00016 5.75579 6.00016 5.99984V9.99984C6.00016 10.368 5.70168 10.6665 5.3335 10.6665C4.96531 10.6665 4.66683 10.368 4.66683 9.99984V7.22312L4.36151 7.42005C4.05209 7.61961 3.63948 7.53056 3.43992 7.22115C3.24035 6.91173 3.3294 6.49912 3.63882 6.29956L4.97215 5.43959C5.17724 5.30731 5.43822 5.29767 5.65252 5.41446Z"}},{tag:"path",attrs:{fill:"currentColor",d:"M12.3335 5.99984C12.3335 5.75579 12.2001 5.53124 11.9858 5.41446C11.7716 5.29767 11.5106 5.30731 11.3055 5.43959L9.97215 6.29956C9.66274 6.49912 9.57368 6.91173 9.77325 7.22115C9.97281 7.53056 10.3854 7.61961 10.6948 7.42005L11.0002 7.22312V9.99984C11.0002 10.368 11.2986 10.6665 11.6668 10.6665C12.035 10.6665 12.3335 10.368 12.3335 9.99984V5.99984Z"}},{tag:"path",attrs:{fill:"currentColor",d:"M8.00008 5.99984C8.36827 5.99984 8.66675 6.29831 8.66675 6.6665V6.99984C8.66675 7.36803 8.36827 7.6665 8.00008 7.6665C7.63189 7.6665 7.33341 7.36803 7.33341 6.99984V6.6665C7.33341 6.29831 7.63189 5.99984 8.00008 5.99984Z"}},{tag:"path",attrs:{fill:"currentColor",d:"M8.66675 8.99984C8.66675 8.63165 8.36827 8.33317 8.00008 8.33317C7.63189 8.33317 7.33341 8.63165 7.33341 8.99984V9.33317C7.33341 9.70136 7.63189 9.99984 8.00008 9.99984C8.36827 9.99984 8.66675 9.70136 8.66675 9.33317V8.99984Z"}},{tag:"path",attrs:{fill:"currentColor",d:"M0.666748 2.99984C0.666748 2.26346 1.2637 1.6665 2.00008 1.6665H14.0001C14.7365 1.6665 15.3334 2.26346 15.3334 2.99984V12.9998C15.3334 13.7362 14.7365 14.3332 14.0001 14.3332H2.00008C1.26371 14.3332 0.666748 13.7362 0.666748 12.9998V2.99984ZM14.0001 2.99984H2.00008V12.9998H14.0001V2.99984Z",fillRule:"evenodd",clipRule:"evenodd"}}]},ul=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"one-to-one-icon",ref:n,icon:Rv}))});ul.displayName="OneToOneIcon";const Mv={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"currentColor",d:"M8 15C11.866 15 15 11.866 15 8C15 4.13401 11.866 1 8 1C4.13401 1 1 4.13401 1 8C1 11.866 4.13401 15 8 15ZM11.7245 6.42417C11.9588 6.18985 11.9588 5.80995 11.7245 5.57564C11.4901 5.34132 11.1102 5.34132 10.8759 5.57564L7.3002 9.15137L5.72446 7.57564C5.49014 7.34132 5.11025 7.34132 4.87593 7.57564C4.64162 7.80995 4.64162 8.18985 4.87593 8.42417L6.87593 10.4242C7.11025 10.6585 7.49014 10.6585 7.72446 10.4242L11.7245 6.42417Z",fillRule:"evenodd",clipRule:"evenodd"}}]},ll=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"success-icon",ref:n,icon:Mv}))});ll.displayName="SuccessIcon";const Nv={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"currentColor",d:"M15 8C15 11.866 11.866 15 8 15C4.13401 15 1 11.866 1 8C1 4.13401 4.13401 1 8 1C11.866 1 15 4.13401 15 8ZM8.00008 12.3671C8.46031 12.3671 8.83342 11.994 8.83342 11.5338C8.83342 11.0735 8.46031 10.7004 8.00008 10.7004C7.53985 10.7004 7.16675 11.0735 7.16675 11.5338C7.16675 11.994 7.53985 12.3671 8.00008 12.3671ZM8.5999 4.4335C8.5999 4.10213 8.33127 3.8335 7.9999 3.8335C7.66853 3.8335 7.3999 4.10213 7.3999 4.4335V9.36683C7.3999 9.6982 7.66853 9.96683 7.9999 9.96683C8.33127 9.96683 8.5999 9.6982 8.5999 9.36683V4.4335Z",fillRule:"evenodd",clipRule:"evenodd"}}]},cl=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"warning-icon",ref:n,icon:Nv}))});cl.displayName="WarningIcon";const Pv={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"currentColor",d:"M8.04883 5.38216C8.04883 5.01397 7.75035 4.71549 7.38216 4.71549C7.01397 4.71549 6.71549 5.01397 6.71549 5.38216V6.71897L5.3865 6.7207C5.01831 6.72117 4.72022 7.02004 4.7207 7.38823C4.72118 7.75642 5.02005 8.05451 5.38824 8.05403L6.71549 8.0523V9.38216C6.71549 9.75035 7.01397 10.0488 7.38216 10.0488C7.75035 10.0488 8.04883 9.75035 8.04883 9.38216V8.05056L9.38304 8.04883C9.75123 8.04835 10.0493 7.74948 10.0488 7.38129C10.0484 7.0131 9.74949 6.71502 9.3813 6.7155L8.04883 6.71723V5.38216Z"}},{tag:"path",attrs:{fill:"currentColor",d:"M7.38216 1.04883C3.88437 1.04883 1.04883 3.88437 1.04883 7.38216C1.04883 10.88 3.88437 13.7155 7.38216 13.7155C8.89089 13.7155 10.2764 13.1879 11.3643 12.3072L13.813 14.7559C14.0733 15.0162 14.4954 15.0162 14.7558 14.7559C15.0161 14.4955 15.0161 14.0734 14.7558 13.8131L12.3071 11.3644C13.1879 10.2765 13.7155 8.89095 13.7155 7.38216C13.7155 3.88437 10.88 1.04883 7.38216 1.04883ZM2.38216 7.38216C2.38216 4.62075 4.62075 2.38216 7.38216 2.38216C10.1436 2.38216 12.3822 4.62075 12.3822 7.38216C12.3822 10.1436 10.1436 12.3822 7.38216 12.3822C4.62075 12.3822 2.38216 10.1436 2.38216 7.38216Z",fillRule:"evenodd",clipRule:"evenodd"}}]},dl=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"zoom-in-icon",ref:n,icon:Pv}))});dl.displayName="ZoomInIcon";const kv={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"currentColor",d:"M4.71549 7.38216C4.71549 7.01397 5.01397 6.71549 5.38216 6.71549H9.38216C9.75035 6.71549 10.0488 7.01397 10.0488 7.38216C10.0488 7.75035 9.75035 8.04883 9.38216 8.04883H5.38216C5.01397 8.04883 4.71549 7.75035 4.71549 7.38216Z"}},{tag:"path",attrs:{fill:"currentColor",d:"M1.04883 7.38216C1.04883 3.88437 3.88437 1.04883 7.38216 1.04883C10.88 1.04883 13.7155 3.88437 13.7155 7.38216C13.7155 8.89095 13.1879 10.2765 12.3071 11.3644L14.7558 13.8131C15.0161 14.0734 15.0161 14.4955 14.7558 14.7559C14.4954 15.0162 14.0733 15.0162 13.813 14.7559L11.3643 12.3072C10.2764 13.1879 8.89089 13.7155 7.38216 13.7155C3.88437 13.7155 1.04883 10.88 1.04883 7.38216ZM7.38216 2.38216C4.62075 2.38216 2.38216 4.62075 2.38216 7.38216C2.38216 10.1436 4.62075 12.3822 7.38216 12.3822C10.1436 12.3822 12.3822 10.1436 12.3822 7.38216C12.3822 4.62075 10.1436 2.38216 7.38216 2.38216Z",fillRule:"evenodd",clipRule:"evenodd"}}]},fl=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"zoom-out-icon",ref:n,icon:kv}))});fl.displayName="ZoomOutIcon";const _v={tag:"svg",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16",width:"1em",height:"1em"},children:[{tag:"path",attrs:{fill:"#0B9EFB",d:"M8.79993 14.0166C8.79993 14.4585 8.44176 14.8166 7.99993 14.8166C4.23529 14.8166 1.18345 11.7648 1.18345 8.00017C1.18345 4.23554 4.23529 1.18369 7.99993 1.1837C11.7646 1.1837 14.8164 4.23554 14.8164 8.00017C14.8164 8.442 14.4582 8.80017 14.0164 8.80017C13.5746 8.80017 13.2164 8.442 13.2164 8.00017C13.2164 5.11919 10.8809 2.7837 7.99993 2.7837C5.11895 2.7837 2.78345 5.11919 2.78345 8.00017C2.78345 10.8812 5.11895 13.2166 7.99993 13.2166C8.44176 13.2166 8.79993 13.5748 8.79993 14.0166Z",fillOpacity:.2,fillRule:"evenodd",clipRule:"evenodd"}},{tag:"path",attrs:{fill:"#0B9EFB",d:"M7.20007 1.98384C7.20007 1.54201 7.55824 1.18384 8.00007 1.18384C11.7647 1.18384 14.8165 4.23568 14.8165 8.00032C14.8165 11.765 11.7647 14.8168 8.00007 14.8168C4.23543 14.8168 1.18359 11.765 1.18359 8.00032C1.18359 7.55849 1.54177 7.20031 1.98359 7.20031C2.42542 7.20031 2.78359 7.55849 2.78359 8.00032C2.78359 10.8813 5.11909 13.2168 8.00007 13.2168C10.8811 13.2168 13.2165 10.8813 13.2165 8.00032C13.2165 5.11933 10.8811 2.78384 8.00007 2.78384C7.55824 2.78384 7.20007 2.42567 7.20007 1.98384Z",fillRule:"evenodd",clipRule:"evenodd"}}]},vl=y.forwardRef(function(t,n){return y.createElement(Ge,Object.assign({},t,{id:"loading-multi-icon",ref:n,icon:_v}))});vl.displayName="LoadingMultiIcon";function ml(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=ml(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function pl(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=ml(e))&&(r&&(r+=" "),r+=t);return r}const Fa="-",Iv=e=>{const t=Av(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:a=>{const s=a.split(Fa);return s[0]===""&&s.length!==1&&s.shift(),hl(s,t)||Dv(a)},getConflictingClassGroupIds:(a,s)=>{const c=n[a]||[];return s&&r[a]?[...c,...r[a]]:c}}},hl=(e,t)=>{var a;if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),o=r?hl(e.slice(1),r):void 0;if(o)return o;if(t.validators.length===0)return;const i=e.join(Fa);return(a=t.validators.find(({validator:s})=>s(i)))==null?void 0:a.classGroupId},As=/^\[(.+)\]$/,Dv=e=>{if(As.test(e)){const t=As.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},Av=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return Ov(Object.entries(e.classGroups),n).forEach(([i,a])=>{sa(a,r,i,t)}),r},sa=(e,t,n,r)=>{e.forEach(o=>{if(typeof o=="string"){const i=o===""?t:Ts(t,o);i.classGroupId=n;return}if(typeof o=="function"){if(Tv(o)){sa(o(r),t,n,r);return}t.validators.push({validator:o,classGroupId:n});return}Object.entries(o).forEach(([i,a])=>{sa(a,Ts(t,i),n,r)})})},Ts=(e,t)=>{let n=e;return t.split(Fa).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},Tv=e=>e.isThemeGetter,Ov=(e,t)=>t?e.map(([n,r])=>{const o=r.map(i=>typeof i=="string"?t+i:typeof i=="object"?Object.fromEntries(Object.entries(i).map(([a,s])=>[t+a,s])):i);return[n,o]}):e,jv=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const o=(i,a)=>{n.set(i,a),t++,t>e&&(t=0,r=n,n=new Map)};return{get(i){let a=n.get(i);if(a!==void 0)return a;if((a=r.get(i))!==void 0)return o(i,a),a},set(i,a){n.has(i)?n.set(i,a):o(i,a)}}},gl="!",Lv=e=>{const{separator:t,experimentalParseClassName:n}=e,r=t.length===1,o=t[0],i=t.length,a=s=>{const c=[];let l=0,f=0,u;for(let h=0;h<s.length;h++){let x=s[h];if(l===0){if(x===o&&(r||s.slice(h,h+i)===t)){c.push(s.slice(f,h)),f=h+i;continue}if(x==="/"){u=h;continue}}x==="["?l++:x==="]"&&l--}const m=c.length===0?s:s.substring(f),p=m.startsWith(gl),g=p?m.substring(1):m,b=u&&u>f?u-f:void 0;return{modifiers:c,hasImportantModifier:p,baseClassName:g,maybePostfixModifierPosition:b}};return n?s=>n({className:s,parseClassName:a}):a},$v=e=>{if(e.length<=1)return e;const t=[];let n=[];return e.forEach(r=>{r[0]==="["?(t.push(...n.sort(),r),n=[]):n.push(r)}),t.push(...n.sort()),t},Fv=e=>({cache:jv(e.cacheSize),parseClassName:Lv(e),...Iv(e)}),zv=/\s+/,Bv=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:o}=t,i=[],a=e.trim().split(zv);let s="";for(let c=a.length-1;c>=0;c-=1){const l=a[c],{modifiers:f,hasImportantModifier:u,baseClassName:m,maybePostfixModifierPosition:p}=n(l);let g=!!p,b=r(g?m.substring(0,p):m);if(!b){if(!g){s=l+(s.length>0?" "+s:s);continue}if(b=r(m),!b){s=l+(s.length>0?" "+s:s);continue}g=!1}const h=$v(f).join(":"),x=u?h+gl:h,E=x+b;if(i.includes(E))continue;i.push(E);const w=o(b,g);for(let C=0;C<w.length;++C){const S=w[C];i.push(x+S)}s=l+(s.length>0?" "+s:s)}return s};function Hv(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=bl(t))&&(r&&(r+=" "),r+=n);return r}const bl=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=bl(e[r]))&&(n&&(n+=" "),n+=t);return n};function Vv(e,...t){let n,r,o,i=a;function a(c){const l=t.reduce((f,u)=>u(f),e());return n=Fv(l),r=n.cache.get,o=n.cache.set,i=s,s(c)}function s(c){const l=r(c);if(l)return l;const f=Bv(c,n);return o(c,f),f}return function(){return i(Hv.apply(null,arguments))}}const Te=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},yl=/^\[(?:([a-z-]+):)?(.+)\]$/i,Wv=/^\d+\/\d+$/,Kv=new Set(["px","full","screen"]),Uv=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Gv=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Yv=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,Zv=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,qv=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,rn=e=>cr(e)||Kv.has(e)||Wv.test(e),Cn=e=>yr(e,"length",om),cr=e=>!!e&&!Number.isNaN(Number(e)),zi=e=>yr(e,"number",cr),Ir=e=>!!e&&Number.isInteger(Number(e)),Xv=e=>e.endsWith("%")&&cr(e.slice(0,-1)),de=e=>yl.test(e),En=e=>Uv.test(e),Qv=new Set(["length","size","percentage"]),Jv=e=>yr(e,Qv,xl),em=e=>yr(e,"position",xl),tm=new Set(["image","url"]),nm=e=>yr(e,tm,am),rm=e=>yr(e,"",im),Dr=()=>!0,yr=(e,t,n)=>{const r=yl.exec(e);return r?r[1]?typeof t=="string"?r[1]===t:t.has(r[1]):n(r[2]):!1},om=e=>Gv.test(e)&&!Yv.test(e),xl=()=>!1,im=e=>Zv.test(e),am=e=>qv.test(e),sm=()=>{const e=Te("colors"),t=Te("spacing"),n=Te("blur"),r=Te("brightness"),o=Te("borderColor"),i=Te("borderRadius"),a=Te("borderSpacing"),s=Te("borderWidth"),c=Te("contrast"),l=Te("grayscale"),f=Te("hueRotate"),u=Te("invert"),m=Te("gap"),p=Te("gradientColorStops"),g=Te("gradientColorStopPositions"),b=Te("inset"),h=Te("margin"),x=Te("opacity"),E=Te("padding"),w=Te("saturate"),C=Te("scale"),S=Te("sepia"),R=Te("skew"),L=Te("space"),D=Te("translate"),H=()=>["auto","contain","none"],k=()=>["auto","hidden","clip","visible","scroll"],T=()=>["auto",de,t],F=()=>[de,t],z=()=>["",rn,Cn],A=()=>["auto",cr,de],_=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],M=()=>["solid","dashed","dotted","double","none"],I=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],N=()=>["start","end","center","between","around","evenly","stretch"],P=()=>["","0",de],j=()=>["auto","avoid","all","avoid-page","page","left","right","column"],B=()=>[cr,de];return{cacheSize:500,separator:":",theme:{colors:[Dr],spacing:[rn,Cn],blur:["none","",En,de],brightness:B(),borderColor:[e],borderRadius:["none","","full",En,de],borderSpacing:F(),borderWidth:z(),contrast:B(),grayscale:P(),hueRotate:B(),invert:P(),gap:F(),gradientColorStops:[e],gradientColorStopPositions:[Xv,Cn],inset:T(),margin:T(),opacity:B(),padding:F(),saturate:B(),scale:B(),sepia:P(),skew:B(),space:F(),translate:F()},classGroups:{aspect:[{aspect:["auto","square","video",de]}],container:["container"],columns:[{columns:[En]}],"break-after":[{"break-after":j()}],"break-before":[{"break-before":j()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[..._(),de]}],overflow:[{overflow:k()}],"overflow-x":[{"overflow-x":k()}],"overflow-y":[{"overflow-y":k()}],overscroll:[{overscroll:H()}],"overscroll-x":[{"overscroll-x":H()}],"overscroll-y":[{"overscroll-y":H()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[b]}],"inset-x":[{"inset-x":[b]}],"inset-y":[{"inset-y":[b]}],start:[{start:[b]}],end:[{end:[b]}],top:[{top:[b]}],right:[{right:[b]}],bottom:[{bottom:[b]}],left:[{left:[b]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Ir,de]}],basis:[{basis:T()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",de]}],grow:[{grow:P()}],shrink:[{shrink:P()}],order:[{order:["first","last","none",Ir,de]}],"grid-cols":[{"grid-cols":[Dr]}],"col-start-end":[{col:["auto",{span:["full",Ir,de]},de]}],"col-start":[{"col-start":A()}],"col-end":[{"col-end":A()}],"grid-rows":[{"grid-rows":[Dr]}],"row-start-end":[{row:["auto",{span:[Ir,de]},de]}],"row-start":[{"row-start":A()}],"row-end":[{"row-end":A()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",de]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",de]}],gap:[{gap:[m]}],"gap-x":[{"gap-x":[m]}],"gap-y":[{"gap-y":[m]}],"justify-content":[{justify:["normal",...N()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...N(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...N(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[E]}],px:[{px:[E]}],py:[{py:[E]}],ps:[{ps:[E]}],pe:[{pe:[E]}],pt:[{pt:[E]}],pr:[{pr:[E]}],pb:[{pb:[E]}],pl:[{pl:[E]}],m:[{m:[h]}],mx:[{mx:[h]}],my:[{my:[h]}],ms:[{ms:[h]}],me:[{me:[h]}],mt:[{mt:[h]}],mr:[{mr:[h]}],mb:[{mb:[h]}],ml:[{ml:[h]}],"space-x":[{"space-x":[L]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[L]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",de,t]}],"min-w":[{"min-w":[de,t,"min","max","fit"]}],"max-w":[{"max-w":[de,t,"none","full","min","max","fit","prose",{screen:[En]},En]}],h:[{h:[de,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[de,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[de,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[de,t,"auto","min","max","fit"]}],"font-size":[{text:["base",En,Cn]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",zi]}],"font-family":[{font:[Dr]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",de]}],"line-clamp":[{"line-clamp":["none",cr,zi]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",rn,de]}],"list-image":[{"list-image":["none",de]}],"list-style-type":[{list:["none","disc","decimal",de]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[x]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[x]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...M(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",rn,Cn]}],"underline-offset":[{"underline-offset":["auto",rn,de]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:F()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",de]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",de]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[x]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[..._(),em]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",Jv]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},nm]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[g]}],"gradient-via-pos":[{via:[g]}],"gradient-to-pos":[{to:[g]}],"gradient-from":[{from:[p]}],"gradient-via":[{via:[p]}],"gradient-to":[{to:[p]}],rounded:[{rounded:[i]}],"rounded-s":[{"rounded-s":[i]}],"rounded-e":[{"rounded-e":[i]}],"rounded-t":[{"rounded-t":[i]}],"rounded-r":[{"rounded-r":[i]}],"rounded-b":[{"rounded-b":[i]}],"rounded-l":[{"rounded-l":[i]}],"rounded-ss":[{"rounded-ss":[i]}],"rounded-se":[{"rounded-se":[i]}],"rounded-ee":[{"rounded-ee":[i]}],"rounded-es":[{"rounded-es":[i]}],"rounded-tl":[{"rounded-tl":[i]}],"rounded-tr":[{"rounded-tr":[i]}],"rounded-br":[{"rounded-br":[i]}],"rounded-bl":[{"rounded-bl":[i]}],"border-w":[{border:[s]}],"border-w-x":[{"border-x":[s]}],"border-w-y":[{"border-y":[s]}],"border-w-s":[{"border-s":[s]}],"border-w-e":[{"border-e":[s]}],"border-w-t":[{"border-t":[s]}],"border-w-r":[{"border-r":[s]}],"border-w-b":[{"border-b":[s]}],"border-w-l":[{"border-l":[s]}],"border-opacity":[{"border-opacity":[x]}],"border-style":[{border:[...M(),"hidden"]}],"divide-x":[{"divide-x":[s]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[s]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[x]}],"divide-style":[{divide:M()}],"border-color":[{border:[o]}],"border-color-x":[{"border-x":[o]}],"border-color-y":[{"border-y":[o]}],"border-color-s":[{"border-s":[o]}],"border-color-e":[{"border-e":[o]}],"border-color-t":[{"border-t":[o]}],"border-color-r":[{"border-r":[o]}],"border-color-b":[{"border-b":[o]}],"border-color-l":[{"border-l":[o]}],"divide-color":[{divide:[o]}],"outline-style":[{outline:["",...M()]}],"outline-offset":[{"outline-offset":[rn,de]}],"outline-w":[{outline:[rn,Cn]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:z()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[x]}],"ring-offset-w":[{"ring-offset":[rn,Cn]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",En,rm]}],"shadow-color":[{shadow:[Dr]}],opacity:[{opacity:[x]}],"mix-blend":[{"mix-blend":[...I(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":I()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[c]}],"drop-shadow":[{"drop-shadow":["","none",En,de]}],grayscale:[{grayscale:[l]}],"hue-rotate":[{"hue-rotate":[f]}],invert:[{invert:[u]}],saturate:[{saturate:[w]}],sepia:[{sepia:[S]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[c]}],"backdrop-grayscale":[{"backdrop-grayscale":[l]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[f]}],"backdrop-invert":[{"backdrop-invert":[u]}],"backdrop-opacity":[{"backdrop-opacity":[x]}],"backdrop-saturate":[{"backdrop-saturate":[w]}],"backdrop-sepia":[{"backdrop-sepia":[S]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[a]}],"border-spacing-x":[{"border-spacing-x":[a]}],"border-spacing-y":[{"border-spacing-y":[a]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",de]}],duration:[{duration:B()}],ease:[{ease:["linear","in","out","in-out",de]}],delay:[{delay:B()}],animate:[{animate:["none","spin","ping","pulse","bounce",de]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[C]}],"scale-x":[{"scale-x":[C]}],"scale-y":[{"scale-y":[C]}],rotate:[{rotate:[Ir,de]}],"translate-x":[{"translate-x":[D]}],"translate-y":[{"translate-y":[D]}],"skew-x":[{"skew-x":[R]}],"skew-y":[{"skew-y":[R]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",de]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",de]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":F()}],"scroll-mx":[{"scroll-mx":F()}],"scroll-my":[{"scroll-my":F()}],"scroll-ms":[{"scroll-ms":F()}],"scroll-me":[{"scroll-me":F()}],"scroll-mt":[{"scroll-mt":F()}],"scroll-mr":[{"scroll-mr":F()}],"scroll-mb":[{"scroll-mb":F()}],"scroll-ml":[{"scroll-ml":F()}],"scroll-p":[{"scroll-p":F()}],"scroll-px":[{"scroll-px":F()}],"scroll-py":[{"scroll-py":F()}],"scroll-ps":[{"scroll-ps":F()}],"scroll-pe":[{"scroll-pe":F()}],"scroll-pt":[{"scroll-pt":F()}],"scroll-pr":[{"scroll-pr":F()}],"scroll-pb":[{"scroll-pb":F()}],"scroll-pl":[{"scroll-pl":F()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",de]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[rn,Cn,zi]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},um=Vv(sm);function W(...e){return um(pl(e))}function lm(e){const{className:t,items:n}=e,[r,o]=y.useState(null),i=a=>{o(r===a?null:a)};return v.jsx("div",{"data-u-comp":"accordion",className:W("univer-divide-x-0 univer-divide-y univer-divide-solid univer-divide-gray-200 dark:!univer-divide-gray-600",t),children:n.map((a,s)=>v.jsxs("div",{children:[v.jsxs("button",{className:"univer-box-border univer-flex univer-w-full univer-cursor-pointer univer-items-center univer-gap-1.5 univer-border-none univer-bg-transparent univer-p-4 univer-text-left univer-text-gray-700 hover:univer-text-gray-900 focus:univer-outline-none dark:!univer-text-gray-200 dark:hover:!univer-text-white",type:"button",onClick:()=>i(s),children:[v.jsx(nl,{className:W("univer-size-2.5 univer-flex-shrink-0 univer-transition-transform",{"-univer-rotate-90":r!==s,"univer-rotate-0":r===s})}),v.jsx("span",{className:"univer-font-medium",children:a.label})]}),v.jsx("div",{className:W("univer-overflow-hidden univer-transition-[max-height,opacity] univer-duration-500 univer-ease-in-out",{"univer-max-h-screen":r===s,"univer-max-h-0":r!==s}),children:v.jsx("div",{className:"univer-box-border univer-px-4 univer-py-1.5",children:a.children})})]},s))})}const Os=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,js=pl,za=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return js(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:o,defaultVariants:i}=t,a=Object.keys(o).map(l=>{const f=n==null?void 0:n[l],u=i==null?void 0:i[l];if(f===null)return null;const m=Os(f)||Os(u);return o[l][m]}),s=n&&Object.entries(n).reduce((l,f)=>{let[u,m]=f;return m===void 0||(l[u]=m),l},{}),c=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((l,f)=>{let{class:u,className:m,...p}=f;return Object.entries(p).every(g=>{let[b,h]=g;return Array.isArray(h)?h.includes({...i,...s}[b]):{...i,...s}[b]===h})?[...l,u,m]:l},[]);return js(e,a,c,n==null?void 0:n.class,n==null?void 0:n.className)},cm=za(`
1
+ Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,t)=>()=>(e&&(t=e(e=0)),t),s=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),c=(e,n)=>{let r={};for(var i in e)t(r,i,{get:e[i],enumerable:!0});return n||t(r,Symbol.toStringTag,{value:`Module`}),r},l=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(var c=r(i),l=0,u=c.length,d;l<u;l++)d=c[l],!a.call(e,d)&&d!==o&&t(e,d,{get:(e=>i[e]).bind(null,d),enumerable:!(s=n(i,d))||s.enumerable});return e},u=(n,r,a)=>(a=n==null?{}:e(i(n)),l(r||!n||!n.__esModule?t(a,`default`,{value:n,enumerable:!0}):a,n)),d=e=>a.call(e,`module.exports`)?e[`module.exports`]:l(t({},`__esModule`,{value:!0}),e);let f=require(`@univerjs/icons`);
2
+ /**
3
+ * @license React
4
+ * react.production.js
5
+ *
6
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
7
+ *
8
+ * This source code is licensed under the MIT license found in the
9
+ * LICENSE file in the root directory of this source tree.
10
+ */
11
+ var p=s((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.consumer`),s=Symbol.for(`react.context`),c=Symbol.for(`react.forward_ref`),l=Symbol.for(`react.suspense`),u=Symbol.for(`react.memo`),d=Symbol.for(`react.lazy`),f=Symbol.for(`react.activity`),p=Symbol.iterator;function m(e){return typeof e!=`object`||!e?null:(e=p&&e[p]||e[`@@iterator`],typeof e==`function`?e:null)}var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,_={};function v(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){if(typeof e!=`object`&&typeof e!=`function`&&e!=null)throw Error(`takes an object of state variables to update or a function which returns an object of state variables.`);this.updater.enqueueSetState(this,e,t,`setState`)},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,`forceUpdate`)};function y(){}y.prototype=v.prototype;function b(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}var x=b.prototype=new y;x.constructor=b,g(x,v.prototype),x.isPureReactComponent=!0;var S=Array.isArray;function C(){}var w={H:null,A:null,T:null,S:null},T=Object.prototype.hasOwnProperty;function E(e,n,r){var i=r.ref;return{$$typeof:t,type:e,key:n,ref:i===void 0?null:i,props:r}}function D(e,t){return E(e.type,t,e.props)}function O(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function k(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var A=/\/+/g;function j(e,t){return typeof e==`object`&&e&&e.key!=null?k(``+e.key):t.toString(36)}function ee(e){switch(e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason;default:switch(typeof e.status==`string`?e.then(C,C):(e.status=`pending`,e.then(function(t){e.status===`pending`&&(e.status=`fulfilled`,e.value=t)},function(t){e.status===`pending`&&(e.status=`rejected`,e.reason=t)})),e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason}}throw e}function M(e,r,i,a,o){var s=typeof e;(s===`undefined`||s===`boolean`)&&(e=null);var c=!1;if(e===null)c=!0;else switch(s){case`bigint`:case`string`:case`number`:c=!0;break;case`object`:switch(e.$$typeof){case t:case n:c=!0;break;case d:return c=e._init,M(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+j(e,0):a,S(o)?(i=``,c!=null&&(i=c.replace(A,`$&/`)+`/`),M(o,r,i,``,function(e){return e})):o!=null&&(O(o)&&(o=D(o,i+(o.key==null||e&&e.key===o.key?``:(``+o.key).replace(A,`$&/`)+`/`)+c)),r.push(o)),1;c=0;var l=a===``?`.`:a+`:`;if(S(e))for(var u=0;u<e.length;u++)a=e[u],s=l+j(a,u),c+=M(a,r,i,s,o);else if(u=m(e),typeof u==`function`)for(e=u.call(e),u=0;!(a=e.next()).done;)a=a.value,s=l+j(a,u++),c+=M(a,r,i,s,o);else if(s===`object`){if(typeof e.then==`function`)return M(ee(e),r,i,a,o);throw r=String(e),Error(`Objects are not valid as a React child (found: `+(r===`[object Object]`?`object with keys {`+Object.keys(e).join(`, `)+`}`:r)+`). If you meant to render a collection of children, use an array instead.`)}return c}function N(e,t,n){if(e==null)return e;var r=[],i=0;return M(e,r,``,``,function(e){return t.call(n,e,i++)}),r}function P(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(t){(e._status===0||e._status===-1)&&(e._status=1,e._result=t)},function(t){(e._status===0||e._status===-1)&&(e._status=2,e._result=t)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var F=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},te={map:N,forEach:function(e,t,n){N(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return N(e,function(){t++}),t},toArray:function(e){return N(e,function(e){return e})||[]},only:function(e){if(!O(e))throw Error(`React.Children.only expected to receive a single React element child.`);return e}};e.Activity=f,e.Children=te,e.Component=v,e.Fragment=r,e.Profiler=a,e.PureComponent=b,e.StrictMode=i,e.Suspense=l,e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=w,e.__COMPILER_RUNTIME={__proto__:null,c:function(e){return w.H.useMemoCache(e)}},e.cache=function(e){return function(){return e.apply(null,arguments)}},e.cacheSignal=function(){return null},e.cloneElement=function(e,t,n){if(e==null)throw Error(`The argument must be a React element, but you passed `+e+`.`);var r=g({},e.props),i=e.key;if(t!=null)for(a in t.key!==void 0&&(i=``+t.key),t)!T.call(t,a)||a===`key`||a===`__self`||a===`__source`||a===`ref`&&t.ref===void 0||(r[a]=t[a]);var a=arguments.length-2;if(a===1)r.children=n;else if(1<a){for(var o=Array(a),s=0;s<a;s++)o[s]=arguments[s+2];r.children=o}return E(e.type,i,r)},e.createContext=function(e){return e={$$typeof:s,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:o,_context:e},e},e.createElement=function(e,t,n){var r,i={},a=null;if(t!=null)for(r in t.key!==void 0&&(a=``+t.key),t)T.call(t,r)&&r!==`key`&&r!==`__self`&&r!==`__source`&&(i[r]=t[r]);var o=arguments.length-2;if(o===1)i.children=n;else if(1<o){for(var s=Array(o),c=0;c<o;c++)s[c]=arguments[c+2];i.children=s}if(e&&e.defaultProps)for(r in o=e.defaultProps,o)i[r]===void 0&&(i[r]=o[r]);return E(e,a,i)},e.createRef=function(){return{current:null}},e.forwardRef=function(e){return{$$typeof:c,render:e}},e.isValidElement=O,e.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:P}},e.memo=function(e,t){return{$$typeof:u,type:e,compare:t===void 0?null:t}},e.startTransition=function(e){var t=w.T,n={};w.T=n;try{var r=e(),i=w.S;i!==null&&i(n,r),typeof r==`object`&&r&&typeof r.then==`function`&&r.then(C,F)}catch(e){F(e)}finally{t!==null&&n.types!==null&&(t.types=n.types),w.T=t}},e.unstable_useCacheRefresh=function(){return w.H.useCacheRefresh()},e.use=function(e){return w.H.use(e)},e.useActionState=function(e,t,n){return w.H.useActionState(e,t,n)},e.useCallback=function(e,t){return w.H.useCallback(e,t)},e.useContext=function(e){return w.H.useContext(e)},e.useDebugValue=function(){},e.useDeferredValue=function(e,t){return w.H.useDeferredValue(e,t)},e.useEffect=function(e,t){return w.H.useEffect(e,t)},e.useEffectEvent=function(e){return w.H.useEffectEvent(e)},e.useId=function(){return w.H.useId()},e.useImperativeHandle=function(e,t,n){return w.H.useImperativeHandle(e,t,n)},e.useInsertionEffect=function(e,t){return w.H.useInsertionEffect(e,t)},e.useLayoutEffect=function(e,t){return w.H.useLayoutEffect(e,t)},e.useMemo=function(e,t){return w.H.useMemo(e,t)},e.useOptimistic=function(e,t){return w.H.useOptimistic(e,t)},e.useReducer=function(e,t,n){return w.H.useReducer(e,t,n)},e.useRef=function(e){return w.H.useRef(e)},e.useState=function(e){return w.H.useState(e)},e.useSyncExternalStore=function(e,t,n){return w.H.useSyncExternalStore(e,t,n)},e.useTransition=function(){return w.H.useTransition()},e.version=`19.2.4`})),m=s(((e,t)=>{t.exports=p()})),h=u(m());function g(e){var t,n,r=``;if(typeof e==`string`||typeof e==`number`)r+=e;else if(typeof e==`object`)if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=g(e[t]))&&(r&&(r+=` `),r+=n)}else for(n in e)e[n]&&(r&&(r+=` `),r+=n);return r}function _(){for(var e,t,n=0,r=``,i=arguments.length;n<i;n++)(e=arguments[n])&&(t=g(e))&&(r&&(r+=` `),r+=t);return r}const v=e=>{let t=S(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:e=>{let n=e.split(`-`);return n[0]===``&&n.length!==1&&n.shift(),y(n,t)||x(e)},getConflictingClassGroupIds:(e,t)=>{let i=n[e]||[];return t&&r[e]?[...i,...r[e]]:i}}},y=(e,t)=>{var n;if(e.length===0)return t.classGroupId;let r=e[0],i=t.nextPart.get(r),a=i?y(e.slice(1),i):void 0;if(a)return a;if(t.validators.length===0)return;let o=e.join(`-`);return(n=t.validators.find(({validator:e})=>e(o)))==null?void 0:n.classGroupId},b=/^\[(.+)\]$/,x=e=>{if(b.test(e)){let t=b.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(`:`));if(n)return`arbitrary..`+n}},S=e=>{let{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return E(Object.entries(e.classGroups),n).forEach(([e,n])=>{C(n,r,e,t)}),r},C=(e,t,n,r)=>{e.forEach(e=>{if(typeof e==`string`){let r=e===``?t:w(t,e);r.classGroupId=n;return}if(typeof e==`function`){if(T(e)){C(e(r),t,n,r);return}t.validators.push({validator:e,classGroupId:n});return}Object.entries(e).forEach(([e,i])=>{C(i,w(t,e),n,r)})})},w=(e,t)=>{let n=e;return t.split(`-`).forEach(e=>{n.nextPart.has(e)||n.nextPart.set(e,{nextPart:new Map,validators:[]}),n=n.nextPart.get(e)}),n},T=e=>e.isThemeGetter,E=(e,t)=>t?e.map(([e,n])=>[e,n.map(e=>typeof e==`string`?t+e:typeof e==`object`?Object.fromEntries(Object.entries(e).map(([e,n])=>[t+e,n])):e)]):e,D=e=>{if(e<1)return{get:()=>void 0,set:()=>{}};let t=0,n=new Map,r=new Map,i=(i,a)=>{n.set(i,a),t++,t>e&&(t=0,r=n,n=new Map)};return{get(e){let t=n.get(e);if(t!==void 0)return t;if((t=r.get(e))!==void 0)return i(e,t),t},set(e,t){n.has(e)?n.set(e,t):i(e,t)}}},O=e=>{let{separator:t,experimentalParseClassName:n}=e,r=t.length===1,i=t[0],a=t.length,o=e=>{let n=[],o=0,s=0,c;for(let l=0;l<e.length;l++){let u=e[l];if(o===0){if(u===i&&(r||e.slice(l,l+a)===t)){n.push(e.slice(s,l)),s=l+a;continue}if(u===`/`){c=l;continue}}u===`[`?o++:u===`]`&&o--}let l=n.length===0?e:e.substring(s),u=l.startsWith(`!`);return{modifiers:n,hasImportantModifier:u,baseClassName:u?l.substring(1):l,maybePostfixModifierPosition:c&&c>s?c-s:void 0}};return n?e=>n({className:e,parseClassName:o}):o},k=e=>{if(e.length<=1)return e;let t=[],n=[];return e.forEach(e=>{e[0]===`[`?(t.push(...n.sort(),e),n=[]):n.push(e)}),t.push(...n.sort()),t},A=e=>({cache:D(e.cacheSize),parseClassName:O(e),...v(e)}),j=/\s+/,ee=(e,t)=>{let{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i}=t,a=[],o=e.trim().split(j),s=``;for(let e=o.length-1;e>=0;--e){let t=o[e],{modifiers:c,hasImportantModifier:l,baseClassName:u,maybePostfixModifierPosition:d}=n(t),f=!!d,p=r(f?u.substring(0,d):u);if(!p){if(!f){s=t+(s.length>0?` `+s:s);continue}if(p=r(u),!p){s=t+(s.length>0?` `+s:s);continue}f=!1}let m=k(c).join(`:`),h=l?m+`!`:m,g=h+p;if(a.includes(g))continue;a.push(g);let _=i(p,f);for(let e=0;e<_.length;++e){let t=_[e];a.push(h+t)}s=t+(s.length>0?` `+s:s)}return s};function M(){let e=0,t,n,r=``;for(;e<arguments.length;)(t=arguments[e++])&&(n=N(t))&&(r&&(r+=` `),r+=n);return r}const N=e=>{if(typeof e==`string`)return e;let t,n=``;for(let r=0;r<e.length;r++)e[r]&&(t=N(e[r]))&&(n&&(n+=` `),n+=t);return n};function P(e,...t){let n,r,i,a=o;function o(o){return n=A(t.reduce((e,t)=>t(e),e())),r=n.cache.get,i=n.cache.set,a=s,s(o)}function s(e){let t=r(e);if(t)return t;let a=ee(e,n);return i(e,a),a}return function(){return a(M.apply(null,arguments))}}const F=e=>{let t=t=>t[e]||[];return t.isThemeGetter=!0,t},te=/^\[(?:([a-z-]+):)?(.+)\]$/i,ne=/^\d+\/\d+$/,re=new Set([`px`,`full`,`screen`]),ie=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,I=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,ae=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,oe=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,se=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,ce=e=>ue(e)||re.has(e)||ne.test(e),le=e=>Se(e,`length`,Ce),ue=e=>!!e&&!Number.isNaN(Number(e)),de=e=>Se(e,`number`,ue),fe=e=>!!e&&Number.isInteger(Number(e)),pe=e=>e.endsWith(`%`)&&ue(e.slice(0,-1)),L=e=>te.test(e),me=e=>ie.test(e),he=new Set([`length`,`size`,`percentage`]),ge=e=>Se(e,he,we),_e=e=>Se(e,`position`,we),ve=new Set([`image`,`url`]),ye=e=>Se(e,ve,Ee),be=e=>Se(e,``,Te),xe=()=>!0,Se=(e,t,n)=>{let r=te.exec(e);return r?r[1]?typeof t==`string`?r[1]===t:t.has(r[1]):n(r[2]):!1},Ce=e=>I.test(e)&&!ae.test(e),we=()=>!1,Te=e=>oe.test(e),Ee=e=>se.test(e),De=P(()=>{let e=F(`colors`),t=F(`spacing`),n=F(`blur`),r=F(`brightness`),i=F(`borderColor`),a=F(`borderRadius`),o=F(`borderSpacing`),s=F(`borderWidth`),c=F(`contrast`),l=F(`grayscale`),u=F(`hueRotate`),d=F(`invert`),f=F(`gap`),p=F(`gradientColorStops`),m=F(`gradientColorStopPositions`),h=F(`inset`),g=F(`margin`),_=F(`opacity`),v=F(`padding`),y=F(`saturate`),b=F(`scale`),x=F(`sepia`),S=F(`skew`),C=F(`space`),w=F(`translate`),T=()=>[`auto`,`contain`,`none`],E=()=>[`auto`,`hidden`,`clip`,`visible`,`scroll`],D=()=>[`auto`,L,t],O=()=>[L,t],k=()=>[``,ce,le],A=()=>[`auto`,ue,L],j=()=>[`bottom`,`center`,`left`,`left-bottom`,`left-top`,`right`,`right-bottom`,`right-top`,`top`],ee=()=>[`solid`,`dashed`,`dotted`,`double`,`none`],M=()=>[`normal`,`multiply`,`screen`,`overlay`,`darken`,`lighten`,`color-dodge`,`color-burn`,`hard-light`,`soft-light`,`difference`,`exclusion`,`hue`,`saturation`,`color`,`luminosity`],N=()=>[`start`,`end`,`center`,`between`,`around`,`evenly`,`stretch`],P=()=>[``,`0`,L],te=()=>[`auto`,`avoid`,`all`,`avoid-page`,`page`,`left`,`right`,`column`],ne=()=>[ue,L];return{cacheSize:500,separator:`:`,theme:{colors:[xe],spacing:[ce,le],blur:[`none`,``,me,L],brightness:ne(),borderColor:[e],borderRadius:[`none`,``,`full`,me,L],borderSpacing:O(),borderWidth:k(),contrast:ne(),grayscale:P(),hueRotate:ne(),invert:P(),gap:O(),gradientColorStops:[e],gradientColorStopPositions:[pe,le],inset:D(),margin:D(),opacity:ne(),padding:O(),saturate:ne(),scale:ne(),sepia:P(),skew:ne(),space:O(),translate:O()},classGroups:{aspect:[{aspect:[`auto`,`square`,`video`,L]}],container:[`container`],columns:[{columns:[me]}],"break-after":[{"break-after":te()}],"break-before":[{"break-before":te()}],"break-inside":[{"break-inside":[`auto`,`avoid`,`avoid-page`,`avoid-column`]}],"box-decoration":[{"box-decoration":[`slice`,`clone`]}],box:[{box:[`border`,`content`]}],display:[`block`,`inline-block`,`inline`,`flex`,`inline-flex`,`table`,`inline-table`,`table-caption`,`table-cell`,`table-column`,`table-column-group`,`table-footer-group`,`table-header-group`,`table-row-group`,`table-row`,`flow-root`,`grid`,`inline-grid`,`contents`,`list-item`,`hidden`],float:[{float:[`right`,`left`,`none`,`start`,`end`]}],clear:[{clear:[`left`,`right`,`both`,`none`,`start`,`end`]}],isolation:[`isolate`,`isolation-auto`],"object-fit":[{object:[`contain`,`cover`,`fill`,`none`,`scale-down`]}],"object-position":[{object:[...j(),L]}],overflow:[{overflow:E()}],"overflow-x":[{"overflow-x":E()}],"overflow-y":[{"overflow-y":E()}],overscroll:[{overscroll:T()}],"overscroll-x":[{"overscroll-x":T()}],"overscroll-y":[{"overscroll-y":T()}],position:[`static`,`fixed`,`absolute`,`relative`,`sticky`],inset:[{inset:[h]}],"inset-x":[{"inset-x":[h]}],"inset-y":[{"inset-y":[h]}],start:[{start:[h]}],end:[{end:[h]}],top:[{top:[h]}],right:[{right:[h]}],bottom:[{bottom:[h]}],left:[{left:[h]}],visibility:[`visible`,`invisible`,`collapse`],z:[{z:[`auto`,fe,L]}],basis:[{basis:D()}],"flex-direction":[{flex:[`row`,`row-reverse`,`col`,`col-reverse`]}],"flex-wrap":[{flex:[`wrap`,`wrap-reverse`,`nowrap`]}],flex:[{flex:[`1`,`auto`,`initial`,`none`,L]}],grow:[{grow:P()}],shrink:[{shrink:P()}],order:[{order:[`first`,`last`,`none`,fe,L]}],"grid-cols":[{"grid-cols":[xe]}],"col-start-end":[{col:[`auto`,{span:[`full`,fe,L]},L]}],"col-start":[{"col-start":A()}],"col-end":[{"col-end":A()}],"grid-rows":[{"grid-rows":[xe]}],"row-start-end":[{row:[`auto`,{span:[fe,L]},L]}],"row-start":[{"row-start":A()}],"row-end":[{"row-end":A()}],"grid-flow":[{"grid-flow":[`row`,`col`,`dense`,`row-dense`,`col-dense`]}],"auto-cols":[{"auto-cols":[`auto`,`min`,`max`,`fr`,L]}],"auto-rows":[{"auto-rows":[`auto`,`min`,`max`,`fr`,L]}],gap:[{gap:[f]}],"gap-x":[{"gap-x":[f]}],"gap-y":[{"gap-y":[f]}],"justify-content":[{justify:[`normal`,...N()]}],"justify-items":[{"justify-items":[`start`,`end`,`center`,`stretch`]}],"justify-self":[{"justify-self":[`auto`,`start`,`end`,`center`,`stretch`]}],"align-content":[{content:[`normal`,...N(),`baseline`]}],"align-items":[{items:[`start`,`end`,`center`,`baseline`,`stretch`]}],"align-self":[{self:[`auto`,`start`,`end`,`center`,`stretch`,`baseline`]}],"place-content":[{"place-content":[...N(),`baseline`]}],"place-items":[{"place-items":[`start`,`end`,`center`,`baseline`,`stretch`]}],"place-self":[{"place-self":[`auto`,`start`,`end`,`center`,`stretch`]}],p:[{p:[v]}],px:[{px:[v]}],py:[{py:[v]}],ps:[{ps:[v]}],pe:[{pe:[v]}],pt:[{pt:[v]}],pr:[{pr:[v]}],pb:[{pb:[v]}],pl:[{pl:[v]}],m:[{m:[g]}],mx:[{mx:[g]}],my:[{my:[g]}],ms:[{ms:[g]}],me:[{me:[g]}],mt:[{mt:[g]}],mr:[{mr:[g]}],mb:[{mb:[g]}],ml:[{ml:[g]}],"space-x":[{"space-x":[C]}],"space-x-reverse":[`space-x-reverse`],"space-y":[{"space-y":[C]}],"space-y-reverse":[`space-y-reverse`],w:[{w:[`auto`,`min`,`max`,`fit`,`svw`,`lvw`,`dvw`,L,t]}],"min-w":[{"min-w":[L,t,`min`,`max`,`fit`]}],"max-w":[{"max-w":[L,t,`none`,`full`,`min`,`max`,`fit`,`prose`,{screen:[me]},me]}],h:[{h:[L,t,`auto`,`min`,`max`,`fit`,`svh`,`lvh`,`dvh`]}],"min-h":[{"min-h":[L,t,`min`,`max`,`fit`,`svh`,`lvh`,`dvh`]}],"max-h":[{"max-h":[L,t,`min`,`max`,`fit`,`svh`,`lvh`,`dvh`]}],size:[{size:[L,t,`auto`,`min`,`max`,`fit`]}],"font-size":[{text:[`base`,me,le]}],"font-smoothing":[`antialiased`,`subpixel-antialiased`],"font-style":[`italic`,`not-italic`],"font-weight":[{font:[`thin`,`extralight`,`light`,`normal`,`medium`,`semibold`,`bold`,`extrabold`,`black`,de]}],"font-family":[{font:[xe]}],"fvn-normal":[`normal-nums`],"fvn-ordinal":[`ordinal`],"fvn-slashed-zero":[`slashed-zero`],"fvn-figure":[`lining-nums`,`oldstyle-nums`],"fvn-spacing":[`proportional-nums`,`tabular-nums`],"fvn-fraction":[`diagonal-fractions`,`stacked-fractions`],tracking:[{tracking:[`tighter`,`tight`,`normal`,`wide`,`wider`,`widest`,L]}],"line-clamp":[{"line-clamp":[`none`,ue,de]}],leading:[{leading:[`none`,`tight`,`snug`,`normal`,`relaxed`,`loose`,ce,L]}],"list-image":[{"list-image":[`none`,L]}],"list-style-type":[{list:[`none`,`disc`,`decimal`,L]}],"list-style-position":[{list:[`inside`,`outside`]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[_]}],"text-alignment":[{text:[`left`,`center`,`right`,`justify`,`start`,`end`]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[_]}],"text-decoration":[`underline`,`overline`,`line-through`,`no-underline`],"text-decoration-style":[{decoration:[...ee(),`wavy`]}],"text-decoration-thickness":[{decoration:[`auto`,`from-font`,ce,le]}],"underline-offset":[{"underline-offset":[`auto`,ce,L]}],"text-decoration-color":[{decoration:[e]}],"text-transform":[`uppercase`,`lowercase`,`capitalize`,`normal-case`],"text-overflow":[`truncate`,`text-ellipsis`,`text-clip`],"text-wrap":[{text:[`wrap`,`nowrap`,`balance`,`pretty`]}],indent:[{indent:O()}],"vertical-align":[{align:[`baseline`,`top`,`middle`,`bottom`,`text-top`,`text-bottom`,`sub`,`super`,L]}],whitespace:[{whitespace:[`normal`,`nowrap`,`pre`,`pre-line`,`pre-wrap`,`break-spaces`]}],break:[{break:[`normal`,`words`,`all`,`keep`]}],hyphens:[{hyphens:[`none`,`manual`,`auto`]}],content:[{content:[`none`,L]}],"bg-attachment":[{bg:[`fixed`,`local`,`scroll`]}],"bg-clip":[{"bg-clip":[`border`,`padding`,`content`,`text`]}],"bg-opacity":[{"bg-opacity":[_]}],"bg-origin":[{"bg-origin":[`border`,`padding`,`content`]}],"bg-position":[{bg:[...j(),_e]}],"bg-repeat":[{bg:[`no-repeat`,{repeat:[``,`x`,`y`,`round`,`space`]}]}],"bg-size":[{bg:[`auto`,`cover`,`contain`,ge]}],"bg-image":[{bg:[`none`,{"gradient-to":[`t`,`tr`,`r`,`br`,`b`,`bl`,`l`,`tl`]},ye]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[m]}],"gradient-via-pos":[{via:[m]}],"gradient-to-pos":[{to:[m]}],"gradient-from":[{from:[p]}],"gradient-via":[{via:[p]}],"gradient-to":[{to:[p]}],rounded:[{rounded:[a]}],"rounded-s":[{"rounded-s":[a]}],"rounded-e":[{"rounded-e":[a]}],"rounded-t":[{"rounded-t":[a]}],"rounded-r":[{"rounded-r":[a]}],"rounded-b":[{"rounded-b":[a]}],"rounded-l":[{"rounded-l":[a]}],"rounded-ss":[{"rounded-ss":[a]}],"rounded-se":[{"rounded-se":[a]}],"rounded-ee":[{"rounded-ee":[a]}],"rounded-es":[{"rounded-es":[a]}],"rounded-tl":[{"rounded-tl":[a]}],"rounded-tr":[{"rounded-tr":[a]}],"rounded-br":[{"rounded-br":[a]}],"rounded-bl":[{"rounded-bl":[a]}],"border-w":[{border:[s]}],"border-w-x":[{"border-x":[s]}],"border-w-y":[{"border-y":[s]}],"border-w-s":[{"border-s":[s]}],"border-w-e":[{"border-e":[s]}],"border-w-t":[{"border-t":[s]}],"border-w-r":[{"border-r":[s]}],"border-w-b":[{"border-b":[s]}],"border-w-l":[{"border-l":[s]}],"border-opacity":[{"border-opacity":[_]}],"border-style":[{border:[...ee(),`hidden`]}],"divide-x":[{"divide-x":[s]}],"divide-x-reverse":[`divide-x-reverse`],"divide-y":[{"divide-y":[s]}],"divide-y-reverse":[`divide-y-reverse`],"divide-opacity":[{"divide-opacity":[_]}],"divide-style":[{divide:ee()}],"border-color":[{border:[i]}],"border-color-x":[{"border-x":[i]}],"border-color-y":[{"border-y":[i]}],"border-color-s":[{"border-s":[i]}],"border-color-e":[{"border-e":[i]}],"border-color-t":[{"border-t":[i]}],"border-color-r":[{"border-r":[i]}],"border-color-b":[{"border-b":[i]}],"border-color-l":[{"border-l":[i]}],"divide-color":[{divide:[i]}],"outline-style":[{outline:[``,...ee()]}],"outline-offset":[{"outline-offset":[ce,L]}],"outline-w":[{outline:[ce,le]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:k()}],"ring-w-inset":[`ring-inset`],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[_]}],"ring-offset-w":[{"ring-offset":[ce,le]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:[``,`inner`,`none`,me,be]}],"shadow-color":[{shadow:[xe]}],opacity:[{opacity:[_]}],"mix-blend":[{"mix-blend":[...M(),`plus-lighter`,`plus-darker`]}],"bg-blend":[{"bg-blend":M()}],filter:[{filter:[``,`none`]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[c]}],"drop-shadow":[{"drop-shadow":[``,`none`,me,L]}],grayscale:[{grayscale:[l]}],"hue-rotate":[{"hue-rotate":[u]}],invert:[{invert:[d]}],saturate:[{saturate:[y]}],sepia:[{sepia:[x]}],"backdrop-filter":[{"backdrop-filter":[``,`none`]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[c]}],"backdrop-grayscale":[{"backdrop-grayscale":[l]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[u]}],"backdrop-invert":[{"backdrop-invert":[d]}],"backdrop-opacity":[{"backdrop-opacity":[_]}],"backdrop-saturate":[{"backdrop-saturate":[y]}],"backdrop-sepia":[{"backdrop-sepia":[x]}],"border-collapse":[{border:[`collapse`,`separate`]}],"border-spacing":[{"border-spacing":[o]}],"border-spacing-x":[{"border-spacing-x":[o]}],"border-spacing-y":[{"border-spacing-y":[o]}],"table-layout":[{table:[`auto`,`fixed`]}],caption:[{caption:[`top`,`bottom`]}],transition:[{transition:[`none`,`all`,``,`colors`,`opacity`,`shadow`,`transform`,L]}],duration:[{duration:ne()}],ease:[{ease:[`linear`,`in`,`out`,`in-out`,L]}],delay:[{delay:ne()}],animate:[{animate:[`none`,`spin`,`ping`,`pulse`,`bounce`,L]}],transform:[{transform:[``,`gpu`,`none`]}],scale:[{scale:[b]}],"scale-x":[{"scale-x":[b]}],"scale-y":[{"scale-y":[b]}],rotate:[{rotate:[fe,L]}],"translate-x":[{"translate-x":[w]}],"translate-y":[{"translate-y":[w]}],"skew-x":[{"skew-x":[S]}],"skew-y":[{"skew-y":[S]}],"transform-origin":[{origin:[`center`,`top`,`top-right`,`right`,`bottom-right`,`bottom`,`bottom-left`,`left`,`top-left`,L]}],accent:[{accent:[`auto`,e]}],appearance:[{appearance:[`none`,`auto`]}],cursor:[{cursor:[`auto`,`default`,`pointer`,`wait`,`text`,`move`,`help`,`not-allowed`,`none`,`context-menu`,`progress`,`cell`,`crosshair`,`vertical-text`,`alias`,`copy`,`no-drop`,`grab`,`grabbing`,`all-scroll`,`col-resize`,`row-resize`,`n-resize`,`e-resize`,`s-resize`,`w-resize`,`ne-resize`,`nw-resize`,`se-resize`,`sw-resize`,`ew-resize`,`ns-resize`,`nesw-resize`,`nwse-resize`,`zoom-in`,`zoom-out`,L]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":[`none`,`auto`]}],resize:[{resize:[`none`,`y`,`x`,``]}],"scroll-behavior":[{scroll:[`auto`,`smooth`]}],"scroll-m":[{"scroll-m":O()}],"scroll-mx":[{"scroll-mx":O()}],"scroll-my":[{"scroll-my":O()}],"scroll-ms":[{"scroll-ms":O()}],"scroll-me":[{"scroll-me":O()}],"scroll-mt":[{"scroll-mt":O()}],"scroll-mr":[{"scroll-mr":O()}],"scroll-mb":[{"scroll-mb":O()}],"scroll-ml":[{"scroll-ml":O()}],"scroll-p":[{"scroll-p":O()}],"scroll-px":[{"scroll-px":O()}],"scroll-py":[{"scroll-py":O()}],"scroll-ps":[{"scroll-ps":O()}],"scroll-pe":[{"scroll-pe":O()}],"scroll-pt":[{"scroll-pt":O()}],"scroll-pr":[{"scroll-pr":O()}],"scroll-pb":[{"scroll-pb":O()}],"scroll-pl":[{"scroll-pl":O()}],"snap-align":[{snap:[`start`,`end`,`center`,`align-none`]}],"snap-stop":[{snap:[`normal`,`always`]}],"snap-type":[{snap:[`none`,`x`,`y`,`both`]}],"snap-strictness":[{snap:[`mandatory`,`proximity`]}],touch:[{touch:[`auto`,`none`,`manipulation`]}],"touch-x":[{"touch-pan":[`x`,`left`,`right`]}],"touch-y":[{"touch-pan":[`y`,`up`,`down`]}],"touch-pz":[`touch-pinch-zoom`],select:[{select:[`none`,`text`,`all`,`auto`]}],"will-change":[{"will-change":[`auto`,`scroll`,`contents`,`transform`,L]}],fill:[{fill:[e,`none`]}],"stroke-w":[{stroke:[ce,le,de]}],stroke:[{stroke:[e,`none`]}],sr:[`sr-only`,`not-sr-only`],"forced-color-adjust":[{"forced-color-adjust":[`auto`,`none`]}]},conflictingClassGroups:{overflow:[`overflow-x`,`overflow-y`],overscroll:[`overscroll-x`,`overscroll-y`],inset:[`inset-x`,`inset-y`,`start`,`end`,`top`,`right`,`bottom`,`left`],"inset-x":[`right`,`left`],"inset-y":[`top`,`bottom`],flex:[`basis`,`grow`,`shrink`],gap:[`gap-x`,`gap-y`],p:[`px`,`py`,`ps`,`pe`,`pt`,`pr`,`pb`,`pl`],px:[`pr`,`pl`],py:[`pt`,`pb`],m:[`mx`,`my`,`ms`,`me`,`mt`,`mr`,`mb`,`ml`],mx:[`mr`,`ml`],my:[`mt`,`mb`],size:[`w`,`h`],"font-size":[`leading`],"fvn-normal":[`fvn-ordinal`,`fvn-slashed-zero`,`fvn-figure`,`fvn-spacing`,`fvn-fraction`],"fvn-ordinal":[`fvn-normal`],"fvn-slashed-zero":[`fvn-normal`],"fvn-figure":[`fvn-normal`],"fvn-spacing":[`fvn-normal`],"fvn-fraction":[`fvn-normal`],"line-clamp":[`display`,`overflow`],rounded:[`rounded-s`,`rounded-e`,`rounded-t`,`rounded-r`,`rounded-b`,`rounded-l`,`rounded-ss`,`rounded-se`,`rounded-ee`,`rounded-es`,`rounded-tl`,`rounded-tr`,`rounded-br`,`rounded-bl`],"rounded-s":[`rounded-ss`,`rounded-es`],"rounded-e":[`rounded-se`,`rounded-ee`],"rounded-t":[`rounded-tl`,`rounded-tr`],"rounded-r":[`rounded-tr`,`rounded-br`],"rounded-b":[`rounded-br`,`rounded-bl`],"rounded-l":[`rounded-tl`,`rounded-bl`],"border-spacing":[`border-spacing-x`,`border-spacing-y`],"border-w":[`border-w-s`,`border-w-e`,`border-w-t`,`border-w-r`,`border-w-b`,`border-w-l`],"border-w-x":[`border-w-r`,`border-w-l`],"border-w-y":[`border-w-t`,`border-w-b`],"border-color":[`border-color-s`,`border-color-e`,`border-color-t`,`border-color-r`,`border-color-b`,`border-color-l`],"border-color-x":[`border-color-r`,`border-color-l`],"border-color-y":[`border-color-t`,`border-color-b`],"scroll-m":[`scroll-mx`,`scroll-my`,`scroll-ms`,`scroll-me`,`scroll-mt`,`scroll-mr`,`scroll-mb`,`scroll-ml`],"scroll-mx":[`scroll-mr`,`scroll-ml`],"scroll-my":[`scroll-mt`,`scroll-mb`],"scroll-p":[`scroll-px`,`scroll-py`,`scroll-ps`,`scroll-pe`,`scroll-pt`,`scroll-pr`,`scroll-pb`,`scroll-pl`],"scroll-px":[`scroll-pr`,`scroll-pl`],"scroll-py":[`scroll-pt`,`scroll-pb`],touch:[`touch-x`,`touch-y`,`touch-pz`],"touch-x":[`touch`],"touch-y":[`touch`],"touch-pz":[`touch`]},conflictingClassGroupModifiers:{"font-size":[`leading`]}}});function R(...e){return De(_(e))}
12
+ /**
13
+ * @license React
14
+ * react-jsx-runtime.production.js
15
+ *
16
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
17
+ *
18
+ * This source code is licensed under the MIT license found in the
19
+ * LICENSE file in the root directory of this source tree.
20
+ */
21
+ var Oe=s((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.fragment`);function r(e,n,r){var i=null;if(r!==void 0&&(i=``+r),n.key!==void 0&&(i=``+n.key),`key`in n)for(var a in r={},n)a!==`key`&&(r[a]=n[a]);else r=n;return n=r.ref,{$$typeof:t,type:e,key:i,ref:n===void 0?null:n,props:r}}e.Fragment=n,e.jsx=r,e.jsxs=r})),z=s(((e,t)=>{t.exports=Oe()}))();function ke(e){let{className:t,items:n}=e,[r,i]=(0,h.useState)(null),a=e=>{i(r===e?null:e)};return(0,z.jsx)(`div`,{"data-u-comp":`accordion`,className:R(`univer-divide-x-0 univer-divide-y univer-divide-solid univer-divide-gray-200 dark:!univer-divide-gray-600`,t),children:n.map((e,t)=>(0,z.jsxs)(`div`,{children:[(0,z.jsxs)(`button`,{className:`univer-box-border univer-flex univer-w-full univer-cursor-pointer univer-items-center univer-gap-1.5 univer-border-none univer-bg-transparent univer-p-4 univer-text-left univer-text-gray-700 hover:univer-text-gray-900 focus:univer-outline-none dark:!univer-text-gray-200 dark:hover:!univer-text-white`,type:`button`,onClick:()=>a(t),children:[(0,z.jsx)(f.DownIcon,{className:R(`univer-size-2.5 univer-flex-shrink-0 univer-transition-transform`,{"-univer-rotate-90":r!==t,"univer-rotate-0":r===t})}),(0,z.jsx)(`span`,{className:`univer-font-medium`,children:e.label})]}),(0,z.jsx)(`div`,{className:R(`univer-overflow-hidden univer-transition-[max-height,opacity] univer-duration-500 univer-ease-in-out`,{"univer-max-h-screen":r===t,"univer-max-h-0":r!==t}),children:(0,z.jsx)(`div`,{className:`univer-box-border univer-px-4 univer-py-1.5`,children:e.children})})]},t))})}const Ae=e=>typeof e==`boolean`?`${e}`:e===0?`0`:e,je=_,Me=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return je(e,n==null?void 0:n.class,n==null?void 0:n.className);let{variants:i,defaultVariants:a}=t,o=Object.keys(i).map(e=>{let t=n==null?void 0:n[e],r=a==null?void 0:a[e];if(t===null)return null;let o=Ae(t)||Ae(r);return i[e][o]}),s=n&&Object.entries(n).reduce((e,t)=>{let[n,r]=t;return r===void 0||(e[n]=r),e},{});return je(e,o,t==null||(r=t.compoundVariants)==null?void 0:r.reduce((e,t)=>{let{class:n,className:r,...i}=t;return Object.entries(i).every(e=>{let[t,n]=e;return Array.isArray(n)?n.includes({...a,...s}[t]):{...a,...s}[t]===n})?[...e,n,r]:e},[]),n==null?void 0:n.class,n==null?void 0:n.className)},Ne=Me(`
2
22
  univer-relative univer-inline-block univer-overflow-hidden univer-whitespace-nowrap univer-bg-gray-200
3
23
  univer-text-center univer-align-middle univer-text-white
4
- `,{variants:{shape:{circle:"univer-rounded-full",square:"univer-rounded"},size:{middle:"univer-size-9 univer-leading-9",small:"univer-size-7 univer-leading-7"}},defaultVariants:{shape:"circle",size:"middle"}});function dm(e){const{children:t,className:n,style:r,title:o,alt:i,shape:a="circle",size:s="middle",src:c,fit:l="fill",onError:f,onLoad:u}=e,m=typeof s=="number"?{width:`${s}px`,height:`${s}px`,lineHeight:`${s}px`}:{},p={objectFit:l};return v.jsxs("span",{className:W(cm({shape:a,size:typeof s=="number"?"middle":s}),{"univer-bg-transparent":c},n),style:{...m,...r,...c&&p},children:[c&&v.jsx("img",{className:"univer-block univer-size-full",src:c,title:o,alt:i,onError:f,onLoad:u}),t]})}function wl(e){const{className:t,children:n,closable:r=!1,onClose:o}=e;return v.jsxs("span",{"data-u-comp":"badge",className:W(`
5
- univer-box-border univer-inline-flex univer-items-center univer-gap-1 univer-truncate
6
- univer-rounded-md univer-border univer-border-solid univer-border-gray-100 univer-bg-gray-100
7
- univer-px-2.5 univer-py-0.5 univer-text-xs univer-font-medium univer-text-gray-900
8
- dark:!univer-border-gray-500 dark:!univer-bg-gray-700 dark:!univer-text-gray-300
9
- `,t),children:[v.jsx("span",{className:"univer-flex-1 univer-truncate",children:n}),r&&v.jsx("button",{className:"univer-flex univer-cursor-pointer univer-items-center univer-justify-center univer-border-none univer-p-0 univer-outline-none univer-transition-opacity hover:univer-opacity-70",type:"button","aria-label":"Close badge",onClick:o,children:v.jsx(ii,{className:"univer-text-current"})})]})}function Ls(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Qr(...e){return t=>{let n=!1;const r=e.map(o=>{const i=Ls(o,t);return!n&&typeof i=="function"&&(n=!0),i});if(n)return()=>{for(let o=0;o<r.length;o++){const i=r[o];typeof i=="function"?i():Ls(e[o],null)}}}}function Ue(...e){return d.useCallback(Qr(...e),e)}var fm=Symbol.for("react.lazy"),Lo=d[" use ".trim().toString()];function vm(e){return typeof e=="object"&&e!==null&&"then"in e}function Cl(e){return e!=null&&typeof e=="object"&&"$$typeof"in e&&e.$$typeof===fm&&"_payload"in e&&vm(e._payload)}function El(e){const t=pm(e),n=d.forwardRef((r,o)=>{let{children:i,...a}=r;Cl(i)&&typeof Lo=="function"&&(i=Lo(i._payload));const s=d.Children.toArray(i),c=s.find(gm);if(c){const l=c.props.children,f=s.map(u=>u===c?d.Children.count(l)>1?d.Children.only(null):d.isValidElement(l)?l.props.children:null:u);return v.jsx(t,{...a,ref:o,children:d.isValidElement(l)?d.cloneElement(l,void 0,f):null})}return v.jsx(t,{...a,ref:o,children:i})});return n.displayName=`${e}.Slot`,n}var mm=El("Slot");function pm(e){const t=d.forwardRef((n,r)=>{let{children:o,...i}=n;if(Cl(o)&&typeof Lo=="function"&&(o=Lo(o._payload)),d.isValidElement(o)){const a=ym(o),s=bm(i,o.props);return o.type!==d.Fragment&&(s.ref=r?Qr(r,a):a),d.cloneElement(o,s)}return d.Children.count(o)>1?d.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var hm=Symbol("radix.slottable");function gm(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===hm}function bm(e,t){const n={...t};for(const r in t){const o=e[r],i=t[r];/^on[A-Z]/.test(r)?o&&i?n[r]=(...s)=>{const c=i(...s);return o(...s),c}:o&&(n[r]=o):r==="style"?n[r]={...o,...i}:r==="className"&&(n[r]=[o,i].filter(Boolean).join(" "))}return{...e,...n}}function ym(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}const xm=za(`
24
+ `,{variants:{shape:{circle:`univer-rounded-full`,square:`univer-rounded`},size:{middle:`univer-size-9 univer-leading-9`,small:`univer-size-7 univer-leading-7`}},defaultVariants:{shape:`circle`,size:`middle`}});function Pe(e){let{children:t,className:n,style:r,title:i,alt:a,shape:o=`circle`,size:s=`middle`,src:c,fit:l=`fill`,onError:u,onLoad:d}=e,f=typeof s==`number`?{width:`${s}px`,height:`${s}px`,lineHeight:`${s}px`}:{},p={objectFit:l};return(0,z.jsxs)(`span`,{className:R(Ne({shape:o,size:typeof s==`number`?`middle`:s}),{"univer-bg-transparent":c},n),style:{...f,...r,...c&&p},children:[c&&(0,z.jsx)(`img`,{className:`univer-block univer-size-full`,src:c,title:i,alt:a,onError:u,onLoad:d}),t]})}function Fe(e){let{className:t,children:n,closable:r=!1,onClose:i}=e;return(0,z.jsxs)(`span`,{"data-u-comp":`badge`,className:R(`univer-box-border univer-inline-flex univer-items-center univer-gap-1 univer-truncate univer-rounded-md univer-border univer-border-solid univer-border-gray-100 univer-bg-gray-100 univer-px-2.5 univer-py-0.5 univer-text-xs univer-font-medium univer-text-gray-900 dark:!univer-border-gray-500 dark:!univer-bg-gray-700 dark:!univer-text-gray-300`,t),children:[(0,z.jsx)(`span`,{className:`univer-flex-1 univer-truncate`,children:n}),r&&(0,z.jsx)(`button`,{className:`univer-flex univer-cursor-pointer univer-items-center univer-justify-center univer-border-none univer-p-0 univer-outline-none univer-transition-opacity hover:univer-opacity-70`,type:`button`,"aria-label":`Close badge`,onClick:i,children:(0,z.jsx)(f.CloseIcon,{className:`univer-text-current`})})]})}function Ie(e,t){if(typeof e==`function`)return e(t);e!=null&&(e.current=t)}function Le(...e){return t=>{let n=!1,r=e.map(e=>{let r=Ie(e,t);return!n&&typeof r==`function`&&(n=!0),r});if(n)return()=>{for(let t=0;t<r.length;t++){let n=r[t];typeof n==`function`?n():Ie(e[t],null)}}}}function Re(...e){return h.useCallback(Le(...e),e)}var ze=Symbol.for(`react.lazy`),Be=h.use;function Ve(e){return typeof e==`object`&&!!e&&`then`in e}function He(e){return typeof e==`object`&&!!e&&`$$typeof`in e&&e.$$typeof===ze&&`_payload`in e&&Ve(e._payload)}function Ue(e){let t=Ge(e),n=h.forwardRef((e,n)=>{let{children:r,...i}=e;He(r)&&typeof Be==`function`&&(r=Be(r._payload));let a=h.Children.toArray(r),o=a.find(qe);if(o){let e=o.props.children,r=a.map(t=>t===o?h.Children.count(e)>1?h.Children.only(null):h.isValidElement(e)?e.props.children:null:t);return(0,z.jsx)(t,{...i,ref:n,children:h.isValidElement(e)?h.cloneElement(e,void 0,r):null})}return(0,z.jsx)(t,{...i,ref:n,children:r})});return n.displayName=`${e}.Slot`,n}var We=Ue(`Slot`);function Ge(e){let t=h.forwardRef((e,t)=>{let{children:n,...r}=e;if(He(n)&&typeof Be==`function`&&(n=Be(n._payload)),h.isValidElement(n)){let e=Ye(n),i=Je(r,n.props);return n.type!==h.Fragment&&(i.ref=t?Le(t,e):e),h.cloneElement(n,i)}return h.Children.count(n)>1?h.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Ke=Symbol(`radix.slottable`);function qe(e){return h.isValidElement(e)&&typeof e.type==`function`&&`__radixId`in e.type&&e.type.__radixId===Ke}function Je(e,t){let n={...t};for(let r in t){let i=e[r],a=t[r];/^on[A-Z]/.test(r)?i&&a?n[r]=(...e)=>{let t=a(...e);return i(...e),t}:i&&(n[r]=i):r===`style`?n[r]={...i,...a}:r===`className`&&(n[r]=[i,a].filter(Boolean).join(` `))}return{...e,...n}}function Ye(e){var t,n;let r=(t=Object.getOwnPropertyDescriptor(e.props,`ref`))==null?void 0:t.get,i=r&&`isReactWarning`in r&&r.isReactWarning;return i?e.ref:(r=(n=Object.getOwnPropertyDescriptor(e,`ref`))==null?void 0:n.get,i=r&&`isReactWarning`in r&&r.isReactWarning,i?e.props.ref:e.props.ref||e.ref)}const Xe=Me(`
10
25
  univer-box-border univer-inline-flex univer-cursor-pointer univer-select-none univer-items-center
11
26
  univer-justify-center univer-gap-2 univer-whitespace-nowrap univer-rounded-md univer-border univer-border-solid
12
27
  univer-text-sm univer-font-medium univer-transition-colors
@@ -46,252 +61,116 @@
46
61
  dark:!univer-text-white
47
62
  dark:hover:!univer-bg-gray-700
48
63
  dark:active:!univer-bg-gray-600
49
- `},size:{small:"univer-h-6 univer-rounded-md univer-px-1.5 univer-text-xs",middle:"univer-h-8 univer-rounded-lg univer-px-2 univer-text-sm",large:"univer-h-10 univer-rounded-lg univer-px-3 univer-text-sm"}},defaultVariants:{variant:"default",size:"middle"}}),un=y.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},i)=>{const a=r?mm:"button";return v.jsx(a,{className:W(xm({variant:t,size:n,className:e})),ref:i,"data-u-comp":"button",...o})});un.displayName="Button";const wm=({className:e,orientation:t="horizontal",children:n})=>{const r=y.Children.count(n),o=t==="horizontal",i=t==="vertical";return v.jsx("div",{className:W("univer-grid",{"univer-grid-flow-row":i,"univer-w-fit":i},e),children:y.Children.map(n,(a,s)=>{const c=s===0,l=s===r-1;return y.cloneElement(a,{className:W({"!univer-rounded-l-none":o&&!c,"!univer-rounded-r-none":o&&!l,"!univer-border-l-0":o&&!c,"!univer-rounded-t-none":i&&!c,"!univer-rounded-b-none":i&&!l,"!univer-border-t-0":i&&!c},a.props.className)})})})};function Ba(){return typeof window<"u"&&typeof document<"u"}const Zt=y.createContext({mountContainer:Ba()?document.body:null});function Cm(e){const{children:t,locale:n,mountContainer:r}=e,o=y.useMemo(()=>({locale:n,mountContainer:r}),[n,r]);return v.jsx(Zt.Provider,{value:o,children:t})}function Sl(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var ko={exports:{}},Em=ko.exports,$s;function Sm(){return $s||($s=1,(function(e,t){(function(n,r){e.exports=r()})(Em,(function(){var n=1e3,r=6e4,o=36e5,i="millisecond",a="second",s="minute",c="hour",l="day",f="week",u="month",m="quarter",p="year",g="date",b="Invalid Date",h=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,x=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,E={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(A){var _=["th","st","nd","rd"],M=A%100;return"["+A+(_[(M-20)%10]||_[M]||_[0])+"]"}},w=function(A,_,M){var I=String(A);return!I||I.length>=_?A:""+Array(_+1-I.length).join(M)+A},C={s:w,z:function(A){var _=-A.utcOffset(),M=Math.abs(_),I=Math.floor(M/60),N=M%60;return(_<=0?"+":"-")+w(I,2,"0")+":"+w(N,2,"0")},m:function A(_,M){if(_.date()<M.date())return-A(M,_);var I=12*(M.year()-_.year())+(M.month()-_.month()),N=_.clone().add(I,u),P=M-N<0,j=_.clone().add(I+(P?-1:1),u);return+(-(I+(M-N)/(P?N-j:j-N))||0)},a:function(A){return A<0?Math.ceil(A)||0:Math.floor(A)},p:function(A){return{M:u,y:p,w:f,d:l,D:g,h:c,m:s,s:a,ms:i,Q:m}[A]||String(A||"").toLowerCase().replace(/s$/,"")},u:function(A){return A===void 0}},S="en",R={};R[S]=E;var L="$isDayjsObject",D=function(A){return A instanceof F||!(!A||!A[L])},H=function A(_,M,I){var N;if(!_)return S;if(typeof _=="string"){var P=_.toLowerCase();R[P]&&(N=P),M&&(R[P]=M,N=P);var j=_.split("-");if(!N&&j.length>1)return A(j[0])}else{var B=_.name;R[B]=_,N=B}return!I&&N&&(S=N),N||!I&&S},k=function(A,_){if(D(A))return A.clone();var M=typeof _=="object"?_:{};return M.date=A,M.args=arguments,new F(M)},T=C;T.l=H,T.i=D,T.w=function(A,_){return k(A,{locale:_.$L,utc:_.$u,x:_.$x,$offset:_.$offset})};var F=(function(){function A(M){this.$L=H(M.locale,null,!0),this.parse(M),this.$x=this.$x||M.x||{},this[L]=!0}var _=A.prototype;return _.parse=function(M){this.$d=(function(I){var N=I.date,P=I.utc;if(N===null)return new Date(NaN);if(T.u(N))return new Date;if(N instanceof Date)return new Date(N);if(typeof N=="string"&&!/Z$/i.test(N)){var j=N.match(h);if(j){var B=j[2]-1||0,K=(j[7]||"0").substring(0,3);return P?new Date(Date.UTC(j[1],B,j[3]||1,j[4]||0,j[5]||0,j[6]||0,K)):new Date(j[1],B,j[3]||1,j[4]||0,j[5]||0,j[6]||0,K)}}return new Date(N)})(M),this.init()},_.init=function(){var M=this.$d;this.$y=M.getFullYear(),this.$M=M.getMonth(),this.$D=M.getDate(),this.$W=M.getDay(),this.$H=M.getHours(),this.$m=M.getMinutes(),this.$s=M.getSeconds(),this.$ms=M.getMilliseconds()},_.$utils=function(){return T},_.isValid=function(){return this.$d.toString()!==b},_.isSame=function(M,I){var N=k(M);return this.startOf(I)<=N&&N<=this.endOf(I)},_.isAfter=function(M,I){return k(M)<this.startOf(I)},_.isBefore=function(M,I){return this.endOf(I)<k(M)},_.$g=function(M,I,N){return T.u(M)?this[I]:this.set(N,M)},_.unix=function(){return Math.floor(this.valueOf()/1e3)},_.valueOf=function(){return this.$d.getTime()},_.startOf=function(M,I){var N=this,P=!!T.u(I)||I,j=T.p(M),B=function(q,ne){var ae=T.w(N.$u?Date.UTC(N.$y,ne,q):new Date(N.$y,ne,q),N);return P?ae:ae.endOf(l)},K=function(q,ne){return T.w(N.toDate()[q].apply(N.toDate("s"),(P?[0,0,0,0]:[23,59,59,999]).slice(ne)),N)},$=this.$W,O=this.$M,V=this.$D,U="set"+(this.$u?"UTC":"");switch(j){case p:return P?B(1,0):B(31,11);case u:return P?B(1,O):B(0,O+1);case f:var oe=this.$locale().weekStart||0,G=($<oe?$+7:$)-oe;return B(P?V-G:V+(6-G),O);case l:case g:return K(U+"Hours",0);case c:return K(U+"Minutes",1);case s:return K(U+"Seconds",2);case a:return K(U+"Milliseconds",3);default:return this.clone()}},_.endOf=function(M){return this.startOf(M,!1)},_.$set=function(M,I){var N,P=T.p(M),j="set"+(this.$u?"UTC":""),B=(N={},N[l]=j+"Date",N[g]=j+"Date",N[u]=j+"Month",N[p]=j+"FullYear",N[c]=j+"Hours",N[s]=j+"Minutes",N[a]=j+"Seconds",N[i]=j+"Milliseconds",N)[P],K=P===l?this.$D+(I-this.$W):I;if(P===u||P===p){var $=this.clone().set(g,1);$.$d[B](K),$.init(),this.$d=$.set(g,Math.min(this.$D,$.daysInMonth())).$d}else B&&this.$d[B](K);return this.init(),this},_.set=function(M,I){return this.clone().$set(M,I)},_.get=function(M){return this[T.p(M)]()},_.add=function(M,I){var N,P=this;M=Number(M);var j=T.p(I),B=function(O){var V=k(P);return T.w(V.date(V.date()+Math.round(O*M)),P)};if(j===u)return this.set(u,this.$M+M);if(j===p)return this.set(p,this.$y+M);if(j===l)return B(1);if(j===f)return B(7);var K=(N={},N[s]=r,N[c]=o,N[a]=n,N)[j]||1,$=this.$d.getTime()+M*K;return T.w($,this)},_.subtract=function(M,I){return this.add(-1*M,I)},_.format=function(M){var I=this,N=this.$locale();if(!this.isValid())return N.invalidDate||b;var P=M||"YYYY-MM-DDTHH:mm:ssZ",j=T.z(this),B=this.$H,K=this.$m,$=this.$M,O=N.weekdays,V=N.months,U=N.meridiem,oe=function(ne,ae,ue,he){return ne&&(ne[ae]||ne(I,P))||ue[ae].slice(0,he)},G=function(ne){return T.s(B%12||12,ne,"0")},q=U||function(ne,ae,ue){var he=ne<12?"AM":"PM";return ue?he.toLowerCase():he};return P.replace(x,(function(ne,ae){return ae||(function(ue){switch(ue){case"YY":return String(I.$y).slice(-2);case"YYYY":return T.s(I.$y,4,"0");case"M":return $+1;case"MM":return T.s($+1,2,"0");case"MMM":return oe(N.monthsShort,$,V,3);case"MMMM":return oe(V,$);case"D":return I.$D;case"DD":return T.s(I.$D,2,"0");case"d":return String(I.$W);case"dd":return oe(N.weekdaysMin,I.$W,O,2);case"ddd":return oe(N.weekdaysShort,I.$W,O,3);case"dddd":return O[I.$W];case"H":return String(B);case"HH":return T.s(B,2,"0");case"h":return G(1);case"hh":return G(2);case"a":return q(B,K,!0);case"A":return q(B,K,!1);case"m":return String(K);case"mm":return T.s(K,2,"0");case"s":return String(I.$s);case"ss":return T.s(I.$s,2,"0");case"SSS":return T.s(I.$ms,3,"0");case"Z":return j}return null})(ne)||j.replace(":","")}))},_.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},_.diff=function(M,I,N){var P,j=this,B=T.p(I),K=k(M),$=(K.utcOffset()-this.utcOffset())*r,O=this-K,V=function(){return T.m(j,K)};switch(B){case p:P=V()/12;break;case u:P=V();break;case m:P=V()/3;break;case f:P=(O-$)/6048e5;break;case l:P=(O-$)/864e5;break;case c:P=O/o;break;case s:P=O/r;break;case a:P=O/n;break;default:P=O}return N?P:T.a(P)},_.daysInMonth=function(){return this.endOf(u).$D},_.$locale=function(){return R[this.$L]},_.locale=function(M,I){if(!M)return this.$L;var N=this.clone(),P=H(M,I,!0);return P&&(N.$L=P),N},_.clone=function(){return T.w(this.$d,this)},_.toDate=function(){return new Date(this.valueOf())},_.toJSON=function(){return this.isValid()?this.toISOString():null},_.toISOString=function(){return this.$d.toISOString()},_.toString=function(){return this.$d.toUTCString()},A})(),z=F.prototype;return k.prototype=z,[["$ms",i],["$s",a],["$m",s],["$H",c],["$W",l],["$M",u],["$y",p],["$D",g]].forEach((function(A){z[A[1]]=function(_){return this.$g(_,A[0],A[1])}})),k.extend=function(A,_){return A.$i||(A(_,F,k),A.$i=!0),k},k.locale=H,k.isDayjs=D,k.unix=function(A){return k(1e3*A)},k.en=R[S],k.Ls=R,k.p={},k}))})(ko)),ko.exports}var Rm=Sm();const $o=Sl(Rm),kn="univer-scrollbar-thin univer-scrollbar-track-gray-50 univer-scrollbar-thumb-gray-300 dark:!univer-scrollbar-track-gray-900 dark:!univer-scrollbar-thumb-gray-700",xr="univer-border-gray-200 dark:!univer-border-gray-600 univer-border-solid",ct=W(xr,"univer-border"),Mm=W(xr,"univer-border-l univer-border-b univer-border-t-0 univer-border-r-0"),Rl=W(xr,"univer-border-l univer-border-b-0 univer-border-t-0 univer-border-r-0"),Nm=W(xr,"univer-border-l-0 univer-border-b-0 univer-border-t univer-border-r-0"),Pm=W(xr,"univer-border-l-0 univer-border-b univer-border-t-0 univer-border-r-0"),km=W(xr,"univer-border-l-0 univer-border-b-0 univer-border-t-0 univer-border-r"),_m="univer-divide-gray-200 dark:!univer-divide-gray-600 univer-divide-y univer-divide-x-0 univer-divide-solid",Im="univer-divide-gray-200 dark:!univer-divide-gray-600 univer-divide-x univer-divide-y-0 univer-divide-solid";function Ml(e){const{className:t,value:n,onValueChange:r}=e;function o(i){const a=i.target.value,[s,c,l]=a.split(":").map(Number),f=new Date(n!=null?n:Date.now());f.setHours(s,c,l,0),r==null||r(f)}return v.jsxs("div",{"data-u-comp":"time-input",className:"univer-relative univer-mx-auto univer-mt-1 univer-w-fit",children:[v.jsx(el,{className:"univer-absolute univer-left-2 univer-top-1/2 -univer-translate-y-1/2 univer-text-gray-600 dark:!univer-text-gray-400"}),v.jsx("input",{className:W("univer-block univer-h-7 univer-w-fit univer-appearance-none univer-rounded-md univer-bg-transparent univer-pl-6 univer-pr-2 univer-text-center univer-text-gray-800 univer-shadow univer-outline-none univer-transition-all univer-duration-200 focus:univer-border-primary-600 dark:!univer-text-white dark:focus:!univer-border-primary-500 [&::-webkit-calendar-picker-indicator]:univer-hidden [&::-webkit-calendar-picker-indicator]:univer-appearance-none",ct,t),type:"time",step:"1",value:$o(n).format("HH:mm:ss"),onChange:o})]})}function Dm(e,t){return new Date(e,t+1,0).getDate()}function Am(e,t){return new Date(e,t,1).getDay()}function Bi(e){const{className:t,...n}=e;return v.jsx("button",{className:W("univer-size-7 univer-rounded-md univer-border-none univer-bg-transparent univer-p-1 univer-transition-all hover:univer-bg-gray-200 dark:hover:!univer-bg-gray-600",t),type:"button",...n})}function Fo(e){const{className:t,max:n,min:r,showTime:o=!1,value:i,onValueChange:a}=e,{locale:s}=y.useContext(Zt),{year:c,weekDays:l,months:f}=s==null?void 0:s.Calendar,u=new Date,[m,p]=y.useState((i!=null?i:u).getFullYear()),[g,b]=y.useState((i!=null?i:u).getMonth());function h(){b(k=>k===0?(p(T=>T-1),11):k-1)}function x(){b(k=>k===11?(p(T=>T+1),0):k+1)}const E=Dm(m,g),w=Am(m,g),C=y.useMemo(()=>{const k=[];for(let T=0;T<w;T++)k.push(null);for(let T=1;T<=E;T++)k.push(T);return k},[E,w]);function S(k){return k&&m===(i==null?void 0:i.getFullYear())&&g===(i==null?void 0:i.getMonth())&&k===(i==null?void 0:i.getDate())}function R(k){return k&&m===u.getFullYear()&&g===u.getMonth()&&k===u.getDate()}function L(k){var _,M,I;if(!k)return!1;const T=(_=i==null?void 0:i.getHours())!=null?_:u.getHours(),F=(M=i==null?void 0:i.getMinutes())!=null?M:u.getMinutes(),z=(I=i==null?void 0:i.getSeconds())!=null?I:u.getSeconds(),A=new Date(m,g,k,T,F,z);return!!(r&&A<r||n&&A>n)}function D(k){var _,M,I;if(L(k))return;const T=(_=i==null?void 0:i.getHours())!=null?_:u.getHours(),F=(M=i==null?void 0:i.getMinutes())!=null?M:u.getMinutes(),z=(I=i==null?void 0:i.getSeconds())!=null?I:u.getSeconds(),A=new Date(m,g,k,T,F,z);a==null||a(A)}function H(k){var _;const T=k.getHours(),F=k.getMinutes(),z=k.getSeconds(),A=new Date(m,g,(_=i==null?void 0:i.getDate())!=null?_:u.getDate(),T,F,z);a==null||a(A)}return v.jsxs("div",{"data-u-comp":"calendar",className:W("univer-mx-auto univer-max-w-xs univer-select-none univer-rounded univer-bg-white univer-text-gray-900 dark:!univer-bg-gray-900 dark:!univer-text-white",t),children:[v.jsxs("nav",{className:"univer-mb-4 univer-flex univer-items-center univer-justify-between",children:[v.jsx(Bi,{className:"univer-text-lg univer-text-gray-500 dark:!univer-text-gray-200","aria-label":"Previous Month",onClick:h,children:v.jsx(Vr,{className:"univer-rotate-180"})}),v.jsxs("span",{className:"univer-flex univer-gap-0.5 univer-text-sm univer-font-medium",children:[v.jsx("span",{children:m}),v.jsx("span",{children:c}),v.jsx("span",{children:f[g]})]}),v.jsx(Bi,{className:"univer-text-lg univer-text-gray-500 dark:!univer-text-gray-200","aria-label":"Next Month",onClick:x,children:v.jsx(Vr,{})})]}),v.jsx("div",{className:"univer-mb-1 univer-grid univer-grid-cols-7 univer-gap-1 univer-text-center univer-text-sm univer-text-gray-500 dark:!univer-text-gray-200",children:l.map(k=>v.jsx("div",{children:k},k))}),v.jsx("div",{className:"univer-grid univer-grid-cols-7 univer-gap-1 univer-text-center",children:C.map((k,T)=>k?v.jsx(Bi,{className:W({"!univer-bg-primary-600 univer-font-bold univer-text-white":!R(k)&&S(k),"dark:!univer-text-white":!R(k)&&!S(k),"!univer-bg-primary-600 univer-text-white":R(k)&&S(k),"univer-font-semibold univer-text-primary-600 dark:!univer-text-primary-500":R(k)&&!S(k),"univer-cursor-not-allowed univer-opacity-40":L(k),"univer-hover:bg-primary-100 univer-cursor-pointer univer-text-gray-800":!S(k)&&!L(k)}),onClick:()=>D(k),disabled:L(k),children:k},T):v.jsx("div",{},T))}),o&&v.jsx(Ml,{value:i,onValueChange:H})]})}function Fs({emptyText:e}){return v.jsx("section",{className:"univer-h-8 univer-px-2 univer-pr-32 univer-text-sm/8 univer-text-gray-600 dark:!univer-text-gray-200",children:e})}function Tm(e){const{value:t,options:n=[],onChange:r,contentClassName:o,wrapperClassName:i}=e,{locale:a}=y.useContext(Zt),s=y.useMemo(()=>{const l=[n];return t.forEach((f,u)=>{const m=l[u].find(p=>p.value===f);m!=null&&m.children&&l.push(m.children)}),l},[t]);function c(l,f){if(f===t[l])return;if(t[l+1]){const m=t.slice(0,l+1);m[l]=f,r(m);return}const u=[...t];u[l]=f,r(u)}return v.jsxs("section",{"data-u-comp":"cascader-list",className:W("univer-overflow-auto-y univer-grid univer-h-full univer-max-h-80 univer-grid-flow-col univer-rounded univer-py-2 univer-text-gray-900 dark:!univer-text-white [&>ul:not(:last-child)]:univer-border-0 [&>ul:not(:last-child)]:univer-border-r [&>ul:not(:last-child)]:univer-border-solid [&>ul:not(:last-child)]:univer-border-r-gray-200",ct,kn,i),children:[s.map((l,f)=>l.length?v.jsx("ul",{className:W("univer-m-0 univer-h-full univer-max-h-full univer-list-none univer-overflow-auto univer-px-2",kn,o),children:l.map(u=>v.jsx("li",{children:v.jsxs("a",{className:W("univer-relative univer-block univer-h-8 univer-cursor-pointer univer-rounded univer-text-sm/8",{"univer-px-7":f>0,"univer-px-1.5":f===0,"univer-bg-gray-200 dark:!univer-bg-gray-600":u.value===t[f]}),onClick:()=>c(f,u.value),children:[f>0&&v.jsx("span",{className:"univer-absolute univer-left-2 univer-flex univer-h-full univer-items-center",children:u.value===t[f]&&v.jsx(br,{className:"univer-text-primary-600"})}),v.jsx("span",{children:u.label})]})},u.value))},f):v.jsx(Fs,{emptyText:a==null?void 0:a.CascaderList.empty},f)),t.length<=0&&v.jsx(Fs,{emptyText:a==null?void 0:a.CascaderList.empty})]})}function Om(e){const{children:t,className:n,style:r,value:o,disabled:i,direction:a="horizontal",onChange:s}=e,c=l=>{o.includes(l)?s(o.filter(f=>f!==l)):s([...o,l])};return v.jsx("div",{className:W("univer-flex univer-gap-2",{"univer-flex-col":a==="vertical"},n),style:r,children:y.Children.map(t,(l,f)=>y.isValidElement(l)?y.cloneElement(l,{key:f,children:l.props.children,checked:l.props.value?o.includes(l.props.value):!1,disabled:i!=null?i:l.props.disabled,onChange:c}):l)})}function Nl(e){const{children:t,className:n,style:r,checked:o=!1,indeterminate:i=!1,value:a,disabled:s=!1,onChange:c,contentClassName:l}=e,f=y.useRef(null);function u(m){var p,g;if(m.stopPropagation(),!(!c||s))if(typeof a<"u")c==null||c(a);else{const b=(g=(p=f==null?void 0:f.current)==null?void 0:p.checked)!=null?g:!1;c==null||c(b)}}return v.jsxs("label",{"data-u-comp":"checkbox",className:W("univer-box-border univer-inline-flex univer-items-center univer-gap-2 univer-text-sm",{"univer-cursor-pointer univer-text-gray-900 dark:!univer-text-white":!s,"univer-text-gray-400":s},n),style:r,children:[v.jsxs("span",{className:"univer-relative univer-block",children:[v.jsx("input",{ref:f,className:"univer-absolute univer-size-0 univer-opacity-0",type:"checkbox",checked:o,disabled:s,onChange:u}),v.jsxs("span",{className:W("univer-relative univer-box-border univer-flex univer-size-4 univer-items-center univer-justify-center univer-overflow-hidden univer-rounded univer-border univer-border-solid univer-transition-colors",{"univer-opacity-50":s,"univer-border-primary-600 univer-bg-primary-600":o||i,"univer-border-gray-300 univer-bg-gray-50 dark:!univer-border-gray-500 dark:!univer-bg-gray-600":!o&&!i}),children:[o&&v.jsx(br,{className:"univer-absolute univer-left-1/2 univer-top-1/2 univer-block univer-size-3 -univer-translate-x-1/2 -univer-translate-y-1/2 univer-text-white"}),i&&!o&&v.jsx("span",{className:"univer-absolute univer-left-1/2 univer-top-1/2 univer-block univer-h-0.5 univer-w-2.5 -univer-translate-x-1/2 -univer-translate-y-1/2 univer-rounded univer-bg-white"})]})]}),v.jsx("span",{className:W("univer-select-none",l),children:t})]})}function ie(e,t,{checkForDefaultPrevented:n=!0}={}){return function(o){if(e==null||e(o),n===!1||!o.defaultPrevented)return t==null?void 0:t(o)}}function jm(e,t){const n=d.createContext(t),r=i=>{const{children:a,...s}=i,c=d.useMemo(()=>s,Object.values(s));return v.jsx(n.Provider,{value:c,children:a})};r.displayName=e+"Provider";function o(i){const a=d.useContext(n);if(a)return a;if(t!==void 0)return t;throw new Error(`\`${i}\` must be used within \`${e}\``)}return[r,o]}function An(e,t=[]){let n=[];function r(i,a){const s=d.createContext(a),c=n.length;n=[...n,a];const l=u=>{var x;const{scope:m,children:p,...g}=u,b=((x=m==null?void 0:m[e])==null?void 0:x[c])||s,h=d.useMemo(()=>g,Object.values(g));return v.jsx(b.Provider,{value:h,children:p})};l.displayName=i+"Provider";function f(u,m){var b;const p=((b=m==null?void 0:m[e])==null?void 0:b[c])||s,g=d.useContext(p);if(g)return g;if(a!==void 0)return a;throw new Error(`\`${u}\` must be used within \`${i}\``)}return[l,f]}const o=()=>{const i=n.map(a=>d.createContext(a));return function(s){const c=(s==null?void 0:s[e])||i;return d.useMemo(()=>({[`__scope${e}`]:{...s,[e]:c}}),[s,c])}};return o.scopeName=e,[r,Lm(o,...t)]}function Lm(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(i){const a=r.reduce((s,{useScope:c,scopeName:l})=>{const u=c(i)[`__scope${l}`];return{...s,...u}},{});return d.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}var _n=globalThis!=null&&globalThis.document?d.useLayoutEffect:()=>{},$m=d[" useId ".trim().toString()]||(()=>{}),Fm=0;function on(e){const[t,n]=d.useState($m());return _n(()=>{n(r=>r!=null?r:String(Fm++))},[e]),e||(t?`radix-${t}`:"")}var zm=d[" useInsertionEffect ".trim().toString()]||_n;function wr({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[o,i,a]=Bm({defaultProp:t,onChange:n}),s=e!==void 0,c=s?e:o;{const f=d.useRef(e!==void 0);d.useEffect(()=>{const u=f.current;u!==s&&console.warn(`${r} is changing from ${u?"controlled":"uncontrolled"} to ${s?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),f.current=s},[s,r])}const l=d.useCallback(f=>{var u;if(s){const m=Hm(f)?f(e):f;m!==e&&((u=a.current)==null||u.call(a,m))}else i(f)},[s,e,i,a]);return[c,l]}function Bm({defaultProp:e,onChange:t}){const[n,r]=d.useState(e),o=d.useRef(n),i=d.useRef(t);return zm(()=>{i.current=t},[t]),d.useEffect(()=>{var a;o.current!==n&&((a=i.current)==null||a.call(i,n),o.current=n)},[n,o]),[n,r,i]}function Hm(e){return typeof e=="function"}function vr(e){const t=Vm(e),n=d.forwardRef((r,o)=>{const{children:i,...a}=r,s=d.Children.toArray(i),c=s.find(Km);if(c){const l=c.props.children,f=s.map(u=>u===c?d.Children.count(l)>1?d.Children.only(null):d.isValidElement(l)?l.props.children:null:u);return v.jsx(t,{...a,ref:o,children:d.isValidElement(l)?d.cloneElement(l,void 0,f):null})}return v.jsx(t,{...a,ref:o,children:i})});return n.displayName=`${e}.Slot`,n}function Vm(e){const t=d.forwardRef((n,r)=>{const{children:o,...i}=n;if(d.isValidElement(o)){const a=Gm(o),s=Um(i,o.props);return o.type!==d.Fragment&&(s.ref=r?Qr(r,a):a),d.cloneElement(o,s)}return d.Children.count(o)>1?d.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Wm=Symbol("radix.slottable");function Km(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Wm}function Um(e,t){const n={...t};for(const r in t){const o=e[r],i=t[r];/^on[A-Z]/.test(r)?o&&i?n[r]=(...s)=>{const c=i(...s);return o(...s),c}:o&&(n[r]=o):r==="style"?n[r]={...o,...i}:r==="className"&&(n[r]=[o,i].filter(Boolean).join(" "))}return{...e,...n}}function Gm(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Ym=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],$e=Ym.reduce((e,t)=>{const n=vr(`Primitive.${t}`),r=d.forwardRef((o,i)=>{const{asChild:a,...s}=o,c=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),v.jsx(c,{...s,ref:i})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Pl(e,t){e&&Qu.flushSync(()=>e.dispatchEvent(t))}function Ut(e){const t=d.useRef(e);return d.useEffect(()=>{t.current=e}),d.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}function Zm(e,t=globalThis==null?void 0:globalThis.document){const n=Ut(e);d.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var qm="DismissableLayer",ua="dismissableLayer.update",Xm="dismissableLayer.pointerDownOutside",Qm="dismissableLayer.focusOutside",zs,kl=d.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Jr=d.forwardRef((e,t)=>{var L;const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:i,onInteractOutside:a,onDismiss:s,...c}=e,l=d.useContext(kl),[f,u]=d.useState(null),m=(L=f==null?void 0:f.ownerDocument)!=null?L:globalThis==null?void 0:globalThis.document,[,p]=d.useState({}),g=Ue(t,D=>u(D)),b=Array.from(l.layers),[h]=[...l.layersWithOutsidePointerEventsDisabled].slice(-1),x=b.indexOf(h),E=f?b.indexOf(f):-1,w=l.layersWithOutsidePointerEventsDisabled.size>0,C=E>=x,S=tp(D=>{const H=D.target,k=[...l.branches].some(T=>T.contains(H));!C||k||(o==null||o(D),a==null||a(D),D.defaultPrevented||s==null||s())},m),R=np(D=>{const H=D.target;[...l.branches].some(T=>T.contains(H))||(i==null||i(D),a==null||a(D),D.defaultPrevented||s==null||s())},m);return Zm(D=>{E===l.layers.size-1&&(r==null||r(D),!D.defaultPrevented&&s&&(D.preventDefault(),s()))},m),d.useEffect(()=>{if(f)return n&&(l.layersWithOutsidePointerEventsDisabled.size===0&&(zs=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),l.layersWithOutsidePointerEventsDisabled.add(f)),l.layers.add(f),Bs(),()=>{n&&l.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=zs)}},[f,m,n,l]),d.useEffect(()=>()=>{f&&(l.layers.delete(f),l.layersWithOutsidePointerEventsDisabled.delete(f),Bs())},[f,l]),d.useEffect(()=>{const D=()=>p({});return document.addEventListener(ua,D),()=>document.removeEventListener(ua,D)},[]),v.jsx($e.div,{...c,ref:g,style:{pointerEvents:w?C?"auto":"none":void 0,...e.style},onFocusCapture:ie(e.onFocusCapture,R.onFocusCapture),onBlurCapture:ie(e.onBlurCapture,R.onBlurCapture),onPointerDownCapture:ie(e.onPointerDownCapture,S.onPointerDownCapture)})});Jr.displayName=qm;var Jm="DismissableLayerBranch",ep=d.forwardRef((e,t)=>{const n=d.useContext(kl),r=d.useRef(null),o=Ue(t,r);return d.useEffect(()=>{const i=r.current;if(i)return n.branches.add(i),()=>{n.branches.delete(i)}},[n.branches]),v.jsx($e.div,{...e,ref:o})});ep.displayName=Jm;function tp(e,t=globalThis==null?void 0:globalThis.document){const n=Ut(e),r=d.useRef(!1),o=d.useRef(()=>{});return d.useEffect(()=>{const i=s=>{if(s.target&&!r.current){let c=function(){_l(Xm,n,l,{discrete:!0})};const l={originalEvent:s};s.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}else t.removeEventListener("click",o.current);r.current=!1},a=window.setTimeout(()=>{t.addEventListener("pointerdown",i)},0);return()=>{window.clearTimeout(a),t.removeEventListener("pointerdown",i),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function np(e,t=globalThis==null?void 0:globalThis.document){const n=Ut(e),r=d.useRef(!1);return d.useEffect(()=>{const o=i=>{i.target&&!r.current&&_l(Qm,n,{originalEvent:i},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function Bs(){const e=new CustomEvent(ua);document.dispatchEvent(e)}function _l(e,t,n,{discrete:r}){const o=n.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?Pl(o,i):o.dispatchEvent(i)}var Hi="focusScope.autoFocusOnMount",Vi="focusScope.autoFocusOnUnmount",Hs={bubbles:!1,cancelable:!0},rp="FocusScope",ai=d.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:i,...a}=e,[s,c]=d.useState(null),l=Ut(o),f=Ut(i),u=d.useRef(null),m=Ue(t,b=>c(b)),p=d.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;d.useEffect(()=>{if(r){let b=function(w){if(p.paused||!s)return;const C=w.target;s.contains(C)?u.current=C:Rn(u.current,{select:!0})},h=function(w){if(p.paused||!s)return;const C=w.relatedTarget;C!==null&&(s.contains(C)||Rn(u.current,{select:!0}))},x=function(w){if(document.activeElement===document.body)for(const S of w)S.removedNodes.length>0&&Rn(s)};document.addEventListener("focusin",b),document.addEventListener("focusout",h);const E=new MutationObserver(x);return s&&E.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",b),document.removeEventListener("focusout",h),E.disconnect()}}},[r,s,p.paused]),d.useEffect(()=>{if(s){Ws.add(p);const b=document.activeElement;if(!s.contains(b)){const x=new CustomEvent(Hi,Hs);s.addEventListener(Hi,l),s.dispatchEvent(x),x.defaultPrevented||(op(lp(Il(s)),{select:!0}),document.activeElement===b&&Rn(s))}return()=>{s.removeEventListener(Hi,l),setTimeout(()=>{const x=new CustomEvent(Vi,Hs);s.addEventListener(Vi,f),s.dispatchEvent(x),x.defaultPrevented||Rn(b!=null?b:document.body,{select:!0}),s.removeEventListener(Vi,f),Ws.remove(p)},0)}}},[s,l,f,p]);const g=d.useCallback(b=>{if(!n&&!r||p.paused)return;const h=b.key==="Tab"&&!b.altKey&&!b.ctrlKey&&!b.metaKey,x=document.activeElement;if(h&&x){const E=b.currentTarget,[w,C]=ip(E);w&&C?!b.shiftKey&&x===C?(b.preventDefault(),n&&Rn(w,{select:!0})):b.shiftKey&&x===w&&(b.preventDefault(),n&&Rn(C,{select:!0})):x===E&&b.preventDefault()}},[n,r,p.paused]);return v.jsx($e.div,{tabIndex:-1,...a,ref:m,onKeyDown:g})});ai.displayName=rp;function op(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(Rn(r,{select:t}),document.activeElement!==n)return}function ip(e){const t=Il(e),n=Vs(t,e),r=Vs(t.reverse(),e);return[n,r]}function Il(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Vs(e,t){for(const n of e)if(!ap(n,{upTo:t}))return n}function ap(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function sp(e){return e instanceof HTMLInputElement&&"select"in e}function Rn(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&sp(e)&&t&&e.select()}}var Ws=up();function up(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=Ks(e,t),e.unshift(t)},remove(t){var n;e=Ks(e,t),(n=e[0])==null||n.resume()}}}function Ks(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function lp(e){return e.filter(t=>t.tagName!=="A")}var cp="Portal",eo=d.forwardRef((e,t)=>{var s;const{container:n,...r}=e,[o,i]=d.useState(!1);_n(()=>i(!0),[]);const a=n||o&&((s=globalThis==null?void 0:globalThis.document)==null?void 0:s.body);return a?ut.createPortal(v.jsx($e.div,{...r,ref:t}),a):null});eo.displayName=cp;function dp(e,t){return d.useReducer((n,r)=>{const o=t[n][r];return o!=null?o:n},e)}var Nt=e=>{const{present:t,children:n}=e,r=fp(t),o=typeof n=="function"?n({present:r.isPresent}):d.Children.only(n),i=Ue(r.ref,vp(o));return typeof n=="function"||r.isPresent?d.cloneElement(o,{ref:i}):null};Nt.displayName="Presence";function fp(e){const[t,n]=d.useState(),r=d.useRef(null),o=d.useRef(e),i=d.useRef("none"),a=e?"mounted":"unmounted",[s,c]=dp(a,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return d.useEffect(()=>{const l=ho(r.current);i.current=s==="mounted"?l:"none"},[s]),_n(()=>{const l=r.current,f=o.current;if(f!==e){const m=i.current,p=ho(l);e?c("MOUNT"):p==="none"||(l==null?void 0:l.display)==="none"?c("UNMOUNT"):c(f&&m!==p?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,c]),_n(()=>{var l;if(t){let f;const u=(l=t.ownerDocument.defaultView)!=null?l:window,m=g=>{const h=ho(r.current).includes(CSS.escape(g.animationName));if(g.target===t&&h&&(c("ANIMATION_END"),!o.current)){const x=t.style.animationFillMode;t.style.animationFillMode="forwards",f=u.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=x)})}},p=g=>{g.target===t&&(i.current=ho(r.current))};return t.addEventListener("animationstart",p),t.addEventListener("animationcancel",m),t.addEventListener("animationend",m),()=>{u.clearTimeout(f),t.removeEventListener("animationstart",p),t.removeEventListener("animationcancel",m),t.removeEventListener("animationend",m)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:d.useCallback(l=>{r.current=l?getComputedStyle(l):null,n(l)},[])}}function ho(e){return(e==null?void 0:e.animationName)||"none"}function vp(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Wi=0;function Ha(){d.useEffect(()=>{var t,n;const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",(t=e[0])!=null?t:Us()),document.body.insertAdjacentElement("beforeend",(n=e[1])!=null?n:Us()),Wi++,()=>{Wi===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(r=>r.remove()),Wi--}},[])}function Us(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var Vt=function(){return Vt=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(t[i]=n[i])}return t},Vt.apply(this,arguments)};function Dl(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function mp(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,i;r<o;r++)(i||!(r in t))&&(i||(i=Array.prototype.slice.call(t,0,r)),i[r]=t[r]);return e.concat(i||Array.prototype.slice.call(t))}var _o="right-scroll-bar-position",Io="width-before-scroll-bar",pp="with-scroll-bars-hidden",hp="--removed-body-scroll-bar-size";function Ki(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function gp(e,t){var n=y.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var o=n.value;o!==r&&(n.value=r,n.callback(r,o))}}}})[0];return n.callback=t,n.facade}var bp=typeof window<"u"?d.useLayoutEffect:d.useEffect,Gs=new WeakMap;function yp(e,t){var n=gp(null,function(r){return e.forEach(function(o){return Ki(o,r)})});return bp(function(){var r=Gs.get(n);if(r){var o=new Set(r),i=new Set(e),a=n.current;o.forEach(function(s){i.has(s)||Ki(s,null)}),i.forEach(function(s){o.has(s)||Ki(s,a)})}Gs.set(n,e)},[e]),n}function xp(e){return e}function wp(e,t){t===void 0&&(t=xp);var n=[],r=!1,o={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(i){var a=t(i,r);return n.push(a),function(){n=n.filter(function(s){return s!==a})}},assignSyncMedium:function(i){for(r=!0;n.length;){var a=n;n=[],a.forEach(i)}n={push:function(s){return i(s)},filter:function(){return n}}},assignMedium:function(i){r=!0;var a=[];if(n.length){var s=n;n=[],s.forEach(i),a=n}var c=function(){var f=a;a=[],f.forEach(i)},l=function(){return Promise.resolve().then(c)};l(),n={push:function(f){a.push(f),l()},filter:function(f){return a=a.filter(f),n}}}};return o}function Cp(e){e===void 0&&(e={});var t=wp(null);return t.options=Vt({async:!0,ssr:!1},e),t}var Al=function(e){var t=e.sideCar,n=Dl(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return d.createElement(r,Vt({},n))};Al.isSideCarExport=!0;function Ep(e,t){return e.useMedium(t),Al}var Tl=Cp(),Ui=function(){},si=d.forwardRef(function(e,t){var n=d.useRef(null),r=d.useState({onScrollCapture:Ui,onWheelCapture:Ui,onTouchMoveCapture:Ui}),o=r[0],i=r[1],a=e.forwardProps,s=e.children,c=e.className,l=e.removeScrollBar,f=e.enabled,u=e.shards,m=e.sideCar,p=e.noRelative,g=e.noIsolation,b=e.inert,h=e.allowPinchZoom,x=e.as,E=x===void 0?"div":x,w=e.gapMode,C=Dl(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),S=m,R=yp([n,t]),L=Vt(Vt({},C),o);return d.createElement(d.Fragment,null,f&&d.createElement(S,{sideCar:Tl,removeScrollBar:l,shards:u,noRelative:p,noIsolation:g,inert:b,setCallbacks:i,allowPinchZoom:!!h,lockRef:n,gapMode:w}),a?d.cloneElement(d.Children.only(s),Vt(Vt({},L),{ref:R})):d.createElement(E,Vt({},L,{className:c,ref:R}),s))});si.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};si.classNames={fullWidth:Io,zeroRight:_o};var Sp=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function Rp(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=Sp();return t&&e.setAttribute("nonce",t),e}function Mp(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function Np(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var Pp=function(){var e=0,t=null;return{add:function(n){e==0&&(t=Rp())&&(Mp(t,n),Np(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},kp=function(){var e=Pp();return function(t,n){d.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Ol=function(){var e=kp(),t=function(n){var r=n.styles,o=n.dynamic;return e(r,o),null};return t},_p={left:0,top:0,right:0,gap:0},Gi=function(e){return parseInt(e||"",10)||0},Ip=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[Gi(n),Gi(r),Gi(o)]},Dp=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return _p;var t=Ip(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},Ap=Ol(),dr="data-scroll-locked",Tp=function(e,t,n,r){var o=e.left,i=e.top,a=e.right,s=e.gap;return n===void 0&&(n="margin"),`
50
- .`.concat(pp,` {
51
- overflow: hidden `).concat(r,`;
52
- padding-right: `).concat(s,"px ").concat(r,`;
64
+ `},size:{small:`univer-h-6 univer-rounded-md univer-px-1.5 univer-text-xs`,middle:`univer-h-8 univer-rounded-lg univer-px-2 univer-text-sm`,large:`univer-h-10 univer-rounded-lg univer-px-3 univer-text-sm`}},defaultVariants:{variant:`default`,size:`middle`}}),Ze=(0,h.forwardRef)(({className:e,variant:t,size:n,asChild:r=!1,...i},a)=>(0,z.jsx)(r?We:`button`,{className:R(Xe({variant:t,size:n,className:e})),ref:a,"data-u-comp":`button`,...i}));Ze.displayName=`Button`;const Qe=({className:e,orientation:t=`horizontal`,children:n})=>{let r=h.Children.count(n),i=t===`horizontal`,a=t===`vertical`;return(0,z.jsx)(`div`,{className:R(`univer-grid`,{"univer-grid-flow-row":a,"univer-w-fit":a},e),children:h.Children.map(n,(e,t)=>{let n=t===0,o=t===r-1;return(0,h.cloneElement)(e,{className:R({"!univer-rounded-l-none":i&&!n,"!univer-rounded-r-none":i&&!o,"!univer-border-l-0":i&&!n,"!univer-rounded-t-none":a&&!n,"!univer-rounded-b-none":a&&!o,"!univer-border-t-0":a&&!n},e.props.className)})})})};function $e(){return typeof window<`u`&&typeof document<`u`}const et=(0,h.createContext)({mountContainer:$e()?document.body:null});function tt(e){let{children:t,locale:n,mountContainer:r}=e,i=(0,h.useMemo)(()=>({locale:n,mountContainer:r}),[n,r]);return(0,z.jsx)(et.Provider,{value:i,children:t})}var nt=u(s(((e,t)=>{(function(n,r){typeof e==`object`&&t!==void 0?t.exports=r():typeof define==`function`&&define.amd?define(r):(n=typeof globalThis<`u`?globalThis:n||self).dayjs=r()})(e,(function(){"use strict";var e=1e3,t=6e4,n=36e5,r=`millisecond`,i=`second`,a=`minute`,o=`hour`,s=`day`,c=`week`,l=`month`,u=`quarter`,d=`year`,f=`date`,p=`Invalid Date`,m=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,h=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,g={name:`en`,weekdays:`Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday`.split(`_`),months:`January_February_March_April_May_June_July_August_September_October_November_December`.split(`_`),ordinal:function(e){var t=[`th`,`st`,`nd`,`rd`],n=e%100;return`[`+e+(t[(n-20)%10]||t[n]||t[0])+`]`}},_=function(e,t,n){var r=String(e);return!r||r.length>=t?e:``+Array(t+1-r.length).join(n)+e},v={s:_,z:function(e){var t=-e.utcOffset(),n=Math.abs(t),r=Math.floor(n/60),i=n%60;return(t<=0?`+`:`-`)+_(r,2,`0`)+`:`+_(i,2,`0`)},m:function e(t,n){if(t.date()<n.date())return-e(n,t);var r=12*(n.year()-t.year())+(n.month()-t.month()),i=t.clone().add(r,l),a=n-i<0,o=t.clone().add(r+(a?-1:1),l);return+(-(r+(n-i)/(a?i-o:o-i))||0)},a:function(e){return e<0?Math.ceil(e)||0:Math.floor(e)},p:function(e){return{M:l,y:d,w:c,d:s,D:f,h:o,m:a,s:i,ms:r,Q:u}[e]||String(e||``).toLowerCase().replace(/s$/,``)},u:function(e){return e===void 0}},y=`en`,b={};b[y]=g;var x=`$isDayjsObject`,S=function(e){return e instanceof E||!(!e||!e[x])},C=function e(t,n,r){var i;if(!t)return y;if(typeof t==`string`){var a=t.toLowerCase();b[a]&&(i=a),n&&(b[a]=n,i=a);var o=t.split(`-`);if(!i&&o.length>1)return e(o[0])}else{var s=t.name;b[s]=t,i=s}return!r&&i&&(y=i),i||!r&&y},w=function(e,t){if(S(e))return e.clone();var n=typeof t==`object`?t:{};return n.date=e,n.args=arguments,new E(n)},T=v;T.l=C,T.i=S,T.w=function(e,t){return w(e,{locale:t.$L,utc:t.$u,x:t.$x,$offset:t.$offset})};var E=function(){function g(e){this.$L=C(e.locale,null,!0),this.parse(e),this.$x=this.$x||e.x||{},this[x]=!0}var _=g.prototype;return _.parse=function(e){this.$d=function(e){var t=e.date,n=e.utc;if(t===null)return new Date(NaN);if(T.u(t))return new Date;if(t instanceof Date)return new Date(t);if(typeof t==`string`&&!/Z$/i.test(t)){var r=t.match(m);if(r){var i=r[2]-1||0,a=(r[7]||`0`).substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,a)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,a)}}return new Date(t)}(e),this.init()},_.init=function(){var e=this.$d;this.$y=e.getFullYear(),this.$M=e.getMonth(),this.$D=e.getDate(),this.$W=e.getDay(),this.$H=e.getHours(),this.$m=e.getMinutes(),this.$s=e.getSeconds(),this.$ms=e.getMilliseconds()},_.$utils=function(){return T},_.isValid=function(){return this.$d.toString()!==p},_.isSame=function(e,t){var n=w(e);return this.startOf(t)<=n&&n<=this.endOf(t)},_.isAfter=function(e,t){return w(e)<this.startOf(t)},_.isBefore=function(e,t){return this.endOf(t)<w(e)},_.$g=function(e,t,n){return T.u(e)?this[t]:this.set(n,e)},_.unix=function(){return Math.floor(this.valueOf()/1e3)},_.valueOf=function(){return this.$d.getTime()},_.startOf=function(e,t){var n=this,r=!!T.u(t)||t,u=T.p(e),p=function(e,t){var i=T.w(n.$u?Date.UTC(n.$y,t,e):new Date(n.$y,t,e),n);return r?i:i.endOf(s)},m=function(e,t){return T.w(n.toDate()[e].apply(n.toDate(`s`),(r?[0,0,0,0]:[23,59,59,999]).slice(t)),n)},h=this.$W,g=this.$M,_=this.$D,v=`set`+(this.$u?`UTC`:``);switch(u){case d:return r?p(1,0):p(31,11);case l:return r?p(1,g):p(0,g+1);case c:var y=this.$locale().weekStart||0,b=(h<y?h+7:h)-y;return p(r?_-b:_+(6-b),g);case s:case f:return m(v+`Hours`,0);case o:return m(v+`Minutes`,1);case a:return m(v+`Seconds`,2);case i:return m(v+`Milliseconds`,3);default:return this.clone()}},_.endOf=function(e){return this.startOf(e,!1)},_.$set=function(e,t){var n,c=T.p(e),u=`set`+(this.$u?`UTC`:``),p=(n={},n[s]=u+`Date`,n[f]=u+`Date`,n[l]=u+`Month`,n[d]=u+`FullYear`,n[o]=u+`Hours`,n[a]=u+`Minutes`,n[i]=u+`Seconds`,n[r]=u+`Milliseconds`,n)[c],m=c===s?this.$D+(t-this.$W):t;if(c===l||c===d){var h=this.clone().set(f,1);h.$d[p](m),h.init(),this.$d=h.set(f,Math.min(this.$D,h.daysInMonth())).$d}else p&&this.$d[p](m);return this.init(),this},_.set=function(e,t){return this.clone().$set(e,t)},_.get=function(e){return this[T.p(e)]()},_.add=function(r,u){var f,p=this;r=Number(r);var m=T.p(u),h=function(e){var t=w(p);return T.w(t.date(t.date()+Math.round(e*r)),p)};if(m===l)return this.set(l,this.$M+r);if(m===d)return this.set(d,this.$y+r);if(m===s)return h(1);if(m===c)return h(7);var g=(f={},f[a]=t,f[o]=n,f[i]=e,f)[m]||1,_=this.$d.getTime()+r*g;return T.w(_,this)},_.subtract=function(e,t){return this.add(-1*e,t)},_.format=function(e){var t=this,n=this.$locale();if(!this.isValid())return n.invalidDate||p;var r=e||`YYYY-MM-DDTHH:mm:ssZ`,i=T.z(this),a=this.$H,o=this.$m,s=this.$M,c=n.weekdays,l=n.months,u=n.meridiem,d=function(e,n,i,a){return e&&(e[n]||e(t,r))||i[n].slice(0,a)},f=function(e){return T.s(a%12||12,e,`0`)},m=u||function(e,t,n){var r=e<12?`AM`:`PM`;return n?r.toLowerCase():r};return r.replace(h,(function(e,r){return r||function(e){switch(e){case`YY`:return String(t.$y).slice(-2);case`YYYY`:return T.s(t.$y,4,`0`);case`M`:return s+1;case`MM`:return T.s(s+1,2,`0`);case`MMM`:return d(n.monthsShort,s,l,3);case`MMMM`:return d(l,s);case`D`:return t.$D;case`DD`:return T.s(t.$D,2,`0`);case`d`:return String(t.$W);case`dd`:return d(n.weekdaysMin,t.$W,c,2);case`ddd`:return d(n.weekdaysShort,t.$W,c,3);case`dddd`:return c[t.$W];case`H`:return String(a);case`HH`:return T.s(a,2,`0`);case`h`:return f(1);case`hh`:return f(2);case`a`:return m(a,o,!0);case`A`:return m(a,o,!1);case`m`:return String(o);case`mm`:return T.s(o,2,`0`);case`s`:return String(t.$s);case`ss`:return T.s(t.$s,2,`0`);case`SSS`:return T.s(t.$ms,3,`0`);case`Z`:return i}return null}(e)||i.replace(`:`,``)}))},_.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},_.diff=function(r,f,p){var m,h=this,g=T.p(f),_=w(r),v=(_.utcOffset()-this.utcOffset())*t,y=this-_,b=function(){return T.m(h,_)};switch(g){case d:m=b()/12;break;case l:m=b();break;case u:m=b()/3;break;case c:m=(y-v)/6048e5;break;case s:m=(y-v)/864e5;break;case o:m=y/n;break;case a:m=y/t;break;case i:m=y/e;break;default:m=y}return p?m:T.a(m)},_.daysInMonth=function(){return this.endOf(l).$D},_.$locale=function(){return b[this.$L]},_.locale=function(e,t){if(!e)return this.$L;var n=this.clone(),r=C(e,t,!0);return r&&(n.$L=r),n},_.clone=function(){return T.w(this.$d,this)},_.toDate=function(){return new Date(this.valueOf())},_.toJSON=function(){return this.isValid()?this.toISOString():null},_.toISOString=function(){return this.$d.toISOString()},_.toString=function(){return this.$d.toUTCString()},g}(),D=E.prototype;return w.prototype=D,[[`$ms`,r],[`$s`,i],[`$m`,a],[`$H`,o],[`$W`,s],[`$M`,l],[`$y`,d],[`$D`,f]].forEach((function(e){D[e[1]]=function(t){return this.$g(t,e[0],e[1])}})),w.extend=function(e,t){return e.$i||(e(t,E,w),e.$i=!0),w},w.locale=C,w.isDayjs=S,w.unix=function(e){return w(1e3*e)},w.en=b[y],w.Ls=b,w.p={},w}))}))());const rt=`univer-scrollbar-thin univer-scrollbar-track-gray-50 univer-scrollbar-thumb-gray-300 dark:!univer-scrollbar-track-gray-900 dark:!univer-scrollbar-thumb-gray-700`,it=`univer-border-gray-200 dark:!univer-border-gray-600 univer-border-solid`,at=R(it,`univer-border`),ot=R(it,`univer-border-l univer-border-b univer-border-t-0 univer-border-r-0`),st=R(it,`univer-border-l univer-border-b-0 univer-border-t-0 univer-border-r-0`),ct=R(it,`univer-border-l-0 univer-border-b-0 univer-border-t univer-border-r-0`),lt=R(it,`univer-border-l-0 univer-border-b univer-border-t-0 univer-border-r-0`),ut=R(it,`univer-border-l-0 univer-border-b-0 univer-border-t-0 univer-border-r`);function dt(e){let{className:t,value:n,onValueChange:r}=e;function i(e){let[t,i,a]=e.target.value.split(`:`).map(Number),o=new Date(n==null?Date.now():n);o.setHours(t,i,a,0),r==null||r(o)}return(0,z.jsxs)(`div`,{"data-u-comp":`time-input`,className:`univer-relative univer-mx-auto univer-mt-1 univer-w-fit`,children:[(0,z.jsx)(f.ClockIcon,{className:`univer-absolute univer-left-2 univer-top-1/2 -univer-translate-y-1/2 univer-text-gray-600 dark:!univer-text-gray-400`}),(0,z.jsx)(`input`,{className:R(`univer-block univer-h-7 univer-w-fit univer-appearance-none univer-rounded-md univer-bg-transparent univer-pl-6 univer-pr-2 univer-text-center univer-text-gray-800 univer-shadow univer-outline-none univer-transition-all univer-duration-200 focus:univer-border-primary-600 dark:!univer-text-white dark:focus:!univer-border-primary-500 [&::-webkit-calendar-picker-indicator]:univer-hidden [&::-webkit-calendar-picker-indicator]:univer-appearance-none`,at,t),type:`time`,step:`1`,value:(0,nt.default)(n).format(`HH:mm:ss`),onChange:i})]})}function ft(e,t){return new Date(e,t+1,0).getDate()}function pt(e,t){return new Date(e,t,1).getDay()}function mt(e){let{className:t,...n}=e;return(0,z.jsx)(`button`,{className:R(`univer-size-7 univer-rounded-md univer-border-none univer-bg-transparent univer-p-1 univer-transition-all hover:univer-bg-gray-200 dark:hover:!univer-bg-gray-600`,t),type:`button`,...n})}function ht(e){let{className:t,max:n,min:r,showTime:i=!1,value:a,onValueChange:o}=e,{locale:s}=(0,h.useContext)(et),{year:c,weekDays:l,months:u}=s==null?void 0:s.Calendar,d=new Date,[p,m]=(0,h.useState)((a==null?d:a).getFullYear()),[g,_]=(0,h.useState)((a==null?d:a).getMonth());function v(){_(e=>e===0?(m(e=>e-1),11):e-1)}function y(){_(e=>e===11?(m(e=>e+1),0):e+1)}let b=ft(p,g),x=pt(p,g),S=(0,h.useMemo)(()=>{let e=[];for(let t=0;t<x;t++)e.push(null);for(let t=1;t<=b;t++)e.push(t);return e},[b,x]);function C(e){return e&&p===(a==null?void 0:a.getFullYear())&&g===(a==null?void 0:a.getMonth())&&e===(a==null?void 0:a.getDate())}function w(e){return e&&p===d.getFullYear()&&g===d.getMonth()&&e===d.getDate()}function T(e){var t,i,o;if(!e)return!1;let s=(t=a==null?void 0:a.getHours())==null?d.getHours():t,c=(i=a==null?void 0:a.getMinutes())==null?d.getMinutes():i,l=(o=a==null?void 0:a.getSeconds())==null?d.getSeconds():o,u=new Date(p,g,e,s,c,l);return!!(r&&u<r||n&&u>n)}function E(e){var t,n,r;if(T(e))return;let i=(t=a==null?void 0:a.getHours())==null?d.getHours():t,s=(n=a==null?void 0:a.getMinutes())==null?d.getMinutes():n,c=(r=a==null?void 0:a.getSeconds())==null?d.getSeconds():r;o==null||o(new Date(p,g,e,i,s,c))}function D(e){var t;let n=e.getHours(),r=e.getMinutes(),i=e.getSeconds(),s=new Date(p,g,(t=a==null?void 0:a.getDate())==null?d.getDate():t,n,r,i);o==null||o(s)}return(0,z.jsxs)(`div`,{"data-u-comp":`calendar`,className:R(`univer-mx-auto univer-max-w-xs univer-select-none univer-rounded univer-bg-white univer-text-gray-900 dark:!univer-bg-gray-900 dark:!univer-text-white`,t),children:[(0,z.jsxs)(`nav`,{className:`univer-mb-4 univer-flex univer-items-center univer-justify-between`,children:[(0,z.jsx)(mt,{className:`univer-text-lg univer-text-gray-500 dark:!univer-text-gray-200`,"aria-label":`Previous Month`,onClick:v,children:(0,z.jsx)(f.MoreRightIcon,{className:`univer-rotate-180`})}),(0,z.jsxs)(`span`,{className:`univer-flex univer-gap-0.5 univer-text-sm univer-font-medium`,children:[(0,z.jsx)(`span`,{children:p}),(0,z.jsx)(`span`,{children:c}),(0,z.jsx)(`span`,{children:u[g]})]}),(0,z.jsx)(mt,{className:`univer-text-lg univer-text-gray-500 dark:!univer-text-gray-200`,"aria-label":`Next Month`,onClick:y,children:(0,z.jsx)(f.MoreRightIcon,{})})]}),(0,z.jsx)(`div`,{className:`univer-mb-1 univer-grid univer-grid-cols-7 univer-gap-1 univer-text-center univer-text-sm univer-text-gray-500 dark:!univer-text-gray-200`,children:l.map(e=>(0,z.jsx)(`div`,{children:e},e))}),(0,z.jsx)(`div`,{className:`univer-grid univer-grid-cols-7 univer-gap-1 univer-text-center`,children:S.map((e,t)=>e?(0,z.jsx)(mt,{className:R({"!univer-bg-primary-600 univer-font-bold univer-text-white":!w(e)&&C(e),"dark:!univer-text-white":!w(e)&&!C(e),"!univer-bg-primary-600 univer-text-white":w(e)&&C(e),"univer-font-semibold univer-text-primary-600 dark:!univer-text-primary-500":w(e)&&!C(e),"univer-cursor-not-allowed univer-opacity-40":T(e),"univer-hover:bg-primary-100 univer-cursor-pointer univer-text-gray-800":!C(e)&&!T(e)}),onClick:()=>E(e),disabled:T(e),children:e},t):(0,z.jsx)(`div`,{},t))}),i&&(0,z.jsx)(dt,{value:a,onValueChange:D})]})}function gt({emptyText:e}){return(0,z.jsx)(`section`,{className:`univer-h-8 univer-px-2 univer-pr-32 univer-text-sm/8 univer-text-gray-600 dark:!univer-text-gray-200`,children:e})}function _t(e){let{value:t,options:n=[],onChange:r,contentClassName:i,wrapperClassName:a}=e,{locale:o}=(0,h.useContext)(et),s=(0,h.useMemo)(()=>{let e=[n];return t.forEach((t,n)=>{let r=e[n].find(e=>e.value===t);r!=null&&r.children&&e.push(r.children)}),e},[t]);function c(e,n){if(n===t[e])return;if(t[e+1]){let i=t.slice(0,e+1);i[e]=n,r(i);return}let i=[...t];i[e]=n,r(i)}return(0,z.jsxs)(`section`,{"data-u-comp":`cascader-list`,className:R(`univer-overflow-auto-y univer-grid univer-h-full univer-max-h-80 univer-grid-flow-col univer-rounded univer-py-2 univer-text-gray-900 dark:!univer-text-white [&>ul:not(:last-child)]:univer-border-0 [&>ul:not(:last-child)]:univer-border-r [&>ul:not(:last-child)]:univer-border-solid [&>ul:not(:last-child)]:univer-border-r-gray-200`,at,rt,a),children:[s.map((e,n)=>e.length?(0,z.jsx)(`ul`,{className:R(`univer-m-0 univer-h-full univer-max-h-full univer-list-none univer-overflow-auto univer-px-2`,rt,i),children:e.map(e=>(0,z.jsx)(`li`,{children:(0,z.jsxs)(`a`,{className:R(`univer-relative univer-block univer-h-8 univer-cursor-pointer univer-rounded univer-text-sm/8`,{"univer-px-7":n>0,"univer-px-1.5":n===0,"univer-bg-gray-200 dark:!univer-bg-gray-600":e.value===t[n]}),onClick:()=>c(n,e.value),children:[n>0&&(0,z.jsx)(`span`,{className:`univer-absolute univer-left-2 univer-flex univer-h-full univer-items-center`,children:e.value===t[n]&&(0,z.jsx)(f.CheckMarkIcon,{className:`univer-text-primary-600`})}),(0,z.jsx)(`span`,{children:e.label})]})},e.value))},n):(0,z.jsx)(gt,{emptyText:o==null?void 0:o.CascaderList.empty},n)),t.length<=0&&(0,z.jsx)(gt,{emptyText:o==null?void 0:o.CascaderList.empty})]})}function vt(e){let{children:t,className:n,style:r,value:i,disabled:a,direction:o=`horizontal`,onChange:s}=e,c=e=>{i.includes(e)?s(i.filter(t=>t!==e)):s([...i,e])};return(0,z.jsx)(`div`,{className:R(`univer-flex univer-gap-2`,{"univer-flex-col":o===`vertical`},n),style:r,children:h.Children.map(t,(e,t)=>(0,h.isValidElement)(e)?(0,h.cloneElement)(e,{key:t,children:e.props.children,checked:e.props.value?i.includes(e.props.value):!1,disabled:a==null?e.props.disabled:a,onChange:c}):e)})}function yt(e){let{children:t,className:n,style:r,checked:i=!1,indeterminate:a=!1,value:o,disabled:s=!1,onChange:c,contentClassName:l}=e,u=(0,h.useRef)(null);function d(e){if(e.stopPropagation(),!(!c||s))if(o!==void 0)c==null||c(o);else{var t,n;let e=(t=u==null||(n=u.current)==null?void 0:n.checked)==null?!1:t;c==null||c(e)}}return(0,z.jsxs)(`label`,{"data-u-comp":`checkbox`,className:R(`univer-box-border univer-inline-flex univer-items-center univer-gap-2 univer-text-sm`,{"univer-cursor-pointer univer-text-gray-900 dark:!univer-text-white":!s,"univer-text-gray-400":s},n),style:r,children:[(0,z.jsxs)(`span`,{className:`univer-relative univer-block`,children:[(0,z.jsx)(`input`,{ref:u,className:`univer-absolute univer-size-0 univer-opacity-0`,type:`checkbox`,checked:i,disabled:s,onChange:d}),(0,z.jsxs)(`span`,{className:R(`univer-relative univer-box-border univer-flex univer-size-4 univer-items-center univer-justify-center univer-overflow-hidden univer-rounded univer-border univer-border-solid univer-transition-colors`,{"univer-opacity-50":s,"univer-border-primary-600 univer-bg-primary-600":i||a,"univer-border-gray-300 univer-bg-gray-50 dark:!univer-border-gray-500 dark:!univer-bg-gray-600":!i&&!a}),children:[i&&(0,z.jsx)(f.CheckMarkIcon,{className:`univer-absolute univer-left-1/2 univer-top-1/2 univer-block univer-size-3 -univer-translate-x-1/2 -univer-translate-y-1/2 univer-text-white`}),a&&!i&&(0,z.jsx)(`span`,{className:`univer-absolute univer-left-1/2 univer-top-1/2 univer-block univer-h-0.5 univer-w-2.5 -univer-translate-x-1/2 -univer-translate-y-1/2 univer-rounded univer-bg-white`})]})]}),(0,z.jsx)(`span`,{className:R(`univer-select-none`,l),children:t})]})}typeof window<`u`&&window.document&&window.document.createElement;function B(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e==null||e(r),n===!1||!r.defaultPrevented)return t==null?void 0:t(r)}}function bt(e,t){let n=h.createContext(t),r=e=>{let{children:t,...r}=e,i=h.useMemo(()=>r,Object.values(r));return(0,z.jsx)(n.Provider,{value:i,children:t})};r.displayName=e+`Provider`;function i(r){let i=h.useContext(n);if(i)return i;if(t!==void 0)return t;throw Error(`\`${r}\` must be used within \`${e}\``)}return[r,i]}function xt(e,t=[]){let n=[];function r(t,r){let i=h.createContext(r),a=n.length;n=[...n,r];let o=t=>{var n;let{scope:r,children:o,...s}=t,c=(r==null||(n=r[e])==null?void 0:n[a])||i,l=h.useMemo(()=>s,Object.values(s));return(0,z.jsx)(c.Provider,{value:l,children:o})};o.displayName=t+`Provider`;function s(n,o){var s;let c=(o==null||(s=o[e])==null?void 0:s[a])||i,l=h.useContext(c);if(l)return l;if(r!==void 0)return r;throw Error(`\`${n}\` must be used within \`${t}\``)}return[o,s]}let i=()=>{let t=n.map(e=>h.createContext(e));return function(n){let r=(n==null?void 0:n[e])||t;return h.useMemo(()=>({[`__scope${e}`]:{...n,[e]:r}}),[n,r])}};return i.scopeName=e,[r,St(i,...t)]}function St(...e){let t=e[0];if(e.length===1)return t;let n=()=>{let n=e.map(e=>({useScope:e(),scopeName:e.scopeName}));return function(e){let r=n.reduce((t,{useScope:n,scopeName:r})=>{let i=n(e)[`__scope${r}`];return{...t,...i}},{});return h.useMemo(()=>({[`__scope${t.scopeName}`]:r}),[r])}};return n.scopeName=t.scopeName,n}var Ct,wt=(Ct=globalThis)!=null&&Ct.document?h.useLayoutEffect:()=>{},Tt=h.useId||(()=>void 0),Et=0;function Dt(e){let[t,n]=h.useState(Tt());return wt(()=>{e||n(e=>e==null?String(Et++):e)},[e]),e||(t?`radix-${t}`:``)}var Ot=h.useInsertionEffect||wt;function kt({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){let[i,a,o]=At({defaultProp:t,onChange:n}),s=e!==void 0,c=s?e:i;{let t=h.useRef(e!==void 0);h.useEffect(()=>{let e=t.current;if(e!==s){let t=e?`controlled`:`uncontrolled`,n=s?`controlled`:`uncontrolled`;console.warn(`${r} is changing from ${t} to ${n}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`)}t.current=s},[s,r])}return[c,h.useCallback(t=>{if(s){let r=jt(t)?t(e):t;if(r!==e){var n;(n=o.current)==null||n.call(o,r)}}else a(t)},[s,e,a,o])]}function At({defaultProp:e,onChange:t}){let[n,r]=h.useState(e),i=h.useRef(n),a=h.useRef(t);return Ot(()=>{a.current=t},[t]),h.useEffect(()=>{if(i.current!==n){var e;(e=a.current)==null||e.call(a,n),i.current=n}},[n,i]),[n,r,a]}function jt(e){return typeof e==`function`}
65
+ /**
66
+ * @license React
67
+ * react-dom.production.js
68
+ *
69
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
70
+ *
71
+ * This source code is licensed under the MIT license found in the
72
+ * LICENSE file in the root directory of this source tree.
73
+ */
74
+ var Mt=s((e=>{var t=m();function n(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function r(){}var i={d:{f:r,r:function(){throw Error(n(522))},D:r,C:r,L:r,m:r,X:r,S:r,M:r},p:0,findDOMNode:null},a=Symbol.for(`react.portal`);function o(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:a,key:r==null?null:``+r,children:e,containerInfo:t,implementation:n}}var s=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function c(e,t){if(e===`font`)return``;if(typeof t==`string`)return t===`use-credentials`?t:``}e.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=i,e.createPortal=function(e,t){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)throw Error(n(299));return o(e,t,null,r)},e.flushSync=function(e){var t=s.T,n=i.p;try{if(s.T=null,i.p=2,e)return e()}finally{s.T=t,i.p=n,i.d.f()}},e.preconnect=function(e,t){typeof e==`string`&&(t?(t=t.crossOrigin,t=typeof t==`string`?t===`use-credentials`?t:``:void 0):t=null,i.d.C(e,t))},e.prefetchDNS=function(e){typeof e==`string`&&i.d.D(e)},e.preinit=function(e,t){if(typeof e==`string`&&t&&typeof t.as==`string`){var n=t.as,r=c(n,t.crossOrigin),a=typeof t.integrity==`string`?t.integrity:void 0,o=typeof t.fetchPriority==`string`?t.fetchPriority:void 0;n===`style`?i.d.S(e,typeof t.precedence==`string`?t.precedence:void 0,{crossOrigin:r,integrity:a,fetchPriority:o}):n===`script`&&i.d.X(e,{crossOrigin:r,integrity:a,fetchPriority:o,nonce:typeof t.nonce==`string`?t.nonce:void 0})}},e.preinitModule=function(e,t){if(typeof e==`string`)if(typeof t==`object`&&t){if(t.as==null||t.as===`script`){var n=c(t.as,t.crossOrigin);i.d.M(e,{crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0})}}else t==null&&i.d.M(e)},e.preload=function(e,t){if(typeof e==`string`&&typeof t==`object`&&t&&typeof t.as==`string`){var n=t.as,r=c(n,t.crossOrigin);i.d.L(e,n,{crossOrigin:r,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0,type:typeof t.type==`string`?t.type:void 0,fetchPriority:typeof t.fetchPriority==`string`?t.fetchPriority:void 0,referrerPolicy:typeof t.referrerPolicy==`string`?t.referrerPolicy:void 0,imageSrcSet:typeof t.imageSrcSet==`string`?t.imageSrcSet:void 0,imageSizes:typeof t.imageSizes==`string`?t.imageSizes:void 0,media:typeof t.media==`string`?t.media:void 0})}},e.preloadModule=function(e,t){if(typeof e==`string`)if(t){var n=c(t.as,t.crossOrigin);i.d.m(e,{as:typeof t.as==`string`&&t.as!==`script`?t.as:void 0,crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0})}else i.d.m(e)},e.requestFormReset=function(e){i.d.r(e)},e.unstable_batchedUpdates=function(e,t){return e(t)},e.useFormState=function(e,t,n){return s.H.useFormState(e,t,n)},e.useFormStatus=function(){return s.H.useHostTransitionStatus()},e.version=`19.2.4`})),Nt=s(((e,t)=>{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=Mt()})),Pt=u(Nt(),1);function Ft(e){let t=It(e),n=h.forwardRef((e,n)=>{let{children:r,...i}=e,a=h.Children.toArray(r),o=a.find(Rt);if(o){let e=o.props.children,r=a.map(t=>t===o?h.Children.count(e)>1?h.Children.only(null):h.isValidElement(e)?e.props.children:null:t);return(0,z.jsx)(t,{...i,ref:n,children:h.isValidElement(e)?h.cloneElement(e,void 0,r):null})}return(0,z.jsx)(t,{...i,ref:n,children:r})});return n.displayName=`${e}.Slot`,n}function It(e){let t=h.forwardRef((e,t)=>{let{children:n,...r}=e;if(h.isValidElement(n)){let e=Bt(n),i=zt(r,n.props);return n.type!==h.Fragment&&(i.ref=t?Le(t,e):e),h.cloneElement(n,i)}return h.Children.count(n)>1?h.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Lt=Symbol(`radix.slottable`);function Rt(e){return h.isValidElement(e)&&typeof e.type==`function`&&`__radixId`in e.type&&e.type.__radixId===Lt}function zt(e,t){let n={...t};for(let r in t){let i=e[r],a=t[r];/^on[A-Z]/.test(r)?i&&a?n[r]=(...e)=>{let t=a(...e);return i(...e),t}:i&&(n[r]=i):r===`style`?n[r]={...i,...a}:r===`className`&&(n[r]=[i,a].filter(Boolean).join(` `))}return{...e,...n}}function Bt(e){var t,n;let r=(t=Object.getOwnPropertyDescriptor(e.props,`ref`))==null?void 0:t.get,i=r&&`isReactWarning`in r&&r.isReactWarning;return i?e.ref:(r=(n=Object.getOwnPropertyDescriptor(e,`ref`))==null?void 0:n.get,i=r&&`isReactWarning`in r&&r.isReactWarning,i?e.props.ref:e.props.ref||e.ref)}var Vt=[`a`,`button`,`div`,`form`,`h2`,`h3`,`img`,`input`,`label`,`li`,`nav`,`ol`,`p`,`select`,`span`,`svg`,`ul`].reduce((e,t)=>{let n=Ft(`Primitive.${t}`),r=h.forwardRef((e,r)=>{let{asChild:i,...a}=e,o=i?n:t;return typeof window<`u`&&(window[Symbol.for(`radix-ui`)]=!0),(0,z.jsx)(o,{...a,ref:r})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Ht(e,t){e&&Pt.flushSync(()=>e.dispatchEvent(t))}function Ut(e){let t=h.useRef(e);return h.useEffect(()=>{t.current=e}),h.useMemo(()=>(...e)=>{var n;return(n=t.current)==null?void 0:n.call(t,...e)},[])}function Wt(e,t=(()=>{var e;return(e=globalThis)==null?void 0:e.document})()){let n=Ut(e);h.useEffect(()=>{let e=e=>{e.key===`Escape`&&n(e)};return t.addEventListener(`keydown`,e,{capture:!0}),()=>t.removeEventListener(`keydown`,e,{capture:!0})},[n,t])}var Gt=`DismissableLayer`,Kt=`dismissableLayer.update`,qt=`dismissableLayer.pointerDownOutside`,Jt=`dismissableLayer.focusOutside`,Yt,Xt=h.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Zt=h.forwardRef((e,t)=>{var n,r;let{disableOutsidePointerEvents:i=!1,onEscapeKeyDown:a,onPointerDownOutside:o,onFocusOutside:s,onInteractOutside:c,onDismiss:l,...u}=e,d=h.useContext(Xt),[f,p]=h.useState(null),m=(n=f==null?void 0:f.ownerDocument)==null?(r=globalThis)==null?void 0:r.document:n,[,g]=h.useState({}),_=Re(t,e=>p(e)),v=Array.from(d.layers),[y]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),b=v.indexOf(y),x=f?v.indexOf(f):-1,S=d.layersWithOutsidePointerEventsDisabled.size>0,C=x>=b,w=en(e=>{let t=e.target,n=[...d.branches].some(e=>e.contains(t));!C||n||(o==null||o(e),c==null||c(e),e.defaultPrevented||l==null||l())},m),T=tn(e=>{let t=e.target;[...d.branches].some(e=>e.contains(t))||(s==null||s(e),c==null||c(e),e.defaultPrevented||l==null||l())},m);return Wt(e=>{x===d.layers.size-1&&(a==null||a(e),!e.defaultPrevented&&l&&(e.preventDefault(),l()))},m),h.useEffect(()=>{if(f)return i&&(d.layersWithOutsidePointerEventsDisabled.size===0&&(Yt=m.body.style.pointerEvents,m.body.style.pointerEvents=`none`),d.layersWithOutsidePointerEventsDisabled.add(f)),d.layers.add(f),nn(),()=>{i&&d.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=Yt)}},[f,m,i,d]),h.useEffect(()=>()=>{f&&(d.layers.delete(f),d.layersWithOutsidePointerEventsDisabled.delete(f),nn())},[f,d]),h.useEffect(()=>{let e=()=>g({});return document.addEventListener(Kt,e),()=>document.removeEventListener(Kt,e)},[]),(0,z.jsx)(Vt.div,{...u,ref:_,style:{pointerEvents:S?C?`auto`:`none`:void 0,...e.style},onFocusCapture:B(e.onFocusCapture,T.onFocusCapture),onBlurCapture:B(e.onBlurCapture,T.onBlurCapture),onPointerDownCapture:B(e.onPointerDownCapture,w.onPointerDownCapture)})});Zt.displayName=Gt;var Qt=`DismissableLayerBranch`,$t=h.forwardRef((e,t)=>{let n=h.useContext(Xt),r=h.useRef(null),i=Re(t,r);return h.useEffect(()=>{let e=r.current;if(e)return n.branches.add(e),()=>{n.branches.delete(e)}},[n.branches]),(0,z.jsx)(Vt.div,{...e,ref:i})});$t.displayName=Qt;function en(e,t=(()=>{var e;return(e=globalThis)==null?void 0:e.document})()){let n=Ut(e),r=h.useRef(!1),i=h.useRef(()=>{});return h.useEffect(()=>{let e=e=>{if(e.target&&!r.current){let r=function(){rn(qt,n,a,{discrete:!0})},a={originalEvent:e};e.pointerType===`touch`?(t.removeEventListener(`click`,i.current),i.current=r,t.addEventListener(`click`,i.current,{once:!0})):r()}else t.removeEventListener(`click`,i.current);r.current=!1},a=window.setTimeout(()=>{t.addEventListener(`pointerdown`,e)},0);return()=>{window.clearTimeout(a),t.removeEventListener(`pointerdown`,e),t.removeEventListener(`click`,i.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function tn(e,t=(()=>{var e;return(e=globalThis)==null?void 0:e.document})()){let n=Ut(e),r=h.useRef(!1);return h.useEffect(()=>{let e=e=>{e.target&&!r.current&&rn(Jt,n,{originalEvent:e},{discrete:!1})};return t.addEventListener(`focusin`,e),()=>t.removeEventListener(`focusin`,e)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function nn(){let e=new CustomEvent(Kt);document.dispatchEvent(e)}function rn(e,t,n,{discrete:r}){let i=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),r?Ht(i,a):i.dispatchEvent(a)}var an=`focusScope.autoFocusOnMount`,on=`focusScope.autoFocusOnUnmount`,sn={bubbles:!1,cancelable:!0},cn=`FocusScope`,ln=h.forwardRef((e,t)=>{let{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:a,...o}=e,[s,c]=h.useState(null),l=Ut(i),u=Ut(a),d=h.useRef(null),f=Re(t,e=>c(e)),p=h.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;h.useEffect(()=>{if(r){let e=function(e){if(p.paused||!s)return;let t=e.target;s.contains(t)?d.current=t:gn(d.current,{select:!0})},t=function(e){if(p.paused||!s)return;let t=e.relatedTarget;t!==null&&(s.contains(t)||gn(d.current,{select:!0}))},n=function(e){if(document.activeElement===document.body)for(let t of e)t.removedNodes.length>0&&gn(s)};document.addEventListener(`focusin`,e),document.addEventListener(`focusout`,t);let r=new MutationObserver(n);return s&&r.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener(`focusin`,e),document.removeEventListener(`focusout`,t),r.disconnect()}}},[r,s,p.paused]),h.useEffect(()=>{if(s){_n.add(p);let e=document.activeElement;if(!s.contains(e)){let t=new CustomEvent(an,sn);s.addEventListener(an,l),s.dispatchEvent(t),t.defaultPrevented||(un(bn(fn(s)),{select:!0}),document.activeElement===e&&gn(s))}return()=>{s.removeEventListener(an,l),setTimeout(()=>{let t=new CustomEvent(on,sn);s.addEventListener(on,u),s.dispatchEvent(t),t.defaultPrevented||gn(e==null?document.body:e,{select:!0}),s.removeEventListener(on,u),_n.remove(p)},0)}}},[s,l,u,p]);let m=h.useCallback(e=>{if(!n&&!r||p.paused)return;let t=e.key===`Tab`&&!e.altKey&&!e.ctrlKey&&!e.metaKey,i=document.activeElement;if(t&&i){let t=e.currentTarget,[r,a]=dn(t);r&&a?!e.shiftKey&&i===a?(e.preventDefault(),n&&gn(r,{select:!0})):e.shiftKey&&i===r&&(e.preventDefault(),n&&gn(a,{select:!0})):i===t&&e.preventDefault()}},[n,r,p.paused]);return(0,z.jsx)(Vt.div,{tabIndex:-1,...o,ref:f,onKeyDown:m})});ln.displayName=cn;function un(e,{select:t=!1}={}){let n=document.activeElement;for(let r of e)if(gn(r,{select:t}),document.activeElement!==n)return}function dn(e){let t=fn(e);return[pn(t,e),pn(t.reverse(),e)]}function fn(e){let t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>{let t=e.tagName===`INPUT`&&e.type===`hidden`;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function pn(e,t){for(let n of e)if(!mn(n,{upTo:t}))return n}function mn(e,{upTo:t}){if(getComputedStyle(e).visibility===`hidden`)return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display===`none`)return!0;e=e.parentElement}return!1}function hn(e){return e instanceof HTMLInputElement&&`select`in e}function gn(e,{select:t=!1}={}){if(e&&e.focus){let n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&hn(e)&&t&&e.select()}}var _n=vn();function vn(){let e=[];return{add(t){let n=e[0];t!==n&&(n==null||n.pause()),e=yn(e,t),e.unshift(t)},remove(t){var n;e=yn(e,t),(n=e[0])==null||n.resume()}}}function yn(e,t){let n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function bn(e){return e.filter(e=>e.tagName!==`A`)}var xn=`Portal`,Sn=h.forwardRef((e,t)=>{var n;let{container:r,...i}=e,[a,o]=h.useState(!1);wt(()=>o(!0),[]);let s=r||a&&((n=globalThis)==null||(n=n.document)==null?void 0:n.body);return s?Pt.createPortal((0,z.jsx)(Vt.div,{...i,ref:t}),s):null});Sn.displayName=xn;function Cn(e,t){return h.useReducer((e,n)=>{let r=t[e][n];return r==null?e:r},e)}var wn=e=>{let{present:t,children:n}=e,r=Tn(t),i=typeof n==`function`?n({present:r.isPresent}):h.Children.only(n),a=Re(r.ref,Dn(i));return typeof n==`function`||r.isPresent?h.cloneElement(i,{ref:a}):null};wn.displayName=`Presence`;function Tn(e){let[t,n]=h.useState(),r=h.useRef(null),i=h.useRef(e),a=h.useRef(`none`),[o,s]=Cn(e?`mounted`:`unmounted`,{mounted:{UNMOUNT:`unmounted`,ANIMATION_OUT:`unmountSuspended`},unmountSuspended:{MOUNT:`mounted`,ANIMATION_END:`unmounted`},unmounted:{MOUNT:`mounted`}});return h.useEffect(()=>{let e=En(r.current);a.current=o===`mounted`?e:`none`},[o]),wt(()=>{let t=r.current,n=i.current;if(n!==e){let r=a.current,o=En(t);e?s(`MOUNT`):o===`none`||(t==null?void 0:t.display)===`none`?s(`UNMOUNT`):s(n&&r!==o?`ANIMATION_OUT`:`UNMOUNT`),i.current=e}},[e,s]),wt(()=>{if(t){var e;let n,o=(e=t.ownerDocument.defaultView)==null?window:e,c=e=>{let a=En(r.current).includes(CSS.escape(e.animationName));if(e.target===t&&a&&(s(`ANIMATION_END`),!i.current)){let e=t.style.animationFillMode;t.style.animationFillMode=`forwards`,n=o.setTimeout(()=>{t.style.animationFillMode===`forwards`&&(t.style.animationFillMode=e)})}},l=e=>{e.target===t&&(a.current=En(r.current))};return t.addEventListener(`animationstart`,l),t.addEventListener(`animationcancel`,c),t.addEventListener(`animationend`,c),()=>{o.clearTimeout(n),t.removeEventListener(`animationstart`,l),t.removeEventListener(`animationcancel`,c),t.removeEventListener(`animationend`,c)}}else s(`ANIMATION_END`)},[t,s]),{isPresent:[`mounted`,`unmountSuspended`].includes(o),ref:h.useCallback(e=>{r.current=e?getComputedStyle(e):null,n(e)},[])}}function En(e){return(e==null?void 0:e.animationName)||`none`}function Dn(e){var t,n;let r=(t=Object.getOwnPropertyDescriptor(e.props,`ref`))==null?void 0:t.get,i=r&&`isReactWarning`in r&&r.isReactWarning;return i?e.ref:(r=(n=Object.getOwnPropertyDescriptor(e,`ref`))==null?void 0:n.get,i=r&&`isReactWarning`in r&&r.isReactWarning,i?e.props.ref:e.props.ref||e.ref)}var On=0;function kn(){h.useEffect(()=>{var e,t;let n=document.querySelectorAll(`[data-radix-focus-guard]`);return document.body.insertAdjacentElement(`afterbegin`,(e=n[0])==null?An():e),document.body.insertAdjacentElement(`beforeend`,(t=n[1])==null?An():t),On++,()=>{On===1&&document.querySelectorAll(`[data-radix-focus-guard]`).forEach(e=>e.remove()),On--}},[])}function An(){let e=document.createElement(`span`);return e.setAttribute(`data-radix-focus-guard`,``),e.tabIndex=0,e.style.outline=`none`,e.style.opacity=`0`,e.style.position=`fixed`,e.style.pointerEvents=`none`,e}var jn=c({__addDisposableResource:()=>ar,__assign:()=>lr,__asyncDelegator:()=>Zn,__asyncGenerator:()=>Xn,__asyncValues:()=>Qn,__await:()=>Yn,__awaiter:()=>Vn,__classPrivateFieldGet:()=>nr,__classPrivateFieldIn:()=>ir,__classPrivateFieldSet:()=>rr,__createBinding:()=>ur,__decorate:()=>Pn,__disposeResources:()=>or,__esDecorate:()=>In,__exportStar:()=>Un,__extends:()=>Mn,__generator:()=>Hn,__importDefault:()=>tr,__importStar:()=>er,__makeTemplateObject:()=>$n,__metadata:()=>Bn,__param:()=>Fn,__propKey:()=>Rn,__read:()=>Gn,__rest:()=>Nn,__rewriteRelativeImportExtension:()=>sr,__runInitializers:()=>Ln,__setFunctionName:()=>zn,__spread:()=>Kn,__spreadArray:()=>Jn,__spreadArrays:()=>qn,__values:()=>Wn,default:()=>mr});function Mn(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Class extends value `+String(t)+` is not a constructor or null`);cr(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}function Nn(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function Pn(e,t,n,r){var i=arguments.length,a=i<3?t:r===null?r=Object.getOwnPropertyDescriptor(t,n):r,o;if(typeof Reflect==`object`&&typeof Reflect.decorate==`function`)a=Reflect.decorate(e,t,n,r);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(i<3?o(a):i>3?o(t,n,a):o(t,n))||a);return i>3&&a&&Object.defineProperty(t,n,a),a}function Fn(e,t){return function(n,r){t(n,r,e)}}function In(e,t,n,r,i,a){function o(e){if(e!==void 0&&typeof e!=`function`)throw TypeError(`Function expected`);return e}for(var s=r.kind,c=s===`getter`?`get`:s===`setter`?`set`:`value`,l=!t&&e?r.static?e:e.prototype:null,u=t||(l?Object.getOwnPropertyDescriptor(l,r.name):{}),d,f=!1,p=n.length-1;p>=0;p--){var m={};for(var h in r)m[h]=h===`access`?{}:r[h];for(var h in r.access)m.access[h]=r.access[h];m.addInitializer=function(e){if(f)throw TypeError(`Cannot add initializers after decoration has completed`);a.push(o(e||null))};var g=(0,n[p])(s===`accessor`?{get:u.get,set:u.set}:u[c],m);if(s===`accessor`){if(g===void 0)continue;if(typeof g!=`object`||!g)throw TypeError(`Object expected`);(d=o(g.get))&&(u.get=d),(d=o(g.set))&&(u.set=d),(d=o(g.init))&&i.unshift(d)}else (d=o(g))&&(s===`field`?i.unshift(d):u[c]=d)}l&&Object.defineProperty(l,r.name,u),f=!0}function Ln(e,t,n){for(var r=arguments.length>2,i=0;i<t.length;i++)n=r?t[i].call(e,n):t[i].call(e);return r?n:void 0}function Rn(e){return typeof e==`symbol`?e:`${e}`}function zn(e,t,n){return typeof t==`symbol`&&(t=t.description?`[${t.description}]`:``),Object.defineProperty(e,`name`,{configurable:!0,value:n?`${n} ${t}`:t})}function Bn(e,t){if(typeof Reflect==`object`&&typeof Reflect.metadata==`function`)return Reflect.metadata(e,t)}function Vn(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||(n=Promise))(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})}function Hn(e,t){var n={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},r,i,a,o=Object.create((typeof Iterator==`function`?Iterator:Object).prototype);return o.next=s(0),o.throw=s(1),o.return=s(2),typeof Symbol==`function`&&(o[Symbol.iterator]=function(){return this}),o;function s(e){return function(t){return c([e,t])}}function c(s){if(r)throw TypeError(`Generator is already executing.`);for(;o&&(o=0,s[0]&&(n=0)),n;)try{if(r=1,i&&(a=s[0]&2?i.return:s[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,s[1])).done)return a;switch(i=0,a&&(s=[s[0]&2,a.value]),s[0]){case 0:case 1:a=s;break;case 4:return n.label++,{value:s[1],done:!1};case 5:n.label++,i=s[1],s=[0];continue;case 7:s=n.ops.pop(),n.trys.pop();continue;default:if((a=n.trys,!(a=a.length>0&&a[a.length-1]))&&(s[0]===6||s[0]===2)){n=0;continue}if(s[0]===3&&(!a||s[1]>a[0]&&s[1]<a[3])){n.label=s[1];break}if(s[0]===6&&n.label<a[1]){n.label=a[1],a=s;break}if(a&&n.label<a[2]){n.label=a[2],n.ops.push(s);break}a[2]&&n.ops.pop(),n.trys.pop();continue}s=t.call(e,n)}catch(e){s=[6,e],i=0}finally{r=a=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}}function Un(e,t){for(var n in e)n!==`default`&&!Object.prototype.hasOwnProperty.call(t,n)&&ur(t,e,n)}function Wn(e){var t=typeof Symbol==`function`&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&typeof e.length==`number`)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw TypeError(t?`Object is not iterable.`:`Symbol.iterator is not defined.`)}function Gn(e,t){var n=typeof Symbol==`function`&&e[Symbol.iterator];if(!n)return e;var r=n.call(e),i,a=[],o;try{for(;(t===void 0||t-- >0)&&!(i=r.next()).done;)a.push(i.value)}catch(e){o={error:e}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(o)throw o.error}}return a}function Kn(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(Gn(arguments[t]));return e}function qn(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;for(var r=Array(e),i=0,t=0;t<n;t++)for(var a=arguments[t],o=0,s=a.length;o<s;o++,i++)r[i]=a[o];return r}function Jn(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,a;r<i;r++)(a||!(r in t))&&(a||(a=Array.prototype.slice.call(t,0,r)),a[r]=t[r]);return e.concat(a||Array.prototype.slice.call(t))}function Yn(e){return this instanceof Yn?(this.v=e,this):new Yn(e)}function Xn(e,t,n){if(!Symbol.asyncIterator)throw TypeError(`Symbol.asyncIterator is not defined.`);var r=n.apply(e,t||[]),i,a=[];return i=Object.create((typeof AsyncIterator==`function`?AsyncIterator:Object).prototype),s(`next`),s(`throw`),s(`return`,o),i[Symbol.asyncIterator]=function(){return this},i;function o(e){return function(t){return Promise.resolve(t).then(e,d)}}function s(e,t){r[e]&&(i[e]=function(t){return new Promise(function(n,r){a.push([e,t,n,r])>1||c(e,t)})},t&&(i[e]=t(i[e])))}function c(e,t){try{l(r[e](t))}catch(e){f(a[0][3],e)}}function l(e){e.value instanceof Yn?Promise.resolve(e.value.v).then(u,d):f(a[0][2],e)}function u(e){c(`next`,e)}function d(e){c(`throw`,e)}function f(e,t){e(t),a.shift(),a.length&&c(a[0][0],a[0][1])}}function Zn(e){var t,n;return t={},r(`next`),r(`throw`,function(e){throw e}),r(`return`),t[Symbol.iterator]=function(){return this},t;function r(r,i){t[r]=e[r]?function(t){return(n=!n)?{value:Yn(e[r](t)),done:!1}:i?i(t):t}:i}}function Qn(e){if(!Symbol.asyncIterator)throw TypeError(`Symbol.asyncIterator is not defined.`);var t=e[Symbol.asyncIterator],n;return t?t.call(e):(e=typeof Wn==`function`?Wn(e):e[Symbol.iterator](),n={},r(`next`),r(`throw`),r(`return`),n[Symbol.asyncIterator]=function(){return this},n);function r(t){n[t]=e[t]&&function(n){return new Promise(function(r,a){n=e[t](n),i(r,a,n.done,n.value)})}}function i(e,t,n,r){Promise.resolve(r).then(function(t){e({value:t,done:n})},t)}}function $n(e,t){return Object.defineProperty?Object.defineProperty(e,`raw`,{value:t}):e.raw=t,e}function er(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var n=fr(e),r=0;r<n.length;r++)n[r]!==`default`&&ur(t,e,n[r]);return dr(t,e),t}function tr(e){return e&&e.__esModule?e:{default:e}}function nr(e,t,n,r){if(n===`a`&&!r)throw TypeError(`Private accessor was defined without a getter`);if(typeof t==`function`?e!==t||!r:!t.has(e))throw TypeError(`Cannot read private member from an object whose class did not declare it`);return n===`m`?r:n===`a`?r.call(e):r?r.value:t.get(e)}function rr(e,t,n,r,i){if(r===`m`)throw TypeError(`Private method is not writable`);if(r===`a`&&!i)throw TypeError(`Private accessor was defined without a setter`);if(typeof t==`function`?e!==t||!i:!t.has(e))throw TypeError(`Cannot write private member to an object whose class did not declare it`);return r===`a`?i.call(e,n):i?i.value=n:t.set(e,n),n}function ir(e,t){if(t===null||typeof t!=`object`&&typeof t!=`function`)throw TypeError(`Cannot use 'in' operator on non-object`);return typeof e==`function`?t===e:e.has(t)}function ar(e,t,n){if(t!=null){if(typeof t!=`object`&&typeof t!=`function`)throw TypeError(`Object expected.`);var r,i;if(n){if(!Symbol.asyncDispose)throw TypeError(`Symbol.asyncDispose is not defined.`);r=t[Symbol.asyncDispose]}if(r===void 0){if(!Symbol.dispose)throw TypeError(`Symbol.dispose is not defined.`);r=t[Symbol.dispose],n&&(i=r)}if(typeof r!=`function`)throw TypeError(`Object not disposable.`);i&&(r=function(){try{i.call(this)}catch(e){return Promise.reject(e)}}),e.stack.push({value:t,dispose:r,async:n})}else n&&e.stack.push({async:!0});return t}function or(e){function t(t){e.error=e.hasError?new pr(t,e.error,`An error was suppressed during disposal.`):t,e.hasError=!0}var n,r=0;function i(){for(;n=e.stack.pop();)try{if(!n.async&&r===1)return r=0,e.stack.push(n),Promise.resolve().then(i);if(n.dispose){var a=n.dispose.call(n.value);if(n.async)return r|=2,Promise.resolve(a).then(i,function(e){return t(e),i()})}else r|=1}catch(e){t(e)}if(r===1)return e.hasError?Promise.reject(e.error):Promise.resolve();if(e.hasError)throw e.error}return i()}function sr(e,t){return typeof e==`string`&&/^\.\.?\//.test(e)?e.replace(/\.(tsx)$|((?:\.d)?)((?:\.[^./]+?)?)\.([cm]?)ts$/i,function(e,n,r,i,a){return n?t?`.jsx`:`.js`:r&&(!i||!a)?e:r+i+`.`+a.toLowerCase()+`js`}):e}var cr,lr,ur,dr,fr,pr,mr,hr=o((()=>{cr=function(e,t){return cr=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},cr(e,t)},lr=function(){return lr=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n],t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},lr.apply(this,arguments)},ur=Object.create?(function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||(`get`in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}):(function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),dr=Object.create?(function(e,t){Object.defineProperty(e,`default`,{enumerable:!0,value:t})}):function(e,t){e.default=t},fr=function(e){return fr=Object.getOwnPropertyNames||function(e){var t=[];for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[t.length]=n);return t},fr(e)},pr=typeof SuppressedError==`function`?SuppressedError:function(e,t,n){var r=Error(n);return r.name=`SuppressedError`,r.error=e,r.suppressed=t,r},mr={__extends:Mn,__assign:lr,__rest:Nn,__decorate:Pn,__param:Fn,__esDecorate:In,__runInitializers:Ln,__propKey:Rn,__setFunctionName:zn,__metadata:Bn,__awaiter:Vn,__generator:Hn,__createBinding:ur,__exportStar:Un,__values:Wn,__read:Gn,__spread:Kn,__spreadArrays:qn,__spreadArray:Jn,__await:Yn,__asyncGenerator:Xn,__asyncDelegator:Zn,__asyncValues:Qn,__makeTemplateObject:$n,__importStar:er,__importDefault:tr,__classPrivateFieldGet:nr,__classPrivateFieldSet:rr,__classPrivateFieldIn:ir,__addDisposableResource:ar,__disposeResources:or,__rewriteRelativeImportExtension:sr}})),gr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.removedBarSizeVariable=e.noScrollbarsClassName=e.fullWidthClassName=e.zeroRightClassName=void 0,e.zeroRightClassName=`right-scroll-bar-position`,e.fullWidthClassName=`width-before-scroll-bar`,e.noScrollbarsClassName=`with-scroll-bars-hidden`,e.removedBarSizeVariable=`--removed-body-scroll-bar-size`})),_r=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.assignRef=void 0;function t(e,t){return typeof e==`function`?e(t):e&&(e.current=t),e}e.assignRef=t})),vr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.useCallbackRef=void 0;var t=m();function n(e,n){var r=(0,t.useState)(function(){return{value:e,callback:n,facade:{get current(){return r.value},set current(e){var t=r.value;t!==e&&(r.value=e,r.callback(e,t))}}}})[0];return r.callback=n,r.facade}e.useCallbackRef=n})),yr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.createCallbackRef=void 0;function t(e){var t=null;return{get current(){return t},set current(n){var r=t;r!==n&&(t=n,e(n,r))}}}e.createCallbackRef=t})),br=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.mergeRefs=void 0;var t=_r(),n=yr();function r(e){return(0,n.createCallbackRef)(function(n){return e.forEach(function(e){return(0,t.assignRef)(e,n)})})}e.mergeRefs=r})),xr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.useMergeRefs=void 0;var t=(hr(),d(jn)).__importStar(m()),n=_r(),r=vr(),i=typeof window<`u`?t.useLayoutEffect:t.useEffect,a=new WeakMap;function o(e,t){var o=(0,r.useCallbackRef)(t||null,function(t){return e.forEach(function(e){return(0,n.assignRef)(e,t)})});return i(function(){var t=a.get(o);if(t){var r=new Set(t),i=new Set(e),s=o.current;r.forEach(function(e){i.has(e)||(0,n.assignRef)(e,null)}),i.forEach(function(e){r.has(e)||(0,n.assignRef)(e,s)})}a.set(o,e)},[e]),o}e.useMergeRefs=o})),Sr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.useTransformRef=void 0;var t=_r(),n=vr();function r(e,r){return(0,n.useCallbackRef)(null,function(n){return(0,t.assignRef)(e,r(n))})}e.useTransformRef=r})),Cr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.transformRef=void 0;var t=_r(),n=yr();function r(e,r){return(0,n.createCallbackRef)(function(n){return(0,t.assignRef)(e,r(n))})}e.transformRef=r})),wr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.useRefToCallback=e.refToCallback=void 0;function t(e){return function(t){typeof e==`function`?e(t):e&&(e.current=t)}}e.refToCallback=t;var n=function(){return null},r=new WeakMap,i=function(e){var i=e||n,a=r.get(i);if(a)return a;var o=t(i);return r.set(i,o),o};function a(e){return i(e)}e.useRefToCallback=a})),Tr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.useRefToCallback=e.refToCallback=e.transformRef=e.useTransformRef=e.useMergeRefs=e.mergeRefs=e.createCallbackRef=e.useCallbackRef=e.assignRef=void 0;var t=_r();Object.defineProperty(e,`assignRef`,{enumerable:!0,get:function(){return t.assignRef}});var n=vr();Object.defineProperty(e,`useCallbackRef`,{enumerable:!0,get:function(){return n.useCallbackRef}});var r=yr();Object.defineProperty(e,`createCallbackRef`,{enumerable:!0,get:function(){return r.createCallbackRef}});var i=br();Object.defineProperty(e,`mergeRefs`,{enumerable:!0,get:function(){return i.mergeRefs}});var a=xr();Object.defineProperty(e,`useMergeRefs`,{enumerable:!0,get:function(){return a.useMergeRefs}});var o=Sr();Object.defineProperty(e,`useTransformRef`,{enumerable:!0,get:function(){return o.useTransformRef}});var s=Cr();Object.defineProperty(e,`transformRef`,{enumerable:!0,get:function(){return s.transformRef}});var c=wr();Object.defineProperty(e,`refToCallback`,{enumerable:!0,get:function(){return c.refToCallback}}),Object.defineProperty(e,`useRefToCallback`,{enumerable:!0,get:function(){return c.useRefToCallback}})})),Er=s(((e,t)=>{t.exports.isNode=Object.prototype.toString.call(typeof process<`u`?process:0)===`[object process]`})),Dr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.env=void 0,e.env={isNode:Er().isNode,forceCache:!1}})),Or=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.useSidecar=void 0;var t=m(),n=Dr(),r=new WeakMap,i={};function a(e,t){var r=t&&t.options||i;return n.env.isNode&&!r.ssr?[null,null]:o(e,t)}e.useSidecar=a;function o(e,a){var o=a&&a.options||i,s=n.env.forceCache||n.env.isNode&&!!o.ssr||!o.async,c=(0,t.useState)(s?function(){return r.get(e)}:void 0),l=c[0],u=c[1],d=(0,t.useState)(null),f=d[0],p=d[1];return(0,t.useEffect)(function(){l||e().then(function(t){var n=a?a.read():t.default||t;if(!n){console.error(`Sidecar error: with importer`,e);var i;throw a?(console.error(`Sidecar error: with medium`,a),i=Error(`Sidecar medium was not found`)):i=Error(`Sidecar was not found in exports`),p(function(){return i}),i}r.set(e,n),u(function(){return n})},function(e){return p(function(){return e})})},[]),[l,f]}})),kr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.sidecar=void 0;var t=(hr(),d(jn)),n=t.__importStar(m()),r=Or();function i(e,i){var a=function(){return i};return function(o){var s=(0,r.useSidecar)(e,o.sideCar),c=s[0];return s[1]&&i?a:c?n.createElement(c,t.__assign({},o)):null}}e.sidecar=i})),Ar=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.setConfig=e.config=void 0,e.config={onError:function(e){return console.error(e)}},e.setConfig=function(t){Object.assign(e.config,t)}})),jr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.createSidecarMedium=e.createMedium=void 0;var t=(hr(),d(jn));function n(e){return e}function r(e,t){t===void 0&&(t=n);var r=[],i=!1;return{read:function(){if(i)throw Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return r.length?r[r.length-1]:e},useMedium:function(e){var n=t(e,i);return r.push(n),function(){r=r.filter(function(e){return e!==n})}},assignSyncMedium:function(e){for(i=!0;r.length;){var t=r;r=[],t.forEach(e)}r={push:function(t){return e(t)},filter:function(){return r}}},assignMedium:function(e){i=!0;var t=[];if(r.length){var n=r;r=[],n.forEach(e),t=r}var a=function(){var n=t;t=[],n.forEach(e)},o=function(){return Promise.resolve().then(a)};o(),r={push:function(e){t.push(e),o()},filter:function(e){return t=t.filter(e),r}}}}}function i(e,t){return t===void 0&&(t=n),r(e,t)}e.createMedium=i;function a(e){e===void 0&&(e={});var n=r(null);return n.options=t.__assign({async:!0,ssr:!1},e),n}e.createSidecarMedium=a})),Mr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.renderCar=void 0;var t=(hr(),d(jn)),n=t.__importStar(m()),r=m();function i(e,i){function a(i){var a=i.stateRef,o=i.props,s=(0,r.useCallback)(function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return(0,r.useLayoutEffect)(function(){a.current(e)}),null},[]);return n.createElement(e,t.__assign({},o,{children:s}))}var o=n.memo(function(e){var t=e.stateRef,n=e.defaultState,i=e.children,a=(0,r.useState)(n.current),o=a[0],s=a[1];return(0,r.useEffect)(function(){t.current=s},[]),i.apply(void 0,o)},function(){return!0});return function(e){var t=n.useRef(i(e)),r=n.useRef(function(e){return t.current=e});return n.createElement(n.Fragment,null,n.createElement(a,{stateRef:r,props:e}),n.createElement(o,{stateRef:r,defaultState:t,children:e.children}))}}e.renderCar=i})),Nr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.exportSidecar=void 0;var t=(hr(),d(jn)),n=t.__importStar(m()),r=function(e){var r=e.sideCar,i=t.__rest(e,[`sideCar`]);if(!r)throw Error("Sidecar: please provide `sideCar` property to import the right car");var a=r.read();if(!a)throw Error(`Sidecar medium not found`);return n.createElement(a,t.__assign({},i))};r.isSideCarExport=!0;function i(e,t){return e.useMedium(t),r}e.exportSidecar=i})),Pr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.exportSidecar=e.renderCar=e.createSidecarMedium=e.createMedium=e.setConfig=e.useSidecar=e.sidecar=void 0;var t=kr();Object.defineProperty(e,`sidecar`,{enumerable:!0,get:function(){return t.sidecar}});var n=Or();Object.defineProperty(e,`useSidecar`,{enumerable:!0,get:function(){return n.useSidecar}});var r=Ar();Object.defineProperty(e,`setConfig`,{enumerable:!0,get:function(){return r.setConfig}});var i=jr();Object.defineProperty(e,`createMedium`,{enumerable:!0,get:function(){return i.createMedium}}),Object.defineProperty(e,`createSidecarMedium`,{enumerable:!0,get:function(){return i.createSidecarMedium}});var a=Mr();Object.defineProperty(e,`renderCar`,{enumerable:!0,get:function(){return a.renderCar}});var o=Nr();Object.defineProperty(e,`exportSidecar`,{enumerable:!0,get:function(){return o.exportSidecar}})})),Fr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.effectCar=void 0,e.effectCar=(0,Pr().createSidecarMedium)()})),Ir=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.RemoveScroll=void 0;var t=(hr(),d(jn)),n=t.__importStar(m()),r=gr(),i=Tr(),a=Fr(),o=function(){},s=n.forwardRef(function(e,r){var s=n.useRef(null),c=n.useState({onScrollCapture:o,onWheelCapture:o,onTouchMoveCapture:o}),l=c[0],u=c[1],d=e.forwardProps,f=e.children,p=e.className,m=e.removeScrollBar,h=e.enabled,g=e.shards,_=e.sideCar,v=e.noRelative,y=e.noIsolation,b=e.inert,x=e.allowPinchZoom,S=e.as,C=S===void 0?`div`:S,w=e.gapMode,T=t.__rest(e,[`forwardProps`,`children`,`className`,`removeScrollBar`,`enabled`,`shards`,`sideCar`,`noRelative`,`noIsolation`,`inert`,`allowPinchZoom`,`as`,`gapMode`]),E=_,D=(0,i.useMergeRefs)([s,r]),O=t.__assign(t.__assign({},T),l);return n.createElement(n.Fragment,null,h&&n.createElement(E,{sideCar:a.effectCar,removeScrollBar:m,shards:g,noRelative:v,noIsolation:y,inert:b,setCallbacks:u,allowPinchZoom:!!x,lockRef:s,gapMode:w}),d?n.cloneElement(n.Children.only(f),t.__assign(t.__assign({},O),{ref:D})):n.createElement(C,t.__assign({},O,{className:p,ref:D}),f))});e.RemoveScroll=s,s.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},s.classNames={fullWidth:r.fullWidthClassName,zeroRight:r.zeroRightClassName}})),Lr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0});var t;e.setNonce=function(e){t=e},e.getNonce=function(){if(t)return t;if(typeof __webpack_nonce__<`u`)return __webpack_nonce__}})),Rr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.stylesheetSingleton=void 0;var t=Lr();function n(){if(!document)return null;var e=document.createElement(`style`);e.type=`text/css`;var n=(0,t.getNonce)();return n&&e.setAttribute(`nonce`,n),e}function r(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function i(e){(document.head||document.getElementsByTagName(`head`)[0]).appendChild(e)}e.stylesheetSingleton=function(){var e=0,t=null;return{add:function(a){e==0&&(t=n())&&(r(t,a),i(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}}})),zr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.styleHookSingleton=void 0;var t=(hr(),d(jn)).__importStar(m()),n=Rr();e.styleHookSingleton=function(){var e=(0,n.stylesheetSingleton)();return function(n,r){t.useEffect(function(){return e.add(n),function(){e.remove()}},[n&&r])}}})),Br=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.styleSingleton=void 0;var t=zr();e.styleSingleton=function(){var e=(0,t.styleHookSingleton)();return function(t){var n=t.styles,r=t.dynamic;return e(n,r),null}}})),Vr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.styleHookSingleton=e.stylesheetSingleton=e.styleSingleton=void 0;var t=Br();Object.defineProperty(e,`styleSingleton`,{enumerable:!0,get:function(){return t.styleSingleton}});var n=Rr();Object.defineProperty(e,`stylesheetSingleton`,{enumerable:!0,get:function(){return n.stylesheetSingleton}});var r=zr();Object.defineProperty(e,`styleHookSingleton`,{enumerable:!0,get:function(){return r.styleHookSingleton}})})),Hr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.getGapWidth=e.zeroGap=void 0,e.zeroGap={left:0,top:0,right:0,gap:0};var t=function(e){return parseInt(e||``,10)||0},n=function(e){var n=window.getComputedStyle(document.body),r=n[e===`padding`?`paddingLeft`:`marginLeft`],i=n[e===`padding`?`paddingTop`:`marginTop`],a=n[e===`padding`?`paddingRight`:`marginRight`];return[t(r),t(i),t(a)]};e.getGapWidth=function(t){if(t===void 0&&(t=`margin`),typeof window>`u`)return e.zeroGap;var r=n(t),i=document.documentElement.clientWidth,a=window.innerWidth;return{left:r[0],top:r[1],right:r[2],gap:Math.max(0,a-i+r[2]-r[0])}}})),Ur=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.RemoveScrollBar=e.useLockAttribute=e.lockAttribute=void 0;var t=(hr(),d(jn)).__importStar(m()),n=Vr(),r=gr(),i=Hr(),a=(0,n.styleSingleton)();e.lockAttribute=`data-scroll-locked`;var o=function(t,n,i,a){var o=t.left,s=t.top,c=t.right,l=t.gap;return i===void 0&&(i=`margin`),`
75
+ .${r.noScrollbarsClassName} {
76
+ overflow: hidden ${a};
77
+ padding-right: ${l}px ${a};
53
78
  }
54
- body[`).concat(dr,`] {
55
- overflow: hidden `).concat(r,`;
79
+ body[${e.lockAttribute}] {
80
+ overflow: hidden ${a};
56
81
  overscroll-behavior: contain;
57
- `).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&`
58
- padding-left: `.concat(o,`px;
59
- padding-top: `).concat(i,`px;
60
- padding-right: `).concat(a,`px;
82
+ ${[n&&`position: relative ${a};`,i===`margin`&&`
83
+ padding-left: ${o}px;
84
+ padding-top: ${s}px;
85
+ padding-right: ${c}px;
61
86
  margin-left:0;
62
87
  margin-top:0;
63
- margin-right: `).concat(s,"px ").concat(r,`;
64
- `),n==="padding"&&"padding-right: ".concat(s,"px ").concat(r,";")].filter(Boolean).join(""),`
88
+ margin-right: ${l}px ${a};
89
+ `,i===`padding`&&`padding-right: ${l}px ${a};`].filter(Boolean).join(``)}
65
90
  }
66
91
 
67
- .`).concat(_o,` {
68
- right: `).concat(s,"px ").concat(r,`;
92
+ .${r.zeroRightClassName} {
93
+ right: ${l}px ${a};
69
94
  }
70
95
 
71
- .`).concat(Io,` {
72
- margin-right: `).concat(s,"px ").concat(r,`;
96
+ .${r.fullWidthClassName} {
97
+ margin-right: ${l}px ${a};
73
98
  }
74
99
 
75
- .`).concat(_o," .").concat(_o,` {
76
- right: 0 `).concat(r,`;
100
+ .${r.zeroRightClassName} .${r.zeroRightClassName} {
101
+ right: 0 ${a};
77
102
  }
78
103
 
79
- .`).concat(Io," .").concat(Io,` {
80
- margin-right: 0 `).concat(r,`;
104
+ .${r.fullWidthClassName} .${r.fullWidthClassName} {
105
+ margin-right: 0 ${a};
81
106
  }
82
107
 
83
- body[`).concat(dr,`] {
84
- `).concat(hp,": ").concat(s,`px;
108
+ body[${e.lockAttribute}] {
109
+ ${r.removedBarSizeVariable}: ${l}px;
85
110
  }
86
- `)},Ys=function(){var e=parseInt(document.body.getAttribute(dr)||"0",10);return isFinite(e)?e:0},Op=function(){d.useEffect(function(){return document.body.setAttribute(dr,(Ys()+1).toString()),function(){var e=Ys()-1;e<=0?document.body.removeAttribute(dr):document.body.setAttribute(dr,e.toString())}},[])},jp=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=r===void 0?"margin":r;Op();var i=d.useMemo(function(){return Dp(o)},[o]);return d.createElement(Ap,{styles:Tp(i,!t,o,n?"":"!important")})},la=!1;if(typeof window<"u")try{var go=Object.defineProperty({},"passive",{get:function(){return la=!0,!0}});window.addEventListener("test",go,go),window.removeEventListener("test",go,go)}catch{la=!1}var tr=la?{passive:!1}:!1,Lp=function(e){return e.tagName==="TEXTAREA"},jl=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!Lp(e)&&n[t]==="visible")},$p=function(e){return jl(e,"overflowY")},Fp=function(e){return jl(e,"overflowX")},Zs=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var o=Ll(e,r);if(o){var i=$l(e,r),a=i[1],s=i[2];if(a>s)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},zp=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},Bp=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},Ll=function(e,t){return e==="v"?$p(t):Fp(t)},$l=function(e,t){return e==="v"?zp(t):Bp(t)},Hp=function(e,t){return e==="h"&&t==="rtl"?-1:1},Vp=function(e,t,n,r,o){var i=Hp(e,window.getComputedStyle(t).direction),a=i*r,s=n.target,c=t.contains(s),l=!1,f=a>0,u=0,m=0;do{if(!s)break;var p=$l(e,s),g=p[0],b=p[1],h=p[2],x=b-h-i*g;(g||x)&&Ll(e,s)&&(u+=x,m+=g);var E=s.parentNode;s=E&&E.nodeType===Node.DOCUMENT_FRAGMENT_NODE?E.host:E}while(!c&&s!==document.body||c&&(t.contains(s)||t===s));return(f&&Math.abs(u)<1||!f&&Math.abs(m)<1)&&(l=!0),l},bo=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},qs=function(e){return[e.deltaX,e.deltaY]},Xs=function(e){return e&&"current"in e?e.current:e},Wp=function(e,t){return e[0]===t[0]&&e[1]===t[1]},Kp=function(e){return`
87
- .block-interactivity-`.concat(e,` {pointer-events: none;}
88
- .allow-interactivity-`).concat(e,` {pointer-events: all;}
89
- `)},Up=0,nr=[];function Gp(e){var t=d.useRef([]),n=d.useRef([0,0]),r=d.useRef(),o=d.useState(Up++)[0],i=d.useState(Ol)[0],a=d.useRef(e);d.useEffect(function(){a.current=e},[e]),d.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var b=mp([e.lockRef.current],(e.shards||[]).map(Xs),!0).filter(Boolean);return b.forEach(function(h){return h.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),b.forEach(function(h){return h.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var s=d.useCallback(function(b,h){if("touches"in b&&b.touches.length===2||b.type==="wheel"&&b.ctrlKey)return!a.current.allowPinchZoom;var x=bo(b),E=n.current,w="deltaX"in b?b.deltaX:E[0]-x[0],C="deltaY"in b?b.deltaY:E[1]-x[1],S,R=b.target,L=Math.abs(w)>Math.abs(C)?"h":"v";if("touches"in b&&L==="h"&&R.type==="range")return!1;var D=Zs(L,R);if(!D)return!0;if(D?S=L:(S=L==="v"?"h":"v",D=Zs(L,R)),!D)return!1;if(!r.current&&"changedTouches"in b&&(w||C)&&(r.current=S),!S)return!0;var H=r.current||S;return Vp(H,h,b,H==="h"?w:C)},[]),c=d.useCallback(function(b){var h=b;if(!(!nr.length||nr[nr.length-1]!==i)){var x="deltaY"in h?qs(h):bo(h),E=t.current.filter(function(S){return S.name===h.type&&(S.target===h.target||h.target===S.shadowParent)&&Wp(S.delta,x)})[0];if(E&&E.should){h.cancelable&&h.preventDefault();return}if(!E){var w=(a.current.shards||[]).map(Xs).filter(Boolean).filter(function(S){return S.contains(h.target)}),C=w.length>0?s(h,w[0]):!a.current.noIsolation;C&&h.cancelable&&h.preventDefault()}}},[]),l=d.useCallback(function(b,h,x,E){var w={name:b,delta:h,target:x,should:E,shadowParent:Yp(x)};t.current.push(w),setTimeout(function(){t.current=t.current.filter(function(C){return C!==w})},1)},[]),f=d.useCallback(function(b){n.current=bo(b),r.current=void 0},[]),u=d.useCallback(function(b){l(b.type,qs(b),b.target,s(b,e.lockRef.current))},[]),m=d.useCallback(function(b){l(b.type,bo(b),b.target,s(b,e.lockRef.current))},[]);d.useEffect(function(){return nr.push(i),e.setCallbacks({onScrollCapture:u,onWheelCapture:u,onTouchMoveCapture:m}),document.addEventListener("wheel",c,tr),document.addEventListener("touchmove",c,tr),document.addEventListener("touchstart",f,tr),function(){nr=nr.filter(function(b){return b!==i}),document.removeEventListener("wheel",c,tr),document.removeEventListener("touchmove",c,tr),document.removeEventListener("touchstart",f,tr)}},[]);var p=e.removeScrollBar,g=e.inert;return d.createElement(d.Fragment,null,g?d.createElement(i,{styles:Kp(o)}):null,p?d.createElement(jp,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function Yp(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const Zp=Ep(Tl,Gp);var ui=d.forwardRef(function(e,t){return d.createElement(si,Vt({},e,{ref:t,sideCar:Zp}))});ui.classNames=si.classNames;var qp=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},rr=new WeakMap,yo=new WeakMap,xo={},Yi=0,Fl=function(e){return e&&(e.host||Fl(e.parentNode))},Xp=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=Fl(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},Qp=function(e,t,n,r){var o=Xp(t,Array.isArray(e)?e:[e]);xo[n]||(xo[n]=new WeakMap);var i=xo[n],a=[],s=new Set,c=new Set(o),l=function(u){!u||s.has(u)||(s.add(u),l(u.parentNode))};o.forEach(l);var f=function(u){!u||c.has(u)||Array.prototype.forEach.call(u.children,function(m){if(s.has(m))f(m);else try{var p=m.getAttribute(r),g=p!==null&&p!=="false",b=(rr.get(m)||0)+1,h=(i.get(m)||0)+1;rr.set(m,b),i.set(m,h),a.push(m),b===1&&g&&yo.set(m,!0),h===1&&m.setAttribute(n,"true"),g||m.setAttribute(r,"true")}catch(x){console.error("aria-hidden: cannot operate on ",m,x)}})};return f(t),s.clear(),Yi++,function(){a.forEach(function(u){var m=rr.get(u)-1,p=i.get(u)-1;rr.set(u,m),i.set(u,p),m||(yo.has(u)||u.removeAttribute(r),yo.delete(u)),p||u.removeAttribute(n)}),Yi--,Yi||(rr=new WeakMap,rr=new WeakMap,yo=new WeakMap,xo={})}},Va=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=qp(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live], script"))),Qp(r,o,n,"aria-hidden")):function(){return null}},li="Dialog",[zl]=An(li),[Jp,Ot]=zl(li),Bl=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:o,onOpenChange:i,modal:a=!0}=e,s=d.useRef(null),c=d.useRef(null),[l,f]=wr({prop:r,defaultProp:o!=null?o:!1,onChange:i,caller:li});return v.jsx(Jp,{scope:t,triggerRef:s,contentRef:c,contentId:on(),titleId:on(),descriptionId:on(),open:l,onOpenChange:f,onOpenToggle:d.useCallback(()=>f(u=>!u),[f]),modal:a,children:n})};Bl.displayName=li;var Hl="DialogTrigger",eh=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Ot(Hl,n),i=Ue(t,o.triggerRef);return v.jsx($e.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":Ua(o.open),...r,ref:i,onClick:ie(e.onClick,o.onOpenToggle)})});eh.displayName=Hl;var Wa="DialogPortal",[th,Vl]=zl(Wa,{forceMount:void 0}),Wl=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:o}=e,i=Ot(Wa,t);return v.jsx(th,{scope:t,forceMount:n,children:d.Children.map(r,a=>v.jsx(Nt,{present:n||i.open,children:v.jsx(eo,{asChild:!0,container:o,children:a})}))})};Wl.displayName=Wa;var zo="DialogOverlay",Kl=d.forwardRef((e,t)=>{const n=Vl(zo,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,i=Ot(zo,e.__scopeDialog);return i.modal?v.jsx(Nt,{present:r||i.open,children:v.jsx(rh,{...o,ref:t})}):null});Kl.displayName=zo;var nh=vr("DialogOverlay.RemoveScroll"),rh=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Ot(zo,n);return v.jsx(ui,{as:nh,allowPinchZoom:!0,shards:[o.contentRef],children:v.jsx($e.div,{"data-state":Ua(o.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),Wn="DialogContent",Ul=d.forwardRef((e,t)=>{const n=Vl(Wn,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,i=Ot(Wn,e.__scopeDialog);return v.jsx(Nt,{present:r||i.open,children:i.modal?v.jsx(oh,{...o,ref:t}):v.jsx(ih,{...o,ref:t})})});Ul.displayName=Wn;var oh=d.forwardRef((e,t)=>{const n=Ot(Wn,e.__scopeDialog),r=d.useRef(null),o=Ue(t,n.contentRef,r);return d.useEffect(()=>{const i=r.current;if(i)return Va(i)},[]),v.jsx(Gl,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:ie(e.onCloseAutoFocus,i=>{var a;i.preventDefault(),(a=n.triggerRef.current)==null||a.focus()}),onPointerDownOutside:ie(e.onPointerDownOutside,i=>{const a=i.detail.originalEvent,s=a.button===0&&a.ctrlKey===!0;(a.button===2||s)&&i.preventDefault()}),onFocusOutside:ie(e.onFocusOutside,i=>i.preventDefault())})}),ih=d.forwardRef((e,t)=>{const n=Ot(Wn,e.__scopeDialog),r=d.useRef(!1),o=d.useRef(!1);return v.jsx(Gl,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:i=>{var a,s;(a=e.onCloseAutoFocus)==null||a.call(e,i),i.defaultPrevented||(r.current||(s=n.triggerRef.current)==null||s.focus(),i.preventDefault()),r.current=!1,o.current=!1},onInteractOutside:i=>{var c,l;(c=e.onInteractOutside)==null||c.call(e,i),i.defaultPrevented||(r.current=!0,i.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const a=i.target;(l=n.triggerRef.current)!=null&&l.contains(a)&&i.preventDefault(),i.detail.originalEvent.type==="focusin"&&o.current&&i.preventDefault()}})}),Gl=d.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:i,...a}=e,s=Ot(Wn,n),c=d.useRef(null),l=Ue(t,c);return Ha(),v.jsxs(v.Fragment,{children:[v.jsx(ai,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:i,children:v.jsx(Jr,{role:"dialog",id:s.contentId,"aria-describedby":s.descriptionId,"aria-labelledby":s.titleId,"data-state":Ua(s.open),...a,ref:l,onDismiss:()=>s.onOpenChange(!1)})}),v.jsxs(v.Fragment,{children:[v.jsx(ah,{titleId:s.titleId}),v.jsx(uh,{contentRef:c,descriptionId:s.descriptionId})]})]})}),Ka="DialogTitle",Yl=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Ot(Ka,n);return v.jsx($e.h2,{id:o.titleId,...r,ref:t})});Yl.displayName=Ka;var Zl="DialogDescription",ql=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Ot(Zl,n);return v.jsx($e.p,{id:o.descriptionId,...r,ref:t})});ql.displayName=Zl;var Xl="DialogClose",Ql=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Ot(Xl,n);return v.jsx($e.button,{type:"button",...r,ref:t,onClick:ie(e.onClick,()=>o.onOpenChange(!1))})});Ql.displayName=Xl;function Ua(e){return e?"open":"closed"}var Jl="DialogTitleWarning",[EC,ec]=jm(Jl,{contentName:Wn,titleName:Ka,docsSlug:"dialog"}),ah=({titleId:e})=>{const t=ec(Jl),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
111
+ `},s=function(){var t=parseInt(document.body.getAttribute(e.lockAttribute)||`0`,10);return isFinite(t)?t:0};e.useLockAttribute=function(){t.useEffect(function(){return document.body.setAttribute(e.lockAttribute,(s()+1).toString()),function(){var t=s()-1;t<=0?document.body.removeAttribute(e.lockAttribute):document.body.setAttribute(e.lockAttribute,t.toString())}},[])},e.RemoveScrollBar=function(n){var r=n.noRelative,s=n.noImportant,c=n.gapMode,l=c===void 0?`margin`:c;(0,e.useLockAttribute)();var u=t.useMemo(function(){return(0,i.getGapWidth)(l)},[l]);return t.createElement(a,{styles:o(u,!r,l,s?``:`!important`)})}})),Wr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.getGapWidth=e.removedBarSizeVariable=e.noScrollbarsClassName=e.fullWidthClassName=e.zeroRightClassName=e.RemoveScrollBar=void 0;var t=Ur();Object.defineProperty(e,`RemoveScrollBar`,{enumerable:!0,get:function(){return t.RemoveScrollBar}});var n=gr();Object.defineProperty(e,`zeroRightClassName`,{enumerable:!0,get:function(){return n.zeroRightClassName}}),Object.defineProperty(e,`fullWidthClassName`,{enumerable:!0,get:function(){return n.fullWidthClassName}}),Object.defineProperty(e,`noScrollbarsClassName`,{enumerable:!0,get:function(){return n.noScrollbarsClassName}}),Object.defineProperty(e,`removedBarSizeVariable`,{enumerable:!0,get:function(){return n.removedBarSizeVariable}});var r=Hr();Object.defineProperty(e,`getGapWidth`,{enumerable:!0,get:function(){return r.getGapWidth}})})),Gr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.nonPassive=void 0;var t=!1;if(typeof window<`u`)try{var n=Object.defineProperty({},`passive`,{get:function(){return t=!0,!0}});window.addEventListener(`test`,n,n),window.removeEventListener(`test`,n,n)}catch{t=!1}e.nonPassive=t?{passive:!1}:!1})),Kr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.handleScroll=e.locationCouldBeScrolled=void 0;var t=function(e){return e.tagName===`TEXTAREA`},n=function(e,n){if(!(e instanceof Element))return!1;var r=window.getComputedStyle(e);return r[n]!==`hidden`&&!(r.overflowY===r.overflowX&&!t(e)&&r[n]===`visible`)},r=function(e){return n(e,`overflowY`)},i=function(e){return n(e,`overflowX`)};e.locationCouldBeScrolled=function(e,t){var n=t.ownerDocument,r=t;do{if(typeof ShadowRoot<`u`&&r instanceof ShadowRoot&&(r=r.host),s(e,r)){var i=c(e,r);if(i[1]>i[2])return!0}r=r.parentNode}while(r&&r!==n.body);return!1};var a=function(e){return[e.scrollTop,e.scrollHeight,e.clientHeight]},o=function(e){return[e.scrollLeft,e.scrollWidth,e.clientWidth]},s=function(e,t){return e===`v`?r(t):i(t)},c=function(e,t){return e===`v`?a(t):o(t)},l=function(e,t){return e===`h`&&t===`rtl`?-1:1};e.handleScroll=function(e,t,n,r,i){var a=l(e,window.getComputedStyle(t).direction),o=a*r,u=n.target,d=t.contains(u),f=!1,p=o>0,m=0,h=0;do{if(!u)break;var g=c(e,u),_=g[0],v=g[1]-g[2]-a*_;(_||v)&&s(e,u)&&(m+=v,h+=_);var y=u.parentNode;u=y&&y.nodeType===Node.DOCUMENT_FRAGMENT_NODE?y.host:y}while(!d&&u!==document.body||d&&(t.contains(u)||t===u));return(p&&(i&&Math.abs(m)<1||!i&&o>m)||!p&&(i&&Math.abs(h)<1||!i&&-o>h))&&(f=!0),f}})),qr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.RemoveScrollSideCar=e.getDeltaXY=e.getTouchXY=void 0;var t=(hr(),d(jn)),n=t.__importStar(m()),r=Wr(),i=Vr(),a=Gr(),o=Kr();e.getTouchXY=function(e){return`changedTouches`in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},e.getDeltaXY=function(e){return[e.deltaX,e.deltaY]};var s=function(e){return e&&`current`in e?e.current:e},c=function(e,t){return e[0]===t[0]&&e[1]===t[1]},l=function(e){return`
112
+ .block-interactivity-${e} {pointer-events: none;}
113
+ .allow-interactivity-${e} {pointer-events: all;}
114
+ `},u=0,f=[];function p(d){var p=n.useRef([]),m=n.useRef([0,0]),g=n.useRef(),_=n.useState(u++)[0],v=n.useState(i.styleSingleton)[0],y=n.useRef(d);n.useEffect(function(){y.current=d},[d]),n.useEffect(function(){if(d.inert){document.body.classList.add(`block-interactivity-${_}`);var e=t.__spreadArray([d.lockRef.current],(d.shards||[]).map(s),!0).filter(Boolean);return e.forEach(function(e){return e.classList.add(`allow-interactivity-${_}`)}),function(){document.body.classList.remove(`block-interactivity-${_}`),e.forEach(function(e){return e.classList.remove(`allow-interactivity-${_}`)})}}},[d.inert,d.lockRef.current,d.shards]);var b=n.useCallback(function(t,n){if(`touches`in t&&t.touches.length===2||t.type===`wheel`&&t.ctrlKey)return!y.current.allowPinchZoom;var r=(0,e.getTouchXY)(t),i=m.current,a=`deltaX`in t?t.deltaX:i[0]-r[0],s=`deltaY`in t?t.deltaY:i[1]-r[1],c,l=t.target,u=Math.abs(a)>Math.abs(s)?`h`:`v`;if(`touches`in t&&u===`h`&&l.type===`range`)return!1;var d=(0,o.locationCouldBeScrolled)(u,l);if(!d)return!0;if(d?c=u:(c=u===`v`?`h`:`v`,d=(0,o.locationCouldBeScrolled)(u,l)),!d)return!1;if(!g.current&&`changedTouches`in t&&(a||s)&&(g.current=c),!c)return!0;var f=g.current||c;return(0,o.handleScroll)(f,n,t,f===`h`?a:s,!0)},[]),x=n.useCallback(function(t){var n=t;if(!(!f.length||f[f.length-1]!==v)){var r=`deltaY`in n?(0,e.getDeltaXY)(n):(0,e.getTouchXY)(n),i=p.current.filter(function(e){return e.name===n.type&&(e.target===n.target||n.target===e.shadowParent)&&c(e.delta,r)})[0];if(i&&i.should){n.cancelable&&n.preventDefault();return}if(!i){var a=(y.current.shards||[]).map(s).filter(Boolean).filter(function(e){return e.contains(n.target)});(a.length>0?b(n,a[0]):!y.current.noIsolation)&&n.cancelable&&n.preventDefault()}}},[]),S=n.useCallback(function(e,t,n,r){var i={name:e,delta:t,target:n,should:r,shadowParent:h(n)};p.current.push(i),setTimeout(function(){p.current=p.current.filter(function(e){return e!==i})},1)},[]),C=n.useCallback(function(t){m.current=(0,e.getTouchXY)(t),g.current=void 0},[]),w=n.useCallback(function(t){S(t.type,(0,e.getDeltaXY)(t),t.target,b(t,d.lockRef.current))},[]),T=n.useCallback(function(t){S(t.type,(0,e.getTouchXY)(t),t.target,b(t,d.lockRef.current))},[]);n.useEffect(function(){return f.push(v),d.setCallbacks({onScrollCapture:w,onWheelCapture:w,onTouchMoveCapture:T}),document.addEventListener(`wheel`,x,a.nonPassive),document.addEventListener(`touchmove`,x,a.nonPassive),document.addEventListener(`touchstart`,C,a.nonPassive),function(){f=f.filter(function(e){return e!==v}),document.removeEventListener(`wheel`,x,a.nonPassive),document.removeEventListener(`touchmove`,x,a.nonPassive),document.removeEventListener(`touchstart`,C,a.nonPassive)}},[]);var E=d.removeScrollBar,D=d.inert;return n.createElement(n.Fragment,null,D?n.createElement(v,{styles:l(_)}):null,E?n.createElement(r.RemoveScrollBar,{noRelative:d.noRelative,gapMode:d.gapMode}):null)}e.RemoveScrollSideCar=p;function h(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}})),Jr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0});var t=Pr(),n=qr(),r=Fr();e.default=(0,t.exportSidecar)(r.effectCar,n.RemoveScrollSideCar)})),Yr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0});var t=(hr(),d(jn)),n=t.__importStar(m()),r=Ir(),i=t.__importDefault(Jr()),a=n.forwardRef(function(e,a){return n.createElement(r.RemoveScroll,t.__assign({},e,{ref:a,sideCar:i.default}))});a.classNames=r.RemoveScroll.classNames,e.default=a})),Xr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.RemoveScroll=void 0,e.RemoveScroll=(hr(),d(jn)).__importDefault(Yr()).default})),Zr=s((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.suppressOthers=e.supportsInert=e.inertOthers=e.hideOthers=void 0;var t=function(e){return typeof document>`u`?null:(Array.isArray(e)?e[0]:e).ownerDocument.body},n=new WeakMap,r=new WeakMap,i={},a=0,o=function(e){return e&&(e.host||o(e.parentNode))},s=function(e,t){return t.map(function(t){if(e.contains(t))return t;var n=o(t);return n&&e.contains(n)?n:(console.error(`aria-hidden`,t,`in not contained inside`,e,`. Doing nothing`),null)}).filter(function(e){return!!e})},c=function(e,t,o,c){var l=s(t,Array.isArray(e)?e:[e]);i[o]||(i[o]=new WeakMap);var u=i[o],d=[],f=new Set,p=new Set(l),m=function(e){!e||f.has(e)||(f.add(e),m(e.parentNode))};l.forEach(m);var h=function(e){!e||p.has(e)||Array.prototype.forEach.call(e.children,function(e){if(f.has(e))h(e);else try{var t=e.getAttribute(c),i=t!==null&&t!==`false`,a=(n.get(e)||0)+1,s=(u.get(e)||0)+1;n.set(e,a),u.set(e,s),d.push(e),a===1&&i&&r.set(e,!0),s===1&&e.setAttribute(o,`true`),i||e.setAttribute(c,`true`)}catch(t){console.error(`aria-hidden: cannot operate on `,e,t)}})};return h(t),f.clear(),a++,function(){d.forEach(function(e){var t=n.get(e)-1,i=u.get(e)-1;n.set(e,t),u.set(e,i),t||(r.has(e)||e.removeAttribute(c),r.delete(e)),i||e.removeAttribute(o)}),a--,a||(n=new WeakMap,n=new WeakMap,r=new WeakMap,i={})}};e.hideOthers=function(e,n,r){r===void 0&&(r=`data-aria-hidden`);var i=Array.from(Array.isArray(e)?e:[e]),a=n||t(e);return a?(i.push.apply(i,Array.from(a.querySelectorAll(`[aria-live], script`))),c(i,a,r,`aria-hidden`)):function(){return null}},e.inertOthers=function(e,n,r){r===void 0&&(r=`data-inert-ed`);var i=n||t(e);return i?c(e,i,r,`inert`):function(){return null}},e.supportsInert=function(){return typeof HTMLElement<`u`&&HTMLElement.prototype.hasOwnProperty(`inert`)},e.suppressOthers=function(t,n,r){return r===void 0&&(r=`data-suppressed`),((0,e.supportsInert)()?e.inertOthers:e.hideOthers)(t,n,r)}})),Qr=Xr(),$r=Zr(),ei=`Dialog`,[ti,ni]=xt(ei),[ri,ii]=ti(ei),ai=e=>{let{__scopeDialog:t,children:n,open:r,defaultOpen:i,onOpenChange:a,modal:o=!0}=e,s=h.useRef(null),c=h.useRef(null),[l,u]=kt({prop:r,defaultProp:i==null?!1:i,onChange:a,caller:ei});return(0,z.jsx)(ri,{scope:t,triggerRef:s,contentRef:c,contentId:Dt(),titleId:Dt(),descriptionId:Dt(),open:l,onOpenChange:u,onOpenToggle:h.useCallback(()=>u(e=>!e),[u]),modal:o,children:n})};ai.displayName=ei;var oi=`DialogTrigger`,si=h.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=ii(oi,n),a=Re(t,i.triggerRef);return(0,z.jsx)(Vt.button,{type:`button`,"aria-haspopup":`dialog`,"aria-expanded":i.open,"aria-controls":i.contentId,"data-state":Di(i.open),...r,ref:a,onClick:B(e.onClick,i.onOpenToggle)})});si.displayName=oi;var ci=`DialogPortal`,[li,ui]=ti(ci,{forceMount:void 0}),di=e=>{let{__scopeDialog:t,forceMount:n,children:r,container:i}=e,a=ii(ci,t);return(0,z.jsx)(li,{scope:t,forceMount:n,children:h.Children.map(r,e=>(0,z.jsx)(wn,{present:n||a.open,children:(0,z.jsx)(Sn,{asChild:!0,container:i,children:e})}))})};di.displayName=ci;var fi=`DialogOverlay`,pi=h.forwardRef((e,t)=>{let n=ui(fi,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=ii(fi,e.__scopeDialog);return a.modal?(0,z.jsx)(wn,{present:r||a.open,children:(0,z.jsx)(hi,{...i,ref:t})}):null});pi.displayName=fi;var mi=Ft(`DialogOverlay.RemoveScroll`),hi=h.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=ii(fi,n);return(0,z.jsx)(Qr.RemoveScroll,{as:mi,allowPinchZoom:!0,shards:[i.contentRef],children:(0,z.jsx)(Vt.div,{"data-state":Di(i.open),...r,ref:t,style:{pointerEvents:`auto`,...r.style}})})}),gi=`DialogContent`,_i=h.forwardRef((e,t)=>{let n=ui(gi,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=ii(gi,e.__scopeDialog);return(0,z.jsx)(wn,{present:r||a.open,children:a.modal?(0,z.jsx)(vi,{...i,ref:t}):(0,z.jsx)(yi,{...i,ref:t})})});_i.displayName=gi;var vi=h.forwardRef((e,t)=>{let n=ii(gi,e.__scopeDialog),r=h.useRef(null),i=Re(t,n.contentRef,r);return h.useEffect(()=>{let e=r.current;if(e)return(0,$r.hideOthers)(e)},[]),(0,z.jsx)(bi,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:B(e.onCloseAutoFocus,e=>{var t;e.preventDefault(),(t=n.triggerRef.current)==null||t.focus()}),onPointerDownOutside:B(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0;(t.button===2||n)&&e.preventDefault()}),onFocusOutside:B(e.onFocusOutside,e=>e.preventDefault())})}),yi=h.forwardRef((e,t)=>{let n=ii(gi,e.__scopeDialog),r=h.useRef(!1),i=h.useRef(!1);return(0,z.jsx)(bi,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{var a;if((a=e.onCloseAutoFocus)==null||a.call(e,t),!t.defaultPrevented){var o;r.current||(o=n.triggerRef.current)==null||o.focus(),t.preventDefault()}r.current=!1,i.current=!1},onInteractOutside:t=>{var a,o;(a=e.onInteractOutside)==null||a.call(e,t),t.defaultPrevented||(r.current=!0,t.detail.originalEvent.type===`pointerdown`&&(i.current=!0));let s=t.target;(o=n.triggerRef.current)!=null&&o.contains(s)&&t.preventDefault(),t.detail.originalEvent.type===`focusin`&&i.current&&t.preventDefault()}})}),bi=h.forwardRef((e,t)=>{let{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:a,...o}=e,s=ii(gi,n),c=h.useRef(null),l=Re(t,c);return kn(),(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(ln,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:a,children:(0,z.jsx)(Zt,{role:`dialog`,id:s.contentId,"aria-describedby":s.descriptionId,"aria-labelledby":s.titleId,"data-state":Di(s.open),...o,ref:l,onDismiss:()=>s.onOpenChange(!1)})}),(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(ji,{titleId:s.titleId}),(0,z.jsx)(Mi,{contentRef:c,descriptionId:s.descriptionId})]})]})}),xi=`DialogTitle`,Si=h.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=ii(xi,n);return(0,z.jsx)(Vt.h2,{id:i.titleId,...r,ref:t})});Si.displayName=xi;var Ci=`DialogDescription`,wi=h.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=ii(Ci,n);return(0,z.jsx)(Vt.p,{id:i.descriptionId,...r,ref:t})});wi.displayName=Ci;var Ti=`DialogClose`,Ei=h.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=ii(Ti,n);return(0,z.jsx)(Vt.button,{type:`button`,...r,ref:t,onClick:B(e.onClick,()=>i.onOpenChange(!1))})});Ei.displayName=Ti;function Di(e){return e?`open`:`closed`}var Oi=`DialogTitleWarning`,[ki,Ai]=bt(Oi,{contentName:gi,titleName:xi,docsSlug:`dialog`}),ji=({titleId:e})=>{let t=Ai(Oi),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
90
115
 
91
116
  If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
92
117
 
93
- For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return d.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},sh="DialogDescriptionWarning",uh=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${ec(sh).contentName}}.`;return d.useEffect(()=>{var i;const o=(i=e.current)==null?void 0:i.getAttribute("aria-describedby");t&&o&&(document.getElementById(t)||console.warn(r))},[r,e,t]),null},lh=Bl,ch=Wl,tc=Kl,nc=Ul,rc=Yl,oc=ql,dh=Ql;const fh=lh,vh=ch,ic=y.forwardRef(({className:e,...t},n)=>v.jsx(tc,{ref:n,className:W(`
94
- data-[state=open]:univer-animate-in data-[state=open]:univer-fade-in-0
95
- data-[state=closed]:univer-animate-out data-[state=closed]:univer-fade-out-0
96
- univer-fixed univer-inset-0 univer-z-[1080] univer-bg-[rgba(0,0,0,0.8)]
97
- `,e),...t}));ic.displayName=tc.displayName;const ac=y.forwardRef(({className:e,children:t,closable:n=!0,onClickClose:r,...o},i)=>v.jsxs(vh,{children:[v.jsx(ic,{}),v.jsxs(nc,{ref:i,className:W(`
98
- data-[state=open]:univer-animate-in data-[state=open]:univer-fade-in-0
99
- data-[state=open]:univer-zoom-in-95 data-[state=open]:univer-slide-in-from-left-1/2
100
- data-[state=open]:univer-slide-in-from-top-[48%]
101
- data-[state=closed]:univer-animate-out data-[state=closed]:univer-fade-out-0
102
- data-[state=closed]:univer-zoom-out-95 data-[state=closed]:univer-slide-out-to-left-1/2
103
- data-[state=closed]:univer-slide-out-to-top-[48%]
104
- univer-fixed univer-left-1/2 univer-top-1/2 univer-z-[1080] univer-box-border univer-grid
105
- univer-w-full univer-max-w-lg -univer-translate-x-1/2 -univer-translate-y-1/2 univer-gap-4
106
- univer-bg-white univer-p-4 univer-text-gray-500 univer-shadow-md univer-duration-200
107
- sm:!univer-rounded-lg
108
- dark:!univer-bg-gray-700 dark:!univer-text-gray-400
109
- `,ct,e),...o,children:[t,n&&v.jsxs(dh,{className:"univer-absolute univer-right-4 univer-top-4 univer-size-6 univer-cursor-pointer univer-rounded-sm univer-border-none univer-bg-transparent univer-p-0 univer-transition-opacity hover:univer-opacity-100 disabled:univer-pointer-events-none",onClick:r,children:[v.jsx(ii,{className:"univer-size-4 univer-text-gray-400"}),v.jsx("span",{className:"univer-sr-only",children:"Close"})]})]})]}));ac.displayName=nc.displayName;const sc=({className:e,...t})=>v.jsx("div",{className:W(`
110
- univer-flex univer-flex-col univer-space-y-1.5 univer-text-center
111
- sm:!univer-text-left
112
- `,e),...t});sc.displayName="DialogHeader";const uc=({className:e,...t})=>v.jsx("div",{className:W(`
113
- univer-flex univer-flex-col-reverse
114
- sm:!univer-flex-row sm:!univer-justify-end sm:!univer-space-x-2
115
- `,e),...t});uc.displayName="DialogFooter";const lc=y.forwardRef(({className:e,...t},n)=>v.jsx(rc,{ref:n,className:W(`
116
- univer-my-0 univer-text-lg univer-font-semibold univer-leading-none univer-tracking-tight
117
- univer-text-gray-900
118
- dark:!univer-text-white
119
- `,e),...t}));lc.displayName=rc.displayName;const cc=y.forwardRef(({className:e,...t},n)=>v.jsx(oc,{ref:n,className:W("univer-text-sm univer-text-gray-500",e),...t}));cc.displayName=oc.displayName;function mh(e={}){const t=y.useCallback(()=>{const{innerWidth:h,innerHeight:x}=window;return{x:Math.max(0,(h-0)/2),y:Math.max(0,(x-0)/2)}},[]),{defaultPosition:n=t(),enabled:r=!1}=e,[o,i]=y.useState(n),[a,s]=y.useState(!1),c=y.useRef(null),l=y.useRef({x:0,y:0}),f=y.useRef({x:0,y:0}),u=y.useRef(!1);y.useEffect(()=>{if(!c.current||u.current||e.defaultPosition)return;const{width:h,height:x}=c.current.getBoundingClientRect(),{innerWidth:E,innerHeight:w}=window,C=Math.max(0,(E-h)/2),S=Math.max(0,(w-x)/2);i({x:C,y:S}),l.current={x:C,y:S},u.current=!0},[e.defaultPosition]);const m=y.useCallback((h,x)=>{if(!c.current)return{x:h,y:x};const E=c.current.getBoundingClientRect(),{clientWidth:w,clientHeight:C}=document.documentElement;let S=l.current.x+(h-f.current.x),R=l.current.y+(x-f.current.y);return S<0&&(S=0),R<0&&(R=0),S+E.width>w&&(S=w-E.width),R+E.height>C&&(R=C-E.height),{x:S,y:R}},[]),p=y.useCallback(h=>{r&&(h.preventDefault(),h.stopPropagation(),l.current={...o},f.current={x:h.clientX,y:h.clientY},s(!0),document.body.style.userSelect="none")},[r,o]),g=y.useCallback(h=>{if(!a)return;h.preventDefault(),h.stopPropagation();const x=m(h.clientX,h.clientY);i(x)},[a,m]),b=y.useCallback(()=>{s(!1),document.body.style.userSelect=""},[]);return y.useEffect(()=>{if(r)return document.addEventListener("mousemove",g),document.addEventListener("mouseup",b),()=>{document.removeEventListener("mousemove",g),document.removeEventListener("mouseup",b)}},[r,g,b]),{position:o,isDragging:a,elementRef:c,setElementRef:h=>{if(c.current=h,h&&!u.current&&!e.defaultPosition){const{width:x,height:E}=h.getBoundingClientRect(),{innerWidth:w,innerHeight:C}=window,S=Math.max(0,(w-x)/2),R=Math.max(0,(C-E)/2);i({x:S,y:R}),l.current={x:S,y:R},u.current=!0}},handleMouseDown:p}}function Ga(e){var z,A,_,M;const{className:t,children:n,style:r,open:o=!1,title:i,width:a,draggable:s=!1,defaultPosition:c,footer:l,mask:f=!0,keyboard:u=!0,closable:m=!0,maskClosable:p=!0,showOk:g,showCancel:b,onOpenChange:h,onClose:x,onOk:E,onCancel:w}=e,{locale:C}=y.useContext(Zt),{position:S,isDragging:R,setElementRef:L,handleMouseDown:D}=mh({defaultPosition:c,enabled:s}),H=l!=null?l:g||b?v.jsxs("div",{className:"univer-flex univer-justify-end univer-gap-2",children:[b&&v.jsx(un,{onClick:w,children:(A=(z=C==null?void 0:C.Confirm)==null?void 0:z.cancel)!=null?A:"Cancel"}),g&&v.jsx(un,{variant:"primary",onClick:E,children:(M=(_=C==null?void 0:C.Confirm)==null?void 0:_.confirm)!=null?M:"OK"})]}):null,k=y.useCallback(I=>{I&&s&&L(I)},[s,L]),T=y.useCallback(I=>{!f&&!I||(h==null||h(I),I||x==null||x())},[x,h]);function F(){h==null||h(!1),x==null||x()}return v.jsx(fh,{open:o,onOpenChange:T,modal:f!==!1,children:v.jsxs(ac,{ref:k,className:W(t,{"!univer-animate-none":s}),style:{...r,width:a?typeof a=="number"?`${a}px`:a:void 0,maxWidth:a?"initial":void 0,...s?{position:"absolute",margin:0,left:0,top:0,transform:`translate(${S.x}px, ${S.y}px)`,transition:R?"none":void 0,cursor:R?"grabbing":void 0}:{}},closable:m,onClickClose:F,onEscapeKeyDown:I=>{u&&F(),I.preventDefault()},onPointerDownOutside:I=>{p&&F(),I.preventDefault()},children:[v.jsxs(sc,{className:W({"!univer-hidden":!i}),"data-drag-handle":s?"true":void 0,style:{cursor:s?"grab":void 0,userSelect:s?"none":void 0,touchAction:s?"none":void 0},onMouseDown:s?D:void 0,children:[v.jsx(lc,{children:i}),v.jsx(cc,{className:"univer-hidden"})]}),n,H&&v.jsx(uc,{children:H})]})})}const mr=(e,t,n)=>{t=t/100,n=n/100;const r=n*t,o=r*(1-Math.abs(e/60%2-1)),i=n-r;let a=0,s=0,c=0;return e>=0&&e<60?(a=r,s=o,c=0):e>=60&&e<120?(a=o,s=r,c=0):e>=120&&e<180?(a=0,s=r,c=o):e>=180&&e<240?(a=0,s=o,c=r):e>=240&&e<300?(a=o,s=0,c=r):e>=300&&e<360&&(a=r,s=0,c=o),[Math.round((a+i)*255),Math.round((s+i)*255),Math.round((c+i)*255)]},dc=(e,t,n)=>{const r=o=>o.toString(16).padStart(2,"0");return`#${r(e)}${r(t)}${r(n)}`},Ya=(e,t,n)=>{e/=255,t/=255,n/=255;const r=Math.max(e,t,n),o=Math.min(e,t,n),i=r-o;let a=0,s=0;const c=r;return r!==0&&(s=i/r),i!==0&&(r===e?a=(t-n)/i+(t<n?6:0):r===t?a=(n-e)/i+2:r===n&&(a=(e-t)/i+4),a*=60),[a,s*100,c*100]},Za=e=>{e.length===4&&(e=`#${e.slice(1).split("").map(o=>o+o).join("")}`);const[t,n,r]=e.match(/\w\w/g).map(o=>Number.parseInt(o,16));return Ya(t,n,r)},Bo=(e,t,n)=>{const[r,o,i]=mr(e,t,n);return dc(r,o,i)},ph=(e,t,n,r)=>{const[o,i,a]=mr(e,t,n);return`rgba(${o}, ${i}, ${a}, ${r})`},hh=e=>{const t=e.match(/rgba?\((\d+),\s*(\d+),\s*(\d+)(?:,\s*(\d*\.?\d+))?\)/);if(!t)throw new Error("Invalid RGBA string");return[Number.parseInt(t[1],10),Number.parseInt(t[2],10),Number.parseInt(t[3],10),t[4]?Number.parseFloat(t[4]):1]};function gh({hsv:e,alpha:t,onChange:n,onChanged:r}){const[o,i]=y.useState(!1),a=y.useRef(null),s=y.useRef(null),c=y.useMemo(()=>{var g,b;return(b=(g=s.current)==null?void 0:g.clientWidth)!=null?b:0},[s.current]),l=y.useCallback(g=>{const b=a.current;if(!b)return;const h=b.getBoundingClientRect(),x=h.width-c,E=Math.max(0,Math.min(g-h.left,x));n(Math.round(E/x*100)/100)},[n]),f=y.useCallback(g=>{o&&l(g.clientX)},[o,l]),u=y.useCallback(()=>{i(!1),r==null||r(t)},[t]);y.useEffect(()=>(o&&(window.addEventListener("pointermove",f),window.addEventListener("pointerup",u),window.addEventListener("mouseup",u)),()=>{window.removeEventListener("pointermove",f),window.removeEventListener("pointerup",u),window.removeEventListener("mouseup",u)}),[o,f,u]);const m=()=>{var b;return`${Math.min(Math.max(t*100,0),100)/100*(100-c/((b=a.current)==null?void 0:b.clientWidth)*100)}%`},p=mr(...e);return v.jsxs("div",{className:"univer-relative univer-w-full univer-select-none",children:[v.jsx("div",{className:"univer-absolute univer-inset-0 univer-rounded-full",style:{backgroundImage:"linear-gradient(45deg, #E3E5EA 25%, transparent 25%), linear-gradient(-45deg, #E3E5EA 25%, transparent 25%), linear-gradient(45deg, transparent 75%, #E3E5EA 75%), linear-gradient(-45deg, transparent 75%, #E3E5EA 75%)",backgroundPosition:"0 0, 0 4px, 4px -4px, -4px 0",backgroundSize:"8px 8px"}}),v.jsx("div",{ref:a,className:"univer-relative univer-h-2 univer-w-full univer-cursor-pointer univer-rounded-full univer-shadow-inner",style:{background:`linear-gradient(to right, transparent, rgb(${p.join(",")}))`},onPointerDown:g=>{i(!0),l(g.clientX)},children:v.jsx("div",{ref:s,className:"univer-absolute univer-top-1/2 univer-box-border univer-size-2 univer-rounded-full univer-bg-transparent univer-shadow-md univer-ring-2 univer-ring-white univer-transition-transform univer-duration-75 univer-will-change-transform",style:{left:m(),transform:"translateY(-50%)",transition:o?"none":"all 0.1s ease-out"}})})]})}function bh({hsv:e,onChange:t}){const[n,r]=y.useState(""),o=y.useMemo(()=>Bo(e[0],e[1],e[2]),[e]);y.useEffect(()=>{r(o.replace(/^#/,""))},[o]);const i=c=>/^[0-9A-Fa-f]{6}$/.test(c),a=c=>{const l=c.target.value.trim();if(!(l.length>6)&&!(l!==""&&!/^[0-9A-Fa-f]*$/.test(l))&&(r(l),i(l))){const f=Za(l);f&&t&&t(...f)}},s=()=>{i(n)||r(o.replace(/^#/,""))};return v.jsxs(v.Fragment,{children:[v.jsx("input",{className:W("univer-w-full univer-px-2 !univer-pl-4 univer-uppercase focus:univer-border-primary-500 focus:univer-outline-none dark:!univer-text-white",ct),value:n,onChange:a,onBlur:s,maxLength:6,spellCheck:!1}),v.jsx("span",{className:"univer-absolute univer-left-1.5 univer-top-1/2 -univer-translate-y-1/2 univer-text-sm univer-text-gray-400",children:"#"})]})}function yh({hsv:e,alpha:t,format:n,onChange:r}){const[o,i]=y.useState({r:0,g:0,b:0,a:1});y.useEffect(()=>{const[c,l,f]=mr(e[0],e[1],e[2]);i({r:Math.round(c),g:Math.round(l),b:Math.round(f),a:t!=null?t:1})},[e,t]);const a=(c,l)=>{if(c==="a"){if(l!==""&&!/^\d*\.?\d*$/.test(l))return;const m=l===""?0:Number.parseFloat(l);if(m>1)return;const p={...o,a:m};i(p),r&&r(e[0],e[1],e[2],m);return}if(l!==""&&!/^\d*$/.test(l))return;const f=l===""?0:Number.parseInt(l,10);if(f>255)return;const u={...o,[c]:f};if(i(u),r){const m=Ya(u.r,u.g,u.b);r(...m,o.a)}},s=()=>{const[c,l,f]=mr(e[0],e[1],e[2]);i({r:Math.round(c),g:Math.round(l),b:Math.round(f),a:t!=null?t:1})};return v.jsxs("div",{className:"univer-flex univer-items-center univer-gap-2 [&>input]:univer-w-11 [&>input]:univer-border-gray-200 [&>input]:focus:univer-border-primary-500 dark:[&>input]:!univer-border-gray-600 dark:[&>input]:!univer-text-white",children:[v.jsx("input",{value:o.r,onChange:c=>a("r",c.target.value),onBlur:s,maxLength:3}),v.jsx("input",{value:o.g,onChange:c=>a("g",c.target.value),onBlur:s,maxLength:3}),v.jsx("input",{value:o.b,onChange:c=>a("b",c.target.value),onBlur:s,maxLength:3}),n==="rgba"&&v.jsx("input",{value:o.a,onChange:c=>a("a",c.target.value),onBlur:s,maxLength:4})]})}function xh({hsv:e,alpha:t,format:n,onChange:r}){return v.jsx("div",{className:"dark:![&_input]:univer-border-gray-600 dark:![&_input]:univer-text-white univer-flex univer-gap-2 [&_input]:univer-box-border [&_input]:univer-flex [&_input]:univer-h-7 [&_input]:univer-items-center [&_input]:univer-rounded [&_input]:univer-border [&_input]:univer-border-solid [&_input]:univer-border-gray-200 [&_input]:univer-bg-transparent [&_input]:univer-px-1.5 [&_input]:univer-text-sm [&_input]:univer-text-gray-700 [&_input]:univer-outline-none",children:v.jsxs("div",{className:"univer-relative univer-flex univer-flex-1 univer-gap-2",children:[v.jsx(bh,{hsv:e,onChange:r}),v.jsx(yh,{hsv:e,alpha:t,format:n,onChange:r})]})})}const wh=[["#FFFFFF","#E1EFFE","#FDE8E8","#FEECDC","#FFF4B9","#DEF7EC","#D5F5F6","#EDEBFE","#FCE8F3"],["#CDD0D8","#A4CAFE","#F8B4B4","#FDBA8C","#FAC815","#84E1BC","#7EDCE2","#CABFFD","#F8B4D9"],["#979DAC","#3F83F8","#F05252","#FF5A1F","#D49D0F","#0DA471","#0694A2","#9061F9","#E74694"],["#414657","#1A56DB","#C81E1E","#B43403","#9A6D15","#046C4E","#036672","#6C2BD9","#BF125D"],["#000000","#233876","#771D1D","#771D1D","#634312","#014737","#014451","#4A1D96","#751A3D"]];function Ch({hsv:e,onChange:t}){const n=y.useCallback(o=>{const[i,a,s]=Za(o);t(i,a,s)},[t]),r=Bo(e[0],e[1],e[2]);return v.jsx("div",{"data-u-comp":"color-picker-presets",className:"univer-grid univer-content-center univer-gap-2",children:wh.map((o,i)=>v.jsx("div",{className:"univer-grid univer-grid-flow-col univer-items-center univer-justify-between univer-gap-2",children:o.map((a,s)=>v.jsx("button",{type:"button",className:W("univer-box-border univer-size-5 univer-cursor-pointer univer-rounded-full univer-border univer-border-solid univer-border-transparent univer-bg-gray-300 univer-transition-shadow",{"univer-ring-2 univer-ring-offset-2 univer-ring-offset-white dark:!univer-ring-primary-600 dark:!univer-ring-offset-gray-600":a.toUpperCase()===r.toUpperCase(),"!univer-border-gray-200":i===0&&s===0}),style:{backgroundColor:a},onClick:()=>n(a)},s))},i))})}function Eh({hsv:e,onChange:t,onChanged:n}){const r=y.useRef(null),o=y.useRef(null),[i,a]=y.useState(!1);y.useEffect(()=>{const u=r.current;if(!u)return;const m=u.getContext("2d");if(!m)return;const p=m.createLinearGradient(0,0,u.width,0);p.addColorStop(0,`hsl(${e[0]}, 0%, 50%)`),p.addColorStop(1,`hsl(${e[0]}, 100%, 50%)`),m.fillStyle=p,m.fillRect(0,0,u.width,u.height);const g=m.createLinearGradient(0,0,0,u.height);g.addColorStop(0,"rgba(255, 255, 255, 0)"),g.addColorStop(1,"rgba(0, 0, 0, 1)"),m.fillStyle=g,m.fillRect(0,0,u.width,u.height)},[e]);const s=u=>{u.stopPropagation();const m=r.current;if(!m)return;const p=m.getBoundingClientRect(),g=Math.max(0,Math.min(u.clientX-p.left,p.width)),b=Math.max(0,Math.min(u.clientY-p.top,p.height)),h=g/p.width*100,x=100-b/p.height*100;t(e[0],h,x)},c=y.useCallback(()=>{a(!1)},[e]);function l(){n==null||n(e[0],e[1],e[2])}y.useEffect(()=>{var u;return(u=o.current)==null||u.addEventListener("mouseup",l),window.addEventListener("pointerup",c),window.addEventListener("mouseup",c),()=>{var m;(m=o.current)==null||m.removeEventListener("mouseup",l),window.removeEventListener("pointerup",c),window.removeEventListener("mouseup",c)}},[e]);const f=()=>{var x,E,w,C;const p=(E=(x=o.current)==null?void 0:x.clientWidth)!=null?E:0,g=(C=(w=o.current)==null?void 0:w.clientHeight)!=null?C:0,b=e[1]/100*p-8,h=(100-e[2])/100*g-8;return{transform:`translate(${b}px, ${h}px)`,transition:i?"none":"transform 0.1s ease-out"}};return y.useEffect(()=>{const u=()=>{a(!1)};return window.addEventListener("pointerup",u),window.addEventListener("mouseup",u),()=>{window.removeEventListener("pointerup",u),window.removeEventListener("mouseup",u)}},[]),v.jsxs("div",{"data-u-comp":"color-picker-spectrum",ref:o,className:"univer-relative univer-overflow-hidden",children:[v.jsx("canvas",{ref:r,className:"univer-size-full univer-cursor-crosshair univer-rounded",onPointerDown:u=>{a(!0),s(u)},onPointerMove:u=>i&&s(u)}),v.jsx("div",{className:"univer-pointer-events-none univer-absolute univer-left-0 univer-top-0 univer-size-4 univer-rounded-full univer-border-2 univer-border-white univer-shadow-md univer-ring-2 univer-ring-white univer-will-change-transform",style:f()})]})}function Sh({hsv:e,onChange:t,onChanged:n}){const[r,o]=y.useState(!1),i=y.useRef(null),a=y.useRef(null),s=y.useMemo(()=>{var m,p;return(p=(m=a.current)==null?void 0:m.clientWidth)!=null?p:0},[]),c=y.useCallback(m=>{const p=i.current;if(!p)return;const g=p.getBoundingClientRect(),b=g.width-s,h=Math.max(0,Math.min(m-g.left,b)),x=Math.round(h/b*360);t(x,e[1],e[2])},[e,s,t]),l=y.useCallback(m=>{m.stopPropagation(),r&&c(m.clientX)},[r,c]),f=y.useCallback(()=>{o(!1),n==null||n(e[0],e[1],e[2])},[e,n]);y.useEffect(()=>(r&&(window.addEventListener("pointermove",l),window.addEventListener("pointerup",f),window.addEventListener("mouseup",f)),()=>{window.removeEventListener("pointermove",l),window.removeEventListener("pointerup",f),window.removeEventListener("mouseup",f)}),[r,l,f]);const u=()=>{var p;return`${Math.min(Math.max(e[0],0),360)/360*(100-s/((p=i.current)==null?void 0:p.clientWidth)*100)}%`};return v.jsx("div",{"data-u-comp":"color-picker-hue-slider",className:"univer-relative univer-w-full univer-select-none",children:v.jsx("div",{ref:i,className:"univer-relative univer-h-2 univer-w-full univer-cursor-pointer univer-rounded-full univer-shadow-inner",style:{background:`linear-gradient(to right,
118
+ For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return h.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},V=`DialogDescriptionWarning`,Mi=({contentRef:e,descriptionId:t})=>{let n=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${Ai(V).contentName}}.`;return h.useEffect(()=>{var r;let i=(r=e.current)==null?void 0:r.getAttribute(`aria-describedby`);t&&i&&(document.getElementById(t)||console.warn(n))},[n,e,t]),null},Ni=ai,Pi=di,Fi=pi,Ii=_i,Li=Si,Ri=wi,zi=Ei;const Bi=Ni,Vi=Pi,Hi=(0,h.forwardRef)(({className:e,...t},n)=>(0,z.jsx)(Fi,{ref:n,className:R(`data-[state=open]:univer-animate-in data-[state=open]:univer-fade-in-0 data-[state=closed]:univer-animate-out data-[state=closed]:univer-fade-out-0 univer-fixed univer-inset-0 univer-z-[1080] univer-bg-[rgba(0,0,0,0.8)]`,e),...t}));Hi.displayName=Fi.displayName;const Ui=(0,h.forwardRef)(({className:e,children:t,closable:n=!0,onClickClose:r,...i},a)=>(0,z.jsxs)(Vi,{children:[(0,z.jsx)(Hi,{}),(0,z.jsxs)(Ii,{ref:a,className:R(`data-[state=open]:univer-animate-in data-[state=open]:univer-fade-in-0 data-[state=open]:univer-zoom-in-95 data-[state=open]:univer-slide-in-from-left-1/2 data-[state=open]:univer-slide-in-from-top-[48%] data-[state=closed]:univer-animate-out data-[state=closed]:univer-fade-out-0 data-[state=closed]:univer-zoom-out-95 data-[state=closed]:univer-slide-out-to-left-1/2 data-[state=closed]:univer-slide-out-to-top-[48%] univer-fixed univer-left-1/2 univer-top-1/2 univer-z-[1080] univer-box-border univer-grid univer-w-full univer-max-w-lg -univer-translate-x-1/2 -univer-translate-y-1/2 univer-gap-4 univer-bg-white univer-p-4 univer-text-gray-500 univer-shadow-md univer-duration-200 sm:!univer-rounded-lg dark:!univer-bg-gray-700 dark:!univer-text-gray-400`,at,e),...i,children:[t,n&&(0,z.jsxs)(zi,{className:`univer-absolute univer-right-4 univer-top-4 univer-size-6 univer-cursor-pointer univer-rounded-sm univer-border-none univer-bg-transparent univer-p-0 univer-transition-opacity hover:univer-opacity-100 disabled:univer-pointer-events-none`,onClick:r,children:[(0,z.jsx)(f.CloseIcon,{className:`univer-size-4 univer-text-gray-400`}),(0,z.jsx)(`span`,{className:`univer-sr-only`,children:`Close`})]})]})]}));Ui.displayName=Ii.displayName;const Wi=({className:e,...t})=>(0,z.jsx)(`div`,{className:R(`univer-flex univer-flex-col univer-space-y-1.5 univer-text-center sm:!univer-text-left`,e),...t});Wi.displayName=`DialogHeader`;const Gi=({className:e,...t})=>(0,z.jsx)(`div`,{className:R(`univer-flex univer-flex-col-reverse sm:!univer-flex-row sm:!univer-justify-end sm:!univer-space-x-2`,e),...t});Gi.displayName=`DialogFooter`;const Ki=(0,h.forwardRef)(({className:e,...t},n)=>(0,z.jsx)(Li,{ref:n,className:R(`univer-my-0 univer-text-lg univer-font-semibold univer-leading-none univer-tracking-tight univer-text-gray-900 dark:!univer-text-white`,e),...t}));Ki.displayName=Li.displayName;const qi=(0,h.forwardRef)(({className:e,...t},n)=>(0,z.jsx)(Ri,{ref:n,className:R(`univer-text-sm univer-text-gray-500`,e),...t}));qi.displayName=Ri.displayName;function Ji(e={}){let t=(0,h.useCallback)(()=>{let{innerWidth:e,innerHeight:t}=window;return{x:Math.max(0,(e-0)/2),y:Math.max(0,(t-0)/2)}},[]),{defaultPosition:n=t(),enabled:r=!1}=e,[i,a]=(0,h.useState)(n),[o,s]=(0,h.useState)(!1),c=(0,h.useRef)(null),l=(0,h.useRef)({x:0,y:0}),u=(0,h.useRef)({x:0,y:0}),d=(0,h.useRef)(!1);(0,h.useEffect)(()=>{if(!c.current||d.current||e.defaultPosition)return;let{width:t,height:n}=c.current.getBoundingClientRect(),{innerWidth:r,innerHeight:i}=window,o=Math.max(0,(r-t)/2),s=Math.max(0,(i-n)/2);a({x:o,y:s}),l.current={x:o,y:s},d.current=!0},[e.defaultPosition]);let f=(0,h.useCallback)((e,t)=>{if(!c.current)return{x:e,y:t};let n=c.current.getBoundingClientRect(),{clientWidth:r,clientHeight:i}=document.documentElement,a=l.current.x+(e-u.current.x),o=l.current.y+(t-u.current.y);return a<0&&(a=0),o<0&&(o=0),a+n.width>r&&(a=r-n.width),o+n.height>i&&(o=i-n.height),{x:a,y:o}},[]),p=(0,h.useCallback)(e=>{r&&(e.preventDefault(),e.stopPropagation(),l.current={...i},u.current={x:e.clientX,y:e.clientY},s(!0),document.body.style.userSelect=`none`)},[r,i]),m=(0,h.useCallback)(e=>{o&&(e.preventDefault(),e.stopPropagation(),a(f(e.clientX,e.clientY)))},[o,f]),g=(0,h.useCallback)(()=>{s(!1),document.body.style.userSelect=``},[]);return(0,h.useEffect)(()=>{if(r)return document.addEventListener(`mousemove`,m),document.addEventListener(`mouseup`,g),()=>{document.removeEventListener(`mousemove`,m),document.removeEventListener(`mouseup`,g)}},[r,m,g]),{position:i,isDragging:o,elementRef:c,setElementRef:t=>{if(c.current=t,t&&!d.current&&!e.defaultPosition){let{width:e,height:n}=t.getBoundingClientRect(),{innerWidth:r,innerHeight:i}=window,o=Math.max(0,(r-e)/2),s=Math.max(0,(i-n)/2);a({x:o,y:s}),l.current={x:o,y:s},d.current=!0}},handleMouseDown:p}}function Yi(e){var t,n,r,i;let{className:a,children:o,style:s,open:c=!1,title:l,width:u,draggable:d=!1,defaultPosition:f,footer:p,mask:m=!0,keyboard:g=!0,closable:_=!0,maskClosable:v=!0,showOk:y,showCancel:b,onOpenChange:x,onClose:S,onOk:C,onCancel:w}=e,{locale:T}=(0,h.useContext)(et),{position:E,isDragging:D,setElementRef:O,handleMouseDown:k}=Ji({defaultPosition:f,enabled:d}),A=p==null?y||b?(0,z.jsxs)(`div`,{className:`univer-flex univer-justify-end univer-gap-2`,children:[b&&(0,z.jsx)(Ze,{onClick:w,children:(t=T==null||(n=T.Confirm)==null?void 0:n.cancel)==null?`Cancel`:t}),y&&(0,z.jsx)(Ze,{variant:`primary`,onClick:C,children:(r=T==null||(i=T.Confirm)==null?void 0:i.confirm)==null?`OK`:r})]}):null:p,j=(0,h.useCallback)(e=>{e&&d&&O(e)},[d,O]),ee=(0,h.useCallback)(e=>{!m&&!e||(x==null||x(e),e||S==null||S())},[S,x]);function M(){x==null||x(!1),S==null||S()}return(0,z.jsx)(Bi,{open:c,onOpenChange:ee,modal:m!==!1,children:(0,z.jsxs)(Ui,{ref:j,className:R(a,{"!univer-animate-none":d}),style:{...s,width:u?typeof u==`number`?`${u}px`:u:void 0,maxWidth:u?`initial`:void 0,...d?{position:`absolute`,margin:0,left:0,top:0,transform:`translate(${E.x}px, ${E.y}px)`,transition:D?`none`:void 0,cursor:D?`grabbing`:void 0}:{}},closable:_,onClickClose:M,onEscapeKeyDown:e=>{g&&M(),e.preventDefault()},onPointerDownOutside:e=>{v&&M(),e.preventDefault()},children:[(0,z.jsxs)(Wi,{className:R({"!univer-hidden":!l}),"data-drag-handle":d?`true`:void 0,style:{cursor:d?`grab`:void 0,userSelect:d?`none`:void 0,touchAction:d?`none`:void 0},onMouseDown:d?k:void 0,children:[(0,z.jsx)(Ki,{children:l}),(0,z.jsx)(qi,{className:`univer-hidden`})]}),o,A&&(0,z.jsx)(Gi,{children:A})]})})}const Xi=(e,t,n)=>{t/=100,n/=100;let r=n*t,i=r*(1-Math.abs(e/60%2-1)),a=n-r,o=0,s=0,c=0;return e>=0&&e<60?(o=r,s=i,c=0):e>=60&&e<120?(o=i,s=r,c=0):e>=120&&e<180?(o=0,s=r,c=i):e>=180&&e<240?(o=0,s=i,c=r):e>=240&&e<300?(o=i,s=0,c=r):e>=300&&e<360&&(o=r,s=0,c=i),[Math.round((o+a)*255),Math.round((s+a)*255),Math.round((c+a)*255)]},Zi=(e,t,n)=>{let r=e=>e.toString(16).padStart(2,`0`);return`#${r(e)}${r(t)}${r(n)}`},Qi=(e,t,n)=>{e/=255,t/=255,n/=255;let r=Math.max(e,t,n),i=r-Math.min(e,t,n),a=0,o=0,s=r;return r!==0&&(o=i/r),i!==0&&(r===e?a=(t-n)/i+(t<n?6:0):r===t?a=(n-e)/i+2:r===n&&(a=(e-t)/i+4),a*=60),[a,o*100,s*100]},$i=e=>{e.length===4&&(e=`#${e.slice(1).split(``).map(e=>e+e).join(``)}`);let[t,n,r]=e.match(/\w\w/g).map(e=>Number.parseInt(e,16));return Qi(t,n,r)},ea=(e,t,n)=>{let[r,i,a]=Xi(e,t,n);return Zi(r,i,a)},ta=(e,t,n,r)=>{let[i,a,o]=Xi(e,t,n);return`rgba(${i}, ${a}, ${o}, ${r})`},na=e=>{let t=e.match(/rgba?\((\d+),\s*(\d+),\s*(\d+)(?:,\s*(\d*\.?\d+))?\)/);if(!t)throw Error(`Invalid RGBA string`);return[Number.parseInt(t[1],10),Number.parseInt(t[2],10),Number.parseInt(t[3],10),t[4]?Number.parseFloat(t[4]):1]};function ra({hsv:e,alpha:t,onChange:n,onChanged:r}){let[i,a]=(0,h.useState)(!1),o=(0,h.useRef)(null),s=(0,h.useRef)(null),c=(0,h.useCallback)(e=>{var t,r;let i=o.current;if(!i)return;let a=(t=(r=s.current)==null?void 0:r.clientWidth)==null?0:t,c=i.getBoundingClientRect(),l=c.width-a;if(l<=0){n(0);return}let u=Math.max(0,Math.min(e-c.left,l));n(Math.round(u/l*100)/100)},[n]),l=(0,h.useCallback)(e=>{i&&c(e.clientX)},[i,c]),u=(0,h.useCallback)(()=>{a(!1),r==null||r(t)},[t]);(0,h.useEffect)(()=>(i&&(window.addEventListener(`pointermove`,l),window.addEventListener(`pointerup`,u),window.addEventListener(`mouseup`,u)),()=>{window.removeEventListener(`pointermove`,l),window.removeEventListener(`pointerup`,u),window.removeEventListener(`mouseup`,u)}),[i,l,u]);let d=()=>{var e,n,r,i;let a=Math.min(Math.max(t*100,0),100),c=(e=(n=s.current)==null?void 0:n.clientWidth)==null?0:e,l=(r=(i=o.current)==null?void 0:i.clientWidth)==null?0:r,u=l>0?c/l*100:0;return`${a/100*(100-u)}%`},f=Xi(...e);return(0,z.jsxs)(`div`,{className:`univer-relative univer-w-full univer-select-none`,children:[(0,z.jsx)(`div`,{className:`univer-absolute univer-inset-0 univer-rounded-full`,style:{backgroundImage:`linear-gradient(45deg, #E3E5EA 25%, transparent 25%), linear-gradient(-45deg, #E3E5EA 25%, transparent 25%), linear-gradient(45deg, transparent 75%, #E3E5EA 75%), linear-gradient(-45deg, transparent 75%, #E3E5EA 75%)`,backgroundPosition:`0 0, 0 4px, 4px -4px, -4px 0`,backgroundSize:`8px 8px`}}),(0,z.jsx)(`div`,{ref:o,className:`univer-relative univer-h-2 univer-w-full univer-cursor-pointer univer-rounded-full univer-shadow-inner`,style:{background:`linear-gradient(to right, transparent, rgb(${f.join(`,`)}))`},onPointerDown:e=>{a(!0),c(e.clientX)},children:(0,z.jsx)(`div`,{ref:s,className:`univer-absolute univer-top-1/2 univer-box-border univer-size-2 univer-rounded-full univer-bg-transparent univer-shadow-md univer-ring-2 univer-ring-white univer-transition-transform univer-duration-75 univer-will-change-transform`,style:{left:d(),transform:`translateY(-50%)`,transition:i?`none`:`all 0.1s ease-out`}})})]})}function ia({hsv:e,onChange:t}){let[n,r]=(0,h.useState)(``),i=(0,h.useMemo)(()=>ea(e[0],e[1],e[2]),[e]);(0,h.useEffect)(()=>{r(i.replace(/^#/,``))},[i]);let a=e=>/^[0-9A-Fa-f]{6}$/.test(e);return(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(`input`,{className:R(`univer-w-full univer-px-2 !univer-pl-4 univer-uppercase focus:univer-border-primary-500 focus:univer-outline-none dark:!univer-text-white`,at),value:n,onChange:e=>{let n=e.target.value.trim();if(!(n.length>6)&&!(n!==``&&!/^[0-9A-Fa-f]*$/.test(n))&&(r(n),a(n))){let e=$i(n);e&&t&&t(...e)}},onBlur:()=>{a(n)||r(i.replace(/^#/,``))},maxLength:6,spellCheck:!1}),(0,z.jsx)(`span`,{className:`univer-absolute univer-left-1.5 univer-top-1/2 -univer-translate-y-1/2 univer-text-sm univer-text-gray-400`,children:`#`})]})}function aa({hsv:e,alpha:t,format:n,onChange:r}){let[i,a]=(0,h.useState)({r:0,g:0,b:0,a:1});(0,h.useEffect)(()=>{let[n,r,i]=Xi(e[0],e[1],e[2]);a({r:Math.round(n),g:Math.round(r),b:Math.round(i),a:t==null?1:t})},[e,t]);let o=(t,n)=>{if(t===`a`){if(n!==``&&!/^\d*\.?\d*$/.test(n))return;let t=n===``?0:Number.parseFloat(n);if(t>1)return;a({...i,a:t}),r&&r(e[0],e[1],e[2],t);return}if(n!==``&&!/^\d*$/.test(n))return;let o=n===``?0:Number.parseInt(n,10);if(o>255)return;let s={...i,[t]:o};a(s),r&&r(...Qi(s.r,s.g,s.b),i.a)},s=()=>{let[n,r,i]=Xi(e[0],e[1],e[2]);a({r:Math.round(n),g:Math.round(r),b:Math.round(i),a:t==null?1:t})};return(0,z.jsxs)(`div`,{className:`univer-flex univer-items-center univer-gap-2 [&>input]:univer-w-11 [&>input]:univer-border-gray-200 [&>input]:focus:univer-border-primary-500 dark:[&>input]:!univer-border-gray-600 dark:[&>input]:!univer-text-white`,children:[(0,z.jsx)(`input`,{value:i.r,onChange:e=>o(`r`,e.target.value),onBlur:s,maxLength:3}),(0,z.jsx)(`input`,{value:i.g,onChange:e=>o(`g`,e.target.value),onBlur:s,maxLength:3}),(0,z.jsx)(`input`,{value:i.b,onChange:e=>o(`b`,e.target.value),onBlur:s,maxLength:3}),n===`rgba`&&(0,z.jsx)(`input`,{value:i.a,onChange:e=>o(`a`,e.target.value),onBlur:s,maxLength:4})]})}function oa({hsv:e,alpha:t,format:n,onChange:r}){return(0,z.jsx)(`div`,{className:`dark:![&_input]:univer-border-gray-600 dark:![&_input]:univer-text-white univer-flex univer-gap-2 [&_input]:univer-box-border [&_input]:univer-flex [&_input]:univer-h-7 [&_input]:univer-items-center [&_input]:univer-rounded [&_input]:univer-border [&_input]:univer-border-solid [&_input]:univer-border-gray-200 [&_input]:univer-bg-transparent [&_input]:univer-px-1.5 [&_input]:univer-text-sm [&_input]:univer-text-gray-700 [&_input]:univer-outline-none`,children:(0,z.jsxs)(`div`,{className:`univer-relative univer-flex univer-flex-1 univer-gap-2`,children:[(0,z.jsx)(ia,{hsv:e,onChange:r}),(0,z.jsx)(aa,{hsv:e,alpha:t,format:n,onChange:r})]})})}const sa=[[`#FFFFFF`,`#E1EFFE`,`#FDE8E8`,`#FEECDC`,`#FFF4B9`,`#DEF7EC`,`#D5F5F6`,`#EDEBFE`,`#FCE8F3`],[`#CDD0D8`,`#A4CAFE`,`#F8B4B4`,`#FDBA8C`,`#FAC815`,`#84E1BC`,`#7EDCE2`,`#CABFFD`,`#F8B4D9`],[`#979DAC`,`#3F83F8`,`#F05252`,`#FF5A1F`,`#D49D0F`,`#0DA471`,`#0694A2`,`#9061F9`,`#E74694`],[`#414657`,`#1A56DB`,`#C81E1E`,`#B43403`,`#9A6D15`,`#046C4E`,`#036672`,`#6C2BD9`,`#BF125D`],[`#000000`,`#233876`,`#771D1D`,`#8A2C0D`,`#634312`,`#014737`,`#014451`,`#4A1D96`,`#751A3D`]];function ca({hsv:e,onChange:t}){let n=(0,h.useCallback)(e=>{let[n,r,i]=$i(e);t(n,r,i)},[t]),r=ea(e[0],e[1],e[2]);return(0,z.jsx)(`div`,{"data-u-comp":`color-picker-presets`,className:`univer-grid univer-content-center univer-gap-2`,children:sa.map((e,t)=>(0,z.jsx)(`div`,{className:`univer-grid univer-grid-flow-col univer-items-center univer-justify-between univer-gap-2`,children:e.map((e,i)=>(0,z.jsx)(`button`,{type:`button`,className:R(`univer-box-border univer-size-5 univer-cursor-pointer univer-rounded-full univer-border univer-border-solid univer-border-transparent univer-bg-gray-300 univer-transition-shadow`,{"univer-ring-2 univer-ring-offset-2 univer-ring-offset-white dark:!univer-ring-primary-600 dark:!univer-ring-offset-gray-600":e.toUpperCase()===r.toUpperCase(),"!univer-border-gray-200":t===0&&i===0}),style:{backgroundColor:e},onClick:()=>n(e)},i))},t))})}function la({hsv:e,onChange:t,onChanged:n}){let r=(0,h.useRef)(null),i=(0,h.useRef)(null),[a,o]=(0,h.useState)(!1);(0,h.useEffect)(()=>{let t=r.current;if(!t)return;let n=t.getContext(`2d`);if(!n)return;let i=n.createLinearGradient(0,0,t.width,0);i.addColorStop(0,`hsl(${e[0]}, 0%, 50%)`),i.addColorStop(1,`hsl(${e[0]}, 100%, 50%)`),n.fillStyle=i,n.fillRect(0,0,t.width,t.height);let a=n.createLinearGradient(0,0,0,t.height);a.addColorStop(0,`rgba(255, 255, 255, 0)`),a.addColorStop(1,`rgba(0, 0, 0, 1)`),n.fillStyle=a,n.fillRect(0,0,t.width,t.height)},[e]);let s=n=>{n.stopPropagation();let i=r.current;if(!i)return;let a=i.getBoundingClientRect(),o=Math.max(0,Math.min(n.clientX-a.left,a.width)),s=Math.max(0,Math.min(n.clientY-a.top,a.height)),c=o/a.width*100,l=100-s/a.height*100;t(e[0],c,l)},c=(0,h.useCallback)(()=>{o(!1)},[e]);function l(){n==null||n(e[0],e[1],e[2])}(0,h.useEffect)(()=>{var e;return(e=i.current)==null||e.addEventListener(`mouseup`,l),window.addEventListener(`pointerup`,c),window.addEventListener(`mouseup`,c),()=>{var e;(e=i.current)==null||e.removeEventListener(`mouseup`,l),window.removeEventListener(`pointerup`,c),window.removeEventListener(`mouseup`,c)}},[e]);let u=()=>{var t,n,r,o;let s=(t=(n=i.current)==null?void 0:n.clientWidth)==null?0:t,c=(r=(o=i.current)==null?void 0:o.clientHeight)==null?0:r;return{transform:`translate(${e[1]/100*s-8}px, ${(100-e[2])/100*c-8}px)`,transition:a?`none`:`transform 0.1s ease-out`}};return(0,h.useEffect)(()=>{let e=()=>{o(!1)};return window.addEventListener(`pointerup`,e),window.addEventListener(`mouseup`,e),()=>{window.removeEventListener(`pointerup`,e),window.removeEventListener(`mouseup`,e)}},[]),(0,z.jsxs)(`div`,{"data-u-comp":`color-picker-spectrum`,ref:i,className:`univer-relative univer-overflow-hidden`,children:[(0,z.jsx)(`canvas`,{ref:r,className:`univer-size-full univer-cursor-crosshair univer-rounded`,onPointerDown:e=>{o(!0),s(e)},onPointerMove:e=>a&&s(e)}),(0,z.jsx)(`div`,{className:`univer-pointer-events-none univer-absolute univer-left-0 univer-top-0 univer-size-4 univer-rounded-full univer-border-2 univer-border-white univer-shadow-md univer-ring-2 univer-ring-white univer-will-change-transform`,style:u()})]})}function ua({hsv:e,onChange:t,onChanged:n}){let[r,i]=(0,h.useState)(!1),a=(0,h.useRef)(null),o=(0,h.useRef)(null),s=(0,h.useCallback)(n=>{var r,i;let s=a.current;if(!s)return;let c=(r=(i=o.current)==null?void 0:i.clientWidth)==null?0:r,l=s.getBoundingClientRect(),u=l.width-c;if(u<=0){t(0,e[1],e[2]);return}let d=Math.max(0,Math.min(n-l.left,u));t(Math.round(d/u*360),e[1],e[2])},[e,t]),c=(0,h.useCallback)(e=>{e.stopPropagation(),r&&s(e.clientX)},[r,s]),l=(0,h.useCallback)(()=>{i(!1),n==null||n(e[0],e[1],e[2])},[e,n]);(0,h.useEffect)(()=>(r&&(window.addEventListener(`pointermove`,c),window.addEventListener(`pointerup`,l),window.addEventListener(`mouseup`,l)),()=>{window.removeEventListener(`pointermove`,c),window.removeEventListener(`pointerup`,l),window.removeEventListener(`mouseup`,l)}),[r,c,l]);let u=()=>{var t,n,r,i;let s=Math.min(Math.max(e[0],0),360),c=(t=(n=o.current)==null?void 0:n.clientWidth)==null?0:t,l=(r=(i=a.current)==null?void 0:i.clientWidth)==null?0:r,u=l>0?c/l*100:0;return`${s/360*(100-u)}%`};return(0,z.jsx)(`div`,{"data-u-comp":`color-picker-hue-slider`,className:`univer-relative univer-w-full univer-select-none`,children:(0,z.jsx)(`div`,{ref:a,className:`univer-relative univer-h-2 univer-w-full univer-cursor-pointer univer-rounded-full univer-shadow-inner`,style:{background:`linear-gradient(to right,
120
119
  hsl(0, 100%, 50%),
121
120
  hsl(60, 100%, 50%),
122
121
  hsl(120, 100%, 50%),
123
122
  hsl(180, 100%, 50%),
124
123
  hsl(240, 100%, 50%),
125
124
  hsl(300, 100%, 50%),
126
- hsl(360, 100%, 50%))`},onPointerDown:m=>{o(!0),c(m.clientX)},children:v.jsx("div",{ref:a,className:"univer-absolute univer-top-1/2 univer-box-border univer-size-2 univer-rounded-full univer-bg-transparent univer-shadow-md univer-ring-2 univer-ring-white univer-transition-transform univer-duration-75 univer-will-change-transform",style:{left:u(),transform:"translateY(-50%)",transition:r?"none":"all 0.1s ease-out"}})})})}const Rh=y.memo(Eh),Mh=y.memo(Sh),Nh=y.memo(gh),Ph=y.memo(xh),kh=y.memo(Ch);function fc({format:e="hex",value:t,onChange:n}){if(!Ba)return null;const{locale:r}=y.useContext(Zt),[o,i]=y.useState([0,100,100]),[a,s]=y.useState(1),[c,l]=y.useState(!1),f=y.useCallback((b,h,x)=>mr(b,h,x),[]);y.useEffect(()=>{try{const b=t||(e==="hex"?"#000000":"rgba(0, 0, 0, 1)");if(e==="hex"){const[h,x,E]=Za(b);i([h,x,E]),s(1)}else if(e==="rgba"){const[h,x,E,w]=hh(b),[C,S,R]=Ya(h,x,E);i([C,S,R]),s(w)}}catch(b){console.error("Invalid value:",b)}},[t,e]);function u(b,h,x){i([b,h,x])}function m(b){s(b)}function p(b,h,x,E=a){if(e==="hex"){const[w,C,S]=f(b,h,x),R=dc(w,C,S);n==null||n(R)}else if(e==="rgba"){const[w,C,S]=f(b,h,x);n==null||n(`rgba(${w}, ${C}, ${S}, ${E})`)}}function g(){const[b,h,x]=o;if(e==="hex"){const E=Bo(b,h,x);n==null||n(E)}else if(e==="rgba"){const[E,w,C]=f(b,h,x);n==null||n(`rgba(${E}, ${w}, ${C}, ${a})`)}l(!1)}return v.jsxs("div",{"data-u-comp":"color-picker",className:"univer-cursor-default univer-space-y-2 univer-rounded-lg",onClick:b=>b.stopPropagation(),children:[v.jsx(kh,{hsv:o,onChange:(b,h,x)=>{u(b,h,x),m(1),p(b,h,x,1)}}),v.jsx("div",{className:"univer-flex univer-h-7 univer-items-center",children:v.jsx("a",{className:"univer-cursor-pointer univer-gap-2 univer-text-sm univer-text-gray-900 univer-transition-opacity hover:univer-opacity-80 dark:!univer-text-white",onClick:()=>l(!0),children:r==null?void 0:r.ColorPicker.more})}),v.jsx(Ga,{className:"!univer-w-fit !univer-p-2.5",closable:!1,maskClosable:!1,open:c,onOpenChange:l,children:v.jsxs("div",{className:"univer-grid univer-w-64 univer-gap-2",children:[v.jsx(Rh,{hsv:o,onChange:u}),v.jsxs("div",{className:"univer-flex univer-items-center univer-gap-2",children:[v.jsx("div",{className:"univer-size-6 univer-flex-shrink-0 univer-rounded-sm",style:{backgroundColor:e==="hex"?Bo(...o):ph(...o,a)}}),v.jsxs("div",{className:"univer-flex-1 univer-space-y-2",children:[v.jsx(Mh,{hsv:o,onChange:u}),e==="rgba"&&v.jsx(Nh,{hsv:o,alpha:a,onChange:m})]})]}),v.jsx(Ph,{hsv:o,alpha:a,format:e,onChange:(b,h,x,E)=>{u(b,h,x),E!==void 0&&m(E)}}),v.jsxs("footer",{className:"univer-flex univer-items-center univer-justify-end univer-gap-2",children:[v.jsx(un,{onClick:()=>l(!1),children:r==null?void 0:r.ColorPicker.cancel}),v.jsx(un,{variant:"primary",onClick:g,children:r==null?void 0:r.ColorPicker.confirm})]})]})})]})}function _h(e){const{locale:t,cancelText:n,confirmText:r,onClose:o,onConfirm:i,closable:a=!0}=e;return v.jsxs("footer",{className:"univer-flex univer-items-center univer-justify-end univer-gap-2",children:[a&&v.jsx(un,{onClick:o,children:n!=null?n:t==null?void 0:t.Confirm.cancel}),v.jsx(un,{variant:"primary",onClick:i,children:r!=null?r:t==null?void 0:t.Confirm.confirm})]})}function Ih(e){const{children:t,visible:n=!1,title:r,cancelText:o,confirmText:i,width:a,onClose:s,onConfirm:c,closable:l=!0}=e,{locale:f}=y.useContext(Zt);return v.jsx(Ga,{open:n,title:r,maskClosable:!1,footer:v.jsx(_h,{locale:f,cancelText:o,confirmText:i,onClose:s,onConfirm:c,closable:l}),onClose:s,width:a,closable:l,children:t})}const Dh=["top","right","bottom","left"],In=Math.min,yt=Math.max,Ho=Math.round,wo=Math.floor,Kt=e=>({x:e,y:e}),Ah={left:"right",right:"left",bottom:"top",top:"bottom"},Th={start:"end",end:"start"};function ca(e,t,n){return yt(e,In(t,n))}function ln(e,t){return typeof e=="function"?e(t):e}function cn(e){return e.split("-")[0]}function Cr(e){return e.split("-")[1]}function qa(e){return e==="x"?"y":"x"}function Xa(e){return e==="y"?"height":"width"}const Oh=new Set(["top","bottom"]);function Wt(e){return Oh.has(cn(e))?"y":"x"}function Qa(e){return qa(Wt(e))}function jh(e,t,n){n===void 0&&(n=!1);const r=Cr(e),o=Qa(e),i=Xa(o);let a=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(a=Vo(a)),[a,Vo(a)]}function Lh(e){const t=Vo(e);return[da(e),t,da(t)]}function da(e){return e.replace(/start|end/g,t=>Th[t])}const Qs=["left","right"],Js=["right","left"],$h=["top","bottom"],Fh=["bottom","top"];function zh(e,t,n){switch(e){case"top":case"bottom":return n?t?Js:Qs:t?Qs:Js;case"left":case"right":return t?$h:Fh;default:return[]}}function Bh(e,t,n,r){const o=Cr(e);let i=zh(cn(e),n==="start",r);return o&&(i=i.map(a=>a+"-"+o),t&&(i=i.concat(i.map(da)))),i}function Vo(e){return e.replace(/left|right|bottom|top/g,t=>Ah[t])}function Hh(e){return{top:0,right:0,bottom:0,left:0,...e}}function vc(e){return typeof e!="number"?Hh(e):{top:e,right:e,bottom:e,left:e}}function Wo(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function eu(e,t,n){let{reference:r,floating:o}=e;const i=Wt(t),a=Qa(t),s=Xa(a),c=cn(t),l=i==="y",f=r.x+r.width/2-o.width/2,u=r.y+r.height/2-o.height/2,m=r[s]/2-o[s]/2;let p;switch(c){case"top":p={x:f,y:r.y-o.height};break;case"bottom":p={x:f,y:r.y+r.height};break;case"right":p={x:r.x+r.width,y:u};break;case"left":p={x:r.x-o.width,y:u};break;default:p={x:r.x,y:r.y}}switch(Cr(t)){case"start":p[a]-=m*(n&&l?-1:1);break;case"end":p[a]+=m*(n&&l?-1:1);break}return p}const Vh=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:i=[],platform:a}=n,s=i.filter(Boolean),c=await(a.isRTL==null?void 0:a.isRTL(t));let l=await a.getElementRects({reference:e,floating:t,strategy:o}),{x:f,y:u}=eu(l,r,c),m=r,p={},g=0;for(let b=0;b<s.length;b++){const{name:h,fn:x}=s[b],{x:E,y:w,data:C,reset:S}=await x({x:f,y:u,initialPlacement:r,placement:m,strategy:o,middlewareData:p,rects:l,platform:a,elements:{reference:e,floating:t}});f=E!=null?E:f,u=w!=null?w:u,p={...p,[h]:{...p[h],...C}},S&&g<=50&&(g++,typeof S=="object"&&(S.placement&&(m=S.placement),S.rects&&(l=S.rects===!0?await a.getElementRects({reference:e,floating:t,strategy:o}):S.rects),{x:f,y:u}=eu(l,m,c)),b=-1)}return{x:f,y:u,placement:m,strategy:o,middlewareData:p}};async function Wr(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:i,rects:a,elements:s,strategy:c}=e,{boundary:l="clippingAncestors",rootBoundary:f="viewport",elementContext:u="floating",altBoundary:m=!1,padding:p=0}=ln(t,e),g=vc(p),h=s[m?u==="floating"?"reference":"floating":u],x=Wo(await i.getClippingRect({element:(n=await(i.isElement==null?void 0:i.isElement(h)))==null||n?h:h.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(s.floating)),boundary:l,rootBoundary:f,strategy:c})),E=u==="floating"?{x:r,y:o,width:a.floating.width,height:a.floating.height}:a.reference,w=await(i.getOffsetParent==null?void 0:i.getOffsetParent(s.floating)),C=await(i.isElement==null?void 0:i.isElement(w))?await(i.getScale==null?void 0:i.getScale(w))||{x:1,y:1}:{x:1,y:1},S=Wo(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:E,offsetParent:w,strategy:c}):E);return{top:(x.top-S.top+g.top)/C.y,bottom:(S.bottom-x.bottom+g.bottom)/C.y,left:(x.left-S.left+g.left)/C.x,right:(S.right-x.right+g.right)/C.x}}const Wh=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:i,platform:a,elements:s,middlewareData:c}=t,{element:l,padding:f=0}=ln(e,t)||{};if(l==null)return{};const u=vc(f),m={x:n,y:r},p=Qa(o),g=Xa(p),b=await a.getDimensions(l),h=p==="y",x=h?"top":"left",E=h?"bottom":"right",w=h?"clientHeight":"clientWidth",C=i.reference[g]+i.reference[p]-m[p]-i.floating[g],S=m[p]-i.reference[p],R=await(a.getOffsetParent==null?void 0:a.getOffsetParent(l));let L=R?R[w]:0;(!L||!await(a.isElement==null?void 0:a.isElement(R)))&&(L=s.floating[w]||i.floating[g]);const D=C/2-S/2,H=L/2-b[g]/2-1,k=In(u[x],H),T=In(u[E],H),F=k,z=L-b[g]-T,A=L/2-b[g]/2+D,_=ca(F,A,z),M=!c.arrow&&Cr(o)!=null&&A!==_&&i.reference[g]/2-(A<F?k:T)-b[g]/2<0,I=M?A<F?A-F:A-z:0;return{[p]:m[p]+I,data:{[p]:_,centerOffset:A-_-I,...M&&{alignmentOffset:I}},reset:M}}}),Kh=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:i,rects:a,initialPlacement:s,platform:c,elements:l}=t,{mainAxis:f=!0,crossAxis:u=!0,fallbackPlacements:m,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:g="none",flipAlignment:b=!0,...h}=ln(e,t);if((n=i.arrow)!=null&&n.alignmentOffset)return{};const x=cn(o),E=Wt(s),w=cn(s)===s,C=await(c.isRTL==null?void 0:c.isRTL(l.floating)),S=m||(w||!b?[Vo(s)]:Lh(s)),R=g!=="none";!m&&R&&S.push(...Bh(s,b,g,C));const L=[s,...S],D=await Wr(t,h),H=[];let k=((r=i.flip)==null?void 0:r.overflows)||[];if(f&&H.push(D[x]),u){const A=jh(o,a,C);H.push(D[A[0]],D[A[1]])}if(k=[...k,{placement:o,overflows:H}],!H.every(A=>A<=0)){var T,F;const A=(((T=i.flip)==null?void 0:T.index)||0)+1,_=L[A];if(_&&(!(u==="alignment"?E!==Wt(_):!1)||k.every(N=>Wt(N.placement)===E?N.overflows[0]>0:!0)))return{data:{index:A,overflows:k},reset:{placement:_}};let M=(F=k.filter(I=>I.overflows[0]<=0).sort((I,N)=>I.overflows[1]-N.overflows[1])[0])==null?void 0:F.placement;if(!M)switch(p){case"bestFit":{var z;const I=(z=k.filter(N=>{if(R){const P=Wt(N.placement);return P===E||P==="y"}return!0}).map(N=>[N.placement,N.overflows.filter(P=>P>0).reduce((P,j)=>P+j,0)]).sort((N,P)=>N[1]-P[1])[0])==null?void 0:z[0];I&&(M=I);break}case"initialPlacement":M=s;break}if(o!==M)return{reset:{placement:M}}}return{}}}};function tu(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function nu(e){return Dh.some(t=>e[t]>=0)}const Uh=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=ln(e,t);switch(r){case"referenceHidden":{const i=await Wr(t,{...o,elementContext:"reference"}),a=tu(i,n.reference);return{data:{referenceHiddenOffsets:a,referenceHidden:nu(a)}}}case"escaped":{const i=await Wr(t,{...o,altBoundary:!0}),a=tu(i,n.floating);return{data:{escapedOffsets:a,escaped:nu(a)}}}default:return{}}}}},mc=new Set(["left","top"]);async function Gh(e,t){const{placement:n,platform:r,elements:o}=e,i=await(r.isRTL==null?void 0:r.isRTL(o.floating)),a=cn(n),s=Cr(n),c=Wt(n)==="y",l=mc.has(a)?-1:1,f=i&&c?-1:1,u=ln(t,e);let{mainAxis:m,crossAxis:p,alignmentAxis:g}=typeof u=="number"?{mainAxis:u,crossAxis:0,alignmentAxis:null}:{mainAxis:u.mainAxis||0,crossAxis:u.crossAxis||0,alignmentAxis:u.alignmentAxis};return s&&typeof g=="number"&&(p=s==="end"?g*-1:g),c?{x:p*f,y:m*l}:{x:m*l,y:p*f}}const Yh=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:i,placement:a,middlewareData:s}=t,c=await Gh(t,e);return a===((n=s.offset)==null?void 0:n.placement)&&(r=s.arrow)!=null&&r.alignmentOffset?{}:{x:o+c.x,y:i+c.y,data:{...c,placement:a}}}}},Zh=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:i=!0,crossAxis:a=!1,limiter:s={fn:h=>{let{x,y:E}=h;return{x,y:E}}},...c}=ln(e,t),l={x:n,y:r},f=await Wr(t,c),u=Wt(cn(o)),m=qa(u);let p=l[m],g=l[u];if(i){const h=m==="y"?"top":"left",x=m==="y"?"bottom":"right",E=p+f[h],w=p-f[x];p=ca(E,p,w)}if(a){const h=u==="y"?"top":"left",x=u==="y"?"bottom":"right",E=g+f[h],w=g-f[x];g=ca(E,g,w)}const b=s.fn({...t,[m]:p,[u]:g});return{...b,data:{x:b.x-n,y:b.y-r,enabled:{[m]:i,[u]:a}}}}}},qh=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:i,middlewareData:a}=t,{offset:s=0,mainAxis:c=!0,crossAxis:l=!0}=ln(e,t),f={x:n,y:r},u=Wt(o),m=qa(u);let p=f[m],g=f[u];const b=ln(s,t),h=typeof b=="number"?{mainAxis:b,crossAxis:0}:{mainAxis:0,crossAxis:0,...b};if(c){const w=m==="y"?"height":"width",C=i.reference[m]-i.floating[w]+h.mainAxis,S=i.reference[m]+i.reference[w]-h.mainAxis;p<C?p=C:p>S&&(p=S)}if(l){var x,E;const w=m==="y"?"width":"height",C=mc.has(cn(o)),S=i.reference[u]-i.floating[w]+(C&&((x=a.offset)==null?void 0:x[u])||0)+(C?0:h.crossAxis),R=i.reference[u]+i.reference[w]+(C?0:((E=a.offset)==null?void 0:E[u])||0)-(C?h.crossAxis:0);g<S?g=S:g>R&&(g=R)}return{[m]:p,[u]:g}}}},Xh=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:o,rects:i,platform:a,elements:s}=t,{apply:c=()=>{},...l}=ln(e,t),f=await Wr(t,l),u=cn(o),m=Cr(o),p=Wt(o)==="y",{width:g,height:b}=i.floating;let h,x;u==="top"||u==="bottom"?(h=u,x=m===(await(a.isRTL==null?void 0:a.isRTL(s.floating))?"start":"end")?"left":"right"):(x=u,h=m==="end"?"top":"bottom");const E=b-f.top-f.bottom,w=g-f.left-f.right,C=In(b-f[h],E),S=In(g-f[x],w),R=!t.middlewareData.shift;let L=C,D=S;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(D=w),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(L=E),R&&!m){const k=yt(f.left,0),T=yt(f.right,0),F=yt(f.top,0),z=yt(f.bottom,0);p?D=g-2*(k!==0||T!==0?k+T:yt(f.left,f.right)):L=b-2*(F!==0||z!==0?F+z:yt(f.top,f.bottom))}await c({...t,availableWidth:D,availableHeight:L});const H=await a.getDimensions(s.floating);return g!==H.width||b!==H.height?{reset:{rects:!0}}:{}}}};function ci(){return typeof window<"u"}function Er(e){return pc(e)?(e.nodeName||"").toLowerCase():"#document"}function wt(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function qt(e){var t;return(t=(pc(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function pc(e){return ci()?e instanceof Node||e instanceof wt(e).Node:!1}function Dt(e){return ci()?e instanceof Element||e instanceof wt(e).Element:!1}function Gt(e){return ci()?e instanceof HTMLElement||e instanceof wt(e).HTMLElement:!1}function ru(e){return!ci()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof wt(e).ShadowRoot}const Qh=new Set(["inline","contents"]);function to(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=At(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!Qh.has(o)}const Jh=new Set(["table","td","th"]);function eg(e){return Jh.has(Er(e))}const tg=[":popover-open",":modal"];function di(e){return tg.some(t=>{try{return e.matches(t)}catch{return!1}})}const ng=["transform","translate","scale","rotate","perspective"],rg=["transform","translate","scale","rotate","perspective","filter"],og=["paint","layout","strict","content"];function Ja(e){const t=es(),n=Dt(e)?At(e):e;return ng.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||rg.some(r=>(n.willChange||"").includes(r))||og.some(r=>(n.contain||"").includes(r))}function ig(e){let t=Dn(e);for(;Gt(t)&&!pr(t);){if(Ja(t))return t;if(di(t))return null;t=Dn(t)}return null}function es(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const ag=new Set(["html","body","#document"]);function pr(e){return ag.has(Er(e))}function At(e){return wt(e).getComputedStyle(e)}function fi(e){return Dt(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Dn(e){if(Er(e)==="html")return e;const t=e.assignedSlot||e.parentNode||ru(e)&&e.host||qt(e);return ru(t)?t.host:t}function hc(e){const t=Dn(e);return pr(t)?e.ownerDocument?e.ownerDocument.body:e.body:Gt(t)&&to(t)?t:hc(t)}function Kr(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=hc(e),i=o===((r=e.ownerDocument)==null?void 0:r.body),a=wt(o);if(i){const s=fa(a);return t.concat(a,a.visualViewport||[],to(o)?o:[],s&&n?Kr(s):[])}return t.concat(o,Kr(o,[],n))}function fa(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function gc(e){const t=At(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=Gt(e),i=o?e.offsetWidth:n,a=o?e.offsetHeight:r,s=Ho(n)!==i||Ho(r)!==a;return s&&(n=i,r=a),{width:n,height:r,$:s}}function ts(e){return Dt(e)?e:e.contextElement}function fr(e){const t=ts(e);if(!Gt(t))return Kt(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:i}=gc(t);let a=(i?Ho(n.width):n.width)/r,s=(i?Ho(n.height):n.height)/o;return(!a||!Number.isFinite(a))&&(a=1),(!s||!Number.isFinite(s))&&(s=1),{x:a,y:s}}const sg=Kt(0);function bc(e){const t=wt(e);return!es()||!t.visualViewport?sg:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function ug(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==wt(e)?!1:t}function Kn(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),i=ts(e);let a=Kt(1);t&&(r?Dt(r)&&(a=fr(r)):a=fr(e));const s=ug(i,n,r)?bc(i):Kt(0);let c=(o.left+s.x)/a.x,l=(o.top+s.y)/a.y,f=o.width/a.x,u=o.height/a.y;if(i){const m=wt(i),p=r&&Dt(r)?wt(r):r;let g=m,b=fa(g);for(;b&&r&&p!==g;){const h=fr(b),x=b.getBoundingClientRect(),E=At(b),w=x.left+(b.clientLeft+parseFloat(E.paddingLeft))*h.x,C=x.top+(b.clientTop+parseFloat(E.paddingTop))*h.y;c*=h.x,l*=h.y,f*=h.x,u*=h.y,c+=w,l+=C,g=wt(b),b=fa(g)}}return Wo({width:f,height:u,x:c,y:l})}function vi(e,t){const n=fi(e).scrollLeft;return t?t.left+n:Kn(qt(e)).left+n}function yc(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-vi(e,n),o=n.top+t.scrollTop;return{x:r,y:o}}function lg(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const i=o==="fixed",a=qt(r),s=t?di(t.floating):!1;if(r===a||s&&i)return n;let c={scrollLeft:0,scrollTop:0},l=Kt(1);const f=Kt(0),u=Gt(r);if((u||!u&&!i)&&((Er(r)!=="body"||to(a))&&(c=fi(r)),Gt(r))){const p=Kn(r);l=fr(r),f.x=p.x+r.clientLeft,f.y=p.y+r.clientTop}const m=a&&!u&&!i?yc(a,c):Kt(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-c.scrollLeft*l.x+f.x+m.x,y:n.y*l.y-c.scrollTop*l.y+f.y+m.y}}function cg(e){return Array.from(e.getClientRects())}function dg(e){const t=qt(e),n=fi(e),r=e.ownerDocument.body,o=yt(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),i=yt(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let a=-n.scrollLeft+vi(e);const s=-n.scrollTop;return At(r).direction==="rtl"&&(a+=yt(t.clientWidth,r.clientWidth)-o),{width:o,height:i,x:a,y:s}}const ou=25;function fg(e,t){const n=wt(e),r=qt(e),o=n.visualViewport;let i=r.clientWidth,a=r.clientHeight,s=0,c=0;if(o){i=o.width,a=o.height;const f=es();(!f||f&&t==="fixed")&&(s=o.offsetLeft,c=o.offsetTop)}const l=vi(r);if(l<=0){const f=r.ownerDocument,u=f.body,m=getComputedStyle(u),p=f.compatMode==="CSS1Compat"&&parseFloat(m.marginLeft)+parseFloat(m.marginRight)||0,g=Math.abs(r.clientWidth-u.clientWidth-p);g<=ou&&(i-=g)}else l<=ou&&(i+=l);return{width:i,height:a,x:s,y:c}}const vg=new Set(["absolute","fixed"]);function mg(e,t){const n=Kn(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,i=Gt(e)?fr(e):Kt(1),a=e.clientWidth*i.x,s=e.clientHeight*i.y,c=o*i.x,l=r*i.y;return{width:a,height:s,x:c,y:l}}function iu(e,t,n){let r;if(t==="viewport")r=fg(e,n);else if(t==="document")r=dg(qt(e));else if(Dt(t))r=mg(t,n);else{const o=bc(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return Wo(r)}function xc(e,t){const n=Dn(e);return n===t||!Dt(n)||pr(n)?!1:At(n).position==="fixed"||xc(n,t)}function pg(e,t){const n=t.get(e);if(n)return n;let r=Kr(e,[],!1).filter(s=>Dt(s)&&Er(s)!=="body"),o=null;const i=At(e).position==="fixed";let a=i?Dn(e):e;for(;Dt(a)&&!pr(a);){const s=At(a),c=Ja(a);!c&&s.position==="fixed"&&(o=null),(i?!c&&!o:!c&&s.position==="static"&&!!o&&vg.has(o.position)||to(a)&&!c&&xc(e,a))?r=r.filter(f=>f!==a):o=s,a=Dn(a)}return t.set(e,r),r}function hg(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const a=[...n==="clippingAncestors"?di(t)?[]:pg(t,this._c):[].concat(n),r],s=a[0],c=a.reduce((l,f)=>{const u=iu(t,f,o);return l.top=yt(u.top,l.top),l.right=In(u.right,l.right),l.bottom=In(u.bottom,l.bottom),l.left=yt(u.left,l.left),l},iu(t,s,o));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function gg(e){const{width:t,height:n}=gc(e);return{width:t,height:n}}function bg(e,t,n){const r=Gt(t),o=qt(t),i=n==="fixed",a=Kn(e,!0,i,t);let s={scrollLeft:0,scrollTop:0};const c=Kt(0);function l(){c.x=vi(o)}if(r||!r&&!i)if((Er(t)!=="body"||to(o))&&(s=fi(t)),r){const p=Kn(t,!0,i,t);c.x=p.x+t.clientLeft,c.y=p.y+t.clientTop}else o&&l();i&&!r&&o&&l();const f=o&&!r&&!i?yc(o,s):Kt(0),u=a.left+s.scrollLeft-c.x-f.x,m=a.top+s.scrollTop-c.y-f.y;return{x:u,y:m,width:a.width,height:a.height}}function Zi(e){return At(e).position==="static"}function au(e,t){if(!Gt(e)||At(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return qt(e)===n&&(n=n.ownerDocument.body),n}function wc(e,t){const n=wt(e);if(di(e))return n;if(!Gt(e)){let o=Dn(e);for(;o&&!pr(o);){if(Dt(o)&&!Zi(o))return o;o=Dn(o)}return n}let r=au(e,t);for(;r&&eg(r)&&Zi(r);)r=au(r,t);return r&&pr(r)&&Zi(r)&&!Ja(r)?n:r||ig(e)||n}const yg=async function(e){const t=this.getOffsetParent||wc,n=this.getDimensions,r=await n(e.floating);return{reference:bg(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function xg(e){return At(e).direction==="rtl"}const wg={convertOffsetParentRelativeRectToViewportRelativeRect:lg,getDocumentElement:qt,getClippingRect:hg,getOffsetParent:wc,getElementRects:yg,getClientRects:cg,getDimensions:gg,getScale:fr,isElement:Dt,isRTL:xg};function Cc(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Cg(e,t){let n=null,r;const o=qt(e);function i(){var s;clearTimeout(r),(s=n)==null||s.disconnect(),n=null}function a(s,c){s===void 0&&(s=!1),c===void 0&&(c=1),i();const l=e.getBoundingClientRect(),{left:f,top:u,width:m,height:p}=l;if(s||t(),!m||!p)return;const g=wo(u),b=wo(o.clientWidth-(f+m)),h=wo(o.clientHeight-(u+p)),x=wo(f),w={rootMargin:-g+"px "+-b+"px "+-h+"px "+-x+"px",threshold:yt(0,In(1,c))||1};let C=!0;function S(R){const L=R[0].intersectionRatio;if(L!==c){if(!C)return a();L?a(!1,L):r=setTimeout(()=>{a(!1,1e-7)},1e3)}L===1&&!Cc(l,e.getBoundingClientRect())&&a(),C=!1}try{n=new IntersectionObserver(S,{...w,root:o.ownerDocument})}catch{n=new IntersectionObserver(S,w)}n.observe(e)}return a(!0),i}function Eg(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:i=!0,elementResize:a=typeof ResizeObserver=="function",layoutShift:s=typeof IntersectionObserver=="function",animationFrame:c=!1}=r,l=ts(e),f=o||i?[...l?Kr(l):[],...Kr(t)]:[];f.forEach(x=>{o&&x.addEventListener("scroll",n,{passive:!0}),i&&x.addEventListener("resize",n)});const u=l&&s?Cg(l,n):null;let m=-1,p=null;a&&(p=new ResizeObserver(x=>{let[E]=x;E&&E.target===l&&p&&(p.unobserve(t),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var w;(w=p)==null||w.observe(t)})),n()}),l&&!c&&p.observe(l),p.observe(t));let g,b=c?Kn(e):null;c&&h();function h(){const x=Kn(e);b&&!Cc(b,x)&&n(),b=x,g=requestAnimationFrame(h)}return n(),()=>{var x;f.forEach(E=>{o&&E.removeEventListener("scroll",n),i&&E.removeEventListener("resize",n)}),u==null||u(),(x=p)==null||x.disconnect(),p=null,c&&cancelAnimationFrame(g)}}const Sg=Yh,Rg=Zh,Mg=Kh,Ng=Xh,Pg=Uh,su=Wh,kg=qh,_g=(e,t,n)=>{const r=new Map,o={platform:wg,...n},i={...o.platform,_c:r};return Vh(e,t,{...o,platform:i})};var Ig=typeof document<"u",Dg=function(){},Do=Ig?y.useLayoutEffect:Dg;function Ko(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!Ko(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const i=o[r];if(!(i==="_owner"&&e.$$typeof)&&!Ko(e[i],t[i]))return!1}return!0}return e!==e&&t!==t}function Ec(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function uu(e,t){const n=Ec(e);return Math.round(t*n)/n}function qi(e){const t=d.useRef(e);return Do(()=>{t.current=e}),t}function Ag(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:i,floating:a}={},transform:s=!0,whileElementsMounted:c,open:l}=e,[f,u]=d.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[m,p]=d.useState(r);Ko(m,r)||p(r);const[g,b]=d.useState(null),[h,x]=d.useState(null),E=d.useCallback(N=>{N!==R.current&&(R.current=N,b(N))},[]),w=d.useCallback(N=>{N!==L.current&&(L.current=N,x(N))},[]),C=i||g,S=a||h,R=d.useRef(null),L=d.useRef(null),D=d.useRef(f),H=c!=null,k=qi(c),T=qi(o),F=qi(l),z=d.useCallback(()=>{if(!R.current||!L.current)return;const N={placement:t,strategy:n,middleware:m};T.current&&(N.platform=T.current),_g(R.current,L.current,N).then(P=>{const j={...P,isPositioned:F.current!==!1};A.current&&!Ko(D.current,j)&&(D.current=j,Qu.flushSync(()=>{u(j)}))})},[m,t,n,T,F]);Do(()=>{l===!1&&D.current.isPositioned&&(D.current.isPositioned=!1,u(N=>({...N,isPositioned:!1})))},[l]);const A=d.useRef(!1);Do(()=>(A.current=!0,()=>{A.current=!1}),[]),Do(()=>{if(C&&(R.current=C),S&&(L.current=S),C&&S){if(k.current)return k.current(C,S,z);z()}},[C,S,z,k,H]);const _=d.useMemo(()=>({reference:R,floating:L,setReference:E,setFloating:w}),[E,w]),M=d.useMemo(()=>({reference:C,floating:S}),[C,S]),I=d.useMemo(()=>{const N={position:n,left:0,top:0};if(!M.floating)return N;const P=uu(M.floating,f.x),j=uu(M.floating,f.y);return s?{...N,transform:"translate("+P+"px, "+j+"px)",...Ec(M.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:P,top:j}},[n,s,M.floating,f.x,f.y]);return d.useMemo(()=>({...f,update:z,refs:_,elements:M,floatingStyles:I}),[f,z,_,M,I])}const Tg=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:o}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?su({element:r.current,padding:o}).fn(n):{}:r?su({element:r,padding:o}).fn(n):{}}}},Og=(e,t)=>({...Sg(e),options:[e,t]}),jg=(e,t)=>({...Rg(e),options:[e,t]}),Lg=(e,t)=>({...kg(e),options:[e,t]}),$g=(e,t)=>({...Mg(e),options:[e,t]}),Fg=(e,t)=>({...Ng(e),options:[e,t]}),zg=(e,t)=>({...Pg(e),options:[e,t]}),Bg=(e,t)=>({...Tg(e),options:[e,t]});var Hg="Arrow",Sc=d.forwardRef((e,t)=>{const{children:n,width:r=10,height:o=5,...i}=e;return v.jsx($e.svg,{...i,ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:v.jsx("polygon",{points:"0,0 30,0 15,10"})})});Sc.displayName=Hg;var Vg=Sc;function Wg(e){const[t,n]=d.useState(void 0);return _n(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const i=o[0];let a,s;if("borderBoxSize"in i){const c=i.borderBoxSize,l=Array.isArray(c)?c[0]:c;a=l.inlineSize,s=l.blockSize}else a=e.offsetWidth,s=e.offsetHeight;n({width:a,height:s})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var ns="Popper",[Rc,Sr]=An(ns),[Kg,Mc]=Rc(ns),Nc=e=>{const{__scopePopper:t,children:n}=e,[r,o]=d.useState(null);return v.jsx(Kg,{scope:t,anchor:r,onAnchorChange:o,children:n})};Nc.displayName=ns;var Pc="PopperAnchor",kc=d.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,i=Mc(Pc,n),a=d.useRef(null),s=Ue(t,a),c=d.useRef(null);return d.useEffect(()=>{const l=c.current;c.current=(r==null?void 0:r.current)||a.current,l!==c.current&&i.onAnchorChange(c.current)}),r?null:v.jsx($e.div,{...o,ref:s})});kc.displayName=Pc;var rs="PopperContent",[Ug,Gg]=Rc(rs),_c=d.forwardRef((e,t)=>{var oe,G,q,ne,ae,ue,he,xe;const{__scopePopper:n,side:r="bottom",sideOffset:o=0,align:i="center",alignOffset:a=0,arrowPadding:s=0,avoidCollisions:c=!0,collisionBoundary:l=[],collisionPadding:f=0,sticky:u="partial",hideWhenDetached:m=!1,updatePositionStrategy:p="optimized",onPlaced:g,...b}=e,h=Mc(rs,n),[x,E]=d.useState(null),w=Ue(t,ge=>E(ge)),[C,S]=d.useState(null),R=Wg(C),L=(oe=R==null?void 0:R.width)!=null?oe:0,D=(G=R==null?void 0:R.height)!=null?G:0,H=r+(i!=="center"?"-"+i:""),k=typeof f=="number"?f:{top:0,right:0,bottom:0,left:0,...f},T=Array.isArray(l)?l:[l],F=T.length>0,z={padding:k,boundary:T.filter(Zg),altBoundary:F},{refs:A,floatingStyles:_,placement:M,isPositioned:I,middlewareData:N}=Ag({strategy:"fixed",placement:H,whileElementsMounted:(...ge)=>Eg(...ge,{animationFrame:p==="always"}),elements:{reference:h.anchor},middleware:[Og({mainAxis:o+D,alignmentAxis:a}),c&&jg({mainAxis:!0,crossAxis:!1,limiter:u==="partial"?Lg():void 0,...z}),c&&$g({...z}),Fg({...z,apply:({elements:ge,rects:Ne,availableWidth:ke,availableHeight:be})=>{const{width:ye,height:Le}=Ne.reference,le=ge.floating.style;le.setProperty("--radix-popper-available-width",`${ke}px`),le.setProperty("--radix-popper-available-height",`${be}px`),le.setProperty("--radix-popper-anchor-width",`${ye}px`),le.setProperty("--radix-popper-anchor-height",`${Le}px`)}}),C&&Bg({element:C,padding:s}),qg({arrowWidth:L,arrowHeight:D}),m&&zg({strategy:"referenceHidden",...z})]}),[P,j]=Ac(M),B=Ut(g);_n(()=>{I&&(B==null||B())},[I,B]);const K=(q=N.arrow)==null?void 0:q.x,$=(ne=N.arrow)==null?void 0:ne.y,O=((ae=N.arrow)==null?void 0:ae.centerOffset)!==0,[V,U]=d.useState();return _n(()=>{x&&U(window.getComputedStyle(x).zIndex)},[x]),v.jsx("div",{ref:A.setFloating,"data-radix-popper-content-wrapper":"",style:{..._,transform:I?_.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:V,"--radix-popper-transform-origin":[(ue=N.transformOrigin)==null?void 0:ue.x,(he=N.transformOrigin)==null?void 0:he.y].join(" "),...((xe=N.hide)==null?void 0:xe.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:v.jsx(Ug,{scope:n,placedSide:P,onArrowChange:S,arrowX:K,arrowY:$,shouldHideArrow:O,children:v.jsx($e.div,{"data-side":P,"data-align":j,...b,ref:w,style:{...b.style,animation:I?void 0:"none"}})})})});_c.displayName=rs;var Ic="PopperArrow",Yg={top:"bottom",right:"left",bottom:"top",left:"right"},Dc=d.forwardRef(function(t,n){const{__scopePopper:r,...o}=t,i=Gg(Ic,r),a=Yg[i.placedSide];return v.jsx("span",{ref:i.onArrowChange,style:{position:"absolute",left:i.arrowX,top:i.arrowY,[a]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[i.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[i.placedSide],visibility:i.shouldHideArrow?"hidden":void 0},children:v.jsx(Vg,{...o,ref:n,style:{...o.style,display:"block"}})})});Dc.displayName=Ic;function Zg(e){return e!==null}var qg=e=>({name:"transformOrigin",options:e,fn(t){var h,x,E,w,C;const{placement:n,rects:r,middlewareData:o}=t,a=((h=o.arrow)==null?void 0:h.centerOffset)!==0,s=a?0:e.arrowWidth,c=a?0:e.arrowHeight,[l,f]=Ac(n),u={start:"0%",center:"50%",end:"100%"}[f],m=((E=(x=o.arrow)==null?void 0:x.x)!=null?E:0)+s/2,p=((C=(w=o.arrow)==null?void 0:w.y)!=null?C:0)+c/2;let g="",b="";return l==="bottom"?(g=a?u:`${m}px`,b=`${-c}px`):l==="top"?(g=a?u:`${m}px`,b=`${r.floating.height+c}px`):l==="right"?(g=`${-c}px`,b=a?u:`${p}px`):l==="left"&&(g=`${r.floating.width+c}px`,b=a?u:`${p}px`),{data:{x:g,y:b}}}});function Ac(e){const[t,n="center"]=e.split("-");return[t,n]}var mi=Nc,pi=kc,os=_c,is=Dc,hi="Popover",[Tc]=An(hi,[Sr]),no=Sr(),[Xg,Tn]=Tc(hi),Oc=e=>{const{__scopePopover:t,children:n,open:r,defaultOpen:o,onOpenChange:i,modal:a=!1}=e,s=no(t),c=d.useRef(null),[l,f]=d.useState(!1),[u,m]=wr({prop:r,defaultProp:o!=null?o:!1,onChange:i,caller:hi});return v.jsx(mi,{...s,children:v.jsx(Xg,{scope:t,contentId:on(),triggerRef:c,open:u,onOpenChange:m,onOpenToggle:d.useCallback(()=>m(p=>!p),[m]),hasCustomAnchor:l,onCustomAnchorAdd:d.useCallback(()=>f(!0),[]),onCustomAnchorRemove:d.useCallback(()=>f(!1),[]),modal:a,children:n})})};Oc.displayName=hi;var jc="PopoverAnchor",Qg=d.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,o=Tn(jc,n),i=no(n),{onCustomAnchorAdd:a,onCustomAnchorRemove:s}=o;return d.useEffect(()=>(a(),()=>s()),[a,s]),v.jsx(pi,{...i,...r,ref:t})});Qg.displayName=jc;var Lc="PopoverTrigger",$c=d.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,o=Tn(Lc,n),i=no(n),a=Ue(t,o.triggerRef),s=v.jsx($e.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":Vc(o.open),...r,ref:a,onClick:ie(e.onClick,o.onOpenToggle)});return o.hasCustomAnchor?s:v.jsx(pi,{asChild:!0,...i,children:s})});$c.displayName=Lc;var as="PopoverPortal",[Jg,e0]=Tc(as,{forceMount:void 0}),Fc=e=>{const{__scopePopover:t,forceMount:n,children:r,container:o}=e,i=Tn(as,t);return v.jsx(Jg,{scope:t,forceMount:n,children:v.jsx(Nt,{present:n||i.open,children:v.jsx(eo,{asChild:!0,container:o,children:r})})})};Fc.displayName=as;var hr="PopoverContent",zc=d.forwardRef((e,t)=>{const n=e0(hr,e.__scopePopover),{forceMount:r=n.forceMount,...o}=e,i=Tn(hr,e.__scopePopover);return v.jsx(Nt,{present:r||i.open,children:i.modal?v.jsx(n0,{...o,ref:t}):v.jsx(r0,{...o,ref:t})})});zc.displayName=hr;var t0=vr("PopoverContent.RemoveScroll"),n0=d.forwardRef((e,t)=>{const n=Tn(hr,e.__scopePopover),r=d.useRef(null),o=Ue(t,r),i=d.useRef(!1);return d.useEffect(()=>{const a=r.current;if(a)return Va(a)},[]),v.jsx(ui,{as:t0,allowPinchZoom:!0,children:v.jsx(Bc,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:ie(e.onCloseAutoFocus,a=>{var s;a.preventDefault(),i.current||(s=n.triggerRef.current)==null||s.focus()}),onPointerDownOutside:ie(e.onPointerDownOutside,a=>{const s=a.detail.originalEvent,c=s.button===0&&s.ctrlKey===!0,l=s.button===2||c;i.current=l},{checkForDefaultPrevented:!1}),onFocusOutside:ie(e.onFocusOutside,a=>a.preventDefault(),{checkForDefaultPrevented:!1})})})}),r0=d.forwardRef((e,t)=>{const n=Tn(hr,e.__scopePopover),r=d.useRef(!1),o=d.useRef(!1);return v.jsx(Bc,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:i=>{var a,s;(a=e.onCloseAutoFocus)==null||a.call(e,i),i.defaultPrevented||(r.current||(s=n.triggerRef.current)==null||s.focus(),i.preventDefault()),r.current=!1,o.current=!1},onInteractOutside:i=>{var c,l;(c=e.onInteractOutside)==null||c.call(e,i),i.defaultPrevented||(r.current=!0,i.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const a=i.target;(l=n.triggerRef.current)!=null&&l.contains(a)&&i.preventDefault(),i.detail.originalEvent.type==="focusin"&&o.current&&i.preventDefault()}})}),Bc=d.forwardRef((e,t)=>{const{__scopePopover:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:i,disableOutsidePointerEvents:a,onEscapeKeyDown:s,onPointerDownOutside:c,onFocusOutside:l,onInteractOutside:f,...u}=e,m=Tn(hr,n),p=no(n);return Ha(),v.jsx(ai,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:i,children:v.jsx(Jr,{asChild:!0,disableOutsidePointerEvents:a,onInteractOutside:f,onEscapeKeyDown:s,onPointerDownOutside:c,onFocusOutside:l,onDismiss:()=>m.onOpenChange(!1),children:v.jsx(os,{"data-state":Vc(m.open),role:"dialog",id:m.contentId,...p,...u,ref:t,style:{...u.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),Hc="PopoverClose",o0=d.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,o=Tn(Hc,n);return v.jsx($e.button,{type:"button",...r,ref:t,onClick:ie(e.onClick,()=>o.onOpenChange(!1))})});o0.displayName=Hc;var i0="PopoverArrow",a0=d.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,o=no(n);return v.jsx(is,{...o,...r,ref:t})});a0.displayName=i0;function Vc(e){return e?"open":"closed"}var s0=Oc,u0=$c,l0=Fc,c0=zc;function d0({...e}){return v.jsx(s0,{"data-slot":"popover",...e})}function f0({...e}){return v.jsx(u0,{"data-slot":"popover-trigger",...e})}function v0({className:e,align:t="center",sideOffset:n=4,...r}){return v.jsx(l0,{children:v.jsx(c0,{"data-slot":"popover-content",align:t,sideOffset:n,className:W(`
127
- univer-outline-hidden
128
- data-[state=open]:univer-animate-in data-[state=open]:univer-fade-in-0
129
- data-[state=open]:univer-zoom-in-95
130
- data-[state=closed]:univer-animate-out data-[state=closed]:univer-fade-out-0
131
- data-[state=closed]:univer-zoom-out-95
132
- data-[side=bottom]:univer-slide-in-from-top-2
133
- data-[side=left]:univer-slide-in-from-right-2
134
- data-[side=right]:univer-slide-in-from-left-2
135
- data-[side=top]:univer-slide-in-from-bottom-2
136
- univer-z-[1080] univer-max-h-[--radix-popper-available-height] univer-overflow-y-auto
137
- univer-rounded-md univer-bg-white univer-text-gray-900 univer-shadow-md
138
- dark:!univer-bg-gray-900 dark:!univer-text-white
139
- dark:focus-visible:!univer-border-gray-600
140
- `,ct,kn,e),...r})})}function ss(e){const{children:t,overlay:n,disabled:r,open:o,onOpenChange:i,...a}=e,[s,c]=y.useState(!1),l=o!==void 0,f=l?o:s;function u(m){r||(l||c(m),i==null||i(m))}return v.jsxs(d0,{open:f,onOpenChange:u,children:[v.jsx(f0,{asChild:!0,children:t}),v.jsx(v0,{...a,children:n})]})}function m0(e){const{value:t,onValueChange:n,className:r}=e,[o,i]=y.useState(!1);function a(s){n==null||n(s),i(!1)}return v.jsx(ss,{align:"start",overlay:v.jsx("div",{className:"univer-p-2",children:v.jsx(Fo,{value:t,onValueChange:a})}),open:o,onOpenChange:i,children:v.jsxs("button",{className:W("univer-flex univer-h-8 univer-items-center univer-justify-between univer-gap-2 univer-rounded-md univer-bg-transparent univer-px-2 univer-text-sm univer-text-gray-800 univer-transition-all hover:univer-border-primary-600 dark:!univer-text-white",ct,r),type:"button",children:[$o(t).format("YYYY-MM-DD"),v.jsx(La,{className:"univer-text-gray-600 dark:!univer-text-gray-400"})]})})}function p0(e){const{value:t=[new Date,new Date],onValueChange:n,className:r}=e,[o,i]=y.useState(!1);function a(s){let[c,l]=s;c>l&&([c,l]=[l,c]),n==null||n([c,l]),i(!1)}return v.jsx(ss,{align:"start",overlay:v.jsxs("div",{className:"univer-grid univer-grid-cols-2 univer-gap-2 univer-p-2",children:[v.jsx(Fo,{value:t[0],max:t[1],onValueChange:s=>{a([s,t[1]])}}),v.jsx(Fo,{value:t[1],min:t[0],onValueChange:s=>{a([t[0],s])}})]}),open:o,onOpenChange:i,children:v.jsxs("button",{className:W("univer-flex univer-h-8 univer-items-center univer-justify-between univer-gap-2 univer-rounded-md univer-bg-transparent univer-px-2 univer-text-sm univer-text-gray-800 univer-transition-all hover:univer-border-primary-600 dark:!univer-text-white",ct,r),type:"button",children:[v.jsxs("span",{className:"univer-flex univer-gap-1",children:[v.jsx("span",{children:$o(t[0]).format("YYYY-MM-DD")}),v.jsx("span",{children:"-"}),v.jsx("span",{children:$o(t[1]).format("YYYY-MM-DD")})]}),v.jsx(La,{className:"univer-text-gray-600 dark:!univer-text-gray-400"})]})})}function h0(e,t,n){if(t===n||t<0||n<0||t>=e.length||n>=e.length)return e;const r=[...e],[o]=r.splice(t,1);return r.splice(n,0,o),r}function g0(e){const{list:t,onListChange:n,idKey:r,itemRender:o,className:i,style:a,draggableHandle:s,rowHeight:c,margin:l=[0,0],onDragStart:f,onDragStop:u,...m}=e,[p,g]=y.useState(t),b=y.useRef(t),[h,x]=y.useState(null),[E,w]=y.useState(null),[C,S]=y.useState(null),[R,L]=y.useState(null),[D,H]=y.useState(!1),k=y.useRef(null),T=y.useRef({x:0,y:0}),F=y.useRef({width:0,height:0}),z=y.useRef(null),A=y.useRef(null),_=y.useRef(-1);y.useEffect(()=>{h||(g(t),b.current=t)},[h,t]),y.useEffect(()=>{H(typeof document<"u")},[]),y.useEffect(()=>{if(!h)return;const P=B=>{const K=A.current;if(!K||k.current!==B.pointerId)return;L({x:B.clientX-T.current.x,y:B.clientY-T.current.y});const $=document.elementFromPoint(B.clientX,B.clientY),O=$==null?void 0:$.closest("[data-draggable-list-item-id]"),V=O==null?void 0:O.dataset.draggableListItemId;!V||V===K||(w(V),g(U=>{const oe=U.findIndex(ne=>I(ne)===K),G=U.findIndex(ne=>I(ne)===V);if(oe<0||G<0||oe===G)return U;const q=h0(U,oe,G);return b.current=q,q}))},j=B=>{if(k.current!==B.pointerId)return;const K=A.current,$=_.current,O=b.current;if(K){const V=O.findIndex(U=>I(U)===K);u==null||u(void 0,{y:$},{y:V}),$>=0&&n([...O])}k.current=null,z.current=null,A.current=null,_.current=-1,w(null),S(null),L(null),x(null)};return window.addEventListener("pointermove",P),window.addEventListener("pointerup",j),window.addEventListener("pointercancel",j),()=>{window.removeEventListener("pointermove",P),window.removeEventListener("pointerup",j),window.removeEventListener("pointercancel",j)}},[h,u,n]);const M=y.useMemo(()=>{const[P,j]=l;return{rowGap:`${j}px`,paddingLeft:P?`${P}px`:void 0,paddingRight:P?`${P}px`:void 0,...a}},[l,a]),I=P=>String(P[r]),N=h?p.find(P=>I(P)===h):null;return v.jsxs(v.Fragment,{children:[v.jsx("div",{...m,className:W("univer-flex univer-flex-col",h&&"univer-cursor-grabbing univer-select-none",i),style:M,children:p.map((P,j)=>{const B=I(P),K=h===B,$=E===B&&!K;return v.jsxs("div",{"data-draggable-list-item-id":B,className:W("univer-relative univer-transition-all univer-duration-150",K&&"univer-opacity-0",$&&`
125
+ hsl(360, 100%, 50%))`},onPointerDown:e=>{i(!0),s(e.clientX)},children:(0,z.jsx)(`div`,{ref:o,className:`univer-absolute univer-top-1/2 univer-box-border univer-size-2 univer-rounded-full univer-bg-transparent univer-shadow-md univer-ring-2 univer-ring-white univer-transition-transform univer-duration-75 univer-will-change-transform`,style:{left:u(),transform:`translateY(-50%)`,transition:r?`none`:`all 0.1s ease-out`}})})})}const da=(0,h.memo)(la),fa=(0,h.memo)(ua),pa=(0,h.memo)(ra),ma=(0,h.memo)(oa),ha=(0,h.memo)(ca);function ga({format:e=`hex`,value:t,onChange:n}){if(!$e)return null;let{locale:r}=(0,h.useContext)(et),[i,a]=(0,h.useState)([0,100,100]),[o,s]=(0,h.useState)(1),[c,l]=(0,h.useState)(!1),u=(0,h.useCallback)((e,t,n)=>Xi(e,t,n),[]);(0,h.useEffect)(()=>{try{let n=t||(e===`hex`?`#000000`:`rgba(0, 0, 0, 1)`);if(e===`hex`){let[e,t,r]=$i(n);a([e,t,r]),s(1)}else if(e===`rgba`){let[e,t,r,i]=na(n),[o,c,l]=Qi(e,t,r);a([o,c,l]),s(i)}}catch(e){console.error(`Invalid value:`,e)}},[t,e]);function d(e,t,n){a([e,t,n])}function f(e){s(e)}function p(t,r,i,a=o){if(e===`hex`){let[e,a,o]=u(t,r,i),s=Zi(e,a,o);n==null||n(s)}else if(e===`rgba`){let[e,o,s]=u(t,r,i);n==null||n(`rgba(${e}, ${o}, ${s}, ${a})`)}}function m(){let[t,r,a]=i;if(e===`hex`){let e=ea(t,r,a);n==null||n(e)}else if(e===`rgba`){let[e,i,s]=u(t,r,a);n==null||n(`rgba(${e}, ${i}, ${s}, ${o})`)}l(!1)}return(0,z.jsxs)(`div`,{"data-u-comp":`color-picker`,className:`univer-cursor-default univer-space-y-2 univer-rounded-lg`,onClick:e=>e.stopPropagation(),children:[(0,z.jsx)(ha,{hsv:i,onChange:(e,t,n)=>{d(e,t,n),f(1),p(e,t,n,1)}}),(0,z.jsx)(`div`,{className:`univer-flex univer-h-7 univer-items-center`,children:(0,z.jsx)(`a`,{className:`univer-cursor-pointer univer-gap-2 univer-text-sm univer-text-gray-900 univer-transition-opacity hover:univer-opacity-80 dark:!univer-text-white`,onClick:()=>l(!0),children:r==null?void 0:r.ColorPicker.more})}),(0,z.jsx)(Yi,{className:`!univer-w-fit !univer-p-2.5`,closable:!1,maskClosable:!1,open:c,onOpenChange:l,children:(0,z.jsxs)(`div`,{className:`univer-grid univer-w-64 univer-gap-2`,children:[(0,z.jsx)(da,{hsv:i,onChange:d}),(0,z.jsxs)(`div`,{className:`univer-flex univer-items-center univer-gap-2`,children:[(0,z.jsx)(`div`,{className:`univer-size-6 univer-flex-shrink-0 univer-rounded-sm`,style:{backgroundColor:e===`hex`?ea(...i):ta(...i,o)}}),(0,z.jsxs)(`div`,{className:`univer-flex-1 univer-space-y-2`,children:[(0,z.jsx)(fa,{hsv:i,onChange:d}),e===`rgba`&&(0,z.jsx)(pa,{hsv:i,alpha:o,onChange:f})]})]}),(0,z.jsx)(ma,{hsv:i,alpha:o,format:e,onChange:(e,t,n,r)=>{d(e,t,n),r!==void 0&&f(r)}}),(0,z.jsxs)(`footer`,{className:`univer-flex univer-items-center univer-justify-end univer-gap-2`,children:[(0,z.jsx)(Ze,{onClick:()=>l(!1),children:r==null?void 0:r.ColorPicker.cancel}),(0,z.jsx)(Ze,{variant:`primary`,onClick:m,children:r==null?void 0:r.ColorPicker.confirm})]})]})})]})}function _a(e){let{locale:t,cancelText:n,confirmText:r,onClose:i,onConfirm:a,closable:o=!0}=e;return(0,z.jsxs)(`footer`,{className:`univer-flex univer-items-center univer-justify-end univer-gap-2`,children:[o&&(0,z.jsx)(Ze,{onClick:i,children:n==null?t==null?void 0:t.Confirm.cancel:n}),(0,z.jsx)(Ze,{variant:`primary`,onClick:a,children:r==null?t==null?void 0:t.Confirm.confirm:r})]})}function va(e){let{children:t,visible:n=!1,title:r,cancelText:i,confirmText:a,width:o,onClose:s,onConfirm:c,closable:l=!0}=e,{locale:u}=(0,h.useContext)(et);return(0,z.jsx)(Yi,{open:n,title:r,maskClosable:!1,footer:(0,z.jsx)(_a,{locale:u,cancelText:i,confirmText:a,onClose:s,onConfirm:c,closable:l}),onClose:s,width:o,closable:l,children:t})}const ya=[`top`,`right`,`bottom`,`left`],ba=Math.min,xa=Math.max,Sa=Math.round,Ca=Math.floor,wa=e=>({x:e,y:e}),Ta={left:`right`,right:`left`,bottom:`top`,top:`bottom`},Ea={start:`end`,end:`start`};function Da(e,t,n){return xa(e,ba(t,n))}function Oa(e,t){return typeof e==`function`?e(t):e}function ka(e){return e.split(`-`)[0]}function Aa(e){return e.split(`-`)[1]}function ja(e){return e===`x`?`y`:`x`}function Ma(e){return e===`y`?`height`:`width`}const Na=new Set([`top`,`bottom`]);function Pa(e){return Na.has(ka(e))?`y`:`x`}function Fa(e){return ja(Pa(e))}function Ia(e,t,n){n===void 0&&(n=!1);let r=Aa(e),i=Fa(e),a=Ma(i),o=i===`x`?r===(n?`end`:`start`)?`right`:`left`:r===`start`?`bottom`:`top`;return t.reference[a]>t.floating[a]&&(o=Ga(o)),[o,Ga(o)]}function La(e){let t=Ga(e);return[Ra(e),t,Ra(t)]}function Ra(e){return e.replace(/start|end/g,e=>Ea[e])}const za=[`left`,`right`],Ba=[`right`,`left`],Va=[`top`,`bottom`],Ha=[`bottom`,`top`];function Ua(e,t,n){switch(e){case`top`:case`bottom`:return n?t?Ba:za:t?za:Ba;case`left`:case`right`:return t?Va:Ha;default:return[]}}function Wa(e,t,n,r){let i=Aa(e),a=Ua(ka(e),n===`start`,r);return i&&(a=a.map(e=>e+`-`+i),t&&(a=a.concat(a.map(Ra)))),a}function Ga(e){return e.replace(/left|right|bottom|top/g,e=>Ta[e])}function Ka(e){return{top:0,right:0,bottom:0,left:0,...e}}function qa(e){return typeof e==`number`?{top:e,right:e,bottom:e,left:e}:Ka(e)}function Ja(e){let{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function Ya(e,t,n){let{reference:r,floating:i}=e,a=Pa(t),o=Fa(t),s=Ma(o),c=ka(t),l=a===`y`,u=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,f=r[s]/2-i[s]/2,p;switch(c){case`top`:p={x:u,y:r.y-i.height};break;case`bottom`:p={x:u,y:r.y+r.height};break;case`right`:p={x:r.x+r.width,y:d};break;case`left`:p={x:r.x-i.width,y:d};break;default:p={x:r.x,y:r.y}}switch(Aa(t)){case`start`:p[o]-=f*(n&&l?-1:1);break;case`end`:p[o]+=f*(n&&l?-1:1);break}return p}const Xa=async(e,t,n)=>{let{placement:r=`bottom`,strategy:i=`absolute`,middleware:a=[],platform:o}=n,s=a.filter(Boolean),c=await(o.isRTL==null?void 0:o.isRTL(t)),l=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=Ya(l,r,c),f=r,p={},m=0;for(let n=0;n<s.length;n++){let{name:a,fn:h}=s[n],{x:g,y:_,data:v,reset:y}=await h({x:u,y:d,initialPlacement:r,placement:f,strategy:i,middlewareData:p,rects:l,platform:o,elements:{reference:e,floating:t}});u=g==null?u:g,d=_==null?d:_,p={...p,[a]:{...p[a],...v}},y&&m<=50&&(m++,typeof y==`object`&&(y.placement&&(f=y.placement),y.rects&&(l=y.rects===!0?await o.getElementRects({reference:e,floating:t,strategy:i}):y.rects),{x:u,y:d}=Ya(l,f,c)),n=-1)}return{x:u,y:d,placement:f,strategy:i,middlewareData:p}};async function Za(e,t){var n;t===void 0&&(t={});let{x:r,y:i,platform:a,rects:o,elements:s,strategy:c}=e,{boundary:l=`clippingAncestors`,rootBoundary:u=`viewport`,elementContext:d=`floating`,altBoundary:f=!1,padding:p=0}=Oa(t,e),m=qa(p),h=s[f?d===`floating`?`reference`:`floating`:d],g=Ja(await a.getClippingRect({element:(n=await(a.isElement==null?void 0:a.isElement(h)))==null||n?h:h.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(s.floating)),boundary:l,rootBoundary:u,strategy:c})),_=d===`floating`?{x:r,y:i,width:o.floating.width,height:o.floating.height}:o.reference,v=await(a.getOffsetParent==null?void 0:a.getOffsetParent(s.floating)),y=await(a.isElement==null?void 0:a.isElement(v))&&await(a.getScale==null?void 0:a.getScale(v))||{x:1,y:1},b=Ja(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:_,offsetParent:v,strategy:c}):_);return{top:(g.top-b.top+m.top)/y.y,bottom:(b.bottom-g.bottom+m.bottom)/y.y,left:(g.left-b.left+m.left)/y.x,right:(b.right-g.right+m.right)/y.x}}const Qa=e=>({name:`arrow`,options:e,async fn(t){let{x:n,y:r,placement:i,rects:a,platform:o,elements:s,middlewareData:c}=t,{element:l,padding:u=0}=Oa(e,t)||{};if(l==null)return{};let d=qa(u),f={x:n,y:r},p=Fa(i),m=Ma(p),h=await o.getDimensions(l),g=p===`y`,_=g?`top`:`left`,v=g?`bottom`:`right`,y=g?`clientHeight`:`clientWidth`,b=a.reference[m]+a.reference[p]-f[p]-a.floating[m],x=f[p]-a.reference[p],S=await(o.getOffsetParent==null?void 0:o.getOffsetParent(l)),C=S?S[y]:0;(!C||!await(o.isElement==null?void 0:o.isElement(S)))&&(C=s.floating[y]||a.floating[m]);let w=b/2-x/2,T=C/2-h[m]/2-1,E=ba(d[_],T),D=ba(d[v],T),O=E,k=C-h[m]-D,A=C/2-h[m]/2+w,j=Da(O,A,k),ee=!c.arrow&&Aa(i)!=null&&A!==j&&a.reference[m]/2-(A<O?E:D)-h[m]/2<0,M=ee?A<O?A-O:A-k:0;return{[p]:f[p]+M,data:{[p]:j,centerOffset:A-j-M,...ee&&{alignmentOffset:M}},reset:ee}}}),$a=function(e){return e===void 0&&(e={}),{name:`flip`,options:e,async fn(t){var n,r;let{placement:i,middlewareData:a,rects:o,initialPlacement:s,platform:c,elements:l}=t,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:f,fallbackStrategy:p=`bestFit`,fallbackAxisSideDirection:m=`none`,flipAlignment:h=!0,...g}=Oa(e,t);if((n=a.arrow)!=null&&n.alignmentOffset)return{};let _=ka(i),v=Pa(s),y=ka(s)===s,b=await(c.isRTL==null?void 0:c.isRTL(l.floating)),x=f||(y||!h?[Ga(s)]:La(s)),S=m!==`none`;!f&&S&&x.push(...Wa(s,h,m,b));let C=[s,...x],w=await Za(t,g),T=[],E=((r=a.flip)==null?void 0:r.overflows)||[];if(u&&T.push(w[_]),d){let e=Ia(i,o,b);T.push(w[e[0]],w[e[1]])}if(E=[...E,{placement:i,overflows:T}],!T.every(e=>e<=0)){var D,O;let e=(((D=a.flip)==null?void 0:D.index)||0)+1,t=C[e];if(t&&(!(d===`alignment`&&v!==Pa(t))||E.every(e=>Pa(e.placement)===v?e.overflows[0]>0:!0)))return{data:{index:e,overflows:E},reset:{placement:t}};let n=(O=E.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0])==null?void 0:O.placement;if(!n)switch(p){case`bestFit`:{var k;let e=(k=E.filter(e=>{if(S){let t=Pa(e.placement);return t===v||t===`y`}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0])==null?void 0:k[0];e&&(n=e);break}case`initialPlacement`:n=s;break}if(i!==n)return{reset:{placement:n}}}return{}}}};function eo(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function to(e){return ya.some(t=>e[t]>=0)}const no=function(e){return e===void 0&&(e={}),{name:`hide`,options:e,async fn(t){let{rects:n}=t,{strategy:r=`referenceHidden`,...i}=Oa(e,t);switch(r){case`referenceHidden`:{let e=eo(await Za(t,{...i,elementContext:`reference`}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:to(e)}}}case`escaped`:{let e=eo(await Za(t,{...i,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:to(e)}}}default:return{}}}}},ro=new Set([`left`,`top`]);async function io(e,t){let{placement:n,platform:r,elements:i}=e,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=ka(n),s=Aa(n),c=Pa(n)===`y`,l=ro.has(o)?-1:1,u=a&&c?-1:1,d=Oa(t,e),{mainAxis:f,crossAxis:p,alignmentAxis:m}=typeof d==`number`?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&typeof m==`number`&&(p=s===`end`?m*-1:m),c?{x:p*u,y:f*l}:{x:f*l,y:p*u}}const ao=function(e){return e===void 0&&(e=0),{name:`offset`,options:e,async fn(t){var n,r;let{x:i,y:a,placement:o,middlewareData:s}=t,c=await io(t,e);return o===((n=s.offset)==null?void 0:n.placement)&&(r=s.arrow)!=null&&r.alignmentOffset?{}:{x:i+c.x,y:a+c.y,data:{...c,placement:o}}}}},oo=function(e){return e===void 0&&(e={}),{name:`shift`,options:e,async fn(t){let{x:n,y:r,placement:i}=t,{mainAxis:a=!0,crossAxis:o=!1,limiter:s={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...c}=Oa(e,t),l={x:n,y:r},u=await Za(t,c),d=Pa(ka(i)),f=ja(d),p=l[f],m=l[d];if(a){let e=f===`y`?`top`:`left`,t=f===`y`?`bottom`:`right`,n=p+u[e],r=p-u[t];p=Da(n,p,r)}if(o){let e=d===`y`?`top`:`left`,t=d===`y`?`bottom`:`right`,n=m+u[e],r=m-u[t];m=Da(n,m,r)}let h=s.fn({...t,[f]:p,[d]:m});return{...h,data:{x:h.x-n,y:h.y-r,enabled:{[f]:a,[d]:o}}}}}},so=function(e){return e===void 0&&(e={}),{options:e,fn(t){let{x:n,y:r,placement:i,rects:a,middlewareData:o}=t,{offset:s=0,mainAxis:c=!0,crossAxis:l=!0}=Oa(e,t),u={x:n,y:r},d=Pa(i),f=ja(d),p=u[f],m=u[d],h=Oa(s,t),g=typeof h==`number`?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(c){let e=f===`y`?`height`:`width`,t=a.reference[f]-a.floating[e]+g.mainAxis,n=a.reference[f]+a.reference[e]-g.mainAxis;p<t?p=t:p>n&&(p=n)}if(l){var _,v;let e=f===`y`?`width`:`height`,t=ro.has(ka(i)),n=a.reference[d]-a.floating[e]+(t&&((_=o.offset)==null?void 0:_[d])||0)+(t?0:g.crossAxis),r=a.reference[d]+a.reference[e]+(t?0:((v=o.offset)==null?void 0:v[d])||0)-(t?g.crossAxis:0);m<n?m=n:m>r&&(m=r)}return{[f]:p,[d]:m}}}},co=function(e){return e===void 0&&(e={}),{name:`size`,options:e,async fn(t){var n,r;let{placement:i,rects:a,platform:o,elements:s}=t,{apply:c=()=>{},...l}=Oa(e,t),u=await Za(t,l),d=ka(i),f=Aa(i),p=Pa(i)===`y`,{width:m,height:h}=a.floating,g,_;d===`top`||d===`bottom`?(g=d,_=f===(await(o.isRTL==null?void 0:o.isRTL(s.floating))?`start`:`end`)?`left`:`right`):(_=d,g=f===`end`?`top`:`bottom`);let v=h-u.top-u.bottom,y=m-u.left-u.right,b=ba(h-u[g],v),x=ba(m-u[_],y),S=!t.middlewareData.shift,C=b,w=x;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(w=y),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(C=v),S&&!f){let e=xa(u.left,0),t=xa(u.right,0),n=xa(u.top,0),r=xa(u.bottom,0);p?w=m-2*(e!==0||t!==0?e+t:xa(u.left,u.right)):C=h-2*(n!==0||r!==0?n+r:xa(u.top,u.bottom))}await c({...t,availableWidth:w,availableHeight:C});let T=await o.getDimensions(s.floating);return m!==T.width||h!==T.height?{reset:{rects:!0}}:{}}}};function lo(){return typeof window<`u`}function H(e){return uo(e)?(e.nodeName||``).toLowerCase():`#document`}function U(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function W(e){var t;return(t=(uo(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function uo(e){return lo()?e instanceof Node||e instanceof U(e).Node:!1}function fo(e){return lo()?e instanceof Element||e instanceof U(e).Element:!1}function po(e){return lo()?e instanceof HTMLElement||e instanceof U(e).HTMLElement:!1}function mo(e){return!lo()||typeof ShadowRoot>`u`?!1:e instanceof ShadowRoot||e instanceof U(e).ShadowRoot}const ho=new Set([`inline`,`contents`]);function go(e){let{overflow:t,overflowX:n,overflowY:r,display:i}=Oo(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!ho.has(i)}const _o=new Set([`table`,`td`,`th`]);function vo(e){return _o.has(H(e))}const yo=[`:popover-open`,`:modal`];function bo(e){return yo.some(t=>{try{return e.matches(t)}catch{return!1}})}const xo=[`transform`,`translate`,`scale`,`rotate`,`perspective`],So=[`transform`,`translate`,`scale`,`rotate`,`perspective`,`filter`],Co=[`paint`,`layout`,`strict`,`content`];function wo(e){let t=Eo(),n=fo(e)?Oo(e):e;return xo.some(e=>n[e]?n[e]!==`none`:!1)||(n.containerType?n.containerType!==`normal`:!1)||!t&&(n.backdropFilter?n.backdropFilter!==`none`:!1)||!t&&(n.filter?n.filter!==`none`:!1)||So.some(e=>(n.willChange||``).includes(e))||Co.some(e=>(n.contain||``).includes(e))}function To(e){let t=Ao(e);for(;po(t)&&!G(t);){if(wo(t))return t;if(bo(t))return null;t=Ao(t)}return null}function Eo(){return typeof CSS>`u`||!CSS.supports?!1:CSS.supports(`-webkit-backdrop-filter`,`none`)}const Do=new Set([`html`,`body`,`#document`]);function G(e){return Do.has(H(e))}function Oo(e){return U(e).getComputedStyle(e)}function ko(e){return fo(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Ao(e){if(H(e)===`html`)return e;let t=e.assignedSlot||e.parentNode||mo(e)&&e.host||W(e);return mo(t)?t.host:t}function jo(e){let t=Ao(e);return G(t)?e.ownerDocument?e.ownerDocument.body:e.body:po(t)&&go(t)?t:jo(t)}function Mo(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);let i=jo(e),a=i===((r=e.ownerDocument)==null?void 0:r.body),o=U(i);if(a){let e=No(o);return t.concat(o,o.visualViewport||[],go(i)?i:[],e&&n?Mo(e):[])}return t.concat(i,Mo(i,[],n))}function No(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Po(e){let t=Oo(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,i=po(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,s=Sa(n)!==a||Sa(r)!==o;return s&&(n=a,r=o),{width:n,height:r,$:s}}function Fo(e){return fo(e)?e:e.contextElement}function Io(e){let t=Fo(e);if(!po(t))return wa(1);let n=t.getBoundingClientRect(),{width:r,height:i,$:a}=Po(t),o=(a?Sa(n.width):n.width)/r,s=(a?Sa(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!s||!Number.isFinite(s))&&(s=1),{x:o,y:s}}const Lo=wa(0);function Ro(e){let t=U(e);return!Eo()||!t.visualViewport?Lo:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function zo(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==U(e)?!1:t}function Bo(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);let i=e.getBoundingClientRect(),a=Fo(e),o=wa(1);t&&(r?fo(r)&&(o=Io(r)):o=Io(e));let s=zo(a,n,r)?Ro(a):wa(0),c=(i.left+s.x)/o.x,l=(i.top+s.y)/o.y,u=i.width/o.x,d=i.height/o.y;if(a){let e=U(a),t=r&&fo(r)?U(r):r,n=e,i=No(n);for(;i&&r&&t!==n;){let e=Io(i),t=i.getBoundingClientRect(),r=Oo(i),a=t.left+(i.clientLeft+parseFloat(r.paddingLeft))*e.x,o=t.top+(i.clientTop+parseFloat(r.paddingTop))*e.y;c*=e.x,l*=e.y,u*=e.x,d*=e.y,c+=a,l+=o,n=U(i),i=No(n)}}return Ja({width:u,height:d,x:c,y:l})}function Vo(e,t){let n=ko(e).scrollLeft;return t?t.left+n:Bo(W(e)).left+n}function Ho(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-Vo(e,n),y:n.top+t.scrollTop}}function Uo(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e,a=i===`fixed`,o=W(r),s=t?bo(t.floating):!1;if(r===o||s&&a)return n;let c={scrollLeft:0,scrollTop:0},l=wa(1),u=wa(0),d=po(r);if((d||!d&&!a)&&((H(r)!==`body`||go(o))&&(c=ko(r)),po(r))){let e=Bo(r);l=Io(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}let f=o&&!d&&!a?Ho(o,c):wa(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-c.scrollLeft*l.x+u.x+f.x,y:n.y*l.y-c.scrollTop*l.y+u.y+f.y}}function Wo(e){return Array.from(e.getClientRects())}function Go(e){let t=W(e),n=ko(e),r=e.ownerDocument.body,i=xa(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=xa(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight),o=-n.scrollLeft+Vo(e),s=-n.scrollTop;return Oo(r).direction===`rtl`&&(o+=xa(t.clientWidth,r.clientWidth)-i),{width:i,height:a,x:o,y:s}}function Ko(e,t){let n=U(e),r=W(e),i=n.visualViewport,a=r.clientWidth,o=r.clientHeight,s=0,c=0;if(i){a=i.width,o=i.height;let e=Eo();(!e||e&&t===`fixed`)&&(s=i.offsetLeft,c=i.offsetTop)}let l=Vo(r);if(l<=0){let e=r.ownerDocument,t=e.body,n=getComputedStyle(t),i=e.compatMode===`CSS1Compat`&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,o=Math.abs(r.clientWidth-t.clientWidth-i);o<=25&&(a-=o)}else l<=25&&(a+=l);return{width:a,height:o,x:s,y:c}}const qo=new Set([`absolute`,`fixed`]);function Jo(e,t){let n=Bo(e,!0,t===`fixed`),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=po(e)?Io(e):wa(1);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:i*a.x,y:r*a.y}}function Yo(e,t,n){let r;if(t===`viewport`)r=Ko(e,n);else if(t===`document`)r=Go(W(e));else if(fo(t))r=Jo(t,n);else{let n=Ro(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return Ja(r)}function Xo(e,t){let n=Ao(e);return n===t||!fo(n)||G(n)?!1:Oo(n).position===`fixed`||Xo(n,t)}function Zo(e,t){let n=t.get(e);if(n)return n;let r=Mo(e,[],!1).filter(e=>fo(e)&&H(e)!==`body`),i=null,a=Oo(e).position===`fixed`,o=a?Ao(e):e;for(;fo(o)&&!G(o);){let t=Oo(o),n=wo(o);!n&&t.position===`fixed`&&(i=null),(a?!n&&!i:!n&&t.position===`static`&&i&&qo.has(i.position)||go(o)&&!n&&Xo(e,o))?r=r.filter(e=>e!==o):i=t,o=Ao(o)}return t.set(e,r),r}function Qo(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e,a=[...n===`clippingAncestors`?bo(t)?[]:Zo(t,this._c):[].concat(n),r],o=a[0],s=a.reduce((e,n)=>{let r=Yo(t,n,i);return e.top=xa(r.top,e.top),e.right=ba(r.right,e.right),e.bottom=ba(r.bottom,e.bottom),e.left=xa(r.left,e.left),e},Yo(t,o,i));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}}function $o(e){let{width:t,height:n}=Po(e);return{width:t,height:n}}function es(e,t,n){let r=po(t),i=W(t),a=n===`fixed`,o=Bo(e,!0,a,t),s={scrollLeft:0,scrollTop:0},c=wa(0);function l(){c.x=Vo(i)}if(r||!r&&!a)if((H(t)!==`body`||go(i))&&(s=ko(t)),r){let e=Bo(t,!0,a,t);c.x=e.x+t.clientLeft,c.y=e.y+t.clientTop}else i&&l();a&&!r&&i&&l();let u=i&&!r&&!a?Ho(i,s):wa(0);return{x:o.left+s.scrollLeft-c.x-u.x,y:o.top+s.scrollTop-c.y-u.y,width:o.width,height:o.height}}function ts(e){return Oo(e).position===`static`}function ns(e,t){if(!po(e)||Oo(e).position===`fixed`)return null;if(t)return t(e);let n=e.offsetParent;return W(e)===n&&(n=n.ownerDocument.body),n}function rs(e,t){let n=U(e);if(bo(e))return n;if(!po(e)){let t=Ao(e);for(;t&&!G(t);){if(fo(t)&&!ts(t))return t;t=Ao(t)}return n}let r=ns(e,t);for(;r&&vo(r)&&ts(r);)r=ns(r,t);return r&&G(r)&&ts(r)&&!wo(r)?n:r||To(e)||n}const is=async function(e){let t=this.getOffsetParent||rs,n=this.getDimensions,r=await n(e.floating);return{reference:es(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function as(e){return Oo(e).direction===`rtl`}const os={convertOffsetParentRelativeRectToViewportRelativeRect:Uo,getDocumentElement:W,getClippingRect:Qo,getOffsetParent:rs,getElementRects:is,getClientRects:Wo,getDimensions:$o,getScale:Io,isElement:fo,isRTL:as};function ss(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function cs(e,t){let n=null,r,i=W(e);function a(){var e;clearTimeout(r),(e=n)==null||e.disconnect(),n=null}function o(s,c){s===void 0&&(s=!1),c===void 0&&(c=1),a();let l=e.getBoundingClientRect(),{left:u,top:d,width:f,height:p}=l;if(s||t(),!f||!p)return;let m=Ca(d),h=Ca(i.clientWidth-(u+f)),g=Ca(i.clientHeight-(d+p)),_=Ca(u),v={rootMargin:-m+`px `+-h+`px `+-g+`px `+-_+`px`,threshold:xa(0,ba(1,c))||1},y=!0;function b(t){let n=t[0].intersectionRatio;if(n!==c){if(!y)return o();n?o(!1,n):r=setTimeout(()=>{o(!1,1e-7)},1e3)}n===1&&!ss(l,e.getBoundingClientRect())&&o(),y=!1}try{n=new IntersectionObserver(b,{...v,root:i.ownerDocument})}catch{n=new IntersectionObserver(b,v)}n.observe(e)}return o(!0),a}function ls(e,t,n,r){r===void 0&&(r={});let{ancestorScroll:i=!0,ancestorResize:a=!0,elementResize:o=typeof ResizeObserver==`function`,layoutShift:s=typeof IntersectionObserver==`function`,animationFrame:c=!1}=r,l=Fo(e),u=i||a?[...l?Mo(l):[],...Mo(t)]:[];u.forEach(e=>{i&&e.addEventListener(`scroll`,n,{passive:!0}),a&&e.addEventListener(`resize`,n)});let d=l&&s?cs(l,n):null,f=-1,p=null;o&&(p=new ResizeObserver(e=>{let[r]=e;r&&r.target===l&&p&&(p.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var e;(e=p)==null||e.observe(t)})),n()}),l&&!c&&p.observe(l),p.observe(t));let m,h=c?Bo(e):null;c&&g();function g(){let t=Bo(e);h&&!ss(h,t)&&n(),h=t,m=requestAnimationFrame(g)}return n(),()=>{var e;u.forEach(e=>{i&&e.removeEventListener(`scroll`,n),a&&e.removeEventListener(`resize`,n)}),d==null||d(),(e=p)==null||e.disconnect(),p=null,c&&cancelAnimationFrame(m)}}const us=ao,ds=oo,fs=$a,ps=co,ms=no,hs=Qa,gs=so,_s=(e,t,n)=>{let r=new Map,i={platform:os,...n},a={...i.platform,_c:r};return Xa(e,t,{...i,platform:a})};var vs=typeof document<`u`?h.useLayoutEffect:function(){};function ys(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e==`function`&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e==`object`){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!ys(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){let n=i[r];if(!(n===`_owner`&&e.$$typeof)&&!ys(e[n],t[n]))return!1}return!0}return e!==e&&t!==t}function bs(e){return typeof window>`u`?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function xs(e,t){let n=bs(e);return Math.round(t*n)/n}function Ss(e){let t=h.useRef(e);return vs(()=>{t.current=e}),t}function Cs(e){e===void 0&&(e={});let{placement:t=`bottom`,strategy:n=`absolute`,middleware:r=[],platform:i,elements:{reference:a,floating:o}={},transform:s=!0,whileElementsMounted:c,open:l}=e,[u,d]=h.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=h.useState(r);ys(f,r)||p(r);let[m,g]=h.useState(null),[_,v]=h.useState(null),y=h.useCallback(e=>{e!==C.current&&(C.current=e,g(e))},[]),b=h.useCallback(e=>{e!==w.current&&(w.current=e,v(e))},[]),x=a||m,S=o||_,C=h.useRef(null),w=h.useRef(null),T=h.useRef(u),E=c!=null,D=Ss(c),O=Ss(i),k=Ss(l),A=h.useCallback(()=>{if(!C.current||!w.current)return;let e={placement:t,strategy:n,middleware:f};O.current&&(e.platform=O.current),_s(C.current,w.current,e).then(e=>{let t={...e,isPositioned:k.current!==!1};j.current&&!ys(T.current,t)&&(T.current=t,Pt.flushSync(()=>{d(t)}))})},[f,t,n,O,k]);vs(()=>{l===!1&&T.current.isPositioned&&(T.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[l]);let j=h.useRef(!1);vs(()=>(j.current=!0,()=>{j.current=!1}),[]),vs(()=>{if(x&&(C.current=x),S&&(w.current=S),x&&S){if(D.current)return D.current(x,S,A);A()}},[x,S,A,D,E]);let ee=h.useMemo(()=>({reference:C,floating:w,setReference:y,setFloating:b}),[y,b]),M=h.useMemo(()=>({reference:x,floating:S}),[x,S]),N=h.useMemo(()=>{let e={position:n,left:0,top:0};if(!M.floating)return e;let t=xs(M.floating,u.x),r=xs(M.floating,u.y);return s?{...e,transform:`translate(`+t+`px, `+r+`px)`,...bs(M.floating)>=1.5&&{willChange:`transform`}}:{position:n,left:t,top:r}},[n,s,M.floating,u.x,u.y]);return h.useMemo(()=>({...u,update:A,refs:ee,elements:M,floatingStyles:N}),[u,A,ee,M,N])}const ws=e=>{function t(e){return{}.hasOwnProperty.call(e,`current`)}return{name:`arrow`,options:e,fn(n){let{element:r,padding:i}=typeof e==`function`?e(n):e;return r&&t(r)?r.current==null?{}:hs({element:r.current,padding:i}).fn(n):r?hs({element:r,padding:i}).fn(n):{}}}},Ts=(e,t)=>({...us(e),options:[e,t]}),Es=(e,t)=>({...ds(e),options:[e,t]}),Ds=(e,t)=>({...gs(e),options:[e,t]}),Os=(e,t)=>({...fs(e),options:[e,t]}),ks=(e,t)=>({...ps(e),options:[e,t]}),As=(e,t)=>({...ms(e),options:[e,t]}),js=(e,t)=>({...ws(e),options:[e,t]});var Ms=`Arrow`,Ns=h.forwardRef((e,t)=>{let{children:n,width:r=10,height:i=5,...a}=e;return(0,z.jsx)(Vt.svg,{...a,ref:t,width:r,height:i,viewBox:`0 0 30 10`,preserveAspectRatio:`none`,children:e.asChild?n:(0,z.jsx)(`polygon`,{points:`0,0 30,0 15,10`})})});Ns.displayName=Ms;var Ps=Ns;function Fs(e){let[t,n]=h.useState(void 0);return wt(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});let t=new ResizeObserver(t=>{if(!Array.isArray(t)||!t.length)return;let r=t[0],i,a;if(`borderBoxSize`in r){let e=r.borderBoxSize,t=Array.isArray(e)?e[0]:e;i=t.inlineSize,a=t.blockSize}else i=e.offsetWidth,a=e.offsetHeight;n({width:i,height:a})});return t.observe(e,{box:`border-box`}),()=>t.unobserve(e)}else n(void 0)},[e]),t}var Is=`Popper`,[Ls,Rs]=xt(Is),[zs,Bs]=Ls(Is),Vs=e=>{let{__scopePopper:t,children:n}=e,[r,i]=h.useState(null);return(0,z.jsx)(zs,{scope:t,anchor:r,onAnchorChange:i,children:n})};Vs.displayName=Is;var Hs=`PopperAnchor`,Us=h.forwardRef((e,t)=>{let{__scopePopper:n,virtualRef:r,...i}=e,a=Bs(Hs,n),o=h.useRef(null),s=Re(t,o),c=h.useRef(null);return h.useEffect(()=>{let e=c.current;c.current=(r==null?void 0:r.current)||o.current,e!==c.current&&a.onAnchorChange(c.current)}),r?null:(0,z.jsx)(Vt.div,{...i,ref:s})});Us.displayName=Hs;var Ws=`PopperContent`,[Gs,Ks]=Ls(Ws),qs=h.forwardRef((e,t)=>{var n,r,i,a,o,s,c,l;let{__scopePopper:u,side:d=`bottom`,sideOffset:f=0,align:p=`center`,alignOffset:m=0,arrowPadding:g=0,avoidCollisions:_=!0,collisionBoundary:v=[],collisionPadding:y=0,sticky:b=`partial`,hideWhenDetached:x=!1,updatePositionStrategy:S=`optimized`,onPlaced:C,...w}=e,T=Bs(Ws,u),[E,D]=h.useState(null),O=Re(t,e=>D(e)),[k,A]=h.useState(null),j=Fs(k),ee=(n=j==null?void 0:j.width)==null?0:n,M=(r=j==null?void 0:j.height)==null?0:r,N=d+(p===`center`?``:`-`+p),P=typeof y==`number`?y:{top:0,right:0,bottom:0,left:0,...y},F=Array.isArray(v)?v:[v],te=F.length>0,ne={padding:P,boundary:F.filter(Zs),altBoundary:te},{refs:re,floatingStyles:ie,placement:I,isPositioned:ae,middlewareData:oe}=Cs({strategy:`fixed`,placement:N,whileElementsMounted:(...e)=>ls(...e,{animationFrame:S===`always`}),elements:{reference:T.anchor},middleware:[Ts({mainAxis:f+M,alignmentAxis:m}),_&&Es({mainAxis:!0,crossAxis:!1,limiter:b===`partial`?Ds():void 0,...ne}),_&&Os({...ne}),ks({...ne,apply:({elements:e,rects:t,availableWidth:n,availableHeight:r})=>{let{width:i,height:a}=t.reference,o=e.floating.style;o.setProperty(`--radix-popper-available-width`,`${n}px`),o.setProperty(`--radix-popper-available-height`,`${r}px`),o.setProperty(`--radix-popper-anchor-width`,`${i}px`),o.setProperty(`--radix-popper-anchor-height`,`${a}px`)}}),k&&js({element:k,padding:g}),Qs({arrowWidth:ee,arrowHeight:M}),x&&As({strategy:`referenceHidden`,...ne})]}),[se,ce]=$s(I),le=Ut(C);wt(()=>{ae&&(le==null||le())},[ae,le]);let ue=(i=oe.arrow)==null?void 0:i.x,de=(a=oe.arrow)==null?void 0:a.y,fe=((o=oe.arrow)==null?void 0:o.centerOffset)!==0,[pe,L]=h.useState();return wt(()=>{E&&L(window.getComputedStyle(E).zIndex)},[E]),(0,z.jsx)(`div`,{ref:re.setFloating,"data-radix-popper-content-wrapper":``,style:{...ie,transform:ae?ie.transform:`translate(0, -200%)`,minWidth:`max-content`,zIndex:pe,"--radix-popper-transform-origin":[(s=oe.transformOrigin)==null?void 0:s.x,(c=oe.transformOrigin)==null?void 0:c.y].join(` `),...((l=oe.hide)==null?void 0:l.referenceHidden)&&{visibility:`hidden`,pointerEvents:`none`}},dir:e.dir,children:(0,z.jsx)(Gs,{scope:u,placedSide:se,onArrowChange:A,arrowX:ue,arrowY:de,shouldHideArrow:fe,children:(0,z.jsx)(Vt.div,{"data-side":se,"data-align":ce,...w,ref:O,style:{...w.style,animation:ae?void 0:`none`}})})})});qs.displayName=Ws;var Js=`PopperArrow`,Ys={top:`bottom`,right:`left`,bottom:`top`,left:`right`},Xs=h.forwardRef(function(e,t){let{__scopePopper:n,...r}=e,i=Ks(Js,n),a=Ys[i.placedSide];return(0,z.jsx)(`span`,{ref:i.onArrowChange,style:{position:`absolute`,left:i.arrowX,top:i.arrowY,[a]:0,transformOrigin:{top:``,right:`0 0`,bottom:`center 0`,left:`100% 0`}[i.placedSide],transform:{top:`translateY(100%)`,right:`translateY(50%) rotate(90deg) translateX(-50%)`,bottom:`rotate(180deg)`,left:`translateY(50%) rotate(-90deg) translateX(50%)`}[i.placedSide],visibility:i.shouldHideArrow?`hidden`:void 0},children:(0,z.jsx)(Ps,{...r,ref:t,style:{...r.style,display:`block`}})})});Xs.displayName=Js;function Zs(e){return e!==null}var Qs=e=>({name:`transformOrigin`,options:e,fn(t){var n,r,i,a,o;let{placement:s,rects:c,middlewareData:l}=t,u=((n=l.arrow)==null?void 0:n.centerOffset)!==0,d=u?0:e.arrowWidth,f=u?0:e.arrowHeight,[p,m]=$s(s),h={start:`0%`,center:`50%`,end:`100%`}[m],g=((r=(i=l.arrow)==null?void 0:i.x)==null?0:r)+d/2,_=((a=(o=l.arrow)==null?void 0:o.y)==null?0:a)+f/2,v=``,y=``;return p===`bottom`?(v=u?h:`${g}px`,y=`${-f}px`):p===`top`?(v=u?h:`${g}px`,y=`${c.floating.height+f}px`):p===`right`?(v=`${-f}px`,y=u?h:`${_}px`):p===`left`&&(v=`${c.floating.width+f}px`,y=u?h:`${_}px`),{data:{x:v,y}}}});function $s(e){let[t,n=`center`]=e.split(`-`);return[t,n]}var ec=Vs,tc=Us,nc=qs,rc=Xs,ic=`Popover`,[ac,oc]=xt(ic,[Rs]),sc=Rs(),[cc,lc]=ac(ic),uc=e=>{let{__scopePopover:t,children:n,open:r,defaultOpen:i,onOpenChange:a,modal:o=!1}=e,s=sc(t),c=h.useRef(null),[l,u]=h.useState(!1),[d,f]=kt({prop:r,defaultProp:i==null?!1:i,onChange:a,caller:ic});return(0,z.jsx)(ec,{...s,children:(0,z.jsx)(cc,{scope:t,contentId:Dt(),triggerRef:c,open:d,onOpenChange:f,onOpenToggle:h.useCallback(()=>f(e=>!e),[f]),hasCustomAnchor:l,onCustomAnchorAdd:h.useCallback(()=>u(!0),[]),onCustomAnchorRemove:h.useCallback(()=>u(!1),[]),modal:o,children:n})})};uc.displayName=ic;var dc=`PopoverAnchor`,fc=h.forwardRef((e,t)=>{let{__scopePopover:n,...r}=e,i=lc(dc,n),a=sc(n),{onCustomAnchorAdd:o,onCustomAnchorRemove:s}=i;return h.useEffect(()=>(o(),()=>s()),[o,s]),(0,z.jsx)(tc,{...a,...r,ref:t})});fc.displayName=dc;var pc=`PopoverTrigger`,mc=h.forwardRef((e,t)=>{let{__scopePopover:n,...r}=e,i=lc(pc,n),a=sc(n),o=Re(t,i.triggerRef),s=(0,z.jsx)(Vt.button,{type:`button`,"aria-haspopup":`dialog`,"aria-expanded":i.open,"aria-controls":i.contentId,"data-state":kc(i.open),...r,ref:o,onClick:B(e.onClick,i.onOpenToggle)});return i.hasCustomAnchor?s:(0,z.jsx)(tc,{asChild:!0,...a,children:s})});mc.displayName=pc;var hc=`PopoverPortal`,[gc,_c]=ac(hc,{forceMount:void 0}),vc=e=>{let{__scopePopover:t,forceMount:n,children:r,container:i}=e,a=lc(hc,t);return(0,z.jsx)(gc,{scope:t,forceMount:n,children:(0,z.jsx)(wn,{present:n||a.open,children:(0,z.jsx)(Sn,{asChild:!0,container:i,children:r})})})};vc.displayName=hc;var yc=`PopoverContent`,bc=h.forwardRef((e,t)=>{let n=_c(yc,e.__scopePopover),{forceMount:r=n.forceMount,...i}=e,a=lc(yc,e.__scopePopover);return(0,z.jsx)(wn,{present:r||a.open,children:a.modal?(0,z.jsx)(Sc,{...i,ref:t}):(0,z.jsx)(Cc,{...i,ref:t})})});bc.displayName=yc;var xc=Ft(`PopoverContent.RemoveScroll`),Sc=h.forwardRef((e,t)=>{let n=lc(yc,e.__scopePopover),r=h.useRef(null),i=Re(t,r),a=h.useRef(!1);return h.useEffect(()=>{let e=r.current;if(e)return(0,$r.hideOthers)(e)},[]),(0,z.jsx)(Qr.RemoveScroll,{as:xc,allowPinchZoom:!0,children:(0,z.jsx)(wc,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:B(e.onCloseAutoFocus,e=>{var t;e.preventDefault(),a.current||(t=n.triggerRef.current)==null||t.focus()}),onPointerDownOutside:B(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0;a.current=t.button===2||n},{checkForDefaultPrevented:!1}),onFocusOutside:B(e.onFocusOutside,e=>e.preventDefault(),{checkForDefaultPrevented:!1})})})}),Cc=h.forwardRef((e,t)=>{let n=lc(yc,e.__scopePopover),r=h.useRef(!1),i=h.useRef(!1);return(0,z.jsx)(wc,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{var a;if((a=e.onCloseAutoFocus)==null||a.call(e,t),!t.defaultPrevented){var o;r.current||(o=n.triggerRef.current)==null||o.focus(),t.preventDefault()}r.current=!1,i.current=!1},onInteractOutside:t=>{var a,o;(a=e.onInteractOutside)==null||a.call(e,t),t.defaultPrevented||(r.current=!0,t.detail.originalEvent.type===`pointerdown`&&(i.current=!0));let s=t.target;(o=n.triggerRef.current)!=null&&o.contains(s)&&t.preventDefault(),t.detail.originalEvent.type===`focusin`&&i.current&&t.preventDefault()}})}),wc=h.forwardRef((e,t)=>{let{__scopePopover:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:a,disableOutsidePointerEvents:o,onEscapeKeyDown:s,onPointerDownOutside:c,onFocusOutside:l,onInteractOutside:u,...d}=e,f=lc(yc,n),p=sc(n);return kn(),(0,z.jsx)(ln,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:a,children:(0,z.jsx)(Zt,{asChild:!0,disableOutsidePointerEvents:o,onInteractOutside:u,onEscapeKeyDown:s,onPointerDownOutside:c,onFocusOutside:l,onDismiss:()=>f.onOpenChange(!1),children:(0,z.jsx)(nc,{"data-state":kc(f.open),role:`dialog`,id:f.contentId,...p,...d,ref:t,style:{...d.style,"--radix-popover-content-transform-origin":`var(--radix-popper-transform-origin)`,"--radix-popover-content-available-width":`var(--radix-popper-available-width)`,"--radix-popover-content-available-height":`var(--radix-popper-available-height)`,"--radix-popover-trigger-width":`var(--radix-popper-anchor-width)`,"--radix-popover-trigger-height":`var(--radix-popper-anchor-height)`}})})})}),Tc=`PopoverClose`,Ec=h.forwardRef((e,t)=>{let{__scopePopover:n,...r}=e,i=lc(Tc,n);return(0,z.jsx)(Vt.button,{type:`button`,...r,ref:t,onClick:B(e.onClick,()=>i.onOpenChange(!1))})});Ec.displayName=Tc;var Dc=`PopoverArrow`,Oc=h.forwardRef((e,t)=>{let{__scopePopover:n,...r}=e,i=sc(n);return(0,z.jsx)(rc,{...i,...r,ref:t})});Oc.displayName=Dc;function kc(e){return e?`open`:`closed`}var Ac=uc,jc=mc,Mc=vc,Nc=bc;function Pc({...e}){return(0,z.jsx)(Ac,{"data-slot":`popover`,...e})}function Fc({...e}){return(0,z.jsx)(jc,{"data-slot":`popover-trigger`,...e})}function Ic({className:e,align:t=`center`,sideOffset:n=4,...r}){return(0,z.jsx)(Mc,{children:(0,z.jsx)(Nc,{"data-slot":`popover-content`,align:t,sideOffset:n,className:R(`univer-outline-hidden data-[state=open]:univer-animate-in data-[state=open]:univer-fade-in-0 data-[state=open]:univer-zoom-in-95 data-[state=closed]:univer-animate-out data-[state=closed]:univer-fade-out-0 data-[state=closed]:univer-zoom-out-95 data-[side=bottom]:univer-slide-in-from-top-2 data-[side=left]:univer-slide-in-from-right-2 data-[side=right]:univer-slide-in-from-left-2 data-[side=top]:univer-slide-in-from-bottom-2 univer-z-[1080] univer-max-h-[--radix-popper-available-height] univer-overflow-y-auto univer-rounded-md univer-bg-white univer-text-gray-900 univer-shadow-md dark:!univer-bg-gray-900 dark:!univer-text-white dark:focus-visible:!univer-border-gray-600`,at,rt,e),...r})})}function Lc(e){let{children:t,overlay:n,disabled:r,open:i,onOpenChange:a,...o}=e,[s,c]=(0,h.useState)(!1),l=i!==void 0,u=l?i:s;function d(e){r||(l||c(e),a==null||a(e))}return(0,z.jsxs)(Pc,{open:u,onOpenChange:d,children:[(0,z.jsx)(Fc,{asChild:!0,children:t}),(0,z.jsx)(Ic,{...o,children:n})]})}function Rc(e){let{value:t,onValueChange:n,className:r}=e,[i,a]=(0,h.useState)(!1);function o(e){n==null||n(e),a(!1)}return(0,z.jsx)(Lc,{align:`start`,overlay:(0,z.jsx)(`div`,{className:`univer-p-2`,children:(0,z.jsx)(ht,{value:t,onValueChange:o})}),open:i,onOpenChange:a,children:(0,z.jsxs)(`button`,{className:R(`univer-flex univer-h-8 univer-items-center univer-justify-between univer-gap-2 univer-rounded-md univer-bg-transparent univer-px-2 univer-text-sm univer-text-gray-800 univer-transition-all hover:univer-border-primary-600 dark:!univer-text-white`,at,r),type:`button`,children:[(0,nt.default)(t).format(`YYYY-MM-DD`),(0,z.jsx)(f.CalendarIcon,{className:`univer-text-gray-600 dark:!univer-text-gray-400`})]})})}function zc(e){let{value:t=[new Date,new Date],onValueChange:n,className:r}=e,[i,a]=(0,h.useState)(!1);function o(e){let[t,r]=e;t>r&&([t,r]=[r,t]),n==null||n([t,r]),a(!1)}return(0,z.jsx)(Lc,{align:`start`,overlay:(0,z.jsxs)(`div`,{className:`univer-grid univer-grid-cols-2 univer-gap-2 univer-p-2`,children:[(0,z.jsx)(ht,{value:t[0],max:t[1],onValueChange:e=>{o([e,t[1]])}}),(0,z.jsx)(ht,{value:t[1],min:t[0],onValueChange:e=>{o([t[0],e])}})]}),open:i,onOpenChange:a,children:(0,z.jsxs)(`button`,{className:R(`univer-flex univer-h-8 univer-items-center univer-justify-between univer-gap-2 univer-rounded-md univer-bg-transparent univer-px-2 univer-text-sm univer-text-gray-800 univer-transition-all hover:univer-border-primary-600 dark:!univer-text-white`,at,r),type:`button`,children:[(0,z.jsxs)(`span`,{className:`univer-flex univer-gap-1`,children:[(0,z.jsx)(`span`,{children:(0,nt.default)(t[0]).format(`YYYY-MM-DD`)}),(0,z.jsx)(`span`,{children:`-`}),(0,z.jsx)(`span`,{children:(0,nt.default)(t[1]).format(`YYYY-MM-DD`)})]}),(0,z.jsx)(f.CalendarIcon,{className:`univer-text-gray-600 dark:!univer-text-gray-400`})]})})}function Bc(e,t,n){if(t===n||t<0||n<0||t>=e.length||n>=e.length)return e;let r=[...e],[i]=r.splice(t,1);return r.splice(n,0,i),r}function Vc(e){let{list:t,onListChange:n,idKey:r,itemRender:i,className:a,style:o,draggableHandle:s,rowHeight:c,margin:l=[0,0],onDragStart:u,onDragStop:d,...f}=e,[p,m]=(0,h.useState)(t),g=(0,h.useRef)(t),[_,v]=(0,h.useState)(null),[y,b]=(0,h.useState)(null),[x,S]=(0,h.useState)(null),[C,w]=(0,h.useState)(null),[T,E]=(0,h.useState)(!1),D=(0,h.useRef)(null),O=(0,h.useRef)({x:0,y:0}),k=(0,h.useRef)({width:0,height:0}),A=(0,h.useRef)(null),j=(0,h.useRef)(null),ee=(0,h.useRef)(null),M=(0,h.useRef)(-1);(0,h.useEffect)(()=>{_||(m(t),g.current=t)},[_,t]),(0,h.useEffect)(()=>{E(typeof document<`u`)},[]),(0,h.useEffect)(()=>{let e=A.current;e&&(e.replaceChildren(),x&&e.appendChild(x))},[x]),(0,h.useEffect)(()=>{if(!_)return;let e=e=>{let t=ee.current;if(!t||D.current!==e.pointerId)return;w({x:e.clientX-O.current.x,y:e.clientY-O.current.y});let n=document.elementFromPoint(e.clientX,e.clientY),r=n==null?void 0:n.closest(`[data-draggable-list-item-id]`),i=r==null?void 0:r.dataset.draggableListItemId;!i||i===t||(b(i),m(e=>{let n=e.findIndex(e=>P(e)===t),r=e.findIndex(e=>P(e)===i);if(n<0||r<0||n===r)return e;let a=Bc(e,n,r);return g.current=a,a}))},t=e=>{if(D.current!==e.pointerId)return;let t=ee.current,r=M.current,i=g.current;if(t){let e=i.findIndex(e=>P(e)===t);d==null||d(void 0,{y:r},{y:e}),r>=0&&n([...i])}D.current=null,j.current=null,ee.current=null,M.current=-1,b(null),S(null),w(null),v(null)};return window.addEventListener(`pointermove`,e),window.addEventListener(`pointerup`,t),window.addEventListener(`pointercancel`,t),()=>{window.removeEventListener(`pointermove`,e),window.removeEventListener(`pointerup`,t),window.removeEventListener(`pointercancel`,t)}},[_,d,n]);let N=(0,h.useMemo)(()=>{let[e,t]=l;return{rowGap:`${t}px`,paddingLeft:e?`${e}px`:void 0,paddingRight:e?`${e}px`:void 0,...o}},[l,o]),P=e=>String(e[r]),F=_?p.find(e=>P(e)===_):null;return(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(`div`,{...f,className:R(`univer-flex univer-flex-col`,_&&`univer-cursor-grabbing univer-select-none`,a),style:N,children:p.map((e,t)=>{let n=P(e),r=_===n,a=y===n&&!r;return(0,z.jsxs)(`div`,{"data-draggable-list-item-id":n,className:R(`univer-relative univer-transition-all univer-duration-150`,r&&`univer-opacity-0`,a&&`
141
126
  univer-bg-primary-50/60
142
127
  dark:!univer-bg-primary-900/20
143
128
  univer-rounded univer-border univer-border-primary-200
144
129
  dark:!univer-border-primary-700
145
- `),onPointerDownCapture:O=>{if(k.current!==null)return;if(!s)z.current=B;else{const oe=!!O.target.closest(s);z.current=oe?B:null}if(z.current!==B)return;const V=O.currentTarget.getBoundingClientRect();T.current={x:O.clientX-V.left,y:O.clientY-V.top},F.current={width:V.width,height:V.height},L({x:V.left,y:V.top}),S(O.currentTarget.innerHTML),k.current=O.pointerId,A.current=B,_.current=j,x(B),b.current=p,f==null||f(void 0,{y:j}),O.preventDefault(),O.currentTarget.setPointerCapture(O.pointerId)},style:{...c?{minHeight:`${c}px`}:void 0,cursor:h?"grabbing":void 0},children:[K&&v.jsx("div",{className:`
130
+ `),onPointerDownCapture:e=>{if(D.current!==null||(s?j.current=e.target.closest(s)?n:null:j.current=n,j.current!==n))return;let r=e.currentTarget.getBoundingClientRect();O.current={x:e.clientX-r.left,y:e.clientY-r.top},k.current={width:r.width,height:r.height},w({x:r.left,y:r.top}),S(e.currentTarget.cloneNode(!0)),D.current=e.pointerId,ee.current=n,M.current=t,v(n),g.current=p,u==null||u(void 0,{y:t}),e.preventDefault(),e.currentTarget.setPointerCapture(e.pointerId)},style:{...c?{minHeight:`${c}px`}:void 0,cursor:_?`grabbing`:void 0},children:[r&&(0,z.jsx)(`div`,{className:`
146
131
  univer-bg-primary-50/50 univer-absolute univer-inset-0 univer-rounded
147
132
  univer-border univer-border-dashed univer-border-primary-300
148
- `}),o(P,j)]},B)})}),D&&N&&R&&ut.createPortal(v.jsx("div",{className:W("univer-pointer-events-none univer-fixed univer-rounded-md univer-border univer-border-gray-200 univer-bg-white univer-shadow-lg dark:!univer-border-gray-700 dark:!univer-bg-gray-800"),style:{zIndex:2147483647,left:`${R.x}px`,top:`${R.y}px`,width:`${F.current.width}px`,height:`${F.current.height}px`,opacity:.95},children:C?v.jsx("div",{dangerouslySetInnerHTML:{__html:C}}):o(N,p.findIndex(P=>I(P)===I(N)))}),document.body)]})}function Wc(e){const t=e+"CollectionProvider",[n,r]=An(t),[o,i]=n(t,{collectionRef:{current:null},itemMap:new Map}),a=b=>{const{scope:h,children:x}=b,E=y.useRef(null),w=y.useRef(new Map).current;return v.jsx(o,{scope:h,itemMap:w,collectionRef:E,children:x})};a.displayName=t;const s=e+"CollectionSlot",c=vr(s),l=y.forwardRef((b,h)=>{const{scope:x,children:E}=b,w=i(s,x),C=Ue(h,w.collectionRef);return v.jsx(c,{ref:C,children:E})});l.displayName=s;const f=e+"CollectionItemSlot",u="data-radix-collection-item",m=vr(f),p=y.forwardRef((b,h)=>{const{scope:x,children:E,...w}=b,C=y.useRef(null),S=Ue(h,C),R=i(f,x);return y.useEffect(()=>(R.itemMap.set(C,{ref:C,...w}),()=>{R.itemMap.delete(C)})),v.jsx(m,{[u]:"",ref:S,children:E})});p.displayName=f;function g(b){const h=i(e+"CollectionConsumer",b);return y.useCallback(()=>{const E=h.collectionRef.current;if(!E)return[];const w=Array.from(E.querySelectorAll(`[${u}]`));return Array.from(h.itemMap.values()).sort((R,L)=>w.indexOf(R.ref.current)-w.indexOf(L.ref.current))},[h.collectionRef,h.itemMap])}return[{Provider:a,Slot:l,ItemSlot:p},g,r]}var b0=d.createContext(void 0);function Kc(e){const t=d.useContext(b0);return e||t||"ltr"}var Xi="rovingFocusGroup.onEntryFocus",y0={bubbles:!1,cancelable:!0},ro="RovingFocusGroup",[va,Uc,x0]=Wc(ro),[w0,Gc]=An(ro,[x0]),[C0,E0]=w0(ro),Yc=d.forwardRef((e,t)=>v.jsx(va.Provider,{scope:e.__scopeRovingFocusGroup,children:v.jsx(va.Slot,{scope:e.__scopeRovingFocusGroup,children:v.jsx(S0,{...e,ref:t})})}));Yc.displayName=ro;var S0=d.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:o=!1,dir:i,currentTabStopId:a,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:c,onEntryFocus:l,preventScrollOnEntryFocus:f=!1,...u}=e,m=d.useRef(null),p=Ue(t,m),g=Kc(i),[b,h]=wr({prop:a,defaultProp:s!=null?s:null,onChange:c,caller:ro}),[x,E]=d.useState(!1),w=Ut(l),C=Uc(n),S=d.useRef(!1),[R,L]=d.useState(0);return d.useEffect(()=>{const D=m.current;if(D)return D.addEventListener(Xi,w),()=>D.removeEventListener(Xi,w)},[w]),v.jsx(C0,{scope:n,orientation:r,dir:g,loop:o,currentTabStopId:b,onItemFocus:d.useCallback(D=>h(D),[h]),onItemShiftTab:d.useCallback(()=>E(!0),[]),onFocusableItemAdd:d.useCallback(()=>L(D=>D+1),[]),onFocusableItemRemove:d.useCallback(()=>L(D=>D-1),[]),children:v.jsx($e.div,{tabIndex:x||R===0?-1:0,"data-orientation":r,...u,ref:p,style:{outline:"none",...e.style},onMouseDown:ie(e.onMouseDown,()=>{S.current=!0}),onFocus:ie(e.onFocus,D=>{const H=!S.current;if(D.target===D.currentTarget&&H&&!x){const k=new CustomEvent(Xi,y0);if(D.currentTarget.dispatchEvent(k),!k.defaultPrevented){const T=C().filter(M=>M.focusable),F=T.find(M=>M.active),z=T.find(M=>M.id===b),_=[F,z,...T].filter(Boolean).map(M=>M.ref.current);Xc(_,f)}}S.current=!1}),onBlur:ie(e.onBlur,()=>E(!1))})})}),Zc="RovingFocusGroupItem",qc=d.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:o=!1,tabStopId:i,children:a,...s}=e,c=on(),l=i||c,f=E0(Zc,n),u=f.currentTabStopId===l,m=Uc(n),{onFocusableItemAdd:p,onFocusableItemRemove:g,currentTabStopId:b}=f;return d.useEffect(()=>{if(r)return p(),()=>g()},[r,p,g]),v.jsx(va.ItemSlot,{scope:n,id:l,focusable:r,active:o,children:v.jsx($e.span,{tabIndex:u?0:-1,"data-orientation":f.orientation,...s,ref:t,onMouseDown:ie(e.onMouseDown,h=>{r?f.onItemFocus(l):h.preventDefault()}),onFocus:ie(e.onFocus,()=>f.onItemFocus(l)),onKeyDown:ie(e.onKeyDown,h=>{if(h.key==="Tab"&&h.shiftKey){f.onItemShiftTab();return}if(h.target!==h.currentTarget)return;const x=N0(h,f.orientation,f.dir);if(x!==void 0){if(h.metaKey||h.ctrlKey||h.altKey||h.shiftKey)return;h.preventDefault();let w=m().filter(C=>C.focusable).map(C=>C.ref.current);if(x==="last")w.reverse();else if(x==="prev"||x==="next"){x==="prev"&&w.reverse();const C=w.indexOf(h.currentTarget);w=f.loop?P0(w,C+1):w.slice(C+1)}setTimeout(()=>Xc(w))}}),children:typeof a=="function"?a({isCurrentTabStop:u,hasTabStop:b!=null}):a})})});qc.displayName=Zc;var R0={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function M0(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function N0(e,t,n){const r=M0(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return R0[r]}function Xc(e,t=!1){const n=document.activeElement;for(const r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}function P0(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var k0=Yc,_0=qc,ma=["Enter"," "],I0=["ArrowDown","PageUp","Home"],Qc=["ArrowUp","PageDown","End"],D0=[...I0,...Qc],A0={ltr:[...ma,"ArrowRight"],rtl:[...ma,"ArrowLeft"]},T0={ltr:["ArrowLeft"],rtl:["ArrowRight"]},oo="Menu",[Ur,O0,j0]=Wc(oo),[Un,Jc]=An(oo,[j0,Sr,Gc]),io=Sr(),ed=Gc(),[td,On]=Un(oo),[L0,ao]=Un(oo),nd=e=>{const{__scopeMenu:t,open:n=!1,children:r,dir:o,onOpenChange:i,modal:a=!0}=e,s=io(t),[c,l]=d.useState(null),f=d.useRef(!1),u=Ut(i),m=Kc(o);return d.useEffect(()=>{const p=()=>{f.current=!0,document.addEventListener("pointerdown",g,{capture:!0,once:!0}),document.addEventListener("pointermove",g,{capture:!0,once:!0})},g=()=>f.current=!1;return document.addEventListener("keydown",p,{capture:!0}),()=>{document.removeEventListener("keydown",p,{capture:!0}),document.removeEventListener("pointerdown",g,{capture:!0}),document.removeEventListener("pointermove",g,{capture:!0})}},[]),v.jsx(mi,{...s,children:v.jsx(td,{scope:t,open:n,onOpenChange:u,content:c,onContentChange:l,children:v.jsx(L0,{scope:t,onClose:d.useCallback(()=>u(!1),[u]),isUsingKeyboardRef:f,dir:m,modal:a,children:r})})})};nd.displayName=oo;var $0="MenuAnchor",us=d.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,o=io(n);return v.jsx(pi,{...o,...r,ref:t})});us.displayName=$0;var ls="MenuPortal",[F0,rd]=Un(ls,{forceMount:void 0}),od=e=>{const{__scopeMenu:t,forceMount:n,children:r,container:o}=e,i=On(ls,t);return v.jsx(F0,{scope:t,forceMount:n,children:v.jsx(Nt,{present:n||i.open,children:v.jsx(eo,{asChild:!0,container:o,children:r})})})};od.displayName=ls;var Mt="MenuContent",[z0,cs]=Un(Mt),id=d.forwardRef((e,t)=>{const n=rd(Mt,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,i=On(Mt,e.__scopeMenu),a=ao(Mt,e.__scopeMenu);return v.jsx(Ur.Provider,{scope:e.__scopeMenu,children:v.jsx(Nt,{present:r||i.open,children:v.jsx(Ur.Slot,{scope:e.__scopeMenu,children:a.modal?v.jsx(B0,{...o,ref:t}):v.jsx(H0,{...o,ref:t})})})})}),B0=d.forwardRef((e,t)=>{const n=On(Mt,e.__scopeMenu),r=d.useRef(null),o=Ue(t,r);return d.useEffect(()=>{const i=r.current;if(i)return Va(i)},[]),v.jsx(ds,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:ie(e.onFocusOutside,i=>i.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)})}),H0=d.forwardRef((e,t)=>{const n=On(Mt,e.__scopeMenu);return v.jsx(ds,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)})}),V0=vr("MenuContent.ScrollLock"),ds=d.forwardRef((e,t)=>{const{__scopeMenu:n,loop:r=!1,trapFocus:o,onOpenAutoFocus:i,onCloseAutoFocus:a,disableOutsidePointerEvents:s,onEntryFocus:c,onEscapeKeyDown:l,onPointerDownOutside:f,onFocusOutside:u,onInteractOutside:m,onDismiss:p,disableOutsideScroll:g,...b}=e,h=On(Mt,n),x=ao(Mt,n),E=io(n),w=ed(n),C=O0(n),[S,R]=d.useState(null),L=d.useRef(null),D=Ue(t,L,h.onContentChange),H=d.useRef(0),k=d.useRef(""),T=d.useRef(0),F=d.useRef(null),z=d.useRef("right"),A=d.useRef(0),_=g?ui:d.Fragment,M=g?{as:V0,allowPinchZoom:!0}:void 0,I=P=>{var oe,G;const j=k.current+P,B=C().filter(q=>!q.disabled),K=document.activeElement,$=(oe=B.find(q=>q.ref.current===K))==null?void 0:oe.textValue,O=B.map(q=>q.textValue),V=t1(O,j,$),U=(G=B.find(q=>q.textValue===V))==null?void 0:G.ref.current;(function q(ne){k.current=ne,window.clearTimeout(H.current),ne!==""&&(H.current=window.setTimeout(()=>q(""),1e3))})(j),U&&setTimeout(()=>U.focus())};d.useEffect(()=>()=>window.clearTimeout(H.current),[]),Ha();const N=d.useCallback(P=>{var B,K;return z.current===((B=F.current)==null?void 0:B.side)&&r1(P,(K=F.current)==null?void 0:K.area)},[]);return v.jsx(z0,{scope:n,searchRef:k,onItemEnter:d.useCallback(P=>{N(P)&&P.preventDefault()},[N]),onItemLeave:d.useCallback(P=>{var j;N(P)||((j=L.current)==null||j.focus(),R(null))},[N]),onTriggerLeave:d.useCallback(P=>{N(P)&&P.preventDefault()},[N]),pointerGraceTimerRef:T,onPointerGraceIntentChange:d.useCallback(P=>{F.current=P},[]),children:v.jsx(_,{...M,children:v.jsx(ai,{asChild:!0,trapped:o,onMountAutoFocus:ie(i,P=>{var j;P.preventDefault(),(j=L.current)==null||j.focus({preventScroll:!0})}),onUnmountAutoFocus:a,children:v.jsx(Jr,{asChild:!0,disableOutsidePointerEvents:s,onEscapeKeyDown:l,onPointerDownOutside:f,onFocusOutside:u,onInteractOutside:m,onDismiss:p,children:v.jsx(k0,{asChild:!0,...w,dir:x.dir,orientation:"vertical",loop:r,currentTabStopId:S,onCurrentTabStopIdChange:R,onEntryFocus:ie(c,P=>{x.isUsingKeyboardRef.current||P.preventDefault()}),preventScrollOnEntryFocus:!0,children:v.jsx(os,{role:"menu","aria-orientation":"vertical","data-state":Cd(h.open),"data-radix-menu-content":"",dir:x.dir,...E,...b,ref:D,style:{outline:"none",...b.style},onKeyDown:ie(b.onKeyDown,P=>{const B=P.target.closest("[data-radix-menu-content]")===P.currentTarget,K=P.ctrlKey||P.altKey||P.metaKey,$=P.key.length===1;B&&(P.key==="Tab"&&P.preventDefault(),!K&&$&&I(P.key));const O=L.current;if(P.target!==O||!D0.includes(P.key))return;P.preventDefault();const U=C().filter(oe=>!oe.disabled).map(oe=>oe.ref.current);Qc.includes(P.key)&&U.reverse(),J0(U)}),onBlur:ie(e.onBlur,P=>{P.currentTarget.contains(P.target)||(window.clearTimeout(H.current),k.current="")}),onPointerMove:ie(e.onPointerMove,Gr(P=>{const j=P.target,B=A.current!==P.clientX;if(P.currentTarget.contains(j)&&B){const K=P.clientX>A.current?"right":"left";z.current=K,A.current=P.clientX}}))})})})})})})});id.displayName=Mt;var W0="MenuGroup",fs=d.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return v.jsx($e.div,{role:"group",...r,ref:t})});fs.displayName=W0;var K0="MenuLabel",ad=d.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return v.jsx($e.div,{...r,ref:t})});ad.displayName=K0;var Uo="MenuItem",lu="menu.itemSelect",gi=d.forwardRef((e,t)=>{const{disabled:n=!1,onSelect:r,...o}=e,i=d.useRef(null),a=ao(Uo,e.__scopeMenu),s=cs(Uo,e.__scopeMenu),c=Ue(t,i),l=d.useRef(!1),f=()=>{const u=i.current;if(!n&&u){const m=new CustomEvent(lu,{bubbles:!0,cancelable:!0});u.addEventListener(lu,p=>r==null?void 0:r(p),{once:!0}),Pl(u,m),m.defaultPrevented?l.current=!1:a.onClose()}};return v.jsx(sd,{...o,ref:c,disabled:n,onClick:ie(e.onClick,f),onPointerDown:u=>{var m;(m=e.onPointerDown)==null||m.call(e,u),l.current=!0},onPointerUp:ie(e.onPointerUp,u=>{var m;l.current||(m=u.currentTarget)==null||m.click()}),onKeyDown:ie(e.onKeyDown,u=>{const m=s.searchRef.current!=="";n||m&&u.key===" "||ma.includes(u.key)&&(u.currentTarget.click(),u.preventDefault())})})});gi.displayName=Uo;var sd=d.forwardRef((e,t)=>{const{__scopeMenu:n,disabled:r=!1,textValue:o,...i}=e,a=cs(Uo,n),s=ed(n),c=d.useRef(null),l=Ue(t,c),[f,u]=d.useState(!1),[m,p]=d.useState("");return d.useEffect(()=>{var b;const g=c.current;g&&p(((b=g.textContent)!=null?b:"").trim())},[i.children]),v.jsx(Ur.ItemSlot,{scope:n,disabled:r,textValue:o!=null?o:m,children:v.jsx(_0,{asChild:!0,...s,focusable:!r,children:v.jsx($e.div,{role:"menuitem","data-highlighted":f?"":void 0,"aria-disabled":r||void 0,"data-disabled":r?"":void 0,...i,ref:l,onPointerMove:ie(e.onPointerMove,Gr(g=>{r?a.onItemLeave(g):(a.onItemEnter(g),g.defaultPrevented||g.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:ie(e.onPointerLeave,Gr(g=>a.onItemLeave(g))),onFocus:ie(e.onFocus,()=>u(!0)),onBlur:ie(e.onBlur,()=>u(!1))})})})}),U0="MenuCheckboxItem",ud=d.forwardRef((e,t)=>{const{checked:n=!1,onCheckedChange:r,...o}=e;return v.jsx(vd,{scope:e.__scopeMenu,checked:n,children:v.jsx(gi,{role:"menuitemcheckbox","aria-checked":Go(n)?"mixed":n,...o,ref:t,"data-state":ps(n),onSelect:ie(o.onSelect,()=>r==null?void 0:r(Go(n)?!0:!n),{checkForDefaultPrevented:!1})})})});ud.displayName=U0;var ld="MenuRadioGroup",[G0,Y0]=Un(ld,{value:void 0,onValueChange:()=>{}}),cd=d.forwardRef((e,t)=>{const{value:n,onValueChange:r,...o}=e,i=Ut(r);return v.jsx(G0,{scope:e.__scopeMenu,value:n,onValueChange:i,children:v.jsx(fs,{...o,ref:t})})});cd.displayName=ld;var dd="MenuRadioItem",fd=d.forwardRef((e,t)=>{const{value:n,...r}=e,o=Y0(dd,e.__scopeMenu),i=n===o.value;return v.jsx(vd,{scope:e.__scopeMenu,checked:i,children:v.jsx(gi,{role:"menuitemradio","aria-checked":i,...r,ref:t,"data-state":ps(i),onSelect:ie(r.onSelect,()=>{var a;return(a=o.onValueChange)==null?void 0:a.call(o,n)},{checkForDefaultPrevented:!1})})})});fd.displayName=dd;var vs="MenuItemIndicator",[vd,Z0]=Un(vs,{checked:!1}),md=d.forwardRef((e,t)=>{const{__scopeMenu:n,forceMount:r,...o}=e,i=Z0(vs,n);return v.jsx(Nt,{present:r||Go(i.checked)||i.checked===!0,children:v.jsx($e.span,{...o,ref:t,"data-state":ps(i.checked)})})});md.displayName=vs;var q0="MenuSeparator",pd=d.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return v.jsx($e.div,{role:"separator","aria-orientation":"horizontal",...r,ref:t})});pd.displayName=q0;var X0="MenuArrow",hd=d.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,o=io(n);return v.jsx(is,{...o,...r,ref:t})});hd.displayName=X0;var ms="MenuSub",[Q0,gd]=Un(ms),bd=e=>{const{__scopeMenu:t,children:n,open:r=!1,onOpenChange:o}=e,i=On(ms,t),a=io(t),[s,c]=d.useState(null),[l,f]=d.useState(null),u=Ut(o);return d.useEffect(()=>(i.open===!1&&u(!1),()=>u(!1)),[i.open,u]),v.jsx(mi,{...a,children:v.jsx(td,{scope:t,open:r,onOpenChange:u,content:l,onContentChange:f,children:v.jsx(Q0,{scope:t,contentId:on(),triggerId:on(),trigger:s,onTriggerChange:c,children:n})})})};bd.displayName=ms;var $r="MenuSubTrigger",yd=d.forwardRef((e,t)=>{const n=On($r,e.__scopeMenu),r=ao($r,e.__scopeMenu),o=gd($r,e.__scopeMenu),i=cs($r,e.__scopeMenu),a=d.useRef(null),{pointerGraceTimerRef:s,onPointerGraceIntentChange:c}=i,l={__scopeMenu:e.__scopeMenu},f=d.useCallback(()=>{a.current&&window.clearTimeout(a.current),a.current=null},[]);return d.useEffect(()=>f,[f]),d.useEffect(()=>{const u=s.current;return()=>{window.clearTimeout(u),c(null)}},[s,c]),v.jsx(us,{asChild:!0,...l,children:v.jsx(sd,{id:o.triggerId,"aria-haspopup":"menu","aria-expanded":n.open,"aria-controls":o.contentId,"data-state":Cd(n.open),...e,ref:Qr(t,o.onTriggerChange),onClick:u=>{var m;(m=e.onClick)==null||m.call(e,u),!(e.disabled||u.defaultPrevented)&&(u.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:ie(e.onPointerMove,Gr(u=>{i.onItemEnter(u),!u.defaultPrevented&&!e.disabled&&!n.open&&!a.current&&(i.onPointerGraceIntentChange(null),a.current=window.setTimeout(()=>{n.onOpenChange(!0),f()},100))})),onPointerLeave:ie(e.onPointerLeave,Gr(u=>{var p,g;f();const m=(p=n.content)==null?void 0:p.getBoundingClientRect();if(m){const b=(g=n.content)==null?void 0:g.dataset.side,h=b==="right",x=h?-5:5,E=m[h?"left":"right"],w=m[h?"right":"left"];i.onPointerGraceIntentChange({area:[{x:u.clientX+x,y:u.clientY},{x:E,y:m.top},{x:w,y:m.top},{x:w,y:m.bottom},{x:E,y:m.bottom}],side:b}),window.clearTimeout(s.current),s.current=window.setTimeout(()=>i.onPointerGraceIntentChange(null),300)}else{if(i.onTriggerLeave(u),u.defaultPrevented)return;i.onPointerGraceIntentChange(null)}})),onKeyDown:ie(e.onKeyDown,u=>{var p;const m=i.searchRef.current!=="";e.disabled||m&&u.key===" "||A0[r.dir].includes(u.key)&&(n.onOpenChange(!0),(p=n.content)==null||p.focus(),u.preventDefault())})})})});yd.displayName=$r;var xd="MenuSubContent",wd=d.forwardRef((e,t)=>{const n=rd(Mt,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,i=On(Mt,e.__scopeMenu),a=ao(Mt,e.__scopeMenu),s=gd(xd,e.__scopeMenu),c=d.useRef(null),l=Ue(t,c);return v.jsx(Ur.Provider,{scope:e.__scopeMenu,children:v.jsx(Nt,{present:r||i.open,children:v.jsx(Ur.Slot,{scope:e.__scopeMenu,children:v.jsx(ds,{id:s.contentId,"aria-labelledby":s.triggerId,...o,ref:l,align:"start",side:a.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:f=>{var u;a.isUsingKeyboardRef.current&&((u=c.current)==null||u.focus()),f.preventDefault()},onCloseAutoFocus:f=>f.preventDefault(),onFocusOutside:ie(e.onFocusOutside,f=>{f.target!==s.trigger&&i.onOpenChange(!1)}),onEscapeKeyDown:ie(e.onEscapeKeyDown,f=>{a.onClose(),f.preventDefault()}),onKeyDown:ie(e.onKeyDown,f=>{var p;const u=f.currentTarget.contains(f.target),m=T0[a.dir].includes(f.key);u&&m&&(i.onOpenChange(!1),(p=s.trigger)==null||p.focus(),f.preventDefault())})})})})})});wd.displayName=xd;function Cd(e){return e?"open":"closed"}function Go(e){return e==="indeterminate"}function ps(e){return Go(e)?"indeterminate":e?"checked":"unchecked"}function J0(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function e1(e,t){return e.map((n,r)=>e[(t+r)%e.length])}function t1(e,t,n){const o=t.length>1&&Array.from(t).every(l=>l===t[0])?t[0]:t,i=n?e.indexOf(n):-1;let a=e1(e,Math.max(i,0));o.length===1&&(a=a.filter(l=>l!==n));const c=a.find(l=>l.toLowerCase().startsWith(o.toLowerCase()));return c!==n?c:void 0}function n1(e,t){const{x:n,y:r}=e;let o=!1;for(let i=0,a=t.length-1;i<t.length;a=i++){const s=t[i],c=t[a],l=s.x,f=s.y,u=c.x,m=c.y;f>r!=m>r&&n<(u-l)*(r-f)/(m-f)+l&&(o=!o)}return o}function r1(e,t){if(!t)return!1;const n={x:e.clientX,y:e.clientY};return n1(n,t)}function Gr(e){return t=>t.pointerType==="mouse"?e(t):void 0}var o1=nd,i1=us,a1=od,s1=id,u1=fs,l1=ad,c1=gi,d1=ud,f1=cd,v1=fd,m1=md,p1=pd,h1=hd,g1=bd,b1=yd,y1=wd,bi="DropdownMenu",[x1]=An(bi,[Jc]),dt=Jc(),[w1,Ed]=x1(bi),Sd=e=>{const{__scopeDropdownMenu:t,children:n,dir:r,open:o,defaultOpen:i,onOpenChange:a,modal:s=!0}=e,c=dt(t),l=d.useRef(null),[f,u]=wr({prop:o,defaultProp:i!=null?i:!1,onChange:a,caller:bi});return v.jsx(w1,{scope:t,triggerId:on(),triggerRef:l,contentId:on(),open:f,onOpenChange:u,onOpenToggle:d.useCallback(()=>u(m=>!m),[u]),modal:s,children:v.jsx(o1,{...c,open:f,onOpenChange:u,dir:r,modal:s,children:n})})};Sd.displayName=bi;var Rd="DropdownMenuTrigger",Md=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,disabled:r=!1,...o}=e,i=Ed(Rd,n),a=dt(n);return v.jsx(i1,{asChild:!0,...a,children:v.jsx($e.button,{type:"button",id:i.triggerId,"aria-haspopup":"menu","aria-expanded":i.open,"aria-controls":i.open?i.contentId:void 0,"data-state":i.open?"open":"closed","data-disabled":r?"":void 0,disabled:r,...o,ref:Qr(t,i.triggerRef),onPointerDown:ie(e.onPointerDown,s=>{!r&&s.button===0&&s.ctrlKey===!1&&(i.onOpenToggle(),i.open||s.preventDefault())}),onKeyDown:ie(e.onKeyDown,s=>{r||(["Enter"," "].includes(s.key)&&i.onOpenToggle(),s.key==="ArrowDown"&&i.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(s.key)&&s.preventDefault())})})})});Md.displayName=Rd;var C1="DropdownMenuPortal",Nd=e=>{const{__scopeDropdownMenu:t,...n}=e,r=dt(t);return v.jsx(a1,{...r,...n})};Nd.displayName=C1;var Pd="DropdownMenuContent",kd=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ed(Pd,n),i=dt(n),a=d.useRef(!1);return v.jsx(s1,{id:o.contentId,"aria-labelledby":o.triggerId,...i,...r,ref:t,onCloseAutoFocus:ie(e.onCloseAutoFocus,s=>{var c;a.current||(c=o.triggerRef.current)==null||c.focus(),a.current=!1,s.preventDefault()}),onInteractOutside:ie(e.onInteractOutside,s=>{const c=s.detail.originalEvent,l=c.button===0&&c.ctrlKey===!0,f=c.button===2||l;(!o.modal||f)&&(a.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});kd.displayName=Pd;var E1="DropdownMenuGroup",S1=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=dt(n);return v.jsx(u1,{...o,...r,ref:t})});S1.displayName=E1;var R1="DropdownMenuLabel",M1=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=dt(n);return v.jsx(l1,{...o,...r,ref:t})});M1.displayName=R1;var N1="DropdownMenuItem",_d=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=dt(n);return v.jsx(c1,{...o,...r,ref:t})});_d.displayName=N1;var P1="DropdownMenuCheckboxItem",Id=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=dt(n);return v.jsx(d1,{...o,...r,ref:t})});Id.displayName=P1;var k1="DropdownMenuRadioGroup",Dd=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=dt(n);return v.jsx(f1,{...o,...r,ref:t})});Dd.displayName=k1;var _1="DropdownMenuRadioItem",Ad=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=dt(n);return v.jsx(v1,{...o,...r,ref:t})});Ad.displayName=_1;var I1="DropdownMenuItemIndicator",Td=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=dt(n);return v.jsx(m1,{...o,...r,ref:t})});Td.displayName=I1;var D1="DropdownMenuSeparator",Od=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=dt(n);return v.jsx(p1,{...o,...r,ref:t})});Od.displayName=D1;var A1="DropdownMenuArrow",T1=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=dt(n);return v.jsx(h1,{...o,...r,ref:t})});T1.displayName=A1;var O1=e=>{const{__scopeDropdownMenu:t,children:n,open:r,onOpenChange:o,defaultOpen:i}=e,a=dt(t),[s,c]=wr({prop:r,defaultProp:i!=null?i:!1,onChange:o,caller:"DropdownMenuSub"});return v.jsx(g1,{...a,open:s,onOpenChange:c,children:n})},j1="DropdownMenuSubTrigger",jd=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=dt(n);return v.jsx(b1,{...o,...r,ref:t})});jd.displayName=j1;var L1="DropdownMenuSubContent",Ld=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=dt(n);return v.jsx(y1,{...o,...r,ref:t,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});Ld.displayName=L1;var $1=Sd,F1=Md,$d=Nd,z1=kd,B1=_d,H1=Id,V1=Dd,W1=Ad,Fd=Td,K1=Od,U1=O1,G1=jd,Y1=Ld;function Z1({...e}){return v.jsx($1,{"data-slot":"dropdown-menu",...e})}function q1({...e}){return v.jsx($d,{"data-slot":"dropdown-menu-portal",...e})}function X1({...e}){return v.jsx(F1,{"data-slot":"dropdown-menu-trigger",...e})}function Q1({...e}){return v.jsx(U1,{"data-slot":"dropdown-menu-sub",...e})}function J1({...e}){return v.jsx(V1,{"data-slot":"dropdown-menu-radio-group",...e})}function eb({className:e,inset:t,children:n,...r}){return v.jsxs(G1,{"data-slot":"dropdown-menu-sub-trigger","data-inset":t,className:W(`
149
- univer-flex univer-cursor-default univer-select-none univer-items-center univer-justify-between
150
- univer-gap-2 univer-rounded univer-px-2 univer-py-1.5 univer-text-sm univer-outline-none
151
- data-[state=open]:univer-bg-gray-100
152
- focus:univer-bg-gray-100
153
- dark:data-[state=open]:!univer-bg-gray-600
154
- dark:focus:!univer-bg-gray-600
155
- [&_svg]:univer-pointer-events-none [&_svg]:univer-size-4 [&_svg]:univer-shrink-0
156
- `,e),...r,children:[n,v.jsx(Vr,{className:"ml-auto"})]})}function tb({className:e,...t}){return v.jsx(Y1,{"data-slot":"dropdown-menu-sub-content",className:W(`
157
- data-[state=open]:univer-animate-in data-[state=open]:univer-fade-in-0
158
- data-[state=open]:univer-zoom-in-95
159
- data-[state=closed]:univer-animate-out data-[state=closed]:univer-fade-out-0
160
- data-[state=closed]:univer-zoom-out-95
161
- data-[side=bottom]:univer-slide-in-from-top-2
162
- data-[side=left]:univer-slide-in-from-right-2
163
- data-[side=right]:univer-slide-in-from-left-2
164
- data-[side=top]:univer-slide-in-from-bottom-2
165
- univer-z-[1080] univer-box-border univer-max-h-[--radix-popper-available-height]
166
- univer-overflow-y-auto univer-rounded-md univer-bg-white univer-p-1.5 univer-text-gray-900
167
- univer-shadow-md
168
- dark:!univer-bg-gray-700 dark:!univer-text-white
169
- `,ct,kn,e),...t})}function nb({className:e,sideOffset:t=4,...n}){return v.jsx($d,{children:v.jsx(z1,{"data-slot":"dropdown-menu-content",sideOffset:t,className:W(`
170
- data-[state=open]:univer-animate-in data-[state=open]:univer-fade-in-0
171
- data-[state=open]:univer-zoom-in-95
172
- data-[state=closed]:univer-animate-out data-[state=closed]:univer-fade-out-0
173
- data-[state=closed]:univer-zoom-out-95
174
- data-[side=bottom]:univer-slide-in-from-top-2
175
- data-[side=left]:univer-slide-in-from-right-2
176
- data-[side=right]:univer-slide-in-from-left-2
177
- data-[side=top]:univer-slide-in-from-bottom-2
178
- univer-z-[1080] univer-box-border univer-max-h-[--radix-popper-available-height]
179
- univer-overflow-y-auto univer-rounded-md univer-bg-white univer-p-1.5 univer-text-gray-900
180
- univer-shadow-md
181
- dark:!univer-bg-gray-700 dark:!univer-text-white
182
- `,ct,kn,e),...n})})}function rb({className:e,inset:t,variant:n="default",...r}){return v.jsx(B1,{"data-slot":"dropdown-menu-item","data-inset":t,"data-variant":n,className:W(`
183
- univer-relative univer-flex univer-cursor-default univer-select-none univer-items-center univer-gap-2
184
- univer-rounded univer-px-2 univer-py-1.5 univer-text-sm univer-outline-none univer-transition-colors
185
- data-[disabled]:univer-pointer-events-none data-[disabled]:univer-opacity-50
186
- focus:univer-bg-gray-100
187
- dark:focus:!univer-bg-gray-600
188
- [&>svg]:univer-size-4 [&>svg]:univer-shrink-0
189
- `,e),...r})}function ob({className:e,children:t,hideIndicator:n,checked:r,...o}){return v.jsxs(H1,{"data-slot":"dropdown-menu-checkbox-item",className:W(`
190
- univer-relative univer-flex univer-cursor-default univer-select-none univer-items-center
191
- univer-rounded univer-py-1.5 univer-pr-2 univer-text-sm univer-outline-none univer-transition-colors
192
- data-[disabled]:univer-pointer-events-none data-[disabled]:univer-opacity-50
193
- focus:univer-bg-gray-100
194
- dark:focus:!univer-bg-gray-600
195
- `,{"univer-pl-8":!n,"univer-pl-2":n},e),checked:r,...o,children:[!n&&v.jsx("span",{className:"univer-absolute univer-left-2 univer-flex univer-size-3.5 univer-items-center univer-justify-center",children:v.jsx(Fd,{children:v.jsx(br,{className:"univer-block univer-size-4 univer-fill-current univer-text-primary-600"})})}),t]})}function ib({className:e,children:t,hideIndicator:n,...r}){return v.jsxs(W1,{"data-slot":"dropdown-menu-radio-item",className:W(`
196
- univer-relative univer-flex univer-cursor-default univer-select-none univer-items-center
197
- univer-rounded univer-py-1.5 univer-pr-2 univer-text-sm univer-outline-none univer-transition-colors
198
- data-[disabled]:univer-pointer-events-none data-[disabled]:univer-opacity-50
199
- focus:univer-bg-gray-100
200
- dark:focus:!univer-bg-gray-600
201
- `,{"univer-pl-8":!n,"univer-pl-2":n},e),...r,children:[!n&&v.jsx("span",{className:"univer-absolute univer-left-2 univer-flex univer-size-3.5 univer-items-center univer-justify-center",children:v.jsx(Fd,{children:v.jsx(br,{className:"univer-block univer-size-4 univer-fill-current univer-text-primary-600"})})}),t]})}function cu({className:e,...t}){return v.jsx(K1,{className:W("-univer-mx-1 univer-my-1 univer-h-px univer-bg-gray-200 dark:!univer-bg-gray-600",e),...t})}function hs(e){const{children:t,items:n,disabled:r,open:o,onOpenChange:i,...a}=e,[s,c]=y.useState(!1),l=o!==void 0,f=l?o:s;function u(p){r||(l||c(p),i==null||i(p))}function m(p,g){var x;const{className:b,type:h}=p;if(h==="separator")return v.jsx(cu,{className:b},g);if(h==="radio")return v.jsx(J1,{className:b,value:p.value,onValueChange:p.onSelect,children:p.options.map((E,w)=>{if("type"in E){if(E.type==="separator")return v.jsx(cu,{className:E.className},w)}else{if(E.value===void 0)throw new Error("[DropdownMenu]: `value` is required");return v.jsx(ib,{value:E.value,disabled:E.disabled,hideIndicator:p.hideIndicator,children:E.label},E.value)}return null})},g);if(h==="checkbox")return v.jsx(ob,{className:b,disabled:p.disabled,checked:p.checked,onSelect:()=>{var E;(E=p.onSelect)==null||E.call(p,p.value)},children:p.label},g);if(h==="item")return v.jsx(rb,{className:b,disabled:p.disabled,onSelect:()=>{var E;(E=p.onSelect)==null||E.call(p,p)},children:p.children},g);if(h==="subItem")return v.jsxs(Q1,{children:[v.jsx(eb,{children:p.children}),v.jsx(q1,{children:v.jsx(tb,{sideOffset:12,children:(x=p.options)==null?void 0:x.map((E,w)=>m(E,w))})})]},g)}return v.jsxs(Z1,{modal:!1,open:f,onOpenChange:u,children:[v.jsx(X1,{asChild:!0,children:t}),v.jsx(nb,{className:"univer-text-sm",collisionPadding:{top:12,bottom:12},onWheel:p=>p.stopPropagation(),...a,children:n.map((p,g)=>m(p,g))})]})}const ab=y.createContext(!1),sb=e=>{const{label:t,desc:n,children:r,style:o,className:i,error:a,contentStyle:s,collapsable:c=!1,defaultCollapsed:l=!1}=e,[f,u]=y.useState(l);return v.jsx(ab.Provider,{value:!0,children:v.jsxs("div",{"data-u-comp":"form-layout",className:W("univer-mb-3 univer-flex univer-flex-col",i),style:o,children:[t&&v.jsxs("div",{className:W("univer-mb-2 univer-flex univer-min-h-3.5 univer-items-center univer-text-sm univer-text-gray-900 dark:!univer-text-white",{"univer-cursor-pointer":c}),onClick:()=>u(!f),children:[t,c&&v.jsx(sl,{className:W("univer-ml-1 univer-transition-transform",{"univer-rotate-180":f})})]}),f&&c?null:v.jsxs(v.Fragment,{children:[n&&v.jsx("div",{className:"univer-mt-1 univer-text-sm univer-text-gray-600 dark:!univer-text-gray-200",children:n}),r?v.jsxs("div",{className:W("last:univer-mb-0 [&_[data-u-comp=input]]:univer-w-full [&_[data-u-comp=select]]:univer-w-full",{"[&_[data-u-comp=input]]:univer-border-red-500":a,"[&_[data-u-comp=select]]:univer-border-red-500":a}),style:s,children:[r,a?v.jsx("div",{className:"univer-mt-1 univer-text-xs univer-text-red-500",children:a}):null]}):null]})]})})},ub=e=>v.jsx("div",{className:"univer-flex univer-justify-between [&_[data-u-comp=form-layout]]:univer-max-w-[calc(50%-8px)] [&_[data-u-comp=form-layout]]:univer-shrink [&_[data-u-comp=form-layout]]:univer-grow",children:e.children});function zd(e){const{className:t,value:n=0,total:r=0,loop:o,text:i,onChange:a}=e,s=y.useMemo(()=>i!=null?i:`${n}/${r}`,[n,r,i]),c=r>0,l=()=>{n===1?o&&(a==null||a(r)):a==null||a(n-1)},f=()=>{n===r?o&&(a==null||a(1)):a==null||a(n+1)};return v.jsx("div",{"data-u-comp":"pager",className:W("univer-flex univer-flex-shrink-0 univer-items-center univer-text-sm univer-text-gray-700 dark:!univer-text-gray-400",t),children:c?v.jsxs(v.Fragment,{children:[v.jsx("button",{"data-u-comp":"pager-left-arrow",className:"univer-inline-flex univer-size-4 univer-cursor-pointer univer-items-center univer-rounded univer-border-none univer-bg-transparent univer-p-0 hover:univer-bg-gray-50 dark:hover:!univer-bg-gray-600",type:"button",role:"button",onClick:l,children:v.jsx(al,{})}),v.jsx("span",{className:"univer-mx-1",children:s}),v.jsx("button",{"data-u-comp":"pager-right-arrow",className:"univer-inline-flex univer-size-4 univer-cursor-pointer univer-items-center univer-rounded univer-border-none univer-bg-transparent univer-p-0 hover:univer-bg-gray-50 dark:hover:!univer-bg-gray-600",type:"button",role:"button",onClick:f,children:v.jsx(Vr,{})})]}):v.jsx("div",{className:"univer-mx-1",children:s})})}const Qi=`
133
+ `}),i(e,t)]},n)})}),T&&F&&C&&(0,Pt.createPortal)((0,z.jsx)(`div`,{className:R(`univer-pointer-events-none univer-fixed univer-rounded-md univer-border univer-border-gray-200 univer-bg-white univer-shadow-lg dark:!univer-border-gray-700 dark:!univer-bg-gray-800`),style:{zIndex:2147483647,left:`${C.x}px`,top:`${C.y}px`,width:`${k.current.width}px`,height:`${k.current.height}px`,opacity:.95},children:x?(0,z.jsx)(`div`,{ref:A}):i(F,p.findIndex(e=>P(e)===P(F)))}),document.body)]})}function Hc(e){let t=e+`CollectionProvider`,[n,r]=xt(t),[i,a]=n(t,{collectionRef:{current:null},itemMap:new Map}),o=e=>{let{scope:t,children:n}=e,r=h.useRef(null),a=h.useRef(new Map).current;return(0,z.jsx)(i,{scope:t,itemMap:a,collectionRef:r,children:n})};o.displayName=t;let s=e+`CollectionSlot`,c=Ft(s),l=h.forwardRef((e,t)=>{let{scope:n,children:r}=e;return(0,z.jsx)(c,{ref:Re(t,a(s,n).collectionRef),children:r})});l.displayName=s;let u=e+`CollectionItemSlot`,d=`data-radix-collection-item`,f=Ft(u),p=h.forwardRef((e,t)=>{let{scope:n,children:r,...i}=e,o=h.useRef(null),s=Re(t,o),c=a(u,n);return h.useEffect(()=>(c.itemMap.set(o,{ref:o,...i}),()=>void c.itemMap.delete(o))),(0,z.jsx)(f,{[d]:``,ref:s,children:r})});p.displayName=u;function m(t){let n=a(e+`CollectionConsumer`,t);return h.useCallback(()=>{let e=n.collectionRef.current;if(!e)return[];let t=Array.from(e.querySelectorAll(`[${d}]`));return Array.from(n.itemMap.values()).sort((e,n)=>t.indexOf(e.ref.current)-t.indexOf(n.ref.current))},[n.collectionRef,n.itemMap])}return[{Provider:o,Slot:l,ItemSlot:p},m,r]}Map;var Uc=h.createContext(void 0);function Wc(e){let t=h.useContext(Uc);return e||t||`ltr`}var Gc=`rovingFocusGroup.onEntryFocus`,Kc={bubbles:!1,cancelable:!0},qc=`RovingFocusGroup`,[Jc,Yc,Xc]=Hc(qc),[Zc,Qc]=xt(qc,[Xc]),[$c,el]=Zc(qc),tl=h.forwardRef((e,t)=>(0,z.jsx)(Jc.Provider,{scope:e.__scopeRovingFocusGroup,children:(0,z.jsx)(Jc.Slot,{scope:e.__scopeRovingFocusGroup,children:(0,z.jsx)(nl,{...e,ref:t})})}));tl.displayName=qc;var nl=h.forwardRef((e,t)=>{let{__scopeRovingFocusGroup:n,orientation:r,loop:i=!1,dir:a,currentTabStopId:o,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:c,onEntryFocus:l,preventScrollOnEntryFocus:u=!1,...d}=e,f=h.useRef(null),p=Re(t,f),m=Wc(a),[g,_]=kt({prop:o,defaultProp:s==null?null:s,onChange:c,caller:qc}),[v,y]=h.useState(!1),b=Ut(l),x=Yc(n),S=h.useRef(!1),[C,w]=h.useState(0);return h.useEffect(()=>{let e=f.current;if(e)return e.addEventListener(Gc,b),()=>e.removeEventListener(Gc,b)},[b]),(0,z.jsx)($c,{scope:n,orientation:r,dir:m,loop:i,currentTabStopId:g,onItemFocus:h.useCallback(e=>_(e),[_]),onItemShiftTab:h.useCallback(()=>y(!0),[]),onFocusableItemAdd:h.useCallback(()=>w(e=>e+1),[]),onFocusableItemRemove:h.useCallback(()=>w(e=>e-1),[]),children:(0,z.jsx)(Vt.div,{tabIndex:v||C===0?-1:0,"data-orientation":r,...d,ref:p,style:{outline:`none`,...e.style},onMouseDown:B(e.onMouseDown,()=>{S.current=!0}),onFocus:B(e.onFocus,e=>{let t=!S.current;if(e.target===e.currentTarget&&t&&!v){let t=new CustomEvent(Gc,Kc);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){let e=x().filter(e=>e.focusable);cl([e.find(e=>e.active),e.find(e=>e.id===g),...e].filter(Boolean).map(e=>e.ref.current),u)}}S.current=!1}),onBlur:B(e.onBlur,()=>y(!1))})})}),rl=`RovingFocusGroupItem`,il=h.forwardRef((e,t)=>{let{__scopeRovingFocusGroup:n,focusable:r=!0,active:i=!1,tabStopId:a,children:o,...s}=e,c=Dt(),l=a||c,u=el(rl,n),d=u.currentTabStopId===l,f=Yc(n),{onFocusableItemAdd:p,onFocusableItemRemove:m,currentTabStopId:g}=u;return h.useEffect(()=>{if(r)return p(),()=>m()},[r,p,m]),(0,z.jsx)(Jc.ItemSlot,{scope:n,id:l,focusable:r,active:i,children:(0,z.jsx)(Vt.span,{tabIndex:d?0:-1,"data-orientation":u.orientation,...s,ref:t,onMouseDown:B(e.onMouseDown,e=>{r?u.onItemFocus(l):e.preventDefault()}),onFocus:B(e.onFocus,()=>u.onItemFocus(l)),onKeyDown:B(e.onKeyDown,e=>{if(e.key===`Tab`&&e.shiftKey){u.onItemShiftTab();return}if(e.target!==e.currentTarget)return;let t=sl(e,u.orientation,u.dir);if(t!==void 0){if(e.metaKey||e.ctrlKey||e.altKey||e.shiftKey)return;e.preventDefault();let n=f().filter(e=>e.focusable).map(e=>e.ref.current);if(t===`last`)n.reverse();else if(t===`prev`||t===`next`){t===`prev`&&n.reverse();let r=n.indexOf(e.currentTarget);n=u.loop?ll(n,r+1):n.slice(r+1)}setTimeout(()=>cl(n))}}),children:typeof o==`function`?o({isCurrentTabStop:d,hasTabStop:g!=null}):o})})});il.displayName=rl;var al={ArrowLeft:`prev`,ArrowUp:`prev`,ArrowRight:`next`,ArrowDown:`next`,PageUp:`first`,Home:`first`,PageDown:`last`,End:`last`};function ol(e,t){return t===`rtl`?e===`ArrowLeft`?`ArrowRight`:e===`ArrowRight`?`ArrowLeft`:e:e}function sl(e,t,n){let r=ol(e.key,n);if(!(t===`vertical`&&[`ArrowLeft`,`ArrowRight`].includes(r))&&!(t===`horizontal`&&[`ArrowUp`,`ArrowDown`].includes(r)))return al[r]}function cl(e,t=!1){let n=document.activeElement;for(let r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}function ll(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var ul=tl,dl=il,fl=[`Enter`,` `],pl=[`ArrowDown`,`PageUp`,`Home`],ml=[`ArrowUp`,`PageDown`,`End`],hl=[...pl,...ml],gl={ltr:[...fl,`ArrowRight`],rtl:[...fl,`ArrowLeft`]},_l={ltr:[`ArrowLeft`],rtl:[`ArrowRight`]},vl=`Menu`,[yl,bl,xl]=Hc(vl),[Sl,Cl]=xt(vl,[xl,Rs,Qc]),wl=Rs(),Tl=Qc(),[El,Dl]=Sl(vl),[Ol,kl]=Sl(vl),Al=e=>{let{__scopeMenu:t,open:n=!1,children:r,dir:i,onOpenChange:a,modal:o=!0}=e,s=wl(t),[c,l]=h.useState(null),u=h.useRef(!1),d=Ut(a),f=Wc(i);return h.useEffect(()=>{let e=()=>{u.current=!0,document.addEventListener(`pointerdown`,t,{capture:!0,once:!0}),document.addEventListener(`pointermove`,t,{capture:!0,once:!0})},t=()=>u.current=!1;return document.addEventListener(`keydown`,e,{capture:!0}),()=>{document.removeEventListener(`keydown`,e,{capture:!0}),document.removeEventListener(`pointerdown`,t,{capture:!0}),document.removeEventListener(`pointermove`,t,{capture:!0})}},[]),(0,z.jsx)(ec,{...s,children:(0,z.jsx)(El,{scope:t,open:n,onOpenChange:d,content:c,onContentChange:l,children:(0,z.jsx)(Ol,{scope:t,onClose:h.useCallback(()=>d(!1),[d]),isUsingKeyboardRef:u,dir:f,modal:o,children:r})})})};Al.displayName=vl;var jl=`MenuAnchor`,Ml=h.forwardRef((e,t)=>{let{__scopeMenu:n,...r}=e,i=wl(n);return(0,z.jsx)(tc,{...i,...r,ref:t})});Ml.displayName=jl;var Nl=`MenuPortal`,[Pl,Fl]=Sl(Nl,{forceMount:void 0}),Il=e=>{let{__scopeMenu:t,forceMount:n,children:r,container:i}=e,a=Dl(Nl,t);return(0,z.jsx)(Pl,{scope:t,forceMount:n,children:(0,z.jsx)(wn,{present:n||a.open,children:(0,z.jsx)(Sn,{asChild:!0,container:i,children:r})})})};Il.displayName=Nl;var Ll=`MenuContent`,[K,q]=Sl(Ll),J=h.forwardRef((e,t)=>{let n=Fl(Ll,e.__scopeMenu),{forceMount:r=n.forceMount,...i}=e,a=Dl(Ll,e.__scopeMenu),o=kl(Ll,e.__scopeMenu);return(0,z.jsx)(yl.Provider,{scope:e.__scopeMenu,children:(0,z.jsx)(wn,{present:r||a.open,children:(0,z.jsx)(yl.Slot,{scope:e.__scopeMenu,children:o.modal?(0,z.jsx)(Y,{...i,ref:t}):(0,z.jsx)(X,{...i,ref:t})})})})}),Y=h.forwardRef((e,t)=>{let n=Dl(Ll,e.__scopeMenu),r=h.useRef(null),i=Re(t,r);return h.useEffect(()=>{let e=r.current;if(e)return(0,$r.hideOthers)(e)},[]),(0,z.jsx)(zl,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:B(e.onFocusOutside,e=>e.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)})}),X=h.forwardRef((e,t)=>{let n=Dl(Ll,e.__scopeMenu);return(0,z.jsx)(zl,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)})}),Rl=Ft(`MenuContent.ScrollLock`),zl=h.forwardRef((e,t)=>{let{__scopeMenu:n,loop:r=!1,trapFocus:i,onOpenAutoFocus:a,onCloseAutoFocus:o,disableOutsidePointerEvents:s,onEntryFocus:c,onEscapeKeyDown:l,onPointerDownOutside:u,onFocusOutside:d,onInteractOutside:f,onDismiss:p,disableOutsideScroll:m,...g}=e,_=Dl(Ll,n),v=kl(Ll,n),y=wl(n),b=Tl(n),x=bl(n),[S,C]=h.useState(null),w=h.useRef(null),T=Re(t,w,_.onContentChange),E=h.useRef(0),D=h.useRef(``),O=h.useRef(0),k=h.useRef(null),A=h.useRef(`right`),j=h.useRef(0),ee=m?Qr.RemoveScroll:h.Fragment,M=m?{as:Rl,allowPinchZoom:!0}:void 0,N=e=>{var t,n;let r=D.current+e,i=x().filter(e=>!e.disabled),a=document.activeElement,o=(t=i.find(e=>e.ref.current===a))==null?void 0:t.textValue,s=Cu(i.map(e=>e.textValue),r,o),c=(n=i.find(e=>e.textValue===s))==null?void 0:n.ref.current;(function e(t){D.current=t,window.clearTimeout(E.current),t!==``&&(E.current=window.setTimeout(()=>e(``),1e3))})(r),c&&setTimeout(()=>c.focus())};h.useEffect(()=>()=>window.clearTimeout(E.current),[]),kn();let P=h.useCallback(e=>{var t,n;return A.current===((t=k.current)==null?void 0:t.side)&&Tu(e,(n=k.current)==null?void 0:n.area)},[]);return(0,z.jsx)(K,{scope:n,searchRef:D,onItemEnter:h.useCallback(e=>{P(e)&&e.preventDefault()},[P]),onItemLeave:h.useCallback(e=>{var t;P(e)||((t=w.current)==null||t.focus(),C(null))},[P]),onTriggerLeave:h.useCallback(e=>{P(e)&&e.preventDefault()},[P]),pointerGraceTimerRef:O,onPointerGraceIntentChange:h.useCallback(e=>{k.current=e},[]),children:(0,z.jsx)(ee,{...M,children:(0,z.jsx)(ln,{asChild:!0,trapped:i,onMountAutoFocus:B(a,e=>{var t;e.preventDefault(),(t=w.current)==null||t.focus({preventScroll:!0})}),onUnmountAutoFocus:o,children:(0,z.jsx)(Zt,{asChild:!0,disableOutsidePointerEvents:s,onEscapeKeyDown:l,onPointerDownOutside:u,onFocusOutside:d,onInteractOutside:f,onDismiss:p,children:(0,z.jsx)(ul,{asChild:!0,...b,dir:v.dir,orientation:`vertical`,loop:r,currentTabStopId:S,onCurrentTabStopIdChange:C,onEntryFocus:B(c,e=>{v.isUsingKeyboardRef.current||e.preventDefault()}),preventScrollOnEntryFocus:!0,children:(0,z.jsx)(nc,{role:`menu`,"aria-orientation":`vertical`,"data-state":vu(_.open),"data-radix-menu-content":``,dir:v.dir,...y,...g,ref:T,style:{outline:`none`,...g.style},onKeyDown:B(g.onKeyDown,e=>{let t=e.target.closest(`[data-radix-menu-content]`)===e.currentTarget,n=e.ctrlKey||e.altKey||e.metaKey,r=e.key.length===1;t&&(e.key===`Tab`&&e.preventDefault(),!n&&r&&N(e.key));let i=w.current;if(e.target!==i||!hl.includes(e.key))return;e.preventDefault();let a=x().filter(e=>!e.disabled).map(e=>e.ref.current);ml.includes(e.key)&&a.reverse(),xu(a)}),onBlur:B(e.onBlur,e=>{e.currentTarget.contains(e.target)||(window.clearTimeout(E.current),D.current=``)}),onPointerMove:B(e.onPointerMove,Eu(e=>{let t=e.target,n=j.current!==e.clientX;e.currentTarget.contains(t)&&n&&(A.current=e.clientX>j.current?`right`:`left`,j.current=e.clientX)}))})})})})})})});J.displayName=Ll;var Bl=`MenuGroup`,Vl=h.forwardRef((e,t)=>{let{__scopeMenu:n,...r}=e;return(0,z.jsx)(Vt.div,{role:`group`,...r,ref:t})});Vl.displayName=Bl;var Hl=`MenuLabel`,Ul=h.forwardRef((e,t)=>{let{__scopeMenu:n,...r}=e;return(0,z.jsx)(Vt.div,{...r,ref:t})});Ul.displayName=Hl;var Wl=`MenuItem`,Gl=`menu.itemSelect`,Kl=h.forwardRef((e,t)=>{let{disabled:n=!1,onSelect:r,...i}=e,a=h.useRef(null),o=kl(Wl,e.__scopeMenu),s=q(Wl,e.__scopeMenu),c=Re(t,a),l=h.useRef(!1),u=()=>{let e=a.current;if(!n&&e){let t=new CustomEvent(Gl,{bubbles:!0,cancelable:!0});e.addEventListener(Gl,e=>r==null?void 0:r(e),{once:!0}),Ht(e,t),t.defaultPrevented?l.current=!1:o.onClose()}};return(0,z.jsx)(ql,{...i,ref:c,disabled:n,onClick:B(e.onClick,u),onPointerDown:t=>{var n;(n=e.onPointerDown)==null||n.call(e,t),l.current=!0},onPointerUp:B(e.onPointerUp,e=>{var t;l.current||(t=e.currentTarget)==null||t.click()}),onKeyDown:B(e.onKeyDown,e=>{let t=s.searchRef.current!==``;n||t&&e.key===` `||fl.includes(e.key)&&(e.currentTarget.click(),e.preventDefault())})})});Kl.displayName=Wl;var ql=h.forwardRef((e,t)=>{let{__scopeMenu:n,disabled:r=!1,textValue:i,...a}=e,o=q(Wl,n),s=Tl(n),c=h.useRef(null),l=Re(t,c),[u,d]=h.useState(!1),[f,p]=h.useState(``);return h.useEffect(()=>{let e=c.current;if(e){var t;p(((t=e.textContent)==null?``:t).trim())}},[a.children]),(0,z.jsx)(yl.ItemSlot,{scope:n,disabled:r,textValue:i==null?f:i,children:(0,z.jsx)(dl,{asChild:!0,...s,focusable:!r,children:(0,z.jsx)(Vt.div,{role:`menuitem`,"data-highlighted":u?``:void 0,"aria-disabled":r||void 0,"data-disabled":r?``:void 0,...a,ref:l,onPointerMove:B(e.onPointerMove,Eu(e=>{r?o.onItemLeave(e):(o.onItemEnter(e),e.defaultPrevented||e.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:B(e.onPointerLeave,Eu(e=>o.onItemLeave(e))),onFocus:B(e.onFocus,()=>d(!0)),onBlur:B(e.onBlur,()=>d(!1))})})})}),Jl=`MenuCheckboxItem`,Yl=h.forwardRef((e,t)=>{let{checked:n=!1,onCheckedChange:r,...i}=e;return(0,z.jsx)(ru,{scope:e.__scopeMenu,checked:n,children:(0,z.jsx)(Kl,{role:`menuitemcheckbox`,"aria-checked":yu(n)?`mixed`:n,...i,ref:t,"data-state":bu(n),onSelect:B(i.onSelect,()=>r==null?void 0:r(yu(n)?!0:!n),{checkForDefaultPrevented:!1})})})});Yl.displayName=Jl;var Xl=`MenuRadioGroup`,[Zl,Ql]=Sl(Xl,{value:void 0,onValueChange:()=>{}}),$l=h.forwardRef((e,t)=>{let{value:n,onValueChange:r,...i}=e,a=Ut(r);return(0,z.jsx)(Zl,{scope:e.__scopeMenu,value:n,onValueChange:a,children:(0,z.jsx)(Vl,{...i,ref:t})})});$l.displayName=Xl;var eu=`MenuRadioItem`,tu=h.forwardRef((e,t)=>{let{value:n,...r}=e,i=Ql(eu,e.__scopeMenu),a=n===i.value;return(0,z.jsx)(ru,{scope:e.__scopeMenu,checked:a,children:(0,z.jsx)(Kl,{role:`menuitemradio`,"aria-checked":a,...r,ref:t,"data-state":bu(a),onSelect:B(r.onSelect,()=>{var e;return(e=i.onValueChange)==null?void 0:e.call(i,n)},{checkForDefaultPrevented:!1})})})});tu.displayName=eu;var nu=`MenuItemIndicator`,[ru,iu]=Sl(nu,{checked:!1}),au=h.forwardRef((e,t)=>{let{__scopeMenu:n,forceMount:r,...i}=e,a=iu(nu,n);return(0,z.jsx)(wn,{present:r||yu(a.checked)||a.checked===!0,children:(0,z.jsx)(Vt.span,{...i,ref:t,"data-state":bu(a.checked)})})});au.displayName=nu;var ou=`MenuSeparator`,su=h.forwardRef((e,t)=>{let{__scopeMenu:n,...r}=e;return(0,z.jsx)(Vt.div,{role:`separator`,"aria-orientation":`horizontal`,...r,ref:t})});su.displayName=ou;var cu=`MenuArrow`,lu=h.forwardRef((e,t)=>{let{__scopeMenu:n,...r}=e,i=wl(n);return(0,z.jsx)(rc,{...i,...r,ref:t})});lu.displayName=cu;var uu=`MenuSub`,[du,fu]=Sl(uu),pu=e=>{let{__scopeMenu:t,children:n,open:r=!1,onOpenChange:i}=e,a=Dl(uu,t),o=wl(t),[s,c]=h.useState(null),[l,u]=h.useState(null),d=Ut(i);return h.useEffect(()=>(a.open===!1&&d(!1),()=>d(!1)),[a.open,d]),(0,z.jsx)(ec,{...o,children:(0,z.jsx)(El,{scope:t,open:r,onOpenChange:d,content:l,onContentChange:u,children:(0,z.jsx)(du,{scope:t,contentId:Dt(),triggerId:Dt(),trigger:s,onTriggerChange:c,children:n})})})};pu.displayName=uu;var mu=`MenuSubTrigger`,hu=h.forwardRef((e,t)=>{let n=Dl(mu,e.__scopeMenu),r=kl(mu,e.__scopeMenu),i=fu(mu,e.__scopeMenu),a=q(mu,e.__scopeMenu),o=h.useRef(null),{pointerGraceTimerRef:s,onPointerGraceIntentChange:c}=a,l={__scopeMenu:e.__scopeMenu},u=h.useCallback(()=>{o.current&&window.clearTimeout(o.current),o.current=null},[]);return h.useEffect(()=>u,[u]),h.useEffect(()=>{let e=s.current;return()=>{window.clearTimeout(e),c(null)}},[s,c]),(0,z.jsx)(Ml,{asChild:!0,...l,children:(0,z.jsx)(ql,{id:i.triggerId,"aria-haspopup":`menu`,"aria-expanded":n.open,"aria-controls":i.contentId,"data-state":vu(n.open),...e,ref:Le(t,i.onTriggerChange),onClick:t=>{var r;(r=e.onClick)==null||r.call(e,t),!(e.disabled||t.defaultPrevented)&&(t.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:B(e.onPointerMove,Eu(t=>{a.onItemEnter(t),!t.defaultPrevented&&!e.disabled&&!n.open&&!o.current&&(a.onPointerGraceIntentChange(null),o.current=window.setTimeout(()=>{n.onOpenChange(!0),u()},100))})),onPointerLeave:B(e.onPointerLeave,Eu(e=>{var t;u();let r=(t=n.content)==null?void 0:t.getBoundingClientRect();if(r){var i;let t=(i=n.content)==null?void 0:i.dataset.side,o=t===`right`,c=o?-5:5,l=r[o?`left`:`right`],u=r[o?`right`:`left`];a.onPointerGraceIntentChange({area:[{x:e.clientX+c,y:e.clientY},{x:l,y:r.top},{x:u,y:r.top},{x:u,y:r.bottom},{x:l,y:r.bottom}],side:t}),window.clearTimeout(s.current),s.current=window.setTimeout(()=>a.onPointerGraceIntentChange(null),300)}else{if(a.onTriggerLeave(e),e.defaultPrevented)return;a.onPointerGraceIntentChange(null)}})),onKeyDown:B(e.onKeyDown,t=>{let i=a.searchRef.current!==``;if(!(e.disabled||i&&t.key===` `)&&gl[r.dir].includes(t.key)){var o;n.onOpenChange(!0),(o=n.content)==null||o.focus(),t.preventDefault()}})})})});hu.displayName=mu;var gu=`MenuSubContent`,_u=h.forwardRef((e,t)=>{let n=Fl(Ll,e.__scopeMenu),{forceMount:r=n.forceMount,...i}=e,a=Dl(Ll,e.__scopeMenu),o=kl(Ll,e.__scopeMenu),s=fu(gu,e.__scopeMenu),c=h.useRef(null),l=Re(t,c);return(0,z.jsx)(yl.Provider,{scope:e.__scopeMenu,children:(0,z.jsx)(wn,{present:r||a.open,children:(0,z.jsx)(yl.Slot,{scope:e.__scopeMenu,children:(0,z.jsx)(zl,{id:s.contentId,"aria-labelledby":s.triggerId,...i,ref:l,align:`start`,side:o.dir===`rtl`?`left`:`right`,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:e=>{var t;o.isUsingKeyboardRef.current&&((t=c.current)==null||t.focus()),e.preventDefault()},onCloseAutoFocus:e=>e.preventDefault(),onFocusOutside:B(e.onFocusOutside,e=>{e.target!==s.trigger&&a.onOpenChange(!1)}),onEscapeKeyDown:B(e.onEscapeKeyDown,e=>{o.onClose(),e.preventDefault()}),onKeyDown:B(e.onKeyDown,e=>{let t=e.currentTarget.contains(e.target),n=_l[o.dir].includes(e.key);if(t&&n){var r;a.onOpenChange(!1),(r=s.trigger)==null||r.focus(),e.preventDefault()}})})})})})});_u.displayName=gu;function vu(e){return e?`open`:`closed`}function yu(e){return e===`indeterminate`}function bu(e){return yu(e)?`indeterminate`:e?`checked`:`unchecked`}function xu(e){let t=document.activeElement;for(let n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function Su(e,t){return e.map((n,r)=>e[(t+r)%e.length])}function Cu(e,t,n){let r=t.length>1&&Array.from(t).every(e=>e===t[0])?t[0]:t,i=n?e.indexOf(n):-1,a=Su(e,Math.max(i,0));r.length===1&&(a=a.filter(e=>e!==n));let o=a.find(e=>e.toLowerCase().startsWith(r.toLowerCase()));return o===n?void 0:o}function wu(e,t){let{x:n,y:r}=e,i=!1;for(let e=0,a=t.length-1;e<t.length;a=e++){let o=t[e],s=t[a],c=o.x,l=o.y,u=s.x,d=s.y;l>r!=d>r&&n<(u-c)*(r-l)/(d-l)+c&&(i=!i)}return i}function Tu(e,t){return t?wu({x:e.clientX,y:e.clientY},t):!1}function Eu(e){return t=>t.pointerType===`mouse`?e(t):void 0}var Du=Al,Ou=Ml,ku=Il,Au=J,ju=Vl,Mu=Ul,Nu=Kl,Pu=Yl,Fu=$l,Iu=tu,Lu=au,Ru=su,zu=lu,Bu=pu,Vu=hu,Hu=_u,Uu=`DropdownMenu`,[Z,Wu]=xt(Uu,[Cl]),Gu=Cl(),[Ku,qu]=Z(Uu),Ju=e=>{let{__scopeDropdownMenu:t,children:n,dir:r,open:i,defaultOpen:a,onOpenChange:o,modal:s=!0}=e,c=Gu(t),l=h.useRef(null),[u,d]=kt({prop:i,defaultProp:a==null?!1:a,onChange:o,caller:Uu});return(0,z.jsx)(Ku,{scope:t,triggerId:Dt(),triggerRef:l,contentId:Dt(),open:u,onOpenChange:d,onOpenToggle:h.useCallback(()=>d(e=>!e),[d]),modal:s,children:(0,z.jsx)(Du,{...c,open:u,onOpenChange:d,dir:r,modal:s,children:n})})};Ju.displayName=Uu;var Yu=`DropdownMenuTrigger`,Xu=h.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,disabled:r=!1,...i}=e,a=qu(Yu,n),o=Gu(n);return(0,z.jsx)(Ou,{asChild:!0,...o,children:(0,z.jsx)(Vt.button,{type:`button`,id:a.triggerId,"aria-haspopup":`menu`,"aria-expanded":a.open,"aria-controls":a.open?a.contentId:void 0,"data-state":a.open?`open`:`closed`,"data-disabled":r?``:void 0,disabled:r,...i,ref:Le(t,a.triggerRef),onPointerDown:B(e.onPointerDown,e=>{!r&&e.button===0&&e.ctrlKey===!1&&(a.onOpenToggle(),a.open||e.preventDefault())}),onKeyDown:B(e.onKeyDown,e=>{r||([`Enter`,` `].includes(e.key)&&a.onOpenToggle(),e.key===`ArrowDown`&&a.onOpenChange(!0),[`Enter`,` `,`ArrowDown`].includes(e.key)&&e.preventDefault())})})})});Xu.displayName=Yu;var Zu=`DropdownMenuPortal`,Qu=e=>{let{__scopeDropdownMenu:t,...n}=e,r=Gu(t);return(0,z.jsx)(ku,{...r,...n})};Qu.displayName=Zu;var $u=`DropdownMenuContent`,ed=h.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=qu($u,n),a=Gu(n),o=h.useRef(!1);return(0,z.jsx)(Au,{id:i.contentId,"aria-labelledby":i.triggerId,...a,...r,ref:t,onCloseAutoFocus:B(e.onCloseAutoFocus,e=>{var t;o.current||(t=i.triggerRef.current)==null||t.focus(),o.current=!1,e.preventDefault()}),onInteractOutside:B(e.onInteractOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0,r=t.button===2||n;(!i.modal||r)&&(o.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":`var(--radix-popper-transform-origin)`,"--radix-dropdown-menu-content-available-width":`var(--radix-popper-available-width)`,"--radix-dropdown-menu-content-available-height":`var(--radix-popper-available-height)`,"--radix-dropdown-menu-trigger-width":`var(--radix-popper-anchor-width)`,"--radix-dropdown-menu-trigger-height":`var(--radix-popper-anchor-height)`}})});ed.displayName=$u;var td=`DropdownMenuGroup`,nd=h.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=Gu(n);return(0,z.jsx)(ju,{...i,...r,ref:t})});nd.displayName=td;var rd=`DropdownMenuLabel`,id=h.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=Gu(n);return(0,z.jsx)(Mu,{...i,...r,ref:t})});id.displayName=rd;var ad=`DropdownMenuItem`,od=h.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=Gu(n);return(0,z.jsx)(Nu,{...i,...r,ref:t})});od.displayName=ad;var sd=`DropdownMenuCheckboxItem`,cd=h.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=Gu(n);return(0,z.jsx)(Pu,{...i,...r,ref:t})});cd.displayName=sd;var ld=`DropdownMenuRadioGroup`,ud=h.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=Gu(n);return(0,z.jsx)(Fu,{...i,...r,ref:t})});ud.displayName=ld;var dd=`DropdownMenuRadioItem`,fd=h.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=Gu(n);return(0,z.jsx)(Iu,{...i,...r,ref:t})});fd.displayName=dd;var pd=`DropdownMenuItemIndicator`,md=h.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=Gu(n);return(0,z.jsx)(Lu,{...i,...r,ref:t})});md.displayName=pd;var hd=`DropdownMenuSeparator`,gd=h.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=Gu(n);return(0,z.jsx)(Ru,{...i,...r,ref:t})});gd.displayName=hd;var _d=`DropdownMenuArrow`,vd=h.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=Gu(n);return(0,z.jsx)(zu,{...i,...r,ref:t})});vd.displayName=_d;var Q=e=>{let{__scopeDropdownMenu:t,children:n,open:r,onOpenChange:i,defaultOpen:a}=e,o=Gu(t),[s,c]=kt({prop:r,defaultProp:a==null?!1:a,onChange:i,caller:`DropdownMenuSub`});return(0,z.jsx)(Bu,{...o,open:s,onOpenChange:c,children:n})},yd=`DropdownMenuSubTrigger`,bd=h.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=Gu(n);return(0,z.jsx)(Vu,{...i,...r,ref:t})});bd.displayName=yd;var xd=`DropdownMenuSubContent`,Sd=h.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=Gu(n);return(0,z.jsx)(Hu,{...i,...r,ref:t,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":`var(--radix-popper-transform-origin)`,"--radix-dropdown-menu-content-available-width":`var(--radix-popper-available-width)`,"--radix-dropdown-menu-content-available-height":`var(--radix-popper-available-height)`,"--radix-dropdown-menu-trigger-width":`var(--radix-popper-anchor-width)`,"--radix-dropdown-menu-trigger-height":`var(--radix-popper-anchor-height)`}})});Sd.displayName=xd;var Cd=Ju,wd=Xu,Td=Qu,Ed=ed,Dd=od,Od=cd,kd=ud,Ad=fd,jd=md,$=gd,Md=Q,Nd=bd,Pd=Sd;function Fd({...e}){return(0,z.jsx)(Cd,{"data-slot":`dropdown-menu`,...e})}function Id({...e}){return(0,z.jsx)(Td,{"data-slot":`dropdown-menu-portal`,...e})}function Ld({...e}){return(0,z.jsx)(wd,{"data-slot":`dropdown-menu-trigger`,...e})}function Rd({...e}){return(0,z.jsx)(Md,{"data-slot":`dropdown-menu-sub`,...e})}function zd({...e}){return(0,z.jsx)(kd,{"data-slot":`dropdown-menu-radio-group`,...e})}function Bd({className:e,inset:t,children:n,...r}){return(0,z.jsxs)(Nd,{"data-slot":`dropdown-menu-sub-trigger`,"data-inset":t,className:R(`univer-flex univer-cursor-default univer-select-none univer-items-center univer-justify-between univer-gap-2 univer-rounded univer-px-2 univer-py-1.5 univer-text-sm univer-outline-none data-[state=open]:univer-bg-gray-100 focus:univer-bg-gray-100 dark:data-[state=open]:!univer-bg-gray-600 dark:focus:!univer-bg-gray-600 [&_svg]:univer-pointer-events-none [&_svg]:univer-size-4 [&_svg]:univer-shrink-0`,e),...r,children:[n,(0,z.jsx)(f.MoreRightIcon,{className:`ml-auto`})]})}function Vd({className:e,...t}){return(0,z.jsx)(Pd,{"data-slot":`dropdown-menu-sub-content`,className:R(`data-[state=open]:univer-animate-in data-[state=open]:univer-fade-in-0 data-[state=open]:univer-zoom-in-95 data-[state=closed]:univer-animate-out data-[state=closed]:univer-fade-out-0 data-[state=closed]:univer-zoom-out-95 data-[side=bottom]:univer-slide-in-from-top-2 data-[side=left]:univer-slide-in-from-right-2 data-[side=right]:univer-slide-in-from-left-2 data-[side=top]:univer-slide-in-from-bottom-2 univer-z-[1080] univer-box-border univer-max-h-[--radix-popper-available-height] univer-overflow-y-auto univer-rounded-md univer-bg-white univer-p-1.5 univer-text-gray-900 univer-shadow-md dark:!univer-bg-gray-700 dark:!univer-text-white`,at,rt,e),...t})}function Hd({className:e,sideOffset:t=4,...n}){return(0,z.jsx)(Td,{children:(0,z.jsx)(Ed,{"data-slot":`dropdown-menu-content`,sideOffset:t,className:R(`data-[state=open]:univer-animate-in data-[state=open]:univer-fade-in-0 data-[state=open]:univer-zoom-in-95 data-[state=closed]:univer-animate-out data-[state=closed]:univer-fade-out-0 data-[state=closed]:univer-zoom-out-95 data-[side=bottom]:univer-slide-in-from-top-2 data-[side=left]:univer-slide-in-from-right-2 data-[side=right]:univer-slide-in-from-left-2 data-[side=top]:univer-slide-in-from-bottom-2 univer-z-[1080] univer-box-border univer-max-h-[--radix-popper-available-height] univer-overflow-y-auto univer-rounded-md univer-bg-white univer-p-1.5 univer-text-gray-900 univer-shadow-md dark:!univer-bg-gray-700 dark:!univer-text-white`,at,rt,e),...n})})}function Ud({className:e,inset:t,variant:n=`default`,...r}){return(0,z.jsx)(Dd,{"data-slot":`dropdown-menu-item`,"data-inset":t,"data-variant":n,className:R(`univer-relative univer-flex univer-cursor-default univer-select-none univer-items-center univer-gap-2 univer-rounded univer-px-2 univer-py-1.5 univer-text-sm univer-outline-none univer-transition-colors data-[disabled]:univer-pointer-events-none data-[disabled]:univer-opacity-50 focus:univer-bg-gray-100 dark:focus:!univer-bg-gray-600 [&>svg]:univer-size-4 [&>svg]:univer-shrink-0`,e),...r})}function Wd({className:e,children:t,hideIndicator:n,checked:r,...i}){return(0,z.jsxs)(Od,{"data-slot":`dropdown-menu-checkbox-item`,className:R(`univer-relative univer-flex univer-cursor-default univer-select-none univer-items-center univer-rounded univer-py-1.5 univer-pr-2 univer-text-sm univer-outline-none univer-transition-colors data-[disabled]:univer-pointer-events-none data-[disabled]:univer-opacity-50 focus:univer-bg-gray-100 dark:focus:!univer-bg-gray-600`,{"univer-pl-8":!n,"univer-pl-2":n},e),checked:r,...i,children:[!n&&(0,z.jsx)(`span`,{className:`univer-absolute univer-left-2 univer-flex univer-size-3.5 univer-items-center univer-justify-center`,children:(0,z.jsx)(jd,{children:(0,z.jsx)(f.CheckMarkIcon,{className:`univer-block univer-size-4 univer-fill-current univer-text-primary-600`})})}),t]})}function Gd({className:e,children:t,hideIndicator:n,...r}){return(0,z.jsxs)(Ad,{"data-slot":`dropdown-menu-radio-item`,className:R(`univer-relative univer-flex univer-cursor-default univer-select-none univer-items-center univer-rounded univer-py-1.5 univer-pr-2 univer-text-sm univer-outline-none univer-transition-colors data-[disabled]:univer-pointer-events-none data-[disabled]:univer-opacity-50 focus:univer-bg-gray-100 dark:focus:!univer-bg-gray-600`,{"univer-pl-8":!n,"univer-pl-2":n},e),...r,children:[!n&&(0,z.jsx)(`span`,{className:`univer-absolute univer-left-2 univer-flex univer-size-3.5 univer-items-center univer-justify-center`,children:(0,z.jsx)(jd,{children:(0,z.jsx)(f.CheckMarkIcon,{className:`univer-block univer-size-4 univer-fill-current univer-text-primary-600`})})}),t]})}function Kd({className:e,...t}){return(0,z.jsx)($,{className:R(`-univer-mx-1 univer-my-1 univer-h-px univer-bg-gray-200 dark:!univer-bg-gray-600`,e),...t})}function qd(e){let{children:t,items:n,disabled:r,open:i,onOpenChange:a,...o}=e,[s,c]=(0,h.useState)(!1),l=i!==void 0,u=l?i:s;function d(e){r||(l||c(e),a==null||a(e))}function f(e,t){let{className:n,type:r}=e;if(r===`separator`)return(0,z.jsx)(Kd,{className:n},t);if(r===`radio`)return(0,z.jsx)(zd,{className:n,value:e.value,onValueChange:e.onSelect,children:e.options.map((t,n)=>{if(`type`in t){if(t.type===`separator`)return(0,z.jsx)(Kd,{className:t.className},n)}else{if(t.value===void 0)throw Error("[DropdownMenu]: `value` is required");return(0,z.jsx)(Gd,{value:t.value,disabled:t.disabled,hideIndicator:e.hideIndicator,children:t.label},t.value)}return null})},t);if(r===`checkbox`)return(0,z.jsx)(Wd,{className:n,disabled:e.disabled,checked:e.checked,onSelect:()=>{var t;(t=e.onSelect)==null||t.call(e,e.value)},children:e.label},t);if(r===`item`)return(0,z.jsx)(Ud,{className:n,disabled:e.disabled,onSelect:()=>{var t;(t=e.onSelect)==null||t.call(e,e)},children:e.children},t);if(r===`subItem`){var i;return(0,z.jsxs)(Rd,{children:[(0,z.jsx)(Bd,{children:e.children}),(0,z.jsx)(Id,{children:(0,z.jsx)(Vd,{sideOffset:12,children:(i=e.options)==null?void 0:i.map((e,t)=>f(e,t))})})]},t)}}return(0,z.jsxs)(Fd,{modal:!1,open:u,onOpenChange:d,children:[(0,z.jsx)(Ld,{asChild:!0,children:t}),(0,z.jsx)(Hd,{className:`univer-text-sm`,collisionPadding:{top:12,bottom:12},onWheel:e=>e.stopPropagation(),...o,children:n.map((e,t)=>f(e,t))})]})}const Jd=(0,h.createContext)(!1),Yd=e=>{let{label:t,desc:n,children:r,style:i,className:a,error:o,contentStyle:s,collapsable:c=!1,defaultCollapsed:l=!1}=e,[u,d]=(0,h.useState)(l);return(0,z.jsx)(Jd.Provider,{value:!0,children:(0,z.jsxs)(`div`,{"data-u-comp":`form-layout`,className:R(`univer-mb-3 univer-flex univer-flex-col`,a),style:i,children:[t&&(0,z.jsxs)(`div`,{className:R(`univer-mb-2 univer-flex univer-min-h-3.5 univer-items-center univer-text-sm univer-text-gray-900 dark:!univer-text-white`,{"univer-cursor-pointer":c}),onClick:()=>d(!u),children:[t,c&&(0,z.jsx)(f.MoreUpIcon,{className:R(`univer-ml-1 univer-transition-transform`,{"univer-rotate-180":u})})]}),u&&c?null:(0,z.jsxs)(z.Fragment,{children:[n&&(0,z.jsx)(`div`,{className:`univer-mt-1 univer-text-sm univer-text-gray-600 dark:!univer-text-gray-200`,children:n}),r?(0,z.jsxs)(`div`,{className:R(`last:univer-mb-0 [&_[data-u-comp=input]]:univer-w-full [&_[data-u-comp=select]]:univer-w-full`,{"[&_[data-u-comp=input]]:univer-border-red-500":o,"[&_[data-u-comp=select]]:univer-border-red-500":o}),style:s,children:[r,o?(0,z.jsx)(`div`,{className:`univer-mt-1 univer-text-xs univer-text-red-500`,children:o}):null]}):null]})]})})},Xd=e=>(0,z.jsx)(`div`,{className:`univer-flex univer-justify-between [&_[data-u-comp=form-layout]]:univer-max-w-[calc(50%-8px)] [&_[data-u-comp=form-layout]]:univer-shrink [&_[data-u-comp=form-layout]]:univer-grow`,children:e.children});function Zd(e){let{className:t,value:n=0,total:r=0,loop:i,text:a,onChange:o}=e,s=(0,h.useMemo)(()=>a==null?`${n}/${r}`:a,[n,r,a]),c=r>0,l=()=>{n===1?i&&(o==null||o(r)):o==null||o(n-1)},u=()=>{n===r?i&&(o==null||o(1)):o==null||o(n+1)};return(0,z.jsx)(`div`,{"data-u-comp":`pager`,className:R(`univer-flex univer-flex-shrink-0 univer-items-center univer-text-sm univer-text-gray-700 dark:!univer-text-gray-400`,t),children:c?(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(`button`,{"data-u-comp":`pager-left-arrow`,className:`univer-inline-flex univer-size-4 univer-cursor-pointer univer-items-center univer-rounded univer-border-none univer-bg-transparent univer-p-0 hover:univer-bg-gray-50 dark:hover:!univer-bg-gray-600`,type:`button`,role:`button`,onClick:l,children:(0,z.jsx)(f.MoreLeftIcon,{})}),(0,z.jsx)(`span`,{className:`univer-mx-1`,children:s}),(0,z.jsx)(`button`,{"data-u-comp":`pager-right-arrow`,className:`univer-inline-flex univer-size-4 univer-cursor-pointer univer-items-center univer-rounded univer-border-none univer-bg-transparent univer-p-0 hover:univer-bg-gray-50 dark:hover:!univer-bg-gray-600`,type:`button`,role:`button`,onClick:u,children:(0,z.jsx)(f.MoreRightIcon,{})})]}):(0,z.jsx)(`div`,{className:`univer-mx-1`,children:s})})}const Qd=`
202
134
  univer-flex univer-cursor-pointer univer-items-center univer-justify-center univer-border-none
203
135
  univer-bg-transparent univer-p-0 univer-text-current
204
136
  hover:univer-text-white
205
- `;function lb(e){const{className:t,images:n,open:r,onOpenChange:o}=e,[i,a]=y.useState(!1),[s,c]=y.useState(0),[l,f]=y.useState(1),u=y.useRef(null),m=y.useMemo(()=>n[s],[s,n]);if(y.useEffect(()=>{r&&u.current&&u.current.focus()},[r]),y.useEffect(()=>{if(!r)return;const g=b=>{b.key==="Escape"&&(o==null||o(!1))};return window.addEventListener("keydown",g),()=>window.removeEventListener("keydown",g)},[r,o]),y.useEffect(()=>{if(r)a(!0);else{const g=setTimeout(()=>{a(!1)},150);return()=>clearTimeout(g)}},[r]),y.useEffect(()=>{if(!r)return;const g=b=>{b.preventDefault();const h=-b.deltaY*.001;f(x=>Math.min(Math.max(.5,x+h),2))};return window.addEventListener("wheel",g,{passive:!1}),()=>{window.removeEventListener("wheel",g)}},[r]),!r&&!i)return null;function p(g){if(g==="reset"){f(1);return}const b=l+g;b<.5||b>2||f(b)}return ut.createPortal(v.jsxs("div",{"data-u-comp":"gallery",role:"dialog","aria-modal":"true","aria-label":"Image gallery",tabIndex:-1,ref:u,className:W(`
206
- univer-absolute univer-inset-0 univer-z-[1080] univer-flex univer-size-full univer-select-none
207
- univer-items-center univer-justify-center
208
- `,{"univer-animate-in univer-fade-in":r,"univer-animate-out univer-fade-out":!r},t),children:[v.jsx("div",{className:"univer-absolute univer-inset-0 univer-size-full univer-bg-gray-900 univer-opacity-80","aria-hidden":"true",onClick:()=>o==null?void 0:o(!1)}),v.jsx("div",{className:"univer-relative",children:m&&v.jsx("img",{className:"univer-max-h-[40vh] univer-max-w-[60vw] univer-transition-transform univer-duration-300 univer-ease-out",style:{transform:`scale(${l})`},src:m,alt:`Image ${s+1} of ${n.length}`,draggable:!1})}),v.jsxs("footer",{className:"univer-absolute univer-bottom-6 univer-left-1/2 univer-flex -univer-translate-x-1/2 univer-items-center univer-gap-3 univer-rounded-full univer-bg-gray-800 univer-px-6 univer-py-3 univer-text-gray-400",children:[v.jsx(zd,{className:"!univer-text-gray-400 [&_[data-u-comp=pager-left-arrow]:hover]:!univer-bg-gray-600 [&_[data-u-comp=pager-right-arrow]:hover]:!univer-bg-gray-600",value:s+1,total:n.length,onChange:g=>c(g-1)}),v.jsx("button",{type:"button","aria-label":"Zoom in",className:Qi,onClick:()=>p(.25),children:v.jsx(dl,{"aria-hidden":"true"})}),v.jsx("button",{type:"button","aria-label":"Zoom out",className:Qi,onClick:()=>p(-.25),children:v.jsx(fl,{"aria-hidden":"true"})}),v.jsx("button",{type:"button","aria-label":"Reset zoom",className:Qi,onClick:()=>p("reset"),children:v.jsx(ul,{"aria-hidden":"true"})})]})]}),document.body)}const cb=za(`
137
+ `;function $d(e){let{className:t,images:n,open:r,onOpenChange:i}=e,[a,o]=(0,h.useState)(!1),[s,c]=(0,h.useState)(0),[l,u]=(0,h.useState)(1),d=(0,h.useRef)(null),p=(0,h.useMemo)(()=>n[s],[s,n]);if((0,h.useEffect)(()=>{r&&d.current&&d.current.focus()},[r]),(0,h.useEffect)(()=>{if(!r)return;let e=e=>{e.key===`Escape`&&(i==null||i(!1))};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[r,i]),(0,h.useEffect)(()=>{if(r)o(!0);else{let e=setTimeout(()=>{o(!1)},150);return()=>clearTimeout(e)}},[r]),(0,h.useEffect)(()=>{if(!r)return;let e=e=>{e.preventDefault();let t=-e.deltaY*.001;u(e=>Math.min(Math.max(.5,e+t),2))};return window.addEventListener(`wheel`,e,{passive:!1}),()=>{window.removeEventListener(`wheel`,e)}},[r]),!r&&!a)return null;function m(e){if(e===`reset`){u(1);return}let t=l+e;t<.5||t>2||u(t)}return(0,Pt.createPortal)((0,z.jsxs)(`div`,{"data-u-comp":`gallery`,role:`dialog`,"aria-modal":`true`,"aria-label":`Image gallery`,tabIndex:-1,ref:d,className:R(`univer-absolute univer-inset-0 univer-z-[1080] univer-flex univer-size-full univer-select-none univer-items-center univer-justify-center`,{"univer-animate-in univer-fade-in":r,"univer-animate-out univer-fade-out":!r},t),children:[(0,z.jsx)(`div`,{className:`univer-absolute univer-inset-0 univer-size-full univer-bg-gray-900 univer-opacity-80`,"aria-hidden":`true`,onClick:()=>i==null?void 0:i(!1)}),(0,z.jsx)(`div`,{className:`univer-relative`,children:p&&(0,z.jsx)(`img`,{className:`univer-max-h-[40vh] univer-max-w-[60vw] univer-transition-transform univer-duration-300 univer-ease-out`,style:{transform:`scale(${l})`},src:p,alt:`Image ${s+1} of ${n.length}`,draggable:!1})}),(0,z.jsxs)(`footer`,{className:`univer-absolute univer-bottom-6 univer-left-1/2 univer-flex -univer-translate-x-1/2 univer-items-center univer-gap-3 univer-rounded-full univer-bg-gray-800 univer-px-6 univer-py-3 univer-text-gray-400`,children:[(0,z.jsx)(Zd,{className:`!univer-text-gray-400 [&_[data-u-comp=pager-left-arrow]:hover]:!univer-bg-gray-600 [&_[data-u-comp=pager-right-arrow]:hover]:!univer-bg-gray-600`,value:s+1,total:n.length,onChange:e=>c(e-1)}),(0,z.jsx)(`button`,{type:`button`,"aria-label":`Zoom in`,className:Qd,onClick:()=>m(.25),children:(0,z.jsx)(f.ZoomInIcon,{"aria-hidden":`true`})}),(0,z.jsx)(`button`,{type:`button`,"aria-label":`Zoom out`,className:Qd,onClick:()=>m(-.25),children:(0,z.jsx)(f.ZoomOutIcon,{"aria-hidden":`true`})}),(0,z.jsx)(`button`,{type:`button`,"aria-label":`Reset zoom`,className:Qd,onClick:()=>m(`reset`),children:(0,z.jsx)(f.OneToOneIcon,{"aria-hidden":`true`})})]})]}),document.body)}const ef=Me(`
209
138
  univer-box-border univer-w-full univer-rounded-md univer-bg-white univer-transition-colors univer-duration-200
210
139
  placeholder:univer-text-gray-400
211
140
  focus:univer-border-primary-600 focus:univer-outline-none focus:univer-ring-2 focus:univer-ring-primary-50
212
141
  dark:!univer-bg-gray-700 dark:!univer-text-white
213
142
  dark:focus:!univer-ring-primary-900
214
- `,{variants:{size:{mini:"univer-h-7 univer-px-1.5 univer-text-sm",small:"univer-h-8 univer-px-2 univer-text-sm",middle:"univer-h-10 univer-px-3 univer-text-base",large:"univer-h-12 univer-px-4 univer-text-lg"}},defaultVariants:{size:"small"}}),Bd=y.forwardRef(({autoFocus:e=!1,className:t,style:n,type:r="text",placeholder:o,value:i,size:a="small",allowClear:s=!1,disabled:c=!1,onClick:l,onKeyDown:f,onChange:u,onFocus:m,onBlur:p,slot:g,inputClass:b,inputStyle:h,...x},E)=>{const w=H=>{H.stopPropagation(),u==null||u("")},C=H=>{u==null||u(H.target.value)},S=y.useMemo(()=>s&&i&&!c||g,[s,c,g,i]),[R,L]=y.useState(0),D=y.useRef(null);return y.useEffect(()=>{let H=null;return g&&D.current&&(H=new MutationObserver(()=>{D.current&&L(D.current.offsetWidth+8)}),H.observe(D.current,{childList:!0,subtree:!0}),L(D.current.offsetWidth+8)),()=>H==null?void 0:H.disconnect()},[D.current]),y.useEffect(()=>{s&&!(g&&D.current)&&L(26)},[]),v.jsxs("div",{"data-u-comp":"input",className:W("univer-relative univer-inline-flex univer-w-full univer-items-center univer-rounded-md",c&&"univer-cursor-not-allowed",t),style:n,children:[v.jsx("input",{ref:E,type:r,className:W(cb({size:a}),ct,c&&`
143
+ `,{variants:{size:{mini:`univer-h-7 univer-px-1.5 univer-text-sm`,small:`univer-h-8 univer-px-2 univer-text-sm`,middle:`univer-h-10 univer-px-3 univer-text-base`,large:`univer-h-12 univer-px-4 univer-text-lg`}},defaultVariants:{size:`small`}}),tf=(0,h.forwardRef)(({autoFocus:e=!1,className:t,style:n,type:r=`text`,placeholder:i,value:a,size:o=`small`,allowClear:s=!1,disabled:c=!1,onClick:l,onKeyDown:u,onChange:d,onFocus:p,onBlur:m,slot:g,inputClass:_,inputStyle:v,...y},b)=>{let x=e=>{e.stopPropagation(),d==null||d(``)},S=e=>{d==null||d(e.target.value)},C=(0,h.useMemo)(()=>s&&a&&!c||g,[s,c,g,a]),[w,T]=(0,h.useState)(0),E=(0,h.useRef)(null);return(0,h.useEffect)(()=>{let e=null;return g&&E.current&&(e=new MutationObserver(()=>{E.current&&T(E.current.offsetWidth+8)}),e.observe(E.current,{childList:!0,subtree:!0}),T(E.current.offsetWidth+8)),()=>e==null?void 0:e.disconnect()},[E.current]),(0,h.useEffect)(()=>{s&&!(g&&E.current)&&T(26)},[]),(0,z.jsxs)(`div`,{"data-u-comp":`input`,className:R(`univer-relative univer-inline-flex univer-w-full univer-items-center univer-rounded-md`,c&&`univer-cursor-not-allowed`,t),style:n,children:[(0,z.jsx)(`input`,{ref:b,type:r,className:R(ef({size:o}),at,c&&`
215
144
  univer-cursor-not-allowed univer-bg-gray-50 univer-text-gray-400
216
145
  dark:!univer-text-gray-500
217
- `,s&&!g&&"univer-pr-8",b),placeholder:o,value:i,disabled:c,autoFocus:e,onClick:l,onKeyDown:f,onChange:C,onFocus:m,onBlur:p,style:{...h,paddingRight:R},...x}),S&&v.jsxs("div",{className:"univer-absolute univer-right-2 univer-flex univer-items-center univer-gap-1 univer-rounded-full",ref:D,children:[g,s&&i&&!c&&v.jsx("button",{type:"button",onClick:w,className:"univer-flex univer-size-4 univer-cursor-pointer univer-items-center univer-rounded-full univer-border-none univer-bg-transparent univer-p-1 univer-text-gray-400 univer-transition-colors univer-duration-200 hover:univer-text-gray-500 focus:univer-outline-none",children:v.jsx(ii,{className:"univer-size-3"})})]})]})}),pa=y.forwardRef(({value:e,defaultValue:t,size:n="small",min:r=Number.MIN_SAFE_INTEGER,max:o=Number.MAX_SAFE_INTEGER,step:i=1,precision:a,formatter:s,parser:c,controls:l=!0,className:f,inputClassName:u,controlsClassName:m,disabled:p,onChange:g,onKeyDown:b,onPressEnter:h,onFocus:x,onBlur:E,allowEmpty:w=!1},C)=>{const[S,R]=y.useState(e!==void 0?e:t!==void 0?t:null),L=y.useRef(S),[D,H]=y.useState(A(S)),k=y.useRef(null),T=y.useRef(null),F=y.useRef(null),z=$=>{C&&(typeof C=="function"?C($):C.current=$),k.current=$};y.useEffect(()=>{e!==void 0&&e!==S&&(R(e),L.current=e,H(A(e)))},[e]),y.useEffect(()=>{S!==null&&(L.current=S)},[S]),y.useEffect(()=>()=>{T.current&&clearTimeout(T.current),F.current&&clearInterval(F.current)},[]);function A($){if($==null)return"";let O=$;return a!==void 0&&(O=Number($).toFixed(a)),s?s(O):String(O)}function _($){if(!$)return null;let O=$;c&&(O=c($));try{const U=O.replace(/[^\d.-]/g,"").split("."),oe=U[0],G=U.length>1?U.slice(1).join(""):"",q=oe+(G?`.${G}`:""),ne=Number(q);if(Number.isNaN(ne))return null;let ae;if(a!==void 0){const ue=10**a,he=Math.round(ne*ue)/ue;he.toString().includes("e")?ae=Number.parseFloat(he.toFixed(a)):ae=he}else ne.toString().includes("e")?ae=Number.parseFloat(ne.toFixed(16).replace(/\.?0+$/,"")):ae=ne;return o!==void 0&&ae>o&&(ae=o),r!==void 0&&ae<r&&(ae=r),ae}catch{return null}}function M($){if(H($),w&&$===""){R(null),g==null||g(null);return}const O=_($);R(O),g==null||g(O)}function I($){if(S===null){if(D===""&&w)g&&g(null);else{const V=L.current;R(V),H(A(V)),g&&g(V)}E==null||E($);return}let O=S;o!==void 0&&O>o&&(O=o),r!==void 0&&O<r&&(O=r),O!==S?(R(O),H(A(O)),g==null||g(O)):H(A(S)),E==null||E($)}function N($){if(p)return;const O=$?i:-i;let V;S!==null?V=S:L.current!==null?V=L.current:V=r>0?r:0;let U=V+O;o!==void 0&&U>o&&(U=o),r!==void 0&&U<r&&(U=r),U!==V&&(R(U),L.current=U,H(A(U)),g==null||g(U))}function P($){p||(b==null||b($),$.key==="ArrowUp"?($.preventDefault(),N(!0)):$.key==="ArrowDown"?($.preventDefault(),N(!1)):$.key==="Enter"&&(h==null||h($)))}function j($){var O;p||(N($),(O=k.current)==null||O.focus())}const B=p||o!==void 0&&S!==null&&S>=o,K=p||r!==void 0&&S!==null&&S<=r;return v.jsx("div",{className:W("univer-inline-block",f),children:v.jsxs("div",{className:"univer-relative univer-w-full",children:[v.jsx(Bd,{ref:z,className:W("univer-box-border",u),size:n,value:D,disabled:p,onChange:M,onFocus:x,onBlur:I,onKeyDown:P}),l&&v.jsxs("div",{className:W(`
218
- univer-absolute univer-right-px univer-top-px univer-flex univer-h-[calc(100%-2px)]
219
- univer-flex-col univer-overflow-hidden univer-rounded-r-md
220
- before:univer-absolute before:univer-top-1/2 before:univer-block before:univer-h-px
221
- before:univer-w-full before:-univer-translate-y-1/2 before:univer-bg-gray-200
222
- before:univer-content-[""]
223
- dark:before:!univer-bg-gray-600
224
- `,Rl,m),children:[v.jsx("span",{className:W(`
225
- univer-box-border univer-flex univer-h-1/2 univer-w-5 univer-cursor-pointer
226
- univer-items-center univer-justify-center univer-border-none univer-bg-transparent
227
- univer-p-0 univer-transition-colors
228
- hover:univer-bg-gray-100
229
- dark:!univer-text-white
230
- dark:hover:!univer-bg-gray-600
231
- `,B&&"univer-cursor-not-allowed univer-opacity-60"),role:"button","aria-label":"increment","aria-disabled":B,tabIndex:-1,onMouseDown:$=>$.preventDefault(),onClick:()=>{B||j(!0)},children:"+"}),v.jsx("span",{className:W(`
232
- univer-box-border univer-flex univer-h-1/2 univer-w-5 univer-cursor-pointer
233
- univer-items-center univer-justify-center univer-border-none univer-bg-transparent
234
- univer-p-0 univer-transition-colors
235
- hover:univer-bg-gray-100
236
- dark:!univer-text-white
237
- dark:hover:!univer-bg-gray-600
238
- `,K&&"univer-cursor-not-allowed univer-opacity-60"),role:"button","aria-label":"decrement","aria-disabled":K,tabIndex:-1,onMouseDown:$=>$.preventDefault(),onClick:()=>{K||j(!1)},children:"-"})]})]})})});function Hd({items:e,value:t,defaultValue:n,onChange:r,className:o=""}){const[i,a]=y.useState(t!==void 0?t:n||e[0].value),[s,c]=y.useState({}),l=y.useRef(new Map),f=y.useRef(null);y.useEffect(()=>{t!==void 0&&t!==i&&a(t)},[t]);const u=(p,g)=>{const b=l.current.get(p),h=g?l.current.get(g):null;if(b&&f.current){const x=f.current.getBoundingClientRect(),E=b.getBoundingClientRect(),w=E.left-x.left-4;if(h){const S=h.getBoundingClientRect().left-x.left-4;c({"--slide-from":`${S}px`,"--slide-to":`${w}px`,width:`${E.width}px`,transform:`translateX(${w}px)`})}else c({width:`${E.width}px`,transform:`translateX(${w}px)`})}};y.useEffect(()=>{u(i)},[i]);const m=p=>{const g=i;a(p),r==null||r(p),u(p,g)};return v.jsxs("div",{"data-u-comp":"segmented",ref:f,className:W("univer-relative univer-box-border univer-flex univer-gap-4 univer-rounded-lg univer-bg-gray-100 univer-p-1 dark:!univer-bg-gray-800",o),children:[v.jsx("div",{className:"univer-animate-univer-slide univer-absolute univer-h-6 univer-rounded-md univer-bg-white univer-shadow-sm univer-transition-all univer-duration-200 dark:!univer-bg-gray-700 dark:!univer-text-gray-400",style:s}),e.map(p=>v.jsx("button",{ref:g=>{g&&l.current.set(p.value,g)},className:W("univer-relative univer-box-border univer-flex-1 univer-cursor-pointer univer-border-none univer-bg-transparent univer-px-3 univer-py-1 univer-text-xs univer-font-medium univer-transition-colors",{"univer-text-gray-900 dark:!univer-text-white":i===p.value,"univer-text-gray-500 hover:univer-text-gray-900 dark:hover:!univer-text-white":i!==p.value}),type:"button",onClick:()=>m(p.value),children:p.label},String(p.value)))]})}function yi(e){var k,T;const{children:t,className:n,asChild:r=!0,title:o,placement:i="bottom",showIfEllipsis:a=!1,visible:s,onVisibleChange:c}=e,[l,f]=y.useState(!1),u=s!==void 0,m=u?s:l,p=y.useRef(null),g=y.useRef(null),b=y.useRef(null),[h,x]=y.useState(null),[E,w]=y.useState(i);function C(F){return Math.abs(F.scrollWidth-F.clientWidth)>1}function S(){u?c==null||c(!0):f(!0)}function R(){u?c==null||c(!1):f(!1)}y.useLayoutEffect(()=>{if(!m)return;const F=p.current,z=g.current;if(!F||!z)return;const A=F.getBoundingClientRect(),_=z.getBoundingClientRect(),M=8,I=window.innerWidth,N=window.innerHeight,P=[i,"bottom","top","right","left"];let j=i,B=0,K=0;const $=O=>{let V=0,U=0;return O==="bottom"?(V=A.bottom+M,U=A.left+A.width/2-_.width/2):O==="top"?(V=A.top-_.height-M,U=A.left+A.width/2-_.width/2):O==="left"?(V=A.top+A.height/2-_.height/2,U=A.left-_.width-M):(V=A.top+A.height/2-_.height/2,U=A.right+M),{t:V,l:U}};for(const O of P){const{t:V,l:U}=$(O),oe=U>=0&&U+_.width<=I,G=V>=0&&V+_.height<=N;if(oe&&G){j=O,B=V,K=U;break}}if(!B&&!K){const O=$(i);B=Math.min(Math.max(0,O.t),N-_.height),K=Math.min(Math.max(0,O.l),I-_.width)}w(j),x({top:Math.round(B+window.scrollY),left:Math.round(K+window.scrollX)})},[m,i]),y.useEffect(()=>{if(!m)return;const F=()=>{if(!p.current||!g.current)return;const z=p.current.getBoundingClientRect(),A=g.current.getBoundingClientRect(),_=8;let M=0,I=0;E==="bottom"?(M=z.bottom+_,I=z.left+z.width/2-A.width/2):E==="top"?(M=z.top-A.height-_,I=z.left+z.width/2-A.width/2):E==="left"?(M=z.top+z.height/2-A.height/2,I=z.left-A.width-_):(M=z.top+z.height/2-A.height/2,I=z.right+_),x({top:Math.round(M+window.scrollY),left:Math.round(I+window.scrollX)})};return window.addEventListener("scroll",F,!0),window.addEventListener("resize",F),()=>{window.removeEventListener("scroll",F,!0),window.removeEventListener("resize",F)}},[m,E]);const L={ref:F=>p.current=F,onMouseEnter:()=>{a&&p.current&&!C(p.current)||S()},onMouseLeave:()=>R(),onFocus:()=>S(),onBlur:()=>R()},D=r?v.jsx("span",{...L,className:"univer-inline-block univer-max-w-full univer-truncate",children:t}):v.jsx("button",{type:"button",...L,children:t});let H=null;return typeof document<"u"&&m&&o&&document.body&&(H=ut.createPortal(v.jsxs("div",{ref:g,role:"tooltip",className:W("univer-animate-in univer-fade-in-0 univer-zoom-in-95 univer-pointer-events-auto univer-absolute univer-z-[1081] univer-box-border univer-w-fit univer-max-w-sm univer-text-balance univer-rounded-lg univer-bg-gray-700 univer-px-2.5 univer-py-2 univer-text-xs univer-font-medium univer-text-white univer-shadow-lg univer-drop-shadow-sm dark:!univer-bg-gray-100 dark:!univer-text-gray-900",n),style:{top:(k=h==null?void 0:h.top)!=null?k:-9999,left:(T=h==null?void 0:h.left)!=null?T:-9999},onMouseEnter:()=>S(),onMouseLeave:()=>R(),children:[v.jsx("div",{className:"univer-break-words",children:o}),v.jsx("div",{ref:b,className:"univer-absolute univer-size-2.5 univer-rotate-45 univer-rounded-sm univer-bg-gray-700 dark:!univer-bg-gray-100",style:{...E==="bottom"&&{top:-5,left:"50%",transform:"translateX(-50%) rotate(45deg)"},...E==="top"&&{bottom:-5,left:"50%",transform:"translateX(-50%) rotate(45deg)"},...E==="left"&&{right:-5,top:"50%",transform:"translateY(-50%) rotate(45deg)"},...E==="right"&&{left:-5,top:"50%",transform:"translateY(-50%) rotate(45deg)"}}})]}),document.body)),v.jsxs(v.Fragment,{children:[D,H]})}const db={type:"linear",stops:[{color:"#ffffff",offset:0},{color:"#000000",offset:100}],angle:90};function fb(e){var x,E;const{className:t,value:n=db,onChange:r}=e,{locale:o}=y.useContext(Zt),[i,a]=y.useState(0),s=y.useRef(null),c=y.useMemo(()=>[...n.stops].sort((w,C)=>w.offset-C.offset),[n.stops]),l=w=>{r==null||r({...n,type:w})},f=w=>{r==null||r({...n,angle:w!=null?w:0})},u=w=>{const C=[...n.stops];C[i]={...C[i],color:w},r==null||r({...n,stops:C})},m=w=>{if(w===null)return;const C=[...n.stops];C[i]={...C[i],offset:w},r==null||r({...n,stops:C})},p=w=>{if(!s.current)return;const C=s.current.getBoundingClientRect(),S=Math.round((w.clientX-C.left)/C.width*100),L={color:([...c].reverse().find(H=>H.offset<=S)||c[0]).color,offset:S},D=[...n.stops,L];r==null||r({...n,stops:D}),a(D.length-1)},g=()=>{if(n.stops.length<=2)return;const w=n.stops.filter((C,S)=>S!==i);r==null||r({...n,stops:w}),a(0)},b=y.useMemo(()=>`linear-gradient(to right, ${c.map(C=>`${C.color} ${C.offset}%`).join(", ")})`,[c]),h=y.useMemo(()=>{const w=c.map(C=>`${C.color} ${C.offset}%`).join(", ");switch(n.type){case"linear":return`linear-gradient(${n.angle}deg, ${w})`;case"radial":return`radial-gradient(circle, ${w})`;case"angular":return`conic-gradient(from ${n.angle}deg, ${w})`;case"diamond":return`radial-gradient(circle, ${w})`;default:return`linear-gradient(${n.angle}deg, ${w})`}},[n,c]);return v.jsxs("div",{className:W("univer-flex univer-w-64 univer-flex-col univer-gap-4 univer-rounded-lg univer-bg-white univer-p-4 univer-shadow-lg dark:!univer-bg-gray-800",t),children:[v.jsx(Hd,{items:[{label:o==null?void 0:o.GradientColorPicker.linear,value:"linear"},{label:o==null?void 0:o.GradientColorPicker.radial,value:"radial"},{label:o==null?void 0:o.GradientColorPicker.angular,value:"angular"},{label:o==null?void 0:o.GradientColorPicker.diamond,value:"diamond"}],value:n.type,onChange:w=>l(w)}),v.jsx("div",{className:"univer-h-32 univer-w-full univer-rounded-md univer-border univer-border-gray-200 dark:!univer-border-gray-600",style:{background:h}}),v.jsxs("div",{className:"univer-relative univer-mt-4 univer-h-6",children:[v.jsx("div",{ref:s,className:"univer-absolute univer-inset-x-0 univer-top-1/2 univer-h-2 -univer-translate-y-1/2 univer-cursor-crosshair univer-rounded-full",style:{background:b},onClick:p}),n.stops.map((w,C)=>v.jsx("div",{className:W(`
239
- univer-absolute univer-top-1/2 univer-size-4 -univer-translate-x-1/2
240
- -univer-translate-y-1/2 univer-cursor-pointer univer-rounded-full univer-border-2
241
- univer-border-white univer-shadow-md
242
- `,i===C?"univer-z-10 univer-ring-2 univer-ring-primary-500":"univer-z-0"),style:{left:`${w.offset}%`,backgroundColor:w.color},onClick:S=>{S.stopPropagation(),a(C)},onPointerDown:S=>{const R=S.clientX,L=w.offset,D=k=>{if(!s.current)return;const T=s.current.getBoundingClientRect(),z=(k.clientX-R)/T.width*100,A=Math.max(0,Math.min(100,Math.round(L+z))),_=[...n.stops];_[C]={..._[C],offset:A},r==null||r({...n,stops:_})},H=()=>{window.removeEventListener("pointermove",D),window.removeEventListener("pointerup",H)};window.addEventListener("pointermove",D),window.addEventListener("pointerup",H)}},C))]}),v.jsxs("div",{className:"univer-flex univer-items-end univer-gap-2",children:[v.jsxs("div",{className:"univer-flex-1",children:[v.jsx("div",{className:"univer-mb-1 univer-text-xs univer-text-gray-500",children:o==null?void 0:o.GradientColorPicker.offset}),v.jsx(pa,{value:(x=n.stops[i])==null?void 0:x.offset,min:0,max:100,onChange:m})]}),(n.type==="linear"||n.type==="angular")&&v.jsxs("div",{className:"univer-flex-1",children:[v.jsx("div",{className:"univer-mb-1 univer-text-xs univer-text-gray-500",children:o==null?void 0:o.GradientColorPicker.angle}),v.jsx(pa,{value:n.angle,min:0,max:360,onChange:f})]}),v.jsx("div",{className:"univer-flex univer-gap-1",children:v.jsx(yi,{title:o==null?void 0:o.GradientColorPicker.delete,children:v.jsx(un,{variant:"danger",onClick:g,disabled:n.stops.length<=2,children:v.jsx(tl,{})})})})]}),v.jsx("div",{className:"univer-border-t univer-border-gray-100 univer-pt-4 dark:!univer-border-gray-700",children:v.jsx(fc,{value:(E=n.stops[i])==null?void 0:E.color,onChange:u})})]})}var Ji,xi="HoverCard",[Vd]=An(xi,[Sr]),wi=Sr(),[vb,Ci]=Vd(xi),Wd=e=>{const{__scopeHoverCard:t,children:n,open:r,defaultOpen:o,onOpenChange:i,openDelay:a=700,closeDelay:s=300}=e,c=wi(t),l=d.useRef(0),f=d.useRef(0),u=d.useRef(!1),m=d.useRef(!1),[p,g]=wr({prop:r,defaultProp:o!=null?o:!1,onChange:i,caller:xi}),b=d.useCallback(()=>{clearTimeout(f.current),l.current=window.setTimeout(()=>g(!0),a)},[a,g]),h=d.useCallback(()=>{clearTimeout(l.current),!u.current&&!m.current&&(f.current=window.setTimeout(()=>g(!1),s))},[s,g]),x=d.useCallback(()=>g(!1),[g]);return d.useEffect(()=>()=>{clearTimeout(l.current),clearTimeout(f.current)},[]),v.jsx(vb,{scope:t,open:p,onOpenChange:g,onOpen:b,onClose:h,onDismiss:x,hasSelectionRef:u,isPointerDownOnContentRef:m,children:v.jsx(mi,{...c,children:n})})};Wd.displayName=xi;var Kd="HoverCardTrigger",Ud=d.forwardRef((e,t)=>{const{__scopeHoverCard:n,...r}=e,o=Ci(Kd,n),i=wi(n);return v.jsx(pi,{asChild:!0,...i,children:v.jsx($e.a,{"data-state":o.open?"open":"closed",...r,ref:t,onPointerEnter:ie(e.onPointerEnter,Zo(o.onOpen)),onPointerLeave:ie(e.onPointerLeave,Zo(o.onClose)),onFocus:ie(e.onFocus,o.onOpen),onBlur:ie(e.onBlur,o.onClose),onTouchStart:ie(e.onTouchStart,a=>a.preventDefault())})})});Ud.displayName=Kd;var gs="HoverCardPortal",[mb,pb]=Vd(gs,{forceMount:void 0}),Gd=e=>{const{__scopeHoverCard:t,forceMount:n,children:r,container:o}=e,i=Ci(gs,t);return v.jsx(mb,{scope:t,forceMount:n,children:v.jsx(Nt,{present:n||i.open,children:v.jsx(eo,{asChild:!0,container:o,children:r})})})};Gd.displayName=gs;var Yo="HoverCardContent",Yd=d.forwardRef((e,t)=>{const n=pb(Yo,e.__scopeHoverCard),{forceMount:r=n.forceMount,...o}=e,i=Ci(Yo,e.__scopeHoverCard);return v.jsx(Nt,{present:r||i.open,children:v.jsx(hb,{"data-state":i.open?"open":"closed",...o,onPointerEnter:ie(e.onPointerEnter,Zo(i.onOpen)),onPointerLeave:ie(e.onPointerLeave,Zo(i.onClose)),ref:t})})});Yd.displayName=Yo;var hb=d.forwardRef((e,t)=>{const{__scopeHoverCard:n,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:i,onInteractOutside:a,...s}=e,c=Ci(Yo,n),l=wi(n),f=d.useRef(null),u=Ue(t,f),[m,p]=d.useState(!1);return d.useEffect(()=>{if(m){const g=document.body;return Ji=g.style.userSelect||g.style.webkitUserSelect,g.style.userSelect="none",g.style.webkitUserSelect="none",()=>{g.style.userSelect=Ji,g.style.webkitUserSelect=Ji}}},[m]),d.useEffect(()=>{if(f.current){const g=()=>{p(!1),c.isPointerDownOnContentRef.current=!1,setTimeout(()=>{var h;((h=document.getSelection())==null?void 0:h.toString())!==""&&(c.hasSelectionRef.current=!0)})};return document.addEventListener("pointerup",g),()=>{document.removeEventListener("pointerup",g),c.hasSelectionRef.current=!1,c.isPointerDownOnContentRef.current=!1}}},[c.isPointerDownOnContentRef,c.hasSelectionRef]),d.useEffect(()=>{f.current&&yb(f.current).forEach(b=>b.setAttribute("tabindex","-1"))}),v.jsx(Jr,{asChild:!0,disableOutsidePointerEvents:!1,onInteractOutside:a,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:ie(i,g=>{g.preventDefault()}),onDismiss:c.onDismiss,children:v.jsx(os,{...l,...s,onPointerDown:ie(s.onPointerDown,g=>{g.currentTarget.contains(g.target)&&p(!0),c.hasSelectionRef.current=!1,c.isPointerDownOnContentRef.current=!0}),ref:u,style:{...s.style,userSelect:m?"text":void 0,WebkitUserSelect:m?"text":void 0,"--radix-hover-card-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-hover-card-content-available-width":"var(--radix-popper-available-width)","--radix-hover-card-content-available-height":"var(--radix-popper-available-height)","--radix-hover-card-trigger-width":"var(--radix-popper-anchor-width)","--radix-hover-card-trigger-height":"var(--radix-popper-anchor-height)"}})})}),gb="HoverCardArrow",bb=d.forwardRef((e,t)=>{const{__scopeHoverCard:n,...r}=e,o=wi(n);return v.jsx(is,{...o,...r,ref:t})});bb.displayName=gb;function Zo(e){return t=>t.pointerType==="touch"?void 0:e()}function yb(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP});for(;n.nextNode();)t.push(n.currentNode);return t}var xb=Wd,wb=Ud,Cb=Gd,Zd=Yd;const Eb=xb,Sb=Cb,Rb=wb,qd=y.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>v.jsx(Zd,{ref:o,align:t,sideOffset:n,className:W(`
243
- data-[state=open]:univer-animate-in data-[state=open]:univer-fade-in-0 data-[state=open]:univer-zoom-in-95
244
- data-[state=closed]:univer-animate-out data-[state=closed]:univer-fade-out-0
245
- data-[state=closed]:univer-zoom-out-95
246
- data-[side=bottom]:univer-slide-in-from-top-2
247
- data-[side=left]:univer-slide-in-from-right-2
248
- data-[side=right]:univer-slide-in-from-left-2
249
- data-[side=top]:univer-slide-in-from-bottom-2
250
- univer-z-[1080] univer-w-64 univer-origin-[--radix-hover-card-content-transform-origin] univer-rounded-md
251
- univer-bg-white univer-text-gray-900 univer-shadow-md univer-outline-none
252
- dark:!univer-bg-gray-900 dark:!univer-text-white
253
- `,ct,e),...r}));qd.displayName=Zd.displayName;function Mb(e){const{children:t,overlay:n,disabled:r,openDelay:o=200,open:i,onOpenChange:a,...s}=e,[c,l]=y.useState(!1),f=i!==void 0,u=f?i:c;function m(p){r||(f||l(p),a==null||a(p))}return v.jsxs(Eb,{open:u,onOpenChange:m,openDelay:o,children:[v.jsx(Rb,{asChild:!0,children:t}),v.jsx(Sb,{children:v.jsx(qd,{...s,children:n})})]})}function Nb(e){const{keyboard:t,className:n}=e,r=t.split("+");return v.jsx("span",{className:W("univer-inline-block univer-h-6 univer-select-none univer-whitespace-nowrap univer-rounded-md univer-bg-gray-50 univer-px-2 univer-font-mono univer-text-xs/6 univer-font-medium univer-text-gray-700 dark:!univer-bg-gray-700 dark:!univer-text-white",ct,n),children:r.map((o,i)=>v.jsxs(v.Fragment,{children:[v.jsx("kbd",{className:"univer-inline-block univer-h-full",children:o}),i<r.length-1&&v.jsx("span",{className:"univer-inline-block univer-h-full univer-px-1",children:"+"})]},i))})}function Me(){return Me=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Me.apply(null,arguments)}function lt(e){"@babel/helpers - typeof";return lt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},lt(e)}function Pb(e,t){if(lt(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(lt(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Xd(e){var t=Pb(e,"string");return lt(t)=="symbol"?t:t+""}function me(e,t,n){return(t=Xd(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function du(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function Z(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?du(Object(n),!0).forEach(function(r){me(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):du(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ha(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function kb(e){if(Array.isArray(e))return ha(e)}function _b(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Qd(e,t){if(e){if(typeof e=="string")return ha(e,t);var n={}.toString.call(e).slice(8,-1);return n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set"?Array.from(e):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?ha(e,t):void 0}}function Ib(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
254
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Yt(e){return kb(e)||_b(e)||Qd(e)||Ib()}function Db(e){if(Array.isArray(e))return e}function Ab(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,o,i,a,s=[],c=!0,l=!1;try{if(i=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(f){l=!0,o=f}finally{try{if(!c&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(l)throw o}}return s}}function Tb(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
255
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function te(e,t){return Db(e)||Ab(e,t)||Qd(e,t)||Tb()}function bs(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function Qe(e,t){if(e==null)return{};var n,r,o=bs(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var ea={exports:{}};var fu;function Ob(){return fu||(fu=1,(function(e){(function(){var t={}.hasOwnProperty;function n(){for(var i="",a=0;a<arguments.length;a++){var s=arguments[a];s&&(i=o(i,r(s)))}return i}function r(i){if(typeof i=="string"||typeof i=="number")return i;if(typeof i!="object")return"";if(Array.isArray(i))return n.apply(null,i);if(i.toString!==Object.prototype.toString&&!i.toString.toString().includes("[native code]"))return i.toString();var a="";for(var s in i)t.call(i,s)&&i[s]&&(a=o(a,s));return a}function o(i,a){return a?i?i+" "+a:i+a:i}e.exports?(n.default=n,e.exports=n):window.classNames=n})()})(ea)),ea.exports}var jb=Ob();const at=Sl(jb);var Lb=Symbol.for("react.element"),$b=Symbol.for("react.transitional.element"),Fb=Symbol.for("react.fragment");function Jd(e){return e&&lt(e)==="object"&&(e.$$typeof===Lb||e.$$typeof===$b)&&e.type===Fb}function qo(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=[];return y.Children.forEach(e,function(r){r==null&&!t.keepEmpty||(Array.isArray(r)?n=n.concat(qo(r)):Jd(r)&&r.props?n=n.concat(qo(r.props.children,t)):n.push(r))}),n}var ga={},zb=function(t){};function Bb(e,t){}function Hb(e,t){}function Vb(){ga={}}function ef(e,t,n){!t&&!ga[n]&&(e(!1,n),ga[n]=!0)}function Rr(e,t){ef(Bb,e,t)}function Wb(e,t){ef(Hb,e,t)}Rr.preMessage=zb;Rr.resetWarned=Vb;Rr.noteOnce=Wb;function Yr(e){return e instanceof HTMLElement||e instanceof SVGElement}function Kb(e){return e&&lt(e)==="object"&&Yr(e.nativeElement)?e.nativeElement:Yr(e)?e:null}function Ao(e){var t=Kb(e);if(t)return t;if(e instanceof y.Component){var n;return(n=ut.findDOMNode)===null||n===void 0?void 0:n.call(ut,e)}return null}var ta={exports:{}},Se={};var vu;function Ub(){if(vu)return Se;vu=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),a=Symbol.for("react.context"),s=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),u=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),p=Symbol.for("react.offscreen"),g;g=Symbol.for("react.module.reference");function b(h){if(typeof h=="object"&&h!==null){var x=h.$$typeof;switch(x){case e:switch(h=h.type,h){case n:case o:case r:case l:case f:return h;default:switch(h=h&&h.$$typeof,h){case s:case a:case c:case m:case u:case i:return h;default:return x}}case t:return x}}}return Se.ContextConsumer=a,Se.ContextProvider=i,Se.Element=e,Se.ForwardRef=c,Se.Fragment=n,Se.Lazy=m,Se.Memo=u,Se.Portal=t,Se.Profiler=o,Se.StrictMode=r,Se.Suspense=l,Se.SuspenseList=f,Se.isAsyncMode=function(){return!1},Se.isConcurrentMode=function(){return!1},Se.isContextConsumer=function(h){return b(h)===a},Se.isContextProvider=function(h){return b(h)===i},Se.isElement=function(h){return typeof h=="object"&&h!==null&&h.$$typeof===e},Se.isForwardRef=function(h){return b(h)===c},Se.isFragment=function(h){return b(h)===n},Se.isLazy=function(h){return b(h)===m},Se.isMemo=function(h){return b(h)===u},Se.isPortal=function(h){return b(h)===t},Se.isProfiler=function(h){return b(h)===o},Se.isStrictMode=function(h){return b(h)===r},Se.isSuspense=function(h){return b(h)===l},Se.isSuspenseList=function(h){return b(h)===f},Se.isValidElementType=function(h){return typeof h=="string"||typeof h=="function"||h===n||h===o||h===r||h===l||h===f||h===p||typeof h=="object"&&h!==null&&(h.$$typeof===m||h.$$typeof===u||h.$$typeof===i||h.$$typeof===a||h.$$typeof===c||h.$$typeof===g||h.getModuleId!==void 0)},Se.typeOf=b,Se}var mu;function Gb(){return mu||(mu=1,ta.exports=Ub()),ta.exports}var na=Gb();function tf(e,t,n){var r=d.useRef({});return(!("value"in r.current)||n(r.current.condition,t))&&(r.current.value=e(),r.current.condition=t),r.current.value}var Yb=Number(y.version.split(".")[0]),ys=function(t,n){typeof t=="function"?t(n):lt(t)==="object"&&t&&"current"in t&&(t.current=n)},nf=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var o=n.filter(Boolean);return o.length<=1?o[0]:function(i){n.forEach(function(a){ys(a,i)})}},Ei=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return tf(function(){return nf.apply(void 0,n)},n,function(o,i){return o.length!==i.length||o.every(function(a,s){return a!==i[s]})})},Si=function(t){var n,r;if(!t)return!1;if(rf(t)&&Yb>=19)return!0;var o=na.isMemo(t)?t.type.type:t.type;return!(typeof o=="function"&&!((n=o.prototype)!==null&&n!==void 0&&n.render)&&o.$$typeof!==na.ForwardRef||typeof t=="function"&&!((r=t.prototype)!==null&&r!==void 0&&r.render)&&t.$$typeof!==na.ForwardRef)};function rf(e){return y.isValidElement(e)&&!Jd(e)}var xs=function(t){if(t&&rf(t)){var n=t;return n.props.propertyIsEnumerable("ref")?n.props.ref:n.ref}return null},ba=d.createContext(null);function Zb(e){var t=e.children,n=e.onBatchResize,r=d.useRef(0),o=d.useRef([]),i=d.useContext(ba),a=d.useCallback(function(s,c,l){r.current+=1;var f=r.current;o.current.push({size:s,element:c,data:l}),Promise.resolve().then(function(){f===r.current&&(n==null||n(o.current),o.current=[])}),i==null||i(s,c,l)},[n,i]);return d.createElement(ba.Provider,{value:a},t)}var of=(function(){if(typeof Map<"u")return Map;function e(t,n){var r=-1;return t.some(function(o,i){return o[0]===n?(r=i,!0):!1}),r}return(function(){function t(){this.__entries__=[]}return Object.defineProperty(t.prototype,"size",{get:function(){return this.__entries__.length},enumerable:!0,configurable:!0}),t.prototype.get=function(n){var r=e(this.__entries__,n),o=this.__entries__[r];return o&&o[1]},t.prototype.set=function(n,r){var o=e(this.__entries__,n);~o?this.__entries__[o][1]=r:this.__entries__.push([n,r])},t.prototype.delete=function(n){var r=this.__entries__,o=e(r,n);~o&&r.splice(o,1)},t.prototype.has=function(n){return!!~e(this.__entries__,n)},t.prototype.clear=function(){this.__entries__.splice(0)},t.prototype.forEach=function(n,r){r===void 0&&(r=null);for(var o=0,i=this.__entries__;o<i.length;o++){var a=i[o];n.call(r,a[1],a[0])}},t})()})(),ya=typeof window<"u"&&typeof document<"u"&&window.document===document,Xo=(function(){return typeof global<"u"&&global.Math===Math?global:typeof self<"u"&&self.Math===Math?self:typeof window<"u"&&window.Math===Math?window:Function("return this")()})(),qb=(function(){return typeof requestAnimationFrame=="function"?requestAnimationFrame.bind(Xo):function(e){return setTimeout(function(){return e(Date.now())},1e3/60)}})(),Xb=2;function Qb(e,t){var n=!1,r=!1,o=0;function i(){n&&(n=!1,e()),r&&s()}function a(){qb(i)}function s(){var c=Date.now();if(n){if(c-o<Xb)return;r=!0}else n=!0,r=!1,setTimeout(a,t);o=c}return s}var Jb=20,ey=["top","right","bottom","left","width","height","size","weight"],ty=typeof MutationObserver<"u",ny=(function(){function e(){this.connected_=!1,this.mutationEventsAdded_=!1,this.mutationsObserver_=null,this.observers_=[],this.onTransitionEnd_=this.onTransitionEnd_.bind(this),this.refresh=Qb(this.refresh.bind(this),Jb)}return e.prototype.addObserver=function(t){~this.observers_.indexOf(t)||this.observers_.push(t),this.connected_||this.connect_()},e.prototype.removeObserver=function(t){var n=this.observers_,r=n.indexOf(t);~r&&n.splice(r,1),!n.length&&this.connected_&&this.disconnect_()},e.prototype.refresh=function(){var t=this.updateObservers_();t&&this.refresh()},e.prototype.updateObservers_=function(){var t=this.observers_.filter(function(n){return n.gatherActive(),n.hasActive()});return t.forEach(function(n){return n.broadcastActive()}),t.length>0},e.prototype.connect_=function(){!ya||this.connected_||(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),ty?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},e.prototype.disconnect_=function(){!ya||!this.connected_||(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},e.prototype.onTransitionEnd_=function(t){var n=t.propertyName,r=n===void 0?"":n,o=ey.some(function(i){return!!~r.indexOf(i)});o&&this.refresh()},e.getInstance=function(){return this.instance_||(this.instance_=new e),this.instance_},e.instance_=null,e})(),af=(function(e,t){for(var n=0,r=Object.keys(t);n<r.length;n++){var o=r[n];Object.defineProperty(e,o,{value:t[o],enumerable:!1,writable:!1,configurable:!0})}return e}),gr=(function(e){var t=e&&e.ownerDocument&&e.ownerDocument.defaultView;return t||Xo}),sf=Ri(0,0,0,0);function Qo(e){return parseFloat(e)||0}function pu(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];return t.reduce(function(r,o){var i=e["border-"+o+"-width"];return r+Qo(i)},0)}function ry(e){for(var t=["top","right","bottom","left"],n={},r=0,o=t;r<o.length;r++){var i=o[r],a=e["padding-"+i];n[i]=Qo(a)}return n}function oy(e){var t=e.getBBox();return Ri(0,0,t.width,t.height)}function iy(e){var t=e.clientWidth,n=e.clientHeight;if(!t&&!n)return sf;var r=gr(e).getComputedStyle(e),o=ry(r),i=o.left+o.right,a=o.top+o.bottom,s=Qo(r.width),c=Qo(r.height);if(r.boxSizing==="border-box"&&(Math.round(s+i)!==t&&(s-=pu(r,"left","right")+i),Math.round(c+a)!==n&&(c-=pu(r,"top","bottom")+a)),!sy(e)){var l=Math.round(s+i)-t,f=Math.round(c+a)-n;Math.abs(l)!==1&&(s-=l),Math.abs(f)!==1&&(c-=f)}return Ri(o.left,o.top,s,c)}var ay=(function(){return typeof SVGGraphicsElement<"u"?function(e){return e instanceof gr(e).SVGGraphicsElement}:function(e){return e instanceof gr(e).SVGElement&&typeof e.getBBox=="function"}})();function sy(e){return e===gr(e).document.documentElement}function uy(e){return ya?ay(e)?oy(e):iy(e):sf}function ly(e){var t=e.x,n=e.y,r=e.width,o=e.height,i=typeof DOMRectReadOnly<"u"?DOMRectReadOnly:Object,a=Object.create(i.prototype);return af(a,{x:t,y:n,width:r,height:o,top:n,right:t+r,bottom:o+n,left:t}),a}function Ri(e,t,n,r){return{x:e,y:t,width:n,height:r}}var cy=(function(){function e(t){this.broadcastWidth=0,this.broadcastHeight=0,this.contentRect_=Ri(0,0,0,0),this.target=t}return e.prototype.isActive=function(){var t=uy(this.target);return this.contentRect_=t,t.width!==this.broadcastWidth||t.height!==this.broadcastHeight},e.prototype.broadcastRect=function(){var t=this.contentRect_;return this.broadcastWidth=t.width,this.broadcastHeight=t.height,t},e})(),dy=(function(){function e(t,n){var r=ly(n);af(this,{target:t,contentRect:r})}return e})(),fy=(function(){function e(t,n,r){if(this.activeObservations_=[],this.observations_=new of,typeof t!="function")throw new TypeError("The callback provided as parameter 1 is not a function.");this.callback_=t,this.controller_=n,this.callbackCtx_=r}return e.prototype.observe=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if(!(typeof Element>"u"||!(Element instanceof Object))){if(!(t instanceof gr(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var n=this.observations_;n.has(t)||(n.set(t,new cy(t)),this.controller_.addObserver(this),this.controller_.refresh())}},e.prototype.unobserve=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if(!(typeof Element>"u"||!(Element instanceof Object))){if(!(t instanceof gr(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var n=this.observations_;n.has(t)&&(n.delete(t),n.size||this.controller_.removeObserver(this))}},e.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},e.prototype.gatherActive=function(){var t=this;this.clearActive(),this.observations_.forEach(function(n){n.isActive()&&t.activeObservations_.push(n)})},e.prototype.broadcastActive=function(){if(this.hasActive()){var t=this.callbackCtx_,n=this.activeObservations_.map(function(r){return new dy(r.target,r.broadcastRect())});this.callback_.call(t,n,t),this.clearActive()}},e.prototype.clearActive=function(){this.activeObservations_.splice(0)},e.prototype.hasActive=function(){return this.activeObservations_.length>0},e})(),uf=typeof WeakMap<"u"?new WeakMap:new of,lf=(function(){function e(t){if(!(this instanceof e))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var n=ny.getInstance(),r=new fy(t,n,this);uf.set(this,r)}return e})();["observe","unobserve","disconnect"].forEach(function(e){lf.prototype[e]=function(){var t;return(t=uf.get(this))[e].apply(t,arguments)}});var vy=(function(){return typeof Xo.ResizeObserver<"u"?Xo.ResizeObserver:lf})(),Pn=new Map;function my(e){e.forEach(function(t){var n,r=t.target;(n=Pn.get(r))===null||n===void 0||n.forEach(function(o){return o(r)})})}var cf=new vy(my);function py(e,t){Pn.has(e)||(Pn.set(e,new Set),cf.observe(e)),Pn.get(e).add(t)}function hy(e,t){Pn.has(e)&&(Pn.get(e).delete(t),Pn.get(e).size||(cf.unobserve(e),Pn.delete(e)))}function Mi(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function hu(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Xd(r.key),r)}}function Ni(e,t,n){return t&&hu(e.prototype,t),n&&hu(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Jo(e,t){return Jo=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,r){return n.__proto__=r,n},Jo(e,t)}function Pi(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Jo(e,t)}function ei(e){return ei=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},ei(e)}function df(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(df=function(){return!!e})()}function xa(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function gy(e,t){if(t&&(lt(t)=="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return xa(e)}function ki(e){var t=df();return function(){var n,r=ei(e);if(t){var o=ei(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return gy(this,n)}}var by=(function(e){Pi(n,e);var t=ki(n);function n(){return Mi(this,n),t.apply(this,arguments)}return Ni(n,[{key:"render",value:function(){return this.props.children}}]),n})(d.Component);function yy(e,t){var n=e.children,r=e.disabled,o=d.useRef(null),i=d.useRef(null),a=d.useContext(ba),s=typeof n=="function",c=s?n(o):n,l=d.useRef({width:-1,height:-1,offsetWidth:-1,offsetHeight:-1}),f=!s&&d.isValidElement(c)&&Si(c),u=f?xs(c):null,m=Ei(u,o),p=function(){var x;return Ao(o.current)||(o.current&&lt(o.current)==="object"?Ao((x=o.current)===null||x===void 0?void 0:x.nativeElement):null)||Ao(i.current)};d.useImperativeHandle(t,function(){return p()});var g=d.useRef(e);g.current=e;var b=d.useCallback(function(h){var x=g.current,E=x.onResize,w=x.data,C=h.getBoundingClientRect(),S=C.width,R=C.height,L=h.offsetWidth,D=h.offsetHeight,H=Math.floor(S),k=Math.floor(R);if(l.current.width!==H||l.current.height!==k||l.current.offsetWidth!==L||l.current.offsetHeight!==D){var T={width:H,height:k,offsetWidth:L,offsetHeight:D};l.current=T;var F=L===Math.round(S)?S:L,z=D===Math.round(R)?R:D,A=Z(Z({},T),{},{offsetWidth:F,offsetHeight:z});a==null||a(A,h,w),E&&Promise.resolve().then(function(){E(A,h)})}},[]);return d.useEffect(function(){var h=p();return h&&!r&&py(h,b),function(){return hy(h,b)}},[o.current,r]),d.createElement(by,{ref:i},f?d.cloneElement(c,{ref:m}):c)}var xy=d.forwardRef(yy),wy="rc-observer-key";function Cy(e,t){var n=e.children,r=typeof n=="function"?[n]:qo(n);return r.map(function(o,i){var a=(o==null?void 0:o.key)||"".concat(wy,"-").concat(i);return d.createElement(xy,Me({},e,{key:a,ref:i===0?t:void 0}),o)})}var so=d.forwardRef(Cy);so.Collection=Zb;function dn(){return!!(typeof window<"u"&&window.document&&window.document.createElement)}var gu=dn()?d.useLayoutEffect:d.useEffect,mt=function(t,n){var r=d.useRef(!0);gu(function(){return t(r.current)},n),gu(function(){return r.current=!1,function(){r.current=!0}},[])},bu=function(t,n){mt(function(r){if(!r)return t()},n)},Ey=["prefixCls","invalidate","item","renderItem","responsive","responsiveDisabled","registerSize","itemKey","className","style","children","display","order","component"],or=void 0;function Sy(e,t){var n=e.prefixCls,r=e.invalidate,o=e.item,i=e.renderItem,a=e.responsive,s=e.responsiveDisabled,c=e.registerSize,l=e.itemKey,f=e.className,u=e.style,m=e.children,p=e.display,g=e.order,b=e.component,h=b===void 0?"div":b,x=Qe(e,Ey),E=a&&!p;function w(D){c(l,D)}d.useEffect(function(){return function(){w(null)}},[]);var C=i&&o!==or?i(o,{index:g}):m,S;r||(S={opacity:E?0:1,height:E?0:or,overflowY:E?"hidden":or,order:a?g:or,pointerEvents:E?"none":or,position:E?"absolute":or});var R={};E&&(R["aria-hidden"]=!0);var L=d.createElement(h,Me({className:at(!r&&n,f),style:Z(Z({},S),u)},R,x,{ref:t}),C);return a&&(L=d.createElement(so,{onResize:function(H){var k=H.offsetWidth;w(k)},disabled:s},L)),L}var Br=d.forwardRef(Sy);Br.displayName="Item";function xt(e){var t=d.useRef();t.current=e;var n=d.useCallback(function(){for(var r,o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];return(r=t.current)===null||r===void 0?void 0:r.call.apply(r,[t].concat(i))},[]);return n}var ff=function(t){return+setTimeout(t,16)},vf=function(t){return clearTimeout(t)};typeof window<"u"&&"requestAnimationFrame"in window&&(ff=function(t){return window.requestAnimationFrame(t)},vf=function(t){return window.cancelAnimationFrame(t)});var yu=0,ws=new Map;function mf(e){ws.delete(e)}var an=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;yu+=1;var r=yu;function o(i){if(i===0)mf(r),t();else{var a=ff(function(){o(i-1)});ws.set(r,a)}}return o(n),r};an.cancel=function(e){var t=ws.get(e);return mf(e),vf(t)};function Ry(e){if(typeof MessageChannel>"u")an(e);else{var t=new MessageChannel;t.port1.onmessage=function(){return e()},t.port2.postMessage(void 0)}}function My(){var e=d.useRef(null),t=function(r){e.current||(e.current=[],Ry(function(){ut.unstable_batchedUpdates(function(){e.current.forEach(function(o){o()}),e.current=null})})),e.current.push(r)};return t}function Ar(e,t){var n=d.useState(t),r=te(n,2),o=r[0],i=r[1],a=xt(function(s){e(function(){i(s)})});return[o,a]}var ti=y.createContext(null),Ny=["component"],Py=["className"],ky=["className"],_y=function(t,n){var r=d.useContext(ti);if(!r){var o=t.component,i=o===void 0?"div":o,a=Qe(t,Ny);return d.createElement(i,Me({},a,{ref:n}))}var s=r.className,c=Qe(r,Py),l=t.className,f=Qe(t,ky);return d.createElement(ti.Provider,{value:null},d.createElement(Br,Me({ref:n,className:at(s,l)},c,f)))},pf=d.forwardRef(_y);pf.displayName="RawItem";var Iy=["prefixCls","data","renderItem","renderRawItem","itemKey","itemWidth","ssr","style","className","maxCount","renderRest","renderRawRest","suffix","component","itemComponent","onVisibleChange"],hf="responsive",gf="invalidate";function Dy(e){return"+ ".concat(e.length," ...")}function Ay(e,t){var n=e.prefixCls,r=n===void 0?"rc-overflow":n,o=e.data,i=o===void 0?[]:o,a=e.renderItem,s=e.renderRawItem,c=e.itemKey,l=e.itemWidth,f=l===void 0?10:l,u=e.ssr,m=e.style,p=e.className,g=e.maxCount,b=e.renderRest,h=e.renderRawRest,x=e.suffix,E=e.component,w=E===void 0?"div":E,C=e.itemComponent,S=e.onVisibleChange,R=Qe(e,Iy),L=u==="full",D=My(),H=Ar(D,null),k=te(H,2),T=k[0],F=k[1],z=T||0,A=Ar(D,new Map),_=te(A,2),M=_[0],I=_[1],N=Ar(D,0),P=te(N,2),j=P[0],B=P[1],K=Ar(D,0),$=te(K,2),O=$[0],V=$[1],U=Ar(D,0),oe=te(U,2),G=oe[0],q=oe[1],ne=y.useState(null),ae=te(ne,2),ue=ae[0],he=ae[1],xe=y.useState(null),ge=te(xe,2),Ne=ge[0],ke=ge[1],be=d.useMemo(function(){return Ne===null&&L?Number.MAX_SAFE_INTEGER:Ne||0},[Ne,T]),ye=y.useState(!1),Le=te(ye,2),le=Le[0],ce=Le[1],re="".concat(r,"-item"),Je=Math.max(j,O),Fe=g===hf,pe=i.length&&Fe,et=g===gf,tt=pe||typeof g=="number"&&i.length>g,Oe=y.useMemo(function(){var J=i;return pe?T===null&&L?J=i:J=i.slice(0,Math.min(i.length,z/f)):typeof g=="number"&&(J=i.slice(0,g)),J},[i,f,T,g,pe]),He=y.useMemo(function(){return pe?i.slice(be+1):i.slice(Oe.length)},[i,Oe,pe,be]),Ve=y.useCallback(function(J,ee){var Y;return typeof c=="function"?c(J):(Y=c&&(J==null?void 0:J[c]))!==null&&Y!==void 0?Y:ee},[c]),_e=y.useCallback(a||function(J){return J},[a]);function Ae(J,ee,Y){Ne===J&&(ee===void 0||ee===ue)||(ke(J),Y||(ce(J<i.length-1),S==null||S(J)),ee!==void 0&&he(ee))}function Re(J,ee){F(ee.clientWidth)}function Be(J,ee){I(function(Y){var ve=new Map(Y);return ee===null?ve.delete(J):ve.set(J,ee),ve})}function Ie(J,ee){V(ee),B(O)}function nt(J,ee){q(ee)}function Ye(J){return M.get(Ve(Oe[J],J))}mt(function(){if(z&&typeof Je=="number"&&Oe){var J=G,ee=Oe.length,Y=ee-1;if(!ee){Ae(0,null);return}for(var ve=0;ve<ee;ve+=1){var We=Ye(ve);if(L&&(We=We||0),We===void 0){Ae(ve-1,void 0,!0);break}if(J+=We,Y===0&&J<=z||ve===Y-1&&J+Ye(Y)<=z){Ae(Y,null);break}else if(J+Je>z){Ae(ve-1,J-We-G+O);break}}x&&Ye(0)+G>z&&he(null)}},[z,M,O,G,Ve,Oe]);var rt=le&&!!He.length,Pt={};ue!==null&&pe&&(Pt={position:"absolute",left:ue,top:0});var ft={prefixCls:re,responsive:pe,component:C,invalidate:et},jt=s?function(J,ee){var Y=Ve(J,ee);return d.createElement(ti.Provider,{key:Y,value:Z(Z({},ft),{},{order:ee,item:J,itemKey:Y,registerSize:Be,display:ee<=be})},s(J,ee))}:function(J,ee){var Y=Ve(J,ee);return d.createElement(Br,Me({},ft,{order:ee,key:Y,item:J,renderItem:_e,itemKey:Y,registerSize:Be,display:ee<=be}))},Ze={order:rt?be:Number.MAX_SAFE_INTEGER,className:"".concat(re,"-rest"),registerSize:Ie,display:rt},X=b||Dy,Ce=h?d.createElement(ti.Provider,{value:Z(Z({},ft),Ze)},h(He)):d.createElement(Br,Me({},ft,Ze),typeof X=="function"?X(He):X),fe=d.createElement(w,Me({className:at(!et&&r,p),style:m,ref:t},R),Oe.map(jt),tt?Ce:null,x&&d.createElement(Br,Me({},ft,{responsive:Fe,responsiveDisabled:!pe,order:be,className:"".concat(re,"-suffix"),registerSize:nt,display:!0,style:Pt}),x));return Fe?d.createElement(so,{onResize:Re,disabled:!pe},fe):fe}var sn=d.forwardRef(Ay);sn.displayName="Overflow";sn.Item=pf;sn.RESPONSIVE=hf;sn.INVALIDATE=gf;function Zr(e){var t=d.useRef(!1),n=d.useState(e),r=te(n,2),o=r[0],i=r[1];d.useEffect(function(){return t.current=!1,function(){t.current=!0}},[]);function a(s,c){c&&t.current||i(s)}return[o,a]}function ra(e){return e!==void 0}function To(e,t){var n=t||{},r=n.defaultValue,o=n.value,i=n.onChange,a=n.postState,s=Zr(function(){return ra(o)?o:ra(r)?typeof r=="function"?r():r:typeof e=="function"?e():e}),c=te(s,2),l=c[0],f=c[1],u=o!==void 0?o:l,m=a?a(u):u,p=xt(i),g=Zr([u]),b=te(g,2),h=b[0],x=b[1];bu(function(){var w=h[0];l!==w&&p(l,w)},[h]),bu(function(){ra(o)||f(o)},[o]);var E=xt(function(w,C){f(w,C),x([u],C)});return[m,E]}function bf(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,r=new Set;function o(i,a){var s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,c=r.has(i);if(Rr(!c,"Warning: There may be circular references"),c)return!1;if(i===a)return!0;if(n&&s>1)return!1;r.add(i);var l=s+1;if(Array.isArray(i)){if(!Array.isArray(a)||i.length!==a.length)return!1;for(var f=0;f<i.length;f++)if(!o(i[f],a[f],l))return!1;return!0}if(i&&a&&lt(i)==="object"&&lt(a)==="object"){var u=Object.keys(i);return u.length!==Object.keys(a).length?!1:u.every(function(m){return o(i[m],a[m],l)})}return!1}return o(e,t)}var yf=d.createContext(null);function xf(e,t){return e===void 0?null:"".concat(e,"-").concat(t)}function wf(e){var t=d.useContext(yf);return xf(t,e)}var Ty=["children","locked"],Tt=d.createContext(null);function Oy(e,t){var n=Z({},e);return Object.keys(t).forEach(function(r){var o=t[r];o!==void 0&&(n[r]=o)}),n}function qr(e){var t=e.children,n=e.locked,r=Qe(e,Ty),o=d.useContext(Tt),i=tf(function(){return Oy(o,r)},[o,r],function(a,s){return!n&&(a[0]!==s[0]||!bf(a[1],s[1],!0))});return d.createElement(Tt.Provider,{value:i},t)}var jy=[],Cf=d.createContext(null);function _i(){return d.useContext(Cf)}var Ef=d.createContext(jy);function uo(e){var t=d.useContext(Ef);return d.useMemo(function(){return e!==void 0?[].concat(Yt(t),[e]):t},[t,e])}var Sf=d.createContext(null),Cs=d.createContext({});const Rf=(function(e){if(!e)return!1;if(e instanceof Element){if(e.offsetParent)return!0;if(e.getBBox){var t=e.getBBox(),n=t.width,r=t.height;if(n||r)return!0}if(e.getBoundingClientRect){var o=e.getBoundingClientRect(),i=o.width,a=o.height;if(i||a)return!0}}return!1});function xu(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(Rf(e)){var n=e.nodeName.toLowerCase(),r=["input","select","textarea","button"].includes(n)||e.isContentEditable||n==="a"&&!!e.getAttribute("href"),o=e.getAttribute("tabindex"),i=Number(o),a=null;return o&&!Number.isNaN(i)?a=i:r&&a===null&&(a=0),r&&e.disabled&&(a=null),a!==null&&(a>=0||t&&a<0)}return!1}function Ly(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n=Yt(e.querySelectorAll("*")).filter(function(r){return xu(r,t)});return xu(e,t)&&n.unshift(e),n}var fn={ENTER:13,ESC:27,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40},wa=fn.LEFT,Ca=fn.RIGHT,Ea=fn.UP,Oo=fn.DOWN,jo=fn.ENTER,Mf=fn.ESC,Tr=fn.HOME,Or=fn.END,wu=[Ea,Oo,wa,Ca];function $y(e,t,n,r){var o,i="prev",a="next",s="children",c="parent";if(e==="inline"&&r===jo)return{inlineTrigger:!0};var l=me(me({},Ea,i),Oo,a),f=me(me(me(me({},wa,n?a:i),Ca,n?i:a),Oo,s),jo,s),u=me(me(me(me(me(me({},Ea,i),Oo,a),jo,s),Mf,c),wa,n?s:c),Ca,n?c:s),m={inline:l,horizontal:f,vertical:u,inlineSub:l,horizontalSub:u,verticalSub:u},p=(o=m["".concat(e).concat(t?"":"Sub")])===null||o===void 0?void 0:o[r];switch(p){case i:return{offset:-1,sibling:!0};case a:return{offset:1,sibling:!0};case c:return{offset:-1,sibling:!1};case s:return{offset:1,sibling:!1};default:return null}}function Fy(e){for(var t=e;t;){if(t.getAttribute("data-menu-list"))return t;t=t.parentElement}return null}function zy(e,t){for(var n=e||document.activeElement;n;){if(t.has(n))return n;n=n.parentElement}return null}function Es(e,t){var n=Ly(e,!0);return n.filter(function(r){return t.has(r)})}function Cu(e,t,n){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:1;if(!e)return null;var o=Es(e,t),i=o.length,a=o.findIndex(function(s){return n===s});return r<0?a===-1?a=i-1:a-=1:r>0&&(a+=1),a=(a+i)%i,o[a]}var Sa=function(t,n){var r=new Set,o=new Map,i=new Map;return t.forEach(function(a){var s=document.querySelector("[data-menu-id='".concat(xf(n,a),"']"));s&&(r.add(s),i.set(s,a),o.set(a,s))}),{elements:r,key2element:o,element2key:i}};function By(e,t,n,r,o,i,a,s,c,l){var f=d.useRef(),u=d.useRef();u.current=t;var m=function(){an.cancel(f.current)};return d.useEffect(function(){return function(){m()}},[]),function(p){var g=p.which;if([].concat(wu,[jo,Mf,Tr,Or]).includes(g)){var b=i(),h=Sa(b,r),x=h,E=x.elements,w=x.key2element,C=x.element2key,S=w.get(t),R=zy(S,E),L=C.get(R),D=$y(e,a(L,!0).length===1,n,g);if(!D&&g!==Tr&&g!==Or)return;(wu.includes(g)||[Tr,Or].includes(g))&&p.preventDefault();var H=function(I){if(I){var N=I,P=I.querySelector("a");P!=null&&P.getAttribute("href")&&(N=P);var j=C.get(I);s(j),m(),f.current=an(function(){u.current===j&&N.focus()})}};if([Tr,Or].includes(g)||D.sibling||!R){var k;!R||e==="inline"?k=o.current:k=Fy(R);var T,F=Es(k,E);g===Tr?T=F[0]:g===Or?T=F[F.length-1]:T=Cu(k,E,R,D.offset),H(T)}else if(D.inlineTrigger)c(L);else if(D.offset>0)c(L,!0),m(),f.current=an(function(){h=Sa(b,r);var M=R.getAttribute("aria-controls"),I=document.getElementById(M),N=Cu(I,h.elements);H(N)},5);else if(D.offset<0){var z=a(L,!0),A=z[z.length-2],_=w.get(A);c(A,!1),H(_)}}l==null||l(p)}}function Hy(e){Promise.resolve().then(e)}var Ss="__RC_UTIL_PATH_SPLIT__",Eu=function(t){return t.join(Ss)},Vy=function(t){return t.split(Ss)},Ra="rc-menu-more";function Wy(){var e=d.useState({}),t=te(e,2),n=t[1],r=y.useRef(new Map),o=y.useRef(new Map),i=d.useState([]),a=te(i,2),s=a[0],c=a[1],l=y.useRef(0),f=y.useRef(!1),u=function(){f.current||n({})},m=y.useCallback(function(w,C){var S=Eu(C);o.current.set(S,w),r.current.set(w,S),l.current+=1;var R=l.current;Hy(function(){R===l.current&&u()})},[]),p=y.useCallback(function(w,C){var S=Eu(C);o.current.delete(S),r.current.delete(w)},[]),g=y.useCallback(function(w){c(w)},[]),b=y.useCallback(function(w,C){var S=r.current.get(w)||"",R=Vy(S);return C&&s.includes(R[0])&&R.unshift(Ra),R},[s]),h=y.useCallback(function(w,C){return w.filter(function(S){return S!==void 0}).some(function(S){var R=b(S,!0);return R.includes(C)})},[b]),x=function(){var C=Yt(r.current.keys());return s.length&&C.push(Ra),C},E=y.useCallback(function(w){var C="".concat(r.current.get(w)).concat(Ss),S=new Set;return Yt(o.current.keys()).forEach(function(R){R.startsWith(C)&&S.add(o.current.get(R))}),S},[]);return d.useEffect(function(){return function(){f.current=!0}},[]),{registerPath:m,unregisterPath:p,refreshOverflowKeys:g,isSubPathKey:h,getKeyPath:b,getKeys:x,getSubPathKeys:E}}function Fr(e){var t=d.useRef(e);t.current=e;var n=d.useCallback(function(){for(var r,o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];return(r=t.current)===null||r===void 0?void 0:r.call.apply(r,[t].concat(i))},[]);return e?n:void 0}var Ky=Math.random().toFixed(5).toString().slice(2),Su=0;function Uy(e){var t=To(e,{value:e}),n=te(t,2),r=n[0],o=n[1];return d.useEffect(function(){Su+=1;var i="".concat(Ky,"-").concat(Su);o("rc-menu-uuid-".concat(i))},[]),r}function Rs(e,t){var n=Object.assign({},e);return Array.isArray(t)&&t.forEach(function(r){delete n[r]}),n}function Nf(e,t,n,r){var o=d.useContext(Tt),i=o.activeKey,a=o.onActive,s=o.onInactive,c={active:i===e};return t||(c.onMouseEnter=function(l){n==null||n({key:e,domEvent:l}),a(e)},c.onMouseLeave=function(l){r==null||r({key:e,domEvent:l}),s(e)}),c}function Pf(e){var t=d.useContext(Tt),n=t.mode,r=t.rtl,o=t.inlineIndent;if(n!=="inline")return null;var i=e;return r?{paddingRight:i*o}:{paddingLeft:i*o}}function kf(e){var t=e.icon,n=e.props,r=e.children,o;return t===null||t===!1?null:(typeof t=="function"?o=d.createElement(t,Z({},n)):typeof t!="boolean"&&(o=t),o||r||null)}var Gy=["item"];function ni(e){var t=e.item,n=Qe(e,Gy);return Object.defineProperty(n,"item",{get:function(){return Rr(!1,"`info.item` is deprecated since we will move to function component that not provides React Node instance in future."),t}}),n}var Yy=["title","attribute","elementRef"],Zy=["style","className","eventKey","warnKey","disabled","itemIcon","children","role","onMouseEnter","onMouseLeave","onClick","onKeyDown","onFocus"],qy=["active"],Xy=(function(e){Pi(n,e);var t=ki(n);function n(){return Mi(this,n),t.apply(this,arguments)}return Ni(n,[{key:"render",value:function(){var o=this.props,i=o.title,a=o.attribute,s=o.elementRef,c=Qe(o,Yy),l=Rs(c,["eventKey","popupClassName","popupOffset","onTitleClick"]);return Rr(!a,"`attribute` of Menu.Item is deprecated. Please pass attribute directly."),d.createElement(sn.Item,Me({},a,{title:typeof i=="string"?i:void 0},l,{ref:s}))}}]),n})(d.Component),Qy=d.forwardRef(function(e,t){var n=e.style,r=e.className,o=e.eventKey;e.warnKey;var i=e.disabled,a=e.itemIcon,s=e.children,c=e.role,l=e.onMouseEnter,f=e.onMouseLeave,u=e.onClick,m=e.onKeyDown,p=e.onFocus,g=Qe(e,Zy),b=wf(o),h=d.useContext(Tt),x=h.prefixCls,E=h.onItemClick,w=h.disabled,C=h.overflowDisabled,S=h.itemIcon,R=h.selectedKeys,L=h.onActive,D=d.useContext(Cs),H=D._internalRenderMenuItem,k="".concat(x,"-item"),T=d.useRef(),F=d.useRef(),z=w||i,A=Ei(t,F),_=uo(o),M=function(q){return{key:o,keyPath:Yt(_).reverse(),item:T.current,domEvent:q}},I=a||S,N=Nf(o,z,l,f),P=N.active,j=Qe(N,qy),B=R.includes(o),K=Pf(_.length),$=function(q){if(!z){var ne=M(q);u==null||u(ni(ne)),E(ne)}},O=function(q){if(m==null||m(q),q.which===fn.ENTER){var ne=M(q);u==null||u(ni(ne)),E(ne)}},V=function(q){L(o),p==null||p(q)},U={};e.role==="option"&&(U["aria-selected"]=B);var oe=d.createElement(Xy,Me({ref:T,elementRef:A,role:c===null?"none":c||"menuitem",tabIndex:i?null:-1,"data-menu-id":C&&b?null:b},Rs(g,["extra"]),j,U,{component:"li","aria-disabled":i,style:Z(Z({},K),n),className:at(k,me(me(me({},"".concat(k,"-active"),P),"".concat(k,"-selected"),B),"".concat(k,"-disabled"),z),r),onClick:$,onKeyDown:O,onFocus:V}),s,d.createElement(kf,{props:Z(Z({},e),{},{isSelected:B}),icon:I}));return H&&(oe=H(oe,e,{selected:B})),oe});function Jy(e,t){var n=e.eventKey,r=_i(),o=uo(n);return d.useEffect(function(){if(r)return r.registerPath(n,o),function(){r.unregisterPath(n,o)}},[o]),r?null:d.createElement(Qy,Me({},e,{ref:t}))}const Ii=d.forwardRef(Jy);var ex=["className","children"],tx=function(t,n){var r=t.className,o=t.children,i=Qe(t,ex),a=d.useContext(Tt),s=a.prefixCls,c=a.mode,l=a.rtl;return d.createElement("ul",Me({className:at(s,l&&"".concat(s,"-rtl"),"".concat(s,"-sub"),"".concat(s,"-").concat(c==="inline"?"inline":"vertical"),r),role:"menu"},i,{"data-menu-list":!0,ref:n}),o)},Ms=d.forwardRef(tx);Ms.displayName="SubMenuList";function Ns(e,t){return qo(e).map(function(n,r){if(d.isValidElement(n)){var o,i,a=n.key,s=(o=(i=n.props)===null||i===void 0?void 0:i.eventKey)!==null&&o!==void 0?o:a,c=s==null;c&&(s="tmp_key-".concat([].concat(Yt(t),[r]).join("-")));var l={key:s,eventKey:s};return d.cloneElement(n,l)}return n})}var _f=d.createContext(null),Ru=[];function nx(e,t){var n=d.useState(function(){if(!dn())return null;var g=document.createElement("div");return g}),r=te(n,1),o=r[0],i=d.useRef(!1),a=d.useContext(_f),s=d.useState(Ru),c=te(s,2),l=c[0],f=c[1],u=a||(i.current?void 0:function(g){f(function(b){var h=[g].concat(Yt(b));return h})});function m(){o.parentElement||document.body.appendChild(o),i.current=!0}function p(){var g;(g=o.parentElement)===null||g===void 0||g.removeChild(o),i.current=!1}return mt(function(){return e?a?a(m):m():p(),p},[e]),mt(function(){l.length&&(l.forEach(function(g){return g()}),f(Ru))},[l]),[o,u]}function rx(e,t){if(!e)return!1;if(e.contains)return e.contains(t);for(var n=t;n;){if(n===e)return!0;n=n.parentNode}return!1}var Mu="data-rc-order",Nu="data-rc-priority",ox="rc-util-key",Ma=new Map;function If(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=e.mark;return t?t.startsWith("data-")?t:"data-".concat(t):ox}function Di(e){if(e.attachTo)return e.attachTo;var t=document.querySelector("head");return t||document.body}function ix(e){return e==="queue"?"prependQueue":e?"prepend":"append"}function Ps(e){return Array.from((Ma.get(e)||e).children).filter(function(t){return t.tagName==="STYLE"})}function Df(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!dn())return null;var n=t.csp,r=t.prepend,o=t.priority,i=o===void 0?0:o,a=ix(r),s=a==="prependQueue",c=document.createElement("style");c.setAttribute(Mu,a),s&&i&&c.setAttribute(Nu,"".concat(i)),n!=null&&n.nonce&&(c.nonce=n==null?void 0:n.nonce),c.innerHTML=e;var l=Di(t),f=l.firstChild;if(r){if(s){var u=(t.styles||Ps(l)).filter(function(m){if(!["prepend","prependQueue"].includes(m.getAttribute(Mu)))return!1;var p=Number(m.getAttribute(Nu)||0);return i>=p});if(u.length)return l.insertBefore(c,u[u.length-1].nextSibling),c}l.insertBefore(c,f)}else l.appendChild(c);return c}function Af(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=Di(t);return(t.styles||Ps(n)).find(function(r){return r.getAttribute(If(t))===e})}function Na(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=Af(e,t);if(n){var r=Di(t);r.removeChild(n)}}function ax(e,t){var n=Ma.get(e);if(!n||!rx(document,n)){var r=Df("",t),o=r.parentNode;Ma.set(e,o),e.removeChild(r)}}function Tf(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=Di(n),o=Ps(r),i=Z(Z({},n),{},{styles:o});ax(r,i);var a=Af(t,i);if(a){var s,c;if((s=i.csp)!==null&&s!==void 0&&s.nonce&&a.nonce!==((c=i.csp)===null||c===void 0?void 0:c.nonce)){var l;a.nonce=(l=i.csp)===null||l===void 0?void 0:l.nonce}return a.innerHTML!==e&&(a.innerHTML=e),a}var f=Df(e,i);return f.setAttribute(If(i),t),f}function sx(e){var t="rc-scrollbar-measure-".concat(Math.random().toString(36).substring(7)),n=document.createElement("div");n.id=t;var r=n.style;r.position="absolute",r.left="0",r.top="0",r.width="100px",r.height="100px",r.overflow="scroll";var o,i;if(e){var a=getComputedStyle(e);r.scrollbarColor=a.scrollbarColor,r.scrollbarWidth=a.scrollbarWidth;var s=getComputedStyle(e,"::-webkit-scrollbar"),c=parseInt(s.width,10),l=parseInt(s.height,10);try{var f=c?"width: ".concat(s.width,";"):"",u=l?"height: ".concat(s.height,";"):"";Tf(`
256
- #`.concat(t,`::-webkit-scrollbar {
257
- `).concat(f,`
258
- `).concat(u,`
259
- }`),t)}catch(g){console.error(g),o=c,i=l}}document.body.appendChild(n);var m=e&&o&&!isNaN(o)?o:n.offsetWidth-n.clientWidth,p=e&&i&&!isNaN(i)?i:n.offsetHeight-n.clientHeight;return document.body.removeChild(n),Na(t),{width:m,height:p}}function ux(e){return typeof document>"u"||!e||!(e instanceof Element)?{width:0,height:0}:sx(e)}function lx(){return document.body.scrollHeight>(window.innerHeight||document.documentElement.clientHeight)&&window.innerWidth>document.body.offsetWidth}var cx="rc-util-locker-".concat(Date.now()),Pu=0;function dx(e){var t=!!e,n=d.useState(function(){return Pu+=1,"".concat(cx,"_").concat(Pu)}),r=te(n,1),o=r[0];mt(function(){if(t){var i=ux(document.body).width,a=lx();Tf(`
260
- html body {
261
- overflow-y: hidden;
262
- `.concat(a?"width: calc(100% - ".concat(i,"px);"):"",`
263
- }`),o)}else Na(o);return function(){Na(o)}},[t,o])}var fx=!1;function vx(e){return fx}var ku=function(t){return t===!1?!1:!dn()||!t?null:typeof t=="string"?document.querySelector(t):typeof t=="function"?t():t},Of=d.forwardRef(function(e,t){var n=e.open,r=e.autoLock,o=e.getContainer;e.debug;var i=e.autoDestroy,a=i===void 0?!0:i,s=e.children,c=d.useState(n),l=te(c,2),f=l[0],u=l[1],m=f||n;d.useEffect(function(){(a||n)&&u(n)},[n,a]);var p=d.useState(function(){return ku(o)}),g=te(p,2),b=g[0],h=g[1];d.useEffect(function(){var T=ku(o);h(T!=null?T:null)});var x=nx(m&&!b),E=te(x,2),w=E[0],C=E[1],S=b!=null?b:w;dx(r&&n&&dn()&&(S===w||S===document.body));var R=null;if(s&&Si(s)&&t){var L=s;R=L.ref}var D=Ei(R,t);if(!m||!dn()||b===void 0)return null;var H=S===!1||vx(),k=s;return t&&(k=d.cloneElement(s,{ref:D})),d.createElement(_f.Provider,{value:C},H?k:ut.createPortal(k,S))});function jf(e){var t;return e==null||(t=e.getRootNode)===null||t===void 0?void 0:t.call(e)}function mx(e){return jf(e)instanceof ShadowRoot}function Pa(e){return mx(e)?jf(e):null}function px(){var e=Z({},d);return e.useId}var _u=0,Iu=px();const hx=Iu?(function(t){var n=Iu();return t||n}):(function(t){var n=d.useState("ssr-id"),r=te(n,2),o=r[0],i=r[1];return d.useEffect(function(){var a=_u;_u+=1,i("rc_unique_".concat(a))},[]),t||o}),gx=(function(){if(typeof navigator>"u"||typeof window>"u")return!1;var e=navigator.userAgent||navigator.vendor||window.opera;return/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino|android|ipad|playbook|silk/i.test(e)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw-(n|u)|c55\/|capi|ccwa|cdm-|cell|chtm|cldc|cmd-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc-s|devi|dica|dmob|do(c|p)o|ds(12|-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(-|_)|g1 u|g560|gene|gf-5|g-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd-(m|p|t)|hei-|hi(pt|ta)|hp( i|ip)|hs-c|ht(c(-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i-(20|go|ma)|i230|iac( |-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|-[a-w])|libw|lynx|m1-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|-([1-8]|c))|phil|pire|pl(ay|uc)|pn-2|po(ck|rt|se)|prox|psio|pt-g|qa-a|qc(07|12|21|32|60|-[2-7]|i-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h-|oo|p-)|sdk\/|se(c(-|0|1)|47|mc|nd|ri)|sgh-|shar|sie(-|m)|sk-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h-|v-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl-|tdg-|tel(i|m)|tim-|t-mo|to(pl|sh)|ts(70|m-|m3|m5)|tx-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas-|your|zeto|zte-/i.test(e==null?void 0:e.substr(0,4))});var bx=d.createContext({}),yx=(function(e){Pi(n,e);var t=ki(n);function n(){return Mi(this,n),t.apply(this,arguments)}return Ni(n,[{key:"render",value:function(){return this.props.children}}]),n})(d.Component);function xx(e){var t=d.useReducer(function(s){return s+1},0),n=te(t,2),r=n[1],o=d.useRef(e),i=xt(function(){return o.current}),a=xt(function(s){o.current=typeof s=="function"?s(o.current):s,r()});return[i,a]}var Mn="none",Co="appear",Eo="enter",So="leave",Du="none",It="prepare",ur="start",lr="active",ks="end",Lf="prepared";function Au(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit".concat(e)]="webkit".concat(t),n["Moz".concat(e)]="moz".concat(t),n["ms".concat(e)]="MS".concat(t),n["O".concat(e)]="o".concat(t.toLowerCase()),n}function wx(e,t){var n={animationend:Au("Animation","AnimationEnd"),transitionend:Au("Transition","TransitionEnd")};return e&&("AnimationEvent"in t||delete n.animationend.animation,"TransitionEvent"in t||delete n.transitionend.transition),n}var Cx=wx(dn(),typeof window<"u"?window:{}),$f={};if(dn()){var Ex=document.createElement("div");$f=Ex.style}var Ro={};function Ff(e){if(Ro[e])return Ro[e];var t=Cx[e];if(t)for(var n=Object.keys(t),r=n.length,o=0;o<r;o+=1){var i=n[o];if(Object.prototype.hasOwnProperty.call(t,i)&&i in $f)return Ro[e]=t[i],Ro[e]}return""}var zf=Ff("animationend"),Bf=Ff("transitionend"),Hf=!!(zf&&Bf),Tu=zf||"animationend",Ou=Bf||"transitionend";function ju(e,t){if(!e)return null;if(lt(e)==="object"){var n=t.replace(/-\w/g,function(r){return r[1].toUpperCase()});return e[n]}return"".concat(e,"-").concat(t)}const Sx=(function(e){var t=y.useRef();function n(o){o&&(o.removeEventListener(Ou,e),o.removeEventListener(Tu,e))}function r(o){t.current&&t.current!==o&&n(t.current),o&&o!==t.current&&(o.addEventListener(Ou,e),o.addEventListener(Tu,e),t.current=o)}return d.useEffect(function(){return function(){n(t.current)}},[]),[r,n]});var Vf=dn()?y.useLayoutEffect:y.useEffect;const Rx=(function(){var e=d.useRef(null);function t(){an.cancel(e.current)}function n(r){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:2;t();var i=an(function(){o<=1?r({isCanceled:function(){return i!==e.current}}):n(r,o-1)});e.current=i}return d.useEffect(function(){return function(){t()}},[]),[n,t]});var Mx=[It,ur,lr,ks],Nx=[It,Lf],Wf=!1,Px=!0;function Kf(e){return e===lr||e===ks}const kx=(function(e,t,n){var r=Zr(Du),o=te(r,2),i=o[0],a=o[1],s=Rx(),c=te(s,2),l=c[0],f=c[1];function u(){a(It,!0)}var m=t?Nx:Mx;return Vf(function(){if(i!==Du&&i!==ks){var p=m.indexOf(i),g=m[p+1],b=n(i);b===Wf?a(g,!0):g&&l(function(h){function x(){h.isCanceled()||a(g,!0)}b===!0?x():Promise.resolve(b).then(x)})}},[e,i]),d.useEffect(function(){return function(){f()}},[]),[u,i]});function _x(e,t,n,r){var o=r.motionEnter,i=o===void 0?!0:o,a=r.motionAppear,s=a===void 0?!0:a,c=r.motionLeave,l=c===void 0?!0:c,f=r.motionDeadline,u=r.motionLeaveImmediately,m=r.onAppearPrepare,p=r.onEnterPrepare,g=r.onLeavePrepare,b=r.onAppearStart,h=r.onEnterStart,x=r.onLeaveStart,E=r.onAppearActive,w=r.onEnterActive,C=r.onLeaveActive,S=r.onAppearEnd,R=r.onEnterEnd,L=r.onLeaveEnd,D=r.onVisibleChanged,H=Zr(),k=te(H,2),T=k[0],F=k[1],z=xx(Mn),A=te(z,2),_=A[0],M=A[1],I=Zr(null),N=te(I,2),P=N[0],j=N[1],B=_(),K=y.useRef(!1),$=y.useRef(null);function O(){return n()}var V=y.useRef(!1);function U(){M(Mn),j(null,!0)}var oe=xt(function(le){var ce=_();if(ce!==Mn){var re=O();if(!(le&&!le.deadline&&le.target!==re)){var Je=V.current,Fe;ce===Co&&Je?Fe=S==null?void 0:S(re,le):ce===Eo&&Je?Fe=R==null?void 0:R(re,le):ce===So&&Je&&(Fe=L==null?void 0:L(re,le)),Je&&Fe!==!1&&U()}}}),G=Sx(oe),q=te(G,1),ne=q[0],ae=function(ce){switch(ce){case Co:return me(me(me({},It,m),ur,b),lr,E);case Eo:return me(me(me({},It,p),ur,h),lr,w);case So:return me(me(me({},It,g),ur,x),lr,C);default:return{}}},ue=d.useMemo(function(){return ae(B)},[B]),he=kx(B,!e,function(le){if(le===It){var ce=ue[It];return ce?ce(O()):Wf}if(Ne in ue){var re;j(((re=ue[Ne])===null||re===void 0?void 0:re.call(ue,O(),null))||null)}return Ne===lr&&B!==Mn&&(ne(O()),f>0&&(clearTimeout($.current),$.current=setTimeout(function(){oe({deadline:!0})},f))),Ne===Lf&&U(),Px}),xe=te(he,2),ge=xe[0],Ne=xe[1],ke=Kf(Ne);V.current=ke;var be=y.useRef(null);Vf(function(){if(!(K.current&&be.current===t)){F(t);var le=K.current;K.current=!0;var ce;!le&&t&&s&&(ce=Co),le&&t&&i&&(ce=Eo),(le&&!t&&l||!le&&u&&!t&&l)&&(ce=So);var re=ae(ce);ce&&(e||re[It])?(M(ce),ge()):M(Mn),be.current=t}},[t]),y.useEffect(function(){(B===Co&&!s||B===Eo&&!i||B===So&&!l)&&M(Mn)},[s,i,l]),y.useEffect(function(){return function(){K.current=!1,clearTimeout($.current)}},[]);var ye=d.useRef(!1);y.useEffect(function(){T&&(ye.current=!0),T!==void 0&&B===Mn&&((ye.current||T)&&(D==null||D(T)),ye.current=!0)},[T,B]);var Le=P;return ue[It]&&Ne===ur&&(Le=Z({transition:"none"},Le)),[B,Ne,Le,T!=null?T:t]}function Ix(e){var t=e;lt(e)==="object"&&(t=e.transitionSupport);function n(o,i){return!!(o.motionName&&t&&i!==!1)}var r=d.forwardRef(function(o,i){var a=o.visible,s=a===void 0?!0:a,c=o.removeOnLeave,l=c===void 0?!0:c,f=o.forceRender,u=o.children,m=o.motionName,p=o.leavedClassName,g=o.eventProps,b=d.useContext(bx),h=b.motion,x=n(o,h),E=y.useRef(),w=y.useRef();function C(){try{return E.current instanceof HTMLElement?E.current:Ao(w.current)}catch{return null}}var S=_x(x,s,C,o),R=te(S,4),L=R[0],D=R[1],H=R[2],k=R[3],T=d.useRef(k);k&&(T.current=!0);var F=d.useCallback(function(N){E.current=N,ys(i,N)},[i]),z,A=Z(Z({},g),{},{visible:s});if(!u)z=null;else if(L===Mn)k?z=u(Z({},A),F):!l&&T.current&&p?z=u(Z(Z({},A),{},{className:p}),F):f||!l&&!p?z=u(Z(Z({},A),{},{style:{display:"none"}}),F):z=null;else{var _;D===It?_="prepare":Kf(D)?_="active":D===ur&&(_="start");var M=ju(m,"".concat(L,"-").concat(_));z=u(Z(Z({},A),{},{className:at(ju(m,L),me(me({},M,M&&_),m,typeof m=="string")),style:H}),F)}if(d.isValidElement(z)&&Si(z)){var I=xs(z);I||(z=d.cloneElement(z,{ref:F}))}return d.createElement(yx,{ref:w},z)});return r.displayName="CSSMotion",r}const Ai=Ix(Hf);var ka="add",_a="keep",Ia="remove",oa="removed";function Dx(e){var t;return e&&lt(e)==="object"&&"key"in e?t=e:t={key:e},Z(Z({},t),{},{key:String(t.key)})}function Da(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return e.map(Dx)}function Ax(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],n=[],r=0,o=t.length,i=Da(e),a=Da(t);i.forEach(function(l){for(var f=!1,u=r;u<o;u+=1){var m=a[u];if(m.key===l.key){r<u&&(n=n.concat(a.slice(r,u).map(function(p){return Z(Z({},p),{},{status:ka})})),r=u),n.push(Z(Z({},m),{},{status:_a})),r+=1,f=!0;break}}f||n.push(Z(Z({},l),{},{status:Ia}))}),r<o&&(n=n.concat(a.slice(r).map(function(l){return Z(Z({},l),{},{status:ka})})));var s={};n.forEach(function(l){var f=l.key;s[f]=(s[f]||0)+1});var c=Object.keys(s).filter(function(l){return s[l]>1});return c.forEach(function(l){n=n.filter(function(f){var u=f.key,m=f.status;return u!==l||m!==Ia}),n.forEach(function(f){f.key===l&&(f.status=_a)})}),n}var Tx=["component","children","onVisibleChanged","onAllRemoved"],Ox=["status"],jx=["eventProps","visible","children","motionName","motionAppear","motionEnter","motionLeave","motionLeaveImmediately","motionDeadline","removeOnLeave","leavedClassName","onAppearPrepare","onAppearStart","onAppearActive","onAppearEnd","onEnterStart","onEnterActive","onEnterEnd","onLeaveStart","onLeaveActive","onLeaveEnd"];function Lx(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Ai,n=(function(r){Pi(i,r);var o=ki(i);function i(){var a;Mi(this,i);for(var s=arguments.length,c=new Array(s),l=0;l<s;l++)c[l]=arguments[l];return a=o.call.apply(o,[this].concat(c)),me(xa(a),"state",{keyEntities:[]}),me(xa(a),"removeKey",function(f){a.setState(function(u){var m=u.keyEntities.map(function(p){return p.key!==f?p:Z(Z({},p),{},{status:oa})});return{keyEntities:m}},function(){var u=a.state.keyEntities,m=u.filter(function(p){var g=p.status;return g!==oa}).length;m===0&&a.props.onAllRemoved&&a.props.onAllRemoved()})}),a}return Ni(i,[{key:"render",value:function(){var s=this,c=this.state.keyEntities,l=this.props,f=l.component,u=l.children,m=l.onVisibleChanged;l.onAllRemoved;var p=Qe(l,Tx),g=f||d.Fragment,b={};return jx.forEach(function(h){b[h]=p[h],delete p[h]}),delete p.keys,d.createElement(g,p,c.map(function(h,x){var E=h.status,w=Qe(h,Ox),C=E===ka||E===_a;return d.createElement(t,Me({},b,{key:w.key,visible:C,eventProps:w,onVisibleChanged:function(R){m==null||m(R,{key:w.key}),R||s.removeKey(w.key)}}),function(S,R){return u(Z(Z({},S),{},{index:x}),R)})}))}}],[{key:"getDerivedStateFromProps",value:function(s,c){var l=s.keys,f=c.keyEntities,u=Da(l),m=Ax(f,u);return{keyEntities:m.filter(function(p){var g=f.find(function(b){var h=b.key;return p.key===h});return!(g&&g.status===oa&&p.status===Ia)})}}}]),i})(d.Component);return me(n,"defaultProps",{component:"div"}),n}Lx(Hf);function $x(e){var t=e.prefixCls,n=e.align,r=e.arrow,o=e.arrowPos,i=r||{},a=i.className,s=i.content,c=o.x,l=c===void 0?0:c,f=o.y,u=f===void 0?0:f,m=d.useRef();if(!n||!n.points)return null;var p={position:"absolute"};if(n.autoArrow!==!1){var g=n.points[0],b=n.points[1],h=g[0],x=g[1],E=b[0],w=b[1];h===E||!["t","b"].includes(h)?p.top=u:h==="t"?p.top=0:p.bottom=0,x===w||!["l","r"].includes(x)?p.left=l:x==="l"?p.left=0:p.right=0}return d.createElement("div",{ref:m,className:at("".concat(t,"-arrow"),a),style:p},s)}function Fx(e){var t=e.prefixCls,n=e.open,r=e.zIndex,o=e.mask,i=e.motion;return o?d.createElement(Ai,Me({},i,{motionAppear:!0,visible:n,removeOnLeave:!0}),function(a){var s=a.className;return d.createElement("div",{style:{zIndex:r},className:at("".concat(t,"-mask"),s)})}):null}var zx=d.memo(function(e){var t=e.children;return t},function(e,t){return t.cache}),Bx=d.forwardRef(function(e,t){var n=e.popup,r=e.className,o=e.prefixCls,i=e.style,a=e.target,s=e.onVisibleChanged,c=e.open,l=e.keepDom,f=e.fresh,u=e.onClick,m=e.mask,p=e.arrow,g=e.arrowPos,b=e.align,h=e.motion,x=e.maskMotion,E=e.forceRender,w=e.getPopupContainer,C=e.autoDestroy,S=e.portal,R=e.zIndex,L=e.onMouseEnter,D=e.onMouseLeave,H=e.onPointerEnter,k=e.onPointerDownCapture,T=e.ready,F=e.offsetX,z=e.offsetY,A=e.offsetR,_=e.offsetB,M=e.onAlign,I=e.onPrepare,N=e.stretch,P=e.targetWidth,j=e.targetHeight,B=typeof n=="function"?n():n,K=c||l,$=(w==null?void 0:w.length)>0,O=d.useState(!w||!$),V=te(O,2),U=V[0],oe=V[1];if(mt(function(){!U&&$&&a&&oe(!0)},[U,$,a]),!U)return null;var G="auto",q={left:"-1000vw",top:"-1000vh",right:G,bottom:G};if(T||!c){var ne,ae=b.points,ue=b.dynamicInset||((ne=b._experimental)===null||ne===void 0?void 0:ne.dynamicInset),he=ue&&ae[0][1]==="r",xe=ue&&ae[0][0]==="b";he?(q.right=A,q.left=G):(q.left=F,q.right=G),xe?(q.bottom=_,q.top=G):(q.top=z,q.bottom=G)}var ge={};return N&&(N.includes("height")&&j?ge.height=j:N.includes("minHeight")&&j&&(ge.minHeight=j),N.includes("width")&&P?ge.width=P:N.includes("minWidth")&&P&&(ge.minWidth=P)),c||(ge.pointerEvents="none"),d.createElement(S,{open:E||K,getContainer:w&&function(){return w(a)},autoDestroy:C},d.createElement(Fx,{prefixCls:o,open:c,zIndex:R,mask:m,motion:x}),d.createElement(so,{onResize:M,disabled:!c},function(Ne){return d.createElement(Ai,Me({motionAppear:!0,motionEnter:!0,motionLeave:!0,removeOnLeave:!1,forceRender:E,leavedClassName:"".concat(o,"-hidden")},h,{onAppearPrepare:I,onEnterPrepare:I,visible:c,onVisibleChanged:function(be){var ye;h==null||(ye=h.onVisibleChanged)===null||ye===void 0||ye.call(h,be),s(be)}}),function(ke,be){var ye=ke.className,Le=ke.style,le=at(o,ye,r);return d.createElement("div",{ref:nf(Ne,t,be),className:le,style:Z(Z(Z(Z({"--arrow-x":"".concat(g.x||0,"px"),"--arrow-y":"".concat(g.y||0,"px")},q),ge),Le),{},{boxSizing:"border-box",zIndex:R},i),onMouseEnter:L,onMouseLeave:D,onPointerEnter:H,onClick:u,onPointerDownCapture:k},p&&d.createElement($x,{prefixCls:o,arrow:p,arrowPos:g,align:b}),d.createElement(zx,{cache:!c&&!f},B))})}))}),Hx=d.forwardRef(function(e,t){var n=e.children,r=e.getTriggerDOMNode,o=Si(n),i=d.useCallback(function(s){ys(t,r?r(s):s)},[r]),a=Ei(i,xs(n));return o?d.cloneElement(n,{ref:a}):n}),Lu=d.createContext(null);function $u(e){return e?Array.isArray(e)?e:[e]:[]}function Vx(e,t,n,r){return d.useMemo(function(){var o=$u(n!=null?n:t),i=$u(r!=null?r:t),a=new Set(o),s=new Set(i);return e&&(a.has("hover")&&(a.delete("hover"),a.add("click")),s.has("hover")&&(s.delete("hover"),s.add("click"))),[a,s]},[e,t,n,r])}function Wx(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],n=arguments.length>2?arguments[2]:void 0;return n?e[0]===t[0]:e[0]===t[0]&&e[1]===t[1]}function Kx(e,t,n,r){for(var o=n.points,i=Object.keys(e),a=0;a<i.length;a+=1){var s,c=i[a];if(Wx((s=e[c])===null||s===void 0?void 0:s.points,o,r))return"".concat(t,"-placement-").concat(c)}return""}function Fu(e,t,n,r){return t||(n?{motionName:"".concat(e,"-").concat(n)}:r?{motionName:r}:null)}function lo(e){return e.ownerDocument.defaultView}function Aa(e){for(var t=[],n=e==null?void 0:e.parentElement,r=["hidden","scroll","clip","auto"];n;){var o=lo(n).getComputedStyle(n),i=o.overflowX,a=o.overflowY,s=o.overflow;[i,a,s].some(function(c){return r.includes(c)})&&t.push(n),n=n.parentElement}return t}function Xr(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;return Number.isNaN(e)?t:e}function jr(e){return Xr(parseFloat(e),0)}function zu(e,t){var n=Z({},e);return(t||[]).forEach(function(r){if(!(r instanceof HTMLBodyElement||r instanceof HTMLHtmlElement)){var o=lo(r).getComputedStyle(r),i=o.overflow,a=o.overflowClipMargin,s=o.borderTopWidth,c=o.borderBottomWidth,l=o.borderLeftWidth,f=o.borderRightWidth,u=r.getBoundingClientRect(),m=r.offsetHeight,p=r.clientHeight,g=r.offsetWidth,b=r.clientWidth,h=jr(s),x=jr(c),E=jr(l),w=jr(f),C=Xr(Math.round(u.width/g*1e3)/1e3),S=Xr(Math.round(u.height/m*1e3)/1e3),R=(g-b-E-w)*C,L=(m-p-h-x)*S,D=h*S,H=x*S,k=E*C,T=w*C,F=0,z=0;if(i==="clip"){var A=jr(a);F=A*C,z=A*S}var _=u.x+k-F,M=u.y+D-z,I=_+u.width+2*F-k-T-R,N=M+u.height+2*z-D-H-L;n.left=Math.max(n.left,_),n.top=Math.max(n.top,M),n.right=Math.min(n.right,I),n.bottom=Math.min(n.bottom,N)}}),n}function Bu(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n="".concat(t),r=n.match(/^(.*)\%$/);return r?e*(parseFloat(r[1])/100):parseFloat(n)}function Hu(e,t){var n=t||[],r=te(n,2),o=r[0],i=r[1];return[Bu(e.width,o),Bu(e.height,i)]}function Vu(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";return[e[0],e[1]]}function ir(e,t){var n=t[0],r=t[1],o,i;return n==="t"?i=e.y:n==="b"?i=e.y+e.height:i=e.y+e.height/2,r==="l"?o=e.x:r==="r"?o=e.x+e.width:o=e.x+e.width/2,{x:o,y:i}}function Sn(e,t){var n={t:"b",b:"t",l:"r",r:"l"};return e.map(function(r,o){return o===t?n[r]||"c":r}).join("")}function Ux(e,t,n,r,o,i,a){var s=d.useState({ready:!1,offsetX:0,offsetY:0,offsetR:0,offsetB:0,arrowX:0,arrowY:0,scaleX:1,scaleY:1,align:o[r]||{}}),c=te(s,2),l=c[0],f=c[1],u=d.useRef(0),m=d.useMemo(function(){return t?Aa(t):[]},[t]),p=d.useRef({}),g=function(){p.current={}};e||g();var b=xt(function(){if(t&&n&&e){let Rt=function(er,xn){var wn=arguments.length>2&&arguments[2]!==void 0?arguments[2]:Je,_r=O.x+er,vo=O.y+xn,ji=_r+he,Li=vo+ue,$i=Math.max(_r,wn.left),Q=Math.max(vo,wn.top),se=Math.min(ji,wn.right),je=Math.min(Li,wn.bottom);return Math.max(0,(se-$i)*(je-Q))},fo=function(){Lt=O.y+Y,en=Lt+ue,Et=O.x+ee,pn=Et+he};var E,w,C,S,R=t,L=R.ownerDocument,D=lo(R),H=D.getComputedStyle(R),k=H.width,T=H.height,F=H.position,z=R.style.left,A=R.style.top,_=R.style.right,M=R.style.bottom,I=R.style.overflow,N=Z(Z({},o[r]),i),P=L.createElement("div");(E=R.parentElement)===null||E===void 0||E.appendChild(P),P.style.left="".concat(R.offsetLeft,"px"),P.style.top="".concat(R.offsetTop,"px"),P.style.position=F,P.style.height="".concat(R.offsetHeight,"px"),P.style.width="".concat(R.offsetWidth,"px"),R.style.left="0",R.style.top="0",R.style.right="auto",R.style.bottom="auto",R.style.overflow="hidden";var j;if(Array.isArray(n))j={x:n[0],y:n[1],width:0,height:0};else{var B,K,$=n.getBoundingClientRect();$.x=(B=$.x)!==null&&B!==void 0?B:$.left,$.y=(K=$.y)!==null&&K!==void 0?K:$.top,j={x:$.x,y:$.y,width:$.width,height:$.height}}var O=R.getBoundingClientRect();O.x=(w=O.x)!==null&&w!==void 0?w:O.left,O.y=(C=O.y)!==null&&C!==void 0?C:O.top;var V=L.documentElement,U=V.clientWidth,oe=V.clientHeight,G=V.scrollWidth,q=V.scrollHeight,ne=V.scrollTop,ae=V.scrollLeft,ue=O.height,he=O.width,xe=j.height,ge=j.width,Ne={left:0,top:0,right:U,bottom:oe},ke={left:-ae,top:-ne,right:G-ae,bottom:q-ne},be=N.htmlRegion,ye="visible",Le="visibleFirst";be!=="scroll"&&be!==Le&&(be=ye);var le=be===Le,ce=zu(ke,m),re=zu(Ne,m),Je=be===ye?re:ce,Fe=le?re:Je;R.style.left="auto",R.style.top="auto",R.style.right="0",R.style.bottom="0";var pe=R.getBoundingClientRect();R.style.left=z,R.style.top=A,R.style.right=_,R.style.bottom=M,R.style.overflow=I,(S=R.parentElement)===null||S===void 0||S.removeChild(P);var et=Xr(Math.round(he/parseFloat(k)*1e3)/1e3),tt=Xr(Math.round(ue/parseFloat(T)*1e3)/1e3);if(et===0||tt===0||Yr(n)&&!Rf(n))return;var Oe=N.offset,He=N.targetOffset,Ve=Hu(O,Oe),_e=te(Ve,2),Ae=_e[0],Re=_e[1],Be=Hu(j,He),Ie=te(Be,2),nt=Ie[0],Ye=Ie[1];j.x-=nt,j.y-=Ye;var rt=N.points||[],Pt=te(rt,2),ft=Pt[0],jt=Pt[1],Ze=Vu(jt),X=Vu(ft),Ce=ir(j,Ze),fe=ir(O,X),J=Z({},N),ee=Ce.x-fe.x+Ae,Y=Ce.y-fe.y+Re,ve=Rt(ee,Y),We=Rt(ee,Y,re),Ke=ir(j,["t","l"]),De=ir(O,["t","l"]),Xt=ir(j,["b","r"]),vt=ir(O,["b","r"]),Ct=N.overflow||{},Qt=Ct.adjustX,Mr=Ct.adjustY,Jt=Ct.shiftX,pt=Ct.shiftY,mn=function(xn){return typeof xn=="boolean"?xn:xn>=0},Lt,en,Et,pn;fo();var $t=mn(Mr),Gn=X[0]===Ze[0];if($t&&X[0]==="t"&&(en>Fe.bottom||p.current.bt)){var qe=Y;Gn?qe-=ue-xe:qe=Ke.y-vt.y-Re;var Yn=Rt(ee,qe),Nr=Rt(ee,qe,re);Yn>ve||Yn===ve&&(!le||Nr>=We)?(p.current.bt=!0,Y=qe,Re=-Re,J.points=[Sn(X,0),Sn(Ze,0)]):p.current.bt=!1}if($t&&X[0]==="b"&&(Lt<Fe.top||p.current.tb)){var Ft=Y;Gn?Ft+=ue-xe:Ft=Xt.y-De.y-Re;var zt=Rt(ee,Ft),jn=Rt(ee,Ft,re);zt>ve||zt===ve&&(!le||jn>=We)?(p.current.tb=!0,Y=Ft,Re=-Re,J.points=[Sn(X,0),Sn(Ze,0)]):p.current.tb=!1}var Zn=mn(Qt),qn=X[1]===Ze[1];if(Zn&&X[1]==="l"&&(pn>Fe.right||p.current.rl)){var tn=ee;qn?tn-=he-ge:tn=Ke.x-vt.x-Ae;var Ln=Rt(tn,Y),kt=Rt(tn,Y,re);Ln>ve||Ln===ve&&(!le||kt>=We)?(p.current.rl=!0,ee=tn,Ae=-Ae,J.points=[Sn(X,1),Sn(Ze,1)]):p.current.rl=!1}if(Zn&&X[1]==="r"&&(Et<Fe.left||p.current.lr)){var _t=ee;qn?_t+=he-ge:_t=Xt.x-De.x-Ae;var Xn=Rt(_t,Y),Qn=Rt(_t,Y,re);Xn>ve||Xn===ve&&(!le||Qn>=We)?(p.current.lr=!0,ee=_t,Ae=-Ae,J.points=[Sn(X,1),Sn(Ze,1)]):p.current.lr=!1}fo();var gt=Jt===!0?0:Jt;typeof gt=="number"&&(Et<re.left&&(ee-=Et-re.left-Ae,j.x+ge<re.left+gt&&(ee+=j.x-re.left+ge-gt)),pn>re.right&&(ee-=pn-re.right-Ae,j.x>re.right-gt&&(ee+=j.x-re.right+gt)));var bt=pt===!0?0:pt;typeof bt=="number"&&(Lt<re.top&&(Y-=Lt-re.top-Re,j.y+xe<re.top+bt&&(Y+=j.y-re.top+xe-bt)),en>re.bottom&&(Y-=en-re.bottom-Re,j.y>re.bottom-bt&&(Y+=j.y-re.bottom+bt)));var hn=O.x+ee,gn=hn+he,St=O.y+Y,Pr=St+ue,Pe=j.x,we=Pe+ge,Ee=j.y,ot=Ee+xe,it=Math.max(hn,Pe),bn=Math.min(gn,we),yn=(it+bn)/2,kr=yn-hn,Jn=Math.max(St,Ee),$n=Math.min(Pr,ot),nn=(Jn+$n)/2,Fn=nn-St;a==null||a(t,J);var zn=pe.right-O.x-(ee+O.width),Bt=pe.bottom-O.y-(Y+O.height);et===1&&(ee=Math.round(ee),zn=Math.round(zn)),tt===1&&(Y=Math.round(Y),Bt=Math.round(Bt));var Oi={ready:!0,offsetX:ee/et,offsetY:Y/tt,offsetR:zn/et,offsetB:Bt/tt,arrowX:kr/et,arrowY:Fn/tt,scaleX:et,scaleY:tt,align:J};f(Oi)}}),h=function(){u.current+=1;var w=u.current;Promise.resolve().then(function(){u.current===w&&b()})},x=function(){f(function(w){return Z(Z({},w),{},{ready:!1})})};return mt(x,[r]),mt(function(){e||x()},[e]),[l.ready,l.offsetX,l.offsetY,l.offsetR,l.offsetB,l.arrowX,l.arrowY,l.scaleX,l.scaleY,l.align,h]}function Gx(e,t,n,r,o){mt(function(){if(e&&t&&n){let u=function(){r(),o()};var i=t,a=n,s=Aa(i),c=Aa(a),l=lo(a),f=new Set([l].concat(Yt(s),Yt(c)));return f.forEach(function(m){m.addEventListener("scroll",u,{passive:!0})}),l.addEventListener("resize",u,{passive:!0}),r(),function(){f.forEach(function(m){m.removeEventListener("scroll",u),l.removeEventListener("resize",u)})}}},[e,t,n])}function Yx(e,t,n,r,o,i,a,s){var c=d.useRef(e);c.current=e;var l=d.useRef(!1);d.useEffect(function(){if(t&&r&&(!o||i)){var u=function(){l.current=!1},m=function(h){var x;c.current&&!a(((x=h.composedPath)===null||x===void 0||(x=x.call(h))===null||x===void 0?void 0:x[0])||h.target)&&!l.current&&s(!1)},p=lo(r);p.addEventListener("pointerdown",u,!0),p.addEventListener("mousedown",m,!0),p.addEventListener("contextmenu",m,!0);var g=Pa(n);return g&&(g.addEventListener("mousedown",m,!0),g.addEventListener("contextmenu",m,!0)),function(){p.removeEventListener("pointerdown",u,!0),p.removeEventListener("mousedown",m,!0),p.removeEventListener("contextmenu",m,!0),g&&(g.removeEventListener("mousedown",m,!0),g.removeEventListener("contextmenu",m,!0))}}},[t,n,r,o,i]);function f(){l.current=!0}return f}var Zx=["prefixCls","children","action","showAction","hideAction","popupVisible","defaultPopupVisible","onPopupVisibleChange","afterPopupVisibleChange","mouseEnterDelay","mouseLeaveDelay","focusDelay","blurDelay","mask","maskClosable","getPopupContainer","forceRender","autoDestroy","destroyPopupOnHide","popup","popupClassName","popupStyle","popupPlacement","builtinPlacements","popupAlign","zIndex","stretch","getPopupClassNameFromAlign","fresh","alignPoint","onPopupClick","onPopupAlign","arrow","popupMotion","maskMotion","popupTransitionName","popupAnimation","maskTransitionName","maskAnimation","className","getTriggerDOMNode"];function qx(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Of,t=d.forwardRef(function(n,r){var o=n.prefixCls,i=o===void 0?"rc-trigger-popup":o,a=n.children,s=n.action,c=s===void 0?"hover":s,l=n.showAction,f=n.hideAction,u=n.popupVisible,m=n.defaultPopupVisible,p=n.onPopupVisibleChange,g=n.afterPopupVisibleChange,b=n.mouseEnterDelay,h=n.mouseLeaveDelay,x=h===void 0?.1:h,E=n.focusDelay,w=n.blurDelay,C=n.mask,S=n.maskClosable,R=S===void 0?!0:S,L=n.getPopupContainer,D=n.forceRender,H=n.autoDestroy,k=n.destroyPopupOnHide,T=n.popup,F=n.popupClassName,z=n.popupStyle,A=n.popupPlacement,_=n.builtinPlacements,M=_===void 0?{}:_,I=n.popupAlign,N=n.zIndex,P=n.stretch,j=n.getPopupClassNameFromAlign,B=n.fresh,K=n.alignPoint,$=n.onPopupClick,O=n.onPopupAlign,V=n.arrow,U=n.popupMotion,oe=n.maskMotion,G=n.popupTransitionName,q=n.popupAnimation,ne=n.maskTransitionName,ae=n.maskAnimation,ue=n.className,he=n.getTriggerDOMNode,xe=Qe(n,Zx),ge=H||k||!1,Ne=d.useState(!1),ke=te(Ne,2),be=ke[0],ye=ke[1];mt(function(){ye(gx())},[]);var Le=d.useRef({}),le=d.useContext(Lu),ce=d.useMemo(function(){return{registerSubPopup:function(se,je){Le.current[se]=je,le==null||le.registerSubPopup(se,je)}}},[le]),re=hx(),Je=d.useState(null),Fe=te(Je,2),pe=Fe[0],et=Fe[1],tt=d.useRef(null),Oe=xt(function(Q){tt.current=Q,Yr(Q)&&pe!==Q&&et(Q),le==null||le.registerSubPopup(re,Q)}),He=d.useState(null),Ve=te(He,2),_e=Ve[0],Ae=Ve[1],Re=d.useRef(null),Be=xt(function(Q){Yr(Q)&&_e!==Q&&(Ae(Q),Re.current=Q)}),Ie=d.Children.only(a),nt=(Ie==null?void 0:Ie.props)||{},Ye={},rt=xt(function(Q){var se,je,Xe=_e;return(Xe==null?void 0:Xe.contains(Q))||((se=Pa(Xe))===null||se===void 0?void 0:se.host)===Q||Q===Xe||(pe==null?void 0:pe.contains(Q))||((je=Pa(pe))===null||je===void 0?void 0:je.host)===Q||Q===pe||Object.values(Le.current).some(function(ze){return(ze==null?void 0:ze.contains(Q))||Q===ze})}),Pt=Fu(i,U,q,G),ft=Fu(i,oe,ae,ne),jt=d.useState(m||!1),Ze=te(jt,2),X=Ze[0],Ce=Ze[1],fe=u!=null?u:X,J=xt(function(Q){u===void 0&&Ce(Q)});mt(function(){Ce(u||!1)},[u]);var ee=d.useRef(fe);ee.current=fe;var Y=d.useRef([]);Y.current=[];var ve=xt(function(Q){var se;J(Q),((se=Y.current[Y.current.length-1])!==null&&se!==void 0?se:fe)!==Q&&(Y.current.push(Q),p==null||p(Q))}),We=d.useRef(),Ke=function(){clearTimeout(We.current)},De=function(se){var je=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;Ke(),je===0?ve(se):We.current=setTimeout(function(){ve(se)},je*1e3)};d.useEffect(function(){return Ke},[]);var Xt=d.useState(!1),vt=te(Xt,2),Ct=vt[0],Qt=vt[1];mt(function(Q){(!Q||fe)&&Qt(!0)},[fe]);var Mr=d.useState(null),Jt=te(Mr,2),pt=Jt[0],mn=Jt[1],Lt=d.useState(null),en=te(Lt,2),Et=en[0],pn=en[1],$t=function(se){pn([se.clientX,se.clientY])},Gn=Ux(fe,pe,K&&Et!==null?Et:_e,A,M,I,O),qe=te(Gn,11),Yn=qe[0],Nr=qe[1],Ft=qe[2],zt=qe[3],jn=qe[4],Zn=qe[5],qn=qe[6],tn=qe[7],Ln=qe[8],kt=qe[9],_t=qe[10],Xn=Vx(be,c,l,f),Qn=te(Xn,2),gt=Qn[0],bt=Qn[1],hn=gt.has("click"),gn=bt.has("click")||bt.has("contextMenu"),St=xt(function(){Ct||_t()}),Pr=function(){ee.current&&K&&gn&&De(!1)};Gx(fe,_e,pe,St,Pr),mt(function(){St()},[Et,A]),mt(function(){fe&&!(M!=null&&M[A])&&St()},[JSON.stringify(I)]);var Pe=d.useMemo(function(){var Q=Kx(M,i,kt,K);return at(Q,j==null?void 0:j(kt))},[kt,j,M,i,K]);d.useImperativeHandle(r,function(){return{nativeElement:Re.current,popupElement:tt.current,forceAlign:St}});var we=d.useState(0),Ee=te(we,2),ot=Ee[0],it=Ee[1],bn=d.useState(0),yn=te(bn,2),kr=yn[0],Jn=yn[1],$n=function(){if(P&&_e){var se=_e.getBoundingClientRect();it(se.width),Jn(se.height)}},nn=function(){$n(),St()},Fn=function(se){Qt(!1),_t(),g==null||g(se)},zn=function(){return new Promise(function(se){$n(),mn(function(){return se})})};mt(function(){pt&&(_t(),pt(),mn(null))},[pt]);function Bt(Q,se,je,Xe){Ye[Q]=function(ze){var mo;Xe==null||Xe(ze),De(se,je);for(var Fi=arguments.length,Ds=new Array(Fi>1?Fi-1:0),po=1;po<Fi;po++)Ds[po-1]=arguments[po];(mo=nt[Q])===null||mo===void 0||mo.call.apply(mo,[nt,ze].concat(Ds))}}(hn||gn)&&(Ye.onClick=function(Q){var se;ee.current&&gn?De(!1):!ee.current&&hn&&($t(Q),De(!0));for(var je=arguments.length,Xe=new Array(je>1?je-1:0),ze=1;ze<je;ze++)Xe[ze-1]=arguments[ze];(se=nt.onClick)===null||se===void 0||se.call.apply(se,[nt,Q].concat(Xe))});var Oi=Yx(fe,gn,_e,pe,C,R,rt,De),Rt=gt.has("hover"),fo=bt.has("hover"),er,xn;Rt&&(Bt("onMouseEnter",!0,b,function(Q){$t(Q)}),Bt("onPointerEnter",!0,b,function(Q){$t(Q)}),er=function(se){(fe||Ct)&&pe!==null&&pe!==void 0&&pe.contains(se.target)&&De(!0,b)},K&&(Ye.onMouseMove=function(Q){var se;(se=nt.onMouseMove)===null||se===void 0||se.call(nt,Q)})),fo&&(Bt("onMouseLeave",!1,x),Bt("onPointerLeave",!1,x),xn=function(){De(!1,x)}),gt.has("focus")&&Bt("onFocus",!0,E),bt.has("focus")&&Bt("onBlur",!1,w),gt.has("contextMenu")&&(Ye.onContextMenu=function(Q){var se;ee.current&&bt.has("contextMenu")?De(!1):($t(Q),De(!0)),Q.preventDefault();for(var je=arguments.length,Xe=new Array(je>1?je-1:0),ze=1;ze<je;ze++)Xe[ze-1]=arguments[ze];(se=nt.onContextMenu)===null||se===void 0||se.call.apply(se,[nt,Q].concat(Xe))}),ue&&(Ye.className=at(nt.className,ue));var wn=Z(Z({},nt),Ye),_r={},vo=["onContextMenu","onClick","onMouseDown","onTouchStart","onMouseEnter","onMouseLeave","onFocus","onBlur"];vo.forEach(function(Q){xe[Q]&&(_r[Q]=function(){for(var se,je=arguments.length,Xe=new Array(je),ze=0;ze<je;ze++)Xe[ze]=arguments[ze];(se=wn[Q])===null||se===void 0||se.call.apply(se,[wn].concat(Xe)),xe[Q].apply(xe,Xe)})});var ji=d.cloneElement(Ie,Z(Z({},wn),_r)),Li={x:Zn,y:qn},$i=V?Z({},V!==!0?V:{}):null;return d.createElement(d.Fragment,null,d.createElement(so,{disabled:!fe,ref:Be,onResize:nn},d.createElement(Hx,{getTriggerDOMNode:he},ji)),d.createElement(Lu.Provider,{value:ce},d.createElement(Bx,{portal:e,ref:Oe,prefixCls:i,popup:T,className:at(F,Pe),style:z,target:_e,onMouseEnter:er,onMouseLeave:xn,onPointerEnter:er,zIndex:N,open:fe,keepDom:Ct,fresh:B,onClick:$,onPointerDownCapture:Oi,mask:C,motion:Pt,maskMotion:ft,onVisibleChanged:Fn,onPrepare:zn,forceRender:D,autoDestroy:ge,getPopupContainer:L,align:kt,arrow:$i,arrowPos:Li,ready:Yn,offsetX:Nr,offsetY:Ft,offsetR:zt,offsetB:jn,onAlign:St,stretch:P,targetWidth:ot/tn,targetHeight:kr/Ln})))});return t}const Xx=qx(Of);var st={adjustX:1,adjustY:1},Qx={topLeft:{points:["bl","tl"],overflow:st},topRight:{points:["br","tr"],overflow:st},bottomLeft:{points:["tl","bl"],overflow:st},bottomRight:{points:["tr","br"],overflow:st},leftTop:{points:["tr","tl"],overflow:st},leftBottom:{points:["br","bl"],overflow:st},rightTop:{points:["tl","tr"],overflow:st},rightBottom:{points:["bl","br"],overflow:st}},Jx={topLeft:{points:["bl","tl"],overflow:st},topRight:{points:["br","tr"],overflow:st},bottomLeft:{points:["tl","bl"],overflow:st},bottomRight:{points:["tr","br"],overflow:st},rightTop:{points:["tr","tl"],overflow:st},rightBottom:{points:["br","bl"],overflow:st},leftTop:{points:["tl","tr"],overflow:st},leftBottom:{points:["bl","br"],overflow:st}};function Uf(e,t,n){if(t)return t;if(n)return n[e]||n.other}var ew={horizontal:"bottomLeft",vertical:"rightTop","vertical-left":"rightTop","vertical-right":"leftTop"};function tw(e){var t=e.prefixCls,n=e.visible,r=e.children,o=e.popup,i=e.popupStyle,a=e.popupClassName,s=e.popupOffset,c=e.disabled,l=e.mode,f=e.onVisibleChange,u=d.useContext(Tt),m=u.getPopupContainer,p=u.rtl,g=u.subMenuOpenDelay,b=u.subMenuCloseDelay,h=u.builtinPlacements,x=u.triggerSubMenuAction,E=u.forceSubMenuRender,w=u.rootClassName,C=u.motion,S=u.defaultMotions,R=d.useState(!1),L=te(R,2),D=L[0],H=L[1],k=Z(p?Z({},Jx):Z({},Qx),h),T=ew[l],F=Uf(l,C,S),z=d.useRef(F);l!=="inline"&&(z.current=F);var A=Z(Z({},z.current),{},{leavedClassName:"".concat(t,"-hidden"),removeOnLeave:!1,motionAppear:!0}),_=d.useRef();return d.useEffect(function(){return _.current=an(function(){H(n)}),function(){an.cancel(_.current)}},[n]),d.createElement(Xx,{prefixCls:t,popupClassName:at("".concat(t,"-popup"),me({},"".concat(t,"-rtl"),p),a,w),stretch:l==="horizontal"?"minWidth":null,getPopupContainer:m,builtinPlacements:k,popupPlacement:T,popupVisible:D,popup:o,popupStyle:i,popupAlign:s&&{offset:s},action:c?[]:[x],mouseEnterDelay:g,mouseLeaveDelay:b,onPopupVisibleChange:f,forceRender:E,popupMotion:A,fresh:!0},r)}function nw(e){var t=e.id,n=e.open,r=e.keyPath,o=e.children,i="inline",a=d.useContext(Tt),s=a.prefixCls,c=a.forceSubMenuRender,l=a.motion,f=a.defaultMotions,u=a.mode,m=d.useRef(!1);m.current=u===i;var p=d.useState(!m.current),g=te(p,2),b=g[0],h=g[1],x=m.current?n:!1;d.useEffect(function(){m.current&&h(!1)},[u]);var E=Z({},Uf(i,l,f));r.length>1&&(E.motionAppear=!1);var w=E.onVisibleChanged;return E.onVisibleChanged=function(C){return!m.current&&!C&&h(!0),w==null?void 0:w(C)},b?null:d.createElement(qr,{mode:i,locked:!m.current},d.createElement(Ai,Me({visible:x},E,{forceRender:c,removeOnLeave:!1,leavedClassName:"".concat(s,"-hidden")}),function(C){var S=C.className,R=C.style;return d.createElement(Ms,{id:t,className:S,style:R},o)}))}var rw=["style","className","title","eventKey","warnKey","disabled","internalPopupClose","children","itemIcon","expandIcon","popupClassName","popupOffset","popupStyle","onClick","onMouseEnter","onMouseLeave","onTitleClick","onTitleMouseEnter","onTitleMouseLeave"],ow=["active"],iw=d.forwardRef(function(e,t){var n=e.style,r=e.className,o=e.title,i=e.eventKey;e.warnKey;var a=e.disabled,s=e.internalPopupClose,c=e.children,l=e.itemIcon,f=e.expandIcon,u=e.popupClassName,m=e.popupOffset,p=e.popupStyle,g=e.onClick,b=e.onMouseEnter,h=e.onMouseLeave,x=e.onTitleClick,E=e.onTitleMouseEnter,w=e.onTitleMouseLeave,C=Qe(e,rw),S=wf(i),R=d.useContext(Tt),L=R.prefixCls,D=R.mode,H=R.openKeys,k=R.disabled,T=R.overflowDisabled,F=R.activeKey,z=R.selectedKeys,A=R.itemIcon,_=R.expandIcon,M=R.onItemClick,I=R.onOpenChange,N=R.onActive,P=d.useContext(Cs),j=P._internalRenderSubMenuItem,B=d.useContext(Sf),K=B.isSubPathKey,$=uo(),O="".concat(L,"-submenu"),V=k||a,U=d.useRef(),oe=d.useRef(),G=l!=null?l:A,q=f!=null?f:_,ne=H.includes(i),ae=!T&&ne,ue=K(z,i),he=Nf(i,V,E,w),xe=he.active,ge=Qe(he,ow),Ne=d.useState(!1),ke=te(Ne,2),be=ke[0],ye=ke[1],Le=function(Ie){V||ye(Ie)},le=function(Ie){Le(!0),b==null||b({key:i,domEvent:Ie})},ce=function(Ie){Le(!1),h==null||h({key:i,domEvent:Ie})},re=d.useMemo(function(){return xe||(D!=="inline"?be||K([F],i):!1)},[D,xe,F,be,i,K]),Je=Pf($.length),Fe=function(Ie){V||(x==null||x({key:i,domEvent:Ie}),D==="inline"&&I(i,!ne))},pe=Fr(function(Be){g==null||g(ni(Be)),M(Be)}),et=function(Ie){D!=="inline"&&I(i,Ie)},tt=function(){N(i)},Oe=S&&"".concat(S,"-popup"),He=d.useMemo(function(){return d.createElement(kf,{icon:D!=="horizontal"?q:void 0,props:Z(Z({},e),{},{isOpen:ae,isSubMenu:!0})},d.createElement("i",{className:"".concat(O,"-arrow")}))},[D,q,e,ae,O]),Ve=d.createElement("div",Me({role:"menuitem",style:Je,className:"".concat(O,"-title"),tabIndex:V?null:-1,ref:U,title:typeof o=="string"?o:null,"data-menu-id":T&&S?null:S,"aria-expanded":ae,"aria-haspopup":!0,"aria-controls":Oe,"aria-disabled":V,onClick:Fe,onFocus:tt},ge),o,He),_e=d.useRef(D);if(D!=="inline"&&$.length>1?_e.current="vertical":_e.current=D,!T){var Ae=_e.current;Ve=d.createElement(tw,{mode:Ae,prefixCls:O,visible:!s&&ae&&D!=="inline",popupClassName:u,popupOffset:m,popupStyle:p,popup:d.createElement(qr,{mode:Ae==="horizontal"?"vertical":Ae},d.createElement(Ms,{id:Oe,ref:oe},c)),disabled:V,onVisibleChange:et},Ve)}var Re=d.createElement(sn.Item,Me({ref:t,role:"none"},C,{component:"li",style:n,className:at(O,"".concat(O,"-").concat(D),r,me(me(me(me({},"".concat(O,"-open"),ae),"".concat(O,"-active"),re),"".concat(O,"-selected"),ue),"".concat(O,"-disabled"),V)),onMouseEnter:le,onMouseLeave:ce}),Ve,!T&&d.createElement(nw,{id:Oe,open:ae,keyPath:$},c));return j&&(Re=j(Re,e,{selected:ue,active:re,open:ae,disabled:V})),d.createElement(qr,{onItemClick:pe,mode:D==="horizontal"?"vertical":D,itemIcon:G,expandIcon:q},Re)}),Ti=d.forwardRef(function(e,t){var n=e.eventKey,r=e.children,o=uo(n),i=Ns(r,o),a=_i();d.useEffect(function(){if(a)return a.registerPath(n,o),function(){a.unregisterPath(n,o)}},[o]);var s;return a?s=i:s=d.createElement(iw,Me({ref:t},e),i),d.createElement(Ef.Provider,{value:o},s)});function Gf(e){var t=e.className,n=e.style,r=d.useContext(Tt),o=r.prefixCls,i=_i();return i?null:d.createElement("li",{role:"separator",className:at("".concat(o,"-item-divider"),t),style:n})}var aw=["className","title","eventKey","children"],sw=d.forwardRef(function(e,t){var n=e.className,r=e.title;e.eventKey;var o=e.children,i=Qe(e,aw),a=d.useContext(Tt),s=a.prefixCls,c="".concat(s,"-item-group");return d.createElement("li",Me({ref:t,role:"presentation"},i,{onClick:function(f){return f.stopPropagation()},className:at(c,n)}),d.createElement("div",{role:"presentation",className:"".concat(c,"-title"),title:typeof r=="string"?r:void 0},r),d.createElement("ul",{role:"group",className:"".concat(c,"-list")},o))}),_s=d.forwardRef(function(e,t){var n=e.eventKey,r=e.children,o=uo(n),i=Ns(r,o),a=_i();return a?i:d.createElement(sw,Me({ref:t},Rs(e,["warnKey"])),i)}),uw=["label","children","key","type","extra"];function Ta(e,t,n){var r=t.item,o=t.group,i=t.submenu,a=t.divider;return(e||[]).map(function(s,c){if(s&&lt(s)==="object"){var l=s,f=l.label,u=l.children,m=l.key,p=l.type,g=l.extra,b=Qe(l,uw),h=m!=null?m:"tmp-".concat(c);return u||p==="group"?p==="group"?d.createElement(o,Me({key:h},b,{title:f}),Ta(u,t,n)):d.createElement(i,Me({key:h},b,{title:f}),Ta(u,t,n)):p==="divider"?d.createElement(a,Me({key:h},b)):d.createElement(r,Me({key:h},b,{extra:g}),f,(!!g||g===0)&&d.createElement("span",{className:"".concat(n,"-item-extra")},g))}return null}).filter(function(s){return s})}function Wu(e,t,n,r,o){var i=e,a=Z({divider:Gf,item:Ii,group:_s,submenu:Ti},r);return t&&(i=Ta(t,a,o)),Ns(i,n)}var lw=["prefixCls","rootClassName","style","className","tabIndex","items","children","direction","id","mode","inlineCollapsed","disabled","disabledOverflow","subMenuOpenDelay","subMenuCloseDelay","forceSubMenuRender","defaultOpenKeys","openKeys","activeKey","defaultActiveFirst","selectable","multiple","defaultSelectedKeys","selectedKeys","onSelect","onDeselect","inlineIndent","motion","defaultMotions","triggerSubMenuAction","builtinPlacements","itemIcon","expandIcon","overflowedIndicator","overflowedIndicatorPopupClassName","getPopupContainer","onClick","onOpenChange","onKeyDown","openAnimation","openTransitionName","_internalRenderMenuItem","_internalRenderSubMenuItem","_internalComponents"],Bn=[],cw=d.forwardRef(function(e,t){var n,r=e,o=r.prefixCls,i=o===void 0?"rc-menu":o,a=r.rootClassName,s=r.style,c=r.className,l=r.tabIndex,f=l===void 0?0:l,u=r.items,m=r.children,p=r.direction,g=r.id,b=r.mode,h=b===void 0?"vertical":b,x=r.inlineCollapsed,E=r.disabled,w=r.disabledOverflow,C=r.subMenuOpenDelay,S=C===void 0?.1:C,R=r.subMenuCloseDelay,L=R===void 0?.1:R,D=r.forceSubMenuRender,H=r.defaultOpenKeys,k=r.openKeys,T=r.activeKey,F=r.defaultActiveFirst,z=r.selectable,A=z===void 0?!0:z,_=r.multiple,M=_===void 0?!1:_,I=r.defaultSelectedKeys,N=r.selectedKeys,P=r.onSelect,j=r.onDeselect,B=r.inlineIndent,K=B===void 0?24:B,$=r.motion,O=r.defaultMotions,V=r.triggerSubMenuAction,U=V===void 0?"hover":V,oe=r.builtinPlacements,G=r.itemIcon,q=r.expandIcon,ne=r.overflowedIndicator,ae=ne===void 0?"...":ne,ue=r.overflowedIndicatorPopupClassName,he=r.getPopupContainer,xe=r.onClick,ge=r.onOpenChange,Ne=r.onKeyDown;r.openAnimation,r.openTransitionName;var ke=r._internalRenderMenuItem,be=r._internalRenderSubMenuItem,ye=r._internalComponents,Le=Qe(r,lw),le=d.useMemo(function(){return[Wu(m,u,Bn,ye,i),Wu(m,u,Bn,{},i)]},[m,u,ye]),ce=te(le,2),re=ce[0],Je=ce[1],Fe=d.useState(!1),pe=te(Fe,2),et=pe[0],tt=pe[1],Oe=d.useRef(),He=Uy(g),Ve=p==="rtl",_e=To(H,{value:k,postState:function(we){return we||Bn}}),Ae=te(_e,2),Re=Ae[0],Be=Ae[1],Ie=function(we){var Ee=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;function ot(){Be(we),ge==null||ge(we)}Ee?ut.flushSync(ot):ot()},nt=d.useState(Re),Ye=te(nt,2),rt=Ye[0],Pt=Ye[1],ft=d.useRef(!1),jt=d.useMemo(function(){return(h==="inline"||h==="vertical")&&x?["vertical",x]:[h,!1]},[h,x]),Ze=te(jt,2),X=Ze[0],Ce=Ze[1],fe=X==="inline",J=d.useState(X),ee=te(J,2),Y=ee[0],ve=ee[1],We=d.useState(Ce),Ke=te(We,2),De=Ke[0],Xt=Ke[1];d.useEffect(function(){ve(X),Xt(Ce),ft.current&&(fe?Be(rt):Ie(Bn))},[X,Ce]);var vt=d.useState(0),Ct=te(vt,2),Qt=Ct[0],Mr=Ct[1],Jt=Qt>=re.length-1||Y!=="horizontal"||w;d.useEffect(function(){fe&&Pt(Re)},[Re]),d.useEffect(function(){return ft.current=!0,function(){ft.current=!1}},[]);var pt=Wy(),mn=pt.registerPath,Lt=pt.unregisterPath,en=pt.refreshOverflowKeys,Et=pt.isSubPathKey,pn=pt.getKeyPath,$t=pt.getKeys,Gn=pt.getSubPathKeys,qe=d.useMemo(function(){return{registerPath:mn,unregisterPath:Lt}},[mn,Lt]),Yn=d.useMemo(function(){return{isSubPathKey:Et}},[Et]);d.useEffect(function(){en(Jt?Bn:re.slice(Qt+1).map(function(Pe){return Pe.key}))},[Qt,Jt]);var Nr=To(T||F&&((n=re[0])===null||n===void 0?void 0:n.key),{value:T}),Ft=te(Nr,2),zt=Ft[0],jn=Ft[1],Zn=Fr(function(Pe){jn(Pe)}),qn=Fr(function(){jn(void 0)});y.useImperativeHandle(t,function(){return{list:Oe.current,focus:function(we){var Ee,ot=$t(),it=Sa(ot,He),bn=it.elements,yn=it.key2element,kr=it.element2key,Jn=Es(Oe.current,bn),$n=zt!=null?zt:Jn[0]?kr.get(Jn[0]):(Ee=re.find(function(zn){return!zn.props.disabled}))===null||Ee===void 0?void 0:Ee.key,nn=yn.get($n);if($n&&nn){var Fn;nn==null||(Fn=nn.focus)===null||Fn===void 0||Fn.call(nn,we)}}}});var tn=To(I||[],{value:N,postState:function(we){return Array.isArray(we)?we:we==null?Bn:[we]}}),Ln=te(tn,2),kt=Ln[0],_t=Ln[1],Xn=function(we){if(A){var Ee=we.key,ot=kt.includes(Ee),it;M?ot?it=kt.filter(function(yn){return yn!==Ee}):it=[].concat(Yt(kt),[Ee]):it=[Ee],_t(it);var bn=Z(Z({},we),{},{selectedKeys:it});ot?j==null||j(bn):P==null||P(bn)}!M&&Re.length&&Y!=="inline"&&Ie(Bn)},Qn=Fr(function(Pe){xe==null||xe(ni(Pe)),Xn(Pe)}),gt=Fr(function(Pe,we){var Ee=Re.filter(function(it){return it!==Pe});if(we)Ee.push(Pe);else if(Y!=="inline"){var ot=Gn(Pe);Ee=Ee.filter(function(it){return!ot.has(it)})}bf(Re,Ee,!0)||Ie(Ee,!0)}),bt=function(we,Ee){var ot=Ee!=null?Ee:!Re.includes(we);gt(we,ot)},hn=By(Y,zt,Ve,He,Oe,$t,pn,jn,bt,Ne);d.useEffect(function(){tt(!0)},[]);var gn=d.useMemo(function(){return{_internalRenderMenuItem:ke,_internalRenderSubMenuItem:be}},[ke,be]),St=Y!=="horizontal"||w?re:re.map(function(Pe,we){return d.createElement(qr,{key:Pe.key,overflowDisabled:we>Qt},Pe)}),Pr=d.createElement(sn,Me({id:g,ref:Oe,prefixCls:"".concat(i,"-overflow"),component:"ul",itemComponent:Ii,className:at(i,"".concat(i,"-root"),"".concat(i,"-").concat(Y),c,me(me({},"".concat(i,"-inline-collapsed"),De),"".concat(i,"-rtl"),Ve),a),dir:p,style:s,role:"menu",tabIndex:f,data:St,renderRawItem:function(we){return we},renderRawRest:function(we){var Ee=we.length,ot=Ee?re.slice(-Ee):null;return d.createElement(Ti,{eventKey:Ra,title:ae,disabled:Jt,internalPopupClose:Ee===0,popupClassName:ue},ot)},maxCount:Y!=="horizontal"||w?sn.INVALIDATE:sn.RESPONSIVE,ssr:"full","data-menu-list":!0,onVisibleChange:function(we){Mr(we)},onKeyDown:hn},Le));return d.createElement(Cs.Provider,{value:gn},d.createElement(yf.Provider,{value:He},d.createElement(qr,{prefixCls:i,rootClassName:a,mode:Y,openKeys:Re,rtl:Ve,disabled:E,motion:et?$:null,defaultMotions:et?O:null,activeKey:zt,onActive:Zn,onInactive:qn,selectedKeys:kt,inlineIndent:K,subMenuOpenDelay:S,subMenuCloseDelay:L,forceSubMenuRender:D,builtinPlacements:oe,triggerSubMenuAction:U,getPopupContainer:he,itemIcon:G,expandIcon:q,onItemClick:Qn,onOpenChange:gt},d.createElement(Sf.Provider,{value:Yn},Pr),d.createElement("div",{style:{display:"none"},"aria-hidden":!0},d.createElement(Cf.Provider,{value:qe},Je)))))}),co=cw;co.Item=Ii;co.SubMenu=Ti;co.ItemGroup=_s;co.Divider=Gf;const dw=y.forwardRef((e,t)=>{const{mountContainer:n}=y.useContext(Zt),{wrapperClass:r,...o}=e;return n&&v.jsx(co,{ref:t,prefixCls:W("univer-menu",e.className),getPopupContainer:()=>n,...o,className:r})});function fw(e){return v.jsx(Ii,{...e})}function vw(e){return v.jsx(Ti,{...e})}function mw(e){return v.jsx(_s,{...e})}function pw({items:e}){return v.jsx("div",{className:"univer-menu-item-group univer-flex univer-flex-wrap univer-gap-2.5 univer-p-1 univer-px-0",children:e.map(t=>{const n=v.jsx("div",{className:W("univer-flex univer-size-6 univer-cursor-pointer univer-items-center univer-justify-center univer-rounded-md hover:univer-bg-gray-50 dark:hover:!univer-bg-gray-900",{"univer-bg-gray-50 dark:!univer-bg-gray-900":t.active},t.className),onClick:()=>t.onClick(),children:v.jsx(t.Icon,{className:"univer-size-4 univer-text-gray-900 dark:!univer-text-gray-200"})},t.key);return t.tooltip?v.jsx(yi,{title:t.tooltip,children:n},t.key):n})})}function hw(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",t.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}const gw=e=>{switch(e){case"success":return xw;case"info":return Cw;case"warning":return ww;case"error":return Ew;default:return null}},bw=Array(12).fill(0),yw=({visible:e,className:t})=>y.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},y.createElement("div",{className:"sonner-spinner"},bw.map((n,r)=>y.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),xw=y.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},y.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),ww=y.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},y.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),Cw=y.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},y.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),Ew=y.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},y.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),Sw=y.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},y.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),y.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),Rw=()=>{const[e,t]=y.useState(document.hidden);return y.useEffect(()=>{const n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e};let Oa=1;class Mw{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{const n=this.subscribers.indexOf(t);this.subscribers.splice(n,1)}),this.publish=t=>{this.subscribers.forEach(n=>n(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var n;const{message:r,...o}=t,i=typeof(t==null?void 0:t.id)=="number"||((n=t.id)==null?void 0:n.length)>0?t.id:Oa++,a=this.toasts.find(c=>c.id===i),s=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(i)&&this.dismissedToasts.delete(i),a?this.toasts=this.toasts.map(c=>c.id===i?(this.publish({...c,...t,id:i,title:r}),{...c,...t,id:i,dismissible:s,title:r}):c):this.addToast({title:r,...o,dismissible:s,id:i}),i},this.dismiss=t=>(t?(this.dismissedToasts.add(t),requestAnimationFrame(()=>this.subscribers.forEach(n=>n({id:t,dismiss:!0})))):this.toasts.forEach(n=>{this.subscribers.forEach(r=>r({id:n.id,dismiss:!0}))}),t),this.message=(t,n)=>this.create({...n,message:t}),this.error=(t,n)=>this.create({...n,message:t,type:"error"}),this.success=(t,n)=>this.create({...n,type:"success",message:t}),this.info=(t,n)=>this.create({...n,type:"info",message:t}),this.warning=(t,n)=>this.create({...n,type:"warning",message:t}),this.loading=(t,n)=>this.create({...n,type:"loading",message:t}),this.promise=(t,n)=>{if(!n)return;let r;n.loading!==void 0&&(r=this.create({...n,promise:t,type:"loading",message:n.loading,description:typeof n.description!="function"?n.description:void 0}));const o=Promise.resolve(t instanceof Function?t():t);let i=r!==void 0,a;const s=o.then(async l=>{if(a=["resolve",l],y.isValidElement(l))i=!1,this.create({id:r,type:"default",message:l});else if(Pw(l)&&!l.ok){i=!1;const u=typeof n.error=="function"?await n.error(`HTTP error! status: ${l.status}`):n.error,m=typeof n.description=="function"?await n.description(`HTTP error! status: ${l.status}`):n.description,g=typeof u=="object"&&!y.isValidElement(u)?u:{message:u};this.create({id:r,type:"error",description:m,...g})}else if(l instanceof Error){i=!1;const u=typeof n.error=="function"?await n.error(l):n.error,m=typeof n.description=="function"?await n.description(l):n.description,g=typeof u=="object"&&!y.isValidElement(u)?u:{message:u};this.create({id:r,type:"error",description:m,...g})}else if(n.success!==void 0){i=!1;const u=typeof n.success=="function"?await n.success(l):n.success,m=typeof n.description=="function"?await n.description(l):n.description,g=typeof u=="object"&&!y.isValidElement(u)?u:{message:u};this.create({id:r,type:"success",description:m,...g})}}).catch(async l=>{if(a=["reject",l],n.error!==void 0){i=!1;const f=typeof n.error=="function"?await n.error(l):n.error,u=typeof n.description=="function"?await n.description(l):n.description,p=typeof f=="object"&&!y.isValidElement(f)?f:{message:f};this.create({id:r,type:"error",description:u,...p})}}).finally(()=>{i&&(this.dismiss(r),r=void 0),n.finally==null||n.finally.call(n)}),c=()=>new Promise((l,f)=>s.then(()=>a[0]==="reject"?f(a[1]):l(a[1])).catch(f));return typeof r!="string"&&typeof r!="number"?{unwrap:c}:Object.assign(r,{unwrap:c})},this.custom=(t,n)=>{const r=(n==null?void 0:n.id)||Oa++;return this.create({jsx:t(r),id:r,...n}),r},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const ht=new Mw,Nw=(e,t)=>{const n=(t==null?void 0:t.id)||Oa++;return ht.addToast({title:e,...t,id:n}),n},Pw=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",kw=Nw,_w=()=>ht.toasts,Iw=()=>ht.getActiveToasts(),Nn=Object.assign(kw,{success:ht.success,info:ht.info,warning:ht.warning,error:ht.error,custom:ht.custom,message:ht.message,promise:ht.promise,dismiss:ht.dismiss,loading:ht.loading},{getHistory:_w,getToasts:Iw});hw("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");function Mo(e){return e.label!==void 0}const Dw=3,Aw="24px",Tw="16px",Ku=4e3,Ow=356,jw=14,Lw=45,$w=200;function Ht(...e){return e.filter(Boolean).join(" ")}function Fw(e){const[t,n]=e.split("-"),r=[];return t&&r.push(t),n&&r.push(n),r}const zw=e=>{var t,n,r,o,i,a,s,c,l;const{invert:f,toast:u,unstyled:m,interacting:p,setHeights:g,visibleToasts:b,heights:h,index:x,toasts:E,expanded:w,removeToast:C,defaultRichColors:S,closeButton:R,style:L,cancelButtonStyle:D,actionButtonStyle:H,className:k="",descriptionClassName:T="",duration:F,position:z,gap:A,expandByDefault:_,classNames:M,icons:I,closeButtonAriaLabel:N="Close toast"}=e,[P,j]=y.useState(null),[B,K]=y.useState(null),[$,O]=y.useState(!1),[V,U]=y.useState(!1),[oe,G]=y.useState(!1),[q,ne]=y.useState(!1),[ae,ue]=y.useState(!1),[he,xe]=y.useState(0),[ge,Ne]=y.useState(0),ke=y.useRef(u.duration||F||Ku),be=y.useRef(null),ye=y.useRef(null),Le=x===0,le=x+1<=b,ce=u.type,re=u.dismissible!==!1,Je=u.className||"",Fe=u.descriptionClassName||"",pe=y.useMemo(()=>h.findIndex(X=>X.toastId===u.id)||0,[h,u.id]),et=y.useMemo(()=>{var X;return(X=u.closeButton)!=null?X:R},[u.closeButton,R]),tt=y.useMemo(()=>u.duration||F||Ku,[u.duration,F]),Oe=y.useRef(0),He=y.useRef(0),Ve=y.useRef(0),_e=y.useRef(null),[Ae,Re]=z.split("-"),Be=y.useMemo(()=>h.reduce((X,Ce,fe)=>fe>=pe?X:X+Ce.height,0),[h,pe]),Ie=Rw(),nt=u.invert||f,Ye=ce==="loading";He.current=y.useMemo(()=>pe*A+Be,[pe,Be]),y.useEffect(()=>{ke.current=tt},[tt]),y.useEffect(()=>{O(!0)},[]),y.useEffect(()=>{const X=ye.current;if(X){const Ce=X.getBoundingClientRect().height;return Ne(Ce),g(fe=>[{toastId:u.id,height:Ce,position:u.position},...fe]),()=>g(fe=>fe.filter(J=>J.toastId!==u.id))}},[g,u.id]),y.useLayoutEffect(()=>{if(!$)return;const X=ye.current,Ce=X.style.height;X.style.height="auto";const fe=X.getBoundingClientRect().height;X.style.height=Ce,Ne(fe),g(J=>J.find(Y=>Y.toastId===u.id)?J.map(Y=>Y.toastId===u.id?{...Y,height:fe}:Y):[{toastId:u.id,height:fe,position:u.position},...J])},[$,u.title,u.description,g,u.id,u.jsx,u.action,u.cancel]);const rt=y.useCallback(()=>{U(!0),xe(He.current),g(X=>X.filter(Ce=>Ce.toastId!==u.id)),setTimeout(()=>{C(u)},$w)},[u,C,g,He]);y.useEffect(()=>{if(u.promise&&ce==="loading"||u.duration===1/0||u.type==="loading")return;let X;return w||p||Ie?(()=>{if(Ve.current<Oe.current){const J=new Date().getTime()-Oe.current;ke.current=ke.current-J}Ve.current=new Date().getTime()})():ke.current!==1/0&&(Oe.current=new Date().getTime(),X=setTimeout(()=>{u.onAutoClose==null||u.onAutoClose.call(u,u),rt()},ke.current)),()=>clearTimeout(X)},[w,p,u,ce,Ie,rt]),y.useEffect(()=>{u.delete&&(rt(),u.onDismiss==null||u.onDismiss.call(u,u))},[rt,u.delete]);function Pt(){var X;if(I!=null&&I.loading){var Ce;return y.createElement("div",{className:Ht(M==null?void 0:M.loader,u==null||(Ce=u.classNames)==null?void 0:Ce.loader,"sonner-loader"),"data-visible":ce==="loading"},I.loading)}return y.createElement(yw,{className:Ht(M==null?void 0:M.loader,u==null||(X=u.classNames)==null?void 0:X.loader),visible:ce==="loading"})}const ft=u.icon||(I==null?void 0:I[ce])||gw(ce);var jt,Ze;return y.createElement("li",{tabIndex:0,ref:ye,className:Ht(k,Je,M==null?void 0:M.toast,u==null||(t=u.classNames)==null?void 0:t.toast,M==null?void 0:M.default,M==null?void 0:M[ce],u==null||(n=u.classNames)==null?void 0:n[ce]),"data-sonner-toast":"","data-rich-colors":(jt=u.richColors)!=null?jt:S,"data-styled":!(u.jsx||u.unstyled||m),"data-mounted":$,"data-promise":!!u.promise,"data-swiped":ae,"data-removed":V,"data-visible":le,"data-y-position":Ae,"data-x-position":Re,"data-index":x,"data-front":Le,"data-swiping":oe,"data-dismissible":re,"data-type":ce,"data-invert":nt,"data-swipe-out":q,"data-swipe-direction":B,"data-expanded":!!(w||_&&$),"data-testid":u.testId,style:{"--index":x,"--toasts-before":x,"--z-index":E.length-x,"--offset":`${V?he:He.current}px`,"--initial-height":_?"auto":`${ge}px`,...L,...u.style},onDragEnd:()=>{G(!1),j(null),_e.current=null},onPointerDown:X=>{X.button!==2&&(Ye||!re||(be.current=new Date,xe(He.current),X.target.setPointerCapture(X.pointerId),X.target.tagName!=="BUTTON"&&(G(!0),_e.current={x:X.clientX,y:X.clientY})))},onPointerUp:()=>{var X,Ce,fe;if(q||!re)return;_e.current=null;const J=Number(((X=ye.current)==null?void 0:X.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),ee=Number(((Ce=ye.current)==null?void 0:Ce.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),Y=new Date().getTime()-((fe=be.current)==null?void 0:fe.getTime()),ve=P==="x"?J:ee,We=Math.abs(ve)/Y;if(Math.abs(ve)>=Lw||We>.11){xe(He.current),u.onDismiss==null||u.onDismiss.call(u,u),K(P==="x"?J>0?"right":"left":ee>0?"down":"up"),rt(),ne(!0);return}else{var Ke,De;(Ke=ye.current)==null||Ke.style.setProperty("--swipe-amount-x","0px"),(De=ye.current)==null||De.style.setProperty("--swipe-amount-y","0px")}ue(!1),G(!1),j(null)},onPointerMove:X=>{var Ce,fe,J;if(!_e.current||!re||((Ce=window.getSelection())==null?void 0:Ce.toString().length)>0)return;const Y=X.clientY-_e.current.y,ve=X.clientX-_e.current.x;var We;const Ke=(We=e.swipeDirections)!=null?We:Fw(z);!P&&(Math.abs(ve)>1||Math.abs(Y)>1)&&j(Math.abs(ve)>Math.abs(Y)?"x":"y");let De={x:0,y:0};const Xt=vt=>1/(1.5+Math.abs(vt)/20);if(P==="y"){if(Ke.includes("top")||Ke.includes("bottom"))if(Ke.includes("top")&&Y<0||Ke.includes("bottom")&&Y>0)De.y=Y;else{const vt=Y*Xt(Y);De.y=Math.abs(vt)<Math.abs(Y)?vt:Y}}else if(P==="x"&&(Ke.includes("left")||Ke.includes("right")))if(Ke.includes("left")&&ve<0||Ke.includes("right")&&ve>0)De.x=ve;else{const vt=ve*Xt(ve);De.x=Math.abs(vt)<Math.abs(ve)?vt:ve}(Math.abs(De.x)>0||Math.abs(De.y)>0)&&ue(!0),(fe=ye.current)==null||fe.style.setProperty("--swipe-amount-x",`${De.x}px`),(J=ye.current)==null||J.style.setProperty("--swipe-amount-y",`${De.y}px`)}},et&&!u.jsx&&ce!=="loading"?y.createElement("button",{"aria-label":N,"data-disabled":Ye,"data-close-button":!0,onClick:Ye||!re?()=>{}:()=>{rt(),u.onDismiss==null||u.onDismiss.call(u,u)},className:Ht(M==null?void 0:M.closeButton,u==null||(r=u.classNames)==null?void 0:r.closeButton)},(Ze=I==null?void 0:I.close)!=null?Ze:Sw):null,(ce||u.icon||u.promise)&&u.icon!==null&&((I==null?void 0:I[ce])!==null||u.icon)?y.createElement("div",{"data-icon":"",className:Ht(M==null?void 0:M.icon,u==null||(o=u.classNames)==null?void 0:o.icon)},u.promise||u.type==="loading"&&!u.icon?u.icon||Pt():null,u.type!=="loading"?ft:null):null,y.createElement("div",{"data-content":"",className:Ht(M==null?void 0:M.content,u==null||(i=u.classNames)==null?void 0:i.content)},y.createElement("div",{"data-title":"",className:Ht(M==null?void 0:M.title,u==null||(a=u.classNames)==null?void 0:a.title)},u.jsx?u.jsx:typeof u.title=="function"?u.title():u.title),u.description?y.createElement("div",{"data-description":"",className:Ht(T,Fe,M==null?void 0:M.description,u==null||(s=u.classNames)==null?void 0:s.description)},typeof u.description=="function"?u.description():u.description):null),y.isValidElement(u.cancel)?u.cancel:u.cancel&&Mo(u.cancel)?y.createElement("button",{"data-button":!0,"data-cancel":!0,style:u.cancelButtonStyle||D,onClick:X=>{Mo(u.cancel)&&re&&(u.cancel.onClick==null||u.cancel.onClick.call(u.cancel,X),rt())},className:Ht(M==null?void 0:M.cancelButton,u==null||(c=u.classNames)==null?void 0:c.cancelButton)},u.cancel.label):null,y.isValidElement(u.action)?u.action:u.action&&Mo(u.action)?y.createElement("button",{"data-button":!0,"data-action":!0,style:u.actionButtonStyle||H,onClick:X=>{Mo(u.action)&&(u.action.onClick==null||u.action.onClick.call(u.action,X),!X.defaultPrevented&&rt())},className:Ht(M==null?void 0:M.actionButton,u==null||(l=u.classNames)==null?void 0:l.actionButton)},u.action.label):null)};function Uu(){if(typeof window>"u"||typeof document>"u")return"ltr";const e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function Bw(e,t){const n={};return[e,t].forEach((r,o)=>{const i=o===1,a=i?"--mobile-offset":"--offset",s=i?Tw:Aw;function c(l){["top","right","bottom","left"].forEach(f=>{n[`${a}-${f}`]=typeof l=="number"?`${l}px`:l})}typeof r=="number"||typeof r=="string"?c(r):typeof r=="object"?["top","right","bottom","left"].forEach(l=>{r[l]===void 0?n[`${a}-${l}`]=s:n[`${a}-${l}`]=typeof r[l]=="number"?`${r[l]}px`:r[l]}):c(s)}),n}const Yf=y.forwardRef(function(t,n){const{id:r,invert:o,position:i="bottom-right",hotkey:a=["altKey","KeyT"],expand:s,closeButton:c,className:l,offset:f,mobileOffset:u,theme:m="light",richColors:p,duration:g,style:b,visibleToasts:h=Dw,toastOptions:x,dir:E=Uu(),gap:w=jw,icons:C,containerAriaLabel:S="Notifications"}=t,[R,L]=y.useState([]),D=y.useMemo(()=>r?R.filter($=>$.toasterId===r):R.filter($=>!$.toasterId),[R,r]),H=y.useMemo(()=>Array.from(new Set([i].concat(D.filter($=>$.position).map($=>$.position)))),[D,i]),[k,T]=y.useState([]),[F,z]=y.useState(!1),[A,_]=y.useState(!1),[M,I]=y.useState(m!=="system"?m:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),N=y.useRef(null),P=a.join("+").replace(/Key/g,"").replace(/Digit/g,""),j=y.useRef(null),B=y.useRef(!1),K=y.useCallback($=>{L(O=>{var V;return(V=O.find(U=>U.id===$.id))!=null&&V.delete||ht.dismiss($.id),O.filter(({id:U})=>U!==$.id)})},[]);return y.useEffect(()=>ht.subscribe($=>{if($.dismiss){requestAnimationFrame(()=>{L(O=>O.map(V=>V.id===$.id?{...V,delete:!0}:V))});return}setTimeout(()=>{ut.flushSync(()=>{L(O=>{const V=O.findIndex(U=>U.id===$.id);return V!==-1?[...O.slice(0,V),{...O[V],...$},...O.slice(V+1)]:[$,...O]})})})}),[R]),y.useEffect(()=>{if(m!=="system"){I(m);return}if(m==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?I("dark"):I("light")),typeof window>"u")return;const $=window.matchMedia("(prefers-color-scheme: dark)");try{$.addEventListener("change",({matches:O})=>{I(O?"dark":"light")})}catch{$.addListener(({matches:V})=>{try{I(V?"dark":"light")}catch(U){console.error(U)}})}},[m]),y.useEffect(()=>{R.length<=1&&z(!1)},[R]),y.useEffect(()=>{const $=O=>{var V;if(a.every(G=>O[G]||O.code===G)){var oe;z(!0),(oe=N.current)==null||oe.focus()}O.code==="Escape"&&(document.activeElement===N.current||(V=N.current)!=null&&V.contains(document.activeElement))&&z(!1)};return document.addEventListener("keydown",$),()=>document.removeEventListener("keydown",$)},[a]),y.useEffect(()=>{if(N.current)return()=>{j.current&&(j.current.focus({preventScroll:!0}),j.current=null,B.current=!1)}},[N.current]),y.createElement("section",{ref:n,"aria-label":`${S} ${P}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},H.map(($,O)=>{var V;const[U,oe]=$.split("-");return D.length?y.createElement("ol",{key:$,dir:E==="auto"?Uu():E,tabIndex:-1,ref:N,className:l,"data-sonner-toaster":!0,"data-sonner-theme":M,"data-y-position":U,"data-x-position":oe,style:{"--front-toast-height":`${((V=k[0])==null?void 0:V.height)||0}px`,"--width":`${Ow}px`,"--gap":`${w}px`,...b,...Bw(f,u)},onBlur:G=>{B.current&&!G.currentTarget.contains(G.relatedTarget)&&(B.current=!1,j.current&&(j.current.focus({preventScroll:!0}),j.current=null))},onFocus:G=>{G.target instanceof HTMLElement&&G.target.dataset.dismissible==="false"||B.current||(B.current=!0,j.current=G.relatedTarget)},onMouseEnter:()=>z(!0),onMouseMove:()=>z(!0),onMouseLeave:()=>{A||z(!1)},onDragEnd:()=>z(!1),onPointerDown:G=>{G.target instanceof HTMLElement&&G.target.dataset.dismissible==="false"||_(!0)},onPointerUp:()=>_(!1)},D.filter(G=>!G.position&&O===0||G.position===$).map((G,q)=>{var ne,ae;return y.createElement(zw,{key:G.id,icons:C,index:q,toast:G,defaultRichColors:p,duration:(ne=x==null?void 0:x.duration)!=null?ne:g,className:x==null?void 0:x.className,descriptionClassName:x==null?void 0:x.descriptionClassName,invert:o,visibleToasts:h,closeButton:(ae=x==null?void 0:x.closeButton)!=null?ae:c,interacting:A,position:$,style:x==null?void 0:x.style,unstyled:x==null?void 0:x.unstyled,classNames:x==null?void 0:x.classNames,cancelButtonStyle:x==null?void 0:x.cancelButtonStyle,actionButtonStyle:x==null?void 0:x.actionButtonStyle,closeButtonAriaLabel:x==null?void 0:x.closeButtonAriaLabel,removeToast:K,toasts:D.filter(ue=>ue.position==G.position),heights:k.filter(ue=>ue.position==G.position),setHeights:T,expandByDefault:s,gap:w,expanded:F,swipeDirections:t.swipeDirections})})):null}))});var Zf=(e=>(e.Success="success",e.Info="info",e.Warning="warning",e.Error="error",e.Loading="loading",e))(Zf||{});const qf="univer-message-toaster",Xf=3e3,Hr=new Set,Qf=v.jsx(vl,{className:"univer-animate-spin univer-text-violet-500"});let Gu=0;const Hw={success:v.jsx(ll,{className:"univer-text-green-500"}),info:v.jsx(il,{className:"univer-text-sky-500 dark:!univer-text-sky-400"}),warning:v.jsx(cl,{className:"univer-text-amber-500"}),error:v.jsx(ol,{className:"univer-text-red-500"}),loading:Qf},Lr={success:"[&_[data-icon]]:univer-text-green-500",info:"[&_[data-icon]]:univer-text-sky-500",warning:"[&_[data-icon]]:univer-text-amber-500",error:"[&_[data-icon]]:univer-text-red-500",loading:"[&_[data-icon]]:univer-text-violet-500"},Vw=e=>{switch(e){case"success":return Nn.success;case"warning":return Nn.warning;case"error":return Nn.error;case"loading":return Nn.loading;default:return Nn.info}},Ww=()=>{const e=`univer-message-${Gu}`;return Gu+=1,e},Kw=({className:e,...t})=>v.jsx(Yf,{id:qf,position:"top-center",visibleToasts:4,closeButton:!1,expand:!1,icons:{loading:Qf},offset:{top:16},className:W(`
264
- [&_[data-sonner-toast]]:univer-bg-white/95
265
- dark:[&_[data-sonner-toast]]:!univer-bg-gray-800/95
266
- [&_[data-sonner-toast]]:univer-rounded-2xl [&_[data-sonner-toast]]:univer-border
267
- [&_[data-sonner-toast]]:univer-border-solid [&_[data-sonner-toast]]:univer-border-gray-200
268
- [&_[data-sonner-toast]]:univer-shadow-[0_16px_40px_-20px_rgba(15,23,42,0.55)]
269
- [&_[data-sonner-toast]]:univer-backdrop-blur-sm
270
- dark:[&_[data-sonner-toast]]:!univer-border-gray-600
271
- `,e),toastOptions:{duration:Xf,classNames:{toast:`
146
+ `,s&&!g&&`univer-pr-8`,_),placeholder:i,value:a,disabled:c,autoFocus:e,onClick:l,onKeyDown:u,onChange:S,onFocus:p,onBlur:m,style:{...v,paddingRight:w},...y}),C&&(0,z.jsxs)(`div`,{className:`univer-absolute univer-right-2 univer-flex univer-items-center univer-gap-1 univer-rounded-full`,ref:E,children:[g,s&&a&&!c&&(0,z.jsx)(`button`,{type:`button`,onClick:x,className:`univer-flex univer-size-4 univer-cursor-pointer univer-items-center univer-rounded-full univer-border-none univer-bg-transparent univer-p-1 univer-text-gray-400 univer-transition-colors univer-duration-200 hover:univer-text-gray-500 focus:univer-outline-none`,children:(0,z.jsx)(f.CloseIcon,{className:`univer-size-3`})})]})]})}),nf=(0,h.forwardRef)(({value:e,defaultValue:t,size:n=`small`,min:r=-(2**53-1),max:i=2**53-1,step:a=1,precision:o,formatter:s,parser:c,controls:l=!0,className:u,inputClassName:d,controlsClassName:f,disabled:p,onChange:m,onKeyDown:g,onPressEnter:_,onFocus:v,onBlur:y,allowEmpty:b=!1},x)=>{let[S,C]=(0,h.useState)(e===void 0?t===void 0?null:t:e),w=(0,h.useRef)(S),[T,E]=(0,h.useState)(j(S)),D=(0,h.useRef)(null),O=(0,h.useRef)(null),k=(0,h.useRef)(null),A=e=>{x&&(typeof x==`function`?x(e):x.current=e),D.current=e};(0,h.useEffect)(()=>{e!==void 0&&e!==S&&(C(e),w.current=e,E(j(e)))},[e]),(0,h.useEffect)(()=>{S!==null&&(w.current=S)},[S]),(0,h.useEffect)(()=>()=>{O.current&&clearTimeout(O.current),k.current&&clearInterval(k.current)},[]);function j(e){if(e==null)return``;let t=e;return o!==void 0&&(t=Number(e).toFixed(o)),s?s(t):String(t)}function ee(e){if(!e)return null;let t=e;c&&(t=c(e));try{let e=t.replace(/[^\d.-]/g,``).split(`.`),n=e[0],a=e.length>1?e.slice(1).join(``):``,s=n+(a?`.${a}`:``),c=Number(s);if(Number.isNaN(c))return null;let l;if(o!==void 0){let e=10**o,t=Math.round(c*e)/e;l=t.toString().includes(`e`)?Number.parseFloat(t.toFixed(o)):t}else l=c.toString().includes(`e`)?Number.parseFloat(c.toFixed(16).replace(/\.?0+$/,``)):c;return i!==void 0&&l>i&&(l=i),r!==void 0&&l<r&&(l=r),l}catch{return null}}function M(e){if(E(e),b&&e===``){C(null),m==null||m(null);return}let t=ee(e);C(t),m==null||m(t)}function N(e){if(S===null){if(T===``&&b)m&&m(null);else{let e=w.current;C(e),E(j(e)),m&&m(e)}y==null||y(e);return}let t=S;i!==void 0&&t>i&&(t=i),r!==void 0&&t<r&&(t=r),t===S?E(j(S)):(C(t),E(j(t)),m==null||m(t)),y==null||y(e)}function P(e){if(p)return;let t=e?a:-a,n;n=S===null?w.current===null?r>0?r:0:w.current:S;let o=n+t;i!==void 0&&o>i&&(o=i),r!==void 0&&o<r&&(o=r),o!==n&&(C(o),w.current=o,E(j(o)),m==null||m(o))}function F(e){p||(g==null||g(e),e.key===`ArrowUp`?(e.preventDefault(),P(!0)):e.key===`ArrowDown`?(e.preventDefault(),P(!1)):e.key===`Enter`&&(_==null||_(e)))}function te(e){var t;p||(P(e),(t=D.current)==null||t.focus())}let ne=p||i!==void 0&&S!==null&&S>=i,re=p||r!==void 0&&S!==null&&S<=r;return(0,z.jsx)(`div`,{className:R(`univer-inline-block`,u),children:(0,z.jsxs)(`div`,{className:`univer-relative univer-w-full`,children:[(0,z.jsx)(tf,{ref:A,className:R(`univer-box-border`,d),size:n,value:T,disabled:p,onChange:M,onFocus:v,onBlur:N,onKeyDown:F}),l&&(0,z.jsxs)(`div`,{className:R(`univer-absolute univer-right-px univer-top-px univer-flex univer-h-[calc(100%-2px)] univer-flex-col univer-overflow-hidden univer-rounded-r-md before:univer-absolute before:univer-top-1/2 before:univer-block before:univer-h-px before:univer-w-full before:-univer-translate-y-1/2 before:univer-bg-gray-200 before:univer-content-[""] dark:before:!univer-bg-gray-600`,st,f),children:[(0,z.jsx)(`span`,{className:R(`univer-box-border univer-flex univer-h-1/2 univer-w-5 univer-cursor-pointer univer-items-center univer-justify-center univer-border-none univer-bg-transparent univer-p-0 univer-transition-colors hover:univer-bg-gray-100 dark:!univer-text-white dark:hover:!univer-bg-gray-600`,ne&&`univer-cursor-not-allowed univer-opacity-60`),role:`button`,"aria-label":`increment`,"aria-disabled":ne,tabIndex:-1,onMouseDown:e=>e.preventDefault(),onClick:()=>{ne||te(!0)},children:`+`}),(0,z.jsx)(`span`,{className:R(`univer-box-border univer-flex univer-h-1/2 univer-w-5 univer-cursor-pointer univer-items-center univer-justify-center univer-border-none univer-bg-transparent univer-p-0 univer-transition-colors hover:univer-bg-gray-100 dark:!univer-text-white dark:hover:!univer-bg-gray-600`,re&&`univer-cursor-not-allowed univer-opacity-60`),role:`button`,"aria-label":`decrement`,"aria-disabled":re,tabIndex:-1,onMouseDown:e=>e.preventDefault(),onClick:()=>{re||te(!1)},children:`-`})]})]})})});function rf({items:e,value:t,defaultValue:n,onChange:r,className:i=``}){let[a,o]=(0,h.useState)(t===void 0?n||e[0].value:t),[s,c]=(0,h.useState)({}),l=(0,h.useRef)(new Map),u=(0,h.useRef)(null);(0,h.useEffect)(()=>{t!==void 0&&t!==a&&o(t)},[t]);let d=(e,t)=>{let n=l.current.get(e),r=t?l.current.get(t):null;if(n&&u.current){let e=u.current.getBoundingClientRect(),t=n.getBoundingClientRect(),i=t.left-e.left-4;if(r){let n=r.getBoundingClientRect().left-e.left-4;c({"--slide-from":`${n}px`,"--slide-to":`${i}px`,width:`${t.width}px`,transform:`translateX(${i}px)`})}else c({width:`${t.width}px`,transform:`translateX(${i}px)`})}};(0,h.useEffect)(()=>{d(a)},[a]);let f=e=>{let t=a;o(e),r==null||r(e),d(e,t)};return(0,z.jsxs)(`div`,{"data-u-comp":`segmented`,ref:u,className:R(`univer-relative univer-box-border univer-flex univer-gap-4 univer-rounded-lg univer-bg-gray-100 univer-p-1 dark:!univer-bg-gray-800`,i),children:[(0,z.jsx)(`div`,{className:`univer-animate-univer-slide univer-absolute univer-h-6 univer-rounded-md univer-bg-white univer-shadow-sm univer-transition-all univer-duration-200 dark:!univer-bg-gray-700 dark:!univer-text-gray-400`,style:s}),e.map(e=>(0,z.jsx)(`button`,{ref:t=>{t&&l.current.set(e.value,t)},className:R(`univer-relative univer-box-border univer-flex-1 univer-cursor-pointer univer-border-none univer-bg-transparent univer-px-3 univer-py-1 univer-text-xs univer-font-medium univer-transition-colors`,{"univer-text-gray-900 dark:!univer-text-white":a===e.value,"univer-text-gray-500 hover:univer-text-gray-900 dark:hover:!univer-text-white":a!==e.value}),type:`button`,onClick:()=>f(e.value),children:e.label},String(e.value)))]})}function af(e){let{children:t,className:n,asChild:r=!0,title:i,placement:a=`bottom`,showIfEllipsis:o=!1,visible:s,onVisibleChange:c}=e,[l,u]=(0,h.useState)(!1),d=s!==void 0,f=d?s:l,p=(0,h.useRef)(null),m=(0,h.useRef)(null),g=(0,h.useRef)(null),[_,v]=(0,h.useState)(null),[y,b]=(0,h.useState)(a);function x(e){return Math.abs(e.scrollWidth-e.clientWidth)>1}function S(){d?c==null||c(!0):u(!0)}function C(){d?c==null||c(!1):u(!1)}(0,h.useLayoutEffect)(()=>{if(!f)return;let e=p.current,t=m.current;if(!e||!t)return;let n=e.getBoundingClientRect(),r=t.getBoundingClientRect(),i=window.innerWidth,o=window.innerHeight,s=[a,`bottom`,`top`,`right`,`left`],c=a,l=0,u=0,d=e=>{let t=0,i=0;return e===`bottom`?(t=n.bottom+8,i=n.left+n.width/2-r.width/2):e===`top`?(t=n.top-r.height-8,i=n.left+n.width/2-r.width/2):e===`left`?(t=n.top+n.height/2-r.height/2,i=n.left-r.width-8):(t=n.top+n.height/2-r.height/2,i=n.right+8),{t,l:i}};for(let e of s){let{t,l:n}=d(e),a=n>=0&&n+r.width<=i,s=t>=0&&t+r.height<=o;if(a&&s){c=e,l=t,u=n;break}}if(!l&&!u){let e=d(a);l=Math.min(Math.max(0,e.t),o-r.height),u=Math.min(Math.max(0,e.l),i-r.width)}b(c),v({top:Math.round(l+window.scrollY),left:Math.round(u+window.scrollX)})},[f,a]),(0,h.useEffect)(()=>{if(!f)return;let e=()=>{if(!p.current||!m.current)return;let e=p.current.getBoundingClientRect(),t=m.current.getBoundingClientRect(),n=0,r=0;y===`bottom`?(n=e.bottom+8,r=e.left+e.width/2-t.width/2):y===`top`?(n=e.top-t.height-8,r=e.left+e.width/2-t.width/2):y===`left`?(n=e.top+e.height/2-t.height/2,r=e.left-t.width-8):(n=e.top+e.height/2-t.height/2,r=e.right+8),v({top:Math.round(n+window.scrollY),left:Math.round(r+window.scrollX)})};return window.addEventListener(`scroll`,e,!0),window.addEventListener(`resize`,e),()=>{window.removeEventListener(`scroll`,e,!0),window.removeEventListener(`resize`,e)}},[f,y]);let w={ref:e=>p.current=e,onMouseEnter:()=>{o&&p.current&&!x(p.current)||S()},onMouseLeave:()=>C(),onFocus:()=>S(),onBlur:()=>C()},T=r?(0,z.jsx)(`span`,{...w,className:`univer-inline-block univer-max-w-full univer-truncate`,children:t}):(0,z.jsx)(`button`,{type:`button`,...w,children:t}),E=null;if(typeof document<`u`&&f&&i&&document.body){var D,O;E=(0,Pt.createPortal)((0,z.jsxs)(`div`,{ref:m,role:`tooltip`,className:R(`univer-animate-in univer-fade-in-0 univer-zoom-in-95 univer-pointer-events-auto univer-absolute univer-z-[1081] univer-box-border univer-w-fit univer-max-w-sm univer-text-balance univer-rounded-lg univer-bg-gray-700 univer-px-2.5 univer-py-2 univer-text-xs univer-font-medium univer-text-white univer-shadow-lg univer-drop-shadow-sm dark:!univer-bg-gray-100 dark:!univer-text-gray-900`,n),style:{top:(D=_==null?void 0:_.top)==null?-9999:D,left:(O=_==null?void 0:_.left)==null?-9999:O},onMouseEnter:()=>S(),onMouseLeave:()=>C(),children:[(0,z.jsx)(`div`,{className:`univer-break-words`,children:i}),(0,z.jsx)(`div`,{ref:g,className:`univer-absolute univer-size-2.5 univer-rotate-45 univer-rounded-sm univer-bg-gray-700 dark:!univer-bg-gray-100`,style:{...y===`bottom`&&{top:-5,left:`50%`,transform:`translateX(-50%) rotate(45deg)`},...y===`top`&&{bottom:-5,left:`50%`,transform:`translateX(-50%) rotate(45deg)`},...y===`left`&&{right:-5,top:`50%`,transform:`translateY(-50%) rotate(45deg)`},...y===`right`&&{left:-5,top:`50%`,transform:`translateY(-50%) rotate(45deg)`}}})]}),document.body)}return(0,z.jsxs)(z.Fragment,{children:[T,E]})}const of={type:`linear`,stops:[{color:`#ffffff`,offset:0},{color:`#000000`,offset:100}],angle:90};function sf(e){var t,n;let{className:r,value:i=of,onChange:a}=e,{locale:o}=(0,h.useContext)(et),[s,c]=(0,h.useState)(0),l=(0,h.useRef)(null),u=(0,h.useMemo)(()=>[...i.stops].sort((e,t)=>e.offset-t.offset),[i.stops]),d=e=>{a==null||a({...i,type:e})},p=e=>{a==null||a({...i,angle:e==null?0:e})},m=e=>{let t=[...i.stops];t[s]={...t[s],color:e},a==null||a({...i,stops:t})},g=e=>{if(e===null)return;let t=[...i.stops];t[s]={...t[s],offset:e},a==null||a({...i,stops:t})},_=e=>{if(!l.current)return;let t=l.current.getBoundingClientRect(),n=Math.round((e.clientX-t.left)/t.width*100),r={color:([...u].reverse().find(e=>e.offset<=n)||u[0]).color,offset:n},o=[...i.stops,r];a==null||a({...i,stops:o}),c(o.length-1)},v=()=>{if(i.stops.length<=2)return;let e=i.stops.filter((e,t)=>t!==s);a==null||a({...i,stops:e}),c(0)},y=(0,h.useMemo)(()=>`linear-gradient(to right, ${u.map(e=>`${e.color} ${e.offset}%`).join(`, `)})`,[u]),b=(0,h.useMemo)(()=>{let e=u.map(e=>`${e.color} ${e.offset}%`).join(`, `);switch(i.type){case`linear`:return`linear-gradient(${i.angle}deg, ${e})`;case`radial`:return`radial-gradient(circle, ${e})`;case`angular`:return`conic-gradient(from ${i.angle}deg, ${e})`;case`diamond`:return`radial-gradient(circle, ${e})`;default:return`linear-gradient(${i.angle}deg, ${e})`}},[i,u]);return(0,z.jsxs)(`div`,{className:R(`univer-flex univer-w-64 univer-flex-col univer-gap-4 univer-rounded-lg univer-bg-white univer-p-4 univer-shadow-lg dark:!univer-bg-gray-800`,r),children:[(0,z.jsx)(rf,{items:[{label:o==null?void 0:o.GradientColorPicker.linear,value:`linear`},{label:o==null?void 0:o.GradientColorPicker.radial,value:`radial`},{label:o==null?void 0:o.GradientColorPicker.angular,value:`angular`},{label:o==null?void 0:o.GradientColorPicker.diamond,value:`diamond`}],value:i.type,onChange:e=>d(e)}),(0,z.jsx)(`div`,{className:`univer-h-32 univer-w-full univer-rounded-md univer-border univer-border-gray-200 dark:!univer-border-gray-600`,style:{background:b}}),(0,z.jsxs)(`div`,{className:`univer-relative univer-mt-4 univer-h-6`,children:[(0,z.jsx)(`div`,{ref:l,className:`univer-absolute univer-inset-x-0 univer-top-1/2 univer-h-2 -univer-translate-y-1/2 univer-cursor-crosshair univer-rounded-full`,style:{background:y},onClick:_}),i.stops.map((e,t)=>(0,z.jsx)(`div`,{className:R(`univer-absolute univer-top-1/2 univer-size-4 -univer-translate-x-1/2 -univer-translate-y-1/2 univer-cursor-pointer univer-rounded-full univer-border-2 univer-border-white univer-shadow-md`,s===t?`univer-z-10 univer-ring-2 univer-ring-primary-500`:`univer-z-0`),style:{left:`${e.offset}%`,backgroundColor:e.color},onClick:e=>{e.stopPropagation(),c(t)},onPointerDown:n=>{let r=n.clientX,o=e.offset,s=e=>{if(!l.current)return;let n=l.current.getBoundingClientRect(),s=(e.clientX-r)/n.width*100,c=Math.max(0,Math.min(100,Math.round(o+s))),u=[...i.stops];u[t]={...u[t],offset:c},a==null||a({...i,stops:u})},c=()=>{window.removeEventListener(`pointermove`,s),window.removeEventListener(`pointerup`,c)};window.addEventListener(`pointermove`,s),window.addEventListener(`pointerup`,c)}},t))]}),(0,z.jsxs)(`div`,{className:`univer-flex univer-items-end univer-gap-2`,children:[(0,z.jsxs)(`div`,{className:`univer-flex-1`,children:[(0,z.jsx)(`div`,{className:`univer-mb-1 univer-text-xs univer-text-gray-500`,children:o==null?void 0:o.GradientColorPicker.offset}),(0,z.jsx)(nf,{value:(t=i.stops[s])==null?void 0:t.offset,min:0,max:100,onChange:g})]}),(i.type===`linear`||i.type===`angular`)&&(0,z.jsxs)(`div`,{className:`univer-flex-1`,children:[(0,z.jsx)(`div`,{className:`univer-mb-1 univer-text-xs univer-text-gray-500`,children:o==null?void 0:o.GradientColorPicker.angle}),(0,z.jsx)(nf,{value:i.angle,min:0,max:360,onChange:p})]}),(0,z.jsx)(`div`,{className:`univer-flex univer-gap-1`,children:(0,z.jsx)(af,{title:o==null?void 0:o.GradientColorPicker.delete,children:(0,z.jsx)(Ze,{variant:`danger`,onClick:v,disabled:i.stops.length<=2,children:(0,z.jsx)(f.DeleteIcon,{})})})})]}),(0,z.jsx)(`div`,{className:`univer-border-t univer-border-gray-100 univer-pt-4 dark:!univer-border-gray-700`,children:(0,z.jsx)(ga,{value:(n=i.stops[s])==null?void 0:n.color,onChange:m})})]})}var cf,lf=`HoverCard`,[uf,df]=xt(lf,[Rs]),ff=Rs(),[pf,mf]=uf(lf),hf=e=>{let{__scopeHoverCard:t,children:n,open:r,defaultOpen:i,onOpenChange:a,openDelay:o=700,closeDelay:s=300}=e,c=ff(t),l=h.useRef(0),u=h.useRef(0),d=h.useRef(!1),f=h.useRef(!1),[p,m]=kt({prop:r,defaultProp:i==null?!1:i,onChange:a,caller:lf}),g=h.useCallback(()=>{clearTimeout(u.current),l.current=window.setTimeout(()=>m(!0),o)},[o,m]),_=h.useCallback(()=>{clearTimeout(l.current),!d.current&&!f.current&&(u.current=window.setTimeout(()=>m(!1),s))},[s,m]),v=h.useCallback(()=>m(!1),[m]);return h.useEffect(()=>()=>{clearTimeout(l.current),clearTimeout(u.current)},[]),(0,z.jsx)(pf,{scope:t,open:p,onOpenChange:m,onOpen:g,onClose:_,onDismiss:v,hasSelectionRef:d,isPointerDownOnContentRef:f,children:(0,z.jsx)(ec,{...c,children:n})})};hf.displayName=lf;var gf=`HoverCardTrigger`,_f=h.forwardRef((e,t)=>{let{__scopeHoverCard:n,...r}=e,i=mf(gf,n),a=ff(n);return(0,z.jsx)(tc,{asChild:!0,...a,children:(0,z.jsx)(Vt.a,{"data-state":i.open?`open`:`closed`,...r,ref:t,onPointerEnter:B(e.onPointerEnter,Df(i.onOpen)),onPointerLeave:B(e.onPointerLeave,Df(i.onClose)),onFocus:B(e.onFocus,i.onOpen),onBlur:B(e.onBlur,i.onClose),onTouchStart:B(e.onTouchStart,e=>e.preventDefault())})})});_f.displayName=gf;var vf=`HoverCardPortal`,[yf,bf]=uf(vf,{forceMount:void 0}),xf=e=>{let{__scopeHoverCard:t,forceMount:n,children:r,container:i}=e,a=mf(vf,t);return(0,z.jsx)(yf,{scope:t,forceMount:n,children:(0,z.jsx)(wn,{present:n||a.open,children:(0,z.jsx)(Sn,{asChild:!0,container:i,children:r})})})};xf.displayName=vf;var Sf=`HoverCardContent`,Cf=h.forwardRef((e,t)=>{let n=bf(Sf,e.__scopeHoverCard),{forceMount:r=n.forceMount,...i}=e,a=mf(Sf,e.__scopeHoverCard);return(0,z.jsx)(wn,{present:r||a.open,children:(0,z.jsx)(wf,{"data-state":a.open?`open`:`closed`,...i,onPointerEnter:B(e.onPointerEnter,Df(a.onOpen)),onPointerLeave:B(e.onPointerLeave,Df(a.onClose)),ref:t})})});Cf.displayName=Sf;var wf=h.forwardRef((e,t)=>{let{__scopeHoverCard:n,onEscapeKeyDown:r,onPointerDownOutside:i,onFocusOutside:a,onInteractOutside:o,...s}=e,c=mf(Sf,n),l=ff(n),u=h.useRef(null),d=Re(t,u),[f,p]=h.useState(!1);return h.useEffect(()=>{if(f){let e=document.body;return cf=e.style.userSelect||e.style.webkitUserSelect,e.style.userSelect=`none`,e.style.webkitUserSelect=`none`,()=>{e.style.userSelect=cf,e.style.webkitUserSelect=cf}}},[f]),h.useEffect(()=>{if(u.current){let e=()=>{p(!1),c.isPointerDownOnContentRef.current=!1,setTimeout(()=>{var e;((e=document.getSelection())==null?void 0:e.toString())!==``&&(c.hasSelectionRef.current=!0)})};return document.addEventListener(`pointerup`,e),()=>{document.removeEventListener(`pointerup`,e),c.hasSelectionRef.current=!1,c.isPointerDownOnContentRef.current=!1}}},[c.isPointerDownOnContentRef,c.hasSelectionRef]),h.useEffect(()=>{u.current&&Of(u.current).forEach(e=>e.setAttribute(`tabindex`,`-1`))}),(0,z.jsx)(Zt,{asChild:!0,disableOutsidePointerEvents:!1,onInteractOutside:o,onEscapeKeyDown:r,onPointerDownOutside:i,onFocusOutside:B(a,e=>{e.preventDefault()}),onDismiss:c.onDismiss,children:(0,z.jsx)(nc,{...l,...s,onPointerDown:B(s.onPointerDown,e=>{e.currentTarget.contains(e.target)&&p(!0),c.hasSelectionRef.current=!1,c.isPointerDownOnContentRef.current=!0}),ref:d,style:{...s.style,userSelect:f?`text`:void 0,WebkitUserSelect:f?`text`:void 0,"--radix-hover-card-content-transform-origin":`var(--radix-popper-transform-origin)`,"--radix-hover-card-content-available-width":`var(--radix-popper-available-width)`,"--radix-hover-card-content-available-height":`var(--radix-popper-available-height)`,"--radix-hover-card-trigger-width":`var(--radix-popper-anchor-width)`,"--radix-hover-card-trigger-height":`var(--radix-popper-anchor-height)`}})})}),Tf=`HoverCardArrow`,Ef=h.forwardRef((e,t)=>{let{__scopeHoverCard:n,...r}=e,i=ff(n);return(0,z.jsx)(rc,{...i,...r,ref:t})});Ef.displayName=Tf;function Df(e){return t=>t.pointerType===`touch`?void 0:e()}function Of(e){let t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP});for(;n.nextNode();)t.push(n.currentNode);return t}var kf=hf,Af=_f,jf=xf,Mf=Cf;const Nf=kf,Pf=jf,Ff=Af,If=(0,h.forwardRef)(({className:e,align:t=`center`,sideOffset:n=4,...r},i)=>(0,z.jsx)(Mf,{ref:i,align:t,sideOffset:n,className:R(`data-[state=open]:univer-animate-in data-[state=open]:univer-fade-in-0 data-[state=open]:univer-zoom-in-95 data-[state=closed]:univer-animate-out data-[state=closed]:univer-fade-out-0 data-[state=closed]:univer-zoom-out-95 data-[side=bottom]:univer-slide-in-from-top-2 data-[side=left]:univer-slide-in-from-right-2 data-[side=right]:univer-slide-in-from-left-2 data-[side=top]:univer-slide-in-from-bottom-2 univer-z-[1080] univer-w-64 univer-origin-[--radix-hover-card-content-transform-origin] univer-rounded-md univer-bg-white univer-text-gray-900 univer-shadow-md univer-outline-none dark:!univer-bg-gray-900 dark:!univer-text-white`,at,e),...r}));If.displayName=Mf.displayName;function Lf(e){let{children:t,overlay:n,disabled:r,openDelay:i=200,open:a,onOpenChange:o,...s}=e,[c,l]=(0,h.useState)(!1),u=a!==void 0,d=u?a:c;function f(e){r||(u||l(e),o==null||o(e))}return(0,z.jsxs)(Nf,{open:d,onOpenChange:f,openDelay:i,children:[(0,z.jsx)(Ff,{asChild:!0,children:t}),(0,z.jsx)(Pf,{children:(0,z.jsx)(If,{...s,children:n})})]})}function Rf(e){let{keyboard:t,className:n}=e,r=t.split(`+`);return(0,z.jsx)(`span`,{className:R(`univer-inline-block univer-h-6 univer-select-none univer-whitespace-nowrap univer-rounded-md univer-bg-gray-50 univer-px-2 univer-font-mono univer-text-xs/6 univer-font-medium univer-text-gray-700 dark:!univer-bg-gray-700 dark:!univer-text-white`,at,n),children:r.map((e,t)=>(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(`kbd`,{className:`univer-inline-block univer-h-full`,children:e}),t<r.length-1&&(0,z.jsx)(`span`,{className:`univer-inline-block univer-h-full univer-px-1`,children:`+`})]},t))})}function zf(e){if(!e||typeof document>`u`)return;let t=document.head||document.getElementsByTagName(`head`)[0],n=document.createElement(`style`);n.type=`text/css`,t.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}const Bf=e=>{switch(e){case`success`:return Uf;case`info`:return Gf;case`warning`:return Wf;case`error`:return Kf;default:return null}},Vf=Array(12).fill(0),Hf=({visible:e,className:t})=>h.createElement(`div`,{className:[`sonner-loading-wrapper`,t].filter(Boolean).join(` `),"data-visible":e},h.createElement(`div`,{className:`sonner-spinner`},Vf.map((e,t)=>h.createElement(`div`,{className:`sonner-loading-bar`,key:`spinner-bar-${t}`})))),Uf=h.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 20 20`,fill:`currentColor`,height:`20`,width:`20`},h.createElement(`path`,{fillRule:`evenodd`,d:`M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z`,clipRule:`evenodd`})),Wf=h.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 24 24`,fill:`currentColor`,height:`20`,width:`20`},h.createElement(`path`,{fillRule:`evenodd`,d:`M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z`,clipRule:`evenodd`})),Gf=h.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 20 20`,fill:`currentColor`,height:`20`,width:`20`},h.createElement(`path`,{fillRule:`evenodd`,d:`M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z`,clipRule:`evenodd`})),Kf=h.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 20 20`,fill:`currentColor`,height:`20`,width:`20`},h.createElement(`path`,{fillRule:`evenodd`,d:`M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z`,clipRule:`evenodd`})),qf=h.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`12`,height:`12`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`1.5`,strokeLinecap:`round`,strokeLinejoin:`round`},h.createElement(`line`,{x1:`18`,y1:`6`,x2:`6`,y2:`18`}),h.createElement(`line`,{x1:`6`,y1:`6`,x2:`18`,y2:`18`})),Jf=()=>{let[e,t]=h.useState(document.hidden);return h.useEffect(()=>{let e=()=>{t(document.hidden)};return document.addEventListener(`visibilitychange`,e),()=>window.removeEventListener(`visibilitychange`,e)},[]),e};let Yf=1;const Xf=new class{constructor(){this.subscribe=e=>(this.subscribers.push(e),()=>{let t=this.subscribers.indexOf(e);this.subscribers.splice(t,1)}),this.publish=e=>{this.subscribers.forEach(t=>t(e))},this.addToast=e=>{this.publish(e),this.toasts=[...this.toasts,e]},this.create=e=>{var t;let{message:n,...r}=e,i=typeof(e==null?void 0:e.id)==`number`||((t=e.id)==null?void 0:t.length)>0?e.id:Yf++,a=this.toasts.find(e=>e.id===i),o=e.dismissible===void 0?!0:e.dismissible;return this.dismissedToasts.has(i)&&this.dismissedToasts.delete(i),a?this.toasts=this.toasts.map(t=>t.id===i?(this.publish({...t,...e,id:i,title:n}),{...t,...e,id:i,dismissible:o,title:n}):t):this.addToast({title:n,...r,dismissible:o,id:i}),i},this.dismiss=e=>(e?(this.dismissedToasts.add(e),requestAnimationFrame(()=>this.subscribers.forEach(t=>t({id:e,dismiss:!0})))):this.toasts.forEach(e=>{this.subscribers.forEach(t=>t({id:e.id,dismiss:!0}))}),e),this.message=(e,t)=>this.create({...t,message:e}),this.error=(e,t)=>this.create({...t,message:e,type:`error`}),this.success=(e,t)=>this.create({...t,type:`success`,message:e}),this.info=(e,t)=>this.create({...t,type:`info`,message:e}),this.warning=(e,t)=>this.create({...t,type:`warning`,message:e}),this.loading=(e,t)=>this.create({...t,type:`loading`,message:e}),this.promise=(e,t)=>{if(!t)return;let n;t.loading!==void 0&&(n=this.create({...t,promise:e,type:`loading`,message:t.loading,description:typeof t.description==`function`?void 0:t.description}));let r=Promise.resolve(e instanceof Function?e():e),i=n!==void 0,a,o=r.then(async e=>{if(a=[`resolve`,e],h.isValidElement(e))i=!1,this.create({id:n,type:`default`,message:e});else if(Qf(e)&&!e.ok){i=!1;let r=typeof t.error==`function`?await t.error(`HTTP error! status: ${e.status}`):t.error,a=typeof t.description==`function`?await t.description(`HTTP error! status: ${e.status}`):t.description,o=typeof r==`object`&&!h.isValidElement(r)?r:{message:r};this.create({id:n,type:`error`,description:a,...o})}else if(e instanceof Error){i=!1;let r=typeof t.error==`function`?await t.error(e):t.error,a=typeof t.description==`function`?await t.description(e):t.description,o=typeof r==`object`&&!h.isValidElement(r)?r:{message:r};this.create({id:n,type:`error`,description:a,...o})}else if(t.success!==void 0){i=!1;let r=typeof t.success==`function`?await t.success(e):t.success,a=typeof t.description==`function`?await t.description(e):t.description,o=typeof r==`object`&&!h.isValidElement(r)?r:{message:r};this.create({id:n,type:`success`,description:a,...o})}}).catch(async e=>{if(a=[`reject`,e],t.error!==void 0){i=!1;let r=typeof t.error==`function`?await t.error(e):t.error,a=typeof t.description==`function`?await t.description(e):t.description,o=typeof r==`object`&&!h.isValidElement(r)?r:{message:r};this.create({id:n,type:`error`,description:a,...o})}}).finally(()=>{i&&(this.dismiss(n),n=void 0),t.finally==null||t.finally.call(t)}),s=()=>new Promise((e,t)=>o.then(()=>a[0]===`reject`?t(a[1]):e(a[1])).catch(t));return typeof n!=`string`&&typeof n!=`number`?{unwrap:s}:Object.assign(n,{unwrap:s})},this.custom=(e,t)=>{let n=(t==null?void 0:t.id)||Yf++;return this.create({jsx:e(n),id:n,...t}),n},this.getActiveToasts=()=>this.toasts.filter(e=>!this.dismissedToasts.has(e.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}},Zf=(e,t)=>{let n=(t==null?void 0:t.id)||Yf++;return Xf.addToast({title:e,...t,id:n}),n},Qf=e=>e&&typeof e==`object`&&`ok`in e&&typeof e.ok==`boolean`&&`status`in e&&typeof e.status==`number`,$f=Zf,ep=Object.assign($f,{success:Xf.success,info:Xf.info,warning:Xf.warning,error:Xf.error,custom:Xf.custom,message:Xf.message,promise:Xf.promise,dismiss:Xf.dismiss,loading:Xf.loading},{getHistory:()=>Xf.toasts,getToasts:()=>Xf.getActiveToasts()});zf(`[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}`);function tp(e){return e.label!==void 0}const np=4e3;function rp(...e){return e.filter(Boolean).join(` `)}function ip(e){let[t,n]=e.split(`-`),r=[];return t&&r.push(t),n&&r.push(n),r}const ap=e=>{var t,n,r,i,a,o,s,c,l;let{invert:u,toast:d,unstyled:f,interacting:p,setHeights:m,visibleToasts:g,heights:_,index:v,toasts:y,expanded:b,removeToast:x,defaultRichColors:S,closeButton:C,style:w,cancelButtonStyle:T,actionButtonStyle:E,className:D=``,descriptionClassName:O=``,duration:k,position:A,gap:j,expandByDefault:ee,classNames:M,icons:N,closeButtonAriaLabel:P=`Close toast`}=e,[F,te]=h.useState(null),[ne,re]=h.useState(null),[ie,I]=h.useState(!1),[ae,oe]=h.useState(!1),[se,ce]=h.useState(!1),[le,ue]=h.useState(!1),[de,fe]=h.useState(!1),[pe,L]=h.useState(0),[me,he]=h.useState(0),ge=h.useRef(d.duration||k||np),_e=h.useRef(null),ve=h.useRef(null),ye=v===0,be=v+1<=g,xe=d.type,Se=d.dismissible!==!1,Ce=d.className||``,we=d.descriptionClassName||``,Te=h.useMemo(()=>_.findIndex(e=>e.toastId===d.id)||0,[_,d.id]),Ee=h.useMemo(()=>{var e;return(e=d.closeButton)==null?C:e},[d.closeButton,C]),De=h.useMemo(()=>d.duration||k||np,[d.duration,k]),R=h.useRef(0),Oe=h.useRef(0),z=h.useRef(0),ke=h.useRef(null),[Ae,je]=A.split(`-`),Me=h.useMemo(()=>_.reduce((e,t,n)=>n>=Te?e:e+t.height,0),[_,Te]),Ne=Jf(),Pe=d.invert||u,Fe=xe===`loading`;Oe.current=h.useMemo(()=>Te*j+Me,[Te,Me]),h.useEffect(()=>{ge.current=De},[De]),h.useEffect(()=>{I(!0)},[]),h.useEffect(()=>{let e=ve.current;if(e){let t=e.getBoundingClientRect().height;return he(t),m(e=>[{toastId:d.id,height:t,position:d.position},...e]),()=>m(e=>e.filter(e=>e.toastId!==d.id))}},[m,d.id]),h.useLayoutEffect(()=>{if(!ie)return;let e=ve.current,t=e.style.height;e.style.height=`auto`;let n=e.getBoundingClientRect().height;e.style.height=t,he(n),m(e=>e.find(e=>e.toastId===d.id)?e.map(e=>e.toastId===d.id?{...e,height:n}:e):[{toastId:d.id,height:n,position:d.position},...e])},[ie,d.title,d.description,m,d.id,d.jsx,d.action,d.cancel]);let Ie=h.useCallback(()=>{oe(!0),L(Oe.current),m(e=>e.filter(e=>e.toastId!==d.id)),setTimeout(()=>{x(d)},200)},[d,x,m,Oe]);h.useEffect(()=>{if(d.promise&&xe===`loading`||d.duration===1/0||d.type===`loading`)return;let e;return b||p||Ne?(()=>{if(z.current<R.current){let e=new Date().getTime()-R.current;ge.current-=e}z.current=new Date().getTime()})():ge.current!==1/0&&(R.current=new Date().getTime(),e=setTimeout(()=>{d.onAutoClose==null||d.onAutoClose.call(d,d),Ie()},ge.current)),()=>clearTimeout(e)},[b,p,d,xe,Ne,Ie]),h.useEffect(()=>{d.delete&&(Ie(),d.onDismiss==null||d.onDismiss.call(d,d))},[Ie,d.delete]);function Le(){var e;if(N!=null&&N.loading){var t;return h.createElement(`div`,{className:rp(M==null?void 0:M.loader,d==null||(t=d.classNames)==null?void 0:t.loader,`sonner-loader`),"data-visible":xe===`loading`},N.loading)}return h.createElement(Hf,{className:rp(M==null?void 0:M.loader,d==null||(e=d.classNames)==null?void 0:e.loader),visible:xe===`loading`})}let Re=d.icon||(N==null?void 0:N[xe])||Bf(xe);var ze,Be;return h.createElement(`li`,{tabIndex:0,ref:ve,className:rp(D,Ce,M==null?void 0:M.toast,d==null||(t=d.classNames)==null?void 0:t.toast,M==null?void 0:M.default,M==null?void 0:M[xe],d==null||(n=d.classNames)==null?void 0:n[xe]),"data-sonner-toast":``,"data-rich-colors":(ze=d.richColors)==null?S:ze,"data-styled":!(d.jsx||d.unstyled||f),"data-mounted":ie,"data-promise":!!d.promise,"data-swiped":de,"data-removed":ae,"data-visible":be,"data-y-position":Ae,"data-x-position":je,"data-index":v,"data-front":ye,"data-swiping":se,"data-dismissible":Se,"data-type":xe,"data-invert":Pe,"data-swipe-out":le,"data-swipe-direction":ne,"data-expanded":!!(b||ee&&ie),"data-testid":d.testId,style:{"--index":v,"--toasts-before":v,"--z-index":y.length-v,"--offset":`${ae?pe:Oe.current}px`,"--initial-height":ee?`auto`:`${me}px`,...w,...d.style},onDragEnd:()=>{ce(!1),te(null),ke.current=null},onPointerDown:e=>{e.button!==2&&(Fe||!Se||(_e.current=new Date,L(Oe.current),e.target.setPointerCapture(e.pointerId),e.target.tagName!==`BUTTON`&&(ce(!0),ke.current={x:e.clientX,y:e.clientY})))},onPointerUp:()=>{var e,t,n;if(le||!Se)return;ke.current=null;let r=Number(((e=ve.current)==null?void 0:e.style.getPropertyValue(`--swipe-amount-x`).replace(`px`,``))||0),i=Number(((t=ve.current)==null?void 0:t.style.getPropertyValue(`--swipe-amount-y`).replace(`px`,``))||0),a=new Date().getTime()-((n=_e.current)==null?void 0:n.getTime()),o=F===`x`?r:i,s=Math.abs(o)/a;if(Math.abs(o)>=45||s>.11){L(Oe.current),d.onDismiss==null||d.onDismiss.call(d,d),re(F===`x`?r>0?`right`:`left`:i>0?`down`:`up`),Ie(),ue(!0);return}else{var c,l;(c=ve.current)==null||c.style.setProperty(`--swipe-amount-x`,`0px`),(l=ve.current)==null||l.style.setProperty(`--swipe-amount-y`,`0px`)}fe(!1),ce(!1),te(null)},onPointerMove:t=>{var n,r,i;if(!ke.current||!Se||((n=window.getSelection())==null?void 0:n.toString().length)>0)return;let a=t.clientY-ke.current.y,o=t.clientX-ke.current.x;var s;let c=(s=e.swipeDirections)==null?ip(A):s;!F&&(Math.abs(o)>1||Math.abs(a)>1)&&te(Math.abs(o)>Math.abs(a)?`x`:`y`);let l={x:0,y:0},u=e=>1/(1.5+Math.abs(e)/20);if(F===`y`){if(c.includes(`top`)||c.includes(`bottom`))if(c.includes(`top`)&&a<0||c.includes(`bottom`)&&a>0)l.y=a;else{let e=a*u(a);l.y=Math.abs(e)<Math.abs(a)?e:a}}else if(F===`x`&&(c.includes(`left`)||c.includes(`right`)))if(c.includes(`left`)&&o<0||c.includes(`right`)&&o>0)l.x=o;else{let e=o*u(o);l.x=Math.abs(e)<Math.abs(o)?e:o}(Math.abs(l.x)>0||Math.abs(l.y)>0)&&fe(!0),(r=ve.current)==null||r.style.setProperty(`--swipe-amount-x`,`${l.x}px`),(i=ve.current)==null||i.style.setProperty(`--swipe-amount-y`,`${l.y}px`)}},Ee&&!d.jsx&&xe!==`loading`?h.createElement(`button`,{"aria-label":P,"data-disabled":Fe,"data-close-button":!0,onClick:Fe||!Se?()=>{}:()=>{Ie(),d.onDismiss==null||d.onDismiss.call(d,d)},className:rp(M==null?void 0:M.closeButton,d==null||(r=d.classNames)==null?void 0:r.closeButton)},(Be=N==null?void 0:N.close)==null?qf:Be):null,(xe||d.icon||d.promise)&&d.icon!==null&&((N==null?void 0:N[xe])!==null||d.icon)?h.createElement(`div`,{"data-icon":``,className:rp(M==null?void 0:M.icon,d==null||(i=d.classNames)==null?void 0:i.icon)},d.promise||d.type===`loading`&&!d.icon?d.icon||Le():null,d.type===`loading`?null:Re):null,h.createElement(`div`,{"data-content":``,className:rp(M==null?void 0:M.content,d==null||(a=d.classNames)==null?void 0:a.content)},h.createElement(`div`,{"data-title":``,className:rp(M==null?void 0:M.title,d==null||(o=d.classNames)==null?void 0:o.title)},d.jsx?d.jsx:typeof d.title==`function`?d.title():d.title),d.description?h.createElement(`div`,{"data-description":``,className:rp(O,we,M==null?void 0:M.description,d==null||(s=d.classNames)==null?void 0:s.description)},typeof d.description==`function`?d.description():d.description):null),h.isValidElement(d.cancel)?d.cancel:d.cancel&&tp(d.cancel)?h.createElement(`button`,{"data-button":!0,"data-cancel":!0,style:d.cancelButtonStyle||T,onClick:e=>{tp(d.cancel)&&Se&&(d.cancel.onClick==null||d.cancel.onClick.call(d.cancel,e),Ie())},className:rp(M==null?void 0:M.cancelButton,d==null||(c=d.classNames)==null?void 0:c.cancelButton)},d.cancel.label):null,h.isValidElement(d.action)?d.action:d.action&&tp(d.action)?h.createElement(`button`,{"data-button":!0,"data-action":!0,style:d.actionButtonStyle||E,onClick:e=>{tp(d.action)&&(d.action.onClick==null||d.action.onClick.call(d.action,e),!e.defaultPrevented&&Ie())},className:rp(M==null?void 0:M.actionButton,d==null||(l=d.classNames)==null?void 0:l.actionButton)},d.action.label):null)};function op(){if(typeof window>`u`||typeof document>`u`)return`ltr`;let e=document.documentElement.getAttribute(`dir`);return e===`auto`||!e?window.getComputedStyle(document.documentElement).direction:e}function sp(e,t){let n={};return[e,t].forEach((e,t)=>{let r=t===1,i=r?`--mobile-offset`:`--offset`,a=r?`16px`:`24px`;function o(e){[`top`,`right`,`bottom`,`left`].forEach(t=>{n[`${i}-${t}`]=typeof e==`number`?`${e}px`:e})}typeof e==`number`||typeof e==`string`?o(e):typeof e==`object`?[`top`,`right`,`bottom`,`left`].forEach(t=>{e[t]===void 0?n[`${i}-${t}`]=a:n[`${i}-${t}`]=typeof e[t]==`number`?`${e[t]}px`:e[t]}):o(a)}),n}const cp=h.forwardRef(function(e,t){let{id:n,invert:r,position:i=`bottom-right`,hotkey:a=[`altKey`,`KeyT`],expand:o,closeButton:s,className:c,offset:l,mobileOffset:u,theme:d=`light`,richColors:f,duration:p,style:m,visibleToasts:g=3,toastOptions:_,dir:v=op(),gap:y=14,icons:b,containerAriaLabel:x=`Notifications`}=e,[S,C]=h.useState([]),w=h.useMemo(()=>n?S.filter(e=>e.toasterId===n):S.filter(e=>!e.toasterId),[S,n]),T=h.useMemo(()=>Array.from(new Set([i].concat(w.filter(e=>e.position).map(e=>e.position)))),[w,i]),[E,D]=h.useState([]),[O,k]=h.useState(!1),[A,j]=h.useState(!1),[ee,M]=h.useState(d===`system`?typeof window<`u`&&window.matchMedia&&window.matchMedia(`(prefers-color-scheme: dark)`).matches?`dark`:`light`:d),N=h.useRef(null),P=a.join(`+`).replace(/Key/g,``).replace(/Digit/g,``),F=h.useRef(null),te=h.useRef(!1),ne=h.useCallback(e=>{C(t=>{var n;return(n=t.find(t=>t.id===e.id))!=null&&n.delete||Xf.dismiss(e.id),t.filter(({id:t})=>t!==e.id)})},[]);return h.useEffect(()=>Xf.subscribe(e=>{if(e.dismiss){requestAnimationFrame(()=>{C(t=>t.map(t=>t.id===e.id?{...t,delete:!0}:t))});return}setTimeout(()=>{Pt.flushSync(()=>{C(t=>{let n=t.findIndex(t=>t.id===e.id);return n===-1?[e,...t]:[...t.slice(0,n),{...t[n],...e},...t.slice(n+1)]})})})}),[S]),h.useEffect(()=>{if(d!==`system`){M(d);return}if(d===`system`&&(window.matchMedia&&window.matchMedia(`(prefers-color-scheme: dark)`).matches?M(`dark`):M(`light`)),typeof window>`u`)return;let e=window.matchMedia(`(prefers-color-scheme: dark)`);try{e.addEventListener(`change`,({matches:e})=>{M(e?`dark`:`light`)})}catch{e.addListener(({matches:e})=>{try{M(e?`dark`:`light`)}catch(e){console.error(e)}})}},[d]),h.useEffect(()=>{S.length<=1&&k(!1)},[S]),h.useEffect(()=>{let e=e=>{var t;if(a.every(t=>e[t]||e.code===t)){var n;k(!0),(n=N.current)==null||n.focus()}e.code===`Escape`&&(document.activeElement===N.current||(t=N.current)!=null&&t.contains(document.activeElement))&&k(!1)};return document.addEventListener(`keydown`,e),()=>document.removeEventListener(`keydown`,e)},[a]),h.useEffect(()=>{if(N.current)return()=>{F.current&&(F.current.focus({preventScroll:!0}),F.current=null,te.current=!1)}},[N.current]),h.createElement(`section`,{ref:t,"aria-label":`${x} ${P}`,tabIndex:-1,"aria-live":`polite`,"aria-relevant":`additions text`,"aria-atomic":`false`,suppressHydrationWarning:!0},T.map((t,n)=>{var i;let[a,d]=t.split(`-`);return w.length?h.createElement(`ol`,{key:t,dir:v===`auto`?op():v,tabIndex:-1,ref:N,className:c,"data-sonner-toaster":!0,"data-sonner-theme":ee,"data-y-position":a,"data-x-position":d,style:{"--front-toast-height":`${((i=E[0])==null?void 0:i.height)||0}px`,"--width":`356px`,"--gap":`${y}px`,...m,...sp(l,u)},onBlur:e=>{te.current&&!e.currentTarget.contains(e.relatedTarget)&&(te.current=!1,F.current&&(F.current.focus({preventScroll:!0}),F.current=null))},onFocus:e=>{e.target instanceof HTMLElement&&e.target.dataset.dismissible===`false`||te.current||(te.current=!0,F.current=e.relatedTarget)},onMouseEnter:()=>k(!0),onMouseMove:()=>k(!0),onMouseLeave:()=>{A||k(!1)},onDragEnd:()=>k(!1),onPointerDown:e=>{e.target instanceof HTMLElement&&e.target.dataset.dismissible===`false`||j(!0)},onPointerUp:()=>j(!1)},w.filter(e=>!e.position&&n===0||e.position===t).map((n,i)=>{var a,c;return h.createElement(ap,{key:n.id,icons:b,index:i,toast:n,defaultRichColors:f,duration:(a=_==null?void 0:_.duration)==null?p:a,className:_==null?void 0:_.className,descriptionClassName:_==null?void 0:_.descriptionClassName,invert:r,visibleToasts:g,closeButton:(c=_==null?void 0:_.closeButton)==null?s:c,interacting:A,position:t,style:_==null?void 0:_.style,unstyled:_==null?void 0:_.unstyled,classNames:_==null?void 0:_.classNames,cancelButtonStyle:_==null?void 0:_.cancelButtonStyle,actionButtonStyle:_==null?void 0:_.actionButtonStyle,closeButtonAriaLabel:_==null?void 0:_.closeButtonAriaLabel,removeToast:ne,toasts:w.filter(e=>e.position==n.position),heights:E.filter(e=>e.position==n.position),setHeights:D,expandByDefault:o,gap:y,expanded:O,swipeDirections:e.swipeDirections})})):null}))});let lp=function(e){return e.Success=`success`,e.Info=`info`,e.Warning=`warning`,e.Error=`error`,e.Loading=`loading`,e}({});const up=`univer-message-toaster`,dp=3e3,fp=new Set,pp=(0,z.jsx)(f.LoadingMultiIcon,{className:`univer-animate-spin univer-text-violet-500`});let mp=0;const hp={[lp.Success]:(0,z.jsx)(f.SuccessIcon,{className:`univer-text-green-500`}),[lp.Info]:(0,z.jsx)(f.InfoIcon,{className:`univer-text-sky-500 dark:!univer-text-sky-400`}),[lp.Warning]:(0,z.jsx)(f.WarningIcon,{className:`univer-text-amber-500`}),[lp.Error]:(0,z.jsx)(f.ErrorIcon,{className:`univer-text-red-500`}),[lp.Loading]:pp},gp={[lp.Success]:`[&_[data-icon]]:univer-text-green-500`,[lp.Info]:`[&_[data-icon]]:univer-text-sky-500`,[lp.Warning]:`[&_[data-icon]]:univer-text-amber-500`,[lp.Error]:`[&_[data-icon]]:univer-text-red-500`,[lp.Loading]:`[&_[data-icon]]:univer-text-violet-500`},_p=e=>{switch(e){case lp.Success:return ep.success;case lp.Warning:return ep.warning;case lp.Error:return ep.error;case lp.Loading:return ep.loading;case lp.Info:default:return ep.info}},vp=()=>{let e=`univer-message-${mp}`;return mp+=1,e},yp=({className:e,...t})=>(0,z.jsx)(cp,{id:up,position:`top-center`,visibleToasts:4,closeButton:!1,expand:!1,icons:{loading:pp},offset:{top:16},className:R(`[&_[data-sonner-toast]]:univer-bg-white/95 dark:[&_[data-sonner-toast]]:!univer-bg-gray-800/95 [&_[data-sonner-toast]]:univer-rounded-2xl [&_[data-sonner-toast]]:univer-border [&_[data-sonner-toast]]:univer-border-solid [&_[data-sonner-toast]]:univer-border-gray-200 [&_[data-sonner-toast]]:univer-shadow-[0_16px_40px_-20px_rgba(15,23,42,0.55)] [&_[data-sonner-toast]]:univer-backdrop-blur-sm dark:[&_[data-sonner-toast]]:!univer-border-gray-600`,e),toastOptions:{duration:dp,classNames:{toast:`
272
147
  univer-group univer-min-h-0 univer-min-w-[320px] univer-max-w-[520px] univer-px-3.5 univer-py-3
273
148
  univer-font-sans univer-transition-all univer-duration-300
274
149
  `,title:`
275
150
  univer-m-0 univer-font-sans univer-text-sm univer-font-medium univer-leading-5 univer-text-gray-700
276
151
  dark:!univer-text-gray-100
277
- `,content:"univer-gap-2.5",icon:"[&>svg]:univer-block [&>svg]:univer-size-4",success:Lr.success,info:Lr.info,warning:Lr.warning,error:Lr.error,loading:Lr.loading}},...t}),Uw=({content:e,duration:t,id:n,onClose:r,type:o="info"})=>{const i=n!=null?n:Ww(),a=Vw(o);let s=!1;const c=()=>{s||(s=!0,Hr.delete(i),r==null||r())};return a(e,{id:i,toasterId:qf,duration:t!=null?t:Xf,icon:o==="loading"?void 0:Hw[o],onDismiss:c,onAutoClose:c}),Hr.add(i),i},Gw=e=>{if(typeof e<"u"){Nn.dismiss(e),Hr.delete(e);return}Hr.forEach(t=>{Nn.dismiss(t)}),Hr.clear()};function Jf(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,Jo(e,t)}function Yw(e,t){return e.classList?!!t&&e.classList.contains(t):(" "+(e.className.baseVal||e.className)+" ").indexOf(" "+t+" ")!==-1}function Zw(e,t){e.classList?e.classList.add(t):Yw(e,t)||(typeof e.className=="string"?e.className=e.className+" "+t:e.setAttribute("class",(e.className&&e.className.baseVal||"")+" "+t))}function Yu(e,t){return e.replace(new RegExp("(^|\\s)"+t+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}function qw(e,t){e.classList?e.classList.remove(t):typeof e.className=="string"?e.className=Yu(e.className,t):e.setAttribute("class",Yu(e.className&&e.className.baseVal||"",t))}const Zu={disabled:!1},ev=y.createContext(null);var tv=function(t){return t.scrollTop},zr="unmounted",Hn="exited",Vn="entering",sr="entered",ja="exiting",vn=(function(e){Jf(t,e);function t(r,o){var i;i=e.call(this,r,o)||this;var a=o,s=a&&!a.isMounting?r.enter:r.appear,c;return i.appearStatus=null,r.in?s?(c=Hn,i.appearStatus=Vn):c=sr:r.unmountOnExit||r.mountOnEnter?c=zr:c=Hn,i.state={status:c},i.nextCallback=null,i}t.getDerivedStateFromProps=function(o,i){var a=o.in;return a&&i.status===zr?{status:Hn}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var i=null;if(o!==this.props){var a=this.state.status;this.props.in?a!==Vn&&a!==sr&&(i=Vn):(a===Vn||a===sr)&&(i=ja)}this.updateStatus(!1,i)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,i,a,s;return i=a=s=o,o!=null&&typeof o!="number"&&(i=o.exit,a=o.enter,s=o.appear!==void 0?o.appear:a),{exit:i,enter:a,appear:s}},n.updateStatus=function(o,i){if(o===void 0&&(o=!1),i!==null)if(this.cancelNextCallback(),i===Vn){if(this.props.unmountOnExit||this.props.mountOnEnter){var a=this.props.nodeRef?this.props.nodeRef.current:ut.findDOMNode(this);a&&tv(a)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===Hn&&this.setState({status:zr})},n.performEnter=function(o){var i=this,a=this.props.enter,s=this.context?this.context.isMounting:o,c=this.props.nodeRef?[s]:[ut.findDOMNode(this),s],l=c[0],f=c[1],u=this.getTimeouts(),m=s?u.appear:u.enter;if(!o&&!a||Zu.disabled){this.safeSetState({status:sr},function(){i.props.onEntered(l)});return}this.props.onEnter(l,f),this.safeSetState({status:Vn},function(){i.props.onEntering(l,f),i.onTransitionEnd(m,function(){i.safeSetState({status:sr},function(){i.props.onEntered(l,f)})})})},n.performExit=function(){var o=this,i=this.props.exit,a=this.getTimeouts(),s=this.props.nodeRef?void 0:ut.findDOMNode(this);if(!i||Zu.disabled){this.safeSetState({status:Hn},function(){o.props.onExited(s)});return}this.props.onExit(s),this.safeSetState({status:ja},function(){o.props.onExiting(s),o.onTransitionEnd(a.exit,function(){o.safeSetState({status:Hn},function(){o.props.onExited(s)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,i){i=this.setNextCallback(i),this.setState(o,i)},n.setNextCallback=function(o){var i=this,a=!0;return this.nextCallback=function(s){a&&(a=!1,i.nextCallback=null,o(s))},this.nextCallback.cancel=function(){a=!1},this.nextCallback},n.onTransitionEnd=function(o,i){this.setNextCallback(i);var a=this.props.nodeRef?this.props.nodeRef.current:ut.findDOMNode(this),s=o==null&&!this.props.addEndListener;if(!a||s){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[a,this.nextCallback],l=c[0],f=c[1];this.props.addEndListener(l,f)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===zr)return null;var i=this.props,a=i.children;i.in,i.mountOnEnter,i.unmountOnExit,i.appear,i.enter,i.exit,i.timeout,i.addEndListener,i.onEnter,i.onEntering,i.onEntered,i.onExit,i.onExiting,i.onExited,i.nodeRef;var s=bs(i,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return y.createElement(ev.Provider,{value:null},typeof a=="function"?a(o,s):y.cloneElement(y.Children.only(a),s))},t})(y.Component);vn.contextType=ev;vn.propTypes={};function ar(){}vn.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:ar,onEntering:ar,onEntered:ar,onExit:ar,onExiting:ar,onExited:ar};vn.UNMOUNTED=zr;vn.EXITED=Hn;vn.ENTERING=Vn;vn.ENTERED=sr;vn.EXITING=ja;var Xw=function(t,n){return t&&n&&n.split(" ").forEach(function(r){return Zw(t,r)})},ia=function(t,n){return t&&n&&n.split(" ").forEach(function(r){return qw(t,r)})},Is=(function(e){Jf(t,e);function t(){for(var r,o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];return r=e.call.apply(e,[this].concat(i))||this,r.appliedClasses={appear:{},enter:{},exit:{}},r.onEnter=function(s,c){var l=r.resolveArguments(s,c),f=l[0],u=l[1];r.removeClasses(f,"exit"),r.addClass(f,u?"appear":"enter","base"),r.props.onEnter&&r.props.onEnter(s,c)},r.onEntering=function(s,c){var l=r.resolveArguments(s,c),f=l[0],u=l[1],m=u?"appear":"enter";r.addClass(f,m,"active"),r.props.onEntering&&r.props.onEntering(s,c)},r.onEntered=function(s,c){var l=r.resolveArguments(s,c),f=l[0],u=l[1],m=u?"appear":"enter";r.removeClasses(f,m),r.addClass(f,m,"done"),r.props.onEntered&&r.props.onEntered(s,c)},r.onExit=function(s){var c=r.resolveArguments(s),l=c[0];r.removeClasses(l,"appear"),r.removeClasses(l,"enter"),r.addClass(l,"exit","base"),r.props.onExit&&r.props.onExit(s)},r.onExiting=function(s){var c=r.resolveArguments(s),l=c[0];r.addClass(l,"exit","active"),r.props.onExiting&&r.props.onExiting(s)},r.onExited=function(s){var c=r.resolveArguments(s),l=c[0];r.removeClasses(l,"exit"),r.addClass(l,"exit","done"),r.props.onExited&&r.props.onExited(s)},r.resolveArguments=function(s,c){return r.props.nodeRef?[r.props.nodeRef.current,s]:[s,c]},r.getClassNames=function(s){var c=r.props.classNames,l=typeof c=="string",f=l&&c?c+"-":"",u=l?""+f+s:c[s],m=l?u+"-active":c[s+"Active"],p=l?u+"-done":c[s+"Done"];return{baseClassName:u,activeClassName:m,doneClassName:p}},r}var n=t.prototype;return n.addClass=function(o,i,a){var s=this.getClassNames(i)[a+"ClassName"],c=this.getClassNames("enter"),l=c.doneClassName;i==="appear"&&a==="done"&&l&&(s+=" "+l),a==="active"&&o&&tv(o),s&&(this.appliedClasses[i][a]=s,Xw(o,s))},n.removeClasses=function(o,i){var a=this.appliedClasses[i],s=a.base,c=a.active,l=a.done;this.appliedClasses[i]={},s&&ia(o,s),c&&ia(o,c),l&&ia(o,l)},n.render=function(){var o=this.props;o.classNames;var i=bs(o,["classNames"]);return y.createElement(vn,Me({},i,{onEnter:this.onEnter,onEntered:this.onEntered,onEntering:this.onEntering,onExit:this.onExit,onExiting:this.onExiting,onExited:this.onExited}))},t})(y.Component);Is.defaultProps={classNames:""};Is.propTypes={};const No=2;function Qw(e){const{children:t,visible:n=!1,offset:r=[0,0],overflowVisible:o=!1,placementY:i="below"}=e,a=y.useRef(null),[s,c]=y.useState(r),{mountContainer:l}=y.useContext(Zt),f=()=>{const m=a.current;if(!m)return null;const[p,g]=r,{clientWidth:b,clientHeight:h}=m,{innerWidth:x,innerHeight:E}=window,w=Math.max(0,x-b-No),C=Math.max(0,E-h-No),S=Math.min(Math.max(p,0),w),R=i==="above"?g-h:g,L=Math.min(Math.max(R,0),C);return[S,L]};y.useEffect(()=>{if(!n){c([-9999,-9999]);return}const m=f();m&&c(m)},[r,i,n]),y.useEffect(()=>{if(!n)return;const m=()=>{const p=f();p&&c(p)};return window.addEventListener("resize",m),()=>{window.removeEventListener("resize",m)}},[r,i,n]);function u(m){m.preventDefault()}return ut.createPortal(v.jsx(Is,{in:n,nodeRef:a,timeout:500,classNames:{enter:"univer-popup-enter",enterActive:"univer-popup-enter-active",enterDone:"univer-popup-enter-done",exitActive:"univer-popup-exit",exitDone:"univer-popup-exit-active"},children:v.jsx("section",{ref:a,className:"univer-popup",style:{left:s[0]+No,top:s[1]+No,overflow:o?"visible":void 0},onContextMenu:u,children:t})}),l)}function Jw(e){const{children:t,className:n,style:r,value:o,disabled:i=!1,direction:a="horizontal",onChange:s}=e,c=l=>{s(l)};return v.jsx("div",{className:W("univer-flex univer-gap-2",{"univer-flex-col":a==="vertical"},n),style:r,children:y.Children.map(t,(l,f)=>y.isValidElement(l)?y.cloneElement(l,{key:f,children:l.props.children,value:l.props.value,checked:o===l.props.value,disabled:i!=null?i:l.props.disabled,onChange:c}):l)})}function eC(e){const{children:t,checked:n,value:r,disabled:o=!1,onChange:i}=e,a=y.useRef(null);function s(c){var l;if(c.stopPropagation(),!(!i||o))if(typeof r<"u")i&&i(r);else{const f=(l=a==null?void 0:a.current)==null?void 0:l.checked;i&&i(f)}}return v.jsxs("label",{"data-u-comp":"radio",className:W("univer-box-border univer-inline-flex univer-items-center univer-gap-2 univer-text-sm",{"univer-cursor-pointer univer-text-gray-900 dark:!univer-text-white":!o,"univer-text-gray-400":o}),children:[v.jsxs("span",{className:"univer-relative univer-block",children:[v.jsx("input",{ref:a,className:"univer-absolute univer-size-0 univer-opacity-0",type:"radio",checked:n,disabled:o,onChange:s}),v.jsx("span",{className:W("univer-relative univer-box-border univer-flex univer-size-4 univer-items-center univer-justify-center univer-overflow-hidden univer-rounded-full univer-border univer-border-solid univer-transition-colors",{"univer-opacity-50":o,"univer-border-primary-600 univer-bg-primary-600 dark:!univer-bg-primary-600":n,"univer-border-gray-300 univer-bg-gray-50 dark:!univer-border-gray-500 dark:!univer-bg-gray-600":!n}),children:n&&v.jsx("span",{className:"univer-absolute univer-left-1/2 univer-top-1/2 univer-block univer-size-2 -univer-translate-x-1/2 -univer-translate-y-1/2 univer-rounded-full univer-bg-white"})})]}),v.jsx("span",{children:t})]})}function tC(e){const{value:t,options:n=[],hideCheckMark:r=!1,onChange:o,multiple:i,className:a,optionClassName:s}=e,c=Array.isArray(t)?t:[t];function l(f){const u=c.indexOf(f);i?u>-1?o(c.filter(m=>m===f)):o([...c,f]):u>-1?o(void 0):o(f)}return v.jsx("ul",{className:W("univer-m-0 univer-grid univer-max-h-80 univer-list-none univer-gap-1 univer-overflow-y-auto univer-rounded univer-p-1.5",ct,kn,a),children:n.map((f,u)=>{const m=c.indexOf(f.value)>-1;return v.jsx("li",{children:v.jsxs("a",{className:W("univer-relative univer-block univer-cursor-pointer univer-select-none univer-rounded univer-py-1.5 univer-pl-8 univer-pr-2 univer-text-sm univer-text-gray-900 univer-transition-colors hover:univer-bg-gray-100 dark:!univer-text-white dark:hover:!univer-bg-gray-600",s,{"univer-bg-gray-200 dark:!univer-bg-gray-500":m}),onClick:()=>l(f.value),children:[!r&&m&&v.jsx(br,{className:"univer-absolute univer-left-0 univer-top-1/2 -univer-translate-y-1/2 univer-pl-2 univer-text-primary-600"}),v.jsx("span",{style:{color:f.color},children:f.label})]})},u)})})}const nv=W("univer-box-border univer-inline-flex univer-h-8 univer-min-w-36 univer-items-center univer-justify-between univer-gap-2 univer-rounded-lg univer-bg-white univer-px-2.5 univer-transition-colors univer-duration-200 dark:!univer-bg-gray-700 dark:!univer-text-white",ct);function nC(e){const{className:t,value:n,disabled:r=!1,options:o=[],borderless:i=!1,onChange:a}=e,[s,c]=y.useState(!1);function l(m){c(m)}const f=y.useMemo(()=>{const m=[];for(const p of o)p.options?(p.options.forEach(g=>{m.push({label:g.label,value:g.value,disabled:g.disabled})}),m.push({type:"separator"})):m.push({label:p.label,value:p.value,disabled:p.disabled});return[{type:"radio",value:n,hideIndicator:!0,options:m,onSelect:p=>{a(p)}}]},[o]),u=y.useMemo(()=>{let m=null;for(const p of o)if(p.options){for(const g of p.options)if(g.value===n){m=g.label;break}}else if(p.value===n){m=p.label;break}return m||n},[o,n]);return v.jsx(hs,{className:"max-h univer-w-[--radix-popper-anchor-width] univer-min-w-36",align:"start",open:s,items:f,disabled:r,onOpenChange:l,children:v.jsxs("div",{"data-u-comp":"select",className:W(nv,{"univer-border-primary-600 univer-outline-none univer-ring-2 univer-ring-primary-50 dark:!univer-ring-primary-900":s&&!i,"univer-border-transparent univer-bg-transparent hover:univer-border-transparent":i,"univer-cursor-not-allowed":r,"hover:univer-border-primary-600":!r&&!i,"univer-cursor-pointer":!r&&!s},t),children:[v.jsx("div",{className:"univer-flex-1 univer-truncate univer-text-sm univer-text-gray-500 dark:!univer-text-white",children:u}),v.jsx($a,{className:"univer-flex-shrink-0 dark:!univer-text-white"})]})})}function rC(e){const{className:t,value:n=[],disabled:r=!1,options:o=[],borderless:i=!1,onChange:a}=e,[s,c]=y.useState(!1);function l(p){c(p)}const f=y.useMemo(()=>o.map(p=>({type:"checkbox",value:p.value,label:p.label,disabled:p.disabled,checked:n.includes(p.value),onSelect:g=>{const b=n.includes(g)?n.filter(h=>h!==g):[...n,g];a(b)}})),[o]);function u(p){const g=n.filter(b=>b!==p);a(g)}const m=y.useMemo(()=>o.filter(p=>n.includes(p.value)).map((p,g)=>v.jsx(wl,{className:"univer-max-w-32",closable:!0,onClose:()=>u(p.value),children:p.label},g)),[o,n]);return v.jsx(hs,{className:"univer-w-[--radix-popper-anchor-width] univer-min-w-36",align:"start",open:s,items:f,disabled:r,onOpenChange:l,children:v.jsxs("div",{"data-u-comp":"multiple-select",className:W(nv,{"univer-border-primary-600 univer-outline-none univer-ring-2 univer-ring-primary-50 dark:!univer-ring-primary-900":s&&!i,"univer-border-transparent univer-bg-transparent hover:univer-border-transparent":i,"univer-cursor-not-allowed":r,"hover:univer-border-primary-600":!r&&!i,"univer-cursor-pointer":!r&&!s},t),children:[v.jsx("div",{className:"univer-box-border univer-flex univer-w-[calc(100%-16px)] univer-gap-2 univer-pr-2",children:m}),v.jsx($a,{className:"univer-flex-shrink-0 dark:!univer-text-white"})]})})}var oC=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],iC=oC.reduce((e,t)=>{const n=El(`Primitive.${t}`),r=d.forwardRef((o,i)=>{const{asChild:a,...s}=o,c=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),v.jsx(c,{...s,ref:i})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{}),aC="Separator",qu="horizontal",sC=["horizontal","vertical"],rv=d.forwardRef((e,t)=>{const{decorative:n,orientation:r=qu,...o}=e,i=uC(r)?r:qu,s=n?{role:"none"}:{"aria-orientation":i==="vertical"?i:void 0,role:"separator"};return v.jsx(iC.div,{"data-orientation":i,...s,...o,ref:t})});rv.displayName=aC;function uC(e){return sC.includes(e)}var lC=rv;function cC({className:e,orientation:t="horizontal",decorative:n=!0,...r}){return v.jsx(lC,{"data-u-comp":"separator","data-slot":"separator-root",decorative:n,orientation:t,className:W(`
278
- univer-shrink-0 univer-bg-gray-200
279
- data-[orientation=horizontal]:univer-h-px
280
- data-[orientation=vertical]:univer-h-full
281
- data-[orientation=horizontal]:univer-w-full
282
- data-[orientation=vertical]:univer-w-px
283
- dark:!univer-bg-gray-600
284
- `,e),...r})}const dC=e=>{const{defaultChecked:t=!1,onChange:n}=e,[r,o]=y.useState(t),i=()=>{o(!r),n==null||n(!r)};return y.useEffect(()=>{o(t)},[t]),v.jsx("div",{className:"univer-h-4",children:v.jsxs("label",{className:"univer-relative univer-inline-block univer-h-4 univer-w-7",children:[v.jsx("input",{className:"univer-size-0 univer-opacity-0",type:"checkbox",checked:r,onChange:i}),v.jsx("span",{className:W("univer-absolute univer-inset-0 univer-cursor-pointer univer-rounded-2xl univer-transition-colors univer-duration-200",{"univer-bg-primary-600":r,"univer-bg-gray-200 dark:!univer-bg-gray-600":!r}),children:v.jsx("span",{className:W("univer-absolute univer-bottom-0.5 univer-left-0.5 univer-size-3 univer-rounded-full univer-bg-white univer-transition-transform univer-duration-200",{"univer-translate-x-3":r})})})]})})},fC=y.forwardRef((e,t)=>{const n=y.useRef(null),r=y.useRef({width:0,height:0}),{className:o,onResize:i,onValueChange:a,...s}=e;y.useImperativeHandle(t,()=>n.current,[]),y.useLayoutEffect(()=>{const l=n.current;if(l&&i){const f=new ResizeObserver(u=>{const{width:m,height:p}=u[0].target.getBoundingClientRect();m===0||p===0||(r.current.width!==m||r.current.height!==p)&&(r.current={width:m,height:p},i(m,p))});return f.observe(l),()=>{f.unobserve(l),f.disconnect()}}},[i]);function c(l){const f=l.target.value;a==null||a(f)}return v.jsx("textarea",{ref:n,"data-u-comp":"textarea","data-slot":"textarea",className:W(`
285
- univer-box-border univer-flex univer-w-full univer-resize univer-rounded-md univer-bg-transparent
286
- univer-p-2 univer-text-base univer-text-gray-900 univer-outline-none
287
- univer-transition-[color,box-shadow]
288
- placeholder:univer-text-gray-200
289
- disabled:univer-cursor-not-allowed disabled:univer-opacity-50
290
- dark:!univer-text-white
291
- `,ct,kn,o),onChange:c,...s})});function vC({visibleToasts:e,...t}){return v.jsx(Yf,{className:"dark:![&_[data-description]]:univer-text-gray-200 [&_[data-description]]:univer-text-sm [&_[data-description]]:univer-text-gray-600 [&_[data-icon]>svg]:univer-relative [&_[data-icon]>svg]:univer-top-1 [&_[data-icon]]:univer-self-baseline [&_[data-sonner-toast]]:univer-shadow-md [&_[data-title]]:univer-text-sm [&_[data-title]]:univer-text-gray-900",toastOptions:{classNames:{content:"univer-leading-normal",success:"[&_[data-icon]]:univer-text-green-500",info:"[&_[data-icon]]:univer-text-primary-600",error:"[&_[data-icon]]:univer-text-red-500",warning:"[&_[data-icon]]:univer-text-yellow-500"}},visibleToasts:e!=null?e:5,...t})}function mC(e){const{data:t,itemKey:n,children:r,height:o,itemHeight:i,overscan:a=2,className:s,style:c}=e,[l,f]=y.useState(0);if(!o||!i||i<=0)return v.jsx("div",{className:s,style:c,children:t.map((x,E)=>{const w=typeof n=="function"?n(x):x[n];return v.jsx("div",{children:r(x,E)},w)})});const u=Math.max(0,Math.floor(l/i)-a),m=Math.ceil(o/i)+a*2,p=Math.min(t.length,u+m),g=u*i,b=t.length*i,h=t.slice(u,p);return v.jsx("div",{className:s,style:{...c,height:o,overflowY:"auto"},onScroll:x=>f(x.currentTarget.scrollTop),children:v.jsx("div",{style:{height:b,position:"relative"},children:v.jsx("div",{style:{transform:`translateY(${g}px)`},children:h.map((x,E)=>{const w=typeof n=="function"?n(x):x[n];return v.jsx("div",{children:r(x,u+E)},w)})})})})}const ov=(e,t)=>{const n=[],r=o=>{var i;if(n.push(o.key),t===o.key||(i=o.children)!=null&&i.length&&o.children.some(r))return!0;n.pop()};return e.some(r),n},iv=(e,t)=>{const n=t!=null?t:new Map;let r=e;return{findNodePathFromTreeWithCache:o=>{const i=n.get(o);if(i)return i;const a=ov(r,o);return a.map((c,l,f)=>{const u=[];for(let m=0;m<=l;m++)u.push(f[m]);return u}).reverse().forEach(c=>{const l=c[c.length-1];n.set(l,c)}),a},reset:o=>{n.clear(),o&&(r=o)}}},ri=(e,t)=>t.length?t.reduce((n,r)=>{const o=n.find(i=>i.key===r);return(o==null?void 0:o.children)||[]},e):e,pC=(e,t)=>{const n=t.slice(0),r=n.pop();return ri(e,n).find(i=>i.key===r)},hC=(e,t,n)=>{const r=new Set(t),o=n[n.length-1],i=ri(e,n);if(r.has(o)){if(i.length){const s=c=>{r.delete(c.key),c.children&&c.children.forEach(l=>s(l))};i.forEach(s)}n.map((s,c,l)=>{const f=[];for(let u=0;u<=c;u++)f.push(l[u]);return f}).reverse().some(s=>{const c=ri(e,s),l=s[s.length-1];if(c.every(f=>!r.has(f.key)))r.delete(l);else return!0;return!1})}else{const a=s=>{r.add(s.key),s.children&&s.children.forEach(c=>a(c))};n.forEach(s=>r.add(s)),i.length&&i.forEach(a)}return[...r]},gC=(e,t)=>{const n=t.children||[],r=o=>{var i;return(i=o.children)!=null&&i.length?!!o.children.every(r):e.has(o.key)};return n.length?n.some(o=>!r(o)):!1},bC=(e,t)=>{const n=[],r=iv(e);return t.forEach(o=>{var s;const i=r.findNodePathFromTreeWithCache(o),a=pC(e,i);a&&((s=a.children)!=null&&s.length||n.push(a))}),n};var av=(e=>(e[e.ONLY_LEAF_NODE=0]="ONLY_LEAF_NODE",e[e.ALL=1]="ALL",e))(av||{});function sv(e,t,n=1){const r=[];return e.forEach(o=>{r.push({...o,level:n}),o.children&&t.has(o.key)&&r.push(...sv(o.children,t,n+1))}),r}function yC(e){const{data:t=[],defaultCache:n,style:r,defaultExpandAll:o=!1,selectionMode:i=1,valueGroup:a=[],onChange:s,onExpend:c,height:l=200,itemHeight:f=32,attachRender:u}=e,[m,p]=y.useState({}),g=y.useMemo(()=>new Set,[]),b=y.useMemo(()=>iv(t,n),[t,n]),h=y.useMemo(()=>{const C=new Set;return a.forEach(S=>{b.findNodePathFromTreeWithCache(S).forEach(L=>C.add(L))}),C},[a,b]);y.useEffect(()=>{function C(S){var R;g.add(S.key),(R=S.children)==null||R.forEach(C)}o&&t.forEach(C),p({})},[o,t]);const x=y.useMemo(()=>sv(t,g),[t,m,g]);function E(C){var S;(S=C.children)!=null&&S.length&&(g.has(C.key)?g.delete(C.key):g.add(C.key),p({})),!(i===0&&C.children)&&(c==null||c(C.key))}function w(C){const{title:S,key:R,level:L=0}=C,D=e.treeNodeClassName,H=g.has(R),k=h.has(R),T=gC(h,C);return v.jsx("div",{className:W("univer-relative univer-text-[13px]",D),style:{paddingLeft:`${L*20}px`},children:v.jsxs("div",{className:"univer-relative univer-my-1 univer-flex univer-w-full univer-items-center",children:[C.children&&C.children.length>0&&v.jsx("span",{className:W("univer-absolute univer-left-[-16px] univer-top-1/2 univer-flex univer--translate-y-1/2 univer-items-center univer-justify-center univer-text-[8px]",{"univer-rotate-[-90deg]":!H}),onClick:F=>{F.stopPropagation(),E(C)},children:v.jsx(rl,{})}),v.jsx(Nl,{checked:k&&!T,indeterminate:k&&T,onChange:()=>{s==null||s(C)}}),v.jsx("div",{className:`
152
+ `,content:`univer-gap-2.5`,icon:`[&>svg]:univer-block [&>svg]:univer-size-4`,success:gp[lp.Success],info:gp[lp.Info],warning:gp[lp.Warning],error:gp[lp.Error],loading:gp[lp.Loading]}},...t}),bp=({content:e,duration:t,id:n,onClose:r,type:i=lp.Info})=>{let a=n==null?vp():n,o=_p(i),s=!1,c=()=>{s||(s=!0,fp.delete(a),r==null||r())};return o(e,{id:a,toasterId:up,duration:t==null?dp:t,icon:i===lp.Loading?void 0:hp[i],onDismiss:c,onAutoClose:c}),fp.add(a),a},xp=e=>{if(e!==void 0){ep.dismiss(e),fp.delete(e);return}fp.forEach(e=>{ep.dismiss(e)}),fp.clear()};var Sp=s(((e,t)=>{t.exports=`SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED`})),Cp=s(((e,t)=>{var n=Sp();function r(){}function i(){}i.resetWarningCache=r,t.exports=function(){function e(e,t,r,i,a,o){if(o!==n){var s=Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name=`Invariant Violation`,s}}e.isRequired=e;function t(){return e}var a={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:i,resetWarningCache:r};return a.PropTypes=a,a}})),wp=s(((e,t)=>{t.exports=Cp()()})),Tp=s(((e,t)=>{function n(e){return e&&e.__esModule?e:{default:e}}t.exports=n,t.exports.__esModule=!0,t.exports.default=t.exports})),Ep=s(((e,t)=>{e.__esModule=!0,e.default=n;function n(e,t){return e.classList?!!t&&e.classList.contains(t):(` `+(e.className.baseVal||e.className)+` `).indexOf(` `+t+` `)!==-1}t.exports=e.default})),Dp=s(((e,t)=>{var n=Tp();e.__esModule=!0,e.default=i;var r=n(Ep());function i(e,t){e.classList?e.classList.add(t):(0,r.default)(e,t)||(typeof e.className==`string`?e.className=e.className+` `+t:e.setAttribute(`class`,(e.className&&e.className.baseVal||``)+` `+t))}t.exports=e.default})),Op=s(((e,t)=>{e.__esModule=!0,e.default=r;function n(e,t){return e.replace(RegExp(`(^|\\s)`+t+`(?:\\s|$)`,`g`),`$1`).replace(/\s+/g,` `).replace(/^\s*|\s*$/g,``)}function r(e,t){e.classList?e.classList.remove(t):typeof e.className==`string`?e.className=n(e.className,t):e.setAttribute(`class`,n(e.className&&e.className.baseVal||``,t))}t.exports=e.default})),kp=s(((e,t)=>{e.__esModule=!0,e.default=void 0,e.default={disabled:!1},t.exports=e.default})),Ap=s((e=>{e.__esModule=!0,e.classNamesShape=e.timeoutsShape=void 0,t(wp());function t(e){return e&&e.__esModule?e:{default:e}}e.timeoutsShape=null,e.classNamesShape=null})),jp=s(((e,t)=>{e.__esModule=!0,e.default=void 0;var n=r(m());function r(e){return e&&e.__esModule?e:{default:e}}e.default=n.default.createContext(null),t.exports=e.default})),Mp=s((e=>{e.__esModule=!0,e.forceReflow=void 0,e.forceReflow=function(e){return e.scrollTop}})),Np=s((e=>{e.__esModule=!0,e.default=e.EXITING=e.ENTERED=e.ENTERING=e.EXITED=e.UNMOUNTED=void 0,o(wp());var t=o(m()),n=o(Nt()),r=o(kp());Ap();var i=o(jp()),a=Mp();function o(e){return e&&e.__esModule?e:{default:e}}function s(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,a;for(a=0;a<r.length;a++)i=r[a],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}function c(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}var l=`unmounted`;e.UNMOUNTED=l;var u=`exited`;e.EXITED=u;var d=`entering`;e.ENTERING=d;var f=`entered`;e.ENTERED=f;var p=`exiting`;e.EXITING=p;var h=function(e){c(o,e);function o(t,n){var r=e.call(this,t,n)||this,i=n,a=i&&!i.isMounting?t.enter:t.appear,o;return r.appearStatus=null,t.in?a?(o=u,r.appearStatus=d):o=f:o=t.unmountOnExit||t.mountOnEnter?l:u,r.state={status:o},r.nextCallback=null,r}o.getDerivedStateFromProps=function(e,t){return e.in&&t.status===l?{status:u}:null};var m=o.prototype;return m.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},m.componentDidUpdate=function(e){var t=null;if(e!==this.props){var n=this.state.status;this.props.in?n!==d&&n!==f&&(t=d):(n===d||n===f)&&(t=p)}this.updateStatus(!1,t)},m.componentWillUnmount=function(){this.cancelNextCallback()},m.getTimeouts=function(){var e=this.props.timeout,t=n=r=e,n,r;return e!=null&&typeof e!=`number`&&(t=e.exit,n=e.enter,r=e.appear===void 0?n:e.appear),{exit:t,enter:n,appear:r}},m.updateStatus=function(e,t){if(e===void 0&&(e=!1),t!==null)if(this.cancelNextCallback(),t===d){if(this.props.unmountOnExit||this.props.mountOnEnter){var r=this.props.nodeRef?this.props.nodeRef.current:n.default.findDOMNode(this);r&&(0,a.forceReflow)(r)}this.performEnter(e)}else this.performExit();else this.props.unmountOnExit&&this.state.status===u&&this.setState({status:l})},m.performEnter=function(e){var t=this,i=this.props.enter,a=this.context?this.context.isMounting:e,o=this.props.nodeRef?[a]:[n.default.findDOMNode(this),a],s=o[0],c=o[1],l=this.getTimeouts(),u=a?l.appear:l.enter;if(!e&&!i||r.default.disabled){this.safeSetState({status:f},function(){t.props.onEntered(s)});return}this.props.onEnter(s,c),this.safeSetState({status:d},function(){t.props.onEntering(s,c),t.onTransitionEnd(u,function(){t.safeSetState({status:f},function(){t.props.onEntered(s,c)})})})},m.performExit=function(){var e=this,t=this.props.exit,i=this.getTimeouts(),a=this.props.nodeRef?void 0:n.default.findDOMNode(this);if(!t||r.default.disabled){this.safeSetState({status:u},function(){e.props.onExited(a)});return}this.props.onExit(a),this.safeSetState({status:p},function(){e.props.onExiting(a),e.onTransitionEnd(i.exit,function(){e.safeSetState({status:u},function(){e.props.onExited(a)})})})},m.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},m.safeSetState=function(e,t){t=this.setNextCallback(t),this.setState(e,t)},m.setNextCallback=function(e){var t=this,n=!0;return this.nextCallback=function(r){n&&(n=!1,t.nextCallback=null,e(r))},this.nextCallback.cancel=function(){n=!1},this.nextCallback},m.onTransitionEnd=function(e,t){this.setNextCallback(t);var r=this.props.nodeRef?this.props.nodeRef.current:n.default.findDOMNode(this),i=e==null&&!this.props.addEndListener;if(!r||i){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var a=this.props.nodeRef?[this.nextCallback]:[r,this.nextCallback],o=a[0],s=a[1];this.props.addEndListener(o,s)}e!=null&&setTimeout(this.nextCallback,e)},m.render=function(){var e=this.state.status;if(e===l)return null;var n=this.props,r=n.children;n.in,n.mountOnEnter,n.unmountOnExit,n.appear,n.enter,n.exit,n.timeout,n.addEndListener,n.onEnter,n.onEntering,n.onEntered,n.onExit,n.onExiting,n.onExited,n.nodeRef;var a=s(n,[`children`,`in`,`mountOnEnter`,`unmountOnExit`,`appear`,`enter`,`exit`,`timeout`,`addEndListener`,`onEnter`,`onEntering`,`onEntered`,`onExit`,`onExiting`,`onExited`,`nodeRef`]);return t.default.createElement(i.default.Provider,{value:null},typeof r==`function`?r(e,a):t.default.cloneElement(t.default.Children.only(r),a))},o}(t.default.Component);h.contextType=i.default,h.propTypes={};function g(){}h.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:g,onEntering:g,onEntered:g,onExit:g,onExiting:g,onExited:g},h.UNMOUNTED=l,h.EXITED=u,h.ENTERING=d,h.ENTERED=f,h.EXITING=p,e.default=h})),Pp=s(((e,t)=>{e.__esModule=!0,e.default=void 0,s(wp());var n=s(Dp()),r=s(Op()),i=s(m()),a=s(Np());Ap();var o=Mp();function s(e){return e&&e.__esModule?e:{default:e}}function c(){return c=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},c.apply(this,arguments)}function l(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,a;for(a=0;a<r.length;a++)i=r[a],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}function u(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}var d=function(e,t){return e&&t&&t.split(` `).forEach(function(t){return(0,n.default)(e,t)})},f=function(e,t){return e&&t&&t.split(` `).forEach(function(t){return(0,r.default)(e,t)})},p=function(e){u(t,e);function t(){for(var t,n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];return t=e.call.apply(e,[this].concat(r))||this,t.appliedClasses={appear:{},enter:{},exit:{}},t.onEnter=function(e,n){var r=t.resolveArguments(e,n),i=r[0],a=r[1];t.removeClasses(i,`exit`),t.addClass(i,a?`appear`:`enter`,`base`),t.props.onEnter&&t.props.onEnter(e,n)},t.onEntering=function(e,n){var r=t.resolveArguments(e,n),i=r[0],a=r[1]?`appear`:`enter`;t.addClass(i,a,`active`),t.props.onEntering&&t.props.onEntering(e,n)},t.onEntered=function(e,n){var r=t.resolveArguments(e,n),i=r[0],a=r[1]?`appear`:`enter`;t.removeClasses(i,a),t.addClass(i,a,`done`),t.props.onEntered&&t.props.onEntered(e,n)},t.onExit=function(e){var n=t.resolveArguments(e)[0];t.removeClasses(n,`appear`),t.removeClasses(n,`enter`),t.addClass(n,`exit`,`base`),t.props.onExit&&t.props.onExit(e)},t.onExiting=function(e){var n=t.resolveArguments(e)[0];t.addClass(n,`exit`,`active`),t.props.onExiting&&t.props.onExiting(e)},t.onExited=function(e){var n=t.resolveArguments(e)[0];t.removeClasses(n,`exit`),t.addClass(n,`exit`,`done`),t.props.onExited&&t.props.onExited(e)},t.resolveArguments=function(e,n){return t.props.nodeRef?[t.props.nodeRef.current,e]:[e,n]},t.getClassNames=function(e){var n=t.props.classNames,r=typeof n==`string`,i=r&&n?n+`-`:``,a=r?``+i+e:n[e];return{baseClassName:a,activeClassName:r?a+`-active`:n[e+`Active`],doneClassName:r?a+`-done`:n[e+`Done`]}},t}var n=t.prototype;return n.addClass=function(e,t,n){var r=this.getClassNames(t)[n+`ClassName`],i=this.getClassNames(`enter`).doneClassName;t===`appear`&&n===`done`&&i&&(r+=` `+i),n===`active`&&e&&(0,o.forceReflow)(e),r&&(this.appliedClasses[t][n]=r,d(e,r))},n.removeClasses=function(e,t){var n=this.appliedClasses[t],r=n.base,i=n.active,a=n.done;this.appliedClasses[t]={},r&&f(e,r),i&&f(e,i),a&&f(e,a)},n.render=function(){var e=this.props;e.classNames;var t=l(e,[`classNames`]);return i.default.createElement(a.default,c({},t,{onEnter:this.onEnter,onEntered:this.onEntered,onEntering:this.onEntering,onExit:this.onExit,onExiting:this.onExiting,onExited:this.onExited}))},t}(i.default.Component);p.defaultProps={classNames:``},p.propTypes={},e.default=p,t.exports=e.default})),Fp=s((e=>{e.__esModule=!0,e.getChildMapping=n,e.mergeChildMappings=r,e.getInitialChildMapping=a,e.getNextChildMapping=o;var t=m();function n(e,n){var r=function(e){return n&&(0,t.isValidElement)(e)?n(e):e},i=Object.create(null);return e&&t.Children.map(e,function(e){return e}).forEach(function(e){i[e.key]=r(e)}),i}function r(e,t){e=e||{},t=t||{};function n(n){return n in t?t[n]:e[n]}var r=Object.create(null),i=[];for(var a in e)a in t?i.length&&(r[a]=i,i=[]):i.push(a);var o,s={};for(var c in t){if(r[c])for(o=0;o<r[c].length;o++){var l=r[c][o];s[r[c][o]]=n(l)}s[c]=n(c)}for(o=0;o<i.length;o++)s[i[o]]=n(i[o]);return s}function i(e,t,n){return n[t]==null?e.props[t]:n[t]}function a(e,r){return n(e.children,function(n){return(0,t.cloneElement)(n,{onExited:r.bind(null,n),in:!0,appear:i(n,`appear`,e),enter:i(n,`enter`,e),exit:i(n,`exit`,e)})})}function o(e,a,o){var s=n(e.children),c=r(a,s);return Object.keys(c).forEach(function(n){var r=c[n];if((0,t.isValidElement)(r)){var l=n in a,u=n in s,d=a[n],f=(0,t.isValidElement)(d)&&!d.props.in;u&&(!l||f)?c[n]=(0,t.cloneElement)(r,{onExited:o.bind(null,r),in:!0,exit:i(r,`exit`,e),enter:i(r,`enter`,e)}):!u&&l&&!f?c[n]=(0,t.cloneElement)(r,{in:!1}):u&&l&&(0,t.isValidElement)(d)&&(c[n]=(0,t.cloneElement)(r,{onExited:o.bind(null,r),in:d.props.in,exit:i(r,`exit`,e),enter:i(r,`enter`,e)}))}}),c}})),Ip=s(((e,t)=>{e.__esModule=!0,e.default=void 0,a(wp());var n=a(m()),r=a(jp()),i=Fp();function a(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,a;for(a=0;a<r.length;a++)i=r[a],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}function s(){return s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},s.apply(this,arguments)}function c(e){if(e===void 0)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return e}function l(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}var u=Object.values||function(e){return Object.keys(e).map(function(t){return e[t]})},d={component:`div`,childFactory:function(e){return e}},f=function(e){l(t,e);function t(t,n){var r=e.call(this,t,n)||this;return r.state={contextValue:{isMounting:!0},handleExited:r.handleExited.bind(c(r)),firstRender:!0},r}var a=t.prototype;return a.componentDidMount=function(){this.mounted=!0,this.setState({contextValue:{isMounting:!1}})},a.componentWillUnmount=function(){this.mounted=!1},t.getDerivedStateFromProps=function(e,t){var n=t.children,r=t.handleExited;return{children:t.firstRender?(0,i.getInitialChildMapping)(e,r):(0,i.getNextChildMapping)(e,n,r),firstRender:!1}},a.handleExited=function(e,t){var n=(0,i.getChildMapping)(this.props.children);e.key in n||(e.props.onExited&&e.props.onExited(t),this.mounted&&this.setState(function(t){var n=s({},t.children);return delete n[e.key],{children:n}}))},a.render=function(){var e=this.props,t=e.component,i=e.childFactory,a=o(e,[`component`,`childFactory`]),s=this.state.contextValue,c=u(this.state.children).map(i);return delete a.appear,delete a.enter,delete a.exit,t===null?n.default.createElement(r.default.Provider,{value:s},c):n.default.createElement(r.default.Provider,{value:s},n.default.createElement(t,a,c))},t}(n.default.Component);f.propTypes={},f.defaultProps=d,e.default=f,t.exports=e.default})),Lp=s(((e,t)=>{e.__esModule=!0,e.default=void 0,a(wp());var n=a(m()),r=a(Nt()),i=a(Ip());function a(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,a;for(a=0;a<r.length;a++)i=r[a],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}function s(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}var c=function(e){s(t,e);function t(){for(var t,n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];return t=e.call.apply(e,[this].concat(r))||this,t.handleEnter=function(){for(var e=arguments.length,n=Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.handleLifecycle(`onEnter`,0,n)},t.handleEntering=function(){for(var e=arguments.length,n=Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.handleLifecycle(`onEntering`,0,n)},t.handleEntered=function(){for(var e=arguments.length,n=Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.handleLifecycle(`onEntered`,0,n)},t.handleExit=function(){for(var e=arguments.length,n=Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.handleLifecycle(`onExit`,1,n)},t.handleExiting=function(){for(var e=arguments.length,n=Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.handleLifecycle(`onExiting`,1,n)},t.handleExited=function(){for(var e=arguments.length,n=Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.handleLifecycle(`onExited`,1,n)},t}var a=t.prototype;return a.handleLifecycle=function(e,t,i){var a,o=this.props.children,s=n.default.Children.toArray(o)[t];if(s.props[e]&&(a=s.props)[e].apply(a,i),this.props[e]){var c=s.props.nodeRef?void 0:r.default.findDOMNode(this);this.props[e](c)}},a.render=function(){var e=this.props,t=e.children,r=e.in,a=o(e,[`children`,`in`]),s=n.default.Children.toArray(t),c=s[0],l=s[1];return delete a.onEnter,delete a.onEntering,delete a.onEntered,delete a.onExit,delete a.onExiting,delete a.onExited,n.default.createElement(i.default,a,r?n.default.cloneElement(c,{key:`first`,onEnter:this.handleEnter,onEntering:this.handleEntering,onEntered:this.handleEntered}):n.default.cloneElement(l,{key:`second`,onEnter:this.handleExit,onEntering:this.handleExiting,onEntered:this.handleExited}))},t}(n.default.Component);c.propTypes={},e.default=c,t.exports=e.default})),Rp=s((e=>{e.__esModule=!0,e.default=e.modes=void 0;var t=o(m());o(wp());var n=Np(),r=o(jp()),i,a;function o(e){return e&&e.__esModule?e:{default:e}}function s(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}function c(e,n){return!(e===n||t.default.isValidElement(e)&&t.default.isValidElement(n)&&e.key!=null&&e.key===n.key)}var l={out:`out-in`,in:`in-out`};e.modes=l;var u=function(e,t,n){return function(){var r;e.props[t]&&(r=e.props)[t].apply(r,arguments),n()}},d=(i={},i[l.out]=function(e){var r=e.current,i=e.changeState;return t.default.cloneElement(r,{in:!1,onExited:u(r,`onExited`,function(){i(n.ENTERING,null)})})},i[l.in]=function(e){var r=e.current,i=e.changeState,a=e.children;return[r,t.default.cloneElement(a,{in:!0,onEntered:u(a,`onEntered`,function(){i(n.ENTERING)})})]},i),f=(a={},a[l.out]=function(e){var r=e.children,i=e.changeState;return t.default.cloneElement(r,{in:!0,onEntered:u(r,`onEntered`,function(){i(n.ENTERED,t.default.cloneElement(r,{in:!0}))})})},a[l.in]=function(e){var r=e.current,i=e.children,a=e.changeState;return[t.default.cloneElement(r,{in:!1,onExited:u(r,`onExited`,function(){a(n.ENTERED,t.default.cloneElement(i,{in:!0}))})}),t.default.cloneElement(i,{in:!0})]},a),p=function(e){s(i,e);function i(){for(var t,r=arguments.length,i=Array(r),a=0;a<r;a++)i[a]=arguments[a];return t=e.call.apply(e,[this].concat(i))||this,t.state={status:n.ENTERED,current:null},t.appeared=!1,t.changeState=function(e,n){n===void 0&&(n=t.state.current),t.setState({status:e,current:n})},t}var a=i.prototype;return a.componentDidMount=function(){this.appeared=!0},i.getDerivedStateFromProps=function(e,r){return e.children==null?{current:null}:r.status===n.ENTERING&&e.mode===l.in?{status:n.ENTERING}:r.current&&c(r.current,e.children)?{status:n.EXITING}:{current:t.default.cloneElement(e.children,{in:!0})}},a.render=function(){var e=this.props,i=e.children,a=e.mode,o=this.state,s=o.status,c=o.current,l={children:i,current:c,changeState:this.changeState,status:s},u;switch(s){case n.ENTERING:u=f[a](l);break;case n.EXITING:u=d[a](l);break;case n.ENTERED:u=c}return t.default.createElement(r.default.Provider,{value:{isMounting:!this.appeared}},u)},i}(t.default.Component);p.propTypes={},p.defaultProps={mode:l.out},e.default=p})),zp=s((e=>{e.__esModule=!0,e.config=e.Transition=e.TransitionGroup=e.SwitchTransition=e.ReplaceTransition=e.CSSTransition=void 0,e.CSSTransition=t(Pp()).default,e.ReplaceTransition=t(Lp()).default,e.SwitchTransition=t(Rp()).default,e.TransitionGroup=t(Ip()).default,e.Transition=t(Np()).default,e.config=t(kp()).default;function t(e){return e&&e.__esModule?e:{default:e}}}))();const Bp=[-9999,-9999];function Vp(e){let{children:t,visible:n=!1,offset:r=[0,0],overflowVisible:i=!1,placementY:a=`below`}=e,o=(0,h.useRef)(null),[s,c]=(0,h.useState)(Bp),{mountContainer:l}=(0,h.useContext)(et),u=()=>{let e=o.current;if(!e)return null;let[t,n]=r,{clientWidth:i,clientHeight:s}=e,{innerWidth:c,innerHeight:l}=window,u=Math.max(0,c-i-2),d=Math.max(0,l-s-2),f=Math.min(Math.max(t,0),u),p=a===`above`?n-s:n;return[f,Math.min(Math.max(p,0),d)]};(0,h.useLayoutEffect)(()=>{if(!n){c(Bp);return}let e=u();e&&c(e)},[r,a,n]),(0,h.useEffect)(()=>{if(!n)return;let e=()=>{let e=u();e&&c(e)};return window.addEventListener(`resize`,e),()=>{window.removeEventListener(`resize`,e)}},[r,a,n]);function d(e){e.preventDefault()}return(0,Pt.createPortal)((0,z.jsx)(zp.CSSTransition,{in:n,nodeRef:o,timeout:500,classNames:{enter:`univer-popup-enter`,enterActive:`univer-popup-enter-active`,enterDone:`univer-popup-enter-done`,exitActive:`univer-popup-exit`,exitDone:`univer-popup-exit-active`},children:(0,z.jsx)(`section`,{ref:o,className:`univer-popup`,style:{left:s[0]+2,top:s[1]+2,overflow:i?`visible`:void 0},onContextMenu:d,children:t})}),l)}function Hp(e){let{children:t,className:n,style:r,value:i,disabled:a=!1,direction:o=`horizontal`,onChange:s}=e,c=e=>{s(e)};return(0,z.jsx)(`div`,{className:R(`univer-flex univer-gap-2`,{"univer-flex-col":o===`vertical`},n),style:r,children:h.Children.map(t,(e,t)=>(0,h.isValidElement)(e)?(0,h.cloneElement)(e,{key:t,children:e.props.children,value:e.props.value,checked:i===e.props.value,disabled:a==null?e.props.disabled:a,onChange:c}):e)})}function Up(e){let{children:t,checked:n,value:r,disabled:i=!1,onChange:a}=e,o=(0,h.useRef)(null);function s(e){if(e.stopPropagation(),!(!a||i))if(r!==void 0)a&&a(r);else{let e=o.current.checked;a&&a(e)}}return(0,z.jsxs)(`label`,{"data-u-comp":`radio`,className:R(`univer-box-border univer-inline-flex univer-items-center univer-gap-2 univer-text-sm`,{"univer-cursor-pointer univer-text-gray-900 dark:!univer-text-white":!i,"univer-text-gray-400":i}),children:[(0,z.jsxs)(`span`,{className:`univer-relative univer-block`,children:[(0,z.jsx)(`input`,{ref:o,className:`univer-absolute univer-size-0 univer-opacity-0`,type:`radio`,checked:n,disabled:i,onChange:s}),(0,z.jsx)(`span`,{className:R(`univer-relative univer-box-border univer-flex univer-size-4 univer-items-center univer-justify-center univer-overflow-hidden univer-rounded-full univer-border univer-border-solid univer-transition-colors`,{"univer-opacity-50":i,"univer-border-primary-600 univer-bg-primary-600 dark:!univer-bg-primary-600":n,"univer-border-gray-300 univer-bg-gray-50 dark:!univer-border-gray-500 dark:!univer-bg-gray-600":!n}),children:n&&(0,z.jsx)(`span`,{className:`univer-absolute univer-left-1/2 univer-top-1/2 univer-block univer-size-2 -univer-translate-x-1/2 -univer-translate-y-1/2 univer-rounded-full univer-bg-white`})})]}),(0,z.jsx)(`span`,{children:t})]})}function Wp(e){let{value:t,options:n=[],hideCheckMark:r=!1,onChange:i,multiple:a,className:o,optionClassName:s}=e,c=Array.isArray(t)?t:[t];function l(e){let t=c.indexOf(e);i(a?t>-1?c.filter(t=>t===e):[...c,e]:t>-1?void 0:e)}return(0,z.jsx)(`ul`,{className:R(`univer-m-0 univer-grid univer-max-h-80 univer-list-none univer-gap-1 univer-overflow-y-auto univer-rounded univer-p-1.5`,at,rt,o),children:n.map((e,t)=>{let n=c.indexOf(e.value)>-1;return(0,z.jsx)(`li`,{children:(0,z.jsxs)(`a`,{className:R(`univer-relative univer-block univer-cursor-pointer univer-select-none univer-rounded univer-py-1.5 univer-pl-8 univer-pr-2 univer-text-sm univer-text-gray-900 univer-transition-colors hover:univer-bg-gray-100 dark:!univer-text-white dark:hover:!univer-bg-gray-600`,s,{"univer-bg-gray-200 dark:!univer-bg-gray-500":n}),onClick:()=>l(e.value),children:[!r&&n&&(0,z.jsx)(f.CheckMarkIcon,{className:`univer-absolute univer-left-0 univer-top-1/2 -univer-translate-y-1/2 univer-pl-2 univer-text-primary-600`}),(0,z.jsx)(`span`,{style:{color:e.color},children:e.label})]})},t)})})}const Gp=R(`univer-box-border univer-inline-flex univer-h-8 univer-min-w-36 univer-items-center univer-justify-between univer-gap-2 univer-rounded-lg univer-bg-white univer-px-2.5 univer-transition-colors univer-duration-200 dark:!univer-bg-gray-700 dark:!univer-text-white`,at);function Kp(e){let{className:t,value:n,disabled:r=!1,options:i=[],borderless:a=!1,onChange:o}=e,[s,c]=(0,h.useState)(!1);function l(e){c(e)}let u=(0,h.useMemo)(()=>{let e=[];for(let t of i)t.options?(t.options.forEach(t=>{e.push({label:t.label,value:t.value,disabled:t.disabled})}),e.push({type:`separator`})):e.push({label:t.label,value:t.value,disabled:t.disabled});return[{type:`radio`,value:n,hideIndicator:!0,options:e,onSelect:e=>{o(e)}}]},[i]),d=(0,h.useMemo)(()=>{let e=null;for(let t of i)if(t.options){for(let r of t.options)if(r.value===n){e=r.label;break}}else if(t.value===n){e=t.label;break}return e||n},[i,n]);return(0,z.jsx)(qd,{className:`max-h univer-w-[--radix-popper-anchor-width] univer-min-w-36`,align:`start`,open:s,items:u,disabled:r,onOpenChange:l,children:(0,z.jsxs)(`div`,{"data-u-comp":`select`,className:R(Gp,{"univer-border-primary-600 univer-outline-none univer-ring-2 univer-ring-primary-50 dark:!univer-ring-primary-900":s&&!a,"univer-border-transparent univer-bg-transparent hover:univer-border-transparent":a,"univer-cursor-not-allowed":r,"hover:univer-border-primary-600":!r&&!a,"univer-cursor-pointer":!r&&!s},t),children:[(0,z.jsx)(`div`,{className:`univer-flex-1 univer-truncate univer-text-sm univer-text-gray-500 dark:!univer-text-white`,children:d}),(0,z.jsx)(f.MoreDownIcon,{className:`univer-flex-shrink-0 dark:!univer-text-white`})]})})}function qp(e){let{className:t,value:n=[],disabled:r=!1,options:i=[],borderless:a=!1,onChange:o}=e,[s,c]=(0,h.useState)(!1);function l(e){c(e)}let u=(0,h.useMemo)(()=>i.map(e=>({type:`checkbox`,value:e.value,label:e.label,disabled:e.disabled,checked:n.includes(e.value),onSelect:e=>{o(n.includes(e)?n.filter(t=>t!==e):[...n,e])}})),[i]);function d(e){o(n.filter(t=>t!==e))}let p=(0,h.useMemo)(()=>i.filter(e=>n.includes(e.value)).map((e,t)=>(0,z.jsx)(Fe,{className:`univer-max-w-32`,closable:!0,onClose:()=>d(e.value),children:e.label},t)),[i,n]);return(0,z.jsx)(qd,{className:`univer-w-[--radix-popper-anchor-width] univer-min-w-36`,align:`start`,open:s,items:u,disabled:r,onOpenChange:l,children:(0,z.jsxs)(`div`,{"data-u-comp":`multiple-select`,className:R(Gp,{"univer-border-primary-600 univer-outline-none univer-ring-2 univer-ring-primary-50 dark:!univer-ring-primary-900":s&&!a,"univer-border-transparent univer-bg-transparent hover:univer-border-transparent":a,"univer-cursor-not-allowed":r,"hover:univer-border-primary-600":!r&&!a,"univer-cursor-pointer":!r&&!s},t),children:[(0,z.jsx)(`div`,{className:`univer-box-border univer-flex univer-w-[calc(100%-16px)] univer-gap-2 univer-pr-2`,children:p}),(0,z.jsx)(f.MoreDownIcon,{className:`univer-flex-shrink-0 dark:!univer-text-white`})]})})}var Jp=[`a`,`button`,`div`,`form`,`h2`,`h3`,`img`,`input`,`label`,`li`,`nav`,`ol`,`p`,`select`,`span`,`svg`,`ul`].reduce((e,t)=>{let n=Ue(`Primitive.${t}`),r=h.forwardRef((e,r)=>{let{asChild:i,...a}=e,o=i?n:t;return typeof window<`u`&&(window[Symbol.for(`radix-ui`)]=!0),(0,z.jsx)(o,{...a,ref:r})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{}),Yp=`Separator`,Xp=`horizontal`,Zp=[`horizontal`,`vertical`],Qp=h.forwardRef((e,t)=>{let{decorative:n,orientation:r=Xp,...i}=e,a=$p(r)?r:Xp,o=a===`vertical`?a:void 0,s=n?{role:`none`}:{"aria-orientation":o,role:`separator`};return(0,z.jsx)(Jp.div,{"data-orientation":a,...s,...i,ref:t})});Qp.displayName=Yp;function $p(e){return Zp.includes(e)}var em=Qp;function tm({className:e,orientation:t=`horizontal`,decorative:n=!0,...r}){return(0,z.jsx)(em,{"data-u-comp":`separator`,"data-slot":`separator-root`,decorative:n,orientation:t,className:R(`univer-shrink-0 univer-bg-gray-200 data-[orientation=horizontal]:univer-h-px data-[orientation=vertical]:univer-h-full data-[orientation=horizontal]:univer-w-full data-[orientation=vertical]:univer-w-px dark:!univer-bg-gray-600`,e),...r})}const nm=e=>{let{defaultChecked:t=!1,onChange:n}=e,[r,i]=(0,h.useState)(t);return(0,h.useEffect)(()=>{i(t)},[t]),(0,z.jsx)(`div`,{className:`univer-h-4`,children:(0,z.jsxs)(`label`,{className:`univer-relative univer-inline-block univer-h-4 univer-w-7`,children:[(0,z.jsx)(`input`,{className:`univer-size-0 univer-opacity-0`,type:`checkbox`,checked:r,onChange:()=>{i(!r),n==null||n(!r)}}),(0,z.jsx)(`span`,{className:R(`univer-absolute univer-inset-0 univer-cursor-pointer univer-rounded-2xl univer-transition-colors univer-duration-200`,{"univer-bg-primary-600":r,"univer-bg-gray-200 dark:!univer-bg-gray-600":!r}),children:(0,z.jsx)(`span`,{className:R(`univer-absolute univer-bottom-0.5 univer-left-0.5 univer-size-3 univer-rounded-full univer-bg-white univer-transition-transform univer-duration-200`,{"univer-translate-x-3":r})})})]})})},rm=(0,h.forwardRef)((e,t)=>{let n=(0,h.useRef)(null),r=(0,h.useRef)({width:0,height:0}),{className:i,onResize:a,onValueChange:o,...s}=e;(0,h.useImperativeHandle)(t,()=>n.current,[]),(0,h.useLayoutEffect)(()=>{let e=n.current;if(e&&a){let t=new ResizeObserver(e=>{let{width:t,height:n}=e[0].target.getBoundingClientRect();t===0||n===0||(r.current.width!==t||r.current.height!==n)&&(r.current={width:t,height:n},a(t,n))});return t.observe(e),()=>{t.unobserve(e),t.disconnect()}}},[a]);function c(e){let t=e.target.value;o==null||o(t)}return(0,z.jsx)(`textarea`,{ref:n,"data-u-comp":`textarea`,"data-slot":`textarea`,className:R(`univer-box-border univer-flex univer-w-full univer-resize univer-rounded-md univer-bg-transparent univer-p-2 univer-text-base univer-text-gray-900 univer-outline-none univer-transition-[color,box-shadow] placeholder:univer-text-gray-200 disabled:univer-cursor-not-allowed disabled:univer-opacity-50 dark:!univer-text-white`,at,rt,i),onChange:c,...s})});function im({visibleToasts:e,...t}){return(0,z.jsx)(cp,{className:`dark:![&_[data-description]]:univer-text-gray-200 [&_[data-description]]:univer-text-sm [&_[data-description]]:univer-text-gray-600 [&_[data-icon]>svg]:univer-relative [&_[data-icon]>svg]:univer-top-1 [&_[data-icon]]:univer-self-baseline [&_[data-sonner-toast]]:univer-shadow-md [&_[data-title]]:univer-text-sm [&_[data-title]]:univer-text-gray-900`,toastOptions:{classNames:{content:`univer-leading-normal`,success:`[&_[data-icon]]:univer-text-green-500`,info:`[&_[data-icon]]:univer-text-primary-600`,error:`[&_[data-icon]]:univer-text-red-500`,warning:`[&_[data-icon]]:univer-text-yellow-500`}},visibleToasts:e==null?5:e,...t})}function am(e){let{data:t,itemKey:n,children:r,height:i,itemHeight:a,overscan:o=2,className:s,style:c}=e,[l,u]=(0,h.useState)(0);if(!i||!a||a<=0)return(0,z.jsx)(`div`,{className:s,style:c,children:t.map((e,t)=>{let i=typeof n==`function`?n(e):e[n];return(0,z.jsx)(`div`,{children:r(e,t)},i)})});let d=Math.max(0,Math.floor(l/a)-o),f=Math.ceil(i/a)+o*2,p=Math.min(t.length,d+f),m=d*a,g=t.length*a,_=t.slice(d,p);return(0,z.jsx)(`div`,{className:s,style:{...c,height:i,overflowY:`auto`},onScroll:e=>u(e.currentTarget.scrollTop),children:(0,z.jsx)(`div`,{style:{height:g,position:`relative`},children:(0,z.jsx)(`div`,{style:{transform:`translateY(${m}px)`},children:_.map((e,t)=>{let i=typeof n==`function`?n(e):e[n];return(0,z.jsx)(`div`,{children:r(e,d+t)},i)})})})})}const om=(e,t)=>{let n=[],r=e=>{var i;if(n.push(e.key),t===e.key||(i=e.children)!=null&&i.length&&e.children.some(r))return!0;n.pop()};return e.some(r),n},sm=(e,t)=>{let n=t==null?new Map:t,r=e;return{findNodePathFromTreeWithCache:e=>{let t=n.get(e);if(t)return t;let i=om(r,e);return i.map((e,t,n)=>{let r=[];for(let e=0;e<=t;e++)r.push(n[e]);return r}).reverse().forEach(e=>{let t=e[e.length-1];n.set(t,e)}),i},reset:e=>{n.clear(),e&&(r=e)}}},cm=(e,t)=>t.length?t.reduce((e,t)=>{let n=e.find(e=>e.key===t);return(n==null?void 0:n.children)||[]},e):e,lm=(e,t)=>{let n=t.slice(0),r=n.pop();return cm(e,n).find(e=>e.key===r)},um=(e,t,n)=>{let r=new Set(t),i=n[n.length-1],a=cm(e,n);if(r.has(i)){if(a.length){let e=t=>{r.delete(t.key),t.children&&t.children.forEach(t=>e(t))};a.forEach(e)}n.map((e,t,n)=>{let r=[];for(let e=0;e<=t;e++)r.push(n[e]);return r}).reverse().some(t=>{let n=cm(e,t),i=t[t.length-1];if(n.every(e=>!r.has(e.key)))r.delete(i);else return!0;return!1})}else{let e=t=>{r.add(t.key),t.children&&t.children.forEach(t=>e(t))};n.forEach(e=>r.add(e)),a.length&&a.forEach(e)}return[...r]},dm=(e,t)=>{let n=t.children||[],r=t=>{var n;return(n=t.children)!=null&&n.length?!!t.children.every(r):e.has(t.key)};return n.length?n.some(e=>!r(e)):!1},fm=(e,t)=>{let n=[],r=sm(e);return t.forEach(t=>{let i=lm(e,r.findNodePathFromTreeWithCache(t));if(i){var a;(a=i.children)!=null&&a.length||n.push(i)}}),n};let pm=function(e){return e[e.ONLY_LEAF_NODE=0]=`ONLY_LEAF_NODE`,e[e.ALL=1]=`ALL`,e}({});function mm(e,t,n=1){let r=[];return e.forEach(e=>{r.push({...e,level:n}),e.children&&t.has(e.key)&&r.push(...mm(e.children,t,n+1))}),r}function hm(e){let{data:t=[],defaultCache:n,style:r,defaultExpandAll:i=!1,selectionMode:a=pm.ALL,valueGroup:o=[],onChange:s,onExpend:c,height:l=200,itemHeight:u=32,attachRender:d}=e,[p,m]=(0,h.useState)({}),g=(0,h.useMemo)(()=>new Set,[]),_=(0,h.useMemo)(()=>sm(t,n),[t,n]),v=(0,h.useMemo)(()=>{let e=new Set;return o.forEach(t=>{_.findNodePathFromTreeWithCache(t).forEach(t=>e.add(t))}),e},[o,_]);(0,h.useEffect)(()=>{function e(t){var n;g.add(t.key),(n=t.children)==null||n.forEach(e)}i&&t.forEach(e),m({})},[i,t]);let y=(0,h.useMemo)(()=>mm(t,g),[t,p,g]);function b(e){var t;(t=e.children)!=null&&t.length&&(g.has(e.key)?g.delete(e.key):g.add(e.key),m({})),!(a===pm.ONLY_LEAF_NODE&&e.children)&&(c==null||c(e.key))}function x(t){let{title:n,key:r,level:i=0}=t,a=e.treeNodeClassName,o=g.has(r),c=v.has(r),l=dm(v,t);return(0,z.jsx)(`div`,{className:R(`univer-relative univer-text-[13px]`,a),style:{paddingLeft:`${i*20}px`},children:(0,z.jsxs)(`div`,{className:`univer-relative univer-my-1 univer-flex univer-w-full univer-items-center`,children:[t.children&&t.children.length>0&&(0,z.jsx)(`span`,{className:R(`univer-absolute univer-left-[-16px] univer-top-1/2 univer-flex univer--translate-y-1/2 univer-items-center univer-justify-center univer-text-[8px]`,{"univer-rotate-[-90deg]":!o}),onClick:e=>{e.stopPropagation(),b(t)},children:(0,z.jsx)(f.DropdownIcon,{})}),(0,z.jsx)(yt,{checked:c&&!l,indeterminate:c&&l,onChange:()=>{s==null||s(t)}}),(0,z.jsx)(`div`,{className:`
292
153
  univer-mx-1 univer-flex univer-h-full univer-shrink univer-items-center univer-overflow-hidden
293
154
  univer-text-ellipsis univer-whitespace-nowrap
294
- `,onClick:F=>{F.stopPropagation(),E(C)},children:v.jsx(yi,{className:"univer-block",showIfEllipsis:!0,placement:"top",title:S,children:v.jsx("span",{className:"univer-block",children:S})})}),u&&u(C)]})},R)}return v.jsx("section",{className:`
155
+ `,onClick:e=>{e.stopPropagation(),b(t)},children:(0,z.jsx)(af,{className:`univer-block`,showIfEllipsis:!0,placement:`top`,title:n,children:(0,z.jsx)(`span`,{className:`univer-block`,children:n})})}),d&&d(t)]})},r)}return(0,z.jsx)(`section`,{className:`
295
156
  univer-relative univer-select-none univer-text-gray-900
296
157
  dark:!univer-text-white
297
- `,children:v.jsx("div",{className:"univer-m-0 univer-h-full univer-list-none univer-p-0",style:r,children:v.jsx(mC,{data:x,itemKey:C=>C.key,height:l,itemHeight:f,children:C=>w(C)})})})}const oi=new WeakMap;function xC(e,t){let n=oi.get(t);n||(n=uv.createRoot(t),oi.set(t,n)),n.render(e)}function wC(e){const t=oi.get(e);t&&(t.unmount(),oi.delete(e))}const aa=new Set;let Po;function CC(e){return Po||(Po=new ResizeObserver((...t)=>{aa.forEach(n=>n(...t))})),{observe(t,n){aa.add(e),Po.observe(t,n)},unobserve(t){aa.delete(e),Po.unobserve(t)}}}exports.Accordion=lm;exports.Avatar=dm;exports.Badge=wl;exports.Button=un;exports.ButtonGroup=wm;exports.Calendar=Fo;exports.CascaderList=Tm;exports.Checkbox=Nl;exports.CheckboxGroup=Om;exports.ColorPicker=fc;exports.ConfigContext=Zt;exports.ConfigProvider=Cm;exports.Confirm=Ih;exports.DatePicker=m0;exports.DateRangePicker=p0;exports.Dialog=Ga;exports.DraggableList=g0;exports.Dropdown=ss;exports.DropdownMenu=hs;exports.FormDualColumnLayout=ub;exports.FormLayout=sb;exports.Gallery=lb;exports.GradientColorPicker=fb;exports.HoverCard=Mb;exports.Input=Bd;exports.InputNumber=pa;exports.KBD=Nb;exports.Menu=dw;exports.MenuItem=fw;exports.MenuItemGroup=mw;exports.MessageType=Zf;exports.Messager=Kw;exports.MultipleSelect=rC;exports.Pager=zd;exports.Popup=Qw;exports.Radio=eC;exports.RadioGroup=Jw;exports.Segmented=Hd;exports.Select=nC;exports.SelectList=tC;exports.Separator=cC;exports.SubMenu=vw;exports.Switch=dC;exports.Textarea=fC;exports.TimeInput=Ml;exports.TinyMenuGroup=pw;exports.Toaster=vC;exports.Tooltip=yi;exports.Tree=yC;exports.TreeSelectionMode=av;exports.borderBottomClassName=Pm;exports.borderClassName=ct;exports.borderLeftBottomClassName=Mm;exports.borderLeftClassName=Rl;exports.borderRightClassName=km;exports.borderTopClassName=Nm;exports.clsx=W;exports.divideXClassName=Im;exports.divideYClassName=_m;exports.filterLeafNode=bC;exports.findNodePathFromTree=ov;exports.findSubTreeFromPath=ri;exports.isBrowser=Ba;exports.mergeTreeSelected=hC;exports.message=Uw;exports.removeMessage=Gw;exports.render=xC;exports.resizeObserverCtor=CC;exports.scrollbarClassName=kn;exports.toast=Nn;exports.unmount=wC;
158
+ `,children:(0,z.jsx)(`div`,{className:`univer-m-0 univer-h-full univer-list-none univer-p-0`,style:r,children:(0,z.jsx)(am,{data:y,itemKey:e=>e.key,height:l,itemHeight:u,children:e=>x(e)})})})}
159
+ /**
160
+ * @license React
161
+ * scheduler.production.js
162
+ *
163
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
164
+ *
165
+ * This source code is licensed under the MIT license found in the
166
+ * LICENSE file in the root directory of this source tree.
167
+ */
168
+ var gm=s((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0<n;){var r=n-1>>>1,a=e[r];if(0<i(a,t))e[r]=t,e[n]=a,n=r;else break a}}function n(e){return e.length===0?null:e[0]}function r(e){if(e.length===0)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;a:for(var r=0,a=e.length,o=a>>>1;r<o;){var s=2*(r+1)-1,c=e[s],l=s+1,u=e[l];if(0>i(c,n))l<a&&0>i(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(l<a&&0>i(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function x(e){if(h=!1,b(e),!m)if(n(c)!==null)m=!0,S||(S=!0,O());else{var t=n(l);t!==null&&j(x,t.startTime-e)}}var S=!1,C=-1,w=5,T=-1;function E(){return g?!0:!(e.unstable_now()-T<w)}function D(){if(g=!1,S){var t=e.unstable_now();T=t;var i=!0;try{a:{m=!1,h&&(h=!1,v(C),C=-1),p=!0;var a=f;try{b:{for(b(t),d=n(c);d!==null&&!(d.expirationTime>t&&E());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&j(x,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}i=void 0}}finally{i?O():S=!1}}}var O;if(typeof y==`function`)O=function(){y(D)};else if(typeof MessageChannel<`u`){var k=new MessageChannel,A=k.port2;k.port1.onmessage=D,O=function(){A.postMessage(null)}}else O=function(){_(D,0)};function j(t,n){C=_(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125<e?console.error(`forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported`):w=0<e?Math.floor(1e3/e):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_next=function(e){switch(f){case 1:case 2:case 3:var t=3;break;default:t=f}var n=f;f=t;try{return e()}finally{f=n}},e.unstable_requestPaint=function(){g=!0},e.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=f;f=e;try{return t()}finally{f=n}},e.unstable_scheduleCallback=function(r,i,a){var o=e.unstable_now();switch(typeof a==`object`&&a?(a=a.delay,a=typeof a==`number`&&0<a?o+a:o):a=o,r){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return s=a+s,r={id:u++,callback:i,priorityLevel:r,startTime:a,expirationTime:s,sortIndex:-1},a>o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(C),C=-1):h=!0,j(x,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,S||(S=!0,O()))),r},e.unstable_shouldYield=E,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),_m=s(((e,t)=>{t.exports=gm()})),vm=s((e=>{var t=_m(),n=m(),r=Nt();function i(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function a(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function o(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function s(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function c(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function l(e){if(o(e)!==e)throw Error(i(188))}function u(e){var t=e.alternate;if(!t){if(t=o(e),t===null)throw Error(i(188));return t===e?e:null}for(var n=e,r=t;;){var a=n.return;if(a===null)break;var s=a.alternate;if(s===null){if(r=a.return,r!==null){n=r;continue}break}if(a.child===s.child){for(s=a.child;s;){if(s===n)return l(a),e;if(s===r)return l(a),t;s=s.sibling}throw Error(i(188))}if(n.return!==r.return)n=a,r=s;else{for(var c=!1,u=a.child;u;){if(u===n){c=!0,n=a,r=s;break}if(u===r){c=!0,r=a,n=s;break}u=u.sibling}if(!c){for(u=s.child;u;){if(u===n){c=!0,n=s,r=a;break}if(u===r){c=!0,r=s,n=a;break}u=u.sibling}if(!c)throw Error(i(189))}}if(n.alternate!==r)throw Error(i(190))}if(n.tag!==3)throw Error(i(188));return n.stateNode.current===n?e:t}function d(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=d(e),t!==null)return t;e=e.sibling}return null}var f=Object.assign,p=Symbol.for(`react.element`),h=Symbol.for(`react.transitional.element`),g=Symbol.for(`react.portal`),_=Symbol.for(`react.fragment`),v=Symbol.for(`react.strict_mode`),y=Symbol.for(`react.profiler`),b=Symbol.for(`react.consumer`),x=Symbol.for(`react.context`),S=Symbol.for(`react.forward_ref`),C=Symbol.for(`react.suspense`),w=Symbol.for(`react.suspense_list`),T=Symbol.for(`react.memo`),E=Symbol.for(`react.lazy`),D=Symbol.for(`react.activity`),O=Symbol.for(`react.memo_cache_sentinel`),k=Symbol.iterator;function A(e){return typeof e!=`object`||!e?null:(e=k&&e[k]||e[`@@iterator`],typeof e==`function`?e:null)}var j=Symbol.for(`react.client.reference`);function ee(e){if(e==null)return null;if(typeof e==`function`)return e.$$typeof===j?null:e.displayName||e.name||null;if(typeof e==`string`)return e;switch(e){case _:return`Fragment`;case y:return`Profiler`;case v:return`StrictMode`;case C:return`Suspense`;case w:return`SuspenseList`;case D:return`Activity`}if(typeof e==`object`)switch(e.$$typeof){case g:return`Portal`;case x:return e.displayName||`Context`;case b:return(e._context.displayName||`Context`)+`.Consumer`;case S:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||``,e=e===``?`ForwardRef`:`ForwardRef(`+e+`)`),e;case T:return t=e.displayName||null,t===null?ee(e.type)||`Memo`:t;case E:t=e._payload,e=e._init;try{return ee(e(t))}catch{}}return null}var M=Array.isArray,N=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,P=r.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,F={pending:!1,data:null,method:null,action:null},te=[],ne=-1;function re(e){return{current:e}}function ie(e){0>ne||(e.current=te[ne],te[ne]=null,ne--)}function I(e,t){ne++,te[ne]=e.current,e.current=t}var ae=re(null),oe=re(null),se=re(null),ce=re(null);function le(e,t){switch(I(se,t),I(oe,e),I(ae,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Bd(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Bd(t),e=Vd(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}ie(ae),I(ae,e)}function ue(){ie(ae),ie(oe),ie(se)}function de(e){e.memoizedState!==null&&I(ce,e);var t=ae.current,n=Vd(t,e.type);t!==n&&(I(oe,e),I(ae,n))}function fe(e){oe.current===e&&(ie(ae),ie(oe)),ce.current===e&&(ie(ce),Zf._currentValue=F)}var pe,L;function me(e){if(pe===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);pe=t&&t[1]||``,L=-1<e.stack.indexOf(`
169
+ at`)?` (<anonymous>)`:-1<e.stack.indexOf(`@`)?`@unknown:0:0`:``}return`
170
+ `+pe+e+L}var he=!1;function ge(e,t){if(!e||he)return``;he=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var r={DetermineComponentFrameRoot:function(){try{if(t){var n=function(){throw Error()};if(Object.defineProperty(n.prototype,`props`,{set:function(){throw Error()}}),typeof Reflect==`object`&&Reflect.construct){try{Reflect.construct(n,[])}catch(e){var r=e}Reflect.construct(e,[],n)}else{try{n.call()}catch(e){r=e}e.call(n.prototype)}}else{try{throw Error()}catch(e){r=e}(n=e())&&typeof n.catch==`function`&&n.catch(function(){})}}catch(e){if(e&&r&&typeof e.stack==`string`)return[e.stack,r.stack]}return[null,null]}};r.DetermineComponentFrameRoot.displayName=`DetermineComponentFrameRoot`;var i=Object.getOwnPropertyDescriptor(r.DetermineComponentFrameRoot,`name`);i&&i.configurable&&Object.defineProperty(r.DetermineComponentFrameRoot,`name`,{value:`DetermineComponentFrameRoot`});var a=r.DetermineComponentFrameRoot(),o=a[0],s=a[1];if(o&&s){var c=o.split(`
171
+ `),l=s.split(`
172
+ `);for(i=r=0;r<c.length&&!c[r].includes(`DetermineComponentFrameRoot`);)r++;for(;i<l.length&&!l[i].includes(`DetermineComponentFrameRoot`);)i++;if(r===c.length||i===l.length)for(r=c.length-1,i=l.length-1;1<=r&&0<=i&&c[r]!==l[i];)i--;for(;1<=r&&0<=i;r--,i--)if(c[r]!==l[i]){if(r!==1||i!==1)do if(r--,i--,0>i||c[r]!==l[i]){var u=`
173
+ `+c[r].replace(` at new `,` at `);return e.displayName&&u.includes(`<anonymous>`)&&(u=u.replace(`<anonymous>`,e.displayName)),u}while(1<=r&&0<=i);break}}}finally{he=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?me(n):``}function _e(e,t){switch(e.tag){case 26:case 27:case 5:return me(e.type);case 16:return me(`Lazy`);case 13:return e.child!==t&&t!==null?me(`Suspense Fallback`):me(`Suspense`);case 19:return me(`SuspenseList`);case 0:case 15:return ge(e.type,!1);case 11:return ge(e.type.render,!1);case 1:return ge(e.type,!0);case 31:return me(`Activity`);default:return``}}function ve(e){try{var t=``,n=null;do t+=_e(e,n),n=e,e=e.return;while(e);return t}catch(e){return`
174
+ Error generating stack: `+e.message+`
175
+ `+e.stack}}var ye=Object.prototype.hasOwnProperty,be=t.unstable_scheduleCallback,xe=t.unstable_cancelCallback,Se=t.unstable_shouldYield,Ce=t.unstable_requestPaint,we=t.unstable_now,Te=t.unstable_getCurrentPriorityLevel,Ee=t.unstable_ImmediatePriority,De=t.unstable_UserBlockingPriority,R=t.unstable_NormalPriority,Oe=t.unstable_LowPriority,z=t.unstable_IdlePriority,ke=t.log,Ae=t.unstable_setDisableYieldValue,je=null,Me=null;function Ne(e){if(typeof ke==`function`&&Ae(e),Me&&typeof Me.setStrictMode==`function`)try{Me.setStrictMode(je,e)}catch{}}var Pe=Math.clz32?Math.clz32:Le,Fe=Math.log,Ie=Math.LN2;function Le(e){return e>>>=0,e===0?32:31-(Fe(e)/Ie|0)|0}var Re=256,ze=262144,Be=4194304;function Ve(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function He(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var i=0,a=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var s=r&134217727;return s===0?(s=r&~a,s===0?o===0?n||(n=r&~e,n!==0&&(i=Ve(n))):i=Ve(o):i=Ve(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=Ve(n))):i=Ve(o)):i=Ve(r)),i===0?0:t!==0&&t!==i&&(t&a)===0&&(a=i&-i,n=t&-t,a>=n||a===32&&n&4194048)?t:i}function Ue(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function We(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Ge(){var e=Be;return Be<<=1,!(Be&62914560)&&(Be=4194304),e}function Ke(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function qe(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function Je(e,t,n,r,i,a){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var s=e.entanglements,c=e.expirationTimes,l=e.hiddenUpdates;for(n=o&~n;0<n;){var u=31-Pe(n),d=1<<u;s[u]=0,c[u]=-1;var f=l[u];if(f!==null)for(l[u]=null,u=0;u<f.length;u++){var p=f[u];p!==null&&(p.lane&=-536870913)}n&=~d}r!==0&&Ye(e,r,0),a!==0&&i===0&&e.tag!==0&&(e.suspendedLanes|=a&~(o&~t))}function Ye(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var r=31-Pe(t);e.entangledLanes|=t,e.entanglements[r]=e.entanglements[r]|1073741824|n&261930}function Xe(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-Pe(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}function Ze(e,t){var n=t&-t;return n=n&42?1:Qe(n),(n&(e.suspendedLanes|t))===0?n:0}function Qe(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function $e(e){return e&=-e,2<e?8<e?e&134217727?32:268435456:8:2}function et(){var e=P.p;return e===0?(e=window.event,e===void 0?32:pp(e.type)):e}function tt(e,t){var n=P.p;try{return P.p=e,t()}finally{P.p=n}}var nt=Math.random().toString(36).slice(2),rt=`__reactFiber$`+nt,it=`__reactProps$`+nt,at=`__reactContainer$`+nt,ot=`__reactEvents$`+nt,st=`__reactListeners$`+nt,ct=`__reactHandles$`+nt,lt=`__reactResources$`+nt,ut=`__reactMarker$`+nt;function dt(e){delete e[rt],delete e[it],delete e[ot],delete e[st],delete e[ct]}function ft(e){var t=e[rt];if(t)return t;for(var n=e.parentNode;n;){if(t=n[at]||n[rt]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=uf(e);e!==null;){if(n=e[rt])return n;e=uf(e)}return t}e=n,n=e.parentNode}return null}function pt(e){if(e=e[rt]||e[at]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function mt(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(i(33))}function ht(e){var t=e[lt];return t||(t=e[lt]={hoistableStyles:new Map,hoistableScripts:new Map}),t}function gt(e){e[ut]=!0}var _t=new Set,vt={};function yt(e,t){B(e,t),B(e+`Capture`,t)}function B(e,t){for(vt[e]=t,e=0;e<t.length;e++)_t.add(t[e])}var bt=RegExp(`^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$`),xt={},St={};function Ct(e){return ye.call(St,e)?!0:ye.call(xt,e)?!1:bt.test(e)?St[e]=!0:(xt[e]=!0,!1)}function wt(e,t,n){if(Ct(t))if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:e.removeAttribute(t);return;case`boolean`:var r=t.toLowerCase().slice(0,5);if(r!==`data-`&&r!==`aria-`){e.removeAttribute(t);return}}e.setAttribute(t,``+n)}}function Tt(e,t,n){if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(t);return}e.setAttribute(t,``+n)}}function Et(e,t,n,r){if(r===null)e.removeAttribute(n);else{switch(typeof r){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(n);return}e.setAttributeNS(t,n,``+r)}}function Dt(e){switch(typeof e){case`bigint`:case`boolean`:case`number`:case`string`:case`undefined`:return e;case`object`:return e;default:return``}}function Ot(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()===`input`&&(t===`checkbox`||t===`radio`)}function kt(e,t,n){var r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&r!==void 0&&typeof r.get==`function`&&typeof r.set==`function`){var i=r.get,a=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(e){n=``+e,a.call(this,e)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(e){n=``+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function At(e){if(!e._valueTracker){var t=Ot(e)?`checked`:`value`;e._valueTracker=kt(e,t,``+e[t])}}function jt(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r=``;return e&&(r=Ot(e)?e.checked?`true`:`false`:e.value),e=r,e===n?!1:(t.setValue(e),!0)}function Mt(e){if(e=e||(typeof document<`u`?document:void 0),e===void 0)return null;try{return e.activeElement||e.body}catch{return e.body}}var Pt=/[\n"\\]/g;function Ft(e){return e.replace(Pt,function(e){return`\\`+e.charCodeAt(0).toString(16)+` `})}function It(e,t,n,r,i,a,o,s){e.name=``,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`?e.type=o:e.removeAttribute(`type`),t==null?o!==`submit`&&o!==`reset`||e.removeAttribute(`value`):o===`number`?(t===0&&e.value===``||e.value!=t)&&(e.value=``+Dt(t)):e.value!==``+Dt(t)&&(e.value=``+Dt(t)),t==null?n==null?r!=null&&e.removeAttribute(`value`):Rt(e,o,Dt(n)):Rt(e,o,Dt(t)),i==null&&a!=null&&(e.defaultChecked=!!a),i!=null&&(e.checked=i&&typeof i!=`function`&&typeof i!=`symbol`),s!=null&&typeof s!=`function`&&typeof s!=`symbol`&&typeof s!=`boolean`?e.name=``+Dt(s):e.removeAttribute(`name`)}function Lt(e,t,n,r,i,a,o,s){if(a!=null&&typeof a!=`function`&&typeof a!=`symbol`&&typeof a!=`boolean`&&(e.type=a),t!=null||n!=null){if(!(a!==`submit`&&a!==`reset`||t!=null)){At(e);return}n=n==null?``:``+Dt(n),t=t==null?n:``+Dt(t),s||t===e.value||(e.value=t),e.defaultValue=t}r=r==null?i:r,r=typeof r!=`function`&&typeof r!=`symbol`&&!!r,e.checked=s?e.checked:!!r,e.defaultChecked=!!r,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`&&(e.name=o),At(e)}function Rt(e,t,n){t===`number`&&Mt(e.ownerDocument)===e||e.defaultValue===``+n||(e.defaultValue=``+n)}function zt(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t[`$`+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty(`$`+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=``+Dt(n),t=null,i=0;i<e.length;i++){if(e[i].value===n){e[i].selected=!0,r&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function Bt(e,t,n){if(t!=null&&(t=``+Dt(t),t!==e.value&&(e.value=t),n==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=n==null?``:``+Dt(n)}function Vt(e,t,n,r){if(t==null){if(r!=null){if(n!=null)throw Error(i(92));if(M(r)){if(1<r.length)throw Error(i(93));r=r[0]}n=r}n==null&&(n=``),t=n}n=Dt(t),e.defaultValue=n,r=e.textContent,r===n&&r!==``&&r!==null&&(e.value=r),At(e)}function Ht(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Ut=new Set(`animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp`.split(` `));function Wt(e,t,n){var r=t.indexOf(`--`)===0;n==null||typeof n==`boolean`||n===``?r?e.setProperty(t,``):t===`float`?e.cssFloat=``:e[t]=``:r?e.setProperty(t,n):typeof n!=`number`||n===0||Ut.has(t)?t===`float`?e.cssFloat=n:e[t]=(``+n).trim():e[t]=n+`px`}function Gt(e,t,n){if(t!=null&&typeof t!=`object`)throw Error(i(62));if(e=e.style,n!=null){for(var r in n)!n.hasOwnProperty(r)||t!=null&&t.hasOwnProperty(r)||(r.indexOf(`--`)===0?e.setProperty(r,``):r===`float`?e.cssFloat=``:e[r]=``);for(var a in t)r=t[a],t.hasOwnProperty(a)&&n[a]!==r&&Wt(e,a,r)}else for(var o in t)t.hasOwnProperty(o)&&Wt(e,o,t[o])}function Kt(e){if(e.indexOf(`-`)===-1)return!1;switch(e){case`annotation-xml`:case`color-profile`:case`font-face`:case`font-face-src`:case`font-face-uri`:case`font-face-format`:case`font-face-name`:case`missing-glyph`:return!1;default:return!0}}var qt=new Map([[`acceptCharset`,`accept-charset`],[`htmlFor`,`for`],[`httpEquiv`,`http-equiv`],[`crossOrigin`,`crossorigin`],[`accentHeight`,`accent-height`],[`alignmentBaseline`,`alignment-baseline`],[`arabicForm`,`arabic-form`],[`baselineShift`,`baseline-shift`],[`capHeight`,`cap-height`],[`clipPath`,`clip-path`],[`clipRule`,`clip-rule`],[`colorInterpolation`,`color-interpolation`],[`colorInterpolationFilters`,`color-interpolation-filters`],[`colorProfile`,`color-profile`],[`colorRendering`,`color-rendering`],[`dominantBaseline`,`dominant-baseline`],[`enableBackground`,`enable-background`],[`fillOpacity`,`fill-opacity`],[`fillRule`,`fill-rule`],[`floodColor`,`flood-color`],[`floodOpacity`,`flood-opacity`],[`fontFamily`,`font-family`],[`fontSize`,`font-size`],[`fontSizeAdjust`,`font-size-adjust`],[`fontStretch`,`font-stretch`],[`fontStyle`,`font-style`],[`fontVariant`,`font-variant`],[`fontWeight`,`font-weight`],[`glyphName`,`glyph-name`],[`glyphOrientationHorizontal`,`glyph-orientation-horizontal`],[`glyphOrientationVertical`,`glyph-orientation-vertical`],[`horizAdvX`,`horiz-adv-x`],[`horizOriginX`,`horiz-origin-x`],[`imageRendering`,`image-rendering`],[`letterSpacing`,`letter-spacing`],[`lightingColor`,`lighting-color`],[`markerEnd`,`marker-end`],[`markerMid`,`marker-mid`],[`markerStart`,`marker-start`],[`overlinePosition`,`overline-position`],[`overlineThickness`,`overline-thickness`],[`paintOrder`,`paint-order`],[`panose-1`,`panose-1`],[`pointerEvents`,`pointer-events`],[`renderingIntent`,`rendering-intent`],[`shapeRendering`,`shape-rendering`],[`stopColor`,`stop-color`],[`stopOpacity`,`stop-opacity`],[`strikethroughPosition`,`strikethrough-position`],[`strikethroughThickness`,`strikethrough-thickness`],[`strokeDasharray`,`stroke-dasharray`],[`strokeDashoffset`,`stroke-dashoffset`],[`strokeLinecap`,`stroke-linecap`],[`strokeLinejoin`,`stroke-linejoin`],[`strokeMiterlimit`,`stroke-miterlimit`],[`strokeOpacity`,`stroke-opacity`],[`strokeWidth`,`stroke-width`],[`textAnchor`,`text-anchor`],[`textDecoration`,`text-decoration`],[`textRendering`,`text-rendering`],[`transformOrigin`,`transform-origin`],[`underlinePosition`,`underline-position`],[`underlineThickness`,`underline-thickness`],[`unicodeBidi`,`unicode-bidi`],[`unicodeRange`,`unicode-range`],[`unitsPerEm`,`units-per-em`],[`vAlphabetic`,`v-alphabetic`],[`vHanging`,`v-hanging`],[`vIdeographic`,`v-ideographic`],[`vMathematical`,`v-mathematical`],[`vectorEffect`,`vector-effect`],[`vertAdvY`,`vert-adv-y`],[`vertOriginX`,`vert-origin-x`],[`vertOriginY`,`vert-origin-y`],[`wordSpacing`,`word-spacing`],[`writingMode`,`writing-mode`],[`xmlnsXlink`,`xmlns:xlink`],[`xHeight`,`x-height`]]),Jt=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Yt(e){return Jt.test(``+e)?`javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')`:e}function Xt(){}var Zt=null;function Qt(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var $t=null,en=null;function tn(e){var t=pt(e);if(t&&(e=t.stateNode)){var n=e[it]||null;a:switch(e=t.stateNode,t.type){case`input`:if(It(e,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),t=n.name,n.type===`radio`&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll(`input[name="`+Ft(``+t)+`"][type="radio"]`),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var a=r[it]||null;if(!a)throw Error(i(90));It(r,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name)}}for(t=0;t<n.length;t++)r=n[t],r.form===e.form&&jt(r)}break a;case`textarea`:Bt(e,n.value,n.defaultValue);break a;case`select`:t=n.value,t!=null&&zt(e,!!n.multiple,t,!1)}}}var nn=!1;function rn(e,t,n){if(nn)return e(t,n);nn=!0;try{return e(t)}finally{if(nn=!1,($t!==null||en!==null)&&(yu(),$t&&(t=$t,e=en,en=$t=null,tn(t),e)))for(t=0;t<e.length;t++)tn(e[t])}}function an(e,t){var n=e.stateNode;if(n===null)return null;var r=n[it]||null;if(r===null)return null;n=r[t];a:switch(t){case`onClick`:case`onClickCapture`:case`onDoubleClick`:case`onDoubleClickCapture`:case`onMouseDown`:case`onMouseDownCapture`:case`onMouseMove`:case`onMouseMoveCapture`:case`onMouseUp`:case`onMouseUpCapture`:case`onMouseEnter`:(r=!r.disabled)||(e=e.type,r=!(e===`button`||e===`input`||e===`select`||e===`textarea`)),e=!r;break a;default:e=!1}if(e)return null;if(n&&typeof n!=`function`)throw Error(i(231,t,typeof n));return n}var on=!(typeof window>`u`||window.document===void 0||window.document.createElement===void 0),sn=!1;if(on)try{var cn={};Object.defineProperty(cn,`passive`,{get:function(){sn=!0}}),window.addEventListener(`test`,cn,cn),window.removeEventListener(`test`,cn,cn)}catch{sn=!1}var ln=null,un=null,dn=null;function fn(){if(dn)return dn;var e,t=un,n=t.length,r,i=`value`in ln?ln.value:ln.textContent,a=i.length;for(e=0;e<n&&t[e]===i[e];e++);var o=n-e;for(r=1;r<=o&&t[n-r]===i[a-r];r++);return dn=i.slice(e,1<r?1-r:void 0)}function pn(e){var t=e.keyCode;return`charCode`in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function mn(){return!0}function hn(){return!1}function gn(e){function t(t,n,r,i,a){for(var o in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=i,this.target=a,this.currentTarget=null,e)e.hasOwnProperty(o)&&(t=e[o],this[o]=t?t(i):i[o]);return this.isDefaultPrevented=(i.defaultPrevented==null?!1===i.returnValue:i.defaultPrevented)?mn:hn,this.isPropagationStopped=hn,this}return f(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():typeof e.returnValue!=`unknown`&&(e.returnValue=!1),this.isDefaultPrevented=mn)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():typeof e.cancelBubble!=`unknown`&&(e.cancelBubble=!0),this.isPropagationStopped=mn)},persist:function(){},isPersistent:mn}),t}var _n={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},vn=gn(_n),yn=f({},_n,{view:0,detail:0}),bn=gn(yn),xn,Sn,Cn,wn=f({},yn,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Fn,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return`movementX`in e?e.movementX:(e!==Cn&&(Cn&&e.type===`mousemove`?(xn=e.screenX-Cn.screenX,Sn=e.screenY-Cn.screenY):Sn=xn=0,Cn=e),xn)},movementY:function(e){return`movementY`in e?e.movementY:Sn}}),Tn=gn(wn),En=gn(f({},wn,{dataTransfer:0})),Dn=gn(f({},yn,{relatedTarget:0})),On=gn(f({},_n,{animationName:0,elapsedTime:0,pseudoElement:0})),kn=gn(f({},_n,{clipboardData:function(e){return`clipboardData`in e?e.clipboardData:window.clipboardData}})),An=gn(f({},_n,{data:0})),jn={Esc:`Escape`,Spacebar:` `,Left:`ArrowLeft`,Up:`ArrowUp`,Right:`ArrowRight`,Down:`ArrowDown`,Del:`Delete`,Win:`OS`,Menu:`ContextMenu`,Apps:`ContextMenu`,Scroll:`ScrollLock`,MozPrintableKey:`Unidentified`},Mn={8:`Backspace`,9:`Tab`,12:`Clear`,13:`Enter`,16:`Shift`,17:`Control`,18:`Alt`,19:`Pause`,20:`CapsLock`,27:`Escape`,32:` `,33:`PageUp`,34:`PageDown`,35:`End`,36:`Home`,37:`ArrowLeft`,38:`ArrowUp`,39:`ArrowRight`,40:`ArrowDown`,45:`Insert`,46:`Delete`,112:`F1`,113:`F2`,114:`F3`,115:`F4`,116:`F5`,117:`F6`,118:`F7`,119:`F8`,120:`F9`,121:`F10`,122:`F11`,123:`F12`,144:`NumLock`,145:`ScrollLock`,224:`Meta`},Nn={Alt:`altKey`,Control:`ctrlKey`,Meta:`metaKey`,Shift:`shiftKey`};function Pn(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Nn[e])?!!t[e]:!1}function Fn(){return Pn}var In=gn(f({},yn,{key:function(e){if(e.key){var t=jn[e.key]||e.key;if(t!==`Unidentified`)return t}return e.type===`keypress`?(e=pn(e),e===13?`Enter`:String.fromCharCode(e)):e.type===`keydown`||e.type===`keyup`?Mn[e.keyCode]||`Unidentified`:``},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Fn,charCode:function(e){return e.type===`keypress`?pn(e):0},keyCode:function(e){return e.type===`keydown`||e.type===`keyup`?e.keyCode:0},which:function(e){return e.type===`keypress`?pn(e):e.type===`keydown`||e.type===`keyup`?e.keyCode:0}})),Ln=gn(f({},wn,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),Rn=gn(f({},yn,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Fn})),zn=gn(f({},_n,{propertyName:0,elapsedTime:0,pseudoElement:0})),Bn=gn(f({},wn,{deltaX:function(e){return`deltaX`in e?e.deltaX:`wheelDeltaX`in e?-e.wheelDeltaX:0},deltaY:function(e){return`deltaY`in e?e.deltaY:`wheelDeltaY`in e?-e.wheelDeltaY:`wheelDelta`in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0})),Vn=gn(f({},_n,{newState:0,oldState:0})),Hn=[9,13,27,32],Un=on&&`CompositionEvent`in window,Wn=null;on&&`documentMode`in document&&(Wn=document.documentMode);var Gn=on&&`TextEvent`in window&&!Wn,Kn=on&&(!Un||Wn&&8<Wn&&11>=Wn),qn=` `,Jn=!1;function Yn(e,t){switch(e){case`keyup`:return Hn.indexOf(t.keyCode)!==-1;case`keydown`:return t.keyCode!==229;case`keypress`:case`mousedown`:case`focusout`:return!0;default:return!1}}function Xn(e){return e=e.detail,typeof e==`object`&&`data`in e?e.data:null}var Zn=!1;function Qn(e,t){switch(e){case`compositionend`:return Xn(t);case`keypress`:return t.which===32?(Jn=!0,qn):null;case`textInput`:return e=t.data,e===qn&&Jn?null:e;default:return null}}function $n(e,t){if(Zn)return e===`compositionend`||!Un&&Yn(e,t)?(e=fn(),dn=un=ln=null,Zn=!1,e):null;switch(e){case`paste`:return null;case`keypress`:if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case`compositionend`:return Kn&&t.locale!==`ko`?null:t.data;default:return null}}var er={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function tr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t===`input`?!!er[e.type]:t===`textarea`}function nr(e,t,n,r){$t?en?en.push(r):en=[r]:$t=r,t=Td(t,`onChange`),0<t.length&&(n=new vn(`onChange`,`change`,null,n,r),e.push({event:n,listeners:t}))}var rr=null,ir=null;function ar(e){vd(e,0)}function or(e){if(jt(mt(e)))return e}function sr(e,t){if(e===`change`)return t}var cr=!1;if(on){var lr;if(on){var ur=`oninput`in document;if(!ur){var dr=document.createElement(`div`);dr.setAttribute(`oninput`,`return;`),ur=typeof dr.oninput==`function`}lr=ur}else lr=!1;cr=lr&&(!document.documentMode||9<document.documentMode)}function fr(){rr&&(rr.detachEvent(`onpropertychange`,pr),ir=rr=null)}function pr(e){if(e.propertyName===`value`&&or(ir)){var t=[];nr(t,ir,e,Qt(e)),rn(ar,t)}}function mr(e,t,n){e===`focusin`?(fr(),rr=t,ir=n,rr.attachEvent(`onpropertychange`,pr)):e===`focusout`&&fr()}function hr(e){if(e===`selectionchange`||e===`keyup`||e===`keydown`)return or(ir)}function gr(e,t){if(e===`click`)return or(t)}function _r(e,t){if(e===`input`||e===`change`)return or(t)}function vr(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var yr=typeof Object.is==`function`?Object.is:vr;function br(e,t){if(yr(e,t))return!0;if(typeof e!=`object`||!e||typeof t!=`object`||!t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!ye.call(t,i)||!yr(e[i],t[i]))return!1}return!0}function xr(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Sr(e,t){var n=xr(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}a:{for(;n;){if(n.nextSibling){n=n.nextSibling;break a}n=n.parentNode}n=void 0}n=xr(n)}}function Cr(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Cr(e,t.parentNode):`contains`in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function wr(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Mt(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href==`string`}catch{n=!1}if(n)e=t.contentWindow;else break;t=Mt(e.document)}return t}function Tr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t===`input`&&(e.type===`text`||e.type===`search`||e.type===`tel`||e.type===`url`||e.type===`password`)||t===`textarea`||e.contentEditable===`true`)}var Er=on&&`documentMode`in document&&11>=document.documentMode,Dr=null,Or=null,kr=null,Ar=!1;function jr(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Ar||Dr==null||Dr!==Mt(r)||(r=Dr,`selectionStart`in r&&Tr(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),kr&&br(kr,r)||(kr=r,r=Td(Or,`onSelect`),0<r.length&&(t=new vn(`onSelect`,`select`,null,t,n),e.push({event:t,listeners:r}),t.target=Dr)))}function Mr(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n[`Webkit`+e]=`webkit`+t,n[`Moz`+e]=`moz`+t,n}var Nr={animationend:Mr(`Animation`,`AnimationEnd`),animationiteration:Mr(`Animation`,`AnimationIteration`),animationstart:Mr(`Animation`,`AnimationStart`),transitionrun:Mr(`Transition`,`TransitionRun`),transitionstart:Mr(`Transition`,`TransitionStart`),transitioncancel:Mr(`Transition`,`TransitionCancel`),transitionend:Mr(`Transition`,`TransitionEnd`)},Pr={},Fr={};on&&(Fr=document.createElement(`div`).style,`AnimationEvent`in window||(delete Nr.animationend.animation,delete Nr.animationiteration.animation,delete Nr.animationstart.animation),`TransitionEvent`in window||delete Nr.transitionend.transition);function Ir(e){if(Pr[e])return Pr[e];if(!Nr[e])return e;var t=Nr[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Fr)return Pr[e]=t[n];return e}var Lr=Ir(`animationend`),Rr=Ir(`animationiteration`),zr=Ir(`animationstart`),Br=Ir(`transitionrun`),Vr=Ir(`transitionstart`),Hr=Ir(`transitioncancel`),Ur=Ir(`transitionend`),Wr=new Map,Gr=`abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel`.split(` `);Gr.push(`scrollEnd`);function Kr(e,t){Wr.set(e,t),yt(t,[e])}var qr=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},Jr=[],Yr=0,Xr=0;function Zr(){for(var e=Yr,t=Xr=Yr=0;t<e;){var n=Jr[t];Jr[t++]=null;var r=Jr[t];Jr[t++]=null;var i=Jr[t];Jr[t++]=null;var a=Jr[t];if(Jr[t++]=null,r!==null&&i!==null){var o=r.pending;o===null?i.next=i:(i.next=o.next,o.next=i),r.pending=i}a!==0&&ti(n,i,a)}}function Qr(e,t,n,r){Jr[Yr++]=e,Jr[Yr++]=t,Jr[Yr++]=n,Jr[Yr++]=r,Xr|=r,e.lanes|=r,e=e.alternate,e!==null&&(e.lanes|=r)}function $r(e,t,n,r){return Qr(e,t,n,r),ni(e)}function ei(e,t){return Qr(e,null,null,t),ni(e)}function ti(e,t,n){e.lanes|=n;var r=e.alternate;r!==null&&(r.lanes|=n);for(var i=!1,a=e.return;a!==null;)a.childLanes|=n,r=a.alternate,r!==null&&(r.childLanes|=n),a.tag===22&&(e=a.stateNode,e===null||e._visibility&1||(i=!0)),e=a,a=a.return;return e.tag===3?(a=e.stateNode,i&&t!==null&&(i=31-Pe(n),e=a.hiddenUpdates,r=e[i],r===null?e[i]=[t]:r.push(t),t.lane=n|536870912),a):null}function ni(e){if(50<uu)throw uu=0,du=null,Error(i(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var ri={};function ii(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function ai(e,t,n,r){return new ii(e,t,n,r)}function oi(e){return e=e.prototype,!(!e||!e.isReactComponent)}function si(e,t){var n=e.alternate;return n===null?(n=ai(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&65011712,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n.refCleanup=e.refCleanup,n}function ci(e,t){e.flags&=65011714;var n=e.alternate;return n===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=n.childLanes,e.lanes=n.lanes,e.child=n.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=n.memoizedProps,e.memoizedState=n.memoizedState,e.updateQueue=n.updateQueue,e.type=n.type,t=n.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function li(e,t,n,r,a,o){var s=0;if(r=e,typeof e==`function`)oi(e)&&(s=1);else if(typeof e==`string`)s=Hf(e,n,ae.current)?26:e===`html`||e===`head`||e===`body`?27:5;else a:switch(e){case D:return e=ai(31,n,t,a),e.elementType=D,e.lanes=o,e;case _:return ui(n.children,a,o,t);case v:s=8,a|=24;break;case y:return e=ai(12,n,t,a|2),e.elementType=y,e.lanes=o,e;case C:return e=ai(13,n,t,a),e.elementType=C,e.lanes=o,e;case w:return e=ai(19,n,t,a),e.elementType=w,e.lanes=o,e;default:if(typeof e==`object`&&e)switch(e.$$typeof){case x:s=10;break a;case b:s=9;break a;case S:s=11;break a;case T:s=14;break a;case E:s=16,r=null;break a}s=29,n=Error(i(130,e===null?`null`:typeof e,``)),r=null}return t=ai(s,n,t,a),t.elementType=e,t.type=r,t.lanes=o,t}function ui(e,t,n,r){return e=ai(7,e,r,t),e.lanes=n,e}function di(e,t,n){return e=ai(6,e,null,t),e.lanes=n,e}function fi(e){var t=ai(18,null,null,0);return t.stateNode=e,t}function pi(e,t,n){return t=ai(4,e.children===null?[]:e.children,e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var mi=new WeakMap;function hi(e,t){if(typeof e==`object`&&e){var n=mi.get(e);return n===void 0?(t={value:e,source:t,stack:ve(t)},mi.set(e,t),t):n}return{value:e,source:t,stack:ve(t)}}var gi=[],_i=0,vi=null,yi=0,bi=[],xi=0,Si=null,Ci=1,wi=``;function Ti(e,t){gi[_i++]=yi,gi[_i++]=vi,vi=e,yi=t}function Ei(e,t,n){bi[xi++]=Ci,bi[xi++]=wi,bi[xi++]=Si,Si=e;var r=Ci;e=wi;var i=32-Pe(r)-1;r&=~(1<<i),n+=1;var a=32-Pe(t)+i;if(30<a){var o=i-i%5;a=(r&(1<<o)-1).toString(32),r>>=o,i-=o,Ci=1<<32-Pe(t)+i|n<<i|r,wi=a+e}else Ci=1<<a|n<<i|r,wi=e}function Di(e){e.return!==null&&(Ti(e,1),Ei(e,1,0))}function Oi(e){for(;e===vi;)vi=gi[--_i],gi[_i]=null,yi=gi[--_i],gi[_i]=null;for(;e===Si;)Si=bi[--xi],bi[xi]=null,wi=bi[--xi],bi[xi]=null,Ci=bi[--xi],bi[xi]=null}function ki(e,t){bi[xi++]=Ci,bi[xi++]=wi,bi[xi++]=Si,Ci=t.id,wi=t.overflow,Si=e}var Ai=null,ji=null,V=!1,Mi=null,Ni=!1,Pi=Error(i(519));function Fi(e){throw Vi(hi(Error(i(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?`text`:`HTML`,``)),e)),Pi}function Ii(e){var t=e.stateNode,n=e.type,r=e.memoizedProps;switch(t[rt]=e,t[it]=r,n){case`dialog`:Q(`cancel`,t),Q(`close`,t);break;case`iframe`:case`object`:case`embed`:Q(`load`,t);break;case`video`:case`audio`:for(n=0;n<gd.length;n++)Q(gd[n],t);break;case`source`:Q(`error`,t);break;case`img`:case`image`:case`link`:Q(`error`,t),Q(`load`,t);break;case`details`:Q(`toggle`,t);break;case`input`:Q(`invalid`,t),Lt(t,r.value,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name,!0);break;case`select`:Q(`invalid`,t);break;case`textarea`:Q(`invalid`,t),Vt(t,r.value,r.defaultValue,r.children)}n=r.children,typeof n!=`string`&&typeof n!=`number`&&typeof n!=`bigint`||t.textContent===``+n||!0===r.suppressHydrationWarning||jd(t.textContent,n)?(r.popover!=null&&(Q(`beforetoggle`,t),Q(`toggle`,t)),r.onScroll!=null&&Q(`scroll`,t),r.onScrollEnd!=null&&Q(`scrollend`,t),r.onClick!=null&&(t.onclick=Xt),t=!0):t=!1,t||Fi(e,!0)}function Li(e){for(Ai=e.return;Ai;)switch(Ai.tag){case 5:case 31:case 13:Ni=!1;return;case 27:case 3:Ni=!0;return;default:Ai=Ai.return}}function Ri(e){if(e!==Ai)return!1;if(!V)return Li(e),V=!0,!1;var t=e.tag,n;if((n=t!==3&&t!==27)&&((n=t===5)&&(n=e.type,n=!(n!==`form`&&n!==`button`)||Hd(e.type,e.memoizedProps)),n=!n),n&&ji&&Fi(e),Li(e),t===13){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(317));ji=lf(e)}else if(t===31){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(317));ji=lf(e)}else t===27?(t=ji,Xd(e.type)?(e=cf,cf=null,ji=e):ji=t):ji=Ai?sf(e.stateNode.nextSibling):null;return!0}function zi(){ji=Ai=null,V=!1}function Bi(){var e=Mi;return e!==null&&(Xl===null?Xl=e:Xl.push.apply(Xl,e),Mi=null),e}function Vi(e){Mi===null?Mi=[e]:Mi.push(e)}var Hi=re(null),Ui=null,Wi=null;function Gi(e,t,n){I(Hi,t._currentValue),t._currentValue=n}function Ki(e){e._currentValue=Hi.current,ie(Hi)}function qi(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)===t?r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t):(e.childLanes|=t,r!==null&&(r.childLanes|=t)),e===n)break;e=e.return}}function Ji(e,t,n,r){var a=e.child;for(a!==null&&(a.return=e);a!==null;){var o=a.dependencies;if(o!==null){var s=a.child;o=o.firstContext;a:for(;o!==null;){var c=o;o=a;for(var l=0;l<t.length;l++)if(c.context===t[l]){o.lanes|=n,c=o.alternate,c!==null&&(c.lanes|=n),qi(o.return,n,e),r||(s=null);break a}o=c.next}}else if(a.tag===18){if(s=a.return,s===null)throw Error(i(341));s.lanes|=n,o=s.alternate,o!==null&&(o.lanes|=n),qi(s,n,e),s=null}else s=a.child;if(s!==null)s.return=a;else for(s=a;s!==null;){if(s===e){s=null;break}if(a=s.sibling,a!==null){a.return=s.return,s=a;break}s=s.return}a=s}}function Yi(e,t,n,r){e=null;for(var a=t,o=!1;a!==null;){if(!o){if(a.flags&524288)o=!0;else if(a.flags&262144)break}if(a.tag===10){var s=a.alternate;if(s===null)throw Error(i(387));if(s=s.memoizedProps,s!==null){var c=a.type;yr(a.pendingProps.value,s.value)||(e===null?e=[c]:e.push(c))}}else if(a===ce.current){if(s=a.alternate,s===null)throw Error(i(387));s.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(e===null?e=[Zf]:e.push(Zf))}a=a.return}e!==null&&Ji(t,e,n,r),t.flags|=262144}function Xi(e){for(e=e.firstContext;e!==null;){if(!yr(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function Zi(e){Ui=e,Wi=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function Qi(e){return ea(Ui,e)}function $i(e,t){return Ui===null&&Zi(e),ea(e,t)}function ea(e,t){var n=t._currentValue;if(t={context:t,memoizedValue:n,next:null},Wi===null){if(e===null)throw Error(i(308));Wi=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Wi=Wi.next=t;return n}var ta=typeof AbortController<`u`?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(t,n){e.push(n)}};this.abort=function(){t.aborted=!0,e.forEach(function(e){return e()})}},na=t.unstable_scheduleCallback,ra=t.unstable_NormalPriority,ia={$$typeof:x,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function aa(){return{controller:new ta,data:new Map,refCount:0}}function oa(e){e.refCount--,e.refCount===0&&na(ra,function(){e.controller.abort()})}var sa=null,ca=0,la=0,ua=null;function da(e,t){if(sa===null){var n=sa=[];ca=0,la=ud(),ua={status:`pending`,value:void 0,then:function(e){n.push(e)}}}return ca++,t.then(fa,fa),t}function fa(){if(--ca===0&&sa!==null){ua!==null&&(ua.status=`fulfilled`);var e=sa;sa=null,la=0,ua=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function pa(e,t){var n=[],r={status:`pending`,value:null,reason:null,then:function(e){n.push(e)}};return e.then(function(){r.status=`fulfilled`,r.value=t;for(var e=0;e<n.length;e++)(0,n[e])(t)},function(e){for(r.status=`rejected`,r.reason=e,e=0;e<n.length;e++)(0,n[e])(void 0)}),r}var ma=N.S;N.S=function(e,t){$l=we(),typeof t==`object`&&t&&typeof t.then==`function`&&da(e,t),ma!==null&&ma(e,t)};var ha=re(null);function ga(){var e=ha.current;return e===null?q.pooledCache:e}function _a(e,t){t===null?I(ha,ha.current):I(ha,t.pool)}function va(){var e=ga();return e===null?null:{parent:ia._currentValue,pool:e}}var ya=Error(i(460)),ba=Error(i(474)),xa=Error(i(542)),Sa={then:function(){}};function Ca(e){return e=e.status,e===`fulfilled`||e===`rejected`}function wa(e,t,n){switch(n=e[n],n===void 0?e.push(t):n!==t&&(t.then(Xt,Xt),t=n),t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Oa(e),e;default:if(typeof t.status==`string`)t.then(Xt,Xt);else{if(e=q,e!==null&&100<e.shellSuspendCounter)throw Error(i(482));e=t,e.status=`pending`,e.then(function(e){if(t.status===`pending`){var n=t;n.status=`fulfilled`,n.value=e}},function(e){if(t.status===`pending`){var n=t;n.status=`rejected`,n.reason=e}})}switch(t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Oa(e),e}throw Ea=t,ya}}function Ta(e){try{var t=e._init;return t(e._payload)}catch(e){throw typeof e==`object`&&e&&typeof e.then==`function`?(Ea=e,ya):e}}var Ea=null;function Da(){if(Ea===null)throw Error(i(459));var e=Ea;return Ea=null,e}function Oa(e){if(e===ya||e===xa)throw Error(i(483))}var ka=null,Aa=0;function ja(e){var t=Aa;return Aa+=1,ka===null&&(ka=[]),wa(ka,e,t)}function Ma(e,t){t=t.props.ref,e.ref=t===void 0?null:t}function Na(e,t){throw t.$$typeof===p?Error(i(525)):(e=Object.prototype.toString.call(t),Error(i(31,e===`[object Object]`?`object with keys {`+Object.keys(t).join(`, `)+`}`:e)))}function Pa(e){function t(t,n){if(e){var r=t.deletions;r===null?(t.deletions=[n],t.flags|=16):r.push(n)}}function n(n,r){if(!e)return null;for(;r!==null;)t(n,r),r=r.sibling;return null}function r(e){for(var t=new Map;e!==null;)e.key===null?t.set(e.index,e):t.set(e.key,e),e=e.sibling;return t}function a(e,t){return e=si(e,t),e.index=0,e.sibling=null,e}function o(t,n,r){return t.index=r,e?(r=t.alternate,r===null?(t.flags|=67108866,n):(r=r.index,r<n?(t.flags|=67108866,n):r)):(t.flags|=1048576,n)}function s(t){return e&&t.alternate===null&&(t.flags|=67108866),t}function c(e,t,n,r){return t===null||t.tag!==6?(t=di(n,e.mode,r),t.return=e,t):(t=a(t,n),t.return=e,t)}function l(e,t,n,r){var i=n.type;return i===_?d(e,t,n.props.children,r,n.key):t!==null&&(t.elementType===i||typeof i==`object`&&i&&i.$$typeof===E&&Ta(i)===t.type)?(t=a(t,n.props),Ma(t,n),t.return=e,t):(t=li(n.type,n.key,n.props,null,e.mode,r),Ma(t,n),t.return=e,t)}function u(e,t,n,r){return t===null||t.tag!==4||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?(t=pi(n,e.mode,r),t.return=e,t):(t=a(t,n.children||[]),t.return=e,t)}function d(e,t,n,r,i){return t===null||t.tag!==7?(t=ui(n,e.mode,r,i),t.return=e,t):(t=a(t,n),t.return=e,t)}function f(e,t,n){if(typeof t==`string`&&t!==``||typeof t==`number`||typeof t==`bigint`)return t=di(``+t,e.mode,n),t.return=e,t;if(typeof t==`object`&&t){switch(t.$$typeof){case h:return n=li(t.type,t.key,t.props,null,e.mode,n),Ma(n,t),n.return=e,n;case g:return t=pi(t,e.mode,n),t.return=e,t;case E:return t=Ta(t),f(e,t,n)}if(M(t)||A(t))return t=ui(t,e.mode,n,null),t.return=e,t;if(typeof t.then==`function`)return f(e,ja(t),n);if(t.$$typeof===x)return f(e,$i(e,t),n);Na(e,t)}return null}function p(e,t,n,r){var i=t===null?null:t.key;if(typeof n==`string`&&n!==``||typeof n==`number`||typeof n==`bigint`)return i===null?c(e,t,``+n,r):null;if(typeof n==`object`&&n){switch(n.$$typeof){case h:return n.key===i?l(e,t,n,r):null;case g:return n.key===i?u(e,t,n,r):null;case E:return n=Ta(n),p(e,t,n,r)}if(M(n)||A(n))return i===null?d(e,t,n,r,null):null;if(typeof n.then==`function`)return p(e,t,ja(n),r);if(n.$$typeof===x)return p(e,t,$i(e,n),r);Na(e,n)}return null}function m(e,t,n,r,i){if(typeof r==`string`&&r!==``||typeof r==`number`||typeof r==`bigint`)return e=e.get(n)||null,c(t,e,``+r,i);if(typeof r==`object`&&r){switch(r.$$typeof){case h:return e=e.get(r.key===null?n:r.key)||null,l(t,e,r,i);case g:return e=e.get(r.key===null?n:r.key)||null,u(t,e,r,i);case E:return r=Ta(r),m(e,t,n,r,i)}if(M(r)||A(r))return e=e.get(n)||null,d(t,e,r,i,null);if(typeof r.then==`function`)return m(e,t,n,ja(r),i);if(r.$$typeof===x)return m(e,t,n,$i(t,r),i);Na(t,r)}return null}function v(i,a,s,c){for(var l=null,u=null,d=a,h=a=0,g=null;d!==null&&h<s.length;h++){d.index>h?(g=d,d=null):g=d.sibling;var _=p(i,d,s[h],c);if(_===null){d===null&&(d=g);break}e&&d&&_.alternate===null&&t(i,d),a=o(_,a,h),u===null?l=_:u.sibling=_,u=_,d=g}if(h===s.length)return n(i,d),V&&Ti(i,h),l;if(d===null){for(;h<s.length;h++)d=f(i,s[h],c),d!==null&&(a=o(d,a,h),u===null?l=d:u.sibling=d,u=d);return V&&Ti(i,h),l}for(d=r(d);h<s.length;h++)g=m(d,i,h,s[h],c),g!==null&&(e&&g.alternate!==null&&d.delete(g.key===null?h:g.key),a=o(g,a,h),u===null?l=g:u.sibling=g,u=g);return e&&d.forEach(function(e){return t(i,e)}),V&&Ti(i,h),l}function y(a,s,c,l){if(c==null)throw Error(i(151));for(var u=null,d=null,h=s,g=s=0,_=null,v=c.next();h!==null&&!v.done;g++,v=c.next()){h.index>g?(_=h,h=null):_=h.sibling;var y=p(a,h,v.value,l);if(y===null){h===null&&(h=_);break}e&&h&&y.alternate===null&&t(a,h),s=o(y,s,g),d===null?u=y:d.sibling=y,d=y,h=_}if(v.done)return n(a,h),V&&Ti(a,g),u;if(h===null){for(;!v.done;g++,v=c.next())v=f(a,v.value,l),v!==null&&(s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return V&&Ti(a,g),u}for(h=r(h);!v.done;g++,v=c.next())v=m(h,a,g,v.value,l),v!==null&&(e&&v.alternate!==null&&h.delete(v.key===null?g:v.key),s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return e&&h.forEach(function(e){return t(a,e)}),V&&Ti(a,g),u}function b(e,r,o,c){if(typeof o==`object`&&o&&o.type===_&&o.key===null&&(o=o.props.children),typeof o==`object`&&o){switch(o.$$typeof){case h:a:{for(var l=o.key;r!==null;){if(r.key===l){if(l=o.type,l===_){if(r.tag===7){n(e,r.sibling),c=a(r,o.props.children),c.return=e,e=c;break a}}else if(r.elementType===l||typeof l==`object`&&l&&l.$$typeof===E&&Ta(l)===r.type){n(e,r.sibling),c=a(r,o.props),Ma(c,o),c.return=e,e=c;break a}n(e,r);break}else t(e,r);r=r.sibling}o.type===_?(c=ui(o.props.children,e.mode,c,o.key),c.return=e,e=c):(c=li(o.type,o.key,o.props,null,e.mode,c),Ma(c,o),c.return=e,e=c)}return s(e);case g:a:{for(l=o.key;r!==null;){if(r.key===l)if(r.tag===4&&r.stateNode.containerInfo===o.containerInfo&&r.stateNode.implementation===o.implementation){n(e,r.sibling),c=a(r,o.children||[]),c.return=e,e=c;break a}else{n(e,r);break}else t(e,r);r=r.sibling}c=pi(o,e.mode,c),c.return=e,e=c}return s(e);case E:return o=Ta(o),b(e,r,o,c)}if(M(o))return v(e,r,o,c);if(A(o)){if(l=A(o),typeof l!=`function`)throw Error(i(150));return o=l.call(o),y(e,r,o,c)}if(typeof o.then==`function`)return b(e,r,ja(o),c);if(o.$$typeof===x)return b(e,r,$i(e,o),c);Na(e,o)}return typeof o==`string`&&o!==``||typeof o==`number`||typeof o==`bigint`?(o=``+o,r!==null&&r.tag===6?(n(e,r.sibling),c=a(r,o),c.return=e,e=c):(n(e,r),c=di(o,e.mode,c),c.return=e,e=c),s(e)):n(e,r)}return function(e,t,n,r){try{Aa=0;var i=b(e,t,n,r);return ka=null,i}catch(t){if(t===ya||t===xa)throw t;var a=ai(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var Fa=Pa(!0),Ia=Pa(!1),La=!1;function Ra(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function za(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function Ba(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Va(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,K&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=ni(e),ti(e,null,n),t}return Qr(e,r,t,n),ni(e)}function Ha(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,n&4194048)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Xe(e,n)}}function Ua(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var Wa=!1;function Ga(){if(Wa){var e=ua;if(e!==null)throw e}}function Ka(e,t,n,r){Wa=!1;var i=e.updateQueue;La=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var c=s,l=c.next;c.next=null,o===null?a=l:o.next=l,o=c;var u=e.alternate;u!==null&&(u=u.updateQueue,s=u.lastBaseUpdate,s!==o&&(s===null?u.firstBaseUpdate=l:s.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;o=0,u=l=c=null,s=a;do{var p=s.lane&-536870913,m=p!==s.lane;if(m?(Y&p)===p:(r&p)===p){p!==0&&p===la&&(Wa=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var h=e,g=s;p=t;var _=n;switch(g.tag){case 1:if(h=g.payload,typeof h==`function`){d=h.call(_,d,p);break a}d=h;break a;case 3:h.flags=h.flags&-65537|128;case 0:if(h=g.payload,p=typeof h==`function`?h.call(_,d,p):h,p==null)break a;d=f({},d,p);break a;case 2:La=!0}}p=s.callback,p!==null&&(e.flags|=64,m&&(e.flags|=8192),m=i.callbacks,m===null?i.callbacks=[p]:m.push(p))}else m={lane:p,tag:s.tag,payload:s.payload,callback:s.callback,next:null},u===null?(l=u=m,c=d):u=u.next=m,o|=p;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;m=s,s=m.next,m.next=null,i.lastBaseUpdate=m,i.shared.pending=null}}while(1);u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,a===null&&(i.shared.lanes=0),Wl|=o,e.lanes=o,e.memoizedState=d}}function qa(e,t){if(typeof e!=`function`)throw Error(i(191,e));e.call(t)}function Ja(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;e<n.length;e++)qa(n[e],t)}var Ya=re(null),Xa=re(0);function Za(e,t){e=Hl,I(Xa,e),I(Ya,t),Hl=e|t.baseLanes}function Qa(){I(Xa,Hl),I(Ya,Ya.current)}function $a(){Hl=Xa.current,ie(Ya),ie(Xa)}var eo=re(null),to=null;function no(e){var t=e.alternate;I(so,so.current&1),I(eo,e),to===null&&(t===null||Ya.current!==null||t.memoizedState!==null)&&(to=e)}function ro(e){I(so,so.current),I(eo,e),to===null&&(to=e)}function io(e){e.tag===22?(I(so,so.current),I(eo,e),to===null&&(to=e)):ao(e)}function ao(){I(so,so.current),I(eo,eo.current)}function oo(e){ie(eo),to===e&&(to=null),ie(so)}var so=re(0);function co(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||rf(n)||af(n)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder===`forwards`||t.memoizedProps.revealOrder===`backwards`||t.memoizedProps.revealOrder===`unstable_legacy-backwards`||t.memoizedProps.revealOrder===`together`)){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var lo=0,H=null,U=null,W=null,uo=!1,fo=!1,po=!1,mo=0,ho=0,go=null,_o=0;function vo(){throw Error(i(321))}function yo(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!yr(e[n],t[n]))return!1;return!0}function bo(e,t,n,r,i,a){return lo=a,H=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,N.H=e===null||e.memoizedState===null?Is:Ls,po=!1,a=n(r,i),po=!1,fo&&(a=So(t,n,r,i)),xo(e),a}function xo(e){N.H=Fs;var t=U!==null&&U.next!==null;if(lo=0,W=U=H=null,uo=!1,ho=0,go=null,t)throw Error(i(300));e===null||ec||(e=e.dependencies,e!==null&&Xi(e)&&(ec=!0))}function So(e,t,n,r){H=e;var a=0;do{if(fo&&(go=null),ho=0,fo=!1,25<=a)throw Error(i(301));if(a+=1,W=U=null,e.updateQueue!=null){var o=e.updateQueue;o.lastEffect=null,o.events=null,o.stores=null,o.memoCache!=null&&(o.memoCache.index=0)}N.H=Rs,o=t(n,r)}while(fo);return o}function Co(){var e=N.H,t=e.useState()[0];return t=typeof t.then==`function`?ko(t):t,e=e.useState()[0],(U===null?null:U.memoizedState)!==e&&(H.flags|=1024),t}function wo(){var e=mo!==0;return mo=0,e}function To(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function Eo(e){if(uo){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}uo=!1}lo=0,W=U=H=null,fo=!1,ho=mo=0,go=null}function Do(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return W===null?H.memoizedState=W=e:W=W.next=e,W}function G(){if(U===null){var e=H.alternate;e=e===null?null:e.memoizedState}else e=U.next;var t=W===null?H.memoizedState:W.next;if(t!==null)W=t,U=e;else{if(e===null)throw H.alternate===null?Error(i(467)):Error(i(310));U=e,e={memoizedState:U.memoizedState,baseState:U.baseState,baseQueue:U.baseQueue,queue:U.queue,next:null},W===null?H.memoizedState=W=e:W=W.next=e}return W}function Oo(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function ko(e){var t=ho;return ho+=1,go===null&&(go=[]),e=wa(go,e,t),t=H,(W===null?t.memoizedState:W.next)===null&&(t=t.alternate,N.H=t===null||t.memoizedState===null?Is:Ls),e}function Ao(e){if(typeof e==`object`&&e){if(typeof e.then==`function`)return ko(e);if(e.$$typeof===x)return Qi(e)}throw Error(i(438,String(e)))}function jo(e){var t=null,n=H.updateQueue;if(n!==null&&(t=n.memoCache),t==null){var r=H.alternate;r!==null&&(r=r.updateQueue,r!==null&&(r=r.memoCache,r!=null&&(t={data:r.data.map(function(e){return e.slice()}),index:0})))}if(t==null&&(t={data:[],index:0}),n===null&&(n=Oo(),H.updateQueue=n),n.memoCache=t,n=t.data[t.index],n===void 0)for(n=t.data[t.index]=Array(e),r=0;r<e;r++)n[r]=O;return t.index++,n}function Mo(e,t){return typeof t==`function`?t(e):t}function No(e){return Po(G(),U,e)}function Po(e,t,n){var r=e.queue;if(r===null)throw Error(i(311));r.lastRenderedReducer=n;var a=e.baseQueue,o=r.pending;if(o!==null){if(a!==null){var s=a.next;a.next=o.next,o.next=s}t.baseQueue=a=o,r.pending=null}if(o=e.baseState,a===null)e.memoizedState=o;else{t=a.next;var c=s=null,l=null,u=t,d=!1;do{var f=u.lane&-536870913;if(f===u.lane?(lo&f)===f:(Y&f)===f){var p=u.revertLane;if(p===0)l!==null&&(l=l.next={lane:0,revertLane:0,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),f===la&&(d=!0);else if((lo&p)===p){u=u.next,p===la&&(d=!0);continue}else f={lane:0,revertLane:u.revertLane,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=f,s=o):l=l.next=f,H.lanes|=p,Wl|=p;f=u.action,po&&n(o,f),o=u.hasEagerState?u.eagerState:n(o,f)}else p={lane:f,revertLane:u.revertLane,gesture:u.gesture,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=p,s=o):l=l.next=p,H.lanes|=f,Wl|=f;u=u.next}while(u!==null&&u!==t);if(l===null?s=o:l.next=c,!yr(o,e.memoizedState)&&(ec=!0,d&&(n=ua,n!==null)))throw n;e.memoizedState=o,e.baseState=s,e.baseQueue=l,r.lastRenderedState=o}return a===null&&(r.lanes=0),[e.memoizedState,r.dispatch]}function Fo(e){var t=G(),n=t.queue;if(n===null)throw Error(i(311));n.lastRenderedReducer=e;var r=n.dispatch,a=n.pending,o=t.memoizedState;if(a!==null){n.pending=null;var s=a=a.next;do o=e(o,s.action),s=s.next;while(s!==a);yr(o,t.memoizedState)||(ec=!0),t.memoizedState=o,t.baseQueue===null&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function Io(e,t,n){var r=H,a=G(),o=V;if(o){if(n===void 0)throw Error(i(407));n=n()}else n=t();var s=!yr((U||a).memoizedState,n);if(s&&(a.memoizedState=n,ec=!0),a=a.queue,ss(zo.bind(null,r,a,e),[e]),a.getSnapshot!==t||s||W!==null&&W.memoizedState.tag&1){if(r.flags|=2048,ns(9,{destroy:void 0},Ro.bind(null,r,a,n,t),null),q===null)throw Error(i(349));o||lo&127||Lo(r,t,n)}return n}function Lo(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=H.updateQueue,t===null?(t=Oo(),H.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Ro(e,t,n,r){t.value=n,t.getSnapshot=r,Bo(t)&&Vo(e)}function zo(e,t,n){return n(function(){Bo(t)&&Vo(e)})}function Bo(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!yr(e,n)}catch{return!0}}function Vo(e){var t=ei(e,2);t!==null&&mu(t,e,2)}function Ho(e){var t=Do();if(typeof e==`function`){var n=e;if(e=n(),po){Ne(!0);try{n()}finally{Ne(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Mo,lastRenderedState:e},t}function Uo(e,t,n,r){return e.baseState=n,Po(e,U,typeof r==`function`?r:Mo)}function Wo(e,t,n,r,a){if(Ms(e))throw Error(i(485));if(e=t.action,e!==null){var o={payload:a,action:e,next:null,isTransition:!0,status:`pending`,value:null,reason:null,listeners:[],then:function(e){o.listeners.push(e)}};N.T===null?o.isTransition=!1:n(!0),r(o),n=t.pending,n===null?(o.next=t.pending=o,Go(t,o)):(o.next=n.next,t.pending=n.next=o)}}function Go(e,t){var n=t.action,r=t.payload,i=e.state;if(t.isTransition){var a=N.T,o={};N.T=o;try{var s=n(i,r),c=N.S;c!==null&&c(o,s),Ko(e,t,s)}catch(n){Jo(e,t,n)}finally{a!==null&&o.types!==null&&(a.types=o.types),N.T=a}}else try{a=n(i,r),Ko(e,t,a)}catch(n){Jo(e,t,n)}}function Ko(e,t,n){typeof n==`object`&&n&&typeof n.then==`function`?n.then(function(n){qo(e,t,n)},function(n){return Jo(e,t,n)}):qo(e,t,n)}function qo(e,t,n){t.status=`fulfilled`,t.value=n,Yo(t),e.state=n,t=e.pending,t!==null&&(n=t.next,n===t?e.pending=null:(n=n.next,t.next=n,Go(e,n)))}function Jo(e,t,n){var r=e.pending;if(e.pending=null,r!==null){r=r.next;do t.status=`rejected`,t.reason=n,Yo(t),t=t.next;while(t!==r)}e.action=null}function Yo(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function Xo(e,t){return t}function Zo(e,t){if(V){var n=q.formState;if(n!==null){a:{var r=H;if(V){if(ji){b:{for(var i=ji,a=Ni;i.nodeType!==8;){if(!a){i=null;break b}if(i=sf(i.nextSibling),i===null){i=null;break b}}a=i.data,i=a===`F!`||a===`F`?i:null}if(i){ji=sf(i.nextSibling),r=i.data===`F!`;break a}}Fi(r)}r=!1}r&&(t=n[0])}}return n=Do(),n.memoizedState=n.baseState=t,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Xo,lastRenderedState:t},n.queue=r,n=ks.bind(null,H,r),r.dispatch=n,r=Ho(!1),a=js.bind(null,H,!1,r.queue),r=Do(),i={state:t,dispatch:null,action:e,pending:null},r.queue=i,n=Wo.bind(null,H,i,a,n),i.dispatch=n,r.memoizedState=e,[t,n,!1]}function Qo(e){return $o(G(),U,e)}function $o(e,t,n){if(t=Po(e,t,Xo)[0],e=No(Mo)[0],typeof t==`object`&&t&&typeof t.then==`function`)try{var r=ko(t)}catch(e){throw e===ya?xa:e}else r=t;t=G();var i=t.queue,a=i.dispatch;return n!==t.memoizedState&&(H.flags|=2048,ns(9,{destroy:void 0},es.bind(null,i,n),null)),[r,a,e]}function es(e,t){e.action=t}function ts(e){var t=G(),n=U;if(n!==null)return $o(t,n,e);G(),t=t.memoizedState,n=G();var r=n.queue.dispatch;return n.memoizedState=e,[t,r,!1]}function ns(e,t,n,r){return e={tag:e,create:n,deps:r,inst:t,next:null},t=H.updateQueue,t===null&&(t=Oo(),H.updateQueue=t),n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function rs(){return G().memoizedState}function is(e,t,n,r){var i=Do();H.flags|=e,i.memoizedState=ns(1|t,{destroy:void 0},n,r===void 0?null:r)}function as(e,t,n,r){var i=G();r=r===void 0?null:r;var a=i.memoizedState.inst;U!==null&&r!==null&&yo(r,U.memoizedState.deps)?i.memoizedState=ns(t,a,n,r):(H.flags|=e,i.memoizedState=ns(1|t,a,n,r))}function os(e,t){is(8390656,8,e,t)}function ss(e,t){as(2048,8,e,t)}function cs(e){H.flags|=4;var t=H.updateQueue;if(t===null)t=Oo(),H.updateQueue=t,t.events=[e];else{var n=t.events;n===null?t.events=[e]:n.push(e)}}function ls(e){var t=G().memoizedState;return cs({ref:t,nextImpl:e}),function(){if(K&2)throw Error(i(440));return t.impl.apply(void 0,arguments)}}function us(e,t){return as(4,2,e,t)}function ds(e,t){return as(4,4,e,t)}function fs(e,t){if(typeof t==`function`){e=e();var n=t(e);return function(){typeof n==`function`?n():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function ps(e,t,n){n=n==null?null:n.concat([e]),as(4,4,fs.bind(null,t,e),n)}function ms(){}function hs(e,t){var n=G();t=t===void 0?null:t;var r=n.memoizedState;return t!==null&&yo(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function gs(e,t){var n=G();t=t===void 0?null:t;var r=n.memoizedState;if(t!==null&&yo(t,r[1]))return r[0];if(r=e(),po){Ne(!0);try{e()}finally{Ne(!1)}}return n.memoizedState=[r,t],r}function _s(e,t,n){return n===void 0||lo&1073741824&&!(Y&261930)?e.memoizedState=t:(e.memoizedState=n,e=pu(),H.lanes|=e,Wl|=e,n)}function vs(e,t,n,r){return yr(n,t)?n:Ya.current===null?!(lo&42)||lo&1073741824&&!(Y&261930)?(ec=!0,e.memoizedState=n):(e=pu(),H.lanes|=e,Wl|=e,t):(e=_s(e,n,r),yr(e,t)||(ec=!0),e)}function ys(e,t,n,r,i){var a=P.p;P.p=a!==0&&8>a?a:8;var o=N.T,s={};N.T=s,js(e,!1,t,n);try{var c=i(),l=N.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?As(e,t,pa(c,r),fu(e)):As(e,t,r,fu(e))}catch(n){As(e,t,{then:function(){},status:`rejected`,reason:n},fu())}finally{P.p=a,o!==null&&s.types!==null&&(o.types=s.types),N.T=o}}function bs(){}function xs(e,t,n,r){if(e.tag!==5)throw Error(i(476));var a=Ss(e).queue;ys(e,a,t,F,n===null?bs:function(){return Cs(e),n(r)})}function Ss(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:F,baseState:F,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Mo,lastRenderedState:F},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Mo,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function Cs(e){var t=Ss(e);t.next===null&&(t=e.alternate.memoizedState),As(e,t.next.queue,{},fu())}function ws(){return Qi(Zf)}function Ts(){return G().memoizedState}function Es(){return G().memoizedState}function Ds(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=fu();e=Ba(n);var r=Va(t,e,n);r!==null&&(mu(r,t,n),Ha(r,t,n)),t={cache:aa()},e.payload=t;return}t=t.return}}function Os(e,t,n){var r=fu();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},Ms(e)?Ns(t,n):(n=$r(e,t,n,r),n!==null&&(mu(n,e,r),Ps(n,t,r)))}function ks(e,t,n){As(e,t,n,fu())}function As(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(Ms(e))Ns(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,yr(s,o))return Qr(e,t,i,0),q===null&&Zr(),!1}catch{}if(n=$r(e,t,i,r),n!==null)return mu(n,e,r),Ps(n,t,r),!0}return!1}function js(e,t,n,r){if(r={lane:2,revertLane:ud(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},Ms(e)){if(t)throw Error(i(479))}else t=$r(e,n,r,2),t!==null&&mu(t,e,2)}function Ms(e){var t=e.alternate;return e===H||t!==null&&t===H}function Ns(e,t){fo=uo=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Ps(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Xe(e,n)}}var Fs={readContext:Qi,use:Ao,useCallback:vo,useContext:vo,useEffect:vo,useImperativeHandle:vo,useLayoutEffect:vo,useInsertionEffect:vo,useMemo:vo,useReducer:vo,useRef:vo,useState:vo,useDebugValue:vo,useDeferredValue:vo,useTransition:vo,useSyncExternalStore:vo,useId:vo,useHostTransitionStatus:vo,useFormState:vo,useActionState:vo,useOptimistic:vo,useMemoCache:vo,useCacheRefresh:vo};Fs.useEffectEvent=vo;var Is={readContext:Qi,use:Ao,useCallback:function(e,t){return Do().memoizedState=[e,t===void 0?null:t],e},useContext:Qi,useEffect:os,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),is(4194308,4,fs.bind(null,t,e),n)},useLayoutEffect:function(e,t){return is(4194308,4,e,t)},useInsertionEffect:function(e,t){is(4,2,e,t)},useMemo:function(e,t){var n=Do();t=t===void 0?null:t;var r=e();if(po){Ne(!0);try{e()}finally{Ne(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=Do();if(n!==void 0){var i=n(t);if(po){Ne(!0);try{n(t)}finally{Ne(!1)}}}else i=t;return r.memoizedState=r.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},r.queue=e,e=e.dispatch=Os.bind(null,H,e),[r.memoizedState,e]},useRef:function(e){var t=Do();return e={current:e},t.memoizedState=e},useState:function(e){e=Ho(e);var t=e.queue,n=ks.bind(null,H,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:ms,useDeferredValue:function(e,t){return _s(Do(),e,t)},useTransition:function(){var e=Ho(!1);return e=ys.bind(null,H,e.queue,!0,!1),Do().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=H,a=Do();if(V){if(n===void 0)throw Error(i(407));n=n()}else{if(n=t(),q===null)throw Error(i(349));Y&127||Lo(r,t,n)}a.memoizedState=n;var o={value:n,getSnapshot:t};return a.queue=o,os(zo.bind(null,r,o,e),[e]),r.flags|=2048,ns(9,{destroy:void 0},Ro.bind(null,r,o,n,t),null),n},useId:function(){var e=Do(),t=q.identifierPrefix;if(V){var n=wi,r=Ci;n=(r&~(1<<32-Pe(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=mo++,0<n&&(t+=`H`+n.toString(32)),t+=`_`}else n=_o++,t=`_`+t+`r_`+n.toString(32)+`_`;return e.memoizedState=t},useHostTransitionStatus:ws,useFormState:Zo,useActionState:Zo,useOptimistic:function(e){var t=Do();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=js.bind(null,H,!0,n),n.dispatch=t,[e,t]},useMemoCache:jo,useCacheRefresh:function(){return Do().memoizedState=Ds.bind(null,H)},useEffectEvent:function(e){var t=Do(),n={impl:e};return t.memoizedState=n,function(){if(K&2)throw Error(i(440));return n.impl.apply(void 0,arguments)}}},Ls={readContext:Qi,use:Ao,useCallback:hs,useContext:Qi,useEffect:ss,useImperativeHandle:ps,useInsertionEffect:us,useLayoutEffect:ds,useMemo:gs,useReducer:No,useRef:rs,useState:function(){return No(Mo)},useDebugValue:ms,useDeferredValue:function(e,t){return vs(G(),U.memoizedState,e,t)},useTransition:function(){var e=No(Mo)[0],t=G().memoizedState;return[typeof e==`boolean`?e:ko(e),t]},useSyncExternalStore:Io,useId:Ts,useHostTransitionStatus:ws,useFormState:Qo,useActionState:Qo,useOptimistic:function(e,t){return Uo(G(),U,e,t)},useMemoCache:jo,useCacheRefresh:Es};Ls.useEffectEvent=ls;var Rs={readContext:Qi,use:Ao,useCallback:hs,useContext:Qi,useEffect:ss,useImperativeHandle:ps,useInsertionEffect:us,useLayoutEffect:ds,useMemo:gs,useReducer:Fo,useRef:rs,useState:function(){return Fo(Mo)},useDebugValue:ms,useDeferredValue:function(e,t){var n=G();return U===null?_s(n,e,t):vs(n,U.memoizedState,e,t)},useTransition:function(){var e=Fo(Mo)[0],t=G().memoizedState;return[typeof e==`boolean`?e:ko(e),t]},useSyncExternalStore:Io,useId:Ts,useHostTransitionStatus:ws,useFormState:ts,useActionState:ts,useOptimistic:function(e,t){var n=G();return U===null?(n.baseState=e,[e,n.queue.dispatch]):Uo(n,U,e,t)},useMemoCache:jo,useCacheRefresh:Es};Rs.useEffectEvent=ls;function zs(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:f({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Bs={enqueueSetState:function(e,t,n){e=e._reactInternals;var r=fu(),i=Ba(r);i.payload=t,n!=null&&(i.callback=n),t=Va(e,i,r),t!==null&&(mu(t,e,r),Ha(t,e,r))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=fu(),i=Ba(r);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=Va(e,i,r),t!==null&&(mu(t,e,r),Ha(t,e,r))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=fu(),r=Ba(n);r.tag=2,t!=null&&(r.callback=t),t=Va(e,r,n),t!==null&&(mu(t,e,n),Ha(t,e,n))}};function Vs(e,t,n,r,i,a,o){return e=e.stateNode,typeof e.shouldComponentUpdate==`function`?e.shouldComponentUpdate(r,a,o):t.prototype&&t.prototype.isPureReactComponent?!br(n,r)||!br(i,a):!0}function Hs(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps==`function`&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps==`function`&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&Bs.enqueueReplaceState(t,t.state,null)}function Us(e,t){var n=t;if(`ref`in t)for(var r in n={},t)r!==`ref`&&(n[r]=t[r]);if(e=e.defaultProps)for(var i in n===t&&(n=f({},n)),e)n[i]===void 0&&(n[i]=e[i]);return n}function Ws(e){qr(e)}function Gs(e){console.error(e)}function Ks(e){qr(e)}function qs(e,t){try{var n=e.onUncaughtError;n(t.value,{componentStack:t.stack})}catch(e){setTimeout(function(){throw e})}}function Js(e,t,n){try{var r=e.onCaughtError;r(n.value,{componentStack:n.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(e){setTimeout(function(){throw e})}}function Ys(e,t,n){return n=Ba(n),n.tag=3,n.payload={element:null},n.callback=function(){qs(e,t)},n}function Xs(e){return e=Ba(e),e.tag=3,e}function Zs(e,t,n,r){var i=n.type.getDerivedStateFromError;if(typeof i==`function`){var a=r.value;e.payload=function(){return i(a)},e.callback=function(){Js(t,n,r)}}var o=n.stateNode;o!==null&&typeof o.componentDidCatch==`function`&&(e.callback=function(){Js(t,n,r),typeof i!=`function`&&(nu===null?nu=new Set([this]):nu.add(this));var e=r.stack;this.componentDidCatch(r.value,{componentStack:e===null?``:e})})}function Qs(e,t,n,r,a){if(n.flags|=32768,typeof r==`object`&&r&&typeof r.then==`function`){if(t=n.alternate,t!==null&&Yi(t,n,a,!0),n=eo.current,n!==null){switch(n.tag){case 31:case 13:return to===null?Eu():n.alternate===null&&Ul===0&&(Ul=3),n.flags&=-257,n.flags|=65536,n.lanes=a,r===Sa?n.flags|=16384:(t=n.updateQueue,t===null?n.updateQueue=new Set([r]):t.add(r),Wu(e,r,a)),!1;case 22:return n.flags|=65536,r===Sa?n.flags|=16384:(t=n.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([r])},n.updateQueue=t):(n=t.retryQueue,n===null?t.retryQueue=new Set([r]):n.add(r)),Wu(e,r,a)),!1}throw Error(i(435,n.tag))}return Wu(e,r,a),Eu(),!1}if(V)return t=eo.current,t===null?(r!==Pi&&(t=Error(i(423),{cause:r}),Vi(hi(t,n))),e=e.current.alternate,e.flags|=65536,a&=-a,e.lanes|=a,r=hi(r,n),a=Ys(e.stateNode,r,a),Ua(e,a),Ul!==4&&(Ul=2)):(!(t.flags&65536)&&(t.flags|=256),t.flags|=65536,t.lanes=a,r!==Pi&&(e=Error(i(422),{cause:r}),Vi(hi(e,n)))),!1;var o=Error(i(520),{cause:r});if(o=hi(o,n),Yl===null?Yl=[o]:Yl.push(o),Ul!==4&&(Ul=2),t===null)return!0;r=hi(r,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=a&-a,n.lanes|=e,e=Ys(n.stateNode,r,e),Ua(n,e),!1;case 1:if(t=n.type,o=n.stateNode,!(n.flags&128)&&(typeof t.getDerivedStateFromError==`function`||o!==null&&typeof o.componentDidCatch==`function`&&(nu===null||!nu.has(o))))return n.flags|=65536,a&=-a,n.lanes|=a,a=Xs(a),Zs(a,e,n,r),Ua(n,a),!1}n=n.return}while(n!==null);return!1}var $s=Error(i(461)),ec=!1;function tc(e,t,n,r){t.child=e===null?Ia(t,null,n,r):Fa(t,e.child,n,r)}function nc(e,t,n,r,i){n=n.render;var a=t.ref;if(`ref`in r){var o={};for(var s in r)s!==`ref`&&(o[s]=r[s])}else o=r;return Zi(t),r=bo(e,t,n,o,a,i),s=wo(),e!==null&&!ec?(To(e,t,i),Ec(e,t,i)):(V&&s&&Di(t),t.flags|=1,tc(e,t,r,i),t.child)}function rc(e,t,n,r,i){if(e===null){var a=n.type;return typeof a==`function`&&!oi(a)&&a.defaultProps===void 0&&n.compare===null?(t.tag=15,t.type=a,ic(e,t,a,r,i)):(e=li(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!Dc(e,i)){var o=a.memoizedProps;if(n=n.compare,n=n===null?br:n,n(o,r)&&e.ref===t.ref)return Ec(e,t,i)}return t.flags|=1,e=si(a,r),e.ref=t.ref,e.return=t,t.child=e}function ic(e,t,n,r,i){if(e!==null){var a=e.memoizedProps;if(br(a,r)&&e.ref===t.ref)if(ec=!1,t.pendingProps=r=a,Dc(e,i))e.flags&131072&&(ec=!0);else return t.lanes=e.lanes,Ec(e,t,i)}return fc(e,t,n,r,i)}function ac(e,t,n,r){var i=r.children,a=e===null?null:e.memoizedState;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),r.mode===`hidden`){if(t.flags&128){if(a=a===null?n:a.baseLanes|n,e!==null){for(r=t.child=e.child,i=0;r!==null;)i=i|r.lanes|r.childLanes,r=r.sibling;r=i&~a}else r=0,t.child=null;return sc(e,t,a,n,r)}if(n&536870912)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&_a(t,a===null?null:a.cachePool),a===null?Qa():Za(t,a),io(t);else return r=t.lanes=536870912,sc(e,t,a===null?n:a.baseLanes|n,n,r)}else a===null?(e!==null&&_a(t,null),Qa(),ao(t)):(_a(t,a.cachePool),Za(t,a),ao(t),t.memoizedState=null);return tc(e,t,i,n),t.child}function oc(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function sc(e,t,n,r,i){var a=ga();return a=a===null?null:{parent:ia._currentValue,pool:a},t.memoizedState={baseLanes:n,cachePool:a},e!==null&&_a(t,null),Qa(),io(t),e!==null&&Yi(e,t,r,!0),t.childLanes=i,null}function cc(e,t){return t=xc({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function lc(e,t,n){return Fa(t,e.child,null,n),e=cc(t,t.pendingProps),e.flags|=2,oo(t),t.memoizedState=null,e}function uc(e,t,n){var r=t.pendingProps,a=(t.flags&128)!=0;if(t.flags&=-129,e===null){if(V){if(r.mode===`hidden`)return e=cc(t,r),t.lanes=536870912,oc(null,e);if(ro(t),(e=ji)?(e=nf(e,Ni),e=e!==null&&e.data===`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Si===null?null:{id:Ci,overflow:wi},retryLane:536870912,hydrationErrors:null},n=fi(e),n.return=t,t.child=n,Ai=t,ji=null)):e=null,e===null)throw Fi(t);return t.lanes=536870912,null}return cc(t,r)}var o=e.memoizedState;if(o!==null){var s=o.dehydrated;if(ro(t),a)if(t.flags&256)t.flags&=-257,t=lc(e,t,n);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(i(558));else if(ec||Yi(e,t,n,!1),a=(n&e.childLanes)!==0,ec||a){if(r=q,r!==null&&(s=Ze(r,n),s!==0&&s!==o.retryLane))throw o.retryLane=s,ei(e,s),mu(r,e,s),$s;Eu(),t=lc(e,t,n)}else e=o.treeContext,ji=sf(s.nextSibling),Ai=t,V=!0,Mi=null,Ni=!1,e!==null&&ki(t,e),t=cc(t,r),t.flags|=4096;return t}return e=si(e.child,{mode:r.mode,children:r.children}),e.ref=t.ref,t.child=e,e.return=t,e}function dc(e,t){var n=t.ref;if(n===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof n!=`function`&&typeof n!=`object`)throw Error(i(284));(e===null||e.ref!==n)&&(t.flags|=4194816)}}function fc(e,t,n,r,i){return Zi(t),n=bo(e,t,n,r,void 0,i),r=wo(),e!==null&&!ec?(To(e,t,i),Ec(e,t,i)):(V&&r&&Di(t),t.flags|=1,tc(e,t,n,i),t.child)}function pc(e,t,n,r,i,a){return Zi(t),t.updateQueue=null,n=So(t,r,n,i),xo(e),r=wo(),e!==null&&!ec?(To(e,t,a),Ec(e,t,a)):(V&&r&&Di(t),t.flags|=1,tc(e,t,n,a),t.child)}function mc(e,t,n,r,i){if(Zi(t),t.stateNode===null){var a=ri,o=n.contextType;typeof o==`object`&&o&&(a=Qi(o)),a=new n(r,a),t.memoizedState=a.state!==null&&a.state!==void 0?a.state:null,a.updater=Bs,t.stateNode=a,a._reactInternals=t,a=t.stateNode,a.props=r,a.state=t.memoizedState,a.refs={},Ra(t),o=n.contextType,a.context=typeof o==`object`&&o?Qi(o):ri,a.state=t.memoizedState,o=n.getDerivedStateFromProps,typeof o==`function`&&(zs(t,n,o,r),a.state=t.memoizedState),typeof n.getDerivedStateFromProps==`function`||typeof a.getSnapshotBeforeUpdate==`function`||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(o=a.state,typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount(),o!==a.state&&Bs.enqueueReplaceState(a,a.state,null),Ka(t,r,a,i),Ga(),a.state=t.memoizedState),typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!0}else if(e===null){a=t.stateNode;var s=t.memoizedProps,c=Us(n,s);a.props=c;var l=a.context,u=n.contextType;o=ri,typeof u==`object`&&u&&(o=Qi(u));var d=n.getDerivedStateFromProps;u=typeof d==`function`||typeof a.getSnapshotBeforeUpdate==`function`,s=t.pendingProps!==s,u||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(s||l!==o)&&Hs(t,a,r,o),La=!1;var f=t.memoizedState;a.state=f,Ka(t,r,a,i),Ga(),l=t.memoizedState,s||f!==l||La?(typeof d==`function`&&(zs(t,n,d,r),l=t.memoizedState),(c=La||Vs(t,n,c,r,f,l,o))?(u||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount()),typeof a.componentDidMount==`function`&&(t.flags|=4194308)):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=o,r=c):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!1)}else{a=t.stateNode,za(e,t),o=t.memoizedProps,u=Us(n,o),a.props=u,d=t.pendingProps,f=a.context,l=n.contextType,c=ri,typeof l==`object`&&l&&(c=Qi(l)),s=n.getDerivedStateFromProps,(l=typeof s==`function`||typeof a.getSnapshotBeforeUpdate==`function`)||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(o!==d||f!==c)&&Hs(t,a,r,c),La=!1,f=t.memoizedState,a.state=f,Ka(t,r,a,i),Ga();var p=t.memoizedState;o!==d||f!==p||La||e!==null&&e.dependencies!==null&&Xi(e.dependencies)?(typeof s==`function`&&(zs(t,n,s,r),p=t.memoizedState),(u=La||Vs(t,n,u,r,f,p,c)||e!==null&&e.dependencies!==null&&Xi(e.dependencies))?(l||typeof a.UNSAFE_componentWillUpdate!=`function`&&typeof a.componentWillUpdate!=`function`||(typeof a.componentWillUpdate==`function`&&a.componentWillUpdate(r,p,c),typeof a.UNSAFE_componentWillUpdate==`function`&&a.UNSAFE_componentWillUpdate(r,p,c)),typeof a.componentDidUpdate==`function`&&(t.flags|=4),typeof a.getSnapshotBeforeUpdate==`function`&&(t.flags|=1024)):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=p),a.props=r,a.state=p,a.context=c,r=u):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return a=r,dc(e,t),r=(t.flags&128)!=0,a||r?(a=t.stateNode,n=r&&typeof n.getDerivedStateFromError!=`function`?null:a.render(),t.flags|=1,e!==null&&r?(t.child=Fa(t,e.child,null,i),t.child=Fa(t,null,n,i)):tc(e,t,n,i),t.memoizedState=a.state,e=t.child):e=Ec(e,t,i),e}function hc(e,t,n,r){return zi(),t.flags|=256,tc(e,t,n,r),t.child}var gc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function _c(e){return{baseLanes:e,cachePool:va()}}function vc(e,t,n){return e=e===null?0:e.childLanes&~n,t&&(e|=ql),e}function yc(e,t,n){var r=t.pendingProps,a=!1,o=(t.flags&128)!=0,s;if((s=o)||(s=e!==null&&e.memoizedState===null?!1:(so.current&2)!=0),s&&(a=!0,t.flags&=-129),s=(t.flags&32)!=0,t.flags&=-33,e===null){if(V){if(a?no(t):ao(t),(e=ji)?(e=nf(e,Ni),e=e!==null&&e.data!==`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Si===null?null:{id:Ci,overflow:wi},retryLane:536870912,hydrationErrors:null},n=fi(e),n.return=t,t.child=n,Ai=t,ji=null)):e=null,e===null)throw Fi(t);return af(e)?t.lanes=32:t.lanes=536870912,null}var c=r.children;return r=r.fallback,a?(ao(t),a=t.mode,c=xc({mode:`hidden`,children:c},a),r=ui(r,a,n,null),c.return=t,r.return=t,c.sibling=r,t.child=c,r=t.child,r.memoizedState=_c(n),r.childLanes=vc(e,s,n),t.memoizedState=gc,oc(null,r)):(no(t),bc(t,c))}var l=e.memoizedState;if(l!==null&&(c=l.dehydrated,c!==null)){if(o)t.flags&256?(no(t),t.flags&=-257,t=Sc(e,t,n)):t.memoizedState===null?(ao(t),c=r.fallback,a=t.mode,r=xc({mode:`visible`,children:r.children},a),c=ui(c,a,n,null),c.flags|=2,r.return=t,c.return=t,r.sibling=c,t.child=r,Fa(t,e.child,null,n),r=t.child,r.memoizedState=_c(n),r.childLanes=vc(e,s,n),t.memoizedState=gc,t=oc(null,r)):(ao(t),t.child=e.child,t.flags|=128,t=null);else if(no(t),af(c)){if(s=c.nextSibling&&c.nextSibling.dataset,s)var u=s.dgst;s=u,r=Error(i(419)),r.stack=``,r.digest=s,Vi({value:r,source:null,stack:null}),t=Sc(e,t,n)}else if(ec||Yi(e,t,n,!1),s=(n&e.childLanes)!==0,ec||s){if(s=q,s!==null&&(r=Ze(s,n),r!==0&&r!==l.retryLane))throw l.retryLane=r,ei(e,r),mu(s,e,r),$s;rf(c)||Eu(),t=Sc(e,t,n)}else rf(c)?(t.flags|=192,t.child=e.child,t=null):(e=l.treeContext,ji=sf(c.nextSibling),Ai=t,V=!0,Mi=null,Ni=!1,e!==null&&ki(t,e),t=bc(t,r.children),t.flags|=4096);return t}return a?(ao(t),c=r.fallback,a=t.mode,l=e.child,u=l.sibling,r=si(l,{mode:`hidden`,children:r.children}),r.subtreeFlags=l.subtreeFlags&65011712,u===null?(c=ui(c,a,n,null),c.flags|=2):c=si(u,c),c.return=t,r.return=t,r.sibling=c,t.child=r,oc(null,r),r=t.child,c=e.child.memoizedState,c===null?c=_c(n):(a=c.cachePool,a===null?a=va():(l=ia._currentValue,a=a.parent===l?a:{parent:l,pool:l}),c={baseLanes:c.baseLanes|n,cachePool:a}),r.memoizedState=c,r.childLanes=vc(e,s,n),t.memoizedState=gc,oc(e.child,r)):(no(t),n=e.child,e=n.sibling,n=si(n,{mode:`visible`,children:r.children}),n.return=t,n.sibling=null,e!==null&&(s=t.deletions,s===null?(t.deletions=[e],t.flags|=16):s.push(e)),t.child=n,t.memoizedState=null,n)}function bc(e,t){return t=xc({mode:`visible`,children:t},e.mode),t.return=e,e.child=t}function xc(e,t){return e=ai(22,e,null,t),e.lanes=0,e}function Sc(e,t,n){return Fa(t,e.child,null,n),e=bc(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Cc(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),qi(e.return,t,n)}function wc(e,t,n,r,i,a){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i,treeForkCount:a}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=i,o.treeForkCount=a)}function Tc(e,t,n){var r=t.pendingProps,i=r.revealOrder,a=r.tail;r=r.children;var o=so.current,s=(o&2)!=0;if(s?(o=o&1|2,t.flags|=128):o&=1,I(so,o),tc(e,t,r,n),r=V?yi:0,!s&&e!==null&&e.flags&128)a:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Cc(e,n,t);else if(e.tag===19)Cc(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break a;for(;e.sibling===null;){if(e.return===null||e.return===t)break a;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(i){case`forwards`:for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&co(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),wc(t,!1,i,n,a,r);break;case`backwards`:case`unstable_legacy-backwards`:for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&co(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}wc(t,!0,n,null,a,r);break;case`together`:wc(t,!1,null,null,void 0,r);break;default:t.memoizedState=null}return t.child}function Ec(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Wl|=t.lanes,(n&t.childLanes)===0)if(e!==null){if(Yi(e,t,n,!1),(n&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(i(153));if(t.child!==null){for(e=t.child,n=si(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=si(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function Dc(e,t){return(e.lanes&t)===0?(e=e.dependencies,!!(e!==null&&Xi(e))):!0}function Oc(e,t,n){switch(t.tag){case 3:le(t,t.stateNode.containerInfo),Gi(t,ia,e.memoizedState.cache),zi();break;case 27:case 5:de(t);break;case 4:le(t,t.stateNode.containerInfo);break;case 10:Gi(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,ro(t),null;break;case 13:var r=t.memoizedState;if(r!==null)return r.dehydrated===null?(n&t.child.childLanes)===0?(no(t),e=Ec(e,t,n),e===null?null:e.sibling):yc(e,t,n):(no(t),t.flags|=128,null);no(t);break;case 19:var i=(e.flags&128)!=0;if(r=(n&t.childLanes)!==0,r||(Yi(e,t,n,!1),r=(n&t.childLanes)!==0),i){if(r)return Tc(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),I(so,so.current),r)break;return null;case 22:return t.lanes=0,ac(e,t,n,t.pendingProps);case 24:Gi(t,ia,e.memoizedState.cache)}return Ec(e,t,n)}function kc(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps)ec=!0;else{if(!Dc(e,n)&&!(t.flags&128))return ec=!1,Oc(e,t,n);ec=!!(e.flags&131072)}else ec=!1,V&&t.flags&1048576&&Ei(t,yi,t.index);switch(t.lanes=0,t.tag){case 16:a:{var r=t.pendingProps;if(e=Ta(t.elementType),t.type=e,typeof e==`function`)oi(e)?(r=Us(e,r),t.tag=1,t=mc(null,t,e,r,n)):(t.tag=0,t=fc(null,t,e,r,n));else{if(e!=null){var a=e.$$typeof;if(a===S){t.tag=11,t=nc(null,t,e,r,n);break a}else if(a===T){t.tag=14,t=rc(null,t,e,r,n);break a}}throw t=ee(e)||e,Error(i(306,t,``))}}return t;case 0:return fc(e,t,t.type,t.pendingProps,n);case 1:return r=t.type,a=Us(r,t.pendingProps),mc(e,t,r,a,n);case 3:a:{if(le(t,t.stateNode.containerInfo),e===null)throw Error(i(387));r=t.pendingProps;var o=t.memoizedState;a=o.element,za(e,t),Ka(t,r,null,n);var s=t.memoizedState;if(r=s.cache,Gi(t,ia,r),r!==o.cache&&Ji(t,[ia],n,!0),Ga(),r=s.element,o.isDehydrated)if(o={element:r,isDehydrated:!1,cache:s.cache},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){t=hc(e,t,r,n);break a}else if(r!==a){a=hi(Error(i(424)),t),Vi(a),t=hc(e,t,r,n);break a}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName===`HTML`?e.ownerDocument.body:e}for(ji=sf(e.firstChild),Ai=t,V=!0,Mi=null,Ni=!0,n=Ia(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling}else{if(zi(),r===a){t=Ec(e,t,n);break a}tc(e,t,r,n)}t=t.child}return t;case 26:return dc(e,t),e===null?(n=Of(t.type,null,t.pendingProps,null))?t.memoizedState=n:V||(n=t.type,e=t.pendingProps,r=zd(se.current).createElement(n),r[rt]=t,r[it]=e,Nd(r,n,e),gt(r),t.stateNode=r):t.memoizedState=Of(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return de(t),e===null&&V&&(r=t.stateNode=df(t.type,t.pendingProps,se.current),Ai=t,Ni=!0,a=ji,Xd(t.type)?(cf=a,ji=sf(r.firstChild)):ji=a),tc(e,t,t.pendingProps.children,n),dc(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&V&&((a=r=ji)&&(r=ef(r,t.type,t.pendingProps,Ni),r===null?a=!1:(t.stateNode=r,Ai=t,ji=sf(r.firstChild),Ni=!1,a=!0)),a||Fi(t)),de(t),a=t.type,o=t.pendingProps,s=e===null?null:e.memoizedProps,r=o.children,Hd(a,o)?r=null:s!==null&&Hd(a,s)&&(t.flags|=32),t.memoizedState!==null&&(a=bo(e,t,Co,null,null,n),Zf._currentValue=a),dc(e,t),tc(e,t,r,n),t.child;case 6:return e===null&&V&&((e=n=ji)&&(n=tf(n,t.pendingProps,Ni),n===null?e=!1:(t.stateNode=n,Ai=t,ji=null,e=!0)),e||Fi(t)),null;case 13:return yc(e,t,n);case 4:return le(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Fa(t,null,r,n):tc(e,t,r,n),t.child;case 11:return nc(e,t,t.type,t.pendingProps,n);case 7:return tc(e,t,t.pendingProps,n),t.child;case 8:return tc(e,t,t.pendingProps.children,n),t.child;case 12:return tc(e,t,t.pendingProps.children,n),t.child;case 10:return r=t.pendingProps,Gi(t,t.type,r.value),tc(e,t,r.children,n),t.child;case 9:return a=t.type._context,r=t.pendingProps.children,Zi(t),a=Qi(a),r=r(a),t.flags|=1,tc(e,t,r,n),t.child;case 14:return rc(e,t,t.type,t.pendingProps,n);case 15:return ic(e,t,t.type,t.pendingProps,n);case 19:return Tc(e,t,n);case 31:return uc(e,t,n);case 22:return ac(e,t,n,t.pendingProps);case 24:return Zi(t),r=Qi(ia),e===null?(a=ga(),a===null&&(a=q,o=aa(),a.pooledCache=o,o.refCount++,o!==null&&(a.pooledCacheLanes|=n),a=o),t.memoizedState={parent:r,cache:a},Ra(t),Gi(t,ia,a)):((e.lanes&n)!==0&&(za(e,t),Ka(t,null,null,n),Ga()),a=e.memoizedState,o=t.memoizedState,a.parent===r?(r=o.cache,Gi(t,ia,r),r!==a.cache&&Ji(t,[ia],n,!0)):(a={parent:r,cache:r},t.memoizedState=a,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=a),Gi(t,ia,r))),tc(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(i(156,t.tag))}function Ac(e){e.flags|=4}function jc(e,t,n,r,i){if((t=(e.mode&32)!=0)&&(t=!1),t){if(e.flags|=16777216,(i&335544128)===i)if(e.stateNode.complete)e.flags|=8192;else if(Cu())e.flags|=8192;else throw Ea=Sa,ba}else e.flags&=-16777217}function Mc(e,t){if(t.type!==`stylesheet`||t.state.loading&4)e.flags&=-16777217;else if(e.flags|=16777216,!Uf(t))if(Cu())e.flags|=8192;else throw Ea=Sa,ba}function Nc(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag===22?536870912:Ge(),e.lanes|=t,Jl|=t)}function Pc(e,t){if(!V)switch(e.tailMode){case`hidden`:t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case`collapsed`:n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function Fc(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&65011712,r|=i.flags&65011712,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function Ic(e,t,n){var r=t.pendingProps;switch(Oi(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Fc(t),null;case 1:return Fc(t),null;case 3:return n=t.stateNode,r=null,e!==null&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),Ki(ia),ue(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(e===null||e.child===null)&&(Ri(t)?Ac(t):e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Bi())),Fc(t),null;case 26:var a=t.type,o=t.memoizedState;return e===null?(Ac(t),o===null?(Fc(t),jc(t,a,null,r,n)):(Fc(t),Mc(t,o))):o?o===e.memoizedState?(Fc(t),t.flags&=-16777217):(Ac(t),Fc(t),Mc(t,o)):(e=e.memoizedProps,e!==r&&Ac(t),Fc(t),jc(t,a,e,r,n)),null;case 27:if(fe(t),n=se.current,a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Ac(t);else{if(!r){if(t.stateNode===null)throw Error(i(166));return Fc(t),null}e=ae.current,Ri(t)?Ii(t,e):(e=df(a,r,n),t.stateNode=e,Ac(t))}return Fc(t),null;case 5:if(fe(t),a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Ac(t);else{if(!r){if(t.stateNode===null)throw Error(i(166));return Fc(t),null}if(o=ae.current,Ri(t))Ii(t,o);else{var s=zd(se.current);switch(o){case 1:o=s.createElementNS(`http://www.w3.org/2000/svg`,a);break;case 2:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,a);break;default:switch(a){case`svg`:o=s.createElementNS(`http://www.w3.org/2000/svg`,a);break;case`math`:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,a);break;case`script`:o=s.createElement(`div`),o.innerHTML=`<script><\/script>`,o=o.removeChild(o.firstChild);break;case`select`:o=typeof r.is==`string`?s.createElement(`select`,{is:r.is}):s.createElement(`select`),r.multiple?o.multiple=!0:r.size&&(o.size=r.size);break;default:o=typeof r.is==`string`?s.createElement(a,{is:r.is}):s.createElement(a)}}o[rt]=t,o[it]=r;a:for(s=t.child;s!==null;){if(s.tag===5||s.tag===6)o.appendChild(s.stateNode);else if(s.tag!==4&&s.tag!==27&&s.child!==null){s.child.return=s,s=s.child;continue}if(s===t)break a;for(;s.sibling===null;){if(s.return===null||s.return===t)break a;s=s.return}s.sibling.return=s.return,s=s.sibling}t.stateNode=o;a:switch(Nd(o,a,r),a){case`button`:case`input`:case`select`:case`textarea`:r=!!r.autoFocus;break a;case`img`:r=!0;break a;default:r=!1}r&&Ac(t)}}return Fc(t),jc(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&Ac(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(i(166));if(e=se.current,Ri(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,a=Ai,a!==null)switch(a.tag){case 27:case 5:r=a.memoizedProps}e[rt]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||jd(e.nodeValue,n)),e||Fi(t,!0)}else e=zd(e).createTextNode(r),e[rt]=t,t.stateNode=e}return Fc(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=Ri(t),n!==null){if(e===null){if(!r)throw Error(i(318));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(557));e[rt]=t}else zi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Fc(t),e=!1}else n=Bi(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(oo(t),t):(oo(t),null);if(t.flags&128)throw Error(i(558))}return Fc(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(a=Ri(t),r!==null&&r.dehydrated!==null){if(e===null){if(!a)throw Error(i(318));if(a=t.memoizedState,a=a===null?null:a.dehydrated,!a)throw Error(i(317));a[rt]=t}else zi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Fc(t),a=!1}else a=Bi(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),a=!0;if(!a)return t.flags&256?(oo(t),t):(oo(t),null)}return oo(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,a=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(a=r.alternate.memoizedState.cachePool.pool),o=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(o=r.memoizedState.cachePool.pool),o!==a&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Nc(t,t.updateQueue),Fc(t),null);case 4:return ue(),e===null&&xd(t.stateNode.containerInfo),Fc(t),null;case 10:return Ki(t.type),Fc(t),null;case 19:if(ie(so),r=t.memoizedState,r===null)return Fc(t),null;if(a=(t.flags&128)!=0,o=r.rendering,o===null)if(a)Pc(r,!1);else{if(Ul!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=co(e),o!==null){for(t.flags|=128,Pc(r,!1),e=o.updateQueue,t.updateQueue=e,Nc(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)ci(n,e),n=n.sibling;return I(so,so.current&1|2),V&&Ti(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&we()>eu&&(t.flags|=128,a=!0,Pc(r,!1),t.lanes=4194304)}else{if(!a)if(e=co(o),e!==null){if(t.flags|=128,a=!0,e=e.updateQueue,t.updateQueue=e,Nc(t,e),Pc(r,!0),r.tail===null&&r.tailMode===`hidden`&&!o.alternate&&!V)return Fc(t),null}else 2*we()-r.renderingStartTime>eu&&n!==536870912&&(t.flags|=128,a=!0,Pc(r,!1),t.lanes=4194304);r.isBackwards?(o.sibling=t.child,t.child=o):(e=r.last,e===null?t.child=o:e.sibling=o,r.last=o)}return r.tail===null?(Fc(t),null):(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=we(),e.sibling=null,n=so.current,I(so,a?n&1|2:n&1),V&&Ti(t,r.treeForkCount),e);case 22:case 23:return oo(t),$a(),r=t.memoizedState!==null,e===null?r&&(t.flags|=8192):e.memoizedState!==null!==r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(Fc(t),t.subtreeFlags&6&&(t.flags|=8192)):Fc(t),n=t.updateQueue,n!==null&&Nc(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),r=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),e!==null&&ie(ha),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),Ki(ia),Fc(t),null;case 25:return null;case 30:return null}throw Error(i(156,t.tag))}function Lc(e,t){switch(Oi(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Ki(ia),ue(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return fe(t),null;case 31:if(t.memoizedState!==null){if(oo(t),t.alternate===null)throw Error(i(340));zi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(oo(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(i(340));zi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return ie(so),null;case 4:return ue(),null;case 10:return Ki(t.type),null;case 22:case 23:return oo(t),$a(),e!==null&&ie(ha),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Ki(ia),null;case 25:return null;default:return null}}function Rc(e,t){switch(Oi(t),t.tag){case 3:Ki(ia),ue();break;case 26:case 27:case 5:fe(t);break;case 4:ue();break;case 31:t.memoizedState!==null&&oo(t);break;case 13:oo(t);break;case 19:ie(so);break;case 10:Ki(t.type);break;case 22:case 23:oo(t),$a(),e!==null&&ie(ha);break;case 24:Ki(ia)}}function zc(e,t){try{var n=t.updateQueue,r=n===null?null:n.lastEffect;if(r!==null){var i=r.next;n=i;do{if((n.tag&e)===e){r=void 0;var a=n.create,o=n.inst;r=a(),o.destroy=r}n=n.next}while(n!==i)}}catch(e){Z(t,t.return,e)}}function Bc(e,t,n){try{var r=t.updateQueue,i=r===null?null:r.lastEffect;if(i!==null){var a=i.next;r=a;do{if((r.tag&e)===e){var o=r.inst,s=o.destroy;if(s!==void 0){o.destroy=void 0,i=t;var c=n,l=s;try{l()}catch(e){Z(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){Z(t,t.return,e)}}function Vc(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{Ja(t,n)}catch(t){Z(e,e.return,t)}}}function Hc(e,t,n){n.props=Us(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){Z(e,t,n)}}function Uc(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;case 30:r=e.stateNode;break;default:r=e.stateNode}typeof n==`function`?e.refCleanup=n(r):n.current=r}}catch(n){Z(e,t,n)}}function Wc(e,t){var n=e.ref,r=e.refCleanup;if(n!==null)if(typeof r==`function`)try{r()}catch(n){Z(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==`function`)try{n(null)}catch(n){Z(e,t,n)}else n.current=null}function Gc(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{a:switch(t){case`button`:case`input`:case`select`:case`textarea`:n.autoFocus&&r.focus();break a;case`img`:n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){Z(e,e.return,t)}}function Kc(e,t,n){try{var r=e.stateNode;Pd(r,e.type,n,t),r[it]=t}catch(t){Z(e,e.return,t)}}function qc(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Xd(e.type)||e.tag===4}function Jc(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||qc(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&Xd(e.type)||e.flags&2||e.child===null||e.tag===4)continue a;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Yc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n).insertBefore(e,t):(t=n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n,t.appendChild(e),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Xt));else if(r!==4&&(r===27&&Xd(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(Yc(e,t,n),e=e.sibling;e!==null;)Yc(e,t,n),e=e.sibling}function Xc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(r===27&&Xd(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(Xc(e,t,n),e=e.sibling;e!==null;)Xc(e,t,n),e=e.sibling}function Zc(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Nd(t,r,n),t[rt]=e,t[it]=n}catch(t){Z(e,e.return,t)}}var Qc=!1,$c=!1,el=!1,tl=typeof WeakSet==`function`?WeakSet:Set,nl=null;function rl(e,t){if(e=e.containerInfo,Ld=op,e=wr(e),Tr(e)){if(`selectionStart`in e)var n={start:e.selectionStart,end:e.selectionEnd};else a:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var a=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break a}var s=0,c=-1,l=-1,u=0,d=0,f=e,p=null;b:for(;;){for(var m;f!==n||a!==0&&f.nodeType!==3||(c=s+a),f!==o||r!==0&&f.nodeType!==3||(l=s+r),f.nodeType===3&&(s+=f.nodeValue.length),(m=f.firstChild)!==null;)p=f,f=m;for(;;){if(f===e)break b;if(p===n&&++u===a&&(c=s),p===o&&++d===r&&(l=s),(m=f.nextSibling)!==null)break;f=p,p=f.parentNode}f=m}n=c===-1||l===-1?null:{start:c,end:l}}else n=null}n=n||{start:0,end:0}}else n=null;for(Rd={focusedElem:e,selectionRange:n},op=!1,nl=t;nl!==null;)if(t=nl,e=t.child,t.subtreeFlags&1028&&e!==null)e.return=t,nl=e;else for(;nl!==null;){switch(t=nl,o=t.alternate,e=t.flags,t.tag){case 0:if(e&4&&(e=t.updateQueue,e=e===null?null:e.events,e!==null))for(n=0;n<e.length;n++)a=e[n],a.ref.impl=a.nextImpl;break;case 11:case 15:break;case 1:if(e&1024&&o!==null){e=void 0,n=t,a=o.memoizedProps,o=o.memoizedState,r=n.stateNode;try{var h=Us(n.type,a);e=r.getSnapshotBeforeUpdate(h,o),r.__reactInternalSnapshotBeforeUpdate=e}catch(e){Z(n,n.return,e)}}break;case 3:if(e&1024){if(e=t.stateNode.containerInfo,n=e.nodeType,n===9)$d(e);else if(n===1)switch(e.nodeName){case`HEAD`:case`HTML`:case`BODY`:$d(e);break;default:e.textContent=``}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if(e&1024)throw Error(i(163))}if(e=t.sibling,e!==null){e.return=t.return,nl=e;break}nl=t.return}}function il(e,t,n){var r=n.flags;switch(n.tag){case 0:case 11:case 15:yl(e,n),r&4&&zc(5,n);break;case 1:if(yl(e,n),r&4)if(e=n.stateNode,t===null)try{e.componentDidMount()}catch(e){Z(n,n.return,e)}else{var i=Us(n.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(i,t,e.__reactInternalSnapshotBeforeUpdate)}catch(e){Z(n,n.return,e)}}r&64&&Vc(n),r&512&&Uc(n,n.return);break;case 3:if(yl(e,n),r&64&&(e=n.updateQueue,e!==null)){if(t=null,n.child!==null)switch(n.child.tag){case 27:case 5:t=n.child.stateNode;break;case 1:t=n.child.stateNode}try{Ja(e,t)}catch(e){Z(n,n.return,e)}}break;case 27:t===null&&r&4&&Zc(n);case 26:case 5:yl(e,n),t===null&&r&4&&Gc(n),r&512&&Uc(n,n.return);break;case 12:yl(e,n);break;case 31:yl(e,n),r&4&&ul(e,n);break;case 13:yl(e,n),r&4&&dl(e,n),r&64&&(e=n.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(n=qu.bind(null,n),of(e,n))));break;case 22:if(r=n.memoizedState!==null||Qc,!r){t=t!==null&&t.memoizedState!==null||$c,i=Qc;var a=$c;Qc=r,($c=t)&&!a?xl(e,n,(n.subtreeFlags&8772)!=0):yl(e,n),Qc=i,$c=a}break;case 30:break;default:yl(e,n)}}function al(e){var t=e.alternate;t!==null&&(e.alternate=null,al(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&dt(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var ol=null,sl=!1;function cl(e,t,n){for(n=n.child;n!==null;)ll(e,t,n),n=n.sibling}function ll(e,t,n){if(Me&&typeof Me.onCommitFiberUnmount==`function`)try{Me.onCommitFiberUnmount(je,n)}catch{}switch(n.tag){case 26:$c||Wc(n,t),cl(e,t,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:$c||Wc(n,t);var r=ol,i=sl;Xd(n.type)&&(ol=n.stateNode,sl=!1),cl(e,t,n),ff(n.stateNode),ol=r,sl=i;break;case 5:$c||Wc(n,t);case 6:if(r=ol,i=sl,ol=null,cl(e,t,n),ol=r,sl=i,ol!==null)if(sl)try{(ol.nodeType===9?ol.body:ol.nodeName===`HTML`?ol.ownerDocument.body:ol).removeChild(n.stateNode)}catch(e){Z(n,t,e)}else try{ol.removeChild(n.stateNode)}catch(e){Z(n,t,e)}break;case 18:ol!==null&&(sl?(e=ol,Zd(e.nodeType===9?e.body:e.nodeName===`HTML`?e.ownerDocument.body:e,n.stateNode),Mp(e)):Zd(ol,n.stateNode));break;case 4:r=ol,i=sl,ol=n.stateNode.containerInfo,sl=!0,cl(e,t,n),ol=r,sl=i;break;case 0:case 11:case 14:case 15:Bc(2,n,t),$c||Bc(4,n,t),cl(e,t,n);break;case 1:$c||(Wc(n,t),r=n.stateNode,typeof r.componentWillUnmount==`function`&&Hc(n,t,r)),cl(e,t,n);break;case 21:cl(e,t,n);break;case 22:$c=(r=$c)||n.memoizedState!==null,cl(e,t,n),$c=r;break;default:cl(e,t,n)}}function ul(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Mp(e)}catch(e){Z(t,t.return,e)}}}function dl(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Mp(e)}catch(e){Z(t,t.return,e)}}function fl(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new tl),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new tl),t;default:throw Error(i(435,e.tag))}}function pl(e,t){var n=fl(e);t.forEach(function(t){if(!n.has(t)){n.add(t);var r=Ju.bind(null,e,t);t.then(r,r)}})}function ml(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var a=n[r],o=e,s=t,c=s;a:for(;c!==null;){switch(c.tag){case 27:if(Xd(c.type)){ol=c.stateNode,sl=!1;break a}break;case 5:ol=c.stateNode,sl=!1;break a;case 3:case 4:ol=c.stateNode.containerInfo,sl=!0;break a}c=c.return}if(ol===null)throw Error(i(160));ll(o,s,a),ol=null,sl=!1,o=a.alternate,o!==null&&(o.return=null),a.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)gl(t,e),t=t.sibling}var hl=null;function gl(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:ml(t,e),_l(e),r&4&&(Bc(3,e,e.return),zc(3,e),Bc(5,e,e.return));break;case 1:ml(t,e),_l(e),r&512&&($c||n===null||Wc(n,n.return)),r&64&&Qc&&(e=e.updateQueue,e!==null&&(r=e.callbacks,r!==null&&(n=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=n===null?r:n.concat(r))));break;case 26:var a=hl;if(ml(t,e),_l(e),r&512&&($c||n===null||Wc(n,n.return)),r&4){var o=n===null?null:n.memoizedState;if(r=e.memoizedState,n===null)if(r===null)if(e.stateNode===null){a:{r=e.type,n=e.memoizedProps,a=a.ownerDocument||a;b:switch(r){case`title`:o=a.getElementsByTagName(`title`)[0],(!o||o[ut]||o[rt]||o.namespaceURI===`http://www.w3.org/2000/svg`||o.hasAttribute(`itemprop`))&&(o=a.createElement(r),a.head.insertBefore(o,a.querySelector(`head > title`))),Nd(o,r,n),o[rt]=e,gt(o),r=o;break a;case`link`:var s=Bf(`link`,`href`,a).get(r+(n.href||``));if(s){for(var c=0;c<s.length;c++)if(o=s[c],o.getAttribute(`href`)===(n.href==null||n.href===``?null:n.href)&&o.getAttribute(`rel`)===(n.rel==null?null:n.rel)&&o.getAttribute(`title`)===(n.title==null?null:n.title)&&o.getAttribute(`crossorigin`)===(n.crossOrigin==null?null:n.crossOrigin)){s.splice(c,1);break b}}o=a.createElement(r),Nd(o,r,n),a.head.appendChild(o);break;case`meta`:if(s=Bf(`meta`,`content`,a).get(r+(n.content||``))){for(c=0;c<s.length;c++)if(o=s[c],o.getAttribute(`content`)===(n.content==null?null:``+n.content)&&o.getAttribute(`name`)===(n.name==null?null:n.name)&&o.getAttribute(`property`)===(n.property==null?null:n.property)&&o.getAttribute(`http-equiv`)===(n.httpEquiv==null?null:n.httpEquiv)&&o.getAttribute(`charset`)===(n.charSet==null?null:n.charSet)){s.splice(c,1);break b}}o=a.createElement(r),Nd(o,r,n),a.head.appendChild(o);break;default:throw Error(i(468,r))}o[rt]=e,gt(o),r=o}e.stateNode=r}else Vf(a,e.type,e.stateNode);else e.stateNode=Ff(a,r,e.memoizedProps);else o===r?r===null&&e.stateNode!==null&&Kc(e,e.memoizedProps,n.memoizedProps):(o===null?n.stateNode!==null&&(n=n.stateNode,n.parentNode.removeChild(n)):o.count--,r===null?Vf(a,e.type,e.stateNode):Ff(a,r,e.memoizedProps))}break;case 27:ml(t,e),_l(e),r&512&&($c||n===null||Wc(n,n.return)),n!==null&&r&4&&Kc(e,e.memoizedProps,n.memoizedProps);break;case 5:if(ml(t,e),_l(e),r&512&&($c||n===null||Wc(n,n.return)),e.flags&32){a=e.stateNode;try{Ht(a,``)}catch(t){Z(e,e.return,t)}}r&4&&e.stateNode!=null&&(a=e.memoizedProps,Kc(e,a,n===null?a:n.memoizedProps)),r&1024&&(el=!0);break;case 6:if(ml(t,e),_l(e),r&4){if(e.stateNode===null)throw Error(i(162));r=e.memoizedProps,n=e.stateNode;try{n.nodeValue=r}catch(t){Z(e,e.return,t)}}break;case 3:if(zf=null,a=hl,hl=hf(t.containerInfo),ml(t,e),hl=a,_l(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Mp(t.containerInfo)}catch(t){Z(e,e.return,t)}el&&(el=!1,vl(e));break;case 4:r=hl,hl=hf(e.stateNode.containerInfo),ml(t,e),_l(e),hl=r;break;case 12:ml(t,e),_l(e);break;case 31:ml(t,e),_l(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,pl(e,r)));break;case 13:ml(t,e),_l(e),e.child.flags&8192&&e.memoizedState!==null!=(n!==null&&n.memoizedState!==null)&&(Ql=we()),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,pl(e,r)));break;case 22:a=e.memoizedState!==null;var l=n!==null&&n.memoizedState!==null,u=Qc,d=$c;if(Qc=u||a,$c=d||l,ml(t,e),$c=d,Qc=u,_l(e),r&8192)a:for(t=e.stateNode,t._visibility=a?t._visibility&-2:t._visibility|1,a&&(n===null||l||Qc||$c||bl(e)),n=null,t=e;;){if(t.tag===5||t.tag===26){if(n===null){l=n=t;try{if(o=l.stateNode,a)s=o.style,typeof s.setProperty==`function`?s.setProperty(`display`,`none`,`important`):s.display=`none`;else{c=l.stateNode;var f=l.memoizedProps.style,p=f!=null&&f.hasOwnProperty(`display`)?f.display:null;c.style.display=p==null||typeof p==`boolean`?``:(``+p).trim()}}catch(e){Z(l,l.return,e)}}}else if(t.tag===6){if(n===null){l=t;try{l.stateNode.nodeValue=a?``:l.memoizedProps}catch(e){Z(l,l.return,e)}}}else if(t.tag===18){if(n===null){l=t;try{var m=l.stateNode;a?Qd(m,!0):Qd(l.stateNode,!1)}catch(e){Z(l,l.return,e)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break a;for(;t.sibling===null;){if(t.return===null||t.return===e)break a;n===t&&(n=null),t=t.return}n===t&&(n=null),t.sibling.return=t.return,t=t.sibling}r&4&&(r=e.updateQueue,r!==null&&(n=r.retryQueue,n!==null&&(r.retryQueue=null,pl(e,n))));break;case 19:ml(t,e),_l(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,pl(e,r)));break;case 30:break;case 21:break;default:ml(t,e),_l(e)}}function _l(e){var t=e.flags;if(t&2){try{for(var n,r=e.return;r!==null;){if(qc(r)){n=r;break}r=r.return}if(n==null)throw Error(i(160));switch(n.tag){case 27:var a=n.stateNode;Xc(e,Jc(e),a);break;case 5:var o=n.stateNode;n.flags&32&&(Ht(o,``),n.flags&=-33),Xc(e,Jc(e),o);break;case 3:case 4:var s=n.stateNode.containerInfo;Yc(e,Jc(e),s);break;default:throw Error(i(161))}}catch(t){Z(e,e.return,t)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function vl(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;vl(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function yl(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)il(e,t.alternate,t),t=t.sibling}function bl(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:Bc(4,t,t.return),bl(t);break;case 1:Wc(t,t.return);var n=t.stateNode;typeof n.componentWillUnmount==`function`&&Hc(t,t.return,n),bl(t);break;case 27:ff(t.stateNode);case 26:case 5:Wc(t,t.return),bl(t);break;case 22:t.memoizedState===null&&bl(t);break;case 30:bl(t);break;default:bl(t)}e=e.sibling}}function xl(e,t,n){for(n=n&&(t.subtreeFlags&8772)!=0,t=t.child;t!==null;){var r=t.alternate,i=e,a=t,o=a.flags;switch(a.tag){case 0:case 11:case 15:xl(i,a,n),zc(4,a);break;case 1:if(xl(i,a,n),r=a,i=r.stateNode,typeof i.componentDidMount==`function`)try{i.componentDidMount()}catch(e){Z(r,r.return,e)}if(r=a,i=r.updateQueue,i!==null){var s=r.stateNode;try{var c=i.shared.hiddenCallbacks;if(c!==null)for(i.shared.hiddenCallbacks=null,i=0;i<c.length;i++)qa(c[i],s)}catch(e){Z(r,r.return,e)}}n&&o&64&&Vc(a),Uc(a,a.return);break;case 27:Zc(a);case 26:case 5:xl(i,a,n),n&&r===null&&o&4&&Gc(a),Uc(a,a.return);break;case 12:xl(i,a,n);break;case 31:xl(i,a,n),n&&o&4&&ul(i,a);break;case 13:xl(i,a,n),n&&o&4&&dl(i,a);break;case 22:a.memoizedState===null&&xl(i,a,n),Uc(a,a.return);break;case 30:break;default:xl(i,a,n)}t=t.sibling}}function Sl(e,t){var n=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==n&&(e!=null&&e.refCount++,n!=null&&oa(n))}function Cl(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&oa(e))}function wl(e,t,n,r){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Tl(e,t,n,r),t=t.sibling}function Tl(e,t,n,r){var i=t.flags;switch(t.tag){case 0:case 11:case 15:wl(e,t,n,r),i&2048&&zc(9,t);break;case 1:wl(e,t,n,r);break;case 3:wl(e,t,n,r),i&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&oa(e)));break;case 12:if(i&2048){wl(e,t,n,r),e=t.stateNode;try{var a=t.memoizedProps,o=a.id,s=a.onPostCommit;typeof s==`function`&&s(o,t.alternate===null?`mount`:`update`,e.passiveEffectDuration,-0)}catch(e){Z(t,t.return,e)}}else wl(e,t,n,r);break;case 31:wl(e,t,n,r);break;case 13:wl(e,t,n,r);break;case 23:break;case 22:a=t.stateNode,o=t.alternate,t.memoizedState===null?a._visibility&2?wl(e,t,n,r):(a._visibility|=2,El(e,t,n,r,(t.subtreeFlags&10256)!=0||!1)):a._visibility&2?wl(e,t,n,r):Dl(e,t),i&2048&&Sl(o,t);break;case 24:wl(e,t,n,r),i&2048&&Cl(t.alternate,t);break;default:wl(e,t,n,r)}}function El(e,t,n,r,i){for(i=i&&((t.subtreeFlags&10256)!=0||!1),t=t.child;t!==null;){var a=e,o=t,s=n,c=r,l=o.flags;switch(o.tag){case 0:case 11:case 15:El(a,o,s,c,i),zc(8,o);break;case 23:break;case 22:var u=o.stateNode;o.memoizedState===null?(u._visibility|=2,El(a,o,s,c,i)):u._visibility&2?El(a,o,s,c,i):Dl(a,o),i&&l&2048&&Sl(o.alternate,o);break;case 24:El(a,o,s,c,i),i&&l&2048&&Cl(o.alternate,o);break;default:El(a,o,s,c,i)}t=t.sibling}}function Dl(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var n=e,r=t,i=r.flags;switch(r.tag){case 22:Dl(n,r),i&2048&&Sl(r.alternate,r);break;case 24:Dl(n,r),i&2048&&Cl(r.alternate,r);break;default:Dl(n,r)}t=t.sibling}}var Ol=8192;function kl(e,t,n){if(e.subtreeFlags&Ol)for(e=e.child;e!==null;)Al(e,t,n),e=e.sibling}function Al(e,t,n){switch(e.tag){case 26:kl(e,t,n),e.flags&Ol&&e.memoizedState!==null&&Wf(n,hl,e.memoizedState,e.memoizedProps);break;case 5:kl(e,t,n);break;case 3:case 4:var r=hl;hl=hf(e.stateNode.containerInfo),kl(e,t,n),hl=r;break;case 22:e.memoizedState===null&&(r=e.alternate,r!==null&&r.memoizedState!==null?(r=Ol,Ol=16777216,kl(e,t,n),Ol=r):kl(e,t,n));break;default:kl(e,t,n)}}function jl(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Ml(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];nl=r,Fl(r,e)}jl(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Nl(e),e=e.sibling}function Nl(e){switch(e.tag){case 0:case 11:case 15:Ml(e),e.flags&2048&&Bc(9,e,e.return);break;case 3:Ml(e);break;case 12:Ml(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,Pl(e)):Ml(e);break;default:Ml(e)}}function Pl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];nl=r,Fl(r,e)}jl(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:Bc(8,t,t.return),Pl(t);break;case 22:n=t.stateNode,n._visibility&2&&(n._visibility&=-3,Pl(t));break;default:Pl(t)}e=e.sibling}}function Fl(e,t){for(;nl!==null;){var n=nl;switch(n.tag){case 0:case 11:case 15:Bc(8,n,t);break;case 23:case 22:if(n.memoizedState!==null&&n.memoizedState.cachePool!==null){var r=n.memoizedState.cachePool.pool;r!=null&&r.refCount++}break;case 24:oa(n.memoizedState.cache)}if(r=n.child,r!==null)r.return=n,nl=r;else a:for(n=e;nl!==null;){r=nl;var i=r.sibling,a=r.return;if(al(r),r===n){nl=null;break a}if(i!==null){i.return=a,nl=i;break a}nl=a}}}var Il={getCacheForType:function(e){var t=Qi(ia),n=t.data.get(e);return n===void 0&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return Qi(ia).controller.signal}},Ll=typeof WeakMap==`function`?WeakMap:Map,K=0,q=null,J=null,Y=0,X=0,Rl=null,zl=!1,Bl=!1,Vl=!1,Hl=0,Ul=0,Wl=0,Gl=0,Kl=0,ql=0,Jl=0,Yl=null,Xl=null,Zl=!1,Ql=0,$l=0,eu=1/0,tu=null,nu=null,ru=0,iu=null,au=null,ou=0,su=0,cu=null,lu=null,uu=0,du=null;function fu(){return K&2&&Y!==0?Y&-Y:N.T===null?et():ud()}function pu(){if(ql===0)if(!(Y&536870912)||V){var e=ze;ze<<=1,!(ze&3932160)&&(ze=262144),ql=e}else ql=536870912;return e=eo.current,e!==null&&(e.flags|=32),ql}function mu(e,t,n){(e===q&&(X===2||X===9)||e.cancelPendingCommit!==null)&&(xu(e,0),vu(e,Y,ql,!1)),qe(e,n),(!(K&2)||e!==q)&&(e===q&&(!(K&2)&&(Gl|=n),Ul===4&&vu(e,Y,ql,!1)),nd(e))}function hu(e,t,n){if(K&6)throw Error(i(327));var r=!n&&(t&127)==0&&(t&e.expiredLanes)===0||Ue(e,t),a=r?ku(e,t):Du(e,t,!0),o=r;do{if(a===0){Bl&&!r&&vu(e,t,0,!1);break}else{if(n=e.current.alternate,o&&!_u(n)){a=Du(e,t,!1),o=!1;continue}if(a===2){if(o=t,e.errorRecoveryDisabledLanes&o)var s=0;else s=e.pendingLanes&-536870913,s=s===0?s&536870912?536870912:0:s;if(s!==0){t=s;a:{var c=e;a=Yl;var l=c.current.memoizedState.isDehydrated;if(l&&(xu(c,s).flags|=256),s=Du(c,s,!1),s!==2){if(Vl&&!l){c.errorRecoveryDisabledLanes|=o,Gl|=o,a=4;break a}o=Xl,Xl=a,o!==null&&(Xl===null?Xl=o:Xl.push.apply(Xl,o))}a=s}if(o=!1,a!==2)continue}}if(a===1){xu(e,0),vu(e,t,0,!0);break}a:{switch(r=e,o=a,o){case 0:case 1:throw Error(i(345));case 4:if((t&4194048)!==t)break;case 6:vu(r,t,ql,!zl);break a;case 2:Xl=null;break;case 3:case 5:break;default:throw Error(i(329))}if((t&62914560)===t&&(a=Ql+300-we(),10<a)){if(vu(r,t,ql,!zl),He(r,0,!0)!==0)break a;ou=t,r.timeoutHandle=Gd(gu.bind(null,r,n,Xl,tu,Zl,t,ql,Gl,Jl,zl,o,`Throttled`,-0,0),a);break a}gu(r,n,Xl,tu,Zl,t,ql,Gl,Jl,zl,o,null,-0,0)}}break}while(1);nd(e)}function gu(e,t,n,r,i,a,o,s,c,l,u,d,f,p){if(e.timeoutHandle=-1,d=t.subtreeFlags,d&8192||(d&16785408)==16785408){d={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Xt},Al(t,a,d);var m=(a&62914560)===a?Ql-we():(a&4194048)===a?$l-we():0;if(m=Kf(d,m),m!==null){ou=a,e.cancelPendingCommit=m(Iu.bind(null,e,t,a,n,r,i,o,s,c,u,d,null,f,p)),vu(e,a,o,!l);return}}Iu(e,t,a,n,r,i,o,s,c)}function _u(e){for(var t=e;;){var n=t.tag;if((n===0||n===11||n===15)&&t.flags&16384&&(n=t.updateQueue,n!==null&&(n=n.stores,n!==null)))for(var r=0;r<n.length;r++){var i=n[r],a=i.getSnapshot;i=i.value;try{if(!yr(a(),i))return!1}catch{return!1}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function vu(e,t,n,r){t&=~Kl,t&=~Gl,e.suspendedLanes|=t,e.pingedLanes&=~t,r&&(e.warmLanes|=t),r=e.expirationTimes;for(var i=t;0<i;){var a=31-Pe(i),o=1<<a;r[a]=-1,i&=~o}n!==0&&Ye(e,n,t)}function yu(){return K&6?!0:(rd(0,!1),!1)}function bu(){if(J!==null){if(X===0)var e=J.return;else e=J,Wi=Ui=null,Eo(e),ka=null,Aa=0,e=J;for(;e!==null;)Rc(e.alternate,e),e=e.return;J=null}}function xu(e,t){var n=e.timeoutHandle;n!==-1&&(e.timeoutHandle=-1,Kd(n)),n=e.cancelPendingCommit,n!==null&&(e.cancelPendingCommit=null,n()),ou=0,bu(),q=e,J=n=si(e.current,null),Y=t,X=0,Rl=null,zl=!1,Bl=Ue(e,t),Vl=!1,Jl=ql=Kl=Gl=Wl=Ul=0,Xl=Yl=null,Zl=!1,t&8&&(t|=t&32);var r=e.entangledLanes;if(r!==0)for(e=e.entanglements,r&=t;0<r;){var i=31-Pe(r),a=1<<i;t|=e[i],r&=~a}return Hl=t,Zr(),n}function Su(e,t){H=null,N.H=Fs,t===ya||t===xa?(t=Da(),X=3):t===ba?(t=Da(),X=4):X=t===$s?8:typeof t==`object`&&t&&typeof t.then==`function`?6:1,Rl=t,J===null&&(Ul=1,qs(e,hi(t,e.current)))}function Cu(){var e=eo.current;return e===null?!0:(Y&4194048)===Y?to===null:(Y&62914560)===Y||Y&536870912?e===to:!1}function wu(){var e=N.H;return N.H=Fs,e===null?Fs:e}function Tu(){var e=N.A;return N.A=Il,e}function Eu(){Ul=4,zl||(Y&4194048)!==Y&&eo.current!==null||(Bl=!0),!(Wl&134217727)&&!(Gl&134217727)||q===null||vu(q,Y,ql,!1)}function Du(e,t,n){var r=K;K|=2;var i=wu(),a=Tu();(q!==e||Y!==t)&&(tu=null,xu(e,t)),t=!1;var o=Ul;a:do try{if(X!==0&&J!==null){var s=J,c=Rl;switch(X){case 8:bu(),o=6;break a;case 3:case 2:case 9:case 6:eo.current===null&&(t=!0);var l=X;if(X=0,Rl=null,Nu(e,s,c,l),n&&Bl){o=0;break a}break;default:l=X,X=0,Rl=null,Nu(e,s,c,l)}}Ou(),o=Ul;break}catch(t){Su(e,t)}while(1);return t&&e.shellSuspendCounter++,Wi=Ui=null,K=r,N.H=i,N.A=a,J===null&&(q=null,Y=0,Zr()),o}function Ou(){for(;J!==null;)ju(J)}function ku(e,t){var n=K;K|=2;var r=wu(),a=Tu();q!==e||Y!==t?(tu=null,eu=we()+500,xu(e,t)):Bl=Ue(e,t);a:do try{if(X!==0&&J!==null){t=J;var o=Rl;b:switch(X){case 1:X=0,Rl=null,Nu(e,t,o,1);break;case 2:case 9:if(Ca(o)){X=0,Rl=null,Mu(t);break}t=function(){X!==2&&X!==9||q!==e||(X=7),nd(e)},o.then(t,t);break a;case 3:X=7;break a;case 4:X=5;break a;case 7:Ca(o)?(X=0,Rl=null,Mu(t)):(X=0,Rl=null,Nu(e,t,o,7));break;case 5:var s=null;switch(J.tag){case 26:s=J.memoizedState;case 5:case 27:var c=J;if(s?Uf(s):c.stateNode.complete){X=0,Rl=null;var l=c.sibling;if(l!==null)J=l;else{var u=c.return;u===null?J=null:(J=u,Pu(u))}break b}}X=0,Rl=null,Nu(e,t,o,5);break;case 6:X=0,Rl=null,Nu(e,t,o,6);break;case 8:bu(),Ul=6;break a;default:throw Error(i(462))}}Au();break}catch(t){Su(e,t)}while(1);return Wi=Ui=null,N.H=r,N.A=a,K=n,J===null?(q=null,Y=0,Zr(),Ul):0}function Au(){for(;J!==null&&!Se();)ju(J)}function ju(e){var t=kc(e.alternate,e,Hl);e.memoizedProps=e.pendingProps,t===null?Pu(e):J=t}function Mu(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=pc(n,t,t.pendingProps,t.type,void 0,Y);break;case 11:t=pc(n,t,t.pendingProps,t.type.render,t.ref,Y);break;case 5:Eo(t);default:Rc(n,t),t=J=ci(t,Hl),t=kc(n,t,Hl)}e.memoizedProps=e.pendingProps,t===null?Pu(e):J=t}function Nu(e,t,n,r){Wi=Ui=null,Eo(t),ka=null,Aa=0;var i=t.return;try{if(Qs(e,i,t,n,Y)){Ul=1,qs(e,hi(n,e.current)),J=null;return}}catch(t){if(i!==null)throw J=i,t;Ul=1,qs(e,hi(n,e.current)),J=null;return}t.flags&32768?(V||r===1?e=!0:Bl||Y&536870912?e=!1:(zl=e=!0,(r===2||r===9||r===3||r===6)&&(r=eo.current,r!==null&&r.tag===13&&(r.flags|=16384))),Fu(t,e)):Pu(t)}function Pu(e){var t=e;do{if(t.flags&32768){Fu(t,zl);return}e=t.return;var n=Ic(t.alternate,t,Hl);if(n!==null){J=n;return}if(t=t.sibling,t!==null){J=t;return}J=t=e}while(t!==null);Ul===0&&(Ul=5)}function Fu(e,t){do{var n=Lc(e.alternate,e);if(n!==null){n.flags&=32767,J=n;return}if(n=e.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&(e=e.sibling,e!==null)){J=e;return}J=e=n}while(e!==null);Ul=6,J=null}function Iu(e,t,n,r,a,o,s,c,l){e.cancelPendingCommit=null;do Vu();while(ru!==0);if(K&6)throw Error(i(327));if(t!==null){if(t===e.current)throw Error(i(177));if(o=t.lanes|t.childLanes,o|=Xr,Je(e,n,o,s,c,l),e===q&&(J=q=null,Y=0),au=t,iu=e,ou=n,su=o,cu=a,lu=r,t.subtreeFlags&10256||t.flags&10256?(e.callbackNode=null,e.callbackPriority=0,Yu(R,function(){return Hu(),null})):(e.callbackNode=null,e.callbackPriority=0),r=(t.flags&13878)!=0,t.subtreeFlags&13878||r){r=N.T,N.T=null,a=P.p,P.p=2,s=K,K|=4;try{rl(e,t,n)}finally{K=s,P.p=a,N.T=r}}ru=1,Lu(),Ru(),zu()}}function Lu(){if(ru===1){ru=0;var e=iu,t=au,n=(t.flags&13878)!=0;if(t.subtreeFlags&13878||n){n=N.T,N.T=null;var r=P.p;P.p=2;var i=K;K|=4;try{gl(t,e);var a=Rd,o=wr(e.containerInfo),s=a.focusedElem,c=a.selectionRange;if(o!==s&&s&&s.ownerDocument&&Cr(s.ownerDocument.documentElement,s)){if(c!==null&&Tr(s)){var l=c.start,u=c.end;if(u===void 0&&(u=l),`selectionStart`in s)s.selectionStart=l,s.selectionEnd=Math.min(u,s.value.length);else{var d=s.ownerDocument||document,f=d&&d.defaultView||window;if(f.getSelection){var p=f.getSelection(),m=s.textContent.length,h=Math.min(c.start,m),g=c.end===void 0?h:Math.min(c.end,m);!p.extend&&h>g&&(o=g,g=h,h=o);var _=Sr(s,h),v=Sr(s,g);if(_&&v&&(p.rangeCount!==1||p.anchorNode!==_.node||p.anchorOffset!==_.offset||p.focusNode!==v.node||p.focusOffset!==v.offset)){var y=d.createRange();y.setStart(_.node,_.offset),p.removeAllRanges(),h>g?(p.addRange(y),p.extend(v.node,v.offset)):(y.setEnd(v.node,v.offset),p.addRange(y))}}}}for(d=[],p=s;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof s.focus==`function`&&s.focus(),s=0;s<d.length;s++){var b=d[s];b.element.scrollLeft=b.left,b.element.scrollTop=b.top}}op=!!Ld,Rd=Ld=null}finally{K=i,P.p=r,N.T=n}}e.current=t,ru=2}}function Ru(){if(ru===2){ru=0;var e=iu,t=au,n=(t.flags&8772)!=0;if(t.subtreeFlags&8772||n){n=N.T,N.T=null;var r=P.p;P.p=2;var i=K;K|=4;try{il(e,t.alternate,t)}finally{K=i,P.p=r,N.T=n}}ru=3}}function zu(){if(ru===4||ru===3){ru=0,Ce();var e=iu,t=au,n=ou,r=lu;t.subtreeFlags&10256||t.flags&10256?ru=5:(ru=0,au=iu=null,Bu(e,e.pendingLanes));var i=e.pendingLanes;if(i===0&&(nu=null),$e(n),t=t.stateNode,Me&&typeof Me.onCommitFiberRoot==`function`)try{Me.onCommitFiberRoot(je,t,void 0,(t.current.flags&128)==128)}catch{}if(r!==null){t=N.T,i=P.p,P.p=2,N.T=null;try{for(var a=e.onRecoverableError,o=0;o<r.length;o++){var s=r[o];a(s.value,{componentStack:s.stack})}}finally{N.T=t,P.p=i}}ou&3&&Vu(),nd(e),i=e.pendingLanes,n&261930&&i&42?e===du?uu++:(uu=0,du=e):uu=0,rd(0,!1)}}function Bu(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,oa(t)))}function Vu(){return Lu(),Ru(),zu(),Hu()}function Hu(){if(ru!==5)return!1;var e=iu,t=su;su=0;var n=$e(ou),r=N.T,a=P.p;try{P.p=32>n?32:n,N.T=null,n=cu,cu=null;var o=iu,s=ou;if(ru=0,au=iu=null,ou=0,K&6)throw Error(i(331));var c=K;if(K|=4,Nl(o.current),Tl(o,o.current,s,n),K=c,rd(0,!1),Me&&typeof Me.onPostCommitFiberRoot==`function`)try{Me.onPostCommitFiberRoot(je,o)}catch{}return!0}finally{P.p=a,N.T=r,Bu(e,t)}}function Uu(e,t,n){t=hi(n,t),t=Ys(e.stateNode,t,2),e=Va(e,t,2),e!==null&&(qe(e,2),nd(e))}function Z(e,t,n){if(e.tag===3)Uu(e,e,n);else for(;t!==null;){if(t.tag===3){Uu(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(nu===null||!nu.has(r))){e=hi(n,e),n=Xs(2),r=Va(t,n,2),r!==null&&(Zs(n,r,t,e),qe(r,2),nd(r));break}}t=t.return}}function Wu(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Ll;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(Vl=!0,i.add(n),e=Gu.bind(null,e,t,n),t.then(e,e))}function Gu(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,q===e&&(Y&n)===n&&(Ul===4||Ul===3&&(Y&62914560)===Y&&300>we()-Ql?!(K&2)&&xu(e,0):Kl|=n,Jl===Y&&(Jl=0)),nd(e)}function Ku(e,t){t===0&&(t=Ge()),e=ei(e,t),e!==null&&(qe(e,t),nd(e))}function qu(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Ku(e,n)}function Ju(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,a=e.memoizedState;a!==null&&(n=a.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(i(314))}r!==null&&r.delete(t),Ku(e,n)}function Yu(e,t){return be(e,t)}var Xu=null,Zu=null,Qu=!1,$u=!1,ed=!1,td=0;function nd(e){e!==Zu&&e.next===null&&(Zu===null?Xu=Zu=e:Zu=Zu.next=e),$u=!0,Qu||(Qu=!0,ld())}function rd(e,t){if(!ed&&$u){ed=!0;do for(var n=!1,r=Xu;r!==null;){if(!t)if(e!==0){var i=r.pendingLanes;if(i===0)var a=0;else{var o=r.suspendedLanes,s=r.pingedLanes;a=(1<<31-Pe(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,cd(r,a))}else a=Y,a=He(r,r===q?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||Ue(r,a)||(n=!0,cd(r,a));r=r.next}while(n);ed=!1}}function id(){ad()}function ad(){$u=Qu=!1;var e=0;td!==0&&Wd()&&(e=td);for(var t=we(),n=null,r=Xu;r!==null;){var i=r.next,a=od(r,t);a===0?(r.next=null,n===null?Xu=i:n.next=i,i===null&&(Zu=n)):(n=r,(e!==0||a&3)&&($u=!0)),r=i}ru!==0&&ru!==5||rd(e,!1),td!==0&&(td=0)}function od(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0<a;){var o=31-Pe(a),s=1<<o,c=i[o];c===-1?((s&n)===0||(s&r)!==0)&&(i[o]=We(s,t)):c<=t&&(e.expiredLanes|=s),a&=~s}if(t=q,n=Y,n=He(e,e===t?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r=e.callbackNode,n===0||e===t&&(X===2||X===9)||e.cancelPendingCommit!==null)return r!==null&&r!==null&&xe(r),e.callbackNode=null,e.callbackPriority=0;if(!(n&3)||Ue(e,n)){if(t=n&-n,t===e.callbackPriority)return t;switch(r!==null&&xe(r),$e(n)){case 2:case 8:n=De;break;case 32:n=R;break;case 268435456:n=z;break;default:n=R}return r=sd.bind(null,e),n=be(n,r),e.callbackPriority=t,e.callbackNode=n,t}return r!==null&&r!==null&&xe(r),e.callbackPriority=2,e.callbackNode=null,2}function sd(e,t){if(ru!==0&&ru!==5)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(Vu()&&e.callbackNode!==n)return null;var r=Y;return r=He(e,e===q?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r===0?null:(hu(e,r,t),od(e,we()),e.callbackNode!=null&&e.callbackNode===n?sd.bind(null,e):null)}function cd(e,t){if(Vu())return null;hu(e,t,!0)}function ld(){Jd(function(){K&6?be(Ee,id):ad()})}function ud(){if(td===0){var e=la;e===0&&(e=Re,Re<<=1,!(Re&261888)&&(Re=256)),td=e}return td}function dd(e){return e==null||typeof e==`symbol`||typeof e==`boolean`?null:typeof e==`function`?e:Yt(``+e)}function fd(e,t){var n=t.ownerDocument.createElement(`input`);return n.name=t.name,n.value=t.value,e.id&&n.setAttribute(`form`,e.id),t.parentNode.insertBefore(n,t),e=new FormData(e),n.parentNode.removeChild(n),e}function pd(e,t,n,r,i){if(t===`submit`&&n&&n.stateNode===i){var a=dd((i[it]||null).action),o=r.submitter;o&&(t=(t=o[it]||null)?dd(t.formAction):o.getAttribute(`formAction`),t!==null&&(a=t,o=null));var s=new vn(`action`,`action`,null,r,i);e.push({event:s,listeners:[{instance:null,listener:function(){if(r.defaultPrevented){if(td!==0){var e=o?fd(i,o):new FormData(i);xs(n,{pending:!0,data:e,method:i.method,action:a},null,e)}}else typeof a==`function`&&(s.preventDefault(),e=o?fd(i,o):new FormData(i),xs(n,{pending:!0,data:e,method:i.method,action:a},a,e))},currentTarget:i}]})}}for(var md=0;md<Gr.length;md++){var hd=Gr[md];Kr(hd.toLowerCase(),`on`+(hd[0].toUpperCase()+hd.slice(1)))}Kr(Lr,`onAnimationEnd`),Kr(Rr,`onAnimationIteration`),Kr(zr,`onAnimationStart`),Kr(`dblclick`,`onDoubleClick`),Kr(`focusin`,`onFocus`),Kr(`focusout`,`onBlur`),Kr(Br,`onTransitionRun`),Kr(Vr,`onTransitionStart`),Kr(Hr,`onTransitionCancel`),Kr(Ur,`onTransitionEnd`),B(`onMouseEnter`,[`mouseout`,`mouseover`]),B(`onMouseLeave`,[`mouseout`,`mouseover`]),B(`onPointerEnter`,[`pointerout`,`pointerover`]),B(`onPointerLeave`,[`pointerout`,`pointerover`]),yt(`onChange`,`change click focusin focusout input keydown keyup selectionchange`.split(` `)),yt(`onSelect`,`focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange`.split(` `)),yt(`onBeforeInput`,[`compositionend`,`keypress`,`textInput`,`paste`]),yt(`onCompositionEnd`,`compositionend focusout keydown keypress keyup mousedown`.split(` `)),yt(`onCompositionStart`,`compositionstart focusout keydown keypress keyup mousedown`.split(` `)),yt(`onCompositionUpdate`,`compositionupdate focusout keydown keypress keyup mousedown`.split(` `));var gd=`abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting`.split(` `),_d=new Set(`beforetoggle cancel close invalid load scroll scrollend toggle`.split(` `).concat(gd));function vd(e,t){t=(t&4)!=0;for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;a:{var a=void 0;if(t)for(var o=r.length-1;0<=o;o--){var s=r[o],c=s.instance,l=s.currentTarget;if(s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){qr(e)}i.currentTarget=null,a=c}else for(o=0;o<r.length;o++){if(s=r[o],c=s.instance,l=s.currentTarget,s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){qr(e)}i.currentTarget=null,a=c}}}}function Q(e,t){var n=t[ot];n===void 0&&(n=t[ot]=new Set);var r=e+`__bubble`;n.has(r)||(Sd(t,e,2,!1),n.add(r))}function yd(e,t,n){var r=0;t&&(r|=4),Sd(n,e,r,t)}var bd=`_reactListening`+Math.random().toString(36).slice(2);function xd(e){if(!e[bd]){e[bd]=!0,_t.forEach(function(t){t!==`selectionchange`&&(_d.has(t)||yd(t,!1,e),yd(t,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[bd]||(t[bd]=!0,yd(`selectionchange`,!1,t))}}function Sd(e,t,n,r){switch(pp(t)){case 2:var i=sp;break;case 8:i=cp;break;default:i=lp}n=i.bind(null,t,n,e),i=void 0,!sn||t!==`touchstart`&&t!==`touchmove`&&t!==`wheel`||(i=!0),r?i===void 0?e.addEventListener(t,n,!0):e.addEventListener(t,n,{capture:!0,passive:i}):i===void 0?e.addEventListener(t,n,!1):e.addEventListener(t,n,{passive:i})}function Cd(e,t,n,r,i){var a=r;if(!(t&1)&&!(t&2)&&r!==null)a:for(;;){if(r===null)return;var s=r.tag;if(s===3||s===4){var c=r.stateNode.containerInfo;if(c===i)break;if(s===4)for(s=r.return;s!==null;){var l=s.tag;if((l===3||l===4)&&s.stateNode.containerInfo===i)return;s=s.return}for(;c!==null;){if(s=ft(c),s===null)return;if(l=s.tag,l===5||l===6||l===26||l===27){r=a=s;continue a}c=c.parentNode}}r=r.return}rn(function(){var r=a,i=Qt(n),s=[];a:{var c=Wr.get(e);if(c!==void 0){var l=vn,u=e;switch(e){case`keypress`:if(pn(n)===0)break a;case`keydown`:case`keyup`:l=In;break;case`focusin`:u=`focus`,l=Dn;break;case`focusout`:u=`blur`,l=Dn;break;case`beforeblur`:case`afterblur`:l=Dn;break;case`click`:if(n.button===2)break a;case`auxclick`:case`dblclick`:case`mousedown`:case`mousemove`:case`mouseup`:case`mouseout`:case`mouseover`:case`contextmenu`:l=Tn;break;case`drag`:case`dragend`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`dragstart`:case`drop`:l=En;break;case`touchcancel`:case`touchend`:case`touchmove`:case`touchstart`:l=Rn;break;case Lr:case Rr:case zr:l=On;break;case Ur:l=zn;break;case`scroll`:case`scrollend`:l=bn;break;case`wheel`:l=Bn;break;case`copy`:case`cut`:case`paste`:l=kn;break;case`gotpointercapture`:case`lostpointercapture`:case`pointercancel`:case`pointerdown`:case`pointermove`:case`pointerout`:case`pointerover`:case`pointerup`:l=Ln;break;case`toggle`:case`beforetoggle`:l=Vn}var d=(t&4)!=0,f=!d&&(e===`scroll`||e===`scrollend`),p=d?c===null?null:c+`Capture`:c;d=[];for(var m=r,h;m!==null;){var g=m;if(h=g.stateNode,g=g.tag,g!==5&&g!==26&&g!==27||h===null||p===null||(g=an(m,p),g!=null&&d.push(wd(m,g,h))),f)break;m=m.return}0<d.length&&(c=new l(c,u,null,n,i),s.push({event:c,listeners:d}))}}if(!(t&7)){a:{if(c=e===`mouseover`||e===`pointerover`,l=e===`mouseout`||e===`pointerout`,c&&n!==Zt&&(u=n.relatedTarget||n.fromElement)&&(ft(u)||u[at]))break a;if((l||c)&&(c=i.window===i?i:(c=i.ownerDocument)?c.defaultView||c.parentWindow:window,l?(u=n.relatedTarget||n.toElement,l=r,u=u?ft(u):null,u!==null&&(f=o(u),d=u.tag,u!==f||d!==5&&d!==27&&d!==6)&&(u=null)):(l=null,u=r),l!==u)){if(d=Tn,g=`onMouseLeave`,p=`onMouseEnter`,m=`mouse`,(e===`pointerout`||e===`pointerover`)&&(d=Ln,g=`onPointerLeave`,p=`onPointerEnter`,m=`pointer`),f=l==null?c:mt(l),h=u==null?c:mt(u),c=new d(g,m+`leave`,l,n,i),c.target=f,c.relatedTarget=h,g=null,ft(i)===r&&(d=new d(p,m+`enter`,u,n,i),d.target=h,d.relatedTarget=f,g=d),f=g,l&&u)b:{for(d=Ed,p=l,m=u,h=0,g=p;g;g=d(g))h++;g=0;for(var _=m;_;_=d(_))g++;for(;0<h-g;)p=d(p),h--;for(;0<g-h;)m=d(m),g--;for(;h--;){if(p===m||m!==null&&p===m.alternate){d=p;break b}p=d(p),m=d(m)}d=null}else d=null;l!==null&&Dd(s,c,l,d,!1),u!==null&&f!==null&&Dd(s,f,u,d,!0)}}a:{if(c=r?mt(r):window,l=c.nodeName&&c.nodeName.toLowerCase(),l===`select`||l===`input`&&c.type===`file`)var v=sr;else if(tr(c))if(cr)v=_r;else{v=hr;var y=mr}else l=c.nodeName,!l||l.toLowerCase()!==`input`||c.type!==`checkbox`&&c.type!==`radio`?r&&Kt(r.elementType)&&(v=sr):v=gr;if(v&&(v=v(e,r))){nr(s,v,n,i);break a}y&&y(e,c,r),e===`focusout`&&r&&c.type===`number`&&r.memoizedProps.value!=null&&Rt(c,`number`,c.value)}switch(y=r?mt(r):window,e){case`focusin`:(tr(y)||y.contentEditable===`true`)&&(Dr=y,Or=r,kr=null);break;case`focusout`:kr=Or=Dr=null;break;case`mousedown`:Ar=!0;break;case`contextmenu`:case`mouseup`:case`dragend`:Ar=!1,jr(s,n,i);break;case`selectionchange`:if(Er)break;case`keydown`:case`keyup`:jr(s,n,i)}var b;if(Un)b:{switch(e){case`compositionstart`:var x=`onCompositionStart`;break b;case`compositionend`:x=`onCompositionEnd`;break b;case`compositionupdate`:x=`onCompositionUpdate`;break b}x=void 0}else Zn?Yn(e,n)&&(x=`onCompositionEnd`):e===`keydown`&&n.keyCode===229&&(x=`onCompositionStart`);x&&(Kn&&n.locale!==`ko`&&(Zn||x!==`onCompositionStart`?x===`onCompositionEnd`&&Zn&&(b=fn()):(ln=i,un=`value`in ln?ln.value:ln.textContent,Zn=!0)),y=Td(r,x),0<y.length&&(x=new An(x,e,null,n,i),s.push({event:x,listeners:y}),b?x.data=b:(b=Xn(n),b!==null&&(x.data=b)))),(b=Gn?Qn(e,n):$n(e,n))&&(x=Td(r,`onBeforeInput`),0<x.length&&(y=new An(`onBeforeInput`,`beforeinput`,null,n,i),s.push({event:y,listeners:x}),y.data=b)),pd(s,e,r,n,i)}vd(s,t)})}function wd(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Td(e,t){for(var n=t+`Capture`,r=[];e!==null;){var i=e,a=i.stateNode;if(i=i.tag,i!==5&&i!==26&&i!==27||a===null||(i=an(e,n),i!=null&&r.unshift(wd(e,i,a)),i=an(e,t),i!=null&&r.push(wd(e,i,a))),e.tag===3)return r;e=e.return}return[]}function Ed(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Dd(e,t,n,r,i){for(var a=t._reactName,o=[];n!==null&&n!==r;){var s=n,c=s.alternate,l=s.stateNode;if(s=s.tag,c!==null&&c===r)break;s!==5&&s!==26&&s!==27||l===null||(c=l,i?(l=an(n,a),l!=null&&o.unshift(wd(n,l,c))):i||(l=an(n,a),l!=null&&o.push(wd(n,l,c)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var Od=/\r\n?/g,kd=/\u0000|\uFFFD/g;function Ad(e){return(typeof e==`string`?e:``+e).replace(Od,`
176
+ `).replace(kd,``)}function jd(e,t){return t=Ad(t),Ad(e)===t}function $(e,t,n,r,a,o){switch(n){case`children`:typeof r==`string`?t===`body`||t===`textarea`&&r===``||Ht(e,r):(typeof r==`number`||typeof r==`bigint`)&&t!==`body`&&Ht(e,``+r);break;case`className`:Tt(e,`class`,r);break;case`tabIndex`:Tt(e,`tabindex`,r);break;case`dir`:case`role`:case`viewBox`:case`width`:case`height`:Tt(e,n,r);break;case`style`:Gt(e,r,o);break;case`data`:if(t!==`object`){Tt(e,`data`,r);break}case`src`:case`href`:if(r===``&&(t!==`a`||n!==`href`)){e.removeAttribute(n);break}if(r==null||typeof r==`function`||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=Yt(``+r),e.setAttribute(n,r);break;case`action`:case`formAction`:if(typeof r==`function`){e.setAttribute(n,`javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')`);break}else typeof o==`function`&&(n===`formAction`?(t!==`input`&&$(e,t,`name`,a.name,a,null),$(e,t,`formEncType`,a.formEncType,a,null),$(e,t,`formMethod`,a.formMethod,a,null),$(e,t,`formTarget`,a.formTarget,a,null)):($(e,t,`encType`,a.encType,a,null),$(e,t,`method`,a.method,a,null),$(e,t,`target`,a.target,a,null)));if(r==null||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=Yt(``+r),e.setAttribute(n,r);break;case`onClick`:r!=null&&(e.onclick=Xt);break;case`onScroll`:r!=null&&Q(`scroll`,e);break;case`onScrollEnd`:r!=null&&Q(`scrollend`,e);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));e.innerHTML=n}}break;case`multiple`:e.multiple=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`muted`:e.muted=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`defaultValue`:case`defaultChecked`:case`innerHTML`:case`ref`:break;case`autoFocus`:break;case`xlinkHref`:if(r==null||typeof r==`function`||typeof r==`boolean`||typeof r==`symbol`){e.removeAttribute(`xlink:href`);break}n=Yt(``+r),e.setAttributeNS(`http://www.w3.org/1999/xlink`,`xlink:href`,n);break;case`contentEditable`:case`spellCheck`:case`draggable`:case`value`:case`autoReverse`:case`externalResourcesRequired`:case`focusable`:case`preserveAlpha`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``+r):e.removeAttribute(n);break;case`inert`:case`allowFullScreen`:case`async`:case`autoPlay`:case`controls`:case`default`:case`defer`:case`disabled`:case`disablePictureInPicture`:case`disableRemotePlayback`:case`formNoValidate`:case`hidden`:case`loop`:case`noModule`:case`noValidate`:case`open`:case`playsInline`:case`readOnly`:case`required`:case`reversed`:case`scoped`:case`seamless`:case`itemScope`:r&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``):e.removeAttribute(n);break;case`capture`:case`download`:!0===r?e.setAttribute(n,``):!1!==r&&r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,r):e.removeAttribute(n);break;case`cols`:case`rows`:case`size`:case`span`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`&&!isNaN(r)&&1<=r?e.setAttribute(n,r):e.removeAttribute(n);break;case`rowSpan`:case`start`:r==null||typeof r==`function`||typeof r==`symbol`||isNaN(r)?e.removeAttribute(n):e.setAttribute(n,r);break;case`popover`:Q(`beforetoggle`,e),Q(`toggle`,e),wt(e,`popover`,r);break;case`xlinkActuate`:Et(e,`http://www.w3.org/1999/xlink`,`xlink:actuate`,r);break;case`xlinkArcrole`:Et(e,`http://www.w3.org/1999/xlink`,`xlink:arcrole`,r);break;case`xlinkRole`:Et(e,`http://www.w3.org/1999/xlink`,`xlink:role`,r);break;case`xlinkShow`:Et(e,`http://www.w3.org/1999/xlink`,`xlink:show`,r);break;case`xlinkTitle`:Et(e,`http://www.w3.org/1999/xlink`,`xlink:title`,r);break;case`xlinkType`:Et(e,`http://www.w3.org/1999/xlink`,`xlink:type`,r);break;case`xmlBase`:Et(e,`http://www.w3.org/XML/1998/namespace`,`xml:base`,r);break;case`xmlLang`:Et(e,`http://www.w3.org/XML/1998/namespace`,`xml:lang`,r);break;case`xmlSpace`:Et(e,`http://www.w3.org/XML/1998/namespace`,`xml:space`,r);break;case`is`:wt(e,`is`,r);break;case`innerText`:case`textContent`:break;default:(!(2<n.length)||n[0]!==`o`&&n[0]!==`O`||n[1]!==`n`&&n[1]!==`N`)&&(n=qt.get(n)||n,wt(e,n,r))}}function Md(e,t,n,r,a,o){switch(n){case`style`:Gt(e,r,o);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));e.innerHTML=n}}break;case`children`:typeof r==`string`?Ht(e,r):(typeof r==`number`||typeof r==`bigint`)&&Ht(e,``+r);break;case`onScroll`:r!=null&&Q(`scroll`,e);break;case`onScrollEnd`:r!=null&&Q(`scrollend`,e);break;case`onClick`:r!=null&&(e.onclick=Xt);break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`innerHTML`:case`ref`:break;case`innerText`:case`textContent`:break;default:if(!vt.hasOwnProperty(n))a:{if(n[0]===`o`&&n[1]===`n`&&(a=n.endsWith(`Capture`),t=n.slice(2,a?n.length-7:void 0),o=e[it]||null,o=o==null?null:o[n],typeof o==`function`&&e.removeEventListener(t,o,a),typeof r==`function`)){typeof o!=`function`&&o!==null&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(t,r,a);break a}n in e?e[n]=r:!0===r?e.setAttribute(n,``):wt(e,n,r)}}}function Nd(e,t,n){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`img`:Q(`error`,e),Q(`load`,e);var r=!1,a=!1,o;for(o in n)if(n.hasOwnProperty(o)){var s=n[o];if(s!=null)switch(o){case`src`:r=!0;break;case`srcSet`:a=!0;break;case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:$(e,t,o,s,n,null)}}a&&$(e,t,`srcSet`,n.srcSet,n,null),r&&$(e,t,`src`,n.src,n,null);return;case`input`:Q(`invalid`,e);var c=o=s=a=null,l=null,u=null;for(r in n)if(n.hasOwnProperty(r)){var d=n[r];if(d!=null)switch(r){case`name`:a=d;break;case`type`:s=d;break;case`checked`:l=d;break;case`defaultChecked`:u=d;break;case`value`:o=d;break;case`defaultValue`:c=d;break;case`children`:case`dangerouslySetInnerHTML`:if(d!=null)throw Error(i(137,t));break;default:$(e,t,r,d,n,null)}}Lt(e,o,c,l,u,s,a,!1);return;case`select`:for(a in Q(`invalid`,e),r=s=o=null,n)if(n.hasOwnProperty(a)&&(c=n[a],c!=null))switch(a){case`value`:o=c;break;case`defaultValue`:s=c;break;case`multiple`:r=c;default:$(e,t,a,c,n,null)}t=o,n=s,e.multiple=!!r,t==null?n!=null&&zt(e,!!r,n,!0):zt(e,!!r,t,!1);return;case`textarea`:for(s in Q(`invalid`,e),o=a=r=null,n)if(n.hasOwnProperty(s)&&(c=n[s],c!=null))switch(s){case`value`:r=c;break;case`defaultValue`:a=c;break;case`children`:o=c;break;case`dangerouslySetInnerHTML`:if(c!=null)throw Error(i(91));break;default:$(e,t,s,c,n,null)}Vt(e,r,a,o);return;case`option`:for(l in n)if(n.hasOwnProperty(l)&&(r=n[l],r!=null))switch(l){case`selected`:e.selected=r&&typeof r!=`function`&&typeof r!=`symbol`;break;default:$(e,t,l,r,n,null)}return;case`dialog`:Q(`beforetoggle`,e),Q(`toggle`,e),Q(`cancel`,e),Q(`close`,e);break;case`iframe`:case`object`:Q(`load`,e);break;case`video`:case`audio`:for(r=0;r<gd.length;r++)Q(gd[r],e);break;case`image`:Q(`error`,e),Q(`load`,e);break;case`details`:Q(`toggle`,e);break;case`embed`:case`source`:case`link`:Q(`error`,e),Q(`load`,e);case`area`:case`base`:case`br`:case`col`:case`hr`:case`keygen`:case`meta`:case`param`:case`track`:case`wbr`:case`menuitem`:for(u in n)if(n.hasOwnProperty(u)&&(r=n[u],r!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:$(e,t,u,r,n,null)}return;default:if(Kt(t)){for(d in n)n.hasOwnProperty(d)&&(r=n[d],r!==void 0&&Md(e,t,d,r,n,void 0));return}}for(c in n)n.hasOwnProperty(c)&&(r=n[c],r!=null&&$(e,t,c,r,n,null))}function Pd(e,t,n,r){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`input`:var a=null,o=null,s=null,c=null,l=null,u=null,d=null;for(m in n){var f=n[m];if(n.hasOwnProperty(m)&&f!=null)switch(m){case`checked`:break;case`value`:break;case`defaultValue`:l=f;default:r.hasOwnProperty(m)||$(e,t,m,null,r,f)}}for(var p in r){var m=r[p];if(f=n[p],r.hasOwnProperty(p)&&(m!=null||f!=null))switch(p){case`type`:o=m;break;case`name`:a=m;break;case`checked`:u=m;break;case`defaultChecked`:d=m;break;case`value`:s=m;break;case`defaultValue`:c=m;break;case`children`:case`dangerouslySetInnerHTML`:if(m!=null)throw Error(i(137,t));break;default:m!==f&&$(e,t,p,m,r,f)}}It(e,s,c,l,u,d,o,a);return;case`select`:for(o in m=s=c=p=null,n)if(l=n[o],n.hasOwnProperty(o)&&l!=null)switch(o){case`value`:break;case`multiple`:m=l;default:r.hasOwnProperty(o)||$(e,t,o,null,r,l)}for(a in r)if(o=r[a],l=n[a],r.hasOwnProperty(a)&&(o!=null||l!=null))switch(a){case`value`:p=o;break;case`defaultValue`:c=o;break;case`multiple`:s=o;default:o!==l&&$(e,t,a,o,r,l)}t=c,n=s,r=m,p==null?!!r!=!!n&&(t==null?zt(e,!!n,n?[]:``,!1):zt(e,!!n,t,!0)):zt(e,!!n,p,!1);return;case`textarea`:for(c in m=p=null,n)if(a=n[c],n.hasOwnProperty(c)&&a!=null&&!r.hasOwnProperty(c))switch(c){case`value`:break;case`children`:break;default:$(e,t,c,null,r,a)}for(s in r)if(a=r[s],o=n[s],r.hasOwnProperty(s)&&(a!=null||o!=null))switch(s){case`value`:p=a;break;case`defaultValue`:m=a;break;case`children`:break;case`dangerouslySetInnerHTML`:if(a!=null)throw Error(i(91));break;default:a!==o&&$(e,t,s,a,r,o)}Bt(e,p,m);return;case`option`:for(var h in n)if(p=n[h],n.hasOwnProperty(h)&&p!=null&&!r.hasOwnProperty(h))switch(h){case`selected`:e.selected=!1;break;default:$(e,t,h,null,r,p)}for(l in r)if(p=r[l],m=n[l],r.hasOwnProperty(l)&&p!==m&&(p!=null||m!=null))switch(l){case`selected`:e.selected=p&&typeof p!=`function`&&typeof p!=`symbol`;break;default:$(e,t,l,p,r,m)}return;case`img`:case`link`:case`area`:case`base`:case`br`:case`col`:case`embed`:case`hr`:case`keygen`:case`meta`:case`param`:case`source`:case`track`:case`wbr`:case`menuitem`:for(var g in n)p=n[g],n.hasOwnProperty(g)&&p!=null&&!r.hasOwnProperty(g)&&$(e,t,g,null,r,p);for(u in r)if(p=r[u],m=n[u],r.hasOwnProperty(u)&&p!==m&&(p!=null||m!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:if(p!=null)throw Error(i(137,t));break;default:$(e,t,u,p,r,m)}return;default:if(Kt(t)){for(var _ in n)p=n[_],n.hasOwnProperty(_)&&p!==void 0&&!r.hasOwnProperty(_)&&Md(e,t,_,void 0,r,p);for(d in r)p=r[d],m=n[d],!r.hasOwnProperty(d)||p===m||p===void 0&&m===void 0||Md(e,t,d,p,r,m);return}}for(var v in n)p=n[v],n.hasOwnProperty(v)&&p!=null&&!r.hasOwnProperty(v)&&$(e,t,v,null,r,p);for(f in r)p=r[f],m=n[f],!r.hasOwnProperty(f)||p===m||p==null&&m==null||$(e,t,f,p,r,m)}function Fd(e){switch(e){case`css`:case`script`:case`font`:case`img`:case`image`:case`input`:case`link`:return!0;default:return!1}}function Id(){if(typeof performance.getEntriesByType==`function`){for(var e=0,t=0,n=performance.getEntriesByType(`resource`),r=0;r<n.length;r++){var i=n[r],a=i.transferSize,o=i.initiatorType,s=i.duration;if(a&&s&&Fd(o)){for(o=0,s=i.responseEnd,r+=1;r<n.length;r++){var c=n[r],l=c.startTime;if(l>s)break;var u=c.transferSize,d=c.initiatorType;u&&Fd(d)&&(c=c.responseEnd,o+=u*(c<s?1:(s-l)/(c-l)))}if(--r,t+=8*(a+o)/(i.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e==`number`)?e:5}var Ld=null,Rd=null;function zd(e){return e.nodeType===9?e:e.ownerDocument}function Bd(e){switch(e){case`http://www.w3.org/2000/svg`:return 1;case`http://www.w3.org/1998/Math/MathML`:return 2;default:return 0}}function Vd(e,t){if(e===0)switch(t){case`svg`:return 1;case`math`:return 2;default:return 0}return e===1&&t===`foreignObject`?0:e}function Hd(e,t){return e===`textarea`||e===`noscript`||typeof t.children==`string`||typeof t.children==`number`||typeof t.children==`bigint`||typeof t.dangerouslySetInnerHTML==`object`&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var Ud=null;function Wd(){var e=window.event;return e&&e.type===`popstate`?e===Ud?!1:(Ud=e,!0):(Ud=null,!1)}var Gd=typeof setTimeout==`function`?setTimeout:void 0,Kd=typeof clearTimeout==`function`?clearTimeout:void 0,qd=typeof Promise==`function`?Promise:void 0,Jd=typeof queueMicrotask==`function`?queueMicrotask:qd===void 0?Gd:function(e){return qd.resolve(null).then(e).catch(Yd)};function Yd(e){setTimeout(function(){throw e})}function Xd(e){return e===`head`}function Zd(e,t){var n=t,r=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8)if(n=i.data,n===`/$`||n===`/&`){if(r===0){e.removeChild(i),Mp(t);return}r--}else if(n===`$`||n===`$?`||n===`$~`||n===`$!`||n===`&`)r++;else if(n===`html`)ff(e.ownerDocument.documentElement);else if(n===`head`){n=e.ownerDocument.head,ff(n);for(var a=n.firstChild;a;){var o=a.nextSibling,s=a.nodeName;a[ut]||s===`SCRIPT`||s===`STYLE`||s===`LINK`&&a.rel.toLowerCase()===`stylesheet`||n.removeChild(a),a=o}}else n===`body`&&ff(e.ownerDocument.body);n=i}while(n);Mp(t)}function Qd(e,t){var n=e;e=0;do{var r=n.nextSibling;if(n.nodeType===1?t?(n._stashedDisplay=n.style.display,n.style.display=`none`):(n.style.display=n._stashedDisplay||``,n.getAttribute(`style`)===``&&n.removeAttribute(`style`)):n.nodeType===3&&(t?(n._stashedText=n.nodeValue,n.nodeValue=``):n.nodeValue=n._stashedText||``),r&&r.nodeType===8)if(n=r.data,n===`/$`){if(e===0)break;e--}else n!==`$`&&n!==`$?`&&n!==`$~`&&n!==`$!`||e++;n=r}while(n)}function $d(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var n=t;switch(t=t.nextSibling,n.nodeName){case`HTML`:case`HEAD`:case`BODY`:$d(n),dt(n);continue;case`SCRIPT`:case`STYLE`:continue;case`LINK`:if(n.rel.toLowerCase()===`stylesheet`)continue}e.removeChild(n)}}function ef(e,t,n,r){for(;e.nodeType===1;){var i=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!r&&(e.nodeName!==`INPUT`||e.type!==`hidden`))break}else if(!r)if(t===`input`&&e.type===`hidden`){var a=i.name==null?null:``+i.name;if(i.type===`hidden`&&e.getAttribute(`name`)===a)return e}else return e;else if(!e[ut])switch(t){case`meta`:if(!e.hasAttribute(`itemprop`))break;return e;case`link`:if(a=e.getAttribute(`rel`),a===`stylesheet`&&e.hasAttribute(`data-precedence`)||a!==i.rel||e.getAttribute(`href`)!==(i.href==null||i.href===``?null:i.href)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin)||e.getAttribute(`title`)!==(i.title==null?null:i.title))break;return e;case`style`:if(e.hasAttribute(`data-precedence`))break;return e;case`script`:if(a=e.getAttribute(`src`),(a!==(i.src==null?null:i.src)||e.getAttribute(`type`)!==(i.type==null?null:i.type)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin))&&a&&e.hasAttribute(`async`)&&!e.hasAttribute(`itemprop`))break;return e;default:return e}if(e=sf(e.nextSibling),e===null)break}return null}function tf(e,t,n){if(t===``)return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!n||(e=sf(e.nextSibling),e===null))return null;return e}function nf(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!t||(e=sf(e.nextSibling),e===null))return null;return e}function rf(e){return e.data===`$?`||e.data===`$~`}function af(e){return e.data===`$!`||e.data===`$?`&&e.ownerDocument.readyState!==`loading`}function of(e,t){var n=e.ownerDocument;if(e.data===`$~`)e._reactRetry=t;else if(e.data!==`$?`||n.readyState!==`loading`)t();else{var r=function(){t(),n.removeEventListener(`DOMContentLoaded`,r)};n.addEventListener(`DOMContentLoaded`,r),e._reactRetry=r}}function sf(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t===`$`||t===`$!`||t===`$?`||t===`$~`||t===`&`||t===`F!`||t===`F`)break;if(t===`/$`||t===`/&`)return null}}return e}var cf=null;function lf(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`/$`||n===`/&`){if(t===0)return sf(e.nextSibling);t--}else n!==`$`&&n!==`$!`&&n!==`$?`&&n!==`$~`&&n!==`&`||t++}e=e.nextSibling}return null}function uf(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`$`||n===`$!`||n===`$?`||n===`$~`||n===`&`){if(t===0)return e;t--}else n!==`/$`&&n!==`/&`||t++}e=e.previousSibling}return null}function df(e,t,n){switch(t=zd(n),e){case`html`:if(e=t.documentElement,!e)throw Error(i(452));return e;case`head`:if(e=t.head,!e)throw Error(i(453));return e;case`body`:if(e=t.body,!e)throw Error(i(454));return e;default:throw Error(i(451))}}function ff(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);dt(e)}var pf=new Map,mf=new Set;function hf(e){return typeof e.getRootNode==`function`?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var gf=P.d;P.d={f:_f,r:vf,D:xf,C:Sf,L:Cf,m:wf,X:Ef,S:Tf,M:Df};function _f(){var e=gf.f(),t=yu();return e||t}function vf(e){var t=pt(e);t!==null&&t.tag===5&&t.type===`form`?Cs(t):gf.r(e)}var yf=typeof document>`u`?null:document;function bf(e,t,n){var r=yf;if(r&&typeof t==`string`&&t){var i=Ft(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),mf.has(i)||(mf.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Nd(t,`link`,e),gt(t),r.head.appendChild(t)))}}function xf(e){gf.D(e),bf(`dns-prefetch`,e,null)}function Sf(e,t){gf.C(e,t),bf(`preconnect`,e,t)}function Cf(e,t,n){gf.L(e,t,n);var r=yf;if(r&&e&&t){var i=`link[rel="preload"][as="`+Ft(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+Ft(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+Ft(n.imageSizes)+`"]`)):i+=`[href="`+Ft(e)+`"]`;var a=i;switch(t){case`style`:a=kf(e);break;case`script`:a=Nf(e)}pf.has(a)||(e=f({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),pf.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(Af(a))||t===`script`&&r.querySelector(Pf(a))||(t=r.createElement(`link`),Nd(t,`link`,e),gt(t),r.head.appendChild(t)))}}function wf(e,t){gf.m(e,t);var n=yf;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+Ft(r)+`"][href="`+Ft(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Nf(e)}if(!pf.has(a)&&(e=f({rel:`modulepreload`,href:e},t),pf.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(Pf(a)))return}r=n.createElement(`link`),Nd(r,`link`,e),gt(r),n.head.appendChild(r)}}}function Tf(e,t,n){gf.S(e,t,n);var r=yf;if(r&&e){var i=ht(r).hoistableStyles,a=kf(e);t=t||`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(Af(a)))s.loading=5;else{e=f({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=pf.get(a))&&Lf(e,n);var c=o=r.createElement(`link`);gt(c),Nd(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,If(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function Ef(e,t){gf.X(e,t);var n=yf;if(n&&e){var r=ht(n).hoistableScripts,i=Nf(e),a=r.get(i);a||(a=n.querySelector(Pf(i)),a||(e=f({src:e,async:!0},t),(t=pf.get(i))&&Rf(e,t),a=n.createElement(`script`),gt(a),Nd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Df(e,t){gf.M(e,t);var n=yf;if(n&&e){var r=ht(n).hoistableScripts,i=Nf(e),a=r.get(i);a||(a=n.querySelector(Pf(i)),a||(e=f({src:e,async:!0,type:`module`},t),(t=pf.get(i))&&Rf(e,t),a=n.createElement(`script`),gt(a),Nd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Of(e,t,n,r){var a=(a=se.current)?hf(a):null;if(!a)throw Error(i(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=kf(n.href),n=ht(a).hoistableStyles,r=n.get(t),r||(r={type:`style`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=kf(n.href);var o=ht(a).hoistableStyles,s=o.get(e);if(s||(a=a.ownerDocument||a,s={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},o.set(e,s),(o=a.querySelector(Af(e)))&&!o._p&&(s.instance=o,s.state.loading=5),pf.has(e)||(n={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},pf.set(e,n),o||Mf(a,e,n,s.state))),t&&r===null)throw Error(i(528,``));return s}if(t&&r!==null)throw Error(i(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Nf(n),n=ht(a).hoistableScripts,r=n.get(t),r||(r={type:`script`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(i(444,e))}}function kf(e){return`href="`+Ft(e)+`"`}function Af(e){return`link[rel="stylesheet"][`+e+`]`}function jf(e){return f({},e,{"data-precedence":e.precedence,precedence:null})}function Mf(e,t,n,r){e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)?r.loading=1:(t=e.createElement(`link`),r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2}),Nd(t,`link`,n),gt(t),e.head.appendChild(t))}function Nf(e){return`[src="`+Ft(e)+`"]`}function Pf(e){return`script[async]`+e}function Ff(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+Ft(n.href)+`"]`);if(r)return t.instance=r,gt(r),r;var a=f({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),gt(r),Nd(r,`style`,a),If(r,n.precedence,e),t.instance=r;case`stylesheet`:a=kf(n.href);var o=e.querySelector(Af(a));if(o)return t.state.loading|=4,t.instance=o,gt(o),o;r=jf(n),(a=pf.get(a))&&Lf(r,a),o=(e.ownerDocument||e).createElement(`link`),gt(o);var s=o;return s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),Nd(o,`link`,r),t.state.loading|=4,If(o,n.precedence,e),t.instance=o;case`script`:return o=Nf(n.src),(a=e.querySelector(Pf(o)))?(t.instance=a,gt(a),a):(r=n,(a=pf.get(o))&&(r=f({},n),Rf(r,a)),e=e.ownerDocument||e,a=e.createElement(`script`),gt(a),Nd(a,`link`,r),e.head.appendChild(a),t.instance=a);case`void`:return null;default:throw Error(i(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,If(r,n.precedence,e));return t.instance}function If(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o<r.length;o++){var s=r[o];if(s.dataset.precedence===t)a=s;else if(a!==i)break}a?a.parentNode.insertBefore(e,a.nextSibling):(t=n.nodeType===9?n.head:n,t.insertBefore(e,t.firstChild))}function Lf(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.title==null&&(e.title=t.title)}function Rf(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.integrity==null&&(e.integrity=t.integrity)}var zf=null;function Bf(e,t,n){if(zf===null){var r=new Map,i=zf=new Map;i.set(n,r)}else i=zf,r=i.get(n),r||(r=new Map,i.set(n,r));if(r.has(e))return r;for(r.set(e,null),n=n.getElementsByTagName(e),i=0;i<n.length;i++){var a=n[i];if(!(a[ut]||a[rt]||e===`link`&&a.getAttribute(`rel`)===`stylesheet`)&&a.namespaceURI!==`http://www.w3.org/2000/svg`){var o=a.getAttribute(t)||``;o=e+o;var s=r.get(o);s?s.push(a):r.set(o,[a])}}return r}function Vf(e,t,n){e=e.ownerDocument||e,e.head.insertBefore(n,t===`title`?e.querySelector(`head > title`):null)}function Hf(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case`meta`:case`title`:return!0;case`style`:if(typeof t.precedence!=`string`||typeof t.href!=`string`||t.href===``)break;return!0;case`link`:if(typeof t.rel!=`string`||typeof t.href!=`string`||t.href===``||t.onLoad||t.onError)break;switch(t.rel){case`stylesheet`:return e=t.disabled,typeof t.precedence==`string`&&e==null;default:return!0}case`script`:if(t.async&&typeof t.async!=`function`&&typeof t.async!=`symbol`&&!t.onLoad&&!t.onError&&t.src&&typeof t.src==`string`)return!0}return!1}function Uf(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function Wf(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=kf(r.href),a=t.querySelector(Af(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=qf.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,gt(a);return}a=t.ownerDocument||t,r=jf(r),(i=pf.get(i))&&Lf(r,i),a=a.createElement(`link`),gt(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Nd(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=qf.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var Gf=0;function Kf(e,t){return e.stylesheets&&e.count===0&&Yf(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&Yf(e,e.stylesheets),e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}},6e4+t);0<e.imgBytes&&Gf===0&&(Gf=62500*Id());var i=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&Yf(e,e.stylesheets),e.unsuspend)){var t=e.unsuspend;e.unsuspend=null,t()}},(e.imgBytes>Gf?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function qf(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Yf(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Jf=null;function Yf(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Jf=new Map,t.forEach(Xf,e),Jf=null,qf.call(e))}function Xf(e,t){if(!(t.state.loading&4)){var n=Jf.get(e);if(n)var r=n.get(null);else{n=new Map,Jf.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a<i.length;a++){var o=i[a];(o.nodeName===`LINK`||o.getAttribute(`media`)!==`not all`)&&(n.set(o.dataset.precedence,o),r=o)}r&&n.set(null,r)}i=t.instance,o=i.getAttribute(`data-precedence`),a=n.get(o)||r,a===r&&n.set(null,i),n.set(o,i),this.count++,r=qf.bind(this),i.addEventListener(`load`,r),i.addEventListener(`error`,r),a?a.parentNode.insertBefore(i,a.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(i,e.firstChild)),t.state.loading|=4}}var Zf={$$typeof:x,Provider:null,Consumer:null,_currentValue:F,_currentValue2:F,_threadCount:0};function Qf(e,t,n,r,i,a,o,s,c){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Ke(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ke(0),this.hiddenUpdates=Ke(null),this.identifierPrefix=r,this.onUncaughtError=i,this.onCaughtError=a,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=c,this.incompleteTransitions=new Map}function $f(e,t,n,r,i,a,o,s,c,l,u,d){return e=new Qf(e,t,n,o,c,l,u,d,s),t=1,!0===a&&(t|=24),a=ai(3,null,null,t),e.current=a,a.stateNode=e,t=aa(),t.refCount++,e.pooledCache=t,t.refCount++,a.memoizedState={element:r,isDehydrated:n,cache:t},Ra(a),e}function ep(e){return e?(e=ri,e):ri}function tp(e,t,n,r,i,a){i=ep(i),r.context===null?r.context=i:r.pendingContext=i,r=Ba(t),r.payload={element:n},a=a===void 0?null:a,a!==null&&(r.callback=a),n=Va(e,r,t),n!==null&&(mu(n,e,t),Ha(n,e,t))}function np(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function rp(e,t){np(e,t),(e=e.alternate)&&np(e,t)}function ip(e){if(e.tag===13||e.tag===31){var t=ei(e,67108864);t!==null&&mu(t,e,67108864),rp(e,67108864)}}function ap(e){if(e.tag===13||e.tag===31){var t=fu();t=Qe(t);var n=ei(e,t);n!==null&&mu(n,e,t),rp(e,t)}}var op=!0;function sp(e,t,n,r){var i=N.T;N.T=null;var a=P.p;try{P.p=2,lp(e,t,n,r)}finally{P.p=a,N.T=i}}function cp(e,t,n,r){var i=N.T;N.T=null;var a=P.p;try{P.p=8,lp(e,t,n,r)}finally{P.p=a,N.T=i}}function lp(e,t,n,r){if(op){var i=up(r);if(i===null)Cd(e,t,r,dp,n),Sp(e,r);else if(wp(i,e,t,n,r))r.stopPropagation();else if(Sp(e,r),t&4&&-1<xp.indexOf(e)){for(;i!==null;){var a=pt(i);if(a!==null)switch(a.tag){case 3:if(a=a.stateNode,a.current.memoizedState.isDehydrated){var o=Ve(a.pendingLanes);if(o!==0){var s=a;for(s.pendingLanes|=2,s.entangledLanes|=2;o;){var c=1<<31-Pe(o);s.entanglements[1]|=c,o&=~c}nd(a),!(K&6)&&(eu=we()+500,rd(0,!1))}}break;case 31:case 13:s=ei(a,2),s!==null&&mu(s,a,2),yu(),rp(a,2)}if(a=up(r),a===null&&Cd(e,t,r,dp,n),a===i)break;i=a}i!==null&&r.stopPropagation()}else Cd(e,t,r,null,n)}}function up(e){return e=Qt(e),fp(e)}var dp=null;function fp(e){if(dp=null,e=ft(e),e!==null){var t=o(e);if(t===null)e=null;else{var n=t.tag;if(n===13){if(e=s(t),e!==null)return e;e=null}else if(n===31){if(e=c(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return dp=e,null}function pp(e){switch(e){case`beforetoggle`:case`cancel`:case`click`:case`close`:case`contextmenu`:case`copy`:case`cut`:case`auxclick`:case`dblclick`:case`dragend`:case`dragstart`:case`drop`:case`focusin`:case`focusout`:case`input`:case`invalid`:case`keydown`:case`keypress`:case`keyup`:case`mousedown`:case`mouseup`:case`paste`:case`pause`:case`play`:case`pointercancel`:case`pointerdown`:case`pointerup`:case`ratechange`:case`reset`:case`resize`:case`seeked`:case`submit`:case`toggle`:case`touchcancel`:case`touchend`:case`touchstart`:case`volumechange`:case`change`:case`selectionchange`:case`textInput`:case`compositionstart`:case`compositionend`:case`compositionupdate`:case`beforeblur`:case`afterblur`:case`beforeinput`:case`blur`:case`fullscreenchange`:case`focus`:case`hashchange`:case`popstate`:case`select`:case`selectstart`:return 2;case`drag`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`mousemove`:case`mouseout`:case`mouseover`:case`pointermove`:case`pointerout`:case`pointerover`:case`scroll`:case`touchmove`:case`wheel`:case`mouseenter`:case`mouseleave`:case`pointerenter`:case`pointerleave`:return 8;case`message`:switch(Te()){case Ee:return 2;case De:return 8;case R:case Oe:return 32;case z:return 268435456;default:return 32}default:return 32}}var mp=!1,hp=null,gp=null,_p=null,vp=new Map,yp=new Map,bp=[],xp=`mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset`.split(` `);function Sp(e,t){switch(e){case`focusin`:case`focusout`:hp=null;break;case`dragenter`:case`dragleave`:gp=null;break;case`mouseover`:case`mouseout`:_p=null;break;case`pointerover`:case`pointerout`:vp.delete(t.pointerId);break;case`gotpointercapture`:case`lostpointercapture`:yp.delete(t.pointerId)}}function Cp(e,t,n,r,i,a){return e===null||e.nativeEvent!==a?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:a,targetContainers:[i]},t!==null&&(t=pt(t),t!==null&&ip(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function wp(e,t,n,r,i){switch(t){case`focusin`:return hp=Cp(hp,e,t,n,r,i),!0;case`dragenter`:return gp=Cp(gp,e,t,n,r,i),!0;case`mouseover`:return _p=Cp(_p,e,t,n,r,i),!0;case`pointerover`:var a=i.pointerId;return vp.set(a,Cp(vp.get(a)||null,e,t,n,r,i)),!0;case`gotpointercapture`:return a=i.pointerId,yp.set(a,Cp(yp.get(a)||null,e,t,n,r,i)),!0}return!1}function Tp(e){var t=ft(e.target);if(t!==null){var n=o(t);if(n!==null){if(t=n.tag,t===13){if(t=s(n),t!==null){e.blockedOn=t,tt(e.priority,function(){ap(n)});return}}else if(t===31){if(t=c(n),t!==null){e.blockedOn=t,tt(e.priority,function(){ap(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Ep(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=up(e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);Zt=r,n.target.dispatchEvent(r),Zt=null}else return t=pt(n),t!==null&&ip(t),e.blockedOn=n,!1;t.shift()}return!0}function Dp(e,t,n){Ep(e)&&n.delete(t)}function Op(){mp=!1,hp!==null&&Ep(hp)&&(hp=null),gp!==null&&Ep(gp)&&(gp=null),_p!==null&&Ep(_p)&&(_p=null),vp.forEach(Dp),yp.forEach(Dp)}function kp(e,n){e.blockedOn===n&&(e.blockedOn=null,mp||(mp=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,Op)))}var Ap=null;function jp(e){Ap!==e&&(Ap=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){Ap===e&&(Ap=null);for(var t=0;t<e.length;t+=3){var n=e[t],r=e[t+1],i=e[t+2];if(typeof r!=`function`){if(fp(r||n)===null)continue;break}var a=pt(n);a!==null&&(e.splice(t,3),t-=3,xs(a,{pending:!0,data:i,method:n.method,action:r},r,i))}}))}function Mp(e){function t(t){return kp(t,e)}hp!==null&&kp(hp,e),gp!==null&&kp(gp,e),_p!==null&&kp(_p,e),vp.forEach(t),yp.forEach(t);for(var n=0;n<bp.length;n++){var r=bp[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<bp.length&&(n=bp[0],n.blockedOn===null);)Tp(n),n.blockedOn===null&&bp.shift();if(n=(e.ownerDocument||e).$$reactFormReplay,n!=null)for(r=0;r<n.length;r+=3){var i=n[r],a=n[r+1],o=i[it]||null;if(typeof a==`function`)o||jp(n);else if(o){var s=null;if(a&&a.hasAttribute(`formAction`)){if(i=a,o=a[it]||null)s=o.formAction;else if(fp(i)!==null)continue}else s=o.action;typeof s==`function`?n[r+1]=s:(n.splice(r,3),r-=3),jp(n)}}}function Np(){function e(e){e.canIntercept&&e.info===`react-transition`&&e.intercept({handler:function(){return new Promise(function(e){return i=e})},focusReset:`manual`,scroll:`manual`})}function t(){i!==null&&(i(),i=null),r||setTimeout(n,20)}function n(){if(!r&&!navigation.transition){var e=navigation.currentEntry;e&&e.url!=null&&navigation.navigate(e.url,{state:e.getState(),info:`react-transition`,history:`replace`})}}if(typeof navigation==`object`){var r=!1,i=null;return navigation.addEventListener(`navigate`,e),navigation.addEventListener(`navigatesuccess`,t),navigation.addEventListener(`navigateerror`,t),setTimeout(n,100),function(){r=!0,navigation.removeEventListener(`navigate`,e),navigation.removeEventListener(`navigatesuccess`,t),navigation.removeEventListener(`navigateerror`,t),i!==null&&(i(),i=null)}}}function Pp(e){this._internalRoot=e}Fp.prototype.render=Pp.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(i(409));var n=t.current;tp(n,fu(),e,t,null,null)},Fp.prototype.unmount=Pp.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;tp(e.current,2,null,e,null,null),yu(),t[at]=null}};function Fp(e){this._internalRoot=e}Fp.prototype.unstable_scheduleHydration=function(e){if(e){var t=et();e={blockedOn:null,target:e,priority:t};for(var n=0;n<bp.length&&t!==0&&t<bp[n].priority;n++);bp.splice(n,0,e),n===0&&Tp(e)}};var Ip=n.version;if(Ip!==`19.2.4`)throw Error(i(527,Ip,`19.2.4`));P.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render==`function`?Error(i(188)):(e=Object.keys(e).join(`,`),Error(i(268,e)));return e=u(t),e=e===null?null:d(e),e=e===null?null:e.stateNode,e};var Lp={bundleType:0,version:`19.2.4`,rendererPackageName:`react-dom`,currentDispatcherRef:N,reconcilerVersion:`19.2.4`};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`){var Rp=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Rp.isDisabled&&Rp.supportsFiber)try{je=Rp.inject(Lp),Me=Rp}catch{}}e.createRoot=function(e,t){if(!a(e))throw Error(i(299));var n=!1,r=``,o=Ws,s=Gs,c=Ks;return t!=null&&(!0===t.unstable_strictMode&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onUncaughtError!==void 0&&(o=t.onUncaughtError),t.onCaughtError!==void 0&&(s=t.onCaughtError),t.onRecoverableError!==void 0&&(c=t.onRecoverableError)),t=$f(e,1,!1,null,null,n,r,null,o,s,c,Np),e[at]=t.current,xd(e),new Pp(t)}})),ym=s(((e,t)=>{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=vm()}))();const bm=new WeakMap;function xm(e,t){let n=bm.get(t);n||(n=(0,ym.createRoot)(t),bm.set(t,n)),n.render(e)}function Sm(e){let t=bm.get(e);t&&(t.unmount(),bm.delete(e))}const Cm=new Set;let wm;function Tm(e){return wm||(wm=new ResizeObserver((...e)=>{Cm.forEach(t=>t(...e))})),{observe(t,n){Cm.add(e),wm.observe(t,n)},unobserve(t){Cm.delete(e),wm.unobserve(t)}}}exports.Accordion=ke,exports.Avatar=Pe,exports.Badge=Fe,exports.Button=Ze,exports.ButtonGroup=Qe,exports.Calendar=ht,exports.CascaderList=_t,exports.Checkbox=yt,exports.CheckboxGroup=vt,exports.ColorPicker=ga,exports.ConfigContext=et,exports.ConfigProvider=tt,exports.Confirm=va,exports.DatePicker=Rc,exports.DateRangePicker=zc,exports.Dialog=Yi,exports.DraggableList=Vc,exports.Dropdown=Lc,exports.DropdownMenu=qd,exports.FormDualColumnLayout=Xd,exports.FormLayout=Yd,exports.Gallery=$d,exports.GradientColorPicker=sf,exports.HoverCard=Lf,exports.Input=tf,exports.InputNumber=nf,exports.KBD=Rf,exports.MessageType=lp,exports.Messager=yp,exports.MultipleSelect=qp,exports.Pager=Zd,exports.Popup=Vp,exports.Radio=Up,exports.RadioGroup=Hp,exports.Segmented=rf,exports.Select=Kp,exports.SelectList=Wp,exports.Separator=tm,exports.Switch=nm,exports.Textarea=rm,exports.TimeInput=dt,exports.Toaster=im,exports.Tooltip=af,exports.Tree=hm,exports.TreeSelectionMode=pm,exports.borderBottomClassName=lt,exports.borderClassName=at,exports.borderLeftBottomClassName=ot,exports.borderLeftClassName=st,exports.borderRightClassName=ut,exports.borderTopClassName=ct,exports.clsx=R,exports.divideXClassName=`univer-divide-gray-200 dark:!univer-divide-gray-600 univer-divide-x univer-divide-y-0 univer-divide-solid`,exports.divideYClassName=`univer-divide-gray-200 dark:!univer-divide-gray-600 univer-divide-y univer-divide-x-0 univer-divide-solid`,exports.filterLeafNode=fm,exports.findNodePathFromTree=om,exports.findSubTreeFromPath=cm,exports.isBrowser=$e,exports.mergeTreeSelected=um,exports.message=bp,exports.removeMessage=xp,exports.render=xm,exports.resizeObserverCtor=Tm,exports.scrollbarClassName=rt,exports.toast=ep,exports.unmount=Sm;