W3C-Noto

W3C site, using Noto Sans

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey, Greasemonkey किंवा Violentmonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

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

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey किंवा Violentmonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल..

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

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल..

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्क्रिप्ट व्यवस्थापक एक्स्टेंशन इंस्टॉल करावे लागेल.

(माझ्याकडे आधीच युझर स्क्रिप्ट व्यवस्थापक आहे, मला इंस्टॉल करू द्या!)

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला Stylus सारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला Stylus सारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला Stylus सारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्टाईल व्यवस्थापक इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्टाईल व्यवस्थापक इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्टाईल व्यवस्थापक इंस्टॉल करावे लागेल.

(माझ्याकडे आधीच युझर स्टाईल व्यवस्थापक आहे, मला इंस्टॉल करू द्या!)

// ==UserScript==
// @name        W3C-Noto
// @description W3C site, using Noto Sans
// @namespace   https://tripu.info/
// @version     0.3.1
// @include     http://w3.org/*
// @include     http://*.w3.org/*
// @include     https://w3.org/*
// @include     https://*.w3.org/*
// @license     MIT
// @supportURL  https://tripu.info/
// @author      tripu
// ==/UserScript==

console.debug('[W3C-Noto] Start');

(() => {
    'use strict';
    if (document && document.getElementsByTagName && document.createElement) {
        var head = document.getElementsByTagName('head');
        if (head && 1 === head.length) {
            const link = document.createElement('link'),
                  style = document.createElement('style');
            head = head[0];
            link.setAttribute('href', '//www.w3.org/People/Antonio/noto/noto-tmp.css');
            link.setAttribute('rel', 'stylesheet');
            style.innerText = `
                :not(pre):not(ol):not(ul) {
                    line-height: 1.5;
                }
                pre, pre *, ol, ol *, ul, ul * {
                    line-height: 1.25;
                }
                :not(code):not(pre) {
                    font-family: 'Noto Sans', sans-serif;
                }
                code, code *, pre, pre * {
                    font-family:  'Inconsolata', monospace !important;
                }
            `;
            head.appendChild(link);
            head.appendChild(style);
            console.debug('[W3C-Noto] Done');
        } else
            console.debug('[W3C-Noto] No head');
    } else
        console.debug('[W3C-Noto] No document');
})();

console.debug('[W3C-Noto] End');