diff --git a/demo/accordion.html b/demo/accordion.html index 2a9f47e..b6bdf00 100644 --- a/demo/accordion.html +++ b/demo/accordion.html @@ -246,9 +246,130 @@
Accordion
background-image: url('./images/_D805345-12.jpg'); background-image: linear-gradient(to bottom, rgba(255,255,255,0.1) 0%,rgba(255,255,255,0) 100%), url(./images/_D805345-12.jpg); } + + .cmd-button { + min-width: 170px; + } +
Vertical Accordion, aria-multiselectable="true"
+ + +
+ + + + + +
+ + + + + +
Horizontal Flexbox Accordion
@@ -633,104 +754,6 @@
Fifth
- -
Vertical Accordion, aria-multiselectable="true"
- - - - -

All images appearing in this page are the exclusive property of Leif Olsen and are protected under the United States and International Copyright laws. The images may not be reproduced or manipulated without the written permission of Leif Olsen. @@ -739,13 +762,47 @@

Fifth

diff --git a/demo/index.html b/demo/index.html index 75f508c..07efe67 100644 --- a/demo/index.html +++ b/demo/index.html @@ -174,6 +174,9 @@

Selectfield

of the standard [HTML <select> element.

+

Sticky Header

+

A sticky header makes site navigation easily accessible anywhere on the page and saves content space at the same.

+ diff --git a/lib/mdl-ext.js b/lib/mdl-ext.js index e750e32..294396d 100644 --- a/lib/mdl-ext.js +++ b/lib/mdl-ext.js @@ -721,15 +721,56 @@ return /******/ (function(modules) { // webpackBootstrap // Initialize instance. this.init(); }; + window['MaterialExtAccordion'] = MaterialExtAccordion; + /** + * Handles custom command event, 'open', 'close', or 'toggle' + * @param event. A custom event + * @private + */ + MaterialExtAccordion.prototype.commandHandler_ = function (event) { + var _this = this; + + event.preventDefault(); + event.stopPropagation(); + + if (event.detail && event.detail.action) { + (function () { + var action = event.detail.action.toLowerCase(); + + if ('open' === action || 'close' === action || 'toggle' === action) { + + if (event.detail.target === undefined) { + + if (_this.element_.hasAttribute('aria-multiselectable') && 'false' !== _this.element_.getAttribute('aria-multiselectable').toLowerCase()) { + + [].concat((0, _toConsumableArray3.default)(_this.element_.querySelectorAll('.' + PANEL))).forEach(function (panel) { + panel.dispatchEvent((0, _customEvent.createCustomEvent)('command_', { + detail: { action: action } + })); + }); + } + } else if (event.detail.target !== null) { + + event.detail.target.dispatchEvent( + // Let the even bubble, in case the evnt is dispatched to a child element of the panel + (0, _customEvent.createCustomEvent)('command_', { + bubbles: true, detail: { action: action } + })); + } + } + })(); + } + }; + /** * Initialize accordion's panels * * @private */ MaterialExtAccordion.prototype.initAccordion_ = function () { - var _this = this; + var _this2 = this; this.element_.setAttribute('role', 'tablist'); @@ -738,9 +779,11 @@ return /******/ (function(modules) { // webpackBootstrap } [].concat((0, _toConsumableArray3.default)(this.element_.querySelectorAll('.' + PANEL))).forEach(function (panel) { - new MaterialExtAccordionPanel(panel, _this); + new MaterialExtAccordionPanel(panel, _this2); }); + this.element_.addEventListener('command', this.commandHandler_.bind(this), false); + this.element_.classList.add(IS_UPGRADED); }; @@ -749,7 +792,6 @@ return /******/ (function(modules) { // webpackBootstrap */ MaterialExtAccordion.prototype.init = function () { if (this.element_) { - //console.log('***** init', this.element_.classList, this.element_.getAttribute('data-upgraded')); this.initAccordion_(); } }; @@ -798,37 +840,32 @@ return /******/ (function(modules) { // webpackBootstrap } header.addEventListener('click', function (event) { + event.preventDefault(); event.stopPropagation(); if (!panel.hasAttribute('disabled')) { + if (panel.hasAttribute('open')) { - panel.removeAttribute('open'); - header.removeAttribute('aria-expanded'); - header.setAttribute('aria-hidden', ''); + + closePanel(panel, header); // Dispatch toggle event to accordion element dispatchToggleEvent('close', panel, ctx.element_); } else { if (ctx.element_.hasAttribute('aria-multiselectable') && 'false' === ctx.element_.getAttribute('aria-multiselectable').toLowerCase()) { - var openPanel = ctx.element_.querySelector('.' + PANEL + '[open]'); - if (openPanel) { - openPanel.removeAttribute('open'); - var h = openPanel.querySelector('.' + HEADER); - h.removeAttribute('aria-expanded'); - h.setAttribute('aria-hidden', ''); + var _openPanel = ctx.element_.querySelector('.' + PANEL + '[open]'); + if (_openPanel) { + closePanel(_openPanel, _openPanel.querySelector('.' + HEADER)); // Dispatch toggle event to accordion element - dispatchToggleEvent('close', openPanel, ctx.element_); + dispatchToggleEvent('close', _openPanel, ctx.element_); } removeAriaSelectedAttribute(); } - panel.setAttribute('open', ''); - header.setAttribute('aria-expanded', ''); - header.setAttribute('aria-selected', ''); - header.removeAttribute('aria-hidden', ''); + openPanel(panel, header); // Dispatch toggle event to accordion element dispatchToggleEvent('open', panel, ctx.element_); @@ -892,6 +929,51 @@ return /******/ (function(modules) { // webpackBootstrap } }, true); + panel.addEventListener('command_', function (event) { + event.preventDefault(); + event.stopPropagation(); + + if (event.detail && event.detail.action) { + var action = event.detail.action.toLowerCase(); + switch (action) { + case 'open': + openPanel(panel, header); + break; + case 'close': + closePanel(panel, header); + break; + case 'toggle': + togglePanel(panel, header); + break; + } + } + }); + + function togglePanel(panel, header) { + if (panel.hasAttribute('open')) { + closePanel(panel, header); + } else { + openPanel(panel, header); + } + } + + function openPanel(panel, header) { + if (!panel.hasAttribute('disabled')) { + panel.setAttribute('open', ''); + header.setAttribute('aria-expanded', ''); + header.setAttribute('aria-selected', ''); + header.removeAttribute('aria-hidden', ''); + } + } + + function closePanel(panel, header) { + if (!panel.hasAttribute('disabled')) { + panel.removeAttribute('open'); + header.removeAttribute('aria-expanded'); + header.setAttribute('aria-hidden', ''); + } + } + function removeAriaSelectedAttribute() { var selectedHeader = ctx.element_.querySelector('.' + HEADER + '[aria-selected]'); if (selectedHeader) { diff --git a/lib/mdl-ext.js.map b/lib/mdl-ext.js.map index 3d503e7..fd1696d 100644 --- a/lib/mdl-ext.js.map +++ b/lib/mdl-ext.js.map @@ -1 +1 @@ -{"version":3,"sources":["webpack:///webpack/universalModuleDefinition?5ca6","webpack:///webpack/bootstrap 33e40fc71f35ff7f5216?62c9","webpack:///./~/babel-runtime/~/core-js/library/modules/_wks.js?2014","webpack:///./~/babel-runtime/~/core-js/library/modules/_core.js?d611","webpack:///./~/babel-runtime/~/core-js/library/modules/_global.js?3c52","webpack:///./~/babel-runtime/~/core-js/library/modules/_iterators.js?f3f3","webpack:///./~/babel-runtime/~/core-js/library/modules/_an-object.js?3af2","webpack:///./~/babel-runtime/~/core-js/library/modules/_hide.js?0d2e","webpack:///./src/utils/custom-event.js?bfbd","webpack:///./~/babel-runtime/~/core-js/library/modules/_descriptors.js?c0f5","webpack:///./~/babel-runtime/~/core-js/library/modules/_export.js?8e40","webpack:///./~/babel-runtime/~/core-js/library/modules/_has.js?ddd0","webpack:///./~/babel-runtime/~/core-js/library/modules/_is-object.js?cfda","webpack:///./~/babel-runtime/~/core-js/library/modules/_object-dp.js?5986","webpack:///./~/babel-runtime/~/core-js/library/modules/_to-iobject.js?527c","webpack:///./~/babel-runtime/helpers/toConsumableArray.js?1825","webpack:///./~/babel-runtime/~/core-js/library/modules/_defined.js?932b","webpack:///./~/babel-runtime/~/core-js/library/modules/_property-desc.js?256b","webpack:///./~/babel-runtime/~/core-js/library/modules/_shared-key.js?5602","webpack:///./~/babel-runtime/~/core-js/library/modules/_to-integer.js?09ce","webpack:///./~/babel-runtime/~/core-js/library/modules/es6.string.iterator.js?ae27","webpack:///./~/babel-runtime/core-js/get-iterator.js?1b08","webpack:///./~/babel-runtime/~/core-js/library/modules/_classof.js?4e04","webpack:///./~/babel-runtime/~/core-js/library/modules/_cof.js?7381","webpack:///./~/babel-runtime/~/core-js/library/modules/_ctx.js?4e59","webpack:///./~/babel-runtime/~/core-js/library/modules/_dom-create.js?612f","webpack:///./~/babel-runtime/~/core-js/library/modules/_enum-bug-keys.js?3254","webpack:///./~/babel-runtime/~/core-js/library/modules/_fails.js?c6dd","webpack:///./~/babel-runtime/~/core-js/library/modules/_iter-define.js?4272","webpack:///./~/babel-runtime/~/core-js/library/modules/_object-keys.js?5d2e","webpack:///./~/babel-runtime/~/core-js/library/modules/_set-to-string-tag.js?57a7","webpack:///./~/babel-runtime/~/core-js/library/modules/_shared.js?f1ee","webpack:///./~/babel-runtime/~/core-js/library/modules/_to-length.js?f510","webpack:///./~/babel-runtime/~/core-js/library/modules/_to-object.js?ca4f","webpack:///./~/babel-runtime/~/core-js/library/modules/_uid.js?c10a","webpack:///./~/babel-runtime/~/core-js/library/modules/core.get-iterator-method.js?8a45","webpack:///./~/babel-runtime/~/core-js/library/modules/web.dom.iterable.js?7e82","webpack:///./src/accordion/accordion.js?021c","webpack:///./src/index.js?9552","webpack:///./src/lightboard/lightboard.js?4a51","webpack:///./src/lightbox/lightbox.js?4a9b","webpack:///./src/selectfield/selectfield.js?4310","webpack:///./src/sticky-header/sticky-header.js?0ce9","webpack:///./~/babel-runtime/core-js/array/from.js?efc2","webpack:///./~/babel-runtime/core-js/is-iterable.js?350e","webpack:///./~/babel-runtime/core-js/number/is-integer.js?14ca","webpack:///./~/babel-runtime/core-js/object/entries.js?41f9","webpack:///./~/babel-runtime/helpers/slicedToArray.js?39c4","webpack:///./~/babel-runtime/~/core-js/library/fn/array/from.js?56e0","webpack:///./~/babel-runtime/~/core-js/library/fn/get-iterator.js?cf7c","webpack:///./~/babel-runtime/~/core-js/library/fn/is-iterable.js?f64a","webpack:///./~/babel-runtime/~/core-js/library/fn/number/is-integer.js?17db","webpack:///./~/babel-runtime/~/core-js/library/fn/object/entries.js?eb23","webpack:///./~/babel-runtime/~/core-js/library/modules/_a-function.js?0699","webpack:///./~/babel-runtime/~/core-js/library/modules/_add-to-unscopables.js?7da3","webpack:///./~/babel-runtime/~/core-js/library/modules/_array-includes.js?3a79","webpack:///./~/babel-runtime/~/core-js/library/modules/_create-property.js?f892","webpack:///./~/babel-runtime/~/core-js/library/modules/_html.js?8916","webpack:///./~/babel-runtime/~/core-js/library/modules/_ie8-dom-define.js?b102","webpack:///./~/babel-runtime/~/core-js/library/modules/_iobject.js?34ed","webpack:///./~/babel-runtime/~/core-js/library/modules/_is-array-iter.js?a9d0","webpack:///./~/babel-runtime/~/core-js/library/modules/_is-integer.js?9053","webpack:///./~/babel-runtime/~/core-js/library/modules/_iter-call.js?45cd","webpack:///./~/babel-runtime/~/core-js/library/modules/_iter-create.js?0359","webpack:///./~/babel-runtime/~/core-js/library/modules/_iter-detect.js?e400","webpack:///./~/babel-runtime/~/core-js/library/modules/_iter-step.js?8944","webpack:///./~/babel-runtime/~/core-js/library/modules/_library.js?08a9","webpack:///./~/babel-runtime/~/core-js/library/modules/_object-create.js?9175","webpack:///./~/babel-runtime/~/core-js/library/modules/_object-dps.js?73bc","webpack:///./~/babel-runtime/~/core-js/library/modules/_object-gpo.js?5ec8","webpack:///./~/babel-runtime/~/core-js/library/modules/_object-keys-internal.js?6fa8","webpack:///./~/babel-runtime/~/core-js/library/modules/_object-pie.js?a26b","webpack:///./~/babel-runtime/~/core-js/library/modules/_object-to-array.js?205b","webpack:///./~/babel-runtime/~/core-js/library/modules/_redefine.js?350a","webpack:///./~/babel-runtime/~/core-js/library/modules/_string-at.js?8678","webpack:///./~/babel-runtime/~/core-js/library/modules/_to-index.js?7bea","webpack:///./~/babel-runtime/~/core-js/library/modules/_to-primitive.js?1a65","webpack:///./~/babel-runtime/~/core-js/library/modules/core.get-iterator.js?74ea","webpack:///./~/babel-runtime/~/core-js/library/modules/core.is-iterable.js?be30","webpack:///./~/babel-runtime/~/core-js/library/modules/es6.array.from.js?f8ab","webpack:///./~/babel-runtime/~/core-js/library/modules/es6.array.iterator.js?8359","webpack:///./~/babel-runtime/~/core-js/library/modules/es6.number.is-integer.js?a48c","webpack:///./~/babel-runtime/~/core-js/library/modules/es7.object.entries.js?872a","webpack:///./src/mdl-ext-build.scss?16f6"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD,O;ACVA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA,uBAAe;AACf;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;;AAGA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;;;;;;;;;;;;;;;ACtCA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,G;;;;;;ACPA,8BAA6B;AAC7B,sCAAqC,gC;;;;;;ACDrC;AACA;AAC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;AACf,gBAAe;AACf,iBAAgB;AAChB,0B;;;;;;AC5DA,wBAAuB;AACvB;AACA;AACA,G;;;;;;ACHA;AACA;AACA,G;;;;;;ACFA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,IAAG,UAAU;AACb;AACA;AACA;AACA,G;;;;;;ACfA;AACA;AACA;AACA;AACA;AACA,G;;;;;;ACLA;;AAEA;;AAEA;;AAEA;;AAEA,uCAAsC,uCAAuC,gBAAgB;;AAE7F;AACA;AACA,8CAA6C,gBAAgB;AAC7D;AACA;;AAEA;AACA,IAAG;AACH;AACA;AACA,G;;;;;;ACpBA;AACA;AACA;AACA;AACA,G;;;;;;ACJA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,G;;;;;;ACPA;AACA;AACA;AACA;AACA,G;;;;;;ACJA;AACA;AACA;AACA;AACA;AACA,G;;;;;;ACLA;AACA;;AAEA;AACA;AACA,8BAA6B;AAC7B,eAAc;AACd;AACA,EAAC;AACD;AACA;AACA;AACA,gCAA+B;AAC/B;AACA;AACA,WAAU;AACV,EAAC,E;;;;;;AChBD,mBAAkB,wD;;;;;;ACAlB;AACA;AACA;AACA;AACA,0BAAyB,kBAAkB,EAAE;;AAE7C;AACA;AACA;AACA;AACA,IAAG,UAAU;AACb;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,G;;;;;;ACtBA,kBAAiB;;AAEjB;AACA;AACA,G;;;;;;ACJA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,G;;;;;;ACnBA;AACA;AACA;AACA;AACA;AACA;AACA,G;;;;;;ACNA;AACA;AACA;AACA,c;;;;;;ACHA;AACA;AACA;AACA,IAAG;AACH;AACA;AACA,G;;;;;;ACNA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,6BAA4B,aAAa;;AAEzC;AACA;AACA;AACA;AACA;AACA,yCAAwC,oCAAoC;AAC5E,6CAA4C,oCAAoC;AAChF,MAAK,2BAA2B,oCAAoC;AACpE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,iBAAgB,mBAAmB;AACnC;AACA;AACA,kCAAiC,2BAA2B;AAC5D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAK;AACL;AACA;AACA,G;;;;;;ACrEA;AACA;AACA;;AAEA;AACA;AACA,G;;;;;;ACNA;AACA;AACA;;AAEA;AACA,mEAAkE,+BAA+B;AACjG,G;;;;;;ACNA;AACA;AACA,oDAAmD;AACnD;AACA,wCAAuC;AACvC,G;;;;;;ACLA;AACA;AACA;AACA;AACA,4DAA2D;AAC3D,G;;;;;;ACLA;AACA;AACA;AACA;AACA,G;;;;;;ACJA;AACA;AACA;AACA;AACA,G;;;;;;ACJA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,G;;;;;;ACPA;AACA;AACA;AACA;AACA;;AAEA,yGAAwG,OAAO;AAC/G;AACA;AACA;AACA;AACA;AACA,E;;;;;;;;;;;;ACiBA;;;;AAEA,EAAC,YAAW;AACV;;AAGA,OAAM,mBAAmB,gBAAzB;AACA,OAAM,SAAS,CAAf;AACA,OAAM,WAAW,EAAjB;AACA,OAAM,WAAW,EAAjB;AACA,OAAM,SAAS,EAAf;AACA,OAAM,UAAU,EAAhB;AACA,OAAM,gBAAgB,EAAtB;AACA,OAAM,cAAc,EAApB;AACA,OAAM,iBAAiB,EAAvB;AACA,OAAM,gBAAgB,EAAtB;;AAEA,OAAM,QAAQ,yBAAd;AACA,OAAM,SAAS,iCAAf;AACA,OAAM,iBAAiB,0CAAvB;AACA,OAAM,cAAc,aAApB;AACA,OAAM,SAAS,YAAf;AACA,OAAM,mBAAmB,mDAAzB;AACA,OAAM,gBAAgB,sB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FA;AACA;AACA,0C;;;;;;ACFA;AACA,0D;;;;;;ACDA;AACA,wD;;;;;;ACDA;AACA;AACA;AACA,G;;;;;;ACHA,6BAA4B,e;;;;;;ACA5B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAK,WAAW,eAAe;AAC/B;AACA,MAAK;AACL;AACA,G;;;;;;ACpBA;AACA;AACA;;AAEA;AACA;AACA;AACA,G;;;;;;ACPA,8E;;;;;;ACAA;AACA,sEAAsE,gBAAgB,UAAU,GAAG;AACnG,EAAC,E;;;;;;ACFD;AACA;AACA;AACA;AACA,G;;;;;;ACJA;AACA;AACA;AACA;;AAEA;AACA;AACA,G;;;;;;ACPA;AACA;AACA;AACA;AACA;AACA,G;;;;;;ACLA;AACA;AACA;AACA;AACA;AACA;AACA,IAAG;AACH;AACA;AACA;AACA;AACA,G;;;;;;ACXA;AACA;AACA;AACA;AACA;;AAEA;AACA,0FAAgF,aAAa,EAAE;;AAE/F;AACA,sDAAqD,0BAA0B;AAC/E;AACA,G;;;;;;ACZA;AACA;;AAEA;AACA;AACA,gCAA+B,qBAAqB;AACpD,gCAA+B,SAAS,EAAE;AAC1C,EAAC,UAAU;;AAEX;AACA;AACA;AACA;AACA;AACA;AACA,4BAA2B,SAAS,mBAAmB;AACvD,gCAA+B,aAAa;AAC5C;AACA,IAAG,UAAU;AACb;AACA,G;;;;;;ACpBA;AACA,WAAU;AACV,G;;;;;;ACFA,uB;;;;;;ACAA;AACA;AACA;AACA;AACA;AACA,8BAA6B;AAC7B;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8BAA6B;AAC7B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAG;AACH;AACA,G;;;;;;ACvCA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,G;;;;;;ACZA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,IAAG;AACH,G;;;;;;ACZA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,G;;;;;;AChBA,eAAc,sB;;;;;;ACAd;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAK;AACL;AACA,G;;;;;;ACfA,yC;;;;;;ACAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,G;;;;;;AChBA;AACA;AACA;AACA;AACA;AACA;AACA,G;;;;;;ACNA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,G;;;;;;ACXA;AACA;AACA;AACA;AACA;AACA;AACA,G;;;;;;ACNA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,G;;;;;;ACRA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,yEAA0E,kBAAkB,EAAE;AAC9F;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,qDAAoD,gCAAgC;AACpF;AACA;AACA,MAAK;AACL;AACA,kCAAiC,gBAAgB;AACjD;AACA;AACA;AACA;AACA;AACA;AACA,EAAC;;;;;;;ACpCD;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,iCAAgC;AAChC,eAAc;AACd,kBAAiB;AACjB;AACA,EAAC;AACD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,EAAC;;AAED;AACA;;AAEA;AACA;AACA,6B;;;;;;ACjCA;AACA;;AAEA,+BAA8B,mCAAoC,E;;;;;;ACHlE;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,EAAC,E;;;;;;ACRD,0C","file":"mdl-ext.js","sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine(\"mdl-ext\", [], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"mdl-ext\"] = factory();\n\telse\n\t\troot[\"mdl-ext\"] = factory();\n})(this, function() {\nreturn \n\n\n/** WEBPACK FOOTER **\n ** webpack/universalModuleDefinition\n **/\n\n\n/** WEBPACK FOOTER **\n ** webpack/universalModuleDefinition\n **/"," \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId])\n \t\t\treturn installedModules[moduleId].exports;\n\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\texports: {},\n \t\t\tid: moduleId,\n \t\t\tloaded: false\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.loaded = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(0);\n\n\n\n/** WEBPACK FOOTER **\n ** webpack/bootstrap 33e40fc71f35ff7f5216\n **/\n\n\n/** WEBPACK FOOTER **\n ** webpack/bootstrap 33e40fc71f35ff7f5216\n **/","var store = require('./_shared')('wks')\n , uid = require('./_uid')\n , Symbol = require('./_global').Symbol\n , USE_SYMBOL = typeof Symbol == 'function';\nmodule.exports = function(name){\n return store[name] || (store[name] =\n USE_SYMBOL && Symbol[name] || (USE_SYMBOL ? Symbol : uid)('Symbol.' + name));\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_wks.js\n ** module id = 1\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_wks.js\n ** module id = 1\n ** module chunks = 0 1\n **/","var core = module.exports = {version: '2.2.2'};\nif(typeof __e == 'number')__e = core; // eslint-disable-line no-undef\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_core.js\n ** module id = 2\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_core.js\n ** module id = 2\n ** module chunks = 0 1\n **/","// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028\nvar global = module.exports = typeof window != 'undefined' && window.Math == Math\n ? window : typeof self != 'undefined' && self.Math == Math ? self : Function('return this')();\nif(typeof __g == 'number')__g = global; // eslint-disable-line no-undef\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_global.js\n ** module id = 3\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_global.js\n ** module id = 3\n ** module chunks = 0 1\n **/","module.exports = {};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_iterators.js\n ** module id = 4\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_iterators.js\n ** module id = 4\n ** module chunks = 0 1\n **/","var isObject = require('./_is-object');\nmodule.exports = function(it){\n if(!isObject(it))throw TypeError(it + ' is not an object!');\n return it;\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_an-object.js\n ** module id = 5\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_an-object.js\n ** module id = 5\n ** module chunks = 0 1\n **/","var dP = require('./_object-dp')\n , createDesc = require('./_property-desc');\nmodule.exports = require('./_descriptors') ? function(object, key, value){\n return dP.f(object, key, createDesc(1, value));\n} : function(object, key, value){\n object[key] = value;\n return object;\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_hide.js\n ** module id = 6\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_hide.js\n ** module id = 6\n ** module chunks = 0 1\n **/","/**\n * @license\n * Copyright 2016 Leif Olsen. All Rights Reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n\n/**\n * Due to a bug in mdl-1.1.3 it is not possible to use a globally polyfilled CustomEvent constructor\n * Since I do not care too much about IE11, a brute force approach is sufficient.\n *\n * @param {string} typeArg Is a String representing the name of the event.\n * @param {Object} customEventInit Is an EventInit dictionary, having the following fields:\n * \"bubbles\", optional and defaulting to false, of type Boolean, indicating if the event bubbles or not.\n * \"cancelable\", optional and defaulting to false, of type Boolean, indicating if the event can be canceled or not.\n * \"detail\", optional and defaulting to null, of type any, that is an event-dependent value associated with the event.\n */\n\nexport function createCustomEvent( typeArg, customEventInit = { bubbles: false, cancelable: false, detail: null } ) {\n 'use strict';\n\n try {\n // Modern browsers\n return new window.CustomEvent(typeArg, customEventInit);\n }\n catch(e) {\n // Copied from https://github.com/webcomponents/webcomponentsjs/blob/v0.7.12/CustomElements.js#L950\n // Copied from http://stackoverflow.com/questions/23349191/event-preventdefault-is-not-working-in-ie-11-for-custom-events\n const ce = document.createEvent('CustomEvent');\n ce.initCustomEvent(typeArg, customEventInit.bubbles, customEventInit.cancelable, customEventInit.detail);\n\n ce.preventDefault = function() {\n Object.defineProperty(this, 'defaultPrevented', {\n get: function() {\n return true;\n }\n });\n };\n return ce;\n }\n // Let old browsers throw whatewer they want to throw\n}\n\n\n\n/** WEBPACK FOOTER **\n ** ./src/utils/custom-event.js\n **/\n\n\n/** WEBPACK FOOTER **\n ** ./src/utils/custom-event.js\n **/","// Thank's IE8 for his funny defineProperty\nmodule.exports = !require('./_fails')(function(){\n return Object.defineProperty({}, 'a', {get: function(){ return 7; }}).a != 7;\n});\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_descriptors.js\n ** module id = 8\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_descriptors.js\n ** module id = 8\n ** module chunks = 0 1\n **/","var global = require('./_global')\n , core = require('./_core')\n , ctx = require('./_ctx')\n , hide = require('./_hide')\n , PROTOTYPE = 'prototype';\n\nvar $export = function(type, name, source){\n var IS_FORCED = type & $export.F\n , IS_GLOBAL = type & $export.G\n , IS_STATIC = type & $export.S\n , IS_PROTO = type & $export.P\n , IS_BIND = type & $export.B\n , IS_WRAP = type & $export.W\n , exports = IS_GLOBAL ? core : core[name] || (core[name] = {})\n , expProto = exports[PROTOTYPE]\n , target = IS_GLOBAL ? global : IS_STATIC ? global[name] : (global[name] || {})[PROTOTYPE]\n , key, own, out;\n if(IS_GLOBAL)source = name;\n for(key in source){\n // contains in native\n own = !IS_FORCED && target && target[key] !== undefined;\n if(own && key in exports)continue;\n // export native or passed\n out = own ? target[key] : source[key];\n // prevent global pollution for namespaces\n exports[key] = IS_GLOBAL && typeof target[key] != 'function' ? source[key]\n // bind timers to global for call from export context\n : IS_BIND && own ? ctx(out, global)\n // wrap global constructors for prevent change them in library\n : IS_WRAP && target[key] == out ? (function(C){\n var F = function(a, b, c){\n if(this instanceof C){\n switch(arguments.length){\n case 0: return new C;\n case 1: return new C(a);\n case 2: return new C(a, b);\n } return new C(a, b, c);\n } return C.apply(this, arguments);\n };\n F[PROTOTYPE] = C[PROTOTYPE];\n return F;\n // make static versions for prototype methods\n })(out) : IS_PROTO && typeof out == 'function' ? ctx(Function.call, out) : out;\n // export proto methods to core.%CONSTRUCTOR%.methods.%NAME%\n if(IS_PROTO){\n (exports.virtual || (exports.virtual = {}))[key] = out;\n // export proto methods to core.%CONSTRUCTOR%.prototype.%NAME%\n if(type & $export.R && expProto && !expProto[key])hide(expProto, key, out);\n }\n }\n};\n// type bitmap\n$export.F = 1; // forced\n$export.G = 2; // global\n$export.S = 4; // static\n$export.P = 8; // proto\n$export.B = 16; // bind\n$export.W = 32; // wrap\n$export.U = 64; // safe\n$export.R = 128; // real proto method for `library` \nmodule.exports = $export;\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_export.js\n ** module id = 9\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_export.js\n ** module id = 9\n ** module chunks = 0 1\n **/","var hasOwnProperty = {}.hasOwnProperty;\nmodule.exports = function(it, key){\n return hasOwnProperty.call(it, key);\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_has.js\n ** module id = 10\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_has.js\n ** module id = 10\n ** module chunks = 0 1\n **/","module.exports = function(it){\n return typeof it === 'object' ? it !== null : typeof it === 'function';\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_is-object.js\n ** module id = 11\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_is-object.js\n ** module id = 11\n ** module chunks = 0 1\n **/","var anObject = require('./_an-object')\n , IE8_DOM_DEFINE = require('./_ie8-dom-define')\n , toPrimitive = require('./_to-primitive')\n , dP = Object.defineProperty;\n\nexports.f = require('./_descriptors') ? Object.defineProperty : function defineProperty(O, P, Attributes){\n anObject(O);\n P = toPrimitive(P, true);\n anObject(Attributes);\n if(IE8_DOM_DEFINE)try {\n return dP(O, P, Attributes);\n } catch(e){ /* empty */ }\n if('get' in Attributes || 'set' in Attributes)throw TypeError('Accessors not supported!');\n if('value' in Attributes)O[P] = Attributes.value;\n return O;\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_object-dp.js\n ** module id = 12\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_object-dp.js\n ** module id = 12\n ** module chunks = 0 1\n **/","// to indexed object, toObject with fallback for non-array-like ES3 strings\nvar IObject = require('./_iobject')\n , defined = require('./_defined');\nmodule.exports = function(it){\n return IObject(defined(it));\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_to-iobject.js\n ** module id = 13\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_to-iobject.js\n ** module id = 13\n ** module chunks = 0 1\n **/","\"use strict\";\n\nexports.__esModule = true;\n\nvar _from = require(\"babel-runtime/core-js/array/from\");\n\nvar _from2 = _interopRequireDefault(_from);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nexports.default = function (arr) {\n if (Array.isArray(arr)) {\n for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) {\n arr2[i] = arr[i];\n }\n\n return arr2;\n } else {\n return (0, _from2.default)(arr);\n }\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/helpers/toConsumableArray.js\n ** module id = 14\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/helpers/toConsumableArray.js\n ** module id = 14\n ** module chunks = 0 1\n **/","// 7.2.1 RequireObjectCoercible(argument)\nmodule.exports = function(it){\n if(it == undefined)throw TypeError(\"Can't call method on \" + it);\n return it;\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_defined.js\n ** module id = 15\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_defined.js\n ** module id = 15\n ** module chunks = 0 1\n **/","module.exports = function(bitmap, value){\n return {\n enumerable : !(bitmap & 1),\n configurable: !(bitmap & 2),\n writable : !(bitmap & 4),\n value : value\n };\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_property-desc.js\n ** module id = 16\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_property-desc.js\n ** module id = 16\n ** module chunks = 0 1\n **/","var shared = require('./_shared')('keys')\r\n , uid = require('./_uid');\r\nmodule.exports = function(key){\r\n return shared[key] || (shared[key] = uid(key));\r\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_shared-key.js\n ** module id = 17\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_shared-key.js\n ** module id = 17\n ** module chunks = 0 1\n **/","// 7.1.4 ToInteger\nvar ceil = Math.ceil\n , floor = Math.floor;\nmodule.exports = function(it){\n return isNaN(it = +it) ? 0 : (it > 0 ? floor : ceil)(it);\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_to-integer.js\n ** module id = 18\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_to-integer.js\n ** module id = 18\n ** module chunks = 0 1\n **/","'use strict';\nvar $at = require('./_string-at')(true);\n\n// 21.1.3.27 String.prototype[@@iterator]()\nrequire('./_iter-define')(String, 'String', function(iterated){\n this._t = String(iterated); // target\n this._i = 0; // next index\n// 21.1.5.2.1 %StringIteratorPrototype%.next()\n}, function(){\n var O = this._t\n , index = this._i\n , point;\n if(index >= O.length)return {value: undefined, done: true};\n point = $at(O, index);\n this._i += point.length;\n return {value: point, done: false};\n});\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/es6.string.iterator.js\n ** module id = 19\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/es6.string.iterator.js\n ** module id = 19\n ** module chunks = 0 1\n **/","module.exports = { \"default\": require(\"core-js/library/fn/get-iterator\"), __esModule: true };\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/core-js/get-iterator.js\n ** module id = 20\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/core-js/get-iterator.js\n ** module id = 20\n ** module chunks = 0 1\n **/","// getting tag from 19.1.3.6 Object.prototype.toString()\nvar cof = require('./_cof')\n , TAG = require('./_wks')('toStringTag')\n // ES3 wrong here\n , ARG = cof(function(){ return arguments; }()) == 'Arguments';\n\n// fallback for IE11 Script Access Denied error\nvar tryGet = function(it, key){\n try {\n return it[key];\n } catch(e){ /* empty */ }\n};\n\nmodule.exports = function(it){\n var O, T, B;\n return it === undefined ? 'Undefined' : it === null ? 'Null'\n // @@toStringTag case\n : typeof (T = tryGet(O = Object(it), TAG)) == 'string' ? T\n // builtinTag case\n : ARG ? cof(O)\n // ES3 arguments fallback\n : (B = cof(O)) == 'Object' && typeof O.callee == 'function' ? 'Arguments' : B;\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_classof.js\n ** module id = 21\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_classof.js\n ** module id = 21\n ** module chunks = 0 1\n **/","var toString = {}.toString;\n\nmodule.exports = function(it){\n return toString.call(it).slice(8, -1);\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_cof.js\n ** module id = 22\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_cof.js\n ** module id = 22\n ** module chunks = 0 1\n **/","// optional / simple context binding\nvar aFunction = require('./_a-function');\nmodule.exports = function(fn, that, length){\n aFunction(fn);\n if(that === undefined)return fn;\n switch(length){\n case 1: return function(a){\n return fn.call(that, a);\n };\n case 2: return function(a, b){\n return fn.call(that, a, b);\n };\n case 3: return function(a, b, c){\n return fn.call(that, a, b, c);\n };\n }\n return function(/* ...args */){\n return fn.apply(that, arguments);\n };\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_ctx.js\n ** module id = 23\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_ctx.js\n ** module id = 23\n ** module chunks = 0 1\n **/","var isObject = require('./_is-object')\n , document = require('./_global').document\n // in old IE typeof document.createElement is 'object'\n , is = isObject(document) && isObject(document.createElement);\nmodule.exports = function(it){\n return is ? document.createElement(it) : {};\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_dom-create.js\n ** module id = 24\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_dom-create.js\n ** module id = 24\n ** module chunks = 0 1\n **/","// IE 8- don't enum bug keys\r\nmodule.exports = (\r\n 'constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf'\r\n).split(',');\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_enum-bug-keys.js\n ** module id = 25\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_enum-bug-keys.js\n ** module id = 25\n ** module chunks = 0 1\n **/","module.exports = function(exec){\n try {\n return !!exec();\n } catch(e){\n return true;\n }\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_fails.js\n ** module id = 26\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_fails.js\n ** module id = 26\n ** module chunks = 0 1\n **/","'use strict';\nvar LIBRARY = require('./_library')\n , $export = require('./_export')\n , redefine = require('./_redefine')\n , hide = require('./_hide')\n , has = require('./_has')\n , Iterators = require('./_iterators')\n , $iterCreate = require('./_iter-create')\n , setToStringTag = require('./_set-to-string-tag')\n , getPrototypeOf = require('./_object-gpo')\n , ITERATOR = require('./_wks')('iterator')\n , BUGGY = !([].keys && 'next' in [].keys()) // Safari has buggy iterators w/o `next`\n , FF_ITERATOR = '@@iterator'\n , KEYS = 'keys'\n , VALUES = 'values';\n\nvar returnThis = function(){ return this; };\n\nmodule.exports = function(Base, NAME, Constructor, next, DEFAULT, IS_SET, FORCED){\n $iterCreate(Constructor, NAME, next);\n var getMethod = function(kind){\n if(!BUGGY && kind in proto)return proto[kind];\n switch(kind){\n case KEYS: return function keys(){ return new Constructor(this, kind); };\n case VALUES: return function values(){ return new Constructor(this, kind); };\n } return function entries(){ return new Constructor(this, kind); };\n };\n var TAG = NAME + ' Iterator'\n , DEF_VALUES = DEFAULT == VALUES\n , VALUES_BUG = false\n , proto = Base.prototype\n , $native = proto[ITERATOR] || proto[FF_ITERATOR] || DEFAULT && proto[DEFAULT]\n , $default = $native || getMethod(DEFAULT)\n , $entries = DEFAULT ? !DEF_VALUES ? $default : getMethod('entries') : undefined\n , $anyNative = NAME == 'Array' ? proto.entries || $native : $native\n , methods, key, IteratorPrototype;\n // Fix native\n if($anyNative){\n IteratorPrototype = getPrototypeOf($anyNative.call(new Base));\n if(IteratorPrototype !== Object.prototype){\n // Set @@toStringTag to native iterators\n setToStringTag(IteratorPrototype, TAG, true);\n // fix for some old engines\n if(!LIBRARY && !has(IteratorPrototype, ITERATOR))hide(IteratorPrototype, ITERATOR, returnThis);\n }\n }\n // fix Array#{values, @@iterator}.name in V8 / FF\n if(DEF_VALUES && $native && $native.name !== VALUES){\n VALUES_BUG = true;\n $default = function values(){ return $native.call(this); };\n }\n // Define iterator\n if((!LIBRARY || FORCED) && (BUGGY || VALUES_BUG || !proto[ITERATOR])){\n hide(proto, ITERATOR, $default);\n }\n // Plug for library\n Iterators[NAME] = $default;\n Iterators[TAG] = returnThis;\n if(DEFAULT){\n methods = {\n values: DEF_VALUES ? $default : getMethod(VALUES),\n keys: IS_SET ? $default : getMethod(KEYS),\n entries: $entries\n };\n if(FORCED)for(key in methods){\n if(!(key in proto))redefine(proto, key, methods[key]);\n } else $export($export.P + $export.F * (BUGGY || VALUES_BUG), NAME, methods);\n }\n return methods;\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_iter-define.js\n ** module id = 27\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_iter-define.js\n ** module id = 27\n ** module chunks = 0 1\n **/","// 19.1.2.14 / 15.2.3.14 Object.keys(O)\r\nvar $keys = require('./_object-keys-internal')\r\n , enumBugKeys = require('./_enum-bug-keys');\r\n\r\nmodule.exports = Object.keys || function keys(O){\r\n return $keys(O, enumBugKeys);\r\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_object-keys.js\n ** module id = 28\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_object-keys.js\n ** module id = 28\n ** module chunks = 0 1\n **/","var def = require('./_object-dp').f\n , has = require('./_has')\n , TAG = require('./_wks')('toStringTag');\n\nmodule.exports = function(it, tag, stat){\n if(it && !has(it = stat ? it : it.prototype, TAG))def(it, TAG, {configurable: true, value: tag});\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_set-to-string-tag.js\n ** module id = 29\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_set-to-string-tag.js\n ** module id = 29\n ** module chunks = 0 1\n **/","var global = require('./_global')\n , SHARED = '__core-js_shared__'\n , store = global[SHARED] || (global[SHARED] = {});\nmodule.exports = function(key){\n return store[key] || (store[key] = {});\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_shared.js\n ** module id = 30\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_shared.js\n ** module id = 30\n ** module chunks = 0 1\n **/","// 7.1.15 ToLength\nvar toInteger = require('./_to-integer')\n , min = Math.min;\nmodule.exports = function(it){\n return it > 0 ? min(toInteger(it), 0x1fffffffffffff) : 0; // pow(2, 53) - 1 == 9007199254740991\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_to-length.js\n ** module id = 31\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_to-length.js\n ** module id = 31\n ** module chunks = 0 1\n **/","// 7.1.13 ToObject(argument)\nvar defined = require('./_defined');\nmodule.exports = function(it){\n return Object(defined(it));\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_to-object.js\n ** module id = 32\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_to-object.js\n ** module id = 32\n ** module chunks = 0 1\n **/","var id = 0\n , px = Math.random();\nmodule.exports = function(key){\n return 'Symbol('.concat(key === undefined ? '' : key, ')_', (++id + px).toString(36));\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_uid.js\n ** module id = 33\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_uid.js\n ** module id = 33\n ** module chunks = 0 1\n **/","var classof = require('./_classof')\n , ITERATOR = require('./_wks')('iterator')\n , Iterators = require('./_iterators');\nmodule.exports = require('./_core').getIteratorMethod = function(it){\n if(it != undefined)return it[ITERATOR]\n || it['@@iterator']\n || Iterators[classof(it)];\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/core.get-iterator-method.js\n ** module id = 34\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/core.get-iterator-method.js\n ** module id = 34\n ** module chunks = 0 1\n **/","require('./es6.array.iterator');\nvar global = require('./_global')\n , hide = require('./_hide')\n , Iterators = require('./_iterators')\n , TO_STRING_TAG = require('./_wks')('toStringTag');\n\nfor(var collections = ['NodeList', 'DOMTokenList', 'MediaList', 'StyleSheetList', 'CSSRuleList'], i = 0; i < 5; i++){\n var NAME = collections[i]\n , Collection = global[NAME]\n , proto = Collection && Collection.prototype;\n if(proto && !proto[TO_STRING_TAG])hide(proto, TO_STRING_TAG, NAME);\n Iterators[NAME] = Iterators.Array;\n}\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/web.dom.iterable.js\n ** module id = 35\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/web.dom.iterable.js\n ** module id = 35\n ** module chunks = 0 1\n **/","/**\n * @license\n * Copyright 2016 Leif Olsen. All Rights Reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n *\n * This code is built with Google Material Design Lite,\n * which is Licensed under the Apache License, Version 2.0\n */\n\n/**\n * A WAI-ARIA friendly accordion component.\n * An accordion is a collection of expandable panels associated with a common outer container. Panels consist\n * of a header and an associated content region or panel. The primary use of an Accordion is to present multiple sections\n * of content on a single page without scrolling, where all of the sections are peers in the application or object hierarchy.\n * The general look is similar to a tree where each root tree node is an expandable accordion header. The user navigates\n * and makes the contents of each panel visible (or not) by interacting with the Accordion Header\n */\n\nimport { createCustomEvent } from '../utils/custom-event';\n\n(function() {\n 'use strict';\n\n\n const RIPPLE_COMPONENT = 'MaterialRipple';\n const VK_TAB = 9;\n const VK_ENTER = 13;\n const VK_SPACE = 32;\n const VK_END = 35;\n const VK_HOME = 36;\n const VK_ARROW_LEFT = 37;\n const VK_ARROW_UP = 38;\n const VK_ARROW_RIGHT = 39;\n const VK_ARROW_DOWN = 40;\n\n const PANEL = 'mdlext-accordion__panel';\n const HEADER = 'mdlext-accordion__panel__header';\n const HEADER_TABSTOP = 'mdlext-accordion__panel__header__tabstop';\n const IS_UPGRADED = 'is-upgraded';\n const RIPPLE = 'mdl-ripple';\n const RIPPLE_CONTAINER = 'mdlext-accordion__panel__header__ripple-container';\n const RIPPLE_EFFECT = 'mdl-js-ripple-effect';\n const RIPPLE_EFFECT_IGNORE_EVENTS = 'mdl-js-ripple-effect--ignore-events';\n\n\n /**\n * Class constructor for Accordion MDLEXT component.\n * Implements MDL component design pattern defined at:\n * https://github.com/jasonmayes/mdl-component-design-pattern\n *\n * @constructor\n * @param {Element} element The element that will be upgraded.\n */\n const MaterialExtAccordion = function MaterialExtAccordion(element) {\n // Stores the Accordion HTML element.\n this.element_ = element;\n\n // Initialize instance.\n this.init();\n };\n window['MaterialExtAccordion'] = MaterialExtAccordion;\n\n /**\n * Initialize accordion's panels\n *\n * @private\n */\n MaterialExtAccordion.prototype.initAccordion_ = function() {\n\n this.element_.setAttribute('role', 'tablist');\n\n if (this.element_.classList.contains(RIPPLE_EFFECT)) {\n this.element_.classList.add(RIPPLE_EFFECT_IGNORE_EVENTS);\n }\n\n [...this.element_.querySelectorAll(`.${PANEL}`)].forEach( panel => {\n new MaterialExtAccordionPanel(panel, this);\n });\n\n this.element_.classList.add(IS_UPGRADED);\n };\n\n /**\n * Initialize Accordion element.\n */\n MaterialExtAccordion.prototype.init = function() {\n if (this.element_) {\n //console.log('***** init', this.element_.classList, this.element_.getAttribute('data-upgraded'));\n this.initAccordion_();\n }\n };\n\n\n /**\n * Constructor for an individual accordion panel.\n *\n * @constructor\n * @param {Element} panel The HTML element for the tab.\n * @param {MaterialExtAccordion} ctx The MaterialExtAccordion object that owns the panel.\n */\n function MaterialExtAccordionPanel(panel, ctx) {\n\n const header = panel.querySelector(`.${HEADER}`);\n if(header === null) {\n throw new Error('There must be a header element for each accordion panel.');\n }\n\n header.setAttribute('role', 'tab');\n\n let a = header.querySelector(`a.${HEADER_TABSTOP}`);\n if(a === null) {\n // An anchor is required for focus/tab stop\n a = document.createElement('a');\n a.href = '#';\n a.classList.add(HEADER_TABSTOP);\n header.appendChild(a);\n }\n\n panel.setAttribute('role', 'tabpanel');\n\n if(panel.hasAttribute('open')) {\n header.setAttribute('aria-expanded', '');\n }\n else {\n header.setAttribute('aria-hidden', '');\n }\n\n if (ctx.element_.classList.contains(RIPPLE_EFFECT)) {\n const rippleContainer = a;\n rippleContainer.classList.add(RIPPLE_CONTAINER);\n rippleContainer.classList.add(RIPPLE_EFFECT);\n const ripple = document.createElement('span');\n ripple.classList.add(RIPPLE);\n rippleContainer.appendChild(ripple);\n componentHandler.upgradeElement(rippleContainer, RIPPLE_COMPONENT);\n }\n\n header.addEventListener('click', ( event => {\n event.preventDefault();\n event.stopPropagation();\n\n if(!panel.hasAttribute('disabled')) {\n if(panel.hasAttribute('open')) {\n panel.removeAttribute('open');\n header.removeAttribute('aria-expanded');\n header.setAttribute('aria-hidden', '');\n\n // Dispatch toggle event to accordion element\n dispatchToggleEvent('close', panel, ctx.element_);\n }\n else {\n if(ctx.element_.hasAttribute('aria-multiselectable') &&\n 'false' === ctx.element_.getAttribute('aria-multiselectable').toLowerCase()) {\n\n const openPanel = ctx.element_.querySelector(`.${PANEL}[open]`);\n if (openPanel) {\n openPanel.removeAttribute('open');\n const h = openPanel.querySelector(`.${HEADER}`);\n h.removeAttribute('aria-expanded');\n h.setAttribute('aria-hidden', '');\n\n // Dispatch toggle event to accordion element\n dispatchToggleEvent('close', openPanel, ctx.element_);\n }\n removeAriaSelectedAttribute();\n }\n\n panel.setAttribute('open', '');\n header.setAttribute('aria-expanded', '');\n header.setAttribute('aria-selected', '');\n header.removeAttribute('aria-hidden', '');\n\n // Dispatch toggle event to accordion element\n dispatchToggleEvent('open', panel, ctx.element_);\n }\n focus(panel);\n }\n }), true);\n\n\n header.addEventListener('keydown', ( event => {\n if (event.keyCode === VK_TAB\n || event.keyCode === VK_ENTER || event.keyCode === VK_SPACE\n || event.keyCode === VK_END || event.keyCode === VK_HOME\n || event.keyCode === VK_ARROW_UP || event.keyCode === VK_ARROW_LEFT\n || event.keyCode === VK_ARROW_DOWN || event.keyCode === VK_ARROW_RIGHT) {\n\n const panels = panel.parentNode.children;\n let nextPanel = null;\n const n = panel.parentNode.childElementCount - 1;\n\n for (let i = 0; i <= n; i++) {\n\n if (event.keyCode === VK_HOME) {\n nextPanel = panels[0];\n break;\n }\n else if (event.keyCode === VK_END) {\n nextPanel = panels[n];\n break;\n }\n\n if(panels[i] == panel) {\n if(event.keyCode === VK_ARROW_UP || event.keyCode === VK_ARROW_LEFT) {\n nextPanel = i > 0 ? panels[i-1] : panels[n];\n }\n else if (event.keyCode === VK_ARROW_DOWN || event.keyCode === VK_ARROW_RIGHT) {\n nextPanel = i < n ? panels[i+1] : panels[0];\n }\n else if (event.keyCode === VK_TAB) {\n if(event.shiftKey) {\n if(i > 0 && !panels[i-1].hasAttribute('open')) {\n nextPanel = panels[i-1];\n }\n }\n else if (i < n) {\n if(!panel.hasAttribute('open')) {\n nextPanel = panels[i+1];\n }\n }\n }\n else if (event.keyCode === VK_ENTER || event.keyCode === VK_SPACE) {\n event.preventDefault();\n event.stopPropagation();\n\n // Trigger mouse click event for any attached listeners.\n const evt = new MouseEvent('click', {\n bubbles: true,\n cancelable: true,\n view: window\n });\n header.dispatchEvent(evt);\n }\n break;\n }\n }\n if(nextPanel) {\n event.preventDefault();\n event.stopPropagation();\n focus(nextPanel);\n }\n }\n }), true);\n\n function removeAriaSelectedAttribute() {\n const selectedHeader = ctx.element_.querySelector(`.${HEADER}[aria-selected]`);\n if(selectedHeader) {\n selectedHeader.removeAttribute('aria-selected');\n }\n }\n\n function focus(nextPanel) {\n const a = nextPanel.querySelector(`.${HEADER} a`);\n if(a) {\n removeAriaSelectedAttribute();\n a.focus();\n nextPanel.querySelector(`.${HEADER}`).setAttribute('aria-selected', '');\n }\n }\n\n function dispatchToggleEvent(state, source, target) {\n const evt = createCustomEvent('toggle', {\n bubbles: true,\n cancelable: true,\n detail: { state: state, source: source }\n });\n target.dispatchEvent(evt);\n }\n }\n\n // The component registers itself. It can assume componentHandler is available\n // in the global scope.\n /* eslint no-undef: 0 */\n componentHandler.register({\n constructor: MaterialExtAccordion,\n classAsString: 'MaterialExtAccordion',\n cssClass: 'mdlext-js-accordion',\n widget: true\n });\n})();\n\n\n\n/** WEBPACK FOOTER **\n ** ./src/accordion/accordion.js\n **/\n\n\n/** WEBPACK FOOTER **\n ** ./src/accordion/accordion.js\n **/","'use strict';\nimport 'utils/custom-event';\nimport 'sticky-header/sticky-header';\nimport 'selectfield/selectfield';\nimport 'accordion/accordion';\nimport 'lightboard/lightboard';\nimport 'lightbox/lightbox';\n\n\n\n/** WEBPACK FOOTER **\n ** ./src/index.js\n **/\n\n\n/** WEBPACK FOOTER **\n ** ./src/index.js\n **/","/**\n * @license\n * Copyright 2016 Leif Olsen. All Rights Reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n *\n * This code is built with Google Material Design Lite,\n * which is Licensed under the Apache License, Version 2.0\n */\n\n/**\n * A lightboard is a translucent surface illuminated from behind, used for situations\n * where a shape laid upon the surface needs to be seen with high contrast. In the \"old days\" of photography\n * photograpers used a lightboard to get a quick view of their slides. The goal is to create a responsive lightbox\n * design, based on flex layout, similar to what is used in Adobe LightRoom to browse images.\n */\n\nimport { createCustomEvent } from '../utils/custom-event';\n\n(function() {\n 'use strict';\n\n const VK_TAB = 9;\n const VK_ENTER = 13;\n const VK_SPACE = 32;\n const VK_END = 35;\n const VK_HOME = 36;\n const VK_ARROW_LEFT = 37;\n const VK_ARROW_UP = 38;\n const VK_ARROW_RIGHT = 39;\n const VK_ARROW_DOWN = 40;\n\n const IS_UPGRADED = 'is-upgraded';\n const LIGHTBOARD = 'mdlext-lightboard';\n const SLIDE = 'mdlext-lightboard__slide';\n const SLIDE_TABSTOP = 'mdlext-lightboard__slide__frame';\n const RIPPLE_COMPONENT = 'MaterialRipple';\n const RIPPLE = 'mdl-ripple';\n const RIPPLE_CONTAINER = 'mdlext-lightboard__slide__ripple-container';\n const RIPPLE_EFFECT = 'mdl-js-ripple-effect';\n const RIPPLE_EFFECT_IGNORE_EVENTS = 'mdl-js-ripple-effect--ignore-events';\n\n /**\n * @constructor\n * @param {Element} element The element that will be upgraded.\n */\n const MaterialExtLightboard = function MaterialExtLightboard(element) {\n // Stores the element.\n this.element_ = element;\n\n // Initialize instance.\n this.init();\n };\n window['MaterialExtLightboard'] = MaterialExtLightboard;\n\n /**\n * Initialize lightboard slides\n *\n * @private\n */\n MaterialExtLightboard.prototype.initLightboard_ = function() {\n\n this.element_.setAttribute('role', 'grid');\n [...this.element_.querySelectorAll(`.${SLIDE}`)].forEach(\n slide => slide.setAttribute('role', 'cell')\n );\n\n if (this.element_.classList.contains(RIPPLE_EFFECT)) {\n this.element_.classList.add(RIPPLE_EFFECT_IGNORE_EVENTS);\n\n [...this.element_.querySelectorAll(`.${SLIDE}`)].forEach(\n slide => addRipple(slide)\n );\n }\n\n /**\n * Trigger when user cliks on a slide\n */\n this.element_.addEventListener('click', ( function(event) {\n event.preventDefault();\n event.stopPropagation();\n const slide = getSlide(event.target);\n\n if(event.target !== this) {\n focus(slide);\n\n // Remove 'aria-selected' attribute\n [...this.children] // Should I use querySelectorAll ???\n .filter( panel => panel.hasAttribute('aria-selected'))\n .forEach( selected => selected.removeAttribute('aria-selected'));\n\n // Set 'aria-selected' on current slide\n slide.setAttribute('aria-selected', '');\n\n const evt = createCustomEvent('select', {\n bubbles: true,\n cancelable: true,\n detail: { source: slide }\n });\n this.dispatchEvent(evt);\n }\n }).bind(this.element_), true);\n\n /**\n * Trigger when user presses a keboard key\n */\n this.element_.addEventListener('keydown', ( function(event) {\n // Maybe this function should be throttled??\n if (event.keyCode === VK_TAB\n || event.keyCode === VK_ENTER || event.keyCode === VK_SPACE\n || event.keyCode === VK_END || event.keyCode === VK_HOME\n || event.keyCode === VK_ARROW_UP || event.keyCode === VK_ARROW_LEFT\n || event.keyCode === VK_ARROW_DOWN || event.keyCode === VK_ARROW_RIGHT) {\n\n if(event.target !== this) {\n const panel = getSlide(event.target);\n const panels = this.children;\n let nextPanel = null;\n const n = this.childElementCount - 1;\n\n for (let i = 0; i <= n; i++) {\n if (event.keyCode === VK_HOME) {\n nextPanel = panels[0];\n break;\n }\n else if (event.keyCode === VK_END) {\n nextPanel = panels[n];\n break;\n }\n\n if (panels[i] === panel) {\n if (event.keyCode === VK_ARROW_UP || event.keyCode === VK_ARROW_LEFT) {\n nextPanel = i > 0 ? panels[i - 1] : panels[n];\n }\n else if (event.keyCode === VK_ARROW_DOWN || event.keyCode === VK_ARROW_RIGHT) {\n nextPanel = i < n ? panels[i + 1] : panels[0];\n }\n else if (event.keyCode === VK_TAB) {\n if (event.shiftKey) {\n if (i > 0) {\n nextPanel = panels[i - 1];\n }\n }\n else if (i < n) {\n nextPanel = panels[i + 1];\n }\n }\n else if (event.keyCode === VK_ENTER || event.keyCode === VK_SPACE) {\n event.preventDefault();\n event.stopPropagation();\n\n // Trigger mouse click event for any attached listeners.\n const evt = new MouseEvent('click', {\n bubbles: true,\n cancelable: true,\n view: window\n });\n panel.dispatchEvent(evt);\n }\n break;\n }\n }\n if (nextPanel) {\n event.preventDefault();\n event.stopPropagation();\n focus(nextPanel);\n }\n }\n }\n }).bind(this.element_), true);\n\n this.element_.classList.add(IS_UPGRADED);\n };\n\n function getSlide(element) {\n if (!element || element.classList.contains(LIGHTBOARD)) {\n return null;\n }\n return element.classList.contains(SLIDE) ? element : getSlide(element.parentNode);\n }\n\n function focus(slide) {\n if(slide) {\n const a = slide.querySelector(`a.${SLIDE_TABSTOP}`);\n if (a) {\n a.focus();\n }\n }\n }\n\n function addRipple(slide) {\n // Use anchor as ripple container\n const a = slide.querySelector(`a.${SLIDE_TABSTOP}`);\n if(a) {\n const rippleContainer = a;\n rippleContainer.classList.add(RIPPLE_CONTAINER);\n rippleContainer.classList.add(RIPPLE_EFFECT);\n const ripple = document.createElement('span');\n ripple.classList.add(RIPPLE);\n rippleContainer.appendChild(ripple);\n componentHandler.upgradeElement(rippleContainer, RIPPLE_COMPONENT);\n }\n }\n\n /**\n * Initialize component\n */\n MaterialExtLightboard.prototype.init = function() {\n if (this.element_) {\n this.initLightboard_();\n }\n };\n\n // The component registers itself. It can assume componentHandler is available\n // in the global scope.\n /* eslint no-undef: 0 */\n /* jshint undef:false */\n componentHandler.register({\n constructor: MaterialExtLightboard,\n classAsString: 'MaterialExtLightboard',\n cssClass: 'mdlext-js-lightboard',\n widget: true\n });\n})();\n\n\n\n/** WEBPACK FOOTER **\n ** ./src/lightboard/lightboard.js\n **/\n\n\n/** WEBPACK FOOTER **\n ** ./src/lightboard/lightboard.js\n **/","/**\n * @license\n * Copyright 2016 Leif Olsen. All Rights Reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n *\n * This code is built with Google Material Design Lite,\n * which is Licensed under the Apache License, Version 2.0\n */\n\n\n/**\n * Responsive Lightbox\n */\n\nimport { createCustomEvent } from '../utils/custom-event';\n\n(function() {\n 'use strict';\n\n const VK_ESC = 27;\n const VK_SPACE = 32;\n const VK_END = 35;\n const VK_HOME = 36;\n const VK_ARROW_LEFT = 37;\n const VK_ARROW_UP = 38;\n const VK_ARROW_RIGHT = 39;\n const VK_ARROW_DOWN = 40;\n\n const IS_UPGRADED = 'is-upgraded';\n const LIGHTBOX_CLASS = 'mdlext-lightbox';\n const STICKY_FOOTER_CLASS = 'mdlext-lightbox--sticky-footer';\n const BUTTON_CLASS = 'mdl-button';\n\n /**\n * https://github.com/google/material-design-lite/issues/4205\n * @constructor\n * @param {Element} element The element that will be upgraded.\n */\n const MaterialExtLightbox = function MaterialExtLightbox(element) {\n // Stores the element.\n this.element_ = element;\n\n // false: allow rAF to be called, true: blocks rAF\n this.drawing_ = false;\n\n // Initialize instance.\n this.init();\n };\n window['MaterialExtLightbox'] = MaterialExtLightbox;\n\n\n /**\n * Handle keypress\n * @param event\n * @private\n */\n MaterialExtLightbox.prototype.keyDownHandler_ = function(event) {\n\n if (event) {\n if ( event.keyCode === VK_ESC || event.keyCode === VK_SPACE\n || event.keyCode === VK_END || event.keyCode === VK_HOME\n || event.keyCode === VK_ARROW_UP || event.keyCode === VK_ARROW_LEFT\n || event.keyCode === VK_ARROW_DOWN || event.keyCode === VK_ARROW_RIGHT) {\n\n if(event.keyCode !== VK_ESC) {\n event.preventDefault();\n event.stopPropagation();\n }\n\n let action = 'first';\n if (event.keyCode === VK_END) {\n action = 'last';\n }\n else if (event.keyCode === VK_ARROW_UP || event.keyCode === VK_ARROW_LEFT) {\n action = 'prev';\n }\n else if (event.keyCode === VK_ARROW_DOWN || event.keyCode === VK_ARROW_RIGHT) {\n action = 'next';\n }\n else if (event.keyCode === VK_SPACE) {\n action = 'select';\n }\n else if (event.keyCode === VK_ESC) {\n action = 'cancel';\n }\n\n dispatchAction_(action, this);\n }\n }\n };\n\n /**\n * Handle button clicks\n * @param event\n * @private\n */\n MaterialExtLightbox.prototype.buttonClickHandler_ = function(event) {\n\n if (event) {\n event.preventDefault();\n event.stopPropagation();\n\n dispatchAction_(this.getAttribute('data-action') || '', this);\n\n let n = this;\n while((n = n.parentNode) != null) {\n if(n.classList.contains(LIGHTBOX_CLASS)) {\n n.focus();\n break;\n }\n }\n }\n };\n\n /**\n * Dispatches an action custom event\n * @param action\n * @param source\n * @param target\n * @private\n */\n function dispatchAction_(action, source, target = source) {\n\n target.dispatchEvent(createCustomEvent('action', {\n bubbles: true,\n cancelable: true,\n detail: {\n action: action || '',\n source: source\n }\n }));\n }\n\n /**\n * Reposition dialog if component parent element is \"DIALOG\"\n * @param lightboxElement\n * @private\n */\n function repositionDialog_(lightboxElement) {\n const footerHeight = (footer, isSticky) => isSticky && footer ? footer.offsetHeight : 0;\n\n const reposition = (dialog, fh) => {\n if (window.getComputedStyle(dialog).position === 'absolute') {\n const scrollTop = document.body.scrollTop || document.documentElement.scrollTop;\n const topValue = scrollTop + (window.innerHeight - dialog.offsetHeight - fh) / 2;\n dialog.style.top = `${Math.max(scrollTop, topValue)}px`;\n }\n };\n\n const dialog = lightboxElement.parentNode.nodeName === 'DIALOG' ? lightboxElement.parentNode : null;\n if(dialog && dialog.hasAttribute('open')) {\n lightboxElement.style.width = 'auto';\n lightboxElement.style.maxWidth = '100%';\n const img = lightboxElement.querySelector('img');\n if(img) {\n lightboxElement.style.maxWidth = img.naturalWidth !== 'undefined' ? `${img.naturalWidth}px` : `${img.width}px` || '100%';\n }\n\n const fh = footerHeight(lightboxElement.querySelector('footer'), lightboxElement.classList.contains(STICKY_FOOTER_CLASS));\n const vh = Math.max(document.documentElement.clientHeight, window.innerHeight || 0) - fh;\n if (dialog.offsetHeight > vh) {\n let n = 0;\n while(dialog.offsetHeight > vh && ++n < 4) {\n lightboxElement.style.width = `${lightboxElement.offsetWidth * vh / lightboxElement.offsetHeight}px`;\n }\n }\n reposition(dialog, fh);\n }\n }\n\n /**\n * Handle image load\n * @param event\n * @private\n */\n\n MaterialExtLightbox.prototype.imgLoadHandler_ = function( /*event*/ ) {\n repositionDialog_(this);\n };\n\n\n /**\n * Handle image drag\n * @param event\n * @private\n */\n MaterialExtLightbox.prototype.imgDragHandler_ = function(event ) {\n\n const setStyles = ( element, properties ) => {\n //noinspection JSAnnotator\n for(const [key, value] of Object.entries(properties)) {\n element.style[key] = value;\n }\n // ... or:\n //for (const key in properties) {\n // element.style[key] = properties[key];\n //}\n };\n\n event.preventDefault();\n //event.stopPropagation();\n\n const x = event.clientX || (event.touches !== undefined ? event.touches[0].clientX : 0);\n\n const img = this;\n img.style.opacity = '0.2';\n\n const slider = document.createElement('div');\n slider.classList.add('mdlext-lightbox__slider');\n setStyles(slider, {'width': `${img.offsetWidth}px`, 'height': `${img.offsetHeight}px`} );\n\n let slide = document.createElement('div');\n slide.classList.add('mdlext-lightbox__slider__slide');\n slide.textContent = '>';\n setStyles(slide, {\n 'width' : `${img.offsetWidth}px`,\n 'height' : `${img.offsetHeight}px`,\n 'line-height' : `${img.offsetHeight}px`,\n 'font-size' : `${img.offsetHeight/4}px`,\n 'text-align' : 'right',\n 'background-image': `url(\"${img.getAttribute('data-img-url-prev') || ''}\")`\n });\n slider.appendChild(slide);\n\n slide = document.createElement('div');\n slide.classList.add('mdlext-lightbox__slider__slide');\n setStyles(slide, {\n 'width' : `${img.offsetWidth}px`,\n 'height' : `${img.offsetHeight}px`,\n 'background-image': `url(\"${img.src}\")`\n });\n slider.appendChild(slide);\n\n slide = document.createElement('div');\n slide.classList.add('mdlext-lightbox__slider__slide');\n slide.textContent = '<';\n setStyles(slide, {\n 'width' : `${img.offsetWidth}px`,\n 'height' : `${img.offsetHeight}px`,\n 'line-height' : `${img.offsetHeight}px`,\n 'font-size' : `${img.offsetHeight/4}px`,\n 'text-align' : 'left',\n 'background-image': `url(\"${img.getAttribute('data-img-url-next') || ''}\")`\n });\n slider.appendChild(slide);\n\n img.parentNode.appendChild(slider);\n\n\n // drag handler\n const drag = e => {\n e.preventDefault();\n const dx = (e.clientX || (e.touches !== undefined ? e.touches[0].clientX : 0)) - x; // TODO: maybe rewrite to improve performance\n\n if(slider.offsetWidth - Math.abs(dx) > 19) {\n slider.style.left = `${dx}px`;\n }\n };\n\n // end drag handler\n const endDrag = e => {\n e.preventDefault();\n //e.stopPropagation();\n\n window.removeEventListener('mousemove', drag);\n window.removeEventListener('touchmove', drag);\n window.removeEventListener('mouseup', endDrag);\n window.removeEventListener('touchend', endDrag);\n\n const dx = slider.offsetLeft;\n img.parentNode.removeChild(slider);\n img.style.opacity = '1.0';\n\n if(Math.abs(dx) > 19) {\n dispatchAction_( (dx > 0 ? 'prev' : 'next') , img);\n }\n };\n\n window.addEventListener('mousemove', drag);\n window.addEventListener('touchmove', drag);\n window.addEventListener('mouseup', endDrag); // .bind(this) does not work here\n window.addEventListener('touchend',endDrag);\n };\n\n\n /**\n * Initialize component\n */\n MaterialExtLightbox.prototype.init = function() {\n\n if (this.element_) {\n // Do the init required for this component to work\n this.element_.addEventListener('keydown', this.keyDownHandler_.bind(this.element_), true);\n\n if(!Number.isInteger(this.element_.getAttribute('tabindex'))) {\n this.element_.setAttribute('tabindex', 1);\n }\n\n [...this.element_.querySelectorAll(`.${BUTTON_CLASS}`)].forEach( button =>\n button.addEventListener('click', this.buttonClickHandler_.bind(button), false)\n );\n\n const figcaption = this.element_.querySelector('figcaption');\n if(figcaption) {\n figcaption.addEventListener('click', this.buttonClickHandler_.bind(figcaption), false);\n }\n\n const footer = this.element_.querySelector('footer');\n if(footer) {\n footer.addEventListener('click', this.buttonClickHandler_.bind(footer), false);\n }\n\n const img = this.element_.querySelector('img');\n if(img) {\n img.addEventListener('load', this.imgLoadHandler_.bind(this.element_), false);\n img.addEventListener('click', e => e.preventDefault(), true);\n img.addEventListener('mousedown', this.imgDragHandler_.bind(img), true);\n img.addEventListener('touchstart', this.imgDragHandler_.bind(img), true);\n }\n\n // See: https://developer.mozilla.org/ru/docs/Web/Events/resize\n window.addEventListener('resize', () => {\n if(!this.drawing_) {\n // Assumes MDL has polyfilled rAF\n window.requestAnimationFrame( () => {\n repositionDialog_(this.element_);\n this.drawing_ = false;\n });\n }\n this.drawing_ = true;\n });\n\n window.addEventListener('orientationchange', () => repositionDialog_(this.element_));\n\n // Set upgraded flag\n this.element_.classList.add(IS_UPGRADED);\n }\n };\n\n /*\n * Downgrade component\n * E.g remove listeners and clean up resources\n * Note: There is a bug i material component container; downgrade is never called!\n * Disables method temporarly to keep code coverage at 100% for functions.\n *\n\n MaterialExtLightbox.prototype.mdlDowngrade_ = function() {\n\n if (this.element_) {\n [...this.element_.querySelectorAll(`.${BUTTON_CLASS}`)].forEach(\n button => button.removeEventListener('click', this.buttonClickHandler_)\n );\n\n this.element_.removeEventListener('keydown', this.keyDownHandler_);\n }\n };\n */\n\n /**\n * The component registers itself. It can assume componentHandler is available in the global scope.\n */\n /* jshint undef:false */\n componentHandler.register({\n constructor: MaterialExtLightbox,\n classAsString: 'MaterialExtLightbox',\n cssClass: 'mdlext-js-lightbox'\n });\n})();\n\n\n\n/** WEBPACK FOOTER **\n ** ./src/lightbox/lightbox.js\n **/\n\n\n/** WEBPACK FOOTER **\n ** ./src/lightbox/lightbox.js\n **/","/**\n * @license\n * Copyright 2016 Leif Olsen. All Rights Reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n *\n * This code is built with Google Material Design Lite,\n * which is Licensed under the Apache License, Version 2.0\n */\n\n/*\n * Copied/Modified from https://github.com/google/material-design-lite/tree/master/src/textfield\n */\n\n(function() {\n 'use strict';\n\n /**\n * Class constructor for Selectfield MDLEXT component.\n * Implements MDL component design pattern defined at:\n * https://github.com/jasonmayes/mdl-component-design-pattern\n *\n * @constructor\n * @param {HTMLElement} element The element that will be upgraded.\n */\n const MaterialExtSelectfield = function MaterialExtSelectfield(element) {\n this.element_ = element;\n this.init(); // Initialize instance.\n };\n\n window['MaterialExtSelectfield'] = MaterialExtSelectfield;\n\n /**\n * Store constants in one place so they can be updated easily.\n *\n * @enum {string | number}\n * @private\n */\n MaterialExtSelectfield.prototype.Constant_ = {\n };\n\n /**\n * Store strings for class names defined by this component that are used in\n * JavaScript. This allows us to simply change it in one place should we\n * decide to modify at a later date.\n *\n * @enum {string}\n * @private\n */\n MaterialExtSelectfield.prototype.CssClasses_ = {\n LABEL: 'mdlext-selectfield__label',\n INPUT: 'mdlext-selectfield__select',\n IS_DIRTY: 'is-dirty',\n IS_FOCUSED: 'is-focused',\n IS_DISABLED: 'is-disabled',\n IS_INVALID: 'is-invalid',\n IS_UPGRADED: 'is-upgraded'\n };\n\n /**\n * Handle focus.\n *\n * @param {Event} event The event that fired.\n * @private\n */\n /*eslint no-unused-vars: 0*/\n MaterialExtSelectfield.prototype.onFocus_ = function(event) {\n this.element_.classList.add(this.CssClasses_.IS_FOCUSED);\n };\n\n /**\n * Handle lost focus.\n *\n * @param {Event} event The event that fired.\n * @private\n */\n /*eslint no-unused-vars: 0*/\n MaterialExtSelectfield.prototype.onBlur_ = function(event) {\n this.element_.classList.remove(this.CssClasses_.IS_FOCUSED);\n };\n\n /**\n * Handle reset event from out side.\n *\n * @param {Event} event The event that fired.\n * @private\n */\n MaterialExtSelectfield.prototype.onReset_ = function(event) {\n this.updateClasses_();\n };\n\n /**\n * Handle class updates.\n *\n * @private\n */\n MaterialExtSelectfield.prototype.updateClasses_ = function() {\n this.checkDisabled();\n this.checkValidity();\n this.checkDirty();\n this.checkFocus();\n };\n\n // Public methods.\n\n /**\n * Check the disabled state and update field accordingly.\n *\n * @public\n */\n MaterialExtSelectfield.prototype.checkDisabled = function() {\n if (this.select_.disabled) {\n this.element_.classList.add(this.CssClasses_.IS_DISABLED);\n } else {\n this.element_.classList.remove(this.CssClasses_.IS_DISABLED);\n }\n };\n MaterialExtSelectfield.prototype['checkDisabled'] = MaterialExtSelectfield.prototype.checkDisabled;\n\n\n /**\n * Check the focus state and update field accordingly.\n *\n * @public\n */\n MaterialExtSelectfield.prototype.checkFocus = function() {\n /*eslint no-extra-boolean-cast: 0*/\n if (Boolean(this.element_.querySelector(':focus'))) {\n this.element_.classList.add(this.CssClasses_.IS_FOCUSED);\n } else {\n this.element_.classList.remove(this.CssClasses_.IS_FOCUSED);\n }\n };\n\n MaterialExtSelectfield.prototype['checkFocus'] = MaterialExtSelectfield.prototype.checkFocus;\n\n\n /**\n * Check the validity state and update field accordingly.\n *\n * @public\n */\n MaterialExtSelectfield.prototype.checkValidity = function() {\n\n /* Don't think it makes any sense to check validity.\n Tests I've done, so far, indicates that setting an illegal value via JS returns selectedIndex=0\n\n if (this.select_.validity) {\n if (this.select_.validity.valid) {\n this.element_.classList.remove(this.CssClasses_.IS_INVALID);\n } else {\n this.element_.classList.add(this.CssClasses_.IS_INVALID);\n }\n }\n */\n };\n\n MaterialExtSelectfield.prototype['checkValidity'] = MaterialExtSelectfield.prototype.checkValidity;\n\n /**\n * Check the dirty state and update field accordingly.\n *\n * @public\n */\n MaterialExtSelectfield.prototype.checkDirty = function() {\n if (this.select_.value && this.select_.value.length > 0) {\n this.element_.classList.add(this.CssClasses_.IS_DIRTY);\n } else {\n this.element_.classList.remove(this.CssClasses_.IS_DIRTY);\n }\n };\n\n MaterialExtSelectfield.prototype['checkDirty'] = MaterialExtSelectfield.prototype.checkDirty;\n\n /**\n * Disable select field.\n *\n * @public\n */\n MaterialExtSelectfield.prototype.disable = function() {\n this.select_.disabled = true;\n this.updateClasses_();\n };\n\n MaterialExtSelectfield.prototype['disable'] = MaterialExtSelectfield.prototype.disable;\n\n /**\n * Enable select field.\n *\n * @public\n */\n MaterialExtSelectfield.prototype.enable = function() {\n this.select_.disabled = false;\n this.updateClasses_();\n };\n\n MaterialExtSelectfield.prototype['enable'] = MaterialExtSelectfield.prototype.enable;\n\n /**\n * Update select field value.\n *\n * @param {string} value The value to which to set the control (optional).\n * @public\n */\n MaterialExtSelectfield.prototype.change = function(value) {\n this.select_.value = value || '';\n this.updateClasses_();\n };\n MaterialExtSelectfield.prototype['change'] = MaterialExtSelectfield.prototype.change;\n\n /**\n * Initialize element.\n */\n MaterialExtSelectfield.prototype.init = function() {\n if (this.element_) {\n this.label_ = this.element_.querySelector(`.${this.CssClasses_.LABEL}`);\n this.select_ = this.element_.querySelector(`.${this.CssClasses_.INPUT}`);\n\n if (this.select_) {\n this.boundUpdateClassesHandler = this.updateClasses_.bind(this);\n this.boundFocusHandler = this.onFocus_.bind(this);\n this.boundBlurHandler = this.onBlur_.bind(this);\n this.boundResetHandler = this.onReset_.bind(this);\n this.select_.addEventListener('change', this.boundUpdateClassesHandler);\n this.select_.addEventListener('focus', this.boundFocusHandler);\n this.select_.addEventListener('blur', this.boundBlurHandler);\n this.select_.addEventListener('reset', this.boundResetHandler);\n\n const invalid = this.element_.classList.contains(this.CssClasses_.IS_INVALID);\n this.updateClasses_();\n this.element_.classList.add(this.CssClasses_.IS_UPGRADED);\n\n if (invalid) {\n this.element_.classList.add(this.CssClasses_.IS_INVALID);\n }\n if (this.select_.hasAttribute('autofocus')) {\n this.element_.focus();\n this.checkFocus();\n }\n }\n }\n };\n\n // The component registers itself. It can assume componentHandler is available\n // in the global scope.\n /*eslint no-undef: 0*/\n /*jshint undef:false */\n componentHandler.register({\n constructor: MaterialExtSelectfield,\n classAsString: 'MaterialExtSelectfield',\n cssClass: 'mdlext-js-selectfield',\n widget: true\n });\n})();\n\n\n\n/** WEBPACK FOOTER **\n ** ./src/selectfield/selectfield.js\n **/\n\n\n/** WEBPACK FOOTER **\n ** ./src/selectfield/selectfield.js\n **/","/**\n * @license\n * Copyright 2016 Leif Olsen. All Rights Reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n *\n * This code is built with Google Material Design Lite,\n * which is Licensed under the Apache License, Version 2.0\n */\n\n/**\n * A sticky header makes site navigation easily accessible anywhere on the page and saves content space at the same.\n * The header should auto-hide, i.e. hiding the header automatically when a user starts scrolling down the page and\n * bringing the header back when a user might need it: they reach the bottom of the page or start scrolling up.\n */\n\n(function() {\n 'use strict';\n\n const IS_UPGRADED = 'is-upgraded';\n const CONTENT_CLASS = 'mdl-layout__content';\n const IS_SCROLL_CLASS = 'mdlext-is-scroll';\n //const STICKY_HEADER_CLASS = 'mdlext-layout__sticky-header';\n\n\n /**\n * @constructor\n * @param {Element} element The element that will be upgraded.\n */\n const MaterialExtStickyHeader = function MaterialExtStickyHeader(element) {\n // Stores the element.\n this.header_ = element;\n\n // Heder listens to scroll events from content\n this.content_ = null;\n this.lastScrollTop_ = 0;\n\n // false: allow rAF to be called, true: blocks rAF\n this.drawing_ = false;\n\n // Initialize instance.\n this.init();\n };\n\n window['MaterialExtStickyHeader'] = MaterialExtStickyHeader;\n\n\n /**\n * Update header width\n * @private\n */\n MaterialExtStickyHeader.prototype.recalcWidth_ = function() {\n this.header_.style.width = `${this.content_.clientWidth}px`;\n };\n\n /**\n * Adjust header width when window resizes or oreientation changes\n * @param event\n * @private\n */\n MaterialExtStickyHeader.prototype.resizeHandler_ = function( /* event */ ) {\n\n // See: https://developer.mozilla.org/ru/docs/Web/Events/resize\n if(!this.drawing_) {\n // Assumes MDL has polyfilled rAF\n window.requestAnimationFrame( () => {\n this.recalcWidth_();\n this.drawing_ = false;\n });\n }\n this.drawing_ = true;\n };\n\n\n /**\n * Update header position\n * @private\n */\n MaterialExtStickyHeader.prototype.reposition_ = function() {\n\n const currentContentScrollTop = this.content_.scrollTop;\n const scrollDiff = this.lastScrollTop_ - currentContentScrollTop;\n const headerTop = (parseInt( window.getComputedStyle( this.header_ ).getPropertyValue( 'top' ) ) || 0) + scrollDiff;\n\n if(currentContentScrollTop <= 0) {\n // Scrolled to the top. Header sticks to the top\n this.header_.style.top = '0';\n this.header_.classList.remove(IS_SCROLL_CLASS);\n }\n else if(scrollDiff > 0) {\n // Scrolled up. Header slides in\n this.header_.style.top = `${( headerTop > 0 ? 0 : headerTop )}px`;\n this.header_.classList.add(IS_SCROLL_CLASS);\n }\n else if(scrollDiff < 0) {\n // Scrolled down\n this.header_.classList.add(IS_SCROLL_CLASS);\n\n if (this.content_.scrollHeight - this.content_.scrollTop <= this.content_.offsetHeight) {\n // Bottom of content\n this.header_.style.top = '0';\n }\n else {\n const offsetHeight = this.header_.offsetHeight;\n this.header_.style.top = `${( Math.abs( headerTop ) > offsetHeight ? -offsetHeight : headerTop )}px`;\n }\n }\n\n this.lastScrollTop_ = currentContentScrollTop;\n };\n\n /**\n * Scroll header when content scrolls\n * @param event\n * @private\n */\n MaterialExtStickyHeader.prototype.scrollHandler_ = function( /* event */ ) {\n // See: https://developer.mozilla.org/ru/docs/Web/Events/resize\n if(!this.drawing_) {\n window.requestAnimationFrame( () => {\n this.reposition_();\n this.drawing_ = false;\n });\n }\n this.drawing_ = true;\n };\n\n /**\n * Init header position\n * @private\n */\n MaterialExtStickyHeader.prototype.updatePosition_ = function( /* event */ ) {\n this.recalcWidth_();\n this.reposition_();\n };\n\n /**\n * Initialize component\n */\n MaterialExtStickyHeader.prototype.init = function() {\n\n if (this.header_) {\n this.content_ = this.header_.parentNode.querySelector(`.${CONTENT_CLASS}`) || null;\n\n if(this.content_) {\n this.content_.style.paddingTop = `${this.header_.offsetHeight}px`; // Make room for sticky header\n this.lastScrollTop_ = this.content_.scrollTop;\n\n this.content_.addEventListener('scroll', this.scrollHandler_.bind(this));\n window.addEventListener('resize', this.resizeHandler_.bind(this));\n window.addEventListener('orientationchange', this.resizeHandler_.bind(this));\n\n // Adjust header width if content changes (e.g. in a SPA)\n const MutationObserver = window.MutationObserver || window.WebKitMutationObserver || window.MozMutationObserver;\n\n\n // jsdom does not support MutationObserver - so this is not testable\n /* istanbul ignore next */\n new MutationObserver( ( /*mutations*/ ) => {\n\n if(!this.drawing_) {\n window.requestAnimationFrame( () => {\n this.updatePosition_();\n this.drawing_ = false;\n });\n }\n this.drawing_ = true;\n\n }).observe( this.content_, {\n attributes: false,\n childList: true,\n characterData: false\n });\n\n // Set initial position\n this.updatePosition_();\n\n // Set upgraded flag\n this.header_.classList.add(IS_UPGRADED);\n }\n }\n };\n\n /*\n * Downgrade component\n * E.g remove listeners and clean up resources\n * Note: There is a bug i material component container; downgrade is never called!\n * Disables method temporarly to keep code coverage at 100% for functions.\n *\n MaterialExtStickyHeader.prototype.mdlDowngrade_ = function() {\n 'use strict';\n };\n */\n\n\n // The component registers itself. It can assume componentHandler is available\n // in the global scope.\n /* eslint no-undef: 0 */\n componentHandler.register({\n constructor: MaterialExtStickyHeader,\n classAsString: 'MaterialExtStickyHeader',\n cssClass: 'mdlext-js-sticky-header'\n });\n})();\n\n\n\n/** WEBPACK FOOTER **\n ** ./src/sticky-header/sticky-header.js\n **/\n\n\n/** WEBPACK FOOTER **\n ** ./src/sticky-header/sticky-header.js\n **/","module.exports = { \"default\": require(\"core-js/library/fn/array/from\"), __esModule: true };\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/core-js/array/from.js\n ** module id = 42\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/core-js/array/from.js\n ** module id = 42\n ** module chunks = 0 1\n **/","module.exports = { \"default\": require(\"core-js/library/fn/is-iterable\"), __esModule: true };\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/core-js/is-iterable.js\n ** module id = 43\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/core-js/is-iterable.js\n ** module id = 43\n ** module chunks = 0 1\n **/","module.exports = { \"default\": require(\"core-js/library/fn/number/is-integer\"), __esModule: true };\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/core-js/number/is-integer.js\n ** module id = 44\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/core-js/number/is-integer.js\n ** module id = 44\n ** module chunks = 0 1\n **/","module.exports = { \"default\": require(\"core-js/library/fn/object/entries\"), __esModule: true };\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/core-js/object/entries.js\n ** module id = 45\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/core-js/object/entries.js\n ** module id = 45\n ** module chunks = 0 1\n **/","\"use strict\";\n\nexports.__esModule = true;\n\nvar _isIterable2 = require(\"babel-runtime/core-js/is-iterable\");\n\nvar _isIterable3 = _interopRequireDefault(_isIterable2);\n\nvar _getIterator2 = require(\"babel-runtime/core-js/get-iterator\");\n\nvar _getIterator3 = _interopRequireDefault(_getIterator2);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nexports.default = function () {\n function sliceIterator(arr, i) {\n var _arr = [];\n var _n = true;\n var _d = false;\n var _e = undefined;\n\n try {\n for (var _i = (0, _getIterator3.default)(arr), _s; !(_n = (_s = _i.next()).done); _n = true) {\n _arr.push(_s.value);\n\n if (i && _arr.length === i) break;\n }\n } catch (err) {\n _d = true;\n _e = err;\n } finally {\n try {\n if (!_n && _i[\"return\"]) _i[\"return\"]();\n } finally {\n if (_d) throw _e;\n }\n }\n\n return _arr;\n }\n\n return function (arr, i) {\n if (Array.isArray(arr)) {\n return arr;\n } else if ((0, _isIterable3.default)(Object(arr))) {\n return sliceIterator(arr, i);\n } else {\n throw new TypeError(\"Invalid attempt to destructure non-iterable instance\");\n }\n };\n}();\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/helpers/slicedToArray.js\n ** module id = 46\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/helpers/slicedToArray.js\n ** module id = 46\n ** module chunks = 0 1\n **/","require('../../modules/es6.string.iterator');\nrequire('../../modules/es6.array.from');\nmodule.exports = require('../../modules/_core').Array.from;\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/fn/array/from.js\n ** module id = 47\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/fn/array/from.js\n ** module id = 47\n ** module chunks = 0 1\n **/","require('../modules/web.dom.iterable');\nrequire('../modules/es6.string.iterator');\nmodule.exports = require('../modules/core.get-iterator');\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/fn/get-iterator.js\n ** module id = 48\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/fn/get-iterator.js\n ** module id = 48\n ** module chunks = 0 1\n **/","require('../modules/web.dom.iterable');\nrequire('../modules/es6.string.iterator');\nmodule.exports = require('../modules/core.is-iterable');\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/fn/is-iterable.js\n ** module id = 49\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/fn/is-iterable.js\n ** module id = 49\n ** module chunks = 0 1\n **/","require('../../modules/es6.number.is-integer');\nmodule.exports = require('../../modules/_core').Number.isInteger;\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/fn/number/is-integer.js\n ** module id = 50\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/fn/number/is-integer.js\n ** module id = 50\n ** module chunks = 0 1\n **/","require('../../modules/es7.object.entries');\nmodule.exports = require('../../modules/_core').Object.entries;\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/fn/object/entries.js\n ** module id = 51\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/fn/object/entries.js\n ** module id = 51\n ** module chunks = 0 1\n **/","module.exports = function(it){\n if(typeof it != 'function')throw TypeError(it + ' is not a function!');\n return it;\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_a-function.js\n ** module id = 52\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_a-function.js\n ** module id = 52\n ** module chunks = 0 1\n **/","module.exports = function(){ /* empty */ };\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_add-to-unscopables.js\n ** module id = 53\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_add-to-unscopables.js\n ** module id = 53\n ** module chunks = 0 1\n **/","// false -> Array#indexOf\n// true -> Array#includes\nvar toIObject = require('./_to-iobject')\n , toLength = require('./_to-length')\n , toIndex = require('./_to-index');\nmodule.exports = function(IS_INCLUDES){\n return function($this, el, fromIndex){\n var O = toIObject($this)\n , length = toLength(O.length)\n , index = toIndex(fromIndex, length)\n , value;\n // Array#includes uses SameValueZero equality algorithm\n if(IS_INCLUDES && el != el)while(length > index){\n value = O[index++];\n if(value != value)return true;\n // Array#toIndex ignores holes, Array#includes - not\n } else for(;length > index; index++)if(IS_INCLUDES || index in O){\n if(O[index] === el)return IS_INCLUDES || index || 0;\n } return !IS_INCLUDES && -1;\n };\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_array-includes.js\n ** module id = 54\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_array-includes.js\n ** module id = 54\n ** module chunks = 0 1\n **/","'use strict';\r\nvar $defineProperty = require('./_object-dp')\r\n , createDesc = require('./_property-desc');\r\n\r\nmodule.exports = function(object, index, value){\r\n if(index in object)$defineProperty.f(object, index, createDesc(0, value));\r\n else object[index] = value;\r\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_create-property.js\n ** module id = 55\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_create-property.js\n ** module id = 55\n ** module chunks = 0 1\n **/","module.exports = require('./_global').document && document.documentElement;\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_html.js\n ** module id = 56\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_html.js\n ** module id = 56\n ** module chunks = 0 1\n **/","module.exports = !require('./_descriptors') && !require('./_fails')(function(){\r\n return Object.defineProperty(require('./_dom-create')('div'), 'a', {get: function(){ return 7; }}).a != 7;\r\n});\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_ie8-dom-define.js\n ** module id = 57\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_ie8-dom-define.js\n ** module id = 57\n ** module chunks = 0 1\n **/","// fallback for non-array-like ES3 and non-enumerable old V8 strings\nvar cof = require('./_cof');\nmodule.exports = Object('z').propertyIsEnumerable(0) ? Object : function(it){\n return cof(it) == 'String' ? it.split('') : Object(it);\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_iobject.js\n ** module id = 58\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_iobject.js\n ** module id = 58\n ** module chunks = 0 1\n **/","// check on default Array iterator\nvar Iterators = require('./_iterators')\n , ITERATOR = require('./_wks')('iterator')\n , ArrayProto = Array.prototype;\n\nmodule.exports = function(it){\n return it !== undefined && (Iterators.Array === it || ArrayProto[ITERATOR] === it);\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_is-array-iter.js\n ** module id = 59\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_is-array-iter.js\n ** module id = 59\n ** module chunks = 0 1\n **/","// 20.1.2.3 Number.isInteger(number)\nvar isObject = require('./_is-object')\n , floor = Math.floor;\nmodule.exports = function isInteger(it){\n return !isObject(it) && isFinite(it) && floor(it) === it;\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_is-integer.js\n ** module id = 60\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_is-integer.js\n ** module id = 60\n ** module chunks = 0 1\n **/","// call something on iterator step with safe closing on error\nvar anObject = require('./_an-object');\nmodule.exports = function(iterator, fn, value, entries){\n try {\n return entries ? fn(anObject(value)[0], value[1]) : fn(value);\n // 7.4.6 IteratorClose(iterator, completion)\n } catch(e){\n var ret = iterator['return'];\n if(ret !== undefined)anObject(ret.call(iterator));\n throw e;\n }\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_iter-call.js\n ** module id = 61\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_iter-call.js\n ** module id = 61\n ** module chunks = 0 1\n **/","'use strict';\nvar create = require('./_object-create')\n , descriptor = require('./_property-desc')\n , setToStringTag = require('./_set-to-string-tag')\n , IteratorPrototype = {};\n\n// 25.1.2.1.1 %IteratorPrototype%[@@iterator]()\nrequire('./_hide')(IteratorPrototype, require('./_wks')('iterator'), function(){ return this; });\n\nmodule.exports = function(Constructor, NAME, next){\n Constructor.prototype = create(IteratorPrototype, {next: descriptor(1, next)});\n setToStringTag(Constructor, NAME + ' Iterator');\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_iter-create.js\n ** module id = 62\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_iter-create.js\n ** module id = 62\n ** module chunks = 0 1\n **/","var ITERATOR = require('./_wks')('iterator')\n , SAFE_CLOSING = false;\n\ntry {\n var riter = [7][ITERATOR]();\n riter['return'] = function(){ SAFE_CLOSING = true; };\n Array.from(riter, function(){ throw 2; });\n} catch(e){ /* empty */ }\n\nmodule.exports = function(exec, skipClosing){\n if(!skipClosing && !SAFE_CLOSING)return false;\n var safe = false;\n try {\n var arr = [7]\n , iter = arr[ITERATOR]();\n iter.next = function(){ return {done: safe = true}; };\n arr[ITERATOR] = function(){ return iter; };\n exec(arr);\n } catch(e){ /* empty */ }\n return safe;\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_iter-detect.js\n ** module id = 63\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_iter-detect.js\n ** module id = 63\n ** module chunks = 0 1\n **/","module.exports = function(done, value){\n return {value: value, done: !!done};\n};\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_iter-step.js\n ** module id = 64\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_iter-step.js\n ** module id = 64\n ** module chunks = 0 1\n **/","module.exports = true;\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_library.js\n ** module id = 65\n ** module chunks = 0 1\n **/\n\n\n/*****************\n ** WEBPACK FOOTER\n ** ./~/babel-runtime/~/core-js/library/modules/_library.js\n ** module id = 65\n ** module chunks = 0 1\n **/","// 19.1.2.2 / 15.2.3.5 Object.create(O [, Properties])\r\nvar anObject = require('./_an-object')\r\n , dPs = require('./_object-dps')\r\n , enumBugKeys = require('./_enum-bug-keys')\r\n , IE_PROTO = require('./_shared-key')('IE_PROTO')\r\n , Empty = function(){ /* empty */ }\r\n , PROTOTYPE = 'prototype';\r\n\r\n// Create object with fake `null` prototype: use iframe Object with cleared prototype\r\nvar createDict = function(){\r\n // Thrash, waste and sodomy: IE GC bug\r\n var iframe = require('./_dom-create')('iframe')\r\n , i = enumBugKeys.length\r\n , gt = '>'\r\n , iframeDocument;\r\n iframe.style.display = 'none';\r\n require('./_html').appendChild(iframe);\r\n iframe.src = 'javascript:'; // eslint-disable-line no-script-url\r\n // createDict = iframe.contentWindow.Object;\r\n // html.removeChild(iframe);\r\n iframeDocument = iframe.contentWindow.document;\r\n iframeDocument.open();\r\n iframeDocument.write(' diff --git a/src/demo/include/_index.html b/src/demo/include/_index.html index 0598a6d..21ef6b9 100644 --- a/src/demo/include/_index.html +++ b/src/demo/include/_index.html @@ -38,3 +38,6 @@

Selectfield

The Material Design Lite Ext (MDLEXT) select field component is an enhanced version of the standard [HTML <select> element.

+ +

Sticky Header

+

A sticky header makes site navigation easily accessible anywhere on the page and saves content space at the same.

diff --git a/test/accordion/accordion.spec.js b/test/accordion/accordion.spec.js index a7bc640..222d00c 100644 --- a/test/accordion/accordion.spec.js +++ b/test/accordion/accordion.spec.js @@ -130,7 +130,7 @@ describe('MaterialExtAccordion', () => {

Maecenas eu vestibulum orci. Ut eget nisi a est sagittis euismod a vel.

-
  • +
  • Fifth
    @@ -539,6 +539,57 @@ describe('MaterialExtAccordion', () => { expect(check).to.have.length.of.at.least(2); }); + it('should toggle using command custom event', () => { + const accordion = qs('#multi-accordion'); + assert.isNotNull(accordion, 'Expected handle to accordion'); + + const panel = qs('#multi-accordion .mdlext-accordion__panel:nth-child(2)'); + assert.isNotNull(panel, 'Expected handle to accordion panel'); + + const isOpen = panel.hasAttribute('open'); + let ev = new CustomEvent('command', { detail: { action : 'toggle', target: panel } } ); + accordion.dispatchEvent(ev); + + assert.notEqual(panel.hasAttribute('open'), isOpen, 'Expected panel to toggle'); + + ev = new CustomEvent('command', { detail: { action : 'toggle', target: panel } } ); + accordion.dispatchEvent(ev); + assert.equal(panel.hasAttribute('open'), isOpen, 'Expected panel to toggle'); + }); + + it('should not open a panel having attribute "disabled"', () => { + const accordion = qs('#multi-accordion'); + assert.isNotNull(accordion, 'Expected handle to accordion'); + + const panel = qs('#disabled-panel'); + assert.isNotNull(panel, 'Expected handle to accordion panel'); + panel.setAttribute('disabled', ''); + + const ev = new CustomEvent('command', { detail: { action : 'open', target: panel } } ); + accordion.dispatchEvent(ev); + + assert.isFalse(panel.hasAttribute('open'), 'Did not expect disabled panel to open'); + }); + + it('should expand all panels not having attribute "disabled"', () => { + const accordion = qs('#multi-accordion'); + assert.isNotNull(accordion, 'Expected handle to accordion'); + + // First close all panels + let ev = new CustomEvent('command', { detail: { action : 'close' } } ); + accordion.dispatchEvent(ev); + + let openPanels = qsa('#multi-accordion .mdlext-accordion__panel[open]'); + assert.equal(openPanels.length, 0, 'Expected all panels to be closed'); + + // Open all panels not having attribute "disabled" + ev = new CustomEvent('command', { detail: { action : 'open' } } ); + accordion.dispatchEvent(ev); + + const allPanels = qsa('#multi-accordion .mdlext-accordion__panel'); + openPanels = qsa('#multi-accordion .mdlext-accordion__panel[open]'); + assert.equal(allPanels.length - openPanels.length, 1, `Expected ${openPanels.length} to have attribute "open"`); + }); function spyOnKeyboardEvent(target, keyCode, shiftKey=false) {