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

report(css): use padding for PWA vertical border space #6972

Merged
merged 5 commits into from
Jan 14, 2019

Conversation

exterkamp
Copy link
Member

Summary
The vertical separator looks squished when looking at small width screens. On large width screens this makes a not very noticable 1px difference 🤷‍♂️

Don't know if this is WAI, but I wanted to mention it since I thought it looked a bit off.

Current view on min-width screens:
margin
With padding instead of margin:
padding

margin: 0 4px;
}

.lh-scores-header .lh-gauge--pwa__wrapper {
margin-right: 4px;
padding-left: 3px; /* 4px - 1px border */
Copy link
Collaborator

Choose a reason for hiding this comment

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

why do we need to subtract the border? didn't we have 9px of space before with margin-left (4) + margin-right (4) + border (1)

Copy link
Member Author

Choose a reason for hiding this comment

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

Yeah it is currently a 9px space. I removed the 1px just to make it 4x4 even because the symmetry is pleasing. It's fair to make it 4x4 + 1px border 🤷‍♂️ I'm just brining up the concern.

Copy link
Collaborator

Choose a reason for hiding this comment

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

maybe my CSS math is just off :) but isn't having only 3px of padding making the border spacing asymmetrical? or are you referring to consistent spacing between the category scores?

Copy link
Member Author

Choose a reason for hiding this comment

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

It makes the overall spacing symmetrical with the rest of the gauges. Or at least that was my intention.

Copy link
Member

@brendankenny brendankenny left a comment

Choose a reason for hiding this comment

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

LGTM

lighthouse-core/report/html/report-styles.css Outdated Show resolved Hide resolved
@exterkamp
Copy link
Member Author

Simplified to just use padding instead of margin 👏

Copy link
Collaborator

@patrickhulce patrickhulce left a comment

Choose a reason for hiding this comment

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

❤️

@brendankenny brendankenny merged commit ff41f6a into master Jan 14, 2019
@brendankenny brendankenny deleted the pwa-line-padding branch January 14, 2019 21:23
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.

None yet

4 participants