ono-react-element 0.1.3 → 0.1.5

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 (250) hide show
  1. package/dist/es/AutoSliderList-CnR9cnHk.js +1 -0
  2. package/dist/es/AvatarCrop-DHnxRLP9.js +1 -0
  3. package/dist/es/Button-CGyWgrQj.js +1 -0
  4. package/dist/es/Card3D-NqDUZB0c.js +1 -0
  5. package/dist/es/Carousel-Bnrz70Tw.js +1 -0
  6. package/dist/es/Checkbox-DI_pnI6U.js +1 -0
  7. package/dist/es/ContextMenu-Boi1cZFI.js +1 -0
  8. package/dist/es/FileDropZone-DCvpaUuw.js +1 -0
  9. package/dist/es/Input-DnB8zvWy.js +1 -0
  10. package/dist/es/List-ClfyFOXz.js +1 -0
  11. package/dist/es/MenuButton-BZMchW23.js +1 -0
  12. package/dist/es/Message-C8cydGYH.js +1 -0
  13. package/dist/es/Modal-BbixgMNW.js +1 -0
  14. package/dist/es/Pagination-D428PpRD.js +1 -0
  15. package/dist/es/Radio-CYirLPd9.js +1 -0
  16. package/dist/es/ScrollableTabs-yCB3QKsp.js +1 -0
  17. package/dist/es/Select-D5REq6YE.js +1 -0
  18. package/dist/es/SvgImg-DWqVwwgv.js +1 -0
  19. package/dist/es/Switch-uZtwu9mV.js +1 -0
  20. package/dist/es/TemplateDialog-xcIPaUIe.js +1 -0
  21. package/dist/es/Toast-nAp61Kbz.js +1 -0
  22. package/dist/es/Tooltip-Dw-vi5zs.js +1 -0
  23. package/dist/es/VirtualList-DKHTLs7s.js +1 -0
  24. package/dist/es/Waterfall-BVjigHTI.js +1 -0
  25. package/dist/es/dependencies-BY0bokKL.js +1 -0
  26. package/dist/es/index.js +1 -1
  27. package/dist/types/components/AutoSliderList/index.d.ts +0 -1
  28. package/dist/types/components/AutoSliderList/types.d.ts +1 -5
  29. package/dist/types/components/Modal/Modal.d.ts +1 -1
  30. package/dist/types/components/VirtualList/EstimatedVirtualList.d.ts +1 -1
  31. package/dist/types/components/index.d.ts +0 -1
  32. package/dist/types/index.d.ts +5 -91
  33. package/dist/umd/index.umd.cjs +1 -1
  34. package/dist/umd/index.umd.cjs.br +0 -0
  35. package/dist/umd/index.umd.cjs.gz +0 -0
  36. package/package.json +71 -53
  37. package/dist/es/AutoSliderList-drdrxgEX.js +0 -1
  38. package/dist/es/AvatarCrop-Cn9RwTGU.js +0 -1
  39. package/dist/es/Button-CWqApx4k.js +0 -1
  40. package/dist/es/Card3D-C1ddJnYV.js +0 -1
  41. package/dist/es/Carousel-D7JsU-he.js +0 -1
  42. package/dist/es/Checkbox-C6L0UHHG.js +0 -1
  43. package/dist/es/ContextMenu-Cg72hSPN.js +0 -1
  44. package/dist/es/FileDropZone-CQy4SsUO.js +0 -1
  45. package/dist/es/InjunctiveBox-DsNUniss.js +0 -1
  46. package/dist/es/Input-CdxX4nzt.js +0 -1
  47. package/dist/es/List-DXRmDwDo.js +0 -1
  48. package/dist/es/MenuButton-CjudK6uV.js +0 -1
  49. package/dist/es/Message-CXBf5Xji.js +0 -1
  50. package/dist/es/Modal-Cq9ZPw9X.js +0 -1
  51. package/dist/es/Pagination-wxdQuNM4.js +0 -1
  52. package/dist/es/PortalRenderer-CUaab_Kw.js +0 -1
  53. package/dist/es/Radio-pth5zZkE.js +0 -1
  54. package/dist/es/ScrollableTabs-CNuEx01I.js +0 -1
  55. package/dist/es/Select-CprTy0VT.js +0 -1
  56. package/dist/es/SvgImg-D2DeoPaA.js +0 -1
  57. package/dist/es/Switch-CQJGc1NQ.js +0 -1
  58. package/dist/es/TemplateDialog-DAzyCsXv.js +0 -1
  59. package/dist/es/Toast-1MB_CUWF.js +0 -1
  60. package/dist/es/Tooltip-7uWxsj7r.js +0 -1
  61. package/dist/es/VirtualList-DThIEdea.js +0 -1
  62. package/dist/es/Waterfall-CDXm71jP.js +0 -1
  63. package/dist/es/addCommasToNumber.ts-Bc5ZX_HW.js +0 -1
  64. package/dist/es/addEventWithOriginHandler.ts-CBP4faL-.js +0 -1
  65. package/dist/es/adjustColor.ts-D1ttRO_o.js +0 -1
  66. package/dist/es/adjustingColors.ts-CQV_S12M.js +0 -1
  67. package/dist/es/base64ToBlob.ts-BpYnI1_k.js +0 -1
  68. package/dist/es/base64ToFile.ts-B526yxVq.js +0 -1
  69. package/dist/es/blobToBase64.ts-CJROQ7nO.js +0 -1
  70. package/dist/es/blobToFile.ts-CjkxPmEw.js +0 -1
  71. package/dist/es/calculateAspectRatio.ts-DLTMZ6rT.js +0 -1
  72. package/dist/es/chainClassNames.ts-B9vmfsc1.js +0 -1
  73. package/dist/es/changeThemeClipPathCircle.ts-CHY9pNkk.js +0 -1
  74. package/dist/es/checkDeviceIsMobile.ts-D_9fa1Z1.js +0 -1
  75. package/dist/es/checkStatusCode.ts-CeS5vbbx.js +0 -1
  76. package/dist/es/clearAsyncContagion.ts-DseR8G-S.js +0 -1
  77. package/dist/es/controlTheScrollbarScrolling.ts-WYW8laxj.js +0 -1
  78. package/dist/es/convertSecondToOtherTime.ts-BlSK8Hsn.js +0 -1
  79. package/dist/es/copy2Clipboard.ts-D-Ux5BRc.js +0 -1
  80. package/dist/es/createIntersectionObserver.ts-CPwdNz7M.js +0 -1
  81. package/dist/es/dayOfYear.ts-FVQlJIhw.js +0 -1
  82. package/dist/es/debounce.ts-DtQl9QX-.js +0 -1
  83. package/dist/es/deepCopy.ts-DZSM2TJ5.js +0 -1
  84. package/dist/es/dependencies-D-GIrksw.js +0 -15480
  85. package/dist/es/distinguishPlatform.ts-BITl3t1o.js +0 -1
  86. package/dist/es/distinguishPlatformDelay.ts-DupUPv6F.js +0 -1
  87. package/dist/es/downloadFile.ts-C5v3gvXJ.js +0 -1
  88. package/dist/es/elementIsInViewport.ts-DnBd8TjE.js +0 -1
  89. package/dist/es/ellipsisString.ts-CEHck07f.js +0 -1
  90. package/dist/es/event-BIaLzjOy.js +0 -1
  91. package/dist/es/fileToBase64.ts-LDhPtYZ8.js +0 -1
  92. package/dist/es/fileToBlob.ts-C4Y1I82u.js +0 -1
  93. package/dist/es/formatColor.ts-D_Sws4M1.js +0 -1
  94. package/dist/es/formatFileSize.ts-CoUwKtCA.js +0 -1
  95. package/dist/es/formatSecond.ts-Dc436DN-.js +0 -1
  96. package/dist/es/formatTime.ts-BY0hrdXI.js +0 -1
  97. package/dist/es/gcd.ts-BCWGat6T.js +0 -1
  98. package/dist/es/getAllTheNumbers.ts-DaNxVd8a.js +0 -1
  99. package/dist/es/getBrowserInfo.ts-CFS4Oz41.js +0 -1
  100. package/dist/es/getColorType.ts-B5Qax_03.js +0 -1
  101. package/dist/es/getContrastColor.ts-vmwZYf4O.js +0 -1
  102. package/dist/es/getElementCenterPosition.ts-CpWYej6j.js +0 -1
  103. package/dist/es/getFileName.ts-CAdDeTqT.js +0 -1
  104. package/dist/es/getFileSuffix.ts-RBCEexOt.js +0 -1
  105. package/dist/es/getImageSIze.ts-BKCUZEmG.js +0 -1
  106. package/dist/es/getPointDistance.ts-oQIzWYT7.js +0 -1
  107. package/dist/es/getURLSearchParams.ts-CdkTE_NB.js +0 -1
  108. package/dist/es/grayColor.ts-BeAK97Od.js +0 -1
  109. package/dist/es/hex2hsl.ts-fQ072W3P.js +0 -1
  110. package/dist/es/hex2hsv.ts-Bewjcepy.js +0 -1
  111. package/dist/es/hex2rgb.ts-tP-M30oZ.js +0 -1
  112. package/dist/es/hex3To6.ts-epLJiP-G.js +0 -1
  113. package/dist/es/hsl2hex.ts-BILOsbJk.js +0 -1
  114. package/dist/es/hsl2rgb.ts-DCdzknv1.js +0 -1
  115. package/dist/es/hsv2hex.ts-U8Md-VPN.js +0 -1
  116. package/dist/es/hsv2rgb.ts-C4AdDfKf.js +0 -1
  117. package/dist/es/isPureNumber.ts-UvzCfFTt.js +0 -1
  118. package/dist/es/isValidColor.ts-oChVkAT9.js +0 -1
  119. package/dist/es/localFormat.ts-B32R_kV4.js +0 -1
  120. package/dist/es/mediaAutoplayPolicies.ts-h8T8o7DV.js +0 -1
  121. package/dist/es/padZero.ts-BTMKlRWN.js +0 -1
  122. package/dist/es/parseQuery.ts-rxlqkZEE.js +0 -1
  123. package/dist/es/passwordStrength.ts-BSVicol-.js +0 -1
  124. package/dist/es/pick.ts-CVf1DuK1.js +0 -1
  125. package/dist/es/printStr.ts-Nd8JNyzN.js +0 -1
  126. package/dist/es/pureNumber.ts-LjeTI9RC.js +0 -1
  127. package/dist/es/quickSort.ts-CTYjJtIg.js +0 -1
  128. package/dist/es/rafTimeout.ts-atBwwlgC.js +0 -1
  129. package/dist/es/randomColor.ts-BiDP87Yi.js +0 -1
  130. package/dist/es/randomString.ts-DpWnx0Kc.js +0 -1
  131. package/dist/es/removeTag.ts-K8ovHu9Z.js +0 -1
  132. package/dist/es/rgb2hex.ts-itJEWSC0.js +0 -1
  133. package/dist/es/rgb2hsl.ts-BmthoL_h.js +0 -1
  134. package/dist/es/rgb2hsv.ts-o8o8uIwc.js +0 -1
  135. package/dist/es/rgb2rgba.ts-ZXQCbTkT.js +0 -1
  136. package/dist/es/safeCapitalizeWord.ts-CBBsQk5s.js +0 -1
  137. package/dist/es/second2Day.ts-XjEpcvCc.js +0 -1
  138. package/dist/es/singleton.ts-BxAjTJl8.js +0 -1
  139. package/dist/es/throttle.ts-D_EqcNzV.js +0 -1
  140. package/dist/es/urlToBase64.ts-DzO1pwIZ.js +0 -1
  141. package/dist/es/urlToBlob.ts-DmOp0wbt.js +0 -1
  142. package/dist/es/urlToFile.ts-KrTFcI-e.js +0 -1
  143. package/dist/es/useClickOutSide.tsx-Drp6uYap.js +0 -1
  144. package/dist/es/useCountdown.tsx-BHrpYPuf.js +0 -1
  145. package/dist/es/useEventListener.tsx-BDtH_FiI.js +0 -1
  146. package/dist/es/useGetElementSize.tsx-CYGNJaFz.js +0 -1
  147. package/dist/es/useKeyPress.tsx-ClBLUMui.js +0 -1
  148. package/dist/es/useMouseClick.tsx-nz5umn7V.js +0 -1
  149. package/dist/es/useQuery.tsx-FzGWYq50.js +0 -1
  150. package/dist/es/useTheme.tsx-C7aAN-Zj.js +0 -1
  151. package/dist/es/useThemePro.tsx-MwfY4tCX.js +0 -1
  152. package/dist/types/components/InjunctiveBox/index.d.ts +0 -1
  153. package/dist/types/components/PortalRenderer/PortalRenderer.d.ts +0 -2
  154. package/dist/types/components/PortalRenderer/index.d.ts +0 -1
  155. package/dist/types/event/createEventEmitter.d.ts +0 -2
  156. package/dist/types/event/eventEmitter.d.ts +0 -9
  157. package/dist/types/event/index.d.ts +0 -1
  158. package/dist/types/hooks/useClickOutSide.d.ts +0 -4
  159. package/dist/types/hooks/useCountdown.d.ts +0 -1
  160. package/dist/types/hooks/useEventListener.d.ts +0 -5
  161. package/dist/types/hooks/useGetElementSize.d.ts +0 -4
  162. package/dist/types/hooks/useKeyPress.d.ts +0 -9
  163. package/dist/types/hooks/useMouseClick.d.ts +0 -8
  164. package/dist/types/hooks/useQuery.d.ts +0 -3
  165. package/dist/types/hooks/useTheme.d.ts +0 -7
  166. package/dist/types/hooks/useThemePro.d.ts +0 -11
  167. package/dist/types/utils/async2sync/clearAsyncContagion.d.ts +0 -1
  168. package/dist/types/utils/browser/getBrowserInfo.d.ts +0 -2
  169. package/dist/types/utils/color/adjustColor.d.ts +0 -1
  170. package/dist/types/utils/color/adjustingColors.d.ts +0 -1
  171. package/dist/types/utils/color/formatColor.d.ts +0 -1
  172. package/dist/types/utils/color/getColorType.d.ts +0 -1
  173. package/dist/types/utils/color/getContrastColor.d.ts +0 -1
  174. package/dist/types/utils/color/grayColor.d.ts +0 -1
  175. package/dist/types/utils/color/hex2hsl.d.ts +0 -1
  176. package/dist/types/utils/color/hex2hsv.d.ts +0 -1
  177. package/dist/types/utils/color/hex2rgb.d.ts +0 -1
  178. package/dist/types/utils/color/hex3To6.d.ts +0 -1
  179. package/dist/types/utils/color/hsl2hex.d.ts +0 -1
  180. package/dist/types/utils/color/hsl2rgb.d.ts +0 -1
  181. package/dist/types/utils/color/hsv2hex.d.ts +0 -1
  182. package/dist/types/utils/color/hsv2rgb.d.ts +0 -1
  183. package/dist/types/utils/color/isValidColor.d.ts +0 -1
  184. package/dist/types/utils/color/randomColor.d.ts +0 -1
  185. package/dist/types/utils/color/rgb2hex.d.ts +0 -1
  186. package/dist/types/utils/color/rgb2hsl.d.ts +0 -1
  187. package/dist/types/utils/color/rgb2hsv.d.ts +0 -1
  188. package/dist/types/utils/color/rgb2rgba.d.ts +0 -1
  189. package/dist/types/utils/color/systemDropper.d.ts +0 -1
  190. package/dist/types/utils/common/addCommasToNumber.d.ts +0 -1
  191. package/dist/types/utils/common/addEventWithOriginHandler.d.ts +0 -1
  192. package/dist/types/utils/common/calculateAspectRatio.d.ts +0 -1
  193. package/dist/types/utils/common/chainClassNames.d.ts +0 -1
  194. package/dist/types/utils/common/checkDeviceIsMobile.d.ts +0 -1
  195. package/dist/types/utils/common/checkStatusCode.d.ts +0 -4
  196. package/dist/types/utils/common/controlTheScrollbarScrolling.d.ts +0 -7
  197. package/dist/types/utils/common/copy2Clipboard.d.ts +0 -1
  198. package/dist/types/utils/common/debounce.d.ts +0 -7
  199. package/dist/types/utils/common/deepCopy.d.ts +0 -1
  200. package/dist/types/utils/common/ellipsisString.d.ts +0 -1
  201. package/dist/types/utils/common/gcd.d.ts +0 -1
  202. package/dist/types/utils/common/getAllTheNumbers.d.ts +0 -1
  203. package/dist/types/utils/common/getElementCenterPosition.d.ts +0 -4
  204. package/dist/types/utils/common/getImageSIze.d.ts +0 -4
  205. package/dist/types/utils/common/getPointDistance.d.ts +0 -1
  206. package/dist/types/utils/common/getURLSearchParams.d.ts +0 -1
  207. package/dist/types/utils/common/isPureNumber.d.ts +0 -1
  208. package/dist/types/utils/common/mediaAutoplayPolicies.d.ts +0 -1
  209. package/dist/types/utils/common/padZero.d.ts +0 -1
  210. package/dist/types/utils/common/parseQuery.d.ts +0 -1
  211. package/dist/types/utils/common/passwordStrength.d.ts +0 -1
  212. package/dist/types/utils/common/pick.d.ts +0 -3
  213. package/dist/types/utils/common/printStr.d.ts +0 -11
  214. package/dist/types/utils/common/pureNumber.d.ts +0 -1
  215. package/dist/types/utils/common/quickSort.d.ts +0 -1
  216. package/dist/types/utils/common/rafTimeout.d.ts +0 -1
  217. package/dist/types/utils/common/randomString.d.ts +0 -1
  218. package/dist/types/utils/common/removeTag.d.ts +0 -1
  219. package/dist/types/utils/common/safeCapitalizeWord.d.ts +0 -1
  220. package/dist/types/utils/common/singleton.d.ts +0 -1
  221. package/dist/types/utils/common/throttle.d.ts +0 -13
  222. package/dist/types/utils/file/base64ToBlob.d.ts +0 -1
  223. package/dist/types/utils/file/base64ToFile.d.ts +0 -1
  224. package/dist/types/utils/file/blobToBase64.d.ts +0 -1
  225. package/dist/types/utils/file/blobToFile.d.ts +0 -1
  226. package/dist/types/utils/file/downloadFile.d.ts +0 -1
  227. package/dist/types/utils/file/fileToBase64.d.ts +0 -1
  228. package/dist/types/utils/file/fileToBlob.d.ts +0 -1
  229. package/dist/types/utils/file/formatFileSize.d.ts +0 -4
  230. package/dist/types/utils/file/getFileName.d.ts +0 -1
  231. package/dist/types/utils/file/getFileSuffix.d.ts +0 -1
  232. package/dist/types/utils/file/urlToBase64.d.ts +0 -1
  233. package/dist/types/utils/file/urlToBlob.d.ts +0 -1
  234. package/dist/types/utils/file/urlToFile.d.ts +0 -1
  235. package/dist/types/utils/intersectionObserver/createIntersectionObserver.d.ts +0 -1
  236. package/dist/types/utils/intersectionObserver/elementIsInViewport.d.ts +0 -5
  237. package/dist/types/utils/platform/distinguishPlatform.d.ts +0 -1
  238. package/dist/types/utils/platform/distinguishPlatformDelay.d.ts +0 -3
  239. package/dist/types/utils/time/convertSecondToOtherTime.d.ts +0 -1
  240. package/dist/types/utils/time/convertTimestamp.d.ts +0 -1
  241. package/dist/types/utils/time/dateFormat.d.ts +0 -1
  242. package/dist/types/utils/time/dayOfYear.d.ts +0 -1
  243. package/dist/types/utils/time/formatSecond.d.ts +0 -1
  244. package/dist/types/utils/time/formatTime.d.ts +0 -1
  245. package/dist/types/utils/time/localFormat.d.ts +0 -3
  246. package/dist/types/utils/time/monthFormat.d.ts +0 -1
  247. package/dist/types/utils/time/second2Day.d.ts +0 -1
  248. package/dist/types/utils/time/yearFormat.d.ts +0 -1
  249. package/dist/types/utils/viewTransition/changeThemeClipPathCircle.d.ts +0 -6
  250. /package/dist/types/components/{InjunctiveBox → Toast}/InjunctiveBox.d.ts +0 -0
@@ -0,0 +1 @@
1
+ import{jsx as re,jsxs as ae}from "react/jsx-runtime";import{c as ce}from "react/compiler-runtime";import{useGetElementSize as de,chainClassNames as X,pureNumber as Y}from "./index.js";import{useState as A,useRef as Z,useEffect as ee,cloneElement as me}from "react";const ye=(te)=>{const e=ce(51),{list:E,style:_,disable:i,children:l,sliderBox:$,className:j,sliderStyle:k,duration:J,sliderClassName:I,currentIndex:K,direction:M,sliderTransitionTimingFunction:O}=te,y=J===void 0 ? 300:J,w=K===void 0 ? 0:K,u=M===void 0 ? "Horizontal":M,ie=O===void 0 ? "ease-in-out":O,[oe,se]=A(!1),[t,P]=A(0);let x;e[0]===Symbol.for("react.memo_cache_sentinel")?(x={t:0,l:0},e[0]=x):x=e[0];const [Q,le]=A(x);let v;e[1]===Symbol.for("react.memo_cache_sentinel")?(v={w:0,h:0},e[1]=v):v=e[1];const [n,ne]=A(v),b=Z(null),U=Z(null),L=oe ? `translate ${y/1e3}s ${ie}`:"initial",B=`${Q.l}px ${Q.t}px`;let g;e[2]!==n.h||e[3]!==n.w||e[4]!==L||e[5]!==B ?(g={width:n.w,height:n.h,transition:L,translate:B},e[2]=n.h,e[3]=n.w,e[4]=L,e[5]=B,e[6]=g):g=e[6];const D=g;let z;e[7]!==u||e[8]!==i||e[9]!==y||e[10]!==t ?(z=()=>{if(typeof t!="number"||!b.current||!U.current)return;const o=Array.from(b.current.children).slice(1);o.forEach((p)=>{p.style.position="relative",p.style.cursor=i ? "not-allowed":"pointer",p.style.zIndex="1";});const h=window.getComputedStyle(b.current),s={t:u==="Horizontal" ? Y(h.paddingTop):o[t].offsetTop,l:u==="Horizontal" ? o[t].offsetLeft:Y(h.paddingLeft)};le(s),ne({w:o[t].offsetWidth,h:o[t].offsetHeight}),setTimeout(()=>se(!0),y);},e[7]=u,e[8]=i,e[9]=y,e[10]=t,e[11]=z):z=e[11];const F=z,{w:G,h:R}=de();let N,S,C,H;e[12]!==w ?(N=()=>{P(w);},S=[w],e[12]=w,e[13]=N,e[14]=S):(N=e[13],S=e[14]),ee(N,S),e[15]!==F ?(C=()=>{F();},e[15]=F,e[16]=C):C=e[16],e[17]!==i||e[18]!==t||e[19]!==R||e[20]!==G ?(H=[t,G,R,i],e[17]=i,e[18]=t,e[19]=R,e[20]=G,e[21]=H):H=e[21],ee(C,H);const W=i ? "ono-auto-slider-list-is-disable":"";let r;e[22]!==j||e[23]!==W ?(r=X("ono-auto-slider-list-container",j,W),e[22]=j,e[23]=W,e[24]=r):r=e[24];const q=u==="Horizontal" ? "row":"column";let a,c,d,m,f,T;if(e[25]!==_||e[26]!==q ?(a={flexDirection:q,..._},e[25]=_,e[26]=q,e[27]=a):a=e[27],e[28]!==I ?(c=X("ono-auto-slider-list-slider",I),e[28]=I,e[29]=c):c=e[29],e[30]!==D||e[31]!==k ?(d={...k,...D},e[30]=D,e[31]=k,e[32]=d):d=e[32],e[33]!==$||e[34]!==c||e[35]!==d ?(m=re("li",{ref:U,className:c,style:d,children:$}),e[33]=$,e[34]=c,e[35]=d,e[36]=m):m=e[36],e[37]!==l||e[38]!==i||e[39]!==t||e[40]!==E){let o;e[42]!==l||e[43]!==i||e[44]!==t ?(o=(h,s)=>me(l({item:h,index:s,isActive:s===t}),{onClick:(p)=>{if(i)return;const V=l({item:h,index:s,isActive:s===t}).props.onClick;V&&V(p),P(s);}}),e[42]=l,e[43]=i,e[44]=t,e[45]=o):o=e[45],f=E.map(o),e[37]=l,e[38]=i,e[39]=t,e[40]=E,e[41]=f;}else f=e[41];return e[46]!==r||e[47]!==a||e[48]!==m||e[49]!==f ?(T=ae("ul",{ref:b,className:r,style:a,children:[m,f]}),e[46]=r,e[47]=a,e[48]=m,e[49]=f,e[50]=T):T=e[50],T;};export{ye as A};
@@ -0,0 +1 @@
1
+ import{jsx as re,jsxs as me,Fragment as ge}from "react/jsx-runtime";import{c as de}from "react/compiler-runtime";import{useState as _,useRef as we,useEffect as he}from "react";const fe=(z)=>{const e=de(70),{imageFile:m,cvsW:H,maskBG:J,border:K,wheelScale:Q,setCtx:D,maskInfo:a,setMaskInfo:b,imageStartState:I,setImageStartState:$,imageState:t,setImageState:o}=z,V=H===void 0 ? 520:H,M=J===void 0 ? "rgba(0,0,0,0.5)":J,w=K===void 0 ? "4px solid #fff":K,L=Q===void 0 ? 0.1:Q,[r,c]=_();let E;e[0]===Symbol.for("react.memo_cache_sentinel")?(E={w:0,h:0},e[0]=E):E=e[0];const [d,ce]=_(E);let v;e[1]===Symbol.for("react.memo_cache_sentinel")?(v={w:0,h:0},e[1]=v):v=e[1];const [i,G]=_(v);let k;e[2]===Symbol.for("react.memo_cache_sentinel")?(k={x:0,y:0},e[2]=k):k=e[2];const [g,S]=_(k),[p,U]=_(!1),N=we(null),x=we(null),s=ue;let f,y,W;if(e[3]!==w||e[4]!==m||e[5]!==D||e[6]!==$||e[7]!==o||e[8]!==b){let l;y=()=>{if(!N.current)return;const{width:n}=N.current.getBoundingClientRect();C(n),ce({w:n,h:n});},e[11]!==w ?(l=()=>{const n=w.split(" ");let h=0;return n.forEach((j)=>{j.includes("px")&&(h=Number(j.split("px")[0]));}),h;},e[11]=w,e[12]=l):l=e[12],f=l;const C=(n)=>{const h=new Image();h.src=typeof m=="string" ? m:URL.createObjectURL(m),h.onload=()=>{let j,R=h.width,B=h.height;R>B ?(j=R/n,R=n,B/=j,s({w:B},b)):(j=B/n,B=n,R/=j,s({w:R},b));const ne=(n-R)/2,se=(n-B)/2;s({w:h.width,h:h.height},G),c(h),s({w:R,h:B,t:se,l:ne},o),$({w:R,h:B,t:se,l:ne}),s(ne>se ?{l:ne}:{l:se},b),D(x.current?.getContext("2d"));};};e[3]=w,e[4]=m,e[5]=D,e[6]=$,e[7]=o,e[8]=b,e[9]=f,e[10]=y;}else f=e[9],y=e[10];e[13]!==t.h||e[14]!==t.l||e[15]!==t.t||e[16]!==t.w||e[17]!==a.l||e[18]!==a.w||e[19]!==o ?(W=()=>{U(!1),t.l>a.l&&s({l:a.l},o),t.t>a.l&&s({t:a.l},o),-t.l>t.w-a.l-a.w&&s({l:-(t.w-a.l-a.w)},o),-t.t>t.h-a.l-a.w&&s({t:-(t.h-a.l-a.w)},o);},e[13]=t.h,e[14]=t.l,e[15]=t.t,e[16]=t.w,e[17]=a.l,e[18]=a.w,e[19]=o,e[20]=W):W=e[20];const u=W;let Y;e[21]!==I.w||e[22]!==i.w||e[23]!==L ?(Y=(l,C)=>{let n=l+(C==="in" ? l*L:-l*L);return n>i.w&&(n=i.w),n<I.w&&(n=I.w),n;},e[21]=I.w,e[22]=i.w,e[23]=L,e[24]=Y):Y=e[24];const X=Y;let F;e[25]!==X||e[26]!==t.w||e[27]!==i.h||e[28]!==i.w||e[29]!==u||e[30]!==o ?(F=(l)=>{l.preventDefault(),l.stopPropagation();const C=l.deltaY<0 ? "in":"out",n=X(t.w,C),h=n/i.w;s({w:n,h:i.h*h},o),u();},e[25]=X,e[26]=t.w,e[27]=i.h,e[28]=i.w,e[29]=u,e[30]=o,e[31]=F):F=e[31];const T=F;let Z,ee,te,oe;e[32]!==y ?(Z=()=>{y();},e[32]=y,e[33]=Z):Z=e[33],e[34]===Symbol.for("react.memo_cache_sentinel")?(ee=[N],e[34]=ee):ee=e[34],he(Z,ee),e[35]!==r||e[36]!==t.h||e[37]!==t.l||e[38]!==t.t||e[39]!==t.w ?(te=()=>{if(!x.current||!r)return;const l=x.current.getContext("2d");l&&(l.clearRect(0,0,x.current.width,x.current.height),l.drawImage(r,t.l,t.t,t.w,t.h));},e[35]=r,e[36]=t.h,e[37]=t.l,e[38]=t.t,e[39]=t.w,e[40]=te):te=e[40],e[41]!==r||e[42]!==t ?(oe=[x,r,t],e[41]=r,e[42]=t,e[43]=oe):oe=e[43],he(te,oe);const ie=p ? "grabbing":"grab";let q,ae,A,O,P,le;return e[44]!==V||e[45]!==ie ?(q={width:V,cursor:ie},e[44]=V,e[45]=ie,e[46]=q):q=e[46],e[47]===Symbol.for("react.memo_cache_sentinel")?(ae=(l)=>{s({x:l.clientX,y:l.clientY},S),U(!0);},e[47]=ae):ae=e[47],e[48]!==t.l||e[49]!==t.t||e[50]!==p||e[51]!==o||e[52]!==g ?(A=(l)=>{if(p){const C=l.clientX-g.x,n=l.clientY-g.y;(Math.abs(C)>10||Math.abs(n)>10)&&(s({t:t.t+n,l:t.l+C},o),s({x:l.clientX,y:l.clientY},S));}},e[48]=t.l,e[49]=t.t,e[50]=p,e[51]=o,e[52]=g,e[53]=A):A=e[53],e[54]!==d.h||e[55]!==d.w||e[56]!==A ?(O=re("canvas",{width:d.w,height:d.h,ref:x,onMouseDown:ae,onMouseMove:A}),e[54]=d.h,e[55]=d.w,e[56]=A,e[57]=O):O=e[57],e[58]!==w||e[59]!==f||e[60]!==r||e[61]!==M||e[62]!==a.w ?(P=r&&re("div",{className:"ono-avatar-mask",children:re("div",{style:{border:w,boxShadow:`${M}0 0 0 10000px`,width:`${a.w+2*f()}px`,height:`${a.w+2*f()}px`}})}),e[58]=w,e[59]=f,e[60]=r,e[61]=M,e[62]=a.w,e[63]=P):P=e[63],e[64]!==T||e[65]!==u||e[66]!==q||e[67]!==O||e[68]!==P ?(le=me("div",{ref:N,className:"ono-avatar-canvas",style:q,onWheel:T,onMouseUp:u,onMouseLeave:u,children:[O,P]}),e[64]=T,e[65]=u,e[66]=q,e[67]=O,e[68]=P,e[69]=le):le=e[69],le;};function ue(z,e){e((m)=>({...m,...z}));}const pe=(z)=>{const e=de(24),{imageFile:m,cvsW:H,maskBG:J,border:K,wheelScale:Q,children:D}=z,a=H===void 0 ? 520:H,b=J===void 0 ? "rgba(0,0,0,0.5)":J,I=K===void 0 ? "4px solid #fff":K,$=Q===void 0 ? 0.1:Q;let t;e[0]===Symbol.for("react.memo_cache_sentinel")?(t={w:0,h:0,t:0,l:0},e[0]=t):t=e[0];const [o,V]=_(t);let M;e[1]===Symbol.for("react.memo_cache_sentinel")?(M={w:0,h:0,t:0,l:0},e[1]=M):M=e[1];const [w,L]=_(M);let r;e[2]===Symbol.for("react.memo_cache_sentinel")?(r={w:0,l:0},e[2]=r):r=e[2];const [c,E]=_(r),[d,ce]=_();let v;e[3]!==o ?(v=(U)=>{L({w:o.w,h:o.h,t:o.t,l:o.l}),U?.();},e[3]=o,e[4]=v):v=e[4];const i=v;let G;e[5]!==d||e[6]!==c ?(G=(U,N)=>{if(!d)return;const x=d.getImageData(c.l,c.l,c.w,c.w),s=document.createElement("canvas"),f=s.getContext("2d");if(s.width=c.w,s.height=c.w,!f)return;const{imageSaveType:y,dataSaveType:W,quality:u}=N||{},Y=y===void 0 ? "png":y,X=W===void 0 ? "base64":W,F=u===void 0 ? 100:u;f.putImageData(x,0,0,0,0,c.w,c.w),X==="base64" ? U(s.toDataURL(`image/${Y}`,F/100)):X==="blob"&&s.toBlob((T)=>{if(T)return U(T);},`image/${Y}`,F/100);},e[5]=d,e[6]=c,e[7]=G):G=e[7];const k=G;let g,S,p;return e[8]!==I||e[9]!==a||e[10]!==m||e[11]!==o||e[12]!==w||e[13]!==b||e[14]!==c||e[15]!==$ ?(g=re(fe,{imageFile:m,cvsW:a,maskBG:b,border:I,wheelScale:$,maskInfo:c,setMaskInfo:E,setCtx:ce,imageStartState:o,setImageStartState:V,imageState:w,setImageState:L}),e[8]=I,e[9]=a,e[10]=m,e[11]=o,e[12]=w,e[13]=b,e[14]=c,e[15]=$,e[16]=g):g=e[16],e[17]!==D||e[18]!==k||e[19]!==i ?(S=D?.({handleConfirm:k,handleReduction:i}),e[17]=D,e[18]=k,e[19]=i,e[20]=S):S=e[20],e[21]!==g||e[22]!==S ?(p=me(ge,{children:[g,S]}),e[21]=g,e[22]=S,e[23]=p):p=e[23],p;};export{pe as A};
@@ -0,0 +1 @@
1
+ import{jsx as c,Fragment as K,jsxs as O}from "react/jsx-runtime";import{c as Q}from "react/compiler-runtime";import{throttle as U,chainClassNames as V}from "./index.js";import{forwardRef as W,useState as X,useRef as G,useEffect as M}from "react";const ot=W((H,r)=>{const t=Q(37),{onClick:u,children:B,disabled:o,loading:e,plain:L,shape:P,htmlType:$,type:q,throttleDuration:l,className:R,style:S,icon:d}=H,m=P===void 0 ? "default":P,k=$===void 0 ? "button":$,T=q===void 0 ? "primary":q,[f,A]=X(!1),n=G(null),h=G(null);let p;t[0]===Symbol.for("react.memo_cache_sentinel")?(p=()=>{if(!n.current)return;const s=n.current,J=s.getBoundingClientRect();s.style.setProperty("--btn-height",J.height+"px");},t[0]=p):p=t[0];const I=p;let b;t[1]!==e ?(b=()=>{if(!h.current)return;const s=h.current;e ?(A(!0),s.classList.add("ono-loading-start")):(setTimeout(()=>{A(!1);},300),s.classList.remove("ono-loading-start"),s.classList.add("ono-loading-end"));},t[1]=e,t[2]=b):b=t[2];const z=b;let y;t[3]!==R||t[4]!==o||t[5]!==d||t[6]!==f||t[7]!==e||t[8]!==L||t[9]!==m||t[10]!==T ?(y=()=>V(`ono-btn-${T}`,e||f ? "ono-is-loading":"",e||d ? "ono-is-icon":"",o ? "ono-btn-is-disabled":"",m==="round" ? "ono-is-round":m==="circle" ? "ono-is-circle":"",L ? "ono-is-plain":"",R ?? ""),t[3]=R,t[4]=o,t[5]=d,t[6]=f,t[7]=e,t[8]=L,t[9]=m,t[10]=T,t[11]=y):y=t[11];const D=y;let g;t[12]!==u||t[13]!==l ?(g=u ? U(u,l ? typeof l=="number" ? l:500:0):void 0,t[12]=u,t[13]=l,t[14]=g):g=t[14];const E=g;let v,C,x,N,_,j,i,a;t[15]!==z ?(v=()=>{z();},t[15]=z,t[16]=v):v=t[16],t[17]!==e ?(C=[e,h],t[17]=e,t[18]=C):C=t[18],M(v,C),t[19]===Symbol.for("react.memo_cache_sentinel")?(x=()=>{I();},N=[n],t[19]=x,t[20]=N):(x=t[19],N=t[20]),M(x,N),t[21]!==r ?(_=()=>{r&&n&&(typeof r=="function" ? r(n.current):r.current=n.current);},j=[r,n],t[21]=r,t[22]=_,t[23]=j):(_=t[22],j=t[23]),M(_,j),t[24]!==D ?(i=D(),t[24]=D,t[25]=i):i=t[25],t[26]!==o||t[27]!==e ?(a=(typeof o=="function" ? o():o)||!!e,t[26]=o,t[27]=e,t[28]=a):a=t[28];const F=(()=>{const s=c("span",{ref:h,className:"ono-btn-icon",children:c("span",{children:typeof e=="object" ? e.icon:c("svg",{viewBox:"0 0 1024 1024",focusable:"false","data-icon":"loading",width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true",children:c("path",{d:"M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z"})})})});return e||f ? s:d ? c("span",{children:d}):c(K,{});})();let w;return t[29]!==B||t[30]!==E||t[31]!==k||t[32]!==S||t[33]!==i||t[34]!==a||t[35]!==F ?(w=O("button",{ref:n,className:i,type:k,disabled:a,style:S,onClick:E,children:[F,B]}),t[29]=B,t[30]=E,t[31]=k,t[32]=S,t[33]=i,t[34]=a,t[35]=F,t[36]=w):w=t[36],w;});export{ot as B};
@@ -0,0 +1 @@
1
+ import{jsx as d}from "react/jsx-runtime";import{useState as R,useRef as E,useEffect as f}from "react";const $=({src:t,children:s,enlarge:l=!1,scale:y=1.1,shadow:a,xRange:i=[-10,10],yRange:g=[-10,10],borderRadius:p=20})=>{const [v,c]=R(!1),e=E(null),u=(r,o,n)=>o/n*(r[1]-r[0])+r[0];return f(()=>{e.current&&a&&e.current.style.setProperty("--sd",a);},[e.current]),f(()=>{if(!s&&!t)throw new Error("请传入children或者src属性");},[s,t]),d("div",{ref:e,className:"ono-card",style:{borderRadius:p,transform:`perspective(500px)scale(${v&&l ? y:1})rotateX(var(--rx,0deg))rotateY(var(--ry,0deg))`},onMouseEnter:()=>c(!0),onMouseMove:(r)=>{const{offsetX:o,offsetY:n}=r.nativeEvent,{offsetWidth:h,offsetHeight:m}=e.current,x=u(i,n,m),P=-u(g,o,h);e.current.style.setProperty("--rx",`${x}deg`),e.current.style.setProperty("--ry",`${P}deg`);},onMouseLeave:()=>{c(!1),e.current.style.setProperty("--rx","0deg"),e.current.style.setProperty("--ry","0deg");},children:s ?? d("img",{src:t,alt:"图片"})});};export{$ as C};
@@ -0,0 +1 @@
1
+ import{jsx as L,jsxs as xe}from "react/jsx-runtime";import{c as ze}from "react/compiler-runtime";import{chainClassNames as Ne}from "./index.js";import{useState as d,useRef as ie,useEffect as O}from "react";const $e=(ve)=>{const e=ze(81),{style:Q,current:i,children:r,className:U,prevButton:f,nextButton:p,dots:ae,speed:ce,afterChange:V,duration:ue,autoPlay:he,isShowArrow:me,waitForAnimate:de,direction:fe}=ve,W=ae===void 0||ae,a=ce===void 0 ? 300:ce,v=ue===void 0 ? 2e3:ue,n=he!==void 0&&he,y=me===void 0||me,Z=de===void 0||de,o=fe===void 0 ? "horizontal":fe,[t,ee]=d(typeof i=="number" ? i+1:1),[g,te]=d(typeof i=="number" ? i:0),[b,ye]=d();let j;e[0]===Symbol.for("react.memo_cache_sentinel")?(j=[],e[0]=j):j=e[0];const [oe,ge]=d(j),[w,re]=d(!1),[x,pe]=d(!1),[z,N]=d(!1),B=ie(null),u=ie(null),ne=ie(null);let C,A;if(e[1]!==n||e[2]!==r||e[3]!==t||e[4]!==o||e[5]!==a){C=()=>{if(!r||!B.current)return;B.current.style.setProperty("--speed",`${a}ms`);const s=B.current.getBoundingClientRect();ye(s);const m=[...r];m.push(r[0]),m.unshift(r[r.length-1]),ge(m.map((le,we)=>L("div",{style:{width:s.width,height:s.height,flexShrink:0},children:le},we))),c(s);};const c=(s)=>{u.current&&(u.current.style.transform=o==="horizontal" ? `translateX(-${s.width*t}px)`:`translateY(-${s.height*t}px)`,u.current.style.flexDirection=o==="horizontal" ? "row":"column",N(n),setTimeout(()=>u.current?.classList.add("ono-carousel-slider"),a));};e[1]=n,e[2]=r,e[3]=t,e[4]=o,e[5]=a,e[6]=C;}else C=e[6];e[7]!==b?.height||e[8]!==b?.width||e[9]!==o ?(A=(c)=>{u.current.style.transform=o==="horizontal" ? `translateX(-${(b?.width||0)*(c+1)}px)`:`translateY(-${(b?.height||0)*(c+1)}px)`;},e[7]=b?.height,e[8]=b?.width,e[9]=o,e[10]=A):A=e[10];const h=A;let E;e[11]!==r||e[12]!==t||e[13]!==w||e[14]!==h||e[15]!==a||e[16]!==Z ?(E=(c)=>{const s=c-t;if(s===0||Z&&w)return;re(!0),N(!1);const m=s<0 ? "prev":"next",le=m==="prev" ? 1:r.length;t===le ?(ee(m==="prev" ? r.length:1),te(m==="prev" ? r.length-1:0),h(c-1),setTimeout(()=>{u.current?.classList.remove("ono-carousel-slider"),h(m==="prev" ? r.length-1:0),setTimeout(()=>{u.current?.classList.add("ono-carousel-slider"),re(!1),N(!0);},20);},a)):(te(c-1),ee(c),h(c-1),setTimeout(()=>{re(!1),N(!0);},a));},e[11]=r,e[12]=t,e[13]=w,e[14]=h,e[15]=a,e[16]=Z,e[17]=E):E=e[17];const l=E;let M;e[18]===Symbol.for("react.memo_cache_sentinel")?(M=()=>{clearTimeout(ne.current),ne.current=null;},e[18]=M):M=e[18];const be=M;let P;e[19]!==n||e[20]!==t||e[21]!==v||e[22]!==x||e[23]!==z||e[24]!==l ?(P=()=>{if(x||!n||!z)return be();ne.current=setTimeout(()=>l(t+1),v);},e[19]=n,e[20]=t,e[21]=v,e[22]=x,e[23]=z,e[24]=l,e[25]=P):P=e[25];const se=P;let R,X,Y,D,F,q,G,H,T,I,J,S,_,$,k,K;return e[26]!==C ?(R=()=>{C();},e[26]=C,e[27]=R):R=e[27],e[28]!==n||e[29]!==o ?(X=[B,u,o,n],e[28]=n,e[29]=o,e[30]=X):X=e[30],O(R,X),e[31]!==V||e[32]!==g ?(Y=()=>{V?.(g);},e[31]=V,e[32]=g,e[33]=Y):Y=e[33],e[34]!==g ?(D=[g],e[34]=g,e[35]=D):D=e[35],O(Y,D),e[36]!==se ?(F=()=>{se();},e[36]=se,e[37]=F):F=e[37],e[38]!==n||e[39]!==t||e[40]!==x||e[41]!==w||e[42]!==z ?(q=[n,z,w,t,x],e[38]=n,e[39]=t,e[40]=x,e[41]=w,e[42]=z,e[43]=q):q=e[43],O(F,q),e[44]!==n||e[45]!==i||e[46]!==v||e[47]!==a||e[48]!==l ?(G=()=>{typeof i=="number"&&(N(!1),l(i+1),setTimeout(()=>N(n),v-a));},e[44]=n,e[45]=i,e[46]=v,e[47]=a,e[48]=l,e[49]=G):G=e[49],e[50]!==i ?(H=[u,i],e[50]=i,e[51]=H):H=e[51],O(G,H),e[52]!==U ?(T=Ne("ono-carousel-container",U),e[52]=U,e[53]=T):T=e[53],e[54]===Symbol.for("react.memo_cache_sentinel")?(I=()=>pe(!0),J=()=>pe(!1),e[54]=I,e[55]=J):(I=e[54],J=e[55]),e[56]!==oe ?(S=L("div",{ref:u,className:"ono-carousel-wrapper",children:oe}),e[56]=oe,e[57]=S):S=e[57],e[58]!==t||e[59]!==o||e[60]!==y||e[61]!==f||e[62]!==l ?(_=y&&L("button",{className:o==="horizontal" ? "ono-carousel-left":"ono-carousel-top",onClick:()=>l(t-1),children:f ? typeof f=="function" ? f():f:o==="horizontal" ? "left":"top"}),e[58]=t,e[59]=o,e[60]=y,e[61]=f,e[62]=l,e[63]=_):_=e[63],e[64]!==t||e[65]!==o||e[66]!==y||e[67]!==p||e[68]!==l ?($=y&&L("button",{className:o==="horizontal" ? "ono-carousel-right":"ono-carousel-bottom",onClick:()=>l(t+1),children:p ? typeof p=="function" ? p():p:o==="horizontal" ? "right":"bottom"}),e[64]=t,e[65]=o,e[66]=y,e[67]=p,e[68]=l,e[69]=$):$=e[69],e[70]!==r||e[71]!==W||e[72]!==h ?(k=W&&L("div",{className:"ono-carousel-indicators",children:r.map((c,s)=>L("button",{className:"ono-carousel-indicator",onClick:()=>{h(s),te(s),ee(s+1);}},s))}),e[70]=r,e[71]=W,e[72]=h,e[73]=k):k=e[73],e[74]!==Q||e[75]!==T||e[76]!==S||e[77]!==_||e[78]!==$||e[79]!==k ?(K=xe("div",{ref:B,className:T,style:Q,onMouseEnter:I,onMouseLeave:J,children:[S,_,$,k]}),e[74]=Q,e[75]=T,e[76]=S,e[77]=_,e[78]=$,e[79]=k,e[80]=K):K=e[80],K;};export{$e as C};
@@ -0,0 +1 @@
1
+ import{jsx as D}from "react/jsx-runtime";import{c as F}from "react/compiler-runtime";import{chainClassNames as G}from "./index.js";import{useState as R,useRef as H,useEffect as I}from "react";const Q=(d)=>{const e=F(29),{id:r,style:n,checked:c,onChange:v,className:a,indeterminate:N,checkedColor:S,indeterminateStyle:$,indeterminateColor:E}=d,t=N!==void 0&&N,s=S===void 0 ? "#0077cc":S,j=$===void 0 ? "line":$,k=E===void 0 ? "#0077cc":E,[u,q]=R(""),o=H(null);let i,l,h;e[0]!==s ?(i={value:s,name:"checkedColor"},e[0]=s,e[1]=i):i=e[1],e[2]!==k ?(l={value:k,name:"indeterminateColor"},e[2]=k,e[3]=l):l=e[3],e[4]!==i||e[5]!==l ?(h=[i,l],e[4]=i,e[5]=l,e[6]=h):h=e[6];const b=h,z=J;let f;e[7]!==u||e[8]!==c||e[9]!==s||e[10]!==t||e[11]!==b ?(f=()=>{if(!o.current)return;const w=getComputedStyle(o.current);u||q(w.borderColor),o.current.style.height=w.width,[{value:w.width,name:"w"},{value:c||t ? s:u,name:"border-color"},...b].forEach((A)=>{const{value:P,name:B}=A;P&&z(P,B,o.current);});},e[7]=u,e[8]=c,e[9]=s,e[10]=t,e[11]=b,e[12]=f):f=e[12];const x=f;let p,y;e[13]!==t||e[14]!==x ?(p=()=>{x(),o.current&&(o.current.indeterminate=t);},e[13]=t,e[14]=x,e[15]=p):p=e[15],e[16]!==a||e[17]!==t||e[18]!==n ?(y=[o,a,n,t],e[16]=a,e[17]=t,e[18]=n,e[19]=y):y=e[19],I(p,y);const g=j==="line" ? "ono-checkbox-line":"ono-checkbox-border";let m,C;return e[20]!==a||e[21]!==g ?(m=G(a,g),e[20]=a,e[21]=g,e[22]=m):m=e[22],e[23]!==c||e[24]!==r||e[25]!==v||e[26]!==n||e[27]!==m ?(C=D("input",{id:r,type:"checkbox",ref:o,checked:c,onChange:v,className:m,style:n}),e[23]=c,e[24]=r,e[25]=v,e[26]=n,e[27]=m,e[28]=C):C=e[28],C;};function J(d,e,r){typeof d=="string" ? r.style.setProperty(`--${e}`,d):r.style.setProperty(`--${e}`,`${d}px`);}export{Q as C};
@@ -0,0 +1 @@
1
+ import{jsx as L}from "react/jsx-runtime";import{c as R}from "react/compiler-runtime";import{portalRenderer as b,useEventListener as U}from "./index.js";import{useRef as $,useLayoutEffect as j}from "react";const z=(i)=>{const e=R(24),{className:r,content:t,style:y,onClick:M,onDoubleClick:f,onContextMenu:m,onMouseDown:d,onMouseUp:h,onMouseEnter:v,onMouseLeave:C,onMouseMove:k,destroy:u,position:o}=i,c=$(null);let a,p,n,s,x;return U("click",u),e[0]!==o.x||e[1]!==o.y ?(a=()=>{if(c.current){const{width:l,height:g}=c.current.getBoundingClientRect(),{innerWidth:N,innerHeight:E}=window;let w=o.x,D=o.y;w+l>N&&(w=Math.max(0,N-l)),D+g>E&&(D=Math.max(0,E-g)),c.current.style.left=`${w}px`,c.current.style.top=`${D}px`;}},e[0]=o.x,e[1]=o.y,e[2]=a):a=e[2],e[3]!==o ?(p=[o],e[3]=o,e[4]=p):p=e[4],j(a,p),e[5]!==o.x||e[6]!==o.y||e[7]!==y ?(n={...y,position:"fixed",left:o.x,top:o.y},e[5]=o.x,e[6]=o.y,e[7]=y,e[8]=n):n=e[8],e[9]!==t||e[10]!==u ?(s=typeof t=="function" ? t((l)=>{u(),l&&l();}):t,e[9]=t,e[10]=u,e[11]=s):s=e[11],e[12]!==r||e[13]!==M||e[14]!==m||e[15]!==f||e[16]!==d||e[17]!==v||e[18]!==C||e[19]!==k||e[20]!==h||e[21]!==n||e[22]!==s ?(x=L("div",{ref:c,className:r,style:n,onClick:M,onDoubleClick:f,onContextMenu:m,onMouseDown:d,onMouseUp:h,onMouseEnter:v,onMouseLeave:C,onMouseMove:k,children:s}),e[12]=r,e[13]=M,e[14]=m,e[15]=f,e[16]=d,e[17]=v,e[18]=C,e[19]=k,e[20]=h,e[21]=n,e[22]=s,e[23]=x):x=e[23],x;},X=({e:i,style:e,content:r,className:t})=>{i.preventDefault(),b(z,{className:t,content:r,position:{x:i.clientX,y:i.clientY},style:{zIndex:9999,...e}},"content-menu-root");};export{X as c};
@@ -0,0 +1 @@
1
+ import{jsxs as b,Fragment as j,jsx as z}from "react/jsx-runtime";import{chainClassNames as A}from "./index.js";import{useState as N,useRef as G}from "react";const L=({isBox:s=!1,multiple:h=!1,children:o,allowFileType:E="image",style:g={},className:y="",isCanClick:F=!0,getFileListData:w,onFileTypeError:c,readingAnimationOptions:a})=>{const [r,D]=N(!1),S=G(null);let f=0,p=[],m=[],l=[],C=[];const T=E==="all" ? ["image","video","audio","document","directory"]:E,v=(e)=>{const i=[];l.forEach((n)=>i.push({name:n.name,fileType:"directory",file:"",isFile:!1,fileSize:0,children:[],parent:""}));for(let n=0;n<i.length;n++)for(let t=0;t<e.length;t++)e[t].parent===i[n].name&&e[t].name!==".DS_Store"&&i[n].children.push(e[t]);i.length===0&&i.push(...e),w(i),p=[],f=0,m=[],l=[],C=[],D(!1);},d=(e,i="")=>{if(e.isDirectory){if(!T.includes("directory"))return c&&c();const n=e.createReader(),t=(O)=>O.readEntries((k)=>{let x=0;k.forEach((u)=>{x++,u.isDirectory&&d(u);}),m.push(...k),C.includes(e.name)||(l.push(e),C.push(e.name)),x>=100 ? t(O):m.forEach((u)=>d(u,e.name));});t(n);}else e.file((n)=>{if(!T.includes(n.type.split("/")[0])&&n.name!==".DS_Store")return c&&c();p.push({name:n.name,fileType:n.type,file:n,isFile:!0,fileSize:n.size,children:[],parent:i});const t=f>=l.length&&l.length===0 ? f:m.length;p.length===t&&v(p);});};return b(j,{children:[z("input",{ref:S,type:"file",style:{display:"none"},multiple:h,value:"",onChange:(e)=>{const i=[...e.target.files],n=[];D(!0),i.forEach((t)=>n.push({name:t.name,fileType:t.type,file:t,isFile:!0,fileSize:t.size,children:[],parent:""})),v(n);}}),z("div",{className:A("ono-file-process-container",s ? "ono-file-process-container-box":"",typeof y=="string" ? y:y(r)),style:{justifyContent:s&&!o ? "center":"initial",cursor:s&&F ? r ? "not-allowed":"pointer":"",...g instanceof Function ? g(r):g},onClick:()=>{if(s&&F){if(r&&a?.readingCannotOperattion)return;S.current.click();}},onDragEnter:(e)=>e.preventDefault(),onDragOver:(e)=>e.preventDefault(),onDrop:(e)=>{if(e.preventDefault(),!r||!a?.readingCannotOperattion)if(f=h ? e.dataTransfer.items.length:1,D(!0),h)for(const i of e.dataTransfer.items)d(i.webkitGetAsEntry());else d(e.dataTransfer.items[0].webkitGetAsEntry());},children:s ? o ? r&&a?.readingCannotOperattion ? a?.animations||"正在读取文件...":o:r&&a?.readingCannotOperattion ? a?.animations||"正在读取文件...":"请将要上传的文件拖拽到此处":o})]});};export{L as F};
@@ -0,0 +1 @@
1
+ import{jsxs as A,jsx as c,Fragment as Le}from "react/jsx-runtime";import{c as ge}from "react/compiler-runtime";import{chainClassNames as he,useKeyPress as Se}from "./index.js";import{forwardRef as Ce,useState as z,useRef as we,useEffect as oe}from "react";const ze=()=>{const d=ge(1);let a;return d[0]===Symbol.for("react.memo_cache_sentinel")?(a=c("svg",{className:"ono-input-icon",viewBox:"64 64 896 896",focusable:"false","data-icon":"close-circle",fill:"currentColor","aria-hidden":"true",children:c("path",{d:"M512 64c247.4 0 448 200.6 448 448S759.4 960 512 960 64 759.4 64 512 264.6 64 512 64zm127.98 274.82h-.04l-.08.06L512 466.75 384.14 338.88c-.04-.05-.06-.06-.08-.06a.12.12 0 00-.07 0c-.03 0-.05.01-.09.05l-45.02 45.02a.2.2 0 00-.05.09.12.12 0 000 .07v.02a.27.27 0 00.06.06L466.75 512 338.88 639.86c-.05.04-.06.06-.06.08a.12.12 0 000 .07c0 .03.01.05.05.09l45.02 45.02a.2.2 0 00.09.05.12.12 0 00.07 0c.02 0 .04-.01.08-.05L512 557.25l127.86 127.87c.04.04.06.05.08.05a.12.12 0 00.07 0c.03 0 .05-.01.09-.05l45.02-45.02a.2.2 0 00.05-.09.12.12 0 000-.07v-.02a.27.27 0 00-.05-.06L557.25 512l127.87-127.86c.04-.04.05-.06.05-.08a.12.12 0 000-.07c0-.03-.01-.05-.05-.09l-45.02-45.02a.2.2 0 00-.09-.05.12.12 0 00-.07 0z"})}),d[0]=a):a=d[0],a;},De=(d)=>{const a=ge(5),{open:e}=d,p=e ? "eye":"eye-invisible";let u,f;return a[0]!==e ?(u=e ? c("path",{d:"M942.2 486.2C847.4 286.5 704.1 186 512 186c-192.2 0-335.4 100.5-430.2 300.3a60.3 60.3 0 000 51.5C176.6 737.5 319.9 838 512 838c192.2 0 335.4-100.5 430.2-300.3 7.7-16.2 7.7-35 0-51.5zM512 766c-161.3 0-279.4-81.8-362.7-254C232.6 339.8 350.7 258 512 258c161.3 0 279.4 81.8 362.7 254C791.5 684.2 673.4 766 512 766zm-4-430c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm0 288c-61.9 0-112-50.1-112-112s50.1-112 112-112 112 50.1 112 112-50.1 112-112 112z"}):A(Le,{children:[c("path",{d:"M942.2 486.2Q889.47 375.11 816.7 305l-50.88 50.88C807.31 395.53 843.45 447.4 874.7 512 791.5 684.2 673.4 766 512 766q-72.67 0-133.87-22.38L323 798.75Q408 838 512 838q288.3 0 430.2-300.3a60.29 60.29 0 000-51.5zm-63.57-320.64L836 122.88a8 8 0 00-11.32 0L715.31 232.2Q624.86 186 512 186q-288.3 0-430.2 300.3a60.3 60.3 0 000 51.5q56.69 119.4 136.5 191.41L112.48 835a8 8 0 000 11.31L155.17 889a8 8 0 0011.31 0l712.15-712.12a8 8 0 000-11.32zM149.3 512C232.6 339.8 350.7 258 512 258c54.54 0 104.13 9.36 149.12 28.39l-70.3 70.3a176 176 0 00-238.13 238.13l-83.42 83.42C223.1 637.49 183.3 582.28 149.3 512zm246.7 0a112.11 112.11 0 01146.2-106.69L401.31 546.2A112 112 0 01396 512z"}),c("path",{d:"M508 624c-3.46 0-6.87-.16-10.25-.47l-52.82 52.82a176.09 176.09 0 00227.42-227.42l-52.82 52.82c.31 3.38.47 6.79.47 10.25a111.94 111.94 0 01-112 112z"})]}),a[0]=e,a[1]=u):u=a[1],a[2]!==p||a[3]!==u ?(f=c("svg",{viewBox:"64 64 896 896",focusable:"false","data-icon":p,fill:"currentColor","aria-hidden":"true",className:"ono-input-icon",children:u}),a[2]=p,a[3]=u,a[4]=f):f=a[4],f;},Ee=Ce((d,a)=>{const e=ge(67),{id:p,name:u,max:f,min:H,maxLength:v,minLength:I,type:ne,className:T,defaultValue:G,placeholder:D,readonly:b,autocomplete:te,autofocus:F,form:J,disabled:m,clearable:w,showPassword:ae,prepend:K,append:M,prefix:P,suffix:y,showCount:g,border:N,boxShadow:re,value:X,onChange:x,onFocus:Z,onBlur:L,onClear:B,onKeyUp:t,onKeyDown:E}=d,xe=ne===void 0 ? "text":ne,n=te===void 0 ? "off":te,o=N===void 0 ? "1px solid #5644b8":N,l=re===void 0 ? "0 0 0 2px #7969d11a":re,i=X===void 0 ? "":X,[s,r]=z(i),[h,C]=z(!1),[S,Ne]=z(!1),ee=we(null),le=w&&!m&&s,se=ae&&!m;let ce;e[0]!==o||e[1]!==l ?(ce=()=>{ee.current&&(ee.current.style.setProperty("--ono-input-border",o),ee.current.style.setProperty("--ono-input-box-shadow",l));},e[0]=o,e[1]=l,e[2]=ce):ce=e[2];const fe=ce;let ie,de,ue,pe;e[3]!==fe ?(ie=()=>{fe();},e[3]=fe,e[4]=ie):ie=e[4],e[5]===Symbol.for("react.memo_cache_sentinel")?(de=[ee],e[5]=de):de=e[5],oe(ie,de),e[6]!==i ?(pe=()=>{r(i);},ue=[i],e[6]=i,e[7]=ue,e[8]=pe):(ue=e[7],pe=e[8]),oe(pe,ue);const ye=m ? "ono-input-is-disabled":"";let R,O;e[9]!==ye ?(R=he("ono-input","ono-input-border",ye),e[9]=ye,e[10]=R):R=e[10],e[11]!==K ?(O=K&&c("div",{className:"ono-prepend",children:K}),e[11]=K,e[12]=O):O=e[12];const ve=h ? "ono-input-is-focus":"";let U,q;e[13]!==T||e[14]!==ve ?(U=he("ono-input-wrapper",ve,T),e[13]=T,e[14]=ve,e[15]=U):U=e[15],e[16]!==P ?(q=P&&c("span",{className:"ono-prefix",children:P}),e[16]=P,e[17]=q):q=e[17];const be=ae ? S ? "text":"password":xe;let _,j,k,Q,Y,V,W,me;return e[18]!==Z ?(_=($)=>{Z?.($),C(!0);},e[18]=Z,e[19]=_):_=e[19],e[20]!==L ?(j=($)=>{L?.($),C(!1);},e[20]=L,e[21]=j):j=e[21],e[22]!==x ?(k=($)=>{x?.($),r($.target.value);},e[22]=x,e[23]=k):k=e[23],e[24]!==n||e[25]!==F||e[26]!==G||e[27]!==m||e[28]!==J||e[29]!==p||e[30]!==s||e[31]!==f||e[32]!==v||e[33]!==H||e[34]!==I||e[35]!==u||e[36]!==E||e[37]!==t||e[38]!==D||e[39]!==b||e[40]!==a||e[41]!==be||e[42]!==_||e[43]!==j||e[44]!==k ?(Q=c("input",{id:p,ref:a,max:f,min:H,name:u,maxLength:v,minLength:I,defaultValue:G,className:"ono-input-inner",type:be,placeholder:D,readOnly:b,autoComplete:n,autoFocus:F,form:J,disabled:m,onFocus:_,onBlur:j,value:s,onChange:k,onKeyUp:t,onKeyDown:E}),e[24]=n,e[25]=F,e[26]=G,e[27]=m,e[28]=J,e[29]=p,e[30]=s,e[31]=f,e[32]=v,e[33]=H,e[34]=I,e[35]=u,e[36]=E,e[37]=t,e[38]=D,e[39]=b,e[40]=a,e[41]=be,e[42]=_,e[43]=j,e[44]=k,e[45]=Q):Q=e[45],e[46]!==S||e[47]!==s||e[48]!==v||e[49]!==B||e[50]!==le||e[51]!==g||e[52]!==se||e[53]!==y ?(Y=(y||le||se||g)&&A("span",{className:"ono-suffix",children:[y,le&&c("button",{className:"ono-clear-icon",onClick:()=>{B?.(),r("");},children:c(ze,{})}),se&&c("button",{className:"ono-eye-icon",onClick:()=>Ne(!S),children:c(De,{open:S})}),g&&v&&A("p",{className:"ono-count",children:[s.length,"/",v]})]}),e[46]=S,e[47]=s,e[48]=v,e[49]=B,e[50]=le,e[51]=g,e[52]=se,e[53]=y,e[54]=Y):Y=e[54],e[55]!==U||e[56]!==q||e[57]!==Q||e[58]!==Y ?(V=A("div",{ref:ee,className:U,onMouseDown:Fe,children:[q,Q,Y]}),e[55]=U,e[56]=q,e[57]=Q,e[58]=Y,e[59]=V):V=e[59],e[60]!==M ?(W=M&&c("div",{className:"ono-append",children:M}),e[60]=M,e[61]=W):W=e[61],e[62]!==R||e[63]!==O||e[64]!==V||e[65]!==W ?(me=A("div",{className:R,children:[O,V,W]}),e[62]=R,e[63]=O,e[64]=V,e[65]=W,e[66]=me):me=e[66],me;});function Fe(d){d.target.tagName!=="INPUT"&&d.preventDefault();}const Re=Ce(({id:d,name:a,rows:e,maxLength:p,minLength:u,className:f,placeholder:H,readonly:v,resize:I=!0,autocomplete:ne="off",autofocus:T,form:G,disabled:D,autoSize:b,showCount:te,border:F="1px solid #5644b8",boxShadow:J="0 0 0 2px #7969d11a",value:m="",onChange:w,onFocus:ae,onBlur:K,onKeyUp:M,onKeyDown:P},y)=>{const [g,N]=z(m),[re,X]=z(!1),[x,Z]=z([m]),[L,B]=z(0),t=we(null),E=(n)=>{const o=x.slice(0,L+1);o.push(n),Z(o),B(o.length-1);};return [{key:"CommandOrControl+z",handler:(n)=>{document.activeElement===t.current&&(n.preventDefault(),(()=>{if(L>0&&t.current){const o=L-1,l=x[o];if(t.current.value=l,N(l),B(o),w){const i={target:t.current};w(i);}}})());},deps:[x]},{key:"CommandOrControl+d",handler:(n)=>{if(t.current&&document.activeElement===t.current){n.preventDefault();const o=((l)=>{const{value:i,selectionStart:s,selectionEnd:r}=l,h=i.substring(0,s)+i.substring(r);return l.value=h,l.setSelectionRange(s,s),h;})(t.current);if(N(o),E(o),w){const l={target:t.current};w(l);}}},deps:[x]}].forEach(({key:n,handler:o,deps:l})=>Se(n,o,{target:t.current,deps:l})),oe(()=>{N(m);},[m]),oe(()=>{(()=>{if(!t.current)return;const n=t.current;((o,l,i,s,r)=>{const h=o.parentNode;o.style.resize=l ? "none":i ? "vertical":"none",h.style.setProperty("--ono-input-border",s),h.style.setProperty("--ono-input-box-shadow",r),h.style.setProperty("--ono-input-height","auto");})(n,b||!1,I,F,J),b&&((o,l)=>{const{minRows:i=2,maxRows:s}=typeof l=="object" ? l:{},r=document.createElement("div");r.style.position="absolute",r.style.visibility="hidden",r.style.whiteSpace="pre-wrap",r.style.wordWrap="break-word",r.style.width=`${o.clientWidth}px`,r.style.font=getComputedStyle(o).font,r.style.padding=getComputedStyle(o).padding,r.style.border=getComputedStyle(o).border,r.style.boxSizing="border-box",document.body.appendChild(r);const h=34*i;let C=h;if(o.value){r.textContent=o.value;const S=r.offsetHeight;C=Math.max(h,S),s&&C>34*s ?(C=34*s,o.style.overflowY="auto"):o.style.overflowY="hidden";}else o.style.overflowY="hidden";o.style.height=`${C}px`,o.style.resize=l ? "none":"vertical",document.body.removeChild(r),Math.floor(C/34);})(n,b);})();},[t,b,g]),oe(()=>{y&&t.current&&(y instanceof Function ? y(t.current):y.current=t.current);},[y,t]),A("div",{className:he("ono-textarea",D ? "ono-input-is-disabled":""),children:[c("div",{className:he("ono-textarea-wrapper",re ? F==="none" ? "":"ono-input-is-focus":"",f),onClick:()=>t.current?.focus(),children:c("textarea",{ref:t,className:"ono-textarea-inner",id:d,rows:e,name:a,maxLength:p,minLength:u,placeholder:H,readOnly:v,autoComplete:ne,autoFocus:T,form:G,disabled:D,onFocus:(n)=>{ae?.(n),X(!0);},onBlur:(n)=>{K?.(n),X(!1);},value:g,onChange:(n)=>{N(n.target.value),E(n.target.value),w?.(n);},onKeyUp:M,onKeyDown:P})}),te&&p&&c("p",{className:"ono-count-bar",onClick:(n)=>n.stopPropagation(),children:g.length+"/"+p})]});});export{Ee as O,Re as a};
@@ -0,0 +1 @@
1
+ import{c as B}from "react/compiler-runtime";import{useState as k,useEffect as D}from "react";const A=(n)=>{const e=B(14),{list:t,children:r,fallback:o,deps:s,insertBetweenDom:a}=n;let c;e[0]!==s ?(c=s===void 0 ? []:s,e[0]=s,e[1]=c):c=e[1];const i=c;let l;e[2]===Symbol.for("react.memo_cache_sentinel")?(l=[],e[2]=l):l=e[2];const [b,y]=k(l);let u;e[3]!==r ?(u=(m)=>m.map(r).filter(_),e[3]=r,e[4]=u):u=e[4];const d=u,w=S;let f;e[5]!==o||e[6]!==d||e[7]!==a||e[8]!==t ?(f=async()=>{if(!t)return;y(o);const m=typeof t=="function" ? await t():t;y(m.length>0 ? w(d(m),a):o);},e[5]=o,e[6]=d,e[7]=a,e[8]=t,e[9]=f):f=e[9];const g=f;let p,h;return e[10]!==g ?(p=()=>{g();},e[10]=g,e[11]=p):p=e[11],e[12]!==i ?(h=[...i],e[12]=i,e[13]=h):h=e[13],D(p,h),b;};function _(n){return n;}function S(n,e){return e ? n.reduce((t,r,o)=>(t.push(r),o<n.length-1&&t.push(e(o)),t),[]):n;}const E=({list:n,children:e,fallback:t,insertBetweenDom:r})=>(()=>{const o=typeof n=="function" ? n():n;return o.length>0 ?((s,a)=>a ? s.reduce((c,i,l)=>(c.push(i),l<s.length-1&&c.push(a(l)),c),[]):s)(((s)=>s.map(e).filter(Boolean))(o),r):t;})();export{A,E as L};
@@ -0,0 +1 @@
1
+ import{jsx as I}from "react/jsx-runtime";import{c as K}from "react/compiler-runtime";import{useState as L,useEffect as O}from "react";const W=(y)=>{const t=K(72),{active:a,onchange:s,width:z,duration:B,lineColor:D,backgroundColor:G}=y,q=z===void 0 ? 40:z,J=B===void 0 ? 400:B,E=D===void 0 ? "#f5f5f5":D,F=G===void 0 ? "#342A7C":G,[o,H]=L(!1),e=typeof q=="string" ? q:`${q}px`,r=P;let i,l,d,c;t[0]!==e ?(i=r(e,0.6),t[0]=e,t[1]=i):i=t[1],t[2]!==e ?(l=r(e,0.06),t[2]=e,t[3]=l):l=t[3],t[4]!==o||t[5]!==e ?(d=r(e,o ? 0.11:0.2),t[4]=o,t[5]=e,t[6]=d):d=t[6],t[7]!==e ?(c=r(e,1),t[7]=e,t[8]=c):c=t[8];const M=`all ${J/1e3}s`;let j;t[9]!==E||t[10]!==i||t[11]!==l||t[12]!==d||t[13]!==c||t[14]!==M ?(j={width:i,height:l,left:d,borderRadius:c,background:E,transition:M},t[9]=E,t[10]=i,t[11]=l,t[12]=d,t[13]=c,t[14]=M,t[15]=j):j=t[15];const n=j;let u,f,h,m,g,p,b,v,w,x,A;t[16]!==o||t[17]!==e ?(u=r(e,o ? 0.8:0.5),t[16]=o,t[17]=e,t[18]=u):u=t[18],t[19]!==o||t[20]!==e ?(f=r(e,o ? 0.05:0.06),t[19]=o,t[20]=e,t[21]=f):f=t[21],t[22]!==o||t[23]!==e ?(h=o ? "translateY(0)rotate(45deg)":`translateY(-${r(e,0.22)})`,t[22]=o,t[23]=e,t[24]=h):h=t[24],t[25]!==n||t[26]!==u||t[27]!==f||t[28]!==h ?(m={...n,width:u,height:f,transform:h},t[25]=n,t[26]=u,t[27]=f,t[28]=h,t[29]=m):m=t[29],t[30]!==o||t[31]!==e ?(g=r(e,o ? 0.8:0.3),t[30]=o,t[31]=e,t[32]=g):g=t[32],t[33]!==o||t[34]!==e ?(p=r(e,o ? 0.05:0.06),t[33]=o,t[34]=e,t[35]=p):p=t[35],t[36]!==o||t[37]!==e ?(b=o ? "translateY(0)rotate(315deg)":`translateY(${r(e,0.22)})`,t[36]=o,t[37]=e,t[38]=b):b=t[38],t[39]!==n||t[40]!==g||t[41]!==p||t[42]!==b ?(v={...n,width:g,height:p,transform:b},t[39]=n,t[40]=g,t[41]=p,t[42]=b,t[43]=v):v=t[43],t[44]!==o||t[45]!==e ?(w=o ? `translateX(${r(e,1.1)})`:"translateX(0)",t[44]=o,t[45]=e,t[46]=w):w=t[46],t[47]!==n||t[48]!==w ?(x={...n,left:"auto",transform:w},t[47]=n,t[48]=w,t[49]=x):x=t[49],t[50]!==m||t[51]!==v||t[52]!==x ?(A=[m,v,x],t[50]=m,t[51]=v,t[52]=x,t[53]=A):A=t[53];const S=A;let N,R,$,k,C,Y,X;return t[54]!==a ?(N=()=>{H(!!a);},R=[a],t[54]=a,t[55]=N,t[56]=R):(N=t[55],R=t[56]),O(N,R),t[57]!==e ?($=r(e,0.2),t[57]=e,t[58]=$):$=t[58],t[59]!==F||t[60]!==e||t[61]!==$ ?(k={width:e,height:e,background:F,borderRadius:$},t[59]=F,t[60]=e,t[61]=$,t[62]=k):k=t[62],t[63]!==o||t[64]!==s ?(C=()=>requestAnimationFrame(()=>{s?.(!o),H(!o);}),t[63]=o,t[64]=s,t[65]=C):C=t[65],t[66]!==S ?(Y=S.map(Q),t[66]=S,t[67]=Y):Y=t[67],t[68]!==k||t[69]!==C||t[70]!==Y ?(X=I("button",{className:"ono-menu-button",style:k,onClick:C,children:Y}),t[68]=k,t[69]=C,t[70]=Y,t[71]=X):X=t[71],X;};function P(y,t){let a;const s=y.split("");return s[s.length-1]==="x"&&(a=Number(s.slice(0,-2).join(""))*t+"px"),a;}function Q(y,t){return I("span",{style:{...y}},t);}export{W as M};
@@ -0,0 +1 @@
1
+ import{jsxs as O0,jsx as c,Fragment as S0}from "react/jsx-runtime";import{c as v0}from "react/compiler-runtime";import{portalRenderer as N0,chainClassNames as x0}from "./index.js";import{useState as G,useRef as l0,useEffect as d0}from "react";let p0=1;const i=[],L=(t,e,o)=>(i.length===0&&(p0=1),_0(e.instancesKey||"",t,{id:`${o}-${p0++}`,key:e.instancesKey||"",reactNode:t,props:e,offsetOptions:{topOffset:0,height:0,bottomOffset:0}}),i),h0=(t)=>{const e=i.findIndex((o)=>o.id===t);return e<=0 ? 0:i[e-1].offsetOptions.bottomOffset;},_0=(t,e,o)=>{const l=(n)=>N0(e,{zIndex:999+p0-1,...n.props,id:n.id},n.id,"ono-message-root");if(!t){const n=l(o);i.push({...o,props:{...o.props,id:o.id,destroy:n},destroy:n});}let d=!1;const N=i.map((n)=>{if(n.key===t){d=!0;const m={...n.props,...o.props};return{...n,props:m};}{const m=l(n);return{...n,props:{...n.props,id:n.id,destroy:m},destroy:m};}});if(Object.assign(i,N),!d){const n=l(o);i.push({...o,props:{...o.props,id:o.id,destroy:n},destroy:n});}},I0={info:{light:"#1677ff",dark:"#1677ff"},success:{light:"#52c41a",dark:"#49aa19"},error:{light:"#ff4d4f",dark:"#a61d24"},warning:{light:"#faad14",dark:"#d89614"},loading:{light:"#9254de",dark:"#f5f5f5"}},J=(t,e)=>I0[t][e],y0=(t)=>{switch(t){case "success":return c("svg",{className:"ono-type-icon",viewBox:"0 0 1024 1024",focusable:"false","data-icon":"check-circle",fill:J(t,"light"),"aria-hidden":"true",children:c("path",{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm193.5 301.7l-210.6 292a31.8 31.8 0 01-51.7 0L318.5 484.9c-3.8-5.3 0-12.7 6.5-12.7h46.9c10.2 0 19.9 4.9 25.9 13.3l71.2 98.8 157.2-218c6-8.3 15.6-13.3 25.9-13.3H699c6.5 0 10.3 7.4 6.5 12.7z"})});case "error":return c("svg",{className:"ono-type-icon",viewBox:"0 0 1024 1024",focusable:"false","data-icon":"close-circle",fill:J(t,"light"),"aria-hidden":"true",children:c("path",{d:"M512 64c247.4 0 448 200.6 448 448S759.4 960 512 960 64 759.4 64 512 264.6 64 512 64zm127.98 274.82h-.04l-.08.06L512 466.75 384.14 338.88c-.04-.05-.06-.06-.08-.06a.12.12 0 00-.07 0c-.03 0-.05.01-.09.05l-45.02 45.02a.2.2 0 00-.05.09.12.12 0 000 .07v.02a.27.27 0 00.06.06L466.75 512 338.88 639.86c-.05.04-.06.06-.06.08a.12.12 0 000 .07c0 .03.01.05.05.09l45.02 45.02a.2.2 0 00.09.05.12.12 0 00.07 0c.02 0 .04-.01.08-.05L512 557.25l127.86 127.87c.04.04.06.05.08.05a.12.12 0 00.07 0c.03 0 .05-.01.09-.05l45.02-45.02a.2.2 0 00.05-.09.12.12 0 000-.07v-.02a.27.27 0 00-.05-.06L557.25 512l127.87-127.86c.04-.04.05-.06.05-.08a.12.12 0 000-.07c0-.03-.01-.05-.05-.09l-45.02-45.02a.2.2 0 00-.09-.05.12.12 0 00-.07 0z"})});case "loading":return c("svg",{className:x0("ono-info-icon","ono-loading"),viewBox:"0 0 1024 1024",focusable:"false","data-icon":"loading",fill:J(t,"light"),"aria-hidden":"true",children:c("path",{d:"M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z"})});default:return c("svg",{className:"ono-info-icon",viewBox:"64 64 896 896",focusable:"false","data-icon":"exclamation-circle",fill:J(t,"light"),"aria-hidden":"true",children:c("path",{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm-32 232c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V296zm32 440a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"})});}},g0=(t)=>{const e=v0(3),{handleDestroy:o}=t;let l,d;return e[0]===Symbol.for("react.memo_cache_sentinel")?(l=c("svg",{className:"ono-clear-icon",viewBox:"64 64 896 896",focusable:"false","data-icon":"close-circle",fill:"currentColor","aria-hidden":"true",children:c("path",{d:"M512 64c247.4 0 448 200.6 448 448S759.4 960 512 960 64 759.4 64 512 264.6 64 512 64zm127.98 274.82h-.04l-.08.06L512 466.75 384.14 338.88c-.04-.05-.06-.06-.08-.06a.12.12 0 00-.07 0c-.03 0-.05.01-.09.05l-45.02 45.02a.2.2 0 00-.05.09.12.12 0 000 .07v.02a.27.27 0 00.06.06L466.75 512 338.88 639.86c-.05.04-.06.06-.06.08a.12.12 0 000 .07c0 .03.01.05.05.09l45.02 45.02a.2.2 0 00.09.05.12.12 0 00.07 0c.02 0 .04-.01.08-.05L512 557.25l127.86 127.87c.04.04.06.05.08.05a.12.12 0 00.07 0c.03 0 .05-.01.09-.05l45.02-45.02a.2.2 0 00.05-.09.12.12 0 000-.07v-.02a.27.27 0 00-.05-.06L557.25 512l127.87-127.86c.04-.04.05-.06.05-.08a.12.12 0 000-.07c0-.03-.01-.05-.05-.09l-45.02-45.02a.2.2 0 00-.09-.05.12.12 0 00-.07 0z"})}),e[0]=l):l=e[0],e[1]!==o ?(d=c("button",{onClick:o,children:l}),e[1]=o,e[2]=d):d=e[2],d;},O=(t)=>{const e=v0(74),{id:o,instancesKey:l,duration:d,speed:N,offset:n,message:m,type:Q,plain:f0,showClose:u0,zIndex:U,onClose:m0,destroy:W}=t,X=d===void 0 ? 3e3:d,h=N===void 0 ? 300:N,Y=n===void 0 ? 20:n,Z=f0===void 0||f0,e0=u0!==void 0&&u0,s0=m0===void 0 ? M0:m0,[,t0]=G(!1),[y,C0]=G(0);let _;e[0]!==o ?(_=((a)=>{const r=i.findIndex((p)=>p.id===a);return r<=0 ? 0:i[r-1].offsetOptions.topOffset;})(o),e[0]=o,e[1]=_):_=e[1];const [k,b0]=G(_);let I;e[2]!==X||e[3]!==m||e[4]!==s0||e[5]!==e0||e[6]!==h||e[7]!==Q ?(I={duration:X,speed:h,message:m,type:Q,showClose:e0,onClose:s0},e[2]=X,e[3]=m,e[4]=s0,e[5]=e0,e[6]=h,e[7]=Q,e[8]=I):I=e[8];const [s,w0]=G(I);let M;e[9]===Symbol.for("react.memo_cache_sentinel")?(M=(a)=>w0((r)=>({...r,...a})),e[9]=M):M=e[9];const z0=M,$=l0(null),o0=l0(null),f=l0(null),C=k+y,n0=`-50%${k}px`,a0=`translate ${h}ms ease-in-out`;let B;e[10]!==n0||e[11]!==a0||e[12]!==U ?(B={translate:n0,transition:a0,zIndex:U},e[10]=n0,e[11]=a0,e[12]=U,e[13]=B):B=e[13];const r0=B;let K;e[14]!==W||e[15]!==y||e[16]!==o||e[17]!==s.onClose||e[18]!==h ?(K=()=>{f.current&&(f.current.classList.remove("ono-message-enter"),f.current.classList.add("ono-message-leave"),f.current.style.translate=`-50%${h0(o)-y}px`,((a)=>{const r=i.findIndex((p)=>p.id===a);r!==-1&&i.splice(r,1);})(o),setTimeout(()=>W(s.onClose),h));},e[14]=W,e[15]=y,e[16]=o,e[17]=s.onClose,e[18]=h,e[19]=K):K=e[19];const g=K;let T;e[20]!==g ?(T=(a,r,p)=>{a!=="loading"&&($.current=setTimeout(g,r-p));},e[20]=g,e[21]=T):T=e[21];const u=T;let j;e[22]===Symbol.for("react.memo_cache_sentinel")?(j=()=>{$.current&&(clearTimeout($.current),$.current=null);},e[22]=j):j=e[22];const k0=j;let D;e[23]!==s.speed ?(D=()=>{if(!f.current)return;const{height:a}=f.current.getBoundingClientRect();f.current.style.setProperty("--speed",`${s.speed}ms`),C0(a);},e[23]=s.speed,e[24]=D):D=e[24];const c0=D;let v,R;e[25]!==o||e[26]!==Y||e[27]!==t0 ?(v=()=>{const a=h0(o);t0((r)=>(r&&b0(a+Y),!0)),requestAnimationFrame(v);},e[25]=o,e[26]=Y,e[27]=t0,e[28]=v):v=e[28],e[29]!==Z||e[30]!==s.type ?(R=()=>x0("ono-message",`ono-message-${s.type}`,"ono-message-enter",Z ? "":"ono-message-color"),e[29]=Z,e[30]=s.type,e[31]=R):R=e[31];const i0=R;let x,E,F,q,A,H,P,b,w,z,V;return e[32]!==l||e[33]!==s.duration||e[34]!==s.speed||e[35]!==s.type||e[36]!==u ?(x=()=>{if(s.type==="loading"){if(o0.current)return;o0.current=setTimeout(()=>{o0.current=null;const a=(r=l||"")? i.find((p)=>p.key===r)?.props:null;var r;a&&(z0({...a}),u(s.type,a.duration||s.duration,a.speed||s.speed),x());},100);}},e[32]=l,e[33]=s.duration,e[34]=s.speed,e[35]=s.type,e[36]=u,e[37]=x):x=e[37],e[38]!==x||e[39]!==v||e[40]!==s.duration||e[41]!==s.speed||e[42]!==s.type||e[43]!==u ?(E=()=>{u(s.type,s.duration,s.speed),v(),x();},e[38]=x,e[39]=v,e[40]=s.duration,e[41]=s.speed,e[42]=s.type,e[43]=u,e[44]=E):E=e[44],e[45]!==s.duration||e[46]!==s.speed||e[47]!==s.type ?(F=[s.type,s.duration,s.speed],e[45]=s.duration,e[46]=s.speed,e[47]=s.type,e[48]=F):F=e[48],d0(E,F),e[49]!==c0 ?(q=()=>{c0();},e[49]=c0,e[50]=q):q=e[50],e[51]===Symbol.for("react.memo_cache_sentinel")?(A=[f],e[51]=A):A=e[51],d0(q,A),e[52]!==C||e[53]!==y||e[54]!==o||e[55]!==k ?(H=()=>{((a,r)=>{const p=i.findIndex((L0)=>L0.id===a);p<0||(i[p].offsetOptions=r);})(o,{topOffset:k,height:y,bottomOffset:C});},e[52]=C,e[53]=y,e[54]=o,e[55]=k,e[56]=H):H=e[56],e[57]!==C ?(P=[C],e[57]=C,e[58]=P):P=e[58],d0(H,P),e[59]!==i0 ?(b=i0(),e[59]=i0,e[60]=b):b=e[60],e[61]!==s.duration||e[62]!==s.speed||e[63]!==s.type||e[64]!==u ?(w=()=>u(s.type,s.duration,s.speed),e[61]=s.duration,e[62]=s.speed,e[63]=s.type,e[64]=u,e[65]=w):w=e[65],e[66]!==g||e[67]!==s ?(z=typeof s.message=="function" ? s.message(y0(s.type),s.showClose&&c(g0,{handleDestroy:g})):O0(S0,{children:[y0(s.type),c("div",{children:s.message}),s.showClose&&c(g0,{handleDestroy:g})]}),e[66]=g,e[67]=s,e[68]=z):z=e[68],e[69]!==r0||e[70]!==b||e[71]!==w||e[72]!==z ?(V=c("div",{ref:f,className:b,style:r0,onMouseEnter:k0,onMouseLeave:w,children:z}),e[69]=r0,e[70]=b,e[71]=w,e[72]=z,e[73]=V):V=e[73],V;},S=(t)=>{if(typeof t=="string")return{message:t};{const e={...t,instancesKey:t.key};return delete e.key,{...e};}},j0={info:(t)=>{L(O,{...S(t),type:"info"},"ono-message");},success:(t)=>{L(O,{...S(t),type:"success"},"ono-message");},warning:(t)=>{L(O,{...S(t),type:"warning"},"ono-message");},error:(t)=>{L(O,{...S(t),type:"error"},"ono-message");},loading:(t)=>{L(O,{...S(t),type:"loading"},"ono-message");}};function M0(){}export{j0 as m};
@@ -0,0 +1 @@
1
+ import{jsx as o,jsxs as c,Fragment as M}from "react/jsx-runtime";import{portalRenderer as E,adjustingColors as m,chainClassNames as F}from "./index.js";import{useState as H,useRef as x,useEffect as y}from "react";import{B as v}from "./Button-CGyWgrQj.js";const L=({title:d="This is a modal title",icon:B,content:g="This is a modal content",okText:N="confirm",cancelText:k="cancel",confirmDisabled:P,cancelDisabled:T,startPosition:t,onConfirm:j,onCancel:w,mask:h=!0,maskClosable:z=!1,width:f,btnClr:a,footer:u=({OkBtn:s,CancelBtn:i})=>c(M,{children:[o(i,{}),o(s,{})]}),modalBody:b,destroy:C})=>{const [s,i]=H(!1),l=x(null),n=x(null),D=[{label:"themeColor",value:a||""},{label:"themeHoverColor",value:a&&m(a,"light",10)||""},{label:"themeActiveColor",value:a&&m(a,"dark",20)||""},{label:"themeDisabledClr",value:a&&m(a,"light",20)||""}],r=()=>{if(t){if(!n.current)return;n.current.classList.remove("ono-modal-enter"),n.current.classList.add("ono-modal-leave"),setTimeout(()=>{C();},300);}else C();};return y(()=>(l.current&&(h ? l.current.showModal():l.current.show()),()=>{l.current&&l.current.close();}),[l.current,h]),y(()=>{(()=>{if(!n.current)return;const e=n.current.style;f&&e.setProperty("--width",f+"px"),t&&(e.setProperty("--left",(t.x/window.innerWidth*100).toFixed(2)+"%"),e.setProperty("--top",(t.y/window.innerHeight*100).toFixed(2)+"%")),a&&D.forEach((p)=>e.setProperty(`--${p.label}`,p.value));})();},[n]),o("dialog",{ref:l,className:"ono-modal",onClick:()=>z&&r(),children:b ? b(r):c("div",{ref:n,className:F("ono-modal-box",t ? "ono-modal-enter":""),onClick:(e)=>e.stopPropagation(),children:[c("div",{className:"ono-modal-box-body",children:[B ?? o("div",{className:"ono-modal-box-body-icon",children:o("svg",{color:"#faad14",viewBox:"64 64 896 896",focusable:"false","data-icon":"exclamation-circle",width:"22px",height:"22px",fill:"currentColor","aria-hidden":"true",style:{marginInlineEnd:"12px"},children:o("path",{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm-32 232c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V296zm32 440a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"})})}),c("div",{className:"ono-modal-box-body-contentBar",children:[o("h1",{className:"ono-modal-box-body-contentBar-title",children:d}),o("p",{className:"ono-modal-box-body-contentBar-content",children:g})]})]}),u&&o("div",{className:"ono-modal-box-footer",children:u({OkBtn:()=>o(v,{className:"ono-modal-box-footer-confirmBtn",loading:s,disabled:P,onClick:async()=>{i(!0);try{const e=j?.();e instanceof Promise&&await e;}finally{i(!1),r();}},children:N ?? "Confirm"}),CancelBtn:()=>o(v,{className:"ono-modal-box-footer-cancelBtn",disabled:T||s,onClick:()=>{w?.(),r();},children:k ?? "Cancel"}),handleClose:()=>r()})})]})});},I=(d)=>E(L,d,"ono-modal");export{I as M};
@@ -0,0 +1 @@
1
+ import{jsx as s,jsxs as q}from "react/jsx-runtime";import{c as w}from "react/compiler-runtime";const E=(O)=>{const n=w(40),{firstBtn:N,lastBtn:u,currentPage:t,total:a,prevBtn:l,nextBtn:c,styles:x,className:F,children:B,onChange:i,pageBtnClassName:y,pageBtnActiveClassName:k,hiddenNextBtnOnLastPage:P,hiddenPrevBtnOnFirstPage:A}=O,r=Math.max(1,Math.min(t,a));let f;n[0]!==B||n[1]!==t||n[2]!==i||n[3]!==k||n[4]!==y||n[5]!==r||n[6]!==a ?(f=()=>Array.from({length:a},(o,e)=>s("li",{className:"ono-pagination-base",onClick:()=>i(e+1),children:B ? B({page:e+1,isActive:t===e+1}):s("div",{className:`ono-pagination-base ${y ?? "ono-pagination-btn"}${r===e+1 ? k ?? "ono-pagination-btn-active":""}`,children:e+1})},e+1)),n[0]=B,n[1]=t,n[2]=i,n[3]=k,n[4]=y,n[5]=r,n[6]=a,n[7]=f):f=n[7];const $=f;let v;n[8]!==$||n[9]!==r||n[10]!==a ?(v=()=>{const o=$();if(o.length<=7)return o;const e=a-1,b=r,L=b>=a-2;return b<=3 ? [...o.slice(0,b===3 ? 4:3),"...",o[e]]:L ? [o[0],"...",...o.slice(b===a-2 ?-4:-3)]:[o[0],"...",...o.slice(b-2,b+1),"...",o[e]];},n[8]=$,n[9]=r,n[10]=a,n[11]=v):v=n[11];const j=v,M=`ono-pagination ${F}`;let p,g,d,m,h,C;return n[12]!==N||n[13]!==i ?(p=N&&s("li",{className:N ? "ono-pagination-base":"ono-pagination-btn",onClick:()=>i(1),children:N}),n[12]=N,n[13]=i,n[14]=p):p=n[14],n[15]!==t||n[16]!==A||n[17]!==i||n[18]!==l ?(g=A&&t===1 ? null:s("li",{className:"ono-pagination-base",style:{cursor:t!==1 ? "pointer":"no-drop"},onClick:()=>{t<=1||i(t-1);},children:l ? typeof l=="function" ? l(t!==1):l:s("div",{className:l ? "ono-pagination-base":"ono-pagination-btn",children:"prevBtn"})}),n[15]=t,n[16]=A,n[17]=i,n[18]=l,n[19]=g):g=n[19],n[20]!==j ?(d=j(),n[20]=j,n[21]=d):d=n[21],n[22]!==t||n[23]!==P||n[24]!==c||n[25]!==i||n[26]!==a ?(m=P&&t===a ? null:s("li",{className:"ono-pagination-base",style:{cursor:t!==a ? "pointer":"no-drop"},onClick:()=>{i(t>=a ? a:t+1);},children:c ? typeof c=="function" ? c(t!==a):c:s("div",{className:c ? "ono-pagination-base":"ono-pagination-btn",children:"nextBtn"})}),n[22]=t,n[23]=P,n[24]=c,n[25]=i,n[26]=a,n[27]=m):m=n[27],n[28]!==u||n[29]!==i||n[30]!==a ?(h=u&&s("li",{className:u ? "ono-pagination-base":"ono-pagination-btn",onClick:()=>i(a),children:u}),n[28]=u,n[29]=i,n[30]=a,n[31]=h):h=n[31],n[32]!==x||n[33]!==M||n[34]!==p||n[35]!==g||n[36]!==d||n[37]!==m||n[38]!==h ?(C=q("ul",{className:M,style:x,children:[p,g,d,m,h]}),n[32]=x,n[33]=M,n[34]=p,n[35]=g,n[36]=d,n[37]=m,n[38]=h,n[39]=C):C=n[39],C;};export{E as P};
@@ -0,0 +1 @@
1
+ import{jsx as R,jsxs as V}from "react/jsx-runtime";import{c as L}from "react/compiler-runtime";import{chainClassNames as M}from "./index.js";import{useState as X,useRef as J,useEffect as Y}from "react";const Z=(C)=>{const e=L(41),{name:n,value:l,style:f,checked:o,onChange:k,children:d,className:b,radioW:j,radioGap:E,checkedColor:P,unCheckedColor:i,disabled:v}=C,u=j===void 0 ? 16:j,m=E===void 0 ? 4:E,a=P===void 0 ? "#532ce1":P,h=i===void 0 ? "transparent":i,t=v!==void 0&&v,[r,g]=X(""),y=J(null),x=J(null),p=J(null);let c,s,N,w,_;e[0]!==u ?(c={value:u,name:"w"},e[0]=u,e[1]=c):c=e[1],e[2]!==m ?(s={value:m,name:"gap"},e[2]=m,e[3]=s):s=e[3],e[4]!==a ?(N={value:a,name:"checkedColor"},e[4]=a,e[5]=N):N=e[5],e[6]!==h ?(w={value:h,name:"unCheckedColor"},e[6]=h,e[7]=w):w=e[7],e[8]!==c||e[9]!==s||e[10]!==N||e[11]!==w ?(_=[c,s,N,w],e[8]=c,e[9]=s,e[10]=N,e[11]=w,e[12]=_):_=e[12];const A=_,O=ee;let $;e[13]!==r||e[14]!==o||e[15]!==a||e[16]!==A ?($=()=>{if(!p.current||!x.current)return;A.forEach((T)=>{const{value:K,name:U}=T;K&&O(K,U,x.current);});const Q=getComputedStyle(p.current);r||g(Q.borderColor),p.current.style.borderColor=o ? a:r;},e[13]=r,e[14]=o,e[15]=a,e[16]=A,e[17]=$):$=e[17];const B=$;let D,F,G,q;e[18]!==B ?(D=()=>{B();},e[18]=B,e[19]=D):D=e[19],e[20]!==r||e[21]!==o ?(F=[x,p,o,r],e[20]=r,e[21]=o,e[22]=F):F=e[22],Y(D,F),e[23]!==b ?(G=M("ono-radio-box",b),e[23]=b,e[24]=G):G=e[24],e[25]===Symbol.for("react.memo_cache_sentinel")?(q=()=>y.current?.click(),e[25]=q):q=e[25];const H=l+"",I=l+""+d;let S,W,z;return e[26]!==o||e[27]!==t||e[28]!==n||e[29]!==k||e[30]!==H||e[31]!==I ?(S=R("div",{ref:p,className:"ono-radio",onClick:q,children:R("input",{type:"radio",name:n,ref:y,value:H,checked:o,disabled:t,id:I,onChange:k})}),e[26]=o,e[27]=t,e[28]=n,e[29]=k,e[30]=H,e[31]=I,e[32]=S):S=e[32],e[33]!==d||e[34]!==l ?(W=d&&R("label",{htmlFor:l+""+d||"",children:d}),e[33]=d,e[34]=l,e[35]=W):W=e[35],e[36]!==f||e[37]!==G||e[38]!==S||e[39]!==W ?(z=V("div",{ref:x,className:G,style:f,children:[S,W]}),e[36]=f,e[37]=G,e[38]=S,e[39]=W,e[40]=z):z=e[40],z;};function ee(C,e,n){const l=typeof C=="number";n.style.setProperty(`--${e}`,l ? `${C}px`:C);}const le=(C)=>{const e=L(25),{name:n,style:l,options:f,onChange:o,className:k,radioW:d,radioGap:b,labelPosition:j,checkedColor:E,unCheckedColor:P,value:i}=C,v=d===void 0 ? 16:d,u=b===void 0 ? 4:b,m=j===void 0 ? "right":j,a=E===void 0 ? "#532ce1":E,h=P===void 0 ? "transparent":P;let t,r,g;if(e[0]!==k ?(t=M("ono-radio-group",k),e[0]=k,e[1]=t):t=e[1],e[2]!==a||e[3]!==m||e[4]!==n||e[5]!==o||e[6]!==f||e[7]!==u||e[8]!==v||e[9]!==i||e[10]!==h){let y;e[12]!==a||e[13]!==m||e[14]!==n||e[15]!==o||e[16]!==u||e[17]!==v||e[18]!==i||e[19]!==h ?(y=(x)=>{const{label:p,value:c,disabled:s}=x;return R(Z,{name:n,value:c,radioW:v,radioGap:u,style:{flexDirection:m==="left" ? "row-reverse":"row"},checkedColor:a,unCheckedColor:h,onChange:()=>o(c),checked:i+""==c+"",disabled:typeof s=="function" ? s(i):s||!1,children:p},p);},e[12]=a,e[13]=m,e[14]=n,e[15]=o,e[16]=u,e[17]=v,e[18]=i,e[19]=h,e[20]=y):y=e[20],r=f.map(y),e[2]=a,e[3]=m,e[4]=n,e[5]=o,e[6]=f,e[7]=u,e[8]=v,e[9]=i,e[10]=h,e[11]=r;}else r=e[11];return e[21]!==l||e[22]!==t||e[23]!==r ?(g=R("div",{className:t,style:l,children:r}),e[21]=l,e[22]=t,e[23]=r,e[24]=g):g=e[24],g;};export{Z as R,le as a};
@@ -0,0 +1 @@
1
+ import{jsx as j}from "react/jsx-runtime";import{c as E}from "react/compiler-runtime";import{chainClassNames as R}from "./index.js";import{forwardRef as z,useState as B,useRef as D,useEffect as A}from "react";const F=(L)=>{const t=E(10),{children:e,disabled:r,className:o,style:d,onClick:n}=L;let c,l,s;return t[0]!==o ?(c=R("ono-scrollable-tab",o),t[0]=o,t[1]=c):c=t[1],t[2]!==r||t[3]!==n ?(l=(a)=>!r&&n?.(a),t[2]=r,t[3]=n,t[4]=l):l=t[4],t[5]!==e||t[6]!==d||t[7]!==c||t[8]!==l ?(s=j("li",{className:c,style:d,onClick:l,children:e}),t[5]=e,t[6]=d,t[7]=c,t[8]=l,t[9]=s):s=t[9],s;},M=z((L,t)=>{const e=E(26),{activeIndex:r,children:o,className:d,style:n,position:c,onChange:l}=L,s=c===void 0 ? "center":c,[a,I]=B(0),u=D(null);let g;e[0]!==l ?(g=(i)=>{u.current&&Array.from(u.current.children).some((x,f)=>{if(x.contains(i.target))return I(f),l?.(f),!0;});},e[0]=l,e[1]=g):g=e[1];const v=g;let y,b,C,k,N,S,m,h,W;return e[2]!==r||e[3]!==a||e[4]!==s||e[5]!==n?.gap ?(y=()=>{const i=u.current;if(!i||a<0)return;const x=i.offsetWidth,f=Array.from(i.children);if(a>=f.length)return;const w=parseInt((n?.gap||getComputedStyle(i).gap||"0").toString(),10)||0;let p=0;f.slice(0,a+1).forEach((q)=>(p+=q.offsetWidth+w,p));e:switch(s){case "start":i.scrollLeft=p-f[a].offsetWidth-w;break e;case "end":i.scrollLeft=p-x;break e;default:p-=f[a].offsetWidth/2+(r!==f.length-1 ? w:0),i.scrollLeft=p-x/2;}},e[2]=r,e[3]=a,e[4]=s,e[5]=n?.gap,e[6]=y):y=e[6],e[7]!==r||e[8]!==o||e[9]!==s ?(b=[u,o,r,s],e[7]=r,e[8]=o,e[9]=s,e[10]=b):b=e[10],A(y,b),e[11]!==r ?(C=()=>{I(r||0);},k=[r],e[11]=r,e[12]=C,e[13]=k):(C=e[12],k=e[13]),A(C,k),e[14]!==t ?(N=()=>{t&&(typeof t=="function" ? t(u.current):t.current=u.current);},S=[t],e[14]=t,e[15]=N,e[16]=S):(N=e[15],S=e[16]),A(N,S),e[17]!==d ?(m=R("ono-scrollable-tabs",d),e[17]=d,e[18]=m):m=e[18],e[19]!==o ?(h=o(F),e[19]=o,e[20]=h):h=e[20],e[21]!==v||e[22]!==n||e[23]!==h||e[24]!==m ?(W=j("ul",{ref:u,className:m,style:n,onClick:v,children:h}),e[21]=v,e[22]=n,e[23]=h,e[24]=m,e[25]=W):W=e[25],W;});export{M as S};
@@ -0,0 +1 @@
1
+ import{jsx as s,Fragment as fe}from "react/jsx-runtime";import{c as re}from "react/compiler-runtime";import{chainClassNames as Q}from "./index.js";import{useState as R,useEffect as me}from "react";import{L as he}from "./List-ClfyFOXz.js";import{O as be}from "./Input-DnB8zvWy.js";import{T as Ce}from "./Tooltip-Dw-vi5zs.js";const ge=(C)=>{const e=re(20),{label:o,value:t,disabled:l,onChange:c,selectValue:i,optionRender:f,currentValue:p,onChangeCursor:g}=C;let m,h,u,b;return e[0]!==c||e[1]!==t ?(m=()=>c?.(t),e[0]=c,e[1]=t,e[2]=m):m=e[2],e[3]!==l||e[4]!==o||e[5]!==g ?(h=()=>!l&&g?.(o),e[3]=l,e[4]=o,e[5]=g,e[6]=h):h=e[6],e[7]!==p||e[8]!==l||e[9]!==o||e[10]!==f||e[11]!==i||e[12]!==t ?(u=f ? f({label:o,value:t,disabled:l},i===o):s("div",{className:Q("ono-option-item-content",p===o&&i!==o ? "ono-option-item-content-active":"",i===o ? "ono-option-item-content-selected":"",l ? "ono-option-item-content-disabled":""),children:o}),e[7]=p,e[8]=l,e[9]=o,e[10]=f,e[11]=i,e[12]=t,e[13]=u):u=e[13],e[14]!==l||e[15]!==o||e[16]!==m||e[17]!==h||e[18]!==u ?(b=s("button",{role:"option","aria-label":o,disabled:l,className:"ono-option-item",onClick:m,onMouseEnter:h,children:u}),e[14]=l,e[15]=o,e[16]=m,e[17]=h,e[18]=u,e[19]=b):b=e[19],b;},xe=(C)=>{const e=re(78),{options:o,defaultValue:t,placeholder:l,inputBorder:c,isShowArrow:i,disabled:f,clearable:p,selectClassName:g,optionsClassName:m,notFoundContent:h,optionRender:u,onClear:b,onChange:v,filterOption:a}=C,[d,se]=R(""),[U,X]=R(""),[r,Y]=R(""),[A,ce]=R(!1),[w,ue]=R(!1),[Z,de]=R("");let B;e[0]!==o ?(B=(n)=>{const K=o.find((pe)=>pe.value===n);se(K ? K.label:"");},e[0]=o,e[1]=B):B=e[1];const N=B;let F;e[2]!==a||e[3]!==o||e[4]!==r ?(F=()=>a ? typeof a=="function" ? a(r,o):o.filter((n)=>n.label.toLocaleLowerCase().includes(r.toLocaleLowerCase())):o,e[2]=a,e[3]=o,e[4]=r,e[5]=F):F=e[5];const $=F;let j;e[6]!==a||e[7]!==r ?(j=(n)=>{ue(n),a&&r&&!n&&Y("");},e[6]=a,e[7]=r,e[8]=j):j=e[8];const ee=j;let z;e[9]!==N||e[10]!==v ?(z=(n)=>{v?.(n),de(n),N(n);},e[9]=N,e[10]=v,e[11]=z):z=e[11];const oe=z;let D;e[12]!==v||e[13]!==b ?(D=()=>{b?.(),v?.(""),de(""),se(""),Y("");},e[12]=v,e[13]=b,e[14]=D):D=e[14];const te=D;let P,T,W,q,S,L;e[15]!==t||e[16]!==N ?(P=()=>{t&&N(t);},e[15]=t,e[16]=N,e[17]=P):P=e[17],e[18]!==t ?(T=[t],e[18]=t,e[19]=T):T=e[19],me(P,T),e[20]!==t||e[21]!==o ?(W=()=>{if(o.length>0){if(t){const n=o.find((K)=>K.value===t);n&&X(n.label);}else for(let n=0;n<o.length;n++)if(o[n]?.disabled!==!0){X(o[0].label);break;}}},q=[o,t],e[20]=t,e[21]=o,e[22]=W,e[23]=q):(W=e[22],q=e[23]),me(W,q),e[24]!==m ?(S=Q("ono-option-container",m),e[24]=m,e[25]=S):S=e[25],e[26]!==$ ?(L=$(),e[26]=$,e[27]=L):L=e[27];const ne=h ?? "No Data";let V,y,_,G,H;e[28]!==ne ?(V=s("div",{className:"ono-option-item",children:s("div",{className:"ono-option-item-content-no-data",onClick:we,children:ne})}),e[28]=ne,e[29]=V):V=e[29],e[30]!==U||e[31]!==oe||e[32]!==d||e[33]!==u ?(y=(n)=>s(ge,{...n,onChange:oe,selectValue:d.toString(),currentValue:U.toString(),optionRender:u,onChangeCursor:X},n.value),e[30]=U,e[31]=oe,e[32]=d,e[33]=u,e[34]=y):y=e[34],e[35]!==L||e[36]!==V||e[37]!==y ?(_=s(he,{list:L,fallback:V,children:y}),e[35]=L,e[36]=V,e[37]=y,e[38]=_):_=e[38],e[39]===Symbol.for("react.memo_cache_sentinel")?(G=()=>ce(!0),H=()=>ce(!1),e[39]=G,e[40]=H):(G=e[39],H=e[40]);const le=a ? "":"ono-select-readonly";let k,x;e[41]!==g||e[42]!==le ?(k=Q(le,g),e[41]=g,e[42]=le,e[43]=k):k=e[43],e[44]!==a||e[45]!==d||e[46]!==l||e[47]!==Z ?(x=a&&Z ? d.toString()||"":l,e[44]=a,e[45]=d,e[46]=l,e[47]=Z,e[48]=x):x=e[48];const ae=!a;let M;e[49]!==a||e[50]!==d||e[51]!==w||e[52]!==r ?(M=a&&w ? r:d.toString(),e[49]=a,e[50]=d,e[51]=w,e[52]=r,e[53]=M):M=e[53];const ie=A&&p;let O,I,E,J;return e[54]!==p||e[55]!==a||e[56]!==d||e[57]!==A||e[58]!==w||e[59]!==r ?(O=A&&p&&d||p&&r&&a ? s(fe,{}):s(ve,{isVisible:w}),e[54]=p,e[55]=a,e[56]=d,e[57]=A,e[58]=w,e[59]=r,e[60]=O):O=e[60],e[61]===Symbol.for("react.memo_cache_sentinel")?(I=(n)=>Y(n.target.value),e[61]=I):I=e[61],e[62]!==f||e[63]!==te||e[64]!==c||e[65]!==k||e[66]!==x||e[67]!==ae||e[68]!==M||e[69]!==ie||e[70]!==O ?(E=s("div",{className:"ono-select",onMouseEnter:G,onMouseLeave:H,children:s(be,{className:k,border:c,disabled:f,placeholder:x,readonly:ae,value:M,clearable:ie,suffix:O,onClear:te,onChange:I})}),e[62]=f,e[63]=te,e[64]=c,e[65]=k,e[66]=x,e[67]=ae,e[68]=M,e[69]=ie,e[70]=O,e[71]=E):E=e[71],e[72]!==ee||e[73]!==i||e[74]!==S||e[75]!==_||e[76]!==E ?(J=s(Ce,{sameWidth:!0,trigger:"click",placement:"bottom",isShowArrow:i,className:S,onOpenChange:ee,content:_,children:E}),e[72]=ee,e[73]=i,e[74]=S,e[75]=_,e[76]=E,e[77]=J):J=e[77],J;},ve=(C)=>{const e=re(5),{isVisible:o}=C,t=o ? "ono-select-arrow-down-active":"";let l,c,i;return e[0]!==t ?(l=Q("ono-select-arrow-down-icon",t),e[0]=t,e[1]=l):l=e[1],e[2]===Symbol.for("react.memo_cache_sentinel")?(c=s("path",{d:"M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"}),e[2]=c):c=e[2],e[3]!==l ?(i=s("svg",{className:l,viewBox:"64 64 896 896",focusable:"false","data-icon":"down",fill:"currentColor","aria-hidden":"true",children:c}),e[3]=l,e[4]=i):i=e[4],i;};function we(C){return C.stopPropagation();}export{xe as O};
@@ -0,0 +1 @@
1
+ import{jsx as d}from "react/jsx-runtime";import{c as w}from "react/compiler-runtime";import{chainClassNames as E}from "./index.js";import{useRef as P,useEffect as R}from "react";const A=(j)=>{const e=w(22),{w:p,h:v,src:h,clr:r,className:y,onClick:g}=j,c=P(null);let s,a,t,n;if(e[0]!==p ?(s={value:p,name:"w"},e[0]=p,e[1]=s):s=e[1],e[2]!==v ?(a={value:v,name:"h"},e[2]=v,e[3]=a):a=e[3],e[4]!==r ?(t={value:r,name:"clr"},e[4]=r,e[5]=t):t=e[5],e[6]!==s||e[7]!==a||e[8]!==t){const k=[s,a,t];n=()=>{c.current&&k.forEach((C)=>{var u,N,$;C.value&&(u=C.value,N=C.name,$=c.current,typeof u=="string" ? $.style.setProperty(`--${N}`,u):$.style.setProperty(`--${N}`,`${u}px`));});},e[6]=s,e[7]=a,e[8]=t,e[9]=n;}else n=e[9];const x=n;let m,i,l,o,f;return e[10]!==x ?(m=()=>{x();},e[10]=x,e[11]=m):m=e[11],e[12]!==r ?(i=[c,r],e[12]=r,e[13]=i):i=e[13],R(m,i),e[14]!==y ?(l=E("ono-svg-img",y),e[14]=y,e[15]=l):l=e[15],e[16]!==h ?(o=d("img",{src:h,alt:""}),e[16]=h,e[17]=o):o=e[17],e[18]!==g||e[19]!==l||e[20]!==o ?(f=d("div",{ref:c,className:l,onClick:g,children:o}),e[18]=g,e[19]=l,e[20]=o,e[21]=f):f=e[21],f;};export{A as S};
@@ -0,0 +1 @@
1
+ import{jsx as k,jsxs as W}from "react/jsx-runtime";import{c as ce}from "react/compiler-runtime";import{chainClassNames as X,pureNumber as Y}from "./index.js";import{useRef as f,useEffect as Z}from "react";const le=(p)=>{const e=ce(50),{id:y,text:t,style:c,color:r,checked:i,onChange:z,name:L,className:n,disabled:M}=p,B=L===void 0 ? "":L,N=M!==void 0&&M,g=f(null),x=f(null),w=f(null),C=f(null),O=f(null),Q=f(null),D=typeof r=="string" ? r:r?.active;let s;e[0]!==D ?(s={value:D,name:"checkedClr"},e[0]=D,e[1]=s):s=e[1];const G=typeof r=="string" ? void 0:r?.inactive;let a,S;e[2]!==G ?(a={value:G,name:"uncheckedClr"},e[2]=G,e[3]=a):a=e[3],e[4]!==s||e[5]!==a ?(S=[s,a],e[4]=s,e[5]=a,e[6]=S):S=e[6];const H=S,ee=ne;let _;e[7]!==n||e[8]!==c||e[9]!==H ?(_=()=>{if(!x.current||!g.current)return;let b=60,U=32;if(n||c){const T=getComputedStyle(x.current);b=Y(T.width),U=Y(T.height);}[...H,{value:b,name:"w"},{value:U,name:"h"}].forEach((T)=>{const{value:V,name:te}=T;V&&ee(V,te,g.current);}),requestAnimationFrame(()=>{C.current&&(C.current.style.transition="translate 0.3s");});},e[7]=n,e[8]=c,e[9]=H,e[10]=_):_=e[10];const I=_;let j;e[11]!==N||e[12]!==z ?(j=(b)=>{N||z?.(b.currentTarget.checked,b);},e[11]=N,e[12]=z,e[13]=j):j=e[13];const J=j;let E,$,q,A;e[14]!==I ?(E=()=>{I();},e[14]=I,e[15]=E):E=e[15],e[16]!==n||e[17]!==r||e[18]!==c||e[19]!==t ?($=[x,g,C,n,c,r,t,O,Q],e[16]=n,e[17]=r,e[18]=c,e[19]=t,e[20]=$):$=e[20],Z(E,$),e[21]!==i ?(q=()=>{w.current&&(w.current.checked=i);},A=[w,i],e[21]=i,e[22]=q,e[23]=A):(q=e[22],A=e[23]),Z(q,A);const K=N ? "ono-switch-is-disabled":"";let l,o,m,F,h,P,u,d,v,R;return e[24]!==K ?(l=X("ono-switch",K),e[24]=K,e[25]=l):l=e[25],e[26]!==i||e[27]!==y||e[28]!==B||e[29]!==J ?(o=k("input",{id:y,name:B,role:"switch",ref:w,type:"checkbox",checked:i,onChange:J}),e[26]=i,e[27]=y,e[28]=B,e[29]=J,e[30]=o):o=e[30],e[31]!==n ?(m=X("ono-switch-box",n),e[31]=n,e[32]=m):m=e[32],e[33]===Symbol.for("react.memo_cache_sentinel")?(F=()=>w.current?.click(),e[33]=F):F=e[33],e[34]!==t?.active ?(h=t?.active&&k("div",{ref:O,className:"ono-switch-children",children:t?.active}),e[34]=t?.active,e[35]=h):h=e[35],e[36]===Symbol.for("react.memo_cache_sentinel")?(P=k("div",{className:"ono-switch-slider"}),e[36]=P):P=e[36],e[37]!==t?.inactive ?(u=t?.inactive&&k("div",{ref:Q,className:"ono-switch-children",children:t?.inactive}),e[37]=t?.inactive,e[38]=u):u=e[38],e[39]!==h||e[40]!==u ?(d=W("div",{ref:C,className:"ono-switch-children-bar",children:[h,P,u]}),e[39]=h,e[40]=u,e[41]=d):d=e[41],e[42]!==c||e[43]!==m||e[44]!==d ?(v=k("div",{ref:x,className:m,style:c,onClick:F,children:d}),e[42]=c,e[43]=m,e[44]=d,e[45]=v):v=e[45],e[46]!==l||e[47]!==o||e[48]!==v ?(R=W("div",{ref:g,className:l,children:[o,v]}),e[46]=l,e[47]=o,e[48]=v,e[49]=R):R=e[49],R;};function ne(p,e,y){const t=typeof p=="number";y.style.setProperty(`--${e}`,t ? `${p}px`:p);}export{le as S};
@@ -0,0 +1 @@
1
+ import{jsx as d}from "react/jsx-runtime";import{chainClassNames as v,getElementCenterPosition as x}from "./index.js";import{useState as P,useRef as b,useEffect as w}from "react";const F=({children:s,animation:e,className:m,duration:i=300,style:u,maskColor:p="rgba(0,0,0,0.5)",disableContextMenu:f,maskClickClose:y=!0,dialogClose:l})=>{const [a,k]=P(!1),o=b(null),c=()=>{if(o.current)if(k(!0),e){const t=o.current;t.classList.remove(`ono-${e.type}-enter`),t.classList.add(`ono-${e.type}-leave`),setTimeout(l,i);}else l();};return w(()=>{(()=>{if(!e||!o.current)return;const t=o.current.parentElement.style,n=o.current.style;switch(t.setProperty("--duration",i/1e3+"s"),e.type){case "zoom":{const{x:r,y:C}=x(e.element),g=(r/window.innerWidth*100).toFixed(2)+"%",h=(C/window.innerHeight*100).toFixed(2)+"%";n.setProperty("--left",g),n.setProperty("--top",h);break;}case "fade":{const r=e.direction==="left-center" ? "--left":"--top";n.setProperty(r,e.startPosition);break;}}})();},[o,e]),d("div",{className:"ono-dialog-mask ono-dialog-mask-"+(a ? "leave":"enter"),style:{background:p},onClick:()=>y&&c(),onContextMenu:(t)=>f&&t.preventDefault(),children:d("div",{ref:o,className:v("ono-dialog",m,(()=>{if(!e)return "";const t=`ono-${e.type}-enter`,n=`ono-${e.type}-leave`;return a ? n:t;})()),style:u,onClick:(t)=>t.stopPropagation(),children:typeof s=="function" ? s(c):s})});};export{F as T};
@@ -0,0 +1 @@
1
+ import{jsx as a,jsxs as _}from "react/jsx-runtime";import{useEventListener as M,chainClassNames as w}from "./index.js";import{useEffect as L,useRef as C}from "react";import k from "react-dom/client";let f,r=null;const E=({className:e,content:s,style:n,onClick:u,onDoubleClick:d,onContextMenu:h,onMouseDown:y,onMouseUp:t,onMouseEnter:p,onMouseLeave:c,onMouseMove:o,isClickBoxToClose:l})=>(M("click",()=>{l&&r&&(r.remove(),r=null);}),a("div",{className:e,style:n,onClick:u,onDoubleClick:d,onContextMenu:h,onMouseDown:y,onMouseUp:t,onMouseEnter:p,onMouseLeave:c,onMouseMove:o,children:typeof s=="function" ? s((g)=>{r&&(r.remove(),r=null,g&&g());}):s})),x="_enter_974ly_32";let i=[];const z={success:{light:"#52c41a",dark:"#49aa19"},error:{light:"#ff4d4f",dark:"#a61d24"},warning:{light:"#faad14",dark:"#d89614"},promise:{light:"",dark:""}},v=(e,s)=>z[e][s],N=(e)=>{switch(e){case "success":return a("svg",{viewBox:"0 0 1024 1024",focusable:"false","data-icon":"check-circle",width:"24px",height:"24px",fill:v(e,"light"),"aria-hidden":"true",children:a("path",{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm193.5 301.7l-210.6 292a31.8 31.8 0 01-51.7 0L318.5 484.9c-3.8-5.3 0-12.7 6.5-12.7h46.9c10.2 0 19.9 4.9 25.9 13.3l71.2 98.8 157.2-218c6-8.3 15.6-13.3 25.9-13.3H699c6.5 0 10.3 7.4 6.5 12.7z"})});case "error":return a("svg",{viewBox:"0 0 1024 1024",focusable:"false","data-icon":"close-circle",width:"24px",height:"24px",fill:v(e,"light"),"aria-hidden":"true",children:a("path",{d:"M512 64c247.4 0 448 200.6 448 448S759.4 960 512 960 64 759.4 64 512 264.6 64 512 64zm127.98 274.82h-.04l-.08.06L512 466.75 384.14 338.88c-.04-.05-.06-.06-.08-.06a.12.12 0 00-.07 0c-.03 0-.05.01-.09.05l-45.02 45.02a.2.2 0 00-.05.09.12.12 0 000 .07v.02a.27.27 0 00.06.06L466.75 512 338.88 639.86c-.05.04-.06.06-.06.08a.12.12 0 000 .07c0 .03.01.05.05.09l45.02 45.02a.2.2 0 00.09.05.12.12 0 00.07 0c.02 0 .04-.01.08-.05L512 557.25l127.86 127.87c.04.04.06.05.08.05a.12.12 0 00.07 0c.03 0 .05-.01.09-.05l45.02-45.02a.2.2 0 00.05-.09.12.12 0 000-.07v-.02a.27.27 0 00-.05-.06L557.25 512l127.87-127.86c.04-.04.05-.06.05-.08a.12.12 0 000-.07c0-.03-.01-.05-.05-.09l-45.02-45.02a.2.2 0 00-.09-.05.12.12 0 00-.07 0z"})});case "warning":return a("svg",{viewBox:"0 0 1024 1024",focusable:"false","data-icon":"exclamation-circle",width:"24px",height:"24px",fill:v(e,"light"),"aria-hidden":"true",children:a("path",{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm-32 232c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V296zm32 440a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"})});}},b=({type:e,speed:s=200,message:n,duration:u=2e3,className:d,style:h,isUseEnterAnimation:y=!0,promiseOptions:t,toastList:p,handleDestroy:c})=>{const o=C(null);return L(()=>{o.current&&(o.current.style.setProperty("--speed",s/1e3+"s"),y&&o.current.classList.add(x),e!=="promise"&&setTimeout(()=>{o.current?.classList.remove(x),o.current?.classList.add("_leave_974ly_36");},u-s));},[o]),L(()=>{e==="promise" ?(typeof n=="function" ? n():n).then((l)=>setTimeout(()=>{c(),m({type:"success",message:typeof t?.success=="function" ? t.success(l):t?.success||"",isUseEnterAnimation:!1,toastList:p});},s)).catch((l)=>setTimeout(()=>{c(),m({type:"error",message:typeof t?.error=="function" ? t.error(l):t?.error||"",isUseEnterAnimation:!1,toastList:p});},s)):setTimeout(()=>c(()=>p=[]),u);},[e]),_("div",{ref:o,className:w(e==="promise" ? "_promise_974ly_15":"_base_974ly_15",d),style:h,onClick:()=>{},children:[a("div",{className:"_icon_974ly_40",children:N(e)}),a("p",{children:typeof n=="string" ? n:t&&t.loading})]});},m=({type:e,speed:s=200,message:n,duration:u=2e3,zIndex:d=9999,className:h,style:y,isUseEnterAnimation:t=!0,promiseOptions:p,toastList:c})=>{return(o=(l={className:"_container_974ly_1",isSingle:!0,style:{zIndex:d},content:(g)=>(L(()=>{},[c]),a(b,{className:h,style:y,type:e,message:n,speed:s,duration:u,isUseEnterAnimation:t,promiseOptions:p,handleDestroy:g,toastList:c}))}).isSingle||!1,o&&r&&f||(r=document.createElement("div"),document.body.appendChild(r),f=k.createRoot(r)),f).render(a(E,{...l})),r;var o,l;},T={success:(e)=>{i.push({type:"success",message:e}),m(typeof e=="string" ?{type:"success",message:e,toastList:i}:{type:"success",...e,toastList:i});},error:(e)=>{i.push({type:"error",message:e}),m(typeof e=="string" ?{type:"error",message:e,toastList:i}:{type:"error",...e,toastList:i});},warning:(e)=>{i.push({type:"warning",message:e}),m(typeof e=="string" ?{type:"warning",message:e,toastList:i}:{type:"warning",...e,toastList:i});},promise:(e,s)=>{i.push({type:"promise",message:e}),m({type:"promise",message:e,promiseOptions:s,toastList:i});}};export{T as t};
@@ -0,0 +1 @@
1
+ import{jsxs as K,jsx as z,Fragment as V}from "react/jsx-runtime";import{c as X}from "react/compiler-runtime";import{useClickOutSide as Y,chainClassNames as Z}from "./index.js";import{useState as ee,useRef as L,useEffect as M}from "react";import{c as te}from "./dependencies-BY0bokKL.js";let D=null,A=null;const le=(P)=>{const e=X(45),{children:s,content:f,onOpenChange:l,trigger:G,placement:H,popperOptions:h,className:F,style:E,isShowArrow:I,sameWidth:R,autoAdjustOverflow:J}=P,o=G===void 0 ? "hover":G,i=H===void 0 ? "top":H;let v;e[0]!==h ?(v=h===void 0 ?{}:h,e[0]=h,e[1]=v):v=e[1];const a=v,T=I===void 0||I,$=J===void 0||J,[n,Q]=ee(!1),w=L(null),t=L(null);let y;e[2]!==l ?(y=(c)=>{l?.(c),Q(c);},e[2]=l,e[3]=y):y=e[3];const r=y;let x;e[4]!==n||e[5]!==r||e[6]!==o ?(x=()=>{t.current&&(o==="hover" ?(t.current.onmouseenter=()=>r(!0),t.current.onmouseleave=()=>r(!1)):o==="click" ? t.current.onclick=()=>r(!n):o==="focus" ?(t.current.onfocus=()=>r(!0),t.current.onblur=()=>r(!1)):t.current.oncontextmenu=()=>r(!n));},e[4]=n,e[5]=r,e[6]=o,e[7]=x):x=e[7];const q=x;let b;e[8]===Symbol.for("react.memo_cache_sentinel")?(b=()=>{if(!t.current)return;const c=Array.from(t.current.children);if(c.length>1)throw new Error("Tooltip only support one child");t.current.style.width=c[0].getBoundingClientRect().width+"px";},e[8]=b):b=e[8];const U=b;let g;e[9]!==$||e[10]!==n||e[11]!==i||e[12]!==a||e[13]!==R ?(g=()=>{n&&t.current&&w.current ? A=te(t.current,w.current,{placement:i,modifiers:[{name:"offset",options:{offset:[0,6]}},R ?{name:"sameWidth",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn(c){const{state:d}=c;d.styles.popper.width=`${d.rects.reference.width}px`;},effect(c){const{state:d}=c;d.elements.popper.style.width=`${d.elements.reference.offsetWidth}px`;}}:{},$ ?{name:"flip",enabled:!0}:{}],...a}):A&&(A.destroy(),A=null,D&&D.remove(),D=null);},e[9]=$,e[10]=n,e[11]=i,e[12]=a,e[13]=R,e[14]=g):g=e[14];const B=g;let S,_,k,C,N,O,W,p,m,u,j;return e[15]!==r||e[16]!==o ?(S=()=>{o!=="click"&&o!=="contextmenu"||r(!1);},e[15]=r,e[16]=o,e[17]=S):S=e[17],e[18]===Symbol.for("react.memo_cache_sentinel")?(_=["click","contextmenu"],e[18]=_):_=e[18],e[19]!==l||e[20]!==o ?(k={event:_,deps:[o,l]},e[19]=l,e[20]=o,e[21]=k):k=e[21],Y(t,S,k),e[22]===Symbol.for("react.memo_cache_sentinel")?(C=()=>{U();},e[22]=C):C=e[22],e[23]!==s ?(N=[t,s],e[23]=s,e[24]=N):N=e[24],M(C,N),e[25]!==B||e[26]!==q ?(O=()=>{q(),B();},e[25]=B,e[26]=q,e[27]=O):O=e[27],e[28]!==n ?(W=[n,t,w],e[28]=n,e[29]=W):W=e[29],M(O,W),e[30]!==F||e[31]!==f||e[32]!==T||e[33]!==n||e[34]!==i||e[35]!==a||e[36]!==E ?(p=n&&K("div",{ref:w,style:E,className:Z("ono-tooltip-popper",F),"data-popper-placement":a.placement||i,children:[z("div",{children:f instanceof Function ? f():f}),T&&z("div",{className:"ono-tooltip-popper-arrow","data-popper-arrow":!0})]}),e[30]=F,e[31]=f,e[32]=T,e[33]=n,e[34]=i,e[35]=a,e[36]=E,e[37]=p):p=e[37],e[38]!==s ?(m=s instanceof Function ? s():s,e[38]=s,e[39]=m):m=e[39],e[40]!==m ?(u=z("div",{ref:t,children:m}),e[40]=m,e[41]=u):u=e[41],e[42]!==p||e[43]!==u ?(j=K(V,{children:[p,u]}),e[42]=p,e[43]=u,e[44]=j):j=e[44],j;};export{le as T};
@@ -0,0 +1 @@
1
+ import{jsx as x}from "react/jsx-runtime";import{throttle as $,useEventListener as k}from "./index.js";import{useState as L,useRef as E,useEffect as I}from "react";import{L as B}from "./List-ClfyFOXz.js";const K=({containerClassName:z,dataSource:c,containerStyle:w={},onEndCallback:p,refreshSpeed:N=50,wrapperClassName:b,wrapperStyle:A={},estimatedSize:g=35,updateDataSourceScroll2Top:C,direction:l="vertical"})=>{const [d,H]=L({viewSize:0,startIndex:0,listSize:0,renderCount:0,prevLen:0}),[a,M]=L([]),o=typeof g=="number" ? g:g(),T=Math.min(c.length,d.startIndex+d.renderCount),m=d.startIndex>0 ? a[d.startIndex-1]?.end:0,W=x(B,{list:c.slice(d.startIndex,T),children:({id:r,data:i})=>x("li",{"data-virtual-id":r,style:l==="vertical" ?{width:"100%"}:{height:"100%"},children:i},r)}),j={display:"flex",listStyle:"none",flexDirection:l==="vertical" ? "column":"row",height:l==="vertical" ? d.listSize-m+"px":"100%",width:l==="vertical" ? "auto":d.listSize-m+"px",translate:l==="vertical" ? `0 ${m}px 0`:`${m}px 0 0`},h=E(null),u=E(null),v=(r)=>H((i)=>({...i,...r})),D=$(()=>{const{scrollTop:r,clientHeight:i,scrollHeight:s,scrollLeft:n,clientWidth:t,scrollWidth:e}=h.current,f=l==="vertical" ? s-i-r:e-t-n;v({startIndex:R(a,l==="vertical" ? r:n)}),(l==="vertical" ? r===o/2:n===o/2)&&v({startIndex:0}),f<=20&&p&&p();},N),R=(r,i)=>{let s=0,n=r.length-1,t=-1;for(;s<=n;){const e=s+Math.floor((n-s)/2),f=r[e].end;if(f===i)return e+1;f<i ? s=e+1:((t===-1||t>e)&&(t=e),n=e-1);}return t;};return k("scroll",D,{target:h.current,deps:[a,l]}),I(()=>{(()=>{if(!h.current)return;const r=(l==="vertical" ? h.current.offsetHeight:h.current.offsetWidth)||0;v({viewSize:r,renderCount:Math.ceil(r/o)+1});})();},[h,l]),I(()=>{c.length&&u&&(()=>{const r=[],i=c.length-d.prevLen,s=i>0 ? a.length:0,n=s>0 ? a[s-1].end:0;for(let t=0;t<(i>0 ? i:c.length);t++){const e=c[(i>0 ? d.prevLen:0)+t];r.push({index:e.id,size:o,start:n ? n+t*o:e.id*o,end:n ? n+(t+1)*o:(e.id+1)*o,dSize:0});}M((t)=>[...i>0 ? t:[],...r]),v({prevLen:c.length}),C&&h.current?.scrollTo(0,0);})();},[u,c,C]),I(()=>{(()=>{if(!u.current||a.length===0)return;const r=Array.from(u.current.childNodes);if(!r.length)return;r.forEach((t)=>{const e=t.getBoundingClientRect(),f=+t.getAttribute("data-virtual-id"),S=a[f],y=S.size-(l==="vertical" ? e.height:e.width);y&&(S.size=l==="vertical" ? e.height:e.width,S.end=S.end-y,S.dSize=y);});const i=+r[0].getAttribute("data-virtual-id"),s=a.length;let n=a[i].dSize;a[i].dSize=0;for(let t=i+1;t<s;t++){const e=a[t];e.start=a[t-1].end,e.end=e.end-n,e.dSize&&(n+=e.dSize,e.dSize=0);}v({listSize:a[s-1].end});})();},[u,a,d.startIndex,l]),x("div",{ref:h,className:z,style:{width:"100%",height:"100%",overflow:"auto",...w},children:x("ul",{ref:u,className:b,style:{...j,...A},children:W})});},O=(z,c)=>z.map((w,p)=>({id:p,data:c(w,p)}));export{K as E,O as c};
@@ -0,0 +1 @@
1
+ import{jsxs as R,jsx as m}from "react/jsx-runtime";import{throttle as k,useEventListener as B,chainClassNames as G}from "./index.js";import{useState as v,useRef as L,useEffect as $}from "react";import{L as I}from "./List-ClfyFOXz.js";const V=({options:t,pageSize:u,children:j,request:A,reloadData:o,className:S,style:H,updateData:N,loading:l=!0,bottomThreshold:O=50})=>{const [a,h]=v({page:1,reloadData:o,loading:!1,isFinish:!1,gap:typeof t=="number" ? 0:t.gap,imageWidth:typeof t=="number" ? t:0,columns:typeof t=="number" ? 0:t.columns,imageList:[]}),[f,D]=v([]),[x,E]=v([]),y=L(null),g=L(null),d=L(null),p=(i)=>h((e)=>({...e,...i})),w=async(i,e)=>{const s=o&&a.reloadData!==o;if(a.isFinish)return;p({loading:!0});const n=await A(i,e);q(n),p({isFinish:!n.length,imageList:s ? [...n]:[...a.imageList,...n],page:i+1,loading:!1});},q=(i)=>h((e)=>{const s=o&&a.reloadData!==o,n=s ? []:[...x],c=s ? Array(e.columns).fill(0):[...JSON.stringify(f)!=="[]" ? f:Array(e.columns).fill(0)];return i.forEach((T)=>{const r=((W)=>{let b=0,z=0;return b=W.indexOf(Math.min(...W)),z=W[b],{index:b,height:z};})(c),J=Math.floor(T.height*e.imageWidth/T.width);n.push({x:r.index%e.columns!==0 ? r.index*e.imageWidth+e.gap*r.index:r.index*e.imageWidth,y:r.height}),c[r.index]+=J+e.gap,D(c);}),E(n),e;}),F=()=>{if(!d.current)return;const i=d.current.clientWidth;let e=0,s=a.page;if(o&&a.reloadData!==o&&(h({page:1,reloadData:o,loading:!1,isFinish:!1,gap:typeof t=="number" ? 0:t.gap,imageWidth:typeof t=="number" ? t:0,columns:typeof t=="number" ? 0:t.columns,imageList:[]}),D([]),E([]),s=1),typeof t=="number"){const n=Math.floor(i/a.imageWidth);e=n-1;const c=e ?(i-n*a.imageWidth)/e:0;p({columns:n,gap:c});}else{e=a.columns-1;const n=(i-e*a.gap)/a.columns;p({imageWidth:n});}w(s,u);},M=()=>{y.current&&clearTimeout(y.current),y.current=setTimeout(F,50);},C=k(()=>{const{scrollTop:i,clientHeight:e,scrollHeight:s}=g.current;s-e-i>O||!a.loading&&w(a.page,u);},50);return B("scroll",C,{target:g.current,deps:[a.loading,a.page]}),$(()=>(F(),window.addEventListener("resize",M),()=>{window.removeEventListener("resize",M);}),[d,o]),$(()=>{N&&w(a.page,u);},[N,a.loading,a.page,g.current]),R("div",{className:"ono-waterfall-container",children:[m("div",{ref:g,className:G(S,"ono-waterfall-content"),style:H,children:m("div",{ref:d,className:"ono-waterfall-wrapper",style:{height:Math.max(...f)-a.gap+"px"},children:m(I,{list:a.imageList,children:(i,e)=>m("div",{className:"ono-waterfall-item",style:{width:`${a.imageWidth}px`,translate:`${x[e].x}px ${x[e].y}px`},children:j(i,e)},i.id)})})}),a.loading&&(typeof l=="function" ? l():l&&typeof l=="boolean" ? m("div",{className:"ono-waterfall-loading",children:"loading..."}):l)]});};export{V as W};
@@ -0,0 +1 @@
1
+ var R="top",N="bottom",I="right",T="left",wt="auto",ct=[R,N,I,T],tt="start",ft="end",Zt="viewport",ot="popper",Ut=ct.reduce(function(e,t){return e.concat([t+"-"+tt,t+"-"+ft]);},[]),Xt=[].concat(ct,[wt]).reduce(function(e,t){return e.concat([t,t+"-"+tt,t+"-"+ft]);},[]),de=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function K(e){return e ?(e.nodeName||"").toLowerCase():null;}function S(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window;}return e;}function Z(e){return e instanceof S(e).Element||e instanceof Element;}function q(e){return e instanceof S(e).HTMLElement||e instanceof HTMLElement;}function Dt(e){return typeof ShadowRoot<"u"&&(e instanceof S(e).ShadowRoot||e instanceof ShadowRoot);}const he={name:"applyStyles",enabled:!0,phase:"write",fn:function(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},a=t.attributes[n]||{},o=t.elements[n];q(o)&&K(o)&&(Object.assign(o.style,r),Object.keys(a).forEach(function(s){var i=a[s];i===!1 ? o.removeAttribute(s):o.setAttribute(s,i===!0 ? "":i);}));});},effect:function(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var a=t.elements[r],o=t.attributes[r]||{},s=Object.keys(t.styles.hasOwnProperty(r)? t.styles[r]:n[r]).reduce(function(i,c){return i[c]="",i;},{});q(a)&&K(a)&&(Object.assign(a.style,s),Object.keys(o).forEach(function(i){a.removeAttribute(i);}));});};},requires:["computeStyles"]};function Y(e){return e.split("-")[0];}var X=Math.max,vt=Math.min,et=Math.round;function Ot(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)? e.brands.map(function(t){return t.brand+"/"+t.version;}).join(" "):navigator.userAgent;}function _t(){return!/^((?!chrome|android).)*safari/i.test(Ot());}function nt(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),a=1,o=1;t&&q(e)&&(a=e.offsetWidth>0&&et(r.width)/e.offsetWidth||1,o=e.offsetHeight>0&&et(r.height)/e.offsetHeight||1);var s=(Z(e)? S(e):window).visualViewport,i=!_t()&&n,c=(r.left+(i&&s ? s.offsetLeft:0))/a,p=(r.top+(i&&s ? s.offsetTop:0))/o,u=r.width/a,f=r.height/o;return{width:u,height:f,top:p,right:c+u,bottom:p+f,left:c,x:c,y:p};}function At(e){var t=nt(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r};}function te(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&Dt(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host;}while(r);}return!1;}function Q(e){return S(e).getComputedStyle(e);}function me(e){return ["table","td","th"].indexOf(K(e))>=0;}function G(e){return((Z(e)? e.ownerDocument:e.document)||window.document).documentElement;}function gt(e){return K(e)==="html" ? e:e.assignedSlot||e.parentNode||(Dt(e)? e.host:null)||G(e);}function zt(e){return q(e)&&Q(e).position!=="fixed" ? e.offsetParent:null;}function pt(e){for(var t=S(e),n=zt(e);n&&me(n)&&Q(n).position==="static";)n=zt(n);return n&&(K(n)==="html"||K(n)==="body"&&Q(n).position==="static")? t:n||(function(r){var a=/firefox/i.test(Ot());if(/Trident/i.test(Ot())&&q(r)&&Q(r).position==="fixed")return null;var o=gt(r);for(Dt(o)&&(o=o.host);q(o)&&["html","body"].indexOf(K(o))<0;){var s=Q(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||a&&s.willChange==="filter"||a&&s.filter&&s.filter!=="none")return o;o=o.parentNode;}return null;})(e)||t;}function Lt(e){return ["top","bottom"].indexOf(e)>=0 ? "x":"y";}function it(e,t,n){return X(e,vt(t,n));}function ee(e){return Object.assign({},{top:0,right:0,bottom:0,left:0},e);}function ne(e,t){return t.reduce(function(n,r){return n[r]=e,n;},{});}const ve={name:"arrow",enabled:!0,phase:"main",fn:function(e){var t,n=e.state,r=e.name,a=e.options,o=n.elements.arrow,s=n.modifiersData.popperOffsets,i=Y(n.placement),c=Lt(i),p=[T,I].indexOf(i)>=0 ? "height":"width";if(o&&s){var u=(function(E,O){return ee(typeof(E=typeof E=="function" ? E(Object.assign({},O.rects,{placement:O.placement})):E)!="number" ? E:ne(E,ct));})(a.padding,n),f=At(o),y=c==="y" ? R:T,d=c==="y" ? N:I,m=n.rects.reference[p]+n.rects.reference[c]-s[c]-n.rects.popper[p],g=s[c]-n.rects.reference[c],h=pt(o),A=h ? c==="y" ? h.clientHeight||0:h.clientWidth||0:0,D=m/2-g/2,b=u[y],x=A-f[p]-u[d],l=A/2-f[p]/2+D,v=it(b,l,x),w=c;n.modifiersData[r]=((t={})[w]=v,t.centerOffset=v-l,t);}},effect:function(e){var t=e.state,n=e.options.element,r=n===void 0 ? "[data-popper-arrow]":n;r!=null&&(typeof r!="string"||(r=t.elements.popper.querySelector(r)))&&te(t.elements.popper,r)&&(t.elements.arrow=r);},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function rt(e){return e.split("-")[1];}var ge={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Ft(e){var t,n=e.popper,r=e.popperRect,a=e.placement,o=e.variation,s=e.offsets,i=e.position,c=e.gpuAcceleration,p=e.adaptive,u=e.roundOffsets,f=e.isFixed,y=s.x,d=y===void 0 ? 0:y,m=s.y,g=m===void 0 ? 0:m,h=typeof u=="function" ? u({x:d,y:g}):{x:d,y:g};d=h.x,g=h.y;var A=s.hasOwnProperty("x"),D=s.hasOwnProperty("y"),b=T,x=R,l=window;if(p){var v=pt(n),w="clientHeight",E="clientWidth";v===S(n)&&Q(v=G(n)).position!=="static"&&i==="absolute"&&(w="scrollHeight",E="scrollWidth"),(a===R||(a===T||a===I)&&o===ft)&&(x=N,g-=(f&&v===l&&l.visualViewport ? l.visualViewport.height:v[w])-r.height,g*=c ? 1:-1),a!==T&&(a!==R&&a!==N||o!==ft)||(b=I,d-=(f&&v===l&&l.visualViewport ? l.visualViewport.width:v[E])-r.width,d*=c ? 1:-1);}var O,W=Object.assign({position:i},p&&ge),H=u===!0 ?(function(U,M){var P=U.x,V=U.y,L=M.devicePixelRatio||1;return{x:et(P*L)/L||0,y:et(V*L)/L||0};})({x:d,y:g},S(n)):{x:d,y:g};return d=H.x,g=H.y,c ? Object.assign({},W,((O={})[x]=D ? "0":"",O[b]=A ? "0":"",O.transform=(l.devicePixelRatio||1)<=1 ? "translate("+d+"px,"+g+"px)":"translate3d("+d+"px,"+g+"px,0)",O)):Object.assign({},W,((t={})[x]=D ? g+"px":"",t[b]=A ? d+"px":"",t.transform="",t));}var ht={passive:!0},ye={left:"right",right:"left",bottom:"top",top:"bottom"};function mt(e){return e.replace(/left|right|bottom|top/g,function(t){return ye[t];});}var be={start:"end",end:"start"};function Yt(e){return e.replace(/start|end/g,function(t){return be[t];});}function Wt(e){var t=S(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset};}function Et(e){return nt(G(e)).left+Wt(e).scrollLeft;}function kt(e){var t=Q(e),n=t.overflow,r=t.overflowX,a=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+a+r);}function re(e){return ["html","body","#document"].indexOf(K(e))>=0 ? e.ownerDocument.body:q(e)&&kt(e)? e:re(gt(e));}function at(e,t){var n;t===void 0&&(t=[]);var r=re(e),a=r===((n=e.ownerDocument)==null ? void 0:n.body),o=S(r),s=a ? [o].concat(o.visualViewport||[],kt(r)? r:[]):r,i=t.concat(s);return a ? i:i.concat(at(gt(s)));}function jt(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height});}function Kt(e,t,n){return t===Zt ? jt((function(r,a){var o=S(r),s=G(r),i=o.visualViewport,c=s.clientWidth,p=s.clientHeight,u=0,f=0;if(i){c=i.width,p=i.height;var y=_t();(y||!y&&a==="fixed")&&(u=i.offsetLeft,f=i.offsetTop);}return{width:c,height:p,x:u+Et(r),y:f};})(e,n)):Z(t)?(function(r,a){var o=nt(r,!1,a==="fixed");return o.top=o.top+r.clientTop,o.left=o.left+r.clientLeft,o.bottom=o.top+r.clientHeight,o.right=o.left+r.clientWidth,o.width=r.clientWidth,o.height=r.clientHeight,o.x=o.left,o.y=o.top,o;})(t,n):jt((function(r){var a,o=G(r),s=Wt(r),i=(a=r.ownerDocument)==null ? void 0:a.body,c=X(o.scrollWidth,o.clientWidth,i ? i.scrollWidth:0,i ? i.clientWidth:0),p=X(o.scrollHeight,o.clientHeight,i ? i.scrollHeight:0,i ? i.clientHeight:0),u=-s.scrollLeft+Et(r),f=-s.scrollTop;return Q(i||o).direction==="rtl"&&(u+=X(o.clientWidth,i ? i.clientWidth:0)-c),{width:c,height:p,x:u,y:f};})(G(e)));}function oe(e){var t,n=e.reference,r=e.element,a=e.placement,o=a ? Y(a):null,s=a ? rt(a):null,i=n.x+n.width/2-r.width/2,c=n.y+n.height/2-r.height/2;switch(o){case R:t={x:i,y:n.y-r.height};break;case N:t={x:i,y:n.y+n.height};break;case I:t={x:n.x+n.width,y:c};break;case T:t={x:n.x-r.width,y:c};break;default:t={x:n.x,y:n.y};}var p=o ? Lt(o):null;if(p!=null){var u=p==="y" ? "height":"width";switch(s){case tt:t[p]=t[p]-(n[u]/2-r[u]/2);break;case ft:t[p]=t[p]+(n[u]/2-r[u]/2);}}return t;}function st(e,t){t===void 0&&(t={});var n=t,r=n.placement,a=r===void 0 ? e.placement:r,o=n.strategy,s=o===void 0 ? e.strategy:o,i=n.boundary,c=i===void 0 ? "clippingParents":i,p=n.rootBoundary,u=p===void 0 ? Zt:p,f=n.elementContext,y=f===void 0 ? ot:f,d=n.altBoundary,m=d!==void 0&&d,g=n.padding,h=g===void 0 ? 0:g,A=ee(typeof h!="number" ? h:ne(h,ct)),D=y===ot ? "reference":ot,b=e.rects.popper,x=e.elements[m ? D:y],l=(function(M,P,V,L){var z=P==="clippingParents" ?(function(j){var B=at(gt(j)),C=["absolute","fixed"].indexOf(Q(j).position)>=0&&q(j)? pt(j):j;return Z(C)? B.filter(function($){return Z($)&&te($,C)&&K($)!=="body";}):[];})(M):[].concat(P),F=[].concat(z,[V]),_=F[0],k=F.reduce(function(j,B){var C=Kt(M,B,L);return j.top=X(C.top,j.top),j.right=vt(C.right,j.right),j.bottom=vt(C.bottom,j.bottom),j.left=X(C.left,j.left),j;},Kt(M,_,L));return k.width=k.right-k.left,k.height=k.bottom-k.top,k.x=k.left,k.y=k.top,k;})(Z(x)? x:x.contextElement||G(e.elements.popper),c,u,s),v=nt(e.elements.reference),w=oe({reference:v,element:b,placement:a}),E=jt(Object.assign({},b,w)),O=y===ot ? E:v,W={top:l.top-O.top+A.top,bottom:O.bottom-l.bottom+A.bottom,left:l.left-O.left+A.left,right:O.right-l.right+A.right},H=e.modifiersData.offset;if(y===ot&&H){var U=H[a];Object.keys(W).forEach(function(M){var P=[I,N].indexOf(M)>=0 ? 1:-1,V=[R,N].indexOf(M)>=0 ? "y":"x";W[M]+=U[V]*P;});}return W;}function xe(e,t){t===void 0&&(t={});var n=t,r=n.placement,a=n.boundary,o=n.rootBoundary,s=n.padding,i=n.flipVariations,c=n.allowedAutoPlacements,p=c===void 0 ? Xt:c,u=rt(r),f=u ? i ? Ut:Ut.filter(function(m){return rt(m)===u;}):ct,y=f.filter(function(m){return p.indexOf(m)>=0;});y.length===0&&(y=f);var d=y.reduce(function(m,g){return m[g]=st(e,{placement:g,boundary:a,rootBoundary:o,padding:s})[Y(g)],m;},{});return Object.keys(d).sort(function(m,g){return d[m]-d[g];});}const we={name:"flip",enabled:!0,phase:"main",fn:function(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var a=n.mainAxis,o=a===void 0||a,s=n.altAxis,i=s===void 0||s,c=n.fallbackPlacements,p=n.padding,u=n.boundary,f=n.rootBoundary,y=n.altBoundary,d=n.flipVariations,m=d===void 0||d,g=n.allowedAutoPlacements,h=t.options.placement,A=Y(h),D=c||(A!==h&&m ?(function(j){if(Y(j)===wt)return [];var B=mt(j);return [Yt(j),B,Yt(B)];})(h):[mt(h)]),b=[h].concat(D).reduce(function(j,B){return j.concat(Y(B)===wt ? xe(t,{placement:B,boundary:u,rootBoundary:f,padding:p,flipVariations:m,allowedAutoPlacements:g}):B);},[]),x=t.rects.reference,l=t.rects.popper,v=new Map(),w=!0,E=b[0],O=0;O<b.length;O++){var W=b[O],H=Y(W),U=rt(W)===tt,M=[R,N].indexOf(H)>=0,P=M ? "width":"height",V=st(t,{placement:W,boundary:u,rootBoundary:f,altBoundary:y,padding:p}),L=M ? U ? I:T:U ? N:R;x[P]>l[P]&&(L=mt(L));var z=mt(L),F=[];if(o&&F.push(V[H]<=0),i&&F.push(V[L]<=0,V[z]<=0),F.every(function(j){return j;})){E=W,w=!1;break;}v.set(W,F);}if(w)for(var _=function(j){var B=b.find(function(C){var $=v.get(C);if($)return $.slice(0,j).every(function(ut){return ut;});});if(B)return E=B,"break";},k=m ? 3:1;k>0&&_(k)!=="break";k--);t.placement!==E&&(t.modifiersData[r]._skip=!0,t.placement=E,t.reset=!0);}},requiresIfExists:["offset"],data:{_skip:!1}};function Qt(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x};}function $t(e){return [R,I,N,T].some(function(t){return e[t]>=0;});}function Oe(e,t,n){n===void 0&&(n=!1);var r,a,o=q(t),s=q(t)&&(function(f){var y=f.getBoundingClientRect(),d=et(y.width)/f.offsetWidth||1,m=et(y.height)/f.offsetHeight||1;return d!==1||m!==1;})(t),i=G(t),c=nt(e,s,n),p={scrollLeft:0,scrollTop:0},u={x:0,y:0};return(o||!o&&!n)&&((K(t)!=="body"||kt(i))&&(p=(r=t)!==S(r)&&q(r)?{scrollLeft:(a=r).scrollLeft,scrollTop:a.scrollTop}:Wt(r)),q(t)?((u=nt(t,!0)).x+=t.clientLeft,u.y+=t.clientTop):i&&(u.x=Et(i))),{x:c.left+p.scrollLeft-u.x,y:c.top+p.scrollTop-u.y,width:c.width,height:c.height};}function Ee(e){var t=new Map(),n=new Set(),r=[];function a(o){n.add(o.name),[].concat(o.requires||[],o.requiresIfExists||[]).forEach(function(s){if(!n.has(s)){var i=t.get(s);i&&a(i);}}),r.push(o);}return e.forEach(function(o){t.set(o.name,o);}),e.forEach(function(o){n.has(o.name)||a(o);}),r;}var Gt={placement:"bottom",modifiers:[],strategy:"absolute"};function Jt(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return!t.some(function(r){return!(r&&typeof r.getBoundingClientRect=="function");});}function je(e){e===void 0&&(e={});var t=e,n=t.defaultModifiers,r=n===void 0 ? []:n,a=t.defaultOptions,o=a===void 0 ? Gt:a;return function(s,i,c){c===void 0&&(c=o);var p,u,f={placement:"bottom",orderedModifiers:[],options:Object.assign({},Gt,o),modifiersData:{},elements:{reference:s,popper:i},attributes:{},styles:{}},y=[],d=!1,m={state:f,setOptions:function(h){var A=typeof h=="function" ? h(f.options):h;g(),f.options=Object.assign({},o,f.options,A),f.scrollParents={reference:Z(s)? at(s):s.contextElement ? at(s.contextElement):[],popper:at(i)};var D,b,x=(function(l){var v=Ee(l);return de.reduce(function(w,E){return w.concat(v.filter(function(O){return O.phase===E;}));},[]);})((D=[].concat(r,f.options.modifiers),b=D.reduce(function(l,v){var w=l[v.name];return l[v.name]=w ? Object.assign({},w,v,{options:Object.assign({},w.options,v.options),data:Object.assign({},w.data,v.data)}):v,l;},{}),Object.keys(b).map(function(l){return b[l];})));return f.orderedModifiers=x.filter(function(l){return l.enabled;}),f.orderedModifiers.forEach(function(l){var v=l.name,w=l.options,E=w===void 0 ?{}:w,O=l.effect;if(typeof O=="function"){var W=O({state:f,name:v,instance:m,options:E});y.push(W||function(){});}}),m.update();},forceUpdate:function(){if(!d){var h=f.elements,A=h.reference,D=h.popper;if(Jt(A,D)){f.rects={reference:Oe(A,pt(D),f.options.strategy==="fixed"),popper:At(D)},f.reset=!1,f.placement=f.options.placement,f.orderedModifiers.forEach(function(O){return f.modifiersData[O.name]=Object.assign({},O.data);});for(var b=0;b<f.orderedModifiers.length;b++)if(f.reset!==!0){var x=f.orderedModifiers[b],l=x.fn,v=x.options,w=v===void 0 ?{}:v,E=x.name;typeof l=="function"&&(f=l({state:f,options:w,name:E,instance:m})||f);}else f.reset=!1,b=-1;}}},update:(p=function(){return new Promise(function(h){m.forceUpdate(),h(f);});},function(){return u||(u=new Promise(function(h){Promise.resolve().then(function(){u=void 0,h(p());});})),u;}),destroy:function(){g(),d=!0;}};if(!Jt(s,i))return m;function g(){y.forEach(function(h){return h();}),y=[];}return m.setOptions(c).then(function(h){!d&&c.onFirstUpdate&&c.onFirstUpdate(h);}),m;};}var De=je({defaultModifiers:[{name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(e){var t=e.state,n=e.instance,r=e.options,a=r.scroll,o=a===void 0||a,s=r.resize,i=s===void 0||s,c=S(t.elements.popper),p=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&p.forEach(function(u){u.addEventListener("scroll",n.update,ht);}),i&&c.addEventListener("resize",n.update,ht),function(){o&&p.forEach(function(u){u.removeEventListener("scroll",n.update,ht);}),i&&c.removeEventListener("resize",n.update,ht);};},data:{}},{name:"popperOffsets",enabled:!0,phase:"read",fn:function(e){var t=e.state,n=e.name;t.modifiersData[n]=oe({reference:t.rects.reference,element:t.rects.popper,placement:t.placement});},data:{}},{name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(e){var t=e.state,n=e.options,r=n.gpuAcceleration,a=r===void 0||r,o=n.adaptive,s=o===void 0||o,i=n.roundOffsets,c=i===void 0||i,p={placement:Y(t.placement),variation:rt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:a,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,Ft(Object.assign({},p,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:s,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,Ft(Object.assign({},p,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement});},data:{}},he,{name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(e){var t=e.state,n=e.options,r=e.name,a=n.offset,o=a===void 0 ? [0,0]:a,s=Xt.reduce(function(u,f){return u[f]=(function(y,d,m){var g=Y(y),h=[T,R].indexOf(g)>=0 ?-1:1,A=typeof m=="function" ? m(Object.assign({},d,{placement:y})):m,D=A[0],b=A[1];return D=D||0,b=(b||0)*h,[T,I].indexOf(g)>=0 ?{x:b,y:D}:{x:D,y:b};})(f,t.rects,o),u;},{}),i=s[t.placement],c=i.x,p=i.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=p),t.modifiersData[r]=s;}},we,{name:"preventOverflow",enabled:!0,phase:"main",fn:function(e){var t=e.state,n=e.options,r=e.name,a=n.mainAxis,o=a===void 0||a,s=n.altAxis,i=s!==void 0&&s,c=n.boundary,p=n.rootBoundary,u=n.altBoundary,f=n.padding,y=n.tether,d=y===void 0||y,m=n.tetherOffset,g=m===void 0 ? 0:m,h=st(t,{boundary:c,rootBoundary:p,padding:f,altBoundary:u}),A=Y(t.placement),D=rt(t.placement),b=!D,x=Lt(A),l=x==="x" ? "y":"x",v=t.modifiersData.popperOffsets,w=t.rects.reference,E=t.rects.popper,O=typeof g=="function" ? g(Object.assign({},t.rects,{placement:t.placement})):g,W=typeof O=="number" ?{mainAxis:O,altAxis:O}:Object.assign({mainAxis:0,altAxis:0},O),H=t.modifiersData.offset ? t.modifiersData.offset[t.placement]:null,U={x:0,y:0};if(v){if(o){var M,P=x==="y" ? R:T,V=x==="y" ? N:I,L=x==="y" ? "height":"width",z=v[x],F=z+h[P],_=z-h[V],k=d ?-E[L]/2:0,j=D===tt ? w[L]:E[L],B=D===tt ?-E[L]:-w[L],C=t.elements.arrow,$=d&&C ? At(C):{width:0,height:0},ut=t.modifiersData["arrow#persistent"] ? t.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},Mt=ut[P],Bt=ut[V],lt=it(0,w[L],$[L]),ie=b ? w[L]/2-k-lt-Mt-W.mainAxis:j-lt-Mt-W.mainAxis,ae=b ?-w[L]/2+k+lt+Bt+W.mainAxis:B+lt+Bt+W.mainAxis,yt=t.elements.arrow&&pt(t.elements.arrow),se=yt ? x==="y" ? yt.clientTop||0:yt.clientLeft||0:0,Tt=(M=H?.[x])!=null ? M:0,fe=z+ae-Tt,Rt=it(d ? vt(F,z+ie-Tt-se):F,z,d ? X(_,fe):_);v[x]=Rt,U[x]=Rt-z;}if(i){var Ht,ce=x==="x" ? R:T,pe=x==="x" ? N:I,J=v[l],dt=l==="y" ? "height":"width",St=J+h[ce],Pt=J-h[pe],bt=[R,T].indexOf(A)!==-1,Vt=(Ht=H?.[l])!=null ? Ht:0,Ct=bt ? St:J-w[dt]-E[dt]-Vt+W.altAxis,qt=bt ? J+w[dt]+E[dt]-Vt-W.altAxis:Pt,It=d&&bt ?(function(ue,le,xt){var Nt=it(ue,le,xt);return Nt>xt ? xt:Nt;})(Ct,J,qt):it(d ? Ct:St,J,d ? qt:Pt);v[l]=It,U[l]=It-J;}t.modifiersData[r]=U;}},requiresIfExists:["offset"]},ve,{name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(e){var t=e.state,n=e.name,r=t.rects.reference,a=t.rects.popper,o=t.modifiersData.preventOverflow,s=st(t,{elementContext:"reference"}),i=st(t,{altBoundary:!0}),c=Qt(s,r),p=Qt(i,a,o),u=$t(c),f=$t(p);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:p,isReferenceHidden:u,hasPopperEscaped:f},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":f});}}]});export{De as c};
package/dist/es/index.js CHANGED
@@ -1 +1 @@
1
- import{u as e}from "./useClickOutSide.tsx-Drp6uYap.js";import{u as a}from "./useCountdown.tsx-BHrpYPuf.js";import{u as m}from "./useEventListener.tsx-BDtH_FiI.js";import{u as f}from "./useGetElementSize.tsx-CYGNJaFz.js";import{u as i}from "./useKeyPress.tsx-ClBLUMui.js";import{u as n}from "./useMouseClick.tsx-nz5umn7V.js";import{u as c}from "./useQuery.tsx-FzGWYq50.js";import{u as d}from "./useTheme.tsx-C7aAN-Zj.js";import{u as b}from "./useThemePro.tsx-MwfY4tCX.js";import{c as T}from "./clearAsyncContagion.ts-DseR8G-S.js";import{g as v}from "./getBrowserInfo.ts-CFS4Oz41.js";import{a as P}from "./adjustColor.ts-D1ttRO_o.js";import{a as F}from "./adjustingColors.ts-CQV_S12M.js";import{f as A}from "./formatColor.ts-D_Sws4M1.js";import{g as I}from "./getColorType.ts-B5Qax_03.js";import{g as k}from "./getContrastColor.ts-vmwZYf4O.js";import{g as L}from "./grayColor.ts-BeAK97Od.js";import{h as N}from "./hex2hsl.ts-fQ072W3P.js";import{h as z}from "./hex2hsv.ts-Bewjcepy.js";import{h as V}from "./hex2rgb.ts-tP-M30oZ.js";import{h as j}from "./hex3To6.ts-epLJiP-G.js";import{h as G}from "./hsl2hex.ts-BILOsbJk.js";import{h as Y}from "./hsl2rgb.ts-DCdzknv1.js";import{h as K}from "./hsv2hex.ts-U8Md-VPN.js";import{h as J}from "./hsv2rgb.ts-C4AdDfKf.js";import{i as _}from "./isValidColor.ts-oChVkAT9.js";import{r as oo}from "./randomColor.ts-BiDP87Yi.js";import{r as eo}from "./rgb2hex.ts-itJEWSC0.js";import{r as ao}from "./rgb2hsl.ts-BmthoL_h.js";import{r as mo}from "./rgb2hsv.ts-o8o8uIwc.js";import{r as fo}from "./rgb2rgba.ts-ZXQCbTkT.js";import{a as io}from "./addCommasToNumber.ts-Bc5ZX_HW.js";import{a as no}from "./addEventWithOriginHandler.ts-CBP4faL-.js";import{c as co}from "./calculateAspectRatio.ts-DLTMZ6rT.js";import{c as ho}from "./chainClassNames.ts-B9vmfsc1.js";import{c as Co}from "./checkDeviceIsMobile.ts-D_9fa1Z1.js";import{c as So}from "./checkStatusCode.ts-CeS5vbbx.js";import{c as yo}from "./controlTheScrollbarScrolling.ts-WYW8laxj.js";import{c as Bo}from "./copy2Clipboard.ts-D-Ux5BRc.js";import{d as Oo}from "./debounce.ts-DtQl9QX-.js";import{d as Do}from "./deepCopy.ts-DZSM2TJ5.js";import{e as Eo}from "./ellipsisString.ts-CEHck07f.js";import{g as wo}from "./gcd.ts-BCWGat6T.js";import{g as Mo}from "./getAllTheNumbers.ts-DaNxVd8a.js";import{g as Ro}from "./getElementCenterPosition.ts-CpWYej6j.js";import{g as Wo}from "./getImageSIze.ts-BKCUZEmG.js";import{g as Zo}from "./getPointDistance.ts-oQIzWYT7.js";import{g as qo}from "./getURLSearchParams.ts-CdkTE_NB.js";import{i as Qo}from "./isPureNumber.ts-UvzCfFTt.js";import{m as Ho}from "./mediaAutoplayPolicies.ts-h8T8o7DV.js";import{p as Uo}from "./padZero.ts-BTMKlRWN.js";import{p as Xo}from "./parseQuery.ts-rxlqkZEE.js";import{p as $o}from "./passwordStrength.ts-BSVicol-.js";import{p as rr}from "./pick.ts-CVf1DuK1.js";import{p as tr}from "./printStr.ts-Nd8JNyzN.js";import{p as sr}from "./pureNumber.ts-LjeTI9RC.js";import{q as pr}from "./quickSort.ts-CTYjJtIg.js";import{r as xr}from "./rafTimeout.ts-atBwwlgC.js";import{r as lr}from "./randomString.ts-DpWnx0Kc.js";import{r as ur}from "./removeTag.ts-K8ovHu9Z.js";import{s as gr}from "./safeCapitalizeWord.ts-CBBsQk5s.js";import{s as hr}from "./singleton.ts-BxAjTJl8.js";import{t as Cr}from "./throttle.ts-D_EqcNzV.js";import{b as Sr}from "./base64ToBlob.ts-BpYnI1_k.js";import{b as yr}from "./base64ToFile.ts-B526yxVq.js";import{b as Br}from "./blobToBase64.ts-CJROQ7nO.js";import{b as Or}from "./blobToFile.ts-CjkxPmEw.js";import{d as Dr}from "./downloadFile.ts-C5v3gvXJ.js";import{f as Er}from "./fileToBase64.ts-LDhPtYZ8.js";import{f as wr}from "./fileToBlob.ts-C4Y1I82u.js";import{f as Mr}from "./formatFileSize.ts-CoUwKtCA.js";import{g as Rr}from "./getFileName.ts-CAdDeTqT.js";import{g as Wr}from "./getFileSuffix.ts-RBCEexOt.js";import{u as Zr}from "./urlToBase64.ts-DzO1pwIZ.js";import{u as qr}from "./urlToBlob.ts-DmOp0wbt.js";import{u as Qr}from "./urlToFile.ts-KrTFcI-e.js";import{c as Hr}from "./createIntersectionObserver.ts-CPwdNz7M.js";import{e as Ur}from "./elementIsInViewport.ts-DnBd8TjE.js";import{d as Xr}from "./distinguishPlatform.ts-BITl3t1o.js";import{d as $r}from "./distinguishPlatformDelay.ts-DupUPv6F.js";import{c as re}from "./convertSecondToOtherTime.ts-BlSK8Hsn.js";import{d as te}from "./dayOfYear.ts-FVQlJIhw.js";import{f as se}from "./formatSecond.ts-Dc436DN-.js";import{f as pe}from "./formatTime.ts-BY0hrdXI.js";import{l as xe}from "./localFormat.ts-B32R_kV4.js";import{s as le}from "./second2Day.ts-XjEpcvCc.js";import{c as ue}from "./changeThemeClipPathCircle.ts-CHY9pNkk.js";import{c as ge}from "./event-BIaLzjOy.js";import{Y as he,Z as be}from "./AutoSliderList-drdrxgEX.js";import{A as Te}from "./AvatarCrop-Cn9RwTGU.js";import{A as ve,L as ye}from "./List-DXRmDwDo.js";import{B as Be}from "./Button-CWqApx4k.js";import{C as Oe}from "./Card3D-C1ddJnYV.js";import{C as De}from "./Carousel-D7JsU-he.js";import{C as Ee}from "./Checkbox-C6L0UHHG.js";import{c as we}from "./ContextMenu-Cg72hSPN.js";import{E as Me,c as Ne}from "./VirtualList-DThIEdea.js";import{F as ze}from "./FileDropZone-CQy4SsUO.js";import{M as Ve}from "./MenuButton-CjudK6uV.js";import{m as je}from "./Message-CXBf5Xji.js";import{M as Ge}from "./Modal-Cq9ZPw9X.js";import{O as Ye,a as He}from "./Input-CdxX4nzt.js";import{O as Ue}from "./Select-CprTy0VT.js";import{P as Xe}from "./Pagination-wxdQuNM4.js";import{p as $e}from "./PortalRenderer-CUaab_Kw.js";import{R as rt,a as et}from "./Radio-pth5zZkE.js";import{S as at}from "./ScrollableTabs-CNuEx01I.js";import{S as mt}from "./SvgImg-D2DeoPaA.js";import{S as ft}from "./Switch-CQJGc1NQ.js";import{T as it}from "./TemplateDialog-DAzyCsXv.js";import{t as nt}from "./Toast-1MB_CUWF.js";import{T as ct}from "./Tooltip-7uWxsj7r.js";import{W as dt}from "./Waterfall-CDXm71jP.js";export{he as AutoSliderList,Te as AvatarCrop,ve as AwaitList,Be as Button,Oe as Card3D,De as Carousel,Ee as Checkbox,be as Direction,Me as EstimatedVirtualList,ze as FileDropZone,ye as List,Ve as MenuButton,Ge as Modal,Ye as OnoInput,Ue as OnoSelect,He as OnoTextarea,Xe as Pagination,rt as Radio,et as RadioGroup,at as ScrollableTabs,mt as SvgImg,ft as Switch,it as TemplateDialog,ct as Tooltip,dt as Waterfall,io as addCommasToNumber,no as addEventWithOriginHandler,P as adjustColor,F as adjustingColors,Sr as base64ToBlob,yr as base64ToFile,Br as blobToBase64,Or as blobToFile,co as calculateAspectRatio,ho as chainClassNames,ue as changeThemeClipPathCircle,Co as checkDeviceIsMobile,So as checkStatusCode,T as clearAsyncContagion,we as contextMenu,yo as controlTheScrollbarScrolling,re as convertSecondToOtherTime,Bo as copy2Clipboard,Ne as createDataSource,ge as createEventEmitter,Hr as createIntersectionObserver,te as dayOfYear,Oo as debounce,Do as deepCopy,Xr as distinguishPlatform,$r as distinguishPlatformDelay,Dr as downloadFile,Ur as elementIsInViewport,Eo as ellipsisString,Er as fileToBase64,wr as fileToBlob,A as formatColor,Mr as formatFileSize,se as formatSecond,pe as formatTime,wo as gcd,Mo as getAllTheNumbers,v as getBrowserInfo,I as getColorType,k as getContrastColor,Ro as getElementCenterPosition,Rr as getFileName,Wr as getFileSuffix,Wo as getImageSIze,Zo as getPointDistance,qo as getURLSearchParams,L as grayColor,N as hex2hsl,z as hex2hsv,V as hex2rgb,j as hex3To6,G as hsl2hex,Y as hsl2rgb,K as hsv2hex,J as hsv2rgb,Qo as isPureNumber,_ as isValidColor,xe as localFormat,Ho as mediaAutoplayPolicies,je as message,Uo as padZero,Xo as parseQuery,$o as passwordStrength,rr as pick,$e as portalRenderer,tr as printStr,sr as pureNumber,pr as quickSort,xr as rafTimeout,oo as randomColor,lr as randomString,ur as removeTag,eo as rgb2hex,ao as rgb2hsl,mo as rgb2hsv,fo as rgb2rgba,gr as safeCapitalizeWord,le as second2Day,hr as singleton,Cr as throttle,nt as toast,Zr as urlToBase64,qr as urlToBlob,Qr as urlToFile,e as useClickOutSide,a as useCountdown,m as useEventListener,f as useGetElementSize,i as useKeyPress,n as useMouseClick,c as useQuery,d as useTheme,b as useThemePro};
1
+ import{A as Pe}from "./AutoSliderList-CnR9cnHk.js";import{A as Fe}from "./AvatarCrop-DHnxRLP9.js";import{B as je}from "./Button-CGyWgrQj.js";import{C as Ye}from "./Card3D-NqDUZB0c.js";import{C as He}from "./Carousel-Bnrz70Tw.js";import{C as We}from "./Checkbox-DI_pnI6U.js";import{c as qe}from "./ContextMenu-Boi1cZFI.js";import{F as Ze}from "./FileDropZone-DCvpaUuw.js";import{O as Je,a as Qe}from "./Input-DnB8zvWy.js";import{A as en,L as nn}from "./List-ClfyFOXz.js";import{M as on}from "./MenuButton-BZMchW23.js";import{m as sn}from "./Message-C8cydGYH.js";import{M as ln}from "./Modal-BbixgMNW.js";import{P as dn}from "./Pagination-D428PpRD.js";import{R as mn,a as gn}from "./Radio-CYirLPd9.js";import{S as pn}from "./ScrollableTabs-yCB3QKsp.js";import{O as bn}from "./Select-D5REq6YE.js";import{S as xn}from "./SvgImg-DWqVwwgv.js";import{S as Mn}from "./Switch-uZtwu9mV.js";import{T as En}from "./TemplateDialog-xcIPaUIe.js";import{t as kn}from "./Toast-nAp61Kbz.js";import{T as Tn}from "./Tooltip-Dw-vi5zs.js";import{E as Ln,c as In}from "./VirtualList-DKHTLs7s.js";import{W as Nn}from "./Waterfall-BVjigHTI.js";import{c as x}from "react/compiler-runtime";import{useEffect as E,useState as M,useRef as N,useReducer as U,createContext as Y,useContext as _}from "react";import{jsx as O}from "react/jsx-runtime";import{useShallow as H}from "zustand/shallow";import K from "react-dom/client";const T=(t,e,n)=>{const r=x(19);let o;r[0]!==n ?(o=n||{},r[0]=n,r[1]=o):o=r[1];const{target:s,deps:a,isDeferred:i}=o;let c;r[2]!==e ?(c=(g)=>e(g),r[2]=e,r[3]=c):c=r[3];const l=c;let u,d,h,m;return r[4]!==t||r[5]!==l||r[6]!==i||r[7]!==s ?(u=()=>(typeof t=="string" ?!i&&(s||window).addEventListener(t,l):t.forEach((g)=>!i&&(s||window).addEventListener(g,l)),()=>{typeof t=="string" ?(s||window).removeEventListener(t,l):t.forEach((g)=>(s||window).removeEventListener(g,l));}),r[4]=t,r[5]=l,r[6]=i,r[7]=s,r[8]=u):u=r[8],r[9]!==a ?(d=a||[],r[9]=a,r[10]=d):d=r[10],r[11]!==d||r[12]!==s ?(h=[s,...d],r[11]=d,r[12]=s,r[13]=h):h=r[13],E(u,h),r[14]!==t||r[15]!==l||r[16]!==i||r[17]!==s ?(m=i ?()=>{typeof t=="string" ?(s||window).addEventListener(t,l):t.forEach((g)=>(s||window).addEventListener(g,l));}:void 0,r[14]=t,r[15]=l,r[16]=i,r[17]=s,r[18]=m):m=r[18],m;},wt=(t,e,n)=>{const r=x(10),o=n?.event||"click";let s,a,i,c;return r[0]!==o ?(s=((l)=>{const u=typeof l=="string" ? [l]:l;if(new Set(u).size!==u.length)throw new Error("there are duplicates in the event type");return u;})(o),r[0]=o,r[1]=s):s=r[1],r[2]!==e||r[3]!==t ?(a=(l)=>{if(t)if(t instanceof Array)t.map(W).some((u)=>!!u&&u.contains(l.target))||e(l);else{const u=t instanceof HTMLElement ? t:t.current;u&&!u.contains(l.target)&&e(l);}},r[2]=e,r[3]=t,r[4]=a):a=r[4],r[5]!==n?.deps ?(i=n?.deps||[],r[5]=n?.deps,r[6]=i):i=r[6],r[7]!==t||r[8]!==i ?(c={deps:[t,...i]},r[7]=t,r[8]=i,r[9]=c):c=r[9],T(s,a,c);};function W(t){return t instanceof HTMLElement ? t:t.current;}const bt=(t,e)=>{const n=x(12),r=t===void 0 ? 60:t,[o,s]=M(r),[a,i]=M(!1),c=N(null);let l;n[0]===Symbol.for("react.memo_cache_sentinel")?(l=()=>i(!0),n[0]=l):l=n[0];const u=l;let d;n[1]!==r||n[2]!==e ?(d=()=>{i(!1),s(r),c.current&&(clearTimeout(c.current),c.current=null),e?.();},n[1]=r,n[2]=e,n[3]=d):d=n[3];const h=d;let m,g,f;return n[4]!==a||n[5]!==o||n[6]!==h ?(m=()=>{if(a)return o>0 ? c.current=setTimeout(()=>{s(X);},1e3):h(),()=>{c.current&&(clearTimeout(c.current),c.current=null);};},g=[a,o,h],n[4]=a,n[5]=o,n[6]=h,n[7]=m,n[8]=g):(m=n[7],g=n[8]),E(m,g),n[9]!==o||n[10]!==h ?(f=[o,u,h],n[9]=o,n[10]=h,n[11]=f):f=n[11],f;};function X(t){return t-1;}const yt=(t)=>{const e=x(9);let n;e[0]===Symbol.for("react.memo_cache_sentinel")?(n={w:0,h:0},e[0]=n):n=e[0];const [r,o]=M(n);let s;e[1]===Symbol.for("react.memo_cache_sentinel")?(s=new ResizeObserver((d)=>{for(const h of d)o({w:h.borderBoxSize[0].inlineSize,h:h.borderBoxSize[0].blockSize});}),e[1]=s):s=e[1];const a=s;let i;e[2]!==t ?(i=()=>{if(t&&typeof t!="function")a.observe(t instanceof HTMLElement ? t:t.current);else if(t&&typeof t=="function"){const d=t();a.observe(d instanceof HTMLElement ? d:d.current);}else o({w:window.innerWidth,h:window.innerHeight});},e[2]=t,e[3]=i):i=e[3];const c=i;let l,u;return e[4]!==c||e[5]!==t ?(l=()=>(c(),window.addEventListener("resize",c),()=>{if(window.removeEventListener("resize",c),t&&typeof t!="function")a.unobserve(t instanceof HTMLElement ? t:t.current);else if(t&&typeof t=="function"){const d=t();a.unobserve(d instanceof HTMLElement ? d:d.current);}}),e[4]=c,e[5]=t,e[6]=l):l=e[6],e[7]!==t ?(u=[t],e[7]=t,e[8]=u):u=e[8],E(l,u),r;},S=(t)=>t.toString().toLocaleLowerCase(),xt=(t,e,n)=>{const r=(o)=>T(o,(s)=>((a,i,c)=>{a.forEach((l)=>{if(l.includes("+")&&l.length>1){const u=l.split("+"),d=i.ctrlKey&&u.includes("ctrl"),h=i.shiftKey&&u.includes("shift"),m=i.altKey&&u.includes("alt"),g=i.metaKey&&u.includes("meta"),f=(i.ctrlKey||i.metaKey)&&u.includes("commandorcontrol");u.length===2 ?(d||h||m||g||f)&&i.key.toLocaleLowerCase()===u[u.length-1]&&e(i,l):u.length===3&&(d&&h||d&&m||d&&g||d&&f||h&&m||h&&g||h&&f||m&&g||m&&f||g&&f)&&i.key.toLocaleLowerCase()===u[u.length-1]&&e(i,l);}else if(l.includes(S(i.key))){if(c)l===S(i.key)&&e(i,l);else if(!(i.ctrlKey||i.metaKey||i.shiftKey||i.altKey))return e(i,l);}});})(t instanceof Array ? t.map((a)=>S(a)):[S(t)],s,n?.exactMatch||!1),{deps:[n?.target,...n?.deps||[]]});n?.events instanceof Array ? n.events.forEach((o)=>r(o)):r(n?.events||"keydown");},vt=()=>{const t=x(2);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e={clientX:0,clientY:0,screenX:0,screenY:0,pageX:0,pageY:0},t[0]=e):e=t[0];const [n,r]=M(e);let o;return t[1]===Symbol.for("react.memo_cache_sentinel")?(o=(s)=>{const a=s.clientX,i=s.clientY,c=s.screenX,l=s.screenY,u=s.pageX,d=s.pageY;r({clientX:a,clientY:i,screenX:c,screenY:l,pageX:u,pageY:d});},t[1]=o):o=t[1],T("click",o),n;};let $=!1;const q=(t)=>{const e=x(13),{theme:n,onDark:r,onLight:o}=t;let s;e[0]===Symbol.for("react.memo_cache_sentinel")?(s=window.matchMedia("(prefers-color-scheme:dark)"),e[0]=s):s=e[0];const a=s;let i;e[1]!==r||e[2]!==o ?(i=()=>{a.matches ? r():o();},e[1]=r,e[2]=o,e[3]=i):i=e[3];const c=i;let l;e[4]!==c||e[5]!==r||e[6]!==o||e[7]!==n ?(l=()=>{$&&($=!1,a.removeEventListener("change",c));t:switch(n){case "light":o();break t;case "dark":r();break t;default:c(),$=!0,a.addEventListener("change",c);}},e[4]=c,e[5]=r,e[6]=o,e[7]=n,e[8]=l):l=e[8];const u=l;let d,h;e[9]!==u ?(d=()=>{u();},e[9]=u,e[10]=d):d=e[10],e[11]!==n ?(h=[n],e[11]=n,e[12]=h):h=e[12],E(d,h);},I=(t)=>{const e="ono-view-transition-clip-path-circle",{element:n,duration:r=300,themeRules:o,onChangeTheme:s}=t,a=o?.()||document.documentElement.classList.contains("dark")? "dark":"light";if(!document.startViewTransition)return s(a==="dark" ? "light":"dark");const i=document.startViewTransition(()=>{const f=document.documentElement.classList.contains("dark");s(f ? "light":"dark");}),{top:c,left:l,width:u,height:d}=n.getBoundingClientRect(),h=l+u/2,m=c+d/2,g=[`circle(0%at ${h}px ${m}px)`,`circle(${Math.hypot(Math.max(h,window.innerWidth-h),Math.max(m,window.innerHeight-m))}px at ${h}px ${m}px)`];((f,w)=>{const b=document.createElement("style");b.setAttribute("type","text/css"),b.setAttribute("data-style-tag",w),b.textContent="::view-transition-old(root),::view-transition-new(root){animation:none;}.dark::view-transition-old(root){z-index:1;}.dark::view-transition-new(root){z-index:999;}::view-transition-old(root){z-index:999;}::view-transition-new(root){z-index:1;}",document.head.appendChild(b);})(0,e),i.ready.then(()=>{document.documentElement.animate({clipPath:a==="light" ? g:g.reverse()},{duration:r,fill:"forwards",easing:"ease-in-out",pseudoElement:a==="light" ? "::view-transition-new(root)":"::view-transition-old(root)"}),setTimeout(()=>{return f=e,void document.head.querySelectorAll("style").forEach((w)=>w.getAttribute("data-style-tag")===f&&w.remove());var f;},r+50);});},Mt=(t)=>{const{initTheme:e="light",themeRules:n=(a)=>{a ? document.documentElement.classList.add("dark"):document.documentElement.classList.remove("dark");}}=t||Object.assign({}),[r,o]=M(e),s=N(null);return q({theme:r,onDark:()=>{s.current ? I({element:s.current,onChangeTheme:()=>n(!0)}):n(!0);},onLight:()=>{s.current ? I({element:s.current,onChangeTheme:()=>n(!1)}):n(!1);}}),[r,({targetTheme:a,element:i,onChange:c})=>{s.current=i||null,c?.(),o(a);}];},St=(t)=>{const e=window.fetch,n={status:"pending",value:null},r=(...o)=>{if(n.status==="fulfilled")return n.value;throw n.status==="rejected" ? n.value:e(...o).then((s)=>s.json()).then((s)=>{n.status="fulfilled",n.value=s;}).catch((s)=>{n.status="rejected",n.value=s;});};window.fetch=r;try{t();}catch(o){o instanceof Promise&&o.finally(()=>{window.fetch=r,t(),window.fetch=e;});}window.fetch=e;};function Et(){const t=navigator.userAgent;let e="Unknown",n="Unknown";return/Chrome\/(\d+)/.test(t)?(e="Chrome",n=RegExp.$1):/Firefox\/(\d+)/.test(t)?(e="Firefox",n=RegExp.$1):/Safari\/(\d+)/.test(t)&&/Version\/([\d.]+)/.test(t)?(e="Safari",n=RegExp.$1):/Edge\/(\d+)/.test(t)&&(e="Edge",n=RegExp.$1),{name:e,version:n,isMobile:/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(t)};}function $t(t){if(typeof window>"u")return{};if(t)return new URLSearchParams(window.location.search).get(t);{const e=new URLSearchParams(window.location.search),n={};for(const [r,o] of e.entries())n[r]=o;return n;}}const V=(t)=>/^#([0-9A-Fa-f]{6}|[0-9A-Fa-f]{3})$/.test(t)? "hex":/^rgb\((1?\d{1,3},\s*1?\d{1,3},\s*1?\d{1,3})\)$/.test(t)? "rgb":"unknown",kt=(t,e,n)=>{const r=V(t);if(r==="hex"){const o=t.replace("#",""),s=parseInt(o.slice(0,2),16),a=parseInt(o.slice(2,4),16),i=parseInt(o.slice(4,6),16);if(e==="lighten"){const c=Math.min(255,Math.max(0,s+(255-s)*n/100)),l=Math.min(255,Math.max(0,a+(255-a)*n/100)),u=Math.min(255,Math.max(0,i+(255-i)*n/100));return `#${c.toString(16).padStart(2,"0")}${l.toString(16).padStart(2,"0")}${u.toString(16).padStart(2,"0")}`;}if(e==="darken"){const c=Math.min(255,Math.max(0,s-s*n/100)),l=Math.min(255,Math.max(0,a-a*n/100)),u=Math.min(255,Math.max(0,i-i*n/100));return `#${c.toString(16).padStart(2,"0")}${l.toString(16).padStart(2,"0")}${u.toString(16).padStart(2,"0")}`;}}else if(r==="rgb"){const o=t.match(/\d+/g),s=parseInt(o[0]),a=parseInt(o[1]),i=parseInt(o[2]);if(e==="lighten")return `rgb(${Math.min(255,Math.max(0,s+(255-s)*n/100))},${Math.min(255,Math.max(0,a+(255-a)*n/100))},${Math.min(255,Math.max(0,i+(255-i)*n/100))})`;if(e==="darken")return `rgb(${Math.min(255,Math.max(0,s-s*n/100))},${Math.min(255,Math.max(0,a-a*n/100))},${Math.min(255,Math.max(0,i-i*n/100))})`;}return t;},R=(t)=>{const e=t.split("#")[1],n=(r)=>[parseInt(r.slice(0,2),16),parseInt(r.slice(2,4),16),parseInt(r.slice(4,6),16)];if(e.length===8){const r=parseInt(e.slice(-2),16)/256,o=n(e.slice(0,-2));return o.push(r),"rgba("+o.join(",")+")";}return "rgb("+n(e).join(",")+")";},y=(t)=>t.match(/(\d+\.?\d*)/g),A=(t)=>{const e=y(t),n=Number(e[0])/255,r=Number(e[1])/255,o=Number(e[2])/255,s=Math.min(n,r,o),a=Math.max(n,r,o);let i=0,c=0,l=(a+s)/2;if(a===s)i=c=0;else{const u=a-s;switch(c=l>0.5 ? u/(2-a-s):u/(a+s),a){case n:i=(r-o)/u+(r<o ? 6:0);break;case r:i=(o-n)/u+2;break;case o:i=(n-r)/u+4;}i/=6;}return `hsl(${Math.round(360*i)},${Math.round(100*c)}%,${Math.round(100*l)}%)`;},Z=(t)=>A(R(t)),G=(t)=>{const e=y(t),n=Number(e[0])/360,r=Number(e[1])/100,o=Number(e[2])/100;let s,a,i;function c(d,h,m){return m<0&&(m+=1),m>1&&(m-=1),m<1/6 ? d+6*(h-d)*m:m<0.5 ? h:m<2/3 ? d+(h-d)*(2/3-m)*6:d;}let l=o<0.5 ? o*(1+r):o+r-o*r,u=2*o-l;return s=c(u,l,n+1/3),a=c(u,l,n),i=c(u,l,n-1/3),`rgb(${Math.round(255*s)},${Math.round(255*a)},${Math.round(255*i)})`;},L=(t)=>{const e=y(t),n=(s)=>Number(s).toString(16).padStart(2,"0"),r=(s)=>s.reduce((a,i)=>a+n(i),"#"),o=(s)=>{const a=s,i=Number(s[s.length-1])!==1 ? Number(s[s.length-1]):100;return a.pop(),r(a)+n(2.56*i);};return e.length===3 ? r(e):e.length===5 ? o([e[0],e[1],e[2],10*Number(e[e.length-1])]):o(e);},J=(t)=>L(G(t)),Ct=(t,e,n)=>{let r=[];if(t.includes("#"))r=y(Z(t));else if(t.includes("rgb"))r=y(A(t));else{if(!t.includes("hsl"))throw new Error("颜色格式错误");r=y(t);}return J(`${r[0]},${r[1]}%,${e==="light" ? Number(r[2])+n>100 ? 100:Number(r[2])+n:Number(r[2])-n<0 ? 0:Number(r[2])-n}%`);},P=(t)=>{const e=y(t);let n=Number(e[0])/255,r=Number(e[1])/255,o=Number(e[2])/255;const s=Math.max(n,r,o),a=Math.min(n,r,o);let i=0,c=0,l=s;const u=s-a;if(c=s===0 ? 0:u/s,s===a)i=0;else{switch(s){case n:i=(r-o)/u+(r<o ? 6:0);break;case r:i=(o-n)/u+2;break;case o:i=(n-r)/u+4;}i/=6;}return `hsv(${360*i},${100*c},${100*l})`;},Tt=(t,e=1,n="rgba")=>{const r=y(t);let o=Number(r[0])/255,s=Number(r[1])/255,a=Number(r[2])/255;switch(n){case "rgba":return `rgba(${o},${s},${a},${e})`;case "hex":return L(t);case "hsl":return A(t);case "hsv":return P(t);default:return t;}},At=(t)=>{const e=(function(r){if(r.startsWith("#"))return r.length===4&&(r=`#${r.slice(1).repeat(2)}`),[parseInt(r.substr(1,2),16),parseInt(r.substr(3,2),16),parseInt(r.substr(5,2),16)];if(r.startsWith("rgb")){const o=r.match(/\d+/g);return [parseInt(o[0]),parseInt(o[1]),parseInt(o[2])];}return null;})(t);return e===null ? null:(299*(n=e)[0]+587*n[1]+114*n[2])/1e3>128 ? "#000":"#fff";var n;},Lt=(t,e,n)=>0.2126*t+0.7152*e+0.0722*n,It=(t)=>P(R(t)),Dt=(t)=>{const e=t.replace("#","").split("");return `#${e[0]+e[0]+e[1]+e[1]+e[2]+e[2]}`;},Q=(t)=>{const e=y(t);let n=Number(e[0])/360,r=Number(e[1])/100,o=Number(e[2])/100,s=0,a=0,i=0;const c=Math.floor(6*n),l=6*n-c,u=o*(1-r),d=o*(1-l*r),h=o*(1-(1-l)*r);switch(c%6){case 0:s=o,a=h,i=u;break;case 1:s=d,a=o,i=u;break;case 2:s=u,a=o,i=h;break;case 3:s=u,a=d,i=o;break;case 4:s=h,a=u,i=o;break;case 5:s=o,a=u,i=d;}return `rgb(${Math.round(255*s)},${Math.round(255*a)},${Math.round(255*i)})`;},Nt=(t)=>L(Q(t)),Ot=(t)=>!(!/^#([0-9A-Fa-f]{6}|[0-9A-Fa-f]{3})$/.test(t)&&!/^rgb\((1?\d{1,3},\s*1?\d{1,3},\s*1?\d{1,3})\)$/.test(t)),Rt=()=>"#"+Math.random().toString(16).slice(2,8).padEnd(6,"0"),Pt=(t,e)=>{if(!e)return t;if(t.includes("rgba")){const n=t.split(",");return n.pop(),n.push(e+")"),n.join(",");}if(t.includes("rgb")){const n=t.split(","),r="rgba("+n[0].split("(")[1],o=n[n.length-1].split(")")[0];return [r,n[1],o," "+e+")"].join(",");}},Bt=(t)=>{if(typeof t!="number"||isNaN(t))throw new Error("请输入有效的数字");const e=t.toString().split(".");return e[0]=e[0].replace(/\B(?=(\d{3})+(?!\d))/g,","),e.join(".");},Ft=(t,e,n)=>{const r=t[e];t[e]=function(o){r&&typeof r=="function"&&r.call(this,o),n.call(this,o);};},zt=(...t)=>{let e="";for(let n=0;n<t.length;n++){const r=t[n];r&&(e&&(e+=" "),e+=r);}return e;},jt=()=>/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent),Ut=(t,e)=>{t.toString().startsWith("2")? e.onSuccess&&e.onSuccess():(t.toString().startsWith("4")||t.toString().startsWith("5"))&&e.onFail&&e.onFail();},Yt=(t)=>navigator.clipboard.writeText(t),_t=(t,e)=>{let n=null;return(...r)=>{n&&clearTimeout(n),n=setTimeout(()=>{t(...r),n=null;},e);};},tt=(t)=>{if(typeof t!="object"||t===null)return t;const e=Array.isArray(t)? []:{};for(const n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=tt(t[n]));return e;},Ht=(t,e,n=t.length)=>e>=t.length ? t:(e<0&&(e=Math.max(0,e+t.length)),n<0&&(n=t.length+n),e>n&&([e,n]=[n,e]),e=Math.max(0,Math.min(e,t.length)),(n=Math.max(0,Math.min(n,t.length)))-e>3 ? t.substring(0,e)+"..."+t.substring(n):t),Kt=(t)=>typeof t!="string"||t.length===0 ? "":t.charAt(0).toUpperCase()+t.slice(1),D=(t,e)=>{for(t=Math.abs(t),e=Math.abs(e);e!==0;){const n=e;e=t%e,t=n;}return t;},Wt=(t,e="viewport")=>{const n=t.getBoundingClientRect(),r=n.left+n.width/2,o=n.top+n.height/2;switch(e){case "page":return{x:r+window.pageXOffset,y:o+window.pageYOffset};case "parent":const s=t.parentElement;if(!s)return{x:r,y:o};const a=s.getBoundingClientRect();return{x:r-(a.left+a.width/2),y:o-(a.top+a.height/2)};default:return{x:r,y:o};}},Xt=(t)=>new Promise((e,n)=>{const r=new Image();let o=null;const s=()=>{o&&URL.revokeObjectURL(o);};r.onload=()=>{s(),e({width:r.width,height:r.height});},r.onerror=()=>{s(),n(new Error("Failed to load image"));},typeof t=="string" ? r.src=t:(o=URL.createObjectURL(t),r.src=o);}),qt=(t,e,n,r)=>Math.sqrt((t-n)**2+(e-r)**2),Vt=(t,e)=>`${Math.floor(t/D(t,e))}:${Math.floor(e/D(t,e))}`,et=(t)=>{const e=new Set();for(const n of t){if(e.has(n))return!0;e.add(n);}return!1;},Zt=(t)=>/^\d+$/.test(t),Gt=(t,e,n)=>{t.muted=!0,t.play();const r=new AudioContext(),o=r.state==="running";r.close(),o ?(t.muted=!1,e?.()):n?.();},p=(t)=>t<10 ? `0${t}`:`${t}`,Jt=(t)=>{const e={};return t.replace(/([^?=&]+)=([^&]+)/g,(n,r,o)=>e[r]=o),e;},Qt=/^(?=.*\d)(?=.*[a-z])(?=.*[A-Z])(?=.*[!@#$%^&*()_+])[\da-zA-Z]{8,}$/,te=({el:t,str:e="hello world",speed:n=100,isExtendStr:r=!0,onDone:o})=>{let s=0,a=null;t.textContent&&r&&(s=t.textContent.length,e=t.textContent+e);const i=()=>{clearTimeout(a);const c=e.substring(0,s+1);t.textContent=c,s++,s!==e.length ? a=setTimeout(i,n):o?.();};i();},ee=(t)=>parseFloat(t.replace(/[^0-9.]/g,"")),ne=(t)=>{if(t.length<2)return [...t];const e=[...t];return C(e,0,e.length-1),e;};function C(t,e,n){if(e<n){const r=(function(o,s,a){const i=o[a];let c=s-1;for(let l=s;l<a;l++)o[l]<=i&&(c++,[o[c],o[l]]=[o[l],o[c]]);return [o[c+1],o[a]]=[o[a],o[c+1]],c+1;})(t,e,n);C(t,e,r-1),C(t,r+1,n);}}const re=(t,e)=>{let n=0;const r=(o)=>{n||(n=o),o-n>=e ? t():requestAnimationFrame(r);};requestAnimationFrame(r);},oe=(t)=>{if(t<=0)return "";let e="";for(let n=0;n<t;n++)e+="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789".charAt(Math.floor(62*Math.random()));return e;},ae=(t)=>new DOMParser().parseFromString(t,"text/html").body.textContent||"",se=({currentIndex:t,itemHeight:e,total:n,showMaxNumber:r,element:o})=>{if(n<=0||r<=0||e<=0||n<=r)return;const s=Math.floor(o.scrollTop/e);if(t>=s&&t<=s+r-1)return;let a;a=t<s ? t*e:(t-r+1)*e;const i=(n-r)*e;a=Math.max(0,Math.min(i,a)),a!==o.scrollTop&&o.scrollTo({top:a});},ie=(t,e=[],n=!0)=>{if(e.length===0)return t;if(et(e))throw new Error("Each item in properties must be unique");if(n){const r={};for(const o of e)r[o]=t[o];return r;}{const r=new Set(e),o={};for(const s in t)r.has(s)||(o[s]=t[s]);return o;}},ce=(t)=>{let e;const n=new Proxy(t,{construct:(r,o)=>(e||(e=Reflect.construct(r,o)),e)});return n.prototype.construct=n,n;};function le(t,e,n={}){let r,o=null,s=null,a=0;const i=n.leading!==!1,c=n.trailing!==!1;function l(){s&&(t.apply(r,s),s=null);}function u(){const h=Date.now();h-a>=e ?(c&&s&&l(),o=null):o=setTimeout(u,e-(h-a));}const d=function(...h){const m=Date.now();s=h,r=this,m-a>=e ? o||(a=m,i ? l():c&&(o=setTimeout(u,e))):!o&&c&&(o=setTimeout(u,e-(m-a)));};return d.cancel=function(){o&&(clearTimeout(o),o=null),a=0,s=null;},d;}const nt=/^data:image\/([a-zA-Z]*);base64,([^\s]*)$/,rt=/^[A-Za-z0-9+/]*={0,2}$/,B=(t)=>{if(typeof t!="string"||t.length===0)return!1;if(nt.test(t))return!0;if(t.length%4!=0||!rt.test(t))return!1;if(t.length<=100)return!0;try{return btoa(atob(t))===t;}catch{return!1;}},ue=(t)=>{if(!B(t))throw new Error("Invalid base64 string");const e=t.indexOf(","),n=t.substring(0,e).match(/:(.*?);/);if(!n||!n[1])throw new Error("Could not extract MIME type from base64 string");const r=n[1],o=atob(t.substring(e+1)),s=new Uint8Array(o.length);for(let a=0;a<o.length;a++)s[a]=o.charCodeAt(a);return new Blob([s],{type:r});},de=(t,e)=>{if(!B(t))throw new Error("Invalid base64 string");const n=t.indexOf(","),r=t.substring(0,n),o=t.substring(n+1),s=r.match(/:(.*?);/);if(!s||!s[1])throw new Error("Could not extract MIME type from base64 string");const a=s[1],i=atob(o),c=new Uint8Array(i.length);for(let h=0;h<i.length;h++)c[h]=i.charCodeAt(h);const l=a.split("/"),u=l[1]==="jpeg" ? ".jpg":"."+l[1],d=new Blob([c],{type:a});return new File([d],e+u,{type:a,lastModified:Date.now()});},ot=(t)=>new Promise((e)=>{const n=new FileReader();n.readAsDataURL(t),n.onload=(r)=>{const o=r.target?.result,s=o.split(",")[1];e(s);};}),at=(t,e="abc.jpg")=>new File([t],e,{type:t.type}),he=async(t,e)=>{const n=(r,o)=>{const s=window.URL.createObjectURL(r),a=document.createElement("a");a.href=s,a.download=encodeURIComponent(o),document.body.appendChild(a),a.click(),document.body.removeChild(a),window.URL.revokeObjectURL(s);};try{if(typeof t=="string"){const r=await fetch(t);if(!r.ok)throw new Error(`Network response was not ok:${r.statusText}`);n(await r.blob(),e);}else n(t,e);}catch{}},me=(t)=>new Promise((e)=>{const n=new FileReader();n.readAsDataURL(t),n.onload=(r)=>e(r.target?.result);}),ge=(t)=>t.slice(0,t.size,t.type),fe=(t,e)=>{const n=["B","KB","MB","GB","TB"];let r=n.indexOf(e?.unit ?? "B");if(r===-1)throw new Error("Invalid unit");if(!e?.unit)for(;t/Math.pow(1024,r)>=1024;)r++;return `${(t/Math.pow(1024,r)).toFixed(e?.decimalPlaces ?? 0)}${n[r]}`;},st=(t)=>{if(!t)return "";const e=t.lastIndexOf(".");return e===-1 ? st(t.substring(t.lastIndexOf("/")+1)):t.substring(0,e);},pe=(t)=>{if(!t)return "";const e=t.lastIndexOf(".");return t.substring(e+1);},F=async(t)=>await(await fetch(t)).blob(),we=async(t)=>await ot(await F(t)),be=async(t)=>at(await F(t)),ye=(t,e,n)=>{const r=new IntersectionObserver(e,n);t instanceof HTMLElement ? r.observe(t):t.forEach((o)=>r.observe(o));},xe=(t,e,n,r={root:null,rootMargin:"0px",threshold:0})=>{const o=new IntersectionObserver((s)=>s.forEach((a)=>a.isIntersecting ? e(a):n(a)),r);t.forEach((s)=>o.observe(s));},it=({onAndroid:t,onIOS:e,onUnknown:n})=>{const r=navigator.userAgent;return/android/i.test(r)?(t(),"Android"):/iPad|iPhone|iPod/.test(r)?(e(),"iOS"):(n?.(),"Unknown");},ve=({onAndroid:t,onIOS:e,onUnknown:n,timeout:r=500})=>()=>{setTimeout(()=>it({onAndroid:t,onIOS:e,onUnknown:n}),r);},Me=(t,e)=>{const n={year:31536e3,month:2592e3,day:86400,hour:3600,minute:60,second:1};if(!n[e])throw new Error('Invalid type. Please use "day","hour","minute",or "second".');return Math.floor(t/n[e]);},Se=(t)=>Math.ceil((t.getTime()-new Date(t.getFullYear(),0,1).getTime())/864e5),Ee=(t)=>{const e=Math.floor(t/3600),n=Math.floor(t%3600/60),r=Math.floor(t%60),o=(s)=>s.toString().padStart(2,"0");return(e>0 ? `${o(e)}:${o(n)}:${o(r)}`:`${o(n)}:${o(r)}`)+(t<10 ? ".00":t<100 ? ".0":"");},z=(t)=>t.toString().length>13 ? new Date(Number(t.toString().substring(0,13))):t.toString().length===13 ? new Date(t):t.toString().length<13&&t.toString().length>10 ? new Date(Number((t.toString()+"000").substring(0,13))):t.toString().length===10 ? new Date(1e3*t):new Date(Number((t.toString()+"000000000000").substring(0,13))),$e=(t,e="YY-MM-DD hh:mm:ss")=>{const n=["YY","MM","DD","hh","mm","ss"],r=[],o=z(t);r.push(o.getFullYear().toString()),r.push(p(o.getMonth()+1)),r.push(p(o.getDate())),r.push(p(o.getHours())),r.push(p(o.getMinutes())),r.push(p(o.getSeconds()));for(let s in r)e=e.replace(n[s],r[s]);return e;},ke=(t,e="YY-MM-DD hh:mm:ss",n="cn")=>{const r=["YY","MM","DD","hh","mm","ss"],o=[],s=z(t);o.push(((a,i)=>{const c={en:["0","1","2","3","4","5","6","7","8","9"],cn:["零","一","二","三","四","五","六","七","八","九"]};return a.split("").map((l)=>c[i][Number(l)]).join("");})(s.getFullYear().toString(),n)),o.push(((a,i)=>({en:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sept","Oct","Nov","Dec"],cn:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"]})[i][Number(a)-1])(p(s.getMonth()+1),n)),o.push(((a,i)=>{let c;return i==="en" ? c=a==="01"||a==="21"||a==="31" ? Number(a)+"st":a==="02"||a==="22" ? Number(a)+"nd":a==="03"||a==="23" ? Number(a)+"rd":Number(a)+"th":a==="01" ? c="一日":a==="02" ? c="二日":a==="03" ? c="三日":a==="04" ? c="四日":a==="05" ? c="五日":a==="06" ? c="六日":a==="07" ? c="七日":a==="08" ? c="八日":a==="09" ? c="九日":a==="10" ? c="十日":a==="11" ? c="十一日":a==="12" ? c="十二日":a==="13" ? c="十三日":a==="14" ? c="十四日":a==="15" ? c="十五日":a==="16" ? c="十六日":a==="17" ? c="十七日":a==="18" ? c="十八日":a==="19" ? c="十九日":a==="20" ? c="二十日":a==="21" ? c="二十一日":a==="22" ? c="二十二日":a==="23" ? c="二十三日":a==="24" ? c="二十四日":a==="25" ? c="二十五日":a==="26" ? c="二十六日":a==="27" ? c="二十七日":a==="28" ? c="二十八日":a==="29" ? c="二十九日":a==="30" ? c="三十日":a==="31"&&(c="三十一日"),c ?? a;})(p(s.getDate()),n)),o.push(p(s.getHours())),o.push(p(s.getMinutes())),o.push(p(s.getSeconds()));for(let a in o)e=e.replace(r[a],o[a]);return e;},Ce=(t,e)=>{const n=["DD","hh","mm","ss"],r=[];r.push(Math.floor(t/86400)),r.push(p(Math.floor(t%86400/3600))),r.push(p(Math.floor(t%3600/60))),r.push(p(t%60));for(let o=0;o<n.length;o++)e=e.replace(n[o],r[o].toString());return e;},Te=(t)=>{const e="ono-view-transition-clip-path-circle",{element:n,duration:r=300,themeRules:o,onChangeTheme:s}=t,a=o?.()||document.documentElement.classList.contains("dark")? "dark":"light";if(!document.startViewTransition)return s(a==="dark" ? "light":"dark");const i=document.startViewTransition(()=>{const f=document.documentElement.classList.contains("dark");s(f ? "light":"dark");}),{top:c,left:l,width:u,height:d}=n.getBoundingClientRect(),h=l+u/2,m=c+d/2,g=[`circle(0%at ${h}px ${m}px)`,`circle(${Math.hypot(Math.max(h,window.innerWidth-h),Math.max(m,window.innerHeight-m))}px at ${h}px ${m}px)`];((f,w)=>{const b=document.createElement("style");b.setAttribute("type","text/css"),b.setAttribute("data-style-tag",w),b.textContent="::view-transition-old(root),::view-transition-new(root){animation:none;}.dark::view-transition-old(root){z-index:1;}.dark::view-transition-new(root){z-index:999;}::view-transition-old(root){z-index:999;}::view-transition-new(root){z-index:1;}",document.head.appendChild(b);})(0,e),i.ready.then(()=>{document.documentElement.animate({clipPath:a==="light" ? g:g.reverse()},{duration:r,fill:"forwards",easing:"ease-in-out",pseudoElement:a==="light" ? "::view-transition-new(root)":"::view-transition-old(root)"}),setTimeout(()=>((f)=>{document.head.querySelectorAll("style").forEach((w)=>w.getAttribute("data-style-tag")===f&&w.remove());})(e),r+50);});},Ae=(t)=>(e)=>t(H((n)=>((r,o=[],s=!0)=>{if(o.length===0)return r;if(((a)=>{const i=new Set();for(const c of a){if(i.has(c))return!0;i.add(c);}return!1;})(o))throw new Error("Each item in properties must be unique");if(s){const a={};for(const i of o)a[i]=r[i];return a;}{const a=new Set(o),i={};for(const c in r)a.has(c)||(i[c]=r[c]);return i;}})(n,e))),ct={get:(t)=>t,set:(t,e)=>({...t,[e.key]:e.value}),del:(t,e)=>{const n={...t};return delete n[e.key],n;}},lt=(t,e)=>ct[e.type](t,e),j=Y(null),Le=(t)=>{const e=x(5),{initData:n,children:r}=t,[o,s]=U(lt,n);let a,i;return e[0]!==o ?(a={data:o,dispatch:s},e[0]=o,e[1]=a):a=e[1],e[2]!==r||e[3]!==a ?(i=O(j.Provider,{value:a,children:r}),e[2]=r,e[3]=a,e[4]=i):i=e[4],i;},ut=()=>{const t=x(6),e=_(j);if(!e)throw new Error("useData must be used within a DataProvider");let n;t[0]!==e ?(n={set:(s,a)=>{typeof a=="function" ? e.dispatch({type:"set",key:s,value:a(e.data[s])}):e.dispatch({type:"set",key:s,value:a});},setAll:(s)=>Object.keys(s).forEach((a)=>e.dispatch({type:"set",key:a,value:s[a]})),del:(s)=>e.dispatch({type:"del",key:s})},t[0]=e,t[1]=n):n=t[1];const r=n;let o;return t[2]!==e.data||t[3]!==e.dispatch||t[4]!==r ?(o={data:e.data,dispatch:r,originDispatch:e.dispatch},t[2]=e.data,t[3]=e.dispatch,t[4]=r,t[5]=o):o=t[5],o;},Ie=(t)=>ut,v=new Map(),De=(t,e,n,r)=>{const{target:o,root:s,reactRoot:a}=((c,l)=>{const u=c||`${l}-${Math.random().toString(36)}`;if(v.has(u)){const f=v.get(u);if(document.contains(f.target))return f;v.delete(u);}let d,h,m=null;l&&(m=document.getElementById(l),m||(m=document.createElement("div"),m.id=l,document.body.appendChild(m))),c ?(d=document.getElementById(c)?? document.createElement("div"),d.id||(d.id=c,m ? m.appendChild(d):document.body.appendChild(d))):(d=document.createElement("div"),m ? m.appendChild(d):document.body.appendChild(d)),d.__reactContainer$ ? h=d.__reactContainer$:(h=K.createRoot(d),d.__reactContainer$=h);const g={target:d,root:m,reactRoot:h};return v.set(u,g),g;})(n,r),i=(c)=>{try{typeof c=="function"&&c();const l=n||`${r}-${Math.random().toString(36)}`;v.delete(l),a.unmount(),n ? document.getElementById(n)?.remove():o.remove(),requestAnimationFrame(()=>{s&&s.children.length===0&&s.remove();});}catch{}};return a.render(O(t,{...e,destroy:i})),i;};class dt{events={};constructor(e){for(let n=0;n<e.length;n++)this.events[e[n]]=new Set();}createEvent(e,n=!1){this.events[e]&&!n||(this.events[e]=new Set());}emit(e,...n){if(!this.events[e])throw new Error(`Event ${e}does not exist`);this.events[e].forEach((r)=>{r(...n);});}on(e,n,r=!0){this.createEvent(e,r),this.events[e].add(n);}cancel(e,n){this.events[e]&&this.events[e].delete(n);}clear(e){if(e)this.createEvent(e,!0);else{const n=Object.keys(this.events);for(let r=0;r<n.length;r++)this.createEvent(n[r],!0);}}}let k=null;const Ne=(t)=>(k||(k=new dt(t)),k);export{Pe as AutoSliderList,Fe as AvatarCrop,en as AwaitList,je as Button,Ye as Card3D,He as Carousel,We as Checkbox,Le as DataProvider,Ln as EstimatedVirtualList,Ze as FileDropZone,nn as List,on as MenuButton,ln as Modal,Je as OnoInput,bn as OnoSelect,Qe as OnoTextarea,dn as Pagination,mn as Radio,gn as RadioGroup,pn as ScrollableTabs,xn as SvgImg,Mn as Switch,En as TemplateDialog,Tn as Tooltip,Nn as Waterfall,Bt as addCommasToNumber,Ft as addEventWithOriginHandler,kt as adjustColor,Ct as adjustingColors,ue as base64ToBlob,de as base64ToFile,ot as blobToBase64,at as blobToFile,zt as chainClassNames,Te as changeThemeClipPathCircle,jt as checkDeviceIsMobile,Ut as checkStatusCode,St as clearAsyncContagion,qe as contextMenu,Me as convertSecondToOtherTime,Yt as copy2Clipboard,Ie as createContextData,In as createDataSource,Ae as createDesignateStore,Ne as createEventEmitter,ye as createIntersectionObserver,Se as dayOfYear,_t as debounce,tt as deepCopy,it as distinguishPlatform,ve as distinguishPlatformDelay,he as downloadFile,xe as elementIsInViewport,Ht as ellipsisString,me as fileToBase64,ge as fileToBlob,Kt as firstLetter2Capitalize,Tt as formatColor,fe as formatFileSize,Ee as formatSecond,$e as formatTime,D as gcd,y as getAllNumbers,Et as getBrowserInfo,V as getColorType,At as getContrastColor,Wt as getElementCenterPosition,st as getFileName,pe as getFileSuffix,Xt as getImageSize,qt as getPointDistance,Vt as getRatio,$t as getURLSearchParams,Lt as grayColor,et as hasDuplicates,Z as hex2hsl,It as hex2hsv,R as hex2rgb,Dt as hex3To6,J as hsl2hex,G as hsl2rgb,Nt as hsv2hex,Q as hsv2rgb,B as isBase64,Zt as isPureNumber,Ot as isValidColor,ke as localFormat,Gt as mediaAutoplayPolicies,sn as message,p as padZero,Jt as parseQuery,Qt as passwordStrength,De as portalRenderer,te as printStr,ee as pureNumber,ne as quickSort,re as rafTimeout,Rt as randomColor,oe as randomString,ae as removeTag,L as rgb2hex,A as rgb2hsl,P as rgb2hsv,Pt as rgb2rgba,se as scrollToItem,Ce as second2Day,ie as selectProperties,ce as singleton,le as throttle,kn as toast,we as urlToBase64,F as urlToBlob,be as urlToFile,wt as useClickOutSide,bt as useCountdown,T as useEventListener,yt as useGetElementSize,xt as useKeyPress,vt as useMouseClick,q as useTheme,Mt as useThemePro};
@@ -1,2 +1 @@
1
1
  export { AutoSliderList } from './AutoSliderList';
2
- export { Direction } from './types';
@@ -1,8 +1,4 @@
1
1
  import { CSSProperties, JSX } from 'react';
2
- export declare enum Direction {
3
- Horizontal = "Horizontal",
4
- Vertical = "Vertical"
5
- }
6
2
  export interface AutoSliderListProps<T> {
7
3
  list: T[];
8
4
  children: ({ item, index, isActive }: {
@@ -14,10 +10,10 @@ export interface AutoSliderListProps<T> {
14
10
  duration?: number;
15
11
  className?: string;
16
12
  style?: CSSProperties;
17
- direction?: Direction;
18
13
  currentIndex?: number;
19
14
  sliderBox?: JSX.Element;
20
15
  sliderClassName?: string;
21
16
  sliderStyle?: CSSProperties;
17
+ direction?: 'Horizontal' | 'Vertical';
22
18
  sliderTransitionTimingFunction?: string;
23
19
  }
@@ -1,2 +1,2 @@
1
1
  import { ModalBoxProps } from './types';
2
- export declare const Modal: (options: ModalBoxProps) => (onDestroy?: (() => void) | undefined) => void;
2
+ export declare const Modal: (options: ModalBoxProps) => (onDestroy?: () => void) => void;
@@ -1,2 +1,2 @@
1
1
  import { VirtualListProps } from './types';
2
- export declare const EstimatedVirtualList: import('react').MemoExoticComponent<({ containerClassName, dataSource, containerStyle, onEndCallback, refreshSpeed, wrapperClassName, wrapperStyle, estimatedSize, updateDataSourceScroll2Top, direction }: VirtualListProps) => import("react/jsx-runtime").JSX.Element>;
2
+ export declare const EstimatedVirtualList: ({ containerClassName, dataSource, containerStyle, onEndCallback, refreshSpeed, wrapperClassName, wrapperStyle, estimatedSize, updateDataSourceScroll2Top, direction }: VirtualListProps) => import("react/jsx-runtime").JSX.Element;
@@ -12,7 +12,6 @@ export * from './MenuButton';
12
12
  export * from './Message';
13
13
  export * from './Modal';
14
14
  export * from './Pagination';
15
- export * from './PortalRenderer';
16
15
  export * from './Radio';
17
16
  export * from './ScrollableTabs';
18
17
  export * from './Select';