New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add copy-to-clipboard button to the build console output #8960
Conversation
Yay, your first pull request towards Jenkins core was created successfully! Thank you so much! |
Thanks for the pull request @anhcraft . When you performed the testing, did you confirm that the copied text was inserted into the clipboard? When I've tested these types of pull requests in the past, I needed to use an HTTPS URL to check that the correct text was placed on the clipboard. |
It should be a secure context, which is localhost or https url |
It worked for me when running locally. My PR does not change the secure-context check at all. |
Would it be possible to put the copy button in the top right corner of the logs like it's done on GitHub amongst others? Having it alongside titles gives the false impression that's their content which will be copied, it's not obvious at first look these buttons concern the logs block below.
|
I think that is a reasonable request for another pull request, since the placement that @anhcraft has selected is consistent with the placement of other copy buttons in Jenkins. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
Co-authored-by: Alexander Brandes <brandes.alexander@web.de>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/label ready-for-merge
This PR is now ready for merge, after ~24 hours, we will merge it if there's no negative feedback.
Thanks!
Congratulations on getting your very first Jenkins core pull request merged 🎉🥳 |
text
. Therefore, this PR also introduces another parameterref
to refer to the target element using the id. Compared to thetext
approach, it has some advantages: reduces page size, supports formatted logging output and can work across UI components.Testing done
Manually testing
Before:
After:
Proposed changelog entries
Submitter checklist
Tasks
@Restricted
or have@since TODO
Javadocs, as appropriate.@Deprecated(since = "TODO")
or@Deprecated(forRemoval = true, since = "TODO")
, if applicable.eval
to ease future introduction of Content Security Policy (CSP) directives (see documentation).Desired reviewers
@jenkinsci/core-pr-reviewers
Before the changes are marked as
ready-for-merge
:Maintainer checklist
Tasks
upgrade-guide-needed
label is set and there is a Proposed upgrade guidelines section in the pull request title (see example).lts-candidate
to be considered (see query).