Toast
A succinct message that is displayed temporarily.
'use client'
import { Button } from '@immit/ui/button'
import { ToastAction, useToast } from '@immit/ui/toast'
export function ToastDemo() {
const { toast } = useToast()
return (
<Button
variant="outline"
onClick={() => {
toast({
title: 'Scheduled: Catch up ',
description: 'Friday, February 10, 2023 at 5:57 PM',
action: (
<ToastAction altText="Goto schedule to undo">Undo</ToastAction>
)
})
}}
>
Add to calendar
</Button>
)
}