Browse Source

i18n, accessibility

pull/2521/head
Bernd Storath 4 months ago
parent
commit
ec38f42430
  1. 16
      src/app/components/Clients/QRCodeDialog.vue
  2. 4
      src/i18n/locales/en.json

16
src/app/components/Clients/QRCodeDialog.vue

@ -9,10 +9,18 @@
</div> </div>
</template> </template>
<template #actions> <template #actions>
<BaseSecondaryButton class="flex items-center gap-2" @click="copyPng"> <BaseSecondaryButton
class="flex items-center gap-2"
:title="$t('client.copyPng')"
@click="copyPng"
>
<IconsCopy class="size-5" /> PNG <IconsCopy class="size-5" /> PNG
</BaseSecondaryButton> </BaseSecondaryButton>
<BaseSecondaryButton class="flex items-center gap-2" @click="downloadPng"> <BaseSecondaryButton
class="flex items-center gap-2"
:title="$t('client.downloadPng')"
@click="downloadPng"
>
<IconsDownload class="size-5" /> PNG <IconsDownload class="size-5" /> PNG
</BaseSecondaryButton> </BaseSecondaryButton>
<DialogClose as-child> <DialogClose as-child>
@ -68,9 +76,9 @@ async function downloadPng() {
} }
async function copyPng() { async function copyPng() {
const blob = await svgToPng();
try { try {
const blob = await svgToPng();
await navigator.clipboard.write([ await navigator.clipboard.write([
new ClipboardItem({ new ClipboardItem({
[blob.type]: blob, [blob.type]: blob,

4
src/i18n/locales/en.json

@ -122,7 +122,9 @@
"config": "Configuration", "config": "Configuration",
"viewConfig": "View Configuration", "viewConfig": "View Configuration",
"firewallIps": "Firewall Allowed IPs", "firewallIps": "Firewall Allowed IPs",
"firewallIpsDesc": "Destination IPs/CIDRs this client can access (server-side enforcement). Leave empty to use Allowed IPs. Supports optional port and protocol filtering. See docs for syntax." "firewallIpsDesc": "Destination IPs/CIDRs this client can access (server-side enforcement). Leave empty to use Allowed IPs. Supports optional port and protocol filtering. See docs for syntax.",
"downloadPng": "Download PNG",
"copyPng": "Copy PNG"
}, },
"dialog": { "dialog": {
"change": "Change", "change": "Change",

Loading…
Cancel
Save