Created
August 27, 2016 05:52
-
-
Save Srijancse-zz/26e725c56a554aec97f8f8da63d12808 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$("a").on('click', function() { | |
if ($(this).text() === "Preview") { | |
$(this).parent().toggleClass("current"); | |
checkCurrent(); | |
} | |
}); | |
function checkCurrent() { | |
if ($('div[rel="wikiEditor-ui-view-preview"]').hasClass("current")) { | |
console.log("You are offline and clicked Preview"); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment