5
0
mirror of git://git.proxmox.com/git/pve-docs.git synced 2025-03-20 22:50:06 +03:00

mediawiki toc: adapt to version 1.35

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
Thomas Lamprecht 2021-05-28 14:19:09 +02:00
parent bc49aa1606
commit acf6050bdd

View File

@ -91,8 +91,11 @@ var asciidoc = {
// add init to mediawiki resource loader queue
(window.RLQ=window.RLQ||[]).push(function(){
mw.hook('wikipage.content').add(function($content) {
asciidoc.toc($content);
asciidoc.footnotes($content);
// cannot use mw.hook directly here yet, the mediawiki.base module is not yet available
mw.loader.implement('pve.doctoc', function() {
mw.hook('wikipage.content').add(function($content) {
asciidoc.toc($content);
asciidoc.footnotes($content);
});
});
});