-
Notifications
You must be signed in to change notification settings - Fork 5k
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
UX: Multichain: Address Copy Button #18153
Conversation
CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes. |
9dd50f6
to
db53a0b
Compare
d1422df
to
d1e1ec0
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.
Looking great. Just need to update the handler
86c7200
to
f6d5796
Compare
Builds ready [2e1e9ec]
Page Load Metrics (1622 ± 41 ms)
Bundle size diffs
|
Codecov Report
@@ Coverage Diff @@
## develop #18153 +/- ##
===========================================
+ Coverage 64.51% 64.52% +0.01%
===========================================
Files 914 915 +1
Lines 35329 35343 +14
Branches 9072 9079 +7
===========================================
+ Hits 22791 22802 +11
- Misses 12538 12541 +3
... and 1 file with indirect coverage changes Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
fa2b3d6
to
2689344
Compare
Builds ready [2689344]
Page Load Metrics (1368 ± 20 ms)
Bundle size diffs
|
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.
Fantastic work. Left one small suggestion
Builds ready [d2a452a]
Page Load Metrics (1722 ± 81 ms)
Bundle size diffs
|
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.
LGTM!
d2a452a
to
5f76dda
Compare
Builds ready [5f76dda]
Page Load Metrics (1635 ± 114 ms)
Bundle size diffs
|
Builds ready [f825147]
Page Load Metrics (1728 ± 44 ms)
Bundle size diffs
|
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.
Left one question that needs @garrettbear's attention
@@ -78,7 +78,7 @@ $text-variants: ( | |||
|
|||
@each $overflow in $overflow-wrap { | |||
&--overflow-wrap-#{$overflow} { | |||
overflow-wrap: $overflow; | |||
word-break: $overflow; |
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.
The property values of $overflow-wrap
don't all work with word-break? e.g. anywhere
$overflow-wrap: normal, break-word, anywhere; |
https://developer.mozilla.org/en-US/docs/Web/CSS/word-break
Do we need to create a wordbreak scss variable? cc @garrettbear
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.
This got reverted, so all good for now. BUT it did expose that we need a word-break
option since you can see in this PR that the overflow-wrap
won't work.
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.
Sweet created an issue. Can you fill in the deets? #18354
ui/components/multichain/address-copy-button/address-copy-button.js
Outdated
Show resolved
Hide resolved
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.
Left some more comments
paddingRight={3} | ||
paddingLeft={3} | ||
size={Size.SM} | ||
className="multichain-address-copy-button" |
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.
Previously if wrap
was true
you set the height to auto
which I think made sense? It would help it degrade gracefully we would end up with a bubble button but at least the text wouldn't be out side the button?
So instead of this(I know I've made the address ridiculously long)
But I guess that's a design decision? cc @SaraCheikh @Akatori-Design
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.
If it breaks it should gracefuly break, so yea I think we should keep the text in the button,
f825147
to
5462848
Compare
Builds ready [5462848]
Page Load Metrics (1817 ± 71 ms)
Bundle size diffs
|
Builds ready [04d1d5b]
Page Load Metrics (1839 ± 68 ms)
Bundle size diffs
|
Here are my suggestions to clean this up and took into consideration of @georgewrmarshall comments as well
|
* multichain copy button updates * Update ui/components/multichain/address-copy-button/index.scss Co-authored-by: George Marshall <[email protected]> --------- Co-authored-by: George Marshall <[email protected]>
Builds ready [c4e71b3]
Page Load Metrics (1595 ± 36 ms)
Bundle size diffs
|
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.
LGTM with one question for design
ui/components/multichain/address-copy-button/address-copy-button.js
Outdated
Show resolved
Hide resolved
…on.js Co-authored-by: George Marshall <[email protected]>
Builds ready [bd923fa]
Page Load Metrics (1553 ± 56 ms)
Bundle size diffs
|
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.
LGTM!
Explanation
Provides the new copy button component for use around the extension.
Fixes: https://github.com/MetaMask/MetaMask-planning/issues/375
Screenshots/Screencaps
Manual Testing Steps
Pre-merge author checklist
Pre-merge reviewer checklist
If further QA is required (e.g. new feature, complex testing steps, large refactor), add the
Extension QA Board
label.In this case, a QA Engineer approval will be be required.