New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

x-postpress

Package Overview
Dependencies
Maintainers
1
Versions
37
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

x-postpress - npm Package Compare versions

Comparing version 2.1.10 to 2.1.11

manifest.json.2fc30186-04de-4fca-a871-a2c008b4c8c7

2

build/es5-bundled/service-worker.js

@@ -40,3 +40,3 @@ /**

var precacheConfig = [["index.html","62d21471c5503d96ce69e129dc95532f"],["manifest.json","57aad2eed3448bc42df48d196f2bea2a"],["src/components/x-postpress.js","c1127eeabd35d2c88b0c276534221e75"]];
var precacheConfig = [["index.html","62d21471c5503d96ce69e129dc95532f"],["manifest.json","57aad2eed3448bc42df48d196f2bea2a"],["src/components/x-postpress.js","0cd892cc8d488e76473ea6ab1dc41836"]];
var cacheName = 'sw-precache-v3--' + (self.registration ? self.registration.scope : '');

@@ -43,0 +43,0 @@

@@ -1,1 +0,1 @@

define(["exports"],function(_exports){"use strict";Object.defineProperty(_exports,"__esModule",{value:!0});_exports.property$1=_exports.property=property;_exports.removeNodesFromTemplate=removeNodesFromTemplate;_exports.insertNodeIntoTemplate=insertNodeIntoTemplate;_exports.templateFactory$1=_exports.templateFactory=templateFactory;_exports.templateCaches$1=_exports.templateCaches=_exports.render$1=_exports.render$2=_exports.render=_exports.parts$1=_exports.parts=_exports.EventPart$1=_exports.EventPart=_exports.PropertyPart$1=_exports.PropertyPart=_exports.PropertyCommitter$1=_exports.PropertyCommitter=_exports.BooleanAttributePart$1=_exports.BooleanAttributePart=_exports.NodePart$1=_exports.NodePart=_exports.AttributePart$1=_exports.AttributePart=_exports.AttributeCommitter$1=_exports.AttributeCommitter=_exports.isPrimitive$1=_exports.isPrimitive=_exports.nothing$1=_exports.nothing=_exports.noChange$1=_exports.noChange=_exports.removeNodes$1=_exports.removeNodes=_exports.reparentNodes$1=_exports.reparentNodes=_exports.isCEPolyfill=_exports.isDirective$1=_exports.isDirective=_exports.directive$1=_exports.directive=_exports.defaultTemplateProcessor$1=_exports.defaultTemplateProcessor=_exports.DefaultTemplateProcessor$1=_exports.DefaultTemplateProcessor=_exports.unsafeHTML=_exports.LitElement=_exports.SVGTemplateResult$2=_exports.SVGTemplateResult$1=_exports.SVGTemplateResult=_exports.TemplateResult$3=_exports.TemplateResult$2=_exports.TemplateResult$1=_exports.TemplateResult=_exports.svg$2=_exports.svg$1=_exports.svg=_exports.html$2=_exports.html$1=_exports.html=_exports.UpdatingElement$1=_exports.UpdatingElement=_exports.notEqual$1=_exports.notEqual=_exports.defaultConverter$1=_exports.defaultConverter=_exports.eventOptions$1=_exports.eventOptions=_exports.queryAll$1=_exports.queryAll=_exports.query$1=_exports.query=_exports.customElement$1=_exports.customElement=_exports.css$1=_exports.css=_exports.unsafeCSS$1=_exports.unsafeCSS=_exports.CSSResult$1=_exports.CSSResult=_exports.supportsAdoptingStyleSheets$1=_exports.supportsAdoptingStyleSheets=_exports.$misc=_exports.$xPostpress$1=_exports.$articles=_exports.$article=_exports.$xPostpress=_exports.$litHtml=_exports.$template=_exports.$templateResult=_exports.$templateInstance=_exports.$templateFactory=_exports.$shadyRender=_exports.$render=_exports.$parts=_exports.$part=_exports.$modifyTemplate=_exports.$dom=_exports.$directive=_exports.$defaultTemplateProcessor=_exports.$unsafeHtml=_exports.$litElement=_exports.$updatingElement=_exports.$decorators=_exports.$cssTag=void 0;_exports.getPostsUrl=_exports.getPosts=_exports.removeSubdomain=_exports.formatDate=_exports.buildQueryString=_exports.$xPostpressDefault$1=_exports.$articlesDefault=_exports.loading=_exports.getErrorMessageArticle=_exports.$articleDefault=_exports.$xPostpressDefault=_exports.lastAttributeNameRegex=_exports.createMarker$1=_exports.createMarker=_exports.isTemplatePartActive$1=_exports.isTemplatePartActive=_exports.Template$1=_exports.Template=_exports.boundAttributeSuffix=_exports.markerRegex=_exports.nodeMarker=_exports.marker=_exports.TemplateInstance$1=_exports.TemplateInstance=void 0;function _templateObject3_1c8d9ae03fba11e999fab3e0d1307b7a(){var data=babelHelpers.taggedTemplateLiteral(["\n <slot name=\"articles\"></slot>\n ","\n "]);_templateObject3_1c8d9ae03fba11e999fab3e0d1307b7a=function _templateObject3_1c8d9ae03fba11e999fab3e0d1307b7a(){return data};return data}function _templateObject2_1c8d9ae03fba11e999fab3e0d1307b7a(){var data=babelHelpers.taggedTemplateLiteral(["\n a,\n a:link,\n a:visited {\n color: var(--a-color, #000);\n text-decoration: var(--a-text-decoration, none);\n }\n\n a:hover {\n text-decoration: var(--a-hover-text-decoration, underline);\n }\n\n article {\n clear: var(--article-clear, inherit);\n margin-bottom: var(--article-margin-bottom, 1rem);\n margin-left: var(--article-margin-left, auto);\n margin-right: var(--article-margin-right, auto);\n margin-top: var(--article-margin-top, 0);\n width: var(--article-width, 80%);\n }\n\n h1 {\n font-size: var(--h1-font-size, inherit);\n }\n\n h2 {\n color: var(--h2-color, #333);\n font-size: var(--h2-font-size, smaller);\n }\n\n hr {\n clear: var(--hr-clear, both);\n display: var(--hr-display, block);\n }\n\n img {\n display: var(--img-display, inherit);\n float: var(--img-float, inherit);\n height: var(--img-height, auto);\n max-height: var(--img-max-height, inherit);\n max-width: var(--img-max-width, 100%);\n padding-bottom: var(--img-padding-bottom, inherit);\n padding-left: var(--img-padding-left, inherit);\n padding-right: var(--img-padding-right, inherit);\n padding-top: var(--img-padding-top, inherit);\n width: var(--img-width, auto);\n }\n\n ul {\n list-style-type: var(--ul-list-style-type, inherit);\n }\n\n p {\n clear: var(--p-clear, inherit);\n text-align: var(--p-text-align, inherit);\n }\n\n pre {\n overflow: auto;\n }\n"]);_templateObject2_1c8d9ae03fba11e999fab3e0d1307b7a=function _templateObject2_1c8d9ae03fba11e999fab3e0d1307b7a(){return data};return data}function _templateObject_1c8d9ae03fba11e999fab3e0d1307b7a(){var data=babelHelpers.taggedTemplateLiteral(["\n <article>\n <h1>","</h1>\n <h2>","</h2>\n <p>","</p>\n <hr />\n </article>\n"]);_templateObject_1c8d9ae03fba11e999fab3e0d1307b7a=function _templateObject_1c8d9ae03fba11e999fab3e0d1307b7a(){return data};return data}var supportsAdoptingStyleSheets="adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype;_exports.supportsAdoptingStyleSheets$1=_exports.supportsAdoptingStyleSheets=supportsAdoptingStyleSheets;var constructionToken=Symbol(),CSSResult=function(){function CSSResult(cssText,safeToken){babelHelpers.classCallCheck(this,CSSResult);if(safeToken!==constructionToken){throw new Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.")}this.cssText=cssText}babelHelpers.createClass(CSSResult,[{key:"toString",value:function toString(){return this.cssText}},{key:"styleSheet",get:function get(){if(this._styleSheet===void 0){if(supportsAdoptingStyleSheets){this._styleSheet=new CSSStyleSheet;this._styleSheet.replaceSync(this.cssText)}else{this._styleSheet=null}}return this._styleSheet}}]);return CSSResult}();_exports.CSSResult$1=_exports.CSSResult=CSSResult;var unsafeCSS=function unsafeCSS(value){return new CSSResult(value+"",constructionToken)};_exports.unsafeCSS$1=_exports.unsafeCSS=unsafeCSS;var textFromCSSResult=function textFromCSSResult(value){if(babelHelpers.instanceof(value,CSSResult)){return value.cssText}else{throw new Error("Value passed to 'css' function must be a 'css' function result: ".concat(value,". Use 'unsafeCSS' to pass non-literal values, but\n take care to ensure page security."))}},css=function css(strings){for(var _len=arguments.length,values=Array(1<_len?_len-1:0),_key=1;_key<_len;_key++){values[_key-1]=arguments[_key]}var cssText=values.reduce(function(acc,v,idx){return acc+textFromCSSResult(v)+strings[idx+1]},strings[0]);return new CSSResult(cssText,constructionToken)};_exports.css$1=_exports.css=css;var cssTag={supportsAdoptingStyleSheets:supportsAdoptingStyleSheets,CSSResult:CSSResult,unsafeCSS:unsafeCSS,css:css};_exports.$cssTag=cssTag;var legacyCustomElement=function legacyCustomElement(tagName,clazz){window.customElements.define(tagName,clazz);return clazz},standardCustomElement=function standardCustomElement(tagName,descriptor){var kind=descriptor.kind,elements=descriptor.elements;return{kind:kind,elements:elements,finisher:function finisher(clazz){window.customElements.define(tagName,clazz)}}},customElement=function customElement(tagName){return function(classOrDescriptor){return"function"===typeof classOrDescriptor?legacyCustomElement(tagName,classOrDescriptor):standardCustomElement(tagName,classOrDescriptor)}};_exports.customElement$1=_exports.customElement=customElement;var standardProperty=function standardProperty(options,element){if("method"===element.kind&&element.descriptor&&!("value"in element.descriptor)){return Object.assign({},element,{finisher:function finisher(clazz){clazz.createProperty(element.key,options)}})}else{return{kind:"field",key:Symbol(),placement:"own",descriptor:{},initializer:function initializer(){if("function"===typeof element.initializer){this[element.key]=element.initializer.call(this)}},finisher:function finisher(clazz){clazz.createProperty(element.key,options)}}}},legacyProperty=function legacyProperty(options,proto,name){proto.constructor.createProperty(name,options)};function property(options){return function(protoOrDescriptor,name){return name!==void 0?legacyProperty(options,protoOrDescriptor,name):standardProperty(options,protoOrDescriptor)}}var query=_query(function(target,selector){return target.querySelector(selector)});_exports.query$1=_exports.query=query;var queryAll=_query(function(target,selector){return target.querySelectorAll(selector)});_exports.queryAll$1=_exports.queryAll=queryAll;var legacyQuery=function legacyQuery(descriptor,proto,name){Object.defineProperty(proto,name,descriptor)},standardQuery=function standardQuery(descriptor,element){return{kind:"method",placement:"prototype",key:element.key,descriptor:descriptor}};function _query(queryFn){return function(selector){return function(protoOrDescriptor,name){var descriptor={get:function get(){return queryFn(this.renderRoot,selector)},enumerable:!0,configurable:!0};return name!==void 0?legacyQuery(descriptor,protoOrDescriptor,name):standardQuery(descriptor,protoOrDescriptor)}}}var standardEventOptions=function standardEventOptions(options,element){return Object.assign({},element,{finisher:function finisher(clazz){Object.assign(clazz.prototype[element.key],options)}})},legacyEventOptions=function legacyEventOptions(options,proto,name){Object.assign(proto[name],options)},eventOptions=function eventOptions(options){return function(protoOrDescriptor,name){return name!==void 0?legacyEventOptions(options,protoOrDescriptor,name):standardEventOptions(options,protoOrDescriptor)}};_exports.eventOptions$1=_exports.eventOptions=eventOptions;var decorators={customElement:customElement,property:property,query:query,queryAll:queryAll,eventOptions:eventOptions};_exports.$decorators=decorators;window.JSCompiler_renameProperty=function(prop,_obj){return prop};var defaultConverter={toAttribute:function toAttribute(value,type){switch(type){case Boolean:return value?"":null;case Object:case Array:return null==value?value:JSON.stringify(value);}return value},fromAttribute:function fromAttribute(value,type){switch(type){case Boolean:return null!==value;case Number:return null===value?null:+value;case Object:case Array:return JSON.parse(value);}return value}};_exports.defaultConverter$1=_exports.defaultConverter=defaultConverter;var notEqual=function notEqual(value,old){return old!==value&&(old===old||value===value)};_exports.notEqual$1=_exports.notEqual=notEqual;var defaultPropertyDeclaration={attribute:!0,type:String,converter:defaultConverter,reflect:!1,hasChanged:notEqual},microtaskPromise=Promise.resolve(!0),STATE_HAS_UPDATED=1,STATE_UPDATE_REQUESTED=1<<2,STATE_IS_REFLECTING_TO_ATTRIBUTE=1<<3,STATE_IS_REFLECTING_TO_PROPERTY=1<<4,STATE_HAS_CONNECTED=1<<5,UpdatingElement=function(_HTMLElement){babelHelpers.inherits(UpdatingElement,_HTMLElement);function UpdatingElement(){var _this;babelHelpers.classCallCheck(this,UpdatingElement);_this=babelHelpers.possibleConstructorReturn(this,babelHelpers.getPrototypeOf(UpdatingElement).call(this));_this._updateState=0;_this._instanceProperties=void 0;_this._updatePromise=microtaskPromise;_this._hasConnectedResolver=void 0;_this._changedProperties=new Map;_this._reflectingProperties=void 0;_this.initialize();return _this}babelHelpers.createClass(UpdatingElement,[{key:"initialize",value:function initialize(){this._saveInstanceProperties()}},{key:"_saveInstanceProperties",value:function _saveInstanceProperties(){var _this2=this;this.constructor._classProperties.forEach(function(_v,p){if(_this2.hasOwnProperty(p)){var value=_this2[p];delete _this2[p];if(!_this2._instanceProperties){_this2._instanceProperties=new Map}_this2._instanceProperties.set(p,value)}})}},{key:"_applyInstanceProperties",value:function _applyInstanceProperties(){var _this3=this;this._instanceProperties.forEach(function(v,p){return _this3[p]=v});this._instanceProperties=void 0}},{key:"connectedCallback",value:function connectedCallback(){this._updateState=this._updateState|STATE_HAS_CONNECTED;if(this._hasConnectedResolver){this._hasConnectedResolver();this._hasConnectedResolver=void 0}else{this.requestUpdate()}}},{key:"disconnectedCallback",value:function disconnectedCallback(){}},{key:"attributeChangedCallback",value:function attributeChangedCallback(name,old,value){if(old!==value){this._attributeToProperty(name,value)}}},{key:"_propertyToAttribute",value:function _propertyToAttribute(name,value){var options=2<arguments.length&&arguments[2]!==void 0?arguments[2]:defaultPropertyDeclaration,ctor=this.constructor,attr=ctor._attributeNameForProperty(name,options);if(attr!==void 0){var attrValue=ctor._propertyValueToAttribute(value,options);if(attrValue===void 0){return}this._updateState=this._updateState|STATE_IS_REFLECTING_TO_ATTRIBUTE;if(null==attrValue){this.removeAttribute(attr)}else{this.setAttribute(attr,attrValue)}this._updateState=this._updateState&~STATE_IS_REFLECTING_TO_ATTRIBUTE}}},{key:"_attributeToProperty",value:function _attributeToProperty(name,value){if(this._updateState&STATE_IS_REFLECTING_TO_ATTRIBUTE){return}var ctor=this.constructor,propName=ctor._attributeToPropertyMap.get(name);if(propName!==void 0){var options=ctor._classProperties.get(propName)||defaultPropertyDeclaration;this._updateState=this._updateState|STATE_IS_REFLECTING_TO_PROPERTY;this[propName]=ctor._propertyValueFromAttribute(value,options);this._updateState=this._updateState&~STATE_IS_REFLECTING_TO_PROPERTY}}},{key:"requestUpdate",value:function requestUpdate(name,oldValue){var shouldRequestUpdate=!0;if(name!==void 0&&!this._changedProperties.has(name)){var ctor=this.constructor,options=ctor._classProperties.get(name)||defaultPropertyDeclaration;if(ctor._valueHasChanged(this[name],oldValue,options.hasChanged)){this._changedProperties.set(name,oldValue);if(!0===options.reflect&&!(this._updateState&STATE_IS_REFLECTING_TO_PROPERTY)){if(this._reflectingProperties===void 0){this._reflectingProperties=new Map}this._reflectingProperties.set(name,options)}}else{shouldRequestUpdate=!1}}if(!this._hasRequestedUpdate&&shouldRequestUpdate){this._enqueueUpdate()}return this.updateComplete}},{key:"_enqueueUpdate",value:function(){var _enqueueUpdate2=babelHelpers.asyncToGenerator(regeneratorRuntime.mark(function _callee(){var _this4=this,resolve,previousUpdatePromise,result;return regeneratorRuntime.wrap(function _callee$(_context){while(1){switch(_context.prev=_context.next){case 0:this._updateState=this._updateState|STATE_UPDATE_REQUESTED;previousUpdatePromise=this._updatePromise;this._updatePromise=new Promise(function(res){return resolve=res});_context.next=5;return previousUpdatePromise;case 5:if(this._hasConnected){_context.next=8;break}_context.next=8;return new Promise(function(res){return _this4._hasConnectedResolver=res});case 8:result=this.performUpdate();if(!(null!=result&&"function"===typeof result.then)){_context.next=12;break}_context.next=12;return result;case 12:resolve(!this._hasRequestedUpdate);case 13:case"end":return _context.stop();}}},_callee,this)}));function _enqueueUpdate(){return _enqueueUpdate2.apply(this,arguments)}return _enqueueUpdate}()},{key:"performUpdate",value:function performUpdate(){if(this._instanceProperties){this._applyInstanceProperties()}if(this.shouldUpdate(this._changedProperties)){var changedProperties=this._changedProperties;this.update(changedProperties);this._markUpdated();if(!(this._updateState&STATE_HAS_UPDATED)){this._updateState=this._updateState|STATE_HAS_UPDATED;this.firstUpdated(changedProperties)}this.updated(changedProperties)}else{this._markUpdated()}}},{key:"_markUpdated",value:function _markUpdated(){this._changedProperties=new Map;this._updateState=this._updateState&~STATE_UPDATE_REQUESTED}},{key:"shouldUpdate",value:function shouldUpdate(_changedProperties){return!0}},{key:"update",value:function update(_changedProperties){var _this5=this;if(this._reflectingProperties!==void 0&&0<this._reflectingProperties.size){this._reflectingProperties.forEach(function(v,k){return _this5._propertyToAttribute(k,_this5[k],v)});this._reflectingProperties=void 0}}},{key:"updated",value:function updated(_changedProperties){}},{key:"firstUpdated",value:function firstUpdated(_changedProperties){}},{key:"_hasConnected",get:function get(){return this._updateState&STATE_HAS_CONNECTED}},{key:"_hasRequestedUpdate",get:function get(){return this._updateState&STATE_UPDATE_REQUESTED}},{key:"hasUpdated",get:function get(){return this._updateState&STATE_HAS_UPDATED}},{key:"updateComplete",get:function get(){return this._updatePromise}}],[{key:"_ensureClassProperties",value:function _ensureClassProperties(){var _this6=this;if(!this.hasOwnProperty(JSCompiler_renameProperty("_classProperties",this))){this._classProperties=new Map;var superProperties=Object.getPrototypeOf(this)._classProperties;if(superProperties!==void 0){superProperties.forEach(function(v,k){return _this6._classProperties.set(k,v)})}}}},{key:"createProperty",value:function createProperty(name){var options=1<arguments.length&&arguments[1]!==void 0?arguments[1]:defaultPropertyDeclaration;this._ensureClassProperties();this._classProperties.set(name,options);if(options.noAccessor||this.prototype.hasOwnProperty(name)){return}var key="symbol"===babelHelpers.typeof(name)?Symbol():"__".concat(name);Object.defineProperty(this.prototype,name,{get:function get(){return this[key]},set:function set(value){var oldValue=this[name];this[key]=value;this.requestUpdate(name,oldValue)},configurable:!0,enumerable:!0})}},{key:"finalize",value:function finalize(){if(this.hasOwnProperty(JSCompiler_renameProperty("finalized",this))&&this.finalized){return}var superCtor=Object.getPrototypeOf(this);if("function"===typeof superCtor.finalize){superCtor.finalize()}this.finalized=!0;this._ensureClassProperties();this._attributeToPropertyMap=new Map;if(this.hasOwnProperty(JSCompiler_renameProperty("properties",this))){var props=this.properties,propKeys=[].concat(babelHelpers.toConsumableArray(Object.getOwnPropertyNames(props)),babelHelpers.toConsumableArray("function"===typeof Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(props):[])),_iteratorNormalCompletion=!0,_didIteratorError=!1,_iteratorError=void 0;try{for(var _iterator=propKeys[Symbol.iterator](),_step,p;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=!0){p=_step.value;this.createProperty(p,props[p])}}catch(err){_didIteratorError=!0;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&null!=_iterator.return){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}}}},{key:"_attributeNameForProperty",value:function _attributeNameForProperty(name,options){var attribute=options.attribute;return!1===attribute?void 0:"string"===typeof attribute?attribute:"string"===typeof name?name.toLowerCase():void 0}},{key:"_valueHasChanged",value:function _valueHasChanged(value,old){var hasChanged=2<arguments.length&&arguments[2]!==void 0?arguments[2]:notEqual;return hasChanged(value,old)}},{key:"_propertyValueFromAttribute",value:function _propertyValueFromAttribute(value,options){var type=options.type,converter=options.converter||defaultConverter,fromAttribute="function"===typeof converter?converter:converter.fromAttribute;return fromAttribute?fromAttribute(value,type):value}},{key:"_propertyValueToAttribute",value:function _propertyValueToAttribute(value,options){if(options.reflect===void 0){return}var type=options.type,converter=options.converter,toAttribute=converter&&converter.toAttribute||defaultConverter.toAttribute;return toAttribute(value,type)}},{key:"observedAttributes",get:function get(){var _this7=this;this.finalize();var attributes=[];this._classProperties.forEach(function(v,p){var attr=_this7._attributeNameForProperty(p,v);if(attr!==void 0){_this7._attributeToPropertyMap.set(attr,p);attributes.push(attr)}});return attributes}}]);return UpdatingElement}(babelHelpers.wrapNativeSuper(HTMLElement));_exports.UpdatingElement$1=_exports.UpdatingElement=UpdatingElement;UpdatingElement.finalized=!0;var updatingElement={defaultConverter:defaultConverter,notEqual:notEqual,UpdatingElement:UpdatingElement};_exports.$updatingElement=updatingElement;var directives=new WeakMap,directive=function directive(f){return function(){var d=f.apply(void 0,arguments);directives.set(d,!0);return d}};_exports.directive$1=_exports.directive=directive;var isDirective=function isDirective(o){return"function"===typeof o&&directives.has(o)};_exports.isDirective$1=_exports.isDirective=isDirective;var directive$1={directive:directive,isDirective:isDirective};_exports.$directive=directive$1;var isCEPolyfill=window.customElements!==void 0&&window.customElements.polyfillWrapFlushCallback!==void 0;_exports.isCEPolyfill=isCEPolyfill;var reparentNodes=function reparentNodes(container,start){var end=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null,before=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null,node=start;while(node!==end){var n=node.nextSibling;container.insertBefore(node,before);node=n}};_exports.reparentNodes$1=_exports.reparentNodes=reparentNodes;var removeNodes=function removeNodes(container,startNode){var endNode=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null,node=startNode;while(node!==endNode){var n=node.nextSibling;container.removeChild(node);node=n}};_exports.removeNodes$1=_exports.removeNodes=removeNodes;var dom={isCEPolyfill:isCEPolyfill,reparentNodes:reparentNodes,removeNodes:removeNodes};_exports.$dom=dom;var noChange={};_exports.noChange$1=_exports.noChange=noChange;var nothing={};_exports.nothing$1=_exports.nothing=nothing;var part={noChange:noChange,nothing:nothing};_exports.$part=part;var marker="{{lit-".concat((Math.random()+"").slice(2),"}}");_exports.marker=marker;var nodeMarker="<!--".concat(marker,"-->");_exports.nodeMarker=nodeMarker;var markerRegex=new RegExp("".concat(marker,"|").concat(nodeMarker));_exports.markerRegex=markerRegex;var boundAttributeSuffix="$lit$";_exports.boundAttributeSuffix=boundAttributeSuffix;var Template=function Template(result,element){var _this8=this;babelHelpers.classCallCheck(this,Template);this.parts=[];this.element=element;var index=-1,partIndex=0,nodesToRemove=[],_prepareTemplate=function _prepareTemplate(template){var content=template.content,walker=document.createTreeWalker(content,133,null,!1),lastPartIndex=0;while(walker.nextNode()){index++;var node=walker.currentNode;if(1===node.nodeType){if(node.hasAttributes()){for(var attributes=node.attributes,count=0,i=0;i<attributes.length;i++){if(0<=attributes[i].value.indexOf(marker)){count++}}while(0<count--){var stringForPart=result.strings[partIndex],name=lastAttributeNameRegex.exec(stringForPart)[2],attributeLookupName=name.toLowerCase()+boundAttributeSuffix,attributeValue=node.getAttribute(attributeLookupName),strings=attributeValue.split(markerRegex);_this8.parts.push({type:"attribute",index:index,name:name,strings:strings});node.removeAttribute(attributeLookupName);partIndex+=strings.length-1}}if("TEMPLATE"===node.tagName){_prepareTemplate(node)}}else if(3===node.nodeType){var data=node.data;if(0<=data.indexOf(marker)){for(var parent=node.parentNode,_strings=data.split(markerRegex),lastIndex=_strings.length-1,_i=0;_i<lastIndex;_i++){parent.insertBefore(""===_strings[_i]?createMarker():document.createTextNode(_strings[_i]),node);_this8.parts.push({type:"node",index:++index})}if(""===_strings[lastIndex]){parent.insertBefore(createMarker(),node);nodesToRemove.push(node)}else{node.data=_strings[lastIndex]}partIndex+=lastIndex}}else if(8===node.nodeType){if(node.data===marker){var _parent=node.parentNode;if(null===node.previousSibling||index===lastPartIndex){index++;_parent.insertBefore(createMarker(),node)}lastPartIndex=index;_this8.parts.push({type:"node",index:index});if(null===node.nextSibling){node.data=""}else{nodesToRemove.push(node);index--}partIndex++}else{var _i2=-1;while(-1!==(_i2=node.data.indexOf(marker,_i2+1))){_this8.parts.push({type:"node",index:-1})}}}}};_prepareTemplate(element);for(var _i3=0,n;_i3<nodesToRemove.length;_i3++){n=nodesToRemove[_i3];n.parentNode.removeChild(n)}};_exports.Template$1=_exports.Template=Template;var isTemplatePartActive=function isTemplatePartActive(part){return-1!==part.index};_exports.isTemplatePartActive$1=_exports.isTemplatePartActive=isTemplatePartActive;var createMarker=function createMarker(){return document.createComment("")};_exports.createMarker$1=_exports.createMarker=createMarker;var lastAttributeNameRegex=/([ \x09\x0a\x0c\x0d])([^\0-\x1F\x7F-\x9F \x09\x0a\x0c\x0d"'>=/]+)([ \x09\x0a\x0c\x0d]*=[ \x09\x0a\x0c\x0d]*(?:[^ \x09\x0a\x0c\x0d"'`<>=]*|"[^"]*|'[^']*))$/;_exports.lastAttributeNameRegex=lastAttributeNameRegex;var template={marker:marker,nodeMarker:nodeMarker,markerRegex:markerRegex,boundAttributeSuffix:boundAttributeSuffix,Template:Template,isTemplatePartActive:isTemplatePartActive,createMarker:createMarker,lastAttributeNameRegex:lastAttributeNameRegex};_exports.$template=template;var TemplateInstance=function(){function TemplateInstance(template,processor,options){babelHelpers.classCallCheck(this,TemplateInstance);this._parts=[];this.template=template;this.processor=processor;this.options=options}babelHelpers.createClass(TemplateInstance,[{key:"update",value:function update(values){var i=0,_iteratorNormalCompletion2=!0,_didIteratorError2=!1,_iteratorError2=void 0;try{for(var _iterator2=this._parts[Symbol.iterator](),_step2,_part;!(_iteratorNormalCompletion2=(_step2=_iterator2.next()).done);_iteratorNormalCompletion2=!0){_part=_step2.value;if(_part!==void 0){_part.setValue(values[i])}i++}}catch(err){_didIteratorError2=!0;_iteratorError2=err}finally{try{if(!_iteratorNormalCompletion2&&null!=_iterator2.return){_iterator2.return()}}finally{if(_didIteratorError2){throw _iteratorError2}}}var _iteratorNormalCompletion3=!0,_didIteratorError3=!1,_iteratorError3=void 0;try{for(var _iterator3=this._parts[Symbol.iterator](),_step3,_part2;!(_iteratorNormalCompletion3=(_step3=_iterator3.next()).done);_iteratorNormalCompletion3=!0){_part2=_step3.value;if(_part2!==void 0){_part2.commit()}}}catch(err){_didIteratorError3=!0;_iteratorError3=err}finally{try{if(!_iteratorNormalCompletion3&&null!=_iterator3.return){_iterator3.return()}}finally{if(_didIteratorError3){throw _iteratorError3}}}}},{key:"_clone",value:function _clone(){var _this9=this,fragment=isCEPolyfill?this.template.element.content.cloneNode(!0):document.importNode(this.template.element.content,!0),parts=this.template.parts,partIndex=0,nodeIndex=0,_prepareInstance=function _prepareInstance(fragment){var walker=document.createTreeWalker(fragment,133,null,!1),node=walker.nextNode();while(partIndex<parts.length&&null!==node){var _part3=parts[partIndex];if(!isTemplatePartActive(_part3)){_this9._parts.push(void 0);partIndex++}else if(nodeIndex===_part3.index){if("node"===_part3.type){var _part4=_this9.processor.handleTextExpression(_this9.options);_part4.insertAfterNode(node.previousSibling);_this9._parts.push(_part4)}else{var _this9$_parts;(_this9$_parts=_this9._parts).push.apply(_this9$_parts,babelHelpers.toConsumableArray(_this9.processor.handleAttributeExpressions(node,_part3.name,_part3.strings,_this9.options)))}partIndex++}else{nodeIndex++;if("TEMPLATE"===node.nodeName){_prepareInstance(node.content)}node=walker.nextNode()}}};_prepareInstance(fragment);if(isCEPolyfill){document.adoptNode(fragment);customElements.upgrade(fragment)}return fragment}}]);return TemplateInstance}();_exports.TemplateInstance$1=_exports.TemplateInstance=TemplateInstance;var templateInstance={TemplateInstance:TemplateInstance};_exports.$templateInstance=templateInstance;var TemplateResult=function(){function TemplateResult(strings,values,type,processor){babelHelpers.classCallCheck(this,TemplateResult);this.strings=strings;this.values=values;this.type=type;this.processor=processor}babelHelpers.createClass(TemplateResult,[{key:"getHTML",value:function getHTML(){for(var endIndex=this.strings.length-1,html="",i=0;i<endIndex;i++){var s=this.strings[i],match=lastAttributeNameRegex.exec(s);if(match){html+=s.substr(0,match.index)+match[1]+match[2]+boundAttributeSuffix+match[3]+marker}else{html+=s+nodeMarker}}return html+this.strings[endIndex]}},{key:"getTemplateElement",value:function getTemplateElement(){var template=document.createElement("template");template.innerHTML=this.getHTML();return template}}]);return TemplateResult}();_exports.TemplateResult$3=_exports.TemplateResult$2=_exports.TemplateResult$1=_exports.TemplateResult=TemplateResult;var SVGTemplateResult=function(_TemplateResult){babelHelpers.inherits(SVGTemplateResult,_TemplateResult);function SVGTemplateResult(){babelHelpers.classCallCheck(this,SVGTemplateResult);return babelHelpers.possibleConstructorReturn(this,babelHelpers.getPrototypeOf(SVGTemplateResult).apply(this,arguments))}babelHelpers.createClass(SVGTemplateResult,[{key:"getHTML",value:function getHTML(){return"<svg>".concat(babelHelpers.get(babelHelpers.getPrototypeOf(SVGTemplateResult.prototype),"getHTML",this).call(this),"</svg>")}},{key:"getTemplateElement",value:function getTemplateElement(){var template=babelHelpers.get(babelHelpers.getPrototypeOf(SVGTemplateResult.prototype),"getTemplateElement",this).call(this),content=template.content,svgElement=content.firstChild;content.removeChild(svgElement);reparentNodes(content,svgElement.firstChild);return template}}]);return SVGTemplateResult}(TemplateResult);_exports.SVGTemplateResult$2=_exports.SVGTemplateResult$1=_exports.SVGTemplateResult=SVGTemplateResult;var templateResult={TemplateResult:TemplateResult,SVGTemplateResult:SVGTemplateResult};_exports.$templateResult=templateResult;var isPrimitive=function isPrimitive(value){return null===value||!("object"===babelHelpers.typeof(value)||"function"===typeof value)};_exports.isPrimitive$1=_exports.isPrimitive=isPrimitive;var AttributeCommitter=function(){function AttributeCommitter(element,name,strings){babelHelpers.classCallCheck(this,AttributeCommitter);this.dirty=!0;this.element=element;this.name=name;this.strings=strings;this.parts=[];for(var i=0;i<strings.length-1;i++){this.parts[i]=this._createPart()}}babelHelpers.createClass(AttributeCommitter,[{key:"_createPart",value:function _createPart(){return new AttributePart(this)}},{key:"_getValue",value:function _getValue(){for(var strings=this.strings,l=strings.length-1,text="",i=0;i<l;i++){text+=strings[i];var _part5=this.parts[i];if(_part5!==void 0){var v=_part5.value;if(null!=v&&(Array.isArray(v)||"string"!==typeof v&&v[Symbol.iterator])){var _iteratorNormalCompletion4=!0,_didIteratorError4=!1,_iteratorError4=void 0;try{for(var _iterator4=v[Symbol.iterator](),_step4,t;!(_iteratorNormalCompletion4=(_step4=_iterator4.next()).done);_iteratorNormalCompletion4=!0){t=_step4.value;text+="string"===typeof t?t:t+""}}catch(err){_didIteratorError4=!0;_iteratorError4=err}finally{try{if(!_iteratorNormalCompletion4&&null!=_iterator4.return){_iterator4.return()}}finally{if(_didIteratorError4){throw _iteratorError4}}}}else{text+="string"===typeof v?v:v+""}}}text+=strings[l];return text}},{key:"commit",value:function commit(){if(this.dirty){this.dirty=!1;this.element.setAttribute(this.name,this._getValue())}}}]);return AttributeCommitter}();_exports.AttributeCommitter$1=_exports.AttributeCommitter=AttributeCommitter;var AttributePart=function(){function AttributePart(comitter){babelHelpers.classCallCheck(this,AttributePart);this.value=void 0;this.committer=comitter}babelHelpers.createClass(AttributePart,[{key:"setValue",value:function setValue(value){if(value!==noChange&&(!isPrimitive(value)||value!==this.value)){this.value=value;if(!isDirective(value)){this.committer.dirty=!0}}}},{key:"commit",value:function commit(){while(isDirective(this.value)){var directive$$1=this.value;this.value=noChange;directive$$1(this)}if(this.value===noChange){return}this.committer.commit()}}]);return AttributePart}();_exports.AttributePart$1=_exports.AttributePart=AttributePart;var NodePart=function(){function NodePart(options){babelHelpers.classCallCheck(this,NodePart);this.value=void 0;this._pendingValue=void 0;this.options=options}babelHelpers.createClass(NodePart,[{key:"appendInto",value:function appendInto(container){this.startNode=container.appendChild(createMarker());this.endNode=container.appendChild(createMarker())}},{key:"insertAfterNode",value:function insertAfterNode(ref){this.startNode=ref;this.endNode=ref.nextSibling}},{key:"appendIntoPart",value:function appendIntoPart(part){part._insert(this.startNode=createMarker());part._insert(this.endNode=createMarker())}},{key:"insertAfterPart",value:function insertAfterPart(ref){ref._insert(this.startNode=createMarker());this.endNode=ref.endNode;ref.endNode=this.startNode}},{key:"setValue",value:function setValue(value){this._pendingValue=value}},{key:"commit",value:function commit(){while(isDirective(this._pendingValue)){var directive$$1=this._pendingValue;this._pendingValue=noChange;directive$$1(this)}var value=this._pendingValue;if(value===noChange){return}if(isPrimitive(value)){if(value!==this.value){this._commitText(value)}}else if(babelHelpers.instanceof(value,TemplateResult)){this._commitTemplateResult(value)}else if(babelHelpers.instanceof(value,Node)){this._commitNode(value)}else if(Array.isArray(value)||value[Symbol.iterator]){this._commitIterable(value)}else if(value===nothing){this.value=nothing;this.clear()}else{this._commitText(value)}}},{key:"_insert",value:function _insert(node){this.endNode.parentNode.insertBefore(node,this.endNode)}},{key:"_commitNode",value:function _commitNode(value){if(this.value===value){return}this.clear();this._insert(value);this.value=value}},{key:"_commitText",value:function _commitText(value){var node=this.startNode.nextSibling;value=null==value?"":value;if(node===this.endNode.previousSibling&&3===node.nodeType){node.data=value}else{this._commitNode(document.createTextNode("string"===typeof value?value:value+""))}this.value=value}},{key:"_commitTemplateResult",value:function _commitTemplateResult(value){var template=this.options.templateFactory(value);if(babelHelpers.instanceof(this.value,TemplateInstance)&&this.value.template===template){this.value.update(value.values)}else{var instance=new TemplateInstance(template,value.processor,this.options),fragment=instance._clone();instance.update(value.values);this._commitNode(fragment);this.value=instance}}},{key:"_commitIterable",value:function _commitIterable(value){if(!Array.isArray(this.value)){this.value=[];this.clear()}var itemParts=this.value,partIndex=0,itemPart,_iteratorNormalCompletion5=!0,_didIteratorError5=!1,_iteratorError5=void 0;try{for(var _iterator5=value[Symbol.iterator](),_step5,item;!(_iteratorNormalCompletion5=(_step5=_iterator5.next()).done);_iteratorNormalCompletion5=!0){item=_step5.value;itemPart=itemParts[partIndex];if(itemPart===void 0){itemPart=new NodePart(this.options);itemParts.push(itemPart);if(0===partIndex){itemPart.appendIntoPart(this)}else{itemPart.insertAfterPart(itemParts[partIndex-1])}}itemPart.setValue(item);itemPart.commit();partIndex++}}catch(err){_didIteratorError5=!0;_iteratorError5=err}finally{try{if(!_iteratorNormalCompletion5&&null!=_iterator5.return){_iterator5.return()}}finally{if(_didIteratorError5){throw _iteratorError5}}}if(partIndex<itemParts.length){itemParts.length=partIndex;this.clear(itemPart&&itemPart.endNode)}}},{key:"clear",value:function clear(){var startNode=0<arguments.length&&arguments[0]!==void 0?arguments[0]:this.startNode;removeNodes(this.startNode.parentNode,startNode.nextSibling,this.endNode)}}]);return NodePart}();_exports.NodePart$1=_exports.NodePart=NodePart;var BooleanAttributePart=function(){function BooleanAttributePart(element,name,strings){babelHelpers.classCallCheck(this,BooleanAttributePart);this.value=void 0;this._pendingValue=void 0;if(2!==strings.length||""!==strings[0]||""!==strings[1]){throw new Error("Boolean attributes can only contain a single expression")}this.element=element;this.name=name;this.strings=strings}babelHelpers.createClass(BooleanAttributePart,[{key:"setValue",value:function setValue(value){this._pendingValue=value}},{key:"commit",value:function commit(){while(isDirective(this._pendingValue)){var directive$$1=this._pendingValue;this._pendingValue=noChange;directive$$1(this)}if(this._pendingValue===noChange){return}var value=!!this._pendingValue;if(this.value!==value){if(value){this.element.setAttribute(this.name,"")}else{this.element.removeAttribute(this.name)}}this.value=value;this._pendingValue=noChange}}]);return BooleanAttributePart}();_exports.BooleanAttributePart$1=_exports.BooleanAttributePart=BooleanAttributePart;var PropertyCommitter=function(_AttributeCommitter){babelHelpers.inherits(PropertyCommitter,_AttributeCommitter);function PropertyCommitter(element,name,strings){var _this10;babelHelpers.classCallCheck(this,PropertyCommitter);_this10=babelHelpers.possibleConstructorReturn(this,babelHelpers.getPrototypeOf(PropertyCommitter).call(this,element,name,strings));_this10.single=2===strings.length&&""===strings[0]&&""===strings[1];return _this10}babelHelpers.createClass(PropertyCommitter,[{key:"_createPart",value:function _createPart(){return new PropertyPart(this)}},{key:"_getValue",value:function _getValue(){if(this.single){return this.parts[0].value}return babelHelpers.get(babelHelpers.getPrototypeOf(PropertyCommitter.prototype),"_getValue",this).call(this)}},{key:"commit",value:function commit(){if(this.dirty){this.dirty=!1;this.element[this.name]=this._getValue()}}}]);return PropertyCommitter}(AttributeCommitter);_exports.PropertyCommitter$1=_exports.PropertyCommitter=PropertyCommitter;var PropertyPart=function(_AttributePart){babelHelpers.inherits(PropertyPart,_AttributePart);function PropertyPart(){babelHelpers.classCallCheck(this,PropertyPart);return babelHelpers.possibleConstructorReturn(this,babelHelpers.getPrototypeOf(PropertyPart).apply(this,arguments))}return PropertyPart}(AttributePart);_exports.PropertyPart$1=_exports.PropertyPart=PropertyPart;var eventOptionsSupported=!1;try{var options={get capture(){eventOptionsSupported=!0;return!1}};window.addEventListener("test",options,options);window.removeEventListener("test",options,options)}catch(_e){}var EventPart=function(){function EventPart(element,eventName,eventContext){var _this11=this;babelHelpers.classCallCheck(this,EventPart);this.value=void 0;this._pendingValue=void 0;this.element=element;this.eventName=eventName;this.eventContext=eventContext;this._boundHandleEvent=function(e){return _this11.handleEvent(e)}}babelHelpers.createClass(EventPart,[{key:"setValue",value:function setValue(value){this._pendingValue=value}},{key:"commit",value:function commit(){while(isDirective(this._pendingValue)){var directive$$1=this._pendingValue;this._pendingValue=noChange;directive$$1(this)}if(this._pendingValue===noChange){return}var newListener=this._pendingValue,oldListener=this.value,shouldRemoveListener=null==newListener||null!=oldListener&&(newListener.capture!==oldListener.capture||newListener.once!==oldListener.once||newListener.passive!==oldListener.passive),shouldAddListener=null!=newListener&&(null==oldListener||shouldRemoveListener);if(shouldRemoveListener){this.element.removeEventListener(this.eventName,this._boundHandleEvent,this._options)}if(shouldAddListener){this._options=getOptions(newListener);this.element.addEventListener(this.eventName,this._boundHandleEvent,this._options)}this.value=newListener;this._pendingValue=noChange}},{key:"handleEvent",value:function handleEvent(event){if("function"===typeof this.value){this.value.call(this.eventContext||this.element,event)}else{this.value.handleEvent(event)}}}]);return EventPart}();_exports.EventPart$1=_exports.EventPart=EventPart;var getOptions=function getOptions(o){return o&&(eventOptionsSupported?{capture:o.capture,passive:o.passive,once:o.once}:o.capture)},parts={isPrimitive:isPrimitive,AttributeCommitter:AttributeCommitter,AttributePart:AttributePart,NodePart:NodePart,BooleanAttributePart:BooleanAttributePart,PropertyCommitter:PropertyCommitter,PropertyPart:PropertyPart,EventPart:EventPart};_exports.$parts=parts;var DefaultTemplateProcessor=function(){function DefaultTemplateProcessor(){babelHelpers.classCallCheck(this,DefaultTemplateProcessor)}babelHelpers.createClass(DefaultTemplateProcessor,[{key:"handleAttributeExpressions",value:function handleAttributeExpressions(element,name,strings,options){var prefix=name[0];if("."===prefix){var _comitter=new PropertyCommitter(element,name.slice(1),strings);return _comitter.parts}if("@"===prefix){return[new EventPart(element,name.slice(1),options.eventContext)]}if("?"===prefix){return[new BooleanAttributePart(element,name.slice(1),strings)]}var comitter=new AttributeCommitter(element,name,strings);return comitter.parts}},{key:"handleTextExpression",value:function handleTextExpression(options){return new NodePart(options)}}]);return DefaultTemplateProcessor}();_exports.DefaultTemplateProcessor$1=_exports.DefaultTemplateProcessor=DefaultTemplateProcessor;var defaultTemplateProcessor=new DefaultTemplateProcessor;_exports.defaultTemplateProcessor$1=_exports.defaultTemplateProcessor=defaultTemplateProcessor;var defaultTemplateProcessor$1={DefaultTemplateProcessor:DefaultTemplateProcessor,defaultTemplateProcessor:defaultTemplateProcessor};_exports.$defaultTemplateProcessor=defaultTemplateProcessor$1;function templateFactory(result){var templateCache=templateCaches.get(result.type);if(templateCache===void 0){templateCache={stringsArray:new WeakMap,keyString:new Map};templateCaches.set(result.type,templateCache)}var template=templateCache.stringsArray.get(result.strings);if(template!==void 0){return template}var key=result.strings.join(marker);template=templateCache.keyString.get(key);if(template===void 0){template=new Template(result,result.getTemplateElement());templateCache.keyString.set(key,template)}templateCache.stringsArray.set(result.strings,template);return template}var templateCaches=new Map;_exports.templateCaches$1=_exports.templateCaches=templateCaches;var templateFactory$1={templateFactory:templateFactory,templateCaches:templateCaches};_exports.$templateFactory=templateFactory$1;var parts$1=new WeakMap;_exports.parts$1=_exports.parts=parts$1;var render=function render(result,container,options){var part=parts$1.get(container);if(part===void 0){removeNodes(container,container.firstChild);parts$1.set(container,part=new NodePart(Object.assign({templateFactory:templateFactory},options)));part.appendInto(container)}part.setValue(result);part.commit()};_exports.render$2=_exports.render=render;var render$1={parts:parts$1,render:render};_exports.$render=render$1;(window.litHtmlVersions||(window.litHtmlVersions=[])).push("1.0.0");var html=function html(strings){for(var _len2=arguments.length,values=Array(1<_len2?_len2-1:0),_key2=1;_key2<_len2;_key2++){values[_key2-1]=arguments[_key2]}return new TemplateResult(strings,values,"html",defaultTemplateProcessor)};_exports.html$2=_exports.html$1=_exports.html=html;var svg=function svg(strings){for(var _len3=arguments.length,values=Array(1<_len3?_len3-1:0),_key3=1;_key3<_len3;_key3++){values[_key3-1]=arguments[_key3]}return new SVGTemplateResult(strings,values,"svg",defaultTemplateProcessor)};_exports.svg$2=_exports.svg$1=_exports.svg=svg;var litHtml={html:html,svg:svg,DefaultTemplateProcessor:DefaultTemplateProcessor,defaultTemplateProcessor:defaultTemplateProcessor,directive:directive,isDirective:isDirective,removeNodes:removeNodes,reparentNodes:reparentNodes,noChange:noChange,nothing:nothing,AttributeCommitter:AttributeCommitter,AttributePart:AttributePart,BooleanAttributePart:BooleanAttributePart,EventPart:EventPart,isPrimitive:isPrimitive,NodePart:NodePart,PropertyCommitter:PropertyCommitter,PropertyPart:PropertyPart,parts:parts$1,render:render,templateCaches:templateCaches,templateFactory:templateFactory,TemplateInstance:TemplateInstance,SVGTemplateResult:SVGTemplateResult,TemplateResult:TemplateResult,createMarker:createMarker,isTemplatePartActive:isTemplatePartActive,Template:Template};_exports.$litHtml=litHtml;var walkerNodeFilter=133;function removeNodesFromTemplate(template,nodesToRemove){var content=template.element.content,parts=template.parts,walker=document.createTreeWalker(content,walkerNodeFilter,null,!1),partIndex=nextActiveIndexInTemplateParts(parts),part=parts[partIndex],nodeIndex=-1,removeCount=0,nodesToRemoveInTemplate=[],currentRemovingNode=null;while(walker.nextNode()){nodeIndex++;var node=walker.currentNode;if(node.previousSibling===currentRemovingNode){currentRemovingNode=null}if(nodesToRemove.has(node)){nodesToRemoveInTemplate.push(node);if(null===currentRemovingNode){currentRemovingNode=node}}if(null!==currentRemovingNode){removeCount++}while(part!==void 0&&part.index===nodeIndex){part.index=null!==currentRemovingNode?-1:part.index-removeCount;partIndex=nextActiveIndexInTemplateParts(parts,partIndex);part=parts[partIndex]}}nodesToRemoveInTemplate.forEach(function(n){return n.parentNode.removeChild(n)})}var countNodes=function countNodes(node){var count=11===node.nodeType?0:1,walker=document.createTreeWalker(node,walkerNodeFilter,null,!1);while(walker.nextNode()){count++}return count},nextActiveIndexInTemplateParts=function nextActiveIndexInTemplateParts(parts){for(var startIndex=1<arguments.length&&arguments[1]!==void 0?arguments[1]:-1,i=startIndex+1,_part6;i<parts.length;i++){_part6=parts[i];if(isTemplatePartActive(_part6)){return i}}return-1};function insertNodeIntoTemplate(template,node){var refNode=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null,content=template.element.content,parts=template.parts;if(null===refNode||refNode===void 0){content.appendChild(node);return}var walker=document.createTreeWalker(content,walkerNodeFilter,null,!1),partIndex=nextActiveIndexInTemplateParts(parts),insertCount=0,walkerIndex=-1;while(walker.nextNode()){walkerIndex++;var walkerNode=walker.currentNode;if(walkerNode===refNode){insertCount=countNodes(node);refNode.parentNode.insertBefore(node,refNode)}while(-1!==partIndex&&parts[partIndex].index===walkerIndex){if(0<insertCount){while(-1!==partIndex){parts[partIndex].index+=insertCount;partIndex=nextActiveIndexInTemplateParts(parts,partIndex)}return}partIndex=nextActiveIndexInTemplateParts(parts,partIndex)}}}var modifyTemplate={removeNodesFromTemplate:removeNodesFromTemplate,insertNodeIntoTemplate:insertNodeIntoTemplate};_exports.$modifyTemplate=modifyTemplate;var getTemplateCacheKey=function getTemplateCacheKey(type,scopeName){return"".concat(type,"--").concat(scopeName)},compatibleShadyCSSVersion=!0;if("undefined"===typeof window.ShadyCSS){compatibleShadyCSSVersion=!1}else if("undefined"===typeof window.ShadyCSS.prepareTemplateDom){console.warn("Incompatible ShadyCSS version detected."+"Please update to at least @webcomponents/webcomponentsjs@2.0.2 and"+"@webcomponents/shadycss@1.3.1.");compatibleShadyCSSVersion=!1}var shadyTemplateFactory=function shadyTemplateFactory(scopeName){return function(result){var cacheKey=getTemplateCacheKey(result.type,scopeName),templateCache=templateCaches.get(cacheKey);if(templateCache===void 0){templateCache={stringsArray:new WeakMap,keyString:new Map};templateCaches.set(cacheKey,templateCache)}var template=templateCache.stringsArray.get(result.strings);if(template!==void 0){return template}var key=result.strings.join(marker);template=templateCache.keyString.get(key);if(template===void 0){var element=result.getTemplateElement();if(compatibleShadyCSSVersion){window.ShadyCSS.prepareTemplateDom(element,scopeName)}template=new Template(result,element);templateCache.keyString.set(key,template)}templateCache.stringsArray.set(result.strings,template);return template}},TEMPLATE_TYPES=["html","svg"],removeStylesFromLitTemplates=function removeStylesFromLitTemplates(scopeName){TEMPLATE_TYPES.forEach(function(type){var templates=templateCaches.get(getTemplateCacheKey(type,scopeName));if(templates!==void 0){templates.keyString.forEach(function(template){var content=template.element.content,styles=new Set;Array.from(content.querySelectorAll("style")).forEach(function(s){styles.add(s)});removeNodesFromTemplate(template,styles)})}})},shadyRenderSet=new Set,prepareTemplateStyles=function prepareTemplateStyles(renderedDOM,template,scopeName){shadyRenderSet.add(scopeName);var styles=renderedDOM.querySelectorAll("style");if(0===styles.length){window.ShadyCSS.prepareTemplateStyles(template.element,scopeName);return}for(var condensedStyle=document.createElement("style"),i=0,style;i<styles.length;i++){style=styles[i];style.parentNode.removeChild(style);condensedStyle.textContent+=style.textContent}removeStylesFromLitTemplates(scopeName);insertNodeIntoTemplate(template,condensedStyle,template.element.content.firstChild);window.ShadyCSS.prepareTemplateStyles(template.element,scopeName);if(window.ShadyCSS.nativeShadow){var _style=template.element.content.querySelector("style");renderedDOM.insertBefore(_style.cloneNode(!0),renderedDOM.firstChild)}else{template.element.content.insertBefore(condensedStyle,template.element.content.firstChild);var removes=new Set([condensedStyle]);removeNodesFromTemplate(template,removes)}},render$2=function render$2(result,container,options){var scopeName=options.scopeName,hasRendered=parts$1.has(container),needsScoping=babelHelpers.instanceof(container,ShadowRoot)&&compatibleShadyCSSVersion&&babelHelpers.instanceof(result,TemplateResult),firstScopeRender=needsScoping&&!shadyRenderSet.has(scopeName),renderContainer=firstScopeRender?document.createDocumentFragment():container;render(result,renderContainer,Object.assign({templateFactory:shadyTemplateFactory(scopeName)},options));if(firstScopeRender){var _part7=parts$1.get(renderContainer);parts$1.delete(renderContainer);if(babelHelpers.instanceof(_part7.value,TemplateInstance)){prepareTemplateStyles(renderContainer,_part7.value.template,scopeName)}removeNodes(container,container.firstChild);container.appendChild(renderContainer);parts$1.set(container,_part7)}if(!hasRendered&&needsScoping){window.ShadyCSS.styleElement(container.host)}};_exports.render$1=render$2;var shadyRender={render:render$2,html:html,svg:svg,TemplateResult:TemplateResult};_exports.$shadyRender=shadyRender;(window.litElementVersions||(window.litElementVersions=[])).push("2.0.1");function arrayFlat(styles){for(var result=1<arguments.length&&arguments[1]!==void 0?arguments[1]:[],i=0,length=styles.length,value;i<length;i++){value=styles[i];if(Array.isArray(value)){arrayFlat(value,result)}else{result.push(value)}}return result}var flattenStyles=function flattenStyles(styles){return styles.flat?styles.flat(1/0):arrayFlat(styles)},LitElement=function(_UpdatingElement){babelHelpers.inherits(LitElement,_UpdatingElement);function LitElement(){babelHelpers.classCallCheck(this,LitElement);return babelHelpers.possibleConstructorReturn(this,babelHelpers.getPrototypeOf(LitElement).apply(this,arguments))}babelHelpers.createClass(LitElement,[{key:"initialize",value:function initialize(){babelHelpers.get(babelHelpers.getPrototypeOf(LitElement.prototype),"initialize",this).call(this);this.renderRoot=this.createRenderRoot();if(window.ShadowRoot&&babelHelpers.instanceof(this.renderRoot,window.ShadowRoot)){this.adoptStyles()}}},{key:"createRenderRoot",value:function createRenderRoot(){return this.attachShadow({mode:"open"})}},{key:"adoptStyles",value:function adoptStyles(){var styles=this.constructor._styles;if(0===styles.length){return}if(window.ShadyCSS!==void 0&&!window.ShadyCSS.nativeShadow){window.ShadyCSS.ScopingShim.prepareAdoptedCssText(styles.map(function(s){return s.cssText}),this.localName)}else if(supportsAdoptingStyleSheets){this.renderRoot.adoptedStyleSheets=styles.map(function(s){return s.styleSheet})}else{this._needsShimAdoptedStyleSheets=!0}}},{key:"connectedCallback",value:function connectedCallback(){babelHelpers.get(babelHelpers.getPrototypeOf(LitElement.prototype),"connectedCallback",this).call(this);if(this.hasUpdated&&window.ShadyCSS!==void 0){window.ShadyCSS.styleElement(this)}}},{key:"update",value:function update(changedProperties){var _this12=this;babelHelpers.get(babelHelpers.getPrototypeOf(LitElement.prototype),"update",this).call(this,changedProperties);var templateResult=this.render();if(babelHelpers.instanceof(templateResult,TemplateResult)){this.constructor.render(templateResult,this.renderRoot,{scopeName:this.localName,eventContext:this})}if(this._needsShimAdoptedStyleSheets){this._needsShimAdoptedStyleSheets=!1;this.constructor._styles.forEach(function(s){var style=document.createElement("style");style.textContent=s.cssText;_this12.renderRoot.appendChild(style)})}}},{key:"render",value:function render(){}}],[{key:"finalize",value:function finalize(){babelHelpers.get(babelHelpers.getPrototypeOf(LitElement),"finalize",this).call(this);this._styles=this.hasOwnProperty(JSCompiler_renameProperty("styles",this))?this._getUniqueStyles():this._styles||[]}},{key:"_getUniqueStyles",value:function _getUniqueStyles(){var userStyles=this.styles,styles=[];if(Array.isArray(userStyles)){var flatStyles=flattenStyles(userStyles),styleSet=flatStyles.reduceRight(function(set,s){set.add(s);return set},new Set);styleSet.forEach(function(v){return styles.unshift(v)})}else if(userStyles){styles.push(userStyles)}return styles}}]);return LitElement}(UpdatingElement);_exports.LitElement=LitElement;LitElement.finalized=!0;LitElement.render=render$2;var litElement={LitElement:LitElement,defaultConverter:defaultConverter,notEqual:notEqual,UpdatingElement:UpdatingElement,customElement:customElement,property:property,query:query,queryAll:queryAll,eventOptions:eventOptions,html:html,svg:svg,TemplateResult:TemplateResult,SVGTemplateResult:SVGTemplateResult,supportsAdoptingStyleSheets:supportsAdoptingStyleSheets,CSSResult:CSSResult,unsafeCSS:unsafeCSS,css:css};_exports.$litElement=litElement;var previousValues=new WeakMap,unsafeHTML=directive(function(value){return function(part){if(!babelHelpers.instanceof(part,NodePart)){throw new Error("unsafeHTML can only be used in text bindings")}var previousValue=previousValues.get(part);if(previousValue!==void 0&&isPrimitive(value)&&value===previousValue.value&&part.value===previousValue.fragment){return}var template=document.createElement("template");template.innerHTML=value;var fragment=document.importNode(template.content,!0);part.setValue(fragment);previousValues.set(part,{value:value,fragment:fragment})}});_exports.unsafeHTML=unsafeHTML;var unsafeHtml={unsafeHTML:unsafeHTML};_exports.$unsafeHtml=unsafeHtml;var buildQueryString=function buildQueryString(props,supportedKeys){var result="";Object.keys(props).forEach(function(key){if(-1===supportedKeys.indexOf(key)){return}if(!result&&props[key]){result="?".concat(key,"=").concat(props[key]);return}if(result&&props[key]){result="".concat(result,"&").concat(key,"=").concat(props[key]);return}});return result};_exports.buildQueryString=buildQueryString;var formatDate=function formatDate(timestring){var pad=function pad(v){return 10>v?"0".concat(v):"".concat(v)},dateString=timestring.split("T")[0],date=new Date(dateString),year=date.getUTCFullYear().toString(),day=pad(date.getUTCDate()),weekday=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"][date.getUTCDay()],month=["January","February","March","April","May","June","July","August","September","October","November","December"][date.getUTCMonth()];return"".concat(weekday,", ").concat(day," ").concat(month," ").concat(year)};_exports.formatDate=formatDate;var removeSubdomain=function removeSubdomain(link,subDomain){return link?link.replace("//".concat(subDomain,"."),"//"):""};_exports.removeSubdomain=removeSubdomain;var getPosts=function getPosts(apiUrl){return new Promise(function(resolve,reject){return fetch(apiUrl).then(function(res){if(res.ok){return res.json()}throw new Error("status: ".concat(res.status,"\n ").concat(res.statusText?" | statusText: ".concat(res.statusText):"","\n "))}).then(function(response){return resolve(response)}).catch(function(err){return reject(err)})})};_exports.getPosts=getPosts;var getPostsUrl=function getPostsUrl(props,supportedKeys){return"".concat(props.apiHost).concat(props.apiPath,"/posts").concat(buildQueryString(props,supportedKeys))};_exports.getPostsUrl=getPostsUrl;var misc={buildQueryString:buildQueryString,formatDate:formatDate,removeSubdomain:removeSubdomain,getPosts:getPosts,getPostsUrl:getPostsUrl};_exports.$misc=misc;var article=function article(_ref){var content=_ref.content,date_gmt=_ref.date_gmt,errorMessage=_ref.errorMessage,link=_ref.link,title=_ref.title;return html(_templateObject_1c8d9ae03fba11e999fab3e0d1307b7a(),unsafeHTML("<a href=\"".concat(link,"\">").concat(title.rendered,"</a>")),errorMessage?errorMessage:date_gmt?formatDate(date_gmt):"",unsafeHTML(content.rendered))};_exports.$articleDefault=article;var article$1={default:article};_exports.$article=article$1;var getErrorMessageArticle=function getErrorMessageArticle(err){return[article({errorMessage:"".concat(err.message),date_gmt:"",link:"",title:{rendered:"Error"},content:{rendered:"<p>Posts are unavailable. Please check the error and try again.</p>"}})]};_exports.getErrorMessageArticle=getErrorMessageArticle;var loading=[article({errorMessage:"",date_gmt:"",link:"",title:{rendered:"Loading..."},content:{rendered:""}})];_exports.loading=loading;var articles=function articles(_articles){return _articles.map(function(res){return article(res)})};_exports.$articlesDefault=articles;var articles$1={getErrorMessageArticle:getErrorMessageArticle,loading:loading,default:articles};_exports.$articles=articles$1;var styles=css(_templateObject2_1c8d9ae03fba11e999fab3e0d1307b7a());_exports.$xPostpressDefault$1=styles;var xPostpress={default:styles};_exports.$xPostpress$1=xPostpress;var __decorate=void 0||function(decorators,target,key,desc){var c=arguments.length,r=3>c?target:null===desc?desc=Object.getOwnPropertyDescriptor(target,key):desc,d;if("object"===("undefined"===typeof Reflect?"undefined":babelHelpers.typeof(Reflect))&&"function"===typeof Reflect.decorate)r=Reflect.decorate(decorators,target,key,desc);else for(var i=decorators.length-1;0<=i;i--){if(d=decorators[i])r=(3>c?d(r):3<c?d(target,key,r):d(target,key))||r}return 3<c&&r&&Object.defineProperty(target,key,r),r},default_1=function(_LitElement){babelHelpers.inherits(default_1,_LitElement);function default_1(){var _this13;babelHelpers.classCallCheck(this,default_1);_this13=babelHelpers.possibleConstructorReturn(this,babelHelpers.getPrototypeOf(default_1).call(this));_this13.apiHost="";_this13.apiPath="/wp-json/wp/v2";_this13.categories="";_this13.include="";_this13.page="";_this13.per_page="";_this13.tags="";_this13.search="";_this13.slug="";_this13.urlAttributes=["apiHost","apiPath"];_this13.builtQueryStringAttributes=["categories","include","page","per_page","search","slug","tags"];_this13.didGetPosts=!1;_this13.articles=loading;return _this13}babelHelpers.createClass(default_1,[{key:"requestPosts",value:function requestPosts(){var _this14=this,postsUrl=getPostsUrl({apiHost:this.apiHost,apiPath:this.apiPath,categories:this.categories,include:this.include,page:this.page,per_page:this.per_page,search:this.search,slug:this.slug,tags:this.tags},this.builtQueryStringAttributes);getPosts(postsUrl).then(function(res){return articles(res)}).catch(function(err){return getErrorMessageArticle(err)}).then(function(articles$$1){_this14.didGetPosts=!0;_this14.articles=articles$$1})}},{key:"firstUpdated",value:function firstUpdated(){if(this.apiHost){this.requestPosts()}}},{key:"updated",value:function updated(changedProperties){if(this.didGetPosts&&this.apiHost){var shouldGetPostsAttributes=[].concat(babelHelpers.toConsumableArray(this.urlAttributes),babelHelpers.toConsumableArray(this.builtQueryStringAttributes)),props=changedProperties.keys(),prop=props.next();while(!prop.done){if(-1!==shouldGetPostsAttributes.indexOf(prop.value)){this.requestPosts();break}prop=props.next()}}}},{key:"render",value:function render(){return html(_templateObject3_1c8d9ae03fba11e999fab3e0d1307b7a(),this.apiHost&&this.articles)}}]);return default_1}(LitElement);default_1.styles=styles;__decorate([property({type:String,reflect:!0})],default_1.prototype,"apiHost",void 0);__decorate([property({type:String,reflect:!0})],default_1.prototype,"apiPath",void 0);__decorate([property({type:String,reflect:!0})],default_1.prototype,"categories",void 0);__decorate([property({type:String,reflect:!0})],default_1.prototype,"include",void 0);__decorate([property({type:String,reflect:!0})],default_1.prototype,"page",void 0);__decorate([property({type:String,reflect:!0})],default_1.prototype,"per_page",void 0);__decorate([property({type:String,reflect:!0})],default_1.prototype,"tags",void 0);__decorate([property({type:String,reflect:!0})],default_1.prototype,"search",void 0);__decorate([property({type:String,reflect:!0})],default_1.prototype,"slug",void 0);__decorate([property({type:Array})],default_1.prototype,"urlAttributes",void 0);__decorate([property({type:Array})],default_1.prototype,"builtQueryStringAttributes",void 0);__decorate([property({type:Boolean})],default_1.prototype,"didGetPosts",void 0);__decorate([property({type:Object,noAccessor:!1})],default_1.prototype,"articles",void 0);default_1=__decorate([customElement("x-postpress")],default_1);var default_1$1=default_1;_exports.$xPostpressDefault=default_1$1;var xPostpress$1={default:default_1$1};_exports.$xPostpress=xPostpress$1});
define(["exports"],function(_exports){"use strict";Object.defineProperty(_exports,"__esModule",{value:!0});_exports.property$1=_exports.property=property;_exports.removeNodesFromTemplate=removeNodesFromTemplate;_exports.insertNodeIntoTemplate=insertNodeIntoTemplate;_exports.templateFactory$1=_exports.templateFactory=templateFactory;_exports.templateCaches$1=_exports.templateCaches=_exports.render$1=_exports.render$2=_exports.render=_exports.parts$1=_exports.parts=_exports.EventPart$1=_exports.EventPart=_exports.PropertyPart$1=_exports.PropertyPart=_exports.PropertyCommitter$1=_exports.PropertyCommitter=_exports.BooleanAttributePart$1=_exports.BooleanAttributePart=_exports.NodePart$1=_exports.NodePart=_exports.AttributePart$1=_exports.AttributePart=_exports.AttributeCommitter$1=_exports.AttributeCommitter=_exports.isPrimitive$1=_exports.isPrimitive=_exports.nothing$1=_exports.nothing=_exports.noChange$1=_exports.noChange=_exports.removeNodes$1=_exports.removeNodes=_exports.reparentNodes$1=_exports.reparentNodes=_exports.isCEPolyfill=_exports.isDirective$1=_exports.isDirective=_exports.directive$1=_exports.directive=_exports.defaultTemplateProcessor$1=_exports.defaultTemplateProcessor=_exports.DefaultTemplateProcessor$1=_exports.DefaultTemplateProcessor=_exports.unsafeHTML=_exports.LitElement=_exports.SVGTemplateResult$2=_exports.SVGTemplateResult$1=_exports.SVGTemplateResult=_exports.TemplateResult$3=_exports.TemplateResult$2=_exports.TemplateResult$1=_exports.TemplateResult=_exports.svg$2=_exports.svg$1=_exports.svg=_exports.html$2=_exports.html$1=_exports.html=_exports.UpdatingElement$1=_exports.UpdatingElement=_exports.notEqual$1=_exports.notEqual=_exports.defaultConverter$1=_exports.defaultConverter=_exports.eventOptions$1=_exports.eventOptions=_exports.queryAll$1=_exports.queryAll=_exports.query$1=_exports.query=_exports.customElement$1=_exports.customElement=_exports.css$1=_exports.css=_exports.unsafeCSS$1=_exports.unsafeCSS=_exports.CSSResult$1=_exports.CSSResult=_exports.supportsAdoptingStyleSheets$1=_exports.supportsAdoptingStyleSheets=_exports.$misc=_exports.$xPostpress$1=_exports.$articles=_exports.$article=_exports.$xPostpress=_exports.$litHtml=_exports.$template=_exports.$templateResult=_exports.$templateInstance=_exports.$templateFactory=_exports.$shadyRender=_exports.$render=_exports.$parts=_exports.$part=_exports.$modifyTemplate=_exports.$dom=_exports.$directive=_exports.$defaultTemplateProcessor=_exports.$unsafeHtml=_exports.$litElement=_exports.$updatingElement=_exports.$decorators=_exports.$cssTag=void 0;_exports.getPostsUrl=_exports.getPosts=_exports.removeSubdomain=_exports.formatDate=_exports.buildQueryString=_exports.$xPostpressDefault$1=_exports.$articlesDefault=_exports.loading=_exports.getErrorMessageArticle=_exports.$articleDefault=_exports.$xPostpressDefault=_exports.lastAttributeNameRegex=_exports.createMarker$1=_exports.createMarker=_exports.isTemplatePartActive$1=_exports.isTemplatePartActive=_exports.Template$1=_exports.Template=_exports.boundAttributeSuffix=_exports.markerRegex=_exports.nodeMarker=_exports.marker=_exports.TemplateInstance$1=_exports.TemplateInstance=void 0;function _templateObject3_6576bdb0dcb611e9a23fc186ac4bedc0(){var data=babelHelpers.taggedTemplateLiteral(["\n <slot name=\"articles\"></slot>\n ","\n "]);_templateObject3_6576bdb0dcb611e9a23fc186ac4bedc0=function _templateObject3_6576bdb0dcb611e9a23fc186ac4bedc0(){return data};return data}function _templateObject2_6576bdb0dcb611e9a23fc186ac4bedc0(){var data=babelHelpers.taggedTemplateLiteral(["\n a,\n a:link,\n a:visited {\n color: var(--a-color, #000);\n text-decoration: var(--a-text-decoration, none);\n }\n\n a:hover {\n text-decoration: var(--a-hover-text-decoration, underline);\n }\n\n article {\n clear: var(--article-clear, inherit);\n margin-bottom: var(--article-margin-bottom, 1rem);\n margin-left: var(--article-margin-left, auto);\n margin-right: var(--article-margin-right, auto);\n margin-top: var(--article-margin-top, 0);\n width: var(--article-width, 80%);\n }\n\n h1 {\n font-size: var(--h1-font-size, inherit);\n }\n\n h2 {\n color: var(--h2-color, #333);\n font-size: var(--h2-font-size, smaller);\n }\n\n hr {\n clear: var(--hr-clear, both);\n display: var(--hr-display, block);\n }\n\n img {\n display: var(--img-display, inherit);\n float: var(--img-float, inherit);\n height: var(--img-height, auto);\n max-height: var(--img-max-height, inherit);\n max-width: var(--img-max-width, 100%);\n padding-bottom: var(--img-padding-bottom, inherit);\n padding-left: var(--img-padding-left, inherit);\n padding-right: var(--img-padding-right, inherit);\n padding-top: var(--img-padding-top, inherit);\n width: var(--img-width, auto);\n }\n\n ul {\n list-style-type: var(--ul-list-style-type, inherit);\n }\n\n p {\n clear: var(--p-clear, inherit);\n text-align: var(--p-text-align, inherit);\n }\n\n pre {\n overflow: auto;\n }\n"]);_templateObject2_6576bdb0dcb611e9a23fc186ac4bedc0=function _templateObject2_6576bdb0dcb611e9a23fc186ac4bedc0(){return data};return data}function _templateObject_6576bdb0dcb611e9a23fc186ac4bedc0(){var data=babelHelpers.taggedTemplateLiteral(["\n <article>\n <h1>","</h1>\n <h2>","</h2>\n <p>","</p>\n <hr />\n </article>\n"]);_templateObject_6576bdb0dcb611e9a23fc186ac4bedc0=function _templateObject_6576bdb0dcb611e9a23fc186ac4bedc0(){return data};return data}var supportsAdoptingStyleSheets="adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype;_exports.supportsAdoptingStyleSheets$1=_exports.supportsAdoptingStyleSheets=supportsAdoptingStyleSheets;var constructionToken=Symbol(),CSSResult=function(){function CSSResult(cssText,safeToken){babelHelpers.classCallCheck(this,CSSResult);if(safeToken!==constructionToken){throw new Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.")}this.cssText=cssText}babelHelpers.createClass(CSSResult,[{key:"toString",value:function toString(){return this.cssText}},{key:"styleSheet",get:function get(){if(this._styleSheet===void 0){if(supportsAdoptingStyleSheets){this._styleSheet=new CSSStyleSheet;this._styleSheet.replaceSync(this.cssText)}else{this._styleSheet=null}}return this._styleSheet}}]);return CSSResult}();_exports.CSSResult$1=_exports.CSSResult=CSSResult;var unsafeCSS=function unsafeCSS(value){return new CSSResult(value+"",constructionToken)};_exports.unsafeCSS$1=_exports.unsafeCSS=unsafeCSS;var textFromCSSResult=function textFromCSSResult(value){if(babelHelpers.instanceof(value,CSSResult)){return value.cssText}else{throw new Error("Value passed to 'css' function must be a 'css' function result: ".concat(value,". Use 'unsafeCSS' to pass non-literal values, but\n take care to ensure page security."))}},css=function css(strings){for(var _len=arguments.length,values=Array(1<_len?_len-1:0),_key=1;_key<_len;_key++){values[_key-1]=arguments[_key]}var cssText=values.reduce(function(acc,v,idx){return acc+textFromCSSResult(v)+strings[idx+1]},strings[0]);return new CSSResult(cssText,constructionToken)};_exports.css$1=_exports.css=css;var cssTag={supportsAdoptingStyleSheets:supportsAdoptingStyleSheets,CSSResult:CSSResult,unsafeCSS:unsafeCSS,css:css};_exports.$cssTag=cssTag;var legacyCustomElement=function legacyCustomElement(tagName,clazz){window.customElements.define(tagName,clazz);return clazz},standardCustomElement=function standardCustomElement(tagName,descriptor){var kind=descriptor.kind,elements=descriptor.elements;return{kind:kind,elements:elements,finisher:function finisher(clazz){window.customElements.define(tagName,clazz)}}},customElement=function customElement(tagName){return function(classOrDescriptor){return"function"===typeof classOrDescriptor?legacyCustomElement(tagName,classOrDescriptor):standardCustomElement(tagName,classOrDescriptor)}};_exports.customElement$1=_exports.customElement=customElement;var standardProperty=function standardProperty(options,element){if("method"===element.kind&&element.descriptor&&!("value"in element.descriptor)){return Object.assign({},element,{finisher:function finisher(clazz){clazz.createProperty(element.key,options)}})}else{return{kind:"field",key:Symbol(),placement:"own",descriptor:{},initializer:function initializer(){if("function"===typeof element.initializer){this[element.key]=element.initializer.call(this)}},finisher:function finisher(clazz){clazz.createProperty(element.key,options)}}}},legacyProperty=function legacyProperty(options,proto,name){proto.constructor.createProperty(name,options)};function property(options){return function(protoOrDescriptor,name){return name!==void 0?legacyProperty(options,protoOrDescriptor,name):standardProperty(options,protoOrDescriptor)}}var query=_query(function(target,selector){return target.querySelector(selector)});_exports.query$1=_exports.query=query;var queryAll=_query(function(target,selector){return target.querySelectorAll(selector)});_exports.queryAll$1=_exports.queryAll=queryAll;var legacyQuery=function legacyQuery(descriptor,proto,name){Object.defineProperty(proto,name,descriptor)},standardQuery=function standardQuery(descriptor,element){return{kind:"method",placement:"prototype",key:element.key,descriptor:descriptor}};function _query(queryFn){return function(selector){return function(protoOrDescriptor,name){var descriptor={get:function get(){return queryFn(this.renderRoot,selector)},enumerable:!0,configurable:!0};return name!==void 0?legacyQuery(descriptor,protoOrDescriptor,name):standardQuery(descriptor,protoOrDescriptor)}}}var standardEventOptions=function standardEventOptions(options,element){return Object.assign({},element,{finisher:function finisher(clazz){Object.assign(clazz.prototype[element.key],options)}})},legacyEventOptions=function legacyEventOptions(options,proto,name){Object.assign(proto[name],options)},eventOptions=function eventOptions(options){return function(protoOrDescriptor,name){return name!==void 0?legacyEventOptions(options,protoOrDescriptor,name):standardEventOptions(options,protoOrDescriptor)}};_exports.eventOptions$1=_exports.eventOptions=eventOptions;var decorators={customElement:customElement,property:property,query:query,queryAll:queryAll,eventOptions:eventOptions};_exports.$decorators=decorators;window.JSCompiler_renameProperty=function(prop,_obj){return prop};var defaultConverter={toAttribute:function toAttribute(value,type){switch(type){case Boolean:return value?"":null;case Object:case Array:return null==value?value:JSON.stringify(value);}return value},fromAttribute:function fromAttribute(value,type){switch(type){case Boolean:return null!==value;case Number:return null===value?null:+value;case Object:case Array:return JSON.parse(value);}return value}};_exports.defaultConverter$1=_exports.defaultConverter=defaultConverter;var notEqual=function notEqual(value,old){return old!==value&&(old===old||value===value)};_exports.notEqual$1=_exports.notEqual=notEqual;var defaultPropertyDeclaration={attribute:!0,type:String,converter:defaultConverter,reflect:!1,hasChanged:notEqual},microtaskPromise=Promise.resolve(!0),STATE_HAS_UPDATED=1,STATE_UPDATE_REQUESTED=1<<2,STATE_IS_REFLECTING_TO_ATTRIBUTE=1<<3,STATE_IS_REFLECTING_TO_PROPERTY=1<<4,STATE_HAS_CONNECTED=1<<5,UpdatingElement=function(_HTMLElement){babelHelpers.inherits(UpdatingElement,_HTMLElement);function UpdatingElement(){var _this;babelHelpers.classCallCheck(this,UpdatingElement);_this=babelHelpers.possibleConstructorReturn(this,babelHelpers.getPrototypeOf(UpdatingElement).call(this));_this._updateState=0;_this._instanceProperties=void 0;_this._updatePromise=microtaskPromise;_this._hasConnectedResolver=void 0;_this._changedProperties=new Map;_this._reflectingProperties=void 0;_this.initialize();return _this}babelHelpers.createClass(UpdatingElement,[{key:"initialize",value:function initialize(){this._saveInstanceProperties()}},{key:"_saveInstanceProperties",value:function _saveInstanceProperties(){var _this2=this;this.constructor._classProperties.forEach(function(_v,p){if(_this2.hasOwnProperty(p)){var value=_this2[p];delete _this2[p];if(!_this2._instanceProperties){_this2._instanceProperties=new Map}_this2._instanceProperties.set(p,value)}})}},{key:"_applyInstanceProperties",value:function _applyInstanceProperties(){var _this3=this;this._instanceProperties.forEach(function(v,p){return _this3[p]=v});this._instanceProperties=void 0}},{key:"connectedCallback",value:function connectedCallback(){this._updateState=this._updateState|STATE_HAS_CONNECTED;if(this._hasConnectedResolver){this._hasConnectedResolver();this._hasConnectedResolver=void 0}else{this.requestUpdate()}}},{key:"disconnectedCallback",value:function disconnectedCallback(){}},{key:"attributeChangedCallback",value:function attributeChangedCallback(name,old,value){if(old!==value){this._attributeToProperty(name,value)}}},{key:"_propertyToAttribute",value:function _propertyToAttribute(name,value){var options=2<arguments.length&&arguments[2]!==void 0?arguments[2]:defaultPropertyDeclaration,ctor=this.constructor,attr=ctor._attributeNameForProperty(name,options);if(attr!==void 0){var attrValue=ctor._propertyValueToAttribute(value,options);if(attrValue===void 0){return}this._updateState=this._updateState|STATE_IS_REFLECTING_TO_ATTRIBUTE;if(null==attrValue){this.removeAttribute(attr)}else{this.setAttribute(attr,attrValue)}this._updateState=this._updateState&~STATE_IS_REFLECTING_TO_ATTRIBUTE}}},{key:"_attributeToProperty",value:function _attributeToProperty(name,value){if(this._updateState&STATE_IS_REFLECTING_TO_ATTRIBUTE){return}var ctor=this.constructor,propName=ctor._attributeToPropertyMap.get(name);if(propName!==void 0){var options=ctor._classProperties.get(propName)||defaultPropertyDeclaration;this._updateState=this._updateState|STATE_IS_REFLECTING_TO_PROPERTY;this[propName]=ctor._propertyValueFromAttribute(value,options);this._updateState=this._updateState&~STATE_IS_REFLECTING_TO_PROPERTY}}},{key:"requestUpdate",value:function requestUpdate(name,oldValue){var shouldRequestUpdate=!0;if(name!==void 0&&!this._changedProperties.has(name)){var ctor=this.constructor,options=ctor._classProperties.get(name)||defaultPropertyDeclaration;if(ctor._valueHasChanged(this[name],oldValue,options.hasChanged)){this._changedProperties.set(name,oldValue);if(!0===options.reflect&&!(this._updateState&STATE_IS_REFLECTING_TO_PROPERTY)){if(this._reflectingProperties===void 0){this._reflectingProperties=new Map}this._reflectingProperties.set(name,options)}}else{shouldRequestUpdate=!1}}if(!this._hasRequestedUpdate&&shouldRequestUpdate){this._enqueueUpdate()}return this.updateComplete}},{key:"_enqueueUpdate",value:function(){var _enqueueUpdate2=babelHelpers.asyncToGenerator(regeneratorRuntime.mark(function _callee(){var _this4=this,resolve,previousUpdatePromise,result;return regeneratorRuntime.wrap(function _callee$(_context){while(1){switch(_context.prev=_context.next){case 0:this._updateState=this._updateState|STATE_UPDATE_REQUESTED;previousUpdatePromise=this._updatePromise;this._updatePromise=new Promise(function(res){return resolve=res});_context.next=5;return previousUpdatePromise;case 5:if(this._hasConnected){_context.next=8;break}_context.next=8;return new Promise(function(res){return _this4._hasConnectedResolver=res});case 8:result=this.performUpdate();if(!(null!=result&&"function"===typeof result.then)){_context.next=12;break}_context.next=12;return result;case 12:resolve(!this._hasRequestedUpdate);case 13:case"end":return _context.stop();}}},_callee,this)}));function _enqueueUpdate(){return _enqueueUpdate2.apply(this,arguments)}return _enqueueUpdate}()},{key:"performUpdate",value:function performUpdate(){if(this._instanceProperties){this._applyInstanceProperties()}if(this.shouldUpdate(this._changedProperties)){var changedProperties=this._changedProperties;this.update(changedProperties);this._markUpdated();if(!(this._updateState&STATE_HAS_UPDATED)){this._updateState=this._updateState|STATE_HAS_UPDATED;this.firstUpdated(changedProperties)}this.updated(changedProperties)}else{this._markUpdated()}}},{key:"_markUpdated",value:function _markUpdated(){this._changedProperties=new Map;this._updateState=this._updateState&~STATE_UPDATE_REQUESTED}},{key:"shouldUpdate",value:function shouldUpdate(_changedProperties){return!0}},{key:"update",value:function update(_changedProperties){var _this5=this;if(this._reflectingProperties!==void 0&&0<this._reflectingProperties.size){this._reflectingProperties.forEach(function(v,k){return _this5._propertyToAttribute(k,_this5[k],v)});this._reflectingProperties=void 0}}},{key:"updated",value:function updated(_changedProperties){}},{key:"firstUpdated",value:function firstUpdated(_changedProperties){}},{key:"_hasConnected",get:function get(){return this._updateState&STATE_HAS_CONNECTED}},{key:"_hasRequestedUpdate",get:function get(){return this._updateState&STATE_UPDATE_REQUESTED}},{key:"hasUpdated",get:function get(){return this._updateState&STATE_HAS_UPDATED}},{key:"updateComplete",get:function get(){return this._updatePromise}}],[{key:"_ensureClassProperties",value:function _ensureClassProperties(){var _this6=this;if(!this.hasOwnProperty(JSCompiler_renameProperty("_classProperties",this))){this._classProperties=new Map;var superProperties=Object.getPrototypeOf(this)._classProperties;if(superProperties!==void 0){superProperties.forEach(function(v,k){return _this6._classProperties.set(k,v)})}}}},{key:"createProperty",value:function createProperty(name){var options=1<arguments.length&&arguments[1]!==void 0?arguments[1]:defaultPropertyDeclaration;this._ensureClassProperties();this._classProperties.set(name,options);if(options.noAccessor||this.prototype.hasOwnProperty(name)){return}var key="symbol"===babelHelpers.typeof(name)?Symbol():"__".concat(name);Object.defineProperty(this.prototype,name,{get:function get(){return this[key]},set:function set(value){var oldValue=this[name];this[key]=value;this.requestUpdate(name,oldValue)},configurable:!0,enumerable:!0})}},{key:"finalize",value:function finalize(){if(this.hasOwnProperty(JSCompiler_renameProperty("finalized",this))&&this.finalized){return}var superCtor=Object.getPrototypeOf(this);if("function"===typeof superCtor.finalize){superCtor.finalize()}this.finalized=!0;this._ensureClassProperties();this._attributeToPropertyMap=new Map;if(this.hasOwnProperty(JSCompiler_renameProperty("properties",this))){var props=this.properties,propKeys=[].concat(babelHelpers.toConsumableArray(Object.getOwnPropertyNames(props)),babelHelpers.toConsumableArray("function"===typeof Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(props):[])),_iteratorNormalCompletion=!0,_didIteratorError=!1,_iteratorError=void 0;try{for(var _iterator=propKeys[Symbol.iterator](),_step,p;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=!0){p=_step.value;this.createProperty(p,props[p])}}catch(err){_didIteratorError=!0;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&null!=_iterator.return){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}}}},{key:"_attributeNameForProperty",value:function _attributeNameForProperty(name,options){var attribute=options.attribute;return!1===attribute?void 0:"string"===typeof attribute?attribute:"string"===typeof name?name.toLowerCase():void 0}},{key:"_valueHasChanged",value:function _valueHasChanged(value,old){var hasChanged=2<arguments.length&&arguments[2]!==void 0?arguments[2]:notEqual;return hasChanged(value,old)}},{key:"_propertyValueFromAttribute",value:function _propertyValueFromAttribute(value,options){var type=options.type,converter=options.converter||defaultConverter,fromAttribute="function"===typeof converter?converter:converter.fromAttribute;return fromAttribute?fromAttribute(value,type):value}},{key:"_propertyValueToAttribute",value:function _propertyValueToAttribute(value,options){if(options.reflect===void 0){return}var type=options.type,converter=options.converter,toAttribute=converter&&converter.toAttribute||defaultConverter.toAttribute;return toAttribute(value,type)}},{key:"observedAttributes",get:function get(){var _this7=this;this.finalize();var attributes=[];this._classProperties.forEach(function(v,p){var attr=_this7._attributeNameForProperty(p,v);if(attr!==void 0){_this7._attributeToPropertyMap.set(attr,p);attributes.push(attr)}});return attributes}}]);return UpdatingElement}(babelHelpers.wrapNativeSuper(HTMLElement));_exports.UpdatingElement$1=_exports.UpdatingElement=UpdatingElement;UpdatingElement.finalized=!0;var updatingElement={defaultConverter:defaultConverter,notEqual:notEqual,UpdatingElement:UpdatingElement};_exports.$updatingElement=updatingElement;var directives=new WeakMap,directive=function directive(f){return function(){var d=f.apply(void 0,arguments);directives.set(d,!0);return d}};_exports.directive$1=_exports.directive=directive;var isDirective=function isDirective(o){return"function"===typeof o&&directives.has(o)};_exports.isDirective$1=_exports.isDirective=isDirective;var directive$1={directive:directive,isDirective:isDirective};_exports.$directive=directive$1;var isCEPolyfill=window.customElements!==void 0&&window.customElements.polyfillWrapFlushCallback!==void 0;_exports.isCEPolyfill=isCEPolyfill;var reparentNodes=function reparentNodes(container,start){var end=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null,before=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null,node=start;while(node!==end){var n=node.nextSibling;container.insertBefore(node,before);node=n}};_exports.reparentNodes$1=_exports.reparentNodes=reparentNodes;var removeNodes=function removeNodes(container,startNode){var endNode=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null,node=startNode;while(node!==endNode){var n=node.nextSibling;container.removeChild(node);node=n}};_exports.removeNodes$1=_exports.removeNodes=removeNodes;var dom={isCEPolyfill:isCEPolyfill,reparentNodes:reparentNodes,removeNodes:removeNodes};_exports.$dom=dom;var noChange={};_exports.noChange$1=_exports.noChange=noChange;var nothing={};_exports.nothing$1=_exports.nothing=nothing;var part={noChange:noChange,nothing:nothing};_exports.$part=part;var marker="{{lit-".concat((Math.random()+"").slice(2),"}}");_exports.marker=marker;var nodeMarker="<!--".concat(marker,"-->");_exports.nodeMarker=nodeMarker;var markerRegex=new RegExp("".concat(marker,"|").concat(nodeMarker));_exports.markerRegex=markerRegex;var boundAttributeSuffix="$lit$";_exports.boundAttributeSuffix=boundAttributeSuffix;var Template=function Template(result,element){var _this8=this;babelHelpers.classCallCheck(this,Template);this.parts=[];this.element=element;var index=-1,partIndex=0,nodesToRemove=[],_prepareTemplate=function _prepareTemplate(template){var content=template.content,walker=document.createTreeWalker(content,133,null,!1),lastPartIndex=0;while(walker.nextNode()){index++;var node=walker.currentNode;if(1===node.nodeType){if(node.hasAttributes()){for(var attributes=node.attributes,count=0,i=0;i<attributes.length;i++){if(0<=attributes[i].value.indexOf(marker)){count++}}while(0<count--){var stringForPart=result.strings[partIndex],name=lastAttributeNameRegex.exec(stringForPart)[2],attributeLookupName=name.toLowerCase()+boundAttributeSuffix,attributeValue=node.getAttribute(attributeLookupName),strings=attributeValue.split(markerRegex);_this8.parts.push({type:"attribute",index:index,name:name,strings:strings});node.removeAttribute(attributeLookupName);partIndex+=strings.length-1}}if("TEMPLATE"===node.tagName){_prepareTemplate(node)}}else if(3===node.nodeType){var data=node.data;if(0<=data.indexOf(marker)){for(var parent=node.parentNode,_strings=data.split(markerRegex),lastIndex=_strings.length-1,_i=0;_i<lastIndex;_i++){parent.insertBefore(""===_strings[_i]?createMarker():document.createTextNode(_strings[_i]),node);_this8.parts.push({type:"node",index:++index})}if(""===_strings[lastIndex]){parent.insertBefore(createMarker(),node);nodesToRemove.push(node)}else{node.data=_strings[lastIndex]}partIndex+=lastIndex}}else if(8===node.nodeType){if(node.data===marker){var _parent=node.parentNode;if(null===node.previousSibling||index===lastPartIndex){index++;_parent.insertBefore(createMarker(),node)}lastPartIndex=index;_this8.parts.push({type:"node",index:index});if(null===node.nextSibling){node.data=""}else{nodesToRemove.push(node);index--}partIndex++}else{var _i2=-1;while(-1!==(_i2=node.data.indexOf(marker,_i2+1))){_this8.parts.push({type:"node",index:-1})}}}}};_prepareTemplate(element);for(var _i3=0,n;_i3<nodesToRemove.length;_i3++){n=nodesToRemove[_i3];n.parentNode.removeChild(n)}};_exports.Template$1=_exports.Template=Template;var isTemplatePartActive=function isTemplatePartActive(part){return-1!==part.index};_exports.isTemplatePartActive$1=_exports.isTemplatePartActive=isTemplatePartActive;var createMarker=function createMarker(){return document.createComment("")};_exports.createMarker$1=_exports.createMarker=createMarker;var lastAttributeNameRegex=/([ \x09\x0a\x0c\x0d])([^\0-\x1F\x7F-\x9F \x09\x0a\x0c\x0d"'>=/]+)([ \x09\x0a\x0c\x0d]*=[ \x09\x0a\x0c\x0d]*(?:[^ \x09\x0a\x0c\x0d"'`<>=]*|"[^"]*|'[^']*))$/;_exports.lastAttributeNameRegex=lastAttributeNameRegex;var template={marker:marker,nodeMarker:nodeMarker,markerRegex:markerRegex,boundAttributeSuffix:boundAttributeSuffix,Template:Template,isTemplatePartActive:isTemplatePartActive,createMarker:createMarker,lastAttributeNameRegex:lastAttributeNameRegex};_exports.$template=template;var TemplateInstance=function(){function TemplateInstance(template,processor,options){babelHelpers.classCallCheck(this,TemplateInstance);this._parts=[];this.template=template;this.processor=processor;this.options=options}babelHelpers.createClass(TemplateInstance,[{key:"update",value:function update(values){var i=0,_iteratorNormalCompletion2=!0,_didIteratorError2=!1,_iteratorError2=void 0;try{for(var _iterator2=this._parts[Symbol.iterator](),_step2,_part;!(_iteratorNormalCompletion2=(_step2=_iterator2.next()).done);_iteratorNormalCompletion2=!0){_part=_step2.value;if(_part!==void 0){_part.setValue(values[i])}i++}}catch(err){_didIteratorError2=!0;_iteratorError2=err}finally{try{if(!_iteratorNormalCompletion2&&null!=_iterator2.return){_iterator2.return()}}finally{if(_didIteratorError2){throw _iteratorError2}}}var _iteratorNormalCompletion3=!0,_didIteratorError3=!1,_iteratorError3=void 0;try{for(var _iterator3=this._parts[Symbol.iterator](),_step3,_part2;!(_iteratorNormalCompletion3=(_step3=_iterator3.next()).done);_iteratorNormalCompletion3=!0){_part2=_step3.value;if(_part2!==void 0){_part2.commit()}}}catch(err){_didIteratorError3=!0;_iteratorError3=err}finally{try{if(!_iteratorNormalCompletion3&&null!=_iterator3.return){_iterator3.return()}}finally{if(_didIteratorError3){throw _iteratorError3}}}}},{key:"_clone",value:function _clone(){var _this9=this,fragment=isCEPolyfill?this.template.element.content.cloneNode(!0):document.importNode(this.template.element.content,!0),parts=this.template.parts,partIndex=0,nodeIndex=0,_prepareInstance=function _prepareInstance(fragment){var walker=document.createTreeWalker(fragment,133,null,!1),node=walker.nextNode();while(partIndex<parts.length&&null!==node){var _part3=parts[partIndex];if(!isTemplatePartActive(_part3)){_this9._parts.push(void 0);partIndex++}else if(nodeIndex===_part3.index){if("node"===_part3.type){var _part4=_this9.processor.handleTextExpression(_this9.options);_part4.insertAfterNode(node.previousSibling);_this9._parts.push(_part4)}else{var _this9$_parts;(_this9$_parts=_this9._parts).push.apply(_this9$_parts,babelHelpers.toConsumableArray(_this9.processor.handleAttributeExpressions(node,_part3.name,_part3.strings,_this9.options)))}partIndex++}else{nodeIndex++;if("TEMPLATE"===node.nodeName){_prepareInstance(node.content)}node=walker.nextNode()}}};_prepareInstance(fragment);if(isCEPolyfill){document.adoptNode(fragment);customElements.upgrade(fragment)}return fragment}}]);return TemplateInstance}();_exports.TemplateInstance$1=_exports.TemplateInstance=TemplateInstance;var templateInstance={TemplateInstance:TemplateInstance};_exports.$templateInstance=templateInstance;var TemplateResult=function(){function TemplateResult(strings,values,type,processor){babelHelpers.classCallCheck(this,TemplateResult);this.strings=strings;this.values=values;this.type=type;this.processor=processor}babelHelpers.createClass(TemplateResult,[{key:"getHTML",value:function getHTML(){for(var endIndex=this.strings.length-1,html="",i=0;i<endIndex;i++){var s=this.strings[i],match=lastAttributeNameRegex.exec(s);if(match){html+=s.substr(0,match.index)+match[1]+match[2]+boundAttributeSuffix+match[3]+marker}else{html+=s+nodeMarker}}return html+this.strings[endIndex]}},{key:"getTemplateElement",value:function getTemplateElement(){var template=document.createElement("template");template.innerHTML=this.getHTML();return template}}]);return TemplateResult}();_exports.TemplateResult$3=_exports.TemplateResult$2=_exports.TemplateResult$1=_exports.TemplateResult=TemplateResult;var SVGTemplateResult=function(_TemplateResult){babelHelpers.inherits(SVGTemplateResult,_TemplateResult);function SVGTemplateResult(){babelHelpers.classCallCheck(this,SVGTemplateResult);return babelHelpers.possibleConstructorReturn(this,babelHelpers.getPrototypeOf(SVGTemplateResult).apply(this,arguments))}babelHelpers.createClass(SVGTemplateResult,[{key:"getHTML",value:function getHTML(){return"<svg>".concat(babelHelpers.get(babelHelpers.getPrototypeOf(SVGTemplateResult.prototype),"getHTML",this).call(this),"</svg>")}},{key:"getTemplateElement",value:function getTemplateElement(){var template=babelHelpers.get(babelHelpers.getPrototypeOf(SVGTemplateResult.prototype),"getTemplateElement",this).call(this),content=template.content,svgElement=content.firstChild;content.removeChild(svgElement);reparentNodes(content,svgElement.firstChild);return template}}]);return SVGTemplateResult}(TemplateResult);_exports.SVGTemplateResult$2=_exports.SVGTemplateResult$1=_exports.SVGTemplateResult=SVGTemplateResult;var templateResult={TemplateResult:TemplateResult,SVGTemplateResult:SVGTemplateResult};_exports.$templateResult=templateResult;var isPrimitive=function isPrimitive(value){return null===value||!("object"===babelHelpers.typeof(value)||"function"===typeof value)};_exports.isPrimitive$1=_exports.isPrimitive=isPrimitive;var AttributeCommitter=function(){function AttributeCommitter(element,name,strings){babelHelpers.classCallCheck(this,AttributeCommitter);this.dirty=!0;this.element=element;this.name=name;this.strings=strings;this.parts=[];for(var i=0;i<strings.length-1;i++){this.parts[i]=this._createPart()}}babelHelpers.createClass(AttributeCommitter,[{key:"_createPart",value:function _createPart(){return new AttributePart(this)}},{key:"_getValue",value:function _getValue(){for(var strings=this.strings,l=strings.length-1,text="",i=0;i<l;i++){text+=strings[i];var _part5=this.parts[i];if(_part5!==void 0){var v=_part5.value;if(null!=v&&(Array.isArray(v)||"string"!==typeof v&&v[Symbol.iterator])){var _iteratorNormalCompletion4=!0,_didIteratorError4=!1,_iteratorError4=void 0;try{for(var _iterator4=v[Symbol.iterator](),_step4,t;!(_iteratorNormalCompletion4=(_step4=_iterator4.next()).done);_iteratorNormalCompletion4=!0){t=_step4.value;text+="string"===typeof t?t:t+""}}catch(err){_didIteratorError4=!0;_iteratorError4=err}finally{try{if(!_iteratorNormalCompletion4&&null!=_iterator4.return){_iterator4.return()}}finally{if(_didIteratorError4){throw _iteratorError4}}}}else{text+="string"===typeof v?v:v+""}}}text+=strings[l];return text}},{key:"commit",value:function commit(){if(this.dirty){this.dirty=!1;this.element.setAttribute(this.name,this._getValue())}}}]);return AttributeCommitter}();_exports.AttributeCommitter$1=_exports.AttributeCommitter=AttributeCommitter;var AttributePart=function(){function AttributePart(comitter){babelHelpers.classCallCheck(this,AttributePart);this.value=void 0;this.committer=comitter}babelHelpers.createClass(AttributePart,[{key:"setValue",value:function setValue(value){if(value!==noChange&&(!isPrimitive(value)||value!==this.value)){this.value=value;if(!isDirective(value)){this.committer.dirty=!0}}}},{key:"commit",value:function commit(){while(isDirective(this.value)){var directive$$1=this.value;this.value=noChange;directive$$1(this)}if(this.value===noChange){return}this.committer.commit()}}]);return AttributePart}();_exports.AttributePart$1=_exports.AttributePart=AttributePart;var NodePart=function(){function NodePart(options){babelHelpers.classCallCheck(this,NodePart);this.value=void 0;this._pendingValue=void 0;this.options=options}babelHelpers.createClass(NodePart,[{key:"appendInto",value:function appendInto(container){this.startNode=container.appendChild(createMarker());this.endNode=container.appendChild(createMarker())}},{key:"insertAfterNode",value:function insertAfterNode(ref){this.startNode=ref;this.endNode=ref.nextSibling}},{key:"appendIntoPart",value:function appendIntoPart(part){part._insert(this.startNode=createMarker());part._insert(this.endNode=createMarker())}},{key:"insertAfterPart",value:function insertAfterPart(ref){ref._insert(this.startNode=createMarker());this.endNode=ref.endNode;ref.endNode=this.startNode}},{key:"setValue",value:function setValue(value){this._pendingValue=value}},{key:"commit",value:function commit(){while(isDirective(this._pendingValue)){var directive$$1=this._pendingValue;this._pendingValue=noChange;directive$$1(this)}var value=this._pendingValue;if(value===noChange){return}if(isPrimitive(value)){if(value!==this.value){this._commitText(value)}}else if(babelHelpers.instanceof(value,TemplateResult)){this._commitTemplateResult(value)}else if(babelHelpers.instanceof(value,Node)){this._commitNode(value)}else if(Array.isArray(value)||value[Symbol.iterator]){this._commitIterable(value)}else if(value===nothing){this.value=nothing;this.clear()}else{this._commitText(value)}}},{key:"_insert",value:function _insert(node){this.endNode.parentNode.insertBefore(node,this.endNode)}},{key:"_commitNode",value:function _commitNode(value){if(this.value===value){return}this.clear();this._insert(value);this.value=value}},{key:"_commitText",value:function _commitText(value){var node=this.startNode.nextSibling;value=null==value?"":value;if(node===this.endNode.previousSibling&&3===node.nodeType){node.data=value}else{this._commitNode(document.createTextNode("string"===typeof value?value:value+""))}this.value=value}},{key:"_commitTemplateResult",value:function _commitTemplateResult(value){var template=this.options.templateFactory(value);if(babelHelpers.instanceof(this.value,TemplateInstance)&&this.value.template===template){this.value.update(value.values)}else{var instance=new TemplateInstance(template,value.processor,this.options),fragment=instance._clone();instance.update(value.values);this._commitNode(fragment);this.value=instance}}},{key:"_commitIterable",value:function _commitIterable(value){if(!Array.isArray(this.value)){this.value=[];this.clear()}var itemParts=this.value,partIndex=0,itemPart,_iteratorNormalCompletion5=!0,_didIteratorError5=!1,_iteratorError5=void 0;try{for(var _iterator5=value[Symbol.iterator](),_step5,item;!(_iteratorNormalCompletion5=(_step5=_iterator5.next()).done);_iteratorNormalCompletion5=!0){item=_step5.value;itemPart=itemParts[partIndex];if(itemPart===void 0){itemPart=new NodePart(this.options);itemParts.push(itemPart);if(0===partIndex){itemPart.appendIntoPart(this)}else{itemPart.insertAfterPart(itemParts[partIndex-1])}}itemPart.setValue(item);itemPart.commit();partIndex++}}catch(err){_didIteratorError5=!0;_iteratorError5=err}finally{try{if(!_iteratorNormalCompletion5&&null!=_iterator5.return){_iterator5.return()}}finally{if(_didIteratorError5){throw _iteratorError5}}}if(partIndex<itemParts.length){itemParts.length=partIndex;this.clear(itemPart&&itemPart.endNode)}}},{key:"clear",value:function clear(){var startNode=0<arguments.length&&arguments[0]!==void 0?arguments[0]:this.startNode;removeNodes(this.startNode.parentNode,startNode.nextSibling,this.endNode)}}]);return NodePart}();_exports.NodePart$1=_exports.NodePart=NodePart;var BooleanAttributePart=function(){function BooleanAttributePart(element,name,strings){babelHelpers.classCallCheck(this,BooleanAttributePart);this.value=void 0;this._pendingValue=void 0;if(2!==strings.length||""!==strings[0]||""!==strings[1]){throw new Error("Boolean attributes can only contain a single expression")}this.element=element;this.name=name;this.strings=strings}babelHelpers.createClass(BooleanAttributePart,[{key:"setValue",value:function setValue(value){this._pendingValue=value}},{key:"commit",value:function commit(){while(isDirective(this._pendingValue)){var directive$$1=this._pendingValue;this._pendingValue=noChange;directive$$1(this)}if(this._pendingValue===noChange){return}var value=!!this._pendingValue;if(this.value!==value){if(value){this.element.setAttribute(this.name,"")}else{this.element.removeAttribute(this.name)}}this.value=value;this._pendingValue=noChange}}]);return BooleanAttributePart}();_exports.BooleanAttributePart$1=_exports.BooleanAttributePart=BooleanAttributePart;var PropertyCommitter=function(_AttributeCommitter){babelHelpers.inherits(PropertyCommitter,_AttributeCommitter);function PropertyCommitter(element,name,strings){var _this10;babelHelpers.classCallCheck(this,PropertyCommitter);_this10=babelHelpers.possibleConstructorReturn(this,babelHelpers.getPrototypeOf(PropertyCommitter).call(this,element,name,strings));_this10.single=2===strings.length&&""===strings[0]&&""===strings[1];return _this10}babelHelpers.createClass(PropertyCommitter,[{key:"_createPart",value:function _createPart(){return new PropertyPart(this)}},{key:"_getValue",value:function _getValue(){if(this.single){return this.parts[0].value}return babelHelpers.get(babelHelpers.getPrototypeOf(PropertyCommitter.prototype),"_getValue",this).call(this)}},{key:"commit",value:function commit(){if(this.dirty){this.dirty=!1;this.element[this.name]=this._getValue()}}}]);return PropertyCommitter}(AttributeCommitter);_exports.PropertyCommitter$1=_exports.PropertyCommitter=PropertyCommitter;var PropertyPart=function(_AttributePart){babelHelpers.inherits(PropertyPart,_AttributePart);function PropertyPart(){babelHelpers.classCallCheck(this,PropertyPart);return babelHelpers.possibleConstructorReturn(this,babelHelpers.getPrototypeOf(PropertyPart).apply(this,arguments))}return PropertyPart}(AttributePart);_exports.PropertyPart$1=_exports.PropertyPart=PropertyPart;var eventOptionsSupported=!1;try{var options={get capture(){eventOptionsSupported=!0;return!1}};window.addEventListener("test",options,options);window.removeEventListener("test",options,options)}catch(_e){}var EventPart=function(){function EventPart(element,eventName,eventContext){var _this11=this;babelHelpers.classCallCheck(this,EventPart);this.value=void 0;this._pendingValue=void 0;this.element=element;this.eventName=eventName;this.eventContext=eventContext;this._boundHandleEvent=function(e){return _this11.handleEvent(e)}}babelHelpers.createClass(EventPart,[{key:"setValue",value:function setValue(value){this._pendingValue=value}},{key:"commit",value:function commit(){while(isDirective(this._pendingValue)){var directive$$1=this._pendingValue;this._pendingValue=noChange;directive$$1(this)}if(this._pendingValue===noChange){return}var newListener=this._pendingValue,oldListener=this.value,shouldRemoveListener=null==newListener||null!=oldListener&&(newListener.capture!==oldListener.capture||newListener.once!==oldListener.once||newListener.passive!==oldListener.passive),shouldAddListener=null!=newListener&&(null==oldListener||shouldRemoveListener);if(shouldRemoveListener){this.element.removeEventListener(this.eventName,this._boundHandleEvent,this._options)}if(shouldAddListener){this._options=getOptions(newListener);this.element.addEventListener(this.eventName,this._boundHandleEvent,this._options)}this.value=newListener;this._pendingValue=noChange}},{key:"handleEvent",value:function handleEvent(event){if("function"===typeof this.value){this.value.call(this.eventContext||this.element,event)}else{this.value.handleEvent(event)}}}]);return EventPart}();_exports.EventPart$1=_exports.EventPart=EventPart;var getOptions=function getOptions(o){return o&&(eventOptionsSupported?{capture:o.capture,passive:o.passive,once:o.once}:o.capture)},parts={isPrimitive:isPrimitive,AttributeCommitter:AttributeCommitter,AttributePart:AttributePart,NodePart:NodePart,BooleanAttributePart:BooleanAttributePart,PropertyCommitter:PropertyCommitter,PropertyPart:PropertyPart,EventPart:EventPart};_exports.$parts=parts;var DefaultTemplateProcessor=function(){function DefaultTemplateProcessor(){babelHelpers.classCallCheck(this,DefaultTemplateProcessor)}babelHelpers.createClass(DefaultTemplateProcessor,[{key:"handleAttributeExpressions",value:function handleAttributeExpressions(element,name,strings,options){var prefix=name[0];if("."===prefix){var _comitter=new PropertyCommitter(element,name.slice(1),strings);return _comitter.parts}if("@"===prefix){return[new EventPart(element,name.slice(1),options.eventContext)]}if("?"===prefix){return[new BooleanAttributePart(element,name.slice(1),strings)]}var comitter=new AttributeCommitter(element,name,strings);return comitter.parts}},{key:"handleTextExpression",value:function handleTextExpression(options){return new NodePart(options)}}]);return DefaultTemplateProcessor}();_exports.DefaultTemplateProcessor$1=_exports.DefaultTemplateProcessor=DefaultTemplateProcessor;var defaultTemplateProcessor=new DefaultTemplateProcessor;_exports.defaultTemplateProcessor$1=_exports.defaultTemplateProcessor=defaultTemplateProcessor;var defaultTemplateProcessor$1={DefaultTemplateProcessor:DefaultTemplateProcessor,defaultTemplateProcessor:defaultTemplateProcessor};_exports.$defaultTemplateProcessor=defaultTemplateProcessor$1;function templateFactory(result){var templateCache=templateCaches.get(result.type);if(templateCache===void 0){templateCache={stringsArray:new WeakMap,keyString:new Map};templateCaches.set(result.type,templateCache)}var template=templateCache.stringsArray.get(result.strings);if(template!==void 0){return template}var key=result.strings.join(marker);template=templateCache.keyString.get(key);if(template===void 0){template=new Template(result,result.getTemplateElement());templateCache.keyString.set(key,template)}templateCache.stringsArray.set(result.strings,template);return template}var templateCaches=new Map;_exports.templateCaches$1=_exports.templateCaches=templateCaches;var templateFactory$1={templateFactory:templateFactory,templateCaches:templateCaches};_exports.$templateFactory=templateFactory$1;var parts$1=new WeakMap;_exports.parts$1=_exports.parts=parts$1;var render=function render(result,container,options){var part=parts$1.get(container);if(part===void 0){removeNodes(container,container.firstChild);parts$1.set(container,part=new NodePart(Object.assign({templateFactory:templateFactory},options)));part.appendInto(container)}part.setValue(result);part.commit()};_exports.render$2=_exports.render=render;var render$1={parts:parts$1,render:render};_exports.$render=render$1;(window.litHtmlVersions||(window.litHtmlVersions=[])).push("1.0.0");var html=function html(strings){for(var _len2=arguments.length,values=Array(1<_len2?_len2-1:0),_key2=1;_key2<_len2;_key2++){values[_key2-1]=arguments[_key2]}return new TemplateResult(strings,values,"html",defaultTemplateProcessor)};_exports.html$2=_exports.html$1=_exports.html=html;var svg=function svg(strings){for(var _len3=arguments.length,values=Array(1<_len3?_len3-1:0),_key3=1;_key3<_len3;_key3++){values[_key3-1]=arguments[_key3]}return new SVGTemplateResult(strings,values,"svg",defaultTemplateProcessor)};_exports.svg$2=_exports.svg$1=_exports.svg=svg;var litHtml={html:html,svg:svg,DefaultTemplateProcessor:DefaultTemplateProcessor,defaultTemplateProcessor:defaultTemplateProcessor,directive:directive,isDirective:isDirective,removeNodes:removeNodes,reparentNodes:reparentNodes,noChange:noChange,nothing:nothing,AttributeCommitter:AttributeCommitter,AttributePart:AttributePart,BooleanAttributePart:BooleanAttributePart,EventPart:EventPart,isPrimitive:isPrimitive,NodePart:NodePart,PropertyCommitter:PropertyCommitter,PropertyPart:PropertyPart,parts:parts$1,render:render,templateCaches:templateCaches,templateFactory:templateFactory,TemplateInstance:TemplateInstance,SVGTemplateResult:SVGTemplateResult,TemplateResult:TemplateResult,createMarker:createMarker,isTemplatePartActive:isTemplatePartActive,Template:Template};_exports.$litHtml=litHtml;var walkerNodeFilter=133;function removeNodesFromTemplate(template,nodesToRemove){var content=template.element.content,parts=template.parts,walker=document.createTreeWalker(content,walkerNodeFilter,null,!1),partIndex=nextActiveIndexInTemplateParts(parts),part=parts[partIndex],nodeIndex=-1,removeCount=0,nodesToRemoveInTemplate=[],currentRemovingNode=null;while(walker.nextNode()){nodeIndex++;var node=walker.currentNode;if(node.previousSibling===currentRemovingNode){currentRemovingNode=null}if(nodesToRemove.has(node)){nodesToRemoveInTemplate.push(node);if(null===currentRemovingNode){currentRemovingNode=node}}if(null!==currentRemovingNode){removeCount++}while(part!==void 0&&part.index===nodeIndex){part.index=null!==currentRemovingNode?-1:part.index-removeCount;partIndex=nextActiveIndexInTemplateParts(parts,partIndex);part=parts[partIndex]}}nodesToRemoveInTemplate.forEach(function(n){return n.parentNode.removeChild(n)})}var countNodes=function countNodes(node){var count=11===node.nodeType?0:1,walker=document.createTreeWalker(node,walkerNodeFilter,null,!1);while(walker.nextNode()){count++}return count},nextActiveIndexInTemplateParts=function nextActiveIndexInTemplateParts(parts){for(var startIndex=1<arguments.length&&arguments[1]!==void 0?arguments[1]:-1,i=startIndex+1,_part6;i<parts.length;i++){_part6=parts[i];if(isTemplatePartActive(_part6)){return i}}return-1};function insertNodeIntoTemplate(template,node){var refNode=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null,content=template.element.content,parts=template.parts;if(null===refNode||refNode===void 0){content.appendChild(node);return}var walker=document.createTreeWalker(content,walkerNodeFilter,null,!1),partIndex=nextActiveIndexInTemplateParts(parts),insertCount=0,walkerIndex=-1;while(walker.nextNode()){walkerIndex++;var walkerNode=walker.currentNode;if(walkerNode===refNode){insertCount=countNodes(node);refNode.parentNode.insertBefore(node,refNode)}while(-1!==partIndex&&parts[partIndex].index===walkerIndex){if(0<insertCount){while(-1!==partIndex){parts[partIndex].index+=insertCount;partIndex=nextActiveIndexInTemplateParts(parts,partIndex)}return}partIndex=nextActiveIndexInTemplateParts(parts,partIndex)}}}var modifyTemplate={removeNodesFromTemplate:removeNodesFromTemplate,insertNodeIntoTemplate:insertNodeIntoTemplate};_exports.$modifyTemplate=modifyTemplate;var getTemplateCacheKey=function getTemplateCacheKey(type,scopeName){return"".concat(type,"--").concat(scopeName)},compatibleShadyCSSVersion=!0;if("undefined"===typeof window.ShadyCSS){compatibleShadyCSSVersion=!1}else if("undefined"===typeof window.ShadyCSS.prepareTemplateDom){console.warn("Incompatible ShadyCSS version detected."+"Please update to at least @webcomponents/webcomponentsjs@2.0.2 and"+"@webcomponents/shadycss@1.3.1.");compatibleShadyCSSVersion=!1}var shadyTemplateFactory=function shadyTemplateFactory(scopeName){return function(result){var cacheKey=getTemplateCacheKey(result.type,scopeName),templateCache=templateCaches.get(cacheKey);if(templateCache===void 0){templateCache={stringsArray:new WeakMap,keyString:new Map};templateCaches.set(cacheKey,templateCache)}var template=templateCache.stringsArray.get(result.strings);if(template!==void 0){return template}var key=result.strings.join(marker);template=templateCache.keyString.get(key);if(template===void 0){var element=result.getTemplateElement();if(compatibleShadyCSSVersion){window.ShadyCSS.prepareTemplateDom(element,scopeName)}template=new Template(result,element);templateCache.keyString.set(key,template)}templateCache.stringsArray.set(result.strings,template);return template}},TEMPLATE_TYPES=["html","svg"],removeStylesFromLitTemplates=function removeStylesFromLitTemplates(scopeName){TEMPLATE_TYPES.forEach(function(type){var templates=templateCaches.get(getTemplateCacheKey(type,scopeName));if(templates!==void 0){templates.keyString.forEach(function(template){var content=template.element.content,styles=new Set;Array.from(content.querySelectorAll("style")).forEach(function(s){styles.add(s)});removeNodesFromTemplate(template,styles)})}})},shadyRenderSet=new Set,prepareTemplateStyles=function prepareTemplateStyles(renderedDOM,template,scopeName){shadyRenderSet.add(scopeName);var styles=renderedDOM.querySelectorAll("style");if(0===styles.length){window.ShadyCSS.prepareTemplateStyles(template.element,scopeName);return}for(var condensedStyle=document.createElement("style"),i=0,style;i<styles.length;i++){style=styles[i];style.parentNode.removeChild(style);condensedStyle.textContent+=style.textContent}removeStylesFromLitTemplates(scopeName);insertNodeIntoTemplate(template,condensedStyle,template.element.content.firstChild);window.ShadyCSS.prepareTemplateStyles(template.element,scopeName);if(window.ShadyCSS.nativeShadow){var _style=template.element.content.querySelector("style");renderedDOM.insertBefore(_style.cloneNode(!0),renderedDOM.firstChild)}else{template.element.content.insertBefore(condensedStyle,template.element.content.firstChild);var removes=new Set([condensedStyle]);removeNodesFromTemplate(template,removes)}},render$2=function render$2(result,container,options){var scopeName=options.scopeName,hasRendered=parts$1.has(container),needsScoping=babelHelpers.instanceof(container,ShadowRoot)&&compatibleShadyCSSVersion&&babelHelpers.instanceof(result,TemplateResult),firstScopeRender=needsScoping&&!shadyRenderSet.has(scopeName),renderContainer=firstScopeRender?document.createDocumentFragment():container;render(result,renderContainer,Object.assign({templateFactory:shadyTemplateFactory(scopeName)},options));if(firstScopeRender){var _part7=parts$1.get(renderContainer);parts$1.delete(renderContainer);if(babelHelpers.instanceof(_part7.value,TemplateInstance)){prepareTemplateStyles(renderContainer,_part7.value.template,scopeName)}removeNodes(container,container.firstChild);container.appendChild(renderContainer);parts$1.set(container,_part7)}if(!hasRendered&&needsScoping){window.ShadyCSS.styleElement(container.host)}};_exports.render$1=render$2;var shadyRender={render:render$2,html:html,svg:svg,TemplateResult:TemplateResult};_exports.$shadyRender=shadyRender;(window.litElementVersions||(window.litElementVersions=[])).push("2.0.1");function arrayFlat(styles){for(var result=1<arguments.length&&arguments[1]!==void 0?arguments[1]:[],i=0,length=styles.length,value;i<length;i++){value=styles[i];if(Array.isArray(value)){arrayFlat(value,result)}else{result.push(value)}}return result}var flattenStyles=function flattenStyles(styles){return styles.flat?styles.flat(1/0):arrayFlat(styles)},LitElement=function(_UpdatingElement){babelHelpers.inherits(LitElement,_UpdatingElement);function LitElement(){babelHelpers.classCallCheck(this,LitElement);return babelHelpers.possibleConstructorReturn(this,babelHelpers.getPrototypeOf(LitElement).apply(this,arguments))}babelHelpers.createClass(LitElement,[{key:"initialize",value:function initialize(){babelHelpers.get(babelHelpers.getPrototypeOf(LitElement.prototype),"initialize",this).call(this);this.renderRoot=this.createRenderRoot();if(window.ShadowRoot&&babelHelpers.instanceof(this.renderRoot,window.ShadowRoot)){this.adoptStyles()}}},{key:"createRenderRoot",value:function createRenderRoot(){return this.attachShadow({mode:"open"})}},{key:"adoptStyles",value:function adoptStyles(){var styles=this.constructor._styles;if(0===styles.length){return}if(window.ShadyCSS!==void 0&&!window.ShadyCSS.nativeShadow){window.ShadyCSS.ScopingShim.prepareAdoptedCssText(styles.map(function(s){return s.cssText}),this.localName)}else if(supportsAdoptingStyleSheets){this.renderRoot.adoptedStyleSheets=styles.map(function(s){return s.styleSheet})}else{this._needsShimAdoptedStyleSheets=!0}}},{key:"connectedCallback",value:function connectedCallback(){babelHelpers.get(babelHelpers.getPrototypeOf(LitElement.prototype),"connectedCallback",this).call(this);if(this.hasUpdated&&window.ShadyCSS!==void 0){window.ShadyCSS.styleElement(this)}}},{key:"update",value:function update(changedProperties){var _this12=this;babelHelpers.get(babelHelpers.getPrototypeOf(LitElement.prototype),"update",this).call(this,changedProperties);var templateResult=this.render();if(babelHelpers.instanceof(templateResult,TemplateResult)){this.constructor.render(templateResult,this.renderRoot,{scopeName:this.localName,eventContext:this})}if(this._needsShimAdoptedStyleSheets){this._needsShimAdoptedStyleSheets=!1;this.constructor._styles.forEach(function(s){var style=document.createElement("style");style.textContent=s.cssText;_this12.renderRoot.appendChild(style)})}}},{key:"render",value:function render(){}}],[{key:"finalize",value:function finalize(){babelHelpers.get(babelHelpers.getPrototypeOf(LitElement),"finalize",this).call(this);this._styles=this.hasOwnProperty(JSCompiler_renameProperty("styles",this))?this._getUniqueStyles():this._styles||[]}},{key:"_getUniqueStyles",value:function _getUniqueStyles(){var userStyles=this.styles,styles=[];if(Array.isArray(userStyles)){var flatStyles=flattenStyles(userStyles),styleSet=flatStyles.reduceRight(function(set,s){set.add(s);return set},new Set);styleSet.forEach(function(v){return styles.unshift(v)})}else if(userStyles){styles.push(userStyles)}return styles}}]);return LitElement}(UpdatingElement);_exports.LitElement=LitElement;LitElement.finalized=!0;LitElement.render=render$2;var litElement={LitElement:LitElement,defaultConverter:defaultConverter,notEqual:notEqual,UpdatingElement:UpdatingElement,customElement:customElement,property:property,query:query,queryAll:queryAll,eventOptions:eventOptions,html:html,svg:svg,TemplateResult:TemplateResult,SVGTemplateResult:SVGTemplateResult,supportsAdoptingStyleSheets:supportsAdoptingStyleSheets,CSSResult:CSSResult,unsafeCSS:unsafeCSS,css:css};_exports.$litElement=litElement;var previousValues=new WeakMap,unsafeHTML=directive(function(value){return function(part){if(!babelHelpers.instanceof(part,NodePart)){throw new Error("unsafeHTML can only be used in text bindings")}var previousValue=previousValues.get(part);if(previousValue!==void 0&&isPrimitive(value)&&value===previousValue.value&&part.value===previousValue.fragment){return}var template=document.createElement("template");template.innerHTML=value;var fragment=document.importNode(template.content,!0);part.setValue(fragment);previousValues.set(part,{value:value,fragment:fragment})}});_exports.unsafeHTML=unsafeHTML;var unsafeHtml={unsafeHTML:unsafeHTML};_exports.$unsafeHtml=unsafeHtml;var buildQueryString=function buildQueryString(props,supportedKeys){var result="";Object.keys(props).forEach(function(key){if(-1===supportedKeys.indexOf(key)){return}if(!result&&props[key]){result="?".concat(key,"=").concat(props[key]);return}if(result&&props[key]){result="".concat(result,"&").concat(key,"=").concat(props[key]);return}});return result};_exports.buildQueryString=buildQueryString;var formatDate=function formatDate(timestring){var pad=function pad(v){return 10>v?"0".concat(v):"".concat(v)},dateString=timestring.split("T")[0],date=new Date(dateString),year=date.getUTCFullYear().toString(),day=pad(date.getUTCDate()),weekday=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"][date.getUTCDay()],month=["January","February","March","April","May","June","July","August","September","October","November","December"][date.getUTCMonth()];return"".concat(weekday,", ").concat(day," ").concat(month," ").concat(year)};_exports.formatDate=formatDate;var removeSubdomain=function removeSubdomain(link,subDomain){return link?link.replace("//".concat(subDomain,"."),"//"):""};_exports.removeSubdomain=removeSubdomain;var getPosts=function getPosts(apiUrl){return new Promise(function(resolve,reject){return fetch(apiUrl).then(function(res){if(res.ok){return res.json()}throw new Error("status: ".concat(res.status,"\n ").concat(res.statusText?" | statusText: ".concat(res.statusText):"","\n "))}).then(function(response){return resolve(response)}).catch(function(err){return reject(err)})})};_exports.getPosts=getPosts;var getPostsUrl=function getPostsUrl(props,supportedKeys){return"".concat(props.apiHost).concat(props.apiPath,"/posts").concat(buildQueryString(props,supportedKeys))};_exports.getPostsUrl=getPostsUrl;var misc={buildQueryString:buildQueryString,formatDate:formatDate,removeSubdomain:removeSubdomain,getPosts:getPosts,getPostsUrl:getPostsUrl};_exports.$misc=misc;var article=function article(_ref){var content=_ref.content,date_gmt=_ref.date_gmt,errorMessage=_ref.errorMessage,link=_ref.link,title=_ref.title;return html(_templateObject_6576bdb0dcb611e9a23fc186ac4bedc0(),unsafeHTML("<a href=\"".concat(link,"\">").concat(title.rendered,"</a>")),errorMessage?errorMessage:date_gmt?formatDate(date_gmt):"",unsafeHTML(content.rendered))};_exports.$articleDefault=article;var article$1={default:article};_exports.$article=article$1;var getErrorMessageArticle=function getErrorMessageArticle(err){return[article({errorMessage:"".concat(err.message),date_gmt:"",link:"",title:{rendered:"Error"},content:{rendered:"<p>Posts are unavailable. Please check the error and try again.</p>"}})]};_exports.getErrorMessageArticle=getErrorMessageArticle;var loading=[article({errorMessage:"",date_gmt:"",link:"",title:{rendered:"Loading..."},content:{rendered:""}})];_exports.loading=loading;var articles=function articles(_articles){return _articles.map(function(res){return article(res)})};_exports.$articlesDefault=articles;var articles$1={getErrorMessageArticle:getErrorMessageArticle,loading:loading,default:articles};_exports.$articles=articles$1;var styles=css(_templateObject2_6576bdb0dcb611e9a23fc186ac4bedc0());_exports.$xPostpressDefault$1=styles;var xPostpress={default:styles};_exports.$xPostpress$1=xPostpress;var __decorate=void 0||function(decorators,target,key,desc){var c=arguments.length,r=3>c?target:null===desc?desc=Object.getOwnPropertyDescriptor(target,key):desc,d;if("object"===("undefined"===typeof Reflect?"undefined":babelHelpers.typeof(Reflect))&&"function"===typeof Reflect.decorate)r=Reflect.decorate(decorators,target,key,desc);else for(var i=decorators.length-1;0<=i;i--){if(d=decorators[i])r=(3>c?d(r):3<c?d(target,key,r):d(target,key))||r}return 3<c&&r&&Object.defineProperty(target,key,r),r},default_1=function(_LitElement){babelHelpers.inherits(default_1,_LitElement);function default_1(){var _this13;babelHelpers.classCallCheck(this,default_1);_this13=babelHelpers.possibleConstructorReturn(this,babelHelpers.getPrototypeOf(default_1).call(this));_this13.apiHost="";_this13.apiPath="/wp-json/wp/v2";_this13.categories="";_this13.include="";_this13.page="";_this13.per_page="";_this13.tags="";_this13.search="";_this13.slug="";_this13.urlAttributes=["apiHost","apiPath"];_this13.builtQueryStringAttributes=["categories","include","page","per_page","search","slug","tags"];_this13.didGetPosts=!1;_this13.articles=loading;return _this13}babelHelpers.createClass(default_1,[{key:"requestPosts",value:function requestPosts(){var _this14=this,postsUrl=getPostsUrl({apiHost:this.apiHost,apiPath:this.apiPath,categories:this.categories,include:this.include,page:this.page,per_page:this.per_page,search:this.search,slug:this.slug,tags:this.tags},this.builtQueryStringAttributes);getPosts(postsUrl).then(function(res){return articles(res)}).catch(function(err){return getErrorMessageArticle(err)}).then(function(articles$$1){_this14.didGetPosts=!0;_this14.articles=articles$$1})}},{key:"firstUpdated",value:function firstUpdated(){if(this.apiHost){this.requestPosts()}}},{key:"updated",value:function updated(changedProperties){if(this.didGetPosts&&this.apiHost){var shouldGetPostsAttributes=[].concat(babelHelpers.toConsumableArray(this.urlAttributes),babelHelpers.toConsumableArray(this.builtQueryStringAttributes)),props=changedProperties.keys(),prop=props.next();while(!prop.done){if(-1!==shouldGetPostsAttributes.indexOf(prop.value)){this.requestPosts();break}prop=props.next()}}}},{key:"render",value:function render(){return html(_templateObject3_6576bdb0dcb611e9a23fc186ac4bedc0(),this.apiHost&&this.articles)}}]);return default_1}(LitElement);default_1.styles=styles;__decorate([property({type:String,reflect:!0})],default_1.prototype,"apiHost",void 0);__decorate([property({type:String,reflect:!0})],default_1.prototype,"apiPath",void 0);__decorate([property({type:String,reflect:!0})],default_1.prototype,"categories",void 0);__decorate([property({type:String,reflect:!0})],default_1.prototype,"include",void 0);__decorate([property({type:String,reflect:!0})],default_1.prototype,"page",void 0);__decorate([property({type:String,reflect:!0})],default_1.prototype,"per_page",void 0);__decorate([property({type:String,reflect:!0})],default_1.prototype,"tags",void 0);__decorate([property({type:String,reflect:!0})],default_1.prototype,"search",void 0);__decorate([property({type:String,reflect:!0})],default_1.prototype,"slug",void 0);__decorate([property({type:Array})],default_1.prototype,"urlAttributes",void 0);__decorate([property({type:Array})],default_1.prototype,"builtQueryStringAttributes",void 0);__decorate([property({type:Boolean})],default_1.prototype,"didGetPosts",void 0);__decorate([property({type:Object,noAccessor:!1})],default_1.prototype,"articles",void 0);default_1=__decorate([customElement("x-postpress")],default_1);var default_1$1=default_1;_exports.$xPostpressDefault=default_1$1;var xPostpress$1={default:default_1$1};_exports.$xPostpress=xPostpress$1});
{
"name": "x-postpress",
"version": "2.1.10",
"version": "2.1.11",
"license": "BSD-3-Clause",

@@ -11,2 +11,3 @@ "homepage": "https://github.com/kherrick/x-postpress#readme",

"main": "./build/esm-bundled/src/components/x-postpress.js",
"module": "./build/esm-bundled/src/components/x-postpress.js",
"scripts": {

@@ -13,0 +14,0 @@ "build:app": "./bin/build-app && npx gulp prpl-server",

@@ -6,3 +6,3 @@ {

"name": "esm-bundled",
"basePath": true,
"basePath": "/",
"browserCapabilities": [

@@ -28,3 +28,3 @@ "es2015",

"name": "es6-bundled",
"basePath": true,
"basePath": "/",
"browserCapabilities": [

@@ -50,3 +50,3 @@ "es2015",

"name": "es5-bundled",
"basePath": true,
"basePath": "/",
"js": {

@@ -89,3 +89,3 @@ "compile": "es5",

"npm": true,
"shell": "src/app.js",
"shell": "src/components/x-postpress.js",
"sources": [

@@ -92,0 +92,0 @@ "./images/**/*",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc