mirror of
https://github.com/anomalyco/opentui.git
synced 2026-04-25 13:06:00 +03:00
[GH-ISSUE #196] Hex colors with alpha channel (#RRGGBBAA) don't render transparency in React #40
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#40
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?
Originally created by @remorses on GitHub (Oct 2, 2025).
Original GitHub issue: https://github.com/anomalyco/opentui/issues/196
When using hex color codes with alpha values (e.g.,
#ff000080for 50% transparent red), the transparency is ignored and the color renders as fully opaque. This forces developers to useRGBA.fromInts()instead of the more common hex format with alpha.Reproduction
Expected behavior
The hex color
#ff000080should render as semi-transparent red (50% opacity), matching the behavior ofRGBA.fromInts(255, 0, 0, 128).Actual behavior
The hex color with alpha channel renders as fully opaque, ignoring the alpha value.
Workaround
Use
RGBA.fromInts()instead of hex colors when transparency is needed.@kommander commented on GitHub (Oct 25, 2025):
This should work in the latest version.