KMF unlock

Remove region lock

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Greasemonkey 油猴子Violentmonkey 暴力猴,才能安装此脚本。

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

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

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

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

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

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

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

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

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

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

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

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

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

// ==UserScript==
// @name         KMF unlock
// @namespace    http://tampermonkey.net/
// @version      0.15
// @description  Remove region lock
// @include     *
// @author       mo
// @match        https://toefl.kmf.com/*
// @run-at       document-idle
// @grant        GM_log
// ==/UserScript==

(function() {
    /* TOEFL section */
    /* Remove blocking box */
    document.querySelectorAll('.shield-box').forEach(function(s){s.remove();});
    document.querySelectorAll('.login-cont').forEach(function(s){s.remove();});
    document.querySelectorAll('.blur').forEach(function(b){b.classList.remove('blur');});

    
    var observer = new MutationObserver(callback);
    observer.observe(document, {childList: true, attributes: true, characterData: true, subtree: true});
    function callback(changes, observer) {
        document.querySelectorAll('.login-cont').forEach(function(s){s.remove();});
        document.querySelectorAll('.blur').forEach(function(b){b.classList.remove('blur');});
    }    
    // Callback function to execute when mutations are observed

    // for (var targetNode in targetNodes) {
    //     // Callback function to execute when mutations are observed
    

    //     // Create an observer instance linked to the callback function
    //     var observer = new MutationObserver(callback);

    //     // Start observing the target node for configured mutations
    //     observer.observe(targetNode, config);
    // }

    /* Remove disable tab and text for mock section*/
    document.querySelectorAll('.tab-forbidden[data-type="PREP"]').forEach(function(e){e.classList.remove('tab-forbidden');});
})();