mirror of
https://github.com/next-theme/hexo-theme-next.git
synced 2026-01-20 19:02:33 +00:00
Overlay body scrollbar in all browsers (#246)
* Apply viewport width to mixin `main-container`
This commit is contained in:
parent
4f9e3cfaba
commit
b02a186765
@ -14,6 +14,10 @@ body {
|
|||||||
font-size: $font-size-base;
|
font-size: $font-size-base;
|
||||||
line-height: $line-height-base;
|
line-height: $line-height-base;
|
||||||
min-height: 100%;
|
min-height: 100%;
|
||||||
|
overflow-x: hidden;
|
||||||
|
@supports (overflow-x: clip) {
|
||||||
|
overflow-x: clip;
|
||||||
|
}
|
||||||
position: relative;
|
position: relative;
|
||||||
transition: padding $transition-ease;
|
transition: padding $transition-ease;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -108,15 +108,16 @@ font-family-icons($icon = '') {
|
|||||||
}
|
}
|
||||||
|
|
||||||
main-container() {
|
main-container() {
|
||||||
margin: 0 auto;
|
--width: $content-desktop;
|
||||||
width: $content-desktop;
|
margin: 0 calc((100vw - var(--width)) / 2);
|
||||||
|
width: var(--width);
|
||||||
|
|
||||||
+desktop-large() {
|
+desktop-large() {
|
||||||
width: $content-desktop-large;
|
--width: $content-desktop-large;
|
||||||
}
|
}
|
||||||
|
|
||||||
+desktop-largest() {
|
+desktop-largest() {
|
||||||
width: $content-desktop-largest;
|
--width: $content-desktop-largest;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -2,6 +2,7 @@
|
|||||||
background: var(--content-bg-color);
|
background: var(--content-bg-color);
|
||||||
border-radius: $border-radius-inner;
|
border-radius: $border-radius-inner;
|
||||||
box-shadow: $box-shadow-inner;
|
box-shadow: $box-shadow-inner;
|
||||||
|
margin: 0 auto;
|
||||||
width: $sidebar-desktop;
|
width: $sidebar-desktop;
|
||||||
|
|
||||||
+tablet-mobile() {
|
+tablet-mobile() {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user