Skip to content

Refactor: Remove bootstrap, adopt semantic tokens, and improve Mantine UI usage - #1347

Merged
elizabetdev merged 53 commits into
mainfrom
update-color-vars
Nov 14, 2025
Merged

Refactor: Remove bootstrap, adopt semantic tokens, and improve Mantine UI usage#1347
elizabetdev merged 53 commits into
mainfrom
update-color-vars

Conversation

@elizabetdev

Copy link
Copy Markdown
Contributor

Description

This PR improves the overall design system consistency, theming capabilities, and maintainability of the project by removing Bootstrap dependencies and enhancing Mantine UI usage.

It also serves as step one in preparing the codebase for the future introduction of Click-UI, which will further streamline and unify component usage across the application.

Key Changes

  • Removed all Bootstrap components and related styles.
  • Replaced them with Mantine UI components for consistent styling and behavior.
  • Introduced and applied semantic design tokens for colors, spacing, and typography.
  • Implemented a more reliable and native light/dark theme system using Mantine’s theming capabilities.
  • Refactored existing components to follow Mantine’s recommended patterns and accessibility best practices.
  • Cleaned up unused CSS and simplified layout structures.

Motivation

Previously, the dark mode was achieved through a global CSS filter, such as:

html.hdx-theme-light {
filter:invert(1) hue-rotate(180deg) brightness(1.05);
}

While this approach provided a quick inversion effect, it had several drawbacks:

  • It distorted colors and images, resulting in inaccurate visual representation.
  • It made fine-tuning design tokens (e.g., specific color shades or contrast) nearly impossible.
  • It negatively impacted accessibility and color contrast consistency.
  • It introduced side effects with third-party components and icons.

By moving to a token-based theme system powered by Mantine, we ensure predictable, maintainable, and accessible theming across all components.

Testing Notes

  • Verify that all pages render correctly with Mantine components.
  • Test both light and dark themes to confirm consistent color application.
  • Check accessibility contrast ratios and interactive states (hover, focus, active).

- Updated button colors and variants across ClickhousePage, DBChartPage, and DBSearchPage for better visual consistency.
- Refined ActionIcon styles in ThemeWrapper to enhance default and subtle variants.
- Adjusted background and border colors in various components to align with new semantic color variables.
- Replaced hardcoded colors with CSS variables for better theme management in stylesheets.
- Removed deprecated design tokens and introduced new semantic color definitions for dark and light modes.
- Added custom utility classes for layout and spacing to supplement Bootstrap utilities.
- Cleaned up unused styles and variables to streamline the codebase.
- Added muted variant styles for Card and Paper components in ThemeWrapper.
- Removed color prop from multiple Text and Button components to use default theme colors.
- Updated background colors in various components to use new color variables.
- Refactored styles in Table and LogTable modules for consistency with new color scheme.
- Removed unused color classes and variables to streamline styles.
- Enhanced hover effects for buttons and text elements for better UX.
…variables; update styles for consistency across the application; enhance accessibility by adjusting text properties; modify button variants for improved UI/UX; streamline form elements and layout for better responsiveness; clean up unused imports and redundant code; ensure uniformity in text sizes and colors throughout the application.
…lean up related code; replace NavHoverDropdown with Mantine's Button component; update styles in SessionSidePanel and various SCSS files for consistency and improved theming; delete obsolete variables.scss file.
…t; update related modal handling and styling for consistency
…ructure and improve readability; adjust Badge component usage in AppNavLink for better consistency; update ThemeWrapper to remove default radius for enhanced theming flexibility
…cy; enhance color usage across components; streamline styles for improved theming and accessibility
…d colors; adjust height for improved styling consistency; enhance BreadcrumbNavigation text color for better visibility; implement custom cursor style for table column resizing; modify semantic colors for improved theming and accessibility.
…with custom implementations for improved consistency and maintainability
@changeset-bot

changeset-botBot commented Nov 11, 2025

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: ecab514

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
NameType
@hyperdx/appMinor
@hyperdx/apiMinor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@vercel

vercelBot commented Nov 11, 2025

Copy link
Copy Markdown

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

ProjectDeploymentPreviewCommentsUpdated (UTC)
hyperdx-v2-oss-appReadyReadyPreviewCommentNov 14, 2025 5:42pm

@elizabetdevelizabetdev changed the title Refactor: Remove react-bootstrap, adopt semantic tokens, and improve Mantine UI usageRefactor: Remove bootstrap, adopt semantic tokens, and improve Mantine UI usageNov 11, 2025
@claude

claudeBot commented Nov 11, 2025

Copy link
Copy Markdown

PR Review: Bootstrap Removal & Mantine Migration

✅ Overall Assessment

This is a well-structured refactor that successfully removes Bootstrap dependencies and migrates to Mantine UI with semantic design tokens. The approach is solid and aligns with modern React/Next.js best practices.

Critical Issues

None found - the PR appears safe to merge from a code quality perspective.

Important Observations

✅ Strengths:

  • Comprehensive semantic color token system in _semantic-colors.scss with proper light/dark mode support
  • Proper removal of Bootstrap dependencies from package.json
  • Consistent migration to Mantine components (Popover, Textarea, ActionIcon, etc.)
  • Good use of CSS custom properties for theming
  • Proper TypeScript typing maintained throughout

⚠️ Minor Concerns (non-blocking):

  • Large changeset: 2824 additions / 2066 deletions across 98 files - consider thorough visual QA testing
  • SCSS typo in AppNav.module.scss:38: margin-bottom: 2x should be 2px (likely non-breaking but incorrect)
  • Removed SSRProvider: Ensure this doesn't break SSR for Mantine components (Mantine v7+ may not need it)
  • Bootstrap Icons dependency: Still using bootstrap-icons CSS despite removing Bootstrap (intentional?)

Testing Recommendations

  • ✅ Visual regression testing across both light and dark themes
  • ✅ Verify accessibility (contrast ratios, keyboard navigation)
  • ✅ Test on mobile/responsive layouts
  • ✅ Verify no hydration errors in SSR

Verdict

Approved - No blocking issues. The minor items noted above can be addressed in follow-up PRs or confirmed as intentional.

@github-actions

github-actionsBot commented Nov 11, 2025

Copy link
Copy Markdown
Contributor

E2E Test Results

All tests passed • 39 passed • 3 skipped • 399s

StatusCount
✅ Passed39
❌ Failed0
⚠️ Flaky1
⏭️ Skipped3

View full report →

…r variable; remove unused color classes for improved clarity and maintainability
… variables for background and border styles; enhance link color based on active state for improved theming and consistency
…e bootstrap utilities documentation for clarity
@pulpdrew

Copy link
Copy Markdown
Contributor

Whoops, I missed the edited comment, sorry @elizabetdev. Ripping the band-aid off is OK with me 👍

@elizabetdev

Copy link
Copy Markdown
ContributorAuthor

@teeohhem and @pulpdrew, I’ve finished addressing Drew’s review.

@teeohhem

Copy link
Copy Markdown
Contributor

My biggest thing I saw was this:
New:
image

Existing:
image

  1. Did we intentionally change the font and its size for the nav?
  2. Items are out of alignment in submenus

@elizabetdev

Copy link
Copy Markdown
ContributorAuthor

@teeohhem I updated the AppNav component to bring it closer to the previous version. The icons on this PR are from Tabler, and a few small UI details were left intentionally (e.g., icon highlight behavior and the beta badge aligned to the right). The beta badge is also using Mantine’s default styling with no overrides, so the text defaults to white. The nav now uses only mantine colors.

menu

@teeohhemteeohhem left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Nicely done!

@elizabetdev
elizabetdev merged commit af6a8d0 into mainNov 14, 2025
9 of 10 checks passed
kodiakhqBot pushed a commit that referenced this pull request Nov 19, 2025
…1384)
This was a regression from #1347. This adds back the existing styles.
<img width="1210" height="548" alt="Screenshot 2025-11-19 at 9 53 27 AM" src="https://github.com/user-attachments/assets/52343706-2b92-4779-94c0-bdccb1668f09" />
Fixes HDX-2863
knudtty pushed a commit that referenced this pull request Apr 16, 2026
knudtty pushed a commit that referenced this pull request Apr 16, 2026
…1384)
This was a regression from #1347. This adds back the existing styles.
<img width="1210" height="548" alt="Screenshot 2025-11-19 at 9 53 27 AM" src="https://github.com/user-attachments/assets/52343706-2b92-4779-94c0-bdccb1668f09" />
Fixes HDX-2863
kodiakhqBot pushed a commit that referenced this pull request Jul 6, 2026
…lowing into adjacent columns (#2234)
## Summary
- Re-add `.text-break`, `.align-top`, `.align-middle`, `.align-bottom` utility classes to `_bootstrap-utilities.scss`. These were referenced by `HDXMultiSeriesTableChart` and `DBRowTable` but dropped during the Bootstrap removal refactor (#1347), leaving wrap mode silently broken.
## Why
With `.text-break` undefined, toggling wrap mode on a Table chart cell containing a long URL/identifier without whitespace leaves the cell with only `overflow: hidden` and default `word-break: normal`. The browser can't break the string, partial fragments leak across cell boundaries during fallback rendering, and the visible result is text appearing to overlap into adjacent columns. Reproducible with many narrow columns + URLs like `login.microsoftonline.com/common/oauth2/v2.0/authorize?client_id=…`.
## Test plan
- [ ] Build a Table chart over data with long unbreakable strings (URLs, trace IDs, hashes)
- [ ] Toggle the wrap-lines icon — long values should break onto multiple lines within their column rather than fragmenting across columns
- [ ] Toggle wrap-lines off — truncate-with-ellipsis behavior unchanged
- [ ] Existing `DBTableChart.test.tsx` still passes
- [ ] Before:
<img width="2856" height="460" alt="image" src="https://github.com/user-attachments/assets/c19c0f4e-a445-40e0-b477-592176687281" />
After: <img width="995" height="246" alt="image" src="https://github.com/user-attachments/assets/617923c1-65fd-40e3-85ec-1484d23c4678" />
Ref: HDX-4180
Sign up for freeto 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.

4 participants

@elizabetdev@brandon-pereira@pulpdrew@teeohhem