{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "utils",
  "title": "Utils",
  "author": "zyx1121 (https://github.com/zyx1121)",
  "description": "cn at @/lib/utils, aware of the five type sizes.",
  "dependencies": [
    "cn"
  ],
  "files": [
    {
      "path": "registry/zyx/lib/utils.ts",
      "content": "import type { CnFunction } from \"cn\"\nimport { createCn } from \"cn/config\"\n\n// cn that knows the zyx type scale. Stock tailwind-merge rules read\n// text-display, text-headline, text-title, text-body and text-caption as colors, so\n// cn(\"text-body\", \"text-foreground\") would drop the size; registering them as\n// font sizes keeps both.\nexport const cn: CnFunction = createCn({\n  extend: {\n    classGroups: {\n      \"font-size\": [\n        { text: [\"display\", \"headline\", \"title\", \"body\", \"caption\"] },\n      ],\n    },\n  },\n})\n",
      "type": "registry:lib"
    }
  ],
  "meta": {
    "useWhen": "Merging class names with cn when you write a component.",
    "notFor": "Runtime logic; it only joins classes.",
    "related": [
      "base"
    ]
  },
  "docs": "Use when: Merging class names with cn when you write a component.\nNot for: Runtime logic; it only joins classes.\nGuide: https://ui.zyx.tw/index.md",
  "categories": [
    "lib"
  ],
  "type": "registry:lib"
}