{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "One choice as a radio group drawn as chips: a fieldset with role radiogroup named by its legend, one radio per option (the first checked), the name and an optional price or note. Static markup.",
  "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/organisms/option-chips.json\n    One choice as a radio group drawn as chips: a fieldset with role radiogroup named by its legend, one radio per option (the first checked), the name and an optional price or note. Static markup.\n    Props (p): name, legend, options, extra, layout. *}\n{var $v_name = ($p['name'] ?? null)}\n{var $v_legend = ($p['legend'] ?? null)}\n{var $v_options = ($p['options'] ?? null)}\n{var $v_extra = ($p['extra'] ?? 'none')}\n{var $v_layout = ($p['layout'] ?? 'wrap')}\n{capture $c_8}\n  {capture $c_1}\n    {=og_text($v_legend)}\n  {/capture}\n  {=og_include('compose/Legend.latte', ['size' => 'sm', 'class' => 'mb-2', 'attrs' => og_attrs(['id', og_tpl('{0}-legend', [$v_name])]), 'children' => (string) $c_1])|noescape}\n  {capture $c_7}\n    {foreach og_l($v_options) as $v_o}\n      {var $v_i = $iterator->counter0}\n      {capture $c_6}\n        {capture $c_3}\n          {=og_include('compose/Radio.latte', ['name' => og_s($v_name), 'value' => og_s(og_get($v_o, ['id'])), 'checked' => og_t(og_eq($v_i, 0))])|noescape}\n          {capture $c_2}\n            {=og_text(og_get($v_o, ['name']))}\n          {/capture}\n          {=og_include('compose/Inline.latte', ['children' => (string) $c_2])|noescape}\n        {/capture}\n        {=og_include('compose/Inline.latte', ['class' => 'flex items-center gap-2', 'children' => (string) $c_3])|noescape}\n        {if og_t(og_eq($v_extra, 'price'))}\n          {capture $c_4}\n            {=og_text(og_money(og_get($v_o, ['price']), og_get($v_o, ['currency'])))}\n          {/capture}\n          {=og_include('compose/Inline.latte', ['class' => 'text-muted-foreground', 'children' => (string) $c_4])|noescape}\n        {/if}\n        {if og_t(og_eq($v_extra, 'note'))}\n          {capture $c_5}\n            {=og_text(og_get($v_o, ['note']))}\n          {/capture}\n          {=og_include('compose/Inline.latte', ['class' => 'text-muted-foreground', 'children' => (string) $c_5])|noescape}\n        {/if}\n      {/capture}\n      {=og_include('compose/Label.latte', ['class' => og_s(og_cnv(['flex items-center gap-2 rounded px-4 py-2 text-sm inset-ring inset-ring-border has-checked:bg-muted has-checked:inset-ring-foreground', (og_t(og_eq($v_layout, 'column')) ? 'justify-between' : '')])), 'attrs' => og_attrs(['data-slot', 'option']), 'children' => (string) $c_6])|noescape}\n    {/foreach}\n  {/capture}\n  {=og_include('compose/Box.latte', ['class' => og_s((og_t(og_eq($v_layout, 'column')) ? 'flex flex-col gap-2' : 'flex flex-wrap gap-2')), 'children' => (string) $c_7])|noescape}\n{/capture}\n{=og_include('compose/Fieldset.latte', ['class' => 'flex flex-col gap-2', 'attrs' => og_attrs(['role', 'radiogroup', 'aria-labelledby', og_tpl('{0}-legend', [$v_name]), 'data-slot', 'option-group']), 'children' => (string) $c_8])|noescape}\n",
      "path": "blocks/option-chips.latte",
      "target": "blocks/option-chips.latte"
    }
  ],
  "meta": {
    "category": "components",
    "kind": "component",
    "tags": [
      "latte",
      "component"
    ]
  },
  "name": "option-chips",
  "registryDependencies": [
    "box",
    "fieldset",
    "inline",
    "label",
    "legend",
    "radio",
    "utils"
  ],
  "runtime": "latte",
  "title": "Option Chips",
  "type": "registry:component"
}
