[{"data":1,"prerenderedAt":154},["ShallowReactive",2],{"\u002Fwork\u002Fcustom-form-builder":3,"\u002Fwork\u002Fcustom-form-builder-surround":145},{"id":4,"title":5,"approach":6,"body":7,"category":125,"description":126,"extension":127,"gallery":128,"image":129,"meta":132,"navigation":133,"order":120,"overview":134,"path":135,"problem":136,"result":137,"seo":138,"stem":139,"tags":140,"__hash__":144},"projects\u002Fwork\u002Fcustom-form-builder.md","Custom Form Builder","Modeled the paper form rather than a general layout language. A typed JSON schema covers page setup, subject columns, header panels, sections of rows, certification, signatures, footer and PDF file name. One renderer draws a definition in three modes, fill, preview and print, so the builder’s live preview is the same component tree the PDF server prints. A hand-written parser validates and repairs every definition before anything renders.",{"type":8,"value":9,"toc":118},"minimark",[10,15,19,23,76,80],[11,12,14],"h2",{"id":13},"my-role","My role",[16,17,18],"p",{},"I designed and built the custom form system end to end, inside an existing Nuxt app that generates PDFs for FileMaker: the schema, the builder, the renderer, the print pipeline and the contracts for the FileMaker scripts.",[11,20,22],{"id":21},"what-the-builder-does","What the builder does",[24,25,26,34,40,46,52,58,64,70],"ul",{},[27,28,29,33],"li",{},[30,31,32],"strong",{},"Three-column editor:"," the saved forms on the left, an outline of the form in printed order in the middle, and a live preview of the real printed sheet on the right.",[27,35,36,39],{},[30,37,38],{},"Paper and layout:"," paper size, orientation, margins, text size and row heights, with as many sheets per form as needed and columns sized by percentage.",[27,41,42,45],{},[30,43,44],{},"Row types:"," compliance marks that cycle through check, X and circled X for each door, ruled text lines, circled Yes \u002F No, checkboxes and spacers. Enter adds the next row and focuses it, since rows are most of the work.",[27,47,48,51],{},[30,49,50],{},"Sections and comments:"," titled runs of rows with comments per section, per row or none, and optional sub-columns per door, such as activating and safety sensors.",[27,53,54,57],{},[30,55,56],{},"Header, certification and sign-off:"," boxed header panels with styled text and fill-in fields, certification text with its own questions, and signature blocks with signature pads that can stamp the date.",[27,59,60,63],{},[30,61,62],{},"PDF file names:"," choose which answers name the generated PDF, such as the facility and work ticket number.",[27,65,66,69],{},[30,67,68],{},"Try before saving:"," open the form exactly as a technician will see it, fill it in, then return to the builder.",[27,71,72,75],{},[30,73,74],{},"Working copies:"," each form keeps its own unsaved copy, so switching between forms loses nothing and the list shows which ones have unsaved changes.",[11,77,79],{"id":78},"under-the-hood","Under the hood",[24,81,82,88,94,100,106,112],{},[27,83,84,87],{},[30,85,86],{},"One renderer, three modes:"," filling, previewing and printing share one component tree, so what you build is what prints.",[27,89,90,93],{},[30,91,92],{},"No breakpoints:"," the renderer compares its own width to the sheet’s paper width and switches between the printed sheet and a stacked layout with larger touch targets, so a portrait form never prints the phone view.",[27,95,96,99],{},[30,97,98],{},"Validation as a trust boundary:"," definitions can be edited by hand in FileMaker and drive a headless Chromium render, so the parser repairs what it can, reports every problem with its location, and refuses a form from a newer schema version rather than printing a compliance sheet with rows missing.",[27,101,102,105],{},[30,103,104],{},"Safe saves:"," every save carries the revision it was based on, so two people editing the same form can’t overwrite each other, and a working copy is only dropped once FileMaker confirms the save. A delete waits for FileMaker to answer before the form leaves the list.",[27,107,108,111],{},[30,109,110],{},"FileMaker Pro and WebDirect:"," the builder runs in FileMaker Pro over the JavaScript bridge, while technicians fill forms in WebDirect, where that bridge doesn’t exist, through a Data API proxy that only accepts requests carrying a launch token signed by FileMaker.",[27,113,114,117],{},[30,115,116],{},"Acceptance check:"," a verify script tests the layout maths against the numbers hardcoded in the hand-written swinging door sheet, so any change that stops the schema reproducing it fails.",{"title":119,"searchDepth":120,"depth":120,"links":121},"",2,[122,123,124],{"id":13,"depth":120,"text":14},{"id":21,"depth":120,"text":22},{"id":78,"depth":120,"text":79},"Vue + FileMaker","A visual builder for printable inspection sheets, so a new form is something office staff design and save to FileMaker rather than new code and a redeploy.","md",null,{"src":130,"alt":131},"\u002Fimages\u002Fprojects\u002Fcustom-form-builder.png","Dev view showing the custom form builder with the saved forms on the left, an outline of the form in printed order in the middle, and a live preview of the real printed sheet on the right",{},true,"An automatic door inspection company files every job as a printed, signed inspection sheet generated from FileMaker. Each sheet was a hand-written Vue page, so every new form needed a developer and a deploy. I designed and built a form builder that describes a sheet as JSON, shows the exact printed output live as you edit, and stores the definition in FileMaker for technicians to fill in and print to PDF.","\u002Fwork\u002Fcustom-form-builder","The five AAADM inspection sheets were roughly 85% copies of each other, and adding a sixth meant another 400-line page, six more components, a new store and a form name wired into four separate places. Only a developer could add or change a form.","The AAADM swinging door sheet, rebuilt purely as a definition, prints a PDF visually indistinguishable from the hand-written page on one landscape Letter page. New inspection sheets are now built, saved to FileMaker and filled in by technicians without touching code.",{"title":5,"description":126},"work\u002Fcustom-form-builder",[141,142,143],"Vue","FileMaker","PDF Generation","FAIIEVfVhM5fwdjFUeUSGufobbqqb4Bl25fAp-PZ-hg",[146,150],{"title":147,"path":148,"stem":149,"children":-1},"FM Agent","\u002Fwork\u002Ffm-agent","work\u002Ffm-agent",{"title":151,"path":152,"stem":153,"children":-1},"Dynamic PDF Printouts","\u002Fwork\u002Fdynamic-pdf-printouts","work\u002Fdynamic-pdf-printouts",1796498995750]