Live HTML on the board
Any DOM node can be an element on the board. It pans, zooms and sits in layer order with the drawings around it.
With interactive: true, its buttons, links and inputs work on the first click, and dragging its padding moves it. Inside a control, data-fn-drag marks an area that drags.
Without interactive, double-click the element to use it and press Escape to return to the board.
const card = document.createElement('div');
card.style.padding = '16px';
card.innerHTML = '<h3>Initiative</h3><button type="button">Next turn</button>';
viewport.addHtmlElement(card, { x: 100, y: 200 }, { w: 250, h: 150 }, { interactive: true });