-
Notifications
You must be signed in to change notification settings - Fork 136
Conversation
cadd093
to
f6afb83
Compare
@@ -22,6 +22,8 @@ export interface Props { | |||
id?: string | |||
disabled?: boolean | |||
icon?: {image: React.ReactNode, position: 'before' | 'after'} | |||
beforeIcon?: React.ReactNode, |
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.
does the existing code not work for your case? in icon
object you already have before
and after
options
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 need both before
and after
at the same time, which is why I changed this.
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.
could we use existing icon object to achieve this and just extend it? I would like to avoid duplicating props.
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 couldn't think of a good way to extend the current icon
prop to work for two different icons, so I thought this would be the cleanest solution. But if you have a good idea for how to do it inside icon
that totally works.
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.
cc @petemill for his thoughts
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 might need some design decision to clarify the change to the button in the system - @rossmoody? I'm not sure it's easily understandable for the user to grasp the meaning of the button when there are 2 icons.
If it isn't a button, but is some kind of 'status chip' then let's make a new component called that. It could for example have a prop which determines which icon is displayed called status
which accepts 'success' / 'fail' / 'info'
...looking at it again, it really doesn't feel like it should be a button to me, since it doesn't perform an action. Instead it conveys information, and expands to show more detailed information (currently on click but may want to be on hover 1 day)
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 is the first I'm seeing this and sadly I really don't have any insight as to how this works or what function it serves. @jenn-rhim will need to chime in on details surrounding this.
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 is not the approved design. We removed this state. @NejcZdovc
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.
@petemill @rossmoody @jenn-rhim so even though that button provided above was not needed we still need it for this one:
647aaac
to
e296a0a
Compare
<StyledIcon> | ||
<UpholdColorIcon /> | ||
</StyledIcon> | ||
{'@' + username} |
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.
Let's maybe do a quick check for username.length
so we don't potentially display just an @
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 username.length === 0
what should we do? We probably shouldn't be showing the box at all in this case
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.
Actually we do this check in WalletWrapper
, which will only display the box if username
is truthy. and ''
is falsy.
<StyledLink onClick={onVerifyClick}> | ||
{getLocale('walletVerifyLink')} | ||
</StyledLink> | ||
{' '} |
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.
Is this for stylistic purposes? Can we maybe accomplish this via CSS if so?
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.
It's not really for stylistic purposes, there should just be a space between the link and the rest of the test and the space will get eaten up by JSX otherwise.
id | ||
} = this.props | ||
|
||
return ( |
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.
Could we break this up in to a couple more methods? Maybe one for footer
and header
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.
done
e296a0a
to
0349d9c
Compare
let's not merge until core PR is ready |
68f5530
to
0861a67
Compare
Removed "Connected" state and rebased everything, ready for re-review. |
e2fd307
to
8ead10e
Compare
76d1def
to
cf1e3f5
Compare
cf1e3f5
to
2c9dd48
Compare
26781b6
to
70b9b73
Compare
8ad5ec1
to
ba27198
Compare
6ac97c2
to
f854347
Compare
f854347
to
5875725
Compare
Modified-by: Christopher Cooper <ccooper@brave.com>
5875725
to
bc1f653
Compare
Changes
Adds UI components (button at top, footer updates, verification panel screen) to indicate uphold wallet status.
See brave/brave-browser#4774.
Test plan
Link / storybook path to visual changes
Integration
Does this contain changes to src/components or src/
Does this contain changes to src/features for brave-core?