gbc-kyc-kit 3.0.3 → 3.0.5
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/gbc-kyc-kit.es.js +394 -241
- package/dist/gbc-kyc-kit.umd.js +71 -71
- package/dist/style.css +1 -1
- package/package.json +3 -2
package/dist/gbc-kyc-kit.es.js
CHANGED
|
@@ -11415,10 +11415,10 @@ var bind$2 = function bind(fn2, thisArg) {
|
|
|
11415
11415
|
};
|
|
11416
11416
|
var bind$1 = bind$2;
|
|
11417
11417
|
var toString$9 = Object.prototype.toString;
|
|
11418
|
-
var kindOf = function(
|
|
11418
|
+
var kindOf = function(cache) {
|
|
11419
11419
|
return function(thing) {
|
|
11420
11420
|
var str = toString$9.call(thing);
|
|
11421
|
-
return
|
|
11421
|
+
return cache[str] || (cache[str] = str.slice(8, -1).toLowerCase());
|
|
11422
11422
|
};
|
|
11423
11423
|
}(/* @__PURE__ */ Object.create(null));
|
|
11424
11424
|
function kindOfTest(type) {
|
|
@@ -12666,7 +12666,7 @@ var axios = axios$2.exports;
|
|
|
12666
12666
|
const ENVIRONMENTS = {
|
|
12667
12667
|
sand: {
|
|
12668
12668
|
auth: {}.VITE_AUTH_URL_SANDBOX,
|
|
12669
|
-
product: "
|
|
12669
|
+
product: "https://gbc-py-core-sandbox-api-products-rtm3lv2joa-uc.a.run.app/",
|
|
12670
12670
|
services: "http://localhost:3002/"
|
|
12671
12671
|
},
|
|
12672
12672
|
stg: {
|
|
@@ -12739,8 +12739,6 @@ function cloneObject(data2) {
|
|
|
12739
12739
|
const isFileListInstance = typeof FileList !== "undefined" ? data2 instanceof FileList : false;
|
|
12740
12740
|
if (data2 instanceof Date) {
|
|
12741
12741
|
copy2 = new Date(data2);
|
|
12742
|
-
} else if (data2 instanceof Set) {
|
|
12743
|
-
copy2 = new Set(data2);
|
|
12744
12742
|
} else if (!(isWeb && (data2 instanceof Blob || isFileListInstance)) && (isArray2 || isObject$6(data2))) {
|
|
12745
12743
|
copy2 = isArray2 ? [] : {};
|
|
12746
12744
|
if (!isArray2 && !isPlainObject$1(data2)) {
|
|
@@ -12757,18 +12755,18 @@ function cloneObject(data2) {
|
|
|
12757
12755
|
}
|
|
12758
12756
|
return copy2;
|
|
12759
12757
|
}
|
|
12760
|
-
var
|
|
12758
|
+
var isKey$4 = (value) => /^\w*$/.test(value);
|
|
12761
12759
|
var isUndefined = (val) => val === void 0;
|
|
12760
|
+
var compact = (value) => Array.isArray(value) ? value.filter(Boolean) : [];
|
|
12761
|
+
var stringToPath$2 = (input) => compact(input.replace(/["|']|\]/g, "").split(/\.|\[/));
|
|
12762
12762
|
var get$2 = (object2, path, defaultValue) => {
|
|
12763
12763
|
if (!path || !isObject$6(object2)) {
|
|
12764
12764
|
return defaultValue;
|
|
12765
12765
|
}
|
|
12766
|
-
const result =
|
|
12766
|
+
const result = (isKey$4(path) ? [path] : stringToPath$2(path)).reduce((result2, key) => isNullOrUndefined(result2) ? result2 : result2[key], object2);
|
|
12767
12767
|
return isUndefined(result) || result === object2 ? isUndefined(object2[path]) ? defaultValue : object2[path] : result;
|
|
12768
12768
|
};
|
|
12769
12769
|
var isBoolean = (value) => typeof value === "boolean";
|
|
12770
|
-
var isKey$4 = (value) => /^\w*$/.test(value);
|
|
12771
|
-
var stringToPath$2 = (input) => compact(input.replace(/["|']|\]/g, "").split(/\.|\[/));
|
|
12772
12770
|
var set$1 = (object2, path, value) => {
|
|
12773
12771
|
let index = -1;
|
|
12774
12772
|
const tempPath = isKey$4(path) ? [path] : stringToPath$2(path);
|
|
@@ -12810,6 +12808,7 @@ const INPUT_VALIDATION_RULES = {
|
|
|
12810
12808
|
validate: "validate"
|
|
12811
12809
|
};
|
|
12812
12810
|
const HookFormContext = React__default$1.createContext(null);
|
|
12811
|
+
HookFormContext.displayName = "HookFormContext";
|
|
12813
12812
|
const useFormContext = () => React__default$1.useContext(HookFormContext);
|
|
12814
12813
|
var getProxyFormState = (formState, control, localProxyFormState, isRoot = true) => {
|
|
12815
12814
|
const result = {
|
|
@@ -12829,6 +12828,7 @@ var getProxyFormState = (formState, control, localProxyFormState, isRoot = true)
|
|
|
12829
12828
|
}
|
|
12830
12829
|
return result;
|
|
12831
12830
|
};
|
|
12831
|
+
const useIsomorphicLayoutEffect = typeof window !== "undefined" ? React__default$1.useLayoutEffect : React__default$1.useEffect;
|
|
12832
12832
|
function useFormState(props) {
|
|
12833
12833
|
const methods = useFormContext();
|
|
12834
12834
|
const { control = methods.control, disabled, name, exact } = props || {};
|
|
@@ -12843,10 +12843,8 @@ function useFormState(props) {
|
|
|
12843
12843
|
isValid: false,
|
|
12844
12844
|
errors: false
|
|
12845
12845
|
});
|
|
12846
|
-
|
|
12847
|
-
|
|
12848
|
-
React__default$1.useEffect(() => control._subscribe({
|
|
12849
|
-
name: _name.current,
|
|
12846
|
+
useIsomorphicLayoutEffect(() => control._subscribe({
|
|
12847
|
+
name,
|
|
12850
12848
|
formState: _localProxyFormState.current,
|
|
12851
12849
|
exact,
|
|
12852
12850
|
callback: (formState2) => {
|
|
@@ -12855,7 +12853,7 @@ function useFormState(props) {
|
|
|
12855
12853
|
...formState2
|
|
12856
12854
|
});
|
|
12857
12855
|
}
|
|
12858
|
-
}), [
|
|
12856
|
+
}), [name, disabled, exact]);
|
|
12859
12857
|
React__default$1.useEffect(() => {
|
|
12860
12858
|
_localProxyFormState.current.isValid && control._setValid(true);
|
|
12861
12859
|
}, [control]);
|
|
@@ -12873,32 +12871,80 @@ var generateWatchOutput = (names, _names, formValues, isGlobal, defaultValue) =>
|
|
|
12873
12871
|
isGlobal && (_names.watchAll = true);
|
|
12874
12872
|
return formValues;
|
|
12875
12873
|
};
|
|
12874
|
+
var isPrimitive = (value) => isNullOrUndefined(value) || !isObjectType(value);
|
|
12875
|
+
function deepEqual(object1, object2, _internal_visited = /* @__PURE__ */ new WeakSet()) {
|
|
12876
|
+
if (isPrimitive(object1) || isPrimitive(object2)) {
|
|
12877
|
+
return object1 === object2;
|
|
12878
|
+
}
|
|
12879
|
+
if (isDateObject(object1) && isDateObject(object2)) {
|
|
12880
|
+
return object1.getTime() === object2.getTime();
|
|
12881
|
+
}
|
|
12882
|
+
const keys1 = Object.keys(object1);
|
|
12883
|
+
const keys2 = Object.keys(object2);
|
|
12884
|
+
if (keys1.length !== keys2.length) {
|
|
12885
|
+
return false;
|
|
12886
|
+
}
|
|
12887
|
+
if (_internal_visited.has(object1) || _internal_visited.has(object2)) {
|
|
12888
|
+
return true;
|
|
12889
|
+
}
|
|
12890
|
+
_internal_visited.add(object1);
|
|
12891
|
+
_internal_visited.add(object2);
|
|
12892
|
+
for (const key of keys1) {
|
|
12893
|
+
const val1 = object1[key];
|
|
12894
|
+
if (!keys2.includes(key)) {
|
|
12895
|
+
return false;
|
|
12896
|
+
}
|
|
12897
|
+
if (key !== "ref") {
|
|
12898
|
+
const val2 = object2[key];
|
|
12899
|
+
if (isDateObject(val1) && isDateObject(val2) || isObject$6(val1) && isObject$6(val2) || Array.isArray(val1) && Array.isArray(val2) ? !deepEqual(val1, val2, _internal_visited) : val1 !== val2) {
|
|
12900
|
+
return false;
|
|
12901
|
+
}
|
|
12902
|
+
}
|
|
12903
|
+
}
|
|
12904
|
+
return true;
|
|
12905
|
+
}
|
|
12876
12906
|
function useWatch(props) {
|
|
12877
12907
|
const methods = useFormContext();
|
|
12878
|
-
const { control = methods.control, name, defaultValue, disabled, exact } = props || {};
|
|
12879
|
-
const _name = React__default$1.useRef(name);
|
|
12908
|
+
const { control = methods.control, name, defaultValue, disabled, exact, compute } = props || {};
|
|
12880
12909
|
const _defaultValue = React__default$1.useRef(defaultValue);
|
|
12881
|
-
|
|
12882
|
-
React__default$1.
|
|
12883
|
-
|
|
12910
|
+
const _compute = React__default$1.useRef(compute);
|
|
12911
|
+
const _computeFormValues = React__default$1.useRef(void 0);
|
|
12912
|
+
_compute.current = compute;
|
|
12913
|
+
const defaultValueMemo = React__default$1.useMemo(() => control._getWatch(name, _defaultValue.current), [control, name]);
|
|
12914
|
+
const [value, updateValue] = React__default$1.useState(_compute.current ? _compute.current(defaultValueMemo) : defaultValueMemo);
|
|
12915
|
+
useIsomorphicLayoutEffect(() => control._subscribe({
|
|
12916
|
+
name,
|
|
12884
12917
|
formState: {
|
|
12885
12918
|
values: true
|
|
12886
12919
|
},
|
|
12887
12920
|
exact,
|
|
12888
|
-
callback: (formState) =>
|
|
12889
|
-
|
|
12890
|
-
|
|
12921
|
+
callback: (formState) => {
|
|
12922
|
+
if (!disabled) {
|
|
12923
|
+
const formValues = generateWatchOutput(name, control._names, formState.values || control._formValues, false, _defaultValue.current);
|
|
12924
|
+
if (_compute.current) {
|
|
12925
|
+
const computedFormValues = _compute.current(formValues);
|
|
12926
|
+
if (!deepEqual(computedFormValues, _computeFormValues.current)) {
|
|
12927
|
+
updateValue(computedFormValues);
|
|
12928
|
+
_computeFormValues.current = computedFormValues;
|
|
12929
|
+
}
|
|
12930
|
+
} else {
|
|
12931
|
+
updateValue(formValues);
|
|
12932
|
+
}
|
|
12933
|
+
}
|
|
12934
|
+
}
|
|
12935
|
+
}), [control, disabled, name, exact]);
|
|
12891
12936
|
React__default$1.useEffect(() => control._removeUnmounted());
|
|
12892
12937
|
return value;
|
|
12893
12938
|
}
|
|
12894
12939
|
function useController(props) {
|
|
12895
12940
|
const methods = useFormContext();
|
|
12896
|
-
const { name, disabled, control = methods.control, shouldUnregister } = props;
|
|
12941
|
+
const { name, disabled, control = methods.control, shouldUnregister, defaultValue } = props;
|
|
12897
12942
|
const isArrayField = isNameInFieldArray(control._names.array, name);
|
|
12943
|
+
const defaultValueMemo = React__default$1.useMemo(() => get$2(control._formValues, name, get$2(control._defaultValues, name, defaultValue)), [control, name, defaultValue]);
|
|
12898
12944
|
const value = useWatch({
|
|
12899
12945
|
control,
|
|
12900
12946
|
name,
|
|
12901
|
-
defaultValue:
|
|
12947
|
+
defaultValue: defaultValueMemo,
|
|
12902
12948
|
exact: true
|
|
12903
12949
|
});
|
|
12904
12950
|
const formState = useFormState({
|
|
@@ -12912,6 +12958,7 @@ function useController(props) {
|
|
|
12912
12958
|
value,
|
|
12913
12959
|
...isBoolean(props.disabled) ? { disabled: props.disabled } : {}
|
|
12914
12960
|
}));
|
|
12961
|
+
_props.current = props;
|
|
12915
12962
|
const fieldState = React__default$1.useMemo(() => Object.defineProperties({}, {
|
|
12916
12963
|
invalid: {
|
|
12917
12964
|
enumerable: true,
|
|
@@ -12952,8 +12999,8 @@ function useController(props) {
|
|
|
12952
12999
|
const field2 = get$2(control._fields, name);
|
|
12953
13000
|
if (field2 && elm) {
|
|
12954
13001
|
field2._f.ref = {
|
|
12955
|
-
focus: () => elm.focus(),
|
|
12956
|
-
select: () => elm.select(),
|
|
13002
|
+
focus: () => elm.focus && elm.focus(),
|
|
13003
|
+
select: () => elm.select && elm.select(),
|
|
12957
13004
|
setCustomValidity: (message) => elm.setCustomValidity(message),
|
|
12958
13005
|
reportValidity: () => elm.reportValidity()
|
|
12959
13006
|
};
|
|
@@ -13040,33 +13087,6 @@ var createSubject = () => {
|
|
|
13040
13087
|
unsubscribe: unsubscribe2
|
|
13041
13088
|
};
|
|
13042
13089
|
};
|
|
13043
|
-
var isPrimitive = (value) => isNullOrUndefined(value) || !isObjectType(value);
|
|
13044
|
-
function deepEqual(object1, object2) {
|
|
13045
|
-
if (isPrimitive(object1) || isPrimitive(object2)) {
|
|
13046
|
-
return object1 === object2;
|
|
13047
|
-
}
|
|
13048
|
-
if (isDateObject(object1) && isDateObject(object2)) {
|
|
13049
|
-
return object1.getTime() === object2.getTime();
|
|
13050
|
-
}
|
|
13051
|
-
const keys1 = Object.keys(object1);
|
|
13052
|
-
const keys2 = Object.keys(object2);
|
|
13053
|
-
if (keys1.length !== keys2.length) {
|
|
13054
|
-
return false;
|
|
13055
|
-
}
|
|
13056
|
-
for (const key of keys1) {
|
|
13057
|
-
const val1 = object1[key];
|
|
13058
|
-
if (!keys2.includes(key)) {
|
|
13059
|
-
return false;
|
|
13060
|
-
}
|
|
13061
|
-
if (key !== "ref") {
|
|
13062
|
-
const val2 = object2[key];
|
|
13063
|
-
if (isDateObject(val1) && isDateObject(val2) || isObject$6(val1) && isObject$6(val2) || Array.isArray(val1) && Array.isArray(val2) ? !deepEqual(val1, val2) : val1 !== val2) {
|
|
13064
|
-
return false;
|
|
13065
|
-
}
|
|
13066
|
-
}
|
|
13067
|
-
}
|
|
13068
|
-
return true;
|
|
13069
|
-
}
|
|
13070
13090
|
var isEmptyObject = (value) => isObject$6(value) && !Object.keys(value).length;
|
|
13071
13091
|
var isFileInput = (element) => element.type === "file";
|
|
13072
13092
|
var isFunction$4 = (value) => typeof value === "function";
|
|
@@ -13262,6 +13282,12 @@ function schemaErrorLookup(errors, _fields, name) {
|
|
|
13262
13282
|
error: foundError
|
|
13263
13283
|
};
|
|
13264
13284
|
}
|
|
13285
|
+
if (foundError && foundError.root && foundError.root.type) {
|
|
13286
|
+
return {
|
|
13287
|
+
name: `${fieldName}.root`,
|
|
13288
|
+
error: foundError.root
|
|
13289
|
+
};
|
|
13290
|
+
}
|
|
13265
13291
|
names.pop();
|
|
13266
13292
|
}
|
|
13267
13293
|
return {
|
|
@@ -13470,6 +13496,7 @@ function createFormControl(props = {}) {
|
|
|
13470
13496
|
let _formState = {
|
|
13471
13497
|
submitCount: 0,
|
|
13472
13498
|
isDirty: false,
|
|
13499
|
+
isReady: false,
|
|
13473
13500
|
isLoading: isFunction$4(_options.defaultValues),
|
|
13474
13501
|
isValidating: false,
|
|
13475
13502
|
isSubmitted: false,
|
|
@@ -13482,8 +13509,8 @@ function createFormControl(props = {}) {
|
|
|
13482
13509
|
errors: _options.errors || {},
|
|
13483
13510
|
disabled: _options.disabled || false
|
|
13484
13511
|
};
|
|
13485
|
-
|
|
13486
|
-
let _defaultValues = isObject$6(_options.defaultValues) || isObject$6(_options.values) ? cloneObject(_options.
|
|
13512
|
+
let _fields = {};
|
|
13513
|
+
let _defaultValues = isObject$6(_options.defaultValues) || isObject$6(_options.values) ? cloneObject(_options.defaultValues || _options.values) || {} : {};
|
|
13487
13514
|
let _formValues = _options.shouldUnregister ? {} : cloneObject(_defaultValues);
|
|
13488
13515
|
let _state = {
|
|
13489
13516
|
action: false,
|
|
@@ -13515,8 +13542,6 @@ function createFormControl(props = {}) {
|
|
|
13515
13542
|
array: createSubject(),
|
|
13516
13543
|
state: createSubject()
|
|
13517
13544
|
};
|
|
13518
|
-
const validationModeBeforeSubmit = getValidationModes(_options.mode);
|
|
13519
|
-
const validationModeAfterSubmit = getValidationModes(_options.reValidateMode);
|
|
13520
13545
|
const shouldDisplayAllAssociatedErrors = _options.criteriaMode === VALIDATION_MODE.all;
|
|
13521
13546
|
const debounce2 = (callback) => (wait) => {
|
|
13522
13547
|
clearTimeout(timer);
|
|
@@ -13724,7 +13749,15 @@ function createFormControl(props = {}) {
|
|
|
13724
13749
|
[...fieldReference.ref.options].forEach((optionRef) => optionRef.selected = fieldValue.includes(optionRef.value));
|
|
13725
13750
|
} else if (fieldReference.refs) {
|
|
13726
13751
|
if (isCheckBoxInput(fieldReference.ref)) {
|
|
13727
|
-
fieldReference.refs.
|
|
13752
|
+
fieldReference.refs.forEach((checkboxRef) => {
|
|
13753
|
+
if (!checkboxRef.defaultChecked || !checkboxRef.disabled) {
|
|
13754
|
+
if (Array.isArray(fieldValue)) {
|
|
13755
|
+
checkboxRef.checked = !!fieldValue.find((data2) => data2 === checkboxRef.value);
|
|
13756
|
+
} else {
|
|
13757
|
+
checkboxRef.checked = fieldValue === checkboxRef.value || !!fieldValue;
|
|
13758
|
+
}
|
|
13759
|
+
}
|
|
13760
|
+
});
|
|
13728
13761
|
} else {
|
|
13729
13762
|
fieldReference.refs.forEach((radioRef) => radioRef.checked = radioRef.value === fieldValue);
|
|
13730
13763
|
}
|
|
@@ -13746,8 +13779,11 @@ function createFormControl(props = {}) {
|
|
|
13746
13779
|
};
|
|
13747
13780
|
const setValues = (name, value, options) => {
|
|
13748
13781
|
for (const fieldKey in value) {
|
|
13782
|
+
if (!value.hasOwnProperty(fieldKey)) {
|
|
13783
|
+
return;
|
|
13784
|
+
}
|
|
13749
13785
|
const fieldValue = value[fieldKey];
|
|
13750
|
-
const fieldName =
|
|
13786
|
+
const fieldName = name + "." + fieldKey;
|
|
13751
13787
|
const field = get$2(_fields, fieldName);
|
|
13752
13788
|
(_names.array.has(name) || isObject$6(fieldValue) || field && !field._f) && !isDateObject(fieldValue) ? setValues(fieldName, fieldValue, options) : setFieldValue(fieldName, fieldValue, options);
|
|
13753
13789
|
}
|
|
@@ -13772,7 +13808,7 @@ function createFormControl(props = {}) {
|
|
|
13772
13808
|
} else {
|
|
13773
13809
|
field && !field._f && !isNullOrUndefined(cloneValue) ? setValues(name, cloneValue, options) : setFieldValue(name, cloneValue, options);
|
|
13774
13810
|
}
|
|
13775
|
-
isWatched(name, _names) && _subjects.state.next({ ..._formState });
|
|
13811
|
+
isWatched(name, _names) && _subjects.state.next({ ..._formState, name });
|
|
13776
13812
|
_subjects.state.next({
|
|
13777
13813
|
name: _state.mount ? name : void 0,
|
|
13778
13814
|
values: cloneObject(_formValues)
|
|
@@ -13787,6 +13823,8 @@ function createFormControl(props = {}) {
|
|
|
13787
13823
|
const _updateIsFieldValueUpdated = (fieldValue) => {
|
|
13788
13824
|
isFieldValueUpdated = Number.isNaN(fieldValue) || isDateObject(fieldValue) && isNaN(fieldValue.getTime()) || deepEqual(fieldValue, get$2(_formValues, name, fieldValue));
|
|
13789
13825
|
};
|
|
13826
|
+
const validationModeBeforeSubmit = getValidationModes(_options.mode);
|
|
13827
|
+
const validationModeAfterSubmit = getValidationModes(_options.reValidateMode);
|
|
13790
13828
|
if (field) {
|
|
13791
13829
|
let error;
|
|
13792
13830
|
let isValid;
|
|
@@ -13918,7 +13956,7 @@ function createFormControl(props = {}) {
|
|
|
13918
13956
|
options && options.shouldFocus && ref && ref.focus && ref.focus();
|
|
13919
13957
|
};
|
|
13920
13958
|
const watch = (name, defaultValue) => isFunction$4(name) ? _subjects.state.subscribe({
|
|
13921
|
-
next: (payload) => name(_getWatch(void 0, defaultValue), payload)
|
|
13959
|
+
next: (payload) => "values" in payload && name(_getWatch(void 0, defaultValue), payload)
|
|
13922
13960
|
}) : _getWatch(name, defaultValue, true);
|
|
13923
13961
|
const _subscribe = (props2) => _subjects.state.subscribe({
|
|
13924
13962
|
next: (formState) => {
|
|
@@ -13926,7 +13964,8 @@ function createFormControl(props = {}) {
|
|
|
13926
13964
|
props2.callback({
|
|
13927
13965
|
values: { ..._formValues },
|
|
13928
13966
|
..._formState,
|
|
13929
|
-
...formState
|
|
13967
|
+
...formState,
|
|
13968
|
+
defaultValues: _defaultValues
|
|
13930
13969
|
});
|
|
13931
13970
|
}
|
|
13932
13971
|
}
|
|
@@ -14068,13 +14107,13 @@ function createFormControl(props = {}) {
|
|
|
14068
14107
|
if (_options.resolver) {
|
|
14069
14108
|
const { errors, values: values2 } = await _runSchema();
|
|
14070
14109
|
_formState.errors = errors;
|
|
14071
|
-
fieldValues = values2;
|
|
14110
|
+
fieldValues = cloneObject(values2);
|
|
14072
14111
|
} else {
|
|
14073
14112
|
await executeBuiltInValidation(_fields);
|
|
14074
14113
|
}
|
|
14075
14114
|
if (_names.disabled.size) {
|
|
14076
14115
|
for (const name of _names.disabled) {
|
|
14077
|
-
|
|
14116
|
+
unset(fieldValues, name);
|
|
14078
14117
|
}
|
|
14079
14118
|
}
|
|
14080
14119
|
unset(_formState.errors, "root");
|
|
@@ -14160,11 +14199,15 @@ function createFormControl(props = {}) {
|
|
|
14160
14199
|
}
|
|
14161
14200
|
}
|
|
14162
14201
|
}
|
|
14163
|
-
|
|
14164
|
-
|
|
14202
|
+
if (keepStateOptions.keepFieldsRef) {
|
|
14203
|
+
for (const fieldName of _names.mount) {
|
|
14204
|
+
setValue(fieldName, get$2(values2, fieldName));
|
|
14205
|
+
}
|
|
14206
|
+
} else {
|
|
14207
|
+
_fields = {};
|
|
14165
14208
|
}
|
|
14166
14209
|
}
|
|
14167
|
-
_formValues = cloneObject(values2);
|
|
14210
|
+
_formValues = _options.shouldUnregister ? keepStateOptions.keepDefaultValues ? cloneObject(_defaultValues) : {} : cloneObject(values2);
|
|
14168
14211
|
_subjects.array.next({
|
|
14169
14212
|
values: { ...values2 }
|
|
14170
14213
|
});
|
|
@@ -14227,6 +14270,7 @@ function createFormControl(props = {}) {
|
|
|
14227
14270
|
setError,
|
|
14228
14271
|
_subscribe,
|
|
14229
14272
|
_runSchema,
|
|
14273
|
+
_focusError,
|
|
14230
14274
|
_getWatch,
|
|
14231
14275
|
_getDirty,
|
|
14232
14276
|
_setValid,
|
|
@@ -14311,25 +14355,61 @@ function useForm(props = {}) {
|
|
|
14311
14355
|
validatingFields: {},
|
|
14312
14356
|
errors: props.errors || {},
|
|
14313
14357
|
disabled: props.disabled || false,
|
|
14358
|
+
isReady: false,
|
|
14314
14359
|
defaultValues: isFunction$4(props.defaultValues) ? void 0 : props.defaultValues
|
|
14315
14360
|
});
|
|
14316
14361
|
if (!_formControl.current) {
|
|
14317
|
-
|
|
14318
|
-
|
|
14319
|
-
|
|
14320
|
-
|
|
14321
|
-
|
|
14322
|
-
|
|
14362
|
+
if (props.formControl) {
|
|
14363
|
+
_formControl.current = {
|
|
14364
|
+
...props.formControl,
|
|
14365
|
+
formState
|
|
14366
|
+
};
|
|
14367
|
+
if (props.defaultValues && !isFunction$4(props.defaultValues)) {
|
|
14368
|
+
props.formControl.reset(props.defaultValues, props.resetOptions);
|
|
14369
|
+
}
|
|
14370
|
+
} else {
|
|
14371
|
+
const { formControl, ...rest } = createFormControl(props);
|
|
14372
|
+
_formControl.current = {
|
|
14373
|
+
...rest,
|
|
14374
|
+
formState
|
|
14375
|
+
};
|
|
14323
14376
|
}
|
|
14324
14377
|
}
|
|
14325
14378
|
const control = _formControl.current.control;
|
|
14326
14379
|
control._options = props;
|
|
14327
|
-
|
|
14328
|
-
|
|
14329
|
-
|
|
14330
|
-
|
|
14331
|
-
|
|
14380
|
+
useIsomorphicLayoutEffect(() => {
|
|
14381
|
+
const sub = control._subscribe({
|
|
14382
|
+
formState: control._proxyFormState,
|
|
14383
|
+
callback: () => updateFormState({ ...control._formState }),
|
|
14384
|
+
reRenderRoot: true
|
|
14385
|
+
});
|
|
14386
|
+
updateFormState((data2) => ({
|
|
14387
|
+
...data2,
|
|
14388
|
+
isReady: true
|
|
14389
|
+
}));
|
|
14390
|
+
control._formState.isReady = true;
|
|
14391
|
+
return sub;
|
|
14392
|
+
}, [control]);
|
|
14332
14393
|
React__default$1.useEffect(() => control._disableForm(props.disabled), [control, props.disabled]);
|
|
14394
|
+
React__default$1.useEffect(() => {
|
|
14395
|
+
if (props.mode) {
|
|
14396
|
+
control._options.mode = props.mode;
|
|
14397
|
+
}
|
|
14398
|
+
if (props.reValidateMode) {
|
|
14399
|
+
control._options.reValidateMode = props.reValidateMode;
|
|
14400
|
+
}
|
|
14401
|
+
}, [control, props.mode, props.reValidateMode]);
|
|
14402
|
+
React__default$1.useEffect(() => {
|
|
14403
|
+
if (props.errors) {
|
|
14404
|
+
control._setErrors(props.errors);
|
|
14405
|
+
control._focusError();
|
|
14406
|
+
}
|
|
14407
|
+
}, [control, props.errors]);
|
|
14408
|
+
React__default$1.useEffect(() => {
|
|
14409
|
+
props.shouldUnregister && control._subjects.state.next({
|
|
14410
|
+
values: control._getWatch()
|
|
14411
|
+
});
|
|
14412
|
+
}, [control, props.shouldUnregister]);
|
|
14333
14413
|
React__default$1.useEffect(() => {
|
|
14334
14414
|
if (control._proxyFormState.isDirty) {
|
|
14335
14415
|
const isDirty = control._getDirty();
|
|
@@ -14342,18 +14422,16 @@ function useForm(props = {}) {
|
|
|
14342
14422
|
}, [control, formState.isDirty]);
|
|
14343
14423
|
React__default$1.useEffect(() => {
|
|
14344
14424
|
if (props.values && !deepEqual(props.values, _values.current)) {
|
|
14345
|
-
control._reset(props.values,
|
|
14425
|
+
control._reset(props.values, {
|
|
14426
|
+
keepFieldsRef: true,
|
|
14427
|
+
...control._options.resetOptions
|
|
14428
|
+
});
|
|
14346
14429
|
_values.current = props.values;
|
|
14347
14430
|
updateFormState((state) => ({ ...state }));
|
|
14348
14431
|
} else {
|
|
14349
14432
|
control._resetDefaultValues();
|
|
14350
14433
|
}
|
|
14351
|
-
}, [props.values
|
|
14352
|
-
React__default$1.useEffect(() => {
|
|
14353
|
-
if (props.errors && !isEmptyObject(props.errors)) {
|
|
14354
|
-
control._setErrors(props.errors);
|
|
14355
|
-
}
|
|
14356
|
-
}, [props.errors, control]);
|
|
14434
|
+
}, [control, props.values]);
|
|
14357
14435
|
React__default$1.useEffect(() => {
|
|
14358
14436
|
if (!control._state.mount) {
|
|
14359
14437
|
control._setValid();
|
|
@@ -14365,11 +14443,6 @@ function useForm(props = {}) {
|
|
|
14365
14443
|
}
|
|
14366
14444
|
control._removeUnmounted();
|
|
14367
14445
|
});
|
|
14368
|
-
React__default$1.useEffect(() => {
|
|
14369
|
-
props.shouldUnregister && control._subjects.state.next({
|
|
14370
|
-
values: control._getWatch()
|
|
14371
|
-
});
|
|
14372
|
-
}, [props.shouldUnregister, control]);
|
|
14373
14446
|
_formControl.current.formState = getProxyFormState(formState, control);
|
|
14374
14447
|
return _formControl.current;
|
|
14375
14448
|
}
|
|
@@ -14887,12 +14960,12 @@ function memoize$3(func, resolver) {
|
|
|
14887
14960
|
throw new TypeError(FUNC_ERROR_TEXT);
|
|
14888
14961
|
}
|
|
14889
14962
|
var memoized = function() {
|
|
14890
|
-
var args = arguments, key = resolver ? resolver.apply(this, args) : args[0],
|
|
14891
|
-
if (
|
|
14892
|
-
return
|
|
14963
|
+
var args = arguments, key = resolver ? resolver.apply(this, args) : args[0], cache = memoized.cache;
|
|
14964
|
+
if (cache.has(key)) {
|
|
14965
|
+
return cache.get(key);
|
|
14893
14966
|
}
|
|
14894
14967
|
var result = func.apply(this, args);
|
|
14895
|
-
memoized.cache =
|
|
14968
|
+
memoized.cache = cache.set(key, result) || cache;
|
|
14896
14969
|
return result;
|
|
14897
14970
|
};
|
|
14898
14971
|
memoized.cache = new (memoize$3.Cache || MapCache$2)();
|
|
@@ -14904,12 +14977,12 @@ var memoize$2 = memoize_1;
|
|
|
14904
14977
|
var MAX_MEMOIZE_SIZE = 500;
|
|
14905
14978
|
function memoizeCapped$1(func) {
|
|
14906
14979
|
var result = memoize$2(func, function(key) {
|
|
14907
|
-
if (
|
|
14908
|
-
|
|
14980
|
+
if (cache.size === MAX_MEMOIZE_SIZE) {
|
|
14981
|
+
cache.clear();
|
|
14909
14982
|
}
|
|
14910
14983
|
return key;
|
|
14911
14984
|
});
|
|
14912
|
-
var
|
|
14985
|
+
var cache = result.cache;
|
|
14913
14986
|
return result;
|
|
14914
14987
|
}
|
|
14915
14988
|
var _memoizeCapped = memoizeCapped$1;
|
|
@@ -15425,8 +15498,8 @@ function arraySome$1(array2, predicate) {
|
|
|
15425
15498
|
return false;
|
|
15426
15499
|
}
|
|
15427
15500
|
var _arraySome = arraySome$1;
|
|
15428
|
-
function cacheHas$1(
|
|
15429
|
-
return
|
|
15501
|
+
function cacheHas$1(cache, key) {
|
|
15502
|
+
return cache.has(key);
|
|
15430
15503
|
}
|
|
15431
15504
|
var _cacheHas = cacheHas$1;
|
|
15432
15505
|
var SetCache = _SetCache, arraySome = _arraySome, cacheHas = _cacheHas;
|
|
@@ -15897,7 +15970,7 @@ Cache.prototype.set = function(key, value) {
|
|
|
15897
15970
|
return this._values[key] = value;
|
|
15898
15971
|
};
|
|
15899
15972
|
var SPLIT_REGEX = /[^.^\]^[]+|(?=\[\]|\.\.)/g, DIGIT_REGEX = /^\d+$/, LEAD_DIGIT_REGEX = /^\d/, SPEC_CHAR_REGEX = /[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g, CLEAN_QUOTES_REGEX = /^\s*(['"]?)(.*?)(\1)\s*$/, MAX_CACHE_SIZE = 512;
|
|
15900
|
-
var pathCache = new Cache(MAX_CACHE_SIZE), setCache = new Cache(MAX_CACHE_SIZE), getCache = new Cache(MAX_CACHE_SIZE);
|
|
15973
|
+
var pathCache = new Cache(MAX_CACHE_SIZE), setCache = new Cache(MAX_CACHE_SIZE), getCache$1 = new Cache(MAX_CACHE_SIZE);
|
|
15901
15974
|
var propertyExpr = {
|
|
15902
15975
|
Cache,
|
|
15903
15976
|
split,
|
|
@@ -15920,7 +15993,7 @@ var propertyExpr = {
|
|
|
15920
15993
|
},
|
|
15921
15994
|
getter: function(path, safe) {
|
|
15922
15995
|
var parts = normalizePath(path);
|
|
15923
|
-
return getCache.get(path) || getCache.set(path, function getter(data2) {
|
|
15996
|
+
return getCache$1.get(path) || getCache$1.set(path, function getter(data2) {
|
|
15924
15997
|
var index = 0, len = parts.length;
|
|
15925
15998
|
while (index < len) {
|
|
15926
15999
|
if (data2 != null || !safe)
|
|
@@ -18155,8 +18228,8 @@ const saveDataToDB = async ({ data: data2, component, eventId, inProduction, sou
|
|
|
18155
18228
|
method: "POST",
|
|
18156
18229
|
inProduction,
|
|
18157
18230
|
path: `api-hub/v1/events/register/${component}/${source2}/${clientId}/${eventId}`,
|
|
18158
|
-
service: "product",
|
|
18159
18231
|
bodyParams: data2,
|
|
18232
|
+
service: "product",
|
|
18160
18233
|
customHeaders
|
|
18161
18234
|
};
|
|
18162
18235
|
try {
|
|
@@ -18188,7 +18261,6 @@ const BlackListController = (clientId, authorize, inProduction, source2, eventId
|
|
|
18188
18261
|
const [csvFile, setCsvFile] = useState(null);
|
|
18189
18262
|
const fileInputRef = useRef(null);
|
|
18190
18263
|
const [batchData, setBatchData] = useState({});
|
|
18191
|
-
console.log(inProduction);
|
|
18192
18264
|
useEffect(() => {
|
|
18193
18265
|
var _a;
|
|
18194
18266
|
if (countryCodeAllowed && (geolocation == null ? void 0 : geolocation.data_connection.isocode)) {
|
|
@@ -18241,7 +18313,6 @@ const BlackListController = (clientId, authorize, inProduction, source2, eventId
|
|
|
18241
18313
|
birth_date: ""
|
|
18242
18314
|
}
|
|
18243
18315
|
});
|
|
18244
|
-
console.log(errorsDoc);
|
|
18245
18316
|
const onSendSubmitDocument = async (data2) => {
|
|
18246
18317
|
var _a, _b;
|
|
18247
18318
|
const {
|
|
@@ -18358,8 +18429,9 @@ const BlackListController = (clientId, authorize, inProduction, source2, eventId
|
|
|
18358
18429
|
};
|
|
18359
18430
|
const parseReq = {
|
|
18360
18431
|
method: "POST",
|
|
18361
|
-
path: "api/v1/
|
|
18432
|
+
path: "api/v1/providers/acuant/search_batch",
|
|
18362
18433
|
customHeaders,
|
|
18434
|
+
service: "services",
|
|
18363
18435
|
inProduction,
|
|
18364
18436
|
bodyParams: {
|
|
18365
18437
|
csvFile
|
|
@@ -20257,11 +20329,11 @@ function rulesheet(callback) {
|
|
|
20257
20329
|
};
|
|
20258
20330
|
}
|
|
20259
20331
|
function memoize$1(fn2) {
|
|
20260
|
-
var
|
|
20332
|
+
var cache = /* @__PURE__ */ Object.create(null);
|
|
20261
20333
|
return function(arg) {
|
|
20262
|
-
if (
|
|
20263
|
-
|
|
20264
|
-
return
|
|
20334
|
+
if (cache[arg] === void 0)
|
|
20335
|
+
cache[arg] = fn2(arg);
|
|
20336
|
+
return cache[arg];
|
|
20265
20337
|
};
|
|
20266
20338
|
}
|
|
20267
20339
|
var identifierWithPointTracking = function identifierWithPointTracking2(begin, points, index) {
|
|
@@ -20541,11 +20613,11 @@ var createCache = function createCache2(options) {
|
|
|
20541
20613
|
currentSheet = sheet;
|
|
20542
20614
|
stylis(selector ? selector + "{" + serialized.styles + "}" : serialized.styles);
|
|
20543
20615
|
if (shouldCache) {
|
|
20544
|
-
|
|
20616
|
+
cache.inserted[serialized.name] = true;
|
|
20545
20617
|
}
|
|
20546
20618
|
};
|
|
20547
20619
|
}
|
|
20548
|
-
var
|
|
20620
|
+
var cache = {
|
|
20549
20621
|
key,
|
|
20550
20622
|
sheet: new StyleSheet({
|
|
20551
20623
|
key,
|
|
@@ -20560,8 +20632,8 @@ var createCache = function createCache2(options) {
|
|
|
20560
20632
|
registered: {},
|
|
20561
20633
|
insert: _insert
|
|
20562
20634
|
};
|
|
20563
|
-
|
|
20564
|
-
return
|
|
20635
|
+
cache.sheet.hydrate(nodesToHydrate);
|
|
20636
|
+
return cache;
|
|
20565
20637
|
};
|
|
20566
20638
|
var reactIs$2 = { exports: {} };
|
|
20567
20639
|
var reactIs_production_min = {};
|
|
@@ -20695,19 +20767,19 @@ function getRegisteredStyles(registered, registeredStyles, classNames) {
|
|
|
20695
20767
|
});
|
|
20696
20768
|
return rawClassName;
|
|
20697
20769
|
}
|
|
20698
|
-
var registerStyles = function registerStyles2(
|
|
20699
|
-
var className =
|
|
20700
|
-
if ((isStringTag2 === false || isBrowser$1 === false) &&
|
|
20701
|
-
|
|
20770
|
+
var registerStyles = function registerStyles2(cache, serialized, isStringTag2) {
|
|
20771
|
+
var className = cache.key + "-" + serialized.name;
|
|
20772
|
+
if ((isStringTag2 === false || isBrowser$1 === false) && cache.registered[className] === void 0) {
|
|
20773
|
+
cache.registered[className] = serialized.styles;
|
|
20702
20774
|
}
|
|
20703
20775
|
};
|
|
20704
|
-
var insertStyles = function insertStyles2(
|
|
20705
|
-
registerStyles(
|
|
20706
|
-
var className =
|
|
20707
|
-
if (
|
|
20776
|
+
var insertStyles = function insertStyles2(cache, serialized, isStringTag2) {
|
|
20777
|
+
registerStyles(cache, serialized, isStringTag2);
|
|
20778
|
+
var className = cache.key + "-" + serialized.name;
|
|
20779
|
+
if (cache.inserted[serialized.name] === void 0) {
|
|
20708
20780
|
var current = serialized;
|
|
20709
20781
|
do {
|
|
20710
|
-
|
|
20782
|
+
cache.insert(serialized === current ? "." + className : "", current, cache.sheet, true);
|
|
20711
20783
|
current = current.next;
|
|
20712
20784
|
} while (current !== void 0);
|
|
20713
20785
|
}
|
|
@@ -20970,8 +21042,8 @@ var EmotionCacheContext = /* @__PURE__ */ React$2.createContext(
|
|
|
20970
21042
|
var CacheProvider = EmotionCacheContext.Provider;
|
|
20971
21043
|
var withEmotionCache = function withEmotionCache2(func) {
|
|
20972
21044
|
return /* @__PURE__ */ forwardRef(function(props, ref) {
|
|
20973
|
-
var
|
|
20974
|
-
return func(props,
|
|
21045
|
+
var cache = useContext(EmotionCacheContext);
|
|
21046
|
+
return func(props, cache, ref);
|
|
20975
21047
|
});
|
|
20976
21048
|
};
|
|
20977
21049
|
var ThemeContext = /* @__PURE__ */ React$2.createContext({});
|
|
@@ -20988,28 +21060,28 @@ var createEmotionProps = function createEmotionProps2(type, props) {
|
|
|
20988
21060
|
return newProps;
|
|
20989
21061
|
};
|
|
20990
21062
|
var Insertion$1 = function Insertion(_ref) {
|
|
20991
|
-
var
|
|
20992
|
-
registerStyles(
|
|
21063
|
+
var cache = _ref.cache, serialized = _ref.serialized, isStringTag2 = _ref.isStringTag;
|
|
21064
|
+
registerStyles(cache, serialized, isStringTag2);
|
|
20993
21065
|
useInsertionEffectAlwaysWithSyncFallback(function() {
|
|
20994
|
-
return insertStyles(
|
|
21066
|
+
return insertStyles(cache, serialized, isStringTag2);
|
|
20995
21067
|
});
|
|
20996
21068
|
return null;
|
|
20997
21069
|
};
|
|
20998
|
-
var Emotion = /* @__PURE__ */ withEmotionCache(function(props,
|
|
21070
|
+
var Emotion = /* @__PURE__ */ withEmotionCache(function(props, cache, ref) {
|
|
20999
21071
|
var cssProp = props.css;
|
|
21000
|
-
if (typeof cssProp === "string" &&
|
|
21001
|
-
cssProp =
|
|
21072
|
+
if (typeof cssProp === "string" && cache.registered[cssProp] !== void 0) {
|
|
21073
|
+
cssProp = cache.registered[cssProp];
|
|
21002
21074
|
}
|
|
21003
21075
|
var WrappedComponent = props[typePropName];
|
|
21004
21076
|
var registeredStyles = [cssProp];
|
|
21005
21077
|
var className = "";
|
|
21006
21078
|
if (typeof props.className === "string") {
|
|
21007
|
-
className = getRegisteredStyles(
|
|
21079
|
+
className = getRegisteredStyles(cache.registered, registeredStyles, props.className);
|
|
21008
21080
|
} else if (props.className != null) {
|
|
21009
21081
|
className = props.className + " ";
|
|
21010
21082
|
}
|
|
21011
21083
|
var serialized = serializeStyles(registeredStyles, void 0, React$2.useContext(ThemeContext));
|
|
21012
|
-
className +=
|
|
21084
|
+
className += cache.key + "-" + serialized.name;
|
|
21013
21085
|
var newProps = {};
|
|
21014
21086
|
for (var _key2 in props) {
|
|
21015
21087
|
if (hasOwn.call(props, _key2) && _key2 !== "css" && _key2 !== typePropName && !isDevelopment$1) {
|
|
@@ -21021,7 +21093,7 @@ var Emotion = /* @__PURE__ */ withEmotionCache(function(props, cache2, ref) {
|
|
|
21021
21093
|
newProps.ref = ref;
|
|
21022
21094
|
}
|
|
21023
21095
|
return /* @__PURE__ */ React$2.createElement(React$2.Fragment, null, /* @__PURE__ */ React$2.createElement(Insertion$1, {
|
|
21024
|
-
cache
|
|
21096
|
+
cache,
|
|
21025
21097
|
serialized,
|
|
21026
21098
|
isStringTag: typeof WrappedComponent === "string"
|
|
21027
21099
|
}), /* @__PURE__ */ React$2.createElement(WrappedComponent, newProps));
|
|
@@ -21060,22 +21132,22 @@ var jsx = function jsx2(type, props) {
|
|
|
21060
21132
|
(function(_JSX) {
|
|
21061
21133
|
})(JSX || (JSX = _jsx.JSX || (_jsx.JSX = {})));
|
|
21062
21134
|
})(jsx || (jsx = {}));
|
|
21063
|
-
var Global = /* @__PURE__ */ withEmotionCache(function(props,
|
|
21135
|
+
var Global = /* @__PURE__ */ withEmotionCache(function(props, cache) {
|
|
21064
21136
|
var styles2 = props.styles;
|
|
21065
21137
|
var serialized = serializeStyles([styles2], void 0, React$2.useContext(ThemeContext));
|
|
21066
21138
|
var sheetRef = React$2.useRef();
|
|
21067
21139
|
useInsertionEffectWithLayoutFallback(function() {
|
|
21068
|
-
var key =
|
|
21069
|
-
var sheet = new
|
|
21140
|
+
var key = cache.key + "-global";
|
|
21141
|
+
var sheet = new cache.sheet.constructor({
|
|
21070
21142
|
key,
|
|
21071
|
-
nonce:
|
|
21072
|
-
container:
|
|
21073
|
-
speedy:
|
|
21143
|
+
nonce: cache.sheet.nonce,
|
|
21144
|
+
container: cache.sheet.container,
|
|
21145
|
+
speedy: cache.sheet.isSpeedy
|
|
21074
21146
|
});
|
|
21075
21147
|
var rehydrating = false;
|
|
21076
21148
|
var node2 = document.querySelector('style[data-emotion="' + key + " " + serialized.name + '"]');
|
|
21077
|
-
if (
|
|
21078
|
-
sheet.before =
|
|
21149
|
+
if (cache.sheet.tags.length) {
|
|
21150
|
+
sheet.before = cache.sheet.tags[0];
|
|
21079
21151
|
}
|
|
21080
21152
|
if (node2 !== null) {
|
|
21081
21153
|
rehydrating = true;
|
|
@@ -21086,7 +21158,7 @@ var Global = /* @__PURE__ */ withEmotionCache(function(props, cache2) {
|
|
|
21086
21158
|
return function() {
|
|
21087
21159
|
sheet.flush();
|
|
21088
21160
|
};
|
|
21089
|
-
}, [
|
|
21161
|
+
}, [cache]);
|
|
21090
21162
|
useInsertionEffectWithLayoutFallback(function() {
|
|
21091
21163
|
var sheetRefCurrent = sheetRef.current;
|
|
21092
21164
|
var sheet = sheetRefCurrent[0], rehydrating = sheetRefCurrent[1];
|
|
@@ -21095,15 +21167,15 @@ var Global = /* @__PURE__ */ withEmotionCache(function(props, cache2) {
|
|
|
21095
21167
|
return;
|
|
21096
21168
|
}
|
|
21097
21169
|
if (serialized.next !== void 0) {
|
|
21098
|
-
insertStyles(
|
|
21170
|
+
insertStyles(cache, serialized.next, true);
|
|
21099
21171
|
}
|
|
21100
21172
|
if (sheet.tags.length) {
|
|
21101
21173
|
var element = sheet.tags[sheet.tags.length - 1].nextElementSibling;
|
|
21102
21174
|
sheet.before = element;
|
|
21103
21175
|
sheet.flush();
|
|
21104
21176
|
}
|
|
21105
|
-
|
|
21106
|
-
}, [
|
|
21177
|
+
cache.insert("", serialized, sheet, false);
|
|
21178
|
+
}, [cache, serialized.name]);
|
|
21107
21179
|
return null;
|
|
21108
21180
|
});
|
|
21109
21181
|
function css() {
|
|
@@ -21152,10 +21224,10 @@ var composeShouldForwardProps = function composeShouldForwardProps2(tag, options
|
|
|
21152
21224
|
return shouldForwardProp2;
|
|
21153
21225
|
};
|
|
21154
21226
|
var Insertion2 = function Insertion3(_ref) {
|
|
21155
|
-
var
|
|
21156
|
-
registerStyles(
|
|
21227
|
+
var cache = _ref.cache, serialized = _ref.serialized, isStringTag2 = _ref.isStringTag;
|
|
21228
|
+
registerStyles(cache, serialized, isStringTag2);
|
|
21157
21229
|
useInsertionEffectAlwaysWithSyncFallback(function() {
|
|
21158
|
-
return insertStyles(
|
|
21230
|
+
return insertStyles(cache, serialized, isStringTag2);
|
|
21159
21231
|
});
|
|
21160
21232
|
return null;
|
|
21161
21233
|
};
|
|
@@ -21188,7 +21260,7 @@ var createStyled$3 = function createStyled(tag, options) {
|
|
|
21188
21260
|
styles2.push(args[i], templateStringsArr[i]);
|
|
21189
21261
|
}
|
|
21190
21262
|
}
|
|
21191
|
-
var Styled = withEmotionCache(function(props,
|
|
21263
|
+
var Styled = withEmotionCache(function(props, cache, ref) {
|
|
21192
21264
|
var FinalTag = shouldUseAs && props.as || baseTag;
|
|
21193
21265
|
var className = "";
|
|
21194
21266
|
var classInterpolations = [];
|
|
@@ -21201,12 +21273,12 @@ var createStyled$3 = function createStyled(tag, options) {
|
|
|
21201
21273
|
mergedProps.theme = React$2.useContext(ThemeContext);
|
|
21202
21274
|
}
|
|
21203
21275
|
if (typeof props.className === "string") {
|
|
21204
|
-
className = getRegisteredStyles(
|
|
21276
|
+
className = getRegisteredStyles(cache.registered, classInterpolations, props.className);
|
|
21205
21277
|
} else if (props.className != null) {
|
|
21206
21278
|
className = props.className + " ";
|
|
21207
21279
|
}
|
|
21208
|
-
var serialized = serializeStyles(styles2.concat(classInterpolations),
|
|
21209
|
-
className +=
|
|
21280
|
+
var serialized = serializeStyles(styles2.concat(classInterpolations), cache.registered, mergedProps);
|
|
21281
|
+
className += cache.key + "-" + serialized.name;
|
|
21210
21282
|
if (targetClassName !== void 0) {
|
|
21211
21283
|
className += " " + targetClassName;
|
|
21212
21284
|
}
|
|
@@ -21224,7 +21296,7 @@ var createStyled$3 = function createStyled(tag, options) {
|
|
|
21224
21296
|
newProps.ref = ref;
|
|
21225
21297
|
}
|
|
21226
21298
|
return /* @__PURE__ */ React$2.createElement(React$2.Fragment, null, /* @__PURE__ */ React$2.createElement(Insertion2, {
|
|
21227
|
-
cache
|
|
21299
|
+
cache,
|
|
21228
21300
|
serialized,
|
|
21229
21301
|
isStringTag: typeof FinalTag === "string"
|
|
21230
21302
|
}), /* @__PURE__ */ React$2.createElement(FinalTag, newProps));
|
|
@@ -21244,10 +21316,10 @@ var createStyled$3 = function createStyled(tag, options) {
|
|
|
21244
21316
|
}
|
|
21245
21317
|
});
|
|
21246
21318
|
Styled.withComponent = function(nextTag, nextOptions) {
|
|
21247
|
-
var
|
|
21319
|
+
var newStyled = createStyled(nextTag, _extends$2({}, options, nextOptions, {
|
|
21248
21320
|
shouldForwardProp: composeShouldForwardProps(Styled, nextOptions, true)
|
|
21249
21321
|
}));
|
|
21250
|
-
return
|
|
21322
|
+
return newStyled.apply(void 0, styles2);
|
|
21251
21323
|
};
|
|
21252
21324
|
return Styled;
|
|
21253
21325
|
};
|
|
@@ -21388,26 +21460,49 @@ var tags = [
|
|
|
21388
21460
|
"text",
|
|
21389
21461
|
"tspan"
|
|
21390
21462
|
];
|
|
21391
|
-
var
|
|
21463
|
+
var styled$5 = createStyled$3.bind(null);
|
|
21392
21464
|
tags.forEach(function(tagName) {
|
|
21393
|
-
|
|
21465
|
+
styled$5[tagName] = styled$5(tagName);
|
|
21394
21466
|
});
|
|
21395
|
-
|
|
21396
|
-
|
|
21397
|
-
cache = createCache({
|
|
21467
|
+
function getCache(injectFirst, enableCssLayer) {
|
|
21468
|
+
const emotionCache = createCache({
|
|
21398
21469
|
key: "css",
|
|
21399
|
-
prepend:
|
|
21470
|
+
prepend: injectFirst
|
|
21400
21471
|
});
|
|
21472
|
+
if (enableCssLayer) {
|
|
21473
|
+
const prevInsert = emotionCache.insert;
|
|
21474
|
+
emotionCache.insert = (...args) => {
|
|
21475
|
+
if (!args[1].styles.match(/^@layer\s+[^{]*$/)) {
|
|
21476
|
+
args[1].styles = `@layer mui {${args[1].styles}}`;
|
|
21477
|
+
}
|
|
21478
|
+
return prevInsert(...args);
|
|
21479
|
+
};
|
|
21480
|
+
}
|
|
21481
|
+
return emotionCache;
|
|
21401
21482
|
}
|
|
21483
|
+
const cacheMap = /* @__PURE__ */ new Map();
|
|
21402
21484
|
function StyledEngineProvider(props) {
|
|
21403
21485
|
const {
|
|
21404
21486
|
injectFirst,
|
|
21487
|
+
enableCssLayer,
|
|
21405
21488
|
children
|
|
21406
21489
|
} = props;
|
|
21407
|
-
|
|
21408
|
-
|
|
21409
|
-
|
|
21410
|
-
|
|
21490
|
+
const cache = React$2.useMemo(() => {
|
|
21491
|
+
const cacheKey = `${injectFirst}-${enableCssLayer}`;
|
|
21492
|
+
if (typeof document === "object" && cacheMap.has(cacheKey)) {
|
|
21493
|
+
return cacheMap.get(cacheKey);
|
|
21494
|
+
}
|
|
21495
|
+
const fresh = getCache(injectFirst, enableCssLayer);
|
|
21496
|
+
cacheMap.set(cacheKey, fresh);
|
|
21497
|
+
return fresh;
|
|
21498
|
+
}, [injectFirst, enableCssLayer]);
|
|
21499
|
+
if (injectFirst || enableCssLayer) {
|
|
21500
|
+
return /* @__PURE__ */ jsx$1(CacheProvider, {
|
|
21501
|
+
value: cache,
|
|
21502
|
+
children
|
|
21503
|
+
});
|
|
21504
|
+
}
|
|
21505
|
+
return children;
|
|
21411
21506
|
}
|
|
21412
21507
|
function isEmpty$4(obj) {
|
|
21413
21508
|
return obj === void 0 || obj === null || Object.keys(obj).length === 0;
|
|
@@ -21423,14 +21518,14 @@ function GlobalStyles$2(props) {
|
|
|
21423
21518
|
});
|
|
21424
21519
|
}
|
|
21425
21520
|
/**
|
|
21426
|
-
* @mui/styled-engine v5.
|
|
21521
|
+
* @mui/styled-engine v5.18.0
|
|
21427
21522
|
*
|
|
21428
21523
|
* @license MIT
|
|
21429
21524
|
* This source code is licensed under the MIT license found in the
|
|
21430
21525
|
* LICENSE file in the root directory of this source tree.
|
|
21431
21526
|
*/
|
|
21432
21527
|
function styled$4(tag, options) {
|
|
21433
|
-
const stylesFactory =
|
|
21528
|
+
const stylesFactory = styled$5(tag, options);
|
|
21434
21529
|
return stylesFactory;
|
|
21435
21530
|
}
|
|
21436
21531
|
const internal_processStyles = (tag, processor) => {
|
|
@@ -21438,10 +21533,16 @@ const internal_processStyles = (tag, processor) => {
|
|
|
21438
21533
|
tag.__emotion_styles = processor(tag.__emotion_styles);
|
|
21439
21534
|
}
|
|
21440
21535
|
};
|
|
21536
|
+
const wrapper = [];
|
|
21537
|
+
function internal_serializeStyles(styles2) {
|
|
21538
|
+
wrapper[0] = styles2;
|
|
21539
|
+
return serializeStyles(wrapper);
|
|
21540
|
+
}
|
|
21441
21541
|
var styledEngine = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
21442
21542
|
__proto__: null,
|
|
21443
21543
|
"default": styled$4,
|
|
21444
21544
|
internal_processStyles,
|
|
21545
|
+
internal_serializeStyles,
|
|
21445
21546
|
ThemeContext,
|
|
21446
21547
|
keyframes,
|
|
21447
21548
|
css,
|
|
@@ -21746,12 +21847,12 @@ function style$2(options) {
|
|
|
21746
21847
|
return fn2;
|
|
21747
21848
|
}
|
|
21748
21849
|
function memoize(fn2) {
|
|
21749
|
-
const
|
|
21850
|
+
const cache = {};
|
|
21750
21851
|
return (arg) => {
|
|
21751
|
-
if (
|
|
21752
|
-
|
|
21852
|
+
if (cache[arg] === void 0) {
|
|
21853
|
+
cache[arg] = fn2(arg);
|
|
21753
21854
|
}
|
|
21754
|
-
return
|
|
21855
|
+
return cache[arg];
|
|
21755
21856
|
};
|
|
21756
21857
|
}
|
|
21757
21858
|
const properties = {
|
|
@@ -22412,7 +22513,8 @@ function unstable_createStyleFunctionSx() {
|
|
|
22412
22513
|
var _theme$unstable_sxCon;
|
|
22413
22514
|
const {
|
|
22414
22515
|
sx,
|
|
22415
|
-
theme = {}
|
|
22516
|
+
theme = {},
|
|
22517
|
+
nested
|
|
22416
22518
|
} = props || {};
|
|
22417
22519
|
if (!sx) {
|
|
22418
22520
|
return null;
|
|
@@ -22446,7 +22548,8 @@ function unstable_createStyleFunctionSx() {
|
|
|
22446
22548
|
if (objectsHaveSameKeys(breakpointsValues, value)) {
|
|
22447
22549
|
css2[styleKey] = styleFunctionSx2({
|
|
22448
22550
|
sx: value,
|
|
22449
|
-
theme
|
|
22551
|
+
theme,
|
|
22552
|
+
nested: true
|
|
22450
22553
|
});
|
|
22451
22554
|
} else {
|
|
22452
22555
|
css2 = merge(css2, breakpointsValues);
|
|
@@ -22457,6 +22560,11 @@ function unstable_createStyleFunctionSx() {
|
|
|
22457
22560
|
}
|
|
22458
22561
|
}
|
|
22459
22562
|
});
|
|
22563
|
+
if (!nested && theme.modularCssLayers) {
|
|
22564
|
+
return {
|
|
22565
|
+
"@layer sx": removeUnusedBreakpoints(breakpointsKeys, css2)
|
|
22566
|
+
};
|
|
22567
|
+
}
|
|
22460
22568
|
return removeUnusedBreakpoints(breakpointsKeys, css2);
|
|
22461
22569
|
}
|
|
22462
22570
|
return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);
|
|
@@ -22527,13 +22635,36 @@ const systemDefaultTheme$2 = createTheme$2();
|
|
|
22527
22635
|
function useTheme$2(defaultTheme2 = systemDefaultTheme$2) {
|
|
22528
22636
|
return useTheme$3(defaultTheme2);
|
|
22529
22637
|
}
|
|
22638
|
+
function wrapGlobalLayer(styles2) {
|
|
22639
|
+
const serialized = internal_serializeStyles(styles2);
|
|
22640
|
+
if (styles2 !== serialized && serialized.styles) {
|
|
22641
|
+
if (!serialized.styles.match(/^@layer\s+[^{]*$/)) {
|
|
22642
|
+
serialized.styles = `@layer global{${serialized.styles}}`;
|
|
22643
|
+
}
|
|
22644
|
+
return serialized;
|
|
22645
|
+
}
|
|
22646
|
+
return styles2;
|
|
22647
|
+
}
|
|
22530
22648
|
function GlobalStyles$1({
|
|
22531
22649
|
styles: styles2,
|
|
22532
22650
|
themeId,
|
|
22533
22651
|
defaultTheme: defaultTheme2 = {}
|
|
22534
22652
|
}) {
|
|
22535
22653
|
const upperTheme = useTheme$2(defaultTheme2);
|
|
22536
|
-
const
|
|
22654
|
+
const resolvedTheme = themeId ? upperTheme[themeId] || upperTheme : upperTheme;
|
|
22655
|
+
let globalStyles = typeof styles2 === "function" ? styles2(resolvedTheme) : styles2;
|
|
22656
|
+
if (resolvedTheme.modularCssLayers) {
|
|
22657
|
+
if (Array.isArray(globalStyles)) {
|
|
22658
|
+
globalStyles = globalStyles.map((styleArg) => {
|
|
22659
|
+
if (typeof styleArg === "function") {
|
|
22660
|
+
return wrapGlobalLayer(styleArg(resolvedTheme));
|
|
22661
|
+
}
|
|
22662
|
+
return wrapGlobalLayer(styleArg);
|
|
22663
|
+
});
|
|
22664
|
+
} else {
|
|
22665
|
+
globalStyles = wrapGlobalLayer(globalStyles);
|
|
22666
|
+
}
|
|
22667
|
+
}
|
|
22537
22668
|
return /* @__PURE__ */ jsx$1(GlobalStyles$2, {
|
|
22538
22669
|
styles: globalStyles
|
|
22539
22670
|
});
|
|
@@ -22824,6 +22955,12 @@ function isStringTag$1(tag) {
|
|
|
22824
22955
|
function shouldForwardProp$1(prop) {
|
|
22825
22956
|
return prop !== "ownerState" && prop !== "theme" && prop !== "sx" && prop !== "as";
|
|
22826
22957
|
}
|
|
22958
|
+
function shallowLayer$1(serialized, layerName) {
|
|
22959
|
+
if (layerName && serialized && typeof serialized === "object" && serialized.styles && !serialized.styles.startsWith("@layer")) {
|
|
22960
|
+
serialized.styles = `@layer ${layerName}{${String(serialized.styles)}}`;
|
|
22961
|
+
}
|
|
22962
|
+
return serialized;
|
|
22963
|
+
}
|
|
22827
22964
|
const systemDefaultTheme$1 = createTheme$2();
|
|
22828
22965
|
const lowercaseFirstLetter$1 = (string2) => {
|
|
22829
22966
|
if (!string2) {
|
|
@@ -22844,7 +22981,7 @@ function defaultOverridesResolver$1(slot) {
|
|
|
22844
22981
|
}
|
|
22845
22982
|
return (props, styles2) => styles2[slot];
|
|
22846
22983
|
}
|
|
22847
|
-
function processStyleArg$1(callableStyle, _ref) {
|
|
22984
|
+
function processStyleArg$1(callableStyle, _ref, layerName) {
|
|
22848
22985
|
let {
|
|
22849
22986
|
ownerState
|
|
22850
22987
|
} = _ref, props = _objectWithoutPropertiesLoose$1(_ref, _excluded$1S);
|
|
@@ -22854,7 +22991,7 @@ function processStyleArg$1(callableStyle, _ref) {
|
|
|
22854
22991
|
if (Array.isArray(resolvedStylesArg)) {
|
|
22855
22992
|
return resolvedStylesArg.flatMap((resolvedStyle) => processStyleArg$1(resolvedStyle, _extends$2({
|
|
22856
22993
|
ownerState
|
|
22857
|
-
}, props)));
|
|
22994
|
+
}, props), layerName));
|
|
22858
22995
|
}
|
|
22859
22996
|
if (!!resolvedStylesArg && typeof resolvedStylesArg === "object" && Array.isArray(resolvedStylesArg.variants)) {
|
|
22860
22997
|
const {
|
|
@@ -22878,14 +23015,15 @@ function processStyleArg$1(callableStyle, _ref) {
|
|
|
22878
23015
|
if (!Array.isArray(result)) {
|
|
22879
23016
|
result = [result];
|
|
22880
23017
|
}
|
|
22881
|
-
|
|
23018
|
+
const variantStyle = typeof variant.style === "function" ? variant.style(_extends$2({
|
|
22882
23019
|
ownerState
|
|
22883
|
-
}, props, ownerState)) : variant.style
|
|
23020
|
+
}, props, ownerState)) : variant.style;
|
|
23021
|
+
result.push(layerName ? shallowLayer$1(internal_serializeStyles(variantStyle), layerName) : variantStyle);
|
|
22884
23022
|
}
|
|
22885
23023
|
});
|
|
22886
23024
|
return result;
|
|
22887
23025
|
}
|
|
22888
|
-
return resolvedStylesArg;
|
|
23026
|
+
return layerName ? shallowLayer$1(internal_serializeStyles(resolvedStylesArg), layerName) : resolvedStylesArg;
|
|
22889
23027
|
}
|
|
22890
23028
|
function createStyled$2(input = {}) {
|
|
22891
23029
|
const {
|
|
@@ -22912,6 +23050,7 @@ function createStyled$2(input = {}) {
|
|
|
22912
23050
|
skipSx: inputSkipSx,
|
|
22913
23051
|
overridesResolver: overridesResolver2 = defaultOverridesResolver$1(lowercaseFirstLetter$1(componentSlot))
|
|
22914
23052
|
} = inputOptions, options = _objectWithoutPropertiesLoose$1(inputOptions, _excluded3$5);
|
|
23053
|
+
const layerName = componentName && componentName.startsWith("Mui") || !!componentSlot ? "components" : "custom";
|
|
22915
23054
|
const skipVariantsResolver = inputSkipVariantsResolver !== void 0 ? inputSkipVariantsResolver : componentSlot && componentSlot !== "Root" && componentSlot !== "root" || false;
|
|
22916
23055
|
const skipSx = inputSkipSx || false;
|
|
22917
23056
|
let label;
|
|
@@ -22929,13 +23068,16 @@ function createStyled$2(input = {}) {
|
|
|
22929
23068
|
}, options));
|
|
22930
23069
|
const transformStyleArg = (stylesArg) => {
|
|
22931
23070
|
if (typeof stylesArg === "function" && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {
|
|
22932
|
-
return (props) =>
|
|
22933
|
-
theme
|
|
23071
|
+
return (props) => {
|
|
23072
|
+
const theme = resolveTheme$1({
|
|
22934
23073
|
theme: props.theme,
|
|
22935
23074
|
defaultTheme: defaultTheme2,
|
|
22936
23075
|
themeId
|
|
22937
|
-
})
|
|
22938
|
-
|
|
23076
|
+
});
|
|
23077
|
+
return processStyleArg$1(stylesArg, _extends$2({}, props, {
|
|
23078
|
+
theme
|
|
23079
|
+
}), theme.modularCssLayers ? layerName : void 0);
|
|
23080
|
+
};
|
|
22939
23081
|
}
|
|
22940
23082
|
return stylesArg;
|
|
22941
23083
|
};
|
|
@@ -22956,7 +23098,7 @@ function createStyled$2(input = {}) {
|
|
|
22956
23098
|
Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {
|
|
22957
23099
|
resolvedStyleOverrides[slotKey] = processStyleArg$1(slotStyle, _extends$2({}, props, {
|
|
22958
23100
|
theme
|
|
22959
|
-
}));
|
|
23101
|
+
}), theme.modularCssLayers ? "theme" : void 0);
|
|
22960
23102
|
});
|
|
22961
23103
|
return overridesResolver2(props, resolvedStyleOverrides);
|
|
22962
23104
|
});
|
|
@@ -22973,7 +23115,7 @@ function createStyled$2(input = {}) {
|
|
|
22973
23115
|
variants: themeVariants
|
|
22974
23116
|
}, _extends$2({}, props, {
|
|
22975
23117
|
theme
|
|
22976
|
-
}));
|
|
23118
|
+
}), theme.modularCssLayers ? "theme" : void 0);
|
|
22977
23119
|
});
|
|
22978
23120
|
}
|
|
22979
23121
|
if (!skipSx) {
|
|
@@ -24568,6 +24710,12 @@ function isStringTag(tag) {
|
|
|
24568
24710
|
function shouldForwardProp(prop) {
|
|
24569
24711
|
return prop !== "ownerState" && prop !== "theme" && prop !== "sx" && prop !== "as";
|
|
24570
24712
|
}
|
|
24713
|
+
function shallowLayer(serialized, layerName) {
|
|
24714
|
+
if (layerName && serialized && typeof serialized === "object" && serialized.styles && !serialized.styles.startsWith("@layer")) {
|
|
24715
|
+
serialized.styles = `@layer ${layerName}{${String(serialized.styles)}}`;
|
|
24716
|
+
}
|
|
24717
|
+
return serialized;
|
|
24718
|
+
}
|
|
24571
24719
|
const systemDefaultTheme = createStyled$1.systemDefaultTheme = (0, _createTheme.default)();
|
|
24572
24720
|
const lowercaseFirstLetter = (string2) => {
|
|
24573
24721
|
if (!string2) {
|
|
@@ -24588,7 +24736,7 @@ function defaultOverridesResolver(slot) {
|
|
|
24588
24736
|
}
|
|
24589
24737
|
return (props, styles2) => styles2[slot];
|
|
24590
24738
|
}
|
|
24591
|
-
function processStyleArg(callableStyle, _ref) {
|
|
24739
|
+
function processStyleArg(callableStyle, _ref, layerName) {
|
|
24592
24740
|
let {
|
|
24593
24741
|
ownerState
|
|
24594
24742
|
} = _ref, props = (0, _objectWithoutPropertiesLoose2.default)(_ref, _excluded$1L);
|
|
@@ -24598,7 +24746,7 @@ function processStyleArg(callableStyle, _ref) {
|
|
|
24598
24746
|
if (Array.isArray(resolvedStylesArg)) {
|
|
24599
24747
|
return resolvedStylesArg.flatMap((resolvedStyle) => processStyleArg(resolvedStyle, (0, _extends2.default)({
|
|
24600
24748
|
ownerState
|
|
24601
|
-
}, props)));
|
|
24749
|
+
}, props), layerName));
|
|
24602
24750
|
}
|
|
24603
24751
|
if (!!resolvedStylesArg && typeof resolvedStylesArg === "object" && Array.isArray(resolvedStylesArg.variants)) {
|
|
24604
24752
|
const {
|
|
@@ -24622,14 +24770,15 @@ function processStyleArg(callableStyle, _ref) {
|
|
|
24622
24770
|
if (!Array.isArray(result)) {
|
|
24623
24771
|
result = [result];
|
|
24624
24772
|
}
|
|
24625
|
-
|
|
24773
|
+
const variantStyle = typeof variant.style === "function" ? variant.style((0, _extends2.default)({
|
|
24626
24774
|
ownerState
|
|
24627
|
-
}, props, ownerState)) : variant.style
|
|
24775
|
+
}, props, ownerState)) : variant.style;
|
|
24776
|
+
result.push(layerName ? shallowLayer((0, _styledEngine$1.internal_serializeStyles)(variantStyle), layerName) : variantStyle);
|
|
24628
24777
|
}
|
|
24629
24778
|
});
|
|
24630
24779
|
return result;
|
|
24631
24780
|
}
|
|
24632
|
-
return resolvedStylesArg;
|
|
24781
|
+
return layerName ? shallowLayer((0, _styledEngine$1.internal_serializeStyles)(resolvedStylesArg), layerName) : resolvedStylesArg;
|
|
24633
24782
|
}
|
|
24634
24783
|
function createStyled2(input = {}) {
|
|
24635
24784
|
const {
|
|
@@ -24656,6 +24805,7 @@ function createStyled2(input = {}) {
|
|
|
24656
24805
|
skipSx: inputSkipSx,
|
|
24657
24806
|
overridesResolver: overridesResolver2 = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))
|
|
24658
24807
|
} = inputOptions, options = (0, _objectWithoutPropertiesLoose2.default)(inputOptions, _excluded3$4);
|
|
24808
|
+
const layerName = componentName && componentName.startsWith("Mui") || !!componentSlot ? "components" : "custom";
|
|
24659
24809
|
const skipVariantsResolver = inputSkipVariantsResolver !== void 0 ? inputSkipVariantsResolver : componentSlot && componentSlot !== "Root" && componentSlot !== "root" || false;
|
|
24660
24810
|
const skipSx = inputSkipSx || false;
|
|
24661
24811
|
let label;
|
|
@@ -24673,13 +24823,16 @@ function createStyled2(input = {}) {
|
|
|
24673
24823
|
}, options));
|
|
24674
24824
|
const transformStyleArg = (stylesArg) => {
|
|
24675
24825
|
if (typeof stylesArg === "function" && stylesArg.__emotion_real !== stylesArg || (0, _deepmerge.isPlainObject)(stylesArg)) {
|
|
24676
|
-
return (props) =>
|
|
24677
|
-
theme
|
|
24826
|
+
return (props) => {
|
|
24827
|
+
const theme = resolveTheme({
|
|
24678
24828
|
theme: props.theme,
|
|
24679
24829
|
defaultTheme: defaultTheme2,
|
|
24680
24830
|
themeId
|
|
24681
|
-
})
|
|
24682
|
-
|
|
24831
|
+
});
|
|
24832
|
+
return processStyleArg(stylesArg, (0, _extends2.default)({}, props, {
|
|
24833
|
+
theme
|
|
24834
|
+
}), theme.modularCssLayers ? layerName : void 0);
|
|
24835
|
+
};
|
|
24683
24836
|
}
|
|
24684
24837
|
return stylesArg;
|
|
24685
24838
|
};
|
|
@@ -24700,7 +24853,7 @@ function createStyled2(input = {}) {
|
|
|
24700
24853
|
Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {
|
|
24701
24854
|
resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, (0, _extends2.default)({}, props, {
|
|
24702
24855
|
theme
|
|
24703
|
-
}));
|
|
24856
|
+
}), theme.modularCssLayers ? "theme" : void 0);
|
|
24704
24857
|
});
|
|
24705
24858
|
return overridesResolver2(props, resolvedStyleOverrides);
|
|
24706
24859
|
});
|
|
@@ -24717,7 +24870,7 @@ function createStyled2(input = {}) {
|
|
|
24717
24870
|
variants: themeVariants
|
|
24718
24871
|
}, (0, _extends2.default)({}, props, {
|
|
24719
24872
|
theme
|
|
24720
|
-
}));
|
|
24873
|
+
}), theme.modularCssLayers ? "theme" : void 0);
|
|
24721
24874
|
});
|
|
24722
24875
|
}
|
|
24723
24876
|
if (!skipSx) {
|
|
@@ -31634,7 +31787,9 @@ const useUtilityClasses$17 = (ownerState) => {
|
|
|
31634
31787
|
};
|
|
31635
31788
|
return composeClasses(slots, getSwitchBaseUtilityClass, classes);
|
|
31636
31789
|
};
|
|
31637
|
-
const SwitchBaseRoot = styled$1(ButtonBase$1
|
|
31790
|
+
const SwitchBaseRoot = styled$1(ButtonBase$1, {
|
|
31791
|
+
name: "MuiSwitchBase"
|
|
31792
|
+
})(({
|
|
31638
31793
|
ownerState
|
|
31639
31794
|
}) => _extends$2({
|
|
31640
31795
|
padding: 9,
|
|
@@ -31645,6 +31800,7 @@ const SwitchBaseRoot = styled$1(ButtonBase$1)(({
|
|
|
31645
31800
|
marginRight: ownerState.size === "small" ? -3 : -12
|
|
31646
31801
|
}));
|
|
31647
31802
|
const SwitchBaseInput = styled$1("input", {
|
|
31803
|
+
name: "MuiSwitchBase",
|
|
31648
31804
|
shouldForwardProp: rootShouldForwardProp$1
|
|
31649
31805
|
})({
|
|
31650
31806
|
cursor: "inherit",
|
|
@@ -35707,6 +35863,7 @@ var NativeSelectInput$1 = NativeSelectInput;
|
|
|
35707
35863
|
var _span$1;
|
|
35708
35864
|
const _excluded$12 = ["children", "classes", "className", "label", "notched"];
|
|
35709
35865
|
const NotchedOutlineRoot$1 = styled$1("fieldset", {
|
|
35866
|
+
name: "MuiNotchedOutlined",
|
|
35710
35867
|
shouldForwardProp: rootShouldForwardProp$1
|
|
35711
35868
|
})({
|
|
35712
35869
|
textAlign: "left",
|
|
@@ -35725,6 +35882,7 @@ const NotchedOutlineRoot$1 = styled$1("fieldset", {
|
|
|
35725
35882
|
minWidth: "0%"
|
|
35726
35883
|
});
|
|
35727
35884
|
const NotchedOutlineLegend = styled$1("legend", {
|
|
35885
|
+
name: "MuiNotchedOutlined",
|
|
35728
35886
|
shouldForwardProp: rootShouldForwardProp$1
|
|
35729
35887
|
})(({
|
|
35730
35888
|
ownerState,
|
|
@@ -39269,10 +39427,11 @@ const DocumentReaderController = (dataDocument, clientId, authorize, eventId, so
|
|
|
39269
39427
|
};
|
|
39270
39428
|
const parseReq = {
|
|
39271
39429
|
method: "POST",
|
|
39272
|
-
path: "api/v1/
|
|
39430
|
+
path: "api/v1/onboarding/validate",
|
|
39273
39431
|
inProduction,
|
|
39274
39432
|
customHeaders,
|
|
39275
|
-
bodyParams: base64
|
|
39433
|
+
bodyParams: base64,
|
|
39434
|
+
service: "services"
|
|
39276
39435
|
};
|
|
39277
39436
|
try {
|
|
39278
39437
|
const res2 = await request2(parseReq);
|
|
@@ -39820,11 +39979,8 @@ function SideDocsSelector({
|
|
|
39820
39979
|
return;
|
|
39821
39980
|
const [track] = streamRef.current.getVideoTracks();
|
|
39822
39981
|
const capabilities = (_a = track.getCapabilities) == null ? void 0 : _a.call(track);
|
|
39823
|
-
|
|
39824
|
-
console.log("focus capabilities:", capabilities);
|
|
39825
|
-
console.log("focus settings:", settings);
|
|
39982
|
+
(_b = track.getSettings) == null ? void 0 : _b.call(track);
|
|
39826
39983
|
if (!capabilities || !capabilities.focusMode) {
|
|
39827
|
-
console.warn("No se puede acceder a las capacidades de enfoque");
|
|
39828
39984
|
return;
|
|
39829
39985
|
}
|
|
39830
39986
|
try {
|
|
@@ -39884,7 +40040,6 @@ function SideDocsSelector({
|
|
|
39884
40040
|
const handleSwitchCamera = () => {
|
|
39885
40041
|
setCurrentCameraIndex((prevIndex) => (prevIndex + 1) % cameras.length);
|
|
39886
40042
|
};
|
|
39887
|
-
console.log("Activate Camera: ", activateCamera, "Distinto de HideCapture Button: ", !hideCaptureButton, "Distinto de Upload document By Phone: ", !uploadDocumentByPhone, "Cantidad de cameras: ", cameras.length);
|
|
39888
40043
|
return /* @__PURE__ */ jsxs(Box$1, {
|
|
39889
40044
|
sx: {
|
|
39890
40045
|
width: "100%"
|
|
@@ -40584,8 +40739,6 @@ function DocumentReader({
|
|
|
40584
40739
|
uploadDocumentByPhone,
|
|
40585
40740
|
setUploadDocumentByPhone
|
|
40586
40741
|
} = DocumentReaderController(dataDocument, clientId, authorize, eventId, source2, inProduction, countryCodeAllowed, validateVpn, successMessage, dualModeRequired);
|
|
40587
|
-
console.log(isLoading, countryCodeAllowed, countryCode);
|
|
40588
|
-
console.log(isLoading, countryCodeAllowed !== null, !countryCode);
|
|
40589
40742
|
return /* @__PURE__ */ jsxs("div", {
|
|
40590
40743
|
className: `kit-gbc ${mode} without-shadow ocr`,
|
|
40591
40744
|
children: [/* @__PURE__ */ jsx$1(k$2, {
|
|
@@ -40658,8 +40811,8 @@ const fetchFaceMatch = async (faceMatch, selfie, inProduction, customHeaders) =>
|
|
|
40658
40811
|
method: "POST",
|
|
40659
40812
|
path: "api/v1/onboarding/face_match",
|
|
40660
40813
|
inProduction,
|
|
40661
|
-
service: "services",
|
|
40662
40814
|
customHeaders,
|
|
40815
|
+
service: "services",
|
|
40663
40816
|
bodyParams: {
|
|
40664
40817
|
doc: faceMatch,
|
|
40665
40818
|
selfie
|
|
@@ -43027,13 +43180,13 @@ function defaultMemoize(func, equalityCheckOrOptions) {
|
|
|
43027
43180
|
};
|
|
43028
43181
|
var _providedOptions$equa = providedOptions.equalityCheck, equalityCheck = _providedOptions$equa === void 0 ? defaultEqualityCheck : _providedOptions$equa, _providedOptions$maxS = providedOptions.maxSize, maxSize = _providedOptions$maxS === void 0 ? 1 : _providedOptions$maxS, resultEqualityCheck = providedOptions.resultEqualityCheck;
|
|
43029
43182
|
var comparator = createCacheKeyComparator(equalityCheck);
|
|
43030
|
-
var
|
|
43183
|
+
var cache = maxSize === 1 ? createSingletonCache(comparator) : createLruCache(maxSize, comparator);
|
|
43031
43184
|
function memoized() {
|
|
43032
|
-
var value =
|
|
43185
|
+
var value = cache.get(arguments);
|
|
43033
43186
|
if (value === NOT_FOUND) {
|
|
43034
43187
|
value = func.apply(null, arguments);
|
|
43035
43188
|
if (resultEqualityCheck) {
|
|
43036
|
-
var entries =
|
|
43189
|
+
var entries = cache.getEntries();
|
|
43037
43190
|
var matchingEntry = entries.find(function(entry) {
|
|
43038
43191
|
return resultEqualityCheck(entry.value, value);
|
|
43039
43192
|
});
|
|
@@ -43041,12 +43194,12 @@ function defaultMemoize(func, equalityCheckOrOptions) {
|
|
|
43041
43194
|
value = matchingEntry.value;
|
|
43042
43195
|
}
|
|
43043
43196
|
}
|
|
43044
|
-
|
|
43197
|
+
cache.put(arguments, value);
|
|
43045
43198
|
}
|
|
43046
43199
|
return value;
|
|
43047
43200
|
}
|
|
43048
43201
|
memoized.clearCache = function() {
|
|
43049
|
-
return
|
|
43202
|
+
return cache.clear();
|
|
43050
43203
|
};
|
|
43051
43204
|
return memoized;
|
|
43052
43205
|
}
|
|
@@ -43197,17 +43350,17 @@ const createSelectorMemoized = (...args) => {
|
|
|
43197
43350
|
const cacheKey = isAPIRef ? stateOrApiRef.current.instanceId : instanceId != null ? instanceId : DEFAULT_INSTANCE_ID;
|
|
43198
43351
|
const state = isAPIRef ? stateOrApiRef.current.state : stateOrApiRef;
|
|
43199
43352
|
const {
|
|
43200
|
-
cache
|
|
43353
|
+
cache
|
|
43201
43354
|
} = cacheContainer;
|
|
43202
|
-
if (
|
|
43355
|
+
if (cache.get(cacheKey) && (_cache$get = cache.get(cacheKey)) != null && _cache$get.get(args)) {
|
|
43203
43356
|
var _cache$get2;
|
|
43204
|
-
return (_cache$get2 =
|
|
43357
|
+
return (_cache$get2 = cache.get(cacheKey)) == null ? void 0 : _cache$get2.get(args)(state, cacheKey);
|
|
43205
43358
|
}
|
|
43206
43359
|
const newSelector = createSelector$1(...args);
|
|
43207
|
-
if (!
|
|
43208
|
-
|
|
43360
|
+
if (!cache.get(cacheKey)) {
|
|
43361
|
+
cache.set(cacheKey, /* @__PURE__ */ new Map());
|
|
43209
43362
|
}
|
|
43210
|
-
(_cache$get3 =
|
|
43363
|
+
(_cache$get3 = cache.get(cacheKey)) == null || _cache$get3.set(args, newSelector);
|
|
43211
43364
|
return newSelector(state, cacheKey);
|
|
43212
43365
|
};
|
|
43213
43366
|
selector.acceptsApiRef = true;
|
|
@@ -43603,7 +43756,7 @@ const getRowsStateFromCache = ({
|
|
|
43603
43756
|
previousTree,
|
|
43604
43757
|
previousTreeDepths
|
|
43605
43758
|
}) => {
|
|
43606
|
-
const
|
|
43759
|
+
const cache = apiRef.current.caches.rows;
|
|
43607
43760
|
const {
|
|
43608
43761
|
tree: unProcessedTree,
|
|
43609
43762
|
treeDepths: unProcessedTreeDepths,
|
|
@@ -43612,16 +43765,16 @@ const getRowsStateFromCache = ({
|
|
|
43612
43765
|
} = apiRef.current.applyStrategyProcessor("rowTreeCreation", {
|
|
43613
43766
|
previousTree,
|
|
43614
43767
|
previousTreeDepths,
|
|
43615
|
-
updates:
|
|
43616
|
-
dataRowIdToIdLookup:
|
|
43617
|
-
dataRowIdToModelLookup:
|
|
43768
|
+
updates: cache.updates,
|
|
43769
|
+
dataRowIdToIdLookup: cache.dataRowIdToIdLookup,
|
|
43770
|
+
dataRowIdToModelLookup: cache.dataRowIdToModelLookup
|
|
43618
43771
|
});
|
|
43619
43772
|
const groupingParamsWithHydrateRows = apiRef.current.unstable_applyPipeProcessors("hydrateRows", {
|
|
43620
43773
|
tree: unProcessedTree,
|
|
43621
43774
|
treeDepths: unProcessedTreeDepths,
|
|
43622
|
-
dataRowIdToIdLookup:
|
|
43775
|
+
dataRowIdToIdLookup: cache.dataRowIdToIdLookup,
|
|
43623
43776
|
dataRowIds: unProcessedDataRowIds,
|
|
43624
|
-
dataRowIdToModelLookup:
|
|
43777
|
+
dataRowIdToModelLookup: cache.dataRowIdToModelLookup
|
|
43625
43778
|
});
|
|
43626
43779
|
apiRef.current.caches.rows.updates = {
|
|
43627
43780
|
type: "partial",
|
|
@@ -49567,14 +49720,14 @@ const buildAggregatedFilterApplier = (filterModel, apiRef, disableEval) => {
|
|
|
49567
49720
|
};
|
|
49568
49721
|
};
|
|
49569
49722
|
const isNotNull = (result) => result != null;
|
|
49570
|
-
const filterModelItems = (
|
|
49571
|
-
if (!
|
|
49572
|
-
|
|
49723
|
+
const filterModelItems = (cache, apiRef, items) => {
|
|
49724
|
+
if (!cache.cleanedFilterItems) {
|
|
49725
|
+
cache.cleanedFilterItems = items.filter((item) => getFilterCallbackFromItem(item, apiRef) !== null);
|
|
49573
49726
|
}
|
|
49574
|
-
return
|
|
49727
|
+
return cache.cleanedFilterItems;
|
|
49575
49728
|
};
|
|
49576
|
-
const passFilterLogic = (allFilterItemResults, allQuickFilterResults, filterModel, apiRef,
|
|
49577
|
-
const cleanedFilterItems = filterModelItems(
|
|
49729
|
+
const passFilterLogic = (allFilterItemResults, allQuickFilterResults, filterModel, apiRef, cache) => {
|
|
49730
|
+
const cleanedFilterItems = filterModelItems(cache, apiRef, filterModel.items);
|
|
49578
49731
|
const cleanedFilterItemResults = allFilterItemResults.filter(isNotNull);
|
|
49579
49732
|
const cleanedQuickFilterResults = allQuickFilterResults.filter(isNotNull);
|
|
49580
49733
|
if (cleanedFilterItemResults.length > 0) {
|
|
@@ -54832,7 +54985,7 @@ const useGridRows = (apiRef, props) => {
|
|
|
54832
54985
|
return acc;
|
|
54833
54986
|
}, {}), [currentPage.rows]);
|
|
54834
54987
|
const throttledRowsChange = React$2.useCallback(({
|
|
54835
|
-
cache
|
|
54988
|
+
cache,
|
|
54836
54989
|
throttle
|
|
54837
54990
|
}) => {
|
|
54838
54991
|
const run = () => {
|
|
@@ -54850,7 +55003,7 @@ const useGridRows = (apiRef, props) => {
|
|
|
54850
55003
|
apiRef.current.forceUpdate();
|
|
54851
55004
|
};
|
|
54852
55005
|
timeout.clear();
|
|
54853
|
-
apiRef.current.caches.rows =
|
|
55006
|
+
apiRef.current.caches.rows = cache;
|
|
54854
55007
|
if (!throttle) {
|
|
54855
55008
|
run();
|
|
54856
55009
|
return;
|
|
@@ -54864,16 +55017,16 @@ const useGridRows = (apiRef, props) => {
|
|
|
54864
55017
|
}, [props.throttleRowsMs, props.rowCount, props.loading, apiRef, timeout]);
|
|
54865
55018
|
const setRows = React$2.useCallback((rows) => {
|
|
54866
55019
|
logger.debug(`Updating all rows, new length ${rows.length}`);
|
|
54867
|
-
const
|
|
55020
|
+
const cache = createRowsInternalCache({
|
|
54868
55021
|
rows,
|
|
54869
55022
|
getRowId: props.getRowId,
|
|
54870
55023
|
loading: props.loading,
|
|
54871
55024
|
rowCount: props.rowCount
|
|
54872
55025
|
});
|
|
54873
55026
|
const prevCache = apiRef.current.caches.rows;
|
|
54874
|
-
|
|
55027
|
+
cache.rowsBeforePartialUpdates = prevCache.rowsBeforePartialUpdates;
|
|
54875
55028
|
throttledRowsChange({
|
|
54876
|
-
cache
|
|
55029
|
+
cache,
|
|
54877
55030
|
throttle: true
|
|
54878
55031
|
});
|
|
54879
55032
|
}, [logger, props.getRowId, props.loading, props.rowCount, throttledRowsChange, apiRef]);
|
|
@@ -54895,13 +55048,13 @@ const useGridRows = (apiRef, props) => {
|
|
|
54895
55048
|
nonPinnedRowsUpdates.push(update);
|
|
54896
55049
|
}
|
|
54897
55050
|
});
|
|
54898
|
-
const
|
|
55051
|
+
const cache = updateCacheWithNewRows({
|
|
54899
55052
|
updates: nonPinnedRowsUpdates,
|
|
54900
55053
|
getRowId: props.getRowId,
|
|
54901
55054
|
previousCache: apiRef.current.caches.rows
|
|
54902
55055
|
});
|
|
54903
55056
|
throttledRowsChange({
|
|
54904
|
-
cache
|
|
55057
|
+
cache,
|
|
54905
55058
|
throttle: true
|
|
54906
55059
|
});
|
|
54907
55060
|
}, [props.signature, props.getRowId, throttledRowsChange, apiRef]);
|
|
@@ -55080,16 +55233,16 @@ const useGridRows = (apiRef, props) => {
|
|
|
55080
55233
|
};
|
|
55081
55234
|
const groupRows = React$2.useCallback(() => {
|
|
55082
55235
|
logger.info(`Row grouping pre-processing have changed, regenerating the row tree`);
|
|
55083
|
-
let
|
|
55236
|
+
let cache;
|
|
55084
55237
|
if (apiRef.current.caches.rows.rowsBeforePartialUpdates === props.rows) {
|
|
55085
|
-
|
|
55238
|
+
cache = _extends$2({}, apiRef.current.caches.rows, {
|
|
55086
55239
|
updates: {
|
|
55087
55240
|
type: "full",
|
|
55088
55241
|
rows: gridDataRowIdsSelector(apiRef)
|
|
55089
55242
|
}
|
|
55090
55243
|
});
|
|
55091
55244
|
} else {
|
|
55092
|
-
|
|
55245
|
+
cache = createRowsInternalCache({
|
|
55093
55246
|
rows: props.rows,
|
|
55094
55247
|
getRowId: props.getRowId,
|
|
55095
55248
|
loading: props.loading,
|
|
@@ -55097,7 +55250,7 @@ const useGridRows = (apiRef, props) => {
|
|
|
55097
55250
|
});
|
|
55098
55251
|
}
|
|
55099
55252
|
throttledRowsChange({
|
|
55100
|
-
cache
|
|
55253
|
+
cache,
|
|
55101
55254
|
throttle: false
|
|
55102
55255
|
});
|
|
55103
55256
|
}, [logger, apiRef, props.rows, props.getRowId, props.loading, props.rowCount, throttledRowsChange]);
|