{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "Work items in lanes with a count; cards with a tag and a person. Moving cards is a port contract (SortableList).",
  "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/kanban-board.json\n\npackage blocks\n\nimport (\n\t\"github.com/ui8kit/codegen/generated/templ/ui/box\"\n\t\"github.com/ui8kit/codegen/generated/templ/compose\"\n\t\"github.com/ui8kit/codegen/generated/templ/ui/text\"\n\tuiutils \"github.com/ui8kit/codegen/generated/templ/orgutils\"\n)\n\n// KanbanBoardProps are the props of KanbanBoard; the values are the JSON shapes of the TypeScript props.\ntype KanbanBoardProps struct {\n\tId any `json:\"id\"`\n\tTitle any `json:\"title\"`\n\tLanes any `json:\"lanes\"`\n\tEmpty any `json:\"empty\"`\n\tCards any `json:\"cards\"`\n\tCountLabel any `json:\"countLabel\"`\n\tCard any `json:\"card\"`\n\tCols any `json:\"cols\"`\n\tTone any `json:\"tone\"`\n\tDensity any `json:\"density\"`\n\tLandmarkLabel any `json:\"landmarkLabel\"`\n}\n\n// Work items in lanes. Each lane has a title, a count and its cards; a card has a title, an optional tag and the person it belongs to. Axes: card (simple, detail: tag and person), cols (2, 3), tone, density. Moving a card between lanes is a port contract.\ntempl KanbanBoard(p KanbanBoardProps) {\n\t{{ vId := p.Id }}\n\t{{ vTitle := p.Title }}\n\t{{ vLanes := p.Lanes }}\n\t{{ vEmpty := uiutils.Def(p.Empty, \"\") }}\n\t{{ vCards := p.Cards }}\n\t{{ vCountLabel := p.CountLabel }}\n\t{{ vCard := uiutils.Def(p.Card, \"detail\") }}\n\t{{ vCols := uiutils.Def(p.Cols, \"3\") }}\n\t{{ vTone := uiutils.Def(p.Tone, \"default\") }}\n\t{{ vDensity := uiutils.Def(p.Density, \"default\") }}\n\t{{ vLandmarkLabel := p.LandmarkLabel }}\n\t@SectionFrame(SectionFrameProps{Id: vId, Title: vTitle, Tone: vTone, Density: vDensity, LandmarkLabel: vLandmarkLabel}) {\n\t\tif uiutils.Eq(uiutils.Len(vLanes), float64(0)) {\n\t\t\t@EmptyState(EmptyStateProps{Icon: \"kanban\", Title: vEmpty})\n\t\t} else {\n\t\t\t@compose.Grid(compose.GridProps{Cols: uiutils.S(uiutils.Cond(uiutils.T(uiutils.Eq(vCols, \"2\")), \"1-2\", \"1-3\")), BoxProps: box.BoxProps{Class: \"items-start gap-4\", Attrs: uiutils.Attrs(\"data-slot\", \"lanes\")}}) {\n\t\t\t\tfor _, vLane := range uiutils.L(vLanes) {\n\t\t\t\t\t@compose.Stack(compose.StackProps{Gap: \"4\", Align: \"stretch\", BoxProps: box.BoxProps{Class: \"rounded bg-muted p-4\", Attrs: uiutils.Attrs(\"data-slot\", \"lane\")}}) {\n\t\t\t\t\t\t@compose.Group(compose.GroupProps{Gap: \"2\", Align: \"center\", Justify: \"between\", BoxProps: box.BoxProps{}}) {\n\t\t\t\t\t\t\t@compose.Title(compose.TitleProps{As: \"3\", Size: \"base\", Weight: \"bold\", TextProps: text.TextProps{}}) {\n\t\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vLane, \"title\")) }\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t@compose.Text(compose.TextProps{Size: \"xs\", TextProps: text.TextProps{Class: \"text-muted-foreground\"}}) {\n\t\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Tpl(vCountLabel, uiutils.Len(uiutils.Where(vCards, \"lane\", uiutils.Get(vLane, \"key\"))))) }\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t@compose.List(compose.ListProps{BoxProps: box.BoxProps{Class: \"m-0 flex list-none flex-col gap-2 p-0\"}}) {\n\t\t\t\t\t\t\tfor _, vC := range uiutils.L(uiutils.Where(vCards, \"lane\", uiutils.Get(vLane, \"key\"))) {\n\t\t\t\t\t\t\t\t@compose.ListItem(compose.ListItemProps{BoxProps: box.BoxProps{Class: uiutils.S(uiutils.Cnv(\"flex flex-col rounded bg-card inset-ring inset-ring-border\", uiutils.Cond(uiutils.T(uiutils.Eq(vDensity, \"compact\")), \"gap-2 p-2\", \"gap-2 p-4\"))), Attrs: uiutils.Attrs(\"data-slot\", \"item\")}}) {\n\t\t\t\t\t\t\t\t\t@compose.Text(compose.TextProps{Size: \"sm\", Weight: \"semibold\", TextProps: text.TextProps{}}) {\n\t\t\t\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vC, \"title\")) }\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tif uiutils.Eq(vCard, \"detail\") {\n\t\t\t\t\t\t\t\t\t\t@compose.Group(compose.GroupProps{Gap: \"2\", Align: \"center\", Justify: \"between\", BoxProps: box.BoxProps{Class: \"flex-wrap\"}}) {\n\t\t\t\t\t\t\t\t\t\t\t@Pill(PillProps{Tone: \"blue\", Icon: \"tag\"}) {\n\t\t\t\t\t\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vC, \"tag\")) }\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t@compose.Text(compose.TextProps{Size: \"xs\", TextProps: text.TextProps{Class: \"text-muted-foreground\"}}) {\n\t\t\t\t\t\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vC, \"who\")) }\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}\n",
      "path": "blocks/kanban-board.templ",
      "target": "blocks/kanban-board.templ"
    }
  ],
  "meta": {
    "category": "dashboard",
    "group": "widgets",
    "kind": "block",
    "tags": [
      "templ",
      "block"
    ]
  },
  "name": "kanban-board",
  "registryDependencies": [
    "empty-state",
    "grid",
    "group",
    "kit-box",
    "kit-text",
    "list",
    "list-item",
    "pill",
    "section-frame",
    "stack",
    "text",
    "title",
    "utils"
  ],
  "runtime": "templ",
  "title": "Kanban Board",
  "type": "registry:block"
}
