@powerlines/plugin-env 0.15.122 → 0.15.124

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (219) hide show
  1. package/dist/babel/plugin.cjs +11 -11
  2. package/dist/babel/plugin.d.cts +2 -2
  3. package/dist/babel/plugin.d.mts +2 -3
  4. package/dist/babel/plugin.mjs +5 -5
  5. package/dist/components/docs.cjs +6 -6
  6. package/dist/components/docs.d.cts +1 -1
  7. package/dist/components/docs.d.mts +1 -1
  8. package/dist/components/docs.mjs +3 -3
  9. package/dist/components/env.cjs +40 -40
  10. package/dist/components/env.d.cts +2 -2
  11. package/dist/components/env.d.mts +2 -2
  12. package/dist/components/env.mjs +11 -11
  13. package/dist/helpers/automd-generator.cjs +2 -2
  14. package/dist/helpers/automd-generator.d.cts +1 -1
  15. package/dist/helpers/automd-generator.d.mts +1 -1
  16. package/dist/helpers/automd-generator.mjs +1 -1
  17. package/dist/helpers/load.cjs +7 -7
  18. package/dist/helpers/load.mjs +8 -8
  19. package/dist/helpers/persistence.cjs +23 -23
  20. package/dist/helpers/persistence.d.cts +1 -1
  21. package/dist/helpers/persistence.d.mts +1 -1
  22. package/dist/helpers/persistence.mjs +5 -5
  23. package/dist/helpers/reflect.cjs +5 -5
  24. package/dist/helpers/reflect.mjs +1 -1
  25. package/dist/helpers/source-file-env.cjs +1 -1
  26. package/dist/helpers/source-file-env.mjs +1 -1
  27. package/dist/index.cjs +13 -10
  28. package/dist/index.d.cts +1 -1
  29. package/dist/index.d.mts +1 -1
  30. package/dist/index.mjs +12 -12
  31. package/dist/types/plugin.cjs +19 -18
  32. package/dist/types/plugin.d.cts +5 -6
  33. package/dist/types/plugin.d.mts +4 -6
  34. package/dist/types/plugin.mjs +4 -4
  35. package/package.json +7 -7
  36. package/dist/deepkit/schemas/reflection.cjs +0 -5426
  37. package/dist/deepkit/schemas/reflection.d.cts +0 -1560
  38. package/dist/deepkit/schemas/reflection.d.mts +0 -1560
  39. package/dist/deepkit/schemas/reflection.mjs +0 -5423
  40. package/dist/deepkit/schemas/reflection2.cjs +0 -4112
  41. package/dist/deepkit/schemas/reflection2.mjs +0 -4110
  42. package/dist/deepkit/src/capnp.cjs +0 -1692
  43. package/dist/deepkit/src/capnp.mjs +0 -1690
  44. package/dist/deepkit/src/esbuild-plugin.cjs +0 -99
  45. package/dist/deepkit/src/esbuild-plugin.mjs +0 -98
  46. package/dist/deepkit/src/reflect-type.cjs +0 -40
  47. package/dist/deepkit/src/reflect-type.mjs +0 -38
  48. package/dist/deepkit/src/resolve-reflections.cjs +0 -23
  49. package/dist/deepkit/src/resolve-reflections.mjs +0 -22
  50. package/dist/deepkit/src/transformer.cjs +0 -92
  51. package/dist/deepkit/src/transformer.mjs +0 -89
  52. package/dist/deepkit/src/transpile.cjs +0 -39
  53. package/dist/deepkit/src/transpile.mjs +0 -37
  54. package/dist/deepkit/src/types.cjs +0 -22
  55. package/dist/deepkit/src/types.d.cts +0 -10
  56. package/dist/deepkit/src/types.d.mts +0 -10
  57. package/dist/deepkit/src/types.mjs +0 -21
  58. package/dist/deepkit/src/utilities.cjs +0 -184
  59. package/dist/deepkit/src/utilities.mjs +0 -183
  60. package/dist/plugin-alloy/src/core/components/output.cjs +0 -43
  61. package/dist/plugin-alloy/src/core/components/output.mjs +0 -42
  62. package/dist/plugin-alloy/src/core/components/single-line-comment.cjs +0 -22
  63. package/dist/plugin-alloy/src/core/components/single-line-comment.mjs +0 -21
  64. package/dist/plugin-alloy/src/core/components/source-file.cjs +0 -64
  65. package/dist/plugin-alloy/src/core/components/source-file.d.cts +0 -23
  66. package/dist/plugin-alloy/src/core/components/source-file.d.mts +0 -23
  67. package/dist/plugin-alloy/src/core/components/source-file.mjs +0 -62
  68. package/dist/plugin-alloy/src/core/contexts/context.cjs +0 -134
  69. package/dist/plugin-alloy/src/core/contexts/context.mjs +0 -126
  70. package/dist/plugin-alloy/src/core/contexts/index.cjs +0 -2
  71. package/dist/plugin-alloy/src/core/contexts/index.mjs +0 -4
  72. package/dist/plugin-alloy/src/core/contexts/reflection.cjs +0 -110
  73. package/dist/plugin-alloy/src/core/contexts/reflection.mjs +0 -101
  74. package/dist/plugin-alloy/src/helpers/refkey.cjs +0 -23
  75. package/dist/plugin-alloy/src/helpers/refkey.mjs +0 -22
  76. package/dist/plugin-alloy/src/index.cjs +0 -105
  77. package/dist/plugin-alloy/src/index.mjs +0 -103
  78. package/dist/plugin-alloy/src/markdown/components/markdown-file.cjs +0 -115
  79. package/dist/plugin-alloy/src/markdown/components/markdown-file.d.cts +0 -8
  80. package/dist/plugin-alloy/src/markdown/components/markdown-file.d.mts +0 -8
  81. package/dist/plugin-alloy/src/markdown/components/markdown-file.mjs +0 -114
  82. package/dist/plugin-alloy/src/markdown/components/markdown-table.cjs +0 -39
  83. package/dist/plugin-alloy/src/markdown/components/markdown-table.mjs +0 -38
  84. package/dist/plugin-alloy/src/markdown/contexts/markdown-table.cjs +0 -72
  85. package/dist/plugin-alloy/src/markdown/contexts/markdown-table.mjs +0 -71
  86. package/dist/plugin-alloy/src/types/components.cjs +0 -22
  87. package/dist/plugin-alloy/src/types/components.d.cts +0 -20
  88. package/dist/plugin-alloy/src/types/components.d.mts +0 -21
  89. package/dist/plugin-alloy/src/types/components.mjs +0 -21
  90. package/dist/plugin-alloy/src/types/index.d.cts +0 -2
  91. package/dist/plugin-alloy/src/types/index.d.mts +0 -2
  92. package/dist/plugin-alloy/src/types/plugin.cjs +0 -53
  93. package/dist/plugin-alloy/src/types/plugin.d.cts +0 -36
  94. package/dist/plugin-alloy/src/types/plugin.d.mts +0 -36
  95. package/dist/plugin-alloy/src/types/plugin.mjs +0 -50
  96. package/dist/plugin-alloy/src/typescript/components/builtin-file.cjs +0 -62
  97. package/dist/plugin-alloy/src/typescript/components/builtin-file.d.cts +0 -26
  98. package/dist/plugin-alloy/src/typescript/components/builtin-file.d.mts +0 -26
  99. package/dist/plugin-alloy/src/typescript/components/builtin-file.mjs +0 -61
  100. package/dist/plugin-alloy/src/typescript/components/tsdoc-reflection.cjs +0 -131
  101. package/dist/plugin-alloy/src/typescript/components/tsdoc-reflection.mjs +0 -129
  102. package/dist/plugin-alloy/src/typescript/components/tsdoc.cjs +0 -451
  103. package/dist/plugin-alloy/src/typescript/components/tsdoc.d.cts +0 -37
  104. package/dist/plugin-alloy/src/typescript/components/tsdoc.d.mts +0 -37
  105. package/dist/plugin-alloy/src/typescript/components/tsdoc.mjs +0 -442
  106. package/dist/plugin-alloy/src/typescript/components/typescript-file.cjs +0 -216
  107. package/dist/plugin-alloy/src/typescript/components/typescript-file.d.cts +0 -16
  108. package/dist/plugin-alloy/src/typescript/components/typescript-file.d.mts +0 -16
  109. package/dist/plugin-alloy/src/typescript/components/typescript-file.mjs +0 -213
  110. package/dist/plugin-alloy/src/typescript/components/typescript-interface.cjs +0 -72
  111. package/dist/plugin-alloy/src/typescript/components/typescript-interface.d.cts +0 -12
  112. package/dist/plugin-alloy/src/typescript/components/typescript-interface.d.mts +0 -12
  113. package/dist/plugin-alloy/src/typescript/components/typescript-interface.mjs +0 -71
  114. package/dist/plugin-alloy/src/typescript/components/typescript-object.cjs +0 -124
  115. package/dist/plugin-alloy/src/typescript/components/typescript-object.mjs +0 -123
  116. package/dist/plugin-automd/src/index.cjs +0 -127
  117. package/dist/plugin-automd/src/index.mjs +0 -124
  118. package/dist/plugin-automd/src/types/plugin.cjs +0 -47
  119. package/dist/plugin-automd/src/types/plugin.d.cts +0 -38
  120. package/dist/plugin-automd/src/types/plugin.d.mts +0 -40
  121. package/dist/plugin-automd/src/types/plugin.mjs +0 -47
  122. package/dist/plugin-automd/src/types/toc.cjs +0 -26
  123. package/dist/plugin-automd/src/types/toc.d.cts +0 -33
  124. package/dist/plugin-automd/src/types/toc.d.mts +0 -33
  125. package/dist/plugin-automd/src/types/toc.mjs +0 -25
  126. package/dist/plugin-babel/src/helpers/ast-utils.cjs +0 -74
  127. package/dist/plugin-babel/src/helpers/ast-utils.mjs +0 -70
  128. package/dist/plugin-babel/src/helpers/create-plugin.cjs +0 -71
  129. package/dist/plugin-babel/src/helpers/create-plugin.mjs +0 -69
  130. package/dist/plugin-babel/src/helpers/filters.cjs +0 -158
  131. package/dist/plugin-babel/src/helpers/filters.mjs +0 -154
  132. package/dist/plugin-babel/src/helpers/index.cjs +0 -5
  133. package/dist/plugin-babel/src/helpers/index.mjs +0 -7
  134. package/dist/plugin-babel/src/helpers/module-helpers.cjs +0 -200
  135. package/dist/plugin-babel/src/helpers/module-helpers.mjs +0 -192
  136. package/dist/plugin-babel/src/helpers/options.cjs +0 -73
  137. package/dist/plugin-babel/src/helpers/options.mjs +0 -70
  138. package/dist/plugin-babel/src/index.cjs +0 -125
  139. package/dist/plugin-babel/src/index.mjs +0 -123
  140. package/dist/plugin-babel/src/types/index.d.mts +0 -1
  141. package/dist/plugin-babel/src/types/plugin.cjs +0 -42
  142. package/dist/plugin-babel/src/types/plugin.d.cts +0 -15
  143. package/dist/plugin-babel/src/types/plugin.d.mts +0 -15
  144. package/dist/plugin-babel/src/types/plugin.mjs +0 -39
  145. package/dist/powerlines/src/internal/helpers/hooks.cjs +0 -136
  146. package/dist/powerlines/src/internal/helpers/hooks.d.cts +0 -47
  147. package/dist/powerlines/src/internal/helpers/hooks.d.mts +0 -49
  148. package/dist/powerlines/src/internal/helpers/hooks.mjs +0 -134
  149. package/dist/powerlines/src/lib/build/esbuild.cjs +0 -142
  150. package/dist/powerlines/src/lib/build/esbuild.mjs +0 -140
  151. package/dist/powerlines/src/lib/constants/environments.cjs +0 -6
  152. package/dist/powerlines/src/lib/constants/environments.mjs +0 -5
  153. package/dist/powerlines/src/lib/entry.cjs +0 -195
  154. package/dist/powerlines/src/lib/entry.mjs +0 -194
  155. package/dist/powerlines/src/lib/logger.cjs +0 -108
  156. package/dist/powerlines/src/lib/logger.mjs +0 -106
  157. package/dist/powerlines/src/lib/unplugin/helpers.cjs +0 -41
  158. package/dist/powerlines/src/lib/unplugin/helpers.mjs +0 -40
  159. package/dist/powerlines/src/lib/unplugin/module-resolution.cjs +0 -98
  160. package/dist/powerlines/src/lib/unplugin/module-resolution.mjs +0 -97
  161. package/dist/powerlines/src/lib/unplugin/plugin.cjs +0 -139
  162. package/dist/powerlines/src/lib/unplugin/plugin.mjs +0 -138
  163. package/dist/powerlines/src/lib/utilities/bundle.cjs +0 -74
  164. package/dist/powerlines/src/lib/utilities/bundle.mjs +0 -72
  165. package/dist/powerlines/src/lib/utilities/resolve.cjs +0 -69
  166. package/dist/powerlines/src/lib/utilities/resolve.mjs +0 -68
  167. package/dist/powerlines/src/lib/utilities/source-file.cjs +0 -68
  168. package/dist/powerlines/src/lib/utilities/source-file.mjs +0 -66
  169. package/dist/powerlines/src/plugin-utils/paths.cjs +0 -46
  170. package/dist/powerlines/src/plugin-utils/paths.mjs +0 -45
  171. package/dist/powerlines/src/types/api.cjs +0 -62
  172. package/dist/powerlines/src/types/api.d.cts +0 -104
  173. package/dist/powerlines/src/types/api.d.mts +0 -104
  174. package/dist/powerlines/src/types/api.mjs +0 -62
  175. package/dist/powerlines/src/types/babel.cjs +0 -156
  176. package/dist/powerlines/src/types/babel.d.cts +0 -23
  177. package/dist/powerlines/src/types/babel.d.mts +0 -23
  178. package/dist/powerlines/src/types/babel.mjs +0 -147
  179. package/dist/powerlines/src/types/build.cjs +0 -127
  180. package/dist/powerlines/src/types/build.d.cts +0 -185
  181. package/dist/powerlines/src/types/build.d.mts +0 -185
  182. package/dist/powerlines/src/types/build.mjs +0 -121
  183. package/dist/powerlines/src/types/commands.cjs +0 -16
  184. package/dist/powerlines/src/types/commands.d.cts +0 -8
  185. package/dist/powerlines/src/types/commands.d.mts +0 -9
  186. package/dist/powerlines/src/types/commands.mjs +0 -15
  187. package/dist/powerlines/src/types/config.cjs +0 -420
  188. package/dist/powerlines/src/types/config.d.cts +0 -435
  189. package/dist/powerlines/src/types/config.d.mts +0 -436
  190. package/dist/powerlines/src/types/config.mjs +0 -397
  191. package/dist/powerlines/src/types/context.cjs +0 -388
  192. package/dist/powerlines/src/types/context.d.cts +0 -514
  193. package/dist/powerlines/src/types/context.d.mts +0 -514
  194. package/dist/powerlines/src/types/context.mjs +0 -371
  195. package/dist/powerlines/src/types/fs.cjs +0 -78
  196. package/dist/powerlines/src/types/fs.d.cts +0 -486
  197. package/dist/powerlines/src/types/fs.d.mts +0 -486
  198. package/dist/powerlines/src/types/fs.mjs +0 -75
  199. package/dist/powerlines/src/types/hooks.cjs +0 -71
  200. package/dist/powerlines/src/types/hooks.d.cts +0 -32
  201. package/dist/powerlines/src/types/hooks.d.mts +0 -32
  202. package/dist/powerlines/src/types/hooks.mjs +0 -68
  203. package/dist/powerlines/src/types/index.cjs +0 -11
  204. package/dist/powerlines/src/types/index.d.mts +0 -12
  205. package/dist/powerlines/src/types/index.mjs +0 -13
  206. package/dist/powerlines/src/types/plugin.cjs +0 -184
  207. package/dist/powerlines/src/types/plugin.d.cts +0 -205
  208. package/dist/powerlines/src/types/plugin.d.mts +0 -205
  209. package/dist/powerlines/src/types/plugin.mjs +0 -178
  210. package/dist/powerlines/src/types/resolved.cjs +0 -149
  211. package/dist/powerlines/src/types/resolved.d.cts +0 -94
  212. package/dist/powerlines/src/types/resolved.d.mts +0 -94
  213. package/dist/powerlines/src/types/resolved.mjs +0 -144
  214. package/dist/powerlines/src/types/tsconfig.d.cts +0 -69
  215. package/dist/powerlines/src/types/tsconfig.d.mts +0 -69
  216. package/dist/powerlines/src/types/unplugin.cjs +0 -64
  217. package/dist/powerlines/src/types/unplugin.d.cts +0 -22
  218. package/dist/powerlines/src/types/unplugin.d.mts +0 -23
  219. package/dist/powerlines/src/types/unplugin.mjs +0 -62
@@ -1,108 +0,0 @@
1
- const require_rolldown_runtime = require('../../../_virtual/rolldown_runtime.cjs');
2
- let __stryke_string_format_title_case = require("@stryke/string-format/title-case");
3
- let chalk = require("chalk");
4
- chalk = require_rolldown_runtime.__toESM(chalk);
5
- let __storm_software_config_tools_types = require("@storm-software/config-tools/types");
6
- let __stryke_string_format_kebab_case = require("@stryke/string-format/kebab-case");
7
- let __storm_software_config_tools_logger = require("@storm-software/config-tools/logger");
8
- let __storm_software_config_tools_utilities_colors = require("@storm-software/config-tools/utilities/colors");
9
- let __stryke_helpers_noop = require("@stryke/helpers/noop");
10
-
11
- //#region ../powerlines/src/lib/logger.ts
12
- function __assignType(fn, args) {
13
- fn.__type = args;
14
- return fn;
15
- }
16
- const __ΩCreateLogOptions = [
17
- "name",
18
- "LogLevelLabel",
19
- "logLevel",
20
- "LogFn",
21
- "customLogger",
22
- "WorkspaceConfig",
23
- "colors",
24
- "colors",
25
- "CreateLogOptions",
26
- "P&4!8P\"w\",J4#8\"w$4%8\"w&.'f4(8Mw)y"
27
- ];
28
- /**
29
- * Create a logging function with a specific name and options.
30
- *
31
- * @param name - The name of the logging function.
32
- * @param options - The options to configure the logging function.
33
- * @returns A logging function.
34
- */
35
- const createLog = __assignType((name, options = {}) => {
36
- const logLevel = options.logLevel === null ? __storm_software_config_tools_types.LogLevelLabel.SILENT : options.logLevel || __storm_software_config_tools_types.LogLevelLabel.INFO;
37
- if (logLevel === __storm_software_config_tools_types.LogLevelLabel.SILENT) return __stryke_helpers_noop.noop;
38
- if (options.customLogger) return options.customLogger;
39
- return __assignType((type, ...args) => (0, __storm_software_config_tools_logger.getLogFn)((0, __storm_software_config_tools_logger.getLogLevel)(type), {
40
- ...options,
41
- logLevel
42
- })(`${chalk.default.bold.hex((0, __storm_software_config_tools_utilities_colors.getColor)("brand", options))(`${name ? (0, __stryke_string_format_kebab_case.kebabCase)(name) : ""}${options.name ? `${name ? chalk.default.gray(" > ") : ""}${(0, __stryke_string_format_kebab_case.kebabCase)(options.name)}` : ""}${chalk.default.gray(" > ")}`)}${args.join(" ")} `.trim()), [
43
- "LogLevelLabel",
44
- "type",
45
- "args",
46
- "",
47
- "P\"w!2\"&@2#\"/$"
48
- ]);
49
- }, [
50
- "name",
51
- () => __ΩCreateLogOptions,
52
- "options",
53
- () => ({}),
54
- "LogFn",
55
- "",
56
- "PP&,J2!n\"2#>$\"w%/&"
57
- ]);
58
- const BADGE_COLORS = [
59
- "#00A0DD",
60
- "#6FCE4E",
61
- "#FBBF24",
62
- "#F43F5E",
63
- "#3B82F6",
64
- "#A855F7",
65
- "#469592",
66
- "#288EDF",
67
- "#D8B4FE",
68
- "#10B981",
69
- "#EF4444",
70
- "#F0EC56",
71
- "#F472B6",
72
- "#22D3EE",
73
- "#EAB308",
74
- "#84CC16",
75
- "#F87171",
76
- "#0EA5E9",
77
- "#D946EF",
78
- "#FACC15",
79
- "#34D399",
80
- "#8B5CF6"
81
- ];
82
- const extendLog = __assignType((logFn, name) => {
83
- return __assignType((type, ...args) => logFn(type, ` ${chalk.default.inverse.hex(BADGE_COLORS[name.split("").map(__assignType((char) => char.charCodeAt(0), [
84
- "char",
85
- "",
86
- "P\"2!\"/\""
87
- ])).reduce(__assignType((ret, charCode) => ret + charCode, [
88
- "ret",
89
- "charCode",
90
- "",
91
- "P\"2!\"2\"\"/#"
92
- ]), 0) % BADGE_COLORS.length] || BADGE_COLORS[0])(` ${(0, __stryke_string_format_title_case.titleCase)(name)} `)} ${args.join(" ")} `), [
93
- "LogLevelLabel",
94
- "type",
95
- "args",
96
- "",
97
- "P\"w!2\"&@2#\"/$"
98
- ]);
99
- }, [
100
- "LogFn",
101
- "logFn",
102
- "name",
103
- "",
104
- "P\"w!2\"&2#\"w!/$"
105
- ]);
106
-
107
- //#endregion
108
- exports.extendLog = extendLog;
@@ -1,106 +0,0 @@
1
- import { titleCase } from "@stryke/string-format/title-case";
2
- import chalk from "chalk";
3
- import { LogLevelLabel } from "@storm-software/config-tools/types";
4
- import { kebabCase } from "@stryke/string-format/kebab-case";
5
- import { getLogFn, getLogLevel } from "@storm-software/config-tools/logger";
6
- import { getColor } from "@storm-software/config-tools/utilities/colors";
7
- import { noop } from "@stryke/helpers/noop";
8
-
9
- //#region ../powerlines/src/lib/logger.ts
10
- function __assignType(fn, args) {
11
- fn.__type = args;
12
- return fn;
13
- }
14
- const __ΩCreateLogOptions = [
15
- "name",
16
- "LogLevelLabel",
17
- "logLevel",
18
- "LogFn",
19
- "customLogger",
20
- "WorkspaceConfig",
21
- "colors",
22
- "colors",
23
- "CreateLogOptions",
24
- "P&4!8P\"w\",J4#8\"w$4%8\"w&.'f4(8Mw)y"
25
- ];
26
- /**
27
- * Create a logging function with a specific name and options.
28
- *
29
- * @param name - The name of the logging function.
30
- * @param options - The options to configure the logging function.
31
- * @returns A logging function.
32
- */
33
- const createLog = __assignType((name, options = {}) => {
34
- const logLevel = options.logLevel === null ? LogLevelLabel.SILENT : options.logLevel || LogLevelLabel.INFO;
35
- if (logLevel === LogLevelLabel.SILENT) return noop;
36
- if (options.customLogger) return options.customLogger;
37
- return __assignType((type, ...args) => getLogFn(getLogLevel(type), {
38
- ...options,
39
- logLevel
40
- })(`${chalk.bold.hex(getColor("brand", options))(`${name ? kebabCase(name) : ""}${options.name ? `${name ? chalk.gray(" > ") : ""}${kebabCase(options.name)}` : ""}${chalk.gray(" > ")}`)}${args.join(" ")} `.trim()), [
41
- "LogLevelLabel",
42
- "type",
43
- "args",
44
- "",
45
- "P\"w!2\"&@2#\"/$"
46
- ]);
47
- }, [
48
- "name",
49
- () => __ΩCreateLogOptions,
50
- "options",
51
- () => ({}),
52
- "LogFn",
53
- "",
54
- "PP&,J2!n\"2#>$\"w%/&"
55
- ]);
56
- const BADGE_COLORS = [
57
- "#00A0DD",
58
- "#6FCE4E",
59
- "#FBBF24",
60
- "#F43F5E",
61
- "#3B82F6",
62
- "#A855F7",
63
- "#469592",
64
- "#288EDF",
65
- "#D8B4FE",
66
- "#10B981",
67
- "#EF4444",
68
- "#F0EC56",
69
- "#F472B6",
70
- "#22D3EE",
71
- "#EAB308",
72
- "#84CC16",
73
- "#F87171",
74
- "#0EA5E9",
75
- "#D946EF",
76
- "#FACC15",
77
- "#34D399",
78
- "#8B5CF6"
79
- ];
80
- const extendLog = __assignType((logFn, name) => {
81
- return __assignType((type, ...args) => logFn(type, ` ${chalk.inverse.hex(BADGE_COLORS[name.split("").map(__assignType((char) => char.charCodeAt(0), [
82
- "char",
83
- "",
84
- "P\"2!\"/\""
85
- ])).reduce(__assignType((ret, charCode) => ret + charCode, [
86
- "ret",
87
- "charCode",
88
- "",
89
- "P\"2!\"2\"\"/#"
90
- ]), 0) % BADGE_COLORS.length] || BADGE_COLORS[0])(` ${titleCase(name)} `)} ${args.join(" ")} `), [
91
- "LogLevelLabel",
92
- "type",
93
- "args",
94
- "",
95
- "P\"w!2\"&@2#\"/$"
96
- ]);
97
- }, [
98
- "LogFn",
99
- "logFn",
100
- "name",
101
- "",
102
- "P\"w!2\"&2#\"w!/$"
103
- ]);
104
-
105
- //#endregion
106
- export { extendLog };
@@ -1,41 +0,0 @@
1
- const require_rolldown_runtime = require('../../../../_virtual/rolldown_runtime.cjs');
2
- const require_build = require('../../types/build.cjs');
3
- let defu = require("defu");
4
- let __stryke_type_checks_is_set_string = require("@stryke/type-checks/is-set-string");
5
-
6
- //#region ../powerlines/src/lib/unplugin/helpers.ts
7
- /**
8
- * Merges a base plugin context with an unplugin context, combining their properties.
9
- *
10
- * @param context - The base plugin context to merge into.
11
- * @param unplugin - The unplugin context to merge from.
12
- * @returns The merged context.
13
- */
14
- function combineContexts(context, unplugin) {
15
- return (0, defu.defu)(context, unplugin);
16
- }
17
- combineContexts.__type = [
18
- "context",
19
- "unplugin",
20
- "combineContexts",
21
- "Merges a base plugin context with an unplugin context, combining their properties.",
22
- "P\"2!P!!K2\"\"/#?$"
23
- ];
24
- /**
25
- * Checks if a value is a valid UnpluginBuilderVariant.
26
- *
27
- * @param str - The value to check.
28
- * @returns True if the value is a UnpluginBuilderVariant, false otherwise.
29
- */
30
- function isUnpluginBuilderVariant(str) {
31
- return (0, __stryke_type_checks_is_set_string.isSetString)(str) && require_build.UNPLUGIN_BUILDER_VARIANTS.includes(str);
32
- }
33
- isUnpluginBuilderVariant.__type = [
34
- "str",
35
- "isUnpluginBuilderVariant",
36
- "Checks if a value is a valid UnpluginBuilderVariant.",
37
- "P#2!!/\"?#"
38
- ];
39
-
40
- //#endregion
41
- exports.combineContexts = combineContexts;
@@ -1,40 +0,0 @@
1
- import { UNPLUGIN_BUILDER_VARIANTS } from "../../types/build.mjs";
2
- import { defu } from "defu";
3
- import { isSetString } from "@stryke/type-checks/is-set-string";
4
-
5
- //#region ../powerlines/src/lib/unplugin/helpers.ts
6
- /**
7
- * Merges a base plugin context with an unplugin context, combining their properties.
8
- *
9
- * @param context - The base plugin context to merge into.
10
- * @param unplugin - The unplugin context to merge from.
11
- * @returns The merged context.
12
- */
13
- function combineContexts(context, unplugin) {
14
- return defu(context, unplugin);
15
- }
16
- combineContexts.__type = [
17
- "context",
18
- "unplugin",
19
- "combineContexts",
20
- "Merges a base plugin context with an unplugin context, combining their properties.",
21
- "P\"2!P!!K2\"\"/#?$"
22
- ];
23
- /**
24
- * Checks if a value is a valid UnpluginBuilderVariant.
25
- *
26
- * @param str - The value to check.
27
- * @returns True if the value is a UnpluginBuilderVariant, false otherwise.
28
- */
29
- function isUnpluginBuilderVariant(str) {
30
- return isSetString(str) && UNPLUGIN_BUILDER_VARIANTS.includes(str);
31
- }
32
- isUnpluginBuilderVariant.__type = [
33
- "str",
34
- "isUnpluginBuilderVariant",
35
- "Checks if a value is a valid UnpluginBuilderVariant.",
36
- "P#2!!/\"?#"
37
- ];
38
-
39
- //#endregion
40
- export { combineContexts };
@@ -1,98 +0,0 @@
1
-
2
- //#region ../powerlines/src/lib/unplugin/module-resolution.ts
3
- const __ΩPick = [
4
- "T",
5
- "K",
6
- "Pick",
7
- "l+e#!e\"!fRb!b\"Pde\"\"N#!w#y"
8
- ];
9
- /**
10
- * Creates the module resolution hook functions for a Powerlines unplugin plugin instance.
11
- *
12
- * @remarks
13
- * This includes the `resolveId` and `load` hooks.
14
- *
15
- * @see https://rollupjs.org/plugin-development/#resolveid
16
- * @see https://rollupjs.org/plugin-development/#load
17
- *
18
- * @param context - The plugin context.
19
- * @returns The module resolution hooks (`resolveId` and `load`).
20
- */
21
- function createUnpluginModuleResolutionFunctions(context) {
22
- const ctx = context;
23
- async function resolveId(id, importer, opts = { isEntry: false }) {
24
- let result = await ctx.$$internal.callHook("resolveId", {
25
- sequential: true,
26
- result: "first",
27
- order: "pre"
28
- }, id, importer, opts);
29
- if (result) return result;
30
- result = await ctx.$$internal.callHook("resolveId", {
31
- sequential: true,
32
- result: "first",
33
- order: "normal"
34
- }, id, importer, opts);
35
- if (result) return result;
36
- result = await ctx.resolve(id, importer, opts);
37
- if (result) return result;
38
- return ctx.$$internal.callHook("resolveId", {
39
- sequential: true,
40
- result: "first",
41
- order: "post"
42
- }, id, importer, opts);
43
- }
44
- resolveId.__type = [
45
- "this",
46
- "id",
47
- "importer",
48
- "isEntry",
49
- "opts",
50
- () => ({ isEntry: false }),
51
- "resolveId",
52
- "PP!!K2!&2\"&2#8P)4$M2%>&P&!,-J`/'"
53
- ];
54
- async function load(id) {
55
- let result = await ctx.$$internal.callHook("load", {
56
- sequential: true,
57
- result: "first",
58
- order: "pre"
59
- }, id);
60
- if (result) return result;
61
- result = await ctx.$$internal.callHook("load", {
62
- sequential: true,
63
- result: "first",
64
- order: "normal"
65
- }, id);
66
- if (result) return result;
67
- result = await ctx.load(id);
68
- if (result) return result;
69
- return ctx.$$internal.callHook("load", {
70
- sequential: true,
71
- result: "first",
72
- order: "post"
73
- }, id);
74
- }
75
- load.__type = [
76
- "this",
77
- "id",
78
- "LoadResult",
79
- "load",
80
- "PP!!K2!&2\"P\"w#,-J`/$"
81
- ];
82
- return {
83
- resolveId,
84
- load
85
- };
86
- }
87
- createUnpluginModuleResolutionFunctions.__type = [
88
- "context",
89
- () => __ΩPick,
90
- "resolveId",
91
- "load",
92
- "createUnpluginModuleResolutionFunctions",
93
- "Creates the module resolution hook functions for a Powerlines unplugin plugin instance.",
94
- "P\"2!!P.#.$Jo\"#/%?&"
95
- ];
96
-
97
- //#endregion
98
- exports.createUnpluginModuleResolutionFunctions = createUnpluginModuleResolutionFunctions;
@@ -1,97 +0,0 @@
1
- //#region ../powerlines/src/lib/unplugin/module-resolution.ts
2
- const __ΩPick = [
3
- "T",
4
- "K",
5
- "Pick",
6
- "l+e#!e\"!fRb!b\"Pde\"\"N#!w#y"
7
- ];
8
- /**
9
- * Creates the module resolution hook functions for a Powerlines unplugin plugin instance.
10
- *
11
- * @remarks
12
- * This includes the `resolveId` and `load` hooks.
13
- *
14
- * @see https://rollupjs.org/plugin-development/#resolveid
15
- * @see https://rollupjs.org/plugin-development/#load
16
- *
17
- * @param context - The plugin context.
18
- * @returns The module resolution hooks (`resolveId` and `load`).
19
- */
20
- function createUnpluginModuleResolutionFunctions(context) {
21
- const ctx = context;
22
- async function resolveId(id, importer, opts = { isEntry: false }) {
23
- let result = await ctx.$$internal.callHook("resolveId", {
24
- sequential: true,
25
- result: "first",
26
- order: "pre"
27
- }, id, importer, opts);
28
- if (result) return result;
29
- result = await ctx.$$internal.callHook("resolveId", {
30
- sequential: true,
31
- result: "first",
32
- order: "normal"
33
- }, id, importer, opts);
34
- if (result) return result;
35
- result = await ctx.resolve(id, importer, opts);
36
- if (result) return result;
37
- return ctx.$$internal.callHook("resolveId", {
38
- sequential: true,
39
- result: "first",
40
- order: "post"
41
- }, id, importer, opts);
42
- }
43
- resolveId.__type = [
44
- "this",
45
- "id",
46
- "importer",
47
- "isEntry",
48
- "opts",
49
- () => ({ isEntry: false }),
50
- "resolveId",
51
- "PP!!K2!&2\"&2#8P)4$M2%>&P&!,-J`/'"
52
- ];
53
- async function load(id) {
54
- let result = await ctx.$$internal.callHook("load", {
55
- sequential: true,
56
- result: "first",
57
- order: "pre"
58
- }, id);
59
- if (result) return result;
60
- result = await ctx.$$internal.callHook("load", {
61
- sequential: true,
62
- result: "first",
63
- order: "normal"
64
- }, id);
65
- if (result) return result;
66
- result = await ctx.load(id);
67
- if (result) return result;
68
- return ctx.$$internal.callHook("load", {
69
- sequential: true,
70
- result: "first",
71
- order: "post"
72
- }, id);
73
- }
74
- load.__type = [
75
- "this",
76
- "id",
77
- "LoadResult",
78
- "load",
79
- "PP!!K2!&2\"P\"w#,-J`/$"
80
- ];
81
- return {
82
- resolveId,
83
- load
84
- };
85
- }
86
- createUnpluginModuleResolutionFunctions.__type = [
87
- "context",
88
- () => __ΩPick,
89
- "resolveId",
90
- "load",
91
- "createUnpluginModuleResolutionFunctions",
92
- "Creates the module resolution hook functions for a Powerlines unplugin plugin instance.",
93
- "P\"2!!P.#.$Jo\"#/%?&"
94
- ];
95
-
96
- //#endregion
97
- export { createUnpluginModuleResolutionFunctions };
@@ -1,139 +0,0 @@
1
- const require_rolldown_runtime = require('../../../../_virtual/rolldown_runtime.cjs');
2
- const require_context = require('../../types/context.cjs');
3
- const require_unplugin = require('../../types/unplugin.cjs');
4
- const require_logger = require('../logger.cjs');
5
- const require_source_file = require('../utilities/source-file.cjs');
6
- const require_helpers = require('./helpers.cjs');
7
- const require_module_resolution = require('./module-resolution.cjs');
8
- let __stryke_string_format_title_case = require("@stryke/string-format/title-case");
9
- let unplugin = require("unplugin");
10
- let __storm_software_config_tools_types = require("@storm-software/config-tools/types");
11
- let __stryke_string_format_kebab_case = require("@stryke/string-format/kebab-case");
12
-
13
- //#region ../powerlines/src/lib/unplugin/plugin.ts
14
- /**
15
- * Creates a Powerlines unplugin instance.
16
- *
17
- * @param context - The plugin context.
18
- * @returns The unplugin instance.
19
- */
20
- function createUnpluginResolver(context, name = "unplugin") {
21
- const ctx = context;
22
- (0, unplugin.setParseImpl)(ctx.parse);
23
- return () => {
24
- const log = require_logger.extendLog(ctx.log, name);
25
- log(__storm_software_config_tools_types.LogLevelLabel.DEBUG, `Initializing ${name.toLowerCase() === "unplugin" ? "Unplugin" : `${(0, __stryke_string_format_title_case.titleCase)(name)} - Unplugin`} plugin`);
26
- try {
27
- const { resolveId, load } = (require_module_resolution.createUnpluginModuleResolutionFunctions.Ω = [[() => require_context.__ΩPluginContext, "n!"]], require_module_resolution.createUnpluginModuleResolutionFunctions(context));
28
- return {
29
- name: name.toLowerCase() === "unplugin" ? "powerlines" : `powerlines:${(0, __stryke_string_format_kebab_case.kebabCase)(name)}`,
30
- api: ctx.$$internal.api,
31
- resolveId: {
32
- filter: { id: { include: [/.*/] } },
33
- handler: resolveId
34
- },
35
- load: {
36
- filter: { id: { include: [/.*/] } },
37
- handler: load
38
- }
39
- };
40
- } catch (error) {
41
- log(__storm_software_config_tools_types.LogLevelLabel.FATAL, error?.message);
42
- throw error;
43
- }
44
- };
45
- }
46
- createUnpluginResolver.__type = [
47
- "context",
48
- "name",
49
- () => require_unplugin.__ΩUnpluginFactory,
50
- "createUnpluginResolver",
51
- "Creates a Powerlines unplugin instance.",
52
- "P\"2!\"2\"\"o#\"/$?%"
53
- ];
54
- /**
55
- * Creates a Powerlines unplugin instance.
56
- *
57
- * @param context - The plugin context.
58
- * @returns The unplugin instance.
59
- */
60
- function createUnplugin(context, name = "unplugin") {
61
- const ctx = context;
62
- (0, unplugin.setParseImpl)(ctx.parse);
63
- return () => {
64
- const log = require_logger.extendLog(ctx.log, name);
65
- log(__storm_software_config_tools_types.LogLevelLabel.DEBUG, `Initializing ${name.toLowerCase() === "unplugin" ? "Unplugin" : `${(0, __stryke_string_format_title_case.titleCase)(name)} - Unplugin`} plugin`);
66
- try {
67
- const { resolveId, load } = (require_module_resolution.createUnpluginModuleResolutionFunctions.Ω = [[() => require_context.__ΩPluginContext, "n!"]], require_module_resolution.createUnpluginModuleResolutionFunctions(context));
68
- async function buildStart() {
69
- log(__storm_software_config_tools_types.LogLevelLabel.DEBUG, "Powerlines build plugin starting...");
70
- await ctx.$$internal.callHook("buildStart", { sequential: true });
71
- }
72
- buildStart.__type = [
73
- "this",
74
- "buildStart",
75
- "P!2!\"/\""
76
- ];
77
- async function transform(code, id) {
78
- let transformed = code;
79
- for (const hook of ctx.$$internal.environment.selectHooks("transform")) {
80
- const result = await hook.handler.apply(require_helpers.combineContexts(ctx, this), [require_source_file.getString(transformed), id]);
81
- if (result) transformed = result;
82
- }
83
- return transformed;
84
- }
85
- transform.__type = [
86
- "this",
87
- "code",
88
- "id",
89
- "transform",
90
- "PP!!K2!&2\"&2#P!,-J`/$"
91
- ];
92
- async function buildEnd() {
93
- log(__storm_software_config_tools_types.LogLevelLabel.DEBUG, "Powerlines build plugin finishing...");
94
- return ctx.$$internal.callHook("buildEnd", { sequential: true });
95
- }
96
- buildEnd.__type = [
97
- "this",
98
- "buildEnd",
99
- "P!2!$`/\""
100
- ];
101
- async function writeBundle() {
102
- log(__storm_software_config_tools_types.LogLevelLabel.DEBUG, "Finalizing Powerlines project output...");
103
- return ctx.$$internal.callHook("writeBundle", { sequential: true });
104
- }
105
- writeBundle.__type = ["writeBundle", "P$`/!"];
106
- return {
107
- name: name.toLowerCase() === "unplugin" ? "powerlines" : `powerlines:${(0, __stryke_string_format_kebab_case.kebabCase)(name)}`,
108
- api: ctx.$$internal.api,
109
- resolveId: {
110
- filter: { id: { include: [/.*/] } },
111
- handler: resolveId
112
- },
113
- load: {
114
- filter: { id: { include: [/.*/] } },
115
- handler: load
116
- },
117
- transform,
118
- buildStart,
119
- buildEnd,
120
- writeBundle,
121
- vite: { sharedDuringBuild: true }
122
- };
123
- } catch (error) {
124
- log(__storm_software_config_tools_types.LogLevelLabel.FATAL, error?.message);
125
- throw error;
126
- }
127
- };
128
- }
129
- createUnplugin.__type = [
130
- "context",
131
- "name",
132
- () => require_unplugin.__ΩUnpluginFactory,
133
- "createUnplugin",
134
- "Creates a Powerlines unplugin instance.",
135
- "P\"2!\"2\"\"o#\"/$?%"
136
- ];
137
-
138
- //#endregion
139
- exports.createUnpluginResolver = createUnpluginResolver;