fix(devices): copy buttons via component method (copyFromId) under CSP build
This commit is contained in:
1 parent
6d01bd7971
commit
3b66b981be
13 files changed
+34
-27
No files matched your search
@@ -111,7 +111,7 @@ templ Devices(user User, devices []handlers.DeviceInfo, pendingRegistrations []P
|
||||
class="input text-xs font-mono"
|
||||
/>
|
||||
<button
|
||||
@click={ "copyToClipboard(document.getElementById('sync-url-" + device.ID.String() + "').value, 'Kobo sync URL')" }
|
||||
@click={ "copyFromId('sync-url-" + device.ID.String() + "', 'Kobo sync URL')" }
|
||||
class="btn btn-primary text-xs px-3"
|
||||
>
|
||||
@Icon("copy", "h-4 w-4")
|
||||
@@ -133,7 +133,7 @@ templ Devices(user User, devices []handlers.DeviceInfo, pendingRegistrations []P
|
||||
class="input text-xs font-mono"
|
||||
/>
|
||||
<button
|
||||
@click={ "copyToClipboard(document.getElementById('auth-token-" + device.ID.String() + "').value, 'Auth token')" }
|
||||
@click={ "copyFromId('auth-token-" + device.ID.String() + "', 'Auth token')" }
|
||||
class="btn btn-primary text-xs px-3"
|
||||
>
|
||||
@Icon("copy", "h-4 w-4")
|
||||
|
||||
Reference in new issue
Block a user