@powerlines/plugin-date 0.12.151 → 0.12.153

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 (151) hide show
  1. package/dist/components/date-fns.cjs +3 -2
  2. package/dist/components/date-fns.mjs +1 -1
  3. package/dist/components/dayjs.cjs +3 -2
  4. package/dist/components/dayjs.mjs +1 -1
  5. package/dist/components/luxon.cjs +3 -2
  6. package/dist/components/luxon.mjs +1 -1
  7. package/dist/components/moment.cjs +3 -2
  8. package/dist/components/moment.mjs +1 -1
  9. package/dist/index.cjs +5 -5
  10. package/dist/index.d.mts +1 -1
  11. package/dist/index.mjs +3 -3
  12. package/dist/node_modules/.pnpm/defu@6.1.4/node_modules/defu/dist/defu.cjs +43 -0
  13. package/dist/node_modules/.pnpm/defu@6.1.4/node_modules/defu/dist/defu.mjs +42 -0
  14. package/dist/packages/plugin-alloy/src/types/components.d.mts +2 -0
  15. package/dist/{plugin-env → packages/plugin-env}/src/types/plugin.d.mts +1 -1
  16. package/dist/{powerlines → packages/powerlines}/src/types/build.d.mts +6 -6
  17. package/dist/{powerlines → packages/powerlines}/src/types/config.d.mts +1 -2
  18. package/dist/{powerlines → packages/powerlines}/src/types/context.d.mts +1 -1
  19. package/dist/{powerlines → packages/powerlines}/src/types/tsconfig.d.mts +1 -1
  20. package/dist/powerlines/src/types/context.d.cts +1 -1
  21. package/dist/types/plugin.d.mts +1 -1
  22. package/package.json +5 -5
  23. package/dist/deepkit/schemas/reflection.cjs +0 -3998
  24. package/dist/deepkit/schemas/reflection.mjs +0 -3996
  25. package/dist/deepkit/schemas/reflection2.cjs +0 -4112
  26. package/dist/deepkit/schemas/reflection2.mjs +0 -4110
  27. package/dist/deepkit/src/capnp.cjs +0 -913
  28. package/dist/deepkit/src/capnp.mjs +0 -911
  29. package/dist/deepkit/src/esbuild-plugin.cjs +0 -47
  30. package/dist/deepkit/src/esbuild-plugin.mjs +0 -46
  31. package/dist/deepkit/src/reflect-type.cjs +0 -22
  32. package/dist/deepkit/src/reflect-type.mjs +0 -20
  33. package/dist/deepkit/src/resolve-reflections.cjs +0 -16
  34. package/dist/deepkit/src/resolve-reflections.mjs +0 -15
  35. package/dist/deepkit/src/transformer.cjs +0 -52
  36. package/dist/deepkit/src/transformer.mjs +0 -49
  37. package/dist/deepkit/src/transpile.cjs +0 -29
  38. package/dist/deepkit/src/transpile.mjs +0 -27
  39. package/dist/deepkit/src/utilities.cjs +0 -66
  40. package/dist/deepkit/src/utilities.mjs +0 -65
  41. package/dist/plugin-alloy/src/core/components/output.cjs +0 -38
  42. package/dist/plugin-alloy/src/core/components/output.mjs +0 -37
  43. package/dist/plugin-alloy/src/core/components/single-line-comment.cjs +0 -20
  44. package/dist/plugin-alloy/src/core/components/single-line-comment.mjs +0 -19
  45. package/dist/plugin-alloy/src/core/components/source-file.cjs +0 -60
  46. package/dist/plugin-alloy/src/core/components/source-file.mjs +0 -58
  47. package/dist/plugin-alloy/src/core/contexts/context.cjs +0 -60
  48. package/dist/plugin-alloy/src/core/contexts/context.mjs +0 -54
  49. package/dist/plugin-alloy/src/core/contexts/index.cjs +0 -2
  50. package/dist/plugin-alloy/src/core/contexts/index.mjs +0 -4
  51. package/dist/plugin-alloy/src/core/contexts/reflection.cjs +0 -46
  52. package/dist/plugin-alloy/src/core/contexts/reflection.mjs +0 -42
  53. package/dist/plugin-alloy/src/helpers/refkey.cjs +0 -16
  54. package/dist/plugin-alloy/src/helpers/refkey.mjs +0 -15
  55. package/dist/plugin-alloy/src/index.cjs +0 -103
  56. package/dist/plugin-alloy/src/index.mjs +0 -101
  57. package/dist/plugin-alloy/src/markdown/components/markdown-file.cjs +0 -7
  58. package/dist/plugin-alloy/src/markdown/components/markdown-file.mjs +0 -9
  59. package/dist/plugin-alloy/src/markdown/components/markdown-table.cjs +0 -5
  60. package/dist/plugin-alloy/src/markdown/components/markdown-table.mjs +0 -7
  61. package/dist/plugin-alloy/src/markdown/contexts/markdown-table.cjs +0 -17
  62. package/dist/plugin-alloy/src/markdown/contexts/markdown-table.mjs +0 -17
  63. package/dist/plugin-alloy/src/types/components.d.mts +0 -3
  64. package/dist/plugin-alloy/src/typescript/components/builtin-file.cjs +0 -47
  65. package/dist/plugin-alloy/src/typescript/components/builtin-file.mjs +0 -46
  66. package/dist/plugin-alloy/src/typescript/components/tsdoc-reflection.cjs +0 -75
  67. package/dist/plugin-alloy/src/typescript/components/tsdoc-reflection.mjs +0 -73
  68. package/dist/plugin-alloy/src/typescript/components/tsdoc.cjs +0 -359
  69. package/dist/plugin-alloy/src/typescript/components/tsdoc.mjs +0 -350
  70. package/dist/plugin-alloy/src/typescript/components/typescript-file.cjs +0 -153
  71. package/dist/plugin-alloy/src/typescript/components/typescript-file.mjs +0 -150
  72. package/dist/plugin-alloy/src/typescript/components/typescript-interface.cjs +0 -53
  73. package/dist/plugin-alloy/src/typescript/components/typescript-interface.mjs +0 -52
  74. package/dist/plugin-alloy/src/typescript/components/typescript-object.cjs +0 -94
  75. package/dist/plugin-alloy/src/typescript/components/typescript-object.mjs +0 -93
  76. package/dist/plugin-automd/src/index.cjs +0 -101
  77. package/dist/plugin-automd/src/index.mjs +0 -98
  78. package/dist/plugin-babel/src/helpers/ast-utils.cjs +0 -10
  79. package/dist/plugin-babel/src/helpers/ast-utils.mjs +0 -9
  80. package/dist/plugin-babel/src/helpers/create-plugin.cjs +0 -41
  81. package/dist/plugin-babel/src/helpers/create-plugin.mjs +0 -39
  82. package/dist/plugin-babel/src/helpers/filters.cjs +0 -23
  83. package/dist/plugin-babel/src/helpers/filters.mjs +0 -21
  84. package/dist/plugin-babel/src/helpers/index.cjs +0 -5
  85. package/dist/plugin-babel/src/helpers/index.mjs +0 -7
  86. package/dist/plugin-babel/src/helpers/module-helpers.cjs +0 -38
  87. package/dist/plugin-babel/src/helpers/module-helpers.mjs +0 -35
  88. package/dist/plugin-babel/src/helpers/options.cjs +0 -50
  89. package/dist/plugin-babel/src/helpers/options.mjs +0 -47
  90. package/dist/plugin-babel/src/index.cjs +0 -91
  91. package/dist/plugin-babel/src/index.mjs +0 -89
  92. package/dist/plugin-env/src/babel/index.cjs +0 -1
  93. package/dist/plugin-env/src/babel/index.mjs +0 -3
  94. package/dist/plugin-env/src/babel/plugin.cjs +0 -121
  95. package/dist/plugin-env/src/babel/plugin.mjs +0 -119
  96. package/dist/plugin-env/src/components/docs.cjs +0 -9
  97. package/dist/plugin-env/src/components/docs.mjs +0 -11
  98. package/dist/plugin-env/src/components/env.cjs +0 -487
  99. package/dist/plugin-env/src/components/env.mjs +0 -484
  100. package/dist/plugin-env/src/components/index.cjs +0 -2
  101. package/dist/plugin-env/src/components/index.mjs +0 -4
  102. package/dist/plugin-env/src/helpers/automd-generator.cjs +0 -22
  103. package/dist/plugin-env/src/helpers/automd-generator.mjs +0 -21
  104. package/dist/plugin-env/src/helpers/create-reflection-resource.cjs +0 -55
  105. package/dist/plugin-env/src/helpers/create-reflection-resource.mjs +0 -54
  106. package/dist/plugin-env/src/helpers/index.cjs +0 -6
  107. package/dist/plugin-env/src/helpers/index.mjs +0 -8
  108. package/dist/plugin-env/src/helpers/load.cjs +0 -83
  109. package/dist/plugin-env/src/helpers/load.mjs +0 -80
  110. package/dist/plugin-env/src/helpers/persistence.cjs +0 -201
  111. package/dist/plugin-env/src/helpers/persistence.mjs +0 -190
  112. package/dist/plugin-env/src/helpers/reflect.cjs +0 -125
  113. package/dist/plugin-env/src/helpers/reflect.mjs +0 -117
  114. package/dist/plugin-env/src/helpers/source-file-env.cjs +0 -24
  115. package/dist/plugin-env/src/helpers/source-file-env.mjs +0 -23
  116. package/dist/plugin-env/src/helpers/template-helpers.cjs +0 -2
  117. package/dist/plugin-env/src/helpers/template-helpers.mjs +0 -4
  118. package/dist/plugin-env/src/index.cjs +0 -172
  119. package/dist/plugin-env/src/index.mjs +0 -170
  120. package/dist/powerlines/src/lib/build/esbuild.cjs +0 -102
  121. package/dist/powerlines/src/lib/build/esbuild.mjs +0 -100
  122. package/dist/powerlines/src/lib/entry.cjs +0 -12
  123. package/dist/powerlines/src/lib/entry.mjs +0 -14
  124. package/dist/powerlines/src/lib/logger.cjs +0 -41
  125. package/dist/powerlines/src/lib/logger.mjs +0 -39
  126. package/dist/powerlines/src/lib/utilities/bundle.cjs +0 -35
  127. package/dist/powerlines/src/lib/utilities/bundle.mjs +0 -34
  128. package/dist/powerlines/src/lib/utilities/file-header.cjs +0 -22
  129. package/dist/powerlines/src/lib/utilities/file-header.mjs +0 -21
  130. package/dist/powerlines/src/lib/utilities/resolve.cjs +0 -30
  131. package/dist/powerlines/src/lib/utilities/resolve.mjs +0 -29
  132. package/dist/powerlines/src/plugin-utils/paths.cjs +0 -1
  133. package/dist/powerlines/src/plugin-utils/paths.mjs +0 -3
  134. /package/dist/{deepkit → packages/deepkit}/schemas/reflection.d.mts +0 -0
  135. /package/dist/{deepkit → packages/deepkit}/src/types.d.mts +0 -0
  136. /package/dist/{plugin-alloy → packages/plugin-alloy}/src/types/index.d.mts +0 -0
  137. /package/dist/{plugin-alloy → packages/plugin-alloy}/src/types/plugin.d.mts +0 -0
  138. /package/dist/{plugin-automd → packages/plugin-automd}/src/types/plugin.d.mts +0 -0
  139. /package/dist/{plugin-automd → packages/plugin-automd}/src/types/toc.d.mts +0 -0
  140. /package/dist/{plugin-babel → packages/plugin-babel}/src/types/index.d.mts +0 -0
  141. /package/dist/{plugin-babel → packages/plugin-babel}/src/types/plugin.d.mts +0 -0
  142. /package/dist/{plugin-env → packages/plugin-env}/src/types/runtime.d.mts +0 -0
  143. /package/dist/{powerlines → packages/powerlines}/src/internal/helpers/hooks.d.mts +0 -0
  144. /package/dist/{powerlines → packages/powerlines}/src/types/api.d.mts +0 -0
  145. /package/dist/{powerlines → packages/powerlines}/src/types/babel.d.mts +0 -0
  146. /package/dist/{powerlines → packages/powerlines}/src/types/commands.d.mts +0 -0
  147. /package/dist/{powerlines → packages/powerlines}/src/types/fs.d.mts +0 -0
  148. /package/dist/{powerlines → packages/powerlines}/src/types/hooks.d.mts +0 -0
  149. /package/dist/{powerlines → packages/powerlines}/src/types/plugin.d.mts +0 -0
  150. /package/dist/{powerlines → packages/powerlines}/src/types/resolved.d.mts +0 -0
  151. /package/dist/{powerlines → packages/powerlines}/src/types/unplugin.d.mts +0 -0
@@ -1,4 +1,5 @@
1
- const require_file_header = require('../powerlines/src/lib/utilities/file-header.cjs');
1
+ const require_rolldown_runtime = require('../_virtual/rolldown_runtime.cjs');
2
+ let powerlines_lib_utilities_file_header = require("powerlines/lib/utilities/file-header");
2
3
 
3
4
  //#region src/components/date-fns.ts
4
5
  /**
@@ -15,7 +16,7 @@ function dateFnsModule(context) {
15
16
  * @module ${context.config.output.builtinPrefix}:date
16
17
  */
17
18
 
18
- ${require_file_header.getFileHeader(context)}
19
+ ${(0, powerlines_lib_utilities_file_header.getFileHeader)(context)}
19
20
 
20
21
  import { DateFormats, TimeUnit } from "@powerlines/plugin-date/types/runtime";
21
22
  import { addDays as dateFnsAddDays } from "date-fns/addDays";
@@ -1,4 +1,4 @@
1
- import { getFileHeader } from "../powerlines/src/lib/utilities/file-header.mjs";
1
+ import { getFileHeader } from "powerlines/lib/utilities/file-header";
2
2
 
3
3
  //#region src/components/date-fns.ts
4
4
  /**
@@ -1,4 +1,5 @@
1
- const require_file_header = require('../powerlines/src/lib/utilities/file-header.cjs');
1
+ const require_rolldown_runtime = require('../_virtual/rolldown_runtime.cjs');
2
+ let powerlines_lib_utilities_file_header = require("powerlines/lib/utilities/file-header");
2
3
 
3
4
  //#region src/components/dayjs.ts
4
5
  /**
@@ -15,7 +16,7 @@ function dayjsModule(context) {
15
16
  * @module ${context.config.output.builtinPrefix}:date
16
17
  */
17
18
 
18
- ${require_file_header.getFileHeader(context)}
19
+ ${(0, powerlines_lib_utilities_file_header.getFileHeader)(context)}
19
20
 
20
21
  import defaultDayjs, { QUnitType } from "dayjs";
21
22
  import customParseFormatPlugin from "dayjs/plugin/customParseFormat";
@@ -1,4 +1,4 @@
1
- import { getFileHeader } from "../powerlines/src/lib/utilities/file-header.mjs";
1
+ import { getFileHeader } from "powerlines/lib/utilities/file-header";
2
2
 
3
3
  //#region src/components/dayjs.ts
4
4
  /**
@@ -1,4 +1,5 @@
1
- const require_file_header = require('../powerlines/src/lib/utilities/file-header.cjs');
1
+ const require_rolldown_runtime = require('../_virtual/rolldown_runtime.cjs');
2
+ let powerlines_lib_utilities_file_header = require("powerlines/lib/utilities/file-header");
2
3
 
3
4
  //#region src/components/luxon.ts
4
5
  /**
@@ -15,7 +16,7 @@ function luxonModule(context) {
15
16
  * @module ${context.config.output.builtinPrefix}:date
16
17
  */
17
18
 
18
- ${require_file_header.getFileHeader(context)}
19
+ ${(0, powerlines_lib_utilities_file_header.getFileHeader)(context)}
19
20
 
20
21
  import { DateTime, Settings, Info } from "luxon";
21
22
  import {
@@ -1,4 +1,4 @@
1
- import { getFileHeader } from "../powerlines/src/lib/utilities/file-header.mjs";
1
+ import { getFileHeader } from "powerlines/lib/utilities/file-header";
2
2
 
3
3
  //#region src/components/luxon.ts
4
4
  /**
@@ -1,4 +1,5 @@
1
- const require_file_header = require('../powerlines/src/lib/utilities/file-header.cjs');
1
+ const require_rolldown_runtime = require('../_virtual/rolldown_runtime.cjs');
2
+ let powerlines_lib_utilities_file_header = require("powerlines/lib/utilities/file-header");
2
3
 
3
4
  //#region src/components/moment.ts
4
5
  /**
@@ -15,7 +16,7 @@ function momentModule(context) {
15
16
  * @module ${context.config.output.builtinPrefix}:date
16
17
  */
17
18
 
18
- ${require_file_header.getFileHeader(context)}
19
+ ${(0, powerlines_lib_utilities_file_header.getFileHeader)(context)}
19
20
 
20
21
  import defaultMoment, { LongDateFormatKey } from "moment";
21
22
  import {
@@ -1,4 +1,4 @@
1
- import { getFileHeader } from "../powerlines/src/lib/utilities/file-header.mjs";
1
+ import { getFileHeader } from "powerlines/lib/utilities/file-header";
2
2
 
3
3
  //#region src/components/moment.ts
4
4
  /**
package/dist/index.cjs CHANGED
@@ -1,13 +1,13 @@
1
1
  Object.defineProperty(exports, '__esModule', { value: true });
2
2
  const require_rolldown_runtime = require('./_virtual/rolldown_runtime.cjs');
3
- const require_index = require('./plugin-env/src/index.cjs');
3
+ const require_defu = require('./node_modules/.pnpm/defu@6.1.4/node_modules/defu/dist/defu.cjs');
4
4
  const require_date_fns = require('./components/date-fns.cjs');
5
5
  const require_dayjs = require('./components/dayjs.cjs');
6
6
  const require_luxon = require('./components/luxon.cjs');
7
7
  const require_moment = require('./components/moment.cjs');
8
8
  require('./components/index.cjs');
9
- let defu = require("defu");
10
- defu = require_rolldown_runtime.__toESM(defu);
9
+ let __powerlines_plugin_env = require("@powerlines/plugin-env");
10
+ __powerlines_plugin_env = require_rolldown_runtime.__toESM(__powerlines_plugin_env);
11
11
  let __storm_software_config_tools_types = require("@storm-software/config-tools/types");
12
12
 
13
13
  //#region src/index.ts
@@ -15,11 +15,11 @@ let __storm_software_config_tools_types = require("@storm-software/config-tools/
15
15
  * A Powerlines plugin to assist in developing other Powerlines plugins.
16
16
  */
17
17
  function plugin(options = {}) {
18
- return [require_index.default(options.env), {
18
+ return [(0, __powerlines_plugin_env.default)(options.env), {
19
19
  name: "date",
20
20
  async config() {
21
21
  this.log(__storm_software_config_tools_types.LogLevelLabel.TRACE, "Providing default configuration for the Powerlines `date` build plugin.");
22
- const config = { date: (0, defu.default)(options, { type: "date-fns" }) };
22
+ const config = { date: require_defu.defu(options, { type: "date-fns" }) };
23
23
  if (!config.date.type || ![
24
24
  "date-fns",
25
25
  "dayjs",
package/dist/index.d.mts CHANGED
@@ -1,4 +1,4 @@
1
- import { Plugin } from "./powerlines/src/types/plugin.mjs";
1
+ import { Plugin } from "./packages/powerlines/src/types/plugin.mjs";
2
2
  import { DateLibraryType, DatePluginContext, DatePluginOptions, DatePluginResolvedConfig, DatePluginUserConfig, __ΩDateLibraryType, __ΩDatePluginContext, __ΩDatePluginOptions, __ΩDatePluginResolvedConfig, __ΩDatePluginUserConfig } from "./types/plugin.mjs";
3
3
  import { dateFnsModule } from "./components/date-fns.mjs";
4
4
  import { dayjsModule } from "./components/dayjs.mjs";
package/dist/index.mjs CHANGED
@@ -1,10 +1,10 @@
1
- import src_default$1 from "./plugin-env/src/index.mjs";
1
+ import { defu } from "./node_modules/.pnpm/defu@6.1.4/node_modules/defu/dist/defu.mjs";
2
2
  import { dateFnsModule } from "./components/date-fns.mjs";
3
3
  import { dayjsModule } from "./components/dayjs.mjs";
4
4
  import { luxonModule } from "./components/luxon.mjs";
5
5
  import { momentModule } from "./components/moment.mjs";
6
6
  import "./components/index.mjs";
7
- import defu from "defu";
7
+ import env from "@powerlines/plugin-env";
8
8
  import { LogLevelLabel } from "@storm-software/config-tools/types";
9
9
 
10
10
  //#region src/index.ts
@@ -12,7 +12,7 @@ import { LogLevelLabel } from "@storm-software/config-tools/types";
12
12
  * A Powerlines plugin to assist in developing other Powerlines plugins.
13
13
  */
14
14
  function plugin(options = {}) {
15
- return [src_default$1(options.env), {
15
+ return [env(options.env), {
16
16
  name: "date",
17
17
  async config() {
18
18
  this.log(LogLevelLabel.TRACE, "Providing default configuration for the Powerlines `date` build plugin.");
@@ -0,0 +1,43 @@
1
+
2
+ //#region ../../node_modules/.pnpm/defu@6.1.4/node_modules/defu/dist/defu.mjs
3
+ function isPlainObject(value) {
4
+ if (value === null || typeof value !== "object") return false;
5
+ const prototype = Object.getPrototypeOf(value);
6
+ if (prototype !== null && prototype !== Object.prototype && Object.getPrototypeOf(prototype) !== null) return false;
7
+ if (Symbol.iterator in value) return false;
8
+ if (Symbol.toStringTag in value) return Object.prototype.toString.call(value) === "[object Module]";
9
+ return true;
10
+ }
11
+ function _defu(baseObject, defaults, namespace = ".", merger) {
12
+ if (!isPlainObject(defaults)) return _defu(baseObject, {}, namespace, merger);
13
+ const object = Object.assign({}, defaults);
14
+ for (const key in baseObject) {
15
+ if (key === "__proto__" || key === "constructor") continue;
16
+ const value = baseObject[key];
17
+ if (value === null || value === void 0) continue;
18
+ if (merger && merger(object, key, value, namespace)) continue;
19
+ if (Array.isArray(value) && Array.isArray(object[key])) object[key] = [...value, ...object[key]];
20
+ else if (isPlainObject(value) && isPlainObject(object[key])) object[key] = _defu(value, object[key], (namespace ? `${namespace}.` : "") + key.toString(), merger);
21
+ else object[key] = value;
22
+ }
23
+ return object;
24
+ }
25
+ function createDefu(merger) {
26
+ return (...arguments_) => arguments_.reduce((p, c) => _defu(p, c, "", merger), {});
27
+ }
28
+ const defu = createDefu();
29
+ const defuFn = createDefu((object, key, currentValue) => {
30
+ if (object[key] !== void 0 && typeof currentValue === "function") {
31
+ object[key] = currentValue(object[key]);
32
+ return true;
33
+ }
34
+ });
35
+ const defuArrayFn = createDefu((object, key, currentValue) => {
36
+ if (Array.isArray(object[key]) && typeof currentValue === "function") {
37
+ object[key] = currentValue(object[key]);
38
+ return true;
39
+ }
40
+ });
41
+
42
+ //#endregion
43
+ exports.defu = defu;
@@ -0,0 +1,42 @@
1
+ //#region ../../node_modules/.pnpm/defu@6.1.4/node_modules/defu/dist/defu.mjs
2
+ function isPlainObject(value) {
3
+ if (value === null || typeof value !== "object") return false;
4
+ const prototype = Object.getPrototypeOf(value);
5
+ if (prototype !== null && prototype !== Object.prototype && Object.getPrototypeOf(prototype) !== null) return false;
6
+ if (Symbol.iterator in value) return false;
7
+ if (Symbol.toStringTag in value) return Object.prototype.toString.call(value) === "[object Module]";
8
+ return true;
9
+ }
10
+ function _defu(baseObject, defaults, namespace = ".", merger) {
11
+ if (!isPlainObject(defaults)) return _defu(baseObject, {}, namespace, merger);
12
+ const object = Object.assign({}, defaults);
13
+ for (const key in baseObject) {
14
+ if (key === "__proto__" || key === "constructor") continue;
15
+ const value = baseObject[key];
16
+ if (value === null || value === void 0) continue;
17
+ if (merger && merger(object, key, value, namespace)) continue;
18
+ if (Array.isArray(value) && Array.isArray(object[key])) object[key] = [...value, ...object[key]];
19
+ else if (isPlainObject(value) && isPlainObject(object[key])) object[key] = _defu(value, object[key], (namespace ? `${namespace}.` : "") + key.toString(), merger);
20
+ else object[key] = value;
21
+ }
22
+ return object;
23
+ }
24
+ function createDefu(merger) {
25
+ return (...arguments_) => arguments_.reduce((p, c) => _defu(p, c, "", merger), {});
26
+ }
27
+ const defu = createDefu();
28
+ const defuFn = createDefu((object, key, currentValue) => {
29
+ if (object[key] !== void 0 && typeof currentValue === "function") {
30
+ object[key] = currentValue(object[key]);
31
+ return true;
32
+ }
33
+ });
34
+ const defuArrayFn = createDefu((object, key, currentValue) => {
35
+ if (Array.isArray(object[key]) && typeof currentValue === "function") {
36
+ object[key] = currentValue(object[key]);
37
+ return true;
38
+ }
39
+ });
40
+
41
+ //#endregion
42
+ export { defu };
@@ -0,0 +1,2 @@
1
+ import "../../../powerlines/src/types/resolved.mjs";
2
+ import { Children } from "@alloy-js/core";
@@ -5,9 +5,9 @@ import { AutoMDPluginOptions } from "../../../plugin-automd/src/types/plugin.mjs
5
5
  import { BabelPluginContext, BabelPluginOptions, BabelPluginResolvedConfig, BabelPluginUserConfig } from "../../../plugin-babel/src/types/plugin.mjs";
6
6
  import "../../../plugin-babel/src/types/index.mjs";
7
7
  import { EnvInterface, SecretsInterface } from "./runtime.mjs";
8
- import { DotenvParseOutput } from "@stryke/env/types";
9
8
  import { DotenvConfiguration, TypeDefinition, TypeDefinitionParameter } from "@stryke/types/configuration";
10
9
  import { Children } from "@alloy-js/core/jsx-runtime";
10
+ import { DotenvParseOutput } from "@stryke/env/types";
11
11
 
12
12
  //#region ../plugin-env/src/types/plugin.d.ts
13
13
  type EnvPluginOptions = Omit<DotenvConfiguration, "types"> & {
@@ -1,9 +1,9 @@
1
- import { BuildOptions } from "esbuild";
2
1
  import { OutputOptions, RollupOptions } from "rollup";
3
2
  import { UserConfig } from "@farmfe/core";
4
3
  import { Configuration } from "@rspack/core";
5
- import { BuildOptions as BuildOptions$1 } from "@storm-software/tsup/types";
4
+ import { BuildOptions } from "@storm-software/tsup/types";
6
5
  import { UnbuildOptions } from "@storm-software/unbuild/types";
6
+ import { BuildOptions as BuildOptions$1 } from "esbuild";
7
7
  import { RolldownOptions } from "rolldown";
8
8
  import { UserConfig as UserConfig$1 } from "tsdown";
9
9
  import { DepOptimizationOptions, UserConfig as UserConfig$2 } from "vite";
@@ -153,8 +153,8 @@ interface BuildConfig {
153
153
  override?: Record<string, any>;
154
154
  }
155
155
  type BuildResolvedConfig = Omit<BuildConfig, "override">;
156
- type ESBuildBuildConfig = Omit<BuildOptions, "entryPoints" | "sourceRoot" | "platform" | "outdir" | "env" | "assets" | "external" | "inject" | "tsconfig" | "tsconfigRaw" | "logLevel"> & BuildConfig;
157
- type ESBuildResolvedBuildConfig = Omit<BuildOptions, "inject"> & BuildResolvedConfig;
156
+ type ESBuildBuildConfig = Omit<BuildOptions$1, "entryPoints" | "sourceRoot" | "platform" | "outdir" | "env" | "assets" | "external" | "inject" | "tsconfig" | "tsconfigRaw" | "logLevel"> & BuildConfig;
157
+ type ESBuildResolvedBuildConfig = Omit<BuildOptions$1, "inject"> & BuildResolvedConfig;
158
158
  type ViteBuildConfig = Omit<UserConfig$2, "entry" | "entryPoints" | "tsconfig" | "tsconfigRaw" | "environments" | "output"> & BuildConfig & {
159
159
  /**
160
160
  * Optimize deps config
@@ -173,8 +173,8 @@ type RollupBuildConfig = Omit<RollupOptions, "entry" | "external" | "input" | "o
173
173
  type RollupResolvedBuildConfig = RollupOptions & BuildResolvedConfig;
174
174
  type RolldownBuildConfig = Omit<RolldownOptions, "input" | "external" | "tsconfig" | "logLevel" | "output"> & BuildConfig;
175
175
  type RolldownResolvedBuildConfig = RolldownOptions & BuildResolvedConfig;
176
- type TsupBuildConfig = Partial<Omit<BuildOptions$1, "userOptions" | "tsconfig" | "tsconfigRaw" | "assets" | "outputPath" | "mode" | "format" | "platform" | "projectRoot" | "clean" | "env" | "entry" | "entryPoints" | "external" | "noExternal" | "skipNodeModulesBundle">> & BuildConfig;
177
- type TsupResolvedBuildConfig = BuildOptions$1 & BuildResolvedConfig;
176
+ type TsupBuildConfig = Partial<Omit<BuildOptions, "userOptions" | "tsconfig" | "tsconfigRaw" | "assets" | "outputPath" | "mode" | "format" | "platform" | "projectRoot" | "clean" | "env" | "entry" | "entryPoints" | "external" | "noExternal" | "skipNodeModulesBundle">> & BuildConfig;
177
+ type TsupResolvedBuildConfig = BuildOptions & BuildResolvedConfig;
178
178
  type TsdownBuildConfig = Partial<Omit<UserConfig$1, "name" | "outDir" | "clean" | "cwd" | "tsconfig" | "publicDir" | "copy" | "alias" | "format" | "platform" | "env" | "define" | "entry" | "external" | "noExternal" | "skipNodeModulesBundle">> & BuildConfig;
179
179
  type TsdownResolvedBuildConfig = UserConfig$1 & BuildResolvedConfig;
180
180
  type UnbuildBuildConfig = Partial<Omit<UnbuildOptions, "tsconfig" | "tsconfigRaw" | "assets" | "outputPath" | "mode" | "format" | "platform" | "projectRoot" | "env" | "entry" | "entryPoints">> & BuildConfig;
@@ -4,11 +4,10 @@ import { StoragePort, StoragePreset } from "./fs.mjs";
4
4
  import { TSConfig } from "./tsconfig.mjs";
5
5
  import { PluginContext } from "./context.mjs";
6
6
  import { Plugin } from "./plugin.mjs";
7
- import "c12";
8
- import { transformAsync } from "@babel/core";
9
7
  import { LogLevelLabel } from "@storm-software/config-tools/types";
10
8
  import { MaybePromise } from "@stryke/types/base";
11
9
  import { PreviewOptions } from "vite";
10
+ import { transformAsync } from "@babel/core";
12
11
  import { Format } from "@storm-software/build-tools/types";
13
12
  import { StormWorkspaceConfig } from "@storm-software/config/types";
14
13
  import { TypeDefinitionParameter } from "@stryke/types/configuration";
@@ -19,7 +19,7 @@ import { RequestInfo, Response } from "undici";
19
19
  //#region ../powerlines/src/types/context.d.ts
20
20
 
21
21
  /**
22
- * The severity level of a {@link LogRecord}.
22
+ * The severity level of a log message.
23
23
  */
24
24
  type LogLevel = "debug" | "info" | "warning" | "error" | "fatal";
25
25
  declare const LogLevel: {
@@ -1,5 +1,5 @@
1
- import ts from "typescript";
2
1
  import { CompilerOptions, TsConfigJson } from "@stryke/types/tsconfig";
2
+ import ts from "typescript";
3
3
 
4
4
  //#region ../powerlines/src/types/tsconfig.d.ts
5
5
  type ReflectionMode = "default" | "explicit" | "never";
@@ -19,7 +19,7 @@ import { RequestInfo, Response } from "undici";
19
19
  //#region ../powerlines/src/types/context.d.ts
20
20
 
21
21
  /**
22
- * The severity level of a {@link LogRecord}.
22
+ * The severity level of a log message.
23
23
  */
24
24
  type LogLevel = "debug" | "info" | "warning" | "error" | "fatal";
25
25
  declare const LogLevel: {
@@ -1,4 +1,4 @@
1
- import { EnvPluginContext, EnvPluginOptions, EnvPluginResolvedConfig, EnvPluginUserConfig } from "../plugin-env/src/types/plugin.mjs";
1
+ import { EnvPluginContext, EnvPluginOptions, EnvPluginResolvedConfig, EnvPluginUserConfig } from "../packages/plugin-env/src/types/plugin.mjs";
2
2
 
3
3
  //#region src/types/plugin.d.ts
4
4
  type DateLibraryType = "date-fns" | "dayjs" | "luxon" | "moment";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@powerlines/plugin-date",
3
- "version": "0.12.151",
3
+ "version": "0.12.153",
4
4
  "type": "module",
5
5
  "description": "A package containing a Powerlines plugin for injecting static .env configuration values to the code so that they're accessible at runtime.",
6
6
  "repository": {
@@ -128,15 +128,15 @@
128
128
  "files": ["dist/**/*"],
129
129
  "keywords": ["powerlines", "storm-software", "powerlines-plugin"],
130
130
  "dependencies": {
131
- "@powerlines/plugin-env": "^0.15.13",
131
+ "@powerlines/plugin-env": "^0.15.15",
132
132
  "@storm-software/config-tools": "^1.188.75",
133
133
  "@stryke/path": "^0.24.1",
134
- "powerlines": "^0.37.2"
134
+ "powerlines": "^0.37.4"
135
135
  },
136
136
  "devDependencies": {
137
- "@powerlines/nx": "^0.11.58",
137
+ "@powerlines/plugin-plugin": "^0.12.82",
138
138
  "@types/node": "^24.10.4"
139
139
  },
140
140
  "publishConfig": { "access": "public" },
141
- "gitHead": "5a9bfc9333eca98a453682f39a04a0d642930a50"
141
+ "gitHead": "48a35579bd5535a267a420c160c273899920b2e7"
142
142
  }