From 31c58baed497516013bba606a5f85907724a4af9 Mon Sep 17 00:00:00 2001 From: Amruth Pillai Date: Wed, 30 Sep 2026 01:27:21 +0200 Subject: [PATCH] feat(applications): enhance application stage tracking and improve form handling --- .../components/add-application-dialog.tsx | 7 ++-- .../components/application-detail-sheet.tsx | 4 +- .../src/features/applications/next-step.ts | 8 +++- .../src/features/assistant/conversation.tsx | 2 + .../web/src/features/resume/editor/chrome.tsx | 2 +- .../src/features/resume/stylesheet/editor.tsx | 1 + apps/web/src/hooks/use-form-blocker.tsx | 40 +++++++------------ .../$resumeId/-components/editor-shell.tsx | 1 + .../letter/-components/letter-shell.tsx | 1 + .../routes/dashboard/applications/index.tsx | 2 + biome.json | 1 + .../pdf/src/templates/azurill/AzurillPage.tsx | 16 +------- .../pdf/src/templates/bronzor/BronzorPage.tsx | 16 +------- .../src/templates/chikorita/ChikoritaPage.tsx | 2 +- .../pdf/src/templates/ditgar/DitgarPage.tsx | 15 +------ .../pdf/src/templates/ditto/DittoPage.tsx | 16 +------- .../pdf/src/templates/gengar/GengarPage.tsx | 16 +------- .../pdf/src/templates/glalie/GlaliePage.tsx | 16 +------- .../pdf/src/templates/kakuna/KakunaPage.tsx | 14 +------ .../pdf/src/templates/lapras/LaprasPage.tsx | 16 +------- .../pdf/src/templates/leafish/LeafishPage.tsx | 16 +------- .../pdf/src/templates/meowth/MeowthPage.tsx | 16 +------- packages/pdf/src/templates/onyx/OnyxPage.tsx | 15 +------ .../pdf/src/templates/pikachu/PikachuPage.tsx | 17 +------- .../pdf/src/templates/rhyhorn/RhyhornPage.tsx | 18 +-------- .../pdf/src/templates/scizor/ScizorPage.tsx | 19 +-------- 26 files changed, 51 insertions(+), 246 deletions(-) diff --git a/apps/web/src/features/applications/components/add-application-dialog.tsx b/apps/web/src/features/applications/components/add-application-dialog.tsx index 28c057ae4..e68925b39 100644 --- a/apps/web/src/features/applications/components/add-application-dialog.tsx +++ b/apps/web/src/features/applications/components/add-application-dialog.tsx @@ -71,7 +71,7 @@ function AddApplicationForm({ onClose, onAdded }: { onClose: () => void; onAdded const [role, setRole] = useState(""); const [company, setCompany] = useState(""); const [stage, setStage] = useState("applied"); - const [parsed, setParsed] = useState(null); + const [reading, setReading] = useState<{ text: string; result: Parsed } | null>(null); const { hasUsableProvider } = useHasUsableAiProvider(); const invalidate = useInvalidateApplications(); const openDialog = useDialogStore((state) => state.openDialog); @@ -84,9 +84,10 @@ function AddApplicationForm({ onClose, onAdded }: { onClose: () => void; onAdded const link = isLink(text); // A link can always be read (for the page's own job data); pasted text needs the AI provider. const readable = text.length > 8 && (link || hasUsableProvider); + // A reading belongs to the text it was made from: editing the text drops it. + const parsed = readable && reading?.text === text ? reading.result : null; useEffect(() => { - setParsed(null); resetRead(); if (!readable) return; @@ -95,7 +96,7 @@ function AddApplicationForm({ onClose, onAdded }: { onClose: () => void; onAdded { input: text }, { onSuccess: (result) => { - setParsed(result); + setReading({ text, result }); setRole((current) => current || result.role); setCompany((current) => current || result.company); }, diff --git a/apps/web/src/features/applications/components/application-detail-sheet.tsx b/apps/web/src/features/applications/components/application-detail-sheet.tsx index 03b8cf465..0ddc9120e 100644 --- a/apps/web/src/features/applications/components/application-detail-sheet.tsx +++ b/apps/web/src/features/applications/components/application-detail-sheet.tsx @@ -32,7 +32,7 @@ import { useClosingValue } from "@/hooks/use-closing-value"; import { useConfirm } from "@/hooks/use-confirm"; import { isImeComposing } from "@/libs/keyboard"; import { orpc } from "@/libs/orpc/client"; -import { stageSince } from "../next-step"; +import { daysInStage } from "../next-step"; import { getClosedReasonLabel, getNextStage, getStageColor, getStageLabel, PIPELINE } from "../stages"; import { useApplicationActions, useInvalidateApplications } from "../use-application-actions"; import { Activity } from "./detail/activity"; @@ -103,7 +103,7 @@ function Detail({ application, onEditDetails, onDeleted }: DetailProps) { const next = getNextStage(application.status); const reached = PIPELINE.indexOf(application.status); - const since = Math.max(0, Math.floor((Date.now() - stageSince(application).getTime()) / 86_400_000)); + const since = daysInStage(application); const closed = application.status === "closed"; const onDelete = async () => { diff --git a/apps/web/src/features/applications/next-step.ts b/apps/web/src/features/applications/next-step.ts index feba131e4..90ef4fe06 100644 --- a/apps/web/src/features/applications/next-step.ts +++ b/apps/web/src/features/applications/next-step.ts @@ -25,7 +25,7 @@ export type NextStep = | { kind: "closed" }; /** When the application entered its current stage (its latest entry for that stage), or when it was added. */ -export function stageSince(application: Pick): Date { +function stageSince(application: Pick): Date { const entries = application.activity .filter((entry) => entry.type === "stage" && entry.stage === application.status) .map((entry) => new Date(entry.at).getTime()); @@ -34,6 +34,10 @@ export function stageSince(application: Pick Math.max(0, Math.floor((to.getTime() - from.getTime()) / DAY_MS)); +/** Whole days the application has spent in its current stage. */ +export const daysInStage = (application: Pick, now = new Date()) => + daysBetween(stageSince(application), now); + export function getNextStep(application: NextStepSource, now = new Date()): NextStep { if (application.status === "closed") return { kind: "closed" }; @@ -51,7 +55,7 @@ export function getNextStep(application: NextStepSource, now = new Date()): Next if (application.status === "saved") return { kind: "not-applied" }; - const days = daysBetween(stageSince(application), now); + const days = daysInStage(application, now); if (application.status === "applied" && days >= FOLLOW_UP_AFTER_DAYS) return { kind: "no-reply", days }; return { kind: "waiting", days }; } diff --git a/apps/web/src/features/assistant/conversation.tsx b/apps/web/src/features/assistant/conversation.tsx index 61476181d..c43d8b6b3 100644 --- a/apps/web/src/features/assistant/conversation.tsx +++ b/apps/web/src/features/assistant/conversation.tsx @@ -106,6 +106,7 @@ export function Conversation(props: ConversationProps) { ), [messages, statuses, document], ); + // biome-ignore lint/nursery/useReactCompiler: publishes to the editor store, which the page canvas reads useEffect(() => setAssistantProposals(proposals), [proposals, setAssistantProposals]); useEffect(() => () => setAssistantProposals([]), [setAssistantProposals]); @@ -133,6 +134,7 @@ export function Conversation(props: ConversationProps) { const undone = toProposals(part, statuses, document).filter( (proposal) => proposal.status === "accepted" && document.stateOf(proposal) === "pending", ); + // biome-ignore lint/nursery/useReactCompiler: an undo happens in the resume store; the new status is also saved to the thread if (undone.length > 0) recordUndone(message, part, undone, "pending"); } } diff --git a/apps/web/src/features/resume/editor/chrome.tsx b/apps/web/src/features/resume/editor/chrome.tsx index 55183d4b5..30711d1dd 100644 --- a/apps/web/src/features/resume/editor/chrome.tsx +++ b/apps/web/src/features/resume/editor/chrome.tsx @@ -37,7 +37,7 @@ const PAGE_WIDTH = { a4: 595.28, letter: 612, "free-form": 595.28 } as const; // Horizontal room the canvas keeps around the page: 40px each side, 16px on phones. const CANVAS_GUTTER = { wide: 80, narrow: 32 } as const; -export function useCanvasWidth() { +function useCanvasWidth() { const ref = useRef(null); const [width, setWidth] = useState(0); diff --git a/apps/web/src/features/resume/stylesheet/editor.tsx b/apps/web/src/features/resume/stylesheet/editor.tsx index adcba5266..196cf877b 100644 --- a/apps/web/src/features/resume/stylesheet/editor.tsx +++ b/apps/web/src/features/resume/stylesheet/editor.tsx @@ -428,6 +428,7 @@ function StylesheetEditorShell({ readOnly = false }: StylesheetEditorShellProps) name: "semantic-css-compiler", }), ); + // biome-ignore lint/nursery/useReactCompiler: the worker is created here so it can be destroyed on unmount setCompiler(client); return () => client.destroy(); }, []); diff --git a/apps/web/src/hooks/use-form-blocker.tsx b/apps/web/src/hooks/use-form-blocker.tsx index 8176a72d4..c5d709e6d 100644 --- a/apps/web/src/hooks/use-form-blocker.tsx +++ b/apps/web/src/hooks/use-form-blocker.tsx @@ -11,7 +11,7 @@ interface UseFormBlockerOptions { export function useFormBlocker(form: Pick, options?: UseFormBlockerOptions) { const confirm = useConfirm(); - const closeDialog = useDialogStore((state) => state.closeDialog); + const onOpenChange = useDialogStore((state) => state.onOpenChange); const setOnBeforeClose = useDialogStore((state) => state.setOnBeforeClose); const isDirty = useStore(form.store, (state) => state.isDirty); @@ -22,32 +22,22 @@ export function useFormBlocker(form: Pick, options?: UseFor shouldBlockRef.current = options?.shouldBlock; }, [options?.shouldBlock]); - const shouldBlock = () => { - if (shouldBlockRef.current) return shouldBlockRef.current(); - return isDirty && !isSubmitting; - }; - - const confirmClose = () => { - if (!shouldBlock()) return true; - - return confirm(t`Are you sure you want to close this dialog?`, { - description: t`You have unsaved changes that will be lost.`, - confirmText: t`Leave`, - cancelText: t`Stay`, - }); - }; - - const requestClose = async () => { - const confirmed = await confirmClose(); - if (!confirmed) return; - - closeDialog(); - }; - useEffect(() => { - setOnBeforeClose(confirmClose); + setOnBeforeClose(() => { + const shouldBlock = shouldBlockRef.current ? shouldBlockRef.current() : isDirty && !isSubmitting; + if (!shouldBlock) return true; + + return confirm(t`Are you sure you want to close this dialog?`, { + description: t`You have unsaved changes that will be lost.`, + confirmText: t`Leave`, + cancelText: t`Stay`, + }); + }); return () => setOnBeforeClose(null); - }, [confirmClose, setOnBeforeClose]); + }, [isDirty, isSubmitting, confirm, setOnBeforeClose]); + + // Closing through the store asks the handler above first. + const requestClose = () => onOpenChange(false); return { requestClose }; } diff --git a/apps/web/src/routes/builder/$resumeId/-components/editor-shell.tsx b/apps/web/src/routes/builder/$resumeId/-components/editor-shell.tsx index f3d4d0ccc..955f0b8c9 100644 --- a/apps/web/src/routes/builder/$resumeId/-components/editor-shell.tsx +++ b/apps/web/src/routes/builder/$resumeId/-components/editor-shell.tsx @@ -238,6 +238,7 @@ function MobileBody({ mode, onModeChange }: MobileBodyProps) { // it in view above its sheet. const pageVisible = view === "page" || view === "design"; useEffect(() => { + // biome-ignore lint/nursery/useReactCompiler: a shared store the preview renderer reads, reset on unmount setPreviewPaused(!pageVisible); return () => setPreviewPaused(false); }, [pageVisible, setPreviewPaused]); diff --git a/apps/web/src/routes/builder/letter/-components/letter-shell.tsx b/apps/web/src/routes/builder/letter/-components/letter-shell.tsx index e1a07b482..b5e0f73bd 100644 --- a/apps/web/src/routes/builder/letter/-components/letter-shell.tsx +++ b/apps/web/src/routes/builder/letter/-components/letter-shell.tsx @@ -176,6 +176,7 @@ function MobileBody({ mode, onModeChange }: MobileBodyProps) { const labels: Record = { write: t`Write`, page: t`Page`, design: t`Design` }; useEffect(() => { + // biome-ignore lint/nursery/useReactCompiler: a shared store the preview renderer reads, reset on unmount setPreviewPaused(view !== "page"); return () => setPreviewPaused(false); }, [view, setPreviewPaused]); diff --git a/apps/web/src/routes/dashboard/applications/index.tsx b/apps/web/src/routes/dashboard/applications/index.tsx index 3e58e018d..5f0688ced 100644 --- a/apps/web/src/routes/dashboard/applications/index.tsx +++ b/apps/web/src/routes/dashboard/applications/index.tsx @@ -86,12 +86,14 @@ function RouteComponent() { useEffect(() => { if (!create) return; + // biome-ignore lint/nursery/useReactCompiler: takes the one-shot ?create flag from the address, then clears it setAdding(true); void navigate({ replace: true, resetScroll: false, search: (prev: Search) => ({ ...prev, create: false }) }); }, [create, navigate]); useEffect(() => { if (!applicationId || !applications) return; + // biome-ignore lint/nursery/useReactCompiler: takes the one-shot ?applicationId from the address, then clears it setSelectedId(applicationId); void navigate({ replace: true, diff --git a/biome.json b/biome.json index c228be16a..ca5bfbe22 100644 --- a/biome.json +++ b/biome.json @@ -57,6 +57,7 @@ "useAwait": "error" }, "nursery": { + "useReactCompiler": "error", "useSortedClasses": { "level": "warn", "fix": "safe", diff --git a/packages/pdf/src/templates/azurill/AzurillPage.tsx b/packages/pdf/src/templates/azurill/AzurillPage.tsx index 339334f4f..16f6c843b 100644 --- a/packages/pdf/src/templates/azurill/AzurillPage.tsx +++ b/packages/pdf/src/templates/azurill/AzurillPage.tsx @@ -251,19 +251,5 @@ const useAzurillTemplate = (): AzurillTemplate => { icon: createIconSlot({ metadata, accentFor }), } satisfies AzurillStyles, }; - }, [ - metadata, - r.row, - primary, - metrics.page.paddingVertical, - metrics.page.paddingHorizontal, - metrics.gapX, - metrics.headerGap, - metrics.columnGap, - base, - metrics.gapY, - foreground, - background, - r.columns, - ]); + }, [metadata, r, primary, metrics, base, foreground, background]); }; diff --git a/packages/pdf/src/templates/bronzor/BronzorPage.tsx b/packages/pdf/src/templates/bronzor/BronzorPage.tsx index f3bbb2f18..bbaadf4d9 100644 --- a/packages/pdf/src/templates/bronzor/BronzorPage.tsx +++ b/packages/pdf/src/templates/bronzor/BronzorPage.tsx @@ -178,19 +178,5 @@ const useBronzorTemplate = (): BronzorTemplate => { }); return { colors, styles: baseStyles satisfies BronzorStyles }; - }, [ - metadata, - r.sectionHeadingTextAlign, - r.row, - primary, - metrics.page.paddingVertical, - metrics.page.paddingHorizontal, - metrics.headerGap, - metrics.columnGap, - metrics.gapY, - foreground, - base, - metrics.gapX, - background, - ]); + }, [metadata, r, primary, metrics, foreground, base, background]); }; diff --git a/packages/pdf/src/templates/chikorita/ChikoritaPage.tsx b/packages/pdf/src/templates/chikorita/ChikoritaPage.tsx index 30d2de162..93a099833 100644 --- a/packages/pdf/src/templates/chikorita/ChikoritaPage.tsx +++ b/packages/pdf/src/templates/chikorita/ChikoritaPage.tsx @@ -284,5 +284,5 @@ const useChikoritaTemplate = (): ChikoritaTemplate => { icon: createIconSlot({ metadata, accentFor }), } satisfies ChikoritaStyles, }; - }, [metadata, r.row, r.headerIdentity, metrics.gapX, primary, foreground, base, metrics.gapY, background, r.columns]); + }, [metadata, r, metrics, primary, foreground, base, background]); }; diff --git a/packages/pdf/src/templates/ditgar/DitgarPage.tsx b/packages/pdf/src/templates/ditgar/DitgarPage.tsx index 227c3c090..c771393fb 100644 --- a/packages/pdf/src/templates/ditgar/DitgarPage.tsx +++ b/packages/pdf/src/templates/ditgar/DitgarPage.tsx @@ -344,18 +344,5 @@ const useDitgarTemplate = (): DitgarTemplate => { }), } satisfies DitgarStyles, }; - }, [ - metadata, - r.row, - r.headerIdentity, - primary, - metrics.gapY, - metrics.page.paddingVertical, - metrics.gapX, - base, - metrics.page.paddingHorizontal, - foreground, - background, - r.columns, - ]); + }, [metadata, r, primary, metrics, base, foreground, background]); }; diff --git a/packages/pdf/src/templates/ditto/DittoPage.tsx b/packages/pdf/src/templates/ditto/DittoPage.tsx index c32a6d108..c0e45b25e 100644 --- a/packages/pdf/src/templates/ditto/DittoPage.tsx +++ b/packages/pdf/src/templates/ditto/DittoPage.tsx @@ -295,19 +295,5 @@ const useDittoTemplate = (): DittoTemplate => { }, } satisfies DittoStyles, }; - }, [ - picture, - metadata, - r.row, - r.headerIdentity, - primary, - metrics.page.paddingVertical, - metrics.gapX, - metrics.page.paddingHorizontal, - foreground, - base, - metrics.gapY, - background, - r.columns, - ]); + }, [picture, metadata, r, primary, metrics, foreground, base, background]); }; diff --git a/packages/pdf/src/templates/gengar/GengarPage.tsx b/packages/pdf/src/templates/gengar/GengarPage.tsx index 982821e0e..3ff54f45b 100644 --- a/packages/pdf/src/templates/gengar/GengarPage.tsx +++ b/packages/pdf/src/templates/gengar/GengarPage.tsx @@ -320,19 +320,5 @@ const useGengarTemplate = (): GengarTemplate => { }), } satisfies GengarStyles, }; - }, [ - metadata, - r.row, - r.headerIdentity, - primary, - metrics.sectionGap, - metrics.gapY, - metrics.page.paddingVertical, - metrics.gapX, - base, - metrics.page.paddingHorizontal, - foreground, - background, - r.columns, - ]); + }, [metadata, r, primary, metrics, base, foreground, background]); }; diff --git a/packages/pdf/src/templates/glalie/GlaliePage.tsx b/packages/pdf/src/templates/glalie/GlaliePage.tsx index 92349a289..ec8e30df1 100644 --- a/packages/pdf/src/templates/glalie/GlaliePage.tsx +++ b/packages/pdf/src/templates/glalie/GlaliePage.tsx @@ -244,19 +244,5 @@ const useGlalieTemplate = (): GlalieTemplate => { icon: createIconSlot({ metadata, accentFor }), } satisfies GlalieStyles, }; - }, [ - metadata, - r.row, - primary, - metrics.sectionGap, - metrics.gapY, - metrics.page.paddingVertical, - metrics.gapX, - base, - metrics.page.paddingHorizontal, - foreground, - background, - r.columns, - r.anchorToColumnStart, - ]); + }, [metadata, r, primary, metrics, base, foreground, background]); }; diff --git a/packages/pdf/src/templates/kakuna/KakunaPage.tsx b/packages/pdf/src/templates/kakuna/KakunaPage.tsx index bebb73795..c65cf9285 100644 --- a/packages/pdf/src/templates/kakuna/KakunaPage.tsx +++ b/packages/pdf/src/templates/kakuna/KakunaPage.tsx @@ -215,17 +215,5 @@ const useKakunaTemplate = (): KakunaTemplate => { icon: createIconSlot({ metadata, accentFor }), } satisfies KakunaStyles, }; - }, [ - metadata, - r.row, - primary, - metrics.sectionGap, - metrics.gapY, - metrics.page.paddingVertical, - metrics.gapX, - base, - metrics.page.paddingHorizontal, - foreground, - background, - ]); + }, [metadata, r, primary, metrics, base, foreground, background]); }; diff --git a/packages/pdf/src/templates/lapras/LaprasPage.tsx b/packages/pdf/src/templates/lapras/LaprasPage.tsx index 229ce6b17..710717ca1 100644 --- a/packages/pdf/src/templates/lapras/LaprasPage.tsx +++ b/packages/pdf/src/templates/lapras/LaprasPage.tsx @@ -185,19 +185,5 @@ const useLaprasTemplate = (): LaprasTemplate => { icon: createIconSlot({ metadata, accentFor }), } satisfies LaprasStyles, }; - }, [ - picture, - metadata, - r.row, - r.headerIdentity, - r.anchorToStart, - primary, - metrics.gapY, - metrics.page.paddingVertical, - metrics.gapX, - base, - metrics.page.paddingHorizontal, - foreground, - background, - ]); + }, [picture, metadata, r, primary, metrics, base, foreground, background]); }; diff --git a/packages/pdf/src/templates/leafish/LeafishPage.tsx b/packages/pdf/src/templates/leafish/LeafishPage.tsx index 31f2d1976..17dc48a0c 100644 --- a/packages/pdf/src/templates/leafish/LeafishPage.tsx +++ b/packages/pdf/src/templates/leafish/LeafishPage.tsx @@ -244,19 +244,5 @@ const useLeafishTemplate = (): LeafishTemplate => { icon: createIconSlot({ metadata, accentFor }), } satisfies LeafishStyles, }; - }, [ - metadata, - r.row, - r.headerIdentity, - primary, - metrics.gapY, - metrics.page.paddingVertical, - metrics.gapX, - base, - metrics.page.paddingHorizontal, - metrics.columnGap, - foreground, - background, - r.columns, - ]); + }, [metadata, r, primary, metrics, base, foreground, background]); }; diff --git a/packages/pdf/src/templates/meowth/MeowthPage.tsx b/packages/pdf/src/templates/meowth/MeowthPage.tsx index c19c1f43d..26dc9f61e 100644 --- a/packages/pdf/src/templates/meowth/MeowthPage.tsx +++ b/packages/pdf/src/templates/meowth/MeowthPage.tsx @@ -229,19 +229,5 @@ const useMeowthTemplate = (): MeowthTemplate => { icon: createIconSlot({ metadata, accentFor }), } satisfies MeowthStyles, }; - }, [ - metadata, - r.sectionHeadingTextAlign, - r.row, - r.headerIdentity, - primary, - metrics.sectionGap, - metrics.gapY, - metrics.page.paddingVertical, - metrics.gapX, - base, - metrics.page.paddingHorizontal, - foreground, - background, - ]); + }, [metadata, r, primary, metrics, base, foreground, background]); }; diff --git a/packages/pdf/src/templates/onyx/OnyxPage.tsx b/packages/pdf/src/templates/onyx/OnyxPage.tsx index 12b307fea..d8661cc65 100644 --- a/packages/pdf/src/templates/onyx/OnyxPage.tsx +++ b/packages/pdf/src/templates/onyx/OnyxPage.tsx @@ -164,18 +164,5 @@ const useOnyxTemplate = (): OnyxTemplate => { icon: createIconSlot({ metadata, accentFor }), } satisfies OnyxStyles, }; - }, [ - metadata, - r.row, - r.headerIdentity, - primary, - metrics.sectionGap, - metrics.gapY, - metrics.page.paddingVertical, - metrics.gapX, - base, - metrics.page.paddingHorizontal, - foreground, - background, - ]); + }, [metadata, r, primary, metrics, base, foreground, background]); }; diff --git a/packages/pdf/src/templates/pikachu/PikachuPage.tsx b/packages/pdf/src/templates/pikachu/PikachuPage.tsx index 2d7cf004f..ac9189970 100644 --- a/packages/pdf/src/templates/pikachu/PikachuPage.tsx +++ b/packages/pdf/src/templates/pikachu/PikachuPage.tsx @@ -288,20 +288,5 @@ const usePikachuTemplate = (): PikachuTemplate => { icon: createIconSlot({ metadata, accentFor }), } satisfies PikachuStyles, }; - }, [ - picture, - metadata, - r.row, - r.headerIdentity, - primary, - metrics.page.paddingVertical, - metrics.page.paddingHorizontal, - metrics.columnGap, - metrics.gapY, - foreground, - base, - metrics.gapX, - background, - r.columns, - ]); + }, [picture, metadata, r, primary, metrics, foreground, base, background]); }; diff --git a/packages/pdf/src/templates/rhyhorn/RhyhornPage.tsx b/packages/pdf/src/templates/rhyhorn/RhyhornPage.tsx index 25a799b7a..ccee7d079 100644 --- a/packages/pdf/src/templates/rhyhorn/RhyhornPage.tsx +++ b/packages/pdf/src/templates/rhyhorn/RhyhornPage.tsx @@ -313,21 +313,5 @@ const useRhyhornTemplate = (): RhyhornTemplate => { icon: createIconSlot({ metadata, accentFor }), } satisfies RhyhornStyles, }; - }, [ - metadata, - r.sectionHeadingTextAlign, - r.row, - r.headerIdentity, - r.contactSeparatorClear, - r.contactSeparator, - primary, - metrics.sectionGap, - metrics.gapY, - metrics.page.paddingVertical, - metrics.gapX, - base, - metrics.page.paddingHorizontal, - foreground, - background, - ]); + }, [metadata, r, primary, metrics, base, foreground, background]); }; diff --git a/packages/pdf/src/templates/scizor/ScizorPage.tsx b/packages/pdf/src/templates/scizor/ScizorPage.tsx index e827bd6dd..4169f1546 100644 --- a/packages/pdf/src/templates/scizor/ScizorPage.tsx +++ b/packages/pdf/src/templates/scizor/ScizorPage.tsx @@ -214,22 +214,5 @@ const useScizorTemplate = (): ScizorTemplate => { icon: createIconSlot({ metadata, accentFor }), } satisfies ScizorStyles, }; - }, [ - metadata, - r.row, - r.headerIdentity, - primary, - metrics.sectionGap, - metrics.page.paddingVertical, - metrics.page.paddingHorizontal, - metrics.itemGapY, - foreground, - metrics.gapY, - base.page, - background, - base.heading, - metrics.gapX, - base.bold, - base, - ]); + }, [metadata, r, primary, metrics, foreground, background, base]); };