{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "UI8Kit 3 Text primitive (unstyled), from @ui8kit/registry",
  "devDependencies": [],
  "digest": "0.1.0",
  "files": [
    {
      "content": "// Code generated by @ui8kit/codegen. DO NOT EDIT.\n// ui.text — shared TypeScript contract (types + classes helpers)\n\nimport { cn } from \"../../utils\";\n\n/** Text renders the requested text element (default p). */\nexport type TextBaseProps = {\n  tag?: \"p\" | \"span\" | \"h1\" | \"h2\" | \"h3\" | \"h4\" | \"h5\" | \"h6\" | \"blockquote\" | \"figcaption\" | \"pre\" | \"code\" | \"small\" | \"strong\" | \"em\" | \"time\" | \"legend\" | \"del\" | \"ins\";\n};\n\nexport type TextClassesInput = {\n  className?: string;\n};\n\n/** Compose Text classes without rendering — the cross-runtime `asChild` substitute. */\nexport function textClasses(input: TextClassesInput = {}): string {\n  return cn(input.className);\n}\n",
      "path": "kit/ui/text/text.shared.ts",
      "target": "kit/ui/text/text.shared.ts"
    },
    {
      "content": "// Code generated by @ui8kit/codegen. DO NOT EDIT.\n/**\n * Text is the polymorphic text primitive. `tag` accepts HTML5 text elements\n * only (p, span, h1–h6, blockquote, code, …); anything else falls back to p.\n */\n\nimport { splitProps, type JSX, type Component } from \"solid-js\";\nimport { Dynamic } from \"solid-js/web\";\nimport { textClasses } from \"./text.shared\";\nimport { safeRest } from \"../../utils/expr\";\nimport { resolveTag, TagGroup } from \"../../utils/tags\";\n\n/**\n * Text renders the requested text element (default p).\n */\nexport type TextProps = Omit<JSX.HTMLAttributes<HTMLElement>, \"class\" | \"className\" | \"children\" | \"tag\"> & {\n  tag?: \"p\" | \"span\" | \"h1\" | \"h2\" | \"h3\" | \"h4\" | \"h5\" | \"h6\" | \"blockquote\" | \"figcaption\" | \"pre\" | \"code\" | \"small\" | \"strong\" | \"em\" | \"time\" | \"legend\" | \"del\" | \"ins\";\n  class?: string;\n  className?: string;\n  children?: JSX.Element;\n};\n\nexport const Text: Component<TextProps> = (props) => {\n  const [local, rest] = splitProps(props, [\"tag\", \"class\", \"className\", \"children\"]);\n  const resolvedTagValue = () => resolveTag(local.tag, \"p\", TagGroup.Text);\n  const cls = () => textClasses({ className: local.class ?? local.className });\n  return (\n    <Dynamic component={resolvedTagValue()} {...(cls() ? { class: cls() } : {})} {...safeRest(rest)}>\n      {local.children}\n    </Dynamic>\n  );\n};\n",
      "path": "kit/ui/text/text.solid.tsx",
      "target": "kit/ui/text/text.solid.tsx"
    }
  ],
  "meta": {
    "category": "kit",
    "kind": "primitive",
    "tags": [
      "solid",
      "primitive"
    ]
  },
  "name": "kit-text",
  "registryDependencies": [
    "utils"
  ],
  "runtime": "solid",
  "title": "Kit Text",
  "type": "registry:ui"
}
