@powerlines/plugin-crypto 0.10.103 → 0.10.104

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.
@@ -116,6 +116,7 @@ function TypescriptFileHeader(props) {
116
116
  */
117
117
  function TypescriptFileHeaderImports(props) {
118
118
  const { imports } = props;
119
+ const context = require_context.usePowerlines();
119
120
  const sourceFile = (0, __alloy_js_typescript.useSourceFile)();
120
121
  const scope = props.scope ?? sourceFile.scope;
121
122
  return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(__alloy_js_core.Show, {
@@ -123,7 +124,7 @@ function TypescriptFileHeaderImports(props) {
123
124
  children: [
124
125
  /* @__PURE__ */ (0, react_jsx_runtime.jsx)(__alloy_js_core.Show, {
125
126
  when: !!imports && Object.keys(imports).length > 0,
126
- children: Object.entries(imports ?? {}).map(([module$1, imported]) => {
127
+ children: Object.entries(imports ?? {}).filter(([key]) => key !== "$builtins").concat(imports && imports.$builtins ? Object.entries(imports.$builtins).map(([key, entry]) => [key.includes(":") ? key : `${context.config.output.builtinPrefix}:${key}`, entry]) : []).map(([module$1, imported]) => {
127
128
  return __alloy_js_core.code`import ${imported === null ? "" : imported.filter((i) => !(0, __stryke_type_checks_is_string.isString)(i) && i.default).map((i) => i.alias ? i.alias : i.name).join(", ") + (imported.filter((i) => !(0, __stryke_type_checks_is_string.isString)(i) && i.default).length > 0 && imported.filter((i) => (0, __stryke_type_checks_is_string.isString)(i) || !i.default).length > 0 ? ", " : "") + (imported.filter((i) => (0, __stryke_type_checks_is_string.isString)(i) || !i.default).length > 0 ? `{ ${imported.map((i) => (0, __stryke_type_checks_is_string.isString)(i) ? i : i.alias ? `${i.name} as ${i.alias}` : i.name).join(", ")} }` : "")} from "${module$1}";`;
128
129
  })
129
130
  }),
@@ -115,6 +115,7 @@ function TypescriptFileHeader(props) {
115
115
  */
116
116
  function TypescriptFileHeaderImports(props) {
117
117
  const { imports } = props;
118
+ const context = usePowerlines();
118
119
  const sourceFile = useSourceFile();
119
120
  const scope = props.scope ?? sourceFile.scope;
120
121
  return /* @__PURE__ */ jsxs(Show, {
@@ -122,7 +123,7 @@ function TypescriptFileHeaderImports(props) {
122
123
  children: [
123
124
  /* @__PURE__ */ jsx(Show, {
124
125
  when: !!imports && Object.keys(imports).length > 0,
125
- children: Object.entries(imports ?? {}).map(([module, imported]) => {
126
+ children: Object.entries(imports ?? {}).filter(([key]) => key !== "$builtins").concat(imports && imports.$builtins ? Object.entries(imports.$builtins).map(([key, entry]) => [key.includes(":") ? key : `${context.config.output.builtinPrefix}:${key}`, entry]) : []).map(([module, imported]) => {
126
127
  return code`import ${imported === null ? "" : imported.filter((i) => !isString(i) && i.default).map((i) => i.alias ? i.alias : i.name).join(", ") + (imported.filter((i) => !isString(i) && i.default).length > 0 && imported.filter((i) => isString(i) || !i.default).length > 0 ? ", " : "") + (imported.filter((i) => isString(i) || !i.default).length > 0 ? `{ ${imported.map((i) => isString(i) ? i : i.alias ? `${i.name} as ${i.alias}` : i.name).join(", ")} }` : "")} from "${module}";`;
127
128
  })
128
129
  }),
@@ -1,3 +1,5 @@
1
+ import "esbuild";
2
+
1
3
  //#region ../powerlines/src/types/build.d.ts
2
4
 
3
5
  type UnpluginBuildVariant = "rollup" | "webpack" | "rspack" | "vite" | "esbuild" | "farm" | "unloader" | "rolldown";
@@ -1,3 +1,4 @@
1
+ import "./build.mjs";
1
2
  import { BabelUserConfig, EnvironmentConfig, InlineConfig, OutputConfig, UserConfig } from "./config.mjs";
2
3
  import { NonUndefined } from "@stryke/types/base";
3
4
  import { ResolvedPreviewOptions } from "vite";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@powerlines/plugin-crypto",
3
- "version": "0.10.103",
3
+ "version": "0.10.104",
4
4
  "type": "module",
5
5
  "description": "A Powerlines plugin that provides unique identifier generation capabilities at runtime by adding the `id` builtin module.",
6
6
  "repository": {
@@ -128,7 +128,7 @@
128
128
  "files": ["dist/**/*"],
129
129
  "keywords": ["powerlines", "storm-software", "powerlines-plugin"],
130
130
  "dependencies": {
131
- "@powerlines/plugin-env": "^0.15.0",
131
+ "@powerlines/plugin-env": "^0.15.1",
132
132
  "@storm-software/config-tools": "^1.188.75",
133
133
  "@stryke/path": "^0.24.1",
134
134
  "defu": "^6.1.4",
@@ -140,5 +140,5 @@
140
140
  "@types/node": "^24.10.4"
141
141
  },
142
142
  "publishConfig": { "access": "public" },
143
- "gitHead": "41988f81e266a609148fcac22a535e5f12bbeb5f"
143
+ "gitHead": "b9a0574767447bffa6549e0492812dfe64e879e3"
144
144
  }