javascript: provide basic functionality

Tooltips dont work, yet. I have to find a more convenient way to add
elements.