mirror of
https://github.com/caddyserver/website.git
synced 2025-04-22 21:16:15 -04:00
Make overflowing tables scroll horizontally on mobile
This commit is contained in:
parent
7a121ca58a
commit
56ed46f83f
3 changed files with 13 additions and 2 deletions
|
@ -718,7 +718,11 @@ table {
|
|||
font-size: 16px;
|
||||
}
|
||||
|
||||
article > table {
|
||||
article > .table-wrapper {
|
||||
overflow-x: scroll;
|
||||
}
|
||||
|
||||
article table {
|
||||
margin: 25px auto;
|
||||
}
|
||||
|
||||
|
|
|
@ -55,6 +55,9 @@ $(function() {
|
|||
let text = item.innerText.replace(/</g,'<').replace(/>/g,'>');
|
||||
$(item).html('<a href="/docs/caddyfile/matchers#syntax" style="color: inherit;" title="Matcher token">' + text + '</a>');
|
||||
});
|
||||
|
||||
// Wrap all tables in a div so we can apply overflow-x: scroll
|
||||
$('table').wrap('<div class="table-wrapper"></div>');
|
||||
});
|
||||
|
||||
// addLinkaddLinksToSubdirectivessToAnchors finds all the ID anchors
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue