Skip to content

feat: merge RFC 7986 COLOR property for calendar components#321

Merged
niccokunzmann merged 8 commits into
mainfrom
feat/color-merging
Feb 24, 2026
Merged

feat: merge RFC 7986 COLOR property for calendar components#321
niccokunzmann merged 8 commits into
mainfrom
feat/color-merging

Conversation

@SashankBhamidi
Copy link
Copy Markdown
Collaborator

Closes #17

RFC 7986 §5.9 defines COLOR as a CSS3 color name that can appear on VCALENDAR, VEVENT, VTODO, and VJOURNAL. Apple extends this with X-APPLE-CALENDAR-COLOR at the calendar level.

This propagates the source calendar's resolved color to any component that lacks its own COLOR. When merging multiple calendars, the first calendar with a color wins for the merged VCALENDAR top-level property. Components that already declare COLOR are left untouched.

Bumps icalendar to >=7.0.0 to use the typed .color API (requires Python 3.10+). Also fixes latent UID-less deduplication bugs for VTODO and VJOURNAL components.

@codecov
Copy link
Copy Markdown

codecov Bot commented Feb 24, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.

Files with missing lines Coverage Δ
src/mergecal/calendar_merger.py 100.00% <100.00%> (ø)
src/mergecal/cli.py 47.82% <ø> (-2.18%) ⬇️
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Comment thread .github/workflows/ci.yml
Comment thread src/mergecal/calendar_merger.py Outdated
Comment thread src/mergecal/calendar_merger.py Outdated
Comment thread src/mergecal/calendar_merger.py
Comment thread src/mergecal/calendar_merger.py
Comment thread src/mergecal/calendar_merger.py Outdated
Copy link
Copy Markdown
Collaborator

@niccokunzmann niccokunzmann left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some changes :)

Comment thread src/mergecal/calendar_merger.py Outdated
Comment thread src/mergecal/calendar_merger.py Outdated
Comment thread src/mergecal/calendar_merger.py Outdated
Comment thread src/mergecal/calendar_merger.py Outdated
Comment thread src/mergecal/calendar_merger.py Outdated
Comment thread src/mergecal/calendar_merger.py
Comment thread src/mergecal/calendar_merger.py Outdated
Comment thread tests/test_color_merging.py Outdated
Comment thread tests/test_color_merging.py
Copy link
Copy Markdown
Collaborator

@niccokunzmann niccokunzmann left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a little change and that is it.
Documenting intention and not code.

Comment thread src/mergecal/calendar_merger.py
Comment thread tests/conftest.py Outdated
@niccokunzmann niccokunzmann merged commit d80fce0 into main Feb 24, 2026
14 checks passed
@niccokunzmann niccokunzmann deleted the feat/color-merging branch February 24, 2026 16:38
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.

Merging event/calendar colors

2 participants