tp-react-elements-dev 1.10.3 → 1.10.6

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/index.js CHANGED
@@ -57,13 +57,14 @@ var isWeb = typeof window !== 'undefined' &&
57
57
  function cloneObject(data) {
58
58
  let copy;
59
59
  const isArray = Array.isArray(data);
60
+ const isFileListInstance = typeof FileList !== 'undefined' ? data instanceof FileList : false;
60
61
  if (data instanceof Date) {
61
62
  copy = new Date(data);
62
63
  }
63
64
  else if (data instanceof Set) {
64
65
  copy = new Set(data);
65
66
  }
66
- else if (!(isWeb && (data instanceof Blob || data instanceof FileList)) &&
67
+ else if (!(isWeb && (data instanceof Blob || isFileListInstance)) &&
67
68
  (isArray || isObject$1(data))) {
68
69
  copy = isArray ? [] : {};
69
70
  if (!isArray && !isPlainObject$1(data)) {
@@ -122,13 +123,12 @@ var set = (object, path, value) => {
122
123
  ? []
123
124
  : {};
124
125
  }
125
- if (key === '__proto__') {
126
+ if (key === '__proto__' || key === 'constructor' || key === 'prototype') {
126
127
  return;
127
128
  }
128
129
  object[key] = newValue;
129
130
  object = object[key];
130
131
  }
131
- return object;
132
132
  };
133
133
 
134
134
  const EVENTS = {
@@ -205,43 +205,6 @@ var getProxyFormState = (formState, control, localProxyFormState, isRoot = true)
205
205
  return result;
206
206
  };
207
207
 
208
- var isEmptyObject = (value) => isObject$1(value) && !Object.keys(value).length;
209
-
210
- var shouldRenderFormState = (formStateData, _proxyFormState, updateFormState, isRoot) => {
211
- updateFormState(formStateData);
212
- const { name, ...formState } = formStateData;
213
- return (isEmptyObject(formState) ||
214
- Object.keys(formState).length >= Object.keys(_proxyFormState).length ||
215
- Object.keys(formState).find((key) => _proxyFormState[key] ===
216
- (!isRoot || VALIDATION_MODE.all)));
217
- };
218
-
219
- var convertToArrayPayload = (value) => (Array.isArray(value) ? value : [value]);
220
-
221
- var shouldSubscribeByName = (name, signalName, exact) => !name ||
222
- !signalName ||
223
- name === signalName ||
224
- convertToArrayPayload(name).some((currentName) => currentName &&
225
- (exact
226
- ? currentName === signalName
227
- : currentName.startsWith(signalName) ||
228
- signalName.startsWith(currentName)));
229
-
230
- function useSubscribe(props) {
231
- const _props = React$1.useRef(props);
232
- _props.current = props;
233
- React$1.useEffect(() => {
234
- const subscription = !props.disabled &&
235
- _props.current.subject &&
236
- _props.current.subject.subscribe({
237
- next: _props.current.next,
238
- });
239
- return () => {
240
- subscription && subscription.unsubscribe();
241
- };
242
- }, [props.disabled]);
243
- }
244
-
245
208
  /**
246
209
  * This custom hook allows you to subscribe to each form state, and isolate the re-render at the custom hook level. It has its scope in terms of form state subscription, so it would not affect other useFormState and useForm. Using this hook can reduce the re-render impact on large and complex form application.
247
210
  *
@@ -276,7 +239,6 @@ function useFormState(props) {
276
239
  const methods = useFormContext();
277
240
  const { control = methods.control, disabled, name, exact } = props || {};
278
241
  const [formState, updateFormState] = React$1.useState(control._formState);
279
- const _mounted = React$1.useRef(true);
280
242
  const _localProxyFormState = React$1.useRef({
281
243
  isDirty: false,
282
244
  isLoading: false,
@@ -289,25 +251,22 @@ function useFormState(props) {
289
251
  });
290
252
  const _name = React$1.useRef(name);
291
253
  _name.current = name;
292
- useSubscribe({
293
- disabled,
294
- next: (value) => _mounted.current &&
295
- shouldSubscribeByName(_name.current, value.name, exact) &&
296
- shouldRenderFormState(value, _localProxyFormState.current, control._updateFormState) &&
297
- updateFormState({
298
- ...control._formState,
299
- ...value,
300
- }),
301
- subject: control._subjects.state,
302
- });
254
+ React$1.useEffect(() => control._subscribe({
255
+ name: _name.current,
256
+ formState: _localProxyFormState.current,
257
+ exact,
258
+ callback: (formState) => {
259
+ !disabled &&
260
+ updateFormState({
261
+ ...control._formState,
262
+ ...formState,
263
+ });
264
+ },
265
+ }), [control, disabled, exact]);
303
266
  React$1.useEffect(() => {
304
- _mounted.current = true;
305
- _localProxyFormState.current.isValid && control._updateValid(true);
306
- return () => {
307
- _mounted.current = false;
308
- };
267
+ _localProxyFormState.current.isValid && control._setValid(true);
309
268
  }, [control]);
310
- return getProxyFormState(formState, control, _localProxyFormState.current, false);
269
+ return React$1.useMemo(() => getProxyFormState(formState, control, _localProxyFormState.current, false), [formState, control]);
311
270
  }
312
271
 
313
272
  var isString = (value) => typeof value === 'string';
@@ -344,16 +303,17 @@ function useWatch(props) {
344
303
  const methods = useFormContext();
345
304
  const { control = methods.control, name, defaultValue, disabled, exact, } = props || {};
346
305
  const _name = React$1.useRef(name);
306
+ const _defaultValue = React$1.useRef(defaultValue);
347
307
  _name.current = name;
348
- useSubscribe({
349
- disabled,
350
- subject: control._subjects.values,
351
- next: (formState) => {
352
- if (shouldSubscribeByName(_name.current, formState.name, exact)) {
353
- updateValue(cloneObject(generateWatchOutput(_name.current, control._names, formState.values || control._formValues, false, defaultValue)));
354
- }
308
+ React$1.useEffect(() => control._subscribe({
309
+ name: _name.current,
310
+ formState: {
311
+ values: true,
355
312
  },
356
- });
313
+ exact,
314
+ callback: (formState) => !disabled &&
315
+ updateValue(generateWatchOutput(_name.current, control._names, formState.values || control._formValues, false, _defaultValue.current)),
316
+ }), [control, disabled, exact]);
357
317
  const [value, updateValue] = React$1.useState(control._getWatch(name, defaultValue));
358
318
  React$1.useEffect(() => control._removeUnmounted());
359
319
  return value;
@@ -396,17 +356,82 @@ function useController(props) {
396
356
  const formState = useFormState({
397
357
  control,
398
358
  name,
359
+ exact: true,
399
360
  });
361
+ const _props = React$1.useRef(props);
400
362
  const _registerProps = React$1.useRef(control.register(name, {
401
363
  ...props.rules,
402
364
  value,
403
365
  ...(isBoolean(props.disabled) ? { disabled: props.disabled } : {}),
404
366
  }));
367
+ const fieldState = React$1.useMemo(() => Object.defineProperties({}, {
368
+ invalid: {
369
+ enumerable: true,
370
+ get: () => !!get(formState.errors, name),
371
+ },
372
+ isDirty: {
373
+ enumerable: true,
374
+ get: () => !!get(formState.dirtyFields, name),
375
+ },
376
+ isTouched: {
377
+ enumerable: true,
378
+ get: () => !!get(formState.touchedFields, name),
379
+ },
380
+ isValidating: {
381
+ enumerable: true,
382
+ get: () => !!get(formState.validatingFields, name),
383
+ },
384
+ error: {
385
+ enumerable: true,
386
+ get: () => get(formState.errors, name),
387
+ },
388
+ }), [formState, name]);
389
+ const onChange = React$1.useCallback((event) => _registerProps.current.onChange({
390
+ target: {
391
+ value: getEventValue(event),
392
+ name: name,
393
+ },
394
+ type: EVENTS.CHANGE,
395
+ }), [name]);
396
+ const onBlur = React$1.useCallback(() => _registerProps.current.onBlur({
397
+ target: {
398
+ value: get(control._formValues, name),
399
+ name: name,
400
+ },
401
+ type: EVENTS.BLUR,
402
+ }), [name, control._formValues]);
403
+ const ref = React$1.useCallback((elm) => {
404
+ const field = get(control._fields, name);
405
+ if (field && elm) {
406
+ field._f.ref = {
407
+ focus: () => elm.focus(),
408
+ select: () => elm.select(),
409
+ setCustomValidity: (message) => elm.setCustomValidity(message),
410
+ reportValidity: () => elm.reportValidity(),
411
+ };
412
+ }
413
+ }, [control._fields, name]);
414
+ const field = React$1.useMemo(() => ({
415
+ name,
416
+ value,
417
+ ...(isBoolean(disabled) || formState.disabled
418
+ ? { disabled: formState.disabled || disabled }
419
+ : {}),
420
+ onChange,
421
+ onBlur,
422
+ ref,
423
+ }), [name, disabled, formState.disabled, onChange, onBlur, ref, value]);
405
424
  React$1.useEffect(() => {
406
425
  const _shouldUnregisterField = control._options.shouldUnregister || shouldUnregister;
426
+ control.register(name, {
427
+ ..._props.current.rules,
428
+ ...(isBoolean(_props.current.disabled)
429
+ ? { disabled: _props.current.disabled }
430
+ : {}),
431
+ });
407
432
  const updateMounted = (name, value) => {
408
433
  const field = get(control._fields, name);
409
- if (field) {
434
+ if (field && field._f) {
410
435
  field._f.mount = value;
411
436
  }
412
437
  };
@@ -418,6 +443,7 @@ function useController(props) {
418
443
  set(control._formValues, name, value);
419
444
  }
420
445
  }
446
+ !isArrayField && control.register(name);
421
447
  return () => {
422
448
  (isArrayField
423
449
  ? _shouldUnregisterField && !control._state.action
@@ -427,72 +453,16 @@ function useController(props) {
427
453
  };
428
454
  }, [name, control, isArrayField, shouldUnregister]);
429
455
  React$1.useEffect(() => {
430
- if (get(control._fields, name)) {
431
- control._updateDisabledField({
432
- disabled,
433
- fields: control._fields,
434
- name,
435
- value: get(control._fields, name)._f.value,
436
- });
437
- }
438
- }, [disabled, name, control]);
439
- return {
440
- field: {
456
+ control._setDisabledField({
457
+ disabled,
441
458
  name,
442
- value,
443
- ...(isBoolean(disabled) || formState.disabled
444
- ? { disabled: formState.disabled || disabled }
445
- : {}),
446
- onChange: React$1.useCallback((event) => _registerProps.current.onChange({
447
- target: {
448
- value: getEventValue(event),
449
- name: name,
450
- },
451
- type: EVENTS.CHANGE,
452
- }), [name]),
453
- onBlur: React$1.useCallback(() => _registerProps.current.onBlur({
454
- target: {
455
- value: get(control._formValues, name),
456
- name: name,
457
- },
458
- type: EVENTS.BLUR,
459
- }), [name, control]),
460
- ref: (elm) => {
461
- const field = get(control._fields, name);
462
- if (field && elm) {
463
- field._f.ref = {
464
- focus: () => elm.focus(),
465
- select: () => elm.select(),
466
- setCustomValidity: (message) => elm.setCustomValidity(message),
467
- reportValidity: () => elm.reportValidity(),
468
- };
469
- }
470
- },
471
- },
459
+ });
460
+ }, [disabled, name, control]);
461
+ return React$1.useMemo(() => ({
462
+ field,
472
463
  formState,
473
- fieldState: Object.defineProperties({}, {
474
- invalid: {
475
- enumerable: true,
476
- get: () => !!get(formState.errors, name),
477
- },
478
- isDirty: {
479
- enumerable: true,
480
- get: () => !!get(formState.dirtyFields, name),
481
- },
482
- isTouched: {
483
- enumerable: true,
484
- get: () => !!get(formState.touchedFields, name),
485
- },
486
- isValidating: {
487
- enumerable: true,
488
- get: () => !!get(formState.validatingFields, name),
489
- },
490
- error: {
491
- enumerable: true,
492
- get: () => get(formState.errors, name),
493
- },
494
- }),
495
- };
464
+ fieldState,
465
+ }), [field, formState, fieldState]);
496
466
  }
497
467
 
498
468
  /**
@@ -549,49 +519,70 @@ var appendErrors = (name, validateAllFieldCriteria, errors, type, message) => va
549
519
  }
550
520
  : {};
551
521
 
552
- var getValidationModes = (mode) => ({
553
- isOnSubmit: !mode || mode === VALIDATION_MODE.onSubmit,
554
- isOnBlur: mode === VALIDATION_MODE.onBlur,
555
- isOnChange: mode === VALIDATION_MODE.onChange,
556
- isOnAll: mode === VALIDATION_MODE.all,
557
- isOnTouch: mode === VALIDATION_MODE.onTouched,
558
- });
522
+ var convertToArrayPayload = (value) => (Array.isArray(value) ? value : [value]);
559
523
 
560
- var isWatched = (name, _names, isBlurEvent) => !isBlurEvent &&
561
- (_names.watchAll ||
562
- _names.watch.has(name) ||
563
- [..._names.watch].some((watchName) => name.startsWith(watchName) &&
564
- /^\.\w+/.test(name.slice(watchName.length))));
524
+ var createSubject = () => {
525
+ let _observers = [];
526
+ const next = (value) => {
527
+ for (const observer of _observers) {
528
+ observer.next && observer.next(value);
529
+ }
530
+ };
531
+ const subscribe = (observer) => {
532
+ _observers.push(observer);
533
+ return {
534
+ unsubscribe: () => {
535
+ _observers = _observers.filter((o) => o !== observer);
536
+ },
537
+ };
538
+ };
539
+ const unsubscribe = () => {
540
+ _observers = [];
541
+ };
542
+ return {
543
+ get observers() {
544
+ return _observers;
545
+ },
546
+ next,
547
+ subscribe,
548
+ unsubscribe,
549
+ };
550
+ };
565
551
 
566
- const iterateFieldsByAction = (fields, action, fieldsNames, abortEarly) => {
567
- for (const key of fieldsNames || Object.keys(fields)) {
568
- const field = get(fields, key);
569
- if (field) {
570
- const { _f, ...currentField } = field;
571
- if (_f) {
572
- if (_f.refs && _f.refs[0] && action(_f.refs[0], key) && !abortEarly) {
573
- break;
574
- }
575
- else if (_f.ref && action(_f.ref, _f.name) && !abortEarly) {
576
- break;
577
- }
578
- else {
579
- iterateFieldsByAction(currentField, action);
580
- }
581
- }
582
- else if (isObject$1(currentField)) {
583
- iterateFieldsByAction(currentField, action);
552
+ var isPrimitive = (value) => isNullOrUndefined(value) || !isObjectType(value);
553
+
554
+ function deepEqual(object1, object2) {
555
+ if (isPrimitive(object1) || isPrimitive(object2)) {
556
+ return object1 === object2;
557
+ }
558
+ if (isDateObject(object1) && isDateObject(object2)) {
559
+ return object1.getTime() === object2.getTime();
560
+ }
561
+ const keys1 = Object.keys(object1);
562
+ const keys2 = Object.keys(object2);
563
+ if (keys1.length !== keys2.length) {
564
+ return false;
565
+ }
566
+ for (const key of keys1) {
567
+ const val1 = object1[key];
568
+ if (!keys2.includes(key)) {
569
+ return false;
570
+ }
571
+ if (key !== 'ref') {
572
+ const val2 = object2[key];
573
+ if ((isDateObject(val1) && isDateObject(val2)) ||
574
+ (isObject$1(val1) && isObject$1(val2)) ||
575
+ (Array.isArray(val1) && Array.isArray(val2))
576
+ ? !deepEqual(val1, val2)
577
+ : val1 !== val2) {
578
+ return false;
584
579
  }
585
580
  }
586
581
  }
587
- };
582
+ return true;
583
+ }
588
584
 
589
- var updateFieldArrayRootError = (errors, error, name) => {
590
- const fieldArrayErrors = compact(get(errors, name));
591
- set(fieldArrayErrors, 'root', error[name]);
592
- set(errors, name, fieldArrayErrors);
593
- return errors;
594
- };
585
+ var isEmptyObject = (value) => isObject$1(value) && !Object.keys(value).length;
595
586
 
596
587
  var isFileInput = (element) => element.type === 'file';
597
588
 
@@ -606,11 +597,99 @@ var isHTMLElement$2 = (value) => {
606
597
  (owner && owner.defaultView ? owner.defaultView.HTMLElement : HTMLElement));
607
598
  };
608
599
 
609
- var isMessage = (value) => isString(value);
600
+ var isMultipleSelect = (element) => element.type === `select-multiple`;
610
601
 
611
602
  var isRadioInput = (element) => element.type === 'radio';
612
603
 
613
- var isRegex = (value) => value instanceof RegExp;
604
+ var isRadioOrCheckbox = (ref) => isRadioInput(ref) || isCheckBoxInput(ref);
605
+
606
+ var live = (ref) => isHTMLElement$2(ref) && ref.isConnected;
607
+
608
+ function baseGet(object, updatePath) {
609
+ const length = updatePath.slice(0, -1).length;
610
+ let index = 0;
611
+ while (index < length) {
612
+ object = isUndefined(object) ? index++ : object[updatePath[index++]];
613
+ }
614
+ return object;
615
+ }
616
+ function isEmptyArray(obj) {
617
+ for (const key in obj) {
618
+ if (obj.hasOwnProperty(key) && !isUndefined(obj[key])) {
619
+ return false;
620
+ }
621
+ }
622
+ return true;
623
+ }
624
+ function unset(object, path) {
625
+ const paths = Array.isArray(path)
626
+ ? path
627
+ : isKey(path)
628
+ ? [path]
629
+ : stringToPath(path);
630
+ const childObject = paths.length === 1 ? object : baseGet(object, paths);
631
+ const index = paths.length - 1;
632
+ const key = paths[index];
633
+ if (childObject) {
634
+ delete childObject[key];
635
+ }
636
+ if (index !== 0 &&
637
+ ((isObject$1(childObject) && isEmptyObject(childObject)) ||
638
+ (Array.isArray(childObject) && isEmptyArray(childObject)))) {
639
+ unset(object, paths.slice(0, -1));
640
+ }
641
+ return object;
642
+ }
643
+
644
+ var objectHasFunction = (data) => {
645
+ for (const key in data) {
646
+ if (isFunction(data[key])) {
647
+ return true;
648
+ }
649
+ }
650
+ return false;
651
+ };
652
+
653
+ function markFieldsDirty(data, fields = {}) {
654
+ const isParentNodeArray = Array.isArray(data);
655
+ if (isObject$1(data) || isParentNodeArray) {
656
+ for (const key in data) {
657
+ if (Array.isArray(data[key]) ||
658
+ (isObject$1(data[key]) && !objectHasFunction(data[key]))) {
659
+ fields[key] = Array.isArray(data[key]) ? [] : {};
660
+ markFieldsDirty(data[key], fields[key]);
661
+ }
662
+ else if (!isNullOrUndefined(data[key])) {
663
+ fields[key] = true;
664
+ }
665
+ }
666
+ }
667
+ return fields;
668
+ }
669
+ function getDirtyFieldsFromDefaultValues(data, formValues, dirtyFieldsFromValues) {
670
+ const isParentNodeArray = Array.isArray(data);
671
+ if (isObject$1(data) || isParentNodeArray) {
672
+ for (const key in data) {
673
+ if (Array.isArray(data[key]) ||
674
+ (isObject$1(data[key]) && !objectHasFunction(data[key]))) {
675
+ if (isUndefined(formValues) ||
676
+ isPrimitive(dirtyFieldsFromValues[key])) {
677
+ dirtyFieldsFromValues[key] = Array.isArray(data[key])
678
+ ? markFieldsDirty(data[key], [])
679
+ : { ...markFieldsDirty(data[key]) };
680
+ }
681
+ else {
682
+ getDirtyFieldsFromDefaultValues(data[key], isNullOrUndefined(formValues) ? {} : formValues[key], dirtyFieldsFromValues[key]);
683
+ }
684
+ }
685
+ else {
686
+ dirtyFieldsFromValues[key] = !deepEqual(data[key], formValues[key]);
687
+ }
688
+ }
689
+ }
690
+ return dirtyFieldsFromValues;
691
+ }
692
+ var getDirtyFields = (defaultValues, formValues) => getDirtyFieldsFromDefaultValues(defaultValues, formValues, markFieldsDirty(formValues));
614
693
 
615
694
  const defaultResult = {
616
695
  value: false,
@@ -637,6 +716,20 @@ var getCheckboxValue = (options) => {
637
716
  return defaultResult;
638
717
  };
639
718
 
719
+ var getFieldValueAs = (value, { valueAsNumber, valueAsDate, setValueAs }) => isUndefined(value)
720
+ ? value
721
+ : valueAsNumber
722
+ ? value === ''
723
+ ? NaN
724
+ : value
725
+ ? +value
726
+ : value
727
+ : valueAsDate && isString(value)
728
+ ? new Date(value)
729
+ : setValueAs
730
+ ? setValueAs(value)
731
+ : value;
732
+
640
733
  const defaultReturn = {
641
734
  isValid: false,
642
735
  value: null,
@@ -650,6 +743,182 @@ var getRadioValue = (options) => Array.isArray(options)
650
743
  : previous, defaultReturn)
651
744
  : defaultReturn;
652
745
 
746
+ function getFieldValue(_f) {
747
+ const ref = _f.ref;
748
+ if (isFileInput(ref)) {
749
+ return ref.files;
750
+ }
751
+ if (isRadioInput(ref)) {
752
+ return getRadioValue(_f.refs).value;
753
+ }
754
+ if (isMultipleSelect(ref)) {
755
+ return [...ref.selectedOptions].map(({ value }) => value);
756
+ }
757
+ if (isCheckBoxInput(ref)) {
758
+ return getCheckboxValue(_f.refs).value;
759
+ }
760
+ return getFieldValueAs(isUndefined(ref.value) ? _f.ref.value : ref.value, _f);
761
+ }
762
+
763
+ var getResolverOptions = (fieldsNames, _fields, criteriaMode, shouldUseNativeValidation) => {
764
+ const fields = {};
765
+ for (const name of fieldsNames) {
766
+ const field = get(_fields, name);
767
+ field && set(fields, name, field._f);
768
+ }
769
+ return {
770
+ criteriaMode,
771
+ names: [...fieldsNames],
772
+ fields,
773
+ shouldUseNativeValidation,
774
+ };
775
+ };
776
+
777
+ var isRegex = (value) => value instanceof RegExp;
778
+
779
+ var getRuleValue = (rule) => isUndefined(rule)
780
+ ? rule
781
+ : isRegex(rule)
782
+ ? rule.source
783
+ : isObject$1(rule)
784
+ ? isRegex(rule.value)
785
+ ? rule.value.source
786
+ : rule.value
787
+ : rule;
788
+
789
+ var getValidationModes = (mode) => ({
790
+ isOnSubmit: !mode || mode === VALIDATION_MODE.onSubmit,
791
+ isOnBlur: mode === VALIDATION_MODE.onBlur,
792
+ isOnChange: mode === VALIDATION_MODE.onChange,
793
+ isOnAll: mode === VALIDATION_MODE.all,
794
+ isOnTouch: mode === VALIDATION_MODE.onTouched,
795
+ });
796
+
797
+ const ASYNC_FUNCTION = 'AsyncFunction';
798
+ var hasPromiseValidation = (fieldReference) => !!fieldReference &&
799
+ !!fieldReference.validate &&
800
+ !!((isFunction(fieldReference.validate) &&
801
+ fieldReference.validate.constructor.name === ASYNC_FUNCTION) ||
802
+ (isObject$1(fieldReference.validate) &&
803
+ Object.values(fieldReference.validate).find((validateFunction) => validateFunction.constructor.name === ASYNC_FUNCTION)));
804
+
805
+ var hasValidation = (options) => options.mount &&
806
+ (options.required ||
807
+ options.min ||
808
+ options.max ||
809
+ options.maxLength ||
810
+ options.minLength ||
811
+ options.pattern ||
812
+ options.validate);
813
+
814
+ var isWatched = (name, _names, isBlurEvent) => !isBlurEvent &&
815
+ (_names.watchAll ||
816
+ _names.watch.has(name) ||
817
+ [..._names.watch].some((watchName) => name.startsWith(watchName) &&
818
+ /^\.\w+/.test(name.slice(watchName.length))));
819
+
820
+ const iterateFieldsByAction = (fields, action, fieldsNames, abortEarly) => {
821
+ for (const key of fieldsNames || Object.keys(fields)) {
822
+ const field = get(fields, key);
823
+ if (field) {
824
+ const { _f, ...currentField } = field;
825
+ if (_f) {
826
+ if (_f.refs && _f.refs[0] && action(_f.refs[0], key) && !abortEarly) {
827
+ return true;
828
+ }
829
+ else if (_f.ref && action(_f.ref, _f.name) && !abortEarly) {
830
+ return true;
831
+ }
832
+ else {
833
+ if (iterateFieldsByAction(currentField, action)) {
834
+ break;
835
+ }
836
+ }
837
+ }
838
+ else if (isObject$1(currentField)) {
839
+ if (iterateFieldsByAction(currentField, action)) {
840
+ break;
841
+ }
842
+ }
843
+ }
844
+ }
845
+ return;
846
+ };
847
+
848
+ function schemaErrorLookup(errors, _fields, name) {
849
+ const error = get(errors, name);
850
+ if (error || isKey(name)) {
851
+ return {
852
+ error,
853
+ name,
854
+ };
855
+ }
856
+ const names = name.split('.');
857
+ while (names.length) {
858
+ const fieldName = names.join('.');
859
+ const field = get(_fields, fieldName);
860
+ const foundError = get(errors, fieldName);
861
+ if (field && !Array.isArray(field) && name !== fieldName) {
862
+ return { name };
863
+ }
864
+ if (foundError && foundError.type) {
865
+ return {
866
+ name: fieldName,
867
+ error: foundError,
868
+ };
869
+ }
870
+ names.pop();
871
+ }
872
+ return {
873
+ name,
874
+ };
875
+ }
876
+
877
+ var shouldRenderFormState = (formStateData, _proxyFormState, updateFormState, isRoot) => {
878
+ updateFormState(formStateData);
879
+ const { name, ...formState } = formStateData;
880
+ return (isEmptyObject(formState) ||
881
+ Object.keys(formState).length >= Object.keys(_proxyFormState).length ||
882
+ Object.keys(formState).find((key) => _proxyFormState[key] ===
883
+ (!isRoot || VALIDATION_MODE.all)));
884
+ };
885
+
886
+ var shouldSubscribeByName = (name, signalName, exact) => !name ||
887
+ !signalName ||
888
+ name === signalName ||
889
+ convertToArrayPayload(name).some((currentName) => currentName &&
890
+ (exact
891
+ ? currentName === signalName
892
+ : currentName.startsWith(signalName) ||
893
+ signalName.startsWith(currentName)));
894
+
895
+ var skipValidation = (isBlurEvent, isTouched, isSubmitted, reValidateMode, mode) => {
896
+ if (mode.isOnAll) {
897
+ return false;
898
+ }
899
+ else if (!isSubmitted && mode.isOnTouch) {
900
+ return !(isTouched || isBlurEvent);
901
+ }
902
+ else if (isSubmitted ? reValidateMode.isOnBlur : mode.isOnBlur) {
903
+ return !isBlurEvent;
904
+ }
905
+ else if (isSubmitted ? reValidateMode.isOnChange : mode.isOnChange) {
906
+ return isBlurEvent;
907
+ }
908
+ return true;
909
+ };
910
+
911
+ var unsetEmptyArray = (ref, name) => !compact(get(ref, name)).length && unset(ref, name);
912
+
913
+ var updateFieldArrayRootError = (errors, error, name) => {
914
+ const fieldArrayErrors = convertToArrayPayload(get(errors, name));
915
+ set(fieldArrayErrors, 'root', error[name]);
916
+ set(errors, name, fieldArrayErrors);
917
+ return errors;
918
+ };
919
+
920
+ var isMessage = (value) => isString(value);
921
+
653
922
  function getValidateError(result, ref, type = 'validate') {
654
923
  if (isMessage(result) ||
655
924
  (Array.isArray(result) && result.every(isMessage)) ||
@@ -669,10 +938,10 @@ var getValueAndMessage = (validationData) => isObject$1(validationData) && !isRe
669
938
  message: '',
670
939
  };
671
940
 
672
- var validateField = async (field, formValues, validateAllFieldCriteria, shouldUseNativeValidation, isFieldArray) => {
673
- const { ref, refs, required, maxLength, minLength, min, max, pattern, validate, name, valueAsNumber, mount, disabled, } = field._f;
941
+ var validateField = async (field, disabledFieldNames, formValues, validateAllFieldCriteria, shouldUseNativeValidation, isFieldArray) => {
942
+ const { ref, refs, required, maxLength, minLength, min, max, pattern, validate, name, valueAsNumber, mount, } = field._f;
674
943
  const inputValue = get(formValues, name);
675
- if (!mount || disabled) {
944
+ if (!mount || disabledFieldNames.has(name)) {
676
945
  return {};
677
946
  }
678
947
  const inputRef = refs ? refs[0] : ref;
@@ -848,273 +1117,6 @@ var validateField = async (field, formValues, validateAllFieldCriteria, shouldUs
848
1117
  return error;
849
1118
  };
850
1119
 
851
- function baseGet(object, updatePath) {
852
- const length = updatePath.slice(0, -1).length;
853
- let index = 0;
854
- while (index < length) {
855
- object = isUndefined(object) ? index++ : object[updatePath[index++]];
856
- }
857
- return object;
858
- }
859
- function isEmptyArray(obj) {
860
- for (const key in obj) {
861
- if (obj.hasOwnProperty(key) && !isUndefined(obj[key])) {
862
- return false;
863
- }
864
- }
865
- return true;
866
- }
867
- function unset(object, path) {
868
- const paths = Array.isArray(path)
869
- ? path
870
- : isKey(path)
871
- ? [path]
872
- : stringToPath(path);
873
- const childObject = paths.length === 1 ? object : baseGet(object, paths);
874
- const index = paths.length - 1;
875
- const key = paths[index];
876
- if (childObject) {
877
- delete childObject[key];
878
- }
879
- if (index !== 0 &&
880
- ((isObject$1(childObject) && isEmptyObject(childObject)) ||
881
- (Array.isArray(childObject) && isEmptyArray(childObject)))) {
882
- unset(object, paths.slice(0, -1));
883
- }
884
- return object;
885
- }
886
-
887
- var createSubject = () => {
888
- let _observers = [];
889
- const next = (value) => {
890
- for (const observer of _observers) {
891
- observer.next && observer.next(value);
892
- }
893
- };
894
- const subscribe = (observer) => {
895
- _observers.push(observer);
896
- return {
897
- unsubscribe: () => {
898
- _observers = _observers.filter((o) => o !== observer);
899
- },
900
- };
901
- };
902
- const unsubscribe = () => {
903
- _observers = [];
904
- };
905
- return {
906
- get observers() {
907
- return _observers;
908
- },
909
- next,
910
- subscribe,
911
- unsubscribe,
912
- };
913
- };
914
-
915
- var isPrimitive = (value) => isNullOrUndefined(value) || !isObjectType(value);
916
-
917
- function deepEqual(object1, object2) {
918
- if (isPrimitive(object1) || isPrimitive(object2)) {
919
- return object1 === object2;
920
- }
921
- if (isDateObject(object1) && isDateObject(object2)) {
922
- return object1.getTime() === object2.getTime();
923
- }
924
- const keys1 = Object.keys(object1);
925
- const keys2 = Object.keys(object2);
926
- if (keys1.length !== keys2.length) {
927
- return false;
928
- }
929
- for (const key of keys1) {
930
- const val1 = object1[key];
931
- if (!keys2.includes(key)) {
932
- return false;
933
- }
934
- if (key !== 'ref') {
935
- const val2 = object2[key];
936
- if ((isDateObject(val1) && isDateObject(val2)) ||
937
- (isObject$1(val1) && isObject$1(val2)) ||
938
- (Array.isArray(val1) && Array.isArray(val2))
939
- ? !deepEqual(val1, val2)
940
- : val1 !== val2) {
941
- return false;
942
- }
943
- }
944
- }
945
- return true;
946
- }
947
-
948
- var isMultipleSelect = (element) => element.type === `select-multiple`;
949
-
950
- var isRadioOrCheckbox = (ref) => isRadioInput(ref) || isCheckBoxInput(ref);
951
-
952
- var live = (ref) => isHTMLElement$2(ref) && ref.isConnected;
953
-
954
- var objectHasFunction = (data) => {
955
- for (const key in data) {
956
- if (isFunction(data[key])) {
957
- return true;
958
- }
959
- }
960
- return false;
961
- };
962
-
963
- function markFieldsDirty(data, fields = {}) {
964
- const isParentNodeArray = Array.isArray(data);
965
- if (isObject$1(data) || isParentNodeArray) {
966
- for (const key in data) {
967
- if (Array.isArray(data[key]) ||
968
- (isObject$1(data[key]) && !objectHasFunction(data[key]))) {
969
- fields[key] = Array.isArray(data[key]) ? [] : {};
970
- markFieldsDirty(data[key], fields[key]);
971
- }
972
- else if (!isNullOrUndefined(data[key])) {
973
- fields[key] = true;
974
- }
975
- }
976
- }
977
- return fields;
978
- }
979
- function getDirtyFieldsFromDefaultValues(data, formValues, dirtyFieldsFromValues) {
980
- const isParentNodeArray = Array.isArray(data);
981
- if (isObject$1(data) || isParentNodeArray) {
982
- for (const key in data) {
983
- if (Array.isArray(data[key]) ||
984
- (isObject$1(data[key]) && !objectHasFunction(data[key]))) {
985
- if (isUndefined(formValues) ||
986
- isPrimitive(dirtyFieldsFromValues[key])) {
987
- dirtyFieldsFromValues[key] = Array.isArray(data[key])
988
- ? markFieldsDirty(data[key], [])
989
- : { ...markFieldsDirty(data[key]) };
990
- }
991
- else {
992
- getDirtyFieldsFromDefaultValues(data[key], isNullOrUndefined(formValues) ? {} : formValues[key], dirtyFieldsFromValues[key]);
993
- }
994
- }
995
- else {
996
- dirtyFieldsFromValues[key] = !deepEqual(data[key], formValues[key]);
997
- }
998
- }
999
- }
1000
- return dirtyFieldsFromValues;
1001
- }
1002
- var getDirtyFields = (defaultValues, formValues) => getDirtyFieldsFromDefaultValues(defaultValues, formValues, markFieldsDirty(formValues));
1003
-
1004
- var getFieldValueAs = (value, { valueAsNumber, valueAsDate, setValueAs }) => isUndefined(value)
1005
- ? value
1006
- : valueAsNumber
1007
- ? value === ''
1008
- ? NaN
1009
- : value
1010
- ? +value
1011
- : value
1012
- : valueAsDate && isString(value)
1013
- ? new Date(value)
1014
- : setValueAs
1015
- ? setValueAs(value)
1016
- : value;
1017
-
1018
- function getFieldValue(_f) {
1019
- const ref = _f.ref;
1020
- if (_f.refs ? _f.refs.every((ref) => ref.disabled) : ref.disabled) {
1021
- return;
1022
- }
1023
- if (isFileInput(ref)) {
1024
- return ref.files;
1025
- }
1026
- if (isRadioInput(ref)) {
1027
- return getRadioValue(_f.refs).value;
1028
- }
1029
- if (isMultipleSelect(ref)) {
1030
- return [...ref.selectedOptions].map(({ value }) => value);
1031
- }
1032
- if (isCheckBoxInput(ref)) {
1033
- return getCheckboxValue(_f.refs).value;
1034
- }
1035
- return getFieldValueAs(isUndefined(ref.value) ? _f.ref.value : ref.value, _f);
1036
- }
1037
-
1038
- var getResolverOptions = (fieldsNames, _fields, criteriaMode, shouldUseNativeValidation) => {
1039
- const fields = {};
1040
- for (const name of fieldsNames) {
1041
- const field = get(_fields, name);
1042
- field && set(fields, name, field._f);
1043
- }
1044
- return {
1045
- criteriaMode,
1046
- names: [...fieldsNames],
1047
- fields,
1048
- shouldUseNativeValidation,
1049
- };
1050
- };
1051
-
1052
- var getRuleValue = (rule) => isUndefined(rule)
1053
- ? rule
1054
- : isRegex(rule)
1055
- ? rule.source
1056
- : isObject$1(rule)
1057
- ? isRegex(rule.value)
1058
- ? rule.value.source
1059
- : rule.value
1060
- : rule;
1061
-
1062
- var hasValidation = (options) => options.mount &&
1063
- (options.required ||
1064
- options.min ||
1065
- options.max ||
1066
- options.maxLength ||
1067
- options.minLength ||
1068
- options.pattern ||
1069
- options.validate);
1070
-
1071
- function schemaErrorLookup(errors, _fields, name) {
1072
- const error = get(errors, name);
1073
- if (error || isKey(name)) {
1074
- return {
1075
- error,
1076
- name,
1077
- };
1078
- }
1079
- const names = name.split('.');
1080
- while (names.length) {
1081
- const fieldName = names.join('.');
1082
- const field = get(_fields, fieldName);
1083
- const foundError = get(errors, fieldName);
1084
- if (field && !Array.isArray(field) && name !== fieldName) {
1085
- return { name };
1086
- }
1087
- if (foundError && foundError.type) {
1088
- return {
1089
- name: fieldName,
1090
- error: foundError,
1091
- };
1092
- }
1093
- names.pop();
1094
- }
1095
- return {
1096
- name,
1097
- };
1098
- }
1099
-
1100
- var skipValidation = (isBlurEvent, isTouched, isSubmitted, reValidateMode, mode) => {
1101
- if (mode.isOnAll) {
1102
- return false;
1103
- }
1104
- else if (!isSubmitted && mode.isOnTouch) {
1105
- return !(isTouched || isBlurEvent);
1106
- }
1107
- else if (isSubmitted ? reValidateMode.isOnBlur : mode.isOnBlur) {
1108
- return !isBlurEvent;
1109
- }
1110
- else if (isSubmitted ? reValidateMode.isOnChange : mode.isOnChange) {
1111
- return isBlurEvent;
1112
- }
1113
- return true;
1114
- };
1115
-
1116
- var unsetEmptyArray = (ref, name) => !compact(get(ref, name)).length && unset(ref, name);
1117
-
1118
1120
  const defaultOptions$2 = {
1119
1121
  mode: VALIDATION_MODE.onSubmit,
1120
1122
  reValidateMode: VALIDATION_MODE.onChange,
@@ -1140,9 +1142,9 @@ function createFormControl(props = {}) {
1140
1142
  errors: _options.errors || {},
1141
1143
  disabled: _options.disabled || false,
1142
1144
  };
1143
- let _fields = {};
1145
+ const _fields = {};
1144
1146
  let _defaultValues = isObject$1(_options.defaultValues) || isObject$1(_options.values)
1145
- ? cloneObject(_options.defaultValues || _options.values) || {}
1147
+ ? cloneObject(_options.values || _options.defaultValues) || {}
1146
1148
  : {};
1147
1149
  let _formValues = _options.shouldUnregister
1148
1150
  ? {}
@@ -1154,6 +1156,7 @@ function createFormControl(props = {}) {
1154
1156
  };
1155
1157
  let _names = {
1156
1158
  mount: new Set(),
1159
+ disabled: new Set(),
1157
1160
  unMount: new Set(),
1158
1161
  array: new Set(),
1159
1162
  watch: new Set(),
@@ -1169,8 +1172,10 @@ function createFormControl(props = {}) {
1169
1172
  isValid: false,
1170
1173
  errors: false,
1171
1174
  };
1175
+ let _proxySubscribeFormState = {
1176
+ ..._proxyFormState,
1177
+ };
1172
1178
  const _subjects = {
1173
- values: createSubject(),
1174
1179
  array: createSubject(),
1175
1180
  state: createSubject(),
1176
1181
  };
@@ -1181,10 +1186,13 @@ function createFormControl(props = {}) {
1181
1186
  clearTimeout(timer);
1182
1187
  timer = setTimeout(callback, wait);
1183
1188
  };
1184
- const _updateValid = async (shouldUpdateValid) => {
1185
- if (_proxyFormState.isValid || shouldUpdateValid) {
1189
+ const _setValid = async (shouldUpdateValid) => {
1190
+ if (!_options.disabled &&
1191
+ (_proxyFormState.isValid ||
1192
+ _proxySubscribeFormState.isValid ||
1193
+ shouldUpdateValid)) {
1186
1194
  const isValid = _options.resolver
1187
- ? isEmptyObject((await _executeSchema()).errors)
1195
+ ? isEmptyObject((await _runSchema()).errors)
1188
1196
  : await executeBuiltInValidation(_fields, true);
1189
1197
  if (isValid !== _formState.isValid) {
1190
1198
  _subjects.state.next({
@@ -1194,7 +1202,11 @@ function createFormControl(props = {}) {
1194
1202
  }
1195
1203
  };
1196
1204
  const _updateIsValidating = (names, isValidating) => {
1197
- if (_proxyFormState.isValidating || _proxyFormState.validatingFields) {
1205
+ if (!_options.disabled &&
1206
+ (_proxyFormState.isValidating ||
1207
+ _proxyFormState.validatingFields ||
1208
+ _proxySubscribeFormState.isValidating ||
1209
+ _proxySubscribeFormState.validatingFields)) {
1198
1210
  (names || Array.from(_names.mount)).forEach((name) => {
1199
1211
  if (name) {
1200
1212
  isValidating
@@ -1208,8 +1220,8 @@ function createFormControl(props = {}) {
1208
1220
  });
1209
1221
  }
1210
1222
  };
1211
- const _updateFieldArray = (name, values = [], method, args, shouldSetValues = true, shouldUpdateFieldsAndState = true) => {
1212
- if (args && method) {
1223
+ const _setFieldArray = (name, values = [], method, args, shouldSetValues = true, shouldUpdateFieldsAndState = true) => {
1224
+ if (args && method && !_options.disabled) {
1213
1225
  _state.action = true;
1214
1226
  if (shouldUpdateFieldsAndState && Array.isArray(get(_fields, name))) {
1215
1227
  const fieldValues = method(get(_fields, name), args.argA, args.argB);
@@ -1221,13 +1233,14 @@ function createFormControl(props = {}) {
1221
1233
  shouldSetValues && set(_formState.errors, name, errors);
1222
1234
  unsetEmptyArray(_formState.errors, name);
1223
1235
  }
1224
- if (_proxyFormState.touchedFields &&
1236
+ if ((_proxyFormState.touchedFields ||
1237
+ _proxySubscribeFormState.touchedFields) &&
1225
1238
  shouldUpdateFieldsAndState &&
1226
1239
  Array.isArray(get(_formState.touchedFields, name))) {
1227
1240
  const touchedFields = method(get(_formState.touchedFields, name), args.argA, args.argB);
1228
1241
  shouldSetValues && set(_formState.touchedFields, name, touchedFields);
1229
1242
  }
1230
- if (_proxyFormState.dirtyFields) {
1243
+ if (_proxyFormState.dirtyFields || _proxySubscribeFormState.dirtyFields) {
1231
1244
  _formState.dirtyFields = getDirtyFields(_defaultValues, _formValues);
1232
1245
  }
1233
1246
  _subjects.state.next({
@@ -1264,7 +1277,7 @@ function createFormControl(props = {}) {
1264
1277
  shouldSkipSetValueAs
1265
1278
  ? set(_formValues, name, shouldSkipSetValueAs ? defaultValue : getFieldValue(field._f))
1266
1279
  : setFieldValue(name, defaultValue);
1267
- _state.mount && _updateValid();
1280
+ _state.mount && _setValid();
1268
1281
  }
1269
1282
  };
1270
1283
  const updateTouchAndDirty = (name, fieldValue, isBlurEvent, shouldDirty, shouldRender) => {
@@ -1273,46 +1286,49 @@ function createFormControl(props = {}) {
1273
1286
  const output = {
1274
1287
  name,
1275
1288
  };
1276
- const disabledField = !!(get(_fields, name) && get(_fields, name)._f.disabled);
1277
- if (!isBlurEvent || shouldDirty) {
1278
- if (_proxyFormState.isDirty) {
1279
- isPreviousDirty = _formState.isDirty;
1280
- _formState.isDirty = output.isDirty = _getDirty();
1281
- shouldUpdateField = isPreviousDirty !== output.isDirty;
1282
- }
1283
- const isCurrentFieldPristine = disabledField || deepEqual(get(_defaultValues, name), fieldValue);
1284
- isPreviousDirty = !!(!disabledField && get(_formState.dirtyFields, name));
1285
- isCurrentFieldPristine || disabledField
1286
- ? unset(_formState.dirtyFields, name)
1287
- : set(_formState.dirtyFields, name, true);
1288
- output.dirtyFields = _formState.dirtyFields;
1289
- shouldUpdateField =
1290
- shouldUpdateField ||
1291
- (_proxyFormState.dirtyFields &&
1292
- isPreviousDirty !== !isCurrentFieldPristine);
1293
- }
1294
- if (isBlurEvent) {
1295
- const isPreviousFieldTouched = get(_formState.touchedFields, name);
1296
- if (!isPreviousFieldTouched) {
1297
- set(_formState.touchedFields, name, isBlurEvent);
1298
- output.touchedFields = _formState.touchedFields;
1289
+ if (!_options.disabled) {
1290
+ if (!isBlurEvent || shouldDirty) {
1291
+ if (_proxyFormState.isDirty || _proxySubscribeFormState.isDirty) {
1292
+ isPreviousDirty = _formState.isDirty;
1293
+ _formState.isDirty = output.isDirty = _getDirty();
1294
+ shouldUpdateField = isPreviousDirty !== output.isDirty;
1295
+ }
1296
+ const isCurrentFieldPristine = deepEqual(get(_defaultValues, name), fieldValue);
1297
+ isPreviousDirty = !!get(_formState.dirtyFields, name);
1298
+ isCurrentFieldPristine
1299
+ ? unset(_formState.dirtyFields, name)
1300
+ : set(_formState.dirtyFields, name, true);
1301
+ output.dirtyFields = _formState.dirtyFields;
1299
1302
  shouldUpdateField =
1300
1303
  shouldUpdateField ||
1301
- (_proxyFormState.touchedFields &&
1302
- isPreviousFieldTouched !== isBlurEvent);
1304
+ ((_proxyFormState.dirtyFields ||
1305
+ _proxySubscribeFormState.dirtyFields) &&
1306
+ isPreviousDirty !== !isCurrentFieldPristine);
1303
1307
  }
1308
+ if (isBlurEvent) {
1309
+ const isPreviousFieldTouched = get(_formState.touchedFields, name);
1310
+ if (!isPreviousFieldTouched) {
1311
+ set(_formState.touchedFields, name, isBlurEvent);
1312
+ output.touchedFields = _formState.touchedFields;
1313
+ shouldUpdateField =
1314
+ shouldUpdateField ||
1315
+ ((_proxyFormState.touchedFields ||
1316
+ _proxySubscribeFormState.touchedFields) &&
1317
+ isPreviousFieldTouched !== isBlurEvent);
1318
+ }
1319
+ }
1320
+ shouldUpdateField && shouldRender && _subjects.state.next(output);
1304
1321
  }
1305
- shouldUpdateField && shouldRender && _subjects.state.next(output);
1306
1322
  return shouldUpdateField ? output : {};
1307
1323
  };
1308
1324
  const shouldRenderByError = (name, isValid, error, fieldState) => {
1309
1325
  const previousFieldError = get(_formState.errors, name);
1310
- const shouldUpdateValid = _proxyFormState.isValid &&
1326
+ const shouldUpdateValid = (_proxyFormState.isValid || _proxySubscribeFormState.isValid) &&
1311
1327
  isBoolean(isValid) &&
1312
1328
  _formState.isValid !== isValid;
1313
- if (props.delayError && error) {
1329
+ if (_options.delayError && error) {
1314
1330
  delayErrorCallback = debounce(() => updateErrors(name, error));
1315
- delayErrorCallback(props.delayError);
1331
+ delayErrorCallback(_options.delayError);
1316
1332
  }
1317
1333
  else {
1318
1334
  clearTimeout(timer);
@@ -1337,14 +1353,14 @@ function createFormControl(props = {}) {
1337
1353
  _subjects.state.next(updatedFormState);
1338
1354
  }
1339
1355
  };
1340
- const _executeSchema = async (name) => {
1356
+ const _runSchema = async (name) => {
1341
1357
  _updateIsValidating(name, true);
1342
1358
  const result = await _options.resolver(_formValues, _options.context, getResolverOptions(name || _names.mount, _fields, _options.criteriaMode, _options.shouldUseNativeValidation));
1343
1359
  _updateIsValidating(name);
1344
1360
  return result;
1345
1361
  };
1346
1362
  const executeSchemaAndUpdateState = async (names) => {
1347
- const { errors } = await _executeSchema(names);
1363
+ const { errors } = await _runSchema(names);
1348
1364
  if (names) {
1349
1365
  for (const name of names) {
1350
1366
  const error = get(errors, name);
@@ -1367,9 +1383,14 @@ function createFormControl(props = {}) {
1367
1383
  const { _f, ...fieldValue } = field;
1368
1384
  if (_f) {
1369
1385
  const isFieldArrayRoot = _names.array.has(_f.name);
1370
- _updateIsValidating([name], true);
1371
- const fieldError = await validateField(field, _formValues, shouldDisplayAllAssociatedErrors, _options.shouldUseNativeValidation && !shouldOnlyCheckValid, isFieldArrayRoot);
1372
- _updateIsValidating([name]);
1386
+ const isPromiseFunction = field._f && hasPromiseValidation(field._f);
1387
+ if (isPromiseFunction && _proxyFormState.validatingFields) {
1388
+ _updateIsValidating([name], true);
1389
+ }
1390
+ const fieldError = await validateField(field, _names.disabled, _formValues, shouldDisplayAllAssociatedErrors, _options.shouldUseNativeValidation && !shouldOnlyCheckValid, isFieldArrayRoot);
1391
+ if (isPromiseFunction && _proxyFormState.validatingFields) {
1392
+ _updateIsValidating([name]);
1393
+ }
1373
1394
  if (fieldError[_f.name]) {
1374
1395
  context.valid = false;
1375
1396
  if (shouldOnlyCheckValid) {
@@ -1383,7 +1404,7 @@ function createFormControl(props = {}) {
1383
1404
  : set(_formState.errors, _f.name, fieldError[_f.name])
1384
1405
  : unset(_formState.errors, _f.name));
1385
1406
  }
1386
- fieldValue &&
1407
+ !isEmptyObject(fieldValue) &&
1387
1408
  (await executeBuiltInValidation(fieldValue, shouldOnlyCheckValid, context));
1388
1409
  }
1389
1410
  }
@@ -1400,8 +1421,9 @@ function createFormControl(props = {}) {
1400
1421
  }
1401
1422
  _names.unMount = new Set();
1402
1423
  };
1403
- const _getDirty = (name, data) => (name && data && set(_formValues, name, data),
1404
- !deepEqual(getValues(), _defaultValues));
1424
+ const _getDirty = (name, data) => !_options.disabled &&
1425
+ (name && data && set(_formValues, name, data),
1426
+ !deepEqual(getValues(), _defaultValues));
1405
1427
  const _getWatch = (names, defaultValue, isGlobal) => generateWatchOutput(names, _names, {
1406
1428
  ...(_state.mount
1407
1429
  ? _formValues
@@ -1411,7 +1433,7 @@ function createFormControl(props = {}) {
1411
1433
  ? { [names]: defaultValue }
1412
1434
  : defaultValue),
1413
1435
  }, isGlobal, defaultValue);
1414
- const _getFieldArray = (name) => compact(get(_state.mount ? _formValues : _defaultValues, name, props.shouldUnregister ? get(_defaultValues, name, []) : []));
1436
+ const _getFieldArray = (name) => compact(get(_state.mount ? _formValues : _defaultValues, name, _options.shouldUnregister ? get(_defaultValues, name, []) : []));
1415
1437
  const setFieldValue = (name, value, options = {}) => {
1416
1438
  const field = get(_fields, name);
1417
1439
  let fieldValue = value;
@@ -1447,9 +1469,9 @@ function createFormControl(props = {}) {
1447
1469
  else {
1448
1470
  fieldReference.ref.value = fieldValue;
1449
1471
  if (!fieldReference.ref.type) {
1450
- _subjects.values.next({
1472
+ _subjects.state.next({
1451
1473
  name,
1452
- values: { ..._formValues },
1474
+ values: cloneObject(_formValues),
1453
1475
  });
1454
1476
  }
1455
1477
  }
@@ -1465,7 +1487,7 @@ function createFormControl(props = {}) {
1465
1487
  const fieldName = `${name}.${fieldKey}`;
1466
1488
  const field = get(_fields, fieldName);
1467
1489
  (_names.array.has(name) ||
1468
- !isPrimitive(fieldValue) ||
1490
+ isObject$1(fieldValue) ||
1469
1491
  (field && !field._f)) &&
1470
1492
  !isDateObject(fieldValue)
1471
1493
  ? setValues(fieldName, fieldValue, options)
@@ -1480,9 +1502,12 @@ function createFormControl(props = {}) {
1480
1502
  if (isFieldArray) {
1481
1503
  _subjects.array.next({
1482
1504
  name,
1483
- values: { ..._formValues },
1505
+ values: cloneObject(_formValues),
1484
1506
  });
1485
- if ((_proxyFormState.isDirty || _proxyFormState.dirtyFields) &&
1507
+ if ((_proxyFormState.isDirty ||
1508
+ _proxyFormState.dirtyFields ||
1509
+ _proxySubscribeFormState.isDirty ||
1510
+ _proxySubscribeFormState.dirtyFields) &&
1486
1511
  options.shouldDirty) {
1487
1512
  _subjects.state.next({
1488
1513
  name,
@@ -1497,9 +1522,9 @@ function createFormControl(props = {}) {
1497
1522
  : setFieldValue(name, cloneValue, options);
1498
1523
  }
1499
1524
  isWatched(name, _names) && _subjects.state.next({ ..._formState });
1500
- _subjects.values.next({
1525
+ _subjects.state.next({
1501
1526
  name: _state.mount ? name : undefined,
1502
- values: { ..._formValues },
1527
+ values: cloneObject(_formValues),
1503
1528
  });
1504
1529
  };
1505
1530
  const onChange = async (event) => {
@@ -1508,16 +1533,18 @@ function createFormControl(props = {}) {
1508
1533
  let name = target.name;
1509
1534
  let isFieldValueUpdated = true;
1510
1535
  const field = get(_fields, name);
1511
- const getCurrentFieldValue = () => target.type ? getFieldValue(field._f) : getEventValue(event);
1512
1536
  const _updateIsFieldValueUpdated = (fieldValue) => {
1513
1537
  isFieldValueUpdated =
1514
1538
  Number.isNaN(fieldValue) ||
1515
- fieldValue === get(_formValues, name, fieldValue);
1539
+ (isDateObject(fieldValue) && isNaN(fieldValue.getTime())) ||
1540
+ deepEqual(fieldValue, get(_formValues, name, fieldValue));
1516
1541
  };
1517
1542
  if (field) {
1518
1543
  let error;
1519
1544
  let isValid;
1520
- const fieldValue = getCurrentFieldValue();
1545
+ const fieldValue = target.type
1546
+ ? getFieldValue(field._f)
1547
+ : getEventValue(event);
1521
1548
  const isBlurEvent = event.type === EVENTS.BLUR || event.type === EVENTS.FOCUS_OUT;
1522
1549
  const shouldSkipValidation = (!hasValidation(field._f) &&
1523
1550
  !_options.resolver &&
@@ -1533,22 +1560,31 @@ function createFormControl(props = {}) {
1533
1560
  else if (field._f.onChange) {
1534
1561
  field._f.onChange(event);
1535
1562
  }
1536
- const fieldState = updateTouchAndDirty(name, fieldValue, isBlurEvent, false);
1563
+ const fieldState = updateTouchAndDirty(name, fieldValue, isBlurEvent);
1537
1564
  const shouldRender = !isEmptyObject(fieldState) || watched;
1538
1565
  !isBlurEvent &&
1539
- _subjects.values.next({
1566
+ _subjects.state.next({
1540
1567
  name,
1541
1568
  type: event.type,
1542
- values: { ..._formValues },
1569
+ values: cloneObject(_formValues),
1543
1570
  });
1544
1571
  if (shouldSkipValidation) {
1545
- _proxyFormState.isValid && _updateValid();
1572
+ if (_proxyFormState.isValid || _proxySubscribeFormState.isValid) {
1573
+ if (_options.mode === 'onBlur') {
1574
+ if (isBlurEvent) {
1575
+ _setValid();
1576
+ }
1577
+ }
1578
+ else if (!isBlurEvent) {
1579
+ _setValid();
1580
+ }
1581
+ }
1546
1582
  return (shouldRender &&
1547
1583
  _subjects.state.next({ name, ...(watched ? {} : fieldState) }));
1548
1584
  }
1549
1585
  !isBlurEvent && watched && _subjects.state.next({ ..._formState });
1550
1586
  if (_options.resolver) {
1551
- const { errors } = await _executeSchema([name]);
1587
+ const { errors } = await _runSchema([name]);
1552
1588
  _updateIsFieldValueUpdated(fieldValue);
1553
1589
  if (isFieldValueUpdated) {
1554
1590
  const previousErrorLookupResult = schemaErrorLookup(_formState.errors, _fields, name);
@@ -1560,14 +1596,15 @@ function createFormControl(props = {}) {
1560
1596
  }
1561
1597
  else {
1562
1598
  _updateIsValidating([name], true);
1563
- error = (await validateField(field, _formValues, shouldDisplayAllAssociatedErrors, _options.shouldUseNativeValidation))[name];
1599
+ error = (await validateField(field, _names.disabled, _formValues, shouldDisplayAllAssociatedErrors, _options.shouldUseNativeValidation))[name];
1564
1600
  _updateIsValidating([name]);
1565
1601
  _updateIsFieldValueUpdated(fieldValue);
1566
1602
  if (isFieldValueUpdated) {
1567
1603
  if (error) {
1568
1604
  isValid = false;
1569
1605
  }
1570
- else if (_proxyFormState.isValid) {
1606
+ else if (_proxyFormState.isValid ||
1607
+ _proxySubscribeFormState.isValid) {
1571
1608
  isValid = await executeBuiltInValidation(_fields, true);
1572
1609
  }
1573
1610
  }
@@ -1602,14 +1639,15 @@ function createFormControl(props = {}) {
1602
1639
  const field = get(_fields, fieldName);
1603
1640
  return await executeBuiltInValidation(field && field._f ? { [fieldName]: field } : field);
1604
1641
  }))).every(Boolean);
1605
- !(!validationResult && !_formState.isValid) && _updateValid();
1642
+ !(!validationResult && !_formState.isValid) && _setValid();
1606
1643
  }
1607
1644
  else {
1608
1645
  validationResult = isValid = await executeBuiltInValidation(_fields);
1609
1646
  }
1610
1647
  _subjects.state.next({
1611
1648
  ...(!isString(name) ||
1612
- (_proxyFormState.isValid && isValid !== _formState.isValid)
1649
+ ((_proxyFormState.isValid || _proxySubscribeFormState.isValid) &&
1650
+ isValid !== _formState.isValid)
1613
1651
  ? {}
1614
1652
  : { name }),
1615
1653
  ...(_options.resolver || !name ? { isValid } : {}),
@@ -1633,9 +1671,9 @@ function createFormControl(props = {}) {
1633
1671
  const getFieldState = (name, formState) => ({
1634
1672
  invalid: !!get((formState || _formState).errors, name),
1635
1673
  isDirty: !!get((formState || _formState).dirtyFields, name),
1636
- isTouched: !!get((formState || _formState).touchedFields, name),
1637
- isValidating: !!get((formState || _formState).validatingFields, name),
1638
1674
  error: get((formState || _formState).errors, name),
1675
+ isValidating: !!get(_formState.validatingFields, name),
1676
+ isTouched: !!get((formState || _formState).touchedFields, name),
1639
1677
  });
1640
1678
  const clearErrors = (name) => {
1641
1679
  name &&
@@ -1662,10 +1700,33 @@ function createFormControl(props = {}) {
1662
1700
  options && options.shouldFocus && ref && ref.focus && ref.focus();
1663
1701
  };
1664
1702
  const watch = (name, defaultValue) => isFunction(name)
1665
- ? _subjects.values.subscribe({
1703
+ ? _subjects.state.subscribe({
1666
1704
  next: (payload) => name(_getWatch(undefined, defaultValue), payload),
1667
1705
  })
1668
1706
  : _getWatch(name, defaultValue, true);
1707
+ const _subscribe = (props) => _subjects.state.subscribe({
1708
+ next: (formState) => {
1709
+ if (shouldSubscribeByName(props.name, formState.name, props.exact) &&
1710
+ shouldRenderFormState(formState, props.formState || _proxyFormState, _setFormState, props.reRenderRoot)) {
1711
+ props.callback({
1712
+ values: { ..._formValues },
1713
+ ..._formState,
1714
+ ...formState,
1715
+ });
1716
+ }
1717
+ },
1718
+ }).unsubscribe;
1719
+ const subscribe = (props) => {
1720
+ _state.mount = true;
1721
+ _proxySubscribeFormState = {
1722
+ ..._proxySubscribeFormState,
1723
+ ...props.formState,
1724
+ };
1725
+ return _subscribe({
1726
+ ...props,
1727
+ formState: _proxySubscribeFormState,
1728
+ });
1729
+ };
1669
1730
  const unregister = (name, options = {}) => {
1670
1731
  for (const fieldName of name ? convertToArrayPayload(name) : _names.mount) {
1671
1732
  _names.mount.delete(fieldName);
@@ -1683,29 +1744,25 @@ function createFormControl(props = {}) {
1683
1744
  !options.keepDefaultValue &&
1684
1745
  unset(_defaultValues, fieldName);
1685
1746
  }
1686
- _subjects.values.next({
1687
- values: { ..._formValues },
1747
+ _subjects.state.next({
1748
+ values: cloneObject(_formValues),
1688
1749
  });
1689
1750
  _subjects.state.next({
1690
1751
  ..._formState,
1691
1752
  ...(!options.keepDirty ? {} : { isDirty: _getDirty() }),
1692
1753
  });
1693
- !options.keepIsValid && _updateValid();
1694
- };
1695
- const _updateDisabledField = ({ disabled, name, field, fields, value, }) => {
1696
- if ((isBoolean(disabled) && _state.mount) || !!disabled) {
1697
- const inputValue = disabled
1698
- ? undefined
1699
- : isUndefined(value)
1700
- ? getFieldValue(field ? field._f : get(fields, name)._f)
1701
- : value;
1702
- set(_formValues, name, inputValue);
1703
- updateTouchAndDirty(name, inputValue, false, false, true);
1754
+ !options.keepIsValid && _setValid();
1755
+ };
1756
+ const _setDisabledField = ({ disabled, name, }) => {
1757
+ if ((isBoolean(disabled) && _state.mount) ||
1758
+ !!disabled ||
1759
+ _names.disabled.has(name)) {
1760
+ disabled ? _names.disabled.add(name) : _names.disabled.delete(name);
1704
1761
  }
1705
1762
  };
1706
1763
  const register = (name, options = {}) => {
1707
1764
  let field = get(_fields, name);
1708
- const disabledIsDefined = isBoolean(options.disabled);
1765
+ const disabledIsDefined = isBoolean(options.disabled) || isBoolean(_options.disabled);
1709
1766
  set(_fields, name, {
1710
1767
  ...(field || {}),
1711
1768
  _f: {
@@ -1717,18 +1774,20 @@ function createFormControl(props = {}) {
1717
1774
  });
1718
1775
  _names.mount.add(name);
1719
1776
  if (field) {
1720
- _updateDisabledField({
1721
- field,
1722
- disabled: options.disabled,
1777
+ _setDisabledField({
1778
+ disabled: isBoolean(options.disabled)
1779
+ ? options.disabled
1780
+ : _options.disabled,
1723
1781
  name,
1724
- value: options.value,
1725
1782
  });
1726
1783
  }
1727
1784
  else {
1728
1785
  updateValidAndValue(name, true, options.value);
1729
1786
  }
1730
1787
  return {
1731
- ...(disabledIsDefined ? { disabled: options.disabled } : {}),
1788
+ ...(disabledIsDefined
1789
+ ? { disabled: options.disabled || _options.disabled }
1790
+ : {}),
1732
1791
  ...(_options.progressive
1733
1792
  ? {
1734
1793
  required: !!options.required,
@@ -1809,20 +1868,26 @@ function createFormControl(props = {}) {
1809
1868
  let onValidError = undefined;
1810
1869
  if (e) {
1811
1870
  e.preventDefault && e.preventDefault();
1812
- e.persist && e.persist();
1871
+ e.persist &&
1872
+ e.persist();
1813
1873
  }
1814
1874
  let fieldValues = cloneObject(_formValues);
1815
1875
  _subjects.state.next({
1816
1876
  isSubmitting: true,
1817
1877
  });
1818
1878
  if (_options.resolver) {
1819
- const { errors, values } = await _executeSchema();
1879
+ const { errors, values } = await _runSchema();
1820
1880
  _formState.errors = errors;
1821
1881
  fieldValues = values;
1822
1882
  }
1823
1883
  else {
1824
1884
  await executeBuiltInValidation(_fields);
1825
1885
  }
1886
+ if (_names.disabled.size) {
1887
+ for (const name of _names.disabled) {
1888
+ set(fieldValues, name, undefined);
1889
+ }
1890
+ }
1826
1891
  unset(_formState.errors, 'root');
1827
1892
  if (isEmptyObject(_formState.errors)) {
1828
1893
  _subjects.state.next({
@@ -1873,7 +1938,7 @@ function createFormControl(props = {}) {
1873
1938
  }
1874
1939
  if (!options.keepError) {
1875
1940
  unset(_formState.errors, name);
1876
- _proxyFormState.isValid && _updateValid();
1941
+ _proxyFormState.isValid && _setValid();
1877
1942
  }
1878
1943
  _subjects.state.next({ ..._formState });
1879
1944
  }
@@ -1888,7 +1953,11 @@ function createFormControl(props = {}) {
1888
1953
  }
1889
1954
  if (!keepStateOptions.keepValues) {
1890
1955
  if (keepStateOptions.keepDirtyValues) {
1891
- for (const fieldName of _names.mount) {
1956
+ const fieldsToCheck = new Set([
1957
+ ..._names.mount,
1958
+ ...Object.keys(getDirtyFields(_defaultValues, _formValues)),
1959
+ ]);
1960
+ for (const fieldName of Array.from(fieldsToCheck)) {
1892
1961
  get(_formState.dirtyFields, fieldName)
1893
1962
  ? set(values, fieldName, get(_formValues, fieldName))
1894
1963
  : setValue(fieldName, get(values, fieldName));
@@ -1912,17 +1981,15 @@ function createFormControl(props = {}) {
1912
1981
  }
1913
1982
  }
1914
1983
  }
1915
- _fields = {};
1984
+ for (const fieldName of _names.mount) {
1985
+ setValue(fieldName, get(values, fieldName));
1986
+ }
1916
1987
  }
1917
- _formValues = props.shouldUnregister
1918
- ? keepStateOptions.keepDefaultValues
1919
- ? cloneObject(_defaultValues)
1920
- : {}
1921
- : cloneObject(values);
1988
+ _formValues = cloneObject(values);
1922
1989
  _subjects.array.next({
1923
1990
  values: { ...values },
1924
1991
  });
1925
- _subjects.values.next({
1992
+ _subjects.state.next({
1926
1993
  values: { ...values },
1927
1994
  });
1928
1995
  }
@@ -1930,6 +1997,7 @@ function createFormControl(props = {}) {
1930
1997
  mount: keepStateOptions.keepDirtyValues ? _names.mount : new Set(),
1931
1998
  unMount: new Set(),
1932
1999
  array: new Set(),
2000
+ disabled: new Set(),
1933
2001
  watch: new Set(),
1934
2002
  watchAll: false,
1935
2003
  focus: '',
@@ -1938,7 +2006,7 @@ function createFormControl(props = {}) {
1938
2006
  !_proxyFormState.isValid ||
1939
2007
  !!keepStateOptions.keepIsValid ||
1940
2008
  !!keepStateOptions.keepDirtyValues;
1941
- _state.watch = !!props.shouldUnregister;
2009
+ _state.watch = !!_options.shouldUnregister;
1942
2010
  _subjects.state.next({
1943
2011
  submitCount: keepStateOptions.keepSubmitCount
1944
2012
  ? _formState.submitCount
@@ -1953,14 +2021,16 @@ function createFormControl(props = {}) {
1953
2021
  ? _formState.isSubmitted
1954
2022
  : false,
1955
2023
  dirtyFields: isEmptyResetValues
1956
- ? []
2024
+ ? {}
1957
2025
  : keepStateOptions.keepDirtyValues
1958
2026
  ? keepStateOptions.keepDefaultValues && _formValues
1959
2027
  ? getDirtyFields(_defaultValues, _formValues)
1960
2028
  : _formState.dirtyFields
1961
2029
  : keepStateOptions.keepDefaultValues && formValues
1962
2030
  ? getDirtyFields(_defaultValues, formValues)
1963
- : {},
2031
+ : keepStateOptions.keepDirty
2032
+ ? _formState.dirtyFields
2033
+ : {},
1964
2034
  touchedFields: keepStateOptions.keepTouched
1965
2035
  ? _formState.touchedFields
1966
2036
  : {},
@@ -1983,11 +2053,13 @@ function createFormControl(props = {}) {
1983
2053
  : fieldReference.ref;
1984
2054
  if (fieldRef.focus) {
1985
2055
  fieldRef.focus();
1986
- options.shouldSelect && fieldRef.select();
2056
+ options.shouldSelect &&
2057
+ isFunction(fieldRef.select) &&
2058
+ fieldRef.select();
1987
2059
  }
1988
2060
  }
1989
2061
  };
1990
- const _updateFormState = (updatedFormState) => {
2062
+ const _setFormState = (updatedFormState) => {
1991
2063
  _formState = {
1992
2064
  ..._formState,
1993
2065
  ...updatedFormState,
@@ -2000,28 +2072,28 @@ function createFormControl(props = {}) {
2000
2072
  isLoading: false,
2001
2073
  });
2002
2074
  });
2003
- return {
2075
+ const methods = {
2004
2076
  control: {
2005
2077
  register,
2006
2078
  unregister,
2007
2079
  getFieldState,
2008
2080
  handleSubmit,
2009
2081
  setError,
2010
- _executeSchema,
2082
+ _subscribe,
2083
+ _runSchema,
2011
2084
  _getWatch,
2012
2085
  _getDirty,
2013
- _updateValid,
2014
- _removeUnmounted,
2015
- _updateFieldArray,
2016
- _updateDisabledField,
2086
+ _setValid,
2087
+ _setFieldArray,
2088
+ _setDisabledField,
2089
+ _setErrors,
2017
2090
  _getFieldArray,
2018
2091
  _reset,
2019
2092
  _resetDefaultValues,
2020
- _updateFormState,
2093
+ _removeUnmounted,
2021
2094
  _disableForm,
2022
2095
  _subjects,
2023
2096
  _proxyFormState,
2024
- _setErrors,
2025
2097
  get _fields() {
2026
2098
  return _fields;
2027
2099
  },
@@ -2046,9 +2118,6 @@ function createFormControl(props = {}) {
2046
2118
  get _formState() {
2047
2119
  return _formState;
2048
2120
  },
2049
- set _formState(value) {
2050
- _formState = value;
2051
- },
2052
2121
  get _options() {
2053
2122
  return _options;
2054
2123
  },
@@ -2059,6 +2128,7 @@ function createFormControl(props = {}) {
2059
2128
  };
2060
2129
  },
2061
2130
  },
2131
+ subscribe,
2062
2132
  trigger,
2063
2133
  register,
2064
2134
  handleSubmit,
@@ -2073,6 +2143,10 @@ function createFormControl(props = {}) {
2073
2143
  setFocus,
2074
2144
  getFieldState,
2075
2145
  };
2146
+ return {
2147
+ ...methods,
2148
+ formControl: methods,
2149
+ };
2076
2150
  }
2077
2151
 
2078
2152
  /**
@@ -2105,8 +2179,8 @@ function createFormControl(props = {}) {
2105
2179
  * ```
2106
2180
  */
2107
2181
  function useForm(props = {}) {
2108
- const _formControl = React$1.useRef();
2109
- const _values = React$1.useRef();
2182
+ const _formControl = React$1.useRef(undefined);
2183
+ const _values = React$1.useRef(undefined);
2110
2184
  const [formState, updateFormState] = React$1.useState({
2111
2185
  isDirty: false,
2112
2186
  isValidating: false,
@@ -2127,20 +2201,22 @@ function useForm(props = {}) {
2127
2201
  });
2128
2202
  if (!_formControl.current) {
2129
2203
  _formControl.current = {
2130
- ...createFormControl(props),
2204
+ ...(props.formControl ? props.formControl : createFormControl(props)),
2131
2205
  formState,
2132
2206
  };
2207
+ if (props.formControl &&
2208
+ props.defaultValues &&
2209
+ !isFunction(props.defaultValues)) {
2210
+ props.formControl.reset(props.defaultValues, props.resetOptions);
2211
+ }
2133
2212
  }
2134
2213
  const control = _formControl.current.control;
2135
2214
  control._options = props;
2136
- useSubscribe({
2137
- subject: control._subjects.state,
2138
- next: (value) => {
2139
- if (shouldRenderFormState(value, control._proxyFormState, control._updateFormState, true)) {
2140
- updateFormState({ ...control._formState });
2141
- }
2142
- },
2143
- });
2215
+ React$1.useLayoutEffect(() => control._subscribe({
2216
+ formState: control._proxyFormState,
2217
+ callback: () => updateFormState({ ...control._formState }),
2218
+ reRenderRoot: true,
2219
+ }), [control]);
2144
2220
  React$1.useEffect(() => control._disableForm(props.disabled), [control, props.disabled]);
2145
2221
  React$1.useEffect(() => {
2146
2222
  if (control._proxyFormState.isDirty) {
@@ -2163,13 +2239,13 @@ function useForm(props = {}) {
2163
2239
  }
2164
2240
  }, [props.values, control]);
2165
2241
  React$1.useEffect(() => {
2166
- if (props.errors) {
2242
+ if (props.errors && !isEmptyObject(props.errors)) {
2167
2243
  control._setErrors(props.errors);
2168
2244
  }
2169
2245
  }, [props.errors, control]);
2170
2246
  React$1.useEffect(() => {
2171
2247
  if (!control._state.mount) {
2172
- control._updateValid();
2248
+ control._setValid();
2173
2249
  control._state.mount = true;
2174
2250
  }
2175
2251
  if (control._state.watch) {
@@ -2180,7 +2256,7 @@ function useForm(props = {}) {
2180
2256
  });
2181
2257
  React$1.useEffect(() => {
2182
2258
  props.shouldUnregister &&
2183
- control._subjects.values.next({
2259
+ control._subjects.state.next({
2184
2260
  values: control._getWatch(),
2185
2261
  });
2186
2262
  }, [props.shouldUnregister, control]);
@@ -2188,6 +2264,10 @@ function useForm(props = {}) {
2188
2264
  return _formControl.current;
2189
2265
  }
2190
2266
 
2267
+ var t=function(t,n,e){if(t&&"reportValidity"in t){var i=get(e,n);t.setCustomValidity(i&&i.message||""),t.reportValidity();}},n=function(r,n){var e=function(e){var i=n.fields[e];i&&i.ref&&"reportValidity"in i.ref?t(i.ref,e,r):i.refs&&i.refs.forEach(function(n){return t(n,e,r)});};for(var i in n.fields)e(i);},e=function(r){return r instanceof Date},i=function(r){return null==r},a=function(r){return "object"==typeof r},o$1=function(r){return !i(r)&&!Array.isArray(r)&&a(r)&&!e(r)},f=function(r){return /^\w*$/.test(r)},s$1=function(r,t,n){for(var e=-1,i=f(t)?[t]:function(r){return t=r.replace(/["|']|\]/g,"").split(/\.|\[/),Array.isArray(t)?t.filter(Boolean):[];var t;}(t),a=i.length,s=a-1;++e<a;){var u=i[e],c=n;if(e!==s){var l=r[u];c=o$1(l)||Array.isArray(l)?l:isNaN(+i[e+1])?{}:[];}r[u]=c,r=r[u];}return r},u=function(t,e){e.shouldUseNativeValidation&&n(t,e);var i={};for(var a in t){var o=get(e.fields,a),f=Object.assign(t[a]||{},{ref:o&&o.ref});if(c(e.names||Object.keys(t),a)){var u=Object.assign({},get(i,a));s$1(u,"root",f),s$1(i,a,u);}else s$1(i,a,f);}return i},c=function(r,t){return r.some(function(r){return r.startsWith(t+".")})};
2268
+
2269
+ function o(o,n$1,a){return void 0===n$1&&(n$1={}),void 0===a&&(a={}),function(s,i,c){try{return Promise.resolve(function(t,r){try{var u=(n$1.context&&"development"===process.env.NODE_ENV&&console.warn("You should not used the yup options context. Please, use the 'useForm' context object instead"),Promise.resolve(o["sync"===a.mode?"validateSync":"validate"](s,Object.assign({abortEarly:!1},n$1,{context:i}))).then(function(t){return c.shouldUseNativeValidation&&n({},c),{values:a.raw?s:t,errors:{}}}));}catch(e){return r(e)}return u&&u.then?u.then(void 0,r):u}(0,function(e){if(!e.inner)throw e;return {values:{},errors:u((o=e,n=!c.shouldUseNativeValidation&&"all"===c.criteriaMode,(o.inner||[]).reduce(function(e,t){if(e[t.path]||(e[t.path]={message:t.message,type:t.type}),n){var o=e[t.path].types,a=o&&o[t.type];e[t.path]=appendErrors(t.path,n,e,t.type,a?[].concat(a,t.message):t.message);}return e},{})),c)};var o,n;}))}catch(e){return Promise.reject(e)}}}
2270
+
2191
2271
  var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
2192
2272
 
2193
2273
  function getDefaultExportFromCjs (x) {
@@ -8357,7 +8437,7 @@ var getDisplayName = /*#__PURE__*/Object.freeze({
8357
8437
 
8358
8438
  var require$$6 = /*@__PURE__*/getAugmentedNamespace(getDisplayName);
8359
8439
 
8360
- const _excluded$1G = ["values", "unit", "step"];
8440
+ const _excluded$1I = ["values", "unit", "step"];
8361
8441
  const sortBreakpointsValues = values => {
8362
8442
  const breakpointsAsArray = Object.keys(values).map(key => ({
8363
8443
  key,
@@ -8391,7 +8471,7 @@ function createBreakpoints(breakpoints) {
8391
8471
  unit = 'px',
8392
8472
  step = 5
8393
8473
  } = breakpoints,
8394
- other = _objectWithoutPropertiesLoose(breakpoints, _excluded$1G);
8474
+ other = _objectWithoutPropertiesLoose(breakpoints, _excluded$1I);
8395
8475
  const sortedValues = sortBreakpointsValues(values);
8396
8476
  const keys = Object.keys(sortedValues);
8397
8477
  function up(key) {
@@ -9535,7 +9615,7 @@ function applyStyles$2(key, styles) {
9535
9615
  return {};
9536
9616
  }
9537
9617
 
9538
- const _excluded$1F = ["breakpoints", "palette", "spacing", "shape"];
9618
+ const _excluded$1H = ["breakpoints", "palette", "spacing", "shape"];
9539
9619
  function createTheme$2(options = {}, ...args) {
9540
9620
  const {
9541
9621
  breakpoints: breakpointsInput = {},
@@ -9543,7 +9623,7 @@ function createTheme$2(options = {}, ...args) {
9543
9623
  spacing: spacingInput,
9544
9624
  shape: shapeInput = {}
9545
9625
  } = options,
9546
- other = _objectWithoutPropertiesLoose(options, _excluded$1F);
9626
+ other = _objectWithoutPropertiesLoose(options, _excluded$1H);
9547
9627
  const breakpoints = createBreakpoints(breakpointsInput);
9548
9628
  const spacing = createSpacing(spacingInput);
9549
9629
  let muiTheme = deepmerge$1({
@@ -9578,7 +9658,7 @@ var createTheme$1 = /*#__PURE__*/Object.freeze({
9578
9658
 
9579
9659
  var require$$7 = /*@__PURE__*/getAugmentedNamespace(createTheme$1);
9580
9660
 
9581
- const _excluded$1E = ["sx"];
9661
+ const _excluded$1G = ["sx"];
9582
9662
  const splitProps = props => {
9583
9663
  var _props$theme$unstable, _props$theme;
9584
9664
  const result = {
@@ -9599,7 +9679,7 @@ function extendSxProp(props) {
9599
9679
  const {
9600
9680
  sx: inSx
9601
9681
  } = props,
9602
- other = _objectWithoutPropertiesLoose(props, _excluded$1E);
9682
+ other = _objectWithoutPropertiesLoose(props, _excluded$1G);
9603
9683
  const {
9604
9684
  systemProps,
9605
9685
  otherProps
@@ -9648,7 +9728,7 @@ var _capitalize = _interopRequireDefault$6(require$$5);
9648
9728
  var _getDisplayName = _interopRequireDefault$6(require$$6);
9649
9729
  var _createTheme = _interopRequireDefault$6(require$$7);
9650
9730
  var _styleFunctionSx = _interopRequireDefault$6(require$$8);
9651
- const _excluded$1D = ["ownerState"],
9731
+ const _excluded$1F = ["ownerState"],
9652
9732
  _excluded2$g = ["variants"],
9653
9733
  _excluded3$7 = ["name", "slot", "skipVariantsResolver", "skipSx", "overridesResolver"];
9654
9734
  /* eslint-disable no-underscore-dangle */
@@ -9695,7 +9775,7 @@ function processStyleArg$1(callableStyle, _ref) {
9695
9775
  let {
9696
9776
  ownerState
9697
9777
  } = _ref,
9698
- props = (0, _objectWithoutPropertiesLoose2.default)(_ref, _excluded$1D);
9778
+ props = (0, _objectWithoutPropertiesLoose2.default)(_ref, _excluded$1F);
9699
9779
  const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle((0, _extends2.default)({
9700
9780
  ownerState
9701
9781
  }, props)) : callableStyle;
@@ -10445,7 +10525,7 @@ const green = {
10445
10525
  A700: '#00c853'
10446
10526
  };
10447
10527
 
10448
- const _excluded$1C = ["mode", "contrastThreshold", "tonalOffset"];
10528
+ const _excluded$1E = ["mode", "contrastThreshold", "tonalOffset"];
10449
10529
  const light = {
10450
10530
  // The colors used to style the text.
10451
10531
  text: {
@@ -10614,7 +10694,7 @@ function createPalette(palette) {
10614
10694
  contrastThreshold = 3,
10615
10695
  tonalOffset = 0.2
10616
10696
  } = palette,
10617
- other = _objectWithoutPropertiesLoose(palette, _excluded$1C);
10697
+ other = _objectWithoutPropertiesLoose(palette, _excluded$1E);
10618
10698
  const primary = palette.primary || getDefaultPrimary(mode);
10619
10699
  const secondary = palette.secondary || getDefaultSecondary(mode);
10620
10700
  const error = palette.error || getDefaultError(mode);
@@ -10738,7 +10818,7 @@ const theme2 = createTheme({ palette: {
10738
10818
  return paletteOutput;
10739
10819
  }
10740
10820
 
10741
- const _excluded$1B = ["fontFamily", "fontSize", "fontWeightLight", "fontWeightRegular", "fontWeightMedium", "fontWeightBold", "htmlFontSize", "allVariants", "pxToRem"];
10821
+ const _excluded$1D = ["fontFamily", "fontSize", "fontWeightLight", "fontWeightRegular", "fontWeightMedium", "fontWeightBold", "htmlFontSize", "allVariants", "pxToRem"];
10742
10822
  function round$2(value) {
10743
10823
  return Math.round(value * 1e5) / 1e5;
10744
10824
  }
@@ -10769,7 +10849,7 @@ function createTypography(palette, typography) {
10769
10849
  allVariants,
10770
10850
  pxToRem: pxToRem2
10771
10851
  } = _ref,
10772
- other = _objectWithoutPropertiesLoose(_ref, _excluded$1B);
10852
+ other = _objectWithoutPropertiesLoose(_ref, _excluded$1D);
10773
10853
  if (process.env.NODE_ENV !== 'production') {
10774
10854
  if (typeof fontSize !== 'number') {
10775
10855
  console.error('MUI: `fontSize` is required to be a number.');
@@ -10836,7 +10916,7 @@ function createShadow(...px) {
10836
10916
  // Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss
10837
10917
  const shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];
10838
10918
 
10839
- const _excluded$1A = ["duration", "easing", "delay"];
10919
+ const _excluded$1C = ["duration", "easing", "delay"];
10840
10920
  // Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves
10841
10921
  // to learn the context in which each easing should be used.
10842
10922
  const easing = {
@@ -10887,7 +10967,7 @@ function createTransitions(inputTransitions) {
10887
10967
  easing: easingOption = mergedEasing.easeInOut,
10888
10968
  delay = 0
10889
10969
  } = options,
10890
- other = _objectWithoutPropertiesLoose(options, _excluded$1A);
10970
+ other = _objectWithoutPropertiesLoose(options, _excluded$1C);
10891
10971
  if (process.env.NODE_ENV !== 'production') {
10892
10972
  const isString = value => typeof value === 'string';
10893
10973
  // IE11 support, replace with Number.isNaN
@@ -10936,7 +11016,7 @@ const zIndex = {
10936
11016
  tooltip: 1500
10937
11017
  };
10938
11018
 
10939
- const _excluded$1z = ["breakpoints", "mixins", "spacing", "palette", "transitions", "typography", "shape"];
11019
+ const _excluded$1B = ["breakpoints", "mixins", "spacing", "palette", "transitions", "typography", "shape"];
10940
11020
  function createTheme(options = {}, ...args) {
10941
11021
  const {
10942
11022
  mixins: mixinsInput = {},
@@ -10944,7 +11024,7 @@ function createTheme(options = {}, ...args) {
10944
11024
  transitions: transitionsInput = {},
10945
11025
  typography: typographyInput = {}
10946
11026
  } = options,
10947
- other = _objectWithoutPropertiesLoose(options, _excluded$1z);
11027
+ other = _objectWithoutPropertiesLoose(options, _excluded$1B);
10948
11028
  if (options.vars) {
10949
11029
  throw new Error(process.env.NODE_ENV !== "production" ? `MUI: \`vars\` is a private field used for CSS variables support.
10950
11030
  Please use another name.` : formatMuiErrorMessage$1(18));
@@ -11900,7 +11980,7 @@ function mergeSlotProps(parameters) {
11900
11980
  };
11901
11981
  }
11902
11982
 
11903
- const _excluded$1y = ["elementType", "externalSlotProps", "ownerState", "skipResolvingSlotProps"];
11983
+ const _excluded$1A = ["elementType", "externalSlotProps", "ownerState", "skipResolvingSlotProps"];
11904
11984
  /**
11905
11985
  * @ignore - do not document.
11906
11986
  * Builds the props to be passed into the slot of an unstyled component.
@@ -11917,7 +11997,7 @@ function useSlotProps(parameters) {
11917
11997
  ownerState,
11918
11998
  skipResolvingSlotProps = false
11919
11999
  } = parameters,
11920
- rest = _objectWithoutPropertiesLoose(parameters, _excluded$1y);
12000
+ rest = _objectWithoutPropertiesLoose(parameters, _excluded$1A);
11921
12001
  const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);
11922
12002
  const {
11923
12003
  props: mergedProps,
@@ -14736,7 +14816,7 @@ function getPopperUtilityClass(slot) {
14736
14816
  }
14737
14817
  generateUtilityClasses(COMPONENT_NAME, ['root']);
14738
14818
 
14739
- const _excluded$1x = ["anchorEl", "children", "direction", "disablePortal", "modifiers", "open", "placement", "popperOptions", "popperRef", "slotProps", "slots", "TransitionProps", "ownerState"],
14819
+ const _excluded$1z = ["anchorEl", "children", "direction", "disablePortal", "modifiers", "open", "placement", "popperOptions", "popperRef", "slotProps", "slots", "TransitionProps", "ownerState"],
14740
14820
  _excluded2$f = ["anchorEl", "children", "container", "direction", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "style", "transition", "slotProps", "slots"];
14741
14821
  function flipPlacement(placement, direction) {
14742
14822
  if (direction === 'ltr') {
@@ -14764,7 +14844,7 @@ function isHTMLElement(element) {
14764
14844
  function isVirtualElement(element) {
14765
14845
  return !isHTMLElement(element);
14766
14846
  }
14767
- const useUtilityClasses$15 = () => {
14847
+ const useUtilityClasses$17 = () => {
14768
14848
  const slots = {
14769
14849
  root: ['root']
14770
14850
  };
@@ -14789,7 +14869,7 @@ const PopperTooltip = /*#__PURE__*/React__namespace.forwardRef(function PopperTo
14789
14869
  // @ts-ignore internal logic
14790
14870
  // prevent from spreading to DOM, it can come from the parent component e.g. Select.
14791
14871
  } = props,
14792
- other = _objectWithoutPropertiesLoose(props, _excluded$1x);
14872
+ other = _objectWithoutPropertiesLoose(props, _excluded$1z);
14793
14873
  const tooltipRef = React__namespace.useRef(null);
14794
14874
  const ownRef = useForkRef(tooltipRef, forwardedRef);
14795
14875
  const popperRef = React__namespace.useRef(null);
@@ -14874,7 +14954,7 @@ const PopperTooltip = /*#__PURE__*/React__namespace.forwardRef(function PopperTo
14874
14954
  if (TransitionProps !== null) {
14875
14955
  childProps.TransitionProps = TransitionProps;
14876
14956
  }
14877
- const classes = useUtilityClasses$15();
14957
+ const classes = useUtilityClasses$17();
14878
14958
  const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';
14879
14959
  const rootProps = useSlotProps({
14880
14960
  elementType: Root,
@@ -15100,7 +15180,7 @@ process.env.NODE_ENV !== "production" ? Popper$1.propTypes /* remove-proptypes *
15100
15180
  transition: PropTypes.bool
15101
15181
  } : void 0;
15102
15182
 
15103
- const _excluded$1w = ["onChange", "maxRows", "minRows", "style", "value"];
15183
+ const _excluded$1y = ["onChange", "maxRows", "minRows", "style", "value"];
15104
15184
  function getStyleValue(value) {
15105
15185
  return parseInt(value, 10) || 0;
15106
15186
  }
@@ -15142,7 +15222,7 @@ const TextareaAutosize = /*#__PURE__*/React__namespace.forwardRef(function Texta
15142
15222
  style,
15143
15223
  value
15144
15224
  } = props,
15145
- other = _objectWithoutPropertiesLoose(props, _excluded$1w);
15225
+ other = _objectWithoutPropertiesLoose(props, _excluded$1y);
15146
15226
  const {
15147
15227
  current: isControlled
15148
15228
  } = React__namespace.useRef(value != null);
@@ -16356,7 +16436,7 @@ process.env.NODE_ENV !== "production" ? GlobalStyles$1.propTypes /* remove-propt
16356
16436
  themeId: PropTypes.string
16357
16437
  } : void 0;
16358
16438
 
16359
- const _excluded$1v = ["className", "component"];
16439
+ const _excluded$1x = ["className", "component"];
16360
16440
  function createBox(options = {}) {
16361
16441
  const {
16362
16442
  themeId,
@@ -16374,7 +16454,7 @@ function createBox(options = {}) {
16374
16454
  className,
16375
16455
  component = 'div'
16376
16456
  } = _extendSxProp,
16377
- other = _objectWithoutPropertiesLoose(_extendSxProp, _excluded$1v);
16457
+ other = _objectWithoutPropertiesLoose(_extendSxProp, _excluded$1x);
16378
16458
  return /*#__PURE__*/jsxRuntimeExports.jsx(BoxRoot, _extends$1({
16379
16459
  as: component,
16380
16460
  ref: ref,
@@ -16385,7 +16465,7 @@ function createBox(options = {}) {
16385
16465
  return Box;
16386
16466
  }
16387
16467
 
16388
- const _excluded$1u = ["ownerState"],
16468
+ const _excluded$1w = ["ownerState"],
16389
16469
  _excluded2$e = ["variants"],
16390
16470
  _excluded3$6 = ["name", "slot", "skipVariantsResolver", "skipSx", "overridesResolver"];
16391
16471
  function isEmpty$2(obj) {
@@ -16429,7 +16509,7 @@ function processStyleArg(callableStyle, _ref) {
16429
16509
  let {
16430
16510
  ownerState
16431
16511
  } = _ref,
16432
- props = _objectWithoutPropertiesLoose(_ref, _excluded$1u);
16512
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$1w);
16433
16513
  const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends$1({
16434
16514
  ownerState
16435
16515
  }, props)) : callableStyle;
@@ -17074,13 +17154,13 @@ if (process.env.NODE_ENV !== 'production') {
17074
17154
  process.env.NODE_ENV !== "production" ? ThemeProvider$2.propTypes = exactProp(ThemeProvider$2.propTypes) : void 0;
17075
17155
  }
17076
17156
 
17077
- const _excluded$1t = ["value"];
17157
+ const _excluded$1v = ["value"];
17078
17158
  const RtlContext = /*#__PURE__*/React__namespace.createContext();
17079
17159
  function RtlProvider(_ref) {
17080
17160
  let {
17081
17161
  value
17082
17162
  } = _ref,
17083
- props = _objectWithoutPropertiesLoose(_ref, _excluded$1t);
17163
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$1v);
17084
17164
  return /*#__PURE__*/jsxRuntimeExports.jsx(RtlContext.Provider, _extends$1({
17085
17165
  value: value != null ? value : true
17086
17166
  }, props));
@@ -17441,7 +17521,7 @@ function useCurrentColorScheme(options) {
17441
17521
  });
17442
17522
  }
17443
17523
 
17444
- const _excluded$1s = ["colorSchemes", "components", "generateCssVars", "cssVarPrefix"];
17524
+ const _excluded$1u = ["colorSchemes", "components", "generateCssVars", "cssVarPrefix"];
17445
17525
  const DISABLE_CSS_TRANSITION = '*{-webkit-transition:none!important;-moz-transition:none!important;-o-transition:none!important;-ms-transition:none!important;transition:none!important}';
17446
17526
  function createCssVarsProvider(options) {
17447
17527
  const {
@@ -17508,7 +17588,7 @@ function createCssVarsProvider(options) {
17508
17588
  }),
17509
17589
  cssVarPrefix
17510
17590
  } = _ref,
17511
- restThemeProp = _objectWithoutPropertiesLoose(_ref, _excluded$1s);
17591
+ restThemeProp = _objectWithoutPropertiesLoose(_ref, _excluded$1u);
17512
17592
  const allColorSchemes = Object.keys(colorSchemes);
17513
17593
  const defaultLightColorScheme = typeof defaultColorScheme === 'string' ? defaultColorScheme : defaultColorScheme.light;
17514
17594
  const defaultDarkColorScheme = typeof defaultColorScheme === 'string' ? defaultColorScheme : defaultColorScheme.dark;
@@ -17953,14 +18033,14 @@ function toPropertyKey(t) {
17953
18033
  return "symbol" == _typeof$1(i) ? i : i + "";
17954
18034
  }
17955
18035
 
17956
- const _excluded$1r = ["colorSchemes", "components", "defaultColorScheme"];
18036
+ const _excluded$1t = ["colorSchemes", "components", "defaultColorScheme"];
17957
18037
  function prepareCssVars(theme, parserConfig) {
17958
18038
  // @ts-ignore - ignore components do not exist
17959
18039
  const {
17960
18040
  colorSchemes = {},
17961
18041
  defaultColorScheme = 'light'
17962
18042
  } = theme,
17963
- otherTheme = _objectWithoutPropertiesLoose(theme, _excluded$1r);
18043
+ otherTheme = _objectWithoutPropertiesLoose(theme, _excluded$1t);
17964
18044
  const {
17965
18045
  vars: rootVars,
17966
18046
  css: rootCss,
@@ -18021,7 +18101,7 @@ function prepareCssVars(theme, parserConfig) {
18021
18101
  };
18022
18102
  }
18023
18103
 
18024
- const _excluded$1q = ["className", "component", "disableGutters", "fixed", "maxWidth", "classes"];
18104
+ const _excluded$1s = ["className", "component", "disableGutters", "fixed", "maxWidth", "classes"];
18025
18105
  const defaultTheme$3 = createTheme$2();
18026
18106
  const defaultCreateStyledComponent$1 = styled('div', {
18027
18107
  name: 'MuiContainer',
@@ -18038,7 +18118,7 @@ const useThemePropsDefault$1 = inProps => useThemeProps$2({
18038
18118
  name: 'MuiContainer',
18039
18119
  defaultTheme: defaultTheme$3
18040
18120
  });
18041
- const useUtilityClasses$14 = (ownerState, componentName) => {
18121
+ const useUtilityClasses$16 = (ownerState, componentName) => {
18042
18122
  const getContainerUtilityClass = slot => {
18043
18123
  return generateUtilityClass$1(componentName, slot);
18044
18124
  };
@@ -18117,7 +18197,7 @@ function createContainer(options = {}) {
18117
18197
  fixed = false,
18118
18198
  maxWidth = 'lg'
18119
18199
  } = props,
18120
- other = _objectWithoutPropertiesLoose(props, _excluded$1q);
18200
+ other = _objectWithoutPropertiesLoose(props, _excluded$1s);
18121
18201
  const ownerState = _extends$1({}, props, {
18122
18202
  component,
18123
18203
  disableGutters,
@@ -18126,7 +18206,7 @@ function createContainer(options = {}) {
18126
18206
  });
18127
18207
 
18128
18208
  // @ts-ignore module augmentation fails if custom breakpoints are used
18129
- const classes = useUtilityClasses$14(ownerState, componentName);
18209
+ const classes = useUtilityClasses$16(ownerState, componentName);
18130
18210
  return (
18131
18211
  /*#__PURE__*/
18132
18212
  // @ts-ignore theme is injected by the styled util
@@ -18153,7 +18233,7 @@ function createContainer(options = {}) {
18153
18233
  return Container;
18154
18234
  }
18155
18235
 
18156
- const _excluded$1p = ["component", "direction", "spacing", "divider", "children", "className", "useFlexGap"];
18236
+ const _excluded$1r = ["component", "direction", "spacing", "divider", "children", "className", "useFlexGap"];
18157
18237
  const defaultTheme$2 = createTheme$2();
18158
18238
  // widening Theme to any so that the consumer can own the theme structure.
18159
18239
  const defaultCreateStyledComponent = styled('div', {
@@ -18286,7 +18366,7 @@ function createStack(options = {}) {
18286
18366
  className,
18287
18367
  useFlexGap = false
18288
18368
  } = props,
18289
- other = _objectWithoutPropertiesLoose(props, _excluded$1p);
18369
+ other = _objectWithoutPropertiesLoose(props, _excluded$1r);
18290
18370
  const ownerState = {
18291
18371
  direction,
18292
18372
  spacing,
@@ -18365,7 +18445,7 @@ function getInputBaseUtilityClass(slot) {
18365
18445
  }
18366
18446
  const inputBaseClasses = generateUtilityClasses$1('MuiInputBase', ['root', 'formControl', 'focused', 'disabled', 'adornedStart', 'adornedEnd', 'error', 'sizeSmall', 'multiline', 'colorSecondary', 'fullWidth', 'hiddenLabel', 'readOnly', 'input', 'inputSizeSmall', 'inputMultiline', 'inputTypeSearch', 'inputAdornedStart', 'inputAdornedEnd', 'inputHiddenLabel']);
18367
18447
 
18368
- const _excluded$1o = ["aria-describedby", "autoComplete", "autoFocus", "className", "color", "components", "componentsProps", "defaultValue", "disabled", "disableInjectingGlobalStyles", "endAdornment", "error", "fullWidth", "id", "inputComponent", "inputProps", "inputRef", "margin", "maxRows", "minRows", "multiline", "name", "onBlur", "onChange", "onClick", "onFocus", "onKeyDown", "onKeyUp", "placeholder", "readOnly", "renderSuffix", "rows", "size", "slotProps", "slots", "startAdornment", "type", "value"];
18448
+ const _excluded$1q = ["aria-describedby", "autoComplete", "autoFocus", "className", "color", "components", "componentsProps", "defaultValue", "disabled", "disableInjectingGlobalStyles", "endAdornment", "error", "fullWidth", "id", "inputComponent", "inputProps", "inputRef", "margin", "maxRows", "minRows", "multiline", "name", "onBlur", "onChange", "onClick", "onFocus", "onKeyDown", "onKeyUp", "placeholder", "readOnly", "renderSuffix", "rows", "size", "slotProps", "slots", "startAdornment", "type", "value"];
18369
18449
  const rootOverridesResolver = (props, styles) => {
18370
18450
  const {
18371
18451
  ownerState
@@ -18378,7 +18458,7 @@ const inputOverridesResolver = (props, styles) => {
18378
18458
  } = props;
18379
18459
  return [styles.input, ownerState.size === 'small' && styles.inputSizeSmall, ownerState.multiline && styles.inputMultiline, ownerState.type === 'search' && styles.inputTypeSearch, ownerState.startAdornment && styles.inputAdornedStart, ownerState.endAdornment && styles.inputAdornedEnd, ownerState.hiddenLabel && styles.inputHiddenLabel];
18380
18460
  };
18381
- const useUtilityClasses$13 = ownerState => {
18461
+ const useUtilityClasses$15 = ownerState => {
18382
18462
  const {
18383
18463
  classes,
18384
18464
  color,
@@ -18594,7 +18674,7 @@ const InputBase = /*#__PURE__*/React__namespace.forwardRef(function InputBase(in
18594
18674
  type = 'text',
18595
18675
  value: valueProp
18596
18676
  } = props,
18597
- other = _objectWithoutPropertiesLoose(props, _excluded$1o);
18677
+ other = _objectWithoutPropertiesLoose(props, _excluded$1q);
18598
18678
  const value = inputPropsProp.value != null ? inputPropsProp.value : valueProp;
18599
18679
  const {
18600
18680
  current: isControlled
@@ -18768,7 +18848,7 @@ const InputBase = /*#__PURE__*/React__namespace.forwardRef(function InputBase(in
18768
18848
  startAdornment,
18769
18849
  type
18770
18850
  });
18771
- const classes = useUtilityClasses$13(ownerState);
18851
+ const classes = useUtilityClasses$15(ownerState);
18772
18852
  const Root = slots.root || components.Root || InputBaseRoot;
18773
18853
  const rootProps = slotProps.root || componentsProps.root || {};
18774
18854
  const Input = slots.input || components.Input || InputBaseComponent;
@@ -19055,8 +19135,8 @@ function getInputUtilityClass(slot) {
19055
19135
  }
19056
19136
  const inputClasses = _extends$1({}, inputBaseClasses, generateUtilityClasses$1('MuiInput', ['root', 'underline', 'input']));
19057
19137
 
19058
- const _excluded$1n = ["disableUnderline", "components", "componentsProps", "fullWidth", "inputComponent", "multiline", "slotProps", "slots", "type"];
19059
- const useUtilityClasses$12 = ownerState => {
19138
+ const _excluded$1p = ["disableUnderline", "components", "componentsProps", "fullWidth", "inputComponent", "multiline", "slotProps", "slots", "type"];
19139
+ const useUtilityClasses$14 = ownerState => {
19060
19140
  const {
19061
19141
  classes,
19062
19142
  disableUnderline
@@ -19166,8 +19246,8 @@ const Input = /*#__PURE__*/React__namespace.forwardRef(function Input(inProps, r
19166
19246
  slots = {},
19167
19247
  type = 'text'
19168
19248
  } = props,
19169
- other = _objectWithoutPropertiesLoose(props, _excluded$1n);
19170
- const classes = useUtilityClasses$12(props);
19249
+ other = _objectWithoutPropertiesLoose(props, _excluded$1p);
19250
+ const classes = useUtilityClasses$14(props);
19171
19251
  const ownerState = {
19172
19252
  disableUnderline
19173
19253
  };
@@ -19387,8 +19467,8 @@ function getFilledInputUtilityClass(slot) {
19387
19467
  }
19388
19468
  const filledInputClasses = _extends$1({}, inputBaseClasses, generateUtilityClasses$1('MuiFilledInput', ['root', 'underline', 'input']));
19389
19469
 
19390
- const _excluded$1m = ["disableUnderline", "components", "componentsProps", "fullWidth", "hiddenLabel", "inputComponent", "multiline", "slotProps", "slots", "type"];
19391
- const useUtilityClasses$11 = ownerState => {
19470
+ const _excluded$1o = ["disableUnderline", "components", "componentsProps", "fullWidth", "hiddenLabel", "inputComponent", "multiline", "slotProps", "slots", "type"];
19471
+ const useUtilityClasses$13 = ownerState => {
19392
19472
  const {
19393
19473
  classes,
19394
19474
  disableUnderline
@@ -19572,14 +19652,14 @@ const FilledInput = /*#__PURE__*/React__namespace.forwardRef(function FilledInpu
19572
19652
  slots = {},
19573
19653
  type = 'text'
19574
19654
  } = props,
19575
- other = _objectWithoutPropertiesLoose(props, _excluded$1m);
19655
+ other = _objectWithoutPropertiesLoose(props, _excluded$1o);
19576
19656
  const ownerState = _extends$1({}, props, {
19577
19657
  fullWidth,
19578
19658
  inputComponent,
19579
19659
  multiline,
19580
19660
  type
19581
19661
  });
19582
- const classes = useUtilityClasses$11(props);
19662
+ const classes = useUtilityClasses$13(props);
19583
19663
  const filledInputComponentsProps = {
19584
19664
  root: {
19585
19665
  ownerState
@@ -19802,7 +19882,7 @@ process.env.NODE_ENV !== "production" ? FilledInput.propTypes /* remove-proptype
19802
19882
  FilledInput.muiName = 'Input';
19803
19883
 
19804
19884
  var _span$3;
19805
- const _excluded$1l = ["children", "classes", "className", "label", "notched"];
19885
+ const _excluded$1n = ["children", "classes", "className", "label", "notched"];
19806
19886
  const NotchedOutlineRoot$1 = styled$1('fieldset', {
19807
19887
  shouldForwardProp: rootShouldForwardProp
19808
19888
  })({
@@ -19879,7 +19959,7 @@ function NotchedOutline(props) {
19879
19959
  label,
19880
19960
  notched
19881
19961
  } = props,
19882
- other = _objectWithoutPropertiesLoose(props, _excluded$1l);
19962
+ other = _objectWithoutPropertiesLoose(props, _excluded$1n);
19883
19963
  const withLabel = label != null && label !== '';
19884
19964
  const ownerState = _extends$1({}, props, {
19885
19965
  notched,
@@ -19934,8 +20014,8 @@ function getOutlinedInputUtilityClass(slot) {
19934
20014
  }
19935
20015
  const outlinedInputClasses = _extends$1({}, inputBaseClasses, generateUtilityClasses$1('MuiOutlinedInput', ['root', 'notchedOutline', 'input']));
19936
20016
 
19937
- const _excluded$1k = ["components", "fullWidth", "inputComponent", "label", "multiline", "notched", "slots", "type"];
19938
- const useUtilityClasses$10 = ownerState => {
20017
+ const _excluded$1m = ["components", "fullWidth", "inputComponent", "label", "multiline", "notched", "slots", "type"];
20018
+ const useUtilityClasses$12 = ownerState => {
19939
20019
  const {
19940
20020
  classes
19941
20021
  } = ownerState;
@@ -20053,8 +20133,8 @@ const OutlinedInput = /*#__PURE__*/React__namespace.forwardRef(function Outlined
20053
20133
  slots = {},
20054
20134
  type = 'text'
20055
20135
  } = props,
20056
- other = _objectWithoutPropertiesLoose(props, _excluded$1k);
20057
- const classes = useUtilityClasses$10(props);
20136
+ other = _objectWithoutPropertiesLoose(props, _excluded$1m);
20137
+ const classes = useUtilityClasses$12(props);
20058
20138
  const muiFormControl = useFormControl();
20059
20139
  const fcs = formControlState({
20060
20140
  props,
@@ -20272,8 +20352,8 @@ function getFormLabelUtilityClasses(slot) {
20272
20352
  }
20273
20353
  const formLabelClasses = generateUtilityClasses$1('MuiFormLabel', ['root', 'colorSecondary', 'focused', 'disabled', 'error', 'filled', 'required', 'asterisk']);
20274
20354
 
20275
- const _excluded$1j = ["children", "className", "color", "component", "disabled", "error", "filled", "focused", "required"];
20276
- const useUtilityClasses$$ = ownerState => {
20355
+ const _excluded$1l = ["children", "className", "color", "component", "disabled", "error", "filled", "focused", "required"];
20356
+ const useUtilityClasses$11 = ownerState => {
20277
20357
  const {
20278
20358
  classes,
20279
20359
  color,
@@ -20337,7 +20417,7 @@ const FormLabel = /*#__PURE__*/React__namespace.forwardRef(function FormLabel(in
20337
20417
  className,
20338
20418
  component = 'label'
20339
20419
  } = props,
20340
- other = _objectWithoutPropertiesLoose(props, _excluded$1j);
20420
+ other = _objectWithoutPropertiesLoose(props, _excluded$1l);
20341
20421
  const muiFormControl = useFormControl();
20342
20422
  const fcs = formControlState({
20343
20423
  props,
@@ -20353,7 +20433,7 @@ const FormLabel = /*#__PURE__*/React__namespace.forwardRef(function FormLabel(in
20353
20433
  focused: fcs.focused,
20354
20434
  required: fcs.required
20355
20435
  });
20356
- const classes = useUtilityClasses$$(ownerState);
20436
+ const classes = useUtilityClasses$11(ownerState);
20357
20437
  return /*#__PURE__*/jsxRuntimeExports.jsxs(FormLabelRoot, _extends$1({
20358
20438
  as: component,
20359
20439
  ownerState: ownerState,
@@ -20427,8 +20507,8 @@ function getInputLabelUtilityClasses(slot) {
20427
20507
  }
20428
20508
  generateUtilityClasses$1('MuiInputLabel', ['root', 'focused', 'disabled', 'error', 'required', 'asterisk', 'formControl', 'sizeSmall', 'shrink', 'animated', 'standard', 'filled', 'outlined']);
20429
20509
 
20430
- const _excluded$1i = ["disableAnimation", "margin", "shrink", "variant", "className"];
20431
- const useUtilityClasses$_ = ownerState => {
20510
+ const _excluded$1k = ["disableAnimation", "margin", "shrink", "variant", "className"];
20511
+ const useUtilityClasses$10 = ownerState => {
20432
20512
  const {
20433
20513
  classes,
20434
20514
  formControl,
@@ -20529,7 +20609,7 @@ const InputLabel = /*#__PURE__*/React__namespace.forwardRef(function InputLabel(
20529
20609
  shrink: shrinkProp,
20530
20610
  className
20531
20611
  } = props,
20532
- other = _objectWithoutPropertiesLoose(props, _excluded$1i);
20612
+ other = _objectWithoutPropertiesLoose(props, _excluded$1k);
20533
20613
  const muiFormControl = useFormControl();
20534
20614
  let shrink = shrinkProp;
20535
20615
  if (typeof shrink === 'undefined' && muiFormControl) {
@@ -20549,7 +20629,7 @@ const InputLabel = /*#__PURE__*/React__namespace.forwardRef(function InputLabel(
20549
20629
  required: fcs.required,
20550
20630
  focused: fcs.focused
20551
20631
  });
20552
- const classes = useUtilityClasses$_(ownerState);
20632
+ const classes = useUtilityClasses$10(ownerState);
20553
20633
  return /*#__PURE__*/jsxRuntimeExports.jsx(InputLabelRoot, _extends$1({
20554
20634
  "data-shrink": shrink,
20555
20635
  ownerState: ownerState,
@@ -20632,8 +20712,8 @@ function getFormControlUtilityClasses(slot) {
20632
20712
  }
20633
20713
  generateUtilityClasses$1('MuiFormControl', ['root', 'marginNone', 'marginNormal', 'marginDense', 'fullWidth', 'disabled']);
20634
20714
 
20635
- const _excluded$1h = ["children", "className", "color", "component", "disabled", "error", "focused", "fullWidth", "hiddenLabel", "margin", "required", "size", "variant"];
20636
- const useUtilityClasses$Z = ownerState => {
20715
+ const _excluded$1j = ["children", "className", "color", "component", "disabled", "error", "focused", "fullWidth", "hiddenLabel", "margin", "required", "size", "variant"];
20716
+ const useUtilityClasses$$ = ownerState => {
20637
20717
  const {
20638
20718
  classes,
20639
20719
  margin,
@@ -20718,7 +20798,7 @@ const FormControl = /*#__PURE__*/React__namespace.forwardRef(function FormContro
20718
20798
  size = 'medium',
20719
20799
  variant = 'outlined'
20720
20800
  } = props,
20721
- other = _objectWithoutPropertiesLoose(props, _excluded$1h);
20801
+ other = _objectWithoutPropertiesLoose(props, _excluded$1j);
20722
20802
  const ownerState = _extends$1({}, props, {
20723
20803
  color,
20724
20804
  component,
@@ -20731,7 +20811,7 @@ const FormControl = /*#__PURE__*/React__namespace.forwardRef(function FormContro
20731
20811
  size,
20732
20812
  variant
20733
20813
  });
20734
- const classes = useUtilityClasses$Z(ownerState);
20814
+ const classes = useUtilityClasses$$(ownerState);
20735
20815
  const [adornedStart, setAdornedStart] = React__namespace.useState(() => {
20736
20816
  // We need to iterate through the children and find the Input in order
20737
20817
  // to fully support server-side rendering.
@@ -20912,8 +20992,8 @@ function getFormHelperTextUtilityClasses(slot) {
20912
20992
  const formHelperTextClasses = generateUtilityClasses$1('MuiFormHelperText', ['root', 'error', 'disabled', 'sizeSmall', 'sizeMedium', 'contained', 'focused', 'filled', 'required']);
20913
20993
 
20914
20994
  var _span$2;
20915
- const _excluded$1g = ["children", "className", "component", "disabled", "error", "filled", "focused", "margin", "required", "variant"];
20916
- const useUtilityClasses$Y = ownerState => {
20995
+ const _excluded$1i = ["children", "className", "component", "disabled", "error", "filled", "focused", "margin", "required", "variant"];
20996
+ const useUtilityClasses$_ = ownerState => {
20917
20997
  const {
20918
20998
  classes,
20919
20999
  contained,
@@ -20971,7 +21051,7 @@ const FormHelperText = /*#__PURE__*/React__namespace.forwardRef(function FormHel
20971
21051
  className,
20972
21052
  component = 'p'
20973
21053
  } = props,
20974
- other = _objectWithoutPropertiesLoose(props, _excluded$1g);
21054
+ other = _objectWithoutPropertiesLoose(props, _excluded$1i);
20975
21055
  const muiFormControl = useFormControl();
20976
21056
  const fcs = formControlState({
20977
21057
  props,
@@ -20989,7 +21069,7 @@ const FormHelperText = /*#__PURE__*/React__namespace.forwardRef(function FormHel
20989
21069
  focused: fcs.focused,
20990
21070
  required: fcs.required
20991
21071
  });
20992
- const classes = useUtilityClasses$Y(ownerState);
21072
+ const classes = useUtilityClasses$_(ownerState);
20993
21073
  return /*#__PURE__*/jsxRuntimeExports.jsx(FormHelperTextRoot, _extends$1({
20994
21074
  as: component,
20995
21075
  ownerState: ownerState,
@@ -21339,8 +21419,8 @@ function getListUtilityClass(slot) {
21339
21419
  }
21340
21420
  generateUtilityClasses$1('MuiList', ['root', 'padding', 'dense', 'subheader']);
21341
21421
 
21342
- const _excluded$1f = ["children", "className", "component", "dense", "disablePadding", "subheader"];
21343
- const useUtilityClasses$X = ownerState => {
21422
+ const _excluded$1h = ["children", "className", "component", "dense", "disablePadding", "subheader"];
21423
+ const useUtilityClasses$Z = ownerState => {
21344
21424
  const {
21345
21425
  classes,
21346
21426
  disablePadding,
@@ -21387,7 +21467,7 @@ const List = /*#__PURE__*/React__namespace.forwardRef(function List(inProps, ref
21387
21467
  disablePadding = false,
21388
21468
  subheader
21389
21469
  } = props,
21390
- other = _objectWithoutPropertiesLoose(props, _excluded$1f);
21470
+ other = _objectWithoutPropertiesLoose(props, _excluded$1h);
21391
21471
  const context = React__namespace.useMemo(() => ({
21392
21472
  dense
21393
21473
  }), [dense]);
@@ -21396,7 +21476,7 @@ const List = /*#__PURE__*/React__namespace.forwardRef(function List(inProps, ref
21396
21476
  dense,
21397
21477
  disablePadding
21398
21478
  });
21399
- const classes = useUtilityClasses$X(ownerState);
21479
+ const classes = useUtilityClasses$Z(ownerState);
21400
21480
  return /*#__PURE__*/jsxRuntimeExports.jsx(ListContext.Provider, {
21401
21481
  value: context,
21402
21482
  children: /*#__PURE__*/jsxRuntimeExports.jsxs(ListRoot, _extends$1({
@@ -21453,7 +21533,7 @@ process.env.NODE_ENV !== "production" ? List.propTypes /* remove-proptypes */ =
21453
21533
  sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object])
21454
21534
  } : void 0;
21455
21535
 
21456
- const _excluded$1e = ["actions", "autoFocus", "autoFocusItem", "children", "className", "disabledItemsFocusable", "disableListWrap", "onKeyDown", "variant"];
21536
+ const _excluded$1g = ["actions", "autoFocus", "autoFocusItem", "children", "className", "disabledItemsFocusable", "disableListWrap", "onKeyDown", "variant"];
21457
21537
  function nextItem(list, item, disableListWrap) {
21458
21538
  if (list === item) {
21459
21539
  return list.firstChild;
@@ -21535,7 +21615,7 @@ const MenuList = /*#__PURE__*/React__namespace.forwardRef(function MenuList(prop
21535
21615
  onKeyDown,
21536
21616
  variant = 'selectedMenu'
21537
21617
  } = props,
21538
- other = _objectWithoutPropertiesLoose(props, _excluded$1e);
21618
+ other = _objectWithoutPropertiesLoose(props, _excluded$1g);
21539
21619
  const listRef = React__namespace.useRef(null);
21540
21620
  const textCriteriaRef = React__namespace.useRef({
21541
21621
  keys: [],
@@ -23171,7 +23251,7 @@ function getTransitionProps(props, options) {
23171
23251
  };
23172
23252
  }
23173
23253
 
23174
- const _excluded$1d = ["addEndListener", "appear", "children", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"];
23254
+ const _excluded$1f = ["addEndListener", "appear", "children", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"];
23175
23255
  function getScale(value) {
23176
23256
  return `scale(${value}, ${value ** 2})`;
23177
23257
  }
@@ -23215,7 +23295,7 @@ const Grow = /*#__PURE__*/React__namespace.forwardRef(function Grow(props, ref)
23215
23295
  // eslint-disable-next-line react/prop-types
23216
23296
  TransitionComponent = Transition
23217
23297
  } = props,
23218
- other = _objectWithoutPropertiesLoose(props, _excluded$1d);
23298
+ other = _objectWithoutPropertiesLoose(props, _excluded$1f);
23219
23299
  const timer = useTimeout();
23220
23300
  const autoTimeout = React__namespace.useRef();
23221
23301
  const theme = useTheme$2();
@@ -23413,7 +23493,7 @@ process.env.NODE_ENV !== "production" ? Grow.propTypes /* remove-proptypes */ =
23413
23493
  } : void 0;
23414
23494
  Grow.muiSupportAuto = true;
23415
23495
 
23416
- const _excluded$1c = ["addEndListener", "appear", "children", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"];
23496
+ const _excluded$1e = ["addEndListener", "appear", "children", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"];
23417
23497
  const styles = {
23418
23498
  entering: {
23419
23499
  opacity: 1
@@ -23450,7 +23530,7 @@ const Fade = /*#__PURE__*/React__namespace.forwardRef(function Fade(props, ref)
23450
23530
  // eslint-disable-next-line react/prop-types
23451
23531
  TransitionComponent = Transition
23452
23532
  } = props,
23453
- other = _objectWithoutPropertiesLoose(props, _excluded$1c);
23533
+ other = _objectWithoutPropertiesLoose(props, _excluded$1e);
23454
23534
  const nodeRef = React__namespace.useRef(null);
23455
23535
  const handleRef = useForkRef(nodeRef, children.ref, ref);
23456
23536
  const normalizedTransitionCallback = callback => maybeIsAppearing => {
@@ -23610,8 +23690,8 @@ function getBackdropUtilityClass(slot) {
23610
23690
  }
23611
23691
  generateUtilityClasses$1('MuiBackdrop', ['root', 'invisible']);
23612
23692
 
23613
- const _excluded$1b = ["children", "className", "component", "components", "componentsProps", "invisible", "open", "slotProps", "slots", "TransitionComponent", "transitionDuration"];
23614
- const useUtilityClasses$W = ownerState => {
23693
+ const _excluded$1d = ["children", "className", "component", "components", "componentsProps", "invisible", "open", "slotProps", "slots", "TransitionComponent", "transitionDuration"];
23694
+ const useUtilityClasses$Y = ownerState => {
23615
23695
  const {
23616
23696
  classes,
23617
23697
  invisible
@@ -23665,12 +23745,12 @@ const Backdrop = /*#__PURE__*/React__namespace.forwardRef(function Backdrop(inPr
23665
23745
  TransitionComponent = Fade,
23666
23746
  transitionDuration
23667
23747
  } = props,
23668
- other = _objectWithoutPropertiesLoose(props, _excluded$1b);
23748
+ other = _objectWithoutPropertiesLoose(props, _excluded$1d);
23669
23749
  const ownerState = _extends$1({}, props, {
23670
23750
  component,
23671
23751
  invisible
23672
23752
  });
23673
- const classes = useUtilityClasses$W(ownerState);
23753
+ const classes = useUtilityClasses$Y(ownerState);
23674
23754
  const rootSlotProps = (_slotProps$root = slotProps.root) != null ? _slotProps$root : componentsProps.root;
23675
23755
  return /*#__PURE__*/jsxRuntimeExports.jsx(TransitionComponent, _extends$1({
23676
23756
  in: open,
@@ -23790,8 +23870,8 @@ function getModalUtilityClass(slot) {
23790
23870
  }
23791
23871
  generateUtilityClasses$1('MuiModal', ['root', 'hidden', 'backdrop']);
23792
23872
 
23793
- const _excluded$1a = ["BackdropComponent", "BackdropProps", "classes", "className", "closeAfterTransition", "children", "container", "component", "components", "componentsProps", "disableAutoFocus", "disableEnforceFocus", "disableEscapeKeyDown", "disablePortal", "disableRestoreFocus", "disableScrollLock", "hideBackdrop", "keepMounted", "onBackdropClick", "onClose", "onTransitionEnter", "onTransitionExited", "open", "slotProps", "slots", "theme"];
23794
- const useUtilityClasses$V = ownerState => {
23873
+ const _excluded$1c = ["BackdropComponent", "BackdropProps", "classes", "className", "closeAfterTransition", "children", "container", "component", "components", "componentsProps", "disableAutoFocus", "disableEnforceFocus", "disableEscapeKeyDown", "disablePortal", "disableRestoreFocus", "disableScrollLock", "hideBackdrop", "keepMounted", "onBackdropClick", "onClose", "onTransitionEnter", "onTransitionExited", "open", "slotProps", "slots", "theme"];
23874
+ const useUtilityClasses$X = ownerState => {
23795
23875
  const {
23796
23876
  open,
23797
23877
  exited,
@@ -23878,7 +23958,7 @@ const Modal = /*#__PURE__*/React__namespace.forwardRef(function Modal(inProps, r
23878
23958
  slots
23879
23959
  // eslint-disable-next-line react/prop-types
23880
23960
  } = props,
23881
- other = _objectWithoutPropertiesLoose(props, _excluded$1a);
23961
+ other = _objectWithoutPropertiesLoose(props, _excluded$1c);
23882
23962
  const propsWithDefaults = _extends$1({}, props, {
23883
23963
  closeAfterTransition,
23884
23964
  disableAutoFocus,
@@ -23904,7 +23984,7 @@ const Modal = /*#__PURE__*/React__namespace.forwardRef(function Modal(inProps, r
23904
23984
  const ownerState = _extends$1({}, propsWithDefaults, {
23905
23985
  exited
23906
23986
  });
23907
- const classes = useUtilityClasses$V(ownerState);
23987
+ const classes = useUtilityClasses$X(ownerState);
23908
23988
  const childProps = {};
23909
23989
  if (children.props.tabIndex === undefined) {
23910
23990
  childProps.tabIndex = '-1';
@@ -24172,8 +24252,8 @@ function getPaperUtilityClass(slot) {
24172
24252
  }
24173
24253
  generateUtilityClasses$1('MuiPaper', ['root', 'rounded', 'outlined', 'elevation', 'elevation0', 'elevation1', 'elevation2', 'elevation3', 'elevation4', 'elevation5', 'elevation6', 'elevation7', 'elevation8', 'elevation9', 'elevation10', 'elevation11', 'elevation12', 'elevation13', 'elevation14', 'elevation15', 'elevation16', 'elevation17', 'elevation18', 'elevation19', 'elevation20', 'elevation21', 'elevation22', 'elevation23', 'elevation24']);
24174
24254
 
24175
- const _excluded$19 = ["className", "component", "elevation", "square", "variant"];
24176
- const useUtilityClasses$U = ownerState => {
24255
+ const _excluded$1b = ["className", "component", "elevation", "square", "variant"];
24256
+ const useUtilityClasses$W = ownerState => {
24177
24257
  const {
24178
24258
  square,
24179
24259
  elevation,
@@ -24227,14 +24307,14 @@ const Paper = /*#__PURE__*/React__namespace.forwardRef(function Paper(inProps, r
24227
24307
  square = false,
24228
24308
  variant = 'elevation'
24229
24309
  } = props,
24230
- other = _objectWithoutPropertiesLoose(props, _excluded$19);
24310
+ other = _objectWithoutPropertiesLoose(props, _excluded$1b);
24231
24311
  const ownerState = _extends$1({}, props, {
24232
24312
  component,
24233
24313
  elevation,
24234
24314
  square,
24235
24315
  variant
24236
24316
  });
24237
- const classes = useUtilityClasses$U(ownerState);
24317
+ const classes = useUtilityClasses$W(ownerState);
24238
24318
  if (process.env.NODE_ENV !== 'production') {
24239
24319
  // eslint-disable-next-line react-hooks/rules-of-hooks
24240
24320
  const theme = useTheme$2();
@@ -24307,7 +24387,7 @@ function getPopoverUtilityClass(slot) {
24307
24387
  }
24308
24388
  generateUtilityClasses$1('MuiPopover', ['root', 'paper']);
24309
24389
 
24310
- const _excluded$18 = ["onEntering"],
24390
+ const _excluded$1a = ["onEntering"],
24311
24391
  _excluded2$d = ["action", "anchorEl", "anchorOrigin", "anchorPosition", "anchorReference", "children", "className", "container", "elevation", "marginThreshold", "open", "PaperProps", "slots", "slotProps", "transformOrigin", "TransitionComponent", "transitionDuration", "TransitionProps", "disableScrollLock"],
24312
24392
  _excluded3$5 = ["slotProps"];
24313
24393
  function getOffsetTop(rect, vertical) {
@@ -24338,7 +24418,7 @@ function getTransformOriginValue(transformOrigin) {
24338
24418
  function resolveAnchorEl(anchorEl) {
24339
24419
  return typeof anchorEl === 'function' ? anchorEl() : anchorEl;
24340
24420
  }
24341
- const useUtilityClasses$T = ownerState => {
24421
+ const useUtilityClasses$V = ownerState => {
24342
24422
  const {
24343
24423
  classes
24344
24424
  } = ownerState;
@@ -24405,7 +24485,7 @@ const Popover = /*#__PURE__*/React__namespace.forwardRef(function Popover(inProp
24405
24485
  } = {},
24406
24486
  disableScrollLock = false
24407
24487
  } = props,
24408
- TransitionProps = _objectWithoutPropertiesLoose(props.TransitionProps, _excluded$18),
24488
+ TransitionProps = _objectWithoutPropertiesLoose(props.TransitionProps, _excluded$1a),
24409
24489
  other = _objectWithoutPropertiesLoose(props, _excluded2$d);
24410
24490
  const externalPaperSlotProps = (_slotProps$paper = slotProps == null ? void 0 : slotProps.paper) != null ? _slotProps$paper : PaperPropsProp;
24411
24491
  const paperRef = React__namespace.useRef();
@@ -24421,7 +24501,7 @@ const Popover = /*#__PURE__*/React__namespace.forwardRef(function Popover(inProp
24421
24501
  transitionDuration: transitionDurationProp,
24422
24502
  TransitionProps
24423
24503
  });
24424
- const classes = useUtilityClasses$T(ownerState);
24504
+ const classes = useUtilityClasses$V(ownerState);
24425
24505
 
24426
24506
  // Returns the top/left offset of the position
24427
24507
  // to attach to on the anchor element (or body if none is provided)
@@ -24823,7 +24903,7 @@ function getMenuUtilityClass(slot) {
24823
24903
  }
24824
24904
  generateUtilityClasses$1('MuiMenu', ['root', 'paper', 'list']);
24825
24905
 
24826
- const _excluded$17 = ["onEntering"],
24906
+ const _excluded$19 = ["onEntering"],
24827
24907
  _excluded2$c = ["autoFocus", "children", "className", "disableAutoFocusItem", "MenuListProps", "onClose", "open", "PaperProps", "PopoverClasses", "transitionDuration", "TransitionProps", "variant", "slots", "slotProps"];
24828
24908
  const RTL_ORIGIN = {
24829
24909
  vertical: 'top',
@@ -24833,7 +24913,7 @@ const LTR_ORIGIN = {
24833
24913
  vertical: 'top',
24834
24914
  horizontal: 'left'
24835
24915
  };
24836
- const useUtilityClasses$S = ownerState => {
24916
+ const useUtilityClasses$U = ownerState => {
24837
24917
  const {
24838
24918
  classes
24839
24919
  } = ownerState;
@@ -24894,7 +24974,7 @@ const Menu$1 = /*#__PURE__*/React__namespace.forwardRef(function Menu(inProps, r
24894
24974
  slots = {},
24895
24975
  slotProps = {}
24896
24976
  } = props,
24897
- TransitionProps = _objectWithoutPropertiesLoose(props.TransitionProps, _excluded$17),
24977
+ TransitionProps = _objectWithoutPropertiesLoose(props.TransitionProps, _excluded$19),
24898
24978
  other = _objectWithoutPropertiesLoose(props, _excluded2$c);
24899
24979
  const isRtl = useRtl();
24900
24980
  const ownerState = _extends$1({}, props, {
@@ -24907,7 +24987,7 @@ const Menu$1 = /*#__PURE__*/React__namespace.forwardRef(function Menu(inProps, r
24907
24987
  TransitionProps,
24908
24988
  variant
24909
24989
  });
24910
- const classes = useUtilityClasses$S(ownerState);
24990
+ const classes = useUtilityClasses$U(ownerState);
24911
24991
  const autoFocusItem = autoFocus && !disableAutoFocusItem && open;
24912
24992
  const menuListActionsRef = React__namespace.useRef(null);
24913
24993
  const handleEntering = (element, isAppearing) => {
@@ -25117,8 +25197,8 @@ function getNativeSelectUtilityClasses(slot) {
25117
25197
  }
25118
25198
  const nativeSelectClasses = generateUtilityClasses$1('MuiNativeSelect', ['root', 'select', 'multiple', 'filled', 'outlined', 'standard', 'disabled', 'icon', 'iconOpen', 'iconFilled', 'iconOutlined', 'iconStandard', 'nativeInput', 'error']);
25119
25199
 
25120
- const _excluded$16 = ["className", "disabled", "error", "IconComponent", "inputRef", "variant"];
25121
- const useUtilityClasses$R = ownerState => {
25200
+ const _excluded$18 = ["className", "disabled", "error", "IconComponent", "inputRef", "variant"];
25201
+ const useUtilityClasses$T = ownerState => {
25122
25202
  const {
25123
25203
  classes,
25124
25204
  variant,
@@ -25244,13 +25324,13 @@ const NativeSelectInput = /*#__PURE__*/React__namespace.forwardRef(function Nati
25244
25324
  inputRef,
25245
25325
  variant = 'standard'
25246
25326
  } = props,
25247
- other = _objectWithoutPropertiesLoose(props, _excluded$16);
25327
+ other = _objectWithoutPropertiesLoose(props, _excluded$18);
25248
25328
  const ownerState = _extends$1({}, props, {
25249
25329
  disabled,
25250
25330
  variant,
25251
25331
  error
25252
25332
  });
25253
- const classes = useUtilityClasses$R(ownerState);
25333
+ const classes = useUtilityClasses$T(ownerState);
25254
25334
  return /*#__PURE__*/jsxRuntimeExports.jsxs(React__namespace.Fragment, {
25255
25335
  children: [/*#__PURE__*/jsxRuntimeExports.jsx(NativeSelectSelect, _extends$1({
25256
25336
  ownerState: ownerState,
@@ -25326,7 +25406,7 @@ function getSelectUtilityClasses(slot) {
25326
25406
  const selectClasses = generateUtilityClasses$1('MuiSelect', ['root', 'select', 'multiple', 'filled', 'outlined', 'standard', 'disabled', 'focused', 'icon', 'iconOpen', 'iconFilled', 'iconOutlined', 'iconStandard', 'nativeInput', 'error']);
25327
25407
 
25328
25408
  var _span$1;
25329
- const _excluded$15 = ["aria-describedby", "aria-label", "autoFocus", "autoWidth", "children", "className", "defaultOpen", "defaultValue", "disabled", "displayEmpty", "error", "IconComponent", "inputRef", "labelId", "MenuProps", "multiple", "name", "onBlur", "onChange", "onClose", "onFocus", "onOpen", "open", "readOnly", "renderValue", "SelectDisplayProps", "tabIndex", "type", "value", "variant"];
25409
+ const _excluded$17 = ["aria-describedby", "aria-label", "autoFocus", "autoWidth", "children", "className", "defaultOpen", "defaultValue", "disabled", "displayEmpty", "error", "IconComponent", "inputRef", "labelId", "MenuProps", "multiple", "name", "onBlur", "onChange", "onClose", "onFocus", "onOpen", "open", "readOnly", "renderValue", "SelectDisplayProps", "tabIndex", "type", "value", "variant"];
25330
25410
  const SelectSelect = styled$1('div', {
25331
25411
  name: 'MuiSelect',
25332
25412
  slot: 'Select',
@@ -25382,7 +25462,7 @@ const SelectNativeInput = styled$1('input', {
25382
25462
  width: '100%',
25383
25463
  boxSizing: 'border-box'
25384
25464
  });
25385
- function areEqualValues(a, b) {
25465
+ function areEqualValues$1(a, b) {
25386
25466
  if (typeof b === 'object' && b !== null) {
25387
25467
  return a === b;
25388
25468
  }
@@ -25393,7 +25473,7 @@ function areEqualValues(a, b) {
25393
25473
  function isEmpty$1(display) {
25394
25474
  return display == null || typeof display === 'string' && !display.trim();
25395
25475
  }
25396
- const useUtilityClasses$Q = ownerState => {
25476
+ const useUtilityClasses$S = ownerState => {
25397
25477
  const {
25398
25478
  classes,
25399
25479
  variant,
@@ -25449,7 +25529,7 @@ const SelectInput = /*#__PURE__*/React__namespace.forwardRef(function SelectInpu
25449
25529
  value: valueProp,
25450
25530
  variant = 'standard'
25451
25531
  } = props,
25452
- other = _objectWithoutPropertiesLoose(props, _excluded$15);
25532
+ other = _objectWithoutPropertiesLoose(props, _excluded$17);
25453
25533
  const [value, setValueState] = useControlled({
25454
25534
  controlled: valueProp,
25455
25535
  default: defaultValue,
@@ -25657,12 +25737,12 @@ const SelectInput = /*#__PURE__*/React__namespace.forwardRef(function SelectInpu
25657
25737
  if (!Array.isArray(value)) {
25658
25738
  throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The \`value\` prop must be an array when using the \`Select\` component with \`multiple\`.` : formatMuiErrorMessage$1(2));
25659
25739
  }
25660
- selected = value.some(v => areEqualValues(v, child.props.value));
25740
+ selected = value.some(v => areEqualValues$1(v, child.props.value));
25661
25741
  if (selected && computeDisplay) {
25662
25742
  displayMultiple.push(child.props.children);
25663
25743
  }
25664
25744
  } else {
25665
- selected = areEqualValues(value, child.props.value);
25745
+ selected = areEqualValues$1(value, child.props.value);
25666
25746
  if (selected && computeDisplay) {
25667
25747
  displaySingle = child.props.children;
25668
25748
  }
@@ -25736,7 +25816,7 @@ const SelectInput = /*#__PURE__*/React__namespace.forwardRef(function SelectInpu
25736
25816
  open,
25737
25817
  error
25738
25818
  });
25739
- const classes = useUtilityClasses$Q(ownerState);
25819
+ const classes = useUtilityClasses$S(ownerState);
25740
25820
  const paperProps = _extends$1({}, MenuProps.PaperProps, (_MenuProps$slotProps = MenuProps.slotProps) == null ? void 0 : _MenuProps$slotProps.paper);
25741
25821
  const listboxId = useId();
25742
25822
  return /*#__PURE__*/jsxRuntimeExports.jsxs(React__namespace.Fragment, {
@@ -25964,8 +26044,8 @@ function getSvgIconUtilityClass(slot) {
25964
26044
  }
25965
26045
  generateUtilityClasses$1('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);
25966
26046
 
25967
- const _excluded$14 = ["children", "className", "color", "component", "fontSize", "htmlColor", "inheritViewBox", "titleAccess", "viewBox"];
25968
- const useUtilityClasses$P = ownerState => {
26047
+ const _excluded$16 = ["children", "className", "color", "component", "fontSize", "htmlColor", "inheritViewBox", "titleAccess", "viewBox"];
26048
+ const useUtilityClasses$R = ownerState => {
25969
26049
  const {
25970
26050
  color,
25971
26051
  fontSize,
@@ -26032,7 +26112,7 @@ const SvgIcon = /*#__PURE__*/React__namespace.forwardRef(function SvgIcon(inProp
26032
26112
  titleAccess,
26033
26113
  viewBox = '0 0 24 24'
26034
26114
  } = props,
26035
- other = _objectWithoutPropertiesLoose(props, _excluded$14);
26115
+ other = _objectWithoutPropertiesLoose(props, _excluded$16);
26036
26116
  const hasSvgAsChild = /*#__PURE__*/React__namespace.isValidElement(children) && children.type === 'svg';
26037
26117
  const ownerState = _extends$1({}, props, {
26038
26118
  color,
@@ -26047,7 +26127,7 @@ const SvgIcon = /*#__PURE__*/React__namespace.forwardRef(function SvgIcon(inProp
26047
26127
  if (!inheritViewBox) {
26048
26128
  more.viewBox = viewBox;
26049
26129
  }
26050
- const classes = useUtilityClasses$P(ownerState);
26130
+ const classes = useUtilityClasses$R(ownerState);
26051
26131
  return /*#__PURE__*/jsxRuntimeExports.jsxs(SvgIconRoot, _extends$1({
26052
26132
  as: component,
26053
26133
  className: clsx(classes.root, className),
@@ -26159,9 +26239,9 @@ var ArrowDropDownIcon$1 = createSvgIcon$1( /*#__PURE__*/jsxRuntimeExports.jsx("p
26159
26239
  d: "M7 10l5 5 5-5z"
26160
26240
  }), 'ArrowDropDown');
26161
26241
 
26162
- const _excluded$13 = ["autoWidth", "children", "classes", "className", "defaultOpen", "displayEmpty", "IconComponent", "id", "input", "inputProps", "label", "labelId", "MenuProps", "multiple", "native", "onClose", "onOpen", "open", "renderValue", "SelectDisplayProps", "variant"],
26242
+ const _excluded$15 = ["autoWidth", "children", "classes", "className", "defaultOpen", "displayEmpty", "IconComponent", "id", "input", "inputProps", "label", "labelId", "MenuProps", "multiple", "native", "onClose", "onOpen", "open", "renderValue", "SelectDisplayProps", "variant"],
26163
26243
  _excluded2$b = ["root"];
26164
- const useUtilityClasses$O = ownerState => {
26244
+ const useUtilityClasses$Q = ownerState => {
26165
26245
  const {
26166
26246
  classes
26167
26247
  } = ownerState;
@@ -26204,7 +26284,7 @@ const Select = /*#__PURE__*/React__namespace.forwardRef(function Select(inProps,
26204
26284
  SelectDisplayProps,
26205
26285
  variant: variantProp = 'outlined'
26206
26286
  } = props,
26207
- other = _objectWithoutPropertiesLoose(props, _excluded$13);
26287
+ other = _objectWithoutPropertiesLoose(props, _excluded$15);
26208
26288
  const inputComponent = native ? NativeSelectInput : SelectInput;
26209
26289
  const muiFormControl = useFormControl();
26210
26290
  const fcs = formControlState({
@@ -26217,7 +26297,7 @@ const Select = /*#__PURE__*/React__namespace.forwardRef(function Select(inProps,
26217
26297
  variant,
26218
26298
  classes: classesProp
26219
26299
  });
26220
- const classes = useUtilityClasses$O(ownerState);
26300
+ const classes = useUtilityClasses$Q(ownerState);
26221
26301
  const restOfClasses = _objectWithoutPropertiesLoose(classes, _excluded2$b);
26222
26302
  const InputComponent = input || {
26223
26303
  standard: /*#__PURE__*/jsxRuntimeExports.jsx(StyledInput, {
@@ -26427,13 +26507,13 @@ function getTextFieldUtilityClass(slot) {
26427
26507
  }
26428
26508
  generateUtilityClasses$1('MuiTextField', ['root']);
26429
26509
 
26430
- const _excluded$12 = ["autoComplete", "autoFocus", "children", "className", "color", "defaultValue", "disabled", "error", "FormHelperTextProps", "fullWidth", "helperText", "id", "InputLabelProps", "inputProps", "InputProps", "inputRef", "label", "maxRows", "minRows", "multiline", "name", "onBlur", "onChange", "onFocus", "placeholder", "required", "rows", "select", "SelectProps", "type", "value", "variant"];
26510
+ const _excluded$14 = ["autoComplete", "autoFocus", "children", "className", "color", "defaultValue", "disabled", "error", "FormHelperTextProps", "fullWidth", "helperText", "id", "InputLabelProps", "inputProps", "InputProps", "inputRef", "label", "maxRows", "minRows", "multiline", "name", "onBlur", "onChange", "onFocus", "placeholder", "required", "rows", "select", "SelectProps", "type", "value", "variant"];
26431
26511
  const variantComponent = {
26432
26512
  standard: Input,
26433
26513
  filled: FilledInput,
26434
26514
  outlined: OutlinedInput
26435
26515
  };
26436
- const useUtilityClasses$N = ownerState => {
26516
+ const useUtilityClasses$P = ownerState => {
26437
26517
  const {
26438
26518
  classes
26439
26519
  } = ownerState;
@@ -26519,7 +26599,7 @@ const TextField = /*#__PURE__*/React__namespace.forwardRef(function TextField(in
26519
26599
  value,
26520
26600
  variant = 'outlined'
26521
26601
  } = props,
26522
- other = _objectWithoutPropertiesLoose(props, _excluded$12);
26602
+ other = _objectWithoutPropertiesLoose(props, _excluded$14);
26523
26603
  const ownerState = _extends$1({}, props, {
26524
26604
  autoFocus,
26525
26605
  color,
@@ -26531,7 +26611,7 @@ const TextField = /*#__PURE__*/React__namespace.forwardRef(function TextField(in
26531
26611
  select,
26532
26612
  variant
26533
26613
  });
26534
- const classes = useUtilityClasses$N(ownerState);
26614
+ const classes = useUtilityClasses$P(ownerState);
26535
26615
  if (process.env.NODE_ENV !== 'production') {
26536
26616
  if (select && !children) {
26537
26617
  console.error('MUI: `children` must be passed when using the `TextField` component with `select`.');
@@ -26781,7 +26861,7 @@ process.env.NODE_ENV !== "production" ? TextField.propTypes /* remove-proptypes
26781
26861
  variant: PropTypes.oneOf(['filled', 'outlined', 'standard'])
26782
26862
  } : void 0;
26783
26863
 
26784
- const _excluded$11 = ["defaultProps", "mixins", "overrides", "palette", "props", "styleOverrides"],
26864
+ const _excluded$13 = ["defaultProps", "mixins", "overrides", "palette", "props", "styleOverrides"],
26785
26865
  _excluded2$a = ["type", "mode"];
26786
26866
  function adaptV4Theme(inputTheme) {
26787
26867
  if (process.env.NODE_ENV !== 'production') {
@@ -26795,7 +26875,7 @@ function adaptV4Theme(inputTheme) {
26795
26875
  props = {},
26796
26876
  styleOverrides = {}
26797
26877
  } = inputTheme,
26798
- other = _objectWithoutPropertiesLoose(inputTheme, _excluded$11);
26878
+ other = _objectWithoutPropertiesLoose(inputTheme, _excluded$13);
26799
26879
  const theme = _extends$1({}, other, {
26800
26880
  components: {}
26801
26881
  });
@@ -27063,12 +27143,12 @@ Use unitless line heights instead.` : formatMuiErrorMessage$1(6));
27063
27143
  return theme;
27064
27144
  }
27065
27145
 
27066
- const _excluded$10 = ["theme"];
27146
+ const _excluded$12 = ["theme"];
27067
27147
  function ThemeProvider(_ref) {
27068
27148
  let {
27069
27149
  theme: themeInput
27070
27150
  } = _ref,
27071
- props = _objectWithoutPropertiesLoose(_ref, _excluded$10);
27151
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$12);
27072
27152
  const scopedTheme = themeInput[THEME_ID];
27073
27153
  return /*#__PURE__*/jsxRuntimeExports.jsx(ThemeProvider$1, _extends$1({}, props, {
27074
27154
  themeId: scopedTheme ? THEME_ID : undefined,
@@ -27111,7 +27191,7 @@ function shouldSkipGeneratingVar(keys) {
27111
27191
  keys[0] === 'palette' && !!((_keys$ = keys[1]) != null && _keys$.match(/(mode|contrastThreshold|tonalOffset)/));
27112
27192
  }
27113
27193
 
27114
- const _excluded$$ = ["colorSchemes", "cssVarPrefix", "shouldSkipGeneratingVar"],
27194
+ const _excluded$11 = ["colorSchemes", "cssVarPrefix", "shouldSkipGeneratingVar"],
27115
27195
  _excluded2$9 = ["palette"];
27116
27196
  const defaultDarkOverlays = [...Array(25)].map((_, index) => {
27117
27197
  if (index === 0) {
@@ -27161,7 +27241,7 @@ function extendTheme(options = {}, ...args) {
27161
27241
  cssVarPrefix = 'mui',
27162
27242
  shouldSkipGeneratingVar: shouldSkipGeneratingVar$1 = shouldSkipGeneratingVar
27163
27243
  } = options,
27164
- input = _objectWithoutPropertiesLoose(options, _excluded$$);
27244
+ input = _objectWithoutPropertiesLoose(options, _excluded$11);
27165
27245
  const getCssVar = createGetCssVar(cssVarPrefix);
27166
27246
  const _createThemeWithoutVa = createTheme(_extends$1({}, input, colorSchemesInput.light && {
27167
27247
  palette: (_colorSchemesInput$li = colorSchemesInput.light) == null ? void 0 : _colorSchemesInput$li.palette
@@ -27604,7 +27684,7 @@ process.env.NODE_ENV !== "production" ? Ripple.propTypes = {
27604
27684
 
27605
27685
  const touchRippleClasses = generateUtilityClasses$1('MuiTouchRipple', ['root', 'ripple', 'rippleVisible', 'ripplePulsate', 'child', 'childLeaving', 'childPulsate']);
27606
27686
 
27607
- const _excluded$_ = ["center", "classes", "className"];
27687
+ const _excluded$10 = ["center", "classes", "className"];
27608
27688
  let _ = t => t,
27609
27689
  _t,
27610
27690
  _t2,
@@ -27733,7 +27813,7 @@ const TouchRipple = /*#__PURE__*/React__namespace.forwardRef(function TouchRippl
27733
27813
  classes = {},
27734
27814
  className
27735
27815
  } = props,
27736
- other = _objectWithoutPropertiesLoose(props, _excluded$_);
27816
+ other = _objectWithoutPropertiesLoose(props, _excluded$10);
27737
27817
  const [ripples, setRipples] = React__namespace.useState([]);
27738
27818
  const nextKey = React__namespace.useRef(0);
27739
27819
  const rippleCallback = React__namespace.useRef(null);
@@ -27927,8 +28007,8 @@ function getButtonBaseUtilityClass(slot) {
27927
28007
  }
27928
28008
  const buttonBaseClasses = generateUtilityClasses$1('MuiButtonBase', ['root', 'disabled', 'focusVisible']);
27929
28009
 
27930
- const _excluded$Z = ["action", "centerRipple", "children", "className", "component", "disabled", "disableRipple", "disableTouchRipple", "focusRipple", "focusVisibleClassName", "LinkComponent", "onBlur", "onClick", "onContextMenu", "onDragLeave", "onFocus", "onFocusVisible", "onKeyDown", "onKeyUp", "onMouseDown", "onMouseLeave", "onMouseUp", "onTouchEnd", "onTouchMove", "onTouchStart", "tabIndex", "TouchRippleProps", "touchRippleRef", "type"];
27931
- const useUtilityClasses$M = ownerState => {
28010
+ const _excluded$$ = ["action", "centerRipple", "children", "className", "component", "disabled", "disableRipple", "disableTouchRipple", "focusRipple", "focusVisibleClassName", "LinkComponent", "onBlur", "onClick", "onContextMenu", "onDragLeave", "onFocus", "onFocusVisible", "onKeyDown", "onKeyUp", "onMouseDown", "onMouseLeave", "onMouseUp", "onTouchEnd", "onTouchMove", "onTouchStart", "tabIndex", "TouchRippleProps", "touchRippleRef", "type"];
28011
+ const useUtilityClasses$O = ownerState => {
27932
28012
  const {
27933
28013
  disabled,
27934
28014
  focusVisible,
@@ -28028,7 +28108,7 @@ const ButtonBase = /*#__PURE__*/React__namespace.forwardRef(function ButtonBase(
28028
28108
  touchRippleRef,
28029
28109
  type
28030
28110
  } = props,
28031
- other = _objectWithoutPropertiesLoose(props, _excluded$Z);
28111
+ other = _objectWithoutPropertiesLoose(props, _excluded$$);
28032
28112
  const buttonRef = React__namespace.useRef(null);
28033
28113
  const rippleRef = React__namespace.useRef(null);
28034
28114
  const handleRippleRef = useForkRef(rippleRef, touchRippleRef);
@@ -28195,7 +28275,7 @@ const ButtonBase = /*#__PURE__*/React__namespace.forwardRef(function ButtonBase(
28195
28275
  tabIndex,
28196
28276
  focusVisible
28197
28277
  });
28198
- const classes = useUtilityClasses$M(ownerState);
28278
+ const classes = useUtilityClasses$O(ownerState);
28199
28279
  return /*#__PURE__*/jsxRuntimeExports.jsxs(ButtonBaseRoot, _extends$1({
28200
28280
  as: ComponentProp,
28201
28281
  className: clsx(classes.root, className),
@@ -28390,8 +28470,8 @@ function getIconButtonUtilityClass(slot) {
28390
28470
  }
28391
28471
  const iconButtonClasses = generateUtilityClasses$1('MuiIconButton', ['root', 'disabled', 'colorInherit', 'colorPrimary', 'colorSecondary', 'colorError', 'colorInfo', 'colorSuccess', 'colorWarning', 'edgeStart', 'edgeEnd', 'sizeSmall', 'sizeMedium', 'sizeLarge']);
28392
28472
 
28393
- const _excluded$Y = ["edge", "children", "className", "color", "disabled", "disableFocusRipple", "size"];
28394
- const useUtilityClasses$L = ownerState => {
28473
+ const _excluded$_ = ["edge", "children", "className", "color", "disabled", "disableFocusRipple", "size"];
28474
+ const useUtilityClasses$N = ownerState => {
28395
28475
  const {
28396
28476
  classes,
28397
28477
  disabled,
@@ -28491,7 +28571,7 @@ const IconButton = /*#__PURE__*/React__namespace.forwardRef(function IconButton(
28491
28571
  disableFocusRipple = false,
28492
28572
  size = 'medium'
28493
28573
  } = props,
28494
- other = _objectWithoutPropertiesLoose(props, _excluded$Y);
28574
+ other = _objectWithoutPropertiesLoose(props, _excluded$_);
28495
28575
  const ownerState = _extends$1({}, props, {
28496
28576
  edge,
28497
28577
  color,
@@ -28499,7 +28579,7 @@ const IconButton = /*#__PURE__*/React__namespace.forwardRef(function IconButton(
28499
28579
  disableFocusRipple,
28500
28580
  size
28501
28581
  });
28502
- const classes = useUtilityClasses$L(ownerState);
28582
+ const classes = useUtilityClasses$N(ownerState);
28503
28583
  return /*#__PURE__*/jsxRuntimeExports.jsx(IconButtonRoot, _extends$1({
28504
28584
  className: clsx(classes.root, className),
28505
28585
  centerRipple: true,
@@ -28588,8 +28668,8 @@ function getTypographyUtilityClass(slot) {
28588
28668
  }
28589
28669
  generateUtilityClasses$1('MuiTypography', ['root', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'subtitle1', 'subtitle2', 'body1', 'body2', 'inherit', 'button', 'caption', 'overline', 'alignLeft', 'alignRight', 'alignCenter', 'alignJustify', 'noWrap', 'gutterBottom', 'paragraph']);
28590
28670
 
28591
- const _excluded$X = ["align", "className", "component", "gutterBottom", "noWrap", "paragraph", "variant", "variantMapping"];
28592
- const useUtilityClasses$K = ownerState => {
28671
+ const _excluded$Z = ["align", "className", "component", "gutterBottom", "noWrap", "paragraph", "variant", "variantMapping"];
28672
+ const useUtilityClasses$M = ownerState => {
28593
28673
  const {
28594
28674
  align,
28595
28675
  gutterBottom,
@@ -28675,7 +28755,7 @@ const Typography = /*#__PURE__*/React__namespace.forwardRef(function Typography(
28675
28755
  variant = 'body1',
28676
28756
  variantMapping = defaultVariantMapping
28677
28757
  } = props,
28678
- other = _objectWithoutPropertiesLoose(props, _excluded$X);
28758
+ other = _objectWithoutPropertiesLoose(props, _excluded$Z);
28679
28759
  const ownerState = _extends$1({}, props, {
28680
28760
  align,
28681
28761
  color,
@@ -28688,7 +28768,7 @@ const Typography = /*#__PURE__*/React__namespace.forwardRef(function Typography(
28688
28768
  variantMapping
28689
28769
  });
28690
28770
  const Component = component || (paragraph ? 'p' : variantMapping[variant] || defaultVariantMapping[variant]) || 'span';
28691
- const classes = useUtilityClasses$K(ownerState);
28771
+ const classes = useUtilityClasses$M(ownerState);
28692
28772
  return /*#__PURE__*/jsxRuntimeExports.jsx(TypographyRoot, _extends$1({
28693
28773
  as: Component,
28694
28774
  ref: ref,
@@ -28791,7 +28871,7 @@ function useTheme$1(defaultTheme = null) {
28791
28871
  }
28792
28872
  default_1$5 = useThemeWithoutDefault.default = useTheme$1;
28793
28873
 
28794
- const _excluded$W = ["anchorEl", "component", "components", "componentsProps", "container", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "transition", "slots", "slotProps"];
28874
+ const _excluded$Y = ["anchorEl", "component", "components", "componentsProps", "container", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "transition", "slots", "slotProps"];
28795
28875
  const PopperRoot = styled$1(Popper$1, {
28796
28876
  name: 'MuiPopper',
28797
28877
  slot: 'Root',
@@ -28834,7 +28914,7 @@ const Popper = /*#__PURE__*/React__namespace.forwardRef(function Popper(inProps,
28834
28914
  slots,
28835
28915
  slotProps
28836
28916
  } = props,
28837
- other = _objectWithoutPropertiesLoose(props, _excluded$W);
28917
+ other = _objectWithoutPropertiesLoose(props, _excluded$Y);
28838
28918
  const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;
28839
28919
  const otherProps = _extends$1({
28840
28920
  anchorEl,
@@ -28992,8 +29072,8 @@ function getListSubheaderUtilityClass(slot) {
28992
29072
  }
28993
29073
  generateUtilityClasses$1('MuiListSubheader', ['root', 'colorPrimary', 'colorInherit', 'gutters', 'inset', 'sticky']);
28994
29074
 
28995
- const _excluded$V = ["className", "color", "component", "disableGutters", "disableSticky", "inset"];
28996
- const useUtilityClasses$J = ownerState => {
29075
+ const _excluded$X = ["className", "color", "component", "disableGutters", "disableSticky", "inset"];
29076
+ const useUtilityClasses$L = ownerState => {
28997
29077
  const {
28998
29078
  classes,
28999
29079
  color,
@@ -29054,7 +29134,7 @@ const ListSubheader = /*#__PURE__*/React__namespace.forwardRef(function ListSubh
29054
29134
  disableSticky = false,
29055
29135
  inset = false
29056
29136
  } = props,
29057
- other = _objectWithoutPropertiesLoose(props, _excluded$V);
29137
+ other = _objectWithoutPropertiesLoose(props, _excluded$X);
29058
29138
  const ownerState = _extends$1({}, props, {
29059
29139
  color,
29060
29140
  component,
@@ -29062,7 +29142,7 @@ const ListSubheader = /*#__PURE__*/React__namespace.forwardRef(function ListSubh
29062
29142
  disableSticky,
29063
29143
  inset
29064
29144
  });
29065
- const classes = useUtilityClasses$J(ownerState);
29145
+ const classes = useUtilityClasses$L(ownerState);
29066
29146
  return /*#__PURE__*/jsxRuntimeExports.jsx(ListSubheaderRoot, _extends$1({
29067
29147
  as: component,
29068
29148
  className: clsx(classes.root, className),
@@ -29128,8 +29208,8 @@ function getChipUtilityClass(slot) {
29128
29208
  }
29129
29209
  const chipClasses = generateUtilityClasses$1('MuiChip', ['root', 'sizeSmall', 'sizeMedium', 'colorError', 'colorInfo', 'colorPrimary', 'colorSecondary', 'colorSuccess', 'colorWarning', 'disabled', 'clickable', 'clickableColorPrimary', 'clickableColorSecondary', 'deletable', 'deletableColorPrimary', 'deletableColorSecondary', 'outlined', 'filled', 'outlinedPrimary', 'outlinedSecondary', 'filledPrimary', 'filledSecondary', 'avatar', 'avatarSmall', 'avatarMedium', 'avatarColorPrimary', 'avatarColorSecondary', 'icon', 'iconSmall', 'iconMedium', 'iconColorPrimary', 'iconColorSecondary', 'label', 'labelSmall', 'labelMedium', 'deleteIcon', 'deleteIconSmall', 'deleteIconMedium', 'deleteIconColorPrimary', 'deleteIconColorSecondary', 'deleteIconOutlinedColorPrimary', 'deleteIconOutlinedColorSecondary', 'deleteIconFilledColorPrimary', 'deleteIconFilledColorSecondary', 'focusVisible']);
29130
29210
 
29131
- const _excluded$U = ["avatar", "className", "clickable", "color", "component", "deleteIcon", "disabled", "icon", "label", "onClick", "onDelete", "onKeyDown", "onKeyUp", "size", "variant", "tabIndex", "skipFocusWhenDisabled"];
29132
- const useUtilityClasses$I = ownerState => {
29211
+ const _excluded$W = ["avatar", "className", "clickable", "color", "component", "deleteIcon", "disabled", "icon", "label", "onClick", "onDelete", "onKeyDown", "onKeyUp", "size", "variant", "tabIndex", "skipFocusWhenDisabled"];
29212
+ const useUtilityClasses$K = ownerState => {
29133
29213
  const {
29134
29214
  classes,
29135
29215
  disabled,
@@ -29414,7 +29494,7 @@ const Chip = /*#__PURE__*/React__namespace.forwardRef(function Chip(inProps, ref
29414
29494
  tabIndex,
29415
29495
  skipFocusWhenDisabled = false // TODO v6: Rename to `focusableWhenDisabled`.
29416
29496
  } = props,
29417
- other = _objectWithoutPropertiesLoose(props, _excluded$U);
29497
+ other = _objectWithoutPropertiesLoose(props, _excluded$W);
29418
29498
  const chipRef = React__namespace.useRef(null);
29419
29499
  const handleRef = useForkRef(chipRef, ref);
29420
29500
  const handleDeleteIconClick = event => {
@@ -29460,7 +29540,7 @@ const Chip = /*#__PURE__*/React__namespace.forwardRef(function Chip(inProps, ref
29460
29540
  clickable,
29461
29541
  variant
29462
29542
  });
29463
- const classes = useUtilityClasses$I(ownerState);
29543
+ const classes = useUtilityClasses$K(ownerState);
29464
29544
  const moreProps = component === ButtonBase ? _extends$1({
29465
29545
  component: ComponentProp || 'div',
29466
29546
  focusVisibleClassName: classes.focusVisible
@@ -29621,12 +29701,12 @@ function getAutocompleteUtilityClass(slot) {
29621
29701
  const autocompleteClasses = generateUtilityClasses$1('MuiAutocomplete', ['root', 'expanded', 'fullWidth', 'focused', 'focusVisible', 'tag', 'tagSizeSmall', 'tagSizeMedium', 'hasPopupIcon', 'hasClearIcon', 'inputRoot', 'input', 'inputFocused', 'endAdornment', 'clearIndicator', 'popupIndicator', 'popupIndicatorOpen', 'popper', 'popperDisablePortal', 'paper', 'listbox', 'loading', 'noOptions', 'option', 'groupLabel', 'groupUl']);
29622
29702
 
29623
29703
  var _ClearIcon, _ArrowDropDownIcon;
29624
- const _excluded$T = ["autoComplete", "autoHighlight", "autoSelect", "blurOnSelect", "ChipProps", "className", "clearIcon", "clearOnBlur", "clearOnEscape", "clearText", "closeText", "componentsProps", "defaultValue", "disableClearable", "disableCloseOnSelect", "disabled", "disabledItemsFocusable", "disableListWrap", "disablePortal", "filterOptions", "filterSelectedOptions", "forcePopupIcon", "freeSolo", "fullWidth", "getLimitTagsText", "getOptionDisabled", "getOptionKey", "getOptionLabel", "isOptionEqualToValue", "groupBy", "handleHomeEndKeys", "id", "includeInputInList", "inputValue", "limitTags", "ListboxComponent", "ListboxProps", "loading", "loadingText", "multiple", "noOptionsText", "onChange", "onClose", "onHighlightChange", "onInputChange", "onOpen", "open", "openOnFocus", "openText", "options", "PaperComponent", "PopperComponent", "popupIcon", "readOnly", "renderGroup", "renderInput", "renderOption", "renderTags", "selectOnFocus", "size", "slotProps", "value"],
29704
+ const _excluded$V = ["autoComplete", "autoHighlight", "autoSelect", "blurOnSelect", "ChipProps", "className", "clearIcon", "clearOnBlur", "clearOnEscape", "clearText", "closeText", "componentsProps", "defaultValue", "disableClearable", "disableCloseOnSelect", "disabled", "disabledItemsFocusable", "disableListWrap", "disablePortal", "filterOptions", "filterSelectedOptions", "forcePopupIcon", "freeSolo", "fullWidth", "getLimitTagsText", "getOptionDisabled", "getOptionKey", "getOptionLabel", "isOptionEqualToValue", "groupBy", "handleHomeEndKeys", "id", "includeInputInList", "inputValue", "limitTags", "ListboxComponent", "ListboxProps", "loading", "loadingText", "multiple", "noOptionsText", "onChange", "onClose", "onHighlightChange", "onInputChange", "onOpen", "open", "openOnFocus", "openText", "options", "PaperComponent", "PopperComponent", "popupIcon", "readOnly", "renderGroup", "renderInput", "renderOption", "renderTags", "selectOnFocus", "size", "slotProps", "value"],
29625
29705
  _excluded2$8 = ["ref"],
29626
29706
  _excluded3$4 = ["key"],
29627
29707
  _excluded4 = ["key"];
29628
29708
  const useThemeProps = createUseThemeProps();
29629
- const useUtilityClasses$H = ownerState => {
29709
+ const useUtilityClasses$J = ownerState => {
29630
29710
  const {
29631
29711
  classes,
29632
29712
  disablePortal,
@@ -30065,7 +30145,7 @@ const Autocomplete = /*#__PURE__*/React__namespace.forwardRef(function Autocompl
30065
30145
  size = 'medium',
30066
30146
  slotProps = {}
30067
30147
  } = props,
30068
- other = _objectWithoutPropertiesLoose(props, _excluded$T);
30148
+ other = _objectWithoutPropertiesLoose(props, _excluded$V);
30069
30149
  /* eslint-enable @typescript-eslint/no-unused-vars */
30070
30150
 
30071
30151
  const {
@@ -30124,7 +30204,7 @@ const Autocomplete = /*#__PURE__*/React__namespace.forwardRef(function Autocompl
30124
30204
  popupOpen,
30125
30205
  size
30126
30206
  });
30127
- const classes = useUtilityClasses$H(ownerState);
30207
+ const classes = useUtilityClasses$J(ownerState);
30128
30208
  let startAdornment;
30129
30209
  if (multiple && value.length > 0) {
30130
30210
  const getCustomizedTagProps = params => _extends$1({
@@ -30758,8 +30838,8 @@ if (process.env.NODE_ENV !== 'production') {
30758
30838
  ButtonGroupButtonContext.displayName = 'ButtonGroupButtonContext';
30759
30839
  }
30760
30840
 
30761
- const _excluded$S = ["children", "color", "component", "className", "disabled", "disableElevation", "disableFocusRipple", "endIcon", "focusVisibleClassName", "fullWidth", "size", "startIcon", "type", "variant"];
30762
- const useUtilityClasses$G = ownerState => {
30841
+ const _excluded$U = ["children", "color", "component", "className", "disabled", "disableElevation", "disableFocusRipple", "endIcon", "focusVisibleClassName", "fullWidth", "size", "startIcon", "type", "variant"];
30842
+ const useUtilityClasses$I = ownerState => {
30763
30843
  const {
30764
30844
  color,
30765
30845
  disableElevation,
@@ -30985,7 +31065,7 @@ const Button = /*#__PURE__*/React__namespace.forwardRef(function Button(inProps,
30985
31065
  type,
30986
31066
  variant = 'text'
30987
31067
  } = props,
30988
- other = _objectWithoutPropertiesLoose(props, _excluded$S);
31068
+ other = _objectWithoutPropertiesLoose(props, _excluded$U);
30989
31069
  const ownerState = _extends$1({}, props, {
30990
31070
  color,
30991
31071
  component,
@@ -30997,7 +31077,7 @@ const Button = /*#__PURE__*/React__namespace.forwardRef(function Button(inProps,
30997
31077
  type,
30998
31078
  variant
30999
31079
  });
31000
- const classes = useUtilityClasses$G(ownerState);
31080
+ const classes = useUtilityClasses$I(ownerState);
31001
31081
  const startIcon = startIconProp && /*#__PURE__*/jsxRuntimeExports.jsx(ButtonStartIcon, {
31002
31082
  className: classes.startIcon,
31003
31083
  ownerState: ownerState,
@@ -31123,8 +31203,8 @@ function getSwitchBaseUtilityClass(slot) {
31123
31203
  }
31124
31204
  generateUtilityClasses$1('PrivateSwitchBase', ['root', 'checked', 'disabled', 'input', 'edgeStart', 'edgeEnd']);
31125
31205
 
31126
- const _excluded$R = ["autoFocus", "checked", "checkedIcon", "className", "defaultChecked", "disabled", "disableFocusRipple", "edge", "icon", "id", "inputProps", "inputRef", "name", "onBlur", "onChange", "onFocus", "readOnly", "required", "tabIndex", "type", "value"];
31127
- const useUtilityClasses$F = ownerState => {
31206
+ const _excluded$T = ["autoFocus", "checked", "checkedIcon", "className", "defaultChecked", "disabled", "disableFocusRipple", "edge", "icon", "id", "inputProps", "inputRef", "name", "onBlur", "onChange", "onFocus", "readOnly", "required", "tabIndex", "type", "value"];
31207
+ const useUtilityClasses$H = ownerState => {
31128
31208
  const {
31129
31209
  classes,
31130
31210
  checked,
@@ -31189,7 +31269,7 @@ const SwitchBase = /*#__PURE__*/React__namespace.forwardRef(function SwitchBase(
31189
31269
  type,
31190
31270
  value
31191
31271
  } = props,
31192
- other = _objectWithoutPropertiesLoose(props, _excluded$R);
31272
+ other = _objectWithoutPropertiesLoose(props, _excluded$T);
31193
31273
  const [checked, setCheckedState] = useControlled({
31194
31274
  controlled: checkedProp,
31195
31275
  default: Boolean(defaultChecked),
@@ -31238,7 +31318,7 @@ const SwitchBase = /*#__PURE__*/React__namespace.forwardRef(function SwitchBase(
31238
31318
  disableFocusRipple,
31239
31319
  edge
31240
31320
  });
31241
- const classes = useUtilityClasses$F(ownerState);
31321
+ const classes = useUtilityClasses$H(ownerState);
31242
31322
  return /*#__PURE__*/jsxRuntimeExports.jsxs(SwitchBaseRoot, _extends$1({
31243
31323
  component: "span",
31244
31324
  className: clsx(classes.root, className),
@@ -31396,8 +31476,8 @@ function getCheckboxUtilityClass(slot) {
31396
31476
  }
31397
31477
  const checkboxClasses = generateUtilityClasses$1('MuiCheckbox', ['root', 'checked', 'disabled', 'indeterminate', 'colorPrimary', 'colorSecondary', 'sizeSmall', 'sizeMedium']);
31398
31478
 
31399
- const _excluded$Q = ["checkedIcon", "color", "icon", "indeterminate", "indeterminateIcon", "inputProps", "size", "className"];
31400
- const useUtilityClasses$E = ownerState => {
31479
+ const _excluded$S = ["checkedIcon", "color", "icon", "indeterminate", "indeterminateIcon", "inputProps", "size", "className"];
31480
+ const useUtilityClasses$G = ownerState => {
31401
31481
  const {
31402
31482
  classes,
31403
31483
  indeterminate,
@@ -31441,8 +31521,8 @@ const CheckboxRoot = styled$1(SwitchBase, {
31441
31521
  color: (theme.vars || theme).palette.action.disabled
31442
31522
  }
31443
31523
  }));
31444
- const defaultCheckedIcon = /*#__PURE__*/jsxRuntimeExports.jsx(CheckBoxIcon, {});
31445
- const defaultIcon = /*#__PURE__*/jsxRuntimeExports.jsx(CheckBoxOutlineBlankIcon, {});
31524
+ const defaultCheckedIcon$1 = /*#__PURE__*/jsxRuntimeExports.jsx(CheckBoxIcon, {});
31525
+ const defaultIcon$1 = /*#__PURE__*/jsxRuntimeExports.jsx(CheckBoxOutlineBlankIcon, {});
31446
31526
  const defaultIndeterminateIcon = /*#__PURE__*/jsxRuntimeExports.jsx(IndeterminateCheckBoxIcon, {});
31447
31527
  const Checkbox = /*#__PURE__*/React__namespace.forwardRef(function Checkbox(inProps, ref) {
31448
31528
  var _icon$props$fontSize, _indeterminateIcon$pr;
@@ -31451,16 +31531,16 @@ const Checkbox = /*#__PURE__*/React__namespace.forwardRef(function Checkbox(inPr
31451
31531
  name: 'MuiCheckbox'
31452
31532
  });
31453
31533
  const {
31454
- checkedIcon = defaultCheckedIcon,
31534
+ checkedIcon = defaultCheckedIcon$1,
31455
31535
  color = 'primary',
31456
- icon: iconProp = defaultIcon,
31536
+ icon: iconProp = defaultIcon$1,
31457
31537
  indeterminate = false,
31458
31538
  indeterminateIcon: indeterminateIconProp = defaultIndeterminateIcon,
31459
31539
  inputProps,
31460
31540
  size = 'medium',
31461
31541
  className
31462
31542
  } = props,
31463
- other = _objectWithoutPropertiesLoose(props, _excluded$Q);
31543
+ other = _objectWithoutPropertiesLoose(props, _excluded$S);
31464
31544
  const icon = indeterminate ? indeterminateIconProp : iconProp;
31465
31545
  const indeterminateIcon = indeterminate ? indeterminateIconProp : checkedIcon;
31466
31546
  const ownerState = _extends$1({}, props, {
@@ -31468,7 +31548,7 @@ const Checkbox = /*#__PURE__*/React__namespace.forwardRef(function Checkbox(inPr
31468
31548
  indeterminate,
31469
31549
  size
31470
31550
  });
31471
- const classes = useUtilityClasses$E(ownerState);
31551
+ const classes = useUtilityClasses$G(ownerState);
31472
31552
  return /*#__PURE__*/jsxRuntimeExports.jsx(CheckboxRoot, _extends$1({
31473
31553
  type: "checkbox",
31474
31554
  inputProps: _extends$1({
@@ -31659,7 +31739,7 @@ if (process.env.NODE_ENV !== 'production') {
31659
31739
  DialogContext.displayName = 'DialogContext';
31660
31740
  }
31661
31741
 
31662
- const _excluded$P = ["aria-describedby", "aria-labelledby", "BackdropComponent", "BackdropProps", "children", "className", "disableEscapeKeyDown", "fullScreen", "fullWidth", "maxWidth", "onBackdropClick", "onClick", "onClose", "open", "PaperComponent", "PaperProps", "scroll", "TransitionComponent", "transitionDuration", "TransitionProps"];
31742
+ const _excluded$R = ["aria-describedby", "aria-labelledby", "BackdropComponent", "BackdropProps", "children", "className", "disableEscapeKeyDown", "fullScreen", "fullWidth", "maxWidth", "onBackdropClick", "onClick", "onClose", "open", "PaperComponent", "PaperProps", "scroll", "TransitionComponent", "transitionDuration", "TransitionProps"];
31663
31743
  const DialogBackdrop = styled$1(Backdrop, {
31664
31744
  name: 'MuiDialog',
31665
31745
  slot: 'Backdrop',
@@ -31668,7 +31748,7 @@ const DialogBackdrop = styled$1(Backdrop, {
31668
31748
  // Improve scrollable dialog support.
31669
31749
  zIndex: -1
31670
31750
  });
31671
- const useUtilityClasses$D = ownerState => {
31751
+ const useUtilityClasses$F = ownerState => {
31672
31752
  const {
31673
31753
  classes,
31674
31754
  scroll,
@@ -31822,7 +31902,7 @@ const Dialog = /*#__PURE__*/React__namespace.forwardRef(function Dialog(inProps,
31822
31902
  transitionDuration = defaultTransitionDuration,
31823
31903
  TransitionProps
31824
31904
  } = props,
31825
- other = _objectWithoutPropertiesLoose(props, _excluded$P);
31905
+ other = _objectWithoutPropertiesLoose(props, _excluded$R);
31826
31906
  const ownerState = _extends$1({}, props, {
31827
31907
  disableEscapeKeyDown,
31828
31908
  fullScreen,
@@ -31830,7 +31910,7 @@ const Dialog = /*#__PURE__*/React__namespace.forwardRef(function Dialog(inProps,
31830
31910
  maxWidth,
31831
31911
  scroll
31832
31912
  });
31833
- const classes = useUtilityClasses$D(ownerState);
31913
+ const classes = useUtilityClasses$F(ownerState);
31834
31914
  const backdropClick = React__namespace.useRef();
31835
31915
  const handleMouseDown = event => {
31836
31916
  // We don't want to close the dialog when clicking the dialog content.
@@ -32045,8 +32125,8 @@ function getDialogActionsUtilityClass(slot) {
32045
32125
  }
32046
32126
  generateUtilityClasses$1('MuiDialogActions', ['root', 'spacing']);
32047
32127
 
32048
- const _excluded$O = ["className", "disableSpacing"];
32049
- const useUtilityClasses$C = ownerState => {
32128
+ const _excluded$Q = ["className", "disableSpacing"];
32129
+ const useUtilityClasses$E = ownerState => {
32050
32130
  const {
32051
32131
  classes,
32052
32132
  disableSpacing
@@ -32087,11 +32167,11 @@ const DialogActions = /*#__PURE__*/React__namespace.forwardRef(function DialogAc
32087
32167
  className,
32088
32168
  disableSpacing = false
32089
32169
  } = props,
32090
- other = _objectWithoutPropertiesLoose(props, _excluded$O);
32170
+ other = _objectWithoutPropertiesLoose(props, _excluded$Q);
32091
32171
  const ownerState = _extends$1({}, props, {
32092
32172
  disableSpacing
32093
32173
  });
32094
- const classes = useUtilityClasses$C(ownerState);
32174
+ const classes = useUtilityClasses$E(ownerState);
32095
32175
  return /*#__PURE__*/jsxRuntimeExports.jsx(DialogActionsRoot, _extends$1({
32096
32176
  className: clsx(classes.root, className),
32097
32177
  ownerState: ownerState,
@@ -32136,8 +32216,8 @@ function getDialogTitleUtilityClass(slot) {
32136
32216
  }
32137
32217
  const dialogTitleClasses = generateUtilityClasses$1('MuiDialogTitle', ['root']);
32138
32218
 
32139
- const _excluded$N = ["className", "dividers"];
32140
- const useUtilityClasses$B = ownerState => {
32219
+ const _excluded$P = ["className", "dividers"];
32220
+ const useUtilityClasses$D = ownerState => {
32141
32221
  const {
32142
32222
  classes,
32143
32223
  dividers
@@ -32183,11 +32263,11 @@ const DialogContent = /*#__PURE__*/React__namespace.forwardRef(function DialogCo
32183
32263
  className,
32184
32264
  dividers = false
32185
32265
  } = props,
32186
- other = _objectWithoutPropertiesLoose(props, _excluded$N);
32266
+ other = _objectWithoutPropertiesLoose(props, _excluded$P);
32187
32267
  const ownerState = _extends$1({}, props, {
32188
32268
  dividers
32189
32269
  });
32190
- const classes = useUtilityClasses$B(ownerState);
32270
+ const classes = useUtilityClasses$D(ownerState);
32191
32271
  return /*#__PURE__*/jsxRuntimeExports.jsx(DialogContentRoot, _extends$1({
32192
32272
  className: clsx(classes.root, className),
32193
32273
  ownerState: ownerState,
@@ -32222,8 +32302,8 @@ process.env.NODE_ENV !== "production" ? DialogContent.propTypes /* remove-propty
32222
32302
  sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object])
32223
32303
  } : void 0;
32224
32304
 
32225
- const _excluded$M = ["className", "id"];
32226
- const useUtilityClasses$A = ownerState => {
32305
+ const _excluded$O = ["className", "id"];
32306
+ const useUtilityClasses$C = ownerState => {
32227
32307
  const {
32228
32308
  classes
32229
32309
  } = ownerState;
@@ -32249,9 +32329,9 @@ const DialogTitle = /*#__PURE__*/React__namespace.forwardRef(function DialogTitl
32249
32329
  className,
32250
32330
  id: idProp
32251
32331
  } = props,
32252
- other = _objectWithoutPropertiesLoose(props, _excluded$M);
32332
+ other = _objectWithoutPropertiesLoose(props, _excluded$O);
32253
32333
  const ownerState = props;
32254
- const classes = useUtilityClasses$A(ownerState);
32334
+ const classes = useUtilityClasses$C(ownerState);
32255
32335
  const {
32256
32336
  titleId = idProp
32257
32337
  } = React__namespace.useContext(DialogContext);
@@ -32296,8 +32376,8 @@ function getDividerUtilityClass(slot) {
32296
32376
  }
32297
32377
  const dividerClasses = generateUtilityClasses$1('MuiDivider', ['root', 'absolute', 'fullWidth', 'inset', 'middle', 'flexItem', 'light', 'vertical', 'withChildren', 'withChildrenVertical', 'textAlignRight', 'textAlignLeft', 'wrapper', 'wrapperVertical']);
32298
32378
 
32299
- const _excluded$L = ["absolute", "children", "className", "component", "flexItem", "light", "orientation", "role", "textAlign", "variant"];
32300
- const useUtilityClasses$z = ownerState => {
32379
+ const _excluded$N = ["absolute", "children", "className", "component", "flexItem", "light", "orientation", "role", "textAlign", "variant"];
32380
+ const useUtilityClasses$B = ownerState => {
32301
32381
  const {
32302
32382
  absolute,
32303
32383
  children,
@@ -32438,7 +32518,7 @@ const Divider = /*#__PURE__*/React__namespace.forwardRef(function Divider(inProp
32438
32518
  textAlign = 'center',
32439
32519
  variant = 'fullWidth'
32440
32520
  } = props,
32441
- other = _objectWithoutPropertiesLoose(props, _excluded$L);
32521
+ other = _objectWithoutPropertiesLoose(props, _excluded$N);
32442
32522
  const ownerState = _extends$1({}, props, {
32443
32523
  absolute,
32444
32524
  component,
@@ -32449,7 +32529,7 @@ const Divider = /*#__PURE__*/React__namespace.forwardRef(function Divider(inProp
32449
32529
  textAlign,
32450
32530
  variant
32451
32531
  });
32452
- const classes = useUtilityClasses$z(ownerState);
32532
+ const classes = useUtilityClasses$B(ownerState);
32453
32533
  return /*#__PURE__*/jsxRuntimeExports.jsx(DividerRoot, _extends$1({
32454
32534
  as: component,
32455
32535
  className: clsx(classes.root, className),
@@ -32534,7 +32614,7 @@ process.env.NODE_ENV !== "production" ? Divider.propTypes /* remove-proptypes */
32534
32614
  variant: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['fullWidth', 'inset', 'middle']), PropTypes.string])
32535
32615
  } : void 0;
32536
32616
 
32537
- const _excluded$K = ["addEndListener", "appear", "children", "container", "direction", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"];
32617
+ const _excluded$M = ["addEndListener", "appear", "children", "container", "direction", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"];
32538
32618
  function getTranslateValue(direction, node, resolvedContainer) {
32539
32619
  const rect = node.getBoundingClientRect();
32540
32620
  const containerRect = resolvedContainer && resolvedContainer.getBoundingClientRect();
@@ -32623,7 +32703,7 @@ const Slide = /*#__PURE__*/React__namespace.forwardRef(function Slide(props, ref
32623
32703
  // eslint-disable-next-line react/prop-types
32624
32704
  TransitionComponent = Transition
32625
32705
  } = props,
32626
- other = _objectWithoutPropertiesLoose(props, _excluded$K);
32706
+ other = _objectWithoutPropertiesLoose(props, _excluded$M);
32627
32707
  const childrenRef = React__namespace.useRef(null);
32628
32708
  const handleRef = useForkRef(children.ref, childrenRef, ref);
32629
32709
  const normalizedTransitionCallback = callback => isAppearing => {
@@ -32906,8 +32986,8 @@ function getFormControlLabelUtilityClasses(slot) {
32906
32986
  }
32907
32987
  const formControlLabelClasses = generateUtilityClasses$1('MuiFormControlLabel', ['root', 'labelPlacementStart', 'labelPlacementTop', 'labelPlacementBottom', 'disabled', 'label', 'error', 'required', 'asterisk']);
32908
32988
 
32909
- const _excluded$J = ["checked", "className", "componentsProps", "control", "disabled", "disableTypography", "inputRef", "label", "labelPlacement", "name", "onChange", "required", "slotProps", "value"];
32910
- const useUtilityClasses$y = ownerState => {
32989
+ const _excluded$L = ["checked", "className", "componentsProps", "control", "disabled", "disableTypography", "inputRef", "label", "labelPlacement", "name", "onChange", "required", "slotProps", "value"];
32990
+ const useUtilityClasses$A = ownerState => {
32911
32991
  const {
32912
32992
  classes,
32913
32993
  disabled,
@@ -33000,7 +33080,7 @@ const FormControlLabel = /*#__PURE__*/React__namespace.forwardRef(function FormC
33000
33080
  required: requiredProp,
33001
33081
  slotProps = {}
33002
33082
  } = props,
33003
- other = _objectWithoutPropertiesLoose(props, _excluded$J);
33083
+ other = _objectWithoutPropertiesLoose(props, _excluded$L);
33004
33084
  const muiFormControl = useFormControl();
33005
33085
  const disabled = (_ref = disabledProp != null ? disabledProp : control.props.disabled) != null ? _ref : muiFormControl == null ? void 0 : muiFormControl.disabled;
33006
33086
  const required = requiredProp != null ? requiredProp : control.props.required;
@@ -33024,7 +33104,7 @@ const FormControlLabel = /*#__PURE__*/React__namespace.forwardRef(function FormC
33024
33104
  required,
33025
33105
  error: fcs.error
33026
33106
  });
33027
- const classes = useUtilityClasses$y(ownerState);
33107
+ const classes = useUtilityClasses$A(ownerState);
33028
33108
  const typographySlotProps = (_slotProps$typography = slotProps.typography) != null ? _slotProps$typography : componentsProps.typography;
33029
33109
  let label = labelProp;
33030
33110
  if (label != null && label.type !== Typography && !disableTypography) {
@@ -33137,8 +33217,8 @@ function getFormGroupUtilityClass(slot) {
33137
33217
  }
33138
33218
  generateUtilityClasses$1('MuiFormGroup', ['root', 'row', 'error']);
33139
33219
 
33140
- const _excluded$I = ["className", "row"];
33141
- const useUtilityClasses$x = ownerState => {
33220
+ const _excluded$K = ["className", "row"];
33221
+ const useUtilityClasses$z = ownerState => {
33142
33222
  const {
33143
33223
  classes,
33144
33224
  row,
@@ -33182,7 +33262,7 @@ const FormGroup = /*#__PURE__*/React__namespace.forwardRef(function FormGroup(in
33182
33262
  className,
33183
33263
  row = false
33184
33264
  } = props,
33185
- other = _objectWithoutPropertiesLoose(props, _excluded$I);
33265
+ other = _objectWithoutPropertiesLoose(props, _excluded$K);
33186
33266
  const muiFormControl = useFormControl();
33187
33267
  const fcs = formControlState({
33188
33268
  props,
@@ -33193,7 +33273,7 @@ const FormGroup = /*#__PURE__*/React__namespace.forwardRef(function FormGroup(in
33193
33273
  row,
33194
33274
  error: fcs.error
33195
33275
  });
33196
- const classes = useUtilityClasses$x(ownerState);
33276
+ const classes = useUtilityClasses$z(ownerState);
33197
33277
  return /*#__PURE__*/jsxRuntimeExports.jsx(FormGroupRoot, _extends$1({
33198
33278
  className: clsx(classes.root, className),
33199
33279
  ownerState: ownerState,
@@ -33253,7 +33333,7 @@ const gridClasses = generateUtilityClasses$1('MuiGrid', ['root', 'container', 'i
33253
33333
  // grid sizes for all breakpoints
33254
33334
  ...GRID_SIZES.map(size => `grid-xs-${size}`), ...GRID_SIZES.map(size => `grid-sm-${size}`), ...GRID_SIZES.map(size => `grid-md-${size}`), ...GRID_SIZES.map(size => `grid-lg-${size}`), ...GRID_SIZES.map(size => `grid-xl-${size}`)]);
33255
33335
 
33256
- const _excluded$H = ["className", "columns", "columnSpacing", "component", "container", "direction", "item", "rowSpacing", "spacing", "wrap", "zeroMinWidth"];
33336
+ const _excluded$J = ["className", "columns", "columnSpacing", "component", "container", "direction", "item", "rowSpacing", "spacing", "wrap", "zeroMinWidth"];
33257
33337
  function getOffset(val) {
33258
33338
  const parse = parseFloat(val);
33259
33339
  return `${parse}${String(val).replace(String(parse), '') || 'px'}`;
@@ -33562,7 +33642,7 @@ function resolveSpacingClasses(spacing, breakpoints) {
33562
33642
  });
33563
33643
  return classes;
33564
33644
  }
33565
- const useUtilityClasses$w = ownerState => {
33645
+ const useUtilityClasses$y = ownerState => {
33566
33646
  const {
33567
33647
  classes,
33568
33648
  container,
@@ -33613,7 +33693,7 @@ const Grid = /*#__PURE__*/React__namespace.forwardRef(function Grid(inProps, ref
33613
33693
  wrap = 'wrap',
33614
33694
  zeroMinWidth = false
33615
33695
  } = props,
33616
- other = _objectWithoutPropertiesLoose(props, _excluded$H);
33696
+ other = _objectWithoutPropertiesLoose(props, _excluded$J);
33617
33697
  const rowSpacing = rowSpacingProp || spacing;
33618
33698
  const columnSpacing = columnSpacingProp || spacing;
33619
33699
  const columnsContext = React__namespace.useContext(GridContext);
@@ -33641,7 +33721,7 @@ const Grid = /*#__PURE__*/React__namespace.forwardRef(function Grid(inProps, ref
33641
33721
  }, breakpointsValues, {
33642
33722
  breakpoints: breakpoints.keys
33643
33723
  });
33644
- const classes = useUtilityClasses$w(ownerState);
33724
+ const classes = useUtilityClasses$y(ownerState);
33645
33725
  return /*#__PURE__*/jsxRuntimeExports.jsx(GridContext.Provider, {
33646
33726
  value: columns,
33647
33727
  children: /*#__PURE__*/jsxRuntimeExports.jsx(GridRoot, _extends$1({
@@ -33801,14 +33881,14 @@ function getInputAdornmentUtilityClass(slot) {
33801
33881
  const inputAdornmentClasses = generateUtilityClasses$1('MuiInputAdornment', ['root', 'filled', 'standard', 'outlined', 'positionStart', 'positionEnd', 'disablePointerEvents', 'hiddenLabel', 'sizeSmall']);
33802
33882
 
33803
33883
  var _span;
33804
- const _excluded$G = ["children", "className", "component", "disablePointerEvents", "disableTypography", "position", "variant"];
33884
+ const _excluded$I = ["children", "className", "component", "disablePointerEvents", "disableTypography", "position", "variant"];
33805
33885
  const overridesResolver$3 = (props, styles) => {
33806
33886
  const {
33807
33887
  ownerState
33808
33888
  } = props;
33809
33889
  return [styles.root, styles[`position${capitalize$1(ownerState.position)}`], ownerState.disablePointerEvents === true && styles.disablePointerEvents, styles[ownerState.variant]];
33810
33890
  };
33811
- const useUtilityClasses$v = ownerState => {
33891
+ const useUtilityClasses$x = ownerState => {
33812
33892
  const {
33813
33893
  classes,
33814
33894
  disablePointerEvents,
@@ -33866,7 +33946,7 @@ const InputAdornment = /*#__PURE__*/React__namespace.forwardRef(function InputAd
33866
33946
  position,
33867
33947
  variant: variantProp
33868
33948
  } = props,
33869
- other = _objectWithoutPropertiesLoose(props, _excluded$G);
33949
+ other = _objectWithoutPropertiesLoose(props, _excluded$I);
33870
33950
  const muiFormControl = useFormControl() || {};
33871
33951
  let variant = variantProp;
33872
33952
  if (variantProp && muiFormControl.variant) {
@@ -33886,7 +33966,7 @@ const InputAdornment = /*#__PURE__*/React__namespace.forwardRef(function InputAd
33886
33966
  position,
33887
33967
  variant
33888
33968
  });
33889
- const classes = useUtilityClasses$v(ownerState);
33969
+ const classes = useUtilityClasses$x(ownerState);
33890
33970
  return /*#__PURE__*/jsxRuntimeExports.jsx(FormControlContext.Provider, {
33891
33971
  value: null,
33892
33972
  children: /*#__PURE__*/jsxRuntimeExports.jsx(InputAdornmentRoot, _extends$1({
@@ -33968,8 +34048,8 @@ function getListItemSecondaryActionClassesUtilityClass(slot) {
33968
34048
  }
33969
34049
  generateUtilityClasses$1('MuiListItemSecondaryAction', ['root', 'disableGutters']);
33970
34050
 
33971
- const _excluded$F = ["className"];
33972
- const useUtilityClasses$u = ownerState => {
34051
+ const _excluded$H = ["className"];
34052
+ const useUtilityClasses$w = ownerState => {
33973
34053
  const {
33974
34054
  disableGutters,
33975
34055
  classes
@@ -34010,12 +34090,12 @@ const ListItemSecondaryAction = /*#__PURE__*/React__namespace.forwardRef(functio
34010
34090
  const {
34011
34091
  className
34012
34092
  } = props,
34013
- other = _objectWithoutPropertiesLoose(props, _excluded$F);
34093
+ other = _objectWithoutPropertiesLoose(props, _excluded$H);
34014
34094
  const context = React__namespace.useContext(ListContext);
34015
34095
  const ownerState = _extends$1({}, props, {
34016
34096
  disableGutters: context.disableGutters
34017
34097
  });
34018
- const classes = useUtilityClasses$u(ownerState);
34098
+ const classes = useUtilityClasses$w(ownerState);
34019
34099
  return /*#__PURE__*/jsxRuntimeExports.jsx(ListItemSecondaryActionRoot, _extends$1({
34020
34100
  className: clsx(classes.root, className),
34021
34101
  ownerState: ownerState,
@@ -34046,7 +34126,7 @@ process.env.NODE_ENV !== "production" ? ListItemSecondaryAction.propTypes /* rem
34046
34126
  } : void 0;
34047
34127
  ListItemSecondaryAction.muiName = 'ListItemSecondaryAction';
34048
34128
 
34049
- const _excluded$E = ["className"],
34129
+ const _excluded$G = ["className"],
34050
34130
  _excluded2$7 = ["alignItems", "autoFocus", "button", "children", "className", "component", "components", "componentsProps", "ContainerComponent", "ContainerProps", "dense", "disabled", "disableGutters", "disablePadding", "divider", "focusVisibleClassName", "secondaryAction", "selected", "slotProps", "slots"];
34051
34131
  const overridesResolver$2 = (props, styles) => {
34052
34132
  const {
@@ -34054,7 +34134,7 @@ const overridesResolver$2 = (props, styles) => {
34054
34134
  } = props;
34055
34135
  return [styles.root, ownerState.dense && styles.dense, ownerState.alignItems === 'flex-start' && styles.alignItemsFlexStart, ownerState.divider && styles.divider, !ownerState.disableGutters && styles.gutters, !ownerState.disablePadding && styles.padding, ownerState.button && styles.button, ownerState.hasSecondaryAction && styles.secondaryAction];
34056
34136
  };
34057
- const useUtilityClasses$t = ownerState => {
34137
+ const useUtilityClasses$v = ownerState => {
34058
34138
  const {
34059
34139
  alignItems,
34060
34140
  button,
@@ -34188,7 +34268,7 @@ const ListItem = /*#__PURE__*/React__namespace.forwardRef(function ListItem(inPr
34188
34268
  slotProps = {},
34189
34269
  slots = {}
34190
34270
  } = props,
34191
- ContainerProps = _objectWithoutPropertiesLoose(props.ContainerProps, _excluded$E),
34271
+ ContainerProps = _objectWithoutPropertiesLoose(props.ContainerProps, _excluded$G),
34192
34272
  other = _objectWithoutPropertiesLoose(props, _excluded2$7);
34193
34273
  const context = React__namespace.useContext(ListContext);
34194
34274
  const childContext = React__namespace.useMemo(() => ({
@@ -34222,7 +34302,7 @@ const ListItem = /*#__PURE__*/React__namespace.forwardRef(function ListItem(inPr
34222
34302
  hasSecondaryAction,
34223
34303
  selected
34224
34304
  });
34225
- const classes = useUtilityClasses$t(ownerState);
34305
+ const classes = useUtilityClasses$v(ownerState);
34226
34306
  const handleRef = useForkRef(listItemRef, ref);
34227
34307
  const Root = slots.root || components.Root || ListItemRoot;
34228
34308
  const rootProps = slotProps.root || componentsProps.root || {};
@@ -34451,8 +34531,8 @@ function getListItemTextUtilityClass(slot) {
34451
34531
  }
34452
34532
  const listItemTextClasses = generateUtilityClasses$1('MuiListItemText', ['root', 'multiline', 'dense', 'inset', 'primary', 'secondary']);
34453
34533
 
34454
- const _excluded$D = ["children", "className", "disableTypography", "inset", "primary", "primaryTypographyProps", "secondary", "secondaryTypographyProps"];
34455
- const useUtilityClasses$s = ownerState => {
34534
+ const _excluded$F = ["children", "className", "disableTypography", "inset", "primary", "primaryTypographyProps", "secondary", "secondaryTypographyProps"];
34535
+ const useUtilityClasses$u = ownerState => {
34456
34536
  const {
34457
34537
  classes,
34458
34538
  inset,
@@ -34508,7 +34588,7 @@ const ListItemText = /*#__PURE__*/React__namespace.forwardRef(function ListItemT
34508
34588
  secondary: secondaryProp,
34509
34589
  secondaryTypographyProps
34510
34590
  } = props,
34511
- other = _objectWithoutPropertiesLoose(props, _excluded$D);
34591
+ other = _objectWithoutPropertiesLoose(props, _excluded$F);
34512
34592
  const {
34513
34593
  dense
34514
34594
  } = React__namespace.useContext(ListContext);
@@ -34521,7 +34601,7 @@ const ListItemText = /*#__PURE__*/React__namespace.forwardRef(function ListItemT
34521
34601
  secondary: !!secondary,
34522
34602
  dense
34523
34603
  });
34524
- const classes = useUtilityClasses$s(ownerState);
34604
+ const classes = useUtilityClasses$u(ownerState);
34525
34605
  if (primary != null && primary.type !== Typography && !disableTypography) {
34526
34606
  primary = /*#__PURE__*/jsxRuntimeExports.jsx(Typography, _extends$1({
34527
34607
  variant: dense ? 'body2' : 'body1',
@@ -34610,14 +34690,14 @@ function getMenuItemUtilityClass(slot) {
34610
34690
  }
34611
34691
  const menuItemClasses = generateUtilityClasses$1('MuiMenuItem', ['root', 'focusVisible', 'dense', 'disabled', 'divider', 'gutters', 'selected']);
34612
34692
 
34613
- const _excluded$C = ["autoFocus", "component", "dense", "divider", "disableGutters", "focusVisibleClassName", "role", "tabIndex", "className"];
34693
+ const _excluded$E = ["autoFocus", "component", "dense", "divider", "disableGutters", "focusVisibleClassName", "role", "tabIndex", "className"];
34614
34694
  const overridesResolver$1 = (props, styles) => {
34615
34695
  const {
34616
34696
  ownerState
34617
34697
  } = props;
34618
34698
  return [styles.root, ownerState.dense && styles.dense, ownerState.divider && styles.divider, !ownerState.disableGutters && styles.gutters];
34619
34699
  };
34620
- const useUtilityClasses$r = ownerState => {
34700
+ const useUtilityClasses$t = ownerState => {
34621
34701
  const {
34622
34702
  disabled,
34623
34703
  dense,
@@ -34732,7 +34812,7 @@ const MenuItem = /*#__PURE__*/React__namespace.forwardRef(function MenuItem(inPr
34732
34812
  tabIndex: tabIndexProp,
34733
34813
  className
34734
34814
  } = props,
34735
- other = _objectWithoutPropertiesLoose(props, _excluded$C);
34815
+ other = _objectWithoutPropertiesLoose(props, _excluded$E);
34736
34816
  const context = React__namespace.useContext(ListContext);
34737
34817
  const childContext = React__namespace.useMemo(() => ({
34738
34818
  dense: dense || context.dense || false,
@@ -34753,7 +34833,7 @@ const MenuItem = /*#__PURE__*/React__namespace.forwardRef(function MenuItem(inPr
34753
34833
  divider,
34754
34834
  disableGutters
34755
34835
  });
34756
- const classes = useUtilityClasses$r(props);
34836
+ const classes = useUtilityClasses$t(props);
34757
34837
  const handleRef = useForkRef(menuItemRef, ref);
34758
34838
  let tabIndex;
34759
34839
  if (!props.disabled) {
@@ -34850,6 +34930,404 @@ process.env.NODE_ENV !== "production" ? MenuItem.propTypes /* remove-proptypes *
34850
34930
  tabIndex: PropTypes.number
34851
34931
  } : void 0;
34852
34932
 
34933
+ var RadioButtonUncheckedIcon = createSvgIcon$1( /*#__PURE__*/jsxRuntimeExports.jsx("path", {
34934
+ d: "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"
34935
+ }), 'RadioButtonUnchecked');
34936
+
34937
+ var RadioButtonCheckedIcon = createSvgIcon$1( /*#__PURE__*/jsxRuntimeExports.jsx("path", {
34938
+ d: "M8.465 8.465C9.37 7.56 10.62 7 12 7C14.76 7 17 9.24 17 12C17 13.38 16.44 14.63 15.535 15.535C14.63 16.44 13.38 17 12 17C9.24 17 7 14.76 7 12C7 10.62 7.56 9.37 8.465 8.465Z"
34939
+ }), 'RadioButtonChecked');
34940
+
34941
+ const RadioButtonIconRoot = styled$1('span', {
34942
+ shouldForwardProp: rootShouldForwardProp
34943
+ })({
34944
+ position: 'relative',
34945
+ display: 'flex'
34946
+ });
34947
+ const RadioButtonIconBackground = styled$1(RadioButtonUncheckedIcon)({
34948
+ // Scale applied to prevent dot misalignment in Safari
34949
+ transform: 'scale(1)'
34950
+ });
34951
+ const RadioButtonIconDot = styled$1(RadioButtonCheckedIcon)(({
34952
+ theme,
34953
+ ownerState
34954
+ }) => _extends$1({
34955
+ left: 0,
34956
+ position: 'absolute',
34957
+ transform: 'scale(0)',
34958
+ transition: theme.transitions.create('transform', {
34959
+ easing: theme.transitions.easing.easeIn,
34960
+ duration: theme.transitions.duration.shortest
34961
+ })
34962
+ }, ownerState.checked && {
34963
+ transform: 'scale(1)',
34964
+ transition: theme.transitions.create('transform', {
34965
+ easing: theme.transitions.easing.easeOut,
34966
+ duration: theme.transitions.duration.shortest
34967
+ })
34968
+ }));
34969
+
34970
+ /**
34971
+ * @ignore - internal component.
34972
+ */
34973
+ function RadioButtonIcon(props) {
34974
+ const {
34975
+ checked = false,
34976
+ classes = {},
34977
+ fontSize
34978
+ } = props;
34979
+ const ownerState = _extends$1({}, props, {
34980
+ checked
34981
+ });
34982
+ return /*#__PURE__*/jsxRuntimeExports.jsxs(RadioButtonIconRoot, {
34983
+ className: classes.root,
34984
+ ownerState: ownerState,
34985
+ children: [/*#__PURE__*/jsxRuntimeExports.jsx(RadioButtonIconBackground, {
34986
+ fontSize: fontSize,
34987
+ className: classes.background,
34988
+ ownerState: ownerState
34989
+ }), /*#__PURE__*/jsxRuntimeExports.jsx(RadioButtonIconDot, {
34990
+ fontSize: fontSize,
34991
+ className: classes.dot,
34992
+ ownerState: ownerState
34993
+ })]
34994
+ });
34995
+ }
34996
+ process.env.NODE_ENV !== "production" ? RadioButtonIcon.propTypes = {
34997
+ /**
34998
+ * If `true`, the component is checked.
34999
+ */
35000
+ checked: PropTypes.bool,
35001
+ /**
35002
+ * Override or extend the styles applied to the component.
35003
+ */
35004
+ classes: PropTypes.object,
35005
+ /**
35006
+ * The size of the component.
35007
+ * `small` is equivalent to the dense radio styling.
35008
+ */
35009
+ fontSize: PropTypes.oneOf(['small', 'medium'])
35010
+ } : void 0;
35011
+
35012
+ /**
35013
+ * @ignore - internal component.
35014
+ */
35015
+ const RadioGroupContext = /*#__PURE__*/React__namespace.createContext(undefined);
35016
+ if (process.env.NODE_ENV !== 'production') {
35017
+ RadioGroupContext.displayName = 'RadioGroupContext';
35018
+ }
35019
+
35020
+ function useRadioGroup() {
35021
+ return React__namespace.useContext(RadioGroupContext);
35022
+ }
35023
+
35024
+ function getRadioUtilityClass(slot) {
35025
+ return generateUtilityClass$1('MuiRadio', slot);
35026
+ }
35027
+ const radioClasses = generateUtilityClasses$1('MuiRadio', ['root', 'checked', 'disabled', 'colorPrimary', 'colorSecondary', 'sizeSmall']);
35028
+
35029
+ const _excluded$D = ["checked", "checkedIcon", "color", "icon", "name", "onChange", "size", "className"];
35030
+ const useUtilityClasses$s = ownerState => {
35031
+ const {
35032
+ classes,
35033
+ color,
35034
+ size
35035
+ } = ownerState;
35036
+ const slots = {
35037
+ root: ['root', `color${capitalize$1(color)}`, size !== 'medium' && `size${capitalize$1(size)}`]
35038
+ };
35039
+ return _extends$1({}, classes, composeClasses(slots, getRadioUtilityClass, classes));
35040
+ };
35041
+ const RadioRoot = styled$1(SwitchBase, {
35042
+ shouldForwardProp: prop => rootShouldForwardProp(prop) || prop === 'classes',
35043
+ name: 'MuiRadio',
35044
+ slot: 'Root',
35045
+ overridesResolver: (props, styles) => {
35046
+ const {
35047
+ ownerState
35048
+ } = props;
35049
+ return [styles.root, ownerState.size !== 'medium' && styles[`size${capitalize$1(ownerState.size)}`], styles[`color${capitalize$1(ownerState.color)}`]];
35050
+ }
35051
+ })(({
35052
+ theme,
35053
+ ownerState
35054
+ }) => _extends$1({
35055
+ color: (theme.vars || theme).palette.text.secondary
35056
+ }, !ownerState.disableRipple && {
35057
+ '&:hover': {
35058
+ backgroundColor: theme.vars ? `rgba(${ownerState.color === 'default' ? theme.vars.palette.action.activeChannel : theme.vars.palette[ownerState.color].mainChannel} / ${theme.vars.palette.action.hoverOpacity})` : alpha_1(ownerState.color === 'default' ? theme.palette.action.active : theme.palette[ownerState.color].main, theme.palette.action.hoverOpacity),
35059
+ // Reset on touch devices, it doesn't add specificity
35060
+ '@media (hover: none)': {
35061
+ backgroundColor: 'transparent'
35062
+ }
35063
+ }
35064
+ }, ownerState.color !== 'default' && {
35065
+ [`&.${radioClasses.checked}`]: {
35066
+ color: (theme.vars || theme).palette[ownerState.color].main
35067
+ }
35068
+ }, {
35069
+ [`&.${radioClasses.disabled}`]: {
35070
+ color: (theme.vars || theme).palette.action.disabled
35071
+ }
35072
+ }));
35073
+ function areEqualValues(a, b) {
35074
+ if (typeof b === 'object' && b !== null) {
35075
+ return a === b;
35076
+ }
35077
+
35078
+ // The value could be a number, the DOM will stringify it anyway.
35079
+ return String(a) === String(b);
35080
+ }
35081
+ const defaultCheckedIcon = /*#__PURE__*/jsxRuntimeExports.jsx(RadioButtonIcon, {
35082
+ checked: true
35083
+ });
35084
+ const defaultIcon = /*#__PURE__*/jsxRuntimeExports.jsx(RadioButtonIcon, {});
35085
+ const Radio = /*#__PURE__*/React__namespace.forwardRef(function Radio(inProps, ref) {
35086
+ var _defaultIcon$props$fo, _defaultCheckedIcon$p;
35087
+ const props = useThemeProps$1({
35088
+ props: inProps,
35089
+ name: 'MuiRadio'
35090
+ });
35091
+ const {
35092
+ checked: checkedProp,
35093
+ checkedIcon = defaultCheckedIcon,
35094
+ color = 'primary',
35095
+ icon = defaultIcon,
35096
+ name: nameProp,
35097
+ onChange: onChangeProp,
35098
+ size = 'medium',
35099
+ className
35100
+ } = props,
35101
+ other = _objectWithoutPropertiesLoose(props, _excluded$D);
35102
+ const ownerState = _extends$1({}, props, {
35103
+ color,
35104
+ size
35105
+ });
35106
+ const classes = useUtilityClasses$s(ownerState);
35107
+ const radioGroup = useRadioGroup();
35108
+ let checked = checkedProp;
35109
+ const onChange = createChainedFunction(onChangeProp, radioGroup && radioGroup.onChange);
35110
+ let name = nameProp;
35111
+ if (radioGroup) {
35112
+ if (typeof checked === 'undefined') {
35113
+ checked = areEqualValues(radioGroup.value, props.value);
35114
+ }
35115
+ if (typeof name === 'undefined') {
35116
+ name = radioGroup.name;
35117
+ }
35118
+ }
35119
+ return /*#__PURE__*/jsxRuntimeExports.jsx(RadioRoot, _extends$1({
35120
+ type: "radio",
35121
+ icon: /*#__PURE__*/React__namespace.cloneElement(icon, {
35122
+ fontSize: (_defaultIcon$props$fo = defaultIcon.props.fontSize) != null ? _defaultIcon$props$fo : size
35123
+ }),
35124
+ checkedIcon: /*#__PURE__*/React__namespace.cloneElement(checkedIcon, {
35125
+ fontSize: (_defaultCheckedIcon$p = defaultCheckedIcon.props.fontSize) != null ? _defaultCheckedIcon$p : size
35126
+ }),
35127
+ ownerState: ownerState,
35128
+ classes: classes,
35129
+ name: name,
35130
+ checked: checked,
35131
+ onChange: onChange,
35132
+ ref: ref,
35133
+ className: clsx(classes.root, className)
35134
+ }, other));
35135
+ });
35136
+ process.env.NODE_ENV !== "production" ? Radio.propTypes /* remove-proptypes */ = {
35137
+ // ┌────────────────────────────── Warning ──────────────────────────────┐
35138
+ // │ These PropTypes are generated from the TypeScript type definitions. │
35139
+ // │ To update them, edit the d.ts file and run `pnpm proptypes`. │
35140
+ // └─────────────────────────────────────────────────────────────────────┘
35141
+ /**
35142
+ * If `true`, the component is checked.
35143
+ */
35144
+ checked: PropTypes.bool,
35145
+ /**
35146
+ * The icon to display when the component is checked.
35147
+ * @default <RadioButtonIcon checked />
35148
+ */
35149
+ checkedIcon: PropTypes.node,
35150
+ /**
35151
+ * Override or extend the styles applied to the component.
35152
+ */
35153
+ classes: PropTypes.object,
35154
+ /**
35155
+ * @ignore
35156
+ */
35157
+ className: PropTypes.string,
35158
+ /**
35159
+ * The color of the component.
35160
+ * It supports both default and custom theme colors, which can be added as shown in the
35161
+ * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).
35162
+ * @default 'primary'
35163
+ */
35164
+ color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['default', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),
35165
+ /**
35166
+ * If `true`, the component is disabled.
35167
+ */
35168
+ disabled: PropTypes.bool,
35169
+ /**
35170
+ * If `true`, the ripple effect is disabled.
35171
+ * @default false
35172
+ */
35173
+ disableRipple: PropTypes.bool,
35174
+ /**
35175
+ * The icon to display when the component is unchecked.
35176
+ * @default <RadioButtonIcon />
35177
+ */
35178
+ icon: PropTypes.node,
35179
+ /**
35180
+ * The id of the `input` element.
35181
+ */
35182
+ id: PropTypes.string,
35183
+ /**
35184
+ * [Attributes](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#Attributes) applied to the `input` element.
35185
+ */
35186
+ inputProps: PropTypes.object,
35187
+ /**
35188
+ * Pass a ref to the `input` element.
35189
+ */
35190
+ inputRef: refType,
35191
+ /**
35192
+ * Name attribute of the `input` element.
35193
+ */
35194
+ name: PropTypes.string,
35195
+ /**
35196
+ * Callback fired when the state is changed.
35197
+ *
35198
+ * @param {React.ChangeEvent<HTMLInputElement>} event The event source of the callback.
35199
+ * You can pull out the new value by accessing `event.target.value` (string).
35200
+ * You can pull out the new checked state by accessing `event.target.checked` (boolean).
35201
+ */
35202
+ onChange: PropTypes.func,
35203
+ /**
35204
+ * If `true`, the `input` element is required.
35205
+ * @default false
35206
+ */
35207
+ required: PropTypes.bool,
35208
+ /**
35209
+ * The size of the component.
35210
+ * `small` is equivalent to the dense radio styling.
35211
+ * @default 'medium'
35212
+ */
35213
+ size: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['medium', 'small']), PropTypes.string]),
35214
+ /**
35215
+ * The system prop that allows defining system overrides as well as additional CSS styles.
35216
+ */
35217
+ sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),
35218
+ /**
35219
+ * The value of the component. The DOM API casts this to a string.
35220
+ */
35221
+ value: PropTypes.any
35222
+ } : void 0;
35223
+
35224
+ function getRadioGroupUtilityClass(slot) {
35225
+ return generateUtilityClass$1('MuiRadioGroup', slot);
35226
+ }
35227
+ generateUtilityClasses$1('MuiRadioGroup', ['root', 'row', 'error']);
35228
+
35229
+ const _excluded$C = ["actions", "children", "className", "defaultValue", "name", "onChange", "value"];
35230
+ const useUtilityClasses$r = props => {
35231
+ const {
35232
+ classes,
35233
+ row,
35234
+ error
35235
+ } = props;
35236
+ const slots = {
35237
+ root: ['root', row && 'row', error && 'error']
35238
+ };
35239
+ return composeClasses(slots, getRadioGroupUtilityClass, classes);
35240
+ };
35241
+ const RadioGroup = /*#__PURE__*/React__namespace.forwardRef(function RadioGroup(props, ref) {
35242
+ const {
35243
+ // private
35244
+ // eslint-disable-next-line react/prop-types
35245
+ actions,
35246
+ children,
35247
+ className,
35248
+ defaultValue,
35249
+ name: nameProp,
35250
+ onChange,
35251
+ value: valueProp
35252
+ } = props,
35253
+ other = _objectWithoutPropertiesLoose(props, _excluded$C);
35254
+ const rootRef = React__namespace.useRef(null);
35255
+ const classes = useUtilityClasses$r(props);
35256
+ const [value, setValueState] = useControlled({
35257
+ controlled: valueProp,
35258
+ default: defaultValue,
35259
+ name: 'RadioGroup'
35260
+ });
35261
+ React__namespace.useImperativeHandle(actions, () => ({
35262
+ focus: () => {
35263
+ let input = rootRef.current.querySelector('input:not(:disabled):checked');
35264
+ if (!input) {
35265
+ input = rootRef.current.querySelector('input:not(:disabled)');
35266
+ }
35267
+ if (input) {
35268
+ input.focus();
35269
+ }
35270
+ }
35271
+ }), []);
35272
+ const handleRef = useForkRef(ref, rootRef);
35273
+ const name = useId(nameProp);
35274
+ const contextValue = React__namespace.useMemo(() => ({
35275
+ name,
35276
+ onChange(event) {
35277
+ setValueState(event.target.value);
35278
+ if (onChange) {
35279
+ onChange(event, event.target.value);
35280
+ }
35281
+ },
35282
+ value
35283
+ }), [name, onChange, setValueState, value]);
35284
+ return /*#__PURE__*/jsxRuntimeExports.jsx(RadioGroupContext.Provider, {
35285
+ value: contextValue,
35286
+ children: /*#__PURE__*/jsxRuntimeExports.jsx(FormGroup, _extends$1({
35287
+ role: "radiogroup",
35288
+ ref: handleRef,
35289
+ className: clsx(classes.root, className)
35290
+ }, other, {
35291
+ children: children
35292
+ }))
35293
+ });
35294
+ });
35295
+ process.env.NODE_ENV !== "production" ? RadioGroup.propTypes /* remove-proptypes */ = {
35296
+ // ┌────────────────────────────── Warning ──────────────────────────────┐
35297
+ // │ These PropTypes are generated from the TypeScript type definitions. │
35298
+ // │ To update them, edit the d.ts file and run `pnpm proptypes`. │
35299
+ // └─────────────────────────────────────────────────────────────────────┘
35300
+ /**
35301
+ * The content of the component.
35302
+ */
35303
+ children: PropTypes.node,
35304
+ /**
35305
+ * @ignore
35306
+ */
35307
+ className: PropTypes.string,
35308
+ /**
35309
+ * The default value. Use when the component is not controlled.
35310
+ */
35311
+ defaultValue: PropTypes.any,
35312
+ /**
35313
+ * The name used to reference the value of the control.
35314
+ * If you don't provide this prop, it falls back to a randomly generated name.
35315
+ */
35316
+ name: PropTypes.string,
35317
+ /**
35318
+ * Callback fired when a radio button is selected.
35319
+ *
35320
+ * @param {React.ChangeEvent<HTMLInputElement>} event The event source of the callback.
35321
+ * @param {string} value The value of the selected radio button.
35322
+ * You can pull out the new value by accessing `event.target.value` (string).
35323
+ */
35324
+ onChange: PropTypes.func,
35325
+ /**
35326
+ * Value of the selected radio button. The DOM API casts this to a string.
35327
+ */
35328
+ value: PropTypes.any
35329
+ } : void 0;
35330
+
34853
35331
  function getTooltipUtilityClass(slot) {
34854
35332
  return generateUtilityClass$1('MuiTooltip', slot);
34855
35333
  }
@@ -59246,16 +59724,21 @@ function formatDayjsToCustomTime(date) {
59246
59724
  }
59247
59725
  function TimePickerFieldWrapper({ props, }) {
59248
59726
  const value = props.getValues(props.item.name);
59249
- return (jsxRuntimeExports.jsxs(LocalizationProvider, Object.assign({ dateAdapter: AdapterDayjs }, { children: [jsxRuntimeExports.jsx(Controller, { name: "time", control: props.control, render: ({ field }) => (jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [" ", renderLabel(props.variant, props), jsxRuntimeExports.jsx(TimePicker, Object.assign({}, field, { value: value ? parseCustomTime(value) : null, onChange: (newTime) => {
59727
+ return (jsxRuntimeExports.jsxs(LocalizationProvider, Object.assign({ dateAdapter: AdapterDayjs }, { children: [jsxRuntimeExports.jsx(Controller, { name: "time", control: props.control, render: ({ field }) => (jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [" ", renderLabel(props.variant, props), jsxRuntimeExports.jsx(TimePicker
59728
+ // ampm={false}
59729
+ , Object.assign({}, field, { value: value ? parseCustomTime(value) : null, onChange: (newTime) => {
59250
59730
  const parsedTime = parseCustomTime(formatDayjsToCustomTime(newTime));
59251
- const min = props.item.minTime ? parseCustomTime(props.item.minTime) : null;
59252
- const max = props.item.maxTime ? parseCustomTime(props.item.maxTime) : null;
59731
+ const min = props.item.minTime
59732
+ ? parseCustomTime(props.item.minTime)
59733
+ : null;
59734
+ const max = props.item.maxTime
59735
+ ? parseCustomTime(props.item.maxTime)
59736
+ : null;
59253
59737
  let finalTime = parsedTime;
59254
- // Auto-correct if value is outside bounds
59255
- if (min && parsedTime.isBefore(min)) {
59738
+ if (min && (parsedTime === null || parsedTime === void 0 ? void 0 : parsedTime.isBefore(min))) {
59256
59739
  finalTime = min;
59257
59740
  }
59258
- else if (max && parsedTime.isAfter(max)) {
59741
+ else if (max && (parsedTime === null || parsedTime === void 0 ? void 0 : parsedTime.isAfter(max))) {
59259
59742
  finalTime = max;
59260
59743
  }
59261
59744
  const formatted = formatDayjsToCustomTime(finalTime);
@@ -59368,7 +59851,7 @@ function formatDateMonthAndYear(date) {
59368
59851
  }
59369
59852
  const renderLabel = (variant, props) => variant === "standard" && (jsxRuntimeExports.jsxs("span", Object.assign({ className: "formInputlabel", style: { fontSize: "12px" } }, { children: [props.item.label, " ", props.item.required && jsxRuntimeExports.jsx("span", Object.assign({ style: { color: "red" } }, { children: "*" }))] })));
59370
59853
  const RenderForm = (props) => {
59371
- var _a, _b, _c;
59854
+ var _a, _b;
59372
59855
  const variant = props.variant || "";
59373
59856
  switch ((_a = props.item) === null || _a === void 0 ? void 0 : _a.inputType) {
59374
59857
  case "text":
@@ -59666,22 +60149,31 @@ const RenderForm = (props) => {
59666
60149
  // />
59667
60150
  // </>
59668
60151
  // );
59669
- case "checkbox-group":
59670
- return (jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [renderLabel(variant, props), jsxRuntimeExports.jsx(FormControl, Object.assign({ component: "fieldset" }, { children: jsxRuntimeExports.jsx(FormGroup, Object.assign({ row: true }, { children: ((_c = props.item) === null || _c === void 0 ? void 0 : _c.settings) &&
59671
- props.item.settings.map((settings, i) => {
59672
- return (jsxRuntimeExports.jsx(Controller, { name: settings.name, control: props.control, render: ({ field }) => {
59673
- return (jsxRuntimeExports.jsx(FormControlLabel, { control: jsxRuntimeExports.jsx(Checkbox, Object.assign({}, field, { checked: field.value })), sx: {
59674
- ".MuiCheckbox-root": {
59675
- padding: "6px 2px 6px 8px",
59676
- ".css-imrjgg-MuiButtonBase-root-MuiCheckbox-root": {
59677
- color: "rgb(0, 0, 0) !important",
59678
- },
59679
- },
59680
- },
59681
- // label={settings.label}
59682
- label: jsxRuntimeExports.jsx(Typography, Object.assign({ variant: "subtitle2", fontSize: "11px", fontWeight: "normal !important" }, { children: settings.label })), labelPlacement: "end" }));
59683
- } }, i));
59684
- }) })) })), jsxRuntimeExports.jsx(ErrorMessageComponent, { children: jsxRuntimeExports.jsx(s, { errors: props.errors, name: props.item.name }) })] }));
60152
+ case "radio-group":
60153
+ return (jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [renderLabel(variant, props), jsxRuntimeExports.jsx(FormControl, Object.assign({ component: "fieldset" }, { children: jsxRuntimeExports.jsx(Controller, { name: props.item.name, control: props.control, render: ({ field }) => {
60154
+ var _a, _b;
60155
+ return (jsxRuntimeExports.jsx(RadioGroup, Object.assign({ value: field.value, onChange: (e) => {
60156
+ field.onChange(e.target.value); // update form state
60157
+ console.log(e.target.value, "radio value selected");
60158
+ props.item.onChangeFn &&
60159
+ props.item.onChangeFn(e.target.value); // optional handler
60160
+ }, row: true, sx: {
60161
+ gap: "8px",
60162
+ } }, { children: (_b = (_a = props.item) === null || _a === void 0 ? void 0 : _a.settings) === null || _b === void 0 ? void 0 : _b.map((option, i) => (jsxRuntimeExports.jsx(FormControlLabel, { value: option.name, control: jsxRuntimeExports.jsx(Radio, { sx: {
60163
+ padding: "6px 2px 6px 8px",
60164
+ color: "black",
60165
+ "&.Mui-checked": {
60166
+ color: "#1976d2", // blue when selected
60167
+ },
60168
+ "& .MuiSvgIcon-root": {
60169
+ fontSize: 16, // 🔹 this actually controls the radio icon size
60170
+ },
60171
+ } }), label: jsxRuntimeExports.jsx(Typography
60172
+ // variant="subtitle2"
60173
+ , Object.assign({
60174
+ // variant="subtitle2"
60175
+ fontSize: "11px", fontWeight: "normal !important" }, { children: option.label })) }, i))) })));
60176
+ } }) })), jsxRuntimeExports.jsx(ErrorMessageComponent, { children: jsxRuntimeExports.jsx(s, { errors: props.errors, name: props.item.name }) })] }));
59685
60177
  // case "radio":
59686
60178
  // return (
59687
60179
  // <>
@@ -62409,6 +62901,7 @@ const useFormValidatingContext = (formArray) => {
62409
62901
  renderCustomError(field);
62410
62902
  break;
62411
62903
  case "checkbox-group":
62904
+ case "radio-group":
62412
62905
  initialValues[field.name] = "";
62413
62906
  if (field.required && field.errorMessage) {
62414
62907
  validationShape[field.name] = create$6()
@@ -62780,4 +63273,5 @@ exports.useTheme = useTheme$2;
62780
63273
  exports.useThemeProps = useThemeProps$1;
62781
63274
  exports.withStyles = withStyles;
62782
63275
  exports.withTheme = withTheme;
63276
+ exports.yupResolverTP = o;
62783
63277
  //# sourceMappingURL=index.js.map