Only show list item add instructions when allowed
This commit is contained in:
parent
9a16d79ab9
commit
c483cf6dc6
@ -44,7 +44,7 @@ export default function ListInput({
|
||||
<PillsInput
|
||||
mt={mt}
|
||||
label={label}
|
||||
description="Press enter or comma to add item"
|
||||
description={canAdd ? "Press enter or comma to add item" : ""}
|
||||
>
|
||||
<Pill.Group>
|
||||
{(form.getTransformedValues()[field_key] as string[]).map(
|
||||
|
@ -31,7 +31,10 @@ export default function ListInput({
|
||||
};
|
||||
|
||||
return (
|
||||
<PillsInput label={label} description="Press enter or comma to add item">
|
||||
<PillsInput
|
||||
label={label}
|
||||
description={canAdd ? "Press enter or comma to add item" : ""}
|
||||
>
|
||||
<Pill.Group>
|
||||
{value.map((item: string) => (
|
||||
<Pill
|
||||
|
Loading…
x
Reference in New Issue
Block a user