Lawn

No dependencies
Code format

Install with shadcn

Needs a free account token. Get a token

npx shadcn@latest add @movin/slider-lawn

About this component

The track is a strip of lawn swaying in the breeze: the thumb mows it as it passes, the cut turf behind it is the fill, quick passes throw clippings, and dragging back lets the grass grow again.

Dependencies
None
Difficulty
Intermediate
Reduced motion
Respected
Theme
Light and dark
Follows page color-scheme

Triggers3

  • State change
  • Ambient
  • Fill

Techniques4

  • Keyframes
  • CSS transition
  • CSS variables
  • Transition delay stagger

Accessibility

Keyboard and screen readers

A native range input named Mowed; the grass is aria-hidden.

Reduced motion

The grass does not sway and no clippings fly.

Use it in anything you build, commercial and client work included. Licence

More sliders

See all
LoomGet code
MachGet code
MarblingGet code
PicketGet code