Box Reveal

An animated box reveal effect with customizable colors, duration, and delay.

Install using CLI

npm
pnpm
bun
yarn
npx shadcn-vue@latest add "https://inspira-ui.com/r/box-reveal.json"

Install Manually

Copy and paste the following code

BoxReveal.vue

API

Prop NameTypeDefaultDescription
colorstring"#5046e6"Background color of the reveal box.
durationnumber0.5Duration of the reveal animation in seconds.
delaynumber0.25Delay before the reveal animation starts in seconds.
classstring""Additional CSS classes for custom styling.

Features

  • Box Reveal Animation: Creates a sliding box reveal effect with smooth transitions.
  • Customizable Animation: Control the animation timing with the duration and delay props.
  • Slot-Based Content: Supports default slot content that appears once the reveal animation completes.
  • Custom Background Color: Easily customize the box's background color using the color prop.

Credits