@elgap/edukaai 0.1.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/.output/nitro.json +15 -0
- package/.output/public/_nuxt/BHDzAs85.js +1 -0
- package/.output/public/_nuxt/BJzbfdL_.js +1 -0
- package/.output/public/_nuxt/BKGLlKXk.js +6 -0
- package/.output/public/_nuxt/BLuXzJk3.js +1 -0
- package/.output/public/_nuxt/BNOzzLI3.js +1 -0
- package/.output/public/_nuxt/BO5GMwXh.js +1 -0
- package/.output/public/_nuxt/BQRbsFGy.js +1 -0
- package/.output/public/_nuxt/Be4MVdOg.js +1 -0
- package/.output/public/_nuxt/Bu4d3Z1T.js +1 -0
- package/.output/public/_nuxt/BwpBBNv4.js +1 -0
- package/.output/public/_nuxt/C1Og9-6n.js +97 -0
- package/.output/public/_nuxt/C3CjAhtj.js +1 -0
- package/.output/public/_nuxt/C6E3Ty3z.js +1 -0
- package/.output/public/_nuxt/COct4B42.js +1 -0
- package/.output/public/_nuxt/CQ6g2dtj.js +1 -0
- package/.output/public/_nuxt/CURSW5TV.js +246 -0
- package/.output/public/_nuxt/CW57JW4s.js +1 -0
- package/.output/public/_nuxt/Cg2fM61o.js +18 -0
- package/.output/public/_nuxt/CgGOeWta.js +1 -0
- package/.output/public/_nuxt/CoyYbT7u.js +1 -0
- package/.output/public/_nuxt/D11MHbGc.js +133 -0
- package/.output/public/_nuxt/D24dz0S8.js +1 -0
- package/.output/public/_nuxt/D3EFPr8x.js +1 -0
- package/.output/public/_nuxt/Dvt4ZHil.js +1 -0
- package/.output/public/_nuxt/builds/latest.json +1 -0
- package/.output/public/_nuxt/builds/meta/ab87ba0e-6d0d-4466-8b12-00d44f8fb9d3.json +1 -0
- package/.output/public/_nuxt/default.C1K1-g4D.css +1 -0
- package/.output/public/_nuxt/entry.CH8k-Mga.css +1 -0
- package/.output/public/_nuxt/error-404.C-Ezrlz-.css +1 -0
- package/.output/public/_nuxt/error-500.DBWf9FGj.css +1 -0
- package/.output/public/_nuxt/first-training.wFDD65zm.css +1 -0
- package/.output/public/_nuxt/import.cUKYdCrq.css +1 -0
- package/.output/public/_nuxt/index.D-2VHyHA.css +1 -0
- package/.output/public/_nuxt/index.D4J_vHmL.css +1 -0
- package/.output/public/_nuxt/mPJeLIz7.js +1 -0
- package/.output/server/chunks/_/error-500.mjs +19 -0
- package/.output/server/chunks/_/error-500.mjs.map +1 -0
- package/.output/server/chunks/build/ExampleCard-styles.BUOJhEg0.mjs +8 -0
- package/.output/server/chunks/build/ExampleCard-styles.BUOJhEg0.mjs.map +1 -0
- package/.output/server/chunks/build/ExampleForm-Bcpl0CfL.mjs +238 -0
- package/.output/server/chunks/build/ExampleForm-Bcpl0CfL.mjs.map +1 -0
- package/.output/server/chunks/build/ImportPreview-styles.CFmMl5Ok.mjs +8 -0
- package/.output/server/chunks/build/ImportPreview-styles.CFmMl5Ok.mjs.map +1 -0
- package/.output/server/chunks/build/_id_-BUSGcL-H.mjs +113 -0
- package/.output/server/chunks/build/_id_-BUSGcL-H.mjs.map +1 -0
- package/.output/server/chunks/build/axolotl-C-EXGgM8.mjs +112 -0
- package/.output/server/chunks/build/axolotl-C-EXGgM8.mjs.map +1 -0
- package/.output/server/chunks/build/best-practices-DsadorHb.mjs +38 -0
- package/.output/server/chunks/build/best-practices-DsadorHb.mjs.map +1 -0
- package/.output/server/chunks/build/client.precomputed.mjs +4 -0
- package/.output/server/chunks/build/client.precomputed.mjs.map +1 -0
- package/.output/server/chunks/build/default-DPkqqHOE.mjs +354 -0
- package/.output/server/chunks/build/default-DPkqqHOE.mjs.map +1 -0
- package/.output/server/chunks/build/default-styles.DsqVVS7k.mjs +8 -0
- package/.output/server/chunks/build/default-styles.DsqVVS7k.mjs.map +1 -0
- package/.output/server/chunks/build/error-404-K4UfZNck.mjs +97 -0
- package/.output/server/chunks/build/error-404-K4UfZNck.mjs.map +1 -0
- package/.output/server/chunks/build/error-404-styles.DuDrf-v0.mjs +8 -0
- package/.output/server/chunks/build/error-404-styles.DuDrf-v0.mjs.map +1 -0
- package/.output/server/chunks/build/error-500-CA7TEPNg.mjs +79 -0
- package/.output/server/chunks/build/error-500-CA7TEPNg.mjs.map +1 -0
- package/.output/server/chunks/build/error-500-styles.8IYEHzz6.mjs +8 -0
- package/.output/server/chunks/build/error-500-styles.8IYEHzz6.mjs.map +1 -0
- package/.output/server/chunks/build/examples-BHK8MDrs.mjs +134 -0
- package/.output/server/chunks/build/examples-BHK8MDrs.mjs.map +1 -0
- package/.output/server/chunks/build/export-BzxFqqfP.mjs +233 -0
- package/.output/server/chunks/build/export-BzxFqqfP.mjs.map +1 -0
- package/.output/server/chunks/build/faq-DKch73dS.mjs +112 -0
- package/.output/server/chunks/build/faq-DKch73dS.mjs.map +1 -0
- package/.output/server/chunks/build/field-guide-qbukT8F0.mjs +38 -0
- package/.output/server/chunks/build/field-guide-qbukT8F0.mjs.map +1 -0
- package/.output/server/chunks/build/first-training-BbEOBcEW.mjs +343 -0
- package/.output/server/chunks/build/first-training-BbEOBcEW.mjs.map +1 -0
- package/.output/server/chunks/build/first-training-styles.BzOa_KRD.mjs +8 -0
- package/.output/server/chunks/build/first-training-styles.BzOa_KRD.mjs.map +1 -0
- package/.output/server/chunks/build/glossary-CxSGCJoH.mjs +397 -0
- package/.output/server/chunks/build/glossary-CxSGCJoH.mjs.map +1 -0
- package/.output/server/chunks/build/huggingface-TSmyUzZU.mjs +128 -0
- package/.output/server/chunks/build/huggingface-TSmyUzZU.mjs.map +1 -0
- package/.output/server/chunks/build/import-C0kYhRv9.mjs +247 -0
- package/.output/server/chunks/build/import-C0kYhRv9.mjs.map +1 -0
- package/.output/server/chunks/build/index-C1ntBEWd.mjs +235 -0
- package/.output/server/chunks/build/index-C1ntBEWd.mjs.map +1 -0
- package/.output/server/chunks/build/index-D3CxihcX.mjs +320 -0
- package/.output/server/chunks/build/index-D3CxihcX.mjs.map +1 -0
- package/.output/server/chunks/build/index-DgKa1cy0.mjs +360 -0
- package/.output/server/chunks/build/index-DgKa1cy0.mjs.map +1 -0
- package/.output/server/chunks/build/index-cG54gaKX.mjs +513 -0
- package/.output/server/chunks/build/index-cG54gaKX.mjs.map +1 -0
- package/.output/server/chunks/build/index-styles.BX2SZiiS.mjs +8 -0
- package/.output/server/chunks/build/index-styles.BX2SZiiS.mjs.map +1 -0
- package/.output/server/chunks/build/llm-training-DIqc0eiM.mjs +91 -0
- package/.output/server/chunks/build/llm-training-DIqc0eiM.mjs.map +1 -0
- package/.output/server/chunks/build/new-b3338aLF.mjs +92 -0
- package/.output/server/chunks/build/new-b3338aLF.mjs.map +1 -0
- package/.output/server/chunks/build/nuxt-link-Ceyd90PQ.mjs +290 -0
- package/.output/server/chunks/build/nuxt-link-Ceyd90PQ.mjs.map +1 -0
- package/.output/server/chunks/build/sample-datasets-CVLWMQUA.mjs +45 -0
- package/.output/server/chunks/build/sample-datasets-CVLWMQUA.mjs.map +1 -0
- package/.output/server/chunks/build/server.mjs +1979 -0
- package/.output/server/chunks/build/server.mjs.map +1 -0
- package/.output/server/chunks/build/styles.mjs +20 -0
- package/.output/server/chunks/build/styles.mjs.map +1 -0
- package/.output/server/chunks/build/test-router-BYM6Cpst.mjs +105 -0
- package/.output/server/chunks/build/test-router-BYM6Cpst.mjs.map +1 -0
- package/.output/server/chunks/nitro/nitro.mjs +5800 -0
- package/.output/server/chunks/nitro/nitro.mjs.map +1 -0
- package/.output/server/chunks/routes/renderer.mjs +481 -0
- package/.output/server/chunks/routes/renderer.mjs.map +1 -0
- package/.output/server/chunks/virtual/_virtual_spa-template.mjs +4 -0
- package/.output/server/chunks/virtual/_virtual_spa-template.mjs.map +1 -0
- package/.output/server/index.mjs +12 -0
- package/.output/server/index.mjs.map +1 -0
- package/.output/server/node_modules/.nitro/@vue/devtools-api@6.6.4/lib/cjs/api/api.js +2 -0
- package/.output/server/node_modules/.nitro/@vue/devtools-api@6.6.4/lib/cjs/api/app.js +2 -0
- package/.output/server/node_modules/.nitro/@vue/devtools-api@6.6.4/lib/cjs/api/component.js +2 -0
- package/.output/server/node_modules/.nitro/@vue/devtools-api@6.6.4/lib/cjs/api/context.js +2 -0
- package/.output/server/node_modules/.nitro/@vue/devtools-api@6.6.4/lib/cjs/api/hooks.js +2 -0
- package/.output/server/node_modules/.nitro/@vue/devtools-api@6.6.4/lib/cjs/api/index.js +22 -0
- package/.output/server/node_modules/.nitro/@vue/devtools-api@6.6.4/lib/cjs/api/util.js +2 -0
- package/.output/server/node_modules/.nitro/@vue/devtools-api@6.6.4/lib/cjs/const.js +5 -0
- package/.output/server/node_modules/.nitro/@vue/devtools-api@6.6.4/lib/cjs/env.js +17 -0
- package/.output/server/node_modules/.nitro/@vue/devtools-api@6.6.4/lib/cjs/index.js +45 -0
- package/.output/server/node_modules/.nitro/@vue/devtools-api@6.6.4/lib/cjs/plugin.js +2 -0
- package/.output/server/node_modules/.nitro/@vue/devtools-api@6.6.4/lib/cjs/proxy.js +111 -0
- package/.output/server/node_modules/.nitro/@vue/devtools-api@6.6.4/lib/cjs/time.js +28 -0
- package/.output/server/node_modules/.nitro/@vue/devtools-api@6.6.4/package.json +37 -0
- package/.output/server/node_modules/.nitro/@vue/devtools-api@7.7.9/dist/index.cjs +42 -0
- package/.output/server/node_modules/.nitro/@vue/devtools-api@7.7.9/package.json +32 -0
- package/.output/server/node_modules/.nitro/hookable@5.5.3/dist/index.cjs +299 -0
- package/.output/server/node_modules/.nitro/hookable@5.5.3/package.json +49 -0
- package/.output/server/node_modules/.nitro/hookable@6.0.1/dist/index.mjs +266 -0
- package/.output/server/node_modules/.nitro/hookable@6.0.1/package.json +52 -0
- package/.output/server/node_modules/.nitro/perfect-debounce@1.0.0/dist/index.cjs +59 -0
- package/.output/server/node_modules/.nitro/perfect-debounce@1.0.0/package.json +44 -0
- package/.output/server/node_modules/.nitro/perfect-debounce@2.1.0/dist/index.mjs +89 -0
- package/.output/server/node_modules/.nitro/perfect-debounce@2.1.0/package.json +41 -0
- package/.output/server/node_modules/@babel/parser/lib/index.js +14582 -0
- package/.output/server/node_modules/@babel/parser/package.json +50 -0
- package/.output/server/node_modules/@iconify/utils/lib/colors/index.js +292 -0
- package/.output/server/node_modules/@iconify/utils/lib/colors/keywords.js +702 -0
- package/.output/server/node_modules/@iconify/utils/lib/css/common.js +76 -0
- package/.output/server/node_modules/@iconify/utils/lib/css/format.js +40 -0
- package/.output/server/node_modules/@iconify/utils/lib/css/icon.js +52 -0
- package/.output/server/node_modules/@iconify/utils/lib/css/icons.js +133 -0
- package/.output/server/node_modules/@iconify/utils/lib/customisations/bool.js +20 -0
- package/.output/server/node_modules/@iconify/utils/lib/customisations/defaults.js +15 -0
- package/.output/server/node_modules/@iconify/utils/lib/customisations/flip.js +18 -0
- package/.output/server/node_modules/@iconify/utils/lib/customisations/merge.js +18 -0
- package/.output/server/node_modules/@iconify/utils/lib/customisations/rotate.js +31 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/cleanup.js +80 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/convert.js +102 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/data.js +29 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/format.js +60 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/parse.js +50 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/regex/base.js +204 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/regex/create.js +35 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/regex/numbers.js +134 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/regex/similar.js +167 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/regex/tree.js +81 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/replace/find.js +94 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/replace/replace.js +28 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/test/components.js +78 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/test/missing.js +68 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/test/name.js +47 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/test/parse.js +105 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/test/similar.js +38 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/test/tree.js +94 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/test/variations.js +64 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon/defaults.js +26 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon/merge.js +18 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon/name.js +58 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon/square.js +34 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon/transformations.js +13 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon-set/convert-info.js +126 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon-set/expand.js +21 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon-set/get-icon.js +27 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon-set/get-icons.js +38 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon-set/minify.js +93 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon-set/parse.js +48 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon-set/tree.js +24 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon-set/validate-basic.js +44 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon-set/validate.js +125 -0
- package/.output/server/node_modules/@iconify/utils/lib/index.js +53 -0
- package/.output/server/node_modules/@iconify/utils/lib/loader/custom.js +32 -0
- package/.output/server/node_modules/@iconify/utils/lib/loader/loader.js +28 -0
- package/.output/server/node_modules/@iconify/utils/lib/loader/modern.js +42 -0
- package/.output/server/node_modules/@iconify/utils/lib/loader/utils.js +63 -0
- package/.output/server/node_modules/@iconify/utils/lib/misc/objects.js +27 -0
- package/.output/server/node_modules/@iconify/utils/lib/misc/strings.js +27 -0
- package/.output/server/node_modules/@iconify/utils/lib/misc/title.js +10 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/build.js +115 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/defs.js +32 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/encode-svg-for-css.js +15 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/html.js +10 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/id.js +42 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/inner-html.js +23 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/parse.js +69 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/pretty.js +55 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/size.js +28 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/trim.js +8 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/url.js +23 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/viewbox.js +9 -0
- package/.output/server/node_modules/@iconify/utils/package.json +118 -0
- package/.output/server/node_modules/@iconify/vue/dist/iconify.mjs +1893 -0
- package/.output/server/node_modules/@iconify/vue/package.json +64 -0
- package/.output/server/node_modules/@vue/compiler-core/dist/compiler-core.cjs.prod.js +6763 -0
- package/.output/server/node_modules/@vue/compiler-core/package.json +58 -0
- package/.output/server/node_modules/@vue/compiler-dom/dist/compiler-dom.cjs.prod.js +689 -0
- package/.output/server/node_modules/@vue/compiler-dom/package.json +57 -0
- package/.output/server/node_modules/@vue/compiler-ssr/dist/compiler-ssr.cjs.js +1413 -0
- package/.output/server/node_modules/@vue/compiler-ssr/package.json +34 -0
- package/.output/server/node_modules/@vue/devtools-kit/dist/index.cjs +6850 -0
- package/.output/server/node_modules/@vue/devtools-kit/package.json +44 -0
- package/.output/server/node_modules/@vue/devtools-shared/dist/index.cjs +378 -0
- package/.output/server/node_modules/@vue/devtools-shared/package.json +34 -0
- package/.output/server/node_modules/@vue/reactivity/dist/reactivity.cjs.prod.js +1870 -0
- package/.output/server/node_modules/@vue/reactivity/package.json +55 -0
- package/.output/server/node_modules/@vue/runtime-core/dist/runtime-core.cjs.prod.js +6810 -0
- package/.output/server/node_modules/@vue/runtime-core/package.json +52 -0
- package/.output/server/node_modules/@vue/runtime-dom/dist/runtime-dom.cjs.prod.js +1750 -0
- package/.output/server/node_modules/@vue/runtime-dom/package.json +60 -0
- package/.output/server/node_modules/@vue/server-renderer/dist/server-renderer.cjs.prod.js +883 -0
- package/.output/server/node_modules/@vue/server-renderer/package.json +55 -0
- package/.output/server/node_modules/@vue/shared/dist/shared.cjs.prod.js +604 -0
- package/.output/server/node_modules/@vue/shared/package.json +47 -0
- package/.output/server/node_modules/birpc/dist/index.cjs +296 -0
- package/.output/server/node_modules/birpc/package.json +57 -0
- package/.output/server/node_modules/consola/dist/chunks/prompt.mjs +280 -0
- package/.output/server/node_modules/consola/dist/core.mjs +512 -0
- package/.output/server/node_modules/consola/dist/index.mjs +651 -0
- package/.output/server/node_modules/consola/dist/shared/consola.DRwqZj3T.mjs +72 -0
- package/.output/server/node_modules/consola/dist/shared/consola.DXBYu-KD.mjs +288 -0
- package/.output/server/node_modules/consola/package.json +136 -0
- package/.output/server/node_modules/devalue/index.js +4 -0
- package/.output/server/node_modules/devalue/package.json +37 -0
- package/.output/server/node_modules/devalue/src/base64.js +110 -0
- package/.output/server/node_modules/devalue/src/constants.js +7 -0
- package/.output/server/node_modules/devalue/src/parse.js +246 -0
- package/.output/server/node_modules/devalue/src/stringify.js +350 -0
- package/.output/server/node_modules/devalue/src/uneval.js +490 -0
- package/.output/server/node_modules/devalue/src/utils.js +148 -0
- package/.output/server/node_modules/entities/dist/commonjs/decode-codepoint.js +77 -0
- package/.output/server/node_modules/entities/dist/commonjs/decode.js +568 -0
- package/.output/server/node_modules/entities/dist/commonjs/generated/decode-data-html.js +7 -0
- package/.output/server/node_modules/entities/dist/commonjs/generated/decode-data-xml.js +7 -0
- package/.output/server/node_modules/entities/dist/commonjs/internal/bin-trie-flags.js +21 -0
- package/.output/server/node_modules/entities/dist/commonjs/internal/decode-shared.js +31 -0
- package/.output/server/node_modules/entities/dist/commonjs/package.json +3 -0
- package/.output/server/node_modules/entities/package.json +120 -0
- package/.output/server/node_modules/estree-walker/dist/umd/estree-walker.js +344 -0
- package/.output/server/node_modules/estree-walker/package.json +37 -0
- package/.output/server/node_modules/pinia/dist/pinia.prod.cjs +719 -0
- package/.output/server/node_modules/pinia/package.json +94 -0
- package/.output/server/node_modules/source-map-js/lib/array-set.js +121 -0
- package/.output/server/node_modules/source-map-js/lib/base64-vlq.js +140 -0
- package/.output/server/node_modules/source-map-js/lib/base64.js +67 -0
- package/.output/server/node_modules/source-map-js/lib/binary-search.js +111 -0
- package/.output/server/node_modules/source-map-js/lib/mapping-list.js +79 -0
- package/.output/server/node_modules/source-map-js/lib/quick-sort.js +132 -0
- package/.output/server/node_modules/source-map-js/lib/source-map-consumer.js +1188 -0
- package/.output/server/node_modules/source-map-js/lib/source-map-generator.js +444 -0
- package/.output/server/node_modules/source-map-js/lib/source-node.js +413 -0
- package/.output/server/node_modules/source-map-js/lib/util.js +594 -0
- package/.output/server/node_modules/source-map-js/package.json +71 -0
- package/.output/server/node_modules/source-map-js/source-map.js +8 -0
- package/.output/server/node_modules/tailwindcss/dist/chunk-X4GG3EDV.mjs +1 -0
- package/.output/server/node_modules/tailwindcss/dist/colors.mjs +1 -0
- package/.output/server/node_modules/tailwindcss/package.json +89 -0
- package/.output/server/node_modules/ufo/dist/index.mjs +645 -0
- package/.output/server/node_modules/ufo/package.json +48 -0
- package/.output/server/node_modules/unhead/dist/index.mjs +9 -0
- package/.output/server/node_modules/unhead/dist/parser.mjs +508 -0
- package/.output/server/node_modules/unhead/dist/plugins.mjs +101 -0
- package/.output/server/node_modules/unhead/dist/scripts.mjs +30 -0
- package/.output/server/node_modules/unhead/dist/server.mjs +180 -0
- package/.output/server/node_modules/unhead/dist/shared/unhead.BPM0-cfG.mjs +44 -0
- package/.output/server/node_modules/unhead/dist/shared/unhead.BYvz9V1x.mjs +43 -0
- package/.output/server/node_modules/unhead/dist/shared/unhead.BnoAbrHA.mjs +269 -0
- package/.output/server/node_modules/unhead/dist/shared/unhead.CApf5sj3.mjs +148 -0
- package/.output/server/node_modules/unhead/dist/shared/unhead.CbpEuj3y.mjs +71 -0
- package/.output/server/node_modules/unhead/dist/shared/unhead.DQc16pHI.mjs +196 -0
- package/.output/server/node_modules/unhead/dist/shared/unhead.D_nrZZPH.mjs +182 -0
- package/.output/server/node_modules/unhead/dist/shared/unhead.ckV6dpEQ.mjs +166 -0
- package/.output/server/node_modules/unhead/dist/shared/unhead.fVVqDC1O.mjs +203 -0
- package/.output/server/node_modules/unhead/dist/shared/unhead.yem5I2v_.mjs +38 -0
- package/.output/server/node_modules/unhead/dist/utils.mjs +5 -0
- package/.output/server/node_modules/unhead/package.json +105 -0
- package/.output/server/node_modules/vue/dist/vue.cjs.js +80 -0
- package/.output/server/node_modules/vue/dist/vue.cjs.prod.js +66 -0
- package/.output/server/node_modules/vue/index.js +7 -0
- package/.output/server/node_modules/vue/index.mjs +1 -0
- package/.output/server/node_modules/vue/package.json +112 -0
- package/.output/server/node_modules/vue/server-renderer/index.mjs +1 -0
- package/.output/server/node_modules/vue-bundle-renderer/dist/runtime.mjs +301 -0
- package/.output/server/node_modules/vue-bundle-renderer/package.json +55 -0
- package/.output/server/node_modules/vue-router/dist/devtools-EWN81iOl.mjs +1220 -0
- package/.output/server/node_modules/vue-router/dist/vue-router.mjs +1557 -0
- package/.output/server/node_modules/vue-router/package.json +153 -0
- package/.output/server/node_modules/vue-router/vue-router.node.mjs +2 -0
- package/.output/server/package.json +37 -0
- package/LICENSE +21 -0
- package/README.md +132 -0
- package/bin/cli.js +75 -0
- package/package.json +71 -0
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
const sortTags = (a, b) => a._w === b._w ? a._p - b._p : a._w - b._w;
|
|
2
|
+
const TAG_WEIGHTS = {
|
|
3
|
+
base: -10,
|
|
4
|
+
title: 10
|
|
5
|
+
};
|
|
6
|
+
const TAG_ALIASES = {
|
|
7
|
+
critical: -8,
|
|
8
|
+
high: -1,
|
|
9
|
+
low: 2
|
|
10
|
+
};
|
|
11
|
+
const WEIGHT_MAP = {
|
|
12
|
+
meta: {
|
|
13
|
+
"content-security-policy": -30,
|
|
14
|
+
"charset": -20,
|
|
15
|
+
"viewport": -15
|
|
16
|
+
},
|
|
17
|
+
link: {
|
|
18
|
+
"preconnect": 20,
|
|
19
|
+
"stylesheet": 60,
|
|
20
|
+
"preload": 70,
|
|
21
|
+
"modulepreload": 70,
|
|
22
|
+
"prefetch": 90,
|
|
23
|
+
"dns-prefetch": 90,
|
|
24
|
+
"prerender": 90
|
|
25
|
+
},
|
|
26
|
+
script: {
|
|
27
|
+
async: 30,
|
|
28
|
+
defer: 80,
|
|
29
|
+
sync: 50
|
|
30
|
+
},
|
|
31
|
+
style: {
|
|
32
|
+
imported: 40,
|
|
33
|
+
sync: 60
|
|
34
|
+
}
|
|
35
|
+
};
|
|
36
|
+
const ImportStyleRe = /@import/;
|
|
37
|
+
const isTruthy = (val) => val === "" || val === true;
|
|
38
|
+
function tagWeight(head, tag) {
|
|
39
|
+
if (typeof tag.tagPriority === "number")
|
|
40
|
+
return tag.tagPriority;
|
|
41
|
+
let weight = 100;
|
|
42
|
+
const offset = TAG_ALIASES[tag.tagPriority] || 0;
|
|
43
|
+
const weightMap = head.resolvedOptions.disableCapoSorting ? {
|
|
44
|
+
link: {},
|
|
45
|
+
script: {},
|
|
46
|
+
style: {}
|
|
47
|
+
} : WEIGHT_MAP;
|
|
48
|
+
if (tag.tag in TAG_WEIGHTS) {
|
|
49
|
+
weight = TAG_WEIGHTS[tag.tag];
|
|
50
|
+
} else if (tag.tag === "meta") {
|
|
51
|
+
const metaType = tag.props["http-equiv"] === "content-security-policy" ? "content-security-policy" : tag.props.charset ? "charset" : tag.props.name === "viewport" ? "viewport" : null;
|
|
52
|
+
if (metaType)
|
|
53
|
+
weight = WEIGHT_MAP.meta[metaType];
|
|
54
|
+
} else if (tag.tag === "link" && tag.props.rel) {
|
|
55
|
+
weight = weightMap.link[tag.props.rel];
|
|
56
|
+
} else if (tag.tag === "script") {
|
|
57
|
+
const type = String(tag.props.type);
|
|
58
|
+
if (isTruthy(tag.props.async)) {
|
|
59
|
+
weight = weightMap.script.async;
|
|
60
|
+
} else if (tag.props.src && !isTruthy(tag.props.defer) && !isTruthy(tag.props.async) && type !== "module" && !type.endsWith("json") || tag.innerHTML && !type.endsWith("json")) {
|
|
61
|
+
weight = weightMap.script.sync;
|
|
62
|
+
} else if (isTruthy(tag.props.defer) && tag.props.src && !isTruthy(tag.props.async) || type === "module") {
|
|
63
|
+
weight = weightMap.script.defer;
|
|
64
|
+
}
|
|
65
|
+
} else if (tag.tag === "style") {
|
|
66
|
+
weight = tag.innerHTML && ImportStyleRe.test(tag.innerHTML) ? weightMap.style.imported : weightMap.style.sync;
|
|
67
|
+
}
|
|
68
|
+
return (weight || 100) + offset;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
export { sortTags as s, tagWeight as t };
|
|
@@ -0,0 +1,196 @@
|
|
|
1
|
+
import { M as MetaTagsArrayable } from './unhead.yem5I2v_.mjs';
|
|
2
|
+
|
|
3
|
+
const NAMESPACES = {
|
|
4
|
+
META: /* @__PURE__ */ new Set(["twitter"]),
|
|
5
|
+
OG: /* @__PURE__ */ new Set(["og", "book", "article", "profile", "fb"]),
|
|
6
|
+
MEDIA: /* @__PURE__ */ new Set(["ogImage", "ogVideo", "ogAudio", "twitterImage"]),
|
|
7
|
+
HTTP_EQUIV: /* @__PURE__ */ new Set(["contentType", "defaultStyle", "xUaCompatible"])
|
|
8
|
+
};
|
|
9
|
+
const META_ALIASES = {
|
|
10
|
+
articleExpirationTime: "article:expiration_time",
|
|
11
|
+
articleModifiedTime: "article:modified_time",
|
|
12
|
+
articlePublishedTime: "article:published_time",
|
|
13
|
+
bookReleaseDate: "book:release_date",
|
|
14
|
+
fbAppId: "fb:app_id",
|
|
15
|
+
ogAudioSecureUrl: "og:audio:secure_url",
|
|
16
|
+
ogAudioUrl: "og:audio",
|
|
17
|
+
ogImageSecureUrl: "og:image:secure_url",
|
|
18
|
+
ogImageUrl: "og:image",
|
|
19
|
+
ogSiteName: "og:site_name",
|
|
20
|
+
ogVideoSecureUrl: "og:video:secure_url",
|
|
21
|
+
ogVideoUrl: "og:video",
|
|
22
|
+
profileFirstName: "profile:first_name",
|
|
23
|
+
profileLastName: "profile:last_name",
|
|
24
|
+
profileUsername: "profile:username",
|
|
25
|
+
msapplicationConfig: "msapplication-Config",
|
|
26
|
+
msapplicationTileColor: "msapplication-TileColor",
|
|
27
|
+
msapplicationTileImage: "msapplication-TileImage"
|
|
28
|
+
};
|
|
29
|
+
const MetaPackingSchema = {
|
|
30
|
+
appleItunesApp: {
|
|
31
|
+
unpack: {
|
|
32
|
+
entrySeparator: ", ",
|
|
33
|
+
// @ts-expect-error untyped
|
|
34
|
+
resolve: ({ key, value }) => `${fixKeyCase(key)}=${value}`
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
refresh: {
|
|
38
|
+
metaKey: "http-equiv",
|
|
39
|
+
unpack: {
|
|
40
|
+
entrySeparator: ";",
|
|
41
|
+
// @ts-expect-error untyped
|
|
42
|
+
resolve: ({ key, value }) => key === "seconds" ? `${value}` : void 0
|
|
43
|
+
}
|
|
44
|
+
},
|
|
45
|
+
robots: {
|
|
46
|
+
unpack: {
|
|
47
|
+
entrySeparator: ", ",
|
|
48
|
+
// @ts-expect-error untyped
|
|
49
|
+
resolve: ({ key, value }) => typeof value === "boolean" ? fixKeyCase(key) : `${fixKeyCase(key)}:${value}`
|
|
50
|
+
}
|
|
51
|
+
},
|
|
52
|
+
contentSecurityPolicy: {
|
|
53
|
+
metaKey: "http-equiv",
|
|
54
|
+
unpack: {
|
|
55
|
+
entrySeparator: "; ",
|
|
56
|
+
// @ts-expect-error untyped
|
|
57
|
+
resolve: ({ key, value }) => `${fixKeyCase(key)} ${value}`
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
charset: {}
|
|
61
|
+
};
|
|
62
|
+
function fixKeyCase(key) {
|
|
63
|
+
const updated = key.replace(/([A-Z])/g, "-$1").toLowerCase();
|
|
64
|
+
const prefixIndex = updated.indexOf("-");
|
|
65
|
+
return prefixIndex === -1 ? updated : NAMESPACES.META.has(updated.slice(0, prefixIndex)) || NAMESPACES.OG.has(updated.slice(0, prefixIndex)) ? key.replace(/([A-Z])/g, ":$1").toLowerCase() : updated;
|
|
66
|
+
}
|
|
67
|
+
function sanitizeObject(input) {
|
|
68
|
+
return Object.fromEntries(Object.entries(input).filter(([k, v]) => String(v) !== "false" && k));
|
|
69
|
+
}
|
|
70
|
+
function transformObject(obj) {
|
|
71
|
+
return Array.isArray(obj) ? obj.map(transformObject) : !obj || typeof obj !== "object" ? obj : Object.fromEntries(Object.entries(obj).map(([k, v]) => [fixKeyCase(k), transformObject(v)]));
|
|
72
|
+
}
|
|
73
|
+
function unpackToString(value, options = {}) {
|
|
74
|
+
const { entrySeparator = "", keyValueSeparator = "", wrapValue, resolve } = options;
|
|
75
|
+
return Object.entries(value).map(([key, val]) => {
|
|
76
|
+
if (resolve) {
|
|
77
|
+
const resolved = resolve({ key, value: val });
|
|
78
|
+
if (resolved !== void 0)
|
|
79
|
+
return resolved;
|
|
80
|
+
}
|
|
81
|
+
const processedVal = typeof val === "object" ? unpackToString(val, options) : typeof val === "number" ? val.toString() : typeof val === "string" && wrapValue ? `${wrapValue}${val.replace(new RegExp(wrapValue, "g"), `\\${wrapValue}`)}${wrapValue}` : val;
|
|
82
|
+
return `${key}${keyValueSeparator}${processedVal}`;
|
|
83
|
+
}).join(entrySeparator);
|
|
84
|
+
}
|
|
85
|
+
function handleObjectEntry(key, value) {
|
|
86
|
+
const sanitizedValue = sanitizeObject(value);
|
|
87
|
+
const fixedKey = fixKeyCase(key);
|
|
88
|
+
const attr = resolveMetaKeyType(fixedKey);
|
|
89
|
+
if (!MetaTagsArrayable.has(fixedKey)) {
|
|
90
|
+
return [{ [attr]: fixedKey, ...sanitizedValue }];
|
|
91
|
+
}
|
|
92
|
+
const input = Object.fromEntries(
|
|
93
|
+
Object.entries(sanitizedValue).map(([k, v]) => [`${key}${k === "url" ? "" : `${k[0].toUpperCase()}${k.slice(1)}`}`, v])
|
|
94
|
+
);
|
|
95
|
+
return unpackMeta(input || {}).sort((a, b) => (a[attr]?.length || 0) - (b[attr]?.length || 0));
|
|
96
|
+
}
|
|
97
|
+
function resolveMetaKeyType(key) {
|
|
98
|
+
if (MetaPackingSchema[key]?.metaKey === "http-equiv" || NAMESPACES.HTTP_EQUIV.has(key)) {
|
|
99
|
+
return "http-equiv";
|
|
100
|
+
}
|
|
101
|
+
const fixed = fixKeyCase(key);
|
|
102
|
+
const colonIndex = fixed.indexOf(":");
|
|
103
|
+
return colonIndex === -1 ? "name" : NAMESPACES.OG.has(fixed.slice(0, colonIndex)) ? "property" : "name";
|
|
104
|
+
}
|
|
105
|
+
function resolveMetaKeyValue(key) {
|
|
106
|
+
return META_ALIASES[key] || fixKeyCase(key);
|
|
107
|
+
}
|
|
108
|
+
function resolvePackedMetaObjectValue(value, key) {
|
|
109
|
+
if (key === "refresh")
|
|
110
|
+
return `${value.seconds};url=${value.url}`;
|
|
111
|
+
return unpackToString(transformObject(value), {
|
|
112
|
+
keyValueSeparator: "=",
|
|
113
|
+
entrySeparator: ", ",
|
|
114
|
+
resolve: ({ value: value2, key: key2 }) => value2 === null ? "" : typeof value2 === "boolean" ? key2 : void 0,
|
|
115
|
+
// @ts-expect-error untyped
|
|
116
|
+
...MetaPackingSchema[key]?.unpack
|
|
117
|
+
});
|
|
118
|
+
}
|
|
119
|
+
function unpackMeta(input) {
|
|
120
|
+
const extras = [];
|
|
121
|
+
const primitives = {};
|
|
122
|
+
for (const [key, value] of Object.entries(input)) {
|
|
123
|
+
if (Array.isArray(value)) {
|
|
124
|
+
if (key === "themeColor") {
|
|
125
|
+
value.forEach((v) => {
|
|
126
|
+
if (typeof v === "object" && v !== null) {
|
|
127
|
+
extras.push({ name: "theme-color", ...v });
|
|
128
|
+
}
|
|
129
|
+
});
|
|
130
|
+
continue;
|
|
131
|
+
}
|
|
132
|
+
for (const v of value) {
|
|
133
|
+
if (typeof v === "object" && v !== null) {
|
|
134
|
+
const urlProps = [];
|
|
135
|
+
const otherProps = [];
|
|
136
|
+
for (const [propKey, propValue] of Object.entries(v)) {
|
|
137
|
+
const metaKey = `${key}${propKey === "url" ? "" : `:${propKey}`}`;
|
|
138
|
+
const meta2 = unpackMeta({ [metaKey]: propValue });
|
|
139
|
+
(propKey === "url" ? urlProps : otherProps).push(...meta2);
|
|
140
|
+
}
|
|
141
|
+
extras.push(...urlProps, ...otherProps);
|
|
142
|
+
} else {
|
|
143
|
+
extras.push(...typeof v === "string" ? unpackMeta({ [key]: v }) : handleObjectEntry(key, v));
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
continue;
|
|
147
|
+
}
|
|
148
|
+
if (typeof value === "object" && value) {
|
|
149
|
+
if (NAMESPACES.MEDIA.has(key)) {
|
|
150
|
+
const prefix = key.startsWith("twitter") ? "twitter" : "og";
|
|
151
|
+
const type = key.replace(/^(og|twitter)/, "").toLowerCase();
|
|
152
|
+
const metaKey = prefix === "twitter" ? "name" : "property";
|
|
153
|
+
if (value.url) {
|
|
154
|
+
extras.push({
|
|
155
|
+
[metaKey]: `${prefix}:${type}`,
|
|
156
|
+
content: value.url
|
|
157
|
+
});
|
|
158
|
+
}
|
|
159
|
+
if (value.secureUrl) {
|
|
160
|
+
extras.push({
|
|
161
|
+
[metaKey]: `${prefix}:${type}:secure_url`,
|
|
162
|
+
content: value.secureUrl
|
|
163
|
+
});
|
|
164
|
+
}
|
|
165
|
+
for (const [propKey, propValue] of Object.entries(value)) {
|
|
166
|
+
if (propKey !== "url" && propKey !== "secureUrl") {
|
|
167
|
+
extras.push({
|
|
168
|
+
[metaKey]: `${prefix}:${type}:${propKey}`,
|
|
169
|
+
// @ts-expect-error untyped
|
|
170
|
+
content: propValue
|
|
171
|
+
});
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
} else if (MetaTagsArrayable.has(fixKeyCase(key))) {
|
|
175
|
+
extras.push(...handleObjectEntry(key, value));
|
|
176
|
+
} else {
|
|
177
|
+
primitives[key] = sanitizeObject(value);
|
|
178
|
+
}
|
|
179
|
+
} else {
|
|
180
|
+
primitives[key] = value;
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
const meta = Object.entries(primitives).map(([key, value]) => {
|
|
184
|
+
if (key === "charset")
|
|
185
|
+
return { charset: value === null ? "_null" : value };
|
|
186
|
+
const metaKey = resolveMetaKeyType(key);
|
|
187
|
+
const keyValue = resolveMetaKeyValue(key);
|
|
188
|
+
const processedValue = value === null ? "_null" : typeof value === "object" ? resolvePackedMetaObjectValue(value, key) : typeof value === "number" ? value.toString() : value;
|
|
189
|
+
return metaKey === "http-equiv" ? { "http-equiv": keyValue, "content": processedValue } : { [metaKey]: keyValue, content: processedValue };
|
|
190
|
+
});
|
|
191
|
+
return [...extras, ...meta].map(
|
|
192
|
+
(m) => !("content" in m) ? m : m.content === "_null" ? { ...m, content: null } : m
|
|
193
|
+
);
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
export { resolveMetaKeyValue as a, resolvePackedMetaObjectValue as b, resolveMetaKeyType as r, unpackMeta as u };
|
|
@@ -0,0 +1,182 @@
|
|
|
1
|
+
import { createHooks } from 'hookable';
|
|
2
|
+
import { n as normalizeEntryToTags, d as dedupeKey, h as hashTag, i as isMetaArrayDupeKey } from './unhead.fVVqDC1O.mjs';
|
|
3
|
+
import { t as tagWeight, s as sortTags } from './unhead.CbpEuj3y.mjs';
|
|
4
|
+
import { c as UsesMergeStrategy, V as ValidHeadTags } from './unhead.yem5I2v_.mjs';
|
|
5
|
+
|
|
6
|
+
function registerPlugin(head, p) {
|
|
7
|
+
const plugin = typeof p === "function" ? p(head) : p;
|
|
8
|
+
const key = plugin.key || String(head.plugins.size + 1);
|
|
9
|
+
const exists = head.plugins.get(key);
|
|
10
|
+
if (!exists) {
|
|
11
|
+
head.plugins.set(key, plugin);
|
|
12
|
+
head.hooks.addHooks(plugin.hooks || {});
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
// @__NO_SIDE_EFFECTS__
|
|
16
|
+
function createHeadCore(resolvedOptions = {}) {
|
|
17
|
+
return /* @__PURE__ */ createUnhead(resolvedOptions);
|
|
18
|
+
}
|
|
19
|
+
// @__NO_SIDE_EFFECTS__
|
|
20
|
+
function createUnhead(resolvedOptions = {}) {
|
|
21
|
+
const hooks = createHooks();
|
|
22
|
+
hooks.addHooks(resolvedOptions.hooks || {});
|
|
23
|
+
const ssr = !resolvedOptions.document;
|
|
24
|
+
const entries = /* @__PURE__ */ new Map();
|
|
25
|
+
const plugins = /* @__PURE__ */ new Map();
|
|
26
|
+
const normalizeQueue = /* @__PURE__ */ new Set();
|
|
27
|
+
const head = {
|
|
28
|
+
_entryCount: 1,
|
|
29
|
+
// 0 is reserved for internal use
|
|
30
|
+
plugins,
|
|
31
|
+
dirty: false,
|
|
32
|
+
resolvedOptions,
|
|
33
|
+
hooks,
|
|
34
|
+
ssr,
|
|
35
|
+
entries,
|
|
36
|
+
headEntries() {
|
|
37
|
+
return [...entries.values()];
|
|
38
|
+
},
|
|
39
|
+
use: (p) => registerPlugin(head, p),
|
|
40
|
+
push(input, _options) {
|
|
41
|
+
const options = { ..._options || {} };
|
|
42
|
+
delete options.head;
|
|
43
|
+
const _i = options._index ?? head._entryCount++;
|
|
44
|
+
const inst = { _i, input, options };
|
|
45
|
+
const _ = {
|
|
46
|
+
_poll(rm = false) {
|
|
47
|
+
head.dirty = true;
|
|
48
|
+
!rm && normalizeQueue.add(_i);
|
|
49
|
+
hooks.callHook("entries:updated", head);
|
|
50
|
+
},
|
|
51
|
+
dispose() {
|
|
52
|
+
if (entries.delete(_i)) {
|
|
53
|
+
head.invalidate();
|
|
54
|
+
}
|
|
55
|
+
},
|
|
56
|
+
// a patch is the same as creating a new entry, just a nice DX
|
|
57
|
+
patch(input2) {
|
|
58
|
+
if (!options.mode || options.mode === "server" && ssr || options.mode === "client" && !ssr) {
|
|
59
|
+
inst.input = input2;
|
|
60
|
+
entries.set(_i, inst);
|
|
61
|
+
_._poll();
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
};
|
|
65
|
+
_.patch(input);
|
|
66
|
+
return _;
|
|
67
|
+
},
|
|
68
|
+
async resolveTags() {
|
|
69
|
+
const ctx = {
|
|
70
|
+
tagMap: /* @__PURE__ */ new Map(),
|
|
71
|
+
tags: [],
|
|
72
|
+
entries: [...head.entries.values()]
|
|
73
|
+
};
|
|
74
|
+
await hooks.callHook("entries:resolve", ctx);
|
|
75
|
+
while (normalizeQueue.size) {
|
|
76
|
+
const i = normalizeQueue.values().next().value;
|
|
77
|
+
normalizeQueue.delete(i);
|
|
78
|
+
const e = entries.get(i);
|
|
79
|
+
if (e) {
|
|
80
|
+
const normalizeCtx = {
|
|
81
|
+
tags: normalizeEntryToTags(e.input, resolvedOptions.propResolvers || []).map((t) => Object.assign(t, e.options)),
|
|
82
|
+
entry: e
|
|
83
|
+
};
|
|
84
|
+
await hooks.callHook("entries:normalize", normalizeCtx);
|
|
85
|
+
e._tags = normalizeCtx.tags.map((t, i2) => {
|
|
86
|
+
t._w = tagWeight(head, t);
|
|
87
|
+
t._p = (e._i << 10) + i2;
|
|
88
|
+
t._d = dedupeKey(t);
|
|
89
|
+
if (!t._d)
|
|
90
|
+
t._h = hashTag(t);
|
|
91
|
+
return t;
|
|
92
|
+
});
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
let hasFlatMeta = false;
|
|
96
|
+
ctx.entries.flatMap((e) => (e._tags || []).map((t) => ({ ...t, props: { ...t.props } }))).sort(sortTags).reduce((acc, next) => {
|
|
97
|
+
const k = next._d || next._h;
|
|
98
|
+
if (!acc.has(k))
|
|
99
|
+
return acc.set(k, next);
|
|
100
|
+
const prev = acc.get(k);
|
|
101
|
+
const strategy = next?.tagDuplicateStrategy || (UsesMergeStrategy.has(next.tag) ? "merge" : null) || (next.key && next.key === prev.key ? "merge" : null);
|
|
102
|
+
if (strategy === "merge") {
|
|
103
|
+
const newProps = { ...prev.props };
|
|
104
|
+
Object.entries(next.props).forEach(([p, v]) => (
|
|
105
|
+
// @ts-expect-error untyped
|
|
106
|
+
newProps[p] = p === "style" ? new Map([...prev.props.style || /* @__PURE__ */ new Map(), ...v]) : p === "class" ? /* @__PURE__ */ new Set([...prev.props.class || /* @__PURE__ */ new Set(), ...v]) : v
|
|
107
|
+
));
|
|
108
|
+
acc.set(k, { ...next, props: newProps });
|
|
109
|
+
} else if (next._p >> 10 === prev._p >> 10 && next.tag === "meta" && isMetaArrayDupeKey(k)) {
|
|
110
|
+
acc.set(k, Object.assign([...Array.isArray(prev) ? prev : [prev], next], next));
|
|
111
|
+
hasFlatMeta = true;
|
|
112
|
+
} else if (next._w === prev._w ? next._p > prev._p : next?._w < prev?._w) {
|
|
113
|
+
acc.set(k, next);
|
|
114
|
+
}
|
|
115
|
+
return acc;
|
|
116
|
+
}, ctx.tagMap);
|
|
117
|
+
const title = ctx.tagMap.get("title");
|
|
118
|
+
const titleTemplate = ctx.tagMap.get("titleTemplate");
|
|
119
|
+
head._title = title?.textContent;
|
|
120
|
+
if (titleTemplate) {
|
|
121
|
+
const titleTemplateFn = titleTemplate?.textContent;
|
|
122
|
+
head._titleTemplate = titleTemplateFn;
|
|
123
|
+
if (titleTemplateFn) {
|
|
124
|
+
let newTitle = typeof titleTemplateFn === "function" ? titleTemplateFn(title?.textContent) : titleTemplateFn;
|
|
125
|
+
if (typeof newTitle === "string" && !head.plugins.has("template-params")) {
|
|
126
|
+
newTitle = newTitle.replace("%s", title?.textContent || "");
|
|
127
|
+
}
|
|
128
|
+
if (title) {
|
|
129
|
+
newTitle === null ? ctx.tagMap.delete("title") : ctx.tagMap.set("title", { ...title, textContent: newTitle });
|
|
130
|
+
} else {
|
|
131
|
+
titleTemplate.tag = "title";
|
|
132
|
+
titleTemplate.textContent = newTitle;
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
ctx.tags = Array.from(ctx.tagMap.values());
|
|
137
|
+
if (hasFlatMeta) {
|
|
138
|
+
ctx.tags = ctx.tags.flat().sort(sortTags);
|
|
139
|
+
}
|
|
140
|
+
await hooks.callHook("tags:beforeResolve", ctx);
|
|
141
|
+
await hooks.callHook("tags:resolve", ctx);
|
|
142
|
+
await hooks.callHook("tags:afterResolve", ctx);
|
|
143
|
+
const finalTags = [];
|
|
144
|
+
for (const t of ctx.tags) {
|
|
145
|
+
const { innerHTML, tag, props } = t;
|
|
146
|
+
if (!ValidHeadTags.has(tag)) {
|
|
147
|
+
continue;
|
|
148
|
+
}
|
|
149
|
+
if (Object.keys(props).length === 0 && !t.innerHTML && !t.textContent) {
|
|
150
|
+
continue;
|
|
151
|
+
}
|
|
152
|
+
if (tag === "meta" && !props.content && !props["http-equiv"] && !props.charset) {
|
|
153
|
+
continue;
|
|
154
|
+
}
|
|
155
|
+
if (tag === "script" && innerHTML) {
|
|
156
|
+
if (String(props.type).endsWith("json")) {
|
|
157
|
+
const v = typeof innerHTML === "string" ? innerHTML : JSON.stringify(innerHTML);
|
|
158
|
+
t.innerHTML = v.replace(/</g, "\\u003C");
|
|
159
|
+
} else if (typeof innerHTML === "string") {
|
|
160
|
+
t.innerHTML = innerHTML.replace(new RegExp(`</${tag}`, "g"), `<\\/${tag}`);
|
|
161
|
+
}
|
|
162
|
+
t._d = dedupeKey(t);
|
|
163
|
+
}
|
|
164
|
+
finalTags.push(t);
|
|
165
|
+
}
|
|
166
|
+
return finalTags;
|
|
167
|
+
},
|
|
168
|
+
invalidate() {
|
|
169
|
+
for (const entry of entries.values()) {
|
|
170
|
+
normalizeQueue.add(entry._i);
|
|
171
|
+
}
|
|
172
|
+
head.dirty = true;
|
|
173
|
+
hooks.callHook("entries:updated", head);
|
|
174
|
+
}
|
|
175
|
+
};
|
|
176
|
+
(resolvedOptions?.plugins || []).forEach((p) => registerPlugin(head, p));
|
|
177
|
+
head.hooks.callHook("init", head);
|
|
178
|
+
resolvedOptions.init?.forEach((e) => e && head.push(e));
|
|
179
|
+
return head;
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
export { createUnhead as a, createHeadCore as c };
|
|
@@ -0,0 +1,166 @@
|
|
|
1
|
+
import { d as defineHeadPlugin } from './unhead.CApf5sj3.mjs';
|
|
2
|
+
import { s as sortTags } from './unhead.CbpEuj3y.mjs';
|
|
3
|
+
import { p as processTemplateParams } from './unhead.BYvz9V1x.mjs';
|
|
4
|
+
|
|
5
|
+
const formatKey = (k) => !k.includes(":key") ? k.split(":").join(":key:") : k;
|
|
6
|
+
const AliasSortingPlugin = defineHeadPlugin({
|
|
7
|
+
key: "aliasSorting",
|
|
8
|
+
hooks: {
|
|
9
|
+
"tags:resolve": (ctx) => {
|
|
10
|
+
let m = false;
|
|
11
|
+
for (const t of ctx.tags) {
|
|
12
|
+
const p = t.tagPriority;
|
|
13
|
+
if (!p)
|
|
14
|
+
continue;
|
|
15
|
+
const s = String(p);
|
|
16
|
+
if (s.startsWith("before:")) {
|
|
17
|
+
const k = formatKey(s.slice(7));
|
|
18
|
+
const l = ctx.tagMap.get(k);
|
|
19
|
+
if (l) {
|
|
20
|
+
if (typeof l.tagPriority === "number")
|
|
21
|
+
t.tagPriority = l.tagPriority;
|
|
22
|
+
t._p = l._p - 1;
|
|
23
|
+
m = true;
|
|
24
|
+
}
|
|
25
|
+
} else if (s.startsWith("after:")) {
|
|
26
|
+
const k = formatKey(s.slice(6));
|
|
27
|
+
const l = ctx.tagMap.get(k);
|
|
28
|
+
if (l) {
|
|
29
|
+
if (typeof l.tagPriority === "number")
|
|
30
|
+
t.tagPriority = l.tagPriority;
|
|
31
|
+
t._p = l._p + 1;
|
|
32
|
+
m = true;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
if (m)
|
|
37
|
+
ctx.tags = ctx.tags.sort(sortTags);
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
});
|
|
41
|
+
|
|
42
|
+
const DeprecationsPlugin = /* @__PURE__ */ defineHeadPlugin({
|
|
43
|
+
key: "deprecations",
|
|
44
|
+
hooks: {
|
|
45
|
+
"entries:normalize": ({ tags }) => {
|
|
46
|
+
for (const tag of tags) {
|
|
47
|
+
if (tag.props.children) {
|
|
48
|
+
tag.innerHTML = tag.props.children;
|
|
49
|
+
delete tag.props.children;
|
|
50
|
+
}
|
|
51
|
+
if (tag.props.hid) {
|
|
52
|
+
tag.key = tag.props.hid;
|
|
53
|
+
delete tag.props.hid;
|
|
54
|
+
}
|
|
55
|
+
if (tag.props.vmid) {
|
|
56
|
+
tag.key = tag.props.vmid;
|
|
57
|
+
delete tag.props.vmid;
|
|
58
|
+
}
|
|
59
|
+
if (tag.props.body) {
|
|
60
|
+
tag.tagPosition = "bodyClose";
|
|
61
|
+
delete tag.props.body;
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
});
|
|
67
|
+
|
|
68
|
+
async function walkPromises(v) {
|
|
69
|
+
const type = typeof v;
|
|
70
|
+
if (type === "function") {
|
|
71
|
+
return v;
|
|
72
|
+
}
|
|
73
|
+
if (v instanceof Promise) {
|
|
74
|
+
return await v;
|
|
75
|
+
}
|
|
76
|
+
if (Array.isArray(v)) {
|
|
77
|
+
return await Promise.all(v.map((r) => walkPromises(r)));
|
|
78
|
+
}
|
|
79
|
+
if (v?.constructor === Object) {
|
|
80
|
+
const next = {};
|
|
81
|
+
for (const key of Object.keys(v)) {
|
|
82
|
+
next[key] = await walkPromises(v[key]);
|
|
83
|
+
}
|
|
84
|
+
return next;
|
|
85
|
+
}
|
|
86
|
+
return v;
|
|
87
|
+
}
|
|
88
|
+
const PromisesPlugin = /* @__PURE__ */ defineHeadPlugin({
|
|
89
|
+
key: "promises",
|
|
90
|
+
hooks: {
|
|
91
|
+
"entries:resolve": async (ctx) => {
|
|
92
|
+
const promises = [];
|
|
93
|
+
for (const k in ctx.entries) {
|
|
94
|
+
if (!ctx.entries[k]._promisesProcessed) {
|
|
95
|
+
promises.push(
|
|
96
|
+
walkPromises(ctx.entries[k].input).then((val) => {
|
|
97
|
+
ctx.entries[k].input = val;
|
|
98
|
+
ctx.entries[k]._promisesProcessed = true;
|
|
99
|
+
})
|
|
100
|
+
);
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
await Promise.all(promises);
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
});
|
|
107
|
+
|
|
108
|
+
const SupportedAttrs = {
|
|
109
|
+
meta: "content",
|
|
110
|
+
link: "href",
|
|
111
|
+
htmlAttrs: "lang"
|
|
112
|
+
};
|
|
113
|
+
const contentAttrs = ["innerHTML", "textContent"];
|
|
114
|
+
const TemplateParamsPlugin = /* @__PURE__ */ defineHeadPlugin((head) => {
|
|
115
|
+
return {
|
|
116
|
+
key: "template-params",
|
|
117
|
+
hooks: {
|
|
118
|
+
"entries:normalize": (ctx) => {
|
|
119
|
+
const params = ctx.tags.filter((t) => t.tag === "templateParams" && t.mode === "server")?.[0]?.props || {};
|
|
120
|
+
if (Object.keys(params).length) {
|
|
121
|
+
head._ssrPayload = {
|
|
122
|
+
templateParams: {
|
|
123
|
+
...head._ssrPayload?.templateParams || {},
|
|
124
|
+
...params
|
|
125
|
+
}
|
|
126
|
+
};
|
|
127
|
+
}
|
|
128
|
+
},
|
|
129
|
+
"tags:resolve": ({ tagMap, tags }) => {
|
|
130
|
+
const params = tagMap.get("templateParams")?.props || {};
|
|
131
|
+
const sep = params.separator || "|";
|
|
132
|
+
delete params.separator;
|
|
133
|
+
params.pageTitle = processTemplateParams(
|
|
134
|
+
// find templateParams
|
|
135
|
+
params.pageTitle || head._title || "",
|
|
136
|
+
params,
|
|
137
|
+
sep
|
|
138
|
+
);
|
|
139
|
+
for (const tag of tags) {
|
|
140
|
+
if (tag.processTemplateParams === false) {
|
|
141
|
+
continue;
|
|
142
|
+
}
|
|
143
|
+
const v = SupportedAttrs[tag.tag];
|
|
144
|
+
if (v && typeof tag.props[v] === "string") {
|
|
145
|
+
tag.props[v] = processTemplateParams(tag.props[v], params, sep);
|
|
146
|
+
} else if (tag.processTemplateParams || tag.tag === "titleTemplate" || tag.tag === "title") {
|
|
147
|
+
for (const p of contentAttrs) {
|
|
148
|
+
if (typeof tag[p] === "string")
|
|
149
|
+
tag[p] = processTemplateParams(tag[p], params, sep, tag.tag === "script" && tag.props.type.endsWith("json"));
|
|
150
|
+
}
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
head._templateParams = params;
|
|
154
|
+
head._separator = sep;
|
|
155
|
+
},
|
|
156
|
+
"tags:afterResolve": ({ tagMap }) => {
|
|
157
|
+
const title = tagMap.get("title");
|
|
158
|
+
if (title?.textContent && title.processTemplateParams !== false) {
|
|
159
|
+
title.textContent = processTemplateParams(title.textContent, head._templateParams, head._separator);
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
};
|
|
164
|
+
});
|
|
165
|
+
|
|
166
|
+
export { AliasSortingPlugin as A, DeprecationsPlugin as D, PromisesPlugin as P, TemplateParamsPlugin as T };
|