mirror of
https://github.com/squidfunk/mkdocs-material.git
synced 2024-06-14 11:52:32 +03:00
Improved styling of code annotations and fixed borders of code blocks in tabs
This commit is contained in:
parent
c7cc8f07ab
commit
71dd84a0e9
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 %}
|
{% endif %}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
{% block styles %}
|
{% block styles %}
|
||||||
<link rel="stylesheet" href="{{ 'assets/stylesheets/main.9d5733d3.min.css' | url }}">
|
<link rel="stylesheet" href="{{ 'assets/stylesheets/main.36ad6006.min.css' | url }}">
|
||||||
{% if config.theme.palette %}
|
{% if config.theme.palette %}
|
||||||
{% set palette = config.theme.palette %}
|
{% set palette = config.theme.palette %}
|
||||||
<link rel="stylesheet" href="{{ 'assets/stylesheets/palette.e6a45f82.min.css' | url }}">
|
<link rel="stylesheet" href="{{ 'assets/stylesheets/palette.e6a45f82.min.css' | url }}">
|
||||||
|
@ -187,12 +187,12 @@
|
|||||||
// Code block is the first child of a tab - remove margin and mirror
|
// Code block is the first child of a tab - remove margin and mirror
|
||||||
// previous (now deprecated) SuperFences code block grouping behavior
|
// previous (now deprecated) SuperFences code block grouping behavior
|
||||||
> pre:first-child,
|
> pre:first-child,
|
||||||
> .highlight:first-child pre,
|
> .highlight:first-child > pre:first-child,
|
||||||
> .highlighttable:first-child {
|
> .highlighttable:first-child {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
|
|
||||||
// Remove rounded borders
|
// Remove rounded borders
|
||||||
code {
|
> code {
|
||||||
border-start-start-radius: 0;
|
border-start-start-radius: 0;
|
||||||
border-start-end-radius: 0;
|
border-start-end-radius: 0;
|
||||||
}
|
}
|
||||||
@ -204,11 +204,6 @@
|
|||||||
border-start-end-radius: 0;
|
border-start-end-radius: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Code block result container is the second child
|
|
||||||
> .result:nth-child(2) {
|
|
||||||
margin-top: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Adjust spacing for nested tabbed container
|
// Adjust spacing for nested tabbed container
|
||||||
> .tabbed-set {
|
> .tabbed-set {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
|
@ -172,7 +172,6 @@
|
|||||||
// alignment of text following an annotation.
|
// alignment of text following an annotation.
|
||||||
&::after {
|
&::after {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0.025em;
|
|
||||||
left: -0.126em;
|
left: -0.126em;
|
||||||
z-index: -1;
|
z-index: -1;
|
||||||
// Hack: the first property is used as a fallback for older browsers
|
// Hack: the first property is used as a fallback for older browsers
|
||||||
@ -209,9 +208,16 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Annotation marker content
|
// Annotation marker
|
||||||
[data-md-annotation-id]::before {
|
[data-md-annotation-id] {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
|
line-height: 90%;
|
||||||
|
|
||||||
|
// Annotation marker content
|
||||||
|
&::before {
|
||||||
|
display: inline-block;
|
||||||
|
padding-bottom: 0.1em;
|
||||||
|
vertical-align: 0.0625em;
|
||||||
transition: transform 400ms cubic-bezier(0.1, 0.7, 0.1, 1);
|
transition: transform 400ms cubic-bezier(0.1, 0.7, 0.1, 1);
|
||||||
content: attr(data-md-annotation-id);
|
content: attr(data-md-annotation-id);
|
||||||
|
|
||||||
@ -226,6 +232,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Annotation index on focus/hover
|
// Annotation index on focus/hover
|
||||||
:is(:focus-within, :hover) > & {
|
:is(:focus-within, :hover) > & {
|
||||||
|
Loading…
Reference in New Issue
Block a user