Updated Min/Max value labels (#813)
Min/Max values fields will now check if a title was passed. If no title was passed the label will be "Minimum" or "Maximum".
This commit is contained in:
parent
d6be107167
commit
4cb2fa66aa
|
@ -118,7 +118,7 @@ export default function NumericRangeField({
|
||||||
<div className="numeric--range-field-inputs">
|
<div className="numeric--range-field-inputs">
|
||||||
<TextInput
|
<TextInput
|
||||||
id={`${id}-min`}
|
id={`${id}-min`}
|
||||||
labelText={`Minimum ${schema.title || ''}`}
|
labelText={(schema as any).properties?.min?.title || `Minimum`}
|
||||||
disabled={disabled}
|
disabled={disabled}
|
||||||
readonly={readonly}
|
readonly={readonly}
|
||||||
value={formatNumberString(min)}
|
value={formatNumberString(min)}
|
||||||
|
@ -131,7 +131,7 @@ export default function NumericRangeField({
|
||||||
/>
|
/>
|
||||||
<TextInput
|
<TextInput
|
||||||
id={`${id}-max`}
|
id={`${id}-max`}
|
||||||
labelText={`Maximum ${schema.title || ''}`}
|
labelText={(schema as any).properties?.max?.title || `Maximum`}
|
||||||
disabled={disabled}
|
disabled={disabled}
|
||||||
readonly={readonly}
|
readonly={readonly}
|
||||||
value={formatNumberString(max)}
|
value={formatNumberString(max)}
|
||||||
|
|
Loading…
Reference in New Issue