jedison 1.12.0 → 1.12.2
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/CHANGELOG.md +8 -0
- package/dist/cjs/jedison.cjs +1 -1
- package/dist/cjs/jedison.cjs.map +1 -1
- package/dist/esm/jedison.js +115 -65
- package/dist/esm/jedison.js.map +1 -1
- package/dist/umd/jedison.umd.js +1 -1
- package/dist/umd/jedison.umd.js.map +1 -1
- package/package.json +1 -1
package/dist/esm/jedison.js
CHANGED
|
@@ -2817,7 +2817,12 @@ class InstanceMultiple extends Instance {
|
|
|
2817
2817
|
this.activeInstance.setValue(value, false, initiator);
|
|
2818
2818
|
}
|
|
2819
2819
|
this.activeInstance.children.forEach((child) => child.register());
|
|
2820
|
-
this.
|
|
2820
|
+
const newValue = this.activeInstance.getValueRaw();
|
|
2821
|
+
const valueWillChange = different(this.value, newValue);
|
|
2822
|
+
this.setValue(newValue, true, initiator);
|
|
2823
|
+
if (!valueWillChange) {
|
|
2824
|
+
this.emit("change", initiator);
|
|
2825
|
+
}
|
|
2821
2826
|
}
|
|
2822
2827
|
onSetValue() {
|
|
2823
2828
|
if (different(this.activeInstance.getValueRaw(), this.value)) {
|
|
@@ -3370,6 +3375,7 @@ class EditorRadios extends EditorBoolean {
|
|
|
3370
3375
|
titles: getSchemaXOption(this.instance.schema, "enumTitles") || ["false", "true"],
|
|
3371
3376
|
id: this.getIdFromPath(this.instance.path),
|
|
3372
3377
|
titleHidden: getSchemaXOption(this.instance.schema, "titleHidden"),
|
|
3378
|
+
titleIconClass: getSchemaXOption(this.instance.schema, "titleIconClass"),
|
|
3373
3379
|
inline: getSchemaXOption(this.instance.schema, "format") === "radios-inline",
|
|
3374
3380
|
info: this.getInfo()
|
|
3375
3381
|
});
|
|
@@ -3442,6 +3448,7 @@ class EditorBooleanCheckbox extends EditorBoolean {
|
|
|
3442
3448
|
description: this.getDescription(),
|
|
3443
3449
|
id: this.getIdFromPath(this.instance.path),
|
|
3444
3450
|
titleHidden: getSchemaXOption(this.instance.schema, "titleHidden"),
|
|
3451
|
+
titleIconClass: getSchemaXOption(this.instance.schema, "titleIconClass"),
|
|
3445
3452
|
info: this.getInfo()
|
|
3446
3453
|
});
|
|
3447
3454
|
}
|
|
@@ -4091,7 +4098,8 @@ class EditorObject extends Editor {
|
|
|
4091
4098
|
propertiesToggleContent: getSchemaXOption(this.instance.schema, "propertiesToggleContent") ?? this.instance.jedison.translator.translate("propertiesToggle"),
|
|
4092
4099
|
collapseToggleContent: getSchemaXOption(this.instance.schema, "collapseToggleContent") ?? this.instance.jedison.translator.translate("collapseToggle"),
|
|
4093
4100
|
addPropertyContent: getSchemaXOption(this.instance.schema, "addPropertyContent") ?? this.instance.jedison.translator.translate("objectAddProperty"),
|
|
4094
|
-
isAccordion: false
|
|
4101
|
+
isAccordion: false,
|
|
4102
|
+
titleIconClass: getSchemaXOption(this.instance.schema, "titleIconClass")
|
|
4095
4103
|
};
|
|
4096
4104
|
}
|
|
4097
4105
|
build() {
|
|
@@ -4595,7 +4603,8 @@ class EditorArray extends Editor {
|
|
|
4595
4603
|
arrayDeleteAllContent: getSchemaXOption(this.instance.schema, "arrayDeleteAllContent") ?? this.instance.jedison.translator.translate("arrayDeleteAll"),
|
|
4596
4604
|
arrayFooterDeleteAll: getSchemaXOption(this.instance.schema, "arrayFooterDeleteAll") ?? this.instance.jedison.getOption("arrayFooterDeleteAll"),
|
|
4597
4605
|
arrayFooterDeleteAllContent: getSchemaXOption(this.instance.schema, "arrayFooterDeleteAllContent") ?? this.instance.jedison.translator.translate("arrayDeleteAll"),
|
|
4598
|
-
collapseToggleContent: getSchemaXOption(this.instance.schema, "collapseToggleContent") ?? this.instance.jedison.translator.translate("collapseToggle")
|
|
4606
|
+
collapseToggleContent: getSchemaXOption(this.instance.schema, "collapseToggleContent") ?? this.instance.jedison.translator.translate("collapseToggle"),
|
|
4607
|
+
titleIconClass: getSchemaXOption(this.instance.schema, "titleIconClass")
|
|
4599
4608
|
});
|
|
4600
4609
|
this.control.jsonData.input.value = JSON.stringify(this.instance.getValue(), null, 2);
|
|
4601
4610
|
}
|
|
@@ -5517,6 +5526,7 @@ class EditorMultiple extends Editor {
|
|
|
5517
5526
|
}
|
|
5518
5527
|
}
|
|
5519
5528
|
refreshUI() {
|
|
5529
|
+
var _a;
|
|
5520
5530
|
this.refreshDisabledState();
|
|
5521
5531
|
this.control.childrenSlot.innerHTML = "";
|
|
5522
5532
|
this.control.childrenSlot.appendChild(this.instance.activeInstance.ui.control.container);
|
|
@@ -5533,9 +5543,15 @@ class EditorMultiple extends Editor {
|
|
|
5533
5543
|
}
|
|
5534
5544
|
if (this.switcherInput === "modal") {
|
|
5535
5545
|
const childControl = this.instance.activeInstance.ui.control;
|
|
5546
|
+
const infoContainer = childControl.infoContainer;
|
|
5536
5547
|
const titleEl = childControl.legendText || childControl.label;
|
|
5537
|
-
if (
|
|
5538
|
-
|
|
5548
|
+
if (infoContainer) {
|
|
5549
|
+
infoContainer.after(this.control.switcher.container);
|
|
5550
|
+
this.control.header.style.display = "none";
|
|
5551
|
+
} else if (titleEl) {
|
|
5552
|
+
const infoEl = (_a = childControl.info) == null ? void 0 : _a.container;
|
|
5553
|
+
const anchor = infoEl && infoEl.parentNode ? infoEl : titleEl;
|
|
5554
|
+
anchor.after(this.control.switcher.container);
|
|
5539
5555
|
this.control.header.style.display = "none";
|
|
5540
5556
|
}
|
|
5541
5557
|
}
|
|
@@ -7466,6 +7482,7 @@ class Theme {
|
|
|
7466
7482
|
const right = document.createElement("div");
|
|
7467
7483
|
const legend = document.createElement("legend");
|
|
7468
7484
|
const legendText = document.createElement("label");
|
|
7485
|
+
const icon = document.createElement("i");
|
|
7469
7486
|
const infoContainer = document.createElement("span");
|
|
7470
7487
|
const dummyInput = document.createElement("input");
|
|
7471
7488
|
const legendLabelId = "legend-label-" + config.id;
|
|
@@ -7481,6 +7498,11 @@ class Theme {
|
|
|
7481
7498
|
legendText.classList.add("jedi-legend");
|
|
7482
7499
|
legendText.setAttribute("id", legendLabelId);
|
|
7483
7500
|
legendText.innerHTML = config.content;
|
|
7501
|
+
if (config.titleIconClass) {
|
|
7502
|
+
this.addIconClass(icon, config.titleIconClass);
|
|
7503
|
+
icon.style.marginRight = "4px";
|
|
7504
|
+
}
|
|
7505
|
+
legendText.style.marginRight = "4px";
|
|
7484
7506
|
infoContainer.classList.add("jedi-editor-info-container");
|
|
7485
7507
|
infoContainer.setAttribute("for", dummyInputId);
|
|
7486
7508
|
dummyInput.setAttribute("aria-hidden", "true");
|
|
@@ -7492,6 +7514,9 @@ class Theme {
|
|
|
7492
7514
|
}
|
|
7493
7515
|
legend.appendChild(left);
|
|
7494
7516
|
legend.appendChild(right);
|
|
7517
|
+
if (config.titleIconClass) {
|
|
7518
|
+
left.appendChild(icon);
|
|
7519
|
+
}
|
|
7495
7520
|
left.appendChild(legendText);
|
|
7496
7521
|
left.appendChild(infoContainer);
|
|
7497
7522
|
legendText.appendChild(dummyInput);
|
|
@@ -7515,6 +7540,7 @@ class Theme {
|
|
|
7515
7540
|
const legendLabelId = "legend-label-" + config.id;
|
|
7516
7541
|
const legend = document.createElement("legend");
|
|
7517
7542
|
const legendText = document.createElement("label");
|
|
7543
|
+
const icon = document.createElement("i");
|
|
7518
7544
|
const dummyInput = document.createElement("input");
|
|
7519
7545
|
legend.classList.add("jedi-editor-legend");
|
|
7520
7546
|
legend.style.fontSize = "inherit";
|
|
@@ -7523,13 +7549,19 @@ class Theme {
|
|
|
7523
7549
|
legendText.classList.add("jedi-label");
|
|
7524
7550
|
legendText.innerHTML = config.content;
|
|
7525
7551
|
legendText.setAttribute("id", legendLabelId);
|
|
7552
|
+
legendText.style.marginRight = "4px";
|
|
7526
7553
|
dummyInput.setAttribute("aria-hidden", "true");
|
|
7527
7554
|
dummyInput.setAttribute("type", "hidden");
|
|
7528
7555
|
dummyInput.setAttribute("disabled", "");
|
|
7529
7556
|
this.visuallyHidden(dummyInput);
|
|
7557
|
+
if (config.titleIconClass) {
|
|
7558
|
+
this.addIconClass(icon, config.titleIconClass);
|
|
7559
|
+
icon.style.marginRight = "4px";
|
|
7560
|
+
legend.appendChild(icon);
|
|
7561
|
+
}
|
|
7530
7562
|
legend.appendChild(legendText);
|
|
7531
7563
|
legendText.appendChild(dummyInput);
|
|
7532
|
-
return { legend, legendText };
|
|
7564
|
+
return { legend, legendText, icon };
|
|
7533
7565
|
}
|
|
7534
7566
|
/**
|
|
7535
7567
|
* Represents a caption for the content of its parent fieldset
|
|
@@ -7547,10 +7579,12 @@ class Theme {
|
|
|
7547
7579
|
}
|
|
7548
7580
|
if (config.titleIconClass) {
|
|
7549
7581
|
this.addIconClass(icon, config.titleIconClass);
|
|
7582
|
+
icon.style.marginRight = "4px";
|
|
7550
7583
|
}
|
|
7551
7584
|
if (config.titleIconClass) {
|
|
7552
7585
|
label.appendChild(icon);
|
|
7553
7586
|
}
|
|
7587
|
+
labelText.style.marginRight = "4px";
|
|
7554
7588
|
label.appendChild(labelText);
|
|
7555
7589
|
return { label, labelText, icon };
|
|
7556
7590
|
}
|
|
@@ -7568,13 +7602,17 @@ class Theme {
|
|
|
7568
7602
|
labelText.innerHTML = config.content;
|
|
7569
7603
|
if (config.titleIconClass) {
|
|
7570
7604
|
this.addIconClass(icon, config.titleIconClass);
|
|
7605
|
+
icon.style.marginRight = "4px";
|
|
7571
7606
|
}
|
|
7572
7607
|
dummyInput.setAttribute("aria-hidden", "true");
|
|
7573
7608
|
dummyInput.setAttribute("type", "hidden");
|
|
7574
7609
|
dummyInput.setAttribute("disabled", "");
|
|
7575
7610
|
dummyInput.setAttribute("id", config.for);
|
|
7576
7611
|
this.visuallyHidden(dummyInput);
|
|
7577
|
-
|
|
7612
|
+
if (config.titleIconClass) {
|
|
7613
|
+
label.appendChild(icon);
|
|
7614
|
+
}
|
|
7615
|
+
labelText.style.marginRight = "4px";
|
|
7578
7616
|
label.appendChild(labelText);
|
|
7579
7617
|
label.appendChild(dummyInput);
|
|
7580
7618
|
return { label, labelText, icon, dummyInput };
|
|
@@ -8027,7 +8065,6 @@ class Theme {
|
|
|
8027
8065
|
container.style.display = "inline-block";
|
|
8028
8066
|
info.setAttribute("href", "#");
|
|
8029
8067
|
info.classList.add("jedi-info-button");
|
|
8030
|
-
info.style.marginLeft = "4px";
|
|
8031
8068
|
if (isObject(config.attributes)) {
|
|
8032
8069
|
for (const [key, value] of Object.entries(config.attributes)) {
|
|
8033
8070
|
info.setAttribute(key, value);
|
|
@@ -8121,13 +8158,13 @@ class Theme {
|
|
|
8121
8158
|
}
|
|
8122
8159
|
container.appendChild(label);
|
|
8123
8160
|
if (isObject(config.info)) {
|
|
8124
|
-
|
|
8161
|
+
container.appendChild(info.container);
|
|
8125
8162
|
}
|
|
8126
8163
|
container.appendChild(placeholder);
|
|
8127
8164
|
container.appendChild(description);
|
|
8128
8165
|
container.appendChild(messages);
|
|
8129
8166
|
container.appendChild(actions);
|
|
8130
|
-
return { container, placeholder, label, labelText, description, messages, actions };
|
|
8167
|
+
return { container, placeholder, label, info, labelText, description, messages, actions };
|
|
8131
8168
|
}
|
|
8132
8169
|
/**
|
|
8133
8170
|
* Object control is a card containing multiple editors.
|
|
@@ -8196,7 +8233,8 @@ class Theme {
|
|
|
8196
8233
|
const { legend, infoContainer, legendText, right } = this.getLegend({
|
|
8197
8234
|
content: config.title,
|
|
8198
8235
|
id: config.id,
|
|
8199
|
-
titleHidden: config.titleHidden
|
|
8236
|
+
titleHidden: config.titleHidden,
|
|
8237
|
+
titleIconClass: config.titleIconClass
|
|
8200
8238
|
});
|
|
8201
8239
|
if (((_a = config == null ? void 0 : config.info) == null ? void 0 : _a.variant) === "modal") {
|
|
8202
8240
|
this.infoAsModal(info, config.id, config.info);
|
|
@@ -8213,7 +8251,9 @@ class Theme {
|
|
|
8213
8251
|
}
|
|
8214
8252
|
fieldset.appendChild(legend);
|
|
8215
8253
|
if (isObject(config.info)) {
|
|
8216
|
-
|
|
8254
|
+
while (info.container.firstChild) {
|
|
8255
|
+
infoContainer.appendChild(info.container.firstChild);
|
|
8256
|
+
}
|
|
8217
8257
|
}
|
|
8218
8258
|
fieldset.appendChild(collapse);
|
|
8219
8259
|
collapse.appendChild(body);
|
|
@@ -8346,7 +8386,8 @@ class Theme {
|
|
|
8346
8386
|
const { legend, legendText, infoContainer, right } = this.getLegend({
|
|
8347
8387
|
content: config.title,
|
|
8348
8388
|
id: config.id,
|
|
8349
|
-
titleHidden: config.titleHidden
|
|
8389
|
+
titleHidden: config.titleHidden,
|
|
8390
|
+
titleIconClass: config.titleIconClass
|
|
8350
8391
|
});
|
|
8351
8392
|
const description = this.getDescription({
|
|
8352
8393
|
content: config.description
|
|
@@ -8375,7 +8416,9 @@ class Theme {
|
|
|
8375
8416
|
}
|
|
8376
8417
|
fieldset.appendChild(legend);
|
|
8377
8418
|
if (isObject(config.info)) {
|
|
8378
|
-
|
|
8419
|
+
while (info.container.firstChild) {
|
|
8420
|
+
infoContainer.appendChild(info.container.firstChild);
|
|
8421
|
+
}
|
|
8379
8422
|
}
|
|
8380
8423
|
fieldset.appendChild(collapse);
|
|
8381
8424
|
collapse.appendChild(body);
|
|
@@ -8430,6 +8473,7 @@ class Theme {
|
|
|
8430
8473
|
jsonData,
|
|
8431
8474
|
legend,
|
|
8432
8475
|
legendText,
|
|
8476
|
+
infoContainer,
|
|
8433
8477
|
switcherSlot,
|
|
8434
8478
|
footerAddBtn,
|
|
8435
8479
|
deleteAllBtn,
|
|
@@ -8575,13 +8619,13 @@ class Theme {
|
|
|
8575
8619
|
}
|
|
8576
8620
|
container.appendChild(label);
|
|
8577
8621
|
if (isObject(config.info)) {
|
|
8578
|
-
|
|
8622
|
+
container.appendChild(info.container);
|
|
8579
8623
|
}
|
|
8580
8624
|
container.appendChild(br);
|
|
8581
8625
|
container.appendChild(description);
|
|
8582
8626
|
container.appendChild(messages);
|
|
8583
8627
|
container.appendChild(actions);
|
|
8584
|
-
return { container, label, labelText, description, messages, actions };
|
|
8628
|
+
return { container, label, info, labelText, description, messages, actions };
|
|
8585
8629
|
}
|
|
8586
8630
|
/**
|
|
8587
8631
|
* A Textarea
|
|
@@ -8617,13 +8661,13 @@ class Theme {
|
|
|
8617
8661
|
}
|
|
8618
8662
|
container.appendChild(label);
|
|
8619
8663
|
if (isObject(config.info)) {
|
|
8620
|
-
|
|
8664
|
+
container.appendChild(info.container);
|
|
8621
8665
|
}
|
|
8622
8666
|
container.appendChild(input);
|
|
8623
8667
|
container.appendChild(description);
|
|
8624
8668
|
container.appendChild(messages);
|
|
8625
8669
|
container.appendChild(actions);
|
|
8626
|
-
return { container, input, label, labelText, description, messages, actions };
|
|
8670
|
+
return { container, input, label, info, labelText, description, messages, actions };
|
|
8627
8671
|
}
|
|
8628
8672
|
adaptForTableTextareaControl(control) {
|
|
8629
8673
|
this.visuallyHidden(control.label);
|
|
@@ -8665,7 +8709,7 @@ class Theme {
|
|
|
8665
8709
|
this.infoAsModal(info, config.id, config.info);
|
|
8666
8710
|
}
|
|
8667
8711
|
if (isObject(config.info)) {
|
|
8668
|
-
|
|
8712
|
+
container.appendChild(info.container);
|
|
8669
8713
|
}
|
|
8670
8714
|
container.appendChild(input);
|
|
8671
8715
|
container.appendChild(description);
|
|
@@ -8699,7 +8743,8 @@ class Theme {
|
|
|
8699
8743
|
const { legend, legendText } = this.getRadioLegend({
|
|
8700
8744
|
content: config.title,
|
|
8701
8745
|
id: config.id,
|
|
8702
|
-
for: config.id
|
|
8746
|
+
for: config.id,
|
|
8747
|
+
titleIconClass: config.titleIconClass
|
|
8703
8748
|
});
|
|
8704
8749
|
const messages = this.getMessagesSlot({
|
|
8705
8750
|
id: messagesId
|
|
@@ -8743,7 +8788,7 @@ class Theme {
|
|
|
8743
8788
|
container.appendChild(fieldset);
|
|
8744
8789
|
fieldset.appendChild(legend);
|
|
8745
8790
|
if (isObject(config.info)) {
|
|
8746
|
-
legendText.
|
|
8791
|
+
legendText.after(info.container);
|
|
8747
8792
|
}
|
|
8748
8793
|
radioControls.forEach((radioControl, index2) => {
|
|
8749
8794
|
fieldset.appendChild(radioControls[index2]);
|
|
@@ -8787,7 +8832,8 @@ class Theme {
|
|
|
8787
8832
|
const { label, labelText } = this.getLabel({
|
|
8788
8833
|
for: config.id,
|
|
8789
8834
|
text: config.title,
|
|
8790
|
-
visuallyHidden: config.titleHidden
|
|
8835
|
+
visuallyHidden: config.titleHidden,
|
|
8836
|
+
titleIconClass: config.titleIconClass
|
|
8791
8837
|
});
|
|
8792
8838
|
const description = this.getDescription({
|
|
8793
8839
|
content: config.description,
|
|
@@ -8808,7 +8854,7 @@ class Theme {
|
|
|
8808
8854
|
formGroup.appendChild(input);
|
|
8809
8855
|
formGroup.appendChild(label);
|
|
8810
8856
|
if (isObject(config.info)) {
|
|
8811
|
-
|
|
8857
|
+
formGroup.appendChild(info.container);
|
|
8812
8858
|
}
|
|
8813
8859
|
formGroup.appendChild(description);
|
|
8814
8860
|
formGroup.appendChild(messages);
|
|
@@ -8828,7 +8874,8 @@ class Theme {
|
|
|
8828
8874
|
const { legend, legendText } = this.getRadioLegend({
|
|
8829
8875
|
content: config.title,
|
|
8830
8876
|
id: config.id,
|
|
8831
|
-
for: config.id
|
|
8877
|
+
for: config.id,
|
|
8878
|
+
titleIconClass: config.titleIconClass
|
|
8832
8879
|
});
|
|
8833
8880
|
const messages = this.getMessagesSlot({
|
|
8834
8881
|
id: messagesId
|
|
@@ -8871,7 +8918,7 @@ class Theme {
|
|
|
8871
8918
|
container.appendChild(fieldset);
|
|
8872
8919
|
fieldset.appendChild(legend);
|
|
8873
8920
|
if (isObject(config.info)) {
|
|
8874
|
-
legendText.
|
|
8921
|
+
legendText.after(info.container);
|
|
8875
8922
|
}
|
|
8876
8923
|
checkboxControls.forEach((checkboxControl, index2) => {
|
|
8877
8924
|
fieldset.appendChild(checkboxControls[index2]);
|
|
@@ -8913,7 +8960,8 @@ class Theme {
|
|
|
8913
8960
|
const { label, labelText } = this.getLabel({
|
|
8914
8961
|
for: config.id,
|
|
8915
8962
|
text: config.title,
|
|
8916
|
-
visuallyHidden: config.titleHidden
|
|
8963
|
+
visuallyHidden: config.titleHidden,
|
|
8964
|
+
titleIconClass: config.titleIconClass
|
|
8917
8965
|
});
|
|
8918
8966
|
const messages = this.getMessagesSlot({
|
|
8919
8967
|
id: messagesId
|
|
@@ -8938,7 +8986,7 @@ class Theme {
|
|
|
8938
8986
|
}
|
|
8939
8987
|
container.appendChild(label);
|
|
8940
8988
|
if (isObject(config.info)) {
|
|
8941
|
-
|
|
8989
|
+
container.appendChild(info.container);
|
|
8942
8990
|
}
|
|
8943
8991
|
container.appendChild(input);
|
|
8944
8992
|
container.appendChild(description);
|
|
@@ -9316,13 +9364,14 @@ class ThemeBootstrap3 extends Theme {
|
|
|
9316
9364
|
}
|
|
9317
9365
|
getLegend(config) {
|
|
9318
9366
|
const superLegend = super.getLegend(config);
|
|
9319
|
-
const { legend } = superLegend;
|
|
9367
|
+
const { legend, infoContainer } = superLegend;
|
|
9320
9368
|
legend.classList.add("panel-heading");
|
|
9321
9369
|
legend.classList.add("pull-left");
|
|
9322
9370
|
legend.style.margin = "0";
|
|
9323
9371
|
legend.style.display = "flex";
|
|
9324
9372
|
legend.style.justifyContent = "space-between";
|
|
9325
9373
|
legend.style.alignItems = "center";
|
|
9374
|
+
infoContainer.style.marginRight = "4px";
|
|
9326
9375
|
return superLegend;
|
|
9327
9376
|
}
|
|
9328
9377
|
getRadioLegend(config) {
|
|
@@ -9334,11 +9383,12 @@ class ThemeBootstrap3 extends Theme {
|
|
|
9334
9383
|
return superRadioLegend;
|
|
9335
9384
|
}
|
|
9336
9385
|
getLabel(config) {
|
|
9337
|
-
|
|
9338
|
-
|
|
9339
|
-
|
|
9340
|
-
|
|
9341
|
-
|
|
9386
|
+
return super.getLabel(config);
|
|
9387
|
+
}
|
|
9388
|
+
getInfo(config = {}) {
|
|
9389
|
+
const info = super.getInfo(config);
|
|
9390
|
+
info.container.style.marginRight = "4px";
|
|
9391
|
+
return info;
|
|
9342
9392
|
}
|
|
9343
9393
|
getCard() {
|
|
9344
9394
|
const card = super.getCard();
|
|
@@ -9505,11 +9555,11 @@ class ThemeBootstrap3 extends Theme {
|
|
|
9505
9555
|
}
|
|
9506
9556
|
getSwitcherModal(config) {
|
|
9507
9557
|
const control = super.getSwitcherModal(config);
|
|
9508
|
-
control.
|
|
9509
|
-
control.trigger.classList.add("label", "label-default");
|
|
9558
|
+
control.trigger.classList.add("label", "label-primary");
|
|
9510
9559
|
control.dialogBody.classList.add("btn-group-vertical");
|
|
9560
|
+
control.dialogBody.style.width = "100%";
|
|
9511
9561
|
control.optionButtons.forEach((btn) => {
|
|
9512
|
-
btn.classList.add("btn", "btn-default");
|
|
9562
|
+
btn.classList.add("btn", "btn-default", "btn-block");
|
|
9513
9563
|
});
|
|
9514
9564
|
return control;
|
|
9515
9565
|
}
|
|
@@ -9570,7 +9620,7 @@ class ThemeBootstrap3 extends Theme {
|
|
|
9570
9620
|
tab.link.style.display = "flex";
|
|
9571
9621
|
tab.link.style.alignItems = "center";
|
|
9572
9622
|
tab.arrayActions.style.flexShrink = "0";
|
|
9573
|
-
tab.arrayActions.
|
|
9623
|
+
tab.arrayActions.classList.add("text-nowrap");
|
|
9574
9624
|
tab.text.style.flex = "1";
|
|
9575
9625
|
tab.text.style.marginLeft = "5px";
|
|
9576
9626
|
tab.text.style.marginRight = "5px";
|
|
@@ -9579,7 +9629,7 @@ class ThemeBootstrap3 extends Theme {
|
|
|
9579
9629
|
if (warning) {
|
|
9580
9630
|
tab.text.removeChild(warning);
|
|
9581
9631
|
warning.style.flexShrink = "0";
|
|
9582
|
-
warning.
|
|
9632
|
+
warning.classList.add("text-nowrap");
|
|
9583
9633
|
tab.link.appendChild(warning);
|
|
9584
9634
|
}
|
|
9585
9635
|
}
|
|
@@ -9724,9 +9774,8 @@ class ThemeBootstrap4 extends Theme {
|
|
|
9724
9774
|
} else {
|
|
9725
9775
|
chevron.textContent = "▾";
|
|
9726
9776
|
}
|
|
9727
|
-
chevron.
|
|
9777
|
+
chevron.classList.add("d-inline-block", "mr-2");
|
|
9728
9778
|
chevron.style.transition = "transform 0.1s ease";
|
|
9729
|
-
chevron.style.marginRight = "0.5em";
|
|
9730
9779
|
toggle.appendChild(chevron);
|
|
9731
9780
|
toggle.appendChild(document.createTextNode(config.title));
|
|
9732
9781
|
const collapse = document.createElement("div");
|
|
@@ -9766,21 +9815,23 @@ class ThemeBootstrap4 extends Theme {
|
|
|
9766
9815
|
}
|
|
9767
9816
|
getLegend(config) {
|
|
9768
9817
|
const superLegend = super.getLegend(config);
|
|
9769
|
-
const { legend } = superLegend;
|
|
9818
|
+
const { legend, infoContainer } = superLegend;
|
|
9770
9819
|
legend.classList.add("card-header");
|
|
9771
9820
|
legend.classList.add("d-flex");
|
|
9772
9821
|
legend.classList.add("justify-content-between");
|
|
9773
9822
|
legend.classList.add("align-items-center");
|
|
9774
9823
|
legend.classList.add("float-left");
|
|
9775
9824
|
legend.classList.add("py-2");
|
|
9825
|
+
infoContainer.classList.add("mr-1");
|
|
9776
9826
|
return superLegend;
|
|
9777
9827
|
}
|
|
9778
9828
|
getLabel(config) {
|
|
9779
|
-
|
|
9780
|
-
|
|
9781
|
-
|
|
9782
|
-
|
|
9783
|
-
|
|
9829
|
+
return super.getLabel(config);
|
|
9830
|
+
}
|
|
9831
|
+
getInfo(config = {}) {
|
|
9832
|
+
const info = super.getInfo(config);
|
|
9833
|
+
info.container.classList.add("mr-1");
|
|
9834
|
+
return info;
|
|
9784
9835
|
}
|
|
9785
9836
|
getCard() {
|
|
9786
9837
|
const card = super.getCard();
|
|
@@ -9898,7 +9949,7 @@ class ThemeBootstrap4 extends Theme {
|
|
|
9898
9949
|
super.adaptForTableRadiosControl(control, td);
|
|
9899
9950
|
control.container.classList.remove("form-group");
|
|
9900
9951
|
control.fieldset.classList.remove("card");
|
|
9901
|
-
control.fieldset.
|
|
9952
|
+
control.fieldset.classList.add("mb-0");
|
|
9902
9953
|
}
|
|
9903
9954
|
getCheckboxesControl(config) {
|
|
9904
9955
|
const control = super.getCheckboxesControl(config);
|
|
@@ -9966,18 +10017,17 @@ class ThemeBootstrap4 extends Theme {
|
|
|
9966
10017
|
}
|
|
9967
10018
|
getSwitcherModal(config) {
|
|
9968
10019
|
const control = super.getSwitcherModal(config);
|
|
9969
|
-
control.
|
|
9970
|
-
control.trigger.classList.add("badge", "badge-secondary");
|
|
10020
|
+
control.trigger.classList.add("badge", "badge-primary");
|
|
9971
10021
|
control.dialogBody.classList.add("btn-group", "btn-group-vertical", "w-100");
|
|
9972
10022
|
control.optionButtons.forEach((btn) => {
|
|
9973
|
-
btn.classList.add("btn", "btn-
|
|
10023
|
+
btn.classList.add("btn", "btn-light");
|
|
9974
10024
|
});
|
|
9975
10025
|
return control;
|
|
9976
10026
|
}
|
|
9977
10027
|
setSwitcherOptionActive(btn, active) {
|
|
9978
10028
|
super.setSwitcherOptionActive(btn, active);
|
|
9979
10029
|
btn.classList.toggle("btn-primary", active);
|
|
9980
|
-
btn.classList.toggle("btn-
|
|
10030
|
+
btn.classList.toggle("btn-light", !active);
|
|
9981
10031
|
}
|
|
9982
10032
|
adaptForTableMultipleControl(control, td) {
|
|
9983
10033
|
super.adaptForTableMultipleControl(control, td);
|
|
@@ -10097,7 +10147,6 @@ class ThemeBootstrap4 extends Theme {
|
|
|
10097
10147
|
closeBtn.setAttribute("always-enabled", "");
|
|
10098
10148
|
info.info.setAttribute("data-toggle", "modal");
|
|
10099
10149
|
info.info.setAttribute("data-target", "#" + modalId);
|
|
10100
|
-
info.container.classList.add("ml-1");
|
|
10101
10150
|
modal.classList.add("modal");
|
|
10102
10151
|
modal.classList.add("fade");
|
|
10103
10152
|
modalDialog.classList.add("modal-dialog");
|
|
@@ -10199,9 +10248,8 @@ class ThemeBootstrap5 extends Theme {
|
|
|
10199
10248
|
} else {
|
|
10200
10249
|
chevron.textContent = "▾";
|
|
10201
10250
|
}
|
|
10202
|
-
chevron.
|
|
10251
|
+
chevron.classList.add("d-inline-block", "me-2");
|
|
10203
10252
|
chevron.style.transition = "transform 0.1s ease";
|
|
10204
|
-
chevron.style.marginRight = "0.5em";
|
|
10205
10253
|
toggle.appendChild(chevron);
|
|
10206
10254
|
toggle.appendChild(document.createTextNode(config.title));
|
|
10207
10255
|
const collapse = document.createElement("div");
|
|
@@ -10241,24 +10289,28 @@ class ThemeBootstrap5 extends Theme {
|
|
|
10241
10289
|
}
|
|
10242
10290
|
getLegend(config) {
|
|
10243
10291
|
const superLegend = super.getLegend(config);
|
|
10244
|
-
const { legend } = superLegend;
|
|
10292
|
+
const { legend, infoContainer } = superLegend;
|
|
10245
10293
|
legend.classList.add("card-header");
|
|
10246
10294
|
legend.classList.add("d-flex");
|
|
10247
10295
|
legend.classList.add("justify-content-between");
|
|
10248
10296
|
legend.classList.add("align-items-center");
|
|
10249
10297
|
legend.classList.add("py-2");
|
|
10298
|
+
infoContainer.classList.add("me-1");
|
|
10250
10299
|
return superLegend;
|
|
10251
10300
|
}
|
|
10252
10301
|
styleLegendWarning(span) {
|
|
10253
|
-
span.classList.add("
|
|
10302
|
+
span.classList.add("me-1");
|
|
10254
10303
|
}
|
|
10255
10304
|
getLabel(config) {
|
|
10256
10305
|
const labelObj = super.getLabel(config);
|
|
10257
|
-
|
|
10258
|
-
labelObj.icon.classList.add("me-1");
|
|
10259
|
-
}
|
|
10306
|
+
labelObj.label.classList.add("mb-1");
|
|
10260
10307
|
return labelObj;
|
|
10261
10308
|
}
|
|
10309
|
+
getInfo(config = {}) {
|
|
10310
|
+
const info = super.getInfo(config);
|
|
10311
|
+
info.container.classList.add("me-1");
|
|
10312
|
+
return info;
|
|
10313
|
+
}
|
|
10262
10314
|
getCard() {
|
|
10263
10315
|
const card = super.getCard();
|
|
10264
10316
|
card.classList.add("card");
|
|
@@ -10378,7 +10430,7 @@ class ThemeBootstrap5 extends Theme {
|
|
|
10378
10430
|
super.adaptForTableRadiosControl(control, td);
|
|
10379
10431
|
control.container.classList.remove("mb-3");
|
|
10380
10432
|
control.fieldset.classList.remove("card");
|
|
10381
|
-
control.fieldset.
|
|
10433
|
+
control.fieldset.classList.add("mb-0");
|
|
10382
10434
|
}
|
|
10383
10435
|
getCheckboxesControl(config) {
|
|
10384
10436
|
const control = super.getCheckboxesControl(config);
|
|
@@ -10439,18 +10491,17 @@ class ThemeBootstrap5 extends Theme {
|
|
|
10439
10491
|
}
|
|
10440
10492
|
getSwitcherModal(config) {
|
|
10441
10493
|
const control = super.getSwitcherModal(config);
|
|
10442
|
-
control.
|
|
10443
|
-
control.trigger.classList.add("badge", "bg-secondary");
|
|
10494
|
+
control.trigger.classList.add("badge", "bg-primary");
|
|
10444
10495
|
control.dialogBody.classList.add("btn-group", "btn-group-vertical", "w-100");
|
|
10445
10496
|
control.optionButtons.forEach((btn) => {
|
|
10446
|
-
btn.classList.add("btn", "btn-
|
|
10497
|
+
btn.classList.add("btn", "btn-light");
|
|
10447
10498
|
});
|
|
10448
10499
|
return control;
|
|
10449
10500
|
}
|
|
10450
10501
|
setSwitcherOptionActive(btn, active) {
|
|
10451
10502
|
super.setSwitcherOptionActive(btn, active);
|
|
10452
10503
|
btn.classList.toggle("btn-primary", active);
|
|
10453
|
-
btn.classList.toggle("btn-
|
|
10504
|
+
btn.classList.toggle("btn-light", !active);
|
|
10454
10505
|
}
|
|
10455
10506
|
adaptForTableMultipleControl(control, td) {
|
|
10456
10507
|
super.adaptForTableMultipleControl(control, td);
|
|
@@ -10567,7 +10618,6 @@ class ThemeBootstrap5 extends Theme {
|
|
|
10567
10618
|
closeBtn.setAttribute("always-enabled", "");
|
|
10568
10619
|
info.info.setAttribute("data-bs-toggle", "modal");
|
|
10569
10620
|
info.info.setAttribute("data-bs-target", "#" + modalId);
|
|
10570
|
-
info.container.classList.add("ms-1");
|
|
10571
10621
|
modal.classList.add("modal");
|
|
10572
10622
|
modal.classList.add("fade");
|
|
10573
10623
|
modalDialog.classList.add("modal-dialog");
|