@aussieljk/forkbook 0.0.1-4 → 0.0.1-6

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 (318) hide show
  1. package/LICENSE +22 -0
  2. package/README.md +35 -53
  3. package/dist/_browser-chunks/{Color-KRDPNBZS.js → Color-2BMQTRYG.js} +3 -3
  4. package/dist/_browser-chunks/WithTooltip-GJACFWKM.js +196 -0
  5. package/dist/_browser-chunks/chunk-6AKCRYVX.js +6 -0
  6. package/dist/_browser-chunks/chunk-6EJEEII7.js +1149 -0
  7. package/dist/_browser-chunks/{chunk-LXQPPHMD.js → chunk-6IKB2UHQ.js} +27 -27
  8. package/dist/_browser-chunks/chunk-DPRGR3QP.js +5995 -0
  9. package/dist/_browser-chunks/{chunk-K6GRZSXS.js → chunk-EQKMUQF3.js} +4 -3
  10. package/dist/_browser-chunks/{chunk-GU3X2J4S.js → chunk-FRAOQJDI.js} +3 -1
  11. package/dist/_browser-chunks/{chunk-2SCZVUKW.js → chunk-H4ZHAXN3.js} +1 -1
  12. package/dist/_browser-chunks/{chunk-ZLWA5RIE.js → chunk-I4ATZPNZ.js} +1 -1
  13. package/dist/_browser-chunks/{chunk-6SHRDXGF.js → chunk-IJYLSHY7.js} +173 -87
  14. package/dist/_browser-chunks/{chunk-SZCSXISG.js → chunk-NA4ITZTK.js} +7 -5
  15. package/dist/_browser-chunks/chunk-NGMQJMCY.js +53 -0
  16. package/dist/_browser-chunks/{chunk-K2B36HKM.js → chunk-O24AZJZ7.js} +1 -1
  17. package/dist/_browser-chunks/{chunk-BZGX2THJ.js → chunk-QAHDGPZ7.js} +3 -3
  18. package/dist/_browser-chunks/{chunk-NMRSYACM.js → chunk-SFMQDIN2.js} +4 -3
  19. package/dist/_browser-chunks/{chunk-ZTQ5MEJ5.js → chunk-UMGDO2ZM.js} +3 -37
  20. package/dist/_browser-chunks/{chunk-FVSEPWWX.js → chunk-X7D777E6.js} +547 -1622
  21. package/dist/_browser-chunks/{chunk-52CW7FF7.js → chunk-YYWKZ7O3.js} +3 -1
  22. package/dist/_node-chunks/{attached-runtime-CYMSKF3A.js → attached-runtime-EBWIOQZN.js} +29 -29
  23. package/dist/_node-chunks/{builder-manager-RMLSIO45.js → builder-manager-ETBLZ2RH.js} +288 -349
  24. package/dist/_node-chunks/{chunk-IR34HUSL.js → chunk-252Y5WHZ.js} +7 -7
  25. package/dist/_node-chunks/{chunk-VPOJCHKM.js → chunk-25PXULSJ.js} +14 -14
  26. package/dist/_node-chunks/chunk-2DBJWMYE.js +495 -0
  27. package/dist/_node-chunks/{chunk-KXDJ77EW.js → chunk-3UWWRDA5.js} +7 -7
  28. package/dist/_node-chunks/{chunk-DVLFCSDG.js → chunk-4KCQYJT6.js} +7 -7
  29. package/dist/_node-chunks/{chunk-X3E55W5S.js → chunk-4MJIPOJ5.js} +6 -6
  30. package/dist/_node-chunks/{chunk-5TPSYG4L.js → chunk-4WLIN3VZ.js} +8 -8
  31. package/dist/_node-chunks/{chunk-WBTLBIED.js → chunk-4XNPO23I.js} +6 -6
  32. package/dist/_node-chunks/{chunk-NHIRHARE.js → chunk-5T635FTI.js} +10 -10
  33. package/dist/_node-chunks/{chunk-YU2WFBFL.js → chunk-5Z6MT4RI.js} +8 -8
  34. package/dist/_node-chunks/{chunk-2QWFS23O.js → chunk-644CUCK5.js} +7 -7
  35. package/dist/_node-chunks/{chunk-7XCJ7RAJ.js → chunk-7E27CGRU.js} +7 -7
  36. package/dist/_node-chunks/{chunk-WS367FSJ.js → chunk-A35J7YYA.js} +6 -6
  37. package/dist/_node-chunks/{chunk-ILFIERUB.js → chunk-ALHPFKVB.js} +8 -8
  38. package/dist/_node-chunks/{chunk-SQMCVWOR.js → chunk-ANDQVXYX.js} +8 -8
  39. package/dist/_node-chunks/{chunk-HUFAUSEX.js → chunk-AS4SFRCZ.js} +6 -6
  40. package/dist/_node-chunks/{chunk-XBXGLD3K.js → chunk-BLUMKQQB.js} +6 -6
  41. package/dist/_node-chunks/{chunk-QU5ANYM7.js → chunk-C5JG7EKF.js} +6 -6
  42. package/dist/_node-chunks/{chunk-P6QAFJ5M.js → chunk-CBUQY454.js} +7 -15
  43. package/dist/_node-chunks/{chunk-4LPAWP5S.js → chunk-CF7KLGUW.js} +22 -20
  44. package/dist/_node-chunks/{chunk-MOITZTEA.js → chunk-CGVPHZVD.js} +8 -8
  45. package/dist/_node-chunks/{chunk-2NWHHNNI.js → chunk-DABFUVLR.js} +6 -6
  46. package/dist/_node-chunks/{chunk-XH6TDVML.js → chunk-DCNZ6SFN.js} +6 -6
  47. package/dist/_node-chunks/{chunk-F2N6BJRH.js → chunk-DDGW2EBW.js} +29843 -51588
  48. package/dist/_node-chunks/{chunk-OS5LQEC6.js → chunk-DRLBJM6X.js} +7 -7
  49. package/dist/_node-chunks/{chunk-GEMKJCEE.js → chunk-E3O7VAPG.js} +10 -10
  50. package/dist/_node-chunks/{chunk-4GD7MMLJ.js → chunk-FIFCNBTL.js} +7 -7
  51. package/dist/_node-chunks/{chunk-UMZSNFWM.js → chunk-FQWTUSYB.js} +6 -6
  52. package/dist/_node-chunks/{chunk-JEEXR245.js → chunk-G6YNW4FK.js} +7 -7
  53. package/dist/_node-chunks/{chunk-HP5UY6OY.js → chunk-GDFQQO5U.js} +6 -6
  54. package/dist/_node-chunks/{chunk-653BSJIX.js → chunk-GGTXOH3W.js} +6 -6
  55. package/dist/_node-chunks/{chunk-PDCSUZ4L.js → chunk-GIOREKIG.js} +7 -7
  56. package/dist/_node-chunks/{chunk-V2JDVM46.js → chunk-GOFK4EKU.js} +6 -6
  57. package/dist/_node-chunks/{chunk-INEYTOWF.js → chunk-GQ3HJNIH.js} +10 -13
  58. package/dist/_node-chunks/{chunk-2APY2YSW.js → chunk-GRTI5653.js} +7 -7
  59. package/dist/_node-chunks/{chunk-KN2S7JF2.js → chunk-HKL3VOYX.js} +6 -6
  60. package/dist/_node-chunks/{chunk-A2UMIN5B.js → chunk-HUPRQZ3I.js} +7 -7
  61. package/dist/_node-chunks/{chunk-7JA2DMCJ.js → chunk-HWRHYM7Z.js} +6 -6
  62. package/dist/_node-chunks/{chunk-SBQT3LMM.js → chunk-I7HRDCNY.js} +10 -10
  63. package/dist/_node-chunks/{chunk-2IJCISIB.js → chunk-IFPMZ247.js} +6 -6
  64. package/dist/_node-chunks/{chunk-DIUBMAMV.js → chunk-J6M5CRYZ.js} +8 -8
  65. package/dist/_node-chunks/{chunk-IBO346NQ.js → chunk-JPXJI6QR.js} +60 -134
  66. package/dist/_node-chunks/{chunk-STRSG3GT.js → chunk-JS2J2SKX.js} +6 -6
  67. package/dist/_node-chunks/{chunk-FNGLVURC.js → chunk-JZWF3XLN.js} +6 -6
  68. package/dist/_node-chunks/{chunk-KINEBDMM.js → chunk-KF3FT3NI.js} +9 -9
  69. package/dist/_node-chunks/chunk-KWPWQA7G.js +2609 -0
  70. package/dist/_node-chunks/{chunk-OIIORQX5.js → chunk-L4JGWK4K.js} +6 -6
  71. package/dist/_node-chunks/{chunk-MRZD5SBV.js → chunk-LFIFBDMS.js} +6 -6
  72. package/dist/_node-chunks/{chunk-UAALLQAQ.js → chunk-LWKLJYYQ.js} +6 -6
  73. package/dist/_node-chunks/{chunk-AFKKN27O.js → chunk-LXVSVTQ3.js} +6 -6
  74. package/dist/_node-chunks/chunk-MDW3GSU3.js +69 -0
  75. package/dist/_node-chunks/{chunk-UXW4I2CN.js → chunk-MFN2XBPL.js} +7 -7
  76. package/dist/_node-chunks/{chunk-ESZVID7Q.js → chunk-MQFB44YS.js} +7 -7
  77. package/dist/_node-chunks/{chunk-3XDIBUGD.js → chunk-MZ2GSR3G.js} +23 -51
  78. package/dist/_node-chunks/{chunk-POXTROIX.js → chunk-N7HEOGTM.js} +9 -6
  79. package/dist/_node-chunks/{chunk-UIFLXDUL.js → chunk-NUAQC3XP.js} +16 -13
  80. package/dist/_node-chunks/{chunk-BOUA7OB7.js → chunk-NX6CSWF3.js} +8 -8
  81. package/dist/_node-chunks/{chunk-B3LK7C7B.js → chunk-NZ7EQWYA.js} +9 -9
  82. package/dist/_node-chunks/{chunk-U5QMVW3H.js → chunk-OLGIDCVD.js} +650 -9
  83. package/dist/_node-chunks/{chunk-NAYTBC72.js → chunk-P65JVLO3.js} +8 -8
  84. package/dist/_node-chunks/{chunk-M2UZP5GC.js → chunk-PAN35AYX.js} +7 -7
  85. package/dist/_node-chunks/{chunk-GZBUCUF7.js → chunk-PLWLCVP2.js} +6 -6
  86. package/dist/_node-chunks/{chunk-A4YELYR3.js → chunk-Q4BEWGMK.js} +6 -6
  87. package/dist/_node-chunks/{chunk-YYIZ2PC4.js → chunk-QNUXGVZZ.js} +6 -6
  88. package/dist/_node-chunks/{chunk-WHZWLJGO.js → chunk-R5DWO2S2.js} +31 -30
  89. package/dist/_node-chunks/{chunk-RMLENEZC.js → chunk-SLZV7PTQ.js} +8 -8
  90. package/dist/_node-chunks/{chunk-B5VFV3ZW.js → chunk-TIRP5JQM.js} +11 -10
  91. package/dist/_node-chunks/{chunk-TLVEPWBN.js → chunk-TMXWDY2O.js} +6 -6
  92. package/dist/_node-chunks/{chunk-LGUMVMBA.js → chunk-TN3ULFFZ.js} +6 -6
  93. package/dist/_node-chunks/{chunk-5ZLOPVTG.js → chunk-TPSJW4CQ.js} +6 -6
  94. package/dist/_node-chunks/{chunk-RNF3Z4ZJ.js → chunk-TYBPAV3X.js} +6 -6
  95. package/dist/_node-chunks/chunk-UUE3PSJB.js +11 -0
  96. package/dist/_node-chunks/chunk-VKNRNBTB.js +18 -0
  97. package/dist/_node-chunks/{chunk-6Y6RBJD7.js → chunk-VPU4E7DI.js} +25 -8
  98. package/dist/_node-chunks/{chunk-FJDJE7XC.js → chunk-WIQ6Y3NX.js} +6 -6
  99. package/dist/_node-chunks/{chunk-DD2S4BFV.js → chunk-WRG3CFGS.js} +6 -6
  100. package/dist/_node-chunks/{chunk-FAZ3MUOI.js → chunk-X3RTVNRN.js} +7 -7
  101. package/dist/_node-chunks/chunk-XOGU5PWI.js +347 -0
  102. package/dist/_node-chunks/{chunk-AU3SF2WM.js → chunk-XWGMQW2H.js} +6 -6
  103. package/dist/_node-chunks/chunk-YCXTTQ7K.js +620 -0
  104. package/dist/_node-chunks/{chunk-KZBZYQTZ.js → chunk-YHH57LHY.js} +9 -9
  105. package/dist/_node-chunks/{chunk-J3M3X7GO.js → chunk-YMZ2SGFK.js} +6 -6
  106. package/dist/_node-chunks/{chunk-AY6B2C46.js → chunk-YNENOZRY.js} +7 -7
  107. package/dist/_node-chunks/{chunk-CGWACHNW.js → chunk-YPGVYNJB.js} +6 -6
  108. package/dist/_node-chunks/{chunk-OQ4NCWE4.js → chunk-YQDBSAXW.js} +7 -7
  109. package/dist/_node-chunks/{chunk-YGXJOSRU.js → chunk-Z4NZLBOX.js} +7 -7
  110. package/dist/_node-chunks/{chunk-74IEHSIR.js → chunk-ZC3ZZKMS.js} +8 -8
  111. package/dist/_node-chunks/{chunk-QDLR4JF5.js → chunk-ZCITDAV4.js} +34 -949
  112. package/dist/_node-chunks/chunk-ZNSGFYAT.js +25 -0
  113. package/dist/_node-chunks/{chunk-XD5SYXAU.js → chunk-ZSH6BUCW.js} +25 -25
  114. package/dist/_node-chunks/{chunk-X2KWNNFB.js → chunk-ZTFNOXZF.js} +6 -6
  115. package/dist/_node-chunks/dist-GGTGKXZA.js +27 -0
  116. package/dist/_node-chunks/dist-NS676VJR.js +16 -0
  117. package/dist/_node-chunks/{local-runtime-KTI3DH6X.js → local-runtime-BUTEKJYV.js} +20 -20
  118. package/dist/_node-chunks/{mdx-plugin-2E3SW5TL.js → mdx-plugin-7WXQIHPV.js} +2263 -130
  119. package/dist/_node-chunks/{monorepo-MWAMFHKY.js → monorepo-NCD3X2BR.js} +11 -11
  120. package/dist/_node-chunks/{monorepo-optimized-tests-relaxed-limits-no-story-deletion-MGORG6W7.js → monorepo-optimized-tests-relaxed-limits-no-story-deletion-SD3B272K.js} +11 -11
  121. package/dist/_node-chunks/optimized-tests-ITVOHEOA.js +22 -0
  122. package/dist/_node-chunks/{pattern-copy-play-QTQOY7E7.js → pattern-copy-play-3QJANDJD.js} +9 -9
  123. package/dist/_node-chunks/postinstallAddon-LEUHOKX6.js +20 -0
  124. package/dist/_node-chunks/{rehype-external-links-T7DZNKMB.js → rehype-external-links-4LR5BDR2.js} +9 -9
  125. package/dist/_node-chunks/{rehype-slug-CSHI5WYI.js → rehype-slug-PWFRGOEV.js} +9 -9
  126. package/dist/_node-chunks/{relaxed-limits-RAZD36YR.js → relaxed-limits-VNNWUW7X.js} +11 -11
  127. package/dist/_node-chunks/{run-S6XSLPEB.js → run-RUAAWEQT.js} +13 -13
  128. package/dist/_node-chunks/{run-KJ3Z2TTY.js → run-YK6ARCWS.js} +17 -17
  129. package/dist/_node-chunks/session-id-JJYVZAKO.js +23 -0
  130. package/dist/_node-chunks/{setup-35J66GFB.js → setup-4QKCICV6.js} +8 -8
  131. package/dist/_node-chunks/{vitest.config.4.template-Z7OCRDKD.js → vitest.config.4.template-WVFLIXN7.js} +7 -7
  132. package/dist/actions/decorator.js +2 -1
  133. package/dist/actions/index.js +2 -1
  134. package/dist/addon-a11y/index.js +2 -1
  135. package/dist/addon-a11y/manager.js +24 -17
  136. package/dist/addon-a11y/preset.js +7 -7
  137. package/dist/addon-a11y/preview.js +2 -1
  138. package/dist/addon-docs/blocks.js +46 -25
  139. package/dist/addon-docs/manager.js +2 -2
  140. package/dist/addon-docs/preset.js +10 -10
  141. package/dist/addon-links/index.js +3 -2
  142. package/dist/addon-links/preview.d.ts +1 -1
  143. package/dist/addon-links/preview.js +3 -2
  144. package/dist/addon-links/react/index.js +2 -1
  145. package/dist/addon-mcp/preset.js +8 -8
  146. package/dist/addon-mcp/tools/preview-stories/preview-stories-app-script.js +17 -45
  147. package/dist/addon-ondevice-actions/index.js +5 -1
  148. package/dist/addon-ondevice-actions/register.js +5 -1
  149. package/dist/addon-pseudo-states/manager.js +2 -2
  150. package/dist/addon-pseudo-states/preview.d.ts +1 -1
  151. package/dist/addon-themes/manager.js +1 -1
  152. package/dist/addon-themes/postinstall.js +7 -7
  153. package/dist/addon-vitest/constants.js +8 -8
  154. package/dist/addon-vitest/manager.js +8 -8
  155. package/dist/addon-vitest/node/coverage-reporter.js +8 -8
  156. package/dist/addon-vitest/node/vitest.js +16 -16
  157. package/dist/addon-vitest/postinstall.js +10 -10
  158. package/dist/addon-vitest/preset.js +15 -16
  159. package/dist/addon-vitest/vitest-plugin/global-setup.js +7 -7
  160. package/dist/addon-vitest/vitest-plugin/index.js +17 -17
  161. package/dist/babel/index.d.ts +91 -842
  162. package/dist/babel/index.js +13 -19
  163. package/dist/bin/core.js +61 -60
  164. package/dist/bin/dispatcher.js +10 -10
  165. package/dist/bin/loader.js +16 -15
  166. package/dist/builder-vite/index.js +15 -15
  167. package/dist/builder-vite/preset.js +13 -13
  168. package/dist/{chunk-DF6btpT3.d.ts → chunk-BGhyFTJO.d.ts} +2 -2
  169. package/dist/chunk-CV4-Z2pn.d.ts +30 -0
  170. package/dist/{chunk-DvufcbCc.d.ts → chunk-CVY28Ngy.d.ts} +1 -1
  171. package/dist/{chunk-B2t1tGRh.d.ts → chunk-CYuvV2sR.d.ts} +11 -13
  172. package/dist/{chunk-BYnH2sbb.d.ts → chunk-ClI-HEh5.d.ts} +1 -1
  173. package/dist/{chunk-DIz17UEJ.d.ts → chunk-CzmZhVrn.d.ts} +35 -1
  174. package/dist/{chunk-B2xylxt5.d.ts → chunk-DROZ9oel.d.ts} +7 -271
  175. package/dist/cli/index.d.ts +13 -866
  176. package/dist/cli/index.js +42 -4952
  177. package/dist/cli/tools/sdk/child-host.d.ts +1 -1
  178. package/dist/cli/tools/sdk/child-host.js +17 -17
  179. package/dist/cli/tools/sdk/index.d.ts +1 -1
  180. package/dist/cli/tools/sdk/index.js +18 -18
  181. package/dist/cli-commands/bin/index.js +7 -7
  182. package/dist/client-logger/index.js +3 -1
  183. package/dist/common/index.d.ts +5 -4
  184. package/dist/common/index.js +35 -37
  185. package/dist/components/index.d.ts +14 -231
  186. package/dist/components/index.js +2518 -8365
  187. package/dist/core-events/index.d.ts +4 -3
  188. package/dist/core-events/index.js +3 -1
  189. package/dist/core-server/index.d.ts +2 -2
  190. package/dist/core-server/index.js +450 -147
  191. package/dist/core-server/presets/common-manager.js +96 -894
  192. package/dist/core-server/presets/common-override-preset.js +12 -10
  193. package/dist/core-server/presets/common-preset.js +39 -40
  194. package/dist/create/bin/index.js +7 -7
  195. package/dist/create/index.js +15 -15
  196. package/dist/csf/index.d.ts +2 -2
  197. package/dist/csf/index.js +27 -93
  198. package/dist/csf-tools/index.d.ts +2 -12
  199. package/dist/csf-tools/index.js +14 -14
  200. package/dist/instrumenter/index.js +3 -1
  201. package/dist/manager/_manager-chunks/{globals-runtime-dKGpUUSb.js → globals-runtime-B-IeQLQu.js} +285 -61
  202. package/dist/manager/_manager-chunks/{globals-runtime-DuLFjsF4.js → globals-runtime-B5-0Ccbv.js} +1 -1
  203. package/dist/manager/_manager-chunks/{globals-runtime-8HkdnU2F.js → globals-runtime-B71TiXST.js} +93 -2146
  204. package/dist/manager/_manager-chunks/globals-runtime-BMCaBukU.js +413 -0
  205. package/dist/manager/_manager-chunks/globals-runtime-BUP5e_t9.js +1396 -0
  206. package/dist/manager/_manager-chunks/globals-runtime-C7mqoHpE.js +2093 -0
  207. package/dist/manager/_manager-chunks/globals-runtime-CBviMKtt.js +446 -0
  208. package/dist/manager/_manager-chunks/{globals-runtime-eLPTIfX-.js → globals-runtime-CYNosEiD.js} +1 -2
  209. package/dist/manager/_manager-chunks/globals-runtime-C_evJrEn.js +1960 -0
  210. package/dist/manager/_manager-chunks/{globals-runtime-C02fvgcd.js → globals-runtime-CdgVeAbk.js} +408 -377
  211. package/dist/manager/_manager-chunks/{globals-runtime-BmphMP6z.js → globals-runtime-Cqn8KdSZ.js} +4 -4
  212. package/dist/manager/_manager-chunks/{globals-runtime-ZHrQFa3-.js → globals-runtime-CrIF09P8.js} +1246 -539
  213. package/dist/manager/_manager-chunks/{globals-runtime-BvM-NY2g.js → globals-runtime-Ct1kY4wb.js} +638 -1731
  214. package/dist/manager/_manager-chunks/globals-runtime-CvyFEPIY.js +5282 -0
  215. package/dist/manager/_manager-chunks/{globals-runtime-FC201B7s.js → globals-runtime-DMBjo1QS.js} +2 -1
  216. package/dist/manager/_manager-chunks/{globals-runtime-C9P2ZbMM.js → globals-runtime-DUK6bGcb.js} +52 -25
  217. package/dist/manager/_manager-chunks/globals-runtime-DedfO-DP.js +3414 -0
  218. package/dist/manager/_manager-chunks/{globals-runtime-q5R9dawi.js → globals-runtime-DqhIYwLp.js} +165 -152
  219. package/dist/manager/_manager-chunks/globals-runtime-XSxCU7PR.js +41 -0
  220. package/dist/manager/_manager-chunks/runtime-BR5z0WoJ.js +456 -0
  221. package/dist/manager/_manager-chunks/{runtime-DdCaBowH.js → runtime-BgYvp1WN.js} +15 -7
  222. package/dist/manager/_manager-chunks/{runtime-BGvLm94o.js → runtime-CHI-LHF1.js} +3 -3
  223. package/dist/manager/_manager-chunks/{runtime-BdLdsHca.js → runtime-CUymj6EY.js} +280 -288
  224. package/dist/manager/_manager-chunks/runtime-CaU1DSEZ.js +528 -0
  225. package/dist/manager/_manager-chunks/{runtime-DMig8mT7.js → runtime-CqItbdKW.js} +3 -2
  226. package/dist/manager/_manager-chunks/{runtime-B9QzcYO3.js → runtime-D4ZOOIV0.js} +5 -531
  227. package/dist/manager/_manager-chunks/{runtime-50_aob4S.js → runtime-DER98nV0.js} +3 -19
  228. package/dist/manager/_manager-chunks/{runtime-CE2sHVqs.js → runtime-DrTLBe7a.js} +39 -40
  229. package/dist/manager/_manager-chunks/runtime-MAf7Wpk5.js +692 -0
  230. package/dist/manager/_manager-chunks/{runtime-CKP1i0--.js → runtime-cVFIMcca.js} +1 -1
  231. package/dist/manager/globals-runtime.js +1 -1
  232. package/dist/manager/globals.d.ts +1 -1
  233. package/dist/manager/globals.js +1 -1
  234. package/dist/manager/runtime.js +1 -1
  235. package/dist/manager-api/index.d.ts +1 -1
  236. package/dist/manager-api/index.js +22 -28
  237. package/dist/manager-errors.d.ts +1 -1
  238. package/dist/mcp/index.js +8 -8
  239. package/dist/mocking-utils/index.js +16 -11
  240. package/dist/nextjs-vite/index.js +3 -2
  241. package/dist/nextjs-vite/node/index.js +7 -7
  242. package/dist/nextjs-vite/preset.js +11 -11
  243. package/dist/nextjs-vite/vite-plugin/index.js +7 -7
  244. package/dist/nextjs-vite-plugin/index.d.ts +1 -2
  245. package/dist/nextjs-vite-plugin/index.js +12 -27
  246. package/dist/nextjs-vite-plugin/mocks/storybook.global.js +8 -8
  247. package/dist/node-logger/index.d.ts +65 -72
  248. package/dist/node-logger/index.js +11 -12
  249. package/dist/oxc-parser/index.js +11 -13
  250. package/dist/oxc-parser/worker.js +10 -10
  251. package/dist/preview/_chunks/{runtime-DVM_AHbR.js → runtime-6P-h06Te.js} +51 -50
  252. package/dist/preview/_chunks/{runtime-BoxmlDdB.js → runtime-B9KKIDGa.js} +202 -81
  253. package/dist/preview/_chunks/{runtime-BIzIdDbb.js → runtime-BPwAnlRx.js} +482 -334
  254. package/dist/preview/_chunks/{runtime-q3wt0e_N.js → runtime-BUnOhg9h.js} +2 -2
  255. package/dist/preview/_chunks/runtime-Bcv1hJky.js +6305 -0
  256. package/dist/preview/_chunks/{runtime-CqHxptiK.js → runtime-C1jgT6tJ.js} +93 -2145
  257. package/dist/preview/_chunks/{runtime-D7B4bVe_.js → runtime-C8QFpkFV.js} +6 -6
  258. package/dist/preview/_chunks/{runtime-CijtAN7R.js → runtime-DdqR8Fd0.js} +15 -6
  259. package/dist/preview/_chunks/{runtime-B3y8ocOg.js → runtime-DvBfMhis.js} +2 -2
  260. package/dist/preview/_chunks/{runtime-BZSnICCg.js → runtime-WapFVPAh.js} +29 -29
  261. package/dist/preview/runtime.js +1 -1
  262. package/dist/preview-api/index.d.ts +1 -1
  263. package/dist/preview-api/index.js +2 -1
  264. package/dist/preview-errors.d.ts +1 -1
  265. package/dist/react/docgen/docgen-worker.js +11 -12
  266. package/dist/react/entry-preview.js +2 -1
  267. package/dist/react/index.js +6 -4
  268. package/dist/react/preset.js +13 -14
  269. package/dist/react/preview.js +3 -2
  270. package/dist/react-native/bin/get-stories.js +8 -8
  271. package/dist/react-native/index.js +25 -211
  272. package/dist/react-native/metro/node.js +10 -9
  273. package/dist/react-native/metro/withStorybook.js +11 -10
  274. package/dist/react-native/scripts/generate.js +8 -8
  275. package/dist/react-vite/node/index.js +7 -7
  276. package/dist/react-vite/preset.js +7 -7
  277. package/dist/router/index.js +3 -1
  278. package/dist/server-errors.d.ts +1 -1
  279. package/dist/server-errors.js +9 -9
  280. package/dist/shared/open-service/index.d.ts +1 -1
  281. package/dist/shared/open-service/services/docgen/worker/docgen-worker.js +9 -9
  282. package/dist/telemetry/index.js +43 -45
  283. package/dist/test/index.js +808 -573
  284. package/dist/theming/create.js +2 -1
  285. package/dist/theming/index.js +22 -1
  286. package/dist/types/index.d.ts +1 -1
  287. package/package.json +17 -45
  288. package/dist/_browser-chunks/WithTooltip-523JD6VH.js +0 -1619
  289. package/dist/_browser-chunks/chunk-5P4QA6MY.js +0 -20
  290. package/dist/_browser-chunks/chunk-UDQ3XQFC.js +0 -108
  291. package/dist/_node-chunks/chunk-7XCEKQGV.js +0 -18
  292. package/dist/_node-chunks/chunk-EGS2SAD2.js +0 -5414
  293. package/dist/_node-chunks/chunk-GKTCJPLL.js +0 -36
  294. package/dist/_node-chunks/chunk-HENM5ZK3.js +0 -1877
  295. package/dist/_node-chunks/chunk-HQM4ISVU.js +0 -11
  296. package/dist/_node-chunks/chunk-K3I3G4VL.js +0 -4731
  297. package/dist/_node-chunks/chunk-MZMPFII2.js +0 -29
  298. package/dist/_node-chunks/chunk-NYAWUR6L.js +0 -3823
  299. package/dist/_node-chunks/chunk-NYRUWAL3.js +0 -23
  300. package/dist/_node-chunks/chunk-SSZ5REKS.js +0 -3008
  301. package/dist/_node-chunks/chunk-WEW23EEE.js +0 -662
  302. package/dist/_node-chunks/chunk-XWQEWRFD.js +0 -51
  303. package/dist/_node-chunks/dist-CNA633FI.js +0 -16
  304. package/dist/_node-chunks/globby-HRQV5N3V.js +0 -2884
  305. package/dist/_node-chunks/jiti-WE7NHS2Y.js +0 -3848
  306. package/dist/_node-chunks/lib-7MVA6CTW.js +0 -366
  307. package/dist/_node-chunks/optimized-tests-IAX6YURR.js +0 -22
  308. package/dist/_node-chunks/postinstallAddon-ROH2TBJX.js +0 -20
  309. package/dist/_node-chunks/session-id-GM226DGP.js +0 -23
  310. package/dist/chunk-BfBzpgct.d.ts +0 -916
  311. package/dist/core-server/presets/common-manager.css +0 -170
  312. package/dist/manager/_manager-chunks/globals-runtime-BIKBO23x.js +0 -3389
  313. package/dist/manager/_manager-chunks/globals-runtime-DkAPXCvc.js +0 -9766
  314. package/dist/manager/_manager-chunks/globals-runtime-DtcOnYHR.js +0 -5357
  315. package/dist/manager/_manager-chunks/runtime-89Cb0A8U.js +0 -998
  316. package/dist/manager/_manager-chunks/runtime-wL4UO7YO.js +0 -452
  317. package/dist/preview/_chunks/runtime-BTPtVY1p.js +0 -1102
  318. package/dist/preview/_chunks/runtime-DZToXfvO.js +0 -9767
@@ -1,3389 +0,0 @@
1
- import { a as __toESM, n as __esmMin } from "./globals-runtime-BdGkqNEt.js";
2
- import { A as require_react_dom, j as require_react } from "./globals-runtime-ZHrQFa3-.js";
3
- //#region ../../node_modules/@floating-ui/utils/dist/floating-ui.utils.dom.mjs
4
- function hasWindow() {
5
- return typeof window !== "undefined";
6
- }
7
- function getNodeName$1(node) {
8
- if (isNode(node)) return (node.nodeName || "").toLowerCase();
9
- return "#document";
10
- }
11
- function getWindow$1(node) {
12
- var _node$ownerDocument;
13
- return (node == null || (_node$ownerDocument = node.ownerDocument) == null ? void 0 : _node$ownerDocument.defaultView) || window;
14
- }
15
- function getDocumentElement$1(node) {
16
- var _ref;
17
- return (_ref = (isNode(node) ? node.ownerDocument : node.document) || window.document) == null ? void 0 : _ref.documentElement;
18
- }
19
- function isNode(value) {
20
- if (!hasWindow()) return false;
21
- return value instanceof Node || value instanceof getWindow$1(value).Node;
22
- }
23
- function isElement$1(value) {
24
- if (!hasWindow()) return false;
25
- return value instanceof Element || value instanceof getWindow$1(value).Element;
26
- }
27
- function isHTMLElement$1(value) {
28
- if (!hasWindow()) return false;
29
- return value instanceof HTMLElement || value instanceof getWindow$1(value).HTMLElement;
30
- }
31
- function isShadowRoot$1(value) {
32
- if (!hasWindow() || typeof ShadowRoot === "undefined") return false;
33
- return value instanceof ShadowRoot || value instanceof getWindow$1(value).ShadowRoot;
34
- }
35
- function isOverflowElement(element) {
36
- const { overflow, overflowX, overflowY, display } = getComputedStyle$2(element);
37
- return /auto|scroll|overlay|hidden|clip/.test(overflow + overflowY + overflowX) && display !== "inline" && display !== "contents";
38
- }
39
- function isTableElement$1(element) {
40
- return /^(table|td|th)$/.test(getNodeName$1(element));
41
- }
42
- function isTopLayer(element) {
43
- try {
44
- if (element.matches(":popover-open")) return true;
45
- } catch (_e) {}
46
- try {
47
- return element.matches(":modal");
48
- } catch (_e) {
49
- return false;
50
- }
51
- }
52
- function isContainingBlock(elementOrCss) {
53
- const css = isElement$1(elementOrCss) ? getComputedStyle$2(elementOrCss) : elementOrCss;
54
- return isNotNone(css.transform) || isNotNone(css.translate) || isNotNone(css.scale) || isNotNone(css.rotate) || isNotNone(css.perspective) || !isWebKit() && (isNotNone(css.backdropFilter) || isNotNone(css.filter)) || willChangeRe.test(css.willChange || "") || containRe.test(css.contain || "");
55
- }
56
- function getContainingBlock$1(element) {
57
- let currentNode = getParentNode$1(element);
58
- while (isHTMLElement$1(currentNode) && !isLastTraversableNode(currentNode)) {
59
- if (isContainingBlock(currentNode)) return currentNode;
60
- else if (isTopLayer(currentNode)) return null;
61
- currentNode = getParentNode$1(currentNode);
62
- }
63
- return null;
64
- }
65
- function isWebKit() {
66
- if (isWebKitValue == null) isWebKitValue = typeof CSS !== "undefined" && CSS.supports && CSS.supports("-webkit-backdrop-filter", "none");
67
- return isWebKitValue;
68
- }
69
- function isLastTraversableNode(node) {
70
- return /^(html|body|#document)$/.test(getNodeName$1(node));
71
- }
72
- function getComputedStyle$2(element) {
73
- return getWindow$1(element).getComputedStyle(element);
74
- }
75
- function getNodeScroll$1(element) {
76
- if (isElement$1(element)) return {
77
- scrollLeft: element.scrollLeft,
78
- scrollTop: element.scrollTop
79
- };
80
- return {
81
- scrollLeft: element.scrollX,
82
- scrollTop: element.scrollY
83
- };
84
- }
85
- function getParentNode$1(node) {
86
- if (getNodeName$1(node) === "html") return node;
87
- const result = node.assignedSlot || node.parentNode || isShadowRoot$1(node) && node.host || getDocumentElement$1(node);
88
- return isShadowRoot$1(result) ? result.host : result;
89
- }
90
- function getNearestOverflowAncestor(node) {
91
- const parentNode = getParentNode$1(node);
92
- if (isLastTraversableNode(parentNode)) return (node.ownerDocument || node).body;
93
- if (isHTMLElement$1(parentNode) && isOverflowElement(parentNode)) return parentNode;
94
- return getNearestOverflowAncestor(parentNode);
95
- }
96
- function getOverflowAncestors(node, list, traverseIframes) {
97
- var _node$ownerDocument2;
98
- if (list === void 0) list = [];
99
- if (traverseIframes === void 0) traverseIframes = true;
100
- const scrollableAncestor = getNearestOverflowAncestor(node);
101
- const isBody = scrollableAncestor === ((_node$ownerDocument2 = node.ownerDocument) == null ? void 0 : _node$ownerDocument2.body);
102
- const win = getWindow$1(scrollableAncestor);
103
- if (isBody) {
104
- const frameElement = getFrameElement(win);
105
- return list.concat(win, win.visualViewport || [], isOverflowElement(scrollableAncestor) ? scrollableAncestor : [], frameElement && traverseIframes ? getOverflowAncestors(frameElement) : []);
106
- } else return list.concat(scrollableAncestor, getOverflowAncestors(scrollableAncestor, [], traverseIframes));
107
- }
108
- function getFrameElement(win) {
109
- return win.parent && Object.getPrototypeOf(win.parent) ? win.frameElement : null;
110
- }
111
- var willChangeRe, containRe, isNotNone, isWebKitValue;
112
- function init_floating_ui_utils_dom() {
113
- return (init_floating_ui_utils_dom = __esmMin((() => {
114
- willChangeRe = /transform|translate|scale|rotate|perspective|filter/;
115
- containRe = /paint|layout|strict|content/;
116
- isNotNone = (value) => !!value && value !== "none";
117
- })))();
118
- }
119
- //#endregion
120
- //#region ../../node_modules/@floating-ui/utils/dist/floating-ui.utils.mjs
121
- function clamp(start, value, end) {
122
- return max$1(start, min$1(value, end));
123
- }
124
- function evaluate(value, param) {
125
- return typeof value === "function" ? value(param) : value;
126
- }
127
- function getSide(placement) {
128
- return placement.split("-")[0];
129
- }
130
- function getAlignment(placement) {
131
- return placement.split("-")[1];
132
- }
133
- function getOppositeAxis(axis) {
134
- return axis === "x" ? "y" : "x";
135
- }
136
- function getAxisLength(axis) {
137
- return axis === "y" ? "height" : "width";
138
- }
139
- function getSideAxis(placement) {
140
- const firstChar = placement[0];
141
- return firstChar === "t" || firstChar === "b" ? "y" : "x";
142
- }
143
- function getAlignmentAxis(placement) {
144
- return getOppositeAxis(getSideAxis(placement));
145
- }
146
- function getAlignmentSides(placement, rects, rtl) {
147
- if (rtl === void 0) rtl = false;
148
- const alignment = getAlignment(placement);
149
- const alignmentAxis = getAlignmentAxis(placement);
150
- const length = getAxisLength(alignmentAxis);
151
- let mainAlignmentSide = alignmentAxis === "x" ? alignment === (rtl ? "end" : "start") ? "right" : "left" : alignment === "start" ? "bottom" : "top";
152
- if (rects.reference[length] > rects.floating[length]) mainAlignmentSide = getOppositePlacement$1(mainAlignmentSide);
153
- return [mainAlignmentSide, getOppositePlacement$1(mainAlignmentSide)];
154
- }
155
- function getExpandedPlacements(placement) {
156
- const oppositePlacement = getOppositePlacement$1(placement);
157
- return [
158
- getOppositeAlignmentPlacement(placement),
159
- oppositePlacement,
160
- getOppositeAlignmentPlacement(oppositePlacement)
161
- ];
162
- }
163
- function getOppositeAlignmentPlacement(placement) {
164
- return placement.includes("start") ? placement.replace("start", "end") : placement.replace("end", "start");
165
- }
166
- function getSideList(side, isStart, rtl) {
167
- switch (side) {
168
- case "top":
169
- case "bottom":
170
- if (rtl) return isStart ? rlPlacement : lrPlacement;
171
- return isStart ? lrPlacement : rlPlacement;
172
- case "left":
173
- case "right": return isStart ? tbPlacement : btPlacement;
174
- default: return [];
175
- }
176
- }
177
- function getOppositeAxisPlacements(placement, flipAlignment, direction, rtl) {
178
- const alignment = getAlignment(placement);
179
- let list = getSideList(getSide(placement), direction === "start", rtl);
180
- if (alignment) {
181
- list = list.map((side) => side + "-" + alignment);
182
- if (flipAlignment) list = list.concat(list.map(getOppositeAlignmentPlacement));
183
- }
184
- return list;
185
- }
186
- function getOppositePlacement$1(placement) {
187
- const side = getSide(placement);
188
- return oppositeSideMap[side] + placement.slice(side.length);
189
- }
190
- function expandPaddingObject(padding) {
191
- var _padding$top, _padding$right, _padding$bottom, _padding$left;
192
- return {
193
- top: (_padding$top = padding.top) != null ? _padding$top : 0,
194
- right: (_padding$right = padding.right) != null ? _padding$right : 0,
195
- bottom: (_padding$bottom = padding.bottom) != null ? _padding$bottom : 0,
196
- left: (_padding$left = padding.left) != null ? _padding$left : 0
197
- };
198
- }
199
- function getPaddingObject(padding) {
200
- return typeof padding !== "number" ? expandPaddingObject(padding) : {
201
- top: padding,
202
- right: padding,
203
- bottom: padding,
204
- left: padding
205
- };
206
- }
207
- function rectToClientRect$1(rect) {
208
- const { x, y, width, height } = rect;
209
- return {
210
- width,
211
- height,
212
- top: y,
213
- left: x,
214
- right: x + width,
215
- bottom: y + height,
216
- x,
217
- y
218
- };
219
- }
220
- var min$1, max$1, round$1, floor, createCoords, oppositeSideMap, lrPlacement, rlPlacement, tbPlacement, btPlacement;
221
- function init_floating_ui_utils() {
222
- return (init_floating_ui_utils = __esmMin((() => {
223
- min$1 = Math.min;
224
- max$1 = Math.max;
225
- round$1 = Math.round;
226
- floor = Math.floor;
227
- createCoords = (v) => ({
228
- x: v,
229
- y: v
230
- });
231
- oppositeSideMap = {
232
- left: "right",
233
- right: "left",
234
- bottom: "top",
235
- top: "bottom"
236
- };
237
- lrPlacement = ["left", "right"];
238
- rlPlacement = ["right", "left"];
239
- tbPlacement = ["top", "bottom"];
240
- btPlacement = ["bottom", "top"];
241
- })))();
242
- }
243
- //#endregion
244
- //#region ../../node_modules/@preact/signals-core/dist/signals-core.module.js
245
- function t() {
246
- if (!(v > 1)) {
247
- var i, t = !1;
248
- (function() {
249
- var i = c;
250
- c = void 0;
251
- while (void 0 !== i) {
252
- var t = i.S;
253
- if (t.v === i.v) {
254
- for (var n = t.t; void 0 !== n; n = n.x) if (n.i === i.i) n.i = t.i;
255
- }
256
- i = i.o;
257
- }
258
- })();
259
- while (void 0 !== h) {
260
- var n = h;
261
- h = void 0;
262
- s++;
263
- while (void 0 !== n) {
264
- var r = n.u;
265
- n.u = void 0;
266
- n.f &= -3;
267
- if (!(8 & n.f) && w(n)) try {
268
- n.c();
269
- } catch (n) {
270
- if (!t) {
271
- i = n;
272
- t = !0;
273
- }
274
- }
275
- n = r;
276
- }
277
- }
278
- s = 0;
279
- v--;
280
- if (t) throw i;
281
- } else v--;
282
- }
283
- function n(i) {
284
- if (v > 0) return i();
285
- e = ++u;
286
- v++;
287
- try {
288
- return i();
289
- } finally {
290
- t();
291
- }
292
- }
293
- function f(i) {
294
- var t = o, n = r;
295
- o = void 0;
296
- r = void 0;
297
- try {
298
- return i();
299
- } finally {
300
- o = t;
301
- r = n;
302
- }
303
- }
304
- function a(i) {
305
- if (void 0 !== o) {
306
- var t = i.n;
307
- if (void 0 === t || t.t !== o) {
308
- t = {
309
- i: 0,
310
- S: i,
311
- p: o.s,
312
- n: void 0,
313
- t: o,
314
- e: void 0,
315
- x: void 0,
316
- r: t
317
- };
318
- if (void 0 !== o.s) o.s.n = t;
319
- o.s = t;
320
- i.n = t;
321
- if (32 & o.f) i.S(t);
322
- return t;
323
- } else if (-1 === t.i) {
324
- t.i = 0;
325
- if (void 0 !== t.n) {
326
- t.n.p = t.p;
327
- if (void 0 !== t.p) t.p.n = t.n;
328
- t.p = o.s;
329
- t.n = void 0;
330
- o.s.n = t;
331
- o.s = t;
332
- }
333
- return t;
334
- }
335
- }
336
- }
337
- function l(i, t) {
338
- this.v = i;
339
- this.i = 0;
340
- this.n = void 0;
341
- this.t = void 0;
342
- this.l = 0;
343
- this.W = null == t ? void 0 : t.watched;
344
- this.Z = null == t ? void 0 : t.unwatched;
345
- this.name = null == t ? void 0 : t.name;
346
- }
347
- function y(i, t) {
348
- return new l(i, t);
349
- }
350
- function w(i) {
351
- for (var t = i.s; void 0 !== t; t = t.n) if (t.S.i !== t.i || !t.S.h() || t.S.i !== t.i) return !0;
352
- return !1;
353
- }
354
- function _(i) {
355
- for (var t = i.s; void 0 !== t; t = t.n) {
356
- var n = t.S.n;
357
- if (void 0 !== n) t.r = n;
358
- t.S.n = t;
359
- t.i = -1;
360
- if (void 0 === t.n) {
361
- i.s = t;
362
- break;
363
- }
364
- }
365
- }
366
- function b(i) {
367
- var t = i.s, n = void 0;
368
- while (void 0 !== t) {
369
- var r = t.p;
370
- if (-1 === t.i) {
371
- t.S.U(t);
372
- if (void 0 !== r) r.n = t.n;
373
- if (void 0 !== t.n) t.n.p = r;
374
- } else n = t;
375
- t.S.n = t.r;
376
- if (void 0 !== t.r) t.r = void 0;
377
- t = r;
378
- }
379
- i.s = n;
380
- }
381
- function p(i, t) {
382
- l.call(this, void 0, t);
383
- this.x = i;
384
- this.s = void 0;
385
- this.g = d - 1;
386
- this.f = 4;
387
- }
388
- function g(i, t) {
389
- return new p(i, t);
390
- }
391
- function S(i) {
392
- var n = i.m;
393
- i.m = void 0;
394
- if ("function" == typeof n) {
395
- v++;
396
- var r = o;
397
- o = void 0;
398
- try {
399
- n();
400
- } catch (t) {
401
- i.f &= -2;
402
- i.f |= 8;
403
- m(i);
404
- throw t;
405
- } finally {
406
- o = r;
407
- t();
408
- }
409
- }
410
- }
411
- function m(i) {
412
- for (var t = i.s; void 0 !== t; t = t.n) t.S.U(t);
413
- i.x = void 0;
414
- i.s = void 0;
415
- S(i);
416
- }
417
- function x(i) {
418
- if (o !== this) throw new Error("Out-of-order effect");
419
- b(this);
420
- o = i;
421
- this.f &= -2;
422
- if (8 & this.f) m(this);
423
- t();
424
- }
425
- function E(i, t) {
426
- this.x = i;
427
- this.m = void 0;
428
- this.s = void 0;
429
- this.u = void 0;
430
- this.f = 32;
431
- this.name = null == t ? void 0 : t.name;
432
- if (r) r.push(this);
433
- }
434
- function j(i, t) {
435
- var n = new E(i, t);
436
- try {
437
- n.c();
438
- } catch (i) {
439
- n.d();
440
- throw i;
441
- }
442
- var r = n.d.bind(n);
443
- r[Symbol.dispose] = r;
444
- return r;
445
- }
446
- var i, r, o, h, v, s, u, e, c, d;
447
- function init_signals_core_module() {
448
- return (init_signals_core_module = __esmMin((() => {
449
- i = Symbol.for("preact-signals");
450
- o = void 0;
451
- h = void 0;
452
- v = 0;
453
- s = 0;
454
- u = 0;
455
- e = 0;
456
- c = void 0;
457
- d = 0;
458
- l.prototype.brand = i;
459
- l.prototype.h = function() {
460
- return !0;
461
- };
462
- l.prototype.S = function(i) {
463
- var t = this, n = this.t;
464
- if (n !== i && void 0 === i.e) {
465
- i.x = n;
466
- this.t = i;
467
- if (void 0 !== n) n.e = i;
468
- else f(function() {
469
- var i;
470
- null == (i = t.W) || i.call(t);
471
- });
472
- }
473
- };
474
- l.prototype.U = function(i) {
475
- var t = this;
476
- if (void 0 !== this.t) {
477
- var n = i.e, r = i.x;
478
- if (void 0 !== n) {
479
- n.x = r;
480
- i.e = void 0;
481
- }
482
- if (void 0 !== r) {
483
- r.e = n;
484
- i.x = void 0;
485
- }
486
- if (i === this.t) {
487
- this.t = r;
488
- if (void 0 === r) f(function() {
489
- var i;
490
- null == (i = t.Z) || i.call(t);
491
- });
492
- }
493
- }
494
- };
495
- l.prototype.subscribe = function(i) {
496
- var t = this;
497
- return j(function() {
498
- var n = t.value;
499
- f(function() {
500
- return i(n);
501
- });
502
- }, { name: "sub" });
503
- };
504
- l.prototype.valueOf = function() {
505
- return this.value;
506
- };
507
- l.prototype.toString = function() {
508
- return this.value + "";
509
- };
510
- l.prototype.toJSON = function() {
511
- return this.value;
512
- };
513
- l.prototype.peek = function() {
514
- var i = this;
515
- return f(function() {
516
- return i.value;
517
- });
518
- };
519
- Object.defineProperty(l.prototype, "value", {
520
- get: function() {
521
- var i = a(this);
522
- if (void 0 !== i) i.i = this.i;
523
- return this.v;
524
- },
525
- set: function(i) {
526
- if (i !== this.v) {
527
- if (s > 100) throw new Error("Cycle detected");
528
- (function(i) {
529
- if (0 !== v && 0 === s) {
530
- if (i.l !== e) {
531
- i.l = e;
532
- c = {
533
- S: i,
534
- v: i.v,
535
- i: i.i,
536
- o: c
537
- };
538
- }
539
- }
540
- })(this);
541
- this.v = i;
542
- this.i++;
543
- d++;
544
- v++;
545
- try {
546
- for (var n = this.t; void 0 !== n; n = n.x) n.t.N();
547
- } finally {
548
- t();
549
- }
550
- }
551
- }
552
- });
553
- p.prototype = new l();
554
- p.prototype.h = function() {
555
- this.f &= -3;
556
- if (1 & this.f) return !1;
557
- if (32 == (36 & this.f)) return !0;
558
- this.f &= -5;
559
- if (this.g === d) return !0;
560
- this.g = d;
561
- this.f |= 1;
562
- if (this.i > 0 && !w(this)) {
563
- this.f &= -2;
564
- return !0;
565
- }
566
- var i = o;
567
- try {
568
- _(this);
569
- o = this;
570
- var t = this.x();
571
- if (16 & this.f || this.v !== t || 0 === this.i) {
572
- this.v = t;
573
- this.f &= -17;
574
- this.i++;
575
- }
576
- } catch (i) {
577
- this.v = i;
578
- this.f |= 16;
579
- this.i++;
580
- }
581
- o = i;
582
- b(this);
583
- this.f &= -2;
584
- return !0;
585
- };
586
- p.prototype.S = function(i) {
587
- if (void 0 === this.t) {
588
- this.f |= 36;
589
- for (var t = this.s; void 0 !== t; t = t.n) t.S.S(t);
590
- }
591
- l.prototype.S.call(this, i);
592
- };
593
- p.prototype.U = function(i) {
594
- if (void 0 !== this.t) {
595
- l.prototype.U.call(this, i);
596
- if (void 0 === this.t) {
597
- this.f &= -33;
598
- for (var t = this.s; void 0 !== t; t = t.n) t.S.U(t);
599
- }
600
- }
601
- };
602
- p.prototype.N = function() {
603
- if (!(2 & this.f)) {
604
- this.f |= 6;
605
- for (var i = this.t; void 0 !== i; i = i.x) i.t.N();
606
- }
607
- };
608
- Object.defineProperty(p.prototype, "value", { get: function() {
609
- if (1 & this.f) throw new Error("Cycle detected");
610
- var i = a(this);
611
- this.h();
612
- if (void 0 !== i) i.i = this.i;
613
- if (16 & this.f) throw this.v;
614
- return this.v;
615
- } });
616
- E.prototype.c = function() {
617
- var i = this.S();
618
- try {
619
- if (8 & this.f) return;
620
- if (void 0 === this.x) return;
621
- var t = this.x();
622
- if ("function" == typeof t) this.m = t;
623
- } finally {
624
- i();
625
- }
626
- };
627
- E.prototype.S = function() {
628
- if (1 & this.f) throw new Error("Cycle detected");
629
- this.f |= 1;
630
- this.f &= -9;
631
- S(this);
632
- _(this);
633
- v++;
634
- var i = o;
635
- o = this;
636
- return x.bind(this, i);
637
- };
638
- E.prototype.N = function() {
639
- if (!(2 & this.f)) {
640
- this.f |= 2;
641
- this.u = h;
642
- h = this;
643
- }
644
- };
645
- E.prototype.d = function() {
646
- this.f |= 8;
647
- if (!(1 & this.f)) m(this);
648
- };
649
- E.prototype.dispose = function() {
650
- this.d();
651
- };
652
- })))();
653
- }
654
- //#endregion
655
- //#region ../../node_modules/@floating-ui/core/dist/floating-ui.core.mjs
656
- function computeCoordsFromPlacement(_ref, placement, rtl) {
657
- let { reference, floating } = _ref;
658
- const sideAxis = getSideAxis(placement);
659
- const alignmentAxis = getAlignmentAxis(placement);
660
- const alignLength = getAxisLength(alignmentAxis);
661
- const side = getSide(placement);
662
- const isVertical = sideAxis === "y";
663
- const commonX = reference.x + reference.width / 2 - floating.width / 2;
664
- const commonY = reference.y + reference.height / 2 - floating.height / 2;
665
- const commonAlign = reference[alignLength] / 2 - floating[alignLength] / 2;
666
- let coords;
667
- switch (side) {
668
- case "top":
669
- coords = {
670
- x: commonX,
671
- y: reference.y - floating.height
672
- };
673
- break;
674
- case "bottom":
675
- coords = {
676
- x: commonX,
677
- y: reference.y + reference.height
678
- };
679
- break;
680
- case "right":
681
- coords = {
682
- x: reference.x + reference.width,
683
- y: commonY
684
- };
685
- break;
686
- case "left":
687
- coords = {
688
- x: reference.x - floating.width,
689
- y: commonY
690
- };
691
- break;
692
- default: coords = {
693
- x: reference.x,
694
- y: reference.y
695
- };
696
- }
697
- const alignment = getAlignment(placement);
698
- if (alignment) coords[alignmentAxis] += commonAlign * (alignment === "end" ? 1 : -1) * (rtl && isVertical ? -1 : 1);
699
- return coords;
700
- }
701
- /**
702
- * Resolves with an object of overflow side offsets that determine how much the
703
- * element is overflowing a given clipping boundary on each side.
704
- * - positive = overflowing the boundary by that number of pixels
705
- * - negative = how many pixels left before it will overflow
706
- * - 0 = lies flush with the boundary
707
- * @see https://floating-ui.com/docs/detectOverflow
708
- */
709
- async function detectOverflow$1(state, options) {
710
- var _await$platform$isEle;
711
- if (options === void 0) options = {};
712
- const { x, y, platform, rects, elements, strategy } = state;
713
- const { boundary = "clippingAncestors", rootBoundary = "viewport", elementContext = "floating", altBoundary = false, padding = 0 } = evaluate(options, state);
714
- const paddingObject = getPaddingObject(padding);
715
- const element = elements[altBoundary ? elementContext === "floating" ? "reference" : "floating" : elementContext];
716
- const clippingClientRect = rectToClientRect$1(await platform.getClippingRect({
717
- element: ((_await$platform$isEle = await (platform.isElement == null ? void 0 : platform.isElement(element))) != null ? _await$platform$isEle : true) ? element : element.contextElement || await (platform.getDocumentElement == null ? void 0 : platform.getDocumentElement(elements.floating)),
718
- boundary,
719
- rootBoundary,
720
- strategy
721
- }));
722
- const rect = elementContext === "floating" ? {
723
- x,
724
- y,
725
- width: rects.floating.width,
726
- height: rects.floating.height
727
- } : rects.reference;
728
- const offsetParent = await (platform.getOffsetParent == null ? void 0 : platform.getOffsetParent(elements.floating));
729
- const offsetScale = await (platform.isElement == null ? void 0 : platform.isElement(offsetParent)) && await (platform.getScale == null ? void 0 : platform.getScale(offsetParent)) || {
730
- x: 1,
731
- y: 1
732
- };
733
- const elementClientRect = rectToClientRect$1(platform.convertOffsetParentRelativeRectToViewportRelativeRect ? await platform.convertOffsetParentRelativeRectToViewportRelativeRect({
734
- elements,
735
- rect,
736
- offsetParent,
737
- strategy
738
- }) : rect);
739
- return {
740
- top: (clippingClientRect.top - elementClientRect.top + paddingObject.top) / offsetScale.y,
741
- bottom: (elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom) / offsetScale.y,
742
- left: (clippingClientRect.left - elementClientRect.left + paddingObject.left) / offsetScale.x,
743
- right: (elementClientRect.right - clippingClientRect.right + paddingObject.right) / offsetScale.x
744
- };
745
- }
746
- async function convertValueToCoords(state, options) {
747
- const { placement, platform, elements } = state;
748
- const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating));
749
- const side = getSide(placement);
750
- const alignment = getAlignment(placement);
751
- const isVertical = getSideAxis(placement) === "y";
752
- const mainAxisMulti = originSides.has(side) ? -1 : 1;
753
- const crossAxisMulti = rtl && isVertical ? -1 : 1;
754
- const rawValue = evaluate(options, state);
755
- let { mainAxis, crossAxis, alignmentAxis } = typeof rawValue === "number" ? {
756
- mainAxis: rawValue,
757
- crossAxis: 0,
758
- alignmentAxis: null
759
- } : {
760
- mainAxis: rawValue.mainAxis || 0,
761
- crossAxis: rawValue.crossAxis || 0,
762
- alignmentAxis: rawValue.alignmentAxis
763
- };
764
- if (alignment && typeof alignmentAxis === "number") crossAxis = alignment === "end" ? alignmentAxis * -1 : alignmentAxis;
765
- return isVertical ? {
766
- x: crossAxis * crossAxisMulti,
767
- y: mainAxis * mainAxisMulti
768
- } : {
769
- x: mainAxis * mainAxisMulti,
770
- y: crossAxis * crossAxisMulti
771
- };
772
- }
773
- var MAX_RESET_COUNT, computePosition$1, flip$1, originSides, offset$1, shift$1, limitShift$1, size$1;
774
- function init_floating_ui_core() {
775
- return (init_floating_ui_core = __esmMin((() => {
776
- init_floating_ui_utils();
777
- MAX_RESET_COUNT = 50;
778
- computePosition$1 = async (reference, floating, config) => {
779
- const { placement = "bottom", strategy = "absolute", middleware = [], platform } = config;
780
- const platformWithDetectOverflow = platform.detectOverflow ? platform : {
781
- ...platform,
782
- detectOverflow: detectOverflow$1
783
- };
784
- const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(floating));
785
- let rects = await platform.getElementRects({
786
- reference,
787
- floating,
788
- strategy
789
- });
790
- let { x, y } = computeCoordsFromPlacement(rects, placement, rtl);
791
- let statefulPlacement = placement;
792
- let resetCount = 0;
793
- const middlewareData = {};
794
- for (let i = 0; i < middleware.length; i++) {
795
- const currentMiddleware = middleware[i];
796
- if (!currentMiddleware) continue;
797
- const { name, fn } = currentMiddleware;
798
- const { x: nextX, y: nextY, data, reset } = await fn({
799
- x,
800
- y,
801
- initialPlacement: placement,
802
- placement: statefulPlacement,
803
- strategy,
804
- middlewareData,
805
- rects,
806
- platform: platformWithDetectOverflow,
807
- elements: {
808
- reference,
809
- floating
810
- }
811
- });
812
- x = nextX != null ? nextX : x;
813
- y = nextY != null ? nextY : y;
814
- middlewareData[name] = {
815
- ...middlewareData[name],
816
- ...data
817
- };
818
- if (reset && resetCount < MAX_RESET_COUNT) {
819
- resetCount++;
820
- if (typeof reset === "object") {
821
- if (reset.placement) statefulPlacement = reset.placement;
822
- if (reset.rects) rects = reset.rects === true ? await platform.getElementRects({
823
- reference,
824
- floating,
825
- strategy
826
- }) : reset.rects;
827
- ({x, y} = computeCoordsFromPlacement(rects, statefulPlacement, rtl));
828
- }
829
- i = -1;
830
- }
831
- }
832
- return {
833
- x,
834
- y,
835
- placement: statefulPlacement,
836
- strategy,
837
- middlewareData
838
- };
839
- };
840
- flip$1 = function(options) {
841
- if (options === void 0) options = {};
842
- return {
843
- name: "flip",
844
- options,
845
- async fn(state) {
846
- var _middlewareData$arrow, _middlewareData$flip;
847
- const { placement, middlewareData, rects, initialPlacement, platform, elements } = state;
848
- const { mainAxis: checkMainAxis = true, crossAxis: checkCrossAxis = true, fallbackPlacements: specifiedFallbackPlacements, fallbackStrategy = "bestFit", fallbackAxisSideDirection = "none", flipAlignment = true, ...detectOverflowOptions } = evaluate(options, state);
849
- if ((_middlewareData$arrow = middlewareData.arrow) != null && _middlewareData$arrow.alignmentOffset) return {};
850
- const side = getSide(placement);
851
- const initialSideAxis = getSideAxis(initialPlacement);
852
- const isBasePlacement = getSide(initialPlacement) === initialPlacement;
853
- const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating));
854
- const fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipAlignment ? [getOppositePlacement$1(initialPlacement)] : getExpandedPlacements(initialPlacement));
855
- const hasFallbackAxisSideDirection = fallbackAxisSideDirection !== "none";
856
- if (!specifiedFallbackPlacements && hasFallbackAxisSideDirection) fallbackPlacements.push(...getOppositeAxisPlacements(initialPlacement, flipAlignment, fallbackAxisSideDirection, rtl));
857
- const placements = [initialPlacement, ...fallbackPlacements];
858
- const overflow = await platform.detectOverflow(state, detectOverflowOptions);
859
- const overflows = [];
860
- let overflowsData = ((_middlewareData$flip = middlewareData.flip) == null ? void 0 : _middlewareData$flip.overflows) || [];
861
- if (checkMainAxis) overflows.push(overflow[side]);
862
- if (checkCrossAxis) {
863
- const sides = getAlignmentSides(placement, rects, rtl);
864
- overflows.push(overflow[sides[0]], overflow[sides[1]]);
865
- }
866
- overflowsData = [...overflowsData, {
867
- placement,
868
- overflows
869
- }];
870
- if (!overflows.every((side) => side <= 0)) {
871
- var _middlewareData$flip2, _overflowsData$filter;
872
- const nextIndex = (((_middlewareData$flip2 = middlewareData.flip) == null ? void 0 : _middlewareData$flip2.index) || 0) + 1;
873
- const nextPlacement = placements[nextIndex];
874
- if (nextPlacement) {
875
- if (!(checkCrossAxis === "alignment" ? initialSideAxis !== getSideAxis(nextPlacement) : false) || overflowsData.every((d) => getSideAxis(d.placement) === initialSideAxis ? d.overflows[0] > 0 : true)) return {
876
- data: {
877
- index: nextIndex,
878
- overflows: overflowsData
879
- },
880
- reset: { placement: nextPlacement }
881
- };
882
- }
883
- let resetPlacement = (_overflowsData$filter = overflowsData.filter((d) => d.overflows[0] <= 0).sort((a, b) => a.overflows[1] - b.overflows[1])[0]) == null ? void 0 : _overflowsData$filter.placement;
884
- if (!resetPlacement) switch (fallbackStrategy) {
885
- case "bestFit": {
886
- var _overflowsData$filter2;
887
- const placement = (_overflowsData$filter2 = overflowsData.filter((d) => {
888
- if (hasFallbackAxisSideDirection) {
889
- const currentSideAxis = getSideAxis(d.placement);
890
- return currentSideAxis === initialSideAxis || currentSideAxis === "y";
891
- }
892
- return true;
893
- }).map((d) => [d.placement, d.overflows.filter((overflow) => overflow > 0).reduce((acc, overflow) => acc + overflow, 0)]).sort((a, b) => a[1] - b[1])[0]) == null ? void 0 : _overflowsData$filter2[0];
894
- if (placement) resetPlacement = placement;
895
- break;
896
- }
897
- case "initialPlacement": resetPlacement = initialPlacement;
898
- }
899
- if (placement !== resetPlacement) return { reset: { placement: resetPlacement } };
900
- }
901
- return {};
902
- }
903
- };
904
- };
905
- originSides = /*#__PURE__*/ new Set(["left", "top"]);
906
- offset$1 = function(options) {
907
- if (options === void 0) options = 0;
908
- return {
909
- name: "offset",
910
- options,
911
- async fn(state) {
912
- var _middlewareData$offse, _middlewareData$arrow;
913
- const { x, y, placement, middlewareData } = state;
914
- const diffCoords = await convertValueToCoords(state, options);
915
- if (placement === ((_middlewareData$offse = middlewareData.offset) == null ? void 0 : _middlewareData$offse.placement) && (_middlewareData$arrow = middlewareData.arrow) != null && _middlewareData$arrow.alignmentOffset) return {};
916
- return {
917
- x: x + diffCoords.x,
918
- y: y + diffCoords.y,
919
- data: {
920
- ...diffCoords,
921
- placement
922
- }
923
- };
924
- }
925
- };
926
- };
927
- shift$1 = function(options) {
928
- if (options === void 0) options = {};
929
- return {
930
- name: "shift",
931
- options,
932
- async fn(state) {
933
- const { x, y, placement, platform } = state;
934
- const { mainAxis: checkMainAxis = true, crossAxis: checkCrossAxis = false, limiter = { fn: (_ref) => {
935
- let { x, y } = _ref;
936
- return {
937
- x,
938
- y
939
- };
940
- } }, ...detectOverflowOptions } = evaluate(options, state);
941
- const coords = {
942
- x,
943
- y
944
- };
945
- const overflow = await platform.detectOverflow(state, detectOverflowOptions);
946
- const crossAxis = getSideAxis(placement);
947
- const mainAxis = getOppositeAxis(crossAxis);
948
- let mainAxisCoord = coords[mainAxis];
949
- let crossAxisCoord = coords[crossAxis];
950
- const clampCoord = (axis, coord) => clamp(coord + overflow[axis === "y" ? "top" : "left"], coord, coord - overflow[axis === "y" ? "bottom" : "right"]);
951
- if (checkMainAxis) mainAxisCoord = clampCoord(mainAxis, mainAxisCoord);
952
- if (checkCrossAxis) crossAxisCoord = clampCoord(crossAxis, crossAxisCoord);
953
- const limitedCoords = limiter.fn({
954
- ...state,
955
- [mainAxis]: mainAxisCoord,
956
- [crossAxis]: crossAxisCoord
957
- });
958
- return {
959
- ...limitedCoords,
960
- data: {
961
- x: limitedCoords.x - x,
962
- y: limitedCoords.y - y,
963
- enabled: {
964
- [mainAxis]: checkMainAxis,
965
- [crossAxis]: checkCrossAxis
966
- }
967
- }
968
- };
969
- }
970
- };
971
- };
972
- limitShift$1 = function(options) {
973
- if (options === void 0) options = {};
974
- return {
975
- options,
976
- fn(state) {
977
- var _rawOffset$mainAxis, _rawOffset$crossAxis;
978
- const { x, y, placement, rects, middlewareData } = state;
979
- const { offset = 0, mainAxis: checkMainAxis = true, crossAxis: checkCrossAxis = true } = evaluate(options, state);
980
- const coords = {
981
- x,
982
- y
983
- };
984
- const crossAxis = getSideAxis(placement);
985
- const mainAxis = getOppositeAxis(crossAxis);
986
- let mainAxisCoord = coords[mainAxis];
987
- let crossAxisCoord = coords[crossAxis];
988
- const rawOffset = evaluate(offset, state);
989
- const computedOffset = typeof rawOffset === "number" ? {
990
- mainAxis: rawOffset,
991
- crossAxis: 0
992
- } : {
993
- mainAxis: (_rawOffset$mainAxis = rawOffset.mainAxis) != null ? _rawOffset$mainAxis : 0,
994
- crossAxis: (_rawOffset$crossAxis = rawOffset.crossAxis) != null ? _rawOffset$crossAxis : 0
995
- };
996
- if (checkMainAxis) {
997
- const len = mainAxis === "y" ? "height" : "width";
998
- const limitMin = rects.reference[mainAxis] - rects.floating[len] + computedOffset.mainAxis;
999
- const limitMax = rects.reference[mainAxis] + rects.reference[len] - computedOffset.mainAxis;
1000
- if (mainAxisCoord < limitMin) mainAxisCoord = limitMin;
1001
- else if (mainAxisCoord > limitMax) mainAxisCoord = limitMax;
1002
- }
1003
- if (checkCrossAxis) {
1004
- var _middlewareData$offse, _middlewareData$offse2;
1005
- const len = mainAxis === "y" ? "width" : "height";
1006
- const isOriginSide = originSides.has(getSide(placement));
1007
- const limitMin = rects.reference[crossAxis] - rects.floating[len] + (isOriginSide ? ((_middlewareData$offse = middlewareData.offset) == null ? void 0 : _middlewareData$offse[crossAxis]) || 0 : 0) + (isOriginSide ? 0 : computedOffset.crossAxis);
1008
- const limitMax = rects.reference[crossAxis] + rects.reference[len] + (isOriginSide ? 0 : ((_middlewareData$offse2 = middlewareData.offset) == null ? void 0 : _middlewareData$offse2[crossAxis]) || 0) - (isOriginSide ? computedOffset.crossAxis : 0);
1009
- if (crossAxisCoord < limitMin) crossAxisCoord = limitMin;
1010
- else if (crossAxisCoord > limitMax) crossAxisCoord = limitMax;
1011
- }
1012
- return {
1013
- [mainAxis]: mainAxisCoord,
1014
- [crossAxis]: crossAxisCoord
1015
- };
1016
- }
1017
- };
1018
- };
1019
- size$1 = function(options) {
1020
- if (options === void 0) options = {};
1021
- return {
1022
- name: "size",
1023
- options,
1024
- async fn(state) {
1025
- const { placement, rects, platform, elements } = state;
1026
- const { apply = () => {}, ...detectOverflowOptions } = evaluate(options, state);
1027
- const overflow = await platform.detectOverflow(state, detectOverflowOptions);
1028
- const side = getSide(placement);
1029
- const alignment = getAlignment(placement);
1030
- const isYAxis = getSideAxis(placement) === "y";
1031
- const { width, height } = rects.floating;
1032
- let heightSide;
1033
- let widthSide;
1034
- if (side === "top" || side === "bottom") {
1035
- heightSide = side;
1036
- widthSide = alignment === (await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating)) ? "start" : "end") ? "left" : "right";
1037
- } else {
1038
- widthSide = side;
1039
- heightSide = alignment === "end" ? "top" : "bottom";
1040
- }
1041
- const maximumClippingHeight = height - overflow.top - overflow.bottom;
1042
- const maximumClippingWidth = width - overflow.left - overflow.right;
1043
- const overflowAvailableHeight = min$1(height - overflow[heightSide], maximumClippingHeight);
1044
- const overflowAvailableWidth = min$1(width - overflow[widthSide], maximumClippingWidth);
1045
- const shiftData = state.middlewareData.shift;
1046
- const noShift = !shiftData;
1047
- let availableHeight = overflowAvailableHeight;
1048
- let availableWidth = overflowAvailableWidth;
1049
- if (shiftData != null && shiftData.enabled.x) availableWidth = maximumClippingWidth;
1050
- if (shiftData != null && shiftData.enabled.y) availableHeight = maximumClippingHeight;
1051
- if (noShift && !alignment) {
1052
- if (isYAxis) availableWidth = width - 2 * max$1(overflow.left, overflow.right);
1053
- else availableHeight = height - 2 * max$1(overflow.top, overflow.bottom);
1054
- }
1055
- await apply({
1056
- ...state,
1057
- availableWidth,
1058
- availableHeight
1059
- });
1060
- const nextDimensions = await platform.getDimensions(elements.floating);
1061
- if (width !== nextDimensions.width || height !== nextDimensions.height) return { reset: { rects: true } };
1062
- return {};
1063
- }
1064
- };
1065
- };
1066
- })))();
1067
- }
1068
- //#endregion
1069
- //#region ../../node_modules/@floating-ui/dom/dist/floating-ui.dom.mjs
1070
- function getCssDimensions(element) {
1071
- const css = getComputedStyle$2(element);
1072
- let width = parseFloat(css.width) || 0;
1073
- let height = parseFloat(css.height) || 0;
1074
- const hasOffset = isHTMLElement$1(element);
1075
- const offsetWidth = hasOffset ? element.offsetWidth : width;
1076
- const offsetHeight = hasOffset ? element.offsetHeight : height;
1077
- const shouldFallback = round$1(width) !== offsetWidth || round$1(height) !== offsetHeight;
1078
- if (shouldFallback) {
1079
- width = offsetWidth;
1080
- height = offsetHeight;
1081
- }
1082
- return {
1083
- width,
1084
- height,
1085
- $: shouldFallback
1086
- };
1087
- }
1088
- function unwrapElement(element) {
1089
- return !isElement$1(element) ? element.contextElement : element;
1090
- }
1091
- function getScale(element) {
1092
- const domElement = unwrapElement(element);
1093
- if (!isHTMLElement$1(domElement)) return createCoords(1);
1094
- const rect = domElement.getBoundingClientRect();
1095
- const { width, height, $ } = getCssDimensions(domElement);
1096
- let x = ($ ? round$1(rect.width) : rect.width) / width;
1097
- let y = ($ ? round$1(rect.height) : rect.height) / height;
1098
- if (!x || !Number.isFinite(x)) x = 1;
1099
- if (!y || !Number.isFinite(y)) y = 1;
1100
- return {
1101
- x,
1102
- y
1103
- };
1104
- }
1105
- function getVisualOffsets(element) {
1106
- const win = getWindow$1(element);
1107
- if (!isWebKit() || !win.visualViewport) return noOffsets;
1108
- return {
1109
- x: win.visualViewport.offsetLeft,
1110
- y: win.visualViewport.offsetTop
1111
- };
1112
- }
1113
- function shouldAddVisualOffsets(element, isFixed, floatingOffsetParent) {
1114
- if (isFixed === void 0) isFixed = false;
1115
- return !!floatingOffsetParent && isFixed && floatingOffsetParent === getWindow$1(element);
1116
- }
1117
- function getBoundingClientRect$1(element, includeScale, isFixedStrategy, offsetParent) {
1118
- if (includeScale === void 0) includeScale = false;
1119
- if (isFixedStrategy === void 0) isFixedStrategy = false;
1120
- const clientRect = element.getBoundingClientRect();
1121
- const domElement = unwrapElement(element);
1122
- let scale = createCoords(1);
1123
- if (includeScale) {
1124
- if (offsetParent) {
1125
- if (isElement$1(offsetParent)) scale = getScale(offsetParent);
1126
- } else scale = getScale(element);
1127
- }
1128
- const visualOffsets = shouldAddVisualOffsets(domElement, isFixedStrategy, offsetParent) ? getVisualOffsets(domElement) : createCoords(0);
1129
- let x = (clientRect.left + visualOffsets.x) / scale.x;
1130
- let y = (clientRect.top + visualOffsets.y) / scale.y;
1131
- let width = clientRect.width / scale.x;
1132
- let height = clientRect.height / scale.y;
1133
- if (domElement && offsetParent) {
1134
- const win = getWindow$1(domElement);
1135
- const offsetWin = isElement$1(offsetParent) ? getWindow$1(offsetParent) : offsetParent;
1136
- let currentWin = win;
1137
- let currentIFrame = getFrameElement(currentWin);
1138
- while (currentIFrame && offsetWin !== currentWin) {
1139
- const iframeScale = getScale(currentIFrame);
1140
- const iframeRect = currentIFrame.getBoundingClientRect();
1141
- const css = getComputedStyle$2(currentIFrame);
1142
- const left = iframeRect.left + (currentIFrame.clientLeft + parseFloat(css.paddingLeft)) * iframeScale.x;
1143
- const top = iframeRect.top + (currentIFrame.clientTop + parseFloat(css.paddingTop)) * iframeScale.y;
1144
- x *= iframeScale.x;
1145
- y *= iframeScale.y;
1146
- width *= iframeScale.x;
1147
- height *= iframeScale.y;
1148
- x += left;
1149
- y += top;
1150
- currentWin = getWindow$1(currentIFrame);
1151
- currentIFrame = getFrameElement(currentWin);
1152
- }
1153
- }
1154
- return rectToClientRect$1({
1155
- width,
1156
- height,
1157
- x,
1158
- y
1159
- });
1160
- }
1161
- function getWindowScrollBarX$1(element, rect) {
1162
- const leftScroll = getNodeScroll$1(element).scrollLeft;
1163
- if (!rect) return getBoundingClientRect$1(getDocumentElement$1(element)).left + leftScroll;
1164
- return rect.left + leftScroll;
1165
- }
1166
- function getHTMLOffset(documentElement, scroll) {
1167
- const htmlRect = documentElement.getBoundingClientRect();
1168
- return {
1169
- x: htmlRect.left + scroll.scrollLeft - getWindowScrollBarX$1(documentElement, htmlRect),
1170
- y: htmlRect.top + scroll.scrollTop
1171
- };
1172
- }
1173
- function convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {
1174
- let { elements, rect, offsetParent, strategy } = _ref;
1175
- const isFixed = strategy === "fixed";
1176
- const documentElement = getDocumentElement$1(offsetParent);
1177
- const topLayer = elements ? isTopLayer(elements.floating) : false;
1178
- if (offsetParent === documentElement || topLayer && isFixed) return rect;
1179
- let scroll = {
1180
- scrollLeft: 0,
1181
- scrollTop: 0
1182
- };
1183
- let scale = createCoords(1);
1184
- const offsets = createCoords(0);
1185
- const isOffsetParentAnElement = isHTMLElement$1(offsetParent);
1186
- if (isOffsetParentAnElement || !isFixed) {
1187
- if (getNodeName$1(offsetParent) !== "body" || isOverflowElement(documentElement)) scroll = getNodeScroll$1(offsetParent);
1188
- if (isOffsetParentAnElement) {
1189
- const offsetRect = getBoundingClientRect$1(offsetParent);
1190
- scale = getScale(offsetParent);
1191
- offsets.x = offsetRect.x + offsetParent.clientLeft;
1192
- offsets.y = offsetRect.y + offsetParent.clientTop;
1193
- }
1194
- }
1195
- const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);
1196
- return {
1197
- width: rect.width * scale.x,
1198
- height: rect.height * scale.y,
1199
- x: rect.x * scale.x - scroll.scrollLeft * scale.x + offsets.x + htmlOffset.x,
1200
- y: rect.y * scale.y - scroll.scrollTop * scale.y + offsets.y + htmlOffset.y
1201
- };
1202
- }
1203
- function getClientRects(element) {
1204
- return element.getClientRects ? Array.from(element.getClientRects()) : [];
1205
- }
1206
- function getDocumentRect$1(html) {
1207
- const scroll = getNodeScroll$1(html);
1208
- const body = html.ownerDocument.body;
1209
- const width = max$1(html.scrollWidth, html.clientWidth, body.scrollWidth, body.clientWidth);
1210
- const height = max$1(html.scrollHeight, html.clientHeight, body.scrollHeight, body.clientHeight);
1211
- let x = -scroll.scrollLeft + getWindowScrollBarX$1(html);
1212
- const y = -scroll.scrollTop;
1213
- if (getComputedStyle$2(body).direction === "rtl") x += max$1(html.clientWidth, body.clientWidth) - width;
1214
- return {
1215
- width,
1216
- height,
1217
- x,
1218
- y
1219
- };
1220
- }
1221
- function getViewportRect$1(element, strategy, rootBoundary) {
1222
- if (rootBoundary === void 0) rootBoundary = "viewport";
1223
- const isLayoutViewport = rootBoundary === "layoutViewport";
1224
- const win = getWindow$1(element);
1225
- const html = getDocumentElement$1(element);
1226
- const visualViewport = win.visualViewport;
1227
- let width = html.clientWidth;
1228
- let height = html.clientHeight;
1229
- let x = 0;
1230
- let y = 0;
1231
- if (visualViewport) {
1232
- const layoutRelativeClientCoords = !isWebKit() || strategy === "fixed";
1233
- if (isLayoutViewport) {
1234
- if (!layoutRelativeClientCoords) {
1235
- x = -visualViewport.offsetLeft;
1236
- y = -visualViewport.offsetTop;
1237
- }
1238
- } else {
1239
- width = visualViewport.width;
1240
- height = visualViewport.height;
1241
- if (layoutRelativeClientCoords) {
1242
- x = visualViewport.offsetLeft;
1243
- y = visualViewport.offsetTop;
1244
- }
1245
- }
1246
- }
1247
- if (getWindowScrollBarX$1(html) <= 0) {
1248
- const doc = html.ownerDocument;
1249
- const body = doc.body;
1250
- const bodyStyles = getComputedStyle(body);
1251
- const bodyMarginInline = doc.compatMode === "CSS1Compat" ? parseFloat(bodyStyles.marginLeft) + parseFloat(bodyStyles.marginRight) || 0 : 0;
1252
- const reservedWidth = Math.abs(html.clientWidth - body.clientWidth - bodyMarginInline);
1253
- const gutter = getComputedStyle(html).scrollbarGutter === "stable both-edges" ? reservedWidth / 2 : reservedWidth;
1254
- if (gutter <= SCROLLBAR_MAX) width -= gutter;
1255
- }
1256
- return {
1257
- width,
1258
- height,
1259
- x,
1260
- y
1261
- };
1262
- }
1263
- function getInnerBoundingClientRect$1(element, strategy) {
1264
- const clientRect = getBoundingClientRect$1(element, true, strategy === "fixed");
1265
- const top = clientRect.top + element.clientTop;
1266
- const left = clientRect.left + element.clientLeft;
1267
- const scale = getScale(element);
1268
- return {
1269
- width: element.clientWidth * scale.x,
1270
- height: element.clientHeight * scale.y,
1271
- x: left * scale.x,
1272
- y: top * scale.y
1273
- };
1274
- }
1275
- function getClientRectFromClippingAncestor(element, clippingAncestor, strategy) {
1276
- let rect;
1277
- if (clippingAncestor === "viewport" || clippingAncestor === "layoutViewport") rect = getViewportRect$1(element, strategy, clippingAncestor);
1278
- else if (clippingAncestor === "document") rect = getDocumentRect$1(getDocumentElement$1(element));
1279
- else if (isElement$1(clippingAncestor)) rect = getInnerBoundingClientRect$1(clippingAncestor, strategy);
1280
- else {
1281
- const visualOffsets = getVisualOffsets(element);
1282
- rect = {
1283
- x: clippingAncestor.x - visualOffsets.x,
1284
- y: clippingAncestor.y - visualOffsets.y,
1285
- width: clippingAncestor.width,
1286
- height: clippingAncestor.height
1287
- };
1288
- }
1289
- return rectToClientRect$1(rect);
1290
- }
1291
- function getClippingElementAncestors(element, cache) {
1292
- const cachedResult = cache.get(element);
1293
- if (cachedResult) return cachedResult;
1294
- let result = getOverflowAncestors(element, [], false).filter((el) => isElement$1(el) && getNodeName$1(el) !== "body");
1295
- let lastKeptComputedStyle = null;
1296
- const elementIsFixed = getComputedStyle$2(element).position === "fixed";
1297
- let currentNode = elementIsFixed ? getParentNode$1(element) : element;
1298
- while (isElement$1(currentNode) && !isLastTraversableNode(currentNode)) {
1299
- const computedStyle = getComputedStyle$2(currentNode);
1300
- const currentNodeIsContaining = isContainingBlock(currentNode);
1301
- const lastPosition = lastKeptComputedStyle ? lastKeptComputedStyle.position : elementIsFixed ? "fixed" : "";
1302
- if (!currentNodeIsContaining && (lastPosition === "fixed" || lastPosition === "absolute" && computedStyle.position === "static")) result = result.filter((ancestor) => ancestor !== currentNode);
1303
- else lastKeptComputedStyle = computedStyle;
1304
- currentNode = getParentNode$1(currentNode);
1305
- }
1306
- cache.set(element, result);
1307
- return result;
1308
- }
1309
- function getClippingRect$1(_ref) {
1310
- let { element, boundary, rootBoundary, strategy } = _ref;
1311
- const clippingAncestors = [...boundary === "clippingAncestors" ? isTopLayer(element) ? [] : getClippingElementAncestors(element, this._c) : [].concat(boundary), rootBoundary];
1312
- const firstRect = getClientRectFromClippingAncestor(element, clippingAncestors[0], strategy);
1313
- let top = firstRect.top;
1314
- let right = firstRect.right;
1315
- let bottom = firstRect.bottom;
1316
- let left = firstRect.left;
1317
- for (let i = 1; i < clippingAncestors.length; i++) {
1318
- const rect = getClientRectFromClippingAncestor(element, clippingAncestors[i], strategy);
1319
- top = max$1(rect.top, top);
1320
- right = min$1(rect.right, right);
1321
- bottom = min$1(rect.bottom, bottom);
1322
- left = max$1(rect.left, left);
1323
- }
1324
- return {
1325
- width: right - left,
1326
- height: bottom - top,
1327
- x: left,
1328
- y: top
1329
- };
1330
- }
1331
- function getDimensions(element) {
1332
- const { width, height } = getCssDimensions(element);
1333
- return {
1334
- width,
1335
- height
1336
- };
1337
- }
1338
- function getRectRelativeToOffsetParent(element, offsetParent, strategy) {
1339
- const isOffsetParentAnElement = isHTMLElement$1(offsetParent);
1340
- const documentElement = getDocumentElement$1(offsetParent);
1341
- const isFixed = strategy === "fixed";
1342
- const rect = getBoundingClientRect$1(element, true, isFixed, offsetParent);
1343
- let scroll = {
1344
- scrollLeft: 0,
1345
- scrollTop: 0
1346
- };
1347
- const offsets = createCoords(0);
1348
- if (isOffsetParentAnElement || !isFixed) {
1349
- if (getNodeName$1(offsetParent) !== "body" || isOverflowElement(documentElement)) scroll = getNodeScroll$1(offsetParent);
1350
- if (isOffsetParentAnElement) {
1351
- const offsetRect = getBoundingClientRect$1(offsetParent, true, isFixed, offsetParent);
1352
- offsets.x = offsetRect.x + offsetParent.clientLeft;
1353
- offsets.y = offsetRect.y + offsetParent.clientTop;
1354
- }
1355
- }
1356
- if (!isOffsetParentAnElement && documentElement) offsets.x = getWindowScrollBarX$1(documentElement);
1357
- const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);
1358
- return {
1359
- x: rect.left + scroll.scrollLeft - offsets.x - htmlOffset.x,
1360
- y: rect.top + scroll.scrollTop - offsets.y - htmlOffset.y,
1361
- width: rect.width,
1362
- height: rect.height
1363
- };
1364
- }
1365
- function isStaticPositioned(element) {
1366
- return getComputedStyle$2(element).position === "static";
1367
- }
1368
- function getTrueOffsetParent$1(element, polyfill) {
1369
- if (!isHTMLElement$1(element) || getComputedStyle$2(element).position === "fixed") return null;
1370
- if (polyfill) return polyfill(element);
1371
- let rawOffsetParent = element.offsetParent;
1372
- if (getDocumentElement$1(element) === rawOffsetParent) rawOffsetParent = rawOffsetParent.ownerDocument.body;
1373
- return rawOffsetParent;
1374
- }
1375
- function getOffsetParent$1(element, polyfill) {
1376
- const win = getWindow$1(element);
1377
- if (isTopLayer(element)) return win;
1378
- if (!isHTMLElement$1(element)) {
1379
- let svgOffsetParent = getParentNode$1(element);
1380
- while (svgOffsetParent && !isLastTraversableNode(svgOffsetParent)) {
1381
- if (isElement$1(svgOffsetParent) && !isStaticPositioned(svgOffsetParent)) return svgOffsetParent;
1382
- svgOffsetParent = getParentNode$1(svgOffsetParent);
1383
- }
1384
- return win;
1385
- }
1386
- let offsetParent = getTrueOffsetParent$1(element, polyfill);
1387
- while (offsetParent && isTableElement$1(offsetParent) && isStaticPositioned(offsetParent)) offsetParent = getTrueOffsetParent$1(offsetParent, polyfill);
1388
- if (offsetParent && isLastTraversableNode(offsetParent) && isStaticPositioned(offsetParent) && !isContainingBlock(offsetParent)) return win;
1389
- return offsetParent || getContainingBlock$1(element) || win;
1390
- }
1391
- function isRTL(element) {
1392
- return getComputedStyle$2(element).direction === "rtl";
1393
- }
1394
- function rectsAreEqual(a, b) {
1395
- return a.x === b.x && a.y === b.y && a.width === b.width && a.height === b.height;
1396
- }
1397
- function observeMove(element, onMove, ancestorResize) {
1398
- let io = null;
1399
- let timeoutId;
1400
- const root = getDocumentElement$1(element);
1401
- function cleanup() {
1402
- var _io;
1403
- clearTimeout(timeoutId);
1404
- (_io = io) == null || _io.disconnect();
1405
- io = null;
1406
- }
1407
- function refresh(skip, threshold) {
1408
- if (skip === void 0) skip = false;
1409
- if (threshold === void 0) threshold = 1;
1410
- cleanup();
1411
- const elementRectForRootMargin = element.getBoundingClientRect();
1412
- const { left, top, width, height } = elementRectForRootMargin;
1413
- if (!skip) onMove();
1414
- if (!width || !height) return;
1415
- const insetTop = floor(top);
1416
- const insetRight = floor(root.clientWidth - (left + width));
1417
- const insetBottom = floor(root.clientHeight - (top + height));
1418
- const insetLeft = floor(left);
1419
- const options = {
1420
- rootMargin: -insetTop + "px " + -insetRight + "px " + -insetBottom + "px " + -insetLeft + "px",
1421
- threshold: max$1(0, min$1(1, threshold)) || 1
1422
- };
1423
- let isFirstUpdate = true;
1424
- function handleObserve(entries) {
1425
- const ratio = entries[0].intersectionRatio;
1426
- if (!rectsAreEqual(elementRectForRootMargin, element.getBoundingClientRect())) return refresh();
1427
- if (ratio !== threshold) {
1428
- if (!isFirstUpdate) return refresh();
1429
- if (!ratio) timeoutId = setTimeout(() => {
1430
- refresh(false, 1e-7);
1431
- }, 1e3);
1432
- else refresh(false, ratio);
1433
- }
1434
- isFirstUpdate = false;
1435
- }
1436
- try {
1437
- io = new IntersectionObserver(handleObserve, {
1438
- ...options,
1439
- root: root.ownerDocument
1440
- });
1441
- } catch (_e) {
1442
- io = new IntersectionObserver(handleObserve, options);
1443
- }
1444
- io.observe(element);
1445
- }
1446
- const win = getWindow$1(element);
1447
- const handleResize = () => refresh(ancestorResize);
1448
- win.addEventListener("resize", handleResize);
1449
- refresh(true);
1450
- return () => {
1451
- win.removeEventListener("resize", handleResize);
1452
- cleanup();
1453
- };
1454
- }
1455
- /**
1456
- * Automatically updates the position of the floating element when necessary.
1457
- * Should only be called when the floating element is mounted on the DOM or
1458
- * visible on the screen.
1459
- * @returns cleanup function that should be invoked when the floating element is
1460
- * removed from the DOM or hidden from the screen.
1461
- * @see https://floating-ui.com/docs/autoUpdate
1462
- */
1463
- function autoUpdate(reference, floating, update, options) {
1464
- if (options === void 0) options = {};
1465
- const { ancestorScroll = true, ancestorResize = true, elementResize = typeof ResizeObserver === "function", layoutShift = typeof IntersectionObserver === "function", animationFrame = false } = options;
1466
- const referenceEl = unwrapElement(reference);
1467
- const ancestors = ancestorScroll || ancestorResize ? [...referenceEl ? getOverflowAncestors(referenceEl) : [], ...floating ? getOverflowAncestors(floating) : []] : [];
1468
- ancestors.forEach((ancestor) => {
1469
- ancestorScroll && ancestor.addEventListener("scroll", update);
1470
- ancestorResize && ancestor.addEventListener("resize", update);
1471
- });
1472
- const cleanupIo = referenceEl && layoutShift ? observeMove(referenceEl, update, ancestorResize) : null;
1473
- let reobserveFrame = -1;
1474
- let resizeObserver = null;
1475
- if (elementResize) {
1476
- resizeObserver = new ResizeObserver((_ref) => {
1477
- let [firstEntry] = _ref;
1478
- if (firstEntry && firstEntry.target === referenceEl && resizeObserver && floating) {
1479
- resizeObserver.unobserve(floating);
1480
- cancelAnimationFrame(reobserveFrame);
1481
- reobserveFrame = requestAnimationFrame(() => {
1482
- var _resizeObserver;
1483
- (_resizeObserver = resizeObserver) == null || _resizeObserver.observe(floating);
1484
- });
1485
- }
1486
- update();
1487
- });
1488
- if (referenceEl && !animationFrame) resizeObserver.observe(referenceEl);
1489
- if (floating) resizeObserver.observe(floating);
1490
- }
1491
- let frameId;
1492
- let prevRefRect = animationFrame ? getBoundingClientRect$1(reference) : null;
1493
- if (animationFrame) frameLoop();
1494
- function frameLoop() {
1495
- const nextRefRect = getBoundingClientRect$1(reference);
1496
- if (prevRefRect && !rectsAreEqual(prevRefRect, nextRefRect)) update();
1497
- prevRefRect = nextRefRect;
1498
- frameId = requestAnimationFrame(frameLoop);
1499
- }
1500
- update();
1501
- return () => {
1502
- var _resizeObserver2;
1503
- ancestors.forEach((ancestor) => {
1504
- ancestorScroll && ancestor.removeEventListener("scroll", update);
1505
- ancestorResize && ancestor.removeEventListener("resize", update);
1506
- });
1507
- cleanupIo?.();
1508
- (_resizeObserver2 = resizeObserver) == null || _resizeObserver2.disconnect();
1509
- resizeObserver = null;
1510
- if (animationFrame) cancelAnimationFrame(frameId);
1511
- };
1512
- }
1513
- var noOffsets, SCROLLBAR_MAX, getElementRects, platform, offset$3, shift$2, flip$3, size$2, limitShift$2, computePosition;
1514
- function init_floating_ui_dom() {
1515
- return (init_floating_ui_dom = __esmMin((() => {
1516
- init_floating_ui_core();
1517
- init_floating_ui_utils();
1518
- init_floating_ui_utils_dom();
1519
- noOffsets = /*#__PURE__*/ createCoords(0);
1520
- SCROLLBAR_MAX = 25;
1521
- getElementRects = async function(data) {
1522
- const getOffsetParentFn = this.getOffsetParent || getOffsetParent$1;
1523
- const getDimensionsFn = this.getDimensions;
1524
- const floatingDimensions = await getDimensionsFn(data.floating);
1525
- return {
1526
- reference: getRectRelativeToOffsetParent(data.reference, await getOffsetParentFn(data.floating), data.strategy),
1527
- floating: {
1528
- x: 0,
1529
- y: 0,
1530
- width: floatingDimensions.width,
1531
- height: floatingDimensions.height
1532
- }
1533
- };
1534
- };
1535
- platform = {
1536
- convertOffsetParentRelativeRectToViewportRelativeRect,
1537
- getDocumentElement: getDocumentElement$1,
1538
- getClippingRect: getClippingRect$1,
1539
- getOffsetParent: getOffsetParent$1,
1540
- getElementRects,
1541
- getClientRects,
1542
- getDimensions,
1543
- getScale,
1544
- isElement: isElement$1,
1545
- isRTL
1546
- };
1547
- offset$3 = offset$1;
1548
- shift$2 = shift$1;
1549
- flip$3 = flip$1;
1550
- size$2 = size$1;
1551
- limitShift$2 = limitShift$1;
1552
- computePosition = (reference, floating, options) => {
1553
- const cache = /* @__PURE__ */ new Map();
1554
- const mergedOptions = options != null ? options : {};
1555
- const platformWithCache = {
1556
- ...platform,
1557
- ...mergedOptions.platform,
1558
- _c: cache
1559
- };
1560
- return computePosition$1(reference, floating, {
1561
- ...mergedOptions,
1562
- platform: platformWithCache
1563
- });
1564
- };
1565
- })))();
1566
- }
1567
- //#endregion
1568
- //#region ../../node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.mjs
1569
- function deepEqual(a, b) {
1570
- if (a === b) return true;
1571
- if (typeof a !== typeof b) return false;
1572
- if (typeof a === "function" && a.toString() === b.toString()) return true;
1573
- let length;
1574
- let i;
1575
- let keys;
1576
- if (a && b && typeof a === "object") {
1577
- if (Array.isArray(a)) {
1578
- length = a.length;
1579
- if (length !== b.length) return false;
1580
- for (i = length; i-- !== 0;) if (!deepEqual(a[i], b[i])) return false;
1581
- return true;
1582
- }
1583
- keys = Object.keys(a);
1584
- length = keys.length;
1585
- if (length !== Object.keys(b).length) return false;
1586
- for (i = length; i-- !== 0;) if (!{}.hasOwnProperty.call(b, keys[i])) return false;
1587
- for (i = length; i-- !== 0;) {
1588
- const key = keys[i];
1589
- if (key === "_owner" && a.$$typeof) continue;
1590
- if (!deepEqual(a[key], b[key])) return false;
1591
- }
1592
- return true;
1593
- }
1594
- return a !== a && b !== b;
1595
- }
1596
- function getDPR(element) {
1597
- if (typeof window === "undefined") return 1;
1598
- return (element.ownerDocument.defaultView || window).devicePixelRatio || 1;
1599
- }
1600
- function roundByDPR(element, value) {
1601
- const dpr = getDPR(element);
1602
- return Math.round(value * dpr) / dpr;
1603
- }
1604
- function useLatestRef(value) {
1605
- const ref = import_react.useRef(value);
1606
- index(() => {
1607
- ref.current = value;
1608
- });
1609
- return ref;
1610
- }
1611
- /**
1612
- * Provides data to position a floating element.
1613
- * @see https://floating-ui.com/docs/useFloating
1614
- */
1615
- function useFloating(options) {
1616
- if (options === void 0) options = {};
1617
- const { placement = "bottom", strategy = "absolute", middleware = [], platform, elements: { reference: externalReference, floating: externalFloating } = {}, transform = true, whileElementsMounted, open } = options;
1618
- const [data, setData] = import_react.useState({
1619
- x: 0,
1620
- y: 0,
1621
- strategy,
1622
- placement,
1623
- middlewareData: {},
1624
- isPositioned: false
1625
- });
1626
- const [latestMiddleware, setLatestMiddleware] = import_react.useState(middleware);
1627
- if (!deepEqual(latestMiddleware, middleware)) setLatestMiddleware(middleware);
1628
- const [_reference, _setReference] = import_react.useState(null);
1629
- const [_floating, _setFloating] = import_react.useState(null);
1630
- const setReference = import_react.useCallback((node) => {
1631
- if (node !== referenceRef.current) {
1632
- referenceRef.current = node;
1633
- _setReference(node);
1634
- }
1635
- }, []);
1636
- const setFloating = import_react.useCallback((node) => {
1637
- if (node !== floatingRef.current) {
1638
- floatingRef.current = node;
1639
- _setFloating(node);
1640
- }
1641
- }, []);
1642
- const referenceEl = externalReference || _reference;
1643
- const floatingEl = externalFloating || _floating;
1644
- const referenceRef = import_react.useRef(null);
1645
- const floatingRef = import_react.useRef(null);
1646
- const dataRef = import_react.useRef(data);
1647
- const hasWhileElementsMounted = whileElementsMounted != null;
1648
- const whileElementsMountedRef = useLatestRef(whileElementsMounted);
1649
- const platformRef = useLatestRef(platform);
1650
- const openRef = useLatestRef(open);
1651
- const update = import_react.useCallback(() => {
1652
- if (!referenceRef.current || !floatingRef.current) return;
1653
- const config = {
1654
- placement,
1655
- strategy,
1656
- middleware: latestMiddleware
1657
- };
1658
- if (platformRef.current) config.platform = platformRef.current;
1659
- computePosition(referenceRef.current, floatingRef.current, config).then((data) => {
1660
- const fullData = {
1661
- ...data,
1662
- isPositioned: openRef.current !== false
1663
- };
1664
- if (isMountedRef.current && !deepEqual(dataRef.current, fullData)) {
1665
- dataRef.current = fullData;
1666
- import_react_dom.flushSync(() => {
1667
- setData(fullData);
1668
- });
1669
- }
1670
- });
1671
- }, [
1672
- latestMiddleware,
1673
- placement,
1674
- strategy,
1675
- platformRef,
1676
- openRef
1677
- ]);
1678
- index(() => {
1679
- if (open === false && dataRef.current.isPositioned) {
1680
- dataRef.current.isPositioned = false;
1681
- setData((data) => ({
1682
- ...data,
1683
- isPositioned: false
1684
- }));
1685
- }
1686
- }, [open]);
1687
- const isMountedRef = import_react.useRef(false);
1688
- index(() => {
1689
- isMountedRef.current = true;
1690
- return () => {
1691
- isMountedRef.current = false;
1692
- };
1693
- }, []);
1694
- index(() => {
1695
- if (referenceEl) referenceRef.current = referenceEl;
1696
- if (floatingEl) floatingRef.current = floatingEl;
1697
- if (referenceEl && floatingEl) {
1698
- if (whileElementsMountedRef.current) return whileElementsMountedRef.current(referenceEl, floatingEl, update);
1699
- update();
1700
- }
1701
- }, [
1702
- referenceEl,
1703
- floatingEl,
1704
- update,
1705
- whileElementsMountedRef,
1706
- hasWhileElementsMounted
1707
- ]);
1708
- const refs = import_react.useMemo(() => ({
1709
- reference: referenceRef,
1710
- floating: floatingRef,
1711
- setReference,
1712
- setFloating
1713
- }), [setReference, setFloating]);
1714
- const elements = import_react.useMemo(() => ({
1715
- reference: referenceEl,
1716
- floating: floatingEl
1717
- }), [referenceEl, floatingEl]);
1718
- const floatingStyles = import_react.useMemo(() => {
1719
- const initialStyles = {
1720
- position: strategy,
1721
- left: 0,
1722
- top: 0
1723
- };
1724
- if (!elements.floating) return initialStyles;
1725
- const x = roundByDPR(elements.floating, data.x);
1726
- const y = roundByDPR(elements.floating, data.y);
1727
- if (transform) return {
1728
- ...initialStyles,
1729
- transform: "translate(" + x + "px, " + y + "px)",
1730
- ...getDPR(elements.floating) >= 1.5 && { willChange: "transform" }
1731
- };
1732
- return {
1733
- position: strategy,
1734
- left: x,
1735
- top: y
1736
- };
1737
- }, [
1738
- strategy,
1739
- transform,
1740
- elements.floating,
1741
- data.x,
1742
- data.y
1743
- ]);
1744
- return import_react.useMemo(() => ({
1745
- ...data,
1746
- update,
1747
- refs,
1748
- elements,
1749
- floatingStyles
1750
- }), [
1751
- data,
1752
- update,
1753
- refs,
1754
- elements,
1755
- floatingStyles
1756
- ]);
1757
- }
1758
- var import_react, import_react$1, import_react_dom, index, offset$2, shift, limitShift, flip$2, size;
1759
- function init_floating_ui_react_dom() {
1760
- return (init_floating_ui_react_dom = __esmMin((() => {
1761
- init_floating_ui_dom();
1762
- import_react = /* @__PURE__ */ __toESM(require_react(), 1);
1763
- import_react$1 = require_react();
1764
- import_react_dom = /* @__PURE__ */ __toESM(require_react_dom(), 1);
1765
- index = typeof document !== "undefined" ? import_react$1.useLayoutEffect : function noop() {};
1766
- offset$2 = (options, deps) => {
1767
- const result = offset$3(options);
1768
- return {
1769
- name: result.name,
1770
- fn: result.fn,
1771
- options: [options, deps]
1772
- };
1773
- };
1774
- shift = (options, deps) => {
1775
- const result = shift$2(options);
1776
- return {
1777
- name: result.name,
1778
- fn: result.fn,
1779
- options: [options, deps]
1780
- };
1781
- };
1782
- limitShift = (options, deps) => {
1783
- return {
1784
- fn: limitShift$2(options).fn,
1785
- options: [options, deps]
1786
- };
1787
- };
1788
- flip$2 = (options, deps) => {
1789
- const result = flip$3(options);
1790
- return {
1791
- name: result.name,
1792
- fn: result.fn,
1793
- options: [options, deps]
1794
- };
1795
- };
1796
- size = (options, deps) => {
1797
- const result = size$2(options);
1798
- return {
1799
- name: result.name,
1800
- fn: result.fn,
1801
- options: [options, deps]
1802
- };
1803
- };
1804
- })))();
1805
- }
1806
- //#endregion
1807
- //#region ../../node_modules/@popperjs/core/lib/enums.js
1808
- var bottom, right, left, auto, basePlacements, start, clippingParents, viewport, popper, reference, variationPlacements, placements, beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite, modifierPhases;
1809
- function init_enums() {
1810
- return (init_enums = __esmMin((() => {
1811
- bottom = "bottom";
1812
- right = "right";
1813
- left = "left";
1814
- auto = "auto";
1815
- basePlacements = [
1816
- "top",
1817
- bottom,
1818
- right,
1819
- left
1820
- ];
1821
- start = "start";
1822
- clippingParents = "clippingParents";
1823
- viewport = "viewport";
1824
- popper = "popper";
1825
- reference = "reference";
1826
- variationPlacements = /*#__PURE__*/ basePlacements.reduce(function(acc, placement) {
1827
- return acc.concat([placement + "-" + start, placement + "-end"]);
1828
- }, []);
1829
- placements = /*#__PURE__*/ [].concat(basePlacements, [auto]).reduce(function(acc, placement) {
1830
- return acc.concat([
1831
- placement,
1832
- placement + "-" + start,
1833
- placement + "-end"
1834
- ]);
1835
- }, []);
1836
- beforeRead = "beforeRead";
1837
- read = "read";
1838
- afterRead = "afterRead";
1839
- beforeMain = "beforeMain";
1840
- main = "main";
1841
- afterMain = "afterMain";
1842
- beforeWrite = "beforeWrite";
1843
- write = "write";
1844
- afterWrite = "afterWrite";
1845
- modifierPhases = [
1846
- beforeRead,
1847
- read,
1848
- afterRead,
1849
- beforeMain,
1850
- main,
1851
- afterMain,
1852
- beforeWrite,
1853
- write,
1854
- afterWrite
1855
- ];
1856
- })))();
1857
- }
1858
- //#endregion
1859
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js
1860
- function getNodeName(element) {
1861
- return element ? (element.nodeName || "").toLowerCase() : null;
1862
- }
1863
- //#endregion
1864
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js
1865
- function getWindow(node) {
1866
- if (node == null) return window;
1867
- if (node.toString() !== "[object Window]") {
1868
- var ownerDocument = node.ownerDocument;
1869
- return ownerDocument ? ownerDocument.defaultView || window : window;
1870
- }
1871
- return node;
1872
- }
1873
- //#endregion
1874
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js
1875
- function isElement(node) {
1876
- return node instanceof getWindow(node).Element || node instanceof Element;
1877
- }
1878
- function isHTMLElement(node) {
1879
- return node instanceof getWindow(node).HTMLElement || node instanceof HTMLElement;
1880
- }
1881
- function isShadowRoot(node) {
1882
- if (typeof ShadowRoot === "undefined") return false;
1883
- return node instanceof getWindow(node).ShadowRoot || node instanceof ShadowRoot;
1884
- }
1885
- function init_instanceOf() {
1886
- return (init_instanceOf = __esmMin((() => {})))();
1887
- }
1888
- //#endregion
1889
- //#region ../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js
1890
- function applyStyles(_ref) {
1891
- var state = _ref.state;
1892
- Object.keys(state.elements).forEach(function(name) {
1893
- var style = state.styles[name] || {};
1894
- var attributes = state.attributes[name] || {};
1895
- var element = state.elements[name];
1896
- if (!isHTMLElement(element) || !getNodeName(element)) return;
1897
- Object.assign(element.style, style);
1898
- Object.keys(attributes).forEach(function(name) {
1899
- var value = attributes[name];
1900
- if (value === false) element.removeAttribute(name);
1901
- else element.setAttribute(name, value === true ? "" : value);
1902
- });
1903
- });
1904
- }
1905
- function effect$2(_ref2) {
1906
- var state = _ref2.state;
1907
- var initialStyles = {
1908
- popper: {
1909
- position: state.options.strategy,
1910
- left: "0",
1911
- top: "0",
1912
- margin: "0"
1913
- },
1914
- arrow: { position: "absolute" },
1915
- reference: {}
1916
- };
1917
- Object.assign(state.elements.popper.style, initialStyles.popper);
1918
- state.styles = initialStyles;
1919
- if (state.elements.arrow) Object.assign(state.elements.arrow.style, initialStyles.arrow);
1920
- return function() {
1921
- Object.keys(state.elements).forEach(function(name) {
1922
- var element = state.elements[name];
1923
- var attributes = state.attributes[name] || {};
1924
- var style = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]).reduce(function(style, property) {
1925
- style[property] = "";
1926
- return style;
1927
- }, {});
1928
- if (!isHTMLElement(element) || !getNodeName(element)) return;
1929
- Object.assign(element.style, style);
1930
- Object.keys(attributes).forEach(function(attribute) {
1931
- element.removeAttribute(attribute);
1932
- });
1933
- });
1934
- };
1935
- }
1936
- var applyStyles_default;
1937
- function init_applyStyles() {
1938
- return (init_applyStyles = __esmMin((() => {
1939
- init_instanceOf();
1940
- applyStyles_default = {
1941
- name: "applyStyles",
1942
- enabled: true,
1943
- phase: "write",
1944
- fn: applyStyles,
1945
- effect: effect$2,
1946
- requires: ["computeStyles"]
1947
- };
1948
- })))();
1949
- }
1950
- //#endregion
1951
- //#region ../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js
1952
- function getBasePlacement(placement) {
1953
- return placement.split("-")[0];
1954
- }
1955
- //#endregion
1956
- //#region ../../node_modules/@popperjs/core/lib/utils/math.js
1957
- var max, min, round;
1958
- function init_math() {
1959
- return (init_math = __esmMin((() => {
1960
- max = Math.max;
1961
- min = Math.min;
1962
- round = Math.round;
1963
- })))();
1964
- }
1965
- //#endregion
1966
- //#region ../../node_modules/@popperjs/core/lib/utils/userAgent.js
1967
- function getUAString() {
1968
- var uaData = navigator.userAgentData;
1969
- if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) return uaData.brands.map(function(item) {
1970
- return item.brand + "/" + item.version;
1971
- }).join(" ");
1972
- return navigator.userAgent;
1973
- }
1974
- //#endregion
1975
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js
1976
- function isLayoutViewport() {
1977
- return !/^((?!chrome|android).)*safari/i.test(getUAString());
1978
- }
1979
- function init_isLayoutViewport() {
1980
- return (init_isLayoutViewport = __esmMin((() => {})))();
1981
- }
1982
- //#endregion
1983
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js
1984
- function getBoundingClientRect(element, includeScale, isFixedStrategy) {
1985
- if (includeScale === void 0) includeScale = false;
1986
- if (isFixedStrategy === void 0) isFixedStrategy = false;
1987
- var clientRect = element.getBoundingClientRect();
1988
- var scaleX = 1;
1989
- var scaleY = 1;
1990
- if (includeScale && isHTMLElement(element)) {
1991
- scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;
1992
- scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;
1993
- }
1994
- var visualViewport = (isElement(element) ? getWindow(element) : window).visualViewport;
1995
- var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;
1996
- var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;
1997
- var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;
1998
- var width = clientRect.width / scaleX;
1999
- var height = clientRect.height / scaleY;
2000
- return {
2001
- width,
2002
- height,
2003
- top: y,
2004
- right: x + width,
2005
- bottom: y + height,
2006
- left: x,
2007
- x,
2008
- y
2009
- };
2010
- }
2011
- function init_getBoundingClientRect() {
2012
- return (init_getBoundingClientRect = __esmMin((() => {
2013
- init_instanceOf();
2014
- init_math();
2015
- init_isLayoutViewport();
2016
- })))();
2017
- }
2018
- //#endregion
2019
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js
2020
- function getLayoutRect(element) {
2021
- var clientRect = getBoundingClientRect(element);
2022
- var width = element.offsetWidth;
2023
- var height = element.offsetHeight;
2024
- if (Math.abs(clientRect.width - width) <= 1) width = clientRect.width;
2025
- if (Math.abs(clientRect.height - height) <= 1) height = clientRect.height;
2026
- return {
2027
- x: element.offsetLeft,
2028
- y: element.offsetTop,
2029
- width,
2030
- height
2031
- };
2032
- }
2033
- function init_getLayoutRect() {
2034
- return (init_getLayoutRect = __esmMin((() => {
2035
- init_getBoundingClientRect();
2036
- })))();
2037
- }
2038
- //#endregion
2039
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/contains.js
2040
- function contains(parent, child) {
2041
- var rootNode = child.getRootNode && child.getRootNode();
2042
- if (parent.contains(child)) return true;
2043
- else if (rootNode && isShadowRoot(rootNode)) {
2044
- var next = child;
2045
- do {
2046
- if (next && parent.isSameNode(next)) return true;
2047
- next = next.parentNode || next.host;
2048
- } while (next);
2049
- }
2050
- return false;
2051
- }
2052
- function init_contains() {
2053
- return (init_contains = __esmMin((() => {
2054
- init_instanceOf();
2055
- })))();
2056
- }
2057
- //#endregion
2058
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js
2059
- function getComputedStyle$1(element) {
2060
- return getWindow(element).getComputedStyle(element);
2061
- }
2062
- function init_getComputedStyle() {
2063
- return (init_getComputedStyle = __esmMin((() => {})))();
2064
- }
2065
- //#endregion
2066
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js
2067
- function isTableElement(element) {
2068
- return [
2069
- "table",
2070
- "td",
2071
- "th"
2072
- ].indexOf(getNodeName(element)) >= 0;
2073
- }
2074
- function init_isTableElement() {
2075
- return (init_isTableElement = __esmMin((() => {})))();
2076
- }
2077
- //#endregion
2078
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js
2079
- function getDocumentElement(element) {
2080
- return ((isElement(element) ? element.ownerDocument : element.document) || window.document).documentElement;
2081
- }
2082
- function init_getDocumentElement() {
2083
- return (init_getDocumentElement = __esmMin((() => {
2084
- init_instanceOf();
2085
- })))();
2086
- }
2087
- //#endregion
2088
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js
2089
- function getParentNode(element) {
2090
- if (getNodeName(element) === "html") return element;
2091
- return element.assignedSlot || element.parentNode || (isShadowRoot(element) ? element.host : null) || getDocumentElement(element);
2092
- }
2093
- function init_getParentNode() {
2094
- return (init_getParentNode = __esmMin((() => {
2095
- init_getDocumentElement();
2096
- init_instanceOf();
2097
- })))();
2098
- }
2099
- //#endregion
2100
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js
2101
- function getTrueOffsetParent(element) {
2102
- if (!isHTMLElement(element) || getComputedStyle$1(element).position === "fixed") return null;
2103
- return element.offsetParent;
2104
- }
2105
- function getContainingBlock(element) {
2106
- var isFirefox = /firefox/i.test(getUAString());
2107
- if (/Trident/i.test(getUAString()) && isHTMLElement(element)) {
2108
- if (getComputedStyle$1(element).position === "fixed") return null;
2109
- }
2110
- var currentNode = getParentNode(element);
2111
- if (isShadowRoot(currentNode)) currentNode = currentNode.host;
2112
- while (isHTMLElement(currentNode) && ["html", "body"].indexOf(getNodeName(currentNode)) < 0) {
2113
- var css = getComputedStyle$1(currentNode);
2114
- if (css.transform !== "none" || css.perspective !== "none" || css.contain === "paint" || ["transform", "perspective"].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === "filter" || isFirefox && css.filter && css.filter !== "none") return currentNode;
2115
- else currentNode = currentNode.parentNode;
2116
- }
2117
- return null;
2118
- }
2119
- function getOffsetParent(element) {
2120
- var window = getWindow(element);
2121
- var offsetParent = getTrueOffsetParent(element);
2122
- while (offsetParent && isTableElement(offsetParent) && getComputedStyle$1(offsetParent).position === "static") offsetParent = getTrueOffsetParent(offsetParent);
2123
- if (offsetParent && (getNodeName(offsetParent) === "html" || getNodeName(offsetParent) === "body" && getComputedStyle$1(offsetParent).position === "static")) return window;
2124
- return offsetParent || getContainingBlock(element) || window;
2125
- }
2126
- function init_getOffsetParent() {
2127
- return (init_getOffsetParent = __esmMin((() => {
2128
- init_getComputedStyle();
2129
- init_instanceOf();
2130
- init_isTableElement();
2131
- init_getParentNode();
2132
- })))();
2133
- }
2134
- //#endregion
2135
- //#region ../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js
2136
- function getMainAxisFromPlacement(placement) {
2137
- return ["top", "bottom"].indexOf(placement) >= 0 ? "x" : "y";
2138
- }
2139
- //#endregion
2140
- //#region ../../node_modules/@popperjs/core/lib/utils/within.js
2141
- function within(min$3, value, max$3) {
2142
- return max(min$3, min(value, max$3));
2143
- }
2144
- function withinMaxClamp(min, value, max) {
2145
- var v = within(min, value, max);
2146
- return v > max ? max : v;
2147
- }
2148
- function init_within() {
2149
- return (init_within = __esmMin((() => {
2150
- init_math();
2151
- })))();
2152
- }
2153
- //#endregion
2154
- //#region ../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js
2155
- function getFreshSideObject() {
2156
- return {
2157
- top: 0,
2158
- right: 0,
2159
- bottom: 0,
2160
- left: 0
2161
- };
2162
- }
2163
- //#endregion
2164
- //#region ../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js
2165
- function mergePaddingObject(paddingObject) {
2166
- return Object.assign({}, getFreshSideObject(), paddingObject);
2167
- }
2168
- function init_mergePaddingObject() {
2169
- return (init_mergePaddingObject = __esmMin((() => {})))();
2170
- }
2171
- //#endregion
2172
- //#region ../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js
2173
- function expandToHashMap(value, keys) {
2174
- return keys.reduce(function(hashMap, key) {
2175
- hashMap[key] = value;
2176
- return hashMap;
2177
- }, {});
2178
- }
2179
- //#endregion
2180
- //#region ../../node_modules/@popperjs/core/lib/modifiers/arrow.js
2181
- function arrow(_ref) {
2182
- var _state$modifiersData$;
2183
- var state = _ref.state, name = _ref.name, options = _ref.options;
2184
- var arrowElement = state.elements.arrow;
2185
- var popperOffsets = state.modifiersData.popperOffsets;
2186
- var basePlacement = getBasePlacement(state.placement);
2187
- var axis = getMainAxisFromPlacement(basePlacement);
2188
- var len = ["left", "right"].indexOf(basePlacement) >= 0 ? "height" : "width";
2189
- if (!arrowElement || !popperOffsets) return;
2190
- var paddingObject = toPaddingObject(options.padding, state);
2191
- var arrowRect = getLayoutRect(arrowElement);
2192
- var minProp = axis === "y" ? "top" : left;
2193
- var maxProp = axis === "y" ? bottom : right;
2194
- var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];
2195
- var startDiff = popperOffsets[axis] - state.rects.reference[axis];
2196
- var arrowOffsetParent = getOffsetParent(arrowElement);
2197
- var clientSize = arrowOffsetParent ? axis === "y" ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;
2198
- var centerToReference = endDiff / 2 - startDiff / 2;
2199
- var min = paddingObject[minProp];
2200
- var max = clientSize - arrowRect[len] - paddingObject[maxProp];
2201
- var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;
2202
- var offset = within(min, center, max);
2203
- var axisProp = axis;
2204
- state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);
2205
- }
2206
- function effect$1(_ref2) {
2207
- var state = _ref2.state;
2208
- var _options$element = _ref2.options.element, arrowElement = _options$element === void 0 ? "[data-popper-arrow]" : _options$element;
2209
- if (arrowElement == null) return;
2210
- if (typeof arrowElement === "string") {
2211
- arrowElement = state.elements.popper.querySelector(arrowElement);
2212
- if (!arrowElement) return;
2213
- }
2214
- if (!contains(state.elements.popper, arrowElement)) return;
2215
- state.elements.arrow = arrowElement;
2216
- }
2217
- var toPaddingObject, arrow_default;
2218
- function init_arrow() {
2219
- return (init_arrow = __esmMin((() => {
2220
- init_getLayoutRect();
2221
- init_contains();
2222
- init_getOffsetParent();
2223
- init_within();
2224
- init_mergePaddingObject();
2225
- init_enums();
2226
- toPaddingObject = function toPaddingObject(padding, state) {
2227
- padding = typeof padding === "function" ? padding(Object.assign({}, state.rects, { placement: state.placement })) : padding;
2228
- return mergePaddingObject(typeof padding !== "number" ? padding : expandToHashMap(padding, basePlacements));
2229
- };
2230
- arrow_default = {
2231
- name: "arrow",
2232
- enabled: true,
2233
- phase: "main",
2234
- fn: arrow,
2235
- effect: effect$1,
2236
- requires: ["popperOffsets"],
2237
- requiresIfExists: ["preventOverflow"]
2238
- };
2239
- })))();
2240
- }
2241
- //#endregion
2242
- //#region ../../node_modules/@popperjs/core/lib/utils/getVariation.js
2243
- function getVariation(placement) {
2244
- return placement.split("-")[1];
2245
- }
2246
- //#endregion
2247
- //#region ../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js
2248
- function roundOffsetsByDPR(_ref, win) {
2249
- var x = _ref.x, y = _ref.y;
2250
- var dpr = win.devicePixelRatio || 1;
2251
- return {
2252
- x: round(x * dpr) / dpr || 0,
2253
- y: round(y * dpr) / dpr || 0
2254
- };
2255
- }
2256
- function mapToStyles(_ref2) {
2257
- var _Object$assign2;
2258
- var popper = _ref2.popper, popperRect = _ref2.popperRect, placement = _ref2.placement, variation = _ref2.variation, offsets = _ref2.offsets, position = _ref2.position, gpuAcceleration = _ref2.gpuAcceleration, adaptive = _ref2.adaptive, roundOffsets = _ref2.roundOffsets, isFixed = _ref2.isFixed;
2259
- var _offsets$x = offsets.x, x = _offsets$x === void 0 ? 0 : _offsets$x, _offsets$y = offsets.y, y = _offsets$y === void 0 ? 0 : _offsets$y;
2260
- var _ref3 = typeof roundOffsets === "function" ? roundOffsets({
2261
- x,
2262
- y
2263
- }) : {
2264
- x,
2265
- y
2266
- };
2267
- x = _ref3.x;
2268
- y = _ref3.y;
2269
- var hasX = offsets.hasOwnProperty("x");
2270
- var hasY = offsets.hasOwnProperty("y");
2271
- var sideX = left;
2272
- var sideY = "top";
2273
- var win = window;
2274
- if (adaptive) {
2275
- var offsetParent = getOffsetParent(popper);
2276
- var heightProp = "clientHeight";
2277
- var widthProp = "clientWidth";
2278
- if (offsetParent === getWindow(popper)) {
2279
- offsetParent = getDocumentElement(popper);
2280
- if (getComputedStyle$1(offsetParent).position !== "static" && position === "absolute") {
2281
- heightProp = "scrollHeight";
2282
- widthProp = "scrollWidth";
2283
- }
2284
- }
2285
- offsetParent = offsetParent;
2286
- if (placement === "top" || (placement === "left" || placement === "right") && variation === "end") {
2287
- sideY = bottom;
2288
- var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : offsetParent[heightProp];
2289
- y -= offsetY - popperRect.height;
2290
- y *= gpuAcceleration ? 1 : -1;
2291
- }
2292
- if (placement === "left" || (placement === "top" || placement === "bottom") && variation === "end") {
2293
- sideX = right;
2294
- var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : offsetParent[widthProp];
2295
- x -= offsetX - popperRect.width;
2296
- x *= gpuAcceleration ? 1 : -1;
2297
- }
2298
- }
2299
- var commonStyles = Object.assign({ position }, adaptive && unsetSides);
2300
- var _ref4 = roundOffsets === true ? roundOffsetsByDPR({
2301
- x,
2302
- y
2303
- }, getWindow(popper)) : {
2304
- x,
2305
- y
2306
- };
2307
- x = _ref4.x;
2308
- y = _ref4.y;
2309
- if (gpuAcceleration) {
2310
- var _Object$assign;
2311
- return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? "0" : "", _Object$assign[sideX] = hasX ? "0" : "", _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? "translate(" + x + "px, " + y + "px)" : "translate3d(" + x + "px, " + y + "px, 0)", _Object$assign));
2312
- }
2313
- return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + "px" : "", _Object$assign2[sideX] = hasX ? x + "px" : "", _Object$assign2.transform = "", _Object$assign2));
2314
- }
2315
- function computeStyles(_ref5) {
2316
- var state = _ref5.state, options = _ref5.options;
2317
- var _options$gpuAccelerat = options.gpuAcceleration, gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat, _options$adaptive = options.adaptive, adaptive = _options$adaptive === void 0 ? true : _options$adaptive, _options$roundOffsets = options.roundOffsets, roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;
2318
- var commonStyles = {
2319
- placement: getBasePlacement(state.placement),
2320
- variation: getVariation(state.placement),
2321
- popper: state.elements.popper,
2322
- popperRect: state.rects.popper,
2323
- gpuAcceleration,
2324
- isFixed: state.options.strategy === "fixed"
2325
- };
2326
- if (state.modifiersData.popperOffsets != null) state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {
2327
- offsets: state.modifiersData.popperOffsets,
2328
- position: state.options.strategy,
2329
- adaptive,
2330
- roundOffsets
2331
- })));
2332
- if (state.modifiersData.arrow != null) state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {
2333
- offsets: state.modifiersData.arrow,
2334
- position: "absolute",
2335
- adaptive: false,
2336
- roundOffsets
2337
- })));
2338
- state.attributes.popper = Object.assign({}, state.attributes.popper, { "data-popper-placement": state.placement });
2339
- }
2340
- var unsetSides, computeStyles_default;
2341
- function init_computeStyles() {
2342
- return (init_computeStyles = __esmMin((() => {
2343
- init_enums();
2344
- init_getOffsetParent();
2345
- init_getDocumentElement();
2346
- init_getComputedStyle();
2347
- init_math();
2348
- unsetSides = {
2349
- top: "auto",
2350
- right: "auto",
2351
- bottom: "auto",
2352
- left: "auto"
2353
- };
2354
- computeStyles_default = {
2355
- name: "computeStyles",
2356
- enabled: true,
2357
- phase: "beforeWrite",
2358
- fn: computeStyles,
2359
- data: {}
2360
- };
2361
- })))();
2362
- }
2363
- //#endregion
2364
- //#region ../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js
2365
- function effect(_ref) {
2366
- var state = _ref.state, instance = _ref.instance, options = _ref.options;
2367
- var _options$scroll = options.scroll, scroll = _options$scroll === void 0 ? true : _options$scroll, _options$resize = options.resize, resize = _options$resize === void 0 ? true : _options$resize;
2368
- var window = getWindow(state.elements.popper);
2369
- var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);
2370
- if (scroll) scrollParents.forEach(function(scrollParent) {
2371
- scrollParent.addEventListener("scroll", instance.update, passive);
2372
- });
2373
- if (resize) window.addEventListener("resize", instance.update, passive);
2374
- return function() {
2375
- if (scroll) scrollParents.forEach(function(scrollParent) {
2376
- scrollParent.removeEventListener("scroll", instance.update, passive);
2377
- });
2378
- if (resize) window.removeEventListener("resize", instance.update, passive);
2379
- };
2380
- }
2381
- var passive, eventListeners_default;
2382
- function init_eventListeners() {
2383
- return (init_eventListeners = __esmMin((() => {
2384
- passive = { passive: true };
2385
- eventListeners_default = {
2386
- name: "eventListeners",
2387
- enabled: true,
2388
- phase: "write",
2389
- fn: function fn() {},
2390
- effect,
2391
- data: {}
2392
- };
2393
- })))();
2394
- }
2395
- //#endregion
2396
- //#region ../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js
2397
- function getOppositePlacement(placement) {
2398
- return placement.replace(/left|right|bottom|top/g, function(matched) {
2399
- return hash$1[matched];
2400
- });
2401
- }
2402
- var hash$1;
2403
- function init_getOppositePlacement() {
2404
- return (init_getOppositePlacement = __esmMin((() => {
2405
- hash$1 = {
2406
- left: "right",
2407
- right: "left",
2408
- bottom: "top",
2409
- top: "bottom"
2410
- };
2411
- })))();
2412
- }
2413
- //#endregion
2414
- //#region ../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js
2415
- function getOppositeVariationPlacement(placement) {
2416
- return placement.replace(/start|end/g, function(matched) {
2417
- return hash[matched];
2418
- });
2419
- }
2420
- var hash;
2421
- function init_getOppositeVariationPlacement() {
2422
- return (init_getOppositeVariationPlacement = __esmMin((() => {
2423
- hash = {
2424
- start: "end",
2425
- end: "start"
2426
- };
2427
- })))();
2428
- }
2429
- //#endregion
2430
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js
2431
- function getWindowScroll(node) {
2432
- var win = getWindow(node);
2433
- return {
2434
- scrollLeft: win.pageXOffset,
2435
- scrollTop: win.pageYOffset
2436
- };
2437
- }
2438
- function init_getWindowScroll() {
2439
- return (init_getWindowScroll = __esmMin((() => {})))();
2440
- }
2441
- //#endregion
2442
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js
2443
- function getWindowScrollBarX(element) {
2444
- return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;
2445
- }
2446
- function init_getWindowScrollBarX() {
2447
- return (init_getWindowScrollBarX = __esmMin((() => {
2448
- init_getBoundingClientRect();
2449
- init_getDocumentElement();
2450
- init_getWindowScroll();
2451
- })))();
2452
- }
2453
- //#endregion
2454
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js
2455
- function getViewportRect(element, strategy) {
2456
- var win = getWindow(element);
2457
- var html = getDocumentElement(element);
2458
- var visualViewport = win.visualViewport;
2459
- var width = html.clientWidth;
2460
- var height = html.clientHeight;
2461
- var x = 0;
2462
- var y = 0;
2463
- if (visualViewport) {
2464
- width = visualViewport.width;
2465
- height = visualViewport.height;
2466
- var layoutViewport = isLayoutViewport();
2467
- if (layoutViewport || !layoutViewport && strategy === "fixed") {
2468
- x = visualViewport.offsetLeft;
2469
- y = visualViewport.offsetTop;
2470
- }
2471
- }
2472
- return {
2473
- width,
2474
- height,
2475
- x: x + getWindowScrollBarX(element),
2476
- y
2477
- };
2478
- }
2479
- function init_getViewportRect() {
2480
- return (init_getViewportRect = __esmMin((() => {
2481
- init_getDocumentElement();
2482
- init_getWindowScrollBarX();
2483
- init_isLayoutViewport();
2484
- })))();
2485
- }
2486
- //#endregion
2487
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js
2488
- function getDocumentRect(element) {
2489
- var _element$ownerDocumen;
2490
- var html = getDocumentElement(element);
2491
- var winScroll = getWindowScroll(element);
2492
- var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;
2493
- var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);
2494
- var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);
2495
- var x = -winScroll.scrollLeft + getWindowScrollBarX(element);
2496
- var y = -winScroll.scrollTop;
2497
- if (getComputedStyle$1(body || html).direction === "rtl") x += max(html.clientWidth, body ? body.clientWidth : 0) - width;
2498
- return {
2499
- width,
2500
- height,
2501
- x,
2502
- y
2503
- };
2504
- }
2505
- function init_getDocumentRect() {
2506
- return (init_getDocumentRect = __esmMin((() => {
2507
- init_getDocumentElement();
2508
- init_getComputedStyle();
2509
- init_getWindowScrollBarX();
2510
- init_getWindowScroll();
2511
- init_math();
2512
- })))();
2513
- }
2514
- //#endregion
2515
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js
2516
- function isScrollParent(element) {
2517
- var _getComputedStyle = getComputedStyle$1(element), overflow = _getComputedStyle.overflow, overflowX = _getComputedStyle.overflowX, overflowY = _getComputedStyle.overflowY;
2518
- return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);
2519
- }
2520
- function init_isScrollParent() {
2521
- return (init_isScrollParent = __esmMin((() => {
2522
- init_getComputedStyle();
2523
- })))();
2524
- }
2525
- //#endregion
2526
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js
2527
- function getScrollParent(node) {
2528
- if ([
2529
- "html",
2530
- "body",
2531
- "#document"
2532
- ].indexOf(getNodeName(node)) >= 0) return node.ownerDocument.body;
2533
- if (isHTMLElement(node) && isScrollParent(node)) return node;
2534
- return getScrollParent(getParentNode(node));
2535
- }
2536
- function init_getScrollParent() {
2537
- return (init_getScrollParent = __esmMin((() => {
2538
- init_getParentNode();
2539
- init_isScrollParent();
2540
- init_instanceOf();
2541
- })))();
2542
- }
2543
- //#endregion
2544
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js
2545
- function listScrollParents(element, list) {
2546
- var _element$ownerDocumen;
2547
- if (list === void 0) list = [];
2548
- var scrollParent = getScrollParent(element);
2549
- var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);
2550
- var win = getWindow(scrollParent);
2551
- var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;
2552
- var updatedList = list.concat(target);
2553
- return isBody ? updatedList : updatedList.concat(listScrollParents(getParentNode(target)));
2554
- }
2555
- function init_listScrollParents() {
2556
- return (init_listScrollParents = __esmMin((() => {
2557
- init_getScrollParent();
2558
- init_getParentNode();
2559
- init_isScrollParent();
2560
- })))();
2561
- }
2562
- //#endregion
2563
- //#region ../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js
2564
- function rectToClientRect(rect) {
2565
- return Object.assign({}, rect, {
2566
- left: rect.x,
2567
- top: rect.y,
2568
- right: rect.x + rect.width,
2569
- bottom: rect.y + rect.height
2570
- });
2571
- }
2572
- //#endregion
2573
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js
2574
- function getInnerBoundingClientRect(element, strategy) {
2575
- var rect = getBoundingClientRect(element, false, strategy === "fixed");
2576
- rect.top = rect.top + element.clientTop;
2577
- rect.left = rect.left + element.clientLeft;
2578
- rect.bottom = rect.top + element.clientHeight;
2579
- rect.right = rect.left + element.clientWidth;
2580
- rect.width = element.clientWidth;
2581
- rect.height = element.clientHeight;
2582
- rect.x = rect.left;
2583
- rect.y = rect.top;
2584
- return rect;
2585
- }
2586
- function getClientRectFromMixedType(element, clippingParent, strategy) {
2587
- return clippingParent === "viewport" ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));
2588
- }
2589
- function getClippingParents(element) {
2590
- var clippingParents = listScrollParents(getParentNode(element));
2591
- var clipperElement = ["absolute", "fixed"].indexOf(getComputedStyle$1(element).position) >= 0 && isHTMLElement(element) ? getOffsetParent(element) : element;
2592
- if (!isElement(clipperElement)) return [];
2593
- return clippingParents.filter(function(clippingParent) {
2594
- return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== "body";
2595
- });
2596
- }
2597
- function getClippingRect(element, boundary, rootBoundary, strategy) {
2598
- var mainClippingParents = boundary === "clippingParents" ? getClippingParents(element) : [].concat(boundary);
2599
- var clippingParents = [].concat(mainClippingParents, [rootBoundary]);
2600
- var firstClippingParent = clippingParents[0];
2601
- var clippingRect = clippingParents.reduce(function(accRect, clippingParent) {
2602
- var rect = getClientRectFromMixedType(element, clippingParent, strategy);
2603
- accRect.top = max(rect.top, accRect.top);
2604
- accRect.right = min(rect.right, accRect.right);
2605
- accRect.bottom = min(rect.bottom, accRect.bottom);
2606
- accRect.left = max(rect.left, accRect.left);
2607
- return accRect;
2608
- }, getClientRectFromMixedType(element, firstClippingParent, strategy));
2609
- clippingRect.width = clippingRect.right - clippingRect.left;
2610
- clippingRect.height = clippingRect.bottom - clippingRect.top;
2611
- clippingRect.x = clippingRect.left;
2612
- clippingRect.y = clippingRect.top;
2613
- return clippingRect;
2614
- }
2615
- function init_getClippingRect() {
2616
- return (init_getClippingRect = __esmMin((() => {
2617
- init_enums();
2618
- init_getViewportRect();
2619
- init_getDocumentRect();
2620
- init_listScrollParents();
2621
- init_getOffsetParent();
2622
- init_getDocumentElement();
2623
- init_getComputedStyle();
2624
- init_instanceOf();
2625
- init_getBoundingClientRect();
2626
- init_getParentNode();
2627
- init_contains();
2628
- init_math();
2629
- })))();
2630
- }
2631
- //#endregion
2632
- //#region ../../node_modules/@popperjs/core/lib/utils/computeOffsets.js
2633
- function computeOffsets(_ref) {
2634
- var reference = _ref.reference, element = _ref.element, placement = _ref.placement;
2635
- var basePlacement = placement ? getBasePlacement(placement) : null;
2636
- var variation = placement ? getVariation(placement) : null;
2637
- var commonX = reference.x + reference.width / 2 - element.width / 2;
2638
- var commonY = reference.y + reference.height / 2 - element.height / 2;
2639
- var offsets;
2640
- switch (basePlacement) {
2641
- case "top":
2642
- offsets = {
2643
- x: commonX,
2644
- y: reference.y - element.height
2645
- };
2646
- break;
2647
- case bottom:
2648
- offsets = {
2649
- x: commonX,
2650
- y: reference.y + reference.height
2651
- };
2652
- break;
2653
- case right:
2654
- offsets = {
2655
- x: reference.x + reference.width,
2656
- y: commonY
2657
- };
2658
- break;
2659
- case left:
2660
- offsets = {
2661
- x: reference.x - element.width,
2662
- y: commonY
2663
- };
2664
- break;
2665
- default: offsets = {
2666
- x: reference.x,
2667
- y: reference.y
2668
- };
2669
- }
2670
- var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;
2671
- if (mainAxis != null) {
2672
- var len = mainAxis === "y" ? "height" : "width";
2673
- switch (variation) {
2674
- case start:
2675
- offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);
2676
- break;
2677
- case "end": offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);
2678
- }
2679
- }
2680
- return offsets;
2681
- }
2682
- function init_computeOffsets() {
2683
- return (init_computeOffsets = __esmMin((() => {
2684
- init_enums();
2685
- })))();
2686
- }
2687
- //#endregion
2688
- //#region ../../node_modules/@popperjs/core/lib/utils/detectOverflow.js
2689
- function detectOverflow(state, options) {
2690
- if (options === void 0) options = {};
2691
- var _options = options, _options$placement = _options.placement, placement = _options$placement === void 0 ? state.placement : _options$placement, _options$strategy = _options.strategy, strategy = _options$strategy === void 0 ? state.strategy : _options$strategy, _options$boundary = _options.boundary, boundary = _options$boundary === void 0 ? clippingParents : _options$boundary, _options$rootBoundary = _options.rootBoundary, rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary, _options$elementConte = _options.elementContext, elementContext = _options$elementConte === void 0 ? popper : _options$elementConte, _options$altBoundary = _options.altBoundary, altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary, _options$padding = _options.padding, padding = _options$padding === void 0 ? 0 : _options$padding;
2692
- var paddingObject = mergePaddingObject(typeof padding !== "number" ? padding : expandToHashMap(padding, basePlacements));
2693
- var altContext = elementContext === "popper" ? reference : popper;
2694
- var popperRect = state.rects.popper;
2695
- var element = state.elements[altBoundary ? altContext : elementContext];
2696
- var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);
2697
- var referenceClientRect = getBoundingClientRect(state.elements.reference);
2698
- var popperOffsets = computeOffsets({
2699
- reference: referenceClientRect,
2700
- element: popperRect,
2701
- strategy: "absolute",
2702
- placement
2703
- });
2704
- var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));
2705
- var elementClientRect = elementContext === "popper" ? popperClientRect : referenceClientRect;
2706
- var overflowOffsets = {
2707
- top: clippingClientRect.top - elementClientRect.top + paddingObject.top,
2708
- bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,
2709
- left: clippingClientRect.left - elementClientRect.left + paddingObject.left,
2710
- right: elementClientRect.right - clippingClientRect.right + paddingObject.right
2711
- };
2712
- var offsetData = state.modifiersData.offset;
2713
- if (elementContext === "popper" && offsetData) {
2714
- var offset = offsetData[placement];
2715
- Object.keys(overflowOffsets).forEach(function(key) {
2716
- var multiply = ["right", "bottom"].indexOf(key) >= 0 ? 1 : -1;
2717
- var axis = ["top", "bottom"].indexOf(key) >= 0 ? "y" : "x";
2718
- overflowOffsets[key] += offset[axis] * multiply;
2719
- });
2720
- }
2721
- return overflowOffsets;
2722
- }
2723
- function init_detectOverflow() {
2724
- return (init_detectOverflow = __esmMin((() => {
2725
- init_getClippingRect();
2726
- init_getDocumentElement();
2727
- init_getBoundingClientRect();
2728
- init_computeOffsets();
2729
- init_enums();
2730
- init_instanceOf();
2731
- init_mergePaddingObject();
2732
- })))();
2733
- }
2734
- //#endregion
2735
- //#region ../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js
2736
- function computeAutoPlacement(state, options) {
2737
- if (options === void 0) options = {};
2738
- var _options = options, placement = _options.placement, boundary = _options.boundary, rootBoundary = _options.rootBoundary, padding = _options.padding, flipVariations = _options.flipVariations, _options$allowedAutoP = _options.allowedAutoPlacements, allowedAutoPlacements = _options$allowedAutoP === void 0 ? placements : _options$allowedAutoP;
2739
- var variation = getVariation(placement);
2740
- var placements$1 = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function(placement) {
2741
- return getVariation(placement) === variation;
2742
- }) : basePlacements;
2743
- var allowedPlacements = placements$1.filter(function(placement) {
2744
- return allowedAutoPlacements.indexOf(placement) >= 0;
2745
- });
2746
- if (allowedPlacements.length === 0) allowedPlacements = placements$1;
2747
- var overflows = allowedPlacements.reduce(function(acc, placement) {
2748
- acc[placement] = detectOverflow(state, {
2749
- placement,
2750
- boundary,
2751
- rootBoundary,
2752
- padding
2753
- })[getBasePlacement(placement)];
2754
- return acc;
2755
- }, {});
2756
- return Object.keys(overflows).sort(function(a, b) {
2757
- return overflows[a] - overflows[b];
2758
- });
2759
- }
2760
- function init_computeAutoPlacement() {
2761
- return (init_computeAutoPlacement = __esmMin((() => {
2762
- init_enums();
2763
- init_detectOverflow();
2764
- })))();
2765
- }
2766
- //#endregion
2767
- //#region ../../node_modules/@popperjs/core/lib/modifiers/flip.js
2768
- function getExpandedFallbackPlacements(placement) {
2769
- if (getBasePlacement(placement) === "auto") return [];
2770
- var oppositePlacement = getOppositePlacement(placement);
2771
- return [
2772
- getOppositeVariationPlacement(placement),
2773
- oppositePlacement,
2774
- getOppositeVariationPlacement(oppositePlacement)
2775
- ];
2776
- }
2777
- function flip(_ref) {
2778
- var state = _ref.state, options = _ref.options, name = _ref.name;
2779
- if (state.modifiersData[name]._skip) return;
2780
- var _options$mainAxis = options.mainAxis, checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis, _options$altAxis = options.altAxis, checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis, specifiedFallbackPlacements = options.fallbackPlacements, padding = options.padding, boundary = options.boundary, rootBoundary = options.rootBoundary, altBoundary = options.altBoundary, _options$flipVariatio = options.flipVariations, flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio, allowedAutoPlacements = options.allowedAutoPlacements;
2781
- var preferredPlacement = state.options.placement;
2782
- var isBasePlacement = getBasePlacement(preferredPlacement) === preferredPlacement;
2783
- var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));
2784
- var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function(acc, placement) {
2785
- return acc.concat(getBasePlacement(placement) === "auto" ? computeAutoPlacement(state, {
2786
- placement,
2787
- boundary,
2788
- rootBoundary,
2789
- padding,
2790
- flipVariations,
2791
- allowedAutoPlacements
2792
- }) : placement);
2793
- }, []);
2794
- var referenceRect = state.rects.reference;
2795
- var popperRect = state.rects.popper;
2796
- var checksMap = /* @__PURE__ */ new Map();
2797
- var makeFallbackChecks = true;
2798
- var firstFittingPlacement = placements[0];
2799
- for (var i = 0; i < placements.length; i++) {
2800
- var placement = placements[i];
2801
- var _basePlacement = getBasePlacement(placement);
2802
- var isStartVariation = getVariation(placement) === start;
2803
- var isVertical = ["top", bottom].indexOf(_basePlacement) >= 0;
2804
- var len = isVertical ? "width" : "height";
2805
- var overflow = detectOverflow(state, {
2806
- placement,
2807
- boundary,
2808
- rootBoundary,
2809
- altBoundary,
2810
- padding
2811
- });
2812
- var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : "top";
2813
- if (referenceRect[len] > popperRect[len]) mainVariationSide = getOppositePlacement(mainVariationSide);
2814
- var altVariationSide = getOppositePlacement(mainVariationSide);
2815
- var checks = [];
2816
- if (checkMainAxis) checks.push(overflow[_basePlacement] <= 0);
2817
- if (checkAltAxis) checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);
2818
- if (checks.every(function(check) {
2819
- return check;
2820
- })) {
2821
- firstFittingPlacement = placement;
2822
- makeFallbackChecks = false;
2823
- break;
2824
- }
2825
- checksMap.set(placement, checks);
2826
- }
2827
- if (makeFallbackChecks) {
2828
- var numberOfChecks = flipVariations ? 3 : 1;
2829
- var _loop = function _loop(_i) {
2830
- var fittingPlacement = placements.find(function(placement) {
2831
- var checks = checksMap.get(placement);
2832
- if (checks) return checks.slice(0, _i).every(function(check) {
2833
- return check;
2834
- });
2835
- });
2836
- if (fittingPlacement) {
2837
- firstFittingPlacement = fittingPlacement;
2838
- return "break";
2839
- }
2840
- };
2841
- for (var _i = numberOfChecks; _i > 0; _i--) if (_loop(_i) === "break") break;
2842
- }
2843
- if (state.placement !== firstFittingPlacement) {
2844
- state.modifiersData[name]._skip = true;
2845
- state.placement = firstFittingPlacement;
2846
- state.reset = true;
2847
- }
2848
- }
2849
- var flip_default;
2850
- function init_flip() {
2851
- return (init_flip = __esmMin((() => {
2852
- init_getOppositePlacement();
2853
- init_getOppositeVariationPlacement();
2854
- init_detectOverflow();
2855
- init_computeAutoPlacement();
2856
- init_enums();
2857
- flip_default = {
2858
- name: "flip",
2859
- enabled: true,
2860
- phase: "main",
2861
- fn: flip,
2862
- requiresIfExists: ["offset"],
2863
- data: { _skip: false }
2864
- };
2865
- })))();
2866
- }
2867
- //#endregion
2868
- //#region ../../node_modules/@popperjs/core/lib/modifiers/hide.js
2869
- function getSideOffsets(overflow, rect, preventedOffsets) {
2870
- if (preventedOffsets === void 0) preventedOffsets = {
2871
- x: 0,
2872
- y: 0
2873
- };
2874
- return {
2875
- top: overflow.top - rect.height - preventedOffsets.y,
2876
- right: overflow.right - rect.width + preventedOffsets.x,
2877
- bottom: overflow.bottom - rect.height + preventedOffsets.y,
2878
- left: overflow.left - rect.width - preventedOffsets.x
2879
- };
2880
- }
2881
- function isAnySideFullyClipped(overflow) {
2882
- return [
2883
- "top",
2884
- right,
2885
- bottom,
2886
- left
2887
- ].some(function(side) {
2888
- return overflow[side] >= 0;
2889
- });
2890
- }
2891
- function hide(_ref) {
2892
- var state = _ref.state, name = _ref.name;
2893
- var referenceRect = state.rects.reference;
2894
- var popperRect = state.rects.popper;
2895
- var preventedOffsets = state.modifiersData.preventOverflow;
2896
- var referenceOverflow = detectOverflow(state, { elementContext: "reference" });
2897
- var popperAltOverflow = detectOverflow(state, { altBoundary: true });
2898
- var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);
2899
- var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);
2900
- var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);
2901
- var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);
2902
- state.modifiersData[name] = {
2903
- referenceClippingOffsets,
2904
- popperEscapeOffsets,
2905
- isReferenceHidden,
2906
- hasPopperEscaped
2907
- };
2908
- state.attributes.popper = Object.assign({}, state.attributes.popper, {
2909
- "data-popper-reference-hidden": isReferenceHidden,
2910
- "data-popper-escaped": hasPopperEscaped
2911
- });
2912
- }
2913
- var hide_default;
2914
- function init_hide() {
2915
- return (init_hide = __esmMin((() => {
2916
- init_enums();
2917
- init_detectOverflow();
2918
- hide_default = {
2919
- name: "hide",
2920
- enabled: true,
2921
- phase: "main",
2922
- requiresIfExists: ["preventOverflow"],
2923
- fn: hide
2924
- };
2925
- })))();
2926
- }
2927
- //#endregion
2928
- //#region ../../node_modules/@popperjs/core/lib/modifiers/offset.js
2929
- function distanceAndSkiddingToXY(placement, rects, offset) {
2930
- var basePlacement = getBasePlacement(placement);
2931
- var invertDistance = ["left", "top"].indexOf(basePlacement) >= 0 ? -1 : 1;
2932
- var _ref = typeof offset === "function" ? offset(Object.assign({}, rects, { placement })) : offset, skidding = _ref[0], distance = _ref[1];
2933
- skidding = skidding || 0;
2934
- distance = (distance || 0) * invertDistance;
2935
- return ["left", "right"].indexOf(basePlacement) >= 0 ? {
2936
- x: distance,
2937
- y: skidding
2938
- } : {
2939
- x: skidding,
2940
- y: distance
2941
- };
2942
- }
2943
- function offset(_ref2) {
2944
- var state = _ref2.state, options = _ref2.options, name = _ref2.name;
2945
- var _options$offset = options.offset, offset = _options$offset === void 0 ? [0, 0] : _options$offset;
2946
- var data = placements.reduce(function(acc, placement) {
2947
- acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);
2948
- return acc;
2949
- }, {});
2950
- var _data$state$placement = data[state.placement], x = _data$state$placement.x, y = _data$state$placement.y;
2951
- if (state.modifiersData.popperOffsets != null) {
2952
- state.modifiersData.popperOffsets.x += x;
2953
- state.modifiersData.popperOffsets.y += y;
2954
- }
2955
- state.modifiersData[name] = data;
2956
- }
2957
- var offset_default;
2958
- function init_offset() {
2959
- return (init_offset = __esmMin((() => {
2960
- init_enums();
2961
- offset_default = {
2962
- name: "offset",
2963
- enabled: true,
2964
- phase: "main",
2965
- requires: ["popperOffsets"],
2966
- fn: offset
2967
- };
2968
- })))();
2969
- }
2970
- //#endregion
2971
- //#region ../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js
2972
- function popperOffsets(_ref) {
2973
- var state = _ref.state, name = _ref.name;
2974
- state.modifiersData[name] = computeOffsets({
2975
- reference: state.rects.reference,
2976
- element: state.rects.popper,
2977
- strategy: "absolute",
2978
- placement: state.placement
2979
- });
2980
- }
2981
- var popperOffsets_default;
2982
- function init_popperOffsets() {
2983
- return (init_popperOffsets = __esmMin((() => {
2984
- init_computeOffsets();
2985
- popperOffsets_default = {
2986
- name: "popperOffsets",
2987
- enabled: true,
2988
- phase: "read",
2989
- fn: popperOffsets,
2990
- data: {}
2991
- };
2992
- })))();
2993
- }
2994
- //#endregion
2995
- //#region ../../node_modules/@popperjs/core/lib/utils/getAltAxis.js
2996
- function getAltAxis(axis) {
2997
- return axis === "x" ? "y" : "x";
2998
- }
2999
- //#endregion
3000
- //#region ../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js
3001
- function preventOverflow(_ref) {
3002
- var state = _ref.state, options = _ref.options, name = _ref.name;
3003
- var _options$mainAxis = options.mainAxis, checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis, _options$altAxis = options.altAxis, checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis, boundary = options.boundary, rootBoundary = options.rootBoundary, altBoundary = options.altBoundary, padding = options.padding, _options$tether = options.tether, tether = _options$tether === void 0 ? true : _options$tether, _options$tetherOffset = options.tetherOffset, tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;
3004
- var overflow = detectOverflow(state, {
3005
- boundary,
3006
- rootBoundary,
3007
- padding,
3008
- altBoundary
3009
- });
3010
- var basePlacement = getBasePlacement(state.placement);
3011
- var variation = getVariation(state.placement);
3012
- var isBasePlacement = !variation;
3013
- var mainAxis = getMainAxisFromPlacement(basePlacement);
3014
- var altAxis = getAltAxis(mainAxis);
3015
- var popperOffsets = state.modifiersData.popperOffsets;
3016
- var referenceRect = state.rects.reference;
3017
- var popperRect = state.rects.popper;
3018
- var tetherOffsetValue = typeof tetherOffset === "function" ? tetherOffset(Object.assign({}, state.rects, { placement: state.placement })) : tetherOffset;
3019
- var normalizedTetherOffsetValue = typeof tetherOffsetValue === "number" ? {
3020
- mainAxis: tetherOffsetValue,
3021
- altAxis: tetherOffsetValue
3022
- } : Object.assign({
3023
- mainAxis: 0,
3024
- altAxis: 0
3025
- }, tetherOffsetValue);
3026
- var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;
3027
- var data = {
3028
- x: 0,
3029
- y: 0
3030
- };
3031
- if (!popperOffsets) return;
3032
- if (checkMainAxis) {
3033
- var _offsetModifierState$;
3034
- var mainSide = mainAxis === "y" ? "top" : left;
3035
- var altSide = mainAxis === "y" ? bottom : right;
3036
- var len = mainAxis === "y" ? "height" : "width";
3037
- var offset = popperOffsets[mainAxis];
3038
- var min$2 = offset + overflow[mainSide];
3039
- var max$2 = offset - overflow[altSide];
3040
- var additive = tether ? -popperRect[len] / 2 : 0;
3041
- var minLen = variation === "start" ? referenceRect[len] : popperRect[len];
3042
- var maxLen = variation === "start" ? -popperRect[len] : -referenceRect[len];
3043
- var arrowElement = state.elements.arrow;
3044
- var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {
3045
- width: 0,
3046
- height: 0
3047
- };
3048
- var arrowPaddingObject = state.modifiersData["arrow#persistent"] ? state.modifiersData["arrow#persistent"].padding : getFreshSideObject();
3049
- var arrowPaddingMin = arrowPaddingObject[mainSide];
3050
- var arrowPaddingMax = arrowPaddingObject[altSide];
3051
- var arrowLen = within(0, referenceRect[len], arrowRect[len]);
3052
- var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;
3053
- var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;
3054
- var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);
3055
- var clientOffset = arrowOffsetParent ? mainAxis === "y" ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;
3056
- var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;
3057
- var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;
3058
- var tetherMax = offset + maxOffset - offsetModifierValue;
3059
- var preventedOffset = within(tether ? min(min$2, tetherMin) : min$2, offset, tether ? max(max$2, tetherMax) : max$2);
3060
- popperOffsets[mainAxis] = preventedOffset;
3061
- data[mainAxis] = preventedOffset - offset;
3062
- }
3063
- if (checkAltAxis) {
3064
- var _offsetModifierState$2;
3065
- var _mainSide = mainAxis === "x" ? "top" : left;
3066
- var _altSide = mainAxis === "x" ? bottom : right;
3067
- var _offset = popperOffsets[altAxis];
3068
- var _len = altAxis === "y" ? "height" : "width";
3069
- var _min = _offset + overflow[_mainSide];
3070
- var _max = _offset - overflow[_altSide];
3071
- var isOriginSide = ["top", left].indexOf(basePlacement) !== -1;
3072
- var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;
3073
- var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;
3074
- var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;
3075
- var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);
3076
- popperOffsets[altAxis] = _preventedOffset;
3077
- data[altAxis] = _preventedOffset - _offset;
3078
- }
3079
- state.modifiersData[name] = data;
3080
- }
3081
- var preventOverflow_default;
3082
- function init_preventOverflow() {
3083
- return (init_preventOverflow = __esmMin((() => {
3084
- init_enums();
3085
- init_within();
3086
- init_getLayoutRect();
3087
- init_getOffsetParent();
3088
- init_detectOverflow();
3089
- init_math();
3090
- preventOverflow_default = {
3091
- name: "preventOverflow",
3092
- enabled: true,
3093
- phase: "main",
3094
- fn: preventOverflow,
3095
- requiresIfExists: ["offset"]
3096
- };
3097
- })))();
3098
- }
3099
- //#endregion
3100
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js
3101
- function getHTMLElementScroll(element) {
3102
- return {
3103
- scrollLeft: element.scrollLeft,
3104
- scrollTop: element.scrollTop
3105
- };
3106
- }
3107
- //#endregion
3108
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js
3109
- function getNodeScroll(node) {
3110
- if (node === getWindow(node) || !isHTMLElement(node)) return getWindowScroll(node);
3111
- else return getHTMLElementScroll(node);
3112
- }
3113
- function init_getNodeScroll() {
3114
- return (init_getNodeScroll = __esmMin((() => {
3115
- init_getWindowScroll();
3116
- init_instanceOf();
3117
- })))();
3118
- }
3119
- //#endregion
3120
- //#region ../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js
3121
- function isElementScaled(element) {
3122
- var rect = element.getBoundingClientRect();
3123
- var scaleX = round(rect.width) / element.offsetWidth || 1;
3124
- var scaleY = round(rect.height) / element.offsetHeight || 1;
3125
- return scaleX !== 1 || scaleY !== 1;
3126
- }
3127
- function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {
3128
- if (isFixed === void 0) isFixed = false;
3129
- var isOffsetParentAnElement = isHTMLElement(offsetParent);
3130
- var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);
3131
- var documentElement = getDocumentElement(offsetParent);
3132
- var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);
3133
- var scroll = {
3134
- scrollLeft: 0,
3135
- scrollTop: 0
3136
- };
3137
- var offsets = {
3138
- x: 0,
3139
- y: 0
3140
- };
3141
- if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {
3142
- if (getNodeName(offsetParent) !== "body" || isScrollParent(documentElement)) scroll = getNodeScroll(offsetParent);
3143
- if (isHTMLElement(offsetParent)) {
3144
- offsets = getBoundingClientRect(offsetParent, true);
3145
- offsets.x += offsetParent.clientLeft;
3146
- offsets.y += offsetParent.clientTop;
3147
- } else if (documentElement) offsets.x = getWindowScrollBarX(documentElement);
3148
- }
3149
- return {
3150
- x: rect.left + scroll.scrollLeft - offsets.x,
3151
- y: rect.top + scroll.scrollTop - offsets.y,
3152
- width: rect.width,
3153
- height: rect.height
3154
- };
3155
- }
3156
- function init_getCompositeRect() {
3157
- return (init_getCompositeRect = __esmMin((() => {
3158
- init_getBoundingClientRect();
3159
- init_getNodeScroll();
3160
- init_instanceOf();
3161
- init_getWindowScrollBarX();
3162
- init_getDocumentElement();
3163
- init_isScrollParent();
3164
- init_math();
3165
- })))();
3166
- }
3167
- //#endregion
3168
- //#region ../../node_modules/@popperjs/core/lib/utils/orderModifiers.js
3169
- function order(modifiers) {
3170
- var map = /* @__PURE__ */ new Map();
3171
- var visited = /* @__PURE__ */ new Set();
3172
- var result = [];
3173
- modifiers.forEach(function(modifier) {
3174
- map.set(modifier.name, modifier);
3175
- });
3176
- function sort(modifier) {
3177
- visited.add(modifier.name);
3178
- [].concat(modifier.requires || [], modifier.requiresIfExists || []).forEach(function(dep) {
3179
- if (!visited.has(dep)) {
3180
- var depModifier = map.get(dep);
3181
- if (depModifier) sort(depModifier);
3182
- }
3183
- });
3184
- result.push(modifier);
3185
- }
3186
- modifiers.forEach(function(modifier) {
3187
- if (!visited.has(modifier.name)) sort(modifier);
3188
- });
3189
- return result;
3190
- }
3191
- function orderModifiers(modifiers) {
3192
- var orderedModifiers = order(modifiers);
3193
- return modifierPhases.reduce(function(acc, phase) {
3194
- return acc.concat(orderedModifiers.filter(function(modifier) {
3195
- return modifier.phase === phase;
3196
- }));
3197
- }, []);
3198
- }
3199
- function init_orderModifiers() {
3200
- return (init_orderModifiers = __esmMin((() => {
3201
- init_enums();
3202
- })))();
3203
- }
3204
- //#endregion
3205
- //#region ../../node_modules/@popperjs/core/lib/utils/debounce.js
3206
- function debounce(fn) {
3207
- var pending;
3208
- return function() {
3209
- if (!pending) pending = new Promise(function(resolve) {
3210
- Promise.resolve().then(function() {
3211
- pending = void 0;
3212
- resolve(fn());
3213
- });
3214
- });
3215
- return pending;
3216
- };
3217
- }
3218
- //#endregion
3219
- //#region ../../node_modules/@popperjs/core/lib/utils/mergeByName.js
3220
- function mergeByName(modifiers) {
3221
- var merged = modifiers.reduce(function(merged, current) {
3222
- var existing = merged[current.name];
3223
- merged[current.name] = existing ? Object.assign({}, existing, current, {
3224
- options: Object.assign({}, existing.options, current.options),
3225
- data: Object.assign({}, existing.data, current.data)
3226
- }) : current;
3227
- return merged;
3228
- }, {});
3229
- return Object.keys(merged).map(function(key) {
3230
- return merged[key];
3231
- });
3232
- }
3233
- //#endregion
3234
- //#region ../../node_modules/@popperjs/core/lib/createPopper.js
3235
- function areValidElements() {
3236
- for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) args[_key] = arguments[_key];
3237
- return !args.some(function(element) {
3238
- return !(element && typeof element.getBoundingClientRect === "function");
3239
- });
3240
- }
3241
- function popperGenerator(generatorOptions) {
3242
- if (generatorOptions === void 0) generatorOptions = {};
3243
- var _generatorOptions = generatorOptions, _generatorOptions$def = _generatorOptions.defaultModifiers, defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def, _generatorOptions$def2 = _generatorOptions.defaultOptions, defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;
3244
- return function createPopper(reference, popper, options) {
3245
- if (options === void 0) options = defaultOptions;
3246
- var state = {
3247
- placement: "bottom",
3248
- orderedModifiers: [],
3249
- options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),
3250
- modifiersData: {},
3251
- elements: {
3252
- reference,
3253
- popper
3254
- },
3255
- attributes: {},
3256
- styles: {}
3257
- };
3258
- var effectCleanupFns = [];
3259
- var isDestroyed = false;
3260
- var instance = {
3261
- state,
3262
- setOptions: function setOptions(setOptionsAction) {
3263
- var options = typeof setOptionsAction === "function" ? setOptionsAction(state.options) : setOptionsAction;
3264
- cleanupModifierEffects();
3265
- state.options = Object.assign({}, defaultOptions, state.options, options);
3266
- state.scrollParents = {
3267
- reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],
3268
- popper: listScrollParents(popper)
3269
- };
3270
- var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers)));
3271
- state.orderedModifiers = orderedModifiers.filter(function(m) {
3272
- return m.enabled;
3273
- });
3274
- runModifierEffects();
3275
- return instance.update();
3276
- },
3277
- forceUpdate: function forceUpdate() {
3278
- if (isDestroyed) return;
3279
- var _state$elements = state.elements, reference = _state$elements.reference, popper = _state$elements.popper;
3280
- if (!areValidElements(reference, popper)) return;
3281
- state.rects = {
3282
- reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === "fixed"),
3283
- popper: getLayoutRect(popper)
3284
- };
3285
- state.reset = false;
3286
- state.placement = state.options.placement;
3287
- state.orderedModifiers.forEach(function(modifier) {
3288
- return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);
3289
- });
3290
- for (var index = 0; index < state.orderedModifiers.length; index++) {
3291
- if (state.reset === true) {
3292
- state.reset = false;
3293
- index = -1;
3294
- continue;
3295
- }
3296
- var _state$orderedModifie = state.orderedModifiers[index], fn = _state$orderedModifie.fn, _state$orderedModifie2 = _state$orderedModifie.options, _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2, name = _state$orderedModifie.name;
3297
- if (typeof fn === "function") state = fn({
3298
- state,
3299
- options: _options,
3300
- name,
3301
- instance
3302
- }) || state;
3303
- }
3304
- },
3305
- update: debounce(function() {
3306
- return new Promise(function(resolve) {
3307
- instance.forceUpdate();
3308
- resolve(state);
3309
- });
3310
- }),
3311
- destroy: function destroy() {
3312
- cleanupModifierEffects();
3313
- isDestroyed = true;
3314
- }
3315
- };
3316
- if (!areValidElements(reference, popper)) return instance;
3317
- instance.setOptions(options).then(function(state) {
3318
- if (!isDestroyed && options.onFirstUpdate) options.onFirstUpdate(state);
3319
- });
3320
- function runModifierEffects() {
3321
- state.orderedModifiers.forEach(function(_ref) {
3322
- var name = _ref.name, _ref$options = _ref.options, options = _ref$options === void 0 ? {} : _ref$options, effect = _ref.effect;
3323
- if (typeof effect === "function") {
3324
- var cleanupFn = effect({
3325
- state,
3326
- name,
3327
- instance,
3328
- options
3329
- });
3330
- effectCleanupFns.push(cleanupFn || function noopFn() {});
3331
- }
3332
- });
3333
- }
3334
- function cleanupModifierEffects() {
3335
- effectCleanupFns.forEach(function(fn) {
3336
- return fn();
3337
- });
3338
- effectCleanupFns = [];
3339
- }
3340
- return instance;
3341
- };
3342
- }
3343
- var DEFAULT_OPTIONS;
3344
- function init_createPopper() {
3345
- return (init_createPopper = __esmMin((() => {
3346
- init_getCompositeRect();
3347
- init_getLayoutRect();
3348
- init_listScrollParents();
3349
- init_getOffsetParent();
3350
- init_orderModifiers();
3351
- init_instanceOf();
3352
- DEFAULT_OPTIONS = {
3353
- placement: "bottom",
3354
- modifiers: [],
3355
- strategy: "absolute"
3356
- };
3357
- })))();
3358
- }
3359
- //#endregion
3360
- //#region ../../node_modules/@popperjs/core/lib/popper.js
3361
- var defaultModifiers, createPopper;
3362
- function init_popper() {
3363
- return (init_popper = __esmMin((() => {
3364
- init_createPopper();
3365
- init_eventListeners();
3366
- init_popperOffsets();
3367
- init_computeStyles();
3368
- init_applyStyles();
3369
- init_offset();
3370
- init_flip();
3371
- init_preventOverflow();
3372
- init_arrow();
3373
- init_hide();
3374
- defaultModifiers = [
3375
- eventListeners_default,
3376
- popperOffsets_default,
3377
- computeStyles_default,
3378
- applyStyles_default,
3379
- offset_default,
3380
- flip_default,
3381
- preventOverflow_default,
3382
- arrow_default,
3383
- hide_default
3384
- ];
3385
- createPopper = /*#__PURE__*/ popperGenerator({ defaultModifiers });
3386
- })))();
3387
- }
3388
- //#endregion
3389
- export { getParentNode$1 as A, getAxisLength as C, init_floating_ui_utils as D, getSideAxis as E, isLastTraversableNode as F, isNode as I, isOverflowElement as L, init_floating_ui_utils_dom as M, isElement$1 as N, getComputedStyle$2 as O, isHTMLElement$1 as P, isShadowRoot$1 as R, getAlignmentAxis as S, getSide as T, n as _, limitShift as a, evaluate as b, size as c, init_floating_ui_dom as d, f, l as g, j as h, init_floating_ui_react_dom as i, getWindow$1 as j, getNodeName$1 as k, useFloating as l, init_signals_core_module as m, init_popper as n, offset$2 as o, g as p, flip$2 as r, shift as s, createPopper as t, autoUpdate as u, y as v, getPaddingObject as w, getAlignment as x, clamp as y };