@json-editor/json-editor 2.13.2 → 2.14.1
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 +18 -0
- package/README.md +2 -1
- package/dist/jsoneditor.js +1 -1
- package/dist/jsoneditor.js.LICENSE.txt +1 -1
- package/dist/nonmin/jsoneditor.js +436 -247
- package/dist/nonmin/jsoneditor.js.map +1 -1
- package/docs/imask.html +1 -1
- package/docs/meta_schema.json +3 -0
- package/package.json +1 -1
- package/src/defaults.js +5 -1
- package/src/editor.js +15 -2
- package/src/editors/array/selectize.js +13 -0
- package/src/editors/array.js +16 -2
- package/src/editors/info.js +1 -1
- package/src/editors/multiple.js +13 -2
- package/src/editors/multiselect.js +3 -2
- package/src/editors/object.js +20 -3
- package/src/editors/radio.js +4 -0
- package/src/editors/select.js +1 -1
- package/src/editors/starrating.js +5 -1
- package/src/editors/string.js +5 -3
- package/src/editors/table.js +3 -2
- package/src/theme.js +56 -4
- package/src/themes/barebones.js +1 -0
- package/src/themes/bootstrap3.js +49 -12
- package/src/themes/bootstrap4.js +38 -13
- package/src/themes/bootstrap5.js +37 -7
- package/src/themes/html.js +1 -0
- package/src/themes/spectre.js +15 -7
- package/src/validator.js +4 -3
- package/tests/codeceptjs/core_test.js +11 -0
- package/tests/codeceptjs/editors/array_test.js +7 -0
- package/tests/codeceptjs/editors/button_test.js +1 -1
- package/tests/codeceptjs/editors/checkbox_test.js +1 -1
- package/tests/codeceptjs/editors/integer_test.js +1 -1
- package/tests/codeceptjs/editors/multiselect_test.js +1 -1
- package/tests/codeceptjs/editors/number_test.js +1 -1
- package/tests/codeceptjs/editors/object_test.js +7 -0
- package/tests/codeceptjs/editors/radio_test.js +1 -2
- package/tests/codeceptjs/editors/rating_test.js +1 -2
- package/tests/codeceptjs/editors/select_test.js +1 -1
- package/tests/codeceptjs/editors/string_test.js +1 -1
- package/tests/codeceptjs/issues/issue-gh-1171_test.js +11 -0
- package/tests/codeceptjs/issues/issue-gh-1272_test.js +21 -0
- package/tests/codeceptjs/issues/issue-gh-1471_test.js +17 -0
- package/tests/codeceptjs/issues/issue-gh-1485_test.js +13 -0
- package/tests/codeceptjs/issues/issue-gh-1491_test.js +9 -0
- package/tests/codeceptjs/issues/issue-gh-812_test.js +2 -2
- package/tests/codeceptjs/meta-schema_test.js +1 -1
- package/tests/codeceptjs/schemaloader_test.js +1 -1
- package/tests/pages/advanced.html +1 -1
- package/tests/pages/anyof-2.html +1 -0
- package/tests/pages/anyof.html +4 -2
- package/tests/pages/array-anyof.html +5 -2
- package/tests/pages/array-checkboxes-infotext.html +5 -2
- package/tests/pages/array-checkboxes.html +5 -2
- package/tests/pages/array-choices.html +5 -2
- package/tests/pages/array-events-table.html +5 -2
- package/tests/pages/array-events.html +7 -3
- package/tests/pages/array-header-template.html +1 -0
- package/tests/pages/array-integers.html +5 -2
- package/tests/pages/array-multiselects.html +5 -2
- package/tests/pages/array-nested-arrays.html +5 -2
- package/tests/pages/array-numbers.html +5 -2
- package/tests/pages/array-objects.html +5 -2
- package/tests/pages/array-ratings.html +5 -2
- package/tests/pages/array-selectize-create.html +1 -0
- package/tests/pages/array-selectize.html +5 -2
- package/tests/pages/array-selects.html +5 -2
- package/tests/pages/array-strings.html +5 -2
- package/tests/pages/array-table-responsive.html +1 -0
- package/tests/pages/array-unique-items-sort.html +5 -2
- package/tests/pages/array.html +5 -2
- package/tests/pages/autocomplete.html +3 -1
- package/tests/pages/button-callbacks.html +4 -2
- package/tests/pages/button-icons.html +2 -1
- package/tests/pages/button_state_mode_1.html +1 -0
- package/tests/pages/button_state_mode_2.html +1 -0
- package/tests/pages/checkbox-labels.html +4 -2
- package/tests/pages/colorpicker-no-3rd-party.html +4 -2
- package/tests/pages/colorpicker-use-vanilla-picker.html +4 -2
- package/tests/pages/container-attributes.html +1 -0
- package/tests/pages/contains.html +1 -0
- package/tests/pages/core.html +5 -3
- package/tests/pages/datetime.html +2 -0
- package/tests/pages/dependentRequired.html +1 -0
- package/tests/pages/dependentSchemas.html +1 -0
- package/tests/pages/disable-button-in-object-editors.html +1 -0
- package/tests/pages/error-messages.html +1 -0
- package/tests/pages/form-name.html +4 -1
- package/tests/pages/grid-strict.html +3 -2
- package/tests/pages/grid.html +3 -2
- package/tests/pages/if-else.html +1 -0
- package/tests/pages/if-then-else-allOf.html +1 -0
- package/tests/pages/if-then-else-disable-fields.html +1 -0
- package/tests/pages/if-then-else.html +1 -0
- package/tests/pages/if-then.html +1 -0
- package/tests/pages/inheritance.html +6 -2
- package/tests/pages/integer.html +4 -2
- package/tests/pages/issues/_template.html +1 -1
- package/tests/pages/issues/issue-gh-1158-2.html +1 -1
- package/tests/pages/issues/issue-gh-1158.html +1 -1
- package/tests/pages/issues/issue-gh-1171.html +39 -0
- package/tests/pages/issues/issue-gh-1272.html +167 -0
- package/tests/pages/issues/issue-gh-1364.html +1 -1
- package/tests/pages/issues/issue-gh-1367.html +1 -1
- package/tests/pages/issues/issue-gh-1466.html +63 -0
- package/tests/pages/issues/issue-gh-1471.html +49 -0
- package/tests/pages/issues/issue-gh-1485.html +59 -0
- package/tests/pages/issues/issue-gh-1491.html +59 -0
- package/tests/pages/issues/issue-gh-812.html +3 -2
- package/tests/pages/issues/issue-gh-823-meta-schema.html +1 -1
- package/tests/pages/issues/issue-gh-848.html +1 -1
- package/tests/pages/keep_only_existing_values.html +1 -0
- package/tests/pages/load-events.html +1 -0
- package/tests/pages/maxContains.html +1 -0
- package/tests/pages/meta-schema.html +4 -0
- package/tests/pages/meta_schema.json +3 -0
- package/tests/pages/minContains.html +1 -0
- package/tests/pages/number.html +4 -2
- package/tests/pages/object-case-sensitive-property-search-false.html +2 -1
- package/tests/pages/object-case-sensitive-property-search-true.html +2 -1
- package/tests/pages/object-no-additional-properties.html +5 -2
- package/tests/pages/object-no-duplicated-id.html +2 -0
- package/tests/pages/object-required-properties.html +5 -3
- package/tests/pages/object-show-opt-in.html +3 -2
- package/tests/pages/object-with-dependencies-array.html +4 -2
- package/tests/pages/object-with-dependencies.html +2 -0
- package/tests/pages/object.html +5 -3
- package/tests/pages/oneof-2.html +1 -0
- package/tests/pages/oneof.html +4 -2
- package/tests/pages/option-dependencies.html +1 -0
- package/tests/pages/option-no_default_values.html +4 -2
- package/tests/pages/per-editor-options.html +1 -1
- package/tests/pages/programmatic-changes.html +4 -3
- package/tests/pages/range.html +4 -2
- package/tests/pages/read-only.html +36 -5
- package/tests/pages/ready.html +2 -1
- package/tests/pages/references.html +1 -1
- package/tests/pages/select.html +4 -3
- package/tests/pages/stepper-manual.html +4 -2
- package/tests/pages/stepper.html +4 -2
- package/tests/pages/string-ace-editor.html +4 -2
- package/tests/pages/string-cleave.html +4 -2
- package/tests/pages/string-custom-attributes.html +4 -2
- package/tests/pages/string-formats.html +4 -2
- package/tests/pages/string-formats2.html +4 -2
- package/tests/pages/string-jodit-editor.html +4 -2
- package/tests/pages/string-sceditor.html +4 -2
- package/tests/pages/string-simplemde-editor.html +4 -2
- package/tests/pages/table.html +4 -2
- package/tests/pages/tabs.html +1 -1
- package/tests/pages/themes.html +38 -52
- package/tests/pages/title-hidden.html +75 -0
- package/tests/pages/translate-property.html +2 -1
- package/tests/pages/urn.html +4 -2
- package/tests/pages/use-name-attributes.html +2 -1
- package/tests/pages/uuid.html +2 -0
- package/tests/pages/validation.html +2 -1
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* * @name JSON Editor
|
|
4
4
|
* * @description JSON Schema Based Editor
|
|
5
5
|
* * This library is the continuation of jdorn's great work (see also https://github.com/jdorn/json-editor/issues/800)
|
|
6
|
-
* * @version "2.
|
|
6
|
+
* * @version "2.14.1"
|
|
7
7
|
* * @author Jeremy Dorn
|
|
8
8
|
* * @see https://github.com/jdorn/json-editor/
|
|
9
9
|
* * @see https://github.com/json-editor/json-editor
|
|
@@ -456,7 +456,11 @@ languages.en = {
|
|
|
456
456
|
/**
|
|
457
457
|
* Warning when deleting a node
|
|
458
458
|
*/
|
|
459
|
-
button_delete_node_warning: 'Are you sure you want to remove this item?'
|
|
459
|
+
button_delete_node_warning: 'Are you sure you want to remove this item?',
|
|
460
|
+
/**
|
|
461
|
+
* Warning when deleting a node
|
|
462
|
+
*/
|
|
463
|
+
table_controls: 'Controls'
|
|
460
464
|
};
|
|
461
465
|
|
|
462
466
|
/* Default per-editor options */
|
|
@@ -706,6 +710,10 @@ var AbstractEditor = /*#__PURE__*/function () {
|
|
|
706
710
|
key: "register",
|
|
707
711
|
value: function register() {
|
|
708
712
|
this.jsoneditor.registerEditor(this);
|
|
713
|
+
if (this.input && !this.label) {
|
|
714
|
+
var ariaLabel = this.getTitle() || this.formname;
|
|
715
|
+
this.input.setAttribute('aria-label', ariaLabel);
|
|
716
|
+
}
|
|
709
717
|
this.onChange();
|
|
710
718
|
}
|
|
711
719
|
}, {
|
|
@@ -865,9 +873,12 @@ var AbstractEditor = /*#__PURE__*/function () {
|
|
|
865
873
|
var _this4 = this;
|
|
866
874
|
/* the active/deactive checbox control. */
|
|
867
875
|
|
|
876
|
+
this.optInLabel = this.theme.getHiddenLabel(this.formname + ' opt-in');
|
|
877
|
+
this.optInLabel.setAttribute('for', this.formname + '-opt-in');
|
|
868
878
|
this.optInCheckbox = document.createElement('input');
|
|
869
879
|
this.optInCheckbox.setAttribute('type', 'checkbox');
|
|
870
880
|
this.optInCheckbox.setAttribute('style', 'margin: 0 10px 0 0;');
|
|
881
|
+
this.optInCheckbox.setAttribute('id', this.formname + '-opt-in');
|
|
871
882
|
this.optInCheckbox.classList.add('json-editor-opt-in');
|
|
872
883
|
this.optInCheckbox.addEventListener('click', function () {
|
|
873
884
|
if (_this4.isActive()) {
|
|
@@ -885,6 +896,7 @@ var AbstractEditor = /*#__PURE__*/function () {
|
|
|
885
896
|
if (parentOptInEnabled || !parentOptInDisabled && globalOptIn || !parentOptInDefined && globalOptIn) {
|
|
886
897
|
/* and control to type object editors if they are not required */
|
|
887
898
|
if (this.parent && this.parent.schema.type === 'object' && !this.isRequired() && this.header) {
|
|
899
|
+
this.header.appendChild(this.optInLabel);
|
|
888
900
|
this.header.appendChild(this.optInCheckbox);
|
|
889
901
|
this.header.insertBefore(this.optInCheckbox, this.header.firstChild);
|
|
890
902
|
}
|
|
@@ -905,6 +917,10 @@ var AbstractEditor = /*#__PURE__*/function () {
|
|
|
905
917
|
this.setValue(this.getDefault(), true);
|
|
906
918
|
this.updateHeaderText();
|
|
907
919
|
this.onWatchedFieldChange();
|
|
920
|
+
if (this.options.titleHidden) {
|
|
921
|
+
this.theme.visuallyHidden(this.label);
|
|
922
|
+
this.theme.visuallyHidden(this.header);
|
|
923
|
+
}
|
|
908
924
|
}
|
|
909
925
|
}, {
|
|
910
926
|
key: "setupWatchListeners",
|
|
@@ -1167,7 +1183,7 @@ var AbstractEditor = /*#__PURE__*/function () {
|
|
|
1167
1183
|
});
|
|
1168
1184
|
|
|
1169
1185
|
// object properties
|
|
1170
|
-
if (Object.keys(this.editors).length) {
|
|
1186
|
+
if (this.editors && Object.keys(this.editors).length) {
|
|
1171
1187
|
vars.properties = {};
|
|
1172
1188
|
Object.keys(this.editors).forEach(function (key) {
|
|
1173
1189
|
var editor = _this7.editors[key];
|
|
@@ -1273,7 +1289,7 @@ var AbstractEditor = /*#__PURE__*/function () {
|
|
|
1273
1289
|
}, {
|
|
1274
1290
|
key: "getTitle",
|
|
1275
1291
|
value: function getTitle() {
|
|
1276
|
-
return this.translateProperty(this.schema.title || this.key);
|
|
1292
|
+
return this.translateProperty(this.schema.title || this.key || this.formname);
|
|
1277
1293
|
}
|
|
1278
1294
|
}, {
|
|
1279
1295
|
key: "enable",
|
|
@@ -1833,7 +1849,7 @@ var ArrayEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
1833
1849
|
key: "build",
|
|
1834
1850
|
value: function build() {
|
|
1835
1851
|
if (!this.options.compact) {
|
|
1836
|
-
this.header = document.createElement('
|
|
1852
|
+
this.header = document.createElement('span');
|
|
1837
1853
|
this.header.textContent = this.getTitle();
|
|
1838
1854
|
this.title = this.theme.getHeader(this.header, this.getPathDepth());
|
|
1839
1855
|
this.container.appendChild(this.title);
|
|
@@ -1892,6 +1908,14 @@ var ArrayEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
1892
1908
|
/* Add controls */
|
|
1893
1909
|
this.addControls();
|
|
1894
1910
|
}
|
|
1911
|
+
}, {
|
|
1912
|
+
key: "postBuild",
|
|
1913
|
+
value: function postBuild() {
|
|
1914
|
+
_get(_getPrototypeOf(ArrayEditor.prototype), "postBuild", this).call(this);
|
|
1915
|
+
if (this.schema.readOnly || this.schema.readonly) {
|
|
1916
|
+
this.disable();
|
|
1917
|
+
}
|
|
1918
|
+
}
|
|
1895
1919
|
}, {
|
|
1896
1920
|
key: "onChildEditorChange",
|
|
1897
1921
|
value: function onChildEditorChange(editor) {
|
|
@@ -2011,7 +2035,7 @@ var ArrayEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
2011
2035
|
key: "empty",
|
|
2012
2036
|
value: function empty(hard) {
|
|
2013
2037
|
var _this3 = this;
|
|
2014
|
-
if (
|
|
2038
|
+
if (this.rows === null) return;
|
|
2015
2039
|
this.rows.forEach(function (row, i) {
|
|
2016
2040
|
if (hard) {
|
|
2017
2041
|
if (_this3.checkParent(row.tab)) row.tab.parentNode.removeChild(row.tab);
|
|
@@ -2020,6 +2044,12 @@ var ArrayEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
2020
2044
|
}
|
|
2021
2045
|
_this3.rows[i] = null;
|
|
2022
2046
|
});
|
|
2047
|
+
if (hard) {
|
|
2048
|
+
for (var j = this.rows.length; j < this.row_cache.length; j++) {
|
|
2049
|
+
this.destroyRow(this.row_cache[j], true);
|
|
2050
|
+
this.row_cache[j] = null;
|
|
2051
|
+
}
|
|
2052
|
+
}
|
|
2023
2053
|
this.rows = [];
|
|
2024
2054
|
if (hard) this.row_cache = [];
|
|
2025
2055
|
}
|
|
@@ -3118,6 +3148,16 @@ var ArraySelectizeEditor = /*#__PURE__*/function (_MultiSelectEditor) {
|
|
|
3118
3148
|
/* Add new event handler. */
|
|
3119
3149
|
/* Note: Must use the "on()" method and not addEventListener() */
|
|
3120
3150
|
this.selectize_instance.on('change', this.multiselectChangeHandler);
|
|
3151
|
+
var label = this.theme.getHiddenLabel(this.formname);
|
|
3152
|
+
this.input.setAttribute('id', this.formname + '-hidden-input');
|
|
3153
|
+
label.setAttribute('for', this.formname + '-hidden-input');
|
|
3154
|
+
this.input.parentNode.insertBefore(label, this.input);
|
|
3155
|
+
var selectizeControl = this.selectize_instance.$control[0];
|
|
3156
|
+
if (selectizeControl) {
|
|
3157
|
+
var selectizeLabel = this.theme.getHiddenLabel(this.formname);
|
|
3158
|
+
selectizeLabel.setAttribute('for', this.formname + '-selectized');
|
|
3159
|
+
selectizeControl.appendChild(selectizeLabel);
|
|
3160
|
+
}
|
|
3121
3161
|
}
|
|
3122
3162
|
_get(_getPrototypeOf(ArraySelectizeEditor.prototype), "afterInputReady", this).call(this);
|
|
3123
3163
|
}
|
|
@@ -5672,7 +5712,7 @@ var InfoEditor = /*#__PURE__*/function (_ButtonEditor) {
|
|
|
5672
5712
|
key: "build",
|
|
5673
5713
|
value: function build() {
|
|
5674
5714
|
this.options.compact = false;
|
|
5675
|
-
this.header = this.label = this.theme.
|
|
5715
|
+
this.header = this.label = this.theme.getLabelLike(this.getTitle());
|
|
5676
5716
|
this.description = this.theme.getDescription(this.schema.description || '');
|
|
5677
5717
|
this.control = this.theme.getFormControl(this.label, this.description, null);
|
|
5678
5718
|
this.container.appendChild(this.control);
|
|
@@ -6309,7 +6349,9 @@ var MultipleEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
6309
6349
|
}, {
|
|
6310
6350
|
key: "buildChildEditor",
|
|
6311
6351
|
value: function buildChildEditor(i) {
|
|
6312
|
-
var
|
|
6352
|
+
var _schema,
|
|
6353
|
+
_schema$options,
|
|
6354
|
+
_this2 = this;
|
|
6313
6355
|
var type = this.types[i];
|
|
6314
6356
|
var holder = this.theme.getChildEditorHolder();
|
|
6315
6357
|
this.editor_holder.appendChild(holder);
|
|
@@ -6326,6 +6368,9 @@ var MultipleEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
6326
6368
|
schema.required = this.schema.required.concat(type.required);
|
|
6327
6369
|
}
|
|
6328
6370
|
}
|
|
6371
|
+
if ((_schema = schema) !== null && _schema !== void 0 && (_schema$options = _schema.options) !== null && _schema$options !== void 0 && _schema$options.dependencies) {
|
|
6372
|
+
delete schema.options.dependencies;
|
|
6373
|
+
}
|
|
6329
6374
|
var editor = this.jsoneditor.getEditorClass(schema);
|
|
6330
6375
|
this.editors[i] = this.jsoneditor.createEditor(editor, {
|
|
6331
6376
|
jsoneditor: this.jsoneditor,
|
|
@@ -6338,7 +6383,9 @@ var MultipleEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
6338
6383
|
this.editors[i].preBuild();
|
|
6339
6384
|
this.editors[i].build();
|
|
6340
6385
|
this.editors[i].postBuild();
|
|
6341
|
-
if (this.editors[i].header)
|
|
6386
|
+
if (this.editors[i].header) {
|
|
6387
|
+
this.theme.visuallyHidden(this.editors[i].header);
|
|
6388
|
+
}
|
|
6342
6389
|
this.editors[i].option = this.switcher_options[i];
|
|
6343
6390
|
holder.addEventListener('change_header_text', function () {
|
|
6344
6391
|
_this2.refreshHeaderText();
|
|
@@ -6420,10 +6467,14 @@ var MultipleEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
6420
6467
|
value: function build() {
|
|
6421
6468
|
var _this3 = this;
|
|
6422
6469
|
var container = this.container;
|
|
6423
|
-
this.header = this.label = this.theme.
|
|
6470
|
+
this.header = this.label = this.theme.getLabelLike(this.getTitle(), this.isRequired());
|
|
6424
6471
|
this.switcher = this.theme.getSwitcher(this.display_text);
|
|
6472
|
+
this.switcher.setAttribute('id', this.formname + 'switcher');
|
|
6473
|
+
this.switcherLabel = this.theme.getHiddenLabel(this.formname + ' switcher');
|
|
6474
|
+
this.switcherLabel.setAttribute('for', this.formname + 'switcher');
|
|
6425
6475
|
if (!this["if"]) {
|
|
6426
6476
|
this.container.appendChild(this.header);
|
|
6477
|
+
container.appendChild(this.switcherLabel);
|
|
6427
6478
|
container.appendChild(this.switcher);
|
|
6428
6479
|
}
|
|
6429
6480
|
this.switcher.addEventListener('change', function (e) {
|
|
@@ -6822,7 +6873,7 @@ var MultiSelectEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
6822
6873
|
value: function build() {
|
|
6823
6874
|
var _this2 = this;
|
|
6824
6875
|
var i;
|
|
6825
|
-
if (!this.options.compact) this.header = this.label = this.theme.
|
|
6876
|
+
if (!this.options.compact) this.header = this.label = this.theme.getLabelLike(this.getTitle(), this.isRequired());
|
|
6826
6877
|
if (this.schema.description) this.description = this.theme.getFormInputDescription(this.translateProperty(this.schema.description));
|
|
6827
6878
|
if (this.options.infoText) this.infoButton = this.theme.getInfoButton(this.translateProperty(this.options.infoText));
|
|
6828
6879
|
if (this.options.compact) this.container.classList.add('compact');
|
|
@@ -6846,6 +6897,7 @@ var MultiSelectEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
6846
6897
|
this.control = this.theme.getMultiCheckboxHolder(this.controls, this.label, this.description, this.infoButton);
|
|
6847
6898
|
this.inputs.controlgroup = this.inputs.controls = this.control; /* Enable error messages for checkboxes */
|
|
6848
6899
|
} else {
|
|
6900
|
+
if (!this.options.compact) this.header = this.label = this.theme.getFormInputLabel(this.getTitle(), this.isRequired());
|
|
6849
6901
|
this.input_type = 'select';
|
|
6850
6902
|
this.input = this.theme.getSelectInput(this.option_keys, true);
|
|
6851
6903
|
this.theme.setSelectOptions(this.input, this.option_keys, this.option_enum.map(function (e) {
|
|
@@ -6857,7 +6909,7 @@ var MultiSelectEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
6857
6909
|
for (i = 0; i < this.option_keys.length; i++) {
|
|
6858
6910
|
this.select_options[this.option_keys[i]] = this.input.children[i];
|
|
6859
6911
|
}
|
|
6860
|
-
this.control = this.theme.getFormControl(this.label, this.input, this.description, this.infoButton);
|
|
6912
|
+
this.control = this.theme.getFormControl(this.label, this.input, this.description, this.infoButton, this.formname);
|
|
6861
6913
|
}
|
|
6862
6914
|
if (this.schema.readOnly || this.schema.readonly) {
|
|
6863
6915
|
this.disable(true);
|
|
@@ -7998,7 +8050,7 @@ var ObjectEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
7998
8050
|
} else {
|
|
7999
8051
|
this.header = '';
|
|
8000
8052
|
if (!this.options.compact) {
|
|
8001
|
-
this.header = document.createElement('
|
|
8053
|
+
this.header = document.createElement('span');
|
|
8002
8054
|
this.header.textContent = this.getTitle();
|
|
8003
8055
|
}
|
|
8004
8056
|
this.title = this.theme.getHeader(this.header, this.getPathDepth());
|
|
@@ -8011,7 +8063,11 @@ var ObjectEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
8011
8063
|
|
|
8012
8064
|
/* Edit JSON modal */
|
|
8013
8065
|
this.editjson_holder = this.theme.getModal();
|
|
8066
|
+
this.editjson_textarea_label = this.theme.getHiddenLabel(this.translate('button_edit_json'));
|
|
8067
|
+
this.editjson_textarea_label.setAttribute('for', this.path + '-' + 'edit-json-textarea');
|
|
8014
8068
|
this.editjson_textarea = this.theme.getTextareaInput();
|
|
8069
|
+
this.editjson_textarea.setAttribute('id', this.path + '-' + 'edit-json-textarea');
|
|
8070
|
+
this.editjson_textarea.setAttribute('aria-labelledby', this.path + '-' + 'edit-json-textarea');
|
|
8015
8071
|
this.editjson_textarea.classList.add('je-edit-json--textarea');
|
|
8016
8072
|
this.editjson_save = this.getButton('button_save', 'save', 'button_save');
|
|
8017
8073
|
this.editjson_save.classList.add('json-editor-btntype-save');
|
|
@@ -8034,6 +8090,7 @@ var ObjectEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
8034
8090
|
e.stopPropagation();
|
|
8035
8091
|
_this7.hideEditJSON();
|
|
8036
8092
|
});
|
|
8093
|
+
this.editjson_holder.appendChild(this.editjson_textarea_label);
|
|
8037
8094
|
this.editjson_holder.appendChild(this.editjson_textarea);
|
|
8038
8095
|
this.editjson_holder.appendChild(this.editjson_save);
|
|
8039
8096
|
this.editjson_holder.appendChild(this.editjson_copy);
|
|
@@ -8047,7 +8104,11 @@ var ObjectEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
8047
8104
|
this.addproperty_add.classList.add('json-editor-btntype-add');
|
|
8048
8105
|
this.addproperty_input = this.theme.getFormInputField('text');
|
|
8049
8106
|
this.addproperty_input.setAttribute('placeholder', 'Property name...');
|
|
8107
|
+
this.addproperty_input_label = this.theme.getHiddenLabel(this.translate('button_properties'));
|
|
8108
|
+
this.addproperty_input_label.setAttribute('for', this.path + '-' + 'property-selector');
|
|
8050
8109
|
this.addproperty_input.classList.add('property-selector-input');
|
|
8110
|
+
this.addproperty_input.setAttribute('id', this.path + '-' + 'property-selector');
|
|
8111
|
+
this.addproperty_input.setAttribute('aria-labelledby', this.path + '-' + 'property-selector');
|
|
8051
8112
|
this.addproperty_add.addEventListener('click', function (e) {
|
|
8052
8113
|
e.preventDefault();
|
|
8053
8114
|
e.stopPropagation();
|
|
@@ -8064,7 +8125,7 @@ var ObjectEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
8064
8125
|
}
|
|
8065
8126
|
});
|
|
8066
8127
|
this.addproperty_input.addEventListener('input', function (e) {
|
|
8067
|
-
e.target.previousSibling.childNodes.forEach(function (value) {
|
|
8128
|
+
e.target.previousSibling.previousSibling.childNodes.forEach(function (value) {
|
|
8068
8129
|
var searchTerm = value.innerText;
|
|
8069
8130
|
var propertyTitle = e.target.value;
|
|
8070
8131
|
var caseSensitivePropertySearch = _this7.options.case_sensitive_property_search || _this7.jsoneditor.options.case_sensitive_property_search;
|
|
@@ -8080,6 +8141,7 @@ var ObjectEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
8080
8141
|
});
|
|
8081
8142
|
});
|
|
8082
8143
|
this.addproperty_holder.appendChild(this.addproperty_list);
|
|
8144
|
+
this.addproperty_holder.appendChild(this.addproperty_input_label);
|
|
8083
8145
|
this.addproperty_holder.appendChild(this.addproperty_input);
|
|
8084
8146
|
this.addproperty_holder.appendChild(this.addproperty_add);
|
|
8085
8147
|
var spacer = document.createElement('div');
|
|
@@ -8231,6 +8293,9 @@ var ObjectEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
8231
8293
|
/* Do it again now that we know the approximate heights of elements */
|
|
8232
8294
|
this.layoutEditors();
|
|
8233
8295
|
}
|
|
8296
|
+
if (this.schema.readOnly || this.schema.readonly) {
|
|
8297
|
+
this.disable();
|
|
8298
|
+
}
|
|
8234
8299
|
}
|
|
8235
8300
|
}, {
|
|
8236
8301
|
key: "deactivateNonRequiredProperties",
|
|
@@ -8341,7 +8406,7 @@ var ObjectEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
8341
8406
|
labelText = key;
|
|
8342
8407
|
}
|
|
8343
8408
|
var label = this.theme.getCheckboxLabel(labelText);
|
|
8344
|
-
var control = this.theme.getFormControl(label, checkbox);
|
|
8409
|
+
var control = this.theme.getFormControl(label, checkbox, null, null, this.path + '-' + key);
|
|
8345
8410
|
control.style.paddingBottom = control.style.marginBottom = control.style.paddingTop = control.style.marginTop = 0;
|
|
8346
8411
|
control.style.height = 'auto';
|
|
8347
8412
|
/* control.style.overflowY = 'hidden'; */
|
|
@@ -8791,43 +8856,47 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
8791
8856
|
/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
8792
8857
|
/* harmony import */ var core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es.symbol.description.js */ "./node_modules/core-js/modules/es.symbol.description.js");
|
|
8793
8858
|
/* harmony import */ var core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
8794
|
-
/* harmony import */ var
|
|
8795
|
-
/* harmony import */ var
|
|
8796
|
-
/* harmony import */ var
|
|
8797
|
-
/* harmony import */ var
|
|
8798
|
-
/* harmony import */ var
|
|
8799
|
-
/* harmony import */ var
|
|
8800
|
-
/* harmony import */ var
|
|
8801
|
-
/* harmony import */ var
|
|
8802
|
-
/* harmony import */ var
|
|
8803
|
-
/* harmony import */ var
|
|
8804
|
-
/* harmony import */ var
|
|
8805
|
-
/* harmony import */ var
|
|
8806
|
-
/* harmony import */ var
|
|
8807
|
-
/* harmony import */ var
|
|
8808
|
-
/* harmony import */ var
|
|
8809
|
-
/* harmony import */ var
|
|
8810
|
-
/* harmony import */ var
|
|
8811
|
-
/* harmony import */ var
|
|
8812
|
-
/* harmony import */ var
|
|
8813
|
-
/* harmony import */ var
|
|
8814
|
-
/* harmony import */ var
|
|
8815
|
-
/* harmony import */ var
|
|
8816
|
-
/* harmony import */ var
|
|
8817
|
-
/* harmony import */ var
|
|
8818
|
-
/* harmony import */ var
|
|
8819
|
-
/* harmony import */ var
|
|
8820
|
-
/* harmony import */ var
|
|
8821
|
-
/* harmony import */ var
|
|
8822
|
-
/* harmony import */ var
|
|
8823
|
-
/* harmony import */ var
|
|
8824
|
-
/* harmony import */ var
|
|
8825
|
-
/* harmony import */ var
|
|
8826
|
-
/* harmony import */ var
|
|
8827
|
-
/* harmony import */ var
|
|
8828
|
-
/* harmony import */ var
|
|
8829
|
-
/* harmony import */ var
|
|
8830
|
-
/* harmony import */ var
|
|
8859
|
+
/* harmony import */ var core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! core-js/modules/es.array.for-each.js */ "./node_modules/core-js/modules/es.array.for-each.js");
|
|
8860
|
+
/* harmony import */ var core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_2__);
|
|
8861
|
+
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! core-js/modules/es.object.to-string.js */ "./node_modules/core-js/modules/es.object.to-string.js");
|
|
8862
|
+
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_3__);
|
|
8863
|
+
/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! core-js/modules/web.dom-collections.for-each.js */ "./node_modules/core-js/modules/web.dom-collections.for-each.js");
|
|
8864
|
+
/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_4__);
|
|
8865
|
+
/* harmony import */ var core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! core-js/modules/es.array.concat.js */ "./node_modules/core-js/modules/es.array.concat.js");
|
|
8866
|
+
/* harmony import */ var core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_5__);
|
|
8867
|
+
/* harmony import */ var core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! core-js/modules/es.function.name.js */ "./node_modules/core-js/modules/es.function.name.js");
|
|
8868
|
+
/* harmony import */ var core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_6__);
|
|
8869
|
+
/* harmony import */ var core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! core-js/modules/es.object.set-prototype-of.js */ "./node_modules/core-js/modules/es.object.set-prototype-of.js");
|
|
8870
|
+
/* harmony import */ var core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_7__);
|
|
8871
|
+
/* harmony import */ var core_js_modules_es_function_bind_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! core-js/modules/es.function.bind.js */ "./node_modules/core-js/modules/es.function.bind.js");
|
|
8872
|
+
/* harmony import */ var core_js_modules_es_function_bind_js__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_function_bind_js__WEBPACK_IMPORTED_MODULE_8__);
|
|
8873
|
+
/* harmony import */ var core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! core-js/modules/es.object.get-prototype-of.js */ "./node_modules/core-js/modules/es.object.get-prototype-of.js");
|
|
8874
|
+
/* harmony import */ var core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_9__);
|
|
8875
|
+
/* harmony import */ var core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! core-js/modules/es.reflect.construct.js */ "./node_modules/core-js/modules/es.reflect.construct.js");
|
|
8876
|
+
/* harmony import */ var core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_10__);
|
|
8877
|
+
/* harmony import */ var core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! core-js/modules/es.object.create.js */ "./node_modules/core-js/modules/es.object.create.js");
|
|
8878
|
+
/* harmony import */ var core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_11__);
|
|
8879
|
+
/* harmony import */ var core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! core-js/modules/es.object.define-property.js */ "./node_modules/core-js/modules/es.object.define-property.js");
|
|
8880
|
+
/* harmony import */ var core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_12__);
|
|
8881
|
+
/* harmony import */ var core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! core-js/modules/es.reflect.get.js */ "./node_modules/core-js/modules/es.reflect.get.js");
|
|
8882
|
+
/* harmony import */ var core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_13__);
|
|
8883
|
+
/* harmony import */ var core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! core-js/modules/es.object.get-own-property-descriptor.js */ "./node_modules/core-js/modules/es.object.get-own-property-descriptor.js");
|
|
8884
|
+
/* harmony import */ var core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_14__);
|
|
8885
|
+
/* harmony import */ var core_js_modules_es_symbol_to_primitive_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! core-js/modules/es.symbol.to-primitive.js */ "./node_modules/core-js/modules/es.symbol.to-primitive.js");
|
|
8886
|
+
/* harmony import */ var core_js_modules_es_symbol_to_primitive_js__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_to_primitive_js__WEBPACK_IMPORTED_MODULE_15__);
|
|
8887
|
+
/* harmony import */ var core_js_modules_es_date_to_primitive_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! core-js/modules/es.date.to-primitive.js */ "./node_modules/core-js/modules/es.date.to-primitive.js");
|
|
8888
|
+
/* harmony import */ var core_js_modules_es_date_to_primitive_js__WEBPACK_IMPORTED_MODULE_16___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_date_to_primitive_js__WEBPACK_IMPORTED_MODULE_16__);
|
|
8889
|
+
/* harmony import */ var core_js_modules_es_number_constructor_js__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! core-js/modules/es.number.constructor.js */ "./node_modules/core-js/modules/es.number.constructor.js");
|
|
8890
|
+
/* harmony import */ var core_js_modules_es_number_constructor_js__WEBPACK_IMPORTED_MODULE_17___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_number_constructor_js__WEBPACK_IMPORTED_MODULE_17__);
|
|
8891
|
+
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! core-js/modules/es.symbol.iterator.js */ "./node_modules/core-js/modules/es.symbol.iterator.js");
|
|
8892
|
+
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_18___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_18__);
|
|
8893
|
+
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! core-js/modules/es.array.iterator.js */ "./node_modules/core-js/modules/es.array.iterator.js");
|
|
8894
|
+
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_19___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_19__);
|
|
8895
|
+
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! core-js/modules/es.string.iterator.js */ "./node_modules/core-js/modules/es.string.iterator.js");
|
|
8896
|
+
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_20___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_20__);
|
|
8897
|
+
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! core-js/modules/web.dom-collections.iterator.js */ "./node_modules/core-js/modules/web.dom-collections.iterator.js");
|
|
8898
|
+
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_21___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_21__);
|
|
8899
|
+
/* harmony import */ var _select_js__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! ./select.js */ "./src/editors/select.js");
|
|
8831
8900
|
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
8832
8901
|
|
|
8833
8902
|
|
|
@@ -8847,6 +8916,8 @@ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" =
|
|
|
8847
8916
|
|
|
8848
8917
|
|
|
8849
8918
|
|
|
8919
|
+
|
|
8920
|
+
|
|
8850
8921
|
|
|
8851
8922
|
|
|
8852
8923
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
@@ -8890,6 +8961,9 @@ var RadioEditor = /*#__PURE__*/function (_SelectEditor) {
|
|
|
8890
8961
|
var radioInputEventhandler = function radioInputEventhandler(e) {
|
|
8891
8962
|
_this.setValue(e.currentTarget.value);
|
|
8892
8963
|
_this.onChange(true);
|
|
8964
|
+
_this.radioGroup.forEach(function (radio) {
|
|
8965
|
+
radio.checked = radio.value === _this.getValue();
|
|
8966
|
+
});
|
|
8893
8967
|
};
|
|
8894
8968
|
for (var i = 0; i < this.enum_values.length; i++) {
|
|
8895
8969
|
/* form radio elements */
|
|
@@ -8983,7 +9057,7 @@ var RadioEditor = /*#__PURE__*/function (_SelectEditor) {
|
|
|
8983
9057
|
}
|
|
8984
9058
|
}]);
|
|
8985
9059
|
return RadioEditor;
|
|
8986
|
-
}(
|
|
9060
|
+
}(_select_js__WEBPACK_IMPORTED_MODULE_22__.SelectEditor);
|
|
8987
9061
|
|
|
8988
9062
|
/***/ }),
|
|
8989
9063
|
|
|
@@ -9457,7 +9531,7 @@ var SelectEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
9457
9531
|
e.stopPropagation();
|
|
9458
9532
|
_this2.onInputChange();
|
|
9459
9533
|
});
|
|
9460
|
-
this.control = this.theme.getFormControl(this.label, this.input, this.description, this.infoButton);
|
|
9534
|
+
this.control = this.theme.getFormControl(this.label, this.input, this.description, this.infoButton, this.formname);
|
|
9461
9535
|
this.container.appendChild(this.control);
|
|
9462
9536
|
this.value = this.enum_values[0];
|
|
9463
9537
|
|
|
@@ -10629,7 +10703,7 @@ var StarratingEditor = /*#__PURE__*/function (_StringEditor) {
|
|
|
10629
10703
|
key: "build",
|
|
10630
10704
|
value: function build() {
|
|
10631
10705
|
var _this = this;
|
|
10632
|
-
if (!this.options.compact) this.header = this.label = this.theme.
|
|
10706
|
+
if (!this.options.compact) this.header = this.label = this.theme.getLabelLike(this.getTitle(), this.isRequired());
|
|
10633
10707
|
if (this.schema.description) this.description = this.theme.getFormInputDescription(this.translateProperty(this.schema.description));
|
|
10634
10708
|
if (this.options.infoText) this.infoButton = this.theme.getInfoButton(this.translateProperty(this.options.infoText));
|
|
10635
10709
|
if (this.options.compact) this.container.classList.add('compact');
|
|
@@ -10668,6 +10742,9 @@ var StarratingEditor = /*#__PURE__*/function (_StringEditor) {
|
|
|
10668
10742
|
if (this.options.displayValue) {
|
|
10669
10743
|
radioLabel.classList.add('starrating-display-enabled');
|
|
10670
10744
|
}
|
|
10745
|
+
var radioText = this.theme.getHiddenText('label');
|
|
10746
|
+
radioText.textContent = i;
|
|
10747
|
+
radioLabel.appendChild(radioText);
|
|
10671
10748
|
this.ratingContainer.appendChild(radioInput);
|
|
10672
10749
|
this.ratingContainer.appendChild(radioLabel);
|
|
10673
10750
|
}
|
|
@@ -11013,7 +11090,6 @@ var StringEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
11013
11090
|
if (this.jsoneditor.options.use_name_attributes) {
|
|
11014
11091
|
this.input.setAttribute('name', this.formname);
|
|
11015
11092
|
}
|
|
11016
|
-
this.input.setAttribute('aria-label', this.formname);
|
|
11017
11093
|
}
|
|
11018
11094
|
}, {
|
|
11019
11095
|
key: "unregister",
|
|
@@ -11046,7 +11122,9 @@ var StringEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
11046
11122
|
if (this.adjust_height) this.adjust_height(this.input);
|
|
11047
11123
|
|
|
11048
11124
|
/* Bubble this setValue to parents if the value changed */
|
|
11049
|
-
|
|
11125
|
+
if (!fromTemplate) {
|
|
11126
|
+
this.onChange(changed);
|
|
11127
|
+
}
|
|
11050
11128
|
|
|
11051
11129
|
/* Return object with changed state and sanitized value for use in editors that extend this */
|
|
11052
11130
|
return {
|
|
@@ -11102,7 +11180,8 @@ var StringEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
11102
11180
|
if (max % this.schema.multipleOf) max = Math.floor(max / this.schema.multipleOf) * this.schema.multipleOf;
|
|
11103
11181
|
step = this.schema.multipleOf;
|
|
11104
11182
|
}
|
|
11105
|
-
this.input = this.theme.getRangeInput(min, max, step);
|
|
11183
|
+
this.input = this.theme.getRangeInput(min, max, step, this.description, this.formname);
|
|
11184
|
+
this.input.setAttribute('id', this.formname);
|
|
11106
11185
|
/* HTML5 Input type */
|
|
11107
11186
|
} else {
|
|
11108
11187
|
this.input_type = 'text';
|
|
@@ -11554,7 +11633,7 @@ var TableEditor = /*#__PURE__*/function (_ArrayEditor) {
|
|
|
11554
11633
|
this.item_default = tmp.getDefault();
|
|
11555
11634
|
this.width = tmp.getNumColumns() + 2;
|
|
11556
11635
|
if (!this.options.compact) {
|
|
11557
|
-
this.header = document.createElement('
|
|
11636
|
+
this.header = document.createElement('span');
|
|
11558
11637
|
this.header.textContent = this.getTitle();
|
|
11559
11638
|
this.title = this.theme.getHeader(this.header, this.getPathDepth());
|
|
11560
11639
|
this.container.appendChild(this.title);
|
|
@@ -11598,8 +11677,9 @@ var TableEditor = /*#__PURE__*/function (_ArrayEditor) {
|
|
|
11598
11677
|
this.row_holder.innerHTML = '';
|
|
11599
11678
|
|
|
11600
11679
|
/* Row Controls column */
|
|
11601
|
-
this.controls_header_cell = this.theme.getTableHeaderCell('
|
|
11680
|
+
this.controls_header_cell = this.theme.getTableHeaderCell(this.translate('table_controls'));
|
|
11602
11681
|
this.controls_header_cell.setAttribute('aria-hidden', 'true');
|
|
11682
|
+
this.controls_header_cell.style.visibility = 'hidden';
|
|
11603
11683
|
this.header_row.appendChild(this.controls_header_cell);
|
|
11604
11684
|
|
|
11605
11685
|
/* Add controls */
|
|
@@ -15312,10 +15392,18 @@ var AbstractTheme = /*#__PURE__*/function () {
|
|
|
15312
15392
|
if (req) el.classList.add('required');
|
|
15313
15393
|
return el;
|
|
15314
15394
|
}
|
|
15395
|
+
}, {
|
|
15396
|
+
key: "getLabelLike",
|
|
15397
|
+
value: function getLabelLike(text, req) {
|
|
15398
|
+
var el = document.createElement('b');
|
|
15399
|
+
el.appendChild(document.createTextNode(text));
|
|
15400
|
+
if (req) el.classList.add('required');
|
|
15401
|
+
return el;
|
|
15402
|
+
}
|
|
15315
15403
|
}, {
|
|
15316
15404
|
key: "getHeader",
|
|
15317
15405
|
value: function getHeader(text, pathDepth) {
|
|
15318
|
-
var el = document.createElement('
|
|
15406
|
+
var el = document.createElement('span');
|
|
15319
15407
|
if (typeof text === 'string') {
|
|
15320
15408
|
el.textContent = text;
|
|
15321
15409
|
} else {
|
|
@@ -15389,7 +15477,7 @@ var AbstractTheme = /*#__PURE__*/function () {
|
|
|
15389
15477
|
}
|
|
15390
15478
|
}, {
|
|
15391
15479
|
key: "getFormRadioControl",
|
|
15392
|
-
value: function getFormRadioControl(label, input, compact) {
|
|
15480
|
+
value: function getFormRadioControl(label, input, compact, formName) {
|
|
15393
15481
|
var el = document.createElement('div');
|
|
15394
15482
|
el.appendChild(label);
|
|
15395
15483
|
input.style.width = 'auto';
|
|
@@ -15397,6 +15485,11 @@ var AbstractTheme = /*#__PURE__*/function () {
|
|
|
15397
15485
|
if (compact) {
|
|
15398
15486
|
el.classList.add('je-radio-control--compact');
|
|
15399
15487
|
}
|
|
15488
|
+
if (input.tagName.toLowerCase() !== 'div' && formName && label && input) {
|
|
15489
|
+
input.setAttribute('id', formName);
|
|
15490
|
+
input.setAttribute('aria-labelledby', formName);
|
|
15491
|
+
label.setAttribute('for', formName);
|
|
15492
|
+
}
|
|
15400
15493
|
return el;
|
|
15401
15494
|
}
|
|
15402
15495
|
}, {
|
|
@@ -15442,13 +15535,41 @@ var AbstractTheme = /*#__PURE__*/function () {
|
|
|
15442
15535
|
el.classList.add('je-textarea');
|
|
15443
15536
|
return el;
|
|
15444
15537
|
}
|
|
15538
|
+
}, {
|
|
15539
|
+
key: "getHiddenLabel",
|
|
15540
|
+
value: function getHiddenLabel(text) {
|
|
15541
|
+
var el = document.createElement('label');
|
|
15542
|
+
el.textContent = text;
|
|
15543
|
+
el.setAttribute('style', 'position: absolute;width: 1px;height: 1px;padding: 0;margin: -1px;overflow: hidden;clip: rect(0,0,0,0);border: 0;');
|
|
15544
|
+
return el;
|
|
15545
|
+
}
|
|
15546
|
+
}, {
|
|
15547
|
+
key: "visuallyHidden",
|
|
15548
|
+
value: function visuallyHidden(element) {
|
|
15549
|
+
if (!element) {
|
|
15550
|
+
return;
|
|
15551
|
+
}
|
|
15552
|
+
element.setAttribute('style', 'position: absolute;width: 1px;height: 1px;padding: 0;margin: -1px;overflow: hidden;clip: rect(0,0,0,0);border: 0;');
|
|
15553
|
+
}
|
|
15554
|
+
}, {
|
|
15555
|
+
key: "getHiddenText",
|
|
15556
|
+
value: function getHiddenText(text) {
|
|
15557
|
+
var el = document.createElement('span');
|
|
15558
|
+
el.textContent = text;
|
|
15559
|
+
el.setAttribute('style', 'position: absolute;width: 1px;height: 1px;padding: 0;margin: -1px;overflow: hidden;clip: rect(0,0,0,0);border: 0;');
|
|
15560
|
+
return el;
|
|
15561
|
+
}
|
|
15445
15562
|
}, {
|
|
15446
15563
|
key: "getRangeInput",
|
|
15447
|
-
value: function getRangeInput(min, max, step) {
|
|
15564
|
+
value: function getRangeInput(min, max, step, description, formName) {
|
|
15448
15565
|
var el = this.getFormInputField('range');
|
|
15449
15566
|
el.setAttribute('min', min);
|
|
15450
15567
|
el.setAttribute('max', max);
|
|
15451
15568
|
el.setAttribute('step', step);
|
|
15569
|
+
if (description) {
|
|
15570
|
+
description.setAttribute('id', formName + '-description');
|
|
15571
|
+
el.setAttribute('aria-describedby', formName + '-description');
|
|
15572
|
+
}
|
|
15452
15573
|
return el;
|
|
15453
15574
|
}
|
|
15454
15575
|
}, {
|
|
@@ -15508,7 +15629,7 @@ var AbstractTheme = /*#__PURE__*/function () {
|
|
|
15508
15629
|
}
|
|
15509
15630
|
}, {
|
|
15510
15631
|
key: "getRangeOutput",
|
|
15511
|
-
value: function getRangeOutput(input
|
|
15632
|
+
value: function getRangeOutput(input) {
|
|
15512
15633
|
var output = document.createElement('output');
|
|
15513
15634
|
var updateOutput = function updateOutput(e) {
|
|
15514
15635
|
output.value = e.currentTarget.value;
|
|
@@ -15553,6 +15674,14 @@ var AbstractTheme = /*#__PURE__*/function () {
|
|
|
15553
15674
|
if (infoText && label) label.appendChild(infoText);
|
|
15554
15675
|
el.appendChild(input);
|
|
15555
15676
|
}
|
|
15677
|
+
if (input.tagName.toLowerCase() !== 'div' && input && label && formName) {
|
|
15678
|
+
label.setAttribute('for', formName);
|
|
15679
|
+
input.setAttribute('id', formName);
|
|
15680
|
+
}
|
|
15681
|
+
if (input.tagName.toLowerCase() !== 'div' && input && description) {
|
|
15682
|
+
description.setAttribute('id', formName + '-description');
|
|
15683
|
+
input.setAttribute('aria-describedby', formName + '-description');
|
|
15684
|
+
}
|
|
15556
15685
|
if (description) el.appendChild(description);
|
|
15557
15686
|
return el;
|
|
15558
15687
|
}
|
|
@@ -15689,7 +15818,9 @@ var AbstractTheme = /*#__PURE__*/function () {
|
|
|
15689
15818
|
}
|
|
15690
15819
|
}, {
|
|
15691
15820
|
key: "addInputError",
|
|
15692
|
-
value: function addInputError(input, text) {
|
|
15821
|
+
value: function addInputError(input, text) {
|
|
15822
|
+
input.errmsg.setAttribute('role', 'alert');
|
|
15823
|
+
}
|
|
15693
15824
|
}, {
|
|
15694
15825
|
key: "removeInputError",
|
|
15695
15826
|
value: function removeInputError(input) {}
|
|
@@ -16045,6 +16176,7 @@ var barebonesTheme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
16045
16176
|
}
|
|
16046
16177
|
input.errmsg.innerHTML = '';
|
|
16047
16178
|
input.errmsg.appendChild(document.createTextNode(text));
|
|
16179
|
+
input.errmsg.setAttribute('role', 'alert');
|
|
16048
16180
|
}
|
|
16049
16181
|
}, {
|
|
16050
16182
|
key: "removeInputError",
|
|
@@ -16198,11 +16330,6 @@ var bootstrap3Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
16198
16330
|
if (this.closest(input, '.compact')) {
|
|
16199
16331
|
input.controlgroup.style.marginBottom = 0;
|
|
16200
16332
|
}
|
|
16201
|
-
if (this.queuedInputErrorText) {
|
|
16202
|
-
var text = this.queuedInputErrorText;
|
|
16203
|
-
delete this.queuedInputErrorText;
|
|
16204
|
-
this.addInputError(input, text);
|
|
16205
|
-
}
|
|
16206
16333
|
|
|
16207
16334
|
/* TODO: use bootstrap slider */
|
|
16208
16335
|
}
|
|
@@ -16215,9 +16342,9 @@ var bootstrap3Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
16215
16342
|
}
|
|
16216
16343
|
}, {
|
|
16217
16344
|
key: "getRangeInput",
|
|
16218
|
-
value: function getRangeInput(min, max, step) {
|
|
16345
|
+
value: function getRangeInput(min, max, step, description, formName) {
|
|
16219
16346
|
/* TODO: use better slider */
|
|
16220
|
-
return _get(_getPrototypeOf(bootstrap3Theme.prototype), "getRangeInput", this).call(this, min, max, step);
|
|
16347
|
+
return _get(_getPrototypeOf(bootstrap3Theme.prototype), "getRangeInput", this).call(this, min, max, step, description, formName);
|
|
16221
16348
|
}
|
|
16222
16349
|
}, {
|
|
16223
16350
|
key: "getFormInputField",
|
|
@@ -16228,9 +16355,33 @@ var bootstrap3Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
16228
16355
|
}
|
|
16229
16356
|
return el;
|
|
16230
16357
|
}
|
|
16358
|
+
}, {
|
|
16359
|
+
key: "getHiddenLabel",
|
|
16360
|
+
value: function getHiddenLabel(text) {
|
|
16361
|
+
var el = document.createElement('label');
|
|
16362
|
+
el.textContent = text;
|
|
16363
|
+
el.classList.add('sr-only');
|
|
16364
|
+
return el;
|
|
16365
|
+
}
|
|
16366
|
+
}, {
|
|
16367
|
+
key: "visuallyHidden",
|
|
16368
|
+
value: function visuallyHidden(element) {
|
|
16369
|
+
if (!element) {
|
|
16370
|
+
return;
|
|
16371
|
+
}
|
|
16372
|
+
element.classList.add('sr-only');
|
|
16373
|
+
}
|
|
16374
|
+
}, {
|
|
16375
|
+
key: "getHiddenText",
|
|
16376
|
+
value: function getHiddenText(text) {
|
|
16377
|
+
var el = document.createElement('span');
|
|
16378
|
+
el.textContent = text;
|
|
16379
|
+
el.classList.add('sr-only');
|
|
16380
|
+
return el;
|
|
16381
|
+
}
|
|
16231
16382
|
}, {
|
|
16232
16383
|
key: "getFormControl",
|
|
16233
|
-
value: function getFormControl(label, input, description, infoText) {
|
|
16384
|
+
value: function getFormControl(label, input, description, infoText, formName) {
|
|
16234
16385
|
var group = document.createElement('div');
|
|
16235
16386
|
if (label && (input.type === 'checkbox' || input.type === 'radio')) {
|
|
16236
16387
|
group.classList.add(input.type);
|
|
@@ -16247,6 +16398,14 @@ var bootstrap3Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
16247
16398
|
group.appendChild(input);
|
|
16248
16399
|
}
|
|
16249
16400
|
if (description) group.appendChild(description);
|
|
16401
|
+
if (input.tagName.toLowerCase() !== 'div' && input && label && formName) {
|
|
16402
|
+
label.setAttribute('for', formName);
|
|
16403
|
+
input.setAttribute('id', formName);
|
|
16404
|
+
}
|
|
16405
|
+
if (input.tagName.toLowerCase() !== 'div' && input && description) {
|
|
16406
|
+
description.setAttribute('id', formName + '-description');
|
|
16407
|
+
input.setAttribute('aria-describedby', formName + '-description');
|
|
16408
|
+
}
|
|
16250
16409
|
return group;
|
|
16251
16410
|
}
|
|
16252
16411
|
}, {
|
|
@@ -16293,6 +16452,18 @@ var bootstrap3Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
16293
16452
|
if (window.DOMPurify) el.innerHTML = window.DOMPurify.sanitize(text);else el.textContent = this.cleanText(text);
|
|
16294
16453
|
return el;
|
|
16295
16454
|
}
|
|
16455
|
+
}, {
|
|
16456
|
+
key: "getHeader",
|
|
16457
|
+
value: function getHeader(text, pathDepth) {
|
|
16458
|
+
var el = document.createElement('span');
|
|
16459
|
+
el.classList.add('h3');
|
|
16460
|
+
if (typeof text === 'string') {
|
|
16461
|
+
el.textContent = text;
|
|
16462
|
+
} else {
|
|
16463
|
+
el.appendChild(text);
|
|
16464
|
+
}
|
|
16465
|
+
return el;
|
|
16466
|
+
}
|
|
16296
16467
|
}, {
|
|
16297
16468
|
key: "getHeaderButtonHolder",
|
|
16298
16469
|
value: function getHeaderButtonHolder() {
|
|
@@ -16334,7 +16505,6 @@ var bootstrap3Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
16334
16505
|
key: "addInputError",
|
|
16335
16506
|
value: function addInputError(input, text) {
|
|
16336
16507
|
if (!input.controlgroup) {
|
|
16337
|
-
this.queuedInputErrorText = text;
|
|
16338
16508
|
return;
|
|
16339
16509
|
}
|
|
16340
16510
|
input.controlgroup.classList.add('has-error');
|
|
@@ -16346,13 +16516,11 @@ var bootstrap3Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
16346
16516
|
input.errmsg.style.display = '';
|
|
16347
16517
|
}
|
|
16348
16518
|
input.errmsg.textContent = text;
|
|
16519
|
+
input.errmsg.setAttribute('role', 'alert');
|
|
16349
16520
|
}
|
|
16350
16521
|
}, {
|
|
16351
16522
|
key: "removeInputError",
|
|
16352
16523
|
value: function removeInputError(input) {
|
|
16353
|
-
if (!input.controlgroup) {
|
|
16354
|
-
delete this.queuedInputErrorText;
|
|
16355
|
-
}
|
|
16356
16524
|
if (!input.errmsg) return;
|
|
16357
16525
|
input.errmsg.style.display = 'none';
|
|
16358
16526
|
input.controlgroup.classList.remove('has-error');
|
|
@@ -16548,57 +16716,51 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
16548
16716
|
/* harmony import */ var core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
16549
16717
|
/* harmony import */ var core_js_modules_es_number_constructor_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es.number.constructor.js */ "./node_modules/core-js/modules/es.number.constructor.js");
|
|
16550
16718
|
/* harmony import */ var core_js_modules_es_number_constructor_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_number_constructor_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
16551
|
-
/* harmony import */ var
|
|
16552
|
-
/* harmony import */ var
|
|
16553
|
-
/* harmony import */ var
|
|
16554
|
-
/* harmony import */ var
|
|
16555
|
-
/* harmony import */ var
|
|
16556
|
-
/* harmony import */ var
|
|
16557
|
-
/* harmony import */ var
|
|
16558
|
-
/* harmony import */ var
|
|
16559
|
-
/* harmony import */ var
|
|
16560
|
-
/* harmony import */ var
|
|
16561
|
-
/* harmony import */ var
|
|
16562
|
-
/* harmony import */ var
|
|
16563
|
-
/* harmony import */ var
|
|
16564
|
-
/* harmony import */ var
|
|
16565
|
-
/* harmony import */ var
|
|
16566
|
-
/* harmony import */ var
|
|
16567
|
-
/* harmony import */ var
|
|
16568
|
-
/* harmony import */ var
|
|
16569
|
-
/* harmony import */ var
|
|
16570
|
-
/* harmony import */ var
|
|
16571
|
-
/* harmony import */ var
|
|
16572
|
-
/* harmony import */ var
|
|
16573
|
-
/* harmony import */ var
|
|
16574
|
-
/* harmony import */ var
|
|
16575
|
-
/* harmony import */ var
|
|
16576
|
-
/* harmony import */ var
|
|
16577
|
-
/* harmony import */ var
|
|
16578
|
-
/* harmony import */ var
|
|
16579
|
-
/* harmony import */ var
|
|
16580
|
-
/* harmony import */ var
|
|
16581
|
-
/* harmony import */ var
|
|
16582
|
-
/* harmony import */ var
|
|
16583
|
-
/* harmony import */ var
|
|
16584
|
-
/* harmony import */ var
|
|
16585
|
-
/* harmony import */ var
|
|
16586
|
-
/* harmony import */ var
|
|
16587
|
-
/* harmony import */ var
|
|
16588
|
-
/* harmony import */ var
|
|
16589
|
-
/* harmony import */ var
|
|
16590
|
-
/* harmony import */ var
|
|
16591
|
-
/* harmony import */ var
|
|
16592
|
-
/* harmony import */ var
|
|
16593
|
-
/* harmony import */ var
|
|
16594
|
-
/* harmony import */ var
|
|
16595
|
-
/* harmony import */ var
|
|
16596
|
-
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_24___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_24__);
|
|
16597
|
-
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(/*! core-js/modules/web.dom-collections.iterator.js */ "./node_modules/core-js/modules/web.dom-collections.iterator.js");
|
|
16598
|
-
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_25___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_25__);
|
|
16599
|
-
/* harmony import */ var _theme_js__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(/*! ../theme.js */ "./src/theme.js");
|
|
16600
|
-
/* harmony import */ var _bootstrap4_css_js__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(/*! ./bootstrap4.css.js */ "./src/themes/bootstrap4.css.js");
|
|
16601
|
-
/* harmony import */ var _utilities__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(/*! ../utilities */ "./src/utilities.js");
|
|
16719
|
+
/* harmony import */ var core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! core-js/modules/es.array.for-each.js */ "./node_modules/core-js/modules/es.array.for-each.js");
|
|
16720
|
+
/* harmony import */ var core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_2__);
|
|
16721
|
+
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! core-js/modules/es.object.to-string.js */ "./node_modules/core-js/modules/es.object.to-string.js");
|
|
16722
|
+
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_3__);
|
|
16723
|
+
/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! core-js/modules/web.dom-collections.for-each.js */ "./node_modules/core-js/modules/web.dom-collections.for-each.js");
|
|
16724
|
+
/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_4__);
|
|
16725
|
+
/* harmony import */ var core_js_modules_es_object_values_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! core-js/modules/es.object.values.js */ "./node_modules/core-js/modules/es.object.values.js");
|
|
16726
|
+
/* harmony import */ var core_js_modules_es_object_values_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_values_js__WEBPACK_IMPORTED_MODULE_5__);
|
|
16727
|
+
/* harmony import */ var core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! core-js/modules/es.array.concat.js */ "./node_modules/core-js/modules/es.array.concat.js");
|
|
16728
|
+
/* harmony import */ var core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_6__);
|
|
16729
|
+
/* harmony import */ var core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! core-js/modules/es.object.set-prototype-of.js */ "./node_modules/core-js/modules/es.object.set-prototype-of.js");
|
|
16730
|
+
/* harmony import */ var core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_7__);
|
|
16731
|
+
/* harmony import */ var core_js_modules_es_function_bind_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! core-js/modules/es.function.bind.js */ "./node_modules/core-js/modules/es.function.bind.js");
|
|
16732
|
+
/* harmony import */ var core_js_modules_es_function_bind_js__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_function_bind_js__WEBPACK_IMPORTED_MODULE_8__);
|
|
16733
|
+
/* harmony import */ var core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! core-js/modules/es.object.get-prototype-of.js */ "./node_modules/core-js/modules/es.object.get-prototype-of.js");
|
|
16734
|
+
/* harmony import */ var core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_9__);
|
|
16735
|
+
/* harmony import */ var core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! core-js/modules/es.reflect.construct.js */ "./node_modules/core-js/modules/es.reflect.construct.js");
|
|
16736
|
+
/* harmony import */ var core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_10__);
|
|
16737
|
+
/* harmony import */ var core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! core-js/modules/es.object.create.js */ "./node_modules/core-js/modules/es.object.create.js");
|
|
16738
|
+
/* harmony import */ var core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_11__);
|
|
16739
|
+
/* harmony import */ var core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! core-js/modules/es.object.define-property.js */ "./node_modules/core-js/modules/es.object.define-property.js");
|
|
16740
|
+
/* harmony import */ var core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_12__);
|
|
16741
|
+
/* harmony import */ var core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! core-js/modules/es.reflect.get.js */ "./node_modules/core-js/modules/es.reflect.get.js");
|
|
16742
|
+
/* harmony import */ var core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_13__);
|
|
16743
|
+
/* harmony import */ var core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! core-js/modules/es.object.get-own-property-descriptor.js */ "./node_modules/core-js/modules/es.object.get-own-property-descriptor.js");
|
|
16744
|
+
/* harmony import */ var core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_14__);
|
|
16745
|
+
/* harmony import */ var core_js_modules_es_symbol_to_primitive_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! core-js/modules/es.symbol.to-primitive.js */ "./node_modules/core-js/modules/es.symbol.to-primitive.js");
|
|
16746
|
+
/* harmony import */ var core_js_modules_es_symbol_to_primitive_js__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_to_primitive_js__WEBPACK_IMPORTED_MODULE_15__);
|
|
16747
|
+
/* harmony import */ var core_js_modules_es_date_to_primitive_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! core-js/modules/es.date.to-primitive.js */ "./node_modules/core-js/modules/es.date.to-primitive.js");
|
|
16748
|
+
/* harmony import */ var core_js_modules_es_date_to_primitive_js__WEBPACK_IMPORTED_MODULE_16___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_date_to_primitive_js__WEBPACK_IMPORTED_MODULE_16__);
|
|
16749
|
+
/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! core-js/modules/es.symbol.js */ "./node_modules/core-js/modules/es.symbol.js");
|
|
16750
|
+
/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_17___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_17__);
|
|
16751
|
+
/* harmony import */ var core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! core-js/modules/es.symbol.description.js */ "./node_modules/core-js/modules/es.symbol.description.js");
|
|
16752
|
+
/* harmony import */ var core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_18___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_18__);
|
|
16753
|
+
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! core-js/modules/es.symbol.iterator.js */ "./node_modules/core-js/modules/es.symbol.iterator.js");
|
|
16754
|
+
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_19___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_19__);
|
|
16755
|
+
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! core-js/modules/es.array.iterator.js */ "./node_modules/core-js/modules/es.array.iterator.js");
|
|
16756
|
+
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_20___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_20__);
|
|
16757
|
+
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! core-js/modules/es.string.iterator.js */ "./node_modules/core-js/modules/es.string.iterator.js");
|
|
16758
|
+
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_21___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_21__);
|
|
16759
|
+
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! core-js/modules/web.dom-collections.iterator.js */ "./node_modules/core-js/modules/web.dom-collections.iterator.js");
|
|
16760
|
+
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_22___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_22__);
|
|
16761
|
+
/* harmony import */ var _theme_js__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! ../theme.js */ "./src/theme.js");
|
|
16762
|
+
/* harmony import */ var _bootstrap4_css_js__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(/*! ./bootstrap4.css.js */ "./src/themes/bootstrap4.css.js");
|
|
16763
|
+
/* harmony import */ var _utilities__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(/*! ../utilities */ "./src/utilities.js");
|
|
16602
16764
|
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
16603
16765
|
|
|
16604
16766
|
|
|
@@ -16619,9 +16781,6 @@ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" =
|
|
|
16619
16781
|
|
|
16620
16782
|
|
|
16621
16783
|
|
|
16622
|
-
|
|
16623
|
-
|
|
16624
|
-
|
|
16625
16784
|
|
|
16626
16785
|
|
|
16627
16786
|
|
|
@@ -16729,8 +16888,8 @@ var bootstrap4Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
16729
16888
|
}
|
|
16730
16889
|
}, {
|
|
16731
16890
|
key: "getRangeInput",
|
|
16732
|
-
value: function getRangeInput(min, max, step) {
|
|
16733
|
-
var el = _get(_getPrototypeOf(bootstrap4Theme.prototype), "getRangeInput", this).call(this, min, max, step);
|
|
16891
|
+
value: function getRangeInput(min, max, step, description, formName) {
|
|
16892
|
+
var el = _get(_getPrototypeOf(bootstrap4Theme.prototype), "getRangeInput", this).call(this, min, max, step, description, formName);
|
|
16734
16893
|
if (this.options.custom_forms === true) {
|
|
16735
16894
|
el.classList.remove('form-control');
|
|
16736
16895
|
el.classList.add('custom-range');
|
|
@@ -16793,7 +16952,7 @@ var bootstrap4Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
16793
16952
|
} else {
|
|
16794
16953
|
input.stepDown();
|
|
16795
16954
|
}
|
|
16796
|
-
(0,
|
|
16955
|
+
(0,_utilities__WEBPACK_IMPORTED_MODULE_25__.trigger)(input, 'change');
|
|
16797
16956
|
});
|
|
16798
16957
|
plusBtn.addEventListener('click', function () {
|
|
16799
16958
|
if (!input.getAttribute('initialized')) {
|
|
@@ -16805,7 +16964,7 @@ var bootstrap4Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
16805
16964
|
} else {
|
|
16806
16965
|
input.stepUp();
|
|
16807
16966
|
}
|
|
16808
|
-
(0,
|
|
16967
|
+
(0,_utilities__WEBPACK_IMPORTED_MODULE_25__.trigger)(input, 'change');
|
|
16809
16968
|
});
|
|
16810
16969
|
return inputGroup;
|
|
16811
16970
|
}
|
|
@@ -16826,9 +16985,33 @@ var bootstrap4Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
16826
16985
|
}
|
|
16827
16986
|
return el;
|
|
16828
16987
|
}
|
|
16988
|
+
}, {
|
|
16989
|
+
key: "getHiddenLabel",
|
|
16990
|
+
value: function getHiddenLabel(text) {
|
|
16991
|
+
var el = document.createElement('label');
|
|
16992
|
+
el.textContent = text;
|
|
16993
|
+
el.classList.add('sr-only');
|
|
16994
|
+
return el;
|
|
16995
|
+
}
|
|
16996
|
+
}, {
|
|
16997
|
+
key: "visuallyHidden",
|
|
16998
|
+
value: function visuallyHidden(element) {
|
|
16999
|
+
if (!element) {
|
|
17000
|
+
return;
|
|
17001
|
+
}
|
|
17002
|
+
element.classList.add('sr-only');
|
|
17003
|
+
}
|
|
17004
|
+
}, {
|
|
17005
|
+
key: "getHiddenText",
|
|
17006
|
+
value: function getHiddenText(text) {
|
|
17007
|
+
var el = document.createElement('span');
|
|
17008
|
+
el.textContent = text;
|
|
17009
|
+
el.classList.add('sr-only');
|
|
17010
|
+
return el;
|
|
17011
|
+
}
|
|
16829
17012
|
}, {
|
|
16830
17013
|
key: "getFormControl",
|
|
16831
|
-
value: function getFormControl(label, input, description, infoText) {
|
|
17014
|
+
value: function getFormControl(label, input, description, infoText, formName) {
|
|
16832
17015
|
var group = document.createElement('div');
|
|
16833
17016
|
group.classList.add('form-group');
|
|
16834
17017
|
if (label && (input.type === 'checkbox' || input.type === 'radio')) {
|
|
@@ -16847,9 +17030,6 @@ var bootstrap4Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
16847
17030
|
check.classList.add('custom-radio');
|
|
16848
17031
|
}
|
|
16849
17032
|
}
|
|
16850
|
-
var unique = (Date.now() * Math.random()).toFixed(0);
|
|
16851
|
-
input.setAttribute('id', unique);
|
|
16852
|
-
label.setAttribute('for', unique);
|
|
16853
17033
|
check.appendChild(input);
|
|
16854
17034
|
check.appendChild(label);
|
|
16855
17035
|
if (infoText) check.appendChild(infoText);
|
|
@@ -16864,6 +17044,14 @@ var bootstrap4Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
16864
17044
|
if (description) {
|
|
16865
17045
|
group.appendChild(description);
|
|
16866
17046
|
}
|
|
17047
|
+
if (input.tagName.toLowerCase() !== 'div' && input && label && formName) {
|
|
17048
|
+
label.setAttribute('for', formName);
|
|
17049
|
+
input.setAttribute('id', formName);
|
|
17050
|
+
}
|
|
17051
|
+
if (input.tagName.toLowerCase() !== 'div' && input && description) {
|
|
17052
|
+
description.setAttribute('id', formName + '-description');
|
|
17053
|
+
input.setAttribute('aria-describedby', formName + '-description');
|
|
17054
|
+
}
|
|
16867
17055
|
return group;
|
|
16868
17056
|
}
|
|
16869
17057
|
}, {
|
|
@@ -17029,10 +17217,8 @@ var bootstrap4Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
17029
17217
|
}, {
|
|
17030
17218
|
key: "getHeader",
|
|
17031
17219
|
value: function getHeader(text, pathDepth) {
|
|
17032
|
-
|
|
17033
|
-
|
|
17034
|
-
|
|
17035
|
-
var el = document.createElement('h3');
|
|
17220
|
+
var el = document.createElement('span');
|
|
17221
|
+
el.classList.add('h3');
|
|
17036
17222
|
el.classList.add('card-title');
|
|
17037
17223
|
el.classList.add('level-' + pathDepth);
|
|
17038
17224
|
if (typeof text === 'string') {
|
|
@@ -17041,9 +17227,6 @@ var bootstrap4Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
17041
17227
|
el.appendChild(text);
|
|
17042
17228
|
}
|
|
17043
17229
|
el.style.display = 'inline-block';
|
|
17044
|
-
|
|
17045
|
-
/* cardHeader.appendChild(el) */
|
|
17046
|
-
|
|
17047
17230
|
return el;
|
|
17048
17231
|
}
|
|
17049
17232
|
}, {
|
|
@@ -17120,6 +17303,7 @@ var bootstrap4Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
17120
17303
|
}
|
|
17121
17304
|
input.errmsg.style.display = 'block';
|
|
17122
17305
|
input.errmsg.textContent = text;
|
|
17306
|
+
input.errmsg.setAttribute('role', 'alert');
|
|
17123
17307
|
}
|
|
17124
17308
|
}, {
|
|
17125
17309
|
key: "removeInputError",
|
|
@@ -17313,10 +17497,10 @@ var bootstrap4Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
17313
17497
|
}
|
|
17314
17498
|
}]);
|
|
17315
17499
|
return bootstrap4Theme;
|
|
17316
|
-
}(
|
|
17500
|
+
}(_theme_js__WEBPACK_IMPORTED_MODULE_23__.AbstractTheme);
|
|
17317
17501
|
|
|
17318
17502
|
/* Custom stylesheet rules. format: "selector" : "CSS rules" */
|
|
17319
|
-
bootstrap4Theme.rules =
|
|
17503
|
+
bootstrap4Theme.rules = _bootstrap4_css_js__WEBPACK_IMPORTED_MODULE_24__["default"];
|
|
17320
17504
|
|
|
17321
17505
|
/***/ }),
|
|
17322
17506
|
|
|
@@ -17371,57 +17555,51 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
17371
17555
|
/* harmony import */ var core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
17372
17556
|
/* harmony import */ var core_js_modules_es_number_constructor_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es.number.constructor.js */ "./node_modules/core-js/modules/es.number.constructor.js");
|
|
17373
17557
|
/* harmony import */ var core_js_modules_es_number_constructor_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_number_constructor_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
17374
|
-
/* harmony import */ var
|
|
17375
|
-
/* harmony import */ var
|
|
17376
|
-
/* harmony import */ var
|
|
17377
|
-
/* harmony import */ var
|
|
17378
|
-
/* harmony import */ var
|
|
17379
|
-
/* harmony import */ var
|
|
17380
|
-
/* harmony import */ var
|
|
17381
|
-
/* harmony import */ var
|
|
17382
|
-
/* harmony import */ var
|
|
17383
|
-
/* harmony import */ var
|
|
17384
|
-
/* harmony import */ var
|
|
17385
|
-
/* harmony import */ var
|
|
17386
|
-
/* harmony import */ var
|
|
17387
|
-
/* harmony import */ var
|
|
17388
|
-
/* harmony import */ var
|
|
17389
|
-
/* harmony import */ var
|
|
17390
|
-
/* harmony import */ var
|
|
17391
|
-
/* harmony import */ var
|
|
17392
|
-
/* harmony import */ var
|
|
17393
|
-
/* harmony import */ var
|
|
17394
|
-
/* harmony import */ var
|
|
17395
|
-
/* harmony import */ var
|
|
17396
|
-
/* harmony import */ var
|
|
17397
|
-
/* harmony import */ var
|
|
17398
|
-
/* harmony import */ var
|
|
17399
|
-
/* harmony import */ var
|
|
17400
|
-
/* harmony import */ var
|
|
17401
|
-
/* harmony import */ var
|
|
17402
|
-
/* harmony import */ var
|
|
17403
|
-
/* harmony import */ var
|
|
17404
|
-
/* harmony import */ var
|
|
17405
|
-
/* harmony import */ var
|
|
17406
|
-
/* harmony import */ var
|
|
17407
|
-
/* harmony import */ var
|
|
17408
|
-
/* harmony import */ var
|
|
17409
|
-
/* harmony import */ var
|
|
17410
|
-
/* harmony import */ var
|
|
17411
|
-
/* harmony import */ var
|
|
17412
|
-
/* harmony import */ var
|
|
17413
|
-
/* harmony import */ var
|
|
17414
|
-
/* harmony import */ var
|
|
17415
|
-
/* harmony import */ var
|
|
17416
|
-
/* harmony import */ var
|
|
17417
|
-
/* harmony import */ var
|
|
17418
|
-
/* harmony import */ var
|
|
17419
|
-
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_24___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_24__);
|
|
17420
|
-
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(/*! core-js/modules/web.dom-collections.iterator.js */ "./node_modules/core-js/modules/web.dom-collections.iterator.js");
|
|
17421
|
-
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_25___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_25__);
|
|
17422
|
-
/* harmony import */ var _theme_js__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(/*! ../theme.js */ "./src/theme.js");
|
|
17423
|
-
/* harmony import */ var _bootstrap5_css_js__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(/*! ./bootstrap5.css.js */ "./src/themes/bootstrap5.css.js");
|
|
17424
|
-
/* harmony import */ var _utilities__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(/*! ../utilities */ "./src/utilities.js");
|
|
17558
|
+
/* harmony import */ var core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! core-js/modules/es.array.for-each.js */ "./node_modules/core-js/modules/es.array.for-each.js");
|
|
17559
|
+
/* harmony import */ var core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_2__);
|
|
17560
|
+
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! core-js/modules/es.object.to-string.js */ "./node_modules/core-js/modules/es.object.to-string.js");
|
|
17561
|
+
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_3__);
|
|
17562
|
+
/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! core-js/modules/web.dom-collections.for-each.js */ "./node_modules/core-js/modules/web.dom-collections.for-each.js");
|
|
17563
|
+
/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_4__);
|
|
17564
|
+
/* harmony import */ var core_js_modules_es_object_values_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! core-js/modules/es.object.values.js */ "./node_modules/core-js/modules/es.object.values.js");
|
|
17565
|
+
/* harmony import */ var core_js_modules_es_object_values_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_values_js__WEBPACK_IMPORTED_MODULE_5__);
|
|
17566
|
+
/* harmony import */ var core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! core-js/modules/es.array.concat.js */ "./node_modules/core-js/modules/es.array.concat.js");
|
|
17567
|
+
/* harmony import */ var core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_6__);
|
|
17568
|
+
/* harmony import */ var core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! core-js/modules/es.object.set-prototype-of.js */ "./node_modules/core-js/modules/es.object.set-prototype-of.js");
|
|
17569
|
+
/* harmony import */ var core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_7__);
|
|
17570
|
+
/* harmony import */ var core_js_modules_es_function_bind_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! core-js/modules/es.function.bind.js */ "./node_modules/core-js/modules/es.function.bind.js");
|
|
17571
|
+
/* harmony import */ var core_js_modules_es_function_bind_js__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_function_bind_js__WEBPACK_IMPORTED_MODULE_8__);
|
|
17572
|
+
/* harmony import */ var core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! core-js/modules/es.object.get-prototype-of.js */ "./node_modules/core-js/modules/es.object.get-prototype-of.js");
|
|
17573
|
+
/* harmony import */ var core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_9__);
|
|
17574
|
+
/* harmony import */ var core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! core-js/modules/es.reflect.construct.js */ "./node_modules/core-js/modules/es.reflect.construct.js");
|
|
17575
|
+
/* harmony import */ var core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_10__);
|
|
17576
|
+
/* harmony import */ var core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! core-js/modules/es.object.create.js */ "./node_modules/core-js/modules/es.object.create.js");
|
|
17577
|
+
/* harmony import */ var core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_11__);
|
|
17578
|
+
/* harmony import */ var core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! core-js/modules/es.object.define-property.js */ "./node_modules/core-js/modules/es.object.define-property.js");
|
|
17579
|
+
/* harmony import */ var core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_12__);
|
|
17580
|
+
/* harmony import */ var core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! core-js/modules/es.reflect.get.js */ "./node_modules/core-js/modules/es.reflect.get.js");
|
|
17581
|
+
/* harmony import */ var core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_13__);
|
|
17582
|
+
/* harmony import */ var core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! core-js/modules/es.object.get-own-property-descriptor.js */ "./node_modules/core-js/modules/es.object.get-own-property-descriptor.js");
|
|
17583
|
+
/* harmony import */ var core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_14__);
|
|
17584
|
+
/* harmony import */ var core_js_modules_es_symbol_to_primitive_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! core-js/modules/es.symbol.to-primitive.js */ "./node_modules/core-js/modules/es.symbol.to-primitive.js");
|
|
17585
|
+
/* harmony import */ var core_js_modules_es_symbol_to_primitive_js__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_to_primitive_js__WEBPACK_IMPORTED_MODULE_15__);
|
|
17586
|
+
/* harmony import */ var core_js_modules_es_date_to_primitive_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! core-js/modules/es.date.to-primitive.js */ "./node_modules/core-js/modules/es.date.to-primitive.js");
|
|
17587
|
+
/* harmony import */ var core_js_modules_es_date_to_primitive_js__WEBPACK_IMPORTED_MODULE_16___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_date_to_primitive_js__WEBPACK_IMPORTED_MODULE_16__);
|
|
17588
|
+
/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! core-js/modules/es.symbol.js */ "./node_modules/core-js/modules/es.symbol.js");
|
|
17589
|
+
/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_17___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_17__);
|
|
17590
|
+
/* harmony import */ var core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! core-js/modules/es.symbol.description.js */ "./node_modules/core-js/modules/es.symbol.description.js");
|
|
17591
|
+
/* harmony import */ var core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_18___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_18__);
|
|
17592
|
+
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! core-js/modules/es.symbol.iterator.js */ "./node_modules/core-js/modules/es.symbol.iterator.js");
|
|
17593
|
+
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_19___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_19__);
|
|
17594
|
+
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! core-js/modules/es.array.iterator.js */ "./node_modules/core-js/modules/es.array.iterator.js");
|
|
17595
|
+
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_20___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_20__);
|
|
17596
|
+
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! core-js/modules/es.string.iterator.js */ "./node_modules/core-js/modules/es.string.iterator.js");
|
|
17597
|
+
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_21___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_21__);
|
|
17598
|
+
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! core-js/modules/web.dom-collections.iterator.js */ "./node_modules/core-js/modules/web.dom-collections.iterator.js");
|
|
17599
|
+
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_22___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_22__);
|
|
17600
|
+
/* harmony import */ var _theme_js__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! ../theme.js */ "./src/theme.js");
|
|
17601
|
+
/* harmony import */ var _bootstrap5_css_js__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(/*! ./bootstrap5.css.js */ "./src/themes/bootstrap5.css.js");
|
|
17602
|
+
/* harmony import */ var _utilities__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(/*! ../utilities */ "./src/utilities.js");
|
|
17425
17603
|
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
17426
17604
|
|
|
17427
17605
|
|
|
@@ -17442,9 +17620,6 @@ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" =
|
|
|
17442
17620
|
|
|
17443
17621
|
|
|
17444
17622
|
|
|
17445
|
-
|
|
17446
|
-
|
|
17447
|
-
|
|
17448
17623
|
|
|
17449
17624
|
|
|
17450
17625
|
|
|
@@ -17545,8 +17720,8 @@ var bootstrap5Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
17545
17720
|
}
|
|
17546
17721
|
}, {
|
|
17547
17722
|
key: "getRangeInput",
|
|
17548
|
-
value: function getRangeInput(min, max, step) {
|
|
17549
|
-
var el = _get(_getPrototypeOf(bootstrap5Theme.prototype), "getRangeInput", this).call(this, min, max, step);
|
|
17723
|
+
value: function getRangeInput(min, max, step, description, formName) {
|
|
17724
|
+
var el = _get(_getPrototypeOf(bootstrap5Theme.prototype), "getRangeInput", this).call(this, min, max, step, description, formName);
|
|
17550
17725
|
el.classList.remove('form-control');
|
|
17551
17726
|
el.classList.add('form-range');
|
|
17552
17727
|
return el;
|
|
@@ -17601,7 +17776,7 @@ var bootstrap5Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
17601
17776
|
} else {
|
|
17602
17777
|
input.stepDown();
|
|
17603
17778
|
}
|
|
17604
|
-
(0,
|
|
17779
|
+
(0,_utilities__WEBPACK_IMPORTED_MODULE_25__.trigger)(input, 'change');
|
|
17605
17780
|
});
|
|
17606
17781
|
plusBtn.addEventListener('click', function () {
|
|
17607
17782
|
if (!input.getAttribute('initialized')) {
|
|
@@ -17613,7 +17788,7 @@ var bootstrap5Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
17613
17788
|
} else {
|
|
17614
17789
|
input.stepUp();
|
|
17615
17790
|
}
|
|
17616
|
-
(0,
|
|
17791
|
+
(0,_utilities__WEBPACK_IMPORTED_MODULE_25__.trigger)(input, 'change');
|
|
17617
17792
|
});
|
|
17618
17793
|
return inputGroup;
|
|
17619
17794
|
}
|
|
@@ -17630,7 +17805,7 @@ var bootstrap5Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
17630
17805
|
}
|
|
17631
17806
|
}, {
|
|
17632
17807
|
key: "getFormControl",
|
|
17633
|
-
value: function getFormControl(label, input, description, infoText) {
|
|
17808
|
+
value: function getFormControl(label, input, description, infoText, formName) {
|
|
17634
17809
|
var group = document.createElement('div');
|
|
17635
17810
|
group.classList.add('form-group');
|
|
17636
17811
|
if (label && (input.type === 'checkbox' || input.type === 'radio')) {
|
|
@@ -17638,9 +17813,14 @@ var bootstrap5Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
17638
17813
|
check.classList.add('form-check');
|
|
17639
17814
|
input.classList.add('form-check-input');
|
|
17640
17815
|
label.classList.add('form-check-label');
|
|
17641
|
-
|
|
17642
|
-
|
|
17643
|
-
|
|
17816
|
+
if (input.tagName.toLowerCase() !== 'div' && input && label && formName) {
|
|
17817
|
+
label.setAttribute('for', formName);
|
|
17818
|
+
input.setAttribute('id', formName);
|
|
17819
|
+
}
|
|
17820
|
+
if (input.tagName.toLowerCase() !== 'div' && input && description) {
|
|
17821
|
+
description.setAttribute('id', formName + '-description');
|
|
17822
|
+
input.setAttribute('aria-describedby', formName + '-description');
|
|
17823
|
+
}
|
|
17644
17824
|
check.appendChild(input);
|
|
17645
17825
|
check.appendChild(label);
|
|
17646
17826
|
if (infoText) check.appendChild(infoText);
|
|
@@ -17658,6 +17838,30 @@ var bootstrap5Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
17658
17838
|
}
|
|
17659
17839
|
return group;
|
|
17660
17840
|
}
|
|
17841
|
+
}, {
|
|
17842
|
+
key: "getHiddenLabel",
|
|
17843
|
+
value: function getHiddenLabel(text) {
|
|
17844
|
+
var el = document.createElement('label');
|
|
17845
|
+
el.textContent = text;
|
|
17846
|
+
el.classList.add('visually-hidden');
|
|
17847
|
+
return el;
|
|
17848
|
+
}
|
|
17849
|
+
}, {
|
|
17850
|
+
key: "visuallyHidden",
|
|
17851
|
+
value: function visuallyHidden(element) {
|
|
17852
|
+
if (!element) {
|
|
17853
|
+
return;
|
|
17854
|
+
}
|
|
17855
|
+
element.classList.add('visually-hidden');
|
|
17856
|
+
}
|
|
17857
|
+
}, {
|
|
17858
|
+
key: "getHiddenText",
|
|
17859
|
+
value: function getHiddenText(text) {
|
|
17860
|
+
var el = document.createElement('span');
|
|
17861
|
+
el.textContent = text;
|
|
17862
|
+
el.classList.add('sr-only');
|
|
17863
|
+
return el;
|
|
17864
|
+
}
|
|
17661
17865
|
}, {
|
|
17662
17866
|
key: "getInfoButton",
|
|
17663
17867
|
value: function getInfoButton(text) {
|
|
@@ -17799,7 +18003,8 @@ var bootstrap5Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
17799
18003
|
}, {
|
|
17800
18004
|
key: "getHeader",
|
|
17801
18005
|
value: function getHeader(text, pathDepth) {
|
|
17802
|
-
var el = document.createElement('
|
|
18006
|
+
var el = document.createElement('span');
|
|
18007
|
+
el.classList.add('h3');
|
|
17803
18008
|
el.classList.add('card-title');
|
|
17804
18009
|
el.classList.add('level-' + pathDepth);
|
|
17805
18010
|
if (typeof text === 'string') {
|
|
@@ -17884,6 +18089,7 @@ var bootstrap5Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
17884
18089
|
}
|
|
17885
18090
|
input.errmsg.style.display = 'block';
|
|
17886
18091
|
input.errmsg.textContent = text;
|
|
18092
|
+
input.errmsg.setAttribute('role', 'alert');
|
|
17887
18093
|
}
|
|
17888
18094
|
}, {
|
|
17889
18095
|
key: "removeInputError",
|
|
@@ -18074,10 +18280,10 @@ var bootstrap5Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
18074
18280
|
}
|
|
18075
18281
|
}]);
|
|
18076
18282
|
return bootstrap5Theme;
|
|
18077
|
-
}(
|
|
18283
|
+
}(_theme_js__WEBPACK_IMPORTED_MODULE_23__.AbstractTheme);
|
|
18078
18284
|
|
|
18079
18285
|
/* Custom stylesheet rules. format: "selector" : "CSS rules" */
|
|
18080
|
-
bootstrap5Theme.rules =
|
|
18286
|
+
bootstrap5Theme.rules = _bootstrap5_css_js__WEBPACK_IMPORTED_MODULE_24__["default"];
|
|
18081
18287
|
|
|
18082
18288
|
/***/ }),
|
|
18083
18289
|
|
|
@@ -18263,6 +18469,7 @@ var htmlTheme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
18263
18469
|
}
|
|
18264
18470
|
input.errmsg.innerHTML = '';
|
|
18265
18471
|
input.errmsg.appendChild(document.createTextNode(text));
|
|
18472
|
+
input.errmsg.setAttribute('role', 'alert');
|
|
18266
18473
|
}
|
|
18267
18474
|
}, {
|
|
18268
18475
|
key: "removeInputError",
|
|
@@ -18912,7 +19119,7 @@ var spectreTheme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
18912
19119
|
}, {
|
|
18913
19120
|
key: "getHeader",
|
|
18914
19121
|
value: function getHeader(text, pathDepth) {
|
|
18915
|
-
var el = document.createElement('
|
|
19122
|
+
var el = document.createElement('span');
|
|
18916
19123
|
if (typeof text === 'string') {
|
|
18917
19124
|
el.textContent = text;
|
|
18918
19125
|
} else {
|
|
@@ -19011,14 +19218,11 @@ var spectreTheme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
19011
19218
|
/* Create input field for type="range" */
|
|
19012
19219
|
}, {
|
|
19013
19220
|
key: "getRangeInput",
|
|
19014
|
-
value: function getRangeInput(min, max, step) {
|
|
19015
|
-
var el = this.
|
|
19221
|
+
value: function getRangeInput(min, max, step, description, formName) {
|
|
19222
|
+
var el = _get(_getPrototypeOf(spectreTheme.prototype), "getRangeInput", this).call(this, min, max, step, description, formName);
|
|
19016
19223
|
el.classList.add('slider');
|
|
19017
19224
|
el.classList.remove('form-input');
|
|
19018
19225
|
el.setAttribute('oninput', 'this.setAttribute("value", this.value)');
|
|
19019
|
-
el.setAttribute('min', min);
|
|
19020
|
-
el.setAttribute('max', max);
|
|
19021
|
-
el.setAttribute('step', step);
|
|
19022
19226
|
return el;
|
|
19023
19227
|
}
|
|
19024
19228
|
}, {
|
|
@@ -19048,7 +19252,7 @@ var spectreTheme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
19048
19252
|
}
|
|
19049
19253
|
}, {
|
|
19050
19254
|
key: "getFormControl",
|
|
19051
|
-
value: function getFormControl(label, input, description, infoText) {
|
|
19255
|
+
value: function getFormControl(label, input, description, infoText, formName) {
|
|
19052
19256
|
var group = document.createElement('div');
|
|
19053
19257
|
group.classList.add('form-group');
|
|
19054
19258
|
if (label && (input.type === 'checkbox' || input.type === 'radio')) {
|
|
@@ -19067,6 +19271,14 @@ var spectreTheme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
19067
19271
|
if (this.options.input_size === 'small') input.classList.add('input-sm', 'select-sm');else if (this.options.input_size === 'large') input.classList.add('input-lg', 'select-lg');
|
|
19068
19272
|
if (input.type !== 'checkbox') group.appendChild(input);
|
|
19069
19273
|
if (description) group.appendChild(description);
|
|
19274
|
+
if (input.tagName.toLowerCase() !== 'div' && input && label && formName) {
|
|
19275
|
+
label.setAttribute('for', formName);
|
|
19276
|
+
input.setAttribute('id', formName);
|
|
19277
|
+
}
|
|
19278
|
+
if (input.tagName.toLowerCase() !== 'div' && input && description) {
|
|
19279
|
+
description.setAttribute('id', formName + '-description');
|
|
19280
|
+
input.setAttribute('aria-describedby', formName + '-description');
|
|
19281
|
+
}
|
|
19070
19282
|
return group;
|
|
19071
19283
|
}
|
|
19072
19284
|
|
|
@@ -19232,6 +19444,7 @@ var spectreTheme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
19232
19444
|
}
|
|
19233
19445
|
input.errmsg.classList.remove('d-hide');
|
|
19234
19446
|
input.errmsg.textContent = text;
|
|
19447
|
+
input.errmsg.setAttribute('role', 'alert');
|
|
19235
19448
|
}
|
|
19236
19449
|
}, {
|
|
19237
19450
|
key: "removeInputError",
|
|
@@ -21199,9 +21412,9 @@ var Validator = /*#__PURE__*/function () {
|
|
|
21199
21412
|
return [];
|
|
21200
21413
|
};
|
|
21201
21414
|
var validatorRx = {
|
|
21202
|
-
date: /^(\d{4}\D\d{2}\D\d{2})
|
|
21203
|
-
time: /^(\d{2}:\d{2}(?::\d{2})?)
|
|
21204
|
-
'datetime-local': /^(\d{4}\D\d{2}\D\d{2}[ T]\d{2}:\d{2}(?::\d{2})?)
|
|
21415
|
+
date: /^(\d{4}\D\d{2}\D\d{2})$/,
|
|
21416
|
+
time: /^(\d{2}:\d{2}(?::\d{2})?)$/,
|
|
21417
|
+
'datetime-local': /^(\d{4}\D\d{2}\D\d{2}[ T]\d{2}:\d{2}(?::\d{2})?)$/
|
|
21205
21418
|
};
|
|
21206
21419
|
var format = {
|
|
21207
21420
|
date: '"YYYY-MM-DD"',
|
|
@@ -27293,30 +27506,6 @@ $({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT }, {
|
|
|
27293
27506
|
});
|
|
27294
27507
|
|
|
27295
27508
|
|
|
27296
|
-
/***/ }),
|
|
27297
|
-
|
|
27298
|
-
/***/ "./node_modules/core-js/modules/es.date.now.js":
|
|
27299
|
-
/*!*****************************************************!*\
|
|
27300
|
-
!*** ./node_modules/core-js/modules/es.date.now.js ***!
|
|
27301
|
-
\*****************************************************/
|
|
27302
|
-
/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => {
|
|
27303
|
-
|
|
27304
|
-
// TODO: Remove from `core-js@4`
|
|
27305
|
-
var $ = __webpack_require__(/*! ../internals/export */ "./node_modules/core-js/internals/export.js");
|
|
27306
|
-
var uncurryThis = __webpack_require__(/*! ../internals/function-uncurry-this */ "./node_modules/core-js/internals/function-uncurry-this.js");
|
|
27307
|
-
|
|
27308
|
-
var $Date = Date;
|
|
27309
|
-
var thisTimeValue = uncurryThis($Date.prototype.getTime);
|
|
27310
|
-
|
|
27311
|
-
// `Date.now` method
|
|
27312
|
-
// https://tc39.es/ecma262/#sec-date.now
|
|
27313
|
-
$({ target: 'Date', stat: true }, {
|
|
27314
|
-
now: function now() {
|
|
27315
|
-
return thisTimeValue(new $Date());
|
|
27316
|
-
}
|
|
27317
|
-
});
|
|
27318
|
-
|
|
27319
|
-
|
|
27320
27509
|
/***/ }),
|
|
27321
27510
|
|
|
27322
27511
|
/***/ "./node_modules/core-js/modules/es.date.to-iso-string.js":
|