Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Theming - Spectrum Provider #1582

Merged
merged 17 commits into from
Oct 24, 2023

Conversation

bmingles
Copy link
Contributor

@bmingles bmingles commented Oct 18, 2023

In this PR:

  • First pass of mapping Spectrum dark theme variables to DH theme variables
  • Added Spectrum components that are being used by DH UI to the styleguide
  • Added some navigation to styleguide
  • Added a Playwright config for Firefox to fix an issue where no pointers were detected in '(any-pointer: fine)' media queries

resolves #1543

@codecov
Copy link

codecov bot commented Oct 19, 2023

Codecov Report

Attention: 13 lines in your changes are missing coverage. Please review.

Comparison is base (f440a38) 46.65% compared to head (870156b) 46.72%.
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1582      +/-   ##
==========================================
+ Coverage   46.65%   46.72%   +0.07%     
==========================================
  Files         575      581       +6     
  Lines       36189    36263      +74     
  Branches     9063     9074      +11     
==========================================
+ Hits        16883    16944      +61     
- Misses      19254    19267      +13     
  Partials       52       52              
Flag Coverage Δ
unit 46.72% <82.89%> (+0.07%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
packages/code-studio/src/styleguide/Icons.tsx 55.17% <ø> (ø)
.../code-studio/src/styleguide/SpectrumComponents.tsx 100.00% <100.00%> (ø)
packages/code-studio/src/styleguide/StyleGuide.tsx 100.00% <100.00%> (ø)
...ackages/code-studio/src/styleguide/ThemeColors.tsx 40.00% <ø> (ø)
packages/code-studio/src/styleguide/Typography.tsx 100.00% <ø> (ø)
packages/code-studio/src/styleguide/constants.ts 100.00% <100.00%> (ø)
packages/components/src/SpectrumUtils.ts 100.00% <ø> (ø)
...ges/components/src/theme/SpectrumThemeProvider.tsx 100.00% <100.00%> (ø)
packages/components/src/theme/ThemeProvider.tsx 100.00% <100.00%> (ø)
packages/components/src/theme/theme-dark/index.ts 100.00% <ø> (ø)
... and 3 more

... and 1 file with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@bmingles bmingles marked this pull request as ready for review October 20, 2023 13:58
@bmingles bmingles requested a review from mofojed October 20, 2023 13:59
@bmingles bmingles force-pushed the 1543-theming-spectrum-provider branch from ba94735 to 8537f41 Compare October 20, 2023 16:43
Copy link
Member

@mofojed mofojed left a comment

Choose a reason for hiding this comment

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

Like the new navigation menu in the style guide!

// 120px. CSS uses this to only show the button when the user has scrolled.
useEffect(() => {
function onScroll() {
document.documentElement.dataset.scroll = String(window.scrollY > 120);
Copy link
Member

Choose a reason for hiding this comment

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

Why 120px? Name the constant to give it some more context.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It's arbitrary. It just "felt" right. I'll name it in next PR

@bmingles bmingles merged commit a4013c0 into deephaven:main Oct 24, 2023
5 checks passed
@bmingles bmingles deleted the 1543-theming-spectrum-provider branch October 24, 2023 14:18
@github-actions github-actions bot locked and limited conversation to collaborators Oct 24, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Theming - Spectrum DH Theme
2 participants