{"$schema":"https://ui.shadcn.com/schema/registry-item.json","name":"command-palette","type":"registry:block","title":"Command palette","description":"A complete keyboard driven action surface with search, grouped results, and shortcuts.","categories":["blocks"],"dependencies":["lucide-react","motion"],"registryDependencies":["https://uiarc.dev/r/arc-motion-tokens.json"],"files":[{"path":"registry/components/command-palette/command-palette.tsx","type":"registry:component","target":"@components/arc/command-palette/command-palette.tsx","content":"\"use client\";\n\nimport { useEffect, useId, useLayoutEffect, useMemo, useRef, useState } from \"react\";\nimport type { KeyboardEvent as ReactKeyboardEvent, ReactNode } from \"react\";\nimport { AnimatePresence, animate, motion, useMotionValue, useReducedMotion } from \"motion/react\";\nimport type { Transition, ValueAnimationTransition, Variants } from \"motion/react\";\nimport { Command as CommandIcon, Search, X } from \"lucide-react\";\nimport { motionTokens } from \"../lib/motion-tokens\";\nimport styles from \"./command-palette.module.css\";\n\nexport interface CommandItem { id: string; label: string; description?: string; group?: string; keywords?: string[]; icon?: ReactNode; shortcut?: string; }\nexport interface CommandPaletteProps { items: CommandItem[]; placeholder?: string; onSelect?: (item: CommandItem) => void; onClose?: () => void; label?: string; /** Focus the search field on mount, for a palette that opens on demand. */ autoFocus?: boolean; }\n\nconst enter: Transition = { duration: motionTokens.duration.standard, ease: [...motionTokens.ease.enter] };\nconst leave: Transition = { duration: motionTokens.duration.instant, ease: [...motionTokens.ease.standard] };\nconst GLIDE_ROWS = 6;\n/** Rows fade out while the rest glide into their place; when the list snaps they leave at once so nothing overlaps the new rows. */\nconst rowExit: Variants = { exit: (glide: boolean) => ({ opacity: 0, transition: glide ? leave : { duration: 0 } }) };\n\ntype Range = [start: number, end: number];\ninterface Ranked { item: CommandItem; score: number; ranges: Range[]; order: number }\n\n/** The first index where `word` starts a word of `text`, or -1. */\nfunction wordStart(text: string, word: string) {\n  for (let at = text.indexOf(word); at !== -1; at = text.indexOf(word, at + 1)) if (at === 0 || !/[\\p{L}\\p{N}]/u.test(text.charAt(at - 1))) return at;\n  return -1;\n}\n/** Letters typed in order, starting at a word, within a short span: \"dup pr\" finds \"Duplicate project\", \"shpr\" finds \"Share project\". */\nfunction subsequence(text: string, word: string): Range[] | null {\n  if (word.length < 2) return null;\n  for (let start = text.indexOf(word.charAt(0)); start !== -1; start = text.indexOf(word.charAt(0), start + 1)) {\n    if (start > 0 && /[\\p{L}\\p{N}]/u.test(text.charAt(start - 1))) continue;\n    const ranges: Range[] = [[start, start + 1]];\n    let at = start;\n    for (let i = 1; i < word.length && at !== -1; i++) {\n      at = text.indexOf(word.charAt(i), at + 1);\n      if (at === -1) break;\n      const last = ranges[ranges.length - 1];\n      if (last && last[1] === at) last[1] = at + 1; else ranges.push([at, at + 1]);\n    }\n    if (at !== -1 && at - start < word.length * 3) return ranges;\n  }\n  return null;\n}\n/** Scores one search word: the label counts most and a prefix ranks first. Descriptions and keywords match only at a word start, so \"test\" never finds \"latest\". */\nfunction scoreWord(item: CommandItem, label: string, word: string): { score: number; ranges: Range[] } | null {\n  const inLabel = wordStart(label, word);\n  if (inLabel === 0) return { score: 100, ranges: [[0, word.length]] };\n  if (inLabel > 0) return { score: 80, ranges: [[inLabel, inLabel + word.length]] };\n  const inside = word.length >= 3 ? label.indexOf(word) : -1;\n  if (inside > 0) return { score: 50, ranges: [[inside, inside + word.length]] };\n  if (item.keywords?.some(keyword => wordStart(keyword.toLowerCase(), word) !== -1)) return { score: 40, ranges: [] };\n  if (item.description && wordStart(item.description.toLowerCase(), word) !== -1) return { score: 25, ranges: [] };\n  const loose = subsequence(label, word);\n  return loose ? { score: 10, ranges: loose } : null;\n}\n/** Every word of the query has to match somewhere; the best matches come first, ties keep the order they were given in. */\nfunction rank(items: CommandItem[], query: string): Ranked[] {\n  const words = query.trim().toLowerCase().split(/\\s+/).filter(Boolean);\n  if (!words.length) return items.map((item, order) => ({ item, score: 0, ranges: [], order }));\n  const ranked: Ranked[] = [];\n  items.forEach((item, order) => {\n    const label = item.label.toLowerCase();\n    let score = 0;\n    const ranges: Range[] = [];\n    for (const word of words) {\n      const match = scoreWord(item, label, word);\n      if (!match) return;\n      score += match.score;\n      ranges.push(...match.ranges);\n    }\n    ranked.push({ item, score, ranges, order });\n  });\n  return ranked.sort((a, b) => b.score - a.score || a.order - b.order);\n}\n/** The label with its matched letters in medium weight. */\nfunction Highlighted({ text, ranges }: { text: string; ranges: Range[] }) {\n  if (!ranges.length) return text;\n  const marked = new Array<boolean>(text.length).fill(false);\n  for (const [start, end] of ranges) for (let i = start; i < end; i++) marked[i] = true;\n  const parts: ReactNode[] = [];\n  for (let i = 0; i < text.length;) {\n    let end = i;\n    while (end < text.length && marked[end] === marked[i]) end++;\n    parts.push(marked[i] ? <mark key={i} className={styles.match}>{text.slice(i, end)}</mark> : text.slice(i, end));\n    i = end;\n  }\n  return parts;\n}\n/** \"⌘ K\" or \"Shift+D\" becomes one keycap per key. */\nconst keysOf = (shortcut: string) => shortcut.split(/\\s+|\\+(?=.)/).filter(Boolean);\n\nexport function CommandPalette({ items, placeholder = \"Search commands\", onSelect, onClose, label = \"Command palette\", autoFocus = false }: CommandPaletteProps) {\n  const inputId = useId();\n  const [query, setQuery] = useState(\"\");\n  const [activeIndex, setActiveIndex] = useState<number | null>(null);\n  const [listHeight, setListHeight] = useState<number | \"auto\">(\"auto\");\n  const reduced = useReducedMotion();\n  const inputRef = useRef<HTMLInputElement>(null);\n  const listRef = useRef<HTMLDivElement>(null);\n  const lastPointer = useRef({ x: -1, y: -1 });\n  const highlightShown = useRef(false);\n  /** Keyboard moves land the highlight instantly; only pointer moves glide. */\n  const keyboardMove = useRef(false);\n  const highlightY = useMotionValue(0);\n  const highlightHeight = useMotionValue(0);\n  const highlightOpacity = useMotionValue(0);\n  // Groups follow their best match, and the list reads top to bottom in that order, so arrow keys walk what you see.\n  const { groupedItems, filtered, rangesById } = useMemo(() => {\n    const grouped = new Map<string, Ranked[]>();\n    for (const entry of rank(items, query)) {\n      const group = entry.item.group ?? \"Actions\";\n      grouped.set(group, [...(grouped.get(group) ?? []), entry]);\n    }\n    const flat: CommandItem[] = [];\n    const groups = [...grouped.entries()].map(([group, entries]) => [group, entries.map(({ item }) => ({ item, index: flat.push(item) - 1 }))] as const);\n    return { groupedItems: groups, filtered: flat, rangesById: new Map([...grouped.values()].flat().map(entry => [entry.item.id, entry.ranges])) };\n  }, [items, query]);\n  const [shift, setShift] = useState({ list: filtered, glide: true });\n  if (shift.list !== filtered) {\n    const before = new Map(shift.list.map((item, index) => [item.id, index]));\n    setShift({ list: filtered, glide: filtered.every((item, index) => Math.abs((before.get(item.id) ?? index) - index) <= GLIDE_ROWS) });\n  }\n  const glide = shift.glide && !reduced;\n  // The first result is active until the pointer or the arrow keys pick another, so Enter always has a target.\n  const safeActiveIndex = filtered.length ? Math.min(activeIndex ?? 0, filtered.length - 1) : -1;\n  const activeId = filtered[safeActiveIndex]?.id;\n\n  useEffect(() => {\n    if (autoFocus) inputRef.current?.focus({ preventScroll: true });\n  }, [autoFocus]);\n\n  useEffect(() => {\n    const focusShortcut = (event: KeyboardEvent) => {\n      if ((event.metaKey || event.ctrlKey) && event.key.toLowerCase() === \"k\") {\n        event.preventDefault();\n        inputRef.current?.focus();\n      }\n    };\n    document.addEventListener(\"keydown\", focusShortcut);\n    return () => document.removeEventListener(\"keydown\", focusShortcut);\n  }, []);\n\n  // The results frame follows the list height, so filtering closes or opens the gap instead of snapping.\n  useLayoutEffect(() => {\n    const list = listRef.current;\n    if (!list) return;\n    const observer = new ResizeObserver(([entry]) => setListHeight(Math.round(entry?.borderBoxSize?.[0]?.blockSize ?? list.offsetHeight)));\n    observer.observe(list);\n    return () => observer.disconnect();\n  }, []);\n\n  // One highlight follows the active result: it glides on a snappy spring for the pointer, lands instantly for arrow keys, and fades in when it first appears.\n  useLayoutEffect(() => {\n    const node = activeId ? document.getElementById(`${inputId}-${activeId}`) : null;\n    if (!node) {\n      highlightShown.current = false;\n      animate(highlightOpacity, 0, { duration: reduced ? 0 : motionTokens.duration.instant });\n      return;\n    }\n    const move: ValueAnimationTransition<number> = !highlightShown.current || reduced || keyboardMove.current ? { duration: 0 } : motionTokens.spring.snappy;\n    // Rows sit inside positioned groups, so their offset is summed up to the list (layout transforms stay out of it).\n    let top = 0;\n    for (let element: HTMLElement | null = node; element && element !== listRef.current; element = element.offsetParent as HTMLElement | null) top += element.offsetTop + (element === node ? 0 : element.clientTop);\n    animate(highlightY, top, move);\n    animate(highlightHeight, node.offsetHeight, move);\n    animate(highlightOpacity, 1, { duration: reduced ? 0 : motionTokens.duration.instant });\n    highlightShown.current = true;\n  }, [activeId, filtered, inputId, reduced, highlightY, highlightHeight, highlightOpacity]);\n\n  useEffect(() => {\n    if (!activeId) return;\n    document.getElementById(`${inputId}-${activeId}`)?.scrollIntoView({ block: \"nearest\" });\n  }, [activeId, inputId]);\n\n  function choose(item: CommandItem) {\n    onSelect?.(item);\n    setQuery(\"\");\n    setActiveIndex(null);\n    inputRef.current?.focus();\n  }\n  function handleKeyDown(event: ReactKeyboardEvent<HTMLInputElement>) {\n    if ([\"ArrowDown\", \"ArrowUp\", \"Home\", \"End\"].includes(event.key)) keyboardMove.current = true;\n    if (event.key === \"ArrowDown\") { event.preventDefault(); setActiveIndex(Math.min(safeActiveIndex + 1, Math.max(filtered.length - 1, 0))); }\n    if (event.key === \"ArrowUp\") { event.preventDefault(); setActiveIndex(Math.max(safeActiveIndex - 1, 0)); }\n    if (event.key === \"Home\") { event.preventDefault(); setActiveIndex(0); }\n    if (event.key === \"End\") { event.preventDefault(); setActiveIndex(Math.max(filtered.length - 1, 0)); }\n    // Enter runs the highlighted result; after typing, with nothing highlighted yet, it runs the top match.\n    const target = filtered[safeActiveIndex];\n    if (event.key === \"Enter\" && target) { event.preventDefault(); choose(target); }\n    if (event.key === \"Escape\") {\n      event.preventDefault();\n      if (query) { setQuery(\"\"); setActiveIndex(null); }\n      else onClose?.();\n    }\n  }\n\n  return <motion.div className={styles.palette} initial={reduced ? false : { opacity: 0, y: 6, scale: .98 }} animate={{ opacity: 1, y: 0, scale: 1 }} transition={reduced ? { duration: 0 } : { default: motionTokens.spring.smooth, opacity: { duration: motionTokens.duration.fast, ease: [...motionTokens.ease.enter] } }}>\n    <div className={styles.searchRow}>\n      <span className={styles.searchIcon}><Search width={18} height={18} strokeWidth={1.75} aria-hidden=\"true\"/></span>\n      <label className={styles.visuallyHidden} htmlFor={inputId}>{label}</label>\n      <input ref={inputRef} id={inputId} role=\"combobox\" aria-autocomplete=\"list\" aria-expanded=\"true\" aria-controls={`${inputId}-results`} aria-activedescendant={activeId ? `${inputId}-${activeId}` : undefined} value={query} onChange={event => { setQuery(event.target.value); setActiveIndex(null); }} onKeyDown={handleKeyDown} placeholder={placeholder} autoComplete=\"off\"/>\n      <AnimatePresence mode=\"popLayout\" initial={false}>\n        {query ? <motion.button key=\"clear\" className={styles.clearButton} type=\"button\" aria-label=\"Clear search\" onClick={() => { setQuery(\"\"); setActiveIndex(null); inputRef.current?.focus(); }} initial={reduced ? false : { opacity: 0, scale: .7, filter: `blur(${motionTokens.blur.subtle}px)` }} animate={{ opacity: 1, scale: 1, filter: \"blur(0px)\" }} exit={reduced ? { opacity: 0, transition: { duration: 0 } } : { opacity: 0, scale: .7, filter: `blur(${motionTokens.blur.subtle}px)`, transition: leave }} transition={reduced ? { duration: 0 } : { default: motionTokens.spring.snappy, opacity: { duration: motionTokens.duration.instant } }}><X width={15} height={15} aria-hidden=\"true\"/></motion.button> : null}\n      </AnimatePresence>\n      {onClose ? <button className={styles.closeButton} type=\"button\" aria-label=\"Close command palette\" onClick={onClose}>Esc</button> : null}\n      <kbd className={styles.commandKey}>⌘ K</kbd>\n    </div>\n    <motion.div className={styles.resultsFrame} initial={false} animate={{ height: listHeight }} transition={reduced ? { duration: 0 } : motionTokens.spring.smooth}>\n      <motion.div ref={listRef} layoutScroll id={`${inputId}-results`} className={styles.results} role=\"listbox\" aria-label=\"Command results\">\n        <motion.span className={styles.highlight} style={{ y: highlightY, height: highlightHeight, opacity: highlightOpacity }} aria-hidden=\"true\"/>\n        {/* Results leave before the empty state arrives, so the frame makes one height change instead of two. */}\n        <AnimatePresence mode=\"wait\" initial={false}>\n          {filtered.length ? <motion.div key=\"results\" initial={reduced ? false : { opacity: 0 }} animate={{ opacity: 1 }} exit={reduced ? { opacity: 0, transition: { duration: 0 } } : { opacity: 0, transition: leave }} transition={enter}>\n            {/* Filtered-out rows pop out of the flow as they fade, so the rest glide up and the frame starts closing on the same keystroke. */}\n            <AnimatePresence mode=\"popLayout\" initial={false} custom={glide}>\n              {groupedItems.map(([group, entries]) => <motion.div layout={glide ? \"position\" : false} className={styles.group} role=\"group\" aria-label={group} key={group} variants={rowExit} initial={reduced ? false : { opacity: 0 }} animate={{ opacity: 1 }} exit=\"exit\" transition={reduced ? { duration: 0 } : { default: enter, layout: motionTokens.spring.smooth }}>\n                <span className={styles.groupHeading} aria-hidden=\"true\">{group}</span>\n                <AnimatePresence mode=\"popLayout\" initial={false} custom={glide}>{entries.map(({ item, index }) => <motion.button layout={glide ? \"position\" : false} key={item.id} id={`${inputId}-${item.id}`} className={`${styles.result} ${index === safeActiveIndex ? styles.activeResult : \"\"}`} type=\"button\" role=\"option\" aria-selected={index === safeActiveIndex} onClick={() => choose(item)} onPointerMove={event => {\n                  // Ignore the synthetic moves browsers send while the list scrolls under a still pointer.\n                  if (event.clientX === lastPointer.current.x && event.clientY === lastPointer.current.y) return;\n                  lastPointer.current = { x: event.clientX, y: event.clientY };\n                  keyboardMove.current = false;\n                  if (index !== safeActiveIndex) setActiveIndex(index);\n                }} variants={rowExit} initial={reduced ? false : { opacity: 0 }} animate={{ opacity: 1 }} exit=\"exit\" transition={reduced ? { duration: 0 } : { default: enter, layout: motionTokens.spring.smooth }}><span className={styles.itemIcon} aria-hidden=\"true\">{item.icon ?? <CommandIcon width={16} height={16}/>}</span><span className={styles.resultCopy}><span className={styles.resultLabel}><Highlighted text={item.label} ranges={rangesById.get(item.id) ?? []}/></span>{item.description && <span className={styles.resultDescription}>{item.description}</span>}</span>{item.shortcut && <span className={styles.shortcut}>{keysOf(item.shortcut).map((key, i) => <kbd key={i}>{key}</kbd>)}</span>}</motion.button>)}</AnimatePresence>\n              </motion.div>)}\n            </AnimatePresence>\n          </motion.div> : <motion.div key=\"empty\" className={styles.empty} initial={reduced ? false : { opacity: 0, y: 6, filter: `blur(${motionTokens.blur.subtle}px)` }} animate={{ opacity: 1, y: 0, filter: \"blur(0px)\" }} exit={reduced ? { opacity: 0, transition: { duration: 0 } } : { opacity: 0, y: -4, transition: leave }} transition={enter}><span><Search width={20} height={20} aria-hidden=\"true\"/></span><strong>No results for “{query.trim()}”</strong><small>Try a different word or clear the search.</small></motion.div>}\n        </AnimatePresence>\n      </motion.div>\n    </motion.div>\n    <span className={styles.visuallyHidden} role=\"status\" aria-live=\"polite\">{query.trim() ? filtered.length ? `${filtered.length} ${filtered.length === 1 ? \"result\" : \"results\"}` : \"No results\" : \"\"}</span>\n  </motion.div>;\n}\n\nexport default CommandPalette;\n"},{"path":"registry/components/command-palette/command-palette.module.css","type":"registry:component","target":"@components/arc/command-palette/command-palette.module.css","content":".palette {\n  width: 100%;\n  overflow: hidden;\n  border: 1px solid var(--border);\n  border-radius: var(--radius-panel);\n  background: var(--surface);\n  box-shadow: var(--shadow-floating);\n  transform-origin: top center;\n}\n\n.searchRow {\n  position: relative;\n  display: flex;\n  min-height: 54px;\n  align-items: center;\n  gap: 10px;\n  padding: 8px 14px;\n  border-bottom: 1px solid var(--border-subtle);\n  transition: background var(--duration-fast) var(--ease-standard);\n}\n\n.searchRow:focus-within { background: var(--surface-muted); }\n.searchIcon, .itemIcon { display: grid; flex: none; place-items: center; color: var(--text-muted); }\n.searchIcon { width: 22px; height: 22px; }\n.searchRow input { min-width: 0; flex: 1; border: 0; outline: 0; background: transparent; color: var(--foreground); font: inherit; font-size: var(--text-sm); }\n.searchRow input::placeholder { color: var(--text-muted); }\n.searchRow input:focus-visible { outline: none; }\n\n.commandKey {\n  display: inline-flex;\n  align-items: center;\n  justify-content: center;\n  flex: none;\n  border: 1px solid var(--border);\n  border-radius: 7px;\n  background: var(--surface-muted);\n  color: var(--text-muted);\n  font-family: inherit;\n  font-size: var(--text-xs);\n  font-weight: 500;\n  line-height: 1;\n  font-variant-numeric: tabular-nums;\n}\n\n.commandKey { min-width: 38px; height: 24px; padding: 0 6px; gap: 2px; }\n.clearButton { display: grid; width: 24px; height: 24px; flex: none; place-items: center; border: 0; border-radius: 7px; background: transparent; color: var(--text-muted); cursor: pointer; transition: color var(--duration-fast) var(--ease-standard), background-color var(--duration-fast) var(--ease-standard); }\n@media (hover: hover) and (pointer: fine) { .clearButton:hover, .closeButton:hover { background: var(--surface); color: var(--foreground); } }\n.clearButton:active, .closeButton:active { background: var(--surface); color: var(--foreground); }\n.closeButton { display: grid; min-width: 27px; height: 24px; flex: none; place-items: center; border: 1px solid var(--border-subtle); border-radius: 7px; background: transparent; color: var(--text-muted); padding: 0 6px; font: inherit; font-size: var(--text-xs); font-weight: 500; line-height: 1; cursor: pointer; transition: color var(--duration-fast) var(--ease-standard), background-color var(--duration-fast) var(--ease-standard), transform var(--duration-fast) var(--ease-standard); }\n@media (prefers-reduced-motion: no-preference) { .closeButton:active { transform: scale(.96); } }\n\n/* The frame animates to the list height; the list keeps its own scroll. */\n.resultsFrame { overflow: hidden; }\n.results { position: relative; max-height: 342px; overflow: auto; padding: 6px 8px; }\n.highlight { position: absolute; top: 0; right: 8px; left: 8px; border-radius: 8px; background: var(--surface-muted); opacity: 0; pointer-events: none; }\n/* Groups are positioned so a row that pops out of the flow is placed against the same box it was measured in, even mid-glide. */\n.group { position: relative; }\n.group + .group { margin-top: 6px; }\n.groupHeading { display: block; padding: 8px 10px 4px; color: var(--text-muted); font-size: var(--text-xs); font-weight: 500; line-height: var(--leading-body); }\n\n/* One line per result: icon, the title, then its description, with any shortcut keys at the right edge. Every row is the same height. */\n.result { position: relative; display: flex; width: 100%; height: 38px; align-items: center; gap: 10px; border: 0; border-radius: 8px; padding: 0 10px; background: transparent; color: var(--foreground); font: inherit; text-align: left; cursor: pointer; }\n/* The active row is drawn by the shared highlight; the row itself only brings its icon up to full contrast. */\n.itemIcon { display: grid; width: 16px; height: 16px; flex: none; place-items: center; color: var(--text-muted); transition: color var(--duration-fast) var(--ease-standard); }\n.itemIcon svg { width: 16px; height: 16px; }\n.activeResult .itemIcon { color: var(--foreground); }\n.resultCopy { display: flex; min-width: 0; flex: 1; align-items: baseline; gap: 8px; }\n.resultLabel, .resultDescription { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }\n.resultLabel { flex: none; max-width: 100%; color: var(--foreground); font-size: var(--text-sm); font-weight: 400; }\n/* The letters that matched the query carry the weight; the rest of the label stays regular. */\n.match { background: none; color: inherit; font-weight: 500; }\n.resultDescription { min-width: 0; color: var(--text-secondary); font-size: var(--text-xs); }\n.shortcut { display: flex; flex: none; gap: 3px; margin-left: auto; }\n.shortcut kbd { display: inline-grid; min-width: 20px; height: 20px; place-items: center; padding: 0 5px; border: 1px solid var(--border); border-radius: 5px; background: var(--surface); color: var(--text-muted); font-family: inherit; font-size: 11px; font-weight: 500; line-height: 1; }\n.empty { display: grid; justify-items: center; gap: 4px; padding: 26px 12px 28px; text-align: center; }\n.empty > span { display: grid; width: 32px; height: 32px; place-items: center; margin-bottom: 5px; color: var(--text-muted); }\n.empty strong { max-width: 100%; overflow: hidden; font-size: var(--text-sm); font-weight: 500; text-overflow: ellipsis; white-space: nowrap; }\n.empty small { color: var(--text-secondary); font-size: var(--text-xs); }\n.visuallyHidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }\n\n@media (max-width: 480px) {\n  .searchRow { gap: 8px; padding: 8px 11px; }\n  .results { padding: 6px; }\n  .highlight { right: 6px; left: 6px; }\n  .result { gap: 8px; }\n  .shortcut, .commandKey { display: none; }\n  }\n\n@media (max-width: 340px) {\n    .result { padding-inline: 6px; }\n}\n\n@media (prefers-reduced-motion: reduce) {\n  .searchRow, .itemIcon, .clearButton, .closeButton { transition: none; }\n}\n\n/* AnimatePresence pops the outgoing .group out of flow at its measured offset; its margin would then move it as it leaves. */\n.group[data-motion-pop-id] { margin: 0; }\n"}],"docs":"Use it for product wide actions and navigation. Provide meaningful groups, icons, keyboard shortcuts, and handlers.","meta":{"tier":"free","kind":"block","builtFrom":["Search","Keyboard navigation","Action list"],"docs":"https://uiarc.dev/components/blocks/command-palette"}}