10% off on all-access. Use code SUPER10.
    d :
    h :
    m :
    Logo

    Animated Modal

    A customizable, compound modal component with animated transitions

    Installation

    Run the following command

    npx shadcn@latest add @aceternity/animated-modal

    props

    ModalProvider

    PropTypeDescription
    childrenReactNodeThe content to be wrapped by the provider.
    PropTypeDescription
    childrenReactNodeThe content to be displayed inside the modal.

    ModalTrigger

    PropTypeDescription
    childrenReactNodeThe content to be displayed inside the trigger button.
    classNamestring?Optional additional class names for the trigger button.

    ModalBody

    PropTypeDescription
    childrenReactNodeThe content to be displayed inside the modal body.
    classNamestring?Optional additional class names for the modal body.

    ModalContent

    PropTypeDescription
    childrenReactNodeThe content to be displayed inside the modal content.
    classNamestring?Optional additional class names for the modal content.

    ModalFooter

    PropTypeDescription
    childrenReactNodeThe content to be displayed inside the modal footer.
    classNamestring?Optional additional class names for the modal footer.

    Overlay

    PropTypeDescription
    classNamestring?Optional additional class names for the overlay.

    useOutsideClick

    PropTypeDescription
    refReact.RefObject<HTMLDivElement>The reference to the element to detect outside clicks.
    callbackFunctionThe callback function to be called when an outside click is detected.

    Build websites faster and 10x better than your competitors with

    Aceternity UI Pro

    Next.js 15, Tailwind CSS v4 and Motion for react powered templates

    100+ templates and blocks combined

    Ready to copy paste component blocks, save days of development time

    Aceternity UI Pro Demo - Light Mode
    Logo
    Aceternity UI

    Access an ever-growing collection of premium, meticulously crafted templates and Component Blocks.

    A product by Aceternity
    Building in public at @mannupaaji

    © 2026 Aceternity Labs LLC. All Rights Reserved.