This website requires JavaScript.
Explore
Help
Sign in
jesus
/
mdbook
Watch
1
Star
0
Fork
You've already forked mdbook
0
Code
Issues
Pull requests
Projects
Releases
Packages
Wiki
Activity
Actions
3b136689ee
mdbook
/
src
/
theme
/
stylus
/
variables.styl
4 lines
89 B
Stylus
Raw
Normal View
History
Unescape
Escape
Fix #47 sidebar stays hidden even after page change
2015-09-24 16:47:33 +02:00
$sidebar-width
=
3
0
0
p
x
On iOS, allow scrolling to the top of the page by tapping the top of the screen * This is a built-in function of iOS Safari that didn't work because the page content was inside absolutely-positioned, scrollable divs. * The fix is to stop using absolute positioning on `.page-wrapper` and `.page`, so that the content uses static positioning and flows naturally down the page. * Consequently, `.sidebar` and `.nav-chapter` now have to use `position: fixed` in order to be positioned relative to the viewport. * This fix also enables Safari's built-in behavior of automatically hiding the top and bottom toolbars when scrolling down the page.
2017-06-04 19:58:51 -07:00
$page-padding
=
1
5
p
x
$max-page-width-with-hidden-sidebar
=
1
0
6
0
p
x
Reference in a new issue
Copy permalink