Skip to content

feat: add sidebar-cv Typst theme with typography/color settings#2

Merged
tamaygz merged 28 commits into
mainfrom
copilot/add-latex-template-resume-editor
May 25, 2026
Merged

feat: add sidebar-cv Typst theme with typography/color settings#2
tamaygz merged 28 commits into
mainfrom
copilot/add-latex-template-resume-editor

Conversation

Copilot AI commented May 22, 2026

Copy link
Copy Markdown

This pull request adds a new "Typst Theme Style" section to the settings page, allowing users to customize fonts and colors for Typst-rendered PDF resumes. It introduces new form fields, updates default and null payloads, and integrates the new settings into the navigation, form handling, and data mapping logic. Additionally, it refactors file and import paths for consistency with the new structure.

New Typst Theme Style Section and Settings:

  • Added a new TypstStyleSettingsSection component that allows users to override fonts and colors for Typst PDF resumes, including custom font pickers and color pickers with validation and previews. (orchestrator/src/client/pages/settings/components/TypstStyleSettingsSection.tsx)
  • Integrated the "Typst Theme Style" section into the settings navigation, section mapping, and form handling logic, including default values, null payloads, and dirty field checks. (orchestrator/src/client/pages/settings/index.tsx) [1] [2] [3] [4] [5] [6] [7] [8] [9] [10]

Refactoring and File Organization:

  • Renamed SettingsPage files and updated import paths throughout the codebase to use the new lowercase settings directory, improving consistency and organization. (orchestrator/src/client/App.tsx, orchestrator/src/client/App.test.tsx, orchestrator/src/client/pages/settings/index.test.tsx) [1] [2] [3]

These changes collectively enhance the flexibility and user experience for customizing Typst-rendered resumes and improve the maintainability of the settings code.

Copilot AI and others added 2 commits May 22, 2026 12:27
Add a new "Sidebar CV" Typst theme inspired by the user's CV design.
Features a tinted left sidebar with photo, name, headline, summary,
skills, languages, and contact details, with the main content area
on the right for professional experience and other sections.

Agent-Logs-Url: https://github.com/tamaygz/job-ops/sessions/ffb0aacb-46e9-4725-b797-661aeab6cca3

Co-authored-by: tamaygz <92460164+tamaygz@users.noreply.github.com>
- Split name across two lines with wide 8pt tracking
- Larger 26pt name, regular weight (not bold) to match original
- Bold italic headline at 12pt
- Sidebar section headings: 12pt, 2pt tracking, centered gray line
- Main section headings: 16pt, 2pt tracking, teal accent
- Entry titles: 11pt bold uppercase with pipe separator
- Date/location line: 8.5pt small caps
- Body text: paragraph style with 14pt first-line indent
- Contact block includes full name above address
- Sidebar padding and main padding adjusted for balance

Agent-Logs-Url: https://github.com/tamaygz/job-ops/sessions/594f2a8d-264d-4452-b4dc-b72043d0aea0

Co-authored-by: tamaygz <92460164+tamaygz@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new adapted Typst resume theme (sidebar-cv) to the resume renderer, providing a two-column layout with a tinted sidebar intended for photo/summary/contact content while keeping experience and other sections in the main column.

Changes:

  • Added sidebar-cv to the generated Typst theme enums/labels/descriptions.
  • Added a new sidebar-cv theme manifest (theme.json) registered as an adapted theme.
  • Implemented the sidebar-cv Typst template (main.typ) with sidebar + main-column rendering driven by resume-data.json.

Reviewed changes

Copilot reviewed 2 out of 3 changed files in this pull request and generated 3 comments.

File Description
shared/src/generated/typst-themes.ts Registers sidebar-cv in the generated theme list/metadata.
orchestrator/src/server/services/resume-renderer/typst-themes/sidebar-cv/theme.json Adds the theme manifest for the new adapted theme.
orchestrator/src/server/services/resume-renderer/typst-themes/sidebar-cv/main.typ Adds the full Typst template implementing the sidebar CV layout.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread orchestrator/src/server/services/resume-renderer/typst-themes/sidebar-cv/main.typ Outdated
…nder, add render test

Agent-Logs-Url: https://github.com/tamaygz/job-ops/sessions/5cdbc21b-75a7-404a-b924-11244bd099c5

Co-authored-by: tamaygz <92460164+tamaygz@users.noreply.github.com>
Copilot AI and others added 3 commits May 22, 2026 16:34
@tamaygz

tamaygz commented May 22, 2026

Copy link
Copy Markdown
Owner

@copilot when selecting typst compact or classic I now see this error:
Preview unavailable
Typst failed with exit code 1. warning: unknown font family: ibm plex serif ┌─ resume.typ:2:16 │ 2 │ #set text(font: "IBM Plex Serif", size: 9pt, lang: "en", fill: rgb("#000000")) │ ^^^^^^^^^^^^^^^^ warning: unknown font family: ibm plex serif ┌─ resume.typ:17:14 │ 17 │ #text(font: "IBM Plex Serif", size: 18pt, weight: "bold", fill: rgb("#dc2626"))[Tamay Gündüz] \ │ ^^^^^^^^^^^^^^^^ error: unknown variable: HEADING_FONT ┌─ resume.typ:18:14 │ 18 │ #text(font: HEADING_FONT, size: 8.5pt, fill: TEXT_COLOR)[Founder of Arqio | Al co-pilot for architects, developers and regulators: decode rules, prepare permit docs, save time. | German living in Barcelona] \ │ ^^^^^^^^^^^^^^^^

Fix root cause

…ons to resolve __HEADING_FONT__ in headlineBlock

Agent-Logs-Url: https://github.com/tamaygz/job-ops/sessions/66941e30-cbe6-44db-b58a-545f85c9091b

Co-authored-by: tamaygz <92460164+tamaygz@users.noreply.github.com>

Copilot AI commented May 22, 2026

Copy link
Copy Markdown
Author

@copilot when selecting typst compact or classic I now see this error:
Preview unavailable
Typst failed with exit code 1. warning: unknown font family: ibm plex serif ┌─ resume.typ:2:16 │ 2 ��...

Fixed in c33f5d0. Root cause: in buildTypstDocument, replaceStylePlaceholders ran on the static template first, but headlineBlock (which contains literal __HEADING_FONT__ and __TEXT_COLOR__) was injected afterward via .replace("__HEADLINE_BLOCK__", headlineBlock) — so those placeholders were never resolved, causing the Typst compile error.

The fix reorders the call so replaceStylePlaceholders wraps the fully-expanded document (after all block substitutions), ensuring every placeholder including those in the dynamically-generated headline block is replaced.

@tamaygz

tamaygz commented May 22, 2026

Copy link
Copy Markdown
Owner

In our new sidebar-cv theme, only the first page is rendered. When I change to anopther typst theme, i see multiple pages (correctly). Analyse and fix rootcause. @copilot

Copilot AI and others added 2 commits May 25, 2026 06:32
- types.ts: add LatexResumeOrderedSectionKey type, sectionOrder field in LatexResumeDocument, and type aliases (ResumeRenderDocument, NormalizeResumeJsonOptions, etc.)
- document.ts: add ORDERABLE_SECTION_KEYS, getOrderedSectionKeys(), improved stripHtml preserving bold/italic tags, sectionOrder field in normalizeResumeJsonToLatexDocument, buildResumeRenderDocument alias
- index.ts: export buildResumeRenderDocument alongside normalizeResumeJsonToLatexDocument
- typst.ts: add escapeRawTypst + HTML-aware escapeTypstText, renderOrderedCoreSections, convertDocFieldsToTypst; wire sectionOrder into buildTypstDocument; use convertDocFieldsToTypst for adapted themes
- typst.test.ts: add section ordering, HTML formatting, and convertDocFieldsToTypst tests; import convertDocFieldsToTypst
- document.test.ts: add "preserves basic formatting tags and strips other HTML tags" test

Agent-Logs-Url: https://github.com/tamaygz/job-ops/sessions/fad5eadd-65e5-48a3-8dda-1d0de30b38e6

Co-authored-by: tamaygz <92460164+tamaygz@users.noreply.github.com>
@tamaygz

tamaygz commented May 25, 2026

Copy link
Copy Markdown
Owner

@copilot carefully review and resolve the merge conflicts

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 27 out of 29 changed files in this pull request and generated 3 comments.

Comment thread orchestrator/src/server/services/resume-renderer/typst.ts Outdated
Comment thread orchestrator/src/server/services/pdf.ts Outdated
…, kanban, section-ordering)

Merge upstream commits:
- 4d86871 Profile items in header (DaKheera47#553)
- e183cdd Show bold text in local PDF renderers (DaKheera47#551)
- 199ad9c fix: kanban horizontal auto-scroll (DaKheera47#550)
- 60107ef chore: release 0.8.0
- 239dde3 Ordering resume sections (DaKheera47#545)

Conflict resolutions:
- types.ts: keep LatexResumeStyle/LatexResumeStyleOverrides (our feature)
- document.ts: keep buildStyle/normalizeColorToHex/componentToHex/clamp (our feature)
- document.test.ts: keep color normalization test (our feature)
- index.ts: use NormalizeResumeJsonOptions, keep LatexResumeStyleOverrides import
- typst.ts: keep LatexResumeStyleOverrides import, simplified tagStack.pop(), normalizeTypstDocumentPicturePath; remove duplicate renderOrderedCoreSections brought in by merge
- typst.test.ts: keep picture path normalization tests (our feature)

Co-authored-by: tamaygz <92460164+tamaygz@users.noreply.github.com>

Copilot AI commented May 25, 2026

Copy link
Copy Markdown
Author

@copilot carefully review and resolve the merge conflicts

Resolved in be73aae. The upstream had moved forward 5 commits since our merge base (dd140e3) — profile items in header, bold text in PDF renderers, kanban fix, 0.8.0 release, and section ordering. Conflicts were resolved as follows:

  • types.ts: kept our LatexResumeStyle/LatexResumeStyleOverrides types (upstream removed them)
  • document.ts: kept buildStyle/normalizeColorToHex/componentToHex functions and style: buildStyle(record) field
  • document.test.ts: kept our color normalization test
  • index.ts: switched to upstream's NormalizeResumeJsonOptions while keeping our LatexResumeStyleOverrides import and typstStyleOverrides passthrough
  • typst.ts: kept LatexResumeStyleOverrides import, our simplified tagStack.pop() logic, and normalizeTypstDocumentPicturePath; removed the duplicate renderOrderedCoreSections that the merge brought in
  • typst.test.ts: kept our picture path normalization tests

All 35 resume-renderer tests pass.

… resolveTypstStyleOverrides return type

Agent-Logs-Url: https://github.com/tamaygz/job-ops/sessions/b3e79194-7bbc-4a92-9a61-53ab3e09f241

Co-authored-by: tamaygz <92460164+tamaygz@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 27 out of 29 changed files in this pull request and generated 1 comment.

Comment thread orchestrator/src/server/services/resume-renderer/typst.ts Outdated
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 27 out of 29 changed files in this pull request and generated no new comments.

@tamaygz

tamaygz commented May 25, 2026

Copy link
Copy Markdown
Owner

@copilot see here for a list of failing checks: https://github.com/DaKheera47/job-ops/pull/549/checks
fix the root causes!

image 2s Run biome ci . orchestrator/src/client/App.tsx:5:1 FIXABLE ━━━━━━━━━━━━━━━━━━━━━━━━

✖ The imports and exports are not sorted.

3 │  */
4 │ 

5 │ import { X } from "lucide-react";
│ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
6 │ import React, { useEffect, useRef, useState } from "react";
7 │ import {

ℹ Safe fix: Organize Imports (Biome)

 28  28 │   import { OnboardingPage } from "./pages/OnboardingPage";
 29  29 │   import { OrchestratorPage } from "./pages/OrchestratorPage";
 30     │ - import·{·SettingsPage·}·from·"./pages/settings";
 31     │ - import·{·SignInPage·}·from·"./pages/SignInPage";
     30 │ + import·{·SignInPage·}·from·"./pages/SignInPage";
     31 │ + import·{·SettingsPage·}·from·"./pages/settings";
 32  32 │   import { TracerLinksPage } from "./pages/TracerLinksPage";
 33  33 │   import { TrackingInboxPage } from "./pages/TrackingInboxPage";

Checked 884 files in 1950ms. No fixes applied.
Found 1 error.
ci ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

✖ Some errors were emitted while running checks.

Error: Process completed with exit code 1.

⎯⎯⎯⎯⎯⎯ Failed Suites 1 ⎯⎯⎯⎯⎯⎯⎯

FAIL src/client/pages/settings/index.test.tsx [ src/client/pages/settings/index.test.tsx ]
Error: Failed to resolve import "../api" from "src/client/pages/settings/index.test.tsx". Does the file exist?
Plugin: vite:import-analysis
File: /home/runner/work/job-ops/job-ops/orchestrator/src/client/pages/settings/index.test.tsx:7:0
65 | const vi_import_3 = await import("react-router-dom");
66 | const vi_import_4 = await import("sonner");
67 | const vi_import_5 = await import("../api");
| ^
68 | const vi_import_6 = await import("../hooks/useTracerReadiness");
69 | const vi_import_7 = await import("../test/renderWithQueryClient");
❯ TransformPluginContext._formatLog ../node_modules/vite/dist/node/chunks/node.js:30408:39
❯ TransformPluginContext.error ../node_modules/vite/dist/node/chunks/node.js:30405:14
❯ normalizeUrl ../node_modules/vite/dist/node/chunks/node.js:27662:18
❯ ../node_modules/vite/dist/node/chunks/node.js:27725:30
❯ TransformPluginContext.transform ../node_modules/vite/dist/node/chunks/node.js:27693:4
❯ EnvironmentPluginContainer.transform ../node_modules/vite/dist/node/chunks/node.js:30193:14
❯ loadAndTransform ../node_modules/vite/dist/node/chunks/node.js:24511:26

⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯[1/1]⎯

Test Files 1 failed | 237 passed (238)
Tests 1530 passed | 4 skipped (1534)
Start at 09:58:37
Duration 115.48s (transform 13.02s, setup 25.30s, import 72.03s, tests 151.31s, environment 158.44s)

npm error Lifecycle script test:run failed with error:
npm error code 1
npm error path /home/runner/work/job-ops/job-ops/orchestrator
npm error workspace job-ops-orchestrator@0.8.0
npm error location /home/runner/work/job-ops/job-ops/orchestrator
npm error command failed
npm error command sh -c vitest run
Error: Process completed with exit code 1.

17s
Run npm --workspace orchestrator run check:types

job-ops-orchestrator@0.8.0 check:types
tsc --noEmit

Error: src/client/pages/settings/index.test.tsx(7,22): error TS2307: Cannot find module '../api' or its corresponding type declarations.
Error: src/client/pages/settings/index.test.tsx(8,44): error TS2307: Cannot find module '../hooks/useTracerReadiness' or its corresponding type declarations.
Error: src/client/pages/settings/index.test.tsx(9,39): error TS2307: Cannot find module '../test/renderWithQueryClient' or its corresponding type declarations.
Error: src/client/pages/settings/index.test.tsx(10,30): error TS2307: Cannot find module './SettingsPage' or its corresponding type declarations.
npm error Lifecycle script check:types failed with error:
npm error code 2
npm error path /home/runner/work/job-ops/job-ops/orchestrator
npm error workspace job-ops-orchestrator@0.8.0
npm error location /home/runner/work/job-ops/job-ops/orchestrator
npm error command failed
npm error command sh -c tsc --noEmit
Error: Process completed with exit code 2.

…aths in settings/index.test.tsx

Agent-Logs-Url: https://github.com/tamaygz/job-ops/sessions/0418b07a-41f6-4e0a-98d6-f26d1433b952

Co-authored-by: tamaygz <92460164+tamaygz@users.noreply.github.com>

Copilot AI commented May 25, 2026

Copy link
Copy Markdown
Author

@copilot see here for a list of failing checks: https://github.com/DaKheera47/job-ops/pull/549/checks
fix the root causes!

...

Fixed in ac1ed22. Two root causes:

  1. Biome linting (App.tsx): SettingsPage and SignInPage imports were in the wrong order — Biome requires ./pages/SignInPage before ./pages/settings (uppercase sorts before lowercase). Swapped them.

  2. Tests + Type Check (settings/index.test.tsx): The test file was moved from pages/SettingsPage.test.tsx to pages/settings/index.test.tsx but relative import paths were never updated. Fixed all five paths (../api../../api, ../hooks/useTracerReadiness../../hooks/useTracerReadiness, ../test/renderWithQueryClient../../test/renderWithQueryClient, ./SettingsPage./index, and the matching vi.mock path).

@tamaygz tamaygz marked this pull request as ready for review May 25, 2026 13:24
@tamaygz tamaygz merged commit ee4bb89 into main May 25, 2026
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.

3 participants