PageSourceSearch

https://moodle.com/wp-content/themes/thetheme/plugins/header.js?ver=1.5.7

js moodle.com collected 2026-09-24 08:28:20 UTC 1,177 bytes, 42 lines download raw bytes

1( function() {
2
3	var body = document.body;
4
5	/* Toggle body 'scrolling' class when scrolling */
6	function scrollPage() {
7	    if ( window.pageYOffset > 90 ) {
8	        body.classList.add( 'scrolling' );
9	    } else {
10	        body.classList.remove( 'scrolling' );
11	    }
12	}
13
14	window.onscroll = scrollPage;
15	scrollPage();
16
17	/* Toggle the language switcher dropdown on click (works for touch and mouse alike) */
18	document.querySelectorAll( '.language-switcher' ).forEach( function( switcher ) {
19		var current = switcher.querySelector( '.language-switcher-current' );
20		if ( ! current ) { return; }
21
22		current.addEventListener( 'click', function( e ) {
23			e.stopPropagation();
24			switcher.classList.toggle( 'is-open' );
25		} );
26	} );
27
28	document.addEventListener( 'click', function() {
29		document.querySelectorAll( '.language-switcher.is-open' ).forEach( function( switcher ) {
30			switcher.classList.remove( 'is-open' );
31		} );
32	} );
33
34	document.addEventListener( 'keydown', function( e ) {
35		if ( e.key === 'Escape' ) {
36			document.querySelectorAll( '.language-switcher.is-open' ).forEach( function( switcher ) {
37				switcher.classList.remove( 'is-open' );
38			} );
39		}
40	} );
41
42} )();

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.