Current Path : /storage/v11800/affypharma/public_html/wp-content/plugins/bdthemes-element-pack/assets/vendor/js/

Linux v11800 5.3.0-1023-aws #25~18.04.1-Ubuntu SMP Fri Jun 5 15:19:18 UTC 2020 aarch64

Upload File :
Current File : /storage/v11800/affypharma/public_html/wp-content/plugins/bdthemes-element-pack/assets/vendor/js/pageable.min.js
!function(t,i){var e="Pageable";"object"==typeof exports?module.exports=i():"function"==typeof define&&define.amd?define([],i):t[e]=i()}("undefined"!=typeof global?global:this.window||this.global,function(){"use strict";var o=function(){},s=function(t){this.instance=t,this.running=!1,this.config=this.instance.config.slideshow};s.prototype.start=function(){var t=this;t.running||(t.running=!0,t.instance.slideIndex=t.instance.index,t.instance.interval=setInterval(function(){t.instance.config.onBeforeStart.call(t.instance,t.instance.slideIndex),setTimeout(function(){t.instance.config.infinite&&t.instance._overScroll(!0),t.instance.index<t.instance.pages.length-1?t.instance.slideIndex++:t.instance.slideIndex=0,t.instance.scrollToIndex(t.instance.slideIndex)},t.config.delay||0)},t.config.interval))},s.prototype.stop=function(){this.running&&(clearInterval(this.instance.interval),this.instance.slideInterval=!1,this.running=!1)};var t=function(t,i){if(void 0===t)return console.error("Pageable:","No container defined.");var s=this,e={pips:!0,animation:300,delay:0,throttle:50,orientation:"vertical",easing:function(t,i,e,s,n){return-e*(t/=s)*(t-2)+i},onInit:o,onUpdate:o,onBeforeStart:o,onStart:o,onScroll:o,onFinish:o,swipeThreshold:50,freeScroll:!1,slideshow:!1,infinite:!1,events:{wheel:!0,mouse:!0,touch:!0}};if(this.container="string"==typeof t?document.querySelector(t):t,!this.container)return console.error("Pageable:","The container could not be found.");if(this.config=function t(i,e){for(var s in e)if(e.hasOwnProperty(s)){var n=e[s];n&&(o=n,"[object Object]"===Object.prototype.toString.call(o))?(i[s]=i[s]||{},t(i[s],n)):i[s]=n}var o;return i}(e,i),this.events=this.config.events,this.config.anchors&&Array.isArray(this.config.anchors)){var n=document.createDocumentFragment();this.config.anchors.forEach(function(t){var i=document.createElement("div");i.dataset.anchor=t,n.appendChild(i)}),this.container.appendChild(n)}if(this.pages=this.container.querySelectorAll("[data-anchor]"),!this.pages.length)return console.error("Pageable:","No child nodes with the [data-anchor] attribute could be found.");this.horizontal="horizontal"===this.config.orientation,this.anchors=[],this.pages.forEach(function(t,i){var e=t.dataset.anchor.replace(/\s+/,"-").toLowerCase();t.id!==e&&(t.id=e),s.anchors.push("#"+e),t.classList.add("pg-page"),t.classList.toggle("pg-active",0==i)}),this.axis=this.horizontal?"x":"y",this.mouseAxis={x:"clientX",y:"clientY"},this.scrollAxis={x:"scrollLeft",y:"scrollTop"},this.size={x:"width",y:"height"},this.bar=this._getScrollBarWidth(),this.index=0,this.slideIndex=0,this.oldIndex=0,this.down=!1,this.initialised=!1,this.touch="ontouchstart"in window||window.DocumentTouch&&document instanceof DocumentTouch,this.init()};return t.prototype.init=function(){if(!this.initialised&&!this.container.pageable){var e=this.config;if(this.wrapper=document.createElement("div"),this.container.parentNode.insertBefore(this.wrapper,this.container),this.wrapper.appendChild(this.container),this.wrapper.classList.add("pg-wrapper","pg-"+e.orientation),this.wrapper.classList.add("pg-wrapper"),this.container.classList.add("pg-container"),document.body.style.margin=0,document.body.style.overflow="hidden",this.container.style.display="inline-block",["Prev","Next"].forEach(function(t){var i="nav"+t+"El";e[i]&&("string"==typeof e[i]?this[i]=document.querySelector(e[i]):e[i]instanceof Element&&(this[i]=e[i]),this[i]&&this[i].classList.add("pg-nav"))},this),e.pips){var t=document.createElement("nav"),o=document.createElement("ul");t.classList.add("pg-pips"),this.pages.forEach(function(t,i){var e=document.createElement("li"),s=document.createElement("a"),n=document.createElement("span");s.href="#"+t.id,0==i&&s.classList.add("active"),s.appendChild(n),e.appendChild(s),o.appendChild(e)}),t.appendChild(o),this.wrapper.appendChild(t),this.pips=Array.from(o.children)}this.pageCount=this.pages.length,this.lastIndex=this.pageCount-1,e.infinite&&this._toggleInfinite(!1,!0),this.bind(),this.update(),this._load();var i=this._getData();this.config.onInit.call(this,i),this.emit("init",i),this.initialised=!0,this.container.pageable=this,e.slideshow&&(this.slider=new s(this),this.slider.start())}},t.prototype.bind=function(){this.callbacks={wheel:this._wheel.bind(this),update:function(t,i,e){var s;return function(){if(e=e||this,!s)return t.apply(e,arguments),s=!0,setTimeout(function(){s=!1},i)}}(this.update.bind(this),this.config.throttle),load:this._load.bind(this),start:this._start.bind(this),drag:this._drag.bind(this),stop:this._stop.bind(this),click:this._click.bind(this),prev:this.prev.bind(this),next:this.next.bind(this),keydown:this._keydown.bind(this)},this.wrapper.addEventListener("wheel",this.callbacks.wheel,!1),window.addEventListener("resize",this.callbacks.update,!1),document.addEventListener("keydown",this.callbacks.keydown,!1),this.wrapper.addEventListener(this.touch?"touchstart":"mousedown",this.callbacks.start,!1),window.addEventListener(this.touch?"touchmove":"mousemove",this.callbacks.drag,!1),window.addEventListener(this.touch?"touchend":"mouseup",this.callbacks.stop,!1),this.navPrevEl&&(this.navPrevEl.addEventListener("click",this.callbacks.prev,!1),this.navNextEl&&this.navNextEl.addEventListener("click",this.callbacks.next,!1)),document.addEventListener("click",this.callbacks.click,!1)},t.prototype.unbind=function(){this.wrapper.removeEventListener("wheel",this.callbacks.wheel),window.removeEventListener("resize",this.callbacks.update),this.wrapper.removeEventListener(this.touch?"touchstart":"mousedown",this.callbacks.start),window.addEventListener(this.touch?"touchmove":"mousemove",this.callbacks.drag),window.removeEventListener(this.touch?"touchend":"mouseup",this.callbacks.stop),document.addEventListener("keydown",this.callbacks.keydown,!1),this.navPrevEl&&this.navPrevEl.removeEventListener("click",this.callbacks.prev,!1),this.navNextEl&&this.navNextEl.removeEventListener("click",this.callbacks.next,!1),document.removeEventListener("click",this.callbacks.click)},t.prototype.scrollToPage=function(t){this.scrollToIndex(t-1)},t.prototype.scrollToAnchor=function(t){this.scrollToIndex(this.anchors.indexOf(t))},t.prototype.scrollToIndex=function(t){if(!this.scrolling&&0<=t&&t<=this.pages.length-1){var i=this.index;this.index=t,this.oldIndex=i,this._scrollBy(this._getScrollAmount(i))}},t.prototype.next=function(){if(this.config.infinite){var t=this.index;if(t===this.lastIndex)return t++,this._scrollBy(-this.data.window[this.size[this.axis]],t)}this.scrollToIndex(this.index+1)},t.prototype.prev=function(){if(this.config.infinite){var t=this.index;if(0===t)return t--,this._scrollBy(this.data.window[this.size[this.axis]],t)}this.scrollToIndex(this.index-1)},t.prototype.update=function(){clearTimeout(this.timer),this.data={window:{width:window.innerWidth,height:window.innerHeight},container:{height:this.wrapper.scrollHeight,width:this.wrapper.scrollWidth}};var e=this.size[this.axis],s=this.horizontal?this.size.y:this.size.x;this.wrapper.style["overflow-"+this.axis]="scroll",this.wrapper.style[e]=this.data.window[e]+"px",this.wrapper.style[s]=this.data.window[s]+this.bar+"px";var t=this.config.infinite?this.pages.length+2:this.pages.length,i=this.config.infinite?this.data.window[e]:0;this.container.style[e]=t*this.data.window[e]+"px",this.wrapper.style["padding-"+(this.horizontal?"bottom":"right")]=this.bar+"px",this.wrapper[this.scrollAxis[this.axis]]=this.index*this.data.window[e]+i,this.scrollSize=t*this.data.window[e]-this.data.window[e],this.scrollPosition=this.data.window[e]*this.index+i,this.pages.forEach(function(t,i){this.horizontal&&(t.style.float="left"),t.style[e]=this.data.window[e]+"px",t.style[s]=this.data.window[s]+"px"},this),this.config.infinite&&this.clones.forEach(function(t){this.horizontal&&(t.style.float="left"),t.style[e]=this.data.window[e]+"px",t.style[s]=this.data.window[s]+"px"},this),this.config.onUpdate.call(this,this._getData()),this.emit("update",this._getData())},t.prototype.orientate=function(t){switch(t){case"vertical":this.horizontal=!1,this.axis="y",this.container.style.width="";break;case"horizontal":this.horizontal=!0,this.axis="x",this.container.style.height="";break;default:return!1}this.wrapper.classList.toggle("pg-vertical",!this.horizontal),this.wrapper.classList.toggle("pg-horizontal",this.horizontal),this.config.orientation=t,this.update()},t.prototype.slideshow=function(){return this.slider},t.prototype.destroy=function(){if(this.initialised){this.emit("destroy"),this.unbind(),document.body.style.margin="",document.body.style.overflow="",this.container.style.display="",this.container.style.height="",this.container.style.width="",this.container.classList.remove("pg-container"),this.wrapper.parentNode.replaceChild(this.container,this.wrapper);for(var t=0;t<this.pages.length;t++){var i=this.pages[t];i.style.height="",i.style.width="",i.style.float="",i.classList.remove("pg-page"),i.classList.remove("pg-active")}["Prev","Next"].forEach(function(t){var i="nav"+t+"El";this[i]&&(this[i].classList.remove("active"),this[i].classList.remove("pg-nav"))},this),this.config.infinite&&this._toggleInfinite(!0),this.config.slideshow&&(this.slider.stop(),this.slider=!1),this.initialised=!1,delete this.container.pageable}},t.prototype.on=function(t,i){this.listeners=this.listeners||{},this.listeners[t]=this.listeners[t]||[],this.listeners[t].push(i)},t.prototype.off=function(t,i){this.listeners=this.listeners||{},t in this.listeners!=!1&&this.listeners[t].splice(this.listeners[t].indexOf(i),1)},t.prototype.emit=function(t){if(this.listeners=this.listeners||{},t in this.listeners!=!1)for(var i=0;i<this.listeners[t].length;i++)this.listeners[t][i].apply(this,[].slice.call(arguments,1))},t.prototype._click=function(t){if(t.target.closest){var i=t.target.closest("a");i&&this.anchors.includes(i.hash)&&(t.preventDefault(),this.scrollToAnchor(i.hash))}},t.prototype._preventDefault=function(t){t.preventDefault(),t.stopPropagation()},t.prototype._keydown=function(t){if(this.scrolling||this.dragging)return t.preventDefault(),!1;var i=!1;void 0!==t.key?i=t.key:void 0!==t.keyCode&&(i=t.keyCode);var e="Arrow"+("x"===this.axis?"Left":"Up"),s="Arrow"+("x"===this.axis?"Right":"Down");if(i)switch(i){case 33:case 37:case e:case"PageUp":t.preventDefault(),this.prev();break;case 34:case 39:case s:case"PageDown":t.preventDefault(),this.next()}},t.prototype._start=function(t){var i=this._getEvent(t);return!this.scrolling&&!this.dragging&&("touchstart"!==t.type||this.events.touch?!!("mousedown"!==t.type||this.events.mouse&&0===t.button)&&(!!i.target.closest("[data-anchor]")&&(this._preventDefault(t),this.dragging=this.config.freeScroll,this.config.slideshow&&this.slider.stop(),this.down={x:i.clientX,y:i.clientY},this.startIndex=this.index,void this.config.onBeforeStart.call(this,this.index))):(i.target.closest("a")||this._preventDefault(t),!1))},t.prototype._drag=function(t){if(this.config.freeScroll&&this.dragging&&!this.scrolling){var i=this._getEvent(t),e=this._limitDrag(i),s=this._getData();this.container.style.transform=this.horizontal?"translate3d("+e+"px, 0, 0)":"translate3d(0, "+e+"px, 0)",s.scrolled-=e,this.config.onScroll.call(this,s,"drag"),this.emit("scroll",s)}},t.prototype._stop=function(t){var i=this,e=this._getEvent(t),s=function(){i.index<i.pages.length-1&&i.index++},n=function(){0<i.index&&i.index--};this.oldIndex=this.index;var o=Math.abs(e[this.mouseAxis[this.axis]]-this.down[this.axis])>=this.config.swipeThreshold,a=this.down&&o;if(this.config.slideshow&&this.slider.start(),this.dragging&&!this.scrolling){var h=this._limitDrag(e);return this.dragging=h,a&&(this.config.infinite&&this._overScroll(h<0,h),0<h?n():s()),this._scrollBy(this._getScrollAmount(this.oldIndex)-h),void(this.down=!1)}if(this.down&&!this.scrolling){var r=e[this.mouseAxis[this.axis]]<this.down[this.axis],l=e[this.mouseAxis[this.axis]]>this.down[this.axis];a&&(this.config.infinite&&this._overScroll(r),r?s():l&&n()),this.startIndex===this.index?this.config.onFinish.call(this,this._getData()):this._scrollBy(this._getScrollAmount(this.oldIndex)),this.down=!1}},t.prototype._wheel=function(t){if(t.preventDefault(),this.events.wheel&&!this.scrolling){var i=this.index,e=this.index,s=0<t.deltaY;this.config.infinite&&this._overScroll(s),s?this.index<this.pages.length-1&&i++:0<this.index&&i--,i!==e&&(this.oldIndex=e,this.scrollToIndex(i))}},t.prototype._load=function(t){var i=location.hash;if(i){var e=this.anchors.indexOf(i);if(-1<e){var s=this.config.infinite?1:0;this.scrollPosition=this.data.window[this.size[this.axis]]*(e+s);var n=this._getData();this.index=e,this.slideIndex=e,this.pages.forEach(function(t,i){t.classList.toggle("pg-active",i===this.index)},this),this._setNavs(),this._setPips(),this.config.onScroll.call(this,n),this.config.onFinish.call(this,n),this.emit("scroll",n)}}this.update()},t.prototype._getEvent=function(t){return this.touch?"touchend"===t.type?t.changedTouches[0]:t.touches[0]:t},t.prototype._getData=function(){return{index:this.index,scrolled:this.config.infinite?this.scrollPosition-this.data.window[this.size[this.axis]]:this.scrollPosition,max:this.config.infinite?this.scrollSize-2*this.data.window[this.size[this.axis]]:this.scrollSize}},t.prototype._overScroll=function(t){var i=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0,e=this.index;e===this.lastIndex&&t?(e++,this._scrollBy(-this.data.window[this.size[this.axis]]-i,e)):0!==e||t||(e--,this._scrollBy(this.data.window[this.size[this.axis]]-i,e))},t.prototype._scrollBy=function(h,r){if(this.scrolling)return!1;this.scrolling=!0,this.config.onBeforeStart.call(this,this.oldIndex),this.emit("scroll.before",this._getData()),this.config.slideshow&&this.slider.stop();var l=this;l.timer=setTimeout(function(){var o=Date.now(),a=l._getScrollOffset();l.config.onStart.call(l,l.pages[l.index].id),l.emit("scroll.start",l._getData()),l.frame=requestAnimationFrame(function t(){var i=Date.now()-o;if(i>l.config.animation){cancelAnimationFrame(l.frame),l.container.style.transform="",l.frame=!1,l.scrolling=!1,l.dragging=!1,l.config.slideshow&&l.slider.start(),l.config.infinite&&(r===l.pageCount?l.index=0:-1===r&&(l.index=l.lastIndex));var e=l._getData();return window.location.hash=l.pages[l.index].id,l.pages.forEach(function(t,i){t.classList.toggle("pg-active",i===l.index)},l),l.slideIndex=l.index,l._setPips(),l._setNavs(),l.config.onFinish.call(l,e),l.emit("scroll.end",e),!1}var s=l.dragging?l.dragging:0,n=l.config.easing(i,s,h,l.config.animation);l.container.style.transform=l.horizontal?"translate3d("+n+"px, 0, 0)":"translate3d(0, "+n+"px, 0)",l.scrollPosition=a[l.axis]-n;e=l._getData();l.config.infinite&&(r===l.pageCount?e.scrolled=0:-1===r&&(e.scrolled=e.max)),l.config.onScroll.call(l,e),l.emit("scroll",e),l.frame=requestAnimationFrame(t)})},l.dragging?0:l.config.delay)},t.prototype._getScrollOffset=function(){return{x:this.wrapper.scrollLeft,y:this.wrapper.scrollTop}},t.prototype._getScrollAmount=function(t,i){void 0===i&&(i=this.index);var e=this.data.window[this.size[this.axis]];return e*t-e*i},t.prototype._getScrollBarWidth=function(){var t,i=document.body,e=document.createElement("div");return e.style.cssText="width: 100; height: 100; overflow: scroll; position: absolute; top: -9999;",i.appendChild(e),t=e.offsetWidth-e.clientWidth,i.removeChild(e),t},t.prototype._toggleInfinite=function(t,i){if(t&&this.config.infinite)this.clones.forEach(function(t){this.container.removeChild(t)},this),this.config.infinite=!1;else if(!this.config.infinite||i){this.config.infinite=!0;var e=this.pages[0].cloneNode(!0),s=this.pages[this.lastIndex].cloneNode(!0);e.id=e.id+"-clone",s.id=s.id+"-clone",e.classList.add("pg-clone"),s.classList.add("pg-clone"),e.classList.remove("pg-active"),s.classList.remove("pg-active"),this.clones=[e,s],this.container.insertBefore(s,this.pages[0]),this.container.appendChild(e)}this.update()},t.prototype._limitDrag=function(t){var i=t[this.mouseAxis[this.axis]]-this.down[this.axis];return this.config.infinite||(0===this.index&&0<i||this.index===this.pages.length-1&&i<0)&&(i/=10),i},t.prototype._setNavs=function(){this.navPrevEl&&this.navPrevEl.classList.toggle("active",this.config.infinite||0<this.index),this.navNextEl&&this.navNextEl.classList.toggle("active",this.config.infinite||this.index<this.pages.length-1)},t.prototype._setPips=function(e){this.config.pips&&(void 0===e&&(e=this.index),this.pips.forEach(function(t,i){t.firstElementChild.classList.toggle("active",i==e)}))},t});

Softgel-Capsule – Affy Pharma Pvt Ltd

Arrange A Callback
[]
1 Step 1
Full Name
Telephone
Departmentyour full name
Postal Address
Message
0 /
Previous
Next
Shopping Basket