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

fix: styles update #2126

Merged
merged 3 commits into from
Jul 3, 2024
Merged

Conversation

joanna-pagepro
Copy link
Contributor

@joanna-pagepro joanna-pagepro commented Apr 3, 2024

Description

There are a number of UI issues occurring across various motion widgets for all responsive sizing including desktop and mobile. These issues should be resolved to ensure they match Figma SOT and create a consistent and strong level of UX across the CDapp.

The issues should be tested and resolved across all responsive sizes unless stated.

Testing

  • Make any action using reputation method and go through steps

Resolves #2062

@CzarekDryl CzarekDryl marked this pull request as ready for review April 5, 2024 10:16
@CzarekDryl CzarekDryl requested review from a team as code owners April 5, 2024 10:16
rdig
rdig previously requested changes Apr 5, 2024
Copy link
Member

@rdig rdig left a comment

Choose a reason for hiding this comment

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

I'm good with the style / logic changes here, with the exception of the Tooltip component which really needs to be refactored, as we keep putting more and more props in it, and it's really not sustainable at this point.

@@ -11,6 +11,7 @@ const displayName = 'Extensions.Tooltip';
const Tooltip: FC<PropsWithChildren<TooltipProps>> = ({
children,
tooltipContent,
tooltipStyle,
Copy link
Member

Choose a reason for hiding this comment

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

This is not the right approach here, as we are already passing in a className prop, that just sets classes on the wrapper. Plus we have isSuccess and isFullWidthContent which are just switches for yet more styles

The solution here is to refactor Tooltip to accept either themes, or the className prop to be more configurable and account for all the places we need to customize styles.

Otherwise, we'll just end up jamming in various props when we need to customize more things (like the arrow color for example)

Copy link
Contributor

Choose a reason for hiding this comment

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

I couldn't make it work using className, it had to be done by styles.

Copy link

@melyndav melyndav left a comment

Choose a reason for hiding this comment

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

Hey @joanna-pagepro - thanks for picking up my issue and great work so far.

A couple of pickups.

  1. The Voting widget has empty space at the top
image
  1. The percentage font is wrong in the outcome widget - see Figma below.
image

it's also impacting this component globally as you can see the dashboard font has also changed in the percentage bar -

image
  1. The gray background of the percentage bar is wrong across all widgets
image

What it should be from Figma:
image

  1. There is added spacing in some widgets but not in others between the value and the % symbol.
    Currently:
image

As per Figma:
image

image
  1. In the case where there are little users showing in the outcome widget, can we fill the empty space with the progress bar.

So currently, there is extra space to the right of the avatar
image

However, in Figma the avatars sit on the right and the progress bar fills the space.
image

Link to example: https://www.figma.com/file/l1dOM5qiQYwF0ElvKDqqjg/Design-System---Colony-v3?type=design&node-id=3134-9308&mode=design&t=fui5vBndDT4Ds1kj-4

Copy link
Contributor

@ArmandoGraterol ArmandoGraterol left a comment

Choose a reason for hiding this comment

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

Thank you for the changes! Left a small comment regarding the code, plus I still see that some of Mel's issues are still alive and kicking. Dunno if they are being handled separately.

Copy link

@melyndav melyndav left a comment

Choose a reason for hiding this comment

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

Hey @joanna-pagepro / @CzarekDryl,

Thanks for working on my feedback.

To clarify, there are needs to be two variations of the progress bar component with different % font sizes.

  1. Uses the extra small font and is featured at the top of motion widgets. Marked in green.

  2. Uses the small font and is used globally outside of motions in places like the dashboard objective widgets and in the main content of the motion widgets.

image

Currently, these keep being changed back and forth because when a change is requested when they need different fonts to match the context and placement.

This needs to be resolved across the top of all motion widgets where the percentage, vote numbers, reveal numbers etc is shown etc.

  1. There is a padding issue above the main CTA inside the vote widget once a vote has been placed.
image

@CzarekDryl CzarekDryl force-pushed the fix/15840824-various-widget-ui-issues branch from eedc0f6 to b1b53b6 Compare April 10, 2024 12:58
@CzarekDryl
Copy link
Contributor

@ArmandoGraterol @melyndav Now everything should be fine

Copy link
Contributor

@ArmandoGraterol ArmandoGraterol left a comment

Choose a reason for hiding this comment

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

Looks good to me 👌 Thank you for the changes!

Copy link

@melyndav melyndav left a comment

Choose a reason for hiding this comment

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

Hey @CzarekDryl thanks for the further changes. Everything is looking correct now with the % font sizes.

However, the issue in the voting widget has popped up again, with extra space showing at the top of the widget.

image

@CzarekDryl
Copy link
Contributor

@melyndav Margin fixed

Copy link

@melyndav melyndav left a comment

Choose a reason for hiding this comment

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

Hey @CzarekDryl thanks again for fixing the issues.

  1. On mobile, all progress bars in the top information section should be full width of th widget and not match the text.

Here below, the progress bar/voting numbers in the reveal step isn't full width.

image

But in the voting widget in the previous step is full width
image

  1. On mobile, the team reputation percentage data doesn't show in the widget
image

On the desktop version you data see it visible
image

  1. On mobile again, when I confirmed the reveal stage it moved to the finalise step, but the top navigation doesn't move along with it to show the active step.
image

@CzarekDryl
Copy link
Contributor

@melyndav Please check it once again :)

@rdig rdig dismissed their stale review April 25, 2024 18:54

stale

Copy link
Contributor

@ArmandoGraterol ArmandoGraterol left a comment

Choose a reason for hiding this comment

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

Looking good! I've noticed the issues Sam and Mel pointed out are fixed for me. Thank you for the changes

Comment on lines +72 to +79
if (!inView) {
setHiddenItem(name);
} else {
setHiddenItem(undefined);
}
Copy link
Contributor

Choose a reason for hiding this comment

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

Nitpick but we could make this simpler by doing this: setHiddenItem(!inView ? name : undefined)

Copy link
Contributor

@iamsamgibbs iamsamgibbs left a comment

Choose a reason for hiding this comment

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

Thanks for the updates on this.

Timer padding is looking better on both mobile and desktop.

Screenshot 2024-04-26 at 15 21 01

And tooltips on mobile are working fine too:

Screenshot 2024-04-26 at 15 21 11

Only one final issue I can find. On certain breakpoints, when you reveal your vote, the 'finalize' pill won't be visible and nor will the arrows to scroll to it. If the 'active' pill is out of view, it should automatically scroll to that pill when that step becomes active.

Screen.Recording.2024-04-26.at.15.26.22.mov

@CzarekDryl CzarekDryl force-pushed the fix/15840824-various-widget-ui-issues branch 2 times, most recently from cfa5fab to 6767240 Compare May 7, 2024 12:29
@CzarekDryl
Copy link
Contributor

@iamsamgibbs I can't reproduce this bug with no arrows on mobile.
image
image

@iamsamgibbs
Copy link
Contributor

@iamsamgibbs I can't reproduce this bug with no arrows on mobile.

I think it specifically happens when revealing your vote as the additional pill for supported / rejected gets added.

@CzarekDryl CzarekDryl force-pushed the fix/15840824-various-widget-ui-issues branch from 6767240 to 862106d Compare May 27, 2024 08:28
@CzarekDryl CzarekDryl requested a review from a team as a code owner May 27, 2024 08:28
@CzarekDryl
Copy link
Contributor

@iamsamgibbs This should be fixed now.

@CzarekDryl CzarekDryl requested a review from iamsamgibbs May 27, 2024 10:13
iamsamgibbs
iamsamgibbs previously approved these changes May 29, 2024
Copy link
Contributor

@iamsamgibbs iamsamgibbs left a comment

Choose a reason for hiding this comment

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

This looks good to me now! Thanks for the fix!

Screen.Recording.2024-05-29.at.19.36.49.mov

@CzarekDryl CzarekDryl force-pushed the fix/15840824-various-widget-ui-issues branch from 9eea0e7 to b0b5194 Compare June 11, 2024 10:41
@CzarekDryl CzarekDryl force-pushed the fix/15840824-various-widget-ui-issues branch from b0b5194 to b67918d Compare June 27, 2024 07:03
iamsamgibbs
iamsamgibbs previously approved these changes Jun 27, 2024
Copy link
Contributor

@iamsamgibbs iamsamgibbs left a comment

Choose a reason for hiding this comment

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

Still looks good to me, hopefully this can get merged soon!

Screenshot 2024-06-27 at 11 10 23 Screenshot 2024-06-27 at 11 10 43

Copy link
Contributor

@bassgeta bassgeta left a comment

Choose a reason for hiding this comment

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

Almost there! Looking good, just noticed some things than can be improved.
When these are resolved, I think we are good to go!

Copy link
Contributor

@bassgeta bassgeta left a comment

Choose a reason for hiding this comment

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

Thank you for the changes, code looks good to me, styles too, nice work on this PR, now 🤞 we get it over the finish line!

Copy link
Contributor

@iamsamgibbs iamsamgibbs left a comment

Choose a reason for hiding this comment

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

Still looking good!

Screenshot 2024-07-02 at 16 23 41 Screenshot 2024-07-02 at 16 24 16 Screenshot 2024-07-02 at 16 24 44 Screenshot 2024-07-02 at 16 25 12

Copy link

@melyndav melyndav left a comment

Choose a reason for hiding this comment

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

@CzarekDryl this one is a good to go from my end!! I do not see any more issues. I know this had been a very long process, but great work throughout it! 💯

@CzarekDryl CzarekDryl merged commit 4256fb6 into master Jul 3, 2024
4 of 6 checks passed
@CzarekDryl CzarekDryl deleted the fix/15840824-various-widget-ui-issues branch July 3, 2024 13:45
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.

Motions: Various widget UI issues
7 participants