mirror of
https://github.com/nextui-org/nextui.git
synced 2025-12-08 19:26:11 +00:00
fix(toast): shouldShowTimeoutProgess typo (#4858)
* fix(toast): shouldShowTimeoutProgess typo * fix(toast): shouldShowTimeoutProgess typo
This commit is contained in:
parent
29df4f5317
commit
fd446dac2a
5
.changeset/thirty-candles-listen.md
Normal file
5
.changeset/thirty-candles-listen.md
Normal file
@ -0,0 +1,5 @@
|
||||
---
|
||||
"@heroui/toast": patch
|
||||
---
|
||||
|
||||
fix shouldShowTimeoutProgess typo (#4856)
|
||||
@ -100,7 +100,7 @@ export interface ToastProps extends ToastVariantProps {
|
||||
/**
|
||||
* should apply styles to indicate timeout progress
|
||||
*/
|
||||
shouldShowTimeoutProgess?: boolean;
|
||||
shouldShowTimeoutProgress?: boolean;
|
||||
/**
|
||||
* The severity of the toast. This changes the icon without having to change the color.
|
||||
* @default "default"
|
||||
@ -155,7 +155,7 @@ export function useToast<T extends ToastProps>(originalProps: UseToastProps<T>)
|
||||
toastOffset = 0,
|
||||
motionProps,
|
||||
timeout = 6000,
|
||||
shouldShowTimeoutProgess = false,
|
||||
shouldShowTimeoutProgress = false,
|
||||
icon,
|
||||
onClose,
|
||||
severity,
|
||||
@ -233,7 +233,7 @@ export function useToast<T extends ToastProps>(originalProps: UseToastProps<T>)
|
||||
|
||||
if (progressBarRef.current) {
|
||||
progressBarRef.current.style.width = `${
|
||||
shouldShowTimeoutProgess ? progressRef.current : 0
|
||||
shouldShowTimeoutProgress ? progressRef.current : 0
|
||||
}%`;
|
||||
}
|
||||
|
||||
@ -251,7 +251,7 @@ export function useToast<T extends ToastProps>(originalProps: UseToastProps<T>)
|
||||
};
|
||||
}, [
|
||||
timeout,
|
||||
shouldShowTimeoutProgess,
|
||||
shouldShowTimeoutProgress,
|
||||
state,
|
||||
isToastHovered,
|
||||
index,
|
||||
|
||||
@ -110,7 +110,7 @@ const ShowTimeoutProgressTemplate = (args: ToastProps) => {
|
||||
title: "Toast Title",
|
||||
description: "Toast Description",
|
||||
timeout: 3000,
|
||||
shouldShowTimeoutProgess: true,
|
||||
shouldShowTimeoutProgress: true,
|
||||
...args,
|
||||
});
|
||||
}}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user