Docs: mobile layout fix (#2466)
* Remove console warning * Fix table overflow issue on mobile
This commit is contained in:
+1
-1
@@ -59,7 +59,7 @@ h1, h2, h3, h4, h5, h6 {
|
|||||||
left: -3.236em;
|
left: -3.236em;
|
||||||
max-width: calc(100cqw);
|
max-width: calc(100cqw);
|
||||||
width: fit-content;
|
width: fit-content;
|
||||||
min-width: calc(100% + 3.236em + 3.236em);
|
min-width: min(calc(100% + 3.236em + 3.236em), 100cqw);
|
||||||
}
|
}
|
||||||
.rst-content .section .wy-table-responsive .docutils {
|
.rst-content .section .wy-table-responsive .docutils {
|
||||||
padding-left: 3.236em;
|
padding-left: 3.236em;
|
||||||
|
|||||||
@@ -134,11 +134,13 @@ function ThemeNav () {
|
|||||||
// .wy-table-responsive activates css rules that change the size of
|
// .wy-table-responsive activates css rules that change the size of
|
||||||
// tables, making anchor points move around.
|
// tables, making anchor points move around.
|
||||||
console.log('Document ready, checking for anchor in URL');
|
console.log('Document ready, checking for anchor in URL');
|
||||||
const anchorEl = document.querySelector(window.location.hash);
|
if (window.location.hash) {
|
||||||
anchorEl.getBoundingClientRect(); // Force layout to ensure scrollIntoView works correctly
|
const anchorEl = document.querySelector(window.location.hash);
|
||||||
if (anchorEl) {
|
anchorEl.getBoundingClientRect(); // Force layout to ensure scrollIntoView works correctly
|
||||||
console.log('Anchor element:', anchorEl);
|
if (anchorEl) {
|
||||||
anchorEl.scrollIntoView({ behavior: 'instant', block: 'start' });
|
console.log('Anchor element:', anchorEl);
|
||||||
|
anchorEl.scrollIntoView({ behavior: 'instant', block: 'start' });
|
||||||
|
}
|
||||||
}
|
}
|
||||||
// end edit by joerick
|
// end edit by joerick
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user