Fix layout-loading state regression in chat overlay projection#51
Fix layout-loading state regression in chat overlay projection#51google-labs-jules[bot] wants to merge 2 commits into
Conversation
This resolves an issue where ShouldLoad... properties in ChatConversationSurfaceProjectionCoordinator would regress to false when their visual components were temporarily hidden (e.g., by a blocking overlay). In XAML/Uno, properties bound to x:Load should ideally be monotonic to avoid destroying the realized visual tree unnecessarily. Tracking these with a boolean union (|=) ensures they stay true after the first realization. Updated tests to enforce this new behavior.
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
Your free trial has ended. If you'd like to continue receiving code reviews, you can add a payment method here.
Fixed a whitespace error in `ChatViewModelTests.cs` that was failing the CI code quality check step.
|
Closing during PR triage: this is a stale or duplicate layout-loading monotonicity attempt. #49 is the clean green candidate for this behavior; this PR is superseded, failing/conflicting, or mixed-scope and should not be merged as-is. |
Understood. Acknowledging that this work is now obsolete and stopping work on this task. |
Problem:
During a rapid UI transition (like a session switch or hydration overlay), the XAML elements representing the active conversation root and the transcript surface could be destroyed and un-loaded because
ShouldLoadActiveConversationRootandShouldLoadTranscriptSurfaceincorrectly reverted tofalsewhen their correspondingShouldShow...properties were temporarily set tofalse.Root Cause:
ChatConversationSurfaceProjectionCoordinatormapped the load states exactly 1:1 with the show states.Why the fix is safe architecturally:
The fix changes the load states to be strict monotonic booleans per coordinator instance: once
ShouldShowbecomes true for the first time,ShouldLoadbecomes and stays true. This preserves XAML performance (the tree is built once and hidden/shown, rather than torn down and rebuilt), aligns with standard Uno/WinUI practices forx:Loadbindings, and keeps XAML state behavior purely within the Presentation.Core projection layer without touching the deeper domain or code-behind.Exact verification commands I ran:
Any remaining unverified GUI-only risks:
No apparent GUI risks, as the visibility rules remain strictly data-driven via
ShouldShow, and XAML bindings tox:Loadwill respect the persistenttruestate, maintaining local state on toggle. AllChatViewModeltests mapping derived states during rapid navigation switches passed successfully.PR created automatically by Jules for task 3281149794251732661 started by @YoungSx