Skip to content

🖌️ Add draggable first-page letterhead layout editor - #37

Merged
JFWooten4 merged 1 commit into
mainfrom
letterhead-drag-drop-layout-20261013
Oct 13, 2026
Merged

JFWooten4 merged 1 commit into
mainfrom
letterhead-drag-drop-layout-20261013

Conversation

@JFWooten4

Copy link
Copy Markdown
Member

Summary

Adds an opt-in visual editor to the Letterhead step, with a paper-like drag-and-drop canvas for arranging the information shown on page 1.

  • Move the existing first-page header, logo/wordmark, visible document title, Quote #, date, submission subtitle, and addressee.
  • Select a field to adjust its width, alignment, and visibility. Drag with a pointer, or use arrow keys (Shift for larger nudges).
  • Add, edit, position, and remove up to 12 custom labeled text fields.
  • Reset to the suggested preset positions or disable the layout editor to retain the original fixed letterhead layout.
  • Mirror the existing form values and logo preview without creating duplicate text inputs for preset information.

PDF integration and compatibility

  • The browser submits normalized coordinates and field definitions, not untrusted drawing instructions.
  • The renderer validates field types, limits, widths, positions, duplicates, and custom-field lengths.
  • Page 1 uses the requested coordinates; the body is moved below the lowest visible field, and an addressee placed by the editor is not repeated in the body.
  • Existing requests without a custom layout continue to use the original first-page rendering.

The feature extends earlier letterhead work:
#11

#15

#29

Verification

  • Confirmed the commit differs from main by the six intended files.
  • Verified JavaScript parses successfully.
  • Added Python regression tests covering layout validation, custom field rendering, positions, visibility, first-page body separation, and the API's validation response.
  • Python rendering tests have not been executed locally in this environment. Review and run python -m unittest discover -s tests before merging.

Add an opt-in visual letterhead canvas for moving, aligning, and hiding preset fields and placing custom labeled text. Validate the layout on submission, render it on page one with body-space reservation, and cover legacy fallback and PDF positions in regression tests.

Co-authored-by: Codex Web <noreply@openai.com>
@vercel

vercel Bot commented Oct 13, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
pdf Ready Ready Preview Oct 13, 2026 6:33pm UTC

@JFWooten4
JFWooten4 merged commit 06ea4b6 into main Oct 13, 2026
2 checks passed
@JFWooten4
JFWooten4 deleted the letterhead-drag-drop-layout-20261013 branch October 13, 2026 18:47
JFWooten4 added a commit that referenced this pull request Oct 13, 2026
Reconcile the separate first-page letterhead squash merge with the expanded layout editor, professional filing style, and portable configuration work. Preserve the existing PR #37 README feature entry alongside PR #38 documentation.

Co-authored-by: Codex Web <noreply@openai.com>
JFWooten4 pushed a commit that referenced this pull request Oct 13, 2026
…ble letterhead layout

Add the Professional filing typography preset, portable configuration import/export, enhanced draggable first-page letterhead controls, updated footnote layout handling, and regression tests. Preserve the letterhead editor separately merged in PR #37 and its documentation.

Co-authored-by: Codex Web <noreply@openai.com>

This branch was successfully deployed

1 active deployment
Preview — 7cfc205d Deployed Oct 13, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant