Repository navigation
refactor(web): drop dead date field keyboard flags and share the duplicate-copy grouping pass - #4562
Merged
Merged
Conversation
arrowDownOpensCalendar and keyboardOpensCalendar both defaulted to true and no call site ever passed false, so the branches they guarded were configuration nobody could reach. Drop both props and keep the behavior every caller already got. While in the handler, replace the switch (true) ladder with a plain switch on event.key: two cases carried a dead "&& !isOpen" term that the early return above already guaranteed. Pull the repeated preventDefault/stopPropagation pair into one consume helper and inline commitTypedDate, a single-use helper whose boolean return was discarded. Behavior preserving: no call site or assertion changes beyond removing the prop that is gone. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019hX2HqFjXbknuZmAsNmnx9
The holiday pass added a second copy of the grouping loop: walk data.ids, resolve the event and its calendar, build a group key, bucket by it. The two copies had already drifted - only the holiday pass skipped events an earlier pass dropped, and only the ical pass guarded a missing event. Group once behind a keyFor callback so each pass contributes only its own key rule. Both guards now hold for both passes, which is a no-op in practice: nothing is dropped before the first pass runs, and that pass already required an icalUid the key could not read from a missing event. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019hX2HqFjXbknuZmAsNmnx9
tyler-dane
enabled auto-merge
October 18, 2026 10:29
Contributor
Author
Tech-debt sweep, 2026-10-15 to 2026-10-18Window: the 50 commits merged to Addressed here (2 items, 1 PR):
Found and deliberately not acted on:
Pre-existing failures this sweep surfaced (both reproduce on clean
Labeled Generated by Claude Code |
Contributor
|
Boot bundle: 509.8 KB gzip (+0.0 KB vs main) |
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 and why
A debt pass over the last 7 days of merged changes (2026-10-15 to 2026-10-18).
No issue: this is the scheduled tech-debt sweep, not a product change. Two
behavior-preserving cleanups, one commit each.
1.
refactor(web): drop dead date field keyboard flagsEventFormDateFieldgrew two boolean props,arrowDownOpensCalendarandkeyboardOpensCalendar. Both defaulted totrue, and no call site everpassed
false:DatePickerspassedarrowDownOpensCalendarexplicitly astrue,TimePickersrelied on the default, andkeyboardOpensCalendarwasnever passed at all. The three branches they guarded were configuration
nobody could reach, and no test covered the
falseside. Both props aregone; every caller keeps the behavior it already had.
While in that handler:
switch (true)becomes a plainswitch (event.key). Two of its casescarried a
&& !isOpenterm that theif (isOpen) returnabove alreadyguaranteed, so the ladder was hiding dead conditions.
preventDefault()+stopPropagation()pair collapses intoone
consumehelper.commitTypedDateis inlined. It had one caller and its boolean return wasdiscarded.
2.
refactor(web): share the duplicate-copy grouping passThe holiday dedupe in #4553 added a second copy of the grouping loop in
mergeDuplicateCopies: walkdata.ids, resolve the event and its calendar,build a group key, bucket by it. The two copies had already drifted - only
the holiday pass skipped events an earlier pass dropped, and only the ical
pass guarded a missing event. Grouping now happens once behind a
keyForcallback, so each pass contributes only its own key rule. Both guards hold
for both passes, which is a no-op in practice: nothing is dropped before the
first pass runs, and that pass already required an
icalUidthat a missingevent could not supply.
Verify
type-check,lint,knipandtest:a11y(65 passed) are green. Bothfailures reproduce on clean
origin/main(5b0e9f8) in this sandbox with thediff reverted, so neither is this change's:
test:web- web shard 3/6 is killed at the runner's 5000 MB RSS rail(5198 MB here), stopping in
apps/calendar-web/src/components/SelectView/SelectView.test.tsx. Onorigin/mainthe same shard trips the same rail at the same file(5015 MB). Shards 1 and 2 pass in full (654 and 760 tests). The memory is
cumulative across the shard's 86 files, not one test: that file on its own
passes 33/33 in 5s.
test:e2e- 252 passed, 1 failed:e2e/calendars/calendar-experience.spec.ts:759"a read-only event can behidden from the menu, shown with x, and stays hidden after reload", on
expect(hidden card).toBeVisible(). Re-run alone onorigin/mainit failson the same locator with the same "element(s) not found".
Targeted runs covering the changed code are green:
bun test:web -- apps/calendar-web/src/events- 397 pass, 0 failbun test:web -- .../EventForm/DateControlsSection- 86 pass, 0 failThe removed props are compile-time surface, so
type-checkcovers theirremoval repo-wide.
Generated by Claude Code