fixed quotes, indent, simpler property

This commit is contained in:
Spitap
2022-09-26 18:21:05 +02:00
parent d1554504f6
commit 14dd836e4e
5 changed files with 16 additions and 22 deletions
@@ -1,6 +1,6 @@
<template>
<button @click="copyDNSToClipboard()" class='dkimbutton'>
<pre id='dkimdns' class='dkim'>{{ domain.dkim_key_selector }}._domain_key.{{ domain.name }}. IN TXT ({{ splitKey(`v=DKIM1;k=rsa;p=${domain.dkim_public_key}`) }})</pre>
<button @click="copyDKIM()" class="dkimbutton">
<pre id="dkimdns" class="dkim">{{ domain.dkim_key_selector }}._domain_key.{{ domain.name }}. IN TXT ({{ splitKey(`v=DKIM1;k=rsa;p=${domain.dkim_public_key}`) }})</pre>
</button>
</template>
@@ -24,9 +24,8 @@ export default {
}
return result.join('\n')
},
copyDNSToClipboard () {
const text = document.getElementById('dkimdns').textContent
navigator.clipboard.writeText(text)
copyDKIM () {
navigator.clipboard.writeText(document.getElementById('dkimdns').textContent)
}
}
}
@@ -164,7 +164,7 @@ export default {
const confirm = await this.$refs.confirm.open(
this.$gettext('Warning'),
this.$gettext(
'Do you really want to regenerate the DKIM keys set for this domain ?'
'DKIM keys already exist for this domain. Do you want to overwrite them?'
),
{
color: 'error',
@@ -32,7 +32,7 @@
elevation="2"
dense
>
<button @click="copyPubKeyToClipboard()" class='dkimbutton'><pre id='dkimpub' class='dkim'>{{ domain.dkim_public_key }}</pre></button>
<button @click="copyPubDKIM()" class="dkimbutton"><pre id="dkimpub" class="dkim">{{ domain.dkim_public_key }}</pre></button>
</v-alert>
</v-card-text>
<v-card-text>
@@ -70,9 +70,8 @@ export default {
close () {
this.$emit('close')
},
copyPubKeyToClipboard () {
const text = document.getElementById('dkimpub').textContent
navigator.clipboard.writeText(text)
copyPubDKIM () {
navigator.clipboard.writeText(document.getElementById('dkimpub').textContent)
}
}
}