preact-material-components
Version:
preact wrapper for "Material Components for the web"
249 lines • 314 kB
JavaScript
!function(t,e){if("object"==typeof exports&&"object"==typeof module)module.exports=e(require("preact"));else if("function"==typeof define&&define.amd)define(["preact"],e);else{var i="object"==typeof exports?e(require("preact")):e(t.preact);for(var n in i)("object"==typeof exports?exports:t)[n]=i[n]}}(window,(function(t){return function(t){var e={};function i(n){if(e[n])return e[n].exports;var s=e[n]={i:n,l:!1,exports:{}};return t[n].call(s.exports,s,s.exports,i),s.l=!0,s.exports}return i.m=t,i.c=e,i.d=function(t,e,n){i.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},i.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},i.t=function(t,e){if(1&e&&(t=i(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(i.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var s in t)i.d(n,s,function(e){return t[e]}.bind(null,s));return n},i.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return i.d(e,"a",e),e},i.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},i.p="",i(i.s=53)}([function(t,e,i){"use strict";
/**
* @license
* Copyright 2016 Google Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/e.a=class{static get cssClasses(){return{}}static get strings(){return{}}static get numbers(){return{}}static get defaultAdapter(){return{}}constructor(t={}){this.adapter_=t}init(){}destroy(){}}},function(t,e,i){"use strict";var n=i(0);
/**
* @license
* Copyright 2016 Google Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/class s{static attachTo(t){return new s(t,new n.a)}constructor(t,e,...i){this.root_=t,this.initialize(...i),this.foundation_=void 0===e?this.getDefaultFoundation():e,this.foundation_.init(),this.initialSyncWithDOM()}initialize(){}getDefaultFoundation(){throw new Error("Subclasses must override getDefaultFoundation to return a properly configured foundation class")}initialSyncWithDOM(){}destroy(){this.foundation_.destroy()}listen(t,e){this.root_.addEventListener(t,e)}unlisten(t,e){this.root_.removeEventListener(t,e)}emit(t,e,i=!1){let n;"function"==typeof CustomEvent?n=new CustomEvent(t,{detail:e,bubbles:i}):(n=document.createEvent("CustomEvent")).initCustomEvent(t,i,!1,e),this.root_.dispatchEvent(n)}}e.a=s},function(t,e,i){"use strict";i.r(e);var n=i(1);
/**
* @license
* Copyright 2016 Google Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/var s=i(0);
/**
* @license
* Copyright 2016 Google Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
const a={ROOT:"mdc-ripple-upgraded",UNBOUNDED:"mdc-ripple-upgraded--unbounded",BG_FOCUSED:"mdc-ripple-upgraded--background-focused",FG_ACTIVATION:"mdc-ripple-upgraded--foreground-activation",FG_DEACTIVATION:"mdc-ripple-upgraded--foreground-deactivation"},r={VAR_LEFT:"--mdc-ripple-left",VAR_TOP:"--mdc-ripple-top",VAR_FG_SIZE:"--mdc-ripple-fg-size",VAR_FG_SCALE:"--mdc-ripple-fg-scale",VAR_FG_TRANSLATE_START:"--mdc-ripple-fg-translate-start",VAR_FG_TRANSLATE_END:"--mdc-ripple-fg-translate-end"},o={PADDING:10,INITIAL_ORIGIN_SCALE:.6,DEACTIVATION_TIMEOUT_MS:225,FG_DEACTIVATION_MS:150,TAP_DELAY_MS:300};var l=i(14);
/**
* @license
* Copyright 2016 Google Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/const d=["touchstart","pointerdown","mousedown","keydown"],c=["touchend","pointerup","mouseup"];let u=[];class h extends s.a{static get cssClasses(){return a}static get strings(){return r}static get numbers(){return o}static get defaultAdapter(){return{browserSupportsCssVars:()=>{},isUnbounded:()=>{},isSurfaceActive:()=>{},isSurfaceDisabled:()=>{},addClass:()=>{},removeClass:()=>{},containsEventTarget:()=>{},registerInteractionHandler:()=>{},deregisterInteractionHandler:()=>{},registerDocumentInteractionHandler:()=>{},deregisterDocumentInteractionHandler:()=>{},registerResizeHandler:()=>{},deregisterResizeHandler:()=>{},updateCssVariable:()=>{},computeBoundingRect:()=>{},getWindowPageOffset:()=>{}}}constructor(t){super(Object.assign(h.defaultAdapter,t)),this.layoutFrame_=0,this.frame_={width:0,height:0},this.activationState_=this.defaultActivationState_(),this.initialSize_=0,this.maxRadius_=0,this.activateHandler_=t=>this.activate_(t),this.deactivateHandler_=t=>this.deactivate_(t),this.focusHandler_=()=>this.handleFocus(),this.blurHandler_=()=>this.handleBlur(),this.resizeHandler_=()=>this.layout(),this.unboundedCoords_={left:0,top:0},this.fgScale_=0,this.activationTimer_=0,this.fgDeactivationRemovalTimer_=0,this.activationAnimationHasEnded_=!1,this.activationTimerCallback_=()=>{this.activationAnimationHasEnded_=!0,this.runDeactivationUXLogicIfReady_()},this.previousActivationEvent_=null}supportsPressRipple_(){return this.adapter_.browserSupportsCssVars()}defaultActivationState_(){return{isActivated:!1,hasDeactivationUXRun:!1,wasActivatedByPointer:!1,wasElementMadeActive:!1,activationEvent:null,isProgrammatic:!1}}init(){const t=this.supportsPressRipple_();if(this.registerRootHandlers_(t),t){const{ROOT:t,UNBOUNDED:e}=h.cssClasses;requestAnimationFrame(()=>{this.adapter_.addClass(t),this.adapter_.isUnbounded()&&(this.adapter_.addClass(e),this.layoutInternal_())})}}destroy(){if(this.supportsPressRipple_()){this.activationTimer_&&(clearTimeout(this.activationTimer_),this.activationTimer_=0,this.adapter_.removeClass(h.cssClasses.FG_ACTIVATION)),this.fgDeactivationRemovalTimer_&&(clearTimeout(this.fgDeactivationRemovalTimer_),this.fgDeactivationRemovalTimer_=0,this.adapter_.removeClass(h.cssClasses.FG_DEACTIVATION));const{ROOT:t,UNBOUNDED:e}=h.cssClasses;requestAnimationFrame(()=>{this.adapter_.removeClass(t),this.adapter_.removeClass(e),this.removeCssVars_()})}this.deregisterRootHandlers_(),this.deregisterDeactivationHandlers_()}registerRootHandlers_(t){t&&(d.forEach(t=>{this.adapter_.registerInteractionHandler(t,this.activateHandler_)}),this.adapter_.isUnbounded()&&this.adapter_.registerResizeHandler(this.resizeHandler_)),this.adapter_.registerInteractionHandler("focus",this.focusHandler_),this.adapter_.registerInteractionHandler("blur",this.blurHandler_)}registerDeactivationHandlers_(t){"keydown"===t.type?this.adapter_.registerInteractionHandler("keyup",this.deactivateHandler_):c.forEach(t=>{this.adapter_.registerDocumentInteractionHandler(t,this.deactivateHandler_)})}deregisterRootHandlers_(){d.forEach(t=>{this.adapter_.deregisterInteractionHandler(t,this.activateHandler_)}),this.adapter_.deregisterInteractionHandler("focus",this.focusHandler_),this.adapter_.deregisterInteractionHandler("blur",this.blurHandler_),this.adapter_.isUnbounded()&&this.adapter_.deregisterResizeHandler(this.resizeHandler_)}deregisterDeactivationHandlers_(){this.adapter_.deregisterInteractionHandler("keyup",this.deactivateHandler_),c.forEach(t=>{this.adapter_.deregisterDocumentInteractionHandler(t,this.deactivateHandler_)})}removeCssVars_(){const{strings:t}=h;Object.keys(t).forEach(e=>{0===e.indexOf("VAR_")&&this.adapter_.updateCssVariable(t[e],null)})}activate_(t){if(this.adapter_.isSurfaceDisabled())return;const e=this.activationState_;if(e.isActivated)return;const i=this.previousActivationEvent_;i&&t&&i.type!==t.type||(e.isActivated=!0,e.isProgrammatic=null===t,e.activationEvent=t,e.wasActivatedByPointer=!e.isProgrammatic&&("mousedown"===t.type||"touchstart"===t.type||"pointerdown"===t.type),t&&u.length>0&&u.some(t=>this.adapter_.containsEventTarget(t))?this.resetActivationState_():(t&&(u.push(t.target),this.registerDeactivationHandlers_(t)),e.wasElementMadeActive=this.checkElementMadeActive_(t),e.wasElementMadeActive&&this.animateActivation_(),requestAnimationFrame(()=>{u=[],e.wasElementMadeActive||" "!==t.key&&32!==t.keyCode||(e.wasElementMadeActive=this.checkElementMadeActive_(t),e.wasElementMadeActive&&this.animateActivation_()),e.wasElementMadeActive||(this.activationState_=this.defaultActivationState_())})))}checkElementMadeActive_(t){return!t||"keydown"!==t.type||this.adapter_.isSurfaceActive()}activate(t=null){this.activate_(t)}animateActivation_(){const{VAR_FG_TRANSLATE_START:t,VAR_FG_TRANSLATE_END:e}=h.strings,{FG_DEACTIVATION:i,FG_ACTIVATION:n}=h.cssClasses,{DEACTIVATION_TIMEOUT_MS:s}=h.numbers;this.layoutInternal_();let a="",r="";if(!this.adapter_.isUnbounded()){const{startPoint:t,endPoint:e}=this.getFgTranslationCoordinates_();a=`${t.x}px, ${t.y}px`,r=`${e.x}px, ${e.y}px`}this.adapter_.updateCssVariable(t,a),this.adapter_.updateCssVariable(e,r),clearTimeout(this.activationTimer_),clearTimeout(this.fgDeactivationRemovalTimer_),this.rmBoundedActivationClasses_(),this.adapter_.removeClass(i),this.adapter_.computeBoundingRect(),this.adapter_.addClass(n),this.activationTimer_=setTimeout(()=>this.activationTimerCallback_(),s)}getFgTranslationCoordinates_(){const{activationEvent:t,wasActivatedByPointer:e}=this.activationState_;let i;return{startPoint:i={x:(i=e?Object(l.getNormalizedEventCoords)(t,this.adapter_.getWindowPageOffset(),this.adapter_.computeBoundingRect()):{x:this.frame_.width/2,y:this.frame_.height/2}).x-this.initialSize_/2,y:i.y-this.initialSize_/2},endPoint:{x:this.frame_.width/2-this.initialSize_/2,y:this.frame_.height/2-this.initialSize_/2}}}runDeactivationUXLogicIfReady_(){const{FG_DEACTIVATION:t}=h.cssClasses,{hasDeactivationUXRun:e,isActivated:i}=this.activationState_;(e||!i)&&this.activationAnimationHasEnded_&&(this.rmBoundedActivationClasses_(),this.adapter_.addClass(t),this.fgDeactivationRemovalTimer_=setTimeout(()=>{this.adapter_.removeClass(t)},o.FG_DEACTIVATION_MS))}rmBoundedActivationClasses_(){const{FG_ACTIVATION:t}=h.cssClasses;this.adapter_.removeClass(t),this.activationAnimationHasEnded_=!1,this.adapter_.computeBoundingRect()}resetActivationState_(){this.previousActivationEvent_=this.activationState_.activationEvent,this.activationState_=this.defaultActivationState_(),setTimeout(()=>this.previousActivationEvent_=null,h.numbers.TAP_DELAY_MS)}deactivate_(t){const e=this.activationState_;if(!e.isActivated)return;const i=Object.assign({},e);if(e.isProgrammatic){const t=null;requestAnimationFrame(()=>this.animateDeactivation_(t,i)),this.resetActivationState_()}else this.deregisterDeactivationHandlers_(),requestAnimationFrame(()=>{this.activationState_.hasDeactivationUXRun=!0,this.animateDeactivation_(t,i),this.resetActivationState_()})}deactivate(t=null){this.deactivate_(t)}animateDeactivation_(t,{wasActivatedByPointer:e,wasElementMadeActive:i}){(e||i)&&this.runDeactivationUXLogicIfReady_()}layout(){this.layoutFrame_&&cancelAnimationFrame(this.layoutFrame_),this.layoutFrame_=requestAnimationFrame(()=>{this.layoutInternal_(),this.layoutFrame_=0})}layoutInternal_(){this.frame_=this.adapter_.computeBoundingRect();const t=Math.max(this.frame_.height,this.frame_.width);this.maxRadius_=this.adapter_.isUnbounded()?t:(()=>{return Math.sqrt(Math.pow(this.frame_.width,2)+Math.pow(this.frame_.height,2))+h.numbers.PADDING})(),this.initialSize_=t*h.numbers.INITIAL_ORIGIN_SCALE,this.fgScale_=this.maxRadius_/this.initialSize_,this.updateLayoutCssVars_()}updateLayoutCssVars_(){const{VAR_FG_SIZE:t,VAR_LEFT:e,VAR_TOP:i,VAR_FG_SCALE:n}=h.strings;this.adapter_.updateCssVariable(t,`${this.initialSize_}px`),this.adapter_.updateCssVariable(n,this.fgScale_),this.adapter_.isUnbounded()&&(this.unboundedCoords_={left:Math.round(this.frame_.width/2-this.initialSize_/2),top:Math.round(this.frame_.height/2-this.initialSize_/2)},this.adapter_.updateCssVariable(e,`${this.unboundedCoords_.left}px`),this.adapter_.updateCssVariable(i,`${this.unboundedCoords_.top}px`))}setUnbounded(t){const{UNBOUNDED:e}=h.cssClasses;t?this.adapter_.addClass(e):this.adapter_.removeClass(e)}handleFocus(){requestAnimationFrame(()=>this.adapter_.addClass(h.cssClasses.BG_FOCUSED))}handleBlur(){requestAnimationFrame(()=>this.adapter_.removeClass(h.cssClasses.BG_FOCUSED))}}var p=h;i.d(e,"MDCRipple",(function(){return _})),i.d(e,"RippleCapableSurface",(function(){return f})),i.d(e,"MDCRippleFoundation",(function(){return p})),i.d(e,"util",(function(){return l}));
/**
* @license
* Copyright 2016 Google Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
class _ extends n.a{constructor(...t){super(...t),this.disabled=!1,this.unbounded_}static attachTo(t,{isUnbounded:e}={}){const i=new _(t);return void 0!==e&&(i.unbounded=e),i}static createAdapter(t){const e=l.getMatchesProperty(HTMLElement.prototype);return{browserSupportsCssVars:()=>l.supportsCssVariables(window),isUnbounded:()=>t.unbounded,isSurfaceActive:()=>t.root_[e](":active"),isSurfaceDisabled:()=>t.disabled,addClass:e=>t.root_.classList.add(e),removeClass:e=>t.root_.classList.remove(e),containsEventTarget:e=>t.root_.contains(e),registerInteractionHandler:(e,i)=>t.root_.addEventListener(e,i,l.applyPassive()),deregisterInteractionHandler:(e,i)=>t.root_.removeEventListener(e,i,l.applyPassive()),registerDocumentInteractionHandler:(t,e)=>document.documentElement.addEventListener(t,e,l.applyPassive()),deregisterDocumentInteractionHandler:(t,e)=>document.documentElement.removeEventListener(t,e,l.applyPassive()),registerResizeHandler:t=>window.addEventListener("resize",t),deregisterResizeHandler:t=>window.removeEventListener("resize",t),updateCssVariable:(e,i)=>t.root_.style.setProperty(e,i),computeBoundingRect:()=>t.root_.getBoundingClientRect(),getWindowPageOffset:()=>({x:window.pageXOffset,y:window.pageYOffset})}}get unbounded(){return this.unbounded_}set unbounded(t){this.unbounded_=Boolean(t),this.setUnbounded_()}setUnbounded_(){this.foundation_.setUnbounded(this.unbounded_)}activate(){this.foundation_.activate()}deactivate(){this.foundation_.deactivate()}layout(){this.foundation_.layout()}getDefaultFoundation(){return new p(_.createAdapter(this))}initialSyncWithDOM(){this.unbounded="mdcRippleIsUnbounded"in this.root_.dataset}}class f{}f.prototype.root_,f.prototype.unbounded,f.prototype.disabled},function(t,e){function i(e){return t.exports=i=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},i(e)}t.exports=i},function(t,e){t.exports=function(t){return t&&t.__esModule?t:{default:t}}},function(t,e){function i(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}t.exports=function(t,e,n){return e&&i(t.prototype,e),n&&i(t,n),t}},function(t,e){t.exports=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}},function(t,e,i){var n=i(17),s=i(54);t.exports=function(t,e){return!e||"object"!==n(e)&&"function"!=typeof e?s(t):e}},function(t,e,i){var n=i(55);t.exports=function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&n(t,e)}},function(e,i){e.exports=t},function(t,e,i){"use strict";var n=i(4);Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.MaterialComponent=void 0;var s=n(i(6)),a=n(i(5)),r=n(i(7)),o=n(i(3)),l=n(i(8)),d=n(i(17)),c=i(2),u=i(18),h=i(9),p=function(t,e,i,n){var s,a=arguments.length,r=a<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"===("undefined"==typeof Reflect?"undefined":(0,d.default)(Reflect))&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,n);else for(var o=t.length-1;o>=0;o--)(s=t[o])&&(r=(a<3?s(r):a>3?s(e,i,r):s(e,i))||r);return a>3&&r&&Object.defineProperty(e,i,r),r},_=["disabled"],f=function(t){function e(){return(0,s.default)(this,e),(0,r.default)(this,(0,o.default)(e).apply(this,arguments))}return(0,l.default)(e,t),(0,a.default)(e,[{key:"render",value:function(t){this.classText||(this.classText=this.buildClassName(t));var e=t,i=e.className||e.class||"";e.class&&delete e.class,e.className&&delete e.className;var n=this.materialDom(e),s="attributes";return"props"in n?(s="props",n.props=n.props||{}):n.attributes=n.attributes||{},n[s].className="".concat(i," ").concat(this.getClassName(n)).split(" ").filter((function(t,e,i){return i.indexOf(t)===e&&""!==t})).join(" "),this.mdcProps.forEach((function(t){t in _||delete n[s][t]})),n}},{key:"componentDidMount",value:function(){this.props.ripple&&this.control&&(this.ripple=new c.MDCRipple(this.control))}},{key:"componentWillReceiveProps",value:function(t){if(this.MDComponent&&this.mdcNotifyProps){var e=!0,i=!1,n=void 0;try{for(var s,a=this.mdcNotifyProps[Symbol.iterator]();!(e=(s=a.next()).done);e=!0){var r=s.value;this.props[r]!==t[r]&&(this.MDComponent[r]=t[r])}}catch(t){i=!0,n=t}finally{try{e||null==a.return||a.return()}finally{if(i)throw n}}}var o=!0,l=!1,d=void 0;try{for(var c,u=this.mdcProps[Symbol.iterator]();!(o=(c=u.next()).done);o=!0){var h=c.value;if(this.props[h]!==t[h]){this.classText=this.buildClassName(t);break}}}catch(t){l=!0,d=t}finally{try{o||null==u.return||u.return()}finally{if(l)throw d}}}},{key:"componentWillUnmount",value:function(){this.ripple&&this.ripple.destroy()}},{key:"afterComponentDidMount",value:function(){if(this.MDComponent&&this.mdcNotifyProps){var t=!0,e=!1,i=void 0;try{for(var n,s=this.mdcNotifyProps[Symbol.iterator]();!(t=(n=s.next()).done);t=!0){var a=n.value;this.MDComponent[a]=this.props[a]}}catch(t){e=!0,i=t}finally{try{t||null==s.return||s.return()}finally{if(e)throw i}}}}},{key:"setControlRef",value:function(t){this.control=t}},{key:"buildClassName",value:function(t){var e="mdc-"+this.componentName;for(var i in t)if(t.hasOwnProperty(i)){var n=t[i];"boolean"==typeof n&&n&&-1!==this.mdcProps.indexOf(i)&&(e+=" mdc-".concat(this.componentName,"--").concat(i))}return e}},{key:"getClassName",value:function(t){if(!t)return"";var e="attributes";"props"in t?(e="props",t.props=t.props||{}):t.attributes=t.attributes||{};var i=t[e]=t[e]||{},n=this.classText;return i.class&&(n+=" "+i.class),i.className&&i.className!==i.class&&(n+=" "+i.className),n}}]),e}(h.Component);e.MaterialComponent=f,p([u.bind],f.prototype,"setControlRef",null);var m=f;e.default=m},function(t,e,i){"use strict";var n=i(0);i.d(e,"b",(function(){return n.a}));var s=i(1);i.d(e,"a",(function(){return s.a}))},function(t,e,i){"use strict";i.d(e,"b",(function(){return s})),i.d(e,"a",(function(){return n}));
/**
* @license
* Copyright 2018 Google Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
const n={ROOT:"mdc-list",LIST_ITEM_CLASS:"mdc-list-item",LIST_ITEM_SELECTED_CLASS:"mdc-list-item--selected",LIST_ITEM_ACTIVATED_CLASS:"mdc-list-item--activated"},s={ARIA_ORIENTATION:"aria-orientation",ARIA_ORIENTATION_HORIZONTAL:"horizontal",ARIA_SELECTED:"aria-selected",FOCUSABLE_CHILD_ELEMENTS:`.${n.LIST_ITEM_CLASS} button:not(:disabled), .${n.LIST_ITEM_CLASS} a`,ENABLED_ITEMS_SELECTOR:".mdc-list-item:not(.mdc-list-item--disabled)"}},function(t,e,i){var n=i(56);function s(e,i,a){return"undefined"!=typeof Reflect&&Reflect.get?t.exports=s=Reflect.get:t.exports=s=function(t,e,i){var s=n(t,e);if(s){var a=Object.getOwnPropertyDescriptor(s,e);return a.get?a.get.call(i):a.value}},s(e,i,a||e)}t.exports=s},function(t,e,i){"use strict";
/**
* @license
* Copyright 2016 Google Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
let n,s;function a(t,e=!1){let i=n;if("boolean"==typeof n&&!e)return i;if(!(t.CSS&&"function"==typeof t.CSS.supports))return;const s=t.CSS.supports("--css-vars","yes"),a=t.CSS.supports("(--css-vars: yes)")&&t.CSS.supports("color","#00000000");return i=!(!s&&!a)&&!function(t){const e=t.document,i=e.createElement("div");i.className="mdc-ripple-surface--test-edge-var-bug",e.body.appendChild(i);const n=t.getComputedStyle(i),s=null!==n&&"solid"===n.borderTopStyle;return i.remove(),s}(t),e||(n=i),i}function r(t=window,e=!1){if(void 0===s||e){let e=!1;try{t.document.addEventListener("test",null,{get passive(){e=!0}})}catch(t){}s=e}return!!s&&{passive:!0}}function o(t){return["webkitMatchesSelector","msMatchesSelector","matches"].filter(e=>e in t).pop()}function l(t,e,i){const{x:n,y:s}=e,a=n+i.left,r=s+i.top;let o,l;return"touchstart"===t.type?(o=t.changedTouches[0].pageX-a,l=t.changedTouches[0].pageY-r):(o=t.pageX-a,l=t.pageY-r),{x:o,y:l}}i.r(e),i.d(e,"supportsCssVariables",(function(){return a})),i.d(e,"applyPassive",(function(){return r})),i.d(e,"getMatchesProperty",(function(){return o})),i.d(e,"getNormalizedEventCoords",(function(){return l}))},function(t,e,i){"use strict";i.d(e,"c",(function(){return r})),i.d(e,"a",(function(){return o})),i.d(e,"b",(function(){return l}));const n={animationstart:{noPrefix:"animationstart",webkitPrefix:"webkitAnimationStart",styleProperty:"animation"},animationend:{noPrefix:"animationend",webkitPrefix:"webkitAnimationEnd",styleProperty:"animation"},animationiteration:{noPrefix:"animationiteration",webkitPrefix:"webkitAnimationIteration",styleProperty:"animation"},transitionend:{noPrefix:"transitionend",webkitPrefix:"webkitTransitionEnd",styleProperty:"transition"}},s={animation:{noPrefix:"animation",webkitPrefix:"-webkit-animation"},transform:{noPrefix:"transform",webkitPrefix:"-webkit-transform"},transition:{noPrefix:"transition",webkitPrefix:"-webkit-transition"}};function a(t,e){if(!function(t){return void 0!==t.document&&"function"==typeof t.document.createElement}(t)||!function(t){return t in n||t in s}(e))return e;const i=e in n?n:s,a=t.document.createElement("div");let r="";return r=i===n?function(t,e,i){return e[t].styleProperty in i.style?e[t].noPrefix:e[t].webkitPrefix}(e,i,a):i[e].noPrefix in a.style?i[e].noPrefix:i[e].webkitPrefix}const r=["transform","WebkitTransform","MozTransform","OTransform","MSTransform"];function o(t,e){return a(t,e)}function l(t,e){return a(t,e)}},function(t,e,i){"use strict";var n=i(0),s=(i(42),i(12));
/**
* @license
* Copyright 2018 Google Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
const a=["input","button","textarea","select"];class r extends n.a{static get strings(){return s.b}static get cssClasses(){return s.a}static get defaultAdapter(){return{getListItemCount:()=>{},getFocusedElementIndex:()=>{},setAttributeForElementIndex:()=>{},removeAttributeForElementIndex:()=>{},addClassForElementIndex:()=>{},removeClassForElementIndex:()=>{},focusItemAtIndex:()=>{},setTabIndexForListItemChildren:()=>{},followHref:()=>{}}}constructor(t){super(Object.assign(r.defaultAdapter,t)),this.wrapFocus_=!1,this.isVertical_=!0,this.isSingleSelectionList_=!1,this.selectedIndex_=-1,this.useActivatedClass_=!1}setWrapFocus(t){this.wrapFocus_=t}setVerticalOrientation(t){this.isVertical_=t}setSingleSelection(t){this.isSingleSelectionList_=t}setUseActivatedClass(t){this.useActivatedClass_=t}setSelectedIndex(t){if(t===this.selectedIndex_)return;const e=this.useActivatedClass_?s.a.LIST_ITEM_ACTIVATED_CLASS:s.a.LIST_ITEM_SELECTED_CLASS;this.selectedIndex_>=0&&(this.adapter_.removeAttributeForElementIndex(this.selectedIndex_,s.b.ARIA_SELECTED),this.adapter_.removeClassForElementIndex(this.selectedIndex_,e),this.adapter_.setAttributeForElementIndex(this.selectedIndex_,"tabindex",-1)),t>=0&&this.adapter_.getListItemCount()>t&&(this.selectedIndex_=t,this.adapter_.setAttributeForElementIndex(this.selectedIndex_,s.b.ARIA_SELECTED,!0),this.adapter_.addClassForElementIndex(this.selectedIndex_,e),this.adapter_.setAttributeForElementIndex(this.selectedIndex_,"tabindex",0),0!==this.selectedIndex_&&this.adapter_.setAttributeForElementIndex(0,"tabindex",-1))}handleFocusIn(t,e){e>=0&&this.adapter_.setTabIndexForListItemChildren(e,0)}handleFocusOut(t,e){e>=0&&this.adapter_.setTabIndexForListItemChildren(e,-1)}handleKeydown(t,e,i){const n="ArrowLeft"===t.key||37===t.keyCode,s="ArrowUp"===t.key||38===t.keyCode,a="ArrowRight"===t.key||39===t.keyCode,r="ArrowDown"===t.key||40===t.keyCode,o="Home"===t.key||36===t.keyCode,l="End"===t.key||35===t.keyCode,d="Enter"===t.key||13===t.keyCode,c="Space"===t.key||32===t.keyCode;let u=this.adapter_.getFocusedElementIndex();-1===u&&(u=i)<0||(this.isVertical_&&r||!this.isVertical_&&a?(this.preventDefaultEvent_(t),this.focusNextElement(u)):this.isVertical_&&s||!this.isVertical_&&n?(this.preventDefaultEvent_(t),this.focusPrevElement(u)):o?(this.preventDefaultEvent_(t),this.focusFirstElement()):l?(this.preventDefaultEvent_(t),this.focusLastElement()):this.isSingleSelectionList_&&(d||c)&&(this.preventDefaultEvent_(t),e&&(this.setSelectedIndex(u),this.adapter_.followHref(u))))}handleClick(){const t=this.adapter_.getFocusedElementIndex();-1!==t&&this.setSelectedIndex(t)}preventDefaultEvent_(t){const e=`${t.target.tagName}`.toLowerCase();-1===a.indexOf(e)&&t.preventDefault()}focusNextElement(t){let e=t+1;if(e>=this.adapter_.getListItemCount()){if(!this.wrapFocus_)return;e=0}this.adapter_.focusItemAtIndex(e)}focusPrevElement(t){let e=t-1;if(e<0){if(!this.wrapFocus_)return;e=this.adapter_.getListItemCount()-1}this.adapter_.focusItemAtIndex(e)}focusFirstElement(){this.adapter_.getListItemCount()>0&&this.adapter_.focusItemAtIndex(0)}focusLastElement(){const t=this.adapter_.getListItemCount()-1;t>=0&&this.adapter_.focusItemAtIndex(t)}}e.a=r},function(t,e){function i(t){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function n(e){return"function"==typeof Symbol&&"symbol"===i(Symbol.iterator)?t.exports=n=function(t){return i(t)}:t.exports=n=function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":i(t)},n(e)}t.exports=n},function(t,e,i){"use strict";var n;function s(t,e,i){if(!i||typeof i.value!==n.typeOfFunction)throw new TypeError("Only methods can be decorated with @bind. <"+e+"> is not a method!");return{configurable:n.boolTrue,get:function(){var t=i.value.bind(this);return Object.defineProperty(this,e,{value:t,configurable:n.boolTrue,writable:n.boolTrue}),t}}}Object.defineProperty(e,"__esModule",{value:!0}),function(t){t.typeOfFunction="function",t.boolTrue=!0}(n||(n={})),e.bind=s,e.default=s},function(t,e,i){"use strict";var n=i(4);Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.Icon=void 0;var s=n(i(6)),a=n(i(5)),r=n(i(7)),o=n(i(3)),l=n(i(8)),d=i(9),c=function(t){function e(){var t;return(0,s.default)(this,e),(t=(0,r.default)(this,(0,o.default)(e).apply(this,arguments))).componentName="icon",t.mdcProps=[],t}return(0,l.default)(e,t),(0,a.default)(e,[{key:"materialDom",value:function(t){var e=["material-icons"];return t.className&&e.push(t.className),(0,d.h)("i",Object.assign({},t,{className:e.join(" ")}),t.children)}}]),e}(n(i(10)).default);e.Icon=c;var u=c;e.default=u},function(t,e,i){"use strict";i(2);
/**
* @license
* Copyright 2017 Google Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/},function(t,e,i){"use strict";var n=i(4);Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.Button=e.ButtonIcon=void 0;var s=n(i(5)),a=n(i(6)),r=n(i(7)),o=n(i(3)),l=n(i(8)),d=i(9),c=n(i(10)),u=n(i(19)),h=n(i(28)),p=function(t){function e(){var t;return(0,a.default)(this,e),(t=(0,r.default)(this,(0,o.default)(e).apply(this,arguments))).componentName="button__icon",t}return(0,l.default)(e,t),e}(u.default);e.ButtonIcon=p;var _=function(t){function e(){var t;return(0,a.default)(this,e),(t=(0,r.default)(this,(0,o.default)(e).apply(this,arguments))).componentName="button",t.mdcProps=["dense","raised","unelevated","outlined"],t.themeProps=["primary","secondary"],t}return(0,l.default)(e,t),(0,s.default)(e,[{key:"materialDom",value:function(t){var e=t.href?"a":"button",i="";return this.themeProps.forEach((function(e){e in t&&!1!==t[e]&&(i+=(0,h.default)(e)+" ")})),(0,d.h)(e,Object.assign({ref:this.setControlRef},t,{className:i}),this.props.children)}}]),e}(c.default);e.Button=_;var f=function(t){function e(){return(0,a.default)(this,e),(0,r.default)(this,(0,o.default)(e).apply(this,arguments))}return(0,l.default)(e,t),e}(_);e.default=f,f.Icon=p},function(t,e,i){"use strict";var n=i(4);Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.List=e.ListGroupHeader=e.ListGroup=e.ListSecondaryText=e.ListPrimaryText=e.ListTextContainer=e.ListDivider=e.ListItemMetaText=e.ListItemMeta=e.ListItemGraphic=e.ListLinkItem=e.ListItem=void 0;var s=n(i(6)),a=n(i(5)),r=n(i(7)),o=n(i(3)),l=n(i(8)),d=i(9),c=n(i(10)),u=n(i(19)),h=function(t){function e(){var t;return(0,s.default)(this,e),(t=(0,r.default)(this,(0,o.default)(e).apply(this,arguments))).componentName="list-item",t.mdcProps=[],t}return(0,l.default)(e,t),(0,a.default)(e,[{key:"materialDom",value:function(t){return(0,d.h)("li",Object.assign({role:"option"},t,{ref:this.setControlRef}),t.children)}}]),e}(c.default);e.ListItem=h;var p=function(t){function e(){var t;return(0,s.default)(this,e),(t=(0,r.default)(this,(0,o.default)(e).apply(this,arguments))).componentName="list-item",t.mdcProps=[],t}return(0,l.default)(e,t),(0,a.default)(e,[{key:"materialDom",value:function(t){return(0,d.h)("a",Object.assign({role:"option"},t,{ref:this.setControlRef}),t.children)}}]),e}(c.default);e.ListLinkItem=p;var _=function(t){function e(){var t;return(0,s.default)(this,e),(t=(0,r.default)(this,(0,o.default)(e).apply(this,arguments))).componentName="list-item__graphic",t.mdcProps=[],t}return(0,l.default)(e,t),(0,a.default)(e,[{key:"materialDom",value:function(t){return(0,d.h)("span",Object.assign({},t,{ref:this.setControlRef,role:"presentation"}),(0,d.h)(u.default,{"aria-hidden":"true"},t.children))}}]),e}(c.default);e.ListItemGraphic=_;var f=function(t){function e(){var t;return(0,s.default)(this,e),(t=(0,r.default)(this,(0,o.default)(e).apply(this,arguments))).componentName="list-item__meta",t}return(0,l.default)(e,t),e}(_);e.ListItemMeta=f;var m=function(t){function e(){var t;return(0,s.default)(this,e),(t=(0,r.default)(this,(0,o.default)(e).apply(this,arguments))).componentName="list-item__meta",t.mdcProps=[],t}return(0,l.default)(e,t),(0,a.default)(e,[{key:"materialDom",value:function(t){return(0,d.h)("span",Object.assign({},t,{ref:this.setControlRef,role:"presentation"}),t.children)}}]),e}(c.default);e.ListItemMetaText=m;var v=function(t){function e(){var t;return(0,s.default)(this,e),(t=(0,r.default)(this,(0,o.default)(e).apply(this,arguments))).componentName="list-divider",t.mdcProps=["inset"],t}return(0,l.default)(e,t),(0,a.default)(e,[{key:"materialDom",value:function(t){return(0,d.h)("li",Object.assign({role:"separator"},t,{ref:this.setControlRef}))}}]),e}(c.default);e.ListDivider=v;var C=function(t){function e(){var t;return(0,s.default)(this,e),(t=(0,r.default)(this,(0,o.default)(e).apply(this,arguments))).componentName="list-item__text",t.mdcProps=[],t}return(0,l.default)(e,t),(0,a.default)(e,[{key:"materialDom",value:function(t){return(0,d.h)("span",Object.assign({},t,{ref:this.setControlRef}),t.children)}}]),e}(c.default);e.ListTextContainer=C;var g=function(t){function e(){var t;return(0,s.default)(this,e),(t=(0,r.default)(this,(0,o.default)(e).apply(this,arguments))).componentName="list-item__primary-text",t}return(0,l.default)(e,t),e}(C);e.ListPrimaryText=g;var E=function(t){function e(){var t;return(0,s.default)(this,e),(t=(0,r.default)(this,(0,o.default)(e).apply(this,arguments))).componentName="list-item__secondary-text",t}return(0,l.default)(e,t),e}(C);e.ListSecondaryText=E;var y=function(t){function e(){var t;return(0,s.default)(this,e),(t=(0,r.default)(this,(0,o.default)(e).apply(this,arguments))).componentName="list-group",t.mdcProps=[],t}return(0,l.default)(e,t),(0,a.default)(e,[{key:"materialDom",value:function(t){return(0,d.h)("div",Object.assign({},t),this.props.children)}}]),e}(c.default);e.ListGroup=y;var T=function(t){function e(){var t;return(0,s.default)(this,e),(t=(0,r.default)(this,(0,o.default)(e).apply(this,arguments))).componentName="list-group__subheader",t.mdcProps=[],t}return(0,l.default)(e,t),(0,a.default)(e,[{key:"materialDom",value:function(t){return(0,d.h)("h3",Object.assign({},t,{ref:this.setControlRef}),t.children)}}]),e}(c.default);e.ListGroupHeader=T;var b=function(t){function e(){var t;return(0,s.default)(this,e),(t=(0,r.default)(this,(0,o.default)(e).apply(this,arguments))).componentName="list",t.mdcProps=["dense","two-line","avatar-list"],t}return(0,l.default)(e,t),(0,a.default)(e,[{key:"materialDom",value:function(t){return t.interactive?(0,d.h)("nav",Object.assign({ref:this.setControlRef},t),t.children):(0,d.h)("ul",Object.assign({},t,{ref:this.setControlRef}),t.children)}}]),e}(c.default);e.List=b;var I=function(t){function e(){return(0,s.default)(this,e),(0,r.default)(this,(0,o.default)(e).apply(this,arguments))}return(0,l.default)(e,t),e}(b);e.default=I,I.Item=h,I.LinkItem=p,I.ItemGraphic=_,I.ItemMeta=f,I.ItemMetaText=m,I.Divider=v,I.TextContainer=C,I.PrimaryText=g,I.SecondaryText=E,I.Group=y,I.GroupHeader=T},function(t,e,i){"use strict";i.d(e,"a",(function(){return r}));var n=i(1),s=i(16),a=(i(42),i(12));
/**
* @license
* Copyright 2018 Google Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
class r extends n.a{constructor(...t){super(...t),this.handleKeydown_,this.handleClick_,this.focusInEventListener_,this.focusOutEventListener_}static attachTo(t){return new r(t)}destroy(){this.root_.removeEventListener("keydown",this.handleKeydown_),this.root_.removeEventListener("click",this.handleClick_),this.root_.removeEventListener("focusin",this.focusInEventListener_),this.root_.removeEventListener("focusout",this.focusOutEventListener_)}initialSyncWithDOM(){this.handleClick_=this.foundation_.handleClick.bind(this.foundation_),this.handleKeydown_=this.handleKeydownEvent_.bind(this),this.focusInEventListener_=this.handleFocusInEvent_.bind(this),this.focusOutEventListener_=this.handleFocusOutEvent_.bind(this),this.root_.addEventListener("keydown",this.handleKeydown_),this.root_.addEventListener("focusin",this.focusInEventListener_),this.root_.addEventListener("focusout",this.focusOutEventListener_),this.layout(),this.initializeListType()}layout(){const t=this.root_.getAttribute(a.b.ARIA_ORIENTATION);this.vertical=t!==a.b.ARIA_ORIENTATION_HORIZONTAL,[].slice.call(this.root_.querySelectorAll(".mdc-list-item:not([tabindex])")).forEach(t=>{t.setAttribute("tabindex",-1)}),[].slice.call(this.root_.querySelectorAll(a.b.FOCUSABLE_CHILD_ELEMENTS)).forEach(t=>t.setAttribute("tabindex",-1))}getListItemIndex_(t){let e=t.target,i=-1;for(;!e.classList.contains(a.a.LIST_ITEM_CLASS)&&!e.classList.contains(a.a.ROOT);)e=e.parentElement;return e.classList.contains(a.a.LIST_ITEM_CLASS)&&(i=this.listElements.indexOf(e)),i}handleFocusInEvent_(t){const e=this.getListItemIndex_(t);this.foundation_.handleFocusIn(t,e)}handleFocusOutEvent_(t){const e=this.getListItemIndex_(t);this.foundation_.handleFocusOut(t,e)}handleKeydownEvent_(t){const e=this.getListItemIndex_(t);e>=0&&this.foundation_.handleKeydown(t,t.target.classList.contains(a.a.LIST_ITEM_CLASS),e)}initializeListType(){const t=this.root_.querySelector(`.${a.a.LIST_ITEM_ACTIVATED_CLASS}, .${a.a.LIST_ITEM_SELECTED_CLASS}`);t&&(t.classList.contains(a.a.LIST_ITEM_ACTIVATED_CLASS)&&this.foundation_.setUseActivatedClass(!0),this.singleSelection=!0,this.selectedIndex=this.listElements.indexOf(t))}set vertical(t){this.foundation_.setVerticalOrientation(t)}get listElements(){return[].slice.call(this.root_.querySelectorAll(a.b.ENABLED_ITEMS_SELECTOR))}set wrapFocus(t){this.foundation_.setWrapFocus(t)}set singleSelection(t){t?this.root_.addEventListener("click",this.handleClick_):this.root_.removeEventListener("click",this.handleClick_),this.foundation_.setSingleSelection(t)}set selectedIndex(t){this.foundation_.setSelectedIndex(t)}getDefaultFoundation(){return new s.a(Object.assign({getListItemCount:()=>this.listElements.length,getFocusedElementIndex:()=>this.listElements.indexOf(document.activeElement),setAttributeForElementIndex:(t,e,i)=>{const n=this.listElements[t];n&&n.setAttribute(e,i)},removeAttributeForElementIndex:(t,e)=>{const i=this.listElements[t];i&&i.removeAttribute(e)},addClassForElementIndex:(t,e)=>{const i=this.listElements[t];i&&i.classList.add(e)},removeClassForElementIndex:(t,e)=>{const i=this.listElements[t];i&&i.classList.remove(e)},focusItemAtIndex:t=>{const e=this.listElements[t];e&&e.focus()},setTabIndexForListItemChildren:(t,e)=>{const i=this.listElements[t];[].slice.call(i.querySelectorAll(a.b.FOCUSABLE_CHILD_ELEMENTS)).forEach(t=>t.setAttribute("tabindex",e))},followHref:t=>{const e=this.listElements[t];e&&e.href&&e.click()}}))}}},function(t,e,i){var n=i(58),s=i(59),a=null;function r(t){return setTimeout(t,0)}t.exports=function(t,e){var i=document,o="string"==typeof t?i.querySelector(t):t,l=s({returnFocusOnDeactivate:!0,escapeDeactivates:!0},e),d={firstTabbableNode:null,lastTabbableNode:null,nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1},c={activate:function(t){if(d.active)return;E(),d.active=!0,d.paused=!1,d.nodeFocusedBeforeActivation=i.activeElement;var e=t&&t.onActivate?t.onActivate:l.onActivate;e&&e();return h(),c},deactivate:u,pause:function(){if(d.paused||!d.active)return;d.paused=!0,p()},unpause:function(){if(!d.paused||!d.active)return;d.paused=!1,h()}};return c;function u(t){if(d.active){p(),d.active=!1,d.paused=!1;var e=t&&void 0!==t.onDeactivate?t.onDeactivate:l.onDeactivate;return e&&e(),(t&&void 0!==t.returnFocus?t.returnFocus:l.returnFocusOnDeactivate)&&r((function(){y(d.nodeFocusedBeforeActivation)})),c}}function h(){if(d.active)return a&&a.pause(),a=c,E(),r((function(){y(f())})),i.addEventListener("focusin",v,!0),i.addEventListener("mousedown",m,!0),i.addEventListener("touchstart",m,!0),i.addEventListener("click",g,!0),i.addEventListener("keydown",C,!0),c}function p(){if(d.active&&a===c)return i.removeEventListener("focusin",v,!0),i.removeEventListener("mousedown",m,!0),i.removeEventListener("touchstart",m,!0),i.removeEventListener("click",g,!0),i.removeEventListener("keydown",C,!0),a=null,c}function _(t){var e=l[t],n=e;if(!e)return null;if("string"==typeof e&&!(n=i.querySelector(e)))throw new Error("`"+t+"` refers to no known node");if("function"==typeof e&&!(n=e()))throw new Error("`"+t+"` did not return a node");return n}function f(){var t;if(!(t=null!==_("initialFocus")?_("initialFocus"):o.contains(i.activeElement)?i.activeElement:d.firstTabbableNode||_("fallbackFocus")))throw new Error("You can't have a focus-trap without at least one focusable element");return t}function m(t){o.contains(t.target)||(l.clickOutsideDeactivates?u({returnFocus:!n.isFocusable(t.target)}):t.preventDefault())}function v(t){o.contains(t.target)||t.target instanceof Document||(t.stopImmediatePropagation(),y(d.mostRecentlyFocusedNode||f()))}function C(t){if(!1!==l.escapeDeactivates&&function(t){return"Escape"===t.key||"Esc"===t.key||27===t.keyCode}(t))return t.preventDefault(),void u();(function(t