Skip to content

Fix space between <figcaption> and <pre>#313

Merged
reinink merged 2 commits into
masterfrom
figure-pre-margin-fix
Aug 30, 2023
Merged

Fix space between <figcaption> and <pre>#313
reinink merged 2 commits into
masterfrom
figure-pre-margin-fix

Conversation

@reinink

@reinink reinink commented Aug 30, 2023

Copy link
Copy Markdown
Member

Fixes #304

This PR fixes a spacing issue when putting a code block within a <figure>, where the margin on the <pre> wasn't being removed due to an ordering issue. This is a similar issue to #267.

By moving the figure styles to the end, the figure > * margin reset now takes priority over the specific element margin styles.

Before:

image

After:

image

@vercel

vercel Bot commented Aug 30, 2023

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
tailwindcss-typography ✅ Ready (Inspect) Visit Preview 💬 Add feedback Aug 30, 2023 3:37pm

@reinink
reinink merged commit ee884f3 into master Aug 30, 2023
@reinink
reinink deleted the figure-pre-margin-fix branch August 30, 2023 15:38
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.

Too much space between figcaption and code block (pre)

1 participant