athar-mcp 0.1.0 → 0.2.0
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.
- package/dashboard/.output/nitro.json +15 -0
- package/dashboard/.output/public/_fonts/31PZhXd_YTCmsoiPQZc-xVtAWAkLogRFRj5mWplmKFE-6WsTw05QKugcwLySGc_b9CIheG8j8LRyo47qPL430Mk.woff2 +0 -0
- package/dashboard/.output/public/_fonts/3e3wuf-V_7icWvlsSS3Ud6R1mFSymwsfz35VcqiVjOk-jnii4_jMs7YAJOhzZP3bGdrbXGt5dYv8_t_rhpHzpcQ.woff2 +0 -0
- package/dashboard/.output/public/_fonts/3mk1pEYaO7RuhctnlpKcyb7yjVLICedncSfY13ffbM8-vJidvBvYJRk77_zQIyVpja44ymm1FQTiYKUcM_aD5Sg.woff2 +0 -0
- package/dashboard/.output/public/_fonts/9FWLUGCSCYLRIRMtCzLrt4Go7DMFXOeN_pyCOJD_44Y-Yh2wNaqrq_e759vVlc3tX81lMwRu9ktkQJX_Svgs-VI.woff2 +0 -0
- package/dashboard/.output/public/_fonts/9IZYb3o3tpRXPqjzNd4r3vIIohLuRBC5-h_ByvqRowU-ZgMUMfi6FcHpaV_ucYIWcBvLG6geajFq70Smps0DAj0.woff2 +0 -0
- package/dashboard/.output/public/_fonts/AA0_6TP-Ed9gQINhOsvbweBE3xLQgxmg6pXqHmvCwsM-egZLwYC5qVnfGWql7G5NfYTIiMP1PB_tQWIq5f7S-0k.woff2 +0 -0
- package/dashboard/.output/public/_fonts/BQnDL9FFy0Q_jvURlmv87luvmXLSMbSuXsfZv_R2Rkk-y5MVrLtP4J_1al8rz8R-MDaUOMAHckAWCwDrKhw25fY.woff2 +0 -0
- package/dashboard/.output/public/_fonts/Df7M9JXECnQBPeMk0JlWv5oI4E80OSjKvG82PCAX-MI-aXpKyr1n0W6NWbCApKANrm9O50H_fjFMdBzwfTY75iM.woff2 +0 -0
- package/dashboard/.output/public/_fonts/F00Bxq4ciZESODR5suhK3xDWcsQ9RLj9SyZQEevpEsw-BLNEvb6wAcL3fpb4n4d3zVEKUoa2hsUKxxkf3YdvJKc.woff2 +0 -0
- package/dashboard/.output/public/_fonts/HsvEuay0nMOs_2ObxMGaCaFlKdRnnDmfWeFTeRbjAVE-UeGuS_NHKiKleun7gcayWaUNaV2zWnEeGUxJVueLYm0.woff +0 -0
- package/dashboard/.output/public/_fonts/JSrPAbQHsQEdUrIE5Ts6fIQ2ymsa4i7HhiCpui6ulCc-_AoyGWssOn06OMh3ZY_GddBBPRny4Igxin4fT_1K6F4.woff2 +0 -0
- package/dashboard/.output/public/_fonts/Jtqhy44WKYEjGWTSusP5YJfJv7Wf74QqgkBOI9u_77s-Rl_Bht5SvmaotE20bkavBEAJEEGEa0hcz3d_8yOeXmw.woff +0 -0
- package/dashboard/.output/public/_fonts/KOrIgK47CByspZJWjOLg8AL2ADg9uFcNjZd9W78jrmM-dU37DP77KwUzMqqldljJHhSe3lJpaSfI9HPfiVAxPOM.woff2 +0 -0
- package/dashboard/.output/public/_fonts/M-60tFLmAJxdPjHsK-2ILWom5zPbu37lb3Qex2waL14-A9y4QcXALPi_RvQsmRsSFUxrT3_J213W4zPFIXetlbw.woff2 +0 -0
- package/dashboard/.output/public/_fonts/NwLHmPccLrJlBVGp4QRXOLZaNI0M_K6XuSwyVjpr47g-jl4tqz8gcsgAJDPcbl5roY78zy31I6Rq51WBLpZngFg.woff2 +0 -0
- package/dashboard/.output/public/_fonts/T-ozk-QJ_Ck37B2RHPl2i-s_gAGGo7suFgagWoJ8bO4-maDXQ_nEXKAaLHm4Joud3DJR9EVzS7QXWMWK8YOTIcs.woff2 +0 -0
- package/dashboard/.output/public/_fonts/TTYbISAfwy-y4uVGS9AH32sK7b2xJsoCESo64ryf8LU-y87nRMqBGo42rUOW9tWZa06o4oTa0USJrAMMoKDamgs.woff2 +0 -0
- package/dashboard/.output/public/_fonts/Y_5DOsLit49q2i2tbcNxnyUen9__GPCX8mwAi03q1aA-pBCjVKDT5tBT3BJckh9uzNkfUWeUIBPz9Y8T55vcj8E.woff2 +0 -0
- package/dashboard/.output/public/_fonts/ZHaz3DhCHNWhsElqYfuM71rfBBDgjuU2sd34vaYJwQg-71NZaZSGjxzAGjCMnCc2zS5rS_EGA0xHKPGCggWuXik.woff +0 -0
- package/dashboard/.output/public/_fonts/_lyVj3lEzRng_G7gZNcCmL83BnMEos-Hf8bpHLMzGQI-zsVE1T2QbmkXlEbQhs2gb3j3VBOOGhzqyW_ZW_0s3F8.woff2 +0 -0
- package/dashboard/.output/public/_fonts/bUcXp2ExGsFoCjH4L_AiPGX0TLCAgnqR8nvW7SxSJYQ-kvm9UWc_MFZW_r85yX6uPdzXVmdcUOio_Wb1x_7QdXM.woff2 +0 -0
- package/dashboard/.output/public/_fonts/f3COenLcoezM74LmVz7-HHQTyPKopVoMY6x2syLMzQE-shPZYE7IAjZWz4okT_CWn96WfGzoLhasK43_mhj3CZI.woff2 +0 -0
- package/dashboard/.output/public/_fonts/h9PwCjip_BNPVO50hT4v29USWFv6H3ZlYx_IestfqgY-sYfLVuZXl9E1aYbn1S0pAr4zfdQ_WT7iBZhrgQY6N-4.woff2 +0 -0
- package/dashboard/.output/public/_fonts/l00UCz_-QvI_NO8AGcu7ooAcrFDlxYUdxCSCh6gBwd4-vPjTZ3ztgw27A2TnHeCycxPvUtXWEVpG33_97ra6su8.woff2 +0 -0
- package/dashboard/.output/public/_fonts/nuenOq7ZFSZ65QudJO7uQ0sOjDqow2WjfXrQh4S9gEc-uF81rxcswER5srfhzyLfPoGlKNAIt2C_BvkXFOc19rw.woff2 +0 -0
- package/dashboard/.output/public/_fonts/pWMvGwciZ-EfQsfR2ueelhC7Jnt5K-8Px8PjPK0mDII-eT9iD0iZ9WWhTJs6V5GxXr0iaUwx_WxgGGriOiGb81o.woff2 +0 -0
- package/dashboard/.output/public/_fonts/sqxfSu-14RfawvZSbzb3mPoBYaXxmTGIac1Kk0GVk_w-oe_5KiWXPVdvpURHWSiaIjA1N_zLqpjSzmfpwRHr7CQ.woff2 +0 -0
- package/dashboard/.output/public/_fonts/wMdBqIWtsuS5eTYXRFwACf6n6oW2h-j42f90vWIPIO8-vrVOc_lrScYZMKO0_R3igKLheJfV2qZ3c5qlWOY0LDQ.woff +0 -0
- package/dashboard/.output/public/_fonts/y3mP_zJcojQwJn30TpF_XxDzgeM6Nbk7MaRg1Ne0YcI-lFx13nqMCMgk_S70gRmwEHXlE5BLp1B4W82RpFihpMs.woff2 +0 -0
- package/dashboard/.output/public/_fonts/zr3WxpLd5PmlBr7e4PWGkhZv6XTg70Pi4sCbC-CEV0Q-v2yL98XOiD3FkbiYlYYeAeTSVSkgAckeOp55Q5kHJmU.woff2 +0 -0
- package/dashboard/.output/public/_nuxt/B0Bu7wg2.js +1 -0
- package/dashboard/.output/public/_nuxt/BNBS3IWx.js +1 -0
- package/dashboard/.output/public/_nuxt/Ba3u15ft.js +1 -0
- package/dashboard/.output/public/_nuxt/CH7yjz82.js +4 -0
- package/dashboard/.output/public/_nuxt/COkkU9In.js +1 -0
- package/dashboard/.output/public/_nuxt/C_XEhq4z.js +1 -0
- package/dashboard/.output/public/_nuxt/YOlRD-cU.js +1 -0
- package/dashboard/.output/public/_nuxt/_id_.Dz86UAW3.css +1 -0
- package/dashboard/.output/public/_nuxt/builds/latest.json +1 -0
- package/dashboard/.output/public/_nuxt/builds/meta/a6e303b2-379a-45a9-8bdf-906e96134fda.json +1 -0
- package/dashboard/.output/public/_nuxt/entry.D51cHmax.css +1 -0
- package/dashboard/.output/public/_nuxt/error-404.C3kT2QX-.css +1 -0
- package/dashboard/.output/public/_nuxt/error-500.BW0Y54Of.css +1 -0
- package/dashboard/.output/public/_nuxt/fpe_5SoV.js +1 -0
- package/dashboard/.output/server/chunks/_/db.mjs +27 -0
- package/dashboard/.output/server/chunks/_/db.mjs.map +1 -0
- package/dashboard/.output/server/chunks/_/error-500.mjs +19 -0
- package/dashboard/.output/server/chunks/_/error-500.mjs.map +1 -0
- package/dashboard/.output/server/chunks/build/_id_-CQaF66RF.mjs +139 -0
- package/dashboard/.output/server/chunks/build/_id_-CQaF66RF.mjs.map +1 -0
- package/dashboard/.output/server/chunks/build/_id_-styles.DKwggH1p.mjs +8 -0
- package/dashboard/.output/server/chunks/build/_id_-styles.DKwggH1p.mjs.map +1 -0
- package/dashboard/.output/server/chunks/build/app-styles.nHRnXOH3.mjs +25 -0
- package/dashboard/.output/server/chunks/build/app-styles.nHRnXOH3.mjs.map +1 -0
- package/dashboard/.output/server/chunks/build/client.precomputed.mjs +4 -0
- package/dashboard/.output/server/chunks/build/client.precomputed.mjs.map +1 -0
- package/dashboard/.output/server/chunks/build/composables-lps5heb5.mjs +23 -0
- package/dashboard/.output/server/chunks/build/composables-lps5heb5.mjs.map +1 -0
- package/dashboard/.output/server/chunks/build/error-404-D0Xi6cQ6.mjs +92 -0
- package/dashboard/.output/server/chunks/build/error-404-D0Xi6cQ6.mjs.map +1 -0
- package/dashboard/.output/server/chunks/build/error-404-styles.C8lgdT6t.mjs +8 -0
- package/dashboard/.output/server/chunks/build/error-404-styles.C8lgdT6t.mjs.map +1 -0
- package/dashboard/.output/server/chunks/build/error-500-DabQpmqy.mjs +75 -0
- package/dashboard/.output/server/chunks/build/error-500-DabQpmqy.mjs.map +1 -0
- package/dashboard/.output/server/chunks/build/error-500-styles.Ccrcwcfa.mjs +8 -0
- package/dashboard/.output/server/chunks/build/error-500-styles.Ccrcwcfa.mjs.map +1 -0
- package/dashboard/.output/server/chunks/build/fetch-BlczD9wj.mjs +503 -0
- package/dashboard/.output/server/chunks/build/fetch-BlczD9wj.mjs.map +1 -0
- package/dashboard/.output/server/chunks/build/index-C-zhU_b9.mjs +174 -0
- package/dashboard/.output/server/chunks/build/index-C-zhU_b9.mjs.map +1 -0
- package/dashboard/.output/server/chunks/build/index-Dnk7jknb.mjs +154 -0
- package/dashboard/.output/server/chunks/build/index-Dnk7jknb.mjs.map +1 -0
- package/dashboard/.output/server/chunks/build/server.mjs +1552 -0
- package/dashboard/.output/server/chunks/build/server.mjs.map +1 -0
- package/dashboard/.output/server/chunks/build/styles.mjs +10 -0
- package/dashboard/.output/server/chunks/build/styles.mjs.map +1 -0
- package/dashboard/.output/server/chunks/nitro/nitro.mjs +5497 -0
- package/dashboard/.output/server/chunks/nitro/nitro.mjs.map +1 -0
- package/dashboard/.output/server/chunks/routes/api/lessons/_id_.get.mjs +35 -0
- package/dashboard/.output/server/chunks/routes/api/lessons/_id_.get.mjs.map +1 -0
- package/dashboard/.output/server/chunks/routes/api/lessons.get.mjs +64 -0
- package/dashboard/.output/server/chunks/routes/api/lessons.get.mjs.map +1 -0
- package/dashboard/.output/server/chunks/routes/api/stats.get.mjs +59 -0
- package/dashboard/.output/server/chunks/routes/api/stats.get.mjs.map +1 -0
- package/dashboard/.output/server/chunks/routes/renderer.mjs +458 -0
- package/dashboard/.output/server/chunks/routes/renderer.mjs.map +1 -0
- package/dashboard/.output/server/chunks/virtual/_virtual_spa-template.mjs +4 -0
- package/dashboard/.output/server/chunks/virtual/_virtual_spa-template.mjs.map +1 -0
- package/dashboard/.output/server/index.mjs +10 -0
- package/dashboard/.output/server/index.mjs.map +1 -0
- package/dashboard/.output/server/node_modules/@babel/parser/lib/index.js +14599 -0
- package/dashboard/.output/server/node_modules/@babel/parser/package.json +50 -0
- package/dashboard/.output/server/node_modules/@vue/compiler-core/dist/compiler-core.cjs.prod.js +6759 -0
- package/dashboard/.output/server/node_modules/@vue/compiler-core/package.json +58 -0
- package/dashboard/.output/server/node_modules/@vue/compiler-dom/dist/compiler-dom.cjs.prod.js +689 -0
- package/dashboard/.output/server/node_modules/@vue/compiler-dom/package.json +57 -0
- package/dashboard/.output/server/node_modules/@vue/compiler-ssr/dist/compiler-ssr.cjs.js +1413 -0
- package/dashboard/.output/server/node_modules/@vue/compiler-ssr/package.json +34 -0
- package/dashboard/.output/server/node_modules/@vue/devtools-api/lib/cjs/api/api.js +2 -0
- package/dashboard/.output/server/node_modules/@vue/devtools-api/lib/cjs/api/app.js +2 -0
- package/dashboard/.output/server/node_modules/@vue/devtools-api/lib/cjs/api/component.js +2 -0
- package/dashboard/.output/server/node_modules/@vue/devtools-api/lib/cjs/api/context.js +2 -0
- package/dashboard/.output/server/node_modules/@vue/devtools-api/lib/cjs/api/hooks.js +2 -0
- package/dashboard/.output/server/node_modules/@vue/devtools-api/lib/cjs/api/index.js +22 -0
- package/dashboard/.output/server/node_modules/@vue/devtools-api/lib/cjs/api/util.js +2 -0
- package/dashboard/.output/server/node_modules/@vue/devtools-api/lib/cjs/const.js +5 -0
- package/dashboard/.output/server/node_modules/@vue/devtools-api/lib/cjs/env.js +17 -0
- package/dashboard/.output/server/node_modules/@vue/devtools-api/lib/cjs/index.js +45 -0
- package/dashboard/.output/server/node_modules/@vue/devtools-api/lib/cjs/plugin.js +2 -0
- package/dashboard/.output/server/node_modules/@vue/devtools-api/lib/cjs/proxy.js +111 -0
- package/dashboard/.output/server/node_modules/@vue/devtools-api/lib/cjs/time.js +28 -0
- package/dashboard/.output/server/node_modules/@vue/devtools-api/package.json +37 -0
- package/dashboard/.output/server/node_modules/@vue/reactivity/dist/reactivity.cjs.prod.js +1899 -0
- package/dashboard/.output/server/node_modules/@vue/reactivity/package.json +55 -0
- package/dashboard/.output/server/node_modules/@vue/runtime-core/dist/runtime-core.cjs.prod.js +6940 -0
- package/dashboard/.output/server/node_modules/@vue/runtime-core/package.json +52 -0
- package/dashboard/.output/server/node_modules/@vue/runtime-dom/dist/runtime-dom.cjs.prod.js +1822 -0
- package/dashboard/.output/server/node_modules/@vue/runtime-dom/package.json +60 -0
- package/dashboard/.output/server/node_modules/@vue/server-renderer/dist/server-renderer.cjs.prod.js +896 -0
- package/dashboard/.output/server/node_modules/@vue/server-renderer/package.json +55 -0
- package/dashboard/.output/server/node_modules/@vue/shared/dist/shared.cjs.prod.js +604 -0
- package/dashboard/.output/server/node_modules/@vue/shared/package.json +47 -0
- package/dashboard/.output/server/node_modules/devalue/index.js +4 -0
- package/dashboard/.output/server/node_modules/devalue/package.json +40 -0
- package/dashboard/.output/server/node_modules/devalue/src/base64.js +60 -0
- package/dashboard/.output/server/node_modules/devalue/src/constants.js +12 -0
- package/dashboard/.output/server/node_modules/devalue/src/parse.js +283 -0
- package/dashboard/.output/server/node_modules/devalue/src/stringify.js +401 -0
- package/dashboard/.output/server/node_modules/devalue/src/uneval.js +552 -0
- package/dashboard/.output/server/node_modules/devalue/src/utils.js +160 -0
- package/dashboard/.output/server/node_modules/entities/dist/commonjs/decode-codepoint.js +77 -0
- package/dashboard/.output/server/node_modules/entities/dist/commonjs/decode.js +568 -0
- package/dashboard/.output/server/node_modules/entities/dist/commonjs/generated/decode-data-html.js +7 -0
- package/dashboard/.output/server/node_modules/entities/dist/commonjs/generated/decode-data-xml.js +7 -0
- package/dashboard/.output/server/node_modules/entities/dist/commonjs/internal/bin-trie-flags.js +21 -0
- package/dashboard/.output/server/node_modules/entities/dist/commonjs/internal/decode-shared.js +31 -0
- package/dashboard/.output/server/node_modules/entities/dist/commonjs/package.json +3 -0
- package/dashboard/.output/server/node_modules/entities/package.json +120 -0
- package/dashboard/.output/server/node_modules/estree-walker/dist/umd/estree-walker.js +344 -0
- package/dashboard/.output/server/node_modules/estree-walker/package.json +37 -0
- package/dashboard/.output/server/node_modules/hookable/dist/index.mjs +257 -0
- package/dashboard/.output/server/node_modules/hookable/package.json +53 -0
- package/dashboard/.output/server/node_modules/perfect-debounce/dist/index.mjs +89 -0
- package/dashboard/.output/server/node_modules/perfect-debounce/package.json +41 -0
- package/dashboard/.output/server/node_modules/source-map-js/lib/array-set.js +121 -0
- package/dashboard/.output/server/node_modules/source-map-js/lib/base64-vlq.js +140 -0
- package/dashboard/.output/server/node_modules/source-map-js/lib/base64.js +67 -0
- package/dashboard/.output/server/node_modules/source-map-js/lib/binary-search.js +111 -0
- package/dashboard/.output/server/node_modules/source-map-js/lib/mapping-list.js +79 -0
- package/dashboard/.output/server/node_modules/source-map-js/lib/quick-sort.js +132 -0
- package/dashboard/.output/server/node_modules/source-map-js/lib/source-map-consumer.js +1188 -0
- package/dashboard/.output/server/node_modules/source-map-js/lib/source-map-generator.js +444 -0
- package/dashboard/.output/server/node_modules/source-map-js/lib/source-node.js +413 -0
- package/dashboard/.output/server/node_modules/source-map-js/lib/util.js +594 -0
- package/dashboard/.output/server/node_modules/source-map-js/package.json +71 -0
- package/dashboard/.output/server/node_modules/source-map-js/source-map.js +8 -0
- package/dashboard/.output/server/node_modules/ufo/dist/index.mjs +645 -0
- package/dashboard/.output/server/node_modules/ufo/package.json +48 -0
- package/dashboard/.output/server/node_modules/unhead/dist/index.mjs +9 -0
- package/dashboard/.output/server/node_modules/unhead/dist/parser.mjs +508 -0
- package/dashboard/.output/server/node_modules/unhead/dist/plugins.mjs +101 -0
- package/dashboard/.output/server/node_modules/unhead/dist/scripts.mjs +30 -0
- package/dashboard/.output/server/node_modules/unhead/dist/server.mjs +180 -0
- package/dashboard/.output/server/node_modules/unhead/dist/shared/unhead.B3VbJo7Y.mjs +207 -0
- package/dashboard/.output/server/node_modules/unhead/dist/shared/unhead.BYvz9V1x.mjs +43 -0
- package/dashboard/.output/server/node_modules/unhead/dist/shared/unhead.BnoAbrHA.mjs +269 -0
- package/dashboard/.output/server/node_modules/unhead/dist/shared/unhead.CaI5ZD4O.mjs +182 -0
- package/dashboard/.output/server/node_modules/unhead/dist/shared/unhead.CbpEuj3y.mjs +71 -0
- package/dashboard/.output/server/node_modules/unhead/dist/shared/unhead.D4vSFytZ.mjs +236 -0
- package/dashboard/.output/server/node_modules/unhead/dist/shared/unhead.DQc16pHI.mjs +196 -0
- package/dashboard/.output/server/node_modules/unhead/dist/shared/unhead.Dh1cQCTe.mjs +44 -0
- package/dashboard/.output/server/node_modules/unhead/dist/shared/unhead.TxTMM7cM.mjs +166 -0
- package/dashboard/.output/server/node_modules/unhead/dist/shared/unhead.yem5I2v_.mjs +38 -0
- package/dashboard/.output/server/node_modules/unhead/dist/utils.mjs +5 -0
- package/dashboard/.output/server/node_modules/unhead/package.json +105 -0
- package/dashboard/.output/server/node_modules/vue/dist/vue.cjs.js +80 -0
- package/dashboard/.output/server/node_modules/vue/dist/vue.cjs.prod.js +66 -0
- package/dashboard/.output/server/node_modules/vue/index.js +7 -0
- package/dashboard/.output/server/node_modules/vue/index.mjs +1 -0
- package/dashboard/.output/server/node_modules/vue/package.json +112 -0
- package/dashboard/.output/server/node_modules/vue/server-renderer/index.mjs +1 -0
- package/dashboard/.output/server/node_modules/vue-bundle-renderer/dist/runtime.mjs +249 -0
- package/dashboard/.output/server/node_modules/vue-bundle-renderer/package.json +57 -0
- package/dashboard/.output/server/node_modules/vue-router/dist/devtools-EWN81iOl.mjs +1220 -0
- package/dashboard/.output/server/node_modules/vue-router/dist/vue-router.mjs +1557 -0
- package/dashboard/.output/server/node_modules/vue-router/package.json +153 -0
- package/dashboard/.output/server/node_modules/vue-router/vue-router.node.mjs +2 -0
- package/dashboard/.output/server/package.json +29 -0
- package/dist/cli/commands/dashboard.d.ts +2 -0
- package/dist/cli/commands/dashboard.d.ts.map +1 -0
- package/dist/cli/commands/dashboard.js +30 -0
- package/dist/cli/commands/dashboard.js.map +1 -0
- package/dist/cli/index.js +5 -0
- package/dist/cli/index.js.map +1 -1
- package/package.json +3 -2
|
@@ -0,0 +1,1552 @@
|
|
|
1
|
+
import process from 'node:process';globalThis._importMeta_=globalThis._importMeta_||{url:"file:///_entry.js",env:process.env};import { hasInjectionContext, inject, defineComponent, shallowRef, h, resolveComponent, getCurrentInstance, computed, unref, ref, Suspense, Fragment, createApp, provide, shallowReactive, onErrorCaptured, onServerPrefetch, createVNode, resolveDynamicComponent, reactive, effectScope, defineAsyncComponent, mergeProps, getCurrentScope, toRef, withCtx, createTextVNode, isReadonly, useSSRContext, isRef, isShallow, isReactive, toRaw } from 'vue';
|
|
2
|
+
import { c as createError$1, p as parseQuery, m as hasProtocol, n as joinURL, o as parseURL, e as encodePath, q as decodePath, r as getContext, s as isScriptProtocol, w as withQuery, t as withTrailingSlash, v as withoutTrailingSlash, x as sanitizeStatusCode, $ as $fetch, y as executeAsync, z as defu } from '../nitro/nitro.mjs';
|
|
3
|
+
import { b as baseURL } from '../routes/renderer.mjs';
|
|
4
|
+
import { RouterView, createMemoryHistory, createRouter, START_LOCATION } from 'vue-router';
|
|
5
|
+
import { ssrRenderSuspense, ssrRenderComponent, ssrRenderVNode, ssrRenderAttrs } from 'vue/server-renderer';
|
|
6
|
+
import 'node:http';
|
|
7
|
+
import 'node:https';
|
|
8
|
+
import 'node:events';
|
|
9
|
+
import 'node:buffer';
|
|
10
|
+
import 'node:fs';
|
|
11
|
+
import 'node:path';
|
|
12
|
+
import 'node:crypto';
|
|
13
|
+
import 'node:url';
|
|
14
|
+
import 'vue-bundle-renderer/runtime';
|
|
15
|
+
import 'unhead/server';
|
|
16
|
+
import 'devalue';
|
|
17
|
+
import 'unhead/utils';
|
|
18
|
+
|
|
19
|
+
function flatHooks(configHooks, hooks = {}, parentName) {
|
|
20
|
+
for (const key in configHooks) {
|
|
21
|
+
const subHook = configHooks[key];
|
|
22
|
+
const name = parentName ? `${parentName}:${key}` : key;
|
|
23
|
+
if (typeof subHook === "object" && subHook !== null) flatHooks(subHook, hooks, name);
|
|
24
|
+
else if (typeof subHook === "function") hooks[name] = subHook;
|
|
25
|
+
}
|
|
26
|
+
return hooks;
|
|
27
|
+
}
|
|
28
|
+
const createTask = /* @__PURE__ */ (() => {
|
|
29
|
+
if (console.createTask) return console.createTask;
|
|
30
|
+
const defaultTask = { run: (fn) => fn() };
|
|
31
|
+
return () => defaultTask;
|
|
32
|
+
})();
|
|
33
|
+
function callHooks(hooks, args, startIndex, task) {
|
|
34
|
+
for (let i = startIndex; i < hooks.length; i += 1) try {
|
|
35
|
+
const result = task ? task.run(() => hooks[i](...args)) : hooks[i](...args);
|
|
36
|
+
if (result && typeof result.then === "function") return Promise.resolve(result).then(() => callHooks(hooks, args, i + 1, task));
|
|
37
|
+
} catch (error) {
|
|
38
|
+
return Promise.reject(error);
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
function serialTaskCaller(hooks, args, name) {
|
|
42
|
+
if (hooks.length > 0) return callHooks(hooks, args, 0, createTask(name));
|
|
43
|
+
}
|
|
44
|
+
function parallelTaskCaller(hooks, args, name) {
|
|
45
|
+
if (hooks.length > 0) {
|
|
46
|
+
const task = createTask(name);
|
|
47
|
+
return Promise.all(hooks.map((hook) => task.run(() => hook(...args))));
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
function callEachWith(callbacks, arg0) {
|
|
51
|
+
for (const callback of [...callbacks]) callback(arg0);
|
|
52
|
+
}
|
|
53
|
+
var Hookable = class {
|
|
54
|
+
_hooks;
|
|
55
|
+
_before;
|
|
56
|
+
_after;
|
|
57
|
+
_deprecatedHooks;
|
|
58
|
+
_deprecatedMessages;
|
|
59
|
+
constructor() {
|
|
60
|
+
this._hooks = {};
|
|
61
|
+
this._before = void 0;
|
|
62
|
+
this._after = void 0;
|
|
63
|
+
this._deprecatedMessages = void 0;
|
|
64
|
+
this._deprecatedHooks = {};
|
|
65
|
+
this.hook = this.hook.bind(this);
|
|
66
|
+
this.callHook = this.callHook.bind(this);
|
|
67
|
+
this.callHookWith = this.callHookWith.bind(this);
|
|
68
|
+
}
|
|
69
|
+
hook(name, function_, options = {}) {
|
|
70
|
+
if (!name || typeof function_ !== "function") return () => {};
|
|
71
|
+
const originalName = name;
|
|
72
|
+
let dep;
|
|
73
|
+
while (this._deprecatedHooks[name]) {
|
|
74
|
+
dep = this._deprecatedHooks[name];
|
|
75
|
+
name = dep.to;
|
|
76
|
+
}
|
|
77
|
+
if (dep && !options.allowDeprecated) {
|
|
78
|
+
let message = dep.message;
|
|
79
|
+
if (!message) message = `${originalName} hook has been deprecated` + (dep.to ? `, please use ${dep.to}` : "");
|
|
80
|
+
if (!this._deprecatedMessages) this._deprecatedMessages = /* @__PURE__ */ new Set();
|
|
81
|
+
if (!this._deprecatedMessages.has(message)) {
|
|
82
|
+
console.warn(message);
|
|
83
|
+
this._deprecatedMessages.add(message);
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
if (!function_.name) try {
|
|
87
|
+
Object.defineProperty(function_, "name", {
|
|
88
|
+
get: () => "_" + name.replace(/\W+/g, "_") + "_hook_cb",
|
|
89
|
+
configurable: true
|
|
90
|
+
});
|
|
91
|
+
} catch {}
|
|
92
|
+
this._hooks[name] = this._hooks[name] || [];
|
|
93
|
+
this._hooks[name].push(function_);
|
|
94
|
+
return () => {
|
|
95
|
+
if (function_) {
|
|
96
|
+
this.removeHook(name, function_);
|
|
97
|
+
function_ = void 0;
|
|
98
|
+
}
|
|
99
|
+
};
|
|
100
|
+
}
|
|
101
|
+
hookOnce(name, function_) {
|
|
102
|
+
let _unreg;
|
|
103
|
+
let _function = (...arguments_) => {
|
|
104
|
+
if (typeof _unreg === "function") _unreg();
|
|
105
|
+
_unreg = void 0;
|
|
106
|
+
_function = void 0;
|
|
107
|
+
return function_(...arguments_);
|
|
108
|
+
};
|
|
109
|
+
_unreg = this.hook(name, _function);
|
|
110
|
+
return _unreg;
|
|
111
|
+
}
|
|
112
|
+
removeHook(name, function_) {
|
|
113
|
+
const hooks = this._hooks[name];
|
|
114
|
+
if (hooks) {
|
|
115
|
+
const index = hooks.indexOf(function_);
|
|
116
|
+
if (index !== -1) hooks.splice(index, 1);
|
|
117
|
+
if (hooks.length === 0) this._hooks[name] = void 0;
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
clearHook(name) {
|
|
121
|
+
this._hooks[name] = void 0;
|
|
122
|
+
}
|
|
123
|
+
deprecateHook(name, deprecated) {
|
|
124
|
+
this._deprecatedHooks[name] = typeof deprecated === "string" ? { to: deprecated } : deprecated;
|
|
125
|
+
const _hooks = this._hooks[name] || [];
|
|
126
|
+
this._hooks[name] = void 0;
|
|
127
|
+
for (const hook of _hooks) this.hook(name, hook);
|
|
128
|
+
}
|
|
129
|
+
deprecateHooks(deprecatedHooks) {
|
|
130
|
+
for (const name in deprecatedHooks) this.deprecateHook(name, deprecatedHooks[name]);
|
|
131
|
+
}
|
|
132
|
+
addHooks(configHooks) {
|
|
133
|
+
const hooks = flatHooks(configHooks);
|
|
134
|
+
const removeFns = Object.keys(hooks).map((key) => this.hook(key, hooks[key]));
|
|
135
|
+
return () => {
|
|
136
|
+
for (const unreg of removeFns) unreg();
|
|
137
|
+
removeFns.length = 0;
|
|
138
|
+
};
|
|
139
|
+
}
|
|
140
|
+
removeHooks(configHooks) {
|
|
141
|
+
const hooks = flatHooks(configHooks);
|
|
142
|
+
for (const key in hooks) this.removeHook(key, hooks[key]);
|
|
143
|
+
}
|
|
144
|
+
removeAllHooks() {
|
|
145
|
+
this._hooks = {};
|
|
146
|
+
}
|
|
147
|
+
callHook(name, ...args) {
|
|
148
|
+
return this.callHookWith(serialTaskCaller, name, args);
|
|
149
|
+
}
|
|
150
|
+
callHookParallel(name, ...args) {
|
|
151
|
+
return this.callHookWith(parallelTaskCaller, name, args);
|
|
152
|
+
}
|
|
153
|
+
callHookWith(caller, name, args) {
|
|
154
|
+
const event = this._before || this._after ? {
|
|
155
|
+
name,
|
|
156
|
+
args,
|
|
157
|
+
context: {}
|
|
158
|
+
} : void 0;
|
|
159
|
+
if (this._before) callEachWith(this._before, event);
|
|
160
|
+
const result = caller(this._hooks[name] ? [...this._hooks[name]] : [], args, name);
|
|
161
|
+
if (result instanceof Promise) return result.finally(() => {
|
|
162
|
+
if (this._after && event) callEachWith(this._after, event);
|
|
163
|
+
});
|
|
164
|
+
if (this._after && event) callEachWith(this._after, event);
|
|
165
|
+
return result;
|
|
166
|
+
}
|
|
167
|
+
beforeEach(function_) {
|
|
168
|
+
this._before = this._before || [];
|
|
169
|
+
this._before.push(function_);
|
|
170
|
+
return () => {
|
|
171
|
+
if (this._before !== void 0) {
|
|
172
|
+
const index = this._before.indexOf(function_);
|
|
173
|
+
if (index !== -1) this._before.splice(index, 1);
|
|
174
|
+
}
|
|
175
|
+
};
|
|
176
|
+
}
|
|
177
|
+
afterEach(function_) {
|
|
178
|
+
this._after = this._after || [];
|
|
179
|
+
this._after.push(function_);
|
|
180
|
+
return () => {
|
|
181
|
+
if (this._after !== void 0) {
|
|
182
|
+
const index = this._after.indexOf(function_);
|
|
183
|
+
if (index !== -1) this._after.splice(index, 1);
|
|
184
|
+
}
|
|
185
|
+
};
|
|
186
|
+
}
|
|
187
|
+
};
|
|
188
|
+
function createHooks() {
|
|
189
|
+
return new Hookable();
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
if (!globalThis.$fetch) {
|
|
193
|
+
globalThis.$fetch = $fetch.create({
|
|
194
|
+
baseURL: baseURL()
|
|
195
|
+
});
|
|
196
|
+
}
|
|
197
|
+
if (!("global" in globalThis)) {
|
|
198
|
+
globalThis.global = globalThis;
|
|
199
|
+
}
|
|
200
|
+
const nuxtLinkDefaults = { "componentName": "NuxtLink" };
|
|
201
|
+
const asyncDataDefaults = { "deep": false };
|
|
202
|
+
const fetchDefaults = {};
|
|
203
|
+
const appId = "nuxt-app";
|
|
204
|
+
function getNuxtAppCtx(id = appId) {
|
|
205
|
+
return getContext(id, {
|
|
206
|
+
asyncContext: false
|
|
207
|
+
});
|
|
208
|
+
}
|
|
209
|
+
const NuxtPluginIndicator = "__nuxt_plugin";
|
|
210
|
+
function createNuxtApp(options) {
|
|
211
|
+
let hydratingCount = 0;
|
|
212
|
+
const nuxtApp = {
|
|
213
|
+
_id: options.id || appId || "nuxt-app",
|
|
214
|
+
_scope: effectScope(),
|
|
215
|
+
provide: void 0,
|
|
216
|
+
versions: {
|
|
217
|
+
get nuxt() {
|
|
218
|
+
return "4.4.8";
|
|
219
|
+
},
|
|
220
|
+
get vue() {
|
|
221
|
+
return nuxtApp.vueApp.version;
|
|
222
|
+
}
|
|
223
|
+
},
|
|
224
|
+
payload: shallowReactive({
|
|
225
|
+
...options.ssrContext?.payload || {},
|
|
226
|
+
data: shallowReactive({}),
|
|
227
|
+
state: reactive({}),
|
|
228
|
+
once: /* @__PURE__ */ new Set(),
|
|
229
|
+
_errors: shallowReactive({})
|
|
230
|
+
}),
|
|
231
|
+
static: {
|
|
232
|
+
data: {}
|
|
233
|
+
},
|
|
234
|
+
runWithContext(fn) {
|
|
235
|
+
if (nuxtApp._scope.active && !getCurrentScope()) {
|
|
236
|
+
return nuxtApp._scope.run(() => callWithNuxt(nuxtApp, fn));
|
|
237
|
+
}
|
|
238
|
+
return callWithNuxt(nuxtApp, fn);
|
|
239
|
+
},
|
|
240
|
+
isHydrating: false,
|
|
241
|
+
deferHydration() {
|
|
242
|
+
if (!nuxtApp.isHydrating) {
|
|
243
|
+
return () => {
|
|
244
|
+
};
|
|
245
|
+
}
|
|
246
|
+
hydratingCount++;
|
|
247
|
+
let called = false;
|
|
248
|
+
return () => {
|
|
249
|
+
if (called) {
|
|
250
|
+
return;
|
|
251
|
+
}
|
|
252
|
+
called = true;
|
|
253
|
+
hydratingCount--;
|
|
254
|
+
if (hydratingCount === 0) {
|
|
255
|
+
nuxtApp.isHydrating = false;
|
|
256
|
+
return nuxtApp.callHook("app:suspense:resolve");
|
|
257
|
+
}
|
|
258
|
+
};
|
|
259
|
+
},
|
|
260
|
+
_asyncDataPromises: {},
|
|
261
|
+
_asyncData: shallowReactive({}),
|
|
262
|
+
_state: shallowReactive({}),
|
|
263
|
+
_payloadRevivers: {},
|
|
264
|
+
...options
|
|
265
|
+
};
|
|
266
|
+
{
|
|
267
|
+
nuxtApp.payload.serverRendered = true;
|
|
268
|
+
}
|
|
269
|
+
if (nuxtApp.ssrContext) {
|
|
270
|
+
nuxtApp.payload.path = nuxtApp.ssrContext.url;
|
|
271
|
+
nuxtApp.ssrContext.nuxt = nuxtApp;
|
|
272
|
+
nuxtApp.ssrContext.payload = nuxtApp.payload;
|
|
273
|
+
nuxtApp.ssrContext.config = {
|
|
274
|
+
public: nuxtApp.ssrContext.runtimeConfig.public,
|
|
275
|
+
app: nuxtApp.ssrContext.runtimeConfig.app
|
|
276
|
+
};
|
|
277
|
+
}
|
|
278
|
+
nuxtApp.hooks = createHooks();
|
|
279
|
+
nuxtApp.hook = nuxtApp.hooks.hook;
|
|
280
|
+
{
|
|
281
|
+
const contextCaller = async function(hooks, args) {
|
|
282
|
+
for (const hook of hooks) {
|
|
283
|
+
await nuxtApp.runWithContext(() => hook(...args));
|
|
284
|
+
}
|
|
285
|
+
};
|
|
286
|
+
nuxtApp.hooks.callHook = (name, ...args) => nuxtApp.hooks.callHookWith(contextCaller, name, args);
|
|
287
|
+
}
|
|
288
|
+
nuxtApp.callHook = nuxtApp.hooks.callHook;
|
|
289
|
+
nuxtApp.provide = (name, value) => {
|
|
290
|
+
const $name = "$" + name;
|
|
291
|
+
defineGetter(nuxtApp, $name, value);
|
|
292
|
+
defineGetter(nuxtApp.vueApp.config.globalProperties, $name, value);
|
|
293
|
+
};
|
|
294
|
+
defineGetter(nuxtApp.vueApp, "$nuxt", nuxtApp);
|
|
295
|
+
defineGetter(nuxtApp.vueApp.config.globalProperties, "$nuxt", nuxtApp);
|
|
296
|
+
const runtimeConfig = options.ssrContext.runtimeConfig;
|
|
297
|
+
nuxtApp.provide("config", runtimeConfig);
|
|
298
|
+
return nuxtApp;
|
|
299
|
+
}
|
|
300
|
+
function registerPluginHooks(nuxtApp, plugin2) {
|
|
301
|
+
if (plugin2.hooks) {
|
|
302
|
+
nuxtApp.hooks.addHooks(plugin2.hooks);
|
|
303
|
+
}
|
|
304
|
+
}
|
|
305
|
+
async function applyPlugin(nuxtApp, plugin2) {
|
|
306
|
+
if (typeof plugin2 === "function") {
|
|
307
|
+
const { provide: provide2 } = await nuxtApp.runWithContext(() => plugin2(nuxtApp)) || {};
|
|
308
|
+
if (provide2 && typeof provide2 === "object") {
|
|
309
|
+
for (const key in provide2) {
|
|
310
|
+
nuxtApp.provide(key, provide2[key]);
|
|
311
|
+
}
|
|
312
|
+
}
|
|
313
|
+
}
|
|
314
|
+
}
|
|
315
|
+
async function applyPlugins(nuxtApp, plugins2) {
|
|
316
|
+
const resolvedPlugins = /* @__PURE__ */ new Set();
|
|
317
|
+
const unresolvedPlugins = [];
|
|
318
|
+
const parallels = [];
|
|
319
|
+
let error = void 0;
|
|
320
|
+
let promiseDepth = 0;
|
|
321
|
+
async function executePlugin(plugin2) {
|
|
322
|
+
const unresolvedPluginsForThisPlugin = plugin2.dependsOn?.filter((name) => plugins2.some((p) => p._name === name) && !resolvedPlugins.has(name)) ?? [];
|
|
323
|
+
if (unresolvedPluginsForThisPlugin.length > 0) {
|
|
324
|
+
unresolvedPlugins.push([new Set(unresolvedPluginsForThisPlugin), plugin2]);
|
|
325
|
+
} else {
|
|
326
|
+
const promise = applyPlugin(nuxtApp, plugin2).then(async () => {
|
|
327
|
+
if (plugin2._name) {
|
|
328
|
+
resolvedPlugins.add(plugin2._name);
|
|
329
|
+
await Promise.all(unresolvedPlugins.map(async ([dependsOn, unexecutedPlugin]) => {
|
|
330
|
+
if (dependsOn.has(plugin2._name)) {
|
|
331
|
+
dependsOn.delete(plugin2._name);
|
|
332
|
+
if (dependsOn.size === 0) {
|
|
333
|
+
promiseDepth++;
|
|
334
|
+
await executePlugin(unexecutedPlugin);
|
|
335
|
+
}
|
|
336
|
+
}
|
|
337
|
+
}));
|
|
338
|
+
}
|
|
339
|
+
}).catch((e) => {
|
|
340
|
+
if (!plugin2.parallel && !nuxtApp.payload.error) {
|
|
341
|
+
throw e;
|
|
342
|
+
}
|
|
343
|
+
error ||= e;
|
|
344
|
+
});
|
|
345
|
+
if (plugin2.parallel) {
|
|
346
|
+
parallels.push(promise);
|
|
347
|
+
} else {
|
|
348
|
+
await promise;
|
|
349
|
+
}
|
|
350
|
+
}
|
|
351
|
+
}
|
|
352
|
+
for (const plugin2 of plugins2) {
|
|
353
|
+
if (nuxtApp.ssrContext?.islandContext && plugin2.env?.islands === false) {
|
|
354
|
+
continue;
|
|
355
|
+
}
|
|
356
|
+
registerPluginHooks(nuxtApp, plugin2);
|
|
357
|
+
}
|
|
358
|
+
for (const plugin2 of plugins2) {
|
|
359
|
+
if (nuxtApp.ssrContext?.islandContext && plugin2.env?.islands === false) {
|
|
360
|
+
continue;
|
|
361
|
+
}
|
|
362
|
+
await executePlugin(plugin2);
|
|
363
|
+
}
|
|
364
|
+
await Promise.all(parallels);
|
|
365
|
+
if (promiseDepth) {
|
|
366
|
+
for (let i = 0; i < promiseDepth; i++) {
|
|
367
|
+
await Promise.all(parallels);
|
|
368
|
+
}
|
|
369
|
+
}
|
|
370
|
+
if (error) {
|
|
371
|
+
throw nuxtApp.payload.error || error;
|
|
372
|
+
}
|
|
373
|
+
}
|
|
374
|
+
// @__NO_SIDE_EFFECTS__
|
|
375
|
+
function defineNuxtPlugin(plugin2) {
|
|
376
|
+
if (typeof plugin2 === "function") {
|
|
377
|
+
return plugin2;
|
|
378
|
+
}
|
|
379
|
+
const _name = plugin2._name || plugin2.name;
|
|
380
|
+
delete plugin2.name;
|
|
381
|
+
return Object.assign(plugin2.setup || (() => {
|
|
382
|
+
}), plugin2, { [NuxtPluginIndicator]: true, _name });
|
|
383
|
+
}
|
|
384
|
+
function callWithNuxt(nuxt, setup, args) {
|
|
385
|
+
const fn = () => setup();
|
|
386
|
+
const nuxtAppCtx = getNuxtAppCtx(nuxt._id);
|
|
387
|
+
{
|
|
388
|
+
return nuxt.vueApp.runWithContext(() => nuxtAppCtx.callAsync(nuxt, fn));
|
|
389
|
+
}
|
|
390
|
+
}
|
|
391
|
+
function tryUseNuxtApp(id) {
|
|
392
|
+
let nuxtAppInstance;
|
|
393
|
+
if (hasInjectionContext()) {
|
|
394
|
+
nuxtAppInstance = getCurrentInstance()?.appContext.app.$nuxt;
|
|
395
|
+
}
|
|
396
|
+
nuxtAppInstance ||= getNuxtAppCtx(id).tryUse();
|
|
397
|
+
return nuxtAppInstance || null;
|
|
398
|
+
}
|
|
399
|
+
function useNuxtApp(id) {
|
|
400
|
+
const nuxtAppInstance = tryUseNuxtApp(id);
|
|
401
|
+
if (!nuxtAppInstance) {
|
|
402
|
+
{
|
|
403
|
+
throw new Error("[nuxt] instance unavailable");
|
|
404
|
+
}
|
|
405
|
+
}
|
|
406
|
+
return nuxtAppInstance;
|
|
407
|
+
}
|
|
408
|
+
// @__NO_SIDE_EFFECTS__
|
|
409
|
+
function useRuntimeConfig(_event) {
|
|
410
|
+
return useNuxtApp().$config;
|
|
411
|
+
}
|
|
412
|
+
function defineGetter(obj, key, val) {
|
|
413
|
+
Object.defineProperty(obj, key, { get: () => val });
|
|
414
|
+
}
|
|
415
|
+
const LayoutMetaSymbol = /* @__PURE__ */ Symbol("layout-meta");
|
|
416
|
+
const PageRouteSymbol = /* @__PURE__ */ Symbol("route");
|
|
417
|
+
globalThis._importMeta_.url.replace(/\/app\/.*$/, "/");
|
|
418
|
+
const useRouter = () => {
|
|
419
|
+
return useNuxtApp()?.$router;
|
|
420
|
+
};
|
|
421
|
+
const useRoute = () => {
|
|
422
|
+
if (hasInjectionContext()) {
|
|
423
|
+
return inject(PageRouteSymbol, useNuxtApp()._route);
|
|
424
|
+
}
|
|
425
|
+
return useNuxtApp()._route;
|
|
426
|
+
};
|
|
427
|
+
// @__NO_SIDE_EFFECTS__
|
|
428
|
+
function defineNuxtRouteMiddleware(middleware) {
|
|
429
|
+
return middleware;
|
|
430
|
+
}
|
|
431
|
+
const isProcessingMiddleware = () => {
|
|
432
|
+
try {
|
|
433
|
+
if (useNuxtApp()._processingMiddleware) {
|
|
434
|
+
return true;
|
|
435
|
+
}
|
|
436
|
+
} catch {
|
|
437
|
+
return false;
|
|
438
|
+
}
|
|
439
|
+
return false;
|
|
440
|
+
};
|
|
441
|
+
const HTML_ATTR_UNSAFE_RE = /[&"'<>]/g;
|
|
442
|
+
const HTML_ATTR_ENCODE_MAP = {
|
|
443
|
+
"&": "%26",
|
|
444
|
+
'"': "%22",
|
|
445
|
+
"'": "%27",
|
|
446
|
+
"<": "%3C",
|
|
447
|
+
">": "%3E"
|
|
448
|
+
};
|
|
449
|
+
function encodeForHtmlAttr(value) {
|
|
450
|
+
return value.replace(HTML_ATTR_UNSAFE_RE, (c) => HTML_ATTR_ENCODE_MAP[c]);
|
|
451
|
+
}
|
|
452
|
+
const navigateTo = (to, options) => {
|
|
453
|
+
to ||= "/";
|
|
454
|
+
const toPath = typeof to === "string" ? to : "path" in to ? resolveRouteObject(to) : useRouter().resolve(to).href;
|
|
455
|
+
const isExternalHost = hasProtocol(toPath, { acceptRelative: true });
|
|
456
|
+
const isExternal = options?.external || isExternalHost;
|
|
457
|
+
if (isExternal) {
|
|
458
|
+
if (!options?.external) {
|
|
459
|
+
throw new Error("Navigating to an external URL is not allowed by default. Use `navigateTo(url, { external: true })`.");
|
|
460
|
+
}
|
|
461
|
+
const { protocol } = new URL(toPath, "http://localhost");
|
|
462
|
+
if (protocol && isScriptProtocol(protocol)) {
|
|
463
|
+
throw new Error(`Cannot navigate to a URL with '${protocol}' protocol.`);
|
|
464
|
+
}
|
|
465
|
+
}
|
|
466
|
+
const inMiddleware = isProcessingMiddleware();
|
|
467
|
+
const router = useRouter();
|
|
468
|
+
const nuxtApp = useNuxtApp();
|
|
469
|
+
{
|
|
470
|
+
if (nuxtApp.ssrContext) {
|
|
471
|
+
const fullPath = typeof to === "string" || isExternal ? toPath : router.resolve(to).fullPath || "/";
|
|
472
|
+
const location2 = isExternal ? toPath : joinURL((/* @__PURE__ */ useRuntimeConfig()).app.baseURL, fullPath);
|
|
473
|
+
const redirect = async function(response) {
|
|
474
|
+
await nuxtApp.callHook("app:redirected");
|
|
475
|
+
const encodedHeader = encodeURL(location2, isExternalHost);
|
|
476
|
+
const encodedLoc = encodeForHtmlAttr(encodedHeader);
|
|
477
|
+
nuxtApp.ssrContext["~renderResponse"] = {
|
|
478
|
+
statusCode: sanitizeStatusCode(options?.redirectCode || 302, 302),
|
|
479
|
+
body: `<!DOCTYPE html><html><head><meta http-equiv="refresh" content="0; url=${encodedLoc}"></head></html>`,
|
|
480
|
+
headers: { location: encodedHeader }
|
|
481
|
+
};
|
|
482
|
+
return response;
|
|
483
|
+
};
|
|
484
|
+
if (!isExternal && inMiddleware) {
|
|
485
|
+
router.afterEach((final) => final.fullPath === fullPath ? redirect(false) : void 0);
|
|
486
|
+
return to;
|
|
487
|
+
}
|
|
488
|
+
return redirect(!inMiddleware ? void 0 : (
|
|
489
|
+
/* abort route navigation */
|
|
490
|
+
false
|
|
491
|
+
));
|
|
492
|
+
}
|
|
493
|
+
}
|
|
494
|
+
if (isExternal) {
|
|
495
|
+
nuxtApp._scope.stop();
|
|
496
|
+
if (options?.replace) {
|
|
497
|
+
(void 0).replace(toPath);
|
|
498
|
+
} else {
|
|
499
|
+
(void 0).href = toPath;
|
|
500
|
+
}
|
|
501
|
+
if (inMiddleware) {
|
|
502
|
+
if (!nuxtApp.isHydrating) {
|
|
503
|
+
return false;
|
|
504
|
+
}
|
|
505
|
+
return new Promise(() => {
|
|
506
|
+
});
|
|
507
|
+
}
|
|
508
|
+
return Promise.resolve();
|
|
509
|
+
}
|
|
510
|
+
const encodedTo = typeof to === "string" ? encodeRoutePath(to) : to;
|
|
511
|
+
return options?.replace ? router.replace(encodedTo) : router.push(encodedTo);
|
|
512
|
+
};
|
|
513
|
+
function resolveRouteObject(to) {
|
|
514
|
+
return withQuery(to.path || "", to.query || {}) + (to.hash || "");
|
|
515
|
+
}
|
|
516
|
+
function encodeURL(location2, isExternalHost = false) {
|
|
517
|
+
const url = new URL(location2, "http://localhost");
|
|
518
|
+
if (!isExternalHost) {
|
|
519
|
+
const pathname = url.pathname.replace(/^\/{2,}/, "/");
|
|
520
|
+
return pathname + url.search + url.hash;
|
|
521
|
+
}
|
|
522
|
+
if (location2.startsWith("//")) {
|
|
523
|
+
return url.toString().replace(url.protocol, "");
|
|
524
|
+
}
|
|
525
|
+
return url.toString();
|
|
526
|
+
}
|
|
527
|
+
function encodeRoutePath(url) {
|
|
528
|
+
const parsed = parseURL(url);
|
|
529
|
+
return encodePath(decodePath(parsed.pathname)) + parsed.search + parsed.hash;
|
|
530
|
+
}
|
|
531
|
+
const NUXT_ERROR_SIGNATURE = "__nuxt_error";
|
|
532
|
+
const useError = /* @__NO_SIDE_EFFECTS__ */ () => toRef(useNuxtApp().payload, "error");
|
|
533
|
+
const showError = (error) => {
|
|
534
|
+
const nuxtError = createError(error);
|
|
535
|
+
try {
|
|
536
|
+
const error2 = /* @__PURE__ */ useError();
|
|
537
|
+
if (false) ;
|
|
538
|
+
error2.value ||= nuxtError;
|
|
539
|
+
} catch {
|
|
540
|
+
throw nuxtError;
|
|
541
|
+
}
|
|
542
|
+
return nuxtError;
|
|
543
|
+
};
|
|
544
|
+
const isNuxtError = (error) => !!error && typeof error === "object" && NUXT_ERROR_SIGNATURE in error;
|
|
545
|
+
const createError = (error) => {
|
|
546
|
+
if (typeof error !== "string" && error.statusText) {
|
|
547
|
+
error.message ??= error.statusText;
|
|
548
|
+
}
|
|
549
|
+
const nuxtError = createError$1(error);
|
|
550
|
+
Object.defineProperty(nuxtError, NUXT_ERROR_SIGNATURE, {
|
|
551
|
+
value: true,
|
|
552
|
+
configurable: false,
|
|
553
|
+
writable: false
|
|
554
|
+
});
|
|
555
|
+
Object.defineProperty(nuxtError, "status", {
|
|
556
|
+
// eslint-disable-next-line @typescript-eslint/no-deprecated
|
|
557
|
+
get: () => nuxtError.statusCode,
|
|
558
|
+
configurable: true
|
|
559
|
+
});
|
|
560
|
+
Object.defineProperty(nuxtError, "statusText", {
|
|
561
|
+
// eslint-disable-next-line @typescript-eslint/no-deprecated
|
|
562
|
+
get: () => nuxtError.statusMessage,
|
|
563
|
+
configurable: true
|
|
564
|
+
});
|
|
565
|
+
return nuxtError;
|
|
566
|
+
};
|
|
567
|
+
function freezeHead(head) {
|
|
568
|
+
const realPush = head.push;
|
|
569
|
+
head.push = () => ({ dispose: () => {
|
|
570
|
+
}, patch: () => {
|
|
571
|
+
}, _poll: () => {
|
|
572
|
+
} });
|
|
573
|
+
return () => {
|
|
574
|
+
head.push = realPush;
|
|
575
|
+
};
|
|
576
|
+
}
|
|
577
|
+
const unhead_k2P3m_ZDyjlr2mMYnoDPwavjsDN8hBlk9cFai0bbopU = /* @__PURE__ */ defineNuxtPlugin({
|
|
578
|
+
name: "nuxt:head",
|
|
579
|
+
enforce: "pre",
|
|
580
|
+
setup(nuxtApp) {
|
|
581
|
+
const head = nuxtApp.ssrContext.head;
|
|
582
|
+
if (nuxtApp.ssrContext.islandContext) {
|
|
583
|
+
const unfreeze = freezeHead(head);
|
|
584
|
+
nuxtApp.hooks.hookOnce("app:created", unfreeze);
|
|
585
|
+
}
|
|
586
|
+
nuxtApp.vueApp.use(head);
|
|
587
|
+
}
|
|
588
|
+
});
|
|
589
|
+
function toArray(value) {
|
|
590
|
+
return Array.isArray(value) ? value : [value];
|
|
591
|
+
}
|
|
592
|
+
const matcher = (m, p) => {
|
|
593
|
+
return [];
|
|
594
|
+
};
|
|
595
|
+
const _routeRulesMatcher = (path) => defu({}, ...matcher("", typeof path === "string" ? path.toLowerCase() : path).map((r) => r.data).reverse());
|
|
596
|
+
const routeRulesMatcher = _routeRulesMatcher;
|
|
597
|
+
function getRouteRules(arg) {
|
|
598
|
+
const path = typeof arg === "string" ? arg : arg.path;
|
|
599
|
+
try {
|
|
600
|
+
return routeRulesMatcher(path.toLowerCase());
|
|
601
|
+
} catch (e) {
|
|
602
|
+
console.error("[nuxt] Error matching route rules.", e);
|
|
603
|
+
return {};
|
|
604
|
+
}
|
|
605
|
+
}
|
|
606
|
+
const _routes = [
|
|
607
|
+
{
|
|
608
|
+
name: "lessons-id",
|
|
609
|
+
path: "/lessons/:id()",
|
|
610
|
+
component: () => import('./_id_-CQaF66RF.mjs')
|
|
611
|
+
},
|
|
612
|
+
{
|
|
613
|
+
name: "lessons",
|
|
614
|
+
path: "/lessons",
|
|
615
|
+
component: () => import('./index-Dnk7jknb.mjs')
|
|
616
|
+
},
|
|
617
|
+
{
|
|
618
|
+
name: "index",
|
|
619
|
+
path: "/",
|
|
620
|
+
component: () => import('./index-C-zhU_b9.mjs')
|
|
621
|
+
}
|
|
622
|
+
];
|
|
623
|
+
const ROUTE_KEY_PARENTHESES_RE = /(:\w+)\([^)]+\)/g;
|
|
624
|
+
const ROUTE_KEY_SYMBOLS_RE = /(:\w+)[?+*]/g;
|
|
625
|
+
const ROUTE_KEY_NORMAL_RE = /:\w+/g;
|
|
626
|
+
function generateRouteKey(route) {
|
|
627
|
+
const source = route?.meta.key ?? route.path.replace(ROUTE_KEY_PARENTHESES_RE, "$1").replace(ROUTE_KEY_SYMBOLS_RE, "$1").replace(ROUTE_KEY_NORMAL_RE, (r) => route.params[r.slice(1)]?.toString() || "");
|
|
628
|
+
return typeof source === "function" ? source(route) : source;
|
|
629
|
+
}
|
|
630
|
+
function isChangingPage(to, from) {
|
|
631
|
+
if (to === from || from === START_LOCATION) {
|
|
632
|
+
return false;
|
|
633
|
+
}
|
|
634
|
+
if (generateRouteKey(to) !== generateRouteKey(from)) {
|
|
635
|
+
return true;
|
|
636
|
+
}
|
|
637
|
+
const areComponentsSame = to.matched.every(
|
|
638
|
+
(comp, index) => comp.components && comp.components.default === from.matched[index]?.components?.default
|
|
639
|
+
);
|
|
640
|
+
if (areComponentsSame) {
|
|
641
|
+
return false;
|
|
642
|
+
}
|
|
643
|
+
return true;
|
|
644
|
+
}
|
|
645
|
+
const routerOptions0 = {
|
|
646
|
+
scrollBehavior(to, from, savedPosition) {
|
|
647
|
+
const nuxtApp = useNuxtApp();
|
|
648
|
+
const hashScrollBehaviour = useRouter().options?.scrollBehaviorType ?? "auto";
|
|
649
|
+
if (to.path.replace(/\/$/, "") === from.path.replace(/\/$/, "")) {
|
|
650
|
+
if (from.hash && !to.hash) {
|
|
651
|
+
return { left: 0, top: 0 };
|
|
652
|
+
}
|
|
653
|
+
if (to.hash) {
|
|
654
|
+
return { el: to.hash, top: _getHashElementScrollMarginTop(to.hash), behavior: hashScrollBehaviour };
|
|
655
|
+
}
|
|
656
|
+
return false;
|
|
657
|
+
}
|
|
658
|
+
const routeAllowsScrollToTop = typeof to.meta.scrollToTop === "function" ? to.meta.scrollToTop(to, from) : to.meta.scrollToTop;
|
|
659
|
+
if (routeAllowsScrollToTop === false) {
|
|
660
|
+
return false;
|
|
661
|
+
}
|
|
662
|
+
if (from === START_LOCATION) {
|
|
663
|
+
return _calculatePosition(to, from, savedPosition, hashScrollBehaviour);
|
|
664
|
+
}
|
|
665
|
+
return new Promise((resolve) => {
|
|
666
|
+
const doScroll = () => {
|
|
667
|
+
requestAnimationFrame(() => resolve(_calculatePosition(to, from, savedPosition, hashScrollBehaviour)));
|
|
668
|
+
};
|
|
669
|
+
nuxtApp.hooks.hookOnce("page:loading:end", () => {
|
|
670
|
+
const transitionPromise = nuxtApp["~transitionPromise"];
|
|
671
|
+
if (transitionPromise) {
|
|
672
|
+
transitionPromise.then(doScroll);
|
|
673
|
+
} else {
|
|
674
|
+
doScroll();
|
|
675
|
+
}
|
|
676
|
+
});
|
|
677
|
+
});
|
|
678
|
+
}
|
|
679
|
+
};
|
|
680
|
+
function _getHashElementScrollMarginTop(selector) {
|
|
681
|
+
try {
|
|
682
|
+
const elem = (void 0).querySelector(selector);
|
|
683
|
+
if (elem) {
|
|
684
|
+
return (Number.parseFloat(getComputedStyle(elem).scrollMarginTop) || 0) + (Number.parseFloat(getComputedStyle((void 0).documentElement).scrollPaddingTop) || 0);
|
|
685
|
+
}
|
|
686
|
+
} catch {
|
|
687
|
+
}
|
|
688
|
+
return 0;
|
|
689
|
+
}
|
|
690
|
+
function _calculatePosition(to, from, savedPosition, defaultHashScrollBehaviour) {
|
|
691
|
+
if (savedPosition) {
|
|
692
|
+
return savedPosition;
|
|
693
|
+
}
|
|
694
|
+
if (to.hash) {
|
|
695
|
+
return {
|
|
696
|
+
el: to.hash,
|
|
697
|
+
top: _getHashElementScrollMarginTop(to.hash),
|
|
698
|
+
behavior: isChangingPage(to, from) ? defaultHashScrollBehaviour : "instant"
|
|
699
|
+
};
|
|
700
|
+
}
|
|
701
|
+
return {
|
|
702
|
+
left: 0,
|
|
703
|
+
top: 0
|
|
704
|
+
};
|
|
705
|
+
}
|
|
706
|
+
const configRouterOptions = {
|
|
707
|
+
hashMode: false,
|
|
708
|
+
scrollBehaviorType: "auto"
|
|
709
|
+
};
|
|
710
|
+
const routerOptions = {
|
|
711
|
+
...configRouterOptions,
|
|
712
|
+
...routerOptions0
|
|
713
|
+
};
|
|
714
|
+
const validate = /* @__PURE__ */ defineNuxtRouteMiddleware(async (to, from) => {
|
|
715
|
+
let __temp, __restore;
|
|
716
|
+
if (!to.meta?.validate) {
|
|
717
|
+
return;
|
|
718
|
+
}
|
|
719
|
+
const result = ([__temp, __restore] = executeAsync(() => Promise.resolve(to.meta.validate(to))), __temp = await __temp, __restore(), __temp);
|
|
720
|
+
if (result === true) {
|
|
721
|
+
return;
|
|
722
|
+
}
|
|
723
|
+
const error = createError({
|
|
724
|
+
fatal: false,
|
|
725
|
+
// eslint-disable-next-line @typescript-eslint/no-deprecated
|
|
726
|
+
status: result && (result.status || result.statusCode) || 404,
|
|
727
|
+
// eslint-disable-next-line @typescript-eslint/no-deprecated
|
|
728
|
+
statusText: result && (result.statusText || result.statusMessage) || `Page Not Found: ${to.fullPath}`,
|
|
729
|
+
data: {
|
|
730
|
+
path: to.fullPath
|
|
731
|
+
}
|
|
732
|
+
});
|
|
733
|
+
return error;
|
|
734
|
+
});
|
|
735
|
+
const manifest_45route_45rule = /* @__PURE__ */ defineNuxtRouteMiddleware((to) => {
|
|
736
|
+
{
|
|
737
|
+
return;
|
|
738
|
+
}
|
|
739
|
+
});
|
|
740
|
+
const globalMiddleware = [
|
|
741
|
+
validate,
|
|
742
|
+
manifest_45route_45rule
|
|
743
|
+
];
|
|
744
|
+
const namedMiddleware = {};
|
|
745
|
+
Object.assign(/* @__PURE__ */ Object.create(null), {});
|
|
746
|
+
const pageIslandRoutes = Object.assign(/* @__PURE__ */ Object.create(null), {});
|
|
747
|
+
const plugin = /* @__PURE__ */ defineNuxtPlugin({
|
|
748
|
+
name: "nuxt:router",
|
|
749
|
+
enforce: "pre",
|
|
750
|
+
async setup(nuxtApp) {
|
|
751
|
+
let __temp, __restore;
|
|
752
|
+
let routerBase = (/* @__PURE__ */ useRuntimeConfig()).app.baseURL;
|
|
753
|
+
const history = routerOptions.history?.(routerBase) ?? createMemoryHistory(routerBase);
|
|
754
|
+
const routes = routerOptions.routes ? ([__temp, __restore] = executeAsync(() => routerOptions.routes(_routes)), __temp = await __temp, __restore(), __temp) ?? _routes : _routes;
|
|
755
|
+
let startPosition;
|
|
756
|
+
const router = createRouter({
|
|
757
|
+
...routerOptions,
|
|
758
|
+
scrollBehavior: (to, from, savedPosition) => {
|
|
759
|
+
if (from === START_LOCATION) {
|
|
760
|
+
startPosition = savedPosition;
|
|
761
|
+
return;
|
|
762
|
+
}
|
|
763
|
+
if (routerOptions.scrollBehavior) {
|
|
764
|
+
router.options.scrollBehavior = routerOptions.scrollBehavior;
|
|
765
|
+
if ("scrollRestoration" in (void 0).history) {
|
|
766
|
+
const unsub = router.beforeEach(() => {
|
|
767
|
+
unsub();
|
|
768
|
+
(void 0).history.scrollRestoration = "manual";
|
|
769
|
+
});
|
|
770
|
+
}
|
|
771
|
+
return routerOptions.scrollBehavior(to, START_LOCATION, startPosition || savedPosition);
|
|
772
|
+
}
|
|
773
|
+
},
|
|
774
|
+
history,
|
|
775
|
+
routes
|
|
776
|
+
});
|
|
777
|
+
nuxtApp.vueApp.use(router);
|
|
778
|
+
const previousRoute = shallowRef(router.currentRoute.value);
|
|
779
|
+
router.afterEach((_to, from) => {
|
|
780
|
+
previousRoute.value = from;
|
|
781
|
+
});
|
|
782
|
+
Object.defineProperty(nuxtApp.vueApp.config.globalProperties, "previousRoute", {
|
|
783
|
+
get: () => previousRoute.value
|
|
784
|
+
});
|
|
785
|
+
const initialURL = nuxtApp.ssrContext.url;
|
|
786
|
+
const _route = shallowRef(router.currentRoute.value);
|
|
787
|
+
const syncCurrentRoute = () => {
|
|
788
|
+
_route.value = router.currentRoute.value;
|
|
789
|
+
};
|
|
790
|
+
router.afterEach((to, from) => {
|
|
791
|
+
const lastTo = to.matched.at(-1)?.components?.default;
|
|
792
|
+
const lastFrom = from.matched.at(-1)?.components?.default;
|
|
793
|
+
if (lastTo === lastFrom) {
|
|
794
|
+
syncCurrentRoute();
|
|
795
|
+
return;
|
|
796
|
+
}
|
|
797
|
+
if (to.matched.length < from.matched.length && to.matched.every((m, i) => m.components?.default === from.matched[i]?.components?.default)) {
|
|
798
|
+
syncCurrentRoute();
|
|
799
|
+
}
|
|
800
|
+
});
|
|
801
|
+
const route = { sync: syncCurrentRoute };
|
|
802
|
+
for (const key in _route.value) {
|
|
803
|
+
Object.defineProperty(route, key, {
|
|
804
|
+
get: () => _route.value[key],
|
|
805
|
+
enumerable: true
|
|
806
|
+
});
|
|
807
|
+
}
|
|
808
|
+
nuxtApp._route = shallowReactive(route);
|
|
809
|
+
nuxtApp._middleware ||= {
|
|
810
|
+
global: [],
|
|
811
|
+
named: {}
|
|
812
|
+
};
|
|
813
|
+
const error = /* @__PURE__ */ useError();
|
|
814
|
+
const isServerPage = nuxtApp.ssrContext?.islandContext?.name?.startsWith("page_");
|
|
815
|
+
if (!nuxtApp.ssrContext?.islandContext || isServerPage) {
|
|
816
|
+
router.afterEach(async (to, _from, failure) => {
|
|
817
|
+
delete nuxtApp._processingMiddleware;
|
|
818
|
+
if (failure) {
|
|
819
|
+
await nuxtApp.callHook("page:loading:end");
|
|
820
|
+
}
|
|
821
|
+
if (failure?.type === 4) {
|
|
822
|
+
return;
|
|
823
|
+
}
|
|
824
|
+
if (to.redirectedFrom && to.fullPath !== initialURL) {
|
|
825
|
+
await nuxtApp.runWithContext(() => navigateTo(to.fullPath || "/"));
|
|
826
|
+
}
|
|
827
|
+
});
|
|
828
|
+
}
|
|
829
|
+
try {
|
|
830
|
+
if (true) {
|
|
831
|
+
;
|
|
832
|
+
[__temp, __restore] = executeAsync(() => router.push(initialURL)), await __temp, __restore();
|
|
833
|
+
;
|
|
834
|
+
}
|
|
835
|
+
;
|
|
836
|
+
[__temp, __restore] = executeAsync(() => router.isReady()), await __temp, __restore();
|
|
837
|
+
;
|
|
838
|
+
} catch (error2) {
|
|
839
|
+
[__temp, __restore] = executeAsync(() => nuxtApp.runWithContext(() => showError(error2))), await __temp, __restore();
|
|
840
|
+
}
|
|
841
|
+
const resolvedInitialRoute = router.currentRoute.value;
|
|
842
|
+
const hasDeferredRoute = false;
|
|
843
|
+
syncCurrentRoute();
|
|
844
|
+
if (nuxtApp.ssrContext?.islandContext && !isServerPage) {
|
|
845
|
+
return { provide: { router } };
|
|
846
|
+
}
|
|
847
|
+
const initialLayout = nuxtApp.payload.state._layout;
|
|
848
|
+
router.beforeEach(async (to, from) => {
|
|
849
|
+
await nuxtApp.callHook("page:loading:start");
|
|
850
|
+
to.meta = reactive(to.meta);
|
|
851
|
+
if (nuxtApp.isHydrating && initialLayout && !isReadonly(to.meta.layout)) {
|
|
852
|
+
to.meta.layout = initialLayout;
|
|
853
|
+
}
|
|
854
|
+
nuxtApp._processingMiddleware = true;
|
|
855
|
+
if (!nuxtApp.ssrContext?.islandContext || isServerPage) {
|
|
856
|
+
const middlewareEntries = /* @__PURE__ */ new Set([...globalMiddleware, ...nuxtApp._middleware.global]);
|
|
857
|
+
for (const component of to.matched) {
|
|
858
|
+
const componentMiddleware = component.meta.middleware;
|
|
859
|
+
if (!componentMiddleware) {
|
|
860
|
+
continue;
|
|
861
|
+
}
|
|
862
|
+
for (const entry2 of toArray(componentMiddleware)) {
|
|
863
|
+
middlewareEntries.add(entry2);
|
|
864
|
+
}
|
|
865
|
+
}
|
|
866
|
+
const routeRules = getRouteRules({ path: to.path });
|
|
867
|
+
if (routeRules.appMiddleware) {
|
|
868
|
+
for (const key in routeRules.appMiddleware) {
|
|
869
|
+
if (routeRules.appMiddleware[key]) {
|
|
870
|
+
middlewareEntries.add(key);
|
|
871
|
+
} else {
|
|
872
|
+
middlewareEntries.delete(key);
|
|
873
|
+
}
|
|
874
|
+
}
|
|
875
|
+
}
|
|
876
|
+
for (const entry2 of middlewareEntries) {
|
|
877
|
+
const middleware = typeof entry2 === "string" ? nuxtApp._middleware.named[entry2] || await namedMiddleware[entry2]?.().then((r) => r.default || r) : entry2;
|
|
878
|
+
if (!middleware) {
|
|
879
|
+
throw new Error(`Unknown route middleware: '${entry2}'.`);
|
|
880
|
+
}
|
|
881
|
+
try {
|
|
882
|
+
if (false) ;
|
|
883
|
+
const result = await nuxtApp.runWithContext(() => middleware(to, from));
|
|
884
|
+
if (true) {
|
|
885
|
+
if (result === false || result instanceof Error) {
|
|
886
|
+
const error2 = result || createError({
|
|
887
|
+
status: 404,
|
|
888
|
+
statusText: `Page Not Found: ${initialURL}`
|
|
889
|
+
});
|
|
890
|
+
await nuxtApp.runWithContext(() => showError(error2));
|
|
891
|
+
return false;
|
|
892
|
+
}
|
|
893
|
+
}
|
|
894
|
+
if (result === true) {
|
|
895
|
+
continue;
|
|
896
|
+
}
|
|
897
|
+
if (result === false) {
|
|
898
|
+
return result;
|
|
899
|
+
}
|
|
900
|
+
if (result) {
|
|
901
|
+
if (isNuxtError(result) && result.fatal) {
|
|
902
|
+
await nuxtApp.runWithContext(() => showError(result));
|
|
903
|
+
}
|
|
904
|
+
return result;
|
|
905
|
+
}
|
|
906
|
+
} catch (err) {
|
|
907
|
+
const error2 = createError(err);
|
|
908
|
+
if (error2.fatal) {
|
|
909
|
+
await nuxtApp.runWithContext(() => showError(error2));
|
|
910
|
+
}
|
|
911
|
+
return error2;
|
|
912
|
+
}
|
|
913
|
+
}
|
|
914
|
+
}
|
|
915
|
+
});
|
|
916
|
+
if (isServerPage) {
|
|
917
|
+
router.beforeResolve((to) => {
|
|
918
|
+
const expected = pageIslandRoutes[nuxtApp.ssrContext.islandContext.name];
|
|
919
|
+
const actual = to.matched.find((m) => m.components?.default?.__nuxt_island)?.components?.default;
|
|
920
|
+
if (!expected || expected !== actual?.__nuxt_island) {
|
|
921
|
+
nuxtApp.ssrContext["~renderResponse"] = {
|
|
922
|
+
statusCode: 400,
|
|
923
|
+
statusMessage: "Invalid island request path"
|
|
924
|
+
};
|
|
925
|
+
return false;
|
|
926
|
+
}
|
|
927
|
+
});
|
|
928
|
+
}
|
|
929
|
+
router.onError(async () => {
|
|
930
|
+
delete nuxtApp._processingMiddleware;
|
|
931
|
+
await nuxtApp.callHook("page:loading:end");
|
|
932
|
+
});
|
|
933
|
+
router.afterEach((to) => {
|
|
934
|
+
if (to.matched.length === 0 && !error.value) {
|
|
935
|
+
return nuxtApp.runWithContext(() => showError(createError({
|
|
936
|
+
status: 404,
|
|
937
|
+
fatal: false,
|
|
938
|
+
statusText: `Page not found: ${to.fullPath}`,
|
|
939
|
+
data: {
|
|
940
|
+
path: to.fullPath
|
|
941
|
+
}
|
|
942
|
+
})));
|
|
943
|
+
}
|
|
944
|
+
});
|
|
945
|
+
nuxtApp.hooks.hookOnce("app:created", async () => {
|
|
946
|
+
try {
|
|
947
|
+
if ("name" in resolvedInitialRoute) {
|
|
948
|
+
resolvedInitialRoute.name = void 0;
|
|
949
|
+
}
|
|
950
|
+
if (hasDeferredRoute) ;
|
|
951
|
+
else {
|
|
952
|
+
await router.replace({
|
|
953
|
+
...resolvedInitialRoute,
|
|
954
|
+
force: true
|
|
955
|
+
});
|
|
956
|
+
}
|
|
957
|
+
router.options.scrollBehavior = routerOptions.scrollBehavior;
|
|
958
|
+
} catch (error2) {
|
|
959
|
+
await nuxtApp.runWithContext(() => showError(error2));
|
|
960
|
+
}
|
|
961
|
+
});
|
|
962
|
+
return { provide: { router } };
|
|
963
|
+
}
|
|
964
|
+
});
|
|
965
|
+
function definePayloadReducer(name, reduce) {
|
|
966
|
+
{
|
|
967
|
+
useNuxtApp().ssrContext["~payloadReducers"][name] = reduce;
|
|
968
|
+
}
|
|
969
|
+
}
|
|
970
|
+
const reducers = [
|
|
971
|
+
["NuxtError", (data) => isNuxtError(data) && data.toJSON()],
|
|
972
|
+
["EmptyShallowRef", (data) => isRef(data) && isShallow(data) && !data.value && (typeof data.value === "bigint" ? "0n" : JSON.stringify(data.value) || "_")],
|
|
973
|
+
["EmptyRef", (data) => isRef(data) && !data.value && (typeof data.value === "bigint" ? "0n" : JSON.stringify(data.value) || "_")],
|
|
974
|
+
["ShallowRef", (data) => isRef(data) && isShallow(data) && data.value],
|
|
975
|
+
["ShallowReactive", (data) => isReactive(data) && isShallow(data) && toRaw(data)],
|
|
976
|
+
["Ref", (data) => isRef(data) && data.value],
|
|
977
|
+
["Reactive", (data) => isReactive(data) && toRaw(data)]
|
|
978
|
+
];
|
|
979
|
+
const revive_payload_server_MVtmlZaQpj6ApFmshWfUWl5PehCebzaBf2NuRMiIbms = /* @__PURE__ */ defineNuxtPlugin({
|
|
980
|
+
name: "nuxt:revive-payload:server",
|
|
981
|
+
setup() {
|
|
982
|
+
for (const [reducer, fn] of reducers) {
|
|
983
|
+
definePayloadReducer(reducer, fn);
|
|
984
|
+
}
|
|
985
|
+
}
|
|
986
|
+
});
|
|
987
|
+
const components_plugin_4kY4pyzJIYX99vmMAAIorFf3CnAaptHitJgf7JxiED8 = /* @__PURE__ */ defineNuxtPlugin({
|
|
988
|
+
name: "nuxt:global-components"
|
|
989
|
+
});
|
|
990
|
+
const plugins = [
|
|
991
|
+
unhead_k2P3m_ZDyjlr2mMYnoDPwavjsDN8hBlk9cFai0bbopU,
|
|
992
|
+
plugin,
|
|
993
|
+
revive_payload_server_MVtmlZaQpj6ApFmshWfUWl5PehCebzaBf2NuRMiIbms,
|
|
994
|
+
components_plugin_4kY4pyzJIYX99vmMAAIorFf3CnAaptHitJgf7JxiED8
|
|
995
|
+
];
|
|
996
|
+
const firstNonUndefined = (...args) => args.find((arg) => arg !== void 0);
|
|
997
|
+
function sanitizeExternalHref(value) {
|
|
998
|
+
let candidate = value.replace(/[\u0000-\u001F\s]+/g, "");
|
|
999
|
+
while (candidate.toLowerCase().startsWith("view-source:")) {
|
|
1000
|
+
candidate = candidate.slice("view-source:".length);
|
|
1001
|
+
}
|
|
1002
|
+
const colon = candidate.indexOf(":");
|
|
1003
|
+
if (colon > 0 && isScriptProtocol(candidate.slice(0, colon + 1))) {
|
|
1004
|
+
return null;
|
|
1005
|
+
}
|
|
1006
|
+
return value;
|
|
1007
|
+
}
|
|
1008
|
+
// @__NO_SIDE_EFFECTS__
|
|
1009
|
+
function defineNuxtLink(options) {
|
|
1010
|
+
const componentName = options.componentName || "NuxtLink";
|
|
1011
|
+
function isHashLinkWithoutHashMode(link) {
|
|
1012
|
+
return typeof link === "string" && link.startsWith("#");
|
|
1013
|
+
}
|
|
1014
|
+
function resolveTrailingSlashBehavior(to, resolve, trailingSlash) {
|
|
1015
|
+
const effectiveTrailingSlash = trailingSlash ?? options.trailingSlash;
|
|
1016
|
+
if (!to || effectiveTrailingSlash !== "append" && effectiveTrailingSlash !== "remove") {
|
|
1017
|
+
return to;
|
|
1018
|
+
}
|
|
1019
|
+
if (typeof to === "string") {
|
|
1020
|
+
return applyTrailingSlashBehavior(to, effectiveTrailingSlash);
|
|
1021
|
+
}
|
|
1022
|
+
const path = "path" in to && to.path !== void 0 ? to.path : resolve(to).path;
|
|
1023
|
+
const resolvedPath = {
|
|
1024
|
+
...to,
|
|
1025
|
+
name: void 0,
|
|
1026
|
+
// named routes would otherwise always override trailing slash behavior
|
|
1027
|
+
path: applyTrailingSlashBehavior(path, effectiveTrailingSlash)
|
|
1028
|
+
};
|
|
1029
|
+
return resolvedPath;
|
|
1030
|
+
}
|
|
1031
|
+
function useNuxtLink(props) {
|
|
1032
|
+
const router = useRouter();
|
|
1033
|
+
const config = /* @__PURE__ */ useRuntimeConfig();
|
|
1034
|
+
const hasTarget = computed(() => !!unref(props.target) && unref(props.target) !== "_self");
|
|
1035
|
+
const isAbsoluteUrl = computed(() => {
|
|
1036
|
+
const path = unref(props.to) || unref(props.href) || "";
|
|
1037
|
+
return typeof path === "string" && hasProtocol(path, { acceptRelative: true });
|
|
1038
|
+
});
|
|
1039
|
+
const builtinRouterLink = resolveComponent("RouterLink");
|
|
1040
|
+
const useBuiltinLink = builtinRouterLink && typeof builtinRouterLink !== "string" ? builtinRouterLink.useLink : void 0;
|
|
1041
|
+
const isExternal = computed(() => {
|
|
1042
|
+
if (unref(props.external)) {
|
|
1043
|
+
return true;
|
|
1044
|
+
}
|
|
1045
|
+
const path = unref(props.to) || unref(props.href) || "";
|
|
1046
|
+
if (typeof path === "object") {
|
|
1047
|
+
return false;
|
|
1048
|
+
}
|
|
1049
|
+
return path === "" || isAbsoluteUrl.value;
|
|
1050
|
+
});
|
|
1051
|
+
const to = computed(() => {
|
|
1052
|
+
const path = unref(props.to) || unref(props.href) || "";
|
|
1053
|
+
if (isExternal.value) {
|
|
1054
|
+
return path;
|
|
1055
|
+
}
|
|
1056
|
+
return resolveTrailingSlashBehavior(path, router.resolve, unref(props.trailingSlash));
|
|
1057
|
+
});
|
|
1058
|
+
const link = isExternal.value ? void 0 : useBuiltinLink?.({ ...props, to, viewTransition: unref(props.viewTransition) });
|
|
1059
|
+
const href = computed(() => {
|
|
1060
|
+
const effectiveTrailingSlash = unref(props.trailingSlash) ?? options.trailingSlash;
|
|
1061
|
+
if (!to.value || isAbsoluteUrl.value || isHashLinkWithoutHashMode(to.value)) {
|
|
1062
|
+
const raw = to.value;
|
|
1063
|
+
return typeof raw === "string" ? sanitizeExternalHref(raw) : raw;
|
|
1064
|
+
}
|
|
1065
|
+
if (isExternal.value) {
|
|
1066
|
+
const path = typeof to.value === "object" && "path" in to.value ? resolveRouteObject(to.value) : to.value;
|
|
1067
|
+
const href2 = typeof path === "object" ? router.resolve(path).href : path;
|
|
1068
|
+
const safe = typeof href2 === "string" ? sanitizeExternalHref(href2) : href2;
|
|
1069
|
+
return safe === null ? null : applyTrailingSlashBehavior(safe, effectiveTrailingSlash);
|
|
1070
|
+
}
|
|
1071
|
+
if (typeof to.value === "object") {
|
|
1072
|
+
return router.resolve(to.value)?.href ?? null;
|
|
1073
|
+
}
|
|
1074
|
+
return applyTrailingSlashBehavior(joinURL(config.app.baseURL, to.value), effectiveTrailingSlash);
|
|
1075
|
+
});
|
|
1076
|
+
return {
|
|
1077
|
+
to,
|
|
1078
|
+
hasTarget,
|
|
1079
|
+
isAbsoluteUrl,
|
|
1080
|
+
isExternal,
|
|
1081
|
+
//
|
|
1082
|
+
href,
|
|
1083
|
+
isActive: link?.isActive ?? computed(() => to.value === router.currentRoute.value.path),
|
|
1084
|
+
isExactActive: link?.isExactActive ?? computed(() => to.value === router.currentRoute.value.path),
|
|
1085
|
+
route: link?.route ?? computed(() => router.resolve(to.value)),
|
|
1086
|
+
async navigate(_e) {
|
|
1087
|
+
if (href.value === null) {
|
|
1088
|
+
return;
|
|
1089
|
+
}
|
|
1090
|
+
await navigateTo(href.value, { replace: unref(props.replace), external: isExternal.value || hasTarget.value });
|
|
1091
|
+
}
|
|
1092
|
+
};
|
|
1093
|
+
}
|
|
1094
|
+
return defineComponent({
|
|
1095
|
+
name: componentName,
|
|
1096
|
+
props: {
|
|
1097
|
+
// Routing
|
|
1098
|
+
to: {
|
|
1099
|
+
type: [String, Object],
|
|
1100
|
+
default: void 0,
|
|
1101
|
+
required: false
|
|
1102
|
+
},
|
|
1103
|
+
href: {
|
|
1104
|
+
type: [String, Object],
|
|
1105
|
+
default: void 0,
|
|
1106
|
+
required: false
|
|
1107
|
+
},
|
|
1108
|
+
// Attributes
|
|
1109
|
+
target: {
|
|
1110
|
+
type: String,
|
|
1111
|
+
default: void 0,
|
|
1112
|
+
required: false
|
|
1113
|
+
},
|
|
1114
|
+
rel: {
|
|
1115
|
+
type: String,
|
|
1116
|
+
default: void 0,
|
|
1117
|
+
required: false
|
|
1118
|
+
},
|
|
1119
|
+
noRel: {
|
|
1120
|
+
type: Boolean,
|
|
1121
|
+
default: void 0,
|
|
1122
|
+
required: false
|
|
1123
|
+
},
|
|
1124
|
+
// Prefetching
|
|
1125
|
+
prefetch: {
|
|
1126
|
+
type: Boolean,
|
|
1127
|
+
default: void 0,
|
|
1128
|
+
required: false
|
|
1129
|
+
},
|
|
1130
|
+
prefetchOn: {
|
|
1131
|
+
type: [String, Object],
|
|
1132
|
+
default: void 0,
|
|
1133
|
+
required: false
|
|
1134
|
+
},
|
|
1135
|
+
noPrefetch: {
|
|
1136
|
+
type: Boolean,
|
|
1137
|
+
default: void 0,
|
|
1138
|
+
required: false
|
|
1139
|
+
},
|
|
1140
|
+
// Styling
|
|
1141
|
+
activeClass: {
|
|
1142
|
+
type: String,
|
|
1143
|
+
default: void 0,
|
|
1144
|
+
required: false
|
|
1145
|
+
},
|
|
1146
|
+
exactActiveClass: {
|
|
1147
|
+
type: String,
|
|
1148
|
+
default: void 0,
|
|
1149
|
+
required: false
|
|
1150
|
+
},
|
|
1151
|
+
prefetchedClass: {
|
|
1152
|
+
type: String,
|
|
1153
|
+
default: void 0,
|
|
1154
|
+
required: false
|
|
1155
|
+
},
|
|
1156
|
+
// Vue Router's `<RouterLink>` additional props
|
|
1157
|
+
replace: {
|
|
1158
|
+
type: Boolean,
|
|
1159
|
+
default: void 0,
|
|
1160
|
+
required: false
|
|
1161
|
+
},
|
|
1162
|
+
ariaCurrentValue: {
|
|
1163
|
+
type: String,
|
|
1164
|
+
default: void 0,
|
|
1165
|
+
required: false
|
|
1166
|
+
},
|
|
1167
|
+
// Edge cases handling
|
|
1168
|
+
external: {
|
|
1169
|
+
type: Boolean,
|
|
1170
|
+
default: void 0,
|
|
1171
|
+
required: false
|
|
1172
|
+
},
|
|
1173
|
+
// Slot API
|
|
1174
|
+
custom: {
|
|
1175
|
+
type: Boolean,
|
|
1176
|
+
default: void 0,
|
|
1177
|
+
required: false
|
|
1178
|
+
},
|
|
1179
|
+
// Behavior
|
|
1180
|
+
trailingSlash: {
|
|
1181
|
+
type: String,
|
|
1182
|
+
default: void 0,
|
|
1183
|
+
required: false
|
|
1184
|
+
}
|
|
1185
|
+
},
|
|
1186
|
+
useLink: useNuxtLink,
|
|
1187
|
+
setup(props, { slots }) {
|
|
1188
|
+
const router = useRouter();
|
|
1189
|
+
const { to, href, navigate, isExternal, hasTarget, isAbsoluteUrl } = useNuxtLink(props);
|
|
1190
|
+
shallowRef(false);
|
|
1191
|
+
const el = void 0;
|
|
1192
|
+
const elRef = void 0;
|
|
1193
|
+
async function prefetch(nuxtApp = useNuxtApp()) {
|
|
1194
|
+
{
|
|
1195
|
+
return;
|
|
1196
|
+
}
|
|
1197
|
+
}
|
|
1198
|
+
return () => {
|
|
1199
|
+
if (!isExternal.value && !hasTarget.value && !isHashLinkWithoutHashMode(to.value)) {
|
|
1200
|
+
const routerLinkProps = {
|
|
1201
|
+
ref: elRef,
|
|
1202
|
+
to: to.value,
|
|
1203
|
+
activeClass: props.activeClass || options.activeClass,
|
|
1204
|
+
exactActiveClass: props.exactActiveClass || options.exactActiveClass,
|
|
1205
|
+
replace: props.replace,
|
|
1206
|
+
ariaCurrentValue: props.ariaCurrentValue,
|
|
1207
|
+
custom: props.custom
|
|
1208
|
+
};
|
|
1209
|
+
if (!props.custom) {
|
|
1210
|
+
routerLinkProps.rel = props.rel || void 0;
|
|
1211
|
+
}
|
|
1212
|
+
return h(
|
|
1213
|
+
resolveComponent("RouterLink"),
|
|
1214
|
+
routerLinkProps,
|
|
1215
|
+
slots.default
|
|
1216
|
+
);
|
|
1217
|
+
}
|
|
1218
|
+
const target = props.target || null;
|
|
1219
|
+
const rel = firstNonUndefined(
|
|
1220
|
+
// converts `""` to `null` to prevent the attribute from being added as empty (`rel=""`)
|
|
1221
|
+
props.noRel ? "" : props.rel,
|
|
1222
|
+
options.externalRelAttribute,
|
|
1223
|
+
/*
|
|
1224
|
+
* A fallback rel of `noopener noreferrer` is applied for external links or links that open in a new tab.
|
|
1225
|
+
* This solves a reverse tabnapping security flaw in browsers pre-2021 as well as improving privacy.
|
|
1226
|
+
*/
|
|
1227
|
+
isAbsoluteUrl.value || hasTarget.value ? "noopener noreferrer" : ""
|
|
1228
|
+
) || null;
|
|
1229
|
+
if (props.custom) {
|
|
1230
|
+
if (!slots.default) {
|
|
1231
|
+
return null;
|
|
1232
|
+
}
|
|
1233
|
+
return slots.default({
|
|
1234
|
+
href: href.value,
|
|
1235
|
+
navigate,
|
|
1236
|
+
prefetch,
|
|
1237
|
+
get route() {
|
|
1238
|
+
if (!href.value) {
|
|
1239
|
+
return void 0;
|
|
1240
|
+
}
|
|
1241
|
+
const url = new URL(href.value, "http://localhost");
|
|
1242
|
+
return {
|
|
1243
|
+
path: url.pathname,
|
|
1244
|
+
fullPath: url.pathname,
|
|
1245
|
+
get query() {
|
|
1246
|
+
return parseQuery(url.search);
|
|
1247
|
+
},
|
|
1248
|
+
hash: url.hash,
|
|
1249
|
+
params: {},
|
|
1250
|
+
name: void 0,
|
|
1251
|
+
matched: [],
|
|
1252
|
+
redirectedFrom: void 0,
|
|
1253
|
+
meta: {},
|
|
1254
|
+
href: href.value
|
|
1255
|
+
};
|
|
1256
|
+
},
|
|
1257
|
+
rel,
|
|
1258
|
+
target,
|
|
1259
|
+
isExternal: isExternal.value || hasTarget.value,
|
|
1260
|
+
isActive: false,
|
|
1261
|
+
isExactActive: false
|
|
1262
|
+
});
|
|
1263
|
+
}
|
|
1264
|
+
return h("a", {
|
|
1265
|
+
ref: el,
|
|
1266
|
+
href: href.value || null,
|
|
1267
|
+
// converts `""` to `null` to prevent the attribute from being added as empty (`href=""`)
|
|
1268
|
+
rel,
|
|
1269
|
+
target,
|
|
1270
|
+
onClick: async (event) => {
|
|
1271
|
+
if (isExternal.value || hasTarget.value) {
|
|
1272
|
+
return;
|
|
1273
|
+
}
|
|
1274
|
+
event.preventDefault();
|
|
1275
|
+
try {
|
|
1276
|
+
const encodedHref = encodeRoutePath(href.value ?? "");
|
|
1277
|
+
return await (props.replace ? router.replace(encodedHref) : router.push(encodedHref));
|
|
1278
|
+
} finally {
|
|
1279
|
+
}
|
|
1280
|
+
}
|
|
1281
|
+
}, slots.default?.());
|
|
1282
|
+
};
|
|
1283
|
+
}
|
|
1284
|
+
});
|
|
1285
|
+
}
|
|
1286
|
+
const __nuxt_component_0 = /* @__PURE__ */ defineNuxtLink(nuxtLinkDefaults);
|
|
1287
|
+
function applyTrailingSlashBehavior(to, trailingSlash) {
|
|
1288
|
+
const normalizeFn = trailingSlash === "append" ? withTrailingSlash : withoutTrailingSlash;
|
|
1289
|
+
const hasProtocolDifferentFromHttp = hasProtocol(to) && !to.startsWith("http");
|
|
1290
|
+
if (hasProtocolDifferentFromHttp) {
|
|
1291
|
+
return to;
|
|
1292
|
+
}
|
|
1293
|
+
return normalizeFn(to, true);
|
|
1294
|
+
}
|
|
1295
|
+
const defineRouteProvider = (name = "RouteProvider") => defineComponent({
|
|
1296
|
+
name,
|
|
1297
|
+
props: {
|
|
1298
|
+
route: {
|
|
1299
|
+
type: Object,
|
|
1300
|
+
required: true
|
|
1301
|
+
},
|
|
1302
|
+
vnode: Object,
|
|
1303
|
+
vnodeRef: Object,
|
|
1304
|
+
renderKey: String,
|
|
1305
|
+
trackRootNodes: Boolean
|
|
1306
|
+
},
|
|
1307
|
+
setup(props) {
|
|
1308
|
+
const previousKey = props.renderKey;
|
|
1309
|
+
const previousRoute = props.route;
|
|
1310
|
+
const route = {};
|
|
1311
|
+
for (const key in props.route) {
|
|
1312
|
+
Object.defineProperty(route, key, {
|
|
1313
|
+
get: () => previousKey === props.renderKey ? props.route[key] : previousRoute[key],
|
|
1314
|
+
enumerable: true
|
|
1315
|
+
});
|
|
1316
|
+
}
|
|
1317
|
+
provide(PageRouteSymbol, shallowReactive(route));
|
|
1318
|
+
return () => {
|
|
1319
|
+
if (!props.vnode) {
|
|
1320
|
+
return props.vnode;
|
|
1321
|
+
}
|
|
1322
|
+
return h(props.vnode, { ref: props.vnodeRef });
|
|
1323
|
+
};
|
|
1324
|
+
}
|
|
1325
|
+
});
|
|
1326
|
+
const RouteProvider = defineRouteProvider();
|
|
1327
|
+
const __nuxt_component_1 = defineComponent({
|
|
1328
|
+
name: "NuxtPage",
|
|
1329
|
+
inheritAttrs: false,
|
|
1330
|
+
props: {
|
|
1331
|
+
name: {
|
|
1332
|
+
type: String
|
|
1333
|
+
},
|
|
1334
|
+
transition: {
|
|
1335
|
+
type: [Boolean, Object],
|
|
1336
|
+
default: void 0
|
|
1337
|
+
},
|
|
1338
|
+
keepalive: {
|
|
1339
|
+
type: [Boolean, Object],
|
|
1340
|
+
default: void 0
|
|
1341
|
+
},
|
|
1342
|
+
route: {
|
|
1343
|
+
type: Object
|
|
1344
|
+
},
|
|
1345
|
+
pageKey: {
|
|
1346
|
+
type: [Function, String],
|
|
1347
|
+
default: null
|
|
1348
|
+
}
|
|
1349
|
+
},
|
|
1350
|
+
setup(props, { attrs, slots, expose }) {
|
|
1351
|
+
const nuxtApp = useNuxtApp();
|
|
1352
|
+
const pageRef = ref();
|
|
1353
|
+
inject(PageRouteSymbol, null);
|
|
1354
|
+
expose({ pageRef });
|
|
1355
|
+
inject(LayoutMetaSymbol, null);
|
|
1356
|
+
nuxtApp.deferHydration();
|
|
1357
|
+
return () => {
|
|
1358
|
+
return h(RouterView, { name: props.name, route: props.route, ...attrs }, {
|
|
1359
|
+
default: (routeProps) => {
|
|
1360
|
+
return h(Suspense, { suspensible: true }, {
|
|
1361
|
+
default() {
|
|
1362
|
+
return h(RouteProvider, {
|
|
1363
|
+
vnode: slots.default ? normalizeSlot(slots.default, routeProps) : routeProps.Component,
|
|
1364
|
+
route: routeProps.route,
|
|
1365
|
+
vnodeRef: pageRef
|
|
1366
|
+
});
|
|
1367
|
+
}
|
|
1368
|
+
});
|
|
1369
|
+
}
|
|
1370
|
+
});
|
|
1371
|
+
};
|
|
1372
|
+
}
|
|
1373
|
+
});
|
|
1374
|
+
function normalizeSlot(slot, data) {
|
|
1375
|
+
const slotContent = slot(data);
|
|
1376
|
+
return slotContent.length === 1 ? h(slotContent[0]) : h(Fragment, void 0, slotContent);
|
|
1377
|
+
}
|
|
1378
|
+
const _export_sfc = (sfc, props) => {
|
|
1379
|
+
const target = sfc.__vccOpts || sfc;
|
|
1380
|
+
for (const [key, val] of props) {
|
|
1381
|
+
target[key] = val;
|
|
1382
|
+
}
|
|
1383
|
+
return target;
|
|
1384
|
+
};
|
|
1385
|
+
const _sfc_main$2 = {};
|
|
1386
|
+
function _sfc_ssrRender(_ctx, _push, _parent, _attrs) {
|
|
1387
|
+
const _component_NuxtLink = __nuxt_component_0;
|
|
1388
|
+
const _component_NuxtPage = __nuxt_component_1;
|
|
1389
|
+
_push(`<div${ssrRenderAttrs(_attrs)}><nav class="nav-bar"><div class="nav-inner">`);
|
|
1390
|
+
_push(ssrRenderComponent(_component_NuxtLink, {
|
|
1391
|
+
to: "/",
|
|
1392
|
+
class: "nav-logo"
|
|
1393
|
+
}, {
|
|
1394
|
+
default: withCtx((_, _push2, _parent2, _scopeId) => {
|
|
1395
|
+
if (_push2) {
|
|
1396
|
+
_push2(`<span class="logo-icon"${_scopeId}>🔮</span><span${_scopeId}>Athar</span><span class="logo-arabic"${_scopeId}>أثر</span>`);
|
|
1397
|
+
} else {
|
|
1398
|
+
return [
|
|
1399
|
+
createVNode("span", { class: "logo-icon" }, "🔮"),
|
|
1400
|
+
createVNode("span", null, "Athar"),
|
|
1401
|
+
createVNode("span", { class: "logo-arabic" }, "أثر")
|
|
1402
|
+
];
|
|
1403
|
+
}
|
|
1404
|
+
}),
|
|
1405
|
+
_: 1
|
|
1406
|
+
}, _parent));
|
|
1407
|
+
_push(`<ul class="nav-links"><li>`);
|
|
1408
|
+
_push(ssrRenderComponent(_component_NuxtLink, { to: "/" }, {
|
|
1409
|
+
default: withCtx((_, _push2, _parent2, _scopeId) => {
|
|
1410
|
+
if (_push2) {
|
|
1411
|
+
_push2(`📊 Dashboard`);
|
|
1412
|
+
} else {
|
|
1413
|
+
return [
|
|
1414
|
+
createTextVNode("📊 Dashboard")
|
|
1415
|
+
];
|
|
1416
|
+
}
|
|
1417
|
+
}),
|
|
1418
|
+
_: 1
|
|
1419
|
+
}, _parent));
|
|
1420
|
+
_push(`</li><li>`);
|
|
1421
|
+
_push(ssrRenderComponent(_component_NuxtLink, { to: "/lessons" }, {
|
|
1422
|
+
default: withCtx((_, _push2, _parent2, _scopeId) => {
|
|
1423
|
+
if (_push2) {
|
|
1424
|
+
_push2(`📚 Lessons`);
|
|
1425
|
+
} else {
|
|
1426
|
+
return [
|
|
1427
|
+
createTextVNode("📚 Lessons")
|
|
1428
|
+
];
|
|
1429
|
+
}
|
|
1430
|
+
}),
|
|
1431
|
+
_: 1
|
|
1432
|
+
}, _parent));
|
|
1433
|
+
_push(`</li></ul></div></nav><main class="app-container">`);
|
|
1434
|
+
_push(ssrRenderComponent(_component_NuxtPage, null, null, _parent));
|
|
1435
|
+
_push(`</main></div>`);
|
|
1436
|
+
}
|
|
1437
|
+
const _sfc_setup$2 = _sfc_main$2.setup;
|
|
1438
|
+
_sfc_main$2.setup = (props, ctx) => {
|
|
1439
|
+
const ssrContext = useSSRContext();
|
|
1440
|
+
(ssrContext.modules || (ssrContext.modules = /* @__PURE__ */ new Set())).add("app.vue");
|
|
1441
|
+
return _sfc_setup$2 ? _sfc_setup$2(props, ctx) : void 0;
|
|
1442
|
+
};
|
|
1443
|
+
const AppComponent = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["ssrRender", _sfc_ssrRender]]);
|
|
1444
|
+
const _sfc_main$1 = {
|
|
1445
|
+
__name: "nuxt-error-page",
|
|
1446
|
+
__ssrInlineRender: true,
|
|
1447
|
+
props: {
|
|
1448
|
+
error: Object
|
|
1449
|
+
},
|
|
1450
|
+
setup(__props) {
|
|
1451
|
+
const props = __props;
|
|
1452
|
+
const _error = props.error;
|
|
1453
|
+
const status = Number(_error.statusCode || 500);
|
|
1454
|
+
const is404 = status === 404;
|
|
1455
|
+
const statusText = _error.statusMessage ?? (is404 ? "Page Not Found" : "Internal Server Error");
|
|
1456
|
+
const description = _error.message || _error.toString();
|
|
1457
|
+
const stack = void 0;
|
|
1458
|
+
const _Error404 = defineAsyncComponent(() => import('./error-404-D0Xi6cQ6.mjs'));
|
|
1459
|
+
const _Error = defineAsyncComponent(() => import('./error-500-DabQpmqy.mjs'));
|
|
1460
|
+
const ErrorTemplate = is404 ? _Error404 : _Error;
|
|
1461
|
+
return (_ctx, _push, _parent, _attrs) => {
|
|
1462
|
+
_push(ssrRenderComponent(unref(ErrorTemplate), mergeProps({ status: unref(status), statusText: unref(statusText), statusCode: unref(status), statusMessage: unref(statusText), description: unref(description), stack: unref(stack) }, _attrs), null, _parent));
|
|
1463
|
+
};
|
|
1464
|
+
}
|
|
1465
|
+
};
|
|
1466
|
+
const _sfc_setup$1 = _sfc_main$1.setup;
|
|
1467
|
+
_sfc_main$1.setup = (props, ctx) => {
|
|
1468
|
+
const ssrContext = useSSRContext();
|
|
1469
|
+
(ssrContext.modules || (ssrContext.modules = /* @__PURE__ */ new Set())).add("../node_modules/nuxt/dist/app/components/nuxt-error-page.vue");
|
|
1470
|
+
return _sfc_setup$1 ? _sfc_setup$1(props, ctx) : void 0;
|
|
1471
|
+
};
|
|
1472
|
+
const _sfc_main = {
|
|
1473
|
+
__name: "nuxt-root",
|
|
1474
|
+
__ssrInlineRender: true,
|
|
1475
|
+
setup(__props) {
|
|
1476
|
+
const IslandRenderer = () => null;
|
|
1477
|
+
const nuxtApp = useNuxtApp();
|
|
1478
|
+
nuxtApp.deferHydration();
|
|
1479
|
+
nuxtApp.ssrContext.url;
|
|
1480
|
+
const SingleRenderer = false;
|
|
1481
|
+
provide(PageRouteSymbol, useRoute());
|
|
1482
|
+
nuxtApp.hooks.callHookWith((hooks) => hooks.map((hook) => hook()), "vue:setup", []);
|
|
1483
|
+
const error = /* @__PURE__ */ useError();
|
|
1484
|
+
const abortRender = error.value && !nuxtApp.ssrContext.error;
|
|
1485
|
+
function invokeAppErrorHandler(err, target, info) {
|
|
1486
|
+
const errorHandler = nuxtApp.vueApp.config.errorHandler;
|
|
1487
|
+
if (errorHandler && !errorHandler.__nuxt_default) {
|
|
1488
|
+
try {
|
|
1489
|
+
errorHandler(err, target, info);
|
|
1490
|
+
} catch (handlerError) {
|
|
1491
|
+
console.error("[nuxt] Error in `app.config.errorHandler`", handlerError);
|
|
1492
|
+
}
|
|
1493
|
+
}
|
|
1494
|
+
}
|
|
1495
|
+
onErrorCaptured((err, target, info) => {
|
|
1496
|
+
nuxtApp.hooks.callHook("vue:error", err, target, info)?.catch((hookError) => console.error("[nuxt] Error in `vue:error` hook", hookError));
|
|
1497
|
+
{
|
|
1498
|
+
const p = nuxtApp.runWithContext(() => showError(err));
|
|
1499
|
+
onServerPrefetch(() => p);
|
|
1500
|
+
invokeAppErrorHandler(err, target, info);
|
|
1501
|
+
return false;
|
|
1502
|
+
}
|
|
1503
|
+
});
|
|
1504
|
+
const islandContext = nuxtApp.ssrContext.islandContext;
|
|
1505
|
+
return (_ctx, _push, _parent, _attrs) => {
|
|
1506
|
+
ssrRenderSuspense(_push, {
|
|
1507
|
+
default: () => {
|
|
1508
|
+
if (unref(abortRender)) {
|
|
1509
|
+
_push(`<div></div>`);
|
|
1510
|
+
} else if (unref(error)) {
|
|
1511
|
+
_push(ssrRenderComponent(unref(_sfc_main$1), { error: unref(error) }, null, _parent));
|
|
1512
|
+
} else if (unref(islandContext)) {
|
|
1513
|
+
_push(ssrRenderComponent(unref(IslandRenderer), { context: unref(islandContext) }, null, _parent));
|
|
1514
|
+
} else if (unref(SingleRenderer)) {
|
|
1515
|
+
ssrRenderVNode(_push, createVNode(resolveDynamicComponent(unref(SingleRenderer)), null, null), _parent);
|
|
1516
|
+
} else {
|
|
1517
|
+
_push(ssrRenderComponent(unref(AppComponent), null, null, _parent));
|
|
1518
|
+
}
|
|
1519
|
+
},
|
|
1520
|
+
_: 1
|
|
1521
|
+
});
|
|
1522
|
+
};
|
|
1523
|
+
}
|
|
1524
|
+
};
|
|
1525
|
+
const _sfc_setup = _sfc_main.setup;
|
|
1526
|
+
_sfc_main.setup = (props, ctx) => {
|
|
1527
|
+
const ssrContext = useSSRContext();
|
|
1528
|
+
(ssrContext.modules || (ssrContext.modules = /* @__PURE__ */ new Set())).add("../node_modules/nuxt/dist/app/components/nuxt-root.vue");
|
|
1529
|
+
return _sfc_setup ? _sfc_setup(props, ctx) : void 0;
|
|
1530
|
+
};
|
|
1531
|
+
let entry;
|
|
1532
|
+
{
|
|
1533
|
+
entry = async function createNuxtAppServer(ssrContext) {
|
|
1534
|
+
const vueApp = createApp(_sfc_main);
|
|
1535
|
+
const nuxt = createNuxtApp({ vueApp, ssrContext });
|
|
1536
|
+
try {
|
|
1537
|
+
await applyPlugins(nuxt, plugins);
|
|
1538
|
+
await nuxt.hooks.callHook("app:created", vueApp);
|
|
1539
|
+
} catch (error) {
|
|
1540
|
+
await nuxt.hooks.callHook("app:error", error);
|
|
1541
|
+
nuxt.payload.error ||= createError(error);
|
|
1542
|
+
}
|
|
1543
|
+
if (ssrContext && (ssrContext["~renderResponse"] || ssrContext._renderResponse)) {
|
|
1544
|
+
throw new Error("skipping render");
|
|
1545
|
+
}
|
|
1546
|
+
return vueApp;
|
|
1547
|
+
};
|
|
1548
|
+
}
|
|
1549
|
+
const entry_default = ((ssrContext) => entry(ssrContext));
|
|
1550
|
+
|
|
1551
|
+
export { _export_sfc as _, __nuxt_component_0 as a, useRoute as b, asyncDataDefaults as c, createError as d, entry_default as default, fetchDefaults as f, useNuxtApp as u };
|
|
1552
|
+
//# sourceMappingURL=server.mjs.map
|