mirror of https://github.com/buster-so/buster.git
update toaster naming
This commit is contained in:
parent
6a5dec59cf
commit
09f81c99c0
|
@ -2,16 +2,16 @@
|
|||
|
||||
import React from 'react';
|
||||
import { useTheme } from 'next-themes';
|
||||
import { Toaster } from 'sonner';
|
||||
import { Toaster as ToasterSonner } from 'sonner';
|
||||
import { CircleCheck } from '@/components/ui/icons';
|
||||
|
||||
type ToasterProps = React.ComponentProps<typeof Toaster>;
|
||||
type ToasterProps = React.ComponentProps<typeof ToasterSonner>;
|
||||
|
||||
const AppToaster = ({ ...props }: ToasterProps) => {
|
||||
const Toaster = ({ ...props }: ToasterProps) => {
|
||||
const { theme = 'system' } = useTheme();
|
||||
|
||||
return (
|
||||
<Toaster
|
||||
<ToasterSonner
|
||||
position="top-center"
|
||||
expand={true}
|
||||
visibleToasts={5}
|
||||
|
@ -35,4 +35,4 @@ const AppToaster = ({ ...props }: ToasterProps) => {
|
|||
);
|
||||
};
|
||||
|
||||
export { AppToaster };
|
||||
export { Toaster };
|
|
@ -1 +1 @@
|
|||
export * from './AppToaster';
|
||||
export * from './Toaster';
|
||||
|
|
|
@ -9,7 +9,7 @@ import {
|
|||
createContext,
|
||||
ContextSelector
|
||||
} from '@fluentui/react-context-selector';
|
||||
import { AppToaster } from '@/components/ui/toaster';
|
||||
import { Toaster } from '@/components/ui/toaster';
|
||||
|
||||
export const ENABLE_DARK_MODE = false;
|
||||
|
||||
|
@ -34,7 +34,7 @@ export const BusterStyleProvider: React.FC<PropsWithChildren<{}>> = ({ children
|
|||
disableTransitionOnChange>
|
||||
<BaseBusterStyleProvider>
|
||||
{children}
|
||||
<AppToaster />
|
||||
<Toaster />
|
||||
</BaseBusterStyleProvider>
|
||||
</NextThemeProvider>
|
||||
);
|
||||
|
|
Loading…
Reference in New Issue