{
  "$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/organisms.ts from packages/compose-gen/specs (compose-gen organism emitters on kit-compose). DO NOT EDIT.\n\nexport type BillingLabels = {\n  label: string;\n  monthly: string;\n  annual: string;\n  save: string;\n};\n",
      "path": "blocks/pricing-tiers.types.ts",
      "target": "blocks/pricing-tiers.types.ts"
    },
    {
      "content": "<!-- Code generated by packages/kit-compose/src/organisms.ts from packages/compose-gen/specs (compose-gen organism emitters on kit-compose). DO NOT EDIT. -->\n<!--\n  A section with a heading and one PricingCard per plan; an empty state when there are none. Axes: layout (grid,\n  stack), columns, emphasis, billing (off: no toggle; monthly or annual: a toggle with that choice selected, and\n  the prices of that period), density, tone.\n-->\n<script lang=\"ts\">\nimport type { BillingLabels } from \"./pricing-tiers.types\";\nimport type { Plan, PricingCardLabels } from \"./pricing-card.types\";\n\nexport type PricingTiersProps = {\n  id: string;\n  title: string;\n  plans: Plan[];\n  labels: PricingCardLabels;\n  billingLabels: BillingLabels;\n  layout?: \"grid\" | \"stack\";\n  cols?: \"1-2\" | \"1-3\" | \"1-4\";\n  emphasis?: \"auto\" | \"off\";\n  billing?: \"off\" | \"monthly\" | \"annual\";\n  tone?: \"default\" | \"muted\";\n  density?: \"roomy\" | \"default\" | \"compact\";\n  landmarkLabel?: string;\n};\n</script>\n\n<script setup lang=\"ts\">\nimport Badge from \"../compose/Badge.vue\";\nimport Grid from \"../compose/Grid.vue\";\nimport Group from \"../compose/Group.vue\";\nimport EmptyState from \"../components/empty-state.vue\";\nimport PricingCard from \"../blocks/pricing-card.vue\";\nimport SectionFrame from \"../components/section-frame.vue\";\nimport Switcher from \"../components/switcher.vue\";\nimport SwitcherItem from \"../components/switcher-item.vue\";\nimport { fitCols } from \"../utils\";\n\nconst {\n  id,\n  title,\n  plans,\n  labels,\n  billingLabels,\n  layout = \"grid\",\n  cols = \"1-3\",\n  emphasis = \"auto\",\n  billing = \"off\",\n  tone = \"default\",\n  density = \"default\",\n  landmarkLabel,\n} = defineProps<PricingTiersProps>();\nconst emit = defineEmits<{ select: [id: string], billing: [period: string] }>();\n</script>\n\n<template>\n  <SectionFrame\n    :id=\"id\"\n    :title=\"title\"\n    :tone=\"tone\"\n    :density=\"density\"\n    :measure=\"(((layout as string) === 'stack') ? 'md' : 'default')\"\n    :landmarkLabel=\"landmarkLabel\"\n  >\n    <Group\n      v-if=\"((billing as string) !== 'off')\"\n      gap=\"4\"\n      align=\"center\"\n      justify=\"center\"\n      class=\"flex-wrap\"\n      data-slot=\"billing\"\n    >\n      <Switcher :label=\"billingLabels.label\">\n        <SwitcherItem :active=\"((billing as string) === 'monthly')\" @click=\"() => emit('billing', 'monthly')\">\n          {{ billingLabels.monthly }}\n        </SwitcherItem>\n        <SwitcherItem :active=\"((billing as string) === 'annual')\" @click=\"() => emit('billing', 'annual')\">\n          {{ billingLabels.annual }}\n        </SwitcherItem>\n      </Switcher>\n      <Badge variant=\"default\" size=\"default\">\n        {{ billingLabels.save }}\n      </Badge>\n    </Group>\n    <EmptyState v-if=\"((plans?.length ?? 0) === 0)\" icon=\"layers\" :title=\"labels.empty\" />\n    <Grid v-else\n      :cols=\"(((layout as string) === 'stack') ? '1' : fitCols(cols, (plans?.length ?? 0)))\"\n      class=\"gap-4\"\n      data-slot=\"tiers\"\n    >\n      <PricingCard v-for=\"plan in plans\" :key=\"plan.id\"\n        :plan=\"plan\"\n        :labels=\"labels\"\n        :emphasis=\"emphasis\"\n        :billing=\"(((billing as string) === 'annual') ? 'annual' : 'monthly')\"\n        :density=\"(((density as string) === 'compact') ? 'compact' : 'default')\"\n        @select=\"() => emit('select', plan.id)\"\n      />\n    </Grid>\n  </SectionFrame>\n</template>\n",
      "path": "blocks/pricing-tiers.vue",
      "target": "blocks/pricing-tiers.vue"
    }
  ],
  "meta": {
    "category": "marketing",
    "group": "pricing",
    "kind": "block",
    "tags": [
      "vue",
      "block"
    ]
  },
  "name": "pricing-tiers",
  "registryDependencies": [
    "badge",
    "empty-state",
    "grid",
    "group",
    "pricing-card",
    "section-frame",
    "switcher",
    "switcher-item",
    "utils"
  ],
  "runtime": "vue",
  "title": "Pricing Tiers",
  "type": "registry:block"
}
