Skip to content

Conversation

@Azd325
Copy link
Contributor

@Azd325 Azd325 commented Dec 22, 2025

Use base06 for text, markdown, and punctuation slots so the OpenCode target matches upstream Catppuccin palettes and provides better contrast across dark Stylix themes.

Previous:
Screenshot 2025-12-22 at 21 18 30

After:
Screenshot 2025-12-22 at 21 19 18


@stylix-automation stylix-automation bot added topic: home-manager Home Manager target topic: modules /modules/ subsystem labels Dec 22, 2025
@arunoruto
Copy link
Contributor

When I implemented it, I was using a few themes as guidelines.
I guess using a brighter foreground color makes sense.
I am not sure if we should check if other themes will also "behave" better.

Copy link
Member

@trueNAHO trueNAHO left a comment

Choose a reason for hiding this comment

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

Use base06 for text, markdown, and punctuation slots so the OpenCode target matches upstream Catppuccin palettes and provides better contrast across dark Stylix themes.

Previous:
Screenshot 2025-12-22 at 21 18 30

After:
Screenshot 2025-12-22 at 21 19 18

Since I do not really use AI tools, I might be wrong on this, but if the
provided screenshots show the AI's intermediate "reasoning", would it not make sense to make it visually less prominent than the final real output? What is upstream's default behavior here?

diff --git a/modules/opencode/hm.nix b/modules/opencode/hm.nix
index ce83cfe20..707c27b10 100644
--- a/modules/opencode/hm.nix
+++ b/modules/opencode/hm.nix
@@ -148,7 +148,7 @@ mkTarget {
                 light = colors.withHashtag.base0A;
               };
               markdownText = {
-                dark = colors.withHashtag.base04;
+                dark = colors.withHashtag.base06;
                 light = colors.withHashtag.base00;
               };
               primary = {
@@ -186,7 +186,7 @@ mkTarget {
                 light = colors.withHashtag.base0D;
               };
               syntaxPunctuation = {
-                dark = colors.withHashtag.base04;
+                dark = colors.withHashtag.base06;
                 light = colors.withHashtag.base00;
               };
               syntaxString = {
@@ -202,7 +202,7 @@ mkTarget {
                 light = colors.withHashtag.base07;
               };
               text = {
-                dark = colors.withHashtag.base04;
+                dark = colors.withHashtag.base06;
                 light = colors.withHashtag.base00;
               };
               textMuted = {

Why should these be different from markdownCodeBlock.dark:

markdownCodeBlock = {
dark = colors.withHashtag.base04;
light = colors.withHashtag.base00;
};

I am not sure if we should check if other themes will also "behave" better.

Usually checking the dark and light themes is fine.

On a side note, the pending PR #1857 introduces

base16Scheme = "${pkgs.base16-schemes}/share/themes/mellow-purple.yaml";

to make it hopefully visually very obvious when something is unthemed or not adaptive enough.

@Azd325
Copy link
Contributor Author

Azd325 commented Dec 23, 2025

I also adjusted the PR a bit more.

Usually checking the dark and light themes is fine.

I tested with solarized light and dark, and the change is not too big. On the other hand, with Catppuccin Mocha, it is a bigger change.

base16Scheme = "${pkgs.base16-schemes}/share/themes/mellow-purple.yaml";
to make it hopefully visually very obvious when something is unthemed or not adaptive enough.

Thanks for this recommendation. That makes the before-and-after effect more obvious

Before

Screenshot 2025-12-23 at 19 36 44 Screenshot 2025-12-23 at 19 36 41 Screenshot 2025-12-23 at 19 36 28

After

Screenshot 2025-12-23 at 19 38 29 Screenshot 2025-12-23 at 19 38 27 Screenshot 2025-12-23 at 19 38 19

@trueNAHO
Copy link
Member

Based on your screenshots, this makes the text indeed stand more out. However, does this align with the upstream behavior:

Since I do not really use AI tools, I might be wrong on this, but if the provided screenshots show the AI's intermediate "reasoning", would it not make sense to make it visually less prominent than the final real output? What is upstream's default behavior here?

@Azd325
Copy link
Contributor Author

Azd325 commented Dec 25, 2025

I see that is in this case not reasoning/thinking; that is an actual response.

I activated the thinking for the session and took before/after screenshots. So there are now extra blocks in the screenshot.
I also attached the default theme from OpenCode. (dark one)

Screenshot 2025-12-25 at 18 43 37 Screenshot 2025-12-25 at 18 43 45 Screenshot 2025-12-25 at 18 36 21 Screenshot 2025-12-25 at 18 36 09

Copy link
Member

@trueNAHO trueNAHO left a comment

Choose a reason for hiding this comment

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

I see that is in this case not reasoning/thinking; that is an actual response.

I activated the thinking for the session and took before/after screenshots. So there are now extra blocks in the screenshot. I also attached the default theme from OpenCode. (dark one)

Thanks for the clarification and screenshots. Seems like upstream distinguishes between "reasoning" and status reports.

I am fine with merging this if @arunoruto approves.

Copy link
Contributor

@arunoruto arunoruto left a comment

Choose a reason for hiding this comment

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

I tried the changes out today and it looked alright to me!

Using base09 for diff hunk headers and base0A for markdown block quotes made
neutral UI elements look urgent. Markdown code blocks also reused the default
text color as a background, reducing contrast.

Return these components to neutral backgrounds instead: keep diff hunk headers
on base03, block quotes on base03/base01, and code blocks on base01 so warnings
stay on base0A and urgency cues remain meaningful.
@trueNAHO trueNAHO added the backport: release-25.11 To be backported to the release-25.11 stable branch label Jan 4, 2026
@trueNAHO trueNAHO merged commit b135edb into nix-community:master Jan 4, 2026
5 checks passed
stylix-automation bot pushed a commit that referenced this pull request Jan 4, 2026
Using base09 for diff hunk headers and base0A for markdown block quotes
made neutral UI elements look urgent. Markdown code blocks also reused
the default text color as a background, reducing contrast.

Return these components to neutral backgrounds instead: keep diff hunk
headers on base03, block quotes on base03/base01, and code blocks on
base01 so warnings stay on base0A and urgency cues remain meaningful.

Link: #2100

Reviewed-by: NAHO <[email protected]>
Approved-by: NAHO <[email protected]>
Tested-by: Mirza Arnaut <[email protected]>
Approved-by: Mirza Arnaut <[email protected]>
(cherry picked from commit b135edb)
@stylix-automation
Copy link
Contributor

Successfully created backport PR for release-25.11:

@github-actions github-actions bot added the has: port to stable This has been backported to the latest stable branch label Jan 4, 2026
@Azd325 Azd325 deleted the opencode-base06 branch January 4, 2026 21:04
rwxae pushed a commit to rwxae/stylix that referenced this pull request Jan 5, 2026
Using base09 for diff hunk headers and base0A for markdown block quotes
made neutral UI elements look urgent. Markdown code blocks also reused
the default text color as a background, reducing contrast.

Return these components to neutral backgrounds instead: keep diff hunk
headers on base03, block quotes on base03/base01, and code blocks on
base01 so warnings stay on base0A and urgency cues remain meaningful.

Link: nix-community#2100

Reviewed-by: NAHO <[email protected]>
Approved-by: NAHO <[email protected]>
Tested-by: Mirza Arnaut <[email protected]>
Approved-by: Mirza Arnaut <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport: release-25.11 To be backported to the release-25.11 stable branch has: port to stable This has been backported to the latest stable branch topic: home-manager Home Manager target topic: modules /modules/ subsystem

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants