Skip to content

fix(core): a typed code without an alpha keeps the alpha in force (#116) - #117

Merged
Maxaubert merged 2 commits into
mainfrom
fix/typed-code-keeps-alpha
Oct 3, 2026
Merged

Maxaubert merged 2 commits into
mainfrom
fix/typed-code-keeps-alpha

Conversation

@Maxaubert

Copy link
Copy Markdown
Owner

Closes #116.

Owner, 2026-10-03: "yes", to keeping the alpha when a 6-digit code is typed. Before this, typing #203040 into a see-through Primary in Prism turned the window solid, because a typed code counted as a whole new colour, alpha included.

  • The change: in colourCommit (core), a code that names no alpha (#rgb, #rrggbb, rgb(), hsl()) changes only the colour and keeps the alpha in force. A code that says an alpha (#rgba, #rrggbbaa, a fourth argument to rgba() or hsla()) sets it, solid included. The alpha bar is unchanged. This applies to every colour field in both apps.
  • New pure helper: saysAlpha, with tests.
  • Versions: core 0.22.1, app 0.27.1. Prism gets it through the automatic core update, whose terminal gate runs termColourPicker.

Verified (the PR gate):

  • Typecheck and lint pass (0 errors). 1221 unit tests pass, including 3 new colourCommit / saysAlpha cases.
  • E2E colourPicker (48 checks) and opacityAlpha (21) pass.
  • Prism's own tests type a 6-digit code once, into the theme editor's Background. That field has no alpha in Prism, so its result doesn't change.

🤖 Generated with Claude Code

https://claude.ai/code/session_01FHHaWKR4M5QtW7Wecyuk4t

@Maxaubert
Maxaubert merged commit bc41fe5 into main Oct 3, 2026
2 checks passed
@Maxaubert
Maxaubert deleted the fix/typed-code-keeps-alpha branch October 3, 2026 18:11
github-actions Bot pushed a commit that referenced this pull request Oct 3, 2026
…) (#117)

* fix(core): a typed code without an alpha keeps the alpha in force (#116)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FHHaWKR4M5QtW7Wecyuk4t

* chore: version 0.27.1

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to 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.

A typed colour code without an alpha keeps the alpha in force

1 participant