@json-editor/json-editor 2.6.1 → 2.9.0-beta.0
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/.github/workflows/build.yml +12 -3
- package/CHANGELOG.md +32 -0
- package/README.md +148 -18
- package/dist/jsoneditor.js +2 -2
- package/dist/nonmin/jsoneditor.js +2920 -643
- package/dist/nonmin/jsoneditor.js.map +1 -1
- package/docs/form-submission.html +162 -0
- package/package.json +4 -3
- package/release-notes.md +2 -0
- package/src/core.js +36 -37
- package/src/defaults.js +10 -2
- package/src/editors/array.js +12 -1
- package/src/editors/autocomplete.js +4 -3
- package/src/editors/button.js +1 -1
- package/src/editors/checkbox.js +3 -1
- package/src/editors/hidden.js +3 -1
- package/src/editors/multiselect.js +17 -6
- package/src/editors/radio.js +8 -3
- package/src/editors/select.js +3 -1
- package/src/editors/signature.js +3 -1
- package/src/editors/string.js +7 -1
- package/src/editors/table.js +20 -2
- package/src/editors/upload.js +1 -1
- package/src/editors/uuid.js +2 -12
- package/src/iconlib.js +1 -1
- package/src/schemaloader.js +319 -103
- package/src/style.css +3 -0
- package/src/style.css.js +1 -1
- package/src/theme.js +0 -2
- package/src/themes/bootstrap3.js +1 -0
- package/src/themes/spectre.js +2 -1
- package/src/utilities.js +18 -0
- package/src/validator.js +36 -34
- package/tests/codeceptjs/codecept.json +1 -1
- package/tests/codeceptjs/core_test.js +125 -0
- package/tests/codeceptjs/editors/advanced_test.js +1 -1
- package/tests/codeceptjs/editors/array_test.js +74 -0
- package/tests/codeceptjs/editors/autocomplete_test.js +16 -0
- package/tests/codeceptjs/editors/button_test.js +10 -3
- package/tests/codeceptjs/editors/integer_test.js +7 -2
- package/tests/codeceptjs/editors/jodit_test.js +3 -3
- package/tests/codeceptjs/editors/range_test.js +12 -0
- package/tests/codeceptjs/editors/uuid_test.js +31 -4
- package/tests/docker-compose.yml +1 -1
- package/tests/fixtures/definitions.json +22 -0
- package/tests/fixtures/properties.json +20 -0
- package/tests/pages/array-checkboxes-infotext.html +52 -0
- package/tests/pages/array-move-events.html +4 -2
- package/tests/pages/array-unique-items-sort.html +78 -0
- package/tests/pages/autocomplete.html +69 -0
- package/tests/pages/button-icons.html +38 -0
- package/tests/pages/core.html +4 -2
- package/tests/pages/error-messages.html +47 -0
- package/tests/pages/grid-strict.html +6 -10
- package/tests/pages/grid.html +0 -4
- package/tests/pages/issues/issue-gh-812.html +4 -2
- package/tests/pages/meta_schema.json +14 -0
- package/tests/pages/object-required-properties.html +7 -7
- package/tests/pages/range.html +60 -0
- package/tests/pages/ready.html +43 -0
- package/tests/pages/references.html +168 -0
- package/tests/pages/string-simplemde-editor.html +81 -0
- package/tests/pages/table-move-events.html +4 -1
- package/tests/pages/urn.html +11 -8
- package/tests/pages/use-name-attributes.html +206 -0
- package/tests/pages/uuid.html +89 -50
- package/tests/pages/validation-messages.json +705 -0
- package/tests/unit/core.spec.js +79 -66
- package/tests/unit/editor.spec.js +20 -8
- package/tests/unit/editors/array.spec.js +3 -2
- package/tests/unit/editors/object.spec.js +3 -1
- package/tests/unit/editors/table.spec.js +4 -2
- package/tests/unit/schemaloader.spec.js +181 -103
- package/tests/unit/validator.spec.js +2 -2
|
@@ -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.9.0-beta.0"
|
|
7
7
|
* * @author Jeremy Dorn
|
|
8
8
|
* * @see https://github.com/jdorn/json-editor/
|
|
9
9
|
* * @see https://github.com/json-editor/json-editor
|
|
@@ -192,6 +192,22 @@ module.exports = function (S, index, unicode) {
|
|
|
192
192
|
};
|
|
193
193
|
|
|
194
194
|
|
|
195
|
+
/***/ }),
|
|
196
|
+
|
|
197
|
+
/***/ "./node_modules/core-js/internals/an-instance.js":
|
|
198
|
+
/*!*******************************************************!*\
|
|
199
|
+
!*** ./node_modules/core-js/internals/an-instance.js ***!
|
|
200
|
+
\*******************************************************/
|
|
201
|
+
/*! no static exports found */
|
|
202
|
+
/***/ (function(module, exports) {
|
|
203
|
+
|
|
204
|
+
module.exports = function (it, Constructor, name) {
|
|
205
|
+
if (!(it instanceof Constructor)) {
|
|
206
|
+
throw TypeError('Incorrect ' + (name ? name + ' ' : '') + 'invocation');
|
|
207
|
+
} return it;
|
|
208
|
+
};
|
|
209
|
+
|
|
210
|
+
|
|
195
211
|
/***/ }),
|
|
196
212
|
|
|
197
213
|
/***/ "./node_modules/core-js/internals/an-object.js":
|
|
@@ -833,6 +849,49 @@ module.exports = function (object, key, value) {
|
|
|
833
849
|
};
|
|
834
850
|
|
|
835
851
|
|
|
852
|
+
/***/ }),
|
|
853
|
+
|
|
854
|
+
/***/ "./node_modules/core-js/internals/date-to-iso-string.js":
|
|
855
|
+
/*!**************************************************************!*\
|
|
856
|
+
!*** ./node_modules/core-js/internals/date-to-iso-string.js ***!
|
|
857
|
+
\**************************************************************/
|
|
858
|
+
/*! no static exports found */
|
|
859
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
860
|
+
|
|
861
|
+
"use strict";
|
|
862
|
+
|
|
863
|
+
var fails = __webpack_require__(/*! ../internals/fails */ "./node_modules/core-js/internals/fails.js");
|
|
864
|
+
var padStart = __webpack_require__(/*! ../internals/string-pad */ "./node_modules/core-js/internals/string-pad.js").start;
|
|
865
|
+
|
|
866
|
+
var abs = Math.abs;
|
|
867
|
+
var DatePrototype = Date.prototype;
|
|
868
|
+
var getTime = DatePrototype.getTime;
|
|
869
|
+
var nativeDateToISOString = DatePrototype.toISOString;
|
|
870
|
+
|
|
871
|
+
// `Date.prototype.toISOString` method implementation
|
|
872
|
+
// https://tc39.es/ecma262/#sec-date.prototype.toisostring
|
|
873
|
+
// PhantomJS / old WebKit fails here:
|
|
874
|
+
module.exports = (fails(function () {
|
|
875
|
+
return nativeDateToISOString.call(new Date(-5e13 - 1)) != '0385-07-25T07:06:39.999Z';
|
|
876
|
+
}) || !fails(function () {
|
|
877
|
+
nativeDateToISOString.call(new Date(NaN));
|
|
878
|
+
})) ? function toISOString() {
|
|
879
|
+
if (!isFinite(getTime.call(this))) throw RangeError('Invalid time value');
|
|
880
|
+
var date = this;
|
|
881
|
+
var year = date.getUTCFullYear();
|
|
882
|
+
var milliseconds = date.getUTCMilliseconds();
|
|
883
|
+
var sign = year < 0 ? '-' : year > 9999 ? '+' : '';
|
|
884
|
+
return sign + padStart(abs(year), sign ? 6 : 4, 0) +
|
|
885
|
+
'-' + padStart(date.getUTCMonth() + 1, 2, 0) +
|
|
886
|
+
'-' + padStart(date.getUTCDate(), 2, 0) +
|
|
887
|
+
'T' + padStart(date.getUTCHours(), 2, 0) +
|
|
888
|
+
':' + padStart(date.getUTCMinutes(), 2, 0) +
|
|
889
|
+
':' + padStart(date.getUTCSeconds(), 2, 0) +
|
|
890
|
+
'.' + padStart(milliseconds, 3, 0) +
|
|
891
|
+
'Z';
|
|
892
|
+
} : nativeDateToISOString;
|
|
893
|
+
|
|
894
|
+
|
|
836
895
|
/***/ }),
|
|
837
896
|
|
|
838
897
|
/***/ "./node_modules/core-js/internals/define-iterator.js":
|
|
@@ -1042,6 +1101,32 @@ module.exports = {
|
|
|
1042
1101
|
};
|
|
1043
1102
|
|
|
1044
1103
|
|
|
1104
|
+
/***/ }),
|
|
1105
|
+
|
|
1106
|
+
/***/ "./node_modules/core-js/internals/engine-is-browser.js":
|
|
1107
|
+
/*!*************************************************************!*\
|
|
1108
|
+
!*** ./node_modules/core-js/internals/engine-is-browser.js ***!
|
|
1109
|
+
\*************************************************************/
|
|
1110
|
+
/*! no static exports found */
|
|
1111
|
+
/***/ (function(module, exports) {
|
|
1112
|
+
|
|
1113
|
+
module.exports = typeof window == 'object';
|
|
1114
|
+
|
|
1115
|
+
|
|
1116
|
+
/***/ }),
|
|
1117
|
+
|
|
1118
|
+
/***/ "./node_modules/core-js/internals/engine-is-ios.js":
|
|
1119
|
+
/*!*********************************************************!*\
|
|
1120
|
+
!*** ./node_modules/core-js/internals/engine-is-ios.js ***!
|
|
1121
|
+
\*********************************************************/
|
|
1122
|
+
/*! no static exports found */
|
|
1123
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
1124
|
+
|
|
1125
|
+
var userAgent = __webpack_require__(/*! ../internals/engine-user-agent */ "./node_modules/core-js/internals/engine-user-agent.js");
|
|
1126
|
+
|
|
1127
|
+
module.exports = /(?:iphone|ipod|ipad).*applewebkit/i.test(userAgent);
|
|
1128
|
+
|
|
1129
|
+
|
|
1045
1130
|
/***/ }),
|
|
1046
1131
|
|
|
1047
1132
|
/***/ "./node_modules/core-js/internals/engine-is-node.js":
|
|
@@ -1057,6 +1142,20 @@ var global = __webpack_require__(/*! ../internals/global */ "./node_modules/core
|
|
|
1057
1142
|
module.exports = classof(global.process) == 'process';
|
|
1058
1143
|
|
|
1059
1144
|
|
|
1145
|
+
/***/ }),
|
|
1146
|
+
|
|
1147
|
+
/***/ "./node_modules/core-js/internals/engine-is-webos-webkit.js":
|
|
1148
|
+
/*!******************************************************************!*\
|
|
1149
|
+
!*** ./node_modules/core-js/internals/engine-is-webos-webkit.js ***!
|
|
1150
|
+
\******************************************************************/
|
|
1151
|
+
/*! no static exports found */
|
|
1152
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
1153
|
+
|
|
1154
|
+
var userAgent = __webpack_require__(/*! ../internals/engine-user-agent */ "./node_modules/core-js/internals/engine-user-agent.js");
|
|
1155
|
+
|
|
1156
|
+
module.exports = /web0s(?!.*chrome)/i.test(userAgent);
|
|
1157
|
+
|
|
1158
|
+
|
|
1060
1159
|
/***/ }),
|
|
1061
1160
|
|
|
1062
1161
|
/***/ "./node_modules/core-js/internals/engine-user-agent.js":
|
|
@@ -1572,6 +1671,25 @@ module.exports = function hasOwn(it, key) {
|
|
|
1572
1671
|
module.exports = {};
|
|
1573
1672
|
|
|
1574
1673
|
|
|
1674
|
+
/***/ }),
|
|
1675
|
+
|
|
1676
|
+
/***/ "./node_modules/core-js/internals/host-report-errors.js":
|
|
1677
|
+
/*!**************************************************************!*\
|
|
1678
|
+
!*** ./node_modules/core-js/internals/host-report-errors.js ***!
|
|
1679
|
+
\**************************************************************/
|
|
1680
|
+
/*! no static exports found */
|
|
1681
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
1682
|
+
|
|
1683
|
+
var global = __webpack_require__(/*! ../internals/global */ "./node_modules/core-js/internals/global.js");
|
|
1684
|
+
|
|
1685
|
+
module.exports = function (a, b) {
|
|
1686
|
+
var console = global.console;
|
|
1687
|
+
if (console && console.error) {
|
|
1688
|
+
arguments.length === 1 ? console.error(a) : console.error(a, b);
|
|
1689
|
+
}
|
|
1690
|
+
};
|
|
1691
|
+
|
|
1692
|
+
|
|
1575
1693
|
/***/ }),
|
|
1576
1694
|
|
|
1577
1695
|
/***/ "./node_modules/core-js/internals/html.js":
|
|
@@ -1882,6 +2000,75 @@ module.exports = function (it) {
|
|
|
1882
2000
|
};
|
|
1883
2001
|
|
|
1884
2002
|
|
|
2003
|
+
/***/ }),
|
|
2004
|
+
|
|
2005
|
+
/***/ "./node_modules/core-js/internals/iterate.js":
|
|
2006
|
+
/*!***************************************************!*\
|
|
2007
|
+
!*** ./node_modules/core-js/internals/iterate.js ***!
|
|
2008
|
+
\***************************************************/
|
|
2009
|
+
/*! no static exports found */
|
|
2010
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
2011
|
+
|
|
2012
|
+
var anObject = __webpack_require__(/*! ../internals/an-object */ "./node_modules/core-js/internals/an-object.js");
|
|
2013
|
+
var isArrayIteratorMethod = __webpack_require__(/*! ../internals/is-array-iterator-method */ "./node_modules/core-js/internals/is-array-iterator-method.js");
|
|
2014
|
+
var toLength = __webpack_require__(/*! ../internals/to-length */ "./node_modules/core-js/internals/to-length.js");
|
|
2015
|
+
var bind = __webpack_require__(/*! ../internals/function-bind-context */ "./node_modules/core-js/internals/function-bind-context.js");
|
|
2016
|
+
var getIteratorMethod = __webpack_require__(/*! ../internals/get-iterator-method */ "./node_modules/core-js/internals/get-iterator-method.js");
|
|
2017
|
+
var iteratorClose = __webpack_require__(/*! ../internals/iterator-close */ "./node_modules/core-js/internals/iterator-close.js");
|
|
2018
|
+
|
|
2019
|
+
var Result = function (stopped, result) {
|
|
2020
|
+
this.stopped = stopped;
|
|
2021
|
+
this.result = result;
|
|
2022
|
+
};
|
|
2023
|
+
|
|
2024
|
+
module.exports = function (iterable, unboundFunction, options) {
|
|
2025
|
+
var that = options && options.that;
|
|
2026
|
+
var AS_ENTRIES = !!(options && options.AS_ENTRIES);
|
|
2027
|
+
var IS_ITERATOR = !!(options && options.IS_ITERATOR);
|
|
2028
|
+
var INTERRUPTED = !!(options && options.INTERRUPTED);
|
|
2029
|
+
var fn = bind(unboundFunction, that, 1 + AS_ENTRIES + INTERRUPTED);
|
|
2030
|
+
var iterator, iterFn, index, length, result, next, step;
|
|
2031
|
+
|
|
2032
|
+
var stop = function (condition) {
|
|
2033
|
+
if (iterator) iteratorClose(iterator);
|
|
2034
|
+
return new Result(true, condition);
|
|
2035
|
+
};
|
|
2036
|
+
|
|
2037
|
+
var callFn = function (value) {
|
|
2038
|
+
if (AS_ENTRIES) {
|
|
2039
|
+
anObject(value);
|
|
2040
|
+
return INTERRUPTED ? fn(value[0], value[1], stop) : fn(value[0], value[1]);
|
|
2041
|
+
} return INTERRUPTED ? fn(value, stop) : fn(value);
|
|
2042
|
+
};
|
|
2043
|
+
|
|
2044
|
+
if (IS_ITERATOR) {
|
|
2045
|
+
iterator = iterable;
|
|
2046
|
+
} else {
|
|
2047
|
+
iterFn = getIteratorMethod(iterable);
|
|
2048
|
+
if (typeof iterFn != 'function') throw TypeError('Target is not iterable');
|
|
2049
|
+
// optimisation for array iterators
|
|
2050
|
+
if (isArrayIteratorMethod(iterFn)) {
|
|
2051
|
+
for (index = 0, length = toLength(iterable.length); length > index; index++) {
|
|
2052
|
+
result = callFn(iterable[index]);
|
|
2053
|
+
if (result && result instanceof Result) return result;
|
|
2054
|
+
} return new Result(false);
|
|
2055
|
+
}
|
|
2056
|
+
iterator = iterFn.call(iterable);
|
|
2057
|
+
}
|
|
2058
|
+
|
|
2059
|
+
next = iterator.next;
|
|
2060
|
+
while (!(step = next.call(iterator)).done) {
|
|
2061
|
+
try {
|
|
2062
|
+
result = callFn(step.value);
|
|
2063
|
+
} catch (error) {
|
|
2064
|
+
iteratorClose(iterator);
|
|
2065
|
+
throw error;
|
|
2066
|
+
}
|
|
2067
|
+
if (typeof result == 'object' && result && result instanceof Result) return result;
|
|
2068
|
+
} return new Result(false);
|
|
2069
|
+
};
|
|
2070
|
+
|
|
2071
|
+
|
|
1885
2072
|
/***/ }),
|
|
1886
2073
|
|
|
1887
2074
|
/***/ "./node_modules/core-js/internals/iterator-close.js":
|
|
@@ -1970,6 +2157,113 @@ module.exports = {
|
|
|
1970
2157
|
module.exports = {};
|
|
1971
2158
|
|
|
1972
2159
|
|
|
2160
|
+
/***/ }),
|
|
2161
|
+
|
|
2162
|
+
/***/ "./node_modules/core-js/internals/microtask.js":
|
|
2163
|
+
/*!*****************************************************!*\
|
|
2164
|
+
!*** ./node_modules/core-js/internals/microtask.js ***!
|
|
2165
|
+
\*****************************************************/
|
|
2166
|
+
/*! no static exports found */
|
|
2167
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
2168
|
+
|
|
2169
|
+
var global = __webpack_require__(/*! ../internals/global */ "./node_modules/core-js/internals/global.js");
|
|
2170
|
+
var getOwnPropertyDescriptor = __webpack_require__(/*! ../internals/object-get-own-property-descriptor */ "./node_modules/core-js/internals/object-get-own-property-descriptor.js").f;
|
|
2171
|
+
var macrotask = __webpack_require__(/*! ../internals/task */ "./node_modules/core-js/internals/task.js").set;
|
|
2172
|
+
var IS_IOS = __webpack_require__(/*! ../internals/engine-is-ios */ "./node_modules/core-js/internals/engine-is-ios.js");
|
|
2173
|
+
var IS_WEBOS_WEBKIT = __webpack_require__(/*! ../internals/engine-is-webos-webkit */ "./node_modules/core-js/internals/engine-is-webos-webkit.js");
|
|
2174
|
+
var IS_NODE = __webpack_require__(/*! ../internals/engine-is-node */ "./node_modules/core-js/internals/engine-is-node.js");
|
|
2175
|
+
|
|
2176
|
+
var MutationObserver = global.MutationObserver || global.WebKitMutationObserver;
|
|
2177
|
+
var document = global.document;
|
|
2178
|
+
var process = global.process;
|
|
2179
|
+
var Promise = global.Promise;
|
|
2180
|
+
// Node.js 11 shows ExperimentalWarning on getting `queueMicrotask`
|
|
2181
|
+
var queueMicrotaskDescriptor = getOwnPropertyDescriptor(global, 'queueMicrotask');
|
|
2182
|
+
var queueMicrotask = queueMicrotaskDescriptor && queueMicrotaskDescriptor.value;
|
|
2183
|
+
|
|
2184
|
+
var flush, head, last, notify, toggle, node, promise, then;
|
|
2185
|
+
|
|
2186
|
+
// modern engines have queueMicrotask method
|
|
2187
|
+
if (!queueMicrotask) {
|
|
2188
|
+
flush = function () {
|
|
2189
|
+
var parent, fn;
|
|
2190
|
+
if (IS_NODE && (parent = process.domain)) parent.exit();
|
|
2191
|
+
while (head) {
|
|
2192
|
+
fn = head.fn;
|
|
2193
|
+
head = head.next;
|
|
2194
|
+
try {
|
|
2195
|
+
fn();
|
|
2196
|
+
} catch (error) {
|
|
2197
|
+
if (head) notify();
|
|
2198
|
+
else last = undefined;
|
|
2199
|
+
throw error;
|
|
2200
|
+
}
|
|
2201
|
+
} last = undefined;
|
|
2202
|
+
if (parent) parent.enter();
|
|
2203
|
+
};
|
|
2204
|
+
|
|
2205
|
+
// browsers with MutationObserver, except iOS - https://github.com/zloirock/core-js/issues/339
|
|
2206
|
+
// also except WebOS Webkit https://github.com/zloirock/core-js/issues/898
|
|
2207
|
+
if (!IS_IOS && !IS_NODE && !IS_WEBOS_WEBKIT && MutationObserver && document) {
|
|
2208
|
+
toggle = true;
|
|
2209
|
+
node = document.createTextNode('');
|
|
2210
|
+
new MutationObserver(flush).observe(node, { characterData: true });
|
|
2211
|
+
notify = function () {
|
|
2212
|
+
node.data = toggle = !toggle;
|
|
2213
|
+
};
|
|
2214
|
+
// environments with maybe non-completely correct, but existent Promise
|
|
2215
|
+
} else if (Promise && Promise.resolve) {
|
|
2216
|
+
// Promise.resolve without an argument throws an error in LG WebOS 2
|
|
2217
|
+
promise = Promise.resolve(undefined);
|
|
2218
|
+
// workaround of WebKit ~ iOS Safari 10.1 bug
|
|
2219
|
+
promise.constructor = Promise;
|
|
2220
|
+
then = promise.then;
|
|
2221
|
+
notify = function () {
|
|
2222
|
+
then.call(promise, flush);
|
|
2223
|
+
};
|
|
2224
|
+
// Node.js without promises
|
|
2225
|
+
} else if (IS_NODE) {
|
|
2226
|
+
notify = function () {
|
|
2227
|
+
process.nextTick(flush);
|
|
2228
|
+
};
|
|
2229
|
+
// for other environments - macrotask based on:
|
|
2230
|
+
// - setImmediate
|
|
2231
|
+
// - MessageChannel
|
|
2232
|
+
// - window.postMessag
|
|
2233
|
+
// - onreadystatechange
|
|
2234
|
+
// - setTimeout
|
|
2235
|
+
} else {
|
|
2236
|
+
notify = function () {
|
|
2237
|
+
// strange IE + webpack dev server bug - use .call(global)
|
|
2238
|
+
macrotask.call(global, flush);
|
|
2239
|
+
};
|
|
2240
|
+
}
|
|
2241
|
+
}
|
|
2242
|
+
|
|
2243
|
+
module.exports = queueMicrotask || function (fn) {
|
|
2244
|
+
var task = { fn: fn, next: undefined };
|
|
2245
|
+
if (last) last.next = task;
|
|
2246
|
+
if (!head) {
|
|
2247
|
+
head = task;
|
|
2248
|
+
notify();
|
|
2249
|
+
} last = task;
|
|
2250
|
+
};
|
|
2251
|
+
|
|
2252
|
+
|
|
2253
|
+
/***/ }),
|
|
2254
|
+
|
|
2255
|
+
/***/ "./node_modules/core-js/internals/native-promise-constructor.js":
|
|
2256
|
+
/*!**********************************************************************!*\
|
|
2257
|
+
!*** ./node_modules/core-js/internals/native-promise-constructor.js ***!
|
|
2258
|
+
\**********************************************************************/
|
|
2259
|
+
/*! no static exports found */
|
|
2260
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
2261
|
+
|
|
2262
|
+
var global = __webpack_require__(/*! ../internals/global */ "./node_modules/core-js/internals/global.js");
|
|
2263
|
+
|
|
2264
|
+
module.exports = global.Promise;
|
|
2265
|
+
|
|
2266
|
+
|
|
1973
2267
|
/***/ }),
|
|
1974
2268
|
|
|
1975
2269
|
/***/ "./node_modules/core-js/internals/native-symbol.js":
|
|
@@ -2009,6 +2303,36 @@ var WeakMap = global.WeakMap;
|
|
|
2009
2303
|
module.exports = typeof WeakMap === 'function' && /native code/.test(inspectSource(WeakMap));
|
|
2010
2304
|
|
|
2011
2305
|
|
|
2306
|
+
/***/ }),
|
|
2307
|
+
|
|
2308
|
+
/***/ "./node_modules/core-js/internals/new-promise-capability.js":
|
|
2309
|
+
/*!******************************************************************!*\
|
|
2310
|
+
!*** ./node_modules/core-js/internals/new-promise-capability.js ***!
|
|
2311
|
+
\******************************************************************/
|
|
2312
|
+
/*! no static exports found */
|
|
2313
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
2314
|
+
|
|
2315
|
+
"use strict";
|
|
2316
|
+
|
|
2317
|
+
var aFunction = __webpack_require__(/*! ../internals/a-function */ "./node_modules/core-js/internals/a-function.js");
|
|
2318
|
+
|
|
2319
|
+
var PromiseCapability = function (C) {
|
|
2320
|
+
var resolve, reject;
|
|
2321
|
+
this.promise = new C(function ($$resolve, $$reject) {
|
|
2322
|
+
if (resolve !== undefined || reject !== undefined) throw TypeError('Bad Promise constructor');
|
|
2323
|
+
resolve = $$resolve;
|
|
2324
|
+
reject = $$reject;
|
|
2325
|
+
});
|
|
2326
|
+
this.resolve = aFunction(resolve);
|
|
2327
|
+
this.reject = aFunction(reject);
|
|
2328
|
+
};
|
|
2329
|
+
|
|
2330
|
+
// 25.4.1.5 NewPromiseCapability(C)
|
|
2331
|
+
module.exports.f = function (C) {
|
|
2332
|
+
return new PromiseCapability(C);
|
|
2333
|
+
};
|
|
2334
|
+
|
|
2335
|
+
|
|
2012
2336
|
/***/ }),
|
|
2013
2337
|
|
|
2014
2338
|
/***/ "./node_modules/core-js/internals/not-a-regexp.js":
|
|
@@ -2633,6 +2957,64 @@ var global = __webpack_require__(/*! ../internals/global */ "./node_modules/core
|
|
|
2633
2957
|
module.exports = global;
|
|
2634
2958
|
|
|
2635
2959
|
|
|
2960
|
+
/***/ }),
|
|
2961
|
+
|
|
2962
|
+
/***/ "./node_modules/core-js/internals/perform.js":
|
|
2963
|
+
/*!***************************************************!*\
|
|
2964
|
+
!*** ./node_modules/core-js/internals/perform.js ***!
|
|
2965
|
+
\***************************************************/
|
|
2966
|
+
/*! no static exports found */
|
|
2967
|
+
/***/ (function(module, exports) {
|
|
2968
|
+
|
|
2969
|
+
module.exports = function (exec) {
|
|
2970
|
+
try {
|
|
2971
|
+
return { error: false, value: exec() };
|
|
2972
|
+
} catch (error) {
|
|
2973
|
+
return { error: true, value: error };
|
|
2974
|
+
}
|
|
2975
|
+
};
|
|
2976
|
+
|
|
2977
|
+
|
|
2978
|
+
/***/ }),
|
|
2979
|
+
|
|
2980
|
+
/***/ "./node_modules/core-js/internals/promise-resolve.js":
|
|
2981
|
+
/*!***********************************************************!*\
|
|
2982
|
+
!*** ./node_modules/core-js/internals/promise-resolve.js ***!
|
|
2983
|
+
\***********************************************************/
|
|
2984
|
+
/*! no static exports found */
|
|
2985
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
2986
|
+
|
|
2987
|
+
var anObject = __webpack_require__(/*! ../internals/an-object */ "./node_modules/core-js/internals/an-object.js");
|
|
2988
|
+
var isObject = __webpack_require__(/*! ../internals/is-object */ "./node_modules/core-js/internals/is-object.js");
|
|
2989
|
+
var newPromiseCapability = __webpack_require__(/*! ../internals/new-promise-capability */ "./node_modules/core-js/internals/new-promise-capability.js");
|
|
2990
|
+
|
|
2991
|
+
module.exports = function (C, x) {
|
|
2992
|
+
anObject(C);
|
|
2993
|
+
if (isObject(x) && x.constructor === C) return x;
|
|
2994
|
+
var promiseCapability = newPromiseCapability.f(C);
|
|
2995
|
+
var resolve = promiseCapability.resolve;
|
|
2996
|
+
resolve(x);
|
|
2997
|
+
return promiseCapability.promise;
|
|
2998
|
+
};
|
|
2999
|
+
|
|
3000
|
+
|
|
3001
|
+
/***/ }),
|
|
3002
|
+
|
|
3003
|
+
/***/ "./node_modules/core-js/internals/redefine-all.js":
|
|
3004
|
+
/*!********************************************************!*\
|
|
3005
|
+
!*** ./node_modules/core-js/internals/redefine-all.js ***!
|
|
3006
|
+
\********************************************************/
|
|
3007
|
+
/*! no static exports found */
|
|
3008
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
3009
|
+
|
|
3010
|
+
var redefine = __webpack_require__(/*! ../internals/redefine */ "./node_modules/core-js/internals/redefine.js");
|
|
3011
|
+
|
|
3012
|
+
module.exports = function (target, src, options) {
|
|
3013
|
+
for (var key in src) redefine(target, key, src[key], options);
|
|
3014
|
+
return target;
|
|
3015
|
+
};
|
|
3016
|
+
|
|
3017
|
+
|
|
2636
3018
|
/***/ }),
|
|
2637
3019
|
|
|
2638
3020
|
/***/ "./node_modules/core-js/internals/redefine.js":
|
|
@@ -3090,6 +3472,48 @@ module.exports = {
|
|
|
3090
3472
|
};
|
|
3091
3473
|
|
|
3092
3474
|
|
|
3475
|
+
/***/ }),
|
|
3476
|
+
|
|
3477
|
+
/***/ "./node_modules/core-js/internals/string-pad.js":
|
|
3478
|
+
/*!******************************************************!*\
|
|
3479
|
+
!*** ./node_modules/core-js/internals/string-pad.js ***!
|
|
3480
|
+
\******************************************************/
|
|
3481
|
+
/*! no static exports found */
|
|
3482
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
3483
|
+
|
|
3484
|
+
// https://github.com/tc39/proposal-string-pad-start-end
|
|
3485
|
+
var toLength = __webpack_require__(/*! ../internals/to-length */ "./node_modules/core-js/internals/to-length.js");
|
|
3486
|
+
var repeat = __webpack_require__(/*! ../internals/string-repeat */ "./node_modules/core-js/internals/string-repeat.js");
|
|
3487
|
+
var requireObjectCoercible = __webpack_require__(/*! ../internals/require-object-coercible */ "./node_modules/core-js/internals/require-object-coercible.js");
|
|
3488
|
+
|
|
3489
|
+
var ceil = Math.ceil;
|
|
3490
|
+
|
|
3491
|
+
// `String.prototype.{ padStart, padEnd }` methods implementation
|
|
3492
|
+
var createMethod = function (IS_END) {
|
|
3493
|
+
return function ($this, maxLength, fillString) {
|
|
3494
|
+
var S = String(requireObjectCoercible($this));
|
|
3495
|
+
var stringLength = S.length;
|
|
3496
|
+
var fillStr = fillString === undefined ? ' ' : String(fillString);
|
|
3497
|
+
var intMaxLength = toLength(maxLength);
|
|
3498
|
+
var fillLen, stringFiller;
|
|
3499
|
+
if (intMaxLength <= stringLength || fillStr == '') return S;
|
|
3500
|
+
fillLen = intMaxLength - stringLength;
|
|
3501
|
+
stringFiller = repeat.call(fillStr, ceil(fillLen / fillStr.length));
|
|
3502
|
+
if (stringFiller.length > fillLen) stringFiller = stringFiller.slice(0, fillLen);
|
|
3503
|
+
return IS_END ? S + stringFiller : stringFiller + S;
|
|
3504
|
+
};
|
|
3505
|
+
};
|
|
3506
|
+
|
|
3507
|
+
module.exports = {
|
|
3508
|
+
// `String.prototype.padStart` method
|
|
3509
|
+
// https://tc39.es/ecma262/#sec-string.prototype.padstart
|
|
3510
|
+
start: createMethod(false),
|
|
3511
|
+
// `String.prototype.padEnd` method
|
|
3512
|
+
// https://tc39.es/ecma262/#sec-string.prototype.padend
|
|
3513
|
+
end: createMethod(true)
|
|
3514
|
+
};
|
|
3515
|
+
|
|
3516
|
+
|
|
3093
3517
|
/***/ }),
|
|
3094
3518
|
|
|
3095
3519
|
/***/ "./node_modules/core-js/internals/string-repeat.js":
|
|
@@ -3180,43 +3604,161 @@ module.exports = {
|
|
|
3180
3604
|
|
|
3181
3605
|
/***/ }),
|
|
3182
3606
|
|
|
3183
|
-
/***/ "./node_modules/core-js/internals/
|
|
3184
|
-
|
|
3185
|
-
!*** ./node_modules/core-js/internals/
|
|
3186
|
-
|
|
3607
|
+
/***/ "./node_modules/core-js/internals/task.js":
|
|
3608
|
+
/*!************************************************!*\
|
|
3609
|
+
!*** ./node_modules/core-js/internals/task.js ***!
|
|
3610
|
+
\************************************************/
|
|
3187
3611
|
/*! no static exports found */
|
|
3188
3612
|
/***/ (function(module, exports, __webpack_require__) {
|
|
3189
3613
|
|
|
3190
|
-
var
|
|
3614
|
+
var global = __webpack_require__(/*! ../internals/global */ "./node_modules/core-js/internals/global.js");
|
|
3615
|
+
var fails = __webpack_require__(/*! ../internals/fails */ "./node_modules/core-js/internals/fails.js");
|
|
3616
|
+
var bind = __webpack_require__(/*! ../internals/function-bind-context */ "./node_modules/core-js/internals/function-bind-context.js");
|
|
3617
|
+
var html = __webpack_require__(/*! ../internals/html */ "./node_modules/core-js/internals/html.js");
|
|
3618
|
+
var createElement = __webpack_require__(/*! ../internals/document-create-element */ "./node_modules/core-js/internals/document-create-element.js");
|
|
3619
|
+
var IS_IOS = __webpack_require__(/*! ../internals/engine-is-ios */ "./node_modules/core-js/internals/engine-is-ios.js");
|
|
3620
|
+
var IS_NODE = __webpack_require__(/*! ../internals/engine-is-node */ "./node_modules/core-js/internals/engine-is-node.js");
|
|
3191
3621
|
|
|
3192
|
-
|
|
3193
|
-
|
|
3194
|
-
|
|
3195
|
-
|
|
3196
|
-
|
|
3622
|
+
var location = global.location;
|
|
3623
|
+
var set = global.setImmediate;
|
|
3624
|
+
var clear = global.clearImmediate;
|
|
3625
|
+
var process = global.process;
|
|
3626
|
+
var MessageChannel = global.MessageChannel;
|
|
3627
|
+
var Dispatch = global.Dispatch;
|
|
3628
|
+
var counter = 0;
|
|
3629
|
+
var queue = {};
|
|
3630
|
+
var ONREADYSTATECHANGE = 'onreadystatechange';
|
|
3631
|
+
var defer, channel, port;
|
|
3632
|
+
|
|
3633
|
+
var run = function (id) {
|
|
3634
|
+
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
3635
|
+
if (queue.hasOwnProperty(id)) {
|
|
3636
|
+
var fn = queue[id];
|
|
3637
|
+
delete queue[id];
|
|
3638
|
+
fn();
|
|
3197
3639
|
}
|
|
3198
|
-
return +value;
|
|
3199
3640
|
};
|
|
3200
3641
|
|
|
3642
|
+
var runner = function (id) {
|
|
3643
|
+
return function () {
|
|
3644
|
+
run(id);
|
|
3645
|
+
};
|
|
3646
|
+
};
|
|
3201
3647
|
|
|
3202
|
-
|
|
3203
|
-
|
|
3204
|
-
|
|
3205
|
-
/*!*************************************************************!*\
|
|
3206
|
-
!*** ./node_modules/core-js/internals/to-absolute-index.js ***!
|
|
3207
|
-
\*************************************************************/
|
|
3208
|
-
/*! no static exports found */
|
|
3209
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
3210
|
-
|
|
3211
|
-
var toInteger = __webpack_require__(/*! ../internals/to-integer */ "./node_modules/core-js/internals/to-integer.js");
|
|
3648
|
+
var listener = function (event) {
|
|
3649
|
+
run(event.data);
|
|
3650
|
+
};
|
|
3212
3651
|
|
|
3213
|
-
var
|
|
3214
|
-
|
|
3652
|
+
var post = function (id) {
|
|
3653
|
+
// old engines have not location.origin
|
|
3654
|
+
global.postMessage(id + '', location.protocol + '//' + location.host);
|
|
3655
|
+
};
|
|
3215
3656
|
|
|
3216
|
-
//
|
|
3217
|
-
|
|
3218
|
-
|
|
3219
|
-
|
|
3657
|
+
// Node.js 0.9+ & IE10+ has setImmediate, otherwise:
|
|
3658
|
+
if (!set || !clear) {
|
|
3659
|
+
set = function setImmediate(fn) {
|
|
3660
|
+
var args = [];
|
|
3661
|
+
var i = 1;
|
|
3662
|
+
while (arguments.length > i) args.push(arguments[i++]);
|
|
3663
|
+
queue[++counter] = function () {
|
|
3664
|
+
// eslint-disable-next-line no-new-func -- spec requirement
|
|
3665
|
+
(typeof fn == 'function' ? fn : Function(fn)).apply(undefined, args);
|
|
3666
|
+
};
|
|
3667
|
+
defer(counter);
|
|
3668
|
+
return counter;
|
|
3669
|
+
};
|
|
3670
|
+
clear = function clearImmediate(id) {
|
|
3671
|
+
delete queue[id];
|
|
3672
|
+
};
|
|
3673
|
+
// Node.js 0.8-
|
|
3674
|
+
if (IS_NODE) {
|
|
3675
|
+
defer = function (id) {
|
|
3676
|
+
process.nextTick(runner(id));
|
|
3677
|
+
};
|
|
3678
|
+
// Sphere (JS game engine) Dispatch API
|
|
3679
|
+
} else if (Dispatch && Dispatch.now) {
|
|
3680
|
+
defer = function (id) {
|
|
3681
|
+
Dispatch.now(runner(id));
|
|
3682
|
+
};
|
|
3683
|
+
// Browsers with MessageChannel, includes WebWorkers
|
|
3684
|
+
// except iOS - https://github.com/zloirock/core-js/issues/624
|
|
3685
|
+
} else if (MessageChannel && !IS_IOS) {
|
|
3686
|
+
channel = new MessageChannel();
|
|
3687
|
+
port = channel.port2;
|
|
3688
|
+
channel.port1.onmessage = listener;
|
|
3689
|
+
defer = bind(port.postMessage, port, 1);
|
|
3690
|
+
// Browsers with postMessage, skip WebWorkers
|
|
3691
|
+
// IE8 has postMessage, but it's sync & typeof its postMessage is 'object'
|
|
3692
|
+
} else if (
|
|
3693
|
+
global.addEventListener &&
|
|
3694
|
+
typeof postMessage == 'function' &&
|
|
3695
|
+
!global.importScripts &&
|
|
3696
|
+
location && location.protocol !== 'file:' &&
|
|
3697
|
+
!fails(post)
|
|
3698
|
+
) {
|
|
3699
|
+
defer = post;
|
|
3700
|
+
global.addEventListener('message', listener, false);
|
|
3701
|
+
// IE8-
|
|
3702
|
+
} else if (ONREADYSTATECHANGE in createElement('script')) {
|
|
3703
|
+
defer = function (id) {
|
|
3704
|
+
html.appendChild(createElement('script'))[ONREADYSTATECHANGE] = function () {
|
|
3705
|
+
html.removeChild(this);
|
|
3706
|
+
run(id);
|
|
3707
|
+
};
|
|
3708
|
+
};
|
|
3709
|
+
// Rest old browsers
|
|
3710
|
+
} else {
|
|
3711
|
+
defer = function (id) {
|
|
3712
|
+
setTimeout(runner(id), 0);
|
|
3713
|
+
};
|
|
3714
|
+
}
|
|
3715
|
+
}
|
|
3716
|
+
|
|
3717
|
+
module.exports = {
|
|
3718
|
+
set: set,
|
|
3719
|
+
clear: clear
|
|
3720
|
+
};
|
|
3721
|
+
|
|
3722
|
+
|
|
3723
|
+
/***/ }),
|
|
3724
|
+
|
|
3725
|
+
/***/ "./node_modules/core-js/internals/this-number-value.js":
|
|
3726
|
+
/*!*************************************************************!*\
|
|
3727
|
+
!*** ./node_modules/core-js/internals/this-number-value.js ***!
|
|
3728
|
+
\*************************************************************/
|
|
3729
|
+
/*! no static exports found */
|
|
3730
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
3731
|
+
|
|
3732
|
+
var classof = __webpack_require__(/*! ../internals/classof-raw */ "./node_modules/core-js/internals/classof-raw.js");
|
|
3733
|
+
|
|
3734
|
+
// `thisNumberValue` abstract operation
|
|
3735
|
+
// https://tc39.es/ecma262/#sec-thisnumbervalue
|
|
3736
|
+
module.exports = function (value) {
|
|
3737
|
+
if (typeof value != 'number' && classof(value) != 'Number') {
|
|
3738
|
+
throw TypeError('Incorrect invocation');
|
|
3739
|
+
}
|
|
3740
|
+
return +value;
|
|
3741
|
+
};
|
|
3742
|
+
|
|
3743
|
+
|
|
3744
|
+
/***/ }),
|
|
3745
|
+
|
|
3746
|
+
/***/ "./node_modules/core-js/internals/to-absolute-index.js":
|
|
3747
|
+
/*!*************************************************************!*\
|
|
3748
|
+
!*** ./node_modules/core-js/internals/to-absolute-index.js ***!
|
|
3749
|
+
\*************************************************************/
|
|
3750
|
+
/*! no static exports found */
|
|
3751
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
3752
|
+
|
|
3753
|
+
var toInteger = __webpack_require__(/*! ../internals/to-integer */ "./node_modules/core-js/internals/to-integer.js");
|
|
3754
|
+
|
|
3755
|
+
var max = Math.max;
|
|
3756
|
+
var min = Math.min;
|
|
3757
|
+
|
|
3758
|
+
// Helper for a popular repeating case of the spec:
|
|
3759
|
+
// Let integer be ? ToInteger(index).
|
|
3760
|
+
// If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).
|
|
3761
|
+
module.exports = function (index, length) {
|
|
3220
3762
|
var integer = toInteger(index);
|
|
3221
3763
|
return integer < 0 ? max(integer + length, 0) : min(integer, length);
|
|
3222
3764
|
};
|
|
@@ -4101,6 +4643,26 @@ $({ target: 'Date', stat: true }, {
|
|
|
4101
4643
|
});
|
|
4102
4644
|
|
|
4103
4645
|
|
|
4646
|
+
/***/ }),
|
|
4647
|
+
|
|
4648
|
+
/***/ "./node_modules/core-js/modules/es.date.to-iso-string.js":
|
|
4649
|
+
/*!***************************************************************!*\
|
|
4650
|
+
!*** ./node_modules/core-js/modules/es.date.to-iso-string.js ***!
|
|
4651
|
+
\***************************************************************/
|
|
4652
|
+
/*! no static exports found */
|
|
4653
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
4654
|
+
|
|
4655
|
+
var $ = __webpack_require__(/*! ../internals/export */ "./node_modules/core-js/internals/export.js");
|
|
4656
|
+
var toISOString = __webpack_require__(/*! ../internals/date-to-iso-string */ "./node_modules/core-js/internals/date-to-iso-string.js");
|
|
4657
|
+
|
|
4658
|
+
// `Date.prototype.toISOString` method
|
|
4659
|
+
// https://tc39.es/ecma262/#sec-date.prototype.toisostring
|
|
4660
|
+
// PhantomJS / old WebKit has a broken implementations
|
|
4661
|
+
$({ target: 'Date', proto: true, forced: Date.prototype.toISOString !== toISOString }, {
|
|
4662
|
+
toISOString: toISOString
|
|
4663
|
+
});
|
|
4664
|
+
|
|
4665
|
+
|
|
4104
4666
|
/***/ }),
|
|
4105
4667
|
|
|
4106
4668
|
/***/ "./node_modules/core-js/modules/es.date.to-string.js":
|
|
@@ -4723,6 +5285,410 @@ $({ global: true, forced: parseInt != parseIntImplementation }, {
|
|
|
4723
5285
|
});
|
|
4724
5286
|
|
|
4725
5287
|
|
|
5288
|
+
/***/ }),
|
|
5289
|
+
|
|
5290
|
+
/***/ "./node_modules/core-js/modules/es.promise.js":
|
|
5291
|
+
/*!****************************************************!*\
|
|
5292
|
+
!*** ./node_modules/core-js/modules/es.promise.js ***!
|
|
5293
|
+
\****************************************************/
|
|
5294
|
+
/*! no static exports found */
|
|
5295
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
5296
|
+
|
|
5297
|
+
"use strict";
|
|
5298
|
+
|
|
5299
|
+
var $ = __webpack_require__(/*! ../internals/export */ "./node_modules/core-js/internals/export.js");
|
|
5300
|
+
var IS_PURE = __webpack_require__(/*! ../internals/is-pure */ "./node_modules/core-js/internals/is-pure.js");
|
|
5301
|
+
var global = __webpack_require__(/*! ../internals/global */ "./node_modules/core-js/internals/global.js");
|
|
5302
|
+
var getBuiltIn = __webpack_require__(/*! ../internals/get-built-in */ "./node_modules/core-js/internals/get-built-in.js");
|
|
5303
|
+
var NativePromise = __webpack_require__(/*! ../internals/native-promise-constructor */ "./node_modules/core-js/internals/native-promise-constructor.js");
|
|
5304
|
+
var redefine = __webpack_require__(/*! ../internals/redefine */ "./node_modules/core-js/internals/redefine.js");
|
|
5305
|
+
var redefineAll = __webpack_require__(/*! ../internals/redefine-all */ "./node_modules/core-js/internals/redefine-all.js");
|
|
5306
|
+
var setPrototypeOf = __webpack_require__(/*! ../internals/object-set-prototype-of */ "./node_modules/core-js/internals/object-set-prototype-of.js");
|
|
5307
|
+
var setToStringTag = __webpack_require__(/*! ../internals/set-to-string-tag */ "./node_modules/core-js/internals/set-to-string-tag.js");
|
|
5308
|
+
var setSpecies = __webpack_require__(/*! ../internals/set-species */ "./node_modules/core-js/internals/set-species.js");
|
|
5309
|
+
var isObject = __webpack_require__(/*! ../internals/is-object */ "./node_modules/core-js/internals/is-object.js");
|
|
5310
|
+
var aFunction = __webpack_require__(/*! ../internals/a-function */ "./node_modules/core-js/internals/a-function.js");
|
|
5311
|
+
var anInstance = __webpack_require__(/*! ../internals/an-instance */ "./node_modules/core-js/internals/an-instance.js");
|
|
5312
|
+
var inspectSource = __webpack_require__(/*! ../internals/inspect-source */ "./node_modules/core-js/internals/inspect-source.js");
|
|
5313
|
+
var iterate = __webpack_require__(/*! ../internals/iterate */ "./node_modules/core-js/internals/iterate.js");
|
|
5314
|
+
var checkCorrectnessOfIteration = __webpack_require__(/*! ../internals/check-correctness-of-iteration */ "./node_modules/core-js/internals/check-correctness-of-iteration.js");
|
|
5315
|
+
var speciesConstructor = __webpack_require__(/*! ../internals/species-constructor */ "./node_modules/core-js/internals/species-constructor.js");
|
|
5316
|
+
var task = __webpack_require__(/*! ../internals/task */ "./node_modules/core-js/internals/task.js").set;
|
|
5317
|
+
var microtask = __webpack_require__(/*! ../internals/microtask */ "./node_modules/core-js/internals/microtask.js");
|
|
5318
|
+
var promiseResolve = __webpack_require__(/*! ../internals/promise-resolve */ "./node_modules/core-js/internals/promise-resolve.js");
|
|
5319
|
+
var hostReportErrors = __webpack_require__(/*! ../internals/host-report-errors */ "./node_modules/core-js/internals/host-report-errors.js");
|
|
5320
|
+
var newPromiseCapabilityModule = __webpack_require__(/*! ../internals/new-promise-capability */ "./node_modules/core-js/internals/new-promise-capability.js");
|
|
5321
|
+
var perform = __webpack_require__(/*! ../internals/perform */ "./node_modules/core-js/internals/perform.js");
|
|
5322
|
+
var InternalStateModule = __webpack_require__(/*! ../internals/internal-state */ "./node_modules/core-js/internals/internal-state.js");
|
|
5323
|
+
var isForced = __webpack_require__(/*! ../internals/is-forced */ "./node_modules/core-js/internals/is-forced.js");
|
|
5324
|
+
var wellKnownSymbol = __webpack_require__(/*! ../internals/well-known-symbol */ "./node_modules/core-js/internals/well-known-symbol.js");
|
|
5325
|
+
var IS_BROWSER = __webpack_require__(/*! ../internals/engine-is-browser */ "./node_modules/core-js/internals/engine-is-browser.js");
|
|
5326
|
+
var IS_NODE = __webpack_require__(/*! ../internals/engine-is-node */ "./node_modules/core-js/internals/engine-is-node.js");
|
|
5327
|
+
var V8_VERSION = __webpack_require__(/*! ../internals/engine-v8-version */ "./node_modules/core-js/internals/engine-v8-version.js");
|
|
5328
|
+
|
|
5329
|
+
var SPECIES = wellKnownSymbol('species');
|
|
5330
|
+
var PROMISE = 'Promise';
|
|
5331
|
+
var getInternalState = InternalStateModule.get;
|
|
5332
|
+
var setInternalState = InternalStateModule.set;
|
|
5333
|
+
var getInternalPromiseState = InternalStateModule.getterFor(PROMISE);
|
|
5334
|
+
var NativePromisePrototype = NativePromise && NativePromise.prototype;
|
|
5335
|
+
var PromiseConstructor = NativePromise;
|
|
5336
|
+
var PromiseConstructorPrototype = NativePromisePrototype;
|
|
5337
|
+
var TypeError = global.TypeError;
|
|
5338
|
+
var document = global.document;
|
|
5339
|
+
var process = global.process;
|
|
5340
|
+
var newPromiseCapability = newPromiseCapabilityModule.f;
|
|
5341
|
+
var newGenericPromiseCapability = newPromiseCapability;
|
|
5342
|
+
var DISPATCH_EVENT = !!(document && document.createEvent && global.dispatchEvent);
|
|
5343
|
+
var NATIVE_REJECTION_EVENT = typeof PromiseRejectionEvent == 'function';
|
|
5344
|
+
var UNHANDLED_REJECTION = 'unhandledrejection';
|
|
5345
|
+
var REJECTION_HANDLED = 'rejectionhandled';
|
|
5346
|
+
var PENDING = 0;
|
|
5347
|
+
var FULFILLED = 1;
|
|
5348
|
+
var REJECTED = 2;
|
|
5349
|
+
var HANDLED = 1;
|
|
5350
|
+
var UNHANDLED = 2;
|
|
5351
|
+
var SUBCLASSING = false;
|
|
5352
|
+
var Internal, OwnPromiseCapability, PromiseWrapper, nativeThen;
|
|
5353
|
+
|
|
5354
|
+
var FORCED = isForced(PROMISE, function () {
|
|
5355
|
+
var GLOBAL_CORE_JS_PROMISE = inspectSource(PromiseConstructor) !== String(PromiseConstructor);
|
|
5356
|
+
// V8 6.6 (Node 10 and Chrome 66) have a bug with resolving custom thenables
|
|
5357
|
+
// https://bugs.chromium.org/p/chromium/issues/detail?id=830565
|
|
5358
|
+
// We can't detect it synchronously, so just check versions
|
|
5359
|
+
if (!GLOBAL_CORE_JS_PROMISE && V8_VERSION === 66) return true;
|
|
5360
|
+
// We need Promise#finally in the pure version for preventing prototype pollution
|
|
5361
|
+
if (IS_PURE && !PromiseConstructorPrototype['finally']) return true;
|
|
5362
|
+
// We can't use @@species feature detection in V8 since it causes
|
|
5363
|
+
// deoptimization and performance degradation
|
|
5364
|
+
// https://github.com/zloirock/core-js/issues/679
|
|
5365
|
+
if (V8_VERSION >= 51 && /native code/.test(PromiseConstructor)) return false;
|
|
5366
|
+
// Detect correctness of subclassing with @@species support
|
|
5367
|
+
var promise = new PromiseConstructor(function (resolve) { resolve(1); });
|
|
5368
|
+
var FakePromise = function (exec) {
|
|
5369
|
+
exec(function () { /* empty */ }, function () { /* empty */ });
|
|
5370
|
+
};
|
|
5371
|
+
var constructor = promise.constructor = {};
|
|
5372
|
+
constructor[SPECIES] = FakePromise;
|
|
5373
|
+
SUBCLASSING = promise.then(function () { /* empty */ }) instanceof FakePromise;
|
|
5374
|
+
if (!SUBCLASSING) return true;
|
|
5375
|
+
// Unhandled rejections tracking support, NodeJS Promise without it fails @@species test
|
|
5376
|
+
return !GLOBAL_CORE_JS_PROMISE && IS_BROWSER && !NATIVE_REJECTION_EVENT;
|
|
5377
|
+
});
|
|
5378
|
+
|
|
5379
|
+
var INCORRECT_ITERATION = FORCED || !checkCorrectnessOfIteration(function (iterable) {
|
|
5380
|
+
PromiseConstructor.all(iterable)['catch'](function () { /* empty */ });
|
|
5381
|
+
});
|
|
5382
|
+
|
|
5383
|
+
// helpers
|
|
5384
|
+
var isThenable = function (it) {
|
|
5385
|
+
var then;
|
|
5386
|
+
return isObject(it) && typeof (then = it.then) == 'function' ? then : false;
|
|
5387
|
+
};
|
|
5388
|
+
|
|
5389
|
+
var notify = function (state, isReject) {
|
|
5390
|
+
if (state.notified) return;
|
|
5391
|
+
state.notified = true;
|
|
5392
|
+
var chain = state.reactions;
|
|
5393
|
+
microtask(function () {
|
|
5394
|
+
var value = state.value;
|
|
5395
|
+
var ok = state.state == FULFILLED;
|
|
5396
|
+
var index = 0;
|
|
5397
|
+
// variable length - can't use forEach
|
|
5398
|
+
while (chain.length > index) {
|
|
5399
|
+
var reaction = chain[index++];
|
|
5400
|
+
var handler = ok ? reaction.ok : reaction.fail;
|
|
5401
|
+
var resolve = reaction.resolve;
|
|
5402
|
+
var reject = reaction.reject;
|
|
5403
|
+
var domain = reaction.domain;
|
|
5404
|
+
var result, then, exited;
|
|
5405
|
+
try {
|
|
5406
|
+
if (handler) {
|
|
5407
|
+
if (!ok) {
|
|
5408
|
+
if (state.rejection === UNHANDLED) onHandleUnhandled(state);
|
|
5409
|
+
state.rejection = HANDLED;
|
|
5410
|
+
}
|
|
5411
|
+
if (handler === true) result = value;
|
|
5412
|
+
else {
|
|
5413
|
+
if (domain) domain.enter();
|
|
5414
|
+
result = handler(value); // can throw
|
|
5415
|
+
if (domain) {
|
|
5416
|
+
domain.exit();
|
|
5417
|
+
exited = true;
|
|
5418
|
+
}
|
|
5419
|
+
}
|
|
5420
|
+
if (result === reaction.promise) {
|
|
5421
|
+
reject(TypeError('Promise-chain cycle'));
|
|
5422
|
+
} else if (then = isThenable(result)) {
|
|
5423
|
+
then.call(result, resolve, reject);
|
|
5424
|
+
} else resolve(result);
|
|
5425
|
+
} else reject(value);
|
|
5426
|
+
} catch (error) {
|
|
5427
|
+
if (domain && !exited) domain.exit();
|
|
5428
|
+
reject(error);
|
|
5429
|
+
}
|
|
5430
|
+
}
|
|
5431
|
+
state.reactions = [];
|
|
5432
|
+
state.notified = false;
|
|
5433
|
+
if (isReject && !state.rejection) onUnhandled(state);
|
|
5434
|
+
});
|
|
5435
|
+
};
|
|
5436
|
+
|
|
5437
|
+
var dispatchEvent = function (name, promise, reason) {
|
|
5438
|
+
var event, handler;
|
|
5439
|
+
if (DISPATCH_EVENT) {
|
|
5440
|
+
event = document.createEvent('Event');
|
|
5441
|
+
event.promise = promise;
|
|
5442
|
+
event.reason = reason;
|
|
5443
|
+
event.initEvent(name, false, true);
|
|
5444
|
+
global.dispatchEvent(event);
|
|
5445
|
+
} else event = { promise: promise, reason: reason };
|
|
5446
|
+
if (!NATIVE_REJECTION_EVENT && (handler = global['on' + name])) handler(event);
|
|
5447
|
+
else if (name === UNHANDLED_REJECTION) hostReportErrors('Unhandled promise rejection', reason);
|
|
5448
|
+
};
|
|
5449
|
+
|
|
5450
|
+
var onUnhandled = function (state) {
|
|
5451
|
+
task.call(global, function () {
|
|
5452
|
+
var promise = state.facade;
|
|
5453
|
+
var value = state.value;
|
|
5454
|
+
var IS_UNHANDLED = isUnhandled(state);
|
|
5455
|
+
var result;
|
|
5456
|
+
if (IS_UNHANDLED) {
|
|
5457
|
+
result = perform(function () {
|
|
5458
|
+
if (IS_NODE) {
|
|
5459
|
+
process.emit('unhandledRejection', value, promise);
|
|
5460
|
+
} else dispatchEvent(UNHANDLED_REJECTION, promise, value);
|
|
5461
|
+
});
|
|
5462
|
+
// Browsers should not trigger `rejectionHandled` event if it was handled here, NodeJS - should
|
|
5463
|
+
state.rejection = IS_NODE || isUnhandled(state) ? UNHANDLED : HANDLED;
|
|
5464
|
+
if (result.error) throw result.value;
|
|
5465
|
+
}
|
|
5466
|
+
});
|
|
5467
|
+
};
|
|
5468
|
+
|
|
5469
|
+
var isUnhandled = function (state) {
|
|
5470
|
+
return state.rejection !== HANDLED && !state.parent;
|
|
5471
|
+
};
|
|
5472
|
+
|
|
5473
|
+
var onHandleUnhandled = function (state) {
|
|
5474
|
+
task.call(global, function () {
|
|
5475
|
+
var promise = state.facade;
|
|
5476
|
+
if (IS_NODE) {
|
|
5477
|
+
process.emit('rejectionHandled', promise);
|
|
5478
|
+
} else dispatchEvent(REJECTION_HANDLED, promise, state.value);
|
|
5479
|
+
});
|
|
5480
|
+
};
|
|
5481
|
+
|
|
5482
|
+
var bind = function (fn, state, unwrap) {
|
|
5483
|
+
return function (value) {
|
|
5484
|
+
fn(state, value, unwrap);
|
|
5485
|
+
};
|
|
5486
|
+
};
|
|
5487
|
+
|
|
5488
|
+
var internalReject = function (state, value, unwrap) {
|
|
5489
|
+
if (state.done) return;
|
|
5490
|
+
state.done = true;
|
|
5491
|
+
if (unwrap) state = unwrap;
|
|
5492
|
+
state.value = value;
|
|
5493
|
+
state.state = REJECTED;
|
|
5494
|
+
notify(state, true);
|
|
5495
|
+
};
|
|
5496
|
+
|
|
5497
|
+
var internalResolve = function (state, value, unwrap) {
|
|
5498
|
+
if (state.done) return;
|
|
5499
|
+
state.done = true;
|
|
5500
|
+
if (unwrap) state = unwrap;
|
|
5501
|
+
try {
|
|
5502
|
+
if (state.facade === value) throw TypeError("Promise can't be resolved itself");
|
|
5503
|
+
var then = isThenable(value);
|
|
5504
|
+
if (then) {
|
|
5505
|
+
microtask(function () {
|
|
5506
|
+
var wrapper = { done: false };
|
|
5507
|
+
try {
|
|
5508
|
+
then.call(value,
|
|
5509
|
+
bind(internalResolve, wrapper, state),
|
|
5510
|
+
bind(internalReject, wrapper, state)
|
|
5511
|
+
);
|
|
5512
|
+
} catch (error) {
|
|
5513
|
+
internalReject(wrapper, error, state);
|
|
5514
|
+
}
|
|
5515
|
+
});
|
|
5516
|
+
} else {
|
|
5517
|
+
state.value = value;
|
|
5518
|
+
state.state = FULFILLED;
|
|
5519
|
+
notify(state, false);
|
|
5520
|
+
}
|
|
5521
|
+
} catch (error) {
|
|
5522
|
+
internalReject({ done: false }, error, state);
|
|
5523
|
+
}
|
|
5524
|
+
};
|
|
5525
|
+
|
|
5526
|
+
// constructor polyfill
|
|
5527
|
+
if (FORCED) {
|
|
5528
|
+
// 25.4.3.1 Promise(executor)
|
|
5529
|
+
PromiseConstructor = function Promise(executor) {
|
|
5530
|
+
anInstance(this, PromiseConstructor, PROMISE);
|
|
5531
|
+
aFunction(executor);
|
|
5532
|
+
Internal.call(this);
|
|
5533
|
+
var state = getInternalState(this);
|
|
5534
|
+
try {
|
|
5535
|
+
executor(bind(internalResolve, state), bind(internalReject, state));
|
|
5536
|
+
} catch (error) {
|
|
5537
|
+
internalReject(state, error);
|
|
5538
|
+
}
|
|
5539
|
+
};
|
|
5540
|
+
PromiseConstructorPrototype = PromiseConstructor.prototype;
|
|
5541
|
+
// eslint-disable-next-line no-unused-vars -- required for `.length`
|
|
5542
|
+
Internal = function Promise(executor) {
|
|
5543
|
+
setInternalState(this, {
|
|
5544
|
+
type: PROMISE,
|
|
5545
|
+
done: false,
|
|
5546
|
+
notified: false,
|
|
5547
|
+
parent: false,
|
|
5548
|
+
reactions: [],
|
|
5549
|
+
rejection: false,
|
|
5550
|
+
state: PENDING,
|
|
5551
|
+
value: undefined
|
|
5552
|
+
});
|
|
5553
|
+
};
|
|
5554
|
+
Internal.prototype = redefineAll(PromiseConstructorPrototype, {
|
|
5555
|
+
// `Promise.prototype.then` method
|
|
5556
|
+
// https://tc39.es/ecma262/#sec-promise.prototype.then
|
|
5557
|
+
then: function then(onFulfilled, onRejected) {
|
|
5558
|
+
var state = getInternalPromiseState(this);
|
|
5559
|
+
var reaction = newPromiseCapability(speciesConstructor(this, PromiseConstructor));
|
|
5560
|
+
reaction.ok = typeof onFulfilled == 'function' ? onFulfilled : true;
|
|
5561
|
+
reaction.fail = typeof onRejected == 'function' && onRejected;
|
|
5562
|
+
reaction.domain = IS_NODE ? process.domain : undefined;
|
|
5563
|
+
state.parent = true;
|
|
5564
|
+
state.reactions.push(reaction);
|
|
5565
|
+
if (state.state != PENDING) notify(state, false);
|
|
5566
|
+
return reaction.promise;
|
|
5567
|
+
},
|
|
5568
|
+
// `Promise.prototype.catch` method
|
|
5569
|
+
// https://tc39.es/ecma262/#sec-promise.prototype.catch
|
|
5570
|
+
'catch': function (onRejected) {
|
|
5571
|
+
return this.then(undefined, onRejected);
|
|
5572
|
+
}
|
|
5573
|
+
});
|
|
5574
|
+
OwnPromiseCapability = function () {
|
|
5575
|
+
var promise = new Internal();
|
|
5576
|
+
var state = getInternalState(promise);
|
|
5577
|
+
this.promise = promise;
|
|
5578
|
+
this.resolve = bind(internalResolve, state);
|
|
5579
|
+
this.reject = bind(internalReject, state);
|
|
5580
|
+
};
|
|
5581
|
+
newPromiseCapabilityModule.f = newPromiseCapability = function (C) {
|
|
5582
|
+
return C === PromiseConstructor || C === PromiseWrapper
|
|
5583
|
+
? new OwnPromiseCapability(C)
|
|
5584
|
+
: newGenericPromiseCapability(C);
|
|
5585
|
+
};
|
|
5586
|
+
|
|
5587
|
+
if (!IS_PURE && typeof NativePromise == 'function' && NativePromisePrototype !== Object.prototype) {
|
|
5588
|
+
nativeThen = NativePromisePrototype.then;
|
|
5589
|
+
|
|
5590
|
+
if (!SUBCLASSING) {
|
|
5591
|
+
// make `Promise#then` return a polyfilled `Promise` for native promise-based APIs
|
|
5592
|
+
redefine(NativePromisePrototype, 'then', function then(onFulfilled, onRejected) {
|
|
5593
|
+
var that = this;
|
|
5594
|
+
return new PromiseConstructor(function (resolve, reject) {
|
|
5595
|
+
nativeThen.call(that, resolve, reject);
|
|
5596
|
+
}).then(onFulfilled, onRejected);
|
|
5597
|
+
// https://github.com/zloirock/core-js/issues/640
|
|
5598
|
+
}, { unsafe: true });
|
|
5599
|
+
|
|
5600
|
+
// makes sure that native promise-based APIs `Promise#catch` properly works with patched `Promise#then`
|
|
5601
|
+
redefine(NativePromisePrototype, 'catch', PromiseConstructorPrototype['catch'], { unsafe: true });
|
|
5602
|
+
}
|
|
5603
|
+
|
|
5604
|
+
// make `.constructor === Promise` work for native promise-based APIs
|
|
5605
|
+
try {
|
|
5606
|
+
delete NativePromisePrototype.constructor;
|
|
5607
|
+
} catch (error) { /* empty */ }
|
|
5608
|
+
|
|
5609
|
+
// make `instanceof Promise` work for native promise-based APIs
|
|
5610
|
+
if (setPrototypeOf) {
|
|
5611
|
+
setPrototypeOf(NativePromisePrototype, PromiseConstructorPrototype);
|
|
5612
|
+
}
|
|
5613
|
+
}
|
|
5614
|
+
}
|
|
5615
|
+
|
|
5616
|
+
$({ global: true, wrap: true, forced: FORCED }, {
|
|
5617
|
+
Promise: PromiseConstructor
|
|
5618
|
+
});
|
|
5619
|
+
|
|
5620
|
+
setToStringTag(PromiseConstructor, PROMISE, false, true);
|
|
5621
|
+
setSpecies(PROMISE);
|
|
5622
|
+
|
|
5623
|
+
PromiseWrapper = getBuiltIn(PROMISE);
|
|
5624
|
+
|
|
5625
|
+
// statics
|
|
5626
|
+
$({ target: PROMISE, stat: true, forced: FORCED }, {
|
|
5627
|
+
// `Promise.reject` method
|
|
5628
|
+
// https://tc39.es/ecma262/#sec-promise.reject
|
|
5629
|
+
reject: function reject(r) {
|
|
5630
|
+
var capability = newPromiseCapability(this);
|
|
5631
|
+
capability.reject.call(undefined, r);
|
|
5632
|
+
return capability.promise;
|
|
5633
|
+
}
|
|
5634
|
+
});
|
|
5635
|
+
|
|
5636
|
+
$({ target: PROMISE, stat: true, forced: IS_PURE || FORCED }, {
|
|
5637
|
+
// `Promise.resolve` method
|
|
5638
|
+
// https://tc39.es/ecma262/#sec-promise.resolve
|
|
5639
|
+
resolve: function resolve(x) {
|
|
5640
|
+
return promiseResolve(IS_PURE && this === PromiseWrapper ? PromiseConstructor : this, x);
|
|
5641
|
+
}
|
|
5642
|
+
});
|
|
5643
|
+
|
|
5644
|
+
$({ target: PROMISE, stat: true, forced: INCORRECT_ITERATION }, {
|
|
5645
|
+
// `Promise.all` method
|
|
5646
|
+
// https://tc39.es/ecma262/#sec-promise.all
|
|
5647
|
+
all: function all(iterable) {
|
|
5648
|
+
var C = this;
|
|
5649
|
+
var capability = newPromiseCapability(C);
|
|
5650
|
+
var resolve = capability.resolve;
|
|
5651
|
+
var reject = capability.reject;
|
|
5652
|
+
var result = perform(function () {
|
|
5653
|
+
var $promiseResolve = aFunction(C.resolve);
|
|
5654
|
+
var values = [];
|
|
5655
|
+
var counter = 0;
|
|
5656
|
+
var remaining = 1;
|
|
5657
|
+
iterate(iterable, function (promise) {
|
|
5658
|
+
var index = counter++;
|
|
5659
|
+
var alreadyCalled = false;
|
|
5660
|
+
values.push(undefined);
|
|
5661
|
+
remaining++;
|
|
5662
|
+
$promiseResolve.call(C, promise).then(function (value) {
|
|
5663
|
+
if (alreadyCalled) return;
|
|
5664
|
+
alreadyCalled = true;
|
|
5665
|
+
values[index] = value;
|
|
5666
|
+
--remaining || resolve(values);
|
|
5667
|
+
}, reject);
|
|
5668
|
+
});
|
|
5669
|
+
--remaining || resolve(values);
|
|
5670
|
+
});
|
|
5671
|
+
if (result.error) reject(result.value);
|
|
5672
|
+
return capability.promise;
|
|
5673
|
+
},
|
|
5674
|
+
// `Promise.race` method
|
|
5675
|
+
// https://tc39.es/ecma262/#sec-promise.race
|
|
5676
|
+
race: function race(iterable) {
|
|
5677
|
+
var C = this;
|
|
5678
|
+
var capability = newPromiseCapability(C);
|
|
5679
|
+
var reject = capability.reject;
|
|
5680
|
+
var result = perform(function () {
|
|
5681
|
+
var $promiseResolve = aFunction(C.resolve);
|
|
5682
|
+
iterate(iterable, function (promise) {
|
|
5683
|
+
$promiseResolve.call(C, promise).then(capability.resolve, reject);
|
|
5684
|
+
});
|
|
5685
|
+
});
|
|
5686
|
+
if (result.error) reject(result.value);
|
|
5687
|
+
return capability.promise;
|
|
5688
|
+
}
|
|
5689
|
+
});
|
|
5690
|
+
|
|
5691
|
+
|
|
4726
5692
|
/***/ }),
|
|
4727
5693
|
|
|
4728
5694
|
/***/ "./node_modules/core-js/modules/es.reflect.construct.js":
|
|
@@ -5936,103 +6902,866 @@ $({ global: true, bind: true, forced: MSIE }, {
|
|
|
5936
6902
|
|
|
5937
6903
|
/***/ }),
|
|
5938
6904
|
|
|
5939
|
-
/***/ "./node_modules/
|
|
5940
|
-
|
|
5941
|
-
!***
|
|
5942
|
-
|
|
6905
|
+
/***/ "./node_modules/regenerator-runtime/runtime.js":
|
|
6906
|
+
/*!*****************************************************!*\
|
|
6907
|
+
!*** ./node_modules/regenerator-runtime/runtime.js ***!
|
|
6908
|
+
\*****************************************************/
|
|
5943
6909
|
/*! no static exports found */
|
|
5944
|
-
/***/ (function(module, exports) {
|
|
6910
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
5945
6911
|
|
|
5946
|
-
|
|
6912
|
+
/**
|
|
6913
|
+
* Copyright (c) 2014-present, Facebook, Inc.
|
|
6914
|
+
*
|
|
6915
|
+
* This source code is licensed under the MIT license found in the
|
|
6916
|
+
* LICENSE file in the root directory of this source tree.
|
|
6917
|
+
*/
|
|
5947
6918
|
|
|
5948
|
-
|
|
5949
|
-
|
|
5950
|
-
|
|
5951
|
-
|
|
6919
|
+
var runtime = (function (exports) {
|
|
6920
|
+
"use strict";
|
|
6921
|
+
|
|
6922
|
+
var Op = Object.prototype;
|
|
6923
|
+
var hasOwn = Op.hasOwnProperty;
|
|
6924
|
+
var undefined; // More compressible than void 0.
|
|
6925
|
+
var $Symbol = typeof Symbol === "function" ? Symbol : {};
|
|
6926
|
+
var iteratorSymbol = $Symbol.iterator || "@@iterator";
|
|
6927
|
+
var asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator";
|
|
6928
|
+
var toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag";
|
|
6929
|
+
|
|
6930
|
+
function define(obj, key, value) {
|
|
6931
|
+
Object.defineProperty(obj, key, {
|
|
6932
|
+
value: value,
|
|
6933
|
+
enumerable: true,
|
|
6934
|
+
configurable: true,
|
|
6935
|
+
writable: true
|
|
6936
|
+
});
|
|
6937
|
+
return obj[key];
|
|
6938
|
+
}
|
|
6939
|
+
try {
|
|
6940
|
+
// IE 8 has a broken Object.defineProperty that only works on DOM objects.
|
|
6941
|
+
define({}, "");
|
|
6942
|
+
} catch (err) {
|
|
6943
|
+
define = function(obj, key, value) {
|
|
6944
|
+
return obj[key] = value;
|
|
6945
|
+
};
|
|
6946
|
+
}
|
|
5952
6947
|
|
|
5953
|
-
|
|
5954
|
-
|
|
5955
|
-
|
|
5956
|
-
|
|
5957
|
-
|
|
5958
|
-
if (typeof window === "object") g = window;
|
|
5959
|
-
}
|
|
6948
|
+
function wrap(innerFn, outerFn, self, tryLocsList) {
|
|
6949
|
+
// If outerFn provided and outerFn.prototype is a Generator, then outerFn.prototype instanceof Generator.
|
|
6950
|
+
var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator;
|
|
6951
|
+
var generator = Object.create(protoGenerator.prototype);
|
|
6952
|
+
var context = new Context(tryLocsList || []);
|
|
5960
6953
|
|
|
5961
|
-
//
|
|
5962
|
-
//
|
|
5963
|
-
|
|
6954
|
+
// The ._invoke method unifies the implementations of the .next,
|
|
6955
|
+
// .throw, and .return methods.
|
|
6956
|
+
generator._invoke = makeInvokeMethod(innerFn, self, context);
|
|
5964
6957
|
|
|
5965
|
-
|
|
6958
|
+
return generator;
|
|
6959
|
+
}
|
|
6960
|
+
exports.wrap = wrap;
|
|
6961
|
+
|
|
6962
|
+
// Try/catch helper to minimize deoptimizations. Returns a completion
|
|
6963
|
+
// record like context.tryEntries[i].completion. This interface could
|
|
6964
|
+
// have been (and was previously) designed to take a closure to be
|
|
6965
|
+
// invoked without arguments, but in all the cases we care about we
|
|
6966
|
+
// already have an existing method we want to call, so there's no need
|
|
6967
|
+
// to create a new function object. We can even get away with assuming
|
|
6968
|
+
// the method takes exactly one argument, since that happens to be true
|
|
6969
|
+
// in every case, so we don't have to touch the arguments object. The
|
|
6970
|
+
// only additional allocation required is the completion record, which
|
|
6971
|
+
// has a stable shape and so hopefully should be cheap to allocate.
|
|
6972
|
+
function tryCatch(fn, obj, arg) {
|
|
6973
|
+
try {
|
|
6974
|
+
return { type: "normal", arg: fn.call(obj, arg) };
|
|
6975
|
+
} catch (err) {
|
|
6976
|
+
return { type: "throw", arg: err };
|
|
6977
|
+
}
|
|
6978
|
+
}
|
|
5966
6979
|
|
|
6980
|
+
var GenStateSuspendedStart = "suspendedStart";
|
|
6981
|
+
var GenStateSuspendedYield = "suspendedYield";
|
|
6982
|
+
var GenStateExecuting = "executing";
|
|
6983
|
+
var GenStateCompleted = "completed";
|
|
6984
|
+
|
|
6985
|
+
// Returning this object from the innerFn has the same effect as
|
|
6986
|
+
// breaking out of the dispatch switch statement.
|
|
6987
|
+
var ContinueSentinel = {};
|
|
6988
|
+
|
|
6989
|
+
// Dummy constructor functions that we use as the .constructor and
|
|
6990
|
+
// .constructor.prototype properties for functions that return Generator
|
|
6991
|
+
// objects. For full spec compliance, you may wish to configure your
|
|
6992
|
+
// minifier not to mangle the names of these two functions.
|
|
6993
|
+
function Generator() {}
|
|
6994
|
+
function GeneratorFunction() {}
|
|
6995
|
+
function GeneratorFunctionPrototype() {}
|
|
6996
|
+
|
|
6997
|
+
// This is a polyfill for %IteratorPrototype% for environments that
|
|
6998
|
+
// don't natively support it.
|
|
6999
|
+
var IteratorPrototype = {};
|
|
7000
|
+
IteratorPrototype[iteratorSymbol] = function () {
|
|
7001
|
+
return this;
|
|
7002
|
+
};
|
|
5967
7003
|
|
|
5968
|
-
|
|
7004
|
+
var getProto = Object.getPrototypeOf;
|
|
7005
|
+
var NativeIteratorPrototype = getProto && getProto(getProto(values([])));
|
|
7006
|
+
if (NativeIteratorPrototype &&
|
|
7007
|
+
NativeIteratorPrototype !== Op &&
|
|
7008
|
+
hasOwn.call(NativeIteratorPrototype, iteratorSymbol)) {
|
|
7009
|
+
// This environment has a native %IteratorPrototype%; use it instead
|
|
7010
|
+
// of the polyfill.
|
|
7011
|
+
IteratorPrototype = NativeIteratorPrototype;
|
|
7012
|
+
}
|
|
5969
7013
|
|
|
5970
|
-
|
|
5971
|
-
|
|
5972
|
-
|
|
5973
|
-
|
|
5974
|
-
|
|
5975
|
-
|
|
7014
|
+
var Gp = GeneratorFunctionPrototype.prototype =
|
|
7015
|
+
Generator.prototype = Object.create(IteratorPrototype);
|
|
7016
|
+
GeneratorFunction.prototype = Gp.constructor = GeneratorFunctionPrototype;
|
|
7017
|
+
GeneratorFunctionPrototype.constructor = GeneratorFunction;
|
|
7018
|
+
GeneratorFunction.displayName = define(
|
|
7019
|
+
GeneratorFunctionPrototype,
|
|
7020
|
+
toStringTagSymbol,
|
|
7021
|
+
"GeneratorFunction"
|
|
7022
|
+
);
|
|
7023
|
+
|
|
7024
|
+
// Helper for defining the .next, .throw, and .return methods of the
|
|
7025
|
+
// Iterator interface in terms of a single ._invoke method.
|
|
7026
|
+
function defineIteratorMethods(prototype) {
|
|
7027
|
+
["next", "throw", "return"].forEach(function(method) {
|
|
7028
|
+
define(prototype, method, function(arg) {
|
|
7029
|
+
return this._invoke(method, arg);
|
|
7030
|
+
});
|
|
7031
|
+
});
|
|
7032
|
+
}
|
|
5976
7033
|
|
|
5977
|
-
|
|
5978
|
-
|
|
5979
|
-
|
|
5980
|
-
|
|
5981
|
-
|
|
5982
|
-
|
|
5983
|
-
|
|
5984
|
-
|
|
5985
|
-
|
|
5986
|
-
|
|
5987
|
-
|
|
5988
|
-
|
|
5989
|
-
|
|
5990
|
-
|
|
5991
|
-
|
|
5992
|
-
|
|
5993
|
-
|
|
5994
|
-
|
|
5995
|
-
|
|
5996
|
-
|
|
5997
|
-
|
|
5998
|
-
|
|
5999
|
-
|
|
6000
|
-
|
|
6001
|
-
|
|
6002
|
-
|
|
6003
|
-
|
|
6004
|
-
|
|
6005
|
-
|
|
6006
|
-
|
|
6007
|
-
|
|
6008
|
-
|
|
6009
|
-
|
|
6010
|
-
|
|
6011
|
-
|
|
6012
|
-
|
|
6013
|
-
|
|
6014
|
-
|
|
6015
|
-
|
|
6016
|
-
|
|
6017
|
-
|
|
6018
|
-
|
|
6019
|
-
|
|
6020
|
-
|
|
6021
|
-
|
|
6022
|
-
|
|
6023
|
-
|
|
6024
|
-
|
|
6025
|
-
|
|
6026
|
-
|
|
6027
|
-
|
|
6028
|
-
|
|
6029
|
-
|
|
6030
|
-
|
|
6031
|
-
|
|
6032
|
-
|
|
6033
|
-
|
|
6034
|
-
|
|
6035
|
-
|
|
7034
|
+
exports.isGeneratorFunction = function(genFun) {
|
|
7035
|
+
var ctor = typeof genFun === "function" && genFun.constructor;
|
|
7036
|
+
return ctor
|
|
7037
|
+
? ctor === GeneratorFunction ||
|
|
7038
|
+
// For the native GeneratorFunction constructor, the best we can
|
|
7039
|
+
// do is to check its .name property.
|
|
7040
|
+
(ctor.displayName || ctor.name) === "GeneratorFunction"
|
|
7041
|
+
: false;
|
|
7042
|
+
};
|
|
7043
|
+
|
|
7044
|
+
exports.mark = function(genFun) {
|
|
7045
|
+
if (Object.setPrototypeOf) {
|
|
7046
|
+
Object.setPrototypeOf(genFun, GeneratorFunctionPrototype);
|
|
7047
|
+
} else {
|
|
7048
|
+
genFun.__proto__ = GeneratorFunctionPrototype;
|
|
7049
|
+
define(genFun, toStringTagSymbol, "GeneratorFunction");
|
|
7050
|
+
}
|
|
7051
|
+
genFun.prototype = Object.create(Gp);
|
|
7052
|
+
return genFun;
|
|
7053
|
+
};
|
|
7054
|
+
|
|
7055
|
+
// Within the body of any async function, `await x` is transformed to
|
|
7056
|
+
// `yield regeneratorRuntime.awrap(x)`, so that the runtime can test
|
|
7057
|
+
// `hasOwn.call(value, "__await")` to determine if the yielded value is
|
|
7058
|
+
// meant to be awaited.
|
|
7059
|
+
exports.awrap = function(arg) {
|
|
7060
|
+
return { __await: arg };
|
|
7061
|
+
};
|
|
7062
|
+
|
|
7063
|
+
function AsyncIterator(generator, PromiseImpl) {
|
|
7064
|
+
function invoke(method, arg, resolve, reject) {
|
|
7065
|
+
var record = tryCatch(generator[method], generator, arg);
|
|
7066
|
+
if (record.type === "throw") {
|
|
7067
|
+
reject(record.arg);
|
|
7068
|
+
} else {
|
|
7069
|
+
var result = record.arg;
|
|
7070
|
+
var value = result.value;
|
|
7071
|
+
if (value &&
|
|
7072
|
+
typeof value === "object" &&
|
|
7073
|
+
hasOwn.call(value, "__await")) {
|
|
7074
|
+
return PromiseImpl.resolve(value.__await).then(function(value) {
|
|
7075
|
+
invoke("next", value, resolve, reject);
|
|
7076
|
+
}, function(err) {
|
|
7077
|
+
invoke("throw", err, resolve, reject);
|
|
7078
|
+
});
|
|
7079
|
+
}
|
|
7080
|
+
|
|
7081
|
+
return PromiseImpl.resolve(value).then(function(unwrapped) {
|
|
7082
|
+
// When a yielded Promise is resolved, its final value becomes
|
|
7083
|
+
// the .value of the Promise<{value,done}> result for the
|
|
7084
|
+
// current iteration.
|
|
7085
|
+
result.value = unwrapped;
|
|
7086
|
+
resolve(result);
|
|
7087
|
+
}, function(error) {
|
|
7088
|
+
// If a rejected Promise was yielded, throw the rejection back
|
|
7089
|
+
// into the async generator function so it can be handled there.
|
|
7090
|
+
return invoke("throw", error, resolve, reject);
|
|
7091
|
+
});
|
|
7092
|
+
}
|
|
7093
|
+
}
|
|
7094
|
+
|
|
7095
|
+
var previousPromise;
|
|
7096
|
+
|
|
7097
|
+
function enqueue(method, arg) {
|
|
7098
|
+
function callInvokeWithMethodAndArg() {
|
|
7099
|
+
return new PromiseImpl(function(resolve, reject) {
|
|
7100
|
+
invoke(method, arg, resolve, reject);
|
|
7101
|
+
});
|
|
7102
|
+
}
|
|
7103
|
+
|
|
7104
|
+
return previousPromise =
|
|
7105
|
+
// If enqueue has been called before, then we want to wait until
|
|
7106
|
+
// all previous Promises have been resolved before calling invoke,
|
|
7107
|
+
// so that results are always delivered in the correct order. If
|
|
7108
|
+
// enqueue has not been called before, then it is important to
|
|
7109
|
+
// call invoke immediately, without waiting on a callback to fire,
|
|
7110
|
+
// so that the async generator function has the opportunity to do
|
|
7111
|
+
// any necessary setup in a predictable way. This predictability
|
|
7112
|
+
// is why the Promise constructor synchronously invokes its
|
|
7113
|
+
// executor callback, and why async functions synchronously
|
|
7114
|
+
// execute code before the first await. Since we implement simple
|
|
7115
|
+
// async functions in terms of async generators, it is especially
|
|
7116
|
+
// important to get this right, even though it requires care.
|
|
7117
|
+
previousPromise ? previousPromise.then(
|
|
7118
|
+
callInvokeWithMethodAndArg,
|
|
7119
|
+
// Avoid propagating failures to Promises returned by later
|
|
7120
|
+
// invocations of the iterator.
|
|
7121
|
+
callInvokeWithMethodAndArg
|
|
7122
|
+
) : callInvokeWithMethodAndArg();
|
|
7123
|
+
}
|
|
7124
|
+
|
|
7125
|
+
// Define the unified helper method that is used to implement .next,
|
|
7126
|
+
// .throw, and .return (see defineIteratorMethods).
|
|
7127
|
+
this._invoke = enqueue;
|
|
7128
|
+
}
|
|
7129
|
+
|
|
7130
|
+
defineIteratorMethods(AsyncIterator.prototype);
|
|
7131
|
+
AsyncIterator.prototype[asyncIteratorSymbol] = function () {
|
|
7132
|
+
return this;
|
|
7133
|
+
};
|
|
7134
|
+
exports.AsyncIterator = AsyncIterator;
|
|
7135
|
+
|
|
7136
|
+
// Note that simple async functions are implemented on top of
|
|
7137
|
+
// AsyncIterator objects; they just return a Promise for the value of
|
|
7138
|
+
// the final result produced by the iterator.
|
|
7139
|
+
exports.async = function(innerFn, outerFn, self, tryLocsList, PromiseImpl) {
|
|
7140
|
+
if (PromiseImpl === void 0) PromiseImpl = Promise;
|
|
7141
|
+
|
|
7142
|
+
var iter = new AsyncIterator(
|
|
7143
|
+
wrap(innerFn, outerFn, self, tryLocsList),
|
|
7144
|
+
PromiseImpl
|
|
7145
|
+
);
|
|
7146
|
+
|
|
7147
|
+
return exports.isGeneratorFunction(outerFn)
|
|
7148
|
+
? iter // If outerFn is a generator, return the full iterator.
|
|
7149
|
+
: iter.next().then(function(result) {
|
|
7150
|
+
return result.done ? result.value : iter.next();
|
|
7151
|
+
});
|
|
7152
|
+
};
|
|
7153
|
+
|
|
7154
|
+
function makeInvokeMethod(innerFn, self, context) {
|
|
7155
|
+
var state = GenStateSuspendedStart;
|
|
7156
|
+
|
|
7157
|
+
return function invoke(method, arg) {
|
|
7158
|
+
if (state === GenStateExecuting) {
|
|
7159
|
+
throw new Error("Generator is already running");
|
|
7160
|
+
}
|
|
7161
|
+
|
|
7162
|
+
if (state === GenStateCompleted) {
|
|
7163
|
+
if (method === "throw") {
|
|
7164
|
+
throw arg;
|
|
7165
|
+
}
|
|
7166
|
+
|
|
7167
|
+
// Be forgiving, per 25.3.3.3.3 of the spec:
|
|
7168
|
+
// https://people.mozilla.org/~jorendorff/es6-draft.html#sec-generatorresume
|
|
7169
|
+
return doneResult();
|
|
7170
|
+
}
|
|
7171
|
+
|
|
7172
|
+
context.method = method;
|
|
7173
|
+
context.arg = arg;
|
|
7174
|
+
|
|
7175
|
+
while (true) {
|
|
7176
|
+
var delegate = context.delegate;
|
|
7177
|
+
if (delegate) {
|
|
7178
|
+
var delegateResult = maybeInvokeDelegate(delegate, context);
|
|
7179
|
+
if (delegateResult) {
|
|
7180
|
+
if (delegateResult === ContinueSentinel) continue;
|
|
7181
|
+
return delegateResult;
|
|
7182
|
+
}
|
|
7183
|
+
}
|
|
7184
|
+
|
|
7185
|
+
if (context.method === "next") {
|
|
7186
|
+
// Setting context._sent for legacy support of Babel's
|
|
7187
|
+
// function.sent implementation.
|
|
7188
|
+
context.sent = context._sent = context.arg;
|
|
7189
|
+
|
|
7190
|
+
} else if (context.method === "throw") {
|
|
7191
|
+
if (state === GenStateSuspendedStart) {
|
|
7192
|
+
state = GenStateCompleted;
|
|
7193
|
+
throw context.arg;
|
|
7194
|
+
}
|
|
7195
|
+
|
|
7196
|
+
context.dispatchException(context.arg);
|
|
7197
|
+
|
|
7198
|
+
} else if (context.method === "return") {
|
|
7199
|
+
context.abrupt("return", context.arg);
|
|
7200
|
+
}
|
|
7201
|
+
|
|
7202
|
+
state = GenStateExecuting;
|
|
7203
|
+
|
|
7204
|
+
var record = tryCatch(innerFn, self, context);
|
|
7205
|
+
if (record.type === "normal") {
|
|
7206
|
+
// If an exception is thrown from innerFn, we leave state ===
|
|
7207
|
+
// GenStateExecuting and loop back for another invocation.
|
|
7208
|
+
state = context.done
|
|
7209
|
+
? GenStateCompleted
|
|
7210
|
+
: GenStateSuspendedYield;
|
|
7211
|
+
|
|
7212
|
+
if (record.arg === ContinueSentinel) {
|
|
7213
|
+
continue;
|
|
7214
|
+
}
|
|
7215
|
+
|
|
7216
|
+
return {
|
|
7217
|
+
value: record.arg,
|
|
7218
|
+
done: context.done
|
|
7219
|
+
};
|
|
7220
|
+
|
|
7221
|
+
} else if (record.type === "throw") {
|
|
7222
|
+
state = GenStateCompleted;
|
|
7223
|
+
// Dispatch the exception by looping back around to the
|
|
7224
|
+
// context.dispatchException(context.arg) call above.
|
|
7225
|
+
context.method = "throw";
|
|
7226
|
+
context.arg = record.arg;
|
|
7227
|
+
}
|
|
7228
|
+
}
|
|
7229
|
+
};
|
|
7230
|
+
}
|
|
7231
|
+
|
|
7232
|
+
// Call delegate.iterator[context.method](context.arg) and handle the
|
|
7233
|
+
// result, either by returning a { value, done } result from the
|
|
7234
|
+
// delegate iterator, or by modifying context.method and context.arg,
|
|
7235
|
+
// setting context.delegate to null, and returning the ContinueSentinel.
|
|
7236
|
+
function maybeInvokeDelegate(delegate, context) {
|
|
7237
|
+
var method = delegate.iterator[context.method];
|
|
7238
|
+
if (method === undefined) {
|
|
7239
|
+
// A .throw or .return when the delegate iterator has no .throw
|
|
7240
|
+
// method always terminates the yield* loop.
|
|
7241
|
+
context.delegate = null;
|
|
7242
|
+
|
|
7243
|
+
if (context.method === "throw") {
|
|
7244
|
+
// Note: ["return"] must be used for ES3 parsing compatibility.
|
|
7245
|
+
if (delegate.iterator["return"]) {
|
|
7246
|
+
// If the delegate iterator has a return method, give it a
|
|
7247
|
+
// chance to clean up.
|
|
7248
|
+
context.method = "return";
|
|
7249
|
+
context.arg = undefined;
|
|
7250
|
+
maybeInvokeDelegate(delegate, context);
|
|
7251
|
+
|
|
7252
|
+
if (context.method === "throw") {
|
|
7253
|
+
// If maybeInvokeDelegate(context) changed context.method from
|
|
7254
|
+
// "return" to "throw", let that override the TypeError below.
|
|
7255
|
+
return ContinueSentinel;
|
|
7256
|
+
}
|
|
7257
|
+
}
|
|
7258
|
+
|
|
7259
|
+
context.method = "throw";
|
|
7260
|
+
context.arg = new TypeError(
|
|
7261
|
+
"The iterator does not provide a 'throw' method");
|
|
7262
|
+
}
|
|
7263
|
+
|
|
7264
|
+
return ContinueSentinel;
|
|
7265
|
+
}
|
|
7266
|
+
|
|
7267
|
+
var record = tryCatch(method, delegate.iterator, context.arg);
|
|
7268
|
+
|
|
7269
|
+
if (record.type === "throw") {
|
|
7270
|
+
context.method = "throw";
|
|
7271
|
+
context.arg = record.arg;
|
|
7272
|
+
context.delegate = null;
|
|
7273
|
+
return ContinueSentinel;
|
|
7274
|
+
}
|
|
7275
|
+
|
|
7276
|
+
var info = record.arg;
|
|
7277
|
+
|
|
7278
|
+
if (! info) {
|
|
7279
|
+
context.method = "throw";
|
|
7280
|
+
context.arg = new TypeError("iterator result is not an object");
|
|
7281
|
+
context.delegate = null;
|
|
7282
|
+
return ContinueSentinel;
|
|
7283
|
+
}
|
|
7284
|
+
|
|
7285
|
+
if (info.done) {
|
|
7286
|
+
// Assign the result of the finished delegate to the temporary
|
|
7287
|
+
// variable specified by delegate.resultName (see delegateYield).
|
|
7288
|
+
context[delegate.resultName] = info.value;
|
|
7289
|
+
|
|
7290
|
+
// Resume execution at the desired location (see delegateYield).
|
|
7291
|
+
context.next = delegate.nextLoc;
|
|
7292
|
+
|
|
7293
|
+
// If context.method was "throw" but the delegate handled the
|
|
7294
|
+
// exception, let the outer generator proceed normally. If
|
|
7295
|
+
// context.method was "next", forget context.arg since it has been
|
|
7296
|
+
// "consumed" by the delegate iterator. If context.method was
|
|
7297
|
+
// "return", allow the original .return call to continue in the
|
|
7298
|
+
// outer generator.
|
|
7299
|
+
if (context.method !== "return") {
|
|
7300
|
+
context.method = "next";
|
|
7301
|
+
context.arg = undefined;
|
|
7302
|
+
}
|
|
7303
|
+
|
|
7304
|
+
} else {
|
|
7305
|
+
// Re-yield the result returned by the delegate method.
|
|
7306
|
+
return info;
|
|
7307
|
+
}
|
|
7308
|
+
|
|
7309
|
+
// The delegate iterator is finished, so forget it and continue with
|
|
7310
|
+
// the outer generator.
|
|
7311
|
+
context.delegate = null;
|
|
7312
|
+
return ContinueSentinel;
|
|
7313
|
+
}
|
|
7314
|
+
|
|
7315
|
+
// Define Generator.prototype.{next,throw,return} in terms of the
|
|
7316
|
+
// unified ._invoke helper method.
|
|
7317
|
+
defineIteratorMethods(Gp);
|
|
7318
|
+
|
|
7319
|
+
define(Gp, toStringTagSymbol, "Generator");
|
|
7320
|
+
|
|
7321
|
+
// A Generator should always return itself as the iterator object when the
|
|
7322
|
+
// @@iterator function is called on it. Some browsers' implementations of the
|
|
7323
|
+
// iterator prototype chain incorrectly implement this, causing the Generator
|
|
7324
|
+
// object to not be returned from this call. This ensures that doesn't happen.
|
|
7325
|
+
// See https://github.com/facebook/regenerator/issues/274 for more details.
|
|
7326
|
+
Gp[iteratorSymbol] = function() {
|
|
7327
|
+
return this;
|
|
7328
|
+
};
|
|
7329
|
+
|
|
7330
|
+
Gp.toString = function() {
|
|
7331
|
+
return "[object Generator]";
|
|
7332
|
+
};
|
|
7333
|
+
|
|
7334
|
+
function pushTryEntry(locs) {
|
|
7335
|
+
var entry = { tryLoc: locs[0] };
|
|
7336
|
+
|
|
7337
|
+
if (1 in locs) {
|
|
7338
|
+
entry.catchLoc = locs[1];
|
|
7339
|
+
}
|
|
7340
|
+
|
|
7341
|
+
if (2 in locs) {
|
|
7342
|
+
entry.finallyLoc = locs[2];
|
|
7343
|
+
entry.afterLoc = locs[3];
|
|
7344
|
+
}
|
|
7345
|
+
|
|
7346
|
+
this.tryEntries.push(entry);
|
|
7347
|
+
}
|
|
7348
|
+
|
|
7349
|
+
function resetTryEntry(entry) {
|
|
7350
|
+
var record = entry.completion || {};
|
|
7351
|
+
record.type = "normal";
|
|
7352
|
+
delete record.arg;
|
|
7353
|
+
entry.completion = record;
|
|
7354
|
+
}
|
|
7355
|
+
|
|
7356
|
+
function Context(tryLocsList) {
|
|
7357
|
+
// The root entry object (effectively a try statement without a catch
|
|
7358
|
+
// or a finally block) gives us a place to store values thrown from
|
|
7359
|
+
// locations where there is no enclosing try statement.
|
|
7360
|
+
this.tryEntries = [{ tryLoc: "root" }];
|
|
7361
|
+
tryLocsList.forEach(pushTryEntry, this);
|
|
7362
|
+
this.reset(true);
|
|
7363
|
+
}
|
|
7364
|
+
|
|
7365
|
+
exports.keys = function(object) {
|
|
7366
|
+
var keys = [];
|
|
7367
|
+
for (var key in object) {
|
|
7368
|
+
keys.push(key);
|
|
7369
|
+
}
|
|
7370
|
+
keys.reverse();
|
|
7371
|
+
|
|
7372
|
+
// Rather than returning an object with a next method, we keep
|
|
7373
|
+
// things simple and return the next function itself.
|
|
7374
|
+
return function next() {
|
|
7375
|
+
while (keys.length) {
|
|
7376
|
+
var key = keys.pop();
|
|
7377
|
+
if (key in object) {
|
|
7378
|
+
next.value = key;
|
|
7379
|
+
next.done = false;
|
|
7380
|
+
return next;
|
|
7381
|
+
}
|
|
7382
|
+
}
|
|
7383
|
+
|
|
7384
|
+
// To avoid creating an additional object, we just hang the .value
|
|
7385
|
+
// and .done properties off the next function object itself. This
|
|
7386
|
+
// also ensures that the minifier will not anonymize the function.
|
|
7387
|
+
next.done = true;
|
|
7388
|
+
return next;
|
|
7389
|
+
};
|
|
7390
|
+
};
|
|
7391
|
+
|
|
7392
|
+
function values(iterable) {
|
|
7393
|
+
if (iterable) {
|
|
7394
|
+
var iteratorMethod = iterable[iteratorSymbol];
|
|
7395
|
+
if (iteratorMethod) {
|
|
7396
|
+
return iteratorMethod.call(iterable);
|
|
7397
|
+
}
|
|
7398
|
+
|
|
7399
|
+
if (typeof iterable.next === "function") {
|
|
7400
|
+
return iterable;
|
|
7401
|
+
}
|
|
7402
|
+
|
|
7403
|
+
if (!isNaN(iterable.length)) {
|
|
7404
|
+
var i = -1, next = function next() {
|
|
7405
|
+
while (++i < iterable.length) {
|
|
7406
|
+
if (hasOwn.call(iterable, i)) {
|
|
7407
|
+
next.value = iterable[i];
|
|
7408
|
+
next.done = false;
|
|
7409
|
+
return next;
|
|
7410
|
+
}
|
|
7411
|
+
}
|
|
7412
|
+
|
|
7413
|
+
next.value = undefined;
|
|
7414
|
+
next.done = true;
|
|
7415
|
+
|
|
7416
|
+
return next;
|
|
7417
|
+
};
|
|
7418
|
+
|
|
7419
|
+
return next.next = next;
|
|
7420
|
+
}
|
|
7421
|
+
}
|
|
7422
|
+
|
|
7423
|
+
// Return an iterator with no values.
|
|
7424
|
+
return { next: doneResult };
|
|
7425
|
+
}
|
|
7426
|
+
exports.values = values;
|
|
7427
|
+
|
|
7428
|
+
function doneResult() {
|
|
7429
|
+
return { value: undefined, done: true };
|
|
7430
|
+
}
|
|
7431
|
+
|
|
7432
|
+
Context.prototype = {
|
|
7433
|
+
constructor: Context,
|
|
7434
|
+
|
|
7435
|
+
reset: function(skipTempReset) {
|
|
7436
|
+
this.prev = 0;
|
|
7437
|
+
this.next = 0;
|
|
7438
|
+
// Resetting context._sent for legacy support of Babel's
|
|
7439
|
+
// function.sent implementation.
|
|
7440
|
+
this.sent = this._sent = undefined;
|
|
7441
|
+
this.done = false;
|
|
7442
|
+
this.delegate = null;
|
|
7443
|
+
|
|
7444
|
+
this.method = "next";
|
|
7445
|
+
this.arg = undefined;
|
|
7446
|
+
|
|
7447
|
+
this.tryEntries.forEach(resetTryEntry);
|
|
7448
|
+
|
|
7449
|
+
if (!skipTempReset) {
|
|
7450
|
+
for (var name in this) {
|
|
7451
|
+
// Not sure about the optimal order of these conditions:
|
|
7452
|
+
if (name.charAt(0) === "t" &&
|
|
7453
|
+
hasOwn.call(this, name) &&
|
|
7454
|
+
!isNaN(+name.slice(1))) {
|
|
7455
|
+
this[name] = undefined;
|
|
7456
|
+
}
|
|
7457
|
+
}
|
|
7458
|
+
}
|
|
7459
|
+
},
|
|
7460
|
+
|
|
7461
|
+
stop: function() {
|
|
7462
|
+
this.done = true;
|
|
7463
|
+
|
|
7464
|
+
var rootEntry = this.tryEntries[0];
|
|
7465
|
+
var rootRecord = rootEntry.completion;
|
|
7466
|
+
if (rootRecord.type === "throw") {
|
|
7467
|
+
throw rootRecord.arg;
|
|
7468
|
+
}
|
|
7469
|
+
|
|
7470
|
+
return this.rval;
|
|
7471
|
+
},
|
|
7472
|
+
|
|
7473
|
+
dispatchException: function(exception) {
|
|
7474
|
+
if (this.done) {
|
|
7475
|
+
throw exception;
|
|
7476
|
+
}
|
|
7477
|
+
|
|
7478
|
+
var context = this;
|
|
7479
|
+
function handle(loc, caught) {
|
|
7480
|
+
record.type = "throw";
|
|
7481
|
+
record.arg = exception;
|
|
7482
|
+
context.next = loc;
|
|
7483
|
+
|
|
7484
|
+
if (caught) {
|
|
7485
|
+
// If the dispatched exception was caught by a catch block,
|
|
7486
|
+
// then let that catch block handle the exception normally.
|
|
7487
|
+
context.method = "next";
|
|
7488
|
+
context.arg = undefined;
|
|
7489
|
+
}
|
|
7490
|
+
|
|
7491
|
+
return !! caught;
|
|
7492
|
+
}
|
|
7493
|
+
|
|
7494
|
+
for (var i = this.tryEntries.length - 1; i >= 0; --i) {
|
|
7495
|
+
var entry = this.tryEntries[i];
|
|
7496
|
+
var record = entry.completion;
|
|
7497
|
+
|
|
7498
|
+
if (entry.tryLoc === "root") {
|
|
7499
|
+
// Exception thrown outside of any try block that could handle
|
|
7500
|
+
// it, so set the completion value of the entire function to
|
|
7501
|
+
// throw the exception.
|
|
7502
|
+
return handle("end");
|
|
7503
|
+
}
|
|
7504
|
+
|
|
7505
|
+
if (entry.tryLoc <= this.prev) {
|
|
7506
|
+
var hasCatch = hasOwn.call(entry, "catchLoc");
|
|
7507
|
+
var hasFinally = hasOwn.call(entry, "finallyLoc");
|
|
7508
|
+
|
|
7509
|
+
if (hasCatch && hasFinally) {
|
|
7510
|
+
if (this.prev < entry.catchLoc) {
|
|
7511
|
+
return handle(entry.catchLoc, true);
|
|
7512
|
+
} else if (this.prev < entry.finallyLoc) {
|
|
7513
|
+
return handle(entry.finallyLoc);
|
|
7514
|
+
}
|
|
7515
|
+
|
|
7516
|
+
} else if (hasCatch) {
|
|
7517
|
+
if (this.prev < entry.catchLoc) {
|
|
7518
|
+
return handle(entry.catchLoc, true);
|
|
7519
|
+
}
|
|
7520
|
+
|
|
7521
|
+
} else if (hasFinally) {
|
|
7522
|
+
if (this.prev < entry.finallyLoc) {
|
|
7523
|
+
return handle(entry.finallyLoc);
|
|
7524
|
+
}
|
|
7525
|
+
|
|
7526
|
+
} else {
|
|
7527
|
+
throw new Error("try statement without catch or finally");
|
|
7528
|
+
}
|
|
7529
|
+
}
|
|
7530
|
+
}
|
|
7531
|
+
},
|
|
7532
|
+
|
|
7533
|
+
abrupt: function(type, arg) {
|
|
7534
|
+
for (var i = this.tryEntries.length - 1; i >= 0; --i) {
|
|
7535
|
+
var entry = this.tryEntries[i];
|
|
7536
|
+
if (entry.tryLoc <= this.prev &&
|
|
7537
|
+
hasOwn.call(entry, "finallyLoc") &&
|
|
7538
|
+
this.prev < entry.finallyLoc) {
|
|
7539
|
+
var finallyEntry = entry;
|
|
7540
|
+
break;
|
|
7541
|
+
}
|
|
7542
|
+
}
|
|
7543
|
+
|
|
7544
|
+
if (finallyEntry &&
|
|
7545
|
+
(type === "break" ||
|
|
7546
|
+
type === "continue") &&
|
|
7547
|
+
finallyEntry.tryLoc <= arg &&
|
|
7548
|
+
arg <= finallyEntry.finallyLoc) {
|
|
7549
|
+
// Ignore the finally entry if control is not jumping to a
|
|
7550
|
+
// location outside the try/catch block.
|
|
7551
|
+
finallyEntry = null;
|
|
7552
|
+
}
|
|
7553
|
+
|
|
7554
|
+
var record = finallyEntry ? finallyEntry.completion : {};
|
|
7555
|
+
record.type = type;
|
|
7556
|
+
record.arg = arg;
|
|
7557
|
+
|
|
7558
|
+
if (finallyEntry) {
|
|
7559
|
+
this.method = "next";
|
|
7560
|
+
this.next = finallyEntry.finallyLoc;
|
|
7561
|
+
return ContinueSentinel;
|
|
7562
|
+
}
|
|
7563
|
+
|
|
7564
|
+
return this.complete(record);
|
|
7565
|
+
},
|
|
7566
|
+
|
|
7567
|
+
complete: function(record, afterLoc) {
|
|
7568
|
+
if (record.type === "throw") {
|
|
7569
|
+
throw record.arg;
|
|
7570
|
+
}
|
|
7571
|
+
|
|
7572
|
+
if (record.type === "break" ||
|
|
7573
|
+
record.type === "continue") {
|
|
7574
|
+
this.next = record.arg;
|
|
7575
|
+
} else if (record.type === "return") {
|
|
7576
|
+
this.rval = this.arg = record.arg;
|
|
7577
|
+
this.method = "return";
|
|
7578
|
+
this.next = "end";
|
|
7579
|
+
} else if (record.type === "normal" && afterLoc) {
|
|
7580
|
+
this.next = afterLoc;
|
|
7581
|
+
}
|
|
7582
|
+
|
|
7583
|
+
return ContinueSentinel;
|
|
7584
|
+
},
|
|
7585
|
+
|
|
7586
|
+
finish: function(finallyLoc) {
|
|
7587
|
+
for (var i = this.tryEntries.length - 1; i >= 0; --i) {
|
|
7588
|
+
var entry = this.tryEntries[i];
|
|
7589
|
+
if (entry.finallyLoc === finallyLoc) {
|
|
7590
|
+
this.complete(entry.completion, entry.afterLoc);
|
|
7591
|
+
resetTryEntry(entry);
|
|
7592
|
+
return ContinueSentinel;
|
|
7593
|
+
}
|
|
7594
|
+
}
|
|
7595
|
+
},
|
|
7596
|
+
|
|
7597
|
+
"catch": function(tryLoc) {
|
|
7598
|
+
for (var i = this.tryEntries.length - 1; i >= 0; --i) {
|
|
7599
|
+
var entry = this.tryEntries[i];
|
|
7600
|
+
if (entry.tryLoc === tryLoc) {
|
|
7601
|
+
var record = entry.completion;
|
|
7602
|
+
if (record.type === "throw") {
|
|
7603
|
+
var thrown = record.arg;
|
|
7604
|
+
resetTryEntry(entry);
|
|
7605
|
+
}
|
|
7606
|
+
return thrown;
|
|
7607
|
+
}
|
|
7608
|
+
}
|
|
7609
|
+
|
|
7610
|
+
// The context.catch method must only be called with a location
|
|
7611
|
+
// argument that corresponds to a known catch block.
|
|
7612
|
+
throw new Error("illegal catch attempt");
|
|
7613
|
+
},
|
|
7614
|
+
|
|
7615
|
+
delegateYield: function(iterable, resultName, nextLoc) {
|
|
7616
|
+
this.delegate = {
|
|
7617
|
+
iterator: values(iterable),
|
|
7618
|
+
resultName: resultName,
|
|
7619
|
+
nextLoc: nextLoc
|
|
7620
|
+
};
|
|
7621
|
+
|
|
7622
|
+
if (this.method === "next") {
|
|
7623
|
+
// Deliberately forget the last sent value so that we don't
|
|
7624
|
+
// accidentally pass it on to the delegate.
|
|
7625
|
+
this.arg = undefined;
|
|
7626
|
+
}
|
|
7627
|
+
|
|
7628
|
+
return ContinueSentinel;
|
|
7629
|
+
}
|
|
7630
|
+
};
|
|
7631
|
+
|
|
7632
|
+
// Regardless of whether this script is executing as a CommonJS module
|
|
7633
|
+
// or not, return the runtime object so that we can declare the variable
|
|
7634
|
+
// regeneratorRuntime in the outer scope, which allows this module to be
|
|
7635
|
+
// injected easily by `bin/regenerator --include-runtime script.js`.
|
|
7636
|
+
return exports;
|
|
7637
|
+
|
|
7638
|
+
}(
|
|
7639
|
+
// If this script is executing as a CommonJS module, use module.exports
|
|
7640
|
+
// as the regeneratorRuntime namespace. Otherwise create a new empty
|
|
7641
|
+
// object. Either way, the resulting object will be used to initialize
|
|
7642
|
+
// the regeneratorRuntime variable at the top of this file.
|
|
7643
|
+
true ? module.exports : undefined
|
|
7644
|
+
));
|
|
7645
|
+
|
|
7646
|
+
try {
|
|
7647
|
+
regeneratorRuntime = runtime;
|
|
7648
|
+
} catch (accidentalStrictMode) {
|
|
7649
|
+
// This module should not be running in strict mode, so the above
|
|
7650
|
+
// assignment should always work unless something is misconfigured. Just
|
|
7651
|
+
// in case runtime.js accidentally runs in strict mode, we can escape
|
|
7652
|
+
// strict mode using a global Function call. This could conceivably fail
|
|
7653
|
+
// if a Content Security Policy forbids using Function, but in that case
|
|
7654
|
+
// the proper solution is to fix the accidental strict mode problem. If
|
|
7655
|
+
// you've misconfigured your bundler to force strict mode and applied a
|
|
7656
|
+
// CSP to forbid Function, and you're not willing to fix either of those
|
|
7657
|
+
// problems, please detail your unique predicament in a GitHub issue.
|
|
7658
|
+
Function("r", "regeneratorRuntime = r")(runtime);
|
|
7659
|
+
}
|
|
7660
|
+
|
|
7661
|
+
|
|
7662
|
+
/***/ }),
|
|
7663
|
+
|
|
7664
|
+
/***/ "./node_modules/webpack/buildin/global.js":
|
|
7665
|
+
/*!***********************************!*\
|
|
7666
|
+
!*** (webpack)/buildin/global.js ***!
|
|
7667
|
+
\***********************************/
|
|
7668
|
+
/*! no static exports found */
|
|
7669
|
+
/***/ (function(module, exports) {
|
|
7670
|
+
|
|
7671
|
+
var g;
|
|
7672
|
+
|
|
7673
|
+
// This works in non-strict mode
|
|
7674
|
+
g = (function() {
|
|
7675
|
+
return this;
|
|
7676
|
+
})();
|
|
7677
|
+
|
|
7678
|
+
try {
|
|
7679
|
+
// This works if eval is allowed (see CSP)
|
|
7680
|
+
g = g || new Function("return this")();
|
|
7681
|
+
} catch (e) {
|
|
7682
|
+
// This works if the window reference is available
|
|
7683
|
+
if (typeof window === "object") g = window;
|
|
7684
|
+
}
|
|
7685
|
+
|
|
7686
|
+
// g can still be undefined, but nothing to do about it...
|
|
7687
|
+
// We return undefined, instead of nothing here, so it's
|
|
7688
|
+
// easier to handle this case. if(!global) { ...}
|
|
7689
|
+
|
|
7690
|
+
module.exports = g;
|
|
7691
|
+
|
|
7692
|
+
|
|
7693
|
+
/***/ }),
|
|
7694
|
+
|
|
7695
|
+
/***/ "./src/core.js":
|
|
7696
|
+
/*!*********************!*\
|
|
7697
|
+
!*** ./src/core.js ***!
|
|
7698
|
+
\*********************/
|
|
7699
|
+
/*! exports provided: JSONEditor */
|
|
7700
|
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
7701
|
+
|
|
7702
|
+
"use strict";
|
|
7703
|
+
__webpack_require__.r(__webpack_exports__);
|
|
7704
|
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "JSONEditor", function() { return JSONEditor; });
|
|
7705
|
+
/* harmony import */ var regenerator_runtime_runtime_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! regenerator-runtime/runtime.js */ "./node_modules/regenerator-runtime/runtime.js");
|
|
7706
|
+
/* harmony import */ var regenerator_runtime_runtime_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(regenerator_runtime_runtime_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
7707
|
+
/* harmony import */ var core_js_modules_es_date_to_string_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es.date.to-string.js */ "./node_modules/core-js/modules/es.date.to-string.js");
|
|
7708
|
+
/* harmony import */ var core_js_modules_es_date_to_string_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_date_to_string_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
7709
|
+
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! core-js/modules/es.object.to-string.js */ "./node_modules/core-js/modules/es.object.to-string.js");
|
|
7710
|
+
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_2__);
|
|
7711
|
+
/* harmony import */ var core_js_modules_es_regexp_to_string_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! core-js/modules/es.regexp.to-string.js */ "./node_modules/core-js/modules/es.regexp.to-string.js");
|
|
7712
|
+
/* harmony import */ var core_js_modules_es_regexp_to_string_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_regexp_to_string_js__WEBPACK_IMPORTED_MODULE_3__);
|
|
7713
|
+
/* harmony import */ var core_js_modules_es_array_reduce_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! core-js/modules/es.array.reduce.js */ "./node_modules/core-js/modules/es.array.reduce.js");
|
|
7714
|
+
/* harmony import */ var core_js_modules_es_array_reduce_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_reduce_js__WEBPACK_IMPORTED_MODULE_4__);
|
|
7715
|
+
/* 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");
|
|
7716
|
+
/* 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__);
|
|
7717
|
+
/* harmony import */ var core_js_modules_es_array_find_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! core-js/modules/es.array.find.js */ "./node_modules/core-js/modules/es.array.find.js");
|
|
7718
|
+
/* harmony import */ var core_js_modules_es_array_find_js__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_find_js__WEBPACK_IMPORTED_MODULE_6__);
|
|
7719
|
+
/* harmony import */ var core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! core-js/modules/es.array.for-each.js */ "./node_modules/core-js/modules/es.array.for-each.js");
|
|
7720
|
+
/* harmony import */ var core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_7__);
|
|
7721
|
+
/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! core-js/modules/web.dom-collections.for-each.js */ "./node_modules/core-js/modules/web.dom-collections.for-each.js");
|
|
7722
|
+
/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_8__);
|
|
7723
|
+
/* harmony import */ var core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! core-js/modules/es.object.keys.js */ "./node_modules/core-js/modules/es.object.keys.js");
|
|
7724
|
+
/* harmony import */ var core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_9__);
|
|
7725
|
+
/* harmony import */ var core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! core-js/modules/es.array.concat.js */ "./node_modules/core-js/modules/es.array.concat.js");
|
|
7726
|
+
/* harmony import */ var core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_10__);
|
|
7727
|
+
/* harmony import */ var core_js_modules_es_object_assign_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! core-js/modules/es.object.assign.js */ "./node_modules/core-js/modules/es.object.assign.js");
|
|
7728
|
+
/* harmony import */ var core_js_modules_es_object_assign_js__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_assign_js__WEBPACK_IMPORTED_MODULE_11__);
|
|
7729
|
+
/* 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");
|
|
7730
|
+
/* 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__);
|
|
7731
|
+
/* harmony import */ var core_js_modules_es_promise_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! core-js/modules/es.promise.js */ "./node_modules/core-js/modules/es.promise.js");
|
|
7732
|
+
/* harmony import */ var core_js_modules_es_promise_js__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_promise_js__WEBPACK_IMPORTED_MODULE_13__);
|
|
7733
|
+
/* harmony import */ var core_js_modules_es_array_is_array_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! core-js/modules/es.array.is-array.js */ "./node_modules/core-js/modules/es.array.is-array.js");
|
|
7734
|
+
/* harmony import */ var core_js_modules_es_array_is_array_js__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_is_array_js__WEBPACK_IMPORTED_MODULE_14__);
|
|
7735
|
+
/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! core-js/modules/es.symbol.js */ "./node_modules/core-js/modules/es.symbol.js");
|
|
7736
|
+
/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_15__);
|
|
7737
|
+
/* harmony import */ var core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! core-js/modules/es.symbol.description.js */ "./node_modules/core-js/modules/es.symbol.description.js");
|
|
7738
|
+
/* harmony import */ var core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_16___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_16__);
|
|
7739
|
+
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! core-js/modules/es.symbol.iterator.js */ "./node_modules/core-js/modules/es.symbol.iterator.js");
|
|
7740
|
+
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_17___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_17__);
|
|
7741
|
+
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! core-js/modules/es.array.iterator.js */ "./node_modules/core-js/modules/es.array.iterator.js");
|
|
7742
|
+
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_18___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_18__);
|
|
7743
|
+
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! core-js/modules/es.string.iterator.js */ "./node_modules/core-js/modules/es.string.iterator.js");
|
|
7744
|
+
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_19___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_19__);
|
|
7745
|
+
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! core-js/modules/web.dom-collections.iterator.js */ "./node_modules/core-js/modules/web.dom-collections.iterator.js");
|
|
7746
|
+
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_20___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_20__);
|
|
7747
|
+
/* harmony import */ var core_js_modules_es_array_from_js__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! core-js/modules/es.array.from.js */ "./node_modules/core-js/modules/es.array.from.js");
|
|
7748
|
+
/* harmony import */ var core_js_modules_es_array_from_js__WEBPACK_IMPORTED_MODULE_21___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_from_js__WEBPACK_IMPORTED_MODULE_21__);
|
|
7749
|
+
/* harmony import */ var core_js_modules_es_array_slice_js__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! core-js/modules/es.array.slice.js */ "./node_modules/core-js/modules/es.array.slice.js");
|
|
7750
|
+
/* harmony import */ var core_js_modules_es_array_slice_js__WEBPACK_IMPORTED_MODULE_22___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_slice_js__WEBPACK_IMPORTED_MODULE_22__);
|
|
7751
|
+
/* harmony import */ var core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! core-js/modules/es.function.name.js */ "./node_modules/core-js/modules/es.function.name.js");
|
|
7752
|
+
/* harmony import */ var core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_23___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_23__);
|
|
7753
|
+
/* harmony import */ var _defaults_js__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(/*! ./defaults.js */ "./src/defaults.js");
|
|
7754
|
+
/* harmony import */ var _validator_js__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(/*! ./validator.js */ "./src/validator.js");
|
|
7755
|
+
/* harmony import */ var _schemaloader_js__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(/*! ./schemaloader.js */ "./src/schemaloader.js");
|
|
7756
|
+
/* harmony import */ var _editors_index_js__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(/*! ./editors/index.js */ "./src/editors/index.js");
|
|
7757
|
+
/* harmony import */ var _templates_index_js__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(/*! ./templates/index.js */ "./src/templates/index.js");
|
|
7758
|
+
/* harmony import */ var _iconlibs_index_js__WEBPACK_IMPORTED_MODULE_29__ = __webpack_require__(/*! ./iconlibs/index.js */ "./src/iconlibs/index.js");
|
|
7759
|
+
/* harmony import */ var _themes_index_js__WEBPACK_IMPORTED_MODULE_30__ = __webpack_require__(/*! ./themes/index.js */ "./src/themes/index.js");
|
|
7760
|
+
/* harmony import */ var _utilities_js__WEBPACK_IMPORTED_MODULE_31__ = __webpack_require__(/*! ./utilities.js */ "./src/utilities.js");
|
|
7761
|
+
/* harmony import */ var _editor__WEBPACK_IMPORTED_MODULE_32__ = __webpack_require__(/*! ./editor */ "./src/editor.js");
|
|
7762
|
+
/* harmony import */ var _theme__WEBPACK_IMPORTED_MODULE_33__ = __webpack_require__(/*! ./theme */ "./src/theme.js");
|
|
7763
|
+
/* harmony import */ var _iconlib__WEBPACK_IMPORTED_MODULE_34__ = __webpack_require__(/*! ./iconlib */ "./src/iconlib.js");
|
|
7764
|
+
/* harmony import */ var _style_css_js__WEBPACK_IMPORTED_MODULE_35__ = __webpack_require__(/*! ./style.css.js */ "./src/style.css.js");
|
|
6036
7765
|
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
|
|
6037
7766
|
|
|
6038
7767
|
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
@@ -6067,6 +7796,12 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
6067
7796
|
|
|
6068
7797
|
|
|
6069
7798
|
|
|
7799
|
+
|
|
7800
|
+
|
|
7801
|
+
|
|
7802
|
+
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
|
|
7803
|
+
|
|
7804
|
+
function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
|
|
6070
7805
|
|
|
6071
7806
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
6072
7807
|
|
|
@@ -6096,7 +7831,7 @@ var JSONEditor = /*#__PURE__*/function () {
|
|
|
6096
7831
|
|
|
6097
7832
|
if (!(element instanceof Element)) throw new Error('element should be an instance of Element');
|
|
6098
7833
|
this.element = element;
|
|
6099
|
-
this.options = Object(
|
|
7834
|
+
this.options = Object(_utilities_js__WEBPACK_IMPORTED_MODULE_31__["extend"])({}, JSONEditor.defaults.options, options);
|
|
6100
7835
|
this.ready = false;
|
|
6101
7836
|
this.copyClipboard = null;
|
|
6102
7837
|
this.schema = this.options.schema;
|
|
@@ -6110,10 +7845,12 @@ var JSONEditor = /*#__PURE__*/function () {
|
|
|
6110
7845
|
/* Load editors and selected theme style rules */
|
|
6111
7846
|
|
|
6112
7847
|
if (!themeClass) throw new Error("Unknown theme ".concat(themeName));
|
|
6113
|
-
this.element.setAttribute('data-theme', themeName);
|
|
7848
|
+
this.element.setAttribute('data-theme', themeName);
|
|
7849
|
+
this.element.classList.add('je-not-loaded');
|
|
7850
|
+
this.element.classList.remove('je-ready'); // eslint-disable-next-line new-cap
|
|
6114
7851
|
|
|
6115
7852
|
this.theme = new themeClass(this);
|
|
6116
|
-
var rules = Object(
|
|
7853
|
+
var rules = Object(_utilities_js__WEBPACK_IMPORTED_MODULE_31__["extend"])(_style_css_js__WEBPACK_IMPORTED_MODULE_35__["default"], this.getEditorsRules());
|
|
6117
7854
|
/* Call addNewStyleRulesToShadowRoot if shadowRoot is found, otherwise call addNewStyleRules */
|
|
6118
7855
|
|
|
6119
7856
|
var addRules = function addRules(themeName, rules, shadowRoot) {
|
|
@@ -6122,7 +7859,7 @@ var JSONEditor = /*#__PURE__*/function () {
|
|
|
6122
7859
|
|
|
6123
7860
|
if (!this.theme.options.disable_theme_rules) {
|
|
6124
7861
|
/* Attempt to locate a shadowRoot parent (i.e. in Web Components) */
|
|
6125
|
-
var shadowRoot = Object(
|
|
7862
|
+
var shadowRoot = Object(_utilities_js__WEBPACK_IMPORTED_MODULE_31__["getShadowParent"])(this.element);
|
|
6126
7863
|
addRules('default', rules, shadowRoot);
|
|
6127
7864
|
|
|
6128
7865
|
if (typeof themeClass.rules !== 'undefined') {
|
|
@@ -6137,82 +7874,103 @@ var JSONEditor = /*#__PURE__*/function () {
|
|
|
6137
7874
|
if (iconClass) this.iconlib = new iconClass();
|
|
6138
7875
|
this.root_container = this.theme.getContainer();
|
|
6139
7876
|
this.element.appendChild(this.root_container);
|
|
6140
|
-
|
|
6141
|
-
|
|
6142
|
-
var fetchUrl = document.location.origin + document.location.pathname.toString();
|
|
6143
|
-
var loader = new _schemaloader_js__WEBPACK_IMPORTED_MODULE_24__["SchemaLoader"](this.options);
|
|
6144
|
-
var location = document.location.toString();
|
|
6145
|
-
|
|
6146
|
-
this.expandSchema = function (schema, fileBase) {
|
|
6147
|
-
return loader.expandSchema(schema, fileBase);
|
|
6148
|
-
};
|
|
6149
|
-
|
|
6150
|
-
this.expandRefs = function (schema, fileBase) {
|
|
6151
|
-
return loader.expandRefs(schema, fileBase);
|
|
6152
|
-
};
|
|
6153
|
-
|
|
6154
|
-
this.refs = loader.refs;
|
|
6155
|
-
loader.load(this.schema, function (schema) {
|
|
6156
|
-
var validatorOptions = _this.options.custom_validators ? {
|
|
6157
|
-
custom_validators: _this.options.custom_validators
|
|
6158
|
-
} : {};
|
|
6159
|
-
_this.validator = new _validator_js__WEBPACK_IMPORTED_MODULE_23__["Validator"](_this, null, validatorOptions, JSONEditor.defaults);
|
|
6160
|
-
|
|
6161
|
-
var editorClass = _this.getEditorClass(schema);
|
|
6162
|
-
|
|
6163
|
-
_this.root = _this.createEditor(editorClass, {
|
|
6164
|
-
jsoneditor: _this,
|
|
6165
|
-
schema: schema,
|
|
6166
|
-
required: true,
|
|
6167
|
-
container: _this.root_container
|
|
6168
|
-
});
|
|
6169
|
-
|
|
6170
|
-
_this.root.preBuild();
|
|
6171
|
-
|
|
6172
|
-
_this.root.build();
|
|
7877
|
+
this.promise = this.load();
|
|
7878
|
+
}
|
|
6173
7879
|
|
|
6174
|
-
|
|
6175
|
-
|
|
7880
|
+
_createClass(JSONEditor, [{
|
|
7881
|
+
key: "load",
|
|
7882
|
+
value: function () {
|
|
7883
|
+
var _load = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee() {
|
|
7884
|
+
var _this2 = this;
|
|
6176
7885
|
|
|
7886
|
+
var fetchUrl, loader, location, schema, validatorOptions, editorClass;
|
|
7887
|
+
return regeneratorRuntime.wrap(function _callee$(_context) {
|
|
7888
|
+
while (1) {
|
|
7889
|
+
switch (_context.prev = _context.next) {
|
|
7890
|
+
case 0:
|
|
7891
|
+
fetchUrl = document.location.origin + document.location.pathname.toString();
|
|
7892
|
+
loader = new _schemaloader_js__WEBPACK_IMPORTED_MODULE_26__["SchemaLoader"](this.options);
|
|
7893
|
+
|
|
7894
|
+
this.expandSchema = function (schema) {
|
|
7895
|
+
return loader.expandSchema(schema);
|
|
7896
|
+
};
|
|
7897
|
+
|
|
7898
|
+
this.expandRefs = function (schema, fileBase) {
|
|
7899
|
+
return loader.expandRefs(schema, fileBase);
|
|
7900
|
+
};
|
|
7901
|
+
|
|
7902
|
+
location = document.location.toString();
|
|
7903
|
+
_context.next = 7;
|
|
7904
|
+
return loader.load(this.schema, fetchUrl, location);
|
|
7905
|
+
|
|
7906
|
+
case 7:
|
|
7907
|
+
schema = _context.sent;
|
|
7908
|
+
validatorOptions = this.options.custom_validators ? {
|
|
7909
|
+
custom_validators: this.options.custom_validators
|
|
7910
|
+
} : {};
|
|
7911
|
+
this.validator = new _validator_js__WEBPACK_IMPORTED_MODULE_25__["Validator"](this, null, validatorOptions, JSONEditor.defaults);
|
|
7912
|
+
editorClass = this.getEditorClass(schema);
|
|
7913
|
+
this.root = this.createEditor(editorClass, {
|
|
7914
|
+
jsoneditor: this,
|
|
7915
|
+
schema: schema,
|
|
7916
|
+
required: true,
|
|
7917
|
+
container: this.root_container
|
|
7918
|
+
});
|
|
7919
|
+
this.root.preBuild();
|
|
7920
|
+
this.root.build();
|
|
7921
|
+
this.root.postBuild();
|
|
7922
|
+
/* Starting data */
|
|
6177
7923
|
|
|
6178
|
-
|
|
6179
|
-
|
|
7924
|
+
if (Object(_utilities_js__WEBPACK_IMPORTED_MODULE_31__["hasOwnProperty"])(this.options, 'startval')) this.root.setValue(this.options.startval);
|
|
7925
|
+
this.validation_results = this.validator.validate(this.root.getValue());
|
|
7926
|
+
this.root.showValidationErrors(this.validation_results);
|
|
7927
|
+
this.ready = true;
|
|
7928
|
+
this.element.classList.remove('je-not-loaded');
|
|
7929
|
+
this.element.classList.add('je-ready');
|
|
7930
|
+
/* Fire ready event asynchronously */
|
|
6180
7931
|
|
|
6181
|
-
|
|
7932
|
+
window.requestAnimationFrame(function () {
|
|
7933
|
+
if (!_this2.ready) return;
|
|
7934
|
+
_this2.validation_results = _this2.validator.validate(_this2.root.getValue());
|
|
6182
7935
|
|
|
6183
|
-
|
|
6184
|
-
/* Fire ready event asynchronously */
|
|
7936
|
+
_this2.root.showValidationErrors(_this2.validation_results);
|
|
6185
7937
|
|
|
6186
|
-
|
|
6187
|
-
if (!_this.ready) return;
|
|
6188
|
-
_this.validation_results = _this.validator.validate(_this.root.getValue());
|
|
7938
|
+
_this2.trigger('ready');
|
|
6189
7939
|
|
|
6190
|
-
|
|
7940
|
+
_this2.trigger('change');
|
|
7941
|
+
});
|
|
6191
7942
|
|
|
6192
|
-
|
|
7943
|
+
case 22:
|
|
7944
|
+
case "end":
|
|
7945
|
+
return _context.stop();
|
|
7946
|
+
}
|
|
7947
|
+
}
|
|
7948
|
+
}, _callee, this);
|
|
7949
|
+
}));
|
|
6193
7950
|
|
|
6194
|
-
|
|
6195
|
-
|
|
6196
|
-
|
|
6197
|
-
}
|
|
7951
|
+
function load() {
|
|
7952
|
+
return _load.apply(this, arguments);
|
|
7953
|
+
}
|
|
6198
7954
|
|
|
6199
|
-
|
|
7955
|
+
return load;
|
|
7956
|
+
}()
|
|
7957
|
+
}, {
|
|
6200
7958
|
key: "getValue",
|
|
6201
7959
|
value: function getValue() {
|
|
6202
|
-
if (!this.ready) throw new Error(
|
|
7960
|
+
if (!this.ready) throw new Error('JSON Editor not ready yet. Make sure the load method is complete');
|
|
6203
7961
|
return this.root.getValue();
|
|
6204
7962
|
}
|
|
6205
7963
|
}, {
|
|
6206
7964
|
key: "setValue",
|
|
6207
7965
|
value: function setValue(value) {
|
|
6208
|
-
if (!this.ready) throw new Error(
|
|
7966
|
+
if (!this.ready) throw new Error('JSON Editor not ready yet. Make sure the load method is complete');
|
|
6209
7967
|
this.root.setValue(value);
|
|
6210
7968
|
return this;
|
|
6211
7969
|
}
|
|
6212
7970
|
}, {
|
|
6213
7971
|
key: "validate",
|
|
6214
7972
|
value: function validate(value) {
|
|
6215
|
-
if (!this.ready) throw new Error(
|
|
7973
|
+
if (!this.ready) throw new Error('JSON Editor not ready yet. Make sure the load method is complete');
|
|
6216
7974
|
/* Custom value */
|
|
6217
7975
|
|
|
6218
7976
|
if (arguments.length === 1) {
|
|
@@ -6305,7 +8063,7 @@ var JSONEditor = /*#__PURE__*/function () {
|
|
|
6305
8063
|
key: "getEditorsRules",
|
|
6306
8064
|
value: function getEditorsRules() {
|
|
6307
8065
|
var extendRule = function extendRule(rules, editorClass) {
|
|
6308
|
-
return editorClass.rules ? Object(
|
|
8066
|
+
return editorClass.rules ? Object(_utilities_js__WEBPACK_IMPORTED_MODULE_31__["extend"])(rules, editorClass.rules) : rules;
|
|
6309
8067
|
};
|
|
6310
8068
|
|
|
6311
8069
|
return Object.values(JSONEditor.defaults.editors).reduce(extendRule, {});
|
|
@@ -6327,34 +8085,34 @@ var JSONEditor = /*#__PURE__*/function () {
|
|
|
6327
8085
|
key: "createEditor",
|
|
6328
8086
|
value: function createEditor(editorClass, options) {
|
|
6329
8087
|
var depthCounter = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 1;
|
|
6330
|
-
options = Object(
|
|
8088
|
+
options = Object(_utilities_js__WEBPACK_IMPORTED_MODULE_31__["extend"])({}, editorClass.options || {}, options); // eslint-disable-next-line new-cap
|
|
6331
8089
|
|
|
6332
8090
|
return new editorClass(options, JSONEditor.defaults, depthCounter);
|
|
6333
8091
|
}
|
|
6334
8092
|
}, {
|
|
6335
8093
|
key: "onChange",
|
|
6336
8094
|
value: function onChange() {
|
|
6337
|
-
var
|
|
8095
|
+
var _this3 = this;
|
|
6338
8096
|
|
|
6339
8097
|
if (!this.ready) return;
|
|
6340
8098
|
if (this.firing_change) return;
|
|
6341
8099
|
this.firing_change = true;
|
|
6342
8100
|
window.requestAnimationFrame(function () {
|
|
6343
|
-
|
|
6344
|
-
if (!
|
|
8101
|
+
_this3.firing_change = false;
|
|
8102
|
+
if (!_this3.ready) return;
|
|
6345
8103
|
/* Validate and cache results */
|
|
6346
8104
|
|
|
6347
|
-
|
|
8105
|
+
_this3.validation_results = _this3.validator.validate(_this3.root.getValue());
|
|
6348
8106
|
|
|
6349
|
-
if (
|
|
6350
|
-
|
|
8107
|
+
if (_this3.options.show_errors !== 'never') {
|
|
8108
|
+
_this3.root.showValidationErrors(_this3.validation_results);
|
|
6351
8109
|
} else {
|
|
6352
|
-
|
|
8110
|
+
_this3.root.showValidationErrors([]);
|
|
6353
8111
|
}
|
|
6354
8112
|
/* Fire change event */
|
|
6355
8113
|
|
|
6356
8114
|
|
|
6357
|
-
|
|
8115
|
+
_this3.trigger('change');
|
|
6358
8116
|
});
|
|
6359
8117
|
return this;
|
|
6360
8118
|
}
|
|
@@ -6526,14 +8284,14 @@ var JSONEditor = /*#__PURE__*/function () {
|
|
|
6526
8284
|
|
|
6527
8285
|
return JSONEditor;
|
|
6528
8286
|
}();
|
|
6529
|
-
JSONEditor.defaults =
|
|
6530
|
-
JSONEditor.AbstractEditor =
|
|
6531
|
-
JSONEditor.AbstractTheme =
|
|
6532
|
-
JSONEditor.AbstractIconLib =
|
|
6533
|
-
Object.assign(JSONEditor.defaults.themes,
|
|
6534
|
-
Object.assign(JSONEditor.defaults.editors,
|
|
6535
|
-
Object.assign(JSONEditor.defaults.templates,
|
|
6536
|
-
Object.assign(JSONEditor.defaults.iconlibs,
|
|
8287
|
+
JSONEditor.defaults = _defaults_js__WEBPACK_IMPORTED_MODULE_24__["defaults"];
|
|
8288
|
+
JSONEditor.AbstractEditor = _editor__WEBPACK_IMPORTED_MODULE_32__["AbstractEditor"];
|
|
8289
|
+
JSONEditor.AbstractTheme = _theme__WEBPACK_IMPORTED_MODULE_33__["AbstractTheme"];
|
|
8290
|
+
JSONEditor.AbstractIconLib = _iconlib__WEBPACK_IMPORTED_MODULE_34__["AbstractIconLib"];
|
|
8291
|
+
Object.assign(JSONEditor.defaults.themes, _themes_index_js__WEBPACK_IMPORTED_MODULE_30__["themes"]);
|
|
8292
|
+
Object.assign(JSONEditor.defaults.editors, _editors_index_js__WEBPACK_IMPORTED_MODULE_27__["editors"]);
|
|
8293
|
+
Object.assign(JSONEditor.defaults.templates, _templates_index_js__WEBPACK_IMPORTED_MODULE_28__["templates"]);
|
|
8294
|
+
Object.assign(JSONEditor.defaults.iconlibs, _iconlibs_index_js__WEBPACK_IMPORTED_MODULE_29__["iconlibs"]);
|
|
6537
8295
|
|
|
6538
8296
|
/***/ }),
|
|
6539
8297
|
|
|
@@ -7040,10 +8798,16 @@ function upload(type, file, cbs) {
|
|
|
7040
8798
|
/* String translate function */
|
|
7041
8799
|
|
|
7042
8800
|
|
|
7043
|
-
function translate(key, variables) {
|
|
8801
|
+
function translate(key, variables, schema) {
|
|
8802
|
+
var schemaMessages = {};
|
|
8803
|
+
|
|
8804
|
+
if (schema && schema.options && schema.options.error_messages && schema.options.error_messages[defaults.language]) {
|
|
8805
|
+
schemaMessages = schema.options.error_messages[defaults.language];
|
|
8806
|
+
}
|
|
8807
|
+
|
|
7044
8808
|
var lang = defaults.languages[defaults.language];
|
|
7045
8809
|
if (!lang) throw new Error("Unknown language ".concat(defaults.language));
|
|
7046
|
-
var string = lang[key] || defaults.languages[default_language][key] || key;
|
|
8810
|
+
var string = schemaMessages[key] || lang[key] || defaults.languages[default_language][key] || key;
|
|
7047
8811
|
|
|
7048
8812
|
if (variables) {
|
|
7049
8813
|
for (var i = 0; i < variables.length; i++) {
|
|
@@ -7064,6 +8828,7 @@ function translateProperty(text, variables) {
|
|
|
7064
8828
|
|
|
7065
8829
|
var options = {
|
|
7066
8830
|
upload: upload,
|
|
8831
|
+
use_name_attributes: true,
|
|
7067
8832
|
prompt_before_delete: true,
|
|
7068
8833
|
use_default_values: true,
|
|
7069
8834
|
max_depth: 0
|
|
@@ -8246,33 +10011,35 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
8246
10011
|
/* harmony import */ var core_js_modules_es_array_map_js__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_map_js__WEBPACK_IMPORTED_MODULE_9__);
|
|
8247
10012
|
/* harmony import */ var core_js_modules_es_array_filter_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! core-js/modules/es.array.filter.js */ "./node_modules/core-js/modules/es.array.filter.js");
|
|
8248
10013
|
/* harmony import */ var core_js_modules_es_array_filter_js__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_filter_js__WEBPACK_IMPORTED_MODULE_10__);
|
|
8249
|
-
/* harmony import */ var
|
|
8250
|
-
/* harmony import */ var
|
|
8251
|
-
/* harmony import */ var
|
|
8252
|
-
/* harmony import */ var
|
|
8253
|
-
/* harmony import */ var
|
|
8254
|
-
/* harmony import */ var
|
|
8255
|
-
/* harmony import */ var
|
|
8256
|
-
/* harmony import */ var
|
|
8257
|
-
/* harmony import */ var
|
|
8258
|
-
/* harmony import */ var
|
|
8259
|
-
/* harmony import */ var
|
|
8260
|
-
/* harmony import */ var
|
|
8261
|
-
/* harmony import */ var
|
|
8262
|
-
/* harmony import */ var
|
|
8263
|
-
/* harmony import */ var
|
|
8264
|
-
/* harmony import */ var
|
|
8265
|
-
/* harmony import */ var
|
|
8266
|
-
/* harmony import */ var
|
|
8267
|
-
/* harmony import */ var
|
|
8268
|
-
/* harmony import */ var
|
|
8269
|
-
/* harmony import */ var
|
|
8270
|
-
/* harmony import */ var
|
|
8271
|
-
/* harmony import */ var
|
|
8272
|
-
/* harmony import */ var
|
|
8273
|
-
/* harmony import */ var
|
|
8274
|
-
/* harmony import */ var
|
|
8275
|
-
/* harmony import */ var
|
|
10014
|
+
/* harmony import */ var core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! core-js/modules/es.object.keys.js */ "./node_modules/core-js/modules/es.object.keys.js");
|
|
10015
|
+
/* harmony import */ var core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_11__);
|
|
10016
|
+
/* harmony import */ var core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! core-js/modules/es.object.set-prototype-of.js */ "./node_modules/core-js/modules/es.object.set-prototype-of.js");
|
|
10017
|
+
/* harmony import */ var core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_12__);
|
|
10018
|
+
/* harmony import */ var core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! core-js/modules/es.object.get-prototype-of.js */ "./node_modules/core-js/modules/es.object.get-prototype-of.js");
|
|
10019
|
+
/* harmony import */ var core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_13__);
|
|
10020
|
+
/* harmony import */ var core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! core-js/modules/es.reflect.construct.js */ "./node_modules/core-js/modules/es.reflect.construct.js");
|
|
10021
|
+
/* harmony import */ var core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_14__);
|
|
10022
|
+
/* harmony import */ var core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! core-js/modules/es.object.create.js */ "./node_modules/core-js/modules/es.object.create.js");
|
|
10023
|
+
/* harmony import */ var core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_15__);
|
|
10024
|
+
/* harmony import */ var core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! core-js/modules/es.reflect.get.js */ "./node_modules/core-js/modules/es.reflect.get.js");
|
|
10025
|
+
/* harmony import */ var core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_16___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_16__);
|
|
10026
|
+
/* harmony import */ var core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! core-js/modules/es.object.get-own-property-descriptor.js */ "./node_modules/core-js/modules/es.object.get-own-property-descriptor.js");
|
|
10027
|
+
/* harmony import */ var core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_17___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_17__);
|
|
10028
|
+
/* harmony import */ var core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! core-js/modules/es.object.define-property.js */ "./node_modules/core-js/modules/es.object.define-property.js");
|
|
10029
|
+
/* harmony import */ var core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_18___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_18__);
|
|
10030
|
+
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! core-js/modules/es.object.to-string.js */ "./node_modules/core-js/modules/es.object.to-string.js");
|
|
10031
|
+
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_19___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_19__);
|
|
10032
|
+
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! core-js/modules/es.symbol.iterator.js */ "./node_modules/core-js/modules/es.symbol.iterator.js");
|
|
10033
|
+
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_20___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_20__);
|
|
10034
|
+
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! core-js/modules/es.array.iterator.js */ "./node_modules/core-js/modules/es.array.iterator.js");
|
|
10035
|
+
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_21___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_21__);
|
|
10036
|
+
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! core-js/modules/es.string.iterator.js */ "./node_modules/core-js/modules/es.string.iterator.js");
|
|
10037
|
+
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_22___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_22__);
|
|
10038
|
+
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! core-js/modules/web.dom-collections.iterator.js */ "./node_modules/core-js/modules/web.dom-collections.iterator.js");
|
|
10039
|
+
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_23___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_23__);
|
|
10040
|
+
/* harmony import */ var _editor_js__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(/*! ../editor.js */ "./src/editor.js");
|
|
10041
|
+
/* harmony import */ var _utilities_js__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(/*! ../utilities.js */ "./src/utilities.js");
|
|
10042
|
+
/* harmony import */ var _array_css_js__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(/*! ./array.css.js */ "./src/editors/array.css.js");
|
|
8276
10043
|
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
|
|
8277
10044
|
|
|
8278
10045
|
|
|
@@ -8297,6 +10064,7 @@ function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "functi
|
|
|
8297
10064
|
|
|
8298
10065
|
|
|
8299
10066
|
|
|
10067
|
+
|
|
8300
10068
|
|
|
8301
10069
|
|
|
8302
10070
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
@@ -8550,13 +10318,13 @@ var ArrayEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
8550
10318
|
if (this.schema.additionalItems === true) {
|
|
8551
10319
|
return {};
|
|
8552
10320
|
} else if (this.schema.additionalItems) {
|
|
8553
|
-
return Object(
|
|
10321
|
+
return Object(_utilities_js__WEBPACK_IMPORTED_MODULE_25__["extend"])({}, this.schema.additionalItems);
|
|
8554
10322
|
}
|
|
8555
10323
|
} else {
|
|
8556
|
-
return Object(
|
|
10324
|
+
return Object(_utilities_js__WEBPACK_IMPORTED_MODULE_25__["extend"])({}, this.schema.items[i]);
|
|
8557
10325
|
}
|
|
8558
10326
|
} else if (this.schema.items) {
|
|
8559
|
-
return Object(
|
|
10327
|
+
return Object(_utilities_js__WEBPACK_IMPORTED_MODULE_25__["extend"])({}, this.schema.items);
|
|
8560
10328
|
} else {
|
|
8561
10329
|
return {};
|
|
8562
10330
|
}
|
|
@@ -8969,6 +10737,7 @@ var ArrayEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
8969
10737
|
var _this9 = this;
|
|
8970
10738
|
|
|
8971
10739
|
var button = this.getButton(this.getItemTitle(), 'copy', 'button_copy_row_title', [this.getItemTitle()]);
|
|
10740
|
+
var schema = this.schema;
|
|
8972
10741
|
button.classList.add('copy', 'json-editor-btntype-copy');
|
|
8973
10742
|
button.setAttribute('data-i', i);
|
|
8974
10743
|
button.addEventListener('click', function (e) {
|
|
@@ -8979,6 +10748,19 @@ var ArrayEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
8979
10748
|
var i = e.currentTarget.getAttribute('data-i') * 1;
|
|
8980
10749
|
value.forEach(function (row, j) {
|
|
8981
10750
|
if (j === i) {
|
|
10751
|
+
/* Force generation of new UUID if the item has been cloned. */
|
|
10752
|
+
if (schema.items.type === 'string' && schema.items.format === 'uuid') {
|
|
10753
|
+
row = Object(_utilities_js__WEBPACK_IMPORTED_MODULE_25__["generateUUID"])();
|
|
10754
|
+
} else if (schema.items.type === 'object' && schema.items.properties) {
|
|
10755
|
+
for (var _i = 0, _Object$keys = Object.keys(row); _i < _Object$keys.length; _i++) {
|
|
10756
|
+
var key = _Object$keys[_i];
|
|
10757
|
+
|
|
10758
|
+
if (schema.items.properties && schema.items.properties[key] && schema.items.properties[key].format === 'uuid') {
|
|
10759
|
+
row[key] = Object(_utilities_js__WEBPACK_IMPORTED_MODULE_25__["generateUUID"])();
|
|
10760
|
+
}
|
|
10761
|
+
}
|
|
10762
|
+
}
|
|
10763
|
+
|
|
8982
10764
|
value.push(row);
|
|
8983
10765
|
}
|
|
8984
10766
|
});
|
|
@@ -9074,7 +10856,7 @@ var ArrayEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
9074
10856
|
/* If it should start collapsed */
|
|
9075
10857
|
|
|
9076
10858
|
if (this.options.collapsed) {
|
|
9077
|
-
Object(
|
|
10859
|
+
Object(_utilities_js__WEBPACK_IMPORTED_MODULE_25__["trigger"])(this.toggle_button, 'click');
|
|
9078
10860
|
}
|
|
9079
10861
|
/* Collapse button disabled */
|
|
9080
10862
|
|
|
@@ -9272,8 +11054,8 @@ var ArrayEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
9272
11054
|
}]);
|
|
9273
11055
|
|
|
9274
11056
|
return ArrayEditor;
|
|
9275
|
-
}(
|
|
9276
|
-
ArrayEditor.rules =
|
|
11057
|
+
}(_editor_js__WEBPACK_IMPORTED_MODULE_24__["AbstractEditor"]);
|
|
11058
|
+
ArrayEditor.rules = _array_css_js__WEBPACK_IMPORTED_MODULE_26__["default"];
|
|
9277
11059
|
|
|
9278
11060
|
/***/ }),
|
|
9279
11061
|
|
|
@@ -10096,6 +11878,8 @@ var AutocompleteEditor = /*#__PURE__*/function (_StringEditor) {
|
|
|
10096
11878
|
}, {
|
|
10097
11879
|
key: "afterInputReady",
|
|
10098
11880
|
value: function afterInputReady() {
|
|
11881
|
+
var _this = this;
|
|
11882
|
+
|
|
10099
11883
|
var options;
|
|
10100
11884
|
|
|
10101
11885
|
if (window.Autocomplete && !this.autocomplete_instance) {
|
|
@@ -10103,17 +11887,18 @@ var AutocompleteEditor = /*#__PURE__*/function (_StringEditor) {
|
|
|
10103
11887
|
|
|
10104
11888
|
/* single property options from schema "options.autocomplete" */
|
|
10105
11889
|
options = this.expandCallbacks('autocomplete', Object(_utilities_js__WEBPACK_IMPORTED_MODULE_15__["extend"])({}, {
|
|
10106
|
-
search: function search(jseditor
|
|
11890
|
+
search: function search(jseditor) {
|
|
10107
11891
|
// eslint-disable-next-line no-console
|
|
10108
11892
|
console.log("No \"search\" callback defined for autocomplete in property \"".concat(jseditor.key, "\""));
|
|
10109
11893
|
return [];
|
|
10110
11894
|
},
|
|
11895
|
+
onSubmit: function onSubmit() {
|
|
11896
|
+
_this.input.blur();
|
|
11897
|
+
},
|
|
10111
11898
|
baseClass: 'autocomplete'
|
|
10112
11899
|
}, this.defaults.options.autocomplete || {}, this.options.autocomplete || {}));
|
|
10113
11900
|
this.autocomplete_wrapper.classList.add(options.baseClass);
|
|
10114
11901
|
this.autocomplete_dropdown.classList.add("".concat(options.baseClass, "-result-list"));
|
|
10115
|
-
/* this.input.classList.add(options.baseClass + '-input'); */
|
|
10116
|
-
|
|
10117
11902
|
this.autocomplete_instance = new window.Autocomplete(this.autocomplete_wrapper, options);
|
|
10118
11903
|
}
|
|
10119
11904
|
|
|
@@ -10586,7 +12371,7 @@ var ButtonEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
10586
12371
|
window.alert("No button action defined for \"".concat(jseditor.path, "\""));
|
|
10587
12372
|
}
|
|
10588
12373
|
}, this.defaults.options.button || {}, this.options.button || {}));
|
|
10589
|
-
this.input = this.
|
|
12374
|
+
this.input = this.getButton(title, options.icon, title);
|
|
10590
12375
|
this.input.addEventListener('click', options.action, false);
|
|
10591
12376
|
|
|
10592
12377
|
if (this.schema.readOnly || this.schema.readonly || this.schema.template) {
|
|
@@ -10774,7 +12559,10 @@ var CheckboxEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
10774
12559
|
_get(_getPrototypeOf(CheckboxEditor.prototype), "register", this).call(this);
|
|
10775
12560
|
|
|
10776
12561
|
if (!this.input) return;
|
|
10777
|
-
|
|
12562
|
+
|
|
12563
|
+
if (this.jsoneditor.options.use_name_attributes) {
|
|
12564
|
+
this.input.setAttribute('name', this.formname);
|
|
12565
|
+
}
|
|
10778
12566
|
}
|
|
10779
12567
|
}, {
|
|
10780
12568
|
key: "unregister",
|
|
@@ -12291,7 +14079,10 @@ var HiddenEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
12291
14079
|
_get(_getPrototypeOf(HiddenEditor.prototype), "register", this).call(this);
|
|
12292
14080
|
|
|
12293
14081
|
if (!this.input) return;
|
|
12294
|
-
|
|
14082
|
+
|
|
14083
|
+
if (this.jsoneditor.options.use_name_attributes) {
|
|
14084
|
+
this.input.setAttribute('name', this.formname);
|
|
14085
|
+
}
|
|
12295
14086
|
}
|
|
12296
14087
|
}, {
|
|
12297
14088
|
key: "unregister",
|
|
@@ -13629,10 +15420,10 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
13629
15420
|
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_6__);
|
|
13630
15421
|
/* harmony import */ var core_js_modules_es_regexp_to_string_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! core-js/modules/es.regexp.to-string.js */ "./node_modules/core-js/modules/es.regexp.to-string.js");
|
|
13631
15422
|
/* harmony import */ var core_js_modules_es_regexp_to_string_js__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_regexp_to_string_js__WEBPACK_IMPORTED_MODULE_7__);
|
|
13632
|
-
/* harmony import */ var
|
|
13633
|
-
/* harmony import */ var
|
|
13634
|
-
/* harmony import */ var
|
|
13635
|
-
/* harmony import */ var
|
|
15423
|
+
/* harmony import */ var core_js_modules_es_array_map_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! core-js/modules/es.array.map.js */ "./node_modules/core-js/modules/es.array.map.js");
|
|
15424
|
+
/* harmony import */ var core_js_modules_es_array_map_js__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_map_js__WEBPACK_IMPORTED_MODULE_8__);
|
|
15425
|
+
/* harmony import */ var core_js_modules_es_array_is_array_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! core-js/modules/es.array.is-array.js */ "./node_modules/core-js/modules/es.array.is-array.js");
|
|
15426
|
+
/* harmony import */ var core_js_modules_es_array_is_array_js__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_is_array_js__WEBPACK_IMPORTED_MODULE_9__);
|
|
13636
15427
|
/* harmony import */ var core_js_modules_es_array_includes_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! core-js/modules/es.array.includes.js */ "./node_modules/core-js/modules/es.array.includes.js");
|
|
13637
15428
|
/* harmony import */ var core_js_modules_es_array_includes_js__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_includes_js__WEBPACK_IMPORTED_MODULE_10__);
|
|
13638
15429
|
/* harmony import */ var core_js_modules_es_string_includes_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! core-js/modules/es.string.includes.js */ "./node_modules/core-js/modules/es.string.includes.js");
|
|
@@ -13758,7 +15549,10 @@ var MultiSelectEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
13758
15549
|
_get(_getPrototypeOf(MultiSelectEditor.prototype), "register", this).call(this);
|
|
13759
15550
|
|
|
13760
15551
|
if (!this.input) return;
|
|
13761
|
-
|
|
15552
|
+
|
|
15553
|
+
if (this.jsoneditor.options.use_name_attributes) {
|
|
15554
|
+
this.input.setAttribute('name', this.formname);
|
|
15555
|
+
}
|
|
13762
15556
|
}
|
|
13763
15557
|
}, {
|
|
13764
15558
|
key: "unregister",
|
|
@@ -13787,17 +15581,22 @@ var MultiSelectEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
13787
15581
|
this.select_options = {};
|
|
13788
15582
|
this.select_values = {};
|
|
13789
15583
|
this.option_keys = [];
|
|
13790
|
-
this.
|
|
15584
|
+
this.option_enum = [];
|
|
13791
15585
|
var i;
|
|
13792
15586
|
var itemsSchema = this.jsoneditor.expandRefs(this.schema.items || {});
|
|
13793
15587
|
var e = itemsSchema["enum"] || [];
|
|
15588
|
+
var oe = itemsSchema.options ? itemsSchema.options["enum"] || [] : [];
|
|
15589
|
+
/* fallback to enum_titles, when options.enum is not present */
|
|
15590
|
+
|
|
13794
15591
|
var t = itemsSchema.options ? itemsSchema.options.enum_titles || [] : [];
|
|
13795
15592
|
|
|
13796
15593
|
for (i = 0; i < e.length; i++) {
|
|
13797
15594
|
/* If the sanitized value is different from the enum value, don't include it */
|
|
13798
15595
|
if (this.sanitize(e[i]) !== e[i]) continue;
|
|
15596
|
+
var d = oe[i] || {};
|
|
15597
|
+
if (!('title' in d)) d.title = "".concat(t[i] || e[i]);
|
|
13799
15598
|
this.option_keys.push("".concat(e[i]));
|
|
13800
|
-
this.
|
|
15599
|
+
this.option_enum.push(d);
|
|
13801
15600
|
this.select_values["".concat(e[i])] = e[i];
|
|
13802
15601
|
}
|
|
13803
15602
|
}
|
|
@@ -13822,9 +15621,15 @@ var MultiSelectEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
13822
15621
|
this.inputs[this.option_keys[i]] = this.theme.getCheckbox();
|
|
13823
15622
|
this.inputs[this.option_keys[i]].id = id;
|
|
13824
15623
|
this.select_options[this.option_keys[i]] = this.inputs[this.option_keys[i]];
|
|
13825
|
-
var label = this.theme.getCheckboxLabel(this.
|
|
15624
|
+
var label = this.theme.getCheckboxLabel(this.option_enum[i].title);
|
|
13826
15625
|
label.htmlFor = id;
|
|
13827
|
-
|
|
15626
|
+
|
|
15627
|
+
if (this.option_enum[i].infoText) {
|
|
15628
|
+
var infoButton = this.theme.getInfoButton(this.translateProperty(this.option_enum[i].infoText));
|
|
15629
|
+
label.appendChild(infoButton);
|
|
15630
|
+
}
|
|
15631
|
+
|
|
15632
|
+
this.controls['_' + this.option_keys[i]] = this.theme.getFormControl(label, this.inputs[this.option_keys[i]]);
|
|
13828
15633
|
}
|
|
13829
15634
|
|
|
13830
15635
|
this.control = this.theme.getMultiCheckboxHolder(this.controls, this.label, this.description, this.infoButton);
|
|
@@ -13833,7 +15638,9 @@ var MultiSelectEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
13833
15638
|
} else {
|
|
13834
15639
|
this.input_type = 'select';
|
|
13835
15640
|
this.input = this.theme.getSelectInput(this.option_keys, true);
|
|
13836
|
-
this.theme.setSelectOptions(this.input, this.option_keys, this.
|
|
15641
|
+
this.theme.setSelectOptions(this.input, this.option_keys, this.option_enum.map(function (e) {
|
|
15642
|
+
return e.title;
|
|
15643
|
+
}));
|
|
13837
15644
|
/* this.input.multiple = true; */
|
|
13838
15645
|
|
|
13839
15646
|
this.input.setAttribute('multiple', 'multiple');
|
|
@@ -15957,31 +17764,33 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
15957
17764
|
/* 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__);
|
|
15958
17765
|
/* harmony import */ var core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! core-js/modules/es.array.concat.js */ "./node_modules/core-js/modules/es.array.concat.js");
|
|
15959
17766
|
/* harmony import */ var core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_2__);
|
|
15960
|
-
/* harmony import */ var
|
|
15961
|
-
/* harmony import */ var
|
|
15962
|
-
/* harmony import */ var
|
|
15963
|
-
/* harmony import */ var
|
|
15964
|
-
/* harmony import */ var
|
|
15965
|
-
/* harmony import */ var
|
|
15966
|
-
/* harmony import */ var
|
|
15967
|
-
/* harmony import */ var
|
|
15968
|
-
/* harmony import */ var
|
|
15969
|
-
/* harmony import */ var
|
|
15970
|
-
/* harmony import */ var
|
|
15971
|
-
/* harmony import */ var
|
|
15972
|
-
/* harmony import */ var
|
|
15973
|
-
/* harmony import */ var
|
|
15974
|
-
/* harmony import */ var
|
|
15975
|
-
/* harmony import */ var
|
|
15976
|
-
/* harmony import */ var
|
|
15977
|
-
/* harmony import */ var
|
|
15978
|
-
/* harmony import */ var
|
|
15979
|
-
/* harmony import */ var
|
|
15980
|
-
/* harmony import */ var
|
|
15981
|
-
/* harmony import */ var
|
|
15982
|
-
/* harmony import */ var
|
|
15983
|
-
/* harmony import */ var
|
|
15984
|
-
/* harmony import */ var
|
|
17767
|
+
/* harmony import */ var core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! core-js/modules/es.function.name.js */ "./node_modules/core-js/modules/es.function.name.js");
|
|
17768
|
+
/* harmony import */ var core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_3__);
|
|
17769
|
+
/* harmony import */ var core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! core-js/modules/es.object.set-prototype-of.js */ "./node_modules/core-js/modules/es.object.set-prototype-of.js");
|
|
17770
|
+
/* harmony import */ var core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_4__);
|
|
17771
|
+
/* harmony import */ var core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! core-js/modules/es.object.get-prototype-of.js */ "./node_modules/core-js/modules/es.object.get-prototype-of.js");
|
|
17772
|
+
/* harmony import */ var core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_5__);
|
|
17773
|
+
/* harmony import */ var core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! core-js/modules/es.reflect.construct.js */ "./node_modules/core-js/modules/es.reflect.construct.js");
|
|
17774
|
+
/* harmony import */ var core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_6__);
|
|
17775
|
+
/* harmony import */ var core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! core-js/modules/es.object.create.js */ "./node_modules/core-js/modules/es.object.create.js");
|
|
17776
|
+
/* harmony import */ var core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_7__);
|
|
17777
|
+
/* harmony import */ var core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! core-js/modules/es.reflect.get.js */ "./node_modules/core-js/modules/es.reflect.get.js");
|
|
17778
|
+
/* harmony import */ var core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_8__);
|
|
17779
|
+
/* harmony import */ var core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! core-js/modules/es.object.get-own-property-descriptor.js */ "./node_modules/core-js/modules/es.object.get-own-property-descriptor.js");
|
|
17780
|
+
/* harmony import */ var core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_9__);
|
|
17781
|
+
/* harmony import */ var core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! core-js/modules/es.object.define-property.js */ "./node_modules/core-js/modules/es.object.define-property.js");
|
|
17782
|
+
/* harmony import */ var core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_10__);
|
|
17783
|
+
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! core-js/modules/es.object.to-string.js */ "./node_modules/core-js/modules/es.object.to-string.js");
|
|
17784
|
+
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_11__);
|
|
17785
|
+
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! core-js/modules/es.symbol.iterator.js */ "./node_modules/core-js/modules/es.symbol.iterator.js");
|
|
17786
|
+
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_12__);
|
|
17787
|
+
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! core-js/modules/es.array.iterator.js */ "./node_modules/core-js/modules/es.array.iterator.js");
|
|
17788
|
+
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_13__);
|
|
17789
|
+
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! core-js/modules/es.string.iterator.js */ "./node_modules/core-js/modules/es.string.iterator.js");
|
|
17790
|
+
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_14__);
|
|
17791
|
+
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! core-js/modules/web.dom-collections.iterator.js */ "./node_modules/core-js/modules/web.dom-collections.iterator.js");
|
|
17792
|
+
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_15__);
|
|
17793
|
+
/* harmony import */ var _select_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ./select.js */ "./src/editors/select.js");
|
|
15985
17794
|
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
|
|
15986
17795
|
|
|
15987
17796
|
|
|
@@ -16000,6 +17809,7 @@ function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "functi
|
|
|
16000
17809
|
|
|
16001
17810
|
|
|
16002
17811
|
|
|
17812
|
+
|
|
16003
17813
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
16004
17814
|
|
|
16005
17815
|
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
@@ -16068,11 +17878,16 @@ var RadioEditor = /*#__PURE__*/function (_SelectEditor) {
|
|
|
16068
17878
|
|
|
16069
17879
|
for (var i = 0; i < this.enum_values.length; i++) {
|
|
16070
17880
|
/* form radio elements */
|
|
16071
|
-
|
|
16072
|
-
name: this.formname,
|
|
17881
|
+
var attributes = {
|
|
16073
17882
|
id: "".concat(this.formname, "[").concat(i, "]"),
|
|
16074
17883
|
value: this.enum_values[i]
|
|
16075
|
-
}
|
|
17884
|
+
};
|
|
17885
|
+
|
|
17886
|
+
if (this.jsoneditor.options.use_name_attributes) {
|
|
17887
|
+
attributes.name = this.formname;
|
|
17888
|
+
}
|
|
17889
|
+
|
|
17890
|
+
this.input = this.theme.getFormRadio(attributes);
|
|
16076
17891
|
/* Set custom attributes on input element. Parameter is array of protected keys. Empty array if none. */
|
|
16077
17892
|
|
|
16078
17893
|
this.setInputAttributes(['id', 'value', 'name']);
|
|
@@ -16163,7 +17978,7 @@ var RadioEditor = /*#__PURE__*/function (_SelectEditor) {
|
|
|
16163
17978
|
}]);
|
|
16164
17979
|
|
|
16165
17980
|
return RadioEditor;
|
|
16166
|
-
}(
|
|
17981
|
+
}(_select_js__WEBPACK_IMPORTED_MODULE_16__["SelectEditor"]);
|
|
16167
17982
|
|
|
16168
17983
|
/***/ }),
|
|
16169
17984
|
|
|
@@ -16519,7 +18334,10 @@ var SelectEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
16519
18334
|
_get(_getPrototypeOf(SelectEditor.prototype), "register", this).call(this);
|
|
16520
18335
|
|
|
16521
18336
|
if (!this.input) return;
|
|
16522
|
-
|
|
18337
|
+
|
|
18338
|
+
if (this.jsoneditor.options.use_name_attributes) {
|
|
18339
|
+
this.input.setAttribute('name', this.formname);
|
|
18340
|
+
}
|
|
16523
18341
|
}
|
|
16524
18342
|
}, {
|
|
16525
18343
|
key: "unregister",
|
|
@@ -17508,7 +19326,11 @@ var SignatureEditor = /*#__PURE__*/function (_StringEditor) {
|
|
|
17508
19326
|
/* Create canvas for signature pad */
|
|
17509
19327
|
|
|
17510
19328
|
var canvas = document.createElement('canvas');
|
|
17511
|
-
|
|
19329
|
+
|
|
19330
|
+
if (this.jsoneditor.options.use_name_attributes) {
|
|
19331
|
+
canvas.setAttribute('name', formname);
|
|
19332
|
+
}
|
|
19333
|
+
|
|
17512
19334
|
canvas.classList.add('signature');
|
|
17513
19335
|
signatureContainer.appendChild(canvas);
|
|
17514
19336
|
this.signaturePad = new window.SignaturePad(canvas, {
|
|
@@ -18392,7 +20214,11 @@ var StringEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
18392
20214
|
_get(_getPrototypeOf(StringEditor.prototype), "register", this).call(this);
|
|
18393
20215
|
|
|
18394
20216
|
if (!this.input) return;
|
|
18395
|
-
|
|
20217
|
+
|
|
20218
|
+
if (this.jsoneditor.options.use_name_attributes) {
|
|
20219
|
+
this.input.setAttribute('name', this.formname);
|
|
20220
|
+
}
|
|
20221
|
+
|
|
18396
20222
|
this.input.setAttribute('aria-label', this.formname);
|
|
18397
20223
|
}
|
|
18398
20224
|
}, {
|
|
@@ -18613,6 +20439,12 @@ var StringEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
18613
20439
|
/* it will generate an error trying to append it to the missing parentNode */
|
|
18614
20440
|
if (_this.input.parentNode) _this.afterInputReady();
|
|
18615
20441
|
if (_this.adjust_height) _this.adjust_height(_this.input);
|
|
20442
|
+
|
|
20443
|
+
if (_this.format === 'range') {
|
|
20444
|
+
var output = _this.control.querySelector('output');
|
|
20445
|
+
|
|
20446
|
+
output.value = _this.input.value;
|
|
20447
|
+
}
|
|
18616
20448
|
});
|
|
18617
20449
|
/* Compile and store the template */
|
|
18618
20450
|
|
|
@@ -18840,32 +20672,34 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
18840
20672
|
/* harmony import */ var core_js_modules_es_array_some_js__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_some_js__WEBPACK_IMPORTED_MODULE_8__);
|
|
18841
20673
|
/* harmony import */ var core_js_modules_es_array_splice_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! core-js/modules/es.array.splice.js */ "./node_modules/core-js/modules/es.array.splice.js");
|
|
18842
20674
|
/* harmony import */ var core_js_modules_es_array_splice_js__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_splice_js__WEBPACK_IMPORTED_MODULE_9__);
|
|
18843
|
-
/* harmony import */ var
|
|
18844
|
-
/* harmony import */ var
|
|
18845
|
-
/* harmony import */ var
|
|
18846
|
-
/* harmony import */ var
|
|
18847
|
-
/* harmony import */ var
|
|
18848
|
-
/* harmony import */ var
|
|
18849
|
-
/* harmony import */ var
|
|
18850
|
-
/* harmony import */ var
|
|
18851
|
-
/* harmony import */ var
|
|
18852
|
-
/* harmony import */ var
|
|
18853
|
-
/* harmony import */ var
|
|
18854
|
-
/* harmony import */ var
|
|
18855
|
-
/* harmony import */ var
|
|
18856
|
-
/* harmony import */ var
|
|
18857
|
-
/* harmony import */ var
|
|
18858
|
-
/* harmony import */ var
|
|
18859
|
-
/* harmony import */ var
|
|
18860
|
-
/* harmony import */ var
|
|
18861
|
-
/* harmony import */ var
|
|
18862
|
-
/* harmony import */ var
|
|
18863
|
-
/* harmony import */ var
|
|
18864
|
-
/* harmony import */ var
|
|
18865
|
-
/* harmony import */ var
|
|
18866
|
-
/* harmony import */ var
|
|
18867
|
-
/* harmony import */ var
|
|
18868
|
-
/* harmony import */ var
|
|
20675
|
+
/* harmony import */ var core_js_modules_es_object_assign_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! core-js/modules/es.object.assign.js */ "./node_modules/core-js/modules/es.object.assign.js");
|
|
20676
|
+
/* harmony import */ var core_js_modules_es_object_assign_js__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_assign_js__WEBPACK_IMPORTED_MODULE_10__);
|
|
20677
|
+
/* harmony import */ var core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! core-js/modules/es.object.set-prototype-of.js */ "./node_modules/core-js/modules/es.object.set-prototype-of.js");
|
|
20678
|
+
/* harmony import */ var core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_11__);
|
|
20679
|
+
/* harmony import */ var core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! core-js/modules/es.object.get-prototype-of.js */ "./node_modules/core-js/modules/es.object.get-prototype-of.js");
|
|
20680
|
+
/* harmony import */ var core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_12__);
|
|
20681
|
+
/* harmony import */ var core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! core-js/modules/es.reflect.construct.js */ "./node_modules/core-js/modules/es.reflect.construct.js");
|
|
20682
|
+
/* harmony import */ var core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_13__);
|
|
20683
|
+
/* harmony import */ var core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! core-js/modules/es.object.create.js */ "./node_modules/core-js/modules/es.object.create.js");
|
|
20684
|
+
/* harmony import */ var core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_14__);
|
|
20685
|
+
/* harmony import */ var core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! core-js/modules/es.reflect.get.js */ "./node_modules/core-js/modules/es.reflect.get.js");
|
|
20686
|
+
/* harmony import */ var core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_15__);
|
|
20687
|
+
/* harmony import */ var core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! core-js/modules/es.object.get-own-property-descriptor.js */ "./node_modules/core-js/modules/es.object.get-own-property-descriptor.js");
|
|
20688
|
+
/* harmony import */ var core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_16___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_16__);
|
|
20689
|
+
/* harmony import */ var core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! core-js/modules/es.object.define-property.js */ "./node_modules/core-js/modules/es.object.define-property.js");
|
|
20690
|
+
/* harmony import */ var core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_17___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_17__);
|
|
20691
|
+
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! core-js/modules/es.object.to-string.js */ "./node_modules/core-js/modules/es.object.to-string.js");
|
|
20692
|
+
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_18___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_18__);
|
|
20693
|
+
/* 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");
|
|
20694
|
+
/* 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__);
|
|
20695
|
+
/* 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");
|
|
20696
|
+
/* 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__);
|
|
20697
|
+
/* 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");
|
|
20698
|
+
/* 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__);
|
|
20699
|
+
/* 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");
|
|
20700
|
+
/* 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__);
|
|
20701
|
+
/* harmony import */ var _array_js__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! ./array.js */ "./src/editors/array.js");
|
|
20702
|
+
/* harmony import */ var _utilities_js__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(/*! ../utilities.js */ "./src/utilities.js");
|
|
18869
20703
|
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
|
|
18870
20704
|
|
|
18871
20705
|
|
|
@@ -18889,6 +20723,7 @@ function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "functi
|
|
|
18889
20723
|
|
|
18890
20724
|
|
|
18891
20725
|
|
|
20726
|
+
|
|
18892
20727
|
|
|
18893
20728
|
|
|
18894
20729
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
@@ -19055,7 +20890,7 @@ var TableEditor = /*#__PURE__*/function (_ArrayEditor) {
|
|
|
19055
20890
|
}, {
|
|
19056
20891
|
key: "getItemDefault",
|
|
19057
20892
|
value: function getItemDefault() {
|
|
19058
|
-
return Object(
|
|
20893
|
+
return Object(_utilities_js__WEBPACK_IMPORTED_MODULE_24__["extend"])({}, {
|
|
19059
20894
|
"default": this.item_default
|
|
19060
20895
|
})["default"];
|
|
19061
20896
|
}
|
|
@@ -19067,7 +20902,7 @@ var TableEditor = /*#__PURE__*/function (_ArrayEditor) {
|
|
|
19067
20902
|
}, {
|
|
19068
20903
|
key: "getElementEditor",
|
|
19069
20904
|
value: function getElementEditor(i, ignore) {
|
|
19070
|
-
var schemaCopy = Object(
|
|
20905
|
+
var schemaCopy = Object(_utilities_js__WEBPACK_IMPORTED_MODULE_24__["extend"])({}, this.schema.items);
|
|
19071
20906
|
var editor = this.jsoneditor.getEditorClass(schemaCopy, this.jsoneditor);
|
|
19072
20907
|
var row = this.row_holder.appendChild(this.theme.getTableRow());
|
|
19073
20908
|
var holder = row;
|
|
@@ -19322,6 +21157,7 @@ var TableEditor = /*#__PURE__*/function (_ArrayEditor) {
|
|
|
19322
21157
|
var _this5 = this;
|
|
19323
21158
|
|
|
19324
21159
|
var button = this.getButton('', 'copy', 'button_copy_row_title_short');
|
|
21160
|
+
var schema = this.schema;
|
|
19325
21161
|
button.classList.add('copy', 'json-editor-btntype-copy');
|
|
19326
21162
|
button.setAttribute('data-i', i);
|
|
19327
21163
|
button.addEventListener('click', function (e) {
|
|
@@ -19331,7 +21167,27 @@ var TableEditor = /*#__PURE__*/function (_ArrayEditor) {
|
|
|
19331
21167
|
|
|
19332
21168
|
var value = _this5.getValue();
|
|
19333
21169
|
|
|
19334
|
-
|
|
21170
|
+
var newValue = value[j];
|
|
21171
|
+
/* On copy, recreate uuid if needed. */
|
|
21172
|
+
|
|
21173
|
+
if (schema.items.type === 'string' && schema.items.format === 'uuid') {
|
|
21174
|
+
newValue = Object(_utilities_js__WEBPACK_IMPORTED_MODULE_24__["generateUUID"])();
|
|
21175
|
+
} else if (schema.items.type === 'object' && schema.items.properties) {
|
|
21176
|
+
value.forEach(function (row, i) {
|
|
21177
|
+
if (j === i) {
|
|
21178
|
+
for (var _i = 0, _Object$keys = Object.keys(row); _i < _Object$keys.length; _i++) {
|
|
21179
|
+
var key = _Object$keys[_i];
|
|
21180
|
+
|
|
21181
|
+
if (schema.items.properties && schema.items.properties[key] && schema.items.properties[key].format === 'uuid') {
|
|
21182
|
+
newValue = Object.assign({}, value[j]);
|
|
21183
|
+
newValue[key] = Object(_utilities_js__WEBPACK_IMPORTED_MODULE_24__["generateUUID"])();
|
|
21184
|
+
}
|
|
21185
|
+
}
|
|
21186
|
+
}
|
|
21187
|
+
});
|
|
21188
|
+
}
|
|
21189
|
+
|
|
21190
|
+
value.splice(j + 1, 0, newValue);
|
|
19335
21191
|
|
|
19336
21192
|
_this5.setValue(value);
|
|
19337
21193
|
|
|
@@ -19423,7 +21279,7 @@ var TableEditor = /*#__PURE__*/function (_ArrayEditor) {
|
|
|
19423
21279
|
/* If it should start collapsed */
|
|
19424
21280
|
|
|
19425
21281
|
if (this.options.collapsed) {
|
|
19426
|
-
Object(
|
|
21282
|
+
Object(_utilities_js__WEBPACK_IMPORTED_MODULE_24__["trigger"])(this.toggle_button, 'click');
|
|
19427
21283
|
}
|
|
19428
21284
|
/* Collapse button disabled */
|
|
19429
21285
|
|
|
@@ -19527,7 +21383,7 @@ var TableEditor = /*#__PURE__*/function (_ArrayEditor) {
|
|
|
19527
21383
|
}]);
|
|
19528
21384
|
|
|
19529
21385
|
return TableEditor;
|
|
19530
|
-
}(
|
|
21386
|
+
}(_array_js__WEBPACK_IMPORTED_MODULE_23__["ArrayEditor"]);
|
|
19531
21387
|
|
|
19532
21388
|
/***/ }),
|
|
19533
21389
|
|
|
@@ -19962,7 +21818,7 @@ var UploadEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
19962
21818
|
|
|
19963
21819
|
if (this.options.auto_upload) {
|
|
19964
21820
|
uploadButton.dispatchEvent(new window.MouseEvent('click'));
|
|
19965
|
-
|
|
21821
|
+
uploadButton.parentNode.removeChild(uploadButton);
|
|
19966
21822
|
}
|
|
19967
21823
|
}
|
|
19968
21824
|
}, {
|
|
@@ -20054,43 +21910,36 @@ var UploadEditor = /*#__PURE__*/function (_AbstractEditor) {
|
|
|
20054
21910
|
"use strict";
|
|
20055
21911
|
__webpack_require__.r(__webpack_exports__);
|
|
20056
21912
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UuidEditor", function() { return UuidEditor; });
|
|
20057
|
-
/* harmony import */ var
|
|
20058
|
-
/* harmony import */ var
|
|
20059
|
-
/* harmony import */ var
|
|
20060
|
-
/* harmony import */ var
|
|
20061
|
-
/* harmony import */ var
|
|
20062
|
-
/* harmony import */ var
|
|
20063
|
-
/* harmony import */ var
|
|
20064
|
-
/* harmony import */ var
|
|
20065
|
-
/* harmony import */ var
|
|
20066
|
-
/* harmony import */ var
|
|
20067
|
-
/* harmony import */ var
|
|
20068
|
-
/* harmony import */ var
|
|
20069
|
-
/* harmony import */ var
|
|
20070
|
-
/* harmony import */ var
|
|
20071
|
-
/* harmony import */ var
|
|
20072
|
-
/* harmony import */ var
|
|
20073
|
-
/* harmony import */ var
|
|
20074
|
-
/* harmony import */ var
|
|
20075
|
-
/* harmony import */ var
|
|
20076
|
-
/* harmony import */ var
|
|
20077
|
-
/* harmony import */ var
|
|
20078
|
-
/* harmony import */ var
|
|
20079
|
-
/* harmony import */ var
|
|
20080
|
-
/* harmony import */ var
|
|
20081
|
-
/* harmony import */ var
|
|
20082
|
-
/* harmony import */ var
|
|
20083
|
-
/* harmony import */ var
|
|
20084
|
-
/* harmony import */ var
|
|
20085
|
-
/* harmony import */ var
|
|
20086
|
-
/* harmony import */ var
|
|
20087
|
-
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! core-js/modules/es.array.iterator.js */ "./node_modules/core-js/modules/es.array.iterator.js");
|
|
20088
|
-
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_15__);
|
|
20089
|
-
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! core-js/modules/es.string.iterator.js */ "./node_modules/core-js/modules/es.string.iterator.js");
|
|
20090
|
-
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_16___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_16__);
|
|
20091
|
-
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! core-js/modules/web.dom-collections.iterator.js */ "./node_modules/core-js/modules/web.dom-collections.iterator.js");
|
|
20092
|
-
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_17___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_17__);
|
|
20093
|
-
/* harmony import */ var _string_js__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! ./string.js */ "./src/editors/string.js");
|
|
21913
|
+
/* harmony import */ var core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.object.set-prototype-of.js */ "./node_modules/core-js/modules/es.object.set-prototype-of.js");
|
|
21914
|
+
/* harmony import */ var core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
21915
|
+
/* harmony import */ var core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es.object.get-prototype-of.js */ "./node_modules/core-js/modules/es.object.get-prototype-of.js");
|
|
21916
|
+
/* harmony import */ var core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
21917
|
+
/* harmony import */ var core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! core-js/modules/es.reflect.construct.js */ "./node_modules/core-js/modules/es.reflect.construct.js");
|
|
21918
|
+
/* harmony import */ var core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_reflect_construct_js__WEBPACK_IMPORTED_MODULE_2__);
|
|
21919
|
+
/* harmony import */ var core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! core-js/modules/es.object.create.js */ "./node_modules/core-js/modules/es.object.create.js");
|
|
21920
|
+
/* harmony import */ var core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_create_js__WEBPACK_IMPORTED_MODULE_3__);
|
|
21921
|
+
/* harmony import */ var core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! core-js/modules/es.reflect.get.js */ "./node_modules/core-js/modules/es.reflect.get.js");
|
|
21922
|
+
/* harmony import */ var core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_reflect_get_js__WEBPACK_IMPORTED_MODULE_4__);
|
|
21923
|
+
/* harmony import */ var core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! core-js/modules/es.object.get-own-property-descriptor.js */ "./node_modules/core-js/modules/es.object.get-own-property-descriptor.js");
|
|
21924
|
+
/* harmony import */ var core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_get_own_property_descriptor_js__WEBPACK_IMPORTED_MODULE_5__);
|
|
21925
|
+
/* harmony import */ var core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! core-js/modules/es.object.define-property.js */ "./node_modules/core-js/modules/es.object.define-property.js");
|
|
21926
|
+
/* harmony import */ var core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_6__);
|
|
21927
|
+
/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! core-js/modules/es.symbol.js */ "./node_modules/core-js/modules/es.symbol.js");
|
|
21928
|
+
/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_7__);
|
|
21929
|
+
/* harmony import */ var core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! core-js/modules/es.symbol.description.js */ "./node_modules/core-js/modules/es.symbol.description.js");
|
|
21930
|
+
/* harmony import */ var core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_8__);
|
|
21931
|
+
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! core-js/modules/es.object.to-string.js */ "./node_modules/core-js/modules/es.object.to-string.js");
|
|
21932
|
+
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_9__);
|
|
21933
|
+
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! core-js/modules/es.symbol.iterator.js */ "./node_modules/core-js/modules/es.symbol.iterator.js");
|
|
21934
|
+
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_10__);
|
|
21935
|
+
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! core-js/modules/es.array.iterator.js */ "./node_modules/core-js/modules/es.array.iterator.js");
|
|
21936
|
+
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_11__);
|
|
21937
|
+
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! core-js/modules/es.string.iterator.js */ "./node_modules/core-js/modules/es.string.iterator.js");
|
|
21938
|
+
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_12__);
|
|
21939
|
+
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! core-js/modules/web.dom-collections.iterator.js */ "./node_modules/core-js/modules/web.dom-collections.iterator.js");
|
|
21940
|
+
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_13__);
|
|
21941
|
+
/* harmony import */ var _utilities_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ../utilities.js */ "./src/utilities.js");
|
|
21942
|
+
/* harmony import */ var _string_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ./string.js */ "./src/editors/string.js");
|
|
20094
21943
|
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
|
|
20095
21944
|
|
|
20096
21945
|
|
|
@@ -20108,10 +21957,6 @@ function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "functi
|
|
|
20108
21957
|
|
|
20109
21958
|
|
|
20110
21959
|
|
|
20111
|
-
|
|
20112
|
-
|
|
20113
|
-
|
|
20114
|
-
|
|
20115
21960
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
20116
21961
|
|
|
20117
21962
|
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
@@ -20137,6 +21982,7 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Re
|
|
|
20137
21982
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
20138
21983
|
|
|
20139
21984
|
|
|
21985
|
+
|
|
20140
21986
|
var UuidEditor = /*#__PURE__*/function (_StringEditor) {
|
|
20141
21987
|
_inherits(UuidEditor, _StringEditor);
|
|
20142
21988
|
|
|
@@ -20194,19 +22040,7 @@ var UuidEditor = /*#__PURE__*/function (_StringEditor) {
|
|
|
20194
22040
|
}, {
|
|
20195
22041
|
key: "getUuid",
|
|
20196
22042
|
value: function getUuid() {
|
|
20197
|
-
|
|
20198
|
-
var d = new Date().getTime();
|
|
20199
|
-
|
|
20200
|
-
if (typeof performance !== 'undefined' && typeof performance.now === 'function') {
|
|
20201
|
-
d += performance.now();
|
|
20202
|
-
/* use high-precision timer if available */
|
|
20203
|
-
}
|
|
20204
|
-
|
|
20205
|
-
return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (c) {
|
|
20206
|
-
var r = (d + Math.random() * 16) % 16 | 0;
|
|
20207
|
-
d = Math.floor(d / 16);
|
|
20208
|
-
return (c === 'x' ? r : r & 0x3 | 0x8).toString(16);
|
|
20209
|
-
});
|
|
22043
|
+
return Object(_utilities_js__WEBPACK_IMPORTED_MODULE_14__["generateUUID"])();
|
|
20210
22044
|
}
|
|
20211
22045
|
}, {
|
|
20212
22046
|
key: "testUuid",
|
|
@@ -20216,7 +22050,7 @@ var UuidEditor = /*#__PURE__*/function (_StringEditor) {
|
|
|
20216
22050
|
}]);
|
|
20217
22051
|
|
|
20218
22052
|
return UuidEditor;
|
|
20219
|
-
}(
|
|
22053
|
+
}(_string_js__WEBPACK_IMPORTED_MODULE_15__["StringEditor"]);
|
|
20220
22054
|
|
|
20221
22055
|
/***/ }),
|
|
20222
22056
|
|
|
@@ -20316,7 +22150,7 @@ var AbstractIconLib = /*#__PURE__*/function () {
|
|
|
20316
22150
|
_createClass(AbstractIconLib, [{
|
|
20317
22151
|
key: "getIconClass",
|
|
20318
22152
|
value: function getIconClass(key) {
|
|
20319
|
-
return this.mapping[key] ? this.icon_prefix + this.mapping[key] :
|
|
22153
|
+
return this.mapping[key] ? this.icon_prefix + this.mapping[key] : this.icon_prefix + key;
|
|
20320
22154
|
}
|
|
20321
22155
|
}, {
|
|
20322
22156
|
key: "getIcon",
|
|
@@ -21289,77 +23123,91 @@ var colorPicker = function colorPicker(schema) {
|
|
|
21289
23123
|
/* Export resolvers in order of discovery, first to last */
|
|
21290
23124
|
|
|
21291
23125
|
|
|
21292
|
-
var resolvers = [colorPicker, ip, ace, xhtml, markdown, jodit, autoComplete, uuid, info, button, stepper, describeBy, starratings, date, oneOf, arraysOfStrings, enumeratedProperties, enumSource, table, upload, base64, any, _boolean, signature, primitive, object, defaultResolver];
|
|
23126
|
+
var resolvers = [colorPicker, ip, ace, xhtml, markdown, jodit, autoComplete, uuid, info, button, stepper, describeBy, starratings, date, oneOf, arraysOfStrings, enumeratedProperties, enumSource, table, upload, base64, any, _boolean, signature, primitive, object, defaultResolver];
|
|
23127
|
+
|
|
23128
|
+
/***/ }),
|
|
23129
|
+
|
|
23130
|
+
/***/ "./src/schemaloader.js":
|
|
23131
|
+
/*!*****************************!*\
|
|
23132
|
+
!*** ./src/schemaloader.js ***!
|
|
23133
|
+
\*****************************/
|
|
23134
|
+
/*! exports provided: SchemaLoader */
|
|
23135
|
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
23136
|
+
|
|
23137
|
+
"use strict";
|
|
23138
|
+
__webpack_require__.r(__webpack_exports__);
|
|
23139
|
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SchemaLoader", function() { return SchemaLoader; });
|
|
23140
|
+
/* harmony import */ var regenerator_runtime_runtime_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! regenerator-runtime/runtime.js */ "./node_modules/regenerator-runtime/runtime.js");
|
|
23141
|
+
/* harmony import */ var regenerator_runtime_runtime_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(regenerator_runtime_runtime_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
23142
|
+
/* harmony import */ var core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es.array.for-each.js */ "./node_modules/core-js/modules/es.array.for-each.js");
|
|
23143
|
+
/* harmony import */ var core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
23144
|
+
/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! core-js/modules/web.dom-collections.for-each.js */ "./node_modules/core-js/modules/web.dom-collections.for-each.js");
|
|
23145
|
+
/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_2__);
|
|
23146
|
+
/* harmony import */ var core_js_modules_es_object_entries_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! core-js/modules/es.object.entries.js */ "./node_modules/core-js/modules/es.object.entries.js");
|
|
23147
|
+
/* harmony import */ var core_js_modules_es_object_entries_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_entries_js__WEBPACK_IMPORTED_MODULE_3__);
|
|
23148
|
+
/* harmony import */ var core_js_modules_es_array_is_array_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! core-js/modules/es.array.is-array.js */ "./node_modules/core-js/modules/es.array.is-array.js");
|
|
23149
|
+
/* harmony import */ var core_js_modules_es_array_is_array_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_is_array_js__WEBPACK_IMPORTED_MODULE_4__);
|
|
23150
|
+
/* harmony import */ var core_js_modules_es_array_reduce_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! core-js/modules/es.array.reduce.js */ "./node_modules/core-js/modules/es.array.reduce.js");
|
|
23151
|
+
/* harmony import */ var core_js_modules_es_array_reduce_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_reduce_js__WEBPACK_IMPORTED_MODULE_5__);
|
|
23152
|
+
/* harmony import */ var core_js_modules_es_regexp_exec_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! core-js/modules/es.regexp.exec.js */ "./node_modules/core-js/modules/es.regexp.exec.js");
|
|
23153
|
+
/* harmony import */ var core_js_modules_es_regexp_exec_js__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_regexp_exec_js__WEBPACK_IMPORTED_MODULE_6__);
|
|
23154
|
+
/* harmony import */ var core_js_modules_es_string_split_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! core-js/modules/es.string.split.js */ "./node_modules/core-js/modules/es.string.split.js");
|
|
23155
|
+
/* harmony import */ var core_js_modules_es_string_split_js__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_split_js__WEBPACK_IMPORTED_MODULE_7__);
|
|
23156
|
+
/* harmony import */ var core_js_modules_es_string_starts_with_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! core-js/modules/es.string.starts-with.js */ "./node_modules/core-js/modules/es.string.starts-with.js");
|
|
23157
|
+
/* harmony import */ var core_js_modules_es_string_starts_with_js__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_starts_with_js__WEBPACK_IMPORTED_MODULE_8__);
|
|
23158
|
+
/* harmony import */ var core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! core-js/modules/es.object.keys.js */ "./node_modules/core-js/modules/es.object.keys.js");
|
|
23159
|
+
/* harmony import */ var core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_9__);
|
|
23160
|
+
/* harmony import */ var core_js_modules_es_array_slice_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! core-js/modules/es.array.slice.js */ "./node_modules/core-js/modules/es.array.slice.js");
|
|
23161
|
+
/* harmony import */ var core_js_modules_es_array_slice_js__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_slice_js__WEBPACK_IMPORTED_MODULE_10__);
|
|
23162
|
+
/* harmony import */ var core_js_modules_es_array_map_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! core-js/modules/es.array.map.js */ "./node_modules/core-js/modules/es.array.map.js");
|
|
23163
|
+
/* harmony import */ var core_js_modules_es_array_map_js__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_map_js__WEBPACK_IMPORTED_MODULE_11__);
|
|
23164
|
+
/* harmony import */ var core_js_modules_es_array_index_of_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! core-js/modules/es.array.index-of.js */ "./node_modules/core-js/modules/es.array.index-of.js");
|
|
23165
|
+
/* harmony import */ var core_js_modules_es_array_index_of_js__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_index_of_js__WEBPACK_IMPORTED_MODULE_12__);
|
|
23166
|
+
/* harmony import */ var core_js_modules_es_object_values_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! core-js/modules/es.object.values.js */ "./node_modules/core-js/modules/es.object.values.js");
|
|
23167
|
+
/* harmony import */ var core_js_modules_es_object_values_js__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_values_js__WEBPACK_IMPORTED_MODULE_13__);
|
|
23168
|
+
/* harmony import */ var core_js_modules_es_array_join_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! core-js/modules/es.array.join.js */ "./node_modules/core-js/modules/es.array.join.js");
|
|
23169
|
+
/* harmony import */ var core_js_modules_es_array_join_js__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_join_js__WEBPACK_IMPORTED_MODULE_14__);
|
|
23170
|
+
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! core-js/modules/es.string.iterator.js */ "./node_modules/core-js/modules/es.string.iterator.js");
|
|
23171
|
+
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_15__);
|
|
23172
|
+
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! core-js/modules/es.array.iterator.js */ "./node_modules/core-js/modules/es.array.iterator.js");
|
|
23173
|
+
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_16___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_16__);
|
|
23174
|
+
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! core-js/modules/web.dom-collections.iterator.js */ "./node_modules/core-js/modules/web.dom-collections.iterator.js");
|
|
23175
|
+
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_17___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_17__);
|
|
23176
|
+
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! core-js/modules/es.object.to-string.js */ "./node_modules/core-js/modules/es.object.to-string.js");
|
|
23177
|
+
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_18___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_18__);
|
|
23178
|
+
/* harmony import */ var core_js_modules_es_promise_js__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! core-js/modules/es.promise.js */ "./node_modules/core-js/modules/es.promise.js");
|
|
23179
|
+
/* harmony import */ var core_js_modules_es_promise_js__WEBPACK_IMPORTED_MODULE_19___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_promise_js__WEBPACK_IMPORTED_MODULE_19__);
|
|
23180
|
+
/* harmony import */ var core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! core-js/modules/es.array.concat.js */ "./node_modules/core-js/modules/es.array.concat.js");
|
|
23181
|
+
/* harmony import */ var core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_20___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_20__);
|
|
23182
|
+
/* harmony import */ var core_js_modules_es_array_includes_js__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! core-js/modules/es.array.includes.js */ "./node_modules/core-js/modules/es.array.includes.js");
|
|
23183
|
+
/* harmony import */ var core_js_modules_es_array_includes_js__WEBPACK_IMPORTED_MODULE_21___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_includes_js__WEBPACK_IMPORTED_MODULE_21__);
|
|
23184
|
+
/* harmony import */ var core_js_modules_es_string_includes_js__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! core-js/modules/es.string.includes.js */ "./node_modules/core-js/modules/es.string.includes.js");
|
|
23185
|
+
/* harmony import */ var core_js_modules_es_string_includes_js__WEBPACK_IMPORTED_MODULE_22___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_includes_js__WEBPACK_IMPORTED_MODULE_22__);
|
|
23186
|
+
/* harmony import */ var core_js_modules_es_array_filter_js__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! core-js/modules/es.array.filter.js */ "./node_modules/core-js/modules/es.array.filter.js");
|
|
23187
|
+
/* harmony import */ var core_js_modules_es_array_filter_js__WEBPACK_IMPORTED_MODULE_23___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_filter_js__WEBPACK_IMPORTED_MODULE_23__);
|
|
23188
|
+
/* harmony import */ var core_js_modules_es_date_to_iso_string_js__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(/*! core-js/modules/es.date.to-iso-string.js */ "./node_modules/core-js/modules/es.date.to-iso-string.js");
|
|
23189
|
+
/* harmony import */ var core_js_modules_es_date_to_iso_string_js__WEBPACK_IMPORTED_MODULE_24___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_date_to_iso_string_js__WEBPACK_IMPORTED_MODULE_24__);
|
|
23190
|
+
/* harmony import */ var core_js_modules_es_date_to_string_js__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(/*! core-js/modules/es.date.to-string.js */ "./node_modules/core-js/modules/es.date.to-string.js");
|
|
23191
|
+
/* harmony import */ var core_js_modules_es_date_to_string_js__WEBPACK_IMPORTED_MODULE_25___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_date_to_string_js__WEBPACK_IMPORTED_MODULE_25__);
|
|
23192
|
+
/* harmony import */ var core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(/*! core-js/modules/es.object.define-property.js */ "./node_modules/core-js/modules/es.object.define-property.js");
|
|
23193
|
+
/* harmony import */ var core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_26___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_26__);
|
|
23194
|
+
/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(/*! core-js/modules/es.symbol.js */ "./node_modules/core-js/modules/es.symbol.js");
|
|
23195
|
+
/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_27___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_27__);
|
|
23196
|
+
/* harmony import */ var core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(/*! core-js/modules/es.symbol.description.js */ "./node_modules/core-js/modules/es.symbol.description.js");
|
|
23197
|
+
/* harmony import */ var core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_28___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_28__);
|
|
23198
|
+
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_29__ = __webpack_require__(/*! core-js/modules/es.symbol.iterator.js */ "./node_modules/core-js/modules/es.symbol.iterator.js");
|
|
23199
|
+
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_29___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_29__);
|
|
23200
|
+
/* harmony import */ var core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_30__ = __webpack_require__(/*! core-js/modules/es.function.name.js */ "./node_modules/core-js/modules/es.function.name.js");
|
|
23201
|
+
/* harmony import */ var core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_30___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_30__);
|
|
23202
|
+
/* harmony import */ var core_js_modules_es_array_from_js__WEBPACK_IMPORTED_MODULE_31__ = __webpack_require__(/*! core-js/modules/es.array.from.js */ "./node_modules/core-js/modules/es.array.from.js");
|
|
23203
|
+
/* harmony import */ var core_js_modules_es_array_from_js__WEBPACK_IMPORTED_MODULE_31___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_from_js__WEBPACK_IMPORTED_MODULE_31__);
|
|
23204
|
+
/* harmony import */ var _utilities_js__WEBPACK_IMPORTED_MODULE_32__ = __webpack_require__(/*! ./utilities.js */ "./src/utilities.js");
|
|
23205
|
+
|
|
21293
23206
|
|
|
21294
|
-
|
|
23207
|
+
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
|
|
21295
23208
|
|
|
21296
|
-
|
|
21297
|
-
/*!*****************************!*\
|
|
21298
|
-
!*** ./src/schemaloader.js ***!
|
|
21299
|
-
\*****************************/
|
|
21300
|
-
/*! exports provided: SchemaLoader */
|
|
21301
|
-
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
23209
|
+
function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
|
|
21302
23210
|
|
|
21303
|
-
"use strict";
|
|
21304
|
-
__webpack_require__.r(__webpack_exports__);
|
|
21305
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SchemaLoader", function() { return SchemaLoader; });
|
|
21306
|
-
/* harmony import */ var core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.array.for-each.js */ "./node_modules/core-js/modules/es.array.for-each.js");
|
|
21307
|
-
/* harmony import */ var core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
21308
|
-
/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/web.dom-collections.for-each.js */ "./node_modules/core-js/modules/web.dom-collections.for-each.js");
|
|
21309
|
-
/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
21310
|
-
/* harmony import */ var core_js_modules_es_object_entries_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! core-js/modules/es.object.entries.js */ "./node_modules/core-js/modules/es.object.entries.js");
|
|
21311
|
-
/* harmony import */ var core_js_modules_es_object_entries_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_entries_js__WEBPACK_IMPORTED_MODULE_2__);
|
|
21312
|
-
/* harmony import */ var core_js_modules_es_array_is_array_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! core-js/modules/es.array.is-array.js */ "./node_modules/core-js/modules/es.array.is-array.js");
|
|
21313
|
-
/* harmony import */ var core_js_modules_es_array_is_array_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_is_array_js__WEBPACK_IMPORTED_MODULE_3__);
|
|
21314
|
-
/* harmony import */ var core_js_modules_es_array_reduce_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! core-js/modules/es.array.reduce.js */ "./node_modules/core-js/modules/es.array.reduce.js");
|
|
21315
|
-
/* harmony import */ var core_js_modules_es_array_reduce_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_reduce_js__WEBPACK_IMPORTED_MODULE_4__);
|
|
21316
|
-
/* harmony import */ var core_js_modules_es_string_starts_with_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! core-js/modules/es.string.starts-with.js */ "./node_modules/core-js/modules/es.string.starts-with.js");
|
|
21317
|
-
/* harmony import */ var core_js_modules_es_string_starts_with_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_starts_with_js__WEBPACK_IMPORTED_MODULE_5__);
|
|
21318
|
-
/* harmony import */ var core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! core-js/modules/es.object.keys.js */ "./node_modules/core-js/modules/es.object.keys.js");
|
|
21319
|
-
/* harmony import */ var core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_6__);
|
|
21320
|
-
/* harmony import */ var core_js_modules_es_array_map_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! core-js/modules/es.array.map.js */ "./node_modules/core-js/modules/es.array.map.js");
|
|
21321
|
-
/* harmony import */ var core_js_modules_es_array_map_js__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_map_js__WEBPACK_IMPORTED_MODULE_7__);
|
|
21322
|
-
/* harmony import */ var core_js_modules_es_object_values_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! core-js/modules/es.object.values.js */ "./node_modules/core-js/modules/es.object.values.js");
|
|
21323
|
-
/* harmony import */ var core_js_modules_es_object_values_js__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_values_js__WEBPACK_IMPORTED_MODULE_8__);
|
|
21324
|
-
/* harmony import */ var core_js_modules_es_regexp_exec_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! core-js/modules/es.regexp.exec.js */ "./node_modules/core-js/modules/es.regexp.exec.js");
|
|
21325
|
-
/* harmony import */ var core_js_modules_es_regexp_exec_js__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_regexp_exec_js__WEBPACK_IMPORTED_MODULE_9__);
|
|
21326
|
-
/* harmony import */ var core_js_modules_es_string_split_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! core-js/modules/es.string.split.js */ "./node_modules/core-js/modules/es.string.split.js");
|
|
21327
|
-
/* harmony import */ var core_js_modules_es_string_split_js__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_split_js__WEBPACK_IMPORTED_MODULE_10__);
|
|
21328
|
-
/* harmony import */ var core_js_modules_es_array_join_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! core-js/modules/es.array.join.js */ "./node_modules/core-js/modules/es.array.join.js");
|
|
21329
|
-
/* harmony import */ var core_js_modules_es_array_join_js__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_join_js__WEBPACK_IMPORTED_MODULE_11__);
|
|
21330
|
-
/* harmony import */ var core_js_modules_es_array_index_of_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! core-js/modules/es.array.index-of.js */ "./node_modules/core-js/modules/es.array.index-of.js");
|
|
21331
|
-
/* harmony import */ var core_js_modules_es_array_index_of_js__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_index_of_js__WEBPACK_IMPORTED_MODULE_12__);
|
|
21332
|
-
/* harmony import */ var core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! core-js/modules/es.array.concat.js */ "./node_modules/core-js/modules/es.array.concat.js");
|
|
21333
|
-
/* harmony import */ var core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_concat_js__WEBPACK_IMPORTED_MODULE_13__);
|
|
21334
|
-
/* harmony import */ var core_js_modules_es_array_includes_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! core-js/modules/es.array.includes.js */ "./node_modules/core-js/modules/es.array.includes.js");
|
|
21335
|
-
/* harmony import */ var core_js_modules_es_array_includes_js__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_includes_js__WEBPACK_IMPORTED_MODULE_14__);
|
|
21336
|
-
/* harmony import */ var core_js_modules_es_string_includes_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! core-js/modules/es.string.includes.js */ "./node_modules/core-js/modules/es.string.includes.js");
|
|
21337
|
-
/* harmony import */ var core_js_modules_es_string_includes_js__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_includes_js__WEBPACK_IMPORTED_MODULE_15__);
|
|
21338
|
-
/* harmony import */ var core_js_modules_es_array_filter_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! core-js/modules/es.array.filter.js */ "./node_modules/core-js/modules/es.array.filter.js");
|
|
21339
|
-
/* harmony import */ var core_js_modules_es_array_filter_js__WEBPACK_IMPORTED_MODULE_16___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_filter_js__WEBPACK_IMPORTED_MODULE_16__);
|
|
21340
|
-
/* harmony import */ var core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! core-js/modules/es.object.define-property.js */ "./node_modules/core-js/modules/es.object.define-property.js");
|
|
21341
|
-
/* harmony import */ var core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_17___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_define_property_js__WEBPACK_IMPORTED_MODULE_17__);
|
|
21342
|
-
/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! core-js/modules/es.symbol.js */ "./node_modules/core-js/modules/es.symbol.js");
|
|
21343
|
-
/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_18___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_18__);
|
|
21344
|
-
/* harmony import */ var core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! core-js/modules/es.symbol.description.js */ "./node_modules/core-js/modules/es.symbol.description.js");
|
|
21345
|
-
/* harmony import */ var core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_19___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_19__);
|
|
21346
|
-
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! core-js/modules/es.object.to-string.js */ "./node_modules/core-js/modules/es.object.to-string.js");
|
|
21347
|
-
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_20___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_20__);
|
|
21348
|
-
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! core-js/modules/es.symbol.iterator.js */ "./node_modules/core-js/modules/es.symbol.iterator.js");
|
|
21349
|
-
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_21___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_21__);
|
|
21350
|
-
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! core-js/modules/es.array.iterator.js */ "./node_modules/core-js/modules/es.array.iterator.js");
|
|
21351
|
-
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_22___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_22__);
|
|
21352
|
-
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! core-js/modules/es.string.iterator.js */ "./node_modules/core-js/modules/es.string.iterator.js");
|
|
21353
|
-
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_23___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_23__);
|
|
21354
|
-
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(/*! core-js/modules/web.dom-collections.iterator.js */ "./node_modules/core-js/modules/web.dom-collections.iterator.js");
|
|
21355
|
-
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_24___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_24__);
|
|
21356
|
-
/* harmony import */ var core_js_modules_es_array_slice_js__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(/*! core-js/modules/es.array.slice.js */ "./node_modules/core-js/modules/es.array.slice.js");
|
|
21357
|
-
/* harmony import */ var core_js_modules_es_array_slice_js__WEBPACK_IMPORTED_MODULE_25___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_slice_js__WEBPACK_IMPORTED_MODULE_25__);
|
|
21358
|
-
/* harmony import */ var core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(/*! core-js/modules/es.function.name.js */ "./node_modules/core-js/modules/es.function.name.js");
|
|
21359
|
-
/* harmony import */ var core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_26___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_26__);
|
|
21360
|
-
/* harmony import */ var core_js_modules_es_array_from_js__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(/*! core-js/modules/es.array.from.js */ "./node_modules/core-js/modules/es.array.from.js");
|
|
21361
|
-
/* harmony import */ var core_js_modules_es_array_from_js__WEBPACK_IMPORTED_MODULE_27___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_from_js__WEBPACK_IMPORTED_MODULE_27__);
|
|
21362
|
-
/* harmony import */ var _utilities_js__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(/*! ./utilities.js */ "./src/utilities.js");
|
|
21363
23211
|
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
21364
23212
|
|
|
21365
23213
|
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
@@ -21397,6 +23245,9 @@ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
|
21397
23245
|
|
|
21398
23246
|
|
|
21399
23247
|
|
|
23248
|
+
|
|
23249
|
+
|
|
23250
|
+
|
|
21400
23251
|
|
|
21401
23252
|
|
|
21402
23253
|
|
|
@@ -21410,14 +23261,56 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
21410
23261
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
21411
23262
|
|
|
21412
23263
|
|
|
23264
|
+
/**
|
|
23265
|
+
* Handles loading Schema and tracking references.
|
|
23266
|
+
*/
|
|
23267
|
+
|
|
21413
23268
|
var SchemaLoader = /*#__PURE__*/function () {
|
|
21414
23269
|
function SchemaLoader(options) {
|
|
21415
23270
|
_classCallCheck(this, SchemaLoader);
|
|
21416
23271
|
|
|
23272
|
+
/**
|
|
23273
|
+
* @prop {object}
|
|
23274
|
+
* Options of the schema. @see readme.
|
|
23275
|
+
*/
|
|
21417
23276
|
this.options = options || {};
|
|
23277
|
+
/**
|
|
23278
|
+
* @prop {object}
|
|
23279
|
+
* The orginial schema to load
|
|
23280
|
+
*/
|
|
23281
|
+
|
|
23282
|
+
this.schema = {};
|
|
23283
|
+
/**
|
|
23284
|
+
* @prop {object}
|
|
23285
|
+
* Storage of External ref. Exemple :
|
|
23286
|
+
* refs = {
|
|
23287
|
+
* "fully/realized/path/to/schema.json": { ... }
|
|
23288
|
+
* "mylocalschema.json": { ... }
|
|
23289
|
+
* }
|
|
23290
|
+
*/
|
|
23291
|
+
|
|
21418
23292
|
this.refs = this.options.refs || {};
|
|
23293
|
+
/**
|
|
23294
|
+
* @prop {object}
|
|
23295
|
+
* Mapping between the schema and ref. Exemple:
|
|
23296
|
+
* refs_with_info = {
|
|
23297
|
+
* "#/counter/1": "fully/realized/path/to/schema.json"
|
|
23298
|
+
* "#/counter/2": "mylocalschema.json"
|
|
23299
|
+
* }
|
|
23300
|
+
*/
|
|
23301
|
+
|
|
21419
23302
|
this.refs_with_info = {};
|
|
23303
|
+
/**
|
|
23304
|
+
* @prop {string}
|
|
23305
|
+
* String to eewrite external ref with.
|
|
23306
|
+
*/
|
|
23307
|
+
|
|
21420
23308
|
this.refs_prefix = '#/counter/';
|
|
23309
|
+
/**
|
|
23310
|
+
* @prop {int}
|
|
23311
|
+
* Counter of ref
|
|
23312
|
+
*/
|
|
23313
|
+
|
|
21421
23314
|
this.refs_counter = 1;
|
|
21422
23315
|
this._subSchema1 = {
|
|
21423
23316
|
/* Version 3 `type` */
|
|
@@ -21472,7 +23365,7 @@ var SchemaLoader = /*#__PURE__*/function () {
|
|
|
21472
23365
|
allOf: function allOf(schema, extended) {
|
|
21473
23366
|
var _this3 = this;
|
|
21474
23367
|
|
|
21475
|
-
var _extended = Object(
|
|
23368
|
+
var _extended = Object(_utilities_js__WEBPACK_IMPORTED_MODULE_32__["extend"])({}, extended);
|
|
21476
23369
|
|
|
21477
23370
|
Object.entries(schema.allOf).forEach(function (_ref5) {
|
|
21478
23371
|
var _ref6 = _slicedToArray(_ref5, 2),
|
|
@@ -21511,7 +23404,7 @@ var SchemaLoader = /*#__PURE__*/function () {
|
|
|
21511
23404
|
oneOf: function oneOf(schema, extended) {
|
|
21512
23405
|
var _this5 = this;
|
|
21513
23406
|
|
|
21514
|
-
var tmp = Object(
|
|
23407
|
+
var tmp = Object(_utilities_js__WEBPACK_IMPORTED_MODULE_32__["extend"])({}, extended);
|
|
21515
23408
|
delete tmp.oneOf;
|
|
21516
23409
|
schema.oneOf.reduce(function (e, s, i) {
|
|
21517
23410
|
e.oneOf[i] = _this5.extendSchemas(_this5.expandSchema(s), tmp);
|
|
@@ -21521,27 +23414,78 @@ var SchemaLoader = /*#__PURE__*/function () {
|
|
|
21521
23414
|
}
|
|
21522
23415
|
};
|
|
21523
23416
|
}
|
|
23417
|
+
/**
|
|
23418
|
+
* Fully loads and expands JSON schema for a provided schema object and URL.
|
|
23419
|
+
*
|
|
23420
|
+
* The callback receives a expanded JSON Schema object with references
|
|
23421
|
+
* replaced with loaded schemas.
|
|
23422
|
+
*
|
|
23423
|
+
* @param {object} schema - A JSON Schema.
|
|
23424
|
+
* @param {string} fetchUrl - Base path from which to store the definitions.
|
|
23425
|
+
* Typically the URI of the schema.
|
|
23426
|
+
* @param {*} location - The base URL from which to load relative paths.
|
|
23427
|
+
* @returns {object} A JSON Schema with references expanded.
|
|
23428
|
+
*/
|
|
23429
|
+
|
|
21524
23430
|
|
|
21525
23431
|
_createClass(SchemaLoader, [{
|
|
21526
23432
|
key: "load",
|
|
21527
|
-
value: function
|
|
21528
|
-
var
|
|
23433
|
+
value: function () {
|
|
23434
|
+
var _load = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(schema, fetchUrl, location) {
|
|
23435
|
+
return regeneratorRuntime.wrap(function _callee$(_context) {
|
|
23436
|
+
while (1) {
|
|
23437
|
+
switch (_context.prev = _context.next) {
|
|
23438
|
+
case 0:
|
|
23439
|
+
this.schema = schema;
|
|
23440
|
+
_context.next = 3;
|
|
23441
|
+
return this._asyncloadExternalRefs(schema, fetchUrl, this._getFileBase(location), true);
|
|
23442
|
+
|
|
23443
|
+
case 3:
|
|
23444
|
+
return _context.abrupt("return", this.expandRefs(schema));
|
|
23445
|
+
|
|
23446
|
+
case 4:
|
|
23447
|
+
case "end":
|
|
23448
|
+
return _context.stop();
|
|
23449
|
+
}
|
|
23450
|
+
}
|
|
23451
|
+
}, _callee, this);
|
|
23452
|
+
}));
|
|
21529
23453
|
|
|
21530
|
-
|
|
21531
|
-
|
|
23454
|
+
function load(_x, _x2, _x3) {
|
|
23455
|
+
return _load.apply(this, arguments);
|
|
23456
|
+
}
|
|
23457
|
+
|
|
23458
|
+
return load;
|
|
23459
|
+
}()
|
|
23460
|
+
/**
|
|
23461
|
+
* Recursively expands loaded references in a provided schema.
|
|
23462
|
+
*
|
|
23463
|
+
* @param {object} schema - A JSON Schema with references already loaded.
|
|
23464
|
+
* @param {boolean} recurseAllOf - Set true to recurse allOf properties.
|
|
23465
|
+
* @returns {object} A JSON Schema with references expanded.
|
|
23466
|
+
*/
|
|
21532
23467
|
|
|
21533
|
-
callback(_this6.expandRefs(schema));
|
|
21534
|
-
}, fetchUrl, this._getFileBase(location));
|
|
21535
|
-
}
|
|
21536
23468
|
}, {
|
|
21537
23469
|
key: "expandRefs",
|
|
21538
23470
|
value: function expandRefs(schema, recurseAllOf) {
|
|
21539
|
-
var
|
|
23471
|
+
var _this6 = this;
|
|
23472
|
+
|
|
23473
|
+
var _schema = Object(_utilities_js__WEBPACK_IMPORTED_MODULE_32__["extend"])({}, schema);
|
|
21540
23474
|
|
|
21541
|
-
|
|
23475
|
+
if (!_schema.$ref) return _schema; // This split the ref to get the Json point if it exists
|
|
23476
|
+
// exemple #/counter/1#/definition/address +
|
|
23477
|
+
// [1] -> /counter/1
|
|
23478
|
+
// [2] -> /definition/address
|
|
23479
|
+
|
|
23480
|
+
var refWithPointerSplit = _schema.$ref.split('#'); // If local ref
|
|
23481
|
+
|
|
23482
|
+
|
|
23483
|
+
if (refWithPointerSplit.length === 2 && !this.refs_with_info[_schema.$ref]) {
|
|
23484
|
+
var sub = this.expandRecursivePointer(this.schema, refWithPointerSplit[1]);
|
|
23485
|
+
return this.extendSchemas(_schema, this.expandSchema(sub));
|
|
23486
|
+
}
|
|
21542
23487
|
|
|
21543
|
-
|
|
21544
|
-
var refObj = this.refs_with_info[_schema.$ref];
|
|
23488
|
+
var refObj = refWithPointerSplit.length > 2 ? this.refs_with_info['#' + refWithPointerSplit[1]] : this.refs_with_info[_schema.$ref];
|
|
21545
23489
|
delete _schema.$ref;
|
|
21546
23490
|
var fetchUrl = refObj.$ref.startsWith('#') ? refObj.fetchUrl : '';
|
|
21547
23491
|
|
|
@@ -21551,19 +23495,54 @@ var SchemaLoader = /*#__PURE__*/function () {
|
|
|
21551
23495
|
/* if reference not found */
|
|
21552
23496
|
// eslint-disable-next-line no-console
|
|
21553
23497
|
console.warn("reference:'".concat(ref, "' not found!"));
|
|
21554
|
-
} else if (recurseAllOf && Object(
|
|
23498
|
+
} else if (recurseAllOf && Object(_utilities_js__WEBPACK_IMPORTED_MODULE_32__["hasOwnProperty"])(this.refs[ref], 'allOf')) {
|
|
21555
23499
|
var allOf = this.refs[ref].allOf;
|
|
21556
23500
|
Object.keys(allOf).forEach(function (key) {
|
|
21557
|
-
allOf[key] =
|
|
23501
|
+
allOf[key] = _this6.expandRefs(allOf[key], true);
|
|
21558
23502
|
});
|
|
21559
23503
|
}
|
|
21560
23504
|
|
|
21561
|
-
|
|
23505
|
+
if (refWithPointerSplit.length > 2) {
|
|
23506
|
+
return this.extendSchemas(_schema, this.expandSchema(this.expandRecursivePointer(this.refs[ref], refWithPointerSplit[2])));
|
|
23507
|
+
} else {
|
|
23508
|
+
return this.extendSchemas(_schema, this.expandSchema(this.refs[ref]));
|
|
23509
|
+
}
|
|
23510
|
+
}
|
|
23511
|
+
/**
|
|
23512
|
+
* Returns a subschema based on a JSON Pointer path.
|
|
23513
|
+
* @param {object} schema - Schema too into
|
|
23514
|
+
* @param {string} pointer - path to look for
|
|
23515
|
+
* @param {object} original_schema - the Original schema
|
|
23516
|
+
* @returns the subschema pointed to by the path
|
|
23517
|
+
*/
|
|
23518
|
+
|
|
23519
|
+
}, {
|
|
23520
|
+
key: "expandRecursivePointer",
|
|
23521
|
+
value: function expandRecursivePointer(schema, pointer) {
|
|
23522
|
+
var subschema = schema;
|
|
23523
|
+
pointer.split('/').slice(1).forEach(function (i) {
|
|
23524
|
+
if (subschema[i]) {
|
|
23525
|
+
subschema = subschema[i];
|
|
23526
|
+
}
|
|
23527
|
+
}); // If the result is a pointer, let's go for another turn
|
|
23528
|
+
|
|
23529
|
+
if (subschema.$refs && subschema.$refs.startsWith('#')) {
|
|
23530
|
+
return this.expandRecursivePointer(schema, subschema.$refs);
|
|
23531
|
+
}
|
|
23532
|
+
|
|
23533
|
+
return subschema;
|
|
21562
23534
|
}
|
|
23535
|
+
/**
|
|
23536
|
+
* Expands a JSON schema and its references.
|
|
23537
|
+
*
|
|
23538
|
+
* @param {object} schema - A JSON Schema with references already loaded.
|
|
23539
|
+
* @returns {object} A JSON Schema with references expanded.
|
|
23540
|
+
*/
|
|
23541
|
+
|
|
21563
23542
|
}, {
|
|
21564
23543
|
key: "expandSchema",
|
|
21565
|
-
value: function expandSchema(schema
|
|
21566
|
-
var
|
|
23544
|
+
value: function expandSchema(schema) {
|
|
23545
|
+
var _this7 = this;
|
|
21567
23546
|
|
|
21568
23547
|
Object.entries(this._subSchema1).forEach(function (_ref7) {
|
|
21569
23548
|
var _ref8 = _slicedToArray(_ref7, 2),
|
|
@@ -21571,17 +23550,17 @@ var SchemaLoader = /*#__PURE__*/function () {
|
|
|
21571
23550
|
func = _ref8[1];
|
|
21572
23551
|
|
|
21573
23552
|
if (schema[key]) {
|
|
21574
|
-
func.call(
|
|
23553
|
+
func.call(_this7, schema);
|
|
21575
23554
|
}
|
|
21576
23555
|
});
|
|
21577
|
-
var extended = Object(
|
|
23556
|
+
var extended = Object(_utilities_js__WEBPACK_IMPORTED_MODULE_32__["extend"])({}, schema);
|
|
21578
23557
|
Object.entries(this._subSchema2).forEach(function (_ref9) {
|
|
21579
23558
|
var _ref10 = _slicedToArray(_ref9, 2),
|
|
21580
23559
|
key = _ref10[0],
|
|
21581
23560
|
func = _ref10[1];
|
|
21582
23561
|
|
|
21583
23562
|
if (schema[key]) {
|
|
21584
|
-
extended = func.call(
|
|
23563
|
+
extended = func.call(_this7, schema, extended);
|
|
21585
23564
|
}
|
|
21586
23565
|
});
|
|
21587
23566
|
return this.expandRefs(extended);
|
|
@@ -21595,36 +23574,55 @@ var SchemaLoader = /*#__PURE__*/function () {
|
|
|
21595
23574
|
}, {
|
|
21596
23575
|
key: "_expandSubSchema",
|
|
21597
23576
|
value: function _expandSubSchema(subschema) {
|
|
21598
|
-
var
|
|
23577
|
+
var _this8 = this;
|
|
21599
23578
|
|
|
21600
23579
|
/* Array of types */
|
|
21601
23580
|
if (Array.isArray(subschema)) return subschema.map(function (m) {
|
|
21602
|
-
return _typeof(m) === 'object' ?
|
|
23581
|
+
return _typeof(m) === 'object' ? _this8.expandSchema(m) : m;
|
|
21603
23582
|
});
|
|
21604
23583
|
/* Schema */
|
|
21605
23584
|
|
|
21606
23585
|
return this.expandSchema(subschema);
|
|
21607
23586
|
}
|
|
21608
|
-
|
|
21609
|
-
|
|
21610
|
-
|
|
21611
|
-
|
|
21612
|
-
|
|
21613
|
-
|
|
21614
|
-
|
|
21615
|
-
|
|
23587
|
+
/**
|
|
23588
|
+
* Rewrite the passed schema's JSON pointers to prepend with the current reference's path, so that it will be converted to a reference "counter".
|
|
23589
|
+
*
|
|
23590
|
+
* @example
|
|
23591
|
+
* In file "../otherreferencedfile.json", referenced from "schema.json":
|
|
23592
|
+
*
|
|
23593
|
+
* "$ref": "#/definitions/myschema" => "$ref": "../path/to/my/referenced/schemafile.json#/definitions/myschema"
|
|
23594
|
+
* ...which will then be parsed later in loadExternalReferences() to "$ref": "#/counter/1#/definitions/myschema"
|
|
23595
|
+
*
|
|
23596
|
+
* @param {object} schema - A JSON Schema with the definitions key present.
|
|
23597
|
+
* @param {string} path - Base path from which to store the definitions in refs. (exemple ../path/to/my/referenced/schemafile.json)
|
|
23598
|
+
* Typically the URI of the schema.
|
|
23599
|
+
*/
|
|
21616
23600
|
|
|
21617
|
-
|
|
21618
|
-
|
|
21619
|
-
|
|
21620
|
-
|
|
21621
|
-
|
|
23601
|
+
}, {
|
|
23602
|
+
key: "_manageRecursivePointer",
|
|
23603
|
+
value: function _manageRecursivePointer(schema, path) {
|
|
23604
|
+
Object.keys(schema).forEach(function (i) {
|
|
23605
|
+
if (schema[i].$ref && schema[i].$ref.indexOf('#') === 0) {
|
|
23606
|
+
schema[i].$ref = path + schema[i].$ref;
|
|
23607
|
+
}
|
|
23608
|
+
});
|
|
21622
23609
|
}
|
|
23610
|
+
/**
|
|
23611
|
+
* Recursively parse a (sub)schema to populate loader reference info.
|
|
23612
|
+
*
|
|
23613
|
+
* @param {object} schema - A JSON Schema
|
|
23614
|
+
* @param {string} fetchUrl - Base path from which to store the definitions.
|
|
23615
|
+
* @param {boolean} firstIteration - Is it the first time we load this function? Help making difference between external ref vs internal pointer
|
|
23616
|
+
* @returns {array} Refs in the format of uri => true if external.
|
|
23617
|
+
*/
|
|
23618
|
+
|
|
21623
23619
|
}, {
|
|
21624
23620
|
key: "_getExternalRefs",
|
|
21625
23621
|
value: function _getExternalRefs(schema, fetchUrl) {
|
|
21626
|
-
var
|
|
23622
|
+
var _this9 = this;
|
|
21627
23623
|
|
|
23624
|
+
var firstIteration = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
|
|
23625
|
+
if (!firstIteration) this._manageRecursivePointer(schema, fetchUrl);
|
|
21628
23626
|
var refs = {};
|
|
21629
23627
|
|
|
21630
23628
|
var mergeRefs = function mergeRefs(newrefs) {
|
|
@@ -21633,18 +23631,25 @@ var SchemaLoader = /*#__PURE__*/function () {
|
|
|
21633
23631
|
});
|
|
21634
23632
|
};
|
|
21635
23633
|
|
|
21636
|
-
if (schema.$ref && _typeof(schema.$ref) !== 'object') {
|
|
23634
|
+
if (schema.$ref && _typeof(schema.$ref) !== 'object' && !(schema.$ref.indexOf('#') === 0 && firstIteration)) {
|
|
23635
|
+
var refBase = schema.$ref;
|
|
23636
|
+
var pointer = ''; // Strip any JSON pointers found for external refs.
|
|
23637
|
+
|
|
23638
|
+
if (refBase.indexOf('#') > 0) refBase = refBase.substr(0, refBase.indexOf('#'));
|
|
23639
|
+
if (refBase !== schema.$ref) pointer = schema.$ref.substr(schema.$ref.indexOf('#')); // We use a fragment idenfier to track json pointer in top of our pointer
|
|
23640
|
+
|
|
21637
23641
|
var refCounter = this.refs_prefix + this.refs_counter++;
|
|
23642
|
+
var refPointer = refCounter + pointer;
|
|
21638
23643
|
|
|
21639
23644
|
if (schema.$ref.substr(0, 1) !== '#' && !this.refs[schema.$ref]) {
|
|
21640
|
-
refs[
|
|
23645
|
+
refs[refBase] = true;
|
|
21641
23646
|
}
|
|
21642
23647
|
|
|
21643
23648
|
this.refs_with_info[refCounter] = {
|
|
21644
23649
|
fetchUrl: fetchUrl,
|
|
21645
|
-
$ref:
|
|
23650
|
+
$ref: refBase
|
|
21646
23651
|
};
|
|
21647
|
-
schema.$ref =
|
|
23652
|
+
schema.$ref = refPointer;
|
|
21648
23653
|
}
|
|
21649
23654
|
|
|
21650
23655
|
Object.values(schema).forEach(function (value) {
|
|
@@ -21653,11 +23658,14 @@ var SchemaLoader = /*#__PURE__*/function () {
|
|
|
21653
23658
|
if (Array.isArray(value)) {
|
|
21654
23659
|
Object.values(value).forEach(function (e) {
|
|
21655
23660
|
if (e && _typeof(e) === 'object') {
|
|
21656
|
-
mergeRefs(
|
|
23661
|
+
mergeRefs(_this9._getExternalRefs(e, fetchUrl, firstIteration));
|
|
21657
23662
|
}
|
|
21658
23663
|
});
|
|
21659
23664
|
} else {
|
|
21660
|
-
|
|
23665
|
+
// Merge Ref if it's not a Pointer
|
|
23666
|
+
if (!value.$ref || !(typeof value.$ref === 'string' && value.$ref.startsWith('#'))) {
|
|
23667
|
+
mergeRefs(_this9._getExternalRefs(value, fetchUrl, firstIteration));
|
|
23668
|
+
}
|
|
21661
23669
|
}
|
|
21662
23670
|
});
|
|
21663
23671
|
|
|
@@ -21701,147 +23709,298 @@ var SchemaLoader = /*#__PURE__*/function () {
|
|
|
21701
23709
|
value: function _isUniformResourceName(uri) {
|
|
21702
23710
|
return uri.substr(0, 4) === 'urn:';
|
|
21703
23711
|
}
|
|
21704
|
-
|
|
21705
|
-
|
|
21706
|
-
|
|
21707
|
-
|
|
21708
|
-
|
|
21709
|
-
|
|
21710
|
-
|
|
21711
|
-
|
|
21712
|
-
|
|
21713
|
-
|
|
21714
|
-
|
|
21715
|
-
|
|
21716
|
-
|
|
21717
|
-
|
|
21718
|
-
|
|
21719
|
-
var urnResolver = _this12.options.urn_resolver;
|
|
21720
|
-
var urn = uri;
|
|
21721
|
-
|
|
21722
|
-
if (typeof urnResolver !== 'function') {
|
|
21723
|
-
// eslint-disable-next-line no-console
|
|
21724
|
-
console.log("No \"urn_resolver\" callback defined to resolve \"".concat(urn, "\""));
|
|
21725
|
-
throw new Error("Must set urn_resolver option to a callback to resolve ".concat(urn));
|
|
21726
|
-
} // theoretically a URN can contain a JSON pointer
|
|
21727
|
-
|
|
21728
|
-
|
|
21729
|
-
if (urn.indexOf('#') > 0) urn = urn.substr(0, urn.indexOf('#'));
|
|
21730
|
-
var response;
|
|
21731
|
-
|
|
21732
|
-
try {
|
|
21733
|
-
response = urnResolver(urn, function (responseText) {
|
|
21734
|
-
try {
|
|
21735
|
-
schema = JSON.parse(responseText);
|
|
21736
|
-
} catch (e) {
|
|
21737
|
-
// eslint-disable-next-line no-console
|
|
21738
|
-
console.log(e);
|
|
21739
|
-
throw new Error("Failed to parse external ref ".concat(urn));
|
|
21740
|
-
}
|
|
21741
|
-
|
|
21742
|
-
if (!(typeof schema === 'boolean' || _typeof(schema) === 'object') || schema === null || Array.isArray(schema)) {
|
|
21743
|
-
throw new Error("External ref does not contain a valid schema - ".concat(urn));
|
|
21744
|
-
}
|
|
21745
|
-
|
|
21746
|
-
_this12.refs[uri] = schema;
|
|
23712
|
+
/**
|
|
23713
|
+
* Loads external references via AJAX.
|
|
23714
|
+
*
|
|
23715
|
+
* Will fail if this.options.ajax is not set to true.
|
|
23716
|
+
*
|
|
23717
|
+
* @param {object} schema - JSON Schema with external references.
|
|
23718
|
+
* @param {string} fetchUrl - Base path from which to store the definitions.
|
|
23719
|
+
* Typically the URI of the schema.
|
|
23720
|
+
* @param {string} fileBase - The base URL from which to load relative paths.
|
|
23721
|
+
* Typically the URI of the schema minus filename, with trailing slash.
|
|
23722
|
+
* @param {boolean} firstIteration - Is it the first time we load this function? Help making difference between external ref vs internal pointer
|
|
23723
|
+
*
|
|
23724
|
+
* @return {boolean}
|
|
23725
|
+
* @throws Error
|
|
23726
|
+
*/
|
|
21747
23727
|
|
|
21748
|
-
|
|
23728
|
+
}, {
|
|
23729
|
+
key: "_asyncloadExternalRefs",
|
|
23730
|
+
value: function () {
|
|
23731
|
+
var _asyncloadExternalRefs2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee2(schema, fetchUrl, fileBase) {
|
|
23732
|
+
var _this10 = this;
|
|
21749
23733
|
|
|
21750
|
-
|
|
21751
|
-
|
|
23734
|
+
var firstIteration,
|
|
23735
|
+
refs,
|
|
23736
|
+
waiting,
|
|
23737
|
+
_loop,
|
|
23738
|
+
_i2,
|
|
23739
|
+
_Object$keys,
|
|
23740
|
+
_ret,
|
|
23741
|
+
_args3 = arguments;
|
|
23742
|
+
|
|
23743
|
+
return regeneratorRuntime.wrap(function _callee2$(_context3) {
|
|
23744
|
+
while (1) {
|
|
23745
|
+
switch (_context3.prev = _context3.next) {
|
|
23746
|
+
case 0:
|
|
23747
|
+
firstIteration = _args3.length > 3 && _args3[3] !== undefined ? _args3[3] : false;
|
|
23748
|
+
refs = this._getExternalRefs(schema, fetchUrl, firstIteration);
|
|
23749
|
+
waiting = 0; // Loop into all schema references
|
|
23750
|
+
|
|
23751
|
+
_loop = /*#__PURE__*/regeneratorRuntime.mark(function _loop() {
|
|
23752
|
+
var uri, urnResolver, urn, response, _externalSchema, url, externalSchema, schemaFromCache, _response, newfileBase, pathItems;
|
|
23753
|
+
|
|
23754
|
+
return regeneratorRuntime.wrap(function _loop$(_context2) {
|
|
23755
|
+
while (1) {
|
|
23756
|
+
switch (_context2.prev = _context2.next) {
|
|
23757
|
+
case 0:
|
|
23758
|
+
uri = _Object$keys[_i2];
|
|
23759
|
+
|
|
23760
|
+
if (!(typeof uri === 'undefined')) {
|
|
23761
|
+
_context2.next = 3;
|
|
23762
|
+
break;
|
|
23763
|
+
}
|
|
23764
|
+
|
|
23765
|
+
return _context2.abrupt("return", "continue");
|
|
23766
|
+
|
|
23767
|
+
case 3:
|
|
23768
|
+
if (!_this10.refs[uri]) {
|
|
23769
|
+
_context2.next = 5;
|
|
23770
|
+
break;
|
|
23771
|
+
}
|
|
23772
|
+
|
|
23773
|
+
return _context2.abrupt("return", "continue");
|
|
23774
|
+
|
|
23775
|
+
case 5:
|
|
23776
|
+
if (!_this10._isUniformResourceName(uri)) {
|
|
23777
|
+
_context2.next = 40;
|
|
23778
|
+
break;
|
|
23779
|
+
}
|
|
23780
|
+
|
|
23781
|
+
_this10.refs[uri] = 'loading';
|
|
23782
|
+
waiting++;
|
|
23783
|
+
urnResolver = _this10.options.urn_resolver;
|
|
23784
|
+
urn = uri;
|
|
23785
|
+
|
|
23786
|
+
if (!(typeof urnResolver !== 'function')) {
|
|
23787
|
+
_context2.next = 13;
|
|
23788
|
+
break;
|
|
23789
|
+
}
|
|
23790
|
+
|
|
23791
|
+
// eslint-disable-next-line no-console
|
|
23792
|
+
console.log("No \"urn_resolver\" callback defined to resolve \"".concat(urn, "\""));
|
|
23793
|
+
throw new Error("Must set urn_resolver option to a callback to resolve ".concat(urn));
|
|
23794
|
+
|
|
23795
|
+
case 13:
|
|
23796
|
+
// theoretically a URN can contain a JSON pointer
|
|
23797
|
+
if (urn.indexOf('#') > 0) urn = urn.substr(0, urn.indexOf('#'));
|
|
23798
|
+
_context2.prev = 14;
|
|
23799
|
+
_context2.next = 17;
|
|
23800
|
+
return urnResolver(urn);
|
|
23801
|
+
|
|
23802
|
+
case 17:
|
|
23803
|
+
response = _context2.sent;
|
|
23804
|
+
_context2.prev = 18;
|
|
23805
|
+
_externalSchema = JSON.parse(response);
|
|
23806
|
+
_context2.next = 26;
|
|
23807
|
+
break;
|
|
23808
|
+
|
|
23809
|
+
case 22:
|
|
23810
|
+
_context2.prev = 22;
|
|
23811
|
+
_context2.t0 = _context2["catch"](18);
|
|
23812
|
+
// eslint-disable-next-line no-console
|
|
23813
|
+
console.log(_context2.t0);
|
|
23814
|
+
throw new Error("Failed to parse external ref ".concat(urn));
|
|
23815
|
+
|
|
23816
|
+
case 26:
|
|
23817
|
+
if (!(!(typeof _externalSchema === 'boolean' || _typeof(_externalSchema) === 'object') || _externalSchema === null || Array.isArray(_externalSchema))) {
|
|
23818
|
+
_context2.next = 28;
|
|
23819
|
+
break;
|
|
23820
|
+
}
|
|
23821
|
+
|
|
23822
|
+
throw new Error("External ref does not contain a valid schema - ".concat(urn));
|
|
23823
|
+
|
|
23824
|
+
case 28:
|
|
23825
|
+
_this10.refs[uri] = _externalSchema;
|
|
23826
|
+
_context2.next = 31;
|
|
23827
|
+
return _this10._asyncloadExternalRefs(_externalSchema, uri, fileBase);
|
|
23828
|
+
|
|
23829
|
+
case 31:
|
|
23830
|
+
_context2.next = 37;
|
|
23831
|
+
break;
|
|
23832
|
+
|
|
23833
|
+
case 33:
|
|
23834
|
+
_context2.prev = 33;
|
|
23835
|
+
_context2.t1 = _context2["catch"](14);
|
|
23836
|
+
// eslint-disable-next-line no-console
|
|
23837
|
+
console.log(_context2.t1);
|
|
23838
|
+
throw new Error("Failed to parse external ref ".concat(urn));
|
|
23839
|
+
|
|
23840
|
+
case 37:
|
|
23841
|
+
if (!(typeof response === 'boolean')) {
|
|
23842
|
+
_context2.next = 39;
|
|
23843
|
+
break;
|
|
23844
|
+
}
|
|
23845
|
+
|
|
23846
|
+
throw new Error("External ref does not contain a valid schema - ".concat(urn));
|
|
23847
|
+
|
|
23848
|
+
case 39:
|
|
23849
|
+
return _context2.abrupt("return", "continue");
|
|
23850
|
+
|
|
23851
|
+
case 40:
|
|
23852
|
+
if (_this10.options.ajax) {
|
|
23853
|
+
_context2.next = 42;
|
|
23854
|
+
break;
|
|
23855
|
+
}
|
|
23856
|
+
|
|
23857
|
+
throw new Error("Must set ajax option to true to load external ref ".concat(uri));
|
|
23858
|
+
|
|
23859
|
+
case 42:
|
|
23860
|
+
waiting++;
|
|
23861
|
+
url = _this10._joinUrl(uri, fileBase);
|
|
23862
|
+
externalSchema = void 0;
|
|
23863
|
+
|
|
23864
|
+
if (_this10.options.ajax_cache_responses) {
|
|
23865
|
+
schemaFromCache = _this10.cacheGet(url);
|
|
23866
|
+
|
|
23867
|
+
if (schemaFromCache) {
|
|
23868
|
+
externalSchema = schemaFromCache;
|
|
23869
|
+
}
|
|
23870
|
+
}
|
|
23871
|
+
|
|
23872
|
+
if (externalSchema) {
|
|
23873
|
+
_context2.next = 61;
|
|
23874
|
+
break;
|
|
23875
|
+
}
|
|
23876
|
+
|
|
23877
|
+
_context2.next = 49;
|
|
23878
|
+
return new Promise(function (resolve) {
|
|
23879
|
+
var r = new XMLHttpRequest();
|
|
23880
|
+
if (_this10.options.ajaxCredentials) r.withCredentials = _this10.options.ajaxCredentials;
|
|
23881
|
+
r.overrideMimeType('application/json');
|
|
23882
|
+
r.open('GET', url, true);
|
|
23883
|
+
|
|
23884
|
+
r.onload = function () {
|
|
23885
|
+
resolve(r);
|
|
23886
|
+
};
|
|
23887
|
+
|
|
23888
|
+
r.onerror = function (e) {
|
|
23889
|
+
resolve(undefined);
|
|
23890
|
+
};
|
|
23891
|
+
|
|
23892
|
+
r.send();
|
|
23893
|
+
});
|
|
23894
|
+
|
|
23895
|
+
case 49:
|
|
23896
|
+
_response = _context2.sent;
|
|
23897
|
+
|
|
23898
|
+
if (!(typeof _response === 'undefined')) {
|
|
23899
|
+
_context2.next = 52;
|
|
23900
|
+
break;
|
|
23901
|
+
}
|
|
23902
|
+
|
|
23903
|
+
throw new Error("Failed to fetch ref via ajax - ".concat(uri));
|
|
23904
|
+
|
|
23905
|
+
case 52:
|
|
23906
|
+
_context2.prev = 52;
|
|
23907
|
+
externalSchema = JSON.parse(_response.responseText);
|
|
23908
|
+
|
|
23909
|
+
if (_this10.options.ajax_cache_responses) {
|
|
23910
|
+
_this10.cacheSet(url, externalSchema);
|
|
23911
|
+
}
|
|
23912
|
+
|
|
23913
|
+
_context2.next = 61;
|
|
23914
|
+
break;
|
|
23915
|
+
|
|
23916
|
+
case 57:
|
|
23917
|
+
_context2.prev = 57;
|
|
23918
|
+
_context2.t2 = _context2["catch"](52);
|
|
23919
|
+
// eslint-disable-next-line no-console
|
|
23920
|
+
console.log(_context2.t2);
|
|
23921
|
+
throw new Error("Failed to parse external ref ".concat(url));
|
|
23922
|
+
|
|
23923
|
+
case 61:
|
|
23924
|
+
if (!(!(typeof externalSchema === 'boolean' || _typeof(externalSchema) === 'object') || externalSchema === null || Array.isArray(externalSchema))) {
|
|
23925
|
+
_context2.next = 63;
|
|
23926
|
+
break;
|
|
23927
|
+
}
|
|
23928
|
+
|
|
23929
|
+
throw new Error("External ref does not contain a valid schema - ".concat(url));
|
|
23930
|
+
|
|
23931
|
+
case 63:
|
|
23932
|
+
_this10.refs[uri] = externalSchema;
|
|
23933
|
+
newfileBase = _this10._getFileBaseFromFileLocation(url); // Add leading slash.
|
|
23934
|
+
|
|
23935
|
+
if (url !== uri) {
|
|
23936
|
+
pathItems = url.split('/');
|
|
23937
|
+
url = (uri.substr(0, 1) === '/' ? '/' : '') + pathItems.pop();
|
|
23938
|
+
}
|
|
23939
|
+
|
|
23940
|
+
_context2.next = 68;
|
|
23941
|
+
return _this10._asyncloadExternalRefs(externalSchema, url, newfileBase);
|
|
23942
|
+
|
|
23943
|
+
case 68:
|
|
23944
|
+
case "end":
|
|
23945
|
+
return _context2.stop();
|
|
23946
|
+
}
|
|
23947
|
+
}
|
|
23948
|
+
}, _loop, null, [[14, 33], [18, 22], [52, 57]]);
|
|
23949
|
+
});
|
|
23950
|
+
_i2 = 0, _Object$keys = Object.keys(refs);
|
|
21752
23951
|
|
|
21753
|
-
|
|
21754
|
-
|
|
23952
|
+
case 5:
|
|
23953
|
+
if (!(_i2 < _Object$keys.length)) {
|
|
23954
|
+
_context3.next = 13;
|
|
23955
|
+
break;
|
|
21755
23956
|
}
|
|
21756
|
-
}, uri, '/');
|
|
21757
|
-
});
|
|
21758
|
-
} catch (e) {
|
|
21759
|
-
// eslint-disable-next-line no-console
|
|
21760
|
-
console.log(e);
|
|
21761
|
-
throw new Error("Failed to parse external ref ".concat(urn));
|
|
21762
|
-
}
|
|
21763
|
-
|
|
21764
|
-
if (typeof response !== 'boolean') {
|
|
21765
|
-
throw new Error("External ref does not contain a valid schema - ".concat(urn));
|
|
21766
|
-
} else if (response !== true) {
|
|
21767
|
-
throw new Error("External ref did not resolve - ".concat(urn));
|
|
21768
|
-
}
|
|
21769
|
-
|
|
21770
|
-
return;
|
|
21771
|
-
}
|
|
21772
23957
|
|
|
21773
|
-
|
|
21774
|
-
_this12.refs[uri] = 'loading';
|
|
21775
|
-
waiting++;
|
|
23958
|
+
return _context3.delegateYield(_loop(), "t0", 7);
|
|
21776
23959
|
|
|
21777
|
-
|
|
23960
|
+
case 7:
|
|
23961
|
+
_ret = _context3.t0;
|
|
21778
23962
|
|
|
21779
|
-
|
|
21780
|
-
|
|
21781
|
-
|
|
21782
|
-
|
|
21783
|
-
|
|
21784
|
-
r.onreadystatechange = function () {
|
|
21785
|
-
if (r.readyState !== 4) return;
|
|
21786
|
-
/* Request succeeded */
|
|
21787
|
-
|
|
21788
|
-
if (r.status === 200) {
|
|
21789
|
-
var _schema2;
|
|
21790
|
-
|
|
21791
|
-
try {
|
|
21792
|
-
_schema2 = JSON.parse(r.responseText);
|
|
21793
|
-
} catch (e) {
|
|
21794
|
-
// eslint-disable-next-line no-console
|
|
21795
|
-
console.log(e);
|
|
21796
|
-
throw new Error("Failed to parse external ref ".concat(url));
|
|
21797
|
-
}
|
|
23963
|
+
if (!(_ret === "continue")) {
|
|
23964
|
+
_context3.next = 10;
|
|
23965
|
+
break;
|
|
23966
|
+
}
|
|
21798
23967
|
|
|
21799
|
-
|
|
21800
|
-
throw new Error("External ref does not contain a valid schema - ".concat(url));
|
|
21801
|
-
}
|
|
23968
|
+
return _context3.abrupt("continue", 10);
|
|
21802
23969
|
|
|
21803
|
-
|
|
23970
|
+
case 10:
|
|
23971
|
+
_i2++;
|
|
23972
|
+
_context3.next = 5;
|
|
23973
|
+
break;
|
|
21804
23974
|
|
|
21805
|
-
|
|
23975
|
+
case 13:
|
|
23976
|
+
if (waiting) {
|
|
23977
|
+
_context3.next = 15;
|
|
23978
|
+
break;
|
|
23979
|
+
}
|
|
21806
23980
|
|
|
23981
|
+
return _context3.abrupt("return", true);
|
|
21807
23982
|
|
|
21808
|
-
|
|
21809
|
-
|
|
21810
|
-
|
|
23983
|
+
case 15:
|
|
23984
|
+
case "end":
|
|
23985
|
+
return _context3.stop();
|
|
21811
23986
|
}
|
|
21812
|
-
|
|
21813
|
-
_this12._getDefinitions(_schema2, "".concat(url, "#/definitions/"));
|
|
21814
|
-
|
|
21815
|
-
_this12._loadExternalRefs(_schema2, function () {
|
|
21816
|
-
waiting--;
|
|
21817
|
-
|
|
21818
|
-
if (done && !waiting) {
|
|
21819
|
-
callback();
|
|
21820
|
-
}
|
|
21821
|
-
}, url, _fileBase);
|
|
21822
|
-
} else {
|
|
21823
|
-
/* Request failed */
|
|
21824
|
-
// eslint-disable-next-line no-console
|
|
21825
|
-
console.log(r);
|
|
21826
|
-
throw new Error("Failed to fetch ref via ajax - ".concat(uri));
|
|
21827
23987
|
}
|
|
21828
|
-
};
|
|
21829
|
-
|
|
21830
|
-
r.send();
|
|
21831
|
-
});
|
|
21832
|
-
done = true;
|
|
23988
|
+
}, _callee2, this);
|
|
23989
|
+
}));
|
|
21833
23990
|
|
|
21834
|
-
|
|
21835
|
-
|
|
23991
|
+
function _asyncloadExternalRefs(_x4, _x5, _x6) {
|
|
23992
|
+
return _asyncloadExternalRefs2.apply(this, arguments);
|
|
21836
23993
|
}
|
|
21837
|
-
|
|
23994
|
+
|
|
23995
|
+
return _asyncloadExternalRefs;
|
|
23996
|
+
}()
|
|
21838
23997
|
}, {
|
|
21839
23998
|
key: "extendSchemas",
|
|
21840
23999
|
value: function extendSchemas(obj1, obj2) {
|
|
21841
|
-
var
|
|
24000
|
+
var _this11 = this;
|
|
21842
24001
|
|
|
21843
|
-
obj1 = Object(
|
|
21844
|
-
obj2 = Object(
|
|
24002
|
+
obj1 = Object(_utilities_js__WEBPACK_IMPORTED_MODULE_32__["extend"])({}, obj1);
|
|
24003
|
+
obj2 = Object(_utilities_js__WEBPACK_IMPORTED_MODULE_32__["extend"])({}, obj2);
|
|
21845
24004
|
var extended = {};
|
|
21846
24005
|
|
|
21847
24006
|
var isRequiredOrDefaultProperties = function isRequiredOrDefaultProperties(prop, val) {
|
|
@@ -21860,7 +24019,7 @@ var SchemaLoader = /*#__PURE__*/function () {
|
|
|
21860
24019
|
mergeType(val);
|
|
21861
24020
|
} else if (_typeof(val) === 'object' && !Array.isArray(val) && val !== null) {
|
|
21862
24021
|
/* Objects should be recursively merged */
|
|
21863
|
-
extended[prop] =
|
|
24022
|
+
extended[prop] = _this11.extendSchemas(val, obj2[prop]);
|
|
21864
24023
|
} else {
|
|
21865
24024
|
/* Otherwise, use the first value */
|
|
21866
24025
|
extended[prop] = val;
|
|
@@ -21920,6 +24079,99 @@ var SchemaLoader = /*#__PURE__*/function () {
|
|
|
21920
24079
|
});
|
|
21921
24080
|
return extended;
|
|
21922
24081
|
}
|
|
24082
|
+
/**
|
|
24083
|
+
* Gets a cache key namespaced for JSON Editor.
|
|
24084
|
+
*
|
|
24085
|
+
* @param {*} key
|
|
24086
|
+
* The schema's key, e.g., URL.
|
|
24087
|
+
* @returns {string}
|
|
24088
|
+
* A namespaced cache key, by prefixing "je-cache::".
|
|
24089
|
+
*/
|
|
24090
|
+
|
|
24091
|
+
}, {
|
|
24092
|
+
key: "getCacheKey",
|
|
24093
|
+
value: function getCacheKey(key) {
|
|
24094
|
+
return ['je-cache', key].join('::');
|
|
24095
|
+
}
|
|
24096
|
+
/**
|
|
24097
|
+
* Returns the schema cache buster from JSON Editor settings.
|
|
24098
|
+
*
|
|
24099
|
+
* @returns {string}
|
|
24100
|
+
* The configured cache buster, if any. Otherwise, returns the current date
|
|
24101
|
+
* in ISO 8601 simplified format (e.g., 2011-10-05 for October 5, 2011).
|
|
24102
|
+
*/
|
|
24103
|
+
|
|
24104
|
+
}, {
|
|
24105
|
+
key: "getCacheBuster",
|
|
24106
|
+
value: function getCacheBuster() {
|
|
24107
|
+
return this.options.ajax_cache_buster || new Date().toISOString().slice(0, 10);
|
|
24108
|
+
}
|
|
24109
|
+
/**
|
|
24110
|
+
* Sets a schema into localStorage cache.
|
|
24111
|
+
*
|
|
24112
|
+
* @param {string} key
|
|
24113
|
+
* The schema's key, e.g., URL.
|
|
24114
|
+
* @param {mixed} data
|
|
24115
|
+
* The schema to store. Can be any data type.
|
|
24116
|
+
*/
|
|
24117
|
+
|
|
24118
|
+
}, {
|
|
24119
|
+
key: "cacheSet",
|
|
24120
|
+
value: function cacheSet(key, data) {
|
|
24121
|
+
try {
|
|
24122
|
+
window.localStorage.setItem(this.getCacheKey(key), JSON.stringify({
|
|
24123
|
+
cacheBuster: this.getCacheBuster(),
|
|
24124
|
+
schema: data
|
|
24125
|
+
}));
|
|
24126
|
+
} catch (e) {
|
|
24127
|
+
// eslint-disable-next-line no-console
|
|
24128
|
+
console.error(e);
|
|
24129
|
+
}
|
|
24130
|
+
}
|
|
24131
|
+
/**
|
|
24132
|
+
* Fetches a schema from localStorage cache.
|
|
24133
|
+
*
|
|
24134
|
+
* @param {string} key
|
|
24135
|
+
* The schema's key, e.g., URL.
|
|
24136
|
+
*
|
|
24137
|
+
* @returns {mixed}
|
|
24138
|
+
* If found, returns the schema.
|
|
24139
|
+
*/
|
|
24140
|
+
|
|
24141
|
+
}, {
|
|
24142
|
+
key: "cacheGet",
|
|
24143
|
+
value: function cacheGet(key) {
|
|
24144
|
+
try {
|
|
24145
|
+
var resultRaw = window.localStorage.getItem(this.getCacheKey(key));
|
|
24146
|
+
|
|
24147
|
+
if (resultRaw) {
|
|
24148
|
+
var resultDecoded = JSON.parse(resultRaw);
|
|
24149
|
+
|
|
24150
|
+
if (resultDecoded.cacheBuster && resultDecoded.schema) {
|
|
24151
|
+
if (resultDecoded.cacheBuster === this.getCacheBuster()) {
|
|
24152
|
+
return resultDecoded.schema;
|
|
24153
|
+
}
|
|
24154
|
+
}
|
|
24155
|
+
|
|
24156
|
+
this.cacheDelete(key);
|
|
24157
|
+
}
|
|
24158
|
+
} catch (e) {
|
|
24159
|
+
// eslint-disable-next-line no-console
|
|
24160
|
+
console.error(e);
|
|
24161
|
+
}
|
|
24162
|
+
}
|
|
24163
|
+
/**
|
|
24164
|
+
* Deletes a schema from localStorage cache.
|
|
24165
|
+
*
|
|
24166
|
+
* @param {string} key
|
|
24167
|
+
* The schema's key, e.g., URL.
|
|
24168
|
+
*/
|
|
24169
|
+
|
|
24170
|
+
}, {
|
|
24171
|
+
key: "cacheDelete",
|
|
24172
|
+
value: function cacheDelete(key) {
|
|
24173
|
+
window.localStorage.removeItem(this.getCacheKey(key));
|
|
24174
|
+
}
|
|
21923
24175
|
}]);
|
|
21924
24176
|
|
|
21925
24177
|
return SchemaLoader;
|
|
@@ -21942,6 +24194,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
21942
24194
|
".je-modal": "background-color:white;border:1px%20solid%20black;box-shadow:3px%203px%20black;position:absolute;z-index:10",
|
|
21943
24195
|
".je-infobutton-icon": "font-size:16px;font-weight:bold;padding:0.25rem;position:relative;display:inline-block",
|
|
21944
24196
|
".je-infobutton-tooltip": "font-size:12px;font-weight:normal;font-family:sans-serif;visibility:hidden;background-color:rgba(50%2C%2050%2C%2050%2C%200.75);margin:0%200.25rem;color:%23fafafa;padding:0.5rem%201rem;border-radius:0.25rem;width:20rem;position:absolute",
|
|
24197
|
+
".je-not-loaded": "pointer-events:none",
|
|
21945
24198
|
".je-header": "display:inline-block",
|
|
21946
24199
|
".je-upload-preview img": "float:left;margin:0%200.5rem%200.5rem%200;max-width:100%25;max-height:5rem",
|
|
21947
24200
|
".je-checkbox": "display:inline-block;width:auto",
|
|
@@ -22658,7 +24911,6 @@ var AbstractTheme = /*#__PURE__*/function () {
|
|
|
22658
24911
|
key: "getRangeOutput",
|
|
22659
24912
|
value: function getRangeOutput(input, startvalue) {
|
|
22660
24913
|
var output = document.createElement('output');
|
|
22661
|
-
output.value = startvalue || 0;
|
|
22662
24914
|
|
|
22663
24915
|
var updateOutput = function updateOutput(e) {
|
|
22664
24916
|
output.value = e.currentTarget.value;
|
|
@@ -23398,6 +25650,7 @@ var bootstrap3Theme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
23398
25650
|
|
|
23399
25651
|
if (label && (input.type === 'checkbox' || input.type === 'radio')) {
|
|
23400
25652
|
group.classList.add(input.type);
|
|
25653
|
+
if (infoText) label.appendChild(infoText);
|
|
23401
25654
|
label.insertBefore(input, label.firstChild);
|
|
23402
25655
|
group.appendChild(label);
|
|
23403
25656
|
} else {
|
|
@@ -25474,7 +27727,7 @@ var spectreTheme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
25474
27727
|
|
|
25475
27728
|
var icon = document.createElement('i');
|
|
25476
27729
|
icon.classList.add('form-icon');
|
|
25477
|
-
el.classList.add('form-checkbox', '
|
|
27730
|
+
el.classList.add('form-checkbox', 'pr-0');
|
|
25478
27731
|
el.insertBefore(icon, el.firstChild);
|
|
25479
27732
|
return el;
|
|
25480
27733
|
}
|
|
@@ -25587,6 +27840,7 @@ var spectreTheme = /*#__PURE__*/function (_AbstractTheme) {
|
|
|
25587
27840
|
|
|
25588
27841
|
if (label && (input.type === 'checkbox' || input.type === 'radio')) {
|
|
25589
27842
|
group.classList.add(input.type);
|
|
27843
|
+
if (infoText) label.appendChild(infoText);
|
|
25590
27844
|
label.insertBefore(input, label.firstChild);
|
|
25591
27845
|
group.appendChild(label);
|
|
25592
27846
|
} else {
|
|
@@ -26495,7 +28749,7 @@ tailwindTheme.rules = _tailwind_css_js__WEBPACK_IMPORTED_MODULE_17__["default"];
|
|
|
26495
28749
|
/*!**************************!*\
|
|
26496
28750
|
!*** ./src/utilities.js ***!
|
|
26497
28751
|
\**************************/
|
|
26498
|
-
/*! exports provided: isPlainObject, deepCopy, extend, trigger, getShadowParent, hasOwnProperty, isNumber, isInteger */
|
|
28752
|
+
/*! exports provided: isPlainObject, deepCopy, extend, trigger, getShadowParent, hasOwnProperty, isNumber, isInteger, generateUUID */
|
|
26499
28753
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
26500
28754
|
|
|
26501
28755
|
"use strict";
|
|
@@ -26508,6 +28762,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
26508
28762
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "hasOwnProperty", function() { return hasOwnProperty; });
|
|
26509
28763
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isNumber", function() { return isNumber; });
|
|
26510
28764
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isInteger", function() { return isInteger; });
|
|
28765
|
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "generateUUID", function() { return generateUUID; });
|
|
26511
28766
|
/* harmony import */ var core_js_modules_es_array_is_array_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.array.is-array.js */ "./node_modules/core-js/modules/es.array.is-array.js");
|
|
26512
28767
|
/* harmony import */ var core_js_modules_es_array_is_array_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_is_array_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
26513
28768
|
/* harmony import */ var core_js_modules_es_array_map_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es.array.map.js */ "./node_modules/core-js/modules/es.array.map.js");
|
|
@@ -26532,18 +28787,21 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
26532
28787
|
/* harmony import */ var core_js_modules_es_parse_float_js__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_parse_float_js__WEBPACK_IMPORTED_MODULE_10__);
|
|
26533
28788
|
/* harmony import */ var core_js_modules_es_parse_int_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! core-js/modules/es.parse-int.js */ "./node_modules/core-js/modules/es.parse-int.js");
|
|
26534
28789
|
/* harmony import */ var core_js_modules_es_parse_int_js__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_parse_int_js__WEBPACK_IMPORTED_MODULE_11__);
|
|
26535
|
-
/* harmony import */ var
|
|
26536
|
-
/* harmony import */ var
|
|
26537
|
-
/* harmony import */ var
|
|
26538
|
-
/* harmony import */ var
|
|
26539
|
-
/* harmony import */ var
|
|
26540
|
-
/* harmony import */ var
|
|
26541
|
-
/* harmony import */ var
|
|
26542
|
-
/* harmony import */ var
|
|
26543
|
-
/* harmony import */ var
|
|
26544
|
-
/* harmony import */ var
|
|
26545
|
-
/* harmony import */ var
|
|
26546
|
-
/* harmony import */ var
|
|
28790
|
+
/* harmony import */ var core_js_modules_es_string_replace_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! core-js/modules/es.string.replace.js */ "./node_modules/core-js/modules/es.string.replace.js");
|
|
28791
|
+
/* harmony import */ var core_js_modules_es_string_replace_js__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_replace_js__WEBPACK_IMPORTED_MODULE_12__);
|
|
28792
|
+
/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! core-js/modules/es.symbol.js */ "./node_modules/core-js/modules/es.symbol.js");
|
|
28793
|
+
/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_13__);
|
|
28794
|
+
/* harmony import */ var core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! core-js/modules/es.symbol.description.js */ "./node_modules/core-js/modules/es.symbol.description.js");
|
|
28795
|
+
/* harmony import */ var core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_14__);
|
|
28796
|
+
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! core-js/modules/es.symbol.iterator.js */ "./node_modules/core-js/modules/es.symbol.iterator.js");
|
|
28797
|
+
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_15__);
|
|
28798
|
+
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! core-js/modules/es.array.iterator.js */ "./node_modules/core-js/modules/es.array.iterator.js");
|
|
28799
|
+
/* harmony import */ var core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_16___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_iterator_js__WEBPACK_IMPORTED_MODULE_16__);
|
|
28800
|
+
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! core-js/modules/es.string.iterator.js */ "./node_modules/core-js/modules/es.string.iterator.js");
|
|
28801
|
+
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_17___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_17__);
|
|
28802
|
+
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! core-js/modules/web.dom-collections.iterator.js */ "./node_modules/core-js/modules/web.dom-collections.iterator.js");
|
|
28803
|
+
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_18___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_18__);
|
|
28804
|
+
|
|
26547
28805
|
|
|
26548
28806
|
|
|
26549
28807
|
|
|
@@ -26647,6 +28905,25 @@ function isInteger(value) {
|
|
|
26647
28905
|
var v = parseInt(value);
|
|
26648
28906
|
return match !== null && !isNaN(v) && isFinite(v);
|
|
26649
28907
|
}
|
|
28908
|
+
/* This function generates a uuid.
|
|
28909
|
+
https://stackoverflow.com/questions/105034/create-guid-uuid-in-javascript
|
|
28910
|
+
TODO: It will be probably better to move to: https://www.npmjs.com/package/uuid
|
|
28911
|
+
*/
|
|
28912
|
+
|
|
28913
|
+
function generateUUID() {
|
|
28914
|
+
var d = new Date().getTime();
|
|
28915
|
+
|
|
28916
|
+
if (typeof performance !== 'undefined' && typeof performance.now === 'function') {
|
|
28917
|
+
d += performance.now();
|
|
28918
|
+
/* use high-precision timer if available */
|
|
28919
|
+
}
|
|
28920
|
+
|
|
28921
|
+
return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (c) {
|
|
28922
|
+
var r = (d + Math.random() * 16) % 16 | 0;
|
|
28923
|
+
d = Math.floor(d / 16);
|
|
28924
|
+
return (c === 'x' ? r : r & 0x3 | 0x8).toString(16);
|
|
28925
|
+
});
|
|
28926
|
+
}
|
|
26650
28927
|
|
|
26651
28928
|
/***/ }),
|
|
26652
28929
|
|
|
@@ -26818,7 +29095,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
26818
29095
|
return [{
|
|
26819
29096
|
path: path,
|
|
26820
29097
|
property: 'const',
|
|
26821
|
-
message: this.translate('error_const')
|
|
29098
|
+
message: this.translate('error_const', null, schema)
|
|
26822
29099
|
}];
|
|
26823
29100
|
}
|
|
26824
29101
|
|
|
@@ -26834,7 +29111,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
26834
29111
|
return [{
|
|
26835
29112
|
path: path,
|
|
26836
29113
|
property: 'enum',
|
|
26837
|
-
message: this.translate('error_enum')
|
|
29114
|
+
message: this.translate('error_enum', null, schema)
|
|
26838
29115
|
}];
|
|
26839
29116
|
}
|
|
26840
29117
|
|
|
@@ -26871,7 +29148,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
26871
29148
|
return [{
|
|
26872
29149
|
path: path,
|
|
26873
29150
|
property: 'anyOf',
|
|
26874
|
-
message: this.translate('error_anyOf')
|
|
29151
|
+
message: this.translate('error_anyOf', null, schema)
|
|
26875
29152
|
}];
|
|
26876
29153
|
}
|
|
26877
29154
|
|
|
@@ -26901,7 +29178,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
26901
29178
|
errors.push({
|
|
26902
29179
|
path: path,
|
|
26903
29180
|
property: 'oneOf',
|
|
26904
|
-
message: this.translate('error_oneOf', [valid])
|
|
29181
|
+
message: this.translate('error_oneOf', [valid], schema)
|
|
26905
29182
|
});
|
|
26906
29183
|
errors.push.apply(errors, oneofErrors);
|
|
26907
29184
|
}
|
|
@@ -26913,7 +29190,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
26913
29190
|
return [{
|
|
26914
29191
|
path: path,
|
|
26915
29192
|
property: 'not',
|
|
26916
|
-
message: this.translate('error_not')
|
|
29193
|
+
message: this.translate('error_not', null, schema)
|
|
26917
29194
|
}];
|
|
26918
29195
|
}
|
|
26919
29196
|
|
|
@@ -26932,7 +29209,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
26932
29209
|
return [{
|
|
26933
29210
|
path: path,
|
|
26934
29211
|
property: 'type',
|
|
26935
|
-
message: this.translate('error_type_union')
|
|
29212
|
+
message: this.translate('error_type_union', null, schema)
|
|
26936
29213
|
}];
|
|
26937
29214
|
}
|
|
26938
29215
|
} else {
|
|
@@ -26945,14 +29222,14 @@ var Validator = /*#__PURE__*/function () {
|
|
|
26945
29222
|
return [{
|
|
26946
29223
|
path: path,
|
|
26947
29224
|
property: 'type',
|
|
26948
|
-
message: this.translate('error_type', [schema.format])
|
|
29225
|
+
message: this.translate('error_type', [schema.format], schema)
|
|
26949
29226
|
}];
|
|
26950
29227
|
}
|
|
26951
29228
|
} else if (!this._checkType(schema.type, value)) {
|
|
26952
29229
|
return [{
|
|
26953
29230
|
path: path,
|
|
26954
29231
|
property: 'type',
|
|
26955
|
-
message: this.translate('error_type', [schema.type])
|
|
29232
|
+
message: this.translate('error_type', [schema.type], schema)
|
|
26956
29233
|
}];
|
|
26957
29234
|
}
|
|
26958
29235
|
}
|
|
@@ -26972,7 +29249,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
26972
29249
|
return [{
|
|
26973
29250
|
path: path,
|
|
26974
29251
|
property: 'disallow',
|
|
26975
|
-
message: this.translate('error_disallow_union')
|
|
29252
|
+
message: this.translate('error_disallow_union', null, schema)
|
|
26976
29253
|
}];
|
|
26977
29254
|
}
|
|
26978
29255
|
} else {
|
|
@@ -26981,7 +29258,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
26981
29258
|
return [{
|
|
26982
29259
|
path: path,
|
|
26983
29260
|
property: 'disallow',
|
|
26984
|
-
message: this.translate('error_disallow', [schema.disallow])
|
|
29261
|
+
message: this.translate('error_disallow', [schema.disallow], schema)
|
|
26985
29262
|
}];
|
|
26986
29263
|
}
|
|
26987
29264
|
}
|
|
@@ -27012,7 +29289,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27012
29289
|
return [{
|
|
27013
29290
|
path: path,
|
|
27014
29291
|
property: 'maximum',
|
|
27015
|
-
message: this.translate(schema.exclusiveMaximum ? 'error_maximum_excl' : 'error_maximum_incl', [schema.maximum])
|
|
29292
|
+
message: this.translate(schema.exclusiveMaximum ? 'error_maximum_excl' : 'error_maximum_incl', [schema.maximum], schema)
|
|
27016
29293
|
}];
|
|
27017
29294
|
}
|
|
27018
29295
|
|
|
@@ -27034,7 +29311,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27034
29311
|
return [{
|
|
27035
29312
|
path: path,
|
|
27036
29313
|
property: 'minimum',
|
|
27037
|
-
message: this.translate(schema.exclusiveMinimum ? 'error_minimum_excl' : 'error_minimum_incl', [schema.minimum])
|
|
29314
|
+
message: this.translate(schema.exclusiveMinimum ? 'error_minimum_excl' : 'error_minimum_incl', [schema.minimum], schema)
|
|
27038
29315
|
}];
|
|
27039
29316
|
}
|
|
27040
29317
|
|
|
@@ -27049,7 +29326,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27049
29326
|
errors.push({
|
|
27050
29327
|
path: path,
|
|
27051
29328
|
property: 'maxLength',
|
|
27052
|
-
message: this.translate('error_maxLength', [schema.maxLength])
|
|
29329
|
+
message: this.translate('error_maxLength', [schema.maxLength], schema)
|
|
27053
29330
|
});
|
|
27054
29331
|
}
|
|
27055
29332
|
|
|
@@ -27062,7 +29339,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27062
29339
|
return [{
|
|
27063
29340
|
path: path,
|
|
27064
29341
|
property: 'minLength',
|
|
27065
|
-
message: this.translate(schema.minLength === 1 ? 'error_notempty' : 'error_minLength', [schema.minLength])
|
|
29342
|
+
message: this.translate(schema.minLength === 1 ? 'error_notempty' : 'error_minLength', [schema.minLength], schema)
|
|
27066
29343
|
}];
|
|
27067
29344
|
}
|
|
27068
29345
|
|
|
@@ -27075,7 +29352,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27075
29352
|
return [{
|
|
27076
29353
|
path: path,
|
|
27077
29354
|
property: 'pattern',
|
|
27078
|
-
message: schema.options && schema.options.patternmessage ? schema.options.patternmessage : this.translate('error_pattern', [schema.pattern])
|
|
29355
|
+
message: schema.options && schema.options.patternmessage ? schema.options.patternmessage : this.translate('error_pattern', [schema.pattern], schema)
|
|
27079
29356
|
}];
|
|
27080
29357
|
}
|
|
27081
29358
|
|
|
@@ -27108,7 +29385,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27108
29385
|
errors.push({
|
|
27109
29386
|
path: path,
|
|
27110
29387
|
property: 'additionalItems',
|
|
27111
|
-
message: this.translate('error_additionalItems')
|
|
29388
|
+
message: this.translate('error_additionalItems', null, schema)
|
|
27112
29389
|
});
|
|
27113
29390
|
break;
|
|
27114
29391
|
/* Default for `additionalItems` is an empty schema */
|
|
@@ -27132,7 +29409,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27132
29409
|
return [{
|
|
27133
29410
|
path: path,
|
|
27134
29411
|
property: 'maxItems',
|
|
27135
|
-
message: this.translate('error_maxItems', [schema.maxItems])
|
|
29412
|
+
message: this.translate('error_maxItems', [schema.maxItems], schema)
|
|
27136
29413
|
}];
|
|
27137
29414
|
}
|
|
27138
29415
|
|
|
@@ -27143,7 +29420,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27143
29420
|
return [{
|
|
27144
29421
|
path: path,
|
|
27145
29422
|
property: 'minItems',
|
|
27146
|
-
message: this.translate('error_minItems', [schema.minItems])
|
|
29423
|
+
message: this.translate('error_minItems', [schema.minItems], schema)
|
|
27147
29424
|
}];
|
|
27148
29425
|
}
|
|
27149
29426
|
|
|
@@ -27159,7 +29436,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27159
29436
|
return [{
|
|
27160
29437
|
path: path,
|
|
27161
29438
|
property: 'uniqueItems',
|
|
27162
|
-
message: this.translate('error_uniqueItems')
|
|
29439
|
+
message: this.translate('error_uniqueItems', null, schema)
|
|
27163
29440
|
}];
|
|
27164
29441
|
}
|
|
27165
29442
|
|
|
@@ -27175,7 +29452,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27175
29452
|
return [{
|
|
27176
29453
|
path: path,
|
|
27177
29454
|
property: 'maxProperties',
|
|
27178
|
-
message: this.translate('error_maxProperties', [schema.maxProperties])
|
|
29455
|
+
message: this.translate('error_maxProperties', [schema.maxProperties], schema)
|
|
27179
29456
|
}];
|
|
27180
29457
|
}
|
|
27181
29458
|
|
|
@@ -27186,7 +29463,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27186
29463
|
return [{
|
|
27187
29464
|
path: path,
|
|
27188
29465
|
property: 'minProperties',
|
|
27189
|
-
message: this.translate('error_minProperties', [schema.minProperties])
|
|
29466
|
+
message: this.translate('error_minProperties', [schema.minProperties], schema)
|
|
27190
29467
|
}];
|
|
27191
29468
|
}
|
|
27192
29469
|
|
|
@@ -27210,7 +29487,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27210
29487
|
errors.push({
|
|
27211
29488
|
path: path,
|
|
27212
29489
|
property: 'required',
|
|
27213
|
-
message: _this8.translate('error_required', [schema && schema.properties && schema.properties[e] && schema.properties[e].title ? schema.properties[e].title : e])
|
|
29490
|
+
message: _this8.translate('error_required', [schema && schema.properties && schema.properties[e] && schema.properties[e].title ? schema.properties[e].title : e], schema)
|
|
27214
29491
|
});
|
|
27215
29492
|
});
|
|
27216
29493
|
}
|
|
@@ -27279,7 +29556,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27279
29556
|
errors.push({
|
|
27280
29557
|
path: path,
|
|
27281
29558
|
property: 'propertyNames',
|
|
27282
|
-
message: _this11.translate('error_property_names_false', [k])
|
|
29559
|
+
message: _this11.translate('error_property_names_false', [k], schema)
|
|
27283
29560
|
});
|
|
27284
29561
|
return "break";
|
|
27285
29562
|
}
|
|
@@ -27352,7 +29629,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27352
29629
|
errors.push({
|
|
27353
29630
|
path: path,
|
|
27354
29631
|
property: 'propertyNames',
|
|
27355
|
-
message: _this11.translate('error_property_names_unsupported', [j])
|
|
29632
|
+
message: _this11.translate('error_property_names_unsupported', [j], schema)
|
|
27356
29633
|
});
|
|
27357
29634
|
return false;
|
|
27358
29635
|
}
|
|
@@ -27360,7 +29637,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27360
29637
|
errors.push({
|
|
27361
29638
|
path: path,
|
|
27362
29639
|
property: 'propertyNames',
|
|
27363
|
-
message: _this11.translate(msg, [k])
|
|
29640
|
+
message: _this11.translate(msg, [k], schema)
|
|
27364
29641
|
});
|
|
27365
29642
|
return false;
|
|
27366
29643
|
});
|
|
@@ -27389,7 +29666,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27389
29666
|
errors.push({
|
|
27390
29667
|
path: path,
|
|
27391
29668
|
property: 'additionalProperties',
|
|
27392
|
-
message: this.translate('error_additional_properties', [k])
|
|
29669
|
+
message: this.translate('error_additional_properties', [k], schema)
|
|
27393
29670
|
});
|
|
27394
29671
|
break;
|
|
27395
29672
|
/* Allowed */
|
|
@@ -27424,7 +29701,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27424
29701
|
errors.push({
|
|
27425
29702
|
path: path,
|
|
27426
29703
|
property: 'dependencies',
|
|
27427
|
-
message: _this12.translate('error_dependency', [d])
|
|
29704
|
+
message: _this12.translate('error_dependency', [d], schema)
|
|
27428
29705
|
});
|
|
27429
29706
|
}
|
|
27430
29707
|
});
|
|
@@ -27588,7 +29865,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27588
29865
|
return [{
|
|
27589
29866
|
path: path,
|
|
27590
29867
|
property: 'required',
|
|
27591
|
-
message: this.translate('error_notset')
|
|
29868
|
+
message: this.translate('error_notset', null, schema)
|
|
27592
29869
|
}];
|
|
27593
29870
|
}
|
|
27594
29871
|
|
|
@@ -27677,7 +29954,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27677
29954
|
return [{
|
|
27678
29955
|
path: path,
|
|
27679
29956
|
property: 'format',
|
|
27680
|
-
message: this.translate('error_pattern', ['^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$'])
|
|
29957
|
+
message: this.translate('error_pattern', ['^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$'], schema)
|
|
27681
29958
|
}];
|
|
27682
29959
|
}
|
|
27683
29960
|
|
|
@@ -27703,7 +29980,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27703
29980
|
return [{
|
|
27704
29981
|
path: path,
|
|
27705
29982
|
property: schema.multipleOf ? 'multipleOf' : 'divisibleBy',
|
|
27706
|
-
message: this.translate('error_multipleOf', [divisor])
|
|
29983
|
+
message: this.translate('error_multipleOf', [divisor], schema)
|
|
27707
29984
|
}];
|
|
27708
29985
|
}
|
|
27709
29986
|
|
|
@@ -27721,14 +29998,14 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27721
29998
|
return [{
|
|
27722
29999
|
path: path,
|
|
27723
30000
|
property: 'format',
|
|
27724
|
-
message: _this15.translate('error_invalid_epoch')
|
|
30001
|
+
message: _this15.translate('error_invalid_epoch', null, schema)
|
|
27725
30002
|
}];
|
|
27726
30003
|
} else if (value !== Math.abs(parseInt(value))) {
|
|
27727
30004
|
/* not much to check for, so we assume value is ok if it's a positive number */
|
|
27728
30005
|
return [{
|
|
27729
30006
|
path: path,
|
|
27730
30007
|
property: 'format',
|
|
27731
|
-
message: _this15.translate("error_".concat(schema.format.replace(/-/g, '_')), [dateFormat])
|
|
30008
|
+
message: _this15.translate("error_".concat(schema.format.replace(/-/g, '_')), [dateFormat], schema)
|
|
27732
30009
|
}];
|
|
27733
30010
|
}
|
|
27734
30011
|
|
|
@@ -27761,7 +30038,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27761
30038
|
return [{
|
|
27762
30039
|
path: path,
|
|
27763
30040
|
property: 'format',
|
|
27764
|
-
message: _this15.translate("error_".concat(editor.format.replace(/-/g, '_')), [errorDateFormat])
|
|
30041
|
+
message: _this15.translate("error_".concat(editor.format.replace(/-/g, '_')), [errorDateFormat], schema)
|
|
27765
30042
|
}];
|
|
27766
30043
|
}
|
|
27767
30044
|
}
|
|
@@ -27790,7 +30067,7 @@ var Validator = /*#__PURE__*/function () {
|
|
|
27790
30067
|
return [{
|
|
27791
30068
|
path: path,
|
|
27792
30069
|
property: 'format',
|
|
27793
|
-
message: this.translate("error_".concat(schema.format.replace(/-/g, '_')), [dateFormat])
|
|
30070
|
+
message: this.translate("error_".concat(schema.format.replace(/-/g, '_')), [dateFormat], schema)
|
|
27794
30071
|
}];
|
|
27795
30072
|
}
|
|
27796
30073
|
} else if (editor) {
|