LayerwiseLayerwise
  • Features
  • Pricing
  • Templates
  • Docs
DownloadDownload
FeaturesPricingTemplatesDocsAI Website BuilderVibe CodingPersonal Software
DownloadDownload
  1. Glossary
  2. /
  3. Motion principles

Frequency of use

Also called animation frequency

The rule that the more often people see an animation, the shorter and subtler it should be, so everyday actions never feel slow.

import { useEffect, useState } from 'react';
import { Dialog } from '@base-ui/react/dialog';

const ACTIONS = [
  'New project',
  'Open settings',
  'Invite people',
  'Switch theme'
];

type CommandMenuProps = { onRun: (action: string) => void };

export function CommandMenu({ onRun }: CommandMenuProps) {
  const [open, setOpen] = useState(false);

  useEffect(() => {
    function onKeyDown(event: KeyboardEvent) {
      if (event.key === 'k' && (event.metaKey || event.ctrlKey)) {
        event.preventDefault();
        setOpen((value) => !value);
      }
    }
    window.addEventListener('keydown', onKeyDown);
    return () => window.removeEventListener('keydown', onKeyDown);
  }, []);

  return (
    <Dialog.Root open={open} onOpenChange={setOpen}>
      <Dialog.Trigger className='rounded-lg border px-3 py-1.5 text-sm text-muted-foreground hover:bg-muted'>
        Quick actions <kbd className='ml-2 text-xs'>⌘K</kbd>
      </Dialog.Trigger>
      <Dialog.Portal>
        <Dialog.Backdrop className='fixed inset-0 bg-black/20 transition-opacity duration-150 data-ending-style:opacity-0 data-ending-style:duration-100 data-starting-style:opacity-0' />
        {/* Opened dozens of times a day, so it stays quick and quiet:
            a 150ms fade with a barely visible scale in, a 100ms fade out. */}
        <Dialog.Popup className='fixed top-24 left-1/2 w-96 max-w-[calc(100vw-2rem)] -translate-x-1/2 rounded-xl border bg-background p-2 shadow-xl outline-none transition-[opacity,scale] duration-150 ease-out data-ending-style:opacity-0 data-ending-style:duration-100 data-starting-style:scale-[0.98] data-starting-style:opacity-0'>
          <Dialog.Title className='px-3 py-2 text-xs font-medium text-muted-foreground'>
            Quick actions
          </Dialog.Title>
          {ACTIONS.map((action) => (
            <Dialog.Close
              key={action}
              onClick={() => onRun(action)}
              className='block w-full rounded-lg px-3 py-2 text-left text-sm outline-none hover:bg-muted focus-visible:bg-muted'
            >
              {action}
            </Dialog.Close>
          ))}
        </Dialog.Popup>
      </Dialog.Portal>
    </Dialog.Root>
  );
}
Make the command palette feel instant because people open it constantly: fade it in and scale it from 0.98 to 1 over 150ms with an ease-out curve, and close it with a 100ms fade. Keep the longer, bouncy celebration animation only for the one-time onboarding finish screen.

Paste into Layerwise or any AI coding tool.

Frequency of use explained

Frequency of use is a guideline for deciding how much motion an interaction gets. Something people see once, like an onboarding screen or a launch celebration, can afford a longer, more expressive animation. Something people trigger dozens of times a day, like a command menu, a dropdown, or switching tabs, should be quick and quiet.

A 600ms bounce is delightful the first time. By the 50th time that day it adds up to 30 seconds of waiting, and people start to feel the interface is slow. For frequent actions, aim for 100 to 200ms with a simple fade or a small scale, or no animation at all for menus opened with a keyboard shortcut.

An easy way to decide: list how often each interaction happens, then give the rare moments personality and keep the frequent ones fast and consistent.

Often confused with

Duration
Duration is how long one animation lasts. Frequency of use is a reason to pick a shorter or longer duration.

Related terms

All terms

Duration

The length of time an animation takes from start to finish, usually set in milliseconds. It decides whether motion feels snappy or sluggish.

Purposeful animation

Animation used only where it helps people notice a change, follow where something went, or understand what just happened.

Command palette

A search box that opens with a shortcut like ⌘K and lets you find and run any command or page by typing a few letters.

Micro-interaction

A small moment of feedback around a single action, like a heart that bursts when tapped or a copy icon that turns into a checkmark.

Build it with Layerwise

Describe your app, watch it run in a live preview, and publish it with a database, storage, and sign-in built in.

DownloadDownloadRead the docs
LayerwiseLayerwise

Build full-stack web apps in minutes with AI.

Product

  • Features
  • Pricing
  • Download
  • Templates

Solutions

  • AI Website Builder
  • Vibe Coding
  • Personal Software

Resources

  • Documentation
  • Changelog
  • Blog
  • Vibe Coding Glossary
  • llms.txt
  • llms-full.txt

Company

  • About
  • Contact

Legal

  • Privacy
  • Analytics Privacy
  • Terms
  • Security
  • Abuse

© 2026 Layerwise. All rights reserved.

Entrances & exits

  • Fade in
  • Slide in
  • Scale in
  • Pop in
  • Blur in
  • Reveal animation
  • Enter and exit animations

Timing & sequencing

  • Duration
  • Delay
  • Keyframes
  • Tweening
  • Stagger
  • Orchestration
  • Fill mode
  • Stepped animation
  • Looping animation
  • Yoyo animation

Easing

  • Easing
  • Linear easing
  • Ease-in
  • Ease-out
  • Ease-in-out
  • Cubic-bezier
  • Asymmetric easing
  • Overshoot easing

Springs & physics

  • Spring animation
  • Stiffness
  • Damping
  • Mass
  • Bounce
  • Velocity
  • Momentum
  • Interruptible animation
  • Rubber-banding

Transforms

  • Translate
  • Scale
  • Rotate
  • Skew
  • 3D flip
  • Perspective
  • Transform origin
  • Origin-aware animation

State transitions

  • Crossfade
  • Morph
  • Shared element transition
  • Layout animation
  • Height auto animation
  • Direction-aware transition
  • Continuity transition
  • Page transition
  • View Transitions API

Scroll effects

  • Scroll reveal
  • Scroll-driven animation
  • Parallax scrolling
  • Scrollytelling
  • Scroll pinning
  • Horizontal scroll section
  • Scroll progress bar
  • Scroll snap
  • Smooth scrolling

Interaction feedback

  • Hover effect
  • Press feedback
  • Ripple effect
  • Shake animation
  • Hold to confirm
  • Drag gesture
  • Drag to reorder
  • Swipe to dismiss
  • Pull to refresh
  • Magnetic button
  • Custom cursor
  • 3D tilt card
  • Spotlight card

Text effects

  • Typewriter effect
  • Text scramble
  • Split text animation
  • Text morph
  • Rotating words
  • Gradient text
  • Shimmer text
  • Number ticker
  • Tabular numbers
  • Underline animation

Loops & ambient motion

  • Marquee
  • Pulse animation
  • Float animation
  • Orbit animation
  • Idle animation
  • Particle background
  • Border beam
  • Confetti
  • Animated gradient

Visual effects

  • Blur
  • Clip-path
  • Mask
  • Before/after slider
  • SVG line drawing
  • Lottie animation

Motion principles

  • Purposeful animation
  • Anticipation
  • Follow-through
  • Squash and stretch
  • Perceived performance
  • Frequency of use
  • Spatial consistency
  • Reduced motion

Animation performance

  • Frame rate (FPS)
  • Jank
  • GPU acceleration
  • will-change
  • Layout thrashing

Layout

  • Hero section
  • Above the fold
  • Sticky header
  • Sidebar
  • Bento grid
  • Card
  • Flexbox
  • CSS Grid
  • Padding vs margin
  • Responsive design
  • Container
  • Masonry layout
  • Split screen
  • Z-index
  • Overflow

Components

  • Button variants
  • Modal
  • Drawer
  • Popover
  • Tooltip
  • Dropdown menu
  • Context menu
  • Toast notification
  • Tabs
  • Segmented control
  • Accordion
  • Carousel
  • Command palette
  • Combobox
  • Toggle switch
  • Checkbox
  • Radio button
  • Date picker
  • Breadcrumb
  • Pagination
  • Infinite scroll
  • Badge
  • Avatar stack
  • Empty state
  • Skeleton screen
  • Spinner
  • Progress bar
  • Data table
  • Stepper
  • Floating label
  • Inline validation
  • Alert banner
  • Tag input

States & patterns

  • Interaction states
  • Focus ring
  • Loading state
  • Optimistic UI
  • Debounce
  • Lazy loading
  • Dark mode
  • Micro-interaction
  • Affordance
  • Undo
  • Drag and drop
  • Keyboard shortcut

Visual styles

  • Glassmorphism
  • Liquid glass
  • Neumorphism
  • Claymorphism
  • Neo-brutalism
  • Skeuomorphism
  • Flat design
  • Mesh gradient
  • Aurora background
  • Grain texture
  • Glow effect
  • Drop shadow
  • Border radius
  • Grid background
  • Typographic hierarchy
  • Accent color
  • Color contrast

Vibe coding & AI

  • Vibe coding
  • Prompt
  • Context window
  • Token
  • AI agent
  • Tool call
  • Hallucination
  • Diff
  • Live preview
  • Checkpoint
  • Git commit
  • Deploy
  • Frontend and backend
  • API
  • Database
  • Rules file
  • MCP
  • Plan mode
  • Visual edit
Fancy 600ms
Search
New file
Open settings
Invite teammate
Opens
1
Waited
0.60s
Subtle 150ms
Search
New file
Open settings
Invite teammate
Opens
1
Waited
0.15s