-
Notifications
You must be signed in to change notification settings - Fork 208
feat: CopyToClipboard - Allow separate content from text to copy for inline variant #3400
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
Conversation
e67bbb7 to
82f3b9c
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #3400 +/- ##
=======================================
Coverage 96.51% 96.51%
=======================================
Files 806 806
Lines 23028 23031 +3
Branches 7550 7551 +1
=======================================
+ Hits 22226 22229 +3
Misses 795 795
Partials 7 7 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
37c99e8 to
b08758b
Compare
b08758b to
107fd26
Compare
107fd26 to
4f60f84
Compare
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.
I believe this is such a large diff because of this change: #3413
3bc12c7 to
14ad304
Compare
Description
Original customer ask:
Customer usecase:
Main problem:
With any custom implementation, i.e. combining
SpaceBetweenusing thevariant="icon"and a string, it will result in a grey icon, this is particularly a problem when used in conjunction with regular inlineCopyToClipboardwhich has a blue icon like inside aSplitPanelwithKeyValuePairs.Solution:
Adds a new property:
textToDisplaywhich allows for specifying a separate display value from the copy value forvariant="inline".This is achieved by assigning a
stringtotextToDisplayand a separatestringtotextToCopy.If
contenthas no value thentextToCopywill be displayed instead.Related links, issue #, if available: n/a
AWSUI-4543465TZAG3kNuqEHow has this been tested?
Review checklist
The following items are to be evaluated by the author(s) and the reviewer(s).
Correctness
CONTRIBUTING.md.CONTRIBUTING.md.Security
checkSafeUrlfunction.Testing
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.