Skip to content
nexubDesign System
v2.4.0

Components · Motion

Scale

StableSince v0.0.1

Scales content in/out from its center.

import { Scale } from '@nexub/react';

Examples

Default

Toggle

Props

Props
PropTypeDefaultDescription
inrequiredboolean—When true, scales content in from 0 to 1. When false, scales it back down to 0.
duration'instant' | 'fast' | 'normal' | 'slow' | 'slower''normal'Controls the animation speed using the design token scale.
easing'linear' | 'in' | 'out' | 'in-out' | 'out-expo' | 'spring''out'Easing curve applied to the animation.
unmountOnExitbooleanfalseRemoves the element from the DOM after the exit animation completes.
asReact.ElementType'div'The HTML element or component to render as the wrapper.
childrenrequiredReact.ReactNode—Content to animate.

On iOS & Android