@kosdev-code/kos-ui-plugin 2.1.5 → 2.1.7

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,10 +1,10 @@
1
1
  var A = Object.defineProperty;
2
- var j = (n, e, t) => e in n ? A(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t;
3
- var P = (n, e, t) => (j(n, typeof e != "symbol" ? e + "" : e, t), t);
2
+ var j = (n, t, e) => t in n ? A(n, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[t] = e;
3
+ var P = (n, t, e) => (j(n, typeof t != "symbol" ? t + "" : t, e), e);
4
4
  import { z as E } from "zod";
5
- function N(n, e) {
6
- for (var t = 0; t < e.length; t++) {
7
- const i = e[t];
5
+ function N(n, t) {
6
+ for (var e = 0; e < t.length; e++) {
7
+ const i = t[e];
8
8
  if (typeof i != "string" && !Array.isArray(i)) {
9
9
  for (const s in i)
10
10
  if (s !== "default" && !(s in n)) {
@@ -32,60 +32,60 @@ function V(n) {
32
32
  v = n;
33
33
  }
34
34
  x.setRemoteDefinitions = V;
35
- async function M(n, e) {
36
- const t = `${n}:${e}`;
37
- if (R.has(t))
38
- return R.get(t);
39
- const o = (await (F.has(n) ? F.get(n) : await q(n)).get(e))();
40
- return R.set(t, o), o;
35
+ async function M(n, t) {
36
+ const e = `${n}:${t}`;
37
+ if (R.has(e))
38
+ return R.get(e);
39
+ const o = (await (F.has(n) ? F.get(n) : await q(n)).get(t))();
40
+ return R.set(e, o), o;
41
41
  }
42
42
  x.loadRemoteModule = M;
43
- const L = (n, e) => new Promise((t, i) => {
43
+ const L = (n, t) => new Promise((e, i) => {
44
44
  const s = document.createElement("script");
45
45
  s.src = n, s.type = "text/javascript", s.async = !0, s.onload = () => {
46
- t({
47
- get: (a) => window[e].get(a),
46
+ e({
47
+ get: (a) => window[t].get(a),
48
48
  init: (a) => {
49
49
  try {
50
- window[e].init(a);
50
+ window[t].init(a);
51
51
  } catch (r) {
52
- console.error(`Failed to initialize remote ${e}`, r), i(r);
52
+ console.error(`Failed to initialize remote ${t}`, r), i(r);
53
53
  }
54
54
  }
55
55
  });
56
- }, s.onerror = () => i(new Error(`Remote ${e} not found`)), document.head.appendChild(s);
56
+ }, s.onerror = () => i(new Error(`Remote ${t} not found`)), document.head.appendChild(s);
57
57
  });
58
58
  async function q(n) {
59
59
  if (!S && !v)
60
60
  throw new Error("Call setRemoteDefinitions or setRemoteUrlResolver to allow Dynamic Federation to find the remote apps correctly.");
61
61
  _ || (_ = !0, await __webpack_init_sharing__("default"));
62
- const e = v ? v[n] : await S(n);
63
- let t = e;
64
- !e.endsWith(".mjs") && !e.endsWith(".js") && (t = `${e}${e.endsWith("/") ? "" : "/"}remoteEntry.js`);
65
- const i = await L(t, n);
62
+ const t = v ? v[n] : await S(n);
63
+ let e = t;
64
+ !t.endsWith(".mjs") && !t.endsWith(".js") && (e = `${t}${t.endsWith("/") ? "" : "/"}remoteEntry.js`);
65
+ const i = await L(e, n);
66
66
  return await i.init(__webpack_share_scopes__.default), F.set(n, i), i;
67
67
  }
68
68
  (function(n) {
69
69
  Object.defineProperty(n, "__esModule", { value: !0 }), n.setRemoteUrlResolver = n.setRemoteDefinitions = n.loadRemoteModule = void 0;
70
- var e = x;
70
+ var t = x;
71
71
  Object.defineProperty(n, "loadRemoteModule", { enumerable: !0, get: function() {
72
- return e.loadRemoteModule;
72
+ return t.loadRemoteModule;
73
73
  } }), Object.defineProperty(n, "setRemoteDefinitions", { enumerable: !0, get: function() {
74
- return e.setRemoteDefinitions;
74
+ return t.setRemoteDefinitions;
75
75
  } }), Object.defineProperty(n, "setRemoteUrlResolver", { enumerable: !0, get: function() {
76
- return e.setRemoteUrlResolver;
76
+ return t.setRemoteUrlResolver;
77
77
  } });
78
78
  })(k);
79
79
  const Re = /* @__PURE__ */ N({
80
80
  __proto__: null
81
81
  }, [k]);
82
82
  function B(n) {
83
- var e;
83
+ var t;
84
84
  try {
85
85
  if ("shape" in n) {
86
- const t = n, i = [];
86
+ const e = n, i = [];
87
87
  for (const [s, o] of Object.entries(
88
- t.shape
88
+ e.shape
89
89
  )) {
90
90
  const a = o, r = {
91
91
  name: s,
@@ -93,32 +93,32 @@ function B(n) {
93
93
  };
94
94
  if (a._def && a._def.description && (r.description = a._def.description), a._def) {
95
95
  let c = a._def.typeName || "unknown";
96
- c === "ZodOptional" && a._def.innerType && (c = ((e = a._def.innerType._def) == null ? void 0 : e.typeName) || "unknown"), r.type = c.replace("Zod", "").toLowerCase();
96
+ c === "ZodOptional" && a._def.innerType && (c = ((t = a._def.innerType._def) == null ? void 0 : t.typeName) || "unknown"), r.type = c.replace("Zod", "").toLowerCase();
97
97
  }
98
98
  i.push(r);
99
99
  }
100
100
  return i;
101
101
  }
102
102
  return [];
103
- } catch (t) {
104
- return console.warn("Failed to extract schema field info:", t), [];
103
+ } catch (e) {
104
+ return console.warn("Failed to extract schema field info:", e), [];
105
105
  }
106
106
  }
107
107
  class H {
108
108
  constructor() {
109
109
  P(this, "issues", []);
110
110
  }
111
- addError(e) {
112
- this.issues.push({ type: "error", message: e });
111
+ addError(t) {
112
+ this.issues.push({ type: "error", message: t });
113
113
  }
114
- addWarning(e) {
115
- this.issues.push({ type: "warning", message: e });
114
+ addWarning(t) {
115
+ this.issues.push({ type: "warning", message: t });
116
116
  }
117
- addInfo(e) {
118
- this.issues.push({ type: "info", message: e });
117
+ addInfo(t) {
118
+ this.issues.push({ type: "info", message: t });
119
119
  }
120
120
  hasErrors() {
121
- return this.issues.some((e) => e.type === "error");
121
+ return this.issues.some((t) => t.type === "error");
122
122
  }
123
123
  hasIssues() {
124
124
  return this.issues.length > 0;
@@ -131,11 +131,11 @@ class W {
131
131
  constructor() {
132
132
  P(this, "cache", /* @__PURE__ */ new Map());
133
133
  }
134
- set(e, t) {
135
- this.cache.set(e, t);
134
+ set(t, e) {
135
+ this.cache.set(t, e);
136
136
  }
137
- get(e) {
138
- return this.cache.get(e) || [];
137
+ get(t) {
138
+ return this.cache.get(t) || [];
139
139
  }
140
140
  clear() {
141
141
  this.cache.clear();
@@ -149,9 +149,9 @@ const U = [];
149
149
  function z(n) {
150
150
  U.push(n);
151
151
  }
152
- function G(n, e, t) {
152
+ function G(n, t, e) {
153
153
  return U.reduce(
154
- (i, s) => s(i, e, t),
154
+ (i, s) => s(i, t, e),
155
155
  n
156
156
  );
157
157
  }
@@ -159,31 +159,31 @@ class J {
159
159
  constructor() {
160
160
  P(this, "extensionPoints", /* @__PURE__ */ new Map());
161
161
  }
162
- define(e) {
163
- if (this.extensionPoints.has(e.id))
164
- return console.warn(`Extension point ${e.id} is already defined`), this.extensionPoints.get(e.id);
165
- const t = {
166
- config: e,
167
- id: e.id,
162
+ define(t) {
163
+ if (this.extensionPoints.has(t.id))
164
+ return console.warn(`Extension point ${t.id} is already defined`), this.extensionPoints.get(t.id);
165
+ const e = {
166
+ config: t,
167
+ id: t.id,
168
168
  isRegistered: !1,
169
- getExtensions: (i) => i[e.id] || {},
169
+ getExtensions: (i) => i[t.id] || {},
170
170
  register: () => {
171
- if (t.isRegistered) {
172
- console.warn(`Extension point ${e.id} is already registered`);
171
+ if (e.isRegistered) {
172
+ console.warn(`Extension point ${t.id} is already registered`);
173
173
  return;
174
174
  }
175
- const i = this.createReducer(e);
176
- z(i), t.isRegistered = !0;
175
+ const i = this.createReducer(t);
176
+ z(i), e.isRegistered = !0;
177
177
  }
178
178
  };
179
- return e.schema && (t.getSchemaFieldInfo = () => B(e.schema)), this.extensionPoints.set(e.id, t), t;
179
+ return t.schema && (e.getSchemaFieldInfo = () => B(t.schema)), this.extensionPoints.set(t.id, e), e;
180
180
  }
181
- createReducer(e) {
182
- return (t, i, s) => {
183
- const o = i[e.contributionKey];
181
+ createReducer(t) {
182
+ return (e, i, s) => {
183
+ const o = i[t.contributionKey];
184
184
  return !o || typeof o != "object" || Object.entries(o).forEach(
185
185
  ([a, r]) => {
186
- var f, h;
186
+ var m, h;
187
187
  if (!r)
188
188
  return;
189
189
  const c = {
@@ -192,9 +192,9 @@ class J {
192
192
  experiences: s,
193
193
  contributions: i
194
194
  };
195
- if (e.validate) {
195
+ if (t.validate) {
196
196
  const d = new H();
197
- if (e.validate(
197
+ if (t.validate(
198
198
  r,
199
199
  d
200
200
  ) === "skip") {
@@ -207,48 +207,48 @@ class J {
207
207
  return;
208
208
  }
209
209
  if (d.hasIssues()) {
210
- const b = d.getIssues().map((g) => ({
211
- ...g,
212
- message: `Extension point validation: ${g.message}`
210
+ const b = d.getIssues().map((f) => ({
211
+ ...f,
212
+ message: `Extension point validation: ${f.message}`
213
213
  }));
214
214
  if (w.set(a, b), d.hasErrors()) {
215
215
  console.error(
216
- `Validation failed for ${e.id} contribution "${a}":`,
217
- b.filter((g) => g.type === "error").map((g) => g.message).join(", ")
216
+ `Validation failed for ${t.id} contribution "${a}":`,
217
+ b.filter((f) => f.type === "error").map((f) => f.message).join(", ")
218
218
  );
219
219
  return;
220
220
  }
221
221
  } else
222
222
  w.set(a, []);
223
223
  }
224
- const l = e.transform ? e.transform(r, c) : r;
225
- t[e.id] || (t[e.id] = {});
224
+ const l = t.transform ? t.transform(r, c) : r;
225
+ e[t.id] || (e[t.id] = {});
226
226
  const u = {
227
227
  id: a,
228
- type: e.contributionKey,
228
+ type: t.contributionKey,
229
229
  data: l,
230
230
  remote: c.remote,
231
231
  sectionId: c.sectionId
232
232
  };
233
- if (e.isRankable && typeof r.rank == "number" && (u.rank = r.rank), l && typeof l == "object" && ("component" in l && (u.component = l.component), "view" in l && (u.view = l.view), "location" in l && (u.location = l.location)), t[e.id][a] = u, e.hasView && ((f = e.relatedPoints) != null && f.view)) {
233
+ if (t.isRankable && typeof r.rank == "number" && (u.rank = r.rank), l && typeof l == "object" && ("component" in l && (u.component = l.component), "view" in l && (u.view = l.view), "location" in l && (u.location = l.location)), e[t.id][a] = u, t.hasView && ((m = t.relatedPoints) != null && m.view)) {
234
234
  const d = r.experienceId, p = s == null ? void 0 : s[d];
235
- p && (t[e.relatedPoints.view] || (t[e.relatedPoints.view] = {}), t[e.relatedPoints.view][a] = {
235
+ p && (e[t.relatedPoints.view] || (e[t.relatedPoints.view] = {}), e[t.relatedPoints.view][a] = {
236
236
  id: a,
237
- type: `${e.contributionKey}.view`,
237
+ type: `${t.contributionKey}.view`,
238
238
  data: p,
239
239
  remote: c.remote,
240
240
  sectionId: c.sectionId
241
241
  });
242
242
  }
243
- (h = e.relatedPoints) != null && h.definition && (t[e.relatedPoints.definition] || (t[e.relatedPoints.definition] = {}), t[e.relatedPoints.definition][a] = {
243
+ (h = t.relatedPoints) != null && h.definition && (e[t.relatedPoints.definition] || (e[t.relatedPoints.definition] = {}), e[t.relatedPoints.definition][a] = {
244
244
  id: a,
245
- type: `${e.contributionKey}.definition`,
245
+ type: `${t.contributionKey}.definition`,
246
246
  data: l,
247
247
  remote: c.remote,
248
248
  sectionId: c.sectionId
249
249
  });
250
250
  }
251
- ), t;
251
+ ), e;
252
252
  };
253
253
  }
254
254
  /**
@@ -256,7 +256,7 @@ class J {
256
256
  */
257
257
  getAllExtensionPoints() {
258
258
  return Array.from(this.extensionPoints.values()).filter(
259
- (e) => e.isRegistered
259
+ (t) => t.isRegistered
260
260
  );
261
261
  }
262
262
  /**
@@ -268,14 +268,14 @@ class J {
268
268
  /**
269
269
  * Get a specific extension point definition
270
270
  */
271
- getExtensionPoint(e) {
272
- return this.extensionPoints.get(e);
271
+ getExtensionPoint(t) {
272
+ return this.extensionPoints.get(t);
273
273
  }
274
274
  /**
275
275
  * Check if an extension point is registered
276
276
  */
277
- hasExtensionPoint(e) {
278
- return this.extensionPoints.has(e);
277
+ hasExtensionPoint(t) {
278
+ return this.extensionPoints.has(t);
279
279
  }
280
280
  }
281
281
  const O = new J();
@@ -284,18 +284,18 @@ function y() {
284
284
  }
285
285
  function Z(n = {}) {
286
286
  const {
287
- experienceIdProperty: e = "experienceId",
288
- flattenComponentProperties: t = !0,
287
+ experienceIdProperty: t = "experienceId",
288
+ flattenComponentProperties: e = !0,
289
289
  customTransform: i
290
290
  } = n;
291
291
  return (s, o) => {
292
292
  var l;
293
- const a = s[e], r = a ? ((l = o.experiences) == null ? void 0 : l[a]) || {} : {};
293
+ const a = s[t], r = a ? ((l = o.experiences) == null ? void 0 : l[a]) || {} : {};
294
294
  let c = {
295
295
  ...s,
296
296
  view: r
297
297
  };
298
- return t && r && (r.component && (c.component = r.component), r.location && (c.location = r.location)), i && (c = i(s, r, o) || c), c;
298
+ return e && r && (r.component && (c.component = r.component), r.location && (c.location = r.location)), i && (c = i(s, r, o) || c), c;
299
299
  };
300
300
  }
301
301
  function Y(n) {
@@ -308,7 +308,7 @@ const Q = {
308
308
  $env: () => process.env.NODE_ENV || "development"
309
309
  };
310
310
  function X(n) {
311
- const e = {
311
+ const t = {
312
312
  id: n.id,
313
313
  displayName: n.displayName,
314
314
  description: n.description,
@@ -321,128 +321,128 @@ function X(n) {
321
321
  exportName: n.metadata.exportName || ee(n.id)
322
322
  } : void 0
323
323
  };
324
- return n.schema && (e.schema = te(n.schema, {
324
+ return n.schema && (t.schema = te(n.schema, {
325
325
  hasView: n.hasView,
326
326
  isRankable: n.isRankable
327
- })), n.validation && (e.validate = ie(n.validation)), n.transform ? e.transform = de(n.transform) : n.hasView && (e.transform = Z()), e;
327
+ })), n.validation && (t.validate = ie(n.validation)), n.transform ? t.transform = de(n.transform) : n.hasView && (t.transform = Z()), t;
328
328
  }
329
329
  function ee(n) {
330
- return n.split(".").map((e) => e.charAt(0).toUpperCase() + e.slice(1)).join("") + "Extension";
330
+ return n.split(".").map((t) => t.charAt(0).toUpperCase() + t.slice(1)).join("") + "Extension";
331
331
  }
332
- function te(n, e) {
332
+ function te(n, t) {
333
333
  try {
334
- const { z: t } = require("zod");
334
+ const { z: e } = require("zod");
335
335
  if (n.properties) {
336
336
  const i = {};
337
- i.id = t.string().min(1), i.title = t.string().min(1), i.namespace = t.string().min(1), e != null && e.hasView && (i.experienceId = t.string().min(1)), e != null && e.isRankable && (i.rank = t.number().min(0).max(1e3).optional());
337
+ i.id = e.string().min(1), i.title = e.string().min(1), i.namespace = e.string().min(1), t != null && t.hasView && (i.experienceId = e.string().min(1)), t != null && t.isRankable && (i.rank = e.number().min(0).max(1e3).optional());
338
338
  for (const [o, a] of Object.entries(n.properties))
339
- i[o] = ne(a, t);
340
- let s = t.object(i);
339
+ i[o] = ne(a, e);
340
+ let s = e.object(i);
341
341
  return n.additionalProperties || (s = s.strict()), s;
342
342
  }
343
- return t.any();
344
- } catch (t) {
345
- console.warn("Zod not available for JSON schema conversion:", t);
343
+ return e.any();
344
+ } catch (e) {
345
+ console.warn("Zod not available for JSON schema conversion:", e);
346
346
  return;
347
347
  }
348
348
  }
349
- function ne(n, e) {
350
- let t;
349
+ function ne(n, t) {
350
+ let e;
351
351
  switch (n.type) {
352
352
  case "string":
353
- t = e.string(), n.minLength && (t = t.min(n.minLength)), n.maxLength && (t = t.max(n.maxLength)), n.pattern && (t = t.regex(new RegExp(n.pattern))), n.enum && (t = e.enum(n.enum));
353
+ e = t.string(), n.minLength && (e = e.min(n.minLength)), n.maxLength && (e = e.max(n.maxLength)), n.pattern && (e = e.regex(new RegExp(n.pattern))), n.enum && (e = t.enum(n.enum));
354
354
  break;
355
355
  case "number":
356
- t = e.number(), n.minimum !== void 0 && (t = t.min(n.minimum)), n.maximum !== void 0 && (t = t.max(n.maximum));
356
+ e = t.number(), n.minimum !== void 0 && (e = e.min(n.minimum)), n.maximum !== void 0 && (e = e.max(n.maximum));
357
357
  break;
358
358
  case "boolean":
359
- t = e.boolean();
359
+ e = t.boolean();
360
360
  break;
361
361
  case "array":
362
- t = e.array(e.any());
362
+ e = t.array(t.any());
363
363
  break;
364
364
  case "object":
365
- t = e.object({});
365
+ e = t.object({});
366
366
  break;
367
367
  default:
368
- t = e.any();
368
+ e = t.any();
369
369
  }
370
- return n.description && (t = t.describe(n.description)), n.default !== void 0 && (t = t.default(n.default)), t;
370
+ return n.description && (e = e.describe(n.description)), n.default !== void 0 && (e = e.default(n.default)), e;
371
371
  }
372
372
  function ie(n) {
373
- return n.module ? ue(n.module) : (e, t) => {
373
+ return n.module ? ue(n.module) : (t, e) => {
374
374
  if (!n.rules)
375
375
  return;
376
- const i = e;
376
+ const i = t;
377
377
  for (const s of n.rules)
378
- se(s, i, t);
378
+ se(s, i, e);
379
379
  };
380
380
  }
381
- function se(n, e, t) {
381
+ function se(n, t, e) {
382
382
  switch (n.type) {
383
383
  case "required":
384
- oe(n, e, t);
384
+ oe(n, t, e);
385
385
  break;
386
386
  case "range":
387
- re(n, e, t);
387
+ re(n, t, e);
388
388
  break;
389
389
  case "pattern":
390
- ae(n, e, t);
390
+ ae(n, t, e);
391
391
  break;
392
392
  case "dependency":
393
- ce(n, e, t);
393
+ ce(n, t, e);
394
394
  break;
395
395
  case "custom":
396
- le(n, e, t);
396
+ le(n, t, e);
397
397
  break;
398
398
  }
399
399
  }
400
- function oe(n, e, t) {
401
- n.field && !e[n.field] && t.addError(n.message || `Field '${n.field}' is required`);
400
+ function oe(n, t, e) {
401
+ n.field && !t[n.field] && e.addError(n.message || `Field '${n.field}' is required`);
402
402
  }
403
- function re(n, e, t) {
404
- if (n.field && typeof e[n.field] == "number") {
405
- const i = e[n.field];
406
- n.min !== void 0 && i < n.min && t.addError(
403
+ function re(n, t, e) {
404
+ if (n.field && typeof t[n.field] == "number") {
405
+ const i = t[n.field];
406
+ n.min !== void 0 && i < n.min && e.addError(
407
407
  n.message || `Field '${n.field}' must be at least ${n.min}`
408
- ), n.max !== void 0 && i > n.max && t.addError(
408
+ ), n.max !== void 0 && i > n.max && e.addError(
409
409
  n.message || `Field '${n.field}' must be at most ${n.max}`
410
410
  );
411
411
  }
412
412
  }
413
- function ae(n, e, t) {
414
- n.field && n.pattern && typeof e[n.field] == "string" && (new RegExp(n.pattern).test(e[n.field]) || t.addError(
413
+ function ae(n, t, e) {
414
+ n.field && n.pattern && typeof t[n.field] == "string" && (new RegExp(n.pattern).test(t[n.field]) || e.addError(
415
415
  n.message || `Field '${n.field}' does not match pattern ${n.pattern}`
416
416
  ));
417
417
  }
418
- function ce(n, e, t) {
418
+ function ce(n, t, e) {
419
419
  if (n.field && n.dependsOn && n.expression)
420
420
  try {
421
- $(n.expression, e) || t.addError(
421
+ $(n.expression, t) || e.addError(
422
422
  n.message || `Field '${n.field}' dependency validation failed`
423
423
  );
424
424
  } catch (i) {
425
- t.addWarning(`Failed to evaluate dependency expression: ${i}`);
425
+ e.addWarning(`Failed to evaluate dependency expression: ${i}`);
426
426
  }
427
427
  }
428
- function le(n, e, t) {
428
+ function le(n, t, e) {
429
429
  if (n.expression)
430
430
  try {
431
- $(n.expression, e) || t.addError(n.message || "Custom validation failed");
431
+ $(n.expression, t) || e.addError(n.message || "Custom validation failed");
432
432
  } catch (i) {
433
- t.addWarning(`Failed to evaluate custom expression: ${i}`);
433
+ e.addWarning(`Failed to evaluate custom expression: ${i}`);
434
434
  }
435
435
  }
436
436
  function ue(n) {
437
- return (e, t) => {
438
- console.warn(`External validation module not implemented: ${n}`), t.addWarning(
437
+ return (t, e) => {
438
+ console.warn(`External validation module not implemented: ${n}`), e.addWarning(
439
439
  `External validation module not yet supported: ${n}`
440
440
  );
441
441
  };
442
442
  }
443
443
  function de(n) {
444
- return n.module ? pe(n.module) : (e, t) => {
445
- const i = { ...e };
444
+ return n.module ? pe(n.module) : (t, e) => {
445
+ const i = { ...t };
446
446
  if (n.addFields)
447
447
  for (const [s, o] of Object.entries(n.addFields))
448
448
  i[s] = fe(o);
@@ -464,18 +464,18 @@ function de(n) {
464
464
  };
465
465
  }
466
466
  function pe(n) {
467
- return (e, t) => (console.warn(`External transform module not implemented: ${n}`), e);
467
+ return (t, e) => (console.warn(`External transform module not implemented: ${n}`), t);
468
468
  }
469
469
  function fe(n) {
470
470
  if (typeof n == "string" && n.startsWith("$")) {
471
- const e = Q[n];
472
- if (e)
473
- return e();
471
+ const t = Q[n];
472
+ if (t)
473
+ return t();
474
474
  }
475
475
  return n;
476
476
  }
477
- function me(n, e) {
478
- switch (e) {
477
+ function me(n, t) {
478
+ switch (t) {
479
479
  case "trim":
480
480
  return n.trim();
481
481
  case "lowercase":
@@ -491,81 +491,81 @@ function me(n, e) {
491
491
  }
492
492
  }
493
493
  function ge(n) {
494
- return n.replace(/[-_\s]+(.)?/g, (e, t) => t ? t.toUpperCase() : "").replace(/^./, (e) => e.toLowerCase());
494
+ return n.replace(/[-_\s]+(.)?/g, (t, e) => e ? e.toUpperCase() : "").replace(/^./, (t) => t.toLowerCase());
495
495
  }
496
496
  function he(n) {
497
497
  return n.replace(/([a-z])([A-Z])/g, "$1-$2").replace(/[\s_]+/g, "-").toLowerCase();
498
498
  }
499
- function $(n, e) {
499
+ function $(n, t) {
500
500
  try {
501
- let t = n;
502
- for (const [i, s] of Object.entries(e)) {
501
+ let e = n;
502
+ for (const [i, s] of Object.entries(t)) {
503
503
  const o = typeof s == "string" ? `"${s}"` : String(s);
504
- t = t.replace(
504
+ e = e.replace(
505
505
  new RegExp(`\\b${i}\\b`, "g"),
506
506
  o
507
507
  );
508
508
  }
509
- if (t.includes("!==")) {
510
- const [i, s] = t.split("!==").map((o) => o.trim());
509
+ if (e.includes("!==")) {
510
+ const [i, s] = e.split("!==").map((o) => o.trim());
511
511
  return i !== s;
512
512
  }
513
- if (t.includes("===")) {
514
- const [i, s] = t.split("===").map((o) => o.trim());
513
+ if (e.includes("===")) {
514
+ const [i, s] = e.split("===").map((o) => o.trim());
515
515
  return i === s;
516
516
  }
517
- return t.includes("||") ? t.split("||").map((s) => s.trim()).some((s) => $(s, e)) : t.includes("&&") ? t.split("&&").map((s) => s.trim()).every((s) => $(s, e)) : !1;
518
- } catch (t) {
519
- return console.error("Expression evaluation failed:", t), !1;
517
+ return e.includes("||") ? e.split("||").map((s) => s.trim()).some((s) => $(s, t)) : e.includes("&&") ? e.split("&&").map((s) => s.trim()).every((s) => $(s, t)) : !1;
518
+ } catch (e) {
519
+ return console.error("Expression evaluation failed:", e), !1;
520
520
  }
521
521
  }
522
- const ye = (n) => (e, t) => {
522
+ const ye = (n) => (t, e) => {
523
523
  var c;
524
- const i = n[t].remote, s = t, o = (c = n[t].contributes) == null ? void 0 : c.experiences;
524
+ const i = n[e].remote, s = e, o = (c = n[e].contributes) == null ? void 0 : c.experiences;
525
525
  return Object.keys(o).forEach((l) => {
526
526
  const u = o[l];
527
- e.experiences[l] = {
527
+ t.experiences[l] = {
528
528
  ...u,
529
529
  remote: i,
530
530
  sectionId: s
531
531
  };
532
532
  }), y().getAllExtensionPoints().forEach((l) => {
533
533
  var h;
534
- const { contributionKey: u } = l.config, f = (h = n[t].contributes) == null ? void 0 : h[u];
535
- f && (e[u] || (e[u] = {}), Array.isArray(f) ? f.forEach((d) => {
536
- d && d.id && (e[u][d.id] = {
534
+ const { contributionKey: u } = l.config, m = (h = n[e].contributes) == null ? void 0 : h[u];
535
+ m && (t[u] || (t[u] = {}), Array.isArray(m) ? m.forEach((d) => {
536
+ d && d.id && (t[u][d.id] = {
537
537
  ...d,
538
538
  remote: i,
539
539
  sectionId: s
540
540
  });
541
- }) : typeof f == "object" && Object.entries(f).forEach(([d, p]) => {
542
- e[u][d] = {
541
+ }) : typeof m == "object" && Object.entries(m).forEach(([d, p]) => {
542
+ t[u][d] = {
543
543
  ...p,
544
544
  id: d,
545
545
  remote: i,
546
546
  sectionId: s
547
547
  };
548
548
  }));
549
- }), e;
549
+ }), t;
550
550
  };
551
551
  async function be(n) {
552
- const e = n ?? window.KosPlugins.__dynamicRemotes;
552
+ const t = n ?? window.KosPlugins.__dynamicRemotes;
553
553
  if (window.KosPlugins.extensions) {
554
554
  const o = window.KosPlugins.extensions;
555
555
  return {
556
556
  extensionPoints: o,
557
557
  getExtensions: (a) => o[a] || [],
558
- remotes: e,
558
+ remotes: t,
559
559
  extensions: window.KosPlugins.__extensions
560
560
  };
561
561
  }
562
- const t = window.KosPlugins.__extensions ?? await Ee(e), i = {};
563
- if (t)
564
- for (const o of Object.keys(t))
562
+ const e = window.KosPlugins.__extensions ?? await Ee(t), i = {};
563
+ if (e)
564
+ for (const o of Object.keys(e))
565
565
  i[o] = Object.values(
566
- t[o] || {}
566
+ e[o] || {}
567
567
  );
568
- return window.KosPlugins.extensions = i, { extensionPoints: i, getExtensions: (o) => i[o] || [], remotes: e, extensions: t };
568
+ return window.KosPlugins.extensions = i, { extensionPoints: i, getExtensions: (o) => i[o] || [], remotes: t, extensions: e };
569
569
  }
570
570
  const T = {
571
571
  controlPourDefinitions: {},
@@ -618,55 +618,55 @@ async function Ee(n) {
618
618
  console.warn(`Failed to load InitPlugin from ${o.remote}:`, a);
619
619
  }
620
620
  }
621
- const e = xe(n), t = e.experiences, s = G(
621
+ const t = xe(n), e = t.experiences, s = G(
622
622
  {},
623
- e,
624
- t
623
+ t,
624
+ e
625
625
  );
626
626
  return window.KosPlugins = window.KosPlugins || {}, window.KosPlugins.__extensions = s, s;
627
627
  }
628
628
  async function Se(n) {
629
- const { getExtensions: e } = await be();
630
- return e(n);
629
+ const { getExtensions: t } = await be();
630
+ return t(n);
631
631
  }
632
- const Pe = (n = null) => (n || window.location.search.replace("?", "")).split("&").map((e) => {
633
- const [t, i] = e.split("=");
634
- return [t, decodeURIComponent(i || "")];
635
- }).reduce((e, [t, i]) => (e[t] = i, e), {}), ve = () => {
636
- const n = window.location.origin, e = Pe();
637
- return (e == null ? void 0 : e.host) || n;
632
+ const Pe = (n = null) => (n || window.location.search.replace("?", "")).split("&").map((t) => {
633
+ const [e, i] = t.split("=");
634
+ return [e, decodeURIComponent(i || "")];
635
+ }).reduce((t, [e, i]) => (t[e] = i, t), {}), ve = () => {
636
+ const n = window.location.origin, t = Pe();
637
+ return (t == null ? void 0 : t.host) || n;
638
638
  }, Fe = async (n) => {
639
- var p, b;
640
- const e = ve(), t = n ?? {}, {
641
- pluginBaseUrl: i = e,
639
+ var b;
640
+ const t = ve(), e = n ?? {}, {
641
+ pluginBaseUrl: i = t,
642
642
  pluginApiPath: s = "/api/app/kosdev.ddk/ncui/plugins",
643
643
  overrides: o = {},
644
644
  pluginContext: a
645
- } = t, r = !!a, c = r ? `${i}/api/kos/ui/plugins/context/${a.context}` : `${i}${s}`;
645
+ } = e, r = !!a, c = r ? `${i}/api/kos/ui/plugins/contexts` : `${i}${s}`;
646
646
  console.log(
647
647
  `initialize-plugins: Using Plugin Framework: ${r}: Fetching plugins from ${c}`
648
648
  );
649
- const u = await (await fetch(c)).json(), f = r ? ((b = (p = u.data) == null ? void 0 : p.groups) == null ? void 0 : b[a.group]) ?? [] : u.data ?? [], h = f == null ? void 0 : f.reduce((g, m) => {
650
- const C = (o == null ? void 0 : o[m.id]) ?? r ? `${i}${m.path}` : `${i}${m.baseUrl}`;
651
- return m.descriptor ? g[m.id] = {
649
+ const u = await (await fetch(c)).json(), m = typeof (a == null ? void 0 : a.context) == "string" ? [a.context] : (a == null ? void 0 : a.context) || [], h = r ? ((b = u.data) == null ? void 0 : b.filter((f) => m.includes(f.name)).flatMap((f) => f.plugins)) ?? [] : u.data ?? [], d = h == null ? void 0 : h.reduce((f, g) => {
650
+ const C = (o == null ? void 0 : o[g.id]) ?? r ? `${i}${g.path}` : `${i}${g.baseUrl}`;
651
+ return g.descriptor ? f[g.id] = {
652
652
  basePath: `${C}remoteEntry.js`,
653
- extensions: m.descriptor.extensions || [],
654
- contributes: m.descriptor.contributes,
655
- remote: m.descriptor.id,
656
- init: !!m.descriptor.init
653
+ extensions: g.descriptor.extensions || [],
654
+ contributes: g.descriptor.contributes,
655
+ remote: g.descriptor.id,
656
+ init: !!g.descriptor.init
657
657
  } : console.error(
658
- `initialize-plugins: Plugin ${m.id} does not have a descriptor`
659
- ), g;
658
+ `initialize-plugins: Plugin ${g.id} does not have a descriptor`
659
+ ), f;
660
660
  }, {});
661
- window.KosPlugins = window.KosPlugins || {}, window.KosPlugins.__dynamicRemotes = h;
662
- const d = Object.keys(h).reduce((g, m) => {
663
- const C = h[m].remote;
664
- return g[C] = h[m].basePath, g;
661
+ window.KosPlugins = window.KosPlugins || {}, window.KosPlugins.__dynamicRemotes = d;
662
+ const p = Object.keys(d).reduce((f, g) => {
663
+ const C = d[g].remote;
664
+ return f[C] = d[g].basePath, f;
665
665
  }, {});
666
- return k.setRemoteDefinitions(d), d;
666
+ return k.setRemoteDefinitions(p), p;
667
667
  };
668
- function _e(n, e, t = !1) {
669
- return !n || Object.keys(n).length === 0 ? null : t ? e && n[e] ? n[e] : null : e && n[e] ? n[e] : Object.values(n).filter((s) => typeof s.id == "string").sort((s, o) => {
668
+ function _e(n, t, e = !1) {
669
+ return !n || Object.keys(n).length === 0 ? null : e ? t && n[t] ? n[t] : null : t && n[t] ? n[t] : Object.values(n).filter((s) => typeof s.id == "string").sort((s, o) => {
670
670
  const a = typeof s.rank == "number" ? s.rank : 1 / 0, r = typeof o.rank == "number" ? o.rank : 1 / 0;
671
671
  if (a === r) {
672
672
  const c = s.id ?? "", l = o.id ?? "";
@@ -683,39 +683,39 @@ const D = E.object({
683
683
  }), we = D.extend({
684
684
  rank: E.number().int().min(0).optional().describe("Optional ranking for ordering (higher = preferred)")
685
685
  });
686
- function Te(n, e, t) {
687
- const i = n.safeParse(e);
686
+ function Te(n, t, e) {
687
+ const i = n.safeParse(t);
688
688
  return i.success ? !0 : (i.error.errors.forEach((s) => {
689
- t.addError(`${s.path.join(".")}: ${s.message}`);
689
+ e.addError(`${s.path.join(".")}: ${s.message}`);
690
690
  }), !1);
691
691
  }
692
- function Ue(n, e, t) {
693
- e && !e.includes(".") && t.addWarning(
694
- `${n} '${e}' should typically include dot notation (e.g., 'category.item')`
692
+ function Ue(n, t, e) {
693
+ t && !t.includes(".") && e.addWarning(
694
+ `${n} '${t}' should typically include dot notation (e.g., 'category.item')`
695
695
  );
696
696
  }
697
- function $e(n, e, t = 1e3) {
698
- n !== void 0 && n > t && e.addWarning(
697
+ function $e(n, t, e = 1e3) {
698
+ n !== void 0 && n > e && t.addWarning(
699
699
  `Rank ${n} seems unusually high - consider using lower values for better ordering`
700
700
  );
701
701
  }
702
- function Oe(n, e = {}) {
703
- return (e.rankable ? we : D).extend(n);
702
+ function Oe(n, t = {}) {
703
+ return (t.rankable ? we : D).extend(n);
704
704
  }
705
- function De(n, e, t = 1e3) {
706
- typeof n == "object" && n !== null && "rank" in n && $e(n.rank, e, t);
705
+ function De(n, t, e = 1e3) {
706
+ typeof n == "object" && n !== null && "rank" in n && $e(n.rank, t, e);
707
707
  }
708
708
  class I {
709
709
  /**
710
710
  * Get all extension points with their plugin information
711
711
  */
712
- static getExtensionPoints(e, t = {}) {
712
+ static getExtensionPoints(t, e = {}) {
713
713
  const {
714
714
  includeLegacyExtensions: i = !0,
715
715
  includeEmptyExtensionPoints: s = !0
716
- } = t, a = y().getAllExtensionPoints(), r = [];
716
+ } = e, a = y().getAllExtensionPoints(), r = [];
717
717
  return a.forEach((c) => {
718
- const l = Object.values((e == null ? void 0 : e[c.id]) || {});
718
+ const l = Object.values((t == null ? void 0 : t[c.id]) || {});
719
719
  !s && l.length === 0 || r.push({
720
720
  id: c.id,
721
721
  displayName: c.config.displayName,
@@ -725,8 +725,8 @@ class I {
725
725
  pluginCount: l.length,
726
726
  plugins: l
727
727
  });
728
- }), i && e && Object.entries(e).forEach(([c, l]) => {
729
- if (r.some((f) => f.id === c))
728
+ }), i && t && Object.entries(t).forEach(([c, l]) => {
729
+ if (r.some((m) => m.id === c))
730
730
  return;
731
731
  const u = Object.values(l || {});
732
732
  !s && u.length === 0 || r.push({
@@ -740,38 +740,38 @@ class I {
740
740
  /**
741
741
  * Filter extension points based on search criteria
742
742
  */
743
- static filterExtensionPoints(e, t) {
744
- if (!t.trim())
745
- return e;
746
- const i = t.toLowerCase();
747
- return e.filter(
743
+ static filterExtensionPoints(t, e) {
744
+ if (!e.trim())
745
+ return t;
746
+ const i = e.toLowerCase();
747
+ return t.filter(
748
748
  (s) => {
749
749
  var o, a, r, c, l, u;
750
- return s.id.toLowerCase().includes(i) || ((o = s.displayName) == null ? void 0 : o.toLowerCase().includes(i)) || ((a = s.description) == null ? void 0 : a.toLowerCase().includes(i)) || ((c = (r = s.metadata) == null ? void 0 : r.category) == null ? void 0 : c.toLowerCase().includes(i)) || ((u = (l = s.metadata) == null ? void 0 : l.tags) == null ? void 0 : u.some((f) => f.toLowerCase().includes(i)));
750
+ return s.id.toLowerCase().includes(i) || ((o = s.displayName) == null ? void 0 : o.toLowerCase().includes(i)) || ((a = s.description) == null ? void 0 : a.toLowerCase().includes(i)) || ((c = (r = s.metadata) == null ? void 0 : r.category) == null ? void 0 : c.toLowerCase().includes(i)) || ((u = (l = s.metadata) == null ? void 0 : l.tags) == null ? void 0 : u.some((m) => m.toLowerCase().includes(i)));
751
751
  }
752
752
  );
753
753
  }
754
754
  /**
755
755
  * Calculate health statistics for the plugin system
756
756
  */
757
- static calculateHealthStats(e) {
758
- const t = e.length, i = e.filter(
757
+ static calculateHealthStats(t) {
758
+ const e = t.length, i = t.filter(
759
759
  (c) => c.pluginCount > 0
760
- ).length, s = e.reduce(
760
+ ).length, s = t.reduce(
761
761
  (c, l) => c + l.pluginCount,
762
762
  0
763
- ), o = e.filter(
763
+ ), o = t.filter(
764
764
  (c) => c.source === "simplified"
765
- ).length, a = e.filter(
765
+ ).length, a = t.filter(
766
766
  (c) => c.source === "legacy"
767
- ).length, r = e.filter(
767
+ ).length, r = t.filter(
768
768
  (c) => {
769
769
  var l;
770
770
  return (l = c.metadata) == null ? void 0 : l.deprecated;
771
771
  }
772
772
  ).length;
773
773
  return {
774
- totalExtensionPoints: t,
774
+ totalExtensionPoints: e,
775
775
  extensionPointsWithPlugins: i,
776
776
  totalPlugins: s,
777
777
  simplifiedExtensionPoints: o,
@@ -782,16 +782,16 @@ class I {
782
782
  /**
783
783
  * Analyze a specific plugin for health and capabilities
784
784
  */
785
- static analyzePlugin(e) {
786
- const t = !!e.component, i = typeof e.rank == "number", s = e.rank || 0, o = [];
787
- if (t ? o.push("UI Component") : o.push("Background Service"), i && o.push(`Rank: ${s}`), e.namespace) {
788
- const r = e.namespace;
785
+ static analyzePlugin(t) {
786
+ const e = !!t.component, i = typeof t.rank == "number", s = t.rank || 0, o = [];
787
+ if (e ? o.push("UI Component") : o.push("Background Service"), i && o.push(`Rank: ${s}`), t.namespace) {
788
+ const r = t.namespace;
789
789
  r.includes("kos") || r.includes("ddk") ? o.push("First-party") : o.push("Third-party");
790
790
  }
791
- e.modalMode && o.push(`Modal: ${e.modalMode}`);
791
+ t.modalMode && o.push(`Modal: ${t.modalMode}`);
792
792
  let a = "healthy";
793
- return e.remote || (a = "warning"), {
794
- hasComponent: t,
793
+ return t.remote || (a = "warning"), {
794
+ hasComponent: e,
795
795
  hasRank: i,
796
796
  healthStatus: a,
797
797
  capabilities: o
@@ -800,55 +800,55 @@ class I {
800
800
  /**
801
801
  * Get extension point by ID with detailed information
802
802
  */
803
- static getExtensionPointById(e, t) {
804
- return e.find((i) => i.id === t);
803
+ static getExtensionPointById(t, e) {
804
+ return t.find((i) => i.id === e);
805
805
  }
806
806
  /**
807
807
  * Validate if an extension point ID follows conventions
808
808
  */
809
- static validateExtensionPointId(e) {
810
- const t = [], i = [];
811
- e.includes(".") || (t.push(
809
+ static validateExtensionPointId(t) {
810
+ const e = [], i = [];
811
+ t.includes(".") || (e.push(
812
812
  "Extension point ID should contain at least one dot (namespace.feature)"
813
813
  ), i.push('Use format like "ddk.myFeature" or "app.myFeature"'));
814
- const s = e.split(".");
815
- s.length < 2 && t.push(
814
+ const s = t.split(".");
815
+ s.length < 2 && e.push(
816
816
  "Extension point ID should have at least 2 parts (namespace.feature)"
817
817
  );
818
818
  const o = s[0];
819
819
  return o && !["ddk", "cui", "app"].includes(o) && !o.endsWith("app") && i.push(
820
820
  "Consider using standard namespaces: ddk, cui, or [appname]app"
821
- ), s.some((r) => /[A-Z]/.test(r)) && (t.push("Extension point ID parts should be lowercase"), i.push(
821
+ ), s.some((r) => /[A-Z]/.test(r)) && (e.push("Extension point ID parts should be lowercase"), i.push(
822
822
  'Use kebab-case or dot notation: "my.feature" not "my.myFeature"'
823
823
  )), {
824
- isValid: t.length === 0,
825
- issues: t,
824
+ isValid: e.length === 0,
825
+ issues: e,
826
826
  suggestions: i
827
827
  };
828
828
  }
829
829
  /**
830
830
  * Validate a plugin descriptor structure and content
831
831
  */
832
- static validatePluginDescriptor(e) {
833
- const t = [], i = [], s = [], o = [];
834
- if (e.id ? e.id.match(/^[a-z0-9-]+$/) || o.push(
832
+ static validatePluginDescriptor(t) {
833
+ const e = [], i = [], s = [], o = [];
834
+ if (t.id ? t.id.match(/^[a-z0-9-]+$/) || o.push(
835
835
  "Plugin ID convention: use lowercase letters, numbers, and hyphens (e.g., 'my-awesome-plugin')"
836
- ) : (s.push("id"), t.push("Plugin descriptor must have an 'id' field")), !e.contributes)
836
+ ) : (s.push("id"), e.push("Plugin descriptor must have an 'id' field")), !t.contributes)
837
837
  i.push(
838
838
  "Plugin has no contributions - it won't extend any functionality"
839
839
  ), o.push("Add a 'contributes' section with plugin contributions");
840
840
  else {
841
- const a = Object.keys(e.contributes);
841
+ const a = Object.keys(t.contributes);
842
842
  a.length === 0 && i.push("Plugin contributes section is empty"), a.forEach((r) => {
843
- const c = e.contributes[r];
843
+ const c = t.contributes[r];
844
844
  if (!Array.isArray(c)) {
845
- t.push(`Contribution '${r}' must be an array`);
845
+ e.push(`Contribution '${r}' must be an array`);
846
846
  return;
847
847
  }
848
848
  c.forEach((l, u) => {
849
- l.id || t.push(
849
+ l.id || e.push(
850
850
  `Contribution ${r}[${u}] missing required 'id' field`
851
- ), r === "experiences" && l.component && !l.location && (t.push(
851
+ ), r === "experiences" && l.component && !l.location && (e.push(
852
852
  `Experience '${l.id}' has component but no location`
853
853
  ), o.push(
854
854
  "Add 'location' field pointing to the component file"
@@ -856,15 +856,15 @@ class I {
856
856
  `${r} contribution '${l.id}' missing 'title' field`
857
857
  ), l.namespace || i.push(
858
858
  `${r} contribution '${l.id}' missing 'namespace' field`
859
- ), l.experienceId || t.push(
859
+ ), l.experienceId || e.push(
860
860
  `${r} contribution '${l.id}' missing required 'experienceId' field`
861
861
  ));
862
862
  });
863
863
  });
864
864
  }
865
- return e.init !== void 0 && typeof e.init != "boolean" && t.push("'init' field must be a boolean value"), {
866
- isValid: t.length === 0 && s.length === 0,
867
- errors: t,
865
+ return t.init !== void 0 && typeof t.init != "boolean" && e.push("'init' field must be a boolean value"), {
866
+ isValid: e.length === 0 && s.length === 0,
867
+ errors: e,
868
868
  warnings: i,
869
869
  missingRequired: s,
870
870
  suggestions: o
@@ -873,9 +873,9 @@ class I {
873
873
  /**
874
874
  * Check compatibility between plugin contributions and available extension points
875
875
  */
876
- static checkPluginCompatibility(e, t) {
876
+ static checkPluginCompatibility(t, e) {
877
877
  const i = [], s = [], o = [], a = [];
878
- if (!e.contributes)
878
+ if (!t.contributes)
879
879
  return {
880
880
  isCompatible: !0,
881
881
  issues: ["Plugin has no contributions to check"],
@@ -884,9 +884,9 @@ class I {
884
884
  suggestions: []
885
885
  };
886
886
  const r = y(), c = new Set(
887
- t.map((l) => l.id)
887
+ e.map((l) => l.id)
888
888
  );
889
- return Object.entries(e.contributes).forEach(
889
+ return Object.entries(t.contributes).forEach(
890
890
  ([l, u]) => {
891
891
  this.getExpectedExtensionPoints(l).forEach((p) => {
892
892
  c.has(p) || (s.push(p), i.push(
@@ -921,7 +921,7 @@ class I {
921
921
  /**
922
922
  * Map contribution keys to their expected extension point IDs
923
923
  */
924
- static getExpectedExtensionPoints(e) {
924
+ static getExpectedExtensionPoints(t) {
925
925
  return {
926
926
  cui: ["ddk.cui", "ddk.cui.view", "ddk.cui.settings.config"],
927
927
  utilities: ["ddk.utility", "ddk.utility.view", "ddk.utilities"],
@@ -934,21 +934,21 @@ class I {
934
934
  // Experiences don't directly map to extension points
935
935
  views: []
936
936
  // Views are mapped by their extension point ID keys
937
- }[e] || [];
937
+ }[t] || [];
938
938
  }
939
939
  /**
940
940
  * Get comprehensive plugin analysis including validation and compatibility
941
941
  */
942
- static analyzePluginDescriptor(e, t) {
943
- const i = this.validatePluginDescriptor(e), s = this.checkPluginCompatibility(
944
- e,
945
- t
942
+ static analyzePluginDescriptor(t, e) {
943
+ const i = this.validatePluginDescriptor(t), s = this.checkPluginCompatibility(
944
+ t,
945
+ e
946
946
  ), o = [];
947
947
  return i.warnings.length > 0 && o.push(
948
948
  "Address validation warnings to improve plugin quality"
949
949
  ), s.isCompatible || o.push(
950
950
  "Resolve compatibility issues before deploying plugin"
951
- ), e.contributes && Object.keys(e.contributes).length === 1 && o.push(
951
+ ), t.contributes && Object.keys(t.contributes).length === 1 && o.push(
952
952
  "Consider adding more contribution types to increase plugin value"
953
953
  ), {
954
954
  validation: i,
@@ -961,14 +961,14 @@ class Ae {
961
961
  /**
962
962
  * Generate complete documentation for all extension points
963
963
  */
964
- static generateFullDocumentation(e, t = {}) {
964
+ static generateFullDocumentation(t, e = {}) {
965
965
  const {
966
966
  includeUsageExamples: i = !0,
967
967
  includeTypeDefinitions: s = !0,
968
968
  includeLegacyExtensions: o = !0,
969
969
  includePluginHealth: a = !0
970
- } = t, r = I.getExtensionPoints(
971
- e,
970
+ } = e, r = I.getExtensionPoints(
971
+ t,
972
972
  {
973
973
  includeLegacyExtensions: o,
974
974
  includeEmptyExtensionPoints: !0
@@ -994,18 +994,18 @@ class Ae {
994
994
  /**
995
995
  * Generate documentation header with metadata
996
996
  */
997
- static generateHeader(e) {
997
+ static generateHeader(t) {
998
998
  return `# KOS Plugin Extension Points Reference
999
999
 
1000
1000
  **Generated**: ${(/* @__PURE__ */ new Date()).toLocaleString()}
1001
1001
 
1002
1002
  ## System Overview
1003
1003
 
1004
- - **Total Extension Points**: ${e.totalExtensionPoints}
1005
- - **Extension Points with Plugins**: ${e.extensionPointsWithPlugins}
1006
- - **Total Active Plugins**: ${e.totalPlugins}
1007
- - **Simplified Extension Points**: ${e.simplifiedExtensionPoints}
1008
- - **Legacy Extension Points**: ${e.legacyExtensionPoints}
1004
+ - **Total Extension Points**: ${t.totalExtensionPoints}
1005
+ - **Extension Points with Plugins**: ${t.extensionPointsWithPlugins}
1006
+ - **Total Active Plugins**: ${t.totalPlugins}
1007
+ - **Simplified Extension Points**: ${t.simplifiedExtensionPoints}
1008
+ - **Legacy Extension Points**: ${t.legacyExtensionPoints}
1009
1009
 
1010
1010
  ---
1011
1011
 
@@ -1014,26 +1014,26 @@ class Ae {
1014
1014
  /**
1015
1015
  * Generate table of contents
1016
1016
  */
1017
- static generateTableOfContents(e) {
1018
- let t = `## Table of Contents
1017
+ static generateTableOfContents(t) {
1018
+ let e = `## Table of Contents
1019
1019
 
1020
1020
  `;
1021
- return t += `- [Overview](#overview)
1022
- `, t += `- [Extension Points](#extension-points)
1023
- `, e.forEach((i) => {
1021
+ return e += `- [Overview](#overview)
1022
+ `, e += `- [Extension Points](#extension-points)
1023
+ `, t.forEach((i) => {
1024
1024
  const s = i.id.toLowerCase().replace(/\./g, "");
1025
- t += ` - [${i.id}](#${s}) (${i.pluginCount} plugins)
1025
+ e += ` - [${i.id}](#${s}) (${i.pluginCount} plugins)
1026
1026
  `;
1027
- }), t += `- [Type Definitions](#type-definitions)
1028
- `, t += `- [Contribution Guide](#contribution-guide)
1029
- `, t += `- [Troubleshooting](#troubleshooting)
1027
+ }), e += `- [Type Definitions](#type-definitions)
1028
+ `, e += `- [Contribution Guide](#contribution-guide)
1029
+ `, e += `- [Troubleshooting](#troubleshooting)
1030
1030
 
1031
- `, t;
1031
+ `, e;
1032
1032
  }
1033
1033
  /**
1034
1034
  * Generate overview section with health statistics
1035
1035
  */
1036
- static generateOverviewSection(e, t) {
1036
+ static generateOverviewSection(t, e) {
1037
1037
  let i = `## Overview
1038
1038
 
1039
1039
  `;
@@ -1041,11 +1041,11 @@ class Ae {
1041
1041
 
1042
1042
  `, i += `### Extension Point Types
1043
1043
 
1044
- `, i += "- **✨ Simplified Extension Points**: Use the new simplified API from `defineExtensionPoint`\n", i += `- **📚 Legacy Extension Points**: Use the traditional reducer-based system
1044
+ `, i += "- ** Simplified Extension Points**: Use the new simplified API from `defineExtensionPoint`\n", i += `- ** Legacy Extension Points**: Use the traditional reducer-based system
1045
1045
 
1046
- `, t.deprecatedExtensionPoints > 0 && (i += `### ⚠️ Deprecated Extension Points
1046
+ `, e.deprecatedExtensionPoints > 0 && (i += `### ⚠️ Deprecated Extension Points
1047
1047
 
1048
- `, i += `${t.deprecatedExtensionPoints} extension points are marked as deprecated. `, i += `Consider migrating to newer alternatives.
1048
+ `, i += `${e.deprecatedExtensionPoints} extension points are marked as deprecated. `, i += `Consider migrating to newer alternatives.
1049
1049
 
1050
1050
  `), i + `---
1051
1051
 
@@ -1054,24 +1054,24 @@ class Ae {
1054
1054
  /**
1055
1055
  * Generate documentation section for a single extension point
1056
1056
  */
1057
- static generateExtensionPointSection(e, t) {
1057
+ static generateExtensionPointSection(t, e) {
1058
1058
  var a;
1059
- const { includeUsageExamples: i = !0, includePluginHealth: s = !0 } = t;
1060
- let o = `## ${e.source === "simplified" ? "✨" : "📚"} ${e.id}
1059
+ const { includeUsageExamples: i = !0, includePluginHealth: s = !0 } = e;
1060
+ let o = `## ${t.id}
1061
1061
 
1062
1062
  `;
1063
- if (e.displayName && (o += `**Display Name**: ${e.displayName}
1063
+ if (t.displayName && (o += `**Display Name**: ${t.displayName}
1064
1064
 
1065
- `), e.description && (o += `**Description**: ${e.description}
1065
+ `), t.description && (o += `**Description**: ${t.description}
1066
1066
 
1067
- `), o += `**Source**: ${e.source}
1068
- `, o += `**Active Plugins**: ${e.pluginCount}
1067
+ `), o += `**Source**: ${t.source}
1068
+ `, o += `**Active Plugins**: ${t.pluginCount}
1069
1069
 
1070
- `, e.metadata) {
1070
+ `, t.metadata) {
1071
1071
  o += `### Metadata
1072
1072
 
1073
1073
  `;
1074
- const r = e.metadata;
1074
+ const r = t.metadata;
1075
1075
  r.category && (o += `- **Category**: ${r.category}
1076
1076
  `), r.owner && (o += `- **Owner**: ${r.owner}
1077
1077
  `), r.since && (o += `- **Since**: ${r.since}
@@ -1080,110 +1080,110 @@ class Ae {
1080
1080
  `), o += `
1081
1081
  `;
1082
1082
  }
1083
- return i && (o += this.generateUsageExamples(e)), e.plugins.length > 0 ? o += this.generatePluginList(
1084
- e.plugins,
1083
+ return i && (o += this.generateUsageExamples(t)), t.plugins.length > 0 ? o += this.generatePluginList(
1084
+ t.plugins,
1085
1085
  s
1086
1086
  ) : o += `### Plugins
1087
1087
 
1088
1088
  No plugins currently registered for this extension point.
1089
1089
 
1090
- `, o += this.generateSchemaFieldsSection(e), o += this.generateContributionStructure(e), o + `---
1090
+ `, o += this.generateSchemaFieldsSection(t), o += this.generateContributionStructure(t), o + `---
1091
1091
 
1092
1092
  `;
1093
1093
  }
1094
1094
  /**
1095
1095
  * Generate usage examples for an extension point
1096
1096
  */
1097
- static generateUsageExamples(e) {
1098
- let t = `### Usage Examples
1097
+ static generateUsageExamples(t) {
1098
+ let e = `### Usage Examples
1099
1099
 
1100
1100
  `;
1101
- return e.source === "simplified" && (t += `#### Using Simplified API
1101
+ return t.source === "simplified" && (e += `#### Using Simplified API
1102
1102
 
1103
- `, t += "```typescript\n", t += `// Import the extension point
1104
- `, t += `import { ${this.getExtensionPointImportName(
1105
- e.id
1103
+ `, e += "```typescript\n", e += `// Import the extension point
1104
+ `, e += `import { ${this.getExtensionPointImportName(
1105
+ t.id
1106
1106
  )} } from './extension-points';
1107
1107
 
1108
- `, t += `// Use extension component hook
1109
- `, t += `import { useExtensionComponent } from '@kosdev-code/kos-ui-plugin';
1108
+ `, e += `// Use extension component hook
1109
+ `, e += `import { useExtensionComponent } from '@kosdev-code/kos-ui-plugin';
1110
1110
 
1111
- `, t += `const Component = useExtensionComponent(${this.getExtensionPointImportName(
1112
- e.id
1111
+ `, e += `const Component = useExtensionComponent(${this.getExtensionPointImportName(
1112
+ t.id
1113
1113
  )});
1114
1114
 
1115
- `, t += `if (Component) {
1116
- `, t += ` return (
1117
- `, t += ` <Component
1118
- `, t += ` customProp="value"
1119
- `, t += ` onComplete={handleComplete}
1120
- `, t += ` />
1121
- `, t += ` );
1122
- `, t += `}
1123
-
1124
- `, t += `// Or use with dynamic component
1125
- `, t += `const [Component] = useDynamicComponent({
1126
- `, t += ` extension: ${this.getExtensionPointImportName(
1127
- e.id
1115
+ `, e += `if (Component) {
1116
+ `, e += ` return (
1117
+ `, e += ` <Component
1118
+ `, e += ` customProp="value"
1119
+ `, e += ` onComplete={handleComplete}
1120
+ `, e += ` />
1121
+ `, e += ` );
1122
+ `, e += `}
1123
+
1124
+ `, e += `// Or use with dynamic component
1125
+ `, e += `const [Component] = useDynamicComponent({
1126
+ `, e += ` extension: ${this.getExtensionPointImportName(
1127
+ t.id
1128
1128
  )}.id
1129
- `, t += `});
1130
- `, t += "```\n\n", t += `#### Using Typed Hooks
1129
+ `, e += `});
1130
+ `, e += "```\n\n", e += `#### Using Typed Hooks
1131
1131
 
1132
- `, t += "```typescript\n", t += `// Get all extensions with type safety
1133
- `, t += `const extensions = useExtensions(${this.getExtensionPointImportName(
1134
- e.id
1132
+ `, e += "```typescript\n", e += `// Get all extensions with type safety
1133
+ `, e += `const extensions = useExtensions(${this.getExtensionPointImportName(
1134
+ t.id
1135
1135
  )});
1136
1136
 
1137
- `, t += `// Get best extension
1138
- `, t += `const bestExtension = useBest(${this.getExtensionPointImportName(
1139
- e.id
1137
+ `, e += `// Get best extension
1138
+ `, e += `const bestExtension = useBest(${this.getExtensionPointImportName(
1139
+ t.id
1140
1140
  )});
1141
1141
 
1142
- `, t += `// Check availability
1143
- `, t += `const hasExtensions = useHasExtensions(${this.getExtensionPointImportName(
1144
- e.id
1142
+ `, e += `// Check availability
1143
+ `, e += `const hasExtensions = useHasExtensions(${this.getExtensionPointImportName(
1144
+ t.id
1145
1145
  )});
1146
- `, t += "```\n\n"), t += `#### Using DynamicComponent
1146
+ `, e += "```\n\n"), e += `#### Using DynamicComponent
1147
1147
 
1148
- `, t += "```typescript\n", t += `import { DynamicComponent } from '@kosdev-code/kos-ui-plugin';
1149
- `, t += `import { ${this.getExtensionPointImportName(
1150
- e.id
1148
+ `, e += "```typescript\n", e += `import { DynamicComponent } from '@kosdev-code/kos-ui-plugin';
1149
+ `, e += `import { ${this.getExtensionPointImportName(
1150
+ t.id
1151
1151
  )} } from './extension-points';
1152
1152
 
1153
- `, t += `<DynamicComponent
1154
- `, t += ` extension={${this.getExtensionPointImportName(
1155
- e.id
1153
+ `, e += `<DynamicComponent
1154
+ `, e += ` extension={${this.getExtensionPointImportName(
1155
+ t.id
1156
1156
  )}.id}
1157
- `, t += ` props={{ customData: "value" }}
1158
- `, t += ` fallback={<div>Loading...</div>}
1159
- `, t += `/>
1160
- `, t += "```\n\n", t += `#### Using Context
1161
-
1162
- `, t += "```typescript\n", t += `import { useKosPluginsContext } from '@kosdev-code/kos-ui-plugin';
1163
- `, t += `import { ${this.getExtensionPointImportName(
1164
- e.id
1157
+ `, e += ` props={{ customData: "value" }}
1158
+ `, e += ` fallback={<div>Loading...</div>}
1159
+ `, e += `/>
1160
+ `, e += "```\n\n", e += `#### Using Context
1161
+
1162
+ `, e += "```typescript\n", e += `import { useKosPluginsContext } from '@kosdev-code/kos-ui-plugin';
1163
+ `, e += `import { ${this.getExtensionPointImportName(
1164
+ t.id
1165
1165
  )} } from './extension-points';
1166
1166
 
1167
- `, t += `const { getExtensions } = useKosPluginsContext();
1168
- `, t += `const extensions = getExtensions(${this.getExtensionPointImportName(
1169
- e.id
1167
+ `, e += `const { getExtensions } = useKosPluginsContext();
1168
+ `, e += `const extensions = getExtensions(${this.getExtensionPointImportName(
1169
+ t.id
1170
1170
  )}.id);
1171
- `, t += "```\n\n", t;
1171
+ `, e += "```\n\n", e;
1172
1172
  }
1173
1173
  /**
1174
1174
  * Generate plugin list with health information
1175
1175
  */
1176
- static generatePluginList(e, t) {
1176
+ static generatePluginList(t, e) {
1177
1177
  let i = `### Active Plugins
1178
1178
 
1179
1179
  `;
1180
- return e.forEach((s) => {
1180
+ return t.forEach((s) => {
1181
1181
  if (i += `#### ${s.id}
1182
1182
 
1183
1183
  `, s.remote && (i += `- **Remote**: ${s.remote}
1184
1184
  `), s.sectionId && (i += `- **Section**: ${s.sectionId}
1185
1185
  `), s.rank !== void 0 && (i += `- **Rank**: ${s.rank}
1186
- `), t) {
1186
+ `), e) {
1187
1187
  const o = I.analyzePlugin(s);
1188
1188
  i += `- **Health**: ${this.getHealthEmoji(o.healthStatus)} ${o.healthStatus}
1189
1189
  `, o.capabilities.length > 0 && (i += `- **Capabilities**: ${o.capabilities.join(", ")}
@@ -1196,10 +1196,10 @@ No plugins currently registered for this extension point.
1196
1196
  /**
1197
1197
  * Generate schema fields documentation
1198
1198
  */
1199
- static generateSchemaFieldsSection(e) {
1200
- if (e.source !== "simplified")
1199
+ static generateSchemaFieldsSection(t) {
1200
+ if (t.source !== "simplified")
1201
1201
  return "";
1202
- const i = y().getExtensionPoint(e.id);
1202
+ const i = y().getExtensionPoint(t.id);
1203
1203
  if (!(i != null && i.getSchemaFieldInfo))
1204
1204
  return "";
1205
1205
  const s = i.getSchemaFieldInfo();
@@ -1222,87 +1222,87 @@ No plugins currently registered for this extension point.
1222
1222
  /**
1223
1223
  * Generate contribution structure documentation
1224
1224
  */
1225
- static generateContributionStructure(e) {
1226
- let t = `### Contribution Structure
1225
+ static generateContributionStructure(t) {
1226
+ let e = `### Contribution Structure
1227
1227
 
1228
1228
  `;
1229
- t += `To contribute to this extension point, add the following to your plugin descriptor:
1229
+ e += `To contribute to this extension point, add the following to your plugin descriptor:
1230
1230
 
1231
- `, t += "```json\n", t += `{
1232
- `, t += ` "id": "your-plugin-id",
1233
- `, t += ` "contributes": {
1231
+ `, e += "```json\n", e += `{
1232
+ `, e += ` "id": "your-plugin-id",
1233
+ `, e += ` "contributes": {
1234
1234
  `;
1235
- const i = this.inferContributionKey(e);
1236
- t += ` "${i}": [
1237
- `, t += ` {
1235
+ const i = this.inferContributionKey(t);
1236
+ e += ` "${i}": [
1237
+ `, e += ` {
1238
1238
  `;
1239
- const s = this.getSchemaFieldsForContribution(e);
1239
+ const s = this.getSchemaFieldsForContribution(t);
1240
1240
  if (s.length > 0) {
1241
1241
  const a = [];
1242
1242
  s.forEach((r) => {
1243
1243
  let c;
1244
1244
  r.name === "id" ? c = '"your-contribution-id"' : r.name === "title" ? c = '"Your Contribution Title"' : r.name === "namespace" ? c = '"your-namespace"' : r.name === "experienceId" ? c = '"your-experience-id"' : r.name === "dashboardKey" ? c = '"your-dashboard-key"' : r.name === "rank" ? c = "10" : r.type === "string" ? c = `"your-${r.name}"` : r.type === "number" ? c = "0" : r.type === "boolean" ? c = "false" : c = `"your-${r.name}"`, (r.required || ["experienceId", "rank", "dashboardKey"].includes(r.name)) && a.push(` "${r.name}": ${c}`);
1245
- }), t += a.join(`,
1245
+ }), e += a.join(`,
1246
1246
  `);
1247
1247
  } else {
1248
- t += ` "id": "your-contribution-id",
1249
- `, t += ` "title": "Your Contribution Title",
1250
- `, t += ' "namespace": "your-namespace"', this.isViewBasedExtensionPoint(e) && (t += `,
1251
- "experienceId": "your-experience-id"`), this.isRankableExtensionPoint(e) && (t += `,
1248
+ e += ` "id": "your-contribution-id",
1249
+ `, e += ` "title": "Your Contribution Title",
1250
+ `, e += ' "namespace": "your-namespace"', this.isViewBasedExtensionPoint(t) && (e += `,
1251
+ "experienceId": "your-experience-id"`), this.isRankableExtensionPoint(t) && (e += `,
1252
1252
  "rank": 10`);
1253
- const a = this.getSpecificFields(e);
1254
- a.length > 0 && (t += `,
1253
+ const a = this.getSpecificFields(t);
1254
+ a.length > 0 && (e += `,
1255
1255
  ${a.join(`,
1256
1256
  `)}`);
1257
1257
  }
1258
- return t += `
1258
+ return e += `
1259
1259
  }
1260
- `, t += " ]", (s.some((a) => a.name === "experienceId") || this.isViewBasedExtensionPoint(e)) && (t += `,
1260
+ `, e += " ]", (s.some((a) => a.name === "experienceId") || this.isViewBasedExtensionPoint(t)) && (e += `,
1261
1261
  "experiences": {
1262
- `, t += ` "your-experience-id": {
1263
- `, t += ` "id": "your-experience-id",
1264
- `, t += ` "component": "YourComponent",
1265
- `, t += ` "location": "./src/components/YourComponent.tsx"
1266
- `, t += ` }
1267
- `, t += " }"), t += `
1262
+ `, e += ` "your-experience-id": {
1263
+ `, e += ` "id": "your-experience-id",
1264
+ `, e += ` "component": "YourComponent",
1265
+ `, e += ` "location": "./src/components/YourComponent.tsx"
1266
+ `, e += ` }
1267
+ `, e += " }"), e += `
1268
1268
  }
1269
- `, t += `}
1270
- `, t += "```\n\n", t;
1269
+ `, e += `}
1270
+ `, e += "```\n\n", e;
1271
1271
  }
1272
1272
  /**
1273
1273
  * Generate TypeScript definitions section
1274
1274
  */
1275
- static generateTypeDefinitionsSection(e) {
1276
- let t = `## Type Definitions
1275
+ static generateTypeDefinitionsSection(t) {
1276
+ let e = `## Type Definitions
1277
1277
 
1278
1278
  `;
1279
- return t += `### Extension Point Types
1279
+ return e += `### Extension Point Types
1280
1280
 
1281
- `, t += "```typescript\n", e.forEach((i) => {
1282
- i.source === "simplified" && (t += `// ${i.id}
1283
- `, t += `interface ${this.getExtensionPointTypeName(i.id)} {
1284
- `, t += ` id: "${i.id}";
1285
- `, t += ` displayName?: "${i.displayName || ""}";
1286
- `, t += ` description?: "${i.description || ""}";
1287
- `, t += `}
1281
+ `, e += "```typescript\n", t.forEach((i) => {
1282
+ i.source === "simplified" && (e += `// ${i.id}
1283
+ `, e += `interface ${this.getExtensionPointTypeName(i.id)} {
1284
+ `, e += ` id: "${i.id}";
1285
+ `, e += ` displayName?: "${i.displayName || ""}";
1286
+ `, e += ` description?: "${i.description || ""}";
1287
+ `, e += `}
1288
1288
 
1289
1289
  `);
1290
- }), t += "```\n\n", t += `### Plugin Contribution Types
1291
-
1292
- `, t += "```typescript\n", t += `interface BaseContribution {
1293
- `, t += ` id: string;
1294
- `, t += ` title: string;
1295
- `, t += ` namespace: string;
1296
- `, t += `}
1297
-
1298
- `, t += `interface ViewBasedContribution extends BaseContribution {
1299
- `, t += ` experienceId: string;
1300
- `, t += `}
1301
-
1302
- `, t += `interface RankableContribution extends BaseContribution {
1303
- `, t += ` rank: number;
1304
- `, t += `}
1305
- `, t += "```\n\n", t;
1290
+ }), e += "```\n\n", e += `### Plugin Contribution Types
1291
+
1292
+ `, e += "```typescript\n", e += `interface BaseContribution {
1293
+ `, e += ` id: string;
1294
+ `, e += ` title: string;
1295
+ `, e += ` namespace: string;
1296
+ `, e += `}
1297
+
1298
+ `, e += `interface ViewBasedContribution extends BaseContribution {
1299
+ `, e += ` experienceId: string;
1300
+ `, e += `}
1301
+
1302
+ `, e += `interface RankableContribution extends BaseContribution {
1303
+ `, e += ` rank: number;
1304
+ `, e += `}
1305
+ `, e += "```\n\n", e;
1306
1306
  }
1307
1307
  /**
1308
1308
  * Generate contribution guide
@@ -1397,12 +1397,12 @@ console.log(validation.warnings); // Check for warnings
1397
1397
  `;
1398
1398
  }
1399
1399
  // Helper methods
1400
- static getExtensionPointImportName(e) {
1400
+ static getExtensionPointImportName(t) {
1401
1401
  var a;
1402
- const i = y().getExtensionPoint(e);
1402
+ const i = y().getExtensionPoint(t);
1403
1403
  if ((a = i == null ? void 0 : i.config.metadata) != null && a.exportName)
1404
1404
  return i.config.metadata.exportName;
1405
- const s = e.split(".");
1405
+ const s = t.split(".");
1406
1406
  return (s.length > 1 ? s.slice(1) : s).map(
1407
1407
  (r) => (
1408
1408
  // Handle hyphenated parts (e.g., "pump-detail" -> "PumpDetail")
@@ -1410,11 +1410,11 @@ console.log(validation.warnings); // Check for warnings
1410
1410
  )
1411
1411
  ).join("") + "Extension";
1412
1412
  }
1413
- static getExtensionPointTypeName(e) {
1414
- return this.getExtensionPointImportName(e) + "Type";
1413
+ static getExtensionPointTypeName(t) {
1414
+ return this.getExtensionPointImportName(t) + "Type";
1415
1415
  }
1416
- static getHealthEmoji(e) {
1417
- switch (e) {
1416
+ static getHealthEmoji(t) {
1417
+ switch (t) {
1418
1418
  case "healthy":
1419
1419
  return "✅";
1420
1420
  case "warning":
@@ -1425,13 +1425,13 @@ console.log(validation.warnings); // Check for warnings
1425
1425
  return "❓";
1426
1426
  }
1427
1427
  }
1428
- static inferContributionKey(e) {
1429
- if (e.source === "simplified") {
1430
- const a = y().getExtensionPoint(e.id);
1428
+ static inferContributionKey(t) {
1429
+ if (t.source === "simplified") {
1430
+ const a = y().getExtensionPoint(t.id);
1431
1431
  if (a != null && a.config.contributionKey)
1432
1432
  return a.config.contributionKey;
1433
1433
  }
1434
- const t = e.id.split("."), i = t[t.length - 1];
1434
+ const e = t.id.split("."), i = e[e.length - 1];
1435
1435
  return {
1436
1436
  cui: "cui",
1437
1437
  utility: "utilities",
@@ -1443,56 +1443,56 @@ console.log(validation.warnings); // Check for warnings
1443
1443
  controlPour: "controlPour"
1444
1444
  }[i] || i + "s";
1445
1445
  }
1446
- static isViewBasedExtensionPoint(e) {
1447
- if (e.source === "simplified") {
1448
- const i = y().getExtensionPoint(e.id);
1446
+ static isViewBasedExtensionPoint(t) {
1447
+ if (t.source === "simplified") {
1448
+ const i = y().getExtensionPoint(t.id);
1449
1449
  return (i == null ? void 0 : i.config.hasView) || !1;
1450
1450
  }
1451
- return e.plugins.some(
1452
- (t) => t.experienceId
1451
+ return t.plugins.some(
1452
+ (e) => e.experienceId
1453
1453
  );
1454
1454
  }
1455
- static isRankableExtensionPoint(e) {
1456
- if (e.source === "simplified") {
1457
- const i = y().getExtensionPoint(e.id);
1455
+ static isRankableExtensionPoint(t) {
1456
+ if (t.source === "simplified") {
1457
+ const i = y().getExtensionPoint(t.id);
1458
1458
  return (i == null ? void 0 : i.config.isRankable) || !1;
1459
1459
  }
1460
- return e.plugins.some(
1461
- (t) => typeof t.rank == "number"
1460
+ return t.plugins.some(
1461
+ (e) => typeof e.rank == "number"
1462
1462
  );
1463
1463
  }
1464
1464
  /**
1465
1465
  * Get schema fields for contribution structure generation
1466
1466
  */
1467
- static getSchemaFieldsForContribution(e) {
1468
- if (e.source !== "simplified")
1467
+ static getSchemaFieldsForContribution(t) {
1468
+ if (t.source !== "simplified")
1469
1469
  return [];
1470
- const i = y().getExtensionPoint(e.id);
1470
+ const i = y().getExtensionPoint(t.id);
1471
1471
  return i != null && i.getSchemaFieldInfo ? i.getSchemaFieldInfo() : [];
1472
1472
  }
1473
- static getSpecificFields(e) {
1474
- const t = [];
1475
- switch (this.inferContributionKey(e)) {
1473
+ static getSpecificFields(t) {
1474
+ const e = [];
1475
+ switch (this.inferContributionKey(t)) {
1476
1476
  case "utilities":
1477
- t.push('"utilDescriptor": "your-util-descriptor"');
1477
+ e.push('"utilDescriptor": "your-util-descriptor"');
1478
1478
  break;
1479
1479
  case "setupStep":
1480
- t.push('"setupDescriptor": "your-setup-descriptor"');
1480
+ e.push('"setupDescriptor": "your-setup-descriptor"');
1481
1481
  break;
1482
1482
  case "settings":
1483
- t.push('"settingsGroup": "your-settings-group"');
1483
+ e.push('"settingsGroup": "your-settings-group"');
1484
1484
  break;
1485
1485
  case "navViews":
1486
- t.push('"navDescriptor": "your-nav-descriptor"');
1486
+ e.push('"navDescriptor": "your-nav-descriptor"');
1487
1487
  break;
1488
1488
  case "troubleActions":
1489
- t.push('"troubleType": "your-trouble-type"');
1489
+ e.push('"troubleType": "your-trouble-type"');
1490
1490
  break;
1491
1491
  case "cui":
1492
- t.push('"cuiDescriptor": "your-cui-descriptor"');
1492
+ e.push('"cuiDescriptor": "your-cui-descriptor"');
1493
1493
  break;
1494
1494
  }
1495
- return t;
1495
+ return e;
1496
1496
  }
1497
1497
  }
1498
1498
  export {
@@ -1520,4 +1520,4 @@ export {
1520
1520
  _e as r,
1521
1521
  Te as v
1522
1522
  };
1523
- //# sourceMappingURL=documentation-generator-BVDETA08.js.map
1523
+ //# sourceMappingURL=documentation-generator-C0BDW8NY.js.map