first commit

This commit is contained in:
2025-05-30 03:09:08 -06:00
parent 99d54737de
commit 1932509066
6221 changed files with 298434 additions and 212 deletions

View File

@ -0,0 +1,11 @@
/*
Name: Demo Accounting 1
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,5 @@
/*
Name: App Landing
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/

View File

@ -0,0 +1,156 @@
/*
Name: Architecture 2
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
/*
* Slider Background
*/
const $slider = $('#slider');
let direction = '';
$slider.on('click', '.owl-next', () => {
direction = 'next';
});
$slider.on('click', '.owl-prev', () => {
direction = 'prev';
});
$slider.on('changed.owl.carousel', ({item}) => {
$('.custom-slider-background .custom-slider-background-image-stage').each(function(){
const $stage = $(this), $stageOuter = $stage.closest('.custom-slider-background-image-stage-outer'), $currentItem = $stage.find('.custom-slider-background-image-item').eq( item.index ), nItems = $stage.find('.custom-slider-background-image-item').length;
const distance = $stage.hasClass('reverse') ? ( $currentItem.outerHeight() * nItems ) - ( $currentItem.outerHeight() * ( item.index + 1 ) ) : $currentItem.outerHeight() * item.index, mathSymbol = $stage.hasClass('reverse') ? '-' : '-';
$stage.css({
transform: 'translate3d(0, '+ mathSymbol + distance +'px, 0)'
});
});
});
// Once we have all ready, show the slider
$slider.on('initialized.owl.carousel', () => {
setTimeout(() => {
$('.custom-slider-background').addClass('show');
}, 800);
});
// Hide nav on first load of page
$slider.on('initialized.owl.carousel', () => {
setTimeout(() => {
$slider.find('.owl-nav').addClass('hide');
}, 200);
});
// Show nav once the slider animation is completed
$('.custom-slider-background').parent().on('transitionend', () => {
setTimeout(() => {
$slider.find('.owl-nav').addClass('show');
$('.custom-slider-background').addClass('custom-box-shadow-1');
}, 2000);
});
/*
* Page Header
*/
$('.custom-page-header-1-wrapper > div').on('animationend', () => {
setTimeout(() => {
$('.custom-page-header-1-wrapper').addClass('custom-box-shadow-1');
}, 1000);
});
/*
* Load More - Projects
*/
const loadMore = {
pages: 0,
currentPage: 1,
$wrapper: $('#loadMoreWrapper'),
$btn: $('#loadMore'),
$btnWrapper: $('#loadMoreBtnWrapper'),
$loader: $('#loadMoreLoader'),
build() {
const self = this;
self.pages = self.$wrapper.data('total-pages');
if(self.pages <= 1) {
self.$btnWrapper.remove();
return;
} else {
// init isotope
self.$wrapper.isotope();
self.$btn.on('click', () => {
self.loadMore();
});
// Lazy Load
if(self.$btn.hasClass('btn-lazy-load')) {
theme.fn.intObs( '#loadMore', "$('#loadMore').trigger('click');", {
rootMargin: '0px 0px 0px 0px'
} );
}
}
},
loadMore() {
const self = this;
self.$btn.css({
opacity: 0
});
self.$loader.show();
// Ajax
$.ajax({
url: 'ajax/demo-architecture-2-ajax-projects-load-more-' + (parseInt(self.currentPage)+1) + '.html',
complete({responseText}) {
const $items = $(responseText);
setTimeout(() => {
self.$wrapper.append($items)
self.$wrapper.isotope('appended', $items);
self.currentPage++;
if(self.currentPage < self.pages) {
self.$btn.css({
opacity: 1
}).blur();
} else {
self.$btnWrapper.remove();
}
self.$loader.hide();
}, 1000);
}
});
}
};
if($('#loadMoreWrapper').get(0)) {
loadMore.build();
}
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,214 @@
/*
Name: Architecture & Interior Design
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
// Custom Content Rotator
$('.custom-content-rotator').each(function(){
$(this).textRotator({
fadeSpeed: 500,
pauseSpeed: 5000
});
});
// Load More - Projects
var portfolioLoadMore = {
pages: 0,
currentPage: 1,
$wrapper: $('#portfolioLoadMoreWrapper'),
$btn: $('#portfolioLoadMore'),
$btnWrapper: $('#portfolioLoadMoreBtnWrapper'),
$loader: $('#portfolioLoadMoreLoader'),
build() {
const self = this;
self.pages = self.$wrapper.data('total-pages');
if(self.pages <= 1) {
self.$btnWrapper.remove();
return;
} else {
self.$btn.on('click', () => {
self.loadMore();
});
// Infinite Scroll
if(self.$btn.hasClass('btn-portfolio-infinite-scroll')) {
theme.fn.intObs( '#portfolioLoadMore', "$('#portfolioLoadMore').trigger('click');", {
rootMargin: '0px 0px 0px 0px'
} );
}
}
},
loadMore() {
const self = this, ajax_url = ( self.$wrapper.data('ajax-url') ) ? self.$wrapper.data('ajax-url') : 'ajax/portfolio-ajax-load-more-';
self.$btn.parent().find('.btn').hide();
self.$loader.addClass('portfolio-load-more-loader-showing').show();
// Ajax
$.ajax({
url: ajax_url + (parseInt(self.currentPage)+1) + '.html',
complete({responseText}) {
const $items = $(responseText);
setTimeout(() => {
self.$wrapper.append($items);
self.currentPage++;
if(self.currentPage < self.pages) {
self.$btn.parent().find('.btn').show().blur();
} else {
self.$btnWrapper.remove();
}
// Carousel
$(() => {
$('[data-plugin-carousel]:not(.manual), .owl-carousel:not(.manual)').each(function() {
const $this = $(this);
let opts;
const pluginOptions = theme.fn.getOptions($this.data('plugin-options'));
if (pluginOptions)
opts = pluginOptions;
$this.themePluginCarousel(opts);
});
});
self.$loader.removeClass('portfolio-load-more-loader-showing').hide();
}, 1000);
}
});
}
}
if($('#portfolioLoadMoreWrapper').get(0)) {
portfolioLoadMore.build();
}
// Load More - Blog
var portfolioLoadMore = {
pages: 0,
currentPage: 1,
$wrapper: $('#portfolioLoadMoreWrapperBlog'),
$btn: $('#portfolioLoadMoreBlog'),
$btnWrapper: $('#portfolioLoadMoreBtnWrapperBlog'),
$loader: $('#portfolioLoadMoreLoaderBlog'),
build() {
const self = this;
self.pages = self.$wrapper.data('total-pages');
if(self.pages <= 1) {
self.$btnWrapper.remove();
return;
} else {
self.$btn.on('click', () => {
self.loadMore();
});
// Infinite Scroll
if(self.$btn.hasClass('btn-portfolio-infinite-scroll')) {
theme.fn.intObs( '#portfolioLoadMoreBlog', "$('#portfolioLoadMoreBlog').trigger('click');", {
rootMargin: '0px 0px 0px 0px'
} );
}
}
},
loadMore() {
const self = this, ajax_url = ( self.$wrapper.data('ajax-url') ) ? self.$wrapper.data('ajax-url') : 'ajax/portfolio-ajax-load-more-';
self.$btn.parent().find('.btn').hide();
self.$loader.addClass('portfolio-load-more-loader-showing').show();
// Ajax
$.ajax({
url: ajax_url + (parseInt(self.currentPage)+1) + '.html',
complete({responseText}) {
const $items = $(responseText);
setTimeout(() => {
self.$wrapper.append($items);
self.currentPage++;
if(self.currentPage < self.pages) {
self.$btn.parent().find('.btn').show().blur();
} else {
self.$btnWrapper.remove();
}
// Carousel
$(() => {
$('[data-plugin-carousel]:not(.manual), .owl-carousel:not(.manual)').each(function() {
const $this = $(this);
let opts;
const pluginOptions = theme.fn.getOptions($this.data('plugin-options'));
if (pluginOptions)
opts = pluginOptions;
$this.themePluginCarousel(opts);
});
});
self.$loader.removeClass('portfolio-load-more-loader-showing').hide();
}, 1000);
}
});
}
}
if($('#portfolioLoadMoreWrapperBlog').get(0)) {
portfolioLoadMore.build();
}
/*
Services Ajax
*/
$('.simple-ajax-popup').magnificPopup({
type: 'ajax',
callbacks: {
open() {
$('html').addClass('lightbox-opened');
},
close() {
$('html').removeClass('lightbox-opened');
}
}
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,51 @@
/*
Name: Auto Services
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
/*
* Datepicker
*/
// Fix datepicker issue when using body with margin (notice top bar)
const datepicker = $.fn.datepicker;
$.fn.datepicker = function(...args) {
const result = datepicker.apply(this, args);
this.on('show', function (e) {
const $target = $(this);
const $picker = $target.data('datepicker').picker;
let top;
if ($picker.hasClass('datepicker-orient-top')) {
top = $target.offset().top - $picker.outerHeight() - parseInt($picker.css('marginTop'));
} else {
top = $target.offset().top + $target.outerHeight() + parseInt($picker.css('marginTop'));
}
$picker.offset({top});
});
return result;
}
// Initialize Datepickers on the page
$('.custom-datepicker').each(function(){
$(this).datepicker();
});
/*
* Timepicker
*/
$('.custom-timepicker').each(function(){
$(this).timepicker({
disableMousewheel: true,
icons: {
up: 'fas fa-chevron-up',
down: 'fas fa-chevron-down'
}
});
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,51 @@
/*
Name: Band
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
/*
* Add "active" class to animate Custom Porto SVG Logo
*/
$(window).on('load', () => {
setTimeout(() => {
$('.custom-porto-svg-logo').addClass('active');
}, 1000);
});
/*
* Scroll and Focus
*/
function scrollAndFocus($this, scrollTarget, focusTarget, scrollOffset, scrollAgain) {
($ => {
$('body').addClass('scrolling');
// if it's inside a header menu
if( $($this).closest('#mainNav').length ) {
$($this).parents('.collapse.show').collapse('hide');
}
$('html, body').animate({
scrollTop: $(scrollTarget).offset().top - (scrollOffset ? scrollOffset : 0)
}, 300, () => {
$('body').removeClass('scrolling');
setTimeout(() => {
$(focusTarget).focus();
}, 500);
if( scrollAgain ) {
$('html, body').animate({
scrollTop: $(scrollTarget).offset().top - (scrollOffset ? scrollOffset : 0)
});
}
});
})(jQuery);
}
$('[data-scroll-and-focus]').on('click', function() {
scrollAndFocus($(this), '#contact', '#name', 70, true);
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,5 @@
/*
Name: Barber
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/

View File

@ -0,0 +1,5 @@
/*
Name: Demo Beauty Salon
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/

View File

@ -0,0 +1,17 @@
/*
Name: Business Consulting 2
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
// Accordion
$("[data-parent='#accordionServices']").on("click", function() {
const trigger = $(this);
$("#accordionServices .collapse.show").each(function() {
if (trigger.attr("href") != ("#" + $(this).attr("id"))) {
$(this).removeClass("show");
}
});
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,120 @@
/*
Name: Demo Business Consulting 4
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
// Particles 1
particlesJS("particles-1", {
"particles": {
"number": {
"value": 30,
"density": {
"enable": true,
"value_area": 800
}
},
"color": {
"value": "#ffffff"
},
"shape": {
"type": "image",
"stroke": {
"width": 0,
"color": "#000000"
},
"polygon": {
"nb_sides": 5
},
"image": {
"src": "img/demos/business-consulting-4/generic/generic-7.png",
"width": 100,
"height": 100
}
},
"opacity": {
"value": 1,
"random": true,
"anim": {
"enable": true,
"speed": 1,
"opacity_min": 0,
"sync": false
}
},
"size": {
"value": 48.10236182596568,
"random": true,
"anim": {
"enable": false,
"speed": 4,
"size_min": 0.3,
"sync": false
}
},
"line_linked": {
"enable": false,
"distance": 150,
"color": "#ffffff",
"opacity": 0.4,
"width": 1
},
"move": {
"enable": true,
"speed": 1,
"direction": "none",
"random": true,
"straight": false,
"out_mode": "out",
"bounce": false,
"attract": {
"enable": false,
"rotateX": 600,
"rotateY": 600
}
}
},
"interactivity": {
"detect_on": "canvas",
"events": {
"onhover": {
"enable": true,
"mode": "bubble"
},
"onclick": {
"enable": true,
"mode": "repulse"
},
"resize": true
},
"modes": {
"grab": {
"distance": 400,
"line_linked": {
"opacity": 1
}
},
"bubble": {
"distance": 250,
"size": 0,
"duration": 2,
"opacity": 0,
"speed": 3
},
"repulse": {
"distance": 400,
"duration": 0.4
},
"push": {
"particles_nb": 4
},
"remove": {
"particles_nb": 2
}
}
},
"retina_detect": true
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,5 @@
/*
Name: Demo Business Consulting 5
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/

View File

@ -0,0 +1,130 @@
/*
Name: Church
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
/*
* Validate
*/
if($('#contactFormMessage').get(0) ) {
$('#contactFormMessage').validate({
onkeyup: false,
onclick: false,
onfocusout: false,
errorPlacement(error, element) {
if (element.attr('type') == 'radio' || element.attr('type') == 'checkbox') {
error.appendTo(element.parent().parent());
} else {
error.insertAfter(element);
}
}
});
}
/*
* Ajax on Page
*/
const ajaxOnPagePortfolioDetails = {
pages: [],
$ajaxBox: $('#galleryAjaxBox'),
$ajaxBoxContent: $('#galleryAjaxBoxContent'),
build() {
const self = this;
$('a[data-ajax-on-page]').each(function() {
self.add($(this));
});
$(document).on('mousedown', 'a[data-ajax-on-page]', ev => {
if (ev.which == 2) {
ev.preventDefault();
return false;
}
});
},
add($el) {
const self = this, href = $el.attr('data-href');
self.pages.push(href);
$el.on('click', function(e) {
e.preventDefault();
self.show(self.pages.indexOf(href));
// Remove active from all items
$('a[data-ajax-on-page]').find('.thumb-info-wrapper').removeClass('active');
// Set active current selected item
$(this).find('.thumb-info-wrapper').addClass('active');
});
},
events() {
const self = this;
// Carousel
if ($.isFunction($.fn['themePluginCarousel'])) {
$(() => {
$('[data-plugin-carousel]:not(.manual), .owl-carousel:not(.manual)').each(function() {
const $this = $(this);
let opts;
const pluginOptions = theme.fn.getOptions($this.data('plugin-options'));
if (pluginOptions)
opts = pluginOptions;
$this.themePluginCarousel(opts);
});
});
}
},
show(i) {
const self = this;
self.$ajaxBoxContent.empty();
self.$ajaxBox.removeClass('ajax-box-init').addClass('ajax-box-loading');
$('html, body').animate({
scrollTop: self.$ajaxBox.offset().top - 100
}, 300, 'easeOutQuad');
// Ajax
$.ajax({
url: self.pages[i],
complete({responseText}) {
setTimeout(() => {
self.$ajaxBoxContent.html(responseText);
self.$ajaxBox.removeClass('ajax-box-loading');
self.events();
}, 1000);
}
});
}
};
if($('#galleryAjaxBox').get(0)) {
ajaxOnPagePortfolioDetails.build();
}
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,27 @@
/*
Name: Cleaning Services
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
/*
* SVG Aspect Ratio
*/
function aspectRatioSVG() {
if( $(window).width() < 2000 ) {
$('svg[preserveAspectRatio]').each(function(){
$(this).attr('preserveAspectRatio', 'xMinYMin');
});
} else {
$('svg[preserveAspectRatio]').each(function(){
$(this).attr('preserveAspectRatio', 'none');
});
}
}
aspectRatioSVG();
$(window).on('resize', () => {
aspectRatioSVG();
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,135 @@
/*
Name: Construction 2
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
// Load More - Projects
const loadMore = {
pages: 0,
currentPage: 1,
$wrapper: $('#loadMoreWrapper'),
$btn: $('#loadMore'),
$btnWrapper: $('#loadMoreBtnWrapper'),
$loader: $('#loadMoreLoader'),
build() {
const self = this;
self.pages = self.$wrapper.data('total-pages');
if(self.pages <= 1) {
self.$btnWrapper.remove();
return;
} else {
// init isotope
self.$wrapper.isotope();
self.$btn.on('click', () => {
self.loadMore();
});
// Lazy Load
if(self.$btn.hasClass('btn-lazy-load')) {
theme.fn.intObs( '#loadMore', "$('#loadMore').trigger('click');", {
rootMargin: '0px 0px 0px 0px'
} );
}
}
},
loadMore() {
const self = this;
self.$btn.css('visibility', 'hidden');
self.$loader.show();
// Ajax
$.ajax({
url: 'ajax/demo-construction-2-ajax-projects-load-more-' + (parseInt(self.currentPage)+1) + '.html',
complete({responseText}) {
const $items = $(responseText);
setTimeout(() => {
self.$wrapper.append($items)
self.$wrapper.isotope('appended', $items);
self.currentPage++;
if(self.currentPage < self.pages) {
self.$btn.css('visibility', 'visible').blur();
} else {
self.$btnWrapper.remove();
}
self.$loader.hide();
}, 1000);
}
});
}
};
if($('#loadMoreWrapper').get(0)) {
loadMore.build();
}
// Thumb Gallery
const $customThumbGalleryDetail = $('#customThumbGalleryDetail');
const $customThumbGalleryThumbs = $('#customThumbGalleryThumbs');
let flag = false;
const duration = 300;
$customThumbGalleryDetail
.owlCarousel({
items: 1,
margin: 10,
nav: false,
dots: false,
loop: false,
navText: [],
rtl: ( $('html').attr('dir') == 'rtl' ) ? true : false
})
.on('changed.owl.carousel', ({item}) => {
if (!flag) {
flag = true;
$customThumbGalleryThumbs.trigger('to.owl.carousel', [item.index-1, duration, true]);
flag = false;
}
});
$customThumbGalleryThumbs
.owlCarousel({
margin: 15,
items: 4,
nav: false,
center: false,
dots: false,
rtl: ( $('html').attr('dir') == 'rtl' ) ? true : false
})
.on('click', '.owl-item', function() {
$customThumbGalleryDetail.trigger('to.owl.carousel', [$(this).index(), duration, true]);
})
.on('changed.owl.carousel', ({item}) => {
if (!flag) {
flag = true;
$customThumbGalleryDetail.trigger('to.owl.carousel', [item.index, duration, true]);
flag = false;
}
});
})).apply(this, [jQuery]);

View File

@ -0,0 +1,74 @@
/*
Name: Demo Creative Agency 1
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
// Disable Scroll to Top
theme.PluginScrollToTop.initialize = () => {};
(($ => {
if (typeof LocomotiveScroll !== 'undefined') {
window.scrollTo(0,0);
setTimeout(() => {
/*
Horizontal Scroll
*/
let scroller;
let initLocoScroll = () => {
window.scrollTo(0,0);
scroller = new LocomotiveScroll({
el: document.querySelector('[data-scroll-container]'),
smooth: true,
direction: (window.innerWidth > 1199 ? "horizontal" : "vertical"),
mobile: {
breakpoint: 0,
smooth: true,
direction: (window.innerWidth > 1199 ? "horizontal" : "vertical")
},
tablet: {
breakpoint: 0,
smooth: true,
direction: (window.innerWidth > 1199 ? "horizontal" : "vertical")
}
});
scroller.on("scroll", () => {
ScrollTrigger.update();
});
}
initLocoScroll();
$('[data-hash]').off().on('click', function(e) {
e.preventDefault();
e.stopPropagation();
const anchor = $($(this).attr('href')).get(0);
scroller.scrollTo(anchor);
});
$(window).afterResize(() => {
scroller.destroy();
initLocoScroll();
});
}, 100);
window.onbeforeunload = () => {
window.scrollTo(0,0);
};
} else {
theme.fn.showErrorMessage('Failed to Load File', 'Failed to load: Locomotive Scroll - Include the following file(s): (vendor/locomotive-scroll/locomotive-scroll.min.js)');
}
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,14 @@
/*
Name: Demo Creative Agency 2
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
$(window).on('load', () => {
setTimeout(() => {
$('.custom-hero-bg').addClass('loaded');
}, 500);
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,62 @@
/*
Name: Demo Dentist
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
const owlTestimonials = $('#textimonialsCarousel');
owlTestimonials.on('initialized.owl.carousel', event => {
if ($.isFunction($.fn['themePluginBeforeAfter'])) {
$(() => {
$('[data-plugin-before-after]:not(.manual)').each(function() {
const $this = $(this);
let opts;
const pluginOptions = theme.fn.getOptions($this.data('plugin-options'));
if (pluginOptions)
opts = pluginOptions;
$this.themePluginBeforeAfter(opts);
});
});
}
});
owlTestimonials.owlCarousel({
loop: false,
responsive: {
0: {
items: 1
},
479: {
items: 1
},
768: {
items: 1
},
979: {
items: 1
},
1199: {
items: 1
}
},
mouseDrag: false,
touchDrag: false,
nav: true,
dots: false,
navText: [],
margin: 0,
autoWidth: false,
autoHeight: false,
items: 1,
rtl: ( $('html').attr('dir') == 'rtl' ) ? true : false
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,28 @@
/*
Name: Event
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
/*
Dialog with CSS animation
*/
theme.fn.execOnceTroughEvent( $('.popup-with-zoom-anim'), 'mouseover.trigger.zoom.lightbox', function(){
$(this).magnificPopup({
type: 'inline',
fixedContentPos: false,
fixedBgPos: true,
overflowY: 'auto',
closeBtnInside: true,
preloader: false,
midClick: true,
removalDelay: 300,
mainClass: 'my-mfp-zoom-in'
});
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,105 @@
/*
Name: Gym
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
// Slider Options
const sliderOptions = {
sliderType: 'standard',
sliderLayout: 'fullscreen',
responsiveLevels: [4096,1200,992,420],
gridwidth:[1170,970,750],
delay: 5000,
disableProgressBar: 'on',
lazyType: "none",
shadow: 0,
spinner: "off",
shuffle: "off",
autoHeight: "off",
fullScreenAlignForce: "off",
fullScreenOffset: "",
hideThumbsOnMobile: "off",
hideSliderAtLimit: 0,
hideCaptionAtLimit: 0,
hideAllCaptionAtLilmit: 0,
debugMode: false,
fallbacks: {
simplifyAll: "off",
nextSlideOnWindowFocus: "off",
disableFocusListener: false,
},
navigation: {
keyboardNavigation: "on",
keyboard_direction: "horizontal",
mouseScrollNavigation: "off",
onHoverStop: "off",
touch: {
touchenabled: "on",
swipe_threshold: 75,
swipe_min_touches: 1,
swipe_direction: "horizontal",
drag_block_vertical: false
},
arrows: {
enable: false,
},
bullets: {
style:"custom-tp-bullets",
enable: true,
container:"slider",
rtl: false,
hide_onmobile: false,
hide_onleave: true,
hide_delay: 200,
hide_delay_mobile: 1200,
hide_under: 0,
hide_over: 9999,
direction:"horizontal",
space: 20,
h_align: "center",
v_align: "bottom",
h_offset: 0,
v_offset: 50
}
},
parallax:{
type:"on",
levels:[20,40,60,80,100],
origo:"enterpoint",
speed:400,
bgparallax:"on",
disable_onmobile:"off"
}
};
// Slider Init
$('#revolutionSlider').revolution(sliderOptions);
// Custom Menu Style
if($('.custom-header-style-1').get(0)) {
$('.header-nav-main nav > ul > li > a').each(function(){
const parent = $(this).parent(), clone = $(this).clone(), clone2 = $(this).clone(), wrapper = $('<span class="wrapper-items-cloned"></span>');
// Config Classes
$(this).addClass('item-original');
clone2.addClass('item-two');
// Insert on DOM
parent.prepend(wrapper);
wrapper.append(clone).append(clone2);
});
}
// Isotope
const $wrapper = $('#itemDetailGallery');
if( $wrapper.get(0) ) {
$wrapper.waitForImages(() => {
$wrapper.isotope({
itemSelector: '.isotope-item'
});
});
}
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,136 @@
/*
Name: Hotel
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
// Slider
$('#revolutionSlider').revolution({
sliderType: 'standard',
sliderLayout: 'fullwidth',
delay: 5000,
gridwidth: 1170,
gridheight: 530,
spinner: 'off',
disableProgressBar: 'on',
parallax:{
type:"on",
levels:[5,10,15,20,25,30,35,40,45,50,55,60,65,70,75,80,85],
origo:"enterpoint",
speed:400,
bgparallax:"on",
disable_onmobile:"off"
},
navigation: {
keyboardNavigation:"off",
keyboard_direction: "horizontal",
mouseScrollNavigation:"off",
onHoverStop:"on",
touch:{
touchenabled:"on",
swipe_threshold: 75,
swipe_min_touches: 1,
swipe_direction: "horizontal",
drag_block_vertical: false
},
bullets: {
enable:true,
hide_onmobile:true,
hide_under:778,
style:"uranus",
tmp: '<span class="tp-bullet-inner"></span>',
hide_onleave:false,
direction:"horizontal",
h_align:"center",
v_align:"bottom",
h_offset:0,
v_offset:45,
space:7
}
}
});
// Header
const $headerWrapper = $('#headerBookNow');
if( $(window).width() > 991 ) {
$headerWrapper.on('mousedown', () => {
$headerWrapper.addClass('open');
});
$(document).mouseup(({target}) => {
if (!$headerWrapper.is(target) && $headerWrapper.has(target).length === 0 && !$(target).parents('.datepicker').get(0)) {
$headerWrapper.removeClass('open');
}
});
}
// DatePicker
$('#bookNowArrivalHeader').datepicker({
defaultDate: '+1d',
startDate: '+1d',
autoclose: true,
orientation: (($('html[dir="rtl"]').get(0)) ? 'bottom right' : 'bottom'),
container: '#header',
rtl: (($('html[dir="rtl"]').get(0)) ? true : false)
});
$('#bookNowDepartureHeader').datepicker({
defaultDate: '+2d',
startDate: '+2d',
autoclose: true,
orientation: (($('html[dir="rtl"]').get(0)) ? 'bottom right' : 'bottom'),
container: '#header',
rtl: (($('html[dir="rtl"]').get(0)) ? true : false)
});
$(document).scroll(() => {
$('#bookNowArrivalHeader, #bookNowDepartureHeader').datepicker('hide').blur();
});
$('#bookNowArrival').datepicker({
defaultDate: '+1d',
startDate: '+1d',
autoclose: true,
orientation: (($('html[dir="rtl"]').get(0)) ? 'bottom left' : 'bottom left'),
container: '#bookFormDetails',
rtl: (($('html[dir="rtl"]').get(0)) ? true : false)
});
$('#bookNowDeparture').datepicker({
defaultDate: '+2d',
startDate: '+2d',
autoclose: true,
orientation: (($('html[dir="rtl"]').get(0)) ? 'bottom left' : 'bottom left'),
container: '#bookFormDetails',
rtl: (($('html[dir="rtl"]').get(0)) ? true : false)
});
// Book Form
$('#bookFormHeader').validate({
onkeyup: false,
onclick: false,
onfocusout: false,
errorPlacement(error, element) {
if (element.attr('type') == 'radio' || element.attr('type') == 'checkbox') {
error.appendTo(element.parent().parent());
} else {
error.insertAfter(element);
}
}
});
$('#bookForm').validate({
onkeyup: false,
onclick: false,
onfocusout: false,
errorPlacement(error, element) {
if (element.attr('type') == 'radio' || element.attr('type') == 'checkbox') {
error.appendTo(element.parent().parent());
} else {
error.insertAfter(element);
}
}
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,69 @@
/*
Name: Industry & Factory
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
/*
* SVG Aspect Ratio
*/
function aspectRatioSVG() {
if( $(window).width() < 2000 ) {
$('svg[preserveAspectRatio]:not(.custom-svg-btn-background)').each(function(){
$(this).attr('preserveAspectRatio', 'xMinYMin');
});
} else {
$('svg[preserveAspectRatio]:not(.custom-svg-btn-background)').each(function(){
$(this).attr('preserveAspectRatio', 'none');
});
}
}
aspectRatioSVG();
$(window).on('resize', () => {
aspectRatioSVG();
});
/*
* Play Video
*/
const $videoBox = $('.custom-featured-box-with-video');
$videoBox.find('.custom-trigger-play-video').on('click', function(e){
e.preventDefault();
const $this = $(this);
// Show Loading Dots
$this
.css('height', $this.outerHeight())
.html( '<div class="bounce-loader"><div class="bounce1"></div><div class="bounce2"></div><div class="bounce3"></div></div>' );
setTimeout(() => {
// Hide Video Poster
$videoBox
.find('.featured-box-background')
.addClass('hide');
// Hide Video Box Content
$videoBox
.find('.box-content')
.addClass('hide');
// Turn the video active
$videoBox
.find('.custom-featured-box-video')
.addClass('active');
// Play video
setTimeout(() => {
$videoBox
.find('.custom-featured-box-video')
.get(0)
.play();
}, 500);
}, 1000);
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,122 @@
/*
Name: it-services
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
/*
* Load More - Cases
*/
const portfolioLoadMore = {
pages: 0,
currentPage: 1,
$wrapper: $('#portfolioLoadMoreWrapper'),
$btn: $('#portfolioLoadMore'),
$btnWrapper: $('#portfolioLoadMoreBtnWrapper'),
$loader: $('#portfolioLoadMoreLoader'),
build() {
const self = this;
self.pages = self.$wrapper.data('total-pages');
if(self.pages <= 1) {
self.$btnWrapper.remove();
return;
} else {
self.$btn.on('click', () => {
self.loadMore();
});
// Infinite Scroll
if(self.$btn.hasClass('btn-portfolio-infinite-scroll')) {
theme.fn.intObs( '#portfolioLoadMore', "$('#portfolioLoadMore').trigger('click');", {
rootMargin: '0px 0px 0px 0px'
} );
}
}
},
loadMore() {
const self = this, ajax_url = ( self.$wrapper.data('ajax-url') ) ? self.$wrapper.data('ajax-url') : 'ajax/portfolio-ajax-load-more-';
self.$btn.hide();
self.$loader.addClass('portfolio-load-more-loader-showing').show();
// Ajax
$.ajax({
url: ajax_url + (parseInt(self.currentPage)+1) + '.html',
complete({responseText}) {
const $items = $(responseText);
setTimeout(() => {
self.$wrapper.append($items)
self.$wrapper.isotope('appended', $items);
self.currentPage++;
if(self.currentPage < self.pages) {
self.$btn.show().blur();
} else {
self.$btnWrapper.remove();
}
// Carousel
$(() => {
$('[data-plugin-carousel]:not(.manual), .owl-carousel:not(.manual)').each(function() {
const $this = $(this);
let opts;
const pluginOptions = theme.fn.getOptions($this.data('plugin-options'));
if (pluginOptions)
opts = pluginOptions;
$this.themePluginCarousel(opts);
});
});
self.$loader.removeClass('portfolio-load-more-loader-showing').hide();
}, 1000);
}
});
}
};
if($('#portfolioLoadMoreWrapper').get(0)) {
portfolioLoadMore.build();
}
/**
* Custom Simple Form Validation
*
*/
$('.custom-form-simple-validation').each(function(){
$(this).validate({
onkeyup: false,
onclick: false,
onfocusout: false,
errorPlacement(error, element) {
if (element.attr('type') == 'radio' || element.attr('type') == 'checkbox') {
error.appendTo(element.closest('.form-group'));
} else {
error.insertAfter(element);
}
}
});
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,27 @@
/*
Name: Law Firm 2
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
/*
* Custom See More Overlay
*/
$('.custom-seemore-overlay-button').on('click', function(e){
e.preventDefault();
const $this = $(this), $wrapper = $this.closest('.custom-seemore-overlay');
$wrapper.addClass('active');
setTimeout(() => {
$this.closest('.custom-seemore-overlay').animate({
'max-height': $wrapper[0].scrollHeight
}, () => {
$this.remove();
$wrapper.closest('.custom-seemore-overlay').css('max-height', 'none');
});
}, 200);
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,87 @@
/*
Name: Law Firm
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
/*
Combination Filters
*/
if($('#combinationFilters').get(0)) {
$(window).on('load', () => {
setTimeout(() => {
const $grid = $('.portfolio-list').isotope({
itemSelector: '.isotope-item',
layoutMode: 'masonry',
filter: '*',
hiddenStyle: {
opacity: 0
},
visibleStyle: {
opacity: 1
},
stagger: 30,
isOriginLeft: ($('html').attr('dir') == 'rtl' ? false : true)
});
const filters = {}, $loader = $('.sort-destination-loader');
$('.filters').on('click', 'a', function(e) {
e.preventDefault();
const $this = $(this);
const $buttonGroup = $this.parents('.portfolio-filter-group');
const filterGroup = $buttonGroup.attr('data-filter-group');
filters[filterGroup] = $this.parent().attr('data-option-value');
const filterValue = concatValues(filters);
$grid.isotope({
filter: filterValue
});
});
$('.portfolio-filter-group').each((i, buttonGroup) => {
const $buttonGroup = $(buttonGroup);
$buttonGroup.on('click', 'a', function() {
$buttonGroup.find('.active').removeClass('active');
$(this).parent().addClass('active');
$(this).addClass('active');
});
});
var concatValues = obj => {
let value = '';
for (const prop in obj) {
value += obj[prop];
}
return value;
}
$(window).on('resize', () => {
setTimeout(() => {
$grid.isotope('layout');
}, 300);
});
if ($loader) {
$loader.removeClass('sort-destination-loader-showing');
setTimeout(() => {
$loader.addClass('sort-destination-loader-loaded');
}, 500);
}
}, 1000);
});
}
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,102 @@
/*
Name: Demo Marketing 1
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
gsap.registerPlugin(ScrollTrigger);
/*
Section Scale
*/
gsap.utils.toArray(".gsap-section-scale").forEach((section, index) => {
const tl1 = gsap.timeline({
scrollTrigger: {
trigger: section,
start: "100% 100%",
end: "bottom top",
scrub: true
},
});
tl1.fromTo(
section, {
scale: 1,
},
{
scale: 0.9,
duration: 1,
ease: "power2.out"
}
);
});
/*
Image Change
*/
gsap.defaults({ overwrite: 'auto'});
// Set up our scroll trigger
const ST = ScrollTrigger.create({
trigger: ".gsap-content-container",
start: "top top",
end: "bottom bottom",
onUpdate: getCurrentSection
});
const contentMarkers = gsap.utils.toArray(".gsap-content-marker");
// Set up our content behaviors
contentMarkers.forEach(marker => {
marker.content = document.querySelector(`#${marker.dataset.markerContent}`);
marker.content.enter = () => {
gsap.fromTo(marker.content, {
autoAlpha: 0
}, {
duration: 0.3,
autoAlpha: 1
});
}
marker.content.leave = () => {
gsap.to(marker.content, {
duration: 0.1,
autoAlpha: 0
});
}
});
// Handle the updated position
let lastContent;
function getCurrentSection() {
let newContent;
const currScroll = scrollY;
// Find the current section
contentMarkers.forEach(({offsetTop, content}) => {
if (currScroll > (offsetTop - 100)) {
newContent = content;
}
});
// If the current section is different than that last, animate in
if (newContent &&
(lastContent == null ||
!newContent.isSameNode(lastContent))) {
// Fade out last section
if (lastContent) {
lastContent.leave();
}
// Animate in new section
newContent.enter();
lastContent = newContent;
}
}
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,104 @@
/*
Name: Medical
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
// Ajax on Page
const ajaxOnPageMedical = {
pages: [],
$ajaxBox: $('#porfolioAjaxBoxMedical'),
$ajaxBoxContent: $('#porfolioAjaxBoxContentMedical'),
build() {
const self = this;
$('a[data-ajax-on-page]').each(function() {
self.add($(this));
});
$(document).on('mousedown', 'a[data-ajax-on-page]', ev => {
if (ev.which == 2) {
ev.preventDefault();
return false;
}
});
},
add($el) {
const self = this, href = $el.attr('data-href');
self.pages.push(href);
$el.on('click', e => {
e.preventDefault();
self.show(self.pages.indexOf(href));
});
},
events() {
const self = this;
// Carousel
if ($.isFunction($.fn['themePluginCarousel'])) {
$(() => {
$('[data-plugin-carousel]:not(.manual), .owl-carousel:not(.manual)').each(function() {
const $this = $(this);
let opts;
const pluginOptions = theme.fn.getOptions($this.data('plugin-options'));
if (pluginOptions)
opts = pluginOptions;
$this.themePluginCarousel(opts);
});
});
}
},
show(i) {
const self = this;
self.$ajaxBoxContent.empty();
self.$ajaxBox.removeClass('ajax-box-init').addClass('ajax-box-loading');
$('html, body').animate({
scrollTop: self.$ajaxBox.offset().top - 100
}, 300, 'easeOutQuad');
// Ajax
$.ajax({
url: self.pages[i],
complete({responseText}) {
setTimeout(() => {
self.$ajaxBoxContent.html(responseText);
self.$ajaxBox.removeClass('ajax-box-loading');
self.events();
}, 1000);
}
});
}
};
if($('#porfolioAjaxBoxMedical').get(0)) {
ajaxOnPageMedical.build();
}
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,229 @@
/*
Name: One Page Agency
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
const $window = $(window);
/*
* Header
*/
const $header = $('#header');
window.onscroll = () => {
if (window.pageYOffset > $header.offset().top) {
$('html').addClass('sticky-header-active');
} else {
$('html').removeClass('sticky-header-active');
}
};
/*
* Collapse Menu Button
*/
$('.header-btn-collapse-nav').on('click', () => {
$('html, body').animate({
scrollTop: $(".header-btn-collapse-nav").offset().top - 18
}, 300);
});
/*
* Isotope
*/
const $wrapper = $('#itemDetailGallery');
if( $wrapper.get(0) ) {
$wrapper.waitForImages(() => {
$wrapper.isotope({
itemSelector: '.isotope-item'
});
});
}
/*
Load More
*/
const portfolioLoadMore = {
pages: 0,
currentPage: 1,
$wrapper: $('#portfolioLoadMoreWrapper'),
$btn: $('#portfolioLoadMore'),
$btnWrapper: $('#portfolioLoadMoreBtnWrapper'),
$loader: $('#portfolioLoadMoreLoader'),
build() {
const self = this;
self.pages = self.$wrapper.data('total-pages');
if(self.pages <= 1) {
self.$btnWrapper.remove();
return;
} else {
self.$btn.on('click', () => {
self.loadMore();
});
// Infinite Scroll
if(self.$btn.hasClass('btn-portfolio-infinite-scroll')) {
theme.fn.intObs( '#portfolioLoadMore', "$('#portfolioLoadMore').trigger('click');", {
rootMargin: '0px 0px 0px 0px'
}, true );
}
}
},
loadMore() {
const self = this, ajax_url = ( self.$wrapper.data('ajax-url') ) ? self.$wrapper.data('ajax-url') : 'ajax/portfolio-ajax-load-more-';
self.$btn.hide();
self.$loader.addClass('portfolio-load-more-loader-showing').show();
// Ajax
$.ajax({
url: ajax_url + (parseInt(self.currentPage)+1) + '.html',
complete({responseText}) {
const $items = $(responseText);
setTimeout(() => {
self.$wrapper.append($items)
self.$wrapper.isotope('appended', $items);
self.currentPage++;
if(self.currentPage < self.pages) {
self.$btn.show().blur();
} else {
self.$btnWrapper.remove();
}
// Carousel
$(() => {
$('[data-plugin-carousel]:not(.manual), .owl-carousel:not(.manual)').each(function() {
const $this = $(this);
let opts;
const pluginOptions = theme.fn.getOptions($this.data('plugin-options'));
if (pluginOptions)
opts = pluginOptions;
$this.themePluginCarousel(opts);
});
});
self.$loader.removeClass('portfolio-load-more-loader-showing').hide();
self.$wrapper.waitForImages(() => {
self.$wrapper.isotope('layout');
});
}, 1000);
}
});
}
};
if($('#portfolioLoadMoreWrapper').get(0)) {
portfolioLoadMore.build();
}
/*
* Ajax on Modal
*/
theme.fn.execOnceTroughEvent( 'a[data-ajax-on-modal]', 'mouseover.trigger.ajax.on.modal', () => {
$('a[data-ajax-on-modal]').magnificPopup({
type: 'ajax',
tLoading: '',
mainClass: 'portfolio-ajax-modal',
closeBtnInside: true,
gallery: {
enabled: true
},
callbacks: {
ajaxContentAdded() {
// Wrapper
const $wrapper = $('.portfolio-ajax-modal');
// Close
$wrapper.find('a[data-ajax-portfolio-close]').on('click', e => {
e.preventDefault();
$.magnificPopup.close();
});
// Remove Next and Close
if($('a[data-ajax-on-modal]').length <= 1) {
$wrapper.find('a[data-ajax-portfolio-prev], a[data-ajax-portfolio-next]').remove();
} else {
// Prev
$wrapper.find('a[data-ajax-portfolio-prev]').on('click', e => {
e.preventDefault();
$('.mfp-arrow-left').trigger('click');
return false;
});
// Next
$wrapper.find('a[data-ajax-portfolio-next]').on('click', e => {
e.preventDefault();
$('.mfp-arrow-right').trigger('click');
return false;
});
}
// Carousel
$(() => {
$('[data-plugin-carousel]:not(.manual), .owl-carousel:not(.manual)').each(function() {
const $this = $(this);
let opts;
const pluginOptions = theme.fn.getOptions($this.data('plugin-options'));
if (pluginOptions)
opts = pluginOptions;
$this.themePluginCarousel(opts);
});
});
}
}
});
});
/*
* Dialog with CSS animation
*/
$('.popup-with-zoom-anim').magnificPopup({
type: 'inline',
fixedContentPos: false,
fixedBgPos: true,
overflowY: 'auto',
closeBtnInside: true,
preloader: false,
midClick: true,
removalDelay: 300,
mainClass: 'my-mfp-zoom-in'
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,134 @@
/*
Name: Demo Personal Portfolio 1
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
/*
Horizontal Scroller Section
*/
if( $('.horizontal-scroller-item').length ) {
if (typeof gsap !== 'undefined') {
// Copy Original HTML to clone on Resize.
const originalScrollHTML = $('.horizontal-scroller').html();
// Generate Scroller
const generateScroller = () => {
let images = gsap.utils.toArray('.horizontal-scroller-item');
gsap.to(images, {
xPercent: -100 * (images.length - 1),
ease: 'none',
scrollTrigger: {
trigger: '.horizontal-scroller',
pin: true,
scrub: 1,
snap: 1 / (images.length - 1),
end: () => '+=' + document.querySelector('.horizontal-scroller-images').offsetWidth
}
});
};
// Resize Event removing and restarting
$(window).afterResize(() => {
setTimeout(() => {
let Alltrigger = ScrollTrigger.getAll();
for (let i = 0; i < Alltrigger.length; i++) {
Alltrigger[i].kill(true);
}
$('.horizontal-scroller-wrapper').empty().html('<section class="horizontal-scroller bg-dark">' + originalScrollHTML + '</section>');
generateScroller();
generateCircleExpand();
}, 500);
});
/*
Circle Expand
*/
var generateCircleExpand = () => {
let section = document.getElementById('circleSection'),
dot = document.getElementById("circleDot");
gsap.set(dot, {
width: "142vmax",
height: "142vmax",
xPercent: -50,
yPercent: -50,
top: "50%",
left: "50%"
});
let tl1 = gsap.timeline({
scrollTrigger: {
trigger: section,
start: "-50%",
end: "0%",
scrub: 2,
invalidateOnRefresh: true,
},
defaults: {
ease: "none"
}
});
tl1
.fromTo(dot, {
scale: 0
}, {
x: 0,
y: 0,
ease: "power3.in",
scale: 1
});
}
// Init GSAP Elements
generateScroller();
generateCircleExpand();
} else {
theme.fn.showErrorMessage('Failed to Load File', 'Failed to load: GSAP - Include the following file(s): (vendor/gsap/gsap.min.js)');
}
/*
Spotlight Cursor Text - Credits: https://codepen.io/carolineartz/pen/rNaGQYo
*/
if( $('.spotlight-cursor-text').length ) {
if (typeof gsap !== 'undefined') {
document.body.addEventListener('mousemove', ({clientX, clientY}) => {
const mouseX = clientX;
const mouseY = clientY;
gsap.to('.shape', {
x: mouseX,
y: mouseY,
stagger: -0.1
});
});
} else {
theme.fn.showErrorMessage('Failed to Load File', 'Failed to load: GSAP - Include the following file(s): (vendor/gsap/gsap.min.js)');
}
}
}
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,49 @@
/*
Name: Demo Personal Portfolio 2
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
/*
Locomotive
*/
if (typeof LocomotiveScroll !== 'undefined') {
window.scrollTo(0,0);
setTimeout(() => {
const scroller = new LocomotiveScroll({
el: document.querySelector("[data-scroll-container]"),
smooth: true,
mobile: {
breakpoint: 0,
smooth: true
},
tablet: {
breakpoint: 0,
smooth: true
}
});
$('[data-hash]').off().on('click', function(e) {
e.preventDefault();
e.stopPropagation();
const anchor = $($(this).attr('href')).get(0);
scroller.scrollTo(anchor);
});
}, 100);
window.onbeforeunload = () => {
window.scrollTo(0,0);
};
} else {
theme.fn.showErrorMessage('Failed to Load File', 'Failed to load: Locomotive Scroll - Include the following file(s): (vendor/locomotive-scroll/locomotive-scroll.min.js)');
}
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,97 @@
/*
Name: Demo Personal Portfolio 3
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
// Disable Scroll to Top
theme.PluginScrollToTop.initialize = () => {};
(($ => {
/*
Locomotive
*/
if (typeof LocomotiveScroll !== 'undefined') {
setTimeout(() => {
const pageContainer = document.querySelector("[data-scroll-container]");
pageContainer.setAttribute("data-scroll-container", "");
const scroller = new LocomotiveScroll({
el: pageContainer,
smooth: true,
mobile: {
breakpoint: 0,
smooth: true
},
tablet: {
breakpoint: 0,
smooth: true
}
});
ScrollTrigger.scrollerProxy(pageContainer, {
getBoundingClientRect() {
return {
left: 0,
top: 0,
width: window.innerWidth,
height: window.innerHeight
};
},
pinType: pageContainer.style.transform ? "transform" : "fixed"
});
const scrollColorElems = document.querySelectorAll("[data-bgcolor]");
scrollColorElems.forEach((colorSection, i) => {
const prevBg = i === 0 ? "" : scrollColorElems[i - 1].dataset.bgcolor;
ScrollTrigger.create({
trigger: colorSection,
scroller: "[data-scroll-container]",
start: "33% 50%",
onEnter: () =>
gsap.to(".bg-color-changer", {
backgroundColor: colorSection.dataset.bgcolor,
overwrite: "auto"
}),
onLeaveBack: () =>
gsap.to(".bg-color-changer", {
backgroundColor: prevBg,
overwrite: "auto"
})
});
});
$('[data-hash]').off().on('click', function(e) {
e.preventDefault();
e.stopPropagation();
const anchor = $($(this).attr('href')).get(0);
$('.hamburguer-btn-side-header.active').trigger('click');
scroller.scrollTo(anchor);
});
scroller.on("scroll", ScrollTrigger.update);
ScrollTrigger.addEventListener("refresh", () => scroller.update());
ScrollTrigger.refresh();
window.scrollTo(0,1);
}, 100);
window.onbeforeunload = () => {
window.scrollTo(0,0);
};
} else {
theme.fn.showErrorMessage('Failed to Load File', 'Failed to load: Locomotive Scroll - Include the following file(s): (vendor/locomotive-scroll/locomotive-scroll.min.js)');
}
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,879 @@
/*
Name: Photography
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
// Disable Scroll to Top
theme.PluginScrollToTop.initialize = () => {};
(($ => {
// Slider Options
const sliderOptions = {
sliderType: 'standard',
sliderLayout: 'fullscreen',
fullScreenOffsetContainer: '#header',
delay: 5000,
disableProgressBar: 'on',
gridwidth: 1170,
gridheight: 500,
lazyType: "none",
shadow: 0,
spinner: "off",
shuffle: "off",
autoHeight: "off",
fullScreenAlignForce: "off",
fullScreenOffset: "",
hideThumbsOnMobile: "off",
hideSliderAtLimit: 0,
hideCaptionAtLimit: 0,
hideAllCaptionAtLilmit: 0,
debugMode: false,
fallbacks: {
simplifyAll: "off",
nextSlideOnWindowFocus: "off",
disableFocusListener: false,
},
navigation: {
keyboardNavigation: "on",
keyboard_direction: "horizontal",
mouseScrollNavigation: "on",
onHoverStop: "off",
touch: {
touchenabled: "on",
swipe_threshold: 75,
swipe_min_touches: 1,
swipe_direction: "horizontal",
drag_block_vertical: false
},
arrows: {
enable: true,
style: "arrows-portfolio-detail-1",
left : {
container:"slider",
h_align:"left",
v_align:"center",
h_offset:0,
v_offset:0,
},
right : {
v_align:"center",
container:"slider",
h_align:"right",
h_offset:0,
v_offset:0
}
}
},
parallax:{
type:"on",
levels:[20,40,60,80,100],
origo:"enterpoint",
speed:400,
bgparallax:"on",
disable_onmobile:"off"
}
};
if( $('.photography-demo-3').get(0) ) {
sliderOptions.fullScreenOffsetContainer = null;
sliderOptions.navigation.arrows.style = 'arrows-side-header-1';
sliderOptions.navigation.arrows.hide_onleave = false;
if( $(window).width() < 992 ) {
sliderOptions.fullScreenOffsetContainer = '#header';
}
}
if( $('.photography-demo-2').get(0) ) {
sliderOptions.fullScreenOffsetContainer = null;
sliderOptions.navigation.arrows.style = 'arrows-transparent-header-photography-1';
sliderOptions.navigation.arrows.hide_onleave = false;
sliderOptions.navigation.arrows.left.h_offset = 20;
sliderOptions.navigation.arrows.right.h_offset = 20;
}
if( $('.rev_about_us').get(0) ) {
sliderOptions.navigation.mouseScrollNavigation = false;
}
// Slider Init
$(window).on('load', () => {
$('#revolutionSlider').revolution(sliderOptions);
});
/*
Custom Portfolio Details Load More
*/
const portfolioDetailLoadMore = {
pages: 0,
currentPage: 0,
$wrapper: $('#portfolioDetailLoadMoreWrapper'),
$btn: $('#portfolioDetailLoadMore'),
$btnWrapper: $('#portfolioDetailLoadMoreBtnWrapper'),
$loader: $('#portfolioDetailLoadMoreLoader'),
build() {
const self = this;
self.pages = self.$wrapper.data('total-pages');
if(self.pages <= 1) {
self.$btnWrapper.remove();
return;
} else {
// init isotope
self.$wrapper.isotope();
self.$btn.on('click', () => {
self.loadMore();
});
// Lazy Load
if(self.$btn.hasClass('btn-portfolioDetail-lazy-load')) {
theme.fn.intObs( '#portfolioDetailLoadMore', "$('#portfolioDetailLoadMore').trigger('click');", {
rootMargin: '0px 0px 0px 0px'
} );
}
}
},
loadMore() {
const self = this;
self.$btn.hide();
self.$loader.show();
// Ajax
$.ajax({
url: 'ajax/demo-photography-portfolio-ajax-on-page-load-more.html',
complete({responseText}) {
const $items = $(responseText);
setTimeout(() => {
self.$wrapper.append($items)
self.$wrapper.isotope('appended', $items);
self.$wrapper.isotope('layout');
self.currentPage++;
if(self.currentPage < self.pages) {
self.$btn.show().blur();
} else {
self.$btnWrapper.remove();
}
self.$wrapper.on( 'layoutComplete', laidOutItems => {
// Carousel
$(() => {
$('[data-plugin-carousel]:not(.manual), .owl-carousel:not(.manual)').each(function() {
const $this = $(this);
let opts;
const pluginOptions = theme.fn.getOptions($this.data('plugin-options'));
if (pluginOptions)
opts = pluginOptions;
$this.themePluginCarousel(opts);
setTimeout(() => {
$this.owlCarousel('refresh');
}, 1);
});
});
});
// Ajax On Page
ajaxOnPagePortfolioDetails.build();
self.$loader.hide();
// Refresh Parallax
$(window).trigger('scroll');
}, 1000);
}
});
}
};
if($('#portfolioDetailLoadMoreWrapper').get(0)) {
portfolioDetailLoadMore.build();
}
/*
Custom Portfolio Infinite Scroll
*/
const portfolioInfiniteScroll = {
pages: 0,
currentPage: 0,
$wrapper: $('.portfolioInfiniteScrollWrapper'),
$btn: $('#portfolioInfiniteScrollLoadMore'),
$btnWrapper: $('#portfolioInfiniteScrollLoadMoreBtnWrapper'),
$loader: $('#portfolioInfiniteScrollLoadMoreLoader'),
build() {
const self = this;
self.pages = self.$wrapper.data('total-pages');
if(self.pages <= 1) {
self.$btnWrapper.remove();
return;
} else {
// init isotope
self.$wrapper.isotope();
self.$btn.on('click', () => {
self.loadMore();
});
// Lazy Load
if(self.$btn.hasClass('btn-portfolioInfiniteScroll-lazy-load')) {
theme.fn.intObs( '#portfolioInfiniteScrollLoadMore', "$('#portfolioInfiniteScrollLoadMore').trigger('click');", {
rootMargin: '0px 0px 0px 0px'
}, true );
}
}
},
loadMore() {
const self = this;
self.$btn.hide();
self.$loader.show();
// Ajax
$.ajax({
url: 'ajax/demo-photography-portfolio-infinite-scroll-load-more.html',
complete({responseText}) {
const $items = $(responseText);
setTimeout(() => {
self.$wrapper.append($items)
self.$wrapper.isotope('appended', $items);
self.$wrapper.isotope('layout');
self.currentPage++;
if(self.currentPage < self.pages) {
self.$btn.show().blur();
} else {
self.$btnWrapper.remove();
}
self.$wrapper.on( 'layoutComplete', laidOutItems => {
// Add new items to gallery
self.$wrapper.find('.item-appended').each(function(){
const imgsrc = $(this).find('.thumb-info-background').attr('data-src'), imgThumbsrc = $(this).find('.thumb-info-background').attr('data-thumb-src'), clone = $('#thumbGalleryDetail .owl-item > div').first().clone(), cloneThumb = $('#thumbGalleryThumbs .owl-item > div').first().clone();
// Create images
clone.find('img').attr('src',imgsrc);
cloneThumb.find('img').attr('src',imgThumbsrc);
// Add images
$('#thumbGalleryDetail').owlCarousel().trigger('add.owl.carousel', [clone]);
$('#thumbGalleryThumbs').owlCarousel().trigger('add.owl.carousel', [cloneThumb]);
$(this).removeClass('item-appended');
});
// Carousel
$(() => {
$('[data-plugin-carousel]:not(.manual), .owl-carousel:not(.manual)').each(function() {
const $this = $(this);
let opts;
const pluginOptions = theme.fn.getOptions($this.data('plugin-options'));
if (pluginOptions)
opts = pluginOptions;
$this.themePluginCarousel(opts);
setTimeout(() => {
$this.owlCarousel('refresh');
}, 1);
});
});
// Lightbox - Clicked Item
$('a[href="#photographyLightbox"]').on('click', function(){
if($('.grid-sizer').get(0)) {
clickedItem = $(this).parent().parent().index() - 1;
} else {
clickedItem = $(this).parent().parent().index();
}
});
// Lightbox
$('.popup-with-move-anim').magnificPopup(portfolioLightboxOptions);
});
self.$loader.hide();
// Refresh Parallax
$(window).trigger('scroll');
}, 1000);
}
});
}
};
if($('.portfolioInfiniteScrollWrapper').get(0)) {
portfolioInfiniteScroll.build();
}
/*
* Ajax on Page
*/
var ajaxOnPagePortfolioDetails = {
pages: [],
$ajaxBox: $('#porfolioDetailsAjaxBox'),
$ajaxBoxContent: $('#porfolioDetailsAjaxBoxContent'),
build() {
const self = this;
$('a[data-ajax-on-page]').each(function() {
self.add($(this));
});
$(document).on('mousedown', 'a[data-ajax-on-page]', ev => {
if (ev.which == 2) {
ev.preventDefault();
return false;
}
});
},
add($el) {
const self = this, href = $el.attr('data-href');
self.pages.push(href);
$el.on('click', e => {
e.preventDefault();
self.show(self.pages.indexOf(href));
});
},
events() {
const self = this;
// Slider
sliderOptions.navigation.mouseScrollNavigation = false;
$('#revolutionSlider').revolution(sliderOptions);
// Carousel
if ($.isFunction($.fn['themePluginCarousel'])) {
$(() => {
$('[data-plugin-carousel]:not(.manual), .owl-carousel:not(.manual)').each(function() {
const $this = $(this);
let opts;
const pluginOptions = theme.fn.getOptions($this.data('plugin-options'));
if (pluginOptions)
opts = pluginOptions;
$this.themePluginCarousel(opts);
});
});
}
},
show(i) {
const self = this;
self.$ajaxBoxContent.empty();
self.$ajaxBox.removeClass('ajax-box-init').addClass('ajax-box-loading');
$('html, body').animate({
scrollTop: self.$ajaxBox.offset().top - 100
}, 300, 'easeOutQuad');
// Ajax
$.ajax({
url: self.pages[i],
complete({responseText}) {
setTimeout(() => {
self.$ajaxBoxContent.html(responseText);
self.$ajaxBox.removeClass('ajax-box-loading');
self.events();
}, 1000);
}
});
}
}
if($('#porfolioDetailsAjaxBox').get(0)) {
ajaxOnPagePortfolioDetails.build();
}
/*
* Portfolio Grid - Init isotope
*/
$(window).on('load', () => {
const $portfolioGrid = $('#portfolioGrid'), $ourBlog = $('#ourBlog'), gridSizer = $portfolioGrid.attr('data-grid-sizer');
// Portfolio Grid
if( $portfolioGrid.get(0) ) {
$portfolioGrid.isotope({
itemSelector: '.isotope-item',
masonry: {
columnWidth: gridSizer,
gutter: 0
}
});
$portfolioGrid.isotope('layout');
}
if( $ourBlog.get(0) ) {
$ourBlog.isotope({
itemSelector: '.isotope-item',
masonry: {
gutter: 0
}
});
$ourBlog.isotope('layout');
}
});
/*
* Horizontal Scroll
*/
const $horizontalScroll = {
$horizontalScrollWrapper : $('#horizontalScrollBox'),
$horizontalScrollContent : $('#horizontalScrollBox .content'),
$horizontalScrollItem : $('#horizontalScrollBox .content .horizontal-scroll-item-wrapper'),
build() {
const self = this;
self.setContentWidth();
self.buttonNavigation();
self.disableEnableButtons();
},
setContentWidth() {
const self = this;
let totalWidth = 0;
$(self.$horizontalScrollItem).each(function(e){
const boxImageWidth = $(this).outerWidth(true);
totalWidth = (totalWidth + boxImageWidth);
});
self.$horizontalScrollContent.width( totalWidth );
},
isElementInView(element, fullyInView) {
const pageLeft = $(window).scrollLeft(), pageRight = pageLeft + $(window).width(), elementLeft = $(element).offset().left, elementRight = elementLeft + $(element).width();
if (fullyInView === true) {
return ((pageLeft < elementLeft) && (pageRight > elementRight));
} else {
return ((elementLeft <= pageRight) && (elementRight >= pageLeft));
}
},
buttonNavigation() {
const self = this;
const nextButton = self.$horizontalScrollWrapper.find('.custom-portfolio-navigation .next');
const prevButton = self.$horizontalScrollWrapper.find('.custom-portfolio-navigation .prev');
const totalItems = self.$horizontalScrollItem.length - 1;
let screen = 0;
let distance = 0;
let index = 0;
let flag = false;
let atualItem;
prevButton.on('click', () => {
if( !flag ){
flag = true;
if( index > 0 ) {
index--;
}
atualItem = self.$horizontalScrollItem.eq(index);
// Check if Element in View
const isElementInView = self.isElementInView(atualItem, false);
if( !isElementInView ) {
self.$horizontalScrollItem.each(function(){
const inView = self.isElementInView($(this), false);
if( inView ) {
atualItem = $(this);
return false;
}
});
}
// If Demo 3
if($('.photography-demo-3').get(0)) {
screen = (($(window).width() - 255 ) - atualItem.outerWidth(true)) / 2;
} else {
screen = ($(window).width() - atualItem.outerWidth(true)) / 2;
}
distance = (atualItem.position().left - screen);
$('#horizontalScrollBox').animate({ scrollLeft: distance }, 300, () => {
flag = false;
});
}
});
nextButton.on('click', () => {
if( !flag ){
flag = true;
if( index < totalItems ) {
index++;
}
atualItem = self.$horizontalScrollItem.eq(index);
// Check if Element in View
const isElementInView = self.isElementInView(atualItem, false);
if( !isElementInView ) {
self.$horizontalScrollItem.each(function(){
const inView = self.isElementInView($(this), false);
if( inView ) {
atualItem = $(this);
index = $(this).index();
return false;
}
});
}
// If Demo 3
if($('.photography-demo-3').get(0)) {
screen = (($(window).width() - 255 ) - atualItem.outerWidth(true)) / 2;
} else {
screen = ($(window).width() - atualItem.outerWidth(true)) / 2;
}
distance = (atualItem.position().left - screen);
$('#horizontalScrollBox').animate({ scrollLeft: distance }, 300, () => {
flag = false;
});
}
});
},
disableEnableButtons() {
const self = this, nextButton = self.$horizontalScrollWrapper.find('.custom-portfolio-navigation .next'), prevButton = self.$horizontalScrollWrapper.find('.custom-portfolio-navigation .prev');
self.$horizontalScrollWrapper.on('scroll', function(){
if( $(this).scrollLeft() == 0 ) {
prevButton.addClass('disable-button');
} else {
prevButton.removeClass('disable-button');
}
if( $(this).scrollLeft() > ((self.$horizontalScrollContent.width() - $(window).width()) - 1) ) {
nextButton.addClass('disable-button');
} else {
nextButton.removeClass('disable-button');
}
});
}
};
if($('#horizontalScrollBox').get(0)) {
$horizontalScroll.build();
$(window).trigger('resize');
const $window = $(window);
// Mousewheel horizontal scroll
$('#horizontalScrollBox').mousewheel(function(event, delta) {
if ($window.width() > 991) {
this.scrollLeft -= (delta * 60);
event.preventDefault();
}
});
// Build $horizontalScroll on resize
$window.on('load', () => {
$(document).ready(() => {
$(window).afterResize(() => {
$horizontalScroll.setContentWidth();
if($('.photography-demo-2').get(0)) {
$(".thumb-info-wrapper img").css('transition','ease all 5s');
$(".thumb-info-wrapper img").on("webkitTransitionEnd otransitionend oTransitionEnd msTransitionEnd transitionend", e => {
$horizontalScroll.setContentWidth();
});
}
});
if($('.photography-demo-2').get(0)) {
$(window).on('resize', () => {
$(".thumb-info-wrapper img").css('transition','none');
});
}
$(window).trigger('resize');
});
});
}
/*
* Lightbox
*/
var clickedItem;
let removeShowThumbsTimeout;
var portfolioLightboxOptions = {
type: 'inline',
fixedContentPos: true,
fixedBgPos: true,
overflowY: 'hidden',
closeBtnInside: true,
preloader: false,
midClick: true,
removalDelay: 300,
mainClass: 'photography-portfolio-gallery',
callbacks: {
open() {
$('#thumbGalleryDetail').owlCarousel().trigger('refresh.owl.carousel');
$('#thumbGalleryDetail').owlCarousel().trigger('to.owl.carousel', [clickedItem, 0]);
$('#thumbGalleryThumbs').owlCarousel('refresh');
removeShowThumbsTimeout = setTimeout(() => {
$('#thumbGalleryThumbs').removeClass('show-thumbs');
}, 3000);
$(document).on('keydown', ({keyCode}) => {
if(keyCode == 37) {
$('#thumbGalleryDetail').trigger('prev.owl')
}
if(keyCode == 39) {
$('#thumbGalleryDetail').trigger('next.owl')
}
});
},
close() {
clearTimeout(removeShowThumbsTimeout);
$('#thumbGalleryThumbs').addClass('show-thumbs');
$(document).off('keydown');
}
}
};
if($('a[href="#photographyLightbox"]').get(0)) {
$('a[href="#photographyLightbox"]').on('click', function(){
if($('.grid-sizer').get(0)) {
clickedItem = $(this).parent().parent().index() - 1;
} else {
clickedItem = $(this).parent().parent().index();
}
});
$('a[href="#photographyLightbox"]').magnificPopup(portfolioLightboxOptions);
}
/*
Thumb Gallery
*/
if( $('#photographyLightbox').get(0) ) {
var $thumbGalleryDetail = $('#thumbGalleryDetail'),
$thumbGalleryThumbs = $('#thumbGalleryThumbs'),
flag = false,
duration = 300;
$thumbGalleryDetail
.owlCarousel({
items: 1,
margin: 10,
nav: true,
dots: false,
loop: false,
navText: [],
rtl: (($('html[dir="rtl"]').get(0)) ? true : false),
onRefreshed(e) {
setTimeout(() => {
$('.mfp-wrap.photography-portfolio-gallery').css('opacity',1);
}, 300);
}
})
.on('changed.owl.carousel', ({item}) => {
if (!flag) {
flag = true;
$thumbGalleryThumbs.trigger('to.owl.carousel', [item.index-1, duration, true]);
// add class to active thumb
$thumbGalleryThumbs.find('.owl-item').removeClass('active-thumb');
$thumbGalleryThumbs.find('.owl-item:eq('+ item.index +')').addClass('active-thumb');
flag = false;
}
});
$thumbGalleryThumbs
.owlCarousel({
margin: 15,
items: 15,
nav: false,
center: false,
dots: false,
pagination: false,
rtl: (($('html[dir="rtl"]').get(0)) ? true : false)
})
.on('click', '.owl-item', function() {
$thumbGalleryDetail.trigger('to.owl.carousel', [$(this).index(), duration, true]);
// add class to active thumb
$thumbGalleryThumbs.find('.owl-item').removeClass('active-thumb');
$(this).addClass('active-thumb');
});
// Set first item with active-thumb
$thumbGalleryThumbs.find('.owl-item:eq(0)').addClass('active-thumb');
}
if( $('#portfolioSliderWithThumbs').get(0) ) {
var $thumbGalleryDetail = $('#thumbGalleryDetail'),
$thumbGalleryThumbs = $('#thumbGalleryThumbs'),
flag = false,
duration = 300;
$thumbGalleryDetail
.owlCarousel({
items: 1,
margin: 10,
nav: true,
dots: false,
loop: false,
navText: [],
rtl: (($('html[dir="rtl"]').get(0)) ? true : false),
onRefreshed(e) {
setTimeout(() => {
$('.mfp-wrap.photography-portfolio-gallery').css('opacity',1);
}, 300);
}
})
.on('changed.owl.carousel', ({item}) => {
if (!flag) {
flag = true;
$thumbGalleryThumbs.trigger('to.owl.carousel', [item.index-1, duration, true]);
// add class to active thumb
$thumbGalleryThumbs.find('.owl-item').removeClass('active-thumb');
$thumbGalleryThumbs.find('.owl-item:eq('+ item.index +')').addClass('active-thumb');
flag = false;
}
});
$thumbGalleryThumbs
.owlCarousel({
margin: 15,
items: 8,
nav: false,
center: false,
dots: false,
pagination: false,
rtl: (($('html[dir="rtl"]').get(0)) ? true : false),
responsive:{
0:{
items:2
},
300:{
items:3
},
767:{
items:6,
},
991:{
items:7,
},
1200:{
items:8,
}
}
})
.on('click', '.owl-item', function() {
$thumbGalleryDetail.trigger('to.owl.carousel', [$(this).index(), duration, true]);
// add class to active thumb
$thumbGalleryThumbs.find('.owl-item').removeClass('active-thumb');
$(this).addClass('active-thumb');
});
// Set first item with active-thumb
$thumbGalleryThumbs.find('.owl-item:eq(0)').addClass('active-thumb');
$(document).on('keydown', ({keyCode}) => {
if(keyCode == 37) {
$('#thumbGalleryDetail').trigger('prev.owl')
}
if(keyCode == 39) {
$('#thumbGalleryDetail').trigger('next.owl')
}
});
}
})).apply(this, [jQuery]);

View File

@ -0,0 +1,26 @@
/*
Name: Product Landing
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
/*
Quantity
*/
$('.quantity .plus').on('click',function(){
const $qty=$(this).parents('.quantity').find('.qty');
const currentVal = parseInt($qty.val());
if (!isNaN(currentVal)) {
$qty.val(currentVal + 1);
}
});
$('.quantity .minus').on('click',function(){
const $qty=$(this).parents('.quantity').find('.qty');
const currentVal = parseInt($qty.val());
if (!isNaN(currentVal) && currentVal > 0) {
$qty.val(currentVal - 1);
}
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,82 @@
/*
Name: RealEstate
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
/*
Header
*/
// Search Properties
const $headerWrapper = $('#headerSearchProperties'), $window = $(window);
$headerWrapper.on('click', () => {
if ($window.width() > 992) {
$headerWrapper.addClass('open');
}
});
$(document).mouseup(({target}) => {
if (!$headerWrapper.is(target) && $headerWrapper.has(target).length === 0) {
$headerWrapper.removeClass('open');
}
});
$('#propertiesFormHeader').validate({
onkeyup: false,
onclick: false,
onfocusout: false,
errorPlacement(error, element) {
if (element.attr('type') == 'radio' || element.attr('type') == 'checkbox') {
error.appendTo(element.parent().parent());
} else {
error.insertAfter(element);
}
}
});
// Thumb Gallery
const $thumbGalleryDetail1 = $('#thumbGalleryDetail');
const $thumbGalleryThumbs1 = $('#thumbGalleryThumbs');
let flag = false;
const duration = 300;
$thumbGalleryDetail1
.owlCarousel({
items: 1,
margin: 10,
nav: true,
dots: false,
loop: false,
navText: [],
rtl: ( $('html').attr('dir') == 'rtl' ) ? true : false
})
.on('changed.owl.carousel', ({item}) => {
if (!flag) {
flag = true;
$thumbGalleryThumbs1.trigger('to.owl.carousel', [item.index-1, duration, true]);
flag = false;
}
});
$thumbGalleryThumbs1
.owlCarousel({
margin: 15,
items: 4,
nav: false,
center: false,
dots: false,
rtl: ( $('html').attr('dir') == 'rtl' ) ? true : false
})
.on('click', '.owl-item', function() {
$thumbGalleryDetail1.trigger('to.owl.carousel', [$(this).index(), duration, true]);
})
.on('changed.owl.carousel', ({item}) => {
if (!flag) {
flag = true;
$thumbGalleryDetail1.trigger('to.owl.carousel', [item.index, duration, true]);
flag = false;
}
});

View File

@ -0,0 +1,5 @@
/*
Name: Demo Renewable Energy
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/

View File

@ -0,0 +1,70 @@
/*
Name: Resume
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
// About Me
$('#aboutMeMoreBtn').on('click', function() {
$(this).hide();
$('#aboutMeMore').toggleClass('about-me-more-visible');
return false;
});
/*
* Timeline
*/
const timelineHeightAdjust = {
$timeline: $('#timeline'),
$timelineBar: $('#timeline .timeline-bar'),
$firstTimelineItem: $('#timeline .timeline-box').first(),
$lastTimelineItem: $('#timeline .timeline-box').last(),
build() {
const self = this;
self.adjustHeight();
},
adjustHeight() {
const self = this, calcFirstItemHeight = self.$firstTimelineItem.outerHeight(true) / 2, calcLastItemHeight = self.$lastTimelineItem.outerHeight(true) / 2;
// Set Timeline Bar Top and Bottom
self.$timelineBar.css({
top: calcFirstItemHeight,
bottom: calcLastItemHeight
});
}
};
if( $('#timeline').get(0) ) {
setTimeout(() => {
// Adjust Timeline Height On Resize
$(window).afterResize(() => {
timelineHeightAdjust.build();
});
}, 1000);
timelineHeightAdjust.build();
}
/*
* Header Image Anim
*/
let lastScrollTop = 0;
$(window).on('scroll', function(){
const st = $(this).scrollTop();
if (st > lastScrollTop){
$('img[custom-anim]').css({
transform: 'translate(0, -'+ st +'px)'
});
} else {
$('img[custom-anim]').css({
transform: 'translate(0, '+ -Math.abs(st) +'px)'
});
}
lastScrollTop = st;
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,26 @@
/*
Name: SEO 2
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
/**
* Custom Simple Form Validation
*
*/
$('.custom-form-simple-validation').each(function(){
$(this).validate({
onkeyup: false,
onclick: false,
onfocusout: false,
errorPlacement(error, element) {
if (element.attr('type') == 'radio' || element.attr('type') == 'checkbox') {
error.appendTo(element.closest('.form-group'));
} else {
error.insertAfter(element);
}
}
});
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,81 @@
/*
Name: Demo SEO 3
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
/*
Mouse Hover Split
*/
const left = document.getElementById("side-left");
const handleMove = ({clientX}) => {
left.style.width = `${clientX / window.innerWidth * 100}%`;
}
document.onmousemove = e => handleMove(e);
document.ontouchmove = ({touches}) => handleMove(touches[0]);
$(window).on('load resize', () => {
const height = $('.mouse-hover-split .side').height();
$('.mouse-hover-split').css('min-height', height);
});
/*
Horizontal Scroller Section
*/
if( $('.horizontal-scroller-item').length ) {
if (typeof gsap !== 'undefined') {
// Copy Original HTML to clone on Resize.
const originalScrollHTML = $('.horizontal-scroller').html();
// Generate Scroller
const generateScroller = () => {
let images = gsap.utils.toArray('.horizontal-scroller-item');
gsap.to(images, {
xPercent: -100 * (images.length - ( $(window).width() > 991 ? 3 : 1 )),
ease: 'none',
scrollTrigger: {
trigger: '.horizontal-scroller',
pin: true,
scrub: 1,
snap: 1 / (images.length - 1),
end: () => '+=' + document.querySelector('.horizontal-scroller-images').offsetWidth
}
});
};
// Resize Event removing and restarting
$(window).afterResize(() => {
setTimeout(() => {
let Alltrigger = ScrollTrigger.getAll();
for (let i = 0; i < Alltrigger.length; i++) {
Alltrigger[i].kill(true);
}
$('.horizontal-scroller-wrapper').empty().html('<section class="horizontal-scroller bg-dark">' + originalScrollHTML + '</section>');
generateScroller();
}, 500);
});
generateScroller();
} else {
theme.fn.showErrorMessage('Failed to Load File', 'Failed to load: GSAP - Include the following file(s): (vendor/gsap/gsap.min.js)');
}
}
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,58 @@
/*
Name: SEO
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
/*
SVG Morphing
*/
setTimeout(() => {
if( $('#shape_one_start').get(0) ) {
const shape1 = KUTE.fromTo('#shape_one_start', {
path: '#shape_one_start'
}, {
path: '#shape_one_end'
}, {
duration: 10000,
easing : 'easingQuadraticInOut',
repeat: 20,
repeatDelay: 1000,
yoyo: true
}).start();
}
if( $('#shape_two_start').get(0) ) {
const shape2 = KUTE.fromTo('#shape_two_start', {
path: '#shape_two_start'
}, {
path: '#shape_two_end'
}, {
duration: 10000,
easing : 'easingQuadraticInOut',
repeat: 20,
repeatDelay: 1000,
yoyo: true
}).start();
}
}, 100);
/*
Form
*/
$('.popup-with-form').magnificPopup({
type: 'inline',
preloader: false,
focus: '#name',
mainClass: 'my-mfp-zoom-in',
callbacks: {
open() {
$('html').addClass('lightbox-opened');
},
close() {
$('html').removeClass('lightbox-opened');
}
}
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,94 @@
/*
Name: Startup Agency
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
/*
SVG Morphing
*/
$(window).on('load', () => {
setTimeout(() => {
if( $('#st0_start').get(0) ) {
var shape1 = KUTE.fromTo('#st0_start', {
path: '#st0_start'
}, {
path: '#st0_end'
}, {
duration: 10000,
easing : 'easingQuadraticInOut',
repeat: 20,
repeatDelay: 1000,
yoyo: true
}).start();
}
if( $('#st1_start').get(0) ) {
var shape1 = KUTE.fromTo('#st1_start', {
path: '#st1_start'
}, {
path: '#st1_end'
}, {
duration: 10000,
easing : 'easingQuadraticInOut',
repeat: 20,
repeatDelay: 1000,
yoyo: true
}).start();
}
if( $('#st2_start').get(0) ) {
var shape1 = KUTE.fromTo('#st2_start', {
path: '#st2_start'
}, {
path: '#st2_end'
}, {
duration: 10000,
easing : 'easingQuadraticInOut',
repeat: 20,
repeatDelay: 1000,
yoyo: true
}).start();
}
if( $('#st3_start').get(0) ) {
var shape1 = KUTE.fromTo('#st3_start', {
path: '#st3_start'
}, {
path: '#st3_end'
}, {
duration: 10000,
easing : 'easingQuadraticInOut',
repeat: 20,
repeatDelay: 1000,
yoyo: true
}).start();
}
/*
* SVG Aspect Ratio
*/
function aspectRatioSVG() {
if( $(window).width() < 2000 ) {
$('svg[preserveAspectRatio]').each(function(){
$(this).attr('preserveAspectRatio', 'xMinYMin');
});
} else {
$('svg[preserveAspectRatio]').each(function(){
$(this).attr('preserveAspectRatio', 'none');
});
}
}
aspectRatioSVG();
$(window).on('resize', () => {
aspectRatioSVG();
});
}, 100);
});
})).apply( this, [ jQuery ]);

View File

@ -0,0 +1,5 @@
/*
Name: Demo Transportation Logistic
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/

View File

@ -0,0 +1,204 @@
/*
Name: Wedding
Written by: Okler Themes - (http://www.okler.net)
Theme Version: 12.1.0
*/
(($ => {
/*
Slider
*/
$('#revolutionSlider').revolution({
sliderType: 'standard',
sliderLayout: 'fullwidth',
delay: 9000,
responsiveLevels: [1920, 1200, 992, 500],
gridwidth: [1920, 1200, 992, 500],
gridheight: 780,
disableProgressBar: 'on',
spinner: 'spinner3',
parallax: {
type: "mouse",
origo: "slidercenter",
speed: 2000,
levels: [2, 3, 4, 5, 6, 7, 12, 16, 10, 50],
},
navigation: {
arrows: {
style: "hades",
enable: false,
hide_onmobile: false,
hide_onleave: false,
tmp: '<div class="tp-arr-allwrapper"><div class="tp-arr-imgholder"></div></div>',
left: {
h_align: "left",
v_align: "center",
h_offset: 10,
v_offset: 0
},
right: {
h_align: "right",
v_align: "center",
h_offset: 10,
v_offset: 0
}
}
}
});
$('#revolutionSlider2').revolution({
sliderType: 'standard',
sliderLayout: 'fullwidth',
delay: 9000,
responsiveLevels: [1920, 1200, 992, 500],
gridwidth: [1920, 1200, 992, 500],
gridheight: 575,
disableProgressBar: 'on',
spinner: 'spinner3',
parallax: {
type: "mouse",
origo: "slidercenter",
speed: 2000,
levels: [2, 3, 4, 5, 6, 7, 12, 16, 10, 50],
},
navigation: {
arrows: {
style: "hades",
enable: false,
hide_onmobile: false,
hide_onleave: false,
tmp: '<div class="tp-arr-allwrapper"><div class="tp-arr-imgholder"></div></div>',
left: {
h_align: "left",
v_align: "center",
h_offset: 10,
v_offset: 0
},
right: {
h_align: "right",
v_align: "center",
h_offset: 10,
v_offset: 0
}
}
}
});
// Our History Gallery
var clickedItem;
let removeShowThumbsTimeout;
const portfolioLightboxOptions = {
type: 'inline',
fixedContentPos: true,
fixedBgPos: true,
overflowY: 'hidden',
closeBtnInside: true,
preloader: false,
midClick: true,
removalDelay: 300,
mainClass: 'wedding-portfolio-gallery',
callbacks: {
open() {
$('#thumbGalleryDetail').owlCarousel().trigger('refresh.owl.carousel');
$('#thumbGalleryDetail').owlCarousel().trigger('to.owl.carousel', [clickedItem, 0]);
$('#thumbGalleryThumbs').owlCarousel('refresh');
removeShowThumbsTimeout = setTimeout(() => {
$('#thumbGalleryThumbs').removeClass('show-thumbs');
}, 3000);
$(document).on('keydown', ({keyCode}) => {
if(keyCode == 37) {
$('#thumbGalleryDetail').trigger('prev.owl')
}
if(keyCode == 39) {
$('#thumbGalleryDetail').trigger('next.owl')
}
});
},
close() {
clearTimeout(removeShowThumbsTimeout);
$('#thumbGalleryThumbs').addClass('show-thumbs');
$(document).off('keydown');
}
}
};
var clickedItem = '';
if( $('a[href="#ourHistoryLightbox"]').length ) {
$('a[href="#ourHistoryLightbox"]').on('click', function(){
clickedItem = $(this).parent().index();
});
$('a[href="#ourHistoryLightbox"]').magnificPopup(portfolioLightboxOptions);
}
/*
Thumb Gallery
*/
if( $('#ourHistoryLightbox').get(0) ) {
const $thumbGalleryDetail = $('#thumbGalleryDetail');
const $thumbGalleryThumbs = $('#thumbGalleryThumbs');
let flag = false;
const duration = 300;
$thumbGalleryDetail
.owlCarousel({
items: 1,
margin: 10,
nav: true,
dots: false,
loop: false,
navText: [],
rtl: (($('html[dir="rtl"]').get(0)) ? true : false),
onRefreshed(e) {
setTimeout(() => {
$('.mfp-wrap.wedding-portfolio-gallery').css('opacity',1);
}, 300);
}
})
.on('changed.owl.carousel', ({item}) => {
if (!flag) {
flag = true;
$thumbGalleryThumbs.trigger('to.owl.carousel', [item.index-1, duration, true]);
// add class to active thumb
$thumbGalleryThumbs.find('.owl-item').removeClass('active-thumb');
$thumbGalleryThumbs.find('.owl-item:eq('+ item.index +')').addClass('active-thumb');
flag = false;
}
});
$thumbGalleryThumbs
.owlCarousel({
margin: 15,
items: 15,
nav: false,
center: false,
dots: false,
pagination: false,
rtl: (($('html[dir="rtl"]').get(0)) ? true : false)
})
.on('click', '.owl-item', function() {
$thumbGalleryDetail.trigger('to.owl.carousel', [$(this).index(), duration, true]);
// add class to active thumb
$thumbGalleryThumbs.find('.owl-item').removeClass('active-thumb');
$(this).addClass('active-thumb');
});
// Set first item with active-thumb
$thumbGalleryThumbs.find('.owl-item:eq(0)').addClass('active-thumb');
}
})).apply( this, [ jQuery ]);