PageSourceSearch

https://passionaria.ro/wp-content/themes/typegrid11/js/jquery.theme.js?ver=1.0

js passionaria.ro collected 2026-10-03 18:56:22 UTC 8,287 bytes, 88 lines download raw bytes

1/* WPBandit Theme Plugin v1.1 */
2(function($,window,document,undefined){var methods={init:function(){},nav_dropdown:function(opts){var options=$.extend({},{"submenu":"ul.sub-menu","speed":"fast"},opts);return this.each(function(){var nav_items=$(this).children("li");nav_items.children(options.submenu).hide();nav_items.hover(function(){$(this).children(options.submenu).slideDown(options.speed);},function(){$(this).children(options.submenu).hide();});});},nav_mobile:function(opts){var options=$.extend({},{"autoHide":true,"before":false,"containerClass":"select-nav","defaultOption":"Navigate to...","deviceWidth":768,"menuClass":"nav","subMenuClass":"sub-menu","subMenuDash":"&ndash;","useWindowWidth":true},opts);var nav=$(this);var navTimeout;$(window).resize(function(){clearTimeout(navTimeout);navTimeout=setTimeout(function(){nav.wpbandit("nav_mobile",options);},500);});var width=(options.useWindowWidth===true)?$(window).width():screen.width;if(width<options.deviceWidth){var container=$('<div class="'+options.containerClass+'"></div>');var menu=$('<select class="'+options.menuClass+'"></select>');if($("."+options.containerClass).length>0){return;}if(options.before){$(this).before(container);}else{$(this).after(container);}menu.appendTo(container);$("<option />",{"selected":"selected","value":"","text":options.defaultOption}).appendTo(menu);$(this).find("a").each(function(){var el=$(this);var optionText=el.text();var optionValue=el.attr("href");var optionParents=el.parents("."+options.subMenuClass);var len=optionParents.length;if(len>0){dash=Array(len+1).join(options.subMenuDash);optionText=dash+" "+optionText;}$("<option />",{"html":optionText,"value":optionValue,"selected":(this.href==window.location.href),}).appendTo(menu);});menu.change(function(){window.location=$(this).find("option:selected").val();});}},sc_accordion:function(opts){var options=$.extend({},{"trigger":".title a","toggle":".inner"},opts);return this.each(function(){var container=$(this);var trigger=container.find(options.trigger);var panels=container.find(options.toggle);panels.hide();trigger.click(function(e){e.preventDefault();var target=$(this).parent().next();if(!target.is(":visible")){panels.slideUp();target.slideDown();container.find(".title").removeClass("active");$(this).parent().addClass("active");}});});},sc_alert:function(opts){var options=$.extend({},{"button":".alert-close"},opts);return this.each(function(){var alert=$(this);var button_close=alert.children(options.button);button_close.click(function(e){e.preventDefault();alert.slideUp();});});},sc_tabs:function(opts){var options=$.extend({},{"tabs":".tab","trigger":".tabs-nav a"},opts);return this.each(function(){var tabs=$(this).find(options.tabs);var trigger=$(this).find(options.trigger);trigger.filter(":first").addClass("active");tabs.filter(":first").show();trigger.click(function(e){e.preventDefault();tabs.hide();tabs.filter(this.hash).show();trigger.removeClass("active");$(this).addClass("active");});});},sc_toggle:function(opts){var options=$.extend({},{"trigger":".title","toggle":".inner"},opts);return this.each(function(){var trigger=$(this).children(options.trigger);var content=$(this).children(options.toggle);trigger.toggle(function(){$(this).addClass("active");content.slideDown();},function(){$(this).removeClass("active");content.slideUp();});});},widget_tabs:function(opts){var options=$.extend({},{"tabs":".wpb-tab","trigger":".wpb-tabs a"},opts);return this.each(function(){var tabs=$(this).find(options.tabs);var trigger=$(this).find(options.trigger);trigger.filter(":first").addClass("active");tabs.filter(":first").show();trigger.click(function(e){e.preventDefault();tabs.hide();tabs.filter(this.hash).show();trigger.removeClass("active");$(this).addClass("active");});});},scroll_top:function(opts){var options=$.extend({},{"speed":"slow"},opts);return this.each(function(){$(this).click(function(e){e.preventDefault();$("html, body").animate({scrollTop:0},options.speed);});});},sticky_footer:function(opts){var options=$.extend({},{"pushDiv":"#sticky-footer-push"},opts);var footer=$(this);wpbPositionFooter(footer,options.pushDiv);$(window).scroll(function(){wpbPositionFooter(footer,options.pushDiv);}).resize(function(){wpbPositionFooter(footer,options.pushDiv);});function wpbPositionFooter(footer,pushDiv){var docHeight=$(document.body).height()-$(pushDiv).height();if(docHeight<$(window).height()){var diff=$(window).height()-docHeight;if(!$(pushDiv).length>
20){footer.before('<div id="'+pushDiv.substring(1,pushDiv.length)+'"></div>');}$(pushDiv).height(diff);}}},portfolio_category_filter:function(opts){var options=$.extend({},{"currentClass":"current"},opts);return this.each(function(){var filters=$(this).children("li");filters.find("a").click(function(e){e.preventDefault();var category=$(this).attr("data-filter");filters.removeClass(options.currentClass);$(this).parent().addClass(options.currentClass);$(".isotope").isotope({filter:category});});});},portfolio_size_switcher:function(opts){var options=$.extend({},{"container":"#portfolio","isotope":true},opts);return this.each(function(){var switcherContainer=$(this);var defaultLayout=switcherContainer.attr("data-current");var switcherItems=$(this).find("li");var portfolioItems=$(options.container).children("div");switcherItems.find("a").each(function(e){if(defaultLayout==$(this).attr("data-layout")){$(this).parent().addClass("current");}});switcherItems.find("a").click(function(e){e.preventDefault();switcherItems.removeClass("current");$(this).parent().addClass("current");var oldLayout=switcherContainer.attr("data-current");var newLayout=$(this).attr("data-layout");switcherContainer.attr("data-current",newLayout);portfolioItems.removeClass(oldLayout).addClass(newLayout);if(options.isotope){$(".isotope").isotope("reLayout");}});});},};$.fn.wpbandit=function(method){if(methods[method]){return methods[method].apply(this,Array.prototype.slice.call(arguments,1));}else{if(typeof method==="object"||!method){return methods.init.apply(this,arguments);}else{$.error("Method "+method+" does not exist on jQuery.wpbandit");}}};})(jQuery,window,document);
3
4/* Theme Javascript */
5jQuery(document).ready(function($) {
6
7	/* Navigation
8	/*-----------------------------------------------------------------------*/
9
10	// Nav Dropdown
11	$('.nav').wpbandit('nav_dropdown');
12
13	/* Shortcodes
14	/*-----------------------------------------------------------------------*/
15
16	// Shortcode : Accordion
17	$('.accordion').wpbandit('sc_accordion');
18
19	// Shortcode : Alert
20	$('.alert').wpbandit('sc_alert');
21
22	// Shortcode : Tabs
23	$('.tabs').wpbandit('sc_tabs');
24
25	// Shortcode : Toggle
26	$('.toggle').wpbandit('sc_toggle');
27
28
29	/* Widgets
30	/*-----------------------------------------------------------------------*/
31
32	// Widget: WPB Tabs
33	$('.widget_wpb_tabs').wpbandit('widget_tabs');
34
35
36	/* Miscellaneous
37	/*-----------------------------------------------------------------------*/
38
39	// Table odd rows class
40	$('table tr:odd').addClass('alt');
41
42	// Scroll To Top
43	$('#footer a#to-top').wpbandit('scroll_top');
44	
45	
46	/* Sidebar collapse
47	/*-----------------------------------------------------------------------*/
48	$('body').addClass('sidebar-collapse');
49	
50	$('.sidebar-toggle').click(function(){
51		$('body').toggleClass('sidebar-collapse').toggleClass('sidebar-expand');
52	});
53	
54	/* Mobile nav smooth toggle height with css transition
55	/*-----------------------------------------------------------------------*/
56	$('.nav-container').on('click', function() {
57		slide($('.nav-wrap .nav', this));
58	});
59	 
60	function slide(content) {
61		var wrapper = content.parent();
62		var contentHeight = content.outerHeight(true);
63		var wrapperHeight = wrapper.height();
64	 
65		wrapper.toggleClass('expand');
66		if (wrapper.hasClass('expand')) {
67		setTimeout(function() {
68			wrapper.addClass('transition').css('height', contentHeight);
69		}, 10);
70	}
71	else {
72		setTimeout(function() {
73			wrapper.css('height', wrapperHeight);
74			setTimeout(function() {
75			wrapper.addClass('transition').css('height', 0);
76			}, 10);
77		}, 10);
78	}
79	 
80	wrapper.one('transitionEnd webkitTransitionEnd transitionend oTransitionEnd msTransitionEnd', function() {
81		if(wrapper.hasClass('open')) {
82			wrapper.removeClass('transition').css('height', 'auto');
83		}
84	});
85	}
86	
87	
88});

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.