mirror of
https://github.com/discourse/DiscoTOC.git
synced 2026-09-16 23:42:13 -04:00
FIX: adjust mobile specificity (#71)
* FIX: adjust mobile specificity * prettier
This commit is contained in:
@@ -231,14 +231,6 @@ export default {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (
|
||||
!classNames.some((className) =>
|
||||
document.body.classList.contains(className)
|
||||
)
|
||||
) {
|
||||
return;
|
||||
}
|
||||
|
||||
// link to each heading
|
||||
if (
|
||||
e.target.closest(".d-toc-item") &&
|
||||
@@ -291,6 +283,14 @@ export default {
|
||||
if (!e.target.closest(".d-toc-wrapper.overlay")) {
|
||||
document.querySelector(".d-toc-wrapper").classList.remove("overlay");
|
||||
}
|
||||
|
||||
if (
|
||||
!classNames.some((className) =>
|
||||
document.body.classList.contains(className)
|
||||
)
|
||||
) {
|
||||
return;
|
||||
}
|
||||
},
|
||||
|
||||
buildTOC(headings) {
|
||||
|
||||
Reference in New Issue
Block a user