@rjsf/core 5.7.3 → 5.8.1

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.
@@ -1154,12 +1154,7 @@ var AnyOfField = /*#__PURE__*/function (_Component) {
1154
1154
  schemaUtils = _this$props4.registry.schemaUtils;
1155
1155
  var discriminator = utils.getDiscriminatorFieldFromSchema(schema);
1156
1156
  var option = schemaUtils.getClosestMatchingOption(formData, options, selectedOption, discriminator);
1157
- if (option > 0) {
1158
- return option;
1159
- }
1160
- // If the form data matches none of the options, use the currently selected
1161
- // option, assuming it's available; otherwise use the first option
1162
- return selectedOption || 0;
1157
+ return option;
1163
1158
  };
1164
1159
  _proto.getFieldId = function getFieldId() {
1165
1160
  var _this$props5 = this.props,
@@ -1772,6 +1767,9 @@ function SchemaFieldRender(props) {
1772
1767
  label = utils.ADDITIONAL_PROPERTY_FLAG in schema ? name : uiOptions.title || props.schema.title || schema.title || name;
1773
1768
  }
1774
1769
  var description = uiOptions.description || props.schema.description || schema.description || '';
1770
+ var richDescription = uiOptions.enableMarkdownInDescription ? jsxRuntime.jsx(Markdown__default["default"], {
1771
+ children: description
1772
+ }) : description;
1775
1773
  var help = uiOptions.help;
1776
1774
  var hidden = uiOptions.widget === 'hidden';
1777
1775
  var classNames = ['form-group', 'field', "field-" + utils.getSchemaType(schema)];
@@ -1806,7 +1804,7 @@ function SchemaFieldRender(props) {
1806
1804
  var fieldProps = {
1807
1805
  description: jsxRuntime.jsx(DescriptionFieldTemplate, {
1808
1806
  id: utils.descriptionId(id),
1809
- description: description,
1807
+ description: richDescription,
1810
1808
  schema: schema,
1811
1809
  uiSchema: uiSchema,
1812
1810
  registry: registry