Prideless MDN

去除 MDN 的 Pride Month 宣传

您需要先安装一个扩展,例如 篡改猴Greasemonkey暴力猴,之后才能安装此脚本。

You will need to install an extension such as Tampermonkey to install this script.

您需要先安装一个扩展,例如 篡改猴暴力猴,之后才能安装此脚本。

您需要先安装一个扩展,例如 篡改猴Userscripts ,之后才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。

您需要先安装用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

// ==UserScript==
// @name              Prideless MDN
// @name:zh-CN        Prideless MDN
// @namespace         https://github.com/ZeroAurora
// @match             https://developer.mozilla.org/*
// @version           1.0
// @author            Whoever but not LGBTQIA+
// @description       Remove the pride from MDN
// @description:zh-CN 去除 MDN 的 Pride Month 宣传
// @homepageURL       https://github.com/ZeroAurora/UserJS-Prideless
// @license           WTFPL
// @grant             GM_addStyle
// @run-at            document-start
// ==/UserScript==

const pridelessCSS = `
.logo .logo-m {
  fill: var(--text-link) !important;
}

.logo .logo-_ {
  fill: var(--text-link) !important;
}

.homepage-hero section p > span::after {
  height: 0 !important;
}
`;

function removePride() {
  const manifestoParent = document.querySelector(
    ".homepage-hero > section:nth-child(1) > p:nth-child(2)"
  );
  const mandala = document.querySelector(".mandala-container");
  if (mandala && mandala.classList.contains("pride")) {
    manifestoParent.innerHTML = `Documenting web technologies, including CSS, HTML, and JavaScript, since 2005.`;
    mandala.classList.remove("animate-colors");
    mandala.classList.remove("pride");
  }
}

GM_addStyle(pridelessCSS);
document.addEventListener("DOMContentLoaded", removePride);