PageSourceSearch

https://naometoque.rs.gov.br/wp-content/themes/prefeituraonline_v3/assets/js/main.js?ver=7.1.3

js naometoque.rs.gov.br collected 2026-10-09 17:17:59 UTC 2,903 bytes, 111 lines download raw bytes

1jQuery(document).ready(function ($) {
2
3	jQuery.noConflict();
4	
5	$( '.pon-menu-dropdown' ).on( 'click', 'button', function() {
6	
7		$( this ).toggleClass('active');
8		$( '.pon-menu-dropdown .menu-content' ).toggle();
9		return false;
10	
11	});
12
13	$( '.pon-mobile-nav' ).on( 'click', '.btn-menu-mobile', function() {
14	
15		$( 'body' ).toggleClass('menu-mobile-open');
16		return false;
17	
18	});
19	
20	$(".menu-mobile-title").on("click", function(e) {
21
22		e.preventDefault();
23		var $this = $(this);
24
25		if ( !$this.hasClass("active") ) {
26			$(".menu-mobile-content").slideUp(400);
27			$(".menu-mobile-title").removeClass("active");			
28		}
29
30		$this.toggleClass("active");
31		$this.next().slideToggle();
32				
33	});
34	
35	$( '.menu-content-header' ).on( 'click', 'a', function() {
36	
37		menu_index =  $( this ).data( 'index' );
38		
39		$( '.menu-content-header a' ).removeClass( 'menu-content-active' );
40		$( this ).addClass( 'menu-content-active' );
41		
42		$( '.menu-content-content > div' ).removeClass( 'menu-content-active' );
43		$( '.menu-content-content > div:eq(' + menu_index + ')' ).addClass( 'menu-content-active' );
44		
45		return false;
46	
47	});
48	
49	$( '.pon-menu-dropdown .menu-item-has-children' ).prepend('<span class="open-sub-menu"><i class="icon-arrow-right"></span>');
50	$( '.pon-menu-dropdown .open-sub-menu' ).on( 'click', function() {		
51		$( this ).closest( '.menu' ).get(0).style.setProperty("--sub-menu", "1");
52		$( this ).closest( '.menu-item-has-children' ).addClass('active');
53		return false;
54	});
55	$( '.pon-menu-dropdown .menu-item-has-children' ).find('.sub-menu').prepend( '<li><a class="back-menu" href="javascript:;"><i class="icon-arrow-left"></i> Categoria anterior</a></li>' );
56	$( '.pon-menu-dropdown .back-menu' ).on( 'click', function() {
57		$( this ).closest( '.menu' ).get(0).style.setProperty("--sub-menu", "0");
58		$( this ).closest( '.menu-item-has-children' ).removeClass('active');
59		return false;
60	});
61	
62	
63	// share bar
64
65	$( document ).on('click', '[data-share]', function () {
66		var url = $(this).data('share');
67		var newW = 800 + 100;
68		var newH = 600 + 100;
69		var left = (screen.width - newW) / 2;
70		var top = (screen.height - newH) / 2;
71		var newwindow = window.open(url, 'name', 'location=0,toolbar=0,width=' + newW + ',height=' + newH + ',left=' + left + ',top=' + top);
72		newwindow.resizeTo(newW, newH);
73		newwindow.moveTo(left, top);
74		newwindow.focus();
75		return false;
76	});
77	
78});
79
80// back link
81
82;(function() {
83
84	let backLink = document.getElementById('back-page');
85
86	if( backLink ) {
87		backLink.setAttribute('href', document.referrer);
88
89		backLink.addEventListener("click", function() {		
90			history.back();
91			return false;
92		});
93	}
94
95})()
96
97// header sticky
98
99;(function() {
100
101	let sticky = 57; /* toolbar height */
102
103	window.onscroll = function() {		
104		if (window.scrollY > sticky) {
105			document.body.classList.add("sticky");
106		} else {
107			document.body.classList.remove("sticky");
108		}
109	};
110
111})()

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.