# Family glyphs

> One glyph per family, drawn on one grid, for family types and the glyph option.

A shadcn/ui block from the [@tealmac](https://ui.tealmac.com/?utm_source=shadcn.exchange) registry, listed on [shadcn.exchange](https://shadcn.exchange/r/tealmac/file-type-family-glyphs).

- Page, with a live preview: https://shadcn.exchange/r/tealmac/file-type-family-glyphs
- Screenshot: https://shadcn.exchange/shot/tealmac/file-type-family-glyphs/light.png
- Registry item: https://ui.tealmac.com/r/file-type-family-glyphs.json
- Listed: 2026-11-01, source last changed 2026-11-01

## Install

```bash
npx shadcn@latest add https://shadcn.exchange/r/tealmac/file-type-family-glyphs.json
```

Run it in a project that has shadcn/ui set up. It adds the files below and installs what they depend on.

## Dependencies

- Registry items: `@tealmac/reui-file-type`

## Files

### `registry/patterns/file-type-family-glyphs/file-type-family-glyphs.tsx`

```tsx
/**
 * Family glyphs - adapted for tealmac UI from the ReUI example "c-file-type-4"
 * (https://github.com/keenthemes/reui), MIT License, Copyright (c) 2025
 * Keenthemes Inc. The full licence text is in THIRD_PARTY_NOTICES.md.
 * Changes: tealmac UI import paths and theme tokens, lucide icons, logical
 * (RTL-safe) spacing and alignment, reduced-motion support and sample
 * content.
 */
import { FILE_TYPE_CATEGORIES, FileType } from "@/components/reui/file-type"

// The blank page goes last: it stands for a file with no type, so it closes
// the set instead of sitting between two families.
const families = [
  ...FILE_TYPE_CATEGORIES.filter((family) => family !== "empty"),
  "empty",
] as const

export function FileTypeFamilyGlyphs() {
  // Cells fit "Presentation" in a monospace font. The width cap holds a row
  // to 5, so with room the 13 families wrap as 5, 5 and a centered 3.
  return (
    <ul className="mx-auto flex max-w-lg flex-wrap justify-center gap-x-1 gap-y-5">
      {families.map((family) => (
        <li key={family} className="flex w-22 flex-col items-center gap-2">
          {/* The caption names the family, so the icon would read twice. */}
          <FileType type={family} aria-hidden="true" />
          <span className="text-muted-foreground text-xs capitalize">
            {family}
          </span>
        </li>
      ))}
    </ul>
  )
}
```
