Topic: Chips Autocomplete
bitjuice pro asked 6 years ago
marchanddesable pro answered 5 years ago
Hi, I also need this feature, autocomplete with chip. I'm working on it and it's almost done, I only have one issue:
Is it possible add new tags with javascript? If I add initial tags at the loading of the page
$('.chipfld').material_chip({ data: arr });
It works.
BUT
I need to add them when I click on the options returned by the backend... So I need to trigger a "add new tag" event when I click on something, It's like simulating the "enter key" on the hidden input field created by the jquery chip.
I also tried to make a fresh tab of datas with the new data added
$('.chipfld').material_chip({ data: myNewArr });
but it doesn't work, the tags are not generated...
Arkadiusz Idzikowski staff commented 5 years ago
You can find more information about adding tags in our documentation:
https://mdbootstrap.com/docs/jquery/components/badges/#javascript-usage
Damian Gemza staff answered 6 years ago
FREE CONSULTATION
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
Answered
- ForumUser: Pro
- Premium support: No
- Technology: MDB Angular
- MDB Version: 6.2.3
- Device: PC
- Browser: Chorme
- OS: Windows 10
- Provided sample code: No
- Provided link: Yes