Skip to content

Commit

Permalink
fix: pass readOnly to select element (#3900)
Browse files Browse the repository at this point in the history
  • Loading branch information
mariuslundgard committed Dec 21, 2022
1 parent bb61fa1 commit f70736f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/sanity/src/core/form/inputs/SelectInput.tsx
Expand Up @@ -86,12 +86,14 @@ export function SelectInput(props: StringInputProps) {
direction={schemaType.options?.direction || 'vertical'}
customValidity={validationError}
onChange={handleChange}
readOnly={readOnly}
/>
) : (
<Select
{...elementProps}
customValidity={validationError}
value={optionValueFromItem(currentItem)}
readOnly={readOnly}
onChange={handleSelectChange}
>
{[EMPTY_ITEM, ...items].map((item, i) => (
Expand Down

1 comment on commit f70736f

@vercel
Copy link

@vercel vercel bot commented on f70736f Dec 21, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

test-studio – ./

test-studio-git-next.sanity.build
test-studio.sanity.build

Please sign in to comment.