[{"data":1,"prerenderedAt":578},["ShallowReactive",2],{"mobile-docs-navigation":3,"command-menu-docs":126,"navigation":183,"mobile-docs-page-meta":218,"docs-pages-category":252,"\u002Fdocs\u002Fcomponents\u002Fform":281,"surround-\u002Fdocs\u002Fcomponents\u002Fform":575},[4],{"title":5,"path":6,"stem":7,"children":8,"page":125},"Docs","\u002Fdocs","docs",[9,19],{"title":10,"path":11,"stem":12,"children":13},"Introduction","\u002Fdocs\u002Fgetting-started","docs\u002F1.getting-started\u002F1.index",[14,15],{"title":10,"path":11,"stem":12},{"title":16,"path":17,"stem":18},"Installation","\u002Fdocs\u002Fgetting-started\u002Finstallation","docs\u002F1.getting-started\u002F2.installation",{"title":20,"path":21,"stem":22,"children":23},"Components","\u002Fdocs\u002Fcomponents","docs\u002F2.components\u002F0.index",[24,25,29,33,37,41,45,49,53,57,61,65,69,73,77,81,85,89,93,97,101,105,109,113,117,121],{"title":20,"path":21,"stem":22},{"title":26,"path":27,"stem":28},"Chat","\u002Fdocs\u002Fcomponents\u002Fchat","docs\u002F2.components\u002F1.chat",{"title":30,"path":31,"stem":32},"PolaroidCard","\u002Fdocs\u002Fcomponents\u002Fpolaroid-card","docs\u002F2.components\u002F10.polaroid-card",{"title":34,"path":35,"stem":36},"FeatureCard","\u002Fdocs\u002Fcomponents\u002Ffeature-card","docs\u002F2.components\u002F11.feature-card",{"title":38,"path":39,"stem":40},"ChangelogTimeline","\u002Fdocs\u002Fcomponents\u002Fchangelog-timeline","docs\u002F2.components\u002F12.changelog-timeline",{"title":42,"path":43,"stem":44},"MetricsGrid","\u002Fdocs\u002Fcomponents\u002Fmetrics-grid","docs\u002F2.components\u002F13.metrics-grid",{"title":46,"path":47,"stem":48},"Testimonials","\u002Fdocs\u002Fcomponents\u002Ftestimonials","docs\u002F2.components\u002F13.testimonials",{"title":50,"path":51,"stem":52},"FeatureGrid","\u002Fdocs\u002Fcomponents\u002Ffeature-grid","docs\u002F2.components\u002F14.feature-grid",{"title":54,"path":55,"stem":56},"FaqTabs","\u002Fdocs\u002Fcomponents\u002Ffaq-tabs","docs\u002F2.components\u002F15.faq-tabs",{"title":58,"path":59,"stem":60},"BlogPostGrid","\u002Fdocs\u002Fcomponents\u002Fblog-post-grid","docs\u002F2.components\u002F16.blog-post-grid",{"title":62,"path":63,"stem":64},"FeatureSplit","\u002Fdocs\u002Fcomponents\u002Ffeature-split","docs\u002F2.components\u002F17.feature-split",{"title":66,"path":67,"stem":68},"FileAttachment","\u002Fdocs\u002Fcomponents\u002Ffile-attachment","docs\u002F2.components\u002F17.file-attachment",{"title":70,"path":71,"stem":72},"ModelPicker","\u002Fdocs\u002Fcomponents\u002Fmodel-picker","docs\u002F2.components\u002F17.model-picker",{"title":74,"path":75,"stem":76},"WorkExperience","\u002Fdocs\u002Fcomponents\u002Fwork-experience","docs\u002F2.components\u002F17.work-experience",{"title":78,"path":79,"stem":80},"Form","\u002Fdocs\u002Fcomponents\u002Fform","docs\u002F2.components\u002F18.form",{"title":82,"path":83,"stem":84},"FormField","\u002Fdocs\u002Fcomponents\u002Fform-field","docs\u002F2.components\u002F19.form-field",{"title":86,"path":87,"stem":88},"ChatMessage","\u002Fdocs\u002Fcomponents\u002Fchat-message","docs\u002F2.components\u002F2.chat-message",{"title":90,"path":91,"stem":92},"ChatMessages","\u002Fdocs\u002Fcomponents\u002Fchat-messages","docs\u002F2.components\u002F3.chat-messages",{"title":94,"path":95,"stem":96},"ChatPrompt","\u002Fdocs\u002Fcomponents\u002Fchat-prompt","docs\u002F2.components\u002F4.chat-prompt",{"title":98,"path":99,"stem":100},"ChatPromptSubmit","\u002Fdocs\u002Fcomponents\u002Fchat-prompt-submit","docs\u002F2.components\u002F5.chat-prompt-submit",{"title":102,"path":103,"stem":104},"DocsSearchModal","\u002Fdocs\u002Fcomponents\u002Fdocs-search-modal","docs\u002F2.components\u002F6.docs-search-modal",{"title":106,"path":107,"stem":108},"PricingPlans","\u002Fdocs\u002Fcomponents\u002Fpricing-plans","docs\u002F2.components\u002F7.pricing-plans",{"title":110,"path":111,"stem":112},"PageToc","\u002Fdocs\u002Fcomponents\u002Fpage-toc","docs\u002F2.components\u002F8.page-toc",{"title":114,"path":115,"stem":116},"ReasoningDisclosure","\u002Fdocs\u002Fcomponents\u002Freasoning-disclosure","docs\u002F2.components\u002F8.reasoning-disclosure",{"title":118,"path":119,"stem":120},"DocsPager","\u002Fdocs\u002Fcomponents\u002Fdocs-pager","docs\u002F2.components\u002F9.docs-pager",{"title":122,"path":123,"stem":124},"HomeCta","\u002Fdocs\u002Fcomponents\u002Fhome-cta","docs\u002F2.components\u002F9.home-cta",false,[127,129,131,133,135,137,139,141,143,145,147,149,151,153,155,157,159,161,163,165,167,169,171,173,175,177,179,181],{"path":59,"title":58,"description":128},"Render responsive blog and content teaser grids from display-ready post data.",{"path":39,"title":38,"description":130},"Render a release timeline from app-owned changelog data with optional rich body slots.",{"path":27,"title":26,"description":132},"Build Nuxt chat interfaces with installable shadcn-vue components you own and compose.",{"path":87,"title":86,"description":134},"Render an individual chat message bubble with AI SDK parts, actions, and layout control.",{"path":91,"title":90,"description":136},"Compose chat message lists with scrolling behavior, loading states, and action-ready assistant output.",{"path":95,"title":94,"description":138},"Build chat input flows with an auto-resizing prompt, keyboard shortcuts, and flexible slot composition.",{"path":99,"title":98,"description":140},"Handle chat submit, stop, and retry actions with a status-aware control for prompt workflows.",{"path":21,"title":20,"description":142},"Explore reusable components that complement Nuxt templates and real app workflows.",{"path":119,"title":118,"description":144},"Render previous and next documentation links from app-owned page data.",{"path":103,"title":102,"description":146},"Add a lightweight local search modal to Nuxt documentation interfaces.",{"path":55,"title":54,"description":148},"Render categorized FAQ sections while keeping answer content in your app.",{"path":35,"title":34,"description":150},"Render a reusable feature, content, or navigation card with optional link and icon slot.",{"path":51,"title":50,"description":152},"Render a complete feature section from app-owned feature data.",{"path":63,"title":62,"description":154},"Render alternating split feature sections with app-owned media and icon slots.",{"path":67,"title":66,"description":156},"Render display-only file attachment UI while your app owns upload behavior.",{"path":79,"title":78,"description":158},"Validate app-owned form state and distribute errors to named fields.",{"path":83,"title":82,"description":160},"Wrap form controls with labels, descriptions, help text, and validation errors.",{"path":123,"title":122,"description":162},"Render a centered marketing CTA section with an integrated starfield background.",{"path":17,"title":16,"description":164},"Start from templates or install individual components in your Nuxt project.",{"path":11,"title":10,"description":166},"Stackhacker UI is an open-source collection of Nuxt templates and components for the shadcn-vue community.",{"path":43,"title":42,"description":168},"Render a responsive marketing metrics section from app-owned data.",{"path":71,"title":70,"description":170},"Render a controlled model selector from app-owned model\u002Fprovider data.",{"path":111,"title":110,"description":172},"Render an on-page table of contents from app-supplied heading links.",{"path":31,"title":30,"description":174},"Render a tilted photo card with app-owned image data and explicit presentation controls.",{"path":107,"title":106,"description":176},"Render a responsive pricing plan section from app-owned data.",{"path":115,"title":114,"description":178},"Show app-owned AI reasoning text in a compact collapsible disclosure.",{"path":47,"title":46,"description":180},"Render a responsive social-proof section from app-owned testimonial data.",{"path":75,"title":74,"description":182},"Render compact work-history and resume lists from app-owned experience data.",[184],{"title":5,"path":6,"stem":7,"children":185,"page":125},[186,190],{"title":10,"path":11,"stem":12,"children":187},[188,189],{"title":10,"path":11,"stem":12},{"title":16,"path":17,"stem":18},{"title":20,"path":21,"stem":22,"children":191},[192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217],{"title":20,"path":21,"stem":22},{"title":26,"path":27,"stem":28},{"title":30,"path":31,"stem":32},{"title":34,"path":35,"stem":36},{"title":38,"path":39,"stem":40},{"title":42,"path":43,"stem":44},{"title":46,"path":47,"stem":48},{"title":50,"path":51,"stem":52},{"title":54,"path":55,"stem":56},{"title":58,"path":59,"stem":60},{"title":62,"path":63,"stem":64},{"title":66,"path":67,"stem":68},{"title":70,"path":71,"stem":72},{"title":74,"path":75,"stem":76},{"title":78,"path":79,"stem":80},{"title":82,"path":83,"stem":84},{"title":86,"path":87,"stem":88},{"title":90,"path":91,"stem":92},{"title":94,"path":95,"stem":96},{"title":98,"path":99,"stem":100},{"title":102,"path":103,"stem":104},{"title":106,"path":107,"stem":108},{"title":110,"path":111,"stem":112},{"title":114,"path":115,"stem":116},{"title":118,"path":119,"stem":120},{"title":122,"path":123,"stem":124},[219,221,222,223,225,227,229,230,231,232,233,234,235,236,237,238,239,241,242,243,244,245,246,247,248,249,250,251],{"path":11,"category":220},"overview",{"path":17,"category":220},{"path":21,"category":220},{"path":27,"category":224},"chat",{"path":31,"category":226},"content",{"path":35,"category":228},"marketing",{"path":39,"category":226},{"path":43,"category":228},{"path":47,"category":228},{"path":51,"category":228},{"path":55,"category":228},{"path":59,"category":226},{"path":63,"category":228},{"path":67,"category":224},{"path":71,"category":224},{"path":75,"category":226},{"path":79,"category":240},"form",{"path":83,"category":240},{"path":87,"category":224},{"path":91,"category":224},{"path":95,"category":224},{"path":99,"category":224},{"path":103,"category":226},{"path":107,"category":228},{"path":111,"category":226},{"path":115,"category":224},{"path":119,"category":226},{"path":123,"category":228},[253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280],{"path":11,"category":220},{"path":17,"category":220},{"path":21,"category":220},{"path":27,"category":224},{"path":31,"category":226},{"path":35,"category":228},{"path":39,"category":226},{"path":43,"category":228},{"path":47,"category":228},{"path":51,"category":228},{"path":55,"category":228},{"path":59,"category":226},{"path":63,"category":228},{"path":67,"category":224},{"path":71,"category":224},{"path":75,"category":226},{"path":79,"category":240},{"path":83,"category":240},{"path":87,"category":224},{"path":91,"category":224},{"path":95,"category":224},{"path":99,"category":224},{"path":103,"category":226},{"path":107,"category":228},{"path":111,"category":226},{"path":115,"category":224},{"path":119,"category":226},{"path":123,"category":228},{"id":282,"title":78,"body":283,"category":240,"description":158,"extension":570,"meta":571,"navigation":572,"path":79,"seo":573,"stem":80,"__hash__":574},"docs\u002Fdocs\u002F2.components\u002F18.form.md",{"type":284,"value":285,"toc":557},"minimark",[286,290,294,298,309,313,321,325,338,341,345,348,354,358,363,497,501,545,549],[287,288],"component-preview",{"name":289},"FormDemo",[291,292,16],"h2",{"id":293},"installation",[295,296,297],"p",{},"Add the shadcn-vue controls you want to compose, then add Stackhacker UI's form layer.",[299,300,306],"pre",{"className":301,"code":303,"language":304,"meta":305},[302],"language-bash","npx shadcn-vue@latest add field input textarea select\nnpx shadcn-vue@latest add \"https:\u002F\u002Fui.stackhacker.io\u002Fr\u002Fform.json\"\nnpx shadcn-vue@latest add \"https:\u002F\u002Fui.stackhacker.io\u002Fr\u002Fform-field.json\"\n","bash","",[307,308,303],"code",{"__ignoreMap":305},[291,310,312],{"id":311},"usage","Usage",[299,314,319],{"className":315,"code":317,"language":318,"meta":305},[316],"language-vue","\u003Cscript setup lang=\"ts\">\nimport { reactive } from 'vue'\nimport { Form, type FormError } from '@\u002Fcomponents\u002Fform'\nimport { FormField } from '@\u002Fcomponents\u002Fform-field'\nimport { Input } from '@\u002Fcomponents\u002Fui\u002Finput'\n\nconst state = reactive({ email: '' })\n\nfunction validate(values: typeof state): FormError[] {\n  if (!values.email.includes('@')) {\n    return [{ name: 'email', message: 'Enter a valid email address.' }]\n  }\n  return []\n}\n\nasync function onSubmit(event) {\n  await saveProfile(event.data)\n}\n\u003C\u002Fscript>\n\n\u003Ctemplate>\n  \u003CForm :state=\"state\" :validate=\"validate\" @submit=\"onSubmit\">\n    \u003CFormField v-slot=\"field\" label=\"Email\" name=\"email\">\n      \u003CInput v-model=\"state.email\" v-bind=\"field\" type=\"email\" \u002F>\n    \u003C\u002FFormField>\n  \u003C\u002FForm>\n\u003C\u002Ftemplate>\n","vue",[307,320,317],{"__ignoreMap":305},[291,322,324],{"id":323},"responsibilities","Responsibilities",[295,326,327,329,330,333,334,337],{},[307,328,78],{}," owns the UI protocol: form event handling, validation triggering, error collection, field-level error distribution, and ",[307,331,332],{},"submit"," \u002F ",[307,335,336],{},"error"," events.",[295,339,340],{},"Your app owns API submission, mutation, persistence, toast, redirect, server error interpretation, auth flows, and business rules.",[291,342,344],{"id":343},"regle-integration","Regle Integration",[295,346,347],{},"Regle remains an app dependency. Stackhacker UI does not import Regle.",[299,349,352],{"className":350,"code":351,"language":318,"meta":305},[316],"\u003Cscript setup lang=\"ts\">\nimport { useRegle } from '@regle\u002Fcore'\nimport { email, required, withMessage } from '@regle\u002Frules'\nimport { Form } from '@\u002Fcomponents\u002Fform'\nimport { FormField } from '@\u002Fcomponents\u002Fform-field'\nimport { Input } from '@\u002Fcomponents\u002Fui\u002Finput'\n\nconst { r$ } = useRegle({ email: '' }, {\n  email: {\n    required,\n    email: withMessage(email, 'Enter a valid email address.')\n  }\n})\n\u003C\u002Fscript>\n\n\u003Ctemplate>\n  \u003CForm :schema=\"r$\" :state=\"r$.$value\">\n    \u003CFormField v-slot=\"field\" label=\"Email\" name=\"email\">\n      \u003CInput v-model=\"r$.$value.email\" v-bind=\"field\" type=\"email\" \u002F>\n    \u003C\u002FFormField>\n  \u003C\u002FForm>\n\u003C\u002Ftemplate>\n",[307,353,351],{"__ignoreMap":305},[291,355,357],{"id":356},"api-reference","API Reference",[359,360,362],"h3",{"id":361},"props","Props",[364,365,366,385],"table",{},[367,368,369],"thead",{},[370,371,372,376,379,382],"tr",{},[373,374,375],"th",{},"Prop",[373,377,378],{},"Type",[373,380,381],{},"Default",[373,383,384],{},"Description",[386,387,388,407,423,440,460,480],"tbody",{},[370,389,390,396,401,404],{},[391,392,393],"td",{},[307,394,395],{},"state",[391,397,398],{},[307,399,400],{},"unknown",[391,402,403],{},"—",[391,405,406],{},"App-owned reactive form state.",[370,408,409,414,418,420],{},[391,410,411],{},[307,412,413],{},"schema",[391,415,416],{},[307,417,400],{},[391,419,403],{},[391,421,422],{},"Optional schema-like validator such as Regle or Standard Schema.",[370,424,425,430,435,437],{},[391,426,427],{},[307,428,429],{},"validate",[391,431,432],{},[307,433,434],{},"(state) => FormError[] | Promise\u003CFormError[]>",[391,436,403],{},[391,438,439],{},"Custom validation function.",[370,441,442,447,452,457],{},[391,443,444],{},[307,445,446],{},"validateOn",[391,448,449],{},[307,450,451],{},"('input' | 'change' | 'blur')[]",[391,453,454],{},[307,455,456],{},"['blur']",[391,458,459],{},"Input events that trigger validation.",[370,461,462,467,472,477],{},[391,463,464],{},[307,465,466],{},"disabled",[391,468,469],{},[307,470,471],{},"boolean",[391,473,474],{},[307,475,476],{},"false",[391,478,479],{},"Marks the form context disabled for fields.",[370,481,482,487,492,494],{},[391,483,484],{},[307,485,486],{},"class",[391,488,489],{},[307,490,491],{},"string",[391,493,403],{},[391,495,496],{},"Additional CSS classes.",[359,498,500],{"id":499},"events","Events",[364,502,503,515],{},[367,504,505],{},[370,506,507,510,513],{},[373,508,509],{},"Event",[373,511,512],{},"Payload",[373,514,384],{},[386,516,517,531],{},[370,518,519,523,528],{},[391,520,521],{},[307,522,332],{},[391,524,525],{},[307,526,527],{},"{ originalEvent, data }",[391,529,530],{},"Emitted after validation succeeds.",[370,532,533,537,542],{},[391,534,535],{},[307,536,336],{},[391,538,539],{},[307,540,541],{},"{ originalEvent, errors, data }",[391,543,544],{},"Emitted after validation fails.",[359,546,548],{"id":547},"types","Types",[299,550,555],{"className":551,"code":553,"language":554,"meta":305},[552],"language-ts","interface FormError {\n  name: string\n  message: string\n  id?: string\n}\n","ts",[307,556,553],{"__ignoreMap":305},{"title":305,"searchDepth":558,"depth":558,"links":559},2,[560,561,562,563,564],{"id":293,"depth":558,"text":16},{"id":311,"depth":558,"text":312},{"id":323,"depth":558,"text":324},{"id":343,"depth":558,"text":344},{"id":356,"depth":558,"text":357,"children":565},[566,568,569],{"id":361,"depth":567,"text":362},3,{"id":499,"depth":567,"text":500},{"id":547,"depth":567,"text":548},"md",{},true,{"title":78,"description":158},"t0l9xixgV6IuwJJUDnTNUqbHCIfKwwWEnZJe67VN-xk",[576,577],{"title":74,"path":75,"stem":76,"children":-1},{"title":82,"path":83,"stem":84,"children":-1},1782805881470]