rsnext/packages/next/compiled/resolve-url-loader/engine/rework.js
2021-01-19 20:08:24 +00:00

1 line
No EOL
28 KiB
JavaScript
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

module.exports=(()=>{var e={327:e=>{"use strict";function atob(e){return Buffer.from(e,"base64").toString("binary")}e.exports=atob.atob=atob},301:(e,t,r)=>{"use strict";var n=r(747);var o=r(622);var i=r(401);Object.defineProperty(t,"commentRegex",{get:function getCommentRegex(){return/^\s*\/(?:\/|\*)[@#]\s+sourceMappingURL=data:(?:application|text)\/json;(?:charset[:=]\S+?;)?base64,(?:.*)$/gm}});Object.defineProperty(t,"mapFileCommentRegex",{get:function getMapFileCommentRegex(){return/(?:\/\/[@#][ \t]+sourceMappingURL=([^\s'"`]+?)[ \t]*$)|(?:\/\*[@#][ \t]+sourceMappingURL=([^\*]+?)[ \t]*(?:\*\/){1}[ \t]*$)/gm}});function decodeBase64(e){return i.Buffer.from(e,"base64").toString()}function stripComment(e){return e.split(",").pop()}function readFromFileMap(e,r){var i=t.mapFileCommentRegex.exec(e);var s=i[1]||i[2];var u=o.resolve(r,s);try{return n.readFileSync(u,"utf8")}catch(e){throw new Error("An error occurred while trying to read the map file at "+u+"\n"+e)}}function Converter(e,t){t=t||{};if(t.isFileComment)e=readFromFileMap(e,t.commentFileDir);if(t.hasComment)e=stripComment(e);if(t.isEncoded)e=decodeBase64(e);if(t.isJSON||t.isEncoded)e=JSON.parse(e);this.sourcemap=e}Converter.prototype.toJSON=function(e){return JSON.stringify(this.sourcemap,null,e)};Converter.prototype.toBase64=function(){var e=this.toJSON();return i.Buffer.from(e,"utf8").toString("base64")};Converter.prototype.toComment=function(e){var t=this.toBase64();var r="sourceMappingURL=data:application/json;charset=utf-8;base64,"+t;return e&&e.multiline?"/*# "+r+" */":"//# "+r};Converter.prototype.toObject=function(){return JSON.parse(this.toJSON())};Converter.prototype.addProperty=function(e,t){if(this.sourcemap.hasOwnProperty(e))throw new Error('property "'+e+'" already exists on the sourcemap, use set property instead');return this.setProperty(e,t)};Converter.prototype.setProperty=function(e,t){this.sourcemap[e]=t;return this};Converter.prototype.getProperty=function(e){return this.sourcemap[e]};t.fromObject=function(e){return new Converter(e)};t.fromJSON=function(e){return new Converter(e,{isJSON:true})};t.fromBase64=function(e){return new Converter(e,{isEncoded:true})};t.fromComment=function(e){e=e.replace(/^\/\*/g,"//").replace(/\*\/$/g,"");return new Converter(e,{isEncoded:true,hasComment:true})};t.fromMapFileComment=function(e,t){return new Converter(e,{commentFileDir:t,isFileComment:true,isJSON:true})};t.fromSource=function(e){var r=e.match(t.commentRegex);return r?t.fromComment(r.pop()):null};t.fromMapFileSource=function(e,r){var n=e.match(t.mapFileCommentRegex);return n?t.fromMapFileComment(n.pop(),r):null};t.removeComments=function(e){return e.replace(t.commentRegex,"")};t.removeMapFileComments=function(e){return e.replace(t.mapFileCommentRegex,"")};t.generateMapFileComment=function(e,t){var r="sourceMappingURL="+e;return t&&t.multiline?"/*# "+r+" */":"//# "+r}},401:(e,t,r)=>{var n=r(293);var o=n.Buffer;function copyProps(e,t){for(var r in e){t[r]=e[r]}}if(o.from&&o.alloc&&o.allocUnsafe&&o.allocUnsafeSlow){e.exports=n}else{copyProps(n,t);t.Buffer=SafeBuffer}function SafeBuffer(e,t,r){return o(e,t,r)}copyProps(o,SafeBuffer);SafeBuffer.from=function(e,t,r){if(typeof e==="number"){throw new TypeError("Argument must not be a number")}return o(e,t,r)};SafeBuffer.alloc=function(e,t,r){if(typeof e!=="number"){throw new TypeError("Argument must be a number")}var n=o(e);if(t!==undefined){if(typeof r==="string"){n.fill(t,r)}else{n.fill(t)}}else{n.fill(0)}return n};SafeBuffer.allocUnsafe=function(e){if(typeof e!=="number"){throw new TypeError("Argument must be a number")}return o(e)};SafeBuffer.allocUnsafeSlow=function(e){if(typeof e!=="number"){throw new TypeError("Argument must be a number")}return n.SlowBuffer(e)}},748:e=>{"use strict";var t="%[a-f0-9]{2}";var r=new RegExp(t,"gi");var n=new RegExp("("+t+")+","gi");function decodeComponents(e,t){try{return decodeURIComponent(e.join(""))}catch(e){}if(e.length===1){return e}t=t||1;var r=e.slice(0,t);var n=e.slice(t);return Array.prototype.concat.call([],decodeComponents(r),decodeComponents(n))}function decode(e){try{return decodeURIComponent(e)}catch(o){var t=e.match(r);for(var n=1;n<t.length;n++){e=decodeComponents(t,n).join("");t=e.match(r)}return e}}function customDecodeURIComponent(e){var t={"%FE%FF":"<22><>","%FF%FE":"<22><>"};var r=n.exec(e);while(r){try{t[r[0]]=decodeURIComponent(r[0])}catch(e){var o=decode(r[0]);if(o!==r[0]){t[r[0]]=o}}r=n.exec(e)}t["%C2"]="<22>";var i=Object.keys(t);for(var s=0;s<i.length;s++){var u=i[s];e=e.replace(new RegExp(u,"g"),t[u])}return e}e.exports=function(e){if(typeof e!=="string"){throw new TypeError("Expected `encodedURI` to be of type `string`, got `"+typeof e+"`")}try{e=e.replace(/\+/g," ");return decodeURIComponent(e)}catch(t){return customDecodeURIComponent(e)}}},989:(e,t,r)=>{try{var n=r(669);if(typeof n.inherits!=="function")throw"";e.exports=n.inherits}catch(t){e.exports=r(350)}},350:e=>{if(typeof Object.create==="function"){e.exports=function inherits(e,t){if(t){e.super_=t;e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:false,writable:true,configurable:true}})}}}else{e.exports=function inherits(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype;e.prototype=new r;e.prototype.constructor=e}}}},269:(e,t,r)=>{"use strict";var n=r(622),o=r(301),i=r(447),s=r(841);var u=r(95);function process(e,t,r){var a=t+(r.absSourceMap?o.fromObject(u.prepend(r.absSourceMap)).toComment({multiline:true}):"");var c=i(a,{source:u.prepend(e)}).use(reworkPlugin).toString({sourcemap:r.outputSourceMap,sourcemapAsObject:r.outputSourceMap});if(r.outputSourceMap){return{content:c.code,map:u.remove(c.map)}}else{return{content:c,map:null}}function reworkPlugin(e){s(e,function visitor(e){if(e){e.forEach(eachDeclaration)}});function eachDeclaration(e){var t=e.value&&e.value.indexOf("url")>=0;if(t){var o=e.position.start,i=r.sourceMapConsumer&&r.sourceMapConsumer.originalPositionFor(o);var s=i&&i.source&&u.remove(n.dirname(i.source));if(s){e.value=r.transformDeclaration(e.value,s)}else if(r.sourceMapConsumer){throw new Error("source-map information is not available at url() declaration")}}}}}e.exports=process},95:(e,t)=>{"use strict";function prepend(e){if(typeof e==="string"){return"file://"+e}else if(e&&typeof e==="object"&&Array.isArray(e.sources)){return Object.assign({},e,{sources:e.sources.map(prepend)})}else{throw new Error("expected string|object")}}t.prepend=prepend;function remove(e){if(typeof e==="string"){return e.replace(/^file:\/{2}/,"")}else if(e&&typeof e==="object"&&Array.isArray(e.sources)){return Object.assign({},e,{sources:e.sources.map(remove)})}else{throw new Error("expected string|object")}}t.remove=remove},841:e=>{e.exports=visit;function visit(e,t){e.rules.forEach(function(r){if(r.rules){visit(r,t);return}if(r.keyframes){r.keyframes.forEach(function(e){t(e.declarations,r)});return}if(!r.declarations)return;t(r.declarations,e)})}},447:(e,t,r)=>{var n=r(792);var o=r(462);var i=n.parse;var s=n.stringify;t=e.exports=rework;function rework(e,t){return new Rework(i(e,t))}function Rework(e){this.obj=e}Rework.prototype.use=function(e){e(this.obj.stylesheet,this);return this};Rework.prototype.toString=function(e){e=e||{};var t=s(this.obj,e);if(e.sourcemap&&!e.sourcemapAsObject){t=t.code+"\n"+sourcemapToComment(t.map)}return t};function sourcemapToComment(e){var t=o.fromObject(e).toBase64();return"/*# sourceMappingURL=data:application/json;base64,"+t+" */"}},462:(e,t,r)=>{"use strict";var n=r(747);var o=r(622);var i=/^[ \t]*(?:\/\/|\/\*)[@#][ \t]+sourceMappingURL=data:(?:application|text)\/json;base64,(.+)(?:\*\/)?/gm;var s=/(?:^[ \t]*\/\/[@|#][ \t]+sourceMappingURL=(.+?)[ \t]*$)|(?:^[ \t]*\/\*[@#][ \t]+sourceMappingURL=(.+?)[ \t]*\*\/[ \t]*$)/gm;function decodeBase64(e){return new Buffer(e,"base64").toString()}function stripComment(e){return e.split(",").pop()}function readFromFileMap(e,t){var r=s.exec(e);s.lastIndex=0;var i=r[1]||r[2];var u=o.join(t,i);try{return n.readFileSync(u,"utf8")}catch(e){throw new Error("An error occurred while trying to read the map file at "+u+"\n"+e)}}function Converter(e,t){t=t||{};try{if(t.isFileComment)e=readFromFileMap(e,t.commentFileDir);if(t.hasComment)e=stripComment(e);if(t.isEncoded)e=decodeBase64(e);if(t.isJSON||t.isEncoded)e=JSON.parse(e);this.sourcemap=e}catch(e){console.error(e);return null}}Converter.prototype.toJSON=function(e){return JSON.stringify(this.sourcemap,null,e)};Converter.prototype.toBase64=function(){var e=this.toJSON();return new Buffer(e).toString("base64")};Converter.prototype.toComment=function(){var e=this.toBase64();return"//# sourceMappingURL=data:application/json;base64,"+e};Converter.prototype.toObject=function(){return JSON.parse(this.toJSON())};Converter.prototype.addProperty=function(e,t){if(this.sourcemap.hasOwnProperty(e))throw new Error("property %s already exists on the sourcemap, use set property instead");return this.setProperty(e,t)};Converter.prototype.setProperty=function(e,t){this.sourcemap[e]=t;return this};Converter.prototype.getProperty=function(e){return this.sourcemap[e]};t.fromObject=function(e){return new Converter(e)};t.fromJSON=function(e){return new Converter(e,{isJSON:true})};t.fromBase64=function(e){return new Converter(e,{isEncoded:true})};t.fromComment=function(e){e=e.replace(/^\/\*/g,"//").replace(/\*\/$/g,"");return new Converter(e,{isEncoded:true,hasComment:true})};t.fromMapFileComment=function(e,t){return new Converter(e,{commentFileDir:t,isFileComment:true,isJSON:true})};t.fromSource=function(e){var r=e.match(i);i.lastIndex=0;return r?t.fromComment(r.pop()):null};t.fromMapFileSource=function(e,r){var n=e.match(s);s.lastIndex=0;return n?t.fromMapFileComment(n.pop(),r):null};t.removeComments=function(e){i.lastIndex=0;return e.replace(i,"")};t.removeMapFileComments=function(e){s.lastIndex=0;return e.replace(s,"")};t.__defineGetter__("commentRegex",function(){i.lastIndex=0;return i});t.__defineGetter__("mapFileCommentRegex",function(){s.lastIndex=0;return s})},792:(e,t,r)=>{t.parse=r(836);t.stringify=r(11)},836:e=>{var t=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g;e.exports=function(e,r){r=r||{};var n=1;var o=1;function updatePosition(e){var t=e.match(/\n/g);if(t)n+=t.length;var r=e.lastIndexOf("\n");o=~r?e.length-r:o+e.length}function position(){var e={line:n,column:o};return function(t){t.position=new Position(e);whitespace();return t}}function Position(e){this.start=e;this.end={line:n,column:o};this.source=r.source}Position.prototype.content=e;var i=[];function error(t){var s=new Error(r.source+":"+n+":"+o+": "+t);s.reason=t;s.filename=r.source;s.line=n;s.column=o;s.source=e;if(r.silent){i.push(s)}else{throw s}}function stylesheet(){var e=rules();return{type:"stylesheet",stylesheet:{source:r.source,rules:e,parsingErrors:i}}}function open(){return match(/^{\s*/)}function close(){return match(/^}/)}function rules(){var t;var r=[];whitespace();comments(r);while(e.length&&e.charAt(0)!="}"&&(t=atrule()||rule())){if(t!==false){r.push(t);comments(r)}}return r}function match(t){var r=t.exec(e);if(!r)return;var n=r[0];updatePosition(n);e=e.slice(n.length);return r}function whitespace(){match(/^\s*/)}function comments(e){var t;e=e||[];while(t=comment()){if(t!==false){e.push(t)}}return e}function comment(){var t=position();if("/"!=e.charAt(0)||"*"!=e.charAt(1))return;var r=2;while(""!=e.charAt(r)&&("*"!=e.charAt(r)||"/"!=e.charAt(r+1)))++r;r+=2;if(""===e.charAt(r-1)){return error("End of comment missing")}var n=e.slice(2,r-2);o+=2;updatePosition(n);e=e.slice(r);o+=2;return t({type:"comment",comment:n})}function selector(){var e=match(/^([^{]+)/);if(!e)return;return trim(e[0]).replace(/\/\*([^*]|[\r\n]|(\*+([^*/]|[\r\n])))*\*\/+/g,"").replace(/"(?:\\"|[^"])*"|'(?:\\'|[^'])*'/g,function(e){return e.replace(/,/g,"")}).split(/\s*(?![^(]*\)),\s*/).map(function(e){return e.replace(/\u200C/g,",")})}function declaration(){var e=position();var r=match(/^(\*?[-#\/\*\\\w]+(\[[0-9a-z_-]+\])?)\s*/);if(!r)return;r=trim(r[0]);if(!match(/^:\s*/))return error("property missing ':'");var n=match(/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^\)]*?\)|[^};])+)/);var o=e({type:"declaration",property:r.replace(t,""),value:n?trim(n[0]).replace(t,""):""});match(/^[;\s]*/);return o}function declarations(){var e=[];if(!open())return error("missing '{'");comments(e);var t;while(t=declaration()){if(t!==false){e.push(t);comments(e)}}if(!close())return error("missing '}'");return e}function keyframe(){var e;var t=[];var r=position();while(e=match(/^((\d+\.\d+|\.\d+|\d+)%?|[a-z]+)\s*/)){t.push(e[1]);match(/^,\s*/)}if(!t.length)return;return r({type:"keyframe",values:t,declarations:declarations()})}function atkeyframes(){var e=position();var t=match(/^@([-\w]+)?keyframes\s*/);if(!t)return;var r=t[1];var t=match(/^([-\w]+)\s*/);if(!t)return error("@keyframes missing name");var n=t[1];if(!open())return error("@keyframes missing '{'");var o;var i=comments();while(o=keyframe()){i.push(o);i=i.concat(comments())}if(!close())return error("@keyframes missing '}'");return e({type:"keyframes",name:n,vendor:r,keyframes:i})}function atsupports(){var e=position();var t=match(/^@supports *([^{]+)/);if(!t)return;var r=trim(t[1]);if(!open())return error("@supports missing '{'");var n=comments().concat(rules());if(!close())return error("@supports missing '}'");return e({type:"supports",supports:r,rules:n})}function athost(){var e=position();var t=match(/^@host\s*/);if(!t)return;if(!open())return error("@host missing '{'");var r=comments().concat(rules());if(!close())return error("@host missing '}'");return e({type:"host",rules:r})}function atmedia(){var e=position();var t=match(/^@media *([^{]+)/);if(!t)return;var r=trim(t[1]);if(!open())return error("@media missing '{'");var n=comments().concat(rules());if(!close())return error("@media missing '}'");return e({type:"media",media:r,rules:n})}function atcustommedia(){var e=position();var t=match(/^@custom-media\s+(--[^\s]+)\s*([^{;]+);/);if(!t)return;return e({type:"custom-media",name:trim(t[1]),media:trim(t[2])})}function atpage(){var e=position();var t=match(/^@page */);if(!t)return;var r=selector()||[];if(!open())return error("@page missing '{'");var n=comments();var o;while(o=declaration()){n.push(o);n=n.concat(comments())}if(!close())return error("@page missing '}'");return e({type:"page",selectors:r,declarations:n})}function atdocument(){var e=position();var t=match(/^@([-\w]+)?document *([^{]+)/);if(!t)return;var r=trim(t[1]);var n=trim(t[2]);if(!open())return error("@document missing '{'");var o=comments().concat(rules());if(!close())return error("@document missing '}'");return e({type:"document",document:n,vendor:r,rules:o})}function atfontface(){var e=position();var t=match(/^@font-face\s*/);if(!t)return;if(!open())return error("@font-face missing '{'");var r=comments();var n;while(n=declaration()){r.push(n);r=r.concat(comments())}if(!close())return error("@font-face missing '}'");return e({type:"font-face",declarations:r})}var s=_compileAtrule("import");var u=_compileAtrule("charset");var a=_compileAtrule("namespace");function _compileAtrule(e){var t=new RegExp("^@"+e+"\\s*([^;]+);");return function(){var r=position();var n=match(t);if(!n)return;var o={type:e};o[e]=n[1].trim();return r(o)}}function atrule(){if(e[0]!="@")return;return atkeyframes()||atmedia()||atcustommedia()||atsupports()||s()||u()||a()||atdocument()||atpage()||athost()||atfontface()}function rule(){var e=position();var t=selector();if(!t)return error("selector missing");comments();return e({type:"rule",selectors:t,declarations:declarations()})}return addParent(stylesheet())};function trim(e){return e?e.replace(/^\s+|\s+$/g,""):""}function addParent(e,t){var r=e&&typeof e.type==="string";var n=r?e:t;for(var o in e){var i=e[o];if(Array.isArray(i)){i.forEach(function(e){addParent(e,n)})}else if(i&&typeof i==="object"){addParent(i,n)}}if(r){Object.defineProperty(e,"parent",{configurable:true,writable:true,enumerable:false,value:t||null})}return e}},691:e=>{e.exports=Compiler;function Compiler(e){this.options=e||{}}Compiler.prototype.emit=function(e){return e};Compiler.prototype.visit=function(e){return this[e.type](e)};Compiler.prototype.mapVisit=function(e,t){var r="";t=t||"";for(var n=0,o=e.length;n<o;n++){r+=this.visit(e[n]);if(t&&n<o-1)r+=this.emit(t)}return r}},432:(e,t,r)=>{var n=r(691);var o=r(989);e.exports=Compiler;function Compiler(e){n.call(this,e)}o(Compiler,n);Compiler.prototype.compile=function(e){return e.stylesheet.rules.map(this.visit,this).join("")};Compiler.prototype.comment=function(e){return this.emit("",e.position)};Compiler.prototype.import=function(e){return this.emit("@import "+e.import+";",e.position)};Compiler.prototype.media=function(e){return this.emit("@media "+e.media,e.position)+this.emit("{")+this.mapVisit(e.rules)+this.emit("}")};Compiler.prototype.document=function(e){var t="@"+(e.vendor||"")+"document "+e.document;return this.emit(t,e.position)+this.emit("{")+this.mapVisit(e.rules)+this.emit("}")};Compiler.prototype.charset=function(e){return this.emit("@charset "+e.charset+";",e.position)};Compiler.prototype.namespace=function(e){return this.emit("@namespace "+e.namespace+";",e.position)};Compiler.prototype.supports=function(e){return this.emit("@supports "+e.supports,e.position)+this.emit("{")+this.mapVisit(e.rules)+this.emit("}")};Compiler.prototype.keyframes=function(e){return this.emit("@"+(e.vendor||"")+"keyframes "+e.name,e.position)+this.emit("{")+this.mapVisit(e.keyframes)+this.emit("}")};Compiler.prototype.keyframe=function(e){var t=e.declarations;return this.emit(e.values.join(","),e.position)+this.emit("{")+this.mapVisit(t)+this.emit("}")};Compiler.prototype.page=function(e){var t=e.selectors.length?e.selectors.join(", "):"";return this.emit("@page "+t,e.position)+this.emit("{")+this.mapVisit(e.declarations)+this.emit("}")};Compiler.prototype["font-face"]=function(e){return this.emit("@font-face",e.position)+this.emit("{")+this.mapVisit(e.declarations)+this.emit("}")};Compiler.prototype.host=function(e){return this.emit("@host",e.position)+this.emit("{")+this.mapVisit(e.rules)+this.emit("}")};Compiler.prototype["custom-media"]=function(e){return this.emit("@custom-media "+e.name+" "+e.media+";",e.position)};Compiler.prototype.rule=function(e){var t=e.declarations;if(!t.length)return"";return this.emit(e.selectors.join(","),e.position)+this.emit("{")+this.mapVisit(t)+this.emit("}")};Compiler.prototype.declaration=function(e){return this.emit(e.property+":"+e.value,e.position)+this.emit(";")}},184:(e,t,r)=>{var n=r(691);var o=r(989);e.exports=Compiler;function Compiler(e){e=e||{};n.call(this,e);this.indentation=e.indent}o(Compiler,n);Compiler.prototype.compile=function(e){return this.stylesheet(e)};Compiler.prototype.stylesheet=function(e){return this.mapVisit(e.stylesheet.rules,"\n\n")};Compiler.prototype.comment=function(e){return this.emit(this.indent()+"/*"+e.comment+"*/",e.position)};Compiler.prototype.import=function(e){return this.emit("@import "+e.import+";",e.position)};Compiler.prototype.media=function(e){return this.emit("@media "+e.media,e.position)+this.emit(" {\n"+this.indent(1))+this.mapVisit(e.rules,"\n\n")+this.emit(this.indent(-1)+"\n}")};Compiler.prototype.document=function(e){var t="@"+(e.vendor||"")+"document "+e.document;return this.emit(t,e.position)+this.emit(" "+" {\n"+this.indent(1))+this.mapVisit(e.rules,"\n\n")+this.emit(this.indent(-1)+"\n}")};Compiler.prototype.charset=function(e){return this.emit("@charset "+e.charset+";",e.position)};Compiler.prototype.namespace=function(e){return this.emit("@namespace "+e.namespace+";",e.position)};Compiler.prototype.supports=function(e){return this.emit("@supports "+e.supports,e.position)+this.emit(" {\n"+this.indent(1))+this.mapVisit(e.rules,"\n\n")+this.emit(this.indent(-1)+"\n}")};Compiler.prototype.keyframes=function(e){return this.emit("@"+(e.vendor||"")+"keyframes "+e.name,e.position)+this.emit(" {\n"+this.indent(1))+this.mapVisit(e.keyframes,"\n")+this.emit(this.indent(-1)+"}")};Compiler.prototype.keyframe=function(e){var t=e.declarations;return this.emit(this.indent())+this.emit(e.values.join(", "),e.position)+this.emit(" {\n"+this.indent(1))+this.mapVisit(t,"\n")+this.emit(this.indent(-1)+"\n"+this.indent()+"}\n")};Compiler.prototype.page=function(e){var t=e.selectors.length?e.selectors.join(", ")+" ":"";return this.emit("@page "+t,e.position)+this.emit("{\n")+this.emit(this.indent(1))+this.mapVisit(e.declarations,"\n")+this.emit(this.indent(-1))+this.emit("\n}")};Compiler.prototype["font-face"]=function(e){return this.emit("@font-face ",e.position)+this.emit("{\n")+this.emit(this.indent(1))+this.mapVisit(e.declarations,"\n")+this.emit(this.indent(-1))+this.emit("\n}")};Compiler.prototype.host=function(e){return this.emit("@host",e.position)+this.emit(" {\n"+this.indent(1))+this.mapVisit(e.rules,"\n\n")+this.emit(this.indent(-1)+"\n}")};Compiler.prototype["custom-media"]=function(e){return this.emit("@custom-media "+e.name+" "+e.media+";",e.position)};Compiler.prototype.rule=function(e){var t=this.indent();var r=e.declarations;if(!r.length)return"";return this.emit(e.selectors.map(function(e){return t+e}).join(",\n"),e.position)+this.emit(" {\n")+this.emit(this.indent(1))+this.mapVisit(r,"\n")+this.emit(this.indent(-1))+this.emit("\n"+this.indent()+"}")};Compiler.prototype.declaration=function(e){return this.emit(this.indent())+this.emit(e.property+": "+e.value,e.position)+this.emit(";")};Compiler.prototype.indent=function(e){this.level=this.level||1;if(null!=e){this.level+=e;return""}return Array(this.level).join(this.indentation||" ")}},11:(e,t,r)=>{var n=r(432);var o=r(184);e.exports=function(e,t){t=t||{};var i=t.compress?new n(t):new o(t);if(t.sourcemap){var s=r(878);s(i);var u=i.compile(e);i.applySourceMaps();var a=t.sourcemap==="generator"?i.map:i.map.toJSON();return{code:u,map:a}}var u=i.compile(e);return u}},878:(e,t,r)=>{var n=r(241).SourceMapGenerator;var o=r(241).SourceMapConsumer;var i=r(227);var s=r(806);var u=r(747);var a=r(622);e.exports=mixin;function mixin(e){e._comment=e.comment;e.map=new n;e.position={line:1,column:1};e.files={};for(var r in t)e[r]=t[r]}t.updatePosition=function(e){var t=e.match(/\n/g);if(t)this.position.line+=t.length;var r=e.lastIndexOf("\n");this.position.column=~r?e.length-r:this.position.column+e.length};t.emit=function(e,t){if(t){var r=s(t.source||"source.css");this.map.addMapping({source:r,generated:{line:this.position.line,column:Math.max(this.position.column-1,0)},original:{line:t.start.line,column:t.start.column-1}});this.addFile(r,t)}this.updatePosition(e);return e};t.addFile=function(e,t){if(typeof t.content!=="string")return;if(Object.prototype.hasOwnProperty.call(this.files,e))return;this.files[e]=t.content};t.applySourceMaps=function(){Object.keys(this.files).forEach(function(e){var t=this.files[e];this.map.setSourceContent(e,t);if(this.options.inputSourcemaps!==false){var r=i.resolveSync(t,e,u.readFileSync);if(r){var n=new o(r.map);var c=r.sourcesRelativeTo;this.map.applySourceMap(n,e,s(a.dirname(c)))}}},this)};t.comment=function(e){if(/^# sourceMappingURL=/.test(e.comment))return this.emit("",e.position);else return this._comment(e)}},609:(e,t,r)=>{var n=r(748);function customDecodeUriComponent(e){return n(e.replace(/\+/g,"%2B"))}e.exports=customDecodeUriComponent},825:(e,t,r)=>{var n=r(835);function resolveUrl(){return Array.prototype.reduce.call(arguments,function(e,t){return n.resolve(e,t)})}e.exports=resolveUrl},227:(e,t,r)=>{var n=r(707);var o=r(825);var i=r(609);var s=r(806);var u=r(327);function callbackAsync(e,t,r){setImmediate(function(){e(t,r)})}function parseMapToJSON(e,t){try{return JSON.parse(e.replace(/^\)\]\}'/,""))}catch(e){e.sourceMapData=t;throw e}}function readSync(e,t,r){var n=i(t);try{return String(e(n))}catch(e){e.sourceMapData=r;throw e}}function resolveSourceMap(e,t,r,n){var o;try{o=resolveSourceMapHelper(e,t)}catch(e){return callbackAsync(n,e)}if(!o||o.map){return callbackAsync(n,null,o)}var s=i(o.url);r(s,function(e,t){if(e){e.sourceMapData=o;return n(e)}o.map=String(t);try{o.map=parseMapToJSON(o.map,o)}catch(e){return n(e)}n(null,o)})}function resolveSourceMapSync(e,t,r){var n=resolveSourceMapHelper(e,t);if(!n||n.map){return n}n.map=readSync(r,n.url,n);n.map=parseMapToJSON(n.map,n);return n}var a=/^data:([^,;]*)(;[^,;]*)*(?:,(.*))?$/;var c=/^(?:application|text)\/json$/;var p="utf-8";function base64ToBuf(e){var t=u(e);var r=t.length;var n=new Uint8Array(r);for(var o=0;o<r;o++){n[o]=t.charCodeAt(o)}return n}function decodeBase64String(e){if(typeof TextDecoder==="undefined"||typeof Uint8Array==="undefined"){return u(e)}var t=base64ToBuf(e);var r=new TextDecoder(p,{fatal:true});return r.decode(t)}function resolveSourceMapHelper(e,t){t=s(t);var r=n.getFrom(e);if(!r){return null}var i=r.match(a);if(i){var u=i[1]||"text/plain";var p=i[2]||"";var m=i[3]||"";var f={sourceMappingURL:r,url:null,sourcesRelativeTo:t,map:m};if(!c.test(u)){var l=new Error("Unuseful data uri mime type: "+u);l.sourceMapData=f;throw l}try{f.map=parseMapToJSON(p===";base64"?decodeBase64String(m):decodeURIComponent(m),f)}catch(l){l.sourceMapData=f;throw l}return f}var h=o(t,r);return{sourceMappingURL:r,url:h,sourcesRelativeTo:h,map:null}}function resolveSources(e,t,r,n,o){if(typeof n==="function"){o=n;n={}}var s=e.sources?e.sources.length:0;var u={sourcesResolved:[],sourcesContent:[]};if(s===0){callbackAsync(o,null,u);return}var a=function(){s--;if(s===0){o(null,u)}};resolveSourcesHelper(e,t,n,function(e,t,n){u.sourcesResolved[n]=e;if(typeof t==="string"){u.sourcesContent[n]=t;callbackAsync(a,null)}else{var o=i(e);r(o,function(e,t){u.sourcesContent[n]=e?e:String(t);a()})}})}function resolveSourcesSync(e,t,r,n){var o={sourcesResolved:[],sourcesContent:[]};if(!e.sources||e.sources.length===0){return o}resolveSourcesHelper(e,t,n,function(e,t,n){o.sourcesResolved[n]=e;if(r!==null){if(typeof t==="string"){o.sourcesContent[n]=t}else{var s=i(e);try{o.sourcesContent[n]=String(r(s))}catch(e){o.sourcesContent[n]=e}}}});return o}var m=/\/?$/;function resolveSourcesHelper(e,t,r,n){r=r||{};t=s(t);var i;var u;var a;for(var c=0,p=e.sources.length;c<p;c++){a=null;if(typeof r.sourceRoot==="string"){a=r.sourceRoot}else if(typeof e.sourceRoot==="string"&&r.sourceRoot!==false){a=e.sourceRoot}if(a===null||a===""){i=o(t,e.sources[c])}else{i=o(t,a.replace(m,"/"),e.sources[c])}u=(e.sourcesContent||[])[c];n(i,u,c)}}function resolve(e,t,r,n,o){if(typeof n==="function"){o=n;n={}}if(e===null){var s=t;var u={sourceMappingURL:null,url:s,sourcesRelativeTo:s,map:null};var a=i(s);r(a,function(e,t){if(e){e.sourceMapData=u;return o(e)}u.map=String(t);try{u.map=parseMapToJSON(u.map,u)}catch(e){return o(e)}_resolveSources(u)})}else{resolveSourceMap(e,t,r,function(e,t){if(e){return o(e)}if(!t){return o(null,null)}_resolveSources(t)})}function _resolveSources(e){resolveSources(e.map,e.sourcesRelativeTo,r,n,function(t,r){if(t){return o(t)}e.sourcesResolved=r.sourcesResolved;e.sourcesContent=r.sourcesContent;o(null,e)})}}function resolveSync(e,t,r,n){var o;if(e===null){var i=t;o={sourceMappingURL:null,url:i,sourcesRelativeTo:i,map:null};o.map=readSync(r,i,o);o.map=parseMapToJSON(o.map,o)}else{o=resolveSourceMapSync(e,t,r);if(!o){return null}}var s=resolveSourcesSync(o.map,o.sourcesRelativeTo,r,n);o.sourcesResolved=s.sourcesResolved;o.sourcesContent=s.sourcesContent;return o}e.exports={resolveSourceMap:resolveSourceMap,resolveSourceMapSync:resolveSourceMapSync,resolveSources:resolveSources,resolveSourcesSync:resolveSourcesSync,resolve:resolve,resolveSync:resolveSync,parseMapToJSON:parseMapToJSON}},707:function(e){void function(t,r){if(typeof define==="function"&&define.amd){define(r)}else if(true){e.exports=r()}else{}}(this,function(){var e=/[#@] sourceMappingURL=([^\s'"]*)/;var t=RegExp("(?:"+"/\\*"+"(?:\\s*\r?\n(?://)?)?"+"(?:"+e.source+")"+"\\s*"+"\\*/"+"|"+"//(?:"+e.source+")"+")"+"\\s*");return{regex:t,_innerRegex:e,getFrom:function(e){var r=e.match(t);return r?r[1]||r[2]||"":null},existsIn:function(e){return t.test(e)},removeFrom:function(e){return e.replace(t,"")},insertBefore:function(e,r){var n=e.match(t);if(n){return e.slice(0,n.index)+r+e.slice(n.index)}else{return e+r}}}})},806:(e,t,r)=>{var n=r(622);"use strict";function urix(e){if(n.sep==="\\"){return e.replace(/\\/g,"/").replace(/^[a-z]:\/?/i,"/")}return e}e.exports=urix},293:e=>{"use strict";e.exports=require("buffer")},747:e=>{"use strict";e.exports=require("fs")},241:e=>{"use strict";e.exports=require("next/dist/compiled/source-map")},622:e=>{"use strict";e.exports=require("path")},835:e=>{"use strict";e.exports=require("url")},669:e=>{"use strict";e.exports=require("util")}};var t={};function __nccwpck_require__(r){if(t[r]){return t[r].exports}var n=t[r]={exports:{}};var o=true;try{e[r].call(n.exports,n,n.exports,__nccwpck_require__);o=false}finally{if(o)delete t[r]}return n.exports}__nccwpck_require__.ab=__dirname+"/";return __nccwpck_require__(269)})();