For agentic workers: REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development (recommended) or superpowers:executing-plans to implement this plan task-by-task. Steps use checkbox (
- [ ]) syntax for tracking.
Goal: Render the uploaded report-logo.png in the shared page header for both exam sprint PDF/HTML reports.
Architecture: Keep the PNG under classpath resources and have each renderer embed it as a Base64 data URI. Templates receive a {{reportLogoDataUri}} placeholder so Playwright PDF generation does not depend on relative file URL resolution.
Tech Stack: Java 17, Spring ClassPathResource, static HTML templates, JUnit 5, AssertJ.
abilities/exam-sprint/infrastructure/src/main/resources/report-assets/report-logo.pngabilities/exam-sprint/infrastructure/src/main/resources/templates/outlook-exam-sprint-report-template.htmlabilities/exam-sprint/infrastructure/src/main/resources/templates/achievement-exam-sprint-report-template.htmlabilities/exam-sprint/infrastructure/src/main/java/cn/yunzhixue/ability/center/examsprint/infrastructure/report/rendering/outlook/ClasspathOutlookExamSprintReportRenderer.javaabilities/exam-sprint/infrastructure/src/main/java/cn/yunzhixue/ability/center/examsprint/infrastructure/report/rendering/achievement/ClasspathAchievementExamSprintReportRenderer.javaabilities/exam-sprint/infrastructure/src/test/java/cn/yunzhixue/ability/center/examsprint/infrastructure/report/rendering/outlook/ClasspathOutlookExamSprintReportRendererTest.javaabilities/exam-sprint/infrastructure/src/test/java/cn/yunzhixue/ability/center/examsprint/infrastructure/report/rendering/achievement/ClasspathAchievementExamSprintReportRendererTest.javarenderShowsStudentNameInReportHeader tests that rendered HTML contains <img class="header-logo-image" src="data:image/png;base64, and does not contain {{reportLogoDataUri}}.mvn -pl abilities/exam-sprint/infrastructure -Dtest=ClasspathOutlookExamSprintReportRendererTest,ClasspathAchievementExamSprintReportRendererTest test and verify RED because templates/renderers do not inject the logo yet..header-logo content with <img class="header-logo-image" src="{{reportLogoDataUri}}" alt="IATSE"/>..header-logo-image CSS with display: block; max-width: 120px; max-height: 42px; to both templates.report-assets/report-logo.png via ClassPathResource, convert bytes using Base64.getEncoder().encodeToString(...), prefix data:image/png;base64,, and replace/fill reportLogoDataUri.mvn -pl abilities/exam-sprint/infrastructure test.