Skip to content

feat: add light theme support#13

Open
jerrydanzaria5-svg wants to merge 1 commit into
coolhillblack:mainfrom
jerrydanzaria5-svg:feat/light-theme
Open

feat: add light theme support#13
jerrydanzaria5-svg wants to merge 1 commit into
coolhillblack:mainfrom
jerrydanzaria5-svg:feat/light-theme

Conversation

@jerrydanzaria5-svg

Copy link
Copy Markdown

Summary

Adds a theme prop to TransactionBuilder to support a light color scheme, addressing the "Light theme" item on the roadmap.

Changes

  • New theme?: "dark" | "light" prop on TransactionBuilderProps (default: "dark")
  • Root wrapper now applies a stx-theme-{theme} class
  • Added CSS custom properties (--stx-bg, --stx-text, --stx-border, --stx-accent, etc.) for both themes in src/styles/index.css
  • Updated README props table and added a short usage example

Why this approach

Using a CSS class + custom properties on the root wrapper keeps the change additive and low-risk — no new Context provider, no changes to existing transaction-building logic, and dark mode's current values are unchanged, so nothing breaks for consumers who don't pass the prop.

Usage

```tsx

```

Testing

  • npm run typecheck passes
  • npm run lint passes
  • Manually verified in dev server: default (no theme prop) renders identically to current dark mode; theme="light" renders with light colors across all steps

Notes

Open to feedback on whether color tokens should also be exposed via tailwind.config.js for consumers who want to customize further — kept this PR scoped to a working light/dark toggle first.

- Add `theme` prop ("dark" | "light") to TransactionBuilderProps
- Apply `stx-theme-{theme}` class to root wrapper
- Add CSS custom properties for light/dark color values
- Default remains "dark" — no behavior change for existing consumers
- Document new prop in README
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant