-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAlert.vue
More file actions
50 lines (47 loc) · 1.49 KB
/
Copy pathAlert.vue
File metadata and controls
50 lines (47 loc) · 1.49 KB
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
48
49
50
<script setup lang="ts">
const colors = ['primary', 'secondary', 'success', 'info', 'warning', 'error', 'neutral'] as const
const variants = ['solid', 'outline', 'soft', 'subtle'] as const
</script>
<template>
<div class="flex flex-col gap-8">
<GallerySection title="Colors">
<div class="flex w-full max-w-md flex-col gap-3">
<UAlert
v-for="c in colors"
:key="c"
:color="c"
variant="soft"
:title="c"
description="Session event delivered by the runtime."
icon="i-material-symbols-notifications-outline"
class="capitalize"
/>
</div>
</GallerySection>
<GallerySection title="Variants">
<div class="flex w-full max-w-md flex-col gap-3">
<UAlert
v-for="v in variants"
:key="v"
color="primary"
:variant="v"
:title="v"
description="Job accepted by the runtime."
icon="i-material-symbols-check-circle-outline"
class="capitalize"
/>
</div>
</GallerySection>
<GallerySection title="With actions">
<UAlert
class="w-full max-w-md"
color="warning"
variant="soft"
title="Lease expiring"
description="The job lease expires in 30 seconds."
icon="i-material-symbols-timer-outline"
:actions="[{ label: 'Renew', color: 'warning' }, { label: 'Dismiss', variant: 'ghost', color: 'neutral' }]"
/>
</GallerySection>
</div>
</template>