// source --> https://emsepompa.com.tr/wp-content/plugins/woocommerce/assets/js/frontend/add-to-cart.min.js
jQuery(function(e){if("undefined"==typeof wc_add_to_cart_params)return!1;var t=function(){e(document.body).on("click",".add_to_cart_button",this.onAddToCart).on("click",".remove_from_cart_button",this.onRemoveFromCart).on("added_to_cart",this.updateButton).on("added_to_cart",this.updateCartPage).on("added_to_cart removed_from_cart",this.updateFragments)};t.prototype.onAddToCart=function(t){var a=e(this);if(a.is(".ajax_add_to_cart")){if(!a.attr("data-product_id"))return!0;t.preventDefault(),a.removeClass("added"),a.addClass("loading");var o={};e.each(a.data(),function(t,a){o[t]=a}),e(document.body).trigger("adding_to_cart",[a,o]),e.post(wc_add_to_cart_params.wc_ajax_url.toString().replace("%%endpoint%%","add_to_cart"),o,function(t){t&&(t.error&&t.product_url?window.location=t.product_url:"yes"!==wc_add_to_cart_params.cart_redirect_after_add?e(document.body).trigger("added_to_cart",[t.fragments,t.cart_hash,a]):window.location=wc_add_to_cart_params.cart_url)})}},t.prototype.onRemoveFromCart=function(t){var a=e(this),o=a.closest(".woocommerce-mini-cart-item");t.preventDefault(),o.block({message:null,overlayCSS:{opacity:.6}}),e.post(wc_add_to_cart_params.wc_ajax_url.toString().replace("%%endpoint%%","remove_from_cart"),{cart_item_key:a.data("cart_item_key")},function(t){t&&t.fragments?e(document.body).trigger("removed_from_cart",[t.fragments,t.cart_hash,a]):window.location=a.attr("href")}).fail(function(){window.location=a.attr("href")})},t.prototype.updateButton=function(t,a,o,r){(r=void 0!==r&&r)&&(r.removeClass("loading"),r.addClass("added"),wc_add_to_cart_params.is_cart||0!==r.parent().find(".added_to_cart").length||r.after(' '+wc_add_to_cart_params.i18n_view_cart+""),e(document.body).trigger("wc_cart_button_updated",[r]))},t.prototype.updateCartPage=function(){var t=window.location.toString().replace("add-to-cart","added-to-cart");e(".shop_table.cart").load(t+" .shop_table.cart:eq(0) > *",function(){e(".shop_table.cart").stop(!0).css("opacity","1").unblock(),e(document.body).trigger("cart_page_refreshed")}),e(".cart_totals").load(t+" .cart_totals:eq(0) > *",function(){e(".cart_totals").stop(!0).css("opacity","1").unblock(),e(document.body).trigger("cart_totals_refreshed")})},t.prototype.updateFragments=function(t,a){a&&(e.each(a,function(t){e(t).addClass("updating").fadeTo("400","0.6").block({message:null,overlayCSS:{opacity:.6}})}),e.each(a,function(t,a){e(t).replaceWith(a),e(t).stop(!0).css("opacity","1").unblock()}),e(document.body).trigger("wc_fragments_loaded"))},new t});
// source --> https://emsepompa.com.tr/wp-content/plugins/duracelltomi-google-tag-manager/js/gtm4wp-form-move-tracker.js
jQuery( function() {
jQuery( ":input" )
.on( "focus", function() {
var input = jQuery(this);
var inputID = input.attr("id") || "(no input ID)";
var inputName = input.attr("name") || "(no input name)";
var inputClass = input.attr("class") || "(no input class)";
var form = jQuery(this.form);
var formID = form.attr("id") || "(no form ID)";
var formName = form.attr("name") || "(no form name)";
var formClass = form.attr("class") || "(no form class)";
window[ gtm4wp_datalayer_name ].push({
'event' : 'gtm4wp.formElementEnter',
'inputID' : inputID,
'inputName' : inputName,
'inputClass': inputClass,
'formID' : formID,
'formName' : formName,
'formClass': formClass
});
})
.on( "blur", function() {
var input = jQuery(this);
var inputID = input.attr("id") || "(no input ID)";
var inputName = input.attr("name") || "(no input name)";
var inputClass = input.attr("class") || "(no input class)";
var form = jQuery(this.form);
var formID = form.attr("id") || "(no form ID)";
var formName = form.attr("name") || "(no form name)";
var formClass = form.attr("class") || "(no form class)";
window[ gtm4wp_datalayer_name ].push({
'event' : 'gtm4wp.formElementLeave',
'inputID' : inputID,
'inputName' : inputName,
'inputClass': inputClass,
'formID' : formID,
'formName' : formName,
'formClass': formClass
});
});
});
// source --> https://emsepompa.com.tr/wp-content/plugins/js_composer/assets/js/vendors/woocommerce-add-to-cart.js
window.jQuery( document ).ready( function ( $ ) {
$( 'body' ).on( 'adding_to_cart', function ( event, $button, data ) {
$button && $button.hasClass( 'vc_gitem-link' ) && $button
.addClass( 'vc-gitem-add-to-cart-loading-btn' )
.parents( '.vc_grid-item-mini' )
.addClass( 'vc-woocommerce-add-to-cart-loading' )
.append( $( '
' ) );
} ).on( 'added_to_cart', function ( event, fragments, cart_hash, $button ) {
if ( 'undefined' === typeof($button) ) {
$button = $( '.vc-gitem-add-to-cart-loading-btn' );
}
$button && $button.hasClass( 'vc_gitem-link' ) && $button
.removeClass( 'vc-gitem-add-to-cart-loading-btn' )
.parents( '.vc_grid-item-mini' )
.removeClass( 'vc-woocommerce-add-to-cart-loading' )
.find( '.vc_wc-load-add-to-loader-wrapper' ).remove();
} );
} );
// source --> https://emsepompa.com.tr/wp-content/themes/wp_spectrum/js/bootstrap.min.js
/*!
* Bootstrap v3.2.0 (http://getbootstrap.com)
* Copyright 2011-2014 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
*/
if("undefined"==typeof jQuery)throw new Error("Bootstrap's JavaScript requires jQuery");+function(a){"use strict";function b(){var a=document.createElement("bootstrap"),b={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(var c in b)if(void 0!==a.style[c])return{end:b[c]};return!1}a.fn.emulateTransitionEnd=function(b){var c=!1,d=this;a(this).one("bsTransitionEnd",function(){c=!0});var e=function(){c||a(d).trigger(a.support.transition.end)};return setTimeout(e,b),this},a(function(){a.support.transition=b(),a.support.transition&&(a.event.special.bsTransitionEnd={bindType:a.support.transition.end,delegateType:a.support.transition.end,handle:function(b){return a(b.target).is(this)?b.handleObj.handler.apply(this,arguments):void 0}})})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var c=a(this),e=c.data("bs.alert");e||c.data("bs.alert",e=new d(this)),"string"==typeof b&&e[b].call(c)})}var c='[data-dismiss="alert"]',d=function(b){a(b).on("click",c,this.close)};d.VERSION="3.2.0",d.prototype.close=function(b){function c(){f.detach().trigger("closed.bs.alert").remove()}var d=a(this),e=d.attr("data-target");e||(e=d.attr("href"),e=e&&e.replace(/.*(?=#[^\s]*$)/,""));var f=a(e);b&&b.preventDefault(),f.length||(f=d.hasClass("alert")?d:d.parent()),f.trigger(b=a.Event("close.bs.alert")),b.isDefaultPrevented()||(f.removeClass("in"),a.support.transition&&f.hasClass("fade")?f.one("bsTransitionEnd",c).emulateTransitionEnd(150):c())};var e=a.fn.alert;a.fn.alert=b,a.fn.alert.Constructor=d,a.fn.alert.noConflict=function(){return a.fn.alert=e,this},a(document).on("click.bs.alert.data-api",c,d.prototype.close)}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.button"),f="object"==typeof b&&b;e||d.data("bs.button",e=new c(this,f)),"toggle"==b?e.toggle():b&&e.setState(b)})}var c=function(b,d){this.$element=a(b),this.options=a.extend({},c.DEFAULTS,d),this.isLoading=!1};c.VERSION="3.2.0",c.DEFAULTS={loadingText:"loading..."},c.prototype.setState=function(b){var c="disabled",d=this.$element,e=d.is("input")?"val":"html",f=d.data();b+="Text",null==f.resetText&&d.data("resetText",d[e]()),d[e](null==f[b]?this.options[b]:f[b]),setTimeout(a.proxy(function(){"loadingText"==b?(this.isLoading=!0,d.addClass(c).attr(c,c)):this.isLoading&&(this.isLoading=!1,d.removeClass(c).removeAttr(c))},this),0)},c.prototype.toggle=function(){var a=!0,b=this.$element.closest('[data-toggle="buttons"]');if(b.length){var c=this.$element.find("input");"radio"==c.prop("type")&&(c.prop("checked")&&this.$element.hasClass("active")?a=!1:b.find(".active").removeClass("active")),a&&c.prop("checked",!this.$element.hasClass("active")).trigger("change")}a&&this.$element.toggleClass("active")};var d=a.fn.button;a.fn.button=b,a.fn.button.Constructor=c,a.fn.button.noConflict=function(){return a.fn.button=d,this},a(document).on("click.bs.button.data-api",'[data-toggle^="button"]',function(c){var d=a(c.target);d.hasClass("btn")||(d=d.closest(".btn")),b.call(d,"toggle"),c.preventDefault()})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.carousel"),f=a.extend({},c.DEFAULTS,d.data(),"object"==typeof b&&b),g="string"==typeof b?b:f.slide;e||d.data("bs.carousel",e=new c(this,f)),"number"==typeof b?e.to(b):g?e[g]():f.interval&&e.pause().cycle()})}var c=function(b,c){this.$element=a(b).on("keydown.bs.carousel",a.proxy(this.keydown,this)),this.$indicators=this.$element.find(".carousel-indicators"),this.options=c,this.paused=this.sliding=this.interval=this.$active=this.$items=null,"hover"==this.options.pause&&this.$element.on("mouseenter.bs.carousel",a.proxy(this.pause,this)).on("mouseleave.bs.carousel",a.proxy(this.cycle,this))};c.VERSION="3.2.0",c.DEFAULTS={interval:5e3,pause:"hover",wrap:!0},c.prototype.keydown=function(a){switch(a.which){case 37:this.prev();break;case 39:this.next();break;default:return}a.preventDefault()},c.prototype.cycle=function(b){return b||(this.paused=!1),this.interval&&clearInterval(this.interval),this.options.interval&&!this.paused&&(this.interval=setInterval(a.proxy(this.next,this),this.options.interval)),this},c.prototype.getItemIndex=function(a){return this.$items=a.parent().children(".item"),this.$items.index(a||this.$active)},c.prototype.to=function(b){var c=this,d=this.getItemIndex(this.$active=this.$element.find(".item.active"));return b>this.$items.length-1||0>b?void 0:this.sliding?this.$element.one("slid.bs.carousel",function(){c.to(b)}):d==b?this.pause().cycle():this.slide(b>d?"next":"prev",a(this.$items[b]))},c.prototype.pause=function(b){return b||(this.paused=!0),this.$element.find(".next, .prev").length&&a.support.transition&&(this.$element.trigger(a.support.transition.end),this.cycle(!0)),this.interval=clearInterval(this.interval),this},c.prototype.next=function(){return this.sliding?void 0:this.slide("next")},c.prototype.prev=function(){return this.sliding?void 0:this.slide("prev")},c.prototype.slide=function(b,c){var d=this.$element.find(".item.active"),e=c||d[b](),f=this.interval,g="next"==b?"left":"right",h="next"==b?"first":"last",i=this;if(!e.length){if(!this.options.wrap)return;e=this.$element.find(".item")[h]()}if(e.hasClass("active"))return this.sliding=!1;var j=e[0],k=a.Event("slide.bs.carousel",{relatedTarget:j,direction:g});if(this.$element.trigger(k),!k.isDefaultPrevented()){if(this.sliding=!0,f&&this.pause(),this.$indicators.length){this.$indicators.find(".active").removeClass("active");var l=a(this.$indicators.children()[this.getItemIndex(e)]);l&&l.addClass("active")}var m=a.Event("slid.bs.carousel",{relatedTarget:j,direction:g});return a.support.transition&&this.$element.hasClass("slide")?(e.addClass(b),e[0].offsetWidth,d.addClass(g),e.addClass(g),d.one("bsTransitionEnd",function(){e.removeClass([b,g].join(" ")).addClass("active"),d.removeClass(["active",g].join(" ")),i.sliding=!1,setTimeout(function(){i.$element.trigger(m)},0)}).emulateTransitionEnd(1e3*d.css("transition-duration").slice(0,-1))):(d.removeClass("active"),e.addClass("active"),this.sliding=!1,this.$element.trigger(m)),f&&this.cycle(),this}};var d=a.fn.carousel;a.fn.carousel=b,a.fn.carousel.Constructor=c,a.fn.carousel.noConflict=function(){return a.fn.carousel=d,this},a(document).on("click.bs.carousel.data-api","[data-slide], [data-slide-to]",function(c){var d,e=a(this),f=a(e.attr("data-target")||(d=e.attr("href"))&&d.replace(/.*(?=#[^\s]+$)/,""));if(f.hasClass("carousel")){var g=a.extend({},f.data(),e.data()),h=e.attr("data-slide-to");h&&(g.interval=!1),b.call(f,g),h&&f.data("bs.carousel").to(h),c.preventDefault()}}),a(window).on("load",function(){a('[data-ride="carousel"]').each(function(){var c=a(this);b.call(c,c.data())})})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.collapse"),f=a.extend({},c.DEFAULTS,d.data(),"object"==typeof b&&b);!e&&f.toggle&&"show"==b&&(b=!b),e||d.data("bs.collapse",e=new c(this,f)),"string"==typeof b&&e[b]()})}var c=function(b,d){this.$element=a(b),this.options=a.extend({},c.DEFAULTS,d),this.transitioning=null,this.options.parent&&(this.$parent=a(this.options.parent)),this.options.toggle&&this.toggle()};c.VERSION="3.2.0",c.DEFAULTS={toggle:!0},c.prototype.dimension=function(){var a=this.$element.hasClass("width");return a?"width":"height"},c.prototype.show=function(){if(!this.transitioning&&!this.$element.hasClass("in")){var c=a.Event("show.bs.collapse");if(this.$element.trigger(c),!c.isDefaultPrevented()){var d=this.$parent&&this.$parent.find("> .panel > .in");if(d&&d.length){var e=d.data("bs.collapse");if(e&&e.transitioning)return;b.call(d,"hide"),e||d.data("bs.collapse",null)}var f=this.dimension();this.$element.removeClass("collapse").addClass("collapsing")[f](0),this.transitioning=1;var g=function(){this.$element.removeClass("collapsing").addClass("collapse in")[f](""),this.transitioning=0,this.$element.trigger("shown.bs.collapse")};if(!a.support.transition)return g.call(this);var h=a.camelCase(["scroll",f].join("-"));this.$element.one("bsTransitionEnd",a.proxy(g,this)).emulateTransitionEnd(350)[f](this.$element[0][h])}}},c.prototype.hide=function(){if(!this.transitioning&&this.$element.hasClass("in")){var b=a.Event("hide.bs.collapse");if(this.$element.trigger(b),!b.isDefaultPrevented()){var c=this.dimension();this.$element[c](this.$element[c]())[0].offsetHeight,this.$element.addClass("collapsing").removeClass("collapse").removeClass("in"),this.transitioning=1;var d=function(){this.transitioning=0,this.$element.trigger("hidden.bs.collapse").removeClass("collapsing").addClass("collapse")};return a.support.transition?void this.$element[c](0).one("bsTransitionEnd",a.proxy(d,this)).emulateTransitionEnd(350):d.call(this)}}},c.prototype.toggle=function(){this[this.$element.hasClass("in")?"hide":"show"]()};var d=a.fn.collapse;a.fn.collapse=b,a.fn.collapse.Constructor=c,a.fn.collapse.noConflict=function(){return a.fn.collapse=d,this},a(document).on("click.bs.collapse.data-api",'[data-toggle="collapse"]',function(c){var d,e=a(this),f=e.attr("data-target")||c.preventDefault()||(d=e.attr("href"))&&d.replace(/.*(?=#[^\s]+$)/,""),g=a(f),h=g.data("bs.collapse"),i=h?"toggle":e.data(),j=e.attr("data-parent"),k=j&&a(j);h&&h.transitioning||(k&&k.find('[data-toggle="collapse"][data-parent="'+j+'"]').not(e).addClass("collapsed"),e[g.hasClass("in")?"addClass":"removeClass"]("collapsed")),b.call(g,i)})}(jQuery),+function(a){"use strict";function b(b){b&&3===b.which||(a(e).remove(),a(f).each(function(){var d=c(a(this)),e={relatedTarget:this};d.hasClass("open")&&(d.trigger(b=a.Event("hide.bs.dropdown",e)),b.isDefaultPrevented()||d.removeClass("open").trigger("hidden.bs.dropdown",e))}))}function c(b){var c=b.attr("data-target");c||(c=b.attr("href"),c=c&&/#[A-Za-z]/.test(c)&&c.replace(/.*(?=#[^\s]*$)/,""));var d=c&&a(c);return d&&d.length?d:b.parent()}function d(b){return this.each(function(){var c=a(this),d=c.data("bs.dropdown");d||c.data("bs.dropdown",d=new g(this)),"string"==typeof b&&d[b].call(c)})}var e=".dropdown-backdrop",f='[data-toggle="dropdown"]',g=function(b){a(b).on("click.bs.dropdown",this.toggle)};g.VERSION="3.2.0",g.prototype.toggle=function(d){var e=a(this);if(!e.is(".disabled, :disabled")){var f=c(e),g=f.hasClass("open");if(b(),!g){"ontouchstart"in document.documentElement&&!f.closest(".navbar-nav").length&&a('').insertAfter(a(this)).on("click",b);var h={relatedTarget:this};if(f.trigger(d=a.Event("show.bs.dropdown",h)),d.isDefaultPrevented())return;e.trigger("focus"),f.toggleClass("open").trigger("shown.bs.dropdown",h)}return!1}},g.prototype.keydown=function(b){if(/(38|40|27)/.test(b.keyCode)){var d=a(this);if(b.preventDefault(),b.stopPropagation(),!d.is(".disabled, :disabled")){var e=c(d),g=e.hasClass("open");if(!g||g&&27==b.keyCode)return 27==b.which&&e.find(f).trigger("focus"),d.trigger("click");var h=" li:not(.divider):visible a",i=e.find('[role="menu"]'+h+', [role="listbox"]'+h);if(i.length){var j=i.index(i.filter(":focus"));38==b.keyCode&&j>0&&j--,40==b.keyCode&&j').appendTo(this.$body),this.$element.on("click.dismiss.bs.modal",a.proxy(function(a){a.target===a.currentTarget&&("static"==this.options.backdrop?this.$element[0].focus.call(this.$element[0]):this.hide.call(this))},this)),e&&this.$backdrop[0].offsetWidth,this.$backdrop.addClass("in"),!b)return;e?this.$backdrop.one("bsTransitionEnd",b).emulateTransitionEnd(150):b()}else if(!this.isShown&&this.$backdrop){this.$backdrop.removeClass("in");var f=function(){c.removeBackdrop(),b&&b()};a.support.transition&&this.$element.hasClass("fade")?this.$backdrop.one("bsTransitionEnd",f).emulateTransitionEnd(150):f()}else b&&b()},c.prototype.checkScrollbar=function(){document.body.clientWidth>=window.innerWidth||(this.scrollbarWidth=this.scrollbarWidth||this.measureScrollbar())},c.prototype.setScrollbar=function(){var a=parseInt(this.$body.css("padding-right")||0,10);this.scrollbarWidth&&this.$body.css("padding-right",a+this.scrollbarWidth)},c.prototype.resetScrollbar=function(){this.$body.css("padding-right","")},c.prototype.measureScrollbar=function(){var a=document.createElement("div");a.className="modal-scrollbar-measure",this.$body.append(a);var b=a.offsetWidth-a.clientWidth;return this.$body[0].removeChild(a),b};var d=a.fn.modal;a.fn.modal=b,a.fn.modal.Constructor=c,a.fn.modal.noConflict=function(){return a.fn.modal=d,this},a(document).on("click.bs.modal.data-api",'[data-toggle="modal"]',function(c){var d=a(this),e=d.attr("href"),f=a(d.attr("data-target")||e&&e.replace(/.*(?=#[^\s]+$)/,"")),g=f.data("bs.modal")?"toggle":a.extend({remote:!/#/.test(e)&&e},f.data(),d.data());d.is("a")&&c.preventDefault(),f.one("show.bs.modal",function(a){a.isDefaultPrevented()||f.one("hidden.bs.modal",function(){d.is(":visible")&&d.trigger("focus")})}),b.call(f,g,this)})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.tooltip"),f="object"==typeof b&&b;(e||"destroy"!=b)&&(e||d.data("bs.tooltip",e=new c(this,f)),"string"==typeof b&&e[b]())})}var c=function(a,b){this.type=this.options=this.enabled=this.timeout=this.hoverState=this.$element=null,this.init("tooltip",a,b)};c.VERSION="3.2.0",c.DEFAULTS={animation:!0,placement:"top",selector:!1,template:'',trigger:"hover focus",title:"",delay:0,html:!1,container:!1,viewport:{selector:"body",padding:0}},c.prototype.init=function(b,c,d){this.enabled=!0,this.type=b,this.$element=a(c),this.options=this.getOptions(d),this.$viewport=this.options.viewport&&a(this.options.viewport.selector||this.options.viewport);for(var e=this.options.trigger.split(" "),f=e.length;f--;){var g=e[f];if("click"==g)this.$element.on("click."+this.type,this.options.selector,a.proxy(this.toggle,this));else if("manual"!=g){var h="hover"==g?"mouseenter":"focusin",i="hover"==g?"mouseleave":"focusout";this.$element.on(h+"."+this.type,this.options.selector,a.proxy(this.enter,this)),this.$element.on(i+"."+this.type,this.options.selector,a.proxy(this.leave,this))}}this.options.selector?this._options=a.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},c.prototype.getDefaults=function(){return c.DEFAULTS},c.prototype.getOptions=function(b){return b=a.extend({},this.getDefaults(),this.$element.data(),b),b.delay&&"number"==typeof b.delay&&(b.delay={show:b.delay,hide:b.delay}),b},c.prototype.getDelegateOptions=function(){var b={},c=this.getDefaults();return this._options&&a.each(this._options,function(a,d){c[a]!=d&&(b[a]=d)}),b},c.prototype.enter=function(b){var c=b instanceof this.constructor?b:a(b.currentTarget).data("bs."+this.type);return c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c)),clearTimeout(c.timeout),c.hoverState="in",c.options.delay&&c.options.delay.show?void(c.timeout=setTimeout(function(){"in"==c.hoverState&&c.show()},c.options.delay.show)):c.show()},c.prototype.leave=function(b){var c=b instanceof this.constructor?b:a(b.currentTarget).data("bs."+this.type);return c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c)),clearTimeout(c.timeout),c.hoverState="out",c.options.delay&&c.options.delay.hide?void(c.timeout=setTimeout(function(){"out"==c.hoverState&&c.hide()},c.options.delay.hide)):c.hide()},c.prototype.show=function(){var b=a.Event("show.bs."+this.type);if(this.hasContent()&&this.enabled){this.$element.trigger(b);var c=a.contains(document.documentElement,this.$element[0]);if(b.isDefaultPrevented()||!c)return;var d=this,e=this.tip(),f=this.getUID(this.type);this.setContent(),e.attr("id",f),this.$element.attr("aria-describedby",f),this.options.animation&&e.addClass("fade");var g="function"==typeof this.options.placement?this.options.placement.call(this,e[0],this.$element[0]):this.options.placement,h=/\s?auto?\s?/i,i=h.test(g);i&&(g=g.replace(h,"")||"top"),e.detach().css({top:0,left:0,display:"block"}).addClass(g).data("bs."+this.type,this),this.options.container?e.appendTo(this.options.container):e.insertAfter(this.$element);var j=this.getPosition(),k=e[0].offsetWidth,l=e[0].offsetHeight;if(i){var m=g,n=this.$element.parent(),o=this.getPosition(n);g="bottom"==g&&j.top+j.height+l-o.scroll>o.height?"top":"top"==g&&j.top-o.scroll-l<0?"bottom":"right"==g&&j.right+k>o.width?"left":"left"==g&&j.left-kg.top+g.height&&(e.top=g.top+g.height-i)}else{var j=b.left-f,k=b.left+f+c;jg.width&&(e.left=g.left+g.width-k)}return e},c.prototype.getTitle=function(){var a,b=this.$element,c=this.options;return a=b.attr("data-original-title")||("function"==typeof c.title?c.title.call(b[0]):c.title)},c.prototype.getUID=function(a){do a+=~~(1e6*Math.random());while(document.getElementById(a));return a},c.prototype.tip=function(){return this.$tip=this.$tip||a(this.options.template)},c.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".tooltip-arrow")},c.prototype.validate=function(){this.$element[0].parentNode||(this.hide(),this.$element=null,this.options=null)},c.prototype.enable=function(){this.enabled=!0},c.prototype.disable=function(){this.enabled=!1},c.prototype.toggleEnabled=function(){this.enabled=!this.enabled},c.prototype.toggle=function(b){var c=this;b&&(c=a(b.currentTarget).data("bs."+this.type),c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c))),c.tip().hasClass("in")?c.leave(c):c.enter(c)},c.prototype.destroy=function(){clearTimeout(this.timeout),this.hide().$element.off("."+this.type).removeData("bs."+this.type)};var d=a.fn.tooltip;a.fn.tooltip=b,a.fn.tooltip.Constructor=c,a.fn.tooltip.noConflict=function(){return a.fn.tooltip=d,this}}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.popover"),f="object"==typeof b&&b;(e||"destroy"!=b)&&(e||d.data("bs.popover",e=new c(this,f)),"string"==typeof b&&e[b]())})}var c=function(a,b){this.init("popover",a,b)};if(!a.fn.tooltip)throw new Error("Popover requires tooltip.js");c.VERSION="3.2.0",c.DEFAULTS=a.extend({},a.fn.tooltip.Constructor.DEFAULTS,{placement:"right",trigger:"click",content:"",template:''}),c.prototype=a.extend({},a.fn.tooltip.Constructor.prototype),c.prototype.constructor=c,c.prototype.getDefaults=function(){return c.DEFAULTS},c.prototype.setContent=function(){var a=this.tip(),b=this.getTitle(),c=this.getContent();a.find(".popover-title")[this.options.html?"html":"text"](b),a.find(".popover-content").empty()[this.options.html?"string"==typeof c?"html":"append":"text"](c),a.removeClass("fade top bottom left right in"),a.find(".popover-title").html()||a.find(".popover-title").hide()},c.prototype.hasContent=function(){return this.getTitle()||this.getContent()},c.prototype.getContent=function(){var a=this.$element,b=this.options;return a.attr("data-content")||("function"==typeof b.content?b.content.call(a[0]):b.content)},c.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".arrow")},c.prototype.tip=function(){return this.$tip||(this.$tip=a(this.options.template)),this.$tip};var d=a.fn.popover;a.fn.popover=b,a.fn.popover.Constructor=c,a.fn.popover.noConflict=function(){return a.fn.popover=d,this}}(jQuery),+function(a){"use strict";function b(c,d){var e=a.proxy(this.process,this);this.$body=a("body"),this.$scrollElement=a(a(c).is("body")?window:c),this.options=a.extend({},b.DEFAULTS,d),this.selector=(this.options.target||"")+" .nav li > a",this.offsets=[],this.targets=[],this.activeTarget=null,this.scrollHeight=0,this.$scrollElement.on("scroll.bs.scrollspy",e),this.refresh(),this.process()}function c(c){return this.each(function(){var d=a(this),e=d.data("bs.scrollspy"),f="object"==typeof c&&c;e||d.data("bs.scrollspy",e=new b(this,f)),"string"==typeof c&&e[c]()})}b.VERSION="3.2.0",b.DEFAULTS={offset:10},b.prototype.getScrollHeight=function(){return this.$scrollElement[0].scrollHeight||Math.max(this.$body[0].scrollHeight,document.documentElement.scrollHeight)},b.prototype.refresh=function(){var b="offset",c=0;a.isWindow(this.$scrollElement[0])||(b="position",c=this.$scrollElement.scrollTop()),this.offsets=[],this.targets=[],this.scrollHeight=this.getScrollHeight();var d=this;this.$body.find(this.selector).map(function(){var d=a(this),e=d.data("target")||d.attr("href"),f=/^#./.test(e)&&a(e);return f&&f.length&&f.is(":visible")&&[[f[b]().top+c,e]]||null}).sort(function(a,b){return a[0]-b[0]}).each(function(){d.offsets.push(this[0]),d.targets.push(this[1])})},b.prototype.process=function(){var a,b=this.$scrollElement.scrollTop()+this.options.offset,c=this.getScrollHeight(),d=this.options.offset+c-this.$scrollElement.height(),e=this.offsets,f=this.targets,g=this.activeTarget;if(this.scrollHeight!=c&&this.refresh(),b>=d)return g!=(a=f[f.length-1])&&this.activate(a);if(g&&b<=e[0])return g!=(a=f[0])&&this.activate(a);for(a=e.length;a--;)g!=f[a]&&b>=e[a]&&(!e[a+1]||b<=e[a+1])&&this.activate(f[a])},b.prototype.activate=function(b){this.activeTarget=b,a(this.selector).parentsUntil(this.options.target,".active").removeClass("active");var c=this.selector+'[data-target="'+b+'"],'+this.selector+'[href="'+b+'"]',d=a(c).parents("li").addClass("active");d.parent(".dropdown-menu").length&&(d=d.closest("li.dropdown").addClass("active")),d.trigger("activate.bs.scrollspy")};var d=a.fn.scrollspy;a.fn.scrollspy=c,a.fn.scrollspy.Constructor=b,a.fn.scrollspy.noConflict=function(){return a.fn.scrollspy=d,this},a(window).on("load.bs.scrollspy.data-api",function(){a('[data-spy="scroll"]').each(function(){var b=a(this);c.call(b,b.data())})})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.tab");e||d.data("bs.tab",e=new c(this)),"string"==typeof b&&e[b]()})}var c=function(b){this.element=a(b)};c.VERSION="3.2.0",c.prototype.show=function(){var b=this.element,c=b.closest("ul:not(.dropdown-menu)"),d=b.data("target");if(d||(d=b.attr("href"),d=d&&d.replace(/.*(?=#[^\s]*$)/,"")),!b.parent("li").hasClass("active")){var e=c.find(".active:last a")[0],f=a.Event("show.bs.tab",{relatedTarget:e});if(b.trigger(f),!f.isDefaultPrevented()){var g=a(d);this.activate(b.closest("li"),c),this.activate(g,g.parent(),function(){b.trigger({type:"shown.bs.tab",relatedTarget:e})})}}},c.prototype.activate=function(b,c,d){function e(){f.removeClass("active").find("> .dropdown-menu > .active").removeClass("active"),b.addClass("active"),g?(b[0].offsetWidth,b.addClass("in")):b.removeClass("fade"),b.parent(".dropdown-menu")&&b.closest("li.dropdown").addClass("active"),d&&d()}var f=c.find("> .active"),g=d&&a.support.transition&&f.hasClass("fade");g?f.one("bsTransitionEnd",e).emulateTransitionEnd(150):e(),f.removeClass("in")};var d=a.fn.tab;a.fn.tab=b,a.fn.tab.Constructor=c,a.fn.tab.noConflict=function(){return a.fn.tab=d,this},a(document).on("click.bs.tab.data-api",'[data-toggle="tab"], [data-toggle="pill"]',function(c){c.preventDefault(),b.call(a(this),"show")})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.affix"),f="object"==typeof b&&b;e||d.data("bs.affix",e=new c(this,f)),"string"==typeof b&&e[b]()})}var c=function(b,d){this.options=a.extend({},c.DEFAULTS,d),this.$target=a(this.options.target).on("scroll.bs.affix.data-api",a.proxy(this.checkPosition,this)).on("click.bs.affix.data-api",a.proxy(this.checkPositionWithEventLoop,this)),this.$element=a(b),this.affixed=this.unpin=this.pinnedOffset=null,this.checkPosition()};c.VERSION="3.2.0",c.RESET="affix affix-top affix-bottom",c.DEFAULTS={offset:0,target:window},c.prototype.getPinnedOffset=function(){if(this.pinnedOffset)return this.pinnedOffset;this.$element.removeClass(c.RESET).addClass("affix");var a=this.$target.scrollTop(),b=this.$element.offset();return this.pinnedOffset=b.top-a},c.prototype.checkPositionWithEventLoop=function(){setTimeout(a.proxy(this.checkPosition,this),1)},c.prototype.checkPosition=function(){if(this.$element.is(":visible")){var b=a(document).height(),d=this.$target.scrollTop(),e=this.$element.offset(),f=this.options.offset,g=f.top,h=f.bottom;"object"!=typeof f&&(h=g=f),"function"==typeof g&&(g=f.top(this.$element)),"function"==typeof h&&(h=f.bottom(this.$element));var i=null!=this.unpin&&d+this.unpin<=e.top?!1:null!=h&&e.top+this.$element.height()>=b-h?"bottom":null!=g&&g>=d?"top":!1;if(this.affixed!==i){null!=this.unpin&&this.$element.css("top","");var j="affix"+(i?"-"+i:""),k=a.Event(j+".bs.affix");this.$element.trigger(k),k.isDefaultPrevented()||(this.affixed=i,this.unpin="bottom"==i?this.getPinnedOffset():null,this.$element.removeClass(c.RESET).addClass(j).trigger(a.Event(j.replace("affix","affixed"))),"bottom"==i&&this.$element.offset({top:b-this.$element.height()-h}))}}};var d=a.fn.affix;a.fn.affix=b,a.fn.affix.Constructor=c,a.fn.affix.noConflict=function(){return a.fn.affix=d,this},a(window).on("load",function(){a('[data-spy="affix"]').each(function(){var c=a(this),d=c.data();d.offset=d.offset||{},d.offsetBottom&&(d.offset.bottom=d.offsetBottom),d.offsetTop&&(d.offset.top=d.offsetTop),b.call(c,d)})})}(jQuery);
// source --> https://emsepompa.com.tr/wp-content/themes/wp_spectrum/js/cs_parallax.js
(function($) { "use strict";
jQuery(document).ready(function ($) {
var window_height = $(window).height();
var window_width = $(window).width();
$('.stripe-parallax-bg').each(function () {
var $this = $(this),
element_h = $this.outerHeight(),
background_w = $this.data('background-width'),
background_h = $this.data('background-height'),
ratio = background_w / background_h;
if($this.hasClass('stripe-video-wrap')) return;
var speedFactor = $this.data('stellar-background-ratio');
var backgroundsize = 'background-size:auto ' + background_h + 'px !important';
var parallax_mobile = parseInt($this.data('parallax-mobile'));
var adjustbackground = function(){
window_height = $(window).height();
element_h = $this.outerHeight();
background_h = element_h + (window_height) * (1-speedFactor);
background_w = background_h*ratio;
if(background_w < $this.outerWidth()){
background_w = $this.outerWidth();
background_h = background_w/ratio;
}
backgroundsize = 'background-size:auto ' + background_h + 'px !important';
};
var doScroll = function(){
if(window_width < 768 && parallax_mobile == 1) return;
var delta = Math.round(isappears($this) * (1-speedFactor));
//if (delta > 0) {
var background_y = $this.outerHeight() - background_h + delta;
$this.css('cssText', backgroundsize + ';background-position: 50% ' + background_y + 'px !important;');
//}
};
adjustbackground();
$(window).bind('resize', function () {
adjustbackground();
doScroll();
}).bind('load',function(){
adjustbackground();
doScroll();
}).bind('scroll', doScroll);
});
/*Video parallax*/
$('.stripe-video-wrap').each(function () {
var $this = $(this),$video = $this.find('video'),speedFactor=$(this).data('stellar-background-ratio')||0.7,ratio=0,video_bottom=0;
var video_height = 0;
var el_height = $(this).outerHeight();
if($this.hasClass('stripe-parallax-bg')){
$video.bind('loadeddata', function(){
adjustvideo();
doScroll();
});
var adjustvideo = function(){
ratio = $video.data('ratio');
//video_height = $(window).width() / ratio;
video_height = el_height + (el_height + window_height) * (1 - speedFactor);
if (video_height < $(window).width() / ratio) {
video_height = $(window).width() / ratio
}
$video.css({
'width': video_height * ratio + 'px',
'maxWidth': video_height * ratio + 'px',
bottom: 0
});
}
if (speedFactor == 1) return;
var doScroll = function(){
if ($(window).width() < 768) return;
$video.attr(
{
'appear':isappears($this),
'delta':Math.round(isappears($this) * (1-speedFactor))
}
);
var delta = Math.round(isappears($this) * (1-speedFactor));
$video.css({
bottom: (0 - delta) + 'px'
})
};
adjustvideo();
doScroll();
$(window).bind('scroll', doScroll).bind('resize',function(){
adjustvideo();
doScroll();
});
}
/*Video btn */
if($('.exp-videobg-control-btn',$this).length > 0){
console.log('ok');
var video = $this.find('video');
var content = $this.find('.stripe-video-content');
video.bind("ended", function() {
content.fadeTo( "slow", 1 );
$(this).addClass('video-pause').removeClass('video-play');
});
video.bind("play", function() {
content.fadeTo( "slow", 0 );
$(this).addClass('video-pause').removeClass('video-pause');
});
video.bind("pause", function() {
content.fadeTo( "slow", 1 );
$(this).addClass('video-pause').removeClass('video-play');
});
video.bind("playing", function() {
content.fadeTo( "slow", 0 );
$(this).addClass('video-play').removeClass('video-pause');
});
$('.exp-videobg-control-btn',$this).click(function(e){
//console.log('click button');
e.stopPropagation();
playVideo(video);
})
$('.ww-video-bg,.stripe-video-content,video',$this).click(function(e){
e.stopPropagation();
pauseVideo(video);
})
}
})
function playVideo(video){
if (video.get(0).paused == true) {
video.get(0).play();
} else {
video.get(0).pause();
}
}
function pauseVideo(video){
if (video.get(0).paused != true) {
video.get(0).pause();
}
}
/*End Video btn */
function isappears(element) {
var scrolltop = $(window).scrollTop(),top = $(element).offset().top;
if(top < $(window).height()){
return scrolltop;
}
if ((scrolltop + $(window).height()) >= ($(element).offset().top)) {
return scrolltop + $(window).height() - $(element).offset().top;
}
return 0;
}
});
})(jQuery);
// source --> https://emsepompa.com.tr/wp-content/themes/wp_spectrum/js/megamenu.js
/* Mega menu */
(function ($) {
var menuNav = function ($el, options) {
this.$menu = $($el);
var defaults = {
mobMenuClass: 'mob-nav-menu',
mobPrecedingElSel: '#cshero-main-menu-mobile-bk',
mobBtnSel: '.btn-navbar',
mobArrowClass: 'mob-nav-arrow',
megaMenuClass: 'mega-menu-item',
megaMenuMaxWidth: 1000,
megaMenuColumnWidth: 232
};
this.o = $.extend(defaults, options);
};
var mn = menuNav.prototype;
mn.getBrowser = function () {
var browser = {},
ua,
match,
matched;
if (mn.browser) {
return mn.browser;
}
ua = navigator.userAgent.toLowerCase();
match = /(chrome)[ \/]([\w.]+)/.exec(ua) ||
/(webkit)[ \/]([\w.]+)/.exec(ua) ||
/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(ua) ||
/(msie) ([\w.]+)/.exec(ua) ||
ua.indexOf("compatible") < 0 && /(mozilla)(?:.*? rv:([\w.]+)|)/.exec(ua) || [];
matched = {
browser: match[1] || "",
version: match[2] || "0"
};
if (matched.browser) {
browser[matched.browser] = true;
browser.version = matched.version;
}
// Chrome is Webkit, but Webkit is also Safari.
if (browser.chrome) {
browser.webkit = true;
} else if (browser.webkit) {
browser.safari = true;
}
mn.browser = browser;
return browser;
}
mn.init = function () {
var self = this,
browser = mn.getBrowser();
self.$win = $(window);
self.win_width = self.$win.width();
self.$body = $('body');
self.$mainUl = self.$menu.find('ul:first');
self.isIE9 = browser.msie && parseInt(browser.version, 10) == 9;
if (self.$menu.is(':visible')) {
//init the main navigation functionality
self.initMain();
} else {
$(window).on('resize.pexetodropdown', function () {
if (self.$menu.is(':visible')) {
self.initMain();
$(window).off('.pexetodropdown');
}
});
}
};
/**
* Inits the main navigation functionality with the drop-down menus on
* hover.
*/
mn.initMain = function () {
var self = this,
menuPosition = 'left';
if (self.$menu.hasClass('center')) {
menuPosition = 'center';
} else if (self.$menu.hasClass('right')||self.$menu.hasClass('pull-right')) {
menuPosition = 'right';
}
this.menuPosition = menuPosition;
//bind the mouseover events
self.$menu.find('ul li').has('ul').not('ul li.mega-menu-item li').each(function () {
$(this).hover(function () {
self.doOnMenuMouseover($(this));
}, function () {
self.doOnMenuMouseout($(this));
});
});
self.$menu.find('a[href="#"]').on('click', function (e) {
e.preventDefault();
});
this.initMegaMenu();
};
mn.initMegaMenu = function () {
this.$megaUls = this.$menu.find('ul li.' + this.o.megaMenuClass).has('ul').children('ul');
if (this.$megaUls.length) {
if (this.$menu.parents('#cshero-header').length) {
this.$parentWrapper = this.$menu.parents('#cshero-header');
} else if (this.$menu.parents('.sticky-wrapper').length) {
this.$parentWrapper = this.$menu.parents('.sticky-wrapper');
} else {
this.$parentWrapper = this.$menu.parents('.container');
}
this.$win.on('pexetoresize', $.proxy(this.setMegaMenuWidth, this));
this.setMegaMenuWidth();
}
};
mn.setMegaMenuMaxWidth = function () {
var maxWidth = 0;
switch (this.menuPosition) {
case 'right':
if (!this.lastMenuLi) {
this.lastMenuLi = this.$menu.find('ul:first>li:last');
}
if (this.isIE9) {
this.lastMenuLi.offset();
}
maxWidth = this.lastMenuLi.offset().left + this.lastMenuLi.width() - this.$parentWrapper.offset().left;
break;
case 'left':
maxWidth = this.$parentWrapper.width();
break;
case 'center':
maxWidth = this.$parentWrapper.width();
break;
}
this.megaMenuMaxWidth = Math.min(this.o.megaMenuMaxWidth, maxWidth);
};
mn.setMegaMenuWidth = function () {
var self = this;
this.setMegaMenuMaxWidth();
this.mainUlWidth = this.$mainUl.width();
this.$megaUls.each(function () {
$(this).addClass('colimdi');
var $ul = $(this),
liNum = $ul.children('li').length,
width,
colsToFit;
if (liNum > 0) {
if (self.o.megaMenuMaxWidth < liNum * self.o.megaMenuColumnWidth) {
colsToFit = Math.floor(self.megaMenuMaxWidth / self.o.megaMenuColumnWidth) || 1;
width = colsToFit * self.o.megaMenuColumnWidth;
} else {
width = liNum * self.o.megaMenuColumnWidth;
colsToFit = liNum;
}
if (this.lastMegaClass) {
$ul.removeClass(this.lastMegaClass);
}
this.lastMegaClass = 'mega-columns-' + colsToFit;
$ul.width(width)
.addClass(this.lastMegaClass);
self.setMegaMenuPosition($ul, width);
}
});
}
mn.setMegaMenuPosition = function ($ul, ulWidth) {
var left,
right,
$li,
centerPosition,
shortestEndDistance;
$li = $ul.parents('li:first');
var $li_left = $li.offset().left + $li.outerWidth();
var $li_right = (jQuery(window).width() - $li.offset().left);
if (ulWidth >= this.mainUlWidth) {
//the mega drop-down is bigger than the parent menu
switch (this.menuPosition) {
case 'right':
//align right
if($li_left < ulWidth){
right = ulWidth - $li_left - 20;
}else{
right = 0;
}
$ul.css({
left: 'auto',
right: -right
});
break;
case 'left':
//align left
if($li_right < ulWidth){
left = ulWidth - $li_right - 20;
}else{
left = 0;
}
$ul.css({
left: -left
});
break;
case 'center':
left = -(ulWidth - this.mainUlWidth) / 2;
$ul.css({
left: left
});
break;
}
} else {
centerPosition = $li.offset().left + $li.width() / 2;
if (ulWidth / 2 <= centerPosition) {
//center
left = ulWidth / 2;
$ul.css({
left: -left
});
} else {
if (centerPosition <= this.mainUlWidth - centerPosition) {
//align left
$ul.css({
left: 0
});
} else {
//align right
$ul.css({
left: 'auto',
right: 0
});
}
}
}
};
/**
* Displays the drop-down menu on mouse over.
* @param {object} $li the hovered element - jQuery object
*/
mn.doOnMenuMouseover = function ($li) {
$(window).trigger('scroll');
var self = this,
$ul = $li.find('ul:first'),
parentUlNum = $ul.parents('ul').length,
elWidth = $li.width(),
ulWidth = $ul.width(),
winWidth = self.$win.width(),
elOffset = $li.offset().left;
$li.addClass('hovered');
if (self.menuPosition == 'right' && !$li.hasClass(self.o.megaMenuClass)) {
if (parentUlNum > 1 && (elWidth + ulWidth + elOffset > winWidth)) {
//if the drop down ul goes beyound the screen, move it on the left side
$ul.css({
left: -elWidth
});
} else if (parentUlNum === 1) {
if (ulWidth + elOffset > winWidth) {
$ul.css({
left: (winWidth - 3 - (ulWidth + elOffset))
});
} else {
$ul.css({
left: 0
});
}
}
}
/* display the drop-down */
$ul.stop().fadeIn(300);
};
/**
* Hides the drop-down on mouse out.
* @param {object} $li the hovered li element - jQuery object
*/
mn.doOnMenuMouseout = function ($li) {
var $ul = $li.find('ul:first');
$li.removeClass('hovered');
$ul.stop().fadeOut(0);
};
$.fn.menuNav = function ($opt) {
return this.each(function () {
new menuNav(this).init();
});
};
$(document).ready(function(){
//setTimeout(function(){$('.cs_mega_menu').menuNav();},1000);
});
})(jQuery);
// source --> https://emsepompa.com.tr/wp-content/themes/wp_spectrum/js/jquery.mousewheel.min.js
/*! Copyright (c) 2013 Brandon Aaron (http://brandon.aaron.sh)
* Licensed under the MIT License (LICENSE.txt).
*
* Version: 3.1.12
*
* Requires: jQuery 1.2.2+
*/
!function(a){"function"==typeof define&&define.amd?define(["jquery"],a):"object"==typeof exports?module.exports=a:a(jQuery)}(function(a){function b(b){var g=b||window.event,h=i.call(arguments,1),j=0,l=0,m=0,n=0,o=0,p=0;if(b=a.event.fix(g),b.type="mousewheel","detail"in g&&(m=-1*g.detail),"wheelDelta"in g&&(m=g.wheelDelta),"wheelDeltaY"in g&&(m=g.wheelDeltaY),"wheelDeltaX"in g&&(l=-1*g.wheelDeltaX),"axis"in g&&g.axis===g.HORIZONTAL_AXIS&&(l=-1*m,m=0),j=0===m?l:m,"deltaY"in g&&(m=-1*g.deltaY,j=m),"deltaX"in g&&(l=g.deltaX,0===m&&(j=-1*l)),0!==m||0!==l){if(1===g.deltaMode){var q=a.data(this,"mousewheel-line-height");j*=q,m*=q,l*=q}else if(2===g.deltaMode){var r=a.data(this,"mousewheel-page-height");j*=r,m*=r,l*=r}if(n=Math.max(Math.abs(m),Math.abs(l)),(!f||f>n)&&(f=n,d(g,n)&&(f/=40)),d(g,n)&&(j/=40,l/=40,m/=40),j=Math[j>=1?"floor":"ceil"](j/f),l=Math[l>=1?"floor":"ceil"](l/f),m=Math[m>=1?"floor":"ceil"](m/f),k.settings.normalizeOffset&&this.getBoundingClientRect){var s=this.getBoundingClientRect();o=b.clientX-s.left,p=b.clientY-s.top}return b.deltaX=l,b.deltaY=m,b.deltaFactor=f,b.offsetX=o,b.offsetY=p,b.deltaMode=0,h.unshift(b,j,l,m),e&&clearTimeout(e),e=setTimeout(c,200),(a.event.dispatch||a.event.handle).apply(this,h)}}function c(){f=null}function d(a,b){return k.settings.adjustOldDeltas&&"mousewheel"===a.type&&b%120===0}var e,f,g=["wheel","mousewheel","DOMMouseScroll","MozMousePixelScroll"],h="onwheel"in document||document.documentMode>=9?["wheel"]:["mousewheel","DomMouseScroll","MozMousePixelScroll"],i=Array.prototype.slice;if(a.event.fixHooks)for(var j=g.length;j;)a.event.fixHooks[g[--j]]=a.event.mouseHooks;var k=a.event.special.mousewheel={version:"3.1.12",setup:function(){if(this.addEventListener)for(var c=h.length;c;)this.addEventListener(h[--c],b,!1);else this.onmousewheel=b;a.data(this,"mousewheel-line-height",k.getLineHeight(this)),a.data(this,"mousewheel-page-height",k.getPageHeight(this))},teardown:function(){if(this.removeEventListener)for(var c=h.length;c;)this.removeEventListener(h[--c],b,!1);else this.onmousewheel=null;a.removeData(this,"mousewheel-line-height"),a.removeData(this,"mousewheel-page-height")},getLineHeight:function(b){var c=a(b),d=c["offsetParent"in a.fn?"offsetParent":"parent"]();return d.length||(d=a("body")),parseInt(d.css("fontSize"),10)||parseInt(c.css("fontSize"),10)||16},getPageHeight:function(b){return a(b).height()},settings:{adjustOldDeltas:!0,normalizeOffset:!0}};a.fn.extend({mousewheel:function(a){return a?this.bind("mousewheel",a):this.trigger("mousewheel")},unmousewheel:function(a){return this.unbind("mousewheel",a)}})});
// source --> https://emsepompa.com.tr/wp-content/themes/wp_spectrum/js/main.js
/*
* CS Hero
*
*/
(function ($) {
"use strict";
/*same height*/
function sameHeight() {
"use strict";
var biggestHeight = 0;
$('.sameheight article').each(function () {
if ($(this).height() > biggestHeight) {
biggestHeight = $(this).height();
}
});
$('.sameheight article').height(biggestHeight);
}
function fullWidth() {
var windowWidth = $(window).width();
$('.stripe').each(function () {
var $bgobj = $(this);
var width = $bgobj.width();
var v = (windowWidth - width) / 2;
$bgobj.css({
marginLeft: -v,
paddingLeft: v,
paddingRight: v
});
})
}
function boxed() {
var windowWidth = $(window).width();
$('.stripe').each(function () {
$(this).css({
marginLeft: 0,
paddingLeft: 0,
paddingRight: 0
});
})
}
$(document).ready(function () {
/* Menu */
var depth = 0;
var el = null;
var w_width = jQuery(window).width();
jQuery('li.menu-item').hover(function(){
el = jQuery('.sub-menu:first',this);
if(el.length > 0){
var el_left = el.offset().left;
var el_width = el.outerWidth();
if(w_width < (el_left+el_width)){
el.addClass('autodrop');
}
}
},function(){
if(el){
el.removeClass('autodrop');
el = null;
}
})
/* End Menu */
/** Active Arrow Menu Mobile ***/
$('.btn-navbar').click(function () {
$("#cshero-header").toggleClass("mobile-arrow-effect");
})
/*** Portfolio Style 4 ***/
$(".portfolio-layout4 .cshero-portfolio-item:odd .portfolio-layout4-custom").addClass("row-right");
if ($(".colorbox").length > 0) {
$(".colorbox").colorbox();
}
if ($(".cs-colorbox-post-video").length > 0) {
$(".cs-colorbox-post-video").colorbox({
iframe: true,
innerWidth: 640,
innerHeight: 390
});
}
if ($(".cs-colorbox-post-gallery").length > 0) {
var pid = $(".cs-colorbox-post-gallery").data('sid');
$(".cs-colorbox-post-gallery").colorbox({
html: ""
});
}
setTimeout(function () {
$('.widget_searchform_content').each(function () {
var wg = $(this);
var offset = wg.offset().left + wg.outerWidth() - $(window).width();
if (offset > 0) {
wg.css({
left: 0 - offset
});
}
})
}, 1000)
$('.smooth2pager').click(function () {
var selector = $(this).data('el-selector');
var top = $(selector).offset().top;
$("html,body").animate({
scrollTop: top
}, 500);
})
var $mainmenu = $('.main-menu-content .cshero-dropdown');
var $stickymenu = $('.sticky-menu .cshero-mobile > ul');
var $mobilemenu = $mainmenu.clone().removeClass('main-menu menu-item-padding right left').addClass('cshero-mobile-menu');
$mobilemenu.find('li').each(function () {
var $this = $(this);
if ($this.find('ul').length > 0) {
var $menutoggle = $('');
$menutoggle.bind('click', function () {
$this.toggleClass('open')
});
$this.append($menutoggle);
}
});
$mobilemenu.appendTo('#cshero-main-menu-mobile');
var $mobilesticky = $mobilemenu.clone(true);
$mobilesticky.find('li').each(function () {
var $this = $(this);
if ($this.find('ul').length > 0) {
var $menutoggle = $('');
$menutoggle.bind('click', function () {
$this.toggleClass('open')
});
$this.append($menutoggle);
}
});
$mobilesticky.appendTo('#cshero-sticky-menu-mobile');
/* Show Tooltip */
$('[data-rel="tooltip"]').tooltip();
/* Back to top */
var window_height = $(window).height();
var back_to_top = $('#back_to_top');
var mainmenu = $('#cshero-header');
var menu_top = $('#cs-header-custom-bottom');
if (menu_top.length > 0) {
menu_top.addClass('menu-up');
}
$(window).scroll(function () {
/* fixed menu */
var scroll_top = $(window).scrollTop();
if (menu_top.length > 0) {
if (scroll_top >= menu_top.outerHeight(true)) {
menu_top.find('#menu').removeClass('menu-up');
} else {
menu_top.find('#menu').addClass('menu-up');
}
if (scroll_top >= (mainmenu.outerHeight() - menu_top.outerHeight(true))) {
menu_top.addClass('fixed-top');
} else {
menu_top.removeClass('fixed-top');
}
}
/* back to top */
if (scroll_top < window_height) {
back_to_top.addClass('off').removeClass('on');
} else {
back_to_top.removeClass('off').addClass('on');
}
});
back_to_top.click(function () {
$("html, body").animate({
scrollTop: 0
}, 1500);
});
/* Fix Column Height */
$('.feature-box').each(function () {
var subs = $(this).find('> .column_container');
if (subs.length < 2)
return;
var maxHeight = Math.max.apply(null, $(this).find("> .column_container").map(function () {
return $(this).height();
}).get());
$(this).find("> .column_container").height(maxHeight - 3);
});
/* Parallax Section */
var windowHeight = $(window).height();
fullWidth();
$('.wpb_row').each(function () {
if ($(this).hasClass('ww-same-height')) {
var height = $(this).height();
$(this).children(":first").children().each(function () {
$(this).css('min-height', height);
});
}
});
//Fade out Title Bar on Scroll
var item_height = $(".cs-page-title").outerHeight(true);
var position = $(".cs-page-title").position();
var title_animate = $("#title-animate,#breadcrumb-animate");
$(window).scroll(function () {
if (position) {
var scroll = $(window).scrollTop();
var max = position.top + item_height;
if (scroll <= max) {
var opacity = scroll / item_height;
title_animate.css("opacity", 1 - opacity);
} else {
title_animate.css("opacity", opacity);
}
}
});
/** row col same height */
$('.vc_row-o-equal-height').each(function() {
"use strict";
var same_height = 0;
var col_items = $(this).find('.vc_column-inner');
col_items.each(function (key) {
"use strict";
var col_height = $(this).outerHeight(true);
var col_style = $(this).attr('style');
if(key == 0){
same_height = col_height;
} else {
if(same_height < col_height){
same_height = col_height;
}
}
});
if(same_height > 0){
col_items.css({height:same_height});
}
});
$(".cs-masonry-layout").each(function () {
$(this).imagesLoaded(function () {
var $container = $(this);
var $column = $(this).data('columns');
var colW = Math.floor($container.width() / $column);
$container.css({
width: colW * $column
}).isotope({
itemSelector: '.cs-masonry-layout-item',
masonry: {
columnWidth: colW
}
});
var $filter = $(this).parent().find('.filter');
if ($filter.length > 0) {
$filter.on('click', function () {
$filter.removeClass('active');
$(this).addClass('active');
var filterValue = $(this).attr('data-filter');
if (filterValue != '*') {
$('.cs_pagination').css('display', 'none');
} else {
$('.cs_pagination').css('display', 'block');
}
$(".cs-masonry-layout").isotope({
filter: filterValue
});
});
}
});
});
$('.header-v4 #cshero-header').bind('mousewheel', function(event) {
event.preventDefault();
var scrollTop = this.scrollTop;
this.scrollTop = (scrollTop + ((event.deltaY * event.deltaFactor) * -1));
});
//Woo button
$('.minus').click(function(){
$(this).parent().find('input[type="number"]').get(0).stepDown();
});
$('.plus').click(function(){
$(this).parent().find('input[type="number"]').get(0).stepUp();
});
// Placeholder Input Cart Search
$('.widget_searchform_content').find("input[type='text']").each(function(ev) {
if(!$(this).val()) {
$(this).attr("placeholder", "Search for item");
}
});
$('.header-v5 .cshero-header-content-widget').find("input[type='text']").each(function(ev) {
if(!$(this).val()) {
$(this).attr("placeholder", "Search for item");
}
});
$('.scroll-to-content').on('click', function(e) {
var id_scroll = $(this).attr('href');
var sticky_height = $('.header-fixed').height();
e.preventDefault();
$("html, body").animate({ scrollTop: $(id_scroll).offset().top - 30 }, 800);
});
/* Angle Full Row */
var w_angle_desktop = $(window).width();
var w_angle_margin = (w_angle_desktop)/2;
$('.vc_row .wpb_column.vc_col-sm-6:nth-child(2) .cms-angle-wrapper').css('margin-left',-w_angle_margin+'px');
$('.vc_row .wpb_column.vc_col-sm-6:nth-child(2) .cms-angle-wrapper').css('width',w_angle_desktop+'px');
var w_angle_margin_1col = (w_angle_desktop - 1170)/2;
$('.vc_row[data-vc-full-width]:not(.vc_row-no-padding) .wpb_column.vc_col-sm-12 .cms-angle-wrapper').css('margin-left',-w_angle_margin_1col+'px');
$('.vc_row[data-vc-full-width]:not(.vc_row-no-padding) .wpb_column.vc_col-sm-12 .cms-angle-wrapper').css('width',w_angle_desktop+'px');
/* Row Offset */
if($(window).width() > 768) {
var w_desktop = $(window).width();
var w_padding = (w_desktop - 1140)/2;
$('.section-offset-left > .vc_column-inner').css('padding-left',w_padding+'px');
$('.section-offset-right > .vc_column-inner').css('padding-right',w_padding+'px');
}
});
})(jQuery);
// source --> https://emsepompa.com.tr/wp-content/themes/wp_spectrum/js/jquery.easing.min.js
/*
* jQuery Easing v1.3 - http://gsgd.co.uk/sandbox/jquery/easing/
*
* Uses the built in easing capabilities added In jQuery 1.1
* to offer multiple easing options
*
* TERMS OF USE - jQuery Easing
*
* Open source under the BSD License.
*
* Copyright © 2008 George McGinley Smith
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without modification,
* are permitted provided that the following conditions are met:
*
* Redistributions of source code must retain the above copyright notice, this list of
* conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice, this list
* of conditions and the following disclaimer in the documentation and/or other materials
* provided with the distribution.
*
* Neither the name of the author nor the names of contributors may be used to endorse
* or promote products derived from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
* COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
* GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
* AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
* OF THE POSSIBILITY OF SUCH DAMAGE.
*
*/
jQuery.easing["jswing"]=jQuery.easing["swing"];jQuery.extend(jQuery.easing,{def:"easeOutQuad",swing:function(a,b,c,d,e){return jQuery.easing[jQuery.easing.def](a,b,c,d,e)},easeInQuad:function(a,b,c,d,e){return d*(b/=e)*b+c},easeOutQuad:function(a,b,c,d,e){return-d*(b/=e)*(b-2)+c},easeInOutQuad:function(a,b,c,d,e){if((b/=e/2)<1)return d/2*b*b+c;return-d/2*(--b*(b-2)-1)+c},easeInCubic:function(a,b,c,d,e){return d*(b/=e)*b*b+c},easeOutCubic:function(a,b,c,d,e){return d*((b=b/e-1)*b*b+1)+c},easeInOutCubic:function(a,b,c,d,e){if((b/=e/2)<1)return d/2*b*b*b+c;return d/2*((b-=2)*b*b+2)+c},easeInQuart:function(a,b,c,d,e){return d*(b/=e)*b*b*b+c},easeOutQuart:function(a,b,c,d,e){return-d*((b=b/e-1)*b*b*b-1)+c},easeInOutQuart:function(a,b,c,d,e){if((b/=e/2)<1)return d/2*b*b*b*b+c;return-d/2*((b-=2)*b*b*b-2)+c},easeInQuint:function(a,b,c,d,e){return d*(b/=e)*b*b*b*b+c},easeOutQuint:function(a,b,c,d,e){return d*((b=b/e-1)*b*b*b*b+1)+c},easeInOutQuint:function(a,b,c,d,e){if((b/=e/2)<1)return d/2*b*b*b*b*b+c;return d/2*((b-=2)*b*b*b*b+2)+c},easeInSine:function(a,b,c,d,e){return-d*Math.cos(b/e*(Math.PI/2))+d+c},easeOutSine:function(a,b,c,d,e){return d*Math.sin(b/e*(Math.PI/2))+c},easeInOutSine:function(a,b,c,d,e){return-d/2*(Math.cos(Math.PI*b/e)-1)+c},easeInExpo:function(a,b,c,d,e){return b==0?c:d*Math.pow(2,10*(b/e-1))+c},easeOutExpo:function(a,b,c,d,e){return b==e?c+d:d*(-Math.pow(2,-10*b/e)+1)+c},easeInOutExpo:function(a,b,c,d,e){if(b==0)return c;if(b==e)return c+d;if((b/=e/2)<1)return d/2*Math.pow(2,10*(b-1))+c;return d/2*(-Math.pow(2,-10*--b)+2)+c},easeInCirc:function(a,b,c,d,e){return-d*(Math.sqrt(1-(b/=e)*b)-1)+c},easeOutCirc:function(a,b,c,d,e){return d*Math.sqrt(1-(b=b/e-1)*b)+c},easeInOutCirc:function(a,b,c,d,e){if((b/=e/2)<1)return-d/2*(Math.sqrt(1-b*b)-1)+c;return d/2*(Math.sqrt(1-(b-=2)*b)+1)+c},easeInElastic:function(a,b,c,d,e){var f=1.70158;var g=0;var h=d;if(b==0)return c;if((b/=e)==1)return c+d;if(!g)g=e*.3;if(h https://emsepompa.com.tr/wp-content/themes/wp_spectrum/js/jquery.nav.js
/*
* jQuery One Page Nav Plugin
* http://github.com/davist11/jQuery-One-Page-Nav
*
* Copyright (c) 2010 Trevor Davis (http://trevordavis.net)
* Dual licensed under the MIT and GPL licenses.
* Uses the same license as jQuery, see:
* http://jquery.org/license
*
* @version 3.0.0
*
* Example usage:
* $('#nav').onePageNav({
* currentClass: 'current',
* changeHash: false,
* scrollSpeed: 750
* });
*/
;(function($, window, document, undefined){
// our plugin constructor
var OnePageNav = function(elem, options){
this.elem = elem;
this.$elem = $(elem);
this.options = options;
this.metadata = this.$elem.data('plugin-options');
this.$win = $(window);
this.sections = {};
this.didScroll = false;
this.$doc = $(document);
this.docHeight = this.$doc.height();
};
// the plugin prototype
OnePageNav.prototype = {
defaults: {
navItems: 'a',
currentClass: 'current',
changeHash: false,
easing: 'swing',
filter: '',
scrollSpeed: 750,
scrollThreshold: 0.5,
scrollOffset: 0,
begin: false,
end: false,
scrollChange: false
},
init: function() {
// Introduce defaults that can be extended either
// globally or using an object literal.
this.config = $.extend({}, this.defaults, this.options, this.metadata);
this.$nav = this.$elem.find(this.config.navItems);
//Filter any links out of the nav
if(this.config.filter !== '') {
this.$nav = this.$nav.filter(this.config.filter);
}
//Handle clicks on the nav
this.$nav.on('click.onePageNav', $.proxy(this.handleClick, this));
//Get the section positions
this.getPositions();
//Handle scroll changes
this.bindInterval();
//Update the positions on resize too
this.$win.on('resize.onePageNav', $.proxy(this.getPositions, this));
return this;
},
adjustNav: function(self, $parent) {
self.$elem.find('.' + self.config.currentClass).removeClass(self.config.currentClass);
$parent.addClass(self.config.currentClass);
},
bindInterval: function() {
var self = this;
var docHeight;
self.$win.on('scroll.onePageNav', function() {
self.didScroll = true;
});
self.t = setInterval(function() {
docHeight = self.$doc.height();
//If it was scrolled
if(self.didScroll) {
self.didScroll = false;
self.scrollChange();
}
//If the document height changes
if(docHeight !== self.docHeight) {
self.docHeight = docHeight;
self.getPositions();
}
}, 250);
},
getHash: function($link) {
var url = $link.attr('href');
if(url != undefined){
return url.split('#')[1];
}
},
getPositions: function() {
var self = this;
var linkHref;
var topPos;
var $target;
self.$nav.each(function() {
linkHref = self.getHash($(this));
$target = $('#' + linkHref);
if($target.length) {
topPos = $target.offset().top;
self.sections[linkHref] = Math.round(topPos);
}
});
},
getSection: function(windowPos) {
var returnValue = null;
var windowHeight = Math.round(this.$win.height() * this.config.scrollThreshold);
for(var section in this.sections) {
if((this.sections[section] - windowHeight) < windowPos) {
returnValue = section;
}
}
return returnValue;
},
handleClick: function(e) {
var self = this;
var $link = $(e.currentTarget);
var $parent = $link.parent();
var newLoc = '#' + self.getHash($link);
//Start callback
if(self.config.begin) {
self.config.begin();
}
//Change the highlighted nav item
self.adjustNav(self, $parent);
//Removing the auto-adjust on scroll
self.unbindInterval();
//Scroll to the correct position
self.scrollTo(newLoc, function() {
//Do we need to change the hash?
if(self.config.changeHash) {
window.location.hash = newLoc;
}
//Add the auto-adjust on scroll back in
self.bindInterval();
//End callback
if(self.config.end) {
self.config.end();
}
});
e.preventDefault();
},
scrollChange: function() {
var windowTop = this.$win.scrollTop();
var position = this.getSection(windowTop);
var $parent;
//If the position is set
if(position !== null) {
$parent = this.$elem.find('a[href$="#' + position + '"]').parent();
//If it's not already the current section
if(!$parent.hasClass(this.config.currentClass)) {
//Change the highlighted nav item
this.adjustNav(this, $parent);
//If there is a scrollChange callback
if(this.config.scrollChange) {
this.config.scrollChange($parent);
}
}
}
},
scrollTo: function(target, callback) {
var row_offset = $(target).attr('data-offset');
if(row_offset != '' && row_offset != undefined){
row_offset = parseInt(row_offset);
} else {
row_offset = this.config.scrollOffset;
}
var offset = $(target).offset().top;
$('html, body').animate({
scrollTop: offset + row_offset
}, this.config.scrollSpeed, this.config.easing, callback);
},
unbindInterval: function() {
clearInterval(this.t);
this.$win.unbind('scroll.onePageNav');
}
};
OnePageNav.defaults = OnePageNav.prototype.defaults;
$.fn.onePageNav = function(options) {
return this.each(function() {
new OnePageNav(this, options).init();
});
};
})( jQuery, window , document );