@wix/form-public 0.24.0 → 0.26.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/dist/_tsup-dts-rollup.d.cts +34 -6
- package/dist/_tsup-dts-rollup.d.ts +34 -6
- package/dist/index.cjs +1060 -917
- package/dist/index.cjs.map +1 -1
- package/dist/index.css +544 -579
- package/dist/index.css.map +1 -1
- package/dist/index.js +961 -818
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import * as
|
|
2
|
-
import
|
|
1
|
+
import * as React32 from 'react';
|
|
2
|
+
import React32__default, { createContext, forwardRef, useState, useMemo, useRef, useEffect, useCallback, useImperativeHandle, useContext } from 'react';
|
|
3
3
|
import ReactDOM from 'react-dom';
|
|
4
4
|
import camelCase from 'lodash.camelcase';
|
|
5
5
|
import mapKeys from 'lodash.mapkeys';
|
|
@@ -2004,15 +2004,15 @@ var init_typeof = __esm({
|
|
|
2004
2004
|
});
|
|
2005
2005
|
|
|
2006
2006
|
// ../../node_modules/@babel/runtime/helpers/esm/toPrimitive.js
|
|
2007
|
-
function toPrimitive(
|
|
2008
|
-
if ("object" != _typeof(
|
|
2009
|
-
var
|
|
2010
|
-
if (void 0 !==
|
|
2011
|
-
var
|
|
2012
|
-
if ("object" != _typeof(
|
|
2007
|
+
function toPrimitive(t, r) {
|
|
2008
|
+
if ("object" != _typeof(t) || !t) return t;
|
|
2009
|
+
var e = t[Symbol.toPrimitive];
|
|
2010
|
+
if (void 0 !== e) {
|
|
2011
|
+
var i = e.call(t, r);
|
|
2012
|
+
if ("object" != _typeof(i)) return i;
|
|
2013
2013
|
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
2014
2014
|
}
|
|
2015
|
-
return (String )(
|
|
2015
|
+
return (String )(t);
|
|
2016
2016
|
}
|
|
2017
2017
|
var init_toPrimitive = __esm({
|
|
2018
2018
|
"../../node_modules/@babel/runtime/helpers/esm/toPrimitive.js"() {
|
|
@@ -2021,9 +2021,9 @@ var init_toPrimitive = __esm({
|
|
|
2021
2021
|
});
|
|
2022
2022
|
|
|
2023
2023
|
// ../../node_modules/@babel/runtime/helpers/esm/toPropertyKey.js
|
|
2024
|
-
function toPropertyKey(
|
|
2025
|
-
var
|
|
2026
|
-
return "symbol" == _typeof(
|
|
2024
|
+
function toPropertyKey(t) {
|
|
2025
|
+
var i = toPrimitive(t, "string");
|
|
2026
|
+
return "symbol" == _typeof(i) ? i : i + "";
|
|
2027
2027
|
}
|
|
2028
2028
|
var init_toPropertyKey = __esm({
|
|
2029
2029
|
"../../node_modules/@babel/runtime/helpers/esm/toPropertyKey.js"() {
|
|
@@ -2033,13 +2033,13 @@ var init_toPropertyKey = __esm({
|
|
|
2033
2033
|
});
|
|
2034
2034
|
|
|
2035
2035
|
// ../../node_modules/@babel/runtime/helpers/esm/defineProperty.js
|
|
2036
|
-
function _defineProperty(
|
|
2037
|
-
return (r = toPropertyKey(r)) in
|
|
2038
|
-
value:
|
|
2036
|
+
function _defineProperty(e, r, t) {
|
|
2037
|
+
return (r = toPropertyKey(r)) in e ? Object.defineProperty(e, r, {
|
|
2038
|
+
value: t,
|
|
2039
2039
|
enumerable: true,
|
|
2040
2040
|
configurable: true,
|
|
2041
2041
|
writable: true
|
|
2042
|
-
}) :
|
|
2042
|
+
}) : e[r] = t, e;
|
|
2043
2043
|
}
|
|
2044
2044
|
var init_defineProperty = __esm({
|
|
2045
2045
|
"../../node_modules/@babel/runtime/helpers/esm/defineProperty.js"() {
|
|
@@ -2048,16 +2048,16 @@ var init_defineProperty = __esm({
|
|
|
2048
2048
|
});
|
|
2049
2049
|
|
|
2050
2050
|
// ../../node_modules/@babel/runtime/helpers/esm/objectSpread.js
|
|
2051
|
-
function _objectSpread(
|
|
2051
|
+
function _objectSpread(e) {
|
|
2052
2052
|
for (var r = 1; r < arguments.length; r++) {
|
|
2053
|
-
var
|
|
2054
|
-
"function" == typeof Object.getOwnPropertySymbols && o.push.apply(o, Object.getOwnPropertySymbols(
|
|
2055
|
-
return Object.getOwnPropertyDescriptor(
|
|
2053
|
+
var t = null != arguments[r] ? Object(arguments[r]) : {}, o = Object.keys(t);
|
|
2054
|
+
"function" == typeof Object.getOwnPropertySymbols && o.push.apply(o, Object.getOwnPropertySymbols(t).filter(function(e2) {
|
|
2055
|
+
return Object.getOwnPropertyDescriptor(t, e2).enumerable;
|
|
2056
2056
|
})), o.forEach(function(r2) {
|
|
2057
|
-
_defineProperty(
|
|
2057
|
+
_defineProperty(e, r2, t[r2]);
|
|
2058
2058
|
});
|
|
2059
2059
|
}
|
|
2060
|
-
return
|
|
2060
|
+
return e;
|
|
2061
2061
|
}
|
|
2062
2062
|
var init_objectSpread = __esm({
|
|
2063
2063
|
"../../node_modules/@babel/runtime/helpers/esm/objectSpread.js"() {
|
|
@@ -2075,16 +2075,16 @@ var init_classCallCheck = __esm({
|
|
|
2075
2075
|
});
|
|
2076
2076
|
|
|
2077
2077
|
// ../../node_modules/@babel/runtime/helpers/esm/createClass.js
|
|
2078
|
-
function _defineProperties(
|
|
2079
|
-
for (var
|
|
2080
|
-
var o = r[
|
|
2081
|
-
o.enumerable = o.enumerable || false, o.configurable = true, "value" in o && (o.writable = true), Object.defineProperty(
|
|
2078
|
+
function _defineProperties(e, r) {
|
|
2079
|
+
for (var t = 0; t < r.length; t++) {
|
|
2080
|
+
var o = r[t];
|
|
2081
|
+
o.enumerable = o.enumerable || false, o.configurable = true, "value" in o && (o.writable = true), Object.defineProperty(e, toPropertyKey(o.key), o);
|
|
2082
2082
|
}
|
|
2083
2083
|
}
|
|
2084
|
-
function _createClass(
|
|
2085
|
-
return r && _defineProperties(
|
|
2084
|
+
function _createClass(e, r, t) {
|
|
2085
|
+
return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", {
|
|
2086
2086
|
writable: false
|
|
2087
|
-
}),
|
|
2087
|
+
}), e;
|
|
2088
2088
|
}
|
|
2089
2089
|
var init_createClass = __esm({
|
|
2090
2090
|
"../../node_modules/@babel/runtime/helpers/esm/createClass.js"() {
|
|
@@ -2093,9 +2093,9 @@ var init_createClass = __esm({
|
|
|
2093
2093
|
});
|
|
2094
2094
|
|
|
2095
2095
|
// ../../node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js
|
|
2096
|
-
function _assertThisInitialized(
|
|
2097
|
-
if (void 0 ===
|
|
2098
|
-
return
|
|
2096
|
+
function _assertThisInitialized(e) {
|
|
2097
|
+
if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
2098
|
+
return e;
|
|
2099
2099
|
}
|
|
2100
2100
|
var init_assertThisInitialized = __esm({
|
|
2101
2101
|
"../../node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js"() {
|
|
@@ -2103,10 +2103,10 @@ var init_assertThisInitialized = __esm({
|
|
|
2103
2103
|
});
|
|
2104
2104
|
|
|
2105
2105
|
// ../../node_modules/@babel/runtime/helpers/esm/possibleConstructorReturn.js
|
|
2106
|
-
function _possibleConstructorReturn(
|
|
2107
|
-
if (
|
|
2108
|
-
if (void 0 !==
|
|
2109
|
-
return _assertThisInitialized(
|
|
2106
|
+
function _possibleConstructorReturn(t, e) {
|
|
2107
|
+
if (e && ("object" == _typeof(e) || "function" == typeof e)) return e;
|
|
2108
|
+
if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined");
|
|
2109
|
+
return _assertThisInitialized(t);
|
|
2110
2110
|
}
|
|
2111
2111
|
var init_possibleConstructorReturn = __esm({
|
|
2112
2112
|
"../../node_modules/@babel/runtime/helpers/esm/possibleConstructorReturn.js"() {
|
|
@@ -2116,10 +2116,10 @@ var init_possibleConstructorReturn = __esm({
|
|
|
2116
2116
|
});
|
|
2117
2117
|
|
|
2118
2118
|
// ../../node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js
|
|
2119
|
-
function _getPrototypeOf(
|
|
2120
|
-
return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(
|
|
2121
|
-
return
|
|
2122
|
-
}, _getPrototypeOf(
|
|
2119
|
+
function _getPrototypeOf(t) {
|
|
2120
|
+
return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(t2) {
|
|
2121
|
+
return t2.__proto__ || Object.getPrototypeOf(t2);
|
|
2122
|
+
}, _getPrototypeOf(t);
|
|
2123
2123
|
}
|
|
2124
2124
|
var init_getPrototypeOf = __esm({
|
|
2125
2125
|
"../../node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js"() {
|
|
@@ -2127,10 +2127,10 @@ var init_getPrototypeOf = __esm({
|
|
|
2127
2127
|
});
|
|
2128
2128
|
|
|
2129
2129
|
// ../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js
|
|
2130
|
-
function _setPrototypeOf(
|
|
2131
|
-
return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(
|
|
2132
|
-
return
|
|
2133
|
-
}, _setPrototypeOf(
|
|
2130
|
+
function _setPrototypeOf(t, e) {
|
|
2131
|
+
return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(t2, e2) {
|
|
2132
|
+
return t2.__proto__ = e2, t2;
|
|
2133
|
+
}, _setPrototypeOf(t, e);
|
|
2134
2134
|
}
|
|
2135
2135
|
var init_setPrototypeOf = __esm({
|
|
2136
2136
|
"../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js"() {
|
|
@@ -2138,17 +2138,17 @@ var init_setPrototypeOf = __esm({
|
|
|
2138
2138
|
});
|
|
2139
2139
|
|
|
2140
2140
|
// ../../node_modules/@babel/runtime/helpers/esm/inherits.js
|
|
2141
|
-
function _inherits(
|
|
2142
|
-
if ("function" != typeof
|
|
2143
|
-
|
|
2141
|
+
function _inherits(t, e) {
|
|
2142
|
+
if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function");
|
|
2143
|
+
t.prototype = Object.create(e && e.prototype, {
|
|
2144
2144
|
constructor: {
|
|
2145
|
-
value:
|
|
2145
|
+
value: t,
|
|
2146
2146
|
writable: true,
|
|
2147
2147
|
configurable: true
|
|
2148
2148
|
}
|
|
2149
|
-
}), Object.defineProperty(
|
|
2149
|
+
}), Object.defineProperty(t, "prototype", {
|
|
2150
2150
|
writable: false
|
|
2151
|
-
}),
|
|
2151
|
+
}), e && _setPrototypeOf(t, e);
|
|
2152
2152
|
}
|
|
2153
2153
|
var init_inherits = __esm({
|
|
2154
2154
|
"../../node_modules/@babel/runtime/helpers/esm/inherits.js"() {
|
|
@@ -2172,9 +2172,9 @@ function makeString(object) {
|
|
|
2172
2172
|
if (object == null) return "";
|
|
2173
2173
|
return "" + object;
|
|
2174
2174
|
}
|
|
2175
|
-
function copy(a, s,
|
|
2175
|
+
function copy(a, s, t) {
|
|
2176
2176
|
a.forEach(function(m) {
|
|
2177
|
-
if (s[m])
|
|
2177
|
+
if (s[m]) t[m] = s[m];
|
|
2178
2178
|
});
|
|
2179
2179
|
}
|
|
2180
2180
|
function getLastOfPath(object, path, Empty) {
|
|
@@ -2801,8 +2801,8 @@ var init_i18next = __esm({
|
|
|
2801
2801
|
var lngs = [];
|
|
2802
2802
|
var fallbackLngs = this.languageUtils.getFallbackCodes(this.options.fallbackLng, options.lng || this.language);
|
|
2803
2803
|
if (this.options.saveMissingTo === "fallback" && fallbackLngs && fallbackLngs[0]) {
|
|
2804
|
-
for (var
|
|
2805
|
-
lngs.push(fallbackLngs[
|
|
2804
|
+
for (var i = 0; i < fallbackLngs.length; i++) {
|
|
2805
|
+
lngs.push(fallbackLngs[i]);
|
|
2806
2806
|
}
|
|
2807
2807
|
} else if (this.options.saveMissingTo === "all") {
|
|
2808
2808
|
lngs = this.languageUtils.toResolveHierarchy(options.lng || this.language);
|
|
@@ -3473,8 +3473,8 @@ var init_i18next = __esm({
|
|
|
3473
3473
|
try {
|
|
3474
3474
|
clonedOptions = JSON.parse(optionsString);
|
|
3475
3475
|
if (inheritedOptions) clonedOptions = _objectSpread({}, inheritedOptions, clonedOptions);
|
|
3476
|
-
} catch (
|
|
3477
|
-
this.logger.warn("failed parsing options string in nesting for key ".concat(key),
|
|
3476
|
+
} catch (e) {
|
|
3477
|
+
this.logger.warn("failed parsing options string in nesting for key ".concat(key), e);
|
|
3478
3478
|
return "".concat(key).concat(sep).concat(optionsString);
|
|
3479
3479
|
}
|
|
3480
3480
|
delete clonedOptions.defaultValue;
|
|
@@ -3822,13 +3822,13 @@ var init_i18next = __esm({
|
|
|
3822
3822
|
});
|
|
3823
3823
|
var deferred = defer();
|
|
3824
3824
|
var load = function load2() {
|
|
3825
|
-
var finish = function finish2(err,
|
|
3825
|
+
var finish = function finish2(err, t) {
|
|
3826
3826
|
if (_this2.isInitialized) _this2.logger.warn("init: i18next is already initialized. You should call init just once!");
|
|
3827
3827
|
_this2.isInitialized = true;
|
|
3828
3828
|
if (!_this2.options.isClone) _this2.logger.log("initialized", _this2.options);
|
|
3829
3829
|
_this2.emit("initialized", _this2.options);
|
|
3830
|
-
deferred.resolve(
|
|
3831
|
-
callback(err,
|
|
3830
|
+
deferred.resolve(t);
|
|
3831
|
+
callback(err, t);
|
|
3832
3832
|
};
|
|
3833
3833
|
if (_this2.languages && _this2.options.compatibilityAPI !== "v1" && !_this2.isInitialized) return finish(null, _this2.t.bind(_this2));
|
|
3834
3834
|
_this2.changeLanguage(_this2.options.lng, finish);
|
|
@@ -3991,7 +3991,7 @@ var init_i18next = __esm({
|
|
|
3991
3991
|
}
|
|
3992
3992
|
}, {
|
|
3993
3993
|
key: "t",
|
|
3994
|
-
value: function
|
|
3994
|
+
value: function t() {
|
|
3995
3995
|
var _this$translator;
|
|
3996
3996
|
return this.translator && (_this$translator = this.translator).translate.apply(_this$translator, arguments);
|
|
3997
3997
|
}
|
|
@@ -4149,15 +4149,15 @@ var require_typeof = __commonJS({
|
|
|
4149
4149
|
var require_toPrimitive = __commonJS({
|
|
4150
4150
|
"../../node_modules/@babel/runtime/helpers/toPrimitive.js"(exports, module) {
|
|
4151
4151
|
var _typeof8 = require_typeof()["default"];
|
|
4152
|
-
function toPrimitive2(
|
|
4153
|
-
if ("object" != _typeof8(
|
|
4154
|
-
var
|
|
4155
|
-
if (void 0 !==
|
|
4156
|
-
var
|
|
4157
|
-
if ("object" != _typeof8(
|
|
4152
|
+
function toPrimitive2(t, r) {
|
|
4153
|
+
if ("object" != _typeof8(t) || !t) return t;
|
|
4154
|
+
var e = t[Symbol.toPrimitive];
|
|
4155
|
+
if (void 0 !== e) {
|
|
4156
|
+
var i = e.call(t, r || "default");
|
|
4157
|
+
if ("object" != _typeof8(i)) return i;
|
|
4158
4158
|
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
4159
4159
|
}
|
|
4160
|
-
return ("string" === r ? String : Number)(
|
|
4160
|
+
return ("string" === r ? String : Number)(t);
|
|
4161
4161
|
}
|
|
4162
4162
|
module.exports = toPrimitive2, module.exports.__esModule = true, module.exports["default"] = module.exports;
|
|
4163
4163
|
}
|
|
@@ -4168,9 +4168,9 @@ var require_toPropertyKey = __commonJS({
|
|
|
4168
4168
|
"../../node_modules/@babel/runtime/helpers/toPropertyKey.js"(exports, module) {
|
|
4169
4169
|
var _typeof8 = require_typeof()["default"];
|
|
4170
4170
|
var toPrimitive2 = require_toPrimitive();
|
|
4171
|
-
function toPropertyKey2(
|
|
4172
|
-
var
|
|
4173
|
-
return "symbol" == _typeof8(
|
|
4171
|
+
function toPropertyKey2(t) {
|
|
4172
|
+
var i = toPrimitive2(t, "string");
|
|
4173
|
+
return "symbol" == _typeof8(i) ? i : i + "";
|
|
4174
4174
|
}
|
|
4175
4175
|
module.exports = toPropertyKey2, module.exports.__esModule = true, module.exports["default"] = module.exports;
|
|
4176
4176
|
}
|
|
@@ -4180,13 +4180,13 @@ var require_toPropertyKey = __commonJS({
|
|
|
4180
4180
|
var require_defineProperty = __commonJS({
|
|
4181
4181
|
"../../node_modules/@babel/runtime/helpers/defineProperty.js"(exports, module) {
|
|
4182
4182
|
var toPropertyKey2 = require_toPropertyKey();
|
|
4183
|
-
function _defineProperty7(
|
|
4184
|
-
return (r = toPropertyKey2(r)) in
|
|
4185
|
-
value:
|
|
4183
|
+
function _defineProperty7(e, r, t) {
|
|
4184
|
+
return (r = toPropertyKey2(r)) in e ? Object.defineProperty(e, r, {
|
|
4185
|
+
value: t,
|
|
4186
4186
|
enumerable: true,
|
|
4187
4187
|
configurable: true,
|
|
4188
4188
|
writable: true
|
|
4189
|
-
}) :
|
|
4189
|
+
}) : e[r] = t, e;
|
|
4190
4190
|
}
|
|
4191
4191
|
module.exports = _defineProperty7, module.exports.__esModule = true, module.exports["default"] = module.exports;
|
|
4192
4192
|
}
|
|
@@ -4207,8 +4207,8 @@ var require_classnames = __commonJS({
|
|
|
4207
4207
|
var hasOwn2 = {}.hasOwnProperty;
|
|
4208
4208
|
function classNames6() {
|
|
4209
4209
|
var classes = "";
|
|
4210
|
-
for (var
|
|
4211
|
-
var arg = arguments[
|
|
4210
|
+
for (var i = 0; i < arguments.length; i++) {
|
|
4211
|
+
var arg = arguments[i];
|
|
4212
4212
|
if (arg) {
|
|
4213
4213
|
classes = appendClass(classes, parseValue(arg));
|
|
4214
4214
|
}
|
|
@@ -4261,7 +4261,7 @@ var require_classnames = __commonJS({
|
|
|
4261
4261
|
var RicosViewerContext;
|
|
4262
4262
|
var init_ViewerContext = __esm({
|
|
4263
4263
|
"../../node_modules/@wix/ricos/dist/es/ricos-context/viewer/ViewerContext.js"() {
|
|
4264
|
-
RicosViewerContext =
|
|
4264
|
+
RicosViewerContext = React32__default.createContext(null);
|
|
4265
4265
|
}
|
|
4266
4266
|
});
|
|
4267
4267
|
|
|
@@ -4278,7 +4278,7 @@ var require_react_is_production_min = __commonJS({
|
|
|
4278
4278
|
var b = "function" === typeof Symbol && Symbol.for;
|
|
4279
4279
|
var c = b ? Symbol.for("react.element") : 60103;
|
|
4280
4280
|
var d = b ? Symbol.for("react.portal") : 60106;
|
|
4281
|
-
var
|
|
4281
|
+
var e = b ? Symbol.for("react.fragment") : 60107;
|
|
4282
4282
|
var f = b ? Symbol.for("react.strict_mode") : 60108;
|
|
4283
4283
|
var g = b ? Symbol.for("react.profiler") : 60114;
|
|
4284
4284
|
var h = b ? Symbol.for("react.provider") : 60109;
|
|
@@ -4289,7 +4289,7 @@ var require_react_is_production_min = __commonJS({
|
|
|
4289
4289
|
var p = b ? Symbol.for("react.suspense") : 60113;
|
|
4290
4290
|
var q = b ? Symbol.for("react.suspense_list") : 60120;
|
|
4291
4291
|
var r = b ? Symbol.for("react.memo") : 60115;
|
|
4292
|
-
var
|
|
4292
|
+
var t = b ? Symbol.for("react.lazy") : 60116;
|
|
4293
4293
|
var v = b ? Symbol.for("react.block") : 60121;
|
|
4294
4294
|
var w = b ? Symbol.for("react.fundamental") : 60117;
|
|
4295
4295
|
var x = b ? Symbol.for("react.responder") : 60118;
|
|
@@ -4302,7 +4302,7 @@ var require_react_is_production_min = __commonJS({
|
|
|
4302
4302
|
switch (a = a.type, a) {
|
|
4303
4303
|
case l:
|
|
4304
4304
|
case m:
|
|
4305
|
-
case
|
|
4305
|
+
case e:
|
|
4306
4306
|
case g:
|
|
4307
4307
|
case f:
|
|
4308
4308
|
case p:
|
|
@@ -4311,7 +4311,7 @@ var require_react_is_production_min = __commonJS({
|
|
|
4311
4311
|
switch (a = a && a.$$typeof, a) {
|
|
4312
4312
|
case k:
|
|
4313
4313
|
case n:
|
|
4314
|
-
case
|
|
4314
|
+
case t:
|
|
4315
4315
|
case r:
|
|
4316
4316
|
case h:
|
|
4317
4317
|
return a;
|
|
@@ -4333,8 +4333,8 @@ var require_react_is_production_min = __commonJS({
|
|
|
4333
4333
|
exports.ContextProvider = h;
|
|
4334
4334
|
exports.Element = c;
|
|
4335
4335
|
exports.ForwardRef = n;
|
|
4336
|
-
exports.Fragment =
|
|
4337
|
-
exports.Lazy =
|
|
4336
|
+
exports.Fragment = e;
|
|
4337
|
+
exports.Lazy = t;
|
|
4338
4338
|
exports.Memo = r;
|
|
4339
4339
|
exports.Portal = d;
|
|
4340
4340
|
exports.Profiler = g;
|
|
@@ -4357,10 +4357,10 @@ var require_react_is_production_min = __commonJS({
|
|
|
4357
4357
|
return z(a) === n;
|
|
4358
4358
|
};
|
|
4359
4359
|
exports.isFragment = function(a) {
|
|
4360
|
-
return z(a) ===
|
|
4360
|
+
return z(a) === e;
|
|
4361
4361
|
};
|
|
4362
4362
|
exports.isLazy = function(a) {
|
|
4363
|
-
return z(a) ===
|
|
4363
|
+
return z(a) === t;
|
|
4364
4364
|
};
|
|
4365
4365
|
exports.isMemo = function(a) {
|
|
4366
4366
|
return z(a) === r;
|
|
@@ -4378,7 +4378,7 @@ var require_react_is_production_min = __commonJS({
|
|
|
4378
4378
|
return z(a) === p;
|
|
4379
4379
|
};
|
|
4380
4380
|
exports.isValidElementType = function(a) {
|
|
4381
|
-
return "string" === typeof a || "function" === typeof a || a ===
|
|
4381
|
+
return "string" === typeof a || "function" === typeof a || a === e || a === m || a === g || a === f || a === p || a === q || "object" === typeof a && null !== a && (a.$$typeof === t || a.$$typeof === r || a.$$typeof === h || a.$$typeof === k || a.$$typeof === n || a.$$typeof === w || a.$$typeof === x || a.$$typeof === y || a.$$typeof === v);
|
|
4382
4382
|
};
|
|
4383
4383
|
exports.typeOf = z;
|
|
4384
4384
|
}
|
|
@@ -4571,8 +4571,8 @@ var require_object_assign = __commonJS({
|
|
|
4571
4571
|
return false;
|
|
4572
4572
|
}
|
|
4573
4573
|
var test2 = {};
|
|
4574
|
-
for (var
|
|
4575
|
-
test2["_" + String.fromCharCode(
|
|
4574
|
+
for (var i = 0; i < 10; i++) {
|
|
4575
|
+
test2["_" + String.fromCharCode(i)] = i;
|
|
4576
4576
|
}
|
|
4577
4577
|
var order2 = Object.getOwnPropertyNames(test2).map(function(n) {
|
|
4578
4578
|
return test2[n];
|
|
@@ -4605,9 +4605,9 @@ var require_object_assign = __commonJS({
|
|
|
4605
4605
|
}
|
|
4606
4606
|
if (getOwnPropertySymbols2) {
|
|
4607
4607
|
symbols = getOwnPropertySymbols2(from);
|
|
4608
|
-
for (var
|
|
4609
|
-
if (propIsEnumerable.call(from, symbols[
|
|
4610
|
-
to[symbols[
|
|
4608
|
+
for (var i = 0; i < symbols.length; i++) {
|
|
4609
|
+
if (propIsEnumerable.call(from, symbols[i])) {
|
|
4610
|
+
to[symbols[i]] = from[symbols[i]];
|
|
4611
4611
|
}
|
|
4612
4612
|
}
|
|
4613
4613
|
}
|
|
@@ -4837,8 +4837,8 @@ var require_factoryWithTypeCheckers = __commonJS({
|
|
|
4837
4837
|
var propType = getPropType(propValue);
|
|
4838
4838
|
return new PropTypeError("Invalid " + location2 + " `" + propFullName + "` of type " + ("`" + propType + "` supplied to `" + componentName + "`, expected an array."));
|
|
4839
4839
|
}
|
|
4840
|
-
for (var
|
|
4841
|
-
var error2 = typeChecker(propValue,
|
|
4840
|
+
for (var i = 0; i < propValue.length; i++) {
|
|
4841
|
+
var error2 = typeChecker(propValue, i, componentName, location2, propFullName + "[" + i + "]", ReactPropTypesSecret);
|
|
4842
4842
|
if (error2 instanceof Error) {
|
|
4843
4843
|
return error2;
|
|
4844
4844
|
}
|
|
@@ -4895,8 +4895,8 @@ var require_factoryWithTypeCheckers = __commonJS({
|
|
|
4895
4895
|
}
|
|
4896
4896
|
function validate2(props, propName, componentName, location2, propFullName) {
|
|
4897
4897
|
var propValue = props[propName];
|
|
4898
|
-
for (var
|
|
4899
|
-
if (is(propValue, expectedValues[
|
|
4898
|
+
for (var i = 0; i < expectedValues.length; i++) {
|
|
4899
|
+
if (is(propValue, expectedValues[i])) {
|
|
4900
4900
|
return null;
|
|
4901
4901
|
}
|
|
4902
4902
|
}
|
|
@@ -4938,19 +4938,19 @@ var require_factoryWithTypeCheckers = __commonJS({
|
|
|
4938
4938
|
process.env.NODE_ENV !== "production" ? printWarning("Invalid argument supplied to oneOfType, expected an instance of array.") : void 0;
|
|
4939
4939
|
return emptyFunctionThatReturnsNull;
|
|
4940
4940
|
}
|
|
4941
|
-
for (var
|
|
4942
|
-
var checker = arrayOfTypeCheckers[
|
|
4941
|
+
for (var i = 0; i < arrayOfTypeCheckers.length; i++) {
|
|
4942
|
+
var checker = arrayOfTypeCheckers[i];
|
|
4943
4943
|
if (typeof checker !== "function") {
|
|
4944
4944
|
printWarning(
|
|
4945
|
-
"Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + getPostfixForTypeWarning(checker) + " at index " +
|
|
4945
|
+
"Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + getPostfixForTypeWarning(checker) + " at index " + i + "."
|
|
4946
4946
|
);
|
|
4947
4947
|
return emptyFunctionThatReturnsNull;
|
|
4948
4948
|
}
|
|
4949
4949
|
}
|
|
4950
4950
|
function validate2(props, propName, componentName, location2, propFullName) {
|
|
4951
4951
|
var expectedTypes = [];
|
|
4952
|
-
for (var
|
|
4953
|
-
var checker2 = arrayOfTypeCheckers[
|
|
4952
|
+
for (var i2 = 0; i2 < arrayOfTypeCheckers.length; i2++) {
|
|
4953
|
+
var checker2 = arrayOfTypeCheckers[i2];
|
|
4954
4954
|
var checkerResult = checker2(props, propName, componentName, location2, propFullName, ReactPropTypesSecret);
|
|
4955
4955
|
if (checkerResult == null) {
|
|
4956
4956
|
return null;
|
|
@@ -5210,28 +5210,28 @@ var require_prop_types = __commonJS({
|
|
|
5210
5210
|
// ../../node_modules/@babel/runtime/helpers/extends.js
|
|
5211
5211
|
var require_extends = __commonJS({
|
|
5212
5212
|
"../../node_modules/@babel/runtime/helpers/extends.js"(exports, module) {
|
|
5213
|
-
function
|
|
5214
|
-
return module.exports =
|
|
5215
|
-
for (var
|
|
5216
|
-
var
|
|
5217
|
-
for (var r in
|
|
5213
|
+
function _extends7() {
|
|
5214
|
+
return module.exports = _extends7 = Object.assign ? Object.assign.bind() : function(n) {
|
|
5215
|
+
for (var e = 1; e < arguments.length; e++) {
|
|
5216
|
+
var t = arguments[e];
|
|
5217
|
+
for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]);
|
|
5218
5218
|
}
|
|
5219
5219
|
return n;
|
|
5220
|
-
}, module.exports.__esModule = true, module.exports["default"] = module.exports,
|
|
5220
|
+
}, module.exports.__esModule = true, module.exports["default"] = module.exports, _extends7.apply(null, arguments);
|
|
5221
5221
|
}
|
|
5222
|
-
module.exports =
|
|
5222
|
+
module.exports = _extends7, module.exports.__esModule = true, module.exports["default"] = module.exports;
|
|
5223
5223
|
}
|
|
5224
5224
|
});
|
|
5225
5225
|
|
|
5226
5226
|
// ../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js
|
|
5227
|
-
function _objectWithoutPropertiesLoose(r,
|
|
5227
|
+
function _objectWithoutPropertiesLoose(r, e) {
|
|
5228
5228
|
if (null == r) return {};
|
|
5229
|
-
var
|
|
5229
|
+
var t = {};
|
|
5230
5230
|
for (var n in r) if ({}.hasOwnProperty.call(r, n)) {
|
|
5231
|
-
if (-1 !==
|
|
5232
|
-
|
|
5231
|
+
if (-1 !== e.indexOf(n)) continue;
|
|
5232
|
+
t[n] = r[n];
|
|
5233
5233
|
}
|
|
5234
|
-
return
|
|
5234
|
+
return t;
|
|
5235
5235
|
}
|
|
5236
5236
|
var init_objectWithoutPropertiesLoose = __esm({
|
|
5237
5237
|
"../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js"() {
|
|
@@ -5239,8 +5239,8 @@ var init_objectWithoutPropertiesLoose = __esm({
|
|
|
5239
5239
|
});
|
|
5240
5240
|
|
|
5241
5241
|
// ../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js
|
|
5242
|
-
function _inheritsLoose(
|
|
5243
|
-
|
|
5242
|
+
function _inheritsLoose(t, o) {
|
|
5243
|
+
t.prototype = Object.create(o.prototype), t.prototype.constructor = t, _setPrototypeOf(t, o);
|
|
5244
5244
|
}
|
|
5245
5245
|
var init_inheritsLoose = __esm({
|
|
5246
5246
|
"../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js"() {
|
|
@@ -5285,7 +5285,7 @@ var init_PropTypes = __esm({
|
|
|
5285
5285
|
var TransitionGroupContext_default;
|
|
5286
5286
|
var init_TransitionGroupContext = __esm({
|
|
5287
5287
|
"../../node_modules/react-transition-group/esm/TransitionGroupContext.js"() {
|
|
5288
|
-
TransitionGroupContext_default =
|
|
5288
|
+
TransitionGroupContext_default = React32__default.createContext(null);
|
|
5289
5289
|
}
|
|
5290
5290
|
});
|
|
5291
5291
|
|
|
@@ -5517,13 +5517,13 @@ var init_Transition = __esm({
|
|
|
5517
5517
|
var _this$props = this.props, children = _this$props.children; _this$props.in; _this$props.mountOnEnter; _this$props.unmountOnExit; _this$props.appear; _this$props.enter; _this$props.exit; _this$props.timeout; _this$props.addEndListener; _this$props.onEnter; _this$props.onEntering; _this$props.onEntered; _this$props.onExit; _this$props.onExiting; _this$props.onExited; _this$props.nodeRef; var childProps = _objectWithoutPropertiesLoose(_this$props, ["children", "in", "mountOnEnter", "unmountOnExit", "appear", "enter", "exit", "timeout", "addEndListener", "onEnter", "onEntering", "onEntered", "onExit", "onExiting", "onExited", "nodeRef"]);
|
|
5518
5518
|
return (
|
|
5519
5519
|
// allows for nested Transitions
|
|
5520
|
-
/* @__PURE__ */
|
|
5520
|
+
/* @__PURE__ */ React32__default.createElement(TransitionGroupContext_default.Provider, {
|
|
5521
5521
|
value: null
|
|
5522
|
-
}, typeof children === "function" ? children(status, childProps) :
|
|
5522
|
+
}, typeof children === "function" ? children(status, childProps) : React32__default.cloneElement(React32__default.Children.only(children), childProps))
|
|
5523
5523
|
);
|
|
5524
5524
|
};
|
|
5525
5525
|
return Transition2;
|
|
5526
|
-
})(
|
|
5526
|
+
})(React32__default.Component);
|
|
5527
5527
|
Transition.contextType = TransitionGroupContext_default;
|
|
5528
5528
|
Transition.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
5529
5529
|
/**
|
|
@@ -6700,10 +6700,10 @@ var require_code = __commonJS({
|
|
|
6700
6700
|
exports.nil = new _Code("");
|
|
6701
6701
|
function _23(strs, ...args) {
|
|
6702
6702
|
const code = [strs[0]];
|
|
6703
|
-
let
|
|
6704
|
-
while (
|
|
6705
|
-
addCodeArg(code, args[
|
|
6706
|
-
code.push(strs[++
|
|
6703
|
+
let i = 0;
|
|
6704
|
+
while (i < args.length) {
|
|
6705
|
+
addCodeArg(code, args[i]);
|
|
6706
|
+
code.push(strs[++i]);
|
|
6707
6707
|
}
|
|
6708
6708
|
return new _Code(code);
|
|
6709
6709
|
}
|
|
@@ -6711,11 +6711,11 @@ var require_code = __commonJS({
|
|
|
6711
6711
|
var plus = new _Code("+");
|
|
6712
6712
|
function str(strs, ...args) {
|
|
6713
6713
|
const expr = [safeStringify(strs[0])];
|
|
6714
|
-
let
|
|
6715
|
-
while (
|
|
6714
|
+
let i = 0;
|
|
6715
|
+
while (i < args.length) {
|
|
6716
6716
|
expr.push(plus);
|
|
6717
|
-
addCodeArg(expr, args[
|
|
6718
|
-
expr.push(plus, safeStringify(strs[++
|
|
6717
|
+
addCodeArg(expr, args[i]);
|
|
6718
|
+
expr.push(plus, safeStringify(strs[++i]));
|
|
6719
6719
|
}
|
|
6720
6720
|
optimize(expr);
|
|
6721
6721
|
return new _Code(expr);
|
|
@@ -6731,17 +6731,17 @@ var require_code = __commonJS({
|
|
|
6731
6731
|
}
|
|
6732
6732
|
exports.addCodeArg = addCodeArg;
|
|
6733
6733
|
function optimize(expr) {
|
|
6734
|
-
let
|
|
6735
|
-
while (
|
|
6736
|
-
if (expr[
|
|
6737
|
-
const res = mergeExprItems(expr[
|
|
6734
|
+
let i = 1;
|
|
6735
|
+
while (i < expr.length - 1) {
|
|
6736
|
+
if (expr[i] === plus) {
|
|
6737
|
+
const res = mergeExprItems(expr[i - 1], expr[i + 1]);
|
|
6738
6738
|
if (res !== void 0) {
|
|
6739
|
-
expr.splice(
|
|
6739
|
+
expr.splice(i - 1, 3, res);
|
|
6740
6740
|
continue;
|
|
6741
6741
|
}
|
|
6742
|
-
expr[
|
|
6742
|
+
expr[i++] = "+";
|
|
6743
6743
|
}
|
|
6744
|
-
|
|
6744
|
+
i++;
|
|
6745
6745
|
}
|
|
6746
6746
|
}
|
|
6747
6747
|
function mergeExprItems(a, b) {
|
|
@@ -7119,27 +7119,27 @@ var require_codegen = __commonJS({
|
|
|
7119
7119
|
}
|
|
7120
7120
|
optimizeNodes() {
|
|
7121
7121
|
const { nodes } = this;
|
|
7122
|
-
let
|
|
7123
|
-
while (
|
|
7124
|
-
const n = nodes[
|
|
7122
|
+
let i = nodes.length;
|
|
7123
|
+
while (i--) {
|
|
7124
|
+
const n = nodes[i].optimizeNodes();
|
|
7125
7125
|
if (Array.isArray(n))
|
|
7126
|
-
nodes.splice(
|
|
7126
|
+
nodes.splice(i, 1, ...n);
|
|
7127
7127
|
else if (n)
|
|
7128
|
-
nodes[
|
|
7128
|
+
nodes[i] = n;
|
|
7129
7129
|
else
|
|
7130
|
-
nodes.splice(
|
|
7130
|
+
nodes.splice(i, 1);
|
|
7131
7131
|
}
|
|
7132
7132
|
return nodes.length > 0 ? this : void 0;
|
|
7133
7133
|
}
|
|
7134
7134
|
optimizeNames(names, constants) {
|
|
7135
7135
|
const { nodes } = this;
|
|
7136
|
-
let
|
|
7137
|
-
while (
|
|
7138
|
-
const n = nodes[
|
|
7136
|
+
let i = nodes.length;
|
|
7137
|
+
while (i--) {
|
|
7138
|
+
const n = nodes[i];
|
|
7139
7139
|
if (n.optimizeNames(names, constants))
|
|
7140
7140
|
continue;
|
|
7141
7141
|
subtractNames(names, n.names);
|
|
7142
|
-
nodes.splice(
|
|
7142
|
+
nodes.splice(i, 1);
|
|
7143
7143
|
}
|
|
7144
7144
|
return nodes.length > 0 ? this : void 0;
|
|
7145
7145
|
}
|
|
@@ -7173,17 +7173,17 @@ var require_codegen = __commonJS({
|
|
|
7173
7173
|
const cond = this.condition;
|
|
7174
7174
|
if (cond === true)
|
|
7175
7175
|
return this.nodes;
|
|
7176
|
-
let
|
|
7177
|
-
if (
|
|
7178
|
-
const ns =
|
|
7179
|
-
|
|
7176
|
+
let e = this.else;
|
|
7177
|
+
if (e) {
|
|
7178
|
+
const ns = e.optimizeNodes();
|
|
7179
|
+
e = this.else = Array.isArray(ns) ? new Else(ns) : ns;
|
|
7180
7180
|
}
|
|
7181
|
-
if (
|
|
7181
|
+
if (e) {
|
|
7182
7182
|
if (cond === false)
|
|
7183
|
-
return
|
|
7183
|
+
return e instanceof _If ? e : e.nodes;
|
|
7184
7184
|
if (this.nodes.length)
|
|
7185
7185
|
return this;
|
|
7186
|
-
return new _If(not(cond),
|
|
7186
|
+
return new _If(not(cond), e instanceof _If ? [e] : e.nodes);
|
|
7187
7187
|
}
|
|
7188
7188
|
if (cond === false || !this.nodes.length)
|
|
7189
7189
|
return void 0;
|
|
@@ -7466,8 +7466,8 @@ var require_codegen = __commonJS({
|
|
|
7466
7466
|
const name = this._scope.toName(nameOrPrefix);
|
|
7467
7467
|
if (this.opts.es5) {
|
|
7468
7468
|
const arr2 = iterable instanceof code_1.Name ? iterable : this.var("_arr", iterable);
|
|
7469
|
-
return this.forRange("_i", 0, (0, code_1._)`${arr2}.length`, (
|
|
7470
|
-
this.var(name, (0, code_1._)`${arr2}[${
|
|
7469
|
+
return this.forRange("_i", 0, (0, code_1._)`${arr2}.length`, (i) => {
|
|
7470
|
+
this.var(name, (0, code_1._)`${arr2}[${i}]`);
|
|
7471
7471
|
forBody(name);
|
|
7472
7472
|
});
|
|
7473
7473
|
}
|
|
@@ -7627,8 +7627,8 @@ var require_codegen = __commonJS({
|
|
|
7627
7627
|
delete names[n.str];
|
|
7628
7628
|
return c;
|
|
7629
7629
|
}
|
|
7630
|
-
function canOptimize(
|
|
7631
|
-
return
|
|
7630
|
+
function canOptimize(e) {
|
|
7631
|
+
return e instanceof code_1._Code && e._items.some((c) => c instanceof code_1.Name && names[c.str] === 1 && constants[c.str] !== void 0);
|
|
7632
7632
|
}
|
|
7633
7633
|
}
|
|
7634
7634
|
function subtractNames(names, from) {
|
|
@@ -7906,8 +7906,8 @@ var require_errors = __commonJS({
|
|
|
7906
7906
|
if (errsCount === void 0)
|
|
7907
7907
|
throw new Error("ajv implementation error");
|
|
7908
7908
|
const err = gen.name("err");
|
|
7909
|
-
gen.forRange("i", errsCount, names_1.default.errors, (
|
|
7910
|
-
gen.const(err, (0, codegen_1._)`${names_1.default.vErrors}[${
|
|
7909
|
+
gen.forRange("i", errsCount, names_1.default.errors, (i) => {
|
|
7910
|
+
gen.const(err, (0, codegen_1._)`${names_1.default.vErrors}[${i}]`);
|
|
7911
7911
|
gen.if((0, codegen_1._)`${err}.instancePath === undefined`, () => gen.assign((0, codegen_1._)`${err}.instancePath`, (0, codegen_1.strConcat)(names_1.default.instancePath, it.errorPath)));
|
|
7912
7912
|
gen.assign((0, codegen_1._)`${err}.schemaPath`, (0, codegen_1.str)`${it.errSchemaPath}/${keyword}`);
|
|
7913
7913
|
if (it.opts.verbose) {
|
|
@@ -8141,7 +8141,7 @@ var require_dataType = __commonJS({
|
|
|
8141
8141
|
exports.coerceAndCheckDataType = coerceAndCheckDataType;
|
|
8142
8142
|
var COERCIBLE = /* @__PURE__ */ new Set(["string", "number", "integer", "boolean", "null"]);
|
|
8143
8143
|
function coerceToTypes(types, coerceTypes) {
|
|
8144
|
-
return coerceTypes ? types.filter((
|
|
8144
|
+
return coerceTypes ? types.filter((t) => COERCIBLE.has(t) || coerceTypes === "array" && t === "array") : [];
|
|
8145
8145
|
}
|
|
8146
8146
|
function coerceData(it, types, coerceTo) {
|
|
8147
8147
|
const { gen, data, opts } = it;
|
|
@@ -8151,9 +8151,9 @@ var require_dataType = __commonJS({
|
|
|
8151
8151
|
gen.if((0, codegen_1._)`${dataType} == 'object' && Array.isArray(${data}) && ${data}.length == 1`, () => gen.assign(data, (0, codegen_1._)`${data}[0]`).assign(dataType, (0, codegen_1._)`typeof ${data}`).if(checkDataTypes(types, data, opts.strictNumbers), () => gen.assign(coerced, data)));
|
|
8152
8152
|
}
|
|
8153
8153
|
gen.if((0, codegen_1._)`${coerced} !== undefined`);
|
|
8154
|
-
for (const
|
|
8155
|
-
if (COERCIBLE.has(
|
|
8156
|
-
coerceSpecificType(
|
|
8154
|
+
for (const t of coerceTo) {
|
|
8155
|
+
if (COERCIBLE.has(t) || t === "array" && opts.coerceTypes === "array") {
|
|
8156
|
+
coerceSpecificType(t);
|
|
8157
8157
|
}
|
|
8158
8158
|
}
|
|
8159
8159
|
gen.else();
|
|
@@ -8163,8 +8163,8 @@ var require_dataType = __commonJS({
|
|
|
8163
8163
|
gen.assign(data, coerced);
|
|
8164
8164
|
assignParentData(it, coerced);
|
|
8165
8165
|
});
|
|
8166
|
-
function coerceSpecificType(
|
|
8167
|
-
switch (
|
|
8166
|
+
function coerceSpecificType(t) {
|
|
8167
|
+
switch (t) {
|
|
8168
8168
|
case "string":
|
|
8169
8169
|
gen.elseIf((0, codegen_1._)`${dataType} == "number" || ${dataType} == "boolean"`).assign(coerced, (0, codegen_1._)`"" + ${data}`).elseIf((0, codegen_1._)`${data} === null`).assign(coerced, (0, codegen_1._)`""`);
|
|
8170
8170
|
return;
|
|
@@ -8236,8 +8236,8 @@ var require_dataType = __commonJS({
|
|
|
8236
8236
|
}
|
|
8237
8237
|
if (types.number)
|
|
8238
8238
|
delete types.integer;
|
|
8239
|
-
for (const
|
|
8240
|
-
cond = (0, codegen_1.and)(cond, checkDataType(
|
|
8239
|
+
for (const t in types)
|
|
8240
|
+
cond = (0, codegen_1.and)(cond, checkDataType(t, data, strictNums, correct));
|
|
8241
8241
|
return cond;
|
|
8242
8242
|
}
|
|
8243
8243
|
exports.checkDataTypes = checkDataTypes;
|
|
@@ -8282,7 +8282,7 @@ var require_defaults = __commonJS({
|
|
|
8282
8282
|
assignDefault(it, key, properties[key].default);
|
|
8283
8283
|
}
|
|
8284
8284
|
} else if (ty === "array" && Array.isArray(items)) {
|
|
8285
|
-
items.forEach((sch,
|
|
8285
|
+
items.forEach((sch, i) => assignDefault(it, i, sch.default));
|
|
8286
8286
|
}
|
|
8287
8287
|
}
|
|
8288
8288
|
exports.assignDefaults = assignDefaults;
|
|
@@ -8399,10 +8399,10 @@ var require_code2 = __commonJS({
|
|
|
8399
8399
|
return valid;
|
|
8400
8400
|
function validateItems(notValid) {
|
|
8401
8401
|
const len = gen.const("len", (0, codegen_1._)`${data}.length`);
|
|
8402
|
-
gen.forRange("i", 0, len, (
|
|
8402
|
+
gen.forRange("i", 0, len, (i) => {
|
|
8403
8403
|
cxt.subschema({
|
|
8404
8404
|
keyword,
|
|
8405
|
-
dataProp:
|
|
8405
|
+
dataProp: i,
|
|
8406
8406
|
dataPropType: util_1.Type.Num
|
|
8407
8407
|
}, valid);
|
|
8408
8408
|
gen.if((0, codegen_1.not)(valid), notValid);
|
|
@@ -8419,10 +8419,10 @@ var require_code2 = __commonJS({
|
|
|
8419
8419
|
return;
|
|
8420
8420
|
const valid = gen.let("valid", false);
|
|
8421
8421
|
const schValid = gen.name("_valid");
|
|
8422
|
-
gen.block(() => schema.forEach((_sch,
|
|
8422
|
+
gen.block(() => schema.forEach((_sch, i) => {
|
|
8423
8423
|
const schCxt = cxt.subschema({
|
|
8424
8424
|
keyword,
|
|
8425
|
-
schemaProp:
|
|
8425
|
+
schemaProp: i,
|
|
8426
8426
|
compositeRule: true
|
|
8427
8427
|
}, schValid);
|
|
8428
8428
|
gen.assign(valid, (0, codegen_1._)`${valid} || ${schValid}`);
|
|
@@ -8486,7 +8486,7 @@ var require_keyword = __commonJS({
|
|
|
8486
8486
|
}
|
|
8487
8487
|
function validateAsync() {
|
|
8488
8488
|
const ruleErrs = gen.let("ruleErrs", null);
|
|
8489
|
-
gen.try(() => assignValid((0, codegen_1._)`await `), (
|
|
8489
|
+
gen.try(() => assignValid((0, codegen_1._)`await `), (e) => gen.assign(valid, false).if((0, codegen_1._)`${e} instanceof ${it.ValidationError}`, () => gen.assign(ruleErrs, (0, codegen_1._)`${e}.errors`), () => gen.throw(e)));
|
|
8490
8490
|
return ruleErrs;
|
|
8491
8491
|
}
|
|
8492
8492
|
function validateSync() {
|
|
@@ -8642,12 +8642,12 @@ var require_fast_deep_equal = __commonJS({
|
|
|
8642
8642
|
if (a === b) return true;
|
|
8643
8643
|
if (a && b && typeof a == "object" && typeof b == "object") {
|
|
8644
8644
|
if (a.constructor !== b.constructor) return false;
|
|
8645
|
-
var length,
|
|
8645
|
+
var length, i, keys2;
|
|
8646
8646
|
if (Array.isArray(a)) {
|
|
8647
8647
|
length = a.length;
|
|
8648
8648
|
if (length != b.length) return false;
|
|
8649
|
-
for (
|
|
8650
|
-
if (!equal(a[
|
|
8649
|
+
for (i = length; i-- !== 0; )
|
|
8650
|
+
if (!equal(a[i], b[i])) return false;
|
|
8651
8651
|
return true;
|
|
8652
8652
|
}
|
|
8653
8653
|
if (a.constructor === RegExp) return a.source === b.source && a.flags === b.flags;
|
|
@@ -8656,10 +8656,10 @@ var require_fast_deep_equal = __commonJS({
|
|
|
8656
8656
|
keys2 = Object.keys(a);
|
|
8657
8657
|
length = keys2.length;
|
|
8658
8658
|
if (length !== Object.keys(b).length) return false;
|
|
8659
|
-
for (
|
|
8660
|
-
if (!Object.prototype.hasOwnProperty.call(b, keys2[
|
|
8661
|
-
for (
|
|
8662
|
-
var key = keys2[
|
|
8659
|
+
for (i = length; i-- !== 0; )
|
|
8660
|
+
if (!Object.prototype.hasOwnProperty.call(b, keys2[i])) return false;
|
|
8661
|
+
for (i = length; i-- !== 0; ) {
|
|
8662
|
+
var key = keys2[i];
|
|
8663
8663
|
if (!equal(a[key], b[key])) return false;
|
|
8664
8664
|
}
|
|
8665
8665
|
return true;
|
|
@@ -8735,8 +8735,8 @@ var require_json_schema_traverse = __commonJS({
|
|
|
8735
8735
|
var sch = schema[key];
|
|
8736
8736
|
if (Array.isArray(sch)) {
|
|
8737
8737
|
if (key in traverse.arrayKeywords) {
|
|
8738
|
-
for (var
|
|
8739
|
-
_traverse(opts, pre, post, sch[
|
|
8738
|
+
for (var i = 0; i < sch.length; i++)
|
|
8739
|
+
_traverse(opts, pre, post, sch[i], jsonPtr + "/" + key + "/" + i, rootSchema, jsonPtr, key, schema, i);
|
|
8740
8740
|
}
|
|
8741
8741
|
} else if (key in traverse.propsKeywords) {
|
|
8742
8742
|
if (sch && typeof sch == "object") {
|
|
@@ -9144,9 +9144,9 @@ var require_validate = __commonJS({
|
|
|
9144
9144
|
it.dataTypes = types;
|
|
9145
9145
|
return;
|
|
9146
9146
|
}
|
|
9147
|
-
types.forEach((
|
|
9148
|
-
if (!includesType(it.dataTypes,
|
|
9149
|
-
strictTypesError(it, `type "${
|
|
9147
|
+
types.forEach((t) => {
|
|
9148
|
+
if (!includesType(it.dataTypes, t)) {
|
|
9149
|
+
strictTypesError(it, `type "${t}" not allowed by context "${it.dataTypes.join(",")}"`);
|
|
9150
9150
|
}
|
|
9151
9151
|
});
|
|
9152
9152
|
narrowSchemaTypes(it, types);
|
|
@@ -9162,7 +9162,7 @@ var require_validate = __commonJS({
|
|
|
9162
9162
|
const rule = rules[keyword];
|
|
9163
9163
|
if (typeof rule == "object" && (0, applicability_1.shouldUseRule)(it.schema, rule)) {
|
|
9164
9164
|
const { type } = rule.definition;
|
|
9165
|
-
if (type.length && !type.some((
|
|
9165
|
+
if (type.length && !type.some((t) => hasApplicableType(ts, t))) {
|
|
9166
9166
|
strictTypesError(it, `missing type "${type.join(",")}" for keyword "${keyword}"`);
|
|
9167
9167
|
}
|
|
9168
9168
|
}
|
|
@@ -9171,15 +9171,15 @@ var require_validate = __commonJS({
|
|
|
9171
9171
|
function hasApplicableType(schTs, kwdT) {
|
|
9172
9172
|
return schTs.includes(kwdT) || kwdT === "number" && schTs.includes("integer");
|
|
9173
9173
|
}
|
|
9174
|
-
function includesType(ts,
|
|
9175
|
-
return ts.includes(
|
|
9174
|
+
function includesType(ts, t) {
|
|
9175
|
+
return ts.includes(t) || t === "integer" && ts.includes("number");
|
|
9176
9176
|
}
|
|
9177
9177
|
function narrowSchemaTypes(it, withTypes) {
|
|
9178
9178
|
const ts = [];
|
|
9179
|
-
for (const
|
|
9180
|
-
if (includesType(withTypes,
|
|
9181
|
-
ts.push(
|
|
9182
|
-
else if (withTypes.includes("integer") &&
|
|
9179
|
+
for (const t of it.dataTypes) {
|
|
9180
|
+
if (includesType(withTypes, t))
|
|
9181
|
+
ts.push(t);
|
|
9182
|
+
else if (withTypes.includes("integer") && t === "number")
|
|
9183
9183
|
ts.push("integer");
|
|
9184
9184
|
}
|
|
9185
9185
|
it.dataTypes = ts;
|
|
@@ -9554,12 +9554,12 @@ var require_compile = __commonJS({
|
|
|
9554
9554
|
}
|
|
9555
9555
|
sch.validate = validate2;
|
|
9556
9556
|
return sch;
|
|
9557
|
-
} catch (
|
|
9557
|
+
} catch (e) {
|
|
9558
9558
|
delete sch.validate;
|
|
9559
9559
|
delete sch.validateName;
|
|
9560
9560
|
if (sourceCode)
|
|
9561
9561
|
this.logger.error("Error compiling schema, function code:", sourceCode);
|
|
9562
|
-
throw
|
|
9562
|
+
throw e;
|
|
9563
9563
|
} finally {
|
|
9564
9564
|
this._compilations.delete(sch);
|
|
9565
9565
|
}
|
|
@@ -9698,24 +9698,24 @@ var require_utils = __commonJS({
|
|
|
9698
9698
|
function stringArrayToHexStripped(input) {
|
|
9699
9699
|
let acc = "";
|
|
9700
9700
|
let code = 0;
|
|
9701
|
-
let
|
|
9702
|
-
for (
|
|
9703
|
-
code = input[
|
|
9701
|
+
let i = 0;
|
|
9702
|
+
for (i = 0; i < input.length; i++) {
|
|
9703
|
+
code = input[i].charCodeAt(0);
|
|
9704
9704
|
if (code === 48) {
|
|
9705
9705
|
continue;
|
|
9706
9706
|
}
|
|
9707
9707
|
if (!(code >= 48 && code <= 57 || code >= 65 && code <= 70 || code >= 97 && code <= 102)) {
|
|
9708
9708
|
return "";
|
|
9709
9709
|
}
|
|
9710
|
-
acc += input[
|
|
9710
|
+
acc += input[i];
|
|
9711
9711
|
break;
|
|
9712
9712
|
}
|
|
9713
|
-
for (
|
|
9714
|
-
code = input[
|
|
9713
|
+
for (i += 1; i < input.length; i++) {
|
|
9714
|
+
code = input[i].charCodeAt(0);
|
|
9715
9715
|
if (!(code >= 48 && code <= 57 || code >= 65 && code <= 70 || code >= 97 && code <= 102)) {
|
|
9716
9716
|
return "";
|
|
9717
9717
|
}
|
|
9718
|
-
acc += input[
|
|
9718
|
+
acc += input[i];
|
|
9719
9719
|
}
|
|
9720
9720
|
return acc;
|
|
9721
9721
|
}
|
|
@@ -9745,8 +9745,8 @@ var require_utils = __commonJS({
|
|
|
9745
9745
|
let endipv6Encountered = false;
|
|
9746
9746
|
let endIpv6 = false;
|
|
9747
9747
|
let consume = consumeHextets;
|
|
9748
|
-
for (let
|
|
9749
|
-
const cursor = input[
|
|
9748
|
+
for (let i = 0; i < input.length; i++) {
|
|
9749
|
+
const cursor = input[i];
|
|
9750
9750
|
if (cursor === "[" || cursor === "]") {
|
|
9751
9751
|
continue;
|
|
9752
9752
|
}
|
|
@@ -9761,7 +9761,7 @@ var require_utils = __commonJS({
|
|
|
9761
9761
|
output2.error = true;
|
|
9762
9762
|
break;
|
|
9763
9763
|
}
|
|
9764
|
-
if (
|
|
9764
|
+
if (i > 0 && input[i - 1] === ":") {
|
|
9765
9765
|
endipv6Encountered = true;
|
|
9766
9766
|
}
|
|
9767
9767
|
address.push(":");
|
|
@@ -9807,8 +9807,8 @@ var require_utils = __commonJS({
|
|
|
9807
9807
|
}
|
|
9808
9808
|
function findToken(str, token) {
|
|
9809
9809
|
let ind = 0;
|
|
9810
|
-
for (let
|
|
9811
|
-
if (str[
|
|
9810
|
+
for (let i = 0; i < str.length; i++) {
|
|
9811
|
+
if (str[i] === token) ind++;
|
|
9812
9812
|
}
|
|
9813
9813
|
return ind;
|
|
9814
9814
|
}
|
|
@@ -10365,8 +10365,8 @@ var require_fast_uri = __commonJS({
|
|
|
10365
10365
|
if (parsed.host && (options.domainHost || schemeHandler && schemeHandler.domainHost) && isIP === false && nonSimpleDomain(parsed.host)) {
|
|
10366
10366
|
try {
|
|
10367
10367
|
parsed.host = URL.domainToASCII(parsed.host.toLowerCase());
|
|
10368
|
-
} catch (
|
|
10369
|
-
parsed.error = parsed.error || "Host's domain name can not be converted to ASCII: " +
|
|
10368
|
+
} catch (e) {
|
|
10369
|
+
parsed.error = parsed.error || "Host's domain name can not be converted to ASCII: " + e;
|
|
10370
10370
|
}
|
|
10371
10371
|
}
|
|
10372
10372
|
}
|
|
@@ -10610,11 +10610,11 @@ var require_core = __commonJS({
|
|
|
10610
10610
|
async function _compileAsync(sch) {
|
|
10611
10611
|
try {
|
|
10612
10612
|
return this._compileSchemaEnv(sch);
|
|
10613
|
-
} catch (
|
|
10614
|
-
if (!(
|
|
10615
|
-
throw
|
|
10616
|
-
checkLoaded.call(this,
|
|
10617
|
-
await loadMissingSchema.call(this,
|
|
10613
|
+
} catch (e) {
|
|
10614
|
+
if (!(e instanceof ref_error_1.default))
|
|
10615
|
+
throw e;
|
|
10616
|
+
checkLoaded.call(this, e);
|
|
10617
|
+
await loadMissingSchema.call(this, e.missingSchema);
|
|
10618
10618
|
return _compileAsync.call(this, sch);
|
|
10619
10619
|
}
|
|
10620
10620
|
}
|
|
@@ -10781,7 +10781,7 @@ var require_core = __commonJS({
|
|
|
10781
10781
|
type: (0, dataType_1.getJSONTypes)(def.type),
|
|
10782
10782
|
schemaType: (0, dataType_1.getJSONTypes)(def.schemaType)
|
|
10783
10783
|
};
|
|
10784
|
-
(0, util_1.eachItem)(keyword, definition.type.length === 0 ? (k) => addRule.call(this, k, definition) : (k) => definition.type.forEach((
|
|
10784
|
+
(0, util_1.eachItem)(keyword, definition.type.length === 0 ? (k) => addRule.call(this, k, definition) : (k) => definition.type.forEach((t) => addRule.call(this, k, definition, t)));
|
|
10785
10785
|
return this;
|
|
10786
10786
|
}
|
|
10787
10787
|
getKeyword(keyword) {
|
|
@@ -10794,9 +10794,9 @@ var require_core = __commonJS({
|
|
|
10794
10794
|
delete RULES.keywords[keyword];
|
|
10795
10795
|
delete RULES.all[keyword];
|
|
10796
10796
|
for (const group of RULES.rules) {
|
|
10797
|
-
const
|
|
10798
|
-
if (
|
|
10799
|
-
group.rules.splice(
|
|
10797
|
+
const i = group.rules.findIndex((rule) => rule.keyword === keyword);
|
|
10798
|
+
if (i >= 0)
|
|
10799
|
+
group.rules.splice(i, 1);
|
|
10800
10800
|
}
|
|
10801
10801
|
return this;
|
|
10802
10802
|
}
|
|
@@ -10810,7 +10810,7 @@ var require_core = __commonJS({
|
|
|
10810
10810
|
errorsText(errors = this.errors, { separator = ", ", dataVar = "data" } = {}) {
|
|
10811
10811
|
if (!errors || errors.length === 0)
|
|
10812
10812
|
return "No errors";
|
|
10813
|
-
return errors.map((
|
|
10813
|
+
return errors.map((e) => `${dataVar}${e.instancePath} ${e.message}`).reduce((text, msg) => text + separator + msg);
|
|
10814
10814
|
}
|
|
10815
10815
|
$dataMetaSchema(metaSchema, keywordsJsonPointers) {
|
|
10816
10816
|
const rules = this.RULES.all;
|
|
@@ -10980,7 +10980,7 @@ var require_core = __commonJS({
|
|
|
10980
10980
|
if (dataType && post)
|
|
10981
10981
|
throw new Error('keyword with "post" flag cannot have "type"');
|
|
10982
10982
|
const { RULES } = this;
|
|
10983
|
-
let ruleGroup = post ? RULES.post : RULES.rules.find(({ type:
|
|
10983
|
+
let ruleGroup = post ? RULES.post : RULES.rules.find(({ type: t }) => t === dataType);
|
|
10984
10984
|
if (!ruleGroup) {
|
|
10985
10985
|
ruleGroup = { type: dataType, rules: [] };
|
|
10986
10986
|
RULES.rules.push(ruleGroup);
|
|
@@ -11004,9 +11004,9 @@ var require_core = __commonJS({
|
|
|
11004
11004
|
(_a = definition.implements) === null || _a === void 0 ? void 0 : _a.forEach((kwd) => this.addKeyword(kwd));
|
|
11005
11005
|
}
|
|
11006
11006
|
function addBeforeRule(ruleGroup, rule, before) {
|
|
11007
|
-
const
|
|
11008
|
-
if (
|
|
11009
|
-
ruleGroup.rules.splice(
|
|
11007
|
+
const i = ruleGroup.rules.findIndex((_rule) => _rule.keyword === before);
|
|
11008
|
+
if (i >= 0) {
|
|
11009
|
+
ruleGroup.rules.splice(i, 0, rule);
|
|
11010
11010
|
} else {
|
|
11011
11011
|
ruleGroup.rules.push(rule);
|
|
11012
11012
|
this.logger.warn(`rule ${before} is not defined`);
|
|
@@ -11116,9 +11116,9 @@ var require_ref = __commonJS({
|
|
|
11116
11116
|
addEvaluatedFrom(v);
|
|
11117
11117
|
if (!allErrors)
|
|
11118
11118
|
gen.assign(valid, true);
|
|
11119
|
-
}, (
|
|
11120
|
-
gen.if((0, codegen_1._)`!(${
|
|
11121
|
-
addErrorsFrom(
|
|
11119
|
+
}, (e) => {
|
|
11120
|
+
gen.if((0, codegen_1._)`!(${e} instanceof ${it.ValidationError})`, () => gen.throw(e));
|
|
11121
|
+
addErrorsFrom(e);
|
|
11122
11122
|
if (!allErrors)
|
|
11123
11123
|
gen.assign(valid, false);
|
|
11124
11124
|
});
|
|
@@ -11481,8 +11481,8 @@ var require_uniqueItems = __commonJS({
|
|
|
11481
11481
|
var util_1 = require_util();
|
|
11482
11482
|
var equal_1 = require_equal();
|
|
11483
11483
|
var error2 = {
|
|
11484
|
-
message: ({ params: { i
|
|
11485
|
-
params: ({ params: { i
|
|
11484
|
+
message: ({ params: { i, j } }) => (0, codegen_1.str)`must NOT have duplicate items (items ## ${j} and ${i} are identical)`,
|
|
11485
|
+
params: ({ params: { i, j } }) => (0, codegen_1._)`{i: ${i}, j: ${j}}`
|
|
11486
11486
|
};
|
|
11487
11487
|
var def = {
|
|
11488
11488
|
keyword: "uniqueItems",
|
|
@@ -11499,21 +11499,21 @@ var require_uniqueItems = __commonJS({
|
|
|
11499
11499
|
cxt.block$data(valid, validateUniqueItems, (0, codegen_1._)`${schemaCode} === false`);
|
|
11500
11500
|
cxt.ok(valid);
|
|
11501
11501
|
function validateUniqueItems() {
|
|
11502
|
-
const
|
|
11502
|
+
const i = gen.let("i", (0, codegen_1._)`${data}.length`);
|
|
11503
11503
|
const j = gen.let("j");
|
|
11504
|
-
cxt.setParams({ i
|
|
11504
|
+
cxt.setParams({ i, j });
|
|
11505
11505
|
gen.assign(valid, true);
|
|
11506
|
-
gen.if((0, codegen_1._)`${
|
|
11506
|
+
gen.if((0, codegen_1._)`${i} > 1`, () => (canOptimize() ? loopN : loopN2)(i, j));
|
|
11507
11507
|
}
|
|
11508
11508
|
function canOptimize() {
|
|
11509
|
-
return itemTypes.length > 0 && !itemTypes.some((
|
|
11509
|
+
return itemTypes.length > 0 && !itemTypes.some((t) => t === "object" || t === "array");
|
|
11510
11510
|
}
|
|
11511
|
-
function loopN(
|
|
11511
|
+
function loopN(i, j) {
|
|
11512
11512
|
const item = gen.name("item");
|
|
11513
11513
|
const wrongType = (0, dataType_1.checkDataTypes)(itemTypes, item, it.opts.strictNumbers, dataType_1.DataType.Wrong);
|
|
11514
11514
|
const indices = gen.const("indices", (0, codegen_1._)`{}`);
|
|
11515
|
-
gen.for((0, codegen_1._)`;${
|
|
11516
|
-
gen.let(item, (0, codegen_1._)`${data}[${
|
|
11515
|
+
gen.for((0, codegen_1._)`;${i}--;`, () => {
|
|
11516
|
+
gen.let(item, (0, codegen_1._)`${data}[${i}]`);
|
|
11517
11517
|
gen.if(wrongType, (0, codegen_1._)`continue`);
|
|
11518
11518
|
if (itemTypes.length > 1)
|
|
11519
11519
|
gen.if((0, codegen_1._)`typeof ${item} == "string"`, (0, codegen_1._)`${item} += "_"`);
|
|
@@ -11521,13 +11521,13 @@ var require_uniqueItems = __commonJS({
|
|
|
11521
11521
|
gen.assign(j, (0, codegen_1._)`${indices}[${item}]`);
|
|
11522
11522
|
cxt.error();
|
|
11523
11523
|
gen.assign(valid, false).break();
|
|
11524
|
-
}).code((0, codegen_1._)`${indices}[${item}] = ${
|
|
11524
|
+
}).code((0, codegen_1._)`${indices}[${item}] = ${i}`);
|
|
11525
11525
|
});
|
|
11526
11526
|
}
|
|
11527
|
-
function loopN2(
|
|
11527
|
+
function loopN2(i, j) {
|
|
11528
11528
|
const eql = (0, util_1.useFunc)(gen, equal_1.default);
|
|
11529
11529
|
const outer = gen.name("outer");
|
|
11530
|
-
gen.label(outer).for((0, codegen_1._)`;${
|
|
11530
|
+
gen.label(outer).for((0, codegen_1._)`;${i}--;`, () => gen.for((0, codegen_1._)`${j} = ${i}; ${j}--;`, () => gen.if((0, codegen_1._)`${eql}(${data}[${i}], ${data}[${j}])`, () => {
|
|
11531
11531
|
cxt.error();
|
|
11532
11532
|
gen.assign(valid, false).break(outer);
|
|
11533
11533
|
})));
|
|
@@ -11597,16 +11597,16 @@ var require_enum = __commonJS({
|
|
|
11597
11597
|
if (!Array.isArray(schema))
|
|
11598
11598
|
throw new Error("ajv implementation error");
|
|
11599
11599
|
const vSchema = gen.const("vSchema", schemaCode);
|
|
11600
|
-
valid = (0, codegen_1.or)(...schema.map((_x,
|
|
11600
|
+
valid = (0, codegen_1.or)(...schema.map((_x, i) => equalCode(vSchema, i)));
|
|
11601
11601
|
}
|
|
11602
11602
|
cxt.pass(valid);
|
|
11603
11603
|
function loopEnum() {
|
|
11604
11604
|
gen.assign(valid, false);
|
|
11605
11605
|
gen.forOf("v", schemaCode, (v) => gen.if((0, codegen_1._)`${getEql()}(${data}, ${v})`, () => gen.assign(valid, true).break()));
|
|
11606
11606
|
}
|
|
11607
|
-
function equalCode(vSchema,
|
|
11608
|
-
const sch = schema[
|
|
11609
|
-
return typeof sch === "object" && sch !== null ? (0, codegen_1._)`${getEql()}(${data}, ${vSchema}[${
|
|
11607
|
+
function equalCode(vSchema, i) {
|
|
11608
|
+
const sch = schema[i];
|
|
11609
|
+
return typeof sch === "object" && sch !== null ? (0, codegen_1._)`${getEql()}(${data}, ${vSchema}[${i}])` : (0, codegen_1._)`${data} === ${sch}`;
|
|
11610
11610
|
}
|
|
11611
11611
|
}
|
|
11612
11612
|
};
|
|
@@ -11691,8 +11691,8 @@ var require_additionalItems = __commonJS({
|
|
|
11691
11691
|
cxt.ok(valid);
|
|
11692
11692
|
}
|
|
11693
11693
|
function validateItems(valid) {
|
|
11694
|
-
gen.forRange("i", items.length, len, (
|
|
11695
|
-
cxt.subschema({ keyword, dataProp:
|
|
11694
|
+
gen.forRange("i", items.length, len, (i) => {
|
|
11695
|
+
cxt.subschema({ keyword, dataProp: i, dataPropType: util_1.Type.Num }, valid);
|
|
11696
11696
|
if (!it.allErrors)
|
|
11697
11697
|
gen.if((0, codegen_1.not)(valid), () => gen.break());
|
|
11698
11698
|
});
|
|
@@ -11734,13 +11734,13 @@ var require_items = __commonJS({
|
|
|
11734
11734
|
}
|
|
11735
11735
|
const valid = gen.name("valid");
|
|
11736
11736
|
const len = gen.const("len", (0, codegen_1._)`${data}.length`);
|
|
11737
|
-
schArr.forEach((sch,
|
|
11737
|
+
schArr.forEach((sch, i) => {
|
|
11738
11738
|
if ((0, util_1.alwaysValidSchema)(it, sch))
|
|
11739
11739
|
return;
|
|
11740
|
-
gen.if((0, codegen_1._)`${len} > ${
|
|
11740
|
+
gen.if((0, codegen_1._)`${len} > ${i}`, () => cxt.subschema({
|
|
11741
11741
|
keyword,
|
|
11742
|
-
schemaProp:
|
|
11743
|
-
dataProp:
|
|
11742
|
+
schemaProp: i,
|
|
11743
|
+
dataProp: i
|
|
11744
11744
|
}, valid));
|
|
11745
11745
|
cxt.ok(valid);
|
|
11746
11746
|
});
|
|
@@ -11874,10 +11874,10 @@ var require_contains = __commonJS({
|
|
|
11874
11874
|
validateItems(schValid, () => gen.if(schValid, () => checkLimits(count)));
|
|
11875
11875
|
}
|
|
11876
11876
|
function validateItems(_valid, block) {
|
|
11877
|
-
gen.forRange("i", 0, len, (
|
|
11877
|
+
gen.forRange("i", 0, len, (i) => {
|
|
11878
11878
|
cxt.subschema({
|
|
11879
11879
|
keyword: "contains",
|
|
11880
|
-
dataProp:
|
|
11880
|
+
dataProp: i,
|
|
11881
11881
|
dataPropType: util_1.Type.Num,
|
|
11882
11882
|
compositeRule: true
|
|
11883
11883
|
}, _valid);
|
|
@@ -12347,23 +12347,23 @@ var require_oneOf = __commonJS({
|
|
|
12347
12347
|
gen.block(validateOneOf);
|
|
12348
12348
|
cxt.result(valid, () => cxt.reset(), () => cxt.error(true));
|
|
12349
12349
|
function validateOneOf() {
|
|
12350
|
-
schArr.forEach((sch,
|
|
12350
|
+
schArr.forEach((sch, i) => {
|
|
12351
12351
|
let schCxt;
|
|
12352
12352
|
if ((0, util_1.alwaysValidSchema)(it, sch)) {
|
|
12353
12353
|
gen.var(schValid, true);
|
|
12354
12354
|
} else {
|
|
12355
12355
|
schCxt = cxt.subschema({
|
|
12356
12356
|
keyword: "oneOf",
|
|
12357
|
-
schemaProp:
|
|
12357
|
+
schemaProp: i,
|
|
12358
12358
|
compositeRule: true
|
|
12359
12359
|
}, schValid);
|
|
12360
12360
|
}
|
|
12361
|
-
if (
|
|
12362
|
-
gen.if((0, codegen_1._)`${schValid} && ${valid}`).assign(valid, false).assign(passing, (0, codegen_1._)`[${passing}, ${
|
|
12361
|
+
if (i > 0) {
|
|
12362
|
+
gen.if((0, codegen_1._)`${schValid} && ${valid}`).assign(valid, false).assign(passing, (0, codegen_1._)`[${passing}, ${i}]`).else();
|
|
12363
12363
|
}
|
|
12364
12364
|
gen.if(schValid, () => {
|
|
12365
12365
|
gen.assign(valid, true);
|
|
12366
|
-
gen.assign(passing,
|
|
12366
|
+
gen.assign(passing, i);
|
|
12367
12367
|
if (schCxt)
|
|
12368
12368
|
cxt.mergeEvaluated(schCxt, codegen_1.Name);
|
|
12369
12369
|
});
|
|
@@ -12388,10 +12388,10 @@ var require_allOf = __commonJS({
|
|
|
12388
12388
|
if (!Array.isArray(schema))
|
|
12389
12389
|
throw new Error("ajv implementation error");
|
|
12390
12390
|
const valid = gen.name("valid");
|
|
12391
|
-
schema.forEach((sch,
|
|
12391
|
+
schema.forEach((sch, i) => {
|
|
12392
12392
|
if ((0, util_1.alwaysValidSchema)(it, sch))
|
|
12393
12393
|
return;
|
|
12394
|
-
const schCxt = cxt.subschema({ keyword: "allOf", schemaProp:
|
|
12394
|
+
const schCxt = cxt.subschema({ keyword: "allOf", schemaProp: i }, valid);
|
|
12395
12395
|
cxt.ok(valid);
|
|
12396
12396
|
cxt.mergeEvaluated(schCxt);
|
|
12397
12397
|
});
|
|
@@ -12745,8 +12745,8 @@ var require_discriminator = __commonJS({
|
|
|
12745
12745
|
const oneOfMapping = {};
|
|
12746
12746
|
const topRequired = hasRequired(parentSchema);
|
|
12747
12747
|
let tagRequired = true;
|
|
12748
|
-
for (let
|
|
12749
|
-
let sch = oneOf[
|
|
12748
|
+
for (let i = 0; i < oneOf.length; i++) {
|
|
12749
|
+
let sch = oneOf[i];
|
|
12750
12750
|
if ((sch === null || sch === void 0 ? void 0 : sch.$ref) && !(0, util_1.schemaHasRulesButRef)(sch, it.self.RULES)) {
|
|
12751
12751
|
const ref = sch.$ref;
|
|
12752
12752
|
sch = compile_1.resolveRef.call(it.self, it.schemaEnv.root, it.baseId, ref);
|
|
@@ -12760,7 +12760,7 @@ var require_discriminator = __commonJS({
|
|
|
12760
12760
|
throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${tagName}"`);
|
|
12761
12761
|
}
|
|
12762
12762
|
tagRequired = tagRequired && (topRequired || hasRequired(sch));
|
|
12763
|
-
addMappings(propSch,
|
|
12763
|
+
addMappings(propSch, i);
|
|
12764
12764
|
}
|
|
12765
12765
|
if (!tagRequired)
|
|
12766
12766
|
throw new Error(`discriminator: "${tagName}" must be required`);
|
|
@@ -12768,22 +12768,22 @@ var require_discriminator = __commonJS({
|
|
|
12768
12768
|
function hasRequired({ required }) {
|
|
12769
12769
|
return Array.isArray(required) && required.includes(tagName);
|
|
12770
12770
|
}
|
|
12771
|
-
function addMappings(sch,
|
|
12771
|
+
function addMappings(sch, i) {
|
|
12772
12772
|
if (sch.const) {
|
|
12773
|
-
addMapping(sch.const,
|
|
12773
|
+
addMapping(sch.const, i);
|
|
12774
12774
|
} else if (sch.enum) {
|
|
12775
12775
|
for (const tagValue of sch.enum) {
|
|
12776
|
-
addMapping(tagValue,
|
|
12776
|
+
addMapping(tagValue, i);
|
|
12777
12777
|
}
|
|
12778
12778
|
} else {
|
|
12779
12779
|
throw new Error(`discriminator: "properties/${tagName}" must have "const" or "enum"`);
|
|
12780
12780
|
}
|
|
12781
12781
|
}
|
|
12782
|
-
function addMapping(tagValue,
|
|
12782
|
+
function addMapping(tagValue, i) {
|
|
12783
12783
|
if (typeof tagValue != "string" || tagValue in oneOfMapping) {
|
|
12784
12784
|
throw new Error(`discriminator: "${tagName}" values must be unique strings`);
|
|
12785
12785
|
}
|
|
12786
|
-
oneOfMapping[tagValue] =
|
|
12786
|
+
oneOfMapping[tagValue] = i;
|
|
12787
12787
|
}
|
|
12788
12788
|
}
|
|
12789
12789
|
}
|
|
@@ -13230,7 +13230,7 @@ var require_formats = __commonJS({
|
|
|
13230
13230
|
try {
|
|
13231
13231
|
new RegExp(str);
|
|
13232
13232
|
return true;
|
|
13233
|
-
} catch (
|
|
13233
|
+
} catch (e) {
|
|
13234
13234
|
return false;
|
|
13235
13235
|
}
|
|
13236
13236
|
}
|
|
@@ -13879,9 +13879,9 @@ function semver_compare_default(a, b) {
|
|
|
13879
13879
|
b = b.split("-");
|
|
13880
13880
|
var pa = a[0].split(".");
|
|
13881
13881
|
var pb = b[0].split(".");
|
|
13882
|
-
for (var
|
|
13883
|
-
var na = Number(pa[
|
|
13884
|
-
var nb = Number(pb[
|
|
13882
|
+
for (var i = 0; i < 3; i++) {
|
|
13883
|
+
var na = Number(pa[i]);
|
|
13884
|
+
var nb = Number(pb[i]);
|
|
13885
13885
|
if (na > nb) return 1;
|
|
13886
13886
|
if (nb > na) return -1;
|
|
13887
13887
|
if (!isNaN(na) && isNaN(nb)) return 1;
|
|
@@ -13920,28 +13920,28 @@ function _typeof2(o) {
|
|
|
13920
13920
|
function _classCallCheck2(a, n) {
|
|
13921
13921
|
if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function");
|
|
13922
13922
|
}
|
|
13923
|
-
function _defineProperties2(
|
|
13924
|
-
for (var
|
|
13925
|
-
var o = r[
|
|
13926
|
-
o.enumerable = o.enumerable || false, o.configurable = true, "value" in o && (o.writable = true), Object.defineProperty(
|
|
13923
|
+
function _defineProperties2(e, r) {
|
|
13924
|
+
for (var t = 0; t < r.length; t++) {
|
|
13925
|
+
var o = r[t];
|
|
13926
|
+
o.enumerable = o.enumerable || false, o.configurable = true, "value" in o && (o.writable = true), Object.defineProperty(e, _toPropertyKey(o.key), o);
|
|
13927
13927
|
}
|
|
13928
13928
|
}
|
|
13929
|
-
function _createClass2(
|
|
13930
|
-
return r && _defineProperties2(
|
|
13929
|
+
function _createClass2(e, r, t) {
|
|
13930
|
+
return r && _defineProperties2(e.prototype, r), Object.defineProperty(e, "prototype", { writable: false }), e;
|
|
13931
13931
|
}
|
|
13932
|
-
function _toPropertyKey(
|
|
13933
|
-
var
|
|
13934
|
-
return "symbol" == _typeof2(
|
|
13932
|
+
function _toPropertyKey(t) {
|
|
13933
|
+
var i = _toPrimitive(t, "string");
|
|
13934
|
+
return "symbol" == _typeof2(i) ? i : i + "";
|
|
13935
13935
|
}
|
|
13936
|
-
function _toPrimitive(
|
|
13937
|
-
if ("object" != _typeof2(
|
|
13938
|
-
var
|
|
13939
|
-
if (void 0 !==
|
|
13940
|
-
var
|
|
13941
|
-
if ("object" != _typeof2(
|
|
13936
|
+
function _toPrimitive(t, r) {
|
|
13937
|
+
if ("object" != _typeof2(t) || !t) return t;
|
|
13938
|
+
var e = t[Symbol.toPrimitive];
|
|
13939
|
+
if (void 0 !== e) {
|
|
13940
|
+
var i = e.call(t, r);
|
|
13941
|
+
if ("object" != _typeof2(i)) return i;
|
|
13942
13942
|
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
13943
13943
|
}
|
|
13944
|
-
return (String )(
|
|
13944
|
+
return (String )(t);
|
|
13945
13945
|
}
|
|
13946
13946
|
function getType(types, type) {
|
|
13947
13947
|
switch (type) {
|
|
@@ -14547,11 +14547,11 @@ var init_matchesEntirely = __esm({
|
|
|
14547
14547
|
});
|
|
14548
14548
|
|
|
14549
14549
|
// ../../node_modules/libphonenumber-js/es6/helpers/getNumberType.js
|
|
14550
|
-
function _createForOfIteratorHelperLoose2(r,
|
|
14551
|
-
var
|
|
14552
|
-
if (
|
|
14553
|
-
if (Array.isArray(r) || (
|
|
14554
|
-
|
|
14550
|
+
function _createForOfIteratorHelperLoose2(r, e) {
|
|
14551
|
+
var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
|
|
14552
|
+
if (t) return (t = t.call(r)).next.bind(t);
|
|
14553
|
+
if (Array.isArray(r) || (t = _unsupportedIterableToArray2(r)) || e) {
|
|
14554
|
+
t && (r = t);
|
|
14555
14555
|
var o = 0;
|
|
14556
14556
|
return function() {
|
|
14557
14557
|
return o >= r.length ? { done: true } : { done: false, value: r[o++] };
|
|
@@ -14562,13 +14562,13 @@ function _createForOfIteratorHelperLoose2(r, e2) {
|
|
|
14562
14562
|
function _unsupportedIterableToArray2(r, a) {
|
|
14563
14563
|
if (r) {
|
|
14564
14564
|
if ("string" == typeof r) return _arrayLikeToArray2(r, a);
|
|
14565
|
-
var
|
|
14566
|
-
return "Object" ===
|
|
14565
|
+
var t = {}.toString.call(r).slice(8, -1);
|
|
14566
|
+
return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray2(r, a) : void 0;
|
|
14567
14567
|
}
|
|
14568
14568
|
}
|
|
14569
14569
|
function _arrayLikeToArray2(r, a) {
|
|
14570
14570
|
(null == a || a > r.length) && (a = r.length);
|
|
14571
|
-
for (var
|
|
14571
|
+
for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
|
|
14572
14572
|
return n;
|
|
14573
14573
|
}
|
|
14574
14574
|
function getNumberType(input, options, metadata) {
|
|
@@ -14875,18 +14875,18 @@ function extractCountryCallingCode(number, country, callingCode, metadata) {
|
|
|
14875
14875
|
return {};
|
|
14876
14876
|
}
|
|
14877
14877
|
metadata = new Metadata(metadata);
|
|
14878
|
-
var
|
|
14879
|
-
while (
|
|
14880
|
-
var _countryCallingCode = number.slice(1,
|
|
14878
|
+
var i = 2;
|
|
14879
|
+
while (i - 1 <= MAX_LENGTH_COUNTRY_CODE && i <= number.length) {
|
|
14880
|
+
var _countryCallingCode = number.slice(1, i);
|
|
14881
14881
|
if (metadata.hasCallingCode(_countryCallingCode)) {
|
|
14882
14882
|
metadata.selectNumberingPlan(_countryCallingCode);
|
|
14883
14883
|
return {
|
|
14884
14884
|
countryCallingCodeSource: isNumberWithIddPrefix ? "FROM_NUMBER_WITH_IDD" : "FROM_NUMBER_WITH_PLUS_SIGN",
|
|
14885
14885
|
countryCallingCode: _countryCallingCode,
|
|
14886
|
-
number: number.slice(
|
|
14886
|
+
number: number.slice(i)
|
|
14887
14887
|
};
|
|
14888
14888
|
}
|
|
14889
|
-
|
|
14889
|
+
i++;
|
|
14890
14890
|
}
|
|
14891
14891
|
return {};
|
|
14892
14892
|
}
|
|
@@ -15043,11 +15043,11 @@ function _typeof3(o) {
|
|
|
15043
15043
|
return o2 && "function" == typeof Symbol && o2.constructor === Symbol && o2 !== Symbol.prototype ? "symbol" : typeof o2;
|
|
15044
15044
|
}, _typeof3(o);
|
|
15045
15045
|
}
|
|
15046
|
-
function _createForOfIteratorHelperLoose3(r,
|
|
15047
|
-
var
|
|
15048
|
-
if (
|
|
15049
|
-
if (Array.isArray(r) || (
|
|
15050
|
-
|
|
15046
|
+
function _createForOfIteratorHelperLoose3(r, e) {
|
|
15047
|
+
var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
|
|
15048
|
+
if (t) return (t = t.call(r)).next.bind(t);
|
|
15049
|
+
if (Array.isArray(r) || (t = _unsupportedIterableToArray3(r)) || e) {
|
|
15050
|
+
t && (r = t);
|
|
15051
15051
|
var o = 0;
|
|
15052
15052
|
return function() {
|
|
15053
15053
|
return o >= r.length ? { done: true } : { done: false, value: r[o++] };
|
|
@@ -15058,52 +15058,52 @@ function _createForOfIteratorHelperLoose3(r, e2) {
|
|
|
15058
15058
|
function _unsupportedIterableToArray3(r, a) {
|
|
15059
15059
|
if (r) {
|
|
15060
15060
|
if ("string" == typeof r) return _arrayLikeToArray3(r, a);
|
|
15061
|
-
var
|
|
15062
|
-
return "Object" ===
|
|
15061
|
+
var t = {}.toString.call(r).slice(8, -1);
|
|
15062
|
+
return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray3(r, a) : void 0;
|
|
15063
15063
|
}
|
|
15064
15064
|
}
|
|
15065
15065
|
function _arrayLikeToArray3(r, a) {
|
|
15066
15066
|
(null == a || a > r.length) && (a = r.length);
|
|
15067
|
-
for (var
|
|
15067
|
+
for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
|
|
15068
15068
|
return n;
|
|
15069
15069
|
}
|
|
15070
|
-
function ownKeys(
|
|
15071
|
-
var
|
|
15070
|
+
function ownKeys(e, r) {
|
|
15071
|
+
var t = Object.keys(e);
|
|
15072
15072
|
if (Object.getOwnPropertySymbols) {
|
|
15073
|
-
var o = Object.getOwnPropertySymbols(
|
|
15073
|
+
var o = Object.getOwnPropertySymbols(e);
|
|
15074
15074
|
r && (o = o.filter(function(r2) {
|
|
15075
|
-
return Object.getOwnPropertyDescriptor(
|
|
15076
|
-
})),
|
|
15075
|
+
return Object.getOwnPropertyDescriptor(e, r2).enumerable;
|
|
15076
|
+
})), t.push.apply(t, o);
|
|
15077
15077
|
}
|
|
15078
|
-
return
|
|
15078
|
+
return t;
|
|
15079
15079
|
}
|
|
15080
|
-
function _objectSpread2(
|
|
15080
|
+
function _objectSpread2(e) {
|
|
15081
15081
|
for (var r = 1; r < arguments.length; r++) {
|
|
15082
|
-
var
|
|
15083
|
-
r % 2 ? ownKeys(Object(
|
|
15084
|
-
_defineProperty2(
|
|
15085
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(
|
|
15086
|
-
Object.defineProperty(
|
|
15082
|
+
var t = null != arguments[r] ? arguments[r] : {};
|
|
15083
|
+
r % 2 ? ownKeys(Object(t), true).forEach(function(r2) {
|
|
15084
|
+
_defineProperty2(e, r2, t[r2]);
|
|
15085
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function(r2) {
|
|
15086
|
+
Object.defineProperty(e, r2, Object.getOwnPropertyDescriptor(t, r2));
|
|
15087
15087
|
});
|
|
15088
15088
|
}
|
|
15089
|
-
return
|
|
15089
|
+
return e;
|
|
15090
15090
|
}
|
|
15091
|
-
function _defineProperty2(
|
|
15092
|
-
return (r = _toPropertyKey2(r)) in
|
|
15091
|
+
function _defineProperty2(e, r, t) {
|
|
15092
|
+
return (r = _toPropertyKey2(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: true, configurable: true, writable: true }) : e[r] = t, e;
|
|
15093
15093
|
}
|
|
15094
|
-
function _toPropertyKey2(
|
|
15095
|
-
var
|
|
15096
|
-
return "symbol" == _typeof3(
|
|
15094
|
+
function _toPropertyKey2(t) {
|
|
15095
|
+
var i = _toPrimitive2(t, "string");
|
|
15096
|
+
return "symbol" == _typeof3(i) ? i : i + "";
|
|
15097
15097
|
}
|
|
15098
|
-
function _toPrimitive2(
|
|
15099
|
-
if ("object" != _typeof3(
|
|
15100
|
-
var
|
|
15101
|
-
if (void 0 !==
|
|
15102
|
-
var
|
|
15103
|
-
if ("object" != _typeof3(
|
|
15098
|
+
function _toPrimitive2(t, r) {
|
|
15099
|
+
if ("object" != _typeof3(t) || !t) return t;
|
|
15100
|
+
var e = t[Symbol.toPrimitive];
|
|
15101
|
+
if (void 0 !== e) {
|
|
15102
|
+
var i = e.call(t, r);
|
|
15103
|
+
if ("object" != _typeof3(i)) return i;
|
|
15104
15104
|
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
15105
15105
|
}
|
|
15106
|
-
return ("string" === r ? String : Number)(
|
|
15106
|
+
return ("string" === r ? String : Number)(t);
|
|
15107
15107
|
}
|
|
15108
15108
|
function formatNumber(input, format, options, metadata) {
|
|
15109
15109
|
if (options) {
|
|
@@ -15223,55 +15223,55 @@ function _typeof4(o) {
|
|
|
15223
15223
|
return o2 && "function" == typeof Symbol && o2.constructor === Symbol && o2 !== Symbol.prototype ? "symbol" : typeof o2;
|
|
15224
15224
|
}, _typeof4(o);
|
|
15225
15225
|
}
|
|
15226
|
-
function ownKeys2(
|
|
15227
|
-
var
|
|
15226
|
+
function ownKeys2(e, r) {
|
|
15227
|
+
var t = Object.keys(e);
|
|
15228
15228
|
if (Object.getOwnPropertySymbols) {
|
|
15229
|
-
var o = Object.getOwnPropertySymbols(
|
|
15229
|
+
var o = Object.getOwnPropertySymbols(e);
|
|
15230
15230
|
r && (o = o.filter(function(r2) {
|
|
15231
|
-
return Object.getOwnPropertyDescriptor(
|
|
15232
|
-
})),
|
|
15231
|
+
return Object.getOwnPropertyDescriptor(e, r2).enumerable;
|
|
15232
|
+
})), t.push.apply(t, o);
|
|
15233
15233
|
}
|
|
15234
|
-
return
|
|
15234
|
+
return t;
|
|
15235
15235
|
}
|
|
15236
|
-
function _objectSpread3(
|
|
15236
|
+
function _objectSpread3(e) {
|
|
15237
15237
|
for (var r = 1; r < arguments.length; r++) {
|
|
15238
|
-
var
|
|
15239
|
-
r % 2 ? ownKeys2(Object(
|
|
15240
|
-
_defineProperty3(
|
|
15241
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(
|
|
15242
|
-
Object.defineProperty(
|
|
15238
|
+
var t = null != arguments[r] ? arguments[r] : {};
|
|
15239
|
+
r % 2 ? ownKeys2(Object(t), true).forEach(function(r2) {
|
|
15240
|
+
_defineProperty3(e, r2, t[r2]);
|
|
15241
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys2(Object(t)).forEach(function(r2) {
|
|
15242
|
+
Object.defineProperty(e, r2, Object.getOwnPropertyDescriptor(t, r2));
|
|
15243
15243
|
});
|
|
15244
15244
|
}
|
|
15245
|
-
return
|
|
15245
|
+
return e;
|
|
15246
15246
|
}
|
|
15247
|
-
function _defineProperty3(
|
|
15248
|
-
return (r = _toPropertyKey3(r)) in
|
|
15247
|
+
function _defineProperty3(e, r, t) {
|
|
15248
|
+
return (r = _toPropertyKey3(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: true, configurable: true, writable: true }) : e[r] = t, e;
|
|
15249
15249
|
}
|
|
15250
15250
|
function _classCallCheck3(a, n) {
|
|
15251
15251
|
if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function");
|
|
15252
15252
|
}
|
|
15253
|
-
function _defineProperties3(
|
|
15254
|
-
for (var
|
|
15255
|
-
var o = r[
|
|
15256
|
-
o.enumerable = o.enumerable || false, o.configurable = true, "value" in o && (o.writable = true), Object.defineProperty(
|
|
15253
|
+
function _defineProperties3(e, r) {
|
|
15254
|
+
for (var t = 0; t < r.length; t++) {
|
|
15255
|
+
var o = r[t];
|
|
15256
|
+
o.enumerable = o.enumerable || false, o.configurable = true, "value" in o && (o.writable = true), Object.defineProperty(e, _toPropertyKey3(o.key), o);
|
|
15257
15257
|
}
|
|
15258
15258
|
}
|
|
15259
|
-
function _createClass3(
|
|
15260
|
-
return r && _defineProperties3(
|
|
15259
|
+
function _createClass3(e, r, t) {
|
|
15260
|
+
return r && _defineProperties3(e.prototype, r), Object.defineProperty(e, "prototype", { writable: false }), e;
|
|
15261
15261
|
}
|
|
15262
|
-
function _toPropertyKey3(
|
|
15263
|
-
var
|
|
15264
|
-
return "symbol" == _typeof4(
|
|
15262
|
+
function _toPropertyKey3(t) {
|
|
15263
|
+
var i = _toPrimitive3(t, "string");
|
|
15264
|
+
return "symbol" == _typeof4(i) ? i : i + "";
|
|
15265
15265
|
}
|
|
15266
|
-
function _toPrimitive3(
|
|
15267
|
-
if ("object" != _typeof4(
|
|
15268
|
-
var
|
|
15269
|
-
if (void 0 !==
|
|
15270
|
-
var
|
|
15271
|
-
if ("object" != _typeof4(
|
|
15266
|
+
function _toPrimitive3(t, r) {
|
|
15267
|
+
if ("object" != _typeof4(t) || !t) return t;
|
|
15268
|
+
var e = t[Symbol.toPrimitive];
|
|
15269
|
+
if (void 0 !== e) {
|
|
15270
|
+
var i = e.call(t, r);
|
|
15271
|
+
if ("object" != _typeof4(i)) return i;
|
|
15272
15272
|
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
15273
15273
|
}
|
|
15274
|
-
return (String )(
|
|
15274
|
+
return (String )(t);
|
|
15275
15275
|
}
|
|
15276
15276
|
function getCountryAndCountryCallingCode(countryOrCountryCallingCode, metadataJson) {
|
|
15277
15277
|
var country;
|
|
@@ -15448,76 +15448,76 @@ function _typeof5(o) {
|
|
|
15448
15448
|
return o2 && "function" == typeof Symbol && o2.constructor === Symbol && o2 !== Symbol.prototype ? "symbol" : typeof o2;
|
|
15449
15449
|
}, _typeof5(o);
|
|
15450
15450
|
}
|
|
15451
|
-
function _createClass4(
|
|
15452
|
-
return Object.defineProperty(
|
|
15451
|
+
function _createClass4(e, r, t) {
|
|
15452
|
+
return Object.defineProperty(e, "prototype", { writable: false }), e;
|
|
15453
15453
|
}
|
|
15454
15454
|
function _classCallCheck4(a, n) {
|
|
15455
15455
|
if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function");
|
|
15456
15456
|
}
|
|
15457
|
-
function _callSuper(
|
|
15458
|
-
return o = _getPrototypeOf2(o), _possibleConstructorReturn2(
|
|
15457
|
+
function _callSuper(t, o, e) {
|
|
15458
|
+
return o = _getPrototypeOf2(o), _possibleConstructorReturn2(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf2(t).constructor) : o.apply(t, e));
|
|
15459
15459
|
}
|
|
15460
|
-
function _possibleConstructorReturn2(
|
|
15461
|
-
if (
|
|
15462
|
-
if (void 0 !==
|
|
15463
|
-
return _assertThisInitialized2(
|
|
15460
|
+
function _possibleConstructorReturn2(t, e) {
|
|
15461
|
+
if (e && ("object" == _typeof5(e) || "function" == typeof e)) return e;
|
|
15462
|
+
if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined");
|
|
15463
|
+
return _assertThisInitialized2(t);
|
|
15464
15464
|
}
|
|
15465
|
-
function _assertThisInitialized2(
|
|
15466
|
-
if (void 0 ===
|
|
15467
|
-
return
|
|
15465
|
+
function _assertThisInitialized2(e) {
|
|
15466
|
+
if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
15467
|
+
return e;
|
|
15468
15468
|
}
|
|
15469
|
-
function _inherits2(
|
|
15470
|
-
if ("function" != typeof
|
|
15471
|
-
|
|
15469
|
+
function _inherits2(t, e) {
|
|
15470
|
+
if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function");
|
|
15471
|
+
t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: true, configurable: true } }), Object.defineProperty(t, "prototype", { writable: false }), e && _setPrototypeOf2(t, e);
|
|
15472
15472
|
}
|
|
15473
|
-
function _wrapNativeSuper(
|
|
15473
|
+
function _wrapNativeSuper(t) {
|
|
15474
15474
|
var r = "function" == typeof Map ? /* @__PURE__ */ new Map() : void 0;
|
|
15475
|
-
return _wrapNativeSuper = function _wrapNativeSuper2(
|
|
15476
|
-
if (null ===
|
|
15477
|
-
if ("function" != typeof
|
|
15475
|
+
return _wrapNativeSuper = function _wrapNativeSuper2(t2) {
|
|
15476
|
+
if (null === t2 || !_isNativeFunction(t2)) return t2;
|
|
15477
|
+
if ("function" != typeof t2) throw new TypeError("Super expression must either be null or a function");
|
|
15478
15478
|
if (void 0 !== r) {
|
|
15479
|
-
if (r.has(
|
|
15480
|
-
r.set(
|
|
15479
|
+
if (r.has(t2)) return r.get(t2);
|
|
15480
|
+
r.set(t2, Wrapper);
|
|
15481
15481
|
}
|
|
15482
15482
|
function Wrapper() {
|
|
15483
|
-
return _construct(
|
|
15483
|
+
return _construct(t2, arguments, _getPrototypeOf2(this).constructor);
|
|
15484
15484
|
}
|
|
15485
|
-
return Wrapper.prototype = Object.create(
|
|
15486
|
-
}, _wrapNativeSuper(
|
|
15485
|
+
return Wrapper.prototype = Object.create(t2.prototype, { constructor: { value: Wrapper, enumerable: false, writable: true, configurable: true } }), _setPrototypeOf2(Wrapper, t2);
|
|
15486
|
+
}, _wrapNativeSuper(t);
|
|
15487
15487
|
}
|
|
15488
|
-
function _construct(
|
|
15488
|
+
function _construct(t, e, r) {
|
|
15489
15489
|
if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments);
|
|
15490
15490
|
var o = [null];
|
|
15491
|
-
o.push.apply(o,
|
|
15492
|
-
var p = new (
|
|
15491
|
+
o.push.apply(o, e);
|
|
15492
|
+
var p = new (t.bind.apply(t, o))();
|
|
15493
15493
|
return r && _setPrototypeOf2(p, r.prototype), p;
|
|
15494
15494
|
}
|
|
15495
15495
|
function _isNativeReflectConstruct() {
|
|
15496
15496
|
try {
|
|
15497
|
-
var
|
|
15497
|
+
var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
15498
15498
|
}));
|
|
15499
|
-
} catch (
|
|
15499
|
+
} catch (t2) {
|
|
15500
15500
|
}
|
|
15501
15501
|
return (_isNativeReflectConstruct = function _isNativeReflectConstruct2() {
|
|
15502
|
-
return !!
|
|
15502
|
+
return !!t;
|
|
15503
15503
|
})();
|
|
15504
15504
|
}
|
|
15505
|
-
function _isNativeFunction(
|
|
15505
|
+
function _isNativeFunction(t) {
|
|
15506
15506
|
try {
|
|
15507
|
-
return -1 !== Function.toString.call(
|
|
15507
|
+
return -1 !== Function.toString.call(t).indexOf("[native code]");
|
|
15508
15508
|
} catch (n) {
|
|
15509
|
-
return "function" == typeof
|
|
15509
|
+
return "function" == typeof t;
|
|
15510
15510
|
}
|
|
15511
15511
|
}
|
|
15512
|
-
function _setPrototypeOf2(
|
|
15513
|
-
return _setPrototypeOf2 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(
|
|
15514
|
-
return
|
|
15515
|
-
}, _setPrototypeOf2(
|
|
15512
|
+
function _setPrototypeOf2(t, e) {
|
|
15513
|
+
return _setPrototypeOf2 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(t2, e2) {
|
|
15514
|
+
return t2.__proto__ = e2, t2;
|
|
15515
|
+
}, _setPrototypeOf2(t, e);
|
|
15516
15516
|
}
|
|
15517
|
-
function _getPrototypeOf2(
|
|
15518
|
-
return _getPrototypeOf2 = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(
|
|
15519
|
-
return
|
|
15520
|
-
}, _getPrototypeOf2(
|
|
15517
|
+
function _getPrototypeOf2(t) {
|
|
15518
|
+
return _getPrototypeOf2 = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(t2) {
|
|
15519
|
+
return t2.__proto__ || Object.getPrototypeOf(t2);
|
|
15520
|
+
}, _getPrototypeOf2(t);
|
|
15521
15521
|
}
|
|
15522
15522
|
var ParseError;
|
|
15523
15523
|
var init_ParseError = __esm({
|
|
@@ -15545,15 +15545,15 @@ function extractExtension(number) {
|
|
|
15545
15545
|
}
|
|
15546
15546
|
var numberWithoutExtension = number.slice(0, start);
|
|
15547
15547
|
var matches = number.match(EXTN_PATTERN);
|
|
15548
|
-
var
|
|
15549
|
-
while (
|
|
15550
|
-
if (matches[
|
|
15548
|
+
var i = 1;
|
|
15549
|
+
while (i < matches.length) {
|
|
15550
|
+
if (matches[i]) {
|
|
15551
15551
|
return {
|
|
15552
15552
|
number: numberWithoutExtension,
|
|
15553
|
-
ext: matches[
|
|
15553
|
+
ext: matches[i]
|
|
15554
15554
|
};
|
|
15555
15555
|
}
|
|
15556
|
-
|
|
15556
|
+
i++;
|
|
15557
15557
|
}
|
|
15558
15558
|
}
|
|
15559
15559
|
var EXTN_PATTERN;
|
|
@@ -15647,11 +15647,11 @@ var init_parseDigits = __esm({
|
|
|
15647
15647
|
});
|
|
15648
15648
|
|
|
15649
15649
|
// ../../node_modules/libphonenumber-js/es6/parseIncompletePhoneNumber.js
|
|
15650
|
-
function _createForOfIteratorHelperLoose4(r,
|
|
15651
|
-
var
|
|
15652
|
-
if (
|
|
15653
|
-
if (Array.isArray(r) || (
|
|
15654
|
-
|
|
15650
|
+
function _createForOfIteratorHelperLoose4(r, e) {
|
|
15651
|
+
var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
|
|
15652
|
+
if (t) return (t = t.call(r)).next.bind(t);
|
|
15653
|
+
if (Array.isArray(r) || (t = _unsupportedIterableToArray4(r)) || e) {
|
|
15654
|
+
t && (r = t);
|
|
15655
15655
|
var o = 0;
|
|
15656
15656
|
return function() {
|
|
15657
15657
|
return o >= r.length ? { done: true } : { done: false, value: r[o++] };
|
|
@@ -15662,13 +15662,13 @@ function _createForOfIteratorHelperLoose4(r, e2) {
|
|
|
15662
15662
|
function _unsupportedIterableToArray4(r, a) {
|
|
15663
15663
|
if (r) {
|
|
15664
15664
|
if ("string" == typeof r) return _arrayLikeToArray4(r, a);
|
|
15665
|
-
var
|
|
15666
|
-
return "Object" ===
|
|
15665
|
+
var t = {}.toString.call(r).slice(8, -1);
|
|
15666
|
+
return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray4(r, a) : void 0;
|
|
15667
15667
|
}
|
|
15668
15668
|
}
|
|
15669
15669
|
function _arrayLikeToArray4(r, a) {
|
|
15670
15670
|
(null == a || a > r.length) && (a = r.length);
|
|
15671
|
-
for (var
|
|
15671
|
+
for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
|
|
15672
15672
|
return n;
|
|
15673
15673
|
}
|
|
15674
15674
|
function parseIncompletePhoneNumber(string) {
|
|
@@ -15695,11 +15695,11 @@ var init_parseIncompletePhoneNumber = __esm({
|
|
|
15695
15695
|
});
|
|
15696
15696
|
|
|
15697
15697
|
// ../../node_modules/libphonenumber-js/es6/helpers/getCountryByNationalNumber.js
|
|
15698
|
-
function _createForOfIteratorHelperLoose5(r,
|
|
15699
|
-
var
|
|
15700
|
-
if (
|
|
15701
|
-
if (Array.isArray(r) || (
|
|
15702
|
-
|
|
15698
|
+
function _createForOfIteratorHelperLoose5(r, e) {
|
|
15699
|
+
var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
|
|
15700
|
+
if (t) return (t = t.call(r)).next.bind(t);
|
|
15701
|
+
if (Array.isArray(r) || (t = _unsupportedIterableToArray5(r)) || e) {
|
|
15702
|
+
t && (r = t);
|
|
15703
15703
|
var o = 0;
|
|
15704
15704
|
return function() {
|
|
15705
15705
|
return o >= r.length ? { done: true } : { done: false, value: r[o++] };
|
|
@@ -15710,13 +15710,13 @@ function _createForOfIteratorHelperLoose5(r, e2) {
|
|
|
15710
15710
|
function _unsupportedIterableToArray5(r, a) {
|
|
15711
15711
|
if (r) {
|
|
15712
15712
|
if ("string" == typeof r) return _arrayLikeToArray5(r, a);
|
|
15713
|
-
var
|
|
15714
|
-
return "Object" ===
|
|
15713
|
+
var t = {}.toString.call(r).slice(8, -1);
|
|
15714
|
+
return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray5(r, a) : void 0;
|
|
15715
15715
|
}
|
|
15716
15716
|
}
|
|
15717
15717
|
function _arrayLikeToArray5(r, a) {
|
|
15718
15718
|
(null == a || a > r.length) && (a = r.length);
|
|
15719
|
-
for (var
|
|
15719
|
+
for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
|
|
15720
15720
|
return n;
|
|
15721
15721
|
}
|
|
15722
15722
|
function getCountryByNationalNumber(nationalPhoneNumber, _ref) {
|
|
@@ -16056,43 +16056,43 @@ function _typeof6(o) {
|
|
|
16056
16056
|
return o2 && "function" == typeof Symbol && o2.constructor === Symbol && o2 !== Symbol.prototype ? "symbol" : typeof o2;
|
|
16057
16057
|
}, _typeof6(o);
|
|
16058
16058
|
}
|
|
16059
|
-
function ownKeys3(
|
|
16060
|
-
var
|
|
16059
|
+
function ownKeys3(e, r) {
|
|
16060
|
+
var t = Object.keys(e);
|
|
16061
16061
|
if (Object.getOwnPropertySymbols) {
|
|
16062
|
-
var o = Object.getOwnPropertySymbols(
|
|
16062
|
+
var o = Object.getOwnPropertySymbols(e);
|
|
16063
16063
|
r && (o = o.filter(function(r2) {
|
|
16064
|
-
return Object.getOwnPropertyDescriptor(
|
|
16065
|
-
})),
|
|
16064
|
+
return Object.getOwnPropertyDescriptor(e, r2).enumerable;
|
|
16065
|
+
})), t.push.apply(t, o);
|
|
16066
16066
|
}
|
|
16067
|
-
return
|
|
16067
|
+
return t;
|
|
16068
16068
|
}
|
|
16069
|
-
function _objectSpread4(
|
|
16069
|
+
function _objectSpread4(e) {
|
|
16070
16070
|
for (var r = 1; r < arguments.length; r++) {
|
|
16071
|
-
var
|
|
16072
|
-
r % 2 ? ownKeys3(Object(
|
|
16073
|
-
_defineProperty4(
|
|
16074
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(
|
|
16075
|
-
Object.defineProperty(
|
|
16071
|
+
var t = null != arguments[r] ? arguments[r] : {};
|
|
16072
|
+
r % 2 ? ownKeys3(Object(t), true).forEach(function(r2) {
|
|
16073
|
+
_defineProperty4(e, r2, t[r2]);
|
|
16074
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys3(Object(t)).forEach(function(r2) {
|
|
16075
|
+
Object.defineProperty(e, r2, Object.getOwnPropertyDescriptor(t, r2));
|
|
16076
16076
|
});
|
|
16077
16077
|
}
|
|
16078
|
-
return
|
|
16078
|
+
return e;
|
|
16079
16079
|
}
|
|
16080
|
-
function _defineProperty4(
|
|
16081
|
-
return (r = _toPropertyKey5(r)) in
|
|
16080
|
+
function _defineProperty4(e, r, t) {
|
|
16081
|
+
return (r = _toPropertyKey5(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: true, configurable: true, writable: true }) : e[r] = t, e;
|
|
16082
16082
|
}
|
|
16083
|
-
function _toPropertyKey5(
|
|
16084
|
-
var
|
|
16085
|
-
return "symbol" == _typeof6(
|
|
16083
|
+
function _toPropertyKey5(t) {
|
|
16084
|
+
var i = _toPrimitive5(t, "string");
|
|
16085
|
+
return "symbol" == _typeof6(i) ? i : i + "";
|
|
16086
16086
|
}
|
|
16087
|
-
function _toPrimitive5(
|
|
16088
|
-
if ("object" != _typeof6(
|
|
16089
|
-
var
|
|
16090
|
-
if (void 0 !==
|
|
16091
|
-
var
|
|
16092
|
-
if ("object" != _typeof6(
|
|
16087
|
+
function _toPrimitive5(t, r) {
|
|
16088
|
+
if ("object" != _typeof6(t) || !t) return t;
|
|
16089
|
+
var e = t[Symbol.toPrimitive];
|
|
16090
|
+
if (void 0 !== e) {
|
|
16091
|
+
var i = e.call(t, r);
|
|
16092
|
+
if ("object" != _typeof6(i)) return i;
|
|
16093
16093
|
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
16094
16094
|
}
|
|
16095
|
-
return ("string" === r ? String : Number)(
|
|
16095
|
+
return ("string" === r ? String : Number)(t);
|
|
16096
16096
|
}
|
|
16097
16097
|
function parsePhoneNumberWithError(text, options, metadata) {
|
|
16098
16098
|
return parse2(text, _objectSpread4(_objectSpread4({}, options), {}, {
|
|
@@ -16114,46 +16114,46 @@ function _typeof7(o) {
|
|
|
16114
16114
|
return o2 && "function" == typeof Symbol && o2.constructor === Symbol && o2 !== Symbol.prototype ? "symbol" : typeof o2;
|
|
16115
16115
|
}, _typeof7(o);
|
|
16116
16116
|
}
|
|
16117
|
-
function ownKeys4(
|
|
16118
|
-
var
|
|
16117
|
+
function ownKeys4(e, r) {
|
|
16118
|
+
var t = Object.keys(e);
|
|
16119
16119
|
if (Object.getOwnPropertySymbols) {
|
|
16120
|
-
var o = Object.getOwnPropertySymbols(
|
|
16120
|
+
var o = Object.getOwnPropertySymbols(e);
|
|
16121
16121
|
r && (o = o.filter(function(r2) {
|
|
16122
|
-
return Object.getOwnPropertyDescriptor(
|
|
16123
|
-
})),
|
|
16122
|
+
return Object.getOwnPropertyDescriptor(e, r2).enumerable;
|
|
16123
|
+
})), t.push.apply(t, o);
|
|
16124
16124
|
}
|
|
16125
|
-
return
|
|
16125
|
+
return t;
|
|
16126
16126
|
}
|
|
16127
|
-
function _objectSpread5(
|
|
16127
|
+
function _objectSpread5(e) {
|
|
16128
16128
|
for (var r = 1; r < arguments.length; r++) {
|
|
16129
|
-
var
|
|
16130
|
-
r % 2 ? ownKeys4(Object(
|
|
16131
|
-
_defineProperty5(
|
|
16132
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(
|
|
16133
|
-
Object.defineProperty(
|
|
16129
|
+
var t = null != arguments[r] ? arguments[r] : {};
|
|
16130
|
+
r % 2 ? ownKeys4(Object(t), true).forEach(function(r2) {
|
|
16131
|
+
_defineProperty5(e, r2, t[r2]);
|
|
16132
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys4(Object(t)).forEach(function(r2) {
|
|
16133
|
+
Object.defineProperty(e, r2, Object.getOwnPropertyDescriptor(t, r2));
|
|
16134
16134
|
});
|
|
16135
16135
|
}
|
|
16136
|
-
return
|
|
16136
|
+
return e;
|
|
16137
16137
|
}
|
|
16138
|
-
function _defineProperty5(
|
|
16139
|
-
return (r = _toPropertyKey6(r)) in
|
|
16138
|
+
function _defineProperty5(e, r, t) {
|
|
16139
|
+
return (r = _toPropertyKey6(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: true, configurable: true, writable: true }) : e[r] = t, e;
|
|
16140
16140
|
}
|
|
16141
|
-
function _toPropertyKey6(
|
|
16142
|
-
var
|
|
16143
|
-
return "symbol" == _typeof7(
|
|
16141
|
+
function _toPropertyKey6(t) {
|
|
16142
|
+
var i = _toPrimitive6(t, "string");
|
|
16143
|
+
return "symbol" == _typeof7(i) ? i : i + "";
|
|
16144
16144
|
}
|
|
16145
|
-
function _toPrimitive6(
|
|
16146
|
-
if ("object" != _typeof7(
|
|
16147
|
-
var
|
|
16148
|
-
if (void 0 !==
|
|
16149
|
-
var
|
|
16150
|
-
if ("object" != _typeof7(
|
|
16145
|
+
function _toPrimitive6(t, r) {
|
|
16146
|
+
if ("object" != _typeof7(t) || !t) return t;
|
|
16147
|
+
var e = t[Symbol.toPrimitive];
|
|
16148
|
+
if (void 0 !== e) {
|
|
16149
|
+
var i = e.call(t, r);
|
|
16150
|
+
if ("object" != _typeof7(i)) return i;
|
|
16151
16151
|
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
16152
16152
|
}
|
|
16153
|
-
return ("string" === r ? String : Number)(
|
|
16153
|
+
return ("string" === r ? String : Number)(t);
|
|
16154
16154
|
}
|
|
16155
|
-
function _slicedToArray(r,
|
|
16156
|
-
return _arrayWithHoles(r) || _iterableToArrayLimit(r,
|
|
16155
|
+
function _slicedToArray(r, e) {
|
|
16156
|
+
return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray6(r, e) || _nonIterableRest();
|
|
16157
16157
|
}
|
|
16158
16158
|
function _nonIterableRest() {
|
|
16159
16159
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
@@ -16161,26 +16161,26 @@ function _nonIterableRest() {
|
|
|
16161
16161
|
function _unsupportedIterableToArray6(r, a) {
|
|
16162
16162
|
if (r) {
|
|
16163
16163
|
if ("string" == typeof r) return _arrayLikeToArray6(r, a);
|
|
16164
|
-
var
|
|
16165
|
-
return "Object" ===
|
|
16164
|
+
var t = {}.toString.call(r).slice(8, -1);
|
|
16165
|
+
return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray6(r, a) : void 0;
|
|
16166
16166
|
}
|
|
16167
16167
|
}
|
|
16168
16168
|
function _arrayLikeToArray6(r, a) {
|
|
16169
16169
|
(null == a || a > r.length) && (a = r.length);
|
|
16170
|
-
for (var
|
|
16170
|
+
for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
|
|
16171
16171
|
return n;
|
|
16172
16172
|
}
|
|
16173
16173
|
function _iterableToArrayLimit(r, l) {
|
|
16174
|
-
var
|
|
16175
|
-
if (null !=
|
|
16176
|
-
var
|
|
16174
|
+
var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
|
|
16175
|
+
if (null != t) {
|
|
16176
|
+
var e, n, i, u, a = [], f = true, o = false;
|
|
16177
16177
|
try {
|
|
16178
|
-
if (
|
|
16178
|
+
if (i = (t = t.call(r)).next, 0 === l) ; else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = true) ;
|
|
16179
16179
|
} catch (r2) {
|
|
16180
16180
|
o = true, n = r2;
|
|
16181
16181
|
} finally {
|
|
16182
16182
|
try {
|
|
16183
|
-
if (!f && null !=
|
|
16183
|
+
if (!f && null != t["return"] && (u = t["return"](), Object(u) !== u)) return;
|
|
16184
16184
|
} finally {
|
|
16185
16185
|
if (o) throw n;
|
|
16186
16186
|
}
|
|
@@ -16318,9 +16318,9 @@ function validatePhoneNumber(data, lenientPhoneValidation) {
|
|
|
16318
16318
|
} else {
|
|
16319
16319
|
return void 0;
|
|
16320
16320
|
}
|
|
16321
|
-
} catch (
|
|
16322
|
-
if (
|
|
16323
|
-
return phoneValidationErrorMessages(
|
|
16321
|
+
} catch (e) {
|
|
16322
|
+
if (e instanceof ParseError) {
|
|
16323
|
+
return phoneValidationErrorMessages(e, data);
|
|
16324
16324
|
} else {
|
|
16325
16325
|
return {
|
|
16326
16326
|
keyword: "format",
|
|
@@ -16350,8 +16350,8 @@ function compileAllowedCountryCodesValidation(schema) {
|
|
|
16350
16350
|
};
|
|
16351
16351
|
return validate2;
|
|
16352
16352
|
}
|
|
16353
|
-
function phoneValidationErrorMessages(
|
|
16354
|
-
switch (
|
|
16353
|
+
function phoneValidationErrorMessages(e, data) {
|
|
16354
|
+
switch (e.message) {
|
|
16355
16355
|
case "INVALID_COUNTRY":
|
|
16356
16356
|
return {
|
|
16357
16357
|
keyword: "countryCode",
|
|
@@ -16468,8 +16468,8 @@ var require_dist2 = __commonJS({
|
|
|
16468
16468
|
}
|
|
16469
16469
|
if (items) {
|
|
16470
16470
|
errors.items = {};
|
|
16471
|
-
for (let
|
|
16472
|
-
errors.items[
|
|
16471
|
+
for (let i = 0; i < items.length; i++)
|
|
16472
|
+
errors.items[i] = [];
|
|
16473
16473
|
}
|
|
16474
16474
|
return errors;
|
|
16475
16475
|
}
|
|
@@ -16725,11 +16725,11 @@ var require_uniqueItemProperties = __commonJS({
|
|
|
16725
16725
|
hash[p] = true;
|
|
16726
16726
|
}
|
|
16727
16727
|
} else {
|
|
16728
|
-
for (let
|
|
16729
|
-
const x = data[
|
|
16728
|
+
for (let i = data.length; i--; ) {
|
|
16729
|
+
const x = data[i];
|
|
16730
16730
|
if (!x || typeof x != "object")
|
|
16731
16731
|
continue;
|
|
16732
|
-
for (let j =
|
|
16732
|
+
for (let j = i; j--; ) {
|
|
16733
16733
|
const y = data[j];
|
|
16734
16734
|
if (y && typeof y == "object" && equal(x[key], y[key]))
|
|
16735
16735
|
return false;
|
|
@@ -16750,8 +16750,8 @@ var require_uniqueItemProperties = __commonJS({
|
|
|
16750
16750
|
function getScalarKeys(keys2, schema) {
|
|
16751
16751
|
return keys2.map((key) => {
|
|
16752
16752
|
var _a, _b, _c;
|
|
16753
|
-
const
|
|
16754
|
-
return Array.isArray(
|
|
16753
|
+
const t = (_c = (_b = (_a = schema.items) === null || _a === void 0 ? void 0 : _a.properties) === null || _b === void 0 ? void 0 : _b[key]) === null || _c === void 0 ? void 0 : _c.type;
|
|
16754
|
+
return Array.isArray(t) ? !t.includes("object") && !t.includes("array") : SCALAR_TYPES.includes(t);
|
|
16755
16755
|
});
|
|
16756
16756
|
}
|
|
16757
16757
|
module.exports = getDef;
|
|
@@ -16876,99 +16876,99 @@ var init_form_schema_mapper = __esm({
|
|
|
16876
16876
|
// ../../node_modules/dayjs/dayjs.min.js
|
|
16877
16877
|
var require_dayjs_min = __commonJS({
|
|
16878
16878
|
"../../node_modules/dayjs/dayjs.min.js"(exports, module) {
|
|
16879
|
-
!(function(
|
|
16880
|
-
"object" == typeof exports && "undefined" != typeof module ? module.exports =
|
|
16879
|
+
!(function(t, e) {
|
|
16880
|
+
"object" == typeof exports && "undefined" != typeof module ? module.exports = e() : "function" == typeof define && define.amd ? define(e) : (t = "undefined" != typeof globalThis ? globalThis : t || self).dayjs = e();
|
|
16881
16881
|
})(exports, (function() {
|
|
16882
|
-
var
|
|
16883
|
-
var
|
|
16884
|
-
return "[" +
|
|
16885
|
-
} }, m = function(
|
|
16886
|
-
var r2 = String(
|
|
16887
|
-
return !r2 || r2.length >=
|
|
16888
|
-
}, v = { s: m, z: function(
|
|
16889
|
-
var
|
|
16890
|
-
return (
|
|
16891
|
-
}, m: function
|
|
16892
|
-
if (
|
|
16893
|
-
var r2 = 12 * (n2.year() -
|
|
16894
|
-
return +(-(r2 + (n2 -
|
|
16895
|
-
}, a: function(
|
|
16896
|
-
return
|
|
16897
|
-
}, p: function(
|
|
16898
|
-
return { M: c, y: h, w: o, d: a, D: d, h: u, m: s, s:
|
|
16899
|
-
}, u: function(
|
|
16900
|
-
return void 0 ===
|
|
16882
|
+
var t = 1e3, e = 6e4, n = 36e5, r = "millisecond", i = "second", s = "minute", u = "hour", a = "day", o = "week", c = "month", f = "quarter", h = "year", d = "date", l = "Invalid Date", $ = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, y = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, M = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(t2) {
|
|
16883
|
+
var e2 = ["th", "st", "nd", "rd"], n2 = t2 % 100;
|
|
16884
|
+
return "[" + t2 + (e2[(n2 - 20) % 10] || e2[n2] || e2[0]) + "]";
|
|
16885
|
+
} }, m = function(t2, e2, n2) {
|
|
16886
|
+
var r2 = String(t2);
|
|
16887
|
+
return !r2 || r2.length >= e2 ? t2 : "" + Array(e2 + 1 - r2.length).join(n2) + t2;
|
|
16888
|
+
}, v = { s: m, z: function(t2) {
|
|
16889
|
+
var e2 = -t2.utcOffset(), n2 = Math.abs(e2), r2 = Math.floor(n2 / 60), i2 = n2 % 60;
|
|
16890
|
+
return (e2 <= 0 ? "+" : "-") + m(r2, 2, "0") + ":" + m(i2, 2, "0");
|
|
16891
|
+
}, m: function t2(e2, n2) {
|
|
16892
|
+
if (e2.date() < n2.date()) return -t2(n2, e2);
|
|
16893
|
+
var r2 = 12 * (n2.year() - e2.year()) + (n2.month() - e2.month()), i2 = e2.clone().add(r2, c), s2 = n2 - i2 < 0, u2 = e2.clone().add(r2 + (s2 ? -1 : 1), c);
|
|
16894
|
+
return +(-(r2 + (n2 - i2) / (s2 ? i2 - u2 : u2 - i2)) || 0);
|
|
16895
|
+
}, a: function(t2) {
|
|
16896
|
+
return t2 < 0 ? Math.ceil(t2) || 0 : Math.floor(t2);
|
|
16897
|
+
}, p: function(t2) {
|
|
16898
|
+
return { M: c, y: h, w: o, d: a, D: d, h: u, m: s, s: i, ms: r, Q: f }[t2] || String(t2 || "").toLowerCase().replace(/s$/, "");
|
|
16899
|
+
}, u: function(t2) {
|
|
16900
|
+
return void 0 === t2;
|
|
16901
16901
|
} }, g = "en", D = {};
|
|
16902
16902
|
D[g] = M;
|
|
16903
|
-
var p = "$isDayjsObject", S = function(
|
|
16904
|
-
return
|
|
16905
|
-
}, w = function
|
|
16906
|
-
var
|
|
16907
|
-
if (!
|
|
16908
|
-
if ("string" == typeof
|
|
16909
|
-
var s2 =
|
|
16910
|
-
D[s2] && (
|
|
16911
|
-
var u2 =
|
|
16912
|
-
if (!
|
|
16903
|
+
var p = "$isDayjsObject", S = function(t2) {
|
|
16904
|
+
return t2 instanceof _23 || !(!t2 || !t2[p]);
|
|
16905
|
+
}, w = function t2(e2, n2, r2) {
|
|
16906
|
+
var i2;
|
|
16907
|
+
if (!e2) return g;
|
|
16908
|
+
if ("string" == typeof e2) {
|
|
16909
|
+
var s2 = e2.toLowerCase();
|
|
16910
|
+
D[s2] && (i2 = s2), n2 && (D[s2] = n2, i2 = s2);
|
|
16911
|
+
var u2 = e2.split("-");
|
|
16912
|
+
if (!i2 && u2.length > 1) return t2(u2[0]);
|
|
16913
16913
|
} else {
|
|
16914
|
-
var a2 =
|
|
16915
|
-
D[a2] =
|
|
16916
|
-
}
|
|
16917
|
-
return !r2 &&
|
|
16918
|
-
}, O = function(
|
|
16919
|
-
if (S(
|
|
16920
|
-
var n2 = "object" == typeof
|
|
16921
|
-
return n2.date =
|
|
16914
|
+
var a2 = e2.name;
|
|
16915
|
+
D[a2] = e2, i2 = a2;
|
|
16916
|
+
}
|
|
16917
|
+
return !r2 && i2 && (g = i2), i2 || !r2 && g;
|
|
16918
|
+
}, O = function(t2, e2) {
|
|
16919
|
+
if (S(t2)) return t2.clone();
|
|
16920
|
+
var n2 = "object" == typeof e2 ? e2 : {};
|
|
16921
|
+
return n2.date = t2, n2.args = arguments, new _23(n2);
|
|
16922
16922
|
}, b = v;
|
|
16923
|
-
b.l = w, b.i = S, b.w = function(
|
|
16924
|
-
return O(
|
|
16923
|
+
b.l = w, b.i = S, b.w = function(t2, e2) {
|
|
16924
|
+
return O(t2, { locale: e2.$L, utc: e2.$u, x: e2.$x, $offset: e2.$offset });
|
|
16925
16925
|
};
|
|
16926
16926
|
var _23 = (function() {
|
|
16927
|
-
function M2(
|
|
16928
|
-
this.$L = w(
|
|
16927
|
+
function M2(t2) {
|
|
16928
|
+
this.$L = w(t2.locale, null, true), this.parse(t2), this.$x = this.$x || t2.x || {}, this[p] = true;
|
|
16929
16929
|
}
|
|
16930
16930
|
var m2 = M2.prototype;
|
|
16931
|
-
return m2.parse = function(
|
|
16932
|
-
this.$d = (function(
|
|
16933
|
-
var
|
|
16934
|
-
if (null ===
|
|
16935
|
-
if (b.u(
|
|
16936
|
-
if (
|
|
16937
|
-
if ("string" == typeof
|
|
16938
|
-
var r2 =
|
|
16931
|
+
return m2.parse = function(t2) {
|
|
16932
|
+
this.$d = (function(t3) {
|
|
16933
|
+
var e2 = t3.date, n2 = t3.utc;
|
|
16934
|
+
if (null === e2) return /* @__PURE__ */ new Date(NaN);
|
|
16935
|
+
if (b.u(e2)) return /* @__PURE__ */ new Date();
|
|
16936
|
+
if (e2 instanceof Date) return new Date(e2);
|
|
16937
|
+
if ("string" == typeof e2 && !/Z$/i.test(e2)) {
|
|
16938
|
+
var r2 = e2.match($);
|
|
16939
16939
|
if (r2) {
|
|
16940
|
-
var
|
|
16941
|
-
return n2 ? new Date(Date.UTC(r2[1],
|
|
16940
|
+
var i2 = r2[2] - 1 || 0, s2 = (r2[7] || "0").substring(0, 3);
|
|
16941
|
+
return n2 ? new Date(Date.UTC(r2[1], i2, r2[3] || 1, r2[4] || 0, r2[5] || 0, r2[6] || 0, s2)) : new Date(r2[1], i2, r2[3] || 1, r2[4] || 0, r2[5] || 0, r2[6] || 0, s2);
|
|
16942
16942
|
}
|
|
16943
16943
|
}
|
|
16944
|
-
return new Date(
|
|
16945
|
-
})(
|
|
16944
|
+
return new Date(e2);
|
|
16945
|
+
})(t2), this.init();
|
|
16946
16946
|
}, m2.init = function() {
|
|
16947
|
-
var
|
|
16948
|
-
this.$y =
|
|
16947
|
+
var t2 = this.$d;
|
|
16948
|
+
this.$y = t2.getFullYear(), this.$M = t2.getMonth(), this.$D = t2.getDate(), this.$W = t2.getDay(), this.$H = t2.getHours(), this.$m = t2.getMinutes(), this.$s = t2.getSeconds(), this.$ms = t2.getMilliseconds();
|
|
16949
16949
|
}, m2.$utils = function() {
|
|
16950
16950
|
return b;
|
|
16951
16951
|
}, m2.isValid = function() {
|
|
16952
16952
|
return !(this.$d.toString() === l);
|
|
16953
|
-
}, m2.isSame = function(
|
|
16954
|
-
var n2 = O(
|
|
16955
|
-
return this.startOf(
|
|
16956
|
-
}, m2.isAfter = function(
|
|
16957
|
-
return O(
|
|
16958
|
-
}, m2.isBefore = function(
|
|
16959
|
-
return this.endOf(
|
|
16960
|
-
}, m2.$g = function(
|
|
16961
|
-
return b.u(
|
|
16953
|
+
}, m2.isSame = function(t2, e2) {
|
|
16954
|
+
var n2 = O(t2);
|
|
16955
|
+
return this.startOf(e2) <= n2 && n2 <= this.endOf(e2);
|
|
16956
|
+
}, m2.isAfter = function(t2, e2) {
|
|
16957
|
+
return O(t2) < this.startOf(e2);
|
|
16958
|
+
}, m2.isBefore = function(t2, e2) {
|
|
16959
|
+
return this.endOf(e2) < O(t2);
|
|
16960
|
+
}, m2.$g = function(t2, e2, n2) {
|
|
16961
|
+
return b.u(t2) ? this[e2] : this.set(n2, t2);
|
|
16962
16962
|
}, m2.unix = function() {
|
|
16963
16963
|
return Math.floor(this.valueOf() / 1e3);
|
|
16964
16964
|
}, m2.valueOf = function() {
|
|
16965
16965
|
return this.$d.getTime();
|
|
16966
|
-
}, m2.startOf = function(
|
|
16967
|
-
var n2 = this, r2 = !!b.u(
|
|
16968
|
-
var
|
|
16969
|
-
return r2 ?
|
|
16970
|
-
}, $2 = function(
|
|
16971
|
-
return b.w(n2.toDate()[
|
|
16966
|
+
}, m2.startOf = function(t2, e2) {
|
|
16967
|
+
var n2 = this, r2 = !!b.u(e2) || e2, f2 = b.p(t2), l2 = function(t3, e3) {
|
|
16968
|
+
var i2 = b.w(n2.$u ? Date.UTC(n2.$y, e3, t3) : new Date(n2.$y, e3, t3), n2);
|
|
16969
|
+
return r2 ? i2 : i2.endOf(a);
|
|
16970
|
+
}, $2 = function(t3, e3) {
|
|
16971
|
+
return b.w(n2.toDate()[t3].apply(n2.toDate("s"), (r2 ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(e3)), n2);
|
|
16972
16972
|
}, y2 = this.$W, M3 = this.$M, m3 = this.$D, v2 = "set" + (this.$u ? "UTC" : "");
|
|
16973
16973
|
switch (f2) {
|
|
16974
16974
|
case h:
|
|
@@ -16985,57 +16985,57 @@ var require_dayjs_min = __commonJS({
|
|
|
16985
16985
|
return $2(v2 + "Minutes", 1);
|
|
16986
16986
|
case s:
|
|
16987
16987
|
return $2(v2 + "Seconds", 2);
|
|
16988
|
-
case
|
|
16988
|
+
case i:
|
|
16989
16989
|
return $2(v2 + "Milliseconds", 3);
|
|
16990
16990
|
default:
|
|
16991
16991
|
return this.clone();
|
|
16992
16992
|
}
|
|
16993
|
-
}, m2.endOf = function(
|
|
16994
|
-
return this.startOf(
|
|
16995
|
-
}, m2.$set = function(
|
|
16996
|
-
var n2, o2 = b.p(
|
|
16993
|
+
}, m2.endOf = function(t2) {
|
|
16994
|
+
return this.startOf(t2, false);
|
|
16995
|
+
}, m2.$set = function(t2, e2) {
|
|
16996
|
+
var n2, o2 = b.p(t2), f2 = "set" + (this.$u ? "UTC" : ""), l2 = (n2 = {}, n2[a] = f2 + "Date", n2[d] = f2 + "Date", n2[c] = f2 + "Month", n2[h] = f2 + "FullYear", n2[u] = f2 + "Hours", n2[s] = f2 + "Minutes", n2[i] = f2 + "Seconds", n2[r] = f2 + "Milliseconds", n2)[o2], $2 = o2 === a ? this.$D + (e2 - this.$W) : e2;
|
|
16997
16997
|
if (o2 === c || o2 === h) {
|
|
16998
16998
|
var y2 = this.clone().set(d, 1);
|
|
16999
16999
|
y2.$d[l2]($2), y2.init(), this.$d = y2.set(d, Math.min(this.$D, y2.daysInMonth())).$d;
|
|
17000
17000
|
} else l2 && this.$d[l2]($2);
|
|
17001
17001
|
return this.init(), this;
|
|
17002
|
-
}, m2.set = function(
|
|
17003
|
-
return this.clone().$set(
|
|
17004
|
-
}, m2.get = function(
|
|
17005
|
-
return this[b.p(
|
|
17002
|
+
}, m2.set = function(t2, e2) {
|
|
17003
|
+
return this.clone().$set(t2, e2);
|
|
17004
|
+
}, m2.get = function(t2) {
|
|
17005
|
+
return this[b.p(t2)]();
|
|
17006
17006
|
}, m2.add = function(r2, f2) {
|
|
17007
17007
|
var d2, l2 = this;
|
|
17008
17008
|
r2 = Number(r2);
|
|
17009
|
-
var $2 = b.p(f2), y2 = function(
|
|
17010
|
-
var
|
|
17011
|
-
return b.w(
|
|
17009
|
+
var $2 = b.p(f2), y2 = function(t2) {
|
|
17010
|
+
var e2 = O(l2);
|
|
17011
|
+
return b.w(e2.date(e2.date() + Math.round(t2 * r2)), l2);
|
|
17012
17012
|
};
|
|
17013
17013
|
if ($2 === c) return this.set(c, this.$M + r2);
|
|
17014
17014
|
if ($2 === h) return this.set(h, this.$y + r2);
|
|
17015
17015
|
if ($2 === a) return y2(1);
|
|
17016
17016
|
if ($2 === o) return y2(7);
|
|
17017
|
-
var M3 = (d2 = {}, d2[s] =
|
|
17017
|
+
var M3 = (d2 = {}, d2[s] = e, d2[u] = n, d2[i] = t, d2)[$2] || 1, m3 = this.$d.getTime() + r2 * M3;
|
|
17018
17018
|
return b.w(m3, this);
|
|
17019
|
-
}, m2.subtract = function(
|
|
17020
|
-
return this.add(-1 *
|
|
17021
|
-
}, m2.format = function(
|
|
17022
|
-
var
|
|
17019
|
+
}, m2.subtract = function(t2, e2) {
|
|
17020
|
+
return this.add(-1 * t2, e2);
|
|
17021
|
+
}, m2.format = function(t2) {
|
|
17022
|
+
var e2 = this, n2 = this.$locale();
|
|
17023
17023
|
if (!this.isValid()) return n2.invalidDate || l;
|
|
17024
|
-
var r2 =
|
|
17025
|
-
return
|
|
17026
|
-
}, d2 = function(
|
|
17027
|
-
return b.s(s2 % 12 || 12,
|
|
17028
|
-
}, $2 = f2 || function(
|
|
17029
|
-
var r3 =
|
|
17024
|
+
var r2 = t2 || "YYYY-MM-DDTHH:mm:ssZ", i2 = b.z(this), s2 = this.$H, u2 = this.$m, a2 = this.$M, o2 = n2.weekdays, c2 = n2.months, f2 = n2.meridiem, h2 = function(t3, n3, i3, s3) {
|
|
17025
|
+
return t3 && (t3[n3] || t3(e2, r2)) || i3[n3].slice(0, s3);
|
|
17026
|
+
}, d2 = function(t3) {
|
|
17027
|
+
return b.s(s2 % 12 || 12, t3, "0");
|
|
17028
|
+
}, $2 = f2 || function(t3, e3, n3) {
|
|
17029
|
+
var r3 = t3 < 12 ? "AM" : "PM";
|
|
17030
17030
|
return n3 ? r3.toLowerCase() : r3;
|
|
17031
17031
|
};
|
|
17032
|
-
return r2.replace(y, (function(
|
|
17033
|
-
return r3 || (function(
|
|
17034
|
-
switch (
|
|
17032
|
+
return r2.replace(y, (function(t3, r3) {
|
|
17033
|
+
return r3 || (function(t4) {
|
|
17034
|
+
switch (t4) {
|
|
17035
17035
|
case "YY":
|
|
17036
|
-
return String(
|
|
17036
|
+
return String(e2.$y).slice(-2);
|
|
17037
17037
|
case "YYYY":
|
|
17038
|
-
return b.s(
|
|
17038
|
+
return b.s(e2.$y, 4, "0");
|
|
17039
17039
|
case "M":
|
|
17040
17040
|
return a2 + 1;
|
|
17041
17041
|
case "MM":
|
|
@@ -17045,17 +17045,17 @@ var require_dayjs_min = __commonJS({
|
|
|
17045
17045
|
case "MMMM":
|
|
17046
17046
|
return h2(c2, a2);
|
|
17047
17047
|
case "D":
|
|
17048
|
-
return
|
|
17048
|
+
return e2.$D;
|
|
17049
17049
|
case "DD":
|
|
17050
|
-
return b.s(
|
|
17050
|
+
return b.s(e2.$D, 2, "0");
|
|
17051
17051
|
case "d":
|
|
17052
|
-
return String(
|
|
17052
|
+
return String(e2.$W);
|
|
17053
17053
|
case "dd":
|
|
17054
|
-
return h2(n2.weekdaysMin,
|
|
17054
|
+
return h2(n2.weekdaysMin, e2.$W, o2, 2);
|
|
17055
17055
|
case "ddd":
|
|
17056
|
-
return h2(n2.weekdaysShort,
|
|
17056
|
+
return h2(n2.weekdaysShort, e2.$W, o2, 3);
|
|
17057
17057
|
case "dddd":
|
|
17058
|
-
return o2[
|
|
17058
|
+
return o2[e2.$W];
|
|
17059
17059
|
case "H":
|
|
17060
17060
|
return String(s2);
|
|
17061
17061
|
case "HH":
|
|
@@ -17073,21 +17073,21 @@ var require_dayjs_min = __commonJS({
|
|
|
17073
17073
|
case "mm":
|
|
17074
17074
|
return b.s(u2, 2, "0");
|
|
17075
17075
|
case "s":
|
|
17076
|
-
return String(
|
|
17076
|
+
return String(e2.$s);
|
|
17077
17077
|
case "ss":
|
|
17078
|
-
return b.s(
|
|
17078
|
+
return b.s(e2.$s, 2, "0");
|
|
17079
17079
|
case "SSS":
|
|
17080
|
-
return b.s(
|
|
17080
|
+
return b.s(e2.$ms, 3, "0");
|
|
17081
17081
|
case "Z":
|
|
17082
|
-
return
|
|
17082
|
+
return i2;
|
|
17083
17083
|
}
|
|
17084
17084
|
return null;
|
|
17085
|
-
})(
|
|
17085
|
+
})(t3) || i2.replace(":", "");
|
|
17086
17086
|
}));
|
|
17087
17087
|
}, m2.utcOffset = function() {
|
|
17088
17088
|
return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
|
|
17089
17089
|
}, m2.diff = function(r2, d2, l2) {
|
|
17090
|
-
var $2, y2 = this, M3 = b.p(d2), m3 = O(r2), v2 = (m3.utcOffset() - this.utcOffset()) *
|
|
17090
|
+
var $2, y2 = this, M3 = b.p(d2), m3 = O(r2), v2 = (m3.utcOffset() - this.utcOffset()) * e, g2 = this - m3, D2 = function() {
|
|
17091
17091
|
return b.m(y2, m3);
|
|
17092
17092
|
};
|
|
17093
17093
|
switch (M3) {
|
|
@@ -17110,10 +17110,10 @@ var require_dayjs_min = __commonJS({
|
|
|
17110
17110
|
$2 = g2 / n;
|
|
17111
17111
|
break;
|
|
17112
17112
|
case s:
|
|
17113
|
-
$2 = g2 /
|
|
17113
|
+
$2 = g2 / e;
|
|
17114
17114
|
break;
|
|
17115
|
-
case
|
|
17116
|
-
$2 = g2 /
|
|
17115
|
+
case i:
|
|
17116
|
+
$2 = g2 / t;
|
|
17117
17117
|
break;
|
|
17118
17118
|
default:
|
|
17119
17119
|
$2 = g2;
|
|
@@ -17123,9 +17123,9 @@ var require_dayjs_min = __commonJS({
|
|
|
17123
17123
|
return this.endOf(c).$D;
|
|
17124
17124
|
}, m2.$locale = function() {
|
|
17125
17125
|
return D[this.$L];
|
|
17126
|
-
}, m2.locale = function(
|
|
17127
|
-
if (!
|
|
17128
|
-
var n2 = this.clone(), r2 = w(
|
|
17126
|
+
}, m2.locale = function(t2, e2) {
|
|
17127
|
+
if (!t2) return this.$L;
|
|
17128
|
+
var n2 = this.clone(), r2 = w(t2, e2, true);
|
|
17129
17129
|
return r2 && (n2.$L = r2), n2;
|
|
17130
17130
|
}, m2.clone = function() {
|
|
17131
17131
|
return b.w(this.$d, this);
|
|
@@ -17139,14 +17139,14 @@ var require_dayjs_min = __commonJS({
|
|
|
17139
17139
|
return this.$d.toUTCString();
|
|
17140
17140
|
}, M2;
|
|
17141
17141
|
})(), k = _23.prototype;
|
|
17142
|
-
return O.prototype = k, [["$ms", r], ["$s",
|
|
17143
|
-
k[
|
|
17144
|
-
return this.$g(
|
|
17142
|
+
return O.prototype = k, [["$ms", r], ["$s", i], ["$m", s], ["$H", u], ["$W", a], ["$M", c], ["$y", h], ["$D", d]].forEach((function(t2) {
|
|
17143
|
+
k[t2[1]] = function(e2) {
|
|
17144
|
+
return this.$g(e2, t2[0], t2[1]);
|
|
17145
17145
|
};
|
|
17146
|
-
})), O.extend = function(
|
|
17147
|
-
return
|
|
17148
|
-
}, O.locale = w, O.isDayjs = S, O.unix = function(
|
|
17149
|
-
return O(1e3 *
|
|
17146
|
+
})), O.extend = function(t2, e2) {
|
|
17147
|
+
return t2.$i || (t2(e2, _23, O), t2.$i = true), O;
|
|
17148
|
+
}, O.locale = w, O.isDayjs = S, O.unix = function(t2) {
|
|
17149
|
+
return O(1e3 * t2);
|
|
17150
17150
|
}, O.en = D[g], O.Ls = D, O.p = {}, O;
|
|
17151
17151
|
}));
|
|
17152
17152
|
}
|
|
@@ -17155,41 +17155,41 @@ var require_dayjs_min = __commonJS({
|
|
|
17155
17155
|
// ../../node_modules/dayjs/plugin/utc.js
|
|
17156
17156
|
var require_utc = __commonJS({
|
|
17157
17157
|
"../../node_modules/dayjs/plugin/utc.js"(exports, module) {
|
|
17158
|
-
!(function(
|
|
17159
|
-
"object" == typeof exports && "undefined" != typeof module ? module.exports =
|
|
17158
|
+
!(function(t, i) {
|
|
17159
|
+
"object" == typeof exports && "undefined" != typeof module ? module.exports = i() : "function" == typeof define && define.amd ? define(i) : (t = "undefined" != typeof globalThis ? globalThis : t || self).dayjs_plugin_utc = i();
|
|
17160
17160
|
})(exports, (function() {
|
|
17161
|
-
var
|
|
17161
|
+
var t = "minute", i = /[+-]\d\d(?::?\d\d)?/g, e = /([+-]|\d\d)/g;
|
|
17162
17162
|
return function(s, f, n) {
|
|
17163
17163
|
var u = f.prototype;
|
|
17164
|
-
n.utc = function(
|
|
17165
|
-
var
|
|
17166
|
-
return new f(
|
|
17167
|
-
}, u.utc = function(
|
|
17168
|
-
var
|
|
17169
|
-
return
|
|
17164
|
+
n.utc = function(t2) {
|
|
17165
|
+
var i2 = { date: t2, utc: true, args: arguments };
|
|
17166
|
+
return new f(i2);
|
|
17167
|
+
}, u.utc = function(i2) {
|
|
17168
|
+
var e2 = n(this.toDate(), { locale: this.$L, utc: true });
|
|
17169
|
+
return i2 ? e2.add(this.utcOffset(), t) : e2;
|
|
17170
17170
|
}, u.local = function() {
|
|
17171
17171
|
return n(this.toDate(), { locale: this.$L, utc: false });
|
|
17172
17172
|
};
|
|
17173
17173
|
var r = u.parse;
|
|
17174
|
-
u.parse = function(
|
|
17175
|
-
|
|
17174
|
+
u.parse = function(t2) {
|
|
17175
|
+
t2.utc && (this.$u = true), this.$utils().u(t2.$offset) || (this.$offset = t2.$offset), r.call(this, t2);
|
|
17176
17176
|
};
|
|
17177
17177
|
var o = u.init;
|
|
17178
17178
|
u.init = function() {
|
|
17179
17179
|
if (this.$u) {
|
|
17180
|
-
var
|
|
17181
|
-
this.$y =
|
|
17180
|
+
var t2 = this.$d;
|
|
17181
|
+
this.$y = t2.getUTCFullYear(), this.$M = t2.getUTCMonth(), this.$D = t2.getUTCDate(), this.$W = t2.getUTCDay(), this.$H = t2.getUTCHours(), this.$m = t2.getUTCMinutes(), this.$s = t2.getUTCSeconds(), this.$ms = t2.getUTCMilliseconds();
|
|
17182
17182
|
} else o.call(this);
|
|
17183
17183
|
};
|
|
17184
17184
|
var a = u.utcOffset;
|
|
17185
17185
|
u.utcOffset = function(s2, f2) {
|
|
17186
17186
|
var n2 = this.$utils().u;
|
|
17187
17187
|
if (n2(s2)) return this.$u ? 0 : n2(this.$offset) ? a.call(this) : this.$offset;
|
|
17188
|
-
if ("string" == typeof s2 && (s2 = (function(
|
|
17189
|
-
void 0 ===
|
|
17190
|
-
var s3 =
|
|
17188
|
+
if ("string" == typeof s2 && (s2 = (function(t2) {
|
|
17189
|
+
void 0 === t2 && (t2 = "");
|
|
17190
|
+
var s3 = t2.match(i);
|
|
17191
17191
|
if (!s3) return null;
|
|
17192
|
-
var f3 = ("" + s3[0]).match(
|
|
17192
|
+
var f3 = ("" + s3[0]).match(e) || ["-", 0, 0], n3 = f3[0], u3 = 60 * +f3[1] + +f3[2];
|
|
17193
17193
|
return 0 === u3 ? 0 : "+" === n3 ? u3 : -u3;
|
|
17194
17194
|
})(s2), null === s2)) return this;
|
|
17195
17195
|
var u2 = Math.abs(s2) <= 16 ? 60 * s2 : s2;
|
|
@@ -17197,15 +17197,15 @@ var require_utc = __commonJS({
|
|
|
17197
17197
|
var r2 = this.clone();
|
|
17198
17198
|
if (f2) return r2.$offset = u2, r2.$u = false, r2;
|
|
17199
17199
|
var o2 = this.$u ? this.toDate().getTimezoneOffset() : -1 * this.utcOffset();
|
|
17200
|
-
return (r2 = this.local().add(u2 + o2,
|
|
17200
|
+
return (r2 = this.local().add(u2 + o2, t)).$offset = u2, r2.$x.$localOffset = o2, r2;
|
|
17201
17201
|
};
|
|
17202
17202
|
var h = u.format;
|
|
17203
|
-
u.format = function(
|
|
17204
|
-
var
|
|
17205
|
-
return h.call(this,
|
|
17203
|
+
u.format = function(t2) {
|
|
17204
|
+
var i2 = t2 || (this.$u ? "YYYY-MM-DDTHH:mm:ss[Z]" : "");
|
|
17205
|
+
return h.call(this, i2);
|
|
17206
17206
|
}, u.valueOf = function() {
|
|
17207
|
-
var
|
|
17208
|
-
return this.$d.valueOf() - 6e4 *
|
|
17207
|
+
var t2 = this.$utils().u(this.$offset) ? 0 : this.$offset + (this.$x.$localOffset || this.$d.getTimezoneOffset());
|
|
17208
|
+
return this.$d.valueOf() - 6e4 * t2;
|
|
17209
17209
|
}, u.isUTC = function() {
|
|
17210
17210
|
return !!this.$u;
|
|
17211
17211
|
}, u.toISOString = function() {
|
|
@@ -17214,14 +17214,14 @@ var require_utc = __commonJS({
|
|
|
17214
17214
|
return this.toDate().toUTCString();
|
|
17215
17215
|
};
|
|
17216
17216
|
var l = u.toDate;
|
|
17217
|
-
u.toDate = function(
|
|
17218
|
-
return "s" ===
|
|
17217
|
+
u.toDate = function(t2) {
|
|
17218
|
+
return "s" === t2 && this.$offset ? n(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate() : l.call(this);
|
|
17219
17219
|
};
|
|
17220
17220
|
var c = u.diff;
|
|
17221
|
-
u.diff = function(
|
|
17222
|
-
if (
|
|
17223
|
-
var s2 = this.local(), f2 = n(
|
|
17224
|
-
return c.call(s2, f2,
|
|
17221
|
+
u.diff = function(t2, i2, e2) {
|
|
17222
|
+
if (t2 && this.$u === t2.$u) return c.call(this, t2, i2, e2);
|
|
17223
|
+
var s2 = this.local(), f2 = n(t2).local();
|
|
17224
|
+
return c.call(s2, f2, i2, e2);
|
|
17225
17225
|
};
|
|
17226
17226
|
};
|
|
17227
17227
|
}));
|
|
@@ -17523,8 +17523,8 @@ function mapToStaticDate(value, currentDate) {
|
|
|
17523
17523
|
return setDate(amount, unit);
|
|
17524
17524
|
}
|
|
17525
17525
|
return void 0;
|
|
17526
|
-
} catch (
|
|
17527
|
-
console.error(`Failed to parse format ${value}`,
|
|
17526
|
+
} catch (e) {
|
|
17527
|
+
console.error(`Failed to parse format ${value}`, e);
|
|
17528
17528
|
return void 0;
|
|
17529
17529
|
}
|
|
17530
17530
|
}
|
|
@@ -19917,14 +19917,14 @@ var require_src2 = __commonJS({
|
|
|
19917
19917
|
return;
|
|
19918
19918
|
}
|
|
19919
19919
|
var len = parts.length;
|
|
19920
|
-
for (var
|
|
19921
|
-
var key = parts[
|
|
19922
|
-
if (
|
|
19920
|
+
for (var i = 0; i < len; i++) {
|
|
19921
|
+
var key = parts[i];
|
|
19922
|
+
if (i === len - 1) {
|
|
19923
19923
|
obj[key] = value;
|
|
19924
19924
|
return;
|
|
19925
19925
|
}
|
|
19926
19926
|
if (key === "*" && (0, ts_util_is_1.isArray)(obj)) {
|
|
19927
|
-
var remaining = parts.slice(
|
|
19927
|
+
var remaining = parts.slice(i + 1).join(".");
|
|
19928
19928
|
for (var _i = 0, obj_1 = obj; _i < obj_1.length; _i++) {
|
|
19929
19929
|
var item = obj_1[_i];
|
|
19930
19930
|
set2(item, remaining, value);
|
|
@@ -19952,9 +19952,9 @@ var require_src2 = __commonJS({
|
|
|
19952
19952
|
return;
|
|
19953
19953
|
}
|
|
19954
19954
|
var len = parts.length;
|
|
19955
|
-
for (var
|
|
19956
|
-
var key = parts[
|
|
19957
|
-
if (
|
|
19955
|
+
for (var i = 0; i < len; i++) {
|
|
19956
|
+
var key = parts[i];
|
|
19957
|
+
if (i === len - 1) {
|
|
19958
19958
|
return delete obj[key];
|
|
19959
19959
|
}
|
|
19960
19960
|
obj = obj[key];
|
|
@@ -20136,9 +20136,9 @@ var require_default_operators = __commonJS({
|
|
|
20136
20136
|
var require_engine = __commonJS({
|
|
20137
20137
|
"../../node_modules/js-rules-engine/dist/engine.js"(exports) {
|
|
20138
20138
|
var __spreadArrays4 = exports && exports.__spreadArrays || function() {
|
|
20139
|
-
for (var s = 0,
|
|
20140
|
-
for (var r = Array(s), k = 0,
|
|
20141
|
-
for (var a = arguments[
|
|
20139
|
+
for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;
|
|
20140
|
+
for (var r = Array(s), k = 0, i = 0; i < il; i++)
|
|
20141
|
+
for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
|
|
20142
20142
|
r[k] = a[j];
|
|
20143
20143
|
return r;
|
|
20144
20144
|
};
|
|
@@ -20346,12 +20346,12 @@ var require_dist5 = __commonJS({
|
|
|
20346
20346
|
// ../../node_modules/dayjs/plugin/isSameOrAfter.js
|
|
20347
20347
|
var require_isSameOrAfter = __commonJS({
|
|
20348
20348
|
"../../node_modules/dayjs/plugin/isSameOrAfter.js"(exports, module) {
|
|
20349
|
-
!(function(
|
|
20350
|
-
"object" == typeof exports && "undefined" != typeof module ? module.exports =
|
|
20349
|
+
!(function(e, t) {
|
|
20350
|
+
"object" == typeof exports && "undefined" != typeof module ? module.exports = t() : "function" == typeof define && define.amd ? define(t) : (e = "undefined" != typeof globalThis ? globalThis : e || self).dayjs_plugin_isSameOrAfter = t();
|
|
20351
20351
|
})(exports, (function() {
|
|
20352
|
-
return function(
|
|
20353
|
-
|
|
20354
|
-
return this.isSame(
|
|
20352
|
+
return function(e, t) {
|
|
20353
|
+
t.prototype.isSameOrAfter = function(e2, t2) {
|
|
20354
|
+
return this.isSame(e2, t2) || this.isAfter(e2, t2);
|
|
20355
20355
|
};
|
|
20356
20356
|
};
|
|
20357
20357
|
}));
|
|
@@ -20361,12 +20361,12 @@ var require_isSameOrAfter = __commonJS({
|
|
|
20361
20361
|
// ../../node_modules/dayjs/plugin/isSameOrBefore.js
|
|
20362
20362
|
var require_isSameOrBefore = __commonJS({
|
|
20363
20363
|
"../../node_modules/dayjs/plugin/isSameOrBefore.js"(exports, module) {
|
|
20364
|
-
!(function(
|
|
20365
|
-
"object" == typeof exports && "undefined" != typeof module ? module.exports =
|
|
20364
|
+
!(function(e, i) {
|
|
20365
|
+
"object" == typeof exports && "undefined" != typeof module ? module.exports = i() : "function" == typeof define && define.amd ? define(i) : (e = "undefined" != typeof globalThis ? globalThis : e || self).dayjs_plugin_isSameOrBefore = i();
|
|
20366
20366
|
})(exports, (function() {
|
|
20367
|
-
return function(
|
|
20368
|
-
|
|
20369
|
-
return this.isSame(
|
|
20367
|
+
return function(e, i) {
|
|
20368
|
+
i.prototype.isSameOrBefore = function(e2, i2) {
|
|
20369
|
+
return this.isSame(e2, i2) || this.isBefore(e2, i2);
|
|
20370
20370
|
};
|
|
20371
20371
|
};
|
|
20372
20372
|
}));
|
|
@@ -20493,7 +20493,6 @@ var INPUT_FIELD_TYPES = {
|
|
|
20493
20493
|
var READONLY_FIELD_TYPES = {
|
|
20494
20494
|
HEADER: "HEADER",
|
|
20495
20495
|
RICH_TEXT: "RICH_TEXT",
|
|
20496
|
-
SUBMIT_BUTTON: "SUBMIT_BUTTON",
|
|
20497
20496
|
ECOM_CONTACT_DETAILS: "ECOM_CONTACT_DETAILS",
|
|
20498
20497
|
ECOM_SHIPPING_DETAILS: "ECOM_SHIPPING_DETAILS",
|
|
20499
20498
|
BOOKINGS_HEADER: "BOOKINGS_HEADER",
|
|
@@ -20504,8 +20503,7 @@ var READONLY_FIELD_TYPES = {
|
|
|
20504
20503
|
// ../form-fields/dist/esm/constants/field-types.js
|
|
20505
20504
|
var FIELD_TYPES = {
|
|
20506
20505
|
...INPUT_FIELD_TYPES,
|
|
20507
|
-
...READONLY_FIELD_TYPES
|
|
20508
|
-
};
|
|
20506
|
+
...READONLY_FIELD_TYPES};
|
|
20509
20507
|
|
|
20510
20508
|
// ../form-fields/dist/esm/constants/empty-values.js
|
|
20511
20509
|
var EMPTY_VALUE = null;
|
|
@@ -20557,10 +20555,17 @@ var FormStatusProvider = (_ref) => {
|
|
|
20557
20555
|
setFormStatus
|
|
20558
20556
|
};
|
|
20559
20557
|
}, [currentFormStatus, setFormStatus]);
|
|
20560
|
-
return /* @__PURE__ */
|
|
20558
|
+
return /* @__PURE__ */ React32__default.createElement(FormStatusContext.Provider, {
|
|
20561
20559
|
value: contextValue
|
|
20562
20560
|
}, children);
|
|
20563
20561
|
};
|
|
20562
|
+
function useFormStatus() {
|
|
20563
|
+
const context = useContext(FormStatusContext);
|
|
20564
|
+
if (context === void 0) {
|
|
20565
|
+
throw new Error("useFormStatus must be used within a Form Status provider");
|
|
20566
|
+
}
|
|
20567
|
+
return context;
|
|
20568
|
+
}
|
|
20564
20569
|
var WixRicosViewerContext = /* @__PURE__ */ createContext(void 0);
|
|
20565
20570
|
function useWixRicosViewer() {
|
|
20566
20571
|
const context = useContext(WixRicosViewerContext);
|
|
@@ -20619,22 +20624,22 @@ var ANCHOR_LINK = "anchor-link";
|
|
|
20619
20624
|
|
|
20620
20625
|
// ../../node_modules/@wix/ricos/dist/es/plugin-link/statics/link-viewer-scss.js
|
|
20621
20626
|
var link_viewer_default = {
|
|
20622
|
-
"link": "
|
|
20623
|
-
"linkInViewer": "
|
|
20627
|
+
"link": "FQtO1",
|
|
20628
|
+
"linkInViewer": "rdZDZ"};
|
|
20624
20629
|
|
|
20625
20630
|
// ../../node_modules/@wix/ricos/dist/es/plugin-link/nodeViewDecorators/anchor.js
|
|
20626
20631
|
var decorator = (anchorDecoration, element) => {
|
|
20627
20632
|
const { anchor } = anchorDecoration.anchorData;
|
|
20628
|
-
return /* @__PURE__ */
|
|
20633
|
+
return /* @__PURE__ */ React32__default.createElement(
|
|
20629
20634
|
"a",
|
|
20630
20635
|
{
|
|
20631
20636
|
key: `anchor-${element?.key}`,
|
|
20632
20637
|
target: "_self",
|
|
20633
20638
|
href: `#viewer-${anchor}`,
|
|
20634
20639
|
className: (0, import_classnames.default)(link_viewer_default.link, link_viewer_default.linkInViewer),
|
|
20635
|
-
onClick: (
|
|
20636
|
-
|
|
20637
|
-
|
|
20640
|
+
onClick: (e) => {
|
|
20641
|
+
e.stopPropagation();
|
|
20642
|
+
e.preventDefault();
|
|
20638
20643
|
const anchorString = `viewer-${anchor}`;
|
|
20639
20644
|
const element2 = document.getElementById(anchorString);
|
|
20640
20645
|
addAnchorTagToUrl(anchorString);
|
|
@@ -20683,7 +20688,7 @@ var decorator2 = (element, linkDecoration, contextualData, node) => {
|
|
|
20683
20688
|
type: Node_Type.TEXT,
|
|
20684
20689
|
textData: node.textData
|
|
20685
20690
|
});
|
|
20686
|
-
return /* @__PURE__ */
|
|
20691
|
+
return /* @__PURE__ */ React32__default.createElement(
|
|
20687
20692
|
"a",
|
|
20688
20693
|
{
|
|
20689
20694
|
key: `link=${element.key}`,
|
|
@@ -20742,7 +20747,7 @@ var htmlAttributesPlugin = (_23) => ({
|
|
|
20742
20747
|
type: "",
|
|
20743
20748
|
nodeViewDecorators: [htmlAttributesDecorator],
|
|
20744
20749
|
nodeViewRenderers: {
|
|
20745
|
-
[Node_Type.EXTERNAL]: (__) => /* @__PURE__ */
|
|
20750
|
+
[Node_Type.EXTERNAL]: (__) => /* @__PURE__ */ React32__default.createElement(React32__default.Fragment, null)
|
|
20746
20751
|
}
|
|
20747
20752
|
});
|
|
20748
20753
|
var htmlAttributesDecorator = {
|
|
@@ -20753,13 +20758,13 @@ var htmlAttributesDecorator = {
|
|
|
20753
20758
|
node
|
|
20754
20759
|
} = _ref;
|
|
20755
20760
|
if (((_node$textData = node.textData) == null ? void 0 : _node$textData.text) == null) {
|
|
20756
|
-
return /* @__PURE__ */
|
|
20761
|
+
return /* @__PURE__ */ React32__default.createElement(React32__default.Fragment, null);
|
|
20757
20762
|
}
|
|
20758
20763
|
const props = Object.fromEntries(Object.entries(((_node$externalData = node.externalData) == null ? void 0 : _node$externalData.fields) ?? []).map((_ref2) => {
|
|
20759
20764
|
let [k, v] = _ref2;
|
|
20760
20765
|
return [k, v.stringValue];
|
|
20761
20766
|
}));
|
|
20762
|
-
return /* @__PURE__ */
|
|
20767
|
+
return /* @__PURE__ */ React32__default.createElement("span", props, (_node$textData2 = node.textData) == null ? void 0 : _node$textData2.text);
|
|
20763
20768
|
}
|
|
20764
20769
|
};
|
|
20765
20770
|
|
|
@@ -20778,10 +20783,10 @@ var RicosViewer = (_ref) => {
|
|
|
20778
20783
|
if (!content) {
|
|
20779
20784
|
return null;
|
|
20780
20785
|
}
|
|
20781
|
-
return /* @__PURE__ */
|
|
20786
|
+
return /* @__PURE__ */ React32__default.createElement("div", {
|
|
20782
20787
|
className: (0, import_classnames3.default)(ricos_viewer_module_default.container, className),
|
|
20783
20788
|
"data-hook": dataHook
|
|
20784
|
-
}, /* @__PURE__ */
|
|
20789
|
+
}, /* @__PURE__ */ React32__default.createElement(WixRicosViewer, {
|
|
20785
20790
|
biSettings: {
|
|
20786
20791
|
consumer: "Forms",
|
|
20787
20792
|
platform: "Livesite",
|
|
@@ -20795,7 +20800,7 @@ var RicosViewer = (_ref) => {
|
|
|
20795
20800
|
locale
|
|
20796
20801
|
}));
|
|
20797
20802
|
};
|
|
20798
|
-
var ricos_viewer_default = /* @__PURE__ */
|
|
20803
|
+
var ricos_viewer_default = /* @__PURE__ */ React32__default.memo(RicosViewer);
|
|
20799
20804
|
function useRicosTheme(customTheme) {
|
|
20800
20805
|
return useMemo(() => ({
|
|
20801
20806
|
palette: {
|
|
@@ -20817,7 +20822,7 @@ var UniqueFieldSuffixContextProvider = (_ref) => {
|
|
|
20817
20822
|
compId = "comp"
|
|
20818
20823
|
} = useConfig();
|
|
20819
20824
|
const uniqueId = `${compId}-${parentId.split("-").at(0)}`;
|
|
20820
|
-
return /* @__PURE__ */
|
|
20825
|
+
return /* @__PURE__ */ React32__default.createElement(UniqueFieldSuffixContext.Provider, {
|
|
20821
20826
|
value: uniqueId
|
|
20822
20827
|
}, children);
|
|
20823
20828
|
};
|
|
@@ -20826,14 +20831,14 @@ var FocusedFieldProvider = (_ref) => {
|
|
|
20826
20831
|
let {
|
|
20827
20832
|
children
|
|
20828
20833
|
} = _ref;
|
|
20829
|
-
const [focusedFieldId, setFocusedFieldId] =
|
|
20834
|
+
const [focusedFieldId, setFocusedFieldId] = React32__default.useState(void 0);
|
|
20830
20835
|
const contextValue = useMemo(() => {
|
|
20831
20836
|
return {
|
|
20832
20837
|
focusedFieldId,
|
|
20833
20838
|
setFocusedFieldId
|
|
20834
20839
|
};
|
|
20835
20840
|
}, [focusedFieldId, setFocusedFieldId]);
|
|
20836
|
-
return /* @__PURE__ */
|
|
20841
|
+
return /* @__PURE__ */ React32__default.createElement(FocusedFieldContext.Provider, {
|
|
20837
20842
|
value: contextValue
|
|
20838
20843
|
}, children);
|
|
20839
20844
|
};
|
|
@@ -20861,7 +20866,7 @@ var EventsProvider = (_ref) => {
|
|
|
20861
20866
|
setSubmittedValues(values || {});
|
|
20862
20867
|
}
|
|
20863
20868
|
}), [submitSuccessCounter, submittedValues]);
|
|
20864
|
-
return /* @__PURE__ */
|
|
20869
|
+
return /* @__PURE__ */ React32__default.createElement(EventsContext.Provider, {
|
|
20865
20870
|
value
|
|
20866
20871
|
}, children);
|
|
20867
20872
|
};
|
|
@@ -20902,9 +20907,9 @@ var ScrollProvider = (_ref) => {
|
|
|
20902
20907
|
}
|
|
20903
20908
|
}
|
|
20904
20909
|
}), []);
|
|
20905
|
-
return /* @__PURE__ */
|
|
20910
|
+
return /* @__PURE__ */ React32__default.createElement("div", {
|
|
20906
20911
|
ref: scrollViewRef
|
|
20907
|
-
}, /* @__PURE__ */
|
|
20912
|
+
}, /* @__PURE__ */ React32__default.createElement(ScrollContext.Provider, {
|
|
20908
20913
|
value
|
|
20909
20914
|
}, children));
|
|
20910
20915
|
};
|
|
@@ -20991,13 +20996,13 @@ var __extends = /* @__PURE__ */ (function() {
|
|
|
20991
20996
|
};
|
|
20992
20997
|
})();
|
|
20993
20998
|
var __assign = function() {
|
|
20994
|
-
__assign = Object.assign || function(
|
|
20995
|
-
for (var s,
|
|
20996
|
-
s = arguments[
|
|
20999
|
+
__assign = Object.assign || function(t) {
|
|
21000
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
21001
|
+
s = arguments[i];
|
|
20997
21002
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
20998
|
-
|
|
21003
|
+
t[p] = s[p];
|
|
20999
21004
|
}
|
|
21000
|
-
return
|
|
21005
|
+
return t;
|
|
21001
21006
|
};
|
|
21002
21007
|
return __assign.apply(this, arguments);
|
|
21003
21008
|
};
|
|
@@ -21054,13 +21059,13 @@ var SyntaxError = (
|
|
|
21054
21059
|
}
|
|
21055
21060
|
function describeExpected(expected1) {
|
|
21056
21061
|
var descriptions = expected1.map(describeExpectation);
|
|
21057
|
-
var
|
|
21062
|
+
var i;
|
|
21058
21063
|
var j;
|
|
21059
21064
|
descriptions.sort();
|
|
21060
21065
|
if (descriptions.length > 0) {
|
|
21061
|
-
for (
|
|
21062
|
-
if (descriptions[
|
|
21063
|
-
descriptions[j] = descriptions[
|
|
21066
|
+
for (i = 1, j = 1; i < descriptions.length; i++) {
|
|
21067
|
+
if (descriptions[i - 1] !== descriptions[i]) {
|
|
21068
|
+
descriptions[j] = descriptions[i];
|
|
21064
21069
|
j++;
|
|
21065
21070
|
}
|
|
21066
21071
|
}
|
|
@@ -23341,9 +23346,9 @@ var pegParse = peg$parse;
|
|
|
23341
23346
|
|
|
23342
23347
|
// ../../node_modules/intl-messageformat-parser/lib/normalize.js
|
|
23343
23348
|
var __spreadArrays = function() {
|
|
23344
|
-
for (var s = 0,
|
|
23345
|
-
for (var r = Array(s), k = 0,
|
|
23346
|
-
for (var a = arguments[
|
|
23349
|
+
for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;
|
|
23350
|
+
for (var r = Array(s), k = 0, i = 0; i < il; i++)
|
|
23351
|
+
for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
|
|
23347
23352
|
r[k] = a[j];
|
|
23348
23353
|
return r;
|
|
23349
23354
|
};
|
|
@@ -23358,10 +23363,10 @@ function normalizeHashtagInPlural(els) {
|
|
|
23358
23363
|
var opt = el.options[id];
|
|
23359
23364
|
var matchingLiteralElIndex = -1;
|
|
23360
23365
|
var literalEl = void 0;
|
|
23361
|
-
for (var
|
|
23362
|
-
var el_1 = opt.value[
|
|
23366
|
+
for (var i = 0; i < opt.value.length; i++) {
|
|
23367
|
+
var el_1 = opt.value[i];
|
|
23363
23368
|
if (isLiteralElement(el_1) && PLURAL_HASHTAG_REGEX.test(el_1.value)) {
|
|
23364
|
-
matchingLiteralElIndex =
|
|
23369
|
+
matchingLiteralElIndex = i;
|
|
23365
23370
|
literalEl = el_1;
|
|
23366
23371
|
break;
|
|
23367
23372
|
}
|
|
@@ -23378,13 +23383,13 @@ function normalizeHashtagInPlural(els) {
|
|
|
23378
23383
|
|
|
23379
23384
|
// ../../node_modules/intl-messageformat-parser/lib/skeleton.js
|
|
23380
23385
|
var __assign2 = function() {
|
|
23381
|
-
__assign2 = Object.assign || function(
|
|
23382
|
-
for (var s,
|
|
23383
|
-
s = arguments[
|
|
23386
|
+
__assign2 = Object.assign || function(t) {
|
|
23387
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
23388
|
+
s = arguments[i];
|
|
23384
23389
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
23385
|
-
|
|
23390
|
+
t[p] = s[p];
|
|
23386
23391
|
}
|
|
23387
|
-
return
|
|
23392
|
+
return t;
|
|
23388
23393
|
};
|
|
23389
23394
|
return __assign2.apply(this, arguments);
|
|
23390
23395
|
};
|
|
@@ -23674,9 +23679,9 @@ function parse(input, opts) {
|
|
|
23674
23679
|
|
|
23675
23680
|
// ../../node_modules/intl-format-cache/lib/index.js
|
|
23676
23681
|
var __spreadArrays2 = function() {
|
|
23677
|
-
for (var s = 0,
|
|
23678
|
-
for (var r = Array(s), k = 0,
|
|
23679
|
-
for (var a = arguments[
|
|
23682
|
+
for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;
|
|
23683
|
+
for (var r = Array(s), k = 0, i = 0; i < il; i++)
|
|
23684
|
+
for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
|
|
23680
23685
|
r[k] = a[j];
|
|
23681
23686
|
return r;
|
|
23682
23687
|
};
|
|
@@ -23733,9 +23738,9 @@ var __extends2 = /* @__PURE__ */ (function() {
|
|
|
23733
23738
|
};
|
|
23734
23739
|
})();
|
|
23735
23740
|
var __spreadArrays3 = function() {
|
|
23736
|
-
for (var s = 0,
|
|
23737
|
-
for (var r = Array(s), k = 0,
|
|
23738
|
-
for (var a = arguments[
|
|
23741
|
+
for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;
|
|
23742
|
+
for (var r = Array(s), k = 0, i = 0; i < il; i++)
|
|
23743
|
+
for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
|
|
23739
23744
|
r[k] = a[j];
|
|
23740
23745
|
return r;
|
|
23741
23746
|
};
|
|
@@ -23978,13 +23983,13 @@ function formatHTMLMessage(els, locales, formatters, formats, values, originalMe
|
|
|
23978
23983
|
|
|
23979
23984
|
// ../../node_modules/@wix/wix-i18n-config/node_modules/intl-messageformat/lib/core.js
|
|
23980
23985
|
var __assign3 = function() {
|
|
23981
|
-
__assign3 = Object.assign || function(
|
|
23982
|
-
for (var s,
|
|
23983
|
-
s = arguments[
|
|
23986
|
+
__assign3 = Object.assign || function(t) {
|
|
23987
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
23988
|
+
s = arguments[i];
|
|
23984
23989
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
23985
|
-
|
|
23990
|
+
t[p] = s[p];
|
|
23986
23991
|
}
|
|
23987
|
-
return
|
|
23992
|
+
return t;
|
|
23988
23993
|
};
|
|
23989
23994
|
return __assign3.apply(this, arguments);
|
|
23990
23995
|
};
|
|
@@ -24338,10 +24343,10 @@ function useTranslation() {
|
|
|
24338
24343
|
function generateUUID() {
|
|
24339
24344
|
let uuid = "";
|
|
24340
24345
|
const hexValues = "0123456789abcdef";
|
|
24341
|
-
for (let
|
|
24342
|
-
if (
|
|
24346
|
+
for (let i = 0; i < 36; i++) {
|
|
24347
|
+
if (i === 8 || i === 13 || i === 18 || i === 23) {
|
|
24343
24348
|
uuid += "-";
|
|
24344
|
-
} else if (
|
|
24349
|
+
} else if (i === 14) {
|
|
24345
24350
|
uuid += "4";
|
|
24346
24351
|
} else {
|
|
24347
24352
|
uuid += hexValues.charAt(Math.floor(Math.random() * hexValues.length));
|
|
@@ -24405,7 +24410,7 @@ var ExternalDataProvider = (_ref) => {
|
|
|
24405
24410
|
children,
|
|
24406
24411
|
externalData
|
|
24407
24412
|
} = _ref;
|
|
24408
|
-
return /* @__PURE__ */
|
|
24413
|
+
return /* @__PURE__ */ React32__default.createElement(ExternalDataContext.Provider, {
|
|
24409
24414
|
value: externalData ?? FALLBACK
|
|
24410
24415
|
}, children);
|
|
24411
24416
|
};
|
|
@@ -24417,6 +24422,9 @@ function useExternalData() {
|
|
|
24417
24422
|
return context;
|
|
24418
24423
|
}
|
|
24419
24424
|
var FieldActionsContext = /* @__PURE__ */ createContext({});
|
|
24425
|
+
function useFieldActions() {
|
|
24426
|
+
return useContext(FieldActionsContext);
|
|
24427
|
+
}
|
|
24420
24428
|
var FormFieldsContext = /* @__PURE__ */ createContext(void 0);
|
|
24421
24429
|
function useFormFields() {
|
|
24422
24430
|
const context = useContext(FormFieldsContext);
|
|
@@ -24427,7 +24435,7 @@ function useFormFields() {
|
|
|
24427
24435
|
}
|
|
24428
24436
|
|
|
24429
24437
|
// ../form-fields/dist/esm/ui/form/components/form/form-field.js
|
|
24430
|
-
var
|
|
24438
|
+
var import_extends5 = __toESM(require_extends());
|
|
24431
24439
|
|
|
24432
24440
|
// ../form-fields/dist/esm/ui/form/types/form-view.js
|
|
24433
24441
|
function isInputField2(field) {
|
|
@@ -24514,7 +24522,7 @@ var InputField = (_ref) => {
|
|
|
24514
24522
|
if (!FieldComponent) {
|
|
24515
24523
|
return null;
|
|
24516
24524
|
}
|
|
24517
|
-
return /* @__PURE__ */
|
|
24525
|
+
return /* @__PURE__ */ React32__default.createElement(FieldComponent, (0, import_extends.default)({}, field.properties, {
|
|
24518
24526
|
onChange: handleChange,
|
|
24519
24527
|
onBlur: _onBlur,
|
|
24520
24528
|
onFocus: _onFocus,
|
|
@@ -24550,7 +24558,7 @@ var ReadOnlyField = (_ref) => {
|
|
|
24550
24558
|
if (!FieldComponent) {
|
|
24551
24559
|
return null;
|
|
24552
24560
|
}
|
|
24553
|
-
return /* @__PURE__ */
|
|
24561
|
+
return /* @__PURE__ */ React32__default.createElement(FieldComponent, (0, import_extends2.default)({}, field.properties, {
|
|
24554
24562
|
id: field.id,
|
|
24555
24563
|
externalData,
|
|
24556
24564
|
fieldType: field.fieldType,
|
|
@@ -24592,7 +24600,7 @@ var NestedFormField = (_ref) => {
|
|
|
24592
24600
|
if (!FieldComponent) {
|
|
24593
24601
|
return null;
|
|
24594
24602
|
}
|
|
24595
|
-
return /* @__PURE__ */
|
|
24603
|
+
return /* @__PURE__ */ React32__default.createElement(FieldComponent, (0, import_extends3.default)({}, field.properties, {
|
|
24596
24604
|
onChange: handleChange,
|
|
24597
24605
|
error: fieldError,
|
|
24598
24606
|
errors: fieldErrors,
|
|
@@ -24608,6 +24616,130 @@ var NestedFormField = (_ref) => {
|
|
|
24608
24616
|
}));
|
|
24609
24617
|
};
|
|
24610
24618
|
|
|
24619
|
+
// ../form-fields/dist/esm/ui/form/components/form/submit-button-field.js
|
|
24620
|
+
var import_extends4 = __toESM(require_extends());
|
|
24621
|
+
|
|
24622
|
+
// ../form-fields/dist/esm/fields/submit-button/submit-button/utils.js
|
|
24623
|
+
var getCurrentStep = (form, fieldId) => {
|
|
24624
|
+
var _form$steps;
|
|
24625
|
+
const stepCount = form != null && form.steps ? form.steps.length - 1 : 0;
|
|
24626
|
+
const hasSteps = stepCount > 0;
|
|
24627
|
+
const stepNumber = hasSteps && (form == null || (_form$steps = form.steps) == null ? void 0 : _form$steps.findIndex((step) => {
|
|
24628
|
+
var _step$layout;
|
|
24629
|
+
return (_step$layout = step.layout) == null || (_step$layout = _step$layout.large) == null || (_step$layout = _step$layout.items) == null ? void 0 : _step$layout.find((item) => item.fieldId === fieldId);
|
|
24630
|
+
}));
|
|
24631
|
+
const isLastStep = stepNumber === stepCount;
|
|
24632
|
+
return {
|
|
24633
|
+
hasSteps,
|
|
24634
|
+
stepNumber,
|
|
24635
|
+
isLastStep
|
|
24636
|
+
};
|
|
24637
|
+
};
|
|
24638
|
+
|
|
24639
|
+
// ../form-fields/dist/esm/fields/submit-button/submit-button/use-submit-button.js
|
|
24640
|
+
var useSubmitButton = (_ref) => {
|
|
24641
|
+
let {
|
|
24642
|
+
form,
|
|
24643
|
+
id
|
|
24644
|
+
} = _ref;
|
|
24645
|
+
const {
|
|
24646
|
+
hasSteps,
|
|
24647
|
+
stepNumber,
|
|
24648
|
+
isLastStep
|
|
24649
|
+
} = getCurrentStep(form, id);
|
|
24650
|
+
const {
|
|
24651
|
+
inProgress,
|
|
24652
|
+
actions
|
|
24653
|
+
} = useFieldActions();
|
|
24654
|
+
const [submitInProgress, setSubmitInProgress] = useState(false);
|
|
24655
|
+
const {
|
|
24656
|
+
formStatus
|
|
24657
|
+
} = useFormStatus();
|
|
24658
|
+
const isDisabled = submitInProgress;
|
|
24659
|
+
const isInProgress = inProgress || formStatus === FORM_STATUS.BUSY;
|
|
24660
|
+
const showPreviousButton = hasSteps && stepNumber !== 0;
|
|
24661
|
+
const showNextButton = hasSteps && !isLastStep;
|
|
24662
|
+
const showSubmitButton = !hasSteps || hasSteps && isLastStep;
|
|
24663
|
+
const handleSubmitClick = useCallback(async () => {
|
|
24664
|
+
if (isInProgress) {
|
|
24665
|
+
return;
|
|
24666
|
+
}
|
|
24667
|
+
setSubmitInProgress(true);
|
|
24668
|
+
try {
|
|
24669
|
+
await (actions == null ? void 0 : actions.submitForm());
|
|
24670
|
+
} catch (error2) {
|
|
24671
|
+
console.error(error2);
|
|
24672
|
+
}
|
|
24673
|
+
setSubmitInProgress(false);
|
|
24674
|
+
}, [actions, isInProgress]);
|
|
24675
|
+
return {
|
|
24676
|
+
handleSubmitClick,
|
|
24677
|
+
isDisabled,
|
|
24678
|
+
isInProgress,
|
|
24679
|
+
showPreviousButton,
|
|
24680
|
+
showNextButton,
|
|
24681
|
+
showSubmitButton,
|
|
24682
|
+
hasSteps
|
|
24683
|
+
};
|
|
24684
|
+
};
|
|
24685
|
+
|
|
24686
|
+
// ../form-fields/dist/esm/ui/form/components/form/submit-button-field.js
|
|
24687
|
+
var SubmitButtonField = (_ref) => {
|
|
24688
|
+
let {
|
|
24689
|
+
field,
|
|
24690
|
+
FieldLayout
|
|
24691
|
+
} = _ref;
|
|
24692
|
+
const {
|
|
24693
|
+
submitText,
|
|
24694
|
+
nextText,
|
|
24695
|
+
previousText,
|
|
24696
|
+
text
|
|
24697
|
+
} = field.properties;
|
|
24698
|
+
const componentsById = useFormFields();
|
|
24699
|
+
const externalData = useExternalData();
|
|
24700
|
+
const form = useForm();
|
|
24701
|
+
const {
|
|
24702
|
+
actions
|
|
24703
|
+
} = useFieldActions();
|
|
24704
|
+
const {
|
|
24705
|
+
handleSubmitClick,
|
|
24706
|
+
isDisabled,
|
|
24707
|
+
isInProgress,
|
|
24708
|
+
showPreviousButton,
|
|
24709
|
+
showNextButton,
|
|
24710
|
+
showSubmitButton,
|
|
24711
|
+
hasSteps
|
|
24712
|
+
} = useSubmitButton({
|
|
24713
|
+
form,
|
|
24714
|
+
id: field.id
|
|
24715
|
+
});
|
|
24716
|
+
const submitButtonText = submitText || text || "";
|
|
24717
|
+
const previousButtonText = previousText || "";
|
|
24718
|
+
const nextButtonText = nextText || "";
|
|
24719
|
+
const FieldComponent = componentsById[field.fieldType];
|
|
24720
|
+
if (!FieldComponent) {
|
|
24721
|
+
return null;
|
|
24722
|
+
}
|
|
24723
|
+
return /* @__PURE__ */ React32__default.createElement(FieldComponent, (0, import_extends4.default)({}, field.properties, {
|
|
24724
|
+
id: field.id,
|
|
24725
|
+
externalData,
|
|
24726
|
+
fieldType: field.fieldType,
|
|
24727
|
+
FieldLayout,
|
|
24728
|
+
hasSteps,
|
|
24729
|
+
isDisabled,
|
|
24730
|
+
isInProgress,
|
|
24731
|
+
showPreviousButton,
|
|
24732
|
+
showNextButton,
|
|
24733
|
+
showSubmitButton,
|
|
24734
|
+
submitText: submitButtonText,
|
|
24735
|
+
previousText: previousButtonText,
|
|
24736
|
+
nextText: nextButtonText,
|
|
24737
|
+
onSubmitClick: handleSubmitClick,
|
|
24738
|
+
onPreviousClick: () => actions == null ? void 0 : actions.setPreviousStep(),
|
|
24739
|
+
onNextClick: () => actions == null ? void 0 : actions.setNextStep()
|
|
24740
|
+
}));
|
|
24741
|
+
};
|
|
24742
|
+
|
|
24611
24743
|
// ../form-fields/dist/esm/services/multiline-address.js
|
|
24612
24744
|
var isMultilineAddressField = (field) => {
|
|
24613
24745
|
var _field$view3, _field$view4;
|
|
@@ -24622,18 +24754,24 @@ var FormField = (_ref) => {
|
|
|
24622
24754
|
...rest
|
|
24623
24755
|
} = _ref;
|
|
24624
24756
|
if (!isMultilineAddressField(field) && isNestedFormField(field)) {
|
|
24625
|
-
return /* @__PURE__ */
|
|
24757
|
+
return /* @__PURE__ */ React32__default.createElement(NestedFormField, (0, import_extends5.default)({}, rest, {
|
|
24626
24758
|
field,
|
|
24627
24759
|
FieldLayout
|
|
24628
24760
|
}));
|
|
24629
24761
|
}
|
|
24630
24762
|
if (isInputField2(field)) {
|
|
24631
|
-
return /* @__PURE__ */
|
|
24763
|
+
return /* @__PURE__ */ React32__default.createElement(InputField, (0, import_extends5.default)({}, rest, {
|
|
24764
|
+
field,
|
|
24765
|
+
FieldLayout
|
|
24766
|
+
}));
|
|
24767
|
+
}
|
|
24768
|
+
if (field.fieldType === "SUBMIT_BUTTON") {
|
|
24769
|
+
return /* @__PURE__ */ React32__default.createElement(SubmitButtonField, (0, import_extends5.default)({}, rest, {
|
|
24632
24770
|
field,
|
|
24633
24771
|
FieldLayout
|
|
24634
24772
|
}));
|
|
24635
24773
|
}
|
|
24636
|
-
return /* @__PURE__ */
|
|
24774
|
+
return /* @__PURE__ */ React32__default.createElement(ReadOnlyField, (0, import_extends5.default)({}, rest, {
|
|
24637
24775
|
field,
|
|
24638
24776
|
FieldLayout
|
|
24639
24777
|
}));
|
|
@@ -24649,7 +24787,7 @@ var createFormFields = (_ref) => {
|
|
|
24649
24787
|
FieldLayout
|
|
24650
24788
|
} = _ref;
|
|
24651
24789
|
return form.fields.map((formField) => {
|
|
24652
|
-
const component = /* @__PURE__ */
|
|
24790
|
+
const component = /* @__PURE__ */ React32__default.createElement(FormField, {
|
|
24653
24791
|
key: formField.id,
|
|
24654
24792
|
field: formField,
|
|
24655
24793
|
values,
|
|
@@ -24696,7 +24834,7 @@ var Focusable = (_ref) => {
|
|
|
24696
24834
|
scrollTo(viewRef.current);
|
|
24697
24835
|
}
|
|
24698
24836
|
}, [scrollTo, fieldId, focusedFieldId]);
|
|
24699
|
-
return /* @__PURE__ */
|
|
24837
|
+
return /* @__PURE__ */ React32__default.createElement("div", {
|
|
24700
24838
|
ref: viewRef
|
|
24701
24839
|
}, children);
|
|
24702
24840
|
};
|
|
@@ -24719,17 +24857,17 @@ var Grid = (_ref) => {
|
|
|
24719
24857
|
enableAnimations
|
|
24720
24858
|
} = useConfig();
|
|
24721
24859
|
const reactElementsByRow = getReactElementsByRow(items);
|
|
24722
|
-
return /* @__PURE__ */
|
|
24860
|
+
return /* @__PURE__ */ React32__default.createElement("div", {
|
|
24723
24861
|
className: grid_module_default.container,
|
|
24724
24862
|
dir: isRTL ? "rtl" : ""
|
|
24725
24863
|
}, reactElementsByRow.map((elements, index) => {
|
|
24726
24864
|
var _elements$;
|
|
24727
24865
|
const fieldId = (_elements$ = elements[0]) == null || (_elements$ = _elements$.props) == null || (_elements$ = _elements$.field) == null ? void 0 : _elements$.id;
|
|
24728
24866
|
const key = isMobile && fieldId || index;
|
|
24729
|
-
return /* @__PURE__ */
|
|
24867
|
+
return /* @__PURE__ */ React32__default.createElement(Focusable, {
|
|
24730
24868
|
key: fieldId,
|
|
24731
24869
|
fieldId
|
|
24732
|
-
}, /* @__PURE__ */
|
|
24870
|
+
}, /* @__PURE__ */ React32__default.createElement("div", {
|
|
24733
24871
|
key,
|
|
24734
24872
|
style: getGridStyle({
|
|
24735
24873
|
layout
|
|
@@ -24743,7 +24881,7 @@ var Grid = (_ref) => {
|
|
|
24743
24881
|
function getReactElementsByRow(items) {
|
|
24744
24882
|
const reactElementsByRow = items.reduce((result2, item) => {
|
|
24745
24883
|
const row = item.layout.row;
|
|
24746
|
-
const element = /* @__PURE__ */
|
|
24884
|
+
const element = /* @__PURE__ */ React32__default.cloneElement(item.component, {
|
|
24747
24885
|
key: item.id
|
|
24748
24886
|
});
|
|
24749
24887
|
if (result2[row]) {
|
|
@@ -24770,7 +24908,7 @@ function useFormView() {
|
|
|
24770
24908
|
}
|
|
24771
24909
|
|
|
24772
24910
|
// ../form-fields/dist/esm/field-layout/default-field-layout.js
|
|
24773
|
-
var
|
|
24911
|
+
var import_extends6 = __toESM(require_extends());
|
|
24774
24912
|
|
|
24775
24913
|
// ../form-fields/dist/esm/field-layout/default-field-layout.module.scss
|
|
24776
24914
|
var default_field_layout_module_default = {};
|
|
@@ -24799,7 +24937,7 @@ var DefaultFieldLayout = (_ref) => {
|
|
|
24799
24937
|
const gridColumn = `${layout.column + 1} / span ${layout.width}`;
|
|
24800
24938
|
const [labelRow, inputRow] = rows.map((currentRow) => `${currentRow} / span 1`);
|
|
24801
24939
|
if ("children" in rest) {
|
|
24802
|
-
return /* @__PURE__ */
|
|
24940
|
+
return /* @__PURE__ */ React32__default.createElement("div", (0, import_extends6.default)({
|
|
24803
24941
|
style: {
|
|
24804
24942
|
gridRow,
|
|
24805
24943
|
gridColumn
|
|
@@ -24811,13 +24949,13 @@ var DefaultFieldLayout = (_ref) => {
|
|
|
24811
24949
|
renderInput,
|
|
24812
24950
|
renderDescription
|
|
24813
24951
|
} = rest;
|
|
24814
|
-
return /* @__PURE__ */
|
|
24952
|
+
return /* @__PURE__ */ React32__default.createElement(React32__default.Fragment, null, /* @__PURE__ */ React32__default.createElement("div", {
|
|
24815
24953
|
style: {
|
|
24816
24954
|
gridRow: labelRow,
|
|
24817
24955
|
gridColumn
|
|
24818
24956
|
},
|
|
24819
24957
|
className: default_field_layout_module_default.label
|
|
24820
|
-
}, renderLabel()), /* @__PURE__ */
|
|
24958
|
+
}, renderLabel()), /* @__PURE__ */ React32__default.createElement("div", (0, import_extends6.default)({
|
|
24821
24959
|
style: {
|
|
24822
24960
|
gridRow: inputRow,
|
|
24823
24961
|
gridColumn
|
|
@@ -24843,18 +24981,18 @@ var FormRoot = (_ref) => {
|
|
|
24843
24981
|
errors,
|
|
24844
24982
|
FieldLayout: DefaultFieldLayout
|
|
24845
24983
|
});
|
|
24846
|
-
return /* @__PURE__ */
|
|
24984
|
+
return /* @__PURE__ */ React32__default.createElement(Grid, {
|
|
24847
24985
|
isRTL,
|
|
24848
24986
|
items: formFields,
|
|
24849
24987
|
layout: form.grid
|
|
24850
24988
|
});
|
|
24851
24989
|
};
|
|
24852
24990
|
var Form = (props) => {
|
|
24853
|
-
return /* @__PURE__ */
|
|
24991
|
+
return /* @__PURE__ */ React32__default.createElement(FormViewContext.Provider, {
|
|
24854
24992
|
value: props.form
|
|
24855
|
-
}, /* @__PURE__ */
|
|
24993
|
+
}, /* @__PURE__ */ React32__default.createElement(UniqueFieldSuffixContextProvider, {
|
|
24856
24994
|
parentId: props.form.parentId
|
|
24857
|
-
}, /* @__PURE__ */
|
|
24995
|
+
}, /* @__PURE__ */ React32__default.createElement(FormRoot, props)));
|
|
24858
24996
|
};
|
|
24859
24997
|
|
|
24860
24998
|
// ../form-fields/dist/esm/utils/sort-fields.js
|
|
@@ -26876,12 +27014,12 @@ function isCpfValid(modelValue) {
|
|
|
26876
27014
|
if (!modelValue || CPF_BLACKLIST.includes(modelValue)) {
|
|
26877
27015
|
return false;
|
|
26878
27016
|
}
|
|
26879
|
-
let
|
|
27017
|
+
let i, v1 = 0, v2;
|
|
26880
27018
|
const chars = modelValue.replace(/\D/g, "").split("");
|
|
26881
27019
|
if (chars.length === 11) {
|
|
26882
27020
|
const factors = [10, 9, 8, 7, 6, 5, 4, 3, 2];
|
|
26883
|
-
for (
|
|
26884
|
-
v1 += factors[
|
|
27021
|
+
for (i = 0; i < factors.length; ++i) {
|
|
27022
|
+
v1 += factors[i] * parseInt(chars[i], 10);
|
|
26885
27023
|
}
|
|
26886
27024
|
v1 = 11 - v1 % 11;
|
|
26887
27025
|
if (v1 >= 10) {
|
|
@@ -26891,8 +27029,8 @@ function isCpfValid(modelValue) {
|
|
|
26891
27029
|
return false;
|
|
26892
27030
|
}
|
|
26893
27031
|
v2 = 2 * v1;
|
|
26894
|
-
for (
|
|
26895
|
-
v2 += (factors[
|
|
27032
|
+
for (i = 0; i < factors.length; ++i) {
|
|
27033
|
+
v2 += (factors[i] + 1) * parseInt(chars[i], 10);
|
|
26896
27034
|
}
|
|
26897
27035
|
v2 = 11 - v2 % 11;
|
|
26898
27036
|
if (v2 >= 10) {
|
|
@@ -27938,8 +28076,8 @@ function evaluateOverrideConditionFactory(dateFactory = () => /* @__PURE__ */ ne
|
|
|
27938
28076
|
try {
|
|
27939
28077
|
const rule = getRule(override.condition);
|
|
27940
28078
|
return rule.evaluate(submission);
|
|
27941
|
-
} catch (
|
|
27942
|
-
console.error(
|
|
28079
|
+
} catch (e) {
|
|
28080
|
+
console.error(e);
|
|
27943
28081
|
return false;
|
|
27944
28082
|
}
|
|
27945
28083
|
}
|
|
@@ -28480,7 +28618,7 @@ function clearFieldsWhenHiddenByRule(form, overrides, currentValues, newValues,
|
|
|
28480
28618
|
const fieldCount = (form.fields ?? []).length;
|
|
28481
28619
|
const clearedTargets = [];
|
|
28482
28620
|
let currentForm = applyAllOverrides(form, currentValues, overrides);
|
|
28483
|
-
for (let
|
|
28621
|
+
for (let i = 0; i < fieldCount; i++) {
|
|
28484
28622
|
const newForm = applyAllOverrides(form, newValues, overrides);
|
|
28485
28623
|
const newHiddenTargets = findHiddenTargets(newForm);
|
|
28486
28624
|
const currentHiddenTargets = findHiddenTargets(currentForm);
|
|
@@ -28985,7 +29123,7 @@ var SubmitStatusProvider = ({ children }) => {
|
|
|
28985
29123
|
setSubmitFailureCode,
|
|
28986
29124
|
setSubmitFailureMessage
|
|
28987
29125
|
}), [submitSuccessMessage, submitFailureCode, submitFailureMessage]);
|
|
28988
|
-
return
|
|
29126
|
+
return React32__default.createElement(SubmitStatusContext.Provider, { value }, children);
|
|
28989
29127
|
};
|
|
28990
29128
|
var useSubmitStatus = () => {
|
|
28991
29129
|
const context = useContext(SubmitStatusContext);
|
|
@@ -29011,7 +29149,7 @@ var BiFormSubmissionStatus;
|
|
|
29011
29149
|
})(BiFormSubmissionStatus || (BiFormSubmissionStatus = {}));
|
|
29012
29150
|
var useSubmit = ({ validateAndScrollToError, submitAction, onSubmit, onSubmitSuccess, onSubmitFailure, resetFormValues, values, submitSettings, handleStepChange, navigateToCheckout, onValidate, handleScrollToFirstError }) => {
|
|
29013
29151
|
const { setSubmitSuccessMessage, setSubmitFailureCode, setSubmitFailureMessage } = useSubmitStatus();
|
|
29014
|
-
const { t
|
|
29152
|
+
const { t } = useTranslation();
|
|
29015
29153
|
const { report } = useBi();
|
|
29016
29154
|
const fireSubmitSuccess = useSubmitSuccessTrigger();
|
|
29017
29155
|
const panorama = usePanorama();
|
|
@@ -29023,7 +29161,7 @@ var useSubmit = ({ validateAndScrollToError, submitAction, onSubmit, onSubmitSuc
|
|
|
29023
29161
|
const action = submitSettings?.submitSuccessAction;
|
|
29024
29162
|
const checkoutId = submission?.orderDetails?.checkoutId;
|
|
29025
29163
|
if (checkoutId && navigateToCheckout) {
|
|
29026
|
-
setSubmitSuccessMessage(getCheckoutMessage(
|
|
29164
|
+
setSubmitSuccessMessage(getCheckoutMessage(t("submit.checkout.message")));
|
|
29027
29165
|
navigateToCheckout(checkoutId);
|
|
29028
29166
|
} else if (action === SubmitSuccessAction.THANK_YOU_MESSAGE) {
|
|
29029
29167
|
setSubmitSuccessMessage(submitSettings?.thankYouMessageOptions?.richContent);
|
|
@@ -29041,7 +29179,7 @@ var useSubmit = ({ validateAndScrollToError, submitAction, onSubmit, onSubmitSuc
|
|
|
29041
29179
|
setSubmitFailureCode(void 0);
|
|
29042
29180
|
setSubmitFailureMessage(void 0);
|
|
29043
29181
|
}, [
|
|
29044
|
-
|
|
29182
|
+
t,
|
|
29045
29183
|
submitSettings,
|
|
29046
29184
|
handleStepChange,
|
|
29047
29185
|
navigateToCheckout,
|
|
@@ -29206,26 +29344,26 @@ var SubmitThankYouMessage = ({ messageText }) => {
|
|
|
29206
29344
|
if (!messageText) {
|
|
29207
29345
|
return null;
|
|
29208
29346
|
}
|
|
29209
|
-
return
|
|
29347
|
+
return React32__default.createElement(ricos_viewer_default, { dataHook: DATA_HOOKS.SUBMIT_THANK_YOU_MESSAGE, content: messageText, customTheme, className: submit_status_message_module_default.thankYouMessage });
|
|
29210
29348
|
};
|
|
29211
|
-
var
|
|
29212
|
-
|
|
29213
|
-
var
|
|
29349
|
+
var Error2 = ({ size, ...props }) => /* @__PURE__ */ React32.createElement("svg", { viewBox: "0 0 24 24", fill: "currentColor", width: size || "24", height: size || "24", ...props }, /* @__PURE__ */ React32.createElement("path", { fillRule: "evenodd", d: "M11.5,3 C16.187,3 20,6.813 20,11.5 C20,16.187 16.187,20 11.5,20 C6.813,20 3,16.187 3,11.5 C3,6.813 6.813,3 11.5,3 Z M11.5,4 C7.364,4 4,7.364 4,11.5 C4,15.636 7.364,19 11.5,19 C15.636,19 19,15.636 19,11.5 C19,7.364 15.636,4 11.5,4 Z M12,14 L12,15 L11,15 L11,14 L12,14 Z M12,8 L12,13 L11,13 L11,8 L12,8 Z" }));
|
|
29350
|
+
Error2.displayName = "Error";
|
|
29351
|
+
var Error_default = Error2;
|
|
29214
29352
|
|
|
29215
29353
|
// ../form-viewer/dist/esm/components/submit-status-message/submit-error-message.js
|
|
29216
29354
|
var ERROR_MESSAGE_KEY = "submit.failed.message";
|
|
29217
29355
|
var SubmitErrorMessage = ({ errorMessageCode, errorMessage }) => {
|
|
29218
|
-
const { t
|
|
29356
|
+
const { t, i18n: i18n2 } = useTranslation();
|
|
29219
29357
|
if (!errorMessageCode && !errorMessage) {
|
|
29220
29358
|
return null;
|
|
29221
29359
|
}
|
|
29222
29360
|
const errorMessageKeyByCode = `${ERROR_MESSAGE_KEY}.${errorMessageCode}`;
|
|
29223
29361
|
const errorMessageKey = i18n2.exists(`${TRANSLATIONS_NAMESPACE}:${errorMessageKeyByCode}`) ? errorMessageKeyByCode : ERROR_MESSAGE_KEY;
|
|
29224
|
-
return
|
|
29362
|
+
return React32__default.createElement(
|
|
29225
29363
|
"div",
|
|
29226
29364
|
{ className: submit_status_message_module_default.errorMessage, "data-hook": DATA_HOOKS.SUBMIT_ERROR_MESSAGE },
|
|
29227
|
-
|
|
29228
|
-
errorMessage ||
|
|
29365
|
+
React32__default.createElement(Error_default, { className: submit_status_message_module_default.errorIcon, "aria-hidden": "true" }),
|
|
29366
|
+
errorMessage || t(errorMessageKey)
|
|
29229
29367
|
);
|
|
29230
29368
|
};
|
|
29231
29369
|
|
|
@@ -29245,7 +29383,7 @@ var transitionStyles = {
|
|
|
29245
29383
|
};
|
|
29246
29384
|
var FadeOut = ({ visible, children }) => {
|
|
29247
29385
|
const nodeRef = useRef(null);
|
|
29248
|
-
return
|
|
29386
|
+
return React32__default.createElement(Transition_default, { nodeRef, in: visible, timeout: DURATION }, (state) => React32__default.createElement("div", { ref: nodeRef, style: {
|
|
29249
29387
|
...defaultStyle,
|
|
29250
29388
|
...transitionStyles[state]
|
|
29251
29389
|
} }, [ENTERING, ENTERED, EXITING].includes(state) ? children : null));
|
|
@@ -29254,24 +29392,24 @@ var FadeOut = ({ visible, children }) => {
|
|
|
29254
29392
|
// ../form-viewer/dist/esm/components/submit-status-message/submit-status-message.js
|
|
29255
29393
|
var SubmitStatusMessage = () => {
|
|
29256
29394
|
const { submitSuccessMessage, submitFailureCode, submitFailureMessage } = useSubmitStatus();
|
|
29257
|
-
return
|
|
29395
|
+
return React32__default.createElement(
|
|
29258
29396
|
"div",
|
|
29259
29397
|
{ role: "region", "aria-live": "polite" },
|
|
29260
|
-
|
|
29398
|
+
React32__default.createElement(
|
|
29261
29399
|
FadeOut,
|
|
29262
29400
|
{ visible: !!submitSuccessMessage },
|
|
29263
|
-
|
|
29401
|
+
React32__default.createElement(SubmitThankYouMessage, { messageText: submitSuccessMessage })
|
|
29264
29402
|
),
|
|
29265
|
-
|
|
29403
|
+
React32__default.createElement(SubmitErrorMessage, { errorMessageCode: submitFailureCode, errorMessage: submitFailureMessage })
|
|
29266
29404
|
);
|
|
29267
29405
|
};
|
|
29268
29406
|
var StepTitleA11y = ({ index = 0, total = 0 }) => {
|
|
29269
|
-
const { t
|
|
29270
|
-
const stepTitleA11y =
|
|
29407
|
+
const { t } = useTranslation();
|
|
29408
|
+
const stepTitleA11y = t("form.a11y.step.index.title", {
|
|
29271
29409
|
index: index + 1,
|
|
29272
29410
|
total
|
|
29273
29411
|
});
|
|
29274
|
-
return total > 1 ?
|
|
29412
|
+
return total > 1 ? React32__default.createElement("span", { "aria-label": stepTitleA11y, "aria-live": "polite" }) : null;
|
|
29275
29413
|
};
|
|
29276
29414
|
|
|
29277
29415
|
// ../form-viewer/dist/esm/components/form/form-root.js
|
|
@@ -29416,23 +29554,23 @@ var FormRoot2 = ({
|
|
|
29416
29554
|
if (!formViews?.length || !currentView) {
|
|
29417
29555
|
return null;
|
|
29418
29556
|
}
|
|
29419
|
-
return
|
|
29557
|
+
return React32__default.createElement(
|
|
29420
29558
|
FieldValidationContext.Provider,
|
|
29421
29559
|
{ value: {
|
|
29422
29560
|
validateFields: handleFieldValidation
|
|
29423
29561
|
} },
|
|
29424
|
-
|
|
29562
|
+
React32__default.createElement(
|
|
29425
29563
|
FieldActionsContext.Provider,
|
|
29426
29564
|
{ value: fieldActions },
|
|
29427
|
-
|
|
29565
|
+
React32__default.createElement(
|
|
29428
29566
|
FormStatusProvider,
|
|
29429
29567
|
{ onStatusChange },
|
|
29430
|
-
|
|
29568
|
+
React32__default.createElement(
|
|
29431
29569
|
"div",
|
|
29432
29570
|
{ "data-hook": DATA_HOOKS.FORM_ROOT },
|
|
29433
|
-
|
|
29434
|
-
|
|
29435
|
-
|
|
29571
|
+
React32__default.createElement(Form, { form: currentView, values: normalizedValues, onFieldChange, errors, dataHook: DATA_HOOKS.FORM_ROOT }),
|
|
29572
|
+
React32__default.createElement(StepTitleA11y, { total: formWithOverrides.steps?.length, index: currentStep }),
|
|
29573
|
+
React32__default.createElement(SubmitStatusMessage, null)
|
|
29436
29574
|
)
|
|
29437
29575
|
)
|
|
29438
29576
|
)
|
|
@@ -29509,58 +29647,58 @@ var FormViewerProvider = ({ i18n: i18n2, bi, biFormFillSessionId, form, isMobile
|
|
|
29509
29647
|
enableAnimations
|
|
29510
29648
|
]);
|
|
29511
29649
|
const forcedViewState = useMemo(() => forcedState ?? [], [forcedState]);
|
|
29512
|
-
return
|
|
29650
|
+
return React32__default.createElement(
|
|
29513
29651
|
FormFieldsContext.Provider,
|
|
29514
29652
|
{ value: fields },
|
|
29515
|
-
|
|
29653
|
+
React32__default.createElement(
|
|
29516
29654
|
HttpClientContext.Provider,
|
|
29517
29655
|
{ value: { httpClient } },
|
|
29518
|
-
|
|
29656
|
+
React32__default.createElement(
|
|
29519
29657
|
PanoramaContext.Provider,
|
|
29520
29658
|
{ value: { panorama } },
|
|
29521
|
-
|
|
29659
|
+
React32__default.createElement(
|
|
29522
29660
|
TranslationContext.Provider,
|
|
29523
29661
|
{ value: translations },
|
|
29524
|
-
|
|
29662
|
+
React32__default.createElement(
|
|
29525
29663
|
ScrollProvider,
|
|
29526
29664
|
null,
|
|
29527
|
-
|
|
29665
|
+
React32__default.createElement(
|
|
29528
29666
|
FocusedFieldProvider,
|
|
29529
29667
|
null,
|
|
29530
|
-
|
|
29668
|
+
React32__default.createElement(
|
|
29531
29669
|
FieldInitialDataContext.Provider,
|
|
29532
29670
|
{ value: fieldInitialData },
|
|
29533
|
-
|
|
29671
|
+
React32__default.createElement(
|
|
29534
29672
|
BiContext.Provider,
|
|
29535
29673
|
{ value: formBi },
|
|
29536
|
-
|
|
29674
|
+
React32__default.createElement(
|
|
29537
29675
|
ExternalDataProvider,
|
|
29538
29676
|
{ externalData },
|
|
29539
|
-
|
|
29677
|
+
React32__default.createElement(
|
|
29540
29678
|
ConfigContext.Provider,
|
|
29541
29679
|
{ value: config },
|
|
29542
|
-
|
|
29680
|
+
React32__default.createElement(
|
|
29543
29681
|
ForcedStateContext.Provider,
|
|
29544
29682
|
{ value: forcedViewState },
|
|
29545
|
-
|
|
29683
|
+
React32__default.createElement(
|
|
29546
29684
|
FormContext.Provider,
|
|
29547
29685
|
{ value: form },
|
|
29548
|
-
|
|
29686
|
+
React32__default.createElement(
|
|
29549
29687
|
AddressFormsContext.Provider,
|
|
29550
29688
|
{ value: {
|
|
29551
29689
|
getCountryAddressForm: (country) => getAddressForm(addressTemplates, country),
|
|
29552
29690
|
addressTemplates
|
|
29553
29691
|
} },
|
|
29554
|
-
|
|
29692
|
+
React32__default.createElement(
|
|
29555
29693
|
ExperimentsContext.Provider,
|
|
29556
29694
|
{ value: experiments },
|
|
29557
|
-
|
|
29695
|
+
React32__default.createElement(
|
|
29558
29696
|
EventsProvider,
|
|
29559
29697
|
null,
|
|
29560
|
-
|
|
29698
|
+
React32__default.createElement(
|
|
29561
29699
|
WixRicosViewerContext.Provider,
|
|
29562
29700
|
{ value: WixRicosViewer },
|
|
29563
|
-
|
|
29701
|
+
React32__default.createElement(SubmitStatusProvider, null, children)
|
|
29564
29702
|
)
|
|
29565
29703
|
)
|
|
29566
29704
|
)
|
|
@@ -29599,7 +29737,7 @@ var DisabledFormOverlay = ({ content, isEditor }) => {
|
|
|
29599
29737
|
if (isEditor || !content) {
|
|
29600
29738
|
return null;
|
|
29601
29739
|
}
|
|
29602
|
-
return
|
|
29740
|
+
return React32__default.createElement(ricos_viewer_default, { content, className: disabled_form_overlay_module_default.disabledFormOverlay, customTheme });
|
|
29603
29741
|
};
|
|
29604
29742
|
|
|
29605
29743
|
// ../form-viewer/dist/esm/components/root/form-viewer-static.js
|
|
@@ -29617,23 +29755,23 @@ var FormViewerStatic = forwardRef(({ form, i18n: i18n2, isMobile, isRTL, config
|
|
|
29617
29755
|
return null;
|
|
29618
29756
|
}
|
|
29619
29757
|
const isDisabled = allowFormDisable && formWithValidSteps.properties?.disabled;
|
|
29620
|
-
return
|
|
29621
|
-
|
|
29758
|
+
return React32__default.createElement(
|
|
29759
|
+
React32__default.StrictMode,
|
|
29622
29760
|
null,
|
|
29623
|
-
|
|
29761
|
+
React32__default.createElement(
|
|
29624
29762
|
FormViewerProvider,
|
|
29625
29763
|
{ httpClient, i18n: i18n2, bi, panorama, biFormFillSessionId, form: formWithValidSteps, locale, regionalFormat, isRTL, isMobile, isEditor: config?.isEditor, isComposer: config?.isComposer, externalData, fields, forcedState, instance: config?.instance, experiments, translationNamespace: TRANSLATIONS_NAMESPACE, currency, userData, WixRicosViewer, addressTemplates: config?.addressTemplates, atlasBaseUrl: config?.atlasBaseUrl, fieldInitialData, compId: config?.compId, enableAnimations },
|
|
29626
|
-
|
|
29764
|
+
React32__default.createElement(
|
|
29627
29765
|
"form",
|
|
29628
29766
|
{ "aria-label": formWithValidSteps.properties?.name ?? "", id: `form-${formWithValidSteps.id}`, "data-hook": `form-${formWithValidSteps.id}`, className: (0, import_classnames5.default)({
|
|
29629
29767
|
[form_viewer_static_module_default.readOnly]: readOnly,
|
|
29630
29768
|
[form_viewer_static_module_default.disabled]: isDisabled && !config?.isEditor
|
|
29631
|
-
}), onSubmit: (
|
|
29632
|
-
isDisabled &&
|
|
29633
|
-
|
|
29769
|
+
}), onSubmit: (e) => e.preventDefault() },
|
|
29770
|
+
isDisabled && React32__default.createElement(DisabledFormOverlay, { content: formWithValidSteps.disabledFormMessage, isEditor: config?.isEditor }),
|
|
29771
|
+
React32__default.createElement(
|
|
29634
29772
|
"fieldset",
|
|
29635
29773
|
{ className: form_viewer_static_module_default.fieldsetReset, disabled: readOnly || isDisabled },
|
|
29636
|
-
|
|
29774
|
+
React32__default.createElement(FormRoot2, { form: formWithValidSteps, forwardedRef, config, breakpoint, ...rest })
|
|
29637
29775
|
)
|
|
29638
29776
|
)
|
|
29639
29777
|
)
|
|
@@ -29790,10 +29928,8 @@ var TimeInputMapper = (props) => {
|
|
|
29790
29928
|
};
|
|
29791
29929
|
var TextMapper = (props) => props;
|
|
29792
29930
|
var SubmitButtonMapper = (props) => {
|
|
29793
|
-
const { submitText } = props;
|
|
29794
29931
|
return {
|
|
29795
|
-
...props
|
|
29796
|
-
text: submitText
|
|
29932
|
+
...props
|
|
29797
29933
|
};
|
|
29798
29934
|
};
|
|
29799
29935
|
var ProductListMapper = (props) => {
|
|
@@ -29987,6 +30123,7 @@ function normalizeSchema(obj) {
|
|
|
29987
30123
|
}
|
|
29988
30124
|
return obj;
|
|
29989
30125
|
}
|
|
30126
|
+
var LANGUAGE_CODE = "en";
|
|
29990
30127
|
var mapFieldProps = (fields, mappers) => Object.fromEntries(
|
|
29991
30128
|
Object.entries(fields).map(([fieldType, Component]) => [
|
|
29992
30129
|
fieldType,
|
|
@@ -30005,15 +30142,18 @@ var Form2 = ({
|
|
|
30005
30142
|
values,
|
|
30006
30143
|
onChange,
|
|
30007
30144
|
errors,
|
|
30008
|
-
onValidate
|
|
30145
|
+
onValidate,
|
|
30146
|
+
submitForm
|
|
30009
30147
|
}) => {
|
|
30010
30148
|
const form = normalizeSchema(unformattedForm);
|
|
30011
|
-
const
|
|
30012
|
-
|
|
30013
|
-
|
|
30149
|
+
const i18n2 = initI18n({ locale: LANGUAGE_CODE });
|
|
30150
|
+
const [step, setStep] = useState();
|
|
30151
|
+
const actions = {
|
|
30152
|
+
submitForm,
|
|
30153
|
+
uploadFile: () => {
|
|
30154
|
+
console.log("upload file not implemented");
|
|
30014
30155
|
}
|
|
30015
30156
|
};
|
|
30016
|
-
const i18n2 = initI18n({ locale: siteConfig.locale.languageCode });
|
|
30017
30157
|
const mappedFieldProps = useMemo(
|
|
30018
30158
|
() => mapFieldProps(fields, FIELD_PROP_MAP),
|
|
30019
30159
|
[fields]
|
|
@@ -30025,6 +30165,8 @@ var Form2 = ({
|
|
|
30025
30165
|
return /* @__PURE__ */ jsx(
|
|
30026
30166
|
FormViewerStatic,
|
|
30027
30167
|
{
|
|
30168
|
+
stepId: step,
|
|
30169
|
+
onStepIdChange: setStep,
|
|
30028
30170
|
form,
|
|
30029
30171
|
values,
|
|
30030
30172
|
onChange,
|
|
@@ -30034,9 +30176,10 @@ var Form2 = ({
|
|
|
30034
30176
|
i18n: i18n2,
|
|
30035
30177
|
WixRicosViewer: () => null,
|
|
30036
30178
|
config: {
|
|
30037
|
-
locale:
|
|
30038
|
-
regionalFormat:
|
|
30039
|
-
}
|
|
30179
|
+
locale: LANGUAGE_CODE,
|
|
30180
|
+
regionalFormat: LANGUAGE_CODE
|
|
30181
|
+
},
|
|
30182
|
+
actions
|
|
30040
30183
|
}
|
|
30041
30184
|
);
|
|
30042
30185
|
};
|