refactor(lint): linter auto fix

This commit is contained in:
Corentin Thomasset 2022-04-22 23:31:40 +02:00
parent 8e29a97404
commit 086d31eab5
No known key found for this signature in database
GPG key ID: DBD997E935996158
54 changed files with 1122 additions and 1503 deletions

View file

@ -3,45 +3,41 @@
<template #suffix>
<n-tooltip trigger="hover">
<template #trigger>
<n-button
quaternary
circle
@click="onCopyClicked"
>
<n-button quaternary circle @click="onCopyClicked">
<n-icon :component="ContentCopyFilled" />
</n-button>
</template>
{{ tooltipText }}
</n-tooltip>
</template>
</template>
</n-input>
</template>
<script setup lang="ts">
import { useVModel, useClipboard } from '@vueuse/core'
import { ContentCopyFilled } from '@vicons/material'
import { useVModel, useClipboard } from '@vueuse/core';
import { ContentCopyFilled } from '@vicons/material';
import { ref } from 'vue';
const props = defineProps<{ value: string, }>()
const emit = defineEmits(['update:value'])
const props = defineProps<{ value: string }>();
const emit = defineEmits(['update:value']);
const value = useVModel(props, 'value', emit)
const tooltipText = ref('Copy to clipboard')
const value = useVModel(props, 'value', emit);
const tooltipText = ref('Copy to clipboard');
const {copy} = useClipboard({source: value})
const { copy } = useClipboard({ source: value });
function onCopyClicked() {
copy();
tooltipText.value = 'Copied !'
copy();
tooltipText.value = 'Copied !';
setTimeout(() => {
tooltipText.value = 'Copy to clipboard'
}, 2000)
setTimeout(() => {
tooltipText.value = 'Copy to clipboard';
}, 2000);
}
</script>
<style scoped>
::v-deep(.n-input-wrapper) {
padding-right: 5px;
padding-right: 5px;
}
</style>
</style>