{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "Cta Actions component",
  "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 ActionSet = {\n  /** one or two links, or a form */\n  mode?: \"one\" | \"two\" | \"form\";\n  /** primary action label */\n  cta: string;\n  /** the address of the primary action; none: a button, not a link */\n  href?: string;\n  secondary?: string;\n  secondaryHref?: string;\n  /** label of the form field (the email field, or the prompt line of HeroPrompt) */\n  emailLabel?: string;\n};\n",
      "path": "components/cta-actions.types.ts",
      "target": "components/cta-actions.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  The actions of a call to action: one or two links (ActionGroup), or an email field with a button (actions\n  form).\n-->\n<script lang=\"ts\">\nimport type { ActionSet } from \"./cta-actions.types\";\n\nexport type CtaActionsProps = {\n  id: string;\n  actions: ActionSet;\n  center?: boolean;\n};\n</script>\n\n<script setup lang=\"ts\">\nimport Button from \"../compose/Button.vue\";\nimport Form from \"../compose/Form.vue\";\nimport Group from \"../compose/Group.vue\";\nimport Input from \"../compose/Input.vue\";\nimport Label from \"../compose/Label.vue\";\nimport ActionGroup from \"../components/action-group.vue\";\nimport { cn, tpl } from \"../utils\";\n\nconst { id, actions, center = false } = defineProps<CtaActionsProps>();\n</script>\n\n<template>\n  <Form\n    v-if=\"(actions.mode === 'form')\"\n    method=\"dialog\"\n    :class=\"cn('w-full max-w-md', (center ? 'mx-auto' : ''))\"\n    data-slot=\"email-form\"\n  >\n    <Label :for=\"tpl('{0}-email', id)\" class=\"sr-only\">\n      {{ actions.emailLabel }}\n    </Label>\n    <Group gap=\"2\" align=\"start\" class=\"w-full flex-wrap\">\n      <Input type=\"email\" name=\"email\" class=\"min-w-0 flex-1\" :id=\"tpl('{0}-email', id)\" data-slot=\"field\" />\n      <Button variant=\"default\" size=\"default\" type=\"submit\">\n        {{ actions.cta }}\n      </Button>\n    </Group>\n  </Form>\n  <ActionGroup v-else\n    :primary=\"actions.cta\"\n    :primaryHref=\"actions.href\"\n    :secondary=\"((actions.mode === 'two') ? actions.secondary : undefined)\"\n    :secondaryHref=\"actions.secondaryHref\"\n    :align=\"(center ? 'center' : 'start')\"\n  />\n</template>\n",
      "path": "components/cta-actions.vue",
      "target": "components/cta-actions.vue"
    }
  ],
  "meta": {
    "category": "components",
    "kind": "component",
    "tags": [
      "vue",
      "component"
    ]
  },
  "name": "cta-actions",
  "registryDependencies": [
    "action-group",
    "button",
    "form",
    "group",
    "input",
    "label",
    "utils"
  ],
  "runtime": "vue",
  "title": "Cta Actions",
  "type": "registry:component"
}
