Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix fullWidth support on AutoCompleteInput #4096

Merged
merged 2 commits into from
Dec 2, 2019
Merged

Conversation

fzaninotto
Copy link
Member

Closes #4093 for AutocompleteInput and AutocompleteArrayInput

Now, these two inputs work like all the other components and accept a fullWidth property.

To enable fullWith on AutocompleteInput:

  • When used standalone, add the fullWidth attribute to the AutocompleteInput:
<AutocompleteInput
    source="foo"
    choices={[
        { id: 1, name: 'foo' },
        { id: 2, name: 'bar' },
    ]}
    fullWidth
/>
  • When used inside a ReferenceInput, set the fullWidth prop on the ReferenceInput:
<ReferenceInput source="post_id" reference="posts" fullWidth>
    <AutocompleteInput optionText="title" />
</ReferenceInput>

@fzaninotto fzaninotto added this to the 3.0.3 milestone Dec 2, 2019
@djhi djhi merged commit 3141cc8 into master Dec 2, 2019
@djhi djhi deleted the fix-autocomplete-fullwidth branch December 2, 2019 13:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

<AutocompleteInput /> fullwidth property not working
2 participants