Animated Buttons
Animated button components for fill, directional and label-reveal interactions.
These components retain the standard Siteplane interaction contract and replace generic scale feedback with one focused custom animation.
Installation
pnpm dlx shadcn@4.16.1 add @siteplane/animated-buttonsFill Sweep
Use FillSweepButton for a compact call to action where the hover transition can carry a little more emphasis without changing the control's geometry.
Fill Sweep
A token-driven fill layer sweeps across the reusable button without adding a second press animation.
Expanding Arrow
Use ExpandingArrowButton for a directional action such as learning more or continuing to the next view. The control keeps a stable outer width while its leading surface grows.
Expanding Arrow
The leading surface grows across the control while the label and arrow keep their semantic button behavior.
Expanding Logout
Use ExpandingLogoutButton when an icon-only action benefits from revealing its label on pointer hover. The component reserves the full label width and expands around its fixed center, so nearby content does not jump.
Expanding Logout
The icon action expands around a fixed center while its label is revealed.
Sizing
ExpandingArrowButton and ExpandingLogoutButton inherit sm, default, lg, or xl from SiteplaneUIProvider. Pass size directly when one control needs a local override. FillSweepButton uses the same standard Button sizing contract.
Accessibility
The visible controls remain real buttons with focus styles and accessible names. Hover is additional feedback only; the action does not depend on the animation, and prefers-reduced-motion removes the transitions.