-
Notifications
You must be signed in to change notification settings - Fork 4
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
Enhance/votestatusbuttons #86
base: master
Are you sure you want to change the base?
Conversation
totalYesVotes >= totalNoVotes ? '#4AA0D5' : '#4AA0D5', | ||
'Vote' + '%' | ||
], | ||
open: [totalYesVotes >= totalNoVotes ? '#4AA0D5' : '#4AA0D5', 'Vote'], |
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.
Not sure why there is a ternary operator when both hexes are the same
'Vote' + '%' | ||
], | ||
open: [totalYesVotes >= totalNoVotes ? '#4AA0D5' : '#4AA0D5', 'Vote'], | ||
frozen: [totalYesVotes >= totalNoVotes ? '#919190' : '#919190', 'Vote'], |
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.
Again
const buttonText = buttonStyle[prData.state][1]; | ||
setVoteStatusButton({ color: buttonColor, text: buttonText }); | ||
} | ||
console.log(prData); |
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.
No console logs
src/Components/DOM/ButtonProgress.js
Outdated
const yesWidth = yesPercent * 100 * difference; | ||
const noWidth = noPercent * 100 * difference; | ||
const remainingVotesPercent = 100 - (yesWidth + noWidth); | ||
const yesRoundedCorners = remainingVotesPercent > 0 ? '0px' : '0px 2px 2px 0px'; |
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.
Can this be achieved by having the div nth-child(first) and div nth-child(last) of the VoteBar have rounded corners on the left or the right respectively?
Please make a pull request to turbo-src with these changes |
No description provided.