{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "Plans as a grid or a stack of cards.",
  "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/pricing-tiers.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// PricingTiersProps are the props of PricingTiers; the values are the JSON shapes of the TypeScript props.\ntype PricingTiersProps struct {\n\tId any `json:\"id\"`\n\tTitle any `json:\"title\"`\n\tPlans any `json:\"plans\"`\n\tLabels any `json:\"labels\"`\n\tBillingLabels any `json:\"billingLabels\"`\n\tLayout any `json:\"layout\"`\n\tCols any `json:\"cols\"`\n\tEmphasis any `json:\"emphasis\"`\n\tBilling any `json:\"billing\"`\n\tTone any `json:\"tone\"`\n\tDensity any `json:\"density\"`\n\tLandmarkLabel any `json:\"landmarkLabel\"`\n}\n\n// A section with a heading and one PricingCard per plan; an empty state when there are none. Axes: layout (grid, stack), columns, emphasis, billing (off: no toggle; monthly or annual: a toggle with that choice selected, and the prices of that period), density, tone.\ntempl PricingTiers(p PricingTiersProps) {\n\t{{ vId := p.Id }}\n\t{{ vTitle := p.Title }}\n\t{{ vPlans := p.Plans }}\n\t{{ vLabels := p.Labels }}\n\t{{ vBillingLabels := p.BillingLabels }}\n\t{{ vLayout := uiutils.Def(p.Layout, \"grid\") }}\n\t{{ vCols := uiutils.Def(p.Cols, \"1-3\") }}\n\t{{ vEmphasis := uiutils.Def(p.Emphasis, \"auto\") }}\n\t{{ vBilling := uiutils.Def(p.Billing, \"off\") }}\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, Measure: uiutils.Cond(uiutils.T(uiutils.Eq(vLayout, \"stack\")), \"md\", \"default\"), LandmarkLabel: vLandmarkLabel}) {\n\t\tif !uiutils.Eq(vBilling, \"off\") {\n\t\t\t@compose.Group(compose.GroupProps{Gap: \"4\", Align: \"center\", Justify: \"center\", BoxProps: box.BoxProps{Class: \"flex-wrap\", Attrs: uiutils.Attrs(\"data-slot\", \"billing\")}}) {\n\t\t\t\t@Switcher(SwitcherProps{Label: uiutils.Get(vBillingLabels, \"label\")}) {\n\t\t\t\t\t@SwitcherItem(SwitcherItemProps{Active: uiutils.Eq(vBilling, \"monthly\")}) {\n\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vBillingLabels, \"monthly\")) }\n\t\t\t\t\t}\n\t\t\t\t\t@SwitcherItem(SwitcherItemProps{Active: uiutils.Eq(vBilling, \"annual\")}) {\n\t\t\t\t\t\t{ uiutils.Text(uiutils.Get(vBillingLabels, \"annual\")) }\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t@compose.Badge(compose.BadgeProps{Variant: \"default\", Size: \"default\", TextProps: text.TextProps{}}) {\n\t\t\t\t\t{ uiutils.Text(uiutils.Get(vBillingLabels, \"save\")) }\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif uiutils.Eq(uiutils.Len(vPlans), float64(0)) {\n\t\t\t@EmptyState(EmptyStateProps{Icon: \"layers\", Title: uiutils.Get(vLabels, \"empty\")})\n\t\t} else {\n\t\t\t@compose.Grid(compose.GridProps{Cols: uiutils.S(uiutils.Cond(uiutils.T(uiutils.Eq(vLayout, \"stack\")), \"1\", uiutils.FitCols(vCols, uiutils.Len(vPlans)))), BoxProps: box.BoxProps{Class: \"gap-4\", Attrs: uiutils.Attrs(\"data-slot\", \"tiers\")}}) {\n\t\t\t\tfor _, vPlan := range uiutils.L(vPlans) {\n\t\t\t\t\t@PricingCard(PricingCardProps{Plan: vPlan, Labels: vLabels, Emphasis: vEmphasis, Billing: uiutils.Cond(uiutils.T(uiutils.Eq(vBilling, \"annual\")), \"annual\", \"monthly\"), Density: uiutils.Cond(uiutils.T(uiutils.Eq(vDensity, \"compact\")), \"compact\", \"default\")})\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}\n",
      "path": "blocks/pricing-tiers.templ",
      "target": "blocks/pricing-tiers.templ"
    }
  ],
  "meta": {
    "category": "marketing",
    "group": "pricing",
    "kind": "block",
    "tags": [
      "templ",
      "block"
    ]
  },
  "name": "pricing-tiers",
  "registryDependencies": [
    "badge",
    "empty-state",
    "grid",
    "group",
    "kit-box",
    "kit-text",
    "pricing-card",
    "section-frame",
    "switcher",
    "switcher-item",
    "utils"
  ],
  "runtime": "templ",
  "title": "Pricing Tiers",
  "type": "registry:block"
}
