@nebularstreams/libmui 2.5.99 → 2.5.101
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
|
@@ -29,7 +29,9 @@ const
|
|
|
29
29
|
NEEDS_UPDATE = "needsUpdate",
|
|
30
30
|
REBUILD_CHILDREN = "_rebuild_children",
|
|
31
31
|
NEEDS_DELETE = "delete",
|
|
32
|
-
|
|
32
|
+
KeyWrapper = defineWidget(
|
|
33
|
+
({children}) => [children]
|
|
34
|
+
),
|
|
33
35
|
ToggleWidget = defineWidget(
|
|
34
36
|
({attrs}) => m(ButtonNew, {
|
|
35
37
|
text: attrs.text,
|
|
@@ -553,21 +555,25 @@ const
|
|
|
553
555
|
})]
|
|
554
556
|
: isJson
|
|
555
557
|
? [
|
|
556
|
-
m(
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
if (
|
|
566
|
-
|
|
558
|
+
m(KeyWrapper, [
|
|
559
|
+
m(attrs.CodeMirror, {
|
|
560
|
+
key: parameters.id,
|
|
561
|
+
doc: rawValue,
|
|
562
|
+
schema: metaDef.schema,
|
|
563
|
+
templates: metaDef.templates,
|
|
564
|
+
hint: metaDef.dynamicHint ? metaDef.dynamicHint(targetParameters) : metaDef.hint,
|
|
565
|
+
empty: metaDef.empty,
|
|
566
|
+
onSave: (content) => {
|
|
567
|
+
if (content !== null) {
|
|
568
|
+
set(content || "");
|
|
569
|
+
onchange(UPDATECODE, targetParameters, metaKey, undefined, metaDef);
|
|
570
|
+
if (!content) {
|
|
571
|
+
Notification.add(metaDef.hint + " cleared");
|
|
572
|
+
}
|
|
567
573
|
}
|
|
568
574
|
}
|
|
569
|
-
}
|
|
570
|
-
|
|
575
|
+
})
|
|
576
|
+
])
|
|
571
577
|
]
|
|
572
578
|
: isNumber
|
|
573
579
|
? [
|