{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "nx-emblem",
  "title": "Nx Emblem",
  "description": "The Nexus ReGen arrow logomark as an inline SVG with a weight scale (regular keyline through solid) and currentColor fills, for crisp, legible marks at any size.",
  "registryDependencies": [
    "@nx-ui/utils"
  ],
  "files": [
    {
      "path": "components/blocks/nx-emblem.tsx",
      "content": "import * as React from \"react\"\n\nimport { cn } from \"@/lib/utils\"\n\n/**\n * NxEmblem — the Nexus ReGen arrow logomark, drawn inline as vector paths so it\n * colours with `currentColor`, scales crisply and supports a weight scale.\n *\n * The arrow is a fixed brand glyph: it ALWAYS points down-left. Never flip,\n * mirror or rotate it. The geometry is lifted verbatim from\n * `/public/brand/emblem-navy.svg` — a 512-unit canvas with the arrow drawn in a\n * `translate(74.89 69.54) scale(2.664)` group. The source is one compound\n * `fill-rule=\"evenodd\"` path: subpath 1 is the SOLID arrow silhouette, subpath 2\n * is an inset copy that evenodd knocks out, leaving a thin keyline band. That\n * keyline reads too light at small sizes, hence the `weight` scale below.\n *\n * Weights:\n *  - `regular` — the bare keyline band, exactly as the source asset renders.\n *  - `medium` / `bold` — the same keyline, thickened by painting a same-colour\n *    stroke along the compound path. Stroke width is in path units, so the\n *    group's 2.664 scale multiplies it visually; `bold` is tuned to stay legible\n *    down to a 16px rendered emblem.\n *  - `solid` — the filled arrow silhouette alone (subpath 1, no knockout).\n *\n * Colour comes from `currentColor` (fill and stroke), defaulting to navy on\n * light and Nexus accent-yellow on dark per the brand directive; override by\n * passing text colour utilities via `className`.\n *\n * @example\n * <NxEmblem weight=\"solid\" className=\"size-8\" />\n * <NxEmblem weight=\"bold\" className=\"size-4 text-brand-600\" title=\"Nexus ReGen\" />\n */\n\n/** Subpath 1 — the solid arrow silhouette. */\nconst ARROW_SOLID =\n  \"M128.055 9.93506H87.925H7.92499V50.0651H59.555L7.92499 101.685L22.115 115.875L36.305 130.065L87.935 78.4351V130.065H127.905L128.055 9.93506Z\"\n\n/** Subpath 2 — the inset copy evenodd subtracts to leave the keyline band. */\nconst ARROW_INSET =\n  \"M124.625 126.635V50.0651L124.615 50.0551V13.3651H11.355V46.6351H67.845L61.985 52.4951L12.785 101.695L24.545 113.455L36.305 125.215L85.505 76.0151L91.365 70.1551V126.635H124.625Z\"\n\n/** The full compound path (silhouette + knockout) used by the keyline weights. */\nconst ARROW_KEYLINE = `${ARROW_SOLID}${ARROW_INSET}`\n\nexport type NxEmblemWeight = \"regular\" | \"medium\" | \"bold\" | \"solid\"\n\n/** Stroke width (in the 512-canvas path units, before the 2.664 group scale) that\n * thickens the keyline band for each weight. Tuned so `bold` still reads at a\n * 16px rendered emblem; `medium` sits between it and the bare `regular` band.\n * `regular`/`solid` paint no stroke. */\nconst WEIGHT_STROKE: Record<NxEmblemWeight, number> = {\n  regular: 0,\n  medium: 3,\n  bold: 6.5,\n  solid: 0,\n}\n\nfunction NxEmblem({\n  weight = \"regular\",\n  className,\n  title,\n  ...props\n}: Omit<React.ComponentProps<\"svg\">, \"title\"> & {\n  weight?: NxEmblemWeight\n  /** Accessible name. When set, the SVG is labelled (not hidden). */\n  title?: string\n}) {\n  const strokeWidth = WEIGHT_STROKE[weight]\n\n  return (\n    <svg\n      data-slot=\"nx-emblem\"\n      data-weight={weight}\n      viewBox=\"0 0 512 512\"\n      xmlns=\"http://www.w3.org/2000/svg\"\n      role={title ? \"img\" : undefined}\n      aria-hidden={title ? undefined : true}\n      aria-label={title}\n      className={cn(\"text-brand-600 dark:text-accent-400\", className)}\n      {...props}\n    >\n      {title ? <title>{title}</title> : null}\n      {/* Keep the source group transform so the glyph keeps its exact position\n          and down-left orientation. Never flip/rotate this group. */}\n      <g transform=\"translate(74.8895363356364 69.5353367185549) scale(2.6637809040206446)\">\n        {weight === \"solid\" ? (\n          <path d={ARROW_SOLID} fill=\"currentColor\" />\n        ) : (\n          <path\n            d={ARROW_KEYLINE}\n            fill=\"currentColor\"\n            fillRule=\"evenodd\"\n            clipRule=\"evenodd\"\n            {...(strokeWidth > 0\n              ? {\n                  stroke: \"currentColor\",\n                  strokeWidth,\n                  strokeLinejoin: \"round\",\n                }\n              : {})}\n          />\n        )}\n      </g>\n    </svg>\n  )\n}\n\nexport { NxEmblem }\n",
      "type": "registry:component"
    }
  ],
  "type": "registry:block"
}