-
Notifications
You must be signed in to change notification settings - Fork 49.6k
[DevTools] Larger panel buttons and center #34619
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
Conversation
| }; | ||
|
|
||
| const panelIcons = '0 -960 960 820'; | ||
| const panelIcons = '96 -864 768 768'; |
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.
The AI model I used told me 144 -816 672 672 is the viewbox that fits the path perfectly which I used in #34517.
The original viewbox was directly from the Material icons which didn't fit the path perfectly so it became off-center depending on the font size.
Did you check the alignment when increasing/decreasing base browser font size via settings?
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.
Yea. Seems fine. The font size doesn't matter. Doesn't change. That's up to the button to align itself. If the button comes out of alignment then that's a different issue.
But I mean alignment of the rest of the row is messed up because things like the checkboxes should be buttons etc.
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.
Yea. Seems fine. The font size doesn't matter. Doesn't change. That's up to the button to align itself. If the button comes out of alignment then that's a different issue.
Well, it does matter if the path is not centered in viewbox. But seems like it still is.
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.
Yea I'm not sure where the 820 box came from because all the materialize design ones have a 960 height for the 24px versions which puts them center:
Then I just applied equal sizing to make it a little larger while still always fitting in our viewbox. Seems to work well for all of them.
Really it's weird that we use 24px basis icons and then resize them to 16px. We should probably use 16px basis icon to begin with or maybe use 24px icons everywhere without having to scale them and fix the padding of the buttons instead.
The panel icons are quite small. Especially compared to the equivalent buttons elsewhere in Chrome DevTools that otherwise use the same icons. This makes them a little bigger to make them similar size to our other button icons. They were also a bit off center. This centers them as well. Before: <img width="409" height="426" alt="Screenshot 2025-09-26 at 4 23 15 PM" src="https://github.com/user-attachments/assets/4a5de032-e316-44ed-9424-8bccce00f0cd" /> After: <img width="519" height="388" alt="Screenshot 2025-09-26 at 4 22 57 PM" src="https://github.com/user-attachments/assets/1763e522-5683-4fac-a913-27910a30a039" />
The panel icons are quite small. Especially compared to the equivalent buttons elsewhere in Chrome DevTools that otherwise use the same icons. This makes them a little bigger to make them similar size to our other button icons.
They were also a bit off center. This centers them as well.
Before:
After: