@aussieljk/forkbook 0.0.1-5 → 0.0.1-7

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 (314) hide show
  1. package/dist/_browser-chunks/{Color-GTF4GM7L.js → Color-2YRIFQLC.js} +1 -1
  2. package/dist/_browser-chunks/WithTooltip-4R5JMWZ7.js +196 -0
  3. package/dist/_browser-chunks/{chunk-MJY6ITYT.js → chunk-4EFKUJG2.js} +10 -10
  4. package/dist/_browser-chunks/chunk-6AKCRYVX.js +6 -0
  5. package/dist/_browser-chunks/{chunk-FVSEPWWX.js → chunk-DAUHYZUB.js} +550 -1621
  6. package/dist/_browser-chunks/chunk-E47B5255.js +1149 -0
  7. package/dist/_browser-chunks/{chunk-K6GRZSXS.js → chunk-EQKMUQF3.js} +4 -3
  8. package/dist/_browser-chunks/{chunk-GU3X2J4S.js → chunk-FRAOQJDI.js} +3 -1
  9. package/dist/_browser-chunks/{chunk-2SCZVUKW.js → chunk-H4ZHAXN3.js} +1 -1
  10. package/dist/_browser-chunks/{chunk-HOSBMS2F.js → chunk-HTL5ODCB.js} +1 -1
  11. package/dist/_browser-chunks/{chunk-ZLWA5RIE.js → chunk-I4ATZPNZ.js} +1 -1
  12. package/dist/_browser-chunks/{chunk-6SHRDXGF.js → chunk-IJYLSHY7.js} +173 -87
  13. package/dist/_browser-chunks/{chunk-SZCSXISG.js → chunk-NA4ITZTK.js} +7 -5
  14. package/dist/_browser-chunks/chunk-NGMQJMCY.js +53 -0
  15. package/dist/_browser-chunks/{chunk-K2B36HKM.js → chunk-O24AZJZ7.js} +1 -1
  16. package/dist/_browser-chunks/{chunk-NMRSYACM.js → chunk-SFMQDIN2.js} +4 -3
  17. package/dist/_browser-chunks/{chunk-ZTQ5MEJ5.js → chunk-UMGDO2ZM.js} +3 -37
  18. package/dist/_browser-chunks/chunk-WVF42CP2.js +6027 -0
  19. package/dist/_browser-chunks/{chunk-52CW7FF7.js → chunk-YYWKZ7O3.js} +3 -1
  20. package/dist/_node-chunks/{attached-runtime-IOE3BXIY.js → attached-runtime-WFZCCGUB.js} +29 -29
  21. package/dist/_node-chunks/{builder-manager-GDFEGD72.js → builder-manager-DHKHRZK4.js} +155 -148
  22. package/dist/_node-chunks/{chunk-M2QB5ALN.js → chunk-3ZCGT6VF.js} +6 -6
  23. package/dist/_node-chunks/{chunk-SUJXQU74.js → chunk-4HGC3G6B.js} +46 -15
  24. package/dist/_node-chunks/{chunk-WMQ2VCTF.js → chunk-5PYQ573S.js} +7 -7
  25. package/dist/_node-chunks/{chunk-TYCDPVIH.js → chunk-64JPAW3T.js} +6 -6
  26. package/dist/_node-chunks/chunk-6CB3XSQ2.js +495 -0
  27. package/dist/_node-chunks/{chunk-MHDKWHOA.js → chunk-6K3ZE4HN.js} +6 -6
  28. package/dist/_node-chunks/{chunk-3DCJB2D4.js → chunk-6QZ3PX5R.js} +6 -6
  29. package/dist/_node-chunks/{chunk-6DOJKR3V.js → chunk-7HVDL6M3.js} +29843 -51588
  30. package/dist/_node-chunks/chunk-7PMQPS5E.js +347 -0
  31. package/dist/_node-chunks/{chunk-L5CY6HKG.js → chunk-7V5AOV2J.js} +7 -7
  32. package/dist/_node-chunks/{chunk-AXJJB2K6.js → chunk-7VHCAGBJ.js} +8 -8
  33. package/dist/_node-chunks/{chunk-3DX6THMV.js → chunk-ATX7SHS7.js} +8 -8
  34. package/dist/_node-chunks/{chunk-SDXU22OH.js → chunk-BQC6WCUS.js} +6 -6
  35. package/dist/_node-chunks/{chunk-D6B2DRQZ.js → chunk-BR4WDRY6.js} +8 -8
  36. package/dist/_node-chunks/{chunk-SJZQ44OR.js → chunk-BRHJ4P3A.js} +6 -6
  37. package/dist/_node-chunks/{chunk-N4FLP7AO.js → chunk-CBBFNVFZ.js} +7 -7
  38. package/dist/_node-chunks/{chunk-PHXCOTMO.js → chunk-CDFQORVD.js} +34 -949
  39. package/dist/_node-chunks/{chunk-SR3BCYEH.js → chunk-CENNLCU7.js} +6 -6
  40. package/dist/_node-chunks/{chunk-OTFIQXHR.js → chunk-CNMMDQC3.js} +27 -50
  41. package/dist/_node-chunks/{chunk-E4C2H45J.js → chunk-DMDZPUHM.js} +6 -6
  42. package/dist/_node-chunks/{chunk-45LRLOYO.js → chunk-DT45EUDD.js} +60 -134
  43. package/dist/_node-chunks/{chunk-KQFHT7SW.js → chunk-EAL4RVEF.js} +6 -6
  44. package/dist/_node-chunks/chunk-EFFWFE6W.js +11 -0
  45. package/dist/_node-chunks/{chunk-MDGNN3FJ.js → chunk-ESCZ2NSB.js} +6 -6
  46. package/dist/_node-chunks/{chunk-T2I453AJ.js → chunk-ESZIQTUH.js} +7 -7
  47. package/dist/_node-chunks/{chunk-HWY2CAUH.js → chunk-F3SAYS4R.js} +6 -6
  48. package/dist/_node-chunks/{chunk-LSP54OYM.js → chunk-FTUQ7T3V.js} +25 -8
  49. package/dist/_node-chunks/{chunk-AAAUVDWT.js → chunk-FVFSSIGA.js} +10 -10
  50. package/dist/_node-chunks/{chunk-GS4VNNSS.js → chunk-G2AANC4A.js} +6 -6
  51. package/dist/_node-chunks/{chunk-SAAQFJL4.js → chunk-HUMAXGH2.js} +6 -6
  52. package/dist/_node-chunks/{chunk-A4XRNDN4.js → chunk-I535GEPH.js} +7 -7
  53. package/dist/_node-chunks/{chunk-CK4EHW3K.js → chunk-J3Q56GX3.js} +25 -25
  54. package/dist/_node-chunks/{chunk-U47PBQZ3.js → chunk-JDKYP7FW.js} +10 -10
  55. package/dist/_node-chunks/{chunk-7TUSIVWS.js → chunk-JED5F3H2.js} +6 -6
  56. package/dist/_node-chunks/{chunk-UM5G27IC.js → chunk-JMS4H7QB.js} +7 -7
  57. package/dist/_node-chunks/{chunk-GR65OLAH.js → chunk-JOSJ64KD.js} +7 -7
  58. package/dist/_node-chunks/{chunk-XUHEL63G.js → chunk-JPHSU5OI.js} +6 -6
  59. package/dist/_node-chunks/{chunk-NYWD5LYM.js → chunk-JQICISDD.js} +6 -6
  60. package/dist/_node-chunks/{chunk-I3DKGHVD.js → chunk-JTLOSDYL.js} +9 -9
  61. package/dist/_node-chunks/{chunk-5KAJVK4E.js → chunk-K5RUOW42.js} +7 -7
  62. package/dist/_node-chunks/{chunk-UKEJISQU.js → chunk-KHWCZDIW.js} +650 -9
  63. package/dist/_node-chunks/chunk-KWER36VB.js +20 -0
  64. package/dist/_node-chunks/{chunk-YTBTCM22.js → chunk-LJTP5PAJ.js} +6 -6
  65. package/dist/_node-chunks/chunk-LZYYZ62Y.js +19 -0
  66. package/dist/_node-chunks/{chunk-CGXW2HFE.js → chunk-M7ZVSBNU.js} +6 -6
  67. package/dist/_node-chunks/{chunk-BTFSFATC.js → chunk-MBIIJTGQ.js} +11 -10
  68. package/dist/_node-chunks/{chunk-VBSVLIXU.js → chunk-MF3AT3JQ.js} +6 -6
  69. package/dist/_node-chunks/{chunk-AX2ALHBK.js → chunk-MF5BYASO.js} +9 -6
  70. package/dist/_node-chunks/{chunk-JJNO3SFI.js → chunk-MJFMB4WD.js} +9 -9
  71. package/dist/_node-chunks/{chunk-E4TBS4MV.js → chunk-MRWBN46D.js} +8 -8
  72. package/dist/_node-chunks/{chunk-QQXFB4YA.js → chunk-MZQXEAI6.js} +9 -9
  73. package/dist/_node-chunks/{chunk-TZ2TZW2K.js → chunk-NLPC2DDQ.js} +6 -6
  74. package/dist/_node-chunks/{chunk-HCX5R46Q.js → chunk-NQAFLS5U.js} +8 -8
  75. package/dist/_node-chunks/{chunk-5LE7GXEC.js → chunk-NSZGBFPR.js} +6 -6
  76. package/dist/_node-chunks/{chunk-WHDCECIV.js → chunk-NUYBFTOU.js} +7 -7
  77. package/dist/_node-chunks/{chunk-RCPKLP3X.js → chunk-O7VJA7SM.js} +7 -7
  78. package/dist/_node-chunks/{chunk-2GY2FKLH.js → chunk-OGJ7LDX3.js} +7 -7
  79. package/dist/_node-chunks/{chunk-F4Q7OCCN.js → chunk-OWT6AVWK.js} +8 -8
  80. package/dist/_node-chunks/{chunk-LCXIUTOU.js → chunk-P3GOMPP3.js} +7 -7
  81. package/dist/_node-chunks/{chunk-KCAPE7OJ.js → chunk-PQLXHVWK.js} +6 -6
  82. package/dist/_node-chunks/{chunk-V45RRBTK.js → chunk-Q6QRFKHB.js} +8 -8
  83. package/dist/_node-chunks/{chunk-VJSOHPVD.js → chunk-QSP42ZBM.js} +6 -6
  84. package/dist/_node-chunks/{chunk-7XUQM6SR.js → chunk-QWDR5OWQ.js} +14 -14
  85. package/dist/_node-chunks/{chunk-YLKS7U3M.js → chunk-QWRQXG2V.js} +8 -8
  86. package/dist/_node-chunks/{chunk-4WO3GNZQ.js → chunk-R6AKCXPH.js} +6 -6
  87. package/dist/_node-chunks/{chunk-AXQ6LLSE.js → chunk-RCY7TLET.js} +8 -8
  88. package/dist/_node-chunks/chunk-RKKMQA6N.js +620 -0
  89. package/dist/_node-chunks/{chunk-BV3QRFE6.js → chunk-RZ7UEP4N.js} +6 -6
  90. package/dist/_node-chunks/{chunk-OSJFTZ5N.js → chunk-S3HB4EWT.js} +6 -6
  91. package/dist/_node-chunks/{chunk-QZVFIEOM.js → chunk-SHH7JROR.js} +6 -6
  92. package/dist/_node-chunks/{chunk-Q33BYVLY.js → chunk-SWHTDOB4.js} +7 -7
  93. package/dist/_node-chunks/{chunk-ZPPVG262.js → chunk-SZYMLCHF.js} +6 -6
  94. package/dist/_node-chunks/{chunk-ES5QZBSB.js → chunk-TOGDRW2W.js} +6 -6
  95. package/dist/_node-chunks/{chunk-J64XMUPF.js → chunk-U3E7E4Q2.js} +10 -10
  96. package/dist/_node-chunks/{chunk-RECGEABN.js → chunk-U6DHF3RM.js} +7 -7
  97. package/dist/_node-chunks/{chunk-OB2XHL53.js → chunk-UAG3XK32.js} +31 -30
  98. package/dist/_node-chunks/{chunk-BBD2KUV4.js → chunk-UF6Q6L5C.js} +22 -20
  99. package/dist/_node-chunks/chunk-UGXN7JTT.js +18 -0
  100. package/dist/_node-chunks/{chunk-EWAGCBER.js → chunk-UNCBLHIP.js} +8 -8
  101. package/dist/_node-chunks/chunk-UPJMGWMZ.js +25 -0
  102. package/dist/_node-chunks/chunk-UVV24PG4.js +69 -0
  103. package/dist/_node-chunks/{chunk-E6KXSYWR.js → chunk-WBB4NQ6H.js} +6 -6
  104. package/dist/_node-chunks/{chunk-B2IOB2V3.js → chunk-WHOF2BJB.js} +7 -7
  105. package/dist/_node-chunks/{chunk-FA36CEN4.js → chunk-WME5NEJA.js} +6 -6
  106. package/dist/_node-chunks/{chunk-BFZG4UTW.js → chunk-X63YMAHP.js} +7 -7
  107. package/dist/_node-chunks/chunk-Y2GHAOKI.js +25 -0
  108. package/dist/_node-chunks/{chunk-AXG3EMKS.js → chunk-Y6G64J5S.js} +7 -15
  109. package/dist/_node-chunks/chunk-YVIPYJ53.js +2609 -0
  110. package/dist/_node-chunks/{chunk-NDGTNFUN.js → chunk-YZWUD7I5.js} +16 -13
  111. package/dist/_node-chunks/{chunk-VN3A5CEH.js → chunk-ZIDIYSJQ.js} +7 -7
  112. package/dist/_node-chunks/chunk-ZSGOW4WQ.js +20 -0
  113. package/dist/_node-chunks/dist-5EG56KTF.js +16 -0
  114. package/dist/_node-chunks/dist-UEXSNGGQ.js +27 -0
  115. package/dist/_node-chunks/{local-runtime-RW6AAWSX.js → local-runtime-UN5QK2SE.js} +20 -20
  116. package/dist/_node-chunks/{mdx-plugin-BKWCT6CB.js → mdx-plugin-6M6CMNL3.js} +2263 -130
  117. package/dist/_node-chunks/{monorepo-ZFJ6HM34.js → monorepo-253VKW4B.js} +11 -11
  118. package/dist/_node-chunks/{monorepo-optimized-tests-relaxed-limits-no-story-deletion-C3EW4VJW.js → monorepo-optimized-tests-relaxed-limits-no-story-deletion-3ZOE54OQ.js} +11 -11
  119. package/dist/_node-chunks/optimized-tests-JSWLRMEI.js +22 -0
  120. package/dist/_node-chunks/{pattern-copy-play-2ZMJNCBS.js → pattern-copy-play-CCCJRMSL.js} +9 -9
  121. package/dist/_node-chunks/postinstallAddon-VMANBHPR.js +20 -0
  122. package/dist/_node-chunks/{rehype-external-links-RT5Z62RV.js → rehype-external-links-LJTPLCGD.js} +9 -9
  123. package/dist/_node-chunks/{rehype-slug-H5TWHJ6G.js → rehype-slug-KQI7ULEZ.js} +9 -9
  124. package/dist/_node-chunks/{relaxed-limits-DYLWZGE4.js → relaxed-limits-MUE2NI7S.js} +11 -11
  125. package/dist/_node-chunks/{run-65LLGSVR.js → run-PGZMPNMS.js} +246 -13
  126. package/dist/_node-chunks/{run-BQQLK454.js → run-SYLR25HA.js} +17 -17
  127. package/dist/_node-chunks/session-id-J4A25UQ6.js +23 -0
  128. package/dist/_node-chunks/{setup-NEO7XX66.js → setup-XZWSUYPG.js} +8 -8
  129. package/dist/_node-chunks/{vitest.config.4.template-6P3FZQTY.js → vitest.config.4.template-T25YYRGV.js} +7 -7
  130. package/dist/actions/decorator.js +2 -1
  131. package/dist/actions/index.js +2 -1
  132. package/dist/addon-a11y/index.js +2 -1
  133. package/dist/addon-a11y/manager.js +6 -5
  134. package/dist/addon-a11y/preset.js +7 -7
  135. package/dist/addon-a11y/preview.js +2 -1
  136. package/dist/addon-docs/blocks.js +28 -14
  137. package/dist/addon-docs/manager.js +2 -2
  138. package/dist/addon-docs/preset.js +10 -10
  139. package/dist/addon-links/index.js +3 -2
  140. package/dist/addon-links/preview.d.ts +1 -1
  141. package/dist/addon-links/preview.js +3 -2
  142. package/dist/addon-links/react/index.js +2 -1
  143. package/dist/addon-mcp/preset.js +8 -8
  144. package/dist/addon-mcp/tools/preview-stories/preview-stories-app-script.js +21 -44
  145. package/dist/addon-ondevice-actions/index.js +5 -1
  146. package/dist/addon-ondevice-actions/register.js +5 -1
  147. package/dist/addon-themes/postinstall.js +7 -7
  148. package/dist/addon-vitest/constants.js +8 -8
  149. package/dist/addon-vitest/manager.js +2 -2
  150. package/dist/addon-vitest/node/coverage-reporter.js +8 -8
  151. package/dist/addon-vitest/node/vitest.js +16 -16
  152. package/dist/addon-vitest/postinstall.js +10 -10
  153. package/dist/addon-vitest/preset.js +15 -16
  154. package/dist/addon-vitest/vitest-plugin/global-setup.js +7 -7
  155. package/dist/addon-vitest/vitest-plugin/index.js +17 -17
  156. package/dist/babel/index.d.ts +91 -842
  157. package/dist/babel/index.js +13 -19
  158. package/dist/bin/core.js +61 -60
  159. package/dist/bin/dispatcher.js +16 -11
  160. package/dist/bin/loader.js +16 -15
  161. package/dist/builder-vite/index.js +15 -15
  162. package/dist/builder-vite/preset.js +13 -13
  163. package/dist/{chunk-Jf7j2Ot0.d.ts → chunk-BGhyFTJO.d.ts} +1 -1
  164. package/dist/{chunk-Ce6uhJuR.d.ts → chunk-B_ZhEPlo.d.ts} +1 -1
  165. package/dist/{chunk-CZHsX9Zo.d.ts → chunk-CMaYrou5.d.ts} +1 -1
  166. package/dist/chunk-CV4-Z2pn.d.ts +30 -0
  167. package/dist/{chunk-B2t1tGRh.d.ts → chunk-CYuvV2sR.d.ts} +11 -13
  168. package/dist/{chunk-DpljNJTz.d.ts → chunk-LrH1y9J2.d.ts} +39 -0
  169. package/dist/cli/index.d.ts +13 -866
  170. package/dist/cli/index.js +42 -4952
  171. package/dist/cli/tools/sdk/child-host.d.ts +1 -1
  172. package/dist/cli/tools/sdk/child-host.js +17 -17
  173. package/dist/cli/tools/sdk/index.d.ts +1 -1
  174. package/dist/cli/tools/sdk/index.js +18 -18
  175. package/dist/cli-commands/bin/index.js +7 -7
  176. package/dist/client-logger/index.js +3 -1
  177. package/dist/common/index.d.ts +5 -4
  178. package/dist/common/index.js +35 -37
  179. package/dist/components/index.d.ts +14 -231
  180. package/dist/components/index.js +2512 -8359
  181. package/dist/core-events/index.d.ts +3 -2
  182. package/dist/core-events/index.js +3 -1
  183. package/dist/core-server/index.d.ts +2 -2
  184. package/dist/core-server/index.js +450 -147
  185. package/dist/core-server/presets/common-manager.js +62 -866
  186. package/dist/core-server/presets/common-override-preset.js +12 -10
  187. package/dist/core-server/presets/common-preset.js +39 -40
  188. package/dist/create/bin/index.js +7 -7
  189. package/dist/create/index.js +15 -15
  190. package/dist/csf/index.d.ts +1 -1
  191. package/dist/csf/index.js +27 -93
  192. package/dist/csf-tools/index.d.ts +14 -12
  193. package/dist/csf-tools/index.js +14 -14
  194. package/dist/instrumenter/index.js +3 -1
  195. package/dist/manager/_manager-chunks/{globals-runtime-BgVwdR45.js → globals-runtime-4fCHtNC6.js} +1 -1
  196. package/dist/manager/_manager-chunks/{globals-runtime-DW1HVuLt.js → globals-runtime-BKPOYSwp.js} +410 -379
  197. package/dist/manager/_manager-chunks/{globals-runtime-zVfMhZAt.js → globals-runtime-BMIT8BJb.js} +1 -1
  198. package/dist/manager/_manager-chunks/{globals-runtime-CUBVmgcG.js → globals-runtime-BO0pfoqL.js} +4 -4
  199. package/dist/manager/_manager-chunks/{globals-runtime-Bke4A4DG.js → globals-runtime-BZKYJxYC.js} +1 -1
  200. package/dist/manager/_manager-chunks/{globals-runtime-D_YKR9nf.js → globals-runtime-Bpc_ftuT.js} +1252 -539
  201. package/dist/manager/_manager-chunks/{globals-runtime-DCOX9nD5.js → globals-runtime-CBviMKtt.js} +1 -17
  202. package/dist/manager/_manager-chunks/{globals-runtime-CTB3rhS1.js → globals-runtime-CI-C7ncS.js} +10 -10
  203. package/dist/manager/_manager-chunks/{globals-runtime-Cr3nYYcT.js → globals-runtime-CI_p54Ha.js} +59 -60
  204. package/dist/manager/_manager-chunks/{globals-runtime-CiLcg4q9.js → globals-runtime-CTyYXvUm.js} +1 -1
  205. package/dist/manager/_manager-chunks/{globals-runtime-DqNrRmOM.js → globals-runtime-CoCzM1V_.js} +93 -2146
  206. package/dist/manager/_manager-chunks/{globals-runtime-CXKb33hg.js → globals-runtime-CzEhVGVp.js} +141 -54
  207. package/dist/manager/_manager-chunks/{globals-runtime-CF4o9_wT.js → globals-runtime-D82vqOGq.js} +2 -1
  208. package/dist/manager/_manager-chunks/{globals-runtime-ALpzCL93.js → globals-runtime-DB8fVA5g.js} +2 -145
  209. package/dist/manager/_manager-chunks/{globals-runtime-DMvB3-IM.js → globals-runtime-DMq1Phbl.js} +153 -141
  210. package/dist/manager/_manager-chunks/globals-runtime-DOPUchia.js +5282 -0
  211. package/dist/manager/_manager-chunks/{globals-runtime-BcNHymiF.js → globals-runtime-Dbt08xWQ.js} +1 -1
  212. package/dist/manager/_manager-chunks/{globals-runtime-m07udJ_K.js → globals-runtime-kmPSyf3j.js} +637 -1730
  213. package/dist/manager/_manager-chunks/{runtime-DMig8mT7.js → runtime-5o_11Jae.js} +4 -3
  214. package/dist/manager/_manager-chunks/{runtime-DrjpEyLM.js → runtime-B4U0u9p4.js} +5 -147
  215. package/dist/manager/_manager-chunks/{runtime-B-eSQdxk.js → runtime-BM30BmeT.js} +503 -44
  216. package/dist/manager/_manager-chunks/{runtime-EITvVbkG.js → runtime-BdGkqNEt.js} +1 -2
  217. package/dist/manager/_manager-chunks/{runtime-a5zd7km2.js → runtime-Cf0p9DUx.js} +5 -531
  218. package/dist/manager/_manager-chunks/{runtime-Cdz2BHhM.js → runtime-D-nYLsdk.js} +57 -34
  219. package/dist/manager/_manager-chunks/runtime-D09XMY6V.js +294 -0
  220. package/dist/manager/_manager-chunks/{runtime-Bldwclun.js → runtime-DvrwKw7z.js} +92 -303
  221. package/dist/manager/_manager-chunks/{runtime-DGHNKNQl.js → runtime-DzxaTqVN.js} +10 -29
  222. package/dist/manager/_manager-chunks/runtime-P663lpsR.js +528 -0
  223. package/dist/manager/_manager-chunks/{runtime-Cmu7D8A0.js → runtime-ecY5qnmo.js} +193 -184
  224. package/dist/manager/globals-runtime.js +1 -1
  225. package/dist/manager/runtime.js +1 -1
  226. package/dist/manager-api/index.d.ts +1 -1
  227. package/dist/manager-api/index.js +22 -28
  228. package/dist/manager-errors.d.ts +1 -1
  229. package/dist/mcp/index.js +8 -8
  230. package/dist/mocking-utils/index.js +16 -11
  231. package/dist/nextjs-vite/index.js +3 -2
  232. package/dist/nextjs-vite/node/index.js +7 -7
  233. package/dist/nextjs-vite/node-stand-ins/index.d.ts +68 -0
  234. package/dist/nextjs-vite/node-stand-ins/index.js +145 -0
  235. package/dist/nextjs-vite/preset.js +93 -14
  236. package/dist/nextjs-vite/vite-plugin/index.js +7 -7
  237. package/dist/nextjs-vite-plugin/index.d.ts +1 -2
  238. package/dist/nextjs-vite-plugin/index.js +12 -27
  239. package/dist/nextjs-vite-plugin/mocks/storybook.global.js +8 -8
  240. package/dist/node-logger/index.d.ts +65 -72
  241. package/dist/node-logger/index.js +11 -12
  242. package/dist/oxc-parser/index.js +11 -13
  243. package/dist/oxc-parser/worker.js +10 -10
  244. package/dist/preview/_chunks/{runtime-DVM_AHbR.js → runtime-6P-h06Te.js} +51 -50
  245. package/dist/preview/_chunks/{runtime-BoxmlDdB.js → runtime-B9KKIDGa.js} +202 -81
  246. package/dist/preview/_chunks/{runtime-BIzIdDbb.js → runtime-BPwAnlRx.js} +482 -334
  247. package/dist/preview/_chunks/{runtime-q3wt0e_N.js → runtime-BUnOhg9h.js} +2 -2
  248. package/dist/preview/_chunks/runtime-Bcv1hJky.js +6305 -0
  249. package/dist/preview/_chunks/{runtime-CqHxptiK.js → runtime-C1jgT6tJ.js} +93 -2145
  250. package/dist/preview/_chunks/{runtime-D7B4bVe_.js → runtime-C8QFpkFV.js} +6 -6
  251. package/dist/preview/_chunks/{runtime-CijtAN7R.js → runtime-DdqR8Fd0.js} +15 -6
  252. package/dist/preview/_chunks/{runtime-B3y8ocOg.js → runtime-DvBfMhis.js} +2 -2
  253. package/dist/preview/_chunks/{runtime-BZSnICCg.js → runtime-WapFVPAh.js} +29 -29
  254. package/dist/preview/runtime.js +1 -1
  255. package/dist/preview-api/index.d.ts +1 -1
  256. package/dist/preview-api/index.js +2 -1
  257. package/dist/preview-errors.d.ts +1 -1
  258. package/dist/react/docgen/docgen-worker.js +11 -12
  259. package/dist/react/entry-preview.js +2 -1
  260. package/dist/react/index.js +6 -4
  261. package/dist/react/preset.js +13 -14
  262. package/dist/react/preview.js +3 -2
  263. package/dist/react-native/bin/get-stories.js +8 -8
  264. package/dist/react-native/index.js +25 -211
  265. package/dist/react-native/metro/node.js +10 -9
  266. package/dist/react-native/metro/withStorybook.js +11 -10
  267. package/dist/react-native/scripts/generate.js +8 -8
  268. package/dist/react-vite/node/index.js +7 -7
  269. package/dist/react-vite/preset.js +7 -7
  270. package/dist/router/index.js +3 -1
  271. package/dist/server-errors.d.ts +1 -1
  272. package/dist/server-errors.js +9 -9
  273. package/dist/shared/open-service/index.d.ts +1 -1
  274. package/dist/shared/open-service/services/docgen/worker/docgen-worker.js +9 -9
  275. package/dist/telemetry/index.js +43 -45
  276. package/dist/test/index.js +808 -573
  277. package/dist/theming/create.js +2 -1
  278. package/dist/theming/index.js +22 -1
  279. package/dist/types/index.d.ts +1 -1
  280. package/package.json +21 -44
  281. package/dist/_browser-chunks/WithTooltip-V55S6YCY.js +0 -1619
  282. package/dist/_browser-chunks/chunk-5P4QA6MY.js +0 -20
  283. package/dist/_browser-chunks/chunk-UDQ3XQFC.js +0 -108
  284. package/dist/_node-chunks/chunk-6QQTZT3Z.js +0 -19
  285. package/dist/_node-chunks/chunk-BRD332PB.js +0 -3008
  286. package/dist/_node-chunks/chunk-E2XKJLXK.js +0 -4731
  287. package/dist/_node-chunks/chunk-F2LQJXAB.js +0 -29
  288. package/dist/_node-chunks/chunk-MCZZMBPA.js +0 -20
  289. package/dist/_node-chunks/chunk-MMFUHYSU.js +0 -23
  290. package/dist/_node-chunks/chunk-UGFY5LEG.js +0 -18
  291. package/dist/_node-chunks/chunk-UO5ZOCSQ.js +0 -662
  292. package/dist/_node-chunks/chunk-UW35FCXF.js +0 -20
  293. package/dist/_node-chunks/chunk-VMUXW2E2.js +0 -5414
  294. package/dist/_node-chunks/chunk-VNXE7UJL.js +0 -51
  295. package/dist/_node-chunks/chunk-VRJJ43P2.js +0 -11
  296. package/dist/_node-chunks/chunk-WCJUS7OC.js +0 -1877
  297. package/dist/_node-chunks/chunk-WMBMSNB7.js +0 -36
  298. package/dist/_node-chunks/chunk-YV2QBXU6.js +0 -3823
  299. package/dist/_node-chunks/chunk-ZZNBVMBU.js +0 -25
  300. package/dist/_node-chunks/dist-VFUGPNLK.js +0 -16
  301. package/dist/_node-chunks/globby-N7LO32D3.js +0 -2884
  302. package/dist/_node-chunks/jiti-SJDZ7LQB.js +0 -3848
  303. package/dist/_node-chunks/lib-4HD6QL5R.js +0 -366
  304. package/dist/_node-chunks/optimized-tests-LVKXZ3HQ.js +0 -22
  305. package/dist/_node-chunks/postinstallAddon-I6MAL6PW.js +0 -20
  306. package/dist/_node-chunks/session-id-6Z2RXBTG.js +0 -23
  307. package/dist/chunk-BfBzpgct.d.ts +0 -916
  308. package/dist/core-server/presets/common-manager.css +0 -170
  309. package/dist/manager/_manager-chunks/globals-runtime-Bon7UvQk.js +0 -9766
  310. package/dist/manager/_manager-chunks/globals-runtime-DDOIxI_l.js +0 -1584
  311. package/dist/manager/_manager-chunks/runtime-CuJiHYCp.js +0 -22
  312. package/dist/manager/_manager-chunks/runtime-DFhLVh8q.js +0 -456
  313. package/dist/preview/_chunks/runtime-BTPtVY1p.js +0 -1102
  314. package/dist/preview/_chunks/runtime-DZToXfvO.js +0 -9767
@@ -1,2058 +1,6 @@
1
- import { a as __toESM, n as __esmMin, r as __exportAll } from "./runtime-BdGkqNEt.js";
2
- import { U as require_css_escape, W as require_redent, nt as require_picocolors_browser } from "./runtime-BZSnICCg.js";
3
- import { d as init_adobe_css_tools, u as a } from "./runtime-BTPtVY1p.js";
4
- import { i as require_lib } from "./runtime-BIzIdDbb.js";
5
- import { n as getConfig, r as init_dom_esm } from "./runtime-DZToXfvO.js";
6
- //#region ../../node_modules/@testing-library/jest-dom/node_modules/dom-accessibility-api/dist/polyfills/array.from.mjs
7
- function isCallable(fn) {
8
- return typeof fn === "function" || toStr.call(fn) === "[object Function]";
9
- }
10
- function toInteger(value) {
11
- var number = Number(value);
12
- if (isNaN(number)) return 0;
13
- if (number === 0 || !isFinite(number)) return number;
14
- return (number > 0 ? 1 : -1) * Math.floor(Math.abs(number));
15
- }
16
- function toLength(value) {
17
- var len = toInteger(value);
18
- return Math.min(Math.max(len, 0), maxSafeInteger);
19
- }
20
- /**
21
- * Creates an array from an iterable object.
22
- * @param iterable An iterable object to convert to an array.
23
- */
24
- /**
25
- * Creates an array from an iterable object.
26
- * @param iterable An iterable object to convert to an array.
27
- * @param mapfn A mapping function to call on every element of the array.
28
- * @param thisArg Value of 'this' used to invoke the mapfn.
29
- */
30
- function arrayFrom(arrayLike, mapFn) {
31
- var C = Array;
32
- var items = Object(arrayLike);
33
- if (arrayLike == null) throw new TypeError("Array.from requires an array-like object - not null or undefined");
34
- if (typeof mapFn !== "undefined") {
35
- if (!isCallable(mapFn)) throw new TypeError("Array.from: when provided, the second argument must be a function");
36
- }
37
- var len = toLength(items.length);
38
- var A = isCallable(C) ? Object(new C(len)) : new Array(len);
39
- var k = 0;
40
- var kValue;
41
- while (k < len) {
42
- kValue = items[k];
43
- if (mapFn) A[k] = mapFn(kValue, k);
44
- else A[k] = kValue;
45
- k += 1;
46
- }
47
- A.length = len;
48
- return A;
49
- }
50
- var toStr, maxSafeInteger;
51
- function init_array_from() {
52
- return (init_array_from = __esmMin((() => {
53
- toStr = Object.prototype.toString;
54
- maxSafeInteger = Math.pow(2, 53) - 1;
55
- })))();
56
- }
57
- //#endregion
58
- //#region ../../node_modules/@testing-library/jest-dom/node_modules/dom-accessibility-api/dist/polyfills/SetLike.mjs
59
- function _typeof$1(o) {
60
- "@babel/helpers - typeof";
61
- return _typeof$1 = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(o) {
62
- return typeof o;
63
- } : function(o) {
64
- return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
65
- }, _typeof$1(o);
66
- }
67
- function _classCallCheck(instance, Constructor) {
68
- if (!(instance instanceof Constructor)) throw new TypeError("Cannot call a class as a function");
69
- }
70
- function _defineProperties(target, props) {
71
- for (var i = 0; i < props.length; i++) {
72
- var descriptor = props[i];
73
- descriptor.enumerable = descriptor.enumerable || false;
74
- descriptor.configurable = true;
75
- if ("value" in descriptor) descriptor.writable = true;
76
- Object.defineProperty(target, _toPropertyKey$1(descriptor.key), descriptor);
77
- }
78
- }
79
- function _createClass(Constructor, protoProps, staticProps) {
80
- if (protoProps) _defineProperties(Constructor.prototype, protoProps);
81
- if (staticProps) _defineProperties(Constructor, staticProps);
82
- Object.defineProperty(Constructor, "prototype", { writable: false });
83
- return Constructor;
84
- }
85
- function _defineProperty$1(obj, key, value) {
86
- key = _toPropertyKey$1(key);
87
- if (key in obj) Object.defineProperty(obj, key, {
88
- value,
89
- enumerable: true,
90
- configurable: true,
91
- writable: true
92
- });
93
- else obj[key] = value;
94
- return obj;
95
- }
96
- function _toPropertyKey$1(arg) {
97
- var key = _toPrimitive$1(arg, "string");
98
- return _typeof$1(key) === "symbol" ? key : String(key);
99
- }
100
- function _toPrimitive$1(input, hint) {
101
- if (_typeof$1(input) !== "object" || input === null) return input;
102
- var prim = input[Symbol.toPrimitive];
103
- if (prim !== void 0) {
104
- var res = prim.call(input, hint || "default");
105
- if (_typeof$1(res) !== "object") return res;
106
- throw new TypeError("@@toPrimitive must return a primitive value.");
107
- }
108
- return (hint === "string" ? String : Number)(input);
109
- }
110
- var SetLike, SetLike_default;
111
- function init_SetLike() {
112
- return (init_SetLike = __esmMin((() => {
113
- SetLike = /*#__PURE__*/ function() {
114
- function SetLike() {
115
- var items = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : [];
116
- _classCallCheck(this, SetLike);
117
- _defineProperty$1(this, "items", void 0);
118
- this.items = items;
119
- }
120
- _createClass(SetLike, [
121
- {
122
- key: "add",
123
- value: function add(value) {
124
- if (this.has(value) === false) this.items.push(value);
125
- return this;
126
- }
127
- },
128
- {
129
- key: "clear",
130
- value: function clear() {
131
- this.items = [];
132
- }
133
- },
134
- {
135
- key: "delete",
136
- value: function _delete(value) {
137
- var previousLength = this.items.length;
138
- this.items = this.items.filter(function(item) {
139
- return item !== value;
140
- });
141
- return previousLength !== this.items.length;
142
- }
143
- },
144
- {
145
- key: "forEach",
146
- value: function forEach(callbackfn) {
147
- var _this = this;
148
- this.items.forEach(function(item) {
149
- callbackfn(item, item, _this);
150
- });
151
- }
152
- },
153
- {
154
- key: "has",
155
- value: function has(value) {
156
- return this.items.indexOf(value) !== -1;
157
- }
158
- },
159
- {
160
- key: "size",
161
- get: function get() {
162
- return this.items.length;
163
- }
164
- }
165
- ]);
166
- return SetLike;
167
- }();
168
- SetLike_default = typeof Set === "undefined" ? Set : SetLike;
169
- })))();
170
- }
171
- //#endregion
172
- //#region ../../node_modules/@testing-library/jest-dom/node_modules/dom-accessibility-api/dist/getRole.mjs
173
- /**
174
- * Safe Element.localName for all supported environments
175
- * @param element
176
- */
177
- function getLocalName(element) {
178
- var _element$localName;
179
- return (_element$localName = element.localName) !== null && _element$localName !== void 0 ? _element$localName : element.tagName.toLowerCase();
180
- }
181
- /**
182
- *
183
- * @param element
184
- * @param role The role used for this element. This is specified to control whether you want to use the implicit or explicit role.
185
- */
186
- function hasGlobalAriaAttributes(element, role) {
187
- return [
188
- "aria-atomic",
189
- "aria-busy",
190
- "aria-controls",
191
- "aria-current",
192
- "aria-description",
193
- "aria-describedby",
194
- "aria-details",
195
- "aria-dropeffect",
196
- "aria-flowto",
197
- "aria-grabbed",
198
- "aria-hidden",
199
- "aria-keyshortcuts",
200
- "aria-label",
201
- "aria-labelledby",
202
- "aria-live",
203
- "aria-owns",
204
- "aria-relevant",
205
- "aria-roledescription"
206
- ].some(function(attributeName) {
207
- var _prohibitedAttributes;
208
- return element.hasAttribute(attributeName) && !((_prohibitedAttributes = prohibitedAttributes[role]) !== null && _prohibitedAttributes !== void 0 && _prohibitedAttributes.has(attributeName));
209
- });
210
- }
211
- function ignorePresentationalRole(element, implicitRole) {
212
- return hasGlobalAriaAttributes(element, implicitRole);
213
- }
214
- function getRole(element) {
215
- var explicitRole = getExplicitRole(element);
216
- if (explicitRole === null || presentationRoles.indexOf(explicitRole) !== -1) {
217
- var implicitRole = getImplicitRole(element);
218
- if (presentationRoles.indexOf(explicitRole || "") === -1 || ignorePresentationalRole(element, implicitRole || "")) return implicitRole;
219
- }
220
- return explicitRole;
221
- }
222
- function getImplicitRole(element) {
223
- var mappedByTag = localNameToRoleMappings[getLocalName(element)];
224
- if (mappedByTag !== void 0) return mappedByTag;
225
- switch (getLocalName(element)) {
226
- case "a":
227
- case "area":
228
- case "link":
229
- if (element.hasAttribute("href")) return "link";
230
- break;
231
- case "img":
232
- if (element.getAttribute("alt") === "" && !ignorePresentationalRole(element, "img")) return "presentation";
233
- return "img";
234
- case "input":
235
- var type = element.type;
236
- switch (type) {
237
- case "button":
238
- case "image":
239
- case "reset":
240
- case "submit": return "button";
241
- case "checkbox":
242
- case "radio": return type;
243
- case "range": return "slider";
244
- case "email":
245
- case "tel":
246
- case "text":
247
- case "url":
248
- if (element.hasAttribute("list")) return "combobox";
249
- return "textbox";
250
- case "search":
251
- if (element.hasAttribute("list")) return "combobox";
252
- return "searchbox";
253
- case "number": return "spinbutton";
254
- default: return null;
255
- }
256
- case "select":
257
- if (element.hasAttribute("multiple") || element.size > 1) return "listbox";
258
- return "combobox";
259
- }
260
- return null;
261
- }
262
- function getExplicitRole(element) {
263
- var role = element.getAttribute("role");
264
- if (role !== null) {
265
- var explicitRole = role.trim().split(" ")[0];
266
- if (explicitRole.length > 0) return explicitRole;
267
- }
268
- return null;
269
- }
270
- var localNameToRoleMappings, prohibitedAttributes;
271
- function init_getRole() {
272
- return (init_getRole = __esmMin((() => {
273
- init_util();
274
- localNameToRoleMappings = {
275
- article: "article",
276
- aside: "complementary",
277
- button: "button",
278
- datalist: "listbox",
279
- dd: "definition",
280
- details: "group",
281
- dialog: "dialog",
282
- dt: "term",
283
- fieldset: "group",
284
- figure: "figure",
285
- form: "form",
286
- footer: "contentinfo",
287
- h1: "heading",
288
- h2: "heading",
289
- h3: "heading",
290
- h4: "heading",
291
- h5: "heading",
292
- h6: "heading",
293
- header: "banner",
294
- hr: "separator",
295
- html: "document",
296
- legend: "legend",
297
- li: "listitem",
298
- math: "math",
299
- main: "main",
300
- menu: "list",
301
- nav: "navigation",
302
- ol: "list",
303
- optgroup: "group",
304
- option: "option",
305
- output: "status",
306
- progress: "progressbar",
307
- section: "region",
308
- summary: "button",
309
- table: "table",
310
- tbody: "rowgroup",
311
- textarea: "textbox",
312
- tfoot: "rowgroup",
313
- td: "cell",
314
- th: "columnheader",
315
- thead: "rowgroup",
316
- tr: "row",
317
- ul: "list"
318
- };
319
- prohibitedAttributes = {
320
- caption: /* @__PURE__ */ new Set(["aria-label", "aria-labelledby"]),
321
- code: /* @__PURE__ */ new Set(["aria-label", "aria-labelledby"]),
322
- deletion: /* @__PURE__ */ new Set(["aria-label", "aria-labelledby"]),
323
- emphasis: /* @__PURE__ */ new Set(["aria-label", "aria-labelledby"]),
324
- generic: /* @__PURE__ */ new Set([
325
- "aria-label",
326
- "aria-labelledby",
327
- "aria-roledescription"
328
- ]),
329
- insertion: /* @__PURE__ */ new Set(["aria-label", "aria-labelledby"]),
330
- none: /* @__PURE__ */ new Set(["aria-label", "aria-labelledby"]),
331
- paragraph: /* @__PURE__ */ new Set(["aria-label", "aria-labelledby"]),
332
- presentation: /* @__PURE__ */ new Set(["aria-label", "aria-labelledby"]),
333
- strong: /* @__PURE__ */ new Set(["aria-label", "aria-labelledby"]),
334
- subscript: /* @__PURE__ */ new Set(["aria-label", "aria-labelledby"]),
335
- superscript: /* @__PURE__ */ new Set(["aria-label", "aria-labelledby"])
336
- };
337
- })))();
338
- }
339
- //#endregion
340
- //#region ../../node_modules/@testing-library/jest-dom/node_modules/dom-accessibility-api/dist/util.mjs
341
- function isElement$2(node) {
342
- return node !== null && node.nodeType === node.ELEMENT_NODE;
343
- }
344
- function isHTMLTableCaptionElement(node) {
345
- return isElement$2(node) && getLocalName(node) === "caption";
346
- }
347
- function isHTMLInputElement(node) {
348
- return isElement$2(node) && getLocalName(node) === "input";
349
- }
350
- function isHTMLOptGroupElement(node) {
351
- return isElement$2(node) && getLocalName(node) === "optgroup";
352
- }
353
- function isHTMLSelectElement(node) {
354
- return isElement$2(node) && getLocalName(node) === "select";
355
- }
356
- function isHTMLTableElement(node) {
357
- return isElement$2(node) && getLocalName(node) === "table";
358
- }
359
- function isHTMLTextAreaElement(node) {
360
- return isElement$2(node) && getLocalName(node) === "textarea";
361
- }
362
- function safeWindow(node) {
363
- var defaultView = (node.ownerDocument === null ? node : node.ownerDocument).defaultView;
364
- if (defaultView === null) throw new TypeError("no window available");
365
- return defaultView;
366
- }
367
- function isHTMLFieldSetElement(node) {
368
- return isElement$2(node) && getLocalName(node) === "fieldset";
369
- }
370
- function isHTMLLegendElement(node) {
371
- return isElement$2(node) && getLocalName(node) === "legend";
372
- }
373
- function isHTMLSlotElement(node) {
374
- return isElement$2(node) && getLocalName(node) === "slot";
375
- }
376
- function isSVGElement(node) {
377
- return isElement$2(node) && node.ownerSVGElement !== void 0;
378
- }
379
- function isSVGSVGElement(node) {
380
- return isElement$2(node) && getLocalName(node) === "svg";
381
- }
382
- function isSVGTitleElement(node) {
383
- return isSVGElement(node) && getLocalName(node) === "title";
384
- }
385
- /**
386
- *
387
- * @param {Node} node -
388
- * @param {string} attributeName -
389
- * @returns {Element[]} -
390
- */
391
- function queryIdRefs(node, attributeName) {
392
- if (isElement$2(node) && node.hasAttribute(attributeName)) {
393
- var ids = node.getAttribute(attributeName).split(" ");
394
- var root = node.getRootNode ? node.getRootNode() : node.ownerDocument;
395
- return ids.map(function(id) {
396
- return root.getElementById(id);
397
- }).filter(function(element) {
398
- return element !== null;
399
- });
400
- }
401
- return [];
402
- }
403
- function hasAnyConcreteRoles(node, roles) {
404
- if (isElement$2(node)) return roles.indexOf(getRole(node)) !== -1;
405
- return false;
406
- }
407
- var presentationRoles;
408
- function init_util() {
409
- return (init_util = __esmMin((() => {
410
- init_getRole();
411
- presentationRoles = ["presentation", "none"];
412
- })))();
413
- }
414
- //#endregion
415
- //#region ../../node_modules/@testing-library/jest-dom/node_modules/dom-accessibility-api/dist/accessible-name-and-description.mjs
416
- /**
417
- * A string of characters where all carriage returns, newlines, tabs, and form-feeds are replaced with a single space, and multiple spaces are reduced to a single space. The string contains only character data; it does not contain any markup.
418
- */
419
- /**
420
- * interface for an options-bag where `window.getComputedStyle` can be mocked
421
- */
422
- /**
423
- *
424
- * @param {string} string -
425
- * @returns {FlatString} -
426
- */
427
- function asFlatString(s) {
428
- return s.trim().replace(/\s\s+/g, " ");
429
- }
430
- /**
431
- *
432
- * @param node -
433
- * @param options - These are not optional to prevent accidentally calling it without options in `computeAccessibleName`
434
- * @returns {boolean} -
435
- */
436
- function isHidden(node, getComputedStyleImplementation) {
437
- if (!isElement$2(node)) return false;
438
- if (node.hasAttribute("hidden") || node.getAttribute("aria-hidden") === "true") return true;
439
- var style = getComputedStyleImplementation(node);
440
- return style.getPropertyValue("display") === "none" || style.getPropertyValue("visibility") === "hidden";
441
- }
442
- /**
443
- * @param {Node} node -
444
- * @returns {boolean} - As defined in step 2E of https://w3c.github.io/accname/#mapping_additional_nd_te
445
- */
446
- function isControl(node) {
447
- return hasAnyConcreteRoles(node, [
448
- "button",
449
- "combobox",
450
- "listbox",
451
- "textbox"
452
- ]) || hasAbstractRole(node, "range");
453
- }
454
- function hasAbstractRole(node, role) {
455
- if (!isElement$2(node)) return false;
456
- switch (role) {
457
- case "range": return hasAnyConcreteRoles(node, [
458
- "meter",
459
- "progressbar",
460
- "scrollbar",
461
- "slider",
462
- "spinbutton"
463
- ]);
464
- default: throw new TypeError("No knowledge about abstract role '".concat(role, "'. This is likely a bug :("));
465
- }
466
- }
467
- /**
468
- * element.querySelectorAll but also considers owned tree
469
- * @param element
470
- * @param selectors
471
- */
472
- function querySelectorAllSubtree(element, selectors) {
473
- var elements = arrayFrom(element.querySelectorAll(selectors));
474
- queryIdRefs(element, "aria-owns").forEach(function(root) {
475
- elements.push.apply(elements, arrayFrom(root.querySelectorAll(selectors)));
476
- });
477
- return elements;
478
- }
479
- function querySelectedOptions(listbox) {
480
- if (isHTMLSelectElement(listbox)) return listbox.selectedOptions || querySelectorAllSubtree(listbox, "[selected]");
481
- return querySelectorAllSubtree(listbox, "[aria-selected=\"true\"]");
482
- }
483
- function isMarkedPresentational(node) {
484
- return hasAnyConcreteRoles(node, presentationRoles);
485
- }
486
- /**
487
- * Elements specifically listed in html-aam
488
- *
489
- * We don't need this for `label` or `legend` elements.
490
- * Their implicit roles already allow "naming from content".
491
- *
492
- * sources:
493
- *
494
- * - https://w3c.github.io/html-aam/#table-element
495
- */
496
- function isNativeHostLanguageTextAlternativeElement(node) {
497
- return isHTMLTableCaptionElement(node);
498
- }
499
- /**
500
- * https://w3c.github.io/aria/#namefromcontent
501
- */
502
- function allowsNameFromContent(node) {
503
- return hasAnyConcreteRoles(node, [
504
- "button",
505
- "cell",
506
- "checkbox",
507
- "columnheader",
508
- "gridcell",
509
- "heading",
510
- "label",
511
- "legend",
512
- "link",
513
- "menuitem",
514
- "menuitemcheckbox",
515
- "menuitemradio",
516
- "option",
517
- "radio",
518
- "row",
519
- "rowheader",
520
- "switch",
521
- "tab",
522
- "tooltip",
523
- "treeitem"
524
- ]);
525
- }
526
- /**
527
- * TODO https://github.com/eps1lon/dom-accessibility-api/issues/100
528
- */
529
- function isDescendantOfNativeHostLanguageTextAlternativeElement(node) {
530
- return false;
531
- }
532
- function getValueOfTextbox(element) {
533
- if (isHTMLInputElement(element) || isHTMLTextAreaElement(element)) return element.value;
534
- return element.textContent || "";
535
- }
536
- function getTextualContent(declaration) {
537
- var content = declaration.getPropertyValue("content");
538
- if (/^["'].*["']$/.test(content)) return content.slice(1, -1);
539
- return "";
540
- }
541
- /**
542
- * https://html.spec.whatwg.org/multipage/forms.html#category-label
543
- * TODO: form-associated custom elements
544
- * @param element
545
- */
546
- function isLabelableElement(element) {
547
- var localName = getLocalName(element);
548
- return localName === "button" || localName === "input" && element.getAttribute("type") !== "hidden" || localName === "meter" || localName === "output" || localName === "progress" || localName === "select" || localName === "textarea";
549
- }
550
- /**
551
- * > [...], then the first such descendant in tree order is the label element's labeled control.
552
- * -- https://html.spec.whatwg.org/multipage/forms.html#labeled-control
553
- * @param element
554
- */
555
- function findLabelableElement(element) {
556
- if (isLabelableElement(element)) return element;
557
- var labelableElement = null;
558
- element.childNodes.forEach(function(childNode) {
559
- if (labelableElement === null && isElement$2(childNode)) {
560
- var descendantLabelableElement = findLabelableElement(childNode);
561
- if (descendantLabelableElement !== null) labelableElement = descendantLabelableElement;
562
- }
563
- });
564
- return labelableElement;
565
- }
566
- /**
567
- * Polyfill of HTMLLabelElement.control
568
- * https://html.spec.whatwg.org/multipage/forms.html#labeled-control
569
- * @param label
570
- */
571
- function getControlOfLabel(label) {
572
- if (label.control !== void 0) return label.control;
573
- var htmlFor = label.getAttribute("for");
574
- if (htmlFor !== null) return label.ownerDocument.getElementById(htmlFor);
575
- return findLabelableElement(label);
576
- }
577
- /**
578
- * Polyfill of HTMLInputElement.labels
579
- * https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement/labels
580
- * @param element
581
- */
582
- function getLabels(element) {
583
- var labelsProperty = element.labels;
584
- if (labelsProperty === null) return labelsProperty;
585
- if (labelsProperty !== void 0) return arrayFrom(labelsProperty);
586
- if (!isLabelableElement(element)) return null;
587
- var document = element.ownerDocument;
588
- return arrayFrom(document.querySelectorAll("label")).filter(function(label) {
589
- return getControlOfLabel(label) === element;
590
- });
591
- }
592
- /**
593
- * Gets the contents of a slot used for computing the accname
594
- * @param slot
595
- */
596
- function getSlotContents(slot) {
597
- var assignedNodes = slot.assignedNodes();
598
- if (assignedNodes.length === 0) return arrayFrom(slot.childNodes);
599
- return assignedNodes;
600
- }
601
- /**
602
- * implements https://w3c.github.io/accname/#mapping_additional_nd_te
603
- * @param root
604
- * @param options
605
- * @returns
606
- */
607
- function computeTextAlternative(root) {
608
- var options = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {};
609
- var consultedNodes = new SetLike_default();
610
- var window = safeWindow(root);
611
- var _options$compute = options.compute, compute = _options$compute === void 0 ? "name" : _options$compute, _options$computedStyl = options.computedStyleSupportsPseudoElements, computedStyleSupportsPseudoElements = _options$computedStyl === void 0 ? options.getComputedStyle !== void 0 : _options$computedStyl, _options$getComputedS = options.getComputedStyle, getComputedStyle = _options$getComputedS === void 0 ? window.getComputedStyle.bind(window) : _options$getComputedS, _options$hidden = options.hidden, hidden = _options$hidden === void 0 ? false : _options$hidden;
612
- function computeMiscTextAlternative(node, context) {
613
- var accumulatedText = "";
614
- if (isElement$2(node) && computedStyleSupportsPseudoElements) {
615
- var beforeContent = getTextualContent(getComputedStyle(node, "::before"));
616
- accumulatedText = "".concat(beforeContent, " ").concat(accumulatedText);
617
- }
618
- (isHTMLSlotElement(node) ? getSlotContents(node) : arrayFrom(node.childNodes).concat(queryIdRefs(node, "aria-owns"))).forEach(function(child) {
619
- var result = computeTextAlternative(child, {
620
- isEmbeddedInLabel: context.isEmbeddedInLabel,
621
- isReferenced: false,
622
- recursion: true
623
- });
624
- var separator = (isElement$2(child) ? getComputedStyle(child).getPropertyValue("display") : "inline") !== "inline" ? " " : "";
625
- accumulatedText += "".concat(separator).concat(result).concat(separator);
626
- });
627
- if (isElement$2(node) && computedStyleSupportsPseudoElements) {
628
- var afterContent = getTextualContent(getComputedStyle(node, "::after"));
629
- accumulatedText = "".concat(accumulatedText, " ").concat(afterContent);
630
- }
631
- return accumulatedText.trim();
632
- }
633
- /**
634
- *
635
- * @param element
636
- * @param attributeName
637
- * @returns A string non-empty string or `null`
638
- */
639
- function useAttribute(element, attributeName) {
640
- var attribute = element.getAttributeNode(attributeName);
641
- if (attribute !== null && !consultedNodes.has(attribute) && attribute.value.trim() !== "") {
642
- consultedNodes.add(attribute);
643
- return attribute.value;
644
- }
645
- return null;
646
- }
647
- function computeTooltipAttributeValue(node) {
648
- if (!isElement$2(node)) return null;
649
- return useAttribute(node, "title");
650
- }
651
- function computeElementTextAlternative(node) {
652
- if (!isElement$2(node)) return null;
653
- if (isHTMLFieldSetElement(node)) {
654
- consultedNodes.add(node);
655
- var children = arrayFrom(node.childNodes);
656
- for (var i = 0; i < children.length; i += 1) {
657
- var child = children[i];
658
- if (isHTMLLegendElement(child)) return computeTextAlternative(child, {
659
- isEmbeddedInLabel: false,
660
- isReferenced: false,
661
- recursion: false
662
- });
663
- }
664
- } else if (isHTMLTableElement(node)) {
665
- consultedNodes.add(node);
666
- var _children = arrayFrom(node.childNodes);
667
- for (var _i = 0; _i < _children.length; _i += 1) {
668
- var _child = _children[_i];
669
- if (isHTMLTableCaptionElement(_child)) return computeTextAlternative(_child, {
670
- isEmbeddedInLabel: false,
671
- isReferenced: false,
672
- recursion: false
673
- });
674
- }
675
- } else if (isSVGSVGElement(node)) {
676
- consultedNodes.add(node);
677
- var _children2 = arrayFrom(node.childNodes);
678
- for (var _i2 = 0; _i2 < _children2.length; _i2 += 1) {
679
- var _child2 = _children2[_i2];
680
- if (isSVGTitleElement(_child2)) return _child2.textContent;
681
- }
682
- return null;
683
- } else if (getLocalName(node) === "img" || getLocalName(node) === "area") {
684
- var nameFromAlt = useAttribute(node, "alt");
685
- if (nameFromAlt !== null) return nameFromAlt;
686
- } else if (isHTMLOptGroupElement(node)) {
687
- var nameFromLabel = useAttribute(node, "label");
688
- if (nameFromLabel !== null) return nameFromLabel;
689
- }
690
- if (isHTMLInputElement(node) && (node.type === "button" || node.type === "submit" || node.type === "reset")) {
691
- var nameFromValue = useAttribute(node, "value");
692
- if (nameFromValue !== null) return nameFromValue;
693
- if (node.type === "submit") return "Submit";
694
- if (node.type === "reset") return "Reset";
695
- }
696
- var labels = getLabels(node);
697
- if (labels !== null && labels.length !== 0) {
698
- consultedNodes.add(node);
699
- return arrayFrom(labels).map(function(element) {
700
- return computeTextAlternative(element, {
701
- isEmbeddedInLabel: true,
702
- isReferenced: false,
703
- recursion: true
704
- });
705
- }).filter(function(label) {
706
- return label.length > 0;
707
- }).join(" ");
708
- }
709
- if (isHTMLInputElement(node) && node.type === "image") {
710
- var _nameFromAlt = useAttribute(node, "alt");
711
- if (_nameFromAlt !== null) return _nameFromAlt;
712
- var nameFromTitle = useAttribute(node, "title");
713
- if (nameFromTitle !== null) return nameFromTitle;
714
- return "Submit Query";
715
- }
716
- if (hasAnyConcreteRoles(node, ["button"])) {
717
- var nameFromSubTree = computeMiscTextAlternative(node, {
718
- isEmbeddedInLabel: false,
719
- isReferenced: false
720
- });
721
- if (nameFromSubTree !== "") return nameFromSubTree;
722
- }
723
- return null;
724
- }
725
- function computeTextAlternative(current, context) {
726
- if (consultedNodes.has(current)) return "";
727
- if (!hidden && isHidden(current, getComputedStyle) && !context.isReferenced) {
728
- consultedNodes.add(current);
729
- return "";
730
- }
731
- var labelAttributeNode = isElement$2(current) ? current.getAttributeNode("aria-labelledby") : null;
732
- var labelElements = labelAttributeNode !== null && !consultedNodes.has(labelAttributeNode) ? queryIdRefs(current, "aria-labelledby") : [];
733
- if (compute === "name" && !context.isReferenced && labelElements.length > 0) {
734
- consultedNodes.add(labelAttributeNode);
735
- return labelElements.map(function(element) {
736
- return computeTextAlternative(element, {
737
- isEmbeddedInLabel: context.isEmbeddedInLabel,
738
- isReferenced: true,
739
- recursion: false
740
- });
741
- }).join(" ");
742
- }
743
- var skipToStep2E = context.recursion && isControl(current) && compute === "name";
744
- if (!skipToStep2E) {
745
- var ariaLabel = (isElement$2(current) && current.getAttribute("aria-label") || "").trim();
746
- if (ariaLabel !== "" && compute === "name") {
747
- consultedNodes.add(current);
748
- return ariaLabel;
749
- }
750
- if (!isMarkedPresentational(current)) {
751
- var elementTextAlternative = computeElementTextAlternative(current);
752
- if (elementTextAlternative !== null) {
753
- consultedNodes.add(current);
754
- return elementTextAlternative;
755
- }
756
- }
757
- }
758
- if (hasAnyConcreteRoles(current, ["menu"])) {
759
- consultedNodes.add(current);
760
- return "";
761
- }
762
- if (skipToStep2E || context.isEmbeddedInLabel || context.isReferenced) {
763
- if (hasAnyConcreteRoles(current, ["combobox", "listbox"])) {
764
- consultedNodes.add(current);
765
- var selectedOptions = querySelectedOptions(current);
766
- if (selectedOptions.length === 0) return isHTMLInputElement(current) ? current.value : "";
767
- return arrayFrom(selectedOptions).map(function(selectedOption) {
768
- return computeTextAlternative(selectedOption, {
769
- isEmbeddedInLabel: context.isEmbeddedInLabel,
770
- isReferenced: false,
771
- recursion: true
772
- });
773
- }).join(" ");
774
- }
775
- if (hasAbstractRole(current, "range")) {
776
- consultedNodes.add(current);
777
- if (current.hasAttribute("aria-valuetext")) return current.getAttribute("aria-valuetext");
778
- if (current.hasAttribute("aria-valuenow")) return current.getAttribute("aria-valuenow");
779
- return current.getAttribute("value") || "";
780
- }
781
- if (hasAnyConcreteRoles(current, ["textbox"])) {
782
- consultedNodes.add(current);
783
- return getValueOfTextbox(current);
784
- }
785
- }
786
- if (allowsNameFromContent(current) || isElement$2(current) && context.isReferenced || isNativeHostLanguageTextAlternativeElement(current) || isDescendantOfNativeHostLanguageTextAlternativeElement(current)) {
787
- var accumulatedText2F = computeMiscTextAlternative(current, {
788
- isEmbeddedInLabel: context.isEmbeddedInLabel,
789
- isReferenced: false
790
- });
791
- if (accumulatedText2F !== "") {
792
- consultedNodes.add(current);
793
- return accumulatedText2F;
794
- }
795
- }
796
- if (current.nodeType === current.TEXT_NODE) {
797
- consultedNodes.add(current);
798
- return current.textContent || "";
799
- }
800
- if (context.recursion) {
801
- consultedNodes.add(current);
802
- return computeMiscTextAlternative(current, {
803
- isEmbeddedInLabel: context.isEmbeddedInLabel,
804
- isReferenced: false
805
- });
806
- }
807
- var tooltipAttributeValue = computeTooltipAttributeValue(current);
808
- if (tooltipAttributeValue !== null) {
809
- consultedNodes.add(current);
810
- return tooltipAttributeValue;
811
- }
812
- consultedNodes.add(current);
813
- return "";
814
- }
815
- return asFlatString(computeTextAlternative(root, {
816
- isEmbeddedInLabel: false,
817
- isReferenced: compute === "description",
818
- recursion: false
819
- }));
820
- }
821
- function init_accessible_name_and_description() {
822
- return (init_accessible_name_and_description = __esmMin((() => {
823
- init_array_from();
824
- init_SetLike();
825
- init_util();
826
- })))();
827
- }
828
- //#endregion
829
- //#region ../../node_modules/@testing-library/jest-dom/node_modules/dom-accessibility-api/dist/accessible-description.mjs
830
- function _typeof(o) {
831
- "@babel/helpers - typeof";
832
- return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(o) {
833
- return typeof o;
834
- } : function(o) {
835
- return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
836
- }, _typeof(o);
837
- }
838
- function ownKeys(e, r) {
839
- var t = Object.keys(e);
840
- if (Object.getOwnPropertySymbols) {
841
- var o = Object.getOwnPropertySymbols(e);
842
- r && (o = o.filter(function(r) {
843
- return Object.getOwnPropertyDescriptor(e, r).enumerable;
844
- })), t.push.apply(t, o);
845
- }
846
- return t;
847
- }
848
- function _objectSpread(e) {
849
- for (var r = 1; r < arguments.length; r++) {
850
- var t = null != arguments[r] ? arguments[r] : {};
851
- r % 2 ? ownKeys(Object(t), !0).forEach(function(r) {
852
- _defineProperty(e, r, t[r]);
853
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function(r) {
854
- Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
855
- });
856
- }
857
- return e;
858
- }
859
- function _defineProperty(obj, key, value) {
860
- key = _toPropertyKey(key);
861
- if (key in obj) Object.defineProperty(obj, key, {
862
- value,
863
- enumerable: true,
864
- configurable: true,
865
- writable: true
866
- });
867
- else obj[key] = value;
868
- return obj;
869
- }
870
- function _toPropertyKey(arg) {
871
- var key = _toPrimitive(arg, "string");
872
- return _typeof(key) === "symbol" ? key : String(key);
873
- }
874
- function _toPrimitive(input, hint) {
875
- if (_typeof(input) !== "object" || input === null) return input;
876
- var prim = input[Symbol.toPrimitive];
877
- if (prim !== void 0) {
878
- var res = prim.call(input, hint || "default");
879
- if (_typeof(res) !== "object") return res;
880
- throw new TypeError("@@toPrimitive must return a primitive value.");
881
- }
882
- return (hint === "string" ? String : Number)(input);
883
- }
884
- /**
885
- * @param root
886
- * @param options
887
- * @returns
888
- */
889
- function computeAccessibleDescription(root) {
890
- var options = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {};
891
- var description = queryIdRefs(root, "aria-describedby").map(function(element) {
892
- return computeTextAlternative(element, _objectSpread(_objectSpread({}, options), {}, { compute: "description" }));
893
- }).join(" ");
894
- if (description === "") {
895
- var ariaDescription = root.getAttribute("aria-description");
896
- description = ariaDescription === null ? "" : ariaDescription;
897
- }
898
- if (description === "") {
899
- var title = root.getAttribute("title");
900
- description = title === null ? "" : title;
901
- }
902
- return description;
903
- }
904
- function init_accessible_description() {
905
- return (init_accessible_description = __esmMin((() => {
906
- init_accessible_name_and_description();
907
- init_util();
908
- })))();
909
- }
910
- //#endregion
911
- //#region ../../node_modules/@testing-library/jest-dom/node_modules/dom-accessibility-api/dist/accessible-name.mjs
912
- /**
913
- * https://w3c.github.io/aria/#namefromprohibited
914
- */
915
- function prohibitsNaming(node) {
916
- return hasAnyConcreteRoles(node, [
917
- "caption",
918
- "code",
919
- "deletion",
920
- "emphasis",
921
- "generic",
922
- "insertion",
923
- "none",
924
- "paragraph",
925
- "presentation",
926
- "strong",
927
- "subscript",
928
- "superscript"
929
- ]);
930
- }
931
- /**
932
- * implements https://w3c.github.io/accname/#mapping_additional_nd_name
933
- * @param root
934
- * @param options
935
- * @returns
936
- */
937
- function computeAccessibleName(root) {
938
- var options = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {};
939
- if (prohibitsNaming(root)) return "";
940
- return computeTextAlternative(root, options);
941
- }
942
- function init_accessible_name() {
943
- return (init_accessible_name = __esmMin((() => {
944
- init_accessible_name_and_description();
945
- init_util();
946
- })))();
947
- }
948
- //#endregion
949
- //#region ../../node_modules/@testing-library/jest-dom/node_modules/dom-accessibility-api/dist/index.mjs
950
- function init_dist() {
951
- return (init_dist = __esmMin((() => {
952
- init_accessible_description();
953
- init_accessible_name();
954
- })))();
955
- }
956
- //#endregion
957
- //#region ../../node_modules/@testing-library/jest-dom/dist/matchers-35e4d3bd.mjs
958
- function checkHasWindow(htmlElement, ErrorClass, ...args) {
959
- if (!htmlElement || !htmlElement.ownerDocument || !htmlElement.ownerDocument.defaultView) throw new ErrorClass(htmlElement, ...args);
960
- }
961
- function checkNode(node, ...args) {
962
- checkHasWindow(node, NodeTypeError, ...args);
963
- if (!(node instanceof node.ownerDocument.defaultView.Node)) throw new NodeTypeError(node, ...args);
964
- }
965
- function checkHtmlElement(htmlElement, ...args) {
966
- checkHasWindow(htmlElement, HtmlElementTypeError, ...args);
967
- const window = htmlElement.ownerDocument.defaultView;
968
- if (!(htmlElement instanceof window.HTMLElement) && !(htmlElement instanceof window.SVGElement)) throw new HtmlElementTypeError(htmlElement, ...args);
969
- }
970
- function parseCSS(css, ...args) {
971
- const ast = a(`selector { ${css} }`, { silent: true }).stylesheet;
972
- if (ast.parsingErrors && ast.parsingErrors.length > 0) {
973
- const { reason, line } = ast.parsingErrors[0];
974
- throw new InvalidCSSError({
975
- css,
976
- message: `Syntax error parsing expected css: ${reason} on line: ${line}`
977
- }, ...args);
978
- }
979
- return ast.rules[0].declarations.filter((d) => d.type === "declaration").reduce((obj, { property, value }) => Object.assign(obj, { [property]: value }), {});
980
- }
981
- function display(context, value) {
982
- return typeof value === "string" ? value : context.utils.stringify(value);
983
- }
984
- function getMessage(context, matcher, expectedLabel, expectedValue, receivedLabel, receivedValue) {
985
- return [
986
- `${matcher}\n`,
987
- `${expectedLabel}:\n${context.utils.EXPECTED_COLOR((0, import_redent$1.default)(display(context, expectedValue), 2))}`,
988
- `${receivedLabel}:\n${context.utils.RECEIVED_COLOR((0, import_redent$1.default)(display(context, receivedValue), 2))}`
989
- ].join("\n");
990
- }
991
- function matches(textToMatch, matcher) {
992
- if (matcher instanceof RegExp) return matcher.test(textToMatch);
993
- else return textToMatch.includes(String(matcher));
994
- }
995
- function deprecate(name, replacementText) {
996
- console.warn(`Warning: ${name} has been deprecated and will be removed in future updates.`, replacementText);
997
- }
998
- function normalize$1(text) {
999
- return text.replace(/\s+/g, " ").trim();
1000
- }
1001
- function getTag(element) {
1002
- return element.tagName && element.tagName.toLowerCase();
1003
- }
1004
- function getSelectValue({ multiple, options }) {
1005
- const selectedOptions = [...options].filter((option) => option.selected);
1006
- if (multiple) return [...selectedOptions].map((opt) => opt.value);
1007
- /* istanbul ignore if */
1008
- if (selectedOptions.length === 0) return;
1009
- return selectedOptions[0].value;
1010
- }
1011
- function getInputValue(inputElement) {
1012
- switch (inputElement.type) {
1013
- case "number": return inputElement.value === "" ? null : Number(inputElement.value);
1014
- case "checkbox": return inputElement.checked;
1015
- default: return inputElement.value;
1016
- }
1017
- }
1018
- function getAccessibleValue(element) {
1019
- if (!rolesSupportingValues.includes(element.getAttribute("role"))) return;
1020
- return Number(element.getAttribute("aria-valuenow"));
1021
- }
1022
- function getSingleElementValue(element) {
1023
- /* istanbul ignore if */
1024
- if (!element) return;
1025
- switch (element.tagName.toLowerCase()) {
1026
- case "input": return getInputValue(element);
1027
- case "select": return getSelectValue(element);
1028
- default: return element.value ?? getAccessibleValue(element);
1029
- }
1030
- }
1031
- function toSentence(array, { wordConnector = ", ", lastWordConnector = " and " } = {}) {
1032
- return [array.slice(0, -1).join(wordConnector), array[array.length - 1]].join(array.length > 1 ? lastWordConnector : "");
1033
- }
1034
- function compareAsSet(val1, val2) {
1035
- if (Array.isArray(val1) && Array.isArray(val2)) return [...new Set(val1)].every((v) => new Set(val2).has(v));
1036
- return val1 === val2;
1037
- }
1038
- function toBeInTheDOM(element, container) {
1039
- deprecate("toBeInTheDOM", "Please use toBeInTheDocument for searching the entire document and toContainElement for searching a specific container.");
1040
- if (element) checkHtmlElement(element, toBeInTheDOM, this);
1041
- if (container) checkHtmlElement(container, toBeInTheDOM, this);
1042
- return {
1043
- pass: container ? container.contains(element) : !!element,
1044
- message: () => {
1045
- return [
1046
- this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeInTheDOM`, "element", ""),
1047
- "",
1048
- "Received:",
1049
- ` ${this.utils.printReceived(element ? element.cloneNode(false) : element)}`
1050
- ].join("\n");
1051
- }
1052
- };
1053
- }
1054
- function toBeInTheDocument(element) {
1055
- if (element !== null || !this.isNot) checkHtmlElement(element, toBeInTheDocument, this);
1056
- const pass = element === null ? false : element.ownerDocument === element.getRootNode({ composed: true });
1057
- const errorFound = () => {
1058
- return `expected document not to contain element, found ${this.utils.stringify(element.cloneNode(true))} instead`;
1059
- };
1060
- const errorNotFound = () => {
1061
- return `element could not be found in the document`;
1062
- };
1063
- return {
1064
- pass,
1065
- message: () => {
1066
- return [
1067
- this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeInTheDocument`, "element", ""),
1068
- "",
1069
- this.utils.RECEIVED_COLOR(this.isNot ? errorFound() : errorNotFound())
1070
- ].join("\n");
1071
- }
1072
- };
1073
- }
1074
- function toBeEmpty(element) {
1075
- deprecate("toBeEmpty", "Please use instead toBeEmptyDOMElement for finding empty nodes in the DOM.");
1076
- checkHtmlElement(element, toBeEmpty, this);
1077
- return {
1078
- pass: element.innerHTML === "",
1079
- message: () => {
1080
- return [
1081
- this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeEmpty`, "element", ""),
1082
- "",
1083
- "Received:",
1084
- ` ${this.utils.printReceived(element.innerHTML)}`
1085
- ].join("\n");
1086
- }
1087
- };
1088
- }
1089
- function toBeEmptyDOMElement(element) {
1090
- checkHtmlElement(element, toBeEmptyDOMElement, this);
1091
- return {
1092
- pass: isEmptyElement(element),
1093
- message: () => {
1094
- return [
1095
- this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeEmptyDOMElement`, "element", ""),
1096
- "",
1097
- "Received:",
1098
- ` ${this.utils.printReceived(element.innerHTML)}`
1099
- ].join("\n");
1100
- }
1101
- };
1102
- }
1103
- /**
1104
- * Identifies if an element doesn't contain child nodes (excluding comments)
1105
- * ℹ Node.COMMENT_NODE can't be used because of the following issue
1106
- * https://github.com/jsdom/jsdom/issues/2220
1107
- *
1108
- * @param {*} element an HtmlElement or SVGElement
1109
- * @return {*} true if the element only contains comments or none
1110
- */
1111
- function isEmptyElement(element) {
1112
- return [...element.childNodes].filter((node) => node.nodeType !== 8).length === 0;
1113
- }
1114
- function toContainElement(container, element) {
1115
- checkHtmlElement(container, toContainElement, this);
1116
- if (element !== null) checkHtmlElement(element, toContainElement, this);
1117
- return {
1118
- pass: container.contains(element),
1119
- message: () => {
1120
- return [
1121
- this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toContainElement`, "element", "element"),
1122
- "",
1123
- this.utils.RECEIVED_COLOR(`${this.utils.stringify(container.cloneNode(false))} ${this.isNot ? "contains:" : "does not contain:"} ${this.utils.stringify(element ? element.cloneNode(false) : element)}
1124
- `)
1125
- ].join("\n");
1126
- }
1127
- };
1128
- }
1129
- function getNormalizedHtml(container, htmlText) {
1130
- const div = container.ownerDocument.createElement("div");
1131
- div.innerHTML = htmlText;
1132
- return div.innerHTML;
1133
- }
1134
- function toContainHTML(container, htmlText) {
1135
- checkHtmlElement(container, toContainHTML, this);
1136
- if (typeof htmlText !== "string") throw new Error(`.toContainHTML() expects a string value, got ${htmlText}`);
1137
- return {
1138
- pass: container.outerHTML.includes(getNormalizedHtml(container, htmlText)),
1139
- message: () => {
1140
- return [
1141
- this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toContainHTML`, "element", ""),
1142
- "Expected:",
1143
- ` ${this.utils.EXPECTED_COLOR(htmlText)}`,
1144
- "Received:",
1145
- ` ${this.utils.printReceived(container.cloneNode(true))}`
1146
- ].join("\n");
1147
- }
1148
- };
1149
- }
1150
- function toHaveTextContent(node, checkWith, options = { normalizeWhitespace: true }) {
1151
- checkNode(node, toHaveTextContent, this);
1152
- const textContent = options.normalizeWhitespace ? normalize$1(node.textContent) : node.textContent.replace(/\u00a0/g, " ");
1153
- const checkingWithEmptyString = textContent !== "" && checkWith === "";
1154
- return {
1155
- pass: !checkingWithEmptyString && matches(textContent, checkWith),
1156
- message: () => {
1157
- const to = this.isNot ? "not to" : "to";
1158
- return getMessage(this, this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveTextContent`, "element", ""), checkingWithEmptyString ? `Checking with empty string will always match, use .toBeEmptyDOMElement() instead` : `Expected element ${to} have text content`, checkWith, "Received", textContent);
1159
- }
1160
- };
1161
- }
1162
- function toHaveAccessibleDescription(htmlElement, expectedAccessibleDescription) {
1163
- checkHtmlElement(htmlElement, toHaveAccessibleDescription, this);
1164
- const actualAccessibleDescription = computeAccessibleDescription(htmlElement);
1165
- const missingExpectedValue = arguments.length === 1;
1166
- let pass = false;
1167
- if (missingExpectedValue) pass = actualAccessibleDescription !== "";
1168
- else pass = expectedAccessibleDescription instanceof RegExp ? expectedAccessibleDescription.test(actualAccessibleDescription) : this.equals(actualAccessibleDescription, expectedAccessibleDescription);
1169
- return {
1170
- pass,
1171
- message: () => {
1172
- const to = this.isNot ? "not to" : "to";
1173
- return getMessage(this, this.utils.matcherHint(`${this.isNot ? ".not" : ""}.${toHaveAccessibleDescription.name}`, "element", ""), `Expected element ${to} have accessible description`, expectedAccessibleDescription, "Received", actualAccessibleDescription);
1174
- }
1175
- };
1176
- }
1177
- function toHaveAccessibleErrorMessage(htmlElement, expectedAccessibleErrorMessage) {
1178
- checkHtmlElement(htmlElement, toHaveAccessibleErrorMessage, this);
1179
- const to = this.isNot ? "not to" : "to";
1180
- const method = this.isNot ? ".not.toHaveAccessibleErrorMessage" : ".toHaveAccessibleErrorMessage";
1181
- const errormessageId = htmlElement.getAttribute("aria-errormessage");
1182
- if (!!errormessageId && /\s+/.test(errormessageId)) return {
1183
- pass: false,
1184
- message: () => {
1185
- return getMessage(this, this.utils.matcherHint(method, "element"), "Expected element's `aria-errormessage` attribute to be empty or a single, valid ID", "", "Received", `aria-errormessage="${errormessageId}"`);
1186
- }
1187
- };
1188
- const ariaInvalidVal = htmlElement.getAttribute(ariaInvalidName);
1189
- if (!htmlElement.hasAttribute(ariaInvalidName) || validStates.includes(ariaInvalidVal)) return {
1190
- pass: false,
1191
- message: () => {
1192
- return getMessage(this, this.utils.matcherHint(method, "element"), "Expected element to be marked as invalid with attribute", `${ariaInvalidName}="${String(true)}"`, "Received", htmlElement.hasAttribute("aria-invalid") ? `${ariaInvalidName}="${htmlElement.getAttribute(ariaInvalidName)}` : null);
1193
- }
1194
- };
1195
- const error = normalize$1(htmlElement.ownerDocument.getElementById(errormessageId)?.textContent ?? "");
1196
- return {
1197
- pass: expectedAccessibleErrorMessage === void 0 ? Boolean(error) : expectedAccessibleErrorMessage instanceof RegExp ? expectedAccessibleErrorMessage.test(error) : this.equals(error, expectedAccessibleErrorMessage),
1198
- message: () => {
1199
- return getMessage(this, this.utils.matcherHint(method, "element"), `Expected element ${to} have accessible error message`, expectedAccessibleErrorMessage ?? "", "Received", error);
1200
- }
1201
- };
1202
- }
1203
- function toHaveRole(htmlElement, expectedRole) {
1204
- checkHtmlElement(htmlElement, toHaveRole, this);
1205
- const actualRoles = getExplicitOrImplicitRoles(htmlElement);
1206
- return {
1207
- pass: actualRoles.some((el) => el === expectedRole),
1208
- message: () => {
1209
- const to = this.isNot ? "not to" : "to";
1210
- return getMessage(this, this.utils.matcherHint(`${this.isNot ? ".not" : ""}.${toHaveRole.name}`, "element", ""), `Expected element ${to} have role`, expectedRole, "Received", actualRoles.join(", "));
1211
- }
1212
- };
1213
- }
1214
- function getExplicitOrImplicitRoles(htmlElement) {
1215
- if (htmlElement.hasAttribute("role")) return htmlElement.getAttribute("role").split(" ").filter(Boolean);
1216
- return getImplicitAriaRoles(htmlElement);
1217
- }
1218
- function getImplicitAriaRoles(currentNode) {
1219
- for (const { match, roles } of elementRoleList) if (match(currentNode)) return [...roles];
1220
- /* istanbul ignore next */
1221
- return [];
1222
- }
1223
- /**
1224
- * Transform the roles map (with required attributes and constraints) to a list
1225
- * of roles. Each item in the list has functions to match an element against it.
1226
- *
1227
- * Essentially copied over from [dom-testing-library's
1228
- * helpers](https://github.com/testing-library/dom-testing-library/blob/bd04cf95a1ed85a2238f7dfc1a77d5d16b4f59dc/src/role-helpers.js#L80)
1229
- *
1230
- * TODO: If we are truly just copying over stuff, would it make sense to move
1231
- * this to a separate package?
1232
- *
1233
- * TODO: This technique relies on CSS selectors; are those consistently
1234
- * available in all jest-dom environments? Why do other matchers in this package
1235
- * not use them like this?
1236
- */
1237
- function buildElementRoleList(elementRolesMap) {
1238
- function makeElementSelector({ name, attributes }) {
1239
- return `${name}${attributes.map(({ name: attributeName, value, constraints = [] }) => {
1240
- if (constraints.indexOf("undefined") !== -1) return `:not([${attributeName}])`;
1241
- else if (value) return `[${attributeName}="${value}"]`;
1242
- else return `[${attributeName}]`;
1243
- }).join("")}`;
1244
- }
1245
- function getSelectorSpecificity({ attributes = [] }) {
1246
- return attributes.length;
1247
- }
1248
- function bySelectorSpecificity({ specificity: leftSpecificity }, { specificity: rightSpecificity }) {
1249
- return rightSpecificity - leftSpecificity;
1250
- }
1251
- function match(element) {
1252
- let { attributes = [] } = element;
1253
- const typeTextIndex = attributes.findIndex((attribute) => attribute.value && attribute.name === "type" && attribute.value === "text");
1254
- if (typeTextIndex >= 0) attributes = [...attributes.slice(0, typeTextIndex), ...attributes.slice(typeTextIndex + 1)];
1255
- const selector = makeElementSelector({
1256
- ...element,
1257
- attributes
1258
- });
1259
- return (node) => {
1260
- if (typeTextIndex >= 0 && node.type !== "text") return false;
1261
- return node.matches(selector);
1262
- };
1263
- }
1264
- let result = [];
1265
- for (const [element, roles] of elementRolesMap.entries()) result = [...result, {
1266
- match: match(element),
1267
- roles: Array.from(roles),
1268
- specificity: getSelectorSpecificity(element)
1269
- }];
1270
- return result.sort(bySelectorSpecificity);
1271
- }
1272
- function toHaveAccessibleName(htmlElement, expectedAccessibleName) {
1273
- checkHtmlElement(htmlElement, toHaveAccessibleName, this);
1274
- const actualAccessibleName = computeAccessibleName(htmlElement);
1275
- const missingExpectedValue = arguments.length === 1;
1276
- let pass = false;
1277
- if (missingExpectedValue) pass = actualAccessibleName !== "";
1278
- else pass = expectedAccessibleName instanceof RegExp ? expectedAccessibleName.test(actualAccessibleName) : this.equals(actualAccessibleName, expectedAccessibleName);
1279
- return {
1280
- pass,
1281
- message: () => {
1282
- const to = this.isNot ? "not to" : "to";
1283
- return getMessage(this, this.utils.matcherHint(`${this.isNot ? ".not" : ""}.${toHaveAccessibleName.name}`, "element", ""), `Expected element ${to} have accessible name`, expectedAccessibleName, "Received", actualAccessibleName);
1284
- }
1285
- };
1286
- }
1287
- function printAttribute(stringify, name, value) {
1288
- return value === void 0 ? name : `${name}=${stringify(value)}`;
1289
- }
1290
- function getAttributeComment(stringify, name, value) {
1291
- return value === void 0 ? `element.hasAttribute(${stringify(name)})` : `element.getAttribute(${stringify(name)}) === ${stringify(value)}`;
1292
- }
1293
- function toHaveAttribute(htmlElement, name, expectedValue) {
1294
- checkHtmlElement(htmlElement, toHaveAttribute, this);
1295
- const isExpectedValuePresent = expectedValue !== void 0;
1296
- const hasAttribute = htmlElement.hasAttribute(name);
1297
- const receivedValue = htmlElement.getAttribute(name);
1298
- return {
1299
- pass: isExpectedValuePresent ? hasAttribute && this.equals(receivedValue, expectedValue) : hasAttribute,
1300
- message: () => {
1301
- const to = this.isNot ? "not to" : "to";
1302
- const receivedAttribute = hasAttribute ? printAttribute(this.utils.stringify, name, receivedValue) : null;
1303
- const matcher = this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveAttribute`, "element", this.utils.printExpected(name), {
1304
- secondArgument: isExpectedValuePresent ? this.utils.printExpected(expectedValue) : void 0,
1305
- comment: getAttributeComment(this.utils.stringify, name, expectedValue)
1306
- });
1307
- return getMessage(this, matcher, `Expected the element ${to} have attribute`, printAttribute(this.utils.stringify, name, expectedValue), "Received", receivedAttribute);
1308
- }
1309
- };
1310
- }
1311
- function getExpectedClassNamesAndOptions(params) {
1312
- const lastParam = params.pop();
1313
- let expectedClassNames, options;
1314
- if (typeof lastParam === "object" && !(lastParam instanceof RegExp)) {
1315
- expectedClassNames = params;
1316
- options = lastParam;
1317
- } else {
1318
- expectedClassNames = params.concat(lastParam);
1319
- options = { exact: false };
1320
- }
1321
- return {
1322
- expectedClassNames,
1323
- options
1324
- };
1325
- }
1326
- function splitClassNames(str) {
1327
- if (!str) return [];
1328
- return str.split(/\s+/).filter((s) => s.length > 0);
1329
- }
1330
- function isSubset$1(subset, superset) {
1331
- return subset.every((strOrRegexp) => typeof strOrRegexp === "string" ? superset.includes(strOrRegexp) : superset.some((className) => strOrRegexp.test(className)));
1332
- }
1333
- function toHaveClass(htmlElement, ...params) {
1334
- checkHtmlElement(htmlElement, toHaveClass, this);
1335
- const { expectedClassNames, options } = getExpectedClassNamesAndOptions(params);
1336
- const received = splitClassNames(htmlElement.getAttribute("class"));
1337
- const expected = expectedClassNames.reduce((acc, className) => acc.concat(typeof className === "string" || !className ? splitClassNames(className) : className), []);
1338
- const hasRegExp = expected.some((className) => className instanceof RegExp);
1339
- if (options.exact && hasRegExp) throw new Error("Exact option does not support RegExp expected class names");
1340
- if (options.exact) return {
1341
- pass: isSubset$1(expected, received) && expected.length === received.length,
1342
- message: () => {
1343
- const to = this.isNot ? "not to" : "to";
1344
- return getMessage(this, this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveClass`, "element", this.utils.printExpected(expected.join(" "))), `Expected the element ${to} have EXACTLY defined classes`, expected.join(" "), "Received", received.join(" "));
1345
- }
1346
- };
1347
- return expected.length > 0 ? {
1348
- pass: isSubset$1(expected, received),
1349
- message: () => {
1350
- const to = this.isNot ? "not to" : "to";
1351
- return getMessage(this, this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveClass`, "element", this.utils.printExpected(expected.join(" "))), `Expected the element ${to} have class`, expected.join(" "), "Received", received.join(" "));
1352
- }
1353
- } : {
1354
- pass: this.isNot ? received.length > 0 : false,
1355
- message: () => this.isNot ? getMessage(this, this.utils.matcherHint(".not.toHaveClass", "element", ""), "Expected the element to have classes", "(none)", "Received", received.join(" ")) : [this.utils.matcherHint(`.toHaveClass`, "element"), "At least one expected class must be provided."].join("\n")
1356
- };
1357
- }
1358
- function getStyleDeclaration(document, css) {
1359
- const styles = {};
1360
- const copy = document.createElement("div");
1361
- Object.keys(css).forEach((property) => {
1362
- copy.style[property] = css[property];
1363
- styles[property] = copy.style[property];
1364
- });
1365
- return styles;
1366
- }
1367
- function isSubset(styles, computedStyle) {
1368
- return !!Object.keys(styles).length && Object.entries(styles).every(([prop, value]) => {
1369
- const isCustomProperty = prop.startsWith("--");
1370
- const spellingVariants = [prop];
1371
- if (!isCustomProperty) spellingVariants.push(prop.toLowerCase());
1372
- return spellingVariants.some((name) => computedStyle[name] === value || computedStyle.getPropertyValue(name) === value);
1373
- });
1374
- }
1375
- function printoutStyles(styles) {
1376
- return Object.keys(styles).sort().map((prop) => `${prop}: ${styles[prop]};`).join("\n");
1377
- }
1378
- function expectedDiff(diffFn, expected, computedStyles) {
1379
- const received = Array.from(computedStyles).filter((prop) => expected[prop] !== void 0).reduce((obj, prop) => Object.assign(obj, { [prop]: computedStyles.getPropertyValue(prop) }), {});
1380
- return diffFn(printoutStyles(expected), printoutStyles(received)).replace(`${import_picocolors_browser.default.red("+ Received")}\n`, "");
1381
- }
1382
- function toHaveStyle(htmlElement, css) {
1383
- checkHtmlElement(htmlElement, toHaveStyle, this);
1384
- const parsedCSS = typeof css === "object" ? css : parseCSS(css, toHaveStyle, this);
1385
- const { getComputedStyle } = htmlElement.ownerDocument.defaultView;
1386
- const expected = getStyleDeclaration(htmlElement.ownerDocument, parsedCSS);
1387
- const received = getComputedStyle(htmlElement);
1388
- return {
1389
- pass: isSubset(expected, received),
1390
- message: () => {
1391
- const matcher = `${this.isNot ? ".not" : ""}.toHaveStyle`;
1392
- return [this.utils.matcherHint(matcher, "element", ""), expectedDiff(this.utils.diff, expected, received)].join("\n\n");
1393
- }
1394
- };
1395
- }
1396
- function toHaveFocus(element) {
1397
- checkHtmlElement(element, toHaveFocus, this);
1398
- return {
1399
- pass: element.ownerDocument.activeElement === element,
1400
- message: () => {
1401
- return [
1402
- this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveFocus`, "element", ""),
1403
- "",
1404
- ...this.isNot ? ["Received element is focused:", ` ${this.utils.printReceived(element)}`] : [
1405
- "Expected element with focus:",
1406
- ` ${this.utils.printExpected(element)}`,
1407
- "Received element with focus:",
1408
- ` ${this.utils.printReceived(element.ownerDocument.activeElement)}`
1409
- ]
1410
- ].join("\n");
1411
- }
1412
- };
1413
- }
1414
- function getMultiElementValue(elements) {
1415
- const types = [...new Set(elements.map((element) => element.type))];
1416
- if (types.length !== 1) throw new Error("Multiple form elements with the same name must be of the same type");
1417
- switch (types[0]) {
1418
- case "radio": {
1419
- const theChosenOne = elements.find((radio) => radio.checked);
1420
- return theChosenOne ? theChosenOne.value : void 0;
1421
- }
1422
- case "checkbox": return elements.filter((checkbox) => checkbox.checked).map((checkbox) => checkbox.value);
1423
- default: return elements.map((element) => element.value);
1424
- }
1425
- }
1426
- function getFormValue(container, name) {
1427
- const elements = [...container.querySelectorAll(`[name="${(0, import_css_escape$1.default)(name)}"]`)];
1428
- /* istanbul ignore if */
1429
- if (elements.length === 0) return;
1430
- switch (elements.length) {
1431
- case 1: return getSingleElementValue(elements[0]);
1432
- default: return getMultiElementValue(elements);
1433
- }
1434
- }
1435
- function getPureName(name) {
1436
- return /\[\]$/.test(name) ? name.slice(0, -2) : name;
1437
- }
1438
- function getAllFormValues(container) {
1439
- return Array.from(container.elements).map((element) => element.name).reduce((obj, name) => ({
1440
- ...obj,
1441
- [getPureName(name)]: getFormValue(container, name)
1442
- }), {});
1443
- }
1444
- function toHaveFormValues(formElement, expectedValues) {
1445
- checkHtmlElement(formElement, toHaveFormValues, this);
1446
- if (!formElement.elements) throw new Error("toHaveFormValues must be called on a form or a fieldset");
1447
- const formValues = getAllFormValues(formElement);
1448
- return {
1449
- pass: Object.entries(expectedValues).every(([name, expectedValue]) => compareAsSet(formValues[name], expectedValue)),
1450
- message: () => {
1451
- const to = this.isNot ? "not to" : "to";
1452
- const matcher = `${this.isNot ? ".not" : ""}.toHaveFormValues`;
1453
- const commonKeyValues = Object.keys(formValues).filter((key) => expectedValues.hasOwnProperty(key)).reduce((obj, key) => ({
1454
- ...obj,
1455
- [key]: formValues[key]
1456
- }), {});
1457
- return [
1458
- this.utils.matcherHint(matcher, "element", ""),
1459
- `Expected the element ${to} have form values`,
1460
- this.utils.diff(expectedValues, commonKeyValues)
1461
- ].join("\n\n");
1462
- }
1463
- };
1464
- }
1465
- function isStyleVisible(element) {
1466
- const { getComputedStyle } = element.ownerDocument.defaultView;
1467
- const { display, visibility, opacity } = getComputedStyle(element);
1468
- return display !== "none" && visibility !== "hidden" && visibility !== "collapse" && opacity !== "0" && opacity !== 0;
1469
- }
1470
- function isAttributeVisible(element, previousElement) {
1471
- let detailsVisibility;
1472
- if (previousElement) detailsVisibility = element.nodeName === "DETAILS" && previousElement.nodeName !== "SUMMARY" ? element.hasAttribute("open") : true;
1473
- else detailsVisibility = element.nodeName === "DETAILS" ? element.hasAttribute("open") : true;
1474
- return !element.hasAttribute("hidden") && detailsVisibility;
1475
- }
1476
- function isElementVisible(element, previousElement) {
1477
- return isStyleVisible(element) && isAttributeVisible(element, previousElement) && (!element.parentElement || isElementVisible(element.parentElement, element));
1478
- }
1479
- function toBeVisible(element) {
1480
- checkHtmlElement(element, toBeVisible, this);
1481
- const isInDocument = element.ownerDocument === element.getRootNode({ composed: true });
1482
- const isVisible = isInDocument && isElementVisible(element);
1483
- return {
1484
- pass: isVisible,
1485
- message: () => {
1486
- const is = isVisible ? "is" : "is not";
1487
- return [
1488
- this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeVisible`, "element", ""),
1489
- "",
1490
- `Received element ${is} visible${isInDocument ? "" : " (element is not in the document)"}:`,
1491
- ` ${this.utils.printReceived(element.cloneNode(false))}`
1492
- ].join("\n");
1493
- }
1494
- };
1495
- }
1496
- function isFirstLegendChildOfFieldset(element, parent) {
1497
- return getTag(element) === "legend" && getTag(parent) === "fieldset" && element.isSameNode(Array.from(parent.children).find((child) => getTag(child) === "legend"));
1498
- }
1499
- function isElementDisabledByParent(element, parent) {
1500
- return isElementDisabled(parent) && !isFirstLegendChildOfFieldset(element, parent);
1501
- }
1502
- function isCustomElement(tag) {
1503
- return tag.includes("-");
1504
- }
1505
- function canElementBeDisabled(element) {
1506
- const tag = getTag(element);
1507
- return FORM_TAGS$2.includes(tag) || isCustomElement(tag);
1508
- }
1509
- function isElementDisabled(element) {
1510
- return canElementBeDisabled(element) && element.hasAttribute("disabled");
1511
- }
1512
- function isAncestorDisabled(element) {
1513
- const parent = element.parentElement;
1514
- return Boolean(parent) && (isElementDisabledByParent(element, parent) || isAncestorDisabled(parent));
1515
- }
1516
- function isElementOrAncestorDisabled(element) {
1517
- return canElementBeDisabled(element) && (isElementDisabled(element) || isAncestorDisabled(element));
1518
- }
1519
- function toBeDisabled(element) {
1520
- checkHtmlElement(element, toBeDisabled, this);
1521
- const isDisabled = isElementOrAncestorDisabled(element);
1522
- return {
1523
- pass: isDisabled,
1524
- message: () => {
1525
- const is = isDisabled ? "is" : "is not";
1526
- return [
1527
- this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeDisabled`, "element", ""),
1528
- "",
1529
- `Received element ${is} disabled:`,
1530
- ` ${this.utils.printReceived(element.cloneNode(false))}`
1531
- ].join("\n");
1532
- }
1533
- };
1534
- }
1535
- function toBeEnabled(element) {
1536
- checkHtmlElement(element, toBeEnabled, this);
1537
- const isEnabled = !isElementOrAncestorDisabled(element);
1538
- return {
1539
- pass: isEnabled,
1540
- message: () => {
1541
- const is = isEnabled ? "is" : "is not";
1542
- return [
1543
- this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeEnabled`, "element", ""),
1544
- "",
1545
- `Received element ${is} enabled:`,
1546
- ` ${this.utils.printReceived(element.cloneNode(false))}`
1547
- ].join("\n");
1548
- }
1549
- };
1550
- }
1551
- function isRequiredOnFormTagsExceptInput(element) {
1552
- return FORM_TAGS$1.includes(getTag(element)) && element.hasAttribute("required");
1553
- }
1554
- function isRequiredOnSupportedInput(element) {
1555
- return getTag(element) === "input" && element.hasAttribute("required") && (element.hasAttribute("type") && !UNSUPPORTED_INPUT_TYPES.includes(element.getAttribute("type")) || !element.hasAttribute("type"));
1556
- }
1557
- function isElementRequiredByARIA(element) {
1558
- return element.hasAttribute("aria-required") && element.getAttribute("aria-required") === "true" && (ARIA_FORM_TAGS.includes(getTag(element)) || element.hasAttribute("role") && SUPPORTED_ARIA_ROLES.includes(element.getAttribute("role")));
1559
- }
1560
- function toBeRequired(element) {
1561
- checkHtmlElement(element, toBeRequired, this);
1562
- const isRequired = isRequiredOnFormTagsExceptInput(element) || isRequiredOnSupportedInput(element) || isElementRequiredByARIA(element);
1563
- return {
1564
- pass: isRequired,
1565
- message: () => {
1566
- const is = isRequired ? "is" : "is not";
1567
- return [
1568
- this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeRequired`, "element", ""),
1569
- "",
1570
- `Received element ${is} required:`,
1571
- ` ${this.utils.printReceived(element.cloneNode(false))}`
1572
- ].join("\n");
1573
- }
1574
- };
1575
- }
1576
- function isElementHavingAriaInvalid(element) {
1577
- return element.hasAttribute("aria-invalid") && element.getAttribute("aria-invalid") !== "false";
1578
- }
1579
- function isSupportsValidityMethod(element) {
1580
- return FORM_TAGS.includes(getTag(element));
1581
- }
1582
- function isElementInvalid(element) {
1583
- const isHaveAriaInvalid = isElementHavingAriaInvalid(element);
1584
- if (isSupportsValidityMethod(element)) return isHaveAriaInvalid || !element.checkValidity();
1585
- else return isHaveAriaInvalid;
1586
- }
1587
- function toBeInvalid(element) {
1588
- checkHtmlElement(element, toBeInvalid, this);
1589
- const isInvalid = isElementInvalid(element);
1590
- return {
1591
- pass: isInvalid,
1592
- message: () => {
1593
- const is = isInvalid ? "is" : "is not";
1594
- return [
1595
- this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeInvalid`, "element", ""),
1596
- "",
1597
- `Received element ${is} currently invalid:`,
1598
- ` ${this.utils.printReceived(element.cloneNode(false))}`
1599
- ].join("\n");
1600
- }
1601
- };
1602
- }
1603
- function toBeValid(element) {
1604
- checkHtmlElement(element, toBeValid, this);
1605
- const isValid = !isElementInvalid(element);
1606
- return {
1607
- pass: isValid,
1608
- message: () => {
1609
- const is = isValid ? "is" : "is not";
1610
- return [
1611
- this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeValid`, "element", ""),
1612
- "",
1613
- `Received element ${is} currently valid:`,
1614
- ` ${this.utils.printReceived(element.cloneNode(false))}`
1615
- ].join("\n");
1616
- }
1617
- };
1618
- }
1619
- function toHaveValue(htmlElement, expectedValue) {
1620
- checkHtmlElement(htmlElement, toHaveValue, this);
1621
- if (htmlElement.tagName.toLowerCase() === "input" && ["checkbox", "radio"].includes(htmlElement.type)) throw new Error("input with type=checkbox or type=radio cannot be used with .toHaveValue(). Use .toBeChecked() for type=checkbox or .toHaveFormValues() instead");
1622
- const receivedValue = getSingleElementValue(htmlElement);
1623
- const expectsValue = expectedValue !== void 0;
1624
- let expectedTypedValue = expectedValue;
1625
- let receivedTypedValue = receivedValue;
1626
- if (expectedValue == receivedValue && expectedValue !== receivedValue) {
1627
- expectedTypedValue = `${expectedValue} (${typeof expectedValue})`;
1628
- receivedTypedValue = `${receivedValue} (${typeof receivedValue})`;
1629
- }
1630
- return {
1631
- pass: expectsValue ? compareAsSet(receivedValue, expectedValue) : Boolean(receivedValue),
1632
- message: () => {
1633
- const to = this.isNot ? "not to" : "to";
1634
- const matcher = this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveValue`, "element", expectedValue);
1635
- return getMessage(this, matcher, `Expected the element ${to} have value`, expectsValue ? expectedTypedValue : "(any)", "Received", receivedTypedValue);
1636
- }
1637
- };
1638
- }
1639
- function toHaveDisplayValue(htmlElement, expectedValue) {
1640
- checkHtmlElement(htmlElement, toHaveDisplayValue, this);
1641
- const tagName = htmlElement.tagName.toLowerCase();
1642
- if (![
1643
- "select",
1644
- "input",
1645
- "textarea"
1646
- ].includes(tagName)) throw new Error(".toHaveDisplayValue() currently supports only input, textarea or select elements, try with another matcher instead.");
1647
- if (tagName === "input" && ["radio", "checkbox"].includes(htmlElement.type)) throw new Error(`.toHaveDisplayValue() currently does not support input[type="${htmlElement.type}"], try with another matcher instead.`);
1648
- const values = getValues(tagName, htmlElement);
1649
- const expectedValues = getExpectedValues(expectedValue);
1650
- const numberOfMatchesWithValues = expectedValues.filter((expected) => values.some((value) => expected instanceof RegExp ? expected.test(value) : this.equals(value, String(expected)))).length;
1651
- const matchedWithAllValues = numberOfMatchesWithValues === values.length;
1652
- const matchedWithAllExpectedValues = numberOfMatchesWithValues === expectedValues.length;
1653
- return {
1654
- pass: matchedWithAllValues && matchedWithAllExpectedValues,
1655
- message: () => getMessage(this, this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveDisplayValue`, "element", ""), `Expected element ${this.isNot ? "not " : ""}to have display value`, expectedValue, "Received", values)
1656
- };
1657
- }
1658
- function getValues(tagName, htmlElement) {
1659
- return tagName === "select" ? Array.from(htmlElement).filter((option) => option.selected).map((option) => option.textContent) : [htmlElement.value];
1660
- }
1661
- function getExpectedValues(expectedValue) {
1662
- return expectedValue instanceof Array ? expectedValue : [expectedValue];
1663
- }
1664
- function toBeChecked(element) {
1665
- checkHtmlElement(element, toBeChecked, this);
1666
- const isValidInput = () => {
1667
- return element.tagName.toLowerCase() === "input" && ["checkbox", "radio"].includes(element.type);
1668
- };
1669
- const isValidAriaElement = () => {
1670
- return roleSupportsChecked(element.getAttribute("role")) && ["true", "false"].includes(element.getAttribute("aria-checked"));
1671
- };
1672
- if (!isValidInput() && !isValidAriaElement()) return {
1673
- pass: false,
1674
- message: () => `only inputs with type="checkbox" or type="radio" or elements with ${supportedRolesSentence()} and a valid aria-checked attribute can be used with .toBeChecked(). Use .toHaveValue() instead`
1675
- };
1676
- const isChecked = () => {
1677
- if (isValidInput()) return element.checked;
1678
- return element.getAttribute("aria-checked") === "true";
1679
- };
1680
- return {
1681
- pass: isChecked(),
1682
- message: () => {
1683
- const is = isChecked() ? "is" : "is not";
1684
- return [
1685
- this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBeChecked`, "element", ""),
1686
- "",
1687
- `Received element ${is} checked:`,
1688
- ` ${this.utils.printReceived(element.cloneNode(false))}`
1689
- ].join("\n");
1690
- }
1691
- };
1692
- }
1693
- function supportedRolesSentence() {
1694
- return toSentence(supportedRoles().map((role) => `role="${role}"`), { lastWordConnector: " or " });
1695
- }
1696
- function supportedRoles() {
1697
- return import_lib$1.roles.keys().filter(roleSupportsChecked);
1698
- }
1699
- function roleSupportsChecked(role) {
1700
- return import_lib$1.roles.get(role)?.props["aria-checked"] !== void 0;
1701
- }
1702
- function toBePartiallyChecked(element) {
1703
- checkHtmlElement(element, toBePartiallyChecked, this);
1704
- const isValidInput = () => {
1705
- return element.tagName.toLowerCase() === "input" && element.type === "checkbox";
1706
- };
1707
- const isValidAriaElement = () => {
1708
- return element.getAttribute("role") === "checkbox";
1709
- };
1710
- if (!isValidInput() && !isValidAriaElement()) return {
1711
- pass: false,
1712
- message: () => "only inputs with type=\"checkbox\" or elements with role=\"checkbox\" and a valid aria-checked attribute can be used with .toBePartiallyChecked(). Use .toHaveValue() instead"
1713
- };
1714
- const isPartiallyChecked = () => {
1715
- const isAriaMixed = element.getAttribute("aria-checked") === "mixed";
1716
- if (isValidInput()) return element.indeterminate || isAriaMixed;
1717
- return isAriaMixed;
1718
- };
1719
- return {
1720
- pass: isPartiallyChecked(),
1721
- message: () => {
1722
- const is = isPartiallyChecked() ? "is" : "is not";
1723
- return [
1724
- this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBePartiallyChecked`, "element", ""),
1725
- "",
1726
- `Received element ${is} partially checked:`,
1727
- ` ${this.utils.printReceived(element.cloneNode(false))}`
1728
- ].join("\n");
1729
- }
1730
- };
1731
- }
1732
- function toHaveDescription(htmlElement, checkWith) {
1733
- deprecate("toHaveDescription", "Please use toHaveAccessibleDescription.");
1734
- checkHtmlElement(htmlElement, toHaveDescription, this);
1735
- const expectsDescription = checkWith !== void 0;
1736
- const descriptionIDs = (htmlElement.getAttribute("aria-describedby") || "").split(/\s+/).filter(Boolean);
1737
- let description = "";
1738
- if (descriptionIDs.length > 0) {
1739
- const document = htmlElement.ownerDocument;
1740
- description = normalize$1(descriptionIDs.map((descriptionID) => document.getElementById(descriptionID)).filter(Boolean).map((el) => el.textContent).join(" "));
1741
- }
1742
- return {
1743
- pass: expectsDescription ? checkWith instanceof RegExp ? checkWith.test(description) : this.equals(description, checkWith) : Boolean(description),
1744
- message: () => {
1745
- const to = this.isNot ? "not to" : "to";
1746
- return getMessage(this, this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveDescription`, "element", ""), `Expected the element ${to} have description`, this.utils.printExpected(checkWith), "Received", this.utils.printReceived(description));
1747
- }
1748
- };
1749
- }
1750
- function toHaveErrorMessage(htmlElement, checkWith) {
1751
- deprecate("toHaveErrorMessage", "Please use toHaveAccessibleErrorMessage.");
1752
- checkHtmlElement(htmlElement, toHaveErrorMessage, this);
1753
- if (!htmlElement.hasAttribute("aria-invalid") || htmlElement.getAttribute("aria-invalid") === "false") {
1754
- const not = this.isNot ? ".not" : "";
1755
- return {
1756
- pass: false,
1757
- message: () => {
1758
- return getMessage(this, this.utils.matcherHint(`${not}.toHaveErrorMessage`, "element", ""), `Expected the element to have invalid state indicated by`, "aria-invalid=\"true\"", "Received", htmlElement.hasAttribute("aria-invalid") ? `aria-invalid="${htmlElement.getAttribute("aria-invalid")}"` : this.utils.printReceived(""));
1759
- }
1760
- };
1761
- }
1762
- const expectsErrorMessage = checkWith !== void 0;
1763
- const errormessageIDs = (htmlElement.getAttribute("aria-errormessage") || "").split(/\s+/).filter(Boolean);
1764
- let errormessage = "";
1765
- if (errormessageIDs.length > 0) {
1766
- const document = htmlElement.ownerDocument;
1767
- errormessage = normalize$1(errormessageIDs.map((errormessageID) => document.getElementById(errormessageID)).filter(Boolean).map((el) => el.textContent).join(" "));
1768
- }
1769
- return {
1770
- pass: expectsErrorMessage ? checkWith instanceof RegExp ? checkWith.test(errormessage) : this.equals(errormessage, checkWith) : Boolean(errormessage),
1771
- message: () => {
1772
- const to = this.isNot ? "not to" : "to";
1773
- return getMessage(this, this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveErrorMessage`, "element", ""), `Expected the element ${to} have error message`, this.utils.printExpected(checkWith), "Received", this.utils.printReceived(errormessage));
1774
- }
1775
- };
1776
- }
1777
- /**
1778
- * Returns the selection from the element.
1779
- *
1780
- * @param element {HTMLElement} The element to get the selection from.
1781
- * @returns {String} The selection.
1782
- */
1783
- function getSelection(element) {
1784
- const selection = element.ownerDocument.getSelection();
1785
- if (["input", "textarea"].includes(element.tagName.toLowerCase())) {
1786
- if (["radio", "checkbox"].includes(element.type)) return "";
1787
- return element.value.toString().substring(element.selectionStart, element.selectionEnd);
1788
- }
1789
- if (selection.anchorNode === null || selection.focusNode === null) return "";
1790
- const originalRange = selection.getRangeAt(0);
1791
- const temporaryRange = element.ownerDocument.createRange();
1792
- if (selection.containsNode(element, false)) {
1793
- temporaryRange.selectNodeContents(element);
1794
- selection.removeAllRanges();
1795
- selection.addRange(temporaryRange);
1796
- } else if (element.contains(selection.anchorNode) && element.contains(selection.focusNode));
1797
- else {
1798
- const selectionStartsWithinElement = element === originalRange.startContainer || element.contains(originalRange.startContainer);
1799
- const selectionEndsWithinElement = element === originalRange.endContainer || element.contains(originalRange.endContainer);
1800
- selection.removeAllRanges();
1801
- if (selectionStartsWithinElement || selectionEndsWithinElement) {
1802
- temporaryRange.selectNodeContents(element);
1803
- if (selectionStartsWithinElement) temporaryRange.setStart(originalRange.startContainer, originalRange.startOffset);
1804
- if (selectionEndsWithinElement) temporaryRange.setEnd(originalRange.endContainer, originalRange.endOffset);
1805
- selection.addRange(temporaryRange);
1806
- }
1807
- }
1808
- const result = selection.toString();
1809
- selection.removeAllRanges();
1810
- selection.addRange(originalRange);
1811
- return result;
1812
- }
1813
- /**
1814
- * Checks if the element has the string selected.
1815
- *
1816
- * @param htmlElement {HTMLElement} The html element to check the selection for.
1817
- * @param expectedSelection {String} The selection as a string.
1818
- */
1819
- function toHaveSelection(htmlElement, expectedSelection) {
1820
- checkHtmlElement(htmlElement, toHaveSelection, this);
1821
- const expectsSelection = expectedSelection !== void 0;
1822
- if (expectsSelection && typeof expectedSelection !== "string") throw new Error(`expected selection must be a string or undefined`);
1823
- const receivedSelection = getSelection(htmlElement);
1824
- return {
1825
- pass: expectsSelection ? compareAsSet(receivedSelection, expectedSelection) : Boolean(receivedSelection),
1826
- message: () => {
1827
- const to = this.isNot ? "not to" : "to";
1828
- const matcher = this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toHaveSelection`, "element", expectedSelection);
1829
- return getMessage(this, matcher, `Expected the element ${to} have selection`, expectsSelection ? expectedSelection : "(any)", "Received", receivedSelection);
1830
- }
1831
- };
1832
- }
1833
- function toBePressed(element) {
1834
- checkHtmlElement(element, toBePressed, this);
1835
- const roles = (element.getAttribute("role") || "").split(" ").map((role) => role.trim());
1836
- const isButton = element.tagName.toLowerCase() === "button" || element.tagName.toLowerCase() === "input" && element.type === "button" || roles.includes("button");
1837
- const pressedAttribute = element.getAttribute("aria-pressed");
1838
- if (!isButton || !(pressedAttribute === "true" || pressedAttribute === "false")) return {
1839
- pass: false,
1840
- message: () => `Only button or input with type="button" or element with role="button" and a valid aria-pressed attribute can be used with .toBePressed()`
1841
- };
1842
- return {
1843
- pass: isButton && pressedAttribute === "true",
1844
- message: () => {
1845
- const matcher = this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBePressed`, "element", "");
1846
- return getMessage(this, matcher, `Expected element to have`, `aria-pressed="${this.isNot ? "false" : "true"}"`, `Received`, `aria-pressed="${pressedAttribute}"`);
1847
- }
1848
- };
1849
- }
1850
- function toBePartiallyPressed(element) {
1851
- checkHtmlElement(element, toBePartiallyPressed, this);
1852
- const roles = (element.getAttribute("role") || "").split(" ").map((role) => role.trim());
1853
- const isButton = element.tagName.toLowerCase() === "button" || element.tagName.toLowerCase() === "input" && element.type === "button" || roles.includes("button");
1854
- const pressedAttribute = element.getAttribute("aria-pressed");
1855
- if (!isButton || !(pressedAttribute === "true" || pressedAttribute === "false" || pressedAttribute === "mixed")) return {
1856
- pass: false,
1857
- message: () => `Only button or input with type="button" or element with role="button" and a valid aria-pressed attribute can be used with .toBePartiallyPressed()`
1858
- };
1859
- return {
1860
- pass: isButton && pressedAttribute === "mixed",
1861
- message: () => {
1862
- const to = this.isNot ? "not to" : "to";
1863
- const matcher = this.utils.matcherHint(`${this.isNot ? ".not" : ""}.toBePartiallyPressed`, "element", "");
1864
- return getMessage(this, matcher, `Expected element ${to} have`, `aria-pressed="mixed"`, `Received`, `aria-pressed="${pressedAttribute}"`);
1865
- }
1866
- };
1867
- }
1868
- function makeDocumentPositionErrorString(documentPosition) {
1869
- if (documentPosition in DOCUMENT_POSITIONS_STRINGS) return `${DOCUMENT_POSITIONS_STRINGS[documentPosition]} (${documentPosition})`;
1870
- return `Unknown document position (${documentPosition})`;
1871
- }
1872
- function checkToAppear(methodName, targetDocumentPosition) {
1873
- return function(element, secondElement) {
1874
- checkHtmlElement(element, toAppearBefore, this);
1875
- checkHtmlElement(secondElement, toAppearBefore, this);
1876
- const documentPosition = element.compareDocumentPosition(secondElement);
1877
- return {
1878
- pass: documentPosition === targetDocumentPosition,
1879
- message: () => {
1880
- return [
1881
- this.utils.matcherHint(`${this.isNot ? ".not" : ""}.${methodName}`, "element", "secondElement"),
1882
- "",
1883
- `Received: ${makeDocumentPositionErrorString(documentPosition)}`
1884
- ].join("\n");
1885
- }
1886
- };
1887
- };
1888
- }
1889
- function toAppearBefore(element, secondElement) {
1890
- return checkToAppear("toAppearBefore", DOCUMENT_POSITION_FOLLOWING).apply(this, [element, secondElement]);
1891
- }
1892
- function toAppearAfter(element, secondElement) {
1893
- return checkToAppear("toAppearAfter", DOCUMENT_POSITION_PRECEDING).apply(this, [element, secondElement]);
1894
- }
1895
- var import_redent$1, import_lib$1, import_picocolors_browser, import_css_escape$1, GenericTypeError, HtmlElementTypeError, NodeTypeError, InvalidCSSError, rolesSupportingValues, ariaInvalidName, validStates, elementRoleList, FORM_TAGS$2, FORM_TAGS$1, ARIA_FORM_TAGS, UNSUPPORTED_INPUT_TYPES, SUPPORTED_ARIA_ROLES, FORM_TAGS, DOCUMENT_POSITION_DISCONNECTED, DOCUMENT_POSITION_PRECEDING, DOCUMENT_POSITION_FOLLOWING, DOCUMENT_POSITION_CONTAINS, DOCUMENT_POSITION_CONTAINED_BY, DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC, DOCUMENT_POSITIONS_STRINGS;
1896
- function init_matchers_35e4d3bd() {
1897
- return (init_matchers_35e4d3bd = __esmMin((() => {
1898
- import_redent$1 = /* @__PURE__ */ __toESM(require_redent(), 1);
1899
- init_adobe_css_tools();
1900
- init_dist();
1901
- import_lib$1 = require_lib();
1902
- import_picocolors_browser = /* @__PURE__ */ __toESM(require_picocolors_browser(), 1);
1903
- import_css_escape$1 = /* @__PURE__ */ __toESM(require_css_escape(), 1);
1904
- GenericTypeError = class extends Error {
1905
- constructor(expectedString, received, matcherFn, context) {
1906
- super();
1907
- /* istanbul ignore next */
1908
- if (Error.captureStackTrace) Error.captureStackTrace(this, matcherFn);
1909
- let withType = "";
1910
- try {
1911
- withType = context.utils.printWithType("Received", received, context.utils.printReceived);
1912
- } catch (e) {}
1913
- this.message = [
1914
- context.utils.matcherHint(`${context.isNot ? ".not" : ""}.${matcherFn.name}`, "received", ""),
1915
- "",
1916
- `${context.utils.RECEIVED_COLOR("received")} value must ${expectedString}.`,
1917
- withType
1918
- ].join("\n");
1919
- }
1920
- };
1921
- HtmlElementTypeError = class extends GenericTypeError {
1922
- constructor(...args) {
1923
- super("be an HTMLElement or an SVGElement", ...args);
1924
- }
1925
- };
1926
- NodeTypeError = class extends GenericTypeError {
1927
- constructor(...args) {
1928
- super("be a Node", ...args);
1929
- }
1930
- };
1931
- InvalidCSSError = class extends Error {
1932
- constructor(received, matcherFn, context) {
1933
- super();
1934
- /* istanbul ignore next */
1935
- if (Error.captureStackTrace) Error.captureStackTrace(this, matcherFn);
1936
- this.message = [
1937
- received.message,
1938
- "",
1939
- context.utils.RECEIVED_COLOR(`Failing css:`),
1940
- context.utils.RECEIVED_COLOR(`${received.css}`)
1941
- ].join("\n");
1942
- }
1943
- };
1944
- rolesSupportingValues = [
1945
- "meter",
1946
- "progressbar",
1947
- "slider",
1948
- "spinbutton"
1949
- ];
1950
- ariaInvalidName = "aria-invalid";
1951
- validStates = ["false"];
1952
- elementRoleList = buildElementRoleList(import_lib$1.elementRoles);
1953
- FORM_TAGS$2 = [
1954
- "fieldset",
1955
- "input",
1956
- "select",
1957
- "optgroup",
1958
- "option",
1959
- "button",
1960
- "textarea"
1961
- ];
1962
- FORM_TAGS$1 = ["select", "textarea"];
1963
- ARIA_FORM_TAGS = [
1964
- "input",
1965
- "select",
1966
- "textarea"
1967
- ];
1968
- UNSUPPORTED_INPUT_TYPES = [
1969
- "color",
1970
- "hidden",
1971
- "range",
1972
- "submit",
1973
- "image",
1974
- "reset"
1975
- ];
1976
- SUPPORTED_ARIA_ROLES = [
1977
- "checkbox",
1978
- "combobox",
1979
- "gridcell",
1980
- "listbox",
1981
- "radiogroup",
1982
- "spinbutton",
1983
- "textbox",
1984
- "tree"
1985
- ];
1986
- FORM_TAGS = [
1987
- "form",
1988
- "input",
1989
- "select",
1990
- "textarea"
1991
- ];
1992
- DOCUMENT_POSITION_DISCONNECTED = 1;
1993
- DOCUMENT_POSITION_PRECEDING = 2;
1994
- DOCUMENT_POSITION_FOLLOWING = 4;
1995
- DOCUMENT_POSITION_CONTAINS = 8;
1996
- DOCUMENT_POSITION_CONTAINED_BY = 16;
1997
- DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC = 32;
1998
- DOCUMENT_POSITIONS_STRINGS = {
1999
- [DOCUMENT_POSITION_DISCONNECTED]: "Node.DOCUMENT_POSITION_DISCONNECTED",
2000
- [DOCUMENT_POSITION_PRECEDING]: "Node.DOCUMENT_POSITION_PRECEDING",
2001
- [DOCUMENT_POSITION_FOLLOWING]: "Node.DOCUMENT_POSITION_FOLLOWING",
2002
- [DOCUMENT_POSITION_CONTAINS]: "Node.DOCUMENT_POSITION_CONTAINS",
2003
- [DOCUMENT_POSITION_CONTAINED_BY]: "Node.DOCUMENT_POSITION_CONTAINED_BY",
2004
- [DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC]: "Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC"
2005
- };
2006
- })))();
2007
- }
2008
- //#endregion
2009
- //#region ../../node_modules/@testing-library/jest-dom/dist/matchers.mjs
2010
- var matchers_exports = /* @__PURE__ */ __exportAll({
2011
- toAppearAfter: () => toAppearAfter,
2012
- toAppearBefore: () => toAppearBefore,
2013
- toBeChecked: () => toBeChecked,
2014
- toBeDisabled: () => toBeDisabled,
2015
- toBeEmpty: () => toBeEmpty,
2016
- toBeEmptyDOMElement: () => toBeEmptyDOMElement,
2017
- toBeEnabled: () => toBeEnabled,
2018
- toBeInTheDOM: () => toBeInTheDOM,
2019
- toBeInTheDocument: () => toBeInTheDocument,
2020
- toBeInvalid: () => toBeInvalid,
2021
- toBePartiallyChecked: () => toBePartiallyChecked,
2022
- toBePartiallyPressed: () => toBePartiallyPressed,
2023
- toBePressed: () => toBePressed,
2024
- toBeRequired: () => toBeRequired,
2025
- toBeValid: () => toBeValid,
2026
- toBeVisible: () => toBeVisible,
2027
- toContainElement: () => toContainElement,
2028
- toContainHTML: () => toContainHTML,
2029
- toHaveAccessibleDescription: () => toHaveAccessibleDescription,
2030
- toHaveAccessibleErrorMessage: () => toHaveAccessibleErrorMessage,
2031
- toHaveAccessibleName: () => toHaveAccessibleName,
2032
- toHaveAttribute: () => toHaveAttribute,
2033
- toHaveClass: () => toHaveClass,
2034
- toHaveDescription: () => toHaveDescription,
2035
- toHaveDisplayValue: () => toHaveDisplayValue,
2036
- toHaveErrorMessage: () => toHaveErrorMessage,
2037
- toHaveFocus: () => toHaveFocus,
2038
- toHaveFormValues: () => toHaveFormValues,
2039
- toHaveRole: () => toHaveRole,
2040
- toHaveSelection: () => toHaveSelection,
2041
- toHaveStyle: () => toHaveStyle,
2042
- toHaveTextContent: () => toHaveTextContent,
2043
- toHaveValue: () => toHaveValue
2044
- });
2045
- function init_matchers() {
2046
- return (init_matchers = __esmMin((() => {
2047
- init_matchers_35e4d3bd();
2048
- require_redent();
2049
- init_dist();
2050
- require_lib();
2051
- require_css_escape();
2052
- })))();
2053
- }
2054
- //#endregion
2055
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/misc/isElementType.js
1
+ import { n as __esmMin, r as __exportAll } from "./runtime-BdGkqNEt.js";
2
+ import { l as getConfig, u as init_dom_esm } from "./runtime-Bcv1hJky.js";
3
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/misc/isElementType.js
2056
4
  function isElementType(element, tag, props) {
2057
5
  if (element.namespaceURI && element.namespaceURI !== "http://www.w3.org/1999/xhtml") return false;
2058
6
  tag = Array.isArray(tag) ? tag : [tag];
@@ -2061,7 +9,7 @@ function isElementType(element, tag, props) {
2061
9
  return true;
2062
10
  }
2063
11
  //#endregion
2064
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/misc/getWindow.js
12
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/misc/getWindow.js
2065
13
  function getWindow(node) {
2066
14
  var _node_ownerDocument;
2067
15
  if (isDocument$1(node) && node.defaultView) return node.defaultView;
@@ -2075,7 +23,7 @@ function describe(val) {
2075
23
  return typeof val === "function" ? `function ${val.name}` : val === null ? "null" : String(val);
2076
24
  }
2077
25
  //#endregion
2078
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/dataTransfer/Blob.js
26
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/dataTransfer/Blob.js
2079
27
  function readBlobText(blob, FileReader) {
2080
28
  return new Promise((res, rej) => {
2081
29
  const fr = new FileReader();
@@ -2088,7 +36,7 @@ function readBlobText(blob, FileReader) {
2088
36
  });
2089
37
  }
2090
38
  //#endregion
2091
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/dataTransfer/FileList.js
39
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/dataTransfer/FileList.js
2092
40
  function createFileList(window, files) {
2093
41
  const list = {
2094
42
  ...files,
@@ -2104,7 +52,7 @@ function createFileList(window, files) {
2104
52
  return list;
2105
53
  }
2106
54
  //#endregion
2107
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/dataTransfer/DataTransfer.js
55
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/dataTransfer/DataTransfer.js
2108
56
  function _define_property$8(obj, key, value) {
2109
57
  if (key in obj) Object.defineProperty(obj, key, {
2110
58
  value,
@@ -2215,7 +163,7 @@ function init_DataTransfer() {
2215
163
  })))();
2216
164
  }
2217
165
  //#endregion
2218
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/dataTransfer/Clipboard.js
166
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/dataTransfer/Clipboard.js
2219
167
  function _define_property$7(obj, key, value) {
2220
168
  if (key in obj) Object.defineProperty(obj, key, {
2221
169
  value,
@@ -2339,7 +287,7 @@ function init_Clipboard() {
2339
287
  })))();
2340
288
  }
2341
289
  //#endregion
2342
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/focus/selector.js
290
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/focus/selector.js
2343
291
  var FOCUSABLE_SELECTOR;
2344
292
  function init_selector() {
2345
293
  return (init_selector = __esmMin((() => {
@@ -2357,7 +305,7 @@ function init_selector() {
2357
305
  })))();
2358
306
  }
2359
307
  //#endregion
2360
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/focus/isFocusable.js
308
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/focus/isFocusable.js
2361
309
  function isFocusable(element) {
2362
310
  return element.matches(FOCUSABLE_SELECTOR);
2363
311
  }
@@ -2367,12 +315,12 @@ function init_isFocusable() {
2367
315
  })))();
2368
316
  }
2369
317
  //#endregion
2370
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/misc/cloneEvent.js
318
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/misc/cloneEvent.js
2371
319
  function cloneEvent(event) {
2372
320
  return new event.constructor(event.type, event);
2373
321
  }
2374
322
  //#endregion
2375
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/misc/isDisabled.js
323
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/misc/isDisabled.js
2376
324
  function isDisabled(element) {
2377
325
  for (let el = element; el; el = el.parentElement) if (isElementType(el, [
2378
326
  "button",
@@ -2395,7 +343,7 @@ function init_isDisabled() {
2395
343
  return (init_isDisabled = __esmMin((() => {})))();
2396
344
  }
2397
345
  //#endregion
2398
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/focus/getActiveElement.js
346
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/focus/getActiveElement.js
2399
347
  function getActiveElement(document) {
2400
348
  const activeElement = document.activeElement;
2401
349
  if (activeElement === null || activeElement === void 0 ? void 0 : activeElement.shadowRoot) {
@@ -2415,7 +363,7 @@ function init_getActiveElement() {
2415
363
  })))();
2416
364
  }
2417
365
  //#endregion
2418
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/misc/findClosest.js
366
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/misc/findClosest.js
2419
367
  function findClosest(element, callback) {
2420
368
  let el = element;
2421
369
  do {
@@ -2424,7 +372,7 @@ function findClosest(element, callback) {
2424
372
  } while (el && el !== element.ownerDocument.body);
2425
373
  }
2426
374
  //#endregion
2427
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/edit/isContentEditable.js
375
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/edit/isContentEditable.js
2428
376
  function isContentEditable(element) {
2429
377
  return element.hasAttribute("contenteditable") && (element.getAttribute("contenteditable") == "true" || element.getAttribute("contenteditable") == "");
2430
378
  }
@@ -2438,7 +386,7 @@ function getElement$1(node) {
2438
386
  return node.nodeType === 1 ? node : node.parentElement;
2439
387
  }
2440
388
  //#endregion
2441
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/click/isClickableInput.js
389
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/click/isClickableInput.js
2442
390
  function isClickableInput(element) {
2443
391
  return isElementType(element, "button") || isElementType(element, "input") && element.type in clickableInputTypes;
2444
392
  }
@@ -2459,7 +407,7 @@ function init_isClickableInput() {
2459
407
  })))();
2460
408
  }
2461
409
  //#endregion
2462
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/edit/isEditable.js
410
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/edit/isEditable.js
2463
411
  function isEditable(element) {
2464
412
  return isEditableInputOrTextArea(element) && !element.readOnly || isContentEditable(element);
2465
413
  }
@@ -2487,7 +435,7 @@ function init_isEditable() {
2487
435
  })))();
2488
436
  }
2489
437
  //#endregion
2490
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/focus/selection.js
438
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/focus/selection.js
2491
439
  /**
2492
440
  * Determine if the element has its own selection implementation
2493
441
  * and does not interact with the Document Selection API.
@@ -2507,7 +455,7 @@ function init_selection() {
2507
455
  })))();
2508
456
  }
2509
457
  //#endregion
2510
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/selection/updateSelectionOnFocus.js
458
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/selection/updateSelectionOnFocus.js
2511
459
  /**
2512
460
  * Reset the Document Selection when moving focus into an element
2513
461
  * with own selection implementation.
@@ -2532,7 +480,7 @@ function init_updateSelectionOnFocus() {
2532
480
  })))();
2533
481
  }
2534
482
  //#endregion
2535
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/wrapEvent.js
483
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/wrapEvent.js
2536
484
  function wrapEvent(cb, _element) {
2537
485
  return getConfig().eventWrapper(cb);
2538
486
  }
@@ -2542,7 +490,7 @@ function init_wrapEvent() {
2542
490
  })))();
2543
491
  }
2544
492
  //#endregion
2545
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/focus.js
493
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/focus.js
2546
494
  /**
2547
495
  * Focus closest focusable element.
2548
496
  */ function focusElement(element) {
@@ -2568,7 +516,7 @@ function init_focus() {
2568
516
  })))();
2569
517
  }
2570
518
  //#endregion
2571
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/behavior/registry.js
519
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/behavior/registry.js
2572
520
  var behavior;
2573
521
  function init_registry() {
2574
522
  return (init_registry = __esmMin((() => {
@@ -2576,7 +524,7 @@ function init_registry() {
2576
524
  })))();
2577
525
  }
2578
526
  //#endregion
2579
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/behavior/click.js
527
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/behavior/click.js
2580
528
  function init_click() {
2581
529
  return (init_click = __esmMin((() => {
2582
530
  init_Clipboard();
@@ -2601,7 +549,7 @@ function init_click() {
2601
549
  })))();
2602
550
  }
2603
551
  //#endregion
2604
- //#region ../../node_modules/@testing-library/user-event/dist/esm/document/UI.js
552
+ //#region ../node_modules/@testing-library/user-event/dist/esm/document/UI.js
2605
553
  function isUIValue(value) {
2606
554
  return typeof value === "object" && UIValue in value;
2607
555
  }
@@ -2672,7 +620,7 @@ function init_UI() {
2672
620
  })))();
2673
621
  }
2674
622
  //#endregion
2675
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/edit/timeValue.js
623
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/edit/timeValue.js
2676
624
  function buildTimeValue(value) {
2677
625
  const onlyDigitsValue = value.replace(/\D/g, "");
2678
626
  if (onlyDigitsValue.length < 2) return value;
@@ -2707,7 +655,7 @@ function init_timeValue() {
2707
655
  })))();
2708
656
  }
2709
657
  //#endregion
2710
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/edit/maxLength.js
658
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/edit/maxLength.js
2711
659
  function getMaxLength(element) {
2712
660
  var _element_getAttribute;
2713
661
  const attr = (_element_getAttribute = element.getAttribute("maxlength")) !== null && _element_getAttribute !== void 0 ? _element_getAttribute : "";
@@ -2731,7 +679,7 @@ function init_maxLength() {
2731
679
  })))();
2732
680
  }
2733
681
  //#endregion
2734
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/focus/cursor.js
682
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/focus/cursor.js
2735
683
  function getNextCursorPosition(node, offset, direction, inputType) {
2736
684
  if (isTextNode(node) && offset + direction >= 0 && offset + direction <= node.nodeValue.length) return {
2737
685
  node,
@@ -2815,7 +763,7 @@ function init_cursor() {
2815
763
  return (init_cursor = __esmMin((() => {})))();
2816
764
  }
2817
765
  //#endregion
2818
- //#region ../../node_modules/@testing-library/user-event/dist/esm/document/trackValue.js
766
+ //#region ../node_modules/@testing-library/user-event/dist/esm/document/trackValue.js
2819
767
  function isReact17Element(element) {
2820
768
  return Object.getOwnPropertyNames(element).some((k) => k.startsWith("__react")) && getWindow(element).REACT_VERSION === 17;
2821
769
  }
@@ -2852,7 +800,7 @@ function init_trackValue() {
2852
800
  })))();
2853
801
  }
2854
802
  //#endregion
2855
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/selection/getTargetTypeAndSelection.js
803
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/selection/getTargetTypeAndSelection.js
2856
804
  /**
2857
805
  * Determine which selection logic and selection ranges to consider.
2858
806
  */ function getTargetTypeAndSelection(node) {
@@ -2878,7 +826,7 @@ function init_getTargetTypeAndSelection() {
2878
826
  })))();
2879
827
  }
2880
828
  //#endregion
2881
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/selection/getInputRange.js
829
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/selection/getInputRange.js
2882
830
  /**
2883
831
  * Get the range that would be overwritten by input.
2884
832
  */ function getInputRange(focusNode) {
@@ -2895,7 +843,7 @@ function init_getInputRange() {
2895
843
  })))();
2896
844
  }
2897
845
  //#endregion
2898
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/selection/setSelection.js
846
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/selection/setSelection.js
2899
847
  /**
2900
848
  * Set the selection
2901
849
  */ function setSelection({ focusNode, focusOffset, anchorNode = focusNode, anchorOffset = focusOffset }) {
@@ -2914,7 +862,7 @@ function init_setSelection() {
2914
862
  })))();
2915
863
  }
2916
864
  //#endregion
2917
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/input.js
865
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/input.js
2918
866
  function isDateOrTime(element) {
2919
867
  return isElementType(element, "input") && ["date", "time"].includes(element.type);
2920
868
  }
@@ -3033,7 +981,7 @@ function init_input() {
3033
981
  })))();
3034
982
  }
3035
983
  //#endregion
3036
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/behavior/cut.js
984
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/behavior/cut.js
3037
985
  function init_cut() {
3038
986
  return (init_cut = __esmMin((() => {
3039
987
  init_Clipboard();
@@ -3048,7 +996,7 @@ function init_cut() {
3048
996
  })))();
3049
997
  }
3050
998
  //#endregion
3051
- //#region ../../node_modules/@testing-library/user-event/dist/esm/document/getValueOrTextContent.js
999
+ //#region ../node_modules/@testing-library/user-event/dist/esm/document/getValueOrTextContent.js
3052
1000
  function getValueOrTextContent(element) {
3053
1001
  // istanbul ignore if
3054
1002
  if (!element) return null;
@@ -3062,7 +1010,7 @@ function init_getValueOrTextContent() {
3062
1010
  })))();
3063
1011
  }
3064
1012
  //#endregion
3065
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/misc/isVisible.js
1013
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/misc/isVisible.js
3066
1014
  function isVisible(element) {
3067
1015
  const window = getWindow(element);
3068
1016
  for (let el = element; el === null || el === void 0 ? void 0 : el.ownerDocument; el = el.parentElement) {
@@ -3076,7 +1024,7 @@ function init_isVisible() {
3076
1024
  return (init_isVisible = __esmMin((() => {})))();
3077
1025
  }
3078
1026
  //#endregion
3079
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/focus/getTabDestination.js
1027
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/focus/getTabDestination.js
3080
1028
  function getTabDestination(activeElement, shift) {
3081
1029
  const document = activeElement.ownerDocument;
3082
1030
  const focusableElements = document.querySelectorAll(FOCUSABLE_SELECTOR);
@@ -3127,7 +1075,7 @@ function init_getTabDestination() {
3127
1075
  })))();
3128
1076
  }
3129
1077
  //#endregion
3130
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/selection/moveSelection.js
1078
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/selection/moveSelection.js
3131
1079
  /**
3132
1080
  * Move the selection
3133
1081
  */ function moveSelection(node, direction) {
@@ -3159,7 +1107,7 @@ function init_moveSelection() {
3159
1107
  })))();
3160
1108
  }
3161
1109
  //#endregion
3162
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/selection/selectAll.js
1110
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/selection/selectAll.js
3163
1111
  /**
3164
1112
  * Expand a selection like the browser does when pressing Ctrl+A.
3165
1113
  */ function selectAll(target) {
@@ -3192,7 +1140,7 @@ function init_selectAll() {
3192
1140
  })))();
3193
1141
  }
3194
1142
  //#endregion
3195
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/selection/setSelectionRange.js
1143
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/selection/setSelectionRange.js
3196
1144
  /**
3197
1145
  * Backward-compatible selection.
3198
1146
  *
@@ -3219,7 +1167,7 @@ function init_setSelectionRange() {
3219
1167
  })))();
3220
1168
  }
3221
1169
  //#endregion
3222
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/radio.js
1170
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/radio.js
3223
1171
  function walkRadio(instance, el, direction) {
3224
1172
  const window = getWindow(el);
3225
1173
  const group = Array.from(el.ownerDocument.querySelectorAll(el.name ? `input[type="radio"][name="${window.CSS.escape(el.name)}"]` : `input[type="radio"][name=""], input[type="radio"]:not([name])`));
@@ -3240,7 +1188,7 @@ function init_radio() {
3240
1188
  })))();
3241
1189
  }
3242
1190
  //#endregion
3243
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/behavior/keydown.js
1191
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/behavior/keydown.js
3244
1192
  var keydownBehavior, combinationBehavior;
3245
1193
  function init_keydown() {
3246
1194
  return (init_keydown = __esmMin((() => {
@@ -3328,7 +1276,7 @@ function init_keydown() {
3328
1276
  })))();
3329
1277
  }
3330
1278
  //#endregion
3331
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/behavior/keypress.js
1279
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/behavior/keypress.js
3332
1280
  var ClickInputOnEnter, SubmitSingleInputOnEnter;
3333
1281
  function init_keypress() {
3334
1282
  return (init_keypress = __esmMin((() => {
@@ -3376,7 +1324,7 @@ function init_keypress() {
3376
1324
  })))();
3377
1325
  }
3378
1326
  //#endregion
3379
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/behavior/keyup.js
1327
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/behavior/keyup.js
3380
1328
  var keyupBehavior;
3381
1329
  function init_keyup() {
3382
1330
  return (init_keyup = __esmMin((() => {
@@ -3393,7 +1341,7 @@ function init_keyup() {
3393
1341
  })))();
3394
1342
  }
3395
1343
  //#endregion
3396
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/behavior/paste.js
1344
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/behavior/paste.js
3397
1345
  function init_paste() {
3398
1346
  return (init_paste = __esmMin((() => {
3399
1347
  init_Clipboard();
@@ -3410,7 +1358,7 @@ function init_paste() {
3410
1358
  })))();
3411
1359
  }
3412
1360
  //#endregion
3413
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/eventMap.js
1361
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/eventMap.js
3414
1362
  function getEventClass(type) {
3415
1363
  return eventMap[type].EventType;
3416
1364
  }
@@ -3689,7 +1637,7 @@ function init_eventMap() {
3689
1637
  })))();
3690
1638
  }
3691
1639
  //#endregion
3692
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/createEvent.js
1640
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/createEvent.js
3693
1641
  function createEvent(type, target, init) {
3694
1642
  const window = getWindow(target);
3695
1643
  const { EventType, defaultInit } = eventMap[type];
@@ -3854,7 +1802,7 @@ function init_createEvent() {
3854
1802
  })))();
3855
1803
  }
3856
1804
  //#endregion
3857
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/dispatchEvent.js
1805
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/dispatchEvent.js
3858
1806
  function dispatchUIEvent(target, type, init, preventDefault = false) {
3859
1807
  if (isMouseEvent(type) || isKeyboardEvent(type)) init = {
3860
1808
  ...init,
@@ -3899,7 +1847,7 @@ function init_dispatchEvent() {
3899
1847
  })))();
3900
1848
  }
3901
1849
  //#endregion
3902
- //#region ../../node_modules/@testing-library/user-event/dist/esm/document/patchFocus.js
1850
+ //#region ../node_modules/@testing-library/user-event/dist/esm/document/patchFocus.js
3903
1851
  function patchFocus(HTMLElement) {
3904
1852
  if (HTMLElement.prototype[patched]) return;
3905
1853
  const { focus, blur } = HTMLElement.prototype;
@@ -3965,7 +1913,7 @@ function init_patchFocus() {
3965
1913
  })))();
3966
1914
  }
3967
1915
  //#endregion
3968
- //#region ../../node_modules/@testing-library/user-event/dist/esm/document/interceptor.js
1916
+ //#region ../node_modules/@testing-library/user-event/dist/esm/document/interceptor.js
3969
1917
  function prepareInterceptor(element, propName, interceptorImpl) {
3970
1918
  const prototypeDescriptor = Object.getOwnPropertyDescriptor(element.constructor.prototype, propName);
3971
1919
  const objectDescriptor = Object.getOwnPropertyDescriptor(element, propName);
@@ -4051,7 +1999,7 @@ function init_interceptor() {
4051
1999
  })))();
4052
2000
  }
4053
2001
  //#endregion
4054
- //#region ../../node_modules/@testing-library/user-event/dist/esm/document/prepareDocument.js
2002
+ //#region ../node_modules/@testing-library/user-event/dist/esm/document/prepareDocument.js
4055
2003
  function prepareDocument(document) {
4056
2004
  if (document[isPrepared]) return;
4057
2005
  document.addEventListener("focus", (e) => {
@@ -4097,7 +2045,7 @@ function init_prepareDocument() {
4097
2045
  })))();
4098
2046
  }
4099
2047
  //#endregion
4100
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/misc/getDocumentFromNode.js
2048
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/misc/getDocumentFromNode.js
4101
2049
  function getDocumentFromNode(el) {
4102
2050
  return isDocument(el) ? el : el.ownerDocument;
4103
2051
  }
@@ -4105,7 +2053,7 @@ function isDocument(node) {
4105
2053
  return node.nodeType === 9;
4106
2054
  }
4107
2055
  //#endregion
4108
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/misc/level.js
2056
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/misc/level.js
4109
2057
  function setLevelRef(instance, level) {
4110
2058
  instance.levelRefs[level] = {};
4111
2059
  }
@@ -4123,14 +2071,14 @@ function init_level() {
4123
2071
  })))();
4124
2072
  }
4125
2073
  //#endregion
4126
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/misc/wait.js
2074
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/misc/wait.js
4127
2075
  function wait(config) {
4128
2076
  const delay = config.delay;
4129
2077
  if (typeof delay !== "number") return;
4130
2078
  return Promise.all([new Promise((resolve) => globalThis.setTimeout(() => resolve(), delay)), config.advanceTimers(delay)]);
4131
2079
  }
4132
2080
  //#endregion
4133
- //#region ../../node_modules/@testing-library/user-event/dist/esm/options.js
2081
+ //#region ../node_modules/@testing-library/user-event/dist/esm/options.js
4134
2082
  var PointerEventsCheckLevel;
4135
2083
  function init_options() {
4136
2084
  return (init_options = __esmMin((() => {
@@ -4147,7 +2095,7 @@ function init_options() {
4147
2095
  })))();
4148
2096
  }
4149
2097
  //#endregion
4150
- //#region ../../node_modules/@testing-library/user-event/dist/esm/system/keyboard.js
2098
+ //#region ../node_modules/@testing-library/user-event/dist/esm/system/keyboard.js
4151
2099
  function _define_property$6(obj, key, value) {
4152
2100
  if (key in obj) Object.defineProperty(obj, key, {
4153
2101
  value,
@@ -4297,7 +2245,7 @@ function init_keyboard() {
4297
2245
  })))();
4298
2246
  }
4299
2247
  //#endregion
4300
- //#region ../../node_modules/@testing-library/user-event/dist/esm/keyboard/keyMap.js
2248
+ //#region ../node_modules/@testing-library/user-event/dist/esm/keyboard/keyMap.js
4301
2249
  var defaultKeyMap$1;
4302
2250
  function init_keyMap() {
4303
2251
  return (init_keyMap = __esmMin((() => {
@@ -4469,7 +2417,7 @@ function init_keyMap() {
4469
2417
  })))();
4470
2418
  }
4471
2419
  //#endregion
4472
- //#region ../../node_modules/@testing-library/user-event/dist/esm/pointer/keyMap.js
2420
+ //#region ../node_modules/@testing-library/user-event/dist/esm/pointer/keyMap.js
4473
2421
  var defaultKeyMap;
4474
2422
  function init_keyMap$1() {
4475
2423
  return (init_keyMap$1 = __esmMin((() => {
@@ -4505,7 +2453,7 @@ function init_keyMap$1() {
4505
2453
  })))();
4506
2454
  }
4507
2455
  //#endregion
4508
- //#region ../../node_modules/@testing-library/user-event/dist/esm/system/pointer/buttons.js
2456
+ //#region ../node_modules/@testing-library/user-event/dist/esm/system/pointer/buttons.js
4509
2457
  function _define_property$5(obj, key, value) {
4510
2458
  if (key in obj) Object.defineProperty(obj, key, {
4511
2459
  value,
@@ -4573,7 +2521,7 @@ function init_buttons() {
4573
2521
  })))();
4574
2522
  }
4575
2523
  //#endregion
4576
- //#region ../../node_modules/@testing-library/user-event/dist/esm/system/pointer/device.js
2524
+ //#region ../node_modules/@testing-library/user-event/dist/esm/system/pointer/device.js
4577
2525
  function _define_property$4(obj, key, value) {
4578
2526
  if (key in obj) Object.defineProperty(obj, key, {
4579
2527
  value,
@@ -4607,7 +2555,7 @@ function init_device() {
4607
2555
  })))();
4608
2556
  }
4609
2557
  //#endregion
4610
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/misc/getTreeDiff.js
2558
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/misc/getTreeDiff.js
4611
2559
  function getTreeDiff(a, b) {
4612
2560
  const treeA = [];
4613
2561
  for (let el = a; el; el = el.parentElement) treeA.push(el);
@@ -4622,7 +2570,7 @@ function getTreeDiff(a, b) {
4622
2570
  ];
4623
2571
  }
4624
2572
  //#endregion
4625
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/selection/resolveCaretPosition.js
2573
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/selection/resolveCaretPosition.js
4626
2574
  function resolveCaretPosition({ target, node, offset }) {
4627
2575
  if (hasOwnSelection(target)) return {
4628
2576
  node: target,
@@ -4664,7 +2612,7 @@ function init_resolveCaretPosition() {
4664
2612
  })))();
4665
2613
  }
4666
2614
  //#endregion
4667
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/selection/setSelectionPerMouse.js
2615
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/selection/setSelectionPerMouse.js
4668
2616
  function setSelectionPerMouseDown({ document, target, clickCount, node, offset }) {
4669
2617
  if (hasNoSelection(target)) return;
4670
2618
  const targetHasOwnSelection = hasOwnSelection(target);
@@ -4719,7 +2667,7 @@ function init_setSelectionPerMouse() {
4719
2667
  })))();
4720
2668
  }
4721
2669
  //#endregion
4722
- //#region ../../node_modules/@testing-library/user-event/dist/esm/event/selection/modifySelectionPerMouse.js
2670
+ //#region ../node_modules/@testing-library/user-event/dist/esm/event/selection/modifySelectionPerMouse.js
4723
2671
  function modifySelectionPerMouseMove(selectionRange, { document, target, node, offset }) {
4724
2672
  const selectionFocus = resolveCaretPosition({
4725
2673
  target,
@@ -4753,13 +2701,13 @@ function init_modifySelectionPerMouse() {
4753
2701
  })))();
4754
2702
  }
4755
2703
  //#endregion
4756
- //#region ../../node_modules/@testing-library/user-event/dist/esm/system/pointer/shared.js
2704
+ //#region ../node_modules/@testing-library/user-event/dist/esm/system/pointer/shared.js
4757
2705
  function isDifferentPointerPosition(positionA, positionB) {
4758
2706
  var _positionA_coords, _positionB_coords, _positionA_coords1, _positionB_coords1, _positionA_coords2, _positionB_coords2, _positionA_coords3, _positionB_coords3, _positionA_coords4, _positionB_coords4, _positionA_coords5, _positionB_coords5, _positionA_coords6, _positionB_coords6, _positionA_coords7, _positionB_coords7, _positionA_coords8, _positionB_coords8, _positionA_coords9, _positionB_coords9, _positionA_caret, _positionB_caret, _positionA_caret1, _positionB_caret1;
4759
2707
  return positionA.target !== positionB.target || ((_positionA_coords = positionA.coords) === null || _positionA_coords === void 0 ? void 0 : _positionA_coords.x) !== ((_positionB_coords = positionB.coords) === null || _positionB_coords === void 0 ? void 0 : _positionB_coords.x) || ((_positionA_coords1 = positionA.coords) === null || _positionA_coords1 === void 0 ? void 0 : _positionA_coords1.y) !== ((_positionB_coords1 = positionB.coords) === null || _positionB_coords1 === void 0 ? void 0 : _positionB_coords1.y) || ((_positionA_coords2 = positionA.coords) === null || _positionA_coords2 === void 0 ? void 0 : _positionA_coords2.clientX) !== ((_positionB_coords2 = positionB.coords) === null || _positionB_coords2 === void 0 ? void 0 : _positionB_coords2.clientX) || ((_positionA_coords3 = positionA.coords) === null || _positionA_coords3 === void 0 ? void 0 : _positionA_coords3.clientY) !== ((_positionB_coords3 = positionB.coords) === null || _positionB_coords3 === void 0 ? void 0 : _positionB_coords3.clientY) || ((_positionA_coords4 = positionA.coords) === null || _positionA_coords4 === void 0 ? void 0 : _positionA_coords4.offsetX) !== ((_positionB_coords4 = positionB.coords) === null || _positionB_coords4 === void 0 ? void 0 : _positionB_coords4.offsetX) || ((_positionA_coords5 = positionA.coords) === null || _positionA_coords5 === void 0 ? void 0 : _positionA_coords5.offsetY) !== ((_positionB_coords5 = positionB.coords) === null || _positionB_coords5 === void 0 ? void 0 : _positionB_coords5.offsetY) || ((_positionA_coords6 = positionA.coords) === null || _positionA_coords6 === void 0 ? void 0 : _positionA_coords6.pageX) !== ((_positionB_coords6 = positionB.coords) === null || _positionB_coords6 === void 0 ? void 0 : _positionB_coords6.pageX) || ((_positionA_coords7 = positionA.coords) === null || _positionA_coords7 === void 0 ? void 0 : _positionA_coords7.pageY) !== ((_positionB_coords7 = positionB.coords) === null || _positionB_coords7 === void 0 ? void 0 : _positionB_coords7.pageY) || ((_positionA_coords8 = positionA.coords) === null || _positionA_coords8 === void 0 ? void 0 : _positionA_coords8.screenX) !== ((_positionB_coords8 = positionB.coords) === null || _positionB_coords8 === void 0 ? void 0 : _positionB_coords8.screenX) || ((_positionA_coords9 = positionA.coords) === null || _positionA_coords9 === void 0 ? void 0 : _positionA_coords9.screenY) !== ((_positionB_coords9 = positionB.coords) === null || _positionB_coords9 === void 0 ? void 0 : _positionB_coords9.screenY) || ((_positionA_caret = positionA.caret) === null || _positionA_caret === void 0 ? void 0 : _positionA_caret.node) !== ((_positionB_caret = positionB.caret) === null || _positionB_caret === void 0 ? void 0 : _positionB_caret.node) || ((_positionA_caret1 = positionA.caret) === null || _positionA_caret1 === void 0 ? void 0 : _positionA_caret1.offset) !== ((_positionB_caret1 = positionB.caret) === null || _positionB_caret1 === void 0 ? void 0 : _positionB_caret1.offset);
4760
2708
  }
4761
2709
  //#endregion
4762
- //#region ../../node_modules/@testing-library/user-event/dist/esm/system/pointer/mouse.js
2710
+ //#region ../node_modules/@testing-library/user-event/dist/esm/system/pointer/mouse.js
4763
2711
  function _define_property$3(obj, key, value) {
4764
2712
  if (key in obj) Object.defineProperty(obj, key, {
4765
2713
  value,
@@ -4923,7 +2871,7 @@ function init_mouse() {
4923
2871
  })))();
4924
2872
  }
4925
2873
  //#endregion
4926
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/pointer/cssPointerEvents.js
2874
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/pointer/cssPointerEvents.js
4927
2875
  function hasPointerEvents(instance, element) {
4928
2876
  var _checkPointerEvents;
4929
2877
  return ((_checkPointerEvents = checkPointerEvents(instance, element)) === null || _checkPointerEvents === void 0 ? void 0 : _checkPointerEvents.pointerEvents) !== "none";
@@ -5008,7 +2956,7 @@ function init_cssPointerEvents() {
5008
2956
  })))();
5009
2957
  }
5010
2958
  //#endregion
5011
- //#region ../../node_modules/@testing-library/user-event/dist/esm/system/pointer/pointer.js
2959
+ //#region ../node_modules/@testing-library/user-event/dist/esm/system/pointer/pointer.js
5012
2960
  function _define_property$2(obj, key, value) {
5013
2961
  if (key in obj) Object.defineProperty(obj, key, {
5014
2962
  value,
@@ -5123,7 +3071,7 @@ function init_pointer() {
5123
3071
  })))();
5124
3072
  }
5125
3073
  //#endregion
5126
- //#region ../../node_modules/@testing-library/user-event/dist/esm/system/pointer/index.js
3074
+ //#region ../node_modules/@testing-library/user-event/dist/esm/system/pointer/index.js
5127
3075
  function _define_property$1(obj, key, value) {
5128
3076
  if (key in obj) Object.defineProperty(obj, key, {
5129
3077
  value,
@@ -5256,7 +3204,7 @@ function init_pointer$1() {
5256
3204
  })))();
5257
3205
  }
5258
3206
  //#endregion
5259
- //#region ../../node_modules/@testing-library/user-event/dist/esm/system/index.js
3207
+ //#region ../node_modules/@testing-library/user-event/dist/esm/system/index.js
5260
3208
  function _define_property(obj, key, value) {
5261
3209
  if (key in obj) Object.defineProperty(obj, key, {
5262
3210
  value,
@@ -5297,7 +3245,7 @@ function init_system() {
5297
3245
  })))();
5298
3246
  }
5299
3247
  //#endregion
5300
- //#region ../../node_modules/@testing-library/user-event/dist/esm/convenience/click.js
3248
+ //#region ../node_modules/@testing-library/user-event/dist/esm/convenience/click.js
5301
3249
  async function click$1(element) {
5302
3250
  const pointerIn = [];
5303
3251
  if (!this.config.skipHover) pointerIn.push({ target: element });
@@ -5314,7 +3262,7 @@ async function tripleClick$1(element) {
5314
3262
  return this.pointer([{ target: element }, "[MouseLeft][MouseLeft][MouseLeft]"]);
5315
3263
  }
5316
3264
  //#endregion
5317
- //#region ../../node_modules/@testing-library/user-event/dist/esm/convenience/hover.js
3265
+ //#region ../node_modules/@testing-library/user-event/dist/esm/convenience/hover.js
5318
3266
  async function hover$1(element) {
5319
3267
  return this.pointer({ target: element });
5320
3268
  }
@@ -5329,12 +3277,12 @@ function init_hover() {
5329
3277
  })))();
5330
3278
  }
5331
3279
  //#endregion
5332
- //#region ../../node_modules/@testing-library/user-event/dist/esm/convenience/tab.js
3280
+ //#region ../node_modules/@testing-library/user-event/dist/esm/convenience/tab.js
5333
3281
  async function tab$1({ shift } = {}) {
5334
3282
  return this.keyboard(shift === true ? "{Shift>}{Tab}{/Shift}" : shift === false ? "[/ShiftLeft][/ShiftRight]{Tab}" : "{Tab}");
5335
3283
  }
5336
3284
  //#endregion
5337
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/keyDef/readNextDescriptor.js
3285
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/keyDef/readNextDescriptor.js
5338
3286
  /**
5339
3287
  * Read the next key definition from user input
5340
3288
  *
@@ -5419,7 +3367,7 @@ function init_readNextDescriptor() {
5419
3367
  })))();
5420
3368
  }
5421
3369
  //#endregion
5422
- //#region ../../node_modules/@testing-library/user-event/dist/esm/keyboard/parseKeyDef.js
3370
+ //#region ../node_modules/@testing-library/user-event/dist/esm/keyboard/parseKeyDef.js
5423
3371
  /**
5424
3372
  * Parse key definitions per `keyboardMap`
5425
3373
  *
@@ -5465,7 +3413,7 @@ function init_parseKeyDef() {
5465
3413
  })))();
5466
3414
  }
5467
3415
  //#endregion
5468
- //#region ../../node_modules/@testing-library/user-event/dist/esm/keyboard/index.js
3416
+ //#region ../node_modules/@testing-library/user-event/dist/esm/keyboard/index.js
5469
3417
  async function keyboard$1(text) {
5470
3418
  const actions = parseKeyDef$1(this.config.keyboardMap, text);
5471
3419
  for (let i = 0; i < actions.length; i++) {
@@ -5494,7 +3442,7 @@ function init_keyboard$1() {
5494
3442
  })))();
5495
3443
  }
5496
3444
  //#endregion
5497
- //#region ../../node_modules/@testing-library/user-event/dist/esm/document/copySelection.js
3445
+ //#region ../node_modules/@testing-library/user-event/dist/esm/document/copySelection.js
5498
3446
  function copySelection(target) {
5499
3447
  const data = hasOwnSelection(target) ? { "text/plain": readSelectedValueFromInput(target) } : { "text/plain": String(target.ownerDocument.getSelection()) };
5500
3448
  const dt = createDataTransfer(getWindow(target));
@@ -5514,7 +3462,7 @@ function init_copySelection() {
5514
3462
  })))();
5515
3463
  }
5516
3464
  //#endregion
5517
- //#region ../../node_modules/@testing-library/user-event/dist/esm/clipboard/copy.js
3465
+ //#region ../node_modules/@testing-library/user-event/dist/esm/clipboard/copy.js
5518
3466
  async function copy$1() {
5519
3467
  var _doc_activeElement;
5520
3468
  const doc = this.config.document;
@@ -5531,7 +3479,7 @@ function init_copy() {
5531
3479
  })))();
5532
3480
  }
5533
3481
  //#endregion
5534
- //#region ../../node_modules/@testing-library/user-event/dist/esm/clipboard/cut.js
3482
+ //#region ../node_modules/@testing-library/user-event/dist/esm/clipboard/cut.js
5535
3483
  async function cut$1() {
5536
3484
  var _doc_activeElement;
5537
3485
  const doc = this.config.document;
@@ -5548,7 +3496,7 @@ function init_cut$1() {
5548
3496
  })))();
5549
3497
  }
5550
3498
  //#endregion
5551
- //#region ../../node_modules/@testing-library/user-event/dist/esm/clipboard/paste.js
3499
+ //#region ../node_modules/@testing-library/user-event/dist/esm/clipboard/paste.js
5552
3500
  async function paste$1(clipboardData) {
5553
3501
  var _doc_activeElement, _ref;
5554
3502
  const doc = this.config.document;
@@ -5570,7 +3518,7 @@ function init_paste$1() {
5570
3518
  })))();
5571
3519
  }
5572
3520
  //#endregion
5573
- //#region ../../node_modules/@testing-library/user-event/dist/esm/pointer/parseKeyDef.js
3521
+ //#region ../node_modules/@testing-library/user-event/dist/esm/pointer/parseKeyDef.js
5574
3522
  function parseKeyDef(pointerMap, keys) {
5575
3523
  const defs = [];
5576
3524
  do {
@@ -5592,7 +3540,7 @@ function init_parseKeyDef$1() {
5592
3540
  })))();
5593
3541
  }
5594
3542
  //#endregion
5595
- //#region ../../node_modules/@testing-library/user-event/dist/esm/pointer/index.js
3543
+ //#region ../node_modules/@testing-library/user-event/dist/esm/pointer/index.js
5596
3544
  async function pointer$1(input) {
5597
3545
  const { pointerMap } = this.config;
5598
3546
  const actions = [];
@@ -5658,7 +3606,7 @@ function init_pointer$2() {
5658
3606
  })))();
5659
3607
  }
5660
3608
  //#endregion
5661
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utility/clear.js
3609
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utility/clear.js
5662
3610
  async function clear$1(element) {
5663
3611
  if (!isEditable(element) || isDisabled(element)) throw new Error("clear()` is only supported on editable elements.");
5664
3612
  focusElement(element);
@@ -5685,7 +3633,7 @@ function init_clear() {
5685
3633
  })))();
5686
3634
  }
5687
3635
  //#endregion
5688
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utility/selectOptions.js
3636
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utility/selectOptions.js
5689
3637
  async function selectOptions$1(select, values) {
5690
3638
  return selectOptionsBase.call(this, true, select, values);
5691
3639
  }
@@ -5774,7 +3722,7 @@ function init_selectOptions() {
5774
3722
  })))();
5775
3723
  }
5776
3724
  //#endregion
5777
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utility/type.js
3725
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utility/type.js
5778
3726
  async function type$1(element, text, { skipClick = this.config.skipClick, skipAutoClose = this.config.skipAutoClose, initialSelectionStart, initialSelectionEnd } = {}) {
5779
3727
  if (element.disabled) return;
5780
3728
  if (!skipClick) await this.click(element);
@@ -5790,7 +3738,7 @@ function init_type() {
5790
3738
  })))();
5791
3739
  }
5792
3740
  //#endregion
5793
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utils/edit/setFiles.js
3741
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utils/edit/setFiles.js
5794
3742
  function restoreProperty(obj, prop, descriptor) {
5795
3743
  if (descriptor) Object.defineProperty(obj, prop, descriptor);
5796
3744
  else delete obj[prop];
@@ -5842,7 +3790,7 @@ function init_setFiles() {
5842
3790
  })))();
5843
3791
  }
5844
3792
  //#endregion
5845
- //#region ../../node_modules/@testing-library/user-event/dist/esm/utility/upload.js
3793
+ //#region ../node_modules/@testing-library/user-event/dist/esm/utility/upload.js
5846
3794
  async function upload$1(element, fileOrFiles) {
5847
3795
  const input = isElementType(element, "label") ? element.control : element;
5848
3796
  if (!input || !isElementType(input, "input", { type: "file" })) throw new TypeError(`The ${input === element ? "given" : "associated"} ${input === null || input === void 0 ? void 0 : input.tagName} element does not accept file uploads`);
@@ -5886,7 +3834,7 @@ function init_upload() {
5886
3834
  })))();
5887
3835
  }
5888
3836
  //#endregion
5889
- //#region ../../node_modules/@testing-library/user-event/dist/esm/setup/api.js
3837
+ //#region ../node_modules/@testing-library/user-event/dist/esm/setup/api.js
5890
3838
  var userEventApi;
5891
3839
  function init_api() {
5892
3840
  return (init_api = __esmMin((() => {
@@ -5921,7 +3869,7 @@ function init_api() {
5921
3869
  })))();
5922
3870
  }
5923
3871
  //#endregion
5924
- //#region ../../node_modules/@testing-library/user-event/dist/esm/setup/wrapAsync.js
3872
+ //#region ../node_modules/@testing-library/user-event/dist/esm/setup/wrapAsync.js
5925
3873
  /**
5926
3874
  * Wrap an internal Promise
5927
3875
  */ function wrapAsync(implementation) {
@@ -5933,7 +3881,7 @@ function init_wrapAsync() {
5933
3881
  })))();
5934
3882
  }
5935
3883
  //#endregion
5936
- //#region ../../node_modules/@testing-library/user-event/dist/esm/setup/setup.js
3884
+ //#region ../node_modules/@testing-library/user-event/dist/esm/setup/setup.js
5937
3885
  function createConfig(options = {}, defaults = defaultOptionsSetup, node) {
5938
3886
  const document = getDocument(options, node, defaults);
5939
3887
  return {
@@ -6043,7 +3991,7 @@ function init_setup() {
6043
3991
  })))();
6044
3992
  }
6045
3993
  //#endregion
6046
- //#region ../../node_modules/@testing-library/user-event/dist/esm/setup/directApi.js
3994
+ //#region ../node_modules/@testing-library/user-event/dist/esm/setup/directApi.js
6047
3995
  var directApi_exports = /* @__PURE__ */ __exportAll({
6048
3996
  clear: () => clear,
6049
3997
  click: () => click,
@@ -6120,7 +4068,7 @@ function init_directApi() {
6120
4068
  })))();
6121
4069
  }
6122
4070
  //#endregion
6123
- //#region ../../node_modules/@testing-library/user-event/dist/esm/setup/index.js
4071
+ //#region ../node_modules/@testing-library/user-event/dist/esm/setup/index.js
6124
4072
  var userEvent;
6125
4073
  function init_setup$1() {
6126
4074
  return (init_setup$1 = __esmMin((() => {
@@ -6133,11 +4081,11 @@ function init_setup$1() {
6133
4081
  })))();
6134
4082
  }
6135
4083
  //#endregion
6136
- //#region ../../node_modules/@testing-library/user-event/dist/esm/index.js
4084
+ //#region ../node_modules/@testing-library/user-event/dist/esm/index.js
6137
4085
  function init_esm() {
6138
4086
  return (init_esm = __esmMin((() => {
6139
4087
  init_setup$1();
6140
4088
  })))();
6141
4089
  }
6142
4090
  //#endregion
6143
- export { matchers_exports as a, init_matchers as i, init_setup$1 as n, userEvent as r, init_esm as t };
4091
+ export { init_setup$1 as n, userEvent as r, init_esm as t };