{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "contact-layout-form",
  "title": "Contact Layout Form",
  "description": "Contact form with responsive row layout for side-by-side fields.",
  "registryDependencies": [
    "@buzzform/text",
    "@buzzform/email",
    "@buzzform/row",
    "card",
    "sonner"
  ],
  "files": [
    {
      "path": "registry/shadcn/examples/contact-layout-form.tsx",
      "content": "\"use client\";\n\nimport { defineSchema, type InferType } from \"@buildnbuzz/form-react\";\nimport { toast } from \"sonner\";\nimport {\n  Card,\n  CardContent,\n  CardDescription,\n  CardHeader,\n  CardTitle,\n} from \"@/components/ui/card\";\nimport {\n  Form,\n  FormContent,\n  FormFields,\n  FormSubmit,\n} from \"@/registry/shadcn/form\";\n\nconst contactSchema = defineSchema({\n  fields: [\n    {\n      type: \"row\",\n      fields: [\n        {\n          type: \"text\",\n          name: \"firstName\",\n          label: \"First Name\",\n          placeholder: \"John\",\n          required: true,\n        },\n        {\n          type: \"text\",\n          name: \"lastName\",\n          label: \"Last Name\",\n          placeholder: \"Doe\",\n          required: true,\n        },\n      ],\n    },\n    {\n      type: \"email\",\n      name: \"email\",\n      label: \"Email Address\",\n      placeholder: \"john.doe@example.com\",\n      required: true,\n    },\n    {\n      type: \"row\",\n      fields: [\n        {\n          type: \"text\",\n          name: \"city\",\n          label: \"City\",\n          placeholder: \"New York\",\n          ui: { width: \"60%\" },\n        },\n        {\n          type: \"text\",\n          name: \"zip\",\n          label: \"ZIP Code\",\n          placeholder: \"10001\",\n          ui: { width: \"40%\" },\n        },\n      ],\n    },\n  ],\n});\n\ntype ContactSchema = InferType<typeof contactSchema.fields>;\n\nexport default function ContactLayoutForm() {\n  return (\n    <Card>\n      <CardHeader>\n        <CardTitle>Contact Information</CardTitle>\n        <CardDescription>\n          Side-by-side fields with responsive row layout\n        </CardDescription>\n      </CardHeader>\n      <CardContent>\n        <Form\n          schema={contactSchema}\n          onSubmit={async ({ value }) => {\n            const data = value as ContactSchema;\n            await new Promise((r) => setTimeout(r, 1000));\n            toast(\"Contact saved!\", {\n              description: (\n                <pre className=\"mt-2 max-h-48 overflow-auto rounded-md bg-muted text-muted-foreground p-3 text-xs\">\n                  <code>{JSON.stringify(data, null, 2)}</code>\n                </pre>\n              ),\n            });\n          }}\n        >\n          <FormContent>\n            <FormFields className=\"space-y-4\" />\n            <FormSubmit className=\"mt-6 w-full\">Save Contact</FormSubmit>\n          </FormContent>\n        </Form>\n      </CardContent>\n    </Card>\n  );\n}\n",
      "type": "registry:component",
      "target": "components/buzzform/examples/contact-layout-form.tsx"
    }
  ],
  "type": "registry:block"
}