Skip to content

feat(theme): add gruvbox dark/light (+variants) - #8153

Merged
bijin-bruno merged 4 commits into
usebruno:mainfrom
taylrfnt:feature/gruvbox-theme
Sep 18, 2026
Merged

bijin-bruno merged 4 commits into
usebruno:mainfrom
taylrfnt:feature/gruvbox-theme

Conversation

@taylrfnt

@taylrfnt taylrfnt commented May 30, 2026 •

Copy link
Copy Markdown
Contributor

REF - BRU-4385

Description

I noticed that #6711 had been closed without a new PR, and #5692 has stalled - I love using Bruno daily and wanted to help contribute the gruvbox theme!

This PR adds support for both gruvbox light and dark, in all 3 variants of each aligned with the vscode gruvbox theme. I did use some AI review while working locally as I am not a JavaScript developer, but I do not consider that a "significant" use case.

I have incorporated all the variants within the gruvbox dark/light JS files via shared factories - if these need to be split out I am happy to do so, I was just trying to keep the file count and duplication of code down.

Here's some quick screenshot previews of each flavor:

Gruvbox Dark - Hard
image

Gruvbox Dark - Medium
image

Gruvbox Dark - Soft
image

Gruvbox Light - Hard
image

Gruvbox Light - Medium
image

Gruvbox Light - Soft
image

Contribution Checklist:

  • I've used AI significantly to create this pull request
  • The pull request only addresses one issue or adds one feature.
  • The pull request does not introduce any breaking changes
  • I have added screenshots or gifs to help explain the change if applicable.
  • I have read the contribution guidelines.
  • Create an issue and link to the pull request.

Note: Keeping the PR small and focused helps make it easier to review and merge. If you have multiple changes you want to make, please consider submitting them as separate pull requests.

Publishing to New Package Managers

Please see here for more information.

Summary by CodeRabbit

Summary by CodeRabbit

  • New Features
    • Added six Gruvbox theme variants: Light and Dark, each available in soft, medium, and hard contrast levels.
    • Added Gruvbox themes to the app theme selector, with medium contrast as the default for both modes.
    • Applied Gruvbox styling across the interface, including controls, panels, editor, notifications, and toolbars.

@coderabbitai

coderabbitai Bot commented May 30, 2026 •

Copy link
Copy Markdown
Contributor

Review Change StackReview Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Advanced

Run ID: ce7cbbda-a043-4a25-84ec-a1ef73c43cf0

📥 Commits

Reviewing files that changed from the base of the PR and between 70c697a and 0603430.

📒 Files selected for processing (2)
  • packages/bruno-app/src/themes/dark/gruvbox.js
  • packages/bruno-app/src/themes/light/gruvbox.js

Included review availability: Your plan provides up to 10 included reviews per hour; 8 remain after this review.


Walkthrough

Adds Gruvbox light and dark theme modules with soft, medium, and hard variants. Each module defines palette and theme factories, exports three theme instances, and uses the medium variant as the default. The theme index registers all six variants with mode metadata.

Changes

Gruvbox Theme Family

Layer / File(s) Summary
Gruvbox Light Palette and Color System
packages/bruno-app/src/themes/light/gruvbox.js
Defines shared light colors, contrast-specific background ladders, and derived intent and syntax tokens.
Gruvbox Light Theme Factory and Exports
packages/bruno-app/src/themes/light/gruvbox.js
Builds the light theme object across UI, request, editor, console, and application surfaces. Exports soft, medium, and hard variants.
Gruvbox Dark Palette and Color System
packages/bruno-app/src/themes/dark/gruvbox.js
Defines shared dark colors, contrast-specific background ladders, and derived intent and syntax tokens.
Gruvbox Dark Theme Factory and Exports
packages/bruno-app/src/themes/dark/gruvbox.js
Builds the dark theme object across UI, request, editor, console, and application surfaces. Exports soft, medium, and hard variants.
Theme Registration and Index Integration
packages/bruno-app/src/themes/index.js
Imports all six variants, adds them to themes, and adds light/dark metadata to themeRegistry.

Priority: ➖ Normal

Estimated code review effort: 3 (Moderate) | ~25 minutes

Change: Feature

Merge Risk: ⚪ Minimal · up to 06034

The Gruvbox variants are registered with matching mode metadata, and no remaining merge-blocking risk is established.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the main change: adding Gruvbox light and dark themes with variants.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 2…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Gruvbox shades now line the view
Soft, medium, hard in hue
Light and dark palettes align
Editors glow with syntax shine
Six themes enter the registry anew

Comment @coderabbitai help to get the list of available commands.

@taylrfnt
taylrfnt force-pushed the feature/gruvbox-theme branch from 4ac762f to b56a6fe Compare May 30, 2026 22:16

@coderabbitai coderabbitai Bot 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.

🧹 Nitpick comments (1)
packages/bruno-app/src/themes/light/gruvbox.js (1)

90-93: 💤 Low value

Consider adding variant parameter validation.

The createPalette function doesn't validate that variant is one of 'hard', 'medium', or 'soft'. While the current exports are controlled, adding a guard would prevent potential issues if this factory is used elsewhere in the future.

🛡️ Optional defensive check
 const createPalette = (variant) => {
+  if (!['hard', 'medium', 'soft'].includes(variant)) {
+    throw new Error(`Invalid Gruvbox variant: ${variant}. Must be 'hard', 'medium', or 'soft'.`);
+  }
   const palette = {
     ...sharedPalette,
     background: backgroundsByVariant[variant]
   };
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@packages/bruno-app/src/themes/light/gruvbox.js` around lines 90 - 93, The
createPalette function should validate the variant argument is one of the
allowed values ('hard', 'medium', 'soft') before using
backgroundsByVariant[variant]; add a guard in createPalette that checks variant
against this set and either throws a clear error or falls back to a default
(e.g., 'medium') and logs/warns, referencing the createPalette function and the
backgroundsByVariant lookup to locate the change.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In `@packages/bruno-app/src/themes/light/gruvbox.js`:
- Around line 90-93: The createPalette function should validate the variant
argument is one of the allowed values ('hard', 'medium', 'soft') before using
backgroundsByVariant[variant]; add a guard in createPalette that checks variant
against this set and either throws a clear error or falls back to a default
(e.g., 'medium') and logs/warns, referencing the createPalette function and the
backgroundsByVariant lookup to locate the change.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 7eb6b689-8498-4c51-a212-bc99655651fe

📥 Commits

Reviewing files that changed from the base of the PR and between 7413465 and 4ac762f.

⛔ Files ignored due to path filters (1)
  • package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (3)
  • packages/bruno-app/src/themes/dark/gruvbox.js
  • packages/bruno-app/src/themes/index.js
  • packages/bruno-app/src/themes/light/gruvbox.js

this commit adds support for both gruvbox light and dark, in all 3 variants of each aligned with the vscode gruvbox theme
@taylrfnt
taylrfnt force-pushed the feature/gruvbox-theme branch from b56a6fe to 0fa7dbb Compare May 30, 2026 22:26
@taylrfnt

taylrfnt commented May 30, 2026 •

Copy link
Copy Markdown
Contributor Author

sorry about the force pushes - I had some other npm/JS changes hanging out locally that were updating package.lock that I didn't mean to push. I've amended my commits to include just the gruvbox theme changes :)

@taylrfnt taylrfnt changed the title theme: add gruvbox feat(theme): add gruvbox May 30, 2026
@taylrfnt taylrfnt changed the title feat(theme): add gruvbox feat(theme): add gruvbox dark/light (+variants) May 30, 2026

@coderabbitai coderabbitai Bot 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.

Actionable comments posted: 1

🧹 Nitpick comments (1)
packages/bruno-app/src/themes/light/gruvbox.js (1)

103-124: ⚡ Quick win

Derive syntax from the shared palette instead of repeating hex values.

These literals already exist in sharedPalette, so keeping them duplicated here makes palette edits easy to drift out of sync. Reusing the existing tokens keeps the factory consistent across variants.

♻️ Suggested cleanup
   palette.syntax = {
     // Core language structure
-    KEYWORD: '`#9d0006`', // red dark
-    TAG: '`#9d0006`',
+    KEYWORD: palette.hues.RED_BRIGHT,
+    TAG: palette.hues.RED_BRIGHT,
 
     // Identifiers & properties
-    VARIABLE: '`#3c3836`', // fg
-    PROPERTY: '`#076678`', // blue dark
-    DEFINITION: '`#b57614`', // yellow dark
+    VARIABLE: palette.text.BASE,
+    PROPERTY: palette.hues.BLUE_BRIGHT,
+    DEFINITION: palette.primary.TEXT,
 
     // Literals
-    STRING: '`#79740e`', // green dark
-    NUMBER: '`#8f3f71`', // purple dark
-    ATOM: '`#8f3f71`',
+    STRING: palette.hues.GREEN_BRIGHT,
+    NUMBER: palette.hues.PURPLE,
+    ATOM: palette.hues.PURPLE,
 
     // Operators & punctuation
-    OPERATOR: '`#af3a03`', // orange dark
-    TAG_BRACKET: '`#7c6f64`', // fg3
+    OPERATOR: palette.hues.ORANGE,
+    TAG_BRACKET: palette.text.SUBTEXT0,
 
     // Comments
-    COMMENT: '`#928374`' // gray dark
+    COMMENT: palette.overlay.OVERLAY1
   };
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@packages/bruno-app/src/themes/light/gruvbox.js` around lines 103 - 124,
palette.syntax currently duplicates hard-coded hexes; replace those literals by
referencing the existing sharedPalette tokens so variants stay in sync. Update
the assignment to palette.syntax to map each key (KEYWORD, TAG, VARIABLE,
PROPERTY, DEFINITION, STRING, NUMBER, ATOM, OPERATOR, TAG_BRACKET, COMMENT) to
the corresponding property from sharedPalette (e.g., KEYWORD:
sharedPalette.KEYWORD, COMMENT: sharedPalette.COMMENT, etc.) or derive via a
selective spread, and ensure sharedPalette is in scope/imported in gruvbox.js
before using it.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@packages/bruno-app/src/themes/light/gruvbox.js`:
- Around line 383-388: The close button theme entry uses an empty string for
hoverBorder which can produce invalid CSS; update the close object (the close
property in the gruvbox theme in packages/bruno-app/src/themes/light/gruvbox.js)
to use an explicit value such as 'transparent' for hoverBorder instead of '' so
the consuming styled rules get a valid token.

---

Nitpick comments:
In `@packages/bruno-app/src/themes/light/gruvbox.js`:
- Around line 103-124: palette.syntax currently duplicates hard-coded hexes;
replace those literals by referencing the existing sharedPalette tokens so
variants stay in sync. Update the assignment to palette.syntax to map each key
(KEYWORD, TAG, VARIABLE, PROPERTY, DEFINITION, STRING, NUMBER, ATOM, OPERATOR,
TAG_BRACKET, COMMENT) to the corresponding property from sharedPalette (e.g.,
KEYWORD: sharedPalette.KEYWORD, COMMENT: sharedPalette.COMMENT, etc.) or derive
via a selective spread, and ensure sharedPalette is in scope/imported in
gruvbox.js before using it.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 79fc26e3-ecfc-4a9b-9534-021f948ebefa

📥 Commits

Reviewing files that changed from the base of the PR and between b56a6fe and 0fa7dbb.

📒 Files selected for processing (3)
  • packages/bruno-app/src/themes/dark/gruvbox.js
  • packages/bruno-app/src/themes/index.js
  • packages/bruno-app/src/themes/light/gruvbox.js
🚧 Files skipped from review as they are similar to previous changes (2)
  • packages/bruno-app/src/themes/index.js
  • packages/bruno-app/src/themes/dark/gruvbox.js

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
@taylrfnt

taylrfnt commented Jun 7, 2026

Copy link
Copy Markdown
Contributor Author

Just circling back - I did address the easy win comment from coderabbit - if the nitpick aligns with the maintainers' POV I am happy to address this as well. Just wanted to make sure this is not waiting on me, let me know if this needs any other changes!

@bijin-bruno
bijin-bruno merged commit 3315da6 into usebruno:main Sep 18, 2026
17 of 19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants