{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "The jobs of JobBoard as cards in two columns (title, department, place, type, optional salary, posted, apply) or as a table.",
  "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/job-cards.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/icons\"\n\t\"github.com/ui8kit/codegen/generated/templ/ui/text\"\n\tuiutils \"github.com/ui8kit/codegen/generated/templ/orgutils\"\n)\n\n// JobCardsProps are the props of JobCards; the values are the JSON shapes of the TypeScript props.\ntype JobCardsProps struct {\n\tJobs any `json:\"jobs\"`\n\tDepartments any `json:\"departments\"`\n\tLabels any `json:\"labels\"`\n\tLayout any `json:\"layout\"`\n\tSalary any `json:\"salary\"`\n}\n\n// The jobs of JobBoard as cards in two columns (title, department, place, type, optional salary, posted, apply) or as a table.\ntempl JobCards(p JobCardsProps) {\n\t{{ vJobs := p.Jobs }}\n\t{{ vDepartments := p.Departments }}\n\t{{ vLabels := p.Labels }}\n\t{{ vLayout := uiutils.Def(p.Layout, \"grid\") }}\n\t{{ vSalary := uiutils.Def(p.Salary, \"hide\") }}\n\tif uiutils.Eq(vLayout, \"table\") {\n\t\t@compose.Box(compose.BoxProps{BoxProps: box.BoxProps{Class: \"w-full overflow-x-auto rounded inset-ring inset-ring-border\", Attrs: uiutils.Attrs(\"data-slot\", \"job-cards\")}}) {\n\t\t\t@compose.Table(compose.TableProps{BoxProps: box.BoxProps{Class: \"w-full text-left text-sm\", Attrs: uiutils.Attrs(\"data-slot\", \"job-table\")}}) {\n\t\t\t\t@compose.TableCaption(compose.TableCaptionProps{BoxProps: box.BoxProps{Class: \"sr-only\"}}) {\n\t\t\t\t\t{ uiutils.Text(uiutils.Get(vLabels, \"caption\")) }\n\t\t\t\t}\n\t\t\t\t@compose.TableHead(compose.TableHeadProps{BoxProps: box.BoxProps{Class: \"bg-muted\"}}) {\n\t\t\t\t\t@compose.TableRow(compose.TableRowProps{BoxProps: box.BoxProps{}}) {\n\t\t\t\t\t\t@compose.TableHeadCell(compose.TableHeadCellProps{BoxProps: box.BoxProps{Class: \"px-4 py-2\", Attrs: uiutils.Attrs(\"scope\", \"col\")}}) {\n\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vLabels, \"role\")) }\n\t\t\t\t\t\t}\n\t\t\t\t\t\t@compose.TableHeadCell(compose.TableHeadCellProps{BoxProps: box.BoxProps{Class: \"hidden py-2 md:table-cell\", Attrs: uiutils.Attrs(\"scope\", \"col\")}}) {\n\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vLabels, \"team\")) }\n\t\t\t\t\t\t}\n\t\t\t\t\t\t@compose.TableHeadCell(compose.TableHeadCellProps{BoxProps: box.BoxProps{Class: \"hidden py-2 sm:table-cell\", Attrs: uiutils.Attrs(\"scope\", \"col\")}}) {\n\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vLabels, \"location\")) }\n\t\t\t\t\t\t}\n\t\t\t\t\t\t@compose.TableHeadCell(compose.TableHeadCellProps{BoxProps: box.BoxProps{Class: \"py-2\", Attrs: uiutils.Attrs(\"scope\", \"col\")}}) {\n\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vLabels, \"type\")) }\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif uiutils.Eq(vSalary, \"show\") {\n\t\t\t\t\t\t\t@compose.TableHeadCell(compose.TableHeadCellProps{BoxProps: box.BoxProps{Class: \"hidden py-2 md:table-cell\", Attrs: uiutils.Attrs(\"scope\", \"col\")}}) {\n\t\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vLabels, \"salary\")) }\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t@compose.TableHeadCell(compose.TableHeadCellProps{BoxProps: box.BoxProps{Class: \"py-2 pr-4\", Attrs: uiutils.Attrs(\"scope\", \"col\")}}) {\n\t\t\t\t\t\t\t@compose.Inline(compose.InlineProps{TextProps: text.TextProps{Class: \"sr-only\"}}) {\n\t\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vLabels, \"apply\")) }\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\t@compose.TableBody(compose.TableBodyProps{BoxProps: box.BoxProps{}}) {\n\t\t\t\t\tfor _, vJ := range uiutils.L(vJobs) {\n\t\t\t\t\t\t@compose.TableRow(compose.TableRowProps{BoxProps: box.BoxProps{Class: \"border-t border-border\", Attrs: uiutils.Attrs(\"data-slot\", \"item\")}}) {\n\t\t\t\t\t\t\t@compose.TableCell(compose.TableCellProps{BoxProps: box.BoxProps{Class: \"px-4 py-4 font-medium\"}}) {\n\t\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vJ, \"title\")) }\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t@compose.TableCell(compose.TableCellProps{BoxProps: box.BoxProps{Class: \"hidden md:table-cell\"}}) {\n\t\t\t\t\t\t\t\t{ uiutils.Text(uiutils.FirstOf(uiutils.Where(vDepartments, \"id\", uiutils.Get(vJ, \"dept\")), \"name\")) }\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t@compose.TableCell(compose.TableCellProps{BoxProps: box.BoxProps{Class: \"hidden sm:table-cell\"}}) {\n\t\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vJ, \"location\")) }\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t@compose.TableCell(compose.TableCellProps{BoxProps: box.BoxProps{}}) {\n\t\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vJ, \"type\")) }\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif uiutils.Eq(vSalary, \"show\") {\n\t\t\t\t\t\t\t\t@compose.TableCell(compose.TableCellProps{BoxProps: box.BoxProps{Class: \"hidden md:table-cell\"}}) {\n\t\t\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vJ, \"salary\")) }\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t@compose.TableCell(compose.TableCellProps{BoxProps: box.BoxProps{Class: \"pr-4 text-right\"}}) {\n\t\t\t\t\t\t\t\t@MenuEntry(MenuEntryProps{Href: uiutils.Get(vJ, \"href\"), Class: uiutils.Cnv(\"font-medium\")}) {\n\t\t\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vLabels, \"apply\")) }\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} else {\n\t\t@compose.Grid(compose.GridProps{Cols: \"1-2\", BoxProps: box.BoxProps{Class: \"gap-4\", Attrs: uiutils.Attrs(\"data-slot\", \"items\")}}) {\n\t\t\tfor _, vJ := range uiutils.L(vJobs) {\n\t\t\t\t@compose.Stack(compose.StackProps{Gap: \"4\", BoxProps: box.BoxProps{Class: \"rounded bg-card inset-ring inset-ring-border p-6\", Attrs: uiutils.Attrs(\"data-slot\", \"item\")}}) {\n\t\t\t\t\t@compose.Stack(compose.StackProps{Gap: \"2\", BoxProps: box.BoxProps{}}) {\n\t\t\t\t\t\t@compose.Text(compose.TextProps{Size: \"lg\", Weight: \"semibold\", TextProps: text.TextProps{}}) {\n\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vJ, \"title\")) }\n\t\t\t\t\t\t}\n\t\t\t\t\t\t@compose.Group(compose.GroupProps{Gap: \"4\", BoxProps: box.BoxProps{Class: \"flex-wrap text-sm text-muted-foreground\"}}) {\n\t\t\t\t\t\t\t@compose.Group(compose.GroupProps{Gap: \"2\", Align: \"center\", BoxProps: box.BoxProps{}}) {\n\t\t\t\t\t\t\t\t@icons.LucideIcon(icons.LucideIconProps{Name: \"briefcase\", Size: 16})\n\t\t\t\t\t\t\t\t@compose.Inline(compose.InlineProps{TextProps: text.TextProps{}}) {\n\t\t\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vJ, \"type\")) }\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t@compose.Group(compose.GroupProps{Gap: \"2\", Align: \"center\", BoxProps: box.BoxProps{}}) {\n\t\t\t\t\t\t\t\t@icons.LucideIcon(icons.LucideIconProps{Name: \"map-pin\", Size: 16})\n\t\t\t\t\t\t\t\t@compose.Inline(compose.InlineProps{TextProps: text.TextProps{}}) {\n\t\t\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vJ, \"location\")) }\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t@compose.Group(compose.GroupProps{Gap: \"2\", Align: \"center\", BoxProps: box.BoxProps{}}) {\n\t\t\t\t\t\t\t\t@icons.LucideIcon(icons.LucideIconProps{Name: \"calendar\", Size: 16})\n\t\t\t\t\t\t\t\t@compose.Inline(compose.InlineProps{TextProps: text.TextProps{}}) {\n\t\t\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vJ, \"posted\")) }\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\tif uiutils.Eq(vSalary, \"show\") {\n\t\t\t\t\t\t@compose.Text(compose.TextProps{Size: \"base\", Weight: \"semibold\", TextProps: text.TextProps{Attrs: uiutils.Attrs(\"data-slot\", \"salary\")}}) {\n\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vJ, \"salary\")) }\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t@compose.Group(compose.GroupProps{Gap: \"4\", Align: \"center\", Justify: \"between\", BoxProps: box.BoxProps{Class: \"mt-auto\"}}) {\n\t\t\t\t\t\t@compose.Badge(compose.BadgeProps{Variant: \"secondary\", Size: \"default\", TextProps: text.TextProps{}}) {\n\t\t\t\t\t\t\t{ uiutils.Text(uiutils.FirstOf(uiutils.Where(vDepartments, \"id\", uiutils.Get(vJ, \"dept\")), \"name\")) }\n\t\t\t\t\t\t}\n\t\t\t\t\t\t@MenuEntry(MenuEntryProps{Href: uiutils.Get(vJ, \"href\"), Class: uiutils.Cnv(\"inline-flex items-center gap-2 text-sm font-medium\")}) {\n\t\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vLabels, \"apply\")) }\n\t\t\t\t\t\t\t@icons.LucideIcon(icons.LucideIconProps{Name: \"arrow-right\", Size: 16})\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/job-cards.templ",
      "target": "blocks/job-cards.templ"
    }
  ],
  "meta": {
    "category": "components",
    "kind": "component",
    "tags": [
      "templ",
      "component"
    ]
  },
  "name": "job-cards",
  "registryDependencies": [
    "badge",
    "box",
    "grid",
    "group",
    "inline",
    "kit-box",
    "kit-text",
    "lucide-icon",
    "menu-entry",
    "stack",
    "table",
    "table-body",
    "table-caption",
    "table-cell",
    "table-head",
    "table-head-cell",
    "table-row",
    "text",
    "utils"
  ],
  "runtime": "templ",
  "title": "Job Cards",
  "type": "registry:component"
}
