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

Multiselect for SelectField and AutoComplete #2337

Closed
igorpreston opened this issue Dec 2, 2015 · 6 comments
Closed

Multiselect for SelectField and AutoComplete #2337

igorpreston opened this issue Dec 2, 2015 · 6 comments
Labels
duplicate This issue or pull request already exists

Comments

@igorpreston
Copy link

Hello,

I am utilizing select fields and auto complete a lot in my app and I'd like to know if there are plans for adding multi-select for these fields. I think multi-select is widely required feature that a lot of developers can benefit from.

Thanks!

@oliviertassinari
Copy link
Member

I think that it would be a good feature. As far as I have think about it, it should many require to change the SelectField component.
For the AutoComplete what do you want to achieve something like https://www.google.com/design/spec/components/chips.html#chips-behavior?
Hence, I think that we should create a new component.

@newoga
Copy link
Contributor

newoga commented Dec 2, 2015

Should we just consider expanding the current AutoComplete implementation to be a select field that can have one or several values?

To support chips, we could possibly expose a prop that accepts a function that customizes the rendering of the values, such as the valueRenderer prop in the react-select component.

For example, the code below would show each value as a chip with an avatar as the first letter of the display name kind of like this -> (J) John Smith )

<AutoComplete valueRenderer={(value) => {
  return <Chip avatar={<Avatar>{value.displayName[0]}}</Avatar>}>
    {value.displayName}
  </Chip>
}} { ...otherProps} />

If a custom valueRenderer is not provided, we can use a default implementation that displays the value the way it currently does.

@oliviertassinari
Copy link
Member

I like the idea of a valueRenderer.

@FranBran
Copy link

FranBran commented Mar 9, 2016

+1
is there any progress?

i would love to see a component like the one from MaterializeCSS:
multiSelect

@injune1123
Copy link

+1
I wish there is something like React-Select

screen shot 2016-04-15 at 4 44 26 pm

@tintin1343 tintin1343 added the duplicate This issue or pull request already exists label Apr 20, 2016
@tintin1343
Copy link
Contributor

Closing this as its a duplicate of #1956

@oliviertassinari oliviertassinari removed the new feature New feature or request label Feb 22, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

7 participants