/******/ (function(modules) { // webpackBootstrap /******/ // The module cache /******/ var installedModules = {}; /******/ /******/ // The require function /******/ function webpack_require(moduleId) { /******/ /******/ // Check if module is in cache /******/ if(installedModules) { /******/ return installedModules.exports; /******/ } /******/ // Create a new module (and put it into the cache) /******/ var module = installedModules = { /******/ i: moduleId, /******/ l: false, /******/ exports: {} /******/ }; /******/ /******/ // Execute the module function /******/ modules.call(module.exports, module, module.exports, webpack_require); /******/ /******/ // Flag the module as loaded /******/ module.l = true; /******/ /******/ // Return the exports of the module /******/ return module.exports; /******/ } /******/ /******/ /******/ // expose the modules object (webpack_modules) /******/ webpack_require.m = modules; /******/ /******/ // expose the module cache /******/ webpack_require.c = installedModules; /******/ /******/ // define getter function for harmony exports /******/ webpack_require.d = function(exports, name, getter) { /******/ if(!webpack_require.o(exports, name)) { /******/ Object.defineProperty(exports, name, { /******/ configurable: false, /******/ enumerable: true, /******/ get: getter /******/ }); /******/ } /******/ }; /******/ /******/ // getDefaultExport function for compatibility with non-harmony modules /******/ webpack_require.n = function(module) { /******/ var getter = module && module.__esModule ? /******/ function getDefault() { return module; } : /******/ function getModuleExports() { return module; }; /******/ webpack_require.d(getter, 'a', getter); /******/ return getter; /******/ }; /******/ /******/ // Object.prototype.hasOwnProperty.call /******/ webpack_require.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; /******/ /******/ // webpack_public_path /******/ webpack_require.p = “”; /******/ /******/ // Load entry module and return exports /******/ return webpack_require(_webpack_require_.s = 0); /******/ }) /************************************************************************/ /******/ ([ /* 0 */ /***/ (function(module, webpack_exports, webpack_require) {

“use strict”; Object.defineProperty(webpack_exports, “__esModule”, { value: true }); /* harmony import */ var WEBPACK_IMPORTED_MODULE_0_jump_js = webpack_require(1); /* harmony import */ var WEBPACK_IMPORTED_MODULE_1_ez_js = webpack_require(2); /* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_ez_js___default = webpack_require.n(WEBPACK_IMPORTED_MODULE_1_ez_js); /* global document */

// import easeInOutQuad from './easing';

// for (const key of Object.keys(ez)) { // console.log(“key”, key); // console.log(ez(100, 0, 10, 1000)); // } const ready = webpack_require(3); ready(() => {

// console.log('DOM is ready');
// We get all h2 elements
const list = document.getElementsByClassName('jump-link');
// Get the menu ul
const menuList = document.getElementById('menu-list');
if (list.length > 0) {
  for (let i = 0; i < list.length; i++) {
    const element = list.item(i); // Isolate
    let target = element.getAttribute('href');
    // console.log(target);
    element.addEventListener('click', e => {
      e.preventDefault();
      Object(__WEBPACK_IMPORTED_MODULE_0_jump_js__["a" /* default */])(target, {
        duration: 1500,
        callback: () => {
          // console.log('did the jump!');
        },
        easing: __WEBPACK_IMPORTED_MODULE_1_ez_js___default.a,
        a11y: false
      });
    }, false);
  }
}

});

/***/ }), /* 1 */ /***/ (function(module, webpack_exports, webpack_require) {

“use strict”; // Robert Penner's easeInOutQuad

// find the rest of his easing functions here: robertpenner.com/easing/ // find them exported for ES6 consumption here: github.com/jaxgeller/ez.js

var easeInOutQuad = function easeInOutQuad(t, b, c, d) {

t /= d / 2;
if (t < 1) return c / 2 * t * t + b;
t--;
return -c / 2 * (t * (t - 2) - 1) + b;

};

var _typeof = typeof Symbol === “function” && typeof Symbol.iterator === “symbol” ? function (obj) {

return typeof obj;

} : function (obj) {

return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;

};

var jumper = function jumper() {

// private variable cache
// no variables are created during a jump, preventing memory leaks

var element = void 0; // element to scroll to                   (node)

var start = void 0; // where scroll starts                    (px)
var stop = void 0; // where scroll stops                     (px)

var offset = void 0; // adjustment from the stop position      (px)
var easing = void 0; // easing function                        (function)
var a11y = void 0; // accessibility support flag             (boolean)

var distance = void 0; // distance of scroll                     (px)
var duration = void 0; // scroll duration                        (ms)

var timeStart = void 0; // time scroll started                    (ms)
var timeElapsed = void 0; // time spent scrolling thus far          (ms)

var next = void 0; // next scroll position                   (px)

var callback = void 0; // to call when done scrolling            (function)

// scroll position helper

function location() {
  return window.scrollY || window.pageYOffset;
}

// element offset helper

function top(element) {
  return element.getBoundingClientRect().top + start;
}

// rAF loop helper

function loop(timeCurrent) {
  // store time scroll started, if not started already
  if (!timeStart) {
    timeStart = timeCurrent;
  }

  // determine time spent scrolling so far
  timeElapsed = timeCurrent - timeStart;

  // calculate next scroll position
  next = easing(timeElapsed, start, distance, duration);

  // scroll to it
  window.scrollTo(0, next);

  // check progress
  timeElapsed < duration ? window.requestAnimationFrame(loop) // continue scroll loop
  : done(); // scrolling is done
}

// scroll finished helper

function done() {
  // account for rAF time rounding inaccuracies
  window.scrollTo(0, start + distance);

  // if scrolling to an element, and accessibility is enabled
  if (element && a11y) {
    // add tabindex indicating programmatic focus
    element.setAttribute('tabindex', '-1');

    // focus the element
    element.focus();
  }

  // if it exists, fire the callback
  if (typeof callback === 'function') {
    callback();
  }

  // reset time for next jump
  timeStart = false;
}

// API

function jump(target) {
  var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};

  // resolve options, or use defaults
  duration = options.duration || 1000;
  offset = options.offset || 0;
  callback = options.callback; // "undefined" is a suitable default, and won't be called
  easing = options.easing || easeInOutQuad;
  a11y = options.a11y || false;

  // cache starting position
  start = location();

  // resolve target
  switch (typeof target === 'undefined' ? 'undefined' : _typeof(target)) {
    // scroll from current position
    case 'number':
      element = undefined; // no element to scroll to
      a11y = false; // make sure accessibility is off
      stop = start + target;
      break;

    // scroll to element (node)
    // bounding rect is relative to the viewport
    case 'object':
      element = target;
      stop = top(element);
      break;

    // scroll to element (selector)
    // bounding rect is relative to the viewport
    case 'string':
      element = document.querySelector(target);
      stop = top(element);
      break;
  }

  // resolve scroll distance, accounting for offset
  distance = stop - start + offset;

  // resolve duration
  switch (_typeof(options.duration)) {
    // number in ms
    case 'number':
      duration = options.duration;
      break;

    // function passed the distance of the scroll
    case 'function':
      duration = options.duration(distance);
      break;
  }

  // start the loop
  window.requestAnimationFrame(loop);
}

// expose only the jump method
return jump;

};

// export singleton

var singleton = jumper();

/* harmony default export */ webpack_exports[“a”] = (singleton);

/***/ }), /* 2 */ /***/ (function(module, exports, webpack_require) {

var require;var require;(function(f){if(true){module.exports=f()}else if(typeof define===“function”&&define.amd){define([],f)}else{var g;if(typeof window!==“undefined”){g=window}else if(typeof global!==“undefined”){g=global}else if(typeof self!==“undefined”){g=self}else{g=this}g.Ez = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n){if(!t){var a=typeof require==“function”&&require;if(!u&&a)return require(o,!0);if(i)return i(o,!0);var f=new Error(“Cannot find module '”o“'”);throw f.code=“MODULE_NOT_FOUND”,f}var l=n={exports:{}};t[0].call(l.exports,function(e){var n=t[1];return s(n?n:e)},l,l.exports,e,t,n,r)}return n.exports}var i=typeof require==“function”&&require;for(var o=0;o);return s})({1:[function(require,module,exports){ “use strict”;

Object.defineProperty(exports, “__esModule”, {

value: true

}); exports.easeInQuad = easeInQuad; exports.easeOutQuad = easeOutQuad; exports.easeInOutQuad = easeInOutQuad; exports.easeInCubic = easeInCubic; exports.easeOutCubic = easeOutCubic; exports.easeInOutCubic = easeInOutCubic; exports.easeInQuart = easeInQuart; exports.easeOutQuart = easeOutQuart; exports.easeInOutQuart = easeInOutQuart; exports.easeInQuint = easeInQuint; exports.easeOutQuint = easeOutQuint; exports.easeInOutQuint = easeInOutQuint; exports.easeInSine = easeInSine; exports.easeOutSine = easeOutSine; exports.easeInOutSine = easeInOutSine; exports.easeInExpo = easeInExpo; exports.easeOutExpo = easeOutExpo; exports.easeInOutExpo = easeInOutExpo; exports.easeInCirc = easeInCirc; exports.easeOutCirc = easeOutCirc; exports.easeInOutCirc = easeInOutCirc; exports.easeInElastic = easeInElastic; exports.easeOutElastic = easeOutElastic; exports.easeInOutElastic = easeInOutElastic; exports.easeInBack = easeInBack; exports.easeOutBack = easeOutBack; exports.easeInOutBack = easeInOutBack; exports.easeInBounce = easeInBounce; exports.easeOutBounce = easeOutBounce; exports.easeInOutBounce = easeInOutBounce;

function easeInQuad(t, b, c, d) {

return c * (t /= d) * t + b;

}

function easeOutQuad(t, b, c, d) {

return -c * (t /= d) * (t - 2) + b;

}

function easeInOutQuad(t, b, c, d) {

if ((t /= d / 2) < 1) return c / 2 * t * t + b;
return -c / 2 * (--t * (t - 2) - 1) + b;

}

function easeInCubic(t, b, c, d) {

return c * (t /= d) * t * t + b;

}

function easeOutCubic(t, b, c, d) {

return c * ((t = t / d - 1) * t * t + 1) + b;

}

function easeInOutCubic(t, b, c, d) {

if ((t /= d / 2) < 1) return c / 2 * t * t * t + b;
return c / 2 * ((t -= 2) * t * t + 2) + b;

}

function easeInQuart(t, b, c, d) {

return c * (t /= d) * t * t * t + b;

}

function easeOutQuart(t, b, c, d) {

return -c * ((t = t / d - 1) * t * t * t - 1) + b;

}

function easeInOutQuart(t, b, c, d) {

if ((t /= d / 2) < 1) return c / 2 * t * t * t * t + b;
return -c / 2 * ((t -= 2) * t * t * t - 2) + b;

}

function easeInQuint(t, b, c, d) {

return c * (t /= d) * t * t * t * t + b;

}

function easeOutQuint(t, b, c, d) {

return c * ((t = t / d - 1) * t * t * t * t + 1) + b;

}

function easeInOutQuint(t, b, c, d) {

if ((t /= d / 2) < 1) return c / 2 * t * t * t * t * t + b;
return c / 2 * ((t -= 2) * t * t * t * t + 2) + b;

}

function easeInSine(t, b, c, d) {

return -c * Math.cos(t / d * (Math.PI / 2)) + c + b;

}

function easeOutSine(t, b, c, d) {

return c * Math.sin(t / d * (Math.PI / 2)) + b;

}

function easeInOutSine(t, b, c, d) {

return -c / 2 * (Math.cos(Math.PI * t / d) - 1) + b;

}

function easeInExpo(t, b, c, d) {

return t == 0 ? b : c * Math.pow(2, 10 * (t / d - 1)) + b;

}

function easeOutExpo(t, b, c, d) {

return t == d ? b + c : c * (-Math.pow(2, -10 * t / d) + 1) + b;

}

function easeInOutExpo(t, b, c, d) {

if (t == 0) return b;
if (t == d) return b + c;
if ((t /= d / 2) < 1) return c / 2 * Math.pow(2, 10 * (t - 1)) + b;
return c / 2 * (-Math.pow(2, -10 * --t) + 2) + b;

}

function easeInCirc(t, b, c, d) {

return -c * (Math.sqrt(1 - (t /= d) * t) - 1) + b;

}

function easeOutCirc(t, b, c, d) {

return c * Math.sqrt(1 - (t = t / d - 1) * t) + b;

}

function easeInOutCirc(t, b, c, d) {

if ((t /= d / 2) < 1) return -c / 2 * (Math.sqrt(1 - t * t) - 1) + b;
return c / 2 * (Math.sqrt(1 - (t -= 2) * t) + 1) + b;

}

function easeInElastic(t, b, c, d) {

var s = 1.70158;var p = 0;var a = c;
if (t == 0) return b;if ((t /= d) == 1) return b + c;if (!p) p = d * .3;

if (a < Math.abs(c)) {
  a = c;var s = p / 4;
} else var s = p / (2 * Math.PI) * Math.asin(c / a);
return -(a * Math.pow(2, 10 * (t -= 1)) * Math.sin((t * d - s) * (2 * Math.PI) / p)) + b;

}

function easeOutElastic(t, b, c, d) {

var s = 1.70158;var p = 0;var a = c;
if (t == 0) return b;if ((t /= d) == 1) return b + c;if (!p) p = d * .3;

if (a < Math.abs(c)) {
  a = c;var s = p / 4;
} else var s = p / (2 * Math.PI) * Math.asin(c / a);
return a * Math.pow(2, -10 * t) * Math.sin((t * d - s) * (2 * Math.PI) / p) + c + b;

}

function easeInOutElastic(t, b, c, d) {

var s = 1.70158;var p = 0;var a = c;
if (t == 0) return b;if ((t /= d / 2) == 2) return b + c;if (!p) p = d * (.3 * 1.5);

if (a < Math.abs(c)) {
  a = c;var s = p / 4;
} else var s = p / (2 * Math.PI) * Math.asin(c / a);
if (t < 1) return -.5 * (a * Math.pow(2, 10 * (t -= 1)) * Math.sin((t * d - s) * (2 * Math.PI) / p)) + b;
return a * Math.pow(2, -10 * (t -= 1)) * Math.sin((t * d - s) * (2 * Math.PI) / p) * .5 + c + b;

}

function easeInBack(t, b, c, d, s) {

if (s == undefined) s = 1.70158;
return c * (t /= d) * t * ((s + 1) * t - s) + b;

}

function easeOutBack(t, b, c, d, s) {

if (s == undefined) s = 1.70158;
return c * ((t = t / d - 1) * t * ((s + 1) * t + s) + 1) + b;

}

function easeInOutBack(t, b, c, d, s) {

if (s == undefined) s = 1.70158;
if ((t /= d / 2) < 1) return c / 2 * (t * t * (((s *= 1.525) + 1) * t - s)) + b;
return c / 2 * ((t -= 2) * t * (((s *= 1.525) + 1) * t + s) + 2) + b;

}

function easeInBounce(t, b, c, d) {

return c - easeOutBounce(d - t, 0, c, d) + b;

}

function easeOutBounce(t, b, c, d) {

if ((t /= d) < 1 / 2.75) {
  return c * (7.5625 * t * t) + b;
} else if (t < 2 / 2.75) {
  return c * (7.5625 * (t -= 1.5 / 2.75) * t + .75) + b;
} else if (t < 2.5 / 2.75) {
  return c * (7.5625 * (t -= 2.25 / 2.75) * t + .9375) + b;
} else {
  return c * (7.5625 * (t -= 2.625 / 2.75) * t + .984375) + b;
}

}

function easeInOutBounce(t, b, c, d) {

if (t < d / 2) return easeInBounce(t * 2, 0, c, d) * .5 + b;
return easeOutBounce(t * 2 - d, 0, c, d) * .5 + c * .5 + b;

}

},{}]},{},[1])(1) });

/***/ }), /* 3 */ /***/ (function(module, exports, webpack_require) {

“use strict”; /* global document */ /* eslint-disable no-undef */

function ready(callback) {

if (typeof document === undefined) {
  console.log('document-ready only runs in the browser');
  return;
}
const state = document.readyState;
if (state === 'complete' || state === 'interactive') {
  return setTimeout(callback, 0);
}

document.addEventListener('DOMContentLoaded', () => {
  callback();
});

}

module.exports = ready;

/***/ }) /******/ ]);