-
When I write text close to a code block, margin appears between the tab title and the code block, you can see it in the second tab on the gif. I don't know what the problem is here, and I usually leave space in the markdown, I just accidentally noticed it. I think the recommendation would be to leave space around the code block in the markdown, but still I ask, is this expected behavior or does it look like a bug? 🤔
site_name: Test
theme:
name: material
markdown_extensions:
- pymdownx.superfences
- pymdownx.tabbed:
alternate_style: true
# Header
=== "One"
```js
one
```
**one**
=== "Two"
```
two
```
**two** Code: |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
Thanks for noting. That's actually by design and resembles the behavior of tabbed fenced code blocks before we had Tabbed. The idea is: if a code block is the first child, the margin is gone. You can override the rule that adds the margin with additional CSS if you don't like the behavior: .md-typeset .tabbed-block > .highlight:first-child > pre {
margin: 1em;
} |
Beta Was this translation helpful? Give feedback.
Thanks for noting. That's actually by design and resembles the behavior of tabbed fenced code blocks before we had Tabbed. The idea is: if a code block is the first child, the margin is gone. You can override the rule that adds the margin with additional CSS if you don't like the behavior: