git.schokokeks.org
Repositories
Help
Report an Issue
fs-draft.git
Code
Commits
Branches
Tags
Suche
Strukturansicht:
579dbe0
Branches
Tags
master
midgard
vorlage
fs-draft.git
source
logic
client
main.js
advanced
bfadmin-master
commited
579dbe0
at 2016-04-25 20:27:11
main.js
Blame
History
Raw
"use strict"; function add_tooltips() { for (let dom_node of document.querySelectorAll(".word_fs")) { let url = "http://folksprak.org/munin.php?query=translation_fs_" + dom_node.textContent + "_en"; load_file ( url, function (error, content) { try { let object = JSON.parse(content); dom_node.setAttribute("title", object.map(entry => entry.to.stem).join(", ")); } catch (exception) { console.warn("couldn't parse ", content); } } ) } } function main() { let contentnode = class_contentnode.read(); document.querySelector("#toc").appendChild(contentnode.generate()); contentnode.adjust(); // add_tooltips(); } document.addEventListener("DOMContentLoaded", function (event) {main();});