chorus-codes 0.7.0 → 0.7.2

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 (293) hide show
  1. package/.next/BUILD_ID +1 -1
  2. package/.next/build-manifest.json +3 -3
  3. package/.next/cache/.previewinfo +1 -1
  4. package/.next/cache/.rscinfo +1 -1
  5. package/.next/cache/.tsbuildinfo +1 -1
  6. package/.next/fallback-build-manifest.json +3 -3
  7. package/.next/prerender-manifest.json +3 -3
  8. package/.next/server/app/_global-error.html +1 -1
  9. package/.next/server/app/_global-error.rsc +1 -1
  10. package/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  11. package/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  12. package/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
  13. package/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
  14. package/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  15. package/.next/server/app/_not-found.html +1 -1
  16. package/.next/server/app/_not-found.rsc +1 -1
  17. package/.next/server/app/_not-found.segments/_full.segment.rsc +1 -1
  18. package/.next/server/app/_not-found.segments/_head.segment.rsc +1 -1
  19. package/.next/server/app/_not-found.segments/_index.segment.rsc +1 -1
  20. package/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
  21. package/.next/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
  22. package/.next/server/app/_not-found.segments/_tree.segment.rsc +1 -1
  23. package/.next/server/app/new.html +1 -1
  24. package/.next/server/app/new.rsc +1 -1
  25. package/.next/server/app/new.segments/_full.segment.rsc +1 -1
  26. package/.next/server/app/new.segments/_head.segment.rsc +1 -1
  27. package/.next/server/app/new.segments/_index.segment.rsc +1 -1
  28. package/.next/server/app/new.segments/_tree.segment.rsc +1 -1
  29. package/.next/server/app/new.segments/new/__PAGE__.segment.rsc +1 -1
  30. package/.next/server/app/new.segments/new.segment.rsc +1 -1
  31. package/.next/server/app/onboarding.html +1 -1
  32. package/.next/server/app/onboarding.rsc +1 -1
  33. package/.next/server/app/onboarding.segments/_full.segment.rsc +1 -1
  34. package/.next/server/app/onboarding.segments/_head.segment.rsc +1 -1
  35. package/.next/server/app/onboarding.segments/_index.segment.rsc +1 -1
  36. package/.next/server/app/onboarding.segments/_tree.segment.rsc +1 -1
  37. package/.next/server/app/onboarding.segments/onboarding/__PAGE__.segment.rsc +1 -1
  38. package/.next/server/app/onboarding.segments/onboarding.segment.rsc +1 -1
  39. package/.next/server/app/personas.html +1 -1
  40. package/.next/server/app/personas.rsc +1 -1
  41. package/.next/server/app/personas.segments/_full.segment.rsc +1 -1
  42. package/.next/server/app/personas.segments/_head.segment.rsc +1 -1
  43. package/.next/server/app/personas.segments/_index.segment.rsc +1 -1
  44. package/.next/server/app/personas.segments/_tree.segment.rsc +1 -1
  45. package/.next/server/app/personas.segments/personas/__PAGE__.segment.rsc +1 -1
  46. package/.next/server/app/personas.segments/personas.segment.rsc +1 -1
  47. package/.next/server/app/settings.html +1 -1
  48. package/.next/server/app/settings.rsc +1 -1
  49. package/.next/server/app/settings.segments/_full.segment.rsc +1 -1
  50. package/.next/server/app/settings.segments/_head.segment.rsc +1 -1
  51. package/.next/server/app/settings.segments/_index.segment.rsc +1 -1
  52. package/.next/server/app/settings.segments/_tree.segment.rsc +1 -1
  53. package/.next/server/app/settings.segments/settings/__PAGE__.segment.rsc +1 -1
  54. package/.next/server/app/settings.segments/settings.segment.rsc +1 -1
  55. package/.next/server/app/templates.html +1 -1
  56. package/.next/server/app/templates.rsc +1 -1
  57. package/.next/server/app/templates.segments/_full.segment.rsc +1 -1
  58. package/.next/server/app/templates.segments/_head.segment.rsc +1 -1
  59. package/.next/server/app/templates.segments/_index.segment.rsc +1 -1
  60. package/.next/server/app/templates.segments/_tree.segment.rsc +1 -1
  61. package/.next/server/app/templates.segments/templates/__PAGE__.segment.rsc +1 -1
  62. package/.next/server/app/templates.segments/templates.segment.rsc +1 -1
  63. package/.next/server/middleware-build-manifest.js +3 -3
  64. package/.next/server/pages/404.html +1 -1
  65. package/.next/server/pages/500.html +1 -1
  66. package/.next/server/server-reference-manifest.js +1 -1
  67. package/.next/server/server-reference-manifest.json +1 -1
  68. package/.next/trace +1 -1
  69. package/.next/trace-build +1 -1
  70. package/README.md +38 -15
  71. package/dist/cli/commands/doctor.js +116 -0
  72. package/dist/cli/commands/doctor.js.map +1 -0
  73. package/dist/cli/commands/init.js +211 -0
  74. package/dist/cli/commands/init.js.map +1 -0
  75. package/dist/cli/commands/start.js +298 -0
  76. package/dist/cli/commands/start.js.map +1 -0
  77. package/dist/cli/commands/status.js +54 -0
  78. package/dist/cli/commands/status.js.map +1 -0
  79. package/dist/cli/commands/stop.js +97 -0
  80. package/dist/cli/commands/stop.js.map +1 -0
  81. package/dist/cli/connect.js +108 -0
  82. package/dist/cli/connect.js.map +1 -0
  83. package/dist/cli/index.js +99 -0
  84. package/dist/cli/index.js.map +1 -0
  85. package/dist/cli/port-utils.js +260 -0
  86. package/dist/cli/port-utils.js.map +1 -0
  87. package/dist/cli/runtime-env.js +60 -0
  88. package/dist/cli/runtime-env.js.map +1 -0
  89. package/dist/cli/shared.js +54 -0
  90. package/dist/cli/shared.js.map +1 -0
  91. package/dist/cli/ui.js +60 -0
  92. package/dist/cli/ui.js.map +1 -0
  93. package/dist/daemon/agents/claude.js +98 -0
  94. package/dist/daemon/agents/claude.js.map +1 -0
  95. package/dist/daemon/agents/codex.js +160 -0
  96. package/dist/daemon/agents/codex.js.map +1 -0
  97. package/dist/daemon/agents/gemini.js +111 -0
  98. package/dist/daemon/agents/gemini.js.map +1 -0
  99. package/dist/daemon/agents/index.js +59 -0
  100. package/dist/daemon/agents/index.js.map +1 -0
  101. package/dist/daemon/agents/kimi.js +206 -0
  102. package/dist/daemon/agents/kimi.js.map +1 -0
  103. package/dist/daemon/agents/opencode.js +228 -0
  104. package/dist/daemon/agents/opencode.js.map +1 -0
  105. package/dist/daemon/agents/openrouter.js +274 -0
  106. package/dist/daemon/agents/openrouter.js.map +1 -0
  107. package/dist/daemon/agents/parsers/claude.js +63 -0
  108. package/dist/daemon/agents/parsers/claude.js.map +1 -0
  109. package/dist/daemon/agents/parsers/codex.js +51 -0
  110. package/dist/daemon/agents/parsers/codex.js.map +1 -0
  111. package/dist/daemon/agents/parsers/gemini.js +144 -0
  112. package/dist/daemon/agents/parsers/gemini.js.map +1 -0
  113. package/dist/daemon/agents/parsers/index.js +31 -0
  114. package/dist/daemon/agents/parsers/index.js.map +1 -0
  115. package/dist/daemon/agents/parsers/kimi.js +8 -0
  116. package/dist/daemon/agents/parsers/kimi.js.map +1 -0
  117. package/dist/daemon/agents/parsers/opencode.js +105 -0
  118. package/dist/daemon/agents/parsers/opencode.js.map +1 -0
  119. package/dist/daemon/agents/parsers/openrouter.js +69 -0
  120. package/dist/daemon/agents/parsers/openrouter.js.map +1 -0
  121. package/dist/daemon/agents/parsers/shared.js +17 -0
  122. package/dist/daemon/agents/parsers/shared.js.map +1 -0
  123. package/dist/daemon/agents/preflight.js +83 -0
  124. package/dist/daemon/agents/preflight.js.map +1 -0
  125. package/dist/daemon/agents/quote.js +45 -0
  126. package/dist/daemon/agents/quote.js.map +1 -0
  127. package/dist/daemon/agents/sandbox-guard.js +69 -0
  128. package/dist/daemon/agents/sandbox-guard.js.map +1 -0
  129. package/dist/daemon/agents/types.js +6 -0
  130. package/dist/daemon/agents/types.js.map +1 -0
  131. package/dist/daemon/api-response.js +65 -0
  132. package/dist/daemon/api-response.js.map +1 -0
  133. package/dist/daemon/error-detector.js +329 -0
  134. package/dist/daemon/error-detector.js.map +1 -0
  135. package/dist/daemon/headless.js +533 -0
  136. package/dist/daemon/headless.js.map +1 -0
  137. package/dist/daemon/index.js +333 -0
  138. package/dist/daemon/index.js.map +1 -0
  139. package/dist/daemon/openrouter.js +192 -0
  140. package/dist/daemon/openrouter.js.map +1 -0
  141. package/dist/daemon/orchestrators/claude.js +163 -0
  142. package/dist/daemon/orchestrators/claude.js.map +1 -0
  143. package/dist/daemon/orchestrators/codex.js +101 -0
  144. package/dist/daemon/orchestrators/codex.js.map +1 -0
  145. package/dist/daemon/orchestrators/cursor-windsurf.js +118 -0
  146. package/dist/daemon/orchestrators/cursor-windsurf.js.map +1 -0
  147. package/dist/daemon/orchestrators/gemini.js +108 -0
  148. package/dist/daemon/orchestrators/gemini.js.map +1 -0
  149. package/dist/daemon/orchestrators/index.js +90 -0
  150. package/dist/daemon/orchestrators/index.js.map +1 -0
  151. package/dist/daemon/orchestrators/kimi.js +108 -0
  152. package/dist/daemon/orchestrators/kimi.js.map +1 -0
  153. package/dist/daemon/orchestrators/opencode.js +152 -0
  154. package/dist/daemon/orchestrators/opencode.js.map +1 -0
  155. package/dist/daemon/orchestrators/shared.js +60 -0
  156. package/dist/daemon/orchestrators/shared.js.map +1 -0
  157. package/dist/daemon/output-watcher.js +131 -0
  158. package/dist/daemon/output-watcher.js.map +1 -0
  159. package/dist/daemon/participant-aborts.js +123 -0
  160. package/dist/daemon/participant-aborts.js.map +1 -0
  161. package/dist/daemon/reaper.js +46 -0
  162. package/dist/daemon/reaper.js.map +1 -0
  163. package/dist/daemon/routes/chats-events.js +62 -0
  164. package/dist/daemon/routes/chats-events.js.map +1 -0
  165. package/dist/daemon/routes/chats-stream.js +241 -0
  166. package/dist/daemon/routes/chats-stream.js.map +1 -0
  167. package/dist/daemon/routes/chats-validation.js +13 -0
  168. package/dist/daemon/routes/chats-validation.js.map +1 -0
  169. package/dist/daemon/routes/chats.js +545 -0
  170. package/dist/daemon/routes/chats.js.map +1 -0
  171. package/dist/daemon/routes/openrouter.js +103 -0
  172. package/dist/daemon/routes/openrouter.js.map +1 -0
  173. package/dist/daemon/routes/settings.js +199 -0
  174. package/dist/daemon/routes/settings.js.map +1 -0
  175. package/dist/daemon/routes/stats.js +155 -0
  176. package/dist/daemon/routes/stats.js.map +1 -0
  177. package/dist/daemon/routes/system.js +208 -0
  178. package/dist/daemon/routes/system.js.map +1 -0
  179. package/dist/daemon/routes/templates-personas.js +254 -0
  180. package/dist/daemon/routes/templates-personas.js.map +1 -0
  181. package/dist/daemon/routes/voices.js +139 -0
  182. package/dist/daemon/routes/voices.js.map +1 -0
  183. package/dist/daemon/runner/doer-driver.js +346 -0
  184. package/dist/daemon/runner/doer-driver.js.map +1 -0
  185. package/dist/daemon/runner/doer.js +336 -0
  186. package/dist/daemon/runner/doer.js.map +1 -0
  187. package/dist/daemon/runner/prior-round.js +140 -0
  188. package/dist/daemon/runner/prior-round.js.map +1 -0
  189. package/dist/daemon/runner/prompt-builder.js +292 -0
  190. package/dist/daemon/runner/prompt-builder.js.map +1 -0
  191. package/dist/daemon/runner/review-only-phase.js +103 -0
  192. package/dist/daemon/runner/review-only-phase.js.map +1 -0
  193. package/dist/daemon/runner/reviewer-driver.js +410 -0
  194. package/dist/daemon/runner/reviewer-driver.js.map +1 -0
  195. package/dist/daemon/runner/reviewer.js +384 -0
  196. package/dist/daemon/runner/reviewer.js.map +1 -0
  197. package/dist/daemon/runner/run-with-fallback.js +56 -0
  198. package/dist/daemon/runner/run-with-fallback.js.map +1 -0
  199. package/dist/daemon/runner/sanitize-name.js +8 -0
  200. package/dist/daemon/runner/sanitize-name.js.map +1 -0
  201. package/dist/daemon/runner/stream-file-writer.js +116 -0
  202. package/dist/daemon/runner/stream-file-writer.js.map +1 -0
  203. package/dist/daemon/runner/swap-sidecar.js +102 -0
  204. package/dist/daemon/runner/swap-sidecar.js.map +1 -0
  205. package/dist/daemon/runner/template-fallback.js +119 -0
  206. package/dist/daemon/runner/template-fallback.js.map +1 -0
  207. package/dist/daemon/runner/types.js +3 -0
  208. package/dist/daemon/runner/types.js.map +1 -0
  209. package/dist/daemon/runner/verdict.js +51 -0
  210. package/dist/daemon/runner/verdict.js.map +1 -0
  211. package/dist/daemon/runner-multiplex.js +364 -0
  212. package/dist/daemon/runner-multiplex.js.map +1 -0
  213. package/dist/daemon/runner.js +427 -0
  214. package/dist/daemon/runner.js.map +1 -0
  215. package/dist/daemon/ship.js +340 -0
  216. package/dist/daemon/ship.js.map +1 -0
  217. package/dist/daemon/template-cache.js +37 -0
  218. package/dist/daemon/template-cache.js.map +1 -0
  219. package/dist/daemon/tmux-types.js +9 -0
  220. package/dist/daemon/tmux-types.js.map +1 -0
  221. package/dist/daemon/tmux.js +341 -0
  222. package/dist/daemon/tmux.js.map +1 -0
  223. package/dist/lib/atomic-write.js +55 -0
  224. package/dist/lib/atomic-write.js.map +1 -0
  225. package/dist/lib/chat-events-bus.js +27 -0
  226. package/dist/lib/chat-events-bus.js.map +1 -0
  227. package/dist/lib/chat-slug.js +105 -0
  228. package/dist/lib/chat-slug.js.map +1 -0
  229. package/dist/lib/cli-detect.js +388 -0
  230. package/dist/lib/cli-detect.js.map +1 -0
  231. package/dist/lib/cli-health.js +156 -0
  232. package/dist/lib/cli-health.js.map +1 -0
  233. package/dist/lib/cli-paths.js +113 -0
  234. package/dist/lib/cli-paths.js.map +1 -0
  235. package/dist/lib/cli-precheck.js +141 -0
  236. package/dist/lib/cli-precheck.js.map +1 -0
  237. package/dist/lib/db/chats.js +244 -0
  238. package/dist/lib/db/chats.js.map +1 -0
  239. package/dist/lib/db/connection.js +254 -0
  240. package/dist/lib/db/connection.js.map +1 -0
  241. package/dist/lib/db/index.js +34 -0
  242. package/dist/lib/db/index.js.map +1 -0
  243. package/dist/lib/db/personas.js +65 -0
  244. package/dist/lib/db/personas.js.map +1 -0
  245. package/dist/lib/db/phase-events.js +172 -0
  246. package/dist/lib/db/phase-events.js.map +1 -0
  247. package/dist/lib/db/secrets.js +53 -0
  248. package/dist/lib/db/secrets.js.map +1 -0
  249. package/dist/lib/db/settings.js +47 -0
  250. package/dist/lib/db/settings.js.map +1 -0
  251. package/dist/lib/db/templates.js +75 -0
  252. package/dist/lib/db/templates.js.map +1 -0
  253. package/dist/lib/db/voices.js +184 -0
  254. package/dist/lib/db/voices.js.map +1 -0
  255. package/dist/lib/lineage-maps.js +200 -0
  256. package/dist/lib/lineage-maps.js.map +1 -0
  257. package/dist/lib/logger.js +186 -0
  258. package/dist/lib/logger.js.map +1 -0
  259. package/dist/lib/personas.js +117 -0
  260. package/dist/lib/personas.js.map +1 -0
  261. package/dist/lib/runtime-path.js +222 -0
  262. package/dist/lib/runtime-path.js.map +1 -0
  263. package/dist/lib/settings/billing.js +58 -0
  264. package/dist/lib/settings/billing.js.map +1 -0
  265. package/dist/lib/settings/permissions.js +81 -0
  266. package/dist/lib/settings/permissions.js.map +1 -0
  267. package/dist/lib/settings/transport.js +113 -0
  268. package/dist/lib/settings/transport.js.map +1 -0
  269. package/dist/lib/telemetry.js +290 -0
  270. package/dist/lib/telemetry.js.map +1 -0
  271. package/dist/lib/template-schema.js +319 -0
  272. package/dist/lib/template-schema.js.map +1 -0
  273. package/dist/lib/template-validation.js +82 -0
  274. package/dist/lib/template-validation.js.map +1 -0
  275. package/dist/lib/voices.js +533 -0
  276. package/dist/lib/voices.js.map +1 -0
  277. package/dist/mcp/client.js +138 -0
  278. package/dist/mcp/client.js.map +1 -0
  279. package/dist/mcp/index.js +178 -0
  280. package/dist/mcp/index.js.map +1 -0
  281. package/dist/mcp/tools.js +355 -0
  282. package/dist/mcp/tools.js.map +1 -0
  283. package/package.json +2 -1
  284. package/.next/dev/static/chunks/05w9_next_dist_shared_lib_0beh7rg._.js +0 -6077
  285. package/.next/dev/static/chunks/05w9_next_dist_shared_lib_0beh7rg._.js.map +0 -69
  286. package/.next/dev/static/chunks/05w9_next_dist_shared_lib_0pjsj.j._.js +0 -6318
  287. package/.next/dev/static/chunks/05w9_next_dist_shared_lib_0pjsj.j._.js.map +0 -71
  288. package/.next/dev/types/cache-life.d.ts +0 -145
  289. package/.next/dev/types/routes.d.ts +0 -84
  290. package/.next/dev/types/validator.ts +0 -178
  291. /package/.next/static/{dJlbRLlhISA0JGtHKVqgQ → 9cD3yIOGe_Aqr17uJHTQS}/_buildManifest.js +0 -0
  292. /package/.next/static/{dJlbRLlhISA0JGtHKVqgQ → 9cD3yIOGe_Aqr17uJHTQS}/_clientMiddlewareManifest.js +0 -0
  293. /package/.next/static/{dJlbRLlhISA0JGtHKVqgQ → 9cD3yIOGe_Aqr17uJHTQS}/_ssgManifest.js +0 -0
@@ -1,71 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": [],
4
- "sections": [
5
- {"offset": {"line": 4, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/deployment-id.ts"],"sourcesContent":["let deploymentId: string | undefined\n\nif (typeof window !== 'undefined') {\n deploymentId = document.documentElement.dataset.dplId\n // Immediately remove the attribute to prevent hydration errors (the dplId was inserted into the\n // HTML only), React isn't aware of it at all.\n delete document.documentElement.dataset.dplId\n} else {\n // Client side: replaced with globalThis.NEXT_DEPLOYMENT_ID\n // Server side: left as is or replaced with a string or replaced with false\n deploymentId = process.env.NEXT_DEPLOYMENT_ID || undefined\n}\n\nexport function getDeploymentId(): string | undefined {\n return deploymentId\n}\n\nexport function getDeploymentIdQuery(ampersand = false): string {\n let id = getDeploymentId()\n if (id) {\n return `${ampersand ? '&' : '?'}dpl=${id}`\n }\n return ''\n}\n\nexport function getAssetToken(): string | undefined {\n return (\n process.env.NEXT_IMMUTABLE_ASSET_TOKEN || process.env.NEXT_DEPLOYMENT_ID\n )\n}\n\nexport function getAssetTokenQuery(ampersand = false): string {\n let id = getAssetToken()\n if (id) {\n return `${ampersand ? '&' : '?'}dpl=${id}`\n }\n return ''\n}\n"],"names":["getAssetToken","getAssetTokenQuery","getDeploymentId","getDeploymentIdQuery","deploymentId","window","document","documentElement","dataset","dplId","process","env","NEXT_DEPLOYMENT_ID","undefined","ampersand","id","NEXT_IMMUTABLE_ASSET_TOKEN"],"mappings":"AAUiBU,QAAQC,GAAG,CAACC,kBAAkB;;;;;;;;;;;;;;;;;;IAe/BZ,aAAa,EAAA;eAAbA;;IAMAC,kBAAkB,EAAA;eAAlBA;;IAlBAC,eAAe,EAAA;eAAfA;;IAIAC,oBAAoB,EAAA;eAApBA;;;AAjBhB,IAAIC;AAEJ,IAAI,OAAOC,WAAW,aAAa;IACjCD,eAAeE,SAASC,eAAe,CAACC,OAAO,CAACC,KAAK;IACrD,gGAAgG;IAChG,8CAA8C;IAC9C,OAAOH,SAASC,eAAe,CAACC,OAAO,CAACC,KAAK;AAC/C,OAAO;IACL,2DAA2D;IAC3D,2EAA2E;IAC3EL,0DAAiDS;AACnD;AAEO,SAASX;IACd,OAAOE;AACT;AAEO,SAASD,qBAAqBW,YAAY,KAAK;IACpD,IAAIC,KAAKb;IACT,IAAIa,IAAI;QACN,OAAO,GAAGD,YAAY,MAAM,IAAI,IAAI,EAAEC,IAAI;IAC5C;IACA,OAAO;AACT;AAEO,SAASf;IACd,OACEU,QAAQC,GAAG,CAACK,0BAA0B,IAAIN,QAAQC,GAAG,CAACC,kBAAkB;AAE5E;AAEO,SAASX,mBAAmBa,YAAY,KAAK;IAClD,IAAIC,KAAKf;IACT,IAAIe,IAAI;;IAGR,OAAO;AACT","ignoreList":[0]}},
6
- {"offset": {"line": 69, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/head-manager-context.shared-runtime.ts"],"sourcesContent":["import React from 'react'\n\nexport const HeadManagerContext: React.Context<{\n updateHead?: (state: any) => void\n mountedInstances?: any\n updateScripts?: (state: any) => void\n scripts?: any\n getIsSsr?: () => boolean\n\n // Used in app directory, to render script tags as server components.\n appDir?: boolean\n nonce?: string\n}> = React.createContext({})\n\nif (process.env.NODE_ENV !== 'production') {\n HeadManagerContext.displayName = 'HeadManagerContext'\n}\n"],"names":["HeadManagerContext","React","createContext","process","env","NODE_ENV","displayName"],"mappings":"AAcIG,QAAQC,GAAG,CAACC,QAAQ,KAAK;;;;;+BAZhBL,sBAAAA;;;eAAAA;;;;gEAFK;AAEX,MAAMA,qBAURC,OAAAA,OAAK,CAACC,aAAa,CAAC,CAAC;AAE1B,wCAA2C;IACzCF,mBAAmBM,WAAW,GAAG;AACnC","ignoreList":[0]}},
7
- {"offset": {"line": 90, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/mitt.ts"],"sourcesContent":["/*\nMIT License\n\nCopyright (c) Jason Miller (https://jasonformat.com/)\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n*/\n\n// This file is based on https://github.com/developit/mitt/blob/v1.1.3/src/index.js\n// It's been edited for the needs of this script\n// See the LICENSE at the top of the file\n\ntype Handler = (...evts: any[]) => void\n\nexport type MittEmitter<T> = {\n on(type: T, handler: Handler): void\n off(type: T, handler: Handler): void\n emit(type: T, ...evts: any[]): void\n}\n\nexport default function mitt(): MittEmitter<string> {\n const all: { [s: string]: Handler[] } = Object.create(null)\n\n return {\n on(type: string, handler: Handler) {\n ;(all[type] || (all[type] = [])).push(handler)\n },\n\n off(type: string, handler: Handler) {\n if (all[type]) {\n all[type].splice(all[type].indexOf(handler) >>> 0, 1)\n }\n },\n\n emit(type: string, ...evts: any[]) {\n // eslint-disable-next-line array-callback-return\n ;(all[type] || []).slice().map((handler: Handler) => {\n handler(...evts)\n })\n },\n }\n}\n"],"names":["mitt","all","Object","create","on","type","handler","push","off","splice","indexOf","emit","evts","slice","map"],"mappings":"AAAA;;;;;;;;;;AAUA,GAEA,mFAAmF;AACnF,gDAAgD;AAChD,yCAAyC;;;;+BAUzC,WAAA;;;eAAwBA;;;AAAT,SAASA;IACtB,MAAMC,MAAkCC,OAAOC,MAAM,CAAC;IAEtD,OAAO;QACLC,IAAGC,IAAY,EAAEC,OAAgB;;YAC7BL,CAAAA,GAAG,CAACI,KAAK,IAAKJ,CAAAA,GAAG,CAACI,KAAK,GAAG,EAAC,CAAC,EAAGE,IAAI,CAACD;QACxC;QAEAE,KAAIH,IAAY,EAAEC,OAAgB;YAChC,IAAIL,GAAG,CAACI,KAAK,EAAE;gBACbJ,GAAG,CAACI,KAAK,CAACI,MAAM,CAACR,GAAG,CAACI,KAAK,CAACK,OAAO,CAACJ,aAAa,GAAG;YACrD;QACF;QAEAK,MAAKN,IAAY,EAAE,GAAGO,IAAW;YAC/B,iDAAiD;;YAC/CX,CAAAA,GAAG,CAACI,KAAK,IAAI,EAAC,EAAGQ,KAAK,GAAGC,GAAG,CAAC,CAACR;gBAC9BA,WAAWM;YACb;QACF;IACF;AACF","ignoreList":[0]}},
8
- {"offset": {"line": 137, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router-context.shared-runtime.ts"],"sourcesContent":["import React from 'react'\nimport type { NextRouter } from './router/router'\n\nexport const RouterContext = React.createContext<NextRouter | null>(null)\n\nif (process.env.NODE_ENV !== 'production') {\n RouterContext.displayName = 'RouterContext'\n}\n"],"names":["RouterContext","React","createContext","process","env","NODE_ENV","displayName"],"mappings":"AAKIG,QAAQC,GAAG,CAACC,QAAQ,KAAK;;;;;+BAFhBL,iBAAAA;;;eAAAA;;;;gEAHK;AAGX,MAAMA,gBAAgBC,OAAAA,OAAK,CAACC,aAAa,CAAoB;AAEpE,wCAA2C;IACzCF,cAAcM,WAAW,GAAG;AAC9B","ignoreList":[0]}},
9
- {"offset": {"line": 158, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/utils/warn-once.ts"],"sourcesContent":["let warnOnce = (_: string) => {}\nif (process.env.NODE_ENV !== 'production') {\n const warnings = new Set<string>()\n warnOnce = (msg: string) => {\n if (!warnings.has(msg)) {\n console.warn(msg)\n }\n warnings.add(msg)\n }\n}\n\nexport { warnOnce }\n"],"names":["warnOnce","_","process","env","NODE_ENV","warnings","Set","msg","has","console","warn","add"],"mappings":"AACIE,QAAQC,GAAG,CAACC,QAAQ,KAAK;;;;;+BAUpBJ,YAAAA;;;eAAAA;;;AAXT,IAAIA,WAAW,CAACC,KAAe;AAC/B,wCAA2C;IACzC,MAAMI,WAAW,IAAIC;IACrBN,WAAW,CAACO;QACV,IAAI,CAACF,SAASG,GAAG,CAACD,MAAM;YACtBE,QAAQC,IAAI,CAACH;QACf;QACAF,SAASM,GAAG,CAACJ;IACf;AACF","ignoreList":[0]}},
10
- {"offset": {"line": 183, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/disable-smooth-scroll.ts"],"sourcesContent":["import { warnOnce } from '../../utils/warn-once'\n\n/**\n * Run function with `scroll-behavior: auto` applied to `<html/>`.\n * This css change will be reverted after the function finishes.\n */\nexport function disableSmoothScrollDuringRouteTransition(\n fn: () => void,\n options: { dontForceLayout?: boolean; onlyHashChange?: boolean } = {}\n) {\n // if only the hash is changed, we don't need to disable smooth scrolling\n // we only care to prevent smooth scrolling when navigating to a new page to avoid jarring UX\n if (options.onlyHashChange) {\n fn()\n return\n }\n\n const htmlElement = document.documentElement\n const hasDataAttribute = htmlElement.dataset.scrollBehavior === 'smooth'\n\n if (!hasDataAttribute) {\n // Warn if smooth scrolling is detected but no data attribute is present\n if (\n process.env.NODE_ENV === 'development' &&\n getComputedStyle(htmlElement).scrollBehavior === 'smooth'\n ) {\n warnOnce(\n 'Detected `scroll-behavior: smooth` on the `<html>` element. To disable smooth scrolling during route transitions, ' +\n 'add `data-scroll-behavior=\"smooth\"` to your <html> element. ' +\n 'Learn more: https://nextjs.org/docs/messages/missing-data-scroll-behavior'\n )\n }\n // No smooth scrolling configured, run directly without style manipulation\n fn()\n return\n }\n\n // Proceed with temporarily disabling smooth scrolling\n const existing = htmlElement.style.scrollBehavior\n htmlElement.style.scrollBehavior = 'auto'\n if (!options.dontForceLayout) {\n // In Chrome-based browsers we need to force reflow before calling `scrollTo`.\n // Otherwise it will not pickup the change in scrollBehavior\n // More info here: https://github.com/vercel/next.js/issues/40719#issuecomment-1336248042\n htmlElement.getClientRects()\n }\n fn()\n htmlElement.style.scrollBehavior = existing\n}\n"],"names":["disableSmoothScrollDuringRouteTransition","fn","options","onlyHashChange","htmlElement","document","documentElement","hasDataAttribute","dataset","scrollBehavior","process","env","NODE_ENV","getComputedStyle","warnOnce","existing","style","dontForceLayout","getClientRects"],"mappings":"AAuBMU,QAAQC,GAAG,CAACC,QAAQ;;;;;+BAjBVZ,4CAAAA;;;eAAAA;;;0BANS;AAMlB,SAASA,yCACdC,EAAc,EACdC,UAAmE,CAAC,CAAC;IAErE,yEAAyE;IACzE,6FAA6F;IAC7F,IAAIA,QAAQC,cAAc,EAAE;QAC1BF;QACA;IACF;IAEA,MAAMG,cAAcC,SAASC,eAAe;IAC5C,MAAMC,mBAAmBH,YAAYI,OAAO,CAACC,cAAc,KAAK;IAEhE,IAAI,CAACF,kBAAkB;QACrB,wEAAwE;QACxE,wDAC2B,iBACzBM,iBAAiBT,aAAaK,cAAc,KAAK,UACjD;YACAK,CAAAA,GAAAA,UAAAA,QAAQ,EACN,uHACE,iEACA;QAEN;QACA,0EAA0E;QAC1Eb;QACA;IACF;IAEA,sDAAsD;IACtD,MAAMc,WAAWX,YAAYY,KAAK,CAACP,cAAc;IACjDL,YAAYY,KAAK,CAACP,cAAc,GAAG;IACnC,IAAI,CAACP,QAAQe,eAAe,EAAE;QAC5B,8EAA8E;QAC9E,4DAA4D;QAC5D,yFAAyF;QACzFb,YAAYc,cAAc;IAC5B;IACAjB;IACAG,YAAYY,KAAK,CAACP,cAAc,GAAGM;AACrC","ignoreList":[0]}},
11
- {"offset": {"line": 229, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/page-path/ensure-leading-slash.ts"],"sourcesContent":["/**\n * For a given page path, this function ensures that there is a leading slash.\n * If there is not a leading slash, one is added, otherwise it is noop.\n */\nexport function ensureLeadingSlash(path: string) {\n return path.startsWith('/') ? path : `/${path}`\n}\n"],"names":["ensureLeadingSlash","path","startsWith"],"mappings":"AAAA;;;CAGC;;;+BACeA,sBAAAA;;;eAAAA;;;AAAT,SAASA,mBAAmBC,IAAY;IAC7C,OAAOA,KAAKC,UAAU,CAAC,OAAOD,OAAO,CAAC,CAAC,EAAEA,MAAM;AACjD","ignoreList":[0]}},
12
- {"offset": {"line": 248, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/segment.ts"],"sourcesContent":["import type { FlightRouterState, Segment } from './app-router-types'\n\nexport function getSegmentValue(segment: Segment) {\n return Array.isArray(segment) ? segment[1] : segment\n}\n\nexport function isGroupSegment(segment: string) {\n // Use array[0] for performant purpose\n return segment[0] === '(' && segment.endsWith(')')\n}\n\nexport function isParallelRouteSegment(segment: string) {\n return segment.startsWith('@') && segment !== '@children'\n}\n\nexport function addSearchParamsIfPageSegment(\n segment: Segment,\n searchParams: Record<string, string | string[] | undefined>\n) {\n const isPageSegment = segment.includes(PAGE_SEGMENT_KEY)\n\n if (isPageSegment) {\n const stringifiedQuery = JSON.stringify(searchParams)\n return stringifiedQuery !== '{}'\n ? PAGE_SEGMENT_KEY + '?' + stringifiedQuery\n : PAGE_SEGMENT_KEY\n }\n\n return segment\n}\n\nexport function computeSelectedLayoutSegment(\n segments: string[] | null,\n parallelRouteKey: string\n): string | null {\n if (!segments || segments.length === 0) {\n return null\n }\n\n // For 'children', use first segment; for other parallel routes, use last segment\n const rawSegment =\n parallelRouteKey === 'children'\n ? segments[0]\n : segments[segments.length - 1]\n\n // If the default slot is showing, return null since it's not technically \"selected\" (it's a fallback)\n // Returning an internal value like `__DEFAULT__` would be confusing\n return rawSegment === DEFAULT_SEGMENT_KEY ? null : rawSegment\n}\n\n/** Get the canonical parameters from the current level to the leaf node. */\nexport function getSelectedLayoutSegmentPath(\n tree: FlightRouterState,\n parallelRouteKey: string,\n first = true,\n segmentPath: string[] = []\n): string[] {\n let node: FlightRouterState\n if (first) {\n // Use the provided parallel route key on the first parallel route\n node = tree[1][parallelRouteKey]\n } else {\n // After first parallel route prefer children, if there's no children pick the first parallel route.\n const parallelRoutes = tree[1]\n node = parallelRoutes.children ?? Object.values(parallelRoutes)[0]\n }\n\n if (!node) return segmentPath\n const segment = node[0]\n\n let segmentValue = getSegmentValue(segment)\n\n if (!segmentValue || segmentValue.startsWith(PAGE_SEGMENT_KEY)) {\n return segmentPath\n }\n\n segmentPath.push(segmentValue)\n\n return getSelectedLayoutSegmentPath(\n node,\n parallelRouteKey,\n false,\n segmentPath\n )\n}\n\nexport const PAGE_SEGMENT_KEY = '__PAGE__'\nexport const DEFAULT_SEGMENT_KEY = '__DEFAULT__'\nexport const NOT_FOUND_SEGMENT_KEY = '/_not-found'\n"],"names":["DEFAULT_SEGMENT_KEY","NOT_FOUND_SEGMENT_KEY","PAGE_SEGMENT_KEY","addSearchParamsIfPageSegment","computeSelectedLayoutSegment","getSegmentValue","getSelectedLayoutSegmentPath","isGroupSegment","isParallelRouteSegment","segment","Array","isArray","endsWith","startsWith","searchParams","isPageSegment","includes","stringifiedQuery","JSON","stringify","segments","parallelRouteKey","length","rawSegment","tree","first","segmentPath","node","parallelRoutes","children","Object","values","segmentValue","push"],"mappings":";;;;;;;;;;;;;;;;;;;;;IAuFaA,mBAAmB,EAAA;eAAnBA;;IACAC,qBAAqB,EAAA;eAArBA;;IAFAC,gBAAgB,EAAA;eAAhBA;;IAvEGC,4BAA4B,EAAA;eAA5BA;;IAgBAC,4BAA4B,EAAA;eAA5BA;;IA7BAC,eAAe,EAAA;eAAfA;;IAiDAC,4BAA4B,EAAA;eAA5BA;;IA7CAC,cAAc,EAAA;eAAdA;;IAKAC,sBAAsB,EAAA;eAAtBA;;;AATT,SAASH,gBAAgBI,OAAgB;IAC9C,OAAOC,MAAMC,OAAO,CAACF,WAAWA,OAAO,CAAC,EAAE,GAAGA;AAC/C;AAEO,SAASF,eAAeE,OAAe;IAC5C,sCAAsC;IACtC,OAAOA,OAAO,CAAC,EAAE,KAAK,OAAOA,QAAQG,QAAQ,CAAC;AAChD;AAEO,SAASJ,uBAAuBC,OAAe;IACpD,OAAOA,QAAQI,UAAU,CAAC,QAAQJ,YAAY;AAChD;AAEO,SAASN,6BACdM,OAAgB,EAChBK,YAA2D;IAE3D,MAAMC,gBAAgBN,QAAQO,QAAQ,CAACd;IAEvC,IAAIa,eAAe;QACjB,MAAME,mBAAmBC,KAAKC,SAAS,CAACL;QACxC,OAAOG,qBAAqB,OACxBf,mBAAmB,MAAMe,mBACzBf;IACN;IAEA,OAAOO;AACT;AAEO,SAASL,6BACdgB,QAAyB,EACzBC,gBAAwB;IAExB,IAAI,CAACD,YAAYA,SAASE,MAAM,KAAK,GAAG;QACtC,OAAO;IACT;IAEA,iFAAiF;IACjF,MAAMC,aACJF,qBAAqB,aACjBD,QAAQ,CAAC,EAAE,GACXA,QAAQ,CAACA,SAASE,MAAM,GAAG,EAAE;IAEnC,sGAAsG;IACtG,oEAAoE;IACpE,OAAOC,eAAevB,sBAAsB,OAAOuB;AACrD;AAGO,SAASjB,6BACdkB,IAAuB,EACvBH,gBAAwB,EACxBI,QAAQ,IAAI,EACZC,cAAwB,EAAE;IAE1B,IAAIC;IACJ,IAAIF,OAAO;QACT,kEAAkE;QAClEE,OAAOH,IAAI,CAAC,EAAE,CAACH,iBAAiB;IAClC,OAAO;QACL,oGAAoG;QACpG,MAAMO,iBAAiBJ,IAAI,CAAC,EAAE;QAC9BG,OAAOC,eAAeC,QAAQ,IAAIC,OAAOC,MAAM,CAACH,eAAe,CAAC,EAAE;IACpE;IAEA,IAAI,CAACD,MAAM,OAAOD;IAClB,MAAMjB,UAAUkB,IAAI,CAAC,EAAE;IAEvB,IAAIK,eAAe3B,gBAAgBI;IAEnC,IAAI,CAACuB,gBAAgBA,aAAanB,UAAU,CAACX,mBAAmB;QAC9D,OAAOwB;IACT;IAEAA,YAAYO,IAAI,CAACD;IAEjB,OAAO1B,6BACLqB,MACAN,kBACA,OACAK;AAEJ;AAEO,MAAMxB,mBAAmB;AACzB,MAAMF,sBAAsB;AAC5B,MAAMC,wBAAwB","ignoreList":[0]}},
13
- {"offset": {"line": 351, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/app-paths.ts"],"sourcesContent":["import { ensureLeadingSlash } from '../../page-path/ensure-leading-slash'\nimport { isGroupSegment } from '../../segment'\n\n/**\n * Normalizes an app route so it represents the actual request path. Essentially\n * performing the following transformations:\n *\n * - `/(dashboard)/user/[id]/page` to `/user/[id]`\n * - `/(dashboard)/account/page` to `/account`\n * - `/user/[id]/page` to `/user/[id]`\n * - `/account/page` to `/account`\n * - `/page` to `/`\n * - `/(dashboard)/user/[id]/route` to `/user/[id]`\n * - `/(dashboard)/account/route` to `/account`\n * - `/user/[id]/route` to `/user/[id]`\n * - `/account/route` to `/account`\n * - `/route` to `/`\n * - `/` to `/`\n *\n * @param route the app route to normalize\n * @returns the normalized pathname\n */\nexport function normalizeAppPath(route: string) {\n return ensureLeadingSlash(\n route.split('/').reduce((pathname, segment, index, segments) => {\n // Empty segments are ignored.\n if (!segment) {\n return pathname\n }\n\n // Groups are ignored.\n if (isGroupSegment(segment)) {\n return pathname\n }\n\n // Parallel segments are ignored.\n if (segment[0] === '@') {\n return pathname\n }\n\n // The last segment (if it's a leaf) should be ignored.\n if (\n (segment === 'page' || segment === 'route') &&\n index === segments.length - 1\n ) {\n return pathname\n }\n\n return `${pathname}/${segment}`\n }, '')\n )\n}\n\n/**\n * Comparator for sorting app paths so that parallel slot paths (containing\n * `/@`) come before the children/root page path. This ensures the last item\n * is always the children page, which is what `renderPageComponent` reads via\n * `appPaths[appPaths.length - 1]`.\n *\n * Without this, route group prefixes like `(group)` (char code 0x28) sort\n * before `@` (0x40), causing the children page to sort first instead of last\n * and leading to a manifest mismatch / 404 in webpack dev mode.\n */\nexport function compareAppPaths(a: string, b: string): number {\n const aHasSlot = a.includes('/@')\n const bHasSlot = b.includes('/@')\n if (aHasSlot && !bHasSlot) return -1\n if (!aHasSlot && bHasSlot) return 1\n return a.localeCompare(b)\n}\n\n/**\n * Strips the `.rsc` extension if it's in the pathname.\n * Since this function is used on full urls it checks `?` for searchParams handling.\n */\nexport function normalizeRscURL(url: string) {\n return url.replace(\n /\\.rsc($|\\?)/,\n // $1 ensures `?` is preserved\n '$1'\n )\n}\n"],"names":["compareAppPaths","normalizeAppPath","normalizeRscURL","route","ensureLeadingSlash","split","reduce","pathname","segment","index","segments","isGroupSegment","length","a","b","aHasSlot","includes","bHasSlot","localeCompare","url","replace"],"mappings":";;;;;;;;;;;;;;;IA+DgBA,eAAe,EAAA;eAAfA;;IAzCAC,gBAAgB,EAAA;eAAhBA;;IAqDAC,eAAe,EAAA;eAAfA;;;oCA3EmB;yBACJ;AAqBxB,SAASD,iBAAiBE,KAAa;IAC5C,OAAOC,CAAAA,GAAAA,oBAAAA,kBAAkB,EACvBD,MAAME,KAAK,CAAC,KAAKC,MAAM,CAAC,CAACC,UAAUC,SAASC,OAAOC;QACjD,8BAA8B;QAC9B,IAAI,CAACF,SAAS;YACZ,OAAOD;QACT;QAEA,sBAAsB;QACtB,IAAII,CAAAA,GAAAA,SAAAA,cAAc,EAACH,UAAU;YAC3B,OAAOD;QACT;QAEA,iCAAiC;QACjC,IAAIC,OAAO,CAAC,EAAE,KAAK,KAAK;YACtB,OAAOD;QACT;QAEA,uDAAuD;QACvD,IACGC,CAAAA,YAAY,UAAUA,YAAY,OAAM,KACzCC,UAAUC,SAASE,MAAM,GAAG,GAC5B;YACA,OAAOL;QACT;QAEA,OAAO,GAAGA,SAAS,CAAC,EAAEC,SAAS;IACjC,GAAG;AAEP;AAYO,SAASR,gBAAgBa,CAAS,EAAEC,CAAS;IAClD,MAAMC,WAAWF,EAAEG,QAAQ,CAAC;IAC5B,MAAMC,WAAWH,EAAEE,QAAQ,CAAC;IAC5B,IAAID,YAAY,CAACE,UAAU,OAAO,CAAC;IACnC,IAAI,CAACF,YAAYE,UAAU,OAAO;IAClC,OAAOJ,EAAEK,aAAa,CAACJ;AACzB;AAMO,SAASZ,gBAAgBiB,GAAW;IACzC,OAAOA,IAAIC,OAAO,CAChB,eACA,AACA,8BAD8B;AAGlC","ignoreList":[0]}},
14
- {"offset": {"line": 413, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/interception-routes.ts"],"sourcesContent":["import { normalizeAppPath } from './app-paths'\n\n// order matters here, the first match will be used\nexport const INTERCEPTION_ROUTE_MARKERS = [\n '(..)(..)',\n '(.)',\n '(..)',\n '(...)',\n] as const\n\nexport type InterceptionMarker = (typeof INTERCEPTION_ROUTE_MARKERS)[number]\n\nexport function isInterceptionRouteAppPath(path: string): boolean {\n // TODO-APP: add more serious validation\n return (\n path\n .split('/')\n .find((segment) =>\n INTERCEPTION_ROUTE_MARKERS.find((m) => segment.startsWith(m))\n ) !== undefined\n )\n}\n\ntype InterceptionRouteInformation = {\n /**\n * The intercepting route. This is the route that is being intercepted or the\n * route that the user was coming from. This is matched by the Next-Url\n * header.\n */\n interceptingRoute: string\n\n /**\n * The intercepted route. This is the route that is being intercepted or the\n * route that the user is going to. This is matched by the request pathname.\n */\n interceptedRoute: string\n}\n\nexport function extractInterceptionRouteInformation(\n path: string\n): InterceptionRouteInformation {\n let interceptingRoute: string | undefined\n let marker: (typeof INTERCEPTION_ROUTE_MARKERS)[number] | undefined\n let interceptedRoute: string | undefined\n\n for (const segment of path.split('/')) {\n marker = INTERCEPTION_ROUTE_MARKERS.find((m) => segment.startsWith(m))\n if (marker) {\n ;[interceptingRoute, interceptedRoute] = path.split(marker, 2)\n break\n }\n }\n\n if (!interceptingRoute || !marker || !interceptedRoute) {\n throw new Error(\n `Invalid interception route: ${path}. Must be in the format /<intercepting route>/(..|...|..)(..)/<intercepted route>`\n )\n }\n\n interceptingRoute = normalizeAppPath(interceptingRoute) // normalize the path, e.g. /(blog)/feed -> /feed\n\n switch (marker) {\n case '(.)':\n // (.) indicates that we should match with sibling routes, so we just need to append the intercepted route to the intercepting route\n if (interceptingRoute === '/') {\n interceptedRoute = `/${interceptedRoute}`\n } else {\n interceptedRoute = interceptingRoute + '/' + interceptedRoute\n }\n break\n case '(..)':\n // (..) indicates that we should match at one level up, so we need to remove the last segment of the intercepting route\n if (interceptingRoute === '/') {\n throw new Error(\n `Invalid interception route: ${path}. Cannot use (..) marker at the root level, use (.) instead.`\n )\n }\n interceptedRoute = interceptingRoute\n .split('/')\n .slice(0, -1)\n .concat(interceptedRoute)\n .join('/')\n break\n case '(...)':\n // (...) will match the route segment in the root directory, so we need to use the root directory to prepend the intercepted route\n interceptedRoute = '/' + interceptedRoute\n break\n case '(..)(..)':\n // (..)(..) indicates that we should match at two levels up, so we need to remove the last two segments of the intercepting route\n\n const splitInterceptingRoute = interceptingRoute.split('/')\n if (splitInterceptingRoute.length <= 2) {\n throw new Error(\n `Invalid interception route: ${path}. Cannot use (..)(..) marker at the root level or one level up.`\n )\n }\n\n interceptedRoute = splitInterceptingRoute\n .slice(0, -2)\n .concat(interceptedRoute)\n .join('/')\n break\n default:\n throw new Error('Invariant: unexpected marker')\n }\n\n return { interceptingRoute, interceptedRoute }\n}\n"],"names":["INTERCEPTION_ROUTE_MARKERS","extractInterceptionRouteInformation","isInterceptionRouteAppPath","path","split","find","segment","m","startsWith","undefined","interceptingRoute","marker","interceptedRoute","Error","normalizeAppPath","slice","concat","join","splitInterceptingRoute","length"],"mappings":";;;;;;;;;;;;;;;IAGaA,0BAA0B,EAAA;eAA1BA;;IAmCGC,mCAAmC,EAAA;eAAnCA;;IA1BAC,0BAA0B,EAAA;eAA1BA;;;0BAZiB;AAG1B,MAAMF,6BAA6B;IACxC;IACA;IACA;IACA;CACD;AAIM,SAASE,2BAA2BC,IAAY;IACrD,wCAAwC;IACxC,OACEA,KACGC,KAAK,CAAC,KACNC,IAAI,CAAC,CAACC,UACLN,2BAA2BK,IAAI,CAAC,CAACE,IAAMD,QAAQE,UAAU,CAACD,SACtDE;AAEZ;AAiBO,SAASR,oCACdE,IAAY;IAEZ,IAAIO;IACJ,IAAIC;IAC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;gBAEN;YACF;YAEAS,mBAAmBM,uBAChBH,KAAK,CAAC,GAAG,CAAC,GACVC,MAAM,CAACJ,kBACPK,IAAI,CAAC;YACR;QACF;YACE,MAAM,OAAA,cAAyC,CAAzC,IAAIJ,MAAM,iCAAV,qBAAA;uBAAA;4BAAA;8BAAA;YAAwC;IAClD;IAEA,OAAO;QAAEH;QAAmBE;IAAiB;AAC/C","ignoreList":[0]}},
15
- {"offset": {"line": 522, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/is-dynamic.ts"],"sourcesContent":["import {\n extractInterceptionRouteInformation,\n isInterceptionRouteAppPath,\n} from './interception-routes'\n\n// Identify /.*[param].*/ in route string\nconst TEST_ROUTE = /\\/[^/]*\\[[^/]+\\][^/]*(?=\\/|$)/\n\n// Identify /[param]/ in route string\nconst TEST_STRICT_ROUTE = /\\/\\[[^/]+\\](?=\\/|$)/\n\n/**\n * Check if a route is dynamic.\n *\n * @param route - The route to check.\n * @param strict - Whether to use strict mode which prohibits segments with prefixes/suffixes (default: true).\n * @returns Whether the route is dynamic.\n */\nexport function isDynamicRoute(route: string, strict: boolean = true): boolean {\n if (isInterceptionRouteAppPath(route)) {\n route = extractInterceptionRouteInformation(route).interceptedRoute\n }\n\n if (strict) {\n return TEST_STRICT_ROUTE.test(route)\n }\n\n return TEST_ROUTE.test(route)\n}\n"],"names":["isDynamicRoute","TEST_ROUTE","TEST_STRICT_ROUTE","route","strict","isInterceptionRouteAppPath","extractInterceptionRouteInformation","interceptedRoute","test"],"mappings":";;;+BAkBgBA,kBAAAA;;;eAAAA;;;oCAfT;AAEP,yCAAyC;AACzC,MAAMC,aAAa;AAEnB,qCAAqC;AACrC,MAAMC,oBAAoB;AASnB,SAASF,eAAeG,KAAa,EAAEC,SAAkB,IAAI;IAClE,IAAIC,CAAAA,GAAAA,oBAAAA,0BAA0B,EAACF,QAAQ;QACrCA,QAAQG,CAAAA,GAAAA,oBAAAA,mCAAmC,EAACH,OAAOI,gBAAgB;IACrE;IAEA,IAAIH,QAAQ;QACV,OAAOF,kBAAkBM,IAAI,CAACL;IAChC;IAEA,OAAOF,WAAWO,IAAI,CAACL;AACzB","ignoreList":[0]}},
16
- {"offset": {"line": 549, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/querystring.ts"],"sourcesContent":["import type { ParsedUrlQuery } from 'querystring'\n\nexport function searchParamsToUrlQuery(\n searchParams: URLSearchParams\n): ParsedUrlQuery {\n const query: ParsedUrlQuery = {}\n for (const [key, value] of searchParams.entries()) {\n const existing = query[key]\n if (typeof existing === 'undefined') {\n query[key] = value\n } else if (Array.isArray(existing)) {\n existing.push(value)\n } else {\n query[key] = [existing, value]\n }\n }\n return query\n}\n\nfunction stringifyUrlQueryParam(param: unknown): string {\n if (typeof param === 'string') {\n return param\n }\n\n if (\n (typeof param === 'number' && !isNaN(param)) ||\n typeof param === 'boolean'\n ) {\n return String(param)\n } else {\n return ''\n }\n}\n\nexport function urlQueryToSearchParams(query: ParsedUrlQuery): URLSearchParams {\n const searchParams = new URLSearchParams()\n for (const [key, value] of Object.entries(query)) {\n if (Array.isArray(value)) {\n for (const item of value) {\n searchParams.append(key, stringifyUrlQueryParam(item))\n }\n } else {\n searchParams.set(key, stringifyUrlQueryParam(value))\n }\n }\n return searchParams\n}\n\nexport function assign(\n target: URLSearchParams,\n ...searchParamsList: URLSearchParams[]\n): URLSearchParams {\n for (const searchParams of searchParamsList) {\n for (const key of searchParams.keys()) {\n target.delete(key)\n }\n\n for (const [key, value] of searchParams.entries()) {\n target.append(key, value)\n }\n }\n\n return target\n}\n"],"names":["assign","searchParamsToUrlQuery","urlQueryToSearchParams","searchParams","query","key","value","entries","existing","Array","isArray","push","stringifyUrlQueryParam","param","isNaN","String","URLSearchParams","Object","item","append","set","target","searchParamsList","keys","delete"],"mappings":";;;;;;;;;;;;;;;IAgDgBA,MAAM,EAAA;eAANA;;IA9CAC,sBAAsB,EAAA;eAAtBA;;IAgCAC,sBAAsB,EAAA;eAAtBA;;;AAhCT,SAASD,uBACdE,YAA6B;IAE7B,MAAMC,QAAwB,CAAC;IAC/B,KAAK,MAAM,CAACC,KAAKC,MAAM,IAAIH,aAAaI,OAAO,GAAI;QACjD,MAAMC,WAAWJ,KAAK,CAACC,IAAI;QAC3B,IAAI,OAAOG,aAAa,aAAa;YACnCJ,KAAK,CAACC,IAAI,GAAGC;QACf,OAAO,IAAIG,MAAMC,OAAO,CAACF,WAAW;YAClCA,SAASG,IAAI,CAACL;QAChB,OAAO;YACLF,KAAK,CAACC,IAAI,GAAG;gBAACG;gBAAUF;aAAM;QAChC;IACF;IACA,OAAOF;AACT;AAEA,SAASQ,uBAAuBC,KAAc;IAC5C,IAAI,OAAOA,UAAU,UAAU;QAC7B,OAAOA;IACT;IAEA,IACG,OAAOA,UAAU,YAAY,CAACC,MAAMD,UACrC,OAAOA,UAAU,WACjB;QACA,OAAOE,OAAOF;IAChB,OAAO;QACL,OAAO;IACT;AACF;AAEO,SAASX,uBAAuBE,KAAqB;IAC1D,MAAMD,eAAe,IAAIa;IACzB,KAAK,MAAM,CAACX,KAAKC,MAAM,IAAIW,OAAOV,OAAO,CAACH,OAAQ;QAChD,IAAIK,MAAMC,OAAO,CAACJ,QAAQ;YACxB,KAAK,MAAMY,QAAQZ,MAAO;gBACxBH,aAAagB,MAAM,CAACd,KAAKO,uBAAuBM;YAClD;QACF,OAAO;YACLf,aAAaiB,GAAG,CAACf,KAAKO,uBAAuBN;QAC/C;IACF;IACA,OAAOH;AACT;AAEO,SAASH,OACdqB,MAAuB,EACvB,GAAGC,gBAAmC;IAEtC,KAAK,MAAMnB,gBAAgBmB,iBAAkB;QAC3C,KAAK,MAAMjB,OAAOF,aAAaoB,IAAI,GAAI;YACrCF,OAAOG,MAAM,CAACnB;QAChB;QAEA,KAAK,MAAM,CAACA,KAAKC,MAAM,IAAIH,aAAaI,OAAO,GAAI;YACjDc,OAAOF,MAAM,CAACd,KAAKC;QACrB;IACF;IAEA,OAAOe;AACT","ignoreList":[0]}},
17
- {"offset": {"line": 629, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/utils.ts"],"sourcesContent":["import type { HtmlProps } from './html-context.shared-runtime'\nimport type { ComponentType, JSX } from 'react'\nimport type { DomainLocale } from '../../server/config'\nimport type { Env } from '@next/env'\nimport type { IncomingMessage, ServerResponse } from 'http'\nimport type { NextRouter } from './router/router'\nimport type { ParsedUrlQuery } from 'querystring'\nimport type { PreviewData } from '../../types'\nimport type { COMPILER_NAMES } from './constants'\nimport type fs from 'fs'\n\nexport type NextComponentType<\n Context extends BaseContext = NextPageContext,\n InitialProps = {},\n Props = {},\n> = ComponentType<Props> & {\n /**\n * Used for initial page load data population. Data returned from `getInitialProps` is serialized when server rendered.\n * Make sure to return plain `Object` without using `Date`, `Map`, `Set`.\n * @param context Context of `page`\n */\n getInitialProps?(context: Context): InitialProps | Promise<InitialProps>\n}\n\nexport type DocumentType = NextComponentType<\n DocumentContext,\n DocumentInitialProps,\n DocumentProps\n>\n\nexport type AppType<P = {}> = NextComponentType<\n AppContextType,\n P,\n AppPropsType<any, P>\n>\n\nexport type AppTreeType = ComponentType<\n AppInitialProps & { [name: string]: any }\n>\n\n/**\n * Web vitals provided to _app.reportWebVitals by Core Web Vitals plugin developed by Google Chrome team.\n * https://nextjs.org/blog/next-9-4#integrated-web-vitals-reporting\n */\nexport const WEB_VITALS = ['CLS', 'FCP', 'FID', 'INP', 'LCP', 'TTFB'] as const\nexport type NextWebVitalsMetric = {\n id: string\n startTime: number\n value: number\n attribution?: { [key: string]: unknown }\n} & (\n | {\n label: 'web-vital'\n name: (typeof WEB_VITALS)[number]\n }\n | {\n label: 'custom'\n name:\n | 'Next.js-hydration'\n | 'Next.js-route-change-to-render'\n | 'Next.js-render'\n }\n)\n\nexport type Enhancer<C> = (Component: C) => C\n\nexport type ComponentsEnhancer =\n | {\n enhanceApp?: Enhancer<AppType>\n enhanceComponent?: Enhancer<NextComponentType>\n }\n | Enhancer<NextComponentType>\n\nexport type RenderPageResult = {\n html: string\n head?: Array<JSX.Element | null>\n}\n\nexport type RenderPage = (\n options?: ComponentsEnhancer\n) => DocumentInitialProps | Promise<DocumentInitialProps>\n\nexport type BaseContext = {\n res?: ServerResponse\n [k: string]: any\n}\n\nexport type NEXT_DATA = {\n props: Record<string, any>\n page: string\n query: ParsedUrlQuery\n buildId: string\n assetPrefix?: string\n nextExport?: boolean\n autoExport?: boolean\n isFallback?: boolean\n isExperimentalCompile?: boolean\n dynamicIds?: (string | number)[]\n err?: Error & {\n statusCode?: number\n source?: typeof COMPILER_NAMES.server | typeof COMPILER_NAMES.edgeServer\n }\n gsp?: boolean\n gssp?: boolean\n customServer?: boolean\n gip?: boolean\n appGip?: boolean\n locale?: string\n locales?: readonly string[]\n defaultLocale?: string\n domainLocales?: readonly DomainLocale[]\n scriptLoader?: any[]\n isPreview?: boolean\n notFoundSrcPage?: string\n}\n\n/**\n * `Next` context\n */\nexport interface NextPageContext {\n /**\n * Error object if encountered during rendering\n */\n err?: (Error & { statusCode?: number }) | null\n /**\n * `HTTP` request object.\n */\n req?: IncomingMessage\n /**\n * `HTTP` response object.\n */\n res?: ServerResponse\n /**\n * Path section of `URL`.\n */\n pathname: string\n /**\n * Query string section of `URL` parsed as an object.\n */\n query: ParsedUrlQuery\n /**\n * `String` of the actual path including query.\n */\n asPath?: string\n /**\n * The currently active locale\n */\n locale?: string\n /**\n * All configured locales\n */\n locales?: readonly string[]\n /**\n * The configured default locale\n */\n defaultLocale?: string\n /**\n * `Component` the tree of the App to use if needing to render separately\n */\n AppTree: AppTreeType\n}\n\nexport type AppContextType<Router extends NextRouter = NextRouter> = {\n Component: NextComponentType<NextPageContext>\n AppTree: AppTreeType\n ctx: NextPageContext\n router: Router\n}\n\nexport type AppInitialProps<PageProps = any> = {\n pageProps: PageProps\n}\n\nexport type AppPropsType<\n Router extends NextRouter = NextRouter,\n PageProps = {},\n> = AppInitialProps<PageProps> & {\n Component: NextComponentType<NextPageContext, any, any>\n router: Router\n __N_SSG?: boolean\n __N_SSP?: boolean\n}\n\nexport type DocumentContext = NextPageContext & {\n renderPage: RenderPage\n defaultGetInitialProps(\n ctx: DocumentContext,\n options?: { nonce?: string }\n ): Promise<DocumentInitialProps>\n}\n\nexport type DocumentInitialProps = RenderPageResult & {\n styles?: React.ReactElement[] | Iterable<React.ReactNode> | JSX.Element\n}\n\nexport type DocumentProps = DocumentInitialProps & HtmlProps\n\n/**\n * Next `API` route request\n */\nexport interface NextApiRequest extends IncomingMessage {\n /**\n * Object of `query` values from url\n */\n query: Partial<{\n [key: string]: string | string[]\n }>\n /**\n * Object of `cookies` from header\n */\n cookies: Partial<{\n [key: string]: string\n }>\n\n body: any\n\n env: Env\n\n draftMode?: boolean\n\n preview?: boolean\n /**\n * Preview data set on the request, if any\n * */\n previewData?: PreviewData\n}\n\n/**\n * Send body of response\n */\ntype Send<T> = (body: T) => void\n\n/**\n * Next `API` route response\n */\nexport type NextApiResponse<Data = any> = ServerResponse & {\n /**\n * Send data `any` data in response\n */\n send: Send<Data>\n /**\n * Send data `json` data in response\n */\n json: Send<Data>\n status: (statusCode: number) => NextApiResponse<Data>\n redirect(url: string): NextApiResponse<Data>\n redirect(status: number, url: string): NextApiResponse<Data>\n\n /**\n * Set draft mode\n */\n setDraftMode: (options: { enable: boolean }) => NextApiResponse<Data>\n\n /**\n * Set preview data for Next.js' prerender mode\n */\n setPreviewData: (\n data: object | string,\n options?: {\n /**\n * Specifies the number (in seconds) for the preview session to last for.\n * The given number will be converted to an integer by rounding down.\n * By default, no maximum age is set and the preview session finishes\n * when the client shuts down (browser is closed).\n */\n maxAge?: number\n /**\n * Specifies the path for the preview session to work under. By default,\n * the path is considered the \"default path\", i.e., any pages under \"/\".\n */\n path?: string\n }\n ) => NextApiResponse<Data>\n\n /**\n * Clear preview data for Next.js' prerender mode\n */\n clearPreviewData: (options?: { path?: string }) => NextApiResponse<Data>\n\n /**\n * Revalidate a specific page and regenerate it using On-Demand Incremental\n * Static Regeneration.\n * The path should be an actual path, not a rewritten path. E.g. for\n * \"/blog/[slug]\" this should be \"/blog/post-1\".\n * @link https://nextjs.org/docs/app/building-your-application/data-fetching/incremental-static-regeneration#on-demand-revalidation-with-revalidatepath\n */\n revalidate: (\n urlPath: string,\n opts?: {\n unstable_onlyGenerated?: boolean\n }\n ) => Promise<void>\n}\n\n/**\n * Next `API` route handler\n */\nexport type NextApiHandler<T = any> = (\n req: NextApiRequest,\n res: NextApiResponse<T>\n) => unknown | Promise<unknown>\n\n/**\n * Utils\n */\nexport function execOnce<T extends (...args: any[]) => ReturnType<T>>(\n fn: T\n): T {\n let used = false\n let result: ReturnType<T>\n\n return ((...args: any[]) => {\n if (!used) {\n used = true\n result = fn(...args)\n }\n return result\n }) as T\n}\n\n// Scheme: https://tools.ietf.org/html/rfc3986#section-3.1\n// Absolute URL: https://tools.ietf.org/html/rfc3986#section-4.3\nconst ABSOLUTE_URL_REGEX = /^[a-zA-Z][a-zA-Z\\d+\\-.]*?:/\nexport const isAbsoluteUrl = (url: string) => ABSOLUTE_URL_REGEX.test(url)\n\nexport function getLocationOrigin() {\n const { protocol, hostname, port } = window.location\n return `${protocol}//${hostname}${port ? ':' + port : ''}`\n}\n\nexport function getURL() {\n const { href } = window.location\n const origin = getLocationOrigin()\n return href.substring(origin.length)\n}\n\nexport function getDisplayName<P>(Component: ComponentType<P>) {\n return typeof Component === 'string'\n ? Component\n : Component.displayName || Component.name || 'Unknown'\n}\n\nexport function isResSent(res: ServerResponse) {\n return res.finished || res.headersSent\n}\n\nexport function normalizeRepeatedSlashes(url: string) {\n const urlParts = url.split('?')\n const urlNoQuery = urlParts[0]\n\n return (\n urlNoQuery\n // first we replace any non-encoded backslashes with forward\n // then normalize repeated forward slashes\n .replace(/\\\\/g, '/')\n .replace(/\\/\\/+/g, '/') +\n (urlParts[1] ? `?${urlParts.slice(1).join('?')}` : '')\n )\n}\n\nexport async function loadGetInitialProps<\n C extends BaseContext,\n IP = {},\n P = {},\n>(App: NextComponentType<C, IP, P>, ctx: C): Promise<IP> {\n if (process.env.NODE_ENV !== 'production') {\n if (App.prototype?.getInitialProps) {\n const message = `\"${getDisplayName(\n App\n )}.getInitialProps()\" is defined as an instance method - visit https://nextjs.org/docs/messages/get-initial-props-as-an-instance-method for more information.`\n throw new Error(message)\n }\n }\n // when called from _app `ctx` is nested in `ctx`\n const res = ctx.res || (ctx.ctx && ctx.ctx.res)\n\n if (!App.getInitialProps) {\n if (ctx.ctx && ctx.Component) {\n // @ts-ignore pageProps default\n return {\n pageProps: await loadGetInitialProps(ctx.Component, ctx.ctx),\n }\n }\n return {} as IP\n }\n\n const props = await App.getInitialProps(ctx)\n\n if (res && isResSent(res)) {\n return props\n }\n\n if (!props) {\n const message = `\"${getDisplayName(\n App\n )}.getInitialProps()\" should resolve to an object. But found \"${props}\" instead.`\n throw new Error(message)\n }\n\n if (process.env.NODE_ENV !== 'production') {\n if (Object.keys(props).length === 0 && !ctx.ctx) {\n console.warn(\n `${getDisplayName(\n App\n )} returned an empty object from \\`getInitialProps\\`. This de-optimizes and prevents automatic static optimization. https://nextjs.org/docs/messages/empty-object-getInitialProps`\n )\n }\n }\n\n return props\n}\n\nexport const SP = typeof performance !== 'undefined'\nexport const ST =\n SP &&\n (['mark', 'measure', 'getEntriesByName'] as const).every(\n (method) => typeof performance[method] === 'function'\n )\n\nexport class DecodeError extends Error {}\nexport class NormalizeError extends Error {}\nexport class PageNotFoundError extends Error {\n code: string\n\n constructor(page: string) {\n super()\n this.code = 'ENOENT'\n this.name = 'PageNotFoundError'\n this.message = `Cannot find module for page: ${page}`\n }\n}\n\nexport class MissingStaticPage extends Error {\n constructor(page: string, message: string) {\n super()\n this.message = `Failed to load static file for page: ${page} ${message}`\n }\n}\n\nexport class MiddlewareNotFoundError extends Error {\n code: string\n constructor() {\n super()\n this.code = 'ENOENT'\n this.message = `Cannot find the middleware module`\n }\n}\n\nexport interface CacheFs {\n existsSync: typeof fs.existsSync\n readFile: typeof fs.promises.readFile\n readFileSync: typeof fs.readFileSync\n writeFile(f: string, d: any): Promise<void>\n mkdir(dir: string): Promise<void | string>\n stat(f: string): Promise<{ mtime: Date }>\n}\n\nexport function stringifyError(error: Error) {\n return JSON.stringify({ message: error.message, stack: error.stack })\n}\n"],"names":["DecodeError","MiddlewareNotFoundError","MissingStaticPage","NormalizeError","PageNotFoundError","SP","ST","WEB_VITALS","execOnce","getDisplayName","getLocationOrigin","getURL","isAbsoluteUrl","isResSent","loadGetInitialProps","normalizeRepeatedSlashes","stringifyError","fn","used","result","args","ABSOLUTE_URL_REGEX","url","test","protocol","hostname","port","window","location","href","origin","substring","length","Component","displayName","name","res","finished","headersSent","urlParts","split","urlNoQuery","replace","slice","join","App","ctx","process","env","NODE_ENV","prototype","getInitialProps","message","Error","pageProps","props","Object","keys","console","warn","performance","every","method","constructor","page","code","error","JSON","stringify","stack"],"mappings":"AA6WM+C,QAAQC,GAAG,CAACC,QAAQ,KAAK;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAsDlBjD,WAAW,EAAA;eAAXA;;IAoBAC,uBAAuB,EAAA;eAAvBA;;IAPAC,iBAAiB,EAAA;eAAjBA;;IAZAC,cAAc,EAAA;eAAdA;;IACAC,iBAAiB,EAAA;eAAjBA;;IATAC,EAAE,EAAA;eAAFA;;IACAC,EAAE,EAAA;eAAFA;;IAjXAC,UAAU,EAAA;eAAVA;;IAqQGC,QAAQ,EAAA;eAARA;;IA+BAC,cAAc,EAAA;eAAdA;;IA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A+K,CAAC;QAEtL;IACF;IAEA,OAAOU;AACT;AAEO,MAAMlD,KAAK,OAAOuD,gBAAgB;AAClC,MAAMtD,KACXD,MACC;IAAC;IAAQ;IAAW;CAAmB,CAAWwD,KAAK,CACtD,CAACC,SAAW,OAAOF,WAAW,CAACE,OAAO,KAAK;AAGxC,MAAM9D,oBAAoBqD;AAAO;AACjC,MAAMlD,uBAAuBkD;AAAO;AACpC,MAAMjD,0BAA0BiD;IAGrCU,YAAYC,IAAY,CAAE;QACxB,KAAK;QACL,IAAI,CAACC,IAAI,GAAG;QACZ,IAAI,CAAC9B,IAAI,GAAG;QACZ,IAAI,CAACiB,OAAO,GAAG,CAAC,6BAA6B,EAAEY,MAAM;IACvD;AACF;AAEO,MAAM9D,0BAA0BmD;IACrCU,YAAYC,IAAY,EAAEZ,OAAe,CAAE;QACzC,KAAK;QACL,IAAI,CAACA,OAAO,GAAG,CAAC,qCAAqC,EAAEY,KAAK,CAAC,EAAEZ,SAAS;IAC1E;AACF;AAEO,MAAMnD,gCAAgCoD;IAE3CU,aAAc;QACZ,KAAK;QACL,IAAI,CAACE,IAAI,GAAG;QACZ,IAAI,CAACb,OAAO,GAAG,CAAC,iCAAiC,CAAC;IACpD;AACF;AAWO,SAASpC,eAAekD,KAAY;IACzC,OAAOC,KAAKC,SAAS,CAAC;QAAEhB,SAASc,MAAMd,OAAO;QAAEiB,OAAOH,MAAMG,KAAK;IAAC;AACrE","ignoreList":[0]}},
18
- {"offset": {"line": 839, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/parse-path.ts"],"sourcesContent":["/**\n * Given a path this function will find the pathname, query and hash and return\n * them. This is useful to parse full paths on the client side.\n * @param path A path to parse e.g. /foo/bar?id=1#hash\n */\nexport function parsePath(path: string) {\n const hashIndex = path.indexOf('#')\n const queryIndex = path.indexOf('?')\n const hasQuery = queryIndex > -1 && (hashIndex < 0 || queryIndex < hashIndex)\n\n if (hasQuery || hashIndex > -1) {\n return {\n pathname: path.substring(0, hasQuery ? queryIndex : hashIndex),\n query: hasQuery\n ? path.substring(queryIndex, hashIndex > -1 ? hashIndex : undefined)\n : '',\n hash: hashIndex > -1 ? path.slice(hashIndex) : '',\n }\n }\n\n return { pathname: path, query: '', hash: '' }\n}\n"],"names":["parsePath","path","hashIndex","indexOf","queryIndex","hasQuery","pathname","substring","query","undefined","hash","slice"],"mappings":"AAAA;;;;CAIC;;;+BACeA,aAAAA;;;eAAAA;;;AAAT,SAASA,UAAUC,IAAY;IACpC,MAAMC,YAAYD,KAAKE,OAAO,CAAC;IAC/B,MAAMC,aAAaH,KAAKE,OAAO,CAAC;IAChC,MAAME,WAAWD,aAAa,CAAC,KAAMF,CAAAA,YAAY,KAAKE,aAAaF,SAAQ;IAE3E,IAAIG,YAAYH,YAAY,CAAC,GAAG;QAC9B,OAAO;YACLI,UAAUL,KAAKM,SAAS,CAAC,GAAGF,WAAWD,aAAaF;YACpDM,OAAOH,WACHJ,KAAKM,SAAS,CAACH,YAAYF,YAAY,CAAC,IAAIA,YAAYO,aACxD;YACJC,MAAMR,YAAY,CAAC,IAAID,KAAKU,KAAK,CAACT,aAAa;QACjD;IACF;IAEA,OAAO;QAAEI,UAAUL;QAAMO,OAAO;QAAIE,MAAM;IAAG;AAC/C","ignoreList":[0]}},
19
- {"offset": {"line": 873, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/add-path-prefix.ts"],"sourcesContent":["import { parsePath } from './parse-path'\n\n/**\n * Adds the provided prefix to the given path. It first ensures that the path\n * is indeed starting with a slash.\n */\nexport function addPathPrefix(path: string, prefix?: string) {\n if (!path.startsWith('/') || !prefix) {\n return path\n }\n\n const { pathname, query, hash } = parsePath(path)\n return `${prefix}${pathname}${query}${hash}`\n}\n"],"names":["addPathPrefix","path","prefix","startsWith","pathname","query","hash","parsePath"],"mappings":";;;+BAMgBA,iBAAAA;;;eAAAA;;;2BANU;AAMnB,SAASA,cAAcC,IAAY,EAAEC,MAAe;IACzD,IAAI,CAACD,KAAKE,UAAU,CAAC,QAAQ,CAACD,QAAQ;QACpC,OAAOD;IACT;IAEA,MAAM,EAAEG,QAAQ,EAAEC,KAAK,EAAEC,IAAI,EAAE,GAAGC,CAAAA,GAAAA,WAAAA,SAAS,EAACN;IAC5C,OAAO,GAAGC,SAASE,WAAWC,QAAQC,MAAM;AAC9C","ignoreList":[0]}},
20
- {"offset": {"line": 894, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/remove-trailing-slash.ts"],"sourcesContent":["/**\n * Removes the trailing slash for a given route or page path. Preserves the\n * root page. Examples:\n * - `/foo/bar/` -> `/foo/bar`\n * - `/foo/bar` -> `/foo/bar`\n * - `/` -> `/`\n */\nexport function removeTrailingSlash(route: string) {\n return route.replace(/\\/$/, '') || '/'\n}\n"],"names":["removeTrailingSlash","route","replace"],"mappings":"AAAA;;;;;;CAMC;;;+BACeA,uBAAAA;;;eAAAA;;;AAAT,SAASA,oBAAoBC,KAAa;IAC/C,OAAOA,MAAMC,OAAO,CAAC,OAAO,OAAO;AACrC","ignoreList":[0]}},
21
- {"offset": {"line": 916, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/route-match-utils.ts"],"sourcesContent":["/**\n * Client-safe utilities for route matching that don't import server-side\n * utilities to avoid bundling issues with Turbopack\n */\n\nimport type {\n Key,\n TokensToRegexpOptions,\n ParseOptions,\n TokensToFunctionOptions,\n} from 'next/dist/compiled/path-to-regexp'\nimport {\n pathToRegexp,\n compile,\n regexpToFunction,\n} from 'next/dist/compiled/path-to-regexp'\nimport {\n hasAdjacentParameterIssues,\n normalizeAdjacentParameters,\n stripParameterSeparators,\n stripNormalizedSeparators,\n} from '../../../../lib/route-pattern-normalizer'\n\n/**\n * Client-safe wrapper around pathToRegexp that handles path-to-regexp 6.3.0+ validation errors.\n * This includes both \"Can not repeat without prefix/suffix\" and \"Must have text between parameters\" errors.\n */\nexport function safePathToRegexp(\n route: string | RegExp | Array<string | RegExp>,\n keys?: Key[],\n options?: TokensToRegexpOptions & ParseOptions\n): RegExp {\n if (typeof route !== 'string') {\n return pathToRegexp(route, keys, options)\n }\n\n // Check if normalization is needed and cache the result\n const needsNormalization = hasAdjacentParameterIssues(route)\n const routeToUse = needsNormalization\n ? normalizeAdjacentParameters(route)\n : route\n\n try {\n return pathToRegexp(routeToUse, keys, options)\n } catch (error) {\n // Only try normalization if we haven't already normalized\n if (!needsNormalization) {\n try {\n const normalizedRoute = normalizeAdjacentParameters(route)\n return pathToRegexp(normalizedRoute, keys, options)\n } catch (retryError) {\n // If that doesn't work, fall back to original error\n throw error\n }\n }\n throw error\n }\n}\n\n/**\n * Client-safe wrapper around compile that handles path-to-regexp 6.3.0+ validation errors.\n * No server-side error reporting to avoid bundling issues.\n * When normalization is applied, the returned compiler function automatically strips\n * the internal separator from the output URL.\n */\nexport function safeCompile(\n route: string,\n options?: TokensToFunctionOptions & ParseOptions\n) {\n // Check if normalization is needed and cache the result\n const needsNormalization = hasAdjacentParameterIssues(route)\n const routeToUse = needsNormalization\n ? normalizeAdjacentParameters(route)\n : route\n\n try {\n const compiler = compile(routeToUse, options)\n\n // If we normalized the route, wrap the compiler to strip separators from output\n // The normalization inserts _NEXTSEP_ as a literal string in the pattern to satisfy\n // path-to-regexp validation, but we don't want it in the final compiled URL\n if (needsNormalization) {\n return (params: any) => {\n return stripNormalizedSeparators(compiler(params))\n }\n }\n\n return compiler\n } catch (error) {\n // Only try normalization if we haven't already normalized\n if (!needsNormalization) {\n try {\n const normalizedRoute = normalizeAdjacentParameters(route)\n const compiler = compile(normalizedRoute, options)\n\n // Wrap the compiler to strip separators from output\n return (params: any) => {\n return stripNormalizedSeparators(compiler(params))\n }\n } catch (retryError) {\n // If that doesn't work, fall back to original error\n throw error\n }\n }\n throw error\n }\n}\n\n/**\n * Client-safe wrapper around regexpToFunction that automatically cleans parameters.\n */\nexport function safeRegexpToFunction<\n T extends Record<string, any> = Record<string, any>,\n>(regexp: RegExp, keys?: Key[]): (pathname: string) => { params: T } | false {\n const originalMatcher = regexpToFunction<T>(regexp, keys || [])\n\n return (pathname: string) => {\n const result = originalMatcher(pathname)\n if (!result) return false\n\n // Clean parameters before returning\n return {\n ...result,\n params: stripParameterSeparators(result.params as any) as T,\n }\n }\n}\n\n/**\n * Safe wrapper for route matcher functions that automatically cleans parameters.\n * This is client-safe and doesn't import path-to-regexp.\n */\nexport function safeRouteMatcher<T extends Record<string, any>>(\n matcherFn: (pathname: string) => false | T\n): (pathname: string) => false | T {\n return (pathname: string) => {\n const result = matcherFn(pathname)\n if (!result) return false\n\n // Clean parameters before returning\n return stripParameterSeparators(result) as T\n }\n}\n"],"names":["safeCompile","safePathToRegexp","safeRegexpToFunction","safeRouteMatcher","route","keys","options","pathToRegexp","needsNormalization","hasAdjacentParameterIssues","routeToUse","normalizeAdjacentParameters","error","normalizedRoute","retryError","compiler","compile","params","stripNormalizedSeparators","regexp","originalMatcher","regexpToFunction","pathname","result","stripParameterSeparators","matcherFn"],"mappings":"AAAA;;;CAGC;;;;;;;;;;;;;;;;IA8DeA,WAAW,EAAA;eAAXA;;IAtCAC,gBAAgB,EAAA;eAAhBA;;IAoFAC,oBAAoB,EAAA;eAApBA;;IAqBAC,gBAAgB,EAAA;eAAhBA;;;8BArHT;wCAMA;AAMA,SAASF,iBACd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WAAWC,CAAAA,GAAAA,cAAAA,OAAO,EAACH,iBAAiBP;gBAE1C,oDAAoD;gBACpD,OAAO,CAACW;oBACN,OAAOC,CAAAA,GAAAA,wBAAAA,yBAAyB,EAACH,SAASE;gBAC5C;YACF,EAAE,OAAOH,YAAY;gBACnB,oDAAoD;gBACpD,MAAMF;YACR;QACF;QACA,MAAMA;IACR;AACF;AAKO,SAASV,qBAEdiB,MAAc,EAAEd,IAAY;IAC5B,MAAMe,kBAAkBC,CAAAA,GAAAA,cAAAA,gBAAgB,EAAIF,QAAQd,QAAQ,EAAE;IAE9D,OAAO,CAACiB;QACN,MAAMC,SAASH,gBAAgBE;QAC/B,IAAI,CAACC,QAAQ,OAAO;QAEpB,oCAAoC;QACpC,OAAO;YACL,GAAGA,MAAM;YACTN,QAAQO,CAAAA,GAAAA,wBAAAA,wBAAwB,EAACD,OAAON,MAAM;QAChD;IACF;AACF;AAMO,SAASd,iBACdsB,SAA0C;IAE1C,OAAO,CAACH;QACN,MAAMC,SAASE,UAAUH;QACzB,IAAI,CAACC,QAAQ,OAAO;QAEpB,oCAAoC;QACpC,OAAOC,CAAAA,GAAAA,wBAAAA,wBAAwB,EAACD;IAClC;AACF","ignoreList":[0]}},
22
- {"offset": {"line": 1030, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/route-matcher.ts"],"sourcesContent":["import type { Group } from './route-regex'\nimport { DecodeError } from '../../utils'\nimport type { Params } from '../../../../server/request/params'\nimport { safeRouteMatcher } from './route-match-utils'\n\nexport interface RouteMatchFn {\n (pathname: string): false | Params\n}\n\ntype RouteMatcherOptions = {\n // We only use the exec method of the RegExp object. This helps us avoid using\n // type assertions that the passed in properties are of the correct type.\n re: Pick<RegExp, 'exec'>\n groups: Record<string, Group>\n}\n\nexport function getRouteMatcher({\n re,\n groups,\n}: RouteMatcherOptions): RouteMatchFn {\n const rawMatcher = (pathname: string) => {\n const routeMatch = re.exec(pathname)\n if (!routeMatch) return false\n\n const decode = (param: string) => {\n try {\n return decodeURIComponent(param)\n } catch {\n throw new DecodeError('failed to decode param')\n }\n }\n\n const params: Params = {}\n for (const [key, group] of Object.entries(groups)) {\n const match = routeMatch[group.pos]\n if (match !== undefined) {\n if (group.repeat) {\n params[key] = match.split('/').map((entry) => decode(entry))\n } else {\n params[key] = decode(match)\n }\n }\n }\n\n return params\n }\n\n // Wrap with safe matcher to handle parameter cleaning\n return safeRouteMatcher(rawMatcher)\n}\n"],"names":["getRouteMatcher","re","groups","rawMatcher","pathname","routeMatch","exec","decode","param","decodeURIComponent","DecodeError","params","key","group","Object","entries","match","pos","undefined","repeat","split","map","entry","safeRouteMatcher"],"mappings":";;;+BAgBgBA,mBAAAA;;;eAAAA;;;uBAfY;iCAEK;AAa1B,SAASA,gBAAgB,EAC9BC,EAAE,EACFC,MAAM,EACc;IACpB,MAAMC,aAAa,CAACC;QAClB,MAAMC,aAAaJ,GAAGK,IAAI,CAACF;QAC3B,IAAI,CAACC,YAAY,OAAO;QAExB,MAAME,SAAS,CAACC;YACd,IAAI;gBACF,OAAOC,mBAAmBD;YAC5B,EAAE,OAAM;gBACN,MAAM,OAAA,cAAyC,CAAzC,IAAIE,OAAAA,WAAW,CAAC,2BAAhB,qBAAA;2BAAA;gCAAA;kCAAA;gBAAwC;YAChD;QACF;QAEA,MAAMC,SAAiB,CAAC;QACxB,KAAK,MAAM,CAACC,KAAKC,MAAM,IAAIC,OAAOC,OAAO,CAACb,QAAS;YACjD,MAAMc,QAAQX,UAAU,CAACQ,MAAMI,GAAG,CAAC;YACnC,IAAID,UAAUE,WAAW;gBACvB,IAAIL,MAAMM,MAAM,EAAE;oBAChBR,MAAM,CAACC,IAAI,GAAGI,MAAMI,KAAK,CAAC,KAAKC,GAAG,CAAC,CAACC,QAAUf,OAAOe;gBACvD,OAAO;oBACLX,MAAM,CAACC,IAAI,GAAGL,OAAOS;gBACvB;YACF;QACF;QAEA,OAAOL;IACT;IAEA,sDAAsD;IACtD,OAAOY,CAAAA,GAAAA,iBAAAA,gBAAgB,EAACpB;AAC1B","ignoreList":[0]}},
23
- {"offset": {"line": 1076, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/escape-regexp.ts"],"sourcesContent":["// regexp is based on https://github.com/sindresorhus/escape-string-regexp\nconst reHasRegExp = /[|\\\\{}()[\\]^$+*?.-]/\nconst reReplaceRegExp = /[|\\\\{}()[\\]^$+*?.-]/g\n\nexport function escapeStringRegexp(str: string) {\n // see also: https://github.com/lodash/lodash/blob/2da024c3b4f9947a48517639de7560457cd4ec6c/escapeRegExp.js#L23\n if (reHasRegExp.test(str)) {\n return str.replace(reReplaceRegExp, '\\\\$&')\n }\n return str\n}\n"],"names":["escapeStringRegexp","reHasRegExp","reReplaceRegExp","str","test","replace"],"mappings":"AAAA,0EAA0E;;;;+BAI1DA,sBAAAA;;;eAAAA;;;AAHhB,MAAMC,cAAc;AACpB,MAAMC,kBAAkB;AAEjB,SAASF,mBAAmBG,GAAW;IAC5C,+GAA+G;IAC/G,IAAIF,YAAYG,IAAI,CAACD,MAAM;QACzB,OAAOA,IAAIE,OAAO,CAACH,iBAAiB;IACtC;IACA,OAAOC;AACT","ignoreList":[0]}},
24
- {"offset": {"line": 1099, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/invariant-error.ts"],"sourcesContent":["export class InvariantError extends Error {\n constructor(message: string, options?: ErrorOptions) {\n super(\n `Invariant: ${message.endsWith('.') ? message : message + '.'} This is a bug in Next.js.`,\n options\n )\n this.name = 'InvariantError'\n }\n}\n"],"names":["InvariantError","Error","constructor","message","options","endsWith","name"],"mappings":";;;+BAAaA,kBAAAA;;;eAAAA;;;AAAN,MAAMA,uBAAuBC;IAClCC,YAAYC,OAAe,EAAEC,OAAsB,CAAE;QACnD,KAAK,CACH,CAAC,WAAW,EAAED,QAAQE,QAAQ,CAAC,OAAOF,UAAUA,UAAU,IAAI,0BAA0B,CAAC,EACzFC;QAEF,IAAI,CAACE,IAAI,GAAG;IACd;AACF","ignoreList":[0]}},
25
- {"offset": {"line": 1118, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/parse-loader-tree.ts"],"sourcesContent":["import { DEFAULT_SEGMENT_KEY } from '../../segment'\nimport type { LoaderTree } from '../../../../server/lib/app-dir-module'\n\nexport function parseLoaderTree(tree: LoaderTree) {\n const [segment, parallelRoutes, modules, staticSiblings] = tree\n const { layout, template } = modules\n let { page } = modules\n // a __DEFAULT__ segment means that this route didn't match any of the\n // segments in the route, so we should use the default page\n page = segment === DEFAULT_SEGMENT_KEY ? modules.defaultPage : page\n\n const conventionPath = layout?.[1] || template?.[1] || page?.[1]\n\n return {\n page,\n segment,\n modules,\n /* it can be either layout / template / page */\n conventionPath,\n parallelRoutes,\n staticSiblings,\n }\n}\n"],"names":["parseLoaderTree","tree","segment","parallelRoutes","modules","staticSiblings","layout","template","page","DEFAULT_SEGMENT_KEY","defaultPage","conventionPath"],"mappings":";;;+BAGgBA,mBAAAA;;;eAAAA;;;yBAHoB;AAG7B,SAASA,gBAAgBC,IAAgB;IAC9C,MAAM,CAACC,SAASC,gBAAgBC,SAASC,eAAe,GAAGJ;IAC3D,MAAM,EAAEK,MAAM,EAAEC,QAAQ,EAAE,GAAGH;IAC7B,IAAI,EAAEI,IAAI,EAAE,GAAGJ;IACf,sEAAsE;IACtE,2DAA2D;IAC3DI,OAAON,YAAYO,SAAAA,mBAAmB,GAAGL,QAAQM,WAAW,GAAGF;IAE/D,MAAMG,iBAAiBL,QAAQ,CAAC,EAAE,IAAIC,UAAU,CAAC,EAAE,IAAIC,MAAM,CAAC,EAAE;IAEhE,OAAO;QACLA;QACAN;QACAE;QACA,6CAA6C,GAC7CO;QACAR;QACAE;IACF;AACF","ignoreList":[0]}},
26
- {"offset": {"line": 1149, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/get-segment-param.tsx"],"sourcesContent":["import { INTERCEPTION_ROUTE_MARKERS } from './interception-routes'\nimport type { DynamicParamTypes } from '../../app-router-types'\n\nexport type SegmentParam = {\n paramName: string\n paramType: DynamicParamTypes\n}\n\n/**\n * Parse dynamic route segment to type of parameter\n */\nexport function getSegmentParam(segment: string): SegmentParam | null {\n const interceptionMarker = INTERCEPTION_ROUTE_MARKERS.find((marker) =>\n segment.startsWith(marker)\n )\n\n // if an interception marker is part of the path segment, we need to jump ahead\n // to the relevant portion for param parsing\n if (interceptionMarker) {\n segment = segment.slice(interceptionMarker.length)\n }\n\n if (segment.startsWith('[[...') && segment.endsWith(']]')) {\n return {\n // TODO-APP: Optional catchall does not currently work with parallel routes,\n // so for now aren't handling a potential interception marker.\n paramType: 'optional-catchall',\n paramName: segment.slice(5, -2),\n }\n }\n\n if (segment.startsWith('[...') && segment.endsWith(']')) {\n return {\n paramType: interceptionMarker\n ? `catchall-intercepted-${interceptionMarker}`\n : 'catchall',\n paramName: segment.slice(4, -1),\n }\n }\n\n if (segment.startsWith('[') && segment.endsWith(']')) {\n return {\n paramType: interceptionMarker\n ? `dynamic-intercepted-${interceptionMarker}`\n : 'dynamic',\n paramName: segment.slice(1, -1),\n }\n }\n\n return null\n}\n\nexport function isCatchAll(\n type: DynamicParamTypes\n): type is\n | 'catchall'\n | 'catchall-intercepted-(..)(..)'\n | 'catchall-intercepted-(.)'\n | 'catchall-intercepted-(..)'\n | 'catchall-intercepted-(...)'\n | 'optional-catchall' {\n return (\n type === 'catchall' ||\n type === 'catchall-intercepted-(..)(..)' ||\n type === 'catchall-intercepted-(.)' ||\n type === 'catchall-intercepted-(..)' ||\n type === 'catchall-intercepted-(...)' ||\n type === 'optional-catchall'\n )\n}\n\nexport function getParamProperties(paramType: DynamicParamTypes): {\n repeat: boolean\n optional: boolean\n} {\n let repeat = false\n let optional = false\n\n switch (paramType) {\n case 'catchall':\n case 'catchall-intercepted-(..)(..)':\n case 'catchall-intercepted-(.)':\n case 'catchall-intercepted-(..)':\n case 'catchall-intercepted-(...)':\n repeat = true\n break\n case 'optional-catchall':\n repeat = true\n optional = true\n break\n case 'dynamic':\n case 'dynamic-intercepted-(..)(..)':\n case 'dynamic-intercepted-(.)':\n case 'dynamic-intercepted-(..)':\n case 'dynamic-intercepted-(...)':\n break\n default:\n paramType satisfies never\n }\n\n return { repeat, optional }\n}\n"],"names":["getParamProperties","getSegmentParam","isCatchAll","segment","interceptionMarker","INTERCEPTION_ROUTE_MARKERS","find","marker","startsWith","slice","length","endsWith","paramType","paramName","type","repeat","optional"],"mappings":";;;;;;;;;;;;;;;IAuEgBA,kBAAkB,EAAA;eAAlBA;;IA5DAC,eAAe,EAAA;eAAfA;;IAyCAC,UAAU,EAAA;eAAVA;;;oCApD2B;AAWpC,SAASD,gBAAgBE,OAAe;IAC7C,MAAMC,qBAAqBC,oBAAAA,0BAA0B,CAACC,IAAI,CAAC,CAACC,SAC1DJ,QAAQK,UAAU,CAACD;IAGrB,+EAA+E;IAC/E,4CAA4C;IAC5C,IAAIH,oBAAoB;QACtBD,UAAUA,QAAQM,KAAK,CAACL,mBAAmBM,MAAM;IACnD;IAEA,IAAIP,QAAQK,UAAU,CAAC,YAAYL,QAAQQ,QAAQ,CAAC,OAAO;QACzD,OAAO;YACL,4EAA4E;YAC5E,8DAA8D;YAC9DC,WAAW;YACXC,WAAWV,QAAQM,KAAK,CAAC,GAAG,CAAC;QAC/B;IACF;IAEA,IAAIN,QAAQK,UAAU,CAAC,WAAWL,QAAQQ,QAAQ,CAAC,MAAM;QACvD,OAAO;YACLC,WAAWR,qBACP,CAAC,qBAAqB,EAAEA,oBAAoB,GAC5C;YACJS,WAAWV,QAAQM,KAAK,CAAC,GAAG,CAAC;QAC/B;IACF;IAEA,IAAIN,QAAQK,UAAU,CAAC,QAAQL,QAAQQ,QAAQ,CAAC,MAAM;QACpD,OAAO;YACLC,WAAWR,qBACP,CAAC,oBAAoB,EAAEA,oBAAoB,GAC3C;YACJS,WAAWV,QAAQM,KAAK,CAAC,GAAG,CAAC;QAC/B;IACF;IAEA,OAAO;AACT;AAEO,SAASP,WACdY,IAAuB;IAQvB,OACEA,SAAS,cACTA,SAAS,mCACTA,SAAS,8BACTA,SAAS,+BACTA,SAAS,gCACTA,SAAS;AAEb;AAEO,SAASd,mBAAmBY,SAA4B;IAI7D,IAAIG,SAAS;IACb,IAAIC,WAAW;IAEf,OAAQJ;QACN,KAAK;QACL,KAAK;QACL,KAAK;QACL,KAAK;QACL,KAAK;YACHG,SAAS;YACT;QACF,KAAK;YACHA,SAAS;YACTC,WAAW;YACX;QACF,KAAK;QACL,KAAK;QACL,KAAK;QACL,KAAK;QACL,KAAK;YACH;QACF;YACEJ;IACJ;IAEA,OAAO;QAAEG;QAAQC;IAAS;AAC5B","ignoreList":[0]}},
27
- {"offset": {"line": 1240, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/routes/app.ts"],"sourcesContent":["import { InvariantError } from '../../invariant-error'\nimport { getSegmentParam, type SegmentParam } from '../utils/get-segment-param'\nimport {\n INTERCEPTION_ROUTE_MARKERS,\n type InterceptionMarker,\n} from '../utils/interception-routes'\n\nexport type RouteGroupAppRouteSegment = {\n type: 'route-group'\n name: string\n\n /**\n * If present, this segment has an interception marker prefixing it.\n */\n interceptionMarker?: InterceptionMarker\n}\n\nexport type ParallelRouteAppRouteSegment = {\n type: 'parallel-route'\n name: string\n\n /**\n * If present, this segment has an interception marker prefixing it.\n */\n interceptionMarker?: InterceptionMarker\n}\n\nexport type StaticAppRouteSegment = {\n type: 'static'\n name: string\n\n /**\n * If present, this segment has an interception marker prefixing it.\n */\n interceptionMarker?: InterceptionMarker\n}\n\nexport type DynamicAppRouteSegment = {\n type: 'dynamic'\n name: string\n param: SegmentParam\n\n /**\n * If present, this segment has an interception marker prefixing it.\n */\n interceptionMarker?: InterceptionMarker\n}\n\n/**\n * Represents a single segment in a route path.\n * Can be either static (e.g., \"blog\") or dynamic (e.g., \"[slug]\").\n */\nexport type AppRouteSegment =\n | StaticAppRouteSegment\n | DynamicAppRouteSegment\n | RouteGroupAppRouteSegment\n | ParallelRouteAppRouteSegment\n\nexport type NormalizedAppRouteSegment =\n | StaticAppRouteSegment\n | DynamicAppRouteSegment\n\nexport function parseAppRouteSegment(segment: string): AppRouteSegment | null {\n if (segment === '') {\n return null\n }\n\n // Check if the segment starts with an interception marker\n const interceptionMarker = INTERCEPTION_ROUTE_MARKERS.find((m) =>\n segment.startsWith(m)\n )\n\n const param = getSegmentParam(segment)\n if (param) {\n return {\n type: 'dynamic',\n name: segment,\n param,\n interceptionMarker,\n }\n } else if (segment.startsWith('(') && segment.endsWith(')')) {\n return {\n type: 'route-group',\n name: segment,\n interceptionMarker,\n }\n } else if (segment.startsWith('@')) {\n return {\n type: 'parallel-route',\n name: segment,\n interceptionMarker,\n }\n } else {\n return {\n type: 'static',\n name: segment,\n interceptionMarker,\n }\n }\n}\n\nexport type AppRoute = {\n normalized: boolean\n pathname: string\n segments: AppRouteSegment[]\n dynamicSegments: DynamicAppRouteSegment[]\n interceptionMarker: InterceptionMarker | undefined\n interceptingRoute: AppRoute | undefined\n interceptedRoute: AppRoute | undefined\n}\n\nexport type NormalizedAppRoute = Omit<AppRoute, 'normalized' | 'segments'> & {\n normalized: true\n segments: NormalizedAppRouteSegment[]\n}\n\nexport function isNormalizedAppRoute(\n route: InterceptionAppRoute\n): route is NormalizedInterceptionAppRoute\nexport function isNormalizedAppRoute(\n route: AppRoute | InterceptionAppRoute\n): route is NormalizedAppRoute {\n return route.normalized\n}\n\nexport type InterceptionAppRoute = Omit<\n AppRoute,\n 'interceptionMarker' | 'interceptingRoute' | 'interceptedRoute'\n> & {\n interceptionMarker: InterceptionMarker\n interceptingRoute: AppRoute\n interceptedRoute: AppRoute\n}\n\nexport type NormalizedInterceptionAppRoute = Omit<\n InterceptionAppRoute,\n | 'normalized'\n | 'segments'\n | 'interceptionMarker'\n | 'interceptingRoute'\n | 'interceptedRoute'\n> & {\n normalized: true\n segments: NormalizedAppRouteSegment[]\n interceptionMarker: InterceptionMarker\n interceptingRoute: NormalizedAppRoute\n interceptedRoute: NormalizedAppRoute\n}\n\nexport function isInterceptionAppRoute(\n route: NormalizedAppRoute\n): route is NormalizedInterceptionAppRoute\nexport function isInterceptionAppRoute(\n route: AppRoute\n): route is InterceptionAppRoute {\n return (\n route.interceptionMarker !== undefined &&\n route.interceptingRoute !== undefined &&\n route.interceptedRoute !== undefined\n )\n}\n\nexport function parseAppRoute(\n pathname: string,\n normalized: true\n): NormalizedAppRoute\nexport function parseAppRoute(pathname: string, normalized: false): AppRoute\nexport function parseAppRoute(\n pathname: string,\n normalized: boolean\n): AppRoute | NormalizedAppRoute {\n const pathnameSegments = pathname.split('/').filter(Boolean)\n\n // Build segments array with static and dynamic segments\n const segments: AppRouteSegment[] = []\n\n // Parse if this is an interception route.\n let interceptionMarker: InterceptionMarker | undefined\n let interceptingRoute: AppRoute | NormalizedAppRoute | undefined\n let interceptedRoute: AppRoute | NormalizedAppRoute | undefined\n\n for (const segment of pathnameSegments) {\n // Parse the segment into an AppSegment.\n const appSegment = parseAppRouteSegment(segment)\n if (!appSegment) {\n continue\n }\n\n if (\n normalized &&\n (appSegment.type === 'route-group' ||\n appSegment.type === 'parallel-route')\n ) {\n throw new InvariantError(\n `${pathname} is being parsed as a normalized route, but it has a route group or parallel route segment.`\n )\n }\n\n segments.push(appSegment)\n\n if (appSegment.interceptionMarker) {\n const parts = pathname.split(appSegment.interceptionMarker)\n if (parts.length !== 2) {\n throw new Error(`Invalid interception route: ${pathname}`)\n }\n\n interceptingRoute = normalized\n ? parseAppRoute(parts[0], true)\n : parseAppRoute(parts[0], false)\n interceptedRoute = normalized\n ? parseAppRoute(parts[1], true)\n : parseAppRoute(parts[1], false)\n interceptionMarker = appSegment.interceptionMarker\n }\n }\n\n const dynamicSegments = segments.filter(\n (segment) => segment.type === 'dynamic'\n )\n\n return {\n normalized,\n pathname,\n segments,\n dynamicSegments,\n interceptionMarker,\n interceptingRoute,\n interceptedRoute,\n }\n}\n"],"names":["isInterceptionAppRoute","isNormalizedAppRoute","parseAppRoute","parseAppRouteSegment","segment","interceptionMarker","INTERCEPTION_ROUTE_MARKERS","find","m","startsWith","param","getSegmentParam","type","name","endsWith","route","normalized","undefined","interceptingRoute","interceptedRoute","pathname","pathnameSegments","split","filter","Boolean","segments","appSegment","InvariantError","push","parts","length","Error","dynamicSegments"],"mappings":";;;;;;;;;;;;;;;;IAwJgBA,sBAAsB,EAAA;eAAtBA;;IAjCAC,oBAAoB,EAAA;eAApBA;;IAgDAC,aAAa,EAAA;eAAbA;;IAzGAC,oBAAoB,EAAA;eAApBA;;;gCA9De;iCACoB;oCAI5C;AAyDA,SAASA,qBAAqBC,OAAe;IAClD,IAAIA,YAAY,IAAI;QAClB,OAAO;IACT;IAEA,0DAA0D;IAC1D,MAAMC,qBAAqBC,oBAAAA,0BAA0B,CAACC,IAAI,CAAC,CAACC,IAC1DJ,QAAQK,UAAU,CAACD;IAGrB,MAAME,QAAQC,CAAAA,GAAAA,iBAAAA,eAAe,EAACP;IAC9B,IAAIM,OAAO;QACT,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cAAoD,CAApD,IAAIC,MAAM,CAAC,4BAA4B,EAAEX,UAAU,GAAnD,qBAAA;2BAAA;gCAAA;kCAAA;gBAAmD;YAC3D;YAEAF,oBAAoBF,aAChBd,cAAc2B,KAAK,CAAC,EAAE,EAAE,QACxB3B,cAAc2B,KAAK,CAAC,EAAE,EAAE;YAC5BV,mBAAmBH,aACfd,cAAc2B,KAAK,CAAC,EAAE,EAAE,QACxB3B,cAAc2B,KAAK,CAAC,EAAE,EAAE;YAC5BxB,qBAAqBqB,WAAWrB,kBAAkB;QACpD;IACF;IAEA,MAAM2B,kBAAkBP,SAASF,MAAM,CACrC,CAACnB,UAAYA,QAAQQ,IAAI,KAAK;IAGhC,OAAO;QACLI;QACAI;QACAK;QACAO;QACA3B;QACAa;QACAC;IACF;AACF","ignoreList":[0]}},
28
- {"offset": {"line": 1363, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/interception-prefix-from-param-type.ts"],"sourcesContent":["import type { DynamicParamTypes } from '../../app-router-types'\n\nexport function interceptionPrefixFromParamType(\n paramType: DynamicParamTypes\n): string | null {\n switch (paramType) {\n case 'catchall-intercepted-(..)(..)':\n case 'dynamic-intercepted-(..)(..)':\n return '(..)(..)'\n case 'catchall-intercepted-(.)':\n case 'dynamic-intercepted-(.)':\n return '(.)'\n case 'catchall-intercepted-(..)':\n case 'dynamic-intercepted-(..)':\n return '(..)'\n case 'catchall-intercepted-(...)':\n case 'dynamic-intercepted-(...)':\n return '(...)'\n case 'catchall':\n case 'dynamic':\n case 'optional-catchall':\n default:\n return null\n }\n}\n"],"names":["interceptionPrefixFromParamType","paramType"],"mappings":";;;+BAEgBA,mCAAAA;;;eAAAA;;;AAAT,SAASA,gCACdC,SAA4B;IAE5B,OAAQA;QACN,KAAK;QACL,KAAK;YACH,OAAO;QACT,KAAK;QACL,KAAK;YACH,OAAO;QACT,KAAK;QACL,KAAK;YACH,OAAO;QACT,KAAK;QACL,KAAK;YACH,OAAO;QACT,KAAK;QACL,KAAK;QACL,KAAK;QACL;YACE,OAAO;IACX;AACF","ignoreList":[0]}},
29
- {"offset": {"line": 1397, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/resolve-param-value.ts"],"sourcesContent":["import type { Params } from '../../../../server/request/params'\nimport type { DynamicParamTypes } from '../../app-router-types'\nimport { InvariantError } from '../../invariant-error'\nimport type {\n NormalizedAppRoute,\n NormalizedAppRouteSegment,\n} from '../routes/app'\nimport { interceptionPrefixFromParamType } from './interception-prefix-from-param-type'\n\n/**\n * Extracts the param value from a path segment, handling interception markers\n * based on the expected param type.\n *\n * @param pathSegment - The path segment to extract the value from\n * @param params - The current params object for resolving dynamic param references\n * @param paramType - The expected param type which may include interception marker info\n * @returns The extracted param value\n */\nfunction getParamValueFromSegment(\n pathSegment: NormalizedAppRouteSegment,\n params: Params,\n paramType: DynamicParamTypes\n): string {\n // If the segment is dynamic, resolve it from the params object\n if (pathSegment.type === 'dynamic') {\n return params[pathSegment.param.paramName] as string\n }\n\n // If the paramType indicates this is an intercepted param, strip the marker\n // that matches the interception marker in the param type\n const interceptionPrefix = interceptionPrefixFromParamType(paramType)\n if (interceptionPrefix === pathSegment.interceptionMarker) {\n return pathSegment.name.replace(pathSegment.interceptionMarker, '')\n }\n\n // For static segments, use the name\n return pathSegment.name\n}\n\n/**\n * Resolves a route parameter value from the route segments at the given depth.\n * This shared logic is used by both extractPathnameRouteParamSegmentsFromLoaderTree\n * and resolveRouteParamsFromTree.\n *\n * @param paramName - The parameter name to resolve\n * @param paramType - The parameter type (dynamic, catchall, etc.)\n * @param depth - The current depth in the route tree\n * @param route - The normalized route containing segments\n * @param params - The current params object (used to resolve embedded param references)\n * @param options - Configuration options\n * @returns The resolved parameter value, or undefined if it cannot be resolved\n */\nexport function resolveParamValue(\n paramName: string,\n paramType: DynamicParamTypes,\n depth: number,\n route: NormalizedAppRoute,\n params: Params\n): string | string[] | undefined {\n switch (paramType) {\n case 'catchall':\n case 'optional-catchall':\n case 'catchall-intercepted-(..)(..)':\n case 'catchall-intercepted-(.)':\n case 'catchall-intercepted-(..)':\n case 'catchall-intercepted-(...)':\n // For catchall routes, derive from pathname using depth to determine\n // which segments to use\n const processedSegments: string[] = []\n\n // Process segments to handle any embedded dynamic params\n for (let index = depth; index < route.segments.length; index++) {\n const pathSegment = route.segments[index]\n\n if (pathSegment.type === 'static') {\n let value = pathSegment.name\n\n // For intercepted catch-all params, strip the marker from the first segment\n const interceptionPrefix = interceptionPrefixFromParamType(paramType)\n if (\n interceptionPrefix &&\n index === depth &&\n interceptionPrefix === pathSegment.interceptionMarker\n ) {\n // Strip the interception marker from the value\n value = value.replace(pathSegment.interceptionMarker, '')\n }\n\n processedSegments.push(value)\n } else {\n // If the segment is a param placeholder, check if we have its value\n if (!params.hasOwnProperty(pathSegment.param.paramName)) {\n // If the segment is an optional catchall, we can break out of the\n // loop because it's optional!\n if (pathSegment.param.paramType === 'optional-catchall') {\n break\n }\n\n // Unknown param placeholder in pathname - can't derive full value\n return undefined\n }\n\n // If the segment matches a param, use the param value\n // We don't encode values here as that's handled during retrieval.\n const paramValue = params[pathSegment.param.paramName]\n if (Array.isArray(paramValue)) {\n processedSegments.push(...paramValue)\n } else {\n processedSegments.push(paramValue as string)\n }\n }\n }\n\n if (processedSegments.length > 0) {\n return processedSegments\n } else if (paramType === 'optional-catchall') {\n return undefined\n } else {\n // We shouldn't be able to match a catchall segment without any path\n // segments if it's not an optional catchall\n throw new InvariantError(\n `Unexpected empty path segments match for a route \"${route.pathname}\" with param \"${paramName}\" of type \"${paramType}\"`\n )\n }\n case 'dynamic':\n case 'dynamic-intercepted-(..)(..)':\n case 'dynamic-intercepted-(.)':\n case 'dynamic-intercepted-(..)':\n case 'dynamic-intercepted-(...)':\n // For regular dynamic parameters, take the segment at this depth\n if (depth < route.segments.length) {\n const pathSegment = route.segments[depth]\n\n // Check if the segment at this depth is a placeholder for an unknown param\n if (\n pathSegment.type === 'dynamic' &&\n !params.hasOwnProperty(pathSegment.param.paramName)\n ) {\n // The segment is a placeholder like [category] and we don't have the value\n return undefined\n }\n\n // If the segment matches a param, use the param value from params object\n // Otherwise it's a static segment, just use it directly\n // We don't encode values here as that's handled during retrieval\n return getParamValueFromSegment(pathSegment, params, paramType)\n }\n\n return undefined\n\n default:\n paramType satisfies never\n }\n}\n"],"names":["resolveParamValue","getParamValueFromSegment","pathSegment","params","paramType","type","param","paramName","interceptionPrefix","interceptionPrefixFromParamType","interceptionMarker","name","replace","depth","route","processedSegments","index","segments","length","value","push","hasOwnProperty","undefined","paramValue","Array","isArray","InvariantError","pathname"],"mappings":";;;+BAoDgBA,qBAAAA;;;eAAAA;;;gCAlDe;iDAKiB;AAEhD;;;;;;;;CAQC,GACD,SAASC,yBACPC,WAAsC,EACtCC,MAAc,EACdC,SAA4B;IAE5B,+DAA+D;IAC/D,IAAIF,YAAYG,IAAI,KAAK,WAAW;QAClC,OAAOF,MAAM,CAACD,YAAYI,KAAK,CAACC,SAAS,CAAC;IAC5C;IAEA,4EAA4E;IAC5E,yDAAyD;IACzD,MAAMC,qBAAqBC,CAAAA,GAAAA,iCAAAA,+BAA+B,EAACL;IAC3D,IAAII,uBAAuBN,YAAYQ,kBAAkB,EAAE;QACzD,OAAOR,YAAYS,IAAI,CAACC,OAAO,CAACV,YAAYQ,kBAAkB,EAAE;IAClE;IAEA,oCAAoC;IACpC,OAAOR,YAAYS,IAAI;AACzB;AAeO,SAASX,kBACdO,SAAiB,EACjBH,SAA4B,EAC5BS,KAAa,EACbC,KAAyB,EACzBX,MAAc;IAEd,OAAQC;QACN,KAAK;QACL,KAAK;QACL,KAAK;QACL,KAAK;QACL,KAAK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kD,EAAEZ,MAAMa,QAAQ,CAAC,cAAc,EAAEpB,UAAU,WAAW,EAAEH,UAAU,CAAC,CAAC,GADnH,qBAAA;2BAAA;gCAAA;kCAAA;gBAEN;YACF;QACF,KAAK;QACL,KAAK;QACL,KAAK;QACL,KAAK;QACL,KAAK;YACH,iEAAiE;YACjE,IAAIS,QAAQC,MAAMG,QAAQ,CAACC,MAAM,EAAE;gBACjC,MAAMhB,cAAcY,MAAMG,QAAQ,CAACJ,MAAM;gBAEzC,2EAA2E;gBAC3E,IACEX,YAAYG,IAAI,KAAK,aACrB,CAACF,OAAOkB,cAAc,CAACnB,YAAYI,KAAK,CAACC,SAAS,GAClD;oBACA,2EAA2E;oBAC3E,OAAOe;gBACT;gBAEA,yEAAyE;gBACzE,wDAAwD;gBACxD,iEAAiE;gBACjE,OAAOrB,yBAAyBC,aAAaC,QAAQC;YACvD;YAEA,OAAOkB;QAET;YACElB;IACJ;AACF","ignoreList":[0]}},
30
- {"offset": {"line": 1514, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/get-dynamic-param.ts"],"sourcesContent":["import type { DynamicParam } from '../../../../server/app-render/app-render'\nimport type { LoaderTree } from '../../../../server/lib/app-dir-module'\nimport type { OpaqueFallbackRouteParams } from '../../../../server/request/fallback-params'\nimport type { Params } from '../../../../server/request/params'\nimport type { DynamicParamTypesShort } from '../../app-router-types'\nimport { InvariantError } from '../../invariant-error'\nimport { parseLoaderTree } from './parse-loader-tree'\nimport { parseAppRoute, parseAppRouteSegment } from '../routes/app'\nimport { resolveParamValue } from './resolve-param-value'\n\n/**\n * Gets the value of a param from the params object. This correctly handles the\n * case where the param is a fallback route param and encodes the resulting\n * value.\n *\n * @param interpolatedParams - The params object.\n * @param segmentKey - The key of the segment.\n * @param fallbackRouteParams - The fallback route params.\n * @returns The value of the param.\n */\nfunction getParamValue(\n interpolatedParams: Params,\n segmentKey: string,\n fallbackRouteParams: OpaqueFallbackRouteParams | null\n) {\n let value = interpolatedParams[segmentKey]\n\n if (fallbackRouteParams?.has(segmentKey)) {\n // We know that the fallback route params has the segment key because we\n // checked that above.\n const [searchValue] = fallbackRouteParams.get(segmentKey)!\n value = searchValue\n } else if (Array.isArray(value)) {\n value = value.map((i) => encodeURIComponent(i))\n } else if (typeof value === 'string') {\n value = encodeURIComponent(value)\n }\n\n return value\n}\n\nexport function interpolateParallelRouteParams(\n loaderTree: LoaderTree,\n params: Params,\n pagePath: string,\n fallbackRouteParams: OpaqueFallbackRouteParams | null\n): Params {\n const interpolated = structuredClone(params)\n\n // Stack-based traversal with depth tracking\n const stack: Array<{ tree: LoaderTree; depth: number }> = [\n { tree: loaderTree, depth: 0 },\n ]\n\n // Parse the route from the provided page path.\n const route = parseAppRoute(pagePath, true)\n\n while (stack.length > 0) {\n const { tree, depth } = stack.pop()!\n const { segment, parallelRoutes } = parseLoaderTree(tree)\n\n const appSegment = parseAppRouteSegment(segment)\n\n if (\n appSegment?.type === 'dynamic' &&\n !interpolated.hasOwnProperty(appSegment.param.paramName) &&\n // If the param is in the fallback route params, we don't need to\n // interpolate it because it's already marked as being unknown.\n !fallbackRouteParams?.has(appSegment.param.paramName)\n ) {\n const { paramName, paramType } = appSegment.param\n\n const paramValue = resolveParamValue(\n paramName,\n paramType,\n depth,\n route,\n interpolated\n )\n\n if (paramValue !== undefined) {\n interpolated[paramName] = paramValue\n } else if (paramType !== 'optional-catchall') {\n throw new InvariantError(\n `Could not resolve param value for segment: ${paramName}`\n )\n }\n }\n\n // Calculate next depth - increment if this is not a route group and not empty\n let nextDepth = depth\n if (\n appSegment &&\n appSegment.type !== 'route-group' &&\n appSegment.type !== 'parallel-route'\n ) {\n nextDepth++\n }\n\n // Add all parallel routes to the stack for processing\n for (const parallelRoute of Object.values(parallelRoutes)) {\n stack.push({ tree: parallelRoute, depth: nextDepth })\n }\n }\n\n return interpolated\n}\n\n/**\n *\n * Shared logic on client and server for creating a dynamic param value.\n *\n * This code needs to be shared with the client so it can extract dynamic route\n * params from the URL without a server request.\n *\n * Because everything in this module is sent to the client, we should aim to\n * keep this code as simple as possible. The special case handling for catchall\n * and optional is, alas, unfortunate.\n */\nexport function getDynamicParam(\n interpolatedParams: Params,\n segmentKey: string,\n dynamicParamType: DynamicParamTypesShort,\n fallbackRouteParams: OpaqueFallbackRouteParams | null,\n staticSiblings: readonly string[] | null\n): DynamicParam {\n let value: string | string[] | undefined = getParamValue(\n interpolatedParams,\n segmentKey,\n fallbackRouteParams\n )\n\n // handle the case where an optional catchall does not have a value,\n // e.g. `/dashboard/[[...slug]]` when requesting `/dashboard`\n if (!value || value.length === 0) {\n if (dynamicParamType === 'oc') {\n return {\n param: segmentKey,\n value: null,\n type: dynamicParamType,\n treeSegment: [segmentKey, '', dynamicParamType, staticSiblings],\n }\n }\n\n throw new InvariantError(\n `Missing value for segment key: \"${segmentKey}\" with dynamic param type: ${dynamicParamType}`\n )\n }\n\n const paramCacheKey = Array.isArray(value) ? value.join('/') : value\n\n return {\n param: segmentKey,\n // The value that is passed to user code.\n value,\n // The value that is rendered in the router tree.\n // TODO: If the number of static siblings exceeds some threshold (e.g.,\n // dozens or hundreds), consider sending a Bloom filter instead of the full\n // array to reduce payload size. The client would then use the Bloom filter\n // to check membership with a small false positive rate.\n treeSegment: [segmentKey, paramCacheKey, dynamicParamType, staticSiblings],\n type: dynamicParamType,\n }\n}\n\n/**\n * Regular expression pattern used to match route parameters.\n * Matches both single parameters and parameter groups.\n * Examples:\n * - `[[...slug]]` matches parameter group with key 'slug', repeat: true, optional: true\n * - `[...slug]` matches parameter group with key 'slug', repeat: true, optional: false\n * - `[[foo]]` matches parameter with key 'foo', repeat: false, optional: true\n * - `[bar]` matches parameter with key 'bar', repeat: false, optional: false\n */\nexport const PARAMETER_PATTERN = /^([^[]*)\\[((?:\\[[^\\]]*\\])|[^\\]]+)\\](.*)$/\n\n/**\n * Parses a given parameter from a route to a data structure that can be used\n * to generate the parametrized route.\n * Examples:\n * - `[[...slug]]` -> `{ key: 'slug', repeat: true, optional: true }`\n * - `[...slug]` -> `{ key: 'slug', repeat: true, optional: false }`\n * - `[[foo]]` -> `{ key: 'foo', repeat: false, optional: true }`\n * - `[bar]` -> `{ key: 'bar', repeat: false, optional: false }`\n * - `fizz` -> `{ key: 'fizz', repeat: false, optional: false }`\n * @param param - The parameter to parse.\n * @returns The parsed parameter as a data structure.\n */\nexport function parseParameter(param: string) {\n const match = param.match(PARAMETER_PATTERN)\n\n if (!match) {\n return parseMatchedParameter(param)\n }\n\n return parseMatchedParameter(match[2])\n}\n\n/**\n * Parses a matched parameter from the PARAMETER_PATTERN regex to a data structure that can be used\n * to generate the parametrized route.\n * Examples:\n * - `[...slug]` -> `{ key: 'slug', repeat: true, optional: true }`\n * - `...slug` -> `{ key: 'slug', repeat: true, optional: false }`\n * - `[foo]` -> `{ key: 'foo', repeat: false, optional: true }`\n * - `bar` -> `{ key: 'bar', repeat: false, optional: false }`\n * @param param - The matched parameter to parse.\n * @returns The parsed parameter as a data structure.\n */\nexport function parseMatchedParameter(param: string) {\n const optional = param.startsWith('[') && param.endsWith(']')\n if (optional) {\n param = param.slice(1, -1)\n }\n const repeat = param.startsWith('...')\n if (repeat) {\n param = param.slice(3)\n }\n return { key: param, repeat, optional }\n}\n"],"names":["PARAMETER_PATTERN","getDynamicParam","interpolateParallelRouteParams","parseMatchedParameter","parseParameter","getParamValue","interpolatedParams","segmentKey","fallbackRouteParams","value","has","searchValue","get","Array","isArray","map","i","encodeURIComponent","loaderTree","params","pagePath","interpolated","structuredClone","stack","tree","depth","route","parseAppRoute","length","pop","segment","parallelRoutes","parseLoaderTree","appSegment","parseAppRouteSegment","type","hasOwnProperty","param","paramName","paramType","paramValue","resolveParamValue","undefined","InvariantError","nextDepth","parallelRoute","Object","values","push","dynamicParamType","staticSiblings","treeSegment","paramCacheKey","join","match","optional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CACtB,CAAC,gCAAgC,EAAEpC,WAAW,2BAA2B,EAAE0C,kBAAkB,GADzF,qBAAA;mBAAA;wBAAA;0BAAA;QAEN;IACF;IAEA,MAAMG,gBAAgBvC,MAAMC,OAAO,CAACL,SAASA,MAAM4C,IAAI,CAAC,OAAO5C;IAE/D,OAAO;QACL4B,OAAO9B;QACP,yCAAyC;QACzCE;QACA,iDAAiD;QACjD,uEAAuE;QACvE,2EAA2E;QAC3E,2EAA2E;QAC3E,wDAAwD;QACxD0C,aAAa;YAAC5C;YAAY6C;YAAeH;YAAkBC;SAAe;QAC1Ef,MAAMc;IACR;AACF;AAWO,MAAMjD,oBAAoB;AAc1B,SAASI,eAAeiC,KAAa;IAC1C,MAAMiB,QAAQjB,MAAMiB,KAAK,CAACtD;IAE1B,IAAI,CAACsD,OAAO;QACV,OAAOnD,sBAAsBkC;IAC/B;IAEA,OAAOlC,sBAAsBmD,KAAK,CAAC,EAAE;AACvC;AAaO,SAASnD,sBAAsBkC,KAAa;IACjD,MAAMkB,WAAWlB,MAAMmB,UAAU,CAAC,QAAQnB,MAAMoB,QAAQ,CAAC;IACzD,IAAIF,UAAU;QACZlB,QAAQA,MAAMqB,KAAK,CAAC,GAAG,CAAC;IAC1B;IACA,MAAMC,SAAStB,MAAMmB,UAAU,CAAC;IAChC,IAAIG,QAAQ;QACVtB,QAAQA,MAAMqB,KAAK,CAAC;IACtB;IACA,OAAO;QAAEE,KAAKvB;QAAOsB;QAAQJ;IAAS;AACxC","ignoreList":[0]}},
31
- {"offset": {"line": 1689, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/route-regex.ts"],"sourcesContent":["import {\n NEXT_INTERCEPTION_MARKER_PREFIX,\n NEXT_QUERY_PARAM_PREFIX,\n} from '../../../../lib/constants'\nimport { INTERCEPTION_ROUTE_MARKERS } from './interception-routes'\nimport { escapeStringRegexp } from '../../escape-regexp'\nimport { removeTrailingSlash } from './remove-trailing-slash'\nimport { PARAMETER_PATTERN, parseMatchedParameter } from './get-dynamic-param'\n\nexport interface Group {\n pos: number\n repeat: boolean\n optional: boolean\n}\n\nexport interface RouteRegex {\n groups: { [groupName: string]: Group }\n re: RegExp\n}\n\nexport type RegexReference = {\n names: Record<string, string>\n intercepted: Record<string, string>\n}\n\ntype GetNamedRouteRegexOptions = {\n /**\n * Whether to prefix the route keys with the NEXT_INTERCEPTION_MARKER_PREFIX\n * or NEXT_QUERY_PARAM_PREFIX. This is only relevant when creating the\n * routes-manifest during the build.\n */\n prefixRouteKeys: boolean\n\n /**\n * Whether to include the suffix in the route regex. This means that when you\n * have something like `/[...slug].json` the `.json` part will be included\n * in the regex, yielding `/(.*).json` as the regex.\n */\n includeSuffix?: boolean\n\n /**\n * Whether to include the prefix in the route regex. This means that when you\n * have something like `/[...slug].json` the `/` part will be included\n * in the regex, yielding `^/(.*).json$` as the regex.\n *\n * Note that interception markers will already be included without the need\n */\n includePrefix?: boolean\n\n /**\n * Whether to exclude the optional trailing slash from the route regex.\n */\n excludeOptionalTrailingSlash?: boolean\n\n /**\n * Whether to backtrack duplicate keys. This is only relevant when creating\n * the routes-manifest during the build.\n */\n backreferenceDuplicateKeys?: boolean\n\n /**\n * If provided, this will be used as the reference for the dynamic parameter\n * keys instead of generating them in context. This is currently only used for\n * interception routes.\n */\n reference?: RegexReference\n}\n\ntype GetRouteRegexOptions = {\n /**\n * Whether to include extra parts in the route regex. This means that when you\n * have something like `/[...slug].json` the `.json` part will be included\n * in the regex, yielding `/(.*).json` as the regex.\n */\n includeSuffix?: boolean\n\n /**\n * Whether to include the prefix in the route regex. This means that when you\n * have something like `/[...slug].json` the `/` part will be included\n * in the regex, yielding `^/(.*).json$` as the regex.\n *\n * Note that interception markers will already be included without the need\n * of adding this option.\n */\n includePrefix?: boolean\n\n /**\n * Whether to exclude the optional trailing slash from the route regex.\n */\n excludeOptionalTrailingSlash?: boolean\n}\n\nfunction getParametrizedRoute(\n route: string,\n includeSuffix: boolean,\n includePrefix: boolean\n) {\n const groups: { [groupName: string]: Group } = {}\n let groupIndex = 1\n\n const segments: string[] = []\n for (const segment of removeTrailingSlash(route).slice(1).split('/')) {\n const markerMatch = INTERCEPTION_ROUTE_MARKERS.find((m) =>\n segment.startsWith(m)\n )\n const paramMatches = segment.match(PARAMETER_PATTERN) // Check for parameters\n\n if (markerMatch && paramMatches && paramMatches[2]) {\n const { key, optional, repeat } = parseMatchedParameter(paramMatches[2])\n groups[key] = { pos: groupIndex++, repeat, optional }\n segments.push(`/${escapeStringRegexp(markerMatch)}([^/]+?)`)\n } else if (paramMatches && paramMatches[2]) {\n const { key, repeat, optional } = parseMatchedParameter(paramMatches[2])\n groups[key] = { pos: groupIndex++, repeat, optional }\n\n if (includePrefix && paramMatches[1]) {\n segments.push(`/${escapeStringRegexp(paramMatches[1])}`)\n }\n\n let s = repeat ? (optional ? '(?:/(.+?))?' : '/(.+?)') : '/([^/]+?)'\n\n // Remove the leading slash if includePrefix already added it.\n if (includePrefix && paramMatches[1]) {\n s = s.substring(1)\n }\n\n segments.push(s)\n } else {\n segments.push(`/${escapeStringRegexp(segment)}`)\n }\n\n // If there's a suffix, add it to the segments if it's enabled.\n if (includeSuffix && paramMatches && paramMatches[3]) {\n segments.push(escapeStringRegexp(paramMatches[3]))\n }\n }\n\n return {\n parameterizedRoute: segments.join(''),\n groups,\n }\n}\n\n/**\n * From a normalized route this function generates a regular expression and\n * a corresponding groups object intended to be used to store matching groups\n * from the regular expression.\n */\nexport function getRouteRegex(\n normalizedRoute: string,\n {\n includeSuffix = false,\n includePrefix = false,\n excludeOptionalTrailingSlash = false,\n }: GetRouteRegexOptions = {}\n): RouteRegex {\n const { parameterizedRoute, groups } = getParametrizedRoute(\n normalizedRoute,\n includeSuffix,\n includePrefix\n )\n\n let re = parameterizedRoute\n if (!excludeOptionalTrailingSlash) {\n re += '(?:/)?'\n }\n\n return {\n re: new RegExp(`^${re}$`),\n groups: groups,\n }\n}\n\n/**\n * Builds a function to generate a minimal routeKey using only a-z and minimal\n * number of characters.\n */\nfunction buildGetSafeRouteKey() {\n let i = 0\n\n return () => {\n let routeKey = ''\n let j = ++i\n while (j > 0) {\n routeKey += String.fromCharCode(97 + ((j - 1) % 26))\n j = Math.floor((j - 1) / 26)\n }\n return routeKey\n }\n}\n\nfunction getSafeKeyFromSegment({\n interceptionMarker,\n getSafeRouteKey,\n segment,\n routeKeys,\n keyPrefix,\n backreferenceDuplicateKeys,\n}: {\n interceptionMarker?: string\n getSafeRouteKey: () => string\n segment: string\n routeKeys: Record<string, string>\n keyPrefix?: string\n backreferenceDuplicateKeys: boolean\n}) {\n const { key, optional, repeat } = parseMatchedParameter(segment)\n\n // replace any non-word characters since they can break\n // the named regex\n let cleanedKey = key.replace(/\\W/g, '')\n\n if (keyPrefix) {\n cleanedKey = `${keyPrefix}${cleanedKey}`\n }\n let invalidKey = false\n\n // check if the key is still invalid and fallback to using a known\n // safe key\n if (cleanedKey.length === 0 || cleanedKey.length > 30) {\n invalidKey = true\n }\n if (!isNaN(parseInt(cleanedKey.slice(0, 1)))) {\n invalidKey = true\n }\n\n if (invalidKey) {\n cleanedKey = getSafeRouteKey()\n }\n\n const duplicateKey = cleanedKey in routeKeys\n\n if (keyPrefix) {\n routeKeys[cleanedKey] = `${keyPrefix}${key}`\n } else {\n routeKeys[cleanedKey] = key\n }\n\n // if the segment has an interception marker, make sure that's part of the regex pattern\n // this is to ensure that the route with the interception marker doesn't incorrectly match\n // the non-intercepted route (ie /app/(.)[username] should not match /app/[username])\n const interceptionPrefix = interceptionMarker\n ? escapeStringRegexp(interceptionMarker)\n : ''\n\n let pattern: string\n if (duplicateKey && backreferenceDuplicateKeys) {\n // Use a backreference to the key to ensure that the key is the same value\n // in each of the placeholders.\n pattern = `\\\\k<${cleanedKey}>`\n } else if (repeat) {\n pattern = `(?<${cleanedKey}>.+?)`\n } else {\n pattern = `(?<${cleanedKey}>[^/]+?)`\n }\n\n return {\n key,\n pattern: optional\n ? `(?:/${interceptionPrefix}${pattern})?`\n : `/${interceptionPrefix}${pattern}`,\n cleanedKey: cleanedKey,\n optional,\n repeat,\n }\n}\n\nfunction getNamedParametrizedRoute(\n route: string,\n prefixRouteKeys: boolean,\n includeSuffix: boolean,\n includePrefix: boolean,\n backreferenceDuplicateKeys: boolean,\n reference: RegexReference = { names: {}, intercepted: {} }\n) {\n const getSafeRouteKey = buildGetSafeRouteKey()\n const routeKeys: { [named: string]: string } = {}\n\n const segments: string[] = []\n const inverseParts: string[] = []\n\n // Ensure we don't mutate the original reference object.\n reference = structuredClone(reference)\n\n for (const segment of removeTrailingSlash(route).slice(1).split('/')) {\n const hasInterceptionMarker = INTERCEPTION_ROUTE_MARKERS.some((m) =>\n segment.startsWith(m)\n )\n\n const paramMatches = segment.match(PARAMETER_PATTERN) // Check for parameters\n\n const interceptionMarker = hasInterceptionMarker\n ? paramMatches?.[1]\n : undefined\n\n let keyPrefix: string | undefined\n if (interceptionMarker && paramMatches?.[2]) {\n keyPrefix = prefixRouteKeys ? NEXT_INTERCEPTION_MARKER_PREFIX : undefined\n reference.intercepted[paramMatches[2]] = interceptionMarker\n } else if (paramMatches?.[2] && reference.intercepted[paramMatches[2]]) {\n keyPrefix = prefixRouteKeys ? NEXT_INTERCEPTION_MARKER_PREFIX : undefined\n } else {\n keyPrefix = prefixRouteKeys ? NEXT_QUERY_PARAM_PREFIX : undefined\n }\n\n if (interceptionMarker && paramMatches && paramMatches[2]) {\n // If there's an interception marker, add it to the segments.\n const { key, pattern, cleanedKey, repeat, optional } =\n getSafeKeyFromSegment({\n getSafeRouteKey,\n interceptionMarker,\n segment: paramMatches[2],\n routeKeys,\n keyPrefix,\n backreferenceDuplicateKeys,\n })\n\n segments.push(pattern)\n inverseParts.push(\n `/${paramMatches[1]}:${reference.names[key] ?? cleanedKey}${repeat ? (optional ? '*' : '+') : ''}`\n )\n reference.names[key] ??= cleanedKey\n } else if (paramMatches && paramMatches[2]) {\n // If there's a prefix, add it to the segments if it's enabled.\n if (includePrefix && paramMatches[1]) {\n segments.push(`/${escapeStringRegexp(paramMatches[1])}`)\n inverseParts.push(`/${paramMatches[1]}`)\n }\n\n const { key, pattern, cleanedKey, repeat, optional } =\n getSafeKeyFromSegment({\n getSafeRouteKey,\n segment: paramMatches[2],\n routeKeys,\n keyPrefix,\n backreferenceDuplicateKeys,\n })\n\n // Remove the leading slash if includePrefix already added it.\n let s = pattern\n if (includePrefix && paramMatches[1]) {\n s = s.substring(1)\n }\n\n segments.push(s)\n inverseParts.push(\n `/:${reference.names[key] ?? cleanedKey}${repeat ? (optional ? '*' : '+') : ''}`\n )\n reference.names[key] ??= cleanedKey\n } else {\n segments.push(`/${escapeStringRegexp(segment)}`)\n inverseParts.push(`/${segment}`)\n }\n\n // If there's a suffix, add it to the segments if it's enabled.\n if (includeSuffix && paramMatches && paramMatches[3]) {\n segments.push(escapeStringRegexp(paramMatches[3]))\n inverseParts.push(paramMatches[3])\n }\n }\n\n return {\n namedParameterizedRoute: segments.join(''),\n routeKeys,\n pathToRegexpPattern: inverseParts.join(''),\n reference,\n }\n}\n\n/**\n * This function extends `getRouteRegex` generating also a named regexp where\n * each group is named along with a routeKeys object that indexes the assigned\n * named group with its corresponding key. When the routeKeys need to be\n * prefixed to uniquely identify internally the \"prefixRouteKey\" arg should\n * be \"true\" currently this is only the case when creating the routes-manifest\n * during the build\n */\nexport function getNamedRouteRegex(\n normalizedRoute: string,\n options: GetNamedRouteRegexOptions\n) {\n const result = getNamedParametrizedRoute(\n normalizedRoute,\n options.prefixRouteKeys,\n options.includeSuffix ?? false,\n options.includePrefix ?? false,\n options.backreferenceDuplicateKeys ?? false,\n options.reference\n )\n\n let namedRegex = result.namedParameterizedRoute\n if (!options.excludeOptionalTrailingSlash) {\n namedRegex += '(?:/)?'\n }\n\n return {\n ...getRouteRegex(normalizedRoute, options),\n namedRegex: `^${namedRegex}$`,\n routeKeys: result.routeKeys,\n pathToRegexpPattern: result.pathToRegexpPattern,\n reference: result.reference,\n }\n}\n\n/**\n * Generates a named regexp.\n * This is intended to be using for build time only.\n */\nexport function getNamedMiddlewareRegex(\n normalizedRoute: string,\n options: {\n catchAll?: boolean\n }\n) {\n const { parameterizedRoute } = getParametrizedRoute(\n normalizedRoute,\n false,\n false\n )\n const { catchAll = true } = options\n if (parameterizedRoute === '/') {\n let catchAllRegex = catchAll ? '.*' : ''\n return {\n namedRegex: `^/${catchAllRegex}$`,\n }\n }\n\n const { namedParameterizedRoute } = getNamedParametrizedRoute(\n normalizedRoute,\n false,\n false,\n false,\n false,\n undefined\n )\n let catchAllGroupedRegex = catchAll ? '(?:(/.*)?)' : ''\n return {\n namedRegex: `^${namedParameterizedRoute}${catchAllGroupedRegex}$`,\n }\n}\n"],"names":["getNamedMiddlewareRegex","getNamedRouteRegex","getRouteRegex","getParametrizedRoute","route","includeSuffix","includePrefix","groups","groupIndex","segments","segment","removeTrailingSlash","slice","split","markerMatch","INTERCEPTION_ROUTE_MARKERS","find","m","startsWith","paramMatches","match","PARAMETER_PATTERN","key","optional","repeat","parseMatchedParameter","pos","push","escapeStringRegexp","s","substring","parameterizedRoute","join","normalizedRoute","excludeOptionalTrailingSlash","re","RegExp","buildGetSafeRouteKey","i","routeKey","j","String","fromCharCode","Math","floor","getSafeKeyFromSegment","interceptionMarker","getSafeRouteKey","routeKeys","keyPrefix","backreferenceDuplicateKeys","cleanedKey","replace","invalidKey","length","isNaN","parseInt","duplicateKey","interceptionPrefix","pattern","getNamedParametrizedRoute","prefixRouteKeys","reference","names","intercepted","inverseParts","structuredClone","hasInterceptionMarker","some","undefined","NEXT_INTERCEPTION_MARKER_PREFIX","NEXT_QUERY_PARAM_PREFIX","namedParameterizedRoute","pathToRegexpPattern","options","result","namedRegex","catchAll","catchAllRegex","catchAllGroupedRegex"],"mappings":";;;;;;;;;;;;;;;IAwZgBA,uBAAuB,EAAA;eAAvBA;;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C3B,iBACA,OACA,OACA,OACA,OACAoC;IAEF,IAAIU,uBAAuBF,WAAW,eAAe;IACrD,OAAO;QACLD,YAAY,CAAC,CAAC,EAAEJ,0BAA0BO,qBAAqB,CAAC,CAAC;IACnE;AACF","ignoreList":[0]}},
32
- {"offset": {"line": 1946, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/interpolate-as.ts"],"sourcesContent":["import type { ParsedUrlQuery } from 'querystring'\n\nimport { getRouteMatcher } from './route-matcher'\nimport { getRouteRegex } from './route-regex'\n\nexport function interpolateAs(\n route: string,\n asPathname: string,\n query: ParsedUrlQuery\n) {\n let interpolatedRoute = ''\n\n const dynamicRegex = getRouteRegex(route)\n const dynamicGroups = dynamicRegex.groups\n const dynamicMatches =\n // Try to match the dynamic route against the asPath\n (asPathname !== route ? getRouteMatcher(dynamicRegex)(asPathname) : '') ||\n // Fall back to reading the values from the href\n // TODO: should this take priority; also need to change in the router.\n query\n\n interpolatedRoute = route\n const params = Object.keys(dynamicGroups)\n\n if (\n !params.every((param) => {\n let value = dynamicMatches[param] || ''\n const { repeat, optional } = dynamicGroups[param]\n\n // support single-level catch-all\n // TODO: more robust handling for user-error (passing `/`)\n let replaced = `[${repeat ? '...' : ''}${param}]`\n if (optional) {\n replaced = `${!value ? '/' : ''}[${replaced}]`\n }\n if (repeat && !Array.isArray(value)) value = [value]\n\n return (\n (optional || param in dynamicMatches) &&\n // Interpolate group into data URL if present\n (interpolatedRoute =\n interpolatedRoute!.replace(\n replaced,\n repeat\n ? (value as string[])\n .map(\n // these values should be fully encoded instead of just\n // path delimiter escaped since they are being inserted\n // into the URL and we expect URL encoded segments\n // when parsing dynamic route params\n (segment) => encodeURIComponent(segment)\n )\n .join('/')\n : encodeURIComponent(value as string)\n ) || '/')\n )\n })\n ) {\n interpolatedRoute = '' // did not satisfy all requirements\n\n // n.b. We ignore this error because we handle warning for this case in\n // development in the `<Link>` component directly.\n }\n return {\n params,\n result: interpolatedRoute,\n }\n}\n"],"names":["interpolateAs","route","asPathname","query","interpolatedRoute","dynamicRegex","getRouteRegex","dynamicGroups","groups","dynamicMatches","getRouteMatcher","params","Object","keys","every","param","value","repeat","optional","replaced","Array","isArray","replace","map","segment","encodeURIComponent","join","result"],"mappings":";;;+BAKgBA,iBAAAA;;;eAAAA;;;8BAHgB;4BACF;AAEvB,SAASA,cACdC,KAAa,EACbC,UAAkB,EAClBC,KAAqB;IAErB,IAAIC,oBAAoB;IAExB,MAAMC,eAAeC,CAAAA,GAAAA,YAAAA,aAAa,EAACL;IACnC,MAAMM,gBAAgBF,aAAaG,MAAM;IACzC,MAAMC,iBAEJ,AADA,AACCP,CAAAA,eAAeD,QAAQS,CAAAA,GAAAA,cAAAA,UAD4B,KACb,EAACL,cAAcH,cAAc,EAAC,KACrE,gDAAgD;IAChD,sEAAsE;IACtEC;IAEFC,oBAAoBH;IACpB,MAAMU,SAASC,OAAOC,IAAI,CAACN;IAE3B,IACE,CAACI,OAAOG,KAAK,CAAC,CAACC;QACb,IAAIC,QAAQP,cAAc,CAACM,MAAM,IAAI;QACrC,MAAM,EAAEE,MAAM,EAAEC,QAAQ,EAAE,GAAGX,aAAa,CAACQ,MAAM;QAEjD,iCAAiC;QACjC,0DAA0D;QAC1D,IAAII,WAAW,CAAC,CAAC,EAAEF,SAAS,QAAQ,KAAKF,MAAM,CAAC,CAAC;QACjD,IAAIG,UAAU;YACZC,WAAW,GAAG,CAACH,QAAQ,MAAM,GAAG,CAAC,EAAEG,SAAS,CAAC,CAAC;QAChD;QACA,IAAIF,UAAU,CAACG,MAAMC,OAAO,CAACL,QAAQA,QAAQ;YAACA;SAAM;QAEpD,OACGE,CAAAA,YAAYH,SAASN,cAAa,KACnC,6CAA6C;QAC5CL,CAAAA,oBACCA,kBAAmBkB,OAAO,CACxBH,UACAF,SACKD,MACEO,GAAG,CACF,AACA,uDADuD,AACA;QACvD,kDAAkD;QAClD,oCAAoC;QACpC,CAACC,UAAYC,mBAAmBD,UAEjCE,IAAI,CAAC,OACRD,mBAAmBT,WACpB,GAAE;IAEb,IACA;QACAZ,oBAAoB,GAAG,mCAAmC;;IAE1D,uEAAuE;IACvE,kDAAkD;IACpD;IACA,OAAO;QACLO;QACAgB,QAAQvB;IACV;AACF","ignoreList":[0]}},
33
- {"offset": {"line": 1998, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/get-asset-path-from-route.ts"],"sourcesContent":["// Translates a logical route into its pages asset path (relative from a common prefix)\n// \"asset path\" being its javascript file, data file, prerendered html,...\nexport default function getAssetPathFromRoute(\n route: string,\n ext: string = ''\n): string {\n const path =\n route === '/'\n ? '/index'\n : /^\\/index(\\/|$)/.test(route)\n ? `/index${route}`\n : route\n return path + ext\n}\n"],"names":["getAssetPathFromRoute","route","ext","path","test"],"mappings":"AAAA,uFAAuF;AACvF,0EAA0E;;;;+BAC1E,WAAA;;;eAAwBA;;;AAAT,SAASA,sBACtBC,KAAa,EACbC,MAAc,EAAE;IAEhB,MAAMC,OACJF,UAAU,MACN,WACA,iBAAiBG,IAAI,CAACH,SACpB,CAAC,MAAM,EAAEA,OAAO,GAChBA;IACR,OAAOE,OAAOD;AAChB","ignoreList":[0]}},
34
- {"offset": {"line": 2017, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/parse-relative-url.ts"],"sourcesContent":["import type { ParsedUrlQuery } from 'querystring'\nimport { getLocationOrigin } from '../../utils'\nimport { searchParamsToUrlQuery } from './querystring'\n\nexport interface ParsedRelativeUrl {\n auth: string | null\n hash: string\n host: string | null\n hostname: string | null\n href: string\n pathname: string\n port: string | null\n protocol: string | null\n query: ParsedUrlQuery\n search: string\n slashes: null\n}\n\n/**\n * Parses path-relative urls (e.g. `/hello/world?foo=bar`). If url isn't path-relative\n * (e.g. `./hello`) then at least base must be.\n * Absolute urls are rejected with one exception, in the browser, absolute urls that are on\n * the current origin will be parsed as relative\n */\nexport function parseRelativeUrl(\n url: string,\n base?: string,\n parseQuery?: true\n): ParsedRelativeUrl\nexport function parseRelativeUrl(\n url: string,\n base: string | undefined,\n parseQuery: false\n): Omit<ParsedRelativeUrl, 'query'>\nexport function parseRelativeUrl(\n url: string,\n base?: string,\n parseQuery = true\n): ParsedRelativeUrl | Omit<ParsedRelativeUrl, 'query'> {\n const globalBase = new URL(\n typeof window === 'undefined' ? 'http://n' : getLocationOrigin()\n )\n\n const resolvedBase = base\n ? new URL(base, globalBase)\n : url.startsWith('.')\n ? new URL(\n typeof window === 'undefined' ? 'http://n' : window.location.href\n )\n : globalBase\n\n const { pathname, searchParams, search, hash, href, origin } = url.startsWith(\n '/'\n )\n ? // 'http://localhost:3000///' would be received as '///' in Node.js' IncomingMessage\n // See https://nodejs.org/api/http.html#messageurl\n // Not using `origin` to support other protocols\n new URL(`${resolvedBase.protocol}//${resolvedBase.host}${url}`)\n : new URL(url, resolvedBase)\n\n if (origin !== globalBase.origin) {\n throw new Error(`invariant: invalid relative URL, router received ${url}`)\n }\n\n return {\n auth: null,\n host: null,\n hostname: null,\n pathname,\n port: null,\n protocol: null,\n query: parseQuery ? searchParamsToUrlQuery(searchParams) : undefined,\n search,\n hash,\n href: href.slice(origin.length),\n // We don't know for relative URLs at this point since we set a custom, internal\n // base that isn't surfaced to users.\n slashes: null,\n }\n}\n"],"names":["parseRelativeUrl","url","base","parseQuery","globalBase","URL","window","getLocationOrigin","resolvedBase","startsWith","location","href","pathname","searchParams","search","hash","origin","protocol","host","Error","auth","hostname","port","query","searchParamsToUrlQuery","undefined","slice","length","slashes"],"mappings":";;;+BAkCgBA,oBAAAA;;;eAAAA;;;uBAjCkB;6BACK;AAgChC,SAASA,iBACdC,GAAW,EACXC,IAAa,EACbC,aAAa,IAAI;IAEjB,MAAMC,aAAa,IAAIC,IACrB,OAAOC,WAAW,cAAc,aAAaC,CAAAA,GAAAA,OAAAA,iBAAiB;IAGhE,MAAMC,eAAeN,OACjB,IAAIG,IAAIH,MAAME,cACdH,IAAIQ,UAAU,CAAC,OACb,IAAIJ,IACF,OAAOC,WAAW,cAAc,aAAaA,OAAOI,QAAQ,CAACC,IAAI,IAEnEP;IAEN,MAAM,EAAEQ,QAAQ,EAAEC,YAAY,EAAEC,MAAM,EAAEC,IAAI,EAAEJ,IAAI,EAAEK,MAAM,EAAE,GAAGf,IAAIQ,UAAU,CAC3E,OAGE,AACA,gDAAgD,EADE;IAElD,IAAIJ,IAAI,GAAGG,aAAaS,QAAQ,CAAC,EAAE,EAAET,aAAaU,IAAI,GAAGjB,KAAK,IAC9D,IAAII,IAAIJ,KAAKO;IAEjB,IAAIQ,WAAWZ,WAAWY,MAAM,EAAE;QAChC,MAAM,OAAA,cAAoE,CAApE,IAAIG,MAAM,CAAC,iDAAiD,EAAElB,KAAK,GAAnE,qBAAA;mBAAA;wBAAA;0BAAA;QAAmE;IAC3E;IAEA,OAAO;QACLmB,MAAM;QACNF,MAAM;QACNG,UAAU;QACVT;QACAU,MAAM;QACNL,UAAU;QACVM,OAAOpB,aAAaqB,CAAAA,GAAAA,aAAAA,sBAAsB,EAACX,gBAAgBY;QAC3DX;QACAC;QACAJ,MAAMA,KAAKe,KAAK,CAACV,OAAOW,MAAM;QAC9B,gFAAgF;QAChF,qCAAqC;QACrCC,SAAS;IACX;AACF","ignoreList":[0]}},
35
- {"offset": {"line": 2060, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/encode-uri-path.ts"],"sourcesContent":["export function encodeURIPath(file: string) {\n return file\n .split('/')\n .map((p) => encodeURIComponent(p))\n .join('/')\n}\n"],"names":["encodeURIPath","file","split","map","p","encodeURIComponent","join"],"mappings":";;;+BAAgBA,iBAAAA;;;eAAAA;;;AAAT,SAASA,cAAcC,IAAY;IACxC,OAAOA,KACJC,KAAK,CAAC,KACNC,GAAG,CAAC,CAACC,IAAMC,mBAAmBD,IAC9BE,IAAI,CAAC;AACV","ignoreList":[0]}},
36
- {"offset": {"line": 2076, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/modern-browserslist-target.js"],"sourcesContent":["// Note: This file is JS because it's used by the taskfile-swc.js file, which is JS.\n// Keep file changes in sync with the corresponding `.d.ts` files.\n\n/**\n * These are the minimum browser versions that we consider \"modern\" and thus compile for by default.\n * This list was generated using `pnpm browserslist \"baseline widely available\"` on 2025-10-01.\n */\nconst MODERN_BROWSERSLIST_TARGET = [\n 'chrome 111',\n 'edge 111',\n 'firefox 111',\n 'safari 16.4',\n]\n\nmodule.exports = MODERN_BROWSERSLIST_TARGET\n"],"names":["MODERN_BROWSERSLIST_TARGET","module","exports"],"mappings":"AAAA,oFAAoF;AACpF,kEAAkE;AAElE;;;CAGC,GACD,MAAMA,6BAA6B;IACjC;IACA;IACA;IACA;CACD;AAEDC,OAAOC,OAAO,GAAGF","ignoreList":[0]}},
37
- {"offset": {"line": 2092, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/entry-constants.ts"],"sourcesContent":["export const UNDERSCORE_NOT_FOUND_ROUTE = '/_not-found'\nexport const UNDERSCORE_NOT_FOUND_ROUTE_ENTRY = `${UNDERSCORE_NOT_FOUND_ROUTE}/page`\nexport const UNDERSCORE_GLOBAL_ERROR_ROUTE = '/_global-error'\nexport const UNDERSCORE_GLOBAL_ERROR_ROUTE_ENTRY = `${UNDERSCORE_GLOBAL_ERROR_ROUTE}/page`\n"],"names":["UNDERSCORE_GLOBAL_ERROR_ROUTE","UNDERSCORE_GLOBAL_ERROR_ROUTE_ENTRY","UNDERSCORE_NOT_FOUND_ROUTE","UNDERSCORE_NOT_FOUND_ROUTE_ENTRY"],"mappings":";;;;;;;;;;;;;;;;IAEaA,6BAA6B,EAAA;eAA7BA;;IACAC,mCAAmC,EAAA;eAAnCA;;IAHAC,0BAA0B,EAAA;eAA1BA;;IACAC,gCAAgC,EAAA;eAAhCA;;;AADN,MAAMD,6BAA6B;AACnC,MAAMC,mCAAmC,GAAGD,2BAA2B,KAAK,CAAC;AAC7E,MAAMF,gCAAgC;AACtC,MAAMC,sCAAsC,GAAGD,8BAA8B,KAAK,CAAC","ignoreList":[0]}},
38
- {"offset": {"line": 2129, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/constants.ts"],"sourcesContent":["import MODERN_BROWSERSLIST_TARGET from './modern-browserslist-target'\n\nexport { MODERN_BROWSERSLIST_TARGET }\n\nexport type ValueOf<T> = Required<T>[keyof T]\n\nexport const COMPILER_NAMES = {\n client: 'client',\n server: 'server',\n edgeServer: 'edge-server',\n} as const\n\nexport type CompilerNameValues = ValueOf<typeof COMPILER_NAMES>\n\nexport const COMPILER_INDEXES: {\n [compilerKey in CompilerNameValues]: number\n} = {\n [COMPILER_NAMES.client]: 0,\n [COMPILER_NAMES.server]: 1,\n [COMPILER_NAMES.edgeServer]: 2,\n} as const\n\n// Re-export entry constants for backward compatibility\nexport {\n UNDERSCORE_NOT_FOUND_ROUTE,\n UNDERSCORE_NOT_FOUND_ROUTE_ENTRY,\n UNDERSCORE_GLOBAL_ERROR_ROUTE,\n UNDERSCORE_GLOBAL_ERROR_ROUTE_ENTRY,\n} from './entry-constants'\n\nexport enum AdapterOutputType {\n /**\n * `PAGES` represents all the React pages that are under `pages/`.\n */\n PAGES = 'PAGES',\n\n /**\n * `PAGES_API` represents all the API routes under `pages/api/`.\n */\n PAGES_API = 'PAGES_API',\n /**\n * `APP_PAGE` represents all the React pages that are under `app/` with the\n * filename of `page.{j,t}s{,x}`.\n */\n APP_PAGE = 'APP_PAGE',\n\n /**\n * `APP_ROUTE` represents all the API routes and metadata routes that are under `app/` with the\n * filename of `route.{j,t}s{,x}`.\n */\n APP_ROUTE = 'APP_ROUTE',\n\n /**\n * `PRERENDER` represents an ISR enabled route that might\n * have a seeded cache entry or fallback generated during build\n */\n PRERENDER = 'PRERENDER',\n\n /**\n * `STATIC_FILE` represents a static file (ie /_next/static)\n */\n STATIC_FILE = 'STATIC_FILE',\n\n /**\n * `MIDDLEWARE` represents the middleware output if present\n */\n MIDDLEWARE = 'MIDDLEWARE',\n}\n\nexport const PHASE_EXPORT = 'phase-export'\nexport const PHASE_ANALYZE = 'phase-analyze'\nexport const PHASE_PRODUCTION_BUILD = 'phase-production-build'\nexport const PHASE_PRODUCTION_SERVER = 'phase-production-server'\nexport const PHASE_DEVELOPMENT_SERVER = 'phase-development-server'\nexport const PHASE_TEST = 'phase-test'\nexport const PHASE_INFO = 'phase-info'\n\nexport type PHASE_TYPE =\n | typeof PHASE_INFO\n | typeof PHASE_TEST\n | typeof PHASE_EXPORT\n | typeof PHASE_ANALYZE\n | typeof PHASE_PRODUCTION_BUILD\n | typeof PHASE_PRODUCTION_SERVER\n | typeof PHASE_DEVELOPMENT_SERVER\n\nexport const PAGES_MANIFEST = 'pages-manifest.json'\nexport const APP_PATHS_MANIFEST = 'app-paths-manifest.json'\nexport const APP_PATH_ROUTES_MANIFEST = 'app-path-routes-manifest.json'\nexport const BUILD_MANIFEST = 'build-manifest.json'\nexport const FUNCTIONS_CONFIG_MANIFEST = 'functions-config-manifest.json'\nexport const SUBRESOURCE_INTEGRITY_MANIFEST = 'subresource-integrity-manifest'\nexport const NEXT_FONT_MANIFEST = 'next-font-manifest'\nexport const EXPORT_MARKER = 'export-marker.json'\nexport const EXPORT_DETAIL = 'export-detail.json'\nexport const PRERENDER_MANIFEST = 'prerender-manifest.json'\nexport const PREFETCH_HINTS = 'prefetch-hints.json'\nexport const ROUTES_MANIFEST = 'routes-manifest.json'\nexport const IMAGES_MANIFEST = 'images-manifest.json'\nexport const SERVER_FILES_MANIFEST = 'required-server-files'\nexport const DEV_CLIENT_PAGES_MANIFEST = '_devPagesManifest.json'\nexport const MIDDLEWARE_MANIFEST = 'middleware-manifest.json'\nexport const TURBOPACK_CLIENT_MIDDLEWARE_MANIFEST =\n '_clientMiddlewareManifest.js'\nexport const TURBOPACK_CLIENT_BUILD_MANIFEST = 'client-build-manifest.json'\nexport const DEV_CLIENT_MIDDLEWARE_MANIFEST = '_devMiddlewareManifest.json'\nexport const REACT_LOADABLE_MANIFEST = 'react-loadable-manifest.json'\nexport const SERVER_DIRECTORY = 'server'\nexport const CONFIG_FILES = [\n 'next.config.js',\n 'next.config.mjs',\n 'next.config.ts',\n // process.features can be undefined on Edge runtime\n // TODO: Remove `as any` once we bump @types/node to v22.10.0+\n ...((process?.features as any)?.typescript ? ['next.config.mts'] : []),\n]\nexport const BUILD_ID_FILE = 'BUILD_ID'\nexport const BLOCKED_PAGES = ['/_document', '/_app', '/_error']\nexport const CLIENT_PUBLIC_FILES_PATH = 'public'\nexport const CLIENT_STATIC_FILES_PATH = 'static'\nexport const STRING_LITERAL_DROP_BUNDLE = '__NEXT_DROP_CLIENT_FILE__'\nexport const NEXT_BUILTIN_DOCUMENT = '__NEXT_BUILTIN_DOCUMENT__'\nexport const BARREL_OPTIMIZATION_PREFIX = '__barrel_optimize__'\n\n// server/[entry]/page_client-reference-manifest.js\nexport const CLIENT_REFERENCE_MANIFEST = 'client-reference-manifest'\n// server/server-reference-manifest\nexport const SERVER_REFERENCE_MANIFEST = 'server-reference-manifest'\n// server/middleware-build-manifest.js\nexport const MIDDLEWARE_BUILD_MANIFEST = 'middleware-build-manifest'\n// server/middleware-react-loadable-manifest.js\nexport const MIDDLEWARE_REACT_LOADABLE_MANIFEST =\n 'middleware-react-loadable-manifest'\n// server/interception-route-rewrite-manifest.js\nexport const INTERCEPTION_ROUTE_REWRITE_MANIFEST =\n 'interception-route-rewrite-manifest'\n// server/dynamic-css-manifest.js\nexport const DYNAMIC_CSS_MANIFEST = 'dynamic-css-manifest'\n\n// static/runtime/main.js\nexport const CLIENT_STATIC_FILES_RUNTIME_MAIN = `main`\nexport const CLIENT_STATIC_FILES_RUNTIME_MAIN_APP = `${CLIENT_STATIC_FILES_RUNTIME_MAIN}-app`\n// next internal client components chunk for layouts\nexport const APP_CLIENT_INTERNALS = 'app-pages-internals'\n// static/runtime/react-refresh.js\nexport const CLIENT_STATIC_FILES_RUNTIME_REACT_REFRESH = `react-refresh`\n// static/runtime/webpack.js\nexport const CLIENT_STATIC_FILES_RUNTIME_WEBPACK = `webpack`\n// static/runtime/polyfills.js\nexport const CLIENT_STATIC_FILES_RUNTIME_POLYFILLS = 'polyfills'\nexport const CLIENT_STATIC_FILES_RUNTIME_POLYFILLS_SYMBOL = Symbol(\n CLIENT_STATIC_FILES_RUNTIME_POLYFILLS\n)\nexport const DEFAULT_RUNTIME_WEBPACK = 'webpack-runtime'\nexport const EDGE_RUNTIME_WEBPACK = 'edge-runtime-webpack'\nexport const STATIC_PROPS_ID = '__N_SSG'\nexport const SERVER_PROPS_ID = '__N_SSP'\nexport const DEFAULT_SERIF_FONT = {\n name: 'Times New Roman',\n xAvgCharWidth: 821,\n azAvgWidth: 854.3953488372093,\n unitsPerEm: 2048,\n}\nexport const DEFAULT_SANS_SERIF_FONT = {\n name: 'Arial',\n xAvgCharWidth: 904,\n azAvgWidth: 934.5116279069767,\n unitsPerEm: 2048,\n}\nexport const STATIC_STATUS_PAGES = ['/500']\nexport const TRACE_OUTPUT_VERSION = 1\n// in `MB`\nexport const TURBO_TRACE_DEFAULT_MEMORY_LIMIT = 6000\n\nexport const RSC_MODULE_TYPES = {\n client: 'client',\n server: 'server',\n} as const\n\n// comparing\n// https://nextjs.org/docs/api-reference/edge-runtime\n// with\n// https://nodejs.org/docs/latest/api/globals.html\nexport const EDGE_UNSUPPORTED_NODE_APIS = [\n 'clearImmediate',\n 'setImmediate',\n 'BroadcastChannel',\n 'ByteLengthQueuingStrategy',\n 'CompressionStream',\n 'CountQueuingStrategy',\n 'DecompressionStream',\n 'DomException',\n 'MessageChannel',\n 'MessageEvent',\n 'MessagePort',\n 'ReadableByteStreamController',\n 'ReadableStreamBYOBRequest',\n 'ReadableStreamDefaultController',\n 'TransformStreamDefaultController',\n 'WritableStreamDefaultController',\n]\n\nexport const SYSTEM_ENTRYPOINTS = new Set<string>([\n CLIENT_STATIC_FILES_RUNTIME_MAIN,\n CLIENT_STATIC_FILES_RUNTIME_REACT_REFRESH,\n CLIENT_STATIC_FILES_RUNTIME_MAIN_APP,\n])\n"],"names":["APP_CLIENT_INTERNALS","APP_PATHS_MANIFEST","APP_PATH_ROUTES_MANIFEST","AdapterOutputType","BARREL_OPTIMIZATION_PREFIX","BLOCKED_PAGES","BUILD_ID_FILE","BUILD_MANIFEST","CLIENT_PUBLIC_FILES_PATH","CLIENT_REFERENCE_MANIFEST","CLIENT_STATIC_FILES_PATH","CLIENT_STATIC_FILES_RUNTIME_MAIN","CLIENT_STATIC_FILES_RUNTIME_MAIN_APP","CLIENT_STATIC_FILES_RUNTIME_POLYFILLS","CLIENT_STATIC_FILES_RUNTIME_POLYFILLS_SYMBOL","CLIENT_STATIC_FILES_RUNTIME_REACT_REFRESH","CLIENT_STATIC_FILES_RUNTIME_WEBPACK","COMPILER_INDEXES","COMPILER_NAMES","CONFIG_FILES","DEFAULT_RUNTIME_WEBPACK","DEFAULT_SANS_SERIF_FONT","DEFAULT_SERIF_FONT","DEV_CLIENT_MIDDLEWARE_MANIFEST","DEV_CLIENT_PAGES_MANIFEST","DYNAMIC_CSS_MANIFEST","EDGE_RUNTIME_WEBPACK","EDGE_UNSUPPORTED_NODE_APIS","EXPORT_DETAIL","EXPORT_MARKER","FUNCTIONS_CONFIG_MANIFEST","IMAGES_MANIFEST","INTERCEPTION_ROUTE_REWRITE_MANIFEST","MIDDLEWARE_BUILD_MANIFEST","MIDDLEWARE_MANIFEST","MIDDLEWARE_REACT_LOADABLE_MANIFEST","MODERN_BROWSERSLIST_TARGET","NEXT_BUILTIN_DOCUMENT","NEXT_FONT_MANIFEST","PAGES_MANIFEST","PHASE_ANALYZE","PHASE_DEVELOPMENT_SERVER","PHASE_EXPORT","PHASE_INFO","PHASE_PRODUCTION_BUILD","PHASE_PRODUCTION_SERVER","PHASE_TEST","PREFETCH_HINTS","PRERENDER_MANIFEST","REACT_LOADABLE_MANIFEST","ROUTES_MANIFEST","RSC_MODULE_TYPES","SERVER_DIRECTORY","SERVER_FILES_MANIFEST","SERVER_PROPS_ID","SERVER_REFERENCE_MANIFEST","STATIC_PROPS_ID","STATIC_STATUS_PAGES","STRING_LITERAL_DROP_BUNDLE","SUBRESOURCE_INTEGRITY_MANIFEST","SYSTEM_ENTRYPOINTS","TRACE_OUTPUT_VERSION","TURBOPACK_CLIENT_BUILD_MANIFEST","TURBOPACK_CLIENT_MIDDLEWARE_MANIFEST","TURBO_TRACE_DEFAULT_MEMORY_LIMIT","UNDERSCORE_GLOBAL_ERROR_ROUTE","UNDERSCORE_GLOBAL_ERROR_ROUTE_ENTRY","UNDERSCORE_NOT_FOUND_ROUTE","UNDERSCORE_NOT_FOUND_ROUTE_ENTRY","client","server","edgeServer","process","features","typescript","Symbol","name","xAvgCharWidth","azAvgWidth","unitsPerEm","Set"],"mappings":"AAkHOwE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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AACjC,MAAMgD,6BAA6B;AACnC,MAAMrB,wBAAwB;AAC9B,MAAMjC,6BAA6B;AAGnC,MAAMK,4BAA4B;AAElC,MAAM8C,4BAA4B;AAElC,MAAMtB,4BAA4B;AAElC,MAAME,qCACX;AAEK,MAAMH,sCACX;AAEK,MAAMP,uBAAuB;AAG7B,MAAMd,mCAAmC,CAAC,IAAI,CAAC;AAC/C,MAAMC,uCAAuC,GAAGD,iCAAiC,IAAI,CAAC;AAEtF,MAAMX,uBAAuB;AAE7B,MAAMe,4CAA4C,CAAC,aAAa,CAAC;AAEjE,MAAMC,sCAAsC,CAAC,OAAO,CAAC;AAErD,MAAMH,wCAAwC;AAC9C,MAAMC,+CAA+C6D,OAC1D9D;AAEK,MAAMO,0BAA0B;AAChC,MAAMM,uBAAuB;AAC7B,MAAM8B,kBAAkB;AACxB,MAAMF,kBAAkB;AACxB,MAAMhC,qBAAqB;IAChCsD,MAAM;IACNC,eAAe;IACfC,YAAY;IACZC,YAAY;AACd;AACO,MAAM1D,0BAA0B;IACrCuD,MAAM;IACNC,eAAe;IACfC,YAAY;IACZC,YAAY;AACd;AACO,MAAMtB,sBAAsB;IAAC;CAAO;AACpC,MAAMI,uBAAuB;AAE7B,MAAMG,mCAAmC;AAEzC,MAAMb,mBAAmB;IAC9BkB,QAAQ;IACRC,QAAQ;AACV;AAMO,MAAM3C,6BAA6B;IACxC;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;CACD;AAEM,MAAMiC,qBAAqB,IAAIoB,IAAY;IAChDrE;IACAI;IACAH;CACD","ignoreList":[0]}},
39
- {"offset": {"line": 2581, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/bloom-filter.ts"],"sourcesContent":["// minimal implementation MurmurHash2 hash function\nfunction murmurhash2(str: string) {\n let h = 0\n for (let i = 0; i < str.length; i++) {\n const c = str.charCodeAt(i)\n h = Math.imul(h ^ c, 0x5bd1e995)\n h ^= h >>> 13\n h = Math.imul(h, 0x5bd1e995)\n }\n return h >>> 0\n}\n\n// default to 0.01% error rate as the filter compresses very well\nconst DEFAULT_ERROR_RATE = 0.0001\n\nexport class BloomFilter {\n numItems: number\n errorRate: number\n numBits: number\n numHashes: number\n bitArray: number[]\n\n constructor(numItems: number, errorRate: number = DEFAULT_ERROR_RATE) {\n this.numItems = numItems\n this.errorRate = errorRate\n this.numBits = Math.ceil(\n -(numItems * Math.log(errorRate)) / (Math.log(2) * Math.log(2))\n )\n this.numHashes = Math.ceil((this.numBits / numItems) * Math.log(2))\n this.bitArray = new Array(this.numBits).fill(0)\n }\n\n static from(items: string[], errorRate = DEFAULT_ERROR_RATE) {\n const filter = new BloomFilter(items.length, errorRate)\n\n for (const item of items) {\n filter.add(item)\n }\n return filter\n }\n\n export() {\n const data = {\n numItems: this.numItems,\n errorRate: this.errorRate,\n numBits: this.numBits,\n numHashes: this.numHashes,\n bitArray: this.bitArray,\n }\n\n if (process.env.NEXT_RUNTIME === 'nodejs') {\n if (this.errorRate < DEFAULT_ERROR_RATE) {\n const filterData = JSON.stringify(data)\n const gzipSize = (\n require('next/dist/compiled/gzip-size') as typeof import('next/dist/compiled/gzip-size')\n ).sync(filterData)\n\n if (gzipSize > 1024) {\n console.warn(\n `Creating filter with error rate less than 0.1% (0.001) can increase the size dramatically proceed with caution. Received error rate ${this.errorRate} resulted in size ${filterData.length} bytes, ${gzipSize} bytes (gzip)`\n )\n }\n }\n }\n\n return data\n }\n\n import(data: ReturnType<(typeof this)['export']>) {\n this.numItems = data.numItems\n this.errorRate = data.errorRate\n this.numBits = data.numBits\n this.numHashes = data.numHashes\n this.bitArray = data.bitArray\n }\n\n add(item: string) {\n const hashValues = this.getHashValues(item)\n hashValues.forEach((hash) => {\n this.bitArray[hash] = 1\n })\n }\n\n contains(item: string) {\n const hashValues = this.getHashValues(item)\n return hashValues.every((hash) => this.bitArray[hash])\n }\n\n getHashValues(item: string) {\n const hashValues = []\n for (let i = 1; i <= this.numHashes; i++) {\n const hash = murmurhash2(`${item}${i}`) % this.numBits\n hashValues.push(hash)\n }\n return hashValues\n }\n}\n"],"names":["BloomFilter","murmurhash2","str","h","i","length","c","charCodeAt","Math","imul","DEFAULT_ERROR_RATE","constructor","numItems","errorRate","numBits","ceil","log","numHashes","bitArray","Array","fill","from","items","filter","item","add","export","data","process","env","NEXT_RUNTIME","filterData","JSON","stringify","gzipSize","require","sync","console","warn","import","hashValues","getHashValues","forEach","hash","contains","every","push"],"mappings":"AAkDQ4B,QAAQC,GAAG,CAACC,YAAY,KAAK,UAAU;AAlD/C,mDAAmD;;;;;+BAetC9B,eAAAA;;;eAAAA;;;AAdb,SAASC,YAAYC,GAAW;IAC9B,IAAIC,IAAI;IACR,IAAK,IAAIC,IAAI,GAAGA,IAAIF,IAAIG,MAAM,EAAED,IAAK;QACnC,MAAME,IAAIJ,IAAIK,UAAU,CAACH;QACzBD,IAAIK,KAAKC,IAAI,CAACN,IAAIG,GAAG;QACrBH,KAAKA,MAAM;QACXA,IAAIK,KAAKC,IAAI,CAACN,GAAG;IACnB;IACA,OAAOA,MAAM;AACf;AAEA,iEAAiE;AACjE,MAAMO,qBAAqB;AAEpB,MAAMV;IAOXW,YAAYC,QAAgB,EAAEC,YAAoBH,kBAAkB,CAAE;QACpE,IAAI,CAACE,QAAQ,GAAGA;QAChB,IAAI,CAACC,SAAS,GAAGA;QACjB,IAAI,CAACC,OAAO,GAAGN,KAAKO,IAAI,CACtB,CAAEH,CAAAA,WAAWJ,KAAKQ,GAAG,CAACH,UAAS,IAAML,CAAAA,KAAKQ,GAAG,CAAC,KAAKR,KAAKQ,GAAG,CAAC,EAAC;QAE/D,IAAI,CAACC,SAAS,GAAGT,KAAKO,IAAI,CAAE,IAAI,CAACD,OAAO,GAAGF,WAAYJ,KAAKQ,GAAG,CA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MuC,OAAO1C,YAAY,GAAGuB,OAAOpB,GAAG,IAAI,IAAI,CAACU,OAAO;YACtD0B,WAAWM,IAAI,CAACH;QAClB;QACA,OAAOH;IACT;AACF","ignoreList":[0]}},
40
- {"offset": {"line": 2662, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/is-plain-object.ts"],"sourcesContent":["export function getObjectClassLabel(value: any): string {\n return Object.prototype.toString.call(value)\n}\n\nexport function isPlainObject(value: any): boolean {\n if (getObjectClassLabel(value) !== '[object Object]') {\n return false\n }\n\n const prototype = Object.getPrototypeOf(value)\n\n /**\n * this used to be previously:\n *\n * `return prototype === null || prototype === Object.prototype`\n *\n * but Edge Runtime expose Object from vm, being that kind of type-checking wrongly fail.\n *\n * It was changed to the current implementation since it's resilient to serialization.\n */\n return prototype === null || prototype.hasOwnProperty('isPrototypeOf')\n}\n"],"names":["getObjectClassLabel","isPlainObject","value","Object","prototype","toString","call","getPrototypeOf","hasOwnProperty"],"mappings":";;;;;;;;;;;;;;IAAgBA,mBAAmB,EAAA;eAAnBA;;IAIAC,aAAa,EAAA;eAAbA;;;AAJT,SAASD,oBAAoBE,KAAU;IAC5C,OAAOC,OAAOC,SAAS,CAACC,QAAQ,CAACC,IAAI,CAACJ;AACxC;AAEO,SAASD,cAAcC,KAAU;IACtC,IAAIF,oBAAoBE,WAAW,mBAAmB;QACpD,OAAO;IACT;IAEA,MAAME,YAAYD,OAAOI,cAAc,CAACL;IAExC;;;;;;;;GAQC,GACD,OAAOE,cAAc,QAAQA,UAAUI,cAAc,CAAC;AACxD","ignoreList":[0]}},
41
- {"offset": {"line": 2705, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/sorted-routes.ts"],"sourcesContent":["class UrlNode {\n placeholder: boolean = true\n children: Map<string, UrlNode> = new Map()\n slugName: string | null = null\n restSlugName: string | null = null\n optionalRestSlugName: string | null = null\n\n insert(urlPath: string): void {\n this._insert(urlPath.split('/').filter(Boolean), [], false)\n }\n\n smoosh(): string[] {\n return this._smoosh()\n }\n\n private _smoosh(prefix: string = '/'): string[] {\n const childrenPaths = [...this.children.keys()].sort()\n if (this.slugName !== null) {\n childrenPaths.splice(childrenPaths.indexOf('[]'), 1)\n }\n if (this.restSlugName !== null) {\n childrenPaths.splice(childrenPaths.indexOf('[...]'), 1)\n }\n if (this.optionalRestSlugName !== null) {\n childrenPaths.splice(childrenPaths.indexOf('[[...]]'), 1)\n }\n\n const routes = childrenPaths\n .map((c) => this.children.get(c)!._smoosh(`${prefix}${c}/`))\n .reduce((prev, curr) => [...prev, ...curr], [])\n\n if (this.slugName !== null) {\n routes.push(\n ...this.children.get('[]')!._smoosh(`${prefix}[${this.slugName}]/`)\n )\n }\n\n if (!this.placeholder) {\n const r = prefix === '/' ? '/' : prefix.slice(0, -1)\n if (this.optionalRestSlugName != null) {\n throw new Error(\n `You cannot define a route with the same specificity as a optional catch-all route (\"${r}\" and \"${r}[[...${this.optionalRestSlugName}]]\").`\n )\n }\n\n routes.unshift(r)\n }\n\n if (this.restSlugName !== null) {\n routes.push(\n ...this.children\n .get('[...]')!\n ._smoosh(`${prefix}[...${this.restSlugName}]/`)\n )\n }\n\n if (this.optionalRestSlugName !== null) {\n routes.push(\n ...this.children\n .get('[[...]]')!\n ._smoosh(`${prefix}[[...${this.optionalRestSlugName}]]/`)\n )\n }\n\n return routes\n }\n\n private _insert(\n urlPaths: string[],\n slugNames: string[],\n isCatchAll: boolean\n ): void {\n if (urlPaths.length === 0) {\n this.placeholder = false\n return\n }\n\n if (isCatchAll) {\n throw new Error(`Catch-all must be the last part of the URL.`)\n }\n\n // The next segment in the urlPaths list\n let nextSegment = urlPaths[0]\n\n // Check if the segment matches `[something]`\n if (nextSegment.startsWith('[') && nextSegment.endsWith(']')) {\n // Strip `[` and `]`, leaving only `something`\n let segmentName = nextSegment.slice(1, -1)\n\n let isOptional = false\n if (segmentName.startsWith('[') && segmentName.endsWith(']')) {\n // Strip optional `[` and `]`, leaving only `something`\n segmentName = segmentName.slice(1, -1)\n isOptional = true\n }\n\n if (segmentName.startsWith('…')) {\n throw new Error(\n `Detected a three-dot character ('…') at ('${segmentName}'). Did you mean ('...')?`\n )\n }\n\n if (segmentName.startsWith('...')) {\n // Strip `...`, leaving only `something`\n segmentName = segmentName.substring(3)\n isCatchAll = true\n }\n\n if (segmentName.startsWith('[') || segmentName.endsWith(']')) {\n throw new Error(\n `Segment names may not start or end with extra brackets ('${segmentName}').`\n )\n }\n\n if (segmentName.startsWith('.')) {\n throw new Error(\n `Segment names may not start with erroneous periods ('${segmentName}').`\n )\n }\n\n function handleSlug(previousSlug: string | null, nextSlug: string) {\n if (previousSlug !== null) {\n // If the specific segment already has a slug but the slug is not `something`\n // This prevents collisions like:\n // pages/[post]/index.js\n // pages/[id]/index.js\n // Because currently multiple dynamic params on the same segment level are not supported\n if (previousSlug !== nextSlug) {\n // TODO: This error seems to be confusing for users, needs an error link, the description can be based on above comment.\n throw new Error(\n `You cannot use different slug names for the same dynamic path ('${previousSlug}' !== '${nextSlug}').`\n )\n }\n }\n\n slugNames.forEach((slug) => {\n if (slug === nextSlug) {\n throw new Error(\n `You cannot have the same slug name \"${nextSlug}\" repeat within a single dynamic path`\n )\n }\n\n if (slug.replace(/\\W/g, '') === nextSegment.replace(/\\W/g, '')) {\n throw new Error(\n `You cannot have the slug names \"${slug}\" and \"${nextSlug}\" differ only by non-word symbols within a single dynamic path`\n )\n }\n })\n\n slugNames.push(nextSlug)\n }\n\n if (isCatchAll) {\n if (isOptional) {\n if (this.restSlugName != null) {\n throw new Error(\n `You cannot use both an required and optional catch-all route at the same level (\"[...${this.restSlugName}]\" and \"${urlPaths[0]}\" ).`\n )\n }\n\n handleSlug(this.optionalRestSlugName, segmentName)\n // slugName is kept as it can only be one particular slugName\n this.optionalRestSlugName = segmentName\n // nextSegment is overwritten to [[...]] so that it can later be sorted specifically\n nextSegment = '[[...]]'\n } else {\n if (this.optionalRestSlugName != null) {\n throw new Error(\n `You cannot use both an optional and required catch-all route at the same level (\"[[...${this.optionalRestSlugName}]]\" and \"${urlPaths[0]}\").`\n )\n }\n\n handleSlug(this.restSlugName, segmentName)\n // slugName is kept as it can only be one particular slugName\n this.restSlugName = segmentName\n // nextSegment is overwritten to [...] so that it can later be sorted specifically\n nextSegment = '[...]'\n }\n } else {\n if (isOptional) {\n throw new Error(\n `Optional route parameters are not yet supported (\"${urlPaths[0]}\").`\n )\n }\n handleSlug(this.slugName, segmentName)\n // slugName is kept as it can only be one particular slugName\n this.slugName = segmentName\n // nextSegment is overwritten to [] so that it can later be sorted specifically\n nextSegment = '[]'\n }\n }\n\n // If this UrlNode doesn't have the nextSegment yet we create a new child UrlNode\n if (!this.children.has(nextSegment)) {\n this.children.set(nextSegment, new UrlNode())\n }\n\n this.children\n .get(nextSegment)!\n ._insert(urlPaths.slice(1), slugNames, isCatchAll)\n }\n}\n\n/**\n * @deprecated Use `sortSortableRoutes` or `sortPages` instead.\n */\nexport function getSortedRoutes(\n normalizedPages: ReadonlyArray<string>\n): string[] {\n // First the UrlNode is created, and every UrlNode can have only 1 dynamic segment\n // Eg you can't have pages/[post]/abc.js and pages/[hello]/something-else.js\n // Only 1 dynamic segment per nesting level\n\n // So in the case that is test/integration/dynamic-routing it'll be this:\n // pages/[post]/comments.js\n // pages/blog/[post]/comment/[id].js\n // Both are fine because `pages/[post]` and `pages/blog` are on the same level\n // So in this case `UrlNode` created here has `this.slugName === 'post'`\n // And since your PR passed through `slugName` as an array basically it'd including it in too many possibilities\n // Instead what has to be passed through is the upwards path's dynamic names\n const root = new UrlNode()\n\n // Here the `root` gets injected multiple paths, and insert will break them up into sublevels\n normalizedPages.forEach((pagePath) => root.insert(pagePath))\n // Smoosh will then sort those sublevels up to the point where you get the correct route definition priority\n return root.smoosh()\n}\n\n/**\n * @deprecated Use `sortSortableRouteObjects` or `sortPageObjects` instead.\n */\nexport function getSortedRouteObjects<T>(\n objects: T[],\n getter: (obj: T) => string\n): T[] {\n // We're assuming here that all the pathnames are unique, that way we can\n // sort the list and use the index as the key.\n const indexes: Record<string, number> = {}\n const pathnames: string[] = []\n for (let i = 0; i < objects.length; i++) {\n const pathname = getter(objects[i])\n indexes[pathname] = i\n pathnames[i] = pathname\n }\n\n // Sort the pathnames.\n const sorted = getSortedRoutes(pathnames)\n\n // Map the sorted pathnames back to the original objects using the new sorted\n // index.\n return sorted.map((pathname) => objects[indexes[pathname]])\n}\n"],"names":["getSortedRouteObjects","getSortedRoutes","UrlNode","insert","urlPath","_insert","split","filter","Boolean","smoosh","_smoosh","prefix","childrenPaths","children","keys","sort","slugName","splice","indexOf","restSlugName","optionalRestSlugName","routes","map","c","get","reduce","prev","curr","push","placeholder","r","slice","Error","unshift","urlPaths","slugNames","isCatchAll","length","nextSegment","startsWith","endsWith","segmentName","isOptional","substring","handleSlug","previousSlug","nextSlug","forEach","slug","replace","has","set","Map","normalizedPages","root","pagePath","objects","getter","indexes","pathnames","i","pathname","sorted"],"mappings":";;;;;;;;;;;;;;IAuOgBA,qBAAqB,EAAA;eAArBA;;IAzBAC,eAAe,EAAA;eAAfA;;;AA9MhB,MAAMC;IAOJC,OAAOC,OAAe,EAAQ;QAC5B,IAAI,CAACC,OAAO,CAACD,QAAQE,KAAK,CAAC,KAAKC,MAAM,CAACC,UAAU,EAAE,EAAE;IACvD;IAEAC,SAAmB;QACjB,OAAO,IAAI,CAACC,OAAO;IACrB;IAEQA,QAAQC,SAAiB,GAAG,EAAY;QAC9C,MAAMC,gBAAgB;eAAI,IAAI,CAACC,QAAQ,CAACC,IAAI;SAAG,CAACC,IAAI;QACpD,IAAI,IAAI,CAACC,QAAQ,KAAK,MAAM;YAC1BJ,cAAc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QAAAA,GAAiC,IAAIuC;aACrCpC,QAAAA,GAA0B;aAC1BG,YAAAA,GAA8B;aAC9BC,oBAAAA,GAAsC;;AAoMxC;AAKO,SAASnB,gBACdoD,eAAsC;IAEtC,kFAAkF;IAClF,4EAA4E;IAC5E,2CAA2C;IAE3C,yEAAyE;IACzE,2BAA2B;IAC3B,oCAAoC;IACpC,8EAA8E;IAC9E,wEAAwE;IACxE,gHAAgH;IAChH,4EAA4E;IAC5E,MAAMC,OAAO,IAAIpD;IAEjB,6FAA6F;IAC7FmD,gBAAgBN,OAAO,CAAC,CAACQ,WAAaD,KAAKnD,MAAM,CAACoD;IAClD,4GAA4G;IAC5G,OAAOD,KAAK7C,MAAM;AACpB;AAKO,SAAST,sBACdwD,OAAY,EACZC,MAA0B;IAE1B,yEAAyE;IACzE,8CAA8C;IAC9C,MAAMC,UAAkC,CAAC;IACzC,MAAMC,YAAsB,EAAE;IAC9B,IAAK,IAAIC,IAAI,GAAGA,IAAIJ,QAAQnB,MAAM,EAAEuB,IAAK;QACvC,MAAMC,WAAWJ,OAAOD,OAAO,CAACI,EAAE;QAClCF,OAAO,CAACG,SAAS,GAAGD;QACpBD,SAAS,CAACC,EAAE,GAAGC;IACjB;IAEA,sBAAsB;IACtB,MAAMC,SAAS7D,gBAAgB0D;IAE/B,6EAA6E;IAC7E,SAAS;IACT,OAAOG,OAAOxC,GAAG,CAAC,CAACuC,WAAaL,OAAO,CAACE,OAAO,CAACG,SAAS,CAAC;AAC5D","ignoreList":[0]}},
42
- {"offset": {"line": 2950, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/index.ts"],"sourcesContent":["export { getSortedRoutes, getSortedRouteObjects } from './sorted-routes'\nexport { isDynamicRoute } from './is-dynamic'\n"],"names":["getSortedRouteObjects","getSortedRoutes","isDynamicRoute"],"mappings":";;;;;;;;;;;;;;;IAA0BA,qBAAqB,EAAA;eAArBA,cAAAA,qBAAqB;;IAAtCC,eAAe,EAAA;eAAfA,cAAAA,eAAe;;IACfC,cAAc,EAAA;eAAdA,WAAAA,cAAc;;;8BADgC;2BACxB","ignoreList":[0]}},
43
- {"offset": {"line": 2981, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/page-path/normalize-path-sep.ts"],"sourcesContent":["/**\n * For a given page path, this function ensures that there is no backslash\n * escaping slashes in the path. Example:\n * - `foo\\/bar\\/baz` -> `foo/bar/baz`\n */\nexport function normalizePathSep(path: string): string {\n return path.replace(/\\\\/g, '/')\n}\n"],"names":["normalizePathSep","path","replace"],"mappings":"AAAA;;;;CAIC;;;+BACeA,oBAAAA;;;eAAAA;;;AAAT,SAASA,iBAAiBC,IAAY;IAC3C,OAAOA,KAAKC,OAAO,CAAC,OAAO;AAC7B","ignoreList":[0]}},
44
- {"offset": {"line": 3001, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/page-path/denormalize-page-path.ts"],"sourcesContent":["import { isDynamicRoute } from '../router/utils'\nimport { normalizePathSep } from './normalize-path-sep'\n\n/**\n * Performs the opposite transformation of `normalizePagePath`. Note that\n * this function is not idempotent either in cases where there are multiple\n * leading `/index` for the page. Examples:\n * - `/index` -> `/`\n * - `/index/foo` -> `/foo`\n * - `/index/index` -> `/index`\n */\nexport function denormalizePagePath(page: string) {\n let _page = normalizePathSep(page)\n return _page.startsWith('/index/') && !isDynamicRoute(_page)\n ? _page.slice(6)\n : _page !== '/index'\n ? _page\n : '/'\n}\n"],"names":["denormalizePagePath","page","_page","normalizePathSep","startsWith","isDynamicRoute","slice"],"mappings":";;;+BAWgBA,uBAAAA;;;eAAAA;;;uBAXe;kCACE;AAU1B,SAASA,oBAAoBC,IAAY;IAC9C,IAAIC,QAAQC,CAAAA,GAAAA,kBAAAA,gBAAgB,EAACF;IAC7B,OAAOC,MAAME,UAAU,CAAC,cAAc,CAACC,CAAAA,GAAAA,OAAAA,cAAc,EAACH,SAClDA,MAAMI,KAAK,CAAC,KACZJ,UAAU,WACRA,QACA;AACR","ignoreList":[0]}},
45
- {"offset": {"line": 3020, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/i18n/normalize-locale-path.ts"],"sourcesContent":["export interface PathLocale {\n detectedLocale?: string\n pathname: string\n}\n\n/**\n * A cache of lowercased locales for each list of locales. This is stored as a\n * WeakMap so if the locales are garbage collected, the cache entry will be\n * removed as well.\n */\nconst cache = new WeakMap<readonly string[], readonly string[]>()\n\n/**\n * For a pathname that may include a locale from a list of locales, it\n * removes the locale from the pathname returning it alongside with the\n * detected locale.\n *\n * @param pathname A pathname that may include a locale.\n * @param locales A list of locales.\n * @returns The detected locale and pathname without locale\n */\nexport function normalizeLocalePath(\n pathname: string,\n locales?: readonly string[]\n): PathLocale {\n // If locales is undefined, return the pathname as is.\n if (!locales) return { pathname }\n\n // Get the cached lowercased locales or create a new cache entry.\n let lowercasedLocales = cache.get(locales)\n if (!lowercasedLocales) {\n lowercasedLocales = locales.map((locale) => locale.toLowerCase())\n cache.set(locales, lowercasedLocales)\n }\n\n let detectedLocale: string | undefined\n\n // The first segment will be empty, because it has a leading `/`. If\n // there is no further segment, there is no locale (or it's the default).\n const segments = pathname.split('/', 2)\n\n // If there's no second segment (ie, the pathname is just `/`), there's no\n // locale.\n if (!segments[1]) return { pathname }\n\n // The second segment will contain the locale part if any.\n const segment = segments[1].toLowerCase()\n\n // See if the segment matches one of the locales. If it doesn't, there is\n // no locale (or it's the default).\n const index = lowercasedLocales.indexOf(segment)\n if (index < 0) return { pathname }\n\n // Return the case-sensitive locale.\n detectedLocale = locales[index]\n\n // Remove the `/${locale}` part of the pathname.\n pathname = pathname.slice(detectedLocale.length + 1) || '/'\n\n return { pathname, detectedLocale }\n}\n"],"names":["normalizeLocalePath","cache","WeakMap","pathname","locales","lowercasedLocales","get","map","locale","toLowerCase","set","detectedLocale","segments","split","segment","index","indexOf","slice","length"],"mappings":";;;+BAqBgBA,uBAAAA;;;eAAAA;;;AAhBhB;;;;CAIC,GACD,MAAMC,QAAQ,IAAIC;AAWX,SAASF,oBACdG,QAAgB,EAChBC,OAA2B;IAE3B,sDAAsD;IACtD,IAAI,CAACA,SAAS,OAAO;QAAED;IAAS;IAEhC,iEAAiE;IACjE,IAAIE,oBAAoBJ,MAAMK,GAAG,CAACF;IAClC,IAAI,CAACC,mBAAmB;QACtBA,oBAAoBD,QAAQG,GAAG,CAAC,CAACC,SAAWA,OAAOC,WAAW;QAC9DR,MAAMS,GAAG,CAACN,SAASC;IACrB;IAEA,IAAIM;IAEJ,oEAAoE;IACpE,yEAAyE;IACzE,MAAMC,WAAWT,SAASU,KAAK,CAAC,KAAK;IAErC,0EAA0E;IAC1E,UAAU;IACV,IAAI,CAACD,QAAQ,CAAC,EAAE,EAAE,OAAO;QAAET;IAAS;IAEpC,0DAA0D;IAC1D,MAAMW,UAAUF,QAAQ,CAAC,EAAE,CAACH,WAAW;IAEvC,yEAAyE;IACzE,mCAAmC;IACnC,MAAMM,QAAQV,kBAAkBW,OAAO,CAACF;IACxC,IAAIC,QAAQ,GAAG,OAAO;QAAEZ;IAAS;IAEjC,oCAAoC;IACpCQ,iBAAiBP,OAAO,CAACW,MAAM;IAE/B,gDAAgD;IAChDZ,WAAWA,SAASc,KAAK,CAACN,eAAeO,MAAM,GAAG,MAAM;IAExD,OAAO;QAAEf;QAAUQ;IAAe;AACpC","ignoreList":[0]}},
46
- {"offset": {"line": 3075, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/format-url.ts"],"sourcesContent":["// Format function modified from nodejs\n// Copyright Joyent, Inc. and other Node contributors.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a\n// copy of this software and associated documentation files (the\n// \"Software\"), to deal in the Software without restriction, including\n// without limitation the rights to use, copy, modify, merge, publish,\n// distribute, sublicense, and/or sell copies of the Software, and to permit\n// persons to whom the Software is furnished to do so, subject to the\n// following conditions:\n//\n// The above copyright notice and this permission notice shall be included\n// in all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS\n// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\n// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN\n// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR\n// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE\n// USE OR OTHER DEALINGS IN THE SOFTWARE.\n\nimport type { UrlObject } from 'url'\nimport type { ParsedUrlQuery } from 'querystring'\nimport * as querystring from './querystring'\n\nconst slashedProtocols = /https?|ftp|gopher|file/\n\nexport function formatUrl(urlObj: UrlObject) {\n let { auth, hostname } = urlObj\n let protocol = urlObj.protocol || ''\n let pathname = urlObj.pathname || ''\n let hash = urlObj.hash || ''\n let query = urlObj.query || ''\n let host: string | false = false\n\n auth = auth ? encodeURIComponent(auth).replace(/%3A/i, ':') + '@' : ''\n\n if (urlObj.host) {\n host = auth + urlObj.host\n } else if (hostname) {\n host = auth + (~hostname.indexOf(':') ? `[${hostname}]` : hostname)\n if (urlObj.port) {\n host += ':' + urlObj.port\n }\n }\n\n if (query && typeof query === 'object') {\n query = String(querystring.urlQueryToSearchParams(query as ParsedUrlQuery))\n }\n\n let search = urlObj.search || (query && `?${query}`) || ''\n\n if (protocol && !protocol.endsWith(':')) protocol += ':'\n\n if (\n urlObj.slashes ||\n ((!protocol || slashedProtocols.test(protocol)) && host !== false)\n ) {\n host = '//' + (host || '')\n if (pathname && pathname[0] !== '/') pathname = '/' + pathname\n } else if (!host) {\n host = ''\n }\n\n if (hash && hash[0] !== '#') hash = '#' + hash\n if (search && search[0] !== '?') search = '?' + search\n\n pathname = pathname.replace(/[?#]/g, encodeURIComponent)\n search = search.replace('#', '%23')\n\n return `${protocol}${host}${pathname}${search}${hash}`\n}\n\nexport const urlObjectKeys = [\n 'auth',\n 'hash',\n 'host',\n 'hostname',\n 'href',\n 'path',\n 'pathname',\n 'port',\n 'protocol',\n 'query',\n 'search',\n 'slashes',\n]\n\nexport function formatWithValidation(url: UrlObject): string {\n if (process.env.NODE_ENV === 'development') {\n if (url !== null && typeof url === 'object') {\n Object.keys(url).forEach((key) => {\n if (!urlObjectKeys.includes(key)) {\n console.warn(\n `Unknown key passed via urlObject into url.format: ${key}`\n )\n }\n })\n }\n }\n\n return formatUrl(url)\n}\n"],"names":["formatUrl","formatWithValidation","urlObjectKeys","slashedProtocols","urlObj","auth","hostname","protocol","pathname","hash","query","host","encodeURIComponent","replace","indexOf","port","String","querystring","urlQueryToSearchParams","search","endsWith","slashes","test","url","process","env","NODE_ENV","Object","keys","forEach","key","includes","console","warn"],"mappings":"AA0FMwB,QAAQC,GAAG,CAACC,QAAQ,KAAK;AA1F/B,uCAAuC;AACvC,sDAAsD;AACtD,EAAE;AACF,0EAA0E;AAC1E,gEAAgE;AAChE,sEAAsE;AACtE,sEAAsE;AACtE,4EAA4E;AAC5E,qEAAqE;AACrE,wBAAwB;AACxB,EAAE;AACF,0EAA0E;AAC1E,y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AA,QAAQ,EAAC;QACxB,IAAIH,YAAYA,QAAQ,CAAC,EAAE,KAAK,KAAKA,WAAW,MAAMA;IACxD,OAAO,IAAI,CAACG,MAAM;QAChBA,OAAO;IACT;IAEA,IAAIF,QAAQA,IAAI,CAAC,EAAE,KAAK,KAAKA,OAAO,MAAMA;IAC1C,IAAIU,UAAUA,MAAM,CAAC,EAAE,KAAK,KAAKA,SAAS,MAAMA;IAEhDX,WAAWA,SAASK,OAAO,CAAC,SAASD;IACrCO,SAASA,OAAON,OAAO,CAAC,KAAK;IAE7B,OAAO,GAAGN,WAAWI,OAAOH,WAAWW,SAASV,MAAM;AACxD;AAEO,MAAMP,gBAAgB;IAC3B;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;CACD;AAEM,SAASD,qBAAqBsB,GAAc;IACjD,wCAA4C;QAC1C,IAAIA,QAAQ,QAAQ,OAAOA,QAAQ,UAAU;YAC3CI,OAAOC,IAAI,CAACL,KAAKM,OAAO,CAAC,CAACC;gBACxB,IAAI,CAAC5B,cAAc6B,QAAQ,CAACD,MAAM;oBAChCE,QAAQC,IAAI,CACV,CAAC,kDAAkD,EAAEH,KAAK;gBAE9D;YACF;QACF;IACF;IAEA,OAAO9B,UAAUuB;AACnB","ignoreList":[0]}},
47
- {"offset": {"line": 3189, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/path-has-prefix.ts"],"sourcesContent":["import { parsePath } from './parse-path'\n\n/**\n * Checks if a given path starts with a given prefix. It ensures it matches\n * exactly without containing extra chars. e.g. prefix /docs should replace\n * for /docs, /docs/, /docs/a but not /docsss\n * @param path The path to check.\n * @param prefix The prefix to check against.\n */\nexport function pathHasPrefix(path: string, prefix: string) {\n if (typeof path !== 'string') {\n return false\n }\n\n const { pathname } = parsePath(path)\n return pathname === prefix || pathname.startsWith(prefix + '/')\n}\n"],"names":["pathHasPrefix","path","prefix","pathname","parsePath","startsWith"],"mappings":";;;+BASgBA,iBAAAA;;;eAAAA;;;2BATU;AASnB,SAASA,cAAcC,IAAY,EAAEC,MAAc;IACxD,IAAI,OAAOD,SAAS,UAAU;QAC5B,OAAO;IACT;IAEA,MAAM,EAAEE,QAAQ,EAAE,GAAGC,CAAAA,GAAAA,WAAAA,SAAS,EAACH;IAC/B,OAAOE,aAAaD,UAAUC,SAASE,UAAU,CAACH,SAAS;AAC7D","ignoreList":[0]}},
48
- {"offset": {"line": 3210, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/omit.ts"],"sourcesContent":["export function omit<T extends { [key: string]: unknown }, K extends keyof T>(\n object: T,\n keys: K[]\n): Omit<T, K> {\n const omitted: { [key: string]: unknown } = {}\n Object.keys(object).forEach((key) => {\n if (!keys.includes(key as K)) {\n omitted[key] = object[key]\n }\n })\n return omitted as Omit<T, K>\n}\n"],"names":["omit","object","keys","omitted","Object","forEach","key","includes"],"mappings":";;;+BAAgBA,QAAAA;;;eAAAA;;;AAAT,SAASA,KACdC,MAAS,EACTC,IAAS;IAET,MAAMC,UAAsC,CAAC;IAC7CC,OAAOF,IAAI,CAACD,QAAQI,OAAO,CAAC,CAACC;QAC3B,IAAI,CAACJ,KAAKK,QAAQ,CAACD,MAAW;YAC5BH,OAAO,CAACG,IAAI,GAAGL,MAAM,CAACK,IAAI;QAC5B;IACF;IACA,OAAOH;AACT","ignoreList":[0]}},
49
- {"offset": {"line": 3232, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/is-local-url.ts"],"sourcesContent":["import { isAbsoluteUrl, getLocationOrigin } from '../../utils'\nimport { hasBasePath } from '../../../../client/has-base-path'\n\n/**\n * Detects whether a given url is routable by the Next.js router (browser only).\n */\nexport function isLocalURL(url: string): boolean {\n // prevent a hydration mismatch on href for url with anchor refs\n if (!isAbsoluteUrl(url)) return true\n try {\n // absolute urls can be local if they are on the same origin\n const locationOrigin = getLocationOrigin()\n const resolved = new URL(url, locationOrigin)\n return resolved.origin === locationOrigin && hasBasePath(resolved.pathname)\n } catch (_) {\n return false\n }\n}\n"],"names":["isLocalURL","url","isAbsoluteUrl","locationOrigin","getLocationOrigin","resolved","URL","origin","hasBasePath","pathname","_"],"mappings":";;;+BAMgBA,cAAAA;;;eAAAA;;;uBANiC;6BACrB;AAKrB,SAASA,WAAWC,GAAW;IACpC,gEAAgE;IAChE,IAAI,CAACC,CAAAA,GAAAA,OAAAA,aAAa,EAACD,MAAM,OAAO;IAChC,IAAI;QACF,4DAA4D;QAC5D,MAAME,iBAAiBC,CAAAA,GAAAA,OAAAA,iBAAiB;QACxC,MAAMC,WAAW,IAAIC,IAAIL,KAAKE;QAC9B,OAAOE,SAASE,MAAM,KAAKJ,kBAAkBK,CAAAA,GAAAA,aAAAA,WAAW,EAACH,SAASI,QAAQ;IAC5E,EAAE,OAAOC,GAAG;QACV,OAAO;IACT;AACF","ignoreList":[0]}},
50
- {"offset": {"line": 3259, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/remove-path-prefix.ts"],"sourcesContent":["import { pathHasPrefix } from './path-has-prefix'\n\n/**\n * Given a path and a prefix it will remove the prefix when it exists in the\n * given path. It ensures it matches exactly without containing extra chars\n * and if the prefix is not there it will be noop.\n *\n * @param path The path to remove the prefix from.\n * @param prefix The prefix to be removed.\n */\nexport function removePathPrefix(path: string, prefix: string): string {\n // If the path doesn't start with the prefix we can return it as is. This\n // protects us from situations where the prefix is a substring of the path\n // prefix such as:\n //\n // For prefix: /blog\n //\n // /blog -> true\n // /blog/ -> true\n // /blog/1 -> true\n // /blogging -> false\n // /blogging/ -> false\n // /blogging/1 -> false\n if (!pathHasPrefix(path, prefix)) {\n return path\n }\n\n // Remove the prefix from the path via slicing.\n const withoutPrefix = path.slice(prefix.length)\n\n // If the path without the prefix starts with a `/` we can return it as is.\n if (withoutPrefix.startsWith('/')) {\n return withoutPrefix\n }\n\n // If the path without the prefix doesn't start with a `/` we need to add it\n // back to the path to make sure it's a valid path.\n return `/${withoutPrefix}`\n}\n"],"names":["removePathPrefix","path","prefix","pathHasPrefix","withoutPrefix","slice","length","startsWith"],"mappings":";;;+BAUgBA,oBAAAA;;;eAAAA;;;+BAVc;AAUvB,SAASA,iBAAiBC,IAAY,EAAEC,MAAc;IAC3D,yEAAyE;IACzE,0EAA0E;IAC1E,kBAAkB;IAClB,EAAE;IACF,oBAAoB;IACpB,EAAE;IACF,kBAAkB;IAClB,mBAAmB;IACnB,oBAAoB;IACpB,uBAAuB;IACvB,wBAAwB;IACxB,yBAAyB;IACzB,IAAI,CAACC,CAAAA,GAAAA,eAAAA,aAAa,EAACF,MAAMC,SAAS;QAChC,OAAOD;IACT;IAEA,+CAA+C;IAC/C,MAAMG,gBAAgBH,KAAKI,KAAK,CAACH,OAAOI,MAAM;IAE9C,2EAA2E;IAC3E,IAAIF,cAAcG,UAAU,CAAC,MAAM;QACjC,OAAOH;IACT;IAEA,4EAA4E;IAC5E,mDAAmD;IACnD,OAAO,CAAC,CAAC,EAAEA,eAAe;AAC5B","ignoreList":[0]}},
51
- {"offset": {"line": 3299, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/get-next-pathname-info.ts"],"sourcesContent":["import { normalizeLocalePath } from '../../i18n/normalize-locale-path'\nimport { removePathPrefix } from './remove-path-prefix'\nimport { pathHasPrefix } from './path-has-prefix'\nimport type { I18NProvider } from '../../../../server/lib/i18n-provider'\n\nexport interface NextPathnameInfo {\n /**\n * The base path in case the pathname included it.\n */\n basePath?: string\n /**\n * The buildId for when the parsed URL is a data URL. Parsing it can be\n * disabled with the `parseData` option.\n */\n buildId?: string\n /**\n * If there was a locale in the pathname, this will hold its value.\n */\n locale?: string\n /**\n * The processed pathname without a base path, locale, or data URL elements\n * when parsing it is enabled.\n */\n pathname: string\n /**\n * A boolean telling if the pathname had a trailingSlash. This can be only\n * true if trailingSlash is enabled.\n */\n trailingSlash?: boolean\n}\n\ninterface Options {\n /**\n * When passed to true, this function will also parse Nextjs data URLs.\n */\n parseData?: boolean\n /**\n * A partial of the Next.js configuration to parse the URL.\n */\n nextConfig?: {\n basePath?: string\n i18n?: { locales?: readonly string[] } | null\n trailingSlash?: boolean\n }\n\n /**\n * If provided, this normalizer will be used to detect the locale instead of\n * the default locale detection.\n */\n i18nProvider?: I18NProvider\n}\n\nexport function getNextPathnameInfo(\n pathname: string,\n options: Options\n): NextPathnameInfo {\n const { basePath, i18n, trailingSlash } = options.nextConfig ?? {}\n const info: NextPathnameInfo = {\n pathname,\n trailingSlash: pathname !== '/' ? pathname.endsWith('/') : trailingSlash,\n }\n\n if (basePath && pathHasPrefix(info.pathname, basePath)) {\n info.pathname = removePathPrefix(info.pathname, basePath)\n info.basePath = basePath\n }\n let pathnameNoDataPrefix = info.pathname\n\n if (\n info.pathname.startsWith('/_next/data/') &&\n info.pathname.endsWith('.json')\n ) {\n const paths = info.pathname\n .replace(/^\\/_next\\/data\\//, '')\n .replace(/\\.json$/, '')\n .split('/')\n\n const buildId = paths[0]\n info.buildId = buildId\n pathnameNoDataPrefix =\n paths[1] !== 'index' ? `/${paths.slice(1).join('/')}` : '/'\n\n // update pathname with normalized if enabled although\n // we use normalized to populate locale info still\n if (options.parseData === true) {\n info.pathname = pathnameNoDataPrefix\n }\n }\n\n // If provided, use the locale route normalizer to detect the locale instead\n // of the function below.\n if (i18n) {\n let result = options.i18nProvider\n ? options.i18nProvider.analyze(info.pathname)\n : normalizeLocalePath(info.pathname, i18n.locales)\n\n info.locale = result.detectedLocale\n info.pathname = result.pathname ?? info.pathname\n\n if (!result.detectedLocale && info.buildId) {\n result = options.i18nProvider\n ? options.i18nProvider.analyze(pathnameNoDataPrefix)\n : normalizeLocalePath(pathnameNoDataPrefix, i18n.locales)\n\n if (result.detectedLocale) {\n info.locale = result.detectedLocale\n }\n }\n }\n return info\n}\n"],"names":["getNextPathnameInfo","pathname","options","basePath","i18n","trailingSlash","nextConfig","info","endsWith","pathHasPrefix","removePathPrefix","pathnameNoDataPrefix","startsWith","paths","replace","split","buildId","slice","join","parseData","result","i18nProvider","analyze","normalizeLocalePath","locales","locale","detectedLocale"],"mappings":";;;+BAoDgBA,uBAAAA;;;eAAAA;;;qCApDoB;kCACH;+BACH;AAkDvB,SAASA,oBACdC,QAAgB,EAChBC,OAAgB;IAEhB,MAAM,EAAEC,QAAQ,EAAEC,IAAI,EAAEC,aAAa,EAAE,GAAGH,QAAQI,UAAU,IAAI,CAAC;IACjE,MAAMC,OAAyB;QAC7BN;QACAI,eAAeJ,aAAa,MAAMA,SAASO,QAAQ,CAAC,OAAOH;IAC7D;IAEA,IAAIF,YAAYM,CAAAA,GAAAA,eAAAA,aAAa,EAACF,KAAKN,QAAQ,EAAEE,WAAW;QACtDI,KAAKN,QAAQ,GAAGS,CAAAA,GAAAA,kBAAAA,gBAAgB,EAACH,KAAKN,QAAQ,EAAEE;QAChDI,KAAKJ,QAAQ,GAAGA;IAClB;IACA,IAAIQ,uBAAuBJ,KAAKN,QAAQ;IAExC,IACEM,KAAKN,QAAQ,CAACW,UAAU,CAAC,mBACzBL,KAAKN,QAAQ,CAACO,QAAQ,CAAC,UACvB;QACA,MAAMK,QAAQN,KAAKN,QAAQ,CACxBa,OAAO,CAAC,oBAAoB,IAC5BA,OAAO,CAAC,WAAW,IACnBC,KAAK,CAAC;QAET,MAAMC,UAAUH,KAAK,CAAC,EAAE;QACxBN,KAAKS,OAAO,GAAGA;QACfL,uBACEE,KAAK,CAAC,EAAE,KAAK,UAAU,CAAC,CAAC,EAAEA,MAAMI,KAAK,CAAC,GAAGC,IAAI,CAAC,MAAM,GAAG;QAE1D,sDAAsD;QACtD,kDAAkD;QAClD,IAAIhB,QAAQiB,SAAS,KAAK,MAAM;YAC9BZ,KAAKN,QAAQ,GAAGU;QAClB;IACF;IAEA,4EAA4E;IAC5E,yBAAyB;IACzB,IAAIP,MAAM;QACR,IAAIgB,SAASlB,QAAQmB,YAAY,GAC7BnB,QAAQmB,YAAY,CAACC,OAAO,CAACf,KAAKN,QAAQ,IAC1CsB,CAAAA,GAAAA,qBAAAA,mBAAmB,EAAChB,KAAKN,QAAQ,EAAEG,KAAKoB,OAAO;QAEnDjB,KAAKkB,MAAM,GAAGL,OAAOM,cAAc;QACnCnB,KAAKN,QAAQ,GAAGmB,OAAOnB,QAAQ,IAAIM,KAAKN,QAAQ;QAEhD,IAAI,CAACmB,OAAOM,cAAc,IAAInB,KAAKS,OAAO,EAAE;YAC1CI,SAASlB,QAAQmB,YAAY,GACzBnB,QAAQmB,YAAY,CAACC,OAAO,CAACX,wBAC7BY,CAAAA,GAAAA,qBAAAA,mBAAmB,EAACZ,sBAAsBP,KAAKoB,OAAO;YAE1D,IAAIJ,OAAOM,cAAc,EAAE;gBACzBnB,KAAKkB,MAAM,GAAGL,OAAOM,cAAc;YACrC;QACF;IACF;IACA,OAAOnB;AACT","ignoreList":[0]}},
52
- {"offset": {"line": 3352, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/add-path-suffix.ts"],"sourcesContent":["import { parsePath } from './parse-path'\n\n/**\n * Similarly to `addPathPrefix`, this function adds a suffix at the end on the\n * provided path. It also works only for paths ensuring the argument starts\n * with a slash.\n */\nexport function addPathSuffix(path: string, suffix?: string) {\n if (!path.startsWith('/') || !suffix) {\n return path\n }\n\n const { pathname, query, hash } = parsePath(path)\n return `${pathname}${suffix}${query}${hash}`\n}\n"],"names":["addPathSuffix","path","suffix","startsWith","pathname","query","hash","parsePath"],"mappings":";;;+BAOgBA,iBAAAA;;;eAAAA;;;2BAPU;AAOnB,SAASA,cAAcC,IAAY,EAAEC,MAAe;IACzD,IAAI,CAACD,KAAKE,UAAU,CAAC,QAAQ,CAACD,QAAQ;QACpC,OAAOD;IACT;IAEA,MAAM,EAAEG,QAAQ,EAAEC,KAAK,EAAEC,IAAI,EAAE,GAAGC,CAAAA,GAAAA,WAAAA,SAAS,EAACN;IAC5C,OAAO,GAAGG,WAAWF,SAASG,QAAQC,MAAM;AAC9C","ignoreList":[0]}},
53
- {"offset": {"line": 3373, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/add-locale.ts"],"sourcesContent":["import { addPathPrefix } from './add-path-prefix'\nimport { pathHasPrefix } from './path-has-prefix'\n\n/**\n * For a given path and a locale, if the locale is given, it will prefix the\n * locale. The path shouldn't be an API path. If a default locale is given the\n * prefix will be omitted if the locale is already the default locale.\n */\nexport function addLocale(\n path: string,\n locale?: string | false,\n defaultLocale?: string,\n ignorePrefix?: boolean\n) {\n // If no locale was given or the locale is the default locale, we don't need\n // to prefix the path.\n if (!locale || locale === defaultLocale) return path\n\n const lower = path.toLowerCase()\n\n // If the path is an API path or the path already has the locale prefix, we\n // don't need to prefix the path.\n if (!ignorePrefix) {\n if (pathHasPrefix(lower, '/api')) return path\n if (pathHasPrefix(lower, `/${locale.toLowerCase()}`)) return path\n }\n\n // Add the locale prefix to the path.\n return addPathPrefix(path, `/${locale}`)\n}\n"],"names":["addLocale","path","locale","defaultLocale","ignorePrefix","lower","toLowerCase","pathHasPrefix","addPathPrefix"],"mappings":";;;+BAQgBA,aAAAA;;;eAAAA;;;+BARc;+BACA;AAOvB,SAASA,UACdC,IAAY,EACZC,MAAuB,EACvBC,aAAsB,EACtBC,YAAsB;IAEtB,4EAA4E;IAC5E,sBAAsB;IACtB,IAAI,CAACF,UAAUA,WAAWC,eAAe,OAAOF;IAEhD,MAAMI,QAAQJ,KAAKK,WAAW;IAE9B,2EAA2E;IAC3E,iCAAiC;IACjC,IAAI,CAACF,cAAc;QACjB,IAAIG,CAAAA,GAAAA,eAAAA,aAAa,EAACF,OAAO,SAAS,OAAOJ;QACzC,IAAIM,CAAAA,GAAAA,eAAAA,aAAa,EAACF,OAAO,CAAC,CAAC,EAAEH,OAAOI,WAAW,IAAI,GAAG,OAAOL;IAC/D;IAEA,qCAAqC;IACrC,OAAOO,CAAAA,GAAAA,eAAAA,aAAa,EAACP,MAAM,CAAC,CAAC,EAAEC,QAAQ;AACzC","ignoreList":[0]}},
54
- {"offset": {"line": 3402, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/format-next-pathname-info.ts"],"sourcesContent":["import type { NextPathnameInfo } from './get-next-pathname-info'\nimport { removeTrailingSlash } from './remove-trailing-slash'\nimport { addPathPrefix } from './add-path-prefix'\nimport { addPathSuffix } from './add-path-suffix'\nimport { addLocale } from './add-locale'\n\ninterface ExtendedInfo extends NextPathnameInfo {\n defaultLocale?: string\n ignorePrefix?: boolean\n}\n\nexport function formatNextPathnameInfo(info: ExtendedInfo) {\n let pathname = addLocale(\n info.pathname,\n info.locale,\n info.buildId ? undefined : info.defaultLocale,\n info.ignorePrefix\n )\n\n if (info.buildId || !info.trailingSlash) {\n pathname = removeTrailingSlash(pathname)\n }\n\n if (info.buildId) {\n pathname = addPathSuffix(\n addPathPrefix(pathname, `/_next/data/${info.buildId}`),\n info.pathname === '/' ? 'index.json' : '.json'\n )\n }\n\n pathname = addPathPrefix(pathname, info.basePath)\n return !info.buildId && info.trailingSlash\n ? !pathname.endsWith('/')\n ? addPathSuffix(pathname, '/')\n : pathname\n : removeTrailingSlash(pathname)\n}\n"],"names":["formatNextPathnameInfo","info","pathname","addLocale","locale","buildId","undefined","defaultLocale","ignorePrefix","trailingSlash","removeTrailingSlash","addPathSuffix","addPathPrefix","basePath","endsWith"],"mappings":";;;+BAWgBA,0BAAAA;;;eAAAA;;;qCAVoB;+BACN;+BACA;2BACJ;AAOnB,SAASA,uBAAuBC,IAAkB;IACvD,IAAIC,WAAWC,CAAAA,GAAAA,WAAAA,SAAS,EACtBF,KAAKC,QAAQ,EACbD,KAAKG,MAAM,EACXH,KAAKI,OAAO,GAAGC,YAAYL,KAAKM,aAAa,EAC7CN,KAAKO,YAAY;IAGnB,IAAIP,KAAKI,OAAO,IAAI,CAACJ,KAAKQ,aAAa,EAAE;QACvCP,WAAWQ,CAAAA,GAAAA,qBAAAA,mBAAmB,EAACR;IACjC;IAEA,IAAID,KAAKI,OAAO,EAAE;QAChBH,WAAWS,CAAAA,GAAAA,eAAAA,aAAa,EACtBC,CAAAA,GAAAA,eAAAA,aAAa,EAACV,UAAU,CAAC,YAAY,EAAED,KAAKI,OAAO,EAAE,GACrDJ,KAAKC,QAAQ,KAAK,MAAM,eAAe;IAE3C;IAEAA,WAAWU,CAAAA,GAAAA,eAAAA,aAAa,EAACV,UAAUD,KAAKY,QAAQ;IAChD,OAAO,CAACZ,KAAKI,OAAO,IAAIJ,KAAKQ,aAAa,GACtC,CAACP,SAASY,QAAQ,CAAC,OACjBH,CAAAA,GAAAA,eAAAA,aAAa,EAACT,UAAU,OACxBA,WACFQ,CAAAA,GAAAA,qBAAAA,mBAAmB,EAACR;AAC1B","ignoreList":[0]}},
55
- {"offset": {"line": 3430, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/compare-states.ts"],"sourcesContent":["import type { default as Router } from '../router'\n\nexport function compareRouterStates(a: Router['state'], b: Router['state']) {\n const stateKeys = Object.keys(a)\n if (stateKeys.length !== Object.keys(b).length) return false\n\n for (let i = stateKeys.length; i--; ) {\n const key = stateKeys[i]\n if (key === 'query') {\n const queryKeys = Object.keys(a.query)\n if (queryKeys.length !== Object.keys(b.query).length) {\n return false\n }\n for (let j = queryKeys.length; j--; ) {\n const queryKey = queryKeys[j]\n if (\n !b.query.hasOwnProperty(queryKey) ||\n a.query[queryKey] !== b.query[queryKey]\n ) {\n return false\n }\n }\n } else if (\n !b.hasOwnProperty(key) ||\n a[key as keyof Router['state']] !== b[key as keyof Router['state']]\n ) {\n return false\n }\n }\n\n return true\n}\n"],"names":["compareRouterStates","a","b","stateKeys","Object","keys","length","i","key","queryKeys","query","j","queryKey","hasOwnProperty"],"mappings":";;;+BAEgBA,uBAAAA;;;eAAAA;;;AAAT,SAASA,oBAAoBC,CAAkB,EAAEC,CAAkB;IACxE,MAAMC,YAAYC,OAAOC,IAAI,CAACJ;IAC9B,IAAIE,UAAUG,MAAM,KAAKF,OAAOC,IAAI,CAACH,GAAGI,MAAM,EAAE,OAAO;IAEvD,IAAK,IAAIC,IAAIJ,UAAUG,MAAM,EAAEC,KAAO;QACpC,MAAMC,MAAML,SAAS,CAACI,EAAE;QACxB,IAAIC,QAAQ,SAAS;YACnB,MAAMC,YAAYL,OAAOC,IAAI,CAACJ,EAAES,KAAK;YACrC,IAAID,UAAUH,MAAM,KAAKF,OAAOC,IAAI,CAACH,EAAEQ,KAAK,EAAEJ,MAAM,EAAE;gBACpD,OAAO;YACT;YACA,IAAK,IAAIK,IAAIF,UAAUH,MAAM,EAAEK,KAAO;gBACpC,MAAMC,WAAWH,SAAS,CAACE,EAAE;gBAC7B,IACE,CAACT,EAAEQ,KAAK,CAACG,cAAc,CAACD,aACxBX,EAAES,KAAK,CAACE,SAAS,KAAKV,EAAEQ,KAAK,CAACE,SAAS,EACvC;oBACA,OAAO;gBACT;YACF;QACF,OAAO,IACL,CAACV,EAAEW,cAAc,CAACL,QAClBP,CAAC,CAACO,IAA6B,KAAKN,CAAC,CAACM,IAA6B,EACnE;YACA,OAAO;QACT;IACF;IAEA,OAAO;AACT","ignoreList":[0]}},
56
- {"offset": {"line": 3465, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/html-bots.ts"],"sourcesContent":["// This regex contains the bots that we need to do a blocking render for and can't safely stream the response\n// due to how they parse the DOM. For example, they might explicitly check for metadata in the `head` tag, so we can't stream metadata tags after the `head` was sent.\n// Note: The pattern [\\w-]+-Google captures all Google crawlers with \"-Google\" suffix (e.g., Mediapartners-Google, AdsBot-Google, Storebot-Google)\n// as well as crawlers starting with \"Google-\" (e.g., Google-PageRenderer, Google-InspectionTool)\nexport const HTML_LIMITED_BOT_UA_RE =\n /[\\w-]+-Google|Google-[\\w-]+|Chrome-Lighthouse|Slurp|DuckDuckBot|baiduspider|yandex|sogou|bitlybot|tumblr|vkShare|quora link preview|redditbot|ia_archiver|Bingbot|BingPreview|applebot|facebookexternalhit|facebookcatalog|Twitterbot|LinkedInBot|Slackbot|Discordbot|WhatsApp|SkypeUriPreview|Yeti|googleweblight/i\n"],"names":["HTML_LIMITED_BOT_UA_RE"],"mappings":"AAAA,6GAA6G;AAC7G,sKAAsK;AACtK,kJAAkJ;AAClJ,iGAAiG;;;;+BACpFA,0BAAAA;;;eAAAA;;;AAAN,MAAMA,yBACX","ignoreList":[0]}},
57
- {"offset": {"line": 3483, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/is-bot.ts"],"sourcesContent":["import { HTML_LIMITED_BOT_UA_RE } from './html-bots'\n\n// Bot crawler that will spin up a headless browser and execute JS.\n// Only the main Googlebot search crawler executes JavaScript, not other Google crawlers.\n// x-ref: https://developers.google.com/search/docs/crawling-indexing/google-common-crawlers\n// This regex specifically matches \"Googlebot\" but NOT \"Mediapartners-Google\", \"AdsBot-Google\", etc.\nconst HEADLESS_BROWSER_BOT_UA_RE = /Googlebot(?!-)|Googlebot$/i\n\nexport const HTML_LIMITED_BOT_UA_RE_STRING = HTML_LIMITED_BOT_UA_RE.source\n\nexport { HTML_LIMITED_BOT_UA_RE }\n\nfunction isDomBotUA(userAgent: string) {\n return HEADLESS_BROWSER_BOT_UA_RE.test(userAgent)\n}\n\nfunction isHtmlLimitedBotUA(userAgent: string) {\n return HTML_LIMITED_BOT_UA_RE.test(userAgent)\n}\n\nexport function isBot(userAgent: string): boolean {\n return isDomBotUA(userAgent) || isHtmlLimitedBotUA(userAgent)\n}\n\nexport function getBotType(userAgent: string): 'dom' | 'html' | undefined {\n if (isDomBotUA(userAgent)) {\n return 'dom'\n }\n if (isHtmlLimitedBotUA(userAgent)) {\n return 'html'\n }\n return undefined\n}\n"],"names":["HTML_LIMITED_BOT_UA_RE","HTML_LIMITED_BOT_UA_RE_STRING","getBotType","isBot","HEADLESS_BROWSER_BOT_UA_RE","source","isDomBotUA","userAgent","test","isHtmlLimitedBotUA","undefined"],"mappings":";;;;;;;;;;;;;;;;IAUSA,sBAAsB,EAAA;eAAtBA,UAAAA,sBAAsB;;IAFlBC,6BAA6B,EAAA;eAA7BA;;IAgBGC,UAAU,EAAA;eAAVA;;IAJAC,KAAK,EAAA;eAALA;;;0BApBuB;AAEvC,mEAAmE;AACnE,yFAAyF;AACzF,4FAA4F;AAC5F,oGAAoG;AACpG,MAAMC,6BAA6B;AAE5B,MAAMH,gCAAgCD,UAAAA,sBAAsB,CAACK,MAAM;AAI1E,SAASC,WAAWC,SAAiB;IACnC,OAAOH,2BAA2BI,IAAI,CAACD;AACzC;AAEA,SAASE,mBAAmBF,SAAiB;IAC3C,OAAOP,UAAAA,sBAAsB,CAACQ,IAAI,CAACD;AACrC;AAEO,SAASJ,MAAMI,SAAiB;IACrC,OAAOD,WAAWC,cAAcE,mBAAmBF;AACrD;AAEO,SAASL,WAAWK,SAAiB;IAC1C,IAAID,WAAWC,YAAY;QACzB,OAAO;IACT;IACA,IAAIE,mBAAmBF,YAAY;QACjC,OAAO;IACT;IACA,OAAOG;AACT","ignoreList":[0]}},
58
- {"offset": {"line": 3541, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/router.ts"],"sourcesContent":["import type { ComponentType } from 'react'\nimport type { DomainLocale } from '../../../server/config'\nimport type { MittEmitter } from '../mitt'\nimport type { ParsedUrlQuery } from 'querystring'\nimport type { RouterEvent } from '../../../client/router'\nimport type { StyleSheetTuple } from '../../../client/page-loader'\nimport type { UrlObject } from 'url'\nimport type PageLoader from '../../../client/page-loader'\nimport type { AppContextType, NextPageContext, NEXT_DATA } from '../utils'\nimport { removeTrailingSlash } from './utils/remove-trailing-slash'\nimport {\n getClientBuildManifest,\n isAssetError,\n markAssetError,\n} from '../../../client/route-loader'\nimport { handleClientScriptLoad } from '../../../client/script'\nimport isError, { getProperError } from '../../../lib/is-error'\nimport { denormalizePagePath } from '../page-path/denormalize-page-path'\nimport { normalizeLocalePath } from '../i18n/normalize-locale-path'\nimport mitt from '../mitt'\nimport { getLocationOrigin, getURL, loadGetInitialProps, ST } from '../utils'\nimport { isDynamicRoute } from './utils/is-dynamic'\nimport { parseRelativeUrl } from './utils/parse-relative-url'\nimport { getRouteMatcher } from './utils/route-matcher'\nimport { getRouteRegex } from './utils/route-regex'\nimport { formatWithValidation } from './utils/format-url'\nimport { detectDomainLocale } from '../../../client/detect-domain-locale'\nimport { parsePath } from './utils/parse-path'\nimport { addLocale } from '../../../client/add-locale'\nimport { removeLocale } from '../../../client/remove-locale'\nimport { removeBasePath } from '../../../client/remove-base-path'\nimport { addBasePath } from '../../../client/add-base-path'\nimport { hasBasePath } from '../../../client/has-base-path'\nimport { resolveHref } from '../../../client/resolve-href'\nimport { isAPIRoute } from '../../../lib/is-api-route'\nimport { getNextPathnameInfo } from './utils/get-next-pathname-info'\nimport { formatNextPathnameInfo } from './utils/format-next-pathname-info'\nimport { compareRouterStates } from './utils/compare-states'\nimport { isLocalURL } from './utils/is-local-url'\nimport { isBot } from './utils/is-bot'\nimport { omit } from './utils/omit'\nimport { interpolateAs } from './utils/interpolate-as'\nimport { disableSmoothScrollDuringRouteTransition } from './utils/disable-smooth-scroll'\nimport type { Params } from '../../../server/request/params'\nimport {\n MATCHED_PATH_HEADER,\n NEXT_NAV_DEPLOYMENT_ID_HEADER,\n} from '../../../lib/constants'\nimport { getDeploymentId } from '../deployment-id'\nimport { isJavaScriptURLString } from '../../../client/lib/javascript-url'\n\nlet resolveRewrites: typeof import('./utils/resolve-rewrites').default\nif (process.env.__NEXT_HAS_REWRITES) {\n resolveRewrites = (\n require('./utils/resolve-rewrites') as typeof import('./utils/resolve-rewrites')\n ).default\n}\n\ndeclare global {\n interface Window {\n /* prod */\n __NEXT_DATA__: NEXT_DATA\n }\n}\n\ninterface RouteProperties {\n shallow: boolean\n}\n\ninterface TransitionOptions {\n shallow?: boolean\n locale?: string | false\n scroll?: boolean\n unstable_skipClientCache?: boolean\n}\n\ninterface NextHistoryState {\n url: string\n as: string\n options: TransitionOptions\n}\n\nexport type HistoryState =\n | null\n | { __NA: true; __N?: false }\n | { __N: false; __NA?: false }\n | ({ __NA?: false; __N: true; key: string } & NextHistoryState)\n\nfunction buildCancellationError() {\n return Object.assign(new Error('Route Cancelled'), {\n cancelled: true,\n })\n}\n\ninterface MiddlewareEffectParams<T extends FetchDataOutput> {\n fetchData?: () => Promise<T>\n locale?: string\n asPath: string\n router: Router\n}\n\nexport async function matchesMiddleware<T extends FetchDataOutput>(\n options: MiddlewareEffectParams<T>\n): Promise<boolean> {\n const matchers = await Promise.resolve(\n options.router.pageLoader.getMiddleware()\n )\n if (!matchers) return false\n\n const { pathname: asPathname } = parsePath(options.asPath)\n // remove basePath first since path prefix has to be in the order of `/${basePath}/${locale}`\n const cleanedAs = hasBasePath(asPathname)\n ? removeBasePath(asPathname)\n : asPathname\n const asWithBasePathAndLocale = addBasePath(\n addLocale(cleanedAs, options.locale)\n )\n\n // Check only path match on client. Matching \"has\" should be done on server\n // where we can access more info such as headers, HttpOnly cookie, etc.\n return matchers.some((m) =>\n new RegExp(m.regexp).test(asWithBasePathAndLocale)\n )\n}\n\nfunction stripOrigin(url: string) {\n const origin = getLocationOrigin()\n\n return url.startsWith(origin) ? url.substring(origin.length) : url\n}\n\nfunction prepareUrlAs(router: NextRouter, url: Url, as?: Url) {\n // If url and as provided as an object representation,\n // we'll format them into the string version here.\n let [resolvedHref, resolvedAs] = resolveHref(router, url, true)\n const origin = getLocationOrigin()\n const hrefWasAbsolute = resolvedHref.startsWith(origin)\n const asWasAbsolute = resolvedAs && resolvedAs.startsWith(origin)\n\n resolvedHref = stripOrigin(resolvedHref)\n resolvedAs = resolvedAs ? stripOrigin(resolvedAs) : resolvedAs\n\n const preparedUrl = hrefWasAbsolute ? resolvedHref : addBasePath(resolvedHref)\n const preparedAs = as\n ? stripOrigin(resolveHref(router, as))\n : resolvedAs || resolvedHref\n\n return {\n url: preparedUrl,\n as: asWasAbsolute ? preparedAs : addBasePath(preparedAs),\n }\n}\n\nfunction resolveDynamicRoute(pathname: string, pages: string[]) {\n const cleanPathname = removeTrailingSlash(denormalizePagePath(pathname))\n if (cleanPathname === '/404' || cleanPathname === '/_error') {\n return pathname\n }\n\n // handle resolving href for dynamic routes\n if (!pages.includes(cleanPathname)) {\n // eslint-disable-next-line array-callback-return\n pages.some((page) => {\n if (isDynamicRoute(page) && getRouteRegex(page).re.test(cleanPathname)) {\n pathname = page\n return true\n }\n })\n }\n return removeTrailingSlash(pathname)\n}\n\nfunction getMiddlewareData<T extends FetchDataOutput>(\n source: string,\n response: Response,\n options: MiddlewareEffectParams<T>\n) {\n const nextConfig = {\n basePath: options.router.basePath,\n i18n: { locales: options.router.locales },\n trailingSlash: Boolean(process.env.__NEXT_TRAILING_SLASH),\n }\n const rewriteHeader = response.headers.get('x-nextjs-rewrite')\n\n let rewriteTarget =\n rewriteHeader || response.headers.get('x-nextjs-matched-path')\n\n const matchedPath = response.headers.get(MATCHED_PATH_HEADER)\n\n if (\n matchedPath &&\n !rewriteTarget &&\n !matchedPath.includes('__next_data_catchall') &&\n !matchedPath.includes('/_error') &&\n !matchedPath.includes('/404')\n ) {\n // leverage x-matched-path to detect next.config.js rewrites\n rewriteTarget = matchedPath\n }\n\n if (rewriteTarget) {\n if (\n rewriteTarget.startsWith('/') ||\n process.env.__NEXT_EXTERNAL_MIDDLEWARE_REWRITE_RESOLVE\n ) {\n const parsedRewriteTarget = parseRelativeUrl(rewriteTarget)\n const pathnameInfo = getNextPathnameInfo(parsedRewriteTarget.pathname, {\n nextConfig,\n parseData: true,\n })\n\n let fsPathname = removeTrailingSlash(pathnameInfo.pathname)\n return Promise.all([\n options.router.pageLoader.getPageList(),\n getClientBuildManifest(),\n ]).then(([pages, { __rewrites: rewrites }]: any) => {\n let as = addLocale(pathnameInfo.pathname, pathnameInfo.locale)\n\n if (\n isDynamicRoute(as) ||\n (!rewriteHeader &&\n pages.includes(\n normalizeLocalePath(removeBasePath(as), options.router.locales)\n .pathname\n ))\n ) {\n const parsedSource = getNextPathnameInfo(\n parseRelativeUrl(source).pathname,\n {\n nextConfig: process.env.__NEXT_HAS_REWRITES\n ? undefined\n : nextConfig,\n parseData: true,\n }\n )\n\n as = addBasePath(parsedSource.pathname)\n parsedRewriteTarget.pathname = as\n }\n\n if (process.env.__NEXT_HAS_REWRITES) {\n const result = resolveRewrites(\n as,\n pages,\n rewrites,\n parsedRewriteTarget.query,\n (path: string) => resolveDynamicRoute(path, pages),\n options.router.locales\n )\n\n if (result.matchedPage) {\n parsedRewriteTarget.pathname = result.parsedAs.pathname\n as = parsedRewriteTarget.pathname\n Object.assign(parsedRewriteTarget.query, result.parsedAs.query)\n }\n } else if (!pages.includes(fsPathname)) {\n const resolvedPathname = resolveDynamicRoute(fsPathname, pages)\n\n if (resolvedPathname !== fsPathname) {\n fsPathname = resolvedPathname\n }\n }\n\n const resolvedHref = !pages.includes(fsPathname)\n ? resolveDynamicRoute(\n normalizeLocalePath(\n removeBasePath(parsedRewriteTarget.pathname),\n options.router.locales\n ).pathname,\n pages\n )\n : fsPathname\n\n if (isDynamicRoute(resolvedHref)) {\n const matches = getRouteMatcher(getRouteRegex(resolvedHref))(as)\n Object.assign(parsedRewriteTarget.query, matches || {})\n }\n\n return {\n type: 'rewrite' as const,\n parsedAs: parsedRewriteTarget,\n resolvedHref,\n }\n })\n }\n const src = parsePath(source)\n const pathname = formatNextPathnameInfo({\n ...getNextPathnameInfo(src.pathname, { nextConfig, parseData: true }),\n defaultLocale: options.router.defaultLocale,\n buildId: '',\n })\n\n return Promise.resolve({\n type: 'redirect-external' as const,\n destination: `${pathname}${src.query}${src.hash}`,\n })\n }\n\n const redirectTarget = response.headers.get('x-nextjs-redirect')\n\n if (redirectTarget) {\n if (redirectTarget.startsWith('/')) {\n const src = parsePath(redirectTarget)\n const pathname = formatNextPathnameInfo({\n ...getNextPathnameInfo(src.pathname, { nextConfig, parseData: true }),\n defaultLocale: options.router.defaultLocale,\n buildId: '',\n })\n\n return Promise.resolve({\n type: 'redirect-internal' as const,\n newAs: `${pathname}${src.query}${src.hash}`,\n newUrl: `${pathname}${src.query}${src.hash}`,\n })\n }\n\n return Promise.resolve({\n type: 'redirect-external' as const,\n destination: redirectTarget,\n })\n }\n\n return Promise.resolve({ type: 'next' as const })\n}\n\ninterface WithMiddlewareEffectsOutput extends FetchDataOutput {\n effect: Awaited<ReturnType<typeof getMiddlewareData>>\n}\n\nasync function withMiddlewareEffects<T extends FetchDataOutput>(\n options: MiddlewareEffectParams<T>\n): Promise<WithMiddlewareEffectsOutput | null> {\n const matches = await matchesMiddleware(options)\n if (!matches || !options.fetchData) {\n return null\n }\n\n const data = await options.fetchData()\n\n const effect = await getMiddlewareData(data.dataHref, data.response, options)\n\n return {\n dataHref: data.dataHref,\n json: data.json,\n response: data.response,\n text: data.text,\n cacheKey: data.cacheKey,\n effect,\n }\n}\n\nexport type Url = UrlObject | string\n\nexport type BaseRouter = {\n route: string\n pathname: string\n query: ParsedUrlQuery\n asPath: string\n basePath: string\n locale?: string | undefined\n locales?: readonly string[] | undefined\n defaultLocale?: string | undefined\n domainLocales?: readonly DomainLocale[] | undefined\n isLocaleDomain: boolean\n}\n\nexport type NextRouter = BaseRouter &\n Pick<\n Router,\n | 'push'\n | 'replace'\n | 'reload'\n | 'back'\n | 'forward'\n | 'prefetch'\n | 'beforePopState'\n | 'events'\n | 'isFallback'\n | 'isReady'\n | 'isPreview'\n >\n\nexport type PrefetchOptions = {\n priority?: boolean\n locale?: string | false\n unstable_skipClientCache?: boolean\n}\n\nexport type PrivateRouteInfo =\n | (Omit<CompletePrivateRouteInfo, 'styleSheets'> & { initial: true })\n | CompletePrivateRouteInfo\n\nexport type CompletePrivateRouteInfo = {\n Component: ComponentType\n styleSheets: StyleSheetTuple[]\n __N_SSG?: boolean\n __N_SSP?: boolean\n props?: Record<string, any>\n err?: Error\n error?: any\n route?: string\n resolvedAs?: string\n query?: ParsedUrlQuery\n}\n\nexport type AppProps = Pick<CompletePrivateRouteInfo, 'Component' | 'err'> & {\n router: Router\n} & Record<string, any>\nexport type AppComponent = ComponentType<AppProps>\n\ntype Subscription = (\n data: PrivateRouteInfo,\n App: AppComponent,\n resetScroll: { x: number; y: number } | null\n) => Promise<void>\n\ntype BeforePopStateCallback = (state: NextHistoryState) => boolean\n\ntype ComponentLoadCancel = (() => void) | null\n\ntype HistoryMethod = 'replaceState' | 'pushState'\n\nconst manualScrollRestoration =\n process.env.__NEXT_SCROLL_RESTORATION &&\n typeof window !== 'undefined' &&\n 'scrollRestoration' in window.history &&\n !!(function () {\n try {\n let v = '__next'\n return (sessionStorage.setItem(v, v), sessionStorage.removeItem(v), true)\n } catch (n) {}\n })()\n\nconst SSG_DATA_NOT_FOUND = Symbol('SSG_DATA_NOT_FOUND')\n\nfunction fetchRetry(\n url: string,\n attempts: number,\n options: Pick<RequestInit, 'method' | 'headers'>\n): Promise<Response> {\n return fetch(url, {\n // Cookies are required to be present for Next.js' SSG \"Preview Mode\".\n // Cookies may also be required for `getServerSideProps`.\n //\n // > `fetch` won’t send cookies, unless you set the credentials init\n // > option.\n // https://developer.mozilla.org/docs/Web/API/Fetch_API/Using_Fetch\n //\n // > For maximum browser compatibility when it comes to sending &\n // > receiving cookies, always supply the `credentials: 'same-origin'`\n // > option instead of relying on the default.\n // https://github.com/github/fetch#caveats\n credentials: 'same-origin',\n method: options.method || 'GET',\n headers: Object.assign({}, options.headers, {\n 'x-nextjs-data': '1',\n }),\n }).then((response) => {\n return !response.ok && attempts > 1 && response.status >= 500\n ? fetchRetry(url, attempts - 1, options)\n : response\n })\n}\n\ninterface FetchDataOutput {\n dataHref: string\n json: Record<string, any> | null\n response: Response\n text: string\n cacheKey: string\n}\n\ninterface FetchNextDataParams {\n dataHref: string\n isServerRender: boolean\n parseJSON: boolean | undefined\n hasMiddleware?: boolean\n inflightCache: NextDataCache\n persistCache: boolean\n isPrefetch: boolean\n isBackground?: boolean\n unstable_skipClientCache?: boolean\n}\n\nfunction tryToParseAsJSON(text: string) {\n try {\n return JSON.parse(text)\n } catch (error) {\n return null\n }\n}\n\nfunction fetchNextData({\n dataHref,\n inflightCache,\n isPrefetch,\n hasMiddleware,\n isServerRender,\n parseJSON,\n persistCache,\n isBackground,\n unstable_skipClientCache,\n}: FetchNextDataParams): Promise<FetchDataOutput> {\n const { href: cacheKey } = new URL(dataHref, window.location.href)\n const deploymentId = getDeploymentId()\n const getData = (params?: { method?: 'HEAD' | 'GET' }) =>\n fetchRetry(dataHref, isServerRender ? 3 : 1, {\n headers: Object.assign(\n {} as HeadersInit,\n isPrefetch ? { purpose: 'prefetch' } : {},\n isPrefetch && hasMiddleware ? { 'x-middleware-prefetch': '1' } : {},\n deploymentId ? { 'x-deployment-id': deploymentId } : {}\n ),\n method: params?.method ?? 'GET',\n })\n .then((response) => {\n if (response.ok && params?.method === 'HEAD') {\n return { dataHref, response, text: '', json: {}, cacheKey }\n }\n\n return response.text().then((text) => {\n if (!response.ok) {\n /**\n * When the data response is a redirect because of a middleware\n * we do not consider it an error. The headers must bring the\n * mapped location.\n * TODO: Change the status code in the handler.\n */\n if (\n hasMiddleware &&\n [301, 302, 307, 308].includes(response.status)\n ) {\n return { dataHref, response, text, json: {}, cacheKey }\n }\n\n if (response.status === 404) {\n if (tryToParseAsJSON(text)?.notFound) {\n return {\n dataHref,\n json: { notFound: SSG_DATA_NOT_FOUND },\n response,\n text,\n cacheKey,\n }\n }\n }\n\n const error = new Error(`Failed to load static props`)\n\n /**\n * We should only trigger a server-side transition if this was\n * caused on a client-side transition. Otherwise, we'd get into\n * an infinite loop.\n */\n if (!isServerRender) {\n markAssetError(error)\n }\n\n throw error\n }\n\n let dplResponseHeader = response.headers.get(\n NEXT_NAV_DEPLOYMENT_ID_HEADER\n )\n if (dplResponseHeader != null && dplResponseHeader !== deploymentId) {\n // When not found, or we want to force a MPA navigation because of Skew Protection\n const error = new Error(\n `Loaded static props were from an outdated deployment, forcing a hard reload`\n )\n /**\n * We should only trigger a server-side transition if this was\n * caused on a client-side transition. Otherwise, we'd get into\n * an infinite loop.\n */\n if (!isServerRender) {\n markAssetError(error)\n }\n throw error\n }\n\n return {\n dataHref,\n json: parseJSON ? tryToParseAsJSON(text) : null,\n response,\n text,\n cacheKey,\n }\n })\n })\n .then((data) => {\n if (\n !persistCache ||\n process.env.NODE_ENV !== 'production' ||\n data.response.headers.get('x-middleware-cache') === 'no-cache'\n ) {\n delete inflightCache[cacheKey]\n }\n return data\n })\n .catch((err) => {\n if (!unstable_skipClientCache) {\n delete inflightCache[cacheKey]\n }\n if (\n // chrome\n err.message === 'Failed to fetch' ||\n // firefox\n err.message === 'NetworkError when attempting to fetch resource.' ||\n // safari\n err.message === 'Load failed'\n ) {\n markAssetError(err)\n }\n throw err\n })\n\n // when skipping client cache we wait to update\n // inflight cache until successful data response\n // this allows racing click event with fetching newer data\n // without blocking navigation when stale data is available\n if (unstable_skipClientCache && persistCache) {\n return getData({}).then((data) => {\n if (data.response.headers.get('x-middleware-cache') !== 'no-cache') {\n // only update cache if not marked as no-cache\n inflightCache[cacheKey] = Promise.resolve(data)\n }\n\n return data\n })\n }\n\n if (inflightCache[cacheKey] !== undefined) {\n return inflightCache[cacheKey]\n }\n return (inflightCache[cacheKey] = getData(\n isBackground ? { method: 'HEAD' } : {}\n ))\n}\n\ninterface NextDataCache {\n [asPath: string]: Promise<FetchDataOutput>\n}\n\nexport function createKey() {\n return Math.random().toString(36).slice(2, 10)\n}\n\nfunction handleHardNavigation({\n url,\n router,\n}: {\n url: string\n router: Router\n}) {\n // ensure we don't trigger a hard navigation to the same\n // URL as this can end up with an infinite refresh\n if (url === addBasePath(addLocale(router.asPath, router.locale))) {\n throw new Error(\n `Invariant: attempted to hard navigate to the same URL ${url} ${location.href}`\n )\n }\n window.location.href = url\n}\n\nconst getCancelledHandler = ({\n route,\n router,\n}: {\n route: string\n router: Router\n}) => {\n let cancelled = false\n const cancel = (router.clc = () => {\n cancelled = true\n })\n\n const handleCancelled = () => {\n if (cancelled) {\n const error: any = new Error(\n `Abort fetching component for route: \"${route}\"`\n )\n error.cancelled = true\n throw error\n }\n\n if (cancel === router.clc) {\n router.clc = null\n }\n }\n return handleCancelled\n}\n\nexport default class Router implements BaseRouter {\n basePath: string\n\n /**\n * Map of all components loaded in `Router`\n */\n components: { [pathname: string]: PrivateRouteInfo }\n // Server Data Cache (full data requests)\n sdc: NextDataCache = {}\n // Server Background Cache (HEAD requests)\n sbc: NextDataCache = {}\n\n sub: Subscription\n clc: ComponentLoadCancel\n pageLoader: PageLoader\n _bps: BeforePopStateCallback | undefined\n events: MittEmitter<RouterEvent>\n _wrapApp: (App: AppComponent) => any\n isSsr: boolean\n _inFlightRoute?: string | undefined\n _shallow?: boolean | undefined\n locales?: readonly string[] | undefined\n defaultLocale?: string | undefined\n domainLocales?: readonly DomainLocale[] | undefined\n isReady: boolean\n isLocaleDomain: boolean\n isFirstPopStateEvent = true\n _initialMatchesMiddlewarePromise: Promise<boolean>\n // static entries filter\n _bfl_s?: import('../../lib/bloom-filter').BloomFilter\n // dynamic entires filter\n _bfl_d?: import('../../lib/bloom-filter').BloomFilter\n\n private state: Readonly<{\n route: string\n pathname: string\n query: ParsedUrlQuery\n asPath: string\n locale: string | undefined\n isFallback: boolean\n isPreview: boolean\n }>\n\n private _key: string = createKey()\n\n static events: MittEmitter<RouterEvent> = mitt()\n\n constructor(\n pathname: string,\n query: ParsedUrlQuery,\n as: string,\n {\n initialProps,\n pageLoader,\n App,\n wrapApp,\n Component,\n err,\n subscription,\n isFallback,\n locale,\n locales,\n defaultLocale,\n domainLocales,\n isPreview,\n }: {\n subscription: Subscription\n initialProps: any\n pageLoader: any\n Component: ComponentType\n App: AppComponent\n wrapApp: (WrapAppComponent: AppComponent) => any\n err?: Error\n isFallback: boolean\n locale?: string\n locales?: readonly string[]\n defaultLocale?: string\n domainLocales?: readonly DomainLocale[]\n isPreview?: boolean\n }\n ) {\n // represents the current component key\n const route = removeTrailingSlash(pathname)\n\n // set up the component cache (by route keys)\n this.components = {}\n // We should not keep the cache, if there's an error\n // Otherwise, this cause issues when when going back and\n // come again to the errored page.\n if (pathname !== '/_error') {\n this.components[route] = {\n Component,\n initial: true,\n props: initialProps,\n err,\n __N_SSG: initialProps && initialProps.__N_SSG,\n __N_SSP: initialProps && initialProps.__N_SSP,\n }\n }\n\n this.components['/_app'] = {\n Component: App as ComponentType,\n styleSheets: [\n /* /_app does not need its stylesheets managed */\n ],\n }\n\n // Backwards compat for Router.router.events\n // TODO: Should be remove the following major version as it was never documented\n this.events = Router.events\n\n this.pageLoader = pageLoader\n // if auto prerendered and dynamic route wait to update asPath\n // until after mount to prevent hydration mismatch\n const autoExportDynamic =\n isDynamicRoute(pathname) && self.__NEXT_DATA__.autoExport\n\n this.basePath = process.env.__NEXT_ROUTER_BASEPATH || ''\n this.sub = subscription\n this.clc = null\n this._wrapApp = wrapApp\n // make sure to ignore extra popState in safari on navigating\n // back from external site\n this.isSsr = true\n this.isLocaleDomain = false\n this.isReady = !!(\n self.__NEXT_DATA__.gssp ||\n self.__NEXT_DATA__.gip ||\n self.__NEXT_DATA__.isExperimentalCompile ||\n (self.__NEXT_DATA__.appGip && !self.__NEXT_DATA__.gsp) ||\n (!autoExportDynamic &&\n !self.location.search &&\n !process.env.__NEXT_HAS_REWRITES)\n )\n\n if (process.env.__NEXT_I18N_SUPPORT) {\n this.locales = locales\n this.defaultLocale = defaultLocale\n this.domainLocales = domainLocales\n this.isLocaleDomain = !!detectDomainLocale(\n domainLocales,\n self.location.hostname\n )\n }\n\n this.state = {\n route,\n pathname,\n query,\n asPath: autoExportDynamic ? pathname : as,\n isPreview: !!isPreview,\n locale: process.env.__NEXT_I18N_SUPPORT ? locale : undefined,\n isFallback,\n }\n\n this._initialMatchesMiddlewarePromise = Promise.resolve(false)\n\n if (typeof window !== 'undefined') {\n // make sure \"as\" doesn't start with double slashes or else it can\n // throw an error as it's considered invalid\n if (!as.startsWith('//')) {\n // in order for `e.state` to work on the `onpopstate` event\n // we have to register the initial route upon initialization\n const options: TransitionOptions = { locale }\n const asPath = getURL()\n\n this._initialMatchesMiddlewarePromise = matchesMiddleware({\n router: this,\n locale,\n asPath,\n }).then((matches) => {\n // if middleware matches we leave resolving to the change function\n // as the server needs to resolve for correct priority\n ;(options as any)._shouldResolveHref = as !== pathname\n\n this.changeState(\n 'replaceState',\n matches\n ? asPath\n : formatWithValidation({\n pathname: addBasePath(pathname),\n query,\n }),\n asPath,\n options\n )\n return matches\n })\n }\n\n window.addEventListener('popstate', this.onPopState)\n\n // enable custom scroll restoration handling when available\n // otherwise fallback to browser's default handling\n if (process.env.__NEXT_SCROLL_RESTORATION) {\n if (manualScrollRestoration) {\n window.history.scrollRestoration = 'manual'\n }\n }\n }\n }\n\n onPopState = (e: PopStateEvent): void => {\n const { isFirstPopStateEvent } = this\n this.isFirstPopStateEvent = false\n\n const state = e.state as HistoryState\n\n if (!state) {\n // We get state as undefined for two reasons.\n // 1. With older safari (< 8) and older chrome (< 34)\n // 2. When the URL changed with #\n //\n // In the both cases, we don't need to proceed and change the route.\n // (as it's already changed)\n // But we can simply replace the state with the new changes.\n // Actually, for (1) we don't need to nothing. But it's hard to detect that event.\n // So, doing the following for (1) does no harm.\n const { pathname, query } = this\n this.changeState(\n 'replaceState',\n formatWithValidation({ pathname: addBasePath(pathname), query }),\n getURL()\n )\n return\n }\n\n // __NA is used to identify if the history entry can be handled by the app-router.\n if (state.__NA) {\n window.location.reload()\n return\n }\n\n if (!state.__N) {\n return\n }\n\n // Safari fires popstateevent when reopening the browser.\n if (\n isFirstPopStateEvent &&\n this.locale === state.options.locale &&\n state.as === this.asPath\n ) {\n return\n }\n\n let forcedScroll: { x: number; y: number } | undefined\n const { url, as, options, key } = state\n if (process.env.__NEXT_SCROLL_RESTORATION) {\n if (manualScrollRestoration) {\n if (this._key !== key) {\n // Snapshot current scroll position:\n try {\n sessionStorage.setItem(\n '__next_scroll_' + this._key,\n JSON.stringify({ x: self.pageXOffset, y: self.pageYOffset })\n )\n } catch {}\n\n // Restore old scroll position:\n try {\n const v = sessionStorage.getItem('__next_scroll_' + key)\n forcedScroll = JSON.parse(v!)\n } catch {\n forcedScroll = { x: 0, y: 0 }\n }\n }\n }\n }\n this._key = key\n\n const { pathname } = parseRelativeUrl(url)\n\n // Make sure we don't re-render on initial load,\n // can be caused by navigating back from an external site\n if (\n this.isSsr &&\n as === addBasePath(this.asPath) &&\n pathname === addBasePath(this.pathname)\n ) {\n return\n }\n\n // If the downstream application returns falsy, return.\n // They will then be responsible for handling the event.\n if (this._bps && !this._bps(state)) {\n return\n }\n\n this.change(\n 'replaceState',\n url,\n as,\n Object.assign<{}, TransitionOptions, TransitionOptions>({}, options, {\n shallow: options.shallow && this._shallow,\n locale: options.locale || this.defaultLocale,\n // @ts-ignore internal value not exposed on types\n _h: 0,\n }),\n forcedScroll\n )\n }\n\n reload(): void {\n window.location.reload()\n }\n\n /**\n * Go back in history\n */\n back() {\n window.history.back()\n }\n\n /**\n * Go forward in history\n */\n forward() {\n window.history.forward()\n }\n\n /**\n * Performs a `pushState` with arguments\n * @param url of the route\n * @param as masks `url` for the browser\n * @param options object you can define `shallow` and other options\n */\n push(url: Url, as?: Url, options: TransitionOptions = {}) {\n if (\n isJavaScriptURLString(url.toString()) ||\n (as && isJavaScriptURLString(as.toString()))\n ) {\n throw new Error(\n 'Next.js has blocked a javascript: URL as a security precaution.'\n )\n }\n if (process.env.__NEXT_SCROLL_RESTORATION) {\n // TODO: remove in the future when we update history before route change\n // is complete, as the popstate event should handle this capture.\n if (manualScrollRestoration) {\n try {\n // Snapshot scroll position right before navigating to a new page:\n sessionStorage.setItem(\n '__next_scroll_' + this._key,\n JSON.stringify({ x: self.pageXOffset, y: self.pageYOffset })\n )\n } catch {}\n }\n }\n ;({ url, as } = prepareUrlAs(this, url, as))\n return this.change('pushState', url, as, options)\n }\n\n /**\n * Performs a `replaceState` with arguments\n * @param url of the route\n * @param as masks `url` for the browser\n * @param options object you can define `shallow` and other options\n */\n replace(url: Url, as?: Url, options: TransitionOptions = {}) {\n if (\n isJavaScriptURLString(url.toString()) ||\n (as && isJavaScriptURLString(as.toString()))\n ) {\n throw new Error(\n 'Next.js has blocked a javascript: URL as a security precaution.'\n )\n }\n ;({ url, as } = prepareUrlAs(this, url, as))\n return this.change('replaceState', url, as, options)\n }\n\n async _bfl(\n as: string,\n resolvedAs?: string,\n locale?: string | false,\n skipNavigate?: boolean\n ) {\n if (process.env.__NEXT_CLIENT_ROUTER_FILTER_ENABLED) {\n if (!this._bfl_s && !this._bfl_d) {\n const { BloomFilter } =\n require('../../lib/bloom-filter') as typeof import('../../lib/bloom-filter')\n\n type Filter = ReturnType<\n import('../../lib/bloom-filter').BloomFilter['export']\n >\n let staticFilterData: Filter | undefined\n let dynamicFilterData: Filter | undefined\n\n try {\n ;({\n __routerFilterStatic: staticFilterData,\n __routerFilterDynamic: dynamicFilterData,\n } = (await getClientBuildManifest()) as any as {\n __routerFilterStatic?: Filter\n __routerFilterDynamic?: Filter\n })\n } catch (err) {\n // failed to load build manifest hard navigate\n // to be safe\n console.error(err)\n if (skipNavigate) {\n return true\n }\n handleHardNavigation({\n url: addBasePath(\n addLocale(as, locale || this.locale, this.defaultLocale)\n ),\n router: this,\n })\n return new Promise(() => {})\n }\n\n const routerFilterSValue: Filter | false = process.env\n .__NEXT_CLIENT_ROUTER_S_FILTER as any\n\n if (!staticFilterData && routerFilterSValue) {\n staticFilterData = routerFilterSValue ? routerFilterSValue : undefined\n }\n\n const routerFilterDValue: Filter | false = process.env\n .__NEXT_CLIENT_ROUTER_D_FILTER as any\n\n if (!dynamicFilterData && routerFilterDValue) {\n dynamicFilterData = routerFilterDValue\n ? routerFilterDValue\n : undefined\n }\n\n if (staticFilterData?.numHashes) {\n this._bfl_s = new BloomFilter(\n staticFilterData.numItems,\n staticFilterData.errorRate\n )\n this._bfl_s.import(staticFilterData)\n }\n\n if (dynamicFilterData?.numHashes) {\n this._bfl_d = new BloomFilter(\n dynamicFilterData.numItems,\n dynamicFilterData.errorRate\n )\n this._bfl_d.import(dynamicFilterData)\n }\n }\n\n let matchesBflStatic = false\n let matchesBflDynamic = false\n const pathsToCheck: Array<{ as?: string; allowMatchCurrent?: boolean }> =\n [{ as }, { as: resolvedAs }]\n\n for (const { as: curAs, allowMatchCurrent } of pathsToCheck) {\n if (curAs) {\n const asNoSlash = removeTrailingSlash(\n new URL(curAs, 'http://n').pathname\n )\n const asNoSlashLocale = addBasePath(\n addLocale(asNoSlash, locale || this.locale)\n )\n\n if (\n allowMatchCurrent ||\n asNoSlash !==\n removeTrailingSlash(new URL(this.asPath, 'http://n').pathname)\n ) {\n matchesBflStatic =\n matchesBflStatic ||\n !!this._bfl_s?.contains(asNoSlash) ||\n !!this._bfl_s?.contains(asNoSlashLocale)\n\n for (const normalizedAS of [asNoSlash, asNoSlashLocale]) {\n // if any sub-path of as matches a dynamic filter path\n // it should be hard navigated\n const curAsParts = normalizedAS.split('/')\n for (\n let i = 0;\n !matchesBflDynamic && i < curAsParts.length + 1;\n i++\n ) {\n const currentPart = curAsParts.slice(0, i).join('/')\n if (currentPart && this._bfl_d?.contains(currentPart)) {\n matchesBflDynamic = true\n break\n }\n }\n }\n\n // if the client router filter is matched then we trigger\n // a hard navigation\n if (matchesBflStatic || matchesBflDynamic) {\n if (skipNavigate) {\n return true\n }\n handleHardNavigation({\n url: addBasePath(\n addLocale(as, locale || this.locale, this.defaultLocale)\n ),\n router: this,\n })\n return new Promise(() => {})\n }\n }\n }\n }\n }\n return false\n }\n\n private async change(\n method: HistoryMethod,\n url: string,\n as: string,\n options: TransitionOptions,\n forcedScroll?: { x: number; y: number }\n ): Promise<boolean> {\n if (!isLocalURL(url)) {\n handleHardNavigation({ url, router: this })\n return false\n }\n // WARNING: `_h` is an internal option for handing Next.js client-side\n // hydration. Your app should _never_ use this property. It may change at\n // any time without notice.\n const isQueryUpdating = (options as any)._h === 1\n\n if (!isQueryUpdating && !options.shallow) {\n await this._bfl(as, undefined, options.locale)\n }\n\n let shouldResolveHref =\n isQueryUpdating ||\n (options as any)._shouldResolveHref ||\n parsePath(url).pathname === parsePath(as).pathname\n\n const nextState = {\n ...this.state,\n }\n\n // for static pages with query params in the URL we delay\n // marking the router ready until after the query is updated\n // or a navigation has occurred\n const readyStateChange = this.isReady !== true\n this.isReady = true\n const isSsr = this.isSsr\n\n if (!isQueryUpdating) {\n this.isSsr = false\n }\n\n // if a route transition is already in progress before\n // the query updating is triggered ignore query updating\n if (isQueryUpdating && this.clc) {\n return false\n }\n\n const prevLocale = nextState.locale\n\n if (process.env.__NEXT_I18N_SUPPORT) {\n nextState.locale =\n options.locale === false\n ? this.defaultLocale\n : options.locale || nextState.locale\n\n if (typeof options.locale === 'undefined') {\n options.locale = nextState.locale\n }\n\n const parsedAs = parseRelativeUrl(\n hasBasePath(as) ? removeBasePath(as) : as\n )\n const localePathResult = normalizeLocalePath(\n parsedAs.pathname,\n this.locales\n )\n\n if (localePathResult.detectedLocale) {\n nextState.locale = localePathResult.detectedLocale\n parsedAs.pathname = addBasePath(parsedAs.pathname)\n as = formatWithValidation(parsedAs)\n url = addBasePath(\n normalizeLocalePath(\n hasBasePath(url) ? removeBasePath(url) : url,\n this.locales\n ).pathname\n )\n }\n let didNavigate = false\n\n // we need to wrap this in the env check again since regenerator runtime\n // moves this on its own due to the return\n if (process.env.__NEXT_I18N_SUPPORT) {\n // if the locale isn't configured hard navigate to show 404 page\n if (!this.locales?.includes(nextState.locale!)) {\n parsedAs.pathname = addLocale(parsedAs.pathname, nextState.locale)\n handleHardNavigation({\n url: formatWithValidation(parsedAs),\n router: this,\n })\n // this was previously a return but was removed in favor\n // of better dead code elimination with regenerator runtime\n didNavigate = true\n }\n }\n\n const detectedDomain = detectDomainLocale(\n this.domainLocales,\n undefined,\n nextState.locale\n )\n\n // we need to wrap this in the env check again since regenerator runtime\n // moves this on its own due to the return\n if (process.env.__NEXT_I18N_SUPPORT) {\n // if we are navigating to a domain locale ensure we redirect to the\n // correct domain\n if (\n !didNavigate &&\n detectedDomain &&\n this.isLocaleDomain &&\n self.location.hostname !== detectedDomain.domain\n ) {\n const asNoBasePath = removeBasePath(as)\n handleHardNavigation({\n url: `http${detectedDomain.http ? '' : 's'}://${\n detectedDomain.domain\n }${addBasePath(\n `${\n nextState.locale === detectedDomain.defaultLocale\n ? ''\n : `/${nextState.locale}`\n }${asNoBasePath === '/' ? '' : asNoBasePath}` || '/'\n )}`,\n router: this,\n })\n // this was previously a return but was removed in favor\n // of better dead code elimination with regenerator runtime\n didNavigate = true\n }\n }\n\n if (didNavigate) {\n return new Promise(() => {})\n }\n }\n\n // marking route changes as a navigation start entry\n if (ST) {\n performance.mark('routeChange')\n }\n\n const { shallow = false, scroll = true } = options\n const routeProps = { shallow }\n\n if (this._inFlightRoute && this.clc) {\n if (!isSsr) {\n Router.events.emit(\n 'routeChangeError',\n buildCancellationError(),\n this._inFlightRoute,\n routeProps\n )\n }\n this.clc()\n this.clc = null\n }\n\n as = addBasePath(\n addLocale(\n hasBasePath(as) ? removeBasePath(as) : as,\n options.locale,\n this.defaultLocale\n )\n )\n const cleanedAs = removeLocale(\n hasBasePath(as) ? removeBasePath(as) : as,\n nextState.locale\n )\n this._inFlightRoute = as\n\n const localeChange = prevLocale !== nextState.locale\n\n // If the url change is only related to a hash change\n // We should not proceed. We should only change the state.\n\n if (!isQueryUpdating && this.onlyAHashChange(cleanedAs) && !localeChange) {\n nextState.asPath = cleanedAs\n Router.events.emit('hashChangeStart', as, routeProps)\n // TODO: do we need the resolved href when only a hash change?\n this.changeState(method, url, as, {\n ...options,\n scroll: false,\n })\n if (scroll) {\n this.scrollToHash(cleanedAs)\n }\n try {\n await this.set(nextState, this.components[nextState.route], null)\n } catch (err) {\n if (isError(err) && err.cancelled) {\n Router.events.emit('routeChangeError', err, cleanedAs, routeProps)\n }\n throw err\n }\n\n Router.events.emit('hashChangeComplete', as, routeProps)\n return true\n }\n\n let parsed = parseRelativeUrl(url)\n let { pathname, query } = parsed\n\n // The build manifest needs to be loaded before auto-static dynamic pages\n // get their query parameters to allow ensuring they can be parsed properly\n // when rewritten to\n let pages: string[], rewrites: any\n try {\n ;[pages, { __rewrites: rewrites }] = await Promise.all([\n this.pageLoader.getPageList(),\n getClientBuildManifest(),\n this.pageLoader.getMiddleware(),\n ])\n } catch (err) {\n // If we fail to resolve the page list or client-build manifest, we must\n // do a server-side transition:\n handleHardNavigation({ url: as, router: this })\n return false\n }\n\n // If asked to change the current URL we should reload the current page\n // (not location.reload() but reload getInitialProps and other Next.js stuffs)\n // We also need to set the method = replaceState always\n // as this should not go into the history (That's how browsers work)\n // We should compare the new asPath to the current asPath, not the url\n if (!this.urlIsNew(cleanedAs) && !localeChange) {\n method = 'replaceState'\n }\n\n // we need to resolve the as value using rewrites for dynamic SSG\n // pages to allow building the data URL correctly\n let resolvedAs = as\n\n // url and as should always be prefixed with basePath by this\n // point by either next/link or router.push/replace so strip the\n // basePath from the pathname to match the pages dir 1-to-1\n pathname = pathname\n ? removeTrailingSlash(removeBasePath(pathname))\n : pathname\n\n let route = removeTrailingSlash(pathname)\n const parsedAsPathname = as.startsWith('/') && parseRelativeUrl(as).pathname\n\n // if we detected the path as app route during prefetching\n // trigger hard navigation\n if ((this.components[pathname] as any)?.__appRouter) {\n handleHardNavigation({ url: as, router: this })\n return new Promise(() => {})\n }\n\n const isMiddlewareRewrite = !!(\n parsedAsPathname &&\n route !== parsedAsPathname &&\n (!isDynamicRoute(route) ||\n !getRouteMatcher(getRouteRegex(route))(parsedAsPathname))\n )\n\n // we don't attempt resolve asPath when we need to execute\n // middleware as the resolving will occur server-side\n const isMiddlewareMatch =\n !options.shallow &&\n (await matchesMiddleware({\n asPath: as,\n locale: nextState.locale,\n router: this,\n }))\n\n if (isQueryUpdating && isMiddlewareMatch) {\n shouldResolveHref = false\n }\n\n if (shouldResolveHref && pathname !== '/_error') {\n ;(options as any)._shouldResolveHref = true\n\n if (process.env.__NEXT_HAS_REWRITES && as.startsWith('/')) {\n const rewritesResult = resolveRewrites(\n addBasePath(addLocale(cleanedAs, nextState.locale), true),\n pages,\n rewrites,\n query,\n (p: string) => resolveDynamicRoute(p, pages),\n this.locales\n )\n\n if (rewritesResult.externalDest) {\n handleHardNavigation({ url: as, router: this })\n return true\n }\n if (!isMiddlewareMatch) {\n resolvedAs = rewritesResult.asPath\n }\n\n if (rewritesResult.matchedPage && rewritesResult.resolvedHref) {\n // if this directly matches a page we need to update the href to\n // allow the correct page chunk to be loaded\n pathname = rewritesResult.resolvedHref\n parsed.pathname = addBasePath(pathname)\n\n if (!isMiddlewareMatch) {\n url = formatWithValidation(parsed)\n }\n }\n } else {\n parsed.pathname = resolveDynamicRoute(pathname, pages)\n\n if (parsed.pathname !== pathname) {\n pathname = parsed.pathname\n parsed.pathname = addBasePath(pathname)\n\n if (!isMiddlewareMatch) {\n url = formatWithValidation(parsed)\n }\n }\n }\n }\n\n if (!isLocalURL(as)) {\n if (process.env.NODE_ENV !== 'production') {\n throw new Error(\n `Invalid href: \"${url}\" and as: \"${as}\", received relative href and external as` +\n `\\nSee more info: https://nextjs.org/docs/messages/invalid-relative-url-external-as`\n )\n }\n handleHardNavigation({ url: as, router: this })\n return false\n }\n\n resolvedAs = removeLocale(removeBasePath(resolvedAs), nextState.locale)\n\n route = removeTrailingSlash(pathname)\n let routeMatch: Params | false = false\n\n if (isDynamicRoute(route)) {\n const parsedAs = parseRelativeUrl(resolvedAs)\n const asPathname = parsedAs.pathname\n\n const routeRegex = getRouteRegex(route)\n routeMatch = getRouteMatcher(routeRegex)(asPathname)\n const shouldInterpolate = route === asPathname\n const interpolatedAs = shouldInterpolate\n ? interpolateAs(route, asPathname, query)\n : ({} as { result: undefined; params: undefined })\n\n if (!routeMatch || (shouldInterpolate && !interpolatedAs.result)) {\n const missingParams = Object.keys(routeRegex.groups).filter(\n (param) => !query[param] && !routeRegex.groups[param].optional\n )\n\n if (missingParams.length > 0 && !isMiddlewareMatch) {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(\n `${\n shouldInterpolate\n ? `Interpolating href`\n : `Mismatching \\`as\\` and \\`href\\``\n } failed to manually provide ` +\n `the params: ${missingParams.join(\n ', '\n )} in the \\`href\\`'s \\`query\\``\n )\n }\n\n throw new Error(\n (shouldInterpolate\n ? `The provided \\`href\\` (${url}) value is missing query values (${missingParams.join(\n ', '\n )}) to be interpolated properly. `\n : `The provided \\`as\\` value (${asPathname}) is incompatible with the \\`href\\` value (${route}). `) +\n `Read more: https://nextjs.org/docs/messages/${\n shouldInterpolate\n ? 'href-interpolation-failed'\n : 'incompatible-href-as'\n }`\n )\n }\n } else if (shouldInterpolate) {\n as = formatWithValidation(\n Object.assign({}, parsedAs, {\n pathname: interpolatedAs.result,\n query: omit(query, interpolatedAs.params!),\n })\n )\n } else {\n // Merge params into `query`, overwriting any specified in search\n Object.assign(query, routeMatch)\n }\n }\n\n if (!isQueryUpdating) {\n Router.events.emit('routeChangeStart', as, routeProps)\n }\n\n const isErrorRoute = this.pathname === '/404' || this.pathname === '/_error'\n\n try {\n let routeInfo = await this.getRouteInfo({\n route,\n pathname,\n query,\n as,\n resolvedAs,\n routeProps,\n locale: nextState.locale,\n isPreview: nextState.isPreview,\n hasMiddleware: isMiddlewareMatch,\n unstable_skipClientCache: options.unstable_skipClientCache,\n isQueryUpdating: isQueryUpdating && !this.isFallback,\n isMiddlewareRewrite,\n })\n\n if (!isQueryUpdating && !options.shallow) {\n await this._bfl(\n as,\n 'resolvedAs' in routeInfo ? routeInfo.resolvedAs : undefined,\n nextState.locale\n )\n }\n\n if ('route' in routeInfo && isMiddlewareMatch) {\n pathname = routeInfo.route || route\n route = pathname\n\n if (!routeProps.shallow) {\n query = Object.assign({}, routeInfo.query || {}, query)\n }\n\n const cleanedParsedPathname = hasBasePath(parsed.pathname)\n ? removeBasePath(parsed.pathname)\n : parsed.pathname\n\n if (routeMatch && pathname !== cleanedParsedPathname) {\n Object.keys(routeMatch).forEach((key) => {\n if (routeMatch && query[key] === routeMatch[key]) {\n delete query[key]\n }\n })\n }\n\n if (isDynamicRoute(pathname)) {\n const prefixedAs =\n !routeProps.shallow && routeInfo.resolvedAs\n ? routeInfo.resolvedAs\n : addBasePath(\n addLocale(\n new URL(as, location.href).pathname,\n nextState.locale\n ),\n true\n )\n\n let rewriteAs = prefixedAs\n\n if (hasBasePath(rewriteAs)) {\n rewriteAs = removeBasePath(rewriteAs)\n }\n\n if (process.env.__NEXT_I18N_SUPPORT) {\n const localeResult = normalizeLocalePath(rewriteAs, this.locales)\n nextState.locale = localeResult.detectedLocale || nextState.locale\n rewriteAs = localeResult.pathname\n }\n const routeRegex = getRouteRegex(pathname)\n const curRouteMatch = getRouteMatcher(routeRegex)(\n new URL(rewriteAs, location.href).pathname\n )\n\n if (curRouteMatch) {\n Object.assign(query, curRouteMatch)\n }\n }\n }\n\n // If the routeInfo brings a redirect we simply apply it.\n if ('type' in routeInfo) {\n if (routeInfo.type === 'redirect-internal') {\n return this.change(method, routeInfo.newUrl, routeInfo.newAs, options)\n } else {\n handleHardNavigation({ url: routeInfo.destination, router: this })\n return new Promise(() => {})\n }\n }\n\n const component: any = routeInfo.Component\n if (component && component.unstable_scriptLoader) {\n const scripts = [].concat(component.unstable_scriptLoader())\n\n scripts.forEach((script: any) => {\n handleClientScriptLoad(script.props)\n })\n }\n\n // handle redirect on client-transition\n if ((routeInfo.__N_SSG || routeInfo.__N_SSP) && routeInfo.props) {\n if (\n routeInfo.props.pageProps &&\n routeInfo.props.pageProps.__N_REDIRECT\n ) {\n // Use the destination from redirect without adding locale\n options.locale = false\n\n const destination = routeInfo.props.pageProps.__N_REDIRECT\n\n // check if destination is internal (resolves to a page) and attempt\n // client-navigation if it is falling back to hard navigation if\n // it's not\n if (\n destination.startsWith('/') &&\n routeInfo.props.pageProps.__N_REDIRECT_BASE_PATH !== false\n ) {\n const parsedHref = parseRelativeUrl(destination)\n parsedHref.pathname = resolveDynamicRoute(\n parsedHref.pathname,\n pages\n )\n\n const { url: newUrl, as: newAs } = prepareUrlAs(\n this,\n destination,\n destination\n )\n return this.change(method, newUrl, newAs, options)\n }\n handleHardNavigation({ url: destination, router: this })\n return new Promise(() => {})\n }\n\n nextState.isPreview = !!routeInfo.props.__N_PREVIEW\n\n // handle SSG data 404\n if (routeInfo.props.notFound === SSG_DATA_NOT_FOUND) {\n let notFoundRoute\n\n try {\n await this.fetchComponent('/404')\n notFoundRoute = '/404'\n } catch (_) {\n notFoundRoute = '/_error'\n }\n\n routeInfo = await this.getRouteInfo({\n route: notFoundRoute,\n pathname: notFoundRoute,\n query,\n as,\n resolvedAs,\n routeProps: { shallow: false },\n locale: nextState.locale,\n isPreview: nextState.isPreview,\n isNotFound: true,\n })\n\n if ('type' in routeInfo) {\n throw new Error(`Unexpected middleware effect on /404`)\n }\n }\n }\n\n if (\n isQueryUpdating &&\n this.pathname === '/_error' &&\n self.__NEXT_DATA__.props?.pageProps?.statusCode === 500 &&\n routeInfo.props?.pageProps\n ) {\n // ensure statusCode is still correct for static 500 page\n // when updating query information\n routeInfo.props.pageProps.statusCode = 500\n }\n\n // shallow routing is only allowed for same page URL changes.\n const isValidShallowRoute =\n options.shallow && nextState.route === (routeInfo.route ?? route)\n\n const shouldScroll =\n options.scroll ?? (!isQueryUpdating && !isValidShallowRoute)\n const resetScroll = shouldScroll ? { x: 0, y: 0 } : null\n const upcomingScrollState = forcedScroll ?? resetScroll\n\n // the new state that the router gonna set\n const upcomingRouterState = {\n ...nextState,\n route,\n pathname,\n query,\n asPath: cleanedAs,\n isFallback: false,\n }\n\n // When the page being rendered is the 404 page, we should only update the\n // query parameters. Route changes here might add the basePath when it\n // wasn't originally present. This is also why this block is before the\n // below `changeState` call which updates the browser's history (changing\n // the URL).\n if (isQueryUpdating && isErrorRoute) {\n routeInfo = await this.getRouteInfo({\n route: this.pathname,\n pathname: this.pathname,\n query,\n as,\n resolvedAs,\n routeProps: { shallow: false },\n locale: nextState.locale,\n isPreview: nextState.isPreview,\n isQueryUpdating: isQueryUpdating && !this.isFallback,\n })\n\n if ('type' in routeInfo) {\n throw new Error(`Unexpected middleware effect on ${this.pathname}`)\n }\n\n if (\n this.pathname === '/_error' &&\n self.__NEXT_DATA__.props?.pageProps?.statusCode === 500 &&\n routeInfo.props?.pageProps\n ) {\n // ensure statusCode is still correct for static 500 page\n // when updating query information\n routeInfo.props.pageProps.statusCode = 500\n }\n\n try {\n await this.set(upcomingRouterState, routeInfo, upcomingScrollState)\n } catch (err) {\n if (isError(err) && err.cancelled) {\n Router.events.emit('routeChangeError', err, cleanedAs, routeProps)\n }\n throw err\n }\n\n return true\n }\n\n Router.events.emit('beforeHistoryChange', as, routeProps)\n this.changeState(method, url, as, options)\n\n // for query updates we can skip it if the state is unchanged and we don't\n // need to scroll\n // https://github.com/vercel/next.js/issues/37139\n const canSkipUpdating =\n isQueryUpdating &&\n !upcomingScrollState &&\n !readyStateChange &&\n !localeChange &&\n compareRouterStates(upcomingRouterState, this.state)\n\n if (!canSkipUpdating) {\n try {\n await this.set(upcomingRouterState, routeInfo, upcomingScrollState)\n } catch (e: any) {\n if (e.cancelled) routeInfo.error = routeInfo.error || e\n else throw e\n }\n\n if (routeInfo.error) {\n if (!isQueryUpdating) {\n Router.events.emit(\n 'routeChangeError',\n routeInfo.error,\n cleanedAs,\n routeProps\n )\n }\n\n throw routeInfo.error\n }\n\n if (process.env.__NEXT_I18N_SUPPORT) {\n if (nextState.locale) {\n document.documentElement.lang = nextState.locale\n }\n }\n\n if (!isQueryUpdating) {\n Router.events.emit('routeChangeComplete', as, routeProps)\n }\n\n // A hash mark # is the optional last part of a URL\n const hashRegex = /#.+$/\n if (shouldScroll && hashRegex.test(as)) {\n this.scrollToHash(as)\n }\n }\n\n return true\n } catch (err) {\n if (isError(err) && err.cancelled) {\n return false\n }\n throw err\n }\n }\n\n changeState(\n method: HistoryMethod,\n url: string,\n as: string,\n options: TransitionOptions = {}\n ): void {\n if (process.env.NODE_ENV !== 'production') {\n if (typeof window.history === 'undefined') {\n console.error(`Warning: window.history is not available.`)\n return\n }\n\n if (typeof window.history[method] === 'undefined') {\n console.error(`Warning: window.history.${method} is not available`)\n return\n }\n }\n\n if (method !== 'pushState' || getURL() !== as) {\n this._shallow = options.shallow\n window.history[method](\n {\n url,\n as,\n options,\n __N: true,\n key: (this._key = method !== 'pushState' ? this._key : createKey()),\n } as HistoryState,\n // Most browsers currently ignores this parameter, although they may use it in the future.\n // Passing the empty string here should be safe against future changes to the method.\n // https://developer.mozilla.org/docs/Web/API/History/replaceState\n '',\n as\n )\n }\n }\n\n async handleRouteInfoError(\n err: Error & { code?: any; cancelled?: boolean },\n pathname: string,\n query: ParsedUrlQuery,\n as: string,\n routeProps: RouteProperties,\n loadErrorFail?: boolean\n ): Promise<CompletePrivateRouteInfo> {\n if (err.cancelled) {\n // bubble up cancellation errors\n throw err\n }\n\n if (isAssetError(err) || loadErrorFail) {\n Router.events.emit('routeChangeError', err, as, routeProps)\n\n // If we can't load the page it could be one of following reasons\n // 1. Page doesn't exists\n // 2. Page does exist in a different zone\n // 3. Internal error while loading the page\n\n // So, doing a hard reload is the proper way to deal with this.\n handleHardNavigation({\n url: as,\n router: this,\n })\n\n // Changing the URL doesn't block executing the current code path.\n // So let's throw a cancellation error stop the routing logic.\n throw buildCancellationError()\n }\n\n console.error(err)\n\n try {\n let props: Record<string, any> | undefined\n const { page: Component, styleSheets } =\n await this.fetchComponent('/_error')\n\n const routeInfo: CompletePrivateRouteInfo = {\n props,\n Component,\n styleSheets,\n err,\n error: err,\n }\n\n if (!routeInfo.props) {\n try {\n routeInfo.props = await this.getInitialProps(Component, {\n err,\n pathname,\n query,\n } as any)\n } catch (gipErr) {\n console.error('Error in error page `getInitialProps`: ', gipErr)\n routeInfo.props = {}\n }\n }\n\n return routeInfo\n } catch (routeInfoErr) {\n return this.handleRouteInfoError(\n isError(routeInfoErr) ? routeInfoErr : new Error(routeInfoErr + ''),\n pathname,\n query,\n as,\n routeProps,\n true\n )\n }\n }\n\n async getRouteInfo({\n route: requestedRoute,\n pathname,\n query,\n as,\n resolvedAs,\n routeProps,\n locale,\n hasMiddleware,\n isPreview,\n unstable_skipClientCache,\n isQueryUpdating,\n isMiddlewareRewrite,\n isNotFound,\n }: {\n route: string\n pathname: string\n query: ParsedUrlQuery\n as: string\n resolvedAs: string\n hasMiddleware?: boolean\n routeProps: RouteProperties\n locale: string | undefined\n isPreview: boolean\n unstable_skipClientCache?: boolean\n isQueryUpdating?: boolean\n isMiddlewareRewrite?: boolean\n isNotFound?: boolean\n }) {\n /**\n * This `route` binding can change if there's a rewrite\n * so we keep a reference to the original requested route\n * so we can store the cache for it and avoid re-requesting every time\n * for shallow routing purposes.\n */\n let route = requestedRoute\n\n try {\n let existingInfo: PrivateRouteInfo | undefined = this.components[route]\n if (routeProps.shallow && existingInfo && this.route === route) {\n return existingInfo\n }\n\n const handleCancelled = getCancelledHandler({ route, router: this })\n\n if (hasMiddleware) {\n existingInfo = undefined\n }\n\n let cachedRouteInfo =\n existingInfo &&\n !('initial' in existingInfo) &&\n process.env.NODE_ENV !== 'development'\n ? existingInfo\n : undefined\n\n const isBackground = isQueryUpdating\n const fetchNextDataParams: FetchNextDataParams = {\n dataHref: this.pageLoader.getDataHref({\n href: formatWithValidation({ pathname, query }),\n skipInterpolation: true,\n asPath: isNotFound ? '/404' : resolvedAs,\n locale,\n }),\n hasMiddleware: true,\n isServerRender: this.isSsr,\n parseJSON: true,\n inflightCache: isBackground ? this.sbc : this.sdc,\n persistCache: !isPreview,\n isPrefetch: false,\n unstable_skipClientCache,\n isBackground,\n }\n\n let data:\n | WithMiddlewareEffectsOutput\n | (Pick<WithMiddlewareEffectsOutput, 'json'> &\n Omit<Partial<WithMiddlewareEffectsOutput>, 'json'>)\n | null =\n isQueryUpdating && !isMiddlewareRewrite\n ? null\n : await withMiddlewareEffects({\n fetchData: () => fetchNextData(fetchNextDataParams),\n asPath: isNotFound ? '/404' : resolvedAs,\n locale: locale,\n router: this,\n }).catch((err) => {\n // we don't hard error during query updating\n // as it's un-necessary and doesn't need to be fatal\n // unless it is a fallback route and the props can't\n // be loaded\n if (isQueryUpdating) {\n return null\n }\n throw err\n })\n\n // when rendering error routes we don't apply middleware\n // effects\n if (data && (pathname === '/_error' || pathname === '/404')) {\n data.effect = undefined\n }\n\n if (isQueryUpdating) {\n if (!data) {\n data = { json: self.__NEXT_DATA__.props }\n } else {\n data.json = self.__NEXT_DATA__.props\n }\n }\n\n handleCancelled()\n\n if (\n data?.effect?.type === 'redirect-internal' ||\n data?.effect?.type === 'redirect-external'\n ) {\n return data.effect\n }\n\n if (data?.effect?.type === 'rewrite') {\n const resolvedRoute = removeTrailingSlash(data.effect.resolvedHref)\n const pages = await this.pageLoader.getPageList()\n\n // during query updating the page must match although during\n // client-transition a redirect that doesn't match a page\n // can be returned and this should trigger a hard navigation\n // which is valid for incremental migration\n if (!isQueryUpdating || pages.includes(resolvedRoute)) {\n route = resolvedRoute\n pathname = data.effect.resolvedHref\n query = { ...query, ...data.effect.parsedAs.query }\n resolvedAs = removeBasePath(\n normalizeLocalePath(data.effect.parsedAs.pathname, this.locales)\n .pathname\n )\n\n // Check again the cache with the new destination.\n existingInfo = this.components[route]\n if (\n routeProps.shallow &&\n existingInfo &&\n this.route === route &&\n !hasMiddleware\n ) {\n // If we have a match with the current route due to rewrite,\n // we can copy the existing information to the rewritten one.\n // Then, we return the information along with the matched route.\n return { ...existingInfo, route }\n }\n }\n }\n\n if (isAPIRoute(route)) {\n handleHardNavigation({ url: as, router: this })\n return new Promise<never>(() => {})\n }\n\n const routeInfo =\n cachedRouteInfo ||\n (await this.fetchComponent(route).then<CompletePrivateRouteInfo>(\n (res) => ({\n Component: res.page,\n styleSheets: res.styleSheets,\n __N_SSG: res.mod.__N_SSG,\n __N_SSP: res.mod.__N_SSP,\n })\n ))\n\n if (process.env.NODE_ENV !== 'production') {\n const { isValidElementType } =\n require('next/dist/compiled/react-is') as typeof import('next/dist/compiled/react-is')\n if (!isValidElementType(routeInfo.Component)) {\n throw new Error(\n `The default export is not a React Component in page: \"${pathname}\"`\n )\n }\n }\n const wasBailedPrefetch = data?.response?.headers.get('x-middleware-skip')\n\n const shouldFetchData = routeInfo.__N_SSG || routeInfo.__N_SSP\n\n // For non-SSG prefetches that bailed before sending data\n // we clear the cache to fetch full response\n if (wasBailedPrefetch && data?.dataHref) {\n delete this.sdc[data.dataHref]\n }\n\n const { props, cacheKey } = await this._getData(async () => {\n if (shouldFetchData) {\n if (data?.json && !wasBailedPrefetch) {\n return { cacheKey: data.cacheKey, props: data.json }\n }\n\n const dataHref = data?.dataHref\n ? data.dataHref\n : this.pageLoader.getDataHref({\n href: formatWithValidation({ pathname, query }),\n asPath: resolvedAs,\n locale,\n })\n\n const fetched = await fetchNextData({\n dataHref,\n isServerRender: this.isSsr,\n parseJSON: true,\n inflightCache: wasBailedPrefetch ? {} : this.sdc,\n persistCache: !isPreview,\n isPrefetch: false,\n unstable_skipClientCache,\n })\n\n return {\n cacheKey: fetched.cacheKey,\n props: fetched.json || {},\n }\n }\n\n return {\n headers: {},\n props: await this.getInitialProps(\n routeInfo.Component,\n // we provide AppTree later so this needs to be `any`\n {\n pathname,\n query,\n asPath: as,\n locale,\n locales: this.locales,\n defaultLocale: this.defaultLocale,\n } as any\n ),\n }\n })\n\n // Only bust the data cache for SSP routes although\n // middleware can skip cache per request with\n // x-middleware-cache: no-cache as well\n if (routeInfo.__N_SSP && fetchNextDataParams.dataHref && cacheKey) {\n delete this.sdc[cacheKey]\n }\n\n // we kick off a HEAD request in the background\n // when a non-prefetch request is made to signal revalidation\n if (\n !this.isPreview &&\n routeInfo.__N_SSG &&\n process.env.NODE_ENV !== 'development' &&\n !isQueryUpdating\n ) {\n fetchNextData(\n Object.assign({}, fetchNextDataParams, {\n isBackground: true,\n persistCache: false,\n inflightCache: this.sbc,\n })\n ).catch(() => {})\n }\n\n props.pageProps = Object.assign({}, props.pageProps)\n routeInfo.props = props\n routeInfo.route = route\n routeInfo.query = query\n routeInfo.resolvedAs = resolvedAs\n this.components[route] = routeInfo\n\n return routeInfo\n } catch (err) {\n return this.handleRouteInfoError(\n getProperError(err),\n pathname,\n query,\n as,\n routeProps\n )\n }\n }\n\n private set(\n state: typeof this.state,\n data: PrivateRouteInfo,\n resetScroll: { x: number; y: number } | null\n ): Promise<void> {\n this.state = state\n\n return this.sub(\n data,\n this.components['/_app'].Component as AppComponent,\n resetScroll\n )\n }\n\n /**\n * Callback to execute before replacing router state\n * @param cb callback to be executed\n */\n beforePopState(cb: BeforePopStateCallback) {\n this._bps = cb\n }\n\n onlyAHashChange(as: string): boolean {\n if (!this.asPath) return false\n const [oldUrlNoHash, oldHash] = this.asPath.split('#', 2)\n const [newUrlNoHash, newHash] = as.split('#', 2)\n\n // Makes sure we scroll to the provided hash if the url/hash are the same\n if (newHash && oldUrlNoHash === newUrlNoHash && oldHash === newHash) {\n return true\n }\n\n // If the urls are change, there's more than a hash change\n if (oldUrlNoHash !== newUrlNoHash) {\n return false\n }\n\n // If the hash has changed, then it's a hash only change.\n // This check is necessary to handle both the enter and\n // leave hash === '' cases. The identity case falls through\n // and is treated as a next reload.\n return oldHash !== newHash\n }\n\n scrollToHash(as: string): void {\n const [, hash = ''] = as.split('#', 2)\n\n disableSmoothScrollDuringRouteTransition(\n () => {\n // Scroll to top if the hash is just `#` with no value or `#top`\n // To mirror browsers\n if (hash === '' || hash === 'top') {\n window.scrollTo(0, 0)\n return\n }\n\n // Decode hash to make non-latin anchor works.\n const rawHash = decodeURIComponent(hash)\n // First we check if the element by id is found\n const idEl = document.getElementById(rawHash)\n if (idEl) {\n idEl.scrollIntoView()\n return\n }\n // If there's no element with the id, we check the `name` property\n // To mirror browsers\n const nameEl = document.getElementsByName(rawHash)[0]\n if (nameEl) {\n nameEl.scrollIntoView()\n }\n },\n {\n onlyHashChange: this.onlyAHashChange(as),\n }\n )\n }\n\n urlIsNew(asPath: string): boolean {\n return this.asPath !== asPath\n }\n\n /**\n * Prefetch page code, you may wait for the data during page rendering.\n * This feature only works in production!\n * @param url the href of prefetched page\n * @param asPath the as path of the prefetched page\n */\n async prefetch(\n url: string,\n asPath: string = url,\n options: PrefetchOptions = {}\n ): Promise<void> {\n // Prefetch is not supported in development mode because it would trigger on-demand-entries\n if (process.env.NODE_ENV !== 'production') {\n return\n }\n\n if (typeof window !== 'undefined' && isBot(window.navigator.userAgent)) {\n // No prefetches for bots that render the link since they are typically navigating\n // links via the equivalent of a hard navigation and hence never utilize these\n // prefetches.\n return\n }\n let parsed = parseRelativeUrl(url)\n const urlPathname = parsed.pathname\n\n let { pathname, query } = parsed\n const originalPathname = pathname\n\n if (process.env.__NEXT_I18N_SUPPORT) {\n if (options.locale === false) {\n pathname = normalizeLocalePath!(pathname, this.locales).pathname\n parsed.pathname = pathname\n url = formatWithValidation(parsed)\n\n let parsedAs = parseRelativeUrl(asPath)\n const localePathResult = normalizeLocalePath!(\n parsedAs.pathname,\n this.locales\n )\n parsedAs.pathname = localePathResult.pathname\n options.locale = localePathResult.detectedLocale || this.defaultLocale\n asPath = formatWithValidation(parsedAs)\n }\n }\n\n const pages = await this.pageLoader.getPageList()\n let resolvedAs = asPath\n\n const locale =\n typeof options.locale !== 'undefined'\n ? options.locale || undefined\n : this.locale\n\n const isMiddlewareMatch = await matchesMiddleware({\n asPath: asPath,\n locale: locale,\n router: this,\n })\n\n if (process.env.__NEXT_HAS_REWRITES && asPath.startsWith('/')) {\n let rewrites: any\n ;({ __rewrites: rewrites } = await getClientBuildManifest())\n\n const rewritesResult = resolveRewrites(\n addBasePath(addLocale(asPath, this.locale), true),\n pages,\n rewrites,\n parsed.query,\n (p: string) => resolveDynamicRoute(p, pages),\n this.locales\n )\n\n if (rewritesResult.externalDest) {\n return\n }\n\n if (!isMiddlewareMatch) {\n resolvedAs = removeLocale(\n removeBasePath(rewritesResult.asPath),\n this.locale\n )\n }\n\n if (rewritesResult.matchedPage && rewritesResult.resolvedHref) {\n // if this directly matches a page we need to update the href to\n // allow the correct page chunk to be loaded\n pathname = rewritesResult.resolvedHref\n parsed.pathname = pathname\n\n if (!isMiddlewareMatch) {\n url = formatWithValidation(parsed)\n }\n }\n }\n parsed.pathname = resolveDynamicRoute(parsed.pathname, pages)\n\n if (isDynamicRoute(parsed.pathname)) {\n pathname = parsed.pathname\n parsed.pathname = pathname\n Object.assign(\n query,\n getRouteMatcher(getRouteRegex(parsed.pathname))(\n parsePath(asPath).pathname\n ) || {}\n )\n\n if (!isMiddlewareMatch) {\n url = formatWithValidation(parsed)\n }\n }\n\n const data =\n process.env.__NEXT_MIDDLEWARE_PREFETCH === 'strict'\n ? null\n : await withMiddlewareEffects({\n fetchData: () =>\n fetchNextData({\n dataHref: this.pageLoader.getDataHref({\n href: formatWithValidation({\n pathname: originalPathname,\n query,\n }),\n skipInterpolation: true,\n asPath: resolvedAs,\n locale,\n }),\n hasMiddleware: true,\n isServerRender: false,\n parseJSON: true,\n inflightCache: this.sdc,\n persistCache: !this.isPreview,\n isPrefetch: true,\n }),\n asPath: asPath,\n locale: locale,\n router: this,\n })\n\n /**\n * If there was a rewrite we apply the effects of the rewrite on the\n * current parameters for the prefetch.\n */\n if (data?.effect.type === 'rewrite') {\n parsed.pathname = data.effect.resolvedHref\n pathname = data.effect.resolvedHref\n query = { ...query, ...data.effect.parsedAs.query }\n resolvedAs = data.effect.parsedAs.pathname\n url = formatWithValidation(parsed)\n }\n\n /**\n * If there is a redirect to an external destination then we don't have\n * to prefetch content as it will be unused.\n */\n if (data?.effect.type === 'redirect-external') {\n return\n }\n\n const route = removeTrailingSlash(pathname)\n\n if (await this._bfl(asPath, resolvedAs, options.locale, true)) {\n this.components[urlPathname] = { __appRouter: true } as any\n }\n\n await Promise.all([\n this.pageLoader._isSsg(route).then((isSsg) => {\n return isSsg\n ? fetchNextData({\n dataHref: data?.json\n ? data?.dataHref\n : this.pageLoader.getDataHref({\n href: url,\n asPath: resolvedAs,\n locale: locale,\n }),\n isServerRender: false,\n parseJSON: true,\n inflightCache: this.sdc,\n persistCache: !this.isPreview,\n isPrefetch: true,\n unstable_skipClientCache:\n options.unstable_skipClientCache ||\n (options.priority &&\n !!process.env.__NEXT_OPTIMISTIC_CLIENT_CACHE),\n })\n .then(() => false)\n .catch(() => false)\n : false\n }),\n this.pageLoader[options.priority ? 'loadPage' : 'prefetch'](route),\n ])\n }\n\n async fetchComponent(route: string) {\n const handleCancelled = getCancelledHandler({ route, router: this })\n\n try {\n const componentResult = await this.pageLoader.loadPage(route)\n handleCancelled()\n\n return componentResult\n } catch (err) {\n handleCancelled()\n throw err\n }\n }\n\n _getData<T>(fn: () => Promise<T>): Promise<T> {\n let cancelled = false\n const cancel = () => {\n cancelled = true\n }\n this.clc = cancel\n return fn().then((data) => {\n if (cancel === this.clc) {\n this.clc = null\n }\n\n if (cancelled) {\n const err: any = new Error('Loading initial props cancelled')\n err.cancelled = true\n throw err\n }\n\n return data\n })\n }\n\n getInitialProps(\n Component: ComponentType,\n ctx: NextPageContext\n ): Promise<Record<string, any>> {\n const { Component: App } = this.components['/_app']\n const AppTree = this._wrapApp(App as AppComponent)\n ctx.AppTree = AppTree\n return loadGetInitialProps<AppContextType<Router>>(App, {\n AppTree,\n Component,\n router: this,\n ctx,\n })\n }\n\n get route(): string {\n return this.state.route\n }\n\n get pathname(): string {\n return this.state.pathname\n }\n\n get query(): ParsedUrlQuery {\n return this.state.query\n }\n\n get asPath(): string {\n return this.state.asPath\n }\n\n get locale(): string | undefined {\n return this.state.locale\n }\n\n get isFallback(): boolean {\n return this.state.isFallback\n }\n\n get isPreview(): boolean {\n return this.state.isPreview\n }\n}\n"],"names":["createKey","Router","matchesMiddleware","resolveRewrites","process","env","__NEXT_HAS_REWRITES","require","default","buildCancellationError","Object","assign","Error","cancelled","options","matchers","Promise","resolve","router","pageLoader","getMiddleware","pathname","asPathname","parsePath","asPath","cleanedAs","hasBasePath","removeBasePath","asWithBasePathAndLocale","addBasePath","addLocale","locale","some","m","RegExp","regexp","test","stripOrigin","url","origin","getLocationOrigin","startsWith","substring","length","prepareUrlAs","as","resolvedHref","resolvedAs","resolveHref","hrefWasAbsolute","asWasAbsolute","preparedUrl","preparedAs","resolveDynamicRoute","pages","cleanPathname","removeTrailingSlash","denormalizePagePath","includes","page","isDynamicRoute","getRouteRegex","re","getMiddlewareData","source","response","nextConfig","basePath","i18n","locales","trailingSlash","Boolean","__NEXT_TRAILING_SLASH","rewriteHeader","headers","get","rewriteTarget","matchedPath","MATCHED_PATH_HEADER","__NEXT_EXTERNAL_MIDDLEWARE_REWRITE_RESOLVE","parsedRewriteTarget","parseRelativeUrl","pathnameInfo","getNextPathnameInfo","parseData","fsPathname","all","getPageList","getClientBuildManifest","then","__rewrites","rewrites","normalizeLocalePath","parsedSource","undefined","result","query","path","matchedPage","parsedAs","resolvedPathname","matches","getRouteMatcher","type","src","formatNextPathnameInfo","defaultLocale","buildId","destination","hash","redirectTarget","newAs","newUrl","withMiddlewareEffects","fetchData","data","effect","dataHref","json","text","cacheKey","manualScrollRestoration","__NEXT_SCROLL_RESTORATION","window","history","v","sessionStorage","setItem","removeItem","n","SSG_DATA_NOT_FOUND","Symbol","fetchRetry","attempts","fetch","credentials","method","ok","status","tryToParseAsJSON","JSON","parse","error","fetchNextData","inflightCache","isPrefetch","hasMiddleware","isServerRender","parseJSON","persistCache","isBackground","unstable_skipClientCache","href","URL","location","deploymentId","getDeploymentId","getData","params","purpose","notFound","markAssetError","dplResponseHeader","NEXT_NAV_DEPLOYMENT_ID_HEADER","NODE_ENV","catch","err","message","Math","random","toString","slice","handleHardNavigation","getCancelledHandler","route","cancel","clc","handleCancelled","events","mitt","constructor","initialProps","App","wrapApp","Component","subscription","isFallback","domainLocales","isPreview","sdc","sbc","isFirstPopStateEvent","_key","onPopState","e","state","changeState","formatWithValidation","getURL","__NA","reload","__N","forcedScroll","key","stringify","x","self","pageXOffset","y","pageYOffset","getItem","isSsr","_bps","change","shallow","_shallow","_h","components","initial","props","__N_SSG","__N_SSP","styleSheets","autoExportDynamic","__NEXT_DATA__","autoExport","__NEXT_ROUTER_BASEPATH","sub","_wrapApp","isLocaleDomain","isReady","gssp","gip","isExperimentalCompile","appGip","gsp","search","__NEXT_I18N_SUPPORT","detectDomainLocale","hostname","_initialMatchesMiddlewarePromise","_shouldResolveHref","addEventListener","scrollRestoration","back","forward","push","isJavaScriptURLString","replace","_bfl","skipNavigate","__NEXT_CLIENT_ROUTER_FILTER_ENABLED","_bfl_s","_bfl_d","BloomFilter","staticFilterData","dynamicFilterData","__routerFilterStatic","__routerFilterDynamic","console","routerFilterSValue","__NEXT_CLIENT_ROUTER_S_FILTER","routerFilterDValue","__NEXT_CLIENT_ROUTER_D_FILTER","numHashes","numItems","errorRate","import","matchesBflStatic","matchesBflDynamic","pathsToCheck","curAs","allowMatchCurrent","asNoSlash","asNoSlashLocale","contains","normalizedAS","curAsParts","split","i","currentPart","join","isLocalURL","isQueryUpdating","shouldResolveHref","nextState","readyStateChange","prevLocale","localePathResult","detectedLocale","didNavigate","detectedDomain","domain","asNoBasePath","http","ST","performance","mark","scroll","routeProps","_inFlightRoute","emit","removeLocale","localeChange","onlyAHashChange","scrollToHash","set","isError","parsed","urlIsNew","parsedAsPathname","__appRouter","isMiddlewareRewrite","isMiddlewareMatch","rewritesResult","p","externalDest","routeMatch","routeRegex","shouldInterpolate","interpolatedAs","interpolateAs","missingParams","keys","groups","filter","param","optional","warn","omit","isErrorRoute","routeInfo","getRouteInfo","cleanedParsedPathname","forEach","prefixedAs","rewriteAs","localeResult","curRouteMatch","component","unstable_scriptLoader","scripts","concat","script","handleClientScriptLoad","pageProps","__N_REDIRECT","__N_REDIRECT_BASE_PATH","parsedHref","__N_PREVIEW","notFoundRoute","fetchComponent","_","isNotFound","statusCode","isValidShallowRoute","shouldScroll","resetScroll","upcomingScrollState","upcomingRouterState","canSkipUpdating","compareRouterStates","document","documentElement","lang","hashRegex","handleRouteInfoError","loadErrorFail","isAssetError","getInitialProps","gipErr","routeInfoErr","requestedRoute","existingInfo","cachedRouteInfo","fetchNextDataParams","getDataHref","skipInterpolation","resolvedRoute","isAPIRoute","res","mod","isValidElementType","wasBailedPrefetch","shouldFetchData","_getData","fetched","getProperError","beforePopState","cb","oldUrlNoHash","oldHash","newUrlNoHash","newHash","disableSmoothScrollDuringRouteTransition","scrollTo","rawHash","decodeURIComponent","idEl","getElementById","scrollIntoView","nameEl","getElementsByName","onlyHashChange","prefetch","isBot","navigator","userAgent","urlPathname","originalPathname","__NEXT_MIDDLEWARE_PREFETCH","_isSsg","isSsg","priority","__NEXT_OPTIMISTIC_CLIENT_CACHE","componentResult","loadPage","fn","ctx","AppTree","loadGetInitialProps"],"mappings":"AA46BQI,QAAQC,GAAG,CAACqH,yBAAyB,EAAE;;;;;;;;;;;;;;;;;IAzS/B1H,SAAS,EAAA;eAATA;;IAiDhB,OAi5DC,EAAA;eAj5DoBC;;IA/kBCC,iBAAiB,EAAA;eAAjBA;;;;;qCA5Fc;6BAK7B;wBACgC;mEACC;qCACJ;qCACA;+DACnB;uBACkD;2BACpC;kCACE;8BACD;4BACF;2BACO;oCACF;2BACT;2BACA;8BACG;gCACE;6BACH;6BACA;6BACA;4BACD;qCACS;wCACG;+BACH;4BACT;uBACL;sBACD;+BACS;qCAC2B;2BAKlD;8BACyB;+BACM;AAEtC,IAAIC;AACJ,IAAIC,QAAQC,GAAG,CAACC,mBAAmB,EAAE;;AAoCrC,SAASG;IACP,OAAOC,OAAOC,MAAM,CAAC,OAAA,cAA4B,CAA5B,IAAIC,MAAM,oBAAV,qBAAA;eAAA;oBAAA;sBAAA;IAA2B,IAAG;QACjDC,WAAW;IACb;AACF;AASO,eAAeX,kBACpBY,OAAkC;IAElC,MAAMC,WAAW,MAAMC,QAAQC,OAAO,CACpCH,QAAQI,MAAM,CAACC,UAAU,CAACC,aAAa;IAEzC,IAAI,CAACL,UAAU,OAAO;IAEtB,MAAM,EAAEM,UAAUC,UAAU,EAAE,GAAGC,CAAAA,GAAAA,WAAAA,SAAS,EAACT,QAAQU,MAAM;IACzD,6FAA6F;IAC7F,MAAMC,YAAYC,CAAAA,GAAAA,aAAAA,WAAW,EAACJ,cAC1BK,CAAAA,GAAAA,gBAAAA,cAAc,EAACL,cACfA;IACJ,MAAMM,0BAA0BC,CAAAA,GAAAA,aAAAA,WAAW,EACzCC,CAAAA,GAAAA,WAA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CAACrB,KAAK;IACzB;IAEA,IAAIzJ,WAAmB;QACrB,OAAO,IAAI,CAAC8K,KAAK,CAAC9K,QAAQ;IAC5B;IAEA,IAAI2E,QAAwB;QAC1B,OAAO,IAAI,CAACmG,KAAK,CAACnG,KAAK;IACzB;IAEA,IAAIxE,SAAiB;QACnB,OAAO,IAAI,CAAC2K,KAAK,CAAC3K,MAAM;IAC1B;IAEA,IAAIO,SAA6B;QAC/B,OAAO,IAAI,CAACoK,KAAK,CAACpK,MAAM;IAC1B;IAEA,IAAI2J,aAAsB;QACxB,OAAO,IAAI,CAACS,KAAK,CAACT,UAAU;IAC9B;IAEA,IAAIE,YAAqB;QACvB,OAAO,IAAI,CAACO,KAAK,CAACP,SAAS;IAC7B;AACF","ignoreList":[0]}},
59
- {"offset": {"line": 5415, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/image-config.ts"],"sourcesContent":["export const VALID_LOADERS = [\n 'default',\n 'imgix',\n 'cloudinary',\n 'akamai',\n 'custom',\n] as const\n\nexport type LoaderValue = (typeof VALID_LOADERS)[number]\n\nexport type ImageLoaderProps = {\n src: string\n width: number\n quality?: number\n}\n\nexport type ImageLoaderPropsWithConfig = ImageLoaderProps & {\n config: Readonly<ImageConfig>\n}\n\nexport type LocalPattern = {\n /**\n * Can be literal or wildcard.\n * Single `*` matches a single path segment.\n * Double `**` matches any number of path segments.\n */\n pathname?: string\n\n /**\n * Can be literal query string such as `?v=1` or\n * empty string meaning no query string.\n */\n search?: string\n}\n\nexport type RemotePattern = {\n /**\n * Must be `http` or `https`.\n */\n protocol?: 'http' | 'https'\n\n /**\n * Can be literal or wildcard.\n * Single `*` matches a single subdomain.\n * Double `**` matches any number of subdomains.\n */\n hostname: string\n\n /**\n * Can be literal port such as `8080` or empty string\n * meaning no port.\n */\n port?: string\n\n /**\n * Can be literal or wildcard.\n * Single `*` matches a single path segment.\n * Double `**` matches any number of path segments.\n */\n pathname?: string\n\n /**\n * Can be literal query string such as `?v=1` or\n * empty string meaning no query string.\n */\n search?: string\n}\n\ntype ImageFormat = 'image/avif' | 'image/webp'\n\n/**\n * Image configurations\n *\n * @see [Image configuration options](https://nextjs.org/docs/api-reference/next/image#configuration-options)\n */\nexport type ImageConfigComplete = {\n /** @see [Device sizes documentation](https://nextjs.org/docs/api-reference/next/image#device-sizes) */\n deviceSizes: number[]\n\n /** @see [Image sizing documentation](https://nextjs.org/docs/app/building-your-application/optimizing/images#image-sizing) */\n imageSizes: number[]\n\n /** @see [Image loaders configuration](https://nextjs.org/docs/api-reference/next/legacy/image#loader) */\n loader: LoaderValue\n\n /** @see [Image loader configuration](https://nextjs.org/docs/app/api-reference/components/image#path) */\n path: string\n\n /** @see [Image loader configuration](https://nextjs.org/docs/api-reference/next/image#loader-configuration) */\n loaderFile: string\n\n /**\n * @deprecated Use `remotePatterns` instead.\n */\n domains: string[]\n\n /** @see [Disable static image import configuration](https://nextjs.org/docs/api-reference/next/image#disable-static-imports) */\n disableStaticImages: boolean\n\n /** @see [Cache behavior](https://nextjs.org/docs/api-reference/next/image#caching-behavior) */\n minimumCacheTTL: number\n\n /** @see [Acceptable formats](https://nextjs.org/docs/api-reference/next/image#acceptable-formats) */\n formats: ImageFormat[]\n\n /** @see [Maximum Disk Cache Size (in bytes)](https://nextjs.org/docs/api-reference/next/image#maximumdiskcachesize) */\n maximumDiskCacheSize: number | undefined\n\n /** @see [Maximum Redirects](https://nextjs.org/docs/api-reference/next/image#maximumredirects) */\n maximumRedirects: number\n\n /** @see [Maximum Response Body](https://nextjs.org/docs/api-reference/next/image#maximumresponsebody) */\n maximumResponseBody: number\n\n /** @see [Dangerously Allow Local IP](https://nextjs.org/docs/api-reference/next/image#dangerously-allow-local-ip) */\n dangerouslyAllowLocalIP: boolean\n\n /** @see [Dangerously Allow SVG](https://nextjs.org/docs/api-reference/next/image#dangerously-allow-svg) */\n dangerouslyAllowSVG: boolean\n\n /** @see [Content Security Policy](https://nextjs.org/docs/api-reference/next/image#contentsecuritypolicy) */\n contentSecurityPolicy: string\n\n /** @see [Content Disposition Type](https://nextjs.org/docs/api-reference/next/image#contentdispositiontype) */\n contentDispositionType: 'inline' | 'attachment'\n\n /** @see [Remote Patterns](https://nextjs.org/docs/api-reference/next/image#remotepatterns) */\n remotePatterns: Array<URL | RemotePattern>\n\n /** @see [Local Patterns](https://nextjs.org/docs/api-reference/next/image#localPatterns) */\n localPatterns: LocalPattern[] | undefined\n\n /** @see [Qualities](https://nextjs.org/docs/api-reference/next/image#qualities) */\n qualities: number[] | undefined\n\n /** @see [Unoptimized](https://nextjs.org/docs/api-reference/next/image#unoptimized) */\n unoptimized: boolean\n\n /**\n * When true, the `cacheHandler` configured in next.config.js will also be used\n * for caching optimized images. When false, images use the default filesystem cache.\n * @see [Image Optimization Caching](https://nextjs.org/docs/app/api-reference/config/next-config-js/cacheHandler#image-optimization-caching)\n */\n customCacheHandler: boolean\n}\n\nexport type ImageConfig = Partial<ImageConfigComplete>\n\nexport const imageConfigDefault: ImageConfigComplete = {\n deviceSizes: [640, 750, 828, 1080, 1200, 1920, 2048, 3840],\n imageSizes: [32, 48, 64, 96, 128, 256, 384],\n path: '/_next/image',\n loader: 'default',\n loaderFile: '',\n /**\n * @deprecated Use `remotePatterns` instead to protect your application from malicious users.\n */\n domains: [],\n disableStaticImages: false,\n minimumCacheTTL: 14400, // 4 hours\n formats: ['image/webp'],\n maximumDiskCacheSize: undefined, // auto-detect by default\n maximumRedirects: 3,\n maximumResponseBody: 50_000_000, // 50 MB\n dangerouslyAllowLocalIP: false,\n dangerouslyAllowSVG: false,\n contentSecurityPolicy: `script-src 'none'; frame-src 'none'; sandbox;`,\n contentDispositionType: 'attachment',\n localPatterns: undefined, // default: allow all local images\n remotePatterns: [], // default: allow no remote images\n qualities: [75],\n unoptimized: false,\n customCacheHandler: false,\n}\n"],"names":["VALID_LOADERS","imageConfigDefault","deviceSizes","imageSizes","path","loader","loaderFile","domains","disableStaticImages","minimumCacheTTL","formats","maximumDiskCacheSize","undefined","maximumRedirects","maximumResponseBody","dangerouslyAllowLocalIP","dangerouslyAllowSVG","contentSecurityPolicy","contentDispositionType","localPatterns","remotePatterns","qualities","unoptimized","customCacheHandler"],"mappings":";;;;;;;;;;;;;;IAAaA,aAAa,EAAA;eAAbA;;IAoJAC,kBAAkB,EAAA;eAAlBA;;;AApJN,MAAMD,gBAAgB;IAC3B;IACA;IACA;IACA;IACA;CACD;AA8IM,MAAMC,qBAA0C;IACrDC,aAAa;QAAC;QAAK;QAAK;QAAK;QAAM;QAAM;QAAM;QAAM;KAAK;IAC1DC,YAAY;QAAC;QAAI;QAAI;QAAI;QAAI;QAAK;QAAK;KAAI;IAC3CC,MAAM;IACNC,QAAQ;IACRC,YAAY;IACZ;;GAEC,GACDC,SAAS,EAAE;IACXC,qBAAqB;IACrBC,iBAAiB;IACjBC,SAAS;QAAC;KAAa;IACvBC,sBAAsBC;IACtBC,kBAAkB;IAClBC,qBAAqB;IACrBC,yBAAyB;IACzBC,qBAAqB;IACrBC,uBAAuB,CAAC,6CAA6C,CAAC;IACtEC,wBAAwB;IACxBC,eAAeP;IACfQ,gBAAgB,EAAE;IAClBC,WAAW;QAAC;KAAG;IACfC,aAAa;IACbC,oBAAoB;AACtB","ignoreList":[0]}},
60
- {"offset": {"line": 5493, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/image-config-context.shared-runtime.ts"],"sourcesContent":["import React from 'react'\nimport type { ImageConfigComplete } from './image-config'\nimport { imageConfigDefault } from './image-config'\n\nexport const ImageConfigContext =\n React.createContext<ImageConfigComplete>(imageConfigDefault)\n\nif (process.env.NODE_ENV !== 'production') {\n ImageConfigContext.displayName = 'ImageConfigContext'\n}\n"],"names":["ImageConfigContext","React","createContext","imageConfigDefault","process","env","NODE_ENV","displayName"],"mappings":"AAOII,QAAQC,GAAG,CAACC,QAAQ,KAAK;;;;;+BAHhBN,sBAAAA;;;eAAAA;;;;gEAJK;6BAEiB;AAE5B,MAAMA,qBACXC,OAAAA,OAAK,CAACC,aAAa,CAAsBC,aAAAA,kBAAkB;AAE7D,wCAA2C;IACzCH,mBAAmBO,WAAW,GAAG;AACnC","ignoreList":[0]}},
61
- {"offset": {"line": 5515, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/app-router-context.shared-runtime.ts"],"sourcesContent":["'use client'\n\nimport type {\n FocusAndScrollRef,\n PrefetchKind,\n} from '../../client/components/router-reducer/router-reducer-types'\nimport type { Params } from '../../server/request/params'\nimport type {\n FlightRouterState,\n FlightSegmentPath,\n CacheNode,\n LoadingModuleData,\n} from './app-router-types'\nimport React from 'react'\n\nexport interface NavigateOptions {\n scroll?: boolean\n /**\n * Transition types to apply when navigating. These types are passed to\n * [`React.addTransitionType`](https://react.dev/reference/react/addTransitionType)\n * inside the navigation transition, enabling\n * [`<ViewTransition>`](https://react.dev/reference/react/ViewTransition) components\n * to apply different animations based on the type of navigation.\n */\n transitionTypes?: string[]\n}\n\nexport interface PrefetchOptions {\n kind: PrefetchKind\n onInvalidate?: () => void\n}\n\nexport interface AppRouterInstance {\n /**\n * Navigate to the previous history entry.\n */\n back(): void\n /**\n * Navigate to the next history entry.\n */\n forward(): void\n /**\n * Refresh the current page.\n */\n refresh(): void\n /**\n * Refresh the current page. Use in development only.\n * @internal\n */\n hmrRefresh(): void\n /**\n * Navigate to the provided href.\n * Pushes a new history entry.\n */\n push(href: string, options?: NavigateOptions): void\n /**\n * Navigate to the provided href.\n * Replaces the current history entry.\n */\n replace(href: string, options?: NavigateOptions): void\n /**\n * Prefetch the provided href.\n */\n prefetch(href: string, options?: PrefetchOptions): void\n /**\n * Perform a gesture navigation using prefetched data.\n * Only available when experimental.gestureTransition is enabled.\n * @experimental\n */\n experimental_gesturePush?(href: string, options?: NavigateOptions): void\n}\n\nexport const AppRouterContext = React.createContext<AppRouterInstance | null>(\n null\n)\nexport const LayoutRouterContext = React.createContext<{\n parentTree: FlightRouterState\n parentCacheNode: CacheNode\n parentSegmentPath: FlightSegmentPath | null\n parentParams: Params\n parentLoadingData: LoadingModuleData | null\n debugNameContext: string\n url: string\n isActive: boolean\n} | null>(null)\n\nexport const GlobalLayoutRouterContext = React.createContext<{\n tree: FlightRouterState\n focusAndScrollRef: FocusAndScrollRef\n nextUrl: string | null\n previousNextUrl: string | null\n}>(null as any)\n\nexport const TemplateContext = React.createContext<React.ReactNode>(null as any)\n\nif (process.env.NODE_ENV !== 'production') {\n AppRouterContext.displayName = 'AppRouterContext'\n LayoutRouterContext.displayName = 'LayoutRouterContext'\n GlobalLayoutRouterContext.displayName = 'GlobalLayoutRouterContext'\n TemplateContext.displayName = 'TemplateContext'\n}\n\nexport const MissingSlotContext = React.createContext<Set<string>>(new Set())\n"],"names":["AppRouterContext","GlobalLayoutRouterContext","LayoutRouterContext","MissingSlotContext","TemplateContext","React","createContext","process","env","NODE_ENV","displayName","Set"],"mappings":"AA+FIO,QAAQC,GAAG,CAACC,QAAQ,KAAK;AA/F7B;;;;;;;;;;;;;;;;;;;IAwEaT,gBAAgB,EAAA;eAAhBA;;IAcAC,yBAAyB,EAAA;eAAzBA;;IAXAC,mBAAmB,EAAA;eAAnBA;;IA2BAC,kBAAkB,EAAA;eAAlBA;;IATAC,eAAe,EAAA;eAAfA;;;;gEAhFK;AA2DX,MAAMJ,mBAAmBK,OAAAA,OAAK,CAACC,aAAa,CACjD;AAEK,MAAMJ,sBAAsBG,OAAAA,OAAK,CAACC,aAAa,CAS5C;AAEH,MAAML,4BAA4BI,OAAAA,OAAK,CAACC,aAAa,CAKzD;AAEI,MAAMF,kBAAkBC,OAAAA,OAAK,CAACC,aAAa,CAAkB;AAEpE,wCAA2C;IACzCN,iBAAiBU,WAAW,GAAG;IAC/BR,oBAAoBQ,WAAW,GAAG;IAClCT,0BAA0BS,WAAW,GAAG;IACxCN,gBAAgBM,WAAW,GAAG;AAChC;AAEO,MAAMP,qBAAqBE,OAAAA,OAAK,CAACC,aAAa,CAAc,IAAIK","ignoreList":[0]}},
62
- {"offset": {"line": 5568, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/hooks-client-context.shared-runtime.ts"],"sourcesContent":["'use client'\n\nimport { createContext } from 'react'\nimport type { Params } from '../../server/request/params'\nimport { ReadonlyURLSearchParams } from '../../client/components/readonly-url-search-params'\n\nexport const SearchParamsContext = createContext<URLSearchParams | null>(null)\nexport const PathnameContext = createContext<string | null>(null)\nexport const PathParamsContext = createContext<Params | null>(null)\n\n// Dev-only context for Suspense DevTools instrumentation\n// These promises are used to track navigation hook usage in React DevTools\nexport type InstrumentedPromise<T> = Promise<T> & {\n status: 'fulfilled'\n value: T\n displayName: string\n}\n\nexport type NavigationPromises = {\n pathname: InstrumentedPromise<string>\n searchParams: InstrumentedPromise<ReadonlyURLSearchParams>\n params: InstrumentedPromise<Params>\n // Layout segment hooks (updated at each layout boundary)\n selectedLayoutSegmentPromises?: Map<\n string,\n InstrumentedPromise<string | null>\n >\n selectedLayoutSegmentsPromises?: Map<string, InstrumentedPromise<string[]>>\n}\n\nexport const NavigationPromisesContext =\n createContext<NavigationPromises | null>(null)\n\n// Creates an instrumented promise for Suspense DevTools\n// These promises are always fulfilled and exist purely for\n// tracking in React's Suspense DevTools.\nexport function createDevToolsInstrumentedPromise<T>(\n displayName: string,\n value: T\n): InstrumentedPromise<T> {\n const promise = Promise.resolve(value) as InstrumentedPromise<T>\n promise.status = 'fulfilled'\n promise.value = value\n promise.displayName = `${displayName} (SSR)`\n return promise\n}\n\nexport { ReadonlyURLSearchParams }\n\nif (process.env.NODE_ENV !== 'production') {\n SearchParamsContext.displayName = 'SearchParamsContext'\n PathnameContext.displayName = 'PathnameContext'\n PathParamsContext.displayName = 'PathParamsContext'\n NavigationPromisesContext.displayName = 'NavigationPromisesContext'\n}\n"],"names":["NavigationPromisesContext","PathParamsContext","PathnameContext","ReadonlyURLSearchParams","SearchParamsContext","createDevToolsInstrumentedPromise","createContext","displayName","value","promise","Promise","resolve","status","process","env","NODE_ENV"],"mappings":"AAiDIa,QAAQC,GAAG,CAACC,QAAQ,KAAK;AAjD7B;;;;;;;;;;;;;;;;;;;;IA8Baf,yBAAyB,EAAA;eAAzBA;;IAtBAC,iBAAiB,EAAA;eAAjBA;;IADAC,eAAe,EAAA;eAAfA;;IAwCJC,uBAAuB,EAAA;eAAvBA,yBAAAA,uBAAuB;;IAzCnBC,mBAAmB,EAAA;eAAnBA;;IA8BGC,iCAAiC,EAAA;eAAjCA;;;uBAlCc;yCAEU;AAEjC,MAAMD,sBAAsBE,CAAAA,GAAAA,OAAAA,aAAa,EAAyB;AAClE,MAAMJ,kBAAkBI,CAAAA,GAAAA,OAAAA,aAAa,EAAgB;AACrD,MAAML,oBAAoBK,CAAAA,GAAAA,OAAAA,aAAa,EAAgB;AAsBvD,MAAMN,4BACXM,CAAAA,GAAAA,OAAAA,aAAa,EAA4B;AAKpC,SAASD,kCACdE,WAAmB,EACnBC,KAAQ;IAER,MAAMC,UAAUC,QAAQC,OAAO,CAACH;IAChCC,QAAQG,MAAM,GAAG;IACjBH,QAAQD,KAAK,GAAGA;IAChBC,QAAQF,WAAW,GAAG,GAAGA,YAAY,MAAM,CAAC;IAC5C,OAAOE;AACT;AAIA,wCAA2C;IACzCL,oBAAoBG,WAAW,GAAG;IAClCL,gBAAgBK,WAAW,GAAG;IAC9BN,kBAAkBM,WAAW,GAAG;IAChCP,0BAA0BO,WAAW,GAAG;AAC1C","ignoreList":[0]}},
63
- {"offset": {"line": 5631, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/utils/as-path-to-search-params.ts"],"sourcesContent":["// Convert router.asPath to a URLSearchParams object\n// example: /dynamic/[slug]?foo=bar -> { foo: 'bar' }\nexport function asPathToSearchParams(asPath: string): URLSearchParams {\n return new URL(asPath, 'http://n').searchParams\n}\n"],"names":["asPathToSearchParams","asPath","URL","searchParams"],"mappings":"AAAA,oDAAoD;AACpD,qDAAqD;;;;+BACrCA,wBAAAA;;;eAAAA;;;AAAT,SAASA,qBAAqBC,MAAc;IACjD,OAAO,IAAIC,IAAID,QAAQ,YAAYE,YAAY;AACjD","ignoreList":[0]}},
64
- {"offset": {"line": 5649, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/router/adapters.tsx"],"sourcesContent":["import type { AppRouterInstance } from '../app-router-context.shared-runtime'\nimport type { Params } from '../../../server/request/params'\nimport type { NextRouter } from './router'\n\nimport React, { useMemo, useRef } from 'react'\nimport { PathnameContext } from '../hooks-client-context.shared-runtime'\nimport { isDynamicRoute } from './utils'\nimport { asPathToSearchParams } from './utils/as-path-to-search-params'\nimport { getRouteRegex } from './utils/route-regex'\n\n/** It adapts a Pages Router (`NextRouter`) to the App Router Instance. */\nexport function adaptForAppRouterInstance(\n pagesRouter: NextRouter\n): AppRouterInstance {\n return {\n back() {\n pagesRouter.back()\n },\n forward() {\n pagesRouter.forward()\n },\n refresh() {\n pagesRouter.reload()\n },\n hmrRefresh() {},\n push(href, { scroll } = {}) {\n void pagesRouter.push(href, undefined, { scroll })\n },\n replace(href, { scroll } = {}) {\n void pagesRouter.replace(href, undefined, { scroll })\n },\n prefetch(href) {\n void pagesRouter.prefetch(href)\n },\n }\n}\n\n/**\n * adaptForSearchParams transforms the ParsedURLQuery into URLSearchParams.\n *\n * @param router the router that contains the query.\n * @returns the search params in the URLSearchParams format\n */\nexport function adaptForSearchParams(\n router: Pick<NextRouter, 'isReady' | 'query' | 'asPath'>\n): URLSearchParams {\n if (!router.isReady || !router.query) {\n return new URLSearchParams()\n }\n\n return asPathToSearchParams(router.asPath)\n}\n\nexport function adaptForPathParams(\n router: Pick<NextRouter, 'isReady' | 'pathname' | 'query' | 'asPath'>\n): Params | null {\n if (!router.isReady || !router.query) {\n return null\n }\n const pathParams: Params = {}\n const routeRegex = getRouteRegex(router.pathname)\n const keys = Object.keys(routeRegex.groups)\n for (const key of keys) {\n pathParams[key] = router.query[key]!\n }\n return pathParams\n}\n\nexport function PathnameContextProviderAdapter({\n children,\n router,\n ...props\n}: React.PropsWithChildren<{\n router: Pick<NextRouter, 'pathname' | 'asPath' | 'isReady' | 'isFallback'>\n isAutoExport: boolean\n}>) {\n const ref = useRef(props.isAutoExport)\n const value = useMemo(() => {\n // isAutoExport is only ever `true` on the first render from the server,\n // so reset it to `false` after we read it for the first time as `true`. If\n // we don't use the value, then we don't need it.\n const isAutoExport = ref.current\n if (isAutoExport) {\n ref.current = false\n }\n\n // When the route is a dynamic route, we need to do more processing to\n // determine if we need to stop showing the pathname.\n if (isDynamicRoute(router.pathname)) {\n // When the router is rendering the fallback page, it can't possibly know\n // the path, so return `null` here. Read more about fallback pages over\n // at:\n // https://nextjs.org/docs/api-reference/data-fetching/get-static-paths#fallback-pages\n if (router.isFallback) {\n return null\n }\n\n // When `isAutoExport` is true, meaning this is a page page has been\n // automatically statically optimized, and the router is not ready, then\n // we can't know the pathname yet. Read more about automatic static\n // optimization at:\n // https://nextjs.org/docs/advanced-features/automatic-static-optimization\n if (isAutoExport && !router.isReady) {\n return null\n }\n }\n\n // The `router.asPath` contains the pathname seen by the browser (including\n // any query strings), so it should have that stripped. Read more about the\n // `asPath` option over at:\n // https://nextjs.org/docs/api-reference/next/router#router-object\n let url: URL\n try {\n url = new URL(router.asPath, 'http://f')\n } catch (_) {\n // fallback to / for invalid asPath values e.g. //\n return '/'\n }\n\n return url.pathname\n }, [router.asPath, router.isFallback, router.isReady, router.pathname])\n\n return (\n <PathnameContext.Provider value={value}>\n {children}\n </PathnameContext.Provider>\n )\n}\n"],"names":["PathnameContextProviderAdapter","adaptForAppRouterInstance","adaptForPathParams","adaptForSearchParams","pagesRouter","back","forward","refresh","reload","hmrRefresh","push","href","scroll","undefined","replace","prefetch","router","isReady","query","URLSearchParams","asPathToSearchParams","asPath","pathParams","routeRegex","getRouteRegex","pathname","keys","Object","groups","key","children","props","ref","useRef","isAutoExport","value","useMemo","current","isDynamicRoute","isFallback","url","URL","_","PathnameContext","Provider"],"mappings":";;;;;;;;;;;;;;;;IAoEgBA,8BAA8B,EAAA;eAA9BA;;IAzDAC,yBAAyB,EAAA;eAAzBA;;IA0CAC,kBAAkB,EAAA;eAAlBA;;IAVAC,oBAAoB,EAAA;eAApBA;;;;;iEAvCuB;iDACP;uBACD;sCACM;4BACP;AAGvB,SAASF,0BACdG,WAAuB;IAEvB,OAAO;QACLC;YACED,YAAYC,IAAI;QAClB;QACAC;YACEF,YAAYE,OAAO;QACrB;QACAC;YACEH,YAAYI,MAAM;QACpB;QACAC,eAAc;QACdC,MAAKC,IAAI,EAAE,EAAEC,MAAM,EAAE,GAAG,CAAC,CAAC;YACxB,KAAKR,YAAYM,IAAI,CAACC,MAAME,WAAW;gBAAED;YAAO;QAClD;QACAE,SAAQH,IAAI,EAAE,EAAEC,MAAM,EAAE,GAAG,CAAC,CAAC;YAC3B,KAAKR,YAAYU,OAAO,CAACH,MAAME,WAAW;gBAAED;YAAO;QACrD;QACAG,UAASJ,IAAI;YACX,KAAKP,YAAYW,QAAQ,CAACJ;QAC5B;IACF;AACF;AAQO,SAASR,qBACda,MAAwD;IAEx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AA2B;QAC3B,kEAAkE;QAClE,IAAIuB;QACJ,IAAI;YACFA,MAAM,IAAIC,IAAIzB,OAAOK,MAAM,EAAE;QAC/B,EAAE,OAAOqB,GAAG;YACV,kDAAkD;YAClD,OAAO;QACT;QAEA,OAAOF,IAAIf,QAAQ;IACrB,GAAG;QAACT,OAAOK,MAAM;QAAEL,OAAOuB,UAAU;QAAEvB,OAAOC,OAAO;QAAED,OAAOS,QAAQ;KAAC;IAEtE,OAAA,WAAA,GACE,CAAA,GAAA,YAAA,GAAA,EAACkB,iCAAAA,eAAe,CAACC,QAAQ,EAAA;QAACT,OAAOA;kBAC9BL;;AAGP","ignoreList":[0]}},
65
- {"offset": {"line": 5786, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/lazy-dynamic/bailout-to-csr.ts"],"sourcesContent":["// This has to be a shared module which is shared between client component error boundary and dynamic component\nconst BAILOUT_TO_CSR = 'BAILOUT_TO_CLIENT_SIDE_RENDERING'\n\n/** An error that should be thrown when we want to bail out to client-side rendering. */\nexport class BailoutToCSRError extends Error {\n public readonly digest = BAILOUT_TO_CSR\n\n constructor(public readonly reason: string) {\n super(`Bail out to client-side rendering: ${reason}`)\n }\n}\n\n/** Checks if a passed argument is an error that is thrown if we want to bail out to client-side rendering. */\nexport function isBailoutToCSRError(err: unknown): err is BailoutToCSRError {\n if (typeof err !== 'object' || err === null || !('digest' in err)) {\n return false\n }\n\n return err.digest === BAILOUT_TO_CSR\n}\n"],"names":["BailoutToCSRError","isBailoutToCSRError","BAILOUT_TO_CSR","Error","constructor","reason","digest","err"],"mappings":"AAAA,+GAA+G;;;;;;;;;;;;;;;IAIlGA,iBAAiB,EAAA;eAAjBA;;IASGC,mBAAmB,EAAA;eAAnBA;;;AAZhB,MAAMC,iBAAiB;AAGhB,MAAMF,0BAA0BG;IAGrCC,YAA4BC,MAAc,CAAE;QAC1C,KAAK,CAAC,CAAC,mCAAmC,EAAEA,QAAQ,GAAA,IAAA,CAD1BA,MAAAA,GAAAA,QAAAA,IAAAA,CAFZC,MAAAA,GAASJ;IAIzB;AACF;AAGO,SAASD,oBAAoBM,GAAY;IAC9C,IAAI,OAAOA,QAAQ,YAAYA,QAAQ,QAAQ,CAAE,CAAA,YAAYA,GAAE,GAAI;QACjE,OAAO;IACT;IAEA,OAAOA,IAAID,MAAM,KAAKJ;AACxB","ignoreList":[0]}},
66
- {"offset": {"line": 5824, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/error-source.ts"],"sourcesContent":["const symbolError = Symbol.for('NextjsError')\n\nexport function getErrorSource(error: Error): 'server' | 'edge-server' | null {\n return (error as any)[symbolError] || null\n}\n\nexport type ErrorSourceType = 'edge-server' | 'server'\n\nexport function decorateServerError(error: Error, type: ErrorSourceType) {\n Object.defineProperty(error, symbolError, {\n writable: false,\n enumerable: false,\n configurable: false,\n value: type,\n })\n}\n"],"names":["decorateServerError","getErrorSource","symbolError","Symbol","for","error","type","Object","defineProperty","writable","enumerable","configurable","value"],"mappings":";;;;;;;;;;;;;;IAQgBA,mBAAmB,EAAA;eAAnBA;;IANAC,cAAc,EAAA;eAAdA;;;AAFhB,MAAMC,cAAcC,OAAOC,GAAG,CAAC;AAExB,SAASH,eAAeI,KAAY;IACzC,OAAQA,KAAa,CAACH,YAAY,IAAI;AACxC;AAIO,SAASF,oBAAoBK,KAAY,EAAEC,IAAqB;IACrEC,OAAOC,cAAc,CAACH,OAAOH,aAAa;QACxCO,UAAU;QACVC,YAAY;QACZC,cAAc;QACdC,OAAON;IACT;AACF","ignoreList":[0]}},
67
- {"offset": {"line": 5861, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/normalized-asset-prefix.ts"],"sourcesContent":["export function normalizedAssetPrefix(assetPrefix: string | undefined): string {\n // remove all leading slashes and trailing slashes\n const escapedAssetPrefix = assetPrefix?.replace(/^\\/+|\\/+$/g, '') || false\n\n // if an assetPrefix was '/', we return empty string\n // because it could be an unnecessary trailing slash\n if (!escapedAssetPrefix) {\n return ''\n }\n\n if (URL.canParse(escapedAssetPrefix)) {\n const url = new URL(escapedAssetPrefix).toString()\n return url.endsWith('/') ? url.slice(0, -1) : url\n }\n\n // assuming assetPrefix here is a pathname-style,\n // restore the leading slash\n return `/${escapedAssetPrefix}`\n}\n"],"names":["normalizedAssetPrefix","assetPrefix","escapedAssetPrefix","replace","URL","canParse","url","toString","endsWith","slice"],"mappings":";;;+BAAgBA,yBAAAA;;;eAAAA;;;AAAT,SAASA,sBAAsBC,WAA+B;IACnE,kDAAkD;IAClD,MAAMC,qBAAqBD,aAAaE,QAAQ,cAAc,OAAO;IAErE,oDAAoD;IACpD,oDAAoD;IACpD,IAAI,CAACD,oBAAoB;QACvB,OAAO;IACT;IAEA,IAAIE,IAAIC,QAAQ,CAACH,qBAAqB;QACpC,MAAMI,MAAM,IAAIF,IAAIF,oBAAoBK,QAAQ;QAChD,OAAOD,IAAIE,QAAQ,CAAC,OAAOF,IAAIG,KAAK,CAAC,GAAG,CAAC,KAAKH;IAChD;IAEA,iDAAiD;IACjD,4BAA4B;IAC5B,OAAO,CAAC,CAAC,EAAEJ,oBAAoB;AACjC","ignoreList":[0]}},
68
- {"offset": {"line": 5890, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/format-webpack-messages.ts"],"sourcesContent":["/**\nMIT License\n\nCopyright (c) 2015-present, Facebook, Inc.\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n*/\nimport stripAnsi from 'next/dist/compiled/strip-ansi'\n// This file is based on https://github.com/facebook/create-react-app/blob/7b1a32be6ec9f99a6c9a3c66813f3ac09c4736b9/packages/react-dev-utils/formatWebpackMessages.js\n// It's been edited to remove chalk and CRA-specific logic\n\nconst friendlySyntaxErrorLabel = 'Syntax error:'\n\nconst WEBPACK_BREAKING_CHANGE_POLYFILLS =\n '\\n\\nBREAKING CHANGE: webpack < 5 used to include polyfills for node.js core modules by default.'\n\nfunction isLikelyASyntaxError(message: string) {\n return stripAnsi(message).includes(friendlySyntaxErrorLabel)\n}\n\nlet hadMissingSassError = false\n\n// Cleans up webpack error messages.\nfunction formatMessage(\n message: any,\n verbose?: boolean,\n importTraceNote?: boolean\n) {\n // TODO: Replace this once webpack 5 is stable\n if (typeof message === 'object' && message.message) {\n const filteredModuleTrace =\n message.moduleTrace &&\n message.moduleTrace.filter(\n (trace: any) =>\n !/next-(middleware|client-pages|route|edge-function)-loader\\.js/.test(\n trace.originName\n )\n )\n\n let body = message.message\n const breakingChangeIndex = body.indexOf(WEBPACK_BREAKING_CHANGE_POLYFILLS)\n if (breakingChangeIndex >= 0) {\n body = body.slice(0, breakingChangeIndex)\n }\n\n // TODO: Rspack currently doesn't populate moduleName correctly in some cases,\n // fall back to moduleIdentifier as a workaround\n if (\n process.env.NEXT_RSPACK &&\n !message.moduleName &&\n !message.file &&\n message.moduleIdentifier\n ) {\n const parts = message.moduleIdentifier.split('!')\n message.moduleName = parts[parts.length - 1]\n }\n\n message =\n (message.moduleName ? stripAnsi(message.moduleName) + '\\n' : '') +\n (message.file ? stripAnsi(message.file) + '\\n' : '') +\n body +\n (message.details && verbose ? '\\n' + message.details : '') +\n (filteredModuleTrace && filteredModuleTrace.length\n ? (importTraceNote || '\\n\\nImport trace for requested module:') +\n filteredModuleTrace\n .map((trace: any) => `\\n${trace.moduleName}`)\n .join('')\n : '') +\n (message.stack && verbose ? '\\n' + message.stack : '')\n }\n let lines = message.split('\\n')\n\n // Extract loader paths from Webpack-added headers and move them to end.\n // Original format: \"Module build failed (from ./loaders/foo-loader.js):\"\n // The header line is removed and the path is appended at the end as:\n // \" (from ./loaders/foo-loader.js)\"\n // https://github.com/webpack/webpack/blob/master/lib/ModuleError.js\n const loaderPaths: string[] = []\n lines = lines.filter((line: string) => {\n const match = /Module [A-z ]+\\(from (.+)\\):?\\s*$/.exec(line)\n if (match) {\n loaderPaths.push(match[1])\n return false\n }\n return true\n })\n\n // Transform parsing error into syntax error\n // TODO: move this to our ESLint formatter?\n lines = lines.map((line: string) => {\n const parsingError = /Line (\\d+):(?:(\\d+):)?\\s*Parsing error: (.+)$/.exec(\n line\n )\n if (!parsingError) {\n return line\n }\n const [, errorLine, errorColumn, errorMessage] = parsingError\n return `${friendlySyntaxErrorLabel} ${errorMessage} (${errorLine}:${errorColumn})`\n })\n\n message = lines.join('\\n')\n // Smoosh syntax errors (commonly found in CSS)\n message = message.replace(\n /SyntaxError\\s+\\((\\d+):(\\d+)\\)\\s*(.+?)\\n/g,\n `${friendlySyntaxErrorLabel} $3 ($1:$2)\\n`\n )\n // Clean up export errors\n message = message.replace(\n /^.*export '(.+?)' was not found in '(.+?)'.*$/gm,\n `Attempted import error: '$1' is not exported from '$2'.`\n )\n message = message.replace(\n /^.*export 'default' \\(imported as '(.+?)'\\) was not found in '(.+?)'.*$/gm,\n `Attempted import error: '$2' does not contain a default export (imported as '$1').`\n )\n message = message.replace(\n /^.*export '(.+?)' \\(imported as '(.+?)'\\) was not found in '(.+?)'.*$/gm,\n `Attempted import error: '$1' is not exported from '$3' (imported as '$2').`\n )\n lines = message.split('\\n')\n\n // Remove leading newline\n if (lines.length > 2 && lines[1].trim() === '') {\n lines.splice(1, 1)\n }\n\n // Cleans up verbose \"module not found\" messages for files and packages.\n if (lines[1] && lines[1].startsWith('Module not found: ')) {\n lines = [\n lines[0],\n lines[1]\n .replace('Error: ', '')\n .replace('Module not found: Cannot find file:', 'Cannot find file:'),\n ...lines.slice(2),\n ]\n }\n\n // Add helpful message for users trying to use Sass for the first time\n if (lines[1] && lines[1].match(/Cannot find module.+sass/)) {\n // ./file.module.scss (<<loader info>>) => ./file.module.scss\n const firstLine = lines[0].split('!')\n lines[0] = firstLine[firstLine.length - 1]\n\n lines[1] =\n \"To use Next.js' built-in Sass support, you first need to install `sass`.\\n\"\n lines[1] += 'Run `npm i sass` or `yarn add sass` inside your workspace.\\n'\n lines[1] += '\\nLearn more: https://nextjs.org/docs/messages/install-sass'\n\n // dispose of unhelpful stack trace\n lines = lines.slice(0, 2)\n hadMissingSassError = true\n } else if (\n hadMissingSassError &&\n message.match(/(sass-loader|resolve-url-loader: CSS error)/)\n ) {\n // dispose of unhelpful stack trace following missing sass module\n lines = []\n }\n\n if (!verbose) {\n message = lines.join('\\n')\n // Internal stacks are generally useless so we strip them... with the\n // exception of stacks containing `webpack:` because they're normally\n // from user code generated by Webpack. For more information see\n // https://github.com/facebook/create-react-app/pull/1050\n message = message.replace(\n /^\\s*at\\s((?!webpack:).)*:\\d+:\\d+[\\s)]*(\\n|$)/gm,\n ''\n ) // at ... ...:x:y\n message = message.replace(/^\\s*at\\s<anonymous>(\\n|$)/gm, '') // at <anonymous>\n\n message = message.replace(\n /File was processed with these loaders:\\n(.+[\\\\/](next[\\\\/]dist[\\\\/].+|@next[\\\\/]react-refresh-utils[\\\\/]loader)\\.js\\n)*You may need an additional loader to handle the result of these loaders.\\n/g,\n ''\n )\n\n lines = message.split('\\n')\n }\n\n // Append loader paths at the end (before any remaining stack trace)\n if (loaderPaths.length > 0) {\n for (const loaderPath of loaderPaths) {\n // Don't show internal Next.js loader paths — they're noise for users\n if (!/[/\\\\]next[/\\\\]dist[/\\\\]/.test(loaderPath)) {\n lines.push(` (from ${loaderPath})`)\n }\n }\n }\n\n // Remove duplicated newlines\n lines = (lines as string[]).filter(\n (line, index, arr) =>\n index === 0 || line.trim() !== '' || line.trim() !== arr[index - 1].trim()\n )\n\n // Reassemble the message\n message = lines.join('\\n')\n return message.trim()\n}\n\nexport default function formatWebpackMessages(json: any, verbose?: boolean) {\n const formattedErrors = json.errors.map((message: any) => {\n const isUnknownNextFontError = message.message.includes(\n 'An error occurred in `next/font`.'\n )\n return formatMessage(message, isUnknownNextFontError || verbose)\n })\n const formattedWarnings = json.warnings.map((message: any) => {\n return formatMessage(message, verbose)\n })\n\n // Reorder errors to put the most relevant ones first.\n let reactServerComponentsError = -1\n\n for (let i = 0; i < formattedErrors.length; i++) {\n const error = formattedErrors[i]\n if (error.includes('ReactServerComponentsError')) {\n reactServerComponentsError = i\n break\n }\n }\n\n // Move the reactServerComponentsError to the top if it exists\n if (reactServerComponentsError !== -1) {\n const error = formattedErrors.splice(reactServerComponentsError, 1)\n formattedErrors.unshift(error[0])\n }\n\n const result = {\n ...json,\n errors: formattedErrors,\n warnings: formattedWarnings,\n }\n if (!verbose && result.errors.some(isLikelyASyntaxError)) {\n // If there are any syntax errors, show just them.\n result.errors = result.errors.filter(isLikelyASyntaxError)\n result.warnings = []\n }\n return result\n}\n"],"names":["formatWebpackMessages","friendlySyntaxErrorLabel","WEBPACK_BREAKING_CHANGE_POLYFILLS","isLikelyASyntaxError","message","stripAnsi","includes","hadMissingSassError","formatMessage","verbose","importTraceNote","filteredModuleTrace","moduleTrace","filter","trace","test","originName","body","breakingChangeIndex","indexOf","slice","process","env","NEXT_RSPACK","moduleName","file","moduleIdentifier","parts","split","length","details","map","join","stack","lines","loaderPaths","line","match","exec","push","parsingError","errorLine","errorColumn","errorMessage","replace","trim","splice","startsWith","firstLine","loaderPath","index","arr","json","formattedErrors","errors","isUnknownNextFontError","formattedWarnings","warnings","reactServerComponentsError","i","error","unshift","result","some"],"mappings":"AAgEMqB;AAhEN;;;;;;;;;;;;;;;;;;;;;;AAsBA,GAAA;;;;+BAkMA,WAAA;;;eAAwBrB;;;;oEAjMF;AACtB,qKAAqK;AACrK,0DAA0D;AAE1D,MAAMC,2BAA2B;AAEjC,MAAMC,oCACJ;AAEF,SAASC,qBAAqBC,OAAe;IAC3C,OAAOC,CAAAA,GAAAA,WAAAA,OAAS,EAACD,SAASE,QAAQ,CAACL;AACrC;AAEA,IAAIM,sBAAsB;AAE1B,oCAAoC;AACpC,SAASC,cACPJ,OAAY,EACZK,OAAiB,EACjBC,eAAyB;IAEzB,8CAA8C;IAC9C,IAAI,OAAON,YAAY,YAAYA,QAAQA,OAAO,EAAE;QAClD,MAAMO,sBACJP,QAAQQ,WAAW,IACnBR,QAAQQ,WAAW,CAACC,MAAM,CACxB,CAACC,QACC,CAAC,gEAAgEC,IAAI,CACnED,MAAME,UAAU;QAIxB,IAAIC,OAAOb,QAAQA,OAAO;QAC1B,MAAMc,sBAAsBD,KAAKE,OAAO,CAACjB;QACzC,IAAIgB,uBAAuB,GAAG;YAC5BD,OAAOA,KAAKG,KAAK,CAAC,GAAGF;QACvB;QAEA,8EAA8E;QAC9E,gDAAgD;QAChD,yUACEG,CAAQC,GAAG,CAACC,WAAW,IACvB,CAAC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IACA,MAAM+C,oBAAoBJ,KAAKK,QAAQ,CAAC1B,GAAG,CAAC,CAAC3B;QAC3C,OAAOI,cAAcJ,SAASK;IAChC;IAEA,sDAAsD;IACtD,IAAIiD,6BAA6B,CAAC;IAElC,IAAK,IAAIC,IAAI,GAAGA,IAAIN,gBAAgBxB,MAAM,EAAE8B,IAAK;QAC/C,MAAMC,QAAQP,eAAe,CAACM,EAAE;QAChC,IAAIC,MAAMtD,QAAQ,CAAC,+BAA+B;YAChDoD,6BAA6BC;YAC7B;QACF;IACF;IAEA,8DAA8D;IAC9D,IAAID,+BAA+B,CAAC,GAAG;QACrC,MAAME,QAAQP,gBAAgBP,MAAM,CAACY,4BAA4B;QACjEL,gBAAgBQ,OAAO,CAACD,KAAK,CAAC,EAAE;IAClC;IAEA,MAAME,SAAS;QACb,GAAGV,IAAI;QACPE,QAAQD;QACRI,UAAUD;IACZ;IACA,IAAI,CAAC/C,WAAWqD,OAAOR,MAAM,CAACS,IAAI,CAAC5D,uBAAuB;QACxD,kDAAkD;QAClD2D,OAAOR,MAAM,GAAGQ,OAAOR,MAAM,CAACzC,MAAM,CAACV;QACrC2D,OAAOL,QAAQ,GAAG,EAAE;IACtB;IACA,OAAOK;AACT","ignoreList":[0]}},
69
- {"offset": {"line": 6077, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/side-effect.tsx"],"sourcesContent":["import type React from 'react'\nimport { Children, useEffect, useLayoutEffect, type JSX } from 'react'\n\ntype State = JSX.Element[] | undefined\n\nexport type SideEffectProps = {\n reduceComponentsToState: (components: Array<React.ReactElement<any>>) => State\n handleStateChange?: (state: State) => void\n headManager: any\n children: React.ReactNode\n}\n\nconst isServer = typeof window === 'undefined'\nconst useClientOnlyLayoutEffect = isServer ? () => {} : useLayoutEffect\nconst useClientOnlyEffect = isServer ? () => {} : useEffect\n\nexport default function SideEffect(props: SideEffectProps) {\n const { headManager, reduceComponentsToState } = props\n\n function emitChange() {\n if (headManager && headManager.mountedInstances) {\n const headElements = Children.toArray(\n Array.from(headManager.mountedInstances as Set<React.ReactNode>).filter(\n Boolean\n )\n ) as React.ReactElement[]\n headManager.updateHead(reduceComponentsToState(headElements))\n }\n }\n\n if (isServer) {\n headManager?.mountedInstances?.add(props.children)\n emitChange()\n }\n\n useClientOnlyLayoutEffect(() => {\n headManager?.mountedInstances?.add(props.children)\n return () => {\n headManager?.mountedInstances?.delete(props.children)\n }\n })\n\n // We need to call `updateHead` method whenever the `SideEffect` is trigger in all\n // life-cycles: mount, update, unmount. However, if there are multiple `SideEffect`s\n // being rendered, we only trigger the method from the last one.\n // This is ensured by keeping the last unflushed `updateHead` in the `_pendingUpdate`\n // singleton in the layout effect pass, and actually trigger it in the effect pass.\n useClientOnlyLayoutEffect(() => {\n if (headManager) {\n headManager._pendingUpdate = emitChange\n }\n return () => {\n if (headManager) {\n headManager._pendingUpdate = emitChange\n }\n }\n })\n\n useClientOnlyEffect(() => {\n if (headManager && headManager._pendingUpdate) {\n headManager._pendingUpdate()\n headManager._pendingUpdate = null\n }\n return () => {\n if (headManager && headManager._pendingUpdate) {\n headManager._pendingUpdate()\n headManager._pendingUpdate = null\n }\n }\n })\n\n return null\n}\n"],"names":["SideEffect","isServer","window","useClientOnlyLayoutEffect","useLayoutEffect","useClientOnlyEffect","useEffect","props","headManager","reduceComponentsToState","emitChange","mountedInstances","headElements","Children","toArray","Array","from","filter","Boolean","updateHead","add","children","delete","_pendingUpdate"],"mappings":";;;+BAgBA,WAAA;;;eAAwBA;;;uBAfuC;AAW/D,MAAMC,WAAW,OAAOC,WAAW;AACnC,MAAMC,4BAA4BF,WAAW,KAAO,IAAIG,OAAAA,eAAe;AACvE,MAAMC,sBAAsBJ,WAAW,KAAO,IAAIK,OAAAA,SAAS;AAE5C,SAASN,WAAWO,KAAsB;IACvD,MAAM,EAAEC,WAAW,EAAEC,uBAAuB,EAAE,GAAGF;IAEjD,SAASG;QACP,IAAIF,eAAeA,YAAYG,gBAAgB,EAAE;YAC/C,MAAMC,eAAeC,OAAAA,QAAQ,CAACC,OAAO,CACnCC,MAAMC,IAAI,CAACR,YAAYG,gBAAgB,EAA0BM,MAAM,CACrEC;YAGJV,YAAYW,UAAU,CAACV,wBAAwBG;QACjD;IACF;IAEA,IAAIX,UAAU;QACZO,aAAaG,kBAAkBS,IAAIb,MAAMc,QAAQ;QACjDX;IACF;IAEAP;gDAA0B;YACxBK,aAAaG,kBAAkBS,IAAIb,MAAMc,QAAQ;YACjD;wDAAO;oBACLb,aAAaG,kBAAkBW,OAAOf,MAAMc,QAAQ;gBACtD;;QACF;;IAEA,kFAAkF;IAClF,oFAAoF;IACpF,gEAAgE;IAChE,qFAAqF;IACrF,mFAAmF;IACnFlB;gDAA0B;YACxB,IAAIK,aAAa;gBACfA,YAAYe,cAAc,GAAGb;YAC/B;YACA;wDAAO;oBACL,IAAIF,aAAa;wBACfA,YAAYe,cAAc,GAAGb;oBAC/B;gBACF;;QACF;;IAEAL;0CAAoB;YAClB,IAAIG,eAAeA,YAAYe,cAAc,EAAE;gBAC7Cf,YAAYe,cAAc;gBAC1Bf,YAAYe,cAAc,GAAG;YAC/B;YACA;kDAAO;oBACL,IAAIf,eAAeA,YAAYe,cAAc,EAAE;wBAC7Cf,YAAYe,cAAc;wBAC1Bf,YAAYe,cAAc,GAAG;oBAC/B;gBACF;;QACF;;IAEA,OAAO;AACT","ignoreList":[0]}},
70
- {"offset": {"line": 6153, "column": 0}, "map": {"version":3,"sources":["file:///home/ubuntu/dev/chorus/node_modules/.pnpm/next%4016.2.4_%40babel%2Bcore%407.29.0_react-dom%4019.2.4_react%4019.2.4__react%4019.2.4/node_modules/next/src/shared/lib/head.tsx"],"sourcesContent":["'use client'\n\nimport React, { useContext, type JSX } from 'react'\nimport Effect from './side-effect'\nimport { HeadManagerContext } from './head-manager-context.shared-runtime'\nimport { warnOnce } from './utils/warn-once'\n\nexport function defaultHead(): JSX.Element[] {\n const head = [\n <meta charSet=\"utf-8\" key=\"charset\" />,\n <meta name=\"viewport\" content=\"width=device-width\" key=\"viewport\" />,\n ]\n return head\n}\n\nfunction onlyReactElement(\n list: Array<React.ReactElement<any>>,\n child: React.ReactElement | number | string\n): Array<React.ReactElement<any>> {\n // React children can be \"string\" or \"number\" in this case we ignore them for backwards compat\n if (typeof child === 'string' || typeof child === 'number') {\n return list\n }\n // Adds support for React.Fragment\n if (child.type === React.Fragment) {\n return list.concat(\n // @ts-expect-error @types/react does not remove fragments but this could also return ReactPortal[]\n React.Children.toArray(child.props.children).reduce(\n // @ts-expect-error @types/react does not remove fragments but this could also return ReactPortal[]\n (\n fragmentList: Array<React.ReactElement<any>>,\n fragmentChild: React.ReactElement | number | string\n ): Array<React.ReactElement<any>> => {\n if (\n typeof fragmentChild === 'string' ||\n typeof fragmentChild === 'number'\n ) {\n return fragmentList\n }\n return fragmentList.concat(fragmentChild)\n },\n []\n )\n )\n }\n return list.concat(child)\n}\n\nconst METATYPES = ['name', 'httpEquiv', 'charSet', 'itemProp']\n\n/*\n returns a function for filtering head child elements\n which shouldn't be duplicated, like <title/>\n Also adds support for deduplicated `key` properties\n*/\nfunction unique() {\n const keys = new Set()\n const tags = new Set()\n const metaTypes = new Set()\n const metaCategories: { [metatype: string]: Set<string> } = {}\n\n return (h: React.ReactElement<any>) => {\n let isUnique = true\n let hasKey = false\n\n if (h.key && typeof h.key !== 'number' && h.key.indexOf('$') > 0) {\n hasKey = true\n const key = h.key.slice(h.key.indexOf('$') + 1)\n if (keys.has(key)) {\n isUnique = false\n } else {\n keys.add(key)\n }\n }\n\n // eslint-disable-next-line default-case\n switch (h.type) {\n case 'title':\n case 'base':\n if (tags.has(h.type)) {\n isUnique = false\n } else {\n tags.add(h.type)\n }\n break\n case 'meta':\n for (let i = 0, len = METATYPES.length; i < len; i++) {\n const metatype = METATYPES[i]\n if (!h.props.hasOwnProperty(metatype)) continue\n\n if (metatype === 'charSet') {\n if (metaTypes.has(metatype)) {\n isUnique = false\n } else {\n metaTypes.add(metatype)\n }\n } else {\n const category = h.props[metatype]\n const categories = metaCategories[metatype] || new Set()\n if ((metatype !== 'name' || !hasKey) && categories.has(category)) {\n isUnique = false\n } else {\n categories.add(category)\n metaCategories[metatype] = categories\n }\n }\n }\n break\n }\n\n return isUnique\n }\n}\n\n/**\n *\n * @param headChildrenElements List of children of <Head>\n */\nfunction reduceComponents(\n headChildrenElements: Array<React.ReactElement<any>>\n) {\n return headChildrenElements\n .reduce(onlyReactElement, [])\n .reverse()\n .concat(defaultHead().reverse())\n .filter(unique())\n .reverse()\n .map((c: React.ReactElement<any>, i: number) => {\n const key = c.key || i\n if (process.env.NODE_ENV === 'development') {\n // omit JSON-LD structured data snippets from the warning\n if (c.type === 'script' && c.props['type'] !== 'application/ld+json') {\n const srcMessage = c.props['src']\n ? `<script> tag with src=\"${c.props['src']}\"`\n : `inline <script>`\n warnOnce(\n `Do not add <script> tags using next/head (see ${srcMessage}). Use next/script instead. \\nSee more info here: https://nextjs.org/docs/messages/no-script-tags-in-head-component`\n )\n } else if (c.type === 'link' && c.props['rel'] === 'stylesheet') {\n warnOnce(\n `Do not add stylesheets using next/head (see <link rel=\"stylesheet\"> tag with href=\"${c.props['href']}\"). Use Document instead. \\nSee more info here: https://nextjs.org/docs/messages/no-stylesheets-in-head-component`\n )\n }\n }\n return React.cloneElement(c, { key })\n })\n}\n\n/**\n * This component injects elements to `<head>` of your page.\n * To avoid duplicated `tags` in `<head>` you can use the `key` property, which will make sure every tag is only rendered once.\n */\nfunction Head({ children }: { children: React.ReactNode }) {\n const headManager = useContext(HeadManagerContext)\n return (\n <Effect\n reduceComponentsToState={reduceComponents}\n headManager={headManager}\n >\n {children}\n </Effect>\n )\n}\n\nexport default Head\n"],"names":["defaultHead","head","meta","charSet","name","content","onlyReactElement","list","child","type","React","Fragment","concat","Children","toArray","props","children","reduce","fragmentList","fragmentChild","METATYPES","unique","keys","Set","tags","metaTypes","metaCategories","h","isUnique","hasKey","key","indexOf","slice","has","add","i","len","length","metatype","hasOwnProperty","category","categories","reduceComponents","headChildrenElements","reverse","filter","map","c","process","env","NODE_ENV","srcMessage","warnOnce","cloneElement","Head","headManager","useContext","HeadManagerContext","Effect","reduceComponentsToState"],"mappings":"AAiIUgD,QAAQC,GAAG,CAACC,QAAQ,KAAK;AAjInC;;;;;;;;;;;;;;;;IAoKA,OAAmB,EAAA;eAAnB;;IA7JgBlD,WAAW,EAAA;eAAXA;;;;;;iEAL4B;qEACzB;iDACgB;0BACV;AAElB,SAASA;IACd,MAAMC,OAAO;sBACX,CAAA,GAAA,YAAA,GAAA,EAACC,QAAAA;YAAKC,SAAQ;WAAY;sBAC1B,CAAA,GAAA,YAAA,GAAA,EAACD,QAAAA;YAAKE,MAAK;YAAWC,SAAQ;WAAyB;KACxD;IACD,OAAOJ;AACT;AAEA,SAASK,iBACPC,IAAoC,EACpCC,KAA2C;IAE3C,8FAA8F;IAC9F,IAAI,OAAOA,UAAU,YAAY,OAAOA,UAAU,UAAU;QAC1D,OAAOD;IACT;IACA,kCAAkC;IAClC,IAAIC,MAAMC,IAAI,KAAKC,OAAAA,OAAK,CAACC,QAAQ,EAAE;QACjC,OAAOJ,KAAKK,MAAM,CAChB,AACAF,OAAAA,OAAK,CAACG,QAAQ,CAACC,OAAO,CAACN,MAAMO,KAAK,CAACC,QAAQ,EAAEC,MAAM,CACjD,AACA,CACEC,cACAC,uBAL+F,6DAEE;YAKjG,IACE,OAAOA,kBAAkB,YACzB,OAAOA,kBAAkB,UACzB;gBACA,OAAOD;YACT;YACA,OAAOA,aAAaN,MAAM,CAACO;QAC7B,GACA,EAAE;IAGR;IACA,OAAOZ,KAAKK,MAAM,CAACJ;AACrB;AAEA,MAAMY,YAAY;IAAC;IAAQ;IAAa;IAAW;CAAW;AAE9D;;;;AAIA,GACA,SAASC;IACP,MAAMC,OAAO,IAAIC;IACjB,MAAMC,OAAO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