Libs

<script src="/components/raw/libs/debounce.js"></script>
<script src="/components/raw/libs/lazysizes.js"></script>
<script src="/components/raw/libs/svg4everybody.js"></script>
<script src="/components/raw/libs/nouislider.min.js"></script>
<script src="/components/raw/libs/lory.js"></script>
<script src="/components/raw/libs/../dropdown-list/dropdown-list.js"></script>
<script>
    svg4everybody();
</script>
<script src="{{ static 'debounce.js' }}"></script>
<script src="{{ static 'lazysizes.js' }}"></script>
<script src="{{ static 'svg4everybody.js' }}"></script>
<script src="{{ static 'nouislider.min.js' }}"></script>
<script src="{{ static 'lory.js' }}"></script>
<script src="{{ static '../dropdown-list/dropdown-list.js' }}"></script>
<script>svg4everybody();</script>
/* No context defined for this component. */
  • Content:
    // sass-lint:disable-all
    /* normalize.css v7.0.0 | MIT License | github.com/necolas/normalize.css */
    
    /* Document
       ========================================================================== */
    
    /**
     * 1. Correct the line height in all browsers.
     * 2. Prevent adjustments of font size after orientation changes in
     *    IE on Windows Phone and in iOS.
     */
    
    html {
      line-height: 1.15; /* 1 */
      -ms-text-size-adjust: 100%; /* 2 */
      -webkit-text-size-adjust: 100%; /* 2 */
    }
    
    /* Sections
       ========================================================================== */
    
    /**
     * Remove the margin in all browsers (opinionated).
     */
    
    body {
      margin: 0;
    }
    
    /**
     * Add the correct display in IE 9-.
     */
    
    article,
    aside,
    footer,
    header,
    nav,
    section {
      display: block;
    }
    
    /**
     * Correct the font size and margin on `h1` elements within `section` and
     * `article` contexts in Chrome, Firefox, and Safari.
     */
    
    h1 {
      font-size: 2em;
      margin: 0.67em 0;
    }
    
    /* Grouping content
       ========================================================================== */
    
    /**
     * Add the correct display in IE 9-.
     * 1. Add the correct display in IE.
     */
    
    figcaption,
    figure,
    main { /* 1 */
      display: block;
    }
    
    /**
     * Add the correct margin in IE 8.
     */
    
    figure {
      margin: 1em 40px;
    }
    
    /**
     * 1. Add the correct box sizing in Firefox.
     * 2. Show the overflow in Edge and IE.
     */
    
    hr {
      box-sizing: content-box; /* 1 */
      height: 0; /* 1 */
      overflow: visible; /* 2 */
    }
    
    /**
     * 1. Correct the inheritance and scaling of font size in all browsers.
     * 2. Correct the odd `em` font sizing in all browsers.
     */
    
    pre {
      /* stylelint-disable-next-line font-family-no-duplicate-names */
      font-family: monospace, monospace; /* 1 */
      font-size: 1em; /* 2 */
    }
    
    /* Text-level semantics
       ========================================================================== */
    
    /**
     * 1. Remove the gray background on active links in IE 10.
     * 2. Remove gaps in links underline in iOS 8+ and Safari 8+.
     */
    
    a {
      background-color: transparent; /* 1 */
      -webkit-text-decoration-skip: objects; /* 2 */
    }
    
    /**
     * 1. Remove the bottom border in Chrome 57- and Firefox 39-.
     * 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari.
     */
    
    abbr[title] {
      border-bottom: none; /* 1 */
      text-decoration: underline; /* 2 */
      text-decoration: underline dotted; /* 2 */
    }
    
    /**
     * Prevent the duplicate application of `bolder` by the next rule in Safari 6.
     */
    
    b,
    strong {
      font-weight: inherit;
    }
    
    /**
     * Add the correct font weight in Chrome, Edge, and Safari.
     */
    
    b,
    strong {
      font-weight: bolder;
    }
    
    /**
     * 1. Correct the inheritance and scaling of font size in all browsers.
     * 2. Correct the odd `em` font sizing in all browsers.
     */
    
    code,
    kbd,
    samp {
      /* stylelint-disable-next-line font-family-no-duplicate-names */
      font-family: monospace, monospace; /* 1 */
      font-size: 1em; /* 2 */
    }
    
    /**
     * Add the correct font style in Android 4.3-.
     */
    
    dfn {
      font-style: italic;
    }
    
    /**
     * Add the correct background and color in IE 9-.
     */
    
    mark {
      background-color: #ff0;
      color: #000;
    }
    
    /**
     * Add the correct font size in all browsers.
     */
    
    small {
      font-size: 80%;
    }
    
    /**
     * Prevent `sub` and `sup` elements from affecting the line height in
     * all browsers.
     */
    
    sub,
    sup {
      font-size: 75%;
      line-height: 0;
      position: relative;
      vertical-align: baseline;
    }
    
    sub {
      bottom: -0.25em;
    }
    
    sup {
      top: -0.5em;
    }
    
    /* Embedded content
       ========================================================================== */
    
    /**
     * Add the correct display in IE 9-.
     */
    
    audio,
    video {
      display: inline-block;
    }
    
    /**
     * Add the correct display in iOS 4-7.
     */
    
    audio:not([controls]) {
      display: none;
      height: 0;
    }
    
    /**
     * Remove the border on images inside links in IE 10-.
     */
    
    img {
      border-style: none;
    }
    
    /**
     * Hide the overflow in IE.
     */
    
    svg:not(:root) {
      overflow: hidden;
    }
    
    /* Forms
       ========================================================================== */
    
    /**
     * 1. Change the font styles in all browsers (opinionated).
     * 2. Remove the margin in Firefox and Safari.
     */
    
    button,
    input,
    optgroup,
    select,
    textarea {
      font-family: sans-serif; /* 1 */
      font-size: 100%; /* 1 */
      line-height: 1.15; /* 1 */
      margin: 0; /* 2 */
    }
    
    /**
     * Show the overflow in IE.
     * 1. Show the overflow in Edge.
     */
    
    button,
    input { /* 1 */
      overflow: visible;
    }
    
    /**
     * Remove the inheritance of text transform in Edge, Firefox, and IE.
     * 1. Remove the inheritance of text transform in Firefox.
     */
    
    button,
    select { /* 1 */
      text-transform: none;
    }
    
    /**
     * 1. Prevent a WebKit bug where (2) destroys native `audio` and `video`
     *    controls in Android 4.
     * 2. Correct the inability to style clickable types in iOS and Safari.
     */
    
    button,
    html [type="button"], /* 1 */
    [type="reset"],
    [type="submit"] {
      -webkit-appearance: button; /* 2 */
    }
    
    /**
     * Remove the inner border and padding in Firefox.
     */
    
    button::-moz-focus-inner,
    [type="button"]::-moz-focus-inner,
    [type="reset"]::-moz-focus-inner,
    [type="submit"]::-moz-focus-inner {
      border-style: none;
      padding: 0;
    }
    
    /**
     * Restore the focus styles unset by the previous rule.
     */
    
    button:-moz-focusring,
    [type="button"]:-moz-focusring,
    [type="reset"]:-moz-focusring,
    [type="submit"]:-moz-focusring {
      outline: 1px dotted ButtonText;
    }
    
    /**
     * Correct the padding in Firefox.
     */
    
    fieldset {
      padding: 0.35em 0.75em 0.625em;
    }
    
    /**
     * 1. Correct the text wrapping in Edge and IE.
     * 2. Correct the color inheritance from `fieldset` elements in IE.
     * 3. Remove the padding so developers are not caught out when they zero out
     *    `fieldset` elements in all browsers.
     */
    
    legend {
      box-sizing: border-box; /* 1 */
      color: inherit; /* 2 */
      display: table; /* 1 */
      max-width: 100%; /* 1 */
      padding: 0; /* 3 */
      white-space: normal; /* 1 */
    }
    
    /**
     * 1. Add the correct display in IE 9-.
     * 2. Add the correct vertical alignment in Chrome, Firefox, and Opera.
     */
    
    progress {
      display: inline-block; /* 1 */
      vertical-align: baseline; /* 2 */
    }
    
    /**
     * Remove the default vertical scrollbar in IE.
     */
    
    textarea {
      overflow: auto;
    }
    
    /**
     * 1. Add the correct box sizing in IE 10-.
     * 2. Remove the padding in IE 10-.
     */
    
    [type="checkbox"],
    [type="radio"] {
      box-sizing: border-box; /* 1 */
      padding: 0; /* 2 */
    }
    
    /**
     * Correct the cursor style of increment and decrement buttons in Chrome.
     */
    
    [type="number"]::-webkit-inner-spin-button,
    [type="number"]::-webkit-outer-spin-button {
      height: auto;
    }
    
    /**
     * 1. Correct the odd appearance in Chrome and Safari.
     * 2. Correct the outline style in Safari.
     */
    
    [type="search"] {
      -webkit-appearance: textfield; /* 1 */
      outline-offset: -2px; /* 2 */
    }
    
    /**
     * Remove the inner padding and cancel buttons in Chrome and Safari on macOS.
     */
    
    [type="search"]::-webkit-search-cancel-button,
    [type="search"]::-webkit-search-decoration {
      -webkit-appearance: none;
    }
    
    /**
     * 1. Correct the inability to style clickable types in iOS and Safari.
     * 2. Change font properties to `inherit` in Safari.
     */
    
    ::-webkit-file-upload-button {
      -webkit-appearance: button; /* 1 */
      font: inherit; /* 2 */
    }
    
    /* Interactive
       ========================================================================== */
    
    /*
     * Add the correct display in IE 9-.
     * 1. Add the correct display in Edge, IE, and Firefox.
     */
    
    details, /* 1 */
    menu {
      display: block;
    }
    
    /*
     * Add the correct display in all browsers.
     */
    
    summary {
      display: list-item;
    }
    
    /* Scripting
       ========================================================================== */
    
    /**
     * Add the correct display in IE 9-.
     */
    
    canvas {
      display: inline-block;
    }
    
    /**
     * Add the correct display in IE.
     */
    
    template {
      display: none;
    }
    
    /* Hidden
       ========================================================================== */
    
    /**
     * Add the correct display in IE 10-.
     */
    
    [hidden] {
      display: none;
    }
    
    dd,
    dt {
        margin: 0;
        padding: 0;
    }
    
  • URL: /components/raw/libs/_normalize.scss
  • Filesystem Path: build/components/01-globals/libs/_normalize.scss
  • Size: 7.9 KB
  • Content:
    // sass-lint:disable-all
     /* stylelint-disable */
    /*! nouislider - 10.0.0 - 2017-05-28 14:52:48 */
    /* Functional styling;
     * These styles are required for noUiSlider to function.
     * You don't need to change these rules to apply your design.
     */
    .noUi-target,
    .noUi-target * {
      -webkit-touch-callout: none;
      -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
      -webkit-user-select: none;
      -ms-touch-action: none;
      touch-action: none;
      -ms-user-select: none;
      -moz-user-select: none;
      user-select: none;
      -moz-box-sizing: border-box;
      box-sizing: border-box;
    }
    .noUi-target {
      position: relative;
      direction: ltr;
    }
    .noUi-base {
      width: 100%;
      height: 100%;
      position: relative;
      z-index: 1;
      /* Fix 401 */
    }
    .noUi-connect {
      position: absolute;
      right: 0;
      top: 0;
      left: 0;
      bottom: 0;
    }
    .noUi-origin {
      position: absolute;
      height: 0;
      width: 0;
    }
    .noUi-handle {
      position: relative;
      z-index: 1;
    }
    .noUi-state-tap .noUi-connect,
    .noUi-state-tap .noUi-origin {
      -webkit-transition: top 0.3s, right 0.3s, bottom 0.3s, left 0.3s;
      transition: top 0.3s, right 0.3s, bottom 0.3s, left 0.3s;
    }
    .noUi-state-drag * {
      cursor: inherit !important;
    }
    /* Painting and performance;
     * Browsers can paint handles in their own layer.
     */
    .noUi-base,
    .noUi-handle {
      -webkit-transform: translate3d(0, 0, 0);
      transform: translate3d(0, 0, 0);
    }
    /* Slider size and handle placement;
     */
    .noUi-horizontal {
      height: 18px;
    }
    .noUi-horizontal .noUi-handle {
      width: 34px;
      height: 28px;
      left: -17px;
      top: -6px;
    }
    .noUi-vertical {
      width: 18px;
    }
    .noUi-vertical .noUi-handle {
      width: 28px;
      height: 34px;
      left: -6px;
      top: -17px;
    }
    /* Styling;
     */
    .noUi-target {
      background: #FAFAFA;
      border-radius: 4px;
      border: 1px solid #D3D3D3;
      box-shadow: inset 0 1px 1px #F0F0F0, 0 3px 6px -5px #BBB;
    }
    .noUi-connect {
      background: #3FB8AF;
      border-radius: 4px;
      box-shadow: inset 0 0 3px rgba(51, 51, 51, 0.45);
      -webkit-transition: background 450ms;
      transition: background 450ms;
    }
    /* Handles and cursors;
     */
    .noUi-draggable {
      cursor: ew-resize;
    }
    .noUi-vertical .noUi-draggable {
      cursor: ns-resize;
    }
    .noUi-handle {
      border: 1px solid #D9D9D9;
      border-radius: 3px;
      background: #FFF;
      cursor: default;
      box-shadow: inset 0 0 1px #FFF, inset 0 1px 7px #EBEBEB, 0 3px 6px -3px #BBB;
    }
    .noUi-active {
      box-shadow: inset 0 0 1px #FFF, inset 0 1px 7px #DDD, 0 3px 6px -3px #BBB;
    }
    /* Handle stripes;
     */
    .noUi-handle:before,
    .noUi-handle:after {
      content: "";
      display: block;
      position: absolute;
      height: 14px;
      width: 1px;
      background: #E8E7E6;
      left: 14px;
      top: 6px;
    }
    .noUi-handle:after {
      left: 17px;
    }
    .noUi-vertical .noUi-handle:before,
    .noUi-vertical .noUi-handle:after {
      width: 14px;
      height: 1px;
      left: 6px;
      top: 14px;
    }
    .noUi-vertical .noUi-handle:after {
      top: 17px;
    }
    /* Disabled state;
     */
    [disabled] .noUi-connect {
      background: #B8B8B8;
    }
    [disabled].noUi-target,
    [disabled].noUi-handle,
    [disabled] .noUi-handle {
      cursor: not-allowed;
    }
    /* Base;
     *
     */
    .noUi-pips,
    .noUi-pips * {
      -moz-box-sizing: border-box;
      box-sizing: border-box;
    }
    .noUi-pips {
      position: absolute;
      color: #999;
    }
    /* Values;
     *
     */
    .noUi-value {
      position: absolute;
      white-space: nowrap;
      text-align: center;
    }
    .noUi-value-sub {
      color: #ccc;
      font-size: 10px;
    }
    /* Markings;
     *
     */
    .noUi-marker {
      position: absolute;
      background: #CCC;
    }
    .noUi-marker-sub {
      background: #AAA;
    }
    .noUi-marker-large {
      background: #AAA;
    }
    /* Horizontal layout;
     *
     */
    .noUi-pips-horizontal {
      padding: 10px 0;
      height: 80px;
      top: 100%;
      left: 0;
      width: 100%;
    }
    .noUi-value-horizontal {
      -webkit-transform: translate3d(-50%, 50%, 0);
      transform: translate3d(-50%, 50%, 0);
    }
    .noUi-marker-horizontal.noUi-marker {
      margin-left: -1px;
      width: 2px;
      height: 5px;
    }
    .noUi-marker-horizontal.noUi-marker-sub {
      height: 10px;
    }
    .noUi-marker-horizontal.noUi-marker-large {
      height: 15px;
    }
    /* Vertical layout;
     *
     */
    .noUi-pips-vertical {
      padding: 0 10px;
      height: 100%;
      top: 0;
      left: 100%;
    }
    .noUi-value-vertical {
      -webkit-transform: translate3d(0, 50%, 0);
      transform: translate3d(0, 50%, 0);
      padding-left: 25px;
    }
    .noUi-marker-vertical.noUi-marker {
      width: 5px;
      height: 2px;
      margin-top: -1px;
    }
    .noUi-marker-vertical.noUi-marker-sub {
      width: 10px;
    }
    .noUi-marker-vertical.noUi-marker-large {
      width: 15px;
    }
    .noUi-tooltip {
      display: block;
      position: absolute;
      border: 1px solid #D9D9D9;
      border-radius: 3px;
      background: #fff;
      color: #000;
      padding: 5px;
      text-align: center;
      white-space: nowrap;
    }
    .noUi-horizontal .noUi-tooltip {
      -webkit-transform: translate(-50%, 0);
      transform: translate(-50%, 0);
      left: 50%;
      bottom: 120%;
    }
    .noUi-vertical .noUi-tooltip {
      -webkit-transform: translate(0, -50%);
      transform: translate(0, -50%);
      top: 50%;
      right: 120%;
    }
    /* stylelint-enable */
    // sass-lint:enable-all
    
  • URL: /components/raw/libs/_nouislider.scss
  • Filesystem Path: build/components/01-globals/libs/_nouislider.scss
  • Size: 4.9 KB
  • Content:
    function debounce(callback, wait, context = this) {
      let timeout = null,
          callbackArgs = null;
    
      const later = () => callback.apply(context, callbackArgs);
    
      return function() {
        callbackArgs = arguments;
        clearTimeout(timeout);
        timeout = setTimeout(later, wait);
      }
    }
    
  • URL: /components/raw/libs/debounce.js
  • Filesystem Path: build/components/01-globals/libs/debounce.js
  • Size: 288 Bytes
  • Content:
    /*! lazysizes - v3.0.0 */
    (function(window, factory) {
    	var lazySizes = factory(window, window.document);
    	window.lazySizes = lazySizes;
    	if(typeof module == 'object' && module.exports){
    		module.exports = lazySizes;
    	}
    }(window, function l(window, document) {
    	'use strict';
    	/*jshint eqnull:true */
    	if(!document.getElementsByClassName){return;}
    
    	var lazySizesConfig;
    
    	var docElem = document.documentElement;
    
    	var Date = window.Date;
    
    	var supportPicture = window.HTMLPictureElement;
    
    	var _addEventListener = 'addEventListener';
    
    	var _getAttribute = 'getAttribute';
    
    	var addEventListener = window[_addEventListener];
    
    	var setTimeout = window.setTimeout;
    
    	var requestAnimationFrame = window.requestAnimationFrame || setTimeout;
    
    	var requestIdleCallback = window.requestIdleCallback;
    
    	var regPicture = /^picture$/i;
    
    	var loadEvents = ['load', 'error', 'lazyincluded', '_lazyloaded'];
    
    	var regClassCache = {};
    
    	var forEach = Array.prototype.forEach;
    
    	var hasClass = function(ele, cls) {
    		if(!regClassCache[cls]){
    			regClassCache[cls] = new RegExp('(\\s|^)'+cls+'(\\s|$)');
    		}
    		return regClassCache[cls].test(ele[_getAttribute]('class') || '') && regClassCache[cls];
    	};
    
    	var addClass = function(ele, cls) {
    		if (!hasClass(ele, cls)){
    			ele.setAttribute('class', (ele[_getAttribute]('class') || '').trim() + ' ' + cls);
    		}
    	};
    
    	var removeClass = function(ele, cls) {
    		var reg;
    		if ((reg = hasClass(ele,cls))) {
    			ele.setAttribute('class', (ele[_getAttribute]('class') || '').replace(reg, ' '));
    		}
    	};
    
    	var addRemoveLoadEvents = function(dom, fn, add){
    		var action = add ? _addEventListener : 'removeEventListener';
    		if(add){
    			addRemoveLoadEvents(dom, fn);
    		}
    		loadEvents.forEach(function(evt){
    			dom[action](evt, fn);
    		});
    	};
    
    	var triggerEvent = function(elem, name, detail, noBubbles, noCancelable){
    		var event = document.createEvent('CustomEvent');
    
    		event.initCustomEvent(name, !noBubbles, !noCancelable, detail || {});
    
    		elem.dispatchEvent(event);
    		return event;
    	};
    
    	var updatePolyfill = function (el, full){
    		var polyfill;
    		if( !supportPicture && ( polyfill = (window.picturefill || lazySizesConfig.pf) ) ){
    			polyfill({reevaluate: true, elements: [el]});
    		} else if(full && full.src){
    			el.src = full.src;
    		}
    	};
    
    	var getCSS = function (elem, style){
    		return (getComputedStyle(elem, null) || {})[style];
    	};
    
    	var getWidth = function(elem, parent, width){
    		width = width || elem.offsetWidth;
    
    		while(width < lazySizesConfig.minSize && parent && !elem._lazysizesWidth){
    			width =  parent.offsetWidth;
    			parent = parent.parentNode;
    		}
    
    		return width;
    	};
    
    	var rAF = (function(){
    		var running, waiting;
    		var firstFns = [];
    		var secondFns = [];
    		var fns = firstFns;
    
    		var run = function(){
    			var runFns = fns;
    
    			fns = firstFns.length ? secondFns : firstFns;
    
    			running = true;
    			waiting = false;
    
    			while(runFns.length){
    				runFns.shift()();
    			}
    
    			running = false;
    		};
    
    		var rafBatch = function(fn, queue){
    			if(running && !queue){
    				fn.apply(this, arguments);
    			} else {
    				fns.push(fn);
    
    				if(!waiting){
    					waiting = true;
    					(document.hidden ? setTimeout : requestAnimationFrame)(run);
    				}
    			}
    		};
    
    		rafBatch._lsFlush = run;
    
    		return rafBatch;
    	})();
    
    	var rAFIt = function(fn, simple){
    		return simple ?
    			function() {
    				rAF(fn);
    			} :
    			function(){
    				var that = this;
    				var args = arguments;
    				rAF(function(){
    					fn.apply(that, args);
    				});
    			}
    		;
    	};
    
    	var throttle = function(fn){
    		var running;
    		var lastTime = 0;
    		var gDelay = 125;
    		var RIC_DEFAULT_TIMEOUT = 666;
    		var rICTimeout = RIC_DEFAULT_TIMEOUT;
    		var run = function(){
    			running = false;
    			lastTime = Date.now();
    			fn();
    		};
    		var idleCallback = requestIdleCallback ?
    			function(){
    				requestIdleCallback(run, {timeout: rICTimeout});
    				if(rICTimeout !== RIC_DEFAULT_TIMEOUT){
    					rICTimeout = RIC_DEFAULT_TIMEOUT;
    				}
    			}:
    			rAFIt(function(){
    				setTimeout(run);
    			}, true)
    		;
    
    		return function(isPriority){
    			var delay;
    			if((isPriority = isPriority === true)){
    				rICTimeout = 44;
    			}
    
    			if(running){
    				return;
    			}
    
    			running =  true;
    
    			delay = gDelay - (Date.now() - lastTime);
    
    			if(delay < 0){
    				delay = 0;
    			}
    
    			if(isPriority || (delay < 9 && requestIdleCallback)){
    				idleCallback();
    			} else {
    				setTimeout(idleCallback, delay);
    			}
    		};
    	};
    
    	//based on http://modernjavascript.blogspot.de/2013/08/building-better-debounce.html
    	var debounce = function(func) {
    		var timeout, timestamp;
    		var wait = 99;
    		var run = function(){
    			timeout = null;
    			func();
    		};
    		var later = function() {
    			var last = Date.now() - timestamp;
    
    			if (last < wait) {
    				setTimeout(later, wait - last);
    			} else {
    				(requestIdleCallback || run)(run);
    			}
    		};
    
    		return function() {
    			timestamp = Date.now();
    
    			if (!timeout) {
    				timeout = setTimeout(later, wait);
    			}
    		};
    	};
    
    
    	var loader = (function(){
    		var lazyloadElems, preloadElems, isCompleted, resetPreloadingTimer, loadMode, started;
    
    		var eLvW, elvH, eLtop, eLleft, eLright, eLbottom;
    
    		var defaultExpand, preloadExpand, hFac;
    
    		var regImg = /^img$/i;
    		var regIframe = /^iframe$/i;
    
    		var supportScroll = ('onscroll' in window) && !(/glebot/.test(navigator.userAgent));
    
    		var shrinkExpand = 0;
    		var currentExpand = 0;
    
    		var isLoading = 0;
    		var lowRuns = -1;
    
    		var resetPreloading = function(e){
    			isLoading--;
    			if(e && e.target){
    				addRemoveLoadEvents(e.target, resetPreloading);
    			}
    
    			if(!e || isLoading < 0 || !e.target){
    				isLoading = 0;
    			}
    		};
    
    		var isNestedVisible = function(elem, elemExpand){
    			var outerRect;
    			var parent = elem;
    			var visible = getCSS(document.body, 'visibility') == 'hidden' || getCSS(elem, 'visibility') != 'hidden';
    
    			eLtop -= elemExpand;
    			eLbottom += elemExpand;
    			eLleft -= elemExpand;
    			eLright += elemExpand;
    
    			while(visible && (parent = parent.offsetParent) && parent != document.body && parent != docElem){
    				visible = ((getCSS(parent, 'opacity') || 1) > 0);
    
    				if(visible && getCSS(parent, 'overflow') != 'visible'){
    					outerRect = parent.getBoundingClientRect();
    					visible = eLright > outerRect.left &&
    						eLleft < outerRect.right &&
    						eLbottom > outerRect.top - 1 &&
    						eLtop < outerRect.bottom + 1
    					;
    				}
    			}
    
    			return visible;
    		};
    
    		var checkElements = function() {
    			var eLlen, i, rect, autoLoadElem, loadedSomething, elemExpand, elemNegativeExpand, elemExpandVal, beforeExpandVal;
    
    			if((loadMode = lazySizesConfig.loadMode) && isLoading < 8 && (eLlen = lazyloadElems.length)){
    
    				i = 0;
    
    				lowRuns++;
    
    				if(preloadExpand == null){
    					if(!('expand' in lazySizesConfig)){
    						lazySizesConfig.expand = docElem.clientHeight > 500 && docElem.clientWidth > 500 ? 500 : 370;
    					}
    
    					defaultExpand = lazySizesConfig.expand;
    					preloadExpand = defaultExpand * lazySizesConfig.expFactor;
    				}
    
    				if(currentExpand < preloadExpand && isLoading < 1 && lowRuns > 2 && loadMode > 2 && !document.hidden){
    					currentExpand = preloadExpand;
    					lowRuns = 0;
    				} else if(loadMode > 1 && lowRuns > 1 && isLoading < 6){
    					currentExpand = defaultExpand;
    				} else {
    					currentExpand = shrinkExpand;
    				}
    
    				for(; i < eLlen; i++){
    
    					if(!lazyloadElems[i] || lazyloadElems[i]._lazyRace){continue;}
    
    					if(!supportScroll){unveilElement(lazyloadElems[i]);continue;}
    
    					if(!(elemExpandVal = lazyloadElems[i][_getAttribute]('data-expand')) || !(elemExpand = elemExpandVal * 1)){
    						elemExpand = currentExpand;
    					}
    
    					if(beforeExpandVal !== elemExpand){
    						eLvW = innerWidth + (elemExpand * hFac);
    						elvH = innerHeight + elemExpand;
    						elemNegativeExpand = elemExpand * -1;
    						beforeExpandVal = elemExpand;
    					}
    
    					rect = lazyloadElems[i].getBoundingClientRect();
    
    					if ((eLbottom = rect.bottom) >= elemNegativeExpand &&
    						(eLtop = rect.top) <= elvH &&
    						(eLright = rect.right) >= elemNegativeExpand * hFac &&
    						(eLleft = rect.left) <= eLvW &&
    						(eLbottom || eLright || eLleft || eLtop) &&
    						((isCompleted && isLoading < 3 && !elemExpandVal && (loadMode < 3 || lowRuns < 4)) || isNestedVisible(lazyloadElems[i], elemExpand))){
    						unveilElement(lazyloadElems[i]);
    						loadedSomething = true;
    						if(isLoading > 9){break;}
    					} else if(!loadedSomething && isCompleted && !autoLoadElem &&
    						isLoading < 4 && lowRuns < 4 && loadMode > 2 &&
    						(preloadElems[0] || lazySizesConfig.preloadAfterLoad) &&
    						(preloadElems[0] || (!elemExpandVal && ((eLbottom || eLright || eLleft || eLtop) || lazyloadElems[i][_getAttribute](lazySizesConfig.sizesAttr) != 'auto')))){
    						autoLoadElem = preloadElems[0] || lazyloadElems[i];
    					}
    				}
    
    				if(autoLoadElem && !loadedSomething){
    					unveilElement(autoLoadElem);
    				}
    			}
    		};
    
    		var throttledCheckElements = throttle(checkElements);
    
    		var switchLoadingClass = function(e){
    			addClass(e.target, lazySizesConfig.loadedClass);
    			removeClass(e.target, lazySizesConfig.loadingClass);
    			addRemoveLoadEvents(e.target, rafSwitchLoadingClass);
    		};
    		var rafedSwitchLoadingClass = rAFIt(switchLoadingClass);
    		var rafSwitchLoadingClass = function(e){
    			rafedSwitchLoadingClass({target: e.target});
    		};
    
    		var changeIframeSrc = function(elem, src){
    			try {
    				elem.contentWindow.location.replace(src);
    			} catch(e){
    				elem.src = src;
    			}
    		};
    
    		var handleSources = function(source){
    			var customMedia, parent;
    
    			var sourceSrcset = source[_getAttribute](lazySizesConfig.srcsetAttr);
    
    			if( (customMedia = lazySizesConfig.customMedia[source[_getAttribute]('data-media') || source[_getAttribute]('media')]) ){
    				source.setAttribute('media', customMedia);
    			}
    
    			if(sourceSrcset){
    				source.setAttribute('srcset', sourceSrcset);
    			}
    
    			//https://bugzilla.mozilla.org/show_bug.cgi?id=1170572
    			if(customMedia){
    				parent = source.parentNode;
    				parent.insertBefore(source.cloneNode(), source);
    				parent.removeChild(source);
    			}
    		};
    
    		var lazyUnveil = rAFIt(function (elem, detail, isAuto, sizes, isImg){
    			var src, srcset, parent, isPicture, event, firesLoad;
    
    			if(!(event = triggerEvent(elem, 'lazybeforeunveil', detail)).defaultPrevented){
    
    				if(sizes){
    					if(isAuto){
    						addClass(elem, lazySizesConfig.autosizesClass);
    					} else {
    						elem.setAttribute('sizes', sizes);
    					}
    				}
    
    				srcset = elem[_getAttribute](lazySizesConfig.srcsetAttr);
    				src = elem[_getAttribute](lazySizesConfig.srcAttr);
    
    				if(isImg) {
    					parent = elem.parentNode;
    					isPicture = parent && regPicture.test(parent.nodeName || '');
    				}
    
    				firesLoad = detail.firesLoad || (('src' in elem) && (srcset || src || isPicture));
    
    				event = {target: elem};
    
    				if(firesLoad){
    					addRemoveLoadEvents(elem, resetPreloading, true);
    					clearTimeout(resetPreloadingTimer);
    					resetPreloadingTimer = setTimeout(resetPreloading, 2500);
    
    					addClass(elem, lazySizesConfig.loadingClass);
    					addRemoveLoadEvents(elem, rafSwitchLoadingClass, true);
    				}
    
    				if(isPicture){
    					forEach.call(parent.getElementsByTagName('source'), handleSources);
    				}
    
    				if(srcset){
    					elem.setAttribute('srcset', srcset);
    				} else if(src && !isPicture){
    					if(regIframe.test(elem.nodeName)){
    						changeIframeSrc(elem, src);
    					} else {
    						elem.src = src;
    					}
    				}
    
    				if(srcset || isPicture){
    					updatePolyfill(elem, {src: src});
    				}
    			}
    
    			if(elem._lazyRace){
    				delete elem._lazyRace;
    			}
    			removeClass(elem, lazySizesConfig.lazyClass);
    
    			rAF(function(){
    				if( !firesLoad || (elem.complete && elem.naturalWidth > 1)){
    					if(firesLoad){
    						resetPreloading(event);
    					} else {
    						isLoading--;
    					}
    					switchLoadingClass(event);
    				}
    			}, true);
    		});
    
    		var unveilElement = function (elem){
    			var detail;
    
    			var isImg = regImg.test(elem.nodeName);
    
    			//allow using sizes="auto", but don't use. it's invalid. Use data-sizes="auto" or a valid value for sizes instead (i.e.: sizes="80vw")
    			var sizes = isImg && (elem[_getAttribute](lazySizesConfig.sizesAttr) || elem[_getAttribute]('sizes'));
    			var isAuto = sizes == 'auto';
    
    			if( (isAuto || !isCompleted) && isImg && (elem.src || elem.srcset) && !elem.complete && !hasClass(elem, lazySizesConfig.errorClass)){return;}
    
    			detail = triggerEvent(elem, 'lazyunveilread').detail;
    
    			if(isAuto){
    				 autoSizer.updateElem(elem, true, elem.offsetWidth);
    			}
    
    			elem._lazyRace = true;
    			isLoading++;
    
    			lazyUnveil(elem, detail, isAuto, sizes, isImg);
    		};
    
    		var onload = function(){
    			if(isCompleted){return;}
    			if(Date.now() - started < 999){
    				setTimeout(onload, 999);
    				return;
    			}
    			var afterScroll = debounce(function(){
    				lazySizesConfig.loadMode = 3;
    				throttledCheckElements();
    			});
    
    			isCompleted = true;
    
    			lazySizesConfig.loadMode = 3;
    
    			throttledCheckElements();
    
    			addEventListener('scroll', function(){
    				if(lazySizesConfig.loadMode == 3){
    					lazySizesConfig.loadMode = 2;
    				}
    				afterScroll();
    			}, true);
    		};
    
    		return {
    			_: function(){
    				started = Date.now();
    
    				lazyloadElems = document.getElementsByClassName(lazySizesConfig.lazyClass);
    				preloadElems = document.getElementsByClassName(lazySizesConfig.lazyClass + ' ' + lazySizesConfig.preloadClass);
    				hFac = lazySizesConfig.hFac;
    
    				addEventListener('scroll', throttledCheckElements, true);
    
    				addEventListener('resize', throttledCheckElements, true);
    
    				if(window.MutationObserver){
    					new MutationObserver( throttledCheckElements ).observe( docElem, {childList: true, subtree: true, attributes: true} );
    				} else {
    					docElem[_addEventListener]('DOMNodeInserted', throttledCheckElements, true);
    					docElem[_addEventListener]('DOMAttrModified', throttledCheckElements, true);
    					setInterval(throttledCheckElements, 999);
    				}
    
    				addEventListener('hashchange', throttledCheckElements, true);
    
    				//, 'fullscreenchange'
    				['focus', 'mouseover', 'click', 'load', 'transitionend', 'animationend', 'webkitAnimationEnd'].forEach(function(name){
    					document[_addEventListener](name, throttledCheckElements, true);
    				});
    
    				if((/d$|^c/.test(document.readyState))){
    					onload();
    				} else {
    					addEventListener('load', onload);
    					document[_addEventListener]('DOMContentLoaded', throttledCheckElements);
    					setTimeout(onload, 20000);
    				}
    
    				if(lazyloadElems.length){
    					checkElements();
    					rAF._lsFlush();
    				} else {
    					throttledCheckElements();
    				}
    			},
    			checkElems: throttledCheckElements,
    			unveil: unveilElement
    		};
    	})();
    
    
    	var autoSizer = (function(){
    		var autosizesElems;
    
    		var sizeElement = rAFIt(function(elem, parent, event, width){
    			var sources, i, len;
    			elem._lazysizesWidth = width;
    			width += 'px';
    
    			elem.setAttribute('sizes', width);
    
    			if(regPicture.test(parent.nodeName || '')){
    				sources = parent.getElementsByTagName('source');
    				for(i = 0, len = sources.length; i < len; i++){
    					sources[i].setAttribute('sizes', width);
    				}
    			}
    
    			if(!event.detail.dataAttr){
    				updatePolyfill(elem, event.detail);
    			}
    		});
    		var getSizeElement = function (elem, dataAttr, width){
    			var event;
    			var parent = elem.parentNode;
    
    			if(parent){
    				width = getWidth(elem, parent, width);
    				event = triggerEvent(elem, 'lazybeforesizes', {width: width, dataAttr: !!dataAttr});
    
    				if(!event.defaultPrevented){
    					width = event.detail.width;
    
    					if(width && width !== elem._lazysizesWidth){
    						sizeElement(elem, parent, event, width);
    					}
    				}
    			}
    		};
    
    		var updateElementsSizes = function(){
    			var i;
    			var len = autosizesElems.length;
    			if(len){
    				i = 0;
    
    				for(; i < len; i++){
    					getSizeElement(autosizesElems[i]);
    				}
    			}
    		};
    
    		var debouncedUpdateElementsSizes = debounce(updateElementsSizes);
    
    		return {
    			_: function(){
    				autosizesElems = document.getElementsByClassName(lazySizesConfig.autosizesClass);
    				addEventListener('resize', debouncedUpdateElementsSizes);
    			},
    			checkElems: debouncedUpdateElementsSizes,
    			updateElem: getSizeElement
    		};
    	})();
    
    	var init = function(){
    		if(!init.i){
    			init.i = true;
    			autoSizer._();
    			loader._();
    		}
    	};
    
    	(function(){
    		var prop;
    
    		var lazySizesDefaults = {
    			lazyClass: 'lazyload',
    			loadedClass: 'lazyloaded',
    			loadingClass: 'lazyloading',
    			preloadClass: 'lazypreload',
    			errorClass: 'lazyerror',
    			//strictClass: 'lazystrict',
    			autosizesClass: 'lazyautosizes',
    			srcAttr: 'data-src',
    			srcsetAttr: 'data-srcset',
    			sizesAttr: 'data-sizes',
    			//preloadAfterLoad: false,
    			minSize: 40,
    			customMedia: {},
    			init: true,
    			expFactor: 1.5,
    			hFac: 0.8,
    			loadMode: 2
    		};
    
    		lazySizesConfig = window.lazySizesConfig || window.lazysizesConfig || {};
    
    		for(prop in lazySizesDefaults){
    			if(!(prop in lazySizesConfig)){
    				lazySizesConfig[prop] = lazySizesDefaults[prop];
    			}
    		}
    
    		window.lazySizesConfig = lazySizesConfig;
    
    		setTimeout(function(){
    			if(lazySizesConfig.init){
    				init();
    			}
    		});
    	})();
    
    	return {
    		cfg: lazySizesConfig,
    		autoSizer: autoSizer,
    		loader: loader,
    		init: init,
    		uP: updatePolyfill,
    		aC: addClass,
    		rC: removeClass,
    		hC: hasClass,
    		fire: triggerEvent,
    		gW: getWidth,
    		rAF: rAF,
    	};
    }
    ));
    
  • URL: /components/raw/libs/lazysizes.js
  • Filesystem Path: build/components/01-globals/libs/lazysizes.js
  • Size: 17.2 KB
  • Content:
    (function webpackUniversalModuleDefinition(root, factory) {
    	if(typeof exports === 'object' && typeof module === 'object')
    		module.exports = factory();
    	else if(typeof define === 'function' && define.amd)
    		define([], factory);
    	else {
    		var a = factory();
    		for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
    	}
    })(this, function() {
    return /******/ (function(modules) { // webpackBootstrap
    /******/ 	// The module cache
    /******/ 	var installedModules = {};
    /******/
    /******/ 	// The require function
    /******/ 	function __webpack_require__(moduleId) {
    /******/
    /******/ 		// Check if module is in cache
    /******/ 		if(installedModules[moduleId])
    /******/ 			return installedModules[moduleId].exports;
    /******/
    /******/ 		// Create a new module (and put it into the cache)
    /******/ 		var module = installedModules[moduleId] = {
    /******/ 			exports: {},
    /******/ 			id: moduleId,
    /******/ 			loaded: false
    /******/ 		};
    /******/
    /******/ 		// Execute the module function
    /******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
    /******/
    /******/ 		// Flag the module as loaded
    /******/ 		module.loaded = 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;
    /******/
    /******/ 	// __webpack_public_path__
    /******/ 	__webpack_require__.p = "";
    /******/
    /******/ 	// Load entry module and return exports
    /******/ 	return __webpack_require__(0);
    /******/ })
    /************************************************************************/
    /******/ ([
    /* 0 */
    /***/ function(module, exports, __webpack_require__) {
    
    	module.exports = __webpack_require__(1);
    
    
    /***/ },
    /* 1 */
    /***/ function(module, exports, __webpack_require__) {
    
    	'use strict';
    	
    	Object.defineProperty(exports, "__esModule", {
    	    value: true
    	});
    	
    	var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; /* globals jQuery */
    	
    	exports.lory = lory;
    	
    	var _detectPrefixes = __webpack_require__(2);
    	
    	var _detectPrefixes2 = _interopRequireDefault(_detectPrefixes);
    	
    	var _dispatchEvent = __webpack_require__(3);
    	
    	var _dispatchEvent2 = _interopRequireDefault(_dispatchEvent);
    	
    	var _defaults = __webpack_require__(5);
    	
    	var _defaults2 = _interopRequireDefault(_defaults);
    	
    	function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
    	
    	var slice = Array.prototype.slice;
    	
    	function lory(slider, opts) {
    	    var position = void 0;
    	    var slidesWidth = void 0;
    	    var frameWidth = void 0;
    	    var slides = void 0;
    	
    	    /**
    	     * slider DOM elements
    	     */
    	    var frame = void 0;
    	    var slideContainer = void 0;
    	    var prevCtrl = void 0;
    	    var nextCtrl = void 0;
    	    var prefixes = void 0;
    	    var transitionEndCallback = void 0;
    	
    	    var index = 0;
    	    var options = {};
    	
    	    /**
    	     * if object is jQuery convert to native DOM element
    	     */
    	    if (typeof jQuery !== 'undefined' && slider instanceof jQuery) {
    	        slider = slider[0];
    	    }
    	
    	    /**
    	     * private
    	     * set active class to element which is the current slide
    	     */
    	    function setActiveElement(slides, currentIndex) {
    	        var _options = options,
    	            classNameActiveSlide = _options.classNameActiveSlide;
    	
    	
    	        slides.forEach(function (element, index) {
    	            if (element.classList.contains(classNameActiveSlide)) {
    	                element.classList.remove(classNameActiveSlide);
    	            }
    	        });
    	
    	        slides[currentIndex].classList.add(classNameActiveSlide);
    	    }
    	
    	    /**
    	     * private
    	     * setupInfinite: function to setup if infinite is set
    	     *
    	     * @param  {array} slideArray
    	     * @return {array} array of updated slideContainer elements
    	     */
    	    function setupInfinite(slideArray) {
    	        var _options2 = options,
    	            infinite = _options2.infinite;
    	
    	
    	        var front = slideArray.slice(0, infinite);
    	        var back = slideArray.slice(slideArray.length - infinite, slideArray.length);
    	
    	        front.forEach(function (element) {
    	            var cloned = element.cloneNode(true);
    	
    	            slideContainer.appendChild(cloned);
    	        });
    	
    	        back.reverse().forEach(function (element) {
    	            var cloned = element.cloneNode(true);
    	
    	            slideContainer.insertBefore(cloned, slideContainer.firstChild);
    	        });
    	
    	        slideContainer.addEventListener(prefixes.transitionEnd, onTransitionEnd);
    	
    	        return slice.call(slideContainer.children);
    	    }
    	
    	    /**
    	     * [dispatchSliderEvent description]
    	     * @return {[type]} [description]
    	     */
    	    function dispatchSliderEvent(phase, type, detail) {
    	        (0, _dispatchEvent2.default)(slider, phase + '.lory.' + type, detail);
    	    }
    	
    	    /**
    	     * translates to a given position in a given time in milliseconds
    	     *
    	     * @to        {number} number in pixels where to translate to
    	     * @duration  {number} time in milliseconds for the transistion
    	     * @ease      {string} easing css property
    	     */
    	    function translate(to, duration, ease) {
    	        var style = slideContainer && slideContainer.style;
    	
    	        if (style) {
    	            style[prefixes.transition + 'TimingFunction'] = ease;
    	            style[prefixes.transition + 'Duration'] = duration + 'ms';
    	
    	            if (prefixes.hasTranslate3d) {
    	                style[prefixes.transform] = 'translate3d(' + to + 'px, 0, 0)';
    	            } else {
    	                style[prefixes.transform] = 'translate(' + to + 'px, 0)';
    	            }
    	        }
    	    }
    	
    	    /**
    	     * slidefunction called by prev, next & touchend
    	     *
    	     * determine nextIndex and slide to next postion
    	     * under restrictions of the defined options
    	     *
    	     * @direction  {boolean}
    	     */
    	    function slide(nextIndex, direction) {
    	        var _options3 = options,
    	            slideSpeed = _options3.slideSpeed,
    	            slidesToScroll = _options3.slidesToScroll,
    	            infinite = _options3.infinite,
    	            rewind = _options3.rewind,
    	            rewindSpeed = _options3.rewindSpeed,
    	            ease = _options3.ease,
    	            classNameActiveSlide = _options3.classNameActiveSlide;
    	
    	
    	        var duration = slideSpeed;
    	
    	        var nextSlide = direction ? index + 1 : index - 1;
    	        var maxOffset = Math.round(slidesWidth - frameWidth);
    	
    	        dispatchSliderEvent('before', 'slide', {
    	            index: index,
    	            nextSlide: nextSlide
    	        });
    	
    	        /**
    	         * Reset control classes
    	         */
    	        if (prevCtrl) {
    	            prevCtrl.classList.remove('disabled');
    	        }
    	        if (nextCtrl) {
    	            nextCtrl.classList.remove('disabled');
    	        }
    	
    	        if (typeof nextIndex !== 'number') {
    	            if (direction) {
    	                nextIndex = index + slidesToScroll;
    	            } else {
    	                nextIndex = index - slidesToScroll;
    	            }
    	        }
    	
    	        nextIndex = Math.min(Math.max(nextIndex, 0), slides.length - 1);
    	
    	        if (infinite && direction === undefined) {
    	            nextIndex += infinite;
    	        }
    	
    	        var nextOffset = Math.min(Math.max(slides[nextIndex].offsetLeft * -1, maxOffset * -1), 0);
    	
    	        if (rewind && Math.abs(position.x) === maxOffset && direction) {
    	            nextOffset = 0;
    	            nextIndex = 0;
    	            duration = rewindSpeed;
    	        }
    	
    	        /**
    	         * translate to the nextOffset by a defined duration and ease function
    	         */
    	        translate(nextOffset, duration, ease);
    	
    	        /**
    	         * update the position with the next position
    	         */
    	        position.x = nextOffset;
    	
    	        /**
    	         * update the index with the nextIndex only if
    	         * the offset of the nextIndex is in the range of the maxOffset
    	         */
    	        if (slides[nextIndex].offsetLeft <= maxOffset) {
    	            index = nextIndex;
    	        }
    	
    	        if (infinite && (nextIndex === slides.length - infinite || nextIndex === 0)) {
    	            if (direction) {
    	                index = infinite;
    	            }
    	
    	            if (!direction) {
    	                index = slides.length - infinite * 2;
    	            }
    	
    	            position.x = slides[index].offsetLeft * -1;
    	
    	            transitionEndCallback = function transitionEndCallback() {
    	                translate(slides[index].offsetLeft * -1, 0, undefined);
    	            };
    	        }
    	
    	        if (classNameActiveSlide) {
    	            setActiveElement(slice.call(slides), index);
    	        }
    	
    	        /**
    	         * update classes for next and prev arrows
    	         * based on user settings
    	         */
    	        if (prevCtrl && !infinite && nextIndex === 0) {
    	            prevCtrl.classList.add('disabled');
    	        }
    	
    	        if (nextCtrl && !infinite && !rewind && nextIndex + 1 === slides.length) {
    	            nextCtrl.classList.add('disabled');
    	        }
    	
    	        dispatchSliderEvent('after', 'slide', {
    	            currentSlide: index
    	        });
    	    }
    	
    	    /**
    	     * public
    	     * setup function
    	     */
    	    function setup() {
    	        dispatchSliderEvent('before', 'init');
    	
    	        prefixes = (0, _detectPrefixes2.default)();
    	        options = _extends({}, _defaults2.default, opts);
    	
    	        var _options4 = options,
    	            classNameFrame = _options4.classNameFrame,
    	            classNameSlideContainer = _options4.classNameSlideContainer,
    	            classNamePrevCtrl = _options4.classNamePrevCtrl,
    	            classNameNextCtrl = _options4.classNameNextCtrl,
    	            enableMouseEvents = _options4.enableMouseEvents,
    	            classNameActiveSlide = _options4.classNameActiveSlide;
    	
    	
    	        frame = slider.getElementsByClassName(classNameFrame)[0];
    	        slideContainer = frame.getElementsByClassName(classNameSlideContainer)[0];
    	        prevCtrl = slider.getElementsByClassName(classNamePrevCtrl)[0];
    	        nextCtrl = slider.getElementsByClassName(classNameNextCtrl)[0];
    	
    	        position = {
    	            x: slideContainer.offsetLeft,
    	            y: slideContainer.offsetTop
    	        };
    	
    	        if (options.infinite) {
    	            slides = setupInfinite(slice.call(slideContainer.children));
    	        } else {
    	            slides = slice.call(slideContainer.children);
    	
    	            if (prevCtrl) {
    	                prevCtrl.classList.add('disabled');
    	            }
    	
    	            if (nextCtrl && slides.length === 1 && !options.rewind) {
    	                nextCtrl.classList.add('disabled');
    	            }
    	        }
    	
    	        reset();
    	
    	        if (classNameActiveSlide) {
    	            setActiveElement(slides, index);
    	        }
    	
    	        if (prevCtrl && nextCtrl) {
    	            prevCtrl.addEventListener('click', prev);
    	            nextCtrl.addEventListener('click', next);
    	        }
    	
    	        frame.addEventListener('touchstart', onTouchstart);
    	
    	        if (enableMouseEvents) {
    	            frame.addEventListener('mousedown', onTouchstart);
    	            frame.addEventListener('click', onClick);
    	        }
    	
    	        options.window.addEventListener('resize', onResize);
    	
    	        dispatchSliderEvent('after', 'init');
    	    }
    	
    	    /**
    	     * public
    	     * reset function: called on resize
    	     */
    	    function reset() {
    	        var _options5 = options,
    	            infinite = _options5.infinite,
    	            ease = _options5.ease,
    	            rewindSpeed = _options5.rewindSpeed,
    	            rewindOnResize = _options5.rewindOnResize,
    	            classNameActiveSlide = _options5.classNameActiveSlide;
    	
    	
    	        slidesWidth = slideContainer.getBoundingClientRect().width || slideContainer.offsetWidth;
    	        frameWidth = frame.getBoundingClientRect().width || frame.offsetWidth;
    	
    	        if (frameWidth === slidesWidth) {
    	            slidesWidth = slides.reduce(function (previousValue, slide) {
    	                return previousValue + slide.getBoundingClientRect().width || slide.offsetWidth;
    	            }, 0);
    	        }
    	
    	        if (rewindOnResize) {
    	            index = 0;
    	        } else {
    	            ease = null;
    	            rewindSpeed = 0;
    	        }
    	
    	        if (infinite) {
    	            translate(slides[index + infinite].offsetLeft * -1, 0, null);
    	
    	            index = index + infinite;
    	            position.x = slides[index].offsetLeft * -1;
    	        } else {
    	            translate(slides[index].offsetLeft * -1, rewindSpeed, ease);
    	            position.x = slides[index].offsetLeft * -1;
    	        }
    	
    	        if (classNameActiveSlide) {
    	            setActiveElement(slice.call(slides), index);
    	        }
    	    }
    	
    	    /**
    	     * public
    	     * slideTo: called on clickhandler
    	     */
    	    function slideTo(index) {
    	        slide(index);
    	    }
    	
    	    /**
    	     * public
    	     * returnIndex function: called on clickhandler
    	     */
    	    function returnIndex() {
    	        return index - options.infinite || 0;
    	    }
    	
    	    /**
    	     * public
    	     * prev function: called on clickhandler
    	     */
    	    function prev() {
    	        slide(false, false);
    	    }
    	
    	    /**
    	     * public
    	     * next function: called on clickhandler
    	     */
    	    function next() {
    	        slide(false, true);
    	    }
    	
    	    /**
    	     * public
    	     * destroy function: called to gracefully destroy the lory instance
    	     */
    	    function destroy() {
    	        dispatchSliderEvent('before', 'destroy');
    	
    	        // remove event listeners
    	        frame.removeEventListener(prefixes.transitionEnd, onTransitionEnd);
    	        frame.removeEventListener('touchstart', onTouchstart);
    	        frame.removeEventListener('touchmove', onTouchmove);
    	        frame.removeEventListener('touchend', onTouchend);
    	        frame.removeEventListener('mousemove', onTouchmove);
    	        frame.removeEventListener('mousedown', onTouchstart);
    	        frame.removeEventListener('mouseup', onTouchend);
    	        frame.removeEventListener('mouseleave', onTouchend);
    	        frame.removeEventListener('click', onClick);
    	
    	        options.window.removeEventListener('resize', onResize);
    	
    	        if (prevCtrl) {
    	            prevCtrl.removeEventListener('click', prev);
    	        }
    	
    	        if (nextCtrl) {
    	            nextCtrl.removeEventListener('click', next);
    	        }
    	
    	        // remove cloned slides if infinite is set
    	        if (options.infinite) {
    	            Array.apply(null, Array(options.infinite)).forEach(function () {
    	                slideContainer.removeChild(slideContainer.firstChild);
    	                slideContainer.removeChild(slideContainer.lastChild);
    	            });
    	        }
    	
    	        dispatchSliderEvent('after', 'destroy');
    	    }
    	
    	    // event handling
    	
    	    var touchOffset = void 0;
    	    var delta = void 0;
    	    var isScrolling = void 0;
    	
    	    function onTransitionEnd() {
    	        if (transitionEndCallback) {
    	            transitionEndCallback();
    	
    	            transitionEndCallback = undefined;
    	        }
    	    }
    	
    	    function onTouchstart(event) {
    	        var _options6 = options,
    	            enableMouseEvents = _options6.enableMouseEvents;
    	
    	        var touches = event.touches ? event.touches[0] : event;
    	
    	        if (enableMouseEvents) {
    	            frame.addEventListener('mousemove', onTouchmove);
    	            frame.addEventListener('mouseup', onTouchend);
    	            frame.addEventListener('mouseleave', onTouchend);
    	        }
    	
    	        frame.addEventListener('touchmove', onTouchmove);
    	        frame.addEventListener('touchend', onTouchend);
    	
    	        var pageX = touches.pageX,
    	            pageY = touches.pageY;
    	
    	
    	        touchOffset = {
    	            x: pageX,
    	            y: pageY,
    	            time: Date.now()
    	        };
    	
    	        isScrolling = undefined;
    	
    	        delta = {};
    	
    	        dispatchSliderEvent('on', 'touchstart', {
    	            event: event
    	        });
    	    }
    	
    	    function onTouchmove(event) {
    	        var touches = event.touches ? event.touches[0] : event;
    	        var pageX = touches.pageX,
    	            pageY = touches.pageY;
    	
    	
    	        delta = {
    	            x: pageX - touchOffset.x,
    	            y: pageY - touchOffset.y
    	        };
    	
    	        if (typeof isScrolling === 'undefined') {
    	            isScrolling = !!(isScrolling || Math.abs(delta.x) < Math.abs(delta.y));
    	        }
    	
    	        if (!isScrolling && touchOffset) {
    	            event.preventDefault();
    	            translate(position.x + delta.x, 0, null);
    	        }
    	
    	        // may be
    	        dispatchSliderEvent('on', 'touchmove', {
    	            event: event
    	        });
    	    }
    	
    	    function onTouchend(event) {
    	        /**
    	         * time between touchstart and touchend in milliseconds
    	         * @duration {number}
    	         */
    	        var duration = touchOffset ? Date.now() - touchOffset.time : undefined;
    	
    	        /**
    	         * is valid if:
    	         *
    	         * -> swipe attempt time is over 300 ms
    	         * and
    	         * -> swipe distance is greater than 25px
    	         * or
    	         * -> swipe distance is more then a third of the swipe area
    	         *
    	         * @isValidSlide {Boolean}
    	         */
    	        var isValid = Number(duration) < 300 && Math.abs(delta.x) > 25 || Math.abs(delta.x) > frameWidth / 3;
    	
    	        /**
    	         * is out of bounds if:
    	         *
    	         * -> index is 0 and delta x is greater than 0
    	         * or
    	         * -> index is the last slide and delta is smaller than 0
    	         *
    	         * @isOutOfBounds {Boolean}
    	         */
    	        var isOutOfBounds = !index && delta.x > 0 || index === slides.length - 1 && delta.x < 0;
    	
    	        var direction = delta.x < 0;
    	
    	        if (!isScrolling) {
    	            if (isValid && !isOutOfBounds) {
    	                slide(false, direction);
    	            } else {
    	                translate(position.x, options.snapBackSpeed);
    	            }
    	        }
    	
    	        touchOffset = undefined;
    	
    	        /**
    	         * remove eventlisteners after swipe attempt
    	         */
    	        frame.removeEventListener('touchmove', onTouchmove);
    	        frame.removeEventListener('touchend', onTouchend);
    	        frame.removeEventListener('mousemove', onTouchmove);
    	        frame.removeEventListener('mouseup', onTouchend);
    	        frame.removeEventListener('mouseleave', onTouchend);
    	
    	        dispatchSliderEvent('on', 'touchend', {
    	            event: event
    	        });
    	    }
    	
    	    function onClick(event) {
    	        if (delta.x) {
    	            event.preventDefault();
    	        }
    	    }
    	
    	    function onResize(event) {
    	        reset();
    	
    	        dispatchSliderEvent('on', 'resize', {
    	            event: event
    	        });
    	    }
    	
    	    // trigger initial setup
    	    setup();
    	
    	    // expose public api
    	    return {
    	        setup: setup,
    	        reset: reset,
    	        slideTo: slideTo,
    	        returnIndex: returnIndex,
    	        prev: prev,
    	        next: next,
    	        destroy: destroy
    	    };
    	}
    
    /***/ },
    /* 2 */
    /***/ function(module, exports) {
    
    	/* WEBPACK VAR INJECTION */(function(global) {'use strict';
    	
    	Object.defineProperty(exports, "__esModule", {
    	    value: true
    	});
    	exports.default = detectPrefixes;
    	/**
    	 * Detecting prefixes for saving time and bytes
    	 */
    	function detectPrefixes() {
    	    var transform = void 0;
    	    var transition = void 0;
    	    var transitionEnd = void 0;
    	    var hasTranslate3d = void 0;
    	
    	    (function () {
    	        var el = document.createElement('_');
    	        var style = el.style;
    	
    	        var prop = void 0;
    	
    	        if (style[prop = 'webkitTransition'] === '') {
    	            transitionEnd = 'webkitTransitionEnd';
    	            transition = prop;
    	        }
    	
    	        if (style[prop = 'transition'] === '') {
    	            transitionEnd = 'transitionend';
    	            transition = prop;
    	        }
    	
    	        if (style[prop = 'webkitTransform'] === '') {
    	            transform = prop;
    	        }
    	
    	        if (style[prop = 'msTransform'] === '') {
    	            transform = prop;
    	        }
    	
    	        if (style[prop = 'transform'] === '') {
    	            transform = prop;
    	        }
    	
    	        document.body.insertBefore(el, null);
    	        style[transform] = 'translate3d(0, 0, 0)';
    	        hasTranslate3d = !!global.getComputedStyle(el).getPropertyValue(transform);
    	        document.body.removeChild(el);
    	    })();
    	
    	    return {
    	        transform: transform,
    	        transition: transition,
    	        transitionEnd: transitionEnd,
    	        hasTranslate3d: hasTranslate3d
    	    };
    	}
    	/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
    
    /***/ },
    /* 3 */
    /***/ function(module, exports, __webpack_require__) {
    
    	'use strict';
    	
    	Object.defineProperty(exports, "__esModule", {
    	    value: true
    	});
    	exports.default = dispatchEvent;
    	
    	var _customEvent = __webpack_require__(4);
    	
    	var _customEvent2 = _interopRequireDefault(_customEvent);
    	
    	function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
    	
    	/**
    	 * dispatch custom events
    	 *
    	 * @param  {element} el         slideshow element
    	 * @param  {string}  type       custom event name
    	 * @param  {object}  detail     custom detail information
    	 */
    	function dispatchEvent(target, type, detail) {
    	    var event = new _customEvent2.default(type, {
    	        bubbles: true,
    	        cancelable: true,
    	        detail: detail
    	    });
    	
    	    target.dispatchEvent(event);
    	}
    
    /***/ },
    /* 4 */
    /***/ function(module, exports) {
    
    	/* WEBPACK VAR INJECTION */(function(global) {
    	var NativeCustomEvent = global.CustomEvent;
    	
    	function useNative () {
    	  try {
    	    var p = new NativeCustomEvent('cat', { detail: { foo: 'bar' } });
    	    return  'cat' === p.type && 'bar' === p.detail.foo;
    	  } catch (e) {
    	  }
    	  return false;
    	}
    	
    	/**
    	 * Cross-browser `CustomEvent` constructor.
    	 *
    	 * https://developer.mozilla.org/en-US/docs/Web/API/CustomEvent.CustomEvent
    	 *
    	 * @public
    	 */
    	
    	module.exports = useNative() ? NativeCustomEvent :
    	
    	// IE >= 9
    	'undefined' !== typeof document && 'function' === typeof document.createEvent ? function CustomEvent (type, params) {
    	  var e = document.createEvent('CustomEvent');
    	  if (params) {
    	    e.initCustomEvent(type, params.bubbles, params.cancelable, params.detail);
    	  } else {
    	    e.initCustomEvent(type, false, false, void 0);
    	  }
    	  return e;
    	} :
    	
    	// IE <= 8
    	function CustomEvent (type, params) {
    	  var e = document.createEventObject();
    	  e.type = type;
    	  if (params) {
    	    e.bubbles = Boolean(params.bubbles);
    	    e.cancelable = Boolean(params.cancelable);
    	    e.detail = params.detail;
    	  } else {
    	    e.bubbles = false;
    	    e.cancelable = false;
    	    e.detail = void 0;
    	  }
    	  return e;
    	}
    	
    	/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
    
    /***/ },
    /* 5 */
    /***/ function(module, exports) {
    
    	'use strict';
    	
    	Object.defineProperty(exports, "__esModule", {
    	  value: true
    	});
    	exports.default = {
    	  /**
    	   * slides scrolled at once
    	   * @slidesToScroll {Number}
    	   */
    	  slidesToScroll: 1,
    	
    	  /**
    	   * time in milliseconds for the animation of a valid slide attempt
    	   * @slideSpeed {Number}
    	   */
    	  slideSpeed: 300,
    	
    	  /**
    	   * time in milliseconds for the animation of the rewind after the last slide
    	   * @rewindSpeed {Number}
    	   */
    	  rewindSpeed: 600,
    	
    	  /**
    	   * time for the snapBack of the slider if the slide attempt was not valid
    	   * @snapBackSpeed {Number}
    	   */
    	  snapBackSpeed: 200,
    	
    	  /**
    	   * Basic easing functions: https://developer.mozilla.org/de/docs/Web/CSS/transition-timing-function
    	   * cubic bezier easing functions: http://easings.net/de
    	   * @ease {String}
    	   */
    	  ease: 'ease',
    	
    	  /**
    	   * if slider reached the last slide, with next click the slider goes back to the startindex.
    	   * use infinite or rewind, not both
    	   * @rewind {Boolean}
    	   */
    	  rewind: false,
    	
    	  /**
    	   * number of visible slides or false
    	   * use infinite or rewind, not both
    	   * @infinite {number}
    	   */
    	  infinite: false,
    	
    	  /**
    	   * class name for slider frame
    	   * @classNameFrame {string}
    	   */
    	  classNameFrame: 'js_frame',
    	
    	  /**
    	   * class name for slides container
    	   * @classNameSlideContainer {string}
    	   */
    	  classNameSlideContainer: 'js_slides',
    	
    	  /**
    	   * class name for slider prev control
    	   * @classNamePrevCtrl {string}
    	   */
    	  classNamePrevCtrl: 'js_prev',
    	
    	  /**
    	   * class name for slider next control
    	   * @classNameNextCtrl {string}
    	   */
    	  classNameNextCtrl: 'js_next',
    	
    	  /**
    	   * class name for current active slide
    	   * if emptyString then no class is set
    	   * @classNameActiveSlide {string}
    	   */
    	  classNameActiveSlide: 'active',
    	
    	  /**
    	   * enables mouse events for swiping on desktop devices
    	   * @enableMouseEvents {boolean}
    	   */
    	  enableMouseEvents: false,
    	
    	  /**
    	   * window instance
    	   * @window {object}
    	   */
    	  window: window,
    	
    	  /**
    	   * If false, slides lory to the first slide on window resize.
    	   * @rewindOnResize {boolean}
    	   */
    	  rewindOnResize: true
    	};
    
    /***/ }
    /******/ ])
    });
    ;
  • URL: /components/raw/libs/lory.js
  • Filesystem Path: build/components/01-globals/libs/lory.js
  • Size: 25.4 KB
  • Content:
    /*! nouislider - 10.0.0 - 2017-05-28 14:52:49 */
    
    !function(a){"function"==typeof define&&define.amd?define([],a):"object"==typeof exports?module.exports=a():window.noUiSlider=a()}(function(){"use strict";function a(a){return"object"==typeof a&&"function"==typeof a.to&&"function"==typeof a.from}function b(a){a.parentElement.removeChild(a)}function c(a){a.preventDefault()}function d(a){return a.filter(function(a){return this[a]?!1:this[a]=!0},{})}function e(a,b){return Math.round(a/b)*b}function f(a,b){var c=a.getBoundingClientRect(),d=a.ownerDocument,e=d.documentElement,f=o(d);return/webkit.*Chrome.*Mobile/i.test(navigator.userAgent)&&(f.x=0),b?c.top+f.y-e.clientTop:c.left+f.x-e.clientLeft}function g(a){return"number"==typeof a&&!isNaN(a)&&isFinite(a)}function h(a,b,c){c>0&&(l(a,b),setTimeout(function(){m(a,b)},c))}function i(a){return Math.max(Math.min(a,100),0)}function j(a){return Array.isArray(a)?a:[a]}function k(a){a=String(a);var b=a.split(".");return b.length>1?b[1].length:0}function l(a,b){a.classList?a.classList.add(b):a.className+=" "+b}function m(a,b){a.classList?a.classList.remove(b):a.className=a.className.replace(new RegExp("(^|\\b)"+b.split(" ").join("|")+"(\\b|$)","gi")," ")}function n(a,b){return a.classList?a.classList.contains(b):new RegExp("\\b"+b+"\\b").test(a.className)}function o(a){var b=void 0!==window.pageXOffset,c="CSS1Compat"===(a.compatMode||""),d=b?window.pageXOffset:c?a.documentElement.scrollLeft:a.body.scrollLeft,e=b?window.pageYOffset:c?a.documentElement.scrollTop:a.body.scrollTop;return{x:d,y:e}}function p(){return window.navigator.pointerEnabled?{start:"pointerdown",move:"pointermove",end:"pointerup"}:window.navigator.msPointerEnabled?{start:"MSPointerDown",move:"MSPointerMove",end:"MSPointerUp"}:{start:"mousedown touchstart",move:"mousemove touchmove",end:"mouseup touchend"}}function q(){var a=!1;try{var b=Object.defineProperty({},"passive",{get:function(){a=!0}});window.addEventListener("test",null,b)}catch(c){}return a}function r(){return window.CSS&&CSS.supports&&CSS.supports("touch-action","none")}function s(a,b){return 100/(b-a)}function t(a,b){return 100*b/(a[1]-a[0])}function u(a,b){return t(a,a[0]<0?b+Math.abs(a[0]):b-a[0])}function v(a,b){return b*(a[1]-a[0])/100+a[0]}function w(a,b){for(var c=1;a>=b[c];)c+=1;return c}function x(a,b,c){if(c>=a.slice(-1)[0])return 100;var d,e,f,g,h=w(c,a);return d=a[h-1],e=a[h],f=b[h-1],g=b[h],f+u([d,e],c)/s(f,g)}function y(a,b,c){if(c>=100)return a.slice(-1)[0];var d,e,f,g,h=w(c,b);return d=a[h-1],e=a[h],f=b[h-1],g=b[h],v([d,e],(c-f)*s(f,g))}function z(a,b,c,d){if(100===d)return d;var f,g,h=w(d,a);return c?(f=a[h-1],g=a[h],d-f>(g-f)/2?g:f):b[h-1]?a[h-1]+e(d-a[h-1],b[h-1]):d}function A(a,b,c){var d;if("number"==typeof b&&(b=[b]),"[object Array]"!==Object.prototype.toString.call(b))throw new Error("noUiSlider ("+$+"): 'range' contains invalid value.");if(d="min"===a?0:"max"===a?100:parseFloat(a),!g(d)||!g(b[0]))throw new Error("noUiSlider ("+$+"): 'range' value isn't numeric.");c.xPct.push(d),c.xVal.push(b[0]),d?c.xSteps.push(isNaN(b[1])?!1:b[1]):isNaN(b[1])||(c.xSteps[0]=b[1]),c.xHighestCompleteStep.push(0)}function B(a,b,c){if(!b)return!0;c.xSteps[a]=t([c.xVal[a],c.xVal[a+1]],b)/s(c.xPct[a],c.xPct[a+1]);var d=(c.xVal[a+1]-c.xVal[a])/c.xNumSteps[a],e=Math.ceil(Number(d.toFixed(3))-1),f=c.xVal[a]+c.xNumSteps[a]*e;c.xHighestCompleteStep[a]=f}function C(a,b,c){this.xPct=[],this.xVal=[],this.xSteps=[c||!1],this.xNumSteps=[!1],this.xHighestCompleteStep=[],this.snap=b;var d,e=[];for(d in a)a.hasOwnProperty(d)&&e.push([a[d],d]);for(e.sort(e.length&&"object"==typeof e[0][0]?function(a,b){return a[0][0]-b[0][0]}:function(a,b){return a[0]-b[0]}),d=0;d<e.length;d++)A(e[d][1],e[d][0],this);for(this.xNumSteps=this.xSteps.slice(0),d=0;d<this.xNumSteps.length;d++)B(d,this.xNumSteps[d],this)}function D(b){if(a(b))return!0;throw new Error("noUiSlider ("+$+"): 'format' requires 'to' and 'from' methods.")}function E(a,b){if(!g(b))throw new Error("noUiSlider ("+$+"): 'step' is not numeric.");a.singleStep=b}function F(a,b){if("object"!=typeof b||Array.isArray(b))throw new Error("noUiSlider ("+$+"): 'range' is not an object.");if(void 0===b.min||void 0===b.max)throw new Error("noUiSlider ("+$+"): Missing 'min' or 'max' in 'range'.");if(b.min===b.max)throw new Error("noUiSlider ("+$+"): 'range' 'min' and 'max' cannot be equal.");a.spectrum=new C(b,a.snap,a.singleStep)}function G(a,b){if(b=j(b),!Array.isArray(b)||!b.length)throw new Error("noUiSlider ("+$+"): 'start' option is incorrect.");a.handles=b.length,a.start=b}function H(a,b){if(a.snap=b,"boolean"!=typeof b)throw new Error("noUiSlider ("+$+"): 'snap' option must be a boolean.")}function I(a,b){if(a.animate=b,"boolean"!=typeof b)throw new Error("noUiSlider ("+$+"): 'animate' option must be a boolean.")}function J(a,b){if(a.animationDuration=b,"number"!=typeof b)throw new Error("noUiSlider ("+$+"): 'animationDuration' option must be a number.")}function K(a,b){var c,d=[!1];if("lower"===b?b=[!0,!1]:"upper"===b&&(b=[!1,!0]),b===!0||b===!1){for(c=1;c<a.handles;c++)d.push(b);d.push(!1)}else{if(!Array.isArray(b)||!b.length||b.length!==a.handles+1)throw new Error("noUiSlider ("+$+"): 'connect' option doesn't match handle count.");d=b}a.connect=d}function L(a,b){switch(b){case"horizontal":a.ort=0;break;case"vertical":a.ort=1;break;default:throw new Error("noUiSlider ("+$+"): 'orientation' option is invalid.")}}function M(a,b){if(!g(b))throw new Error("noUiSlider ("+$+"): 'margin' option must be numeric.");if(0!==b&&(a.margin=a.spectrum.getMargin(b),!a.margin))throw new Error("noUiSlider ("+$+"): 'margin' option is only supported on linear sliders.")}function N(a,b){if(!g(b))throw new Error("noUiSlider ("+$+"): 'limit' option must be numeric.");if(a.limit=a.spectrum.getMargin(b),!a.limit||a.handles<2)throw new Error("noUiSlider ("+$+"): 'limit' option is only supported on linear sliders with 2 or more handles.")}function O(a,b){if(!g(b))throw new Error("noUiSlider ("+$+"): 'padding' option must be numeric.");if(0!==b){if(a.padding=a.spectrum.getMargin(b),!a.padding)throw new Error("noUiSlider ("+$+"): 'padding' option is only supported on linear sliders.");if(a.padding<0)throw new Error("noUiSlider ("+$+"): 'padding' option must be a positive number.");if(a.padding>=50)throw new Error("noUiSlider ("+$+"): 'padding' option must be less than half the range.")}}function P(a,b){switch(b){case"ltr":a.dir=0;break;case"rtl":a.dir=1;break;default:throw new Error("noUiSlider ("+$+"): 'direction' option was not recognized.")}}function Q(a,b){if("string"!=typeof b)throw new Error("noUiSlider ("+$+"): 'behaviour' must be a string containing options.");var c=b.indexOf("tap")>=0,d=b.indexOf("drag")>=0,e=b.indexOf("fixed")>=0,f=b.indexOf("snap")>=0,g=b.indexOf("hover")>=0;if(e){if(2!==a.handles)throw new Error("noUiSlider ("+$+"): 'fixed' behaviour must be used with 2 handles");M(a,a.start[1]-a.start[0])}a.events={tap:c||f,drag:d,fixed:e,snap:f,hover:g}}function R(a,b){if(b!==!1)if(b===!0){a.tooltips=[];for(var c=0;c<a.handles;c++)a.tooltips.push(!0)}else{if(a.tooltips=j(b),a.tooltips.length!==a.handles)throw new Error("noUiSlider ("+$+"): must pass a formatter for all handles.");a.tooltips.forEach(function(a){if("boolean"!=typeof a&&("object"!=typeof a||"function"!=typeof a.to))throw new Error("noUiSlider ("+$+"): 'tooltips' must be passed a formatter or 'false'.")})}}function S(a,b){a.ariaFormat=b,D(b)}function T(a,b){a.format=b,D(b)}function U(a,b){if(void 0!==b&&"string"!=typeof b&&b!==!1)throw new Error("noUiSlider ("+$+"): 'cssPrefix' must be a string or `false`.");a.cssPrefix=b}function V(a,b){if(void 0!==b&&"object"!=typeof b)throw new Error("noUiSlider ("+$+"): 'cssClasses' must be an object.");if("string"==typeof a.cssPrefix){a.cssClasses={};for(var c in b)b.hasOwnProperty(c)&&(a.cssClasses[c]=a.cssPrefix+b[c])}else a.cssClasses=b}function W(a,b){if(b!==!0&&b!==!1)throw new Error("noUiSlider ("+$+"): 'useRequestAnimationFrame' option should be true (default) or false.");a.useRequestAnimationFrame=b}function X(a){var b={margin:0,limit:0,padding:0,animate:!0,animationDuration:300,ariaFormat:_,format:_},c={step:{r:!1,t:E},start:{r:!0,t:G},connect:{r:!0,t:K},direction:{r:!0,t:P},snap:{r:!1,t:H},animate:{r:!1,t:I},animationDuration:{r:!1,t:J},range:{r:!0,t:F},orientation:{r:!1,t:L},margin:{r:!1,t:M},limit:{r:!1,t:N},padding:{r:!1,t:O},behaviour:{r:!0,t:Q},ariaFormat:{r:!1,t:S},format:{r:!1,t:T},tooltips:{r:!1,t:R},cssPrefix:{r:!1,t:U},cssClasses:{r:!1,t:V},useRequestAnimationFrame:{r:!1,t:W}},d={connect:!1,direction:"ltr",behaviour:"tap",orientation:"horizontal",cssPrefix:"noUi-",cssClasses:{target:"target",base:"base",origin:"origin",handle:"handle",handleLower:"handle-lower",handleUpper:"handle-upper",horizontal:"horizontal",vertical:"vertical",background:"background",connect:"connect",ltr:"ltr",rtl:"rtl",draggable:"draggable",drag:"state-drag",tap:"state-tap",active:"active",tooltip:"tooltip",pips:"pips",pipsHorizontal:"pips-horizontal",pipsVertical:"pips-vertical",marker:"marker",markerHorizontal:"marker-horizontal",markerVertical:"marker-vertical",markerNormal:"marker-normal",markerLarge:"marker-large",markerSub:"marker-sub",value:"value",valueHorizontal:"value-horizontal",valueVertical:"value-vertical",valueNormal:"value-normal",valueLarge:"value-large",valueSub:"value-sub"},useRequestAnimationFrame:!0};a.format&&!a.ariaFormat&&(a.ariaFormat=a.format),Object.keys(c).forEach(function(e){if(void 0===a[e]&&void 0===d[e]){if(c[e].r)throw new Error("noUiSlider ("+$+"): '"+e+"' is required.");return!0}c[e].t(b,void 0===a[e]?d[e]:a[e])}),b.pips=a.pips;var e=[["left","top"],["right","bottom"]];return b.style=e[b.dir][b.ort],b.styleOposite=e[b.dir?0:1][b.ort],b}function Y(a,e,g){function k(a,b){var c=xa.createElement("div");return b&&l(c,b),a.appendChild(c),c}function s(a,b){var c=k(a,e.cssClasses.origin),d=k(c,e.cssClasses.handle);return d.setAttribute("data-handle",b),d.setAttribute("tabindex","0"),d.setAttribute("role","slider"),d.setAttribute("aria-orientation",e.ort?"vertical":"horizontal"),0===b?l(d,e.cssClasses.handleLower):b===e.handles-1&&l(d,e.cssClasses.handleUpper),c}function t(a,b){return b?k(a,e.cssClasses.connect):!1}function u(a,b){ia=[],ja=[],ja.push(t(b,a[0]));for(var c=0;c<e.handles;c++)ia.push(s(b,c)),ra[c]=c,ja.push(t(b,a[c+1]))}function v(a){l(a,e.cssClasses.target),0===e.dir?l(a,e.cssClasses.ltr):l(a,e.cssClasses.rtl),0===e.ort?l(a,e.cssClasses.horizontal):l(a,e.cssClasses.vertical),ha=k(a,e.cssClasses.base)}function w(a,b){return e.tooltips[b]?k(a.firstChild,e.cssClasses.tooltip):!1}function x(){var a=ia.map(w);ea("update",function(b,c,d){if(a[c]){var f=b[c];e.tooltips[c]!==!0&&(f=e.tooltips[c].to(d[c])),a[c].innerHTML=f}})}function y(){ea("update",function(a,b,c,d,f){ra.forEach(function(a){var b=ia[a],d=S(qa,a,0,!0,!0,!0),g=S(qa,a,100,!0,!0,!0),h=f[a],i=e.ariaFormat.to(c[a]);b.children[0].setAttribute("aria-valuemin",d.toFixed(1)),b.children[0].setAttribute("aria-valuemax",g.toFixed(1)),b.children[0].setAttribute("aria-valuenow",h.toFixed(1)),b.children[0].setAttribute("aria-valuetext",i)})})}function z(a,b,c){if("range"===a||"steps"===a)return ta.xVal;if("count"===a){if(!b)throw new Error("noUiSlider ("+$+"): 'values' required for mode 'count'.");var d,e=100/(b-1),f=0;for(b=[];(d=f++*e)<=100;)b.push(d);a="positions"}return"positions"===a?b.map(function(a){return ta.fromStepping(c?ta.getStep(a):a)}):"values"===a?c?b.map(function(a){return ta.fromStepping(ta.getStep(ta.toStepping(a)))}):b:void 0}function A(a,b,c){function e(a,b){return(a+b).toFixed(7)/1}var f={},g=ta.xVal[0],h=ta.xVal[ta.xVal.length-1],i=!1,j=!1,k=0;return c=d(c.slice().sort(function(a,b){return a-b})),c[0]!==g&&(c.unshift(g),i=!0),c[c.length-1]!==h&&(c.push(h),j=!0),c.forEach(function(d,g){var h,l,m,n,o,p,q,r,s,t,u=d,v=c[g+1];if("steps"===b&&(h=ta.xNumSteps[g]),h||(h=v-u),u!==!1&&void 0!==v)for(h=Math.max(h,1e-7),l=u;v>=l;l=e(l,h)){for(n=ta.toStepping(l),o=n-k,r=o/a,s=Math.round(r),t=o/s,m=1;s>=m;m+=1)p=k+m*t,f[p.toFixed(5)]=["x",0];q=c.indexOf(l)>-1?1:"steps"===b?2:0,!g&&i&&(q=0),l===v&&j||(f[n.toFixed(5)]=[l,q]),k=n}}),f}function B(a,b,c){function d(a,b){var c=b===e.cssClasses.value,d=c?j:m,f=c?h:i;return b+" "+d[e.ort]+" "+f[a]}function f(a,f){f[1]=f[1]&&b?b(f[0],f[1]):f[1];var h=k(g,!1);h.className=d(f[1],e.cssClasses.marker),h.style[e.style]=a+"%",f[1]&&(h=k(g,!1),h.className=d(f[1],e.cssClasses.value),h.style[e.style]=a+"%",h.innerText=c.to(f[0]))}var g=xa.createElement("div"),h=[e.cssClasses.valueNormal,e.cssClasses.valueLarge,e.cssClasses.valueSub],i=[e.cssClasses.markerNormal,e.cssClasses.markerLarge,e.cssClasses.markerSub],j=[e.cssClasses.valueHorizontal,e.cssClasses.valueVertical],m=[e.cssClasses.markerHorizontal,e.cssClasses.markerVertical];return l(g,e.cssClasses.pips),l(g,0===e.ort?e.cssClasses.pipsHorizontal:e.cssClasses.pipsVertical),Object.keys(a).forEach(function(b){f(b,a[b])}),g}function C(){la&&(b(la),la=null)}function D(a){C();var b=a.mode,c=a.density||1,d=a.filter||!1,e=a.values||!1,f=a.stepped||!1,g=z(b,e,f),h=A(c,b,g),i=a.format||{to:Math.round};return la=pa.appendChild(B(h,d,i))}function E(){var a=ha.getBoundingClientRect(),b="offset"+["Width","Height"][e.ort];return 0===e.ort?a.width||ha[b]:a.height||ha[b]}function F(a,b,c,d){var f=function(b){return pa.hasAttribute("disabled")?!1:n(pa,e.cssClasses.tap)?!1:(b=G(b,d.pageOffset))?a===ma.start&&void 0!==b.buttons&&b.buttons>1?!1:d.hover&&b.buttons?!1:(oa||b.preventDefault(),b.calcPoint=b.points[e.ort],void c(b,d)):!1},g=[];return a.split(" ").forEach(function(a){b.addEventListener(a,f,oa?{passive:!0}:!1),g.push([a,f])}),g}function G(a,b){var c,d,e=0===a.type.indexOf("touch"),f=0===a.type.indexOf("mouse"),g=0===a.type.indexOf("pointer");if(0===a.type.indexOf("MSPointer")&&(g=!0),e){if(a.touches.length>1)return!1;c=a.changedTouches[0].pageX,d=a.changedTouches[0].pageY}return b=b||o(xa),(f||g)&&(c=a.clientX+b.x,d=a.clientY+b.y),a.pageOffset=b,a.points=[c,d],a.cursor=f||g,a}function H(a){var b=a-f(ha,e.ort),c=100*b/E();return e.dir?100-c:c}function I(a){var b=100,c=!1;return ia.forEach(function(d,e){if(!d.hasAttribute("disabled")){var f=Math.abs(qa[e]-a);b>f&&(c=e,b=f)}}),c}function J(a,b,c,d){var e=c.slice(),f=[!a,a],g=[a,!a];d=d.slice(),a&&d.reverse(),d.length>1?d.forEach(function(a,c){var d=S(e,a,e[a]+b,f[c],g[c],!1);d===!1?b=0:(b=d-e[a],e[a]=d)}):f=g=[!0];var h=!1;d.forEach(function(a,d){h=W(a,c[a]+b,f[d],g[d])||h}),h&&d.forEach(function(a){K("update",a),K("slide",a)})}function K(a,b,c){Object.keys(va).forEach(function(d){var f=d.split(".")[0];a===f&&va[d].forEach(function(a){a.call(ka,ua.map(e.format.to),b,ua.slice(),c||!1,qa.slice())})})}function L(a,b){"mouseout"===a.type&&"HTML"===a.target.nodeName&&null===a.relatedTarget&&N(a,b)}function M(a,b){if(-1===navigator.appVersion.indexOf("MSIE 9")&&0===a.buttons&&0!==b.buttonsProperty)return N(a,b);var c=(e.dir?-1:1)*(a.calcPoint-b.startCalcPoint),d=100*c/b.baseSize;J(c>0,d,b.locations,b.handleNumbers)}function N(a,b){sa&&(m(sa,e.cssClasses.active),sa=!1),a.cursor&&(za.style.cursor="",za.removeEventListener("selectstart",c)),wa.forEach(function(a){ya.removeEventListener(a[0],a[1])}),m(pa,e.cssClasses.drag),V(),b.handleNumbers.forEach(function(a){K("change",a),K("set",a),K("end",a)})}function O(a,b){if(1===b.handleNumbers.length){var d=ia[b.handleNumbers[0]];if(d.hasAttribute("disabled"))return!1;sa=d.children[0],l(sa,e.cssClasses.active)}a.stopPropagation();var f=F(ma.move,ya,M,{startCalcPoint:a.calcPoint,baseSize:E(),pageOffset:a.pageOffset,handleNumbers:b.handleNumbers,buttonsProperty:a.buttons,locations:qa.slice()}),g=F(ma.end,ya,N,{handleNumbers:b.handleNumbers}),h=F("mouseout",ya,L,{handleNumbers:b.handleNumbers});wa=f.concat(g,h),a.cursor&&(za.style.cursor=getComputedStyle(a.target).cursor,ia.length>1&&l(pa,e.cssClasses.drag),za.addEventListener("selectstart",c,!1)),b.handleNumbers.forEach(function(a){K("start",a)})}function P(a){a.stopPropagation();var b=H(a.calcPoint),c=I(b);return c===!1?!1:(e.events.snap||h(pa,e.cssClasses.tap,e.animationDuration),W(c,b,!0,!0),V(),K("slide",c,!0),K("update",c,!0),K("change",c,!0),K("set",c,!0),void(e.events.snap&&O(a,{handleNumbers:[c]})))}function Q(a){var b=H(a.calcPoint),c=ta.getStep(b),d=ta.fromStepping(c);Object.keys(va).forEach(function(a){"hover"===a.split(".")[0]&&va[a].forEach(function(a){a.call(ka,d)})})}function R(a){a.fixed||ia.forEach(function(a,b){F(ma.start,a.children[0],O,{handleNumbers:[b]})}),a.tap&&F(ma.start,ha,P,{}),a.hover&&F(ma.move,ha,Q,{hover:!0}),a.drag&&ja.forEach(function(b,c){if(b!==!1&&0!==c&&c!==ja.length-1){var d=ia[c-1],f=ia[c],g=[b];l(b,e.cssClasses.draggable),a.fixed&&(g.push(d.children[0]),g.push(f.children[0])),g.forEach(function(a){F(ma.start,a,O,{handles:[d,f],handleNumbers:[c-1,c]})})}})}function S(a,b,c,d,f,g){return ia.length>1&&(d&&b>0&&(c=Math.max(c,a[b-1]+e.margin)),f&&b<ia.length-1&&(c=Math.min(c,a[b+1]-e.margin))),ia.length>1&&e.limit&&(d&&b>0&&(c=Math.min(c,a[b-1]+e.limit)),f&&b<ia.length-1&&(c=Math.max(c,a[b+1]-e.limit))),e.padding&&(0===b&&(c=Math.max(c,e.padding)),b===ia.length-1&&(c=Math.min(c,100-e.padding))),c=ta.getStep(c),c=i(c),c!==a[b]||g?c:!1}function T(a){return a+"%"}function U(a,b){qa[a]=b,ua[a]=ta.fromStepping(b);var c=function(){ia[a].style[e.style]=T(b),Y(a),Y(a+1)};window.requestAnimationFrame&&e.useRequestAnimationFrame?window.requestAnimationFrame(c):c()}function V(){ra.forEach(function(a){var b=qa[a]>50?-1:1,c=3+(ia.length+b*a);ia[a].childNodes[0].style.zIndex=c})}function W(a,b,c,d){return b=S(qa,a,b,c,d,!1),b===!1?!1:(U(a,b),!0)}function Y(a){if(ja[a]){var b=0,c=100;0!==a&&(b=qa[a-1]),a!==ja.length-1&&(c=qa[a]),ja[a].style[e.style]=T(b),ja[a].style[e.styleOposite]=T(100-c)}}function Z(a,b){null!==a&&a!==!1&&("number"==typeof a&&(a=String(a)),a=e.format.from(a),a===!1||isNaN(a)||W(b,ta.toStepping(a),!1,!1))}function _(a,b){var c=j(a),d=void 0===qa[0];b=void 0===b?!0:!!b,c.forEach(Z),e.animate&&!d&&h(pa,e.cssClasses.tap,e.animationDuration),ra.forEach(function(a){W(a,qa[a],!0,!1)}),V(),ra.forEach(function(a){K("update",a),null!==c[a]&&b&&K("set",a)})}function aa(a){_(e.start,a)}function ba(){var a=ua.map(e.format.to);return 1===a.length?a[0]:a}function ca(){for(var a in e.cssClasses)e.cssClasses.hasOwnProperty(a)&&m(pa,e.cssClasses[a]);for(;pa.firstChild;)pa.removeChild(pa.firstChild);delete pa.noUiSlider}function da(){return qa.map(function(a,b){var c=ta.getNearbySteps(a),d=ua[b],e=c.thisStep.step,f=null;e!==!1&&d+e>c.stepAfter.startValue&&(e=c.stepAfter.startValue-d),f=d>c.thisStep.startValue?c.thisStep.step:c.stepBefore.step===!1?!1:d-c.stepBefore.highestStep,100===a?e=null:0===a&&(f=null);var g=ta.countStepDecimals();return null!==e&&e!==!1&&(e=Number(e.toFixed(g))),null!==f&&f!==!1&&(f=Number(f.toFixed(g))),[f,e]})}function ea(a,b){va[a]=va[a]||[],va[a].push(b),"update"===a.split(".")[0]&&ia.forEach(function(a,b){K("update",b)})}function fa(a){var b=a&&a.split(".")[0],c=b&&a.substring(b.length);Object.keys(va).forEach(function(a){var d=a.split(".")[0],e=a.substring(d.length);b&&b!==d||c&&c!==e||delete va[a]})}function ga(a,b){var c=ba(),d=["margin","limit","padding","range","animate","snap","step","format"];d.forEach(function(b){void 0!==a[b]&&(g[b]=a[b])});var f=X(g);d.forEach(function(b){void 0!==a[b]&&(e[b]=f[b])}),ta=f.spectrum,e.margin=f.margin,e.limit=f.limit,e.padding=f.padding,e.pips&&D(e.pips),qa=[],_(a.start||c,b)}var ha,ia,ja,ka,la,ma=p(),na=r(),oa=na&&q(),pa=a,qa=[],ra=[],sa=!1,ta=e.spectrum,ua=[],va={},wa=null,xa=a.ownerDocument,ya=xa.documentElement,za=xa.body;if(pa.noUiSlider)throw new Error("noUiSlider ("+$+"): Slider was already initialized.");return v(pa),u(e.connect,ha),ka={destroy:ca,steps:da,on:ea,off:fa,get:ba,set:_,reset:aa,__moveHandles:function(a,b,c){J(a,b,qa,c)},options:g,updateOptions:ga,target:pa,removePips:C,pips:D},R(e.events),_(e.start),e.pips&&D(e.pips),e.tooltips&&x(),y(),ka}function Z(a,b){if(!a||!a.nodeName)throw new Error("noUiSlider ("+$+"): create requires a single element, got: "+a);var c=X(b,a),d=Y(a,c,b);return a.noUiSlider=d,d}var $="10.0.0";C.prototype.getMargin=function(a){var b=this.xNumSteps[0];if(b&&a/b%1!==0)throw new Error("noUiSlider ("+$+"): 'limit', 'margin' and 'padding' must be divisible by step.");return 2===this.xPct.length?t(this.xVal,a):!1},C.prototype.toStepping=function(a){return a=x(this.xVal,this.xPct,a)},C.prototype.fromStepping=function(a){return y(this.xVal,this.xPct,a)},C.prototype.getStep=function(a){return a=z(this.xPct,this.xSteps,this.snap,a)},C.prototype.getNearbySteps=function(a){var b=w(a,this.xPct);return{stepBefore:{startValue:this.xVal[b-2],step:this.xNumSteps[b-2],highestStep:this.xHighestCompleteStep[b-2]},thisStep:{startValue:this.xVal[b-1],step:this.xNumSteps[b-1],highestStep:this.xHighestCompleteStep[b-1]},stepAfter:{startValue:this.xVal[b-0],step:this.xNumSteps[b-0],highestStep:this.xHighestCompleteStep[b-0]}}},C.prototype.countStepDecimals=function(){var a=this.xNumSteps.map(k);return Math.max.apply(null,a)},C.prototype.convert=function(a){return this.getStep(this.toStepping(a))};var _={to:function(a){return void 0!==a&&a.toFixed(2)},from:Number};return{version:$,create:Z}});
  • URL: /components/raw/libs/nouislider.min.js
  • Filesystem Path: build/components/01-globals/libs/nouislider.min.js
  • Size: 21.2 KB
  • Content:
    !function(root, factory) {
        "function" == typeof define && define.amd ? // AMD. Register as an anonymous module unless amdModuleId is set
        define([], function() {
            return root.svg4everybody = factory();
        }) : "object" == typeof module && module.exports ? // Node. Does not work with strict CommonJS, but
        // only CommonJS-like environments that support module.exports,
        // like Node.
        module.exports = factory() : root.svg4everybody = factory();
    }(this, function() {
        /*! svg4everybody v2.1.4 | github.com/jonathantneal/svg4everybody */
        function embed(parent, svg, target) {
            // if the target exists
            if (target) {
                // create a document fragment to hold the contents of the target
                var fragment = document.createDocumentFragment(), viewBox = !svg.hasAttribute("viewBox") && target.getAttribute("viewBox");
                // conditionally set the viewBox on the svg
                viewBox && svg.setAttribute("viewBox", viewBox);
                // copy the contents of the clone into the fragment
                for (// clone the target
                var clone = target.cloneNode(!0); clone.childNodes.length; ) {
                    fragment.appendChild(clone.firstChild);
                }
                // append the fragment into the svg
                parent.appendChild(fragment);
            }
        }
        function loadreadystatechange(xhr) {
            // listen to changes in the request
            xhr.onreadystatechange = function() {
                // if the request is ready
                if (4 === xhr.readyState) {
                    // get the cached html document
                    var cachedDocument = xhr._cachedDocument;
                    // ensure the cached html document based on the xhr response
                    cachedDocument || (cachedDocument = xhr._cachedDocument = document.implementation.createHTMLDocument(""), 
                    cachedDocument.body.innerHTML = xhr.responseText, xhr._cachedTarget = {}), // clear the xhr embeds list and embed each item
                    xhr._embeds.splice(0).map(function(item) {
                        // get the cached target
                        var target = xhr._cachedTarget[item.id];
                        // ensure the cached target
                        target || (target = xhr._cachedTarget[item.id] = cachedDocument.getElementById(item.id)), 
                        // embed the target into the svg
                        embed(item.parent, item.svg, target);
                    });
                }
            }, // test the ready state change immediately
            xhr.onreadystatechange();
        }
        function svg4everybody(rawopts) {
            function oninterval() {
                // while the index exists in the live <use> collection
                for (// get the cached <use> index
                var index = 0; index < uses.length; ) {
                    // get the current <use>
                    var use = uses[index], parent = use.parentNode, svg = getSVGAncestor(parent);
                    if (svg) {
                        var src = use.getAttribute("xlink:href") || use.getAttribute("href");
                        if (polyfill && (!opts.validate || opts.validate(src, svg, use))) {
                            // remove the <use> element
                            parent.removeChild(use);
                            // parse the src and get the url and id
                            var srcSplit = src.split("#"), url = srcSplit.shift(), id = srcSplit.join("#");
                            // if the link is external
                            if (url.length) {
                                // get the cached xhr request
                                var xhr = requests[url];
                                // ensure the xhr request exists
                                xhr || (xhr = requests[url] = new XMLHttpRequest(), xhr.open("GET", url), xhr.send(), 
                                xhr._embeds = []), // add the svg and id as an item to the xhr embeds list
                                xhr._embeds.push({
                                    parent: parent,
                                    svg: svg,
                                    id: id
                                }), // prepare the xhr ready state change event
                                loadreadystatechange(xhr);
                            } else {
                                // embed the local id into the svg
                                embed(parent, document.getElementById(id));
                            }
                        }
                    } else {
                        // increase the index when the previous value was not "valid"
                        ++index;
                    }
                }
                // continue the interval
                requestAnimationFrame(oninterval, 67);
            }
            var polyfill, opts = Object(rawopts), newerIEUA = /\bTrident\/[567]\b|\bMSIE (?:9|10)\.0\b/, webkitUA = /\bAppleWebKit\/(\d+)\b/, olderEdgeUA = /\bEdge\/12\.(\d+)\b/;
            polyfill = "polyfill" in opts ? opts.polyfill : newerIEUA.test(navigator.userAgent) || (navigator.userAgent.match(olderEdgeUA) || [])[1] < 10547 || (navigator.userAgent.match(webkitUA) || [])[1] < 537;
            // create xhr requests object
            var requests = {}, requestAnimationFrame = window.requestAnimationFrame || setTimeout, uses = document.getElementsByTagName("use");
            // conditionally start the interval if the polyfill is active
            polyfill && oninterval();
        }
        function getSVGAncestor(node) {
            for (var svg = node; "svg" !== svg.nodeName.toLowerCase() && (svg = svg.parentNode); ) {}
            return svg;
        }
        return svg4everybody;
    });
  • URL: /components/raw/libs/svg4everybody.js
  • Filesystem Path: build/components/01-globals/libs/svg4everybody.js
  • Size: 5.5 KB

There are no notes for this item.