Skip to content

Fix layout-loading state regression in chat overlay projection#51

Closed
google-labs-jules[bot] wants to merge 2 commits into
mainfrom
fix/chat-surface-loading-monotonicity-3281149794251732661
Closed

Fix layout-loading state regression in chat overlay projection#51
google-labs-jules[bot] wants to merge 2 commits into
mainfrom
fix/chat-surface-loading-monotonicity-3281149794251732661

Conversation

@google-labs-jules

Copy link
Copy Markdown
Contributor

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 ShouldLoadActiveConversationRoot and ShouldLoadTranscriptSurface incorrectly reverted to false when their corresponding ShouldShow... properties were temporarily set to false.

Root Cause:
ChatConversationSurfaceProjectionCoordinator mapped 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 ShouldShow becomes true for the first time, ShouldLoad becomes 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 for x:Load bindings, 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:

dotnet build SalmonEgg.sln --configuration Debug
dotnet test tests/SalmonEgg.Presentation.Core.Tests/SalmonEgg.Presentation.Core.Tests.csproj --configuration Debug --no-restore
dotnet test SalmonEgg.sln --configuration Debug --no-build

Any remaining unverified GUI-only risks:
No apparent GUI risks, as the visibility rules remain strictly data-driven via ShouldShow, and XAML bindings to x:Load will respect the persistent true state, maintaining local state on toggle. All ChatViewModel tests mapping derived states during rapid navigation switches passed successfully.


PR created automatically by Jules for task 3281149794251732661 started by @YoungSx

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.
@google-labs-jules

Copy link
Copy Markdown
Contributor Author

👋 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 @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

@vercel

vercel Bot commented Jun 3, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
salmonegg Ready Ready Preview, Comment Jun 3, 2026 10:59pm

@greptile-apps greptile-apps Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

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.
@YoungSx

YoungSx commented Jun 25, 2026

Copy link
Copy Markdown
Contributor

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.

@YoungSx YoungSx closed this Jun 25, 2026
@google-labs-jules

Copy link
Copy Markdown
Contributor Author

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.

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.

1 participant