Skip to content

Components / UI

UI

38 components · 25 at 0 B

Accordion, dialog, popover, tabs, carousel, drawer and toast, animated with @starting-style, allow-discrete and anchor positioning.

Zero JavaScript?

For this one, yes. The browser animates the height.

Keyboard?

Native: Tab, Enter, Space.

One at a time?

details name=, also native.

Native <details> items whose height animates open and closed, with an optional one-at-a-time rule the browser enforces.

newly · Chrome 131 · Firefox 143 · Safari 18.4click

Six line icons that morph into a second state: menu to close, plus to close, copy to check, play to pause, sun to moon, and a check that draws itself.

Chrome 52 · Firefox 97 · not Safariclick

Shows notifications arriving one at a time: the new one drops in at the top, the older ones are pushed down, and the oldest slides out.

newly · Chrome 125 · Firefox 129 · Safari 17.5alwaysload

a native select · options stagger in

A native select with an animated picker.

Chrome 138 · not Firefox · Safari 27click

A button whose arrow slides out on hover as a new one slides in.

every browserhover

A row of overlapping avatars with a count chip such as "+2 398".

every browserhover

A browser window around a screenshot or any content: the three lights, an address bar with a lock, optional tabs with one active.

every browseralways

A scroll-snap strip with previous/next buttons and dot markers that the browser generates and keeps in sync.

Chrome 135 · not Firefox · not Safariclickpointer

a tick that draws · one indeterminate

A checkbox whose tick is drawn.

every browserclick
npx astro add moonarc
pnpm astro add moonarc
bunx astro add moonarc

A code block with tabs (for example npm, pnpm, bun) and a copy button per panel.

every browserclick

A ⌘K command palette: a native modal dialog with an input and a ranked list of links.

newly · Chrome 135 · Firefox 144 · Safari 26.2click
npx astro add moonarc
click · check · back

A button that copies text to the clipboard: the icon turns into a check, the label says "Copied", and both come back after the ambient duration.

every browserclick

dialog

Native, animated, zero script.

Escape, backdrop click and focus are the browser's. The scale and the blur are @starting-style and allow-discrete.

A native modal that scales in over a blurred backdrop and scales out again, closes on Escape, the close button or a backdrop click, and traps focus, all handled by the browser.

newly · Chrome 135 · Firefox 144 · Safari 26.2click

A macOS-style dock: the tile under the pointer swells, its neighbours swell less, and the row pushes apart to make room.

every browserhover

drawer

Drag it down.

Follows the finger; on release, distance or velocity decides. Grab it mid-flight and it obeys.

A bottom sheet that slides up over a scrim and can be dragged closed: it follows the finger, and on release springs back or leaves depending on distance and velocity, interruptible mid-flight.

newly · Chrome 135 · Firefox 144 · Safari 26.2clickpointer

click · four declared sizes, one attribute

A black pill that changes shape with its state.

every browserclick
  • src
    • components
      • Hero.astro
      • Nav.astro
    • layouts
      • Base.astro
    • pages
      • index.astro
      • work.astro
  • astro.config.mjs
  • package.json

A project tree whose folders open with an animated height, a turning chevron and a folder glyph that tips open; rows can be lit up to say "this is the file you change".

newly · Chrome 131 · Firefox 143 · Safari 18.4click

Filter buttons over a grid of cards: the cards that stay slide to their new places, the ones that go fade out, the ones that return fade in.

newly · Chrome 137 · Firefox 144 · Safari 18.4click
The scene as a line drawingThe scene in colour

drag · click · ← →

Compares a before and an after image with a line you drag between them.

newly · Chrome 124 · Firefox 121 · Safari 16.5pointerclick
Study 1Study 2Study 3

click · grows from its thumbnail · ← →

A thumbnail gallery whose images open full size: the image grows out of its own thumbnail on a same-document view transition and returns to it on close, and ← → move through the set.

newly · Chrome 111 · Firefox 144 · Safari 18click

A link that shows a small card (image, title, one line, domain) after a moment on hover or focus, above everything, flipping when there is no room.

newly · Chrome 125 · Firefox 147 · Safari 26hover

A glass pane that blurs and tints whatever is behind it.

Chrome 76 · not Firefox · not Safarihover

one input · paste and autofill work

A one-time code in cells, from one native input.

every browserclick

A generic phone frame around a screenshot or any content, with three cut-outs (island, notch, punch), a home bar, and no logo, buttons or brand.

every browseralways

click · the pill slides on a view transition

A floating pill of links whose active pill glides to the page you chose.

newly · Chrome 125 · Firefox 147 · Safari 26clickhover

Raw bytes of JavaScript, from a production build, measured again for every change that can move them.

A popover that opens beside its trigger, flips when there is no room, closes on outside click or Escape, and animates in and out.

newly · Chrome 125 · Firefox 147 · Safari 26click

grows with the text · Enter sends · ⇧Enter breaks the line

The AI prompt box: a form with a textarea that grows with its content through field-sizing, a model select, an attachment button that is a real file input, and a send button that dims until something is typed and spins while the form carries data-pending.

newly · Chrome 123 · Firefox 152 · Safari 26.2click

A highlight sweeps across the body of a button on a loop; hover lifts it on the preset's hover travel and adds a ring, and focus draws the same.

every browseralwayshover
studio

hello@studio.example · Jakarta · 2026

Open the menu.

full · top · right: items in, reversed out

A burger that opens a full-screen menu (or a top sheet, or a side panel) whose items arrive one after another and leave in reverse.

newly · Chrome 135 · Firefox 144 · Safari 26.2click

idle → pending → done · one attribute

One submit button with four faces (idle, pending with a spinner, done with a check that draws itself, error) and a width that follows the label.

every browserclick

2026-09-28: fix: what the audit of every product found.

What shipped
sitescroll · close

The ribbon stays. The page moves.

Dismiss it and the content below slides up on the preset curve as a grid row folds.

An announcement ribbon that sticks to the top of the page and folds away when dismissed, the content below sliding up on the preset curve.

newly · Chrome 117 · Firefox 129 · Safari 17.4loadclick

a checkbox underneath · Space flips it

A toggle that springs.

every browserclick
npx astro add moonarc
pnpm astro add moonarc
npx shadcn@latest add …/r/tabs.json

Tabs with an indicator that slides to the selected one and panels that fade in.

every browserclick

click · the page changes from the button
ThemeScript · 473 B raw, inline in <head>

Cycles system → light → dark, and the page changes theme through a circle that grows from the click, on a same-document view transition.

newly · Chrome 111 · Firefox 144 · Safari 18click

Notifications that slide in, stack behind each other, push up as new ones arrive, and expand into a list on hover.

newly · Chrome 117 · Firefox 129 · Safari 17.5clickhover

hints take turns · Enter sends · the words blur away

Placeholders that take turns, and text that blurs away on submit.

newly · Chrome 125 · Firefox 128 · Safari 16.4clickalways

click · morphs open

A poster with a breathing play button that opens the video in a dialog: a file with native controls, or an embed.

newly · Chrome 135 · Firefox 144 · Safari 26.2click