feat: 09 => add label prop to CancelButton for customizable text
This commit is contained in:
parent
37642160c4
commit
7834cc4395
2 changed files with 4 additions and 1 deletions
|
|
@ -5,6 +5,8 @@ defineEmits<{
|
|||
(e: 'click', v: MouseEvent): void;
|
||||
}>();
|
||||
defineProps<{
|
||||
label?: string;
|
||||
|
||||
iconOnly?: boolean;
|
||||
solid?: boolean;
|
||||
outlined?: boolean;
|
||||
|
|
@ -21,6 +23,6 @@ defineProps<{
|
|||
color="var(--negative-bg)"
|
||||
:title="iconOnly ? $t('general.cancel') : undefined"
|
||||
>
|
||||
{{ $t('general.cancel') }}
|
||||
{{ label || $t('general.cancel') }}
|
||||
</MainButton>
|
||||
</template>
|
||||
|
|
|
|||
|
|
@ -1198,6 +1198,7 @@ watch(
|
|||
<UndoButton outlined @click="undo()" v-if="state.mode === 'edit'" />
|
||||
<CancelButton
|
||||
@click="closeTab()"
|
||||
:label="$t('dialog.action.close')"
|
||||
v-if="state.mode === 'info'"
|
||||
outlined
|
||||
/>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue