-
Notifications
You must be signed in to change notification settings - Fork 621
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
feat: fix toolbar on narrow screens #1754
Conversation
Codecov ReportBase: 65.84% // Head: 66.38% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## main #1754 +/- ##
==========================================
+ Coverage 65.84% 66.38% +0.55%
==========================================
Files 170 170
Lines 5561 5550 -11
Branches 1258 1255 -3
==========================================
+ Hits 3661 3684 +23
+ Misses 1890 1857 -33
+ Partials 10 9 -1
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
size-limit report 📦
|
/create-server |
@@ -33,8 +42,8 @@ export const TOOLBAR_MODE_WIDTH_THRESHOLD = 900; | |||
|
|||
export type ShowModeType = ReturnType<typeof useSizeMode>; | |||
|
|||
export const useSizeMode = (target: React.RefObject<HTMLDivElement>) => { | |||
const [size, setSize] = React.useState<'large' | 'small'>('large'); | |||
export const useSizeMode = (target: RefObject<HTMLDivElement>) => { |
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.
also guys what do you think about this: if we have this "more" button functionality we can go towards removing size
logic, where we have
toolbars depending on width and just show large option with additional "more" button (3dot) ?
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 agree, that simplifies a lot!
/create-server |
/create-server |
/create-server |
/create-server |
Screen.Recording.2022-11-28.at.17.32.22.mov |
Looks great so far! dropdown gets hidden beneath the flamegraph: Screen.Recording.2022-11-28.at.12.01.03.PM.mov |
Also we currently drop groups starting on the right and moving to the left ... How hard would it be to reverse that so that the first items that disappear are the items on the left (i.e. head-first / tail first would disappear first) |
/create-server |
Screen.Recording.2022-11-29.at.13.37.01.mov |
/create-server |
/create-server |
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.
love it! Thanks @dogfrogfog
Brief
Changes