emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[O] [BUG] worg table of contents


From: Rick Frankel
Subject: [O] [BUG] worg table of contents
Date: Wed, 15 May 2013 13:53:55 -0400
User-agent: Roundcube Webmail/0.9.0

The table of contents on worg is shown/hidden using the :hover
pseudo-element on the #table-of-contents element.

The problem is that this doesn't work on an ipad (or other touch
device). The following javascript snippet will add a function to show
the toc when it is "clicked", but I'm not sure where to put it (at the
bottom of "preamble.html"?)

#+BEGIN_SRC javascript
document.addEventListener('DOMContentLoaded',function() {
document.getElementById("table-of-contents").onclick = function() {
var elem = document.getElementById("text-table-of-contents");
elem.style.display = elem.style.display == "block" ? "none" : "block";
}
});
#+END_SRC

rick



reply via email to

[Prev in Thread] Current Thread [Next in Thread]