next
Version:
The React Framework
2 lines • 61.3 kB
JavaScript
(()=>{var e={417:e=>{e.exports=function(e,t){var r=-1,n=[];while((r=e.indexOf(t,r+1))!==-1)n.push(r);return n}},258:e=>{"use strict";function unique_pred(e,t){var r=1,n=e.length,s=e[0],i=e[0];for(var a=1;a<n;++a){i=s;s=e[a];if(t(s,i)){if(a===r){r++;continue}e[r++]=s}}e.length=r;return e}function unique_eq(e){var t=1,r=e.length,n=e[0],s=e[0];for(var i=1;i<r;++i,s=n){s=n;n=e[i];if(n!==s){if(i===t){t++;continue}e[t++]=n}}e.length=t;return e}function unique(e,t,r){if(e.length===0){return e}if(t){if(!r){e.sort(t)}return unique_pred(e,t)}if(!r){e.sort()}return unique_eq(e)}e.exports=unique},209:(e,t,r)=>{e.exports=r(837).deprecate},316:e=>{"use strict";
/*! https://mths.be/cssesc v3.0.0 by @mathias */var t={};var r=t.hasOwnProperty;var n=function merge(e,t){if(!e){return t}var n={};for(var s in t){n[s]=r.call(e,s)?e[s]:t[s]}return n};var s=/[ -,\.\/:-@\[-\^`\{-~]/;var i=/[ -,\.\/:-@\[\]\^`\{-~]/;var a=/['"\\]/;var o=/(^|\\+)?(\\[A-F0-9]{1,6})\x20(?![a-fA-F0-9\x20])/g;var u=function cssesc(e,t){t=n(t,cssesc.options);if(t.quotes!="single"&&t.quotes!="double"){t.quotes="single"}var r=t.quotes=="double"?'"':"'";var a=t.isIdentifier;var u=e.charAt(0);var c="";var l=0;var f=e.length;while(l<f){var p=e.charAt(l++);var h=p.charCodeAt();var d=void 0;if(h<32||h>126){if(h>=55296&&h<=56319&&l<f){var v=e.charCodeAt(l++);if((v&64512)==56320){h=((h&1023)<<10)+(v&1023)+65536}else{l--}}d="\\"+h.toString(16).toUpperCase()+" "}else{if(t.escapeEverything){if(s.test(p)){d="\\"+p}else{d="\\"+h.toString(16).toUpperCase()+" "}}else if(/[\t\n\f\r\x0B]/.test(p)){d="\\"+h.toString(16).toUpperCase()+" "}else if(p=="\\"||!a&&(p=='"'&&r==p||p=="'"&&r==p)||a&&i.test(p)){d="\\"+p}else{d=p}}c+=d}if(a){if(/^-[-\d]/.test(c)){c="\\-"+c.slice(1)}else if(/\d/.test(u)){c="\\3"+u+" "+c.slice(1)}}c=c.replace(o,(function(e,t,r){if(t&&t.length%2){return e}return(t||"")+r}));if(!a&&t.wrap){return r+c+r}return c};u.options={escapeEverything:false,isIdentifier:false,quotes:"single",wrap:false};u.version="3.0.0";e.exports=u},175:(e,t,r)=>{"use strict";const n=r(347);const s=Object.prototype.hasOwnProperty;function getSingleLocalNamesForComposes(e){return e.nodes.map((t=>{if(t.type!=="selector"||t.nodes.length!==1){throw new Error(`composition is only allowed when selector is single :local class name not in "${e}"`)}t=t.nodes[0];if(t.type!=="pseudo"||t.value!==":local"||t.nodes.length!==1){throw new Error('composition is only allowed when selector is single :local class name not in "'+e+'", "'+t+'" is weird')}t=t.first;if(t.type!=="selector"||t.length!==1){throw new Error('composition is only allowed when selector is single :local class name not in "'+e+'", "'+t+'" is weird')}t=t.first;if(t.type!=="class"){throw new Error('composition is only allowed when selector is single :local class name not in "'+e+'", "'+t+'" is weird')}return t.value}))}const i="[\\x20\\t\\r\\n\\f]";const a=new RegExp("\\\\([\\da-f]{1,6}"+i+"?|("+i+")|.)","ig");function unescape(e){return e.replace(a,((e,t,r)=>{const n="0x"+t-65536;return n!==n||r?t:n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,n&1023|56320)}))}const plugin=(e={})=>{const t=e&&e.generateScopedName||plugin.generateScopedName;const r=e&&e.generateExportEntry||plugin.generateExportEntry;const i=e&&e.exportGlobals;return{postcssPlugin:"postcss-modules-scope",Once(e,{rule:a}){const o=Object.create(null);function exportScopedName(n,s){const i=t(s?s:n,e.source.input.from,e.source.input.css);const a=r(s?s:n,i,e.source.input.from,e.source.input.css);const{key:u,value:c}=a;o[u]=o[u]||[];if(o[u].indexOf(c)<0){o[u].push(c)}return i}function localizeNode(e){switch(e.type){case"selector":e.nodes=e.map(localizeNode);return e;case"class":return n.className({value:exportScopedName(e.value,e.raws&&e.raws.value?e.raws.value:null)});case"id":{return n.id({value:exportScopedName(e.value,e.raws&&e.raws.value?e.raws.value:null)})}}throw new Error(`${e.type} ("${e}") is not allowed in a :local block`)}function traverseNode(e){switch(e.type){case"pseudo":if(e.value===":local"){if(e.nodes.length!==1){throw new Error('Unexpected comma (",") in :local block')}const t=localizeNode(e.first,e.spaces);t.first.spaces=e.spaces;const r=e.next();if(r&&r.type==="combinator"&&r.value===" "&&/\\[A-F0-9]{1,6}$/.test(t.last.value)){t.last.spaces.after=" "}e.replaceWith(t);return}case"root":case"selector":{e.each(traverseNode);break}case"id":case"class":if(i){o[e.value]=[e.value]}break}return e}const u={};e.walkRules(/^:import\(.+\)$/,(e=>{e.walkDecls((e=>{u[e.prop]=true}))}));e.walkRules((e=>{let t=n().astSync(e);e.selector=traverseNode(t.clone()).toString();e.walkDecls(/composes|compose-with/i,(e=>{const r=getSingleLocalNamesForComposes(t);const n=e.value.split(/\s+/);n.forEach((t=>{const n=/^global\(([^)]+)\)$/.exec(t);if(n){r.forEach((e=>{o[e].push(n[1])}))}else if(s.call(u,t)){r.forEach((e=>{o[e].push(t)}))}else if(s.call(o,t)){r.forEach((e=>{o[t].forEach((t=>{o[e].push(t)}))}))}else{throw e.error(`referenced class name "${t}" in ${e.prop} not found`)}}));e.remove()}));e.walkDecls((e=>{if(!/:local\s*\((.+?)\)/.test(e.value)){return}let t=e.value.split(/(,|'[^']*'|"[^"]*")/);t=t.map(((e,r)=>{if(r===0||t[r-1]===","){let t=e;const r=/:local\s*\((.+?)\)/.exec(e);if(r){const e=r.input;const n=r[0];const s=r[1];const i=exportScopedName(s);t=e.replace(n,i)}else{return e}return t}else{return e}}));e.value=t.join("")}))}));e.walkAtRules(/keyframes$/i,(e=>{const t=/^\s*:local\s*\((.+?)\)\s*$/.exec(e.params);if(!t){return}e.params=exportScopedName(t[1])}));const c=Object.keys(o);if(c.length>0){const t=a({selector:":export"});c.forEach((e=>t.append({prop:e,value:o[e].join(" "),raws:{before:"\n "}})));e.append(t)}}}};plugin.postcss=true;plugin.generateScopedName=function(e,t){const r=t.replace(/\.[^./\\]+$/,"").replace(/[\W_]+/g,"_").replace(/^_|_$/g,"");return`_${r}__${e}`.trim()};plugin.generateExportEntry=function(e,t){return{key:unescape(e),value:unescape(t)}};e.exports=plugin},347:(e,t,r)=>{"use strict";t.__esModule=true;t["default"]=void 0;var n=_interopRequireDefault(r(780));var s=_interopRequireWildcard(r(627));function _interopRequireWildcard(e){if(e&&e.__esModule){return e}else{var t={};if(e!=null){for(var r in e){if(Object.prototype.hasOwnProperty.call(e,r)){var n=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(e,r):{};if(n.get||n.set){Object.defineProperty(t,r,n)}else{t[r]=e[r]}}}}t.default=e;return t}}function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}var i=function parser(e){return new n.default(e)};Object.assign(i,s);delete i.__esModule;var a=i;t["default"]=a;e.exports=t.default},629:(e,t,r)=>{"use strict";t.__esModule=true;t["default"]=void 0;var n=_interopRequireDefault(r(417));var s=_interopRequireDefault(r(258));var i=_interopRequireDefault(r(4));var a=_interopRequireDefault(r(561));var o=_interopRequireDefault(r(717));var u=_interopRequireDefault(r(786));var c=_interopRequireDefault(r(486));var l=_interopRequireDefault(r(574));var f=_interopRequireDefault(r(307));var p=_interopRequireDefault(r(585));var h=_interopRequireWildcard(r(196));var d=_interopRequireDefault(r(382));var v=_interopRequireDefault(r(604));var _=_interopRequireDefault(r(359));var S=_interopRequireDefault(r(5));var g=_interopRequireWildcard(r(633));var T=_interopRequireWildcard(r(522));var w=_interopRequireWildcard(r(469));var m=r(843);var b,k;function _interopRequireWildcard(e){if(e&&e.__esModule){return e}else{var t={};if(e!=null){for(var r in e){if(Object.prototype.hasOwnProperty.call(e,r)){var n=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(e,r):{};if(n.get||n.set){Object.defineProperty(t,r,n)}else{t[r]=e[r]}}}}t.default=e;return t}}function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function _defineProperties(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||false;n.configurable=true;if("value"in n)n.writable=true;Object.defineProperty(e,n.key,n)}}function _createClass(e,t,r){if(t)_defineProperties(e.prototype,t);if(r)_defineProperties(e,r);return e}var E=(b={},b[T.space]=true,b[T.cr]=true,b[T.feed]=true,b[T.newline]=true,b[T.tab]=true,b);var y=Object.assign({},E,(k={},k[T.comment]=true,k));function tokenStart(e){return{line:e[g.FIELDS.START_LINE],column:e[g.FIELDS.START_COL]}}function tokenEnd(e){return{line:e[g.FIELDS.END_LINE],column:e[g.FIELDS.END_COL]}}function getSource(e,t,r,n){return{start:{line:e,column:t},end:{line:r,column:n}}}function getTokenSource(e){return getSource(e[g.FIELDS.START_LINE],e[g.FIELDS.START_COL],e[g.FIELDS.END_LINE],e[g.FIELDS.END_COL])}function getTokenSourceSpan(e,t){if(!e){return undefined}return getSource(e[g.FIELDS.START_LINE],e[g.FIELDS.START_COL],t[g.FIELDS.END_LINE],t[g.FIELDS.END_COL])}function unescapeProp(e,t){var r=e[t];if(typeof r!=="string"){return}if(r.indexOf("\\")!==-1){(0,m.ensureObject)(e,"raws");e[t]=(0,m.unesc)(r);if(e.raws[t]===undefined){e.raws[t]=r}}return e}var P=function(){function Parser(e,t){if(t===void 0){t={}}this.rule=e;this.options=Object.assign({lossy:false,safe:false},t);this.position=0;this.css=typeof this.rule==="string"?this.rule:this.rule.selector;this.tokens=(0,g.default)({css:this.css,error:this._errorGenerator(),safe:this.options.safe});var r=getTokenSourceSpan(this.tokens[0],this.tokens[this.tokens.length-1]);this.root=new i.default({source:r});this.root.errorGenerator=this._errorGenerator();var n=new a.default({source:{start:{line:1,column:1}}});this.root.append(n);this.current=n;this.loop()}var e=Parser.prototype;e._errorGenerator=function _errorGenerator(){var e=this;return function(t,r){if(typeof e.rule==="string"){return new Error(t)}return e.rule.error(t,r)}};e.attribute=function attribute(){var e=[];var t=this.currToken;this.position++;while(this.position<this.tokens.length&&this.currToken[g.FIELDS.TYPE]!==T.closeSquare){e.push(this.currToken);this.position++}if(this.currToken[g.FIELDS.TYPE]!==T.closeSquare){return this.expected("closing square bracket",this.currToken[g.FIELDS.START_POS])}var r=e.length;var n={source:getSource(t[1],t[2],this.currToken[3],this.currToken[4]),sourceIndex:t[g.FIELDS.START_POS]};if(r===1&&!~[T.word].indexOf(e[0][g.FIELDS.TYPE])){return this.expected("attribute",e[0][g.FIELDS.START_POS])}var s=0;var i="";var a="";var o=null;var u=false;while(s<r){var c=e[s];var l=this.content(c);var f=e[s+1];switch(c[g.FIELDS.TYPE]){case T.space:u=true;if(this.options.lossy){break}if(o){(0,m.ensureObject)(n,"spaces",o);var p=n.spaces[o].after||"";n.spaces[o].after=p+l;var d=(0,m.getProp)(n,"raws","spaces",o,"after")||null;if(d){n.raws.spaces[o].after=d+l}}else{i=i+l;a=a+l}break;case T.asterisk:if(f[g.FIELDS.TYPE]===T.equals){n.operator=l;o="operator"}else if((!n.namespace||o==="namespace"&&!u)&&f){if(i){(0,m.ensureObject)(n,"spaces","attribute");n.spaces.attribute.before=i;i=""}if(a){(0,m.ensureObject)(n,"raws","spaces","attribute");n.raws.spaces.attribute.before=i;a=""}n.namespace=(n.namespace||"")+l;var v=(0,m.getProp)(n,"raws","namespace")||null;if(v){n.raws.namespace+=l}o="namespace"}u=false;break;case T.dollar:if(o==="value"){var _=(0,m.getProp)(n,"raws","value");n.value+="$";if(_){n.raws.value=_+"$"}break}case T.caret:if(f[g.FIELDS.TYPE]===T.equals){n.operator=l;o="operator"}u=false;break;case T.combinator:if(l==="~"&&f[g.FIELDS.TYPE]===T.equals){n.operator=l;o="operator"}if(l!=="|"){u=false;break}if(f[g.FIELDS.TYPE]===T.equals){n.operator=l;o="operator"}else if(!n.namespace&&!n.attribute){n.namespace=true}u=false;break;case T.word:if(f&&this.content(f)==="|"&&e[s+2]&&e[s+2][g.FIELDS.TYPE]!==T.equals&&!n.operator&&!n.namespace){n.namespace=l;o="namespace"}else if(!n.attribute||o==="attribute"&&!u){if(i){(0,m.ensureObject)(n,"spaces","attribute");n.spaces.attribute.before=i;i=""}if(a){(0,m.ensureObject)(n,"raws","spaces","attribute");n.raws.spaces.attribute.before=a;a=""}n.attribute=(n.attribute||"")+l;var S=(0,m.getProp)(n,"raws","attribute")||null;if(S){n.raws.attribute+=l}o="attribute"}else if(!n.value&&n.value!==""||o==="value"&&!u){var w=(0,m.unesc)(l);var b=(0,m.getProp)(n,"raws","value")||"";var k=n.value||"";n.value=k+w;n.quoteMark=null;if(w!==l||b){(0,m.ensureObject)(n,"raws");n.raws.value=(b||k)+l}o="value"}else{var E=l==="i"||l==="I";if((n.value||n.value==="")&&(n.quoteMark||u)){n.insensitive=E;if(!E||l==="I"){(0,m.ensureObject)(n,"raws");n.raws.insensitiveFlag=l}o="insensitive";if(i){(0,m.ensureObject)(n,"spaces","insensitive");n.spaces.insensitive.before=i;i=""}if(a){(0,m.ensureObject)(n,"raws","spaces","insensitive");n.raws.spaces.insensitive.before=a;a=""}}else if(n.value||n.value===""){o="value";n.value+=l;if(n.raws.value){n.raws.value+=l}}}u=false;break;case T.str:if(!n.attribute||!n.operator){return this.error("Expected an attribute followed by an operator preceding the string.",{index:c[g.FIELDS.START_POS]})}var y=(0,h.unescapeValue)(l),P=y.unescaped,O=y.quoteMark;n.value=P;n.quoteMark=O;o="value";(0,m.ensureObject)(n,"raws");n.raws.value=l;u=false;break;case T.equals:if(!n.attribute){return this.expected("attribute",c[g.FIELDS.START_POS],l)}if(n.value){return this.error('Unexpected "=" found; an operator was already defined.',{index:c[g.FIELDS.START_POS]})}n.operator=n.operator?n.operator+l:l;o="operator";u=false;break;case T.comment:if(o){if(u||f&&f[g.FIELDS.TYPE]===T.space||o==="insensitive"){var D=(0,m.getProp)(n,"spaces",o,"after")||"";var q=(0,m.getProp)(n,"raws","spaces",o,"after")||D;(0,m.ensureObject)(n,"raws","spaces",o);n.raws.spaces[o].after=q+l}else{var L=n[o]||"";var I=(0,m.getProp)(n,"raws",o)||L;(0,m.ensureObject)(n,"raws");n.raws[o]=I+l}}else{a=a+l}break;default:return this.error('Unexpected "'+l+'" found.',{index:c[g.FIELDS.START_POS]})}s++}unescapeProp(n,"attribute");unescapeProp(n,"namespace");this.newNode(new h.default(n));this.position++};e.parseWhitespaceEquivalentTokens=function parseWhitespaceEquivalentTokens(e){if(e<0){e=this.tokens.length}var t=this.position;var r=[];var n="";var s=undefined;do{if(E[this.currToken[g.FIELDS.TYPE]]){if(!this.options.lossy){n+=this.content()}}else if(this.currToken[g.FIELDS.TYPE]===T.comment){var i={};if(n){i.before=n;n=""}s=new u.default({value:this.content(),source:getTokenSource(this.currToken),sourceIndex:this.currToken[g.FIELDS.START_POS],spaces:i});r.push(s)}}while(++this.position<e);if(n){if(s){s.spaces.after=n}else if(!this.options.lossy){var a=this.tokens[t];var o=this.tokens[this.position-1];r.push(new f.default({value:"",source:getSource(a[g.FIELDS.START_LINE],a[g.FIELDS.START_COL],o[g.FIELDS.END_LINE],o[g.FIELDS.END_COL]),sourceIndex:a[g.FIELDS.START_POS],spaces:{before:n,after:""}}))}}return r};e.convertWhitespaceNodesToSpace=function convertWhitespaceNodesToSpace(e,t){var r=this;if(t===void 0){t=false}var n="";var s="";e.forEach((function(e){var i=r.lossySpace(e.spaces.before,t);var a=r.lossySpace(e.rawSpaceBefore,t);n+=i+r.lossySpace(e.spaces.after,t&&i.length===0);s+=i+e.value+r.lossySpace(e.rawSpaceAfter,t&&a.length===0)}));if(s===n){s=undefined}var i={space:n,rawSpace:s};return i};e.isNamedCombinator=function isNamedCombinator(e){if(e===void 0){e=this.position}return this.tokens[e+0]&&this.tokens[e+0][g.FIELDS.TYPE]===T.slash&&this.tokens[e+1]&&this.tokens[e+1][g.FIELDS.TYPE]===T.word&&this.tokens[e+2]&&this.tokens[e+2][g.FIELDS.TYPE]===T.slash};e.namedCombinator=function namedCombinator(){if(this.isNamedCombinator()){var e=this.content(this.tokens[this.position+1]);var t=(0,m.unesc)(e).toLowerCase();var r={};if(t!==e){r.value="/"+e+"/"}var n=new v.default({value:"/"+t+"/",source:getSource(this.currToken[g.FIELDS.START_LINE],this.currToken[g.FIELDS.START_COL],this.tokens[this.position+2][g.FIELDS.END_LINE],this.tokens[this.position+2][g.FIELDS.END_COL]),sourceIndex:this.currToken[g.FIELDS.START_POS],raws:r});this.position=this.position+3;return n}else{this.unexpected()}};e.combinator=function combinator(){var e=this;if(this.content()==="|"){return this.namespace()}var t=this.locateNextMeaningfulToken(this.position);if(t<0||this.tokens[t][g.FIELDS.TYPE]===T.comma){var r=this.parseWhitespaceEquivalentTokens(t);if(r.length>0){var n=this.current.last;if(n){var s=this.convertWhitespaceNodesToSpace(r),i=s.space,a=s.rawSpace;if(a!==undefined){n.rawSpaceAfter+=a}n.spaces.after+=i}else{r.forEach((function(t){return e.newNode(t)}))}}return}var o=this.currToken;var u=undefined;if(t>this.position){u=this.parseWhitespaceEquivalentTokens(t)}var c;if(this.isNamedCombinator()){c=this.namedCombinator()}else if(this.currToken[g.FIELDS.TYPE]===T.combinator){c=new v.default({value:this.content(),source:getTokenSource(this.currToken),sourceIndex:this.currToken[g.FIELDS.START_POS]});this.position++}else if(E[this.currToken[g.FIELDS.TYPE]]){}else if(!u){this.unexpected()}if(c){if(u){var l=this.convertWhitespaceNodesToSpace(u),f=l.space,p=l.rawSpace;c.spaces.before=f;c.rawSpaceBefore=p}}else{var h=this.convertWhitespaceNodesToSpace(u,true),d=h.space,_=h.rawSpace;if(!_){_=d}var S={};var w={spaces:{}};if(d.endsWith(" ")&&_.endsWith(" ")){S.before=d.slice(0,d.length-1);w.spaces.before=_.slice(0,_.length-1)}else if(d.startsWith(" ")&&_.startsWith(" ")){S.after=d.slice(1);w.spaces.after=_.slice(1)}else{w.value=_}c=new v.default({value:" ",source:getTokenSourceSpan(o,this.tokens[this.position-1]),sourceIndex:o[g.FIELDS.START_POS],spaces:S,raws:w})}if(this.currToken&&this.currToken[g.FIELDS.TYPE]===T.space){c.spaces.after=this.optionalSpace(this.content());this.position++}return this.newNode(c)};e.comma=function comma(){if(this.position===this.tokens.length-1){this.root.trailingComma=true;this.position++;return}this.current._inferEndPosition();var e=new a.default({source:{start:tokenStart(this.tokens[this.position+1])}});this.current.parent.append(e);this.current=e;this.position++};e.comment=function comment(){var e=this.currToken;this.newNode(new u.default({value:this.content(),source:getTokenSource(e),sourceIndex:e[g.FIELDS.START_POS]}));this.position++};e.error=function error(e,t){throw this.root.error(e,t)};e.missingBackslash=function missingBackslash(){return this.error("Expected a backslash preceding the semicolon.",{index:this.currToken[g.FIELDS.START_POS]})};e.missingParenthesis=function missingParenthesis(){return this.expected("opening parenthesis",this.currToken[g.FIELDS.START_POS])};e.missingSquareBracket=function missingSquareBracket(){return this.expected("opening square bracket",this.currToken[g.FIELDS.START_POS])};e.unexpected=function unexpected(){return this.error("Unexpected '"+this.content()+"'. Escaping special characters with \\ may help.",this.currToken[g.FIELDS.START_POS])};e.namespace=function namespace(){var e=this.prevToken&&this.content(this.prevToken)||true;if(this.nextToken[g.FIELDS.TYPE]===T.word){this.position++;return this.word(e)}else if(this.nextToken[g.FIELDS.TYPE]===T.asterisk){this.position++;return this.universal(e)}};e.nesting=function nesting(){if(this.nextToken){var e=this.content(this.nextToken);if(e==="|"){this.position++;return}}var t=this.currToken;this.newNode(new _.default({value:this.content(),source:getTokenSource(t),sourceIndex:t[g.FIELDS.START_POS]}));this.position++};e.parentheses=function parentheses(){var e=this.current.last;var t=1;this.position++;if(e&&e.type===w.PSEUDO){var r=new a.default({source:{start:tokenStart(this.tokens[this.position-1])}});var n=this.current;e.append(r);this.current=r;while(this.position<this.tokens.length&&t){if(this.currToken[g.FIELDS.TYPE]===T.openParenthesis){t++}if(this.currToken[g.FIELDS.TYPE]===T.closeParenthesis){t--}if(t){this.parse()}else{this.current.source.end=tokenEnd(this.currToken);this.current.parent.source.end=tokenEnd(this.currToken);this.position++}}this.current=n}else{var s=this.currToken;var i="(";var o;while(this.position<this.tokens.length&&t){if(this.currToken[g.FIELDS.TYPE]===T.openParenthesis){t++}if(this.currToken[g.FIELDS.TYPE]===T.closeParenthesis){t--}o=this.currToken;i+=this.parseParenthesisToken(this.currToken);this.position++}if(e){e.appendToPropertyAndEscape("value",i,i)}else{this.newNode(new f.default({value:i,source:getSource(s[g.FIELDS.START_LINE],s[g.FIELDS.START_COL],o[g.FIELDS.END_LINE],o[g.FIELDS.END_COL]),sourceIndex:s[g.FIELDS.START_POS]}))}}if(t){return this.expected("closing parenthesis",this.currToken[g.FIELDS.START_POS])}};e.pseudo=function pseudo(){var e=this;var t="";var r=this.currToken;while(this.currToken&&this.currToken[g.FIELDS.TYPE]===T.colon){t+=this.content();this.position++}if(!this.currToken){return this.expected(["pseudo-class","pseudo-element"],this.position-1)}if(this.currToken[g.FIELDS.TYPE]===T.word){this.splitWord(false,(function(n,s){t+=n;e.newNode(new p.default({value:t,source:getTokenSourceSpan(r,e.currToken),sourceIndex:r[g.FIELDS.START_POS]}));if(s>1&&e.nextToken&&e.nextToken[g.FIELDS.TYPE]===T.openParenthesis){e.error("Misplaced parenthesis.",{index:e.nextToken[g.FIELDS.START_POS]})}}))}else{return this.expected(["pseudo-class","pseudo-element"],this.currToken[g.FIELDS.START_POS])}};e.space=function space(){var e=this.content();if(this.position===0||this.prevToken[g.FIELDS.TYPE]===T.comma||this.prevToken[g.FIELDS.TYPE]===T.openParenthesis||this.current.nodes.every((function(e){return e.type==="comment"}))){this.spaces=this.optionalSpace(e);this.position++}else if(this.position===this.tokens.length-1||this.nextToken[g.FIELDS.TYPE]===T.comma||this.nextToken[g.FIELDS.TYPE]===T.closeParenthesis){this.current.last.spaces.after=this.optionalSpace(e);this.position++}else{this.combinator()}};e.string=function string(){var e=this.currToken;this.newNode(new f.default({value:this.content(),source:getTokenSource(e),sourceIndex:e[g.FIELDS.START_POS]}));this.position++};e.universal=function universal(e){var t=this.nextToken;if(t&&this.content(t)==="|"){this.position++;return this.namespace()}var r=this.currToken;this.newNode(new d.default({value:this.content(),source:getTokenSource(r),sourceIndex:r[g.FIELDS.START_POS]}),e);this.position++};e.splitWord=function splitWord(e,t){var r=this;var i=this.nextToken;var a=this.content();while(i&&~[T.dollar,T.caret,T.equals,T.word].indexOf(i[g.FIELDS.TYPE])){this.position++;var u=this.content();a+=u;if(u.lastIndexOf("\\")===u.length-1){var f=this.nextToken;if(f&&f[g.FIELDS.TYPE]===T.space){a+=this.requiredSpace(this.content(f));this.position++}}i=this.nextToken}var p=(0,n.default)(a,".").filter((function(e){return a[e-1]!=="\\"}));var h=(0,n.default)(a,"#").filter((function(e){return a[e-1]!=="\\"}));var d=(0,n.default)(a,"#{");if(d.length){h=h.filter((function(e){return!~d.indexOf(e)}))}var v=(0,S.default)((0,s.default)([0].concat(p,h)));v.forEach((function(n,s){var i=v[s+1]||a.length;var u=a.slice(n,i);if(s===0&&t){return t.call(r,u,v.length)}var f;var d=r.currToken;var _=d[g.FIELDS.START_POS]+v[s];var S=getSource(d[1],d[2]+n,d[3],d[2]+(i-1));if(~p.indexOf(n)){var T={value:u.slice(1),source:S,sourceIndex:_};f=new o.default(unescapeProp(T,"value"))}else if(~h.indexOf(n)){var w={value:u.slice(1),source:S,sourceIndex:_};f=new c.default(unescapeProp(w,"value"))}else{var m={value:u,source:S,sourceIndex:_};unescapeProp(m,"value");f=new l.default(m)}r.newNode(f,e);e=null}));this.position++};e.word=function word(e){var t=this.nextToken;if(t&&this.content(t)==="|"){this.position++;return this.namespace()}return this.splitWord(e)};e.loop=function loop(){while(this.position<this.tokens.length){this.parse(true)}this.current._inferEndPosition();return this.root};e.parse=function parse(e){switch(this.currToken[g.FIELDS.TYPE]){case T.space:this.space();break;case T.comment:this.comment();break;case T.openParenthesis:this.parentheses();break;case T.closeParenthesis:if(e){this.missingParenthesis()}break;case T.openSquare:this.attribute();break;case T.dollar:case T.caret:case T.equals:case T.word:this.word();break;case T.colon:this.pseudo();break;case T.comma:this.comma();break;case T.asterisk:this.universal();break;case T.ampersand:this.nesting();break;case T.slash:case T.combinator:this.combinator();break;case T.str:this.string();break;case T.closeSquare:this.missingSquareBracket();case T.semicolon:this.missingBackslash();default:this.unexpected()}};e.expected=function expected(e,t,r){if(Array.isArray(e)){var n=e.pop();e=e.join(", ")+" or "+n}var s=/^[aeiou]/.test(e[0])?"an":"a";if(!r){return this.error("Expected "+s+" "+e+".",{index:t})}return this.error("Expected "+s+" "+e+', found "'+r+'" instead.',{index:t})};e.requiredSpace=function requiredSpace(e){return this.options.lossy?" ":e};e.optionalSpace=function optionalSpace(e){return this.options.lossy?"":e};e.lossySpace=function lossySpace(e,t){if(this.options.lossy){return t?" ":""}else{return e}};e.parseParenthesisToken=function parseParenthesisToken(e){var t=this.content(e);if(e[g.FIELDS.TYPE]===T.space){return this.requiredSpace(t)}else{return t}};e.newNode=function newNode(e,t){if(t){if(/^ +$/.test(t)){if(!this.options.lossy){this.spaces=(this.spaces||"")+t}t=true}e.namespace=t;unescapeProp(e,"namespace")}if(this.spaces){e.spaces.before=this.spaces;this.spaces=""}return this.current.append(e)};e.content=function content(e){if(e===void 0){e=this.currToken}return this.css.slice(e[g.FIELDS.START_POS],e[g.FIELDS.END_POS])};e.locateNextMeaningfulToken=function locateNextMeaningfulToken(e){if(e===void 0){e=this.position+1}var t=e;while(t<this.tokens.length){if(y[this.tokens[t][g.FIELDS.TYPE]]){t++;continue}else{return t}}return-1};_createClass(Parser,[{key:"currToken",get:function get(){return this.tokens[this.position]}},{key:"nextToken",get:function get(){return this.tokens[this.position+1]}},{key:"prevToken",get:function get(){return this.tokens[this.position-1]}}]);return Parser}();t["default"]=P;e.exports=t.default},780:(e,t,r)=>{"use strict";t.__esModule=true;t["default"]=void 0;var n=_interopRequireDefault(r(629));function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}var s=function(){function Processor(e,t){this.func=e||function noop(){};this.funcRes=null;this.options=t}var e=Processor.prototype;e._shouldUpdateSelector=function _shouldUpdateSelector(e,t){if(t===void 0){t={}}var r=Object.assign({},this.options,t);if(r.updateSelector===false){return false}else{return typeof e!=="string"}};e._isLossy=function _isLossy(e){if(e===void 0){e={}}var t=Object.assign({},this.options,e);if(t.lossless===false){return true}else{return false}};e._root=function _root(e,t){if(t===void 0){t={}}var r=new n.default(e,this._parseOptions(t));return r.root};e._parseOptions=function _parseOptions(e){return{lossy:this._isLossy(e)}};e._run=function _run(e,t){var r=this;if(t===void 0){t={}}return new Promise((function(n,s){try{var i=r._root(e,t);Promise.resolve(r.func(i)).then((function(n){var s=undefined;if(r._shouldUpdateSelector(e,t)){s=i.toString();e.selector=s}return{transform:n,root:i,string:s}})).then(n,s)}catch(e){s(e);return}}))};e._runSync=function _runSync(e,t){if(t===void 0){t={}}var r=this._root(e,t);var n=this.func(r);if(n&&typeof n.then==="function"){throw new Error("Selector processor returned a promise to a synchronous call.")}var s=undefined;if(t.updateSelector&&typeof e!=="string"){s=r.toString();e.selector=s}return{transform:n,root:r,string:s}};e.ast=function ast(e,t){return this._run(e,t).then((function(e){return e.root}))};e.astSync=function astSync(e,t){return this._runSync(e,t).root};e.transform=function transform(e,t){return this._run(e,t).then((function(e){return e.transform}))};e.transformSync=function transformSync(e,t){return this._runSync(e,t).transform};e.process=function process(e,t){return this._run(e,t).then((function(e){return e.string||e.root.toString()}))};e.processSync=function processSync(e,t){var r=this._runSync(e,t);return r.string||r.root.toString()};return Processor}();t["default"]=s;e.exports=t.default},196:(e,t,r)=>{"use strict";t.__esModule=true;t.unescapeValue=unescapeValue;t["default"]=void 0;var n=_interopRequireDefault(r(316));var s=_interopRequireDefault(r(753));var i=_interopRequireDefault(r(285));var a=r(469);var o;function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function _defineProperties(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||false;n.configurable=true;if("value"in n)n.writable=true;Object.defineProperty(e,n.key,n)}}function _createClass(e,t,r){if(t)_defineProperties(e.prototype,t);if(r)_defineProperties(e,r);return e}function _inheritsLoose(e,t){e.prototype=Object.create(t.prototype);e.prototype.constructor=e;e.__proto__=t}var u=r(209);var c=/^('|")(.*)\1$/;var l=u((function(){}),"Assigning an attribute a value containing characters that might need to be escaped is deprecated. "+"Call attribute.setValue() instead.");var f=u((function(){}),"Assigning attr.quoted is deprecated and has no effect. Assign to attr.quoteMark instead.");var p=u((function(){}),"Constructing an Attribute selector with a value without specifying quoteMark is deprecated. Note: The value should be unescaped now.");function unescapeValue(e){var t=false;var r=null;var n=e;var i=n.match(c);if(i){r=i[1];n=i[2]}n=(0,s.default)(n);if(n!==e){t=true}return{deprecatedUsage:t,unescaped:n,quoteMark:r}}function handleDeprecatedContructorOpts(e){if(e.quoteMark!==undefined){return e}if(e.value===undefined){return e}p();var t=unescapeValue(e.value),r=t.quoteMark,n=t.unescaped;if(!e.raws){e.raws={}}if(e.raws.value===undefined){e.raws.value=e.value}e.value=n;e.quoteMark=r;return e}var h=function(e){_inheritsLoose(Attribute,e);function Attribute(t){var r;if(t===void 0){t={}}r=e.call(this,handleDeprecatedContructorOpts(t))||this;r.type=a.ATTRIBUTE;r.raws=r.raws||{};Object.defineProperty(r.raws,"unquoted",{get:u((function(){return r.value}),"attr.raws.unquoted is deprecated. Call attr.value instead."),set:u((function(){return r.value}),"Setting attr.raws.unquoted is deprecated and has no effect. attr.value is unescaped by default now.")});r._constructed=true;return r}var t=Attribute.prototype;t.getQuotedValue=function getQuotedValue(e){if(e===void 0){e={}}var t=this._determineQuoteMark(e);var r=d[t];var s=(0,n.default)(this._value,r);return s};t._determineQuoteMark=function _determineQuoteMark(e){return e.smart?this.smartQuoteMark(e):this.preferredQuoteMark(e)};t.setValue=function setValue(e,t){if(t===void 0){t={}}this._value=e;this._quoteMark=this._determineQuoteMark(t);this._syncRawValue()};t.smartQuoteMark=function smartQuoteMark(e){var t=this.value;var r=t.replace(/[^']/g,"").length;var s=t.replace(/[^"]/g,"").length;if(r+s===0){var i=(0,n.default)(t,{isIdentifier:true});if(i===t){return Attribute.NO_QUOTE}else{var a=this.preferredQuoteMark(e);if(a===Attribute.NO_QUOTE){var o=this.quoteMark||e.quoteMark||Attribute.DOUBLE_QUOTE;var u=d[o];var c=(0,n.default)(t,u);if(c.length<i.length){return o}}return a}}else if(s===r){return this.preferredQuoteMark(e)}else if(s<r){return Attribute.DOUBLE_QUOTE}else{return Attribute.SINGLE_QUOTE}};t.preferredQuoteMark=function preferredQuoteMark(e){var t=e.preferCurrentQuoteMark?this.quoteMark:e.quoteMark;if(t===undefined){t=e.preferCurrentQuoteMark?e.quoteMark:this.quoteMark}if(t===undefined){t=Attribute.DOUBLE_QUOTE}return t};t._syncRawValue=function _syncRawValue(){var e=(0,n.default)(this._value,d[this.quoteMark]);if(e===this._value){if(this.raws){delete this.raws.value}}else{this.raws.value=e}};t._handleEscapes=function _handleEscapes(e,t){if(this._constructed){var r=(0,n.default)(t,{isIdentifier:true});if(r!==t){this.raws[e]=r}else{delete this.raws[e]}}};t._spacesFor=function _spacesFor(e){var t={before:"",after:""};var r=this.spaces[e]||{};var n=this.raws.spaces&&this.raws.spaces[e]||{};return Object.assign(t,r,n)};t._stringFor=function _stringFor(e,t,r){if(t===void 0){t=e}if(r===void 0){r=defaultAttrConcat}var n=this._spacesFor(t);return r(this.stringifyProperty(e),n)};t.offsetOf=function offsetOf(e){var t=1;var r=this._spacesFor("attribute");t+=r.before.length;if(e==="namespace"||e==="ns"){return this.namespace?t:-1}if(e==="attributeNS"){return t}t+=this.namespaceString.length;if(this.namespace){t+=1}if(e==="attribute"){return t}t+=this.stringifyProperty("attribute").length;t+=r.after.length;var n=this._spacesFor("operator");t+=n.before.length;var s=this.stringifyProperty("operator");if(e==="operator"){return s?t:-1}t+=s.length;t+=n.after.length;var i=this._spacesFor("value");t+=i.before.length;var a=this.stringifyProperty("value");if(e==="value"){return a?t:-1}t+=a.length;t+=i.after.length;var o=this._spacesFor("insensitive");t+=o.before.length;if(e==="insensitive"){return this.insensitive?t:-1}return-1};t.toString=function toString(){var e=this;var t=[this.rawSpaceBefore,"["];t.push(this._stringFor("qualifiedAttribute","attribute"));if(this.operator&&(this.value||this.value==="")){t.push(this._stringFor("operator"));t.push(this._stringFor("value"));t.push(this._stringFor("insensitiveFlag","insensitive",(function(t,r){if(t.length>0&&!e.quoted&&r.before.length===0&&!(e.spaces.value&&e.spaces.value.after)){r.before=" "}return defaultAttrConcat(t,r)})))}t.push("]");t.push(this.rawSpaceAfter);return t.join("")};_createClass(Attribute,[{key:"quoted",get:function get(){var e=this.quoteMark;return e==="'"||e==='"'},set:function set(e){f()}},{key:"quoteMark",get:function get(){return this._quoteMark},set:function set(e){if(!this._constructed){this._quoteMark=e;return}if(this._quoteMark!==e){this._quoteMark=e;this._syncRawValue()}}},{key:"qualifiedAttribute",get:function get(){return this.qualifiedName(this.raws.attribute||this.attribute)}},{key:"insensitiveFlag",get:function get(){return this.insensitive?"i":""}},{key:"value",get:function get(){return this._value},set:function set(e){if(this._constructed){var t=unescapeValue(e),r=t.deprecatedUsage,n=t.unescaped,s=t.quoteMark;if(r){l()}if(n===this._value&&s===this._quoteMark){return}this._value=n;this._quoteMark=s;this._syncRawValue()}else{this._value=e}}},{key:"attribute",get:function get(){return this._attribute},set:function set(e){this._handleEscapes("attribute",e);this._attribute=e}}]);return Attribute}(i.default);t["default"]=h;h.NO_QUOTE=null;h.SINGLE_QUOTE="'";h.DOUBLE_QUOTE='"';var d=(o={"'":{quotes:"single",wrap:true},'"':{quotes:"double",wrap:true}},o[null]={isIdentifier:true},o);function defaultAttrConcat(e,t){return""+t.before+e+t.after}},717:(e,t,r)=>{"use strict";t.__esModule=true;t["default"]=void 0;var n=_interopRequireDefault(r(316));var s=r(843);var i=_interopRequireDefault(r(814));var a=r(469);function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function _defineProperties(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||false;n.configurable=true;if("value"in n)n.writable=true;Object.defineProperty(e,n.key,n)}}function _createClass(e,t,r){if(t)_defineProperties(e.prototype,t);if(r)_defineProperties(e,r);return e}function _inheritsLoose(e,t){e.prototype=Object.create(t.prototype);e.prototype.constructor=e;e.__proto__=t}var o=function(e){_inheritsLoose(ClassName,e);function ClassName(t){var r;r=e.call(this,t)||this;r.type=a.CLASS;r._constructed=true;return r}var t=ClassName.prototype;t.valueToString=function valueToString(){return"."+e.prototype.valueToString.call(this)};_createClass(ClassName,[{key:"value",set:function set(e){if(this._constructed){var t=(0,n.default)(e,{isIdentifier:true});if(t!==e){(0,s.ensureObject)(this,"raws");this.raws.value=t}else if(this.raws){delete this.raws.value}}this._value=e},get:function get(){return this._value}}]);return ClassName}(i.default);t["default"]=o;e.exports=t.default},604:(e,t,r)=>{"use strict";t.__esModule=true;t["default"]=void 0;var n=_interopRequireDefault(r(814));var s=r(469);function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function _inheritsLoose(e,t){e.prototype=Object.create(t.prototype);e.prototype.constructor=e;e.__proto__=t}var i=function(e){_inheritsLoose(Combinator,e);function Combinator(t){var r;r=e.call(this,t)||this;r.type=s.COMBINATOR;return r}return Combinator}(n.default);t["default"]=i;e.exports=t.default},786:(e,t,r)=>{"use strict";t.__esModule=true;t["default"]=void 0;var n=_interopRequireDefault(r(814));var s=r(469);function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function _inheritsLoose(e,t){e.prototype=Object.create(t.prototype);e.prototype.constructor=e;e.__proto__=t}var i=function(e){_inheritsLoose(Comment,e);function Comment(t){var r;r=e.call(this,t)||this;r.type=s.COMMENT;return r}return Comment}(n.default);t["default"]=i;e.exports=t.default},842:(e,t,r)=>{"use strict";t.__esModule=true;t.universal=t.tag=t.string=t.selector=t.root=t.pseudo=t.nesting=t.id=t.comment=t.combinator=t.className=t.attribute=void 0;var n=_interopRequireDefault(r(196));var s=_interopRequireDefault(r(717));var i=_interopRequireDefault(r(604));var a=_interopRequireDefault(r(786));var o=_interopRequireDefault(r(486));var u=_interopRequireDefault(r(359));var c=_interopRequireDefault(r(585));var l=_interopRequireDefault(r(4));var f=_interopRequireDefault(r(561));var p=_interopRequireDefault(r(307));var h=_interopRequireDefault(r(574));var d=_interopRequireDefault(r(382));function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}var v=function attribute(e){return new n.default(e)};t.attribute=v;var _=function className(e){return new s.default(e)};t.className=_;var S=function combinator(e){return new i.default(e)};t.combinator=S;var g=function comment(e){return new a.default(e)};t.comment=g;var T=function id(e){return new o.default(e)};t.id=T;var w=function nesting(e){return new u.default(e)};t.nesting=w;var m=function pseudo(e){return new c.default(e)};t.pseudo=m;var b=function root(e){return new l.default(e)};t.root=b;var k=function selector(e){return new f.default(e)};t.selector=k;var E=function string(e){return new p.default(e)};t.string=E;var y=function tag(e){return new h.default(e)};t.tag=y;var P=function universal(e){return new d.default(e)};t.universal=P},554:(e,t,r)=>{"use strict";t.__esModule=true;t["default"]=void 0;var n=_interopRequireDefault(r(814));var s=_interopRequireWildcard(r(469));function _interopRequireWildcard(e){if(e&&e.__esModule){return e}else{var t={};if(e!=null){for(var r in e){if(Object.prototype.hasOwnProperty.call(e,r)){var n=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(e,r):{};if(n.get||n.set){Object.defineProperty(t,r,n)}else{t[r]=e[r]}}}}t.default=e;return t}}function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function _defineProperties(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||false;n.configurable=true;if("value"in n)n.writable=true;Object.defineProperty(e,n.key,n)}}function _createClass(e,t,r){if(t)_defineProperties(e.prototype,t);if(r)_defineProperties(e,r);return e}function _inheritsLoose(e,t){e.prototype=Object.create(t.prototype);e.prototype.constructor=e;e.__proto__=t}var i=function(e){_inheritsLoose(Container,e);function Container(t){var r;r=e.call(this,t)||this;if(!r.nodes){r.nodes=[]}return r}var t=Container.prototype;t.append=function append(e){e.parent=this;this.nodes.push(e);return this};t.prepend=function prepend(e){e.parent=this;this.nodes.unshift(e);return this};t.at=function at(e){return this.nodes[e]};t.index=function index(e){if(typeof e==="number"){return e}return this.nodes.indexOf(e)};t.removeChild=function removeChild(e){e=this.index(e);this.at(e).parent=undefined;this.nodes.splice(e,1);var t;for(var r in this.indexes){t=this.indexes[r];if(t>=e){this.indexes[r]=t-1}}return this};t.removeAll=function removeAll(){for(var e=this.nodes,t=Array.isArray(e),r=0,e=t?e:e[Symbol.iterator]();;){var n;if(t){if(r>=e.length)break;n=e[r++]}else{r=e.next();if(r.done)break;n=r.value}var s=n;s.parent=undefined}this.nodes=[];return this};t.empty=function empty(){return this.removeAll()};t.insertAfter=function insertAfter(e,t){t.parent=this;var r=this.index(e);this.nodes.splice(r+1,0,t);t.parent=this;var n;for(var s in this.indexes){n=this.indexes[s];if(r<=n){this.indexes[s]=n+1}}return this};t.insertBefore=function insertBefore(e,t){t.parent=this;var r=this.index(e);this.nodes.splice(r,0,t);t.parent=this;var n;for(var s in this.indexes){n=this.indexes[s];if(n<=r){this.indexes[s]=n+1}}return this};t._findChildAtPosition=function _findChildAtPosition(e,t){var r=undefined;this.each((function(n){if(n.atPosition){var s=n.atPosition(e,t);if(s){r=s;return false}}else if(n.isAtPosition(e,t)){r=n;return false}}));return r};t.atPosition=function atPosition(e,t){if(this.isAtPosition(e,t)){return this._findChildAtPosition(e,t)||this}else{return undefined}};t._inferEndPosition=function _inferEndPosition(){if(this.last&&this.last.source&&this.last.source.end){this.source=this.source||{};this.source.end=this.source.end||{};Object.assign(this.source.end,this.last.source.end)}};t.each=function each(e){if(!this.lastEach){this.lastEach=0}if(!this.indexes){this.indexes={}}this.lastEach++;var t=this.lastEach;this.indexes[t]=0;if(!this.length){return undefined}var r,n;while(this.indexes[t]<this.length){r=this.indexes[t];n=e(this.at(r),r);if(n===false){break}this.indexes[t]+=1}delete this.indexes[t];if(n===false){return false}};t.walk=function walk(e){return this.each((function(t,r){var n=e(t,r);if(n!==false&&t.length){n=t.walk(e)}if(n===false){return false}}))};t.walkAttributes=function walkAttributes(e){var t=this;return this.walk((function(r){if(r.type===s.ATTRIBUTE){return e.call(t,r)}}))};t.walkClasses=function walkClasses(e){var t=this;return this.walk((function(r){if(r.type===s.CLASS){return e.call(t,r)}}))};t.walkCombinators=function walkCombinators(e){var t=this;return this.walk((function(r){if(r.type===s.COMBINATOR){return e.call(t,r)}}))};t.walkComments=function walkComments(e){var t=this;return this.walk((function(r){if(r.type===s.COMMENT){return e.call(t,r)}}))};t.walkIds=function walkIds(e){var t=this;return this.walk((function(r){if(r.type===s.ID){return e.call(t,r)}}))};t.walkNesting=function walkNesting(e){var t=this;return this.walk((function(r){if(r.type===s.NESTING){return e.call(t,r)}}))};t.walkPseudos=function walkPseudos(e){var t=this;return this.walk((function(r){if(r.type===s.PSEUDO){return e.call(t,r)}}))};t.walkTags=function walkTags(e){var t=this;return this.walk((function(r){if(r.type===s.TAG){return e.call(t,r)}}))};t.walkUniversals=function walkUniversals(e){var t=this;return this.walk((function(r){if(r.type===s.UNIVERSAL){return e.call(t,r)}}))};t.split=function split(e){var t=this;var r=[];return this.reduce((function(n,s,i){var a=e.call(t,s);r.push(s);if(a){n.push(r);r=[]}else if(i===t.length-1){n.push(r)}return n}),[])};t.map=function map(e){return this.nodes.map(e)};t.reduce=function reduce(e,t){return this.nodes.reduce(e,t)};t.every=function every(e){return this.nodes.every(e)};t.some=function some(e){return this.nodes.some(e)};t.filter=function filter(e){return this.nodes.filter(e)};t.sort=function sort(e){return this.nodes.sort(e)};t.toString=function toString(){return this.map(String).join("")};_createClass(Container,[{key:"first",get:function get(){return this.at(0)}},{key:"last",get:function get(){return this.at(this.length-1)}},{key:"length",get:function get(){return this.nodes.length}}]);return Container}(n.default);t["default"]=i;e.exports=t.default},191:(e,t,r)=>{"use strict";t.__esModule=true;t.isNode=isNode;t.isPseudoElement=isPseudoElement;t.isPseudoClass=isPseudoClass;t.isContainer=isContainer;t.isNamespace=isNamespace;t.isUniversal=t.isTag=t.isString=t.isSelector=t.isRoot=t.isPseudo=t.isNesting=t.isIdentifier=t.isComment=t.isCombinator=t.isClassName=t.isAttribute=void 0;var n=r(469);var s;var i=(s={},s[n.ATTRIBUTE]=true,s[n.CLASS]=true,s[n.COMBINATOR]=true,s[n.COMMENT]=true,s[n.ID]=true,s[n.NESTING]=true,s[n.PSEUDO]=true,s[n.ROOT]=true,s[n.SELECTOR]=true,s[n.STRING]=true,s[n.TAG]=true,s[n.UNIVERSAL]=true,s);function isNode(e){return typeof e==="object"&&i[e.type]}function isNodeType(e,t){return isNode(t)&&t.type===e}var a=isNodeType.bind(null,n.ATTRIBUTE);t.isAttribute=a;var o=isNodeType.bind(null,n.CLASS);t.isClassName=o;var u=isNodeType.bind(null,n.COMBINATOR);t.isCombinator=u;var c=isNodeType.bind(null,n.COMMENT);t.isComment=c;var l=isNodeType.bind(null,n.ID);t.isIdentifier=l;var f=isNodeType.bind(null,n.NESTING);t.isNesting=f;var p=isNodeType.bind(null,n.PSEUDO);t.isPseudo=p;var h=isNodeType.bind(null,n.ROOT);t.isRoot=h;var d=isNodeType.bind(null,n.SELECTOR);t.isSelector=d;var v=isNodeType.bind(null,n.STRING);t.isString=v;var _=isNodeType.bind(null,n.TAG);t.isTag=_;var S=isNodeType.bind(null,n.UNIVERSAL);t.isUniversal=S;function isPseudoElement(e){return p(e)&&e.value&&(e.value.startsWith("::")||e.value.toLowerCase()===":before"||e.value.toLowerCase()===":after")}function isPseudoClass(e){return p(e)&&!isPseudoElement(e)}function isContainer(e){return!!(isNode(e)&&e.walk)}function isNamespace(e){return a(e)||_(e)}},486:(e,t,r)=>{"use strict";t.__esModule=true;t["default"]=void 0;var n=_interopRequireDefault(r(814));var s=r(469);function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function _inheritsLoose(e,t){e.prototype=Object.create(t.prototype);e.prototype.constructor=e;e.__proto__=t}var i=function(e){_inheritsLoose(ID,e);function ID(t){var r;r=e.call(this,t)||this;r.type=s.ID;return r}var t=ID.prototype;t.valueToString=function valueToString(){return"#"+e.prototype.valueToString.call(this)};return ID}(n.default);t["default"]=i;e.exports=t.default},627:(e,t,r)=>{"use strict";t.__esModule=true;var n=r(469);Object.keys(n).forEach((function(e){if(e==="default"||e==="__esModule")return;t[e]=n[e]}));var s=r(842);Object.keys(s).forEach((function(e){if(e==="default"||e==="__esModule")return;t[e]=s[e]}));var i=r(191);Object.keys(i).forEach((function(e){if(e==="default"||e==="__esModule")return;t[e]=i[e]}))},285:(e,t,r)=>{"use strict";t.__esModule=true;t["default"]=void 0;var n=_interopRequireDefault(r(316));var s=r(843);var i=_interopRequireDefault(r(814));function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function _defineProperties(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||false;n.configurable=true;if("value"in n)n.writable=true;Object.defineProperty(e,n.key,n)}}function _createClass(e,t,r){if(t)_defineProperties(e.prototype,t);if(r)_defineProperties(e,r);return e}function _inheritsLoose(e,t){e.prototype=Object.create(t.prototype);e.prototype.constructor=e;e.__proto__=t}var a=function(e){_inheritsLoose(Namespace,e);function Namespace(){return e.apply(this,arguments)||this}var t=Namespace.prototype;t.qualifiedName=function qualifiedName(e){if(this.namespace){return this.namespaceString+"|"+e}else{return e}};t.valueToString=function valueToString(){return this.qualifiedName(e.prototype.valueToString.call(this))};_createClass(Namespace,[{key:"namespace",get:function get(){return this._namespace},set:function set(e){if(e===true||e==="*"||e==="&"){this._namespace=e;if(this.raws){delete this.raws.namespace}return}var t=(0,n.default)(e,{isIdentifier:true});this._namespace=e;if(t!==e){(0,s.ensureObject)(this,"raws");this.raws.namespace=t}else if(this.raws){delete this.raws.namespace}}},{key:"ns",get:function get(){return this._namespace},set:function set(e){this.namespace=e}},{key:"namespaceString",get:function get(){if(this.namespace){var e=this.stringifyProperty("namespace");if(e===true){return""}else{return e}}else{return""}}}]);return Namespace}(i.default);t["default"]=a;e.exports=t.default},359:(e,t,r)=>{"use strict";t.__esModule=true;t["default"]=void 0;var n=_interopRequireDefault(r(814));var s=r(469);function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function _inheritsLoose(e,t){e.prototype=Object.create(t.prototype);e.prototype.constructor=e;e.__proto__=t}var i=function(e){_inheritsLoose(Nesting,e);function Nesting(t){var r;r=e.call(this,t)||this;r.type=s.NESTING;r.value="&";return r}return Nesting}(n.default);t["default"]=i;e.exports=t.default},814:(e,t,r)=>{"use strict";t.__esModule=true;t["default"]=void 0;var n=r(843);function _defineProperties(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||false;n.configurable=true;if("value"in n)n.writable=true;Object.defineProperty(e,n.key,n)}}function _createClass(e,t,r){if(t)_defineProperties(e.prototype,t);if(r)_defineProperties(e,r);return e}var s=function cloneNode(e,t){if(typeof e!=="object"||e===null){return e}var r=new e.constructor;for(var n in e){if(!e.hasOwnProperty(n)){continue}var s=e[n];var i=typeof s;if(n==="parent"&&i==="object"){if(t){r[n]=t}}else if(s instanceof Array){r[n]=s.map((function(e){return cloneNode(e,r)}))}else{r[n]=cloneNode(s,r)}}return r};var i=function(){function Node(e){if(e===void 0){e={}}Object.assign(this,e);this.spaces=this.spaces||{};this.spaces.before=this.spaces.before||"";this.spaces.after=this.spaces.after||""}var e=Node.prototype;e.remove=function remove(){if(this.parent){this.parent.removeChild(this)}this.parent=undefined;return this};e.replaceWith=function replaceWith(){if(this.parent){for(var e in arguments){this.parent.insertBefore(this,arguments[e])}this.remove()}return this};e.next=function next(){return this.parent.at(this.parent.index(this)+1)};e.prev=function prev(){return this.parent.at(this.parent.index(this)-1)};e.clone=function clone(e){if(e===void 0){e={}}var t=s(this);for(var r in e){t[r]=e[r]}return t};e.appendToPropertyAndEscape=function appendToPropertyAndEscape(e,t,r){if(!this.raws){this.raws={}}var n=this[e];var s=this.raws[e];this[e]=n+t;if(s||r!==t){this.raws[e]=(s||n)+r}else{delete this.raws[e]}};e.setPropertyAndEscape=function setPropertyAndEscape(e,t,r){if(!this.raws){this.raws={}}this[e]=t;this.raws[e]=r};e.setPropertyWithoutEscape=function setPropertyWithoutEscape(e,t){this[e]=t;if(this.raws){delete this.raws[e]}};e.isAtPosition=function isAtPosition(e,t){if(this.source&&this.source.start&&this.source.end){if(this.source.start.line>e){return false}if(this.source.end.line<e){return false}if(this.source.start.line===e&&this.source.start.column>t){return false}if(this.source.end.line===e&&thi