Seed drawn-feature fill alpha explicitly in the color - #15
Merged
Merged
Conversation
The EoGPT layer drawer's new alpha slider seeds from the fill color's alpha byte. Drawn features defaulted to a 6-digit #7cc242 — genuinely alpha FF, so the slider seeded at 100% while the polygon rendered translucent through the fill layer's baked-in 0.5 base fill-opacity. Agent-added polygons already carry 8-digit fills (e.g. #3388ff20), which is why they seeded correctly. Carry the drawn default's translucency in the color itself (0x80 = 50%), matching that convention. Note the effective rendered fill gets lighter (0.5 color alpha x 0.5 base = 0.25 vs 0.5 before); the baked 0.5 base is a separate discussion since changing it re-tints every geojson asset. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
User-drawn features defaulted to a 6-digit
fill_color="#7cc242"— alpha genuinelyFF— while rendering translucent through the fill layer's baked-in 0.5 basefill-opacity. Client style editors that read transparency from the color's alpha byte therefore showed 100% for a polygon that looks half-transparent. Agent-added polygons already carry their translucency in the color itself (e.g.#3388ff20) and behave consistently.This makes the drawn default follow the same convention:
fill_color="#7cc24280"(50%).Notes
fill-opacity(['case', hover, 0.72, 0.5]) is left untouched — changing it would re-tint every geojson asset on every map, and deserves its own issue if we want "color alpha is the whole truth" semantics.🤖 Generated with Claude Code