fmeccanici
$livewire->dispatchBrowserEvent('copy-to-clipboard') is not working on Safari
Thanks @pboivin, I am able to import the JS! The clipboard functionality still doesn't work on Safari though. I tried every solution from StackOverflow. Could be out of the scope of Filament, but I'm not sure.
12 replies
$livewire->dispatchBrowserEvent('copy-to-clipboard') is not working on Safari
The second suggestion says that Safari implemented the Clipboard API 1 year ago. Which requires a small amount of javascript code:
What I am missing is how do I execute this piece of javascript code in the action of the table. This the stripped done table I currently have:
Because this table is inside a RelationManager class, which is used inside a Resource. This Resource is used inside a ListRecords class. But there is no associated blade file (or I cannot find it) where I can use a script tag to execute the javascript. I don't see a way to actually execute the Javascript, which is the main question I have. Do you know a way to execute this piece of Javascript?
12 replies
$livewire->dispatchBrowserEvent('copy-to-clipboard') is not working on Safari
Yes I found it on StackOverflow (https://stackoverflow.com/questions/40147676/javascript-copy-to-clipboard-on-safari). There are multiple suggested implementations on this post.
12 replies