feat(reminders): add confirm button

This commit is contained in:
kolaente 2023-06-09 14:27:11 +02:00
parent ae177c73ea
commit 02da1e171e
Signed by: konrad
GPG Key ID: F40E70337AB24C9B
2 changed files with 16 additions and 2 deletions

View File

@ -8,7 +8,7 @@
}"
ref="popup"
>
<slot name="content" :isOpen="open"/>
<slot name="content" :isOpen="open" :toggle="toggle"/>
</div>
</template>

View File

@ -8,7 +8,7 @@
{{ reminderText }}
</SimpleButton>
</template>
<template #content="{isOpen}">
<template #content="{isOpen, toggle}">
<Card class="reminder-options-popup" :class="{'is-open': isOpen}" :padding="false">
<div class="options" v-if="showFormSwitch === null">
<SimpleButton
@ -36,6 +36,15 @@
v-model="reminderDate"
@update:modelValue="setReminderDate"
/>
<x-button
v-if="showFormSwitch !== null"
class="reminder__close-button"
:shadow="false"
@click="toggle"
>
{{ $t('misc.confirm') }}
</x-button>
</Card>
</template>
</Popup>
@ -212,4 +221,9 @@ function translateUnit(amount: number, unit: PeriodUnit): string {
}
}
}
.reminder__close-button {
margin: .5rem;
width: calc(100% - 1rem);
}
</style>