mirror of
https://github.com/squidfunk/mkdocs-material.git
synced 2024-06-14 11:52:32 +03:00
Added support for #only-light and #only-dark image hash fragments
This commit is contained in:
parent
90410f3910
commit
e3fba7ac7d
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
2
material/assets/stylesheets/main.eee90d4d.min.css
vendored
Normal file
2
material/assets/stylesheets/main.eee90d4d.min.css
vendored
Normal file
File diff suppressed because one or more lines are too long
1
material/assets/stylesheets/main.eee90d4d.min.css.map
Normal file
1
material/assets/stylesheets/main.eee90d4d.min.css.map
Normal file
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
1
material/assets/stylesheets/palette.dc90facb.min.css.map
Normal file
1
material/assets/stylesheets/palette.dc90facb.min.css.map
Normal file
File diff suppressed because one or more lines are too long
@ -34,10 +34,10 @@
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
{% block styles %}
|
||||
<link rel="stylesheet" href="{{ 'assets/stylesheets/main.4a1f2921.min.css' | url }}">
|
||||
<link rel="stylesheet" href="{{ 'assets/stylesheets/main.eee90d4d.min.css' | url }}">
|
||||
{% if config.theme.palette %}
|
||||
{% set palette = config.theme.palette %}
|
||||
<link rel="stylesheet" href="{{ 'assets/stylesheets/palette.9204c3b2.min.css' | url }}">
|
||||
<link rel="stylesheet" href="{{ 'assets/stylesheets/palette.dc90facb.min.css' | url }}">
|
||||
{% if palette.primary %}
|
||||
{% import "partials/palette.html" as map %}
|
||||
{% set primary = map.primary(
|
||||
|
@ -439,6 +439,11 @@ kbd {
|
||||
}
|
||||
}
|
||||
|
||||
// Hide images for dark mode
|
||||
img[src$="#only-dark"] {
|
||||
display: none;
|
||||
}
|
||||
|
||||
// Figure
|
||||
figure {
|
||||
display: flow-root;
|
||||
|
@ -95,5 +95,15 @@
|
||||
// Typeset color shades
|
||||
--md-typeset-a-color: hsla(#{hex2hsl($clr-indigo-400)}, 1);
|
||||
}
|
||||
|
||||
// Hide images for light mode
|
||||
img[src$="#only-light"] {
|
||||
display: none;
|
||||
}
|
||||
|
||||
// Show images for dark mode
|
||||
img[src$="#only-dark"] {
|
||||
display: initial;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user