hinatazaka46-process

Perform base processing

Dieses Skript sollte nicht direkt installiert werden. Es handelt sich hier um eine Bibliothek für andere Skripte, welche über folgenden Befehl in den Metadaten eines Skriptes eingebunden wird // @require https://updategreasyfork.deno.dev/scripts/532854/1573309/hinatazaka46-process.js

// ==UserScript==
// @name            hinatazaka46-process
// @namespace       https://gf.zukizuki.org/ja/users/1328592-naoqv
// @description	    Perform base processing
// @description:ja  基底処理を実行
// @version         0.07
// @icon            https://cdn.hinatazaka46.com/files/14/hinata/img/favicons/favicon-32x32.png
// @grant           none
// @license         MIT
// ==/UserScript==

const getPageType = () => (location.href).match(/contents_list/) ? "contents"
  	: (location.href).match(/(news|media|detail|search|formation|diary\/member\/list|diary\/member|diary\/detail|artist\/00|artist|biography|video|contents|discography|aimashou|event|about_fanclub|page)/)[0];

const doProcess = (proc, scriptName) => {
  
  handleException(proc, scriptName);
  

  handleException(() => {
    const colorMode = getColorMode();

    initilizeColorToggle(colorMode);

    analyzeDefaultColor();
    setColor(getPageType(), colorMode);
  }, "HinatazakaBaseProcessor");
};