businesslens 0.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.output/nitro.json +15 -0
- package/.output/public/_nuxt/ANTr5GBv.js +1 -0
- package/.output/public/_nuxt/B3Z-Zt7l.js +37 -0
- package/.output/public/_nuxt/Bd76-HGM.js +1 -0
- package/.output/public/_nuxt/Bf4VrETn.js +1 -0
- package/.output/public/_nuxt/CR3jGlpM.js +1 -0
- package/.output/public/_nuxt/CntoM1kL.js +1 -0
- package/.output/public/_nuxt/DogqooqX.js +1 -0
- package/.output/public/_nuxt/Zsu92SSr.js +1 -0
- package/.output/public/_nuxt/builds/latest.json +1 -0
- package/.output/public/_nuxt/builds/meta/e74555da-0c18-4e95-b959-2bdcc538677b.json +1 -0
- package/.output/public/_nuxt/default.CRZmPCG_.css +1 -0
- package/.output/public/_nuxt/e3lOfLH3.js +1 -0
- package/.output/public/_nuxt/entry.SgkJh-3P.css +1 -0
- package/.output/public/_nuxt/error-404.CTIGkQtd.css +1 -0
- package/.output/public/_nuxt/error-500.CKBWIF4V.css +1 -0
- package/.output/public/_nuxt/fCd72uLR.js +1 -0
- package/.output/public/_nuxt/inter-cyrillic-ext-wght-normal.BOeWTOD4.woff2 +0 -0
- package/.output/public/_nuxt/inter-cyrillic-wght-normal.DqGufNeO.woff2 +0 -0
- package/.output/public/_nuxt/inter-greek-ext-wght-normal.DlzME5K_.woff2 +0 -0
- package/.output/public/_nuxt/inter-greek-wght-normal.CkhJZR-_.woff2 +0 -0
- package/.output/public/_nuxt/inter-latin-ext-wght-normal.DO1Apj_S.woff2 +0 -0
- package/.output/public/_nuxt/inter-latin-wght-normal.Dx4kXJAl.woff2 +0 -0
- package/.output/public/_nuxt/inter-vietnamese-wght-normal.CBcvBZtf.woff2 +0 -0
- package/.output/public/_nuxt/vk0fkBN0.js +1 -0
- package/.output/public/_nuxt/zg6VsE4d.js +39 -0
- package/.output/public/brand/logo/businesslens-mark.svg +20 -0
- package/.output/public/favicon.svg +13 -0
- package/.output/server/chunks/_/error-500.mjs +19 -0
- package/.output/server/chunks/_/error-500.mjs.map +1 -0
- package/.output/server/chunks/_/icons.mjs +6150 -0
- package/.output/server/chunks/_/icons.mjs.map +1 -0
- package/.output/server/chunks/build/Card-DJ5Lo0Cn.mjs +161 -0
- package/.output/server/chunks/build/Card-DJ5Lo0Cn.mjs.map +1 -0
- package/.output/server/chunks/build/EntityInspector-fTjbuYoq.mjs +4412 -0
- package/.output/server/chunks/build/EntityInspector-fTjbuYoq.mjs.map +1 -0
- package/.output/server/chunks/build/Slideover-KOfskX1l.mjs +4226 -0
- package/.output/server/chunks/build/Slideover-KOfskX1l.mjs.map +1 -0
- package/.output/server/chunks/build/Tooltip-DkxwLaX6.mjs +1338 -0
- package/.output/server/chunks/build/Tooltip-DkxwLaX6.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-BJSthw3t.mjs +8999 -0
- package/.output/server/chunks/build/default-BJSthw3t.mjs.map +1 -0
- package/.output/server/chunks/build/default-styles.BYgqaNao.mjs +8 -0
- package/.output/server/chunks/build/default-styles.BYgqaNao.mjs.map +1 -0
- package/.output/server/chunks/build/error-404-BOiGLcfP.mjs +96 -0
- package/.output/server/chunks/build/error-404-BOiGLcfP.mjs.map +1 -0
- package/.output/server/chunks/build/error-404-styles.DA-UkGXW.mjs +8 -0
- package/.output/server/chunks/build/error-404-styles.DA-UkGXW.mjs.map +1 -0
- package/.output/server/chunks/build/error-500-Bwyw373t.mjs +79 -0
- package/.output/server/chunks/build/error-500-Bwyw373t.mjs.map +1 -0
- package/.output/server/chunks/build/error-500-styles.De7qbKJ2.mjs +8 -0
- package/.output/server/chunks/build/error-500-styles.De7qbKJ2.mjs.map +1 -0
- package/.output/server/chunks/build/index-BuhKSZfH.mjs +313 -0
- package/.output/server/chunks/build/index-BuhKSZfH.mjs.map +1 -0
- package/.output/server/chunks/build/journeys-DHHOyxCM.mjs +244 -0
- package/.output/server/chunks/build/journeys-DHHOyxCM.mjs.map +1 -0
- package/.output/server/chunks/build/server.mjs +14099 -0
- package/.output/server/chunks/build/server.mjs.map +1 -0
- package/.output/server/chunks/build/styles.mjs +9 -0
- package/.output/server/chunks/build/styles.mjs.map +1 -0
- package/.output/server/chunks/build/topology-BJfDB_jA.mjs +295 -0
- package/.output/server/chunks/build/topology-BJfDB_jA.mjs.map +1 -0
- package/.output/server/chunks/build/useReport-pDAk-ETG.mjs +406 -0
- package/.output/server/chunks/build/useReport-pDAk-ETG.mjs.map +1 -0
- package/.output/server/chunks/nitro/nitro.mjs +5770 -0
- package/.output/server/chunks/nitro/nitro.mjs.map +1 -0
- package/.output/server/chunks/routes/api/report.get.mjs +617 -0
- package/.output/server/chunks/routes/api/report.get.mjs.map +1 -0
- package/.output/server/chunks/routes/renderer.mjs +451 -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/hookable@5.5.3/dist/index.mjs +290 -0
- package/.output/server/node_modules/.nitro/hookable@5.5.3/package.json +49 -0
- package/.output/server/node_modules/.nitro/hookable@6.1.1/dist/index.mjs +257 -0
- package/.output/server/node_modules/.nitro/hookable@6.1.1/package.json +53 -0
- package/.output/server/node_modules/@babel/parser/lib/index.js +14599 -0
- package/.output/server/node_modules/@babel/parser/package.json +50 -0
- package/.output/server/node_modules/@iconify/utils/lib/colors/index.js +295 -0
- package/.output/server/node_modules/@iconify/utils/lib/colors/keywords.js +701 -0
- package/.output/server/node_modules/@iconify/utils/lib/css/common.js +75 -0
- package/.output/server/node_modules/@iconify/utils/lib/css/format.js +39 -0
- package/.output/server/node_modules/@iconify/utils/lib/css/icon.js +47 -0
- package/.output/server/node_modules/@iconify/utils/lib/css/icons.js +128 -0
- package/.output/server/node_modules/@iconify/utils/lib/customisations/bool.js +19 -0
- package/.output/server/node_modules/@iconify/utils/lib/customisations/defaults.js +13 -0
- package/.output/server/node_modules/@iconify/utils/lib/customisations/flip.js +17 -0
- package/.output/server/node_modules/@iconify/utils/lib/customisations/merge.js +16 -0
- package/.output/server/node_modules/@iconify/utils/lib/customisations/rotate.js +30 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/cleanup.js +78 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/convert.js +100 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/data.js +28 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/format.js +58 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/parse.js +48 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/regex/base.js +203 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/regex/create.js +33 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/regex/numbers.js +132 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/regex/similar.js +165 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/regex/tree.js +79 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/replace/find.js +92 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/replace/replace.js +26 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/test/components.js +76 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/test/missing.js +66 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/test/name.js +45 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/test/parse.js +103 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/test/similar.js +36 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/test/tree.js +92 -0
- package/.output/server/node_modules/@iconify/utils/lib/emoji/test/variations.js +62 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon/defaults.js +25 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon/merge.js +16 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon/name.js +57 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon/square.js +33 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon/transformations.js +12 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon-set/convert-info.js +125 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon-set/expand.js +19 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon-set/get-icon.js +25 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon-set/get-icons.js +36 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon-set/minify.js +91 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon-set/parse.js +46 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon-set/tree.js +23 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon-set/validate-basic.js +42 -0
- package/.output/server/node_modules/@iconify/utils/lib/icon-set/validate.js +123 -0
- package/.output/server/node_modules/@iconify/utils/lib/index.js +52 -0
- package/.output/server/node_modules/@iconify/utils/lib/loader/custom.js +30 -0
- package/.output/server/node_modules/@iconify/utils/lib/loader/loader.js +26 -0
- package/.output/server/node_modules/@iconify/utils/lib/loader/modern.js +27 -0
- package/.output/server/node_modules/@iconify/utils/lib/loader/utils.js +105 -0
- package/.output/server/node_modules/@iconify/utils/lib/misc/objects.js +26 -0
- package/.output/server/node_modules/@iconify/utils/lib/misc/strings.js +26 -0
- package/.output/server/node_modules/@iconify/utils/lib/misc/title.js +9 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/build.js +113 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/defs.js +31 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/encode-svg-for-css.js +13 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/html.js +9 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/id.js +41 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/inner-html.js +22 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/parse.js +67 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/pretty.js +54 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/size.js +27 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/trim.js +7 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/url.js +22 -0
- package/.output/server/node_modules/@iconify/utils/lib/svg/viewbox.js +8 -0
- package/.output/server/node_modules/@iconify/utils/package.json +119 -0
- package/.output/server/node_modules/@vue/compiler-core/dist/compiler-core.cjs.prod.js +6759 -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-api/dist/index.js +2 -0
- package/.output/server/node_modules/@vue/devtools-api/package.json +34 -0
- package/.output/server/node_modules/@vue/devtools-kit/dist/index.js +5670 -0
- package/.output/server/node_modules/@vue/devtools-kit/package.json +44 -0
- package/.output/server/node_modules/@vue/devtools-shared/dist/index.js +239 -0
- package/.output/server/node_modules/@vue/devtools-shared/package.json +33 -0
- package/.output/server/node_modules/@vue/reactivity/dist/reactivity.cjs.prod.js +1899 -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 +6940 -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 +1822 -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 +896 -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/@vue-flow/core/dist/vue-flow-core.mjs +10186 -0
- package/.output/server/node_modules/@vue-flow/core/package.json +95 -0
- package/.output/server/node_modules/ajv/dist/2020.js +55 -0
- package/.output/server/node_modules/ajv/dist/ajv.js +50 -0
- package/.output/server/node_modules/ajv/dist/compile/codegen/code.js +156 -0
- package/.output/server/node_modules/ajv/dist/compile/codegen/index.js +697 -0
- package/.output/server/node_modules/ajv/dist/compile/codegen/scope.js +143 -0
- package/.output/server/node_modules/ajv/dist/compile/errors.js +123 -0
- package/.output/server/node_modules/ajv/dist/compile/index.js +242 -0
- package/.output/server/node_modules/ajv/dist/compile/names.js +28 -0
- package/.output/server/node_modules/ajv/dist/compile/ref_error.js +12 -0
- package/.output/server/node_modules/ajv/dist/compile/resolve.js +155 -0
- package/.output/server/node_modules/ajv/dist/compile/rules.js +26 -0
- package/.output/server/node_modules/ajv/dist/compile/util.js +178 -0
- package/.output/server/node_modules/ajv/dist/compile/validate/applicability.js +19 -0
- package/.output/server/node_modules/ajv/dist/compile/validate/boolSchema.js +50 -0
- package/.output/server/node_modules/ajv/dist/compile/validate/dataType.js +203 -0
- package/.output/server/node_modules/ajv/dist/compile/validate/defaults.js +35 -0
- package/.output/server/node_modules/ajv/dist/compile/validate/index.js +520 -0
- package/.output/server/node_modules/ajv/dist/compile/validate/keyword.js +124 -0
- package/.output/server/node_modules/ajv/dist/compile/validate/subschema.js +81 -0
- package/.output/server/node_modules/ajv/dist/core.js +618 -0
- package/.output/server/node_modules/ajv/dist/refs/data.json +13 -0
- package/.output/server/node_modules/ajv/dist/refs/json-schema-2020-12/index.js +30 -0
- package/.output/server/node_modules/ajv/dist/refs/json-schema-2020-12/meta/applicator.json +48 -0
- package/.output/server/node_modules/ajv/dist/refs/json-schema-2020-12/meta/content.json +17 -0
- package/.output/server/node_modules/ajv/dist/refs/json-schema-2020-12/meta/core.json +51 -0
- package/.output/server/node_modules/ajv/dist/refs/json-schema-2020-12/meta/format-annotation.json +14 -0
- package/.output/server/node_modules/ajv/dist/refs/json-schema-2020-12/meta/meta-data.json +37 -0
- package/.output/server/node_modules/ajv/dist/refs/json-schema-2020-12/meta/unevaluated.json +15 -0
- package/.output/server/node_modules/ajv/dist/refs/json-schema-2020-12/meta/validation.json +90 -0
- package/.output/server/node_modules/ajv/dist/refs/json-schema-2020-12/schema.json +55 -0
- package/.output/server/node_modules/ajv/dist/refs/json-schema-draft-07.json +151 -0
- package/.output/server/node_modules/ajv/dist/runtime/equal.js +7 -0
- package/.output/server/node_modules/ajv/dist/runtime/ucs2length.js +24 -0
- package/.output/server/node_modules/ajv/dist/runtime/uri.js +6 -0
- package/.output/server/node_modules/ajv/dist/runtime/validation_error.js +11 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/applicator/additionalItems.js +49 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/applicator/additionalProperties.js +106 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/applicator/allOf.js +23 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/applicator/anyOf.js +12 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/applicator/contains.js +95 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/applicator/dependencies.js +85 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/applicator/dependentSchemas.js +11 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/applicator/if.js +66 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/applicator/index.js +44 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/applicator/items.js +52 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/applicator/items2020.js +30 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/applicator/not.js +26 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/applicator/oneOf.js +60 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/applicator/patternProperties.js +75 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/applicator/prefixItems.js +12 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/applicator/properties.js +54 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/applicator/propertyNames.js +38 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/applicator/thenElse.js +13 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/code.js +131 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/core/id.js +10 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/core/index.js +16 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/core/ref.js +122 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/discriminator/index.js +104 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/discriminator/types.js +9 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/draft2020.js +23 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/draft7.js +17 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/dynamic/dynamicAnchor.js +30 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/dynamic/dynamicRef.js +51 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/dynamic/index.js +9 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/dynamic/recursiveAnchor.js +16 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/dynamic/recursiveRef.js +10 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/format/format.js +92 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/format/index.js +6 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/metadata.js +18 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/next.js +8 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/unevaluated/index.js +7 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/unevaluated/unevaluatedItems.js +40 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/unevaluated/unevaluatedProperties.js +65 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/validation/const.js +25 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/validation/dependentRequired.js +12 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/validation/enum.js +48 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/validation/index.js +33 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/validation/limitContains.js +15 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/validation/limitItems.js +24 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/validation/limitLength.js +27 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/validation/limitNumber.js +27 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/validation/limitProperties.js +24 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/validation/multipleOf.js +26 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/validation/pattern.js +24 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/validation/required.js +79 -0
- package/.output/server/node_modules/ajv/dist/vocabularies/validation/uniqueItems.js +64 -0
- package/.output/server/node_modules/ajv/package.json +126 -0
- package/.output/server/node_modules/ajv-formats/dist/formats.js +208 -0
- package/.output/server/node_modules/ajv-formats/dist/index.js +37 -0
- package/.output/server/node_modules/ajv-formats/dist/limit.js +69 -0
- package/.output/server/node_modules/ajv-formats/package.json +74 -0
- package/.output/server/node_modules/birpc/dist/index.mjs +291 -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 +40 -0
- package/.output/server/node_modules/devalue/src/base64.js +60 -0
- package/.output/server/node_modules/devalue/src/constants.js +12 -0
- package/.output/server/node_modules/devalue/src/parse.js +283 -0
- package/.output/server/node_modules/devalue/src/stringify.js +401 -0
- package/.output/server/node_modules/devalue/src/uneval.js +552 -0
- package/.output/server/node_modules/devalue/src/utils.js +160 -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/fast-deep-equal/index.js +46 -0
- package/.output/server/node_modules/fast-deep-equal/package.json +61 -0
- package/.output/server/node_modules/fast-uri/index.js +406 -0
- package/.output/server/node_modules/fast-uri/lib/schemes.js +267 -0
- package/.output/server/node_modules/fast-uri/lib/utils.js +443 -0
- package/.output/server/node_modules/fast-uri/package.json +68 -0
- package/.output/server/node_modules/json-schema-traverse/index.js +93 -0
- package/.output/server/node_modules/json-schema-traverse/package.json +43 -0
- package/.output/server/node_modules/perfect-debounce/dist/index.mjs +89 -0
- package/.output/server/node_modules/perfect-debounce/package.json +41 -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.B3VbJo7Y.mjs +207 -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.CaI5ZD4O.mjs +182 -0
- package/.output/server/node_modules/unhead/dist/shared/unhead.CbpEuj3y.mjs +71 -0
- package/.output/server/node_modules/unhead/dist/shared/unhead.D4vSFytZ.mjs +236 -0
- package/.output/server/node_modules/unhead/dist/shared/unhead.DQc16pHI.mjs +196 -0
- package/.output/server/node_modules/unhead/dist/shared/unhead.Dh1cQCTe.mjs +44 -0
- package/.output/server/node_modules/unhead/dist/shared/unhead.TxTMM7cM.mjs +166 -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 +249 -0
- package/.output/server/node_modules/vue-bundle-renderer/package.json +57 -0
- package/.output/server/node_modules/vue-router/dist/devtools-DCoWQoU_.js +1034 -0
- package/.output/server/node_modules/vue-router/dist/useApi-s_02lHjl.js +181 -0
- package/.output/server/node_modules/vue-router/dist/vue-router.js +1499 -0
- package/.output/server/node_modules/vue-router/package.json +226 -0
- package/.output/server/node_modules/vue-router/vue-router.node.mjs +2 -0
- package/.output/server/package.json +41 -0
- package/README.md +114 -0
- package/THIRD_PARTY_NOTICES.md +28 -0
- package/bin/businesslens.mjs +181 -0
- package/package.json +68 -0
- package/packages/report-schema/schemas/report.schema.json +235 -0
- package/packages/report-schema/types/index.ts +1 -0
- package/packages/report-schema/types/report.ts +101 -0
- package/packages/report-schema/validate.mjs +111 -0
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ValueScope = exports.ValueScopeName = exports.Scope = exports.varKinds = exports.UsedValueState = void 0;
|
|
4
|
+
const code_1 = require("./code");
|
|
5
|
+
class ValueError extends Error {
|
|
6
|
+
constructor(name) {
|
|
7
|
+
super(`CodeGen: "code" for ${name} not defined`);
|
|
8
|
+
this.value = name.value;
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
var UsedValueState;
|
|
12
|
+
(function (UsedValueState) {
|
|
13
|
+
UsedValueState[UsedValueState["Started"] = 0] = "Started";
|
|
14
|
+
UsedValueState[UsedValueState["Completed"] = 1] = "Completed";
|
|
15
|
+
})(UsedValueState || (exports.UsedValueState = UsedValueState = {}));
|
|
16
|
+
exports.varKinds = {
|
|
17
|
+
const: new code_1.Name("const"),
|
|
18
|
+
let: new code_1.Name("let"),
|
|
19
|
+
var: new code_1.Name("var"),
|
|
20
|
+
};
|
|
21
|
+
class Scope {
|
|
22
|
+
constructor({ prefixes, parent } = {}) {
|
|
23
|
+
this._names = {};
|
|
24
|
+
this._prefixes = prefixes;
|
|
25
|
+
this._parent = parent;
|
|
26
|
+
}
|
|
27
|
+
toName(nameOrPrefix) {
|
|
28
|
+
return nameOrPrefix instanceof code_1.Name ? nameOrPrefix : this.name(nameOrPrefix);
|
|
29
|
+
}
|
|
30
|
+
name(prefix) {
|
|
31
|
+
return new code_1.Name(this._newName(prefix));
|
|
32
|
+
}
|
|
33
|
+
_newName(prefix) {
|
|
34
|
+
const ng = this._names[prefix] || this._nameGroup(prefix);
|
|
35
|
+
return `${prefix}${ng.index++}`;
|
|
36
|
+
}
|
|
37
|
+
_nameGroup(prefix) {
|
|
38
|
+
var _a, _b;
|
|
39
|
+
if (((_b = (_a = this._parent) === null || _a === void 0 ? void 0 : _a._prefixes) === null || _b === void 0 ? void 0 : _b.has(prefix)) || (this._prefixes && !this._prefixes.has(prefix))) {
|
|
40
|
+
throw new Error(`CodeGen: prefix "${prefix}" is not allowed in this scope`);
|
|
41
|
+
}
|
|
42
|
+
return (this._names[prefix] = { prefix, index: 0 });
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
exports.Scope = Scope;
|
|
46
|
+
class ValueScopeName extends code_1.Name {
|
|
47
|
+
constructor(prefix, nameStr) {
|
|
48
|
+
super(nameStr);
|
|
49
|
+
this.prefix = prefix;
|
|
50
|
+
}
|
|
51
|
+
setValue(value, { property, itemIndex }) {
|
|
52
|
+
this.value = value;
|
|
53
|
+
this.scopePath = (0, code_1._) `.${new code_1.Name(property)}[${itemIndex}]`;
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
exports.ValueScopeName = ValueScopeName;
|
|
57
|
+
const line = (0, code_1._) `\n`;
|
|
58
|
+
class ValueScope extends Scope {
|
|
59
|
+
constructor(opts) {
|
|
60
|
+
super(opts);
|
|
61
|
+
this._values = {};
|
|
62
|
+
this._scope = opts.scope;
|
|
63
|
+
this.opts = { ...opts, _n: opts.lines ? line : code_1.nil };
|
|
64
|
+
}
|
|
65
|
+
get() {
|
|
66
|
+
return this._scope;
|
|
67
|
+
}
|
|
68
|
+
name(prefix) {
|
|
69
|
+
return new ValueScopeName(prefix, this._newName(prefix));
|
|
70
|
+
}
|
|
71
|
+
value(nameOrPrefix, value) {
|
|
72
|
+
var _a;
|
|
73
|
+
if (value.ref === undefined)
|
|
74
|
+
throw new Error("CodeGen: ref must be passed in value");
|
|
75
|
+
const name = this.toName(nameOrPrefix);
|
|
76
|
+
const { prefix } = name;
|
|
77
|
+
const valueKey = (_a = value.key) !== null && _a !== void 0 ? _a : value.ref;
|
|
78
|
+
let vs = this._values[prefix];
|
|
79
|
+
if (vs) {
|
|
80
|
+
const _name = vs.get(valueKey);
|
|
81
|
+
if (_name)
|
|
82
|
+
return _name;
|
|
83
|
+
}
|
|
84
|
+
else {
|
|
85
|
+
vs = this._values[prefix] = new Map();
|
|
86
|
+
}
|
|
87
|
+
vs.set(valueKey, name);
|
|
88
|
+
const s = this._scope[prefix] || (this._scope[prefix] = []);
|
|
89
|
+
const itemIndex = s.length;
|
|
90
|
+
s[itemIndex] = value.ref;
|
|
91
|
+
name.setValue(value, { property: prefix, itemIndex });
|
|
92
|
+
return name;
|
|
93
|
+
}
|
|
94
|
+
getValue(prefix, keyOrRef) {
|
|
95
|
+
const vs = this._values[prefix];
|
|
96
|
+
if (!vs)
|
|
97
|
+
return;
|
|
98
|
+
return vs.get(keyOrRef);
|
|
99
|
+
}
|
|
100
|
+
scopeRefs(scopeName, values = this._values) {
|
|
101
|
+
return this._reduceValues(values, (name) => {
|
|
102
|
+
if (name.scopePath === undefined)
|
|
103
|
+
throw new Error(`CodeGen: name "${name}" has no value`);
|
|
104
|
+
return (0, code_1._) `${scopeName}${name.scopePath}`;
|
|
105
|
+
});
|
|
106
|
+
}
|
|
107
|
+
scopeCode(values = this._values, usedValues, getCode) {
|
|
108
|
+
return this._reduceValues(values, (name) => {
|
|
109
|
+
if (name.value === undefined)
|
|
110
|
+
throw new Error(`CodeGen: name "${name}" has no value`);
|
|
111
|
+
return name.value.code;
|
|
112
|
+
}, usedValues, getCode);
|
|
113
|
+
}
|
|
114
|
+
_reduceValues(values, valueCode, usedValues = {}, getCode) {
|
|
115
|
+
let code = code_1.nil;
|
|
116
|
+
for (const prefix in values) {
|
|
117
|
+
const vs = values[prefix];
|
|
118
|
+
if (!vs)
|
|
119
|
+
continue;
|
|
120
|
+
const nameSet = (usedValues[prefix] = usedValues[prefix] || new Map());
|
|
121
|
+
vs.forEach((name) => {
|
|
122
|
+
if (nameSet.has(name))
|
|
123
|
+
return;
|
|
124
|
+
nameSet.set(name, UsedValueState.Started);
|
|
125
|
+
let c = valueCode(name);
|
|
126
|
+
if (c) {
|
|
127
|
+
const def = this.opts.es5 ? exports.varKinds.var : exports.varKinds.const;
|
|
128
|
+
code = (0, code_1._) `${code}${def} ${name} = ${c};${this.opts._n}`;
|
|
129
|
+
}
|
|
130
|
+
else if ((c = getCode === null || getCode === void 0 ? void 0 : getCode(name))) {
|
|
131
|
+
code = (0, code_1._) `${code}${c}${this.opts._n}`;
|
|
132
|
+
}
|
|
133
|
+
else {
|
|
134
|
+
throw new ValueError(name);
|
|
135
|
+
}
|
|
136
|
+
nameSet.set(name, UsedValueState.Completed);
|
|
137
|
+
});
|
|
138
|
+
}
|
|
139
|
+
return code;
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
exports.ValueScope = ValueScope;
|
|
143
|
+
//# sourceMappingURL=scope.js.map
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.extendErrors = exports.resetErrorsCount = exports.reportExtraError = exports.reportError = exports.keyword$DataError = exports.keywordError = void 0;
|
|
4
|
+
const codegen_1 = require("./codegen");
|
|
5
|
+
const util_1 = require("./util");
|
|
6
|
+
const names_1 = require("./names");
|
|
7
|
+
exports.keywordError = {
|
|
8
|
+
message: ({ keyword }) => (0, codegen_1.str) `must pass "${keyword}" keyword validation`,
|
|
9
|
+
};
|
|
10
|
+
exports.keyword$DataError = {
|
|
11
|
+
message: ({ keyword, schemaType }) => schemaType
|
|
12
|
+
? (0, codegen_1.str) `"${keyword}" keyword must be ${schemaType} ($data)`
|
|
13
|
+
: (0, codegen_1.str) `"${keyword}" keyword is invalid ($data)`,
|
|
14
|
+
};
|
|
15
|
+
function reportError(cxt, error = exports.keywordError, errorPaths, overrideAllErrors) {
|
|
16
|
+
const { it } = cxt;
|
|
17
|
+
const { gen, compositeRule, allErrors } = it;
|
|
18
|
+
const errObj = errorObjectCode(cxt, error, errorPaths);
|
|
19
|
+
if (overrideAllErrors !== null && overrideAllErrors !== void 0 ? overrideAllErrors : (compositeRule || allErrors)) {
|
|
20
|
+
addError(gen, errObj);
|
|
21
|
+
}
|
|
22
|
+
else {
|
|
23
|
+
returnErrors(it, (0, codegen_1._) `[${errObj}]`);
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
exports.reportError = reportError;
|
|
27
|
+
function reportExtraError(cxt, error = exports.keywordError, errorPaths) {
|
|
28
|
+
const { it } = cxt;
|
|
29
|
+
const { gen, compositeRule, allErrors } = it;
|
|
30
|
+
const errObj = errorObjectCode(cxt, error, errorPaths);
|
|
31
|
+
addError(gen, errObj);
|
|
32
|
+
if (!(compositeRule || allErrors)) {
|
|
33
|
+
returnErrors(it, names_1.default.vErrors);
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
exports.reportExtraError = reportExtraError;
|
|
37
|
+
function resetErrorsCount(gen, errsCount) {
|
|
38
|
+
gen.assign(names_1.default.errors, errsCount);
|
|
39
|
+
gen.if((0, codegen_1._) `${names_1.default.vErrors} !== null`, () => gen.if(errsCount, () => gen.assign((0, codegen_1._) `${names_1.default.vErrors}.length`, errsCount), () => gen.assign(names_1.default.vErrors, null)));
|
|
40
|
+
}
|
|
41
|
+
exports.resetErrorsCount = resetErrorsCount;
|
|
42
|
+
function extendErrors({ gen, keyword, schemaValue, data, errsCount, it, }) {
|
|
43
|
+
/* istanbul ignore if */
|
|
44
|
+
if (errsCount === undefined)
|
|
45
|
+
throw new Error("ajv implementation error");
|
|
46
|
+
const err = gen.name("err");
|
|
47
|
+
gen.forRange("i", errsCount, names_1.default.errors, (i) => {
|
|
48
|
+
gen.const(err, (0, codegen_1._) `${names_1.default.vErrors}[${i}]`);
|
|
49
|
+
gen.if((0, codegen_1._) `${err}.instancePath === undefined`, () => gen.assign((0, codegen_1._) `${err}.instancePath`, (0, codegen_1.strConcat)(names_1.default.instancePath, it.errorPath)));
|
|
50
|
+
gen.assign((0, codegen_1._) `${err}.schemaPath`, (0, codegen_1.str) `${it.errSchemaPath}/${keyword}`);
|
|
51
|
+
if (it.opts.verbose) {
|
|
52
|
+
gen.assign((0, codegen_1._) `${err}.schema`, schemaValue);
|
|
53
|
+
gen.assign((0, codegen_1._) `${err}.data`, data);
|
|
54
|
+
}
|
|
55
|
+
});
|
|
56
|
+
}
|
|
57
|
+
exports.extendErrors = extendErrors;
|
|
58
|
+
function addError(gen, errObj) {
|
|
59
|
+
const err = gen.const("err", errObj);
|
|
60
|
+
gen.if((0, codegen_1._) `${names_1.default.vErrors} === null`, () => gen.assign(names_1.default.vErrors, (0, codegen_1._) `[${err}]`), (0, codegen_1._) `${names_1.default.vErrors}.push(${err})`);
|
|
61
|
+
gen.code((0, codegen_1._) `${names_1.default.errors}++`);
|
|
62
|
+
}
|
|
63
|
+
function returnErrors(it, errs) {
|
|
64
|
+
const { gen, validateName, schemaEnv } = it;
|
|
65
|
+
if (schemaEnv.$async) {
|
|
66
|
+
gen.throw((0, codegen_1._) `new ${it.ValidationError}(${errs})`);
|
|
67
|
+
}
|
|
68
|
+
else {
|
|
69
|
+
gen.assign((0, codegen_1._) `${validateName}.errors`, errs);
|
|
70
|
+
gen.return(false);
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
const E = {
|
|
74
|
+
keyword: new codegen_1.Name("keyword"),
|
|
75
|
+
schemaPath: new codegen_1.Name("schemaPath"), // also used in JTD errors
|
|
76
|
+
params: new codegen_1.Name("params"),
|
|
77
|
+
propertyName: new codegen_1.Name("propertyName"),
|
|
78
|
+
message: new codegen_1.Name("message"),
|
|
79
|
+
schema: new codegen_1.Name("schema"),
|
|
80
|
+
parentSchema: new codegen_1.Name("parentSchema"),
|
|
81
|
+
};
|
|
82
|
+
function errorObjectCode(cxt, error, errorPaths) {
|
|
83
|
+
const { createErrors } = cxt.it;
|
|
84
|
+
if (createErrors === false)
|
|
85
|
+
return (0, codegen_1._) `{}`;
|
|
86
|
+
return errorObject(cxt, error, errorPaths);
|
|
87
|
+
}
|
|
88
|
+
function errorObject(cxt, error, errorPaths = {}) {
|
|
89
|
+
const { gen, it } = cxt;
|
|
90
|
+
const keyValues = [
|
|
91
|
+
errorInstancePath(it, errorPaths),
|
|
92
|
+
errorSchemaPath(cxt, errorPaths),
|
|
93
|
+
];
|
|
94
|
+
extraErrorProps(cxt, error, keyValues);
|
|
95
|
+
return gen.object(...keyValues);
|
|
96
|
+
}
|
|
97
|
+
function errorInstancePath({ errorPath }, { instancePath }) {
|
|
98
|
+
const instPath = instancePath
|
|
99
|
+
? (0, codegen_1.str) `${errorPath}${(0, util_1.getErrorPath)(instancePath, util_1.Type.Str)}`
|
|
100
|
+
: errorPath;
|
|
101
|
+
return [names_1.default.instancePath, (0, codegen_1.strConcat)(names_1.default.instancePath, instPath)];
|
|
102
|
+
}
|
|
103
|
+
function errorSchemaPath({ keyword, it: { errSchemaPath } }, { schemaPath, parentSchema }) {
|
|
104
|
+
let schPath = parentSchema ? errSchemaPath : (0, codegen_1.str) `${errSchemaPath}/${keyword}`;
|
|
105
|
+
if (schemaPath) {
|
|
106
|
+
schPath = (0, codegen_1.str) `${schPath}${(0, util_1.getErrorPath)(schemaPath, util_1.Type.Str)}`;
|
|
107
|
+
}
|
|
108
|
+
return [E.schemaPath, schPath];
|
|
109
|
+
}
|
|
110
|
+
function extraErrorProps(cxt, { params, message }, keyValues) {
|
|
111
|
+
const { keyword, data, schemaValue, it } = cxt;
|
|
112
|
+
const { opts, propertyName, topSchemaRef, schemaPath } = it;
|
|
113
|
+
keyValues.push([E.keyword, keyword], [E.params, typeof params == "function" ? params(cxt) : params || (0, codegen_1._) `{}`]);
|
|
114
|
+
if (opts.messages) {
|
|
115
|
+
keyValues.push([E.message, typeof message == "function" ? message(cxt) : message]);
|
|
116
|
+
}
|
|
117
|
+
if (opts.verbose) {
|
|
118
|
+
keyValues.push([E.schema, schemaValue], [E.parentSchema, (0, codegen_1._) `${topSchemaRef}${schemaPath}`], [names_1.default.data, data]);
|
|
119
|
+
}
|
|
120
|
+
if (propertyName)
|
|
121
|
+
keyValues.push([E.propertyName, propertyName]);
|
|
122
|
+
}
|
|
123
|
+
//# sourceMappingURL=errors.js.map
|
|
@@ -0,0 +1,242 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.resolveSchema = exports.getCompilingSchema = exports.resolveRef = exports.compileSchema = exports.SchemaEnv = void 0;
|
|
4
|
+
const codegen_1 = require("./codegen");
|
|
5
|
+
const validation_error_1 = require("../runtime/validation_error");
|
|
6
|
+
const names_1 = require("./names");
|
|
7
|
+
const resolve_1 = require("./resolve");
|
|
8
|
+
const util_1 = require("./util");
|
|
9
|
+
const validate_1 = require("./validate");
|
|
10
|
+
class SchemaEnv {
|
|
11
|
+
constructor(env) {
|
|
12
|
+
var _a;
|
|
13
|
+
this.refs = {};
|
|
14
|
+
this.dynamicAnchors = {};
|
|
15
|
+
let schema;
|
|
16
|
+
if (typeof env.schema == "object")
|
|
17
|
+
schema = env.schema;
|
|
18
|
+
this.schema = env.schema;
|
|
19
|
+
this.schemaId = env.schemaId;
|
|
20
|
+
this.root = env.root || this;
|
|
21
|
+
this.baseId = (_a = env.baseId) !== null && _a !== void 0 ? _a : (0, resolve_1.normalizeId)(schema === null || schema === void 0 ? void 0 : schema[env.schemaId || "$id"]);
|
|
22
|
+
this.schemaPath = env.schemaPath;
|
|
23
|
+
this.localRefs = env.localRefs;
|
|
24
|
+
this.meta = env.meta;
|
|
25
|
+
this.$async = schema === null || schema === void 0 ? void 0 : schema.$async;
|
|
26
|
+
this.refs = {};
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
exports.SchemaEnv = SchemaEnv;
|
|
30
|
+
// let codeSize = 0
|
|
31
|
+
// let nodeCount = 0
|
|
32
|
+
// Compiles schema in SchemaEnv
|
|
33
|
+
function compileSchema(sch) {
|
|
34
|
+
// TODO refactor - remove compilations
|
|
35
|
+
const _sch = getCompilingSchema.call(this, sch);
|
|
36
|
+
if (_sch)
|
|
37
|
+
return _sch;
|
|
38
|
+
const rootId = (0, resolve_1.getFullPath)(this.opts.uriResolver, sch.root.baseId); // TODO if getFullPath removed 1 tests fails
|
|
39
|
+
const { es5, lines } = this.opts.code;
|
|
40
|
+
const { ownProperties } = this.opts;
|
|
41
|
+
const gen = new codegen_1.CodeGen(this.scope, { es5, lines, ownProperties });
|
|
42
|
+
let _ValidationError;
|
|
43
|
+
if (sch.$async) {
|
|
44
|
+
_ValidationError = gen.scopeValue("Error", {
|
|
45
|
+
ref: validation_error_1.default,
|
|
46
|
+
code: (0, codegen_1._) `require("ajv/dist/runtime/validation_error").default`,
|
|
47
|
+
});
|
|
48
|
+
}
|
|
49
|
+
const validateName = gen.scopeName("validate");
|
|
50
|
+
sch.validateName = validateName;
|
|
51
|
+
const schemaCxt = {
|
|
52
|
+
gen,
|
|
53
|
+
allErrors: this.opts.allErrors,
|
|
54
|
+
data: names_1.default.data,
|
|
55
|
+
parentData: names_1.default.parentData,
|
|
56
|
+
parentDataProperty: names_1.default.parentDataProperty,
|
|
57
|
+
dataNames: [names_1.default.data],
|
|
58
|
+
dataPathArr: [codegen_1.nil], // TODO can its length be used as dataLevel if nil is removed?
|
|
59
|
+
dataLevel: 0,
|
|
60
|
+
dataTypes: [],
|
|
61
|
+
definedProperties: new Set(),
|
|
62
|
+
topSchemaRef: gen.scopeValue("schema", this.opts.code.source === true
|
|
63
|
+
? { ref: sch.schema, code: (0, codegen_1.stringify)(sch.schema) }
|
|
64
|
+
: { ref: sch.schema }),
|
|
65
|
+
validateName,
|
|
66
|
+
ValidationError: _ValidationError,
|
|
67
|
+
schema: sch.schema,
|
|
68
|
+
schemaEnv: sch,
|
|
69
|
+
rootId,
|
|
70
|
+
baseId: sch.baseId || rootId,
|
|
71
|
+
schemaPath: codegen_1.nil,
|
|
72
|
+
errSchemaPath: sch.schemaPath || (this.opts.jtd ? "" : "#"),
|
|
73
|
+
errorPath: (0, codegen_1._) `""`,
|
|
74
|
+
opts: this.opts,
|
|
75
|
+
self: this,
|
|
76
|
+
};
|
|
77
|
+
let sourceCode;
|
|
78
|
+
try {
|
|
79
|
+
this._compilations.add(sch);
|
|
80
|
+
(0, validate_1.validateFunctionCode)(schemaCxt);
|
|
81
|
+
gen.optimize(this.opts.code.optimize);
|
|
82
|
+
// gen.optimize(1)
|
|
83
|
+
const validateCode = gen.toString();
|
|
84
|
+
sourceCode = `${gen.scopeRefs(names_1.default.scope)}return ${validateCode}`;
|
|
85
|
+
// console.log((codeSize += sourceCode.length), (nodeCount += gen.nodeCount))
|
|
86
|
+
if (this.opts.code.process)
|
|
87
|
+
sourceCode = this.opts.code.process(sourceCode, sch);
|
|
88
|
+
// console.log("\n\n\n *** \n", sourceCode)
|
|
89
|
+
const makeValidate = new Function(`${names_1.default.self}`, `${names_1.default.scope}`, sourceCode);
|
|
90
|
+
const validate = makeValidate(this, this.scope.get());
|
|
91
|
+
this.scope.value(validateName, { ref: validate });
|
|
92
|
+
validate.errors = null;
|
|
93
|
+
validate.schema = sch.schema;
|
|
94
|
+
validate.schemaEnv = sch;
|
|
95
|
+
if (sch.$async)
|
|
96
|
+
validate.$async = true;
|
|
97
|
+
if (this.opts.code.source === true) {
|
|
98
|
+
validate.source = { validateName, validateCode, scopeValues: gen._values };
|
|
99
|
+
}
|
|
100
|
+
if (this.opts.unevaluated) {
|
|
101
|
+
const { props, items } = schemaCxt;
|
|
102
|
+
validate.evaluated = {
|
|
103
|
+
props: props instanceof codegen_1.Name ? undefined : props,
|
|
104
|
+
items: items instanceof codegen_1.Name ? undefined : items,
|
|
105
|
+
dynamicProps: props instanceof codegen_1.Name,
|
|
106
|
+
dynamicItems: items instanceof codegen_1.Name,
|
|
107
|
+
};
|
|
108
|
+
if (validate.source)
|
|
109
|
+
validate.source.evaluated = (0, codegen_1.stringify)(validate.evaluated);
|
|
110
|
+
}
|
|
111
|
+
sch.validate = validate;
|
|
112
|
+
return sch;
|
|
113
|
+
}
|
|
114
|
+
catch (e) {
|
|
115
|
+
delete sch.validate;
|
|
116
|
+
delete sch.validateName;
|
|
117
|
+
if (sourceCode)
|
|
118
|
+
this.logger.error("Error compiling schema, function code:", sourceCode);
|
|
119
|
+
// console.log("\n\n\n *** \n", sourceCode, this.opts)
|
|
120
|
+
throw e;
|
|
121
|
+
}
|
|
122
|
+
finally {
|
|
123
|
+
this._compilations.delete(sch);
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
exports.compileSchema = compileSchema;
|
|
127
|
+
function resolveRef(root, baseId, ref) {
|
|
128
|
+
var _a;
|
|
129
|
+
ref = (0, resolve_1.resolveUrl)(this.opts.uriResolver, baseId, ref);
|
|
130
|
+
const schOrFunc = root.refs[ref];
|
|
131
|
+
if (schOrFunc)
|
|
132
|
+
return schOrFunc;
|
|
133
|
+
let _sch = resolve.call(this, root, ref);
|
|
134
|
+
if (_sch === undefined) {
|
|
135
|
+
const schema = (_a = root.localRefs) === null || _a === void 0 ? void 0 : _a[ref]; // TODO maybe localRefs should hold SchemaEnv
|
|
136
|
+
const { schemaId } = this.opts;
|
|
137
|
+
if (schema)
|
|
138
|
+
_sch = new SchemaEnv({ schema, schemaId, root, baseId });
|
|
139
|
+
}
|
|
140
|
+
if (_sch === undefined)
|
|
141
|
+
return;
|
|
142
|
+
return (root.refs[ref] = inlineOrCompile.call(this, _sch));
|
|
143
|
+
}
|
|
144
|
+
exports.resolveRef = resolveRef;
|
|
145
|
+
function inlineOrCompile(sch) {
|
|
146
|
+
if ((0, resolve_1.inlineRef)(sch.schema, this.opts.inlineRefs))
|
|
147
|
+
return sch.schema;
|
|
148
|
+
return sch.validate ? sch : compileSchema.call(this, sch);
|
|
149
|
+
}
|
|
150
|
+
// Index of schema compilation in the currently compiled list
|
|
151
|
+
function getCompilingSchema(schEnv) {
|
|
152
|
+
for (const sch of this._compilations) {
|
|
153
|
+
if (sameSchemaEnv(sch, schEnv))
|
|
154
|
+
return sch;
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
exports.getCompilingSchema = getCompilingSchema;
|
|
158
|
+
function sameSchemaEnv(s1, s2) {
|
|
159
|
+
return s1.schema === s2.schema && s1.root === s2.root && s1.baseId === s2.baseId;
|
|
160
|
+
}
|
|
161
|
+
// resolve and compile the references ($ref)
|
|
162
|
+
// TODO returns AnySchemaObject (if the schema can be inlined) or validation function
|
|
163
|
+
function resolve(root, // information about the root schema for the current schema
|
|
164
|
+
ref // reference to resolve
|
|
165
|
+
) {
|
|
166
|
+
let sch;
|
|
167
|
+
while (typeof (sch = this.refs[ref]) == "string")
|
|
168
|
+
ref = sch;
|
|
169
|
+
return sch || this.schemas[ref] || resolveSchema.call(this, root, ref);
|
|
170
|
+
}
|
|
171
|
+
// Resolve schema, its root and baseId
|
|
172
|
+
function resolveSchema(root, // root object with properties schema, refs TODO below SchemaEnv is assigned to it
|
|
173
|
+
ref // reference to resolve
|
|
174
|
+
) {
|
|
175
|
+
const p = this.opts.uriResolver.parse(ref);
|
|
176
|
+
const refPath = (0, resolve_1._getFullPath)(this.opts.uriResolver, p);
|
|
177
|
+
let baseId = (0, resolve_1.getFullPath)(this.opts.uriResolver, root.baseId, undefined);
|
|
178
|
+
// TODO `Object.keys(root.schema).length > 0` should not be needed - but removing breaks 2 tests
|
|
179
|
+
if (Object.keys(root.schema).length > 0 && refPath === baseId) {
|
|
180
|
+
return getJsonPointer.call(this, p, root);
|
|
181
|
+
}
|
|
182
|
+
const id = (0, resolve_1.normalizeId)(refPath);
|
|
183
|
+
const schOrRef = this.refs[id] || this.schemas[id];
|
|
184
|
+
if (typeof schOrRef == "string") {
|
|
185
|
+
const sch = resolveSchema.call(this, root, schOrRef);
|
|
186
|
+
if (typeof (sch === null || sch === void 0 ? void 0 : sch.schema) !== "object")
|
|
187
|
+
return;
|
|
188
|
+
return getJsonPointer.call(this, p, sch);
|
|
189
|
+
}
|
|
190
|
+
if (typeof (schOrRef === null || schOrRef === void 0 ? void 0 : schOrRef.schema) !== "object")
|
|
191
|
+
return;
|
|
192
|
+
if (!schOrRef.validate)
|
|
193
|
+
compileSchema.call(this, schOrRef);
|
|
194
|
+
if (id === (0, resolve_1.normalizeId)(ref)) {
|
|
195
|
+
const { schema } = schOrRef;
|
|
196
|
+
const { schemaId } = this.opts;
|
|
197
|
+
const schId = schema[schemaId];
|
|
198
|
+
if (schId)
|
|
199
|
+
baseId = (0, resolve_1.resolveUrl)(this.opts.uriResolver, baseId, schId);
|
|
200
|
+
return new SchemaEnv({ schema, schemaId, root, baseId });
|
|
201
|
+
}
|
|
202
|
+
return getJsonPointer.call(this, p, schOrRef);
|
|
203
|
+
}
|
|
204
|
+
exports.resolveSchema = resolveSchema;
|
|
205
|
+
const PREVENT_SCOPE_CHANGE = new Set([
|
|
206
|
+
"properties",
|
|
207
|
+
"patternProperties",
|
|
208
|
+
"enum",
|
|
209
|
+
"dependencies",
|
|
210
|
+
"definitions",
|
|
211
|
+
]);
|
|
212
|
+
function getJsonPointer(parsedRef, { baseId, schema, root }) {
|
|
213
|
+
var _a;
|
|
214
|
+
if (((_a = parsedRef.fragment) === null || _a === void 0 ? void 0 : _a[0]) !== "/")
|
|
215
|
+
return;
|
|
216
|
+
for (const part of parsedRef.fragment.slice(1).split("/")) {
|
|
217
|
+
if (typeof schema === "boolean")
|
|
218
|
+
return;
|
|
219
|
+
const partSchema = schema[(0, util_1.unescapeFragment)(part)];
|
|
220
|
+
if (partSchema === undefined)
|
|
221
|
+
return;
|
|
222
|
+
schema = partSchema;
|
|
223
|
+
// TODO PREVENT_SCOPE_CHANGE could be defined in keyword def?
|
|
224
|
+
const schId = typeof schema === "object" && schema[this.opts.schemaId];
|
|
225
|
+
if (!PREVENT_SCOPE_CHANGE.has(part) && schId) {
|
|
226
|
+
baseId = (0, resolve_1.resolveUrl)(this.opts.uriResolver, baseId, schId);
|
|
227
|
+
}
|
|
228
|
+
}
|
|
229
|
+
let env;
|
|
230
|
+
if (typeof schema != "boolean" && schema.$ref && !(0, util_1.schemaHasRulesButRef)(schema, this.RULES)) {
|
|
231
|
+
const $ref = (0, resolve_1.resolveUrl)(this.opts.uriResolver, baseId, schema.$ref);
|
|
232
|
+
env = resolveSchema.call(this, root, $ref);
|
|
233
|
+
}
|
|
234
|
+
// even though resolution failed we need to return SchemaEnv to throw exception
|
|
235
|
+
// so that compileAsync loads missing schema.
|
|
236
|
+
const { schemaId } = this.opts;
|
|
237
|
+
env = env || new SchemaEnv({ schema, schemaId, root, baseId });
|
|
238
|
+
if (env.schema !== env.root.schema)
|
|
239
|
+
return env;
|
|
240
|
+
return undefined;
|
|
241
|
+
}
|
|
242
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const codegen_1 = require("./codegen");
|
|
4
|
+
const names = {
|
|
5
|
+
// validation function arguments
|
|
6
|
+
data: new codegen_1.Name("data"), // data passed to validation function
|
|
7
|
+
// args passed from referencing schema
|
|
8
|
+
valCxt: new codegen_1.Name("valCxt"), // validation/data context - should not be used directly, it is destructured to the names below
|
|
9
|
+
instancePath: new codegen_1.Name("instancePath"),
|
|
10
|
+
parentData: new codegen_1.Name("parentData"),
|
|
11
|
+
parentDataProperty: new codegen_1.Name("parentDataProperty"),
|
|
12
|
+
rootData: new codegen_1.Name("rootData"), // root data - same as the data passed to the first/top validation function
|
|
13
|
+
dynamicAnchors: new codegen_1.Name("dynamicAnchors"), // used to support recursiveRef and dynamicRef
|
|
14
|
+
// function scoped variables
|
|
15
|
+
vErrors: new codegen_1.Name("vErrors"), // null or array of validation errors
|
|
16
|
+
errors: new codegen_1.Name("errors"), // counter of validation errors
|
|
17
|
+
this: new codegen_1.Name("this"),
|
|
18
|
+
// "globals"
|
|
19
|
+
self: new codegen_1.Name("self"),
|
|
20
|
+
scope: new codegen_1.Name("scope"),
|
|
21
|
+
// JTD serialize/parse name for JSON string and position
|
|
22
|
+
json: new codegen_1.Name("json"),
|
|
23
|
+
jsonPos: new codegen_1.Name("jsonPos"),
|
|
24
|
+
jsonLen: new codegen_1.Name("jsonLen"),
|
|
25
|
+
jsonPart: new codegen_1.Name("jsonPart"),
|
|
26
|
+
};
|
|
27
|
+
exports.default = names;
|
|
28
|
+
//# sourceMappingURL=names.js.map
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const resolve_1 = require("./resolve");
|
|
4
|
+
class MissingRefError extends Error {
|
|
5
|
+
constructor(resolver, baseId, ref, msg) {
|
|
6
|
+
super(msg || `can't resolve reference ${ref} from id ${baseId}`);
|
|
7
|
+
this.missingRef = (0, resolve_1.resolveUrl)(resolver, baseId, ref);
|
|
8
|
+
this.missingSchema = (0, resolve_1.normalizeId)((0, resolve_1.getFullPath)(resolver, this.missingRef));
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
exports.default = MissingRefError;
|
|
12
|
+
//# sourceMappingURL=ref_error.js.map
|