feat(front): label prop for CopyInput

This commit is contained in:
ArneBo 2025-01-16 17:09:18 +01:00
parent 6ee0d81976
commit 75d52faedc
2 changed files with 7 additions and 3 deletions

View File

@ -10,11 +10,13 @@ interface Props {
value: string
buttonClasses?: string
id?: string
label: string
}
const props = withDefaults(defineProps<Props>(), {
buttonClasses: 'accent',
id: 'copy-input'
id: 'copy-input',
label: 'label'
})
const { t } = useI18n()
@ -36,6 +38,7 @@ const { copy, isSupported: canCopy, copied } = useClipboard({ source: value, cop
readonly
:name="id"
type="text"
:label="label"
>
<template #input-right>
<Button
@ -73,4 +76,4 @@ p.message {
bottom: -32px;
right: 0px;
}
</style>
</style>

View File

@ -266,11 +266,12 @@ const isOpen = ref(false)
>
<div class="ui form">
<div class="field">
<label :for="library.fid">{{ t('views.content.remote.Card.label.sharingLink') }}</label>
<Spacer />
<copy-input
:id="library.fid"
:button-classes="'basic'"
:value="library.fid"
:label="t('views.content.remote.Card.label.sharingLink')"
/>
</div>
</div>