@powerlines/plugin-env 0.15.13 → 0.15.14
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/dist/_virtual/rolldown_runtime.cjs +4 -0
- package/dist/_virtual/rolldown_runtime.mjs +33 -0
- package/dist/babel/plugin.cjs +16 -16
- package/dist/babel/plugin.d.mts +2 -2
- package/dist/babel/plugin.mjs +7 -7
- package/dist/components/docs.cjs +8 -8
- package/dist/components/docs.mjs +5 -5
- package/dist/components/env.cjs +38 -39
- package/dist/components/env.d.mts +2 -2
- package/dist/components/env.mjs +11 -11
- package/dist/helpers/automd-generator.cjs +4 -4
- package/dist/helpers/automd-generator.d.mts +1 -1
- package/dist/helpers/automd-generator.mjs +3 -3
- package/dist/helpers/load.cjs +12 -13
- package/dist/helpers/load.d.mts +2 -2
- package/dist/helpers/load.mjs +10 -10
- package/dist/helpers/persistence.cjs +23 -23
- package/dist/helpers/persistence.d.mts +1 -1
- package/dist/helpers/persistence.mjs +7 -7
- package/dist/helpers/reflect.cjs +9 -9
- package/dist/helpers/reflect.mjs +5 -5
- package/dist/helpers/source-file-env.cjs +1 -1
- package/dist/helpers/source-file-env.mjs +1 -1
- package/dist/index.cjs +28 -26
- package/dist/index.d.mts +1 -1
- package/dist/index.mjs +25 -25
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/parse-type-definition.cjs +31 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/parse-type-definition.mjs +31 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/to-array.cjs +8 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/to-array.mjs +7 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/type-checks/src/get-object-tag.cjs +6 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/type-checks/src/get-object-tag.mjs +5 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/type-checks/src/index.cjs +3 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/type-checks/src/index.mjs +5 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/type-checks/src/is-buffer.cjs +6 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/type-checks/src/is-buffer.mjs +6 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/type-checks/src/is-collection.cjs +1 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/type-checks/src/is-collection.mjs +3 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/type-checks/src/is-object.cjs +13 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/type-checks/src/is-object.mjs +13 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/type-checks/src/is-plain-object.cjs +13 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/type-checks/src/is-plain-object.mjs +13 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/type-checks/src/is-string.cjs +12 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/type-checks/src/is-string.mjs +11 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/type-checks/src/type-detect.cjs +11 -0
- package/dist/node_modules/.pnpm/@stryke_convert@0.6.30/node_modules/@stryke/convert/dist/type-checks/src/type-detect.mjs +12 -0
- package/dist/node_modules/.pnpm/@stryke_path@0.24.1/node_modules/@stryke/path/dist/is-parent-path.cjs +10 -0
- package/dist/node_modules/.pnpm/@stryke_path@0.24.1/node_modules/@stryke/path/dist/is-parent-path.mjs +10 -0
- package/dist/node_modules/.pnpm/@stryke_path@0.24.1/node_modules/@stryke/path/dist/is-type.cjs +13 -0
- package/dist/node_modules/.pnpm/@stryke_path@0.24.1/node_modules/@stryke/path/dist/is-type.mjs +13 -0
- package/dist/node_modules/.pnpm/@stryke_path@0.24.1/node_modules/@stryke/path/dist/join-paths.cjs +49 -0
- package/dist/node_modules/.pnpm/@stryke_path@0.24.1/node_modules/@stryke/path/dist/join-paths.mjs +49 -0
- package/dist/node_modules/.pnpm/@stryke_path@0.24.1/node_modules/@stryke/path/dist/regex.cjs +9 -0
- package/dist/node_modules/.pnpm/@stryke_path@0.24.1/node_modules/@stryke/path/dist/regex.mjs +5 -0
- package/dist/node_modules/.pnpm/@stryke_path@0.24.1/node_modules/@stryke/path/dist/slash.cjs +8 -0
- package/dist/node_modules/.pnpm/@stryke_path@0.24.1/node_modules/@stryke/path/dist/slash.mjs +7 -0
- package/dist/node_modules/.pnpm/c12@3.3.3_magicast@0.5.1/node_modules/c12/dist/index.cjs +346 -0
- package/dist/node_modules/.pnpm/c12@3.3.3_magicast@0.5.1/node_modules/c12/dist/index.mjs +346 -0
- package/dist/node_modules/.pnpm/confbox@0.2.2/node_modules/confbox/dist/json5.cjs +786 -0
- package/dist/node_modules/.pnpm/confbox@0.2.2/node_modules/confbox/dist/json5.mjs +786 -0
- package/dist/node_modules/.pnpm/confbox@0.2.2/node_modules/confbox/dist/jsonc.cjs +3 -0
- package/dist/node_modules/.pnpm/confbox@0.2.2/node_modules/confbox/dist/jsonc.mjs +3 -0
- package/dist/node_modules/.pnpm/confbox@0.2.2/node_modules/confbox/dist/shared/confbox.DA7CpUDY.cjs +23 -0
- package/dist/node_modules/.pnpm/confbox@0.2.2/node_modules/confbox/dist/shared/confbox.DA7CpUDY.mjs +22 -0
- package/dist/node_modules/.pnpm/confbox@0.2.2/node_modules/confbox/dist/shared/confbox.DnMsyigM.cjs +405 -0
- package/dist/node_modules/.pnpm/confbox@0.2.2/node_modules/confbox/dist/shared/confbox.DnMsyigM.mjs +404 -0
- package/dist/node_modules/.pnpm/confbox@0.2.2/node_modules/confbox/dist/toml.cjs +657 -0
- package/dist/node_modules/.pnpm/confbox@0.2.2/node_modules/confbox/dist/toml.mjs +657 -0
- package/dist/node_modules/.pnpm/confbox@0.2.2/node_modules/confbox/dist/yaml.cjs +1054 -0
- package/dist/node_modules/.pnpm/confbox@0.2.2/node_modules/confbox/dist/yaml.mjs +1054 -0
- package/dist/node_modules/.pnpm/defu@6.1.4/node_modules/defu/dist/defu.cjs +43 -0
- package/dist/node_modules/.pnpm/defu@6.1.4/node_modules/defu/dist/defu.mjs +42 -0
- package/dist/node_modules/.pnpm/destr@2.0.5/node_modules/destr/dist/index.cjs +46 -0
- package/dist/node_modules/.pnpm/destr@2.0.5/node_modules/destr/dist/index.mjs +45 -0
- package/dist/node_modules/.pnpm/dotenv@17.2.3/node_modules/dotenv/lib/main.cjs +288 -0
- package/dist/node_modules/.pnpm/dotenv@17.2.3/node_modules/dotenv/lib/main.mjs +285 -0
- package/dist/node_modules/.pnpm/dotenv@17.2.3/node_modules/dotenv/package.cjs +71 -0
- package/dist/node_modules/.pnpm/dotenv@17.2.3/node_modules/dotenv/package.mjs +68 -0
- package/dist/node_modules/.pnpm/exsolve@1.0.8/node_modules/exsolve/dist/index.cjs +1013 -0
- package/dist/node_modules/.pnpm/exsolve@1.0.8/node_modules/exsolve/dist/index.mjs +1007 -0
- package/dist/node_modules/.pnpm/giget@2.0.0/node_modules/giget/dist/index.cjs +23 -0
- package/dist/node_modules/.pnpm/giget@2.0.0/node_modules/giget/dist/index.mjs +13 -0
- package/dist/node_modules/.pnpm/giget@2.0.0/node_modules/giget/dist/shared/giget.OCaTp9b-.cjs +2698 -0
- package/dist/node_modules/.pnpm/giget@2.0.0/node_modules/giget/dist/shared/giget.OCaTp9b-.mjs +2685 -0
- package/dist/node_modules/.pnpm/jiti@2.6.1/node_modules/jiti/dist/jiti.cjs +4457 -0
- package/dist/node_modules/.pnpm/jiti@2.6.1/node_modules/jiti/dist/jiti.mjs +4454 -0
- package/dist/node_modules/.pnpm/jiti@2.6.1/node_modules/jiti/lib/jiti.cjs +29 -0
- package/dist/node_modules/.pnpm/jiti@2.6.1/node_modules/jiti/lib/jiti.mjs +29 -0
- package/dist/node_modules/.pnpm/node-fetch-native@1.6.7/node_modules/node-fetch-native/dist/chunks/multipart-parser.cjs +181 -0
- package/dist/node_modules/.pnpm/node-fetch-native@1.6.7/node_modules/node-fetch-native/dist/chunks/multipart-parser.mjs +176 -0
- package/dist/node_modules/.pnpm/node-fetch-native@1.6.7/node_modules/node-fetch-native/dist/index.cjs +22 -0
- package/dist/node_modules/.pnpm/node-fetch-native@1.6.7/node_modules/node-fetch-native/dist/index.mjs +17 -0
- package/dist/node_modules/.pnpm/node-fetch-native@1.6.7/node_modules/node-fetch-native/dist/node.cjs +3967 -0
- package/dist/node_modules/.pnpm/node-fetch-native@1.6.7/node_modules/node-fetch-native/dist/node.mjs +3962 -0
- package/dist/node_modules/.pnpm/node-fetch-native@1.6.7/node_modules/node-fetch-native/dist/proxy.cjs +11768 -0
- package/dist/node_modules/.pnpm/node-fetch-native@1.6.7/node_modules/node-fetch-native/dist/proxy.mjs +11763 -0
- package/dist/node_modules/.pnpm/node-fetch-native@1.6.7/node_modules/node-fetch-native/dist/shared/node-fetch-native.DhEqb06g.cjs +25 -0
- package/dist/node_modules/.pnpm/node-fetch-native@1.6.7/node_modules/node-fetch-native/dist/shared/node-fetch-native.DhEqb06g.mjs +20 -0
- package/dist/node_modules/.pnpm/node-fetch-native@1.6.7/node_modules/node-fetch-native/lib/index.cjs +20 -0
- package/dist/node_modules/.pnpm/node-fetch-native@1.6.7/node_modules/node-fetch-native/lib/index.mjs +17 -0
- package/dist/node_modules/.pnpm/nypm@0.6.2/node_modules/nypm/dist/shared/nypm.CLjaS_sz.cjs +174 -0
- package/dist/node_modules/.pnpm/nypm@0.6.2/node_modules/nypm/dist/shared/nypm.CLjaS_sz.mjs +172 -0
- package/dist/node_modules/.pnpm/ohash@2.0.11/node_modules/ohash/dist/crypto/node/index.cjs +13 -0
- package/dist/node_modules/.pnpm/ohash@2.0.11/node_modules/ohash/dist/crypto/node/index.mjs +12 -0
- package/dist/node_modules/.pnpm/ohash@2.0.11/node_modules/ohash/dist/index.cjs +3 -0
- package/dist/node_modules/.pnpm/ohash@2.0.11/node_modules/ohash/dist/index.mjs +3 -0
- package/dist/node_modules/.pnpm/pathe@2.0.3/node_modules/pathe/dist/shared/pathe.M-eThtNZ.cjs +145 -0
- package/dist/node_modules/.pnpm/pathe@2.0.3/node_modules/pathe/dist/shared/pathe.M-eThtNZ.mjs +138 -0
- package/dist/node_modules/.pnpm/pkg-types@2.3.0/node_modules/pkg-types/dist/index.cjs +127 -0
- package/dist/node_modules/.pnpm/pkg-types@2.3.0/node_modules/pkg-types/dist/index.mjs +125 -0
- package/dist/node_modules/.pnpm/rc9@2.1.2/node_modules/rc9/dist/index.cjs +138 -0
- package/dist/node_modules/.pnpm/rc9@2.1.2/node_modules/rc9/dist/index.mjs +136 -0
- package/dist/node_modules/.pnpm/tinyexec@1.0.2/node_modules/tinyexec/dist/main.cjs +629 -0
- package/dist/node_modules/.pnpm/tinyexec@1.0.2/node_modules/tinyexec/dist/main.mjs +627 -0
- package/dist/{plugin-alloy → packages/plugin-alloy}/src/types/components.d.mts +1 -1
- package/dist/{plugin-alloy → packages/plugin-alloy}/src/typescript/components/typescript-file.d.mts +1 -1
- package/dist/{plugin-alloy → packages/plugin-alloy}/src/typescript/components/typescript-interface.d.mts +1 -1
- package/dist/{powerlines → packages/powerlines}/src/types/build.d.mts +6 -6
- package/dist/{powerlines → packages/powerlines}/src/types/config.d.mts +1 -2
- package/dist/{powerlines → packages/powerlines}/src/types/tsconfig.d.mts +1 -1
- package/dist/types/plugin.cjs +19 -18
- package/dist/types/plugin.d.mts +6 -6
- package/dist/types/plugin.mjs +4 -4
- package/dist/types/runtime.cjs +3 -2
- package/dist/types/runtime.d.mts +1 -1
- package/dist/types/runtime.mjs +1 -1
- package/package.json +10 -10
- package/dist/deepkit/schemas/reflection.cjs +0 -5368
- package/dist/deepkit/schemas/reflection.mjs +0 -5365
- package/dist/deepkit/schemas/reflection2.cjs +0 -4112
- package/dist/deepkit/schemas/reflection2.mjs +0 -4110
- package/dist/deepkit/src/capnp.cjs +0 -1692
- package/dist/deepkit/src/capnp.mjs +0 -1690
- package/dist/deepkit/src/esbuild-plugin.cjs +0 -99
- package/dist/deepkit/src/esbuild-plugin.mjs +0 -98
- package/dist/deepkit/src/reflect-type.cjs +0 -40
- package/dist/deepkit/src/reflect-type.mjs +0 -38
- package/dist/deepkit/src/resolve-reflections.cjs +0 -23
- package/dist/deepkit/src/resolve-reflections.mjs +0 -22
- package/dist/deepkit/src/transformer.cjs +0 -92
- package/dist/deepkit/src/transformer.mjs +0 -89
- package/dist/deepkit/src/transpile.cjs +0 -39
- package/dist/deepkit/src/transpile.mjs +0 -37
- package/dist/deepkit/src/types.cjs +0 -22
- package/dist/deepkit/src/types.mjs +0 -21
- package/dist/deepkit/src/utilities.cjs +0 -182
- package/dist/deepkit/src/utilities.mjs +0 -181
- package/dist/plugin-alloy/src/core/components/output.cjs +0 -45
- package/dist/plugin-alloy/src/core/components/output.mjs +0 -44
- package/dist/plugin-alloy/src/core/components/single-line-comment.cjs +0 -22
- package/dist/plugin-alloy/src/core/components/single-line-comment.mjs +0 -21
- package/dist/plugin-alloy/src/core/components/source-file.cjs +0 -64
- package/dist/plugin-alloy/src/core/components/source-file.mjs +0 -62
- package/dist/plugin-alloy/src/core/contexts/context.cjs +0 -136
- package/dist/plugin-alloy/src/core/contexts/context.mjs +0 -128
- package/dist/plugin-alloy/src/core/contexts/index.cjs +0 -2
- package/dist/plugin-alloy/src/core/contexts/index.mjs +0 -4
- package/dist/plugin-alloy/src/core/contexts/reflection.cjs +0 -110
- package/dist/plugin-alloy/src/core/contexts/reflection.mjs +0 -101
- package/dist/plugin-alloy/src/helpers/refkey.cjs +0 -23
- package/dist/plugin-alloy/src/helpers/refkey.mjs +0 -22
- package/dist/plugin-alloy/src/index.cjs +0 -106
- package/dist/plugin-alloy/src/index.mjs +0 -104
- package/dist/plugin-alloy/src/markdown/components/markdown-file.cjs +0 -115
- package/dist/plugin-alloy/src/markdown/components/markdown-file.mjs +0 -114
- package/dist/plugin-alloy/src/markdown/components/markdown-table.cjs +0 -39
- package/dist/plugin-alloy/src/markdown/components/markdown-table.mjs +0 -38
- package/dist/plugin-alloy/src/markdown/contexts/markdown-table.cjs +0 -72
- package/dist/plugin-alloy/src/markdown/contexts/markdown-table.mjs +0 -71
- package/dist/plugin-alloy/src/types/components.cjs +0 -22
- package/dist/plugin-alloy/src/types/components.mjs +0 -21
- package/dist/plugin-alloy/src/types/plugin.cjs +0 -55
- package/dist/plugin-alloy/src/types/plugin.mjs +0 -52
- package/dist/plugin-alloy/src/typescript/components/builtin-file.cjs +0 -57
- package/dist/plugin-alloy/src/typescript/components/builtin-file.mjs +0 -56
- package/dist/plugin-alloy/src/typescript/components/tsdoc-reflection.cjs +0 -126
- package/dist/plugin-alloy/src/typescript/components/tsdoc-reflection.mjs +0 -124
- package/dist/plugin-alloy/src/typescript/components/tsdoc.cjs +0 -442
- package/dist/plugin-alloy/src/typescript/components/tsdoc.mjs +0 -433
- package/dist/plugin-alloy/src/typescript/components/typescript-file.cjs +0 -212
- package/dist/plugin-alloy/src/typescript/components/typescript-file.mjs +0 -209
- package/dist/plugin-alloy/src/typescript/components/typescript-interface.cjs +0 -68
- package/dist/plugin-alloy/src/typescript/components/typescript-interface.mjs +0 -67
- package/dist/plugin-alloy/src/typescript/components/typescript-object.cjs +0 -124
- package/dist/plugin-alloy/src/typescript/components/typescript-object.mjs +0 -123
- package/dist/plugin-automd/src/index.cjs +0 -127
- package/dist/plugin-automd/src/index.mjs +0 -124
- package/dist/plugin-automd/src/types/plugin.cjs +0 -47
- package/dist/plugin-automd/src/types/plugin.mjs +0 -47
- package/dist/plugin-automd/src/types/toc.cjs +0 -26
- package/dist/plugin-automd/src/types/toc.mjs +0 -25
- package/dist/plugin-babel/src/helpers/ast-utils.cjs +0 -74
- package/dist/plugin-babel/src/helpers/ast-utils.mjs +0 -70
- package/dist/plugin-babel/src/helpers/create-plugin.cjs +0 -71
- package/dist/plugin-babel/src/helpers/create-plugin.mjs +0 -69
- package/dist/plugin-babel/src/helpers/filters.cjs +0 -158
- package/dist/plugin-babel/src/helpers/filters.mjs +0 -154
- package/dist/plugin-babel/src/helpers/index.cjs +0 -5
- package/dist/plugin-babel/src/helpers/index.mjs +0 -7
- package/dist/plugin-babel/src/helpers/module-helpers.cjs +0 -200
- package/dist/plugin-babel/src/helpers/module-helpers.mjs +0 -192
- package/dist/plugin-babel/src/helpers/options.cjs +0 -74
- package/dist/plugin-babel/src/helpers/options.mjs +0 -71
- package/dist/plugin-babel/src/index.cjs +0 -131
- package/dist/plugin-babel/src/index.mjs +0 -129
- package/dist/plugin-babel/src/types/plugin.cjs +0 -42
- package/dist/plugin-babel/src/types/plugin.mjs +0 -39
- package/dist/powerlines/src/internal/helpers/hooks.cjs +0 -137
- package/dist/powerlines/src/internal/helpers/hooks.mjs +0 -135
- package/dist/powerlines/src/lib/build/esbuild.cjs +0 -161
- package/dist/powerlines/src/lib/build/esbuild.mjs +0 -159
- package/dist/powerlines/src/lib/entry.cjs +0 -203
- package/dist/powerlines/src/lib/entry.mjs +0 -201
- package/dist/powerlines/src/lib/logger.cjs +0 -108
- package/dist/powerlines/src/lib/logger.mjs +0 -106
- package/dist/powerlines/src/lib/utilities/bundle.cjs +0 -67
- package/dist/powerlines/src/lib/utilities/bundle.mjs +0 -66
- package/dist/powerlines/src/lib/utilities/resolve.cjs +0 -49
- package/dist/powerlines/src/lib/utilities/resolve.mjs +0 -48
- package/dist/powerlines/src/plugin-utils/paths.cjs +0 -46
- package/dist/powerlines/src/plugin-utils/paths.mjs +0 -45
- package/dist/powerlines/src/types/api.cjs +0 -62
- package/dist/powerlines/src/types/api.mjs +0 -62
- package/dist/powerlines/src/types/babel.cjs +0 -156
- package/dist/powerlines/src/types/babel.mjs +0 -147
- package/dist/powerlines/src/types/build.cjs +0 -127
- package/dist/powerlines/src/types/build.mjs +0 -121
- package/dist/powerlines/src/types/commands.cjs +0 -16
- package/dist/powerlines/src/types/commands.mjs +0 -15
- package/dist/powerlines/src/types/config.cjs +0 -413
- package/dist/powerlines/src/types/config.mjs +0 -391
- package/dist/powerlines/src/types/context.cjs +0 -381
- package/dist/powerlines/src/types/context.mjs +0 -364
- package/dist/powerlines/src/types/fs.cjs +0 -78
- package/dist/powerlines/src/types/fs.mjs +0 -75
- package/dist/powerlines/src/types/hooks.cjs +0 -71
- package/dist/powerlines/src/types/hooks.mjs +0 -68
- package/dist/powerlines/src/types/index.cjs +0 -11
- package/dist/powerlines/src/types/index.mjs +0 -13
- package/dist/powerlines/src/types/plugin.cjs +0 -184
- package/dist/powerlines/src/types/plugin.mjs +0 -178
- package/dist/powerlines/src/types/resolved.cjs +0 -153
- package/dist/powerlines/src/types/resolved.mjs +0 -148
- package/dist/powerlines/src/types/unplugin.cjs +0 -47
- package/dist/powerlines/src/types/unplugin.mjs +0 -46
- /package/dist/{deepkit → packages/deepkit}/schemas/reflection.d.mts +0 -0
- /package/dist/{deepkit → packages/deepkit}/src/types.d.mts +0 -0
- /package/dist/{plugin-alloy → packages/plugin-alloy}/src/core/components/source-file.d.mts +0 -0
- /package/dist/{plugin-alloy → packages/plugin-alloy}/src/types/index.d.mts +0 -0
- /package/dist/{plugin-alloy → packages/plugin-alloy}/src/types/plugin.d.mts +0 -0
- /package/dist/{plugin-alloy → packages/plugin-alloy}/src/typescript/components/builtin-file.d.mts +0 -0
- /package/dist/{plugin-alloy → packages/plugin-alloy}/src/typescript/components/tsdoc.d.mts +0 -0
- /package/dist/{plugin-automd → packages/plugin-automd}/src/types/plugin.d.mts +0 -0
- /package/dist/{plugin-automd → packages/plugin-automd}/src/types/toc.d.mts +0 -0
- /package/dist/{plugin-babel → packages/plugin-babel}/src/types/index.d.mts +0 -0
- /package/dist/{plugin-babel → packages/plugin-babel}/src/types/plugin.d.mts +0 -0
- /package/dist/{powerlines → packages/powerlines}/src/internal/helpers/hooks.d.mts +0 -0
- /package/dist/{powerlines → packages/powerlines}/src/types/api.d.mts +0 -0
- /package/dist/{powerlines → packages/powerlines}/src/types/babel.d.mts +0 -0
- /package/dist/{powerlines → packages/powerlines}/src/types/commands.d.mts +0 -0
- /package/dist/{powerlines → packages/powerlines}/src/types/context.d.mts +0 -0
- /package/dist/{powerlines → packages/powerlines}/src/types/fs.d.mts +0 -0
- /package/dist/{powerlines → packages/powerlines}/src/types/hooks.d.mts +0 -0
- /package/dist/{powerlines → packages/powerlines}/src/types/index.d.mts +0 -0
- /package/dist/{powerlines → packages/powerlines}/src/types/plugin.d.mts +0 -0
- /package/dist/{powerlines → packages/powerlines}/src/types/resolved.d.mts +0 -0
- /package/dist/{powerlines → packages/powerlines}/src/types/unplugin.d.mts +0 -0
|
@@ -1,433 +0,0 @@
|
|
|
1
|
-
import { usePowerlines } from "../../core/contexts/context.mjs";
|
|
2
|
-
import { stringifyDefaultValue } from "../../../../deepkit/src/utilities.mjs";
|
|
3
|
-
import { isSetString } from "@stryke/type-checks/is-set-string";
|
|
4
|
-
import { For, List, Prose, Show, childrenArray, splitProps } from "@alloy-js/core";
|
|
5
|
-
import { createComponent, createIntrinsic, memo, mergeProps } from "@alloy-js/core/jsx-runtime";
|
|
6
|
-
import { isUndefined } from "@stryke/type-checks/is-undefined";
|
|
7
|
-
|
|
8
|
-
//#region ../plugin-alloy/src/typescript/components/tsdoc.tsx
|
|
9
|
-
/**
|
|
10
|
-
* Generates a TypeScript interface for the given reflection class.
|
|
11
|
-
*/
|
|
12
|
-
function TSDoc(props) {
|
|
13
|
-
const [{ children, heading }] = splitProps(props, ["children", "heading"]);
|
|
14
|
-
return [
|
|
15
|
-
"/**",
|
|
16
|
-
createIntrinsic("align", {
|
|
17
|
-
string: " * ",
|
|
18
|
-
get children() {
|
|
19
|
-
return [
|
|
20
|
-
createIntrinsic("hbr", {}),
|
|
21
|
-
createComponent(Show, {
|
|
22
|
-
get when() {
|
|
23
|
-
return !isUndefined(heading);
|
|
24
|
-
},
|
|
25
|
-
get children() {
|
|
26
|
-
return [
|
|
27
|
-
heading,
|
|
28
|
-
createIntrinsic("hbr", {}),
|
|
29
|
-
createComponent(Show, {
|
|
30
|
-
get when() {
|
|
31
|
-
return memo(() => !!!isUndefined(children))() && childrenArray(() => children).length > 0;
|
|
32
|
-
},
|
|
33
|
-
get children() {
|
|
34
|
-
return createIntrinsic("hbr", {});
|
|
35
|
-
}
|
|
36
|
-
})
|
|
37
|
-
];
|
|
38
|
-
}
|
|
39
|
-
}),
|
|
40
|
-
createComponent(Show, {
|
|
41
|
-
get when() {
|
|
42
|
-
return memo(() => !!!isUndefined(children))() && childrenArray(() => children).length > 0;
|
|
43
|
-
},
|
|
44
|
-
get children() {
|
|
45
|
-
return createComponent(List, { get children() {
|
|
46
|
-
return childrenArray(() => children);
|
|
47
|
-
} });
|
|
48
|
-
}
|
|
49
|
-
})
|
|
50
|
-
];
|
|
51
|
-
}
|
|
52
|
-
}),
|
|
53
|
-
createIntrinsic("hbr", {}),
|
|
54
|
-
` */`,
|
|
55
|
-
createIntrinsic("hbr", {})
|
|
56
|
-
];
|
|
57
|
-
}
|
|
58
|
-
/**
|
|
59
|
-
* Create a TSDoc `@<props.tag>` tag.
|
|
60
|
-
*/
|
|
61
|
-
function TSDocTag(props) {
|
|
62
|
-
const [{ children, tag }] = splitProps(props, ["children", "tag"]);
|
|
63
|
-
return [
|
|
64
|
-
`@${tag} `,
|
|
65
|
-
createComponent(Show, {
|
|
66
|
-
get when() {
|
|
67
|
-
return Boolean(children);
|
|
68
|
-
},
|
|
69
|
-
get children() {
|
|
70
|
-
return createIntrinsic("align", {
|
|
71
|
-
width: 2,
|
|
72
|
-
get children() {
|
|
73
|
-
return createComponent(Prose, { children });
|
|
74
|
-
}
|
|
75
|
-
});
|
|
76
|
-
}
|
|
77
|
-
}),
|
|
78
|
-
createIntrinsic("hbr", {})
|
|
79
|
-
];
|
|
80
|
-
}
|
|
81
|
-
/**
|
|
82
|
-
* Create a TSDoc `@title` tag.
|
|
83
|
-
*/
|
|
84
|
-
function TSDocTitle(props) {
|
|
85
|
-
const [{ children }, rest] = splitProps(props, ["children"]);
|
|
86
|
-
return createComponent(TSDocTag, mergeProps(rest, {
|
|
87
|
-
tag: "title",
|
|
88
|
-
children
|
|
89
|
-
}));
|
|
90
|
-
}
|
|
91
|
-
/**
|
|
92
|
-
* Create a TSDoc `@domain` tag.
|
|
93
|
-
*/
|
|
94
|
-
function TSDocDomain(props) {
|
|
95
|
-
const [{ children }, rest] = splitProps(props, ["children"]);
|
|
96
|
-
return createComponent(TSDocTag, mergeProps(rest, {
|
|
97
|
-
tag: "domain",
|
|
98
|
-
children
|
|
99
|
-
}));
|
|
100
|
-
}
|
|
101
|
-
/**
|
|
102
|
-
* Create a TSDoc `@alias` tag.
|
|
103
|
-
*/
|
|
104
|
-
function TSDocAlias(props) {
|
|
105
|
-
const [{ children }, rest] = splitProps(props, ["children"]);
|
|
106
|
-
return createComponent(TSDocTag, mergeProps(rest, {
|
|
107
|
-
tag: "alias",
|
|
108
|
-
children
|
|
109
|
-
}));
|
|
110
|
-
}
|
|
111
|
-
/**
|
|
112
|
-
* Create a TSDoc `@permission` tag.
|
|
113
|
-
*/
|
|
114
|
-
function TSDocPermission(props) {
|
|
115
|
-
const [{ children }, rest] = splitProps(props, ["children"]);
|
|
116
|
-
return createComponent(TSDocTag, mergeProps(rest, {
|
|
117
|
-
tag: "permission",
|
|
118
|
-
children
|
|
119
|
-
}));
|
|
120
|
-
}
|
|
121
|
-
/**
|
|
122
|
-
* Create a TSDoc `@defaultValue` tag.
|
|
123
|
-
*/
|
|
124
|
-
function TSDocDefaultValue(props) {
|
|
125
|
-
return [
|
|
126
|
-
"@defaultValue ",
|
|
127
|
-
createComponent(Show, {
|
|
128
|
-
get when() {
|
|
129
|
-
return !isUndefined(props.value);
|
|
130
|
-
},
|
|
131
|
-
get children() {
|
|
132
|
-
return createIntrinsic("align", {
|
|
133
|
-
width: 2,
|
|
134
|
-
get children() {
|
|
135
|
-
return createComponent(Prose, { get children() {
|
|
136
|
-
return stringifyDefaultValue(props.value);
|
|
137
|
-
} });
|
|
138
|
-
}
|
|
139
|
-
});
|
|
140
|
-
}
|
|
141
|
-
}),
|
|
142
|
-
createIntrinsic("hbr", {})
|
|
143
|
-
];
|
|
144
|
-
}
|
|
145
|
-
/**
|
|
146
|
-
* Create a TSDoc `@remarks` tag.
|
|
147
|
-
*/
|
|
148
|
-
function TSDocRemarks(props) {
|
|
149
|
-
return [
|
|
150
|
-
"@remarks ",
|
|
151
|
-
createIntrinsic("hbr", {}),
|
|
152
|
-
createComponent(List, {
|
|
153
|
-
hardline: true,
|
|
154
|
-
get children() {
|
|
155
|
-
return childrenArray(() => props.children);
|
|
156
|
-
}
|
|
157
|
-
})
|
|
158
|
-
];
|
|
159
|
-
}
|
|
160
|
-
/**
|
|
161
|
-
* Create a TSDoc `@see` tag.
|
|
162
|
-
*/
|
|
163
|
-
function TSDocLink(props) {
|
|
164
|
-
return createComponent(TSDocTag, mergeProps(props, { tag: "see" }));
|
|
165
|
-
}
|
|
166
|
-
/**
|
|
167
|
-
* Create a TSDoc `@example` tag.
|
|
168
|
-
*/
|
|
169
|
-
function TSDocExample(props) {
|
|
170
|
-
const [{ tsx, fenced = true, language, children }] = splitProps(props, [
|
|
171
|
-
"tsx",
|
|
172
|
-
"fenced",
|
|
173
|
-
"language",
|
|
174
|
-
"children"
|
|
175
|
-
]);
|
|
176
|
-
return [
|
|
177
|
-
"@example ",
|
|
178
|
-
createIntrinsic("hbr", {}),
|
|
179
|
-
createComponent(Show, {
|
|
180
|
-
when: fenced,
|
|
181
|
-
get children() {
|
|
182
|
-
return [
|
|
183
|
-
"```",
|
|
184
|
-
language || (tsx ? "tsx" : "ts"),
|
|
185
|
-
createIntrinsic("hbr", {})
|
|
186
|
-
];
|
|
187
|
-
}
|
|
188
|
-
}),
|
|
189
|
-
children,
|
|
190
|
-
createComponent(Show, {
|
|
191
|
-
when: fenced,
|
|
192
|
-
get children() {
|
|
193
|
-
return [createIntrinsic("hbr", {}), "```"];
|
|
194
|
-
}
|
|
195
|
-
})
|
|
196
|
-
];
|
|
197
|
-
}
|
|
198
|
-
/**
|
|
199
|
-
* Create a TSDoc `@readonly` tag.
|
|
200
|
-
*/
|
|
201
|
-
function TSDocReadonly() {
|
|
202
|
-
return createComponent(TSDocTag, { tag: "readonly" });
|
|
203
|
-
}
|
|
204
|
-
/**
|
|
205
|
-
* Create a TSDoc `@internal` tag.
|
|
206
|
-
*/
|
|
207
|
-
function TSDocInternal() {
|
|
208
|
-
return createComponent(TSDocTag, { tag: "internal" });
|
|
209
|
-
}
|
|
210
|
-
/**
|
|
211
|
-
* Create a TSDoc `@ignore` tag.
|
|
212
|
-
*/
|
|
213
|
-
function TSDocIgnore() {
|
|
214
|
-
return createComponent(TSDocTag, { tag: "ignore" });
|
|
215
|
-
}
|
|
216
|
-
/**
|
|
217
|
-
* Create a TSDoc `@hidden` tag.
|
|
218
|
-
*/
|
|
219
|
-
function TSDocHidden() {
|
|
220
|
-
return createComponent(TSDocTag, { tag: "hidden" });
|
|
221
|
-
}
|
|
222
|
-
/**
|
|
223
|
-
* Generates a TypeScript interface property for the given reflection class.
|
|
224
|
-
*/
|
|
225
|
-
function TSDocAttributesTags(props) {
|
|
226
|
-
const [{ title, alias, permission, domain, readonly, internal, ignore, hidden, defaultValue }] = splitProps(props, [
|
|
227
|
-
"title",
|
|
228
|
-
"alias",
|
|
229
|
-
"permission",
|
|
230
|
-
"domain",
|
|
231
|
-
"readonly",
|
|
232
|
-
"internal",
|
|
233
|
-
"ignore",
|
|
234
|
-
"hidden",
|
|
235
|
-
"defaultValue"
|
|
236
|
-
]);
|
|
237
|
-
return [
|
|
238
|
-
createComponent(Show, {
|
|
239
|
-
get when() {
|
|
240
|
-
return isSetString(title);
|
|
241
|
-
},
|
|
242
|
-
get children() {
|
|
243
|
-
return createComponent(TSDocTitle, { children: title });
|
|
244
|
-
}
|
|
245
|
-
}),
|
|
246
|
-
createComponent(Show, {
|
|
247
|
-
get when() {
|
|
248
|
-
return !isUndefined(alias) && alias.length > 0;
|
|
249
|
-
},
|
|
250
|
-
get children() {
|
|
251
|
-
return createComponent(For, {
|
|
252
|
-
each: alias ?? [],
|
|
253
|
-
children: (alias$1) => createComponent(TSDocAlias, { children: alias$1 })
|
|
254
|
-
});
|
|
255
|
-
}
|
|
256
|
-
}),
|
|
257
|
-
createComponent(Show, {
|
|
258
|
-
get when() {
|
|
259
|
-
return isSetString(domain);
|
|
260
|
-
},
|
|
261
|
-
get children() {
|
|
262
|
-
return createComponent(TSDocDomain, { children: domain });
|
|
263
|
-
}
|
|
264
|
-
}),
|
|
265
|
-
createComponent(Show, {
|
|
266
|
-
get when() {
|
|
267
|
-
return !isUndefined(permission) && permission.length > 0;
|
|
268
|
-
},
|
|
269
|
-
get children() {
|
|
270
|
-
return createComponent(For, {
|
|
271
|
-
each: permission ?? [],
|
|
272
|
-
children: (permission$1) => createComponent(TSDocPermission, { children: permission$1 })
|
|
273
|
-
});
|
|
274
|
-
}
|
|
275
|
-
}),
|
|
276
|
-
createComponent(Show, {
|
|
277
|
-
when: readonly === true,
|
|
278
|
-
get children() {
|
|
279
|
-
return createComponent(TSDocReadonly, {});
|
|
280
|
-
}
|
|
281
|
-
}),
|
|
282
|
-
createComponent(Show, {
|
|
283
|
-
when: internal === true,
|
|
284
|
-
get children() {
|
|
285
|
-
return createComponent(TSDocInternal, {});
|
|
286
|
-
}
|
|
287
|
-
}),
|
|
288
|
-
createComponent(Show, {
|
|
289
|
-
when: ignore === true,
|
|
290
|
-
get children() {
|
|
291
|
-
return createComponent(TSDocIgnore, {});
|
|
292
|
-
}
|
|
293
|
-
}),
|
|
294
|
-
createComponent(Show, {
|
|
295
|
-
when: hidden === true,
|
|
296
|
-
get children() {
|
|
297
|
-
return createComponent(TSDocHidden, {});
|
|
298
|
-
}
|
|
299
|
-
}),
|
|
300
|
-
createComponent(Show, {
|
|
301
|
-
get when() {
|
|
302
|
-
return !isUndefined(defaultValue);
|
|
303
|
-
},
|
|
304
|
-
get children() {
|
|
305
|
-
return createComponent(TSDocDefaultValue, { value: defaultValue });
|
|
306
|
-
}
|
|
307
|
-
})
|
|
308
|
-
];
|
|
309
|
-
}
|
|
310
|
-
/**
|
|
311
|
-
* Create a TSDoc parameter set off with `@param`.
|
|
312
|
-
*/
|
|
313
|
-
function TSDocParam(props) {
|
|
314
|
-
return [
|
|
315
|
-
"@param ",
|
|
316
|
-
createComponent(TSDocParamName, {
|
|
317
|
-
get name() {
|
|
318
|
-
return props.name;
|
|
319
|
-
},
|
|
320
|
-
get optional() {
|
|
321
|
-
return props.optional;
|
|
322
|
-
},
|
|
323
|
-
get defaultValue() {
|
|
324
|
-
return props.defaultValue;
|
|
325
|
-
}
|
|
326
|
-
}),
|
|
327
|
-
createComponent(TSDocParamDescription, { get children() {
|
|
328
|
-
return props.children;
|
|
329
|
-
} })
|
|
330
|
-
];
|
|
331
|
-
}
|
|
332
|
-
function TSDocParamName(props) {
|
|
333
|
-
return [
|
|
334
|
-
createComponent(Show, {
|
|
335
|
-
get when() {
|
|
336
|
-
return props.optional;
|
|
337
|
-
},
|
|
338
|
-
children: "["
|
|
339
|
-
}),
|
|
340
|
-
memo(() => props.name),
|
|
341
|
-
createComponent(Show, {
|
|
342
|
-
get when() {
|
|
343
|
-
return Boolean(props.defaultValue);
|
|
344
|
-
},
|
|
345
|
-
get children() {
|
|
346
|
-
return ["=", memo(() => props.defaultValue)];
|
|
347
|
-
}
|
|
348
|
-
}),
|
|
349
|
-
createComponent(Show, {
|
|
350
|
-
get when() {
|
|
351
|
-
return props.optional;
|
|
352
|
-
},
|
|
353
|
-
children: "]"
|
|
354
|
-
})
|
|
355
|
-
];
|
|
356
|
-
}
|
|
357
|
-
function TSDocParamDescription(props) {
|
|
358
|
-
return createComponent(Show, {
|
|
359
|
-
get when() {
|
|
360
|
-
return Boolean(props.children);
|
|
361
|
-
},
|
|
362
|
-
get children() {
|
|
363
|
-
return [" - ", createIntrinsic("align", {
|
|
364
|
-
width: 2,
|
|
365
|
-
get children() {
|
|
366
|
-
return createComponent(Prose, { get children() {
|
|
367
|
-
return props.children;
|
|
368
|
-
} });
|
|
369
|
-
}
|
|
370
|
-
})];
|
|
371
|
-
}
|
|
372
|
-
});
|
|
373
|
-
}
|
|
374
|
-
/**
|
|
375
|
-
* Create a TSDoc `@returns` tag.
|
|
376
|
-
*/
|
|
377
|
-
function TSDocReturns(props) {
|
|
378
|
-
return createComponent(TSDocTag, mergeProps(props, { tag: "returns" }));
|
|
379
|
-
}
|
|
380
|
-
/**
|
|
381
|
-
* Create a TSDoc `@throws` tag.
|
|
382
|
-
*/
|
|
383
|
-
function TSDocThrows(props) {
|
|
384
|
-
return createComponent(TSDocTag, mergeProps(props, { tag: "throws" }));
|
|
385
|
-
}
|
|
386
|
-
/**
|
|
387
|
-
* Generates a TSDoc `@module` tag for the given module name.
|
|
388
|
-
*/
|
|
389
|
-
function TSDocModule(props) {
|
|
390
|
-
const [{ children, name, prefix }] = splitProps(props, [
|
|
391
|
-
"children",
|
|
392
|
-
"name",
|
|
393
|
-
"prefix"
|
|
394
|
-
]);
|
|
395
|
-
const context = usePowerlines();
|
|
396
|
-
return [
|
|
397
|
-
"/**",
|
|
398
|
-
createIntrinsic("align", {
|
|
399
|
-
string: " * ",
|
|
400
|
-
get children() {
|
|
401
|
-
return [
|
|
402
|
-
createIntrinsic("hbr", {}),
|
|
403
|
-
createComponent(Show, {
|
|
404
|
-
get when() {
|
|
405
|
-
return Boolean(children);
|
|
406
|
-
},
|
|
407
|
-
get children() {
|
|
408
|
-
return [
|
|
409
|
-
createComponent(List, {
|
|
410
|
-
hardline: true,
|
|
411
|
-
get children() {
|
|
412
|
-
return childrenArray(() => children);
|
|
413
|
-
}
|
|
414
|
-
}),
|
|
415
|
-
createIntrinsic("hbr", {}),
|
|
416
|
-
createIntrinsic("hbr", {})
|
|
417
|
-
];
|
|
418
|
-
}
|
|
419
|
-
}),
|
|
420
|
-
"@module ",
|
|
421
|
-
memo(() => prefix || context?.config.output.builtinPrefix),
|
|
422
|
-
":",
|
|
423
|
-
name
|
|
424
|
-
];
|
|
425
|
-
}
|
|
426
|
-
}),
|
|
427
|
-
createIntrinsic("hbr", {}),
|
|
428
|
-
` */`
|
|
429
|
-
];
|
|
430
|
-
}
|
|
431
|
-
|
|
432
|
-
//#endregion
|
|
433
|
-
export { TSDoc, TSDocAttributesTags, TSDocExample, TSDocLink, TSDocModule, TSDocParam, TSDocRemarks, TSDocReturns, TSDocThrows };
|
|
@@ -1,212 +0,0 @@
|
|
|
1
|
-
const require_rolldown_runtime = require('../../../../_virtual/rolldown_runtime.cjs');
|
|
2
|
-
const require_context = require('../../core/contexts/context.cjs');
|
|
3
|
-
const require_single_line_comment = require('../../core/components/single-line-comment.cjs');
|
|
4
|
-
const require_source_file = require('../../core/components/source-file.cjs');
|
|
5
|
-
let __stryke_string_format_title_case = require("@stryke/string-format/title-case");
|
|
6
|
-
let __stryke_type_checks_is_string = require("@stryke/type-checks/is-string");
|
|
7
|
-
let __stryke_path_append = require("@stryke/path/append");
|
|
8
|
-
let __alloy_js_core = require("@alloy-js/core");
|
|
9
|
-
let __alloy_js_core_jsx_runtime = require("@alloy-js/core/jsx-runtime");
|
|
10
|
-
let __alloy_js_typescript = require("@alloy-js/typescript");
|
|
11
|
-
let __stryke_type_checks_is_boolean = require("@stryke/type-checks/is-boolean");
|
|
12
|
-
|
|
13
|
-
//#region ../plugin-alloy/src/typescript/components/typescript-file.tsx
|
|
14
|
-
/**
|
|
15
|
-
* A base component representing a Powerlines generated Typescript source file.
|
|
16
|
-
*
|
|
17
|
-
* @param props - The properties for the source file.
|
|
18
|
-
* @returns The rendered source file component.
|
|
19
|
-
*/
|
|
20
|
-
function TypescriptFile(props) {
|
|
21
|
-
const [{ children, path, imports, tsx, header, hashbang }, rest] = (0, __alloy_js_core.splitProps)(props, [
|
|
22
|
-
"children",
|
|
23
|
-
"path",
|
|
24
|
-
"imports",
|
|
25
|
-
"tsx",
|
|
26
|
-
"header",
|
|
27
|
-
"hashbang"
|
|
28
|
-
]);
|
|
29
|
-
const directoryContext = (0, __alloy_js_core.useContext)(__alloy_js_core.SourceDirectoryContext);
|
|
30
|
-
const sdData = (0, __alloy_js_typescript.getSourceDirectoryData)(directoryContext);
|
|
31
|
-
const modulePath = (0, __stryke_path_append.appendPath)(path, directoryContext.path);
|
|
32
|
-
const scope = new __alloy_js_typescript.TSModuleScope(modulePath, (0, __alloy_js_core.useScope)());
|
|
33
|
-
sdData.modules.add(scope);
|
|
34
|
-
const pkg = (0, __alloy_js_core.useContext)(__alloy_js_typescript.PackageContext);
|
|
35
|
-
if (pkg) pkg.scope.addModule(scope);
|
|
36
|
-
if (props.export) {
|
|
37
|
-
if (pkg) if ((0, __stryke_type_checks_is_boolean.isBoolean)(props.export)) pkg.scope.addExport(modulePath, scope);
|
|
38
|
-
else pkg.scope.addExport(props.export, scope);
|
|
39
|
-
}
|
|
40
|
-
return (0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_typescript.SourceFileContext.Provider, {
|
|
41
|
-
value: { scope },
|
|
42
|
-
get children() {
|
|
43
|
-
return (0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Scope, {
|
|
44
|
-
value: scope,
|
|
45
|
-
get children() {
|
|
46
|
-
return (0, __alloy_js_core_jsx_runtime.createComponent)(require_source_file.SourceFile, (0, __alloy_js_core_jsx_runtime.mergeProps)(rest, {
|
|
47
|
-
path: modulePath,
|
|
48
|
-
get header() {
|
|
49
|
-
return header ?? (0, __alloy_js_core_jsx_runtime.createComponent)(TypescriptFileHeader, {
|
|
50
|
-
hashbang,
|
|
51
|
-
get children() {
|
|
52
|
-
return (0, __alloy_js_core_jsx_runtime.createComponent)(TypescriptFileHeaderImports, {
|
|
53
|
-
imports,
|
|
54
|
-
scope
|
|
55
|
-
});
|
|
56
|
-
}
|
|
57
|
-
});
|
|
58
|
-
},
|
|
59
|
-
filetype: tsx ? "tsx" : "typescript",
|
|
60
|
-
children
|
|
61
|
-
}));
|
|
62
|
-
}
|
|
63
|
-
});
|
|
64
|
-
}
|
|
65
|
-
});
|
|
66
|
-
}
|
|
67
|
-
/**
|
|
68
|
-
* Renders the header for a Powerlines Typescript source file.
|
|
69
|
-
*
|
|
70
|
-
* @param props - The properties for the source file header.
|
|
71
|
-
* @returns The rendered source file header.
|
|
72
|
-
*/
|
|
73
|
-
function TypescriptFileHeader(props) {
|
|
74
|
-
const { header, hashbang, disableEslint = true, disableBiome = true, disablePrettier = false, children } = props;
|
|
75
|
-
const context = require_context.usePowerlines();
|
|
76
|
-
return [
|
|
77
|
-
(0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
78
|
-
get when() {
|
|
79
|
-
return Boolean(hashbang);
|
|
80
|
-
},
|
|
81
|
-
get children() {
|
|
82
|
-
return [(0, __alloy_js_core_jsx_runtime.memo)(() => hashbang === true ? __alloy_js_core.code`#!/usr/bin/env ${context?.config.mode === "development" ? "-S NODE_OPTIONS=--enable-source-maps" : ""} node` : hashbang), (0, __alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {})];
|
|
83
|
-
}
|
|
84
|
-
}),
|
|
85
|
-
(0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
86
|
-
get when() {
|
|
87
|
-
return Boolean(header);
|
|
88
|
-
},
|
|
89
|
-
get children() {
|
|
90
|
-
return [header, (0, __alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {})];
|
|
91
|
-
}
|
|
92
|
-
}),
|
|
93
|
-
(0, __alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {}),
|
|
94
|
-
(0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
95
|
-
get when() {
|
|
96
|
-
return Boolean(disableEslint);
|
|
97
|
-
},
|
|
98
|
-
get children() {
|
|
99
|
-
return [(0, __alloy_js_core_jsx_runtime.createComponent)(require_single_line_comment.SingleLineComment, {
|
|
100
|
-
variant: "slash-star",
|
|
101
|
-
children: "eslint-disable"
|
|
102
|
-
}), (0, __alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {})];
|
|
103
|
-
}
|
|
104
|
-
}),
|
|
105
|
-
(0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
106
|
-
get when() {
|
|
107
|
-
return Boolean(disablePrettier);
|
|
108
|
-
},
|
|
109
|
-
get children() {
|
|
110
|
-
return [(0, __alloy_js_core_jsx_runtime.createComponent)(require_single_line_comment.SingleLineComment, {
|
|
111
|
-
variant: "slash-star",
|
|
112
|
-
children: "prettier-ignore"
|
|
113
|
-
}), (0, __alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {})];
|
|
114
|
-
}
|
|
115
|
-
}),
|
|
116
|
-
(0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
117
|
-
get when() {
|
|
118
|
-
return Boolean(disableBiome);
|
|
119
|
-
},
|
|
120
|
-
get children() {
|
|
121
|
-
return [(0, __alloy_js_core_jsx_runtime.createComponent)(require_single_line_comment.SingleLineComment, { children: "biome-ignore lint: disable" }), (0, __alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {})];
|
|
122
|
-
}
|
|
123
|
-
}),
|
|
124
|
-
(0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
125
|
-
get when() {
|
|
126
|
-
return Boolean(disableEslint) || Boolean(disablePrettier) || Boolean(disableBiome);
|
|
127
|
-
},
|
|
128
|
-
get children() {
|
|
129
|
-
return (0, __alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {});
|
|
130
|
-
}
|
|
131
|
-
}),
|
|
132
|
-
(0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
133
|
-
get when() {
|
|
134
|
-
return Boolean(children);
|
|
135
|
-
},
|
|
136
|
-
get children() {
|
|
137
|
-
return [children, (0, __alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {})];
|
|
138
|
-
}
|
|
139
|
-
}),
|
|
140
|
-
(0, __alloy_js_core_jsx_runtime.createComponent)(require_single_line_comment.SingleLineComment, { get children() {
|
|
141
|
-
return __alloy_js_core.code`Generated by ${(0, __stryke_string_format_title_case.titleCase)(context?.config.framework) || "Powerlines"}`;
|
|
142
|
-
} }),
|
|
143
|
-
(0, __alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {}),
|
|
144
|
-
(0, __alloy_js_core_jsx_runtime.createComponent)(require_single_line_comment.SingleLineComment, { children: __alloy_js_core.code`NOTE: Do not edit this file manually - it will be overwritten automatically by the "prepare" command` }),
|
|
145
|
-
(0, __alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {})
|
|
146
|
-
];
|
|
147
|
-
}
|
|
148
|
-
/**
|
|
149
|
-
* Renders the header for a Powerlines Typescript source file.
|
|
150
|
-
*
|
|
151
|
-
* @param props - The properties for the source file header.
|
|
152
|
-
* @returns The rendered source file header.
|
|
153
|
-
*/
|
|
154
|
-
function TypescriptFileHeaderImports(props) {
|
|
155
|
-
const { imports, builtinImports } = props;
|
|
156
|
-
const context = require_context.usePowerlines();
|
|
157
|
-
const sourceFile = (0, __alloy_js_typescript.useSourceFile)();
|
|
158
|
-
const scope = props.scope ?? sourceFile.scope;
|
|
159
|
-
return (0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
160
|
-
get when() {
|
|
161
|
-
return scope.importedModules.size > 0 || !!builtinImports && Object.keys(builtinImports).length > 0 || !!imports && Object.keys(imports).length > 0;
|
|
162
|
-
},
|
|
163
|
-
get children() {
|
|
164
|
-
return [
|
|
165
|
-
(0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
166
|
-
get when() {
|
|
167
|
-
return !!imports && Object.keys(imports).length > 0;
|
|
168
|
-
},
|
|
169
|
-
get children() {
|
|
170
|
-
return (0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.For, {
|
|
171
|
-
get each() {
|
|
172
|
-
return Object.entries(imports ?? {});
|
|
173
|
-
},
|
|
174
|
-
children: ([module$1, normalImports]) => {
|
|
175
|
-
return __alloy_js_core.code`import ${normalImports === null ? "" : ` from ${normalImports.filter((i) => !(0, __stryke_type_checks_is_string.isString)(i) && i.default).map((i) => i.alias ? i.alias : i.name).join(", ") + (normalImports.filter((i) => !(0, __stryke_type_checks_is_string.isString)(i) && i.default).length > 0 && normalImports.filter((i) => (0, __stryke_type_checks_is_string.isString)(i) || !i.default).length > 0 ? ", " : "") + (normalImports.filter((i) => (0, __stryke_type_checks_is_string.isString)(i) || !i.default).length > 0 ? `{ ${normalImports.map((i) => (0, __stryke_type_checks_is_string.isString)(i) ? i : i.alias ? `${i.name} as ${i.alias}` : i.name).join(", ")} }` : "")} `} "${module$1}";`;
|
|
176
|
-
}
|
|
177
|
-
});
|
|
178
|
-
}
|
|
179
|
-
}),
|
|
180
|
-
(0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
181
|
-
get when() {
|
|
182
|
-
return builtinImports && Object.keys(builtinImports).length > 0;
|
|
183
|
-
},
|
|
184
|
-
get children() {
|
|
185
|
-
return (0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.For, {
|
|
186
|
-
get each() {
|
|
187
|
-
return Object.entries(builtinImports ?? {});
|
|
188
|
-
},
|
|
189
|
-
children: ([builtinModule, builtinImports$1]) => __alloy_js_core.code`import ${builtinImports$1 === null ? "" : ` from ${builtinImports$1.filter((i) => !(0, __stryke_type_checks_is_string.isString)(i) && i.default).map((i) => i.alias ? i.alias : i.name).join(", ") + (builtinImports$1.filter((i) => !(0, __stryke_type_checks_is_string.isString)(i) && i.default).length > 0 && builtinImports$1.filter((i) => (0, __stryke_type_checks_is_string.isString)(i) || !i.default).length > 0 ? ", " : "") + (builtinImports$1.filter((i) => (0, __stryke_type_checks_is_string.isString)(i) || !i.default).length > 0 ? `{ ${builtinImports$1.map((i) => (0, __stryke_type_checks_is_string.isString)(i) ? i : i.alias ? `${i.name} as ${i.alias}` : i.name).join(", ")} }` : "")} `} "${builtinModule.includes(":") ? builtinModule : `${context.config.output.builtinPrefix}:${builtinModule}`}";`
|
|
190
|
-
});
|
|
191
|
-
}
|
|
192
|
-
}),
|
|
193
|
-
(0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_core.Show, {
|
|
194
|
-
get when() {
|
|
195
|
-
return scope.importedModules.size > 0;
|
|
196
|
-
},
|
|
197
|
-
get children() {
|
|
198
|
-
return (0, __alloy_js_core_jsx_runtime.createComponent)(__alloy_js_typescript.ImportStatements, { get records() {
|
|
199
|
-
return scope.importedModules;
|
|
200
|
-
} });
|
|
201
|
-
}
|
|
202
|
-
}),
|
|
203
|
-
(0, __alloy_js_core_jsx_runtime.createIntrinsic)("hbr", {})
|
|
204
|
-
];
|
|
205
|
-
}
|
|
206
|
-
});
|
|
207
|
-
}
|
|
208
|
-
|
|
209
|
-
//#endregion
|
|
210
|
-
exports.TypescriptFile = TypescriptFile;
|
|
211
|
-
exports.TypescriptFileHeader = TypescriptFileHeader;
|
|
212
|
-
exports.TypescriptFileHeaderImports = TypescriptFileHeaderImports;
|