nova-text-copy-field icon indicating copy to clipboard operation
nova-text-copy-field copied to clipboard

Unable to copy integer values t.value.trim is not a function

Open jonasbrenig opened this issue 3 years ago • 2 comments

Preflight

  • [x] I have searched the repo for this duplicates

Description

Expect Result

Copy value to the clippboard

Steps to reproduce

  • use an int instead of a string for the field
  • click the copy button

Logs, error output, etc

Uncaught TypeError: t.value.trim is not a function

image

Version information

nove-text-copy-field 1.5 Laravel Nova v3.8.4

jonasbrenig avatar Sep 02 '20 13:09 jonasbrenig

If you use a computed field and cast the int to a string before it works just fine.

jonasbrenig avatar Sep 02 '20 13:09 jonasbrenig

Thanks.

bernhardh avatar Sep 19 '21 09:09 bernhardh