mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-25 09:20:36 +01:00
docs(toast): update
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
<script setup lang="ts">
|
||||
import type { AvatarProps } from '@nuxt/ui'
|
||||
|
||||
const props = defineProps<{
|
||||
avatar: AvatarProps
|
||||
}>()
|
||||
|
||||
const toast = useToast()
|
||||
|
||||
function showToast() {
|
||||
toast.add({
|
||||
title: 'User invited',
|
||||
description: 'benjamincanac was invited to the team.',
|
||||
avatar: props.avatar
|
||||
})
|
||||
}
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<UButton label="Invite user" color="gray" variant="outline" @click="showToast" />
|
||||
</template>
|
||||
Reference in New Issue
Block a user