Pasting in to a tagsInput splits a string
I'm not sure if this is a feature or a bug but if you have a simple tagsInput field and you paste a string in, it appears to be splitting it in to different tags
Is this the correct functionality or is there a way to stop it so it just accepts the entire string ?
Solution:Jump to solution
Looks like it was already reported and fixed - https://github.com/filamentphp/filament/issues/9313
GitHub
Each character automatically becoming tags when pasting in a TagsIn...
Package filament/filament Package Version v3.0.0 Laravel Version v10.10 Livewire Version No response PHP Version 8.2 Problem description When pasting texts into the TagsInput field, every character...
5 Replies
Does adding
->debounce(500)
help?I'm not the original poster but I arrived here because I was facing the same issue. I just tried adding
->debounce(500)
but it keeps happening.
I've tested this with the latest versions of the framework Filament (3.0-stable), Laravel (10.10) and it happens both in Firefox and Chrome.This is definitely a bug. Please report it on GitHub. π
Hahaha sorry @awcodes only just saw your reply.
I will try and report it on GH later today.
I did find a semi-work around however for anyone experiencing the same issue. @carloscapote
If you add
->splitKeys([' '])
it appears to work e.g.
This wouldn't work if you have spaces in your tags but for single word tags it appears to work for now.Solution
Looks like it was already reported and fixed - https://github.com/filamentphp/filament/issues/9313
GitHub
Each character automatically becoming tags when pasting in a TagsIn...
Package filament/filament Package Version v3.0.0 Laravel Version v10.10 Livewire Version No response PHP Version 8.2 Problem description When pasting texts into the TagsInput field, every character...