When testing slide changes with Playwright browser:
- Compile the slides using
../template_deck/compile.sh <lecture>.md - Refresh the browser with F5 or by navigating to the URL again
- Then take a screenshot to see the actual changes
Important: Navigating to the same URL does NOT refresh cached content. You MUST press F5 or use browser_navigate to a fresh URL to see updated files.
- ALWAYS refresh the browser after recompiling to view the current version
- Verify screenshot timestamps: If the screenshot file already exists, check its creation time BEFORE taking a new screenshot, then verify the timestamp changed AFTER taking it
- Never assume you're viewing updated content without explicit refresh
- COMMIT changes BEFORE editing so we can roll back to previous versions
- Changes get lost in the shuffle without commits - we can't track what was done!
- Use descriptive commit messages that explain what was fixed
- NEVER run
git checkout,git restore, orgit resetwithout FIRST committing or stashing current changes - Even if the current state seems "broken," it contains valuable work that will be LOST
- Before ANY destructive git operation:
- Run
git stashorgit commit -m "WIP: backup before revert" - THEN perform the revert/checkout
- This allows recovery of work if the revert was a mistake
- Run
- VIOLATING THIS RULE DESTROYS WORK AND WASTES HOURS OF EFFORT
- CSS (
themes/cdl-theme.css): Static styling rules that don't know about slide content - JavaScript (
template_deck/autoscale.js): Dynamic content scaling that measures actual rendered content - Multi-column layouts use CSS custom property
--content-scalewhich JS can set dynamically - Content scaling philosophy: Start at max font size, only scale DOWN when content overflows
slides/template_deck/compile.sh- Main build scriptslides/template_deck/autoscale.js- Dynamic content scalingslides/week1/themes/cdl-theme.css- Theme CSS