feature: allow copying ref names from commit info panel#2321
Open
ivnnv wants to merge 1 commit intosourcegit-scm:developfrom
Open
feature: allow copying ref names from commit info panel#2321ivnnv wants to merge 1 commit intosourcegit-scm:developfrom
ivnnv wants to merge 1 commit intosourcegit-scm:developfrom
Conversation
Adds a small copy button next to each ref pill in the commit info panel. Clicking it copies the ref name (e.g. "main", "origin/feature") to the clipboard, matching the existing copy affordance on the SHA row. CommitRefsPresenter gains an optional Decorator styled property. When set, the presenter renders that single decorator instead of iterating DataContext.Decorators. The existing multi-decorator path is unchanged, so the Histories grid still renders refs the same way it did before. CommitBaseInfo's REFS row, previously a single CommitRefsPresenter rendering all decorators in one custom-drawn run, is now an ItemsControl over Decorators where each item is a single-decorator presenter plus a copy Button. The Button picks up Avalonia's standard tooltip and hover styling. Wrap now happens between pill+button groups instead of inside one continuous presenter. Pill geometry, icons, fills and outlines are unchanged. The Histories grid is intentionally untouched.
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.
Adds a small copy button next to each ref pill in the commit info panel. Clicking it copies the ref name (e.g.
main,origin/feature) to the clipboard, matching the existing copy affordance on the SHA row.The Histories grid is intentionally untouched (copy buttons there would clutter the dense rows). One side effect to flag: wrap in the REFS row now happens between
[pill+button]groups instead of inside one continuous presenter, which is the natural behavior for anItemsControl+WrapPanellayout.Test plan