@ncino/web-components 5.0.0-preview.1 → 5.0.0-preview.3

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 (168) hide show
  1. package/dist/_virtual/_commonjsHelpers.js +1 -1
  2. package/dist/_virtual/index_html.js +1 -1
  3. package/dist/_virtual/index_react.js +1 -1
  4. package/dist/_virtual/preload-helper.js +1 -1
  5. package/dist/assets/node_modules/.pnpm/ckeditor5@45.2.1/node_modules/ckeditor5/dist/ckeditor5.css +1 -1
  6. package/dist/components/accordion/gator/base/accordion.gator.js +6 -6
  7. package/dist/components/avatar/gator/avatar.gator.js +2 -2
  8. package/dist/components/badge/gator/badge.gator.js +2 -2
  9. package/dist/components/boolean/boolean.gator.js +6 -6
  10. package/dist/components/breadcrumbs/gator/breadcrumb/breadcrumb.gator.js +2 -2
  11. package/dist/components/button/gator/button.gator.js +4 -4
  12. package/dist/components/button-group/gator/button-group.gator.js +2 -2
  13. package/dist/components/checkbox/checkbox.gator.js +5 -5
  14. package/dist/components/checkbox-group/checkbox-group.gator.js +8 -8
  15. package/dist/components/combobox/base/combobox.js +1 -1
  16. package/dist/components/combobox/base/combobox.slds.js +13 -13
  17. package/dist/components/date-picker/base/gator/datepicker.gator.js +18 -18
  18. package/dist/components/date-picker/year-month-selector/year-month-selector.gator.js +2 -2
  19. package/dist/components/headline-card/gator/headline-card.gator.js +2 -2
  20. package/dist/components/icon/gator/icon.gator.js +2 -2
  21. package/dist/components/illustration/gator/illustration.gator.js +2 -2
  22. package/dist/components/input/base/input-base.gator.js +1 -1
  23. package/dist/components/input/gator/dropdown/input-dropdown.gator.js +11 -11
  24. package/dist/components/input/gator/input-currency/input-currency.gator.js +2 -2
  25. package/dist/components/input/gator/input-date/input-date.gator.js +15 -15
  26. package/dist/components/input/gator/input-file/input-file.gator.js +3 -3
  27. package/dist/components/input/gator/input-masked/input-masked.gator.js +1 -1
  28. package/dist/components/input/gator/input-phone/input-phone.gator.js +2 -2
  29. package/dist/components/input/gator/input-search/input-search.gator.js +2 -2
  30. package/dist/components/input/gator/input-text/input-text.gator.js +1 -1
  31. package/dist/components/input/gator/input-time/input-time.gator.js +2 -2
  32. package/dist/components/list/gator/list/list.gator.js +2 -2
  33. package/dist/components/list/gator/list-item/list-item.gator.js +6 -6
  34. package/dist/components/menu/base/gator/menu.gator.js +3 -3
  35. package/dist/components/menu/base/slds/menu.slds.js +2 -2
  36. package/dist/components/menu/menu-item/gator/menu-item.gator.js +2 -2
  37. package/dist/components/menu/menu-submenu/menu-submenu.js +1 -1
  38. package/dist/components/modal/gator/modal.gator.js +38 -39
  39. package/dist/components/page-header/gator/page-header.gator.js +2 -2
  40. package/dist/components/panel/gator/panel.gator.js +13 -13
  41. package/dist/components/panel/gator/panel.storybook-test.js +1 -1
  42. package/dist/components/pill/pill.slds.js +3 -3
  43. package/dist/components/popover/gator/popover.gator.js +10 -10
  44. package/dist/components/popover/popover.js +1 -1
  45. package/dist/components/radio/radio.gator.js +2 -2
  46. package/dist/components/radio-group/radio-group.gator.js +2 -2
  47. package/dist/components/selection-box-group/selection-box-group.gator.js +5 -5
  48. package/dist/components/selector/gator/selector.gator.js +2 -2
  49. package/dist/components/switch/gator/switch.gator.js +2 -2
  50. package/dist/components/tabs/gator/tabset/tabset.gator.js +3 -3
  51. package/dist/components/text-detail/gator/text-detail.gator.js +17 -18
  52. package/dist/components/time-picker/gator/time-picker.gator.js +19 -19
  53. package/dist/components/tooltip/tooltip.js +1 -1
  54. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-autosave@45.2.1/node_modules/@ckeditor/ckeditor5-autosave/dist/index.js +2 -2
  55. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-basic-styles@45.2.1/node_modules/@ckeditor/ckeditor5-basic-styles/dist/index.js +2 -2
  56. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-clipboard@45.2.1/node_modules/@ckeditor/ckeditor5-clipboard/dist/index.js +10 -10
  57. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-cloud-services@45.2.1/node_modules/@ckeditor/ckeditor5-cloud-services/dist/index.js +2 -2
  58. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-code-block@45.2.1/node_modules/@ckeditor/ckeditor5-code-block/dist/index.js +5 -5
  59. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-core@45.2.1/node_modules/@ckeditor/ckeditor5-core/dist/index.js +2 -2
  60. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-editor-classic@45.2.1/node_modules/@ckeditor/ckeditor5-editor-classic/dist/index.js +2 -2
  61. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-engine@45.2.1/node_modules/@ckeditor/ckeditor5-engine/dist/index.js +12 -12
  62. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-find-and-replace@45.2.1/node_modules/@ckeditor/ckeditor5-find-and-replace/dist/index.js +3 -3
  63. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-font@45.2.1/node_modules/@ckeditor/ckeditor5-font/dist/index.js +3 -3
  64. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-heading@45.2.1/node_modules/@ckeditor/ckeditor5-heading/dist/index.js +3 -3
  65. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-html-embed@45.2.1/node_modules/@ckeditor/ckeditor5-html-embed/dist/index.js +2 -2
  66. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-html-support@45.2.1/node_modules/@ckeditor/ckeditor5-html-support/dist/index.js +6 -6
  67. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-image@45.2.1/node_modules/@ckeditor/ckeditor5-image/dist/index.js +4 -4
  68. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-indent@45.2.1/node_modules/@ckeditor/ckeditor5-indent/dist/index.js +4 -4
  69. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-link@45.2.1/node_modules/@ckeditor/ckeditor5-link/dist/index.js +2 -2
  70. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-list@45.2.1/node_modules/@ckeditor/ckeditor5-list/dist/index.js +5 -5
  71. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-markdown-gfm@45.2.1/node_modules/@ckeditor/ckeditor5-markdown-gfm/dist/index.js +4 -4
  72. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-media-embed@45.2.1/node_modules/@ckeditor/ckeditor5-media-embed/dist/index.js +2 -2
  73. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-paragraph@45.2.1/node_modules/@ckeditor/ckeditor5-paragraph/dist/index.js +2 -2
  74. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-paste-from-office@45.2.1/node_modules/@ckeditor/ckeditor5-paste-from-office/dist/index.js +9 -9
  75. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-source-editing@45.2.1/node_modules/@ckeditor/ckeditor5-source-editing/dist/index.js +2 -2
  76. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-special-characters@45.2.1/node_modules/@ckeditor/ckeditor5-special-characters/dist/index.js +2 -2
  77. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-style@45.2.1/node_modules/@ckeditor/ckeditor5-style/dist/index.js +2 -2
  78. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-table@45.2.1/node_modules/@ckeditor/ckeditor5-table/dist/index.js +6 -6
  79. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-typing@45.2.1/node_modules/@ckeditor/ckeditor5-typing/dist/index.js +4 -4
  80. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-ui@45.2.1/node_modules/@ckeditor/ckeditor5-ui/dist/index.js +10 -10
  81. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-undo@45.2.1/node_modules/@ckeditor/ckeditor5-undo/dist/index.js +2 -2
  82. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-upload@45.2.1/node_modules/@ckeditor/ckeditor5-upload/dist/index.js +2 -2
  83. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-utils@45.2.1/node_modules/@ckeditor/ckeditor5-utils/dist/index.js +38 -38
  84. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-watchdog@45.2.1/node_modules/@ckeditor/ckeditor5-watchdog/dist/index.js +3 -3
  85. package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-widget@45.2.1/node_modules/@ckeditor/ckeditor5-widget/dist/index.js +2 -2
  86. package/dist/node_modules/.pnpm/@deltablot_dropzone@7.3.1/node_modules/@deltablot/dropzone/dist/dropzone.js +1 -1
  87. package/dist/node_modules/.pnpm/@fastify_busboy@2.1.1/node_modules/@fastify/busboy/lib/main.js +1 -1
  88. package/dist/node_modules/.pnpm/@figma_code-connect@1.3.4/node_modules/@figma/code-connect/dist/common/fetch.js +1 -0
  89. package/dist/node_modules/.pnpm/@figma_code-connect@1.3.4/node_modules/@figma/code-connect/dist/connect/figma_rest_api.js +1 -0
  90. package/dist/node_modules/.pnpm/{@figma_code-connect@1.3.3 → @figma_code-connect@1.3.4}/node_modules/@figma/code-connect/dist/connect/helpers.js +1 -1
  91. package/dist/node_modules/.pnpm/@figma_code-connect@1.3.4/node_modules/@figma/code-connect/package.json.js +1 -0
  92. package/dist/node_modules/.pnpm/@floating-ui_dom@1.7.2/node_modules/@floating-ui/dom/dist/floating-ui.dom.js +1 -1
  93. package/dist/node_modules/.pnpm/@lit_reactive-element@2.1.0/node_modules/@lit/reactive-element/reactive-element.js +2 -2
  94. package/dist/node_modules/.pnpm/@storybook_core@8.6.14_prettier@3.6.2_storybook@8.6.14_prettier@3.6.2_/node_modules/@storybook/core/dist/channels/index.js +9 -9
  95. package/dist/node_modules/.pnpm/@storybook_core@8.6.14_prettier@3.6.2_storybook@8.6.14_prettier@3.6.2_/node_modules/@storybook/core/dist/csf/index.js +1 -1
  96. package/dist/node_modules/.pnpm/@storybook_core@8.6.14_prettier@3.6.2_storybook@8.6.14_prettier@3.6.2_/node_modules/@storybook/core/dist/preview-api/index.js +22 -22
  97. package/dist/node_modules/.pnpm/@storybook_instrumenter@8.6.14_storybook@8.6.14_prettier@3.6.2_/node_modules/@storybook/instrumenter/dist/index.js +36 -36
  98. package/dist/node_modules/.pnpm/@storybook_test@8.6.14_storybook@8.6.14_prettier@3.6.2_/node_modules/@storybook/test/dist/index.js +111 -111
  99. package/dist/node_modules/.pnpm/@vitest_browser@3.2.4_msw@2.7.3_@types_node@24.0.10_typescript@5.8.3__playwright@1.53.2_77c47ac19cbe97978028e1e5ac862536/node_modules/@vitest/browser/context.js +1 -0
  100. package/dist/node_modules/.pnpm/@vitest_expect@3.2.4/node_modules/@vitest/expect/dist/index.js +8 -8
  101. package/dist/node_modules/.pnpm/@vitest_pretty-format@3.2.4/node_modules/@vitest/pretty-format/dist/index.js +2 -2
  102. package/dist/node_modules/.pnpm/@vitest_runner@3.2.4/node_modules/@vitest/runner/dist/chunk-hooks.js +5 -5
  103. package/dist/node_modules/.pnpm/@vitest_snapshot@3.2.4/node_modules/@vitest/snapshot/dist/index.js +11 -11
  104. package/dist/node_modules/.pnpm/@vitest_utils@3.2.4/node_modules/@vitest/utils/dist/diff.js +21 -21
  105. package/dist/node_modules/.pnpm/@vitest_utils@3.2.4/node_modules/@vitest/utils/dist/error.js +2 -2
  106. package/dist/node_modules/.pnpm/axe-core@4.10.3/node_modules/axe-core/axe.js +4 -4
  107. package/dist/node_modules/.pnpm/chai@5.2.0/node_modules/chai/chai.js +3 -3
  108. package/dist/node_modules/.pnpm/es-toolkit@1.32.0/node_modules/es-toolkit/dist/compat/_internal/isPrototype.js +1 -1
  109. package/dist/node_modules/.pnpm/es-toolkit@1.32.0/node_modules/es-toolkit/dist/compat/object/cloneDeepWith.js +1 -1
  110. package/dist/node_modules/.pnpm/es-toolkit@1.32.0/node_modules/es-toolkit/dist/compat/object/get.js +1 -1
  111. package/dist/node_modules/.pnpm/es-toolkit@1.32.0/node_modules/es-toolkit/dist/compat/object/unset.js +1 -1
  112. package/dist/node_modules/.pnpm/es-toolkit@1.32.0/node_modules/es-toolkit/dist/compat/predicate/isPlainObject.js +1 -1
  113. package/dist/node_modules/.pnpm/es-toolkit@1.32.0/node_modules/es-toolkit/dist/function/debounce.js +1 -1
  114. package/dist/node_modules/.pnpm/es-toolkit@1.32.0/node_modules/es-toolkit/dist/object/cloneDeepWith.js +1 -1
  115. package/dist/node_modules/.pnpm/lit-element@4.2.0/node_modules/lit-element/lit-element.js +2 -2
  116. package/dist/node_modules/.pnpm/lit-html@3.3.0/node_modules/lit-html/async-directive.js +1 -1
  117. package/dist/node_modules/.pnpm/lit-html@3.3.0/node_modules/lit-html/directives/class-map.js +2 -2
  118. package/dist/node_modules/.pnpm/lit-html@3.3.0/node_modules/lit-html/directives/ref.js +2 -2
  119. package/dist/node_modules/.pnpm/lit-html@3.3.0/node_modules/lit-html/lit-html.js +3 -3
  120. package/dist/node_modules/.pnpm/tinyrainbow@2.0.0/node_modules/tinyrainbow/dist/chunk-BVHSVHOK.js +1 -1
  121. package/dist/node_modules/.pnpm/undici@5.29.0/node_modules/undici/lib/cache/cache.js +1 -1
  122. package/dist/node_modules/.pnpm/undici@5.29.0/node_modules/undici/lib/cache/cachestorage.js +1 -1
  123. package/dist/node_modules/.pnpm/undici@5.29.0/node_modules/undici/lib/cookies/parse.js +1 -1
  124. package/dist/node_modules/.pnpm/undici@5.29.0/node_modules/undici/lib/fetch/constants.js +1 -1
  125. package/dist/node_modules/.pnpm/undici@5.29.0/node_modules/undici/lib/fetch/headers.js +1 -1
  126. package/dist/node_modules/.pnpm/undici@5.29.0/node_modules/undici/lib/fetch/index.js +1 -1
  127. package/dist/node_modules/.pnpm/undici@5.29.0/node_modules/undici/lib/fetch/request.js +1 -1
  128. package/dist/node_modules/.pnpm/undici@5.29.0/node_modules/undici/lib/fetch/response.js +1 -1
  129. package/dist/node_modules/.pnpm/undici@5.29.0/node_modules/undici/lib/fetch/util.js +2 -2
  130. package/dist/node_modules/.pnpm/undici@5.29.0/node_modules/undici/lib/fetch/webidl.js +1 -1
  131. package/dist/node_modules/.pnpm/undici@5.29.0/node_modules/undici/lib/websocket/connection.js +1 -1
  132. package/dist/node_modules/.pnpm/undici@5.29.0/node_modules/undici/lib/websocket/events.js +1 -1
  133. package/dist/node_modules/.pnpm/undici@5.29.0/node_modules/undici/lib/websocket/frame.js +1 -1
  134. package/dist/node_modules/.pnpm/undici@5.29.0/node_modules/undici/lib/websocket/receiver.js +1 -1
  135. package/dist/node_modules/.pnpm/undici@5.29.0/node_modules/undici/lib/websocket/util.js +1 -1
  136. package/dist/node_modules/.pnpm/undici@5.29.0/node_modules/undici/lib/websocket/websocket.js +1 -1
  137. package/dist/node_modules/.pnpm/vitest@3.2.4_@types_debug@4.1.12_@types_node@24.0.10_@vitest_browser@3.2.4_@vitest_ui@3_8c34ee540b1f52c214debce201d1e515/node_modules/vitest/dist/chunks/utils.XdZDrNZV.js +1 -1
  138. package/dist/node_modules/.pnpm/vitest@3.2.4_@types_debug@4.1.12_@types_node@24.0.10_@vitest_browser@3.2.4_@vitest_ui@3_8c34ee540b1f52c214debce201d1e515/node_modules/vitest/dist/chunks/vi.bdSIJ99Y.js +8 -8
  139. package/dist/packages/web-components/src/components/button/gator/button.gator.scss.js +1 -1
  140. package/dist/packages/web-components/src/components/chip/gator/chip.gator.scss.js +1 -1
  141. package/dist/packages/web-components/src/components/modal/gator/modal.gator.scss.js +1 -1
  142. package/dist/packages/web-components/src/components/switch/gator/switch.gator.scss.js +1 -1
  143. package/dist/packages/web-components/src/components/text-detail/gator/text-detail.gator.scss.js +1 -1
  144. package/dist/packages/web-components/src/index.slds.scss.js +1 -1
  145. package/dist/types/components/modal/gator/modal.gator.d.ts +1 -1
  146. package/dist/types/components/text-detail/gator/text-detail.gator.d.ts +4 -2
  147. package/dist/utils/accessibility-utils.js +1 -1
  148. package/dist/utils/datatestid-utils.js +1 -1
  149. package/dist/utils/lightdom-utils.js +1 -1
  150. package/dist/utils/vitest-a11y-utils.js +1 -1
  151. package/dist/utils/vitest-utils.js +1 -1
  152. package/package.json +10 -10
  153. package/web-types.json +2 -3
  154. package/dist/node_modules/.pnpm/@figma_code-connect@1.3.3/node_modules/@figma/code-connect/dist/common/fetch.js +0 -1
  155. package/dist/node_modules/.pnpm/@figma_code-connect@1.3.3/node_modules/@figma/code-connect/dist/connect/figma_rest_api.js +0 -1
  156. package/dist/node_modules/.pnpm/@figma_code-connect@1.3.3/node_modules/@figma/code-connect/package.json.js +0 -1
  157. package/dist/node_modules/.pnpm/@vitest_browser@3.2.4_msw@2.7.3_@types_node@24.0.10_typescript@5.8.3__playwright@1.53.1_5fd2997ee9a97429a51e07bc2023c338/node_modules/@vitest/browser/context.js +0 -1
  158. /package/dist/node_modules/.pnpm/{@figma_code-connect@1.3.3 → @figma_code-connect@1.3.4}/node_modules/@figma/code-connect/dist/client/external.js +0 -0
  159. /package/dist/node_modules/.pnpm/{@figma_code-connect@1.3.3 → @figma_code-connect@1.3.4}/node_modules/@figma/code-connect/dist/client/figma_client.js +0 -0
  160. /package/dist/node_modules/.pnpm/{@figma_code-connect@1.3.3 → @figma_code-connect@1.3.4}/node_modules/@figma/code-connect/dist/common/logging.js +0 -0
  161. /package/dist/node_modules/.pnpm/{@figma_code-connect@1.3.3 → @figma_code-connect@1.3.4}/node_modules/@figma/code-connect/dist/common/updates.js +0 -0
  162. /package/dist/node_modules/.pnpm/{@figma_code-connect@1.3.3 → @figma_code-connect@1.3.4}/node_modules/@figma/code-connect/dist/connect/external_types.js +0 -0
  163. /package/dist/node_modules/.pnpm/{@figma_code-connect@1.3.3 → @figma_code-connect@1.3.4}/node_modules/@figma/code-connect/dist/connect/index_common.js +0 -0
  164. /package/dist/node_modules/.pnpm/{@figma_code-connect@1.3.3 → @figma_code-connect@1.3.4}/node_modules/@figma/code-connect/dist/html/external.js +0 -0
  165. /package/dist/node_modules/.pnpm/{@figma_code-connect@1.3.3 → @figma_code-connect@1.3.4}/node_modules/@figma/code-connect/dist/html/index_html.js +0 -0
  166. /package/dist/node_modules/.pnpm/{@figma_code-connect@1.3.3 → @figma_code-connect@1.3.4}/node_modules/@figma/code-connect/dist/html/template_literal.js +0 -0
  167. /package/dist/node_modules/.pnpm/{@figma_code-connect@1.3.3 → @figma_code-connect@1.3.4}/node_modules/@figma/code-connect/dist/react/external.js +0 -0
  168. /package/dist/node_modules/.pnpm/{@figma_code-connect@1.3.3 → @figma_code-connect@1.3.4}/node_modules/@figma/code-connect/dist/react/index_react.js +0 -0
@@ -1,27 +1,27 @@
1
1
  const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["node_modules/.pnpm/magic-string@0.30.17/node_modules/magic-string/dist/magic-string.es.js","_virtual/sourcemap-codec.umd.js","node_modules/.pnpm/@jridgewell_sourcemap-codec@1.5.0/node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.umd.js","_virtual/sourcemap-codec.umd2.js"])))=>i.map(i=>d[i]);
2
- var $e=Object.defineProperty;var ke=(t,e,n)=>e in t?$e(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n;var y=(t,e,n)=>ke(t,typeof e!="symbol"?e+"":e,n);import{__vitePreload as Ne}from"../../../../../../../_virtual/preload-helper.js";import{format as Pe,plugins as Re}from"../../../../../@vitest_pretty-format@3.2.4/node_modules/@vitest/pretty-format/dist/index.js";import{r as Ce}from"../../../../../pathe@2.0.3/node_modules/pathe/dist/shared/pathe.M-eThtNZ.js";const Te=44,ee="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Oe=new Uint8Array(64),ge=new Uint8Array(128);for(let t=0;t<ee.length;t++){const e=ee.charCodeAt(t);Oe[t]=e,ge[e]=t}function F(t,e){let n=0,s=0,i=0;do{const a=t.next();i=ge[a],n|=(i&31)<<s,s+=5}while(i&32);const r=n&1;return n>>>=1,r&&(n=-2147483648|-n),e+n}function te(t,e){return t.pos>=e?!1:t.peek()!==Te}class Ae{constructor(e){this.pos=0,this.buffer=e}next(){return this.buffer.charCodeAt(this.pos++)}peek(){return this.buffer.charCodeAt(this.pos)}indexOf(e){const{buffer:n,pos:s}=this,i=n.indexOf(e,s);return i===-1?n.length:i}}function Me(t){const{length:e}=t,n=new Ae(t),s=[];let i=0,r=0,a=0,l=0,o=0;do{const c=n.indexOf(";"),d=[];let p=!0,u=0;for(i=0;n.pos<c;){let S;i=F(n,i),i<u&&(p=!1),u=i,te(n,c)?(r=F(n,r),a=F(n,a),l=F(n,l),te(n,c)?(o=F(n,o),S=[i,r,a,l,o]):S=[i,r,a,l]):S=[i],d.push(S),n.pos++}p||Fe(d),s.push(d),n.pos=c+1}while(n.pos<=e);return s}function Fe(t){t.sort(Le)}function Le(t,e){return t[0]-e[0]}const Be=/^[\w+.-]+:\/\//,De=/^([\w+.-]+:)\/\/([^@/#?]*@)?([^:/#?]*)(:\d+)?(\/[^#?]*)?(\?[^#]*)?(#.*)?/,Je=/^file:(?:\/\/((?![a-z]:)[^/#?]*)?)?(\/?[^#?]*)(\?[^#]*)?(#.*)?/i;var v;(function(t){t[t.Empty=1]="Empty",t[t.Hash=2]="Hash",t[t.Query=3]="Query",t[t.RelativePath=4]="RelativePath",t[t.AbsolutePath=5]="AbsolutePath",t[t.SchemeRelative=6]="SchemeRelative",t[t.Absolute=7]="Absolute"})(v||(v={}));function Xe(t){return Be.test(t)}function je(t){return t.startsWith("//")}function Se(t){return t.startsWith("/")}function We(t){return t.startsWith("file:")}function ne(t){return/^[.?#]/.test(t)}function B(t){const e=De.exec(t);return _e(e[1],e[2]||"",e[3],e[4]||"",e[5]||"/",e[6]||"",e[7]||"")}function Ke(t){const e=Je.exec(t),n=e[2];return _e("file:","",e[1]||"","",Se(n)?n:"/"+n,e[3]||"",e[4]||"")}function _e(t,e,n,s,i,r,a){return{scheme:t,user:e,host:n,port:s,path:i,query:r,hash:a,type:v.Absolute}}function se(t){if(je(t)){const n=B("http:"+t);return n.scheme="",n.type=v.SchemeRelative,n}if(Se(t)){const n=B("http://foo.com"+t);return n.scheme="",n.host="",n.type=v.AbsolutePath,n}if(We(t))return Ke(t);if(Xe(t))return B(t);const e=B("http://foo.com/"+t);return e.scheme="",e.host="",e.type=t?t.startsWith("?")?v.Query:t.startsWith("#")?v.Hash:v.RelativePath:v.Empty,e}function Ue(t){if(t.endsWith("/.."))return t;const e=t.lastIndexOf("/");return t.slice(0,e+1)}function qe(t,e){ye(e,e.type),t.path==="/"?t.path=e.path:t.path=Ue(e.path)+t.path}function ye(t,e){const n=e<=v.RelativePath,s=t.path.split("/");let i=1,r=0,a=!1;for(let o=1;o<s.length;o++){const c=s[o];if(!c){a=!0;continue}if(a=!1,c!=="."){if(c===".."){r?(a=!0,r--,i--):n&&(s[i++]=c);continue}s[i++]=c,r++}}let l="";for(let o=1;o<i;o++)l+="/"+s[o];(!l||a&&!l.endsWith("/.."))&&(l+="/"),t.path=l}function ze(t,e){if(!t&&!e)return"";const n=se(t);let s=n.type;if(e&&s!==v.Absolute){const r=se(e),a=r.type;switch(s){case v.Empty:n.hash=r.hash;case v.Hash:n.query=r.query;case v.Query:case v.RelativePath:qe(n,r);case v.AbsolutePath:n.user=r.user,n.host=r.host,n.port=r.port;case v.SchemeRelative:n.scheme=r.scheme}a>s&&(s=a)}ye(n,s);const i=n.query+n.hash;switch(s){case v.Hash:case v.Query:return i;case v.RelativePath:{const r=n.path.slice(1);return r?ne(e||t)&&!ne(r)?"./"+r+i:r+i:i||"."}case v.AbsolutePath:return n.path+i;default:return n.scheme+"//"+n.user+n.host+n.port+n.path+i}}function ie(t,e){return e&&!e.endsWith("/")&&(e+="/"),ze(t,e)}function He(t){if(!t)return"";const e=t.lastIndexOf("/");return t.slice(0,e+1)}const C=0,Ge=1,Ve=2,Qe=3,Ze=4;function Ye(t,e){const n=re(t,0);if(n===t.length)return t;e||(t=t.slice());for(let s=n;s<t.length;s=re(t,s+1))t[s]=tt(t[s],e);return t}function re(t,e){for(let n=e;n<t.length;n++)if(!et(t[n]))return n;return t.length}function et(t){for(let e=1;e<t.length;e++)if(t[e][C]<t[e-1][C])return!1;return!0}function tt(t,e){return e||(t=t.slice()),t.sort(nt)}function nt(t,e){return t[C]-e[C]}let X=!1;function st(t,e,n,s){for(;n<=s;){const i=n+(s-n>>1),r=t[i][C]-e;if(r===0)return X=!0,i;r<0?n=i+1:s=i-1}return X=!1,n-1}function it(t,e,n){for(let s=n+1;s<t.length&&t[s][C]===e;n=s++);return n}function rt(t,e,n){for(let s=n-1;s>=0&&t[s][C]===e;n=s--);return n}function at(){return{lastKey:-1,lastNeedle:-1,lastIndex:-1}}function ot(t,e,n,s){const{lastKey:i,lastNeedle:r,lastIndex:a}=n;let l=0,o=t.length-1;if(s===i){if(e===r)return X=a!==-1&&t[a][C]===e,a;e>=r?l=a===-1?0:a:o=a}return n.lastKey=s,n.lastNeedle=e,n.lastIndex=st(t,e,l,o)}const lt="`line` must be greater than 0 (lines start at line 1)",ct="`column` must be greater than or equal to 0 (columns start at column 0)",ae=-1,ut=1;class ht{constructor(e,n){const s=typeof e=="string";if(!s&&e._decodedMemo)return e;const i=s?JSON.parse(e):e,{version:r,file:a,names:l,sourceRoot:o,sources:c,sourcesContent:d}=i;this.version=r,this.file=a,this.names=l||[],this.sourceRoot=o,this.sources=c,this.sourcesContent=d,this.ignoreList=i.ignoreList||i.x_google_ignoreList||void 0;const p=ie(o||"",He(n));this.resolvedSources=c.map(S=>ie(S||"",p));const{mappings:u}=i;typeof u=="string"?(this._encoded=u,this._decoded=void 0):(this._encoded=void 0,this._decoded=Ye(u,s)),this._decodedMemo=at(),this._bySources=void 0,this._bySourceMemos=void 0}}function dt(t){var e;return(e=t)._decoded||(e._decoded=Me(t._encoded))}function ft(t,e){let{line:n,column:s,bias:i}=e;if(n--,n<0)throw new Error(lt);if(s<0)throw new Error(ct);const r=dt(t);if(n>=r.length)return D(null,null,null,null);const a=r[n],l=pt(a,t._decodedMemo,n,s,i||ut);if(l===-1)return D(null,null,null,null);const o=a[l];if(o.length===1)return D(null,null,null,null);const{names:c,resolvedSources:d}=t;return D(d[o[Ge]],o[Ve]+1,o[Qe],o.length===5?c[o[Ze]]:null)}function D(t,e,n,s){return{source:t,line:e,column:n,name:s}}function pt(t,e,n,s,i){let r=ot(t,s,e,n);return X?r=(i===ae?it:rt)(t,s,r):i===ae&&r++,r===-1||r===t.length?-1:r}function ve(t){return t!=null}function mt(t){return t===null||typeof t!="function"&&typeof t!="object"}function J(t){return t!=null&&typeof t=="object"&&!Array.isArray(t)}function gt(t){let e=-1,n=null,s=0,i=0,r=null;for(;e<=t.length;){r=t[e],e++;const a=t[e];if((a==='"'||a==="'"||a==="`")&&r!=="\\"&&(n===a?n=null:n||(n=a)),n||(a==="("&&s++,a===")"&&i++),s&&i&&s===i)return e}return null}const xe=/^\s*at .*(?:\S:\d+|\(native\))/m,St=/^(?:eval@)?(?:\[native code\])?$/,_t=["node:internal",/\/packages\/\w+\/dist\//,/\/@vitest\/\w+\/dist\//,"/vitest/dist/","/vitest/src/","/vite-node/dist/","/vite-node/src/","/node_modules/chai/","/node_modules/tinypool/","/node_modules/tinyspy/","/deps/chunk-","/deps/@vitest","/deps/loupe","/deps/chai",/node:\w+/,/__vitest_test__/,/__vitest_browser__/,/\/deps\/vitest_/];function we(t){if(!t.includes(":"))return[t];const n=/(.+?)(?::(\d+))?(?::(\d+))?$/.exec(t.replace(/^\(|\)$/g,""));if(!n)return[t];let s=n[1];if(s.startsWith("async ")&&(s=s.slice(6)),s.startsWith("http:")||s.startsWith("https:")){const i=new URL(s);i.searchParams.delete("import"),i.searchParams.delete("browserv"),s=i.pathname+i.hash+i.search}if(s.startsWith("/@fs/")){const i=/^\/@fs\/[a-zA-Z]:\//.test(s);s=s.slice(i?5:4)}return[s,n[2]||void 0,n[3]||void 0]}function yt(t){let e=t.trim();if(St.test(e)||(e.includes(" > eval")&&(e=e.replace(/ line (\d+)(?: > eval line \d+)* > eval:\d+:\d+/g,":$1")),!e.includes("@")&&!e.includes(":")))return null;const n=/((.*".+"[^@]*)?[^@]*)(@)/,s=e.match(n),i=s&&s[1]?s[1]:void 0,[r,a,l]=we(e.replace(n,""));return!r||!a||!l?null:{file:r,method:i||"",line:Number.parseInt(a),column:Number.parseInt(l)}}function vt(t){let e=t.trim();if(!xe.test(e))return null;e.includes("(eval ")&&(e=e.replace(/eval code/g,"eval").replace(/(\(eval at [^()]*)|(,.*$)/g,""));let n=e.replace(/^\s+/,"").replace(/\(eval code/g,"(").replace(/^.*?\s+/,"");const s=n.match(/ (\(.+\)$)/);n=s?n.replace(s[0],""):n;const[i,r,a]=we(s?s[1]:n);let l=s&&n||"",o=i&&["eval","<anonymous>"].includes(i)?void 0:i;return!o||!r||!a?null:(l.startsWith("async ")&&(l=l.slice(6)),o.startsWith("file://")&&(o=o.slice(7)),o=o.startsWith("node:")||o.startsWith("internal:")?o:Ce(o),l&&(l=l.replace(/__vite_ssr_import_\d+__\./g,"")),{method:l,file:o,line:Number.parseInt(r),column:Number.parseInt(a)})}function j(t,e={}){const{ignoreStackEntries:n=_t}=e;return(xe.test(t)?wt(t):xt(t)).map(i=>{var r;e.getUrlId&&(i.file=e.getUrlId(i.file));const a=(r=e.getSourceMap)===null||r===void 0?void 0:r.call(e,i.file);if(!a||typeof a!="object"||!a.version)return oe(n,i.file)?null:i;const l=new ht(a),{line:o,column:c,source:d,name:p}=ft(l,i);let u=i.file;if(d){const S=i.file.startsWith("file://")?i.file:`file://${i.file}`,I=a.sourceRoot?new URL(a.sourceRoot,S):S;u=new URL(d,I).pathname,u.match(/\/\w:\//)&&(u=u.slice(1))}return oe(n,u)?null:o!=null&&c!=null?{line:o,column:c,file:u,method:p||i.method}:i}).filter(i=>i!=null)}function oe(t,e){return t.some(n=>e.match(n))}function xt(t){return t.split(`
3
- `).map(e=>yt(e)).filter(ve)}function wt(t){return t.split(`
4
- `).map(e=>vt(e)).filter(ve)}function It(t,e={}){if(!t||mt(t))return[];if(t.stacks)return t.stacks;const n=t.stack||"";let s=typeof n=="string"?j(n,e):[];if(!s.length){const i=t;i.fileName!=null&&i.lineNumber!=null&&i.columnNumber!=null&&(s=j(`${i.fileName}:${i.lineNumber}:${i.columnNumber}`,e)),i.sourceURL!=null&&i.line!=null&&i._column!=null&&(s=j(`${i.sourceURL}:${i.line}:${i.column}`,e))}return e.frameFilter&&(s=s.filter(i=>e.frameFilter(t,i)!==!1)),t.stacks=s,s}let Et=()=>"Promise{…}";try{const{getPromiseDetails:t,kPending:e,kRejected:n}=process.binding("util");Array.isArray(t(Promise.resolve()))&&(Et=(s,i)=>{const[r,a]=t(s);return r===e?"Promise{<pending>}":`Promise${r===n?"!":""}{${i.inspect(a,i)}}`})}catch{}function bt(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var W,le;function $t(){if(le)return W;le=1;var t,e,n,s,i,r,a,l,o,c,d,p,u,S,I,b,$,E,k;return u=/\/(?![*\/])(?:\[(?:(?![\]\\]).|\\.)*\]|(?![\/\\]).|\\.)*(\/[$_\u200C\u200D\p{ID_Continue}]*|\\)?/yu,p=/--|\+\+|=>|\.{3}|\??\.(?!\d)|(?:&&|\|\||\?\?|[+\-%&|^]|\*{1,2}|<{1,2}|>{1,3}|!=?|={1,2}|\/(?![\/*]))=?|[?~,:;[\](){}]/y,t=/(\x23?)(?=[$_\p{ID_Start}\\])(?:[$_\u200C\u200D\p{ID_Continue}]|\\u[\da-fA-F]{4}|\\u\{[\da-fA-F]+\})+/yu,I=/(['"])(?:(?!\1)[^\\\n\r]|\\(?:\r\n|[^]))*(\1)?/y,d=/(?:0[xX][\da-fA-F](?:_?[\da-fA-F])*|0[oO][0-7](?:_?[0-7])*|0[bB][01](?:_?[01])*)n?|0n|[1-9](?:_?\d)*n|(?:(?:0(?!\d)|0\d*[89]\d*|[1-9](?:_?\d)*)(?:\.(?:\d(?:_?\d)*)?)?|\.\d(?:_?\d)*)(?:[eE][+-]?\d(?:_?\d)*)?|0[0-7]+/y,b=/[`}](?:[^`\\$]|\\[^]|\$(?!\{))*(`|\$\{)?/y,k=/[\t\v\f\ufeff\p{Zs}]+/yu,l=/\r?\n|[\r\u2028\u2029]/y,o=/\/\*(?:[^*]|\*(?!\/))*(\*\/)?/y,S=/\/\/.*/y,n=/[<>.:={}]|\/(?![\/*])/y,e=/[$_\p{ID_Start}][$_\u200C\u200D\p{ID_Continue}-]*/yu,s=/(['"])(?:(?!\1)[^])*(\1)?/y,i=/[^<>{}]+/y,E=/^(?:[\/+-]|\.{3}|\?(?:InterpolationIn(?:JSX|Template)|NoLineTerminatorHere|NonExpressionParenEnd|UnaryIncDec))?$|[{}([,;<>=*%&|^!~?:]$/,$=/^(?:=>|[;\]){}]|else|\?(?:NoLineTerminatorHere|NonExpressionParenEnd))?$/,r=/^(?:await|case|default|delete|do|else|instanceof|new|return|throw|typeof|void|yield)$/,a=/^(?:return|throw|yield)$/,c=RegExp(l.source),W=function*(_,{jsx:T=!1}={}){var w,P,O,f,m,Z,h,R,Y,N,A,g,M,x;for({length:Z}=_,f=0,m="",x=[{tag:"JS"}],w=[],A=0,g=!1;f<Z;){switch(R=x[x.length-1],R.tag){case"JS":case"JSNonExpressionParen":case"InterpolationInTemplate":case"InterpolationInJSX":if(_[f]==="/"&&(E.test(m)||r.test(m))&&(u.lastIndex=f,h=u.exec(_))){f=u.lastIndex,m=h[0],g=!0,yield{type:"RegularExpressionLiteral",value:h[0],closed:h[1]!==void 0&&h[1]!=="\\"};continue}if(p.lastIndex=f,h=p.exec(_)){switch(M=h[0],Y=p.lastIndex,N=M,M){case"(":m==="?NonExpressionParenKeyword"&&x.push({tag:"JSNonExpressionParen",nesting:A}),A++,g=!1;break;case")":A--,g=!0,R.tag==="JSNonExpressionParen"&&A===R.nesting&&(x.pop(),N="?NonExpressionParenEnd",g=!1);break;case"{":p.lastIndex=0,O=!$.test(m)&&(E.test(m)||r.test(m)),w.push(O),g=!1;break;case"}":switch(R.tag){case"InterpolationInTemplate":if(w.length===R.nesting){b.lastIndex=f,h=b.exec(_),f=b.lastIndex,m=h[0],h[1]==="${"?(m="?InterpolationInTemplate",g=!1,yield{type:"TemplateMiddle",value:h[0]}):(x.pop(),g=!0,yield{type:"TemplateTail",value:h[0],closed:h[1]==="`"});continue}break;case"InterpolationInJSX":if(w.length===R.nesting){x.pop(),f+=1,m="}",yield{type:"JSXPunctuator",value:"}"};continue}}g=w.pop(),N=g?"?ExpressionBraceEnd":"}";break;case"]":g=!0;break;case"++":case"--":N=g?"?PostfixIncDec":"?UnaryIncDec";break;case"<":if(T&&(E.test(m)||r.test(m))){x.push({tag:"JSXTag"}),f+=1,m="<",yield{type:"JSXPunctuator",value:M};continue}g=!1;break;default:g=!1}f=Y,m=N,yield{type:"Punctuator",value:M};continue}if(t.lastIndex=f,h=t.exec(_)){switch(f=t.lastIndex,N=h[0],h[0]){case"for":case"if":case"while":case"with":m!=="."&&m!=="?."&&(N="?NonExpressionParenKeyword")}m=N,g=!r.test(h[0]),yield{type:h[1]==="#"?"PrivateIdentifier":"IdentifierName",value:h[0]};continue}if(I.lastIndex=f,h=I.exec(_)){f=I.lastIndex,m=h[0],g=!0,yield{type:"StringLiteral",value:h[0],closed:h[2]!==void 0};continue}if(d.lastIndex=f,h=d.exec(_)){f=d.lastIndex,m=h[0],g=!0,yield{type:"NumericLiteral",value:h[0]};continue}if(b.lastIndex=f,h=b.exec(_)){f=b.lastIndex,m=h[0],h[1]==="${"?(m="?InterpolationInTemplate",x.push({tag:"InterpolationInTemplate",nesting:w.length}),g=!1,yield{type:"TemplateHead",value:h[0]}):(g=!0,yield{type:"NoSubstitutionTemplate",value:h[0],closed:h[1]==="`"});continue}break;case"JSXTag":case"JSXTagEnd":if(n.lastIndex=f,h=n.exec(_)){switch(f=n.lastIndex,N=h[0],h[0]){case"<":x.push({tag:"JSXTag"});break;case">":x.pop(),m==="/"||R.tag==="JSXTagEnd"?(N="?JSX",g=!0):x.push({tag:"JSXChildren"});break;case"{":x.push({tag:"InterpolationInJSX",nesting:w.length}),N="?InterpolationInJSX",g=!1;break;case"/":m==="<"&&(x.pop(),x[x.length-1].tag==="JSXChildren"&&x.pop(),x.push({tag:"JSXTagEnd"}))}m=N,yield{type:"JSXPunctuator",value:h[0]};continue}if(e.lastIndex=f,h=e.exec(_)){f=e.lastIndex,m=h[0],yield{type:"JSXIdentifier",value:h[0]};continue}if(s.lastIndex=f,h=s.exec(_)){f=s.lastIndex,m=h[0],yield{type:"JSXString",value:h[0],closed:h[2]!==void 0};continue}break;case"JSXChildren":if(i.lastIndex=f,h=i.exec(_)){f=i.lastIndex,m=h[0],yield{type:"JSXText",value:h[0]};continue}switch(_[f]){case"<":x.push({tag:"JSXTag"}),f++,m="<",yield{type:"JSXPunctuator",value:"<"};continue;case"{":x.push({tag:"InterpolationInJSX",nesting:w.length}),f++,m="?InterpolationInJSX",g=!1,yield{type:"JSXPunctuator",value:"{"};continue}}if(k.lastIndex=f,h=k.exec(_)){f=k.lastIndex,yield{type:"WhiteSpace",value:h[0]};continue}if(l.lastIndex=f,h=l.exec(_)){f=l.lastIndex,g=!1,a.test(m)&&(m="?NoLineTerminatorHere"),yield{type:"LineTerminatorSequence",value:h[0]};continue}if(o.lastIndex=f,h=o.exec(_)){f=o.lastIndex,c.test(h[0])&&(g=!1,a.test(m)&&(m="?NoLineTerminatorHere")),yield{type:"MultiLineComment",value:h[0],closed:h[1]!==void 0};continue}if(S.lastIndex=f,h=S.exec(_)){f=S.lastIndex,g=!1,yield{type:"SingleLineComment",value:h[0]};continue}P=String.fromCodePoint(_.codePointAt(f)),f+=P.length,m=P,g=!1,yield{type:R.tag.startsWith("JSX")?"JSXInvalid":"Invalid",value:P}}},W}$t();var Ie={keyword:["break","case","catch","continue","debugger","default","do","else","finally","for","function","if","return","switch","throw","try","var","const","while","with","new","this","super","class","extends","export","import","null","true","false","in","instanceof","typeof","void","delete"],strict:["implements","interface","let","package","private","protected","public","static","yield"]};new Set(Ie.keyword);new Set(Ie.strict);var kt={reset:[0,0],bold:[1,22,"\x1B[22m\x1B[1m"],dim:[2,22,"\x1B[22m\x1B[2m"],italic:[3,23],underline:[4,24],inverse:[7,27],hidden:[8,28],strikethrough:[9,29],black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],gray:[90,39],bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],blackBright:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39],bgBlackBright:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]},Nt=Object.entries(kt);function z(t){return String(t)}z.open="";z.close="";function Pt(t=!1){let e=typeof process<"u"?process:void 0,n=(e==null?void 0:e.env)||{},s=(e==null?void 0:e.argv)||[];return!("NO_COLOR"in n||s.includes("--no-color"))&&("FORCE_COLOR"in n||s.includes("--color")||(e==null?void 0:e.platform)==="win32"||t&&n.TERM!=="dumb"||"CI"in n)||typeof window<"u"&&!!window.chrome}function Rt(t=!1){let e=Pt(t),n=(a,l,o,c)=>{let d="",p=0;do d+=a.substring(p,c)+o,p=c+l.length,c=a.indexOf(l,p);while(~c);return d+a.substring(p)},s=(a,l,o=a)=>{let c=d=>{let p=String(d),u=p.indexOf(l,a.length);return~u?a+n(p,l,o,u)+l:a+p+l};return c.open=a,c.close=l,c},i={isColorSupported:e},r=a=>`\x1B[${a}m`;for(let[a,l]of Nt)i[a]=e?s(r(l[0]),r(l[1]),l[2]):z;return i}Rt();const H=/\r?\n/;function Ct(t,e,n){const s=t.split(H),i=/\r\n/.test(t)?2:1;let r=0;if(e>s.length)return t.length;for(let a=0;a<e-1;a++)r+=s[a].length+i;return r+n}function Tt(t,e){if(e>t.length)throw new Error(`offset is longer than source length! offset ${e} > length ${t.length}`);const n=t.split(H),s=/\r\n/.test(t)?2:1;let i=0,r=0;for(;r<n.length;r++){const a=n[r].length+s;if(i+a>=e)break;i+=a}return r+1}async function Ot(t,e){const n=(await Ne(async()=>{const{default:i}=await import("../../../../../magic-string@0.30.17/node_modules/magic-string/dist/magic-string.es.js");return{default:i}},__vite__mapDeps([0,1,2,3]))).default,s=new Set(e.map(i=>i.file));await Promise.all(Array.from(s).map(async i=>{const r=e.filter(c=>c.file===i),a=await t.readSnapshotFile(i),l=new n(a);for(const c of r){const d=Ct(a,c.line,c.column);Dt(a,l,d,c.snapshot)}const o=l.toString();o!==a&&await t.saveSnapshotFile(i,o)}))}const At=/(?:toMatchInlineSnapshot|toThrowErrorMatchingInlineSnapshot)\s*\(\s*(?:\/\*[\s\S]*\*\/\s*|\/\/.*(?:[\n\r\u2028\u2029]\s*|[\t\v\f \xA0\u1680\u2000-\u200A\u202F\u205F\u3000\uFEFF]))*\{/;function Mt(t,e,n,s){let i=t.slice(n);const r=At.exec(i);if(!r)return!1;i=i.slice(r.index);let a=gt(i);if(a===null)return!1;a+=n+r.index;const l=n+r.index+r[0].length,o=Ft(t,l),c=`, ${Ee(s,t,n)}`;return o===a?e.appendLeft(a,c):e.overwrite(o,a,c),!0}function Ft(t,e){let n=1,s=0;for(;n!==s&&e<t.length;){const i=t[e++];i==="{"?n++:i==="}"&&s++}return e}function Ee(t,e,n){const s=Tt(e,n),r=e.split(H)[s-1].match(/^\s*/)[0]||"",a=r.includes(" ")?`${r} `:`${r} `,l=t.trim().replace(/\\/g,"\\\\").split(/\n/g),o=l.length<=1,c="`";return o?`${c}${l.join(`
2
+ import{__vitePreload as be}from"../../../../../../../_virtual/preload-helper.js";import{format as $e,plugins as ke}from"../../../../../@vitest_pretty-format@3.2.4/node_modules/@vitest/pretty-format/dist/index.js";import{r as Ne}from"../../../../../pathe@2.0.3/node_modules/pathe/dist/shared/pathe.M-eThtNZ.js";const Pe=44,Y="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Re=new Uint8Array(64),me=new Uint8Array(128);for(let t=0;t<Y.length;t++){const e=Y.charCodeAt(t);Re[t]=e,me[e]=t}function M(t,e){let n=0,s=0,i=0;do{const a=t.next();i=me[a],n|=(i&31)<<s,s+=5}while(i&32);const r=n&1;return n>>>=1,r&&(n=-2147483648|-n),e+n}function ee(t,e){return t.pos>=e?!1:t.peek()!==Pe}class Ce{constructor(e){this.pos=0,this.buffer=e}next(){return this.buffer.charCodeAt(this.pos++)}peek(){return this.buffer.charCodeAt(this.pos)}indexOf(e){const{buffer:n,pos:s}=this,i=n.indexOf(e,s);return i===-1?n.length:i}}function Te(t){const{length:e}=t,n=new Ce(t),s=[];let i=0,r=0,a=0,l=0,o=0;do{const c=n.indexOf(";"),d=[];let p=!0,u=0;for(i=0;n.pos<c;){let S;i=M(n,i),i<u&&(p=!1),u=i,ee(n,c)?(r=M(n,r),a=M(n,a),l=M(n,l),ee(n,c)?(o=M(n,o),S=[i,r,a,l,o]):S=[i,r,a,l]):S=[i],d.push(S),n.pos++}p||Oe(d),s.push(d),n.pos=c+1}while(n.pos<=e);return s}function Oe(t){t.sort(Ae)}function Ae(t,e){return t[0]-e[0]}const Me=/^[\w+.-]+:\/\//,Fe=/^([\w+.-]+:)\/\/([^@/#?]*@)?([^:/#?]*)(:\d+)?(\/[^#?]*)?(\?[^#]*)?(#.*)?/,Le=/^file:(?:\/\/((?![a-z]:)[^/#?]*)?)?(\/?[^#?]*)(\?[^#]*)?(#.*)?/i;var y;(function(t){t[t.Empty=1]="Empty",t[t.Hash=2]="Hash",t[t.Query=3]="Query",t[t.RelativePath=4]="RelativePath",t[t.AbsolutePath=5]="AbsolutePath",t[t.SchemeRelative=6]="SchemeRelative",t[t.Absolute=7]="Absolute"})(y||(y={}));function Be(t){return Me.test(t)}function De(t){return t.startsWith("//")}function ge(t){return t.startsWith("/")}function Je(t){return t.startsWith("file:")}function te(t){return/^[.?#]/.test(t)}function L(t){const e=Fe.exec(t);return Se(e[1],e[2]||"",e[3],e[4]||"",e[5]||"/",e[6]||"",e[7]||"")}function Xe(t){const e=Le.exec(t),n=e[2];return Se("file:","",e[1]||"","",ge(n)?n:"/"+n,e[3]||"",e[4]||"")}function Se(t,e,n,s,i,r,a){return{scheme:t,user:e,host:n,port:s,path:i,query:r,hash:a,type:y.Absolute}}function ne(t){if(De(t)){const n=L("http:"+t);return n.scheme="",n.type=y.SchemeRelative,n}if(ge(t)){const n=L("http://foo.com"+t);return n.scheme="",n.host="",n.type=y.AbsolutePath,n}if(Je(t))return Xe(t);if(Be(t))return L(t);const e=L("http://foo.com/"+t);return e.scheme="",e.host="",e.type=t?t.startsWith("?")?y.Query:t.startsWith("#")?y.Hash:y.RelativePath:y.Empty,e}function je(t){if(t.endsWith("/.."))return t;const e=t.lastIndexOf("/");return t.slice(0,e+1)}function We(t,e){_e(e,e.type),t.path==="/"?t.path=e.path:t.path=je(e.path)+t.path}function _e(t,e){const n=e<=y.RelativePath,s=t.path.split("/");let i=1,r=0,a=!1;for(let o=1;o<s.length;o++){const c=s[o];if(!c){a=!0;continue}if(a=!1,c!=="."){if(c===".."){r?(a=!0,r--,i--):n&&(s[i++]=c);continue}s[i++]=c,r++}}let l="";for(let o=1;o<i;o++)l+="/"+s[o];(!l||a&&!l.endsWith("/.."))&&(l+="/"),t.path=l}function Ke(t,e){if(!t&&!e)return"";const n=ne(t);let s=n.type;if(e&&s!==y.Absolute){const r=ne(e),a=r.type;switch(s){case y.Empty:n.hash=r.hash;case y.Hash:n.query=r.query;case y.Query:case y.RelativePath:We(n,r);case y.AbsolutePath:n.user=r.user,n.host=r.host,n.port=r.port;case y.SchemeRelative:n.scheme=r.scheme}a>s&&(s=a)}_e(n,s);const i=n.query+n.hash;switch(s){case y.Hash:case y.Query:return i;case y.RelativePath:{const r=n.path.slice(1);return r?te(e||t)&&!te(r)?"./"+r+i:r+i:i||"."}case y.AbsolutePath:return n.path+i;default:return n.scheme+"//"+n.user+n.host+n.port+n.path+i}}function se(t,e){return e&&!e.endsWith("/")&&(e+="/"),Ke(t,e)}function Ue(t){if(!t)return"";const e=t.lastIndexOf("/");return t.slice(0,e+1)}const R=0,qe=1,ze=2,He=3,Ge=4;function Ve(t,e){const n=ie(t,0);if(n===t.length)return t;e||(t=t.slice());for(let s=n;s<t.length;s=ie(t,s+1))t[s]=Ze(t[s],e);return t}function ie(t,e){for(let n=e;n<t.length;n++)if(!Qe(t[n]))return n;return t.length}function Qe(t){for(let e=1;e<t.length;e++)if(t[e][R]<t[e-1][R])return!1;return!0}function Ze(t,e){return e||(t=t.slice()),t.sort(Ye)}function Ye(t,e){return t[R]-e[R]}let J=!1;function et(t,e,n,s){for(;n<=s;){const i=n+(s-n>>1),r=t[i][R]-e;if(r===0)return J=!0,i;r<0?n=i+1:s=i-1}return J=!1,n-1}function tt(t,e,n){for(let s=n+1;s<t.length&&t[s][R]===e;n=s++);return n}function nt(t,e,n){for(let s=n-1;s>=0&&t[s][R]===e;n=s--);return n}function st(){return{lastKey:-1,lastNeedle:-1,lastIndex:-1}}function it(t,e,n,s){const{lastKey:i,lastNeedle:r,lastIndex:a}=n;let l=0,o=t.length-1;if(s===i){if(e===r)return J=a!==-1&&t[a][R]===e,a;e>=r?l=a===-1?0:a:o=a}return n.lastKey=s,n.lastNeedle=e,n.lastIndex=et(t,e,l,o)}const rt="`line` must be greater than 0 (lines start at line 1)",at="`column` must be greater than or equal to 0 (columns start at column 0)",re=-1,ot=1;class lt{constructor(e,n){const s=typeof e=="string";if(!s&&e._decodedMemo)return e;const i=s?JSON.parse(e):e,{version:r,file:a,names:l,sourceRoot:o,sources:c,sourcesContent:d}=i;this.version=r,this.file=a,this.names=l||[],this.sourceRoot=o,this.sources=c,this.sourcesContent=d,this.ignoreList=i.ignoreList||i.x_google_ignoreList||void 0;const p=se(o||"",Ue(n));this.resolvedSources=c.map(S=>se(S||"",p));const{mappings:u}=i;typeof u=="string"?(this._encoded=u,this._decoded=void 0):(this._encoded=void 0,this._decoded=Ve(u,s)),this._decodedMemo=st(),this._bySources=void 0,this._bySourceMemos=void 0}}function ct(t){var e;return(e=t)._decoded||(e._decoded=Te(t._encoded))}function ut(t,e){let{line:n,column:s,bias:i}=e;if(n--,n<0)throw new Error(rt);if(s<0)throw new Error(at);const r=ct(t);if(n>=r.length)return B(null,null,null,null);const a=r[n],l=ht(a,t._decodedMemo,n,s,i||ot);if(l===-1)return B(null,null,null,null);const o=a[l];if(o.length===1)return B(null,null,null,null);const{names:c,resolvedSources:d}=t;return B(d[o[qe]],o[ze]+1,o[He],o.length===5?c[o[Ge]]:null)}function B(t,e,n,s){return{source:t,line:e,column:n,name:s}}function ht(t,e,n,s,i){let r=it(t,s,e,n);return J?r=(i===re?tt:nt)(t,s,r):i===re&&r++,r===-1||r===t.length?-1:r}function ye(t){return t!=null}function dt(t){return t===null||typeof t!="function"&&typeof t!="object"}function D(t){return t!=null&&typeof t=="object"&&!Array.isArray(t)}function ft(t){let e=-1,n=null,s=0,i=0,r=null;for(;e<=t.length;){r=t[e],e++;const a=t[e];if((a==='"'||a==="'"||a==="`")&&r!=="\\"&&(n===a?n=null:n||(n=a)),n||(a==="("&&s++,a===")"&&i++),s&&i&&s===i)return e}return null}const ve=/^\s*at .*(?:\S:\d+|\(native\))/m,pt=/^(?:eval@)?(?:\[native code\])?$/,mt=["node:internal",/\/packages\/\w+\/dist\//,/\/@vitest\/\w+\/dist\//,"/vitest/dist/","/vitest/src/","/vite-node/dist/","/vite-node/src/","/node_modules/chai/","/node_modules/tinypool/","/node_modules/tinyspy/","/deps/chunk-","/deps/@vitest","/deps/loupe","/deps/chai",/node:\w+/,/__vitest_test__/,/__vitest_browser__/,/\/deps\/vitest_/];function xe(t){if(!t.includes(":"))return[t];const n=/(.+?)(?::(\d+))?(?::(\d+))?$/.exec(t.replace(/^\(|\)$/g,""));if(!n)return[t];let s=n[1];if(s.startsWith("async ")&&(s=s.slice(6)),s.startsWith("http:")||s.startsWith("https:")){const i=new URL(s);i.searchParams.delete("import"),i.searchParams.delete("browserv"),s=i.pathname+i.hash+i.search}if(s.startsWith("/@fs/")){const i=/^\/@fs\/[a-zA-Z]:\//.test(s);s=s.slice(i?5:4)}return[s,n[2]||void 0,n[3]||void 0]}function gt(t){let e=t.trim();if(pt.test(e)||(e.includes(" > eval")&&(e=e.replace(/ line (\d+)(?: > eval line \d+)* > eval:\d+:\d+/g,":$1")),!e.includes("@")&&!e.includes(":")))return null;const n=/((.*".+"[^@]*)?[^@]*)(@)/,s=e.match(n),i=s&&s[1]?s[1]:void 0,[r,a,l]=xe(e.replace(n,""));return!r||!a||!l?null:{file:r,method:i||"",line:Number.parseInt(a),column:Number.parseInt(l)}}function St(t){let e=t.trim();if(!ve.test(e))return null;e.includes("(eval ")&&(e=e.replace(/eval code/g,"eval").replace(/(\(eval at [^()]*)|(,.*$)/g,""));let n=e.replace(/^\s+/,"").replace(/\(eval code/g,"(").replace(/^.*?\s+/,"");const s=n.match(/ (\(.+\)$)/);n=s?n.replace(s[0],""):n;const[i,r,a]=xe(s?s[1]:n);let l=s&&n||"",o=i&&["eval","<anonymous>"].includes(i)?void 0:i;return!o||!r||!a?null:(l.startsWith("async ")&&(l=l.slice(6)),o.startsWith("file://")&&(o=o.slice(7)),o=o.startsWith("node:")||o.startsWith("internal:")?o:Ne(o),l&&(l=l.replace(/__vite_ssr_import_\d+__\./g,"")),{method:l,file:o,line:Number.parseInt(r),column:Number.parseInt(a)})}function X(t,e={}){const{ignoreStackEntries:n=mt}=e;return(ve.test(t)?yt(t):_t(t)).map(i=>{var r;e.getUrlId&&(i.file=e.getUrlId(i.file));const a=(r=e.getSourceMap)===null||r===void 0?void 0:r.call(e,i.file);if(!a||typeof a!="object"||!a.version)return ae(n,i.file)?null:i;const l=new lt(a),{line:o,column:c,source:d,name:p}=ut(l,i);let u=i.file;if(d){const S=i.file.startsWith("file://")?i.file:`file://${i.file}`,w=a.sourceRoot?new URL(a.sourceRoot,S):S;u=new URL(d,w).pathname,u.match(/\/\w:\//)&&(u=u.slice(1))}return ae(n,u)?null:o!=null&&c!=null?{line:o,column:c,file:u,method:p||i.method}:i}).filter(i=>i!=null)}function ae(t,e){return t.some(n=>e.match(n))}function _t(t){return t.split(`
3
+ `).map(e=>gt(e)).filter(ye)}function yt(t){return t.split(`
4
+ `).map(e=>St(e)).filter(ye)}function vt(t,e={}){if(!t||dt(t))return[];if(t.stacks)return t.stacks;const n=t.stack||"";let s=typeof n=="string"?X(n,e):[];if(!s.length){const i=t;i.fileName!=null&&i.lineNumber!=null&&i.columnNumber!=null&&(s=X(`${i.fileName}:${i.lineNumber}:${i.columnNumber}`,e)),i.sourceURL!=null&&i.line!=null&&i._column!=null&&(s=X(`${i.sourceURL}:${i.line}:${i.column}`,e))}return e.frameFilter&&(s=s.filter(i=>e.frameFilter(t,i)!==!1)),t.stacks=s,s}let xt=()=>"Promise{…}";try{const{getPromiseDetails:t,kPending:e,kRejected:n}=process.binding("util");Array.isArray(t(Promise.resolve()))&&(xt=(s,i)=>{const[r,a]=t(s);return r===e?"Promise{<pending>}":`Promise${r===n?"!":""}{${i.inspect(a,i)}}`})}catch{}function wt(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var j,oe;function It(){if(oe)return j;oe=1;var t,e,n,s,i,r,a,l,o,c,d,p,u,S,w,E,b,I,$;return u=/\/(?![*\/])(?:\[(?:(?![\]\\]).|\\.)*\]|(?![\/\\]).|\\.)*(\/[$_\u200C\u200D\p{ID_Continue}]*|\\)?/yu,p=/--|\+\+|=>|\.{3}|\??\.(?!\d)|(?:&&|\|\||\?\?|[+\-%&|^]|\*{1,2}|<{1,2}|>{1,3}|!=?|={1,2}|\/(?![\/*]))=?|[?~,:;[\](){}]/y,t=/(\x23?)(?=[$_\p{ID_Start}\\])(?:[$_\u200C\u200D\p{ID_Continue}]|\\u[\da-fA-F]{4}|\\u\{[\da-fA-F]+\})+/yu,w=/(['"])(?:(?!\1)[^\\\n\r]|\\(?:\r\n|[^]))*(\1)?/y,d=/(?:0[xX][\da-fA-F](?:_?[\da-fA-F])*|0[oO][0-7](?:_?[0-7])*|0[bB][01](?:_?[01])*)n?|0n|[1-9](?:_?\d)*n|(?:(?:0(?!\d)|0\d*[89]\d*|[1-9](?:_?\d)*)(?:\.(?:\d(?:_?\d)*)?)?|\.\d(?:_?\d)*)(?:[eE][+-]?\d(?:_?\d)*)?|0[0-7]+/y,E=/[`}](?:[^`\\$]|\\[^]|\$(?!\{))*(`|\$\{)?/y,$=/[\t\v\f\ufeff\p{Zs}]+/yu,l=/\r?\n|[\r\u2028\u2029]/y,o=/\/\*(?:[^*]|\*(?!\/))*(\*\/)?/y,S=/\/\/.*/y,n=/[<>.:={}]|\/(?![\/*])/y,e=/[$_\p{ID_Start}][$_\u200C\u200D\p{ID_Continue}-]*/yu,s=/(['"])(?:(?!\1)[^])*(\1)?/y,i=/[^<>{}]+/y,I=/^(?:[\/+-]|\.{3}|\?(?:InterpolationIn(?:JSX|Template)|NoLineTerminatorHere|NonExpressionParenEnd|UnaryIncDec))?$|[{}([,;<>=*%&|^!~?:]$/,b=/^(?:=>|[;\]){}]|else|\?(?:NoLineTerminatorHere|NonExpressionParenEnd))?$/,r=/^(?:await|case|default|delete|do|else|instanceof|new|return|throw|typeof|void|yield)$/,a=/^(?:return|throw|yield)$/,c=RegExp(l.source),j=function*(_,{jsx:C=!1}={}){var x,N,T,f,m,Q,h,P,Z,k,O,g,A,v;for({length:Q}=_,f=0,m="",v=[{tag:"JS"}],x=[],O=0,g=!1;f<Q;){switch(P=v[v.length-1],P.tag){case"JS":case"JSNonExpressionParen":case"InterpolationInTemplate":case"InterpolationInJSX":if(_[f]==="/"&&(I.test(m)||r.test(m))&&(u.lastIndex=f,h=u.exec(_))){f=u.lastIndex,m=h[0],g=!0,yield{type:"RegularExpressionLiteral",value:h[0],closed:h[1]!==void 0&&h[1]!=="\\"};continue}if(p.lastIndex=f,h=p.exec(_)){switch(A=h[0],Z=p.lastIndex,k=A,A){case"(":m==="?NonExpressionParenKeyword"&&v.push({tag:"JSNonExpressionParen",nesting:O}),O++,g=!1;break;case")":O--,g=!0,P.tag==="JSNonExpressionParen"&&O===P.nesting&&(v.pop(),k="?NonExpressionParenEnd",g=!1);break;case"{":p.lastIndex=0,T=!b.test(m)&&(I.test(m)||r.test(m)),x.push(T),g=!1;break;case"}":switch(P.tag){case"InterpolationInTemplate":if(x.length===P.nesting){E.lastIndex=f,h=E.exec(_),f=E.lastIndex,m=h[0],h[1]==="${"?(m="?InterpolationInTemplate",g=!1,yield{type:"TemplateMiddle",value:h[0]}):(v.pop(),g=!0,yield{type:"TemplateTail",value:h[0],closed:h[1]==="`"});continue}break;case"InterpolationInJSX":if(x.length===P.nesting){v.pop(),f+=1,m="}",yield{type:"JSXPunctuator",value:"}"};continue}}g=x.pop(),k=g?"?ExpressionBraceEnd":"}";break;case"]":g=!0;break;case"++":case"--":k=g?"?PostfixIncDec":"?UnaryIncDec";break;case"<":if(C&&(I.test(m)||r.test(m))){v.push({tag:"JSXTag"}),f+=1,m="<",yield{type:"JSXPunctuator",value:A};continue}g=!1;break;default:g=!1}f=Z,m=k,yield{type:"Punctuator",value:A};continue}if(t.lastIndex=f,h=t.exec(_)){switch(f=t.lastIndex,k=h[0],h[0]){case"for":case"if":case"while":case"with":m!=="."&&m!=="?."&&(k="?NonExpressionParenKeyword")}m=k,g=!r.test(h[0]),yield{type:h[1]==="#"?"PrivateIdentifier":"IdentifierName",value:h[0]};continue}if(w.lastIndex=f,h=w.exec(_)){f=w.lastIndex,m=h[0],g=!0,yield{type:"StringLiteral",value:h[0],closed:h[2]!==void 0};continue}if(d.lastIndex=f,h=d.exec(_)){f=d.lastIndex,m=h[0],g=!0,yield{type:"NumericLiteral",value:h[0]};continue}if(E.lastIndex=f,h=E.exec(_)){f=E.lastIndex,m=h[0],h[1]==="${"?(m="?InterpolationInTemplate",v.push({tag:"InterpolationInTemplate",nesting:x.length}),g=!1,yield{type:"TemplateHead",value:h[0]}):(g=!0,yield{type:"NoSubstitutionTemplate",value:h[0],closed:h[1]==="`"});continue}break;case"JSXTag":case"JSXTagEnd":if(n.lastIndex=f,h=n.exec(_)){switch(f=n.lastIndex,k=h[0],h[0]){case"<":v.push({tag:"JSXTag"});break;case">":v.pop(),m==="/"||P.tag==="JSXTagEnd"?(k="?JSX",g=!0):v.push({tag:"JSXChildren"});break;case"{":v.push({tag:"InterpolationInJSX",nesting:x.length}),k="?InterpolationInJSX",g=!1;break;case"/":m==="<"&&(v.pop(),v[v.length-1].tag==="JSXChildren"&&v.pop(),v.push({tag:"JSXTagEnd"}))}m=k,yield{type:"JSXPunctuator",value:h[0]};continue}if(e.lastIndex=f,h=e.exec(_)){f=e.lastIndex,m=h[0],yield{type:"JSXIdentifier",value:h[0]};continue}if(s.lastIndex=f,h=s.exec(_)){f=s.lastIndex,m=h[0],yield{type:"JSXString",value:h[0],closed:h[2]!==void 0};continue}break;case"JSXChildren":if(i.lastIndex=f,h=i.exec(_)){f=i.lastIndex,m=h[0],yield{type:"JSXText",value:h[0]};continue}switch(_[f]){case"<":v.push({tag:"JSXTag"}),f++,m="<",yield{type:"JSXPunctuator",value:"<"};continue;case"{":v.push({tag:"InterpolationInJSX",nesting:x.length}),f++,m="?InterpolationInJSX",g=!1,yield{type:"JSXPunctuator",value:"{"};continue}}if($.lastIndex=f,h=$.exec(_)){f=$.lastIndex,yield{type:"WhiteSpace",value:h[0]};continue}if(l.lastIndex=f,h=l.exec(_)){f=l.lastIndex,g=!1,a.test(m)&&(m="?NoLineTerminatorHere"),yield{type:"LineTerminatorSequence",value:h[0]};continue}if(o.lastIndex=f,h=o.exec(_)){f=o.lastIndex,c.test(h[0])&&(g=!1,a.test(m)&&(m="?NoLineTerminatorHere")),yield{type:"MultiLineComment",value:h[0],closed:h[1]!==void 0};continue}if(S.lastIndex=f,h=S.exec(_)){f=S.lastIndex,g=!1,yield{type:"SingleLineComment",value:h[0]};continue}N=String.fromCodePoint(_.codePointAt(f)),f+=N.length,m=N,g=!1,yield{type:P.tag.startsWith("JSX")?"JSXInvalid":"Invalid",value:N}}},j}It();var we={keyword:["break","case","catch","continue","debugger","default","do","else","finally","for","function","if","return","switch","throw","try","var","const","while","with","new","this","super","class","extends","export","import","null","true","false","in","instanceof","typeof","void","delete"],strict:["implements","interface","let","package","private","protected","public","static","yield"]};new Set(we.keyword);new Set(we.strict);var Et={reset:[0,0],bold:[1,22,"\x1B[22m\x1B[1m"],dim:[2,22,"\x1B[22m\x1B[2m"],italic:[3,23],underline:[4,24],inverse:[7,27],hidden:[8,28],strikethrough:[9,29],black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],gray:[90,39],bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],blackBright:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39],bgBlackBright:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]},bt=Object.entries(Et);function q(t){return String(t)}q.open="";q.close="";function $t(t=!1){let e=typeof process<"u"?process:void 0,n=e?.env||{},s=e?.argv||[];return!("NO_COLOR"in n||s.includes("--no-color"))&&("FORCE_COLOR"in n||s.includes("--color")||e?.platform==="win32"||t&&n.TERM!=="dumb"||"CI"in n)||typeof window<"u"&&!!window.chrome}function kt(t=!1){let e=$t(t),n=(a,l,o,c)=>{let d="",p=0;do d+=a.substring(p,c)+o,p=c+l.length,c=a.indexOf(l,p);while(~c);return d+a.substring(p)},s=(a,l,o=a)=>{let c=d=>{let p=String(d),u=p.indexOf(l,a.length);return~u?a+n(p,l,o,u)+l:a+p+l};return c.open=a,c.close=l,c},i={isColorSupported:e},r=a=>`\x1B[${a}m`;for(let[a,l]of bt)i[a]=e?s(r(l[0]),r(l[1]),l[2]):q;return i}kt();const z=/\r?\n/;function Nt(t,e,n){const s=t.split(z),i=/\r\n/.test(t)?2:1;let r=0;if(e>s.length)return t.length;for(let a=0;a<e-1;a++)r+=s[a].length+i;return r+n}function Pt(t,e){if(e>t.length)throw new Error(`offset is longer than source length! offset ${e} > length ${t.length}`);const n=t.split(z),s=/\r\n/.test(t)?2:1;let i=0,r=0;for(;r<n.length;r++){const a=n[r].length+s;if(i+a>=e)break;i+=a}return r+1}async function Rt(t,e){const n=(await be(async()=>{const{default:i}=await import("../../../../../magic-string@0.30.17/node_modules/magic-string/dist/magic-string.es.js");return{default:i}},__vite__mapDeps([0,1,2,3]))).default,s=new Set(e.map(i=>i.file));await Promise.all(Array.from(s).map(async i=>{const r=e.filter(c=>c.file===i),a=await t.readSnapshotFile(i),l=new n(a);for(const c of r){const d=Nt(a,c.line,c.column);Ft(a,l,d,c.snapshot)}const o=l.toString();o!==a&&await t.saveSnapshotFile(i,o)}))}const Ct=/(?:toMatchInlineSnapshot|toThrowErrorMatchingInlineSnapshot)\s*\(\s*(?:\/\*[\s\S]*\*\/\s*|\/\/.*(?:[\n\r\u2028\u2029]\s*|[\t\v\f \xA0\u1680\u2000-\u200A\u202F\u205F\u3000\uFEFF]))*\{/;function Tt(t,e,n,s){let i=t.slice(n);const r=Ct.exec(i);if(!r)return!1;i=i.slice(r.index);let a=ft(i);if(a===null)return!1;a+=n+r.index;const l=n+r.index+r[0].length,o=Ot(t,l),c=`, ${Ie(s,t,n)}`;return o===a?e.appendLeft(a,c):e.overwrite(o,a,c),!0}function Ot(t,e){let n=1,s=0;for(;n!==s&&e<t.length;){const i=t[e++];i==="{"?n++:i==="}"&&s++}return e}function Ie(t,e,n){const s=Pt(e,n),r=e.split(z)[s-1].match(/^\s*/)[0]||"",a=r.includes(" ")?`${r} `:`${r} `,l=t.trim().replace(/\\/g,"\\\\").split(/\n/g),o=l.length<=1,c="`";return o?`${c}${l.join(`
5
5
  `).replace(/`/g,"\\`").replace(/\$\{/g,"\\${")}${c}`:`${c}
6
6
  ${l.map(d=>d?a+d:"").join(`
7
7
  `).replace(/`/g,"\\`").replace(/\$\{/g,"\\${")}
8
- ${r}${c}`}const ce="toMatchInlineSnapshot",ue="toThrowErrorMatchingInlineSnapshot";function Lt(t,e){const n=e-ce.length;if(t.slice(n,e)===ce)return{code:t.slice(n),index:n};const s=e-ue.length;return t.slice(e-s,e)===ue?{code:t.slice(e-s),index:e-s}:{code:t.slice(e),index:e}}const Bt=/(?:toMatchInlineSnapshot|toThrowErrorMatchingInlineSnapshot)\s*\(\s*(?:\/\*[\s\S]*\*\/\s*|\/\/.*(?:[\n\r\u2028\u2029]\s*|[\t\v\f \xA0\u1680\u2000-\u200A\u202F\u205F\u3000\uFEFF]))*[\w$]*(['"`)])/;function Dt(t,e,n,s){const{code:i,index:r}=Lt(t,n),a=Bt.exec(i),l=/toMatchInlineSnapshot|toThrowErrorMatchingInlineSnapshot/.exec(i);if(!a||a.index!==(l==null?void 0:l.index))return Mt(t,e,r,s);const o=a[1],c=r+a.index+a[0].length,d=Ee(s,t,r);if(o===")")return e.appendRight(c-1,d),!0;const u=new RegExp(`(?:^|[^\\\\])${o}`).exec(t.slice(c));if(!u)return!1;const S=c+u.index+u[0].length;return e.overwrite(c-1,S,d),!0}const Jt=/^([^\S\n]*)\S/m;function mn(t){const e=t.match(Jt);if(!e||!e[1])return t;const n=e[1],s=t.split(/\n/g);if(s.length<=2||s[0].trim()!==""||s[s.length-1].trim()!=="")return t;for(let i=1;i<s.length-1;i++)if(s[i]!==""){if(s[i].indexOf(n)!==0)return t;s[i]=s[i].substring(n.length)}return s[s.length-1]="",t=s.join(`
9
- `),t}async function Xt(t,e){await Promise.all(e.map(async n=>{n.readonly||await t.saveSnapshotFile(n.file,n.snapshot)}))}var K={exports:{}},he;function jt(){if(he)return K.exports;he=1;/*
8
+ ${r}${c}`}const le="toMatchInlineSnapshot",ce="toThrowErrorMatchingInlineSnapshot";function At(t,e){const n=e-le.length;if(t.slice(n,e)===le)return{code:t.slice(n),index:n};const s=e-ce.length;return t.slice(e-s,e)===ce?{code:t.slice(e-s),index:e-s}:{code:t.slice(e),index:e}}const Mt=/(?:toMatchInlineSnapshot|toThrowErrorMatchingInlineSnapshot)\s*\(\s*(?:\/\*[\s\S]*\*\/\s*|\/\/.*(?:[\n\r\u2028\u2029]\s*|[\t\v\f \xA0\u1680\u2000-\u200A\u202F\u205F\u3000\uFEFF]))*[\w$]*(['"`)])/;function Ft(t,e,n,s){const{code:i,index:r}=At(t,n),a=Mt.exec(i),l=/toMatchInlineSnapshot|toThrowErrorMatchingInlineSnapshot/.exec(i);if(!a||a.index!==l?.index)return Tt(t,e,r,s);const o=a[1],c=r+a.index+a[0].length,d=Ie(s,t,r);if(o===")")return e.appendRight(c-1,d),!0;const u=new RegExp(`(?:^|[^\\\\])${o}`).exec(t.slice(c));if(!u)return!1;const S=c+u.index+u[0].length;return e.overwrite(c-1,S,d),!0}const Lt=/^([^\S\n]*)\S/m;function hn(t){const e=t.match(Lt);if(!e||!e[1])return t;const n=e[1],s=t.split(/\n/g);if(s.length<=2||s[0].trim()!==""||s[s.length-1].trim()!=="")return t;for(let i=1;i<s.length-1;i++)if(s[i]!==""){if(s[i].indexOf(n)!==0)return t;s[i]=s[i].substring(n.length)}return s[s.length-1]="",t=s.join(`
9
+ `),t}async function Bt(t,e){await Promise.all(e.map(async n=>{n.readonly||await t.saveSnapshotFile(n.file,n.snapshot)}))}var W={exports:{}},ue;function Dt(){if(ue)return W.exports;ue=1;/*
10
10
  * @version 1.4.0
11
11
  * @date 2015-10-26
12
12
  * @stability 3 - Stable
13
13
  * @author Lauri Rooden (https://github.com/litejs/natural-compare-lite)
14
14
  * @license MIT License
15
- */var t=function(e,n){var s,i,r=1,a=0,l=0,o=String.alphabet;function c(d,p,u){if(u){for(s=p;u=c(d,s),u<76&&u>65;)++s;return+d.slice(p-1,s)}return u=o&&o.indexOf(d.charAt(p)),u>-1?u+76:(u=d.charCodeAt(p)||0,u<45||u>127?u:u<46?65:u<48?u-1:u<58?u+18:u<65?u-11:u<91?u+11:u<97?u-37:u<123?u+5:u-63)}if((e+="")!=(n+="")){for(;r;)if(i=c(e,a++),r=c(n,l++),i<76&&r<76&&i>66&&r>66&&(i=c(e,a,a),r=c(n,l,a=s),l=s),i!=r)return i<r?-1:1}return 0};try{K.exports=t}catch{String.naturalCompare=t}return K.exports}var Wt=jt(),Kt=bt(Wt);const Ut=(t,e,n,s,i,r)=>{const a=t.getMockName(),l=a==="vi.fn()"?"":` ${a}`;let o="";if(t.mock.calls.length!==0){const c=n+e.indent;o=` {${e.spacingOuter}${c}"calls": ${r(t.mock.calls,e,c,s,i)}${e.min?", ":","}${e.spacingOuter}${c}"results": ${r(t.mock.results,e,c,s,i)}${e.min?"":","}${e.spacingOuter}${n}}`}return`[MockFunction${l}]${o}`},qt=t=>t&&!!t._isMockFunction,zt={serialize:Ut,test:qt},{DOMCollection:Ht,DOMElement:Gt,Immutable:Vt,ReactElement:Qt,ReactTestComponent:Zt,AsymmetricMatcher:Yt}=Re;let U=[Zt,Qt,Gt,Ht,Vt,Yt,zt];function gn(t){U=[t].concat(U)}function en(){return U}function tn(t,e){return`${t} ${e}`}function nn(t){if(!/ \d+$/.test(t))throw new Error("Snapshot keys must end with a number.");return t.replace(/ \d+$/,"")}function sn(t,e){const n=e.updateSnapshot,s=Object.create(null);let i="",r=!1;if(t!=null)try{i=t,new Function("exports",i)(s)}catch{}return(n==="all"||n==="new")&&i&&(r=!0),{data:s,dirty:r}}function rn(t){return t.includes(`
15
+ */var t=function(e,n){var s,i,r=1,a=0,l=0,o=String.alphabet;function c(d,p,u){if(u){for(s=p;u=c(d,s),u<76&&u>65;)++s;return+d.slice(p-1,s)}return u=o&&o.indexOf(d.charAt(p)),u>-1?u+76:(u=d.charCodeAt(p)||0,u<45||u>127?u:u<46?65:u<48?u-1:u<58?u+18:u<65?u-11:u<91?u+11:u<97?u-37:u<123?u+5:u-63)}if((e+="")!=(n+="")){for(;r;)if(i=c(e,a++),r=c(n,l++),i<76&&r<76&&i>66&&r>66&&(i=c(e,a,a),r=c(n,l,a=s),l=s),i!=r)return i<r?-1:1}return 0};try{W.exports=t}catch{String.naturalCompare=t}return W.exports}var Jt=Dt(),Xt=wt(Jt);const jt=(t,e,n,s,i,r)=>{const a=t.getMockName(),l=a==="vi.fn()"?"":` ${a}`;let o="";if(t.mock.calls.length!==0){const c=n+e.indent;o=` {${e.spacingOuter}${c}"calls": ${r(t.mock.calls,e,c,s,i)}${e.min?", ":","}${e.spacingOuter}${c}"results": ${r(t.mock.results,e,c,s,i)}${e.min?"":","}${e.spacingOuter}${n}}`}return`[MockFunction${l}]${o}`},Wt=t=>t&&!!t._isMockFunction,Kt={serialize:jt,test:Wt},{DOMCollection:Ut,DOMElement:qt,Immutable:zt,ReactElement:Ht,ReactTestComponent:Gt,AsymmetricMatcher:Vt}=ke;let K=[Gt,Ht,qt,Ut,zt,Vt,Kt];function dn(t){K=[t].concat(K)}function Qt(){return K}function Zt(t,e){return`${t} ${e}`}function Yt(t){if(!/ \d+$/.test(t))throw new Error("Snapshot keys must end with a number.");return t.replace(/ \d+$/,"")}function en(t,e){const n=e.updateSnapshot,s=Object.create(null);let i="",r=!1;if(t!=null)try{i=t,new Function("exports",i)(s)}catch{}return(n==="all"||n==="new")&&i&&(r=!0),{data:s,dirty:r}}function tn(t){return t.includes(`
16
16
  `)?`
17
17
  ${t}
18
- `:t}function de(t){return t.length>2&&t.startsWith(`
18
+ `:t}function he(t){return t.length>2&&t.startsWith(`
19
19
  `)&&t.endsWith(`
20
- `)?t.slice(1,-1):t}const an=!0,on=!1;function ln(t,e=2,n={}){return G(Pe(t,{escapeRegex:an,indent:e,plugins:en(),printFunctionName:on,...n}))}function cn(t){return t.replace(/`|\\|\$\{/g,"\\$&")}function fe(t){return`\`${cn(t)}\``}function G(t){return t.replace(/\r\n|\r/g,`
21
- `)}async function un(t,e,n){const s=Object.keys(e).sort(Kt).map(l=>`exports[${fe(l)}] = ${fe(G(e[l]))};`),i=`${t.getHeader()}
20
+ `)?t.slice(1,-1):t}const nn=!0,sn=!1;function rn(t,e=2,n={}){return H($e(t,{escapeRegex:nn,indent:e,plugins:Qt(),printFunctionName:sn,...n}))}function an(t){return t.replace(/`|\\|\$\{/g,"\\$&")}function de(t){return`\`${an(t)}\``}function H(t){return t.replace(/\r\n|\r/g,`
21
+ `)}async function on(t,e,n){const s=Object.keys(e).sort(Xt).map(l=>`exports[${de(l)}] = ${de(H(e[l]))};`),i=`${t.getHeader()}
22
22
 
23
23
  ${s.join(`
24
24
 
25
25
  `)}
26
- `,r=await t.readSnapshotFile(n);r!=null&&r===i||await t.saveSnapshotFile(n,i)}function q(t=[],e=[]){const n=Array.from(t);return e.forEach((s,i)=>{const r=n[i];Array.isArray(t[i])?n[i]=q(t[i],s):J(r)?n[i]=V(t[i],s):n[i]=s}),n}function V(t,e){if(J(t)&&J(e)){const n={...t};return Object.keys(e).forEach(s=>{J(e[s])&&!e[s].$$typeof?s in t?n[s]=V(t[s],e[s]):Object.assign(n,{[s]:e[s]}):Array.isArray(e[s])?n[s]=q(t[s],e[s]):Object.assign(n,{[s]:e[s]})}),n}else if(Array.isArray(t)&&Array.isArray(e))return q(t,e);return t}class be extends Map{constructor(e,n){super(n),this.defaultFn=e}get(e){return this.has(e)||this.set(e,this.defaultFn(e)),super.get(e)}}class L extends be{constructor(){super(()=>0);y(this,"_total")}valueOf(){return this._total=this.total()}increment(n){typeof this._total<"u"&&this._total++,this.set(n,this.get(n)+1)}total(){if(typeof this._total<"u")return this._total;let n=0;for(const s of this.values())n+=s;return n}}function pe(t,e){return t.file===e.file&&t.column===e.column&&t.line===e.line}class Q{constructor(e,n,s,i){y(this,"_counters",new L);y(this,"_dirty");y(this,"_updateSnapshot");y(this,"_snapshotData");y(this,"_initialData");y(this,"_inlineSnapshots");y(this,"_inlineSnapshotStacks");y(this,"_testIdToKeys",new be(()=>[]));y(this,"_rawSnapshots");y(this,"_uncheckedKeys");y(this,"_snapshotFormat");y(this,"_environment");y(this,"_fileExists");y(this,"expand");y(this,"_added",new L);y(this,"_matched",new L);y(this,"_unmatched",new L);y(this,"_updated",new L);this.testFilePath=e,this.snapshotPath=n;const{data:r,dirty:a}=sn(s,i);this._fileExists=s!=null,this._initialData={...r},this._snapshotData={...r},this._dirty=a,this._inlineSnapshots=[],this._inlineSnapshotStacks=[],this._rawSnapshots=[],this._uncheckedKeys=new Set(Object.keys(this._snapshotData)),this.expand=i.expand||!1,this._updateSnapshot=i.updateSnapshot,this._snapshotFormat={printBasicPrototype:!1,escapeString:!1,...i.snapshotFormat},this._environment=i.snapshotEnvironment}get added(){return this._added}set added(e){this._added._total=e}get matched(){return this._matched}set matched(e){this._matched._total=e}get unmatched(){return this._unmatched}set unmatched(e){this._unmatched._total=e}get updated(){return this._updated}set updated(e){this._updated._total=e}static async create(e,n){const s=await n.snapshotEnvironment.resolvePath(e),i=await n.snapshotEnvironment.readSnapshotFile(s);return new Q(e,s,i,n)}get environment(){return this._environment}markSnapshotsAsCheckedForTest(e){this._uncheckedKeys.forEach(n=>{/ \d+$| > /.test(n.slice(e.length))&&this._uncheckedKeys.delete(n)})}clearTest(e){this._inlineSnapshots=this._inlineSnapshots.filter(n=>n.testId!==e),this._inlineSnapshotStacks=this._inlineSnapshotStacks.filter(n=>n.testId!==e);for(const n of this._testIdToKeys.get(e)){const s=nn(n),i=this._counters.get(s);i>0&&((n in this._snapshotData||n in this._initialData)&&(this._snapshotData[n]=this._initialData[n]),this._counters.set(s,i-1))}this._testIdToKeys.delete(e),this.added.delete(e),this.updated.delete(e),this.matched.delete(e),this.unmatched.delete(e)}_inferInlineSnapshotStack(e){const n=e.findIndex(i=>i.method.match(/__VITEST_(RESOLVES|REJECTS)__/));if(n!==-1)return e[n+3];const s=e.findIndex(i=>i.method.includes("__INLINE_SNAPSHOT__"));return s!==-1?e[s+2]:null}_addSnapshot(e,n,s){this._dirty=!0,s.stack?this._inlineSnapshots.push({snapshot:n,testId:s.testId,...s.stack}):s.rawSnapshot?this._rawSnapshots.push({...s.rawSnapshot,snapshot:n}):this._snapshotData[e]=n}async save(){const e=Object.keys(this._snapshotData).length,n=this._inlineSnapshots.length,s=this._rawSnapshots.length,i=!e&&!n&&!s,r={deleted:!1,saved:!1};return(this._dirty||this._uncheckedKeys.size)&&!i?(e&&(await un(this._environment,this._snapshotData,this.snapshotPath),this._fileExists=!0),n&&await Ot(this._environment,this._inlineSnapshots),s&&await Xt(this._environment,this._rawSnapshots),r.saved=!0):!e&&this._fileExists&&(this._updateSnapshot==="all"&&(await this._environment.removeSnapshotFile(this.snapshotPath),this._fileExists=!1),r.deleted=!0),r}getUncheckedCount(){return this._uncheckedKeys.size||0}getUncheckedKeys(){return Array.from(this._uncheckedKeys)}removeUncheckedKeys(){this._updateSnapshot==="all"&&this._uncheckedKeys.size&&(this._dirty=!0,this._uncheckedKeys.forEach(e=>delete this._snapshotData[e]),this._uncheckedKeys.clear())}match({testId:e,testName:n,received:s,key:i,inlineSnapshot:r,isInline:a,error:l,rawSnapshot:o}){this._counters.increment(n);const c=this._counters.get(n);i||(i=tn(n,c)),this._testIdToKeys.get(e).push(i),a&&this._snapshotData[i]!==void 0||this._uncheckedKeys.delete(i);let d=o&&typeof s=="string"?s:ln(s,void 0,this._snapshotFormat);o||(d=rn(d)),o&&o.content&&o.content.match(/\r\n/)&&!d.match(/\r\n/)&&(o.content=G(o.content));const p=a?r:o?o.content:this._snapshotData[i],u=o?p:p==null?void 0:p.trim(),S=u===(o?d:d.trim()),I=p!==void 0,b=a||this._fileExists||o&&o.content!=null;S&&!a&&!o&&(this._snapshotData[i]=d);let $;if(a){var E,k;const _=It(l||new Error("snapshot"),{ignoreStackEntries:[]}),T=this._inferInlineSnapshotStack(_);if(!T)throw new Error(`@vitest/snapshot: Couldn't infer stack frame for inline snapshot.
27
- ${JSON.stringify(_)}`);$=((E=(k=this.environment).processStackTrace)===null||E===void 0?void 0:E.call(k,T))||T,$.column--;const w=this._inlineSnapshotStacks.filter(P=>pe(P,$));if(w.length>0){this._inlineSnapshots=this._inlineSnapshots.filter(O=>!pe(O,$));const P=w.find(O=>O.snapshot!==d);if(P)throw Object.assign(new Error("toMatchInlineSnapshot with different snapshots cannot be called at the same location"),{actual:d,expected:P.snapshot})}this._inlineSnapshotStacks.push({...$,testId:e,snapshot:d})}return I&&this._updateSnapshot==="all"||(!I||!b)&&(this._updateSnapshot==="new"||this._updateSnapshot==="all")?(this._updateSnapshot==="all"?S?this.matched.increment(e):(I?this.updated.increment(e):this.added.increment(e),this._addSnapshot(i,d,{stack:$,testId:e,rawSnapshot:o})):(this._addSnapshot(i,d,{stack:$,testId:e,rawSnapshot:o}),this.added.increment(e)),{actual:"",count:c,expected:"",key:i,pass:!0}):S?(this.matched.increment(e),{actual:"",count:c,expected:"",key:i,pass:!0}):(this.unmatched.increment(e),{actual:o?d:de(d),count:c,expected:u!==void 0?o?u:de(u):void 0,key:i,pass:!1})}async pack(){const e={filepath:this.testFilePath,added:0,fileDeleted:!1,matched:0,unchecked:0,uncheckedKeys:[],unmatched:0,updated:0},n=this.getUncheckedCount(),s=this.getUncheckedKeys();n&&this.removeUncheckedKeys();const i=await this.save();return e.fileDeleted=i.deleted,e.added=this.added.total(),e.matched=this.matched.total(),e.unmatched=this.unmatched.total(),e.updated=this.updated.total(),e.unchecked=i.deleted?0:n,e.uncheckedKeys=Array.from(s),e}}function me(t,e,n,s){const i=new Error(t);return Object.defineProperty(i,"actual",{value:n,enumerable:!0,configurable:!0,writable:!0}),Object.defineProperty(i,"expected",{value:s,enumerable:!0,configurable:!0,writable:!0}),Object.defineProperty(i,"diffOptions",{value:{expand:e}}),i}class Sn{constructor(e={}){y(this,"snapshotStateMap",new Map);this.options=e}async setup(e,n){this.snapshotStateMap.has(e)||this.snapshotStateMap.set(e,await Q.create(e,n))}async finish(e){const s=await this.getSnapshotState(e).pack();return this.snapshotStateMap.delete(e),s}skipTest(e,n){this.getSnapshotState(e).markSnapshotsAsCheckedForTest(n)}clearTest(e,n){this.getSnapshotState(e).clearTest(n)}getSnapshotState(e){const n=this.snapshotStateMap.get(e);if(!n)throw new Error(`The snapshot state for '${e}' is not found. Did you call 'SnapshotClient.setup()'?`);return n}assert(e){const{filepath:n,name:s,testId:i=s,message:r,isInline:a=!1,properties:l,inlineSnapshot:o,error:c,errorMessage:d,rawSnapshot:p}=e;let{received:u}=e;if(!n)throw new Error("Snapshot cannot be used outside of test");const S=this.getSnapshotState(n);if(typeof l=="object"){if(typeof u!="object"||!u)throw new Error("Received value must be an object when the matcher has properties");try{var I,b;if(((I=(b=this.options).isEqual)===null||I===void 0?void 0:I.call(b,u,l))??!1)u=V(u,l);else throw me("Snapshot properties mismatched",S.expand,u,l)}catch(w){throw w.message=d||"Snapshot mismatched",w}}const $=[s,...r?[r]:[]].join(" > "),{actual:E,expected:k,key:_,pass:T}=S.match({testId:i,testName:$,received:u,isInline:a,error:c,inlineSnapshot:o,rawSnapshot:p});if(!T)throw me(`Snapshot \`${_||"unknown"}\` mismatched`,S.expand,p?E:E==null?void 0:E.trim(),p?k:k==null?void 0:k.trim())}async assertRaw(e){if(!e.rawSnapshot)throw new Error("Raw snapshot is required");const{filepath:n,rawSnapshot:s}=e;if(s.content==null){if(!n)throw new Error("Snapshot cannot be used outside of test");const i=this.getSnapshotState(n);e.filepath||(e.filepath=n),s.file=await i.environment.resolveRawPath(n,s.file),s.content=await i.environment.readSnapshotFile(s.file)??void 0}return this.assert(e)}clear(){this.snapshotStateMap.clear()}}export{Sn as SnapshotClient,Q as SnapshotState,gn as addSerializer,en as getSerializers,mn as stripSnapshotIndentation};
26
+ `,r=await t.readSnapshotFile(n);r!=null&&r===i||await t.saveSnapshotFile(n,i)}function U(t=[],e=[]){const n=Array.from(t);return e.forEach((s,i)=>{const r=n[i];Array.isArray(t[i])?n[i]=U(t[i],s):D(r)?n[i]=G(t[i],s):n[i]=s}),n}function G(t,e){if(D(t)&&D(e)){const n={...t};return Object.keys(e).forEach(s=>{D(e[s])&&!e[s].$$typeof?s in t?n[s]=G(t[s],e[s]):Object.assign(n,{[s]:e[s]}):Array.isArray(e[s])?n[s]=U(t[s],e[s]):Object.assign(n,{[s]:e[s]})}),n}else if(Array.isArray(t)&&Array.isArray(e))return U(t,e);return t}class Ee extends Map{constructor(e,n){super(n),this.defaultFn=e}get(e){return this.has(e)||this.set(e,this.defaultFn(e)),super.get(e)}}class F extends Ee{constructor(){super(()=>0)}_total;valueOf(){return this._total=this.total()}increment(e){typeof this._total<"u"&&this._total++,this.set(e,this.get(e)+1)}total(){if(typeof this._total<"u")return this._total;let e=0;for(const n of this.values())e+=n;return e}}function fe(t,e){return t.file===e.file&&t.column===e.column&&t.line===e.line}class V{_counters=new F;_dirty;_updateSnapshot;_snapshotData;_initialData;_inlineSnapshots;_inlineSnapshotStacks;_testIdToKeys=new Ee(()=>[]);_rawSnapshots;_uncheckedKeys;_snapshotFormat;_environment;_fileExists;expand;_added=new F;_matched=new F;_unmatched=new F;_updated=new F;get added(){return this._added}set added(e){this._added._total=e}get matched(){return this._matched}set matched(e){this._matched._total=e}get unmatched(){return this._unmatched}set unmatched(e){this._unmatched._total=e}get updated(){return this._updated}set updated(e){this._updated._total=e}constructor(e,n,s,i){this.testFilePath=e,this.snapshotPath=n;const{data:r,dirty:a}=en(s,i);this._fileExists=s!=null,this._initialData={...r},this._snapshotData={...r},this._dirty=a,this._inlineSnapshots=[],this._inlineSnapshotStacks=[],this._rawSnapshots=[],this._uncheckedKeys=new Set(Object.keys(this._snapshotData)),this.expand=i.expand||!1,this._updateSnapshot=i.updateSnapshot,this._snapshotFormat={printBasicPrototype:!1,escapeString:!1,...i.snapshotFormat},this._environment=i.snapshotEnvironment}static async create(e,n){const s=await n.snapshotEnvironment.resolvePath(e),i=await n.snapshotEnvironment.readSnapshotFile(s);return new V(e,s,i,n)}get environment(){return this._environment}markSnapshotsAsCheckedForTest(e){this._uncheckedKeys.forEach(n=>{/ \d+$| > /.test(n.slice(e.length))&&this._uncheckedKeys.delete(n)})}clearTest(e){this._inlineSnapshots=this._inlineSnapshots.filter(n=>n.testId!==e),this._inlineSnapshotStacks=this._inlineSnapshotStacks.filter(n=>n.testId!==e);for(const n of this._testIdToKeys.get(e)){const s=Yt(n),i=this._counters.get(s);i>0&&((n in this._snapshotData||n in this._initialData)&&(this._snapshotData[n]=this._initialData[n]),this._counters.set(s,i-1))}this._testIdToKeys.delete(e),this.added.delete(e),this.updated.delete(e),this.matched.delete(e),this.unmatched.delete(e)}_inferInlineSnapshotStack(e){const n=e.findIndex(i=>i.method.match(/__VITEST_(RESOLVES|REJECTS)__/));if(n!==-1)return e[n+3];const s=e.findIndex(i=>i.method.includes("__INLINE_SNAPSHOT__"));return s!==-1?e[s+2]:null}_addSnapshot(e,n,s){this._dirty=!0,s.stack?this._inlineSnapshots.push({snapshot:n,testId:s.testId,...s.stack}):s.rawSnapshot?this._rawSnapshots.push({...s.rawSnapshot,snapshot:n}):this._snapshotData[e]=n}async save(){const e=Object.keys(this._snapshotData).length,n=this._inlineSnapshots.length,s=this._rawSnapshots.length,i=!e&&!n&&!s,r={deleted:!1,saved:!1};return(this._dirty||this._uncheckedKeys.size)&&!i?(e&&(await on(this._environment,this._snapshotData,this.snapshotPath),this._fileExists=!0),n&&await Rt(this._environment,this._inlineSnapshots),s&&await Bt(this._environment,this._rawSnapshots),r.saved=!0):!e&&this._fileExists&&(this._updateSnapshot==="all"&&(await this._environment.removeSnapshotFile(this.snapshotPath),this._fileExists=!1),r.deleted=!0),r}getUncheckedCount(){return this._uncheckedKeys.size||0}getUncheckedKeys(){return Array.from(this._uncheckedKeys)}removeUncheckedKeys(){this._updateSnapshot==="all"&&this._uncheckedKeys.size&&(this._dirty=!0,this._uncheckedKeys.forEach(e=>delete this._snapshotData[e]),this._uncheckedKeys.clear())}match({testId:e,testName:n,received:s,key:i,inlineSnapshot:r,isInline:a,error:l,rawSnapshot:o}){this._counters.increment(n);const c=this._counters.get(n);i||(i=Zt(n,c)),this._testIdToKeys.get(e).push(i),a&&this._snapshotData[i]!==void 0||this._uncheckedKeys.delete(i);let d=o&&typeof s=="string"?s:rn(s,void 0,this._snapshotFormat);o||(d=tn(d)),o&&o.content&&o.content.match(/\r\n/)&&!d.match(/\r\n/)&&(o.content=H(o.content));const p=a?r:o?o.content:this._snapshotData[i],u=o?p:p?.trim(),S=u===(o?d:d.trim()),w=p!==void 0,E=a||this._fileExists||o&&o.content!=null;S&&!a&&!o&&(this._snapshotData[i]=d);let b;if(a){var I,$;const _=vt(l||new Error("snapshot"),{ignoreStackEntries:[]}),C=this._inferInlineSnapshotStack(_);if(!C)throw new Error(`@vitest/snapshot: Couldn't infer stack frame for inline snapshot.
27
+ ${JSON.stringify(_)}`);b=((I=($=this.environment).processStackTrace)===null||I===void 0?void 0:I.call($,C))||C,b.column--;const x=this._inlineSnapshotStacks.filter(N=>fe(N,b));if(x.length>0){this._inlineSnapshots=this._inlineSnapshots.filter(T=>!fe(T,b));const N=x.find(T=>T.snapshot!==d);if(N)throw Object.assign(new Error("toMatchInlineSnapshot with different snapshots cannot be called at the same location"),{actual:d,expected:N.snapshot})}this._inlineSnapshotStacks.push({...b,testId:e,snapshot:d})}return w&&this._updateSnapshot==="all"||(!w||!E)&&(this._updateSnapshot==="new"||this._updateSnapshot==="all")?(this._updateSnapshot==="all"?S?this.matched.increment(e):(w?this.updated.increment(e):this.added.increment(e),this._addSnapshot(i,d,{stack:b,testId:e,rawSnapshot:o})):(this._addSnapshot(i,d,{stack:b,testId:e,rawSnapshot:o}),this.added.increment(e)),{actual:"",count:c,expected:"",key:i,pass:!0}):S?(this.matched.increment(e),{actual:"",count:c,expected:"",key:i,pass:!0}):(this.unmatched.increment(e),{actual:o?d:he(d),count:c,expected:u!==void 0?o?u:he(u):void 0,key:i,pass:!1})}async pack(){const e={filepath:this.testFilePath,added:0,fileDeleted:!1,matched:0,unchecked:0,uncheckedKeys:[],unmatched:0,updated:0},n=this.getUncheckedCount(),s=this.getUncheckedKeys();n&&this.removeUncheckedKeys();const i=await this.save();return e.fileDeleted=i.deleted,e.added=this.added.total(),e.matched=this.matched.total(),e.unmatched=this.unmatched.total(),e.updated=this.updated.total(),e.unchecked=i.deleted?0:n,e.uncheckedKeys=Array.from(s),e}}function pe(t,e,n,s){const i=new Error(t);return Object.defineProperty(i,"actual",{value:n,enumerable:!0,configurable:!0,writable:!0}),Object.defineProperty(i,"expected",{value:s,enumerable:!0,configurable:!0,writable:!0}),Object.defineProperty(i,"diffOptions",{value:{expand:e}}),i}class fn{snapshotStateMap=new Map;constructor(e={}){this.options=e}async setup(e,n){this.snapshotStateMap.has(e)||this.snapshotStateMap.set(e,await V.create(e,n))}async finish(e){const s=await this.getSnapshotState(e).pack();return this.snapshotStateMap.delete(e),s}skipTest(e,n){this.getSnapshotState(e).markSnapshotsAsCheckedForTest(n)}clearTest(e,n){this.getSnapshotState(e).clearTest(n)}getSnapshotState(e){const n=this.snapshotStateMap.get(e);if(!n)throw new Error(`The snapshot state for '${e}' is not found. Did you call 'SnapshotClient.setup()'?`);return n}assert(e){const{filepath:n,name:s,testId:i=s,message:r,isInline:a=!1,properties:l,inlineSnapshot:o,error:c,errorMessage:d,rawSnapshot:p}=e;let{received:u}=e;if(!n)throw new Error("Snapshot cannot be used outside of test");const S=this.getSnapshotState(n);if(typeof l=="object"){if(typeof u!="object"||!u)throw new Error("Received value must be an object when the matcher has properties");try{var w,E;if(((w=(E=this.options).isEqual)===null||w===void 0?void 0:w.call(E,u,l))??!1)u=G(u,l);else throw pe("Snapshot properties mismatched",S.expand,u,l)}catch(x){throw x.message=d||"Snapshot mismatched",x}}const b=[s,...r?[r]:[]].join(" > "),{actual:I,expected:$,key:_,pass:C}=S.match({testId:i,testName:b,received:u,isInline:a,error:c,inlineSnapshot:o,rawSnapshot:p});if(!C)throw pe(`Snapshot \`${_||"unknown"}\` mismatched`,S.expand,p?I:I?.trim(),p?$:$?.trim())}async assertRaw(e){if(!e.rawSnapshot)throw new Error("Raw snapshot is required");const{filepath:n,rawSnapshot:s}=e;if(s.content==null){if(!n)throw new Error("Snapshot cannot be used outside of test");const i=this.getSnapshotState(n);e.filepath||(e.filepath=n),s.file=await i.environment.resolveRawPath(n,s.file),s.content=await i.environment.readSnapshotFile(s.file)??void 0}return this.assert(e)}clear(){this.snapshotStateMap.clear()}}export{fn as SnapshotClient,V as SnapshotState,dn as addSerializer,Qt as getSerializers,hn as stripSnapshotIndentation};
@@ -1,42 +1,42 @@
1
- var Qn=Object.defineProperty;var Zn=(n,e,t)=>e in n?Qn(n,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):n[e]=t;var K=(n,e,t)=>Zn(n,typeof e!="symbol"?e+"":e,t);import{format as Q,plugins as Bn}from"../../../../../@vitest_pretty-format@3.2.4/node_modules/@vitest/pretty-format/dist/index.js";import Y from"../../../../../tinyrainbow@2.0.0/node_modules/tinyrainbow/dist/browser.js";import{g as vn,s as Rn}from"./chunk-_commonjsHelpers.js";import{deepClone as wn,getOwnProperties as xn,getType as sn}from"./helpers.js";import"../../../../../loupe@3.1.4/node_modules/loupe/lib/promise.js";const j=-1,O=1,M=0;class A{constructor(e,t){K(this,0);K(this,1);this[0]=e,this[1]=t}}function dn(n,e){if(!n||!e||n.charAt(0)!==e.charAt(0))return 0;let t=0,r=Math.min(n.length,e.length),o=r,l=0;for(;t<o;)n.substring(l,o)===e.substring(l,o)?(t=o,l=t):r=o,o=Math.floor((r-t)/2+t);return o}function kn(n,e){if(!n||!e||n.charAt(n.length-1)!==e.charAt(e.length-1))return 0;let t=0,r=Math.min(n.length,e.length),o=r,l=0;for(;t<o;)n.substring(n.length-o,n.length-l)===e.substring(e.length-o,e.length-l)?(t=o,l=t):r=o,o=Math.floor((r-t)/2+t);return o}function Cn(n,e){const t=n.length,r=e.length;if(t===0||r===0)return 0;t>r?n=n.substring(t-r):t<r&&(e=e.substring(0,t));const o=Math.min(t,r);if(n===e)return o;let l=0,s=1;for(;;){const b=n.substring(o-s),u=e.indexOf(b);if(u===-1)return l;s+=u,(u===0||n.substring(o-s)===e.substring(0,s))&&(l=s,s++)}}function ne(n){let e=!1;const t=[];let r=0,o=null,l=0,s=0,b=0,u=0,F=0;for(;l<n.length;)n[l][0]===M?(t[r++]=l,s=u,b=F,u=0,F=0,o=n[l][1]):(n[l][0]===O?u+=n[l][1].length:F+=n[l][1].length,o&&o.length<=Math.max(s,b)&&o.length<=Math.max(u,F)&&(n.splice(t[r-1],0,new A(j,o)),n[t[r-1]+1][0]=O,r--,r--,l=r>0?t[r-1]:-1,s=0,b=0,u=0,F=0,o=null,e=!0)),l++;for(e&&Nn(n),re(n),l=1;l<n.length;){if(n[l-1][0]===j&&n[l][0]===O){const y=n[l-1][1],C=n[l][1],D=Cn(y,C),c=Cn(C,y);D>=c?(D>=y.length/2||D>=C.length/2)&&(n.splice(l,0,new A(M,C.substring(0,D))),n[l-1][1]=y.substring(0,y.length-D),n[l+1][1]=C.substring(D),l++):(c>=y.length/2||c>=C.length/2)&&(n.splice(l,0,new A(M,y.substring(0,c))),n[l-1][0]=O,n[l-1][1]=C.substring(0,C.length-c),n[l+1][0]=j,n[l+1][1]=y.substring(c),l++),l++}l++}}const bn=/[^a-z0-9]/i,yn=/\s/,$n=/[\r\n]/,ee=/\n\r?\n$/,te=/^\r?\n\r?\n/;function re(n){let e=1;for(;e<n.length-1;){if(n[e-1][0]===M&&n[e+1][0]===M){let t=n[e-1][1],r=n[e][1],o=n[e+1][1];const l=kn(t,r);if(l){const y=r.substring(r.length-l);t=t.substring(0,t.length-l),r=y+r.substring(0,r.length-l),o=y+o}let s=t,b=r,u=o,F=en(t,r)+en(r,o);for(;r.charAt(0)===o.charAt(0);){t+=r.charAt(0),r=r.substring(1)+o.charAt(0),o=o.substring(1);const y=en(t,r)+en(r,o);y>=F&&(F=y,s=t,b=r,u=o)}n[e-1][1]!==s&&(s?n[e-1][1]=s:(n.splice(e-1,1),e--),n[e][1]=b,u?n[e+1][1]=u:(n.splice(e+1,1),e--))}e++}}function Nn(n){n.push(new A(M,""));let e=0,t=0,r=0,o="",l="",s;for(;e<n.length;)switch(n[e][0]){case O:r++,l+=n[e][1],e++;break;case j:t++,o+=n[e][1],e++;break;case M:t+r>1?(t!==0&&r!==0&&(s=dn(l,o),s!==0&&(e-t-r>0&&n[e-t-r-1][0]===M?n[e-t-r-1][1]+=l.substring(0,s):(n.splice(0,0,new A(M,l.substring(0,s))),e++),l=l.substring(s),o=o.substring(s)),s=kn(l,o),s!==0&&(n[e][1]=l.substring(l.length-s)+n[e][1],l=l.substring(0,l.length-s),o=o.substring(0,o.length-s))),e-=t+r,n.splice(e,t+r),o.length&&(n.splice(e,0,new A(j,o)),e++),l.length&&(n.splice(e,0,new A(O,l)),e++),e++):e!==0&&n[e-1][0]===M?(n[e-1][1]+=n[e][1],n.splice(e,1)):e++,r=0,t=0,o="",l="";break}n[n.length-1][1]===""&&n.pop();let b=!1;for(e=1;e<n.length-1;)n[e-1][0]===M&&n[e+1][0]===M&&(n[e][1].substring(n[e][1].length-n[e-1][1].length)===n[e-1][1]?(n[e][1]=n[e-1][1]+n[e][1].substring(0,n[e][1].length-n[e-1][1].length),n[e+1][1]=n[e-1][1]+n[e+1][1],n.splice(e-1,1),b=!0):n[e][1].substring(0,n[e+1][1].length)===n[e+1][1]&&(n[e-1][1]+=n[e+1][1],n[e][1]=n[e][1].substring(n[e+1][1].length)+n[e+1][1],n.splice(e+1,1),b=!0)),e++;b&&Nn(n)}function en(n,e){if(!n||!e)return 6;const t=n.charAt(n.length-1),r=e.charAt(0),o=t.match(bn),l=r.match(bn),s=o&&t.match(yn),b=l&&r.match(yn),u=s&&t.match($n),F=b&&r.match($n),y=u&&n.match(ee),C=F&&e.match(te);return y||C?5:u||F?4:o&&!s&&b?3:s||b?2:o||l?1:0}const qn="Compared values have no visual difference.",oe="Compared values serialize to the same structure.\nPrinting internal object structure without calling `toJSON` instead.";var tn={},Fn;function le(){if(Fn)return tn;Fn=1,Object.defineProperty(tn,"__esModule",{value:!0}),tn.default=D;const n="diff-sequences",e=0,t=(c,i,h,a,f)=>{let p=0;for(;c<i&&h<a&&f(c,h);)c+=1,h+=1,p+=1;return p},r=(c,i,h,a,f)=>{let p=0;for(;c<=i&&h<=a&&f(i,a);)i-=1,a-=1,p+=1;return p},o=(c,i,h,a,f,p,L)=>{let g=0,w=-c,$=p[g],m=$;p[g]+=t($+1,i,a+$-w+1,h,f);const P=c<L?c:L;for(g+=1,w+=2;g<=P;g+=1,w+=2){if(g!==c&&m<p[g])$=p[g];else if($=m+1,i<=$)return g-1;m=p[g],p[g]=$+t($+1,i,a+$-w+1,h,f)}return L},l=(c,i,h,a,f,p,L)=>{let g=0,w=c,$=p[g],m=$;p[g]-=r(i,$-1,h,a+$-w-1,f);const P=c<L?c:L;for(g+=1,w-=2;g<=P;g+=1,w-=2){if(g!==c&&p[g]<m)$=p[g];else if($=m-1,$<i)return g-1;m=p[g],p[g]=$-r(i,$-1,h,a+$-w-1,f)}return L},s=(c,i,h,a,f,p,L,g,w,$,m)=>{const P=a-i,z=h-i,E=f-a-z,R=-E-(c-1),H=-E+(c-1);let k=e;const _=c<g?c:g;for(let T=0,S=-c;T<=_;T+=1,S+=2){const X=T===0||T!==c&&k<L[T],B=X?L[T]:k,q=X?B:B+1,J=P+q-S,U=t(q+1,h,J+1,f,p),G=q+U;if(k=L[T],L[T]=G,R<=S&&S<=H){const Z=(c-1-(S+E))/2;if(Z<=$&&w[Z]-1<=G){const I=P+B-(X?S+1:S-1),N=r(i,B,a,I,p),V=B-N,nn=I-N,x=V+1,on=nn+1;m.nChangePreceding=c-1,c-1===x+on-i-a?(m.aEndPreceding=i,m.bEndPreceding=a):(m.aEndPreceding=x,m.bEndPreceding=on),m.nCommonPreceding=N,N!==0&&(m.aCommonPreceding=x,m.bCommonPreceding=on),m.nCommonFollowing=U,U!==0&&(m.aCommonFollowing=q+1,m.bCommonFollowing=J+1);const mn=G+1,pn=J+U+1;return m.nChangeFollowing=c-1,c-1===h+f-mn-pn?(m.aStartFollowing=h,m.bStartFollowing=f):(m.aStartFollowing=mn,m.bStartFollowing=pn),!0}}}return!1},b=(c,i,h,a,f,p,L,g,w,$,m)=>{const P=f-h,z=h-i,E=f-a-z,R=E-c,H=E+c;let k=e;const _=c<$?c:$;for(let T=0,S=c;T<=_;T+=1,S-=2){const X=T===0||T!==c&&w[T]<k,B=X?w[T]:k,q=X?B:B-1,J=P+q-S,U=r(i,q-1,a,J-1,p),G=q-U;if(k=w[T],w[T]=G,R<=S&&S<=H){const Z=(c+(S-E))/2;if(Z<=g&&G-1<=L[Z]){const I=J-U;if(m.nChangePreceding=c,c===G+I-i-a?(m.aEndPreceding=i,m.bEndPreceding=a):(m.aEndPreceding=G,m.bEndPreceding=I),m.nCommonPreceding=U,U!==0&&(m.aCommonPreceding=G,m.bCommonPreceding=I),m.nChangeFollowing=c-1,c===1)m.nCommonFollowing=0,m.aStartFollowing=h,m.bStartFollowing=f;else{const N=P+B-(X?S-1:S+1),V=t(B,h,N,f,p);m.nCommonFollowing=V,V!==0&&(m.aCommonFollowing=B,m.bCommonFollowing=N);const nn=B+V,x=N+V;c-1===h+f-nn-x?(m.aStartFollowing=h,m.bStartFollowing=f):(m.aStartFollowing=nn,m.bStartFollowing=x)}return!0}}}return!1},u=(c,i,h,a,f,p,L,g,w)=>{const $=a-i,m=f-h,P=h-i,z=f-a,W=z-P;let E=P,R=P;if(L[0]=i-1,g[0]=h,W%2===0){const H=(c||W)/2,k=(P+z)/2;for(let _=1;_<=k;_+=1)if(E=o(_,h,f,$,p,L,E),_<H)R=l(_,i,a,m,p,g,R);else if(b(_,i,h,a,f,p,L,E,g,R,w))return}else{const H=((c||W)+1)/2,k=(P+z+1)/2;let _=1;for(E=o(_,h,f,$,p,L,E),_+=1;_<=k;_+=1)if(R=l(_-1,i,a,m,p,g,R),_<H)E=o(_,h,f,$,p,L,E);else if(s(_,i,h,a,f,p,L,E,g,R,w))return}throw new Error(`${n}: no overlap aStart=${i} aEnd=${h} bStart=${a} bEnd=${f}`)},F=(c,i,h,a,f,p,L,g,w,$)=>{if(f-a<h-i){if(p=!p,p&&L.length===1){const{foundSubsequence:G,isCommon:Z}=L[0];L[1]={foundSubsequence:(I,N,V)=>{G(I,V,N)},isCommon:(I,N)=>Z(N,I)}}const J=i,U=h;i=a,h=f,a=J,f=U}const{foundSubsequence:m,isCommon:P}=L[p?1:0];u(c,i,h,a,f,P,g,w,$);const{nChangePreceding:z,aEndPreceding:W,bEndPreceding:E,nCommonPreceding:R,aCommonPreceding:H,bCommonPreceding:k,nCommonFollowing:_,aCommonFollowing:T,bCommonFollowing:S,nChangeFollowing:X,aStartFollowing:B,bStartFollowing:q}=$;i<W&&a<E&&F(z,i,W,a,E,p,L,g,w,$),R!==0&&m(R,H,k),_!==0&&m(_,T,S),B<h&&q<f&&F(X,B,h,q,f,p,L,g,w,$)},y=(c,i)=>{if(typeof i!="number")throw new TypeError(`${n}: ${c} typeof ${typeof i} is not a number`);if(!Number.isSafeInteger(i))throw new RangeError(`${n}: ${c} value ${i} is not a safe integer`);if(i<0)throw new RangeError(`${n}: ${c} value ${i} is a negative integer`)},C=(c,i)=>{const h=typeof i;if(h!=="function")throw new TypeError(`${n}: ${c} typeof ${h} is not a function`)};function D(c,i,h,a){y("aLength",c),y("bLength",i),C("isCommon",h),C("foundSubsequence",a);const f=t(0,c,0,i,h);if(f!==0&&a(f,0,0),c!==f||i!==f){const p=f,L=f,g=r(p,c-1,L,i-1,h),w=c-g,$=i-g,m=f+g;c!==m&&i!==m&&F(0,p,w,L,$,!1,[{foundSubsequence:a,isCommon:h}],[e],[e],{aCommonFollowing:e,aCommonPreceding:e,aEndPreceding:e,aStartFollowing:e,bCommonFollowing:e,bCommonPreceding:e,bEndPreceding:e,bStartFollowing:e,nChangeFollowing:e,nChangePreceding:e,nCommonFollowing:e,nCommonPreceding:e}),g!==0&&a(g,w,$)}}return tn}var ce=le(),Un=vn(ce);function ie(n,e){return n.replace(/\s+$/,t=>e(t))}function an(n,e,t,r,o,l){return n.length!==0?t(`${r} ${ie(n,o)}`):r!==" "?t(r):e&&l.length!==0?t(`${r} ${l}`):""}function Gn(n,e,{aColor:t,aIndicator:r,changeLineTrailingSpaceColor:o,emptyFirstOrLastLinePlaceholder:l}){return an(n,e,t,r,o,l)}function zn(n,e,{bColor:t,bIndicator:r,changeLineTrailingSpaceColor:o,emptyFirstOrLastLinePlaceholder:l}){return an(n,e,t,r,o,l)}function Hn(n,e,{commonColor:t,commonIndicator:r,commonLineTrailingSpaceColor:o,emptyFirstOrLastLinePlaceholder:l}){return an(n,e,t,r,o,l)}function Ln(n,e,t,r,{patchColor:o}){return o(`@@ -${n+1},${e-n} +${t+1},${r-t} @@`)}function se(n,e){const t=n.length,r=e.contextLines,o=r+r;let l=t,s=!1,b=0,u=0;for(;u!==t;){const g=u;for(;u!==t&&n[u][0]===M;)u+=1;if(g!==u)if(g===0)u>r&&(l-=u-r,s=!0);else if(u===t){const w=u-g;w>r&&(l-=w-r,s=!0)}else{const w=u-g;w>o&&(l-=w-o,b+=1)}for(;u!==t&&n[u][0]!==M;)u+=1}const F=b!==0||s;b!==0?l+=b+1:s&&(l+=1);const y=l-1,C=[];let D=0;F&&C.push("");let c=0,i=0,h=0,a=0;const f=g=>{const w=C.length;C.push(Hn(g,w===0||w===y,e)),h+=1,a+=1},p=g=>{const w=C.length;C.push(Gn(g,w===0||w===y,e)),h+=1},L=g=>{const w=C.length;C.push(zn(g,w===0||w===y,e)),a+=1};for(u=0;u!==t;){let g=u;for(;u!==t&&n[u][0]===M;)u+=1;if(g!==u)if(g===0){u>r&&(g=u-r,c=g,i=g,h=c,a=i);for(let w=g;w!==u;w+=1)f(n[w][1])}else if(u===t){const w=u-g>r?g+r:u;for(let $=g;$!==w;$+=1)f(n[$][1])}else{const w=u-g;if(w>o){const $=g+r;for(let P=g;P!==$;P+=1)f(n[P][1]);C[D]=Ln(c,h,i,a,e),D=C.length,C.push("");const m=w-o;c=h+m,i=a+m,h=c,a=i;for(let P=u-r;P!==u;P+=1)f(n[P][1])}else for(let $=g;$!==u;$+=1)f(n[$][1])}for(;u!==t&&n[u][0]===j;)p(n[u][1]),u+=1;for(;u!==t&&n[u][0]===O;)L(n[u][1]),u+=1}return F&&(C[D]=Ln(c,h,i,a,e)),C.join(`
2
- `)}function ue(n,e){return n.map((t,r,o)=>{const l=t[1],s=r===0||r===o.length-1;switch(t[0]){case j:return Gn(l,s,e);case O:return zn(l,s,e);default:return Hn(l,s,e)}}).join(`
3
- `)}const ln=n=>n,In=5,he=0;function ge(){return{aAnnotation:"Expected",aColor:Y.green,aIndicator:"-",bAnnotation:"Received",bColor:Y.red,bIndicator:"+",changeColor:Y.inverse,changeLineTrailingSpaceColor:ln,commonColor:Y.dim,commonIndicator:" ",commonLineTrailingSpaceColor:ln,compareKeys:void 0,contextLines:In,emptyFirstOrLastLinePlaceholder:"",expand:!1,includeChangeCounts:!1,omitAnnotationLines:!1,patchColor:Y.yellow,printBasicPrototype:!1,truncateThreshold:he,truncateAnnotation:"... Diff result is truncated",truncateAnnotationColor:ln}}function ae(n){return n&&typeof n=="function"?n:void 0}function fe(n){return typeof n=="number"&&Number.isSafeInteger(n)&&n>=0?n:In}function v(n={}){return{...ge(),...n,compareKeys:ae(n.compareKeys),contextLines:fe(n.contextLines)}}function d(n){return n.length===1&&n[0].length===0}function me(n){let e=0,t=0;return n.forEach(r=>{switch(r[0]){case j:e+=1;break;case O:t+=1;break}}),{a:e,b:t}}function pe({aAnnotation:n,aColor:e,aIndicator:t,bAnnotation:r,bColor:o,bIndicator:l,includeChangeCounts:s,omitAnnotationLines:b},u){if(b)return"";let F="",y="";if(s){const c=String(u.a),i=String(u.b),h=r.length-n.length,a=" ".repeat(Math.max(0,h)),f=" ".repeat(Math.max(0,-h)),p=i.length-c.length,L=" ".repeat(Math.max(0,p)),g=" ".repeat(Math.max(0,-p));F=`${a} ${t} ${L}${c}`,y=`${f} ${l} ${g}${i}`}const C=`${t} ${n}${F}`,D=`${l} ${r}${y}`;return`${e(C)}
1
+ import{format as Y,plugins as jn}from"../../../../../@vitest_pretty-format@3.2.4/node_modules/@vitest/pretty-format/dist/index.js";import V from"../../../../../tinyrainbow@2.0.0/node_modules/tinyrainbow/dist/browser.js";import{g as Yn,s as Bn}from"./chunk-_commonjsHelpers.js";import{deepClone as pn,getOwnProperties as Qn,getType as cn}from"./helpers.js";import"../../../../../loupe@3.1.4/node_modules/loupe/lib/promise.js";const j=-1,O=1,M=0;class A{0;1;constructor(e,t){this[0]=e,this[1]=t}}function Zn(n,e){if(!n||!e||n.charAt(0)!==e.charAt(0))return 0;let t=0,r=Math.min(n.length,e.length),o=r,l=0;for(;t<o;)n.substring(l,o)===e.substring(l,o)?(t=o,l=t):r=o,o=Math.floor((r-t)/2+t);return o}function Rn(n,e){if(!n||!e||n.charAt(n.length-1)!==e.charAt(e.length-1))return 0;let t=0,r=Math.min(n.length,e.length),o=r,l=0;for(;t<o;)n.substring(n.length-o,n.length-l)===e.substring(e.length-o,e.length-l)?(t=o,l=t):r=o,o=Math.floor((r-t)/2+t);return o}function wn(n,e){const t=n.length,r=e.length;if(t===0||r===0)return 0;t>r?n=n.substring(t-r):t<r&&(e=e.substring(0,t));const o=Math.min(t,r);if(n===e)return o;let l=0,s=1;for(;;){const b=n.substring(o-s),u=e.indexOf(b);if(u===-1)return l;s+=u,(u===0||n.substring(o-s)===e.substring(0,s))&&(l=s,s++)}}function vn(n){let e=!1;const t=[];let r=0,o=null,l=0,s=0,b=0,u=0,F=0;for(;l<n.length;)n[l][0]===M?(t[r++]=l,s=u,b=F,u=0,F=0,o=n[l][1]):(n[l][0]===O?u+=n[l][1].length:F+=n[l][1].length,o&&o.length<=Math.max(s,b)&&o.length<=Math.max(u,F)&&(n.splice(t[r-1],0,new A(j,o)),n[t[r-1]+1][0]=O,r--,r--,l=r>0?t[r-1]:-1,s=0,b=0,u=0,F=0,o=null,e=!0)),l++;for(e&&kn(n),ne(n),l=1;l<n.length;){if(n[l-1][0]===j&&n[l][0]===O){const y=n[l-1][1],C=n[l][1],D=wn(y,C),c=wn(C,y);D>=c?(D>=y.length/2||D>=C.length/2)&&(n.splice(l,0,new A(M,C.substring(0,D))),n[l-1][1]=y.substring(0,y.length-D),n[l+1][1]=C.substring(D),l++):(c>=y.length/2||c>=C.length/2)&&(n.splice(l,0,new A(M,y.substring(0,c))),n[l-1][0]=O,n[l-1][1]=C.substring(0,C.length-c),n[l+1][0]=j,n[l+1][1]=y.substring(c),l++),l++}l++}}const Cn=/[^a-z0-9]/i,bn=/\s/,yn=/[\r\n]/,xn=/\n\r?\n$/,dn=/^\r?\n\r?\n/;function ne(n){let e=1;for(;e<n.length-1;){if(n[e-1][0]===M&&n[e+1][0]===M){let t=n[e-1][1],r=n[e][1],o=n[e+1][1];const l=Rn(t,r);if(l){const y=r.substring(r.length-l);t=t.substring(0,t.length-l),r=y+r.substring(0,r.length-l),o=y+o}let s=t,b=r,u=o,F=nn(t,r)+nn(r,o);for(;r.charAt(0)===o.charAt(0);){t+=r.charAt(0),r=r.substring(1)+o.charAt(0),o=o.substring(1);const y=nn(t,r)+nn(r,o);y>=F&&(F=y,s=t,b=r,u=o)}n[e-1][1]!==s&&(s?n[e-1][1]=s:(n.splice(e-1,1),e--),n[e][1]=b,u?n[e+1][1]=u:(n.splice(e+1,1),e--))}e++}}function kn(n){n.push(new A(M,""));let e=0,t=0,r=0,o="",l="",s;for(;e<n.length;)switch(n[e][0]){case O:r++,l+=n[e][1],e++;break;case j:t++,o+=n[e][1],e++;break;case M:t+r>1?(t!==0&&r!==0&&(s=Zn(l,o),s!==0&&(e-t-r>0&&n[e-t-r-1][0]===M?n[e-t-r-1][1]+=l.substring(0,s):(n.splice(0,0,new A(M,l.substring(0,s))),e++),l=l.substring(s),o=o.substring(s)),s=Rn(l,o),s!==0&&(n[e][1]=l.substring(l.length-s)+n[e][1],l=l.substring(0,l.length-s),o=o.substring(0,o.length-s))),e-=t+r,n.splice(e,t+r),o.length&&(n.splice(e,0,new A(j,o)),e++),l.length&&(n.splice(e,0,new A(O,l)),e++),e++):e!==0&&n[e-1][0]===M?(n[e-1][1]+=n[e][1],n.splice(e,1)):e++,r=0,t=0,o="",l="";break}n[n.length-1][1]===""&&n.pop();let b=!1;for(e=1;e<n.length-1;)n[e-1][0]===M&&n[e+1][0]===M&&(n[e][1].substring(n[e][1].length-n[e-1][1].length)===n[e-1][1]?(n[e][1]=n[e-1][1]+n[e][1].substring(0,n[e][1].length-n[e-1][1].length),n[e+1][1]=n[e-1][1]+n[e+1][1],n.splice(e-1,1),b=!0):n[e][1].substring(0,n[e+1][1].length)===n[e+1][1]&&(n[e-1][1]+=n[e+1][1],n[e][1]=n[e][1].substring(n[e+1][1].length)+n[e+1][1],n.splice(e+1,1),b=!0)),e++;b&&kn(n)}function nn(n,e){if(!n||!e)return 6;const t=n.charAt(n.length-1),r=e.charAt(0),o=t.match(Cn),l=r.match(Cn),s=o&&t.match(bn),b=l&&r.match(bn),u=s&&t.match(yn),F=b&&r.match(yn),y=u&&n.match(xn),C=F&&e.match(dn);return y||C?5:u||F?4:o&&!s&&b?3:s||b?2:o||l?1:0}const Nn="Compared values have no visual difference.",ee="Compared values serialize to the same structure.\nPrinting internal object structure without calling `toJSON` instead.";var en={},$n;function te(){if($n)return en;$n=1,Object.defineProperty(en,"__esModule",{value:!0}),en.default=D;const n="diff-sequences",e=0,t=(c,i,h,a,f)=>{let p=0;for(;c<i&&h<a&&f(c,h);)c+=1,h+=1,p+=1;return p},r=(c,i,h,a,f)=>{let p=0;for(;c<=i&&h<=a&&f(i,a);)i-=1,a-=1,p+=1;return p},o=(c,i,h,a,f,p,L)=>{let g=0,w=-c,$=p[g],m=$;p[g]+=t($+1,i,a+$-w+1,h,f);const P=c<L?c:L;for(g+=1,w+=2;g<=P;g+=1,w+=2){if(g!==c&&m<p[g])$=p[g];else if($=m+1,i<=$)return g-1;m=p[g],p[g]=$+t($+1,i,a+$-w+1,h,f)}return L},l=(c,i,h,a,f,p,L)=>{let g=0,w=c,$=p[g],m=$;p[g]-=r(i,$-1,h,a+$-w-1,f);const P=c<L?c:L;for(g+=1,w-=2;g<=P;g+=1,w-=2){if(g!==c&&p[g]<m)$=p[g];else if($=m-1,$<i)return g-1;m=p[g],p[g]=$-r(i,$-1,h,a+$-w-1,f)}return L},s=(c,i,h,a,f,p,L,g,w,$,m)=>{const P=a-i,z=h-i,E=f-a-z,R=-E-(c-1),H=-E+(c-1);let k=e;const _=c<g?c:g;for(let T=0,S=-c;T<=_;T+=1,S+=2){const W=T===0||T!==c&&k<L[T],B=W?L[T]:k,q=W?B:B+1,X=P+q-S,U=t(q+1,h,X+1,f,p),G=q+U;if(k=L[T],L[T]=G,R<=S&&S<=H){const Q=(c-1-(S+E))/2;if(Q<=$&&w[Q]-1<=G){const I=P+B-(W?S+1:S-1),N=r(i,B,a,I,p),J=B-N,d=I-N,v=J+1,rn=d+1;m.nChangePreceding=c-1,c-1===v+rn-i-a?(m.aEndPreceding=i,m.bEndPreceding=a):(m.aEndPreceding=v,m.bEndPreceding=rn),m.nCommonPreceding=N,N!==0&&(m.aCommonPreceding=v,m.bCommonPreceding=rn),m.nCommonFollowing=U,U!==0&&(m.aCommonFollowing=q+1,m.bCommonFollowing=X+1);const fn=G+1,mn=X+U+1;return m.nChangeFollowing=c-1,c-1===h+f-fn-mn?(m.aStartFollowing=h,m.bStartFollowing=f):(m.aStartFollowing=fn,m.bStartFollowing=mn),!0}}}return!1},b=(c,i,h,a,f,p,L,g,w,$,m)=>{const P=f-h,z=h-i,E=f-a-z,R=E-c,H=E+c;let k=e;const _=c<$?c:$;for(let T=0,S=c;T<=_;T+=1,S-=2){const W=T===0||T!==c&&w[T]<k,B=W?w[T]:k,q=W?B:B-1,X=P+q-S,U=r(i,q-1,a,X-1,p),G=q-U;if(k=w[T],w[T]=G,R<=S&&S<=H){const Q=(c+(S-E))/2;if(Q<=g&&G-1<=L[Q]){const I=X-U;if(m.nChangePreceding=c,c===G+I-i-a?(m.aEndPreceding=i,m.bEndPreceding=a):(m.aEndPreceding=G,m.bEndPreceding=I),m.nCommonPreceding=U,U!==0&&(m.aCommonPreceding=G,m.bCommonPreceding=I),m.nChangeFollowing=c-1,c===1)m.nCommonFollowing=0,m.aStartFollowing=h,m.bStartFollowing=f;else{const N=P+B-(W?S-1:S+1),J=t(B,h,N,f,p);m.nCommonFollowing=J,J!==0&&(m.aCommonFollowing=B,m.bCommonFollowing=N);const d=B+J,v=N+J;c-1===h+f-d-v?(m.aStartFollowing=h,m.bStartFollowing=f):(m.aStartFollowing=d,m.bStartFollowing=v)}return!0}}}return!1},u=(c,i,h,a,f,p,L,g,w)=>{const $=a-i,m=f-h,P=h-i,z=f-a,K=z-P;let E=P,R=P;if(L[0]=i-1,g[0]=h,K%2===0){const H=(c||K)/2,k=(P+z)/2;for(let _=1;_<=k;_+=1)if(E=o(_,h,f,$,p,L,E),_<H)R=l(_,i,a,m,p,g,R);else if(b(_,i,h,a,f,p,L,E,g,R,w))return}else{const H=((c||K)+1)/2,k=(P+z+1)/2;let _=1;for(E=o(_,h,f,$,p,L,E),_+=1;_<=k;_+=1)if(R=l(_-1,i,a,m,p,g,R),_<H)E=o(_,h,f,$,p,L,E);else if(s(_,i,h,a,f,p,L,E,g,R,w))return}throw new Error(`${n}: no overlap aStart=${i} aEnd=${h} bStart=${a} bEnd=${f}`)},F=(c,i,h,a,f,p,L,g,w,$)=>{if(f-a<h-i){if(p=!p,p&&L.length===1){const{foundSubsequence:G,isCommon:Q}=L[0];L[1]={foundSubsequence:(I,N,J)=>{G(I,J,N)},isCommon:(I,N)=>Q(N,I)}}const X=i,U=h;i=a,h=f,a=X,f=U}const{foundSubsequence:m,isCommon:P}=L[p?1:0];u(c,i,h,a,f,P,g,w,$);const{nChangePreceding:z,aEndPreceding:K,bEndPreceding:E,nCommonPreceding:R,aCommonPreceding:H,bCommonPreceding:k,nCommonFollowing:_,aCommonFollowing:T,bCommonFollowing:S,nChangeFollowing:W,aStartFollowing:B,bStartFollowing:q}=$;i<K&&a<E&&F(z,i,K,a,E,p,L,g,w,$),R!==0&&m(R,H,k),_!==0&&m(_,T,S),B<h&&q<f&&F(W,B,h,q,f,p,L,g,w,$)},y=(c,i)=>{if(typeof i!="number")throw new TypeError(`${n}: ${c} typeof ${typeof i} is not a number`);if(!Number.isSafeInteger(i))throw new RangeError(`${n}: ${c} value ${i} is not a safe integer`);if(i<0)throw new RangeError(`${n}: ${c} value ${i} is a negative integer`)},C=(c,i)=>{const h=typeof i;if(h!=="function")throw new TypeError(`${n}: ${c} typeof ${h} is not a function`)};function D(c,i,h,a){y("aLength",c),y("bLength",i),C("isCommon",h),C("foundSubsequence",a);const f=t(0,c,0,i,h);if(f!==0&&a(f,0,0),c!==f||i!==f){const p=f,L=f,g=r(p,c-1,L,i-1,h),w=c-g,$=i-g,m=f+g;c!==m&&i!==m&&F(0,p,w,L,$,!1,[{foundSubsequence:a,isCommon:h}],[e],[e],{aCommonFollowing:e,aCommonPreceding:e,aEndPreceding:e,aStartFollowing:e,bCommonFollowing:e,bCommonPreceding:e,bEndPreceding:e,bStartFollowing:e,nChangeFollowing:e,nChangePreceding:e,nCommonFollowing:e,nCommonPreceding:e}),g!==0&&a(g,w,$)}}return en}var re=te(),qn=Yn(re);function oe(n,e){return n.replace(/\s+$/,t=>e(t))}function gn(n,e,t,r,o,l){return n.length!==0?t(`${r} ${oe(n,o)}`):r!==" "?t(r):e&&l.length!==0?t(`${r} ${l}`):""}function Un(n,e,{aColor:t,aIndicator:r,changeLineTrailingSpaceColor:o,emptyFirstOrLastLinePlaceholder:l}){return gn(n,e,t,r,o,l)}function Gn(n,e,{bColor:t,bIndicator:r,changeLineTrailingSpaceColor:o,emptyFirstOrLastLinePlaceholder:l}){return gn(n,e,t,r,o,l)}function zn(n,e,{commonColor:t,commonIndicator:r,commonLineTrailingSpaceColor:o,emptyFirstOrLastLinePlaceholder:l}){return gn(n,e,t,r,o,l)}function Fn(n,e,t,r,{patchColor:o}){return o(`@@ -${n+1},${e-n} +${t+1},${r-t} @@`)}function le(n,e){const t=n.length,r=e.contextLines,o=r+r;let l=t,s=!1,b=0,u=0;for(;u!==t;){const g=u;for(;u!==t&&n[u][0]===M;)u+=1;if(g!==u)if(g===0)u>r&&(l-=u-r,s=!0);else if(u===t){const w=u-g;w>r&&(l-=w-r,s=!0)}else{const w=u-g;w>o&&(l-=w-o,b+=1)}for(;u!==t&&n[u][0]!==M;)u+=1}const F=b!==0||s;b!==0?l+=b+1:s&&(l+=1);const y=l-1,C=[];let D=0;F&&C.push("");let c=0,i=0,h=0,a=0;const f=g=>{const w=C.length;C.push(zn(g,w===0||w===y,e)),h+=1,a+=1},p=g=>{const w=C.length;C.push(Un(g,w===0||w===y,e)),h+=1},L=g=>{const w=C.length;C.push(Gn(g,w===0||w===y,e)),a+=1};for(u=0;u!==t;){let g=u;for(;u!==t&&n[u][0]===M;)u+=1;if(g!==u)if(g===0){u>r&&(g=u-r,c=g,i=g,h=c,a=i);for(let w=g;w!==u;w+=1)f(n[w][1])}else if(u===t){const w=u-g>r?g+r:u;for(let $=g;$!==w;$+=1)f(n[$][1])}else{const w=u-g;if(w>o){const $=g+r;for(let P=g;P!==$;P+=1)f(n[P][1]);C[D]=Fn(c,h,i,a,e),D=C.length,C.push("");const m=w-o;c=h+m,i=a+m,h=c,a=i;for(let P=u-r;P!==u;P+=1)f(n[P][1])}else for(let $=g;$!==u;$+=1)f(n[$][1])}for(;u!==t&&n[u][0]===j;)p(n[u][1]),u+=1;for(;u!==t&&n[u][0]===O;)L(n[u][1]),u+=1}return F&&(C[D]=Fn(c,h,i,a,e)),C.join(`
2
+ `)}function ce(n,e){return n.map((t,r,o)=>{const l=t[1],s=r===0||r===o.length-1;switch(t[0]){case j:return Un(l,s,e);case O:return Gn(l,s,e);default:return zn(l,s,e)}}).join(`
3
+ `)}const on=n=>n,Hn=5,ie=0;function se(){return{aAnnotation:"Expected",aColor:V.green,aIndicator:"-",bAnnotation:"Received",bColor:V.red,bIndicator:"+",changeColor:V.inverse,changeLineTrailingSpaceColor:on,commonColor:V.dim,commonIndicator:" ",commonLineTrailingSpaceColor:on,compareKeys:void 0,contextLines:Hn,emptyFirstOrLastLinePlaceholder:"",expand:!1,includeChangeCounts:!1,omitAnnotationLines:!1,patchColor:V.yellow,printBasicPrototype:!1,truncateThreshold:ie,truncateAnnotation:"... Diff result is truncated",truncateAnnotationColor:on}}function ue(n){return n&&typeof n=="function"?n:void 0}function he(n){return typeof n=="number"&&Number.isSafeInteger(n)&&n>=0?n:Hn}function Z(n={}){return{...se(),...n,compareKeys:ue(n.compareKeys),contextLines:he(n.contextLines)}}function x(n){return n.length===1&&n[0].length===0}function ge(n){let e=0,t=0;return n.forEach(r=>{switch(r[0]){case j:e+=1;break;case O:t+=1;break}}),{a:e,b:t}}function ae({aAnnotation:n,aColor:e,aIndicator:t,bAnnotation:r,bColor:o,bIndicator:l,includeChangeCounts:s,omitAnnotationLines:b},u){if(b)return"";let F="",y="";if(s){const c=String(u.a),i=String(u.b),h=r.length-n.length,a=" ".repeat(Math.max(0,h)),f=" ".repeat(Math.max(0,-h)),p=i.length-c.length,L=" ".repeat(Math.max(0,p)),g=" ".repeat(Math.max(0,-p));F=`${a} ${t} ${L}${c}`,y=`${f} ${l} ${g}${i}`}const C=`${t} ${n}${F}`,D=`${l} ${r}${y}`;return`${e(C)}
4
4
  ${o(D)}
5
5
 
6
- `}function fn(n,e,t){return pe(t,me(n))+(t.expand?ue(n,t):se(n,t))+(e?t.truncateAnnotationColor(`
7
- ${t.truncateAnnotation}`):"")}function rn(n,e,t){const r=v(t),[o,l]=Kn(d(n)?[]:n,d(e)?[]:e,r);return fn(o,l,r)}function we(n,e,t,r,o){if(d(n)&&d(t)&&(n=[],t=[]),d(e)&&d(r)&&(e=[],r=[]),n.length!==t.length||e.length!==r.length)return rn(n,e,o);const[l,s]=Kn(t,r,o);let b=0,u=0;return l.forEach(F=>{switch(F[0]){case j:F[1]=n[b],b+=1;break;case O:F[1]=e[u],u+=1;break;default:F[1]=e[u],b+=1,u+=1}}),fn(l,s,v(o))}function Kn(n,e,t){const r=(t==null?void 0:t.truncateThreshold)??!1,o=Math.max(Math.floor((t==null?void 0:t.truncateThreshold)??0),0),l=r?Math.min(n.length,o):n.length,s=r?Math.min(e.length,o):e.length,b=l!==n.length||s!==e.length,u=(c,i)=>n[c]===e[i],F=[];let y=0,C=0;for(Un(l,s,u,(c,i,h)=>{for(;y!==i;y+=1)F.push(new A(j,n[y]));for(;C!==h;C+=1)F.push(new A(O,e[C]));for(;c!==0;c-=1,y+=1,C+=1)F.push(new A(M,e[C]))});y!==l;y+=1)F.push(new A(j,n[y]));for(;C!==s;C+=1)F.push(new A(O,e[C]));return[F,b]}function Pn(n){if(n===void 0)return"undefined";if(n===null)return"null";if(Array.isArray(n))return"array";if(typeof n=="boolean")return"boolean";if(typeof n=="function")return"function";if(typeof n=="number")return"number";if(typeof n=="string")return"string";if(typeof n=="bigint")return"bigint";if(typeof n=="object"){if(n!=null){if(n.constructor===RegExp)return"regexp";if(n.constructor===Map)return"map";if(n.constructor===Set)return"set";if(n.constructor===Date)return"date"}return"object"}else if(typeof n=="symbol")return"symbol";throw new Error(`value of unknown type: ${n}`)}function An(n){return n.includes(`\r
6
+ `}function an(n,e,t){return ae(t,ge(n))+(t.expand?ce(n,t):le(n,t))+(e?t.truncateAnnotationColor(`
7
+ ${t.truncateAnnotation}`):"")}function tn(n,e,t){const r=Z(t),[o,l]=In(x(n)?[]:n,x(e)?[]:e,r);return an(o,l,r)}function fe(n,e,t,r,o){if(x(n)&&x(t)&&(n=[],t=[]),x(e)&&x(r)&&(e=[],r=[]),n.length!==t.length||e.length!==r.length)return tn(n,e,o);const[l,s]=In(t,r,o);let b=0,u=0;return l.forEach(F=>{switch(F[0]){case j:F[1]=n[b],b+=1;break;case O:F[1]=e[u],u+=1;break;default:F[1]=e[u],b+=1,u+=1}}),an(l,s,Z(o))}function In(n,e,t){const r=t?.truncateThreshold??!1,o=Math.max(Math.floor(t?.truncateThreshold??0),0),l=r?Math.min(n.length,o):n.length,s=r?Math.min(e.length,o):e.length,b=l!==n.length||s!==e.length,u=(c,i)=>n[c]===e[i],F=[];let y=0,C=0;for(qn(l,s,u,(c,i,h)=>{for(;y!==i;y+=1)F.push(new A(j,n[y]));for(;C!==h;C+=1)F.push(new A(O,e[C]));for(;c!==0;c-=1,y+=1,C+=1)F.push(new A(M,e[C]))});y!==l;y+=1)F.push(new A(j,n[y]));for(;C!==s;C+=1)F.push(new A(O,e[C]));return[F,b]}function Ln(n){if(n===void 0)return"undefined";if(n===null)return"null";if(Array.isArray(n))return"array";if(typeof n=="boolean")return"boolean";if(typeof n=="function")return"function";if(typeof n=="number")return"number";if(typeof n=="string")return"string";if(typeof n=="bigint")return"bigint";if(typeof n=="object"){if(n!=null){if(n.constructor===RegExp)return"regexp";if(n.constructor===Map)return"map";if(n.constructor===Set)return"set";if(n.constructor===Date)return"date"}return"object"}else if(typeof n=="symbol")return"symbol";throw new Error(`value of unknown type: ${n}`)}function Pn(n){return n.includes(`\r
8
8
  `)?`\r
9
9
  `:`
10
- `}function Ce(n,e,t){const r=(t==null?void 0:t.truncateThreshold)??!1,o=Math.max(Math.floor((t==null?void 0:t.truncateThreshold)??0),0);let l=n.length,s=e.length;if(r){const c=n.includes(`
10
+ `}function me(n,e,t){const r=t?.truncateThreshold??!1,o=Math.max(Math.floor(t?.truncateThreshold??0),0);let l=n.length,s=e.length;if(r){const c=n.includes(`
11
11
  `),i=e.includes(`
12
- `),h=An(n),a=An(e),f=c?`${n.split(h,o).join(h)}
12
+ `),h=Pn(n),a=Pn(e),f=c?`${n.split(h,o).join(h)}
13
13
  `:n,p=i?`${e.split(a,o).join(a)}
14
- `:e;l=f.length,s=p.length}const b=l!==n.length||s!==e.length,u=(c,i)=>n[c]===e[i];let F=0,y=0;const C=[];return Un(l,s,u,(c,i,h)=>{F!==i&&C.push(new A(j,n.slice(F,i))),y!==h&&C.push(new A(O,e.slice(y,h))),F=i+c,y=h+c,C.push(new A(M,e.slice(h,y)))}),F!==l&&C.push(new A(j,n.slice(F))),y!==s&&C.push(new A(O,e.slice(y))),[C,b]}function be(n,e,t){return e.reduce((r,o)=>r+(o[0]===M?o[1]:o[0]===n&&o[1].length!==0?t(o[1]):""),"")}class Dn{constructor(e,t){K(this,"op");K(this,"line");K(this,"lines");K(this,"changeColor");this.op=e,this.line=[],this.lines=[],this.changeColor=t}pushSubstring(e){this.pushDiff(new A(this.op,e))}pushLine(){this.lines.push(this.line.length!==1?new A(this.op,be(this.op,this.line,this.changeColor)):this.line[0][0]===this.op?this.line[0]:new A(this.op,this.line[0][1])),this.line.length=0}isLineEmpty(){return this.line.length===0}pushDiff(e){this.line.push(e)}align(e){const t=e[1];if(t.includes(`
14
+ `:e;l=f.length,s=p.length}const b=l!==n.length||s!==e.length,u=(c,i)=>n[c]===e[i];let F=0,y=0;const C=[];return qn(l,s,u,(c,i,h)=>{F!==i&&C.push(new A(j,n.slice(F,i))),y!==h&&C.push(new A(O,e.slice(y,h))),F=i+c,y=h+c,C.push(new A(M,e.slice(h,y)))}),F!==l&&C.push(new A(j,n.slice(F))),y!==s&&C.push(new A(O,e.slice(y))),[C,b]}function pe(n,e,t){return e.reduce((r,o)=>r+(o[0]===M?o[1]:o[0]===n&&o[1].length!==0?t(o[1]):""),"")}class An{op;line;lines;changeColor;constructor(e,t){this.op=e,this.line=[],this.lines=[],this.changeColor=t}pushSubstring(e){this.pushDiff(new A(this.op,e))}pushLine(){this.lines.push(this.line.length!==1?new A(this.op,pe(this.op,this.line,this.changeColor)):this.line[0][0]===this.op?this.line[0]:new A(this.op,this.line[0][1])),this.line.length=0}isLineEmpty(){return this.line.length===0}pushDiff(e){this.line.push(e)}align(e){const t=e[1];if(t.includes(`
15
15
  `)){const r=t.split(`
16
- `),o=r.length-1;r.forEach((l,s)=>{s<o?(this.pushSubstring(l),this.pushLine()):l.length!==0&&this.pushSubstring(l)})}else this.pushDiff(e)}moveLinesTo(e){this.isLineEmpty()||this.pushLine(),e.push(...this.lines),this.lines.length=0}}class ye{constructor(e,t){K(this,"deleteBuffer");K(this,"insertBuffer");K(this,"lines");this.deleteBuffer=e,this.insertBuffer=t,this.lines=[]}pushDiffCommonLine(e){this.lines.push(e)}pushDiffChangeLines(e){const t=e[1].length===0;(!t||this.deleteBuffer.isLineEmpty())&&this.deleteBuffer.pushDiff(e),(!t||this.insertBuffer.isLineEmpty())&&this.insertBuffer.pushDiff(e)}flushChangeLines(){this.deleteBuffer.moveLinesTo(this.lines),this.insertBuffer.moveLinesTo(this.lines)}align(e){const t=e[0],r=e[1];if(r.includes(`
16
+ `),o=r.length-1;r.forEach((l,s)=>{s<o?(this.pushSubstring(l),this.pushLine()):l.length!==0&&this.pushSubstring(l)})}else this.pushDiff(e)}moveLinesTo(e){this.isLineEmpty()||this.pushLine(),e.push(...this.lines),this.lines.length=0}}class we{deleteBuffer;insertBuffer;lines;constructor(e,t){this.deleteBuffer=e,this.insertBuffer=t,this.lines=[]}pushDiffCommonLine(e){this.lines.push(e)}pushDiffChangeLines(e){const t=e[1].length===0;(!t||this.deleteBuffer.isLineEmpty())&&this.deleteBuffer.pushDiff(e),(!t||this.insertBuffer.isLineEmpty())&&this.insertBuffer.pushDiff(e)}flushChangeLines(){this.deleteBuffer.moveLinesTo(this.lines),this.insertBuffer.moveLinesTo(this.lines)}align(e){const t=e[0],r=e[1];if(r.includes(`
17
17
  `)){const o=r.split(`
18
- `),l=o.length-1;o.forEach((s,b)=>{if(b===0){const u=new A(t,s);this.deleteBuffer.isLineEmpty()&&this.insertBuffer.isLineEmpty()?(this.flushChangeLines(),this.pushDiffCommonLine(u)):(this.pushDiffChangeLines(u),this.flushChangeLines())}else b<l?this.pushDiffCommonLine(new A(t,s)):s.length!==0&&this.pushDiffChangeLines(new A(t,s))})}else this.pushDiffChangeLines(e)}getLines(){return this.flushChangeLines(),this.lines}}function $e(n,e){const t=new Dn(j,e),r=new Dn(O,e),o=new ye(t,r);return n.forEach(l=>{switch(l[0]){case j:t.align(l);break;case O:r.align(l);break;default:o.align(l)}}),o.getLines()}function Fe(n,e){if(e){const t=n.length-1;return n.some((r,o)=>r[0]===M&&(o!==t||r[1]!==`
19
- `))}return n.some(t=>t[0]===M)}function Le(n,e,t){if(n!==e&&n.length!==0&&e.length!==0){const r=n.includes(`
18
+ `),l=o.length-1;o.forEach((s,b)=>{if(b===0){const u=new A(t,s);this.deleteBuffer.isLineEmpty()&&this.insertBuffer.isLineEmpty()?(this.flushChangeLines(),this.pushDiffCommonLine(u)):(this.pushDiffChangeLines(u),this.flushChangeLines())}else b<l?this.pushDiffCommonLine(new A(t,s)):s.length!==0&&this.pushDiffChangeLines(new A(t,s))})}else this.pushDiffChangeLines(e)}getLines(){return this.flushChangeLines(),this.lines}}function Ce(n,e){const t=new An(j,e),r=new An(O,e),o=new we(t,r);return n.forEach(l=>{switch(l[0]){case j:t.align(l);break;case O:r.align(l);break;default:o.align(l)}}),o.getLines()}function be(n,e){if(e){const t=n.length-1;return n.some((r,o)=>r[0]===M&&(o!==t||r[1]!==`
19
+ `))}return n.some(t=>t[0]===M)}function ye(n,e,t){if(n!==e&&n.length!==0&&e.length!==0){const r=n.includes(`
20
20
  `)||e.includes(`
21
- `),[o,l]=Wn(r?`${n}
21
+ `),[o,l]=Kn(r?`${n}
22
22
  `:n,r?`${e}
23
- `:e,!0,t);if(Fe(o,r)){const s=v(t),b=$e(o,s.changeColor);return fn(b,l,s)}}return rn(n.split(`
23
+ `:e,!0,t);if(be(o,r)){const s=Z(t),b=Ce(o,s.changeColor);return an(b,l,s)}}return tn(n.split(`
24
24
  `),e.split(`
25
- `),t)}function Wn(n,e,t,r){const[o,l]=Ce(n,e,r);return ne(o),[o,l]}function un(n,e){const{commonColor:t}=v(e);return t(n)}const{AsymmetricMatcher:Pe,DOMCollection:Ae,DOMElement:De,Immutable:_e,ReactElement:Me,ReactTestComponent:Ee}=Bn,Xn=[Ee,Me,De,Ae,_e,Pe,Bn.Error],hn={maxDepth:20,plugins:Xn},Jn={callToJSON:!1,maxDepth:8,plugins:Xn};function Te(n,e,t){if(Object.is(n,e))return"";const r=Pn(n);let o=r,l=!1;if(r==="object"&&typeof n.asymmetricMatch=="function"){if(n.$$typeof!==Symbol.for("jest.asymmetricMatcher")||typeof n.getExpectedType!="function")return;o=n.getExpectedType(),l=o==="string"}if(o!==Pn(e)){let a=function(L){return L.length<=h?L:`${L.slice(0,h)}...`};const{aAnnotation:s,aColor:b,aIndicator:u,bAnnotation:F,bColor:y,bIndicator:C}=v(t),D=gn(Jn,t);let c=Q(n,D),i=Q(e,D);const h=1e5;c=a(c),i=a(i);const f=`${b(`${u} ${s}:`)}
25
+ `),t)}function Kn(n,e,t,r){const[o,l]=me(n,e,r);return vn(o),[o,l]}function sn(n,e){const{commonColor:t}=Z(e);return t(n)}const{AsymmetricMatcher:$e,DOMCollection:Fe,DOMElement:Le,Immutable:Pe,ReactElement:Ae,ReactTestComponent:De}=jn,Wn=[De,Ae,Le,Fe,Pe,$e,jn.Error],un={maxDepth:20,plugins:Wn},Xn={callToJSON:!1,maxDepth:8,plugins:Wn};function _e(n,e,t){if(Object.is(n,e))return"";const r=Ln(n);let o=r,l=!1;if(r==="object"&&typeof n.asymmetricMatch=="function"){if(n.$$typeof!==Symbol.for("jest.asymmetricMatcher")||typeof n.getExpectedType!="function")return;o=n.getExpectedType(),l=o==="string"}if(o!==Ln(e)){let a=function(L){return L.length<=h?L:`${L.slice(0,h)}...`};const{aAnnotation:s,aColor:b,aIndicator:u,bAnnotation:F,bColor:y,bIndicator:C}=Z(t),D=hn(Xn,t);let c=Y(n,D),i=Y(e,D);const h=1e5;c=a(c),i=a(i);const f=`${b(`${u} ${s}:`)}
26
26
  ${c}`,p=`${y(`${C} ${F}:`)}
27
27
  ${i}`;return`${f}
28
28
 
29
- ${p}`}if(!l)switch(r){case"string":return rn(n.split(`
29
+ ${p}`}if(!l)switch(r){case"string":return tn(n.split(`
30
30
  `),e.split(`
31
- `),t);case"boolean":case"number":return Se(n,e,t);case"map":return cn(_n(n),_n(e),t);case"set":return cn(Mn(n),Mn(e),t);default:return cn(n,e,t)}}function Se(n,e,t){const r=Q(n,hn),o=Q(e,hn);return r===o?"":rn(r.split(`
31
+ `),t);case"boolean":case"number":return Me(n,e,t);case"map":return ln(Dn(n),Dn(e),t);case"set":return ln(_n(n),_n(e),t);default:return ln(n,e,t)}}function Me(n,e,t){const r=Y(n,un),o=Y(e,un);return r===o?"":tn(r.split(`
32
32
  `),o.split(`
33
- `),t)}function _n(n){return new Map(Array.from(n.entries()).sort())}function Mn(n){return new Set(Array.from(n.values()).sort())}function cn(n,e,t){let r,o=!1;try{const s=gn(hn,t);r=En(n,e,s,t)}catch{o=!0}const l=un(qn,t);if(r===void 0||r===l){const s=gn(Jn,t);r=En(n,e,s,t),r!==l&&!o&&(r=`${un(oe,t)}
33
+ `),t)}function Dn(n){return new Map(Array.from(n.entries()).sort())}function _n(n){return new Set(Array.from(n.values()).sort())}function ln(n,e,t){let r,o=!1;try{const s=hn(un,t);r=Mn(n,e,s,t)}catch{o=!0}const l=sn(Nn,t);if(r===void 0||r===l){const s=hn(Xn,t);r=Mn(n,e,s,t),r!==l&&!o&&(r=`${sn(ee,t)}
34
34
 
35
- ${r}`)}return r}function gn(n,e){const{compareKeys:t,printBasicPrototype:r,maxDepth:o}=v(e);return{...n,compareKeys:t,printBasicPrototype:r,maxDepth:o??n.maxDepth}}function En(n,e,t,r){const o={...t,indent:0},l=Q(n,o),s=Q(e,o);if(l===s)return un(qn,r);{const b=Q(n,t),u=Q(e,t);return we(b.split(`
35
+ ${r}`)}return r}function hn(n,e){const{compareKeys:t,printBasicPrototype:r,maxDepth:o}=Z(e);return{...n,compareKeys:t,printBasicPrototype:r,maxDepth:o??n.maxDepth}}function Mn(n,e,t,r){const o={...t,indent:0},l=Y(n,o),s=Y(e,o);if(l===s)return sn(Nn,r);{const b=Y(n,t),u=Y(e,t);return fe(b.split(`
36
36
  `),u.split(`
37
37
  `),l.split(`
38
38
  `),s.split(`
39
- `),r)}}const Tn=2e4;function Sn(n){return sn(n)==="Object"&&typeof n.asymmetricMatch=="function"}function On(n,e){const t=sn(n),r=sn(e);return t===r&&(t==="Object"||t==="Array")}function He(n,e,t){const{aAnnotation:r,bAnnotation:o}=v(t);if(typeof e=="string"&&typeof n=="string"&&e.length>0&&n.length>0&&e.length<=Tn&&n.length<=Tn&&e!==n){if(e.includes(`
39
+ `),r)}}const En=2e4;function Tn(n){return cn(n)==="Object"&&typeof n.asymmetricMatch=="function"}function Sn(n,e){const t=cn(n),r=cn(e);return t===r&&(t==="Object"||t==="Array")}function qe(n,e,t){const{aAnnotation:r,bAnnotation:o}=Z(t);if(typeof e=="string"&&typeof n=="string"&&e.length>0&&n.length>0&&e.length<=En&&n.length<=En&&e!==n){if(e.includes(`
40
40
  `)||n.includes(`
41
- `))return Le(e,n,t);const[y]=Wn(e,n),C=y.some(h=>h[0]===M),D=Oe(r,o),c=D(r)+Re(jn(y,j,C)),i=D(o)+Be(jn(y,O,C));return`${c}
42
- ${i}`}const l=wn(e,{forceWritable:!0}),s=wn(n,{forceWritable:!0}),{replacedExpected:b,replacedActual:u}=Vn(s,l);return Te(b,u,t)}function Vn(n,e,t=new WeakSet,r=new WeakSet){return n instanceof Error&&e instanceof Error&&typeof n.cause<"u"&&typeof e.cause>"u"?(delete n.cause,{replacedActual:n,replacedExpected:e}):On(n,e)?t.has(n)||r.has(e)?{replacedActual:n,replacedExpected:e}:(t.add(n),r.add(e),xn(e).forEach(o=>{const l=e[o],s=n[o];if(Sn(l))l.asymmetricMatch(s)&&(n[o]=l);else if(Sn(s))s.asymmetricMatch(l)&&(e[o]=s);else if(On(s,l)){const b=Vn(s,l,t,r);n[o]=b.replacedActual,e[o]=b.replacedExpected}}),{replacedActual:n,replacedExpected:e}):{replacedActual:n,replacedExpected:e}}function Oe(...n){const e=n.reduce((t,r)=>r.length>t?r.length:t,0);return t=>`${t}: ${" ".repeat(e-t.length)}`}const je="·";function Yn(n){return n.replace(/\s+$/gm,e=>je.repeat(e.length))}function Be(n){return Y.red(Yn(Rn(n)))}function Re(n){return Y.green(Yn(Rn(n)))}function jn(n,e,t){return n.reduce((r,o)=>r+(o[0]===M?o[1]:o[0]===e?t?Y.inverse(o[1]):o[1]:""),"")}export{j as DIFF_DELETE,M as DIFF_EQUAL,O as DIFF_INSERT,A as Diff,Te as diff,Kn as diffLinesRaw,rn as diffLinesUnified,we as diffLinesUnified2,Wn as diffStringsRaw,Le as diffStringsUnified,Oe as getLabelPrinter,He as printDiffOrStringify,Vn as replaceAsymmetricMatcher};
41
+ `))return ye(e,n,t);const[y]=Kn(e,n),C=y.some(h=>h[0]===M),D=Ee(r,o),c=D(r)+Oe(On(y,j,C)),i=D(o)+Se(On(y,O,C));return`${c}
42
+ ${i}`}const l=pn(e,{forceWritable:!0}),s=pn(n,{forceWritable:!0}),{replacedExpected:b,replacedActual:u}=Jn(s,l);return _e(b,u,t)}function Jn(n,e,t=new WeakSet,r=new WeakSet){return n instanceof Error&&e instanceof Error&&typeof n.cause<"u"&&typeof e.cause>"u"?(delete n.cause,{replacedActual:n,replacedExpected:e}):Sn(n,e)?t.has(n)||r.has(e)?{replacedActual:n,replacedExpected:e}:(t.add(n),r.add(e),Qn(e).forEach(o=>{const l=e[o],s=n[o];if(Tn(l))l.asymmetricMatch(s)&&(n[o]=l);else if(Tn(s))s.asymmetricMatch(l)&&(e[o]=s);else if(Sn(s,l)){const b=Jn(s,l,t,r);n[o]=b.replacedActual,e[o]=b.replacedExpected}}),{replacedActual:n,replacedExpected:e}):{replacedActual:n,replacedExpected:e}}function Ee(...n){const e=n.reduce((t,r)=>r.length>t?r.length:t,0);return t=>`${t}: ${" ".repeat(e-t.length)}`}const Te="·";function Vn(n){return n.replace(/\s+$/gm,e=>Te.repeat(e.length))}function Se(n){return V.red(Vn(Bn(n)))}function Oe(n){return V.green(Vn(Bn(n)))}function On(n,e,t){return n.reduce((r,o)=>r+(o[0]===M?o[1]:o[0]===e?t?V.inverse(o[1]):o[1]:""),"")}export{j as DIFF_DELETE,M as DIFF_EQUAL,O as DIFF_INSERT,A as Diff,_e as diff,In as diffLinesRaw,tn as diffLinesUnified,fe as diffLinesUnified2,Kn as diffStringsRaw,ye as diffStringsUnified,Ee as getLabelPrinter,qe as printDiffOrStringify,Jn as replaceAsymmetricMatcher};
@@ -1,2 +1,2 @@
1
- import{printDiffOrStringify as a}from"./diff.js";import{s as c,f as p}from"./chunk-_commonjsHelpers.js";import"../../../../../tinyrainbow@2.0.0/node_modules/tinyrainbow/dist/browser.js";import"../../../../../loupe@3.1.4/node_modules/loupe/lib/promise.js";const m="@@__IMMUTABLE_RECORD__@@",y="@@__IMMUTABLE_ITERABLE__@@";function g(e){return e&&(e[y]||e[m])}const d=Object.getPrototypeOf({});function u(e){return e instanceof Error?`<unserializable>: ${e.message}`:typeof e=="string"?`<unserializable>: ${e}`:"<unserializable>"}function o(e,n=new WeakMap){if(!e||typeof e=="string")return e;if(e instanceof Error&&"toJSON"in e&&typeof e.toJSON=="function"){const r=e.toJSON();return r&&r!==e&&typeof r=="object"&&(typeof e.message=="string"&&f(()=>r.message??(r.message=e.message)),typeof e.stack=="string"&&f(()=>r.stack??(r.stack=e.stack)),typeof e.name=="string"&&f(()=>r.name??(r.name=e.name)),e.cause!=null&&f(()=>r.cause??(r.cause=o(e.cause,n)))),o(r,n)}if(typeof e=="function")return`Function<${e.name||"anonymous"}>`;if(typeof e=="symbol")return e.toString();if(typeof e!="object")return e;if(typeof Buffer<"u"&&e instanceof Buffer)return`<Buffer(${e.length}) ...>`;if(typeof Uint8Array<"u"&&e instanceof Uint8Array)return`<Uint8Array(${e.length}) ...>`;if(g(e))return o(e.toJSON(),n);if(e instanceof Promise||e.constructor&&e.constructor.prototype==="AsyncFunction")return"Promise";if(typeof Element<"u"&&e instanceof Element)return e.tagName;if(typeof e.asymmetricMatch=="function")return`${e.toString()} ${p(e.sample)}`;if(typeof e.toJSON=="function")return o(e.toJSON(),n);if(n.has(e))return n.get(e);if(Array.isArray(e)){const r=new Array(e.length);return n.set(e,r),e.forEach((t,i)=>{try{r[i]=o(t,n)}catch(s){r[i]=u(s)}}),r}else{const r=Object.create(null);n.set(e,r);let t=e;for(;t&&t!==d;)Object.getOwnPropertyNames(t).forEach(i=>{if(!(i in r))try{r[i]=o(e[i],n)}catch(s){delete r[i],r[i]=u(s)}}),t=Object.getPrototypeOf(t);return r}}function f(e){try{return e()}catch{}}function O(e){return e.replace(/__(vite_ssr_import|vi_import)_\d+__\./g,"")}function _(e,n,r=new WeakSet){if(!e||typeof e!="object")return{message:String(e)};const t=e;(t.showDiff||t.showDiff===void 0&&t.expected!==void 0&&t.actual!==void 0)&&(t.diff=a(t.actual,t.expected,{...n,...t.diffOptions})),"expected"in t&&typeof t.expected!="string"&&(t.expected=c(t.expected,10)),"actual"in t&&typeof t.actual!="string"&&(t.actual=c(t.actual,10));try{typeof t.message=="string"&&(t.message=O(t.message))}catch{}try{!r.has(t)&&typeof t.cause=="object"&&(r.add(t),t.cause=_(t.cause,n,r))}catch{}try{return o(t)}catch(i){return o(new Error(`Failed to fully serialize error: ${i==null?void 0:i.message}
2
- Inner error message: ${t==null?void 0:t.message}`))}}export{_ as processError,o as serializeError,o as serializeValue};
1
+ import{printDiffOrStringify as a}from"./diff.js";import{s as c,f as p}from"./chunk-_commonjsHelpers.js";import"../../../../../tinyrainbow@2.0.0/node_modules/tinyrainbow/dist/browser.js";import"../../../../../loupe@3.1.4/node_modules/loupe/lib/promise.js";const m="@@__IMMUTABLE_RECORD__@@",y="@@__IMMUTABLE_ITERABLE__@@";function g(e){return e&&(e[y]||e[m])}const d=Object.getPrototypeOf({});function u(e){return e instanceof Error?`<unserializable>: ${e.message}`:typeof e=="string"?`<unserializable>: ${e}`:"<unserializable>"}function o(e,n=new WeakMap){if(!e||typeof e=="string")return e;if(e instanceof Error&&"toJSON"in e&&typeof e.toJSON=="function"){const r=e.toJSON();return r&&r!==e&&typeof r=="object"&&(typeof e.message=="string"&&f(()=>r.message??(r.message=e.message)),typeof e.stack=="string"&&f(()=>r.stack??(r.stack=e.stack)),typeof e.name=="string"&&f(()=>r.name??(r.name=e.name)),e.cause!=null&&f(()=>r.cause??(r.cause=o(e.cause,n)))),o(r,n)}if(typeof e=="function")return`Function<${e.name||"anonymous"}>`;if(typeof e=="symbol")return e.toString();if(typeof e!="object")return e;if(typeof Buffer<"u"&&e instanceof Buffer)return`<Buffer(${e.length}) ...>`;if(typeof Uint8Array<"u"&&e instanceof Uint8Array)return`<Uint8Array(${e.length}) ...>`;if(g(e))return o(e.toJSON(),n);if(e instanceof Promise||e.constructor&&e.constructor.prototype==="AsyncFunction")return"Promise";if(typeof Element<"u"&&e instanceof Element)return e.tagName;if(typeof e.asymmetricMatch=="function")return`${e.toString()} ${p(e.sample)}`;if(typeof e.toJSON=="function")return o(e.toJSON(),n);if(n.has(e))return n.get(e);if(Array.isArray(e)){const r=new Array(e.length);return n.set(e,r),e.forEach((t,i)=>{try{r[i]=o(t,n)}catch(s){r[i]=u(s)}}),r}else{const r=Object.create(null);n.set(e,r);let t=e;for(;t&&t!==d;)Object.getOwnPropertyNames(t).forEach(i=>{if(!(i in r))try{r[i]=o(e[i],n)}catch(s){delete r[i],r[i]=u(s)}}),t=Object.getPrototypeOf(t);return r}}function f(e){try{return e()}catch{}}function O(e){return e.replace(/__(vite_ssr_import|vi_import)_\d+__\./g,"")}function _(e,n,r=new WeakSet){if(!e||typeof e!="object")return{message:String(e)};const t=e;(t.showDiff||t.showDiff===void 0&&t.expected!==void 0&&t.actual!==void 0)&&(t.diff=a(t.actual,t.expected,{...n,...t.diffOptions})),"expected"in t&&typeof t.expected!="string"&&(t.expected=c(t.expected,10)),"actual"in t&&typeof t.actual!="string"&&(t.actual=c(t.actual,10));try{typeof t.message=="string"&&(t.message=O(t.message))}catch{}try{!r.has(t)&&typeof t.cause=="object"&&(r.add(t),t.cause=_(t.cause,n,r))}catch{}try{return o(t)}catch(i){return o(new Error(`Failed to fully serialize error: ${i?.message}
2
+ Inner error message: ${t?.message}`))}}export{_ as processError,o as serializeError,o as serializeValue};