Skip to content
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

Open
wants to merge 22 commits into
base: master
Choose a base branch
from
Open

Enhance/votestatusbuttons #86

wants to merge 22 commits into from

Conversation

jex441
Copy link

@jex441 jex441 commented Oct 19, 2023

No description provided.

totalYesVotes >= totalNoVotes ? '#4AA0D5' : '#4AA0D5',
'Vote' + '%'
],
open: [totalYesVotes >= totalNoVotes ? '#4AA0D5' : '#4AA0D5', 'Vote'],
Copy link
Author

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'],
Copy link
Author

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);
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No console logs

const yesWidth = yesPercent * 100 * difference;
const noWidth = noPercent * 100 * difference;
const remainingVotesPercent = 100 - (yesWidth + noWidth);
const yesRoundedCorners = remainingVotesPercent > 0 ? '0px' : '0px 2px 2px 0px';
Copy link
Author

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?

@jex441
Copy link
Author

jex441 commented Oct 24, 2023

Please make a pull request to turbo-src with these changes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants