You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The dashboard resource pane could show a different order depending on when it was opened. Resources discovered after the first snapshot were appended, and the browser saved that order even if the user had never moved anything.
Late resources and new groups now enter their default sort order. The dashboard saves only explicit moves, separately for resources and for groups within each grouping mode. It reapplies each move after the previous neighbor at the drop position, or before the next neighbor if the previous one is unavailable. Resources still stay under their parent.
Resource moves, group moves, user-added resource tags, and metric pins now use protected browser local storage. AppHost-declared tags are unchanged.
User-facing usage
With Grouping = None, if frontend and worker are already visible and proxy (a project) and redis (a container) are discovered later, the pane shows redis, frontend, proxy, worker rather than appending the new rows. You can still drag a resource to reorder it among its siblings without freezing the rest of the list.
Previously saved full-list orders, plaintext tags, and plaintext pins are not migrated. The dashboard starts with default ordering and no saved personal tags or pins. The next tag or pin edit replaces the corresponding plaintext value with a protected value. If the dashboard can no longer decrypt a saved value, that setting also returns to its default.
TODO (if users report hitting these limits): Add a way to clear obsolete metric pins and inaccessible personal tag assignments from the dashboard. Pins without matching telemetry and assignments for removed resources or tags now declared by the AppHost still count toward their respective limits. The dashboard currently cannot clear those entries.
Screenshots / Recordings
This PR includes UI changes. Please add screenshots or screen recordings so reviewers can evaluate the visual changes without running locally.
For before/after comparisons, place them side-by-side or label them clearly.
For interactive changes (animations, transitions, new flows), prefer a short screen recording (GIF or video).
If you cannot capture visuals now, note what scenario to test and mark this section as TODO.
TODO: Record the resource pane during discovery with Grouping = None to show late rows moving into their default positions. Then reorder a resource and reload to show that the move persists.
Security considerations
The dashboard uses its existing ASP.NET Core Data Protection keys to protect these values. It does not fall back to plaintext or create new plaintext backups. Existing plaintext entries and backups are not proactively removed. Protection applies to values, not the browser storage key names.
Validation
43 model tests passed on the final implementation, covering both storage modes, resetting legacy plaintext, and replaying moves when anchors disappear.
230 component tests passed before the final helper change. The component tests were not rerun after restoring the unprotected option; all production callers still explicitly select protected storage.
The reason will be displayed to describe this comment to others. Learn more.
🟢 Approval recommended
No active review issues remain for the move-based dashboard ordering changes.
No open issues 🎉
What changed in this PR
This PR makes dashboard resource ordering independent of discovery timing by replaying explicit user moves over the default sort order, rather than saving full-list positions.
Changes:
Places late resources and groups in their default sort order while preserving resource hierarchy.
Saves resource moves and per-grouping-mode group moves separately in browser local storage, using neighboring items as anchors. Previous full-list orders are not migrated.
Updates model tests, component tests, and documentation for the new ordering behavior.
James Newton-King (JamesNK)
changed the title
Preserve dashboard resource order with relative moves
Keep dashboard resource ordering stable and protect saved customizations
Nov 20, 2026
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
The 50-move cap can still produce protected settings exceeding SignalR’s 32 KiB receive limit with maximum-length Unicode tags, causing local-storage reads to disconnect the dashboard even after reload.
No open issues 🎉
1 previously missed issue
In code that hasn't changed since last review
Cap protected group settings to SignalR’s payload limit
The 50-move cap still allows a protected group setting to exceed SignalR's 32 KiB default receive limit (upstream default-branch source): 50 moves with maximum-length CJK tag keys and anchors exceed that limit even without JSON escaping or protection overhead. Saving can succeed, but the next local-storage read sends the oversized value back over SignalR and can disconnect the dashboard, including after reload. Enforce a serialized/protected size budget or split the payload, and extend the payload-size regression test to maximum-length Unicode tags.
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
Human assessment is needed because entry-count caps do not bound protected payload size, allowing long-name or Unicode data to exceed SignalR’s message limit and disconnect the dashboard.
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
Human assessment is needed because the move and pin caps can still allow protected payloads exceeding SignalR’s 32 KiB limit, potentially disconnecting the dashboard on storage reads or reloads.
…e save
Leave the displayed value unchanged on save failure and tell the user to retry. Keep cross-tab edits by reading storage before each save.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Adopt defaults when the saved value is missing or invalid without rewriting storage. Preserve the current value when storage cannot be read.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Allow larger protected browser preferences to round-trip through the Blazor hub without changing the saved item caps.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The reason will be displayed to describe this comment to others. Learn more.
🟡 Changes recommended
Sibling-only key validation lets moves replay against the wrong resource when keys repeat across parents, reporting success without changing the displayed order.
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
The sibling-only persistent-key ambiguity check can allow a move to report success while replay selects an old row under a different parent and leaves the replacement unmoved.
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
Human assessment is needed because unpublished findings identify ordering risks in move compaction after anchor removal and ambiguous replay when replicas share persistent keys.
Updated dashboard/explore.mdx (stable default ordering, only explicit drags saved) and dashboard/data-persistence.mdx (browser settings now protected, legacy plaintext not migrated). Signals: pr_body_has_user_facing_section (the "User-facing usage" section), pr_body_has_deprecation_marker (the TODO about clearing obsolete pins), new_public_type (MetricPinButton.razor.cs), pr_body_has_cli_flag_mention (the test commands, likely a false positive).
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
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.
Description
The dashboard resource pane could show a different order depending on when it was opened. Resources discovered after the first snapshot were appended, and the browser saved that order even if the user had never moved anything.
User-facing usage
With Grouping = None, if
frontendandworkerare already visible andproxy(a project) andredis(a container) are discovered later, the pane showsredis,frontend,proxy,workerrather than appending the new rows. You can still drag a resource to reorder it among its siblings without freezing the rest of the list.Previously saved full-list orders, plaintext tags, and plaintext pins are not migrated. The dashboard starts with default ordering and no saved personal tags or pins. The next tag or pin edit replaces the corresponding plaintext value with a protected value. If the dashboard can no longer decrypt a saved value, that setting also returns to its default.
TODO (if users report hitting these limits): Add a way to clear obsolete metric pins and inaccessible personal tag assignments from the dashboard. Pins without matching telemetry and assignments for removed resources or tags now declared by the AppHost still count toward their respective limits. The dashboard currently cannot clear those entries.
Screenshots / Recordings
TODO: Record the resource pane during discovery with Grouping = None to show late rows moving into their default positions. Then reorder a resource and reload to show that the move persists.
Security considerations
The dashboard uses its existing ASP.NET Core Data Protection keys to protect these values. It does not fall back to plaintext or create new plaintext backups. Existing plaintext entries and backups are not proactively removed. Protection applies to values, not the browser storage key names.
Validation
Test commands
Final model run (43 passed):
Earlier component run (230 passed):
Fixes # (issue)
Checklist
<remarks />and<code />elements on your triple slash comments?