first commit

This commit is contained in:
ameye
2019-08-25 14:08:12 -04:00
commit 9cbc6149dd
482 changed files with 97191 additions and 0 deletions
+17
View File
File diff suppressed because one or more lines are too long
+7
View File
File diff suppressed because one or more lines are too long
+65
View File
@@ -0,0 +1,65 @@
// gradient layout
function checkGradeient() {
//gradient animations
var colors = new Array(
[62, 35, 255], [60, 255, 60], [255, 35, 98], [45, 175, 230], [255, 0, 255], [255, 128, 0]);
var step = 0;
//color table indices for:
// current color left
// next color left
// current color right
// next color right
var colorIndices = [0, 1, 2, 3];
//transition speed
var gradientSpeed = 0.002;
function updateGradient() {
if ($ === undefined) return;
var c0_0 = colors[colorIndices[0]];
var c0_1 = colors[colorIndices[1]];
var c1_0 = colors[colorIndices[2]];
var c1_1 = colors[colorIndices[3]];
var istep = 1 - step;
var r1 = Math.round(istep * c0_0[0] + step * c0_1[0]);
var g1 = Math.round(istep * c0_0[1] + step * c0_1[1]);
var b1 = Math.round(istep * c0_0[2] + step * c0_1[2]);
var color1 = "rgb(" + r1 + "," + g1 + "," + b1 + ")";
var r2 = Math.round(istep * c1_0[0] + step * c1_1[0]);
var g2 = Math.round(istep * c1_0[1] + step * c1_1[1]);
var b2 = Math.round(istep * c1_0[2] + step * c1_1[2]);
var color2 = "rgb(" + r2 + "," + g2 + "," + b2 + ")";
$('#gradient').css({
background: "-webkit-gradient(linear, left top, right top, from(" + color1 + "), to(" + color2 + "))"
}).css({
background: "-moz-linear-gradient(left, " + color1 + " 0%, " + color2 + " 100%)"
});
step += gradientSpeed;
if (step >= 1) {
step %= 1;
colorIndices[0] = colorIndices[1];
colorIndices[2] = colorIndices[3];
//pick two new target color indices
//do not pick the same as the current one
colorIndices[1] = (colorIndices[1] + Math.floor(1 + Math.random() * (colors.length - 1))) % colors.length;
colorIndices[3] = (colorIndices[3] + Math.floor(1 + Math.random() * (colors.length - 1))) % colors.length;
}
}
setInterval(updateGradient, 10);
}
if ($("#gradient").length) {
checkGradeient()
}
+12
View File
File diff suppressed because one or more lines are too long
+2
View File
File diff suppressed because one or more lines are too long
+150
View File
@@ -0,0 +1,150 @@
/*
* jQuery.appear
* https://github.com/bas2k/jquery.appear/
* http://code.google.com/p/jquery-appear/
*
* Copyright (c) 2009 Michael Hixson
* Copyright (c) 2012 Alexander Brovikov
* Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)
*/
(function($) {
$.fn.appear = function(fn, options) {
var settings = $.extend({
//arbitrary data to pass to fn
data: undefined,
//call fn only on the first appear?
one: true,
// X & Y accuracy
accX: 0,
accY: 0
}, options);
return this.each(function() {
var t = $(this);
//whether the element is currently visible
t.appeared = false;
if (!fn) {
//trigger the custom event
t.trigger('appear', settings.data);
return;
}
var w = $(window);
//fires the appear event when appropriate
var check = function() {
//is the element hidden?
if (!t.is(':visible')) {
//it became hidden
t.appeared = false;
return;
}
//is the element inside the visible window?
var a = w.scrollLeft();
var b = w.scrollTop();
var o = t.offset();
var x = o.left;
var y = o.top;
var ax = settings.accX;
var ay = settings.accY;
var th = t.height();
var wh = w.height();
var tw = t.width();
var ww = w.width();
if (y + th + ay >= b &&
y <= b + wh + ay &&
x + tw + ax >= a &&
x <= a + ww + ax) {
//trigger the custom event
if (!t.appeared) t.trigger('appear', settings.data);
} else {
//it scrolled out of view
t.appeared = false;
}
};
//create a modified fn with some additional logic
var modifiedFn = function() {
//mark the element as visible
t.appeared = true;
//is this supposed to happen only once?
if (settings.one) {
//remove the check
w.unbind('scroll', check);
var i = $.inArray(check, $.fn.appear.checks);
if (i >= 0) $.fn.appear.checks.splice(i, 1);
}
//trigger the original fn
fn.apply(this, arguments);
};
//bind the modified fn to the element
if (settings.one) t.one('appear', settings.data, modifiedFn);
else t.bind('appear', settings.data, modifiedFn);
//check whenever the window scrolls
w.scroll(check);
//check whenever the dom changes
$.fn.appear.checks.push(check);
//check now
(check)();
});
};
//keep a queue of appearance checks
$.extend($.fn.appear, {
checks: [],
timeout: null,
//process the queue
checkAll: function() {
var length = $.fn.appear.checks.length;
if (length > 0) while (length--) ($.fn.appear.checks[length])();
},
//check the queue asynchronously
run: function() {
if ($.fn.appear.timeout) clearTimeout($.fn.appear.timeout);
$.fn.appear.timeout = setTimeout($.fn.appear.checkAll, 20);
}
});
//run checks when these methods are called
$.each(['append', 'prepend', 'after', 'before', 'attr',
'removeAttr', 'addClass', 'removeClass', 'toggleClass',
'remove', 'css', 'show', 'hide'], function(i, n) {
var old = $.fn[n];
if (old) {
$.fn[n] = function() {
var r = old.apply(this, arguments);
$.fn.appear.run();
return r;
}
}
});
})(jQuery);
+104
View File
@@ -0,0 +1,104 @@
/**
* downCount: Simple Countdown clock with offset
* Author: Sonny T. <hi@sonnyt.com>, sonnyt.com
*/
(function ($) {
$.fn.downCount = function (options, callback) {
var settings = $.extend({
date: null,
offset: null
}, options);
// Throw error if date is not set
if (!settings.date) {
$.error('Date is not defined.');
}
// Throw error if date is set incorectly
if (!Date.parse(settings.date)) {
$.error('Incorrect date format, it should look like this, 12/24/2012 12:00:00.');
}
// Save container
var container = this;
/**
* Change client's local date to match offset timezone
* @return {Object} Fixed Date object.
*/
var currentDate = function () {
// get client's current date
var date = new Date();
// turn date to utc
var utc = date.getTime() + (date.getTimezoneOffset() * 60000);
// set new Date object
var new_date = new Date(utc + (3600000*settings.offset))
return new_date;
};
/**
* Main downCount function that calculates everything
*/
function countdown () {
var target_date = new Date(settings.date), // set target date
current_date = currentDate(); // get fixed current date
// difference of dates
var difference = target_date - current_date;
// if difference is negative than it's pass the target date
if (difference < 0) {
// stop timer
clearInterval(interval);
if (callback && typeof callback === 'function') callback();
return;
}
// basic math variables
var _second = 1000,
_minute = _second * 60,
_hour = _minute * 60,
_day = _hour * 24;
// calculate dates
var days = Math.floor(difference / _day),
hours = Math.floor((difference % _day) / _hour),
minutes = Math.floor((difference % _hour) / _minute),
seconds = Math.floor((difference % _minute) / _second);
// fix dates so that it will show two digets
days = (String(days).length >= 2) ? days : '0' + days;
hours = (String(hours).length >= 2) ? hours : '0' + hours;
minutes = (String(minutes).length >= 2) ? minutes : '0' + minutes;
seconds = (String(seconds).length >= 2) ? seconds : '0' + seconds;
// based on the date change the refrence wording
var ref_days = (days === 1) ? 'day' : 'days',
ref_hours = (hours === 1) ? 'hour' : 'hours',
ref_minutes = (minutes === 1) ? 'minute' : 'minutes',
ref_seconds = (seconds === 1) ? 'second' : 'seconds';
// set to DOM
container.find('.days').text(days);
container.find('.hours').text(hours);
container.find('.minutes').text(minutes);
container.find('.seconds').text(seconds);
container.find('.days_ref').text(ref_days);
container.find('.hours_ref').text(ref_hours);
container.find('.minutes_ref').text(ref_minutes);
container.find('.seconds_ref').text(ref_seconds);
};
// start
var interval = setInterval(countdown, 1000);
};
})(jQuery);
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
+134
View File
@@ -0,0 +1,134 @@
/* ----- Google Map ----- */
if ($("#map").length) {
function initialize() {
var mapOptions = {
zoom: 16,
scrollwheel: false,
styles: [{
"featureType": "water",
"elementType": "geometry",
"stylers": [{
"color": "#e9e9e9"
}, {
"lightness": 17
}]
}, {
"featureType": "landscape",
"elementType": "geometry",
"stylers": [{
"color": "#f5f5f5"
}, {
"lightness": 20
}]
}, {
"featureType": "road.highway",
"elementType": "geometry.fill",
"stylers": [{
"color": "#ffffff"
}, {
"lightness": 17
}]
}, {
"featureType": "road.highway",
"elementType": "geometry.stroke",
"stylers": [{
"color": "#ffffff"
}, {
"lightness": 29
}, {
"weight": 0.2
}]
}, {
"featureType": "road.arterial",
"elementType": "geometry",
"stylers": [{
"color": "#ffffff"
}, {
"lightness": 18
}]
}, {
"featureType": "road.local",
"elementType": "geometry",
"stylers": [{
"color": "#ffffff"
}, {
"lightness": 18
}]
}, {
"featureType": "poi",
"elementType": "geometry",
"stylers": [{
"color": "#f5f5f5"
}, {
"lightness": 21
}]
}, {
"featureType": "poi.park",
"elementType": "geometry",
"stylers": [{
"color": "#d5d5d5"
}, {
"lightness": 21
}]
}, {
"elementType": "labels.text.stroke",
"stylers": [{
"visibility": "on"
}, {
"color": "#f8f8f8"
}, {
"lightness": 25
}]
}, {
"elementType": "labels.text.fill",
"stylers": [{
"saturation": 36
}, {
"color": "#222222"
}, {
"lightness": 30
}]
}, {
"elementType": "labels.icon",
"stylers": [{
"visibility": "off"
}]
}, {
"featureType": "transit",
"elementType": "geometry",
"stylers": [{
"color": "#f5f5f5"
}, {
"lightness": 19
}]
}, {
"featureType": "administrative",
"elementType": "geometry.fill",
"stylers": [{
"color": "#fefefe"
}, {
"lightness": 10
}]
}, {
"featureType": "administrative",
"elementType": "geometry.stroke",
"stylers": [{
"color": "#fefefe"
}, {
"lightness": 17
}, {
"weight": 1.2
}]
}],
center: new google.maps.LatLng(40.712775, -74.005973) //please add your location here
};
var map = new google.maps.Map(document.getElementById('map'),
mapOptions);
var marker = new google.maps.Marker({
position: map.getCenter(),
//icon: 'images/locating.png', if u want custom
map: map
});
}
google.maps.event.addDomListener(window, 'load', initialize);
}
+12
View File
@@ -0,0 +1,12 @@
/*
* jquery-match-height 0.7.2 by @liabru
* http://brm.io/jquery-match-height/
* License MIT
*/
!function(t){"use strict";"function"==typeof define&&define.amd?define(["jquery"],t):"undefined"!=typeof module&&module.exports?module.exports=t(require("jquery")):t(jQuery)}(function(t){var e=-1,o=-1,n=function(t){return parseFloat(t)||0},a=function(e){var o=1,a=t(e),i=null,r=[];return a.each(function(){var e=t(this),a=e.offset().top-n(e.css("margin-top")),s=r.length>0?r[r.length-1]:null;null===s?r.push(e):Math.floor(Math.abs(i-a))<=o?r[r.length-1]=s.add(e):r.push(e),i=a}),r},i=function(e){var o={
byRow:!0,property:"height",target:null,remove:!1};return"object"==typeof e?t.extend(o,e):("boolean"==typeof e?o.byRow=e:"remove"===e&&(o.remove=!0),o)},r=t.fn.matchHeight=function(e){var o=i(e);if(o.remove){var n=this;return this.css(o.property,""),t.each(r._groups,function(t,e){e.elements=e.elements.not(n)}),this}return this.length<=1&&!o.target?this:(r._groups.push({elements:this,options:o}),r._apply(this,o),this)};r.version="0.7.2",r._groups=[],r._throttle=80,r._maintainScroll=!1,r._beforeUpdate=null,
r._afterUpdate=null,r._rows=a,r._parse=n,r._parseOptions=i,r._apply=function(e,o){var s=i(o),h=t(e),l=[h],c=t(window).scrollTop(),p=t("html").outerHeight(!0),u=h.parents().filter(":hidden");return u.each(function(){var e=t(this);e.data("style-cache",e.attr("style"))}),u.css("display","block"),s.byRow&&!s.target&&(h.each(function(){var e=t(this),o=e.css("display");"inline-block"!==o&&"flex"!==o&&"inline-flex"!==o&&(o="block"),e.data("style-cache",e.attr("style")),e.css({display:o,"padding-top":"0",
"padding-bottom":"0","margin-top":"0","margin-bottom":"0","border-top-width":"0","border-bottom-width":"0",height:"100px",overflow:"hidden"})}),l=a(h),h.each(function(){var e=t(this);e.attr("style",e.data("style-cache")||"")})),t.each(l,function(e,o){var a=t(o),i=0;if(s.target)i=s.target.outerHeight(!1);else{if(s.byRow&&a.length<=1)return void a.css(s.property,"");a.each(function(){var e=t(this),o=e.attr("style"),n=e.css("display");"inline-block"!==n&&"flex"!==n&&"inline-flex"!==n&&(n="block");var a={
display:n};a[s.property]="",e.css(a),e.outerHeight(!1)>i&&(i=e.outerHeight(!1)),o?e.attr("style",o):e.css("display","")})}a.each(function(){var e=t(this),o=0;s.target&&e.is(s.target)||("border-box"!==e.css("box-sizing")&&(o+=n(e.css("border-top-width"))+n(e.css("border-bottom-width")),o+=n(e.css("padding-top"))+n(e.css("padding-bottom"))),e.css(s.property,i-o+"px"))})}),u.each(function(){var e=t(this);e.attr("style",e.data("style-cache")||null)}),r._maintainScroll&&t(window).scrollTop(c/p*t("html").outerHeight(!0)),
this},r._applyDataApi=function(){var e={};t("[data-match-height], [data-mh]").each(function(){var o=t(this),n=o.attr("data-mh")||o.attr("data-match-height");n in e?e[n]=e[n].add(o):e[n]=o}),t.each(e,function(){this.matchHeight(!0)})};var s=function(e){r._beforeUpdate&&r._beforeUpdate(e,r._groups),t.each(r._groups,function(){r._apply(this.elements,this.options)}),r._afterUpdate&&r._afterUpdate(e,r._groups)};r._update=function(n,a){if(a&&"resize"===a.type){var i=t(window).width();if(i===e)return;e=i;
}n?o===-1&&(o=setTimeout(function(){s(a),o=-1},r._throttle)):s(a)},t(r._applyDataApi);var h=t.fn.on?"on":"bind";t(window)[h]("load",function(t){r._update(!1,t)}),t(window)[h]("resize orientationchange",function(t){r._update(!0,t)})});
+1
View File
@@ -0,0 +1 @@
/*! Morphext - v2.4.4 - 2015-05-21 */!function(a){"use strict";function b(b,c){this.element=a(b),this.settings=a.extend({},d,c),this._defaults=d,this._init()}var c="Morphext",d={animation:"bounceIn",separator:",",speed:2e3,complete:a.noop};b.prototype={_init:function(){var b=this;this.phrases=[],this.element.addClass("morphext"),a.each(this.element.text().split(this.settings.separator),function(c,d){b.phrases.push(a.trim(d))}),this.index=-1,this.animate(),this.start()},animate:function(){this.index=++this.index%this.phrases.length,this.element[0].innerHTML='<span class="animated '+this.settings.animation+'">'+this.phrases[this.index]+"</span>",a.isFunction(this.settings.complete)&&this.settings.complete.call(this)},start:function(){var a=this;this._interval=setInterval(function(){a.animate()},this.settings.speed)},stop:function(){this._interval=clearInterval(this._interval)}},a.fn[c]=function(d){return this.each(function(){a.data(this,"plugin_"+c)||a.data(this,"plugin_"+c,new b(this,d))})}}(jQuery);
+7
View File
File diff suppressed because one or more lines are too long
+1
View File
@@ -0,0 +1 @@
!function(e){e.fn.parallaxie=function(o){o=e.extend({speed:.2,repeat:"no-repeat",size:"cover",pos_x:"center",offset:0},o);return this.each(function(){var a=e(this),t=a.data("parallaxie");"object"!=typeof t&&(t={}),t=e.extend({},o,t);var s=a.data("image");if(void 0===s){if(!(s=a.css("background-image")))return;var n=t.offset+(a.offset().top-e(window).scrollTop())*(1-t.speed);a.css({"background-image":s,"background-size":t.size,"background-repeat":t.repeat,"background-attachment":"fixed","background-position":t.pos_x+" "+n+"px"}),e(window).scroll(function(){var o=t.offset+(a.offset().top-e(window).scrollTop())*(1-t.speed);a.data("pos_y",o),a.css("background-position",t.pos_x+" "+o+"px")})}}),this}}(jQuery);
+1
View File
@@ -0,0 +1 @@
!function(e){e.fn.parallaxie=function(o){o=e.extend({speed:.2,repeat:"no-repeat",size:"cover",pos_x:"center",offset:0},o);return this.each(function(){var a=e(this),t=a.data("parallaxie");"object"!=typeof t&&(t={}),t=e.extend({},o,t);var s=a.data("image");if(void 0===s){if(!(s=a.css("background-image")))return;var n=t.offset+(a.offset().top-e(window).scrollTop())*(1-t.speed);a.css({"background-image":s,"background-size":t.size,"background-repeat":t.repeat,"background-attachment":"fixed","background-position":t.pos_x+" "+n+"px"}),e(window).scroll(function(){var o=t.offset+(a.offset().top-e(window).scrollTop())*(1-t.speed);a.data("pos_y",o),a.css("background-position",t.pos_x+" "+o+"px")})}}),this}}(jQuery);
+77
View File
File diff suppressed because one or more lines are too long
+5
View File
File diff suppressed because one or more lines are too long
+778
View File
@@ -0,0 +1,778 @@
$ = jQuery.noConflict();
$(window).on("load", function () {
"use strict";
/* ===================================
Loading Timeout
====================================== */
setTimeout(function () {
$(".loader").fadeOut("slow");
}, 1000);
});
jQuery(function ($) {
"use strict";
/* ===================================
Scroll
====================================== */
$(window).on('scroll', function () {
if ($(this).scrollTop() > 220) { // Set position from top to add class
$('header').addClass('header-appear');
}
else {
$('header').removeClass('header-appear');
}
});
$(".progress-bar").each(function () {
$(this).appear(function () {
$(this).animate({width: $(this).attr("aria-valuenow") + "%"}, 3000)
});
});
$('.count').each(function () {
$(this).appear(function () {
$(this).prop('Counter', 0).animate({
Counter: $(this).text()
}, {
duration: 3000,
easing: 'swing',
step: function (now) {
$(this).text(Math.ceil(now));
}
});
});
});
//scroll to appear
$(window).on('scroll', function () {
if ($(this).scrollTop() > 500)
$('.scroll-top-arrow').fadeIn('slow');
else
$('.scroll-top-arrow').fadeOut('slow');
});
// fixing bottom nav to top on scrolliing
var $fixednav = $(".bottom-nav");
$(window).on("scroll", function () {
var $heightcalc = $(window).height() - $fixednav.height();
if ($(this).scrollTop() > $heightcalc) {
$fixednav.addClass("navbar-bottom-top");
} else {
$fixednav.removeClass("navbar-bottom-top");
}
});
//Click event to scroll to top
$(document).on('click', '.scroll-top-arrow', function () {
$('html, body').animate({scrollTop: 0}, 800);
return false;
});
//scroll sections
if($("body").hasClass("intrective")){
$(".scroll").on("click", function (event) {
event.preventDefault();
$("html,body").animate({
scrollTop: $(this.hash).offset().top}, 1200);
});
}else {
$(".scroll").on("click", function (event) {
event.preventDefault();
$("html,body").animate({
scrollTop: $(this.hash).offset().top - 60}, 1200);
});
}
/* =====================================
Parallax
====================================== */
if ($(window).width() > 992) {
$(".parallax").parallaxie({
speed: 0.55,
offset: 0,
});
}
/* ===================================
Side Menu
====================================== */
if ($("#sidemenu_toggle").length) {
$("#sidemenu_toggle").on("click", function () {
$(".pushwrap").toggleClass("active");
$(".side-menu").addClass("side-menu-active"), $("#close_side_menu").fadeIn(700)
}), $("#close_side_menu").on("click", function () {
$(".side-menu").removeClass("side-menu-active"), $(this).fadeOut(200), $(".pushwrap").removeClass("active")
}), $(".side-nav .navbar-nav .nav-link").on("click", function () {
$(".side-menu").removeClass("side-menu-active"), $("#close_side_menu").fadeOut(200), $(".pushwrap").removeClass("active")
}), $("#btn_sideNavClose").on("click", function () {
$(".side-menu").removeClass("side-menu-active"), $("#close_side_menu").fadeOut(200), $(".pushwrap").removeClass("active")
});
}
if ($(".side-right-btn").length) {
$(".side-right-btn").click(function () {
$(".navbar.navbar-right").toggleClass('show');
}),
$(".navbar.navbar-right .navbar-nav .nav-link").click(function () {
$(".navbar.navbar-right").toggleClass('show');
});
}
/* ===================================
Rotating Text
====================================== */
if ($("#js-rotating").length) {
$("#js-rotating").Morphext({
// The [in] animation type. Refer to Animate.css for a list of available animations.
animation: "flipInX",
// An array of phrases to rotate are created based on this separator. Change it if you wish to separate the phrases differently (e.g. So Simple | Very Doge | Much Wow | Such Cool).
separator: ",",
// The delay between the changing of each phrase in milliseconds.
speed: 3000,
complete: function () {
// Called after the entrance animation is executed.
}
});
}
/* ===================================
Type Text
====================================== */
if ($("#typewriting").length) {
var app = document.getElementById("typewriting");
var typewriter = new Typewriter(app, {
loop: true
});
typewriter.typeString('Way to achieve success').pauseFor(2000).deleteAll()
.typeString('Style to achieve success').pauseFor(2000).deleteAll()
.typeString('Method to achieve success').start();
}
if ($("#personal").length) {
var app = document.getElementById("personal");
var personal = new Typewriter(app, {
loop: true
});
personal.typeString('UI/UX Designer').pauseFor(2000).deleteAll()
.typeString('Web Developer').pauseFor(2000).deleteAll()
.typeString('Wordpress Developer').start();
}
/* =====================================
Coming Soon Count Down
====================================== */
if ($(".count_down").length) {
$('.count_down').downCount({
date: '03/3/2019 12:00:00',
offset: +10
});
}
/* =====================================
Wow
======================================== */
if ($(window).width() > 767) {
var wow = new WOW({
boxClass: 'wow',
animateClass: 'animated',
offset: 0,
mobile: false,
live: true
});
new WOW().init();
}
/* ===================================
Animated Cursor
====================================== */
function animatedCursor() {
if ($("#aimated-cursor").length) {
var e = {x: 0, y: 0}, t = {x: 0, y: 0}, n = .25, o = !1, a = document.getElementById("cursor"),
i = document.getElementById("cursor-loader");
TweenLite.set(a, {xPercent: -50, yPercent: -50}), document.addEventListener("mousemove", function (t) {
var n = window.pageYOffset || document.documentElement.scrollTop;
e.x = t.pageX, e.y = t.pageY - n
}), TweenLite.ticker.addEventListener("tick", function () {
o || (t.x += (e.x - t.x) * n, t.y += (e.y - t.y) * n, TweenLite.set(a, {x: t.x, y: t.y}))
}),
$(".animated-wrap").mouseenter(function (e) {
TweenMax.to(this, .3, {scale: 2}), TweenMax.to(a, .3, {
scale: 2,
borderWidth: "1px",
opacity: .2
}), TweenMax.to(i, .3, {
scale: 2,
borderWidth: "1px",
top: 1,
left: 1
}), TweenMax.to($(this).children(), .3, {scale: .5}), o = !0
}),
$(".animated-wrap").mouseleave(function (e) {
TweenMax.to(this, .3, {scale: 1}), TweenMax.to(a, .3, {
scale: 1,
borderWidth: "2px",
opacity: 1
}), TweenMax.to(i, .3, {
scale: 1,
borderWidth: "2px",
top: 0,
left: 0
}), TweenMax.to($(this).children(), .3, {scale: 1, x: 0, y: 0}), o = !1
}),
$(".animated-wrap").mousemove(function (e) {
var n, o, i, l, r, d, c, s, p, h, x, u, w, f, m;
n = e, o = 2, i = this.getBoundingClientRect(), l = n.pageX - i.left, r = n.pageY - i.top, d = window.pageYOffset || document.documentElement.scrollTop, t.x = i.left + i.width / 2 + (l - i.width / 2) / o, t.y = i.top + i.height / 2 + (r - i.height / 2 - d) / o, TweenMax.to(a, .3, {
x: t.x,
y: t.y
}), s = e, p = c = this, h = c.querySelector(".animated-element"), x = 20, u = p.getBoundingClientRect(), w = s.pageX - u.left, f = s.pageY - u.top, m = window.pageYOffset || document.documentElement.scrollTop, TweenMax.to(h, .3, {
x: (w - u.width / 2) / u.width * x,
y: (f - u.height / 2 - m) / u.height * x,
ease: Power2.easeOut
})
}),
$(".hide-cursor,.btn,.tp-bullets").mouseenter(function (e) {
TweenMax.to("#cursor", .2, {borderWidth: "1px", scale: 2, opacity: 0})
}), $(".hide-cursor,.btn,.tp-bullets").mouseleave(function (e) {
TweenMax.to("#cursor", .3, {borderWidth: "2px", scale: 1, opacity: 1})
}),$(".link").mouseenter(function (e) {
TweenMax.to("#cursor", .2, {
borderWidth: "0px",
scale: 3,
backgroundColor: "rgba(255, 255, 255, 0.27)",
opacity: .15
})
}), $(".link").mouseleave(function (e) {
TweenMax.to("#cursor", .3, {
borderWidth: "2px",
scale: 1,
backgroundColor: "rgba(255, 255, 255, 0)",
opacity: 1
})
})
}
}
if ($(window).width() > 991) {
setTimeout(function () {
animatedCursor();
}, 1000);
}
/* ===================================
Owl Carousel
====================================== */
//About Slider
$("#laptop-slide").owlCarousel({
items: 1,
loop: true,
dots: false,
nav: false,
animateOut: 'fadeOut',
animateIn: 'fadeIn',
autoplay: true,
autoplayTimeout: 3000,
// mouseDrag:false,
responsive: {
1280: {
items: 1,
},
600: {
items: 1,
},
320: {
items: 1,
},
}
});
//App Slider
$("#app-slider").owlCarousel({
items: 1,
loop: true,
dots: false,
nav: false,
animateOut: 'fadeOut',
animateIn: 'fadeIn',
autoplay: true,
autoplayTimeout: 3000,
// mouseDrag:false,
responsive: {
1280: {
items: 1,
},
600: {
items: 1,
},
320: {
items: 1,
},
}
});
// Team Slider
$("#team-slider").owlCarousel({
items: 3,
dots: false,
nav: false,
responsive: {
991: {
items: 3,
},
767: {
items: 2,
},
320: {
items: 1,
},
}
});
//price slider
$("#price-slider").owlCarousel({
items: 3,
dots: false,
nav: false,
responsive: {
991: {
items: 3,
},
767: {
items: 2,
},
320: {
items: 1,
},
}
});
$("#team-three-slider").owlCarousel({
items: 4,
dots: false,
nav: false,
responsive: {
991: {
items: 4,
},
767: {
items: 2,
},
320: {
items: 1,
},
}
});
//testimonial slider
$("#testimonial_slider").owlCarousel({
items: 1,
dots: true,
nav: false,
});
//single slider
$("#single-slider").owlCarousel({
items: 1,
nav: false,
loop: true,
mouseDrag: false,
animateOut: 'fadeOut',
animateIn: 'fadeIn',
autoplay: true,
autoplayTimeout: 3000,
});
//team two slider
$("#team-slider-two").owlCarousel({
items: 1,
nav: false,
loop: true,
dots: false,
responsive: {
991: {
items: 2,
autoplayHoverPause:true,
autoplay: true,
autoplayTimeout: 3000,
},
320: {
items: 1,
},
}
});
//Contact Us
$("#submit_btn").click(function () {
//disable submit button on click
$("#submit_btn").attr("disabled", "disabled");
$("#submit_btn span").text('Sending');
$("#submit_btn i").removeClass('d-none');
var user_name = $('input[name=first_name]').val() + ' ' + $('input[name=last_name]').val();
var user_email = $('input[name=email]').val();
var user_phone = $('input[name=phone]').val();
var user_message = $('textarea[name=message]').val();
//simple validation at client's end
var post_data, output;
var proceed = true;
if (user_name == "") {
proceed = false;
}
if (user_email == "") {
proceed = false;
}
// if (user_phone == "") {
//proceed = false;
// }
if (user_message == "") {
proceed = false;
}
//everything looks good! proceed...
if (proceed) {
//data to be sent to server
post_data = {
'userName': user_name,
'userEmail': user_email,
'userPhone': user_phone,
'userMessage': user_message
};
//Ajax post data to server
$.post('contact.php', post_data, function (response) {
//load json data from server and output message
if (response.type == 'error') {
output = '<div class="alert-danger" style="padding:10px; margin-bottom:30px;">' + response.text + '</div>';
} else {
output = '<div class="alert-success" style="padding:10px; margin-bottom:30px;">' + response.text + '</div>';
//reset values in all input fields
$('.contact-form input').val('');
$('.contact-form textarea').val('');
}
$("#result").hide().html(output).slideDown();
// enable submit button on action done
$("#submit_btn").removeAttr("disabled");
$("#submit_btn span").text('Contact Now');
$("#submit_btn i").addClass('d-none');
}, 'json');
}
else {
output = '<div class="alert-danger" style="padding:10px; margin-bottom:30px;">Please provide the missing fields.</div>';
$("#result").hide().html(output).slideDown();
// enable submit button on action done
$("#submit_btn").removeAttr("disabled");
$("#submit_btn span").text('Contact Now');
$("#submit_btn i").addClass('d-none');
}
});
/*============================================*
Cube Portfolio
* ============================================*/
$('#js-grid-mosaic-flat').cubeportfolio({
filters: '#js-filters-mosaic-flat',
layoutMode: 'mosaic',
sortByDimension: true,
mediaQueries: [{
width: 1500,
cols: 6,
}, {
width: 1100,
cols: 4,
}, {
width: 800,
cols: 3,
}, {
width: 480,
cols: 1,
options: {
gapHorizontal: 15,
gapVertical: 15,
}
}],
defaultFilter: '*',
animationType: 'fadeOutTop',
gapHorizontal: 0,
gapVertical: 0,
gridAdjustment: 'responsive',
caption: 'zoom',
// lightbox
lightboxDelegate: '.cbp-lightbox',
lightboxGallery: true,
lightboxTitleSrc: 'data-title',
plugins: {
loadMore: {
element: '#js-loadMore-mosaic-flat',
action: 'click',
loadItems: 3,
}
},
});
/* ------ CubePortfolio ------ */
$("#portfolio-measonry").cubeportfolio({
filters: '#measonry-filters',
loadMoreAction: 'click',
layoutMode: 'grid',
defaultFilter: '*',
animationType: "scaleSides",
gapHorizontal: 30,
gapVertical: 30,
gridAdjustment: "responsive",
mediaQueries: [{
width: 1500,
cols: 2
}, {
width: 1100,
cols: 2
}, {
width: 768,
cols: 2
}, {
width: 480,
cols: 1
}, {
width: 320,
cols: 1
}],
});
/* ===================================
Revolution Slider
====================================== */
$("#rev_slider_19_1").show().revolution({
sliderType: "standard",
jsFileLocation: "//localhost:82/revslider/revslider/public/assets/js/",
sliderLayout: "fullscreen",
dottedOverlay: "none",
delay: 9000,
navigation: {
keyboardNavigation: "off",
keyboard_direction: "horizontal",
mouseScrollNavigation: "off",
mouseScrollReverse: "default",
onHoverStop: "off",
bullets: {
enable: true,
hide_onmobile: true,
hide_under: 767,
style: "wexim",
hide_onleave: false,
direction: "vertical",
h_align: "left",
v_align: "center",
h_offset: 30,
v_offset: 0,
space: 5,
tmp: '<div class="tp-bullet-inner"></div><div class="tp-line"></div>'
},
touch: {
touchenabled: "on",
swipe_threshold: 75,
swipe_min_touches: 1,
swipe_direction: "horizontal",
drag_block_vertical: false
},
},
responsiveLevels: [1900, 1600, 1200, 1024, 778, 580],
visibilityLevels: [1900, 1600, 1024, 778, 580],
gridwidth: [1100, 1200, 1140, 960, 750, 480],
gridheight: [868, 768, 960, 720],
lazyType: "none",
scrolleffect: {
on_slidebg: "on",
},
parallax: {
type: "mouse",
origo: "slidercenter",
speed: 2000,
speedbg: 0,
speedls: 0,
levels: [2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15],
disable_onmobile: "on"
},
shadow: 0,
spinner: "off",
stopLoop: "off",
stopAfterLoops: -1,
stopAtSlide: -1,
shuffle: "off",
autoHeight: "off",
fullScreenAutoWidth: "off",
fullScreenAlignForce: "off",
fullScreenOffsetContainer: "",
fullScreenOffset: "",
disableProgressBar: "on",
hideThumbsOnMobile: "on",
hideSliderAtLimit: 0,
hideCaptionAtLimit: 0,
hideAllCaptionAtLilmit: 0,
debugMode: false,
fallbacks: {
simplifyAll: "off",
nextSlideOnWindowFocus: "off",
disableFocusListener: false,
}
});
/*animated elements hero banner*/
$("#rev_single").show().revolution({
sliderType: "hero",
jsFileLocation: "js/revolution",
sliderLayout: "fullscreen",
scrollbarDrag: "true",
dottedOverlay: "none",
delay: 9000,
navigation: {},
responsiveLevels: [1240, 1024, 778, 480],
visibilityLevels: [1240, 1024, 778, 480],
gridwidth: [1170, 1024, 778, 480],
gridheight: [868, 768, 960, 720],
lazyType: "none",
parallax: {
type: "scroll",
origo: "slidercenter",
speed: 400,
levels: [10, 15, 20, 25, 30, 35, 40, -10, -15, -20, -25, -30, -35, -40, -45, 55]
},
shadow: 0,
spinner: "off",
autoHeight: "off",
fullScreenAutoWidth: "off",
fullScreenAlignForce: "off",
fullScreenOffsetContainer: "",
disableProgressBar: "on",
hideThumbsOnMobile: "off",
hideSliderAtLimit: 0,
hideCaptionAtLimit: 0,
hideAllCaptionAtLilmit: 0,
debugMode: false,
fallbacks: {
simplifyAll: "off",
disableFocusListener: false
}
});
$("#rev_slider_1064_1").show().revolution({
sliderType:"standard",
jsFileLocation:"revolution/js/",
sliderLayout:"fullscreen",
dottedOverlay:"none",
delay:9000,
navigation: {
keyboardNavigation:"off",
keyboard_direction: "horizontal",
mouseScrollNavigation:"off",
mouseScrollReverse:"default",
onHoverStop:"off",
touch:{
touchenabled:"on",
swipe_threshold: 75,
swipe_min_touches: 1,
swipe_direction: "vertical",
drag_block_vertical: false
}
},
responsiveLevels:[1240,1024,778,480],
visibilityLevels:[1240,1024,778,480],
gridwidth:[1240,1024,778,480],
gridheight:[868,768,960,720],
lazyType:"none",
shadow:0,
spinner:"off",
stopLoop:"on",
stopAfterLoops:0,
stopAtSlide:1,
shuffle:"off",
autoHeight:"off",
fullScreenAutoWidth:"off",
fullScreenAlignForce:"off",
fullScreenOffsetContainer: ".header",
fullScreenOffset: "",
disableProgressBar:"on",
hideThumbsOnMobile:"off",
hideSliderAtLimit:0,
hideCaptionAtLimit:0,
hideAllCaptionAtLilmit:0,
debugMode:false,
fallbacks: {
simplifyAll:"off",
nextSlideOnWindowFocus:"off",
disableFocusListener:false,
}
});
});
+29
View File
@@ -0,0 +1,29 @@
/*
* Title: Typewriter JS
* Descritpion: A native javascript plugin that can be used to create an elegent automatic typewriter animation effect on websites.
* Author: Tameem Safi
* Website: https://safi.me.uk
* Version: 1.0.0
*/
(function(){(function(){for(var a=0,c=["ms","moz","webkit","o"],b=0;b<c.length&&!window.requestAnimationFrame;++b)window.requestAnimationFrame=window[c[b]+"RequestAnimationFrame"],window.cancelAnimationFrame=window[c[b]+"CancelAnimationFrame"]||window[c[b]+"CancelRequestAnimationFrame"];window.requestAnimationFrame||(window.requestAnimationFrame=function(c,b){var f=(new Date).getTime(),d=Math.max(0,16-(f-a)),e=window.setTimeout(function(){c(f+d)},d);a=f+d;return e});window.cancelAnimationFrame||(window.cancelAnimationFrame=
function(a){clearTimeout(a)})})();window.Typewriter=function(a,c){this._settings={cursorAnimationPaused:!1,opacityIncreasing:!1,currentOpacity:1,delayedQue:[],delayItemsCount:0,eventQue:[],calledEvents:[],eventRunning:!1,timeout:!1,delayExecution:!1,fps:.06,typingFrameCount:0,stringToTypeHTMLArray:[],currentTypedCharacters:[],typing:!1,usedIDs:[],charAmountToDelete:!1,userOptions:{},eventLoopRerun:0};if(!a)return console.error("Please choose an DOM element so that type writer can display itself.");
if("object"!==typeof c)return console.error("Typewriter only accepts the options as an object.");this._settings.userOptions=c;this.default_options={strings:!1,cursorClassName:"typewriter-cursor",cursor:"|",animateCursor:!0,blinkSpeed:50,typingSpeed:"natural",deleteSpeed:"natural",charSpanClassName:"typewriter-char",wrapperClassName:"typewriter-wrapper",loop:!1,autoStart:!1,devMode:!1};this.options=this._setupOptions(c);this.el=a;this._setupTypwriterWrapper();this._startCursorAnimation();!0===this.options.autoStart&&
this.options.strings&&this.typeOutAllStrings()};var b=window.Typewriter.prototype;b.stop=function(){this._addToEventQue(this._stopEventLoop);return this};b.start=function(){this._startEventLoop();return this};b.rerun=function(){this._addToEventQue(this._rerunCalledEvents);return this};b.typeString=function(a){if(!a||"string"!=typeof a)return console.error("Please enter a string as the paramater.");a=this._getCharacters(a);this._addToEventQue([this._typeCharacters,[a]]);return this};b.deleteAll=function(){this._addToEventQue([this._deleteChars,
["all"]]);return this};b.deleteChars=function(a){this._addToEventQue([this._deleteChars,[a]]);return this};b.pauseFor=function(a){this._addToEventQue([this._pauseFor,[a]]);return this};b.typeOutAllStrings=function(){var a=this._getStringsAsCharsArray();if(1===a.length)this._typeCharacters(a[0]);else for(var c=0,b=a.length;c<b;c++)this._addToEventQue([this._typeCharacters,[a[c]]]),this.pauseFor(this._randomInteger(1500,2500)),this.deleteAll(),this.pauseFor(this._randomInteger(1500,2500));return this};
b.changeSettings=function(a){if(!a&&"object"!==typeof a)return console.error("Typewriter will only accept an object as the settings.");this._addToEventQue([this._changeSettings,[JSON.stringify(a)]]);return this};b.changeBlinkSpeed=function(a){if(!a&&"number"!==typeof a)return console.error("Please enter a number for the new blink speed.");this.changeSettings({blinkSpeed:a});return this};b.changeTypingSpeed=function(a){if(!a&&"number"!==typeof a)return console.error("Please enter a number for the new typing speed.");
this.changeSettings({typingSpeed:a});return this};b.changeDeleteSpeed=function(a){if(!a&&"number"!==typeof a)return console.error("Please enter a number for the new delete speed.");this.changeSettings({changeDeleteSpeed:a});return this};b._rerunCalledEvents=function(){0<this._settings.currentTypedCharacters.length?(this.deleteAll(),this._resetEventLoop("rerunCalledEvents")):(this._settings.eventQue=this._settings.calledEvents,this._settings.calledEvents=[],this.options=this._setupOptions(this._settings.userOptions),
this._settings.usedIDs=[],this.charAmountToDelete=!1,this._startEventLoop())};b._deleteChars=function(a){a&&(this._settings.charAmountToDelete=a);this._deletingCharIdsAnimation=window.requestAnimationFrame(this._deletingCharAnimationFrame.bind(this));return this};b._pauseFor=function(a){var c=this;c._settings.eventRunning=!0;setTimeout(function(){c._resetEventLoop("pauseFor")},a)};b._changeSettings=function(a){this.options=this._setupOptions(JSON.parse(a[0]));this._resetEventLoop("changeSettings");
this.options.devMode&&console.log("New settings",this.options)};b._deletingCharAnimationFrame=function(){var a=this,c=this.options.deleteSpeed,b=a.options.wrapperClassName,d=a._settings.currentTypedCharacters,e=a._settings.charAmountToDelete;if(!a._settings.charAmountToDelete||0===a._settings.charAmountToDelete||0===d)return a._resetEventLoop("deletingCharAnimationFrame"),!0;"natural"==c&&(c=a._randomInteger(50,150));"all"==e&&(e=d.length,a._settings.charAmountToDelete=e);setTimeout(function(){if(a._settings.charAmountToDelete){var c=
d.length-1,f=d[c];a._settings.currentTypedCharacters.splice(c,1);if(c=document.getElementById(f))a.el.querySelector("."+b).removeChild(c),a._settings.charAmountToDelete=e-1,a.options.devMode&&console.log("Deleted char with ID",f)}a._deletingCharIdsAnimation=window.requestAnimationFrame(a._deletingCharAnimationFrame.bind(a))},c)};b._setupOptions=function(a){var c={},b;for(b in this.default_options)c[b]=this.default_options[b];if(this._settings.userOptions)for(b in this._settings.userOptions)c[b]=this._settings.userOptions[b];
for(b in a)c[b]=a[b];return c};b._addToEventQue=function(a){this._settings.eventQue.push(a);0<this._settings.eventQue.length&&!this._settings.eventRunning&&this.options.autoStart&&this._startEventLoop()};b._startEventLoop=function(){this.options.devMode&&console.log("Event loop started.");if(!this._settings.eventRunning){if(0<this._settings.eventQue.length){this.eventLoopRerun=0;var a=this._settings.eventQue[0];"function"==typeof a?(this._settings.eventRunning=!0,this._settings.calledEvents.push(a),
this._settings.eventQue.splice(0,1),a.call(this),this.options.devMode&&console.log("Event started.")):a instanceof Array&&"function"==typeof a[0]&&a[1]instanceof Array&&(this._settings.eventRunning=!0,this._settings.calledEvents.push(a),this._settings.eventQue.splice(0,1),a[0].call(this,a[1]),this.options.devMode&&console.log("Event started."))}this._eventQueAnimation=window.requestAnimationFrame(this._startEventLoop.bind(this))}if(!this._settings.eventRunning&&0>=this._settings.eventQue.length){var c=
this;c._stopEventLoop();setTimeout(function(){c.options.loop&&(c.eventLoopRerun++,c.options.devMode&&console.log("Before Loop State",c._settings),4<c.eventLoopRerun?(console.error("Maximum amount of loop retries reached."),c._stopEventLoop()):(c.options.devMode&&console.log("Looping events."),c._rerunCalledEvents()))},1E3)}};b._resetEventLoop=function(a){a=a||"Event";this._settings.eventRunning=!1;this._startEventLoop();this.options.devMode&&console.log(a,"Finished")};b._stopEventLoop=function(){window.cancelAnimationFrame(this._eventQueAnimation);
this.options.devMode&&console.log("Event loop stopped.")};b._setupTypwriterWrapper=function(){var a=this.options.wrapperClassName,c=document.createElement("span");c.className=a;this.el.innerHTML="";this.el.appendChild(c)};b._typeCharacters=function(a){this._settings.stringToTypeHTMLArray=this._convertCharsToHTML(a);this._typingAnimation=window.requestAnimationFrame(this._typingAnimationFrame.bind(this,a.length));return this};b._typingAnimationFrame=function(a){var c=this,b=this.options.typingSpeed,
d=c.options.wrapperClassName;if(0==c._settings.stringToTypeHTMLArray.length)return window.cancelAnimationFrame(c._typingAnimation),this._resetEventLoop("typingAnimationFrame"),!0;"natural"==b&&(b=this._randomInteger(50,150));setTimeout(function(){var b=c._settings.stringToTypeHTMLArray[0];c.el.querySelector("."+d).appendChild(b.el);c._settings.currentTypedCharacters.push(b.id);c._settings.stringToTypeHTMLArray.splice(0,1);c._typingAnimation=window.requestAnimationFrame(c._typingAnimationFrame.bind(c,
a));c.options.devMode&&console.log("Typed",b)},b)};b._convertCharsToHTML=function(a){var c=[],b=this.options.charSpanClassName;a=a[0];for(var d=0,e=a.length;d<e;d++){var g=document.createElement("span"),h=this._generateUniqueID();g.id=h;g.className=b+" typewriter-item-"+d;g.innerHTML=a[d];c.push({id:h,el:g})}return c};b._getCharacters=function(a){return"string"!==typeof a?!1:a.split("")};b._getStringsAsCharsArray=function(){var a="string"===typeof this.options.strings;if(!(this.options.strings instanceof
Array))return a?[this.options.strings.split("")]:console.error("Typewriter only accepts strings or an array of strings as the input.");for(var a=[],c=0,b=this.options.strings.length;c<b;c++){var d=this._getCharacters(this.options.strings[c]);if(!d){console.error("Please enter only strings.");break}a.push(d)}return a};b._cursorAnimationFrame=function(){if(!this._settings.cursorAnimationPaused){var a=.001*this.options.blinkSpeed,c=this.el.querySelector(".typewriter-cursor");1==this._settings.opacityIncreasing&&
(1<=this._settings.currentOpacity&&(this._settings.opacityIncreasing=!1,this._settings.currentOpacity=1),this._settings.currentOpacity+=a);0==this._settings.opacityIncreasing&&(0>=this._settings.currentOpacity&&(this._settings.opacityIncreasing=!0,this._settings.currentOpacity=0),this._settings.currentOpacity-=a);c.style.opacity=this._settings.currentOpacity;this._cursorAnimation=window.requestAnimationFrame(this._cursorAnimationFrame.bind(this))}};b._startCursorAnimation=function(){var a=this.options.cursor,
c=this.options.cursorClassName,b=document.createElement("span");b.className=c;b.innerHTML=a;this.el.appendChild(b);this.options.animateCursor&&(this._cursorAnimation=window.requestAnimationFrame(this._cursorAnimationFrame.bind(this)))};b._pauseCursorAnimation=function(){this._settings.cursorAnimationPaused||(window.cancelAnimationFrame(this._cursorAnimation),this._settings.cursorAnimationPaused=!0)};b._restartCursorAnimation=function(){if(!this._settings.cursorAnimationPaused)return console.error("Cursor animation is already running.");
this._settings.cursorAnimationPaused=!1;this._cursorAnimation=window.requestAnimationFrame(this._cursorAnimationFrame.bind(this))};b._randomInteger=function(a,b){return Math.floor(Math.random()*(b-a+1))+a};b._randomID=function(){for(var a="",b=0;b<this._randomInteger(5,15);b++)a+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789".charAt(Math.floor(62*Math.random()));return a};b._generateUniqueID=function(){var a=this._randomID();return-1==this._settings.usedIDs.indexOf(a)?(this._settings.usedIDs.push(a),
a):this._generateUniqueID.call(this)}})();
+2
View File
File diff suppressed because one or more lines are too long