pinner in HTML with CSS animation
  function spinDuring(diagram, spinner, compute) {
    // where compute is a function of zero args
    // show the animated spinner
    if (typeof spinner === 'string') spinner = document.getElementById(spinner);
    if (spinner) {
      // position it in the middle of the viewport DIV
      const x = Math.floor(diagram.div.offsetWidth / 2 - spinner.naturalWidth / 2);
      const y = Math.floor(diagram.div.offsetHeight / 2 - spinner.naturalHeight / 2);
      spinner.style.l