mirror of
https://github.com/anomalyco/opentui.git
synced 2026-04-24 20:45:56 +03:00
[PR #755] Support 256-color fallback for terminals without truecolor #1538
Labels
No labels
bug
core
documentation
feature
good first issue
help wanted
pull-request
question
react
solid
tmux
windows
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/opentui#1538
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/anomalyco/opentui/pull/755
Author: @ryan-z
Created: 2/28/2026
Status: 🔄 Open
Base:
main← Head:feat/256-color-fallback📝 Commits (2)
73952c7feat: 256-color-fallbackd108647refactor: optimize getCapabilities call and add tests📊 Changes
4 files changed (+169 additions, -3 deletions)
View changed files
📝
packages/core/src/zig/ansi.zig(+91 -0)📝
packages/core/src/zig/renderer.zig(+16 -3)📝
packages/core/src/zig/test.zig(+2 -0)➕
packages/core/src/zig/tests/ansi_test.zig(+60 -0)📄 Description
Problem
macOS Terminal.app does not support truecolor (24-bit RGB) by default, limiting colors to the standard 16 or 256 color palette. This makes it hard to see the full range of colors in opentui.
Solution
This PR adds a 256-color fallback:
$COLORTERMenvironment variableUse case
Running opentui in macOS Terminal.app and seeing more than 16 colors.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.