{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "One to five stars (a review's grade, the average of a product). The value is read as the label; the stars themselves are decoration.",
  "devDependencies": [],
  "digest": "0.1.0",
  "files": [
    {
      "content": "{#- Code generated by packages/kit-compose/src/server-organisms.ts from packages/compose-gen/specs (compose-gen organism emitters on kit-compose). DO NOT EDIT.\n    Source: packages/compose-gen/specs/parts/rating.json\n    One to five stars (a review's grade, the average of a product). The value is read as the label; the stars themselves are decoration.\n    Props (p): value, label, max, size, className. -#}\n{%- set v_value = (p.value ?? null) -%}\n{%- set v_label = (p.label ?? null) -%}\n{%- set v_max = (p.max ?? 5) -%}\n{%- set v_size = (p.size ?? 16) -%}\n{%- set v_full = og_round(og_min([v_max, og_max([0, v_value])])) -%}\n{%- set c_1 -%}\n  {%- for v_i in og_l(og_range(v_max)) %}\n    {{ include('icons/LucideIcon.html.twig', {'name': 'star', 'size': og_i(v_size), 'class': og_s((og_t(og_lt(v_i, v_full)) ? 'fill-foreground text-foreground' : 'text-border'))}, with_context = false) }}\n  {%- endfor %}\n{%- endset -%}\n{{ include('compose/Box.html.twig', {'class': og_s(og_cnv(['inline-flex items-center gap-0', (p.className ?? '')])), 'attrs': og_attrs(['role', 'img', 'aria-label', v_label, 'data-slot', 'rating', 'data-value', v_full]), 'children': c_1}, with_context = false) }}\n",
      "path": "blocks/rating.html.twig",
      "target": "blocks/rating.html.twig"
    }
  ],
  "meta": {
    "category": "components",
    "kind": "component",
    "tags": [
      "twig",
      "component"
    ]
  },
  "name": "rating",
  "registryDependencies": [
    "box",
    "lucide-icon",
    "utils"
  ],
  "runtime": "twig",
  "title": "Rating",
  "type": "registry:component"
}
