-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathContentCard.vue
47 lines (43 loc) · 1.23 KB
/
ContentCard.vue
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
<template>
<Card :class="['p-[32px]', 'w-full']" :has-padding="false">
<!-- header -->
<div :class="['flex', 'justify-between', 'items-center','mb-[32px]']">
<Label
v-if="title"
class="w-min"
:text="title"
tag="div"
preset="p5"
valign="middle"
content-class="font-semibold whitespace-nowrap text-like-green"
prepend-class="text-like-green"
>
<template #prepend>
<slot name="label-prepend" />
</template>
</Label>
<slot name="title" />
<div v-if="step && totalStep" :class="['flex', 'flex-col', 'items-end']">
<Stepper :step="step" :total-step="totalStep" />
<Label
preset="p6"
:text="$t('Registration.step', { step: step, total: totalStep })"
class="text-medium-gray"
/>
</div>
</div>
<!-- body -->
<slot />
<!-- footer -->
<slot name="footer" />
</Card>
</template>
<script lang="ts">
import { Vue, Component, Prop } from 'vue-property-decorator'
@Component
export default class ContentCard extends Vue {
@Prop(String) readonly title!: string
@Prop(Number) readonly step!: number
@Prop(Number) readonly totalStep!: number
}
</script>