')
- .append(i.clone())
- .remove()
- .html()
- .replace(/type="password"/i, 'type="text"')
- .replace(/type=password/i, 'type=text')
- );
-
- if (i.attr('id') != '')
- x.attr('id', i.attr('id') + '-polyfill-field');
-
- if (i.attr('name') != '')
- x.attr('name', i.attr('name') + '-polyfill-field');
-
- x.addClass('polyfill-placeholder')
- .val(x.attr('placeholder')).insertAfter(i);
-
- if (i.val() == '')
- i.hide();
- else
- x.hide();
-
- i
- .on('blur', function(event) {
-
- event.preventDefault();
-
- var x = i.parent().find('input[name=' + i.attr('name') + '-polyfill-field]');
-
- if (i.val() == '') {
-
- i.hide();
- x.show();
-
- }
-
- });
-
- x
- .on('focus', function(event) {
-
- event.preventDefault();
-
- var i = x.parent().find('input[name=' + x.attr('name').replace('-polyfill-field', '') + ']');
-
- x.hide();
-
- i
- .show()
- .focus();
-
- })
- .on('keypress', function(event) {
-
- event.preventDefault();
- x.val('');
-
- });
-
- });
-
- // Events.
- $this
- .on('submit', function() {
-
- $this.find('input[type=text],input[type=password],textarea')
- .each(function(event) {
-
- var i = $(this);
-
- if (i.attr('name').match(/-polyfill-field$/))
- i.attr('name', '');
-
- if (i.val() == i.attr('placeholder')) {
-
- i.removeClass('polyfill-placeholder');
- i.val('');
-
- }
-
- });
-
- })
- .on('reset', function(event) {
-
- event.preventDefault();
-
- $this.find('select')
- .val($('option:first').val());
-
- $this.find('input,textarea')
- .each(function() {
-
- var i = $(this),
- x;
-
- i.removeClass('polyfill-placeholder');
-
- switch (this.type) {
-
- case 'submit':
- case 'reset':
- break;
-
- case 'password':
- i.val(i.attr('defaultValue'));
-
- x = i.parent().find('input[name=' + i.attr('name') + '-polyfill-field]');
-
- if (i.val() == '') {
- i.hide();
- x.show();
- }
- else {
- i.show();
- x.hide();
- }
-
- break;
-
- case 'checkbox':
- case 'radio':
- i.attr('checked', i.attr('defaultValue'));
- break;
-
- case 'text':
- case 'textarea':
- i.val(i.attr('defaultValue'));
-
- if (i.val() == '') {
- i.addClass('polyfill-placeholder');
- i.val(i.attr('placeholder'));
- }
-
- break;
-
- default:
- i.val(i.attr('defaultValue'));
- break;
-
- }
- });
-
- });
-
- return $this;
-
- };
-
- /**
- * Moves elements to/from the first positions of their respective parents.
- * @param {jQuery} $elements Elements (or selector) to move.
- * @param {bool} condition If true, moves elements to the top. Otherwise, moves elements back to their original locations.
- */
- $.prioritize = function($elements, condition) {
-
- var key = '__prioritize';
-
- // Expand $elements if it's not already a jQuery object.
- if (typeof $elements != 'jQuery')
- $elements = $($elements);
-
- // Step through elements.
- $elements.each(function() {
-
- var $e = $(this), $p,
- $parent = $e.parent();
-
- // No parent? Bail.
- if ($parent.length == 0)
- return;
-
- // Not moved? Move it.
- if (!$e.data(key)) {
-
- // Condition is false? Bail.
- if (!condition)
- return;
-
- // Get placeholder (which will serve as our point of reference for when this element needs to move back).
- $p = $e.prev();
-
- // Couldn't find anything? Means this element's already at the top, so bail.
- if ($p.length == 0)
- return;
-
- // Move element to top of parent.
- $e.prependTo($parent);
-
- // Mark element as moved.
- $e.data(key, $p);
-
- }
-
- // Moved already?
- else {
-
- // Condition is true? Bail.
- if (condition)
- return;
-
- $p = $e.data(key);
-
- // Move element back to its original location (using our placeholder).
- $e.insertAfter($p);
-
- // Unmark element as moved.
- $e.removeData(key);
-
- }
-
- });
-
- };
-
+(function($) {
+
+ /**
+ * Generate an indented list of links from a nav. Meant for use with panel().
+ * @return {jQuery} jQuery object.
+ */
+ $.fn.navList = function() {
+
+ var $this = $(this);
+ $a = $this.find('a'),
+ b = [];
+
+ $a.each(function() {
+
+ var $this = $(this),
+ indent = Math.max(0, $this.parents('li').length - 1),
+ href = $this.attr('href'),
+ target = $this.attr('target');
+
+ b.push(
+ '
' +
+ ' ' +
+ $this.text() +
+ ' '
+ );
+
+ });
+
+ return b.join('');
+
+ };
+
+ /**
+ * Panel-ify an element.
+ * @param {object} userConfig User config.
+ * @return {jQuery} jQuery object.
+ */
+ $.fn.panel = function(userConfig) {
+
+ // No elements?
+ if (this.length == 0)
+ return $this;
+
+ // Multiple elements?
+ if (this.length > 1) {
+
+ for (var i=0; i < this.length; i++)
+ $(this[i]).panel(userConfig);
+
+ return $this;
+
+ }
+
+ // Vars.
+ var $this = $(this),
+ $body = $('body'),
+ $window = $(window),
+ id = $this.attr('id'),
+ config;
+
+ // Config.
+ config = $.extend({
+
+ // Delay.
+ delay: 0,
+
+ // Hide panel on link click.
+ hideOnClick: false,
+
+ // Hide panel on escape keypress.
+ hideOnEscape: false,
+
+ // Hide panel on swipe.
+ hideOnSwipe: false,
+
+ // Reset scroll position on hide.
+ resetScroll: false,
+
+ // Reset forms on hide.
+ resetForms: false,
+
+ // Side of viewport the panel will appear.
+ side: null,
+
+ // Target element for "class".
+ target: $this,
+
+ // Class to toggle.
+ visibleClass: 'visible'
+
+ }, userConfig);
+
+ // Expand "target" if it's not a jQuery object already.
+ if (typeof config.target != 'jQuery')
+ config.target = $(config.target);
+
+ // Panel.
+
+ // Methods.
+ $this._hide = function(event) {
+
+ // Already hidden? Bail.
+ if (!config.target.hasClass(config.visibleClass))
+ return;
+
+ // If an event was provided, cancel it.
+ if (event) {
+
+ event.preventDefault();
+ event.stopPropagation();
+
+ }
+
+ // Hide.
+ config.target.removeClass(config.visibleClass);
+
+ // Post-hide stuff.
+ window.setTimeout(function() {
+
+ // Reset scroll position.
+ if (config.resetScroll)
+ $this.scrollTop(0);
+
+ // Reset forms.
+ if (config.resetForms)
+ $this.find('form').each(function() {
+ this.reset();
+ });
+
+ }, config.delay);
+
+ };
+
+ // Vendor fixes.
+ $this
+ .css('-ms-overflow-style', '-ms-autohiding-scrollbar')
+ .css('-webkit-overflow-scrolling', 'touch');
+
+ // Hide on click.
+ if (config.hideOnClick) {
+
+ $this.find('a')
+ .css('-webkit-tap-highlight-color', 'rgba(0,0,0,0)');
+
+ $this
+ .on('click', 'a', function(event) {
+
+ var $a = $(this),
+ href = $a.attr('href'),
+ target = $a.attr('target');
+
+ if (!href || href == '#' || href == '' || href == '#' + id)
+ return;
+
+ // Cancel original event.
+ event.preventDefault();
+ event.stopPropagation();
+
+ // Hide panel.
+ $this._hide();
+
+ // Redirect to href.
+ window.setTimeout(function() {
+
+ if (target == '_blank')
+ window.open(href);
+ else
+ window.location.href = href;
+
+ }, config.delay + 10);
+
+ });
+
+ }
+
+ // Event: Touch stuff.
+ $this.on('touchstart', function(event) {
+
+ $this.touchPosX = event.originalEvent.touches[0].pageX;
+ $this.touchPosY = event.originalEvent.touches[0].pageY;
+
+ })
+
+ $this.on('touchmove', function(event) {
+
+ if ($this.touchPosX === null
+ || $this.touchPosY === null)
+ return;
+
+ var diffX = $this.touchPosX - event.originalEvent.touches[0].pageX,
+ diffY = $this.touchPosY - event.originalEvent.touches[0].pageY,
+ th = $this.outerHeight(),
+ ts = ($this.get(0).scrollHeight - $this.scrollTop());
+
+ // Hide on swipe?
+ if (config.hideOnSwipe) {
+
+ var result = false,
+ boundary = 20,
+ delta = 50;
+
+ switch (config.side) {
+
+ case 'left':
+ result = (diffY < boundary && diffY > (-1 * boundary)) && (diffX > delta);
+ break;
+
+ case 'right':
+ result = (diffY < boundary && diffY > (-1 * boundary)) && (diffX < (-1 * delta));
+ break;
+
+ case 'top':
+ result = (diffX < boundary && diffX > (-1 * boundary)) && (diffY > delta);
+ break;
+
+ case 'bottom':
+ result = (diffX < boundary && diffX > (-1 * boundary)) && (diffY < (-1 * delta));
+ break;
+
+ default:
+ break;
+
+ }
+
+ if (result) {
+
+ $this.touchPosX = null;
+ $this.touchPosY = null;
+ $this._hide();
+
+ return false;
+
+ }
+
+ }
+
+ // Prevent vertical scrolling past the top or bottom.
+ if (($this.scrollTop() < 0 && diffY < 0)
+ || (ts > (th - 2) && ts < (th + 2) && diffY > 0)) {
+
+ event.preventDefault();
+ event.stopPropagation();
+
+ }
+
+ });
+
+ // Event: Prevent certain events inside the panel from bubbling.
+ $this.on('click touchend touchstart touchmove', function(event) {
+ event.stopPropagation();
+ });
+
+ // Event: Hide panel if a child anchor tag pointing to its ID is clicked.
+ $this.on('click', 'a[href="#' + id + '"]', function(event) {
+
+ event.preventDefault();
+ event.stopPropagation();
+
+ config.target.removeClass(config.visibleClass);
+
+ });
+
+ // Body.
+
+ // Event: Hide panel on body click/tap.
+ $body.on('click touchend', function(event) {
+ $this._hide(event);
+ });
+
+ // Event: Toggle.
+ $body.on('click', 'a[href="#' + id + '"]', function(event) {
+
+ event.preventDefault();
+ event.stopPropagation();
+
+ config.target.toggleClass(config.visibleClass);
+
+ });
+
+ // Window.
+
+ // Event: Hide on ESC.
+ if (config.hideOnEscape)
+ $window.on('keydown', function(event) {
+
+ if (event.keyCode == 27)
+ $this._hide(event);
+
+ });
+
+ return $this;
+
+ };
+
+ /**
+ * Apply "placeholder" attribute polyfill to one or more forms.
+ * @return {jQuery} jQuery object.
+ */
+ $.fn.placeholder = function() {
+
+ // Browser natively supports placeholders? Bail.
+ if (typeof (document.createElement('input')).placeholder != 'undefined')
+ return $(this);
+
+ // No elements?
+ if (this.length == 0)
+ return $this;
+
+ // Multiple elements?
+ if (this.length > 1) {
+
+ for (var i=0; i < this.length; i++)
+ $(this[i]).placeholder();
+
+ return $this;
+
+ }
+
+ // Vars.
+ var $this = $(this);
+
+ // Text, TextArea.
+ $this.find('input[type=text],textarea')
+ .each(function() {
+
+ var i = $(this);
+
+ if (i.val() == ''
+ || i.val() == i.attr('placeholder'))
+ i
+ .addClass('polyfill-placeholder')
+ .val(i.attr('placeholder'));
+
+ })
+ .on('blur', function() {
+
+ var i = $(this);
+
+ if (i.attr('name').match(/-polyfill-field$/))
+ return;
+
+ if (i.val() == '')
+ i
+ .addClass('polyfill-placeholder')
+ .val(i.attr('placeholder'));
+
+ })
+ .on('focus', function() {
+
+ var i = $(this);
+
+ if (i.attr('name').match(/-polyfill-field$/))
+ return;
+
+ if (i.val() == i.attr('placeholder'))
+ i
+ .removeClass('polyfill-placeholder')
+ .val('');
+
+ });
+
+ // Password.
+ $this.find('input[type=password]')
+ .each(function() {
+
+ var i = $(this);
+ var x = $(
+ $('
')
+ .append(i.clone())
+ .remove()
+ .html()
+ .replace(/type="password"/i, 'type="text"')
+ .replace(/type=password/i, 'type=text')
+ );
+
+ if (i.attr('id') != '')
+ x.attr('id', i.attr('id') + '-polyfill-field');
+
+ if (i.attr('name') != '')
+ x.attr('name', i.attr('name') + '-polyfill-field');
+
+ x.addClass('polyfill-placeholder')
+ .val(x.attr('placeholder')).insertAfter(i);
+
+ if (i.val() == '')
+ i.hide();
+ else
+ x.hide();
+
+ i
+ .on('blur', function(event) {
+
+ event.preventDefault();
+
+ var x = i.parent().find('input[name=' + i.attr('name') + '-polyfill-field]');
+
+ if (i.val() == '') {
+
+ i.hide();
+ x.show();
+
+ }
+
+ });
+
+ x
+ .on('focus', function(event) {
+
+ event.preventDefault();
+
+ var i = x.parent().find('input[name=' + x.attr('name').replace('-polyfill-field', '') + ']');
+
+ x.hide();
+
+ i
+ .show()
+ .focus();
+
+ })
+ .on('keypress', function(event) {
+
+ event.preventDefault();
+ x.val('');
+
+ });
+
+ });
+
+ // Events.
+ $this
+ .on('submit', function() {
+
+ $this.find('input[type=text],input[type=password],textarea')
+ .each(function(event) {
+
+ var i = $(this);
+
+ if (i.attr('name').match(/-polyfill-field$/))
+ i.attr('name', '');
+
+ if (i.val() == i.attr('placeholder')) {
+
+ i.removeClass('polyfill-placeholder');
+ i.val('');
+
+ }
+
+ });
+
+ })
+ .on('reset', function(event) {
+
+ event.preventDefault();
+
+ $this.find('select')
+ .val($('option:first').val());
+
+ $this.find('input,textarea')
+ .each(function() {
+
+ var i = $(this),
+ x;
+
+ i.removeClass('polyfill-placeholder');
+
+ switch (this.type) {
+
+ case 'submit':
+ case 'reset':
+ break;
+
+ case 'password':
+ i.val(i.attr('defaultValue'));
+
+ x = i.parent().find('input[name=' + i.attr('name') + '-polyfill-field]');
+
+ if (i.val() == '') {
+ i.hide();
+ x.show();
+ }
+ else {
+ i.show();
+ x.hide();
+ }
+
+ break;
+
+ case 'checkbox':
+ case 'radio':
+ i.attr('checked', i.attr('defaultValue'));
+ break;
+
+ case 'text':
+ case 'textarea':
+ i.val(i.attr('defaultValue'));
+
+ if (i.val() == '') {
+ i.addClass('polyfill-placeholder');
+ i.val(i.attr('placeholder'));
+ }
+
+ break;
+
+ default:
+ i.val(i.attr('defaultValue'));
+ break;
+
+ }
+ });
+
+ });
+
+ return $this;
+
+ };
+
+ /**
+ * Moves elements to/from the first positions of their respective parents.
+ * @param {jQuery} $elements Elements (or selector) to move.
+ * @param {bool} condition If true, moves elements to the top. Otherwise, moves elements back to their original locations.
+ */
+ $.prioritize = function($elements, condition) {
+
+ var key = '__prioritize';
+
+ // Expand $elements if it's not already a jQuery object.
+ if (typeof $elements != 'jQuery')
+ $elements = $($elements);
+
+ // Step through elements.
+ $elements.each(function() {
+
+ var $e = $(this), $p,
+ $parent = $e.parent();
+
+ // No parent? Bail.
+ if ($parent.length == 0)
+ return;
+
+ // Not moved? Move it.
+ if (!$e.data(key)) {
+
+ // Condition is false? Bail.
+ if (!condition)
+ return;
+
+ // Get placeholder (which will serve as our point of reference for when this element needs to move back).
+ $p = $e.prev();
+
+ // Couldn't find anything? Means this element's already at the top, so bail.
+ if ($p.length == 0)
+ return;
+
+ // Move element to top of parent.
+ $e.prependTo($parent);
+
+ // Mark element as moved.
+ $e.data(key, $p);
+
+ }
+
+ // Moved already?
+ else {
+
+ // Condition is true? Bail.
+ if (condition)
+ return;
+
+ $p = $e.data(key);
+
+ // Move element back to its original location (using our placeholder).
+ $e.insertAfter($p);
+
+ // Unmark element as moved.
+ $e.removeData(key);
+
+ }
+
+ });
+
+ };
+
})(jQuery);
\ No newline at end of file
diff --git a/assets/js/breakpoints.min.js b/assets/js/breakpoints.min.js
index e20ae89..32419cc 100644
--- a/assets/js/breakpoints.min.js
+++ b/assets/js/breakpoints.min.js
@@ -1,2 +1,2 @@
-/* breakpoints.js v1.0 | @ajlkn | MIT licensed */
+/* breakpoints.js v1.0 | @ajlkn | MIT licensed */
var breakpoints=function(){"use strict";function e(e){t.init(e)}var t={list:null,media:{},events:[],init:function(e){t.list=e,window.addEventListener("resize",t.poll),window.addEventListener("orientationchange",t.poll),window.addEventListener("load",t.poll),window.addEventListener("fullscreenchange",t.poll)},active:function(e){var n,a,s,i,r,d,c;if(!(e in t.media)){if(">="==e.substr(0,2)?(a="gte",n=e.substr(2)):"<="==e.substr(0,2)?(a="lte",n=e.substr(2)):">"==e.substr(0,1)?(a="gt",n=e.substr(1)):"<"==e.substr(0,1)?(a="lt",n=e.substr(1)):"!"==e.substr(0,1)?(a="not",n=e.substr(1)):(a="eq",n=e),n&&n in t.list)if(i=t.list[n],Array.isArray(i)){if(r=parseInt(i[0]),d=parseInt(i[1]),isNaN(r)){if(isNaN(d))return;c=i[1].substr(String(d).length)}else c=i[0].substr(String(r).length);if(isNaN(r))switch(a){case"gte":s="screen";break;case"lte":s="screen and (max-width: "+d+c+")";break;case"gt":s="screen and (min-width: "+(d+1)+c+")";break;case"lt":s="screen and (max-width: -1px)";break;case"not":s="screen and (min-width: "+(d+1)+c+")";break;default:s="screen and (max-width: "+d+c+")"}else if(isNaN(d))switch(a){case"gte":s="screen and (min-width: "+r+c+")";break;case"lte":s="screen";break;case"gt":s="screen and (max-width: -1px)";break;case"lt":s="screen and (max-width: "+(r-1)+c+")";break;case"not":s="screen and (max-width: "+(r-1)+c+")";break;default:s="screen and (min-width: "+r+c+")"}else switch(a){case"gte":s="screen and (min-width: "+r+c+")";break;case"lte":s="screen and (max-width: "+d+c+")";break;case"gt":s="screen and (min-width: "+(d+1)+c+")";break;case"lt":s="screen and (max-width: "+(r-1)+c+")";break;case"not":s="screen and (max-width: "+(r-1)+c+"), screen and (min-width: "+(d+1)+c+")";break;default:s="screen and (min-width: "+r+c+") and (max-width: "+d+c+")"}}else s="("==i.charAt(0)?"screen and "+i:i;t.media[e]=!!s&&s}return t.media[e]!==!1&&window.matchMedia(t.media[e]).matches},on:function(e,n){t.events.push({query:e,handler:n,state:!1}),t.active(e)&&n()},poll:function(){var e,n;for(e=0;e
0:!!("ontouchstart"in window),e.mobile="wp"==e.os||"android"==e.os||"ios"==e.os||"bb"==e.os}};return e.init(),e}();!function(e,n){"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?module.exports=n():e.browser=n()}(this,function(){return browser});
diff --git a/assets/js/demo.js b/assets/js/demo.js
index efa932a..01ede5a 100644
--- a/assets/js/demo.js
+++ b/assets/js/demo.js
@@ -1,563 +1,563 @@
-/*
- Story by HTML5 UP
- html5up.net | @ajlkn
- Free for personal and commercial use under the CCA 3.0 license (html5up.net/license)
-
- Note: Only needed for demo purposes. Delete for production sites.
-*/
-
-(function($) {
-
- var $window = $(window);
-
- // Styles.
- $(
- ''
- ).appendTo($('head'));
-
- // Functions.
- $.fn.demo_controls = function(styles, userOptions) {
-
- var $this = $(this),
- $styleProperty, $stylePropertyClasses,
- $controls, $x, $y, $z,
- options,
- current, i, j, k, s, n, count;
-
- // No elements?
- if (this.length == 0)
- return $this;
-
- // Multiple elements?
- if (this.length > 1) {
-
- for (var i=0; i < this.length; i++)
- $(this[i]).demo_controls(styles, userOptions);
-
- return $this;
-
- }
-
- // Options.
- options = $.extend({
- target: null,
- palette: true
- }, userOptions);
-
- // Controls.
- if (styles) {
-
- $controls = $(
- '' +
- '' +
- 'style ' +
- ' ' + (options.palette ? ', ' : ' ') +
- ' ' +
- (options.palette ?
- '' +
- 'scheme ' +
- '' +
- 'default ' +
- 'invert ' +
- ' , ' +
- ' ' +
- '' +
- 'color ' +
- '' +
- 'default ' +
- 'color1 ' +
- 'color2 ' +
- 'color3 ' +
- 'color4 ' +
- 'color5 ' +
- 'color6 ' +
- 'color7 ' +
- ' , ' +
- ' '
- : '') +
- ' '
- );
-
- }
- else {
-
- $controls = $(
- '' +
- (options.palette ?
- '' +
- 'scheme ' +
- '' +
- 'default ' +
- 'invert ' +
- ' and ' +
- ' ' +
- '' +
- 'color ' +
- '' +
- 'default ' +
- 'color1 ' +
- 'color2 ' +
- 'color3 ' +
- 'color4 ' +
- 'color5 ' +
- 'color6 ' +
- 'color7 ' +
- ' ' +
- ' '
- : '') +
- ' '
- );
-
- }
-
- // Target.
- switch (options.target) {
-
- case 'previous':
- $this.prev().find('.demo-controls').replaceWith($controls);
- break;
-
- default:
- $this.find('.demo-controls').replaceWith($controls);
- break;
-
- }
-
- // Styles.
- if (styles) {
-
- $styleProperty = $controls.find('.property[data-name="style"]');
- $stylePropertyClasses = $styleProperty.children('.classes');
-
- for (i in styles) {
-
- current = false;
- count = Object.keys(styles[i]).length;
- n = 1;
-
- // Add to style property.
- $x = $(', ' + i + ' ')
- .appendTo($stylePropertyClasses);
-
- if ($this.hasClass(i)) {
-
- $x.addClass('active');
- current = true;
-
- }
-
- // Step through properties.
- for (j in styles[i]) {
-
- $x = $(
- '' +
- (n == count ? 'and ' : '') +
- '' + j + ' ' +
- '' +
- ' ' + (n < count ? ', ' : '') +
- ' '
- ).appendTo($controls);
-
- $y = $x.children('.classes');
-
- if (current)
- $x.addClass('active');
-
- for (k in styles[i][j]) {
-
- $z = $(', ' + styles[i][j][k].replace('*', '') + ' ')
- .appendTo($y);
-
- if (styles[i][j][k].substr(-1, 1) == '*')
- $z.addClass('default');
-
- if (current
- && $this.hasClass(k))
- $z.addClass('active');
-
- }
-
- n++;
-
- }
-
- }
-
- }
-
- // Events.
- $controls.on('click', 'a', function(event) {
- event.preventDefault();
- });
-
- $controls.on('click', '.property.active', function(event) {
-
- var $property = $(this);
- var $classes = $property.find('.classes > *');
- var $current = $classes.filter('.active');
- var $next;
-
- // Determine next.
- if ($current.length == 0
- || $current.index() == $classes.length - 1)
- $next = $classes.first();
- else
- $next = $current.next();
-
- // Turn on animate all.
- $this.addClass('demo-animate-all');
-
- // Deactivate current.
- $current.removeClass('active');
- $this.removeClass($current.data('class'));
-
- // Activate next.
- $next.addClass('active');
- $this.addClass($next.data('class'));
-
- // Turn off animate all.
- setTimeout(function() {
- $this.removeClass('demo-animate-all');
- }, 500);
-
- });
-
- $controls.on('click', '.property[data-name="style"]', function(event) {
-
- var $property = $(this);
- var $classes = $property.find('.classes > *');
- var $current = $classes.filter('.active');
- var $next;
-
- // Determine next.
- if ($current.length == 0
- || $current.index() == $classes.length - 1)
- $next = $classes.first();
- else
- $next = $current.next();
-
- // Turn on animate all.
- $this.addClass('demo-animate-all');
-
- // Deactivate current.
- $current.removeClass('active');
- $this.removeClass($current.data('class'));
-
- $controls.find('.property[data-requires="' + $current.data('class') + '"]')
- .removeClass('active');
-
- $controls.find('.property[data-requires="' + $current.data('class') + '"] > .classes > .active').each(function() {
-
- $(this).removeClass('active');
-
- if ($(this).data('class') != '-')
- $this.removeClass($(this).data('class'));
-
- });
-
- // Activate next.
- $next.addClass('active');
- $this.addClass($next.data('class'));
-
- $controls.find('.property[data-requires="' + $next.data('class') + '"]')
- .addClass('active');
-
- $controls.find('.property[data-requires="' + $next.data('class') + '"] > .classes > .default').each(function() {
-
- $(this).addClass('active');
-
- if ($(this).data('class') != '-')
- $this.addClass($(this).data('class'));
-
- });
-
- // Turn off animate all.
- setTimeout(function() {
- $this.removeClass('demo-animate-all');
- }, 500);
-
- });
-
- };
-
- // Elements.
-
- // Wrappers.
- $('.wrapper').demo_controls(null, {
- palette: true
- });
-
- // Banner.
- $('.banner').demo_controls({
- style1: {
- 'size': {
- '-': 'normal',
- 'fullscreen': 'fullscreen*'
- },
- 'orientation': {
- 'orient-left': 'left*',
- 'orient-right': 'right'
- },
- 'content alignment': {
- 'content-align-left': 'left*',
- 'content-align-center': 'center',
- 'content-align-right': 'right'
- },
- 'image position': {
- 'image-position-left': 'left',
- 'image-position-center': 'center*',
- 'image-position-right': 'right'
- }
- },
- style2: {
- 'size': {
- '-': 'normal',
- 'fullscreen': 'fullscreen*'
- },
- 'orientation': {
- 'orient-left': 'left',
- 'orient-center': 'center*',
- 'orient-right': 'right'
- },
- 'content alignment': {
- 'content-align-left': 'left',
- 'content-align-center': 'center*',
- 'content-align-right': 'right'
- },
- 'image position': {
- 'image-position-left': 'left',
- 'image-position-center': 'center*',
- 'image-position-right': 'right'
- }
- },
- style3: {
- 'size': {
- '-': 'normal',
- 'fullscreen': 'fullscreen*'
- },
- 'orientation': {
- 'orient-left': 'left',
- 'orient-right': 'right*'
- },
- 'content alignment': {
- 'content-align-left': 'left*',
- 'content-align-center': 'center',
- 'content-align-right': 'right'
- },
- 'image position': {
- 'image-position-left': 'left',
- 'image-position-center': 'center*',
- 'image-position-right': 'right'
- }
- },
- style4: {
- 'size': {
- '-': 'normal',
- 'fullscreen': 'fullscreen*'
- },
- 'phone type': {
- 'iphone': 'iphone*',
- 'android': 'android'
- },
- 'orientation': {
- 'orient-left': 'left',
- 'orient-right': 'right*'
- },
- 'content alignment': {
- 'content-align-left': 'left*',
- 'content-align-center': 'center',
- 'content-align-right': 'right'
- },
- 'image position': {
- 'image-position-left': 'left',
- 'image-position-center': 'center*',
- 'image-position-right': 'right'
- }
- },
- style5: {
- 'size': {
- '-': 'normal',
- 'fullscreen': 'fullscreen*'
- },
- 'content alignment': {
- 'content-align-left': 'left',
- 'content-align-center': 'center*',
- 'content-align-right': 'right'
- },
- 'image position': {
- 'image-position-left': 'left',
- 'image-position-center': 'center*',
- 'image-position-right': 'right'
- }
- }
- });
-
- // Spotlight.
- $('.spotlight').demo_controls({
- style1: {
- 'orientation': {
- 'orient-left': 'left',
- 'orient-right': 'right*'
- },
- 'content alignment': {
- 'content-align-left': 'left*',
- 'content-align-center': 'center',
- 'content-align-right': 'right'
- },
- 'image position': {
- 'image-position-left': 'left*',
- 'image-position-center': 'center',
- 'image-position-right': 'right'
- }
- },
- style2: {
- 'orientation': {
- 'orient-left': 'left',
- 'orient-right': 'right*'
- },
- 'content alignment': {
- 'content-align-left': 'left*',
- 'content-align-center': 'center',
- 'content-align-right': 'right'
- },
- 'image position': {
- 'image-position-left': 'left',
- 'image-position-center': 'center*',
- 'image-position-right': 'right'
- }
- },
- style3: {
- 'phone type': {
- 'iphone': 'iphone*',
- 'android': 'android'
- },
- 'orientation': {
- 'orient-left': 'left',
- 'orient-right': 'right*'
- },
- 'content alignment': {
- 'content-align-left': 'left*',
- 'content-align-center': 'center',
- 'content-align-right': 'right'
- },
- 'image position': {
- 'image-position-left': 'left',
- 'image-position-center': 'center*',
- 'image-position-right': 'right'
- }
- },
- style4: {
- 'size': {
- '-size': 'normal',
- 'fullscreen': 'fullscreen*',
- 'halfscreen': 'halfscreen'
- },
- 'orientation': {
- 'orient-left': 'left*',
- 'orient-center': 'center',
- 'orient-right': 'right'
- },
- 'content alignment': {
- 'content-align-left': 'left*',
- 'content-align-center': 'center',
- 'content-align-right': 'right'
- },
- 'image position': {
- 'image-position-left': 'left',
- 'image-position-center': 'center*',
- 'image-position-right': 'right'
- }
- },
- style5: {
- 'size': {
- '-size': 'normal',
- 'fullscreen': 'fullscreen*',
- 'halfscreen': 'halfscreen'
- },
- 'orientation': {
- 'orient-left': 'left*',
- 'orient-center': 'center',
- 'orient-right': 'right'
- },
- 'content alignment': {
- 'content-align-left': 'left*',
- 'content-align-center': 'center',
- 'content-align-right': 'right'
- },
- 'image position': {
- 'image-position-left': 'left',
- 'image-position-center': 'center*',
- 'image-position-right': 'right'
- }
- },
- });
-
- // Gallery.
- $('.gallery').demo_controls({
- style1: {
- 'size': {
- 'small': 'small',
- 'medium': 'medium*',
- 'big': 'big'
- }
- },
- style2: {
- 'size': {
- 'small': 'small',
- 'medium': 'medium*',
- 'big': 'big'
- }
- },
- }, {
- target: 'previous',
- palette: false
- });
-
- // Items.
- $('.items').demo_controls({
- style1: {
- 'size': {
- 'small': 'small',
- 'medium': 'medium*',
- 'big': 'big'
- }
- },
- style2: {
- 'size': {
- 'small': 'small',
- 'medium': 'medium*',
- 'big': 'big'
- }
- },
- style3: {
- 'size': {
- 'small': 'small',
- 'medium': 'medium*',
- 'big': 'big'
- }
- }
- }, {
- target: 'previous',
- palette: false
- });
-
+/*
+ Story by HTML5 UP
+ html5up.net | @ajlkn
+ Free for personal and commercial use under the CCA 3.0 license (html5up.net/license)
+
+ Note: Only needed for demo purposes. Delete for production sites.
+*/
+
+(function($) {
+
+ var $window = $(window);
+
+ // Styles.
+ $(
+ ''
+ ).appendTo($('head'));
+
+ // Functions.
+ $.fn.demo_controls = function(styles, userOptions) {
+
+ var $this = $(this),
+ $styleProperty, $stylePropertyClasses,
+ $controls, $x, $y, $z,
+ options,
+ current, i, j, k, s, n, count;
+
+ // No elements?
+ if (this.length == 0)
+ return $this;
+
+ // Multiple elements?
+ if (this.length > 1) {
+
+ for (var i=0; i < this.length; i++)
+ $(this[i]).demo_controls(styles, userOptions);
+
+ return $this;
+
+ }
+
+ // Options.
+ options = $.extend({
+ target: null,
+ palette: true
+ }, userOptions);
+
+ // Controls.
+ if (styles) {
+
+ $controls = $(
+ '' +
+ '' +
+ 'style ' +
+ ' ' + (options.palette ? ', ' : ' ') +
+ ' ' +
+ (options.palette ?
+ '' +
+ 'scheme ' +
+ '' +
+ 'default ' +
+ 'invert ' +
+ ' , ' +
+ ' ' +
+ '' +
+ 'color ' +
+ '' +
+ 'default ' +
+ 'color1 ' +
+ 'color2 ' +
+ 'color3 ' +
+ 'color4 ' +
+ 'color5 ' +
+ 'color6 ' +
+ 'color7 ' +
+ ' , ' +
+ ' '
+ : '') +
+ ' '
+ );
+
+ }
+ else {
+
+ $controls = $(
+ '' +
+ (options.palette ?
+ '' +
+ 'scheme ' +
+ '' +
+ 'default ' +
+ 'invert ' +
+ ' and ' +
+ ' ' +
+ '' +
+ 'color ' +
+ '' +
+ 'default ' +
+ 'color1 ' +
+ 'color2 ' +
+ 'color3 ' +
+ 'color4 ' +
+ 'color5 ' +
+ 'color6 ' +
+ 'color7 ' +
+ ' ' +
+ ' '
+ : '') +
+ ' '
+ );
+
+ }
+
+ // Target.
+ switch (options.target) {
+
+ case 'previous':
+ $this.prev().find('.demo-controls').replaceWith($controls);
+ break;
+
+ default:
+ $this.find('.demo-controls').replaceWith($controls);
+ break;
+
+ }
+
+ // Styles.
+ if (styles) {
+
+ $styleProperty = $controls.find('.property[data-name="style"]');
+ $stylePropertyClasses = $styleProperty.children('.classes');
+
+ for (i in styles) {
+
+ current = false;
+ count = Object.keys(styles[i]).length;
+ n = 1;
+
+ // Add to style property.
+ $x = $(', ' + i + ' ')
+ .appendTo($stylePropertyClasses);
+
+ if ($this.hasClass(i)) {
+
+ $x.addClass('active');
+ current = true;
+
+ }
+
+ // Step through properties.
+ for (j in styles[i]) {
+
+ $x = $(
+ '' +
+ (n == count ? 'and ' : '') +
+ '' + j + ' ' +
+ '' +
+ ' ' + (n < count ? ', ' : '') +
+ ' '
+ ).appendTo($controls);
+
+ $y = $x.children('.classes');
+
+ if (current)
+ $x.addClass('active');
+
+ for (k in styles[i][j]) {
+
+ $z = $(', ' + styles[i][j][k].replace('*', '') + ' ')
+ .appendTo($y);
+
+ if (styles[i][j][k].substr(-1, 1) == '*')
+ $z.addClass('default');
+
+ if (current
+ && $this.hasClass(k))
+ $z.addClass('active');
+
+ }
+
+ n++;
+
+ }
+
+ }
+
+ }
+
+ // Events.
+ $controls.on('click', 'a', function(event) {
+ event.preventDefault();
+ });
+
+ $controls.on('click', '.property.active', function(event) {
+
+ var $property = $(this);
+ var $classes = $property.find('.classes > *');
+ var $current = $classes.filter('.active');
+ var $next;
+
+ // Determine next.
+ if ($current.length == 0
+ || $current.index() == $classes.length - 1)
+ $next = $classes.first();
+ else
+ $next = $current.next();
+
+ // Turn on animate all.
+ $this.addClass('demo-animate-all');
+
+ // Deactivate current.
+ $current.removeClass('active');
+ $this.removeClass($current.data('class'));
+
+ // Activate next.
+ $next.addClass('active');
+ $this.addClass($next.data('class'));
+
+ // Turn off animate all.
+ setTimeout(function() {
+ $this.removeClass('demo-animate-all');
+ }, 500);
+
+ });
+
+ $controls.on('click', '.property[data-name="style"]', function(event) {
+
+ var $property = $(this);
+ var $classes = $property.find('.classes > *');
+ var $current = $classes.filter('.active');
+ var $next;
+
+ // Determine next.
+ if ($current.length == 0
+ || $current.index() == $classes.length - 1)
+ $next = $classes.first();
+ else
+ $next = $current.next();
+
+ // Turn on animate all.
+ $this.addClass('demo-animate-all');
+
+ // Deactivate current.
+ $current.removeClass('active');
+ $this.removeClass($current.data('class'));
+
+ $controls.find('.property[data-requires="' + $current.data('class') + '"]')
+ .removeClass('active');
+
+ $controls.find('.property[data-requires="' + $current.data('class') + '"] > .classes > .active').each(function() {
+
+ $(this).removeClass('active');
+
+ if ($(this).data('class') != '-')
+ $this.removeClass($(this).data('class'));
+
+ });
+
+ // Activate next.
+ $next.addClass('active');
+ $this.addClass($next.data('class'));
+
+ $controls.find('.property[data-requires="' + $next.data('class') + '"]')
+ .addClass('active');
+
+ $controls.find('.property[data-requires="' + $next.data('class') + '"] > .classes > .default').each(function() {
+
+ $(this).addClass('active');
+
+ if ($(this).data('class') != '-')
+ $this.addClass($(this).data('class'));
+
+ });
+
+ // Turn off animate all.
+ setTimeout(function() {
+ $this.removeClass('demo-animate-all');
+ }, 500);
+
+ });
+
+ };
+
+ // Elements.
+
+ // Wrappers.
+ $('.wrapper').demo_controls(null, {
+ palette: true
+ });
+
+ // Banner.
+ $('.banner').demo_controls({
+ style1: {
+ 'size': {
+ '-': 'normal',
+ 'fullscreen': 'fullscreen*'
+ },
+ 'orientation': {
+ 'orient-left': 'left*',
+ 'orient-right': 'right'
+ },
+ 'content alignment': {
+ 'content-align-left': 'left*',
+ 'content-align-center': 'center',
+ 'content-align-right': 'right'
+ },
+ 'image position': {
+ 'image-position-left': 'left',
+ 'image-position-center': 'center*',
+ 'image-position-right': 'right'
+ }
+ },
+ style2: {
+ 'size': {
+ '-': 'normal',
+ 'fullscreen': 'fullscreen*'
+ },
+ 'orientation': {
+ 'orient-left': 'left',
+ 'orient-center': 'center*',
+ 'orient-right': 'right'
+ },
+ 'content alignment': {
+ 'content-align-left': 'left',
+ 'content-align-center': 'center*',
+ 'content-align-right': 'right'
+ },
+ 'image position': {
+ 'image-position-left': 'left',
+ 'image-position-center': 'center*',
+ 'image-position-right': 'right'
+ }
+ },
+ style3: {
+ 'size': {
+ '-': 'normal',
+ 'fullscreen': 'fullscreen*'
+ },
+ 'orientation': {
+ 'orient-left': 'left',
+ 'orient-right': 'right*'
+ },
+ 'content alignment': {
+ 'content-align-left': 'left*',
+ 'content-align-center': 'center',
+ 'content-align-right': 'right'
+ },
+ 'image position': {
+ 'image-position-left': 'left',
+ 'image-position-center': 'center*',
+ 'image-position-right': 'right'
+ }
+ },
+ style4: {
+ 'size': {
+ '-': 'normal',
+ 'fullscreen': 'fullscreen*'
+ },
+ 'phone type': {
+ 'iphone': 'iphone*',
+ 'android': 'android'
+ },
+ 'orientation': {
+ 'orient-left': 'left',
+ 'orient-right': 'right*'
+ },
+ 'content alignment': {
+ 'content-align-left': 'left*',
+ 'content-align-center': 'center',
+ 'content-align-right': 'right'
+ },
+ 'image position': {
+ 'image-position-left': 'left',
+ 'image-position-center': 'center*',
+ 'image-position-right': 'right'
+ }
+ },
+ style5: {
+ 'size': {
+ '-': 'normal',
+ 'fullscreen': 'fullscreen*'
+ },
+ 'content alignment': {
+ 'content-align-left': 'left',
+ 'content-align-center': 'center*',
+ 'content-align-right': 'right'
+ },
+ 'image position': {
+ 'image-position-left': 'left',
+ 'image-position-center': 'center*',
+ 'image-position-right': 'right'
+ }
+ }
+ });
+
+ // Spotlight.
+ $('.spotlight').demo_controls({
+ style1: {
+ 'orientation': {
+ 'orient-left': 'left',
+ 'orient-right': 'right*'
+ },
+ 'content alignment': {
+ 'content-align-left': 'left*',
+ 'content-align-center': 'center',
+ 'content-align-right': 'right'
+ },
+ 'image position': {
+ 'image-position-left': 'left*',
+ 'image-position-center': 'center',
+ 'image-position-right': 'right'
+ }
+ },
+ style2: {
+ 'orientation': {
+ 'orient-left': 'left',
+ 'orient-right': 'right*'
+ },
+ 'content alignment': {
+ 'content-align-left': 'left*',
+ 'content-align-center': 'center',
+ 'content-align-right': 'right'
+ },
+ 'image position': {
+ 'image-position-left': 'left',
+ 'image-position-center': 'center*',
+ 'image-position-right': 'right'
+ }
+ },
+ style3: {
+ 'phone type': {
+ 'iphone': 'iphone*',
+ 'android': 'android'
+ },
+ 'orientation': {
+ 'orient-left': 'left',
+ 'orient-right': 'right*'
+ },
+ 'content alignment': {
+ 'content-align-left': 'left*',
+ 'content-align-center': 'center',
+ 'content-align-right': 'right'
+ },
+ 'image position': {
+ 'image-position-left': 'left',
+ 'image-position-center': 'center*',
+ 'image-position-right': 'right'
+ }
+ },
+ style4: {
+ 'size': {
+ '-size': 'normal',
+ 'fullscreen': 'fullscreen*',
+ 'halfscreen': 'halfscreen'
+ },
+ 'orientation': {
+ 'orient-left': 'left*',
+ 'orient-center': 'center',
+ 'orient-right': 'right'
+ },
+ 'content alignment': {
+ 'content-align-left': 'left*',
+ 'content-align-center': 'center',
+ 'content-align-right': 'right'
+ },
+ 'image position': {
+ 'image-position-left': 'left',
+ 'image-position-center': 'center*',
+ 'image-position-right': 'right'
+ }
+ },
+ style5: {
+ 'size': {
+ '-size': 'normal',
+ 'fullscreen': 'fullscreen*',
+ 'halfscreen': 'halfscreen'
+ },
+ 'orientation': {
+ 'orient-left': 'left*',
+ 'orient-center': 'center',
+ 'orient-right': 'right'
+ },
+ 'content alignment': {
+ 'content-align-left': 'left*',
+ 'content-align-center': 'center',
+ 'content-align-right': 'right'
+ },
+ 'image position': {
+ 'image-position-left': 'left',
+ 'image-position-center': 'center*',
+ 'image-position-right': 'right'
+ }
+ },
+ });
+
+ // Gallery.
+ $('.gallery').demo_controls({
+ style1: {
+ 'size': {
+ 'small': 'small',
+ 'medium': 'medium*',
+ 'big': 'big'
+ }
+ },
+ style2: {
+ 'size': {
+ 'small': 'small',
+ 'medium': 'medium*',
+ 'big': 'big'
+ }
+ },
+ }, {
+ target: 'previous',
+ palette: false
+ });
+
+ // Items.
+ $('.items').demo_controls({
+ style1: {
+ 'size': {
+ 'small': 'small',
+ 'medium': 'medium*',
+ 'big': 'big'
+ }
+ },
+ style2: {
+ 'size': {
+ 'small': 'small',
+ 'medium': 'medium*',
+ 'big': 'big'
+ }
+ },
+ style3: {
+ 'size': {
+ 'small': 'small',
+ 'medium': 'medium*',
+ 'big': 'big'
+ }
+ }
+ }, {
+ target: 'previous',
+ palette: false
+ });
+
})(jQuery);
\ No newline at end of file
diff --git a/assets/js/jquery.scrollex.min.js b/assets/js/jquery.scrollex.min.js
index c511a5c..a4727fe 100644
--- a/assets/js/jquery.scrollex.min.js
+++ b/assets/js/jquery.scrollex.min.js
@@ -1,2 +1,2 @@
-/* jquery.scrollex v0.2.1 | (c) @ajlkn | github.com/ajlkn/jquery.scrollex | MIT licensed */
+/* jquery.scrollex v0.2.1 | (c) @ajlkn | github.com/ajlkn/jquery.scrollex | MIT licensed */
!function(t){function e(t,e,n){return"string"==typeof t&&("%"==t.slice(-1)?t=parseInt(t.substring(0,t.length-1))/100*e:"vh"==t.slice(-2)?t=parseInt(t.substring(0,t.length-2))/100*n:"px"==t.slice(-2)&&(t=parseInt(t.substring(0,t.length-2)))),t}var n=t(window),i=1,o={};n.on("scroll",function(){var e=n.scrollTop();t.map(o,function(t){window.clearTimeout(t.timeoutId),t.timeoutId=window.setTimeout(function(){t.handler(e)},t.options.delay)})}).on("load",function(){n.trigger("scroll")}),jQuery.fn.scrollex=function(l){var s=t(this);if(0==this.length)return s;if(this.length>1){for(var r=0;r=i&&o>=t};break;case"bottom":h=function(t,e,n,i,o){return n>=i&&o>=n};break;case"middle":h=function(t,e,n,i,o){return e>=i&&o>=e};break;case"top-only":h=function(t,e,n,i,o){return i>=t&&n>=i};break;case"bottom-only":h=function(t,e,n,i,o){return n>=o&&o>=t};break;default:case"default":h=function(t,e,n,i,o){return n>=i&&o>=t}}return c=function(t){var i,o,l,s,r,a,u=this.state,h=!1,c=this.$element.offset();i=n.height(),o=t+i/2,l=t+i,s=this.$element.outerHeight(),r=c.top+e(this.options.top,s,i),a=c.top+s-e(this.options.bottom,s,i),h=this.test(t,o,l,r,a),h!=u&&(this.state=h,h?this.options.enter&&this.options.enter.apply(this.element):this.options.leave&&this.options.leave.apply(this.element)),this.options.scroll&&this.options.scroll.apply(this.element,[(o-r)/(a-r)])},p={id:a,options:u,test:h,handler:c,state:null,element:this,$element:s,timeoutId:null},o[a]=p,s.data("_scrollexId",p.id),p.options.initialize&&p.options.initialize.apply(this),s},jQuery.fn.unscrollex=function(){var e=t(this);if(0==this.length)return e;if(this.length>1){for(var n=0;n1){for(o=0;o' +
- ' ' +
- '' + $('#logo').html() + ' ' +
- ' '
- )
- .appendTo($body);
-
- // Panel.
- $header
- .panel({
- delay: 500,
- hideOnClick: true,
- hideOnSwipe: true,
- resetScroll: true,
- resetForms: true,
- side: 'right',
- target: $body,
- visibleClass: 'header-visible'
- });
-
- // Scrolly.
- $('.scrolly').scrolly({
- speed: 1000,
- offset: function() {
-
- if (breakpoints.active('<=medium'))
- return $titleBar.height();
-
- return 0;
-
- }
- });
- // Gallery.
- $('.gallery')
- .wrapInner('
')
- .prepend(browser.mobile ? '' : '
')
- .scrollex({
- top: '30vh',
- bottom: '30vh',
- delay: 50,
- initialize: function() {
- $(this).addClass('is-inactive');
- },
- terminate: function() {
- $(this).removeClass('is-inactive');
- },
- enter: function() {
- $(this).removeClass('is-inactive');
- },
- leave: function() {
-
- var $this = $(this);
-
- if ($this.hasClass('onscroll-bidirectional'))
- $this.addClass('is-inactive');
-
- }
- })
- .children('.inner')
- //.css('overflow', 'hidden')
- .css('overflow-y', browser.mobile ? 'visible' : 'hidden')
- .css('overflow-x', browser.mobile ? 'scroll' : 'hidden')
- .scrollLeft(0);
-
- // Style #1.
- // ...
-
- // Style #2.
- $('.gallery')
- .on('wheel', '.inner', function(event) {
-
- var $this = $(this),
- delta = (event.originalEvent.deltaX * 10);
-
- // Cap delta.
- if (delta > 0)
- delta = Math.min(25, delta);
- else if (delta < 0)
- delta = Math.max(-25, delta);
-
- // Scroll.
- $this.scrollLeft( $this.scrollLeft() + delta );
-
- })
- .on('mouseenter', '.forward, .backward', function(event) {
-
- var $this = $(this),
- $inner = $this.siblings('.inner'),
- direction = ($this.hasClass('forward') ? 1 : -1);
-
- // Clear move interval.
- clearInterval(this._gallery_moveIntervalId);
-
- // Start interval.
- this._gallery_moveIntervalId = setInterval(function() {
- $inner.scrollLeft( $inner.scrollLeft() + (5 * direction) );
- }, 10);
-
- })
- .on('mouseleave', '.forward, .backward', function(event) {
-
- // Clear move interval.
- clearInterval(this._gallery_moveIntervalId);
-
- });
-
- // Lightbox.
- $('.gallery.lightbox')
- .on('click', 'a', function(event) {
-
- var $a = $(this),
- $gallery = $a.parents('.gallery'),
- $modal = $gallery.children('.modal'),
- $modalImg = $modal.find('img'),
- href = $a.attr('href');
-
- // Not an image? Bail.
- if (!href.match(/\.(jpg|gif|png|mp4)$/))
- return;
-
- // Prevent default.
- event.preventDefault();
- event.stopPropagation();
-
- // Locked? Bail.
- if ($modal[0]._locked)
- return;
-
- // Lock.
- $modal[0]._locked = true;
-
- // Set src.
- $modalImg.attr('src', href);
-
- // Set visible.
- $modal.addClass('visible');
-
- // Focus.
- $modal.focus();
-
- // Delay.
- setTimeout(function() {
-
- // Unlock.
- $modal[0]._locked = false;
-
- }, 600);
-
- })
- .on('click', '.modal', function(event) {
-
- var $modal = $(this),
- $modalImg = $modal.find('img');
-
- // Locked? Bail.
- if ($modal[0]._locked)
- return;
-
- // Already hidden? Bail.
- if (!$modal.hasClass('visible'))
- return;
-
- // Lock.
- $modal[0]._locked = true;
-
- // Clear visible, loaded.
- $modal
- .removeClass('loaded')
-
- // Delay.
- setTimeout(function() {
-
- $modal
- .removeClass('visible')
-
- setTimeout(function() {
-
- // Clear src.
- $modalImg.attr('src', '');
-
- // Unlock.
- $modal[0]._locked = false;
-
- // Focus.
- $body.focus();
-
- }, 475);
-
- }, 125);
-
- })
- .on('keypress', '.modal', function(event) {
-
- var $modal = $(this);
-
- // Escape? Hide modal.
- if (event.keyCode == 27)
- $modal.trigger('click');
-
- })
- .prepend('
')
- .find('img')
- .on('load', function(event) {
-
- var $modalImg = $(this),
- $modal = $modalImg.parents('.modal');
-
- setTimeout(function() {
-
- // No longer visible? Bail.
- if (!$modal.hasClass('visible'))
- return;
-
- // Set loaded.
- $modal.addClass('loaded');
-
- }, 275);
-
- });
-
-
+/*
+ Read Only by HTML5 UP
+ html5up.net | @ajlkn
+ Free for personal and commercial use under the CCA 3.0 license (html5up.net/license)
+*/
+
+(function($) {
+
+ var $window = $(window),
+ $body = $('body'),
+ $header = $('#header'),
+ $titleBar = null,
+ $nav = $('#nav'),
+ $wrapper = $('#wrapper');
+
+ // Breakpoints.
+ breakpoints({
+ xlarge: [ '1281px', '1680px' ],
+ large: [ '1025px', '1280px' ],
+ medium: [ '737px', '1024px' ],
+ small: [ '481px', '736px' ],
+ xsmall: [ null, '480px' ],
+ });
+
+ // Play initial animations on page load.
+ $window.on('load', function() {
+ window.setTimeout(function() {
+ $body.removeClass('is-preload');
+ }, 100);
+ });
+
+ // Tweaks/fixes.
+
+ // Polyfill: Object fit.
+ if (!browser.canUse('object-fit')) {
+
+ $('.image[data-position]').each(function() {
+
+ var $this = $(this),
+ $img = $this.children('img');
+
+ // Apply img as background.
+ $this
+ .css('background-image', 'url("' + $img.attr('src') + '")')
+ .css('background-position', $this.data('position'))
+ .css('background-size', 'cover')
+ .css('background-repeat', 'no-repeat');
+
+ // Hide img.
+ $img
+ .css('opacity', '0');
+
+ });
+
+ }
+
+ // Header Panel.
+
+ // Nav.
+ var $nav_a = $nav.find('a');
+
+ $nav_a
+ .addClass('scrolly')
+ .on('click', function() {
+
+ var $this = $(this);
+
+ // External link? Bail.
+ if ($this.attr('href').charAt(0) != '#')
+ return;
+
+ // Deactivate all links.
+ $nav_a.removeClass('active');
+
+ // Activate link *and* lock it (so Scrollex doesn't try to activate other links as we're scrolling to this one's section).
+ $this
+ .addClass('active')
+ .addClass('active-locked');
+
+ })
+ .each(function() {
+
+ var $this = $(this),
+ id = $this.attr('href'),
+ $section = $(id);
+
+ // No section for this link? Bail.
+ if ($section.length < 1)
+ return;
+
+ // Scrollex.
+ $section.scrollex({
+ mode: 'middle',
+ top: '5vh',
+ bottom: '5vh',
+ initialize: function() {
+
+ // Deactivate section.
+ $section.addClass('inactive');
+
+ },
+ enter: function() {
+
+ // Activate section.
+ $section.removeClass('inactive');
+
+ // No locked links? Deactivate all links and activate this section's one.
+ if ($nav_a.filter('.active-locked').length == 0) {
+
+ $nav_a.removeClass('active');
+ $this.addClass('active');
+
+ }
+
+ // Otherwise, if this section's link is the one that's locked, unlock it.
+ else if ($this.hasClass('active-locked'))
+ $this.removeClass('active-locked');
+
+ }
+ });
+
+ });
+
+ // Title Bar.
+ $titleBar = $(
+ '
' +
+ '
' +
+ '
' + $('#logo').html() + ' ' +
+ '
'
+ )
+ .appendTo($body);
+
+ // Panel.
+ $header
+ .panel({
+ delay: 500,
+ hideOnClick: true,
+ hideOnSwipe: true,
+ resetScroll: true,
+ resetForms: true,
+ side: 'right',
+ target: $body,
+ visibleClass: 'header-visible'
+ });
+
+ // Scrolly.
+ $('.scrolly').scrolly({
+ speed: 1000,
+ offset: function() {
+
+ if (breakpoints.active('<=medium'))
+ return $titleBar.height();
+
+ return 0;
+
+ }
+ });
+ // Gallery.
+ $('.gallery')
+ .wrapInner('
')
+ .prepend(browser.mobile ? '' : '
')
+ .scrollex({
+ top: '30vh',
+ bottom: '30vh',
+ delay: 50,
+ initialize: function() {
+ $(this).addClass('is-inactive');
+ },
+ terminate: function() {
+ $(this).removeClass('is-inactive');
+ },
+ enter: function() {
+ $(this).removeClass('is-inactive');
+ },
+ leave: function() {
+
+ var $this = $(this);
+
+ if ($this.hasClass('onscroll-bidirectional'))
+ $this.addClass('is-inactive');
+
+ }
+ })
+ .children('.inner')
+ //.css('overflow', 'hidden')
+ .css('overflow-y', browser.mobile ? 'visible' : 'hidden')
+ .css('overflow-x', browser.mobile ? 'scroll' : 'hidden')
+ .scrollLeft(0);
+
+ // Style #1.
+ // ...
+
+ // Style #2.
+ $('.gallery')
+ .on('wheel', '.inner', function(event) {
+
+ var $this = $(this),
+ delta = (event.originalEvent.deltaX * 10);
+
+ // Cap delta.
+ if (delta > 0)
+ delta = Math.min(25, delta);
+ else if (delta < 0)
+ delta = Math.max(-25, delta);
+
+ // Scroll.
+ $this.scrollLeft( $this.scrollLeft() + delta );
+
+ })
+ .on('mouseenter', '.forward, .backward', function(event) {
+
+ var $this = $(this),
+ $inner = $this.siblings('.inner'),
+ direction = ($this.hasClass('forward') ? 1 : -1);
+
+ // Clear move interval.
+ clearInterval(this._gallery_moveIntervalId);
+
+ // Start interval.
+ this._gallery_moveIntervalId = setInterval(function() {
+ $inner.scrollLeft( $inner.scrollLeft() + (5 * direction) );
+ }, 10);
+
+ })
+ .on('mouseleave', '.forward, .backward', function(event) {
+
+ // Clear move interval.
+ clearInterval(this._gallery_moveIntervalId);
+
+ });
+
+ // Lightbox.
+ $('.gallery.lightbox')
+ .on('click', 'a', function(event) {
+
+ var $a = $(this),
+ $gallery = $a.parents('.gallery'),
+ $modal = $gallery.children('.modal'),
+ $modalImg = $modal.find('img'),
+ href = $a.attr('href');
+
+ // Not an image? Bail.
+ if (!href.match(/\.(jpg|gif|png|mp4)$/))
+ return;
+
+ // Prevent default.
+ event.preventDefault();
+ event.stopPropagation();
+
+ // Locked? Bail.
+ if ($modal[0]._locked)
+ return;
+
+ // Lock.
+ $modal[0]._locked = true;
+
+ // Set src.
+ $modalImg.attr('src', href);
+
+ // Set visible.
+ $modal.addClass('visible');
+
+ // Focus.
+ $modal.focus();
+
+ // Delay.
+ setTimeout(function() {
+
+ // Unlock.
+ $modal[0]._locked = false;
+
+ }, 600);
+
+ })
+ .on('click', '.modal', function(event) {
+
+ var $modal = $(this),
+ $modalImg = $modal.find('img');
+
+ // Locked? Bail.
+ if ($modal[0]._locked)
+ return;
+
+ // Already hidden? Bail.
+ if (!$modal.hasClass('visible'))
+ return;
+
+ // Lock.
+ $modal[0]._locked = true;
+
+ // Clear visible, loaded.
+ $modal
+ .removeClass('loaded')
+
+ // Delay.
+ setTimeout(function() {
+
+ $modal
+ .removeClass('visible')
+
+ setTimeout(function() {
+
+ // Clear src.
+ $modalImg.attr('src', '');
+
+ // Unlock.
+ $modal[0]._locked = false;
+
+ // Focus.
+ $body.focus();
+
+ }, 475);
+
+ }, 125);
+
+ })
+ .on('keypress', '.modal', function(event) {
+
+ var $modal = $(this);
+
+ // Escape? Hide modal.
+ if (event.keyCode == 27)
+ $modal.trigger('click');
+
+ })
+ .prepend('
')
+ .find('img')
+ .on('load', function(event) {
+
+ var $modalImg = $(this),
+ $modal = $modalImg.parents('.modal');
+
+ setTimeout(function() {
+
+ // No longer visible? Bail.
+ if (!$modal.hasClass('visible'))
+ return;
+
+ // Set loaded.
+ $modal.addClass('loaded');
+
+ }, 275);
+
+ });
+
+
})(jQuery);
\ No newline at end of file
diff --git a/assets/js/util.js b/assets/js/util.js
index ecf7b37..bdb8e9f 100644
--- a/assets/js/util.js
+++ b/assets/js/util.js
@@ -1,587 +1,587 @@
-(function($) {
-
- /**
- * Generate an indented list of links from a nav. Meant for use with panel().
- * @return {jQuery} jQuery object.
- */
- $.fn.navList = function() {
-
- var $this = $(this);
- $a = $this.find('a'),
- b = [];
-
- $a.each(function() {
-
- var $this = $(this),
- indent = Math.max(0, $this.parents('li').length - 1),
- href = $this.attr('href'),
- target = $this.attr('target');
-
- b.push(
- '
' +
- ' ' +
- $this.text() +
- ' '
- );
-
- });
-
- return b.join('');
-
- };
-
- /**
- * Panel-ify an element.
- * @param {object} userConfig User config.
- * @return {jQuery} jQuery object.
- */
- $.fn.panel = function(userConfig) {
-
- // No elements?
- if (this.length == 0)
- return $this;
-
- // Multiple elements?
- if (this.length > 1) {
-
- for (var i=0; i < this.length; i++)
- $(this[i]).panel(userConfig);
-
- return $this;
-
- }
-
- // Vars.
- var $this = $(this),
- $body = $('body'),
- $window = $(window),
- id = $this.attr('id'),
- config;
-
- // Config.
- config = $.extend({
-
- // Delay.
- delay: 0,
-
- // Hide panel on link click.
- hideOnClick: false,
-
- // Hide panel on escape keypress.
- hideOnEscape: false,
-
- // Hide panel on swipe.
- hideOnSwipe: false,
-
- // Reset scroll position on hide.
- resetScroll: false,
-
- // Reset forms on hide.
- resetForms: false,
-
- // Side of viewport the panel will appear.
- side: null,
-
- // Target element for "class".
- target: $this,
-
- // Class to toggle.
- visibleClass: 'visible'
-
- }, userConfig);
-
- // Expand "target" if it's not a jQuery object already.
- if (typeof config.target != 'jQuery')
- config.target = $(config.target);
-
- // Panel.
-
- // Methods.
- $this._hide = function(event) {
-
- // Already hidden? Bail.
- if (!config.target.hasClass(config.visibleClass))
- return;
-
- // If an event was provided, cancel it.
- if (event) {
-
- event.preventDefault();
- event.stopPropagation();
-
- }
-
- // Hide.
- config.target.removeClass(config.visibleClass);
-
- // Post-hide stuff.
- window.setTimeout(function() {
-
- // Reset scroll position.
- if (config.resetScroll)
- $this.scrollTop(0);
-
- // Reset forms.
- if (config.resetForms)
- $this.find('form').each(function() {
- this.reset();
- });
-
- }, config.delay);
-
- };
-
- // Vendor fixes.
- $this
- .css('-ms-overflow-style', '-ms-autohiding-scrollbar')
- .css('-webkit-overflow-scrolling', 'touch');
-
- // Hide on click.
- if (config.hideOnClick) {
-
- $this.find('a')
- .css('-webkit-tap-highlight-color', 'rgba(0,0,0,0)');
-
- $this
- .on('click', 'a', function(event) {
-
- var $a = $(this),
- href = $a.attr('href'),
- target = $a.attr('target');
-
- if (!href || href == '#' || href == '' || href == '#' + id)
- return;
-
- // Cancel original event.
- event.preventDefault();
- event.stopPropagation();
-
- // Hide panel.
- $this._hide();
-
- // Redirect to href.
- window.setTimeout(function() {
-
- if (target == '_blank')
- window.open(href);
- else
- window.location.href = href;
-
- }, config.delay + 10);
-
- });
-
- }
-
- // Event: Touch stuff.
- $this.on('touchstart', function(event) {
-
- $this.touchPosX = event.originalEvent.touches[0].pageX;
- $this.touchPosY = event.originalEvent.touches[0].pageY;
-
- })
-
- $this.on('touchmove', function(event) {
-
- if ($this.touchPosX === null
- || $this.touchPosY === null)
- return;
-
- var diffX = $this.touchPosX - event.originalEvent.touches[0].pageX,
- diffY = $this.touchPosY - event.originalEvent.touches[0].pageY,
- th = $this.outerHeight(),
- ts = ($this.get(0).scrollHeight - $this.scrollTop());
-
- // Hide on swipe?
- if (config.hideOnSwipe) {
-
- var result = false,
- boundary = 20,
- delta = 50;
-
- switch (config.side) {
-
- case 'left':
- result = (diffY < boundary && diffY > (-1 * boundary)) && (diffX > delta);
- break;
-
- case 'right':
- result = (diffY < boundary && diffY > (-1 * boundary)) && (diffX < (-1 * delta));
- break;
-
- case 'top':
- result = (diffX < boundary && diffX > (-1 * boundary)) && (diffY > delta);
- break;
-
- case 'bottom':
- result = (diffX < boundary && diffX > (-1 * boundary)) && (diffY < (-1 * delta));
- break;
-
- default:
- break;
-
- }
-
- if (result) {
-
- $this.touchPosX = null;
- $this.touchPosY = null;
- $this._hide();
-
- return false;
-
- }
-
- }
-
- // Prevent vertical scrolling past the top or bottom.
- if (($this.scrollTop() < 0 && diffY < 0)
- || (ts > (th - 2) && ts < (th + 2) && diffY > 0)) {
-
- event.preventDefault();
- event.stopPropagation();
-
- }
-
- });
-
- // Event: Prevent certain events inside the panel from bubbling.
- $this.on('click touchend touchstart touchmove', function(event) {
- event.stopPropagation();
- });
-
- // Event: Hide panel if a child anchor tag pointing to its ID is clicked.
- $this.on('click', 'a[href="#' + id + '"]', function(event) {
-
- event.preventDefault();
- event.stopPropagation();
-
- config.target.removeClass(config.visibleClass);
-
- });
-
- // Body.
-
- // Event: Hide panel on body click/tap.
- $body.on('click touchend', function(event) {
- $this._hide(event);
- });
-
- // Event: Toggle.
- $body.on('click', 'a[href="#' + id + '"]', function(event) {
-
- event.preventDefault();
- event.stopPropagation();
-
- config.target.toggleClass(config.visibleClass);
-
- });
-
- // Window.
-
- // Event: Hide on ESC.
- if (config.hideOnEscape)
- $window.on('keydown', function(event) {
-
- if (event.keyCode == 27)
- $this._hide(event);
-
- });
-
- return $this;
-
- };
-
- /**
- * Apply "placeholder" attribute polyfill to one or more forms.
- * @return {jQuery} jQuery object.
- */
- $.fn.placeholder = function() {
-
- // Browser natively supports placeholders? Bail.
- if (typeof (document.createElement('input')).placeholder != 'undefined')
- return $(this);
-
- // No elements?
- if (this.length == 0)
- return $this;
-
- // Multiple elements?
- if (this.length > 1) {
-
- for (var i=0; i < this.length; i++)
- $(this[i]).placeholder();
-
- return $this;
-
- }
-
- // Vars.
- var $this = $(this);
-
- // Text, TextArea.
- $this.find('input[type=text],textarea')
- .each(function() {
-
- var i = $(this);
-
- if (i.val() == ''
- || i.val() == i.attr('placeholder'))
- i
- .addClass('polyfill-placeholder')
- .val(i.attr('placeholder'));
-
- })
- .on('blur', function() {
-
- var i = $(this);
-
- if (i.attr('name').match(/-polyfill-field$/))
- return;
-
- if (i.val() == '')
- i
- .addClass('polyfill-placeholder')
- .val(i.attr('placeholder'));
-
- })
- .on('focus', function() {
-
- var i = $(this);
-
- if (i.attr('name').match(/-polyfill-field$/))
- return;
-
- if (i.val() == i.attr('placeholder'))
- i
- .removeClass('polyfill-placeholder')
- .val('');
-
- });
-
- // Password.
- $this.find('input[type=password]')
- .each(function() {
-
- var i = $(this);
- var x = $(
- $('
')
- .append(i.clone())
- .remove()
- .html()
- .replace(/type="password"/i, 'type="text"')
- .replace(/type=password/i, 'type=text')
- );
-
- if (i.attr('id') != '')
- x.attr('id', i.attr('id') + '-polyfill-field');
-
- if (i.attr('name') != '')
- x.attr('name', i.attr('name') + '-polyfill-field');
-
- x.addClass('polyfill-placeholder')
- .val(x.attr('placeholder')).insertAfter(i);
-
- if (i.val() == '')
- i.hide();
- else
- x.hide();
-
- i
- .on('blur', function(event) {
-
- event.preventDefault();
-
- var x = i.parent().find('input[name=' + i.attr('name') + '-polyfill-field]');
-
- if (i.val() == '') {
-
- i.hide();
- x.show();
-
- }
-
- });
-
- x
- .on('focus', function(event) {
-
- event.preventDefault();
-
- var i = x.parent().find('input[name=' + x.attr('name').replace('-polyfill-field', '') + ']');
-
- x.hide();
-
- i
- .show()
- .focus();
-
- })
- .on('keypress', function(event) {
-
- event.preventDefault();
- x.val('');
-
- });
-
- });
-
- // Events.
- $this
- .on('submit', function() {
-
- $this.find('input[type=text],input[type=password],textarea')
- .each(function(event) {
-
- var i = $(this);
-
- if (i.attr('name').match(/-polyfill-field$/))
- i.attr('name', '');
-
- if (i.val() == i.attr('placeholder')) {
-
- i.removeClass('polyfill-placeholder');
- i.val('');
-
- }
-
- });
-
- })
- .on('reset', function(event) {
-
- event.preventDefault();
-
- $this.find('select')
- .val($('option:first').val());
-
- $this.find('input,textarea')
- .each(function() {
-
- var i = $(this),
- x;
-
- i.removeClass('polyfill-placeholder');
-
- switch (this.type) {
-
- case 'submit':
- case 'reset':
- break;
-
- case 'password':
- i.val(i.attr('defaultValue'));
-
- x = i.parent().find('input[name=' + i.attr('name') + '-polyfill-field]');
-
- if (i.val() == '') {
- i.hide();
- x.show();
- }
- else {
- i.show();
- x.hide();
- }
-
- break;
-
- case 'checkbox':
- case 'radio':
- i.attr('checked', i.attr('defaultValue'));
- break;
-
- case 'text':
- case 'textarea':
- i.val(i.attr('defaultValue'));
-
- if (i.val() == '') {
- i.addClass('polyfill-placeholder');
- i.val(i.attr('placeholder'));
- }
-
- break;
-
- default:
- i.val(i.attr('defaultValue'));
- break;
-
- }
- });
-
- });
-
- return $this;
-
- };
-
- /**
- * Moves elements to/from the first positions of their respective parents.
- * @param {jQuery} $elements Elements (or selector) to move.
- * @param {bool} condition If true, moves elements to the top. Otherwise, moves elements back to their original locations.
- */
- $.prioritize = function($elements, condition) {
-
- var key = '__prioritize';
-
- // Expand $elements if it's not already a jQuery object.
- if (typeof $elements != 'jQuery')
- $elements = $($elements);
-
- // Step through elements.
- $elements.each(function() {
-
- var $e = $(this), $p,
- $parent = $e.parent();
-
- // No parent? Bail.
- if ($parent.length == 0)
- return;
-
- // Not moved? Move it.
- if (!$e.data(key)) {
-
- // Condition is false? Bail.
- if (!condition)
- return;
-
- // Get placeholder (which will serve as our point of reference for when this element needs to move back).
- $p = $e.prev();
-
- // Couldn't find anything? Means this element's already at the top, so bail.
- if ($p.length == 0)
- return;
-
- // Move element to top of parent.
- $e.prependTo($parent);
-
- // Mark element as moved.
- $e.data(key, $p);
-
- }
-
- // Moved already?
- else {
-
- // Condition is true? Bail.
- if (condition)
- return;
-
- $p = $e.data(key);
-
- // Move element back to its original location (using our placeholder).
- $e.insertAfter($p);
-
- // Unmark element as moved.
- $e.removeData(key);
-
- }
-
- });
-
- };
-
+(function($) {
+
+ /**
+ * Generate an indented list of links from a nav. Meant for use with panel().
+ * @return {jQuery} jQuery object.
+ */
+ $.fn.navList = function() {
+
+ var $this = $(this);
+ $a = $this.find('a'),
+ b = [];
+
+ $a.each(function() {
+
+ var $this = $(this),
+ indent = Math.max(0, $this.parents('li').length - 1),
+ href = $this.attr('href'),
+ target = $this.attr('target');
+
+ b.push(
+ '
' +
+ ' ' +
+ $this.text() +
+ ' '
+ );
+
+ });
+
+ return b.join('');
+
+ };
+
+ /**
+ * Panel-ify an element.
+ * @param {object} userConfig User config.
+ * @return {jQuery} jQuery object.
+ */
+ $.fn.panel = function(userConfig) {
+
+ // No elements?
+ if (this.length == 0)
+ return $this;
+
+ // Multiple elements?
+ if (this.length > 1) {
+
+ for (var i=0; i < this.length; i++)
+ $(this[i]).panel(userConfig);
+
+ return $this;
+
+ }
+
+ // Vars.
+ var $this = $(this),
+ $body = $('body'),
+ $window = $(window),
+ id = $this.attr('id'),
+ config;
+
+ // Config.
+ config = $.extend({
+
+ // Delay.
+ delay: 0,
+
+ // Hide panel on link click.
+ hideOnClick: false,
+
+ // Hide panel on escape keypress.
+ hideOnEscape: false,
+
+ // Hide panel on swipe.
+ hideOnSwipe: false,
+
+ // Reset scroll position on hide.
+ resetScroll: false,
+
+ // Reset forms on hide.
+ resetForms: false,
+
+ // Side of viewport the panel will appear.
+ side: null,
+
+ // Target element for "class".
+ target: $this,
+
+ // Class to toggle.
+ visibleClass: 'visible'
+
+ }, userConfig);
+
+ // Expand "target" if it's not a jQuery object already.
+ if (typeof config.target != 'jQuery')
+ config.target = $(config.target);
+
+ // Panel.
+
+ // Methods.
+ $this._hide = function(event) {
+
+ // Already hidden? Bail.
+ if (!config.target.hasClass(config.visibleClass))
+ return;
+
+ // If an event was provided, cancel it.
+ if (event) {
+
+ event.preventDefault();
+ event.stopPropagation();
+
+ }
+
+ // Hide.
+ config.target.removeClass(config.visibleClass);
+
+ // Post-hide stuff.
+ window.setTimeout(function() {
+
+ // Reset scroll position.
+ if (config.resetScroll)
+ $this.scrollTop(0);
+
+ // Reset forms.
+ if (config.resetForms)
+ $this.find('form').each(function() {
+ this.reset();
+ });
+
+ }, config.delay);
+
+ };
+
+ // Vendor fixes.
+ $this
+ .css('-ms-overflow-style', '-ms-autohiding-scrollbar')
+ .css('-webkit-overflow-scrolling', 'touch');
+
+ // Hide on click.
+ if (config.hideOnClick) {
+
+ $this.find('a')
+ .css('-webkit-tap-highlight-color', 'rgba(0,0,0,0)');
+
+ $this
+ .on('click', 'a', function(event) {
+
+ var $a = $(this),
+ href = $a.attr('href'),
+ target = $a.attr('target');
+
+ if (!href || href == '#' || href == '' || href == '#' + id)
+ return;
+
+ // Cancel original event.
+ event.preventDefault();
+ event.stopPropagation();
+
+ // Hide panel.
+ $this._hide();
+
+ // Redirect to href.
+ window.setTimeout(function() {
+
+ if (target == '_blank')
+ window.open(href);
+ else
+ window.location.href = href;
+
+ }, config.delay + 10);
+
+ });
+
+ }
+
+ // Event: Touch stuff.
+ $this.on('touchstart', function(event) {
+
+ $this.touchPosX = event.originalEvent.touches[0].pageX;
+ $this.touchPosY = event.originalEvent.touches[0].pageY;
+
+ })
+
+ $this.on('touchmove', function(event) {
+
+ if ($this.touchPosX === null
+ || $this.touchPosY === null)
+ return;
+
+ var diffX = $this.touchPosX - event.originalEvent.touches[0].pageX,
+ diffY = $this.touchPosY - event.originalEvent.touches[0].pageY,
+ th = $this.outerHeight(),
+ ts = ($this.get(0).scrollHeight - $this.scrollTop());
+
+ // Hide on swipe?
+ if (config.hideOnSwipe) {
+
+ var result = false,
+ boundary = 20,
+ delta = 50;
+
+ switch (config.side) {
+
+ case 'left':
+ result = (diffY < boundary && diffY > (-1 * boundary)) && (diffX > delta);
+ break;
+
+ case 'right':
+ result = (diffY < boundary && diffY > (-1 * boundary)) && (diffX < (-1 * delta));
+ break;
+
+ case 'top':
+ result = (diffX < boundary && diffX > (-1 * boundary)) && (diffY > delta);
+ break;
+
+ case 'bottom':
+ result = (diffX < boundary && diffX > (-1 * boundary)) && (diffY < (-1 * delta));
+ break;
+
+ default:
+ break;
+
+ }
+
+ if (result) {
+
+ $this.touchPosX = null;
+ $this.touchPosY = null;
+ $this._hide();
+
+ return false;
+
+ }
+
+ }
+
+ // Prevent vertical scrolling past the top or bottom.
+ if (($this.scrollTop() < 0 && diffY < 0)
+ || (ts > (th - 2) && ts < (th + 2) && diffY > 0)) {
+
+ event.preventDefault();
+ event.stopPropagation();
+
+ }
+
+ });
+
+ // Event: Prevent certain events inside the panel from bubbling.
+ $this.on('click touchend touchstart touchmove', function(event) {
+ event.stopPropagation();
+ });
+
+ // Event: Hide panel if a child anchor tag pointing to its ID is clicked.
+ $this.on('click', 'a[href="#' + id + '"]', function(event) {
+
+ event.preventDefault();
+ event.stopPropagation();
+
+ config.target.removeClass(config.visibleClass);
+
+ });
+
+ // Body.
+
+ // Event: Hide panel on body click/tap.
+ $body.on('click touchend', function(event) {
+ $this._hide(event);
+ });
+
+ // Event: Toggle.
+ $body.on('click', 'a[href="#' + id + '"]', function(event) {
+
+ event.preventDefault();
+ event.stopPropagation();
+
+ config.target.toggleClass(config.visibleClass);
+
+ });
+
+ // Window.
+
+ // Event: Hide on ESC.
+ if (config.hideOnEscape)
+ $window.on('keydown', function(event) {
+
+ if (event.keyCode == 27)
+ $this._hide(event);
+
+ });
+
+ return $this;
+
+ };
+
+ /**
+ * Apply "placeholder" attribute polyfill to one or more forms.
+ * @return {jQuery} jQuery object.
+ */
+ $.fn.placeholder = function() {
+
+ // Browser natively supports placeholders? Bail.
+ if (typeof (document.createElement('input')).placeholder != 'undefined')
+ return $(this);
+
+ // No elements?
+ if (this.length == 0)
+ return $this;
+
+ // Multiple elements?
+ if (this.length > 1) {
+
+ for (var i=0; i < this.length; i++)
+ $(this[i]).placeholder();
+
+ return $this;
+
+ }
+
+ // Vars.
+ var $this = $(this);
+
+ // Text, TextArea.
+ $this.find('input[type=text],textarea')
+ .each(function() {
+
+ var i = $(this);
+
+ if (i.val() == ''
+ || i.val() == i.attr('placeholder'))
+ i
+ .addClass('polyfill-placeholder')
+ .val(i.attr('placeholder'));
+
+ })
+ .on('blur', function() {
+
+ var i = $(this);
+
+ if (i.attr('name').match(/-polyfill-field$/))
+ return;
+
+ if (i.val() == '')
+ i
+ .addClass('polyfill-placeholder')
+ .val(i.attr('placeholder'));
+
+ })
+ .on('focus', function() {
+
+ var i = $(this);
+
+ if (i.attr('name').match(/-polyfill-field$/))
+ return;
+
+ if (i.val() == i.attr('placeholder'))
+ i
+ .removeClass('polyfill-placeholder')
+ .val('');
+
+ });
+
+ // Password.
+ $this.find('input[type=password]')
+ .each(function() {
+
+ var i = $(this);
+ var x = $(
+ $('
')
+ .append(i.clone())
+ .remove()
+ .html()
+ .replace(/type="password"/i, 'type="text"')
+ .replace(/type=password/i, 'type=text')
+ );
+
+ if (i.attr('id') != '')
+ x.attr('id', i.attr('id') + '-polyfill-field');
+
+ if (i.attr('name') != '')
+ x.attr('name', i.attr('name') + '-polyfill-field');
+
+ x.addClass('polyfill-placeholder')
+ .val(x.attr('placeholder')).insertAfter(i);
+
+ if (i.val() == '')
+ i.hide();
+ else
+ x.hide();
+
+ i
+ .on('blur', function(event) {
+
+ event.preventDefault();
+
+ var x = i.parent().find('input[name=' + i.attr('name') + '-polyfill-field]');
+
+ if (i.val() == '') {
+
+ i.hide();
+ x.show();
+
+ }
+
+ });
+
+ x
+ .on('focus', function(event) {
+
+ event.preventDefault();
+
+ var i = x.parent().find('input[name=' + x.attr('name').replace('-polyfill-field', '') + ']');
+
+ x.hide();
+
+ i
+ .show()
+ .focus();
+
+ })
+ .on('keypress', function(event) {
+
+ event.preventDefault();
+ x.val('');
+
+ });
+
+ });
+
+ // Events.
+ $this
+ .on('submit', function() {
+
+ $this.find('input[type=text],input[type=password],textarea')
+ .each(function(event) {
+
+ var i = $(this);
+
+ if (i.attr('name').match(/-polyfill-field$/))
+ i.attr('name', '');
+
+ if (i.val() == i.attr('placeholder')) {
+
+ i.removeClass('polyfill-placeholder');
+ i.val('');
+
+ }
+
+ });
+
+ })
+ .on('reset', function(event) {
+
+ event.preventDefault();
+
+ $this.find('select')
+ .val($('option:first').val());
+
+ $this.find('input,textarea')
+ .each(function() {
+
+ var i = $(this),
+ x;
+
+ i.removeClass('polyfill-placeholder');
+
+ switch (this.type) {
+
+ case 'submit':
+ case 'reset':
+ break;
+
+ case 'password':
+ i.val(i.attr('defaultValue'));
+
+ x = i.parent().find('input[name=' + i.attr('name') + '-polyfill-field]');
+
+ if (i.val() == '') {
+ i.hide();
+ x.show();
+ }
+ else {
+ i.show();
+ x.hide();
+ }
+
+ break;
+
+ case 'checkbox':
+ case 'radio':
+ i.attr('checked', i.attr('defaultValue'));
+ break;
+
+ case 'text':
+ case 'textarea':
+ i.val(i.attr('defaultValue'));
+
+ if (i.val() == '') {
+ i.addClass('polyfill-placeholder');
+ i.val(i.attr('placeholder'));
+ }
+
+ break;
+
+ default:
+ i.val(i.attr('defaultValue'));
+ break;
+
+ }
+ });
+
+ });
+
+ return $this;
+
+ };
+
+ /**
+ * Moves elements to/from the first positions of their respective parents.
+ * @param {jQuery} $elements Elements (or selector) to move.
+ * @param {bool} condition If true, moves elements to the top. Otherwise, moves elements back to their original locations.
+ */
+ $.prioritize = function($elements, condition) {
+
+ var key = '__prioritize';
+
+ // Expand $elements if it's not already a jQuery object.
+ if (typeof $elements != 'jQuery')
+ $elements = $($elements);
+
+ // Step through elements.
+ $elements.each(function() {
+
+ var $e = $(this), $p,
+ $parent = $e.parent();
+
+ // No parent? Bail.
+ if ($parent.length == 0)
+ return;
+
+ // Not moved? Move it.
+ if (!$e.data(key)) {
+
+ // Condition is false? Bail.
+ if (!condition)
+ return;
+
+ // Get placeholder (which will serve as our point of reference for when this element needs to move back).
+ $p = $e.prev();
+
+ // Couldn't find anything? Means this element's already at the top, so bail.
+ if ($p.length == 0)
+ return;
+
+ // Move element to top of parent.
+ $e.prependTo($parent);
+
+ // Mark element as moved.
+ $e.data(key, $p);
+
+ }
+
+ // Moved already?
+ else {
+
+ // Condition is true? Bail.
+ if (condition)
+ return;
+
+ $p = $e.data(key);
+
+ // Move element back to its original location (using our placeholder).
+ $e.insertAfter($p);
+
+ // Unmark element as moved.
+ $e.removeData(key);
+
+ }
+
+ });
+
+ };
+
})(jQuery);
\ No newline at end of file
diff --git a/assets/sass/libs/_functions.scss b/assets/sass/libs/_functions.scss
index b367524..f563aab 100644
--- a/assets/sass/libs/_functions.scss
+++ b/assets/sass/libs/_functions.scss
@@ -1,90 +1,90 @@
-/// Removes a specific item from a list.
-/// @author Hugo Giraudel
-/// @param {list} $list List.
-/// @param {integer} $index Index.
-/// @return {list} Updated list.
-@function remove-nth($list, $index) {
-
- $result: null;
-
- @if type-of($index) != number {
- @warn "$index: #{quote($index)} is not a number for `remove-nth`.";
- }
- @else if $index == 0 {
- @warn "List index 0 must be a non-zero integer for `remove-nth`.";
- }
- @else if abs($index) > length($list) {
- @warn "List index is #{$index} but list is only #{length($list)} item long for `remove-nth`.";
- }
- @else {
-
- $result: ();
- $index: if($index < 0, length($list) + $index + 1, $index);
-
- @for $i from 1 through length($list) {
-
- @if $i != $index {
- $result: append($result, nth($list, $i));
- }
-
- }
-
- }
-
- @return $result;
-
-}
-
-/// Gets a value from a map.
-/// @author Hugo Giraudel
-/// @param {map} $map Map.
-/// @param {string} $keys Key(s).
-/// @return {string} Value.
-@function val($map, $keys...) {
-
- @if nth($keys, 1) == null {
- $keys: remove-nth($keys, 1);
- }
-
- @each $key in $keys {
- $map: map-get($map, $key);
- }
-
- @return $map;
-
-}
-
-/// Gets a duration value.
-/// @param {string} $keys Key(s).
-/// @return {string} Value.
-@function _duration($keys...) {
- @return val($duration, $keys...);
-}
-
-/// Gets a font value.
-/// @param {string} $keys Key(s).
-/// @return {string} Value.
-@function _font($keys...) {
- @return val($font, $keys...);
-}
-
-/// Gets a misc value.
-/// @param {string} $keys Key(s).
-/// @return {string} Value.
-@function _misc($keys...) {
- @return val($misc, $keys...);
-}
-
-/// Gets a palette value.
-/// @param {string} $keys Key(s).
-/// @return {string} Value.
-@function _palette($keys...) {
- @return val($palette, $keys...);
-}
-
-/// Gets a size value.
-/// @param {string} $keys Key(s).
-/// @return {string} Value.
-@function _size($keys...) {
- @return val($size, $keys...);
+/// Removes a specific item from a list.
+/// @author Hugo Giraudel
+/// @param {list} $list List.
+/// @param {integer} $index Index.
+/// @return {list} Updated list.
+@function remove-nth($list, $index) {
+
+ $result: null;
+
+ @if type-of($index) != number {
+ @warn "$index: #{quote($index)} is not a number for `remove-nth`.";
+ }
+ @else if $index == 0 {
+ @warn "List index 0 must be a non-zero integer for `remove-nth`.";
+ }
+ @else if abs($index) > length($list) {
+ @warn "List index is #{$index} but list is only #{length($list)} item long for `remove-nth`.";
+ }
+ @else {
+
+ $result: ();
+ $index: if($index < 0, length($list) + $index + 1, $index);
+
+ @for $i from 1 through length($list) {
+
+ @if $i != $index {
+ $result: append($result, nth($list, $i));
+ }
+
+ }
+
+ }
+
+ @return $result;
+
+}
+
+/// Gets a value from a map.
+/// @author Hugo Giraudel
+/// @param {map} $map Map.
+/// @param {string} $keys Key(s).
+/// @return {string} Value.
+@function val($map, $keys...) {
+
+ @if nth($keys, 1) == null {
+ $keys: remove-nth($keys, 1);
+ }
+
+ @each $key in $keys {
+ $map: map-get($map, $key);
+ }
+
+ @return $map;
+
+}
+
+/// Gets a duration value.
+/// @param {string} $keys Key(s).
+/// @return {string} Value.
+@function _duration($keys...) {
+ @return val($duration, $keys...);
+}
+
+/// Gets a font value.
+/// @param {string} $keys Key(s).
+/// @return {string} Value.
+@function _font($keys...) {
+ @return val($font, $keys...);
+}
+
+/// Gets a misc value.
+/// @param {string} $keys Key(s).
+/// @return {string} Value.
+@function _misc($keys...) {
+ @return val($misc, $keys...);
+}
+
+/// Gets a palette value.
+/// @param {string} $keys Key(s).
+/// @return {string} Value.
+@function _palette($keys...) {
+ @return val($palette, $keys...);
+}
+
+/// Gets a size value.
+/// @param {string} $keys Key(s).
+/// @return {string} Value.
+@function _size($keys...) {
+ @return val($size, $keys...);
}
\ No newline at end of file
diff --git a/assets/sass/libs/_html-grid.scss b/assets/sass/libs/_html-grid.scss
index 3c08069..7438a8c 100644
--- a/assets/sass/libs/_html-grid.scss
+++ b/assets/sass/libs/_html-grid.scss
@@ -1,149 +1,149 @@
-// html-grid.scss v1.0 | @ajlkn | MIT licensed */
-
-// Mixins.
-
- /// Initializes the current element as an HTML grid.
- /// @param {mixed} $gutters Gutters (either a single number to set both column/row gutters, or a list to set them individually).
- /// @param {mixed} $suffix Column class suffix (optional; either a single suffix or a list).
- @mixin html-grid($gutters: 1.5em, $suffix: '') {
-
- // Initialize.
- $cols: 12;
- $multipliers: 0, 0.25, 0.5, 1, 1.50, 2.00;
- $unit: 100% / $cols;
-
- // Suffixes.
- $suffixes: null;
-
- @if (type-of($suffix) == 'list') {
- $suffixes: $suffix;
- }
- @else {
- $suffixes: ($suffix);
- }
-
- // Gutters.
- $guttersCols: null;
- $guttersRows: null;
-
- @if (type-of($gutters) == 'list') {
-
- $guttersCols: nth($gutters, 1);
- $guttersRows: nth($gutters, 2);
-
- }
- @else {
-
- $guttersCols: $gutters;
- $guttersRows: 0;
-
- }
-
- // Row.
- display: flex;
- flex-wrap: wrap;
- box-sizing: border-box;
- align-items: stretch;
-
- // Columns.
- > * {
- box-sizing: border-box;
- }
-
- // Gutters.
- &.gtr-uniform {
- > * {
- > :last-child {
- margin-bottom: 0;
- }
- }
- }
-
- // Alignment.
- &.aln-left {
- justify-content: flex-start;
- }
-
- &.aln-center {
- justify-content: center;
- }
-
- &.aln-right {
- justify-content: flex-end;
- }
-
- &.aln-top {
- align-items: flex-start;
- }
-
- &.aln-middle {
- align-items: center;
- }
-
- &.aln-bottom {
- align-items: flex-end;
- }
-
- // Step through suffixes.
- @each $suffix in $suffixes {
-
- // Suffix.
- @if ($suffix != '') {
- $suffix: '-' + $suffix;
- }
- @else {
- $suffix: '';
- }
-
- // Row.
-
- // Important.
- > .imp#{$suffix} {
- order: -1;
- }
-
- // Columns, offsets.
- @for $i from 1 through $cols {
- > .col-#{$i}#{$suffix} {
- width: $unit * $i;
- }
-
- > .off-#{$i}#{$suffix} {
- margin-left: $unit * $i;
- }
- }
-
- // Step through multipliers.
- @each $multiplier in $multipliers {
-
- // Gutters.
- $class: null;
-
- @if ($multiplier != 1) {
- $class: '.gtr-' + ($multiplier * 100);
- }
-
- {$class} {
- margin-top: ($guttersRows * $multiplier * -1);
- margin-left: ($guttersCols * $multiplier * -1);
-
- > * {
- padding: ($guttersRows * $multiplier) 0 0 ($guttersCols * $multiplier);
- }
-
- // Uniform.
- &.gtr-uniform {
- margin-top: $guttersCols * $multiplier * -1;
-
- > * {
- padding-top: $guttersCols * $multiplier;
- }
- }
-
- }
-
- }
-
- }
-
+// html-grid.scss v1.0 | @ajlkn | MIT licensed */
+
+// Mixins.
+
+ /// Initializes the current element as an HTML grid.
+ /// @param {mixed} $gutters Gutters (either a single number to set both column/row gutters, or a list to set them individually).
+ /// @param {mixed} $suffix Column class suffix (optional; either a single suffix or a list).
+ @mixin html-grid($gutters: 1.5em, $suffix: '') {
+
+ // Initialize.
+ $cols: 12;
+ $multipliers: 0, 0.25, 0.5, 1, 1.50, 2.00;
+ $unit: 100% / $cols;
+
+ // Suffixes.
+ $suffixes: null;
+
+ @if (type-of($suffix) == 'list') {
+ $suffixes: $suffix;
+ }
+ @else {
+ $suffixes: ($suffix);
+ }
+
+ // Gutters.
+ $guttersCols: null;
+ $guttersRows: null;
+
+ @if (type-of($gutters) == 'list') {
+
+ $guttersCols: nth($gutters, 1);
+ $guttersRows: nth($gutters, 2);
+
+ }
+ @else {
+
+ $guttersCols: $gutters;
+ $guttersRows: 0;
+
+ }
+
+ // Row.
+ display: flex;
+ flex-wrap: wrap;
+ box-sizing: border-box;
+ align-items: stretch;
+
+ // Columns.
+ > * {
+ box-sizing: border-box;
+ }
+
+ // Gutters.
+ &.gtr-uniform {
+ > * {
+ > :last-child {
+ margin-bottom: 0;
+ }
+ }
+ }
+
+ // Alignment.
+ &.aln-left {
+ justify-content: flex-start;
+ }
+
+ &.aln-center {
+ justify-content: center;
+ }
+
+ &.aln-right {
+ justify-content: flex-end;
+ }
+
+ &.aln-top {
+ align-items: flex-start;
+ }
+
+ &.aln-middle {
+ align-items: center;
+ }
+
+ &.aln-bottom {
+ align-items: flex-end;
+ }
+
+ // Step through suffixes.
+ @each $suffix in $suffixes {
+
+ // Suffix.
+ @if ($suffix != '') {
+ $suffix: '-' + $suffix;
+ }
+ @else {
+ $suffix: '';
+ }
+
+ // Row.
+
+ // Important.
+ > .imp#{$suffix} {
+ order: -1;
+ }
+
+ // Columns, offsets.
+ @for $i from 1 through $cols {
+ > .col-#{$i}#{$suffix} {
+ width: $unit * $i;
+ }
+
+ > .off-#{$i}#{$suffix} {
+ margin-left: $unit * $i;
+ }
+ }
+
+ // Step through multipliers.
+ @each $multiplier in $multipliers {
+
+ // Gutters.
+ $class: null;
+
+ @if ($multiplier != 1) {
+ $class: '.gtr-' + ($multiplier * 100);
+ }
+
+ {$class} {
+ margin-top: ($guttersRows * $multiplier * -1);
+ margin-left: ($guttersCols * $multiplier * -1);
+
+ > * {
+ padding: ($guttersRows * $multiplier) 0 0 ($guttersCols * $multiplier);
+ }
+
+ // Uniform.
+ &.gtr-uniform {
+ margin-top: $guttersCols * $multiplier * -1;
+
+ > * {
+ padding-top: $guttersCols * $multiplier;
+ }
+ }
+
+ }
+
+ }
+
+ }
+
}
\ No newline at end of file
diff --git a/assets/sass/libs/_mixins.scss b/assets/sass/libs/_mixins.scss
index 8187463..a331483 100644
--- a/assets/sass/libs/_mixins.scss
+++ b/assets/sass/libs/_mixins.scss
@@ -1,78 +1,78 @@
-/// Makes an element's :before pseudoelement a FontAwesome icon.
-/// @param {string} $content Optional content value to use.
-/// @param {string} $category Optional category to use.
-/// @param {string} $where Optional pseudoelement to target (before or after).
-@mixin icon($content: false, $category: regular, $where: before) {
-
- text-decoration: none;
-
- &:#{$where} {
-
- @if $content {
- content: $content;
- }
-
- -moz-osx-font-smoothing: grayscale;
- -webkit-font-smoothing: antialiased;
- display: inline-block;
- font-style: normal;
- font-variant: normal;
- text-rendering: auto;
- line-height: 1;
- text-transform: none !important;
-
- @if ($category == brands) {
- font-family: 'Font Awesome 5 Brands';
- }
- @elseif ($category == solid) {
- font-family: 'Font Awesome 5 Free';
- font-weight: 900;
- }
- @else {
- font-family: 'Font Awesome 5 Free';
- font-weight: 400;
- }
-
- }
-
-}
-
-/// Applies padding to an element, taking the current element-margin value into account.
-/// @param {mixed} $tb Top/bottom padding.
-/// @param {mixed} $lr Left/right padding.
-/// @param {list} $pad Optional extra padding (in the following order top, right, bottom, left)
-/// @param {bool} $important If true, adds !important.
-@mixin padding($tb, $lr, $pad: (0,0,0,0), $important: null) {
-
- @if $important {
- $important: '!important';
- }
-
- $x: 0.1em;
-
- @if unit(_size(element-margin)) == 'rem' {
- $x: 0.1rem;
- }
-
- padding: ($tb + nth($pad,1)) ($lr + nth($pad,2)) max($x, $tb - _size(element-margin) + nth($pad,3)) ($lr + nth($pad,4)) #{$important};
-
-}
-
-/// Encodes a SVG data URL so IE doesn't choke (via codepen.io/jakob-e/pen/YXXBrp).
-/// @param {string} $svg SVG data URL.
-/// @return {string} Encoded SVG data URL.
-@function svg-url($svg) {
-
- $svg: str-replace($svg, '"', '\'');
- $svg: str-replace($svg, '%', '%25');
- $svg: str-replace($svg, '<', '%3C');
- $svg: str-replace($svg, '>', '%3E');
- $svg: str-replace($svg, '&', '%26');
- $svg: str-replace($svg, '#', '%23');
- $svg: str-replace($svg, '{', '%7B');
- $svg: str-replace($svg, '}', '%7D');
- $svg: str-replace($svg, ';', '%3B');
-
- @return url("data:image/svg+xml;charset=utf8,#{$svg}");
-
+/// Makes an element's :before pseudoelement a FontAwesome icon.
+/// @param {string} $content Optional content value to use.
+/// @param {string} $category Optional category to use.
+/// @param {string} $where Optional pseudoelement to target (before or after).
+@mixin icon($content: false, $category: regular, $where: before) {
+
+ text-decoration: none;
+
+ &:#{$where} {
+
+ @if $content {
+ content: $content;
+ }
+
+ -moz-osx-font-smoothing: grayscale;
+ -webkit-font-smoothing: antialiased;
+ display: inline-block;
+ font-style: normal;
+ font-variant: normal;
+ text-rendering: auto;
+ line-height: 1;
+ text-transform: none !important;
+
+ @if ($category == brands) {
+ font-family: 'Font Awesome 5 Brands';
+ }
+ @elseif ($category == solid) {
+ font-family: 'Font Awesome 5 Free';
+ font-weight: 900;
+ }
+ @else {
+ font-family: 'Font Awesome 5 Free';
+ font-weight: 400;
+ }
+
+ }
+
+}
+
+/// Applies padding to an element, taking the current element-margin value into account.
+/// @param {mixed} $tb Top/bottom padding.
+/// @param {mixed} $lr Left/right padding.
+/// @param {list} $pad Optional extra padding (in the following order top, right, bottom, left)
+/// @param {bool} $important If true, adds !important.
+@mixin padding($tb, $lr, $pad: (0,0,0,0), $important: null) {
+
+ @if $important {
+ $important: '!important';
+ }
+
+ $x: 0.1em;
+
+ @if unit(_size(element-margin)) == 'rem' {
+ $x: 0.1rem;
+ }
+
+ padding: ($tb + nth($pad,1)) ($lr + nth($pad,2)) max($x, $tb - _size(element-margin) + nth($pad,3)) ($lr + nth($pad,4)) #{$important};
+
+}
+
+/// Encodes a SVG data URL so IE doesn't choke (via codepen.io/jakob-e/pen/YXXBrp).
+/// @param {string} $svg SVG data URL.
+/// @return {string} Encoded SVG data URL.
+@function svg-url($svg) {
+
+ $svg: str-replace($svg, '"', '\'');
+ $svg: str-replace($svg, '%', '%25');
+ $svg: str-replace($svg, '<', '%3C');
+ $svg: str-replace($svg, '>', '%3E');
+ $svg: str-replace($svg, '&', '%26');
+ $svg: str-replace($svg, '#', '%23');
+ $svg: str-replace($svg, '{', '%7B');
+ $svg: str-replace($svg, '}', '%7D');
+ $svg: str-replace($svg, ';', '%3B');
+
+ @return url("data:image/svg+xml;charset=utf8,#{$svg}");
+
}
\ No newline at end of file
diff --git a/assets/sass/libs/_vars.scss b/assets/sass/libs/_vars.scss
index 55d6382..5c2d8e6 100644
--- a/assets/sass/libs/_vars.scss
+++ b/assets/sass/libs/_vars.scss
@@ -1,64 +1,64 @@
-// Misc.
- $misc: (
- z-index-base: 10000,
- header-side: 'right'
- );
-
-// Duration.
- $duration: (
- header: 0.5s,
- transition: 0.2s
- );
-
-// Size.
- $size: (
- border-radius: 5px,
- border-width: 2px,
- element-height: 2.75em,
- element-margin: 2.25em,
- container-width: 45em
- );
-
-// Font.
- $font: (
- family: ('Lato', sans-serif),
- family-fixed: ('Source Code Pro', monospace),
- weight: 400,
- weight-bold: 700
- );
-
-// Palette.
- $palette: (
- bg: #fff,
- fg: #888,
- fg-bold: #777,
- fg-light: #aaa,
- border: #f4f4f4,
- border-bg: #fafafa,
- border2: #e4e4e4,
- border2-bg: #f4f4f4,
- border3: #e0e0e0,
- border3-bg: #eaeaea,
-
- accent1: (
- bg: #4acaa8,
- fg-bold: #ffffff,
- fg: mix(#4acaa8, #ffffff, 25%),
- fg-light: mix(#4acaa8, #ffffff, 40%)
- ),
-
- accent2: (
- bg: #989898,
- fg-bold: #ffffff,
- fg: mix(#989898, #ffffff, 25%),
- fg-light: mix(#989898, #ffffff, 40%)
- ),
-
- header: (
- bg: #4acaa8,
- fg-bold: #ffffff,
- fg: mix(#4acaa8, #ffffff, 25%),
- fg-light: mix(#4acaa8, #ffffff, 40%),
- border: mix(#4acaa8, #ffffff, 90%)
- )
+// Misc.
+ $misc: (
+ z-index-base: 10000,
+ header-side: 'right'
+ );
+
+// Duration.
+ $duration: (
+ header: 0.5s,
+ transition: 0.2s
+ );
+
+// Size.
+ $size: (
+ border-radius: 5px,
+ border-width: 2px,
+ element-height: 2.75em,
+ element-margin: 2.25em,
+ container-width: 45em
+ );
+
+// Font.
+ $font: (
+ family: ('Lato', sans-serif),
+ family-fixed: ('Source Code Pro', monospace),
+ weight: 400,
+ weight-bold: 700
+ );
+
+// Palette.
+ $palette: (
+ bg: #fff,
+ fg: #888,
+ fg-bold: #777,
+ fg-light: #aaa,
+ border: #f4f4f4,
+ border-bg: #fafafa,
+ border2: #e4e4e4,
+ border2-bg: #f4f4f4,
+ border3: #e0e0e0,
+ border3-bg: #eaeaea,
+
+ accent1: (
+ bg: #4acaa8,
+ fg-bold: #ffffff,
+ fg: mix(#4acaa8, #ffffff, 25%),
+ fg-light: mix(#4acaa8, #ffffff, 40%)
+ ),
+
+ accent2: (
+ bg: #989898,
+ fg-bold: #ffffff,
+ fg: mix(#989898, #ffffff, 25%),
+ fg-light: mix(#989898, #ffffff, 40%)
+ ),
+
+ header: (
+ bg: #4acaa8,
+ fg-bold: #ffffff,
+ fg: mix(#4acaa8, #ffffff, 25%),
+ fg-light: mix(#4acaa8, #ffffff, 40%),
+ border: mix(#4acaa8, #ffffff, 90%)
+ )
);
\ No newline at end of file
diff --git a/index.html b/index.html
index 8701ac6..2027e0d 100644
--- a/index.html
+++ b/index.html
@@ -1,442 +1,442 @@
-
-
-
-
-
-
-
Adrien CHARBONNEAU – Naturaliste écologue
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Adrien CHARBONNEAU
- 24 ans
- 69100 - Villeurbanne, Rhône - France
-
-
Cette page est, comme vous l'aurez compris, complémentaire à mon Curriculum Vitae (que vous pourrez retrouver ci-dessous ).
- Elle vous présente divers liens et informations utiles à ma présentation. Vous retrouverez notamment la liste de mes compétences professionnelles .
-
Que fais-je en ce moment ? Pour le savoir rendez-vous ici : - ACTUALITÉ -
- N’hésitez pas à me contacter, que ce soit pour une question, une compétence ou une demande de précision sur une expérience professionnelle, en utilisant mon adresse courriel ci-dessous :
-
-
– CURRICULUM VITAE –
-
-
-
-
-
-
-
-
-
-
-
Chevêche d'Athéna
-
Athene noctua
-
-
-
-
-
-
-
-
-
Bruant des roseaux
-
Emberiza schoeniclus
-
-
-
-
-
-
-
-
-
Mésange bleue
-
Cyanistes caeruleus
-
-
-
-
-
-
-
-
-
Mésange charbonnière
-
Parus major
-
-
-
-
-
-
-
-
-
Pochons
-
Sac en tissu pour le transport des oiseaux
-
-
-
-
-
-
-
-
-
Accenteur mouchet
-
Prunella modularis
-
-
-
-
-
-
-
-
-
Travée de baguage
-
Zone ouverte où les filets de capture sont tendus
-
-
-
-
-
-
-
-
-
Pouillot véloce
-
Phylloscopus collybita
-
-
-
-
-
-
-
-
-
Publications
-
Mes différentes publications et écrits scientifiques majeurs qui ont jalonnés mon Master en Biodiversité, Écologie et Évolution.
-
-
-
-
-
Compétition entre deux espèces de Geckos sur l’île de Porquerolles (2019-2020 )
-
(Bientôt disponible ) - La Tarente de Maurétanie (Tarentola mauritanica ) est, sur l'île de Porquerolles (83), une espèce importée par l'homme. Le Gecko indigène de l'île et occupant la même niche écologique que cette dernière est l'Hémidactyle verruqueux (Hemidactylus turcicus ). Il est supposé qu'une compétition réside entre les deux espèces.
-
-
-
-
-
-
Caractérisation du territoire de reproduction de la Pie-grièche méridionale (2019 )
-
La superficie du territoire de reproduction de la Pie-grièche méridionale (Lanius meridionalis ) étant très peu connu, cette étude souhaite apporter des précisions quant à cela.
-
-
-
-
-
-
Étude du lien entre communautés d’Orthoptères et hauteur de végétation par différentes méthodes d’échantillonnage dans la vallée de l’Ubaye (2018-2019 )
-
Sujet de l'école de terrain 2018. Dans le Parc National du Mercantour, la hauteur de végétation a-t-elle une importance dans la répartition des communautés d'Orthoptères ?
-
-
-
-
-
-
-
-
-
-
-
Supports de stage
-
De nombreuses données et annexes sont disponible durant un stage. Elles sont regroupées par stage :
-
-
-
-
-
Support de stage de Master 2 : Impact de la lumière artificielle et de la structure du paysage sur la biodiversité en période nocturne (2020 )
-
Il est admis que la lumière artificielle a des effets néfastes sur la biodiversité. Qu'en est-il en addition à la structure paysagère et au sein du Parc Naturel Régional des Baronnies provençales ?
-
-
-
-
-
-
Support de stage de Master 1 : Caractérisation du territoire de reproduction de la Pie-grièche méridionale (2019 )
-
Dans un but de mesures de gestion de la garrigue et de précision du protocole d'échantillonnage du Plan National d'Actions sur les Pie-grièches (ici la Pie-grièche méridionale), la surface du territoire de reproduction de l'espèce est une information clé.
-
-
-
-
-
-
-
-
-
-
Compétences
-
Mes compétences sont présentées dans la liste ci-dessous, vous y trouverez les références du matériel et des ressources technologiques (ex : logiciel ) que je maîtrise. N’hésitez pas, comme précisé précédemment, à me questionner (ou demander un avis ) sur une compétence, méthode ou matériel utilisé, j’y répondrai avec plaisir.
- Dans les parties concernant le matériel, un astérisque (* ) signifie que je possède le matériel cité. Pour les identifications acoustiques, le matériel est cité dans la section “acoustique”.
-
-
-
-
- Compétences naturalistes
- Suivi ornithologique et entomologique (odonates) dans la Tarentaise (73)
-
-
- OrnithologieIdentification visuelle, en main (formation de baguage ) et acoustique.
- Entomologie(Lépidoptères, Odonates, Orthoptères ) - Identification visuelle, en main (capture au filet, prospection au "drap" nocturne ) et acoustique.
- Mammalogie(Chiroptères, Macro/Méso/Micro-mammifères ) - Identification visuelle et auditive - Télémétrie / Analyse de pelote de réjection.
- HerpétologieIdentification visuelle, en main (plaque à reptiles, "seau" à amphibiens ) et acoustique.
- Botanique généralisteIdentification des familles et utilisation des flores (Flora Gallica / Flore Méd' / Flores forestières... ) - Détermination des habitats - Loupe de botanique, mise en herbier et photographie.
-
-
-
-
- Compétences en méthodologie et en démarche scientifique
- Radiopistage de Pie-grièche méridionale (Lanius meridionalis) dans les Garrigues de Lançon (13)
-
-
- Bases théoriques de l'écologie
-
- Évolution
- Conservation
- Gestion de la biodiversité
- Bio/Éco-acoustique
- Paysage
-
-
- Mise en place de protocole / étude pilote
- Application de protocole/stratégie d'échantillonnage
- Analyse de données(voir Modélisation et Cartographie ci-dessous)
- Rédaction de rapports d'étude/articles scientifiquesIntroduction, Matériel et Méthode, Résultats, Discussion/Conclusion
- Rédaction de rapports d'inventaires/prédiagnostics/Volet Naturel d'Étude d'Impact
-
-
-
-
-
- Compétences en analyses statistiques et en modélisation
- Représentation de l’abondance en orthoptères dans le massif du Mercantour (04) en fonction de la hauteur de végétation
-
-
-
-
- Compétences en analyses spatiales et en cartographie
- Tirage aléatoire de positions sur le territoire de la France métropolitaine
-
-
-
-
- Compétences acoustiques et audionaturalistes
- AudioMoth durant le stage de M2
-
-
-
- Sonogramme partiel d’un Coucou geai (Clamator glandarius ) en migration nocturne – © Adrien CHARBONNEAU
-
-
-
-
- Les autres compétences et intérêts
- Lac du Lauzanier - Mercantour (04)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
Adrien CHARBONNEAU – Naturaliste écologue
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Adrien CHARBONNEAU
+ 24 ans
+ 69100 - Villeurbanne, Rhône - France
+
+
Cette page est, comme vous l'aurez compris, complémentaire à mon Curriculum Vitae (que vous pourrez retrouver ci-dessous ).
+ Elle vous présente divers liens et informations utiles à ma présentation. Vous retrouverez notamment la liste de mes compétences professionnelles .
+
Que fais-je en ce moment ? Pour le savoir rendez-vous ici : - ACTUALITÉ -
+ N’hésitez pas à me contacter, que ce soit pour une question, une compétence ou une demande de précision sur une expérience professionnelle, en utilisant mon adresse courriel ci-dessous :
+
+
– CURRICULUM VITAE –
+
+
+
+
+
+
+
+
+
+
+
Chevêche d'Athéna
+
Athene noctua
+
+
+
+
+
+
+
+
+
Bruant des roseaux
+
Emberiza schoeniclus
+
+
+
+
+
+
+
+
+
Mésange bleue
+
Cyanistes caeruleus
+
+
+
+
+
+
+
+
+
Mésange charbonnière
+
Parus major
+
+
+
+
+
+
+
+
+
Pochons
+
Sac en tissu pour le transport des oiseaux
+
+
+
+
+
+
+
+
+
Accenteur mouchet
+
Prunella modularis
+
+
+
+
+
+
+
+
+
Travée de baguage
+
Zone ouverte où les filets de capture sont tendus
+
+
+
+
+
+
+
+
+
Pouillot véloce
+
Phylloscopus collybita
+
+
+
+
+
+
+
+
+
Publications
+
Mes différentes publications et écrits scientifiques majeurs qui ont jalonnés mon Master en Biodiversité, Écologie et Évolution.
+
+
+
+
+
Compétition entre deux espèces de Geckos sur l’île de Porquerolles (2019-2020 )
+
(Bientôt disponible ) - La Tarente de Maurétanie (Tarentola mauritanica ) est, sur l'île de Porquerolles (83), une espèce importée par l'homme. Le Gecko indigène de l'île et occupant la même niche écologique que cette dernière est l'Hémidactyle verruqueux (Hemidactylus turcicus ). Il est supposé qu'une compétition réside entre les deux espèces.
+
+
+
+
+
+
Caractérisation du territoire de reproduction de la Pie-grièche méridionale (2019 )
+
La superficie du territoire de reproduction de la Pie-grièche méridionale (Lanius meridionalis ) étant très peu connu, cette étude souhaite apporter des précisions quant à cela.
+
+
+
+
+
+
Étude du lien entre communautés d’Orthoptères et hauteur de végétation par différentes méthodes d’échantillonnage dans la vallée de l’Ubaye (2018-2019 )
+
Sujet de l'école de terrain 2018. Dans le Parc National du Mercantour, la hauteur de végétation a-t-elle une importance dans la répartition des communautés d'Orthoptères ?
+
+
+
+
+
+
+
+
+
+
+
Supports de stage
+
De nombreuses données et annexes sont disponible durant un stage. Elles sont regroupées par stage :
+
+
+
+
+
Support de stage de Master 2 : Impact de la lumière artificielle et de la structure du paysage sur la biodiversité en période nocturne (2020 )
+
Il est admis que la lumière artificielle a des effets néfastes sur la biodiversité. Qu'en est-il en addition à la structure paysagère et au sein du Parc Naturel Régional des Baronnies provençales ?
+
+
+
+
+
+
Support de stage de Master 1 : Caractérisation du territoire de reproduction de la Pie-grièche méridionale (2019 )
+
Dans un but de mesures de gestion de la garrigue et de précision du protocole d'échantillonnage du Plan National d'Actions sur les Pie-grièches (ici la Pie-grièche méridionale), la surface du territoire de reproduction de l'espèce est une information clé.
+
+
+
+
+
+
+
+
+
+
Compétences
+
Mes compétences sont présentées dans la liste ci-dessous, vous y trouverez les références du matériel et des ressources technologiques (ex : logiciel ) que je maîtrise. N’hésitez pas, comme précisé précédemment, à me questionner (ou demander un avis ) sur une compétence, méthode ou matériel utilisé, j’y répondrai avec plaisir.
+ Dans les parties concernant le matériel, un astérisque (* ) signifie que je possède le matériel cité. Pour les identifications acoustiques, le matériel est cité dans la section “acoustique”.
+
+
+
+
+ Compétences naturalistes
+ Suivi ornithologique et entomologique (odonates) dans la Tarentaise (73)
+
+
+ OrnithologieIdentification visuelle, en main (formation de baguage ) et acoustique.
+ Entomologie(Lépidoptères, Odonates, Orthoptères ) - Identification visuelle, en main (capture au filet, prospection au "drap" nocturne ) et acoustique.
+ Mammalogie(Chiroptères, Macro/Méso/Micro-mammifères ) - Identification visuelle et auditive - Télémétrie / Analyse de pelote de réjection.
+ HerpétologieIdentification visuelle, en main (plaque à reptiles, "seau" à amphibiens ) et acoustique.
+ Botanique généralisteIdentification des familles et utilisation des flores (Flora Gallica / Flore Méd' / Flores forestières... ) - Détermination des habitats - Loupe de botanique, mise en herbier et photographie.
+
+
+
+
+ Compétences en méthodologie et en démarche scientifique
+ Radiopistage de Pie-grièche méridionale (Lanius meridionalis) dans les Garrigues de Lançon (13)
+
+
+ Bases théoriques de l'écologie
+
+ Évolution
+ Conservation
+ Gestion de la biodiversité
+ Bio/Éco-acoustique
+ Paysage
+
+
+ Mise en place de protocole / étude pilote
+ Application de protocole/stratégie d'échantillonnage
+ Analyse de données(voir Modélisation et Cartographie ci-dessous)
+ Rédaction de rapports d'étude/articles scientifiquesIntroduction, Matériel et Méthode, Résultats, Discussion/Conclusion
+ Rédaction de rapports d'inventaires/prédiagnostics/Volet Naturel d'Étude d'Impact
+
+
+
+
+
+ Compétences en analyses statistiques et en modélisation
+ Représentation de l’abondance en orthoptères dans le massif du Mercantour (04) en fonction de la hauteur de végétation
+
+
+
+
+ Compétences en analyses spatiales et en cartographie
+ Tirage aléatoire de positions sur le territoire de la France métropolitaine
+
+
+
+
+ Compétences acoustiques et audionaturalistes
+ AudioMoth durant le stage de M2
+
+
+
+ Sonogramme partiel d’un Coucou geai (Clamator glandarius ) en migration nocturne – © Adrien CHARBONNEAU
+
+
+
+
+ Les autres compétences et intérêts
+ Lac du Lauzanier - Mercantour (04)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/sitemap.xml b/sitemap.xml
index 5ea0dc0..f0b72f9 100644
--- a/sitemap.xml
+++ b/sitemap.xml
@@ -1,23 +1,23 @@
-
-
-
-
- https://adriencharbonneau.fr/
-
-
- https://adriencharbonneau.fr/docs/CV_Adrien_CHARBONNEAU.pdf
-
-
- https://adriencharbonneau.fr/ACTUALITE.html
-
-
- https://adriencharbonneau.fr/docs/PGM.pdf
-
-
- https://adriencharbonneau.fr/docs/ORTHOPTERES.pdf
-
+
+
+
+
+ https://adriencharbonneau.fr/
+
+
+ https://adriencharbonneau.fr/docs/CV_Adrien_CHARBONNEAU.pdf
+
+
+ https://adriencharbonneau.fr/ACTUALITE.html
+
+
+ https://adriencharbonneau.fr/docs/PGM.pdf
+
+
+ https://adriencharbonneau.fr/docs/ORTHOPTERES.pdf
+
\ No newline at end of file