-
Notifications
You must be signed in to change notification settings - Fork 60
Bugfix: Registering delegate doesn't update UI - Closes #682 #688
Conversation
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.
we don't need delegateRegistration
middleware. you can simply call getDelegate
in account
middleware.
@@ -6,7 +6,7 @@ const Address = (props) => { | |||
const title = props.isDelegate ? 'Delegate' : 'Address'; | |||
const content = props.isDelegate ? | |||
(<div> | |||
<p className="inner primary"> | |||
<p className="inner primary delegate-name"> |
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.
please remove delegate-name
class and use an ID instead of that. when we want to select a an element in js , it is better to use ID.
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 added this class for e2e tests. All e2e tests use classes for selectors. It is not possible to change just this one. We can discuss if we should change classes to IDs in e2e tests, but it is definitely outside the scope of this PR.
@@ -0,0 +1,7 @@ | |||
export default { |
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.
we’re creating src/constants/transactionTypes.js
when there are some other places to use this but you only uses this in one file.So, we don't need this constant.
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 use it in three files:
src/components/transactions/amount.js
src/store/middlewares/delegateRegistration.js
src/store/middlewares/delegateRegistration.test.js
Closes #682