Skip to content

feat(templates): layered proposal/v2 ModernProposal on the extracted core#269

Merged
DemchaAV merged 1 commit into
2.0-devfrom
feat/proposal-v2
Jun 29, 2026
Merged

feat(templates): layered proposal/v2 ModernProposal on the extracted core#269
DemchaAV merged 1 commit into
2.0-devfrom
feat/proposal-v2

Conversation

@DemchaAV

Copy link
Copy Markdown
Owner

Why

Completes the Stage-2 invoice/proposal migration: a proposal/v2 layered family on core + BrandTheme, mirroring invoice/v2 (#257 / #264), so the proposal family can render on the layered stack and eventually replace the cinematic builtin.

What

  • core.theme: BrandTheme.proposalModern() + Typography.proposalModern() (richer h1 / h2 / h3 scale). Reuses Palette.invoiceModern() + Spacing.invoiceModern() — invoice + proposal share one modern business look (a neutral businessModern() rename is a deferred cleanup; the invoice side is byte-unaffected).
  • proposal/v2/presets/ModernProposal (DocumentTemplate<ProposalDocumentSpec>): hero, executive summary, FROM / TO parties, body sections, timeline + pricing tables, acceptance terms, footer — all reading the theme.
  • Bug-fix-forward: builtins/ProposalTemplateV2 never .build()s its first page-flow, so the cinematic proposal silently drops its title / summary / parties (the PDF starts at "Scope"). ModernProposal builds it, so the header renders. The visual-parity baseline is the corrected render. (A separate task is filed to fix the 1.x builtin.)
  • Parties render inline (two-party layout, optional fields) — not core.PartyIdentity, same reasoning as invoice. Table body cells inherit the DSL default to match the builtin.
  • example (on the cream page) + a GenerateAllExamples row.
  • smoke test (5 cases) + ProposalV2VisualParityTest + a blessed 2-page baseline.
  • data.proposal package-info reframed (now backs both the builtin and proposal/v2).

Tests

./mvnw verify javadoc:javadoc -pl . → BUILD SUCCESS, 1625 tests, 0 failures; javadoc clean. The example renders the full proposal (header + sections + tables); visual parity green against the committed baseline.

…core

Add a proposal/v2 family mirroring invoice/v2: ModernProposal
(DocumentTemplate<ProposalDocumentSpec>) renders a proposal on
templates.core + a BrandTheme, porting the cinematic
builtins/ProposalTemplateV2 look — hero, executive summary, FROM / TO
parties, body sections, timeline + pricing tables, acceptance terms,
and footer.

- core.theme: BrandTheme.proposalModern() + Typography.proposalModern()
  (richer h1 / h2 / h3 scale); reuses the invoice palette + spacing — the
  two families share one modern business look.
- ModernProposal fixes a latent bug in the builtin: its first page-flow
  (hero + summary + parties) was never built and silently dropped, so the
  cinematic proposal rendered with no header. The layered preset builds
  it, so the header renders.
- Parties render inline (two-party layout, optional fields), not through
  the CV-shaped PartyIdentity. Table body cells inherit the DSL default to
  match the builtin.
- example (on the cream page background) + a GenerateAllExamples row.
- smoke test (5 cases) + ProposalV2VisualParityTest + blessed baseline.
- data.proposal package-info: note it backs both the builtin and proposal/v2.
@DemchaAV DemchaAV merged commit 5fa3358 into 2.0-dev Jun 29, 2026
11 checks passed
@DemchaAV DemchaAV deleted the feat/proposal-v2 branch June 29, 2026 15:22
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