Giter Site home page Giter Site logo
  • 👋 Hi, I’m @Takashij
  • 👀 I’m interested in ...
  • 🌱 I’m currently learning ...
  • 💞️ I’m looking to collaborate on ...
  • 📫 How to reach me ...

const toggle = document.querySelector(".toggle__theme"); const card = document.querySelector(".app"); toggle.addEventListener("click", () => { let theme = toggle.querySelector(".fas"); if (theme.classList.contains("fa-moon")) { theme.classList.remove("fa-moon"); theme.classList.add("fa-sun"); card.classList.add("dark"); } else {

    theme.classList.remove("fa-sun");
    theme.classList.add("fa-moon");
    card.classList.remove("dark");

}

})

//Chống copy function killCopy(e){ return false; }

function reEnable(){ return true; }

document.onselectstart=new Function ("return false");

if (window.sidebar){ document.onmousedown=killCopy; document.onclick=reEnable; }

function noteOut() { var note = document.querySelector(".note"); note.style.display = "none"; }

setInterval(noteOut,3000);

//Chống chuột phải window.onload = function() { document.addEventListener("contextmenu", function(e) { e.preventDefault(); }, false); document.addEventListener("keydown", function(e) { //document.onkeydown = function(e) { // "I" key if (e.ctrlKey && e.shiftKey && e.keyCode == 73) { disabledEvent(e); } // "J" key if (e.ctrlKey && e.shiftKey && e.keyCode == 74) { disabledEvent(e); } // "S" key + macOS if (e.keyCode == 83 && (navigator.platform.match("Mac") ? e.metaKey : e.ctrlKey)) { disabledEvent(e); } // "U" key if (e.ctrlKey && e.keyCode == 85) { disabledEvent(e); } // "F12" key if (event.keyCode == 123) { disabledEvent(e); } }, false);

function disabledEvent(e) {
    if (e.stopPropagation) {
        e.stopPropagation();
    } else if (window.event) {
        window.event.cancelBubble = true;
    }
    e.preventDefault();
    return false;
}

};

//Chống Ctrl + U document.onkeydown = function(e) { if (e.ctrlKey && (e.keyCode === 67 || e.keyCode === 86 || e.keyCode === 85 || e.keyCode === 117)) { return false; } else { return true; } }; $(document).keypress("u",function(e) { if(e.ctrlKey) return false; else return true; });

takashij's Projects

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.