@rjsf/utils 6.8.0 → 6.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +509 -419
- package/dist/index.cjs.map +4 -4
- package/dist/utils.esm.js +508 -418
- package/dist/utils.esm.js.map +4 -4
- package/dist/utils.umd.js +567 -327
- package/lib/ErrorSchemaBuilder.d.ts +8 -7
- package/lib/ErrorSchemaBuilder.d.ts.map +1 -0
- package/lib/ErrorSchemaBuilder.js +29 -27
- package/lib/ErrorSchemaBuilder.js.map +1 -1
- package/lib/SelectedOptionDescription.d.ts +2 -1
- package/lib/SelectedOptionDescription.d.ts.map +1 -0
- package/lib/SelectedOptionDescription.js +6 -7
- package/lib/SelectedOptionDescription.js.map +1 -1
- package/lib/allowAdditionalItems.d.ts +2 -1
- package/lib/allowAdditionalItems.d.ts.map +1 -0
- package/lib/allowAdditionalItems.js +1 -1
- package/lib/allowAdditionalItems.js.map +1 -1
- package/lib/asNumber.d.ts +1 -0
- package/lib/asNumber.d.ts.map +1 -0
- package/lib/asNumber.js +1 -1
- package/lib/asNumber.js.map +1 -1
- package/lib/canExpand.d.ts +2 -1
- package/lib/canExpand.d.ts.map +1 -0
- package/lib/canExpand.js +1 -1
- package/lib/canExpand.js.map +1 -1
- package/lib/constIsAjvDataReference.d.ts +2 -1
- package/lib/constIsAjvDataReference.d.ts.map +1 -0
- package/lib/constIsAjvDataReference.js +2 -3
- package/lib/constIsAjvDataReference.js.map +1 -1
- package/lib/constants.d.ts +1 -0
- package/lib/constants.d.ts.map +1 -0
- package/lib/createErrorHandler.d.ts +2 -1
- package/lib/createErrorHandler.d.ts.map +1 -0
- package/lib/createErrorHandler.js +3 -4
- package/lib/createErrorHandler.js.map +1 -1
- package/lib/createSchemaUtils.d.ts +2 -1
- package/lib/createSchemaUtils.d.ts.map +1 -0
- package/lib/createSchemaUtils.js +10 -7
- package/lib/createSchemaUtils.js.map +1 -1
- package/lib/dataURItoBlob.d.ts +1 -0
- package/lib/dataURItoBlob.d.ts.map +1 -0
- package/lib/dataURItoBlob.js +1 -2
- package/lib/dataURItoBlob.js.map +1 -1
- package/lib/dateRangeOptions.d.ts +2 -1
- package/lib/dateRangeOptions.d.ts.map +1 -0
- package/lib/dateRangeOptions.js +1 -1
- package/lib/dateRangeOptions.js.map +1 -1
- package/lib/deepEquals.d.ts +1 -0
- package/lib/deepEquals.d.ts.map +1 -0
- package/lib/englishStringTranslator.d.ts +2 -1
- package/lib/englishStringTranslator.d.ts.map +1 -0
- package/lib/englishStringTranslator.js +1 -1
- package/lib/englishStringTranslator.js.map +1 -1
- package/lib/enumOptionSelectedValue.d.ts +2 -1
- package/lib/enumOptionSelectedValue.d.ts.map +1 -0
- package/lib/enumOptionSelectedValue.js +1 -1
- package/lib/enumOptionSelectedValue.js.map +1 -1
- package/lib/enumOptionValueDecoder.d.ts +2 -1
- package/lib/enumOptionValueDecoder.d.ts.map +1 -0
- package/lib/enumOptionValueDecoder.js +1 -1
- package/lib/enumOptionValueDecoder.js.map +1 -1
- package/lib/enumOptionValueEncoder.d.ts +2 -1
- package/lib/enumOptionValueEncoder.d.ts.map +1 -0
- package/lib/enumOptionValueEncoder.js +1 -2
- package/lib/enumOptionValueEncoder.js.map +1 -1
- package/lib/enumOptionsDeselectValue.d.ts +2 -1
- package/lib/enumOptionsDeselectValue.d.ts.map +1 -0
- package/lib/enumOptionsDeselectValue.js +2 -2
- package/lib/enumOptionsDeselectValue.js.map +1 -1
- package/lib/enumOptionsIndexForValue.d.ts +2 -1
- package/lib/enumOptionsIndexForValue.d.ts.map +1 -0
- package/lib/enumOptionsIndexForValue.js +1 -1
- package/lib/enumOptionsIndexForValue.js.map +1 -1
- package/lib/enumOptionsIsSelected.d.ts +2 -1
- package/lib/enumOptionsIsSelected.d.ts.map +1 -0
- package/lib/enumOptionsIsSelected.js +1 -1
- package/lib/enumOptionsIsSelected.js.map +1 -1
- package/lib/enumOptionsSelectValue.d.ts +2 -1
- package/lib/enumOptionsSelectValue.d.ts.map +1 -0
- package/lib/enumOptionsSelectValue.js +2 -3
- package/lib/enumOptionsSelectValue.js.map +1 -1
- package/lib/enumOptionsValueForIndex.d.ts +2 -1
- package/lib/enumOptionsValueForIndex.d.ts.map +1 -0
- package/lib/enums.d.ts +1 -0
- package/lib/enums.d.ts.map +1 -0
- package/lib/findSchemaDefinition.d.ts +2 -1
- package/lib/findSchemaDefinition.d.ts.map +1 -0
- package/lib/findSchemaDefinition.js +7 -11
- package/lib/findSchemaDefinition.js.map +1 -1
- package/lib/getChangedFields.d.ts +11 -2
- package/lib/getChangedFields.d.ts.map +1 -0
- package/lib/getChangedFields.js +57 -18
- package/lib/getChangedFields.js.map +1 -1
- package/lib/getDateElementProps.d.ts +2 -1
- package/lib/getDateElementProps.d.ts.map +1 -0
- package/lib/getDecimalSeparator.d.ts +1 -0
- package/lib/getDecimalSeparator.d.ts.map +1 -0
- package/lib/getDecimalSeparator.js +1 -2
- package/lib/getDecimalSeparator.js.map +1 -1
- package/lib/getDiscriminatorFieldFromSchema.d.ts +2 -1
- package/lib/getDiscriminatorFieldFromSchema.d.ts.map +1 -0
- package/lib/getDiscriminatorFieldFromSchema.js +4 -5
- package/lib/getDiscriminatorFieldFromSchema.js.map +1 -1
- package/lib/getInputProps.d.ts +2 -1
- package/lib/getInputProps.d.ts.map +1 -0
- package/lib/getInputProps.js +4 -1
- package/lib/getInputProps.js.map +1 -1
- package/lib/getOptionMatchingSimpleDiscriminator.d.ts +2 -1
- package/lib/getOptionMatchingSimpleDiscriminator.d.ts.map +1 -0
- package/lib/getOptionMatchingSimpleDiscriminator.js +6 -6
- package/lib/getOptionMatchingSimpleDiscriminator.js.map +1 -1
- package/lib/getOptionValueFormat.d.ts +2 -1
- package/lib/getOptionValueFormat.d.ts.map +1 -0
- package/lib/getOptionValueFormat.js +1 -2
- package/lib/getOptionValueFormat.js.map +1 -1
- package/lib/getPropertySchema.d.ts +12 -0
- package/lib/getPropertySchema.d.ts.map +1 -0
- package/lib/getPropertySchema.js +14 -0
- package/lib/getPropertySchema.js.map +1 -0
- package/lib/getSchemaType.d.ts +2 -1
- package/lib/getSchemaType.d.ts.map +1 -0
- package/lib/getSchemaType.js +1 -1
- package/lib/getSchemaType.js.map +1 -1
- package/lib/getSubmitButtonOptions.d.ts +2 -1
- package/lib/getSubmitButtonOptions.d.ts.map +1 -0
- package/lib/getSubmitButtonOptions.js +3 -3
- package/lib/getSubmitButtonOptions.js.map +1 -1
- package/lib/getTemplate.d.ts +2 -1
- package/lib/getTemplate.d.ts.map +1 -0
- package/lib/getTestIds.d.ts +2 -1
- package/lib/getTestIds.d.ts.map +1 -0
- package/lib/getTestIds.js +6 -5
- package/lib/getTestIds.js.map +1 -1
- package/lib/getUiOptions.d.ts +2 -1
- package/lib/getUiOptions.d.ts.map +1 -0
- package/lib/getUiOptions.js +2 -2
- package/lib/getUiOptions.js.map +1 -1
- package/lib/getWidget.d.ts +2 -1
- package/lib/getWidget.d.ts.map +1 -0
- package/lib/getWidget.js +6 -7
- package/lib/getWidget.js.map +1 -1
- package/lib/guessType.d.ts +2 -1
- package/lib/guessType.d.ts.map +1 -0
- package/lib/hasWidget.d.ts +2 -1
- package/lib/hasWidget.d.ts.map +1 -0
- package/lib/hasWidget.js +1 -1
- package/lib/hasWidget.js.map +1 -1
- package/lib/hashForSchema.d.ts +2 -1
- package/lib/hashForSchema.d.ts.map +1 -0
- package/lib/idGenerators.d.ts +2 -1
- package/lib/idGenerators.d.ts.map +1 -0
- package/lib/idGenerators.js +2 -3
- package/lib/idGenerators.js.map +1 -1
- package/lib/index.d.ts +93 -87
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +85 -81
- package/lib/index.js.map +1 -1
- package/lib/isConstant.d.ts +2 -1
- package/lib/isConstant.d.ts.map +1 -0
- package/lib/isConstant.js +1 -1
- package/lib/isConstant.js.map +1 -1
- package/lib/isCustomWidget.d.ts +2 -1
- package/lib/isCustomWidget.d.ts.map +1 -0
- package/lib/isCustomWidget.js +1 -1
- package/lib/isCustomWidget.js.map +1 -1
- package/lib/isFixedItems.d.ts +2 -1
- package/lib/isFixedItems.d.ts.map +1 -0
- package/lib/isFixedItems.js +1 -1
- package/lib/isFixedItems.js.map +1 -1
- package/lib/isFormDataAvailable.d.ts +1 -0
- package/lib/isFormDataAvailable.d.ts.map +1 -0
- package/lib/isFormDataAvailable.js +7 -4
- package/lib/isFormDataAvailable.js.map +1 -1
- package/lib/isObject.d.ts +3 -1
- package/lib/isObject.d.ts.map +1 -0
- package/lib/isObject.js +8 -2
- package/lib/isObject.js.map +1 -1
- package/lib/isPlainObject.d.ts +9 -0
- package/lib/isPlainObject.d.ts.map +1 -0
- package/lib/isPlainObject.js +15 -0
- package/lib/isPlainObject.js.map +1 -0
- package/lib/isRootSchema.d.ts +2 -1
- package/lib/isRootSchema.d.ts.map +1 -0
- package/lib/isRootSchema.js +2 -2
- package/lib/isRootSchema.js.map +1 -1
- package/lib/jsonSchemaAugmentation.d.ts +1 -0
- package/lib/jsonSchemaAugmentation.d.ts.map +1 -0
- package/lib/labelValue.d.ts +1 -0
- package/lib/labelValue.d.ts.map +1 -0
- package/lib/localToUTC.d.ts +1 -0
- package/lib/localToUTC.d.ts.map +1 -0
- package/lib/logUnsupportedDefaultForEnum.d.ts +2 -1
- package/lib/logUnsupportedDefaultForEnum.d.ts.map +1 -0
- package/lib/logUnsupportedDefaultForEnum.js +1 -1
- package/lib/logUnsupportedDefaultForEnum.js.map +1 -1
- package/lib/lookupFromFormContext.d.ts +3 -2
- package/lib/lookupFromFormContext.d.ts.map +1 -0
- package/lib/lookupFromFormContext.js +4 -5
- package/lib/lookupFromFormContext.js.map +1 -1
- package/lib/mergeDefaultsWithFormData.d.ts +1 -0
- package/lib/mergeDefaultsWithFormData.d.ts.map +1 -0
- package/lib/mergeDefaultsWithFormData.js +20 -16
- package/lib/mergeDefaultsWithFormData.js.map +1 -1
- package/lib/mergeObjects.d.ts +2 -1
- package/lib/mergeObjects.d.ts.map +1 -0
- package/lib/mergeObjects.js +1 -1
- package/lib/mergeObjects.js.map +1 -1
- package/lib/mergeSchemas.d.ts +2 -1
- package/lib/mergeSchemas.d.ts.map +1 -0
- package/lib/mergeSchemas.js +4 -5
- package/lib/mergeSchemas.js.map +1 -1
- package/lib/nameGenerators.d.ts +2 -1
- package/lib/nameGenerators.d.ts.map +1 -0
- package/lib/noop.d.ts +5 -0
- package/lib/noop.d.ts.map +1 -0
- package/lib/noop.js +5 -0
- package/lib/noop.js.map +1 -0
- package/lib/optionsList.d.ts +2 -1
- package/lib/optionsList.d.ts.map +1 -0
- package/lib/optionsList.js +15 -15
- package/lib/optionsList.js.map +1 -1
- package/lib/orderProperties.d.ts +1 -0
- package/lib/orderProperties.d.ts.map +1 -0
- package/lib/pad.d.ts +1 -0
- package/lib/pad.d.ts.map +1 -0
- package/lib/parseDateString.d.ts +2 -1
- package/lib/parseDateString.d.ts.map +1 -0
- package/lib/parser/ParserValidator.d.ts +2 -1
- package/lib/parser/ParserValidator.d.ts.map +1 -0
- package/lib/parser/ParserValidator.js +8 -7
- package/lib/parser/ParserValidator.js.map +1 -1
- package/lib/parser/index.d.ts +3 -2
- package/lib/parser/index.d.ts.map +1 -0
- package/lib/parser/index.js +1 -1
- package/lib/parser/index.js.map +1 -1
- package/lib/parser/schemaParser.d.ts +3 -2
- package/lib/parser/schemaParser.d.ts.map +1 -0
- package/lib/parser/schemaParser.js +6 -7
- package/lib/parser/schemaParser.js.map +1 -1
- package/lib/pathUtils.d.ts +77 -0
- package/lib/pathUtils.d.ts.map +1 -0
- package/lib/pathUtils.js +192 -0
- package/lib/pathUtils.js.map +1 -0
- package/lib/rangeSpec.d.ts +2 -1
- package/lib/rangeSpec.d.ts.map +1 -0
- package/lib/removeOptionalEmptyObjects.d.ts +2 -1
- package/lib/removeOptionalEmptyObjects.d.ts.map +1 -0
- package/lib/removeOptionalEmptyObjects.js +2 -2
- package/lib/removeOptionalEmptyObjects.js.map +1 -1
- package/lib/replaceStringParameters.d.ts +1 -0
- package/lib/replaceStringParameters.d.ts.map +1 -0
- package/lib/resolveUiSchema.d.ts +2 -1
- package/lib/resolveUiSchema.d.ts.map +1 -0
- package/lib/resolveUiSchema.js +6 -8
- package/lib/resolveUiSchema.js.map +1 -1
- package/lib/schema/findFieldInSchema.d.ts +2 -1
- package/lib/schema/findFieldInSchema.d.ts.map +1 -0
- package/lib/schema/findFieldInSchema.js +10 -11
- package/lib/schema/findFieldInSchema.js.map +1 -1
- package/lib/schema/findSelectedOptionInXxxOf.d.ts +2 -1
- package/lib/schema/findSelectedOptionInXxxOf.d.ts.map +1 -0
- package/lib/schema/findSelectedOptionInXxxOf.js +7 -7
- package/lib/schema/findSelectedOptionInXxxOf.js.map +1 -1
- package/lib/schema/getClosestMatchingOption.d.ts +2 -1
- package/lib/schema/getClosestMatchingOption.d.ts.map +1 -0
- package/lib/schema/getClosestMatchingOption.js +18 -23
- package/lib/schema/getClosestMatchingOption.js.map +1 -1
- package/lib/schema/getDefaultFormState.d.ts +2 -1
- package/lib/schema/getDefaultFormState.d.ts.map +1 -0
- package/lib/schema/getDefaultFormState.js +78 -56
- package/lib/schema/getDefaultFormState.js.map +1 -1
- package/lib/schema/getDisplayLabel.d.ts +2 -1
- package/lib/schema/getDisplayLabel.d.ts.map +1 -0
- package/lib/schema/getDisplayLabel.js +7 -7
- package/lib/schema/getDisplayLabel.js.map +1 -1
- package/lib/schema/getFirstMatchingOption.d.ts +2 -1
- package/lib/schema/getFirstMatchingOption.d.ts.map +1 -0
- package/lib/schema/getFirstMatchingOption.js +9 -9
- package/lib/schema/getFirstMatchingOption.js.map +1 -1
- package/lib/schema/getFromSchema.d.ts +3 -2
- package/lib/schema/getFromSchema.d.ts.map +1 -0
- package/lib/schema/getFromSchema.js +10 -11
- package/lib/schema/getFromSchema.js.map +1 -1
- package/lib/schema/index.d.ts +15 -14
- package/lib/schema/index.d.ts.map +1 -0
- package/lib/schema/index.js +14 -14
- package/lib/schema/index.js.map +1 -1
- package/lib/schema/isFilesArray.d.ts +2 -1
- package/lib/schema/isFilesArray.d.ts.map +1 -0
- package/lib/schema/isFilesArray.js +2 -2
- package/lib/schema/isFilesArray.js.map +1 -1
- package/lib/schema/isMultiSelect.d.ts +2 -1
- package/lib/schema/isMultiSelect.d.ts.map +1 -0
- package/lib/schema/isMultiSelect.js +1 -1
- package/lib/schema/isMultiSelect.js.map +1 -1
- package/lib/schema/isSelect.d.ts +2 -1
- package/lib/schema/isSelect.d.ts.map +1 -0
- package/lib/schema/isSelect.js +2 -2
- package/lib/schema/isSelect.js.map +1 -1
- package/lib/schema/omitExtraData.d.ts +2 -1
- package/lib/schema/omitExtraData.d.ts.map +1 -0
- package/lib/schema/omitExtraData.js +100 -64
- package/lib/schema/omitExtraData.js.map +1 -1
- package/lib/schema/retrieveSchema.d.ts +2 -1
- package/lib/schema/retrieveSchema.d.ts.map +1 -0
- package/lib/schema/retrieveSchema.js +32 -40
- package/lib/schema/retrieveSchema.js.map +1 -1
- package/lib/schema/sanitizeDataForNewSchema.d.ts +4 -3
- package/lib/schema/sanitizeDataForNewSchema.d.ts.map +1 -0
- package/lib/schema/sanitizeDataForNewSchema.js +41 -39
- package/lib/schema/sanitizeDataForNewSchema.js.map +1 -1
- package/lib/schema/shallowAllOfMerge.d.ts +1 -0
- package/lib/schema/shallowAllOfMerge.d.ts.map +1 -0
- package/lib/schema/toPathSchema.d.ts +2 -1
- package/lib/schema/toPathSchema.d.ts.map +1 -0
- package/lib/schema/toPathSchema.js +14 -14
- package/lib/schema/toPathSchema.js.map +1 -1
- package/lib/schemaRequiresTrueValue.d.ts +2 -1
- package/lib/schemaRequiresTrueValue.d.ts.map +1 -0
- package/lib/schemaRequiresTrueValue.js +3 -4
- package/lib/schemaRequiresTrueValue.js.map +1 -1
- package/lib/shallowEquals.d.ts +1 -0
- package/lib/shallowEquals.d.ts.map +1 -0
- package/lib/shouldRender.d.ts +2 -1
- package/lib/shouldRender.d.ts.map +1 -0
- package/lib/shouldRender.js +2 -2
- package/lib/shouldRender.js.map +1 -1
- package/lib/shouldRenderOptionalField.d.ts +2 -1
- package/lib/shouldRenderOptionalField.d.ts.map +1 -0
- package/lib/shouldRenderOptionalField.js +11 -10
- package/lib/shouldRenderOptionalField.js.map +1 -1
- package/lib/toConstant.d.ts +2 -1
- package/lib/toConstant.d.ts.map +1 -0
- package/lib/toConstant.js +1 -1
- package/lib/toConstant.js.map +1 -1
- package/lib/toDateString.d.ts +2 -1
- package/lib/toDateString.d.ts.map +1 -0
- package/lib/toErrorList.d.ts +2 -1
- package/lib/toErrorList.d.ts.map +1 -0
- package/lib/toErrorList.js +20 -21
- package/lib/toErrorList.js.map +1 -1
- package/lib/toErrorSchema.d.ts +2 -1
- package/lib/toErrorSchema.d.ts.map +1 -0
- package/lib/toErrorSchema.js +4 -9
- package/lib/toErrorSchema.js.map +1 -1
- package/lib/toFieldPathId.d.ts +2 -1
- package/lib/toFieldPathId.d.ts.map +1 -0
- package/lib/toFieldPathId.js +2 -2
- package/lib/toFieldPathId.js.map +1 -1
- package/lib/types.d.ts +15 -5
- package/lib/types.d.ts.map +1 -0
- package/lib/types.js +1 -1
- package/lib/types.js.map +1 -1
- package/lib/unwrapErrorHandler.d.ts +2 -1
- package/lib/unwrapErrorHandler.d.ts.map +1 -0
- package/lib/unwrapErrorHandler.js +13 -4
- package/lib/unwrapErrorHandler.js.map +1 -1
- package/lib/useAltDateWidgetProps.d.ts +3 -2
- package/lib/useAltDateWidgetProps.d.ts.map +1 -0
- package/lib/useAltDateWidgetProps.js +5 -5
- package/lib/useAltDateWidgetProps.js.map +1 -1
- package/lib/useDeepCompareMemo.d.ts +1 -0
- package/lib/useDeepCompareMemo.d.ts.map +1 -0
- package/lib/useDeepCompareMemo.js +1 -1
- package/lib/useDeepCompareMemo.js.map +1 -1
- package/lib/useFileWidgetProps.d.ts +1 -0
- package/lib/useFileWidgetProps.d.ts.map +1 -0
- package/lib/useFileWidgetProps.js +3 -4
- package/lib/useFileWidgetProps.js.map +1 -1
- package/lib/utcToLocal.d.ts +1 -0
- package/lib/utcToLocal.d.ts.map +1 -0
- package/lib/utcToLocal.js +1 -1
- package/lib/utcToLocal.js.map +1 -1
- package/lib/validationDataMerge.d.ts +2 -1
- package/lib/validationDataMerge.d.ts.map +1 -0
- package/lib/validationDataMerge.js +3 -4
- package/lib/validationDataMerge.js.map +1 -1
- package/lib/withIdRefPrefix.d.ts +2 -1
- package/lib/withIdRefPrefix.d.ts.map +1 -0
- package/lib/withIdRefPrefix.js +2 -2
- package/lib/withIdRefPrefix.js.map +1 -1
- package/package.json +5 -6
- package/src/ErrorSchemaBuilder.ts +25 -24
- package/src/SelectedOptionDescription.tsx +5 -5
- package/src/allowAdditionalItems.ts +2 -2
- package/src/asNumber.ts +1 -1
- package/src/canExpand.ts +2 -2
- package/src/constIsAjvDataReference.ts +5 -4
- package/src/createErrorHandler.ts +5 -7
- package/src/createSchemaUtils.ts +8 -10
- package/src/dateRangeOptions.ts +2 -2
- package/src/englishStringTranslator.ts +2 -2
- package/src/enumOptionSelectedValue.ts +2 -2
- package/src/enumOptionValueDecoder.ts +2 -2
- package/src/enumOptionValueEncoder.ts +2 -4
- package/src/enumOptionsDeselectValue.ts +3 -3
- package/src/enumOptionsIndexForValue.ts +2 -2
- package/src/enumOptionsIsSelected.ts +2 -2
- package/src/enumOptionsSelectValue.ts +3 -5
- package/src/enumOptionsValueForIndex.ts +1 -1
- package/src/findSchemaDefinition.ts +8 -12
- package/src/getChangedFields.ts +57 -18
- package/src/getDateElementProps.ts +1 -1
- package/src/getDiscriminatorFieldFromSchema.ts +5 -7
- package/src/getInputProps.ts +6 -2
- package/src/getOptionMatchingSimpleDiscriminator.ts +7 -7
- package/src/getOptionValueFormat.ts +1 -1
- package/src/getPropertySchema.ts +18 -0
- package/src/getSchemaType.ts +2 -2
- package/src/getSubmitButtonOptions.ts +3 -3
- package/src/getTemplate.ts +1 -1
- package/src/getTestIds.ts +7 -6
- package/src/getUiOptions.ts +3 -3
- package/src/getWidget.tsx +6 -6
- package/src/hasWidget.ts +2 -2
- package/src/hashForSchema.ts +1 -1
- package/src/idGenerators.ts +3 -5
- package/src/index.ts +99 -85
- package/src/isConstant.ts +2 -2
- package/src/isCustomWidget.ts +2 -2
- package/src/isFixedItems.ts +2 -2
- package/src/isFormDataAvailable.ts +7 -5
- package/src/isObject.ts +15 -3
- package/src/isPlainObject.ts +14 -0
- package/src/isRootSchema.ts +3 -3
- package/src/logUnsupportedDefaultForEnum.ts +2 -2
- package/src/lookupFromFormContext.ts +7 -8
- package/src/mergeDefaultsWithFormData.ts +22 -18
- package/src/mergeObjects.ts +2 -2
- package/src/mergeSchemas.ts +5 -7
- package/src/nameGenerators.ts +1 -1
- package/src/noop.ts +4 -0
- package/src/optionsList.ts +9 -9
- package/src/orderProperties.ts +1 -1
- package/src/parseDateString.ts +1 -1
- package/src/parser/ParserValidator.ts +5 -7
- package/src/parser/index.ts +2 -2
- package/src/parser/schemaParser.ts +8 -10
- package/src/pathUtils.ts +203 -0
- package/src/rangeSpec.ts +1 -1
- package/src/removeOptionalEmptyObjects.ts +3 -3
- package/src/resolveUiSchema.ts +5 -7
- package/src/schema/findFieldInSchema.ts +11 -13
- package/src/schema/findSelectedOptionInXxxOf.ts +9 -10
- package/src/schema/getClosestMatchingOption.ts +73 -83
- package/src/schema/getDefaultFormState.ts +62 -34
- package/src/schema/getDisplayLabel.ts +7 -7
- package/src/schema/getFirstMatchingOption.ts +10 -11
- package/src/schema/getFromSchema.ts +12 -14
- package/src/schema/index.ts +14 -14
- package/src/schema/isFilesArray.ts +3 -3
- package/src/schema/isMultiSelect.ts +2 -2
- package/src/schema/isSelect.ts +3 -3
- package/src/schema/omitExtraData.ts +104 -68
- package/src/schema/retrieveSchema.ts +47 -60
- package/src/schema/sanitizeDataForNewSchema.ts +42 -41
- package/src/schema/toPathSchema.ts +14 -14
- package/src/schemaRequiresTrueValue.ts +1 -1
- package/src/shouldRender.ts +3 -3
- package/src/shouldRenderOptionalField.ts +14 -14
- package/src/toConstant.ts +2 -2
- package/src/toDateString.ts +1 -1
- package/src/toErrorList.ts +22 -25
- package/src/toErrorSchema.ts +5 -11
- package/src/toFieldPathId.ts +2 -2
- package/src/types.ts +14 -5
- package/src/unwrapErrorHandler.ts +15 -6
- package/src/useAltDateWidgetProps.tsx +7 -7
- package/src/useDeepCompareMemo.ts +1 -1
- package/src/useFileWidgetProps.ts +1 -1
- package/src/utcToLocal.ts +1 -1
- package/src/validationDataMerge.ts +4 -6
- package/src/withIdRefPrefix.ts +3 -4
- package/lib/tsconfig.tsbuildinfo +0 -1
- package/src/tsconfig.json +0 -9
package/lib/index.d.ts
CHANGED
|
@@ -1,87 +1,93 @@
|
|
|
1
|
-
import allowAdditionalItems from './allowAdditionalItems.
|
|
2
|
-
import asNumber from './asNumber.
|
|
3
|
-
import canExpand from './canExpand.
|
|
4
|
-
import createErrorHandler from './createErrorHandler.
|
|
5
|
-
import createSchemaUtils from './createSchemaUtils.
|
|
6
|
-
import dataURItoBlob from './dataURItoBlob.
|
|
7
|
-
import dateRangeOptions from './dateRangeOptions.
|
|
8
|
-
import deepEquals from './deepEquals.
|
|
9
|
-
import englishStringTranslator from './englishStringTranslator.
|
|
10
|
-
import enumOptionsDeselectValue from './enumOptionsDeselectValue.
|
|
11
|
-
import enumOptionSelectedValue from './enumOptionSelectedValue.
|
|
12
|
-
import enumOptionsIndexForValue from './enumOptionsIndexForValue.
|
|
13
|
-
import enumOptionsIsSelected from './enumOptionsIsSelected.
|
|
14
|
-
import enumOptionsSelectValue from './enumOptionsSelectValue.
|
|
15
|
-
import enumOptionsValueForIndex from './enumOptionsValueForIndex.
|
|
16
|
-
import enumOptionValueDecoder from './enumOptionValueDecoder.
|
|
17
|
-
import enumOptionValueEncoder from './enumOptionValueEncoder.
|
|
18
|
-
import ErrorSchemaBuilder from './ErrorSchemaBuilder.
|
|
19
|
-
import findSchemaDefinition from './findSchemaDefinition.
|
|
20
|
-
import getChangedFields from './getChangedFields.
|
|
21
|
-
import type { DateElementFormat, DateElementProp } from './getDateElementProps.
|
|
22
|
-
import getDateElementProps from './getDateElementProps.
|
|
23
|
-
import getDecimalSeparator from './getDecimalSeparator.
|
|
24
|
-
import getDiscriminatorFieldFromSchema from './getDiscriminatorFieldFromSchema.
|
|
25
|
-
import getInputProps from './getInputProps.
|
|
26
|
-
import getOptionMatchingSimpleDiscriminator from './getOptionMatchingSimpleDiscriminator.
|
|
27
|
-
import getOptionValueFormat from './getOptionValueFormat.
|
|
28
|
-
import
|
|
29
|
-
import
|
|
30
|
-
import
|
|
31
|
-
import
|
|
32
|
-
import
|
|
33
|
-
import
|
|
34
|
-
import
|
|
35
|
-
import
|
|
36
|
-
import
|
|
37
|
-
import
|
|
38
|
-
import
|
|
39
|
-
import
|
|
40
|
-
import
|
|
41
|
-
import
|
|
42
|
-
import
|
|
43
|
-
import
|
|
44
|
-
import
|
|
45
|
-
import
|
|
46
|
-
import
|
|
47
|
-
import
|
|
48
|
-
import
|
|
49
|
-
import
|
|
50
|
-
import
|
|
51
|
-
import
|
|
52
|
-
import
|
|
53
|
-
import
|
|
54
|
-
import
|
|
55
|
-
import
|
|
56
|
-
import
|
|
57
|
-
import
|
|
58
|
-
import
|
|
59
|
-
import
|
|
60
|
-
import
|
|
61
|
-
import
|
|
62
|
-
import
|
|
63
|
-
import
|
|
64
|
-
import
|
|
65
|
-
import
|
|
66
|
-
import
|
|
67
|
-
import
|
|
68
|
-
import
|
|
69
|
-
import
|
|
70
|
-
import
|
|
71
|
-
import
|
|
72
|
-
import
|
|
73
|
-
import
|
|
74
|
-
import
|
|
75
|
-
import
|
|
76
|
-
import
|
|
77
|
-
import
|
|
78
|
-
import
|
|
79
|
-
import
|
|
80
|
-
import
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
export type
|
|
87
|
-
export
|
|
1
|
+
import allowAdditionalItems from './allowAdditionalItems.ts';
|
|
2
|
+
import asNumber from './asNumber.ts';
|
|
3
|
+
import canExpand from './canExpand.ts';
|
|
4
|
+
import createErrorHandler from './createErrorHandler.ts';
|
|
5
|
+
import createSchemaUtils from './createSchemaUtils.ts';
|
|
6
|
+
import dataURItoBlob from './dataURItoBlob.ts';
|
|
7
|
+
import dateRangeOptions from './dateRangeOptions.ts';
|
|
8
|
+
import deepEquals from './deepEquals.ts';
|
|
9
|
+
import englishStringTranslator from './englishStringTranslator.ts';
|
|
10
|
+
import enumOptionsDeselectValue from './enumOptionsDeselectValue.ts';
|
|
11
|
+
import enumOptionSelectedValue from './enumOptionSelectedValue.ts';
|
|
12
|
+
import enumOptionsIndexForValue from './enumOptionsIndexForValue.ts';
|
|
13
|
+
import enumOptionsIsSelected from './enumOptionsIsSelected.ts';
|
|
14
|
+
import enumOptionsSelectValue from './enumOptionsSelectValue.ts';
|
|
15
|
+
import enumOptionsValueForIndex from './enumOptionsValueForIndex.ts';
|
|
16
|
+
import enumOptionValueDecoder from './enumOptionValueDecoder.ts';
|
|
17
|
+
import enumOptionValueEncoder from './enumOptionValueEncoder.ts';
|
|
18
|
+
import ErrorSchemaBuilder from './ErrorSchemaBuilder.ts';
|
|
19
|
+
import findSchemaDefinition from './findSchemaDefinition.ts';
|
|
20
|
+
import getChangedFields from './getChangedFields.ts';
|
|
21
|
+
import type { DateElementFormat, DateElementProp } from './getDateElementProps.ts';
|
|
22
|
+
import getDateElementProps from './getDateElementProps.ts';
|
|
23
|
+
import getDecimalSeparator from './getDecimalSeparator.ts';
|
|
24
|
+
import getDiscriminatorFieldFromSchema from './getDiscriminatorFieldFromSchema.ts';
|
|
25
|
+
import getInputProps from './getInputProps.ts';
|
|
26
|
+
import getOptionMatchingSimpleDiscriminator from './getOptionMatchingSimpleDiscriminator.ts';
|
|
27
|
+
import getOptionValueFormat from './getOptionValueFormat.ts';
|
|
28
|
+
import getPropertySchema from './getPropertySchema.ts';
|
|
29
|
+
import getSchemaType from './getSchemaType.ts';
|
|
30
|
+
import getSubmitButtonOptions from './getSubmitButtonOptions.ts';
|
|
31
|
+
import getTemplate from './getTemplate.ts';
|
|
32
|
+
import getTestIds from './getTestIds.ts';
|
|
33
|
+
import getUiOptions from './getUiOptions.ts';
|
|
34
|
+
import getWidget from './getWidget.tsx';
|
|
35
|
+
import guessType from './guessType.ts';
|
|
36
|
+
import hashForSchema, { hashObject, hashString, sortedJSONStringify } from './hashForSchema.ts';
|
|
37
|
+
import hasWidget from './hasWidget.ts';
|
|
38
|
+
import { ariaDescribedByIds, buttonId, descriptionId, errorId, examplesId, helpId, optionalControlsId, optionId, titleId } from './idGenerators.ts';
|
|
39
|
+
import isConstant from './isConstant.ts';
|
|
40
|
+
import isCustomWidget from './isCustomWidget.ts';
|
|
41
|
+
import isFixedItems from './isFixedItems.ts';
|
|
42
|
+
import isFormDataAvailable from './isFormDataAvailable.ts';
|
|
43
|
+
import isObject from './isObject.ts';
|
|
44
|
+
import isPlainObject from './isPlainObject.ts';
|
|
45
|
+
import isRootSchema from './isRootSchema.ts';
|
|
46
|
+
import labelValue from './labelValue.ts';
|
|
47
|
+
import localToUTC from './localToUTC.ts';
|
|
48
|
+
import logUnsupportedDefaultForEnum from './logUnsupportedDefaultForEnum.ts';
|
|
49
|
+
import lookupFromFormContext from './lookupFromFormContext.ts';
|
|
50
|
+
import mergeDefaultsWithFormData from './mergeDefaultsWithFormData.ts';
|
|
51
|
+
import mergeObjects from './mergeObjects.ts';
|
|
52
|
+
import mergeSchemas from './mergeSchemas.ts';
|
|
53
|
+
import { bracketNameGenerator, dotNotationNameGenerator } from './nameGenerators.ts';
|
|
54
|
+
import noop from './noop.ts';
|
|
55
|
+
import optionsList from './optionsList.ts';
|
|
56
|
+
import orderProperties from './orderProperties.ts';
|
|
57
|
+
import pad from './pad.ts';
|
|
58
|
+
import parseDateString from './parseDateString.ts';
|
|
59
|
+
import { getByPath, hasByPath, setByPath, toPath, unsetByPath } from './pathUtils.ts';
|
|
60
|
+
import type { ObjectPath } from './pathUtils.ts';
|
|
61
|
+
import rangeSpec from './rangeSpec.ts';
|
|
62
|
+
import removeOptionalEmptyObjects from './removeOptionalEmptyObjects.ts';
|
|
63
|
+
import replaceStringParameters from './replaceStringParameters.ts';
|
|
64
|
+
import resolveUiSchema from './resolveUiSchema.ts';
|
|
65
|
+
import schemaRequiresTrueValue from './schemaRequiresTrueValue.ts';
|
|
66
|
+
import SelectedOptionDescription from './SelectedOptionDescription.tsx';
|
|
67
|
+
import type { SelectedOptionDescriptionProps } from './SelectedOptionDescription.tsx';
|
|
68
|
+
import shallowEquals from './shallowEquals.ts';
|
|
69
|
+
import type { ComponentUpdateStrategy } from './shouldRender.ts';
|
|
70
|
+
import shouldRender from './shouldRender.ts';
|
|
71
|
+
import shouldRenderOptionalField from './shouldRenderOptionalField.ts';
|
|
72
|
+
import toConstant from './toConstant.ts';
|
|
73
|
+
import toDateString from './toDateString.ts';
|
|
74
|
+
import toErrorList from './toErrorList.ts';
|
|
75
|
+
import toErrorSchema from './toErrorSchema.ts';
|
|
76
|
+
import toFieldPathId from './toFieldPathId.ts';
|
|
77
|
+
import unwrapErrorHandler from './unwrapErrorHandler.ts';
|
|
78
|
+
import type { DateElementProps, UseAltDateWidgetResult } from './useAltDateWidgetProps.tsx';
|
|
79
|
+
import useAltDateWidgetProps, { DateElement } from './useAltDateWidgetProps.tsx';
|
|
80
|
+
import useDeepCompareMemo from './useDeepCompareMemo.ts';
|
|
81
|
+
import type { FileInfoType, UseFileWidgetPropsResult } from './useFileWidgetProps.ts';
|
|
82
|
+
import useFileWidgetProps from './useFileWidgetProps.ts';
|
|
83
|
+
import utcToLocal from './utcToLocal.ts';
|
|
84
|
+
import validationDataMerge from './validationDataMerge.ts';
|
|
85
|
+
import withIdRefPrefix from './withIdRefPrefix.ts';
|
|
86
|
+
export type * from './types.ts';
|
|
87
|
+
export * from './enums.ts';
|
|
88
|
+
export * from './constants.ts';
|
|
89
|
+
export * from './parser/index.ts';
|
|
90
|
+
export * from './schema/index.ts';
|
|
91
|
+
export type { ComponentUpdateStrategy, DateElementFormat, DateElementProp, DateElementProps, FileInfoType, ObjectPath, SelectedOptionDescriptionProps, UseAltDateWidgetResult, UseFileWidgetPropsResult, };
|
|
92
|
+
export { allowAdditionalItems, ariaDescribedByIds, asNumber, buttonId, canExpand, createErrorHandler, createSchemaUtils, DateElement, dataURItoBlob, dateRangeOptions, deepEquals, descriptionId, englishStringTranslator, enumOptionSelectedValue, enumOptionValueDecoder, enumOptionValueEncoder, enumOptionsDeselectValue, enumOptionsIndexForValue, enumOptionsIsSelected, enumOptionsSelectValue, enumOptionsValueForIndex, errorId, examplesId, ErrorSchemaBuilder, findSchemaDefinition, getChangedFields, getDateElementProps, getDecimalSeparator, getDiscriminatorFieldFromSchema, getInputProps, getOptionMatchingSimpleDiscriminator, getPropertySchema, getOptionValueFormat, getSchemaType, getByPath, getSubmitButtonOptions, getTemplate, getTestIds, getUiOptions, getWidget, guessType, hasByPath, hasWidget, hashForSchema, hashObject, hashString, helpId, isConstant, isCustomWidget, isFixedItems, isFormDataAvailable, isObject, isPlainObject, isRootSchema, labelValue, localToUTC, logUnsupportedDefaultForEnum, lookupFromFormContext, mergeDefaultsWithFormData, mergeObjects, mergeSchemas, noop, optionalControlsId, optionId, optionsList, orderProperties, pad, parseDateString, rangeSpec, removeOptionalEmptyObjects, replaceStringParameters, resolveUiSchema, schemaRequiresTrueValue, setByPath, SelectedOptionDescription, shallowEquals, shouldRender, shouldRenderOptionalField, sortedJSONStringify, titleId, toConstant, toDateString, toErrorList, toErrorSchema, toFieldPathId, toPath, unsetByPath, unwrapErrorHandler, useAltDateWidgetProps, useDeepCompareMemo, useFileWidgetProps, utcToLocal, validationDataMerge, withIdRefPrefix, bracketNameGenerator, dotNotationNameGenerator, };
|
|
93
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,oBAAoB,MAAM,2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EACH,eAAe,EACf,SAAS,EAET,0BAA0B,EAC1B,uBAAuB,EACvB,eAAe,EACf,uBAAuB,EACvB,SAAS,EACT,yBAAyB,EACzB,aAAa,EACb,YAAY,EACZ,yBAAyB,EACzB,mBAAmB,EACnB,OAAO,EACP,UAAU,EACV,YAAY,EACZ,WAAW,EACX,aAAa,EACb,aAAa,EACb,MAAM,EACN,WAAW,EACX,kBAAkB,EAClB,qBAAqB,EACrB,kBAAkB,EAClB,kBAAkB,EAClB,UAAU,EACV,mBAAmB,EACnB,eAAe,EACf,oBAAoB,EACpB,wBAAwB,GACzB,CAAC"}
|
package/lib/index.js
CHANGED
|
@@ -1,83 +1,87 @@
|
|
|
1
|
-
import allowAdditionalItems from
|
|
2
|
-
import asNumber from
|
|
3
|
-
import canExpand from
|
|
4
|
-
import createErrorHandler from
|
|
5
|
-
import createSchemaUtils from
|
|
6
|
-
import dataURItoBlob from
|
|
7
|
-
import dateRangeOptions from
|
|
8
|
-
import deepEquals from
|
|
9
|
-
import englishStringTranslator from
|
|
10
|
-
import enumOptionsDeselectValue from
|
|
11
|
-
import enumOptionSelectedValue from
|
|
12
|
-
import enumOptionsIndexForValue from
|
|
13
|
-
import enumOptionsIsSelected from
|
|
14
|
-
import enumOptionsSelectValue from
|
|
15
|
-
import enumOptionsValueForIndex from
|
|
16
|
-
import enumOptionValueDecoder from
|
|
17
|
-
import enumOptionValueEncoder from
|
|
18
|
-
import ErrorSchemaBuilder from
|
|
19
|
-
import findSchemaDefinition from
|
|
20
|
-
import getChangedFields from
|
|
21
|
-
import getDateElementProps from
|
|
22
|
-
import getDecimalSeparator from
|
|
23
|
-
import getDiscriminatorFieldFromSchema from
|
|
24
|
-
import getInputProps from
|
|
25
|
-
import getOptionMatchingSimpleDiscriminator from
|
|
26
|
-
import getOptionValueFormat from
|
|
27
|
-
import
|
|
28
|
-
import
|
|
29
|
-
import
|
|
30
|
-
import
|
|
31
|
-
import
|
|
32
|
-
import
|
|
33
|
-
import
|
|
34
|
-
import
|
|
35
|
-
import
|
|
36
|
-
import
|
|
37
|
-
import
|
|
38
|
-
import
|
|
39
|
-
import
|
|
40
|
-
import
|
|
41
|
-
import
|
|
42
|
-
import
|
|
43
|
-
import
|
|
44
|
-
import
|
|
45
|
-
import
|
|
46
|
-
import
|
|
47
|
-
import
|
|
48
|
-
import
|
|
49
|
-
import
|
|
50
|
-
import
|
|
51
|
-
import
|
|
52
|
-
import
|
|
53
|
-
import
|
|
54
|
-
import
|
|
55
|
-
import
|
|
56
|
-
import
|
|
57
|
-
import
|
|
58
|
-
import
|
|
59
|
-
import
|
|
60
|
-
import
|
|
61
|
-
import
|
|
62
|
-
import
|
|
63
|
-
import
|
|
64
|
-
import
|
|
65
|
-
import
|
|
66
|
-
import
|
|
67
|
-
import
|
|
68
|
-
import
|
|
69
|
-
import
|
|
70
|
-
import
|
|
71
|
-
import
|
|
72
|
-
import
|
|
73
|
-
import
|
|
74
|
-
import
|
|
75
|
-
import
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
export
|
|
1
|
+
import allowAdditionalItems from "./allowAdditionalItems.js";
|
|
2
|
+
import asNumber from "./asNumber.js";
|
|
3
|
+
import canExpand from "./canExpand.js";
|
|
4
|
+
import createErrorHandler from "./createErrorHandler.js";
|
|
5
|
+
import createSchemaUtils from "./createSchemaUtils.js";
|
|
6
|
+
import dataURItoBlob from "./dataURItoBlob.js";
|
|
7
|
+
import dateRangeOptions from "./dateRangeOptions.js";
|
|
8
|
+
import deepEquals from "./deepEquals.js";
|
|
9
|
+
import englishStringTranslator from "./englishStringTranslator.js";
|
|
10
|
+
import enumOptionsDeselectValue from "./enumOptionsDeselectValue.js";
|
|
11
|
+
import enumOptionSelectedValue from "./enumOptionSelectedValue.js";
|
|
12
|
+
import enumOptionsIndexForValue from "./enumOptionsIndexForValue.js";
|
|
13
|
+
import enumOptionsIsSelected from "./enumOptionsIsSelected.js";
|
|
14
|
+
import enumOptionsSelectValue from "./enumOptionsSelectValue.js";
|
|
15
|
+
import enumOptionsValueForIndex from "./enumOptionsValueForIndex.js";
|
|
16
|
+
import enumOptionValueDecoder from "./enumOptionValueDecoder.js";
|
|
17
|
+
import enumOptionValueEncoder from "./enumOptionValueEncoder.js";
|
|
18
|
+
import ErrorSchemaBuilder from "./ErrorSchemaBuilder.js";
|
|
19
|
+
import findSchemaDefinition from "./findSchemaDefinition.js";
|
|
20
|
+
import getChangedFields from "./getChangedFields.js";
|
|
21
|
+
import getDateElementProps from "./getDateElementProps.js";
|
|
22
|
+
import getDecimalSeparator from "./getDecimalSeparator.js";
|
|
23
|
+
import getDiscriminatorFieldFromSchema from "./getDiscriminatorFieldFromSchema.js";
|
|
24
|
+
import getInputProps from "./getInputProps.js";
|
|
25
|
+
import getOptionMatchingSimpleDiscriminator from "./getOptionMatchingSimpleDiscriminator.js";
|
|
26
|
+
import getOptionValueFormat from "./getOptionValueFormat.js";
|
|
27
|
+
import getPropertySchema from "./getPropertySchema.js";
|
|
28
|
+
import getSchemaType from "./getSchemaType.js";
|
|
29
|
+
import getSubmitButtonOptions from "./getSubmitButtonOptions.js";
|
|
30
|
+
import getTemplate from "./getTemplate.js";
|
|
31
|
+
import getTestIds from "./getTestIds.js";
|
|
32
|
+
import getUiOptions from "./getUiOptions.js";
|
|
33
|
+
import getWidget from "./getWidget.js";
|
|
34
|
+
import guessType from "./guessType.js";
|
|
35
|
+
import hashForSchema, { hashObject, hashString, sortedJSONStringify } from "./hashForSchema.js";
|
|
36
|
+
import hasWidget from "./hasWidget.js";
|
|
37
|
+
import { ariaDescribedByIds, buttonId, descriptionId, errorId, examplesId, helpId, optionalControlsId, optionId, titleId, } from "./idGenerators.js";
|
|
38
|
+
import isConstant from "./isConstant.js";
|
|
39
|
+
import isCustomWidget from "./isCustomWidget.js";
|
|
40
|
+
import isFixedItems from "./isFixedItems.js";
|
|
41
|
+
import isFormDataAvailable from "./isFormDataAvailable.js";
|
|
42
|
+
import isObject from "./isObject.js";
|
|
43
|
+
import isPlainObject from "./isPlainObject.js";
|
|
44
|
+
import isRootSchema from "./isRootSchema.js";
|
|
45
|
+
import labelValue from "./labelValue.js";
|
|
46
|
+
import localToUTC from "./localToUTC.js";
|
|
47
|
+
import logUnsupportedDefaultForEnum from "./logUnsupportedDefaultForEnum.js";
|
|
48
|
+
import lookupFromFormContext from "./lookupFromFormContext.js";
|
|
49
|
+
import mergeDefaultsWithFormData from "./mergeDefaultsWithFormData.js";
|
|
50
|
+
import mergeObjects from "./mergeObjects.js";
|
|
51
|
+
import mergeSchemas from "./mergeSchemas.js";
|
|
52
|
+
import { bracketNameGenerator, dotNotationNameGenerator } from "./nameGenerators.js";
|
|
53
|
+
import noop from "./noop.js";
|
|
54
|
+
import optionsList from "./optionsList.js";
|
|
55
|
+
import orderProperties from "./orderProperties.js";
|
|
56
|
+
import pad from "./pad.js";
|
|
57
|
+
import parseDateString from "./parseDateString.js";
|
|
58
|
+
import { getByPath, hasByPath, setByPath, toPath, unsetByPath } from "./pathUtils.js";
|
|
59
|
+
import rangeSpec from "./rangeSpec.js";
|
|
60
|
+
import removeOptionalEmptyObjects from "./removeOptionalEmptyObjects.js";
|
|
61
|
+
import replaceStringParameters from "./replaceStringParameters.js";
|
|
62
|
+
import resolveUiSchema from "./resolveUiSchema.js";
|
|
63
|
+
import schemaRequiresTrueValue from "./schemaRequiresTrueValue.js";
|
|
64
|
+
import SelectedOptionDescription from "./SelectedOptionDescription.js";
|
|
65
|
+
import shallowEquals from "./shallowEquals.js";
|
|
66
|
+
import shouldRender from "./shouldRender.js";
|
|
67
|
+
import shouldRenderOptionalField from "./shouldRenderOptionalField.js";
|
|
68
|
+
import toConstant from "./toConstant.js";
|
|
69
|
+
import toDateString from "./toDateString.js";
|
|
70
|
+
import toErrorList from "./toErrorList.js";
|
|
71
|
+
import toErrorSchema from "./toErrorSchema.js";
|
|
72
|
+
import toFieldPathId from "./toFieldPathId.js";
|
|
73
|
+
import unwrapErrorHandler from "./unwrapErrorHandler.js";
|
|
74
|
+
import useAltDateWidgetProps, { DateElement } from "./useAltDateWidgetProps.js";
|
|
75
|
+
import useDeepCompareMemo from "./useDeepCompareMemo.js";
|
|
76
|
+
import useFileWidgetProps from "./useFileWidgetProps.js";
|
|
77
|
+
import utcToLocal from "./utcToLocal.js";
|
|
78
|
+
import validationDataMerge from "./validationDataMerge.js";
|
|
79
|
+
import withIdRefPrefix from "./withIdRefPrefix.js";
|
|
80
|
+
export * from "./enums.js";
|
|
81
|
+
export * from "./constants.js";
|
|
82
|
+
export * from "./parser/index.js";
|
|
83
|
+
export * from "./schema/index.js";
|
|
84
|
+
export { allowAdditionalItems, ariaDescribedByIds, asNumber, buttonId, canExpand, createErrorHandler, createSchemaUtils, DateElement, dataURItoBlob, dateRangeOptions, deepEquals, descriptionId, englishStringTranslator, enumOptionSelectedValue, enumOptionValueDecoder, enumOptionValueEncoder, enumOptionsDeselectValue, enumOptionsIndexForValue, enumOptionsIsSelected, enumOptionsSelectValue, enumOptionsValueForIndex, errorId, examplesId, ErrorSchemaBuilder, findSchemaDefinition, getChangedFields, getDateElementProps, getDecimalSeparator, getDiscriminatorFieldFromSchema, getInputProps, getOptionMatchingSimpleDiscriminator, getPropertySchema, getOptionValueFormat, getSchemaType, getByPath, getSubmitButtonOptions, getTemplate, getTestIds, getUiOptions, getWidget, guessType, hasByPath, hasWidget, hashForSchema, hashObject, hashString, helpId, isConstant, isCustomWidget, isFixedItems, isFormDataAvailable, isObject, isPlainObject, isRootSchema, labelValue, localToUTC, logUnsupportedDefaultForEnum, lookupFromFormContext, mergeDefaultsWithFormData, mergeObjects, mergeSchemas, noop, optionalControlsId, optionId, optionsList, orderProperties, pad, parseDateString, rangeSpec,
|
|
81
85
|
// oxlint-disable-next-line typescript/no-deprecated
|
|
82
|
-
removeOptionalEmptyObjects, replaceStringParameters, resolveUiSchema, schemaRequiresTrueValue, SelectedOptionDescription, shallowEquals, shouldRender, shouldRenderOptionalField, sortedJSONStringify, titleId, toConstant, toDateString, toErrorList, toErrorSchema, toFieldPathId, unwrapErrorHandler, useAltDateWidgetProps, useDeepCompareMemo, useFileWidgetProps, utcToLocal, validationDataMerge, withIdRefPrefix, bracketNameGenerator, dotNotationNameGenerator, };
|
|
86
|
+
removeOptionalEmptyObjects, replaceStringParameters, resolveUiSchema, schemaRequiresTrueValue, setByPath, SelectedOptionDescription, shallowEquals, shouldRender, shouldRenderOptionalField, sortedJSONStringify, titleId, toConstant, toDateString, toErrorList, toErrorSchema, toFieldPathId, toPath, unsetByPath, unwrapErrorHandler, useAltDateWidgetProps, useDeepCompareMemo, useFileWidgetProps, utcToLocal, validationDataMerge, withIdRefPrefix, bracketNameGenerator, dotNotationNameGenerator, };
|
|
83
87
|
//# sourceMappingURL=index.js.map
|
package/lib/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,oBAAoB,MAAM,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,oBAAoB,MAAM,2BAA2B,CAAC;AAC7D,OAAO,QAAQ,MAAM,eAAe,CAAC;AACrC,OAAO,SAAS,MAAM,gBAAgB,CAAC;AACvC,OAAO,kBAAkB,MAAM,yBAAyB,CAAC;AACzD,OAAO,iBAAiB,MAAM,wBAAwB,CAAC;AACvD,OAAO,aAAa,MAAM,oBAAoB,CAAC;AAC/C,OAAO,gBAAgB,MAAM,uBAAuB,CAAC;AACrD,OAAO,UAAU,MAAM,iBAAiB,CAAC;AACzC,OAAO,uBAAuB,MAAM,8BAA8B,CAAC;AACnE,OAAO,wBAAwB,MAAM,+BAA+B,CAAC;AACrE,OAAO,uBAAuB,MAAM,8BAA8B,CAAC;AACnE,OAAO,wBAAwB,MAAM,+BAA+B,CAAC;AACrE,OAAO,qBAAqB,MAAM,4BAA4B,CAAC;AAC/D,OAAO,sBAAsB,MAAM,6BAA6B,C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,EACV,4BAA4B,EAC5B,qBAAqB,EACrB,yBAAyB,EACzB,YAAY,EACZ,YAAY,EACZ,IAAI,EACJ,kBAAkB,EAClB,QAAQ,EACR,WAAW,EACX,eAAe,EACf,GAAG,EACH,eAAe,EACf,SAAS;AACT,oDAAoD;AACpD,0BAA0B,EAC1B,uBAAuB,EACvB,eAAe,EACf,uBAAuB,EACvB,SAAS,EACT,yBAAyB,EACzB,aAAa,EACb,YAAY,EACZ,yBAAyB,EACzB,mBAAmB,EACnB,OAAO,EACP,UAAU,EACV,YAAY,EACZ,WAAW,EACX,aAAa,EACb,aAAa,EACb,MAAM,EACN,WAAW,EACX,kBAAkB,EAClB,qBAAqB,EACrB,kBAAkB,EAClB,kBAAkB,EAClB,UAAU,EACV,mBAAmB,EACnB,eAAe,EACf,oBAAoB,EACpB,wBAAwB,GACzB,CAAC"}
|
package/lib/isConstant.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { RJSFSchema, StrictRJSFSchema } from './types.
|
|
1
|
+
import type { RJSFSchema, StrictRJSFSchema } from './types.ts';
|
|
2
2
|
/** This function checks if the given `schema` matches a single constant value. This happens when either the schema has
|
|
3
3
|
* an `enum` array with a single value or there is a `const` defined.
|
|
4
4
|
*
|
|
@@ -6,3 +6,4 @@ import type { RJSFSchema, StrictRJSFSchema } from './types.js';
|
|
|
6
6
|
* @returns - True if the `schema` has a single constant value, false otherwise
|
|
7
7
|
*/
|
|
8
8
|
export default function isConstant<S extends StrictRJSFSchema = RJSFSchema>(schema: S): boolean;
|
|
9
|
+
//# sourceMappingURL=isConstant.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"isConstant.d.ts","sourceRoot":"","sources":["../src/isConstant.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,UAAU,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAE/D;;;;;GAKG;AACH,MAAM,CAAC,OAAO,UAAU,UAAU,CAAC,CAAC,SAAS,gBAAgB,GAAG,UAAU,EAAE,MAAM,EAAE,CAAC,WAEpF"}
|
package/lib/isConstant.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { CONST_KEY } from
|
|
1
|
+
import { CONST_KEY } from "./constants.js";
|
|
2
2
|
/** This function checks if the given `schema` matches a single constant value. This happens when either the schema has
|
|
3
3
|
* an `enum` array with a single value or there is a `const` defined.
|
|
4
4
|
*
|
package/lib/isConstant.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"isConstant.js","sourceRoot":"","sources":["../src/isConstant.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"isConstant.js","sourceRoot":"","sources":["../src/isConstant.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAG3C;;;;;GAKG;AACH,MAAM,CAAC,OAAO,UAAU,UAAU,CAA0C,MAAS;IACnF,OAAO,CAAC,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,IAAI,CAAC,IAAI,MAAM,CAAC,IAAI,CAAC,MAAM,KAAK,CAAC,CAAC,IAAI,SAAS,IAAI,MAAM,CAAC;AACzF,CAAC"}
|
package/lib/isCustomWidget.d.ts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import type { FormContextType, RJSFSchema, StrictRJSFSchema, UiSchema } from './types.
|
|
1
|
+
import type { FormContextType, RJSFSchema, StrictRJSFSchema, UiSchema } from './types.ts';
|
|
2
2
|
/** Checks to see if the `uiSchema` contains the `widget` field and that the widget is not `hidden`
|
|
3
3
|
*
|
|
4
4
|
* @param uiSchema - The UI Schema from which to detect if it is customized
|
|
5
5
|
* @returns - True if the `uiSchema` describes a custom widget, false otherwise
|
|
6
6
|
*/
|
|
7
7
|
export default function isCustomWidget<T = any, S extends StrictRJSFSchema = RJSFSchema, F extends FormContextType = any>(uiSchema?: UiSchema<T, S, F>): boolean;
|
|
8
|
+
//# sourceMappingURL=isCustomWidget.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"isCustomWidget.d.ts","sourceRoot":"","sources":["../src/isCustomWidget.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,eAAe,EAAE,UAAU,EAAE,gBAAgB,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAE1F;;;;GAIG;AACH,MAAM,CAAC,OAAO,UAAU,cAAc,CACpC,CAAC,GAAG,GAAG,EACP,CAAC,SAAS,gBAAgB,GAAG,UAAU,EACvC,CAAC,SAAS,eAAe,GAAG,GAAG,EAC/B,QAAQ,GAAE,QAAQ,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAM,WAMjC"}
|
package/lib/isCustomWidget.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import getUiOptions from
|
|
1
|
+
import getUiOptions from "./getUiOptions.js";
|
|
2
2
|
/** Checks to see if the `uiSchema` contains the `widget` field and that the widget is not `hidden`
|
|
3
3
|
*
|
|
4
4
|
* @param uiSchema - The UI Schema from which to detect if it is customized
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"isCustomWidget.js","sourceRoot":"","sources":["../src/isCustomWidget.ts"],"names":[],"mappings":"AAAA,OAAO,YAAY,MAAM,
|
|
1
|
+
{"version":3,"file":"isCustomWidget.js","sourceRoot":"","sources":["../src/isCustomWidget.ts"],"names":[],"mappings":"AAAA,OAAO,YAAY,MAAM,mBAAmB,CAAC;AAG7C;;;;GAIG;AACH,MAAM,CAAC,OAAO,UAAU,cAAc,CAIpC,WAA8B,EAAE;IAChC,OAAO;IACL,sGAAsG;IACtG,uFAAuF;IACvF,QAAQ,IAAI,YAAY,CAAU,QAAQ,CAAC,IAAI,YAAY,CAAU,QAAQ,CAAC,CAAC,MAAM,KAAK,QAAQ,CACnG,CAAC;AACJ,CAAC"}
|
package/lib/isFixedItems.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { RJSFSchema, StrictRJSFSchema } from './types.
|
|
1
|
+
import type { RJSFSchema, StrictRJSFSchema } from './types.ts';
|
|
2
2
|
/** Detects whether the given `schema` contains fixed items. This is the case when `schema.items` is an array that only
|
|
3
3
|
* contains objects.
|
|
4
4
|
*
|
|
@@ -6,3 +6,4 @@ import type { RJSFSchema, StrictRJSFSchema } from './types.js';
|
|
|
6
6
|
* @returns - True if there are fixed items in the schema, false otherwise
|
|
7
7
|
*/
|
|
8
8
|
export default function isFixedItems<S extends StrictRJSFSchema = RJSFSchema>(schema: S): boolean;
|
|
9
|
+
//# sourceMappingURL=isFixedItems.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"isFixedItems.d.ts","sourceRoot":"","sources":["../src/isFixedItems.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,UAAU,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAE/D;;;;;GAKG;AACH,MAAM,CAAC,OAAO,UAAU,YAAY,CAAC,CAAC,SAAS,gBAAgB,GAAG,UAAU,EAAE,MAAM,EAAE,CAAC,WAEtF"}
|
package/lib/isFixedItems.js
CHANGED
package/lib/isFixedItems.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"isFixedItems.js","sourceRoot":"","sources":["../src/isFixedItems.ts"],"names":[],"mappings":"AAAA,OAAO,QAAQ,MAAM,
|
|
1
|
+
{"version":3,"file":"isFixedItems.js","sourceRoot":"","sources":["../src/isFixedItems.ts"],"names":[],"mappings":"AAAA,OAAO,QAAQ,MAAM,eAAe,CAAC;AAGrC;;;;;GAKG;AACH,MAAM,CAAC,OAAO,UAAU,YAAY,CAA0C,MAAS;IACrF,OAAO,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,MAAM,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC;AACrF,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"isFormDataAvailable.d.ts","sourceRoot":"","sources":["../src/isFormDataAvailable.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,MAAM,CAAC,OAAO,UAAU,mBAAmB,CAAC,CAAC,GAAG,GAAG,EAAE,QAAQ,CAAC,EAAE,CAAC,GAAG,OAAO,CAQ1E"}
|
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
import isEmpty from 'lodash-es/isEmpty.js';
|
|
2
|
-
import isNil from 'lodash-es/isNil.js';
|
|
3
|
-
import isObject from 'lodash-es/isObject.js';
|
|
4
1
|
/** Determines whether the given `formData` represents valid form data, such as a primitive type, an array, or a
|
|
5
2
|
* non-empty object.
|
|
6
3
|
*
|
|
@@ -8,6 +5,12 @@ import isObject from 'lodash-es/isObject.js';
|
|
|
8
5
|
* @returns - True if `formData` is not undefined, null, a primitive type or an array or an empty object
|
|
9
6
|
*/
|
|
10
7
|
export default function isFormDataAvailable(formData) {
|
|
11
|
-
|
|
8
|
+
if (formData === undefined || formData === null) {
|
|
9
|
+
return false;
|
|
10
|
+
}
|
|
11
|
+
if (typeof formData !== 'object' || Array.isArray(formData)) {
|
|
12
|
+
return true;
|
|
13
|
+
}
|
|
14
|
+
return Object.keys(formData).length > 0;
|
|
12
15
|
}
|
|
13
16
|
//# sourceMappingURL=isFormDataAvailable.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"isFormDataAvailable.js","sourceRoot":"","sources":["../src/isFormDataAvailable.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"isFormDataAvailable.js","sourceRoot":"","sources":["../src/isFormDataAvailable.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,MAAM,CAAC,OAAO,UAAU,mBAAmB,CAAU,QAAY;IAC/D,IAAI,QAAQ,KAAK,SAAS,IAAI,QAAQ,KAAK,IAAI,EAAE,CAAC;QAChD,OAAO,KAAK,CAAC;IACf,CAAC;IACD,IAAI,OAAO,QAAQ,KAAK,QAAQ,IAAI,KAAK,CAAC,OAAO,CAAC,QAAQ,CAAC,EAAE,CAAC;QAC5D,OAAO,IAAI,CAAC;IACd,CAAC;IACD,OAAO,MAAM,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC,MAAM,GAAG,CAAC,CAAC;AAC1C,CAAC"}
|
package/lib/isObject.d.ts
CHANGED
|
@@ -1,7 +1,9 @@
|
|
|
1
|
+
import type { GenericObjectType } from './types.ts';
|
|
1
2
|
/** Determines whether a `thing` is an object for the purposes of RJSF. In this case, `thing` is an object if it has
|
|
2
3
|
* the type `object` but is NOT null, an array or a File.
|
|
3
4
|
*
|
|
4
5
|
* @param thing - The thing to check to see whether it is an object
|
|
5
6
|
* @returns - True if it is a non-null, non-array, non-File object
|
|
6
7
|
*/
|
|
7
|
-
export default function isObject(thing:
|
|
8
|
+
export default function isObject(thing: unknown): thing is GenericObjectType;
|
|
9
|
+
//# sourceMappingURL=isObject.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"isObject.d.ts","sourceRoot":"","sources":["../src/isObject.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AAEpD;;;;;GAKG;AACH,MAAM,CAAC,OAAO,UAAU,QAAQ,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,iBAAiB,CAyB3E"}
|
package/lib/isObject.js
CHANGED
|
@@ -10,12 +10,18 @@ export default function isObject(thing) {
|
|
|
10
10
|
}
|
|
11
11
|
// lastModified is guaranteed to be a number on a File instance
|
|
12
12
|
// as per https://w3c.github.io/FileAPI/#dfn-lastModified
|
|
13
|
-
if (
|
|
13
|
+
if ('lastModified' in thing &&
|
|
14
|
+
typeof thing.lastModified === 'number' &&
|
|
15
|
+
typeof File !== 'undefined' &&
|
|
16
|
+
thing instanceof File) {
|
|
14
17
|
return false;
|
|
15
18
|
}
|
|
16
19
|
// getMonth is guaranteed to be a method on a Date instance
|
|
17
20
|
// as per https://tc39.es/ecma262/multipage/numbers-and-dates.html#sec-date.prototype.getmonth
|
|
18
|
-
if (
|
|
21
|
+
if ('getMonth' in thing &&
|
|
22
|
+
typeof thing.getMonth === 'function' &&
|
|
23
|
+
typeof Date !== 'undefined' &&
|
|
24
|
+
thing instanceof Date) {
|
|
19
25
|
return false;
|
|
20
26
|
}
|
|
21
27
|
return !Array.isArray(thing);
|
package/lib/isObject.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"isObject.js","sourceRoot":"","sources":["../src/isObject.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"isObject.js","sourceRoot":"","sources":["../src/isObject.ts"],"names":[],"mappings":"AAEA;;;;;GAKG;AACH,MAAM,CAAC,OAAO,UAAU,QAAQ,CAAC,KAAc;IAC7C,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,KAAK,IAAI,EAAE,CAAC;QAChD,OAAO,KAAK,CAAC;IACf,CAAC;IACD,+DAA+D;IAC/D,yDAAyD;IACzD,IACE,cAAc,IAAI,KAAK;QACvB,OAAO,KAAK,CAAC,YAAY,KAAK,QAAQ;QACtC,OAAO,IAAI,KAAK,WAAW;QAC3B,KAAK,YAAY,IAAI,EACrB,CAAC;QACD,OAAO,KAAK,CAAC;IACf,CAAC;IACD,2DAA2D;IAC3D,8FAA8F;IAC9F,IACE,UAAU,IAAI,KAAK;QACnB,OAAO,KAAK,CAAC,QAAQ,KAAK,UAAU;QACpC,OAAO,IAAI,KAAK,WAAW;QAC3B,KAAK,YAAY,IAAI,EACrB,CAAC;QACD,OAAO,KAAK,CAAC;IACf,CAAC;IACD,OAAO,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;AAC/B,CAAC"}
|