@ea-lab/reactive-json 0.0.11 → 0.0.13
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.
package/dist/reactive-json.js
CHANGED
|
@@ -21208,7 +21208,7 @@ const sx = (n, ...l) => l.length ? sx(n = n.replace(sx.token || "$token", l.shif
|
|
|
21208
21208
|
return /* @__PURE__ */ te.jsx(tl, { ...n, children: n != null && n.paginated ? /* @__PURE__ */ te.jsx(bD.Provider, { value: { pagination: z }, children: L }) : L });
|
|
21209
21209
|
};
|
|
21210
21210
|
function ka({ props: n, currentData: l, datafield: u, path: f }) {
|
|
21211
|
-
const p = nt(La), v = nt(Aa), g = {
|
|
21211
|
+
const p = nt(La), v = nt(Aa), g = p.plugins ?? {}, A = {
|
|
21212
21212
|
AccordionItem: bB,
|
|
21213
21213
|
CheckBoxField: sB,
|
|
21214
21214
|
Count: s7,
|
|
@@ -21230,37 +21230,38 @@ function ka({ props: n, currentData: l, datafield: u, path: f }) {
|
|
|
21230
21230
|
Switch: g7,
|
|
21231
21231
|
Tabs: l7,
|
|
21232
21232
|
TextAreaField: gB,
|
|
21233
|
-
TextField: yB
|
|
21234
|
-
|
|
21233
|
+
TextField: yB,
|
|
21234
|
+
...g == null ? void 0 : g.element
|
|
21235
|
+
}, S = {
|
|
21235
21236
|
BsAccordion: tS,
|
|
21236
21237
|
BsAlert: S4,
|
|
21237
21238
|
BsBadge: XO,
|
|
21238
21239
|
BsButton: $O
|
|
21239
|
-
}, { element:
|
|
21240
|
+
}, { element: x } = p;
|
|
21240
21241
|
if (l === void 0 && (l = ""), n != null && n.type) {
|
|
21241
|
-
let
|
|
21242
|
-
const
|
|
21243
|
-
{ registryId: "module", components:
|
|
21244
|
-
{ registryId: "bootstrap", components:
|
|
21242
|
+
let C, w;
|
|
21243
|
+
const M = [
|
|
21244
|
+
{ registryId: "module", components: A },
|
|
21245
|
+
{ registryId: "bootstrap", components: S }
|
|
21245
21246
|
];
|
|
21246
|
-
for (;
|
|
21247
|
-
const { registryId:
|
|
21248
|
-
if (
|
|
21249
|
-
|
|
21247
|
+
for (; M.length; ) {
|
|
21248
|
+
const { registryId: z, components: B } = M.shift();
|
|
21249
|
+
if (w = B[n.type] ?? void 0, w !== void 0) {
|
|
21250
|
+
C = z;
|
|
21250
21251
|
break;
|
|
21251
21252
|
}
|
|
21252
21253
|
}
|
|
21253
|
-
return
|
|
21254
|
+
return w === void 0 && (w = TA, C = "module"), C === "bootstrap" ? /* @__PURE__ */ te.jsx(
|
|
21254
21255
|
u7,
|
|
21255
21256
|
{
|
|
21256
|
-
bsComponent:
|
|
21257
|
+
bsComponent: w,
|
|
21257
21258
|
path: f,
|
|
21258
21259
|
props: n,
|
|
21259
21260
|
currentData: l,
|
|
21260
21261
|
datafield: u
|
|
21261
21262
|
}
|
|
21262
|
-
) : (TA ===
|
|
21263
|
-
|
|
21263
|
+
) : (TA === w && (n.tag = n.tag ?? n.type), /* @__PURE__ */ te.jsx(
|
|
21264
|
+
w,
|
|
21264
21265
|
{
|
|
21265
21266
|
path: f,
|
|
21266
21267
|
props: n,
|
|
@@ -21270,55 +21271,55 @@ function ka({ props: n, currentData: l, datafield: u, path: f }) {
|
|
|
21270
21271
|
));
|
|
21271
21272
|
}
|
|
21272
21273
|
if (n != null && n.load) {
|
|
21273
|
-
let
|
|
21274
|
-
const
|
|
21275
|
-
if (
|
|
21276
|
-
const
|
|
21274
|
+
let C;
|
|
21275
|
+
const w = (n == null ? void 0 : n.customDataLocation) ?? void 0;
|
|
21276
|
+
if (w) debugger;
|
|
21277
|
+
const M = w ? Ea({
|
|
21277
21278
|
globalDataContext: p,
|
|
21278
21279
|
templateContext: v,
|
|
21279
|
-
valueToEvaluate:
|
|
21280
|
-
}) : l,
|
|
21281
|
-
typeof n.load == "function" ?
|
|
21282
|
-
const { load:
|
|
21283
|
-
return
|
|
21280
|
+
valueToEvaluate: w
|
|
21281
|
+
}) : l, z = w ? Zc({ dataLocation: w, currentPath: f, globalDataContext: p, templateContext: v }) : f;
|
|
21282
|
+
typeof n.load == "function" ? C = n.load(M) : C = x[n.load];
|
|
21283
|
+
const { load: B, customDataLocation: L, ...O } = n;
|
|
21284
|
+
return C = { ...C, ...O }, n.keepTemplateContext ? /* @__PURE__ */ te.jsx(
|
|
21284
21285
|
ka,
|
|
21285
21286
|
{
|
|
21286
|
-
currentData:
|
|
21287
|
+
currentData: M,
|
|
21287
21288
|
datafield: u,
|
|
21288
|
-
path:
|
|
21289
|
-
props:
|
|
21289
|
+
path: z,
|
|
21290
|
+
props: C
|
|
21290
21291
|
}
|
|
21291
|
-
) : /* @__PURE__ */ te.jsx(Aa.Provider, { value: { templateData:
|
|
21292
|
+
) : /* @__PURE__ */ te.jsx(Aa.Provider, { value: { templateData: M, templatePath: z }, children: /* @__PURE__ */ te.jsx(
|
|
21292
21293
|
ka,
|
|
21293
21294
|
{
|
|
21294
|
-
currentData:
|
|
21295
|
+
currentData: M,
|
|
21295
21296
|
datafield: u,
|
|
21296
|
-
path:
|
|
21297
|
-
props:
|
|
21297
|
+
path: z,
|
|
21298
|
+
props: C
|
|
21298
21299
|
}
|
|
21299
21300
|
) });
|
|
21300
21301
|
}
|
|
21301
21302
|
return Array.isArray(n) ? n.map(
|
|
21302
|
-
(
|
|
21303
|
+
(C, w) => /* @__PURE__ */ te.jsx(
|
|
21303
21304
|
ka,
|
|
21304
21305
|
{
|
|
21305
|
-
currentData: l[
|
|
21306
|
-
datafield:
|
|
21307
|
-
path: f + "." +
|
|
21308
|
-
props:
|
|
21306
|
+
currentData: l[w] ?? void 0,
|
|
21307
|
+
datafield: w,
|
|
21308
|
+
path: f + "." + w,
|
|
21309
|
+
props: C ?? void 0
|
|
21309
21310
|
},
|
|
21310
|
-
f + "." +
|
|
21311
|
+
f + "." + w
|
|
21311
21312
|
)
|
|
21312
21313
|
) : typeof n == "object" ? Object.entries(n).map(
|
|
21313
|
-
([
|
|
21314
|
+
([C, w]) => /* @__PURE__ */ te.jsx(
|
|
21314
21315
|
ka,
|
|
21315
21316
|
{
|
|
21316
|
-
currentData: l[
|
|
21317
|
-
datafield:
|
|
21318
|
-
path: f + "." +
|
|
21319
|
-
props:
|
|
21317
|
+
currentData: l[C] ?? void 0,
|
|
21318
|
+
datafield: C ?? void 0,
|
|
21319
|
+
path: f + "." + C,
|
|
21320
|
+
props: w
|
|
21320
21321
|
},
|
|
21321
|
-
f + "." +
|
|
21322
|
+
f + "." + C
|
|
21322
21323
|
)
|
|
21323
21324
|
) : /* @__PURE__ */ te.jsx(cB, { valueToEvaluate: l || (n ?? null) });
|
|
21324
21325
|
}
|
|
@@ -22447,6 +22448,7 @@ function lz({
|
|
|
22447
22448
|
value: {
|
|
22448
22449
|
element: M,
|
|
22449
22450
|
headersForData: u,
|
|
22451
|
+
plugins: f,
|
|
22450
22452
|
setRawAppData: I,
|
|
22451
22453
|
templateData: S.realCurrentData,
|
|
22452
22454
|
templatePath: "data",
|
|
@@ -47689,3 +47691,4 @@ export {
|
|
|
47689
47691
|
lz as ReactiveJsonRoot,
|
|
47690
47692
|
Lz as mergeComponentCollections
|
|
47691
47693
|
};
|
|
47694
|
+
//# sourceMappingURL=reactive-json.js.map
|