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

add emails on format: John Johnson <[email protected]> #66

Open
daggala opened this issue May 5, 2021 · 2 comments
Open

add emails on format: John Johnson <[email protected]> #66

daggala opened this issue May 5, 2021 · 2 comments

Comments

@daggala
Copy link

daggala commented May 5, 2021

It's quite common in gmail and other mail clients that the emails are displayed with the names and then the email inside chevrons, like this: John Johnson [email protected] (see gmail screenshot below)

Capture d’écran 2021-05-05 à 4 59 53 PM

It would be great to be able to copy paste this kind of format in the textfield and keep the format when it transforms into a chip:

Capture d’écran 2021-05-05 à 5 18 49 PM

@mileskin
Copy link

Pasteable example exactly how gmail supports it: Marsellus Wallace <[email protected]>, Winston Wolf <[email protected]>,.

Maybe this lib could parse the input to a list of objects? [{firstName: 'Marsellus', lastName: 'Wallace', email: '[email protected]'}, ...].

@Brian-McBride
Copy link

How will this component know the user's name? You would need an external service for that.
I would think that you could take the component onChange event and create a lookup array with names. Then just create your own display component in getLabel to match up the email (as the key) to your name lookup.

I was thinking the same. But, where do you get the full names? I guess a DB you build up somewhere?

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

No branches or pull requests

3 participants