Force UI Sans-Serif & Clear Text

Override every element’s font and smoothing settings

目前為 2025-05-15 提交的版本,檢視 最新版本

// ==UserScript==
// @name         Force UI Sans-Serif & Clear Text
// @description  Override every element’s font and smoothing settings
// @match        *://*/*
// @run-at       document-start
// @version 0.0.1.20250515170919
// @namespace https://greasyfork.org/users/1435046
// ==/UserScript==

(function() {
 const style = document.createElement('style');
 style.textContent = `
     /* Force system UI sans-serif and clear text smoothing */
     *:not([class*="fa-"]):not([class*="icon-"]):not([class*="material-"]):not([class*="fa"]):not([class*="icon"]):not([class*="material"])
      {
         font-family: ui-sans-serif, system-ui, sans-serif !important;
         -webkit-font-smoothing: antialiased;
         -moz-osx-font-smoothing: grayscale;
         text-rendering: optimizeLegibility;
     }
 `;
 const parent = document.head || document.documentElement;
 parent.appendChild(style);
})();