refactor: Modularize CSS and fix theme-aware text colors
CSS Restructuring: - Reorganize monolithic main.css into modular architecture - Create foundation/ (reset, variables, typography, themes) - Create layout/ (container, page, grid, paper) - Create components/ (8 component files) - Create interactive/ (toggles, remaining for future split) - Create effects/ (skeleton loading) - Create contexts/ (print styles) Theme Support Fixes: - Replace all hardcoded text colors with CSS variables - Fix .section-title: rgb(51,51,51) → var(--text-primary) - Fix .cv-name, .intro-text: hardcoded → theme-aware - Fix .experience-period, .duration-text: #555/#aaa → variables - Fix course/project/experience text colors - Support proper light/dark theme text contrast Icon & Layout Fixes: - Standardize all icon sizes to 80×80px - Change all icon backgrounds to transparent - Fix award section layout (missing flexbox) - Update HTML templates (experience.html, awards.html) to width='80' - Fix default icon sizing conflicts View Switcher Fix: - Fix toggleTheme() to target .cv-container instead of body - Ensures clean/default theme toggle works correctly Files: 40+ CSS files modularized, 3 templates updated, 7 tests added
This commit is contained in:
@@ -55,17 +55,17 @@ end
|
||||
-- ==============================================================================
|
||||
|
||||
def toggleTheme(isClean)
|
||||
set body to document.body
|
||||
set container to the first .cv-container
|
||||
set actionBarToggle to #themeToggle
|
||||
set menuToggle to #themeToggleMenu
|
||||
|
||||
if isClean is true
|
||||
add .theme-clean to body
|
||||
add .theme-clean to container
|
||||
call localStorage.setItem('cv-theme', 'clean')
|
||||
if actionBarToggle exists then set actionBarToggle's checked to true end
|
||||
if menuToggle exists then set menuToggle's checked to true end
|
||||
else
|
||||
remove .theme-clean from body
|
||||
remove .theme-clean from container
|
||||
call localStorage.setItem('cv-theme', 'default')
|
||||
if actionBarToggle exists then set actionBarToggle's checked to false end
|
||||
if menuToggle exists then set menuToggle's checked to false end
|
||||
|
||||
Reference in New Issue
Block a user