Repository navigation
fix(console): on a phone, a page the assistant opens closes its sheet - #37571
Draft
objectstack-fleet[bot] wants to merge 2 commits into
Draft
objectstack-fleet[bot] wants to merge 2 commits into
objectstack-fleet[bot] wants to merge 2 commits into
Conversation
A citation chip in the phone assistant sheet opened the cited record section underneath while the sheet stayed over it. A navigation that leaves the page, or a PUSH onto the same page, now collapses the sheet; the desktop rail is unchanged. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Utp6CXDoFxnz75MqdAxLSW
…her layout The booted phone check showed a chip in the sheet opened over Home lands on an app's record through another layout, which mounts a new dock host that never saw the navigation. The history entry the sheet was shown on is now kept per tab, so the new host closes it too; a REPLACE never does. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Utp6CXDoFxnz75MqdAxLSW
This branch has not been deployed
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.
Requested by Bill · project thread
Fixes #37556
Clause-②: no
Metadata-protocol: none
维护者速读
What changes
ui/packages/app-shell/src/layout/useConsoleChatDock.tsx: on a phone (the drawer is a bottom sheet over the page), the host closes the sheet when the location moves by a PUSH or POP away from the history entry (location.key) the sheet was shown open on. A PUSH onto the same URL counts (a second click on the same citation chip carries fresh section state to the same URL). A REPLACE never closes it: a page rewriting its own query, the host's handoff hand-over, and an old/ai…link landing with the drawer armed open all stay as they were.ai-chat-dock-sheet-shown-at, cleared whenever the sheet is closed), not in the hook. The booted check found why: a chip in the sheet opened over Home lands on an app's record through another layout, which mounts a new dock host that never saw the navigation; a hook-local rule left the sheet open there.open_record, list link, open-form) now reveals the page, and the chip's click path (AiChatPage.tsx, under PR fix(chatbot): redraw record-citation chips after a reload; keep the cited-section scroll to new clicks #37539) is not touched..changeset/37556-phone-dock-closes-on-citation.md(patch,@object-ui/app-shell).Read first:
useConsoleChatDock.tsx, the effect under the full-window one and the two storage helpers abovehasHandoff.Tests
ui/packages/app-shell/src/layout/__tests__/useConsoleChatDock.phoneCollapseOnNavigate-37556.test.tsx(5), the real host,useChatDockStateand router, with stand-in sheet/rail: a phone chip click (PUSH to the cited record) closes the sheet, and reopening it with no target shows the same conversation; a re-click of the same chip URL closes the reopened sheet; a chip that leaves Home for an app (two layouts, two hosts) closes it and reopening shows the same conversation; a same-page REPLACE leaves it open; CONTROL: at desktop width the rail stays open after the same chip click.Acceptance notes
Verification
@object-ui/app-shelltype-checkexit 0; the 38 derived gate families exit 0 (dispatch-gates --ran: 38 run, 0 NOT-MEASURED). The package's whole suite is left to CI'sTest UI(a local whole-suite run of this package took about an hour on 37365 跟进:刷新或重开对话后,AI 回答下方的引用消失 #37487); declared narrowing.pnpm --dir ui exec vitest run packages/app-shell/src/layout/__tests__/useConsoleChatDock.phoneCollapseOnNavigate-37556.test.tsx, expected 5 passed.objectstack dev --seed-admin) with theui/console dev server pointed at it. Injected, not produced: no producer emits the citations part before cloud 10c, so the run serves the conversation-history read with an answer carrying adata-record-citationspart, and a one-agent catalog because the boot has no model./ai/ask/CONVERSATIONlink lands on Home with the sheet open and 3 chips./apps/com.example.showcase/showcase_field_zoo/record/ID?section=contractor-scope, sheet gone (0 in the DOM), the marked headingContractor scopeat top 45 px, in view. Before the per-tab fix the same run left the sheet open over it.objectstack-seat5/ai-36996/shots-37556/in the project files (phone-dock-before-chip.png,phone-dock-chip-closes-sheet.png,phone-dock-reopened-same-thread.png,phone-dock-same-chip-again.png, plus the script).🤖 Generated with Claude Code
Generated by Claude Code