mirror of
https://github.com/squidfunk/mkdocs-material.git
synced 2024-06-14 11:52:32 +03:00
Improved layer promotion and reduced jitter
This commit is contained in:
parent
3242ca974e
commit
bc6a0b5060
@ -130,7 +130,7 @@
|
|||||||
margin-top: px2rem(-20px);
|
margin-top: px2rem(-20px);
|
||||||
padding: 0 px2rem(20px);
|
padding: 0 px2rem(20px);
|
||||||
color: var(--md-default-bg-color--light);
|
color: var(--md-default-bg-color--light);
|
||||||
font-size: px2rem(15px);
|
font-size: ms(-1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -41,7 +41,6 @@
|
|||||||
box-shadow:
|
box-shadow:
|
||||||
0 0 px2rem(4px) rgba(0, 0, 0, 0),
|
0 0 px2rem(4px) rgba(0, 0, 0, 0),
|
||||||
0 px2rem(4px) px2rem(8px) rgba(0, 0, 0, 0);
|
0 px2rem(4px) px2rem(8px) rgba(0, 0, 0, 0);
|
||||||
backface-visibility: hidden;
|
|
||||||
z-index: 2;
|
z-index: 2;
|
||||||
|
|
||||||
// Always hide shadow, in case JavaScript is not available
|
// Always hide shadow, in case JavaScript is not available
|
||||||
@ -156,6 +155,8 @@
|
|||||||
text-overflow: ellipsis;
|
text-overflow: ellipsis;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
// Hack: reduce jitter
|
||||||
|
backface-visibility: hidden;
|
||||||
|
|
||||||
// Page title
|
// Page title
|
||||||
& + & {
|
& + & {
|
||||||
|
@ -205,6 +205,8 @@
|
|||||||
box-shadow:
|
box-shadow:
|
||||||
inset 0 px2rem(1px) 0 var(--md-default-fg-color--lightest);
|
inset 0 px2rem(1px) 0 var(--md-default-fg-color--lightest);
|
||||||
overflow-y: auto;
|
overflow-y: auto;
|
||||||
|
// Hack: reduce jitter
|
||||||
|
backface-visibility: hidden;
|
||||||
scroll-snap-type: y mandatory;
|
scroll-snap-type: y mandatory;
|
||||||
|
|
||||||
// Remove border for first list item
|
// Remove border for first list item
|
||||||
|
@ -130,9 +130,9 @@ $md-toggle__drawer--checked:
|
|||||||
max-height: 100%;
|
max-height: 100%;
|
||||||
margin: 0 px2rem(4px);
|
margin: 0 px2rem(4px);
|
||||||
overflow-y: auto;
|
overflow-y: auto;
|
||||||
scroll-snap-type: y mandatory;
|
|
||||||
// Hack: reduce jitter
|
// Hack: reduce jitter
|
||||||
backface-visibility: hidden;
|
backface-visibility: hidden;
|
||||||
|
scroll-snap-type: y mandatory;
|
||||||
|
|
||||||
// [tablet -]: Adjust margins
|
// [tablet -]: Adjust margins
|
||||||
@include break-to-device(tablet) {
|
@include break-to-device(tablet) {
|
||||||
|
@ -59,10 +59,9 @@
|
|||||||
// Source container
|
// Source container
|
||||||
.md-source {
|
.md-source {
|
||||||
display: block;
|
display: block;
|
||||||
padding-right: px2rem(12px);
|
|
||||||
transition: opacity 250ms;
|
transition: opacity 250ms;
|
||||||
font-size: px2rem(13px);
|
font-size: px2rem(13px);
|
||||||
line-height: 1.2;
|
line-height: 1.25;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
// Hack: reduce jitter
|
// Hack: reduce jitter
|
||||||
backface-visibility: hidden;
|
backface-visibility: hidden;
|
||||||
@ -115,7 +114,7 @@
|
|||||||
// Repository name
|
// Repository name
|
||||||
&__repository {
|
&__repository {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
max-width: 100%;
|
max-width: calc(100% - #{px2rem(24px)});
|
||||||
margin-left: px2rem(12px);
|
margin-left: px2rem(12px);
|
||||||
font-weight: 700;
|
font-weight: 700;
|
||||||
text-overflow: ellipsis;
|
text-overflow: ellipsis;
|
||||||
|
Loading…
Reference in New Issue
Block a user