Refactor to use ai/rsc (#253)

This commit is contained in:
Jeremy 2024-03-14 20:00:52 +03:00 committed by GitHub
parent 69ca8fcc22
commit e85ba803dd
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
66 changed files with 2799 additions and 740 deletions

View file

@ -2,7 +2,7 @@
import * as React from 'react'
import { type DialogProps } from '@radix-ui/react-dialog'
import { toast } from 'react-hot-toast'
import { toast } from 'sonner'
import { ServerActionResult, type Chat } from '@/lib/types'
import { Button } from '@/components/ui/button'
@ -42,18 +42,7 @@ export function ChatShareDialog({
url.pathname = chat.sharePath
copyToClipboard(url.toString())
onCopy()
toast.success('Share link copied to clipboard', {
style: {
borderRadius: '10px',
background: '#333',
color: '#fff',
fontSize: '14px'
},
iconTheme: {
primary: 'white',
secondary: 'black'
}
})
toast.success('Share link copied to clipboard')
},
[copyToClipboard, onCopy]
)