box.activateIfMouseOver(e);
  }));
  document.addEventListener('keydown', debounce(function (e) {
    if (e.code === "Escape" && Toolbox.active) {
      Toolbox.deactivate();
    }
  }));
}

document.addEventListener('DOMContentLoaded', init);

function debounce(fn, opts) {
  opts = opts || {};
  var timeout;
  return function(e) {
    if (opts.stopPropagation) {
      e.stopPropagation();
    }
    var args = arguments;
    if (timeout) {
      clearTimeout(timeout);
    }
    timeout = setTimeout(function