Improve table horizontal scrolling on mobile

pull/620/head
Thibaut Courouble 8 years ago
parent 302e3f1afe
commit 28587710e6

@ -37,13 +37,15 @@ app.templates.aboutPage = -> """
<li><a href="http://www.jeremykratz.com/">Jeremy Kratz</a> for the C/C++ logo
</ul>
<table class="_credits">
<tr>
<th>Documentation
<th>Copyright
<th>License
#{("<tr><td>#{c[0]}<td>&copy; #{c[1]}<td><a href=\"#{c[3]}\">#{c[2]}</a>" for c in credits).join('')}
</table>
<div class="_table">
<table class="_credits">
<tr>
<th>Documentation
<th>Copyright
<th>License
#{("<tr><td>#{c[0]}<td>&copy; #{c[1]}<td><a href=\"#{c[3]}\">#{c[2]}</a>" for c in credits).join('')}
</table>
</div>
<h2 class="_block-heading" id="faq">Questions & Answers</h2>
<dl>

@ -10,15 +10,17 @@ app.templates.offlinePage = (docs) -> """
</div>
</div>
<table class="_docs">
<tr>
<th>Documentation</th>
<th class="_docs-size">Size</th>
<th>Status</th>
<th>Action</th>
</tr>
#{docs}
</table>
<div class="_table">
<table class="_docs">
<tr>
<th>Documentation</th>
<th class="_docs-size">Size</th>
<th>Status</th>
<th>Action</th>
</tr>
#{docs}
</table>
</div>
<p class="_note"><strong>Note:</strong> your browser may delete DevDocs's offline data if your computer is running low on disk space and you haven't used the app in a while. Load this page before going offline to make sure the data is still there.
<h2 class="_block-heading">Questions & Answers</h2>
<dl>

@ -373,6 +373,9 @@
._code { @extend %code; }
._highlight { background: $highlightBackground !important; }
._table { width: 100%; }
._mobile ._table { overflow-x: auto; }
._pre-clip {
display: none;
position: absolute;

@ -105,12 +105,6 @@
max-width: none;
margin-left: 0;
}
// Responsive browser compatibility tables
#compat-desktop,
#compat-mobile {
overflow-x: auto;
}
}
//

@ -102,4 +102,6 @@
.cleared { clear: both; } // CSS/box-shadow
code > strong { font-weight: normal; }
#compat-desktop, #compat-mobile { @extend ._table; }
}

Loading…
Cancel
Save