Skip to content

Commit

Permalink
Merge pull request #132 from cristidumitrescutotalsoft/cristidumitres…
Browse files Browse the repository at this point in the history
…cutotalsoft-feature/autoClose-default-on-useToast-fix1

Add ToastContainerProps custom type for useToast
  • Loading branch information
DCosti authored Oct 7, 2024
2 parents 78b65c0 + c7dbf56 commit 983ac0a
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 8 deletions.
2 changes: 0 additions & 2 deletions src/components/feedback/Toast/ToastContainer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ import { ToastContainerProps } from './types'

const ToastContainer: React.FC<ToastContainerProps> = ({
position = toast.POSITION.TOP_CENTER,
autoClose = false,
newestOnTop = true,
transitionType = 'Slide',
limit = 5,
Expand All @@ -22,7 +21,6 @@ const ToastContainer: React.FC<ToastContainerProps> = ({
<ReactToastify
className={classes.toastWrapper}
position={position}
autoClose={autoClose}
newestOnTop={newestOnTop}
transition={transitionType as any}
theme="colored"
Expand Down
6 changes: 0 additions & 6 deletions src/components/feedback/Toast/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,4 @@ export interface ToastContainerProps extends Omit<ReactToastifyProps, 'transitio
* @default Slide
*/
transitionType?: 'Slide' | 'Bounce' | 'Zoom' | 'Flip'
/**
* Set the delay in ms to close the toast automatically.
* Use `false` to prevent the toast from closing.
* `Default: false`
*/
autoClose?: number | false
}

0 comments on commit 983ac0a

Please sign in to comment.