@nebularstreams/libmui 2.5.120 → 2.5.122
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/package.json
CHANGED
|
@@ -410,14 +410,9 @@ const
|
|
|
410
410
|
},
|
|
411
411
|
isCardieArray
|
|
412
412
|
? Array.isArray(rawValue)
|
|
413
|
-
? rawValue.map(
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
cardid: metaDef.cardid + "-" + index,
|
|
417
|
-
nofold: false,
|
|
418
|
-
size: metaDef.margin || 0,
|
|
419
|
-
expandedView: () => [
|
|
420
|
-
m(ParameterTable, {
|
|
413
|
+
? rawValue.map(
|
|
414
|
+
(item, index) => metaDef.small
|
|
415
|
+
? m(ParameterTable, {
|
|
421
416
|
meta: metaDef.items,
|
|
422
417
|
crit: {},
|
|
423
418
|
when: {},
|
|
@@ -426,6 +421,8 @@ const
|
|
|
426
421
|
parameters: item,
|
|
427
422
|
auxParameters,
|
|
428
423
|
|
|
424
|
+
arrayInfo: {source: rawValue, index},
|
|
425
|
+
|
|
429
426
|
global,
|
|
430
427
|
clone,
|
|
431
428
|
onchange,
|
|
@@ -441,22 +438,56 @@ const
|
|
|
441
438
|
AssetButton: attrs.AssetButton,
|
|
442
439
|
CodeMirror: attrs.CodeMirror
|
|
443
440
|
})
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
441
|
+
: m(CardieWidget, {
|
|
442
|
+
class: "relative grows " + (metaDef.class || "pad-h emby w-max") + (metaDef.dynClass ? " " + metaDef.dynClass(parameters, auxParameters, index) : ""),
|
|
443
|
+
title: metaDef.dynTitle ? metaDef.dynTitle(parameters, auxParameters, index) : metaDef.title + " " + (index + 1),
|
|
444
|
+
cardid: metaDef.cardid + "-" + index,
|
|
445
|
+
nofold: false,
|
|
446
|
+
size: metaDef.margin || 0,
|
|
447
|
+
expandedView: () => [
|
|
448
|
+
m(ParameterTable, {
|
|
449
|
+
meta: metaDef.items,
|
|
450
|
+
crit: {},
|
|
451
|
+
when: {},
|
|
452
|
+
sizes: {},
|
|
453
|
+
|
|
454
|
+
parameters: item,
|
|
455
|
+
auxParameters,
|
|
456
|
+
|
|
457
|
+
global,
|
|
458
|
+
clone,
|
|
459
|
+
onchange,
|
|
460
|
+
itemClass,
|
|
461
|
+
wrapper,
|
|
462
|
+
empty: vacioperovacio,
|
|
463
|
+
itemsDict: attrs.itemsDict,
|
|
464
|
+
layer: attrs.layer,
|
|
465
|
+
onAction: attrs.onAction,
|
|
466
|
+
optionsDict: attrs.optionsDict,
|
|
467
|
+
play: attrs.play,
|
|
468
|
+
auxTargetIsDefault: false,
|
|
469
|
+
AssetButton: attrs.AssetButton,
|
|
470
|
+
CodeMirror: attrs.CodeMirror
|
|
471
|
+
})
|
|
472
|
+
],
|
|
473
|
+
titleExpended: metaDef.titleExpanded || metaDef.hint,
|
|
474
|
+
titleCollapsed: metaDef.titleCollapsed || metaDef.hint,
|
|
475
|
+
})
|
|
476
|
+
)
|
|
477
|
+
.concat(
|
|
478
|
+
metaDef.addAction ? [
|
|
479
|
+
m(ButtonNew, {
|
|
480
|
+
...metaDef.addAction,
|
|
481
|
+
onClick: (e) => {
|
|
482
|
+
if (metaDef.addAction.onClick) {
|
|
483
|
+
metaDef.addAction.onClick(e, parameters, auxParameters);
|
|
484
|
+
} else if (metaDef.addAction.template) {
|
|
485
|
+
rawValue.push(cloneObject(metaDef.addAction.template));
|
|
486
|
+
}
|
|
487
|
+
m.redraw();
|
|
488
|
+
}
|
|
489
|
+
})
|
|
490
|
+
] : [])
|
|
460
491
|
: []
|
|
461
492
|
|
|
462
493
|
: isCardie
|
|
@@ -538,11 +569,11 @@ const
|
|
|
538
569
|
)
|
|
539
570
|
: metaDef.attrs,
|
|
540
571
|
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
572
|
+
metaDef.children
|
|
573
|
+
? metaDef.children(rawValue, state, (critical, rootParameters) => {
|
|
574
|
+
onchange(critical || UPDATECODE, rootParameters ? parameters : targetParameters, metaKey, undefined, metaDef);
|
|
575
|
+
}, global, attrs, targetParameters)
|
|
576
|
+
: [])
|
|
546
577
|
]
|
|
547
578
|
: isPlusMinus
|
|
548
579
|
? [
|
|
@@ -813,7 +844,7 @@ const
|
|
|
813
844
|
if (metaDef.onClick) {
|
|
814
845
|
metaDef.onClick(metaKey, e, targetParameters, auxParameters, global, attrs);
|
|
815
846
|
} else {
|
|
816
|
-
if (attrs.onAction) attrs.onAction(metaKey, e, targetSource);
|
|
847
|
+
if (attrs.onAction) attrs.onAction(metaKey, e, targetSource, attrs.arrayInfo);
|
|
817
848
|
}
|
|
818
849
|
};
|
|
819
850
|
|