varDISABLE_SPEEDY=Boolean(typeofSC_DISABLE_SPEEDY==='boolean'?SC_DISABLE_SPEEDY:typeofprocess!=='undefined'&&typeofprocess.env.REACT_APP_SC_DISABLE_SPEEDY!=='undefined'&&process.env.REACT_APP_SC_DISABLE_SPEEDY!==''?process.env.REACT_APP_SC_DISABLE_SPEEDY==='false'?false:process.env.REACT_APP_SC_DISABLE_SPEEDY:typeofprocess!=='undefined'&&typeofprocess.env.SC_DISABLE_SPEEDY!=='undefined'&&process.env.SC_DISABLE_SPEEDY!==''?process.env.SC_DISABLE_SPEEDY==='false'?false:process.env.SC_DISABLE_SPEEDY:process.env.NODE_ENV!=='production');// Shared empty execution context when generating static styles
//
varEMPTY_ARRAY=Object.freeze([]);
varEMPTY_OBJECT=Object.freeze({});
varerrorMap={
"1":"Cannot create styled-component for component: %s.\n\n",
"2":"Can't collect styles once you've consumed a `ServerStyleSheet`'s styles! `ServerStyleSheet` is a one off instance for each server-side render cycle.\n\n- Are you trying to reuse it across renders?\n- Are you accidentally calling collectStyles twice?\n\n",
"3":"Streaming SSR is only supported in a Node.js environment; Please do not try to call this method in the browser.\n\n",
"4":"The `StyleSheetManager` expects a valid target or sheet prop!\n\n- Does this error occur on the client and is your target falsy?\n- Does this error occur on the server and is the sheet falsy?\n\n",
"5":"The clone method cannot be used on the client!\n\n- Are you running in a client-like environment on the server?\n- Are you trying to run SSR on the client?\n\n",
"6":"Trying to insert a new style tag, but the given Node is unmounted!\n\n- Are you using a custom target that isn't mounted?\n- Does your document not have a valid head element?\n- Have you accidentally removed a style tag manually?\n\n",
"7":"ThemeProvider: Please return an object from your \"theme\" prop function, e.g.\n\n```js\ntheme={() => ({})}\n```\n\n",
"8":"ThemeProvider: Please make your \"theme\" prop an object.\n\n",
"9":"Missing document `<head>`\n\n",
"10":"Cannot find a StyleSheet instance. Usually this happens if there are multiple copies of styled-components loaded at once. Check out this issue for how to troubleshoot and fix the common cases where this situation can happen: https://github.com/styled-components/styled-components/issues/1941#issuecomment-417862021\n\n",
"11":"_This error was replaced with a dev-time warning, it will be deleted for v4 final._ [createGlobalStyle] received children which will not be rendered. Please use the component without passing children elements.\n\n",
"12":"It seems you are interpolating a keyframe declaration (%s) into an untagged string. This was supported in styled-components v3, but is not longer supported in v4 as keyframes are now injected on-demand. Please wrap your string in the css\\`\\` helper which ensures the styles are injected correctly. See https://www.styled-components.com/docs/api#css\n\n",
"13":"%s is not a styled component and cannot be referred to via component selector. See https://www.styled-components.com/docs/advanced#referring-to-other-components for more details.\n\n",
"14":"ThemeProvider: \"theme\" prop is required.\n\n",
"15":"A stylis plugin has been supplied that is not named. We need a name for each plugin to be able to prevent styling collisions between different stylis configurations within the same app. Before you pass your plugin to `<StyleSheetManager stylisPlugins={[]}>`, please make sure each plugin is uniquely-named, e.g.\n\n```js\nObject.defineProperty(importedPlugin, 'name', { value: 'some-unique-name' });\n```\n\n",
"16":"Reached the limit of how many styled components may be created at group %s.\nYou may only create up to 1,073,741,824 components. If you're creating components dynamically,\nas for instance in your render method then you may be running into this limitation.\n\n",
"17":"CSSStyleSheet could not be found on HTMLStyleElement.\nHas styled-components' style tag been unmounted or altered by another script?\n"
thrownewError("An error occurred. See https://git.io/JUIaE#"+code+" for more information."+(interpolations.length>0?" Args: "+interpolations.join(', '):''));
/** Clears all cached names for a given group ID */
;
_proto.clearNames=functionclearNames(id){
if(this.names.has(id)){
this.names.get(id).clear();
}
}
/** Clears all rules for a given group ID */
;
_proto.clearRules=functionclearRules(id){
this.getTag().clearGroup(getGroupForId(id));
this.clearNames(id);
}
/** Clears the entire tag which deletes all rules but not its names */
;
_proto.clearTag=functionclearTag(){
// NOTE: This does not clear the names, since it's only used during SSR
// so that we can continuously output only new rules
this.tag=undefined;
}
/** Outputs the current sheet as a CSS string with markers for SSR */
;
_proto.toString=functiontoString(){
returnoutputSheet(this);
};
returnStyleSheet;
}();
/**
* MIT License
*
* Copyright (c) 2016 Sultan Tarimo
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
* sell copies of the Software and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
* OR IMPLIED INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
* IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
if(// do not replace the first occurrence if it is complex (has a modifier)
(offset===0?COMPLEX_SELECTOR_PREFIX.indexOf(string[_selector.length])===-1:true)&&// no consecutive self refs (.b.b); that is a precedence boost and treated differently
!string.match(_consecutiveSelfRefRegExp)){
return"."+_componentId;
}
returnmatch;
};
/**
* When writing a style like
*
* & + & {
* color: red;
* }
*
* The second ampersand should be a reference to the static component class. stylis
* has no knowledge of static class so we have to intelligently replace the base selector.
*
* https://github.com/thysultan/stylis.js/tree/v3.5.4#plugins <- more info about the context phase values
* "2" means this plugin is taking effect at the very end after all other processing is complete
console.warn(getComponentName(chunk)+" is not a styled component and cannot be referred to via component selector. See https://www.styled-components.com/docs/advanced#referring-to-other-components for more details.");
warnOnce(""+('Your current PostCSS version '+'is ')+runtimeVer+", but "+pluginName+" "+("uses "+pluginVer+". Perhaps this is ")+"the source of the error below.");
console.warn("[withTheme] You are not using a ThemeProvider nor passing a theme prop or a theme in defaultProps in component class \""+getComponentName(Component)+"\"");