Prevent Zoom Pro Ads and Success Hash

Prevents the #success Hash on Zoom join links to allow sharing the link with others and prevents Zoom Pro ads from appearing after the button is clicked.

当前为 2022-06-30 提交的版本,查看 最新版本

// ==UserScript==
// @name        Prevent Zoom Pro Ads and Success Hash
// @namespace   https://github.com/DenverCoder1
// @version     0.0.2
// @description Prevents the #success Hash on Zoom join links to allow sharing the link with others and prevents Zoom Pro ads from appearing after the button is clicked.
// @match       https://*zoom.us/s/*
// @include     https://*.zoom.us/s/*
// @grant       none
// @author      Jonah Lawrence (DenverCoder1)
// @license     MIT
// ==/UserScript==

window.addEventListener("hashchange", function () {
  history.replaceState(null, null, " ");
});

window.onbeforeunload = function (e) {
  var message = "Are you sure you want to leave?";
  e = e || window.event;
  // For IE and Firefox
  if (e) {
    e.returnValue = message;
  }
  // For Safari
  return message;
};