mirror of
https://github.com/squidfunk/mkdocs-material.git
synced 2024-06-14 11:52:32 +03:00
Fixed edge cases for rounded borders on code blocks
This commit is contained in:
parent
aa3440215a
commit
73331ee78c
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -34,7 +34,7 @@
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
{% block styles %}
|
||||
<link rel="stylesheet" href="{{ 'assets/stylesheets/main.faa78eba.min.css' | url }}">
|
||||
<link rel="stylesheet" href="{{ 'assets/stylesheets/main.8d5d63f8.min.css' | url }}">
|
||||
{% if config.theme.palette %}
|
||||
{% set palette = config.theme.palette %}
|
||||
<link rel="stylesheet" href="{{ 'assets/stylesheets/palette.e6a45f82.min.css' | url }}">
|
||||
|
@ -180,6 +180,12 @@
|
||||
// Adjust spacing for code block
|
||||
+ pre {
|
||||
margin-top: 0;
|
||||
|
||||
// Remove rounded border on top side
|
||||
> code {
|
||||
border-top-left-radius: 0;
|
||||
border-top-right-radius: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -191,7 +197,8 @@
|
||||
// don't overlay line numbers, as active annotations have a `z-index` of 2.
|
||||
z-index: 3;
|
||||
float: left;
|
||||
margin-inline: px2em(16px, 13.6px);
|
||||
margin-right: px2em(16px, 13.6px);
|
||||
margin-left: px2em(-16px, 13.6px);
|
||||
padding-left: px2em(16px, 13.6px);
|
||||
color: var(--md-default-fg-color--light);
|
||||
background-color: var(--md-code-bg-color);
|
||||
@ -309,8 +316,8 @@
|
||||
|
||||
// Remove rounded borders on left side
|
||||
code {
|
||||
border-top-right-radius: px2rem(2px);
|
||||
border-bottom-right-radius: px2rem(2px);
|
||||
border-top-left-radius: 0;
|
||||
border-bottom-left-radius: 0;
|
||||
}
|
||||
}
|
||||
|
||||
@ -350,7 +357,7 @@
|
||||
padding: 0 px2rem(16px);
|
||||
}
|
||||
|
||||
// Omit rounded borders
|
||||
// Remove rounded borders
|
||||
code {
|
||||
border-radius: 0;
|
||||
}
|
||||
|
@ -186,13 +186,19 @@
|
||||
> .highlighttable:first-child {
|
||||
margin: 0;
|
||||
|
||||
// Omit rounded borders
|
||||
> code {
|
||||
// Remove rounded borders
|
||||
code {
|
||||
border-start-start-radius: 0;
|
||||
border-start-end-radius: 0;
|
||||
}
|
||||
}
|
||||
|
||||
// Remove rounded border on line numbers container
|
||||
> .highlighttable:first-child .linenos {
|
||||
border-start-start-radius: 0;
|
||||
border-start-end-radius: 0;
|
||||
}
|
||||
|
||||
// Code block result container is the second child
|
||||
> .result:nth-child(2) {
|
||||
margin-top: 0;
|
||||
|
Loading…
Reference in New Issue
Block a user