-
Notifications
You must be signed in to change notification settings - Fork 14
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
Modify poll details page #46
Conversation
- Clicking a poll from home page goes to /:id/results - After creating a poll you go to /:id/cast - Poll URL updated to remove /poll aspect
- Selected poll and its votes now saved in store - Began splitting Poll Details page into reusable components
- Moved calculations for vote states into a getter function - Small bug fixes for better handling before data loads
- Add message stating number of valid events - Add "learn more" expansion item to show event details - Expansion item shows clickable event cards
- If poll is ongoing, there is now a button to cast your vote - If poll is ovr, there is a message stating this
- Update message showing weighted vote - Add radio buttons for selecting options - Enable user to select option and place vote - Redirect to results page after voting - TODO: Update vote counts after placing vote
- Remove stray period and stray space - Make poll options slightly darker - Add page titles to help distinguish cast and result pages - Add validation that user is logged in on cast page. If user is not logged in, token count and weighing is not shown - Add page titles that show up in browser tab bar - Various font, spacing, and CSS changes
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 looking great! There were a lot of moving parts on this one and most everything is looking and working really well. Nice!
A few things I noticed during testing:
- When the poll is created, I think the user should be re-directed to the results page, not the cast page. Sorry, I think this was my fault for not answering your question on the GitHub issue.
- I really like the expanding UI element at the bottom of the results page. I think we should put the "PLACE YOUR VOTE" button inside that expanded section, though, so it's only visible if the user expands it. What do you think?
- When clicking on that "PLACE YOUR VOTE" button, the page updates so fast (which is good!) and the UI is basically the same at the top half of the screen, it sometimes feels like something has just been expanded or something by clicking the button, as opposed to feeling like you've navigated to new page. I'm wondering if there is some way to disambiguate the look/feel of the pages a bit more, beyond just the header at the top. Any thoughts? If we can't think of anything obvious, we can tackle in a different issue.
- Somehow, I sometimes see this "VIEW CURRENT RESULTS" button inside the Valid Events expansion on the results page. I don't know what caused it, but it started appearing when it previously wasn't as I was playing with the UI.
- After poll creation, redirect user to results page (not cast page) - Fix bug that showed "View Results" button on "Results" page
Fixed in last commit. I edited the comment a minute or so after I posted it so that's probably what happened.
My only concern here is that I think it becomes a little harder to figure out how to vote. For example perhaps I don't care what event tokens are required (because maybe I don't realize that I should care), and then I never see a vote button. Maybe if we change the dropdown to "Click to learn more and vote" that would mitigate my concern of having the button contained within the expansion item. What do you think of that?
Just some background on this: Previously we'd send a request to our API to get poll data every time the poll details screen loaded. After this split into 2 pages, that means we'd do it once when first loading the results page and again when loading the cast page. With this original layout, you have a redundant call to the API, but it did feel more clear they were two different pages because of that delay when loading. In an effort to improve the UX, I added some logic to remove the second API call when redundant, then added those small "Poll Results" and "Cast Your Vote" headers to try to make it feel more like loading a separate page. But I agree it's still not very clear. Two ideas that come to mind:
Ah right, I meant to fix that bug but it slipped by. Fixed in last commit |
I agree, let's start with this.
Yup, makes sense. Let's do it. |
- Move "Place Your Vote" button within events expansion item on the Results page - Remove vote stats from the Cast page
Made both changes in the last commit. Removing the vote percentages from within the options had the side effect of shrinking the height of each option, which I think was good to help distinguish it a bit more. Let me know if there's anything else we should change on this branch |
Awesome! Everything looking/working great.
Yes, this actually helped a ton! |
Closes #38
See #38 (comment) for specifics on what changes.
I also added in page titles that should display in the tab par (per #39) so let me know what you think of those.
Let me know your thoughts on everything—it's a lot of changes, so I'm sure there's a few small bugs or CSS improvements that can be made. I'm going to take another look in the morning to look for bugs/UI improvements