fix(edit): curate the CalDAV colour picker (#22) #70
Reference in New Issue
Block a user
Delete Branch "fix/caldav-color-picker-v2"
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?
Revives the CalDAV colour-picker curation (Codeberg #22, reported by @ptab) that was written on
fix/caldav-color-pickerbut never merged — it stalled during the floret-kit migration, which then extractedpastelizeand invalidated the branch's approach. This is a fresh re-land adapted to today's tree.The bug
CalDAV sync adapters (DAVx5) publish all ~147 CSS3 named colours into
CalendarContract.Colors, so the event-colour picker showed a full screen of alphabetically-scrambled, duplicated swatches. It's still live in shipped builds —eventColorPalette()returned the raw list and the picker painted it straight.The fix
Curation now runs in the space the picker actually paints (softened through
pastelize: pinned lightness, capped saturation):The CSS3 dump lands at ~33 distinct, rainbow-ordered swatches. Small hand-picked palettes (Google's) pass through untouched. Every surviving swatch keeps its provider colour key, so picks still round-trip through sync.
floret-kit adaptation
Since the original branch,
pastelizemoved into floret-kit. The painted-space transform now lives self-contained indomain/pastelArgb()as a documented mirror of floret'spastelizeshaping (kept in sync by hand), rather than the two sharing one function.Notes
release/v2.14.1(bugs-only patch train). Rebased to a single commit so no Weblate translation churn rides along../gradlew test lintgreen locally.Closes #22.
Generated with Claude Code