Skip to content

fix(templates): draw the employer in Monogram Sidebar experience entries - #577

Open
DemchaAV wants to merge 1 commit into
fix/pdf-latin-text-layerfrom
fix/cv-monogram-employer-and-cap-docs
Open

fix(templates): draw the employer in Monogram Sidebar experience entries#577
DemchaAV wants to merge 1 commit into
fix/pdf-latin-text-layerfrom
fix/cv-monogram-employer-and-cap-docs

Conversation

@DemchaAV

Copy link
Copy Markdown
Owner

Stacked on #576 — retarget to develop once that merges.

Why

MonogramSidebar.addExperienceEntries rendered entry.title(), entry.date() and
entry.body() and never entry.subtitle(). In an experience section the subtitle is the
employer, so every company name was missing from the rendered CV. The education path in
the same preset does render its subtitle, which is what made the gap look accidental
rather than chosen.

Separately, three presets drop content without saying so. MonogramSidebar,
SidebarPortrait and MintEditorial each cap their blocks — a caller with four jobs who
picks one of them gets two, and nothing in the API or the produced PDF reports it.

What changed

The employer is drawn between the position and the date, in theme.entrySubtitleStyle()
— the shared theme style, not a preset-local one.

Each of the three presets documents its own caps, and the gallery
(docs/templates/v2-layered/using-templates.md) carries the same table under Picking a
preset
.

The caps themselves are unchanged, and the documentation says why. Each preset builds
its columns as one addRow, which is atomic: it fits a page whole or the paginator raises
AtomicNodeTooLargeException. Removing every cap and rendering a dense CV through the
three presets reproduces that immediately — MonogramSidebar asks for 1043pt of an
841pt page, SidebarPortrait 1157pt, MintEditorial 894pt of 745pt — and it does so at
two experience entries, because the skill and education caps are load-bearing too. So
lifting them does not paginate; it turns a CV that silently lost an entry into one that
fails to render. Doing it properly means teaching each preset to pick its own page
boundaries, the way TimelineMinimal does with ColumnPagination — which that helper
cannot serve as written, since it models flattened text blocks and these presets carry a
monogram ring, an SVG contact stack, a portrait and skill bars.

Verification

./mvnw -B -ntp clean verify -pl :graph-compose-core,:graph-compose-render-pdf,:graph-compose-render-docx,:graph-compose-render-pptx,:graph-compose-templates,:graph-compose-testing,:graph-compose-qa,:graph-compose-coverage -am — BUILD SUCCESS, 762 qa tests.
./mvnw -B -ntp javadoc:javadoc -pl :graph-compose-core,:graph-compose-templates — BUILD SUCCESS.

  • MonogramSidebarContentFidelityTest (qa, 2 tests) pins that an experience entry names
    its employer, and that the entry past the documented cap is the only one missing. Both
    go red without this change.
  • One visual baseline (cv-v2-layered/monogram_sidebar-page-0.png) and one committed
    preview (cv-monogram-sidebar-v2.pdf) carry the extra line; the drift gate names no
    others.

An experience entry rendered the position, the date and the description
and never CvEntry.subtitle(), so every company name was missing from the
rendered CV. The education block in the same preset does render its
subtitle, which is what made the gap look accidental rather than chosen.
The employer is now drawn between the position and the date, in the
shared theme entry-subtitle style.

The three presets that cap content — Monogram Sidebar, Sidebar Portrait
and Mint Editorial — now say so. Entries past a per-block cap are not
drawn, do not move to a continuation page, and are reported nowhere, so a
caller picking one of them had no way to learn that a four-job CV shows
two. Each class documents its own caps and the gallery carries the same
table.

The caps stay, and the documentation says why: the columns are one
addRow, which is atomic, so an uncapped block does not spill onto a
second page — it raises AtomicNodeTooLargeException and the CV does not
render at all. Removing every cap and rendering a dense CV through each
preset reproduces that immediately. Lifting them means teaching each
preset to pick its own page boundaries first, the way TimelineMinimal
does with ColumnPagination.

Tests: MonogramSidebarContentFidelityTest pins the employer and the
documented cap; both go red without this change. Full reactor gate green
(762 qa tests). The Monogram Sidebar visual baseline and committed
preview carry the extra line.
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