import { snippetOf } from '~/chrome/lib/codegen'; import { CopyButton, CopyLine } from '~/chrome/ui/copy'; import { ErrorBoundary } from '~/chrome/ui/error-boundary'; import { importLineOf } from '~/chrome/lib/import-line'; import { Matrix } from '~/chrome/ui/matrix'; import { Playground } from '~/chrome/ui/playground'; import { usePlaygroundProps } from '~/chrome/lib/prop-params'; import { PropTable, SpecTableView } from '~/chrome/ui/tables'; import { FigmaPanel } from '../figma/figma-panel'; import { useGroupLabel, useMessages } from '../i18n'; import { propsFor } from '../registry/props'; import type { Composition as CompositionSpec, Entry } from '../registry/types'; /** * A hand-built example and the code for it. * * The tree is rendered once and used twice — shown, and serialised by the copy * button — so the snippet carries whatever the example actually contains: the * nested parts, and the icon imports for a `