Skip to content
Nizivo UI

Motion

Durations, easings and distances, with their reduced-motion values.

Motion tokens swap to their reduced values under prefers-reduced-motion: reduce, or inside any element with data-nz-motion="reduce". Reduced motion keeps short opacity fades and removes movement. The spring easings are linear() curves generated from spring parameters.

Durations

TokenDefaultReduced
--nz-duration-base220ms120ms
--nz-duration-chart-draw700ms0ms
--nz-duration-count-up900ms0ms
--nz-duration-fade140ms120ms
--nz-duration-fast140ms0ms
--nz-duration-instant80ms0ms
--nz-duration-pulse2000ms0ms
--nz-duration-slow320ms120ms
--nz-duration-slower480ms160ms
--nz-duration-spin800ms0ms
--nz-duration-spring493ms120ms
--nz-duration-spring-soft702ms120ms
--nz-stagger-item40ms0ms

Easings

TokenDefaultReducedCurve
--nz-easing-entercubic-bezier(0, 0, 0, 1)linear
--nz-easing-exitcubic-bezier(0.3, 0, 1, 1)linear
--nz-easing-standardcubic-bezier(0.2, 0, 0, 1)linear
--nz-easing-springlinear(0, 0.007 1.5%, 0.027 3.1%, 0.06 4.8%, 0.108 6.7%, 0.211 10%, 0.559 20.2%, 0.658 23.5%, 0.742 26.7%, 0.811 29.8%, 0.868 32.9%, 0.916 36.1%, 0.954 39.4%, 0.985 43%, 1.007 46.9%, 1.022 51.1%, 1.029 55.9%, 1.029 63.7%, 1)linear
--nz-easing-spring-softlinear(0, 0.006 1.2%, 0.021 2.4%, 0.083 5.2%, 0.161 7.8%, 0.462 17%, 0.555 20.3%, 0.637 23.6%, 0.706 26.9%, 0.766 30.3%, 0.817 33.9%, 0.86 37.7%, 0.898 42.1%, 0.929 47%, 0.953 52.5%, 0.971 58.7%, 0.991 73.9%, 1)linear

Distances, scales and effects

TokenDefaultReduced
--nz-distance-float0.5rem0rem
--nz-distance-lift0.25rem0rem
--nz-distance-reveal0.75rem0rem
--nz-scale-enter0.961
--nz-scale-hover1.021
--nz-scale-press0.981
--nz-magnetic-pull0.375rem0rem
--nz-tilt-max-deg60

Chart draw

Charts draw in once, when they first render, on --nz-duration-chart-draw (700 ms) with --nz-easing-standard. The draw is pure CSS, so a server-rendered chart with no JavaScript draws too:

  • AreaChart and Sparkline (any mark layer with ChartFrame's shared nz-chart-svg class): a clip-path sweep reveals the plot from the start of the x axis to its end (the nz-chart-reveal keyframes).
  • BarChart: each bar grows from the baseline, again by clip-path (nz-bar-chart-grow).
  • DonutChart: the ring fades in and settles from 92 % of its size (nz-donut-chart-reveal).

Under Reduced motion the token is 0 ms, so the chart renders at once, already drawn: the same clip, size and opacity the 700 ms draw ends on. A browser test checks both in Chromium, Firefox and WebKit. See the draw on the AreaChart, BarChart and DonutChart pages: reload one to watch it again.

On this page