fix(web): lane inline-create opens the split pane on desktop, stays put on mobile (IDEA-2298) - #1036
Merged
Merged
Conversation
…ut on mobile (IDEA-2298)
The board lane `+` opens a Trello-style draft card (TASK-1676) whose Enter
handler hardcoded a full-page `goto(.../{item}?new=1)`. TASK-1676 predates the
split pane (PLAN-2105), so nothing revisited that destination, leaving the one
create gesture that already knows its title as the only card-open path that
bypasses the pane:
- Clicking an EXISTING card opens the split pane (`onItemOpen` → `?item=`);
creating one navigated the whole page away from the board.
- `?new=1` exists to drop you into the title editor of a fresh "Untitled" item
(`createNewItem`). On this path the title was just typed, so it re-opened the
title editor with that title select-alled.
- There was no viewport branching at all, so mobile — where the lane `+` is
fully present — got ejected off the board too, making a second add a Back
navigation.
`quickCreateInColumn`'s third param becomes `reveal` (caller INTENT) rather than
`navigate` (a destination): the local-index upsert is now unconditional so the
card always lands in its lane, and revealing means `openItemPane(item)` on
desktop and nothing on mobile. The page owns what revealing means, so BoardView
stays unaware the pane exists. The composer closes on submit on every viewport —
on desktop the pane takes focus, so keeping it open for rapid entry would fight
it. Revisit if feedback asks for mobile rapid-add.
The nav-guard's Save-all keeps passing `reveal: false`; saving drafts on the way
out must never open anything.
New e2e pins both destinations and, on both viewports, that the pathname never
changes and `?new=1` is never set. Two traps worth recording: the created card
renders off the SYNCHRONOUS local-index upsert, so it is not a sync point for
the navigation that follows — the first draft of both tests passed against the
reverted fix because the URL assertions raced an unresolved `goto`. Desktop now
waits on `?item=`; mobile can't poll an absence, so it proves the negative
positively by re-opening the lane composer (only possible if the board is still
mounted, and awaiting it gives a would-be navigation time to land). Verified by
mutating the fix back out: both fail for the right reasons, pass on the fix.
Gates: npm run check 0 errors, npm run test 490 passed, new spec 2/2, pane e2e
64/65 (the one failure is the pre-existing BUG-2334 SSE-toast flake, confirmed
by screenshot and passing in isolation). Codex review CLEAN (CONVE-735).
Claude-Session: https://claude.ai/code/session_01E2fRi12n8rARczvdEa2LYT
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
The board lane
+opens a Trello-style draft card (TASK-1676); Enter created the item and then navigated the whole page away to.../{item}?new=1. TASK-1676 predates the split pane (PLAN-2105), so nothing ever revisited that destination.That left the one create gesture that already knows its title as the only card-open path bypassing the pane:
onItemOpen→?item=); creating one left the board entirely.?new=1exists to drop you into the title editor of a fresh"Untitled"item (createNewItem). Here the title was just typed — so it re-opened the title editor with that title select-alled. That's the specific thing that felt wrong.+is fully present at ≤768px, so mobile got ejected off the board too, making a second add a Back navigation.Behavior now
?item=)?new=1quickCreateInColumn's third param becomesreveal(caller intent) rather thannavigate(a destination). The local-index upsert is unconditional so the card always lands in its lane; revealing meansopenItemPane(item)— the same entry point a card click uses — gated on!viewport.isMobile. The page owns what revealing means, soBoardViewstays unaware the pane exists.The composer closes on submit on every viewport. On desktop the pane takes focus, so keeping it open for Trello-style rapid entry would fight it; uniform close is the deliberate call for now, revisitable on feedback.
The nav-guard's Save-all keeps passing
reveal: false— saving drafts on the way out must never open anything.Testing
New
web/e2e/lane-inline-create.spec.tspins both destinations plus the two invariants (pathname unchanged, no?new=1).Two traps worth recording, since they made the first draft of both tests vacuous:
make installtests the stale binary.goto(the desktop pathname assertion passed vacuously; only the?item=check bit). Desktop now waits on?item=landing. Mobile can't poll an absence, so it proves the negative positively — it re-opens the lane composer, which only works if the board is still mounted, and awaiting that click gives a would-be navigation time to land. It also encodes the real UX win: add a second card immediately instead of navigating back.Verified by mutating the fix back out and rebuilding: both fail for the right reasons, pass on the fix.
Also note: the docs collection empty-states to "No docs yet" with no lanes at all, so the spec seeds an anchor doc before there's a
+to click.Gates
npm run check— 0 errors (6 pre-existing warnings)npm run test— 490 passedOut of scope
ListViewgroups by status but has no per-group+at all, so inline create remains board-only. Extending it there is a separate item.Closes IDEA-2298.
https://claude.ai/code/session_01E2fRi12n8rARczvdEa2LYT