Skip to content

Commit

Permalink
fix(frontend): copy-to-clipnoard url with protocol (#1027)
Browse files Browse the repository at this point in the history
  • Loading branch information
mrl5 committed Dec 18, 2022
1 parent 42d4711 commit f77fe7b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions frontend/src/routes/scripts/get/[...hash].svelte
Expand Up @@ -415,13 +415,14 @@
<ul>
{#each Object.keys(webhooks[key]) as type}
{@const url = webhooks[key][type]}
{@const href = $page.url.protocol + '//' + url}
<li class="flex justify-between items-center mt-2">
<a
on:click={(e) => {
e.preventDefault()
copyToClipboard(url)
copyToClipboard(href)
}}
href={$page.url.protocol + '//' + url}
href={href}
class="whitespace-nowrap text-ellipsis overflow-hidden mr-1"
>
{url}
Expand Down

0 comments on commit f77fe7b

Please sign in to comment.