@effect-uai/core 0.17.0 → 0.19.0-dev-20261109183959

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 (218) hide show
  1. package/README.md +5 -5
  2. package/dist/Content-D_Qfn8Ja.d.mts +48 -0
  3. package/dist/Content-D_Qfn8Ja.d.mts.map +1 -0
  4. package/dist/File-B923KvZ9.d.mts +46 -0
  5. package/dist/File-B923KvZ9.d.mts.map +1 -0
  6. package/dist/{Image-Cv6iBLTy.d.mts → Image-Bzc1H_UK.d.mts} +19 -8
  7. package/dist/Image-Bzc1H_UK.d.mts.map +1 -0
  8. package/dist/{Items-C7MyrYPX.d.mts → Items-Bvx8s9QH.d.mts} +109 -16
  9. package/dist/Items-Bvx8s9QH.d.mts.map +1 -0
  10. package/dist/{Loop-ChpaO-ya.d.mts → Loop-CeA0AelN.d.mts} +7 -6
  11. package/dist/Loop-CeA0AelN.d.mts.map +1 -0
  12. package/dist/Tool-Bkryw6-h.d.mts +206 -0
  13. package/dist/Tool-Bkryw6-h.d.mts.map +1 -0
  14. package/dist/ToolEvent-9inLx5cI.d.mts +22 -0
  15. package/dist/ToolEvent-9inLx5cI.d.mts.map +1 -0
  16. package/dist/ToolOutput-BNTIQgGB.d.mts +151 -0
  17. package/dist/ToolOutput-BNTIQgGB.d.mts.map +1 -0
  18. package/dist/Toolkit-D2VGeD5R.d.mts +212 -0
  19. package/dist/Toolkit-D2VGeD5R.d.mts.map +1 -0
  20. package/dist/browser/BrowserTool.d.mts +84 -22
  21. package/dist/browser/BrowserTool.d.mts.map +1 -1
  22. package/dist/browser/BrowserTool.mjs +5 -0
  23. package/dist/browser/BrowserTool.mjs.map +1 -1
  24. package/dist/capabilities/Capabilities.d.mts +1 -1
  25. package/dist/decision-model/Decision.test.mjs +4 -4
  26. package/dist/dist-B5K-y4Be.mjs +191 -0
  27. package/dist/dist-B5K-y4Be.mjs.map +1 -0
  28. package/dist/dist-CorQTQL-.mjs +1533 -0
  29. package/dist/dist-CorQTQL-.mjs.map +1 -0
  30. package/dist/dist-DNeuh84d.mjs +7 -0
  31. package/dist/dist-DNeuh84d.mjs.map +1 -0
  32. package/dist/dist-DzeSyeYF.mjs +10253 -0
  33. package/dist/dist-DzeSyeYF.mjs.map +1 -0
  34. package/dist/domain/File.d.mts +2 -0
  35. package/dist/domain/File.mjs +51 -0
  36. package/dist/domain/File.mjs.map +1 -0
  37. package/dist/domain/Image.d.mts +2 -2
  38. package/dist/domain/Image.mjs +12 -2
  39. package/dist/domain/Image.mjs.map +1 -1
  40. package/dist/domain/Items.d.mts +2 -2
  41. package/dist/domain/Items.mjs +65 -4
  42. package/dist/domain/Items.mjs.map +1 -1
  43. package/dist/domain/Realtime.d.mts +72 -490
  44. package/dist/domain/Realtime.d.mts.map +1 -1
  45. package/dist/domain/Research.d.mts +1 -1
  46. package/dist/domain/Transcript.test.mjs +3 -3
  47. package/dist/domain/Turn.d.mts +57 -262
  48. package/dist/domain/Turn.d.mts.map +1 -1
  49. package/dist/domain/Turn.mjs +1 -1
  50. package/dist/domain/Turn.test.mjs +2 -2
  51. package/dist/embedding-model/Embedding.d.mts +1 -1
  52. package/dist/embedding-model/EmbeddingModel.test.mjs +2 -2
  53. package/dist/embedding-model/EmbeddingModel.test.mjs.map +1 -1
  54. package/dist/image-generator/ImageGenerator.d.mts +10 -66
  55. package/dist/image-generator/ImageGenerator.d.mts.map +1 -1
  56. package/dist/index.C4tKZ0yW-LuFnBtmu.mjs +7042 -0
  57. package/dist/index.C4tKZ0yW-LuFnBtmu.mjs.map +1 -0
  58. package/dist/index.d.mts +10 -9
  59. package/dist/index.mjs +7 -6
  60. package/dist/language-model/LanguageModel.d.mts +2 -2
  61. package/dist/language-model/LanguageModel.test.mjs +2 -2
  62. package/dist/loop/Loop.d.mts +1 -1
  63. package/dist/loop/Loop.mjs.map +1 -1
  64. package/dist/loop/Loop.test.mjs +3 -3
  65. package/dist/math/Probability.test.mjs +2 -2
  66. package/dist/messenger/Messenger.d.mts +43 -289
  67. package/dist/messenger/Messenger.d.mts.map +1 -1
  68. package/dist/messenger/MessengerAdapter.test.mjs +3 -3
  69. package/dist/music-generator/MusicGenerator.test.mjs +3 -3
  70. package/dist/observability/Metrics.d.mts +1 -1
  71. package/dist/observability/Metrics.test.mjs +3 -3
  72. package/dist/observability/Telemetry.d.mts +1 -1
  73. package/dist/observability/Telemetry.mjs +1 -1
  74. package/dist/observability/Telemetry.mjs.map +1 -1
  75. package/dist/observability/Telemetry.test.mjs +4 -4
  76. package/dist/observability/Telemetry.test.mjs.map +1 -1
  77. package/dist/realtime/RealtimeSession.d.mts +1 -1
  78. package/dist/realtime/RealtimeSession.test.mjs +4 -4
  79. package/dist/retry/Retry.test.mjs +2 -2
  80. package/dist/sandbox/Sandbox.d.mts +32 -237
  81. package/dist/sandbox/Sandbox.d.mts.map +1 -1
  82. package/dist/speech-synthesizer/SpeechSynthesizer.test.mjs +3 -3
  83. package/dist/streaming/JSONL.test.mjs +2 -2
  84. package/dist/streaming/Multipart.d.mts +1 -1
  85. package/dist/streaming/Multipart.mjs +3 -2
  86. package/dist/streaming/Multipart.mjs.map +1 -1
  87. package/dist/streaming/Multipart.test.mjs +28 -0
  88. package/dist/streaming/Multipart.test.mjs.map +1 -0
  89. package/dist/streaming/SSE.d.mts +1 -1
  90. package/dist/streaming/SSE.mjs +2 -2
  91. package/dist/streaming/SSE.mjs.map +1 -1
  92. package/dist/streaming/SSE.test.mjs +2 -2
  93. package/dist/streaming/Settle.test.mjs +3 -3
  94. package/dist/streaming/WebSocketSession.d.mts +5 -3
  95. package/dist/streaming/WebSocketSession.d.mts.map +1 -1
  96. package/dist/streaming/WebSocketSession.mjs +22 -10
  97. package/dist/streaming/WebSocketSession.mjs.map +1 -1
  98. package/dist/streaming/WebSocketSession.test.mjs +41 -5
  99. package/dist/streaming/WebSocketSession.test.mjs.map +1 -1
  100. package/dist/structured-format/StructuredFormat.mjs.map +1 -1
  101. package/dist/structured-format/StructuredFormat.test.mjs +2 -2
  102. package/dist/testing/FakeWebSocket.d.mts +5 -1
  103. package/dist/testing/FakeWebSocket.d.mts.map +1 -1
  104. package/dist/testing/FakeWebSocket.mjs +12 -6
  105. package/dist/testing/FakeWebSocket.mjs.map +1 -1
  106. package/dist/testing/MockMessenger.d.mts +19 -134
  107. package/dist/testing/MockMessenger.d.mts.map +1 -1
  108. package/dist/testing/MockProvider.d.mts +1 -1
  109. package/dist/testing/MockSandbox.d.mts +65 -446
  110. package/dist/testing/MockSandbox.d.mts.map +1 -1
  111. package/dist/tool/Content.d.mts +2 -0
  112. package/dist/tool/Content.mjs +46 -0
  113. package/dist/tool/Content.mjs.map +1 -0
  114. package/dist/tool/Content.test.d.mts +1 -0
  115. package/dist/tool/Content.test.mjs +48 -0
  116. package/dist/tool/Content.test.mjs.map +1 -0
  117. package/dist/tool/HistoryCheck.d.mts +6 -15
  118. package/dist/tool/HistoryCheck.d.mts.map +1 -1
  119. package/dist/tool/HistoryCheck.mjs +10 -24
  120. package/dist/tool/HistoryCheck.mjs.map +1 -1
  121. package/dist/tool/Tool.d.mts +2 -2
  122. package/dist/tool/Tool.mjs +55 -130
  123. package/dist/tool/Tool.mjs.map +1 -1
  124. package/dist/tool/Tool.test.mjs +222 -178
  125. package/dist/tool/Tool.test.mjs.map +1 -1
  126. package/dist/tool/ToolDecision.d.mts +164 -0
  127. package/dist/tool/ToolDecision.d.mts.map +1 -0
  128. package/dist/tool/ToolDecision.mjs +146 -0
  129. package/dist/tool/ToolDecision.mjs.map +1 -0
  130. package/dist/tool/ToolDecision.test.d.mts +1 -0
  131. package/dist/tool/ToolDecision.test.mjs +330 -0
  132. package/dist/tool/ToolDecision.test.mjs.map +1 -0
  133. package/dist/tool/ToolEvent.d.mts +2 -2
  134. package/dist/tool/ToolEvent.mjs +2 -34
  135. package/dist/tool/ToolEvent.mjs.map +1 -1
  136. package/dist/tool/ToolOutput.d.mts +2 -0
  137. package/dist/tool/ToolOutput.mjs +128 -0
  138. package/dist/tool/ToolOutput.mjs.map +1 -0
  139. package/dist/tool/ToolOutput.test.d.mts +1 -0
  140. package/dist/tool/ToolOutput.test.mjs +153 -0
  141. package/dist/tool/ToolOutput.test.mjs.map +1 -0
  142. package/dist/tool/Toolkit.d.mts +2 -2
  143. package/dist/tool/Toolkit.mjs +230 -165
  144. package/dist/tool/Toolkit.mjs.map +1 -1
  145. package/dist/tool/Toolkit.test.mjs +433 -391
  146. package/dist/tool/Toolkit.test.mjs.map +1 -1
  147. package/dist/transcriber/Transcriber.test.mjs +3 -3
  148. package/dist/web-read/WebReadTool.d.mts +2 -2
  149. package/dist/web-read/WebReadTool.mjs +1 -0
  150. package/dist/web-read/WebReadTool.mjs.map +1 -1
  151. package/dist/web-search/WebSearchTool.d.mts +2 -2
  152. package/dist/web-search/WebSearchTool.mjs +1 -0
  153. package/dist/web-search/WebSearchTool.mjs.map +1 -1
  154. package/package.json +18 -10
  155. package/src/browser/BrowserTool.ts +5 -0
  156. package/src/domain/File.ts +79 -0
  157. package/src/domain/Image.ts +14 -4
  158. package/src/domain/Items.ts +39 -3
  159. package/src/embedding-model/EmbeddingModel.test.ts +2 -2
  160. package/src/index.ts +3 -2
  161. package/src/loop/Loop.ts +25 -14
  162. package/src/observability/Telemetry.test.ts +1 -1
  163. package/src/observability/Telemetry.ts +2 -2
  164. package/src/streaming/Multipart.test.ts +26 -0
  165. package/src/streaming/Multipart.ts +6 -5
  166. package/src/streaming/SSE.ts +2 -2
  167. package/src/streaming/WebSocketSession.test.ts +54 -2
  168. package/src/streaming/WebSocketSession.ts +27 -6
  169. package/src/structured-format/StructuredFormat.ts +1 -1
  170. package/src/testing/FakeWebSocket.ts +21 -6
  171. package/src/tool/Content.test.ts +40 -0
  172. package/src/tool/Content.ts +38 -0
  173. package/src/tool/HistoryCheck.ts +21 -26
  174. package/src/tool/Tool.test.ts +240 -241
  175. package/src/tool/Tool.ts +204 -309
  176. package/src/tool/ToolDecision.test.ts +301 -0
  177. package/src/tool/ToolDecision.ts +360 -0
  178. package/src/tool/ToolEvent.ts +21 -41
  179. package/src/tool/ToolOutput.test.ts +132 -0
  180. package/src/tool/ToolOutput.ts +198 -0
  181. package/src/tool/Toolkit.test.ts +594 -454
  182. package/src/tool/Toolkit.ts +631 -356
  183. package/src/web-read/WebReadTool.ts +2 -1
  184. package/src/web-search/WebSearchTool.ts +2 -1
  185. package/dist/Image-Cv6iBLTy.d.mts.map +0 -1
  186. package/dist/Items-C7MyrYPX.d.mts.map +0 -1
  187. package/dist/Loop-ChpaO-ya.d.mts.map +0 -1
  188. package/dist/Tool-BF78QWtn.d.mts +0 -314
  189. package/dist/Tool-BF78QWtn.d.mts.map +0 -1
  190. package/dist/ToolEvent-Di4a723B.d.mts +0 -144
  191. package/dist/ToolEvent-Di4a723B.d.mts.map +0 -1
  192. package/dist/ToolResult-BsYQRjmW.d.mts +0 -152
  193. package/dist/ToolResult-BsYQRjmW.d.mts.map +0 -1
  194. package/dist/Toolkit-tlL0F2YR.d.mts +0 -193
  195. package/dist/Toolkit-tlL0F2YR.d.mts.map +0 -1
  196. package/dist/dist-BaenoU1A.mjs +0 -145
  197. package/dist/dist-BaenoU1A.mjs.map +0 -1
  198. package/dist/dist-nohcnkD6.mjs +0 -182
  199. package/dist/dist-nohcnkD6.mjs.map +0 -1
  200. package/dist/magic-string.es-CB2hOw9v.mjs +0 -1014
  201. package/dist/magic-string.es-CB2hOw9v.mjs.map +0 -1
  202. package/dist/test.DNmyFkvJ-YPzDR0Co.mjs +0 -10254
  203. package/dist/test.DNmyFkvJ-YPzDR0Co.mjs.map +0 -1
  204. package/dist/tool/Approval.d.mts +0 -113
  205. package/dist/tool/Approval.d.mts.map +0 -1
  206. package/dist/tool/Approval.mjs +0 -80
  207. package/dist/tool/Approval.mjs.map +0 -1
  208. package/dist/tool/Approval.test.mjs +0 -371
  209. package/dist/tool/Approval.test.mjs.map +0 -1
  210. package/dist/tool/ToolResult.d.mts +0 -2
  211. package/dist/tool/ToolResult.mjs +0 -85
  212. package/dist/tool/ToolResult.mjs.map +0 -1
  213. package/dist/utils-CiH_DjFW.mjs +0 -3918
  214. package/dist/utils-CiH_DjFW.mjs.map +0 -1
  215. package/src/tool/Approval.test.ts +0 -400
  216. package/src/tool/Approval.ts +0 -181
  217. package/src/tool/ToolResult.ts +0 -114
  218. /package/dist/{tool/Approval.test.d.mts → streaming/Multipart.test.d.mts} +0 -0
@@ -1 +0,0 @@
1
- {"version":3,"file":"dist-BaenoU1A.mjs","names":["exports"],"sources":["../../../node_modules/.pnpm/vite@7.3.2_@types+node@26.2.0_jiti@2.6.1_lightningcss@1.32.0_tsx@4.23.12_yaml@2.9.0/node_modules/vite/dist/node/module-runner.js","../../../node_modules/.pnpm/expect-type@1.3.0/node_modules/expect-type/dist/branding.js","../../../node_modules/.pnpm/expect-type@1.3.0/node_modules/expect-type/dist/messages.js","../../../node_modules/.pnpm/expect-type@1.3.0/node_modules/expect-type/dist/overloads.js","../../../node_modules/.pnpm/expect-type@1.3.0/node_modules/expect-type/dist/utils.js","../../../node_modules/.pnpm/expect-type@1.3.0/node_modules/expect-type/dist/index.js","../../../node_modules/.pnpm/vitest@4.1.11_@types+node@26.2.0_vite@7.3.2_@types+node@26.2.0_jiti@2.6.1_lightningcss@1.32.0_tsx@4.23.12_yaml@2.9.0_/node_modules/vitest/dist/index.js"],"sourcesContent":["let SOURCEMAPPING_URL = \"sourceMa\";\nSOURCEMAPPING_URL += \"ppingURL\";\nconst isWindows = typeof process < \"u\" && process.platform === \"win32\";\nfunction unwrapId(id) {\n\treturn id.startsWith(\"/@id/\") ? id.slice(5).replace(\"__x00__\", \"\\0\") : id;\n}\nconst windowsSlashRE = /\\\\/g;\nfunction slash(p) {\n\treturn p.replace(windowsSlashRE, \"/\");\n}\nconst postfixRE = /[?#].*$/;\nfunction cleanUrl(url) {\n\treturn url.replace(postfixRE, \"\");\n}\nfunction isPrimitive(value) {\n\treturn !value || typeof value != \"object\" && typeof value != \"function\";\n}\nconst AsyncFunction = async function() {}.constructor;\nlet asyncFunctionDeclarationPaddingLineCount;\nfunction getAsyncFunctionDeclarationPaddingLineCount() {\n\tif (asyncFunctionDeclarationPaddingLineCount === void 0) {\n\t\tlet body = \"/*code*/\", source = new AsyncFunction(\"a\", \"b\", body).toString();\n\t\tasyncFunctionDeclarationPaddingLineCount = source.slice(0, source.indexOf(body)).split(\"\\n\").length - 1;\n\t}\n\treturn asyncFunctionDeclarationPaddingLineCount;\n}\nfunction promiseWithResolvers() {\n\tlet resolve$1, reject;\n\treturn {\n\t\tpromise: new Promise((_resolve, _reject) => {\n\t\t\tresolve$1 = _resolve, reject = _reject;\n\t\t}),\n\t\tresolve: resolve$1,\n\t\treject\n\t};\n}\nconst _DRIVE_LETTER_START_RE = /^[A-Za-z]:\\//;\nfunction normalizeWindowsPath(input = \"\") {\n\treturn input && input.replace(/\\\\/g, \"/\").replace(_DRIVE_LETTER_START_RE, (r) => r.toUpperCase());\n}\nconst _IS_ABSOLUTE_RE = /^[/\\\\](?![/\\\\])|^[/\\\\]{2}(?!\\.)|^[A-Za-z]:[/\\\\]/, _DRIVE_LETTER_RE = /^[A-Za-z]:$/;\nfunction cwd() {\n\treturn typeof process < \"u\" && typeof process.cwd == \"function\" ? process.cwd().replace(/\\\\/g, \"/\") : \"/\";\n}\nconst resolve = function(...arguments_) {\n\targuments_ = arguments_.map((argument) => normalizeWindowsPath(argument));\n\tlet resolvedPath = \"\", resolvedAbsolute = !1;\n\tfor (let index = arguments_.length - 1; index >= -1 && !resolvedAbsolute; index--) {\n\t\tlet path = index >= 0 ? arguments_[index] : cwd();\n\t\t!path || path.length === 0 || (resolvedPath = `${path}/${resolvedPath}`, resolvedAbsolute = isAbsolute(path));\n\t}\n\treturn resolvedPath = normalizeString(resolvedPath, !resolvedAbsolute), resolvedAbsolute && !isAbsolute(resolvedPath) ? `/${resolvedPath}` : resolvedPath.length > 0 ? resolvedPath : \".\";\n};\nfunction normalizeString(path, allowAboveRoot) {\n\tlet res = \"\", lastSegmentLength = 0, lastSlash = -1, dots = 0, char = null;\n\tfor (let index = 0; index <= path.length; ++index) {\n\t\tif (index < path.length) char = path[index];\n\t\telse if (char === \"/\") break;\n\t\telse char = \"/\";\n\t\tif (char === \"/\") {\n\t\t\tif (!(lastSlash === index - 1 || dots === 1)) if (dots === 2) {\n\t\t\t\tif (res.length < 2 || lastSegmentLength !== 2 || res[res.length - 1] !== \".\" || res[res.length - 2] !== \".\") {\n\t\t\t\t\tif (res.length > 2) {\n\t\t\t\t\t\tlet lastSlashIndex = res.lastIndexOf(\"/\");\n\t\t\t\t\t\tlastSlashIndex === -1 ? (res = \"\", lastSegmentLength = 0) : (res = res.slice(0, lastSlashIndex), lastSegmentLength = res.length - 1 - res.lastIndexOf(\"/\")), lastSlash = index, dots = 0;\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t} else if (res.length > 0) {\n\t\t\t\t\t\tres = \"\", lastSegmentLength = 0, lastSlash = index, dots = 0;\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tallowAboveRoot && (res += res.length > 0 ? \"/..\" : \"..\", lastSegmentLength = 2);\n\t\t\t} else res.length > 0 ? res += `/${path.slice(lastSlash + 1, index)}` : res = path.slice(lastSlash + 1, index), lastSegmentLength = index - lastSlash - 1;\n\t\t\tlastSlash = index, dots = 0;\n\t\t} else char === \".\" && dots !== -1 ? ++dots : dots = -1;\n\t}\n\treturn res;\n}\nconst isAbsolute = function(p) {\n\treturn _IS_ABSOLUTE_RE.test(p);\n}, dirname = function(p) {\n\tlet segments = normalizeWindowsPath(p).replace(/\\/$/, \"\").split(\"/\").slice(0, -1);\n\treturn segments.length === 1 && _DRIVE_LETTER_RE.test(segments[0]) && (segments[0] += \"/\"), segments.join(\"/\") || (isAbsolute(p) ? \"/\" : \".\");\n}, decodeBase64 = typeof atob < \"u\" ? atob : (str) => Buffer.from(str, \"base64\").toString(\"utf-8\"), percentRegEx = /%/g, backslashRegEx = /\\\\/g, newlineRegEx = /\\n/g, carriageReturnRegEx = /\\r/g, tabRegEx = /\\t/g, questionRegex = /\\?/g, hashRegex = /#/g;\nfunction encodePathChars(filepath) {\n\treturn filepath.indexOf(\"%\") !== -1 && (filepath = filepath.replace(percentRegEx, \"%25\")), !isWindows && filepath.indexOf(\"\\\\\") !== -1 && (filepath = filepath.replace(backslashRegEx, \"%5C\")), filepath.indexOf(\"\\n\") !== -1 && (filepath = filepath.replace(newlineRegEx, \"%0A\")), filepath.indexOf(\"\\r\") !== -1 && (filepath = filepath.replace(carriageReturnRegEx, \"%0D\")), filepath.indexOf(\"\t\") !== -1 && (filepath = filepath.replace(tabRegEx, \"%09\")), filepath;\n}\nconst posixDirname = dirname, posixResolve = resolve;\nfunction posixPathToFileHref(posixPath) {\n\tlet resolved = posixResolve(posixPath), filePathLast = posixPath.charCodeAt(posixPath.length - 1);\n\treturn (filePathLast === 47 || isWindows && filePathLast === 92) && resolved[resolved.length - 1] !== \"/\" && (resolved += \"/\"), resolved = encodePathChars(resolved), resolved.indexOf(\"?\") !== -1 && (resolved = resolved.replace(questionRegex, \"%3F\")), resolved.indexOf(\"#\") !== -1 && (resolved = resolved.replace(hashRegex, \"%23\")), new URL(`file://${resolved}`).href;\n}\nfunction toWindowsPath(path) {\n\treturn path.replace(/\\//g, \"\\\\\");\n}\nvar comma = 44, chars = \"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/\", intToChar = new Uint8Array(64), charToInt = new Uint8Array(128);\nfor (let i = 0; i < chars.length; i++) {\n\tlet c = chars.charCodeAt(i);\n\tintToChar[i] = c, charToInt[c] = i;\n}\nfunction decodeInteger(reader, relative) {\n\tlet value = 0, shift = 0, integer = 0;\n\tdo\n\t\tinteger = charToInt[reader.next()], value |= (integer & 31) << shift, shift += 5;\n\twhile (integer & 32);\n\tlet shouldNegate = value & 1;\n\treturn value >>>= 1, shouldNegate && (value = -2147483648 | -value), relative + value;\n}\nfunction hasMoreVlq(reader, max) {\n\treturn reader.pos >= max ? !1 : reader.peek() !== comma;\n}\nvar StringReader = class {\n\tconstructor(buffer) {\n\t\tthis.pos = 0, this.buffer = buffer;\n\t}\n\tnext() {\n\t\treturn this.buffer.charCodeAt(this.pos++);\n\t}\n\tpeek() {\n\t\treturn this.buffer.charCodeAt(this.pos);\n\t}\n\tindexOf(char) {\n\t\tlet { buffer, pos } = this, idx = buffer.indexOf(char, pos);\n\t\treturn idx === -1 ? buffer.length : idx;\n\t}\n};\nfunction decode(mappings) {\n\tlet { length } = mappings, reader = new StringReader(mappings), decoded = [], genColumn = 0, sourcesIndex = 0, sourceLine = 0, sourceColumn = 0, namesIndex = 0;\n\tdo {\n\t\tlet semi = reader.indexOf(\";\"), line = [], sorted = !0, lastCol = 0;\n\t\tfor (genColumn = 0; reader.pos < semi;) {\n\t\t\tlet seg;\n\t\t\tgenColumn = decodeInteger(reader, genColumn), genColumn < lastCol && (sorted = !1), lastCol = genColumn, hasMoreVlq(reader, semi) ? (sourcesIndex = decodeInteger(reader, sourcesIndex), sourceLine = decodeInteger(reader, sourceLine), sourceColumn = decodeInteger(reader, sourceColumn), hasMoreVlq(reader, semi) ? (namesIndex = decodeInteger(reader, namesIndex), seg = [\n\t\t\t\tgenColumn,\n\t\t\t\tsourcesIndex,\n\t\t\t\tsourceLine,\n\t\t\t\tsourceColumn,\n\t\t\t\tnamesIndex\n\t\t\t]) : seg = [\n\t\t\t\tgenColumn,\n\t\t\t\tsourcesIndex,\n\t\t\t\tsourceLine,\n\t\t\t\tsourceColumn\n\t\t\t]) : seg = [genColumn], line.push(seg), reader.pos++;\n\t\t}\n\t\tsorted || sort(line), decoded.push(line), reader.pos = semi + 1;\n\t} while (reader.pos <= length);\n\treturn decoded;\n}\nfunction sort(line) {\n\tline.sort(sortComparator);\n}\nfunction sortComparator(a, b) {\n\treturn a[0] - b[0];\n}\nvar COLUMN = 0, SOURCES_INDEX = 1, SOURCE_LINE = 2, SOURCE_COLUMN = 3, NAMES_INDEX = 4, found = !1;\nfunction binarySearch(haystack, needle, low, high) {\n\tfor (; low <= high;) {\n\t\tlet mid = low + (high - low >> 1), cmp = haystack[mid][COLUMN] - needle;\n\t\tif (cmp === 0) return found = !0, mid;\n\t\tcmp < 0 ? low = mid + 1 : high = mid - 1;\n\t}\n\treturn found = !1, low - 1;\n}\nfunction upperBound(haystack, needle, index) {\n\tfor (let i = index + 1; i < haystack.length && haystack[i][COLUMN] === needle; index = i++);\n\treturn index;\n}\nfunction lowerBound(haystack, needle, index) {\n\tfor (let i = index - 1; i >= 0 && haystack[i][COLUMN] === needle; index = i--);\n\treturn index;\n}\nfunction memoizedBinarySearch(haystack, needle, state, key) {\n\tlet { lastKey, lastNeedle, lastIndex } = state, low = 0, high = haystack.length - 1;\n\tif (key === lastKey) {\n\t\tif (needle === lastNeedle) return found = lastIndex !== -1 && haystack[lastIndex][COLUMN] === needle, lastIndex;\n\t\tneedle >= lastNeedle ? low = lastIndex === -1 ? 0 : lastIndex : high = lastIndex;\n\t}\n\treturn state.lastKey = key, state.lastNeedle = needle, state.lastIndex = binarySearch(haystack, needle, low, high);\n}\nvar LINE_GTR_ZERO = \"`line` must be greater than 0 (lines start at line 1)\", COL_GTR_EQ_ZERO = \"`column` must be greater than or equal to 0 (columns start at column 0)\", LEAST_UPPER_BOUND = -1, GREATEST_LOWER_BOUND = 1;\nfunction cast(map) {\n\treturn map;\n}\nfunction decodedMappings(map) {\n\tvar _a;\n\treturn (_a = cast(map))._decoded || (_a._decoded = decode(cast(map)._encoded));\n}\nfunction originalPositionFor(map, needle) {\n\tlet { line, column, bias } = needle;\n\tif (line--, line < 0) throw Error(LINE_GTR_ZERO);\n\tif (column < 0) throw Error(COL_GTR_EQ_ZERO);\n\tlet decoded = decodedMappings(map);\n\tif (line >= decoded.length) return OMapping(null, null, null, null);\n\tlet segments = decoded[line], index = traceSegmentInternal(segments, cast(map)._decodedMemo, line, column, bias || GREATEST_LOWER_BOUND);\n\tif (index === -1) return OMapping(null, null, null, null);\n\tlet segment = segments[index];\n\tif (segment.length === 1) return OMapping(null, null, null, null);\n\tlet { names, resolvedSources } = map;\n\treturn OMapping(resolvedSources[segment[SOURCES_INDEX]], segment[SOURCE_LINE] + 1, segment[SOURCE_COLUMN], segment.length === 5 ? names[segment[NAMES_INDEX]] : null);\n}\nfunction OMapping(source, line, column, name) {\n\treturn {\n\t\tsource,\n\t\tline,\n\t\tcolumn,\n\t\tname\n\t};\n}\nfunction traceSegmentInternal(segments, memo, line, column, bias) {\n\tlet index = memoizedBinarySearch(segments, column, memo, line);\n\treturn found ? index = (bias === LEAST_UPPER_BOUND ? upperBound : lowerBound)(segments, column, index) : bias === LEAST_UPPER_BOUND && index++, index === -1 || index === segments.length ? -1 : index;\n}\nvar DecodedMap = class {\n\t_encoded;\n\t_decoded;\n\t_decodedMemo;\n\turl;\n\tfile;\n\tversion;\n\tnames = [];\n\tresolvedSources;\n\tconstructor(map, from) {\n\t\tthis.map = map;\n\t\tlet { mappings, names, sources } = map;\n\t\tthis.version = map.version, this.names = names || [], this._encoded = mappings || \"\", this._decodedMemo = memoizedState(), this.url = from, this.file = from;\n\t\tlet originDir = posixDirname(from);\n\t\tthis.resolvedSources = (sources || []).map((s) => posixResolve(originDir, s || \"\"));\n\t}\n};\nfunction memoizedState() {\n\treturn {\n\t\tlastKey: -1,\n\t\tlastNeedle: -1,\n\t\tlastIndex: -1\n\t};\n}\nfunction getOriginalPosition(map, needle) {\n\tlet result = originalPositionFor(map, needle);\n\treturn result.column == null ? null : result;\n}\nconst MODULE_RUNNER_SOURCEMAPPING_REGEXP = /* @__PURE__ */ RegExp(`//# ${SOURCEMAPPING_URL}=data:application/json;base64,(.+)`);\nvar EvaluatedModuleNode = class {\n\timporters = /* @__PURE__ */ new Set();\n\timports = /* @__PURE__ */ new Set();\n\tevaluated = !1;\n\tmeta;\n\tpromise;\n\texports;\n\tfile;\n\tmap;\n\tconstructor(id, url) {\n\t\tthis.id = id, this.url = url, this.file = cleanUrl(id);\n\t}\n}, EvaluatedModules = class {\n\tidToModuleMap = /* @__PURE__ */ new Map();\n\tfileToModulesMap = /* @__PURE__ */ new Map();\n\turlToIdModuleMap = /* @__PURE__ */ new Map();\n\tgetModuleById(id) {\n\t\treturn this.idToModuleMap.get(id);\n\t}\n\tgetModulesByFile(file) {\n\t\treturn this.fileToModulesMap.get(file);\n\t}\n\tgetModuleByUrl(url) {\n\t\treturn this.urlToIdModuleMap.get(unwrapId(url));\n\t}\n\tensureModule(id, url) {\n\t\tif (id = normalizeModuleId(id), this.idToModuleMap.has(id)) {\n\t\t\tlet moduleNode$1 = this.idToModuleMap.get(id);\n\t\t\treturn this.urlToIdModuleMap.set(url, moduleNode$1), moduleNode$1;\n\t\t}\n\t\tlet moduleNode = new EvaluatedModuleNode(id, url);\n\t\tthis.idToModuleMap.set(id, moduleNode), this.urlToIdModuleMap.set(url, moduleNode);\n\t\tlet fileModules = this.fileToModulesMap.get(moduleNode.file) || /* @__PURE__ */ new Set();\n\t\treturn fileModules.add(moduleNode), this.fileToModulesMap.set(moduleNode.file, fileModules), moduleNode;\n\t}\n\tinvalidateModule(node) {\n\t\tnode.evaluated = !1, node.meta = void 0, node.map = void 0, node.promise = void 0, node.exports = void 0, node.imports.clear();\n\t}\n\tgetModuleSourceMapById(id) {\n\t\tlet mod = this.getModuleById(id);\n\t\tif (!mod) return null;\n\t\tif (mod.map) return mod.map;\n\t\tif (!mod.meta || !(\"code\" in mod.meta)) return null;\n\t\tlet pattern = `//# ${SOURCEMAPPING_URL}=data:application/json;base64,`, lastIndex = mod.meta.code.lastIndexOf(pattern);\n\t\tif (lastIndex === -1) return null;\n\t\tlet mapString = MODULE_RUNNER_SOURCEMAPPING_REGEXP.exec(mod.meta.code.slice(lastIndex))?.[1];\n\t\treturn mapString ? (mod.map = new DecodedMap(JSON.parse(decodeBase64(mapString)), mod.file), mod.map) : null;\n\t}\n\tclear() {\n\t\tthis.idToModuleMap.clear(), this.fileToModulesMap.clear(), this.urlToIdModuleMap.clear();\n\t}\n};\nconst prefixedBuiltins = new Set([\n\t\"node:sea\",\n\t\"node:sqlite\",\n\t\"node:test\",\n\t\"node:test/reporters\"\n]);\nfunction normalizeModuleId(file) {\n\treturn prefixedBuiltins.has(file) ? file : slash(file).replace(/^\\/@fs\\//, isWindows ? \"\" : \"/\").replace(/^node:/, \"\").replace(/^\\/+/, \"/\").replace(/^file:\\/+/, isWindows ? \"\" : \"/\");\n}\nvar HMRContext = class {\n\tnewListeners;\n\tconstructor(hmrClient, ownerPath) {\n\t\tthis.hmrClient = hmrClient, this.ownerPath = ownerPath, hmrClient.dataMap.has(ownerPath) || hmrClient.dataMap.set(ownerPath, {});\n\t\tlet mod = hmrClient.hotModulesMap.get(ownerPath);\n\t\tmod && (mod.callbacks = []);\n\t\tlet staleListeners = hmrClient.ctxToListenersMap.get(ownerPath);\n\t\tif (staleListeners) for (let [event, staleFns] of staleListeners) {\n\t\t\tlet listeners = hmrClient.customListenersMap.get(event);\n\t\t\tlisteners && hmrClient.customListenersMap.set(event, listeners.filter((l) => !staleFns.includes(l)));\n\t\t}\n\t\tthis.newListeners = /* @__PURE__ */ new Map(), hmrClient.ctxToListenersMap.set(ownerPath, this.newListeners);\n\t}\n\tget data() {\n\t\treturn this.hmrClient.dataMap.get(this.ownerPath);\n\t}\n\taccept(deps, callback) {\n\t\tif (typeof deps == \"function\" || !deps) this.acceptDeps([this.ownerPath], ([mod]) => deps?.(mod));\n\t\telse if (typeof deps == \"string\") this.acceptDeps([deps], ([mod]) => callback?.(mod));\n\t\telse if (Array.isArray(deps)) this.acceptDeps(deps, callback);\n\t\telse throw Error(\"invalid hot.accept() usage.\");\n\t}\n\tacceptExports(_, callback) {\n\t\tthis.acceptDeps([this.ownerPath], ([mod]) => callback?.(mod));\n\t}\n\tdispose(cb) {\n\t\tthis.hmrClient.disposeMap.set(this.ownerPath, cb);\n\t}\n\tprune(cb) {\n\t\tthis.hmrClient.pruneMap.set(this.ownerPath, cb);\n\t}\n\tdecline() {}\n\tinvalidate(message) {\n\t\tlet firstInvalidatedBy = this.hmrClient.currentFirstInvalidatedBy ?? this.ownerPath;\n\t\tthis.hmrClient.notifyListeners(\"vite:invalidate\", {\n\t\t\tpath: this.ownerPath,\n\t\t\tmessage,\n\t\t\tfirstInvalidatedBy\n\t\t}), this.send(\"vite:invalidate\", {\n\t\t\tpath: this.ownerPath,\n\t\t\tmessage,\n\t\t\tfirstInvalidatedBy\n\t\t}), this.hmrClient.logger.debug(`invalidate ${this.ownerPath}${message ? `: ${message}` : \"\"}`);\n\t}\n\ton(event, cb) {\n\t\tlet addToMap = (map) => {\n\t\t\tlet existing = map.get(event) || [];\n\t\t\texisting.push(cb), map.set(event, existing);\n\t\t};\n\t\taddToMap(this.hmrClient.customListenersMap), addToMap(this.newListeners);\n\t}\n\toff(event, cb) {\n\t\tlet removeFromMap = (map) => {\n\t\t\tlet existing = map.get(event);\n\t\t\tif (existing === void 0) return;\n\t\t\tlet pruned = existing.filter((l) => l !== cb);\n\t\t\tif (pruned.length === 0) {\n\t\t\t\tmap.delete(event);\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tmap.set(event, pruned);\n\t\t};\n\t\tremoveFromMap(this.hmrClient.customListenersMap), removeFromMap(this.newListeners);\n\t}\n\tsend(event, data) {\n\t\tthis.hmrClient.send({\n\t\t\ttype: \"custom\",\n\t\t\tevent,\n\t\t\tdata\n\t\t});\n\t}\n\tacceptDeps(deps, callback = () => {}) {\n\t\tlet mod = this.hmrClient.hotModulesMap.get(this.ownerPath) || {\n\t\t\tid: this.ownerPath,\n\t\t\tcallbacks: []\n\t\t};\n\t\tmod.callbacks.push({\n\t\t\tdeps,\n\t\t\tfn: callback\n\t\t}), this.hmrClient.hotModulesMap.set(this.ownerPath, mod);\n\t}\n}, HMRClient = class {\n\thotModulesMap = /* @__PURE__ */ new Map();\n\tdisposeMap = /* @__PURE__ */ new Map();\n\tpruneMap = /* @__PURE__ */ new Map();\n\tdataMap = /* @__PURE__ */ new Map();\n\tcustomListenersMap = /* @__PURE__ */ new Map();\n\tctxToListenersMap = /* @__PURE__ */ new Map();\n\tcurrentFirstInvalidatedBy;\n\tconstructor(logger, transport, importUpdatedModule) {\n\t\tthis.logger = logger, this.transport = transport, this.importUpdatedModule = importUpdatedModule;\n\t}\n\tasync notifyListeners(event, data) {\n\t\tlet cbs = this.customListenersMap.get(event);\n\t\tcbs && await Promise.allSettled(cbs.map((cb) => cb(data)));\n\t}\n\tsend(payload) {\n\t\tthis.transport.send(payload).catch((err) => {\n\t\t\tthis.logger.error(err);\n\t\t});\n\t}\n\tclear() {\n\t\tthis.hotModulesMap.clear(), this.disposeMap.clear(), this.pruneMap.clear(), this.dataMap.clear(), this.customListenersMap.clear(), this.ctxToListenersMap.clear();\n\t}\n\tasync prunePaths(paths) {\n\t\tawait Promise.all(paths.map((path) => {\n\t\t\tlet disposer = this.disposeMap.get(path);\n\t\t\tif (disposer) return disposer(this.dataMap.get(path));\n\t\t})), await Promise.all(paths.map((path) => {\n\t\t\tlet fn = this.pruneMap.get(path);\n\t\t\tif (fn) return fn(this.dataMap.get(path));\n\t\t}));\n\t}\n\twarnFailedUpdate(err, path) {\n\t\t(!(err instanceof Error) || !err.message.includes(\"fetch\")) && this.logger.error(err), this.logger.error(`Failed to reload ${path}. This could be due to syntax errors or importing non-existent modules. (see errors above)`);\n\t}\n\tupdateQueue = [];\n\tpendingUpdateQueue = !1;\n\tasync queueUpdate(payload) {\n\t\tif (this.updateQueue.push(this.fetchUpdate(payload)), !this.pendingUpdateQueue) {\n\t\t\tthis.pendingUpdateQueue = !0, await Promise.resolve(), this.pendingUpdateQueue = !1;\n\t\t\tlet loading = [...this.updateQueue];\n\t\t\tthis.updateQueue = [], (await Promise.all(loading)).forEach((fn) => fn && fn());\n\t\t}\n\t}\n\tasync fetchUpdate(update) {\n\t\tlet { path, acceptedPath, firstInvalidatedBy } = update, mod = this.hotModulesMap.get(path);\n\t\tif (!mod) return;\n\t\tlet fetchedModule, isSelfUpdate = path === acceptedPath, qualifiedCallbacks = mod.callbacks.filter(({ deps }) => deps.includes(acceptedPath));\n\t\tif (isSelfUpdate || qualifiedCallbacks.length > 0) {\n\t\t\tlet disposer = this.disposeMap.get(acceptedPath);\n\t\t\tdisposer && await disposer(this.dataMap.get(acceptedPath));\n\t\t\ttry {\n\t\t\t\tfetchedModule = await this.importUpdatedModule(update);\n\t\t\t} catch (e) {\n\t\t\t\tthis.warnFailedUpdate(e, acceptedPath);\n\t\t\t}\n\t\t}\n\t\treturn () => {\n\t\t\ttry {\n\t\t\t\tthis.currentFirstInvalidatedBy = firstInvalidatedBy;\n\t\t\t\tfor (let { deps, fn } of qualifiedCallbacks) fn(deps.map((dep) => dep === acceptedPath ? fetchedModule : void 0));\n\t\t\t\tlet loggedPath = isSelfUpdate ? path : `${acceptedPath} via ${path}`;\n\t\t\t\tthis.logger.debug(`hot updated: ${loggedPath}`);\n\t\t\t} finally {\n\t\t\t\tthis.currentFirstInvalidatedBy = void 0;\n\t\t\t}\n\t\t};\n\t}\n};\nfunction analyzeImportedModDifference(mod, rawId, moduleType, metadata) {\n\tif (!metadata?.isDynamicImport && metadata?.importedNames?.length) {\n\t\tlet missingBindings = metadata.importedNames.filter((s) => !(s in mod));\n\t\tif (missingBindings.length) {\n\t\t\tlet lastBinding = missingBindings[missingBindings.length - 1];\n\t\t\tthrow moduleType === \"module\" ? SyntaxError(`[vite] The requested module '${rawId}' does not provide an export named '${lastBinding}'`) : SyntaxError(`\\\n[vite] Named export '${lastBinding}' not found. The requested module '${rawId}' is a CommonJS module, which may not support all module.exports as named exports.\nCommonJS modules can always be imported via the default export, for example using:\n\nimport pkg from '${rawId}';\nconst {${missingBindings.join(\", \")}} = pkg;\n`);\n\t\t}\n\t}\n}\nlet nanoid = (size = 21) => {\n\tlet id = \"\", i = size | 0;\n\tfor (; i--;) id += \"useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict\"[Math.random() * 64 | 0];\n\treturn id;\n};\nfunction reviveInvokeError(e) {\n\tlet error = Error(e.message || \"Unknown invoke error\");\n\treturn Object.assign(error, e, { runnerError: /* @__PURE__ */ Error(\"RunnerError\") }), error;\n}\nconst createInvokeableTransport = (transport) => {\n\tif (transport.invoke) return {\n\t\t...transport,\n\t\tasync invoke(name, data) {\n\t\t\tlet result = await transport.invoke({\n\t\t\t\ttype: \"custom\",\n\t\t\t\tevent: \"vite:invoke\",\n\t\t\t\tdata: {\n\t\t\t\t\tid: \"send\",\n\t\t\t\t\tname,\n\t\t\t\t\tdata\n\t\t\t\t}\n\t\t\t});\n\t\t\tif (\"error\" in result) throw reviveInvokeError(result.error);\n\t\t\treturn result.result;\n\t\t}\n\t};\n\tif (!transport.send || !transport.connect) throw Error(\"transport must implement send and connect when invoke is not implemented\");\n\tlet rpcPromises = /* @__PURE__ */ new Map();\n\treturn {\n\t\t...transport,\n\t\tconnect({ onMessage, onDisconnection }) {\n\t\t\treturn transport.connect({\n\t\t\t\tonMessage(payload) {\n\t\t\t\t\tif (payload.type === \"custom\" && payload.event === \"vite:invoke\") {\n\t\t\t\t\t\tlet data = payload.data;\n\t\t\t\t\t\tif (data.id.startsWith(\"response:\")) {\n\t\t\t\t\t\t\tlet invokeId = data.id.slice(9), promise = rpcPromises.get(invokeId);\n\t\t\t\t\t\t\tif (!promise) return;\n\t\t\t\t\t\t\tpromise.timeoutId && clearTimeout(promise.timeoutId), rpcPromises.delete(invokeId);\n\t\t\t\t\t\t\tlet { error, result } = data.data;\n\t\t\t\t\t\t\terror ? promise.reject(error) : promise.resolve(result);\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tonMessage(payload);\n\t\t\t\t},\n\t\t\t\tonDisconnection\n\t\t\t});\n\t\t},\n\t\tdisconnect() {\n\t\t\treturn rpcPromises.forEach((promise) => {\n\t\t\t\tpromise.reject(/* @__PURE__ */ Error(`transport was disconnected, cannot call ${JSON.stringify(promise.name)}`));\n\t\t\t}), rpcPromises.clear(), transport.disconnect?.();\n\t\t},\n\t\tsend(data) {\n\t\t\treturn transport.send(data);\n\t\t},\n\t\tasync invoke(name, data) {\n\t\t\tlet promiseId = nanoid(), wrappedData = {\n\t\t\t\ttype: \"custom\",\n\t\t\t\tevent: \"vite:invoke\",\n\t\t\t\tdata: {\n\t\t\t\t\tname,\n\t\t\t\t\tid: `send:${promiseId}`,\n\t\t\t\t\tdata\n\t\t\t\t}\n\t\t\t}, sendPromise = transport.send(wrappedData), { promise, resolve: resolve$1, reject } = promiseWithResolvers(), timeout = transport.timeout ?? 6e4, timeoutId;\n\t\t\ttimeout > 0 && (timeoutId = setTimeout(() => {\n\t\t\t\trpcPromises.delete(promiseId), reject(/* @__PURE__ */ Error(`transport invoke timed out after ${timeout}ms (data: ${JSON.stringify(wrappedData)})`));\n\t\t\t}, timeout), timeoutId?.unref?.()), rpcPromises.set(promiseId, {\n\t\t\t\tresolve: resolve$1,\n\t\t\t\treject,\n\t\t\t\tname,\n\t\t\t\ttimeoutId\n\t\t\t}), sendPromise && sendPromise.catch((err) => {\n\t\t\t\tclearTimeout(timeoutId), rpcPromises.delete(promiseId), reject(err);\n\t\t\t});\n\t\t\ttry {\n\t\t\t\treturn await promise;\n\t\t\t} catch (err) {\n\t\t\t\tthrow reviveInvokeError(err);\n\t\t\t}\n\t\t}\n\t};\n}, normalizeModuleRunnerTransport = (transport) => {\n\tlet invokeableTransport = createInvokeableTransport(transport), isConnected = !invokeableTransport.connect, connectingPromise;\n\treturn {\n\t\t...transport,\n\t\t...invokeableTransport.connect ? { async connect(onMessage) {\n\t\t\tif (isConnected) return;\n\t\t\tif (connectingPromise) {\n\t\t\t\tawait connectingPromise;\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tlet maybePromise = invokeableTransport.connect({\n\t\t\t\tonMessage: onMessage ?? (() => {}),\n\t\t\t\tonDisconnection() {\n\t\t\t\t\tisConnected = !1;\n\t\t\t\t}\n\t\t\t});\n\t\t\tmaybePromise && (connectingPromise = maybePromise, await connectingPromise, connectingPromise = void 0), isConnected = !0;\n\t\t} } : {},\n\t\t...invokeableTransport.disconnect ? { async disconnect() {\n\t\t\tisConnected && (connectingPromise && await connectingPromise, isConnected = !1, await invokeableTransport.disconnect());\n\t\t} } : {},\n\t\tasync send(data) {\n\t\t\tif (invokeableTransport.send) {\n\t\t\t\tif (!isConnected) if (connectingPromise) await connectingPromise;\n\t\t\t\telse throw Error(\"send was called before connect\");\n\t\t\t\tawait invokeableTransport.send(data);\n\t\t\t}\n\t\t},\n\t\tasync invoke(name, data) {\n\t\t\tif (!isConnected) if (connectingPromise) await connectingPromise;\n\t\t\telse throw Error(\"invoke was called before connect\");\n\t\t\treturn invokeableTransport.invoke(name, data);\n\t\t}\n\t};\n}, createWebSocketModuleRunnerTransport = (options) => {\n\tlet pingInterval = options.pingInterval ?? 3e4, ws, pingIntervalId;\n\treturn {\n\t\tasync connect({ onMessage, onDisconnection }) {\n\t\t\tlet socket = options.createConnection();\n\t\t\tsocket.addEventListener(\"message\", async ({ data }) => {\n\t\t\t\tonMessage(JSON.parse(data));\n\t\t\t});\n\t\t\tlet isOpened = socket.readyState === socket.OPEN;\n\t\t\tisOpened || await new Promise((resolve$1, reject) => {\n\t\t\t\tsocket.addEventListener(\"open\", () => {\n\t\t\t\t\tisOpened = !0, resolve$1();\n\t\t\t\t}, { once: !0 }), socket.addEventListener(\"close\", async () => {\n\t\t\t\t\tif (!isOpened) {\n\t\t\t\t\t\treject(/* @__PURE__ */ Error(\"WebSocket closed without opened.\"));\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\tonMessage({\n\t\t\t\t\t\ttype: \"custom\",\n\t\t\t\t\t\tevent: \"vite:ws:disconnect\",\n\t\t\t\t\t\tdata: { webSocket: socket }\n\t\t\t\t\t}), onDisconnection();\n\t\t\t\t});\n\t\t\t}), onMessage({\n\t\t\t\ttype: \"custom\",\n\t\t\t\tevent: \"vite:ws:connect\",\n\t\t\t\tdata: { webSocket: socket }\n\t\t\t}), ws = socket, pingIntervalId = setInterval(() => {\n\t\t\t\tsocket.readyState === socket.OPEN && socket.send(JSON.stringify({ type: \"ping\" }));\n\t\t\t}, pingInterval);\n\t\t},\n\t\tdisconnect() {\n\t\t\tclearInterval(pingIntervalId), ws?.close();\n\t\t},\n\t\tsend(data) {\n\t\t\tws.send(JSON.stringify(data));\n\t\t}\n\t};\n};\nfunction createIsBuiltin(builtins) {\n\tlet plainBuiltinsSet = new Set(builtins.filter((builtin) => typeof builtin == \"string\")), regexBuiltins = builtins.filter((builtin) => typeof builtin != \"string\");\n\treturn (id) => plainBuiltinsSet.has(id) || regexBuiltins.some((regexp) => regexp.test(id));\n}\nconst ssrModuleExportsKey = \"__vite_ssr_exports__\", ssrImportKey = \"__vite_ssr_import__\", ssrDynamicImportKey = \"__vite_ssr_dynamic_import__\", ssrExportAllKey = \"__vite_ssr_exportAll__\", ssrExportNameKey = \"__vite_ssr_exportName__\", ssrImportMetaKey = \"__vite_ssr_import_meta__\", noop = () => {}, silentConsole = {\n\tdebug: noop,\n\terror: noop\n}, hmrLogger = {\n\tdebug: (...msg) => console.log(\"[vite]\", ...msg),\n\terror: (error) => console.log(\"[vite]\", error)\n};\nfunction createHMRHandler(handler) {\n\tlet queue = new Queue();\n\treturn (payload) => queue.enqueue(() => handler(payload));\n}\nvar Queue = class {\n\tqueue = [];\n\tpending = !1;\n\tenqueue(promise) {\n\t\treturn new Promise((resolve$1, reject) => {\n\t\t\tthis.queue.push({\n\t\t\t\tpromise,\n\t\t\t\tresolve: resolve$1,\n\t\t\t\treject\n\t\t\t}), this.dequeue();\n\t\t});\n\t}\n\tdequeue() {\n\t\tif (this.pending) return !1;\n\t\tlet item = this.queue.shift();\n\t\treturn item ? (this.pending = !0, item.promise().then(item.resolve).catch(item.reject).finally(() => {\n\t\t\tthis.pending = !1, this.dequeue();\n\t\t}), !0) : !1;\n\t}\n};\nfunction createHMRHandlerForRunner(runner) {\n\treturn createHMRHandler(async (payload) => {\n\t\tlet hmrClient = runner.hmrClient;\n\t\tif (!(!hmrClient || runner.isClosed())) switch (payload.type) {\n\t\t\tcase \"connected\":\n\t\t\t\thmrClient.logger.debug(\"connected.\");\n\t\t\t\tbreak;\n\t\t\tcase \"update\":\n\t\t\t\tawait hmrClient.notifyListeners(\"vite:beforeUpdate\", payload), await Promise.all(payload.updates.map(async (update) => {\n\t\t\t\t\tif (update.type === \"js-update\") return update.acceptedPath = unwrapId(update.acceptedPath), update.path = unwrapId(update.path), hmrClient.queueUpdate(update);\n\t\t\t\t\thmrClient.logger.error(\"css hmr is not supported in runner mode.\");\n\t\t\t\t})), await hmrClient.notifyListeners(\"vite:afterUpdate\", payload);\n\t\t\t\tbreak;\n\t\t\tcase \"custom\":\n\t\t\t\tawait hmrClient.notifyListeners(payload.event, payload.data);\n\t\t\t\tbreak;\n\t\t\tcase \"full-reload\": {\n\t\t\t\tlet { triggeredBy } = payload, clearEntrypointUrls = triggeredBy ? getModulesEntrypoints(runner, getModulesByFile(runner, slash(triggeredBy))) : findAllEntrypoints(runner);\n\t\t\t\tif (!clearEntrypointUrls.size) break;\n\t\t\t\thmrClient.logger.debug(\"program reload\"), await hmrClient.notifyListeners(\"vite:beforeFullReload\", payload), runner.evaluatedModules.clear();\n\t\t\t\tfor (let url of clearEntrypointUrls) try {\n\t\t\t\t\tawait runner.import(url);\n\t\t\t\t} catch (err) {\n\t\t\t\t\terr.code !== \"ERR_OUTDATED_OPTIMIZED_DEP\" && hmrClient.logger.error(`An error happened during full reload\\n${err.message}\\n${err.stack}`);\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tcase \"prune\":\n\t\t\t\tawait hmrClient.notifyListeners(\"vite:beforePrune\", payload), await hmrClient.prunePaths(payload.paths);\n\t\t\t\tbreak;\n\t\t\tcase \"error\": {\n\t\t\t\tawait hmrClient.notifyListeners(\"vite:error\", payload);\n\t\t\t\tlet err = payload.err;\n\t\t\t\thmrClient.logger.error(`Internal Server Error\\n${err.message}\\n${err.stack}`);\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tcase \"ping\": break;\n\t\t\tdefault: return payload;\n\t\t}\n\t});\n}\nfunction getModulesByFile(runner, file) {\n\tlet nodes = runner.evaluatedModules.getModulesByFile(file);\n\treturn nodes ? [...nodes].map((node) => node.id) : [];\n}\nfunction getModulesEntrypoints(runner, modules, visited = /* @__PURE__ */ new Set(), entrypoints = /* @__PURE__ */ new Set()) {\n\tfor (let moduleId of modules) {\n\t\tif (visited.has(moduleId)) continue;\n\t\tvisited.add(moduleId);\n\t\tlet module = runner.evaluatedModules.getModuleById(moduleId);\n\t\tif (module) {\n\t\t\tif (!module.importers.size) {\n\t\t\t\tentrypoints.add(module.url);\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tfor (let importer of module.importers) getModulesEntrypoints(runner, [importer], visited, entrypoints);\n\t\t}\n\t}\n\treturn entrypoints;\n}\nfunction findAllEntrypoints(runner, entrypoints = /* @__PURE__ */ new Set()) {\n\tfor (let mod of runner.evaluatedModules.idToModuleMap.values()) mod.importers.size || entrypoints.add(mod.url);\n\treturn entrypoints;\n}\nconst sourceMapCache = {}, fileContentsCache = {}, evaluatedModulesCache = /* @__PURE__ */ new Set(), retrieveFileHandlers = /* @__PURE__ */ new Set(), retrieveSourceMapHandlers = /* @__PURE__ */ new Set(), createExecHandlers = (handlers) => ((...args) => {\n\tfor (let handler of handlers) {\n\t\tlet result = handler(...args);\n\t\tif (result) return result;\n\t}\n\treturn null;\n}), retrieveFileFromHandlers = createExecHandlers(retrieveFileHandlers), retrieveSourceMapFromHandlers = createExecHandlers(retrieveSourceMapHandlers);\nlet overridden = !1;\nconst originalPrepare = Error.prepareStackTrace;\nfunction resetInterceptor(runner, options) {\n\tevaluatedModulesCache.delete(runner.evaluatedModules), options.retrieveFile && retrieveFileHandlers.delete(options.retrieveFile), options.retrieveSourceMap && retrieveSourceMapHandlers.delete(options.retrieveSourceMap), evaluatedModulesCache.size === 0 && (Error.prepareStackTrace = originalPrepare, overridden = !1);\n}\nfunction interceptStackTrace(runner, options = {}) {\n\treturn overridden ||= (Error.prepareStackTrace = prepareStackTrace, !0), evaluatedModulesCache.add(runner.evaluatedModules), options.retrieveFile && retrieveFileHandlers.add(options.retrieveFile), options.retrieveSourceMap && retrieveSourceMapHandlers.add(options.retrieveSourceMap), () => resetInterceptor(runner, options);\n}\nfunction supportRelativeURL(file, url) {\n\tif (!file) return url;\n\tlet dir = posixDirname(slash(file)), match = /^\\w+:\\/\\/[^/]*/.exec(dir), protocol = match ? match[0] : \"\", startPath = dir.slice(protocol.length);\n\treturn protocol && /^\\/\\w:/.test(startPath) ? (protocol += \"/\", protocol + slash(posixResolve(startPath, url))) : protocol + posixResolve(startPath, url);\n}\nfunction getRunnerSourceMap(position) {\n\tfor (let moduleGraph of evaluatedModulesCache) {\n\t\tlet sourceMap = moduleGraph.getModuleSourceMapById(position.source);\n\t\tif (sourceMap) return {\n\t\t\turl: position.source,\n\t\t\tmap: sourceMap,\n\t\t\tvite: !0\n\t\t};\n\t}\n\treturn null;\n}\nfunction retrieveFile(path) {\n\tif (path in fileContentsCache) return fileContentsCache[path];\n\tlet content = retrieveFileFromHandlers(path);\n\treturn typeof content == \"string\" ? (fileContentsCache[path] = content, content) : null;\n}\nfunction retrieveSourceMapURL(source) {\n\tlet fileData = retrieveFile(source);\n\tif (!fileData) return null;\n\tlet re = /\\/\\/[@#]\\s*sourceMappingURL=([^\\s'\"]+)\\s*$|\\/\\*[@#]\\s*sourceMappingURL=[^\\s*'\"]+\\s*\\*\\/\\s*$/gm, lastMatch, match;\n\tfor (; match = re.exec(fileData);) lastMatch = match;\n\treturn lastMatch ? lastMatch[1] : null;\n}\nconst reSourceMap = /^data:application\\/json[^,]+base64,/;\nfunction retrieveSourceMap(source) {\n\tlet urlAndMap = retrieveSourceMapFromHandlers(source);\n\tif (urlAndMap) return urlAndMap;\n\tlet sourceMappingURL = retrieveSourceMapURL(source);\n\tif (!sourceMappingURL) return null;\n\tlet sourceMapData;\n\tif (reSourceMap.test(sourceMappingURL)) {\n\t\tlet rawData = sourceMappingURL.slice(sourceMappingURL.indexOf(\",\") + 1);\n\t\tsourceMapData = Buffer.from(rawData, \"base64\").toString(), sourceMappingURL = source;\n\t} else sourceMappingURL = supportRelativeURL(source, sourceMappingURL), sourceMapData = retrieveFile(sourceMappingURL);\n\treturn sourceMapData ? {\n\t\turl: sourceMappingURL,\n\t\tmap: sourceMapData\n\t} : null;\n}\nfunction mapSourcePosition(position) {\n\tif (!position.source) return position;\n\tlet sourceMap = getRunnerSourceMap(position);\n\tif (sourceMap ||= sourceMapCache[position.source], !sourceMap) {\n\t\tlet urlAndMap = retrieveSourceMap(position.source);\n\t\tif (urlAndMap && urlAndMap.map) {\n\t\t\tlet url = urlAndMap.url;\n\t\t\tsourceMap = sourceMapCache[position.source] = {\n\t\t\t\turl,\n\t\t\t\tmap: new DecodedMap(typeof urlAndMap.map == \"string\" ? JSON.parse(urlAndMap.map) : urlAndMap.map, url)\n\t\t\t};\n\t\t\tlet contents = sourceMap.map?.map.sourcesContent;\n\t\t\tsourceMap.map && contents && sourceMap.map.resolvedSources.forEach((source, i) => {\n\t\t\t\tlet content = contents[i];\n\t\t\t\tif (content && source && url) {\n\t\t\t\t\tlet contentUrl = supportRelativeURL(url, source);\n\t\t\t\t\tfileContentsCache[contentUrl] = content;\n\t\t\t\t}\n\t\t\t});\n\t\t} else sourceMap = sourceMapCache[position.source] = {\n\t\t\turl: null,\n\t\t\tmap: null\n\t\t};\n\t}\n\tif (sourceMap.map && sourceMap.url) {\n\t\tlet originalPosition = getOriginalPosition(sourceMap.map, position);\n\t\tif (originalPosition && originalPosition.source != null) return originalPosition.source = supportRelativeURL(sourceMap.url, originalPosition.source), sourceMap.vite && (originalPosition._vite = !0), originalPosition;\n\t}\n\treturn position;\n}\nfunction mapEvalOrigin(origin) {\n\tlet match = /^eval at ([^(]+) \\((.+):(\\d+):(\\d+)\\)$/.exec(origin);\n\tif (match) {\n\t\tlet position = mapSourcePosition({\n\t\t\tname: null,\n\t\t\tsource: match[2],\n\t\t\tline: +match[3],\n\t\t\tcolumn: match[4] - 1\n\t\t});\n\t\treturn `eval at ${match[1]} (${position.source}:${position.line}:${position.column + 1})`;\n\t}\n\treturn match = /^eval at ([^(]+) \\((.+)\\)$/.exec(origin), match ? `eval at ${match[1]} (${mapEvalOrigin(match[2])})` : origin;\n}\nfunction CallSiteToString() {\n\tlet fileName, fileLocation = \"\";\n\tif (this.isNative()) fileLocation = \"native\";\n\telse {\n\t\tfileName = this.getScriptNameOrSourceURL(), !fileName && this.isEval() && (fileLocation = this.getEvalOrigin(), fileLocation += \", \"), fileName ? fileLocation += fileName : fileLocation += \"<anonymous>\";\n\t\tlet lineNumber = this.getLineNumber();\n\t\tif (lineNumber != null) {\n\t\t\tfileLocation += `:${lineNumber}`;\n\t\t\tlet columnNumber = this.getColumnNumber();\n\t\t\tcolumnNumber && (fileLocation += `:${columnNumber}`);\n\t\t}\n\t}\n\tlet line = \"\", functionName = this.getFunctionName(), addSuffix = !0, isConstructor = this.isConstructor();\n\tif (this.isToplevel() || isConstructor) isConstructor ? line += `new ${functionName || \"<anonymous>\"}` : functionName ? line += functionName : (line += fileLocation, addSuffix = !1);\n\telse {\n\t\tlet typeName = this.getTypeName();\n\t\ttypeName === \"[object Object]\" && (typeName = \"null\");\n\t\tlet methodName = this.getMethodName();\n\t\tfunctionName ? (typeName && functionName.indexOf(typeName) !== 0 && (line += `${typeName}.`), line += functionName, methodName && functionName.indexOf(`.${methodName}`) !== functionName.length - methodName.length - 1 && (line += ` [as ${methodName}]`)) : line += `${typeName}.${methodName || \"<anonymous>\"}`;\n\t}\n\treturn addSuffix && (line += ` (${fileLocation})`), line;\n}\nfunction cloneCallSite(frame) {\n\tlet object = {};\n\treturn Object.getOwnPropertyNames(Object.getPrototypeOf(frame)).forEach((name) => {\n\t\tlet key = name;\n\t\tobject[key] = /^(?:is|get)/.test(name) ? function() {\n\t\t\treturn frame[key].call(frame);\n\t\t} : frame[key];\n\t}), object.toString = CallSiteToString, object;\n}\nfunction wrapCallSite(frame, state) {\n\tif (state === void 0 && (state = {\n\t\tnextPosition: null,\n\t\tcurPosition: null\n\t}), frame.isNative()) return state.curPosition = null, frame;\n\tlet source = frame.getFileName() || frame.getScriptNameOrSourceURL();\n\tif (source) {\n\t\tlet line = frame.getLineNumber(), column = frame.getColumnNumber() - 1;\n\t\tline === 1 && column > 62 && !frame.isEval() && (column -= 62);\n\t\tlet position = mapSourcePosition({\n\t\t\tname: null,\n\t\t\tsource,\n\t\t\tline,\n\t\t\tcolumn\n\t\t});\n\t\tstate.curPosition = position, frame = cloneCallSite(frame);\n\t\tlet originalFunctionName = frame.getFunctionName;\n\t\treturn frame.getFunctionName = function() {\n\t\t\tlet name = (() => state.nextPosition == null ? originalFunctionName() : state.nextPosition.name || originalFunctionName())();\n\t\t\treturn name === \"eval\" && \"_vite\" in position ? null : name;\n\t\t}, frame.getFileName = function() {\n\t\t\treturn position.source ?? null;\n\t\t}, frame.getLineNumber = function() {\n\t\t\treturn position.line;\n\t\t}, frame.getColumnNumber = function() {\n\t\t\treturn position.column + 1;\n\t\t}, frame.getScriptNameOrSourceURL = function() {\n\t\t\treturn position.source;\n\t\t}, frame;\n\t}\n\tlet origin = frame.isEval() && frame.getEvalOrigin();\n\treturn origin ? (origin = mapEvalOrigin(origin), frame = cloneCallSite(frame), frame.getEvalOrigin = function() {\n\t\treturn origin || void 0;\n\t}, frame) : frame;\n}\nfunction prepareStackTrace(error, stack) {\n\tlet errorString = `${error.name || \"Error\"}: ${error.message || \"\"}`, state = {\n\t\tnextPosition: null,\n\t\tcurPosition: null\n\t}, processedStack = [];\n\tfor (let i = stack.length - 1; i >= 0; i--) processedStack.push(`\\n at ${wrapCallSite(stack[i], state)}`), state.nextPosition = state.curPosition;\n\treturn state.curPosition = state.nextPosition = null, errorString + processedStack.reverse().join(\"\");\n}\nfunction enableSourceMapSupport(runner) {\n\tif (runner.options.sourcemapInterceptor === \"node\") {\n\t\tif (typeof process > \"u\") throw TypeError(\"Cannot use \\\"sourcemapInterceptor: 'node'\\\" because global \\\"process\\\" variable is not available.\");\n\t\tif (typeof process.setSourceMapsEnabled != \"function\") throw TypeError(\"Cannot use \\\"sourcemapInterceptor: 'node'\\\" because \\\"process.setSourceMapsEnabled\\\" function is not available. Please use Node >= 16.6.0.\");\n\t\tlet isEnabledAlready = process.sourceMapsEnabled ?? !1;\n\t\treturn process.setSourceMapsEnabled(!0), () => !isEnabledAlready && process.setSourceMapsEnabled(!1);\n\t}\n\treturn interceptStackTrace(runner, typeof runner.options.sourcemapInterceptor == \"object\" ? runner.options.sourcemapInterceptor : void 0);\n}\nvar ESModulesEvaluator = class {\n\tstartOffset = getAsyncFunctionDeclarationPaddingLineCount();\n\tasync runInlinedModule(context, code) {\n\t\tawait new AsyncFunction(ssrModuleExportsKey, ssrImportMetaKey, ssrImportKey, ssrDynamicImportKey, ssrExportAllKey, ssrExportNameKey, \"\\\"use strict\\\";\" + code)(context[ssrModuleExportsKey], context[ssrImportMetaKey], context[ssrImportKey], context[ssrDynamicImportKey], context[ssrExportAllKey], context[ssrExportNameKey]), Object.seal(context[ssrModuleExportsKey]);\n\t}\n\trunExternalModule(filepath) {\n\t\treturn import(filepath);\n\t}\n};\nconst customizationHookNamespace = \"vite-module-runner:import-meta-resolve/v1/\", customizationHooksModule = `\n\nexport async function resolve(specifier, context, nextResolve) {\n if (specifier.startsWith(${JSON.stringify(customizationHookNamespace)})) {\n const data = specifier.slice(${JSON.stringify(customizationHookNamespace)}.length)\n const [parsedSpecifier, parsedImporter] = JSON.parse(data)\n specifier = parsedSpecifier\n context.parentURL = parsedImporter\n }\n return nextResolve(specifier, context)\n}\n\n`;\nfunction customizationHookResolve(specifier, context, nextResolve) {\n\tif (specifier.startsWith(customizationHookNamespace)) {\n\t\tlet data = specifier.slice(42), [parsedSpecifier, parsedImporter] = JSON.parse(data);\n\t\tspecifier = parsedSpecifier, context.parentURL = parsedImporter;\n\t}\n\treturn nextResolve(specifier, context);\n}\nasync function createImportMetaResolver() {\n\tlet module;\n\ttry {\n\t\tmodule = (await import(\"node:module\")).Module;\n\t} catch {\n\t\treturn;\n\t}\n\tif (module) {\n\t\tif (module.registerHooks) return module.registerHooks({ resolve: customizationHookResolve }), importMetaResolveWithCustomHook;\n\t\tif (module.register) {\n\t\t\ttry {\n\t\t\t\tlet hookModuleContent = `data:text/javascript,${encodeURI(customizationHooksModule)}`;\n\t\t\t\tmodule.register(hookModuleContent);\n\t\t\t} catch (e) {\n\t\t\t\tif (\"code\" in e && e.code === \"ERR_NETWORK_IMPORT_DISALLOWED\") return;\n\t\t\t\tthrow e;\n\t\t\t}\n\t\t\treturn importMetaResolveWithCustomHook;\n\t\t}\n\t}\n}\nfunction importMetaResolveWithCustomHook(specifier, importer) {\n\treturn import.meta.resolve(`${customizationHookNamespace}${JSON.stringify([specifier, importer])}`);\n}\n`${customizationHookNamespace}`;\nconst envProxy = new Proxy({}, { get(_, p) {\n\tthrow Error(`[module runner] Dynamic access of \"import.meta.env\" is not supported. Please, use \"import.meta.env.${String(p)}\" instead.`);\n} });\nfunction createDefaultImportMeta(modulePath) {\n\tlet href = posixPathToFileHref(modulePath), filename = modulePath, dirname$1 = posixDirname(modulePath);\n\treturn {\n\t\tfilename: isWindows ? toWindowsPath(filename) : filename,\n\t\tdirname: isWindows ? toWindowsPath(dirname$1) : dirname$1,\n\t\turl: href,\n\t\tenv: envProxy,\n\t\tresolve(_id, _parent) {\n\t\t\tthrow Error(\"[module runner] \\\"import.meta.resolve\\\" is not supported.\");\n\t\t},\n\t\tglob() {\n\t\t\tthrow Error(\"[module runner] \\\"import.meta.glob\\\" is statically replaced during file transformation. Make sure to reference it by the full name.\");\n\t\t}\n\t};\n}\nlet importMetaResolverCache;\nasync function createNodeImportMeta(modulePath) {\n\tlet defaultMeta = createDefaultImportMeta(modulePath), href = defaultMeta.url;\n\timportMetaResolverCache ??= createImportMetaResolver();\n\tlet importMetaResolver = await importMetaResolverCache;\n\treturn {\n\t\t...defaultMeta,\n\t\tmain: !1,\n\t\tresolve(id, parent) {\n\t\t\treturn (importMetaResolver ?? defaultMeta.resolve)(id, parent ?? href);\n\t\t}\n\t};\n}\nvar ModuleRunner = class {\n\tevaluatedModules;\n\thmrClient;\n\ttransport;\n\tresetSourceMapSupport;\n\tconcurrentModuleNodePromises = /* @__PURE__ */ new Map();\n\tisBuiltin;\n\tbuiltinsPromise;\n\tclosed = !1;\n\tconstructor(options, evaluator = new ESModulesEvaluator(), debug) {\n\t\tif (this.options = options, this.evaluator = evaluator, this.debug = debug, this.evaluatedModules = options.evaluatedModules ?? new EvaluatedModules(), this.transport = normalizeModuleRunnerTransport(options.transport), options.hmr !== !1) {\n\t\t\tlet optionsHmr = options.hmr ?? !0;\n\t\t\tif (this.hmrClient = new HMRClient(optionsHmr === !0 || optionsHmr.logger === void 0 ? hmrLogger : optionsHmr.logger === !1 ? silentConsole : optionsHmr.logger, this.transport, ({ acceptedPath }) => this.import(acceptedPath)), !this.transport.connect) throw Error(\"HMR is not supported by this runner transport, but `hmr` option was set to true\");\n\t\t\tthis.transport.connect(createHMRHandlerForRunner(this));\n\t\t} else this.transport.connect?.();\n\t\toptions.sourcemapInterceptor !== !1 && (this.resetSourceMapSupport = enableSourceMapSupport(this));\n\t}\n\tasync import(url) {\n\t\tlet fetchedModule = await this.cachedModule(url);\n\t\treturn await this.cachedRequest(url, fetchedModule);\n\t}\n\tclearCache() {\n\t\tthis.evaluatedModules.clear(), this.hmrClient?.clear();\n\t}\n\tasync close() {\n\t\tthis.resetSourceMapSupport?.(), this.clearCache(), this.hmrClient = void 0, this.closed = !0, await this.transport.disconnect?.();\n\t}\n\tisClosed() {\n\t\treturn this.closed;\n\t}\n\tprocessImport(exports, fetchResult, metadata) {\n\t\tif (!(\"externalize\" in fetchResult)) return exports;\n\t\tlet { url, type } = fetchResult;\n\t\treturn type !== \"module\" && type !== \"commonjs\" || analyzeImportedModDifference(exports, url, type, metadata), exports;\n\t}\n\tisCircularModule(mod) {\n\t\tfor (let importedFile of mod.imports) if (mod.importers.has(importedFile)) return !0;\n\t\treturn !1;\n\t}\n\tisCircularImport(importers, moduleUrl, visited = /* @__PURE__ */ new Set()) {\n\t\tfor (let importer of importers) {\n\t\t\tif (visited.has(importer)) continue;\n\t\t\tif (visited.add(importer), importer === moduleUrl) return !0;\n\t\t\tlet mod = this.evaluatedModules.getModuleById(importer);\n\t\t\tif (mod && mod.importers.size && this.isCircularImport(mod.importers, moduleUrl, visited)) return !0;\n\t\t}\n\t\treturn !1;\n\t}\n\tasync cachedRequest(url, mod, callstack = [], metadata) {\n\t\tlet meta = mod.meta, moduleId = meta.id, { importers } = mod, importee = callstack[callstack.length - 1];\n\t\tif (importee && importers.add(importee), (callstack.includes(moduleId) || this.isCircularModule(mod) || this.isCircularImport(importers, moduleId)) && mod.exports) return this.processImport(mod.exports, meta, metadata);\n\t\tlet debugTimer;\n\t\tthis.debug && (debugTimer = setTimeout(() => {\n\t\t\tthis.debug(`[module runner] module ${moduleId} takes over 2s to load.\\n${(() => `stack:\\n${[...callstack, moduleId].reverse().map((p) => ` - ${p}`).join(\"\\n\")}`)()}`);\n\t\t}, 2e3));\n\t\ttry {\n\t\t\tif (mod.promise) return this.processImport(await mod.promise, meta, metadata);\n\t\t\tlet promise = this.directRequest(url, mod, callstack);\n\t\t\treturn mod.promise = promise, mod.evaluated = !1, this.processImport(await promise, meta, metadata);\n\t\t} finally {\n\t\t\tmod.evaluated = !0, debugTimer && clearTimeout(debugTimer);\n\t\t}\n\t}\n\tasync cachedModule(url, importer) {\n\t\tlet cached = this.concurrentModuleNodePromises.get(url);\n\t\tif (cached) this.debug?.(\"[module runner] using cached module info for\", url);\n\t\telse {\n\t\t\tlet cachedModule = this.evaluatedModules.getModuleByUrl(url);\n\t\t\tcached = this.getModuleInformation(url, importer, cachedModule).finally(() => {\n\t\t\t\tthis.concurrentModuleNodePromises.delete(url);\n\t\t\t}), this.concurrentModuleNodePromises.set(url, cached);\n\t\t}\n\t\treturn cached;\n\t}\n\tensureBuiltins() {\n\t\tif (!this.isBuiltin) return this.builtinsPromise ??= (async () => {\n\t\t\ttry {\n\t\t\t\tthis.debug?.(\"[module runner] fetching builtins from server\");\n\t\t\t\tlet builtins = (await this.transport.invoke(\"getBuiltins\", [])).map((builtin) => typeof builtin == \"object\" && builtin && \"type\" in builtin ? builtin.type === \"string\" ? builtin.value : new RegExp(builtin.source, builtin.flags) : builtin);\n\t\t\t\tthis.isBuiltin = createIsBuiltin(builtins), this.debug?.(\"[module runner] builtins loaded:\", builtins);\n\t\t\t} finally {\n\t\t\t\tthis.builtinsPromise = void 0;\n\t\t\t}\n\t\t})(), this.builtinsPromise;\n\t}\n\tasync getModuleInformation(url, importer, cachedModule) {\n\t\tif (this.closed) throw Error(\"Vite module runner has been closed.\");\n\t\tawait this.ensureBuiltins(), this.debug?.(\"[module runner] fetching\", url);\n\t\tlet isCached = !!(typeof cachedModule == \"object\" && cachedModule.meta), fetchedModule = url.startsWith(\"data:\") || this.isBuiltin?.(url) ? {\n\t\t\texternalize: url,\n\t\t\ttype: \"builtin\"\n\t\t} : await this.transport.invoke(\"fetchModule\", [\n\t\t\turl,\n\t\t\timporter,\n\t\t\t{\n\t\t\t\tcached: isCached,\n\t\t\t\tstartOffset: this.evaluator.startOffset\n\t\t\t}\n\t\t]);\n\t\tif (\"cache\" in fetchedModule) {\n\t\t\tif (!cachedModule || !cachedModule.meta) throw Error(`Module \"${url}\" was mistakenly invalidated during fetch phase.`);\n\t\t\treturn cachedModule;\n\t\t}\n\t\tlet moduleId = \"externalize\" in fetchedModule ? fetchedModule.externalize : fetchedModule.id, moduleUrl = \"url\" in fetchedModule ? fetchedModule.url : url, module = this.evaluatedModules.ensureModule(moduleId, moduleUrl);\n\t\treturn \"invalidate\" in fetchedModule && fetchedModule.invalidate && this.evaluatedModules.invalidateModule(module), fetchedModule.url = moduleUrl, fetchedModule.id = moduleId, module.meta = fetchedModule, module;\n\t}\n\tasync directRequest(url, mod, _callstack) {\n\t\tlet fetchResult = mod.meta, moduleId = fetchResult.id, callstack = [..._callstack, moduleId], request = async (dep, metadata) => {\n\t\t\tlet importer = \"file\" in fetchResult && fetchResult.file || moduleId, depMod = await this.cachedModule(dep, importer);\n\t\t\treturn depMod.importers.add(moduleId), mod.imports.add(depMod.id), this.cachedRequest(dep, depMod, callstack, metadata);\n\t\t}, dynamicRequest = async (dep) => (dep = String(dep), dep[0] === \".\" && (dep = posixResolve(posixDirname(url), dep)), request(dep, { isDynamicImport: !0 }));\n\t\tif (\"externalize\" in fetchResult) {\n\t\t\tlet { externalize } = fetchResult;\n\t\t\tthis.debug?.(\"[module runner] externalizing\", externalize);\n\t\t\tlet exports$1 = await this.evaluator.runExternalModule(externalize);\n\t\t\treturn mod.exports = exports$1, exports$1;\n\t\t}\n\t\tlet { code, file } = fetchResult;\n\t\tif (code == null) {\n\t\t\tlet importer = callstack[callstack.length - 2];\n\t\t\tthrow Error(`[module runner] Failed to load \"${url}\"${importer ? ` imported from ${importer}` : \"\"}`);\n\t\t}\n\t\tlet createImportMeta = this.options.createImportMeta ?? createDefaultImportMeta, modulePath = cleanUrl(file || moduleId), href = posixPathToFileHref(modulePath), meta = await createImportMeta(modulePath), exports = Object.create(null);\n\t\tObject.defineProperty(exports, Symbol.toStringTag, {\n\t\t\tvalue: \"Module\",\n\t\t\tenumerable: !1,\n\t\t\tconfigurable: !1\n\t\t}), mod.exports = exports;\n\t\tlet hotContext;\n\t\tthis.hmrClient && Object.defineProperty(meta, \"hot\", {\n\t\t\tenumerable: !0,\n\t\t\tget: () => {\n\t\t\t\tif (!this.hmrClient) throw Error(\"[module runner] HMR client was closed.\");\n\t\t\t\treturn this.debug?.(\"[module runner] creating hmr context for\", mod.url), hotContext ||= new HMRContext(this.hmrClient, mod.url), hotContext;\n\t\t\t},\n\t\t\tset: (value) => {\n\t\t\t\thotContext = value;\n\t\t\t}\n\t\t});\n\t\tlet context = {\n\t\t\t[ssrImportKey]: request,\n\t\t\t[ssrDynamicImportKey]: dynamicRequest,\n\t\t\t[ssrModuleExportsKey]: exports,\n\t\t\t[ssrExportAllKey]: (obj) => exportAll(exports, obj),\n\t\t\t[ssrExportNameKey]: (name, getter) => Object.defineProperty(exports, name, {\n\t\t\t\tenumerable: !0,\n\t\t\t\tconfigurable: !0,\n\t\t\t\tget: getter\n\t\t\t}),\n\t\t\t[ssrImportMetaKey]: meta\n\t\t};\n\t\treturn this.debug?.(\"[module runner] executing\", href), await this.evaluator.runInlinedModule(context, code, mod), exports;\n\t}\n};\nfunction exportAll(exports, sourceModule) {\n\tif (exports !== sourceModule && !(isPrimitive(sourceModule) || Array.isArray(sourceModule) || sourceModule instanceof Promise)) {\n\t\tfor (let key in sourceModule) if (key !== \"default\" && key !== \"__esModule\" && !(key in exports)) try {\n\t\t\tObject.defineProperty(exports, key, {\n\t\t\t\tenumerable: !0,\n\t\t\t\tconfigurable: !0,\n\t\t\t\tget: () => sourceModule[key]\n\t\t\t});\n\t\t} catch {}\n\t}\n}\nexport { ESModulesEvaluator, EvaluatedModules, ModuleRunner, createDefaultImportMeta, createNodeImportMeta, createWebSocketModuleRunnerTransport, normalizeModuleId, ssrDynamicImportKey, ssrExportAllKey, ssrExportNameKey, ssrImportKey, ssrImportMetaKey, ssrModuleExportsKey };\n","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\n","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\n/**\n * @internal\n */\nconst inverted = Symbol('inverted');\n/**\n * @internal\n */\nconst expectNull = Symbol('expectNull');\n/**\n * @internal\n */\nconst expectUndefined = Symbol('expectUndefined');\n/**\n * @internal\n */\nconst expectNumber = Symbol('expectNumber');\n/**\n * @internal\n */\nconst expectString = Symbol('expectString');\n/**\n * @internal\n */\nconst expectBoolean = Symbol('expectBoolean');\n/**\n * @internal\n */\nconst expectVoid = Symbol('expectVoid');\n/**\n * @internal\n */\nconst expectFunction = Symbol('expectFunction');\n/**\n * @internal\n */\nconst expectObject = Symbol('expectObject');\n/**\n * @internal\n */\nconst expectArray = Symbol('expectArray');\n/**\n * @internal\n */\nconst expectSymbol = Symbol('expectSymbol');\n/**\n * @internal\n */\nconst expectAny = Symbol('expectAny');\n/**\n * @internal\n */\nconst expectUnknown = Symbol('expectUnknown');\n/**\n * @internal\n */\nconst expectNever = Symbol('expectNever');\n/**\n * @internal\n */\nconst expectNullable = Symbol('expectNullable');\n/**\n * @internal\n */\nconst expectBigInt = Symbol('expectBigInt');\n","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\n","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\n/**\n * @internal\n */\nconst secret = Symbol('secret');\n/**\n * @internal\n */\nconst mismatch = Symbol('mismatch');\n/**\n * A type which should match anything passed as a value but *doesn't*\n * match {@linkcode Mismatch}. It helps TypeScript select the right overload\n * for {@linkcode PositiveExpectTypeOf.toEqualTypeOf | .toEqualTypeOf()} and\n * {@linkcode PositiveExpectTypeOf.toMatchTypeOf | .toMatchTypeOf()}.\n *\n * @internal\n */\nconst avalue = Symbol('avalue');\n","\"use strict\";\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n var desc = Object.getOwnPropertyDescriptor(m, k);\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\n desc = { enumerable: true, get: function() { return m[k]; } };\n }\n Object.defineProperty(o, k2, desc);\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n}));\nvar __exportStar = (this && this.__exportStar) || function(m, exports) {\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.expectTypeOf = void 0;\n__exportStar(require(\"./branding\"), exports); // backcompat, consider removing in next major version\n__exportStar(require(\"./messages\"), exports); // backcompat, consider removing in next major version\n__exportStar(require(\"./overloads\"), exports);\n__exportStar(require(\"./utils\"), exports); // backcompat, consider removing in next major version\nconst fn = () => true;\n/**\n * Similar to Jest's `expect`, but with type-awareness.\n * Gives you access to a number of type-matchers that let you make assertions about the\n * form of a reference or generic type parameter.\n *\n * @example\n * ```ts\n * import { foo, bar } from '../foo'\n * import { expectTypeOf } from 'expect-type'\n *\n * test('foo types', () => {\n * // make sure `foo` has type { a: number }\n * expectTypeOf(foo).toMatchTypeOf({ a: 1 })\n * expectTypeOf(foo).toHaveProperty('a').toBeNumber()\n *\n * // make sure `bar` is a function taking a string:\n * expectTypeOf(bar).parameter(0).toBeString()\n * expectTypeOf(bar).returns.not.toBeAny()\n * })\n * ```\n *\n * @description\n * See the [full docs](https://npmjs.com/package/expect-type#documentation) for lots more examples.\n */\nconst expectTypeOf = (_actual) => {\n const nonFunctionProperties = [\n 'parameters',\n 'returns',\n 'resolves',\n 'not',\n 'items',\n 'constructorParameters',\n 'thisParameter',\n 'instance',\n 'guards',\n 'asserts',\n 'branded',\n ];\n const obj = {\n /* eslint-disable @typescript-eslint/no-unsafe-assignment */\n toBeAny: fn,\n toBeUnknown: fn,\n toBeNever: fn,\n toBeFunction: fn,\n toBeObject: fn,\n toBeArray: fn,\n toBeString: fn,\n toBeNumber: fn,\n toBeBoolean: fn,\n toBeVoid: fn,\n toBeSymbol: fn,\n toBeNull: fn,\n toBeUndefined: fn,\n toBeNullable: fn,\n toBeBigInt: fn,\n toMatchTypeOf: fn,\n toEqualTypeOf: fn,\n toBeConstructibleWith: fn,\n toMatchObjectType: fn,\n toExtend: fn,\n map: exports.expectTypeOf,\n toBeCallableWith: exports.expectTypeOf,\n extract: exports.expectTypeOf,\n exclude: exports.expectTypeOf,\n pick: exports.expectTypeOf,\n omit: exports.expectTypeOf,\n toHaveProperty: exports.expectTypeOf,\n parameter: exports.expectTypeOf,\n };\n const getterProperties = nonFunctionProperties;\n getterProperties.forEach((prop) => Object.defineProperty(obj, prop, { get: () => (0, exports.expectTypeOf)({}) }));\n return obj;\n};\nexports.expectTypeOf = expectTypeOf;\n","export { N as BenchmarkRunner, S as Snapshots, T as TestRunner, a as assert, c as createExpect, g as expect, i as inject, s as should, v as vi, b as vitest } from './chunks/test.DNmyFkvJ.js';\nexport { b as bench } from './chunks/benchmark.CX_oY03V.js';\nexport { V as EvaluatedModules } from './chunks/evaluatedModules.Dg1zASAC.js';\nexport { a as assertType } from './chunks/index.DdgEv5B1.js';\nexport { expectTypeOf } from 'expect-type';\nexport { afterAll, afterEach, aroundAll, aroundEach, beforeAll, beforeEach, describe, it, onTestFailed, onTestFinished, recordArtifact, suite, test } from '@vitest/runner';\nexport { chai } from '@vitest/expect';\nimport '@vitest/utils/helpers';\nimport '@vitest/utils/timers';\nimport './chunks/utils.BX5Fg8C4.js';\nimport '@vitest/runner/utils';\nimport '@vitest/utils/error';\nimport 'pathe';\nimport '@vitest/spy';\nimport '@vitest/utils/offset';\nimport '@vitest/utils/source-map';\nimport './chunks/_commonjsHelpers.D26ty3Ew.js';\nimport './chunks/rpc.MzXet3jl.js';\nimport './chunks/index.Chj8NDwU.js';\nimport '@vitest/snapshot';\nimport 'vite/module-runner';\n"],"x_google_ignoreList":[0,1,2,3,4,5,6],"mappings":";;;AAAA,IAAI,oBAAoB;AACxB,qBAAqB;AACH,OAAO,UAAU,OAAO,QAAQ;CAe5B,iBAAiB,CAAC,EAAA,CAAE;AA8E1B,IAAA,QAAQ;AAAoE,IAAA,4BAAY,IAAI,WAAW,EAAE;AAAG,IAAA,4BAAY,IAAI,WAAW,GAAG;AAC1J,KAAK,IAAI,IAAI,GAAG,IAAI,MAAM,QAAQ,KAAK;CACtC,IAAI,IAAI,MAAM,WAAW,CAAC;CAC1B,UAAU,KAAK,GAAG,UAAU,KAAK;AAClC;AA8IkE,GAAO,kBAAP;AA2e1C,MAAM;AA0L9B,MAAM,6BAA6B;AAAyE,GAG/E,KAAK,UAAU,0BAA0B,EAHsC,EAIzE,KAAK,UAAU,0BAA0B,EAJgC;AA6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C,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;CAyBjB,MAAM,gBAAgB,YAAY;EAC9B,MAAM,wBAAwB;GAC1B;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;EACJ;EACA,MAAM,MAAM;GAER,SAAS;GACT,aAAa;GACb,WAAW;GACX,cAAc;GACd,YAAY;GACZ,WAAW;GACX,YAAY;GACZ,YAAY;GACZ,aAAa;GACb,UAAU;GACV,YAAY;GACZ,UAAU;GACV,eAAe;GACf,cAAc;GACd,YAAY;GACZ,eAAe;GACf,eAAe;GACf,uBAAuB;GACvB,mBAAmB;GACnB,UAAU;GACV,KAAK,QAAQ;GACb,kBAAkB,QAAQ;GAC1B,SAAS,QAAQ;GACjB,SAAS,QAAQ;GACjB,MAAM,QAAQ;GACd,MAAM,QAAQ;GACd,gBAAgB,QAAQ;GACxB,WAAW,QAAQ;EACvB;EAEA,sBAAiB,SAAS,SAAS,OAAO,eAAe,KAAK,MAAM,EAAE,YAAY,GAAG,QAAQ,aAAA,CAAc,CAAC,CAAC,EAAE,CAAC,CAAC;EACjH,OAAO;CACX;CACA,QAAQ,eAAe"}
@@ -1,182 +0,0 @@
1
- import { m as it$1, n as beforeAll, o as describe, r as beforeEach, t as afterAll } from "./utils-CiH_DjFW.mjs";
2
- import { t as TestRunner } from "./test.DNmyFkvJ-YPzDR0Co.mjs";
3
- import * as Cause from "effect/Cause";
4
- import * as Duration from "effect/Duration";
5
- import * as Effect from "effect/Effect";
6
- import * as Exit from "effect/Exit";
7
- import { flow, pipe } from "effect/Function";
8
- import * as Layer from "effect/Layer";
9
- import { isObject } from "effect/Predicate";
10
- import * as Rec from "effect/Record";
11
- import * as Schedule from "effect/Schedule";
12
- import * as Schema from "effect/Schema";
13
- import * as Scope from "effect/Scope";
14
- import * as fc from "effect/testing/FastCheck";
15
- import * as TestClock from "effect/testing/TestClock";
16
- import * as TestConsole from "effect/testing/TestConsole";
17
- //#region ../../node_modules/.pnpm/@effect+vitest@4.0.0-rc.111_effect@4.0.0-rc.111_vitest@4.1.11_@types+node@26.2.0_vite@7_0a4161190c2476edad4e3173ad651095/node_modules/@effect/vitest/dist/internal/internal.js
18
- /**
19
- * @since 4.0.0
20
- */
21
- const getCurrentSuite = TestRunner.getCurrentSuite;
22
- const runPromise = /*#__PURE__*/ Effect.fnUntraced(function* (effect, _ctx) {
23
- const exit = yield* Effect.exit(effect);
24
- if (Exit.isFailure(exit)) {
25
- const errors = Cause.prettyErrors(exit.cause);
26
- for (let i = 0; i < errors.length; i++) yield* Effect.logError(errors[i]);
27
- }
28
- return yield* exit;
29
- }, (effect, _, ctx) => Effect.runPromise(effect, { signal: ctx?.signal }));
30
- /** @internal */
31
- const runTest = (ctx) => (effect) => runPromise(effect, ctx);
32
- const TestEnv = /*#__PURE__*/ Layer.mergeAll(TestConsole.layer, /*#__PURE__*/ TestClock.layer());
33
- /** @internal */
34
- const testOptions = (timeout) => typeof timeout === "number" ? { timeout } : timeout ?? {};
35
- const hookTimeout = (timeout) => timeout === void 0 ? void 0 : Duration.toMillis(Duration.fromInputUnsafe(timeout));
36
- const makeItProxy = (it, overrides) => new Proxy(it, {
37
- apply(target, thisArg, argArray) {
38
- return Reflect.apply(target, thisArg, argArray);
39
- },
40
- get(target, property, receiver) {
41
- if (Object.hasOwn(overrides, property)) return Reflect.get(overrides, property);
42
- return Reflect.get(target, property, receiver);
43
- }
44
- });
45
- const collectTasks = (tasks, acc = []) => {
46
- for (let i = 0; i < tasks.length; i++) {
47
- const task = tasks[i];
48
- if (task.type === "test" && task.mode !== "skip" && task.mode !== "todo") acc.push(task);
49
- else if (task.tasks !== void 0) collectTasks(task.tasks, acc);
50
- }
51
- return acc;
52
- };
53
- /** @internal */
54
- const makeTester = (mapEffect, it = it$1) => {
55
- const run = (ctx, args, self) => pipe(Effect.suspend(() => self(...args)), mapEffect, runTest(ctx));
56
- const f = (name, self, timeout) => it(name, testOptions(timeout), (ctx) => run(ctx, [ctx], self));
57
- const skip = (name, self, timeout) => it.skip(name, testOptions(timeout), (ctx) => run(ctx, [ctx], self));
58
- const skipIf = (condition) => (name, self, timeout) => it.skipIf(condition)(name, testOptions(timeout), (ctx) => run(ctx, [ctx], self));
59
- const runIf = (condition) => (name, self, timeout) => it.runIf(condition)(name, testOptions(timeout), (ctx) => run(ctx, [ctx], self));
60
- const only = (name, self, timeout) => it.only(name, testOptions(timeout), (ctx) => run(ctx, [ctx], self));
61
- const each = (cases) => (name, self, timeout) => it.for(cases)(name, testOptions(timeout), (args, ctx) => run(ctx, [args], self));
62
- const fails = (name, self, timeout) => it$1.fails(name, testOptions(timeout), (ctx) => run(ctx, [ctx], self));
63
- const prop = (name, arbitraries, self, timeout) => {
64
- if (Array.isArray(arbitraries)) {
65
- const arbs = arbitraries.map((arbitrary) => {
66
- if (Schema.isSchema(arbitrary)) return Schema.toArbitrary(arbitrary)(fc);
67
- return arbitrary;
68
- });
69
- return it(name, testOptions(timeout), (ctx) => fc.assert(fc.asyncProperty(...arbs, (...as) => run(ctx, [as, ctx], self)), isObject(timeout) ? timeout?.fastCheck : {}));
70
- }
71
- const arbs = fc.record(Object.keys(arbitraries).reduce(function(result, key) {
72
- const arb = arbitraries[key];
73
- Rec.assignProperty(result, key, Schema.isSchema(arb) ? Schema.toArbitrary(arb)(fc) : arb);
74
- return result;
75
- }, {}));
76
- return it(name, testOptions(timeout), (ctx) => fc.assert(fc.asyncProperty(arbs, (...as) => run(ctx, [as[0], ctx], self)), isObject(timeout) ? timeout?.fastCheck : {}));
77
- };
78
- return Object.assign(f, {
79
- skip,
80
- skipIf,
81
- runIf,
82
- only,
83
- each,
84
- fails,
85
- prop
86
- });
87
- };
88
- /** @internal */
89
- const prop = (name, arbitraries, self, timeout) => {
90
- if (Array.isArray(arbitraries)) {
91
- const arbs = arbitraries.map((arbitrary) => {
92
- if (Schema.isSchema(arbitrary)) throw new Error("Schemas are not supported yet");
93
- return arbitrary;
94
- });
95
- return it$1(name, testOptions(timeout), (ctx) => fc.assert(fc.property(...arbs, (...as) => self(as, ctx)), isObject(timeout) ? timeout?.fastCheck : {}));
96
- }
97
- const arbs = fc.record(Object.keys(arbitraries).reduce(function(result, key) {
98
- const arb = arbitraries[key];
99
- if (Schema.isSchema(arb)) throw new Error("Schemas are not supported yet");
100
- Rec.assignProperty(result, key, arb);
101
- return result;
102
- }, {}));
103
- return it$1(name, testOptions(timeout), (ctx) => fc.assert(fc.property(arbs, (as) => self(as, ctx)), isObject(timeout) ? timeout?.fastCheck : {}));
104
- };
105
- /** @internal */
106
- const layer = (layer_, options) => (...args) => {
107
- const excludeTestServices = options?.excludeTestServices ?? false;
108
- const withTestEnv = excludeTestServices ? layer_ : Layer.provideMerge(layer_, TestEnv);
109
- const memoMap = options?.memoMap ?? Effect.runSync(Layer.makeMemoMap);
110
- const scope = Effect.runSync(Scope.make());
111
- const contextEffect = Layer.buildWithMemoMap(withTestEnv, memoMap, scope).pipe(Effect.orDie, Effect.cached, Effect.runSync);
112
- let closed = false;
113
- const closeScope = (ctx) => {
114
- if (closed) return Promise.resolve();
115
- closed = true;
116
- return runPromise(Scope.close(scope, Exit.void), ctx);
117
- };
118
- const makeIt = (it) => makeItProxy(it, {
119
- effect: makeTester((effect) => Effect.flatMap(contextEffect, (context) => effect.pipe(Effect.scoped, Effect.provide(context))), it),
120
- prop,
121
- flakyTest,
122
- layer(nestedLayer, options) {
123
- return layer(Layer.provideMerge(nestedLayer, withTestEnv), {
124
- ...options,
125
- memoMap: Layer.forkMemoMapUnsafe(memoMap),
126
- excludeTestServices
127
- });
128
- }
129
- });
130
- if (args.length === 1) {
131
- const currentSuite = getCurrentSuite();
132
- const previousTasks = new Set(currentSuite.tasks);
133
- args[0](makeIt(it$1));
134
- const blockTasks = collectTasks(currentSuite.tasks.filter((task) => !previousTasks.has(task)));
135
- if (blockTasks.length === 0) {
136
- afterAll(() => closeScope(), hookTimeout(options?.timeout));
137
- return;
138
- }
139
- const blockTaskSet = new Set(blockTasks);
140
- let remaining = blockTasks.length;
141
- beforeEach((ctx) => {
142
- if (!blockTaskSet.has(ctx.task)) return;
143
- ctx.onTestFinished(() => {
144
- remaining--;
145
- if (remaining === 0) return closeScope(ctx);
146
- });
147
- return runPromise(Effect.asVoid(contextEffect), ctx);
148
- }, hookTimeout(options?.timeout));
149
- afterAll(() => closeScope(), hookTimeout(options?.timeout));
150
- return;
151
- }
152
- return describe(args[0], () => {
153
- beforeAll(() => runPromise(Effect.asVoid(contextEffect)), hookTimeout(options?.timeout));
154
- afterAll(() => closeScope(), hookTimeout(options?.timeout));
155
- return args[1](makeIt(it$1));
156
- });
157
- };
158
- /** @internal */
159
- const flakyTest = (self, timeout = Duration.seconds(30)) => pipe(self, Effect.scoped, Effect.sandbox, Effect.retry(pipe(Schedule.recurs(10), Schedule.while((_) => Effect.succeed(Duration.isLessThanOrEqualTo(Duration.fromInputUnsafe(_.elapsed), Duration.fromInputUnsafe(timeout)))))), Effect.orDie);
160
- /** @internal */
161
- const makeMethods = (it) => makeItProxy(it, {
162
- effect: makeTester(flow(Effect.scoped, Effect.provide(TestEnv)), it),
163
- live: makeTester(Effect.scoped, it),
164
- flakyTest,
165
- layer,
166
- prop
167
- });
168
- /** @internal */
169
- const { effect, live } = /*#__PURE__*/ makeMethods(it$1);
170
- //#endregion
171
- //#region ../../node_modules/.pnpm/@effect+vitest@4.0.0-rc.111_effect@4.0.0-rc.111_vitest@4.1.11_@types+node@26.2.0_vite@7_0a4161190c2476edad4e3173ad651095/node_modules/@effect/vitest/dist/index.js
172
- /**
173
- * @since 4.0.0
174
- */
175
- /**
176
- * @since 4.0.0
177
- */
178
- const it = /*#__PURE__*/ makeMethods(it$1);
179
- //#endregion
180
- export { it as t };
181
-
182
- //# sourceMappingURL=dist-nohcnkD6.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"dist-nohcnkD6.mjs","names":["V.it","V.describe","V.it"],"sources":["../../../node_modules/.pnpm/@effect+vitest@4.0.0-rc.111_effect@4.0.0-rc.111_vitest@4.1.11_@types+node@26.2.0_vite@7_0a4161190c2476edad4e3173ad651095/node_modules/@effect/vitest/dist/internal/internal.js","../../../node_modules/.pnpm/@effect+vitest@4.0.0-rc.111_effect@4.0.0-rc.111_vitest@4.1.11_@types+node@26.2.0_vite@7_0a4161190c2476edad4e3173ad651095/node_modules/@effect/vitest/dist/index.js"],"sourcesContent":["/**\n * @since 4.0.0\n */\nimport * as Cause from \"effect/Cause\";\nimport * as Duration from \"effect/Duration\";\nimport * as Effect from \"effect/Effect\";\nimport * as Exit from \"effect/Exit\";\nimport { flow, pipe } from \"effect/Function\";\nimport * as Layer from \"effect/Layer\";\nimport { isObject } from \"effect/Predicate\";\nimport * as Rec from \"effect/Record\";\nimport * as Schedule from \"effect/Schedule\";\nimport * as Schema from \"effect/Schema\";\nimport * as Scope from \"effect/Scope\";\nimport * as fc from \"effect/testing/FastCheck\";\nimport * as TestClock from \"effect/testing/TestClock\";\nimport * as TestConsole from \"effect/testing/TestConsole\";\nimport * as V from \"vitest\";\nconst getCurrentSuite = V.TestRunner.getCurrentSuite;\nconst runPromise = /*#__PURE__*/Effect.fnUntraced(function* (effect, _ctx) {\n const exit = yield* Effect.exit(effect);\n if (Exit.isFailure(exit)) {\n const errors = Cause.prettyErrors(exit.cause);\n for (let i = 0; i < errors.length; i++) {\n yield* Effect.logError(errors[i]);\n }\n }\n return yield* exit;\n}, (effect, _, ctx) => Effect.runPromise(effect, {\n signal: ctx?.signal\n}));\n/** @internal */\nconst runTest = ctx => effect => runPromise(effect, ctx);\nconst TestEnv = /*#__PURE__*/Layer.mergeAll(TestConsole.layer, /*#__PURE__*/TestClock.layer());\n/** @internal */\nexport const addEqualityTesters = () => {\n V.expect.addEqualityTesters([]);\n};\n/** @internal */\nconst testOptions = timeout => typeof timeout === \"number\" ? {\n timeout\n} : timeout ?? {};\nconst hookTimeout = timeout => timeout === undefined ? undefined : Duration.toMillis(Duration.fromInputUnsafe(timeout));\nconst makeItProxy = (it, overrides) => new Proxy(it, {\n apply(target, thisArg, argArray) {\n return Reflect.apply(target, thisArg, argArray);\n },\n get(target, property, receiver) {\n if (Object.hasOwn(overrides, property)) {\n return Reflect.get(overrides, property);\n }\n // do not bind: binding would strip vitest's static helpers (e.g. `describe.each`)\n return Reflect.get(target, property, receiver);\n }\n});\nconst collectTasks = (tasks, acc = []) => {\n for (let i = 0; i < tasks.length; i++) {\n const task = tasks[i];\n if (task.type === \"test\" && task.mode !== \"skip\" && task.mode !== \"todo\") {\n acc.push(task);\n } else if (task.tasks !== undefined) {\n collectTasks(task.tasks, acc);\n }\n }\n return acc;\n};\n/** @internal */\nconst makeTester = (mapEffect, it = V.it) => {\n const run = (ctx, args, self) => pipe(Effect.suspend(() => self(...args)), mapEffect, runTest(ctx));\n const f = (name, self, timeout) => it(name, testOptions(timeout), ctx => run(ctx, [ctx], self));\n const skip = (name, self, timeout) => it.skip(name, testOptions(timeout), ctx => run(ctx, [ctx], self));\n const skipIf = condition => (name, self, timeout) => it.skipIf(condition)(name, testOptions(timeout), ctx => run(ctx, [ctx], self));\n const runIf = condition => (name, self, timeout) => it.runIf(condition)(name, testOptions(timeout), ctx => run(ctx, [ctx], self));\n const only = (name, self, timeout) => it.only(name, testOptions(timeout), ctx => run(ctx, [ctx], self));\n const each = cases => (name, self, timeout) => it.for(cases)(name, testOptions(timeout), (args, ctx) => run(ctx, [args], self));\n const fails = (name, self, timeout) => V.it.fails(name, testOptions(timeout), ctx => run(ctx, [ctx], self));\n const prop = (name, arbitraries, self, timeout) => {\n if (Array.isArray(arbitraries)) {\n const arbs = arbitraries.map(arbitrary => {\n if (Schema.isSchema(arbitrary)) {\n return Schema.toArbitrary(arbitrary)(fc);\n }\n return arbitrary;\n });\n return it(name, testOptions(timeout), ctx =>\n // @ts-ignore\n fc.assert(\n // @ts-ignore\n fc.asyncProperty(...arbs, (...as) => run(ctx, [as, ctx], self)),\n // @ts-ignore\n isObject(timeout) ? timeout?.fastCheck : {}));\n }\n const arbs = fc.record(Object.keys(arbitraries).reduce(function (result, key) {\n const arb = arbitraries[key];\n Rec.assignProperty(result, key, Schema.isSchema(arb) ? Schema.toArbitrary(arb)(fc) : arb);\n return result;\n }, {}));\n return it(name, testOptions(timeout), ctx =>\n // @ts-ignore\n fc.assert(fc.asyncProperty(arbs, (...as) =>\n // @ts-ignore\n run(ctx, [as[0], ctx], self)),\n // @ts-ignore\n isObject(timeout) ? timeout?.fastCheck : {}));\n };\n return Object.assign(f, {\n skip,\n skipIf,\n runIf,\n only,\n each,\n fails,\n prop\n });\n};\n/** @internal */\nexport const prop = (name, arbitraries, self, timeout) => {\n if (Array.isArray(arbitraries)) {\n const arbs = arbitraries.map(arbitrary => {\n if (Schema.isSchema(arbitrary)) {\n throw new Error(\"Schemas are not supported yet\");\n }\n return arbitrary;\n });\n return V.it(name, testOptions(timeout),\n // @ts-ignore\n ctx => fc.assert(fc.property(...arbs, (...as) => self(as, ctx)), isObject(timeout) ? timeout?.fastCheck : {}));\n }\n const arbs = fc.record(Object.keys(arbitraries).reduce(function (result, key) {\n const arb = arbitraries[key];\n if (Schema.isSchema(arb)) {\n throw new Error(\"Schemas are not supported yet\");\n }\n Rec.assignProperty(result, key, arb);\n return result;\n }, {}));\n return V.it(name, testOptions(timeout),\n // @ts-ignore\n ctx => fc.assert(fc.property(arbs, as => self(as, ctx)), isObject(timeout) ? timeout?.fastCheck : {}));\n};\n/** @internal */\nexport const layer = (layer_, options) => (...args) => {\n const excludeTestServices = options?.excludeTestServices ?? false;\n const withTestEnv = excludeTestServices ? layer_ : Layer.provideMerge(layer_, TestEnv);\n const memoMap = options?.memoMap ?? Effect.runSync(Layer.makeMemoMap);\n const scope = Effect.runSync(Scope.make());\n const contextEffect = Layer.buildWithMemoMap(withTestEnv, memoMap, scope).pipe(Effect.orDie, Effect.cached, Effect.runSync);\n let closed = false;\n const closeScope = ctx => {\n if (closed) {\n return Promise.resolve();\n }\n closed = true;\n return runPromise(Scope.close(scope, Exit.void), ctx);\n };\n const makeIt = it => makeItProxy(it, {\n effect: makeTester(effect => Effect.flatMap(contextEffect, context => effect.pipe(Effect.scoped, Effect.provide(context))), it),\n prop,\n flakyTest,\n layer(nestedLayer, options) {\n return layer(Layer.provideMerge(nestedLayer, withTestEnv), {\n ...options,\n memoMap: Layer.forkMemoMapUnsafe(memoMap),\n excludeTestServices\n });\n }\n });\n if (args.length === 1) {\n const currentSuite = getCurrentSuite();\n const previousTasks = new Set(currentSuite.tasks);\n args[0](makeIt(V.it));\n const blockTasks = collectTasks(currentSuite.tasks.filter(task => !previousTasks.has(task)));\n if (blockTasks.length === 0) {\n V.afterAll(() => closeScope(), hookTimeout(options?.timeout));\n return;\n }\n const blockTaskSet = new Set(blockTasks);\n let remaining = blockTasks.length;\n V.beforeEach(ctx => {\n if (!blockTaskSet.has(ctx.task)) {\n return;\n }\n ctx.onTestFinished(() => {\n remaining--;\n if (remaining === 0) {\n return closeScope(ctx);\n }\n });\n return runPromise(Effect.asVoid(contextEffect), ctx);\n }, hookTimeout(options?.timeout));\n V.afterAll(() => closeScope(), hookTimeout(options?.timeout));\n return;\n }\n return V.describe(args[0], () => {\n V.beforeAll(() => runPromise(Effect.asVoid(contextEffect)), hookTimeout(options?.timeout));\n V.afterAll(() => closeScope(), hookTimeout(options?.timeout));\n return args[1](makeIt(V.it));\n });\n};\n/** @internal */\nexport const flakyTest = (self, timeout = Duration.seconds(30)) => pipe(self, Effect.scoped, Effect.sandbox, Effect.retry(pipe(Schedule.recurs(10), Schedule.while(_ => Effect.succeed(Duration.isLessThanOrEqualTo(Duration.fromInputUnsafe(_.elapsed), Duration.fromInputUnsafe(timeout)))))), Effect.orDie);\n/** @internal */\nexport const makeMethods = it => makeItProxy(it, {\n effect: makeTester(flow(Effect.scoped, Effect.provide(TestEnv)), it),\n live: makeTester(Effect.scoped, it),\n flakyTest,\n layer,\n prop\n});\n/** @internal */\nexport const {\n /** @internal */\n effect,\n /** @internal */\n live\n} = /*#__PURE__*/makeMethods(V.it);\n/** @internal */\nexport const describeWrapped = (name, f) => V.describe(name, it => f(makeMethods(it)));\n//# sourceMappingURL=internal.js.map","import * as V from \"vitest\";\nimport * as internal from \"./internal/internal.js\";\n/**\n * @since 4.0.0\n */\nexport * from \"vitest\";\n/**\n * @since 4.0.0\n */\nexport const addEqualityTesters = internal.addEqualityTesters;\n/**\n * @since 4.0.0\n */\nexport const effect = internal.effect;\n/**\n * @since 4.0.0\n */\nexport const live = internal.live;\n/**\n * Share a `Layer` between multiple tests, optionally wrapping\n * the tests in a `describe` block if a name is provided.\n *\n * @since 4.0.0\n *\n * ```ts\n * import { assert, layer } from \"@effect/vitest\"\n * import { Effect, Layer, Context } from \"effect\"\n *\n * class Foo extends Context.Service<Foo, \"foo\">()(\"Foo\") {\n * static layer = Layer.succeed(Foo, \"foo\")\n * }\n *\n * class Bar extends Context.Service<Bar, \"bar\">()(\"Bar\") {\n * static layer = Layer.effect(\n * Bar,\n * Effect.map(Foo, () => \"bar\" as const)\n * )\n * }\n *\n * layer(Foo.layer)(\"layer\", (it) => {\n * it.effect(\"adds context\", () =>\n * Effect.gen(function*() {\n * const foo = yield* Foo\n * assert.strictEqual(foo, \"foo\")\n * }))\n *\n * it.layer(Bar.layer)(\"nested\", (it) => {\n * it.effect(\"adds context\", () =>\n * Effect.gen(function*() {\n * const foo = yield* Foo\n * const bar = yield* Bar\n * assert.strictEqual(foo, \"foo\")\n * assert.strictEqual(bar, \"bar\")\n * }))\n * })\n * })\n * ```\n */\nexport const layer = internal.layer;\n/**\n * @since 4.0.0\n */\nexport const flakyTest = internal.flakyTest;\n/**\n * @since 4.0.0\n */\nexport const prop = internal.prop;\n/**\n * @since 4.0.0\n */\n/**\n * @since 4.0.0\n */\nexport const it = /*#__PURE__*/internal.makeMethods(V.it);\n/**\n * @since 4.0.0\n */\nexport const makeMethods = internal.makeMethods;\n/**\n * @since 4.0.0\n */\nexport const describeWrapped = internal.describeWrapped;\n//# sourceMappingURL=index.js.map"],"x_google_ignoreList":[0,1],"mappings":";;;;;;;;;;;;;;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