Difference between revisions of "MediaWiki:Common.js"

From Buddha-Nature
((by SublimeText.Mediawiker))
((by SublimeText.Mediawiker))
 
(244 intermediate revisions by the same user not shown)
Line 1: Line 1:
mw.loader.load( 'https://fonts.googleapis.com/css?family=Crimson+Text:400,400i,700', 'text/css' );
 
mw.loader.load( 'https://cdnjs.cloudflare.com/ajax/libs/animate.css/3.5.2/animate.min.css', 'text/css' );
 
mw.loader.load( 'https://use.fontawesome.com/bd289233d5.js' );
 
mw.loader.load( 'https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta.2/css/bootstrap.min.css', 'text/css' );
 
mw.loader.load( 'https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta.2/js/bootstrap.min.js' );
 
mw.loader.load( 'https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.12.3/umd/popper.min.js' );
 
mw.loader.load( 'https://code.jquery.com/jquery-3.2.1.slim.min.js' );
 
  
  
 
+
// Discover page anchors
function BrowserDetection() {
+
$('.fp-arrowUp').click(function(){
    //Check if browser is IE
+
     $.fn.fullpage.moveSectionUp();
    if (navigator.userAgent.search("MSIE") & gt; = 0) {
+
});
        // insert conditional IE code here
+
$('.fp-arrowDown').click(function(){
     }
+
     $.fn.fullpage.moveSectionDown();
    //Check if browser is Chrome
+
});
    else if (navigator.userAgent.search("Chrome") & gt; = 0) {
 
        // insert conditional Chrome code here
 
    }
 
    //Check if browser is Firefox
 
    else if (navigator.userAgent.search("Firefox") & gt; = 0) {
 
        // insert conditional Firefox Code here
 
    }
 
    //Check if browser is Safari
 
    else if (navigator.userAgent.search("Safari") & gt; = 0 & amp; & amp; navigator.userAgent.search("Chrome") & lt; 0) {
 
        function(){ $('#navbar-main').css('background','rgba(16, 55, 82, 0.62)') };
 
     }
 
    //Check if browser is Opera
 
    else if (navigator.userAgent.search("Opera") & gt; = 0) {
 
        // insert conditional Opera code here
 
    }
 
}
 

Latest revision as of 18:26, 16 December 2022

// Discover page anchors
$('.fp-arrowUp').click(function(){
    $.fn.fullpage.moveSectionUp();
});
$('.fp-arrowDown').click(function(){
    $.fn.fullpage.moveSectionDown();
});