@creopse/bridge 0.1.15 → 0.1.17

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.
@@ -1,19 +1,18 @@
1
1
  import { D, S as L, s as M } from "../index-C8b1StIO.js";
2
2
  import x from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/@originjs+vite-plugin-federation@1.4.1/node_modules/@originjs/vite-plugin-federation/dist/index.mjs";
3
3
  import O from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/@vitejs+plugin-basic-ssl@2.3.0_vite@7.0.5_@types+node@24.0.15_jiti@2.6.1_tsx@4.21.0_/node_modules/@vitejs/plugin-basic-ssl/dist/index.mjs";
4
- import R from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/@vitejs+plugin-react@4.6.0_vite@7.0.5_@types+node@24.0.15_jiti@2.6.1_tsx@4.21.0_/node_modules/@vitejs/plugin-react/dist/index.mjs";
5
- import { parse as j, stringify as k } from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/comment-json@4.6.2/node_modules/comment-json/src/index.js";
4
+ import { parse as R, stringify as j } from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/comment-json@4.6.2/node_modules/comment-json/src/index.js";
6
5
  import v from "fs";
7
6
  import a from "path";
8
- import N from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/rollup-plugin-copy@3.5.0/node_modules/rollup-plugin-copy/dist/index.module.js";
9
- import $ from "vite-plugin-auto-import-lite";
10
- import B from "vite-plugin-i18next-loader";
11
- import z from "vite-plugin-json5";
12
- import T from "vite-plugin-top-level-await";
13
- function Z(A = {}) {
7
+ import k from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/rollup-plugin-copy@3.5.0/node_modules/rollup-plugin-copy/dist/index.module.js";
8
+ import N from "vite-plugin-auto-import-lite";
9
+ import $ from "vite-plugin-i18next-loader";
10
+ import B from "vite-plugin-json5";
11
+ import z from "vite-plugin-top-level-await";
12
+ function X(A = {}) {
14
13
  const {
15
14
  manifestPath: w = "./manifest.jsonc",
16
- srcDir: d = "./src",
15
+ srcDir: f = "./src",
17
16
  outDir: u = "frontend",
18
17
  i18nLocalesPath: g,
19
18
  hooksDirs: _ = ["src/hooks"],
@@ -26,15 +25,15 @@ function Z(A = {}) {
26
25
  try {
27
26
  if (v.existsSync(t)) {
28
27
  const r = v.readFileSync(t, "utf-8");
29
- if (e = j(r || "{}"), e.pages && Array.isArray(e.pages))
28
+ if (e = R(r || "{}"), e.pages && Array.isArray(e.pages))
30
29
  for (const h of e.pages)
31
30
  n[`./${h.name}`] = h.module;
32
31
  const o = e.dashboard;
33
32
  o?.module && (n[`./${D}`] = o.module);
34
33
  const P = e.settings;
35
34
  P?.module && (n[`./${L}`] = P.module);
36
- const f = e.development;
37
- i = M(String(e.id)) || i, l = e.entry || l, c = f?.previewPort || c, p = f?.serverPort || p, m = f?.ssl || m;
35
+ const d = e.development;
36
+ i = M(String(e.id)) || i, l = e.entry || l, c = d?.previewPort || c, p = d?.serverPort || p, m = d?.ssl || m;
38
37
  } else
39
38
  console.warn(
40
39
  `[CreopseReactPlugin] Warning: Manifest not found at ${t}`
@@ -45,7 +44,7 @@ function Z(A = {}) {
45
44
  r
46
45
  );
47
46
  }
48
- const I = g ? a.resolve(s, g) : a.resolve(s, d, "i18n/locales"), C = ["react", "react-dom", "zustand", ...y], b = {
47
+ const I = g ? a.resolve(s, g) : a.resolve(s, f, "i18n/locales"), C = ["react", "react-dom", "zustand", ...y], b = {
49
48
  name: "creopse-react-plugin",
50
49
  config() {
51
50
  return {
@@ -54,7 +53,7 @@ function Z(A = {}) {
54
53
  alias: [
55
54
  {
56
55
  find: "@",
57
- replacement: a.resolve(s, d)
56
+ replacement: a.resolve(s, f)
58
57
  }
59
58
  ],
60
59
  dedupe: ["react", "react-dom", "zustand"]
@@ -66,7 +65,7 @@ function Z(A = {}) {
66
65
  cssCodeSplit: !1,
67
66
  rollupOptions: {
68
67
  plugins: [
69
- N({
68
+ k({
70
69
  targets: [
71
70
  {
72
71
  src: t,
@@ -75,7 +74,7 @@ function Z(A = {}) {
75
74
  return e?.mode && (e.mode = S ? "development" : "production"), ((o) => o.replace(/(,)\s*\n/g, `,
76
75
 
77
76
  `))(
78
- k(e, null, 2)
77
+ j(e, null, 2)
79
78
  );
80
79
  }
81
80
  }
@@ -114,23 +113,22 @@ function Z(A = {}) {
114
113
  }
115
114
  };
116
115
  return [
117
- z(),
118
- R(),
116
+ B(),
119
117
  x({
120
118
  name: i,
121
119
  filename: l,
122
120
  exposes: n,
123
121
  shared: C
124
122
  }),
125
- T({
123
+ z({
126
124
  promiseExportName: "__tla",
127
125
  promiseImportName: (r) => `__tla_${r}`
128
126
  }),
129
- B({
127
+ $({
130
128
  paths: [I],
131
129
  include: ["**/*.json"]
132
130
  }),
133
- $({
131
+ N({
134
132
  dirs: _,
135
133
  imports: ["react"],
136
134
  vueTemplate: !1,
@@ -147,5 +145,5 @@ function Z(A = {}) {
147
145
  ];
148
146
  }
149
147
  export {
150
- Z as CreopseReactPlugin
148
+ X as CreopseReactPlugin
151
149
  };
package/dist/vite/vue.js CHANGED
@@ -1,16 +1,15 @@
1
- import { D as C, S as I, s as L } from "../index-C8b1StIO.js";
2
- import b from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/@originjs+vite-plugin-federation@1.4.1/node_modules/@originjs/vite-plugin-federation/dist/index.mjs";
1
+ import { D as C, S as I, s as b } from "../index-C8b1StIO.js";
2
+ import L from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/@originjs+vite-plugin-federation@1.4.1/node_modules/@originjs/vite-plugin-federation/dist/index.mjs";
3
3
  import x from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/@vitejs+plugin-basic-ssl@2.3.0_vite@7.0.5_@types+node@24.0.15_jiti@2.6.1_tsx@4.21.0_/node_modules/@vitejs/plugin-basic-ssl/dist/index.mjs";
4
- import M from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/@vitejs+plugin-vue@6.0.5_vite@7.0.5_@types+node@24.0.15_jiti@2.6.1_tsx@4.21.0__vue@3.5.32_typescript@5.8.3_/node_modules/@vitejs/plugin-vue/dist/index.mjs";
5
- import { parse as O, stringify as V } from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/comment-json@4.6.2/node_modules/comment-json/src/index.js";
4
+ import { parse as M, stringify as O } from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/comment-json@4.6.2/node_modules/comment-json/src/index.js";
6
5
  import P from "fs";
7
- import n from "path";
8
- import N from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/rollup-plugin-copy@3.5.0/node_modules/rollup-plugin-copy/dist/index.module.js";
9
- import $ from "vite-plugin-auto-import-lite";
10
- import j from "vite-plugin-i18next-loader";
11
- import B from "vite-plugin-json5";
12
- import k from "vite-plugin-top-level-await";
13
- function X(h = {}) {
6
+ import i from "path";
7
+ import V from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/rollup-plugin-copy@3.5.0/node_modules/rollup-plugin-copy/dist/index.module.js";
8
+ import N from "vite-plugin-auto-import-lite";
9
+ import $ from "vite-plugin-i18next-loader";
10
+ import j from "vite-plugin-json5";
11
+ import B from "vite-plugin-top-level-await";
12
+ function K(h = {}) {
14
13
  const {
15
14
  manifestPath: A = "./manifest.jsonc",
16
15
  srcDir: g = "./src",
@@ -18,22 +17,22 @@ function X(h = {}) {
18
17
  i18nLocalesPath: v,
19
18
  composablesDirs: _ = ["src/composables"],
20
19
  shared: y = []
21
- } = h, i = process.cwd(), t = n.resolve(i, A), E = process.env.APP_IS_PREVIEW === "true";
20
+ } = h, a = process.cwd(), t = i.resolve(a, A), E = process.env.APP_IS_PREVIEW === "true";
22
21
  let e;
23
- const a = {};
22
+ const s = {};
24
23
  let c = "creopse-plugin", m = "remoteEntry.js", u = 2160, f = 2161, d = !1;
25
24
  try {
26
25
  if (P.existsSync(t)) {
27
26
  const r = P.readFileSync(t, "utf-8");
28
- if (e = O(r || "{}"), e.pages && Array.isArray(e.pages))
27
+ if (e = M(r || "{}"), e.pages && Array.isArray(e.pages))
29
28
  for (const p of e.pages)
30
- a[`./${p.name}`] = p.module;
29
+ s[`./${p.name}`] = p.module;
31
30
  const o = e.dashboard;
32
- o?.module && (a[`./${C}`] = o.module);
33
- const s = e.settings;
34
- s?.module && (a[`./${I}`] = s.module);
31
+ o?.module && (s[`./${C}`] = o.module);
32
+ const n = e.settings;
33
+ n?.module && (s[`./${I}`] = n.module), console.debug(s);
35
34
  const l = e.development;
36
- c = L(String(e.id)) || c, m = e.entry || m, u = l?.previewPort || u, f = l?.serverPort || f, d = l?.ssl || d;
35
+ c = b(String(e.id)) || c, m = e.entry || m, u = l?.previewPort || u, f = l?.serverPort || f, d = l?.ssl || d;
37
36
  } else
38
37
  console.warn(
39
38
  `[CreopseVuePlugin] Warning: Manifest not found at ${t}`
@@ -44,33 +43,33 @@ function X(h = {}) {
44
43
  r
45
44
  );
46
45
  }
47
- const S = v ? n.resolve(i, v) : n.resolve(i, g, "i18n/locales"), D = {
46
+ const S = v ? i.resolve(a, v) : i.resolve(a, g, "i18n/locales"), D = {
48
47
  name: "creopse-vue-plugin",
49
48
  config(r) {
50
- const o = r.root || i, s = n.resolve(o, w);
49
+ const o = r.root || a, n = i.resolve(o, w);
51
50
  return {
52
51
  envPrefix: "APP_",
53
52
  resolve: {
54
- alias: [{ find: "@", replacement: n.resolve(o, g) }],
53
+ alias: [{ find: "@", replacement: i.resolve(o, g) }],
55
54
  dedupe: ["vue"]
56
55
  },
57
56
  build: {
58
57
  target: "esnext",
59
- outDir: s,
58
+ outDir: n,
60
59
  assetsInlineLimit: 1 / 0,
61
60
  cssCodeSplit: !1,
62
61
  rollupOptions: {
63
62
  plugins: [
64
- N({
63
+ V({
65
64
  targets: [
66
65
  {
67
66
  src: t,
68
- dest: s,
67
+ dest: n,
69
68
  transform() {
70
69
  return e?.mode && (e.mode = E ? "development" : "production"), ((p) => p.replace(/(,)\s*\n/g, `,
71
70
 
72
71
  `))(
73
- V(e, null, 2)
72
+ O(e, null, 2)
74
73
  );
75
74
  }
76
75
  }
@@ -104,23 +103,22 @@ function X(h = {}) {
104
103
  }
105
104
  };
106
105
  return [
107
- B(),
108
- M(),
109
- b({
106
+ j(),
107
+ L({
110
108
  name: c,
111
109
  filename: m,
112
- exposes: a,
110
+ exposes: s,
113
111
  shared: ["vue", "pinia", ...y]
114
112
  }),
115
- k({
113
+ B({
116
114
  promiseExportName: "__tla",
117
115
  promiseImportName: (r) => `__tla_${r}`
118
116
  }),
119
- j({
117
+ $({
120
118
  paths: [S],
121
119
  include: ["**/*.json"]
122
120
  }),
123
- $({
121
+ N({
124
122
  dirs: _,
125
123
  imports: ["vue", "pinia"],
126
124
  vueTemplate: !0
@@ -130,5 +128,5 @@ function X(h = {}) {
130
128
  ];
131
129
  }
132
130
  export {
133
- X as CreopseVuePlugin
131
+ K as CreopseVuePlugin
134
132
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@creopse/bridge",
3
3
  "description": "Creopse Bridge Toolkit",
4
- "version": "0.1.15",
4
+ "version": "0.1.17",
5
5
  "private": false,
6
6
  "author": "Noé Gnanih <noegnanih@gmail.com>",
7
7
  "license": "MIT",