Skip to content

Add ThemeProvider and comprehensive UI restyle (nav, footer, PolymathBento, buttons, textarea, CSS) - #2

Merged
wugweb-git merged 1 commit into
mainfrom
codex/overhaul-identity-prism-ui-for-accessibility
Apr 15, 2026
Merged

wugweb-git merged 1 commit into
mainfrom
codex/overhaul-identity-prism-ui-for-accessibility

Conversation

@wugweb-git

Copy link
Copy Markdown
Owner

Motivation

  • Centralize theme handling and enable light/dark switching while moving the app toward a cohesive, token-driven visual system.
  • Refresh global navigation, footer, and key components to improve accessibility, responsiveness, and visual consistency.
  • Replace ad-hoc color classes with CSS variables and utility classes to simplify maintenance and future theming.

Description

  • Add a new ThemeProvider and ThemeToggle with useTheme hook and persistent storage (localStorage) and media-query fallbacks, and wrap the app with ThemeProvider in App.tsx.
  • Overhaul global styles in src/index.css to introduce design tokens (colors, spacing, fonts, states), new utility classes, and dark/light variants controlled by data-theme, and update index.html meta/title and theme attributes.
  • Update layout and UI: replace inline color classes with token-based classes in App.tsx, GlobalNav.tsx, MinimalFooter.tsx, PolymathBento.tsx, and TestingDashboard.tsx, add ThemeToggle into the navigation, improve ARIA roles and keyboard semantics, and restructure PolymathBento with new content blocks and accessible markup.
  • Restyle shared UI primitives by updating button.tsx and textarea.tsx variants to use the new tokenized classes and tuned sizing/behavior.

Testing

  • Ran TypeScript type-check (tsc --noEmit) and a local production build (npm run build) to validate compile-time correctness and bundling, both completed successfully.
  • Performed a local development smoke test by running the app and exercising navigation, theme toggle, and key interactive components, which rendered without runtime errors.

Codex Task

@vercel

vercel Bot commented Apr 15, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
proprofile Ready Ready Preview, Comment Apr 15, 2026 4:19am

@wugweb-git
wugweb-git merged commit d2aba97 into main Apr 15, 2026
2 of 3 checks passed

@chatgpt-codex-connector chatgpt-codex-connector Bot 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.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 4fdbe12308

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +27 to +31
useEffect(() => {
const root = document.documentElement;
root.setAttribute('data-theme', theme);
window.localStorage.setItem(STORAGE_KEY, theme);
}, [theme]);

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Preserve system-theme tracking until user chooses a theme

The provider persists identity-prism-theme on every mount, even when the theme was only inferred from matchMedia. Because the media-change listener later updates only when !persisted, that branch becomes unreachable immediately after first render, so users who never explicitly toggle theme stop following OS light/dark changes after load. This breaks the intended “media-query fallback” behavior until localStorage is manually cleared.

Useful? React with 👍 / 👎.

Comment thread src/index.css
Comment on lines +75 to +79
html,
body,
#root {
width: 100vw;
min-height: 100vh;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Replace root 100vw sizing to prevent horizontal overflow

Applying width: 100vw to the root layout container causes a cross-platform overflow issue when vertical scrollbars consume layout space (common on Windows): 100vw includes scrollbar width, so the page becomes wider than the visible viewport and can produce horizontal scrolling/jitter. This affects the whole app shell because these rules apply to html, body, and #root globally.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant