Traken UI

Modal

A customizable popup or overlay for displaying important content, forms, or dialogs without leaving the current page—supports sizes, colors, shadows, and animations.

Feature

  • Various variants: popup, drawer, and dialog
  • Adjustable size, color, and position for different use cases
  • Multiple animation options for transitions (e.g., scale, fade, slide)
  • Overlay color customization for better visibility and focus
  • Configurable border radius and shadow effects


Colors


Sizes


Radius


Shadow


Border


Animation


Overlay Colors


Examples

Overlay Colors

Prop

PropTypeDefaultDescription
childrenReact.ReactNodeThe content of the modal (can include text, forms, or other components).
color`"base""primary""secondary"
size`"sm""md""lg"
radius`"none""sm""md"
shadow`"none""sm""md"
isOpenbooleanWhether the modal is open or not (controlled externally).
onOpenChange(open: boolean) => voidA callback function to handle modal state change when it is opened or closed.
variant`"popup""drawer""dialog"`
position`"center""top""right"
overlayColor`"dark""light""none"`
animation`"scale""fade""slide"

On this page