{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "An editor file tab (40 px high): a file icon, the label and a close button. `preview` marks a tab that is not pinned yet. Keyboard (Enter and Space activate, Delete closes) is the programmer's behind the click and close events.",
  "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/patterns/editor-tab.json\n    An editor file tab (40 px high): a file icon, the label and a close button. `preview` marks a tab that is not pinned yet. Keyboard (Enter and Space activate, Delete closes) is the programmer's behind the click and close events.\n    Props (p): label, closeLabel, active, preview, className, icon (slot). *}\n{var $v_label = ($p['label'] ?? null)}\n{var $v_closeLabel = ($p['closeLabel'] ?? null)}\n{var $v_active = ($p['active'] ?? false)}\n{var $v_preview = ($p['preview'] ?? false)}\n{capture $c_4}\n  {capture $c_3}\n    {=og_slot(($p['icon'] ?? null))|noescape}\n    {capture $c_1}\n      {=og_text($v_label)}\n    {/capture}\n    {=og_include('compose/Inline.latte', ['class' => og_s(og_cnv(['text-xs text-foreground', (og_t($v_preview) ? 'font-semibold italic' : 'font-bold')])), 'attrs' => og_attrs(['data-slot', 'editor-tab-label']), 'children' => (string) $c_1])|noescape}\n    {capture $c_2}\n      {=og_include('icons/LucideIcon.latte', ['name' => 'x', 'size' => 16])|noescape}\n    {/capture}\n    {=og_include('compose/Button.latte', ['variant' => 'ghost', 'size' => 'sm', 'layout' => 'icon', 'class' => 'p-0 [&>svg]:size-4', 'ariaLabel' => og_s($v_closeLabel), 'attrs' => og_attrs(['tabindex', -1, 'data-slot', 'editor-tab-close']), 'children' => (string) $c_2])|noescape}\n  {/capture}\n  {=og_include('compose/Inline.latte', ['class' => 'flex h-10 items-center gap-2 px-3', 'attrs' => og_attrs(['data-slot', 'editor-tab-content']), 'children' => (string) $c_3])|noescape}\n{/capture}\n{=og_include('compose/Box.latte', ['class' => og_s(og_cnv(['flex h-10 shrink-0 cursor-pointer flex-col justify-center data-[state=active]:bg-card [&_svg]:text-muted-foreground', 'border-r border-border', ($p['className'] ?? '')])), 'attrs' => og_attrs(['role', 'tab', 'aria-selected', $v_active, 'tabindex', (og_t($v_active) ? 0 : -1), 'data-slot', 'editor-tab', 'data-state', (og_t($v_active) ? 'active' : 'default')]), 'children' => (string) $c_4])|noescape}\n",
      "path": "blocks/editor-tab.latte",
      "target": "blocks/editor-tab.latte"
    }
  ],
  "meta": {
    "category": "components",
    "kind": "component",
    "tags": [
      "latte",
      "component"
    ]
  },
  "name": "editor-tab",
  "registryDependencies": [
    "box",
    "button",
    "inline",
    "lucide-icon",
    "utils"
  ],
  "runtime": "latte",
  "title": "Editor Tab",
  "type": "registry:component"
}
