fix(toolbar): anchor the connection and refresh actions at the leading edge#1544
fix(toolbar): anchor the connection and refresh actions at the leading edge#1544datlechin wants to merge 1 commit into
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 2efe010a44
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| .sidebarTrackingSeparator, | ||
| Self.connectionGroup, | ||
| Self.refreshSaveGroup, | ||
| .flexibleSpace, |
There was a problem hiding this comment.
Migrate saved toolbar layouts too
When a user already has an autosaved toolbar configuration from the prior build, this default-only spacer insertion will not repair that restored item list because autosavesConfiguration is enabled in init. In that scenario the saved ordering still lacks the spacer before principal, so the connection/refresh actions remain attached to the centered chip; consider migrating/resetting only the buggy saved ordering or versioning the toolbar identifier so affected profiles receive the new spacer.
Useful? React with 👍 / 👎.
Follow-up to #1543 / #1479.
Problem
After centering the connection chip with
centeredItemIdentifiers, the connection and refresh/save buttons clustered in the middle next to the chip instead of sitting at the leading edge, leaving the area after the window title empty.Cause
connectionGroupandrefreshSaveGroupwere contiguous withprincipal(no space between them and the centered item). WhencenteredItemIdentifierscentersprincipal, items directly adjacent to it with noflexibleSpaceseparator are drawn attached to the centered chip, so they rode into the center.Fix
Restore a
flexibleSpacebetweenrefreshSaveGroupandprincipal, so there is a flexible space on both sides of the chip:The two flexible spaces separate the three zones;
centeredItemIdentifiers = [principal]still does the actual centering, so it stays robust against the visible window title. Result: connection/refresh/save anchored left, chip centered, view actions right.