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

Increase margin-bottom of last textual element in tabset content #2083

Merged
merged 3 commits into from
Jan 28, 2025

Conversation

DavidOliver
Copy link
Contributor

Increases margin of last element unless it's a pre (code box).

Left: before. Right: after.

image

@DavidOliver DavidOliver requested a review from josevalim January 28, 2025 17:05
Copy link

github-actions bot commented Jan 28, 2025

@josevalim
Copy link
Member

Should we check for pre? Or should we check for the last child being a p? For example, what if it is admonition? Or a table? Or an image?

@DavidOliver
Copy link
Contributor Author

I believe most other types of content should benefit from the 1.25em margin, but I'm setting up some tests now and will report back soon.

@DavidOliver
Copy link
Contributor Author

DavidOliver commented Jan 28, 2025

Good call - there were improvements to make. I've set margins for the first and last children of some different kinds. This leaves spacing between elements in a tabpanel unaffected.

image

I'm going to look at margins here for narrow viewports now.

@DavidOliver DavidOliver marked this pull request as draft January 28, 2025 21:03
Copy link
Member

@josevalim josevalim left a comment

Choose a reason for hiding this comment

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

It seems quite some work for small adjustments but if you are happy with it, ship it!

@DavidOliver
Copy link
Contributor Author

For the narrow viewport widths, I've just tightend up the first-child table margin-top and the last-child table margin-bottom.

@DavidOliver DavidOliver marked this pull request as ready for review January 28, 2025 21:56
@DavidOliver DavidOliver merged commit 559939f into elixir-lang:main Jan 28, 2025
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants