shadcn.io is not affiliated with official shadcn/ui
Form Filler AI Block for Svelte
Fill a profile form from pasted text: seven fixed patterns find a name, website, email, phone, founding year, headcount and first sentence, show the line each came from, and mark Edited fields.
Installation
Overview
Save people retyping what they already have, with this form filler for Svelte with Ark UI. A hairline frame with a plus mark on each corner holds a source Textarea at the start with a short company blurb, and at the end a profile form: name, website, email, phone, founded, headcount and about. The Shine Button, the only colored control, runs a real extraction by patterns, seven regular expressions kept in the file: an email, a web address, a phone number, a year after "founded", a number before "people", a name before "is a" and the first sentence. Each field says "Found on line 2" and a Show button marks the match inside its source line, or the field says "Not found in the text". A field you change gets an Edited Badge, and Clear empties the form. It reads patterns in the text; it does not understand it, and the page says so. Guides rule the bands. For onboarding, CRMs and any form that could be filled from a pasted signature or profile.
FAQ
What stays in the page, and how do I make it real?
Everything. The text, the seven patterns and the form values are in the page, and nothing is sent or read by a model. To make it real, replace matchOf with a call to your extraction service that returns the value and where it was found, and keep the rest of the form.
What do the patterns look for?
An address with an at sign, a www address, a run of at least nine digits and punctuation for a phone, four digits after founded, established or since, a number before people, employees or staff, a capitalised name before is a or are a, and the first sentence. Change the text so a pattern no longer matches and the field says it was not found.
What does Show do?
It prints the source line under the text with the matched part marked, so you can check it. Show is off for a field you have edited, since its value no longer comes from the text.
What happens when I fill again after editing?
Every field is read again from the current text, edits are dropped and the Edited badges clear. Clear leaves the text and empties the form.