GFA Design System is still in development; component APIs and styles may change in upcoming releases.

Ask a Question
Language

Pinned item list

Pinned and unpinned sections with layout animation.

Preview & code

GFA Studio CLI · Coming soon

PINNED ITEMS

  • API contract draft

    Backend + web

  • Design review

    Thursday · 45 min

ALL ITEMS

  • Sprint planning

    Friday morning

  • Release notes

    v0.4.0

  • Usability study

    3 participant sessions

Installation

CLI

GFA Studio CLI — Coming soon

The `npx gfa-studio` installer is not published yet. Use Manual install below or download the artifact JSON.

Artifact JSON
https://ui.gkhn.dev/gfa/pinned-item-list.json

Manual

  1. Download the component source from https://ui.gkhn.dev/gfa/pinned-item-list.json (or copy from this repo: apps/web/src/blocks/gfa/pinned-item-list.tsx).
  2. Place it in your project (for example: ./src/blocks/gfa/pinned-item-list.tsx) and adjust imports/aliases.
  3. Ensure cn from @/lib/utils exists.
  4. Theme tokens and utilities should align with globals.css.

Step-by-step getting started guide →

Dependencies

Uses Motion (motion/react, LazyMotion, m, LayoutGroup, AnimatePresence), Lucide (Pin, PinOff), and GFA Button. Pin order and cross-list moves are client state; reproduce in your stack if you drop React.

Props

PropTypeDefaultDescription
itemsreadonly PinnedListItem[]Rows to render; each needs a stable string id.
defaultPinnedIdsreadonly string[]Uncontrolled mode: initial pinned ids (MRU order is applied internally).
pinnedIdsReadonlySet<string> | readonly string[]Controlled mode: current pinned set; keeps stack in sync via effect.
onPinnedChange(pinned: Set<string>) => voidFired after every pin change with the next pinned id set.
classNamestringOptional wrapper classes on the root layout.
emptyLabelstring"No items yet."Copy when items is empty.
pinAriaLabel(pinned: boolean) => stringAccessible name factory for the pin toggle (aria-label).
pinnedSectionTitlestring"PINNED ITEMS"Heading above the pinned list.
allSectionTitlestring"ALL ITEMS"Heading above the unpinned list.
pinnedEmptyLabelstringPlaceholder when nothing is pinned.
allEmptyLabelstringPlaceholder when every item is pinned.

Note: if light/dark looks wrong and you are not sure where it is controlled, this block has no theme prop. Adjust site-wide CSS variables and dark-mode toggles—often class .dark or [data-theme="dark"] on the document root or an ancestor.

Release note

Published
1 May 2026, 12:00(Türkiye — Ankara, Europe/Istanbul)
Last updated
12 May 2026, 15:00(Türkiye — Ankara, Europe/Istanbul)

Instants are stored as UTC (ISO) in the repo; above are the same moments in Türkiye local time. Ankara uses the Europe/Istanbul zone (same offset as İstanbul and the rest of the country).