ngx-chips
ngx-chips copied to clipboard
addOnPaste not working with onAdding.
PLEASE MAKE SURE THAT:
- you searched similar issues online (9/10 issues in this repo are solved by googling, so please...do it)
- you provide an online demo I can see without having to replicate your environment
- you help me by debugging your issue, and if you can't, do go on filling out this form
I'm submitting a ... (check one with "x")
[x] bug report => search github for a similar issue or PR before submitting
[ ] support request/question
Notice: feature requests will be ignored, submit a PR if you'd like
Current behavior I wanted to enter multiple emails with validation and that working fine but want to transform emails into lower case to prevent duplicates so i used onAdding and transformed strings to lowercase before tag added. Also need to add multiple emails on past too with comma separator but it's not working if using onAdding. If i remove onAdding then past working fine.
Expected behavior Pasting should work with onAdding option.
Minimal reproduction of the problem with instructions (if applicable) stackblitz example
What do you use to build your app?. Please specify the version Angular-cli
Angular version: 5
ngx-chips version: 2.0.0-beta.0
Browser: all
@hupptechnologies try giving a split pattern something like this
splitPattern = new RegExp('[,;\ ]'); and in the
<tag-input [addOnPaste]="true" [pasteSplitPattern]="splitPattern"></tag-input>
this worked for me.