@thecb/components 5.9.1 → 5.9.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs.js +2071 -297
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +2072 -298
- package/dist/index.esm.js.map +1 -1
- package/package.json +11 -11
- package/src/.DS_Store +0 -0
- package/src/components/atoms/amount-callout/AmountCallout.theme.js +1 -1
- package/src/components/atoms/button-with-action/ButtonWithAction.js +2 -0
- package/src/components/atoms/button-with-link/ButtonWithLink.js +10 -1
- package/src/components/atoms/icons/AutopayOnIcon.js +4 -10
- package/src/components/atoms/layouts/Box.styled.js +3 -5
- package/src/components/atoms/layouts/Cluster.js +1 -1
- package/src/components/atoms/layouts/Cluster.styled.js +1 -1
- package/src/components/atoms/layouts/examples/cluster-example/ClusterExample.stories.js +5 -12
- package/src/components/atoms/layouts/examples/cover-example/CoverExample.stories.js +2 -6
- package/src/components/atoms/layouts/examples/grid-example/GridExample.stories.js +3 -6
- package/src/components/atoms/layouts/examples/sidebar-example/SidebarExample.stories.js +3 -6
- package/src/components/atoms/layouts/examples/stack-example/StackExample.stories.js +5 -12
- package/src/components/atoms/layouts/examples/switcher-example/SwitcherExample.stories.js +4 -9
- package/src/components/atoms/link/ExternalLink.js +2 -0
- package/src/components/atoms/link/InternalLink.js +2 -0
- package/src/components/atoms/placeholder/Placeholder.js +1 -1
- package/src/components/atoms/text/Text.js +2 -0
- package/src/components/atoms/text/Text.styled.js +1 -0
- package/src/components/molecules/obligation/Obligation.js +46 -16
- package/src/components/molecules/obligation/modules/AmountModule.js +1 -0
- package/src/components/molecules/obligation/modules/AutopayModalModule.js +80 -47
- package/src/components/molecules/obligation/modules/InactiveControlsModule.js +20 -10
- package/src/components/molecules/obligation/modules/InactiveTitleModule.js +2 -2
- package/src/components/molecules/obligation/modules/PaymentDetailsActions.js +8 -9
- package/src/components/molecules/obligation/modules/RemoveAccountModalModule.js +62 -0
- package/src/components/molecules/obligation/modules/index.js +3 -1
- package/src/components/molecules/tab-sidebar/TabSidebar.js +3 -2
- package/src/components/molecules/workflow-tile/WorkflowTile.js +1 -0
- package/src/components/templates/center-single/CenterSingle.js +2 -1
- package/src/components/templates/center-stack/CenterStack.js +2 -1
- package/src/components/templates/default-page-template/DefaultPageTemplate.js +2 -1
- package/src/components/templates/sidebar-single-content/SidebarSingleContent.js +2 -1
- package/src/components/templates/sidebar-stack-content/SidebarStackContent.js +2 -1
- package/src/components/templates/templates.theme.js +1 -1
- package/src/constants/colors.js +10 -8
package/dist/index.cjs.js
CHANGED
|
@@ -1174,16 +1174,16 @@ var unitlessKeys = {
|
|
|
1174
1174
|
};
|
|
1175
1175
|
|
|
1176
1176
|
function memoize(fn) {
|
|
1177
|
-
var cache =
|
|
1177
|
+
var cache = {};
|
|
1178
1178
|
return function (arg) {
|
|
1179
1179
|
if (cache[arg] === undefined) cache[arg] = fn(arg);
|
|
1180
1180
|
return cache[arg];
|
|
1181
1181
|
};
|
|
1182
1182
|
}
|
|
1183
1183
|
|
|
1184
|
-
var reactPropsRegex = /^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|
|
|
1184
|
+
var reactPropsRegex = /^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|inert|itemProp|itemScope|itemType|itemID|itemRef|on|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/; // https://esbench.com/bench/5bfee68a4cd7e6009ef61d23
|
|
1185
1185
|
|
|
1186
|
-
var
|
|
1186
|
+
var index = memoize(function (prop) {
|
|
1187
1187
|
return reactPropsRegex.test(prop) || prop.charCodeAt(0) === 111
|
|
1188
1188
|
/* o */
|
|
1189
1189
|
&& prop.charCodeAt(1) === 110
|
|
@@ -1293,7 +1293,1643 @@ function hoistNonReactStatics(targetComponent, sourceComponent, blacklist) {
|
|
|
1293
1293
|
|
|
1294
1294
|
var hoistNonReactStatics_cjs = hoistNonReactStatics;
|
|
1295
1295
|
|
|
1296
|
-
function y$1(){return (y$1=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e}).apply(this,arguments)}var v$1=function(e,t){for(var n=[e[0]],r=0,o=t.length;r<o;r+=1)n.push(t[r],e[r+1]);return n},g$1=function(t){return null!==t&&"object"==typeof t&&"[object Object]"===(t.toString?t.toString():Object.prototype.toString.call(t))&&!reactIs_28(t)},S=Object.freeze([]),w$1=Object.freeze({});function E(e){return "function"==typeof e}function b$1(e){return "production"!==process.env.NODE_ENV&&"string"==typeof e&&e||e.displayName||e.name||"Component"}function _(e){return e&&"string"==typeof e.styledComponentId}var N="undefined"!=typeof process&&(process.env.REACT_APP_SC_ATTR||process.env.SC_ATTR)||"data-styled",C="undefined"!=typeof window&&"HTMLElement"in window,I=Boolean("boolean"==typeof SC_DISABLE_SPEEDY?SC_DISABLE_SPEEDY:"undefined"!=typeof process&&void 0!==process.env.REACT_APP_SC_DISABLE_SPEEDY&&""!==process.env.REACT_APP_SC_DISABLE_SPEEDY?"false"!==process.env.REACT_APP_SC_DISABLE_SPEEDY&&process.env.REACT_APP_SC_DISABLE_SPEEDY:"undefined"!=typeof process&&void 0!==process.env.SC_DISABLE_SPEEDY&&""!==process.env.SC_DISABLE_SPEEDY?"false"!==process.env.SC_DISABLE_SPEEDY&&process.env.SC_DISABLE_SPEEDY:"production"!==process.env.NODE_ENV),O="production"!==process.env.NODE_ENV?{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"}:{};function R(){for(var e=arguments.length<=0?void 0:arguments[0],t=[],n=1,r=arguments.length;n<r;n+=1)t.push(n<0||arguments.length<=n?void 0:arguments[n]);return t.forEach((function(t){e=e.replace(/%[a-z]/,t);})),e}function D(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];throw "production"===process.env.NODE_ENV?new Error("An error occurred. See https://git.io/JUIaE#"+e+" for more information."+(n.length>0?" Args: "+n.join(", "):"")):new Error(R.apply(void 0,[O[e]].concat(n)).trim())}var j=function(){function e(e){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=e;}var t=e.prototype;return t.indexOfGroup=function(e){for(var t=0,n=0;n<e;n++)t+=this.groupSizes[n];return t},t.insertRules=function(e,t){if(e>=this.groupSizes.length){for(var n=this.groupSizes,r=n.length,o=r;e>=o;)(o<<=1)<0&&D(16,""+e);this.groupSizes=new Uint32Array(o),this.groupSizes.set(n),this.length=o;for(var s=r;s<o;s++)this.groupSizes[s]=0;}for(var i=this.indexOfGroup(e+1),a=0,c=t.length;a<c;a++)this.tag.insertRule(i,t[a])&&(this.groupSizes[e]++,i++);},t.clearGroup=function(e){if(e<this.length){var t=this.groupSizes[e],n=this.indexOfGroup(e),r=n+t;this.groupSizes[e]=0;for(var o=n;o<r;o++)this.tag.deleteRule(n);}},t.getGroup=function(e){var t="";if(e>=this.length||0===this.groupSizes[e])return t;for(var n=this.groupSizes[e],r=this.indexOfGroup(e),o=r+n,s=r;s<o;s++)t+=this.tag.getRule(s)+"/*!sc*/\n";return t},e}(),T=new Map,x$1=new Map,k$1=1,V=function(e){if(T.has(e))return T.get(e);for(;x$1.has(k$1);)k$1++;var t=k$1++;return "production"!==process.env.NODE_ENV&&((0|t)<0||t>1<<30)&&D(16,""+t),T.set(e,t),x$1.set(t,e),t},z$1=function(e){return x$1.get(e)},B=function(e,t){t>=k$1&&(k$1=t+1),T.set(e,t),x$1.set(t,e);},M="style["+N+'][data-styled-version="5.3.5"]',G=new RegExp("^"+N+'\\.g(\\d+)\\[id="([\\w\\d-]+)"\\].*?"([^"]*)'),L=function(e,t,n){for(var r,o=n.split(","),s=0,i=o.length;s<i;s++)(r=o[s])&&e.registerName(t,r);},F=function(e,t){for(var n=(t.textContent||"").split("/*!sc*/\n"),r=[],o=0,s=n.length;o<s;o++){var i=n[o].trim();if(i){var a=i.match(G);if(a){var c=0|parseInt(a[1],10),u=a[2];0!==c&&(B(u,c),L(e,u,a[3]),e.getTag().insertRules(c,r)),r.length=0;}else r.push(i);}}},Y=function(){return "undefined"!=typeof window&&void 0!==window.__webpack_nonce__?window.__webpack_nonce__:null},q$1=function(e){var t=document.head,n=e||t,r=document.createElement("style"),o=function(e){for(var t=e.childNodes,n=t.length;n>=0;n--){var r=t[n];if(r&&1===r.nodeType&&r.hasAttribute(N))return r}}(n),s=void 0!==o?o.nextSibling:null;r.setAttribute(N,"active"),r.setAttribute("data-styled-version","5.3.5");var i=Y();return i&&r.setAttribute("nonce",i),n.insertBefore(r,s),r},H=function(){function e(e){var t=this.element=q$1(e);t.appendChild(document.createTextNode("")),this.sheet=function(e){if(e.sheet)return e.sheet;for(var t=document.styleSheets,n=0,r=t.length;n<r;n++){var o=t[n];if(o.ownerNode===e)return o}D(17);}(t),this.length=0;}var t=e.prototype;return t.insertRule=function(e,t){try{return this.sheet.insertRule(t,e),this.length++,!0}catch(e){return !1}},t.deleteRule=function(e){this.sheet.deleteRule(e),this.length--;},t.getRule=function(e){var t=this.sheet.cssRules[e];return void 0!==t&&"string"==typeof t.cssText?t.cssText:""},e}(),$=function(){function e(e){var t=this.element=q$1(e);this.nodes=t.childNodes,this.length=0;}var t=e.prototype;return t.insertRule=function(e,t){if(e<=this.length&&e>=0){var n=document.createTextNode(t),r=this.nodes[e];return this.element.insertBefore(n,r||null),this.length++,!0}return !1},t.deleteRule=function(e){this.element.removeChild(this.nodes[e]),this.length--;},t.getRule=function(e){return e<this.length?this.nodes[e].textContent:""},e}(),W=function(){function e(e){this.rules=[],this.length=0;}var t=e.prototype;return t.insertRule=function(e,t){return e<=this.length&&(this.rules.splice(e,0,t),this.length++,!0)},t.deleteRule=function(e){this.rules.splice(e,1),this.length--;},t.getRule=function(e){return e<this.length?this.rules[e]:""},e}(),U=C,J={isServer:!C,useCSSOMInjection:!I},X=function(){function e(e,t,n){void 0===e&&(e=w$1),void 0===t&&(t={}),this.options=y$1({},J,{},e),this.gs=t,this.names=new Map(n),this.server=!!e.isServer,!this.server&&C&&U&&(U=!1,function(e){for(var t=document.querySelectorAll(M),n=0,r=t.length;n<r;n++){var o=t[n];o&&"active"!==o.getAttribute(N)&&(F(e,o),o.parentNode&&o.parentNode.removeChild(o));}}(this));}e.registerId=function(e){return V(e)};var t=e.prototype;return t.reconstructWithOptions=function(t,n){return void 0===n&&(n=!0),new e(y$1({},this.options,{},t),this.gs,n&&this.names||void 0)},t.allocateGSInstance=function(e){return this.gs[e]=(this.gs[e]||0)+1},t.getTag=function(){return this.tag||(this.tag=(n=(t=this.options).isServer,r=t.useCSSOMInjection,o=t.target,e=n?new W(o):r?new H(o):new $(o),new j(e)));var e,t,n,r,o;},t.hasNameForId=function(e,t){return this.names.has(e)&&this.names.get(e).has(t)},t.registerName=function(e,t){if(V(e),this.names.has(e))this.names.get(e).add(t);else {var n=new Set;n.add(t),this.names.set(e,n);}},t.insertRules=function(e,t,n){this.registerName(e,t),this.getTag().insertRules(V(e),n);},t.clearNames=function(e){this.names.has(e)&&this.names.get(e).clear();},t.clearRules=function(e){this.getTag().clearGroup(V(e)),this.clearNames(e);},t.clearTag=function(){this.tag=void 0;},t.toString=function(){return function(e){for(var t=e.getTag(),n=t.length,r="",o=0;o<n;o++){var s=z$1(o);if(void 0!==s){var i=e.names.get(s),a=t.getGroup(o);if(i&&a&&i.size){var c=N+".g"+o+'[id="'+s+'"]',u="";void 0!==i&&i.forEach((function(e){e.length>0&&(u+=e+",");})),r+=""+a+c+'{content:"'+u+'"}/*!sc*/\n';}}}return r}(this)},e}(),Z=/(a)(d)/gi,K=function(e){return String.fromCharCode(e+(e>25?39:97))};function Q(e){var t,n="";for(t=Math.abs(e);t>52;t=t/52|0)n=K(t%52)+n;return (K(t%52)+n).replace(Z,"$1-$2")}var ee=function(e,t){for(var n=t.length;n;)e=33*e^t.charCodeAt(--n);return e},te=function(e){return ee(5381,e)};function ne(e){for(var t=0;t<e.length;t+=1){var n=e[t];if(E(n)&&!_(n))return !1}return !0}var re=te("5.3.5"),oe=function(){function e(e,t,n){this.rules=e,this.staticRulesId="",this.isStatic="production"===process.env.NODE_ENV&&(void 0===n||n.isStatic)&&ne(e),this.componentId=t,this.baseHash=ee(re,t),this.baseStyle=n,X.registerId(t);}return e.prototype.generateAndInjectStyles=function(e,t,n){var r=this.componentId,o=[];if(this.baseStyle&&o.push(this.baseStyle.generateAndInjectStyles(e,t,n)),this.isStatic&&!n.hash)if(this.staticRulesId&&t.hasNameForId(r,this.staticRulesId))o.push(this.staticRulesId);else {var s=_e(this.rules,e,t,n).join(""),i=Q(ee(this.baseHash,s)>>>0);if(!t.hasNameForId(r,i)){var a=n(s,"."+i,void 0,r);t.insertRules(r,i,a);}o.push(i),this.staticRulesId=i;}else {for(var c=this.rules.length,u=ee(this.baseHash,n.hash),l="",d=0;d<c;d++){var h=this.rules[d];if("string"==typeof h)l+=h,"production"!==process.env.NODE_ENV&&(u=ee(u,h+d));else if(h){var p=_e(h,e,t,n),f=Array.isArray(p)?p.join(""):p;u=ee(u,f+d),l+=f;}}if(l){var m=Q(u>>>0);if(!t.hasNameForId(r,m)){var y=n(l,"."+m,void 0,r);t.insertRules(r,m,y);}o.push(m);}}return o.join(" ")},e}(),se=/^\s*\/\/.*$/gm,ie=[":","[",".","#"];function ae(e){var t,n,r,o,s=void 0===e?w$1:e,i=s.options,a=void 0===i?w$1:i,c=s.plugins,u=void 0===c?S:c,l=new stylis_min(a),d=[],p=function(e){function t(t){if(t)try{e(t+"}");}catch(e){}}return function(n,r,o,s,i,a,c,u,l,d){switch(n){case 1:if(0===l&&64===r.charCodeAt(0))return e(r+";"),"";break;case 2:if(0===u)return r+"/*|*/";break;case 3:switch(u){case 102:case 112:return e(o[0]+r),"";default:return r+(0===d?"/*|*/":"")}case-2:r.split("/*|*/}").forEach(t);}}}((function(e){d.push(e);})),f=function(e,r,s){return 0===r&&-1!==ie.indexOf(s[n.length])||s.match(o)?e:"."+t};function m(e,s,i,a){void 0===a&&(a="&");var c=e.replace(se,""),u=s&&i?i+" "+s+" { "+c+" }":c;return t=a,n=s,r=new RegExp("\\"+n+"\\b","g"),o=new RegExp("(\\"+n+"\\b){2,}"),l(i||!s?"":s,u)}return l.use([].concat(u,[function(e,t,o){2===e&&o.length&&o[0].lastIndexOf(n)>0&&(o[0]=o[0].replace(r,f));},p,function(e){if(-2===e){var t=d;return d=[],t}}])),m.hash=u.length?u.reduce((function(e,t){return t.name||D(15),ee(e,t.name)}),5381).toString():"",m}var ce=React__default.createContext(),ue=ce.Consumer,le=React__default.createContext(),de=(le.Consumer,new X),he=ae();function pe(){return React.useContext(ce)||de}function fe(){return React.useContext(le)||he}var ye=function(){function e(e,t){var n=this;this.inject=function(e,t){void 0===t&&(t=he);var r=n.name+t.hash;e.hasNameForId(n.id,r)||e.insertRules(n.id,r,t(n.rules,r,"@keyframes"));},this.toString=function(){return D(12,String(n.name))},this.name=e,this.id="sc-keyframes-"+e,this.rules=t;}return e.prototype.getName=function(e){return void 0===e&&(e=he),this.name+e.hash},e}(),ve=/([A-Z])/,ge=/([A-Z])/g,Se=/^ms-/,we=function(e){return "-"+e.toLowerCase()};function Ee(e){return ve.test(e)?e.replace(ge,we).replace(Se,"-ms-"):e}var be=function(e){return null==e||!1===e||""===e};function _e(e,n,r,o){if(Array.isArray(e)){for(var s,i=[],a=0,c=e.length;a<c;a+=1)""!==(s=_e(e[a],n,r,o))&&(Array.isArray(s)?i.push.apply(i,s):i.push(s));return i}if(be(e))return "";if(_(e))return "."+e.styledComponentId;if(E(e)){if("function"!=typeof(l=e)||l.prototype&&l.prototype.isReactComponent||!n)return e;var u=e(n);return "production"!==process.env.NODE_ENV&&reactIs_18(u)&&console.warn(b$1(e)+" 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."),_e(u,n,r,o)}var l;return e instanceof ye?r?(e.inject(r,o),e.getName(o)):e:g$1(e)?function e(t,n){var r,o,s=[];for(var i in t)t.hasOwnProperty(i)&&!be(t[i])&&(Array.isArray(t[i])&&t[i].isCss||E(t[i])?s.push(Ee(i)+":",t[i],";"):g$1(t[i])?s.push.apply(s,e(t[i],i)):s.push(Ee(i)+": "+(r=i,null==(o=t[i])||"boolean"==typeof o||""===o?"":"number"!=typeof o||0===o||r in unitlessKeys?String(o).trim():o+"px")+";"));return n?[n+" {"].concat(s,["}"]):s}(e):e.toString()}var Ne=function(e){return Array.isArray(e)&&(e.isCss=!0),e};function Ae(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return E(e)||g$1(e)?Ne(_e(v$1(S,[e].concat(n)))):0===n.length&&1===e.length&&"string"==typeof e[0]?e:Ne(_e(v$1(e,n)))}var Ce=/invalid hook call/i,Ie=new Set,Pe=function(e,t){if("production"!==process.env.NODE_ENV){var n="The component "+e+(t?' with the id of "'+t+'"':"")+" has been created dynamically.\nYou may see this warning because you've called styled inside another component.\nTo resolve this only create new StyledComponents outside of any render method and function component.",r=console.error;try{var o=!0;console.error=function(e){if(Ce.test(e))o=!1,Ie.delete(n);else {for(var t=arguments.length,s=new Array(t>1?t-1:0),i=1;i<t;i++)s[i-1]=arguments[i];r.apply(void 0,[e].concat(s));}},React.useRef(),o&&!Ie.has(n)&&(console.warn(n),Ie.add(n));}catch(e){Ce.test(e.message)&&Ie.delete(n);}finally{console.error=r;}}},Oe=function(e,t,n){return void 0===n&&(n=w$1),e.theme!==n.theme&&e.theme||t||n.theme},Re=/[!"#$%&'()*+,./:;<=>?@[\\\]^`{|}~-]+/g,De=/(^-|-$)/g;function je(e){return e.replace(Re,"-").replace(De,"")}var Te=function(e){return Q(te(e)>>>0)};function xe(e){return "string"==typeof e&&("production"===process.env.NODE_ENV||e.charAt(0)===e.charAt(0).toLowerCase())}var ke=function(e){return "function"==typeof e||"object"==typeof e&&null!==e&&!Array.isArray(e)},Ve=function(e){return "__proto__"!==e&&"constructor"!==e&&"prototype"!==e};function ze(e,t,n){var r=e[n];ke(t)&&ke(r)?Be(r,t):e[n]=t;}function Be(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];for(var o=0,s=n;o<s.length;o++){var i=s[o];if(ke(i))for(var a in i)Ve(a)&&ze(e,i[a],a);}return e}var Me=React__default.createContext(),Ge=Me.Consumer;function Le(e){var t=React.useContext(Me),n=React.useMemo((function(){return function(e,t){if(!e)return D(14);if(E(e)){var n=e(t);return "production"===process.env.NODE_ENV||null!==n&&!Array.isArray(n)&&"object"==typeof n?n:D(7)}return Array.isArray(e)||"object"!=typeof e?D(8):t?y$1({},t,{},e):e}(e.theme,t)}),[e.theme,t]);return e.children?React__default.createElement(Me.Provider,{value:n},e.children):null}var Fe={};function Ye(e,t,n){var o=_(e),i=!xe(e),a=t.attrs,c=void 0===a?S:a,d=t.componentId,h=void 0===d?function(e,t){var n="string"!=typeof e?"sc":je(e);Fe[n]=(Fe[n]||0)+1;var r=n+"-"+Te("5.3.5"+n+Fe[n]);return t?t+"-"+r:r}(t.displayName,t.parentComponentId):d,p=t.displayName,v=void 0===p?function(e){return xe(e)?"styled."+e:"Styled("+b$1(e)+")"}(e):p,g=t.displayName&&t.componentId?je(t.displayName)+"-"+t.componentId:t.componentId||h,N=o&&e.attrs?Array.prototype.concat(e.attrs,c).filter(Boolean):c,A=t.shouldForwardProp;o&&e.shouldForwardProp&&(A=t.shouldForwardProp?function(n,r,o){return e.shouldForwardProp(n,r,o)&&t.shouldForwardProp(n,r,o)}:e.shouldForwardProp);var C,I=new oe(n,g,o?e.componentStyle:void 0),P=I.isStatic&&0===c.length,O=function(e,t){return function(e,t,n,r){var o=e.attrs,i=e.componentStyle,a=e.defaultProps,c=e.foldedComponentIds,d=e.shouldForwardProp,h=e.styledComponentId,p=e.target;"production"!==process.env.NODE_ENV&&React.useDebugValue(h);var m=function(e,t,n){void 0===e&&(e=w$1);var r=y$1({},t,{theme:e}),o={};return n.forEach((function(e){var t,n,s,i=e;for(t in E(i)&&(i=i(r)),i)r[t]=o[t]="className"===t?(n=o[t],s=i[t],n&&s?n+" "+s:n||s):i[t];})),[r,o]}(Oe(t,React.useContext(Me),a)||w$1,t,o),v=m[0],g=m[1],S=function(e,t,n,r){var o=pe(),s=fe(),i=t?e.generateAndInjectStyles(w$1,o,s):e.generateAndInjectStyles(n,o,s);return "production"!==process.env.NODE_ENV&&React.useDebugValue(i),"production"!==process.env.NODE_ENV&&!t&&r&&r(i),i}(i,r,v,"production"!==process.env.NODE_ENV?e.warnTooManyClasses:void 0),b=n,_=g.$as||t.$as||g.as||t.as||p,N=xe(_),A=g!==t?y$1({},t,{},g):t,C={};for(var I in A)"$"!==I[0]&&"as"!==I&&("forwardedAs"===I?C.as=A[I]:(d?d(I,isPropValid,_):!N||isPropValid(I))&&(C[I]=A[I]));return t.style&&g.style!==t.style&&(C.style=y$1({},t.style,{},g.style)),C.className=Array.prototype.concat(c,h,S!==h?S:null,t.className,g.className).filter(Boolean).join(" "),C.ref=b,React.createElement(_,C)}(C,e,t,P)};return O.displayName=v,(C=React__default.forwardRef(O)).attrs=N,C.componentStyle=I,C.displayName=v,C.shouldForwardProp=A,C.foldedComponentIds=o?Array.prototype.concat(e.foldedComponentIds,e.styledComponentId):S,C.styledComponentId=g,C.target=o?e.target:e,C.withComponent=function(e){var r=t.componentId,o=function(e,t){if(null==e)return {};var n,r,o={},s=Object.keys(e);for(r=0;r<s.length;r++)n=s[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(t,["componentId"]),s=r&&r+"-"+(xe(e)?e:je(b$1(e)));return Ye(e,y$1({},o,{attrs:N,componentId:s}),n)},Object.defineProperty(C,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(t){this._foldedDefaultProps=o?Be({},e.defaultProps,t):t;}}),"production"!==process.env.NODE_ENV&&(Pe(v,g),C.warnTooManyClasses=function(e,t){var n={},r=!1;return function(o){if(!r&&(n[o]=!0,Object.keys(n).length>=200)){var s=t?' with the id of "'+t+'"':"";console.warn("Over 200 classes were generated for component "+e+s+".\nConsider using the attrs method, together with a style object for frequently changed styles.\nExample:\n const Component = styled.div.attrs(props => ({\n style: {\n background: props.background,\n },\n }))`width: 100%;`\n\n <Component />"),r=!0,n={};}}}(v,g)),C.toString=function(){return "."+C.styledComponentId},i&&hoistNonReactStatics_cjs(C,e,{attrs:!0,componentStyle:!0,displayName:!0,foldedComponentIds:!0,shouldForwardProp:!0,styledComponentId:!0,target:!0,withComponent:!0}),C}var qe=function(e){return function e(t,r,o){if(void 0===o&&(o=w$1),!reactIs_27(r))return D(1,String(r));var s=function(){return t(r,o,Ae.apply(void 0,arguments))};return s.withConfig=function(n){return e(t,r,y$1({},o,{},n))},s.attrs=function(n){return e(t,r,y$1({},o,{attrs:Array.prototype.concat(o.attrs,n).filter(Boolean)}))},s}(Ye,e)};["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","textPath","tspan"].forEach((function(e){qe[e]=qe(e);}));"production"!==process.env.NODE_ENV&&"undefined"!=typeof navigator&&"ReactNative"===navigator.product&&console.warn("It looks like you've imported 'styled-components' on React Native.\nPerhaps you're looking to import 'styled-components/native'?\nRead more about this at https://www.styled-components.com/docs/basics#react-native"),"production"!==process.env.NODE_ENV&&"test"!==process.env.NODE_ENV&&"undefined"!=typeof window&&(window["__styled-components-init__"]=window["__styled-components-init__"]||0,1===window["__styled-components-init__"]&&console.warn("It looks like there are several instances of 'styled-components' initialized in this application. This may cause dynamic styles to not render properly, errors during the rehydration process, a missing theme prop, and makes your application bigger without good reason.\n\nSee https://s-c.sh/2BAXzed for more info."),window["__styled-components-init__"]+=1);
|
|
1296
|
+
function _extends$1() {
|
|
1297
|
+
_extends$1 = Object.assign || function (target) {
|
|
1298
|
+
for (var i = 1; i < arguments.length; i++) {
|
|
1299
|
+
var source = arguments[i];
|
|
1300
|
+
|
|
1301
|
+
for (var key in source) {
|
|
1302
|
+
if (Object.prototype.hasOwnProperty.call(source, key)) {
|
|
1303
|
+
target[key] = source[key];
|
|
1304
|
+
}
|
|
1305
|
+
}
|
|
1306
|
+
}
|
|
1307
|
+
|
|
1308
|
+
return target;
|
|
1309
|
+
};
|
|
1310
|
+
|
|
1311
|
+
return _extends$1.apply(this, arguments);
|
|
1312
|
+
}
|
|
1313
|
+
|
|
1314
|
+
function _objectWithoutPropertiesLoose$1(source, excluded) {
|
|
1315
|
+
if (source == null) return {};
|
|
1316
|
+
var target = {};
|
|
1317
|
+
var sourceKeys = Object.keys(source);
|
|
1318
|
+
var key, i;
|
|
1319
|
+
|
|
1320
|
+
for (i = 0; i < sourceKeys.length; i++) {
|
|
1321
|
+
key = sourceKeys[i];
|
|
1322
|
+
if (excluded.indexOf(key) >= 0) continue;
|
|
1323
|
+
target[key] = source[key];
|
|
1324
|
+
}
|
|
1325
|
+
|
|
1326
|
+
return target;
|
|
1327
|
+
}
|
|
1328
|
+
|
|
1329
|
+
//
|
|
1330
|
+
var interleave = (function (strings, interpolations) {
|
|
1331
|
+
var result = [strings[0]];
|
|
1332
|
+
|
|
1333
|
+
for (var i = 0, len = interpolations.length; i < len; i += 1) {
|
|
1334
|
+
result.push(interpolations[i], strings[i + 1]);
|
|
1335
|
+
}
|
|
1336
|
+
|
|
1337
|
+
return result;
|
|
1338
|
+
});
|
|
1339
|
+
|
|
1340
|
+
//
|
|
1341
|
+
var isPlainObject = (function (x) {
|
|
1342
|
+
return x !== null && typeof x === 'object' && (x.toString ? x.toString() : Object.prototype.toString.call(x)) === '[object Object]' && !reactIs_28(x);
|
|
1343
|
+
});
|
|
1344
|
+
|
|
1345
|
+
//
|
|
1346
|
+
var EMPTY_ARRAY = Object.freeze([]);
|
|
1347
|
+
var EMPTY_OBJECT = Object.freeze({});
|
|
1348
|
+
|
|
1349
|
+
//
|
|
1350
|
+
function isFunction(test) {
|
|
1351
|
+
return typeof test === 'function';
|
|
1352
|
+
}
|
|
1353
|
+
|
|
1354
|
+
//
|
|
1355
|
+
function getComponentName(target) {
|
|
1356
|
+
return (process.env.NODE_ENV !== 'production' ? typeof target === 'string' && target : false) || // $FlowFixMe
|
|
1357
|
+
target.displayName || // $FlowFixMe
|
|
1358
|
+
target.name || 'Component';
|
|
1359
|
+
}
|
|
1360
|
+
|
|
1361
|
+
//
|
|
1362
|
+
function isStatelessFunction(test) {
|
|
1363
|
+
return typeof test === 'function' && !(test.prototype && test.prototype.isReactComponent);
|
|
1364
|
+
}
|
|
1365
|
+
|
|
1366
|
+
//
|
|
1367
|
+
function isStyledComponent(target) {
|
|
1368
|
+
return target && typeof target.styledComponentId === 'string';
|
|
1369
|
+
}
|
|
1370
|
+
|
|
1371
|
+
//
|
|
1372
|
+
var SC_ATTR = typeof process !== 'undefined' && (process.env.REACT_APP_SC_ATTR || process.env.SC_ATTR) || 'data-styled';
|
|
1373
|
+
var SC_ATTR_ACTIVE = 'active';
|
|
1374
|
+
var SC_ATTR_VERSION = 'data-styled-version';
|
|
1375
|
+
var SC_VERSION = "5.1.1";
|
|
1376
|
+
var SPLITTER = '/*!sc*/\n';
|
|
1377
|
+
var IS_BROWSER = typeof window !== 'undefined' && 'HTMLElement' in window;
|
|
1378
|
+
var DISABLE_SPEEDY = typeof SC_DISABLE_SPEEDY === 'boolean' && SC_DISABLE_SPEEDY || typeof process !== 'undefined' && (process.env.REACT_APP_SC_DISABLE_SPEEDY || process.env.SC_DISABLE_SPEEDY) || process.env.NODE_ENV !== 'production'; // Shared empty execution context when generating static styles
|
|
1379
|
+
|
|
1380
|
+
//
|
|
1381
|
+
|
|
1382
|
+
/* eslint-disable camelcase, no-undef */
|
|
1383
|
+
var getNonce = function getNonce() {
|
|
1384
|
+
return typeof __webpack_nonce__ !== 'undefined' ? __webpack_nonce__ : null;
|
|
1385
|
+
};
|
|
1386
|
+
|
|
1387
|
+
var errorMap = {
|
|
1388
|
+
"1": "Cannot create styled-component for component: %s.\n\n",
|
|
1389
|
+
"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",
|
|
1390
|
+
"3": "Streaming SSR is only supported in a Node.js environment; Please do not try to call this method in the browser.\n\n",
|
|
1391
|
+
"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",
|
|
1392
|
+
"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",
|
|
1393
|
+
"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",
|
|
1394
|
+
"7": "ThemeProvider: Please return an object from your \"theme\" prop function, e.g.\n\n```js\ntheme={() => ({})}\n```\n\n",
|
|
1395
|
+
"8": "ThemeProvider: Please make your \"theme\" prop an object.\n\n",
|
|
1396
|
+
"9": "Missing document `<head>`\n\n",
|
|
1397
|
+
"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",
|
|
1398
|
+
"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",
|
|
1399
|
+
"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",
|
|
1400
|
+
"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",
|
|
1401
|
+
"14": "ThemeProvider: \"theme\" prop is required.\n\n",
|
|
1402
|
+
"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",
|
|
1403
|
+
"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",
|
|
1404
|
+
"17": "CSSStyleSheet could not be found on HTMLStyleElement.\nHas styled-components' style tag been unmounted or altered by another script?\n"
|
|
1405
|
+
};
|
|
1406
|
+
|
|
1407
|
+
//
|
|
1408
|
+
var ERRORS = process.env.NODE_ENV !== 'production' ? errorMap : {};
|
|
1409
|
+
/**
|
|
1410
|
+
* super basic version of sprintf
|
|
1411
|
+
*/
|
|
1412
|
+
|
|
1413
|
+
function format() {
|
|
1414
|
+
var a = arguments.length <= 0 ? undefined : arguments[0];
|
|
1415
|
+
var b = [];
|
|
1416
|
+
|
|
1417
|
+
for (var c = 1, len = arguments.length; c < len; c += 1) {
|
|
1418
|
+
b.push(c < 0 || arguments.length <= c ? undefined : arguments[c]);
|
|
1419
|
+
}
|
|
1420
|
+
|
|
1421
|
+
b.forEach(function (d) {
|
|
1422
|
+
a = a.replace(/%[a-z]/, d);
|
|
1423
|
+
});
|
|
1424
|
+
return a;
|
|
1425
|
+
}
|
|
1426
|
+
/**
|
|
1427
|
+
* Create an error file out of errors.md for development and a simple web link to the full errors
|
|
1428
|
+
* in production mode.
|
|
1429
|
+
*/
|
|
1430
|
+
|
|
1431
|
+
|
|
1432
|
+
function throwStyledComponentsError(code) {
|
|
1433
|
+
for (var _len = arguments.length, interpolations = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
|
1434
|
+
interpolations[_key - 1] = arguments[_key];
|
|
1435
|
+
}
|
|
1436
|
+
|
|
1437
|
+
if (process.env.NODE_ENV === 'production') {
|
|
1438
|
+
throw new Error("An error occurred. See https://github.com/styled-components/styled-components/blob/master/packages/styled-components/src/utils/errors.md#" + code + " for more information." + (interpolations.length > 0 ? " Additional arguments: " + interpolations.join(', ') : ''));
|
|
1439
|
+
} else {
|
|
1440
|
+
throw new Error(format.apply(void 0, [ERRORS[code]].concat(interpolations)).trim());
|
|
1441
|
+
}
|
|
1442
|
+
}
|
|
1443
|
+
|
|
1444
|
+
//
|
|
1445
|
+
var ELEMENT_TYPE = 1;
|
|
1446
|
+
/* Node.ELEMENT_TYPE */
|
|
1447
|
+
|
|
1448
|
+
/** Find last style element if any inside target */
|
|
1449
|
+
|
|
1450
|
+
var findLastStyleTag = function findLastStyleTag(target) {
|
|
1451
|
+
var childNodes = target.childNodes;
|
|
1452
|
+
|
|
1453
|
+
for (var i = childNodes.length; i >= 0; i--) {
|
|
1454
|
+
var child = childNodes[i];
|
|
1455
|
+
|
|
1456
|
+
if (child && child.nodeType === ELEMENT_TYPE && child.hasAttribute(SC_ATTR)) {
|
|
1457
|
+
return child;
|
|
1458
|
+
}
|
|
1459
|
+
}
|
|
1460
|
+
|
|
1461
|
+
return undefined;
|
|
1462
|
+
};
|
|
1463
|
+
/** Create a style element inside `target` or <head> after the last */
|
|
1464
|
+
|
|
1465
|
+
|
|
1466
|
+
var makeStyleTag = function makeStyleTag(target) {
|
|
1467
|
+
var head = document.head;
|
|
1468
|
+
var parent = target || head;
|
|
1469
|
+
var style = document.createElement('style');
|
|
1470
|
+
var prevStyle = findLastStyleTag(parent);
|
|
1471
|
+
var nextSibling = prevStyle !== undefined ? prevStyle.nextSibling : null;
|
|
1472
|
+
style.setAttribute(SC_ATTR, SC_ATTR_ACTIVE);
|
|
1473
|
+
style.setAttribute(SC_ATTR_VERSION, SC_VERSION);
|
|
1474
|
+
var nonce = getNonce();
|
|
1475
|
+
if (nonce) style.setAttribute('nonce', nonce);
|
|
1476
|
+
parent.insertBefore(style, nextSibling);
|
|
1477
|
+
return style;
|
|
1478
|
+
};
|
|
1479
|
+
/** Get the CSSStyleSheet instance for a given style element */
|
|
1480
|
+
|
|
1481
|
+
var getSheet = function getSheet(tag) {
|
|
1482
|
+
if (tag.sheet) {
|
|
1483
|
+
return tag.sheet;
|
|
1484
|
+
} // Avoid Firefox quirk where the style element might not have a sheet property
|
|
1485
|
+
|
|
1486
|
+
|
|
1487
|
+
var _document = document,
|
|
1488
|
+
styleSheets = _document.styleSheets;
|
|
1489
|
+
|
|
1490
|
+
for (var i = 0, l = styleSheets.length; i < l; i++) {
|
|
1491
|
+
var sheet = styleSheets[i];
|
|
1492
|
+
|
|
1493
|
+
if (sheet.ownerNode === tag) {
|
|
1494
|
+
return sheet;
|
|
1495
|
+
}
|
|
1496
|
+
}
|
|
1497
|
+
|
|
1498
|
+
throwStyledComponentsError(17);
|
|
1499
|
+
return undefined;
|
|
1500
|
+
};
|
|
1501
|
+
|
|
1502
|
+
//
|
|
1503
|
+
/** Create a CSSStyleSheet-like tag depending on the environment */
|
|
1504
|
+
|
|
1505
|
+
var makeTag = function makeTag(_ref) {
|
|
1506
|
+
var isServer = _ref.isServer,
|
|
1507
|
+
useCSSOMInjection = _ref.useCSSOMInjection,
|
|
1508
|
+
target = _ref.target;
|
|
1509
|
+
|
|
1510
|
+
if (isServer) {
|
|
1511
|
+
return new VirtualTag(target);
|
|
1512
|
+
} else if (useCSSOMInjection) {
|
|
1513
|
+
return new CSSOMTag(target);
|
|
1514
|
+
} else {
|
|
1515
|
+
return new TextTag(target);
|
|
1516
|
+
}
|
|
1517
|
+
};
|
|
1518
|
+
var CSSOMTag = /*#__PURE__*/function () {
|
|
1519
|
+
function CSSOMTag(target) {
|
|
1520
|
+
var element = this.element = makeStyleTag(target); // Avoid Edge bug where empty style elements don't create sheets
|
|
1521
|
+
|
|
1522
|
+
element.appendChild(document.createTextNode(''));
|
|
1523
|
+
this.sheet = getSheet(element);
|
|
1524
|
+
this.length = 0;
|
|
1525
|
+
}
|
|
1526
|
+
|
|
1527
|
+
var _proto = CSSOMTag.prototype;
|
|
1528
|
+
|
|
1529
|
+
_proto.insertRule = function insertRule(index, rule) {
|
|
1530
|
+
try {
|
|
1531
|
+
this.sheet.insertRule(rule, index);
|
|
1532
|
+
this.length++;
|
|
1533
|
+
return true;
|
|
1534
|
+
} catch (_error) {
|
|
1535
|
+
return false;
|
|
1536
|
+
}
|
|
1537
|
+
};
|
|
1538
|
+
|
|
1539
|
+
_proto.deleteRule = function deleteRule(index) {
|
|
1540
|
+
this.sheet.deleteRule(index);
|
|
1541
|
+
this.length--;
|
|
1542
|
+
};
|
|
1543
|
+
|
|
1544
|
+
_proto.getRule = function getRule(index) {
|
|
1545
|
+
var rule = this.sheet.cssRules[index]; // Avoid IE11 quirk where cssText is inaccessible on some invalid rules
|
|
1546
|
+
|
|
1547
|
+
if (rule !== undefined && typeof rule.cssText === 'string') {
|
|
1548
|
+
return rule.cssText;
|
|
1549
|
+
} else {
|
|
1550
|
+
return '';
|
|
1551
|
+
}
|
|
1552
|
+
};
|
|
1553
|
+
|
|
1554
|
+
return CSSOMTag;
|
|
1555
|
+
}();
|
|
1556
|
+
/** A Tag that emulates the CSSStyleSheet API but uses text nodes */
|
|
1557
|
+
|
|
1558
|
+
var TextTag = /*#__PURE__*/function () {
|
|
1559
|
+
function TextTag(target) {
|
|
1560
|
+
var element = this.element = makeStyleTag(target);
|
|
1561
|
+
this.nodes = element.childNodes;
|
|
1562
|
+
this.length = 0;
|
|
1563
|
+
}
|
|
1564
|
+
|
|
1565
|
+
var _proto2 = TextTag.prototype;
|
|
1566
|
+
|
|
1567
|
+
_proto2.insertRule = function insertRule(index, rule) {
|
|
1568
|
+
if (index <= this.length && index >= 0) {
|
|
1569
|
+
var node = document.createTextNode(rule);
|
|
1570
|
+
var refNode = this.nodes[index];
|
|
1571
|
+
this.element.insertBefore(node, refNode || null);
|
|
1572
|
+
this.length++;
|
|
1573
|
+
return true;
|
|
1574
|
+
} else {
|
|
1575
|
+
return false;
|
|
1576
|
+
}
|
|
1577
|
+
};
|
|
1578
|
+
|
|
1579
|
+
_proto2.deleteRule = function deleteRule(index) {
|
|
1580
|
+
this.element.removeChild(this.nodes[index]);
|
|
1581
|
+
this.length--;
|
|
1582
|
+
};
|
|
1583
|
+
|
|
1584
|
+
_proto2.getRule = function getRule(index) {
|
|
1585
|
+
if (index < this.length) {
|
|
1586
|
+
return this.nodes[index].textContent;
|
|
1587
|
+
} else {
|
|
1588
|
+
return '';
|
|
1589
|
+
}
|
|
1590
|
+
};
|
|
1591
|
+
|
|
1592
|
+
return TextTag;
|
|
1593
|
+
}();
|
|
1594
|
+
/** A completely virtual (server-side) Tag that doesn't manipulate the DOM */
|
|
1595
|
+
|
|
1596
|
+
var VirtualTag = /*#__PURE__*/function () {
|
|
1597
|
+
function VirtualTag(_target) {
|
|
1598
|
+
this.rules = [];
|
|
1599
|
+
this.length = 0;
|
|
1600
|
+
}
|
|
1601
|
+
|
|
1602
|
+
var _proto3 = VirtualTag.prototype;
|
|
1603
|
+
|
|
1604
|
+
_proto3.insertRule = function insertRule(index, rule) {
|
|
1605
|
+
if (index <= this.length) {
|
|
1606
|
+
this.rules.splice(index, 0, rule);
|
|
1607
|
+
this.length++;
|
|
1608
|
+
return true;
|
|
1609
|
+
} else {
|
|
1610
|
+
return false;
|
|
1611
|
+
}
|
|
1612
|
+
};
|
|
1613
|
+
|
|
1614
|
+
_proto3.deleteRule = function deleteRule(index) {
|
|
1615
|
+
this.rules.splice(index, 1);
|
|
1616
|
+
this.length--;
|
|
1617
|
+
};
|
|
1618
|
+
|
|
1619
|
+
_proto3.getRule = function getRule(index) {
|
|
1620
|
+
if (index < this.length) {
|
|
1621
|
+
return this.rules[index];
|
|
1622
|
+
} else {
|
|
1623
|
+
return '';
|
|
1624
|
+
}
|
|
1625
|
+
};
|
|
1626
|
+
|
|
1627
|
+
return VirtualTag;
|
|
1628
|
+
}();
|
|
1629
|
+
|
|
1630
|
+
//
|
|
1631
|
+
/** Create a GroupedTag with an underlying Tag implementation */
|
|
1632
|
+
|
|
1633
|
+
var makeGroupedTag = function makeGroupedTag(tag) {
|
|
1634
|
+
return new DefaultGroupedTag(tag);
|
|
1635
|
+
};
|
|
1636
|
+
var BASE_SIZE = 1 << 9;
|
|
1637
|
+
|
|
1638
|
+
var DefaultGroupedTag = /*#__PURE__*/function () {
|
|
1639
|
+
function DefaultGroupedTag(tag) {
|
|
1640
|
+
this.groupSizes = new Uint32Array(BASE_SIZE);
|
|
1641
|
+
this.length = BASE_SIZE;
|
|
1642
|
+
this.tag = tag;
|
|
1643
|
+
}
|
|
1644
|
+
|
|
1645
|
+
var _proto = DefaultGroupedTag.prototype;
|
|
1646
|
+
|
|
1647
|
+
_proto.indexOfGroup = function indexOfGroup(group) {
|
|
1648
|
+
var index = 0;
|
|
1649
|
+
|
|
1650
|
+
for (var i = 0; i < group; i++) {
|
|
1651
|
+
index += this.groupSizes[i];
|
|
1652
|
+
}
|
|
1653
|
+
|
|
1654
|
+
return index;
|
|
1655
|
+
};
|
|
1656
|
+
|
|
1657
|
+
_proto.insertRules = function insertRules(group, rules) {
|
|
1658
|
+
if (group >= this.groupSizes.length) {
|
|
1659
|
+
var oldBuffer = this.groupSizes;
|
|
1660
|
+
var oldSize = oldBuffer.length;
|
|
1661
|
+
var newSize = oldSize;
|
|
1662
|
+
|
|
1663
|
+
while (group >= newSize) {
|
|
1664
|
+
newSize <<= 1;
|
|
1665
|
+
|
|
1666
|
+
if (newSize < 0) {
|
|
1667
|
+
throwStyledComponentsError(16, "" + group);
|
|
1668
|
+
}
|
|
1669
|
+
}
|
|
1670
|
+
|
|
1671
|
+
this.groupSizes = new Uint32Array(newSize);
|
|
1672
|
+
this.groupSizes.set(oldBuffer);
|
|
1673
|
+
this.length = newSize;
|
|
1674
|
+
|
|
1675
|
+
for (var i = oldSize; i < newSize; i++) {
|
|
1676
|
+
this.groupSizes[i] = 0;
|
|
1677
|
+
}
|
|
1678
|
+
}
|
|
1679
|
+
|
|
1680
|
+
var ruleIndex = this.indexOfGroup(group + 1);
|
|
1681
|
+
|
|
1682
|
+
for (var _i = 0, l = rules.length; _i < l; _i++) {
|
|
1683
|
+
if (this.tag.insertRule(ruleIndex, rules[_i])) {
|
|
1684
|
+
this.groupSizes[group]++;
|
|
1685
|
+
ruleIndex++;
|
|
1686
|
+
}
|
|
1687
|
+
}
|
|
1688
|
+
};
|
|
1689
|
+
|
|
1690
|
+
_proto.clearGroup = function clearGroup(group) {
|
|
1691
|
+
if (group < this.length) {
|
|
1692
|
+
var length = this.groupSizes[group];
|
|
1693
|
+
var startIndex = this.indexOfGroup(group);
|
|
1694
|
+
var endIndex = startIndex + length;
|
|
1695
|
+
this.groupSizes[group] = 0;
|
|
1696
|
+
|
|
1697
|
+
for (var i = startIndex; i < endIndex; i++) {
|
|
1698
|
+
this.tag.deleteRule(startIndex);
|
|
1699
|
+
}
|
|
1700
|
+
}
|
|
1701
|
+
};
|
|
1702
|
+
|
|
1703
|
+
_proto.getGroup = function getGroup(group) {
|
|
1704
|
+
var css = '';
|
|
1705
|
+
|
|
1706
|
+
if (group >= this.length || this.groupSizes[group] === 0) {
|
|
1707
|
+
return css;
|
|
1708
|
+
}
|
|
1709
|
+
|
|
1710
|
+
var length = this.groupSizes[group];
|
|
1711
|
+
var startIndex = this.indexOfGroup(group);
|
|
1712
|
+
var endIndex = startIndex + length;
|
|
1713
|
+
|
|
1714
|
+
for (var i = startIndex; i < endIndex; i++) {
|
|
1715
|
+
css += "" + this.tag.getRule(i) + SPLITTER;
|
|
1716
|
+
}
|
|
1717
|
+
|
|
1718
|
+
return css;
|
|
1719
|
+
};
|
|
1720
|
+
|
|
1721
|
+
return DefaultGroupedTag;
|
|
1722
|
+
}();
|
|
1723
|
+
|
|
1724
|
+
//
|
|
1725
|
+
var MAX_SMI = 1 << 31 - 1;
|
|
1726
|
+
var groupIDRegister = new Map();
|
|
1727
|
+
var reverseRegister = new Map();
|
|
1728
|
+
var nextFreeGroup = 1;
|
|
1729
|
+
var getGroupForId = function getGroupForId(id) {
|
|
1730
|
+
if (groupIDRegister.has(id)) {
|
|
1731
|
+
return groupIDRegister.get(id);
|
|
1732
|
+
}
|
|
1733
|
+
|
|
1734
|
+
var group = nextFreeGroup++;
|
|
1735
|
+
|
|
1736
|
+
if (process.env.NODE_ENV !== 'production' && ((group | 0) < 0 || group > MAX_SMI)) {
|
|
1737
|
+
throwStyledComponentsError(16, "" + group);
|
|
1738
|
+
}
|
|
1739
|
+
|
|
1740
|
+
groupIDRegister.set(id, group);
|
|
1741
|
+
reverseRegister.set(group, id);
|
|
1742
|
+
return group;
|
|
1743
|
+
};
|
|
1744
|
+
var getIdForGroup = function getIdForGroup(group) {
|
|
1745
|
+
return reverseRegister.get(group);
|
|
1746
|
+
};
|
|
1747
|
+
var setGroupForId = function setGroupForId(id, group) {
|
|
1748
|
+
if (group >= nextFreeGroup) {
|
|
1749
|
+
nextFreeGroup = group + 1;
|
|
1750
|
+
}
|
|
1751
|
+
|
|
1752
|
+
groupIDRegister.set(id, group);
|
|
1753
|
+
reverseRegister.set(group, id);
|
|
1754
|
+
};
|
|
1755
|
+
|
|
1756
|
+
//
|
|
1757
|
+
var SELECTOR = "style[" + SC_ATTR + "][" + SC_ATTR_VERSION + "=\"" + SC_VERSION + "\"]";
|
|
1758
|
+
var MARKER_RE = new RegExp("^" + SC_ATTR + "\\.g(\\d+)\\[id=\"([\\w\\d-]+)\"\\].*?\"([^\"]*)");
|
|
1759
|
+
var outputSheet = function outputSheet(sheet) {
|
|
1760
|
+
var tag = sheet.getTag();
|
|
1761
|
+
var length = tag.length;
|
|
1762
|
+
var css = '';
|
|
1763
|
+
|
|
1764
|
+
for (var group = 0; group < length; group++) {
|
|
1765
|
+
var id = getIdForGroup(group);
|
|
1766
|
+
if (id === undefined) continue;
|
|
1767
|
+
var names = sheet.names.get(id);
|
|
1768
|
+
var rules = tag.getGroup(group);
|
|
1769
|
+
if (names === undefined || rules.length === 0) continue;
|
|
1770
|
+
var selector = SC_ATTR + ".g" + group + "[id=\"" + id + "\"]";
|
|
1771
|
+
var content = '';
|
|
1772
|
+
|
|
1773
|
+
if (names !== undefined) {
|
|
1774
|
+
names.forEach(function (name) {
|
|
1775
|
+
if (name.length > 0) {
|
|
1776
|
+
content += name + ",";
|
|
1777
|
+
}
|
|
1778
|
+
});
|
|
1779
|
+
} // NOTE: It's easier to collect rules and have the marker
|
|
1780
|
+
// after the actual rules to simplify the rehydration
|
|
1781
|
+
|
|
1782
|
+
|
|
1783
|
+
css += "" + rules + selector + "{content:\"" + content + "\"}" + SPLITTER;
|
|
1784
|
+
}
|
|
1785
|
+
|
|
1786
|
+
return css;
|
|
1787
|
+
};
|
|
1788
|
+
|
|
1789
|
+
var rehydrateNamesFromContent = function rehydrateNamesFromContent(sheet, id, content) {
|
|
1790
|
+
var names = content.split(',');
|
|
1791
|
+
var name;
|
|
1792
|
+
|
|
1793
|
+
for (var i = 0, l = names.length; i < l; i++) {
|
|
1794
|
+
// eslint-disable-next-line
|
|
1795
|
+
if (name = names[i]) {
|
|
1796
|
+
sheet.registerName(id, name);
|
|
1797
|
+
}
|
|
1798
|
+
}
|
|
1799
|
+
};
|
|
1800
|
+
|
|
1801
|
+
var rehydrateSheetFromTag = function rehydrateSheetFromTag(sheet, style) {
|
|
1802
|
+
var parts = style.innerHTML.split(SPLITTER);
|
|
1803
|
+
var rules = [];
|
|
1804
|
+
|
|
1805
|
+
for (var i = 0, l = parts.length; i < l; i++) {
|
|
1806
|
+
var part = parts[i].trim();
|
|
1807
|
+
if (!part) continue;
|
|
1808
|
+
var marker = part.match(MARKER_RE);
|
|
1809
|
+
|
|
1810
|
+
if (marker) {
|
|
1811
|
+
var group = parseInt(marker[1], 10) | 0;
|
|
1812
|
+
var id = marker[2];
|
|
1813
|
+
|
|
1814
|
+
if (group !== 0) {
|
|
1815
|
+
// Rehydrate componentId to group index mapping
|
|
1816
|
+
setGroupForId(id, group); // Rehydrate names and rules
|
|
1817
|
+
// looks like: data-styled.g11[id="idA"]{content:"nameA,"}
|
|
1818
|
+
|
|
1819
|
+
rehydrateNamesFromContent(sheet, id, marker[3]);
|
|
1820
|
+
sheet.getTag().insertRules(group, rules);
|
|
1821
|
+
}
|
|
1822
|
+
|
|
1823
|
+
rules.length = 0;
|
|
1824
|
+
} else {
|
|
1825
|
+
rules.push(part);
|
|
1826
|
+
}
|
|
1827
|
+
}
|
|
1828
|
+
};
|
|
1829
|
+
|
|
1830
|
+
var rehydrateSheet = function rehydrateSheet(sheet) {
|
|
1831
|
+
var nodes = document.querySelectorAll(SELECTOR);
|
|
1832
|
+
|
|
1833
|
+
for (var i = 0, l = nodes.length; i < l; i++) {
|
|
1834
|
+
var node = nodes[i];
|
|
1835
|
+
|
|
1836
|
+
if (node && node.getAttribute(SC_ATTR) !== SC_ATTR_ACTIVE) {
|
|
1837
|
+
rehydrateSheetFromTag(sheet, node);
|
|
1838
|
+
|
|
1839
|
+
if (node.parentNode) {
|
|
1840
|
+
node.parentNode.removeChild(node);
|
|
1841
|
+
}
|
|
1842
|
+
}
|
|
1843
|
+
}
|
|
1844
|
+
};
|
|
1845
|
+
|
|
1846
|
+
var SHOULD_REHYDRATE = IS_BROWSER;
|
|
1847
|
+
var defaultOptions = {
|
|
1848
|
+
isServer: !IS_BROWSER,
|
|
1849
|
+
useCSSOMInjection: !DISABLE_SPEEDY
|
|
1850
|
+
};
|
|
1851
|
+
/** Contains the main stylesheet logic for stringification and caching */
|
|
1852
|
+
|
|
1853
|
+
var StyleSheet = /*#__PURE__*/function () {
|
|
1854
|
+
/** Register a group ID to give it an index */
|
|
1855
|
+
StyleSheet.registerId = function registerId(id) {
|
|
1856
|
+
return getGroupForId(id);
|
|
1857
|
+
};
|
|
1858
|
+
|
|
1859
|
+
function StyleSheet(options, globalStyles, names) {
|
|
1860
|
+
if (options === void 0) {
|
|
1861
|
+
options = defaultOptions;
|
|
1862
|
+
}
|
|
1863
|
+
|
|
1864
|
+
if (globalStyles === void 0) {
|
|
1865
|
+
globalStyles = {};
|
|
1866
|
+
}
|
|
1867
|
+
|
|
1868
|
+
this.options = _extends$1({}, defaultOptions, {}, options);
|
|
1869
|
+
this.gs = globalStyles;
|
|
1870
|
+
this.names = new Map(names); // We rehydrate only once and use the sheet that is created first
|
|
1871
|
+
|
|
1872
|
+
if (!this.options.isServer && IS_BROWSER && SHOULD_REHYDRATE) {
|
|
1873
|
+
SHOULD_REHYDRATE = false;
|
|
1874
|
+
rehydrateSheet(this);
|
|
1875
|
+
}
|
|
1876
|
+
}
|
|
1877
|
+
|
|
1878
|
+
var _proto = StyleSheet.prototype;
|
|
1879
|
+
|
|
1880
|
+
_proto.reconstructWithOptions = function reconstructWithOptions(options) {
|
|
1881
|
+
return new StyleSheet(_extends$1({}, this.options, {}, options), this.gs, this.names);
|
|
1882
|
+
};
|
|
1883
|
+
|
|
1884
|
+
_proto.allocateGSInstance = function allocateGSInstance(id) {
|
|
1885
|
+
return this.gs[id] = (this.gs[id] || 0) + 1;
|
|
1886
|
+
}
|
|
1887
|
+
/** Lazily initialises a GroupedTag for when it's actually needed */
|
|
1888
|
+
;
|
|
1889
|
+
|
|
1890
|
+
_proto.getTag = function getTag() {
|
|
1891
|
+
return this.tag || (this.tag = makeGroupedTag(makeTag(this.options)));
|
|
1892
|
+
}
|
|
1893
|
+
/** Check whether a name is known for caching */
|
|
1894
|
+
;
|
|
1895
|
+
|
|
1896
|
+
_proto.hasNameForId = function hasNameForId(id, name) {
|
|
1897
|
+
return this.names.has(id) && this.names.get(id).has(name);
|
|
1898
|
+
}
|
|
1899
|
+
/** Mark a group's name as known for caching */
|
|
1900
|
+
;
|
|
1901
|
+
|
|
1902
|
+
_proto.registerName = function registerName(id, name) {
|
|
1903
|
+
getGroupForId(id);
|
|
1904
|
+
|
|
1905
|
+
if (!this.names.has(id)) {
|
|
1906
|
+
var groupNames = new Set();
|
|
1907
|
+
groupNames.add(name);
|
|
1908
|
+
this.names.set(id, groupNames);
|
|
1909
|
+
} else {
|
|
1910
|
+
this.names.get(id).add(name);
|
|
1911
|
+
}
|
|
1912
|
+
}
|
|
1913
|
+
/** Insert new rules which also marks the name as known */
|
|
1914
|
+
;
|
|
1915
|
+
|
|
1916
|
+
_proto.insertRules = function insertRules(id, name, rules) {
|
|
1917
|
+
this.registerName(id, name);
|
|
1918
|
+
this.getTag().insertRules(getGroupForId(id), rules);
|
|
1919
|
+
}
|
|
1920
|
+
/** Clears all cached names for a given group ID */
|
|
1921
|
+
;
|
|
1922
|
+
|
|
1923
|
+
_proto.clearNames = function clearNames(id) {
|
|
1924
|
+
if (this.names.has(id)) {
|
|
1925
|
+
this.names.get(id).clear();
|
|
1926
|
+
}
|
|
1927
|
+
}
|
|
1928
|
+
/** Clears all rules for a given group ID */
|
|
1929
|
+
;
|
|
1930
|
+
|
|
1931
|
+
_proto.clearRules = function clearRules(id) {
|
|
1932
|
+
this.getTag().clearGroup(getGroupForId(id));
|
|
1933
|
+
this.clearNames(id);
|
|
1934
|
+
}
|
|
1935
|
+
/** Clears the entire tag which deletes all rules but not its names */
|
|
1936
|
+
;
|
|
1937
|
+
|
|
1938
|
+
_proto.clearTag = function clearTag() {
|
|
1939
|
+
// NOTE: This does not clear the names, since it's only used during SSR
|
|
1940
|
+
// so that we can continuously output only new rules
|
|
1941
|
+
this.tag = undefined;
|
|
1942
|
+
}
|
|
1943
|
+
/** Outputs the current sheet as a CSS string with markers for SSR */
|
|
1944
|
+
;
|
|
1945
|
+
|
|
1946
|
+
_proto.toString = function toString() {
|
|
1947
|
+
return outputSheet(this);
|
|
1948
|
+
};
|
|
1949
|
+
|
|
1950
|
+
return StyleSheet;
|
|
1951
|
+
}();
|
|
1952
|
+
|
|
1953
|
+
//
|
|
1954
|
+
|
|
1955
|
+
/* eslint-disable */
|
|
1956
|
+
var SEED = 5381; // When we have separate strings it's useful to run a progressive
|
|
1957
|
+
// version of djb2 where we pretend that we're still looping over
|
|
1958
|
+
// the same string
|
|
1959
|
+
|
|
1960
|
+
var phash = function phash(h, x) {
|
|
1961
|
+
var i = x.length;
|
|
1962
|
+
|
|
1963
|
+
while (i) {
|
|
1964
|
+
h = h * 33 ^ x.charCodeAt(--i);
|
|
1965
|
+
}
|
|
1966
|
+
|
|
1967
|
+
return h;
|
|
1968
|
+
}; // This is a djb2 hashing function
|
|
1969
|
+
|
|
1970
|
+
var hash = function hash(x) {
|
|
1971
|
+
return phash(SEED, x);
|
|
1972
|
+
};
|
|
1973
|
+
|
|
1974
|
+
/**
|
|
1975
|
+
* MIT License
|
|
1976
|
+
*
|
|
1977
|
+
* Copyright (c) 2016 Sultan Tarimo
|
|
1978
|
+
*
|
|
1979
|
+
* Permission is hereby granted, free of charge, to any person obtaining a copy of
|
|
1980
|
+
* this software and associated documentation files (the "Software"),
|
|
1981
|
+
* to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
|
|
1982
|
+
* sell copies of the Software and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
|
1983
|
+
*
|
|
1984
|
+
* The above copyright notice and this permission notice shall be included in all
|
|
1985
|
+
* copies or substantial portions of the Software.
|
|
1986
|
+
*
|
|
1987
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
|
|
1988
|
+
* OR IMPLIED INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
1989
|
+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
1990
|
+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
1991
|
+
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
|
|
1992
|
+
* IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
1993
|
+
*/
|
|
1994
|
+
|
|
1995
|
+
/* eslint-disable */
|
|
1996
|
+
function insertRulePlugin (insertRule) {
|
|
1997
|
+
var delimiter = '/*|*/';
|
|
1998
|
+
var needle = delimiter + "}";
|
|
1999
|
+
|
|
2000
|
+
function toSheet(block) {
|
|
2001
|
+
if (block) {
|
|
2002
|
+
try {
|
|
2003
|
+
insertRule(block + "}");
|
|
2004
|
+
} catch (e) {}
|
|
2005
|
+
}
|
|
2006
|
+
}
|
|
2007
|
+
|
|
2008
|
+
return function ruleSheet(context, content, selectors, parents, line, column, length, ns, depth, at) {
|
|
2009
|
+
switch (context) {
|
|
2010
|
+
// property
|
|
2011
|
+
case 1:
|
|
2012
|
+
// @import
|
|
2013
|
+
if (depth === 0 && content.charCodeAt(0) === 64) return insertRule(content + ";"), '';
|
|
2014
|
+
break;
|
|
2015
|
+
// selector
|
|
2016
|
+
|
|
2017
|
+
case 2:
|
|
2018
|
+
if (ns === 0) return content + delimiter;
|
|
2019
|
+
break;
|
|
2020
|
+
// at-rule
|
|
2021
|
+
|
|
2022
|
+
case 3:
|
|
2023
|
+
switch (ns) {
|
|
2024
|
+
// @font-face, @page
|
|
2025
|
+
case 102:
|
|
2026
|
+
case 112:
|
|
2027
|
+
return insertRule(selectors[0] + content), '';
|
|
2028
|
+
|
|
2029
|
+
default:
|
|
2030
|
+
return content + (at === 0 ? delimiter : '');
|
|
2031
|
+
}
|
|
2032
|
+
|
|
2033
|
+
case -2:
|
|
2034
|
+
content.split(needle).forEach(toSheet);
|
|
2035
|
+
}
|
|
2036
|
+
};
|
|
2037
|
+
}
|
|
2038
|
+
|
|
2039
|
+
var COMMENT_REGEX = /^\s*\/\/.*$/gm;
|
|
2040
|
+
function createStylisInstance(_temp) {
|
|
2041
|
+
var _ref = _temp === void 0 ? EMPTY_OBJECT : _temp,
|
|
2042
|
+
_ref$options = _ref.options,
|
|
2043
|
+
options = _ref$options === void 0 ? EMPTY_OBJECT : _ref$options,
|
|
2044
|
+
_ref$plugins = _ref.plugins,
|
|
2045
|
+
plugins = _ref$plugins === void 0 ? EMPTY_ARRAY : _ref$plugins;
|
|
2046
|
+
|
|
2047
|
+
var stylis = new stylis_min(options); // Wrap `insertRulePlugin to build a list of rules,
|
|
2048
|
+
// and then make our own plugin to return the rules. This
|
|
2049
|
+
// makes it easier to hook into the existing SSR architecture
|
|
2050
|
+
|
|
2051
|
+
var parsingRules = []; // eslint-disable-next-line consistent-return
|
|
2052
|
+
|
|
2053
|
+
var returnRulesPlugin = function returnRulesPlugin(context) {
|
|
2054
|
+
if (context === -2) {
|
|
2055
|
+
var parsedRules = parsingRules;
|
|
2056
|
+
parsingRules = [];
|
|
2057
|
+
return parsedRules;
|
|
2058
|
+
}
|
|
2059
|
+
};
|
|
2060
|
+
|
|
2061
|
+
var parseRulesPlugin = insertRulePlugin(function (rule) {
|
|
2062
|
+
parsingRules.push(rule);
|
|
2063
|
+
});
|
|
2064
|
+
|
|
2065
|
+
var _componentId;
|
|
2066
|
+
|
|
2067
|
+
var _selector;
|
|
2068
|
+
|
|
2069
|
+
var _selectorRegexp;
|
|
2070
|
+
|
|
2071
|
+
var selfReferenceReplacer = function selfReferenceReplacer(match, offset, string) {
|
|
2072
|
+
if ( // the first self-ref is always untouched
|
|
2073
|
+
offset > 0 && // there should be at least two self-refs to do a replacement (.b > .b)
|
|
2074
|
+
string.slice(0, offset).indexOf(_selector) !== -1 && // no consecutive self refs (.b.b); that is a precedence boost and treated differently
|
|
2075
|
+
string.slice(offset - _selector.length, offset) !== _selector) {
|
|
2076
|
+
return "." + _componentId;
|
|
2077
|
+
}
|
|
2078
|
+
|
|
2079
|
+
return match;
|
|
2080
|
+
};
|
|
2081
|
+
/**
|
|
2082
|
+
* When writing a style like
|
|
2083
|
+
*
|
|
2084
|
+
* & + & {
|
|
2085
|
+
* color: red;
|
|
2086
|
+
* }
|
|
2087
|
+
*
|
|
2088
|
+
* The second ampersand should be a reference to the static component class. stylis
|
|
2089
|
+
* has no knowledge of static class so we have to intelligently replace the base selector.
|
|
2090
|
+
*
|
|
2091
|
+
* https://github.com/thysultan/stylis.js#plugins <- more info about the context phase values
|
|
2092
|
+
* "2" means this plugin is taking effect at the very end after all other processing is complete
|
|
2093
|
+
*/
|
|
2094
|
+
|
|
2095
|
+
|
|
2096
|
+
var selfReferenceReplacementPlugin = function selfReferenceReplacementPlugin(context, _, selectors) {
|
|
2097
|
+
if (context === 2 && selectors.length && selectors[0].lastIndexOf(_selector) > 0) {
|
|
2098
|
+
// eslint-disable-next-line no-param-reassign
|
|
2099
|
+
selectors[0] = selectors[0].replace(_selectorRegexp, selfReferenceReplacer);
|
|
2100
|
+
}
|
|
2101
|
+
};
|
|
2102
|
+
|
|
2103
|
+
stylis.use([].concat(plugins, [selfReferenceReplacementPlugin, parseRulesPlugin, returnRulesPlugin]));
|
|
2104
|
+
|
|
2105
|
+
function stringifyRules(css, selector, prefix, componentId) {
|
|
2106
|
+
if (componentId === void 0) {
|
|
2107
|
+
componentId = '&';
|
|
2108
|
+
}
|
|
2109
|
+
|
|
2110
|
+
var flatCSS = css.replace(COMMENT_REGEX, '');
|
|
2111
|
+
var cssStr = selector && prefix ? prefix + " " + selector + " { " + flatCSS + " }" : flatCSS; // stylis has no concept of state to be passed to plugins
|
|
2112
|
+
// but since JS is single=threaded, we can rely on that to ensure
|
|
2113
|
+
// these properties stay in sync with the current stylis run
|
|
2114
|
+
|
|
2115
|
+
_componentId = componentId;
|
|
2116
|
+
_selector = selector;
|
|
2117
|
+
_selectorRegexp = new RegExp("\\" + _selector + "\\b", 'g');
|
|
2118
|
+
return stylis(prefix || !selector ? '' : selector, cssStr);
|
|
2119
|
+
}
|
|
2120
|
+
|
|
2121
|
+
stringifyRules.hash = plugins.length ? plugins.reduce(function (acc, plugin) {
|
|
2122
|
+
if (!plugin.name) {
|
|
2123
|
+
throwStyledComponentsError(15);
|
|
2124
|
+
}
|
|
2125
|
+
|
|
2126
|
+
return phash(acc, plugin.name);
|
|
2127
|
+
}, SEED).toString() : '';
|
|
2128
|
+
return stringifyRules;
|
|
2129
|
+
}
|
|
2130
|
+
|
|
2131
|
+
//
|
|
2132
|
+
var StyleSheetContext = React__default.createContext();
|
|
2133
|
+
var StyleSheetConsumer = StyleSheetContext.Consumer;
|
|
2134
|
+
var StylisContext = React__default.createContext();
|
|
2135
|
+
var StylisConsumer = StylisContext.Consumer;
|
|
2136
|
+
var masterSheet = new StyleSheet();
|
|
2137
|
+
var masterStylis = createStylisInstance();
|
|
2138
|
+
function useStyleSheet() {
|
|
2139
|
+
return React.useContext(StyleSheetContext) || masterSheet;
|
|
2140
|
+
}
|
|
2141
|
+
function useStylis() {
|
|
2142
|
+
return React.useContext(StylisContext) || masterStylis;
|
|
2143
|
+
}
|
|
2144
|
+
|
|
2145
|
+
//
|
|
2146
|
+
|
|
2147
|
+
var Keyframes = /*#__PURE__*/function () {
|
|
2148
|
+
function Keyframes(name, stringifyArgs) {
|
|
2149
|
+
var _this = this;
|
|
2150
|
+
|
|
2151
|
+
this.inject = function (styleSheet) {
|
|
2152
|
+
if (!styleSheet.hasNameForId(_this.id, _this.name)) {
|
|
2153
|
+
styleSheet.insertRules(_this.id, _this.name, masterStylis.apply(void 0, _this.stringifyArgs));
|
|
2154
|
+
}
|
|
2155
|
+
};
|
|
2156
|
+
|
|
2157
|
+
this.toString = function () {
|
|
2158
|
+
return throwStyledComponentsError(12, String(_this.name));
|
|
2159
|
+
};
|
|
2160
|
+
|
|
2161
|
+
this.name = name;
|
|
2162
|
+
this.id = "sc-keyframes-" + name;
|
|
2163
|
+
this.stringifyArgs = stringifyArgs;
|
|
2164
|
+
}
|
|
2165
|
+
|
|
2166
|
+
var _proto = Keyframes.prototype;
|
|
2167
|
+
|
|
2168
|
+
_proto.getName = function getName() {
|
|
2169
|
+
return this.name;
|
|
2170
|
+
};
|
|
2171
|
+
|
|
2172
|
+
return Keyframes;
|
|
2173
|
+
}();
|
|
2174
|
+
|
|
2175
|
+
//
|
|
2176
|
+
|
|
2177
|
+
/**
|
|
2178
|
+
* inlined version of
|
|
2179
|
+
* https://github.com/facebook/fbjs/blob/master/packages/fbjs/src/core/hyphenateStyleName.js
|
|
2180
|
+
*/
|
|
2181
|
+
var uppercasePattern = /([A-Z])/g;
|
|
2182
|
+
var msPattern = /^ms-/;
|
|
2183
|
+
/**
|
|
2184
|
+
* Hyphenates a camelcased CSS property name, for example:
|
|
2185
|
+
*
|
|
2186
|
+
* > hyphenateStyleName('backgroundColor')
|
|
2187
|
+
* < "background-color"
|
|
2188
|
+
* > hyphenateStyleName('MozTransition')
|
|
2189
|
+
* < "-moz-transition"
|
|
2190
|
+
* > hyphenateStyleName('msTransition')
|
|
2191
|
+
* < "-ms-transition"
|
|
2192
|
+
*
|
|
2193
|
+
* As Modernizr suggests (http://modernizr.com/docs/#prefixed), an `ms` prefix
|
|
2194
|
+
* is converted to `-ms-`.
|
|
2195
|
+
*
|
|
2196
|
+
* @param {string} string
|
|
2197
|
+
* @return {string}
|
|
2198
|
+
*/
|
|
2199
|
+
|
|
2200
|
+
function hyphenateStyleName(string) {
|
|
2201
|
+
return string.replace(uppercasePattern, '-$1').toLowerCase().replace(msPattern, '-ms-');
|
|
2202
|
+
}
|
|
2203
|
+
|
|
2204
|
+
//
|
|
2205
|
+
|
|
2206
|
+
function addUnitIfNeeded(name, value) {
|
|
2207
|
+
// https://github.com/amilajack/eslint-plugin-flowtype-errors/issues/133
|
|
2208
|
+
// $FlowFixMe
|
|
2209
|
+
if (value == null || typeof value === 'boolean' || value === '') {
|
|
2210
|
+
return '';
|
|
2211
|
+
}
|
|
2212
|
+
|
|
2213
|
+
if (typeof value === 'number' && value !== 0 && !(name in unitlessKeys)) {
|
|
2214
|
+
return value + "px"; // Presumes implicit 'px' suffix for unitless numbers
|
|
2215
|
+
}
|
|
2216
|
+
|
|
2217
|
+
return String(value).trim();
|
|
2218
|
+
}
|
|
2219
|
+
|
|
2220
|
+
//
|
|
2221
|
+
/**
|
|
2222
|
+
* It's falsish not falsy because 0 is allowed.
|
|
2223
|
+
*/
|
|
2224
|
+
|
|
2225
|
+
var isFalsish = function isFalsish(chunk) {
|
|
2226
|
+
return chunk === undefined || chunk === null || chunk === false || chunk === '';
|
|
2227
|
+
};
|
|
2228
|
+
|
|
2229
|
+
var objToCssArray = function objToCssArray(obj, prevKey) {
|
|
2230
|
+
var rules = [];
|
|
2231
|
+
var keys = Object.keys(obj);
|
|
2232
|
+
keys.forEach(function (key) {
|
|
2233
|
+
if (!isFalsish(obj[key])) {
|
|
2234
|
+
if (isPlainObject(obj[key])) {
|
|
2235
|
+
rules.push.apply(rules, objToCssArray(obj[key], key));
|
|
2236
|
+
return rules;
|
|
2237
|
+
} else if (isFunction(obj[key])) {
|
|
2238
|
+
rules.push(hyphenateStyleName(key) + ":", obj[key], ';');
|
|
2239
|
+
return rules;
|
|
2240
|
+
}
|
|
2241
|
+
|
|
2242
|
+
rules.push(hyphenateStyleName(key) + ": " + addUnitIfNeeded(key, obj[key]) + ";");
|
|
2243
|
+
}
|
|
2244
|
+
|
|
2245
|
+
return rules;
|
|
2246
|
+
});
|
|
2247
|
+
return prevKey ? [prevKey + " {"].concat(rules, ['}']) : rules;
|
|
2248
|
+
};
|
|
2249
|
+
function flatten(chunk, executionContext, styleSheet) {
|
|
2250
|
+
if (Array.isArray(chunk)) {
|
|
2251
|
+
var ruleSet = [];
|
|
2252
|
+
|
|
2253
|
+
for (var i = 0, len = chunk.length, result; i < len; i += 1) {
|
|
2254
|
+
result = flatten(chunk[i], executionContext, styleSheet);
|
|
2255
|
+
if (result === '') continue;else if (Array.isArray(result)) ruleSet.push.apply(ruleSet, result);else ruleSet.push(result);
|
|
2256
|
+
}
|
|
2257
|
+
|
|
2258
|
+
return ruleSet;
|
|
2259
|
+
}
|
|
2260
|
+
|
|
2261
|
+
if (isFalsish(chunk)) {
|
|
2262
|
+
return '';
|
|
2263
|
+
}
|
|
2264
|
+
/* Handle other components */
|
|
2265
|
+
|
|
2266
|
+
|
|
2267
|
+
if (isStyledComponent(chunk)) {
|
|
2268
|
+
return "." + chunk.styledComponentId;
|
|
2269
|
+
}
|
|
2270
|
+
/* Either execute or defer the function */
|
|
2271
|
+
|
|
2272
|
+
|
|
2273
|
+
if (isFunction(chunk)) {
|
|
2274
|
+
if (isStatelessFunction(chunk) && executionContext) {
|
|
2275
|
+
var _result = chunk(executionContext);
|
|
2276
|
+
|
|
2277
|
+
if (process.env.NODE_ENV !== 'production' && reactIs_18(_result)) {
|
|
2278
|
+
// eslint-disable-next-line no-console
|
|
2279
|
+
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.");
|
|
2280
|
+
}
|
|
2281
|
+
|
|
2282
|
+
return flatten(_result, executionContext, styleSheet);
|
|
2283
|
+
} else return chunk;
|
|
2284
|
+
}
|
|
2285
|
+
|
|
2286
|
+
if (chunk instanceof Keyframes) {
|
|
2287
|
+
if (styleSheet) {
|
|
2288
|
+
chunk.inject(styleSheet);
|
|
2289
|
+
return chunk.getName();
|
|
2290
|
+
} else return chunk;
|
|
2291
|
+
}
|
|
2292
|
+
/* Handle objects */
|
|
2293
|
+
|
|
2294
|
+
|
|
2295
|
+
return isPlainObject(chunk) ? objToCssArray(chunk) : chunk.toString();
|
|
2296
|
+
}
|
|
2297
|
+
|
|
2298
|
+
//
|
|
2299
|
+
function css(styles) {
|
|
2300
|
+
for (var _len = arguments.length, interpolations = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
|
2301
|
+
interpolations[_key - 1] = arguments[_key];
|
|
2302
|
+
}
|
|
2303
|
+
|
|
2304
|
+
if (isFunction(styles) || isPlainObject(styles)) {
|
|
2305
|
+
// $FlowFixMe
|
|
2306
|
+
return flatten(interleave(EMPTY_ARRAY, [styles].concat(interpolations)));
|
|
2307
|
+
}
|
|
2308
|
+
|
|
2309
|
+
if (interpolations.length === 0 && styles.length === 1 && typeof styles[0] === "string") {
|
|
2310
|
+
// $FlowFixMe
|
|
2311
|
+
return styles;
|
|
2312
|
+
} // $FlowFixMe
|
|
2313
|
+
|
|
2314
|
+
|
|
2315
|
+
return flatten(interleave(styles, interpolations));
|
|
2316
|
+
}
|
|
2317
|
+
|
|
2318
|
+
function constructWithOptions(componentConstructor, tag, options) {
|
|
2319
|
+
if (options === void 0) {
|
|
2320
|
+
options = EMPTY_OBJECT;
|
|
2321
|
+
}
|
|
2322
|
+
|
|
2323
|
+
if (!reactIs_27(tag)) {
|
|
2324
|
+
return throwStyledComponentsError(1, String(tag));
|
|
2325
|
+
}
|
|
2326
|
+
/* This is callable directly as a template function */
|
|
2327
|
+
// $FlowFixMe: Not typed to avoid destructuring arguments
|
|
2328
|
+
|
|
2329
|
+
|
|
2330
|
+
var templateFunction = function templateFunction() {
|
|
2331
|
+
return componentConstructor(tag, options, css.apply(void 0, arguments));
|
|
2332
|
+
};
|
|
2333
|
+
/* If config methods are called, wrap up a new template function and merge options */
|
|
2334
|
+
|
|
2335
|
+
|
|
2336
|
+
templateFunction.withConfig = function (config) {
|
|
2337
|
+
return constructWithOptions(componentConstructor, tag, _extends$1({}, options, {}, config));
|
|
2338
|
+
};
|
|
2339
|
+
/* Modify/inject new props at runtime */
|
|
2340
|
+
|
|
2341
|
+
|
|
2342
|
+
templateFunction.attrs = function (attrs) {
|
|
2343
|
+
return constructWithOptions(componentConstructor, tag, _extends$1({}, options, {
|
|
2344
|
+
attrs: Array.prototype.concat(options.attrs, attrs).filter(Boolean)
|
|
2345
|
+
}));
|
|
2346
|
+
};
|
|
2347
|
+
|
|
2348
|
+
return templateFunction;
|
|
2349
|
+
}
|
|
2350
|
+
|
|
2351
|
+
/* eslint-disable */
|
|
2352
|
+
|
|
2353
|
+
/**
|
|
2354
|
+
mixin-deep; https://github.com/jonschlinkert/mixin-deep
|
|
2355
|
+
Inlined such that it will be consistently transpiled to an IE-compatible syntax.
|
|
2356
|
+
|
|
2357
|
+
The MIT License (MIT)
|
|
2358
|
+
|
|
2359
|
+
Copyright (c) 2014-present, Jon Schlinkert.
|
|
2360
|
+
|
|
2361
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
2362
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
2363
|
+
in the Software without restriction, including without limitation the rights
|
|
2364
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
2365
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
2366
|
+
furnished to do so, subject to the following conditions:
|
|
2367
|
+
|
|
2368
|
+
The above copyright notice and this permission notice shall be included in
|
|
2369
|
+
all copies or substantial portions of the Software.
|
|
2370
|
+
|
|
2371
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
2372
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
2373
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
2374
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
2375
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
2376
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
2377
|
+
THE SOFTWARE.
|
|
2378
|
+
*/
|
|
2379
|
+
var isObject = function isObject(val) {
|
|
2380
|
+
return typeof val === 'function' || typeof val === 'object' && val !== null && !Array.isArray(val);
|
|
2381
|
+
};
|
|
2382
|
+
|
|
2383
|
+
var isValidKey = function isValidKey(key) {
|
|
2384
|
+
return key !== '__proto__' && key !== 'constructor' && key !== 'prototype';
|
|
2385
|
+
};
|
|
2386
|
+
|
|
2387
|
+
function mixin(target, val, key) {
|
|
2388
|
+
var obj = target[key];
|
|
2389
|
+
|
|
2390
|
+
if (isObject(val) && isObject(obj)) {
|
|
2391
|
+
mixinDeep(obj, val);
|
|
2392
|
+
} else {
|
|
2393
|
+
target[key] = val;
|
|
2394
|
+
}
|
|
2395
|
+
}
|
|
2396
|
+
|
|
2397
|
+
function mixinDeep(target) {
|
|
2398
|
+
for (var _len = arguments.length, rest = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
|
2399
|
+
rest[_key - 1] = arguments[_key];
|
|
2400
|
+
}
|
|
2401
|
+
|
|
2402
|
+
for (var _i = 0, _rest = rest; _i < _rest.length; _i++) {
|
|
2403
|
+
var obj = _rest[_i];
|
|
2404
|
+
|
|
2405
|
+
if (isObject(obj)) {
|
|
2406
|
+
for (var key in obj) {
|
|
2407
|
+
if (isValidKey(key)) {
|
|
2408
|
+
mixin(target, obj[key], key);
|
|
2409
|
+
}
|
|
2410
|
+
}
|
|
2411
|
+
}
|
|
2412
|
+
}
|
|
2413
|
+
|
|
2414
|
+
return target;
|
|
2415
|
+
}
|
|
2416
|
+
|
|
2417
|
+
//
|
|
2418
|
+
|
|
2419
|
+
/* eslint-disable no-bitwise */
|
|
2420
|
+
var AD_REPLACER_R = /(a)(d)/gi;
|
|
2421
|
+
/* This is the "capacity" of our alphabet i.e. 2x26 for all letters plus their capitalised
|
|
2422
|
+
* counterparts */
|
|
2423
|
+
|
|
2424
|
+
var charsLength = 52;
|
|
2425
|
+
/* start at 75 for 'a' until 'z' (25) and then start at 65 for capitalised letters */
|
|
2426
|
+
|
|
2427
|
+
var getAlphabeticChar = function getAlphabeticChar(code) {
|
|
2428
|
+
return String.fromCharCode(code + (code > 25 ? 39 : 97));
|
|
2429
|
+
};
|
|
2430
|
+
/* input a number, usually a hash and convert it to base-52 */
|
|
2431
|
+
|
|
2432
|
+
|
|
2433
|
+
function generateAlphabeticName(code) {
|
|
2434
|
+
var name = '';
|
|
2435
|
+
var x;
|
|
2436
|
+
/* get a char and divide by alphabet-length */
|
|
2437
|
+
|
|
2438
|
+
for (x = Math.abs(code); x > charsLength; x = x / charsLength | 0) {
|
|
2439
|
+
name = getAlphabeticChar(x % charsLength) + name;
|
|
2440
|
+
}
|
|
2441
|
+
|
|
2442
|
+
return (getAlphabeticChar(x % charsLength) + name).replace(AD_REPLACER_R, '$1-$2');
|
|
2443
|
+
}
|
|
2444
|
+
|
|
2445
|
+
//
|
|
2446
|
+
function isStaticRules(rules) {
|
|
2447
|
+
for (var i = 0; i < rules.length; i += 1) {
|
|
2448
|
+
var rule = rules[i];
|
|
2449
|
+
|
|
2450
|
+
if (isFunction(rule) && !isStyledComponent(rule)) {
|
|
2451
|
+
// functions are allowed to be static if they're just being
|
|
2452
|
+
// used to get the classname of a nested styled component
|
|
2453
|
+
return false;
|
|
2454
|
+
}
|
|
2455
|
+
}
|
|
2456
|
+
|
|
2457
|
+
return true;
|
|
2458
|
+
}
|
|
2459
|
+
|
|
2460
|
+
//
|
|
2461
|
+
/*
|
|
2462
|
+
ComponentStyle is all the CSS-specific stuff, not
|
|
2463
|
+
the React-specific stuff.
|
|
2464
|
+
*/
|
|
2465
|
+
|
|
2466
|
+
var ComponentStyle = /*#__PURE__*/function () {
|
|
2467
|
+
function ComponentStyle(rules, componentId) {
|
|
2468
|
+
this.rules = rules;
|
|
2469
|
+
this.staticRulesId = '';
|
|
2470
|
+
this.isStatic = process.env.NODE_ENV === 'production' && isStaticRules(rules);
|
|
2471
|
+
this.componentId = componentId;
|
|
2472
|
+
this.baseHash = hash(componentId); // NOTE: This registers the componentId, which ensures a consistent order
|
|
2473
|
+
// for this component's styles compared to others
|
|
2474
|
+
|
|
2475
|
+
StyleSheet.registerId(componentId);
|
|
2476
|
+
}
|
|
2477
|
+
/*
|
|
2478
|
+
* Flattens a rule set into valid CSS
|
|
2479
|
+
* Hashes it, wraps the whole chunk in a .hash1234 {}
|
|
2480
|
+
* Returns the hash to be injected on render()
|
|
2481
|
+
* */
|
|
2482
|
+
|
|
2483
|
+
|
|
2484
|
+
var _proto = ComponentStyle.prototype;
|
|
2485
|
+
|
|
2486
|
+
_proto.generateAndInjectStyles = function generateAndInjectStyles(executionContext, styleSheet, stylis) {
|
|
2487
|
+
var componentId = this.componentId; // force dynamic classnames if user-supplied stylis plugins are in use
|
|
2488
|
+
|
|
2489
|
+
if (this.isStatic && !stylis.hash) {
|
|
2490
|
+
if (this.staticRulesId && styleSheet.hasNameForId(componentId, this.staticRulesId)) {
|
|
2491
|
+
return this.staticRulesId;
|
|
2492
|
+
}
|
|
2493
|
+
|
|
2494
|
+
var cssStatic = flatten(this.rules, executionContext, styleSheet).join('');
|
|
2495
|
+
var name = generateAlphabeticName(phash(this.baseHash, cssStatic.length) >>> 0);
|
|
2496
|
+
|
|
2497
|
+
if (!styleSheet.hasNameForId(componentId, name)) {
|
|
2498
|
+
var cssStaticFormatted = stylis(cssStatic, "." + name, undefined, componentId);
|
|
2499
|
+
styleSheet.insertRules(componentId, name, cssStaticFormatted);
|
|
2500
|
+
}
|
|
2501
|
+
|
|
2502
|
+
this.staticRulesId = name;
|
|
2503
|
+
return name;
|
|
2504
|
+
} else {
|
|
2505
|
+
var length = this.rules.length;
|
|
2506
|
+
var dynamicHash = phash(this.baseHash, stylis.hash);
|
|
2507
|
+
var css = '';
|
|
2508
|
+
|
|
2509
|
+
for (var i = 0; i < length; i++) {
|
|
2510
|
+
var partRule = this.rules[i];
|
|
2511
|
+
|
|
2512
|
+
if (typeof partRule === 'string') {
|
|
2513
|
+
css += partRule;
|
|
2514
|
+
if (process.env.NODE_ENV !== 'production') dynamicHash = phash(dynamicHash, partRule + i);
|
|
2515
|
+
} else {
|
|
2516
|
+
var partChunk = flatten(partRule, executionContext, styleSheet);
|
|
2517
|
+
var partString = Array.isArray(partChunk) ? partChunk.join('') : partChunk;
|
|
2518
|
+
dynamicHash = phash(dynamicHash, partString + i);
|
|
2519
|
+
css += partString;
|
|
2520
|
+
}
|
|
2521
|
+
}
|
|
2522
|
+
|
|
2523
|
+
var _name = generateAlphabeticName(dynamicHash >>> 0);
|
|
2524
|
+
|
|
2525
|
+
if (!styleSheet.hasNameForId(componentId, _name)) {
|
|
2526
|
+
var cssFormatted = stylis(css, "." + _name, undefined, componentId);
|
|
2527
|
+
styleSheet.insertRules(componentId, _name, cssFormatted);
|
|
2528
|
+
}
|
|
2529
|
+
|
|
2530
|
+
return _name;
|
|
2531
|
+
}
|
|
2532
|
+
};
|
|
2533
|
+
|
|
2534
|
+
return ComponentStyle;
|
|
2535
|
+
}();
|
|
2536
|
+
|
|
2537
|
+
//
|
|
2538
|
+
var LIMIT = 200;
|
|
2539
|
+
var createWarnTooManyClasses = (function (displayName, componentId) {
|
|
2540
|
+
var generatedClasses = {};
|
|
2541
|
+
var warningSeen = false;
|
|
2542
|
+
return function (className) {
|
|
2543
|
+
if (!warningSeen) {
|
|
2544
|
+
generatedClasses[className] = true;
|
|
2545
|
+
|
|
2546
|
+
if (Object.keys(generatedClasses).length >= LIMIT) {
|
|
2547
|
+
// Unable to find latestRule in test environment.
|
|
2548
|
+
|
|
2549
|
+
/* eslint-disable no-console, prefer-template */
|
|
2550
|
+
var parsedIdString = componentId ? " with the id of \"" + componentId + "\"" : '';
|
|
2551
|
+
console.warn("Over " + LIMIT + " classes were generated for component " + displayName + parsedIdString + ".\n" + 'Consider using the attrs method, together with a style object for frequently changed styles.\n' + 'Example:\n' + ' const Component = styled.div.attrs(props => ({\n' + ' style: {\n' + ' background: props.background,\n' + ' },\n' + ' }))`width: 100%;`\n\n' + ' <Component />');
|
|
2552
|
+
warningSeen = true;
|
|
2553
|
+
generatedClasses = {};
|
|
2554
|
+
}
|
|
2555
|
+
}
|
|
2556
|
+
};
|
|
2557
|
+
});
|
|
2558
|
+
|
|
2559
|
+
//
|
|
2560
|
+
var invalidHookCallRe = /invalid hook call/i;
|
|
2561
|
+
var seen = new Set();
|
|
2562
|
+
var checkDynamicCreation = function checkDynamicCreation(displayName, componentId) {
|
|
2563
|
+
if (process.env.NODE_ENV !== 'production') {
|
|
2564
|
+
var parsedIdString = componentId ? " with the id of \"" + componentId + "\"" : '';
|
|
2565
|
+
var message = "The component " + displayName + parsedIdString + " has been created dynamically.\n" + 'You may see this warning because you\'ve called styled inside another component.\n' + 'To resolve this only create new StyledComponents outside of any render method and function component.';
|
|
2566
|
+
|
|
2567
|
+
try {
|
|
2568
|
+
// We purposefully call `useRef` outside of a component and expect it to throw
|
|
2569
|
+
// If it doesn't, then we're inside another component.
|
|
2570
|
+
// eslint-disable-next-line react-hooks/rules-of-hooks
|
|
2571
|
+
React.useRef();
|
|
2572
|
+
|
|
2573
|
+
if (!seen.has(message)) {
|
|
2574
|
+
// eslint-disable-next-line no-console
|
|
2575
|
+
console.warn(message);
|
|
2576
|
+
seen.add(message);
|
|
2577
|
+
}
|
|
2578
|
+
} catch (error) {
|
|
2579
|
+
// The error here is expected, since we're expecting anything that uses `checkDynamicCreation` to
|
|
2580
|
+
// be called outside of a React component.
|
|
2581
|
+
if (invalidHookCallRe.test(error.message)) {
|
|
2582
|
+
// This shouldn't happen, but resets `warningSeen` if we had this error happen intermittently
|
|
2583
|
+
seen["delete"](message);
|
|
2584
|
+
}
|
|
2585
|
+
}
|
|
2586
|
+
}
|
|
2587
|
+
};
|
|
2588
|
+
|
|
2589
|
+
//
|
|
2590
|
+
var determineTheme = (function (props, providedTheme, defaultProps) {
|
|
2591
|
+
if (defaultProps === void 0) {
|
|
2592
|
+
defaultProps = EMPTY_OBJECT;
|
|
2593
|
+
}
|
|
2594
|
+
|
|
2595
|
+
return props.theme !== defaultProps.theme && props.theme || providedTheme || defaultProps.theme;
|
|
2596
|
+
});
|
|
2597
|
+
|
|
2598
|
+
//
|
|
2599
|
+
// Source: https://www.w3.org/TR/cssom-1/#serialize-an-identifier
|
|
2600
|
+
// Control characters and non-letter first symbols are not supported
|
|
2601
|
+
var escapeRegex = /[!"#$%&'()*+,./:;<=>?@[\\\]^`{|}~-]+/g;
|
|
2602
|
+
var dashesAtEnds = /(^-|-$)/g;
|
|
2603
|
+
/**
|
|
2604
|
+
* TODO: Explore using CSS.escape when it becomes more available
|
|
2605
|
+
* in evergreen browsers.
|
|
2606
|
+
*/
|
|
2607
|
+
|
|
2608
|
+
function escape(str) {
|
|
2609
|
+
return str // Replace all possible CSS selectors
|
|
2610
|
+
.replace(escapeRegex, '-') // Remove extraneous hyphens at the start and end
|
|
2611
|
+
.replace(dashesAtEnds, '');
|
|
2612
|
+
}
|
|
2613
|
+
|
|
2614
|
+
//
|
|
2615
|
+
function isTag(target) {
|
|
2616
|
+
return typeof target === 'string' && (process.env.NODE_ENV !== 'production' ? target.charAt(0) === target.charAt(0).toLowerCase() : true);
|
|
2617
|
+
}
|
|
2618
|
+
|
|
2619
|
+
//
|
|
2620
|
+
function generateDisplayName(target) {
|
|
2621
|
+
// $FlowFixMe
|
|
2622
|
+
return isTag(target) ? "styled." + target : "Styled(" + getComponentName(target) + ")";
|
|
2623
|
+
}
|
|
2624
|
+
|
|
2625
|
+
//
|
|
2626
|
+
var generateComponentId = (function (str) {
|
|
2627
|
+
return generateAlphabeticName(hash(str) >>> 0);
|
|
2628
|
+
});
|
|
2629
|
+
|
|
2630
|
+
/**
|
|
2631
|
+
* Convenience function for joining strings to form className chains
|
|
2632
|
+
*/
|
|
2633
|
+
function joinStrings(a, b) {
|
|
2634
|
+
return a && b ? a + " " + b : a || b;
|
|
2635
|
+
}
|
|
2636
|
+
|
|
2637
|
+
var ThemeContext = React__default.createContext();
|
|
2638
|
+
var ThemeConsumer = ThemeContext.Consumer;
|
|
2639
|
+
|
|
2640
|
+
function mergeTheme(theme, outerTheme) {
|
|
2641
|
+
if (!theme) {
|
|
2642
|
+
return throwStyledComponentsError(14);
|
|
2643
|
+
}
|
|
2644
|
+
|
|
2645
|
+
if (isFunction(theme)) {
|
|
2646
|
+
var mergedTheme = theme(outerTheme);
|
|
2647
|
+
|
|
2648
|
+
if (process.env.NODE_ENV !== 'production' && (mergedTheme === null || Array.isArray(mergedTheme) || typeof mergedTheme !== 'object')) {
|
|
2649
|
+
return throwStyledComponentsError(7);
|
|
2650
|
+
}
|
|
2651
|
+
|
|
2652
|
+
return mergedTheme;
|
|
2653
|
+
}
|
|
2654
|
+
|
|
2655
|
+
if (Array.isArray(theme) || typeof theme !== 'object') {
|
|
2656
|
+
return throwStyledComponentsError(8);
|
|
2657
|
+
}
|
|
2658
|
+
|
|
2659
|
+
return outerTheme ? _extends$1({}, outerTheme, {}, theme) : theme;
|
|
2660
|
+
}
|
|
2661
|
+
/**
|
|
2662
|
+
* Provide a theme to an entire react component tree via context
|
|
2663
|
+
*/
|
|
2664
|
+
|
|
2665
|
+
|
|
2666
|
+
function ThemeProvider(props) {
|
|
2667
|
+
var outerTheme = React.useContext(ThemeContext);
|
|
2668
|
+
var themeContext = React.useMemo(function () {
|
|
2669
|
+
return mergeTheme(props.theme, outerTheme);
|
|
2670
|
+
}, [props.theme, outerTheme]);
|
|
2671
|
+
|
|
2672
|
+
if (!props.children) {
|
|
2673
|
+
return null;
|
|
2674
|
+
}
|
|
2675
|
+
|
|
2676
|
+
return /*#__PURE__*/React__default.createElement(ThemeContext.Provider, {
|
|
2677
|
+
value: themeContext
|
|
2678
|
+
}, props.children);
|
|
2679
|
+
}
|
|
2680
|
+
|
|
2681
|
+
/* global $Call */
|
|
2682
|
+
|
|
2683
|
+
var identifiers = {};
|
|
2684
|
+
/* We depend on components having unique IDs */
|
|
2685
|
+
|
|
2686
|
+
function generateId(displayName, parentComponentId) {
|
|
2687
|
+
var name = typeof displayName !== 'string' ? 'sc' : escape(displayName); // Ensure that no displayName can lead to duplicate componentIds
|
|
2688
|
+
|
|
2689
|
+
identifiers[name] = (identifiers[name] || 0) + 1;
|
|
2690
|
+
var componentId = name + "-" + generateComponentId(name + identifiers[name]);
|
|
2691
|
+
return parentComponentId ? parentComponentId + "-" + componentId : componentId;
|
|
2692
|
+
}
|
|
2693
|
+
|
|
2694
|
+
function useResolvedAttrs(theme, props, attrs) {
|
|
2695
|
+
if (theme === void 0) {
|
|
2696
|
+
theme = EMPTY_OBJECT;
|
|
2697
|
+
}
|
|
2698
|
+
|
|
2699
|
+
// NOTE: can't memoize this
|
|
2700
|
+
// returns [context, resolvedAttrs]
|
|
2701
|
+
// where resolvedAttrs is only the things injected by the attrs themselves
|
|
2702
|
+
var context = _extends$1({}, props, {
|
|
2703
|
+
theme: theme
|
|
2704
|
+
});
|
|
2705
|
+
|
|
2706
|
+
var resolvedAttrs = {};
|
|
2707
|
+
attrs.forEach(function (attrDef) {
|
|
2708
|
+
var resolvedAttrDef = attrDef;
|
|
2709
|
+
var key;
|
|
2710
|
+
|
|
2711
|
+
if (isFunction(resolvedAttrDef)) {
|
|
2712
|
+
resolvedAttrDef = resolvedAttrDef(context);
|
|
2713
|
+
}
|
|
2714
|
+
/* eslint-disable guard-for-in */
|
|
2715
|
+
|
|
2716
|
+
|
|
2717
|
+
for (key in resolvedAttrDef) {
|
|
2718
|
+
context[key] = resolvedAttrs[key] = key === 'className' ? joinStrings(resolvedAttrs[key], resolvedAttrDef[key]) : resolvedAttrDef[key];
|
|
2719
|
+
}
|
|
2720
|
+
/* eslint-enable guard-for-in */
|
|
2721
|
+
|
|
2722
|
+
});
|
|
2723
|
+
return [context, resolvedAttrs];
|
|
2724
|
+
}
|
|
2725
|
+
|
|
2726
|
+
function useInjectedStyle(componentStyle, hasAttrs, resolvedAttrs, warnTooManyClasses) {
|
|
2727
|
+
var styleSheet = useStyleSheet();
|
|
2728
|
+
var stylis = useStylis(); // statically styled-components don't need to build an execution context object,
|
|
2729
|
+
// and shouldn't be increasing the number of class names
|
|
2730
|
+
|
|
2731
|
+
var isStatic = componentStyle.isStatic && !hasAttrs;
|
|
2732
|
+
var className = isStatic ? componentStyle.generateAndInjectStyles(EMPTY_OBJECT, styleSheet, stylis) : componentStyle.generateAndInjectStyles(resolvedAttrs, styleSheet, stylis);
|
|
2733
|
+
React.useDebugValue(className);
|
|
2734
|
+
|
|
2735
|
+
if (process.env.NODE_ENV !== 'production' && !isStatic && warnTooManyClasses) {
|
|
2736
|
+
warnTooManyClasses(className);
|
|
2737
|
+
}
|
|
2738
|
+
|
|
2739
|
+
return className;
|
|
2740
|
+
}
|
|
2741
|
+
|
|
2742
|
+
function useStyledComponentImpl(forwardedComponent, props, forwardedRef) {
|
|
2743
|
+
var componentAttrs = forwardedComponent.attrs,
|
|
2744
|
+
componentStyle = forwardedComponent.componentStyle,
|
|
2745
|
+
defaultProps = forwardedComponent.defaultProps,
|
|
2746
|
+
foldedComponentIds = forwardedComponent.foldedComponentIds,
|
|
2747
|
+
shouldForwardProp = forwardedComponent.shouldForwardProp,
|
|
2748
|
+
styledComponentId = forwardedComponent.styledComponentId,
|
|
2749
|
+
target = forwardedComponent.target;
|
|
2750
|
+
React.useDebugValue(styledComponentId); // NOTE: the non-hooks version only subscribes to this when !componentStyle.isStatic,
|
|
2751
|
+
// but that'd be against the rules-of-hooks. We could be naughty and do it anyway as it
|
|
2752
|
+
// should be an immutable value, but behave for now.
|
|
2753
|
+
|
|
2754
|
+
var theme = determineTheme(props, React.useContext(ThemeContext), defaultProps);
|
|
2755
|
+
|
|
2756
|
+
var _useResolvedAttrs = useResolvedAttrs(theme || EMPTY_OBJECT, props, componentAttrs),
|
|
2757
|
+
context = _useResolvedAttrs[0],
|
|
2758
|
+
attrs = _useResolvedAttrs[1];
|
|
2759
|
+
|
|
2760
|
+
var generatedClassName = useInjectedStyle(componentStyle, componentAttrs.length > 0, context, process.env.NODE_ENV !== 'production' ? forwardedComponent.warnTooManyClasses : undefined);
|
|
2761
|
+
var refToForward = forwardedRef;
|
|
2762
|
+
var elementToBeCreated = attrs.$as || props.$as || attrs.as || props.as || target;
|
|
2763
|
+
var isTargetTag = isTag(elementToBeCreated);
|
|
2764
|
+
var computedProps = attrs !== props ? _extends$1({}, props, {}, attrs) : props;
|
|
2765
|
+
var propFilterFn = shouldForwardProp || isTargetTag && index;
|
|
2766
|
+
var propsForElement = {}; // eslint-disable-next-line guard-for-in
|
|
2767
|
+
|
|
2768
|
+
for (var key in computedProps) {
|
|
2769
|
+
if (key[0] === '$' || key === 'as') continue;else if (key === 'forwardedAs') {
|
|
2770
|
+
propsForElement.as = computedProps[key];
|
|
2771
|
+
} else if (!propFilterFn || propFilterFn(key, index)) {
|
|
2772
|
+
// Don't pass through non HTML tags through to HTML elements
|
|
2773
|
+
propsForElement[key] = computedProps[key];
|
|
2774
|
+
}
|
|
2775
|
+
}
|
|
2776
|
+
|
|
2777
|
+
if (props.style && attrs.style !== props.style) {
|
|
2778
|
+
propsForElement.style = _extends$1({}, props.style, {}, attrs.style);
|
|
2779
|
+
}
|
|
2780
|
+
|
|
2781
|
+
propsForElement.className = Array.prototype.concat(foldedComponentIds, styledComponentId, generatedClassName !== styledComponentId ? generatedClassName : null, props.className, attrs.className).filter(Boolean).join(' ');
|
|
2782
|
+
propsForElement.ref = refToForward;
|
|
2783
|
+
return React.createElement(elementToBeCreated, propsForElement);
|
|
2784
|
+
}
|
|
2785
|
+
|
|
2786
|
+
function createStyledComponent(target, options, rules) {
|
|
2787
|
+
var isTargetStyledComp = isStyledComponent(target);
|
|
2788
|
+
var isCompositeComponent = !isTag(target);
|
|
2789
|
+
var _options$displayName = options.displayName,
|
|
2790
|
+
displayName = _options$displayName === void 0 ? generateDisplayName(target) : _options$displayName,
|
|
2791
|
+
_options$componentId = options.componentId,
|
|
2792
|
+
componentId = _options$componentId === void 0 ? generateId(options.displayName, options.parentComponentId) : _options$componentId,
|
|
2793
|
+
_options$attrs = options.attrs,
|
|
2794
|
+
attrs = _options$attrs === void 0 ? EMPTY_ARRAY : _options$attrs;
|
|
2795
|
+
var styledComponentId = options.displayName && options.componentId ? escape(options.displayName) + "-" + options.componentId : options.componentId || componentId; // fold the underlying StyledComponent attrs up (implicit extend)
|
|
2796
|
+
|
|
2797
|
+
var finalAttrs = // $FlowFixMe
|
|
2798
|
+
isTargetStyledComp && target.attrs ? Array.prototype.concat(target.attrs, attrs).filter(Boolean) : attrs; // eslint-disable-next-line prefer-destructuring
|
|
2799
|
+
|
|
2800
|
+
var shouldForwardProp = options.shouldForwardProp; // $FlowFixMe
|
|
2801
|
+
|
|
2802
|
+
if (isTargetStyledComp && target.shouldForwardProp) {
|
|
2803
|
+
if (shouldForwardProp) {
|
|
2804
|
+
// compose nested shouldForwardProp calls
|
|
2805
|
+
shouldForwardProp = function shouldForwardProp(prop, filterFn) {
|
|
2806
|
+
return (// $FlowFixMe
|
|
2807
|
+
target.shouldForwardProp(prop, filterFn) && options.shouldForwardProp(prop, filterFn)
|
|
2808
|
+
);
|
|
2809
|
+
};
|
|
2810
|
+
} else {
|
|
2811
|
+
// eslint-disable-next-line prefer-destructuring
|
|
2812
|
+
shouldForwardProp = target.shouldForwardProp;
|
|
2813
|
+
}
|
|
2814
|
+
}
|
|
2815
|
+
|
|
2816
|
+
var componentStyle = new ComponentStyle(isTargetStyledComp ? // fold the underlying StyledComponent rules up (implicit extend)
|
|
2817
|
+
// $FlowFixMe
|
|
2818
|
+
target.componentStyle.rules.concat(rules) : rules, styledComponentId);
|
|
2819
|
+
/**
|
|
2820
|
+
* forwardRef creates a new interim component, which we'll take advantage of
|
|
2821
|
+
* instead of extending ParentComponent to create _another_ interim class
|
|
2822
|
+
*/
|
|
2823
|
+
|
|
2824
|
+
var WrappedStyledComponent; // eslint-disable-next-line react-hooks/rules-of-hooks
|
|
2825
|
+
|
|
2826
|
+
var forwardRef = function forwardRef(props, ref) {
|
|
2827
|
+
return useStyledComponentImpl(WrappedStyledComponent, props, ref);
|
|
2828
|
+
};
|
|
2829
|
+
|
|
2830
|
+
forwardRef.displayName = displayName; // $FlowFixMe this is a forced cast to merge it StyledComponentWrapperProperties
|
|
2831
|
+
|
|
2832
|
+
WrappedStyledComponent = React__default.forwardRef(forwardRef);
|
|
2833
|
+
WrappedStyledComponent.attrs = finalAttrs;
|
|
2834
|
+
WrappedStyledComponent.componentStyle = componentStyle;
|
|
2835
|
+
WrappedStyledComponent.displayName = displayName;
|
|
2836
|
+
WrappedStyledComponent.shouldForwardProp = shouldForwardProp; // this static is used to preserve the cascade of static classes for component selector
|
|
2837
|
+
// purposes; this is especially important with usage of the css prop
|
|
2838
|
+
|
|
2839
|
+
WrappedStyledComponent.foldedComponentIds = isTargetStyledComp ? // $FlowFixMe
|
|
2840
|
+
Array.prototype.concat(target.foldedComponentIds, target.styledComponentId) : EMPTY_ARRAY;
|
|
2841
|
+
WrappedStyledComponent.styledComponentId = styledComponentId; // fold the underlying StyledComponent target up since we folded the styles
|
|
2842
|
+
|
|
2843
|
+
WrappedStyledComponent.target = isTargetStyledComp ? // $FlowFixMe
|
|
2844
|
+
target.target : target; // $FlowFixMe
|
|
2845
|
+
|
|
2846
|
+
WrappedStyledComponent.withComponent = function withComponent(tag) {
|
|
2847
|
+
var previousComponentId = options.componentId,
|
|
2848
|
+
optionsToCopy = _objectWithoutPropertiesLoose$1(options, ["componentId"]);
|
|
2849
|
+
|
|
2850
|
+
var newComponentId = previousComponentId && previousComponentId + "-" + (isTag(tag) ? tag : escape(getComponentName(tag)));
|
|
2851
|
+
|
|
2852
|
+
var newOptions = _extends$1({}, optionsToCopy, {
|
|
2853
|
+
attrs: finalAttrs,
|
|
2854
|
+
componentId: newComponentId
|
|
2855
|
+
});
|
|
2856
|
+
|
|
2857
|
+
return createStyledComponent(tag, newOptions, rules);
|
|
2858
|
+
}; // $FlowFixMe
|
|
2859
|
+
|
|
2860
|
+
|
|
2861
|
+
Object.defineProperty(WrappedStyledComponent, 'defaultProps', {
|
|
2862
|
+
get: function get() {
|
|
2863
|
+
return this._foldedDefaultProps;
|
|
2864
|
+
},
|
|
2865
|
+
set: function set(obj) {
|
|
2866
|
+
// $FlowFixMe
|
|
2867
|
+
this._foldedDefaultProps = isTargetStyledComp ? mixinDeep({}, target.defaultProps, obj) : obj;
|
|
2868
|
+
}
|
|
2869
|
+
});
|
|
2870
|
+
|
|
2871
|
+
if (process.env.NODE_ENV !== 'production') {
|
|
2872
|
+
checkDynamicCreation(displayName, styledComponentId);
|
|
2873
|
+
WrappedStyledComponent.warnTooManyClasses = createWarnTooManyClasses(displayName, styledComponentId);
|
|
2874
|
+
} // $FlowFixMe
|
|
2875
|
+
|
|
2876
|
+
|
|
2877
|
+
WrappedStyledComponent.toString = function () {
|
|
2878
|
+
return "." + WrappedStyledComponent.styledComponentId;
|
|
2879
|
+
};
|
|
2880
|
+
|
|
2881
|
+
if (isCompositeComponent) {
|
|
2882
|
+
hoistNonReactStatics_cjs(WrappedStyledComponent, target, {
|
|
2883
|
+
// all SC-specific things should not be hoisted
|
|
2884
|
+
attrs: true,
|
|
2885
|
+
componentStyle: true,
|
|
2886
|
+
displayName: true,
|
|
2887
|
+
foldedComponentIds: true,
|
|
2888
|
+
shouldForwardProp: true,
|
|
2889
|
+
self: true,
|
|
2890
|
+
styledComponentId: true,
|
|
2891
|
+
target: true,
|
|
2892
|
+
withComponent: true
|
|
2893
|
+
});
|
|
2894
|
+
}
|
|
2895
|
+
|
|
2896
|
+
return WrappedStyledComponent;
|
|
2897
|
+
}
|
|
2898
|
+
|
|
2899
|
+
//
|
|
2900
|
+
// Thanks to ReactDOMFactories for this handy list!
|
|
2901
|
+
var domElements = ['a', 'abbr', 'address', 'area', 'article', 'aside', 'audio', 'b', 'base', 'bdi', 'bdo', 'big', 'blockquote', 'body', 'br', 'button', 'canvas', 'caption', 'cite', 'code', 'col', 'colgroup', 'data', 'datalist', 'dd', 'del', 'details', 'dfn', 'dialog', 'div', 'dl', 'dt', 'em', 'embed', 'fieldset', 'figcaption', 'figure', 'footer', 'form', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'head', 'header', 'hgroup', 'hr', 'html', 'i', 'iframe', 'img', 'input', 'ins', 'kbd', 'keygen', 'label', 'legend', 'li', 'link', 'main', 'map', 'mark', 'marquee', 'menu', 'menuitem', 'meta', 'meter', 'nav', 'noscript', 'object', 'ol', 'optgroup', 'option', 'output', 'p', 'param', 'picture', 'pre', 'progress', 'q', 'rp', 'rt', 'ruby', 's', 'samp', 'script', 'section', 'select', 'small', 'source', 'span', 'strong', 'style', 'sub', 'summary', 'sup', 'table', 'tbody', 'td', 'textarea', 'tfoot', 'th', 'thead', 'time', 'title', 'tr', 'track', 'u', 'ul', 'var', 'video', 'wbr', // SVG
|
|
2902
|
+
'circle', 'clipPath', 'defs', 'ellipse', 'foreignObject', 'g', 'image', 'line', 'linearGradient', 'marker', 'mask', 'path', 'pattern', 'polygon', 'polyline', 'radialGradient', 'rect', 'stop', 'svg', 'text', 'tspan'];
|
|
2903
|
+
|
|
2904
|
+
//
|
|
2905
|
+
|
|
2906
|
+
var styled = function styled(tag) {
|
|
2907
|
+
return constructWithOptions(createStyledComponent, tag);
|
|
2908
|
+
}; // Shorthands for all valid HTML Elements
|
|
2909
|
+
|
|
2910
|
+
|
|
2911
|
+
domElements.forEach(function (domElement) {
|
|
2912
|
+
styled[domElement] = styled(domElement);
|
|
2913
|
+
});
|
|
2914
|
+
/* Warning if you've imported this file on React Native */
|
|
2915
|
+
|
|
2916
|
+
if (process.env.NODE_ENV !== 'production' && typeof navigator !== 'undefined' && navigator.product === 'ReactNative') {
|
|
2917
|
+
// eslint-disable-next-line no-console
|
|
2918
|
+
console.warn("It looks like you've imported 'styled-components' on React Native.\n" + "Perhaps you're looking to import 'styled-components/native'?\n" + 'Read more about this at https://www.styled-components.com/docs/basics#react-native');
|
|
2919
|
+
}
|
|
2920
|
+
/* Warning if there are several instances of styled-components */
|
|
2921
|
+
|
|
2922
|
+
|
|
2923
|
+
if (process.env.NODE_ENV !== 'production' && process.env.NODE_ENV !== 'test' && typeof window !== 'undefined') {
|
|
2924
|
+
window['__styled-components-init__'] = window['__styled-components-init__'] || 0;
|
|
2925
|
+
|
|
2926
|
+
if (window['__styled-components-init__'] === 1) {
|
|
2927
|
+
// eslint-disable-next-line no-console
|
|
2928
|
+
console.warn("It looks like there are several instances of 'styled-components' initialized in this application. " + 'This may cause dynamic styles not rendering properly, errors happening during rehydration process, ' + 'missing theme prop, and makes your application bigger without a good reason.\n\n' + 'See https://s-c.sh/2BAXzed for more info.');
|
|
2929
|
+
}
|
|
2930
|
+
|
|
2931
|
+
window['__styled-components-init__'] += 1;
|
|
2932
|
+
}
|
|
1297
2933
|
|
|
1298
2934
|
/*! *****************************************************************************
|
|
1299
2935
|
Copyright (c) Microsoft Corporation.
|
|
@@ -1780,17 +3416,17 @@ var FLOAT_32_SUPPORTED = typeof Float32Array !== 'undefined';
|
|
|
1780
3416
|
var a = function (a1, a2) {
|
|
1781
3417
|
return 1.0 - 3.0 * a2 + 3.0 * a1;
|
|
1782
3418
|
};
|
|
1783
|
-
var b$
|
|
3419
|
+
var b$1 = function (a1, a2) {
|
|
1784
3420
|
return 3.0 * a2 - 6.0 * a1;
|
|
1785
3421
|
};
|
|
1786
3422
|
var c$1 = function (a1) {
|
|
1787
3423
|
return 3.0 * a1;
|
|
1788
3424
|
};
|
|
1789
3425
|
var getSlope = function (t, a1, a2) {
|
|
1790
|
-
return 3.0 * a(a1, a2) * t * t + 2.0 * b$
|
|
3426
|
+
return 3.0 * a(a1, a2) * t * t + 2.0 * b$1(a1, a2) * t + c$1(a1);
|
|
1791
3427
|
};
|
|
1792
3428
|
var calcBezier = function (t, a1, a2) {
|
|
1793
|
-
return ((a(a1, a2) * t + b$
|
|
3429
|
+
return ((a(a1, a2) * t + b$1(a1, a2)) * t + c$1(a1)) * t;
|
|
1794
3430
|
};
|
|
1795
3431
|
function cubicBezier(mX1, mY1, mX2, mY2) {
|
|
1796
3432
|
var sampleValues = FLOAT_32_SUPPORTED ? new Float32Array(K_SPLINE_TABLE_SIZE) : new Array(K_SPLINE_TABLE_SIZE);
|
|
@@ -2801,7 +4437,7 @@ var createDOMStyler = function (node, props) {
|
|
|
2801
4437
|
var getStyler = function (node, props) {
|
|
2802
4438
|
return cache.has(node) ? cache.get(node) : createDOMStyler(node, props);
|
|
2803
4439
|
};
|
|
2804
|
-
function index(nodeOrSelector, props) {
|
|
4440
|
+
function index$1(nodeOrSelector, props) {
|
|
2805
4441
|
var node = typeof nodeOrSelector === 'string' ? document.querySelector(nodeOrSelector) : nodeOrSelector;
|
|
2806
4442
|
return getStyler(node, props);
|
|
2807
4443
|
}
|
|
@@ -3863,7 +5499,7 @@ var pointer = function (props) {
|
|
|
3863
5499
|
return touches;
|
|
3864
5500
|
}, getFirstTouch) : mouse(props);
|
|
3865
5501
|
};
|
|
3866
|
-
var index$1 = function (_a) {
|
|
5502
|
+
var index$1$1 = function (_a) {
|
|
3867
5503
|
if (_a === void 0) {
|
|
3868
5504
|
_a = {};
|
|
3869
5505
|
}
|
|
@@ -4494,7 +6130,7 @@ var interpolate$1 = transformers.interpolate;
|
|
|
4494
6130
|
var singleAxisPointer = function (axis) {
|
|
4495
6131
|
return function (from) {
|
|
4496
6132
|
var _a;
|
|
4497
|
-
return index$1((_a = {}, _a[axis] = typeof from === 'string' ? parseFloat(from) : from, _a)).pipe(function (v) {
|
|
6133
|
+
return index$1$1((_a = {}, _a[axis] = typeof from === 'string' ? parseFloat(from) : from, _a)).pipe(function (v) {
|
|
4498
6134
|
return v[axis];
|
|
4499
6135
|
});
|
|
4500
6136
|
};
|
|
@@ -5122,7 +6758,7 @@ var createPoseConfig = function (element, _a) {
|
|
|
5122
6758
|
hoverable: hoverable,
|
|
5123
6759
|
focusable: focusable,
|
|
5124
6760
|
pressable: pressable,
|
|
5125
|
-
element: element, elementStyler: index(element, { preparseOutput: false }), dimensions: createDimensions(element) }) });
|
|
6761
|
+
element: element, elementStyler: index$1(element, { preparseOutput: false }), dimensions: createDimensions(element) }) });
|
|
5126
6762
|
if (draggable) {
|
|
5127
6763
|
var _b = dragPoses(draggable),
|
|
5128
6764
|
drag = _b.drag,
|
|
@@ -5825,7 +7461,7 @@ var themeComponent = function themeComponent(component, componentThemeId, fallba
|
|
|
5825
7461
|
variant = _ref7$variant === void 0 ? defaultVariant : _ref7$variant,
|
|
5826
7462
|
props = _objectWithoutProperties(_ref7, _excluded);
|
|
5827
7463
|
|
|
5828
|
-
var themeContext = React.useContext(
|
|
7464
|
+
var themeContext = React.useContext(ThemeContext);
|
|
5829
7465
|
var metadata = (_themeContext$metadat = themeContext === null || themeContext === void 0 ? void 0 : themeContext.metadata) !== null && _themeContext$metadat !== void 0 ? _themeContext$metadat : {};
|
|
5830
7466
|
var themeValues = themeContext ? createThemeValues(themeContext, fallbackValues, componentThemeId, variant) : fallbackValues;
|
|
5831
7467
|
return component(_objectSpread2(_objectSpread2({}, props), {}, {
|
|
@@ -5899,25 +7535,34 @@ var AQUA_HAZE_WHITE = "#F7F9FA";
|
|
|
5899
7535
|
var BLEACH_WHITE = "#FEF4d7";
|
|
5900
7536
|
var CATSKILL_WHITE = "#EAF2F6"; // GREY
|
|
5901
7537
|
|
|
5902
|
-
var ATHENS_GREY = "#F6F6F9";
|
|
7538
|
+
var ATHENS_GREY = "#F6F6F9"; // CBS-100
|
|
7539
|
+
|
|
5903
7540
|
var ALTO_GREY = "#d1d1d1";
|
|
5904
7541
|
var SILVER_GREY = "#cdcdcd";
|
|
5905
7542
|
var PEWTER_GREY = "#DFE1E4";
|
|
5906
7543
|
var ASH_GREY = "#979797";
|
|
5907
7544
|
var IRON_GREY = "#d5d8dc";
|
|
5908
|
-
var GHOST_GREY = "#CACED8";
|
|
7545
|
+
var GHOST_GREY = "#CACED8"; // CBS-300
|
|
7546
|
+
|
|
5909
7547
|
var DUSTY_GREY = "#9B9B9B";
|
|
5910
7548
|
var REGENT_GREY = "#959EA7";
|
|
5911
|
-
var STORM_GREY = "#6D717E";
|
|
7549
|
+
var STORM_GREY = "#6D717E"; // CBS-700
|
|
7550
|
+
|
|
5912
7551
|
var TROUT_GREY = "#515660";
|
|
5913
7552
|
var MINESHAFT_GREY = "#333333";
|
|
5914
7553
|
var SOOT_GREY = "#999999";
|
|
5915
7554
|
var FIREFLY_GREY = "#091325";
|
|
5916
|
-
var BRIGHT_GREY = "#3B414D";
|
|
5917
|
-
|
|
5918
|
-
var
|
|
7555
|
+
var BRIGHT_GREY = "#3B414D"; // CBS-800
|
|
7556
|
+
|
|
7557
|
+
var CHARADE_GREY = "#292A33"; // CBS-900
|
|
7558
|
+
|
|
7559
|
+
var GRECIAN_GREY = "#E5E7EC"; // CBS-200
|
|
7560
|
+
|
|
5919
7561
|
var BLACK_SQUEEZE = "#EAF2F7";
|
|
5920
|
-
var GREY_CHATEAU = "#959CA8"; //
|
|
7562
|
+
var GREY_CHATEAU = "#959CA8"; // CBS-500
|
|
7563
|
+
|
|
7564
|
+
var COOL_GREY_05 = "#fbfcfd"; // CBS-050
|
|
7565
|
+
// BLUE
|
|
5921
7566
|
|
|
5922
7567
|
var CLOUDBURST_BLUE = "#26395c";
|
|
5923
7568
|
var ZODIAC_BLUE = "#14284b";
|
|
@@ -5951,7 +7596,7 @@ var MUSTARD_YELLOW = "#FFD459";
|
|
|
5951
7596
|
var FIRE_YELLOW = "#B34A00"; // ORANGE
|
|
5952
7597
|
|
|
5953
7598
|
var CARROT_ORANGE = "#ED9620";
|
|
5954
|
-
var ZEST_ORANGE = "#
|
|
7599
|
+
var ZEST_ORANGE = "#B84A00";
|
|
5955
7600
|
var APRICOT_ORANGE = "#FFE8D8"; // RED
|
|
5956
7601
|
|
|
5957
7602
|
var RED = "#FF0000";
|
|
@@ -6021,6 +7666,7 @@ var colors = /*#__PURE__*/Object.freeze({
|
|
|
6021
7666
|
BRIGHT_GREY: BRIGHT_GREY,
|
|
6022
7667
|
CHARADE_GREY: CHARADE_GREY,
|
|
6023
7668
|
GRECIAN_GREY: GRECIAN_GREY,
|
|
7669
|
+
COOL_GREY_05: COOL_GREY_05,
|
|
6024
7670
|
BLACK_SQUEEZE: BLACK_SQUEEZE,
|
|
6025
7671
|
GREY_CHATEAU: GREY_CHATEAU,
|
|
6026
7672
|
CLOUDBURST_BLUE: CLOUDBURST_BLUE,
|
|
@@ -6065,10 +7711,10 @@ var colors = /*#__PURE__*/Object.freeze({
|
|
|
6065
7711
|
ERROR_COLOR: ERROR_COLOR
|
|
6066
7712
|
});
|
|
6067
7713
|
|
|
6068
|
-
var TextSpan =
|
|
7714
|
+
var TextSpan = styled.span.withConfig({
|
|
6069
7715
|
displayName: "Textstyled__TextSpan",
|
|
6070
7716
|
componentId: "sc-1oy97we-0"
|
|
6071
|
-
})(["--font-size:", ";font-size:var(--font-size);line-height:calc(1.5 * var(--font-size));font-weight:", ";font-family:", ";color:", ";&:hover{", "}&:focus{outline:3px solid ", ";outline-offset:2px;}", " ", ""], function (_ref) {
|
|
7717
|
+
})(["--font-size:", ";font-size:var(--font-size);line-height:calc(1.5 * var(--font-size));font-weight:", ";font-family:", ";color:", ";white-space:", ";&:hover{", "}&:focus{outline:3px solid ", ";outline-offset:2px;}", " ", ""], function (_ref) {
|
|
6072
7718
|
var fontSize = _ref.fontSize;
|
|
6073
7719
|
return fontSize;
|
|
6074
7720
|
}, function (_ref2) {
|
|
@@ -6081,14 +7727,17 @@ var TextSpan = qe.span.withConfig({
|
|
|
6081
7727
|
var color = _ref4.color;
|
|
6082
7728
|
return color;
|
|
6083
7729
|
}, function (_ref5) {
|
|
6084
|
-
var
|
|
6085
|
-
return
|
|
6086
|
-
},
|
|
6087
|
-
var
|
|
6088
|
-
|
|
6089
|
-
|
|
6090
|
-
|
|
6091
|
-
|
|
7730
|
+
var $textWrap = _ref5.$textWrap;
|
|
7731
|
+
return $textWrap ? "initial" : "nowrap";
|
|
7732
|
+
}, function (_ref6) {
|
|
7733
|
+
var hoverStyles = _ref6.hoverStyles;
|
|
7734
|
+
return css(["", ""], hoverStyles);
|
|
7735
|
+
}, ROYAL_BLUE, function (_ref7) {
|
|
7736
|
+
var disabled = _ref7.disabled,
|
|
7737
|
+
disabledStyles = _ref7.disabledStyles;
|
|
7738
|
+
return disabled && css(["", ""], disabledStyles);
|
|
7739
|
+
}, function (_ref8) {
|
|
7740
|
+
var extraStyles = _ref8.extraStyles;
|
|
6092
7741
|
return extraStyles;
|
|
6093
7742
|
});
|
|
6094
7743
|
|
|
@@ -7214,7 +8863,7 @@ var general = /*#__PURE__*/Object.freeze({
|
|
|
7214
8863
|
screenReaderOnlyStyle: screenReaderOnlyStyle
|
|
7215
8864
|
});
|
|
7216
8865
|
|
|
7217
|
-
var _excluded$1 = ["themeValues", "weight", "color", "extraStyles", "hoverStyles", "onClick", "onKeyPress", "as", "dataQa", "children"];
|
|
8866
|
+
var _excluded$1 = ["themeValues", "weight", "color", "textWrap", "extraStyles", "hoverStyles", "onClick", "onKeyPress", "as", "dataQa", "children"];
|
|
7218
8867
|
|
|
7219
8868
|
var Text = function Text(_ref) {
|
|
7220
8869
|
var themeValues = _ref.themeValues,
|
|
@@ -7222,6 +8871,8 @@ var Text = function Text(_ref) {
|
|
|
7222
8871
|
weight = _ref$weight === void 0 ? FONT_WEIGHT_REGULAR : _ref$weight,
|
|
7223
8872
|
_ref$color = _ref.color,
|
|
7224
8873
|
color = _ref$color === void 0 ? FIREFLY_GREY : _ref$color,
|
|
8874
|
+
_ref$textWrap = _ref.textWrap,
|
|
8875
|
+
textWrap = _ref$textWrap === void 0 ? true : _ref$textWrap,
|
|
7225
8876
|
_ref$extraStyles = _ref.extraStyles,
|
|
7226
8877
|
extraStyles = _ref$extraStyles === void 0 ? "" : _ref$extraStyles,
|
|
7227
8878
|
hoverStyles = _ref.hoverStyles,
|
|
@@ -7242,7 +8893,8 @@ var Text = function Text(_ref) {
|
|
|
7242
8893
|
hoverStyles: hoverStyles,
|
|
7243
8894
|
onClick: onClick,
|
|
7244
8895
|
onKeyPress: onKeyPress,
|
|
7245
|
-
"data-qa": dataQa
|
|
8896
|
+
"data-qa": dataQa,
|
|
8897
|
+
$textWrap: textWrap
|
|
7246
8898
|
}, rest), safeChildren(children, /*#__PURE__*/React__default.createElement("span", null)));
|
|
7247
8899
|
};
|
|
7248
8900
|
|
|
@@ -7259,7 +8911,7 @@ var _excluded$2 = ["activeStyles", "hoverStyles", "disabledStyles", "extraStyles
|
|
|
7259
8911
|
|
|
7260
8912
|
/* eslint-disable no-unused-vars */
|
|
7261
8913
|
|
|
7262
|
-
var BoxWrapper =
|
|
8914
|
+
var BoxWrapper = styled(function (_ref) {
|
|
7263
8915
|
var activeStyles = _ref.activeStyles,
|
|
7264
8916
|
hoverStyles = _ref.hoverStyles,
|
|
7265
8917
|
disabledStyles = _ref.disabledStyles,
|
|
@@ -7286,13 +8938,14 @@ var BoxWrapper = qe(function (_ref) {
|
|
|
7286
8938
|
}).withConfig({
|
|
7287
8939
|
displayName: "Boxstyled__BoxWrapper",
|
|
7288
8940
|
componentId: "sc-1f9ij0d-0"
|
|
7289
|
-
})(["position:relative;box-sizing:border-box;padding:", ";border:", ";box-shadow:", ";background-color:", ";min-height:", ";", " min-width:", ";max-width:", ";color:", ";border-radius:", ";border-width:", ";
|
|
8941
|
+
})(["position:relative;box-sizing:border-box;padding:", ";border:", ";box-shadow:", ";background-color:", ";min-height:", ";", " min-width:", ";max-width:", ";color:", ";border-radius:", ";border-width:", ";text-align:", ";&:hover{", "}&:focus{", "}&:active{", "}&:disabled{", "}& *{color:", ";}", " ", ""], function (_ref2) {
|
|
7290
8942
|
var padding = _ref2.padding;
|
|
7291
8943
|
return padding;
|
|
7292
8944
|
}, function (_ref3) {
|
|
7293
|
-
var
|
|
8945
|
+
var border = _ref3.border,
|
|
8946
|
+
borderSize = _ref3.borderSize,
|
|
7294
8947
|
borderColor = _ref3.borderColor;
|
|
7295
|
-
return "".concat(borderSize, " solid ").concat(borderColor);
|
|
8948
|
+
return border ? border : "".concat(borderSize, " solid ").concat(borderColor);
|
|
7296
8949
|
}, function (_ref4) {
|
|
7297
8950
|
var boxShadow = _ref4.boxShadow;
|
|
7298
8951
|
return boxShadow;
|
|
@@ -7318,39 +8971,35 @@ var BoxWrapper = qe(function (_ref) {
|
|
|
7318
8971
|
var borderRadius = _ref11.borderRadius;
|
|
7319
8972
|
return borderRadius;
|
|
7320
8973
|
}, function (_ref12) {
|
|
7321
|
-
var borderWidthOverride = _ref12.borderWidthOverride
|
|
7322
|
-
|
|
7323
|
-
return borderWidthOverride ? borderWidthOverride : borderSize;
|
|
8974
|
+
var borderWidthOverride = _ref12.borderWidthOverride;
|
|
8975
|
+
return borderWidthOverride;
|
|
7324
8976
|
}, function (_ref13) {
|
|
7325
|
-
var
|
|
7326
|
-
return border;
|
|
7327
|
-
}, function (_ref14) {
|
|
7328
|
-
var textAlign = _ref14.textAlign;
|
|
8977
|
+
var textAlign = _ref13.textAlign;
|
|
7329
8978
|
return textAlign;
|
|
8979
|
+
}, function (_ref14) {
|
|
8980
|
+
var hoverStyles = _ref14.hoverStyles,
|
|
8981
|
+
as = _ref14.as;
|
|
8982
|
+
return css(["", " ", ""], hoverStyles, as === "button" ? "> * > span {\n ".concat(hoverStyles, "\n border: none;\n outline: none;\n box-shadow: none;\n }") : "");
|
|
7330
8983
|
}, function (_ref15) {
|
|
7331
|
-
var
|
|
7332
|
-
|
|
7333
|
-
return Ae(["", " ", ""], hoverStyles, as === "button" ? "> * > span {\n ".concat(hoverStyles, "\n border: none;\n outline: none;\n box-shadow: none;\n }") : "");
|
|
8984
|
+
var as = _ref15.as;
|
|
8985
|
+
return css(["outline:3px solid ", ";outline-offset:2px;", ""], ROYAL_BLUE, as === "button" && "\n > * > span {\n border: none;\n outline: none;\n box-shadow: none;\n }");
|
|
7334
8986
|
}, function (_ref16) {
|
|
7335
|
-
var
|
|
7336
|
-
|
|
8987
|
+
var activeStyles = _ref16.activeStyles,
|
|
8988
|
+
as = _ref16.as;
|
|
8989
|
+
return css(["", " ", ""], activeStyles, as === "button" ? " > * > span {\n ".concat(activeStyles, "\n border: none;\n outline: none;\n box-shadow: none;\n }") : "");
|
|
7337
8990
|
}, function (_ref17) {
|
|
7338
|
-
var
|
|
8991
|
+
var disabledStyles = _ref17.disabledStyles,
|
|
7339
8992
|
as = _ref17.as;
|
|
7340
|
-
return
|
|
8993
|
+
return css(["", " ", ""], disabledStyles, as === "button" ? " > * > span {\n ".concat(disabledStyles, "\n border: none;\n outline: none;\n box-shadow: none;\n }") : "");
|
|
7341
8994
|
}, function (_ref18) {
|
|
7342
|
-
var
|
|
7343
|
-
as = _ref18.as;
|
|
7344
|
-
return Ae(["", " ", ""], disabledStyles, as === "button" ? " > * > span {\n ".concat(disabledStyles, "\n border: none;\n outline: none;\n box-shadow: none;\n }") : "");
|
|
7345
|
-
}, function (_ref19) {
|
|
7346
|
-
var color = _ref19.color;
|
|
8995
|
+
var color = _ref18.color;
|
|
7347
8996
|
return color;
|
|
8997
|
+
}, function (_ref19) {
|
|
8998
|
+
var hiddenStyles = _ref19.hiddenStyles;
|
|
8999
|
+
return hiddenStyles && css(["display:none;"]);
|
|
7348
9000
|
}, function (_ref20) {
|
|
7349
|
-
var
|
|
7350
|
-
return
|
|
7351
|
-
}, function (_ref21) {
|
|
7352
|
-
var extraStyles = _ref21.extraStyles;
|
|
7353
|
-
return Ae(["", ""], extraStyles);
|
|
9001
|
+
var extraStyles = _ref20.extraStyles;
|
|
9002
|
+
return css(["", ""], extraStyles);
|
|
7354
9003
|
});
|
|
7355
9004
|
/* eslint-enable no-unused-vars */
|
|
7356
9005
|
|
|
@@ -7437,7 +9086,7 @@ var Box = function Box(_ref) {
|
|
|
7437
9086
|
}, rest), safeChildren(children, /*#__PURE__*/React__default.createElement(React.Fragment, null)));
|
|
7438
9087
|
};
|
|
7439
9088
|
|
|
7440
|
-
var CenterWrapper =
|
|
9089
|
+
var CenterWrapper = styled.div.withConfig({
|
|
7441
9090
|
displayName: "Centerstyled__CenterWrapper",
|
|
7442
9091
|
componentId: "sc-vawqfc-0"
|
|
7443
9092
|
})(["box-sizing:content-box;margin-left:auto;margin-right:auto;max-width:", ";padding-left:", ";padding-right:", ";", ";"], function (_ref) {
|
|
@@ -7479,7 +9128,7 @@ var Center = function Center(_ref) {
|
|
|
7479
9128
|
var _excluded$5 = ["overflow"];
|
|
7480
9129
|
/* eslint-disable no-unused-vars */
|
|
7481
9130
|
|
|
7482
|
-
var ClusterWrapper =
|
|
9131
|
+
var ClusterWrapper = styled(function (_ref) {
|
|
7483
9132
|
var overflow = _ref.overflow,
|
|
7484
9133
|
props = _objectWithoutProperties(_ref, _excluded$5);
|
|
7485
9134
|
|
|
@@ -7503,12 +9152,12 @@ var ClusterWrapper = qe(function (_ref) {
|
|
|
7503
9152
|
var $extraStyles = _ref6.$extraStyles;
|
|
7504
9153
|
return $extraStyles;
|
|
7505
9154
|
});
|
|
7506
|
-
var ClusterInnerWrapper =
|
|
9155
|
+
var ClusterInnerWrapper = styled.div.withConfig({
|
|
7507
9156
|
displayName: "Clusterstyled__ClusterInnerWrapper",
|
|
7508
9157
|
componentId: "sc-1dkqsm7-1"
|
|
7509
9158
|
})(["box-sizing:border-box;display:flex;flex-wrap:", ";justify-content:", ";align-items:", ";margin:calc(", " / 2 * -1);min-height:", ";min-width:", ";> *{margin:calc(", " / 2);}"], function (_ref7) {
|
|
7510
|
-
var nowrap = _ref7
|
|
7511
|
-
return nowrap ? "nowrap" : "wrap";
|
|
9159
|
+
var $nowrap = _ref7.$nowrap;
|
|
9160
|
+
return $nowrap ? "nowrap" : "wrap";
|
|
7512
9161
|
}, function (_ref8) {
|
|
7513
9162
|
var justify = _ref8.justify;
|
|
7514
9163
|
return justify;
|
|
@@ -7568,11 +9217,11 @@ var Cluster = function Cluster(_ref) {
|
|
|
7568
9217
|
childGap: childGap,
|
|
7569
9218
|
minHeight: minHeight,
|
|
7570
9219
|
minWidth: minWidth,
|
|
7571
|
-
nowrap: nowrap
|
|
9220
|
+
$nowrap: nowrap
|
|
7572
9221
|
}, safeChildren(children, /*#__PURE__*/React__default.createElement(React.Fragment, null))));
|
|
7573
9222
|
};
|
|
7574
9223
|
|
|
7575
|
-
var GridWrapper =
|
|
9224
|
+
var GridWrapper = styled.div.withConfig({
|
|
7576
9225
|
displayName: "Gridstyled__GridWrapper",
|
|
7577
9226
|
componentId: "sc-8iakdj-0"
|
|
7578
9227
|
})(["display:grid;grid-gap:", ";grid-template-columns:", ";@supports (width:min(", ",100%)){&{grid-template-columns:repeat( auto-fill,minmax( ", ",", " ) );}}"], function (_ref) {
|
|
@@ -7632,14 +9281,14 @@ var Grid = function Grid(_ref) {
|
|
|
7632
9281
|
};
|
|
7633
9282
|
|
|
7634
9283
|
var _excluded$8 = ["onRight", "childGap", "contentMinWidth", "minHeight", "fullHeight"];
|
|
7635
|
-
var SidebarWrapper =
|
|
9284
|
+
var SidebarWrapper = styled.div.withConfig({
|
|
7636
9285
|
displayName: "Sidebarstyled__SidebarWrapper",
|
|
7637
9286
|
componentId: "sc-1bbn2or-0"
|
|
7638
9287
|
})(["overflow:visible;box-sizing:border-box;", ""], function (_ref) {
|
|
7639
9288
|
var fullHeight = _ref.fullHeight;
|
|
7640
9289
|
return fullHeight ? "height: 100%;" : "";
|
|
7641
9290
|
});
|
|
7642
|
-
var SidebarInnerWrapper =
|
|
9291
|
+
var SidebarInnerWrapper = styled( // eslint-disable-next-line no-unused-vars
|
|
7643
9292
|
function (_ref2) {
|
|
7644
9293
|
var onRight = _ref2.onRight,
|
|
7645
9294
|
childGap = _ref2.childGap,
|
|
@@ -7715,7 +9364,7 @@ var Sidebar = function Sidebar(_ref) {
|
|
|
7715
9364
|
}, safeChildren(children, /*#__PURE__*/React__default.createElement(React.Fragment, null))));
|
|
7716
9365
|
};
|
|
7717
9366
|
|
|
7718
|
-
var StackWrapper =
|
|
9367
|
+
var StackWrapper = styled.div.withConfig({
|
|
7719
9368
|
displayName: "Stackstyled__StackWrapper",
|
|
7720
9369
|
componentId: "sc-ejhezz-0"
|
|
7721
9370
|
})(["box-sizing:border-box;display:flex;flex-direction:", ";justify-content:", ";height:", ";> *{margin-top:0;margin-bottom:0;}> * + *{", "}", ";"], function (_ref) {
|
|
@@ -7769,10 +9418,10 @@ var Stack = function Stack(_ref) {
|
|
|
7769
9418
|
}, rest), safeChildren(children, /*#__PURE__*/React__default.createElement(React.Fragment, null)));
|
|
7770
9419
|
};
|
|
7771
9420
|
|
|
7772
|
-
var CoverOuterContainer =
|
|
9421
|
+
var CoverOuterContainer = styled.div.withConfig({
|
|
7773
9422
|
displayName: "Coverstyled__CoverOuterContainer",
|
|
7774
9423
|
componentId: "sc-1jhq379-0"
|
|
7775
|
-
})(["box-sizing:border-box;display:flex;flex-direction:column;min-height:", ";padding:", ";min-width:", ";> *{margin-top:", ";margin-bottom:", ";}
|
|
9424
|
+
})(["box-sizing:border-box;display:flex;flex-direction:column;min-height:", ";padding:", ";min-width:", ";> *{margin-top:", ";margin-bottom:", ";}>:first-child{margin-top:0;}", " ", " >:last-child{margin-bottom:0;}"], function (_ref) {
|
|
7776
9425
|
var minHeight = _ref.minHeight;
|
|
7777
9426
|
return minHeight;
|
|
7778
9427
|
}, function (_ref2) {
|
|
@@ -7836,7 +9485,7 @@ var Cover = function Cover(_ref) {
|
|
|
7836
9485
|
}, rest), singleChild ? /*#__PURE__*/React__default.createElement("div", null) : /*#__PURE__*/React__default.createElement(React.Fragment, null), safeChildren(children, /*#__PURE__*/React__default.createElement(React.Fragment, null)), singleChild ? /*#__PURE__*/React__default.createElement("div", null) : /*#__PURE__*/React__default.createElement(React.Fragment, null));
|
|
7837
9486
|
};
|
|
7838
9487
|
|
|
7839
|
-
var FrameOuterContainer =
|
|
9488
|
+
var FrameOuterContainer = styled.div.withConfig({
|
|
7840
9489
|
displayName: "Framestyled__FrameOuterContainer",
|
|
7841
9490
|
componentId: "sc-1syfnuv-0"
|
|
7842
9491
|
})(["box-sizing:border-box;padding-bottom:", ";position:relative;> *{overflow:hidden;position:absolute;top:0;right:0;bottom:0;left:0;display:flex;justify-content:center;align-items:center;}> img,> video{width:100%;height:100%;object-fit:cover;}"], function (_ref) {
|
|
@@ -7873,11 +9522,11 @@ var Frame = function Frame(_ref) {
|
|
|
7873
9522
|
}, rest), safeChildren(children, /*#__PURE__*/React__default.createElement(React.Fragment, null)));
|
|
7874
9523
|
};
|
|
7875
9524
|
|
|
7876
|
-
var SwitcherOuterContainer =
|
|
9525
|
+
var SwitcherOuterContainer = styled.div.withConfig({
|
|
7877
9526
|
displayName: "Switcherstyled__SwitcherOuterContainer",
|
|
7878
9527
|
componentId: "sc-1ym61kc-0"
|
|
7879
9528
|
})(["box-sizing:border-box;display:block;"]);
|
|
7880
|
-
var SwitcherInnerContainer =
|
|
9529
|
+
var SwitcherInnerContainer = styled.div.withConfig({
|
|
7881
9530
|
displayName: "Switcherstyled__SwitcherInnerContainer",
|
|
7882
9531
|
componentId: "sc-1ym61kc-1"
|
|
7883
9532
|
})(["box-sizing:border-box;display:flex;flex-wrap:wrap;overflow:hidden;padding:", ";margin:", ";", " > *{flex-grow:1;", ";", " ", "}", " ", " ", ""], function (_ref) {
|
|
@@ -7909,7 +9558,7 @@ var SwitcherInnerContainer = qe.div.withConfig({
|
|
|
7909
9558
|
return maxChildren ? "> :nth-last-child(".concat(maxChildren + 1, "), > :nth-last-child(").concat(maxChildren + 1, ") ~ * {\n flex-basis: 100%;\n }") : "";
|
|
7910
9559
|
}, function (_ref9) {
|
|
7911
9560
|
var extraStyles = _ref9.extraStyles;
|
|
7912
|
-
return
|
|
9561
|
+
return css(["", ""], extraStyles);
|
|
7913
9562
|
});
|
|
7914
9563
|
|
|
7915
9564
|
var _excluded$d = ["breakpoint", "childGap", "largeChild", "largeChildSize", "maxChildren", "maxChildrenOnly", "padding", "children", "extraStyles", "constrainMobile"];
|
|
@@ -7976,7 +9625,7 @@ var Switcher = function Switcher(_ref) {
|
|
|
7976
9625
|
}, rest), safeChildren(children, /*#__PURE__*/React__default.createElement(React.Fragment, null))));
|
|
7977
9626
|
};
|
|
7978
9627
|
|
|
7979
|
-
var ImposterWrapper =
|
|
9628
|
+
var ImposterWrapper = styled.div.withConfig({
|
|
7980
9629
|
displayName: "Imposterstyled__ImposterWrapper",
|
|
7981
9630
|
componentId: "sc-1q0gj35-0"
|
|
7982
9631
|
})(["position:", ";top:", ";left:", ";display:", ";", " ", " ", ";"], function (_ref) {
|
|
@@ -9258,7 +10907,7 @@ var MountComponent = function (_a) {
|
|
|
9258
10907
|
var ref = _a.innerRef, values = _a.values, isStatic = _a.isStatic;
|
|
9259
10908
|
React.useEffect(function () {
|
|
9260
10909
|
invariant(ref.current instanceof Element, "No `ref` found. Ensure components created with `motion.custom` forward refs using `React.forwardRef`");
|
|
9261
|
-
var domStyler = index(ref.current, {
|
|
10910
|
+
var domStyler = index$1(ref.current, {
|
|
9262
10911
|
preparseOutput: false,
|
|
9263
10912
|
enableHardwareAcceleration: !isStatic,
|
|
9264
10913
|
});
|
|
@@ -11987,7 +13636,7 @@ var checkAndConvertChangedValueTypes = function (values, ref, target, transition
|
|
|
11987
13636
|
target = __assign({}, target);
|
|
11988
13637
|
transitionEnd = __assign({}, transitionEnd);
|
|
11989
13638
|
var element = ref.current;
|
|
11990
|
-
var elementStyler = index(element);
|
|
13639
|
+
var elementStyler = index$1(element);
|
|
11991
13640
|
var targetPositionalKeys = Object.keys(target).filter(isPositionalKey$1);
|
|
11992
13641
|
// We want to remove any transform values that could affect the element's bounding box before
|
|
11993
13642
|
// it's measured. We'll reapply these later.
|
|
@@ -12308,7 +13957,7 @@ var LayoutAnimation = /** @class */ (function (_super) {
|
|
|
12308
13957
|
transform && (element.style.transform = transform);
|
|
12309
13958
|
return;
|
|
12310
13959
|
}
|
|
12311
|
-
index(element).set({
|
|
13960
|
+
index$1(element).set({
|
|
12312
13961
|
originX: delta.originX,
|
|
12313
13962
|
originY: delta.originY,
|
|
12314
13963
|
});
|
|
@@ -12716,7 +14365,7 @@ var Exit = {
|
|
|
12716
14365
|
}),
|
|
12717
14366
|
};
|
|
12718
14367
|
|
|
12719
|
-
var isPropValid
|
|
14368
|
+
var isPropValid = function (key) { return !isValidMotionProp(key); };
|
|
12720
14369
|
/**
|
|
12721
14370
|
* Emotion and Styled Components both allow users to pass through arbitrary props to their components
|
|
12722
14371
|
* to dynamically generate CSS. They both use the `@emotion/is-prop-valid` package to determine which
|
|
@@ -12732,7 +14381,7 @@ var isPropValid$1 = function (key) { return !isValidMotionProp(key); };
|
|
|
12732
14381
|
*/
|
|
12733
14382
|
try {
|
|
12734
14383
|
var emotionIsPropValid_1 = require("@emotion/is-prop-valid").default;
|
|
12735
|
-
isPropValid
|
|
14384
|
+
isPropValid = function (key) {
|
|
12736
14385
|
// Handle events explicitly as Emotion validates them all as true
|
|
12737
14386
|
if (key.startsWith("on")) {
|
|
12738
14387
|
return !isValidMotionProp(key);
|
|
@@ -12748,7 +14397,7 @@ catch (_a) {
|
|
|
12748
14397
|
function filterValidProps(props) {
|
|
12749
14398
|
var domProps = {};
|
|
12750
14399
|
for (var key in props) {
|
|
12751
|
-
if (isPropValid
|
|
14400
|
+
if (isPropValid(key)) {
|
|
12752
14401
|
domProps[key] = props[key];
|
|
12753
14402
|
}
|
|
12754
14403
|
}
|
|
@@ -12829,7 +14478,7 @@ function createDomMotionConfig(Component) {
|
|
|
12829
14478
|
return {
|
|
12830
14479
|
values: values,
|
|
12831
14480
|
readValueFromSource: function (key) {
|
|
12832
|
-
return index(ref.current).get(key);
|
|
14481
|
+
return index$1(ref.current).get(key);
|
|
12833
14482
|
},
|
|
12834
14483
|
// TODO: This is a good second source of plugins. This function contains the CSS variable
|
|
12835
14484
|
// and unit conversion support. These functions share a common signature. We could make another
|
|
@@ -13119,7 +14768,7 @@ if (typeof window !== "undefined") {
|
|
|
13119
14768
|
}
|
|
13120
14769
|
}
|
|
13121
14770
|
|
|
13122
|
-
var MotionWrapper =
|
|
14771
|
+
var MotionWrapper = styled(motion.div).withConfig({
|
|
13123
14772
|
displayName: "Motionstyled__MotionWrapper",
|
|
13124
14773
|
componentId: "sc-1m6r1io-0"
|
|
13125
14774
|
})(["position:", ";display:", ";box-sizing:border-box;padding:", ";border:", ";border-color:", ";border-size:", ";border-style:", ";border-width:", ";border-radius:", ";background-color:", ";box-shadow:", ";min-height:", ";min-width:", ";height:", ";width:", ";text-align:", ";margin:", ";&:hover,&:focus{", ";}&:active{", ";}&:disabled{", ";}", ";"], function (_ref) {
|
|
@@ -13237,7 +14886,7 @@ var Motion = function Motion(_ref) {
|
|
|
13237
14886
|
}, rest), safeChildren(children, /*#__PURE__*/React__default.createElement(React.Fragment, null)));
|
|
13238
14887
|
};
|
|
13239
14888
|
|
|
13240
|
-
var ReelStyled =
|
|
14889
|
+
var ReelStyled = styled.div.withConfig({
|
|
13241
14890
|
displayName: "Reelstyled__ReelStyled",
|
|
13242
14891
|
componentId: "sc-bhf05j-0"
|
|
13243
14892
|
})(["display:flex;overflow-x:", ";padding:", ";height:", ";justify-content:", ";> * + *{margin-left:", ";}> *{flex:0 0 ", ";}", ""], function (_ref) {
|
|
@@ -13525,11 +15174,11 @@ var rotate = posed.div({
|
|
|
13525
15174
|
}
|
|
13526
15175
|
}
|
|
13527
15176
|
});
|
|
13528
|
-
var SpinnerContainer =
|
|
15177
|
+
var SpinnerContainer = styled.div.withConfig({
|
|
13529
15178
|
displayName: "Spinner__SpinnerContainer",
|
|
13530
15179
|
componentId: "sc-jphte-0"
|
|
13531
15180
|
})(["width:100%;display:flex;flex-direction:row;align-items:center;justify-content:center;"]);
|
|
13532
|
-
var SpinnerIconWrapper =
|
|
15181
|
+
var SpinnerIconWrapper = styled(rotate).withConfig({
|
|
13533
15182
|
displayName: "Spinner__SpinnerIconWrapper",
|
|
13534
15183
|
componentId: "sc-jphte-1"
|
|
13535
15184
|
})(["width:", "px;height:", "px;"], function (_ref) {
|
|
@@ -13575,7 +15224,7 @@ var SpinnerIcon = function SpinnerIcon(_ref3) {
|
|
|
13575
15224
|
}))))));
|
|
13576
15225
|
};
|
|
13577
15226
|
|
|
13578
|
-
var _excluded$h = ["action", "variant", "text", "isLoading", "dataQa", "textExtraStyles", "contentOverride", "extraStyles", "tabIndex", "children"];
|
|
15227
|
+
var _excluded$h = ["action", "variant", "text", "textWrap", "isLoading", "dataQa", "textExtraStyles", "contentOverride", "extraStyles", "tabIndex", "children"];
|
|
13579
15228
|
var rotate$1 = posed.div({
|
|
13580
15229
|
fixed: {
|
|
13581
15230
|
rotate: "0deg"
|
|
@@ -13591,11 +15240,11 @@ var rotate$1 = posed.div({
|
|
|
13591
15240
|
}
|
|
13592
15241
|
}
|
|
13593
15242
|
});
|
|
13594
|
-
var SpinnerContainer$1 =
|
|
15243
|
+
var SpinnerContainer$1 = styled.div.withConfig({
|
|
13595
15244
|
displayName: "ButtonWithAction__SpinnerContainer",
|
|
13596
15245
|
componentId: "sc-1ffs4ga-0"
|
|
13597
15246
|
})(["width:100%;display:flex;flex-direction:row;align-items:center;justify-content:center;"]);
|
|
13598
|
-
var SpinnerIconWrapper$1 =
|
|
15247
|
+
var SpinnerIconWrapper$1 = styled(rotate$1).withConfig({
|
|
13599
15248
|
displayName: "ButtonWithAction__SpinnerIconWrapper",
|
|
13600
15249
|
componentId: "sc-1ffs4ga-1"
|
|
13601
15250
|
})([""]);
|
|
@@ -13632,6 +15281,8 @@ var ButtonWithAction = function ButtonWithAction(_ref2) {
|
|
|
13632
15281
|
_ref2$variant = _ref2.variant,
|
|
13633
15282
|
variant = _ref2$variant === void 0 ? "primary" : _ref2$variant,
|
|
13634
15283
|
text = _ref2.text,
|
|
15284
|
+
_ref2$textWrap = _ref2.textWrap,
|
|
15285
|
+
textWrap = _ref2$textWrap === void 0 ? false : _ref2$textWrap,
|
|
13635
15286
|
_ref2$isLoading = _ref2.isLoading,
|
|
13636
15287
|
isLoading = _ref2$isLoading === void 0 ? false : _ref2$isLoading,
|
|
13637
15288
|
_ref2$dataQa = _ref2.dataQa,
|
|
@@ -13645,7 +15296,7 @@ var ButtonWithAction = function ButtonWithAction(_ref2) {
|
|
|
13645
15296
|
children = _ref2.children,
|
|
13646
15297
|
rest = _objectWithoutProperties(_ref2, _excluded$h);
|
|
13647
15298
|
|
|
13648
|
-
var themeContext = React.useContext(
|
|
15299
|
+
var themeContext = React.useContext(ThemeContext);
|
|
13649
15300
|
var themeValues = createThemeValues(themeContext, fallbackValues$1, "Button", variant);
|
|
13650
15301
|
var isMobile = themeContext.isMobile;
|
|
13651
15302
|
var hoverStyles = "\n outline: none;\n background-color: ".concat(themeValues.hoverBackgroundColor, ";\n border-color: ").concat(themeValues.hoverBorderColor, ";\n color: ").concat(themeValues.hoverColor, ";\n text-decoration: ").concat(variant === "ghost" || variant === "smallGhost" ? "underline" : "none", ";\n cursor: pointer;\n ");
|
|
@@ -13676,6 +15327,7 @@ var ButtonWithAction = function ButtonWithAction(_ref2) {
|
|
|
13676
15327
|
weight: themeValues.fontWeight,
|
|
13677
15328
|
variant: themeValues.fontSizeVariant,
|
|
13678
15329
|
color: themeValues.color,
|
|
15330
|
+
textWrap: textWrap,
|
|
13679
15331
|
extraStyles: textExtraStyles
|
|
13680
15332
|
}, text)));
|
|
13681
15333
|
};
|
|
@@ -14619,11 +16271,11 @@ var GenericCard = function GenericCard() {
|
|
|
14619
16271
|
})))));
|
|
14620
16272
|
};
|
|
14621
16273
|
|
|
14622
|
-
var BankItemWrapper =
|
|
16274
|
+
var BankItemWrapper = styled.div.withConfig({
|
|
14623
16275
|
displayName: "PaymentIcon__BankItemWrapper",
|
|
14624
16276
|
componentId: "sc-1k0jl35-0"
|
|
14625
16277
|
})(["display:flex;justify-content:flex-start;align-items:center;"]);
|
|
14626
|
-
var BankAccountText =
|
|
16278
|
+
var BankAccountText = styled.h4.withConfig({
|
|
14627
16279
|
displayName: "PaymentIcon__BankAccountText",
|
|
14628
16280
|
componentId: "sc-1k0jl35-1"
|
|
14629
16281
|
})(["color:", ";font-size:1rem;font-weight:400;line-height:1.5rem;text-align:left;margin-right:0.5rem;display:inline-block;"], CHARADE_GREY);
|
|
@@ -14856,8 +16508,7 @@ var TimeoutImage = function TimeoutImage() {
|
|
|
14856
16508
|
})))));
|
|
14857
16509
|
};
|
|
14858
16510
|
|
|
14859
|
-
var AutopayOnIcon = function AutopayOnIcon(
|
|
14860
|
-
var themeValues = _ref.themeValues;
|
|
16511
|
+
var AutopayOnIcon = function AutopayOnIcon() {
|
|
14861
16512
|
return /*#__PURE__*/React__default.createElement("svg", {
|
|
14862
16513
|
xmlns: "http://www.w3.org/2000/svg",
|
|
14863
16514
|
width: "12",
|
|
@@ -14870,14 +16521,12 @@ var AutopayOnIcon = function AutopayOnIcon(_ref) {
|
|
|
14870
16521
|
strokeWidth: "1"
|
|
14871
16522
|
}, /*#__PURE__*/React__default.createElement("path", {
|
|
14872
16523
|
className: "autopayIcon",
|
|
14873
|
-
fill:
|
|
16524
|
+
fill: SEA_GREEN,
|
|
14874
16525
|
fillRule: "nonzero",
|
|
14875
16526
|
d: "M1.898 5.75c.079 0 .141-.02.188-.059a.281.281 0 00.094-.152 3.825 3.825 0 011.394-2.144A3.838 3.838 0 016 2.563c.5 0 .98.09 1.441.27.461.179.88.44 1.254.784l-.984.985A.542.542 0 007.547 5c0 .156.055.29.164.398.11.11.242.165.398.165h3.141c.156 0 .289-.055.398-.165A.542.542 0 0011.812 5V1.86a.542.542 0 00-.164-.399.542.542 0 00-.398-.164.542.542 0 00-.398.164l-.844.844A5.699 5.699 0 006 .688c-.938 0-1.809.207-2.613.62-.805.415-1.48.981-2.028 1.7A5.726 5.726 0 00.281 5.422a.265.265 0 00.059.223c.055.07.129.105.222.105h1.336zM6 12.312c.937 0 1.809-.207 2.613-.62a5.919 5.919 0 002.028-1.7 5.726 5.726 0 001.078-2.414.265.265 0 00-.059-.223.267.267 0 00-.223-.105h-1.335c-.079 0-.141.02-.188.059a.281.281 0 00-.094.152 3.825 3.825 0 01-1.394 2.144c-.711.555-1.52.833-2.426.833-.5 0-.98-.09-1.441-.27a3.985 3.985 0 01-1.254-.785l.984-.985A.542.542 0 004.453 8a.542.542 0 00-.164-.398.542.542 0 00-.398-.164H.75a.542.542 0 00-.398.164A.542.542 0 00.187 8v3.14c0 .157.055.29.165.4.109.108.242.163.398.163.156 0 .29-.055.398-.164l.844-.844A5.699 5.699 0 006 12.312z"
|
|
14876
16527
|
})));
|
|
14877
16528
|
};
|
|
14878
16529
|
|
|
14879
|
-
var AutopayOnIcon$1 = themeComponent(AutopayOnIcon, "Icons", fallbackValues$2, "primary");
|
|
14880
|
-
|
|
14881
16530
|
var NotFoundIcon = function NotFoundIcon() {
|
|
14882
16531
|
return /*#__PURE__*/React__default.createElement("svg", {
|
|
14883
16532
|
width: "548px",
|
|
@@ -16922,7 +18571,7 @@ var Alert = function Alert(_ref) {
|
|
|
16922
18571
|
|
|
16923
18572
|
var Alert$1 = themeComponent(Alert, "Alert", fallbackValues$4, "info");
|
|
16924
18573
|
|
|
16925
|
-
var TitleText =
|
|
18574
|
+
var TitleText = styled.h1.withConfig({
|
|
16926
18575
|
displayName: "Titlestyled__TitleText",
|
|
16927
18576
|
componentId: "sc-11lhluq-0"
|
|
16928
18577
|
})(["font-size:", ";line-height:1.5;color:", ";font-weight:", ";margin:", ";text-align:", ";font-family:", ";", ";"], function (_ref) {
|
|
@@ -17041,7 +18690,7 @@ var Title = function Title(_ref) {
|
|
|
17041
18690
|
|
|
17042
18691
|
var Title$1 = themeComponent(Title, "Title", fallbacks, "large");
|
|
17043
18692
|
|
|
17044
|
-
var color$3 = "#
|
|
18693
|
+
var color$3 = "#292A33";
|
|
17045
18694
|
var fallbackValues$6 = {
|
|
17046
18695
|
color: color$3
|
|
17047
18696
|
};
|
|
@@ -17063,8 +18712,8 @@ var AmountCallout = function AmountCallout(_ref) {
|
|
|
17063
18712
|
|
|
17064
18713
|
var AmountCallout$1 = themeComponent(AmountCallout, "AmountCallout", fallbackValues$6);
|
|
17065
18714
|
|
|
17066
|
-
function _extends$
|
|
17067
|
-
_extends$
|
|
18715
|
+
function _extends$2() {
|
|
18716
|
+
_extends$2 = Object.assign || function (target) {
|
|
17068
18717
|
for (var i = 1; i < arguments.length; i++) {
|
|
17069
18718
|
var source = arguments[i];
|
|
17070
18719
|
|
|
@@ -17078,7 +18727,7 @@ function _extends$1() {
|
|
|
17078
18727
|
return target;
|
|
17079
18728
|
};
|
|
17080
18729
|
|
|
17081
|
-
return _extends$
|
|
18730
|
+
return _extends$2.apply(this, arguments);
|
|
17082
18731
|
}
|
|
17083
18732
|
|
|
17084
18733
|
function _assertThisInitialized(self) {
|
|
@@ -17185,7 +18834,7 @@ function _wrapNativeSuper(Class) {
|
|
|
17185
18834
|
* Parse errors.md and turn it into a simple hash of code: message
|
|
17186
18835
|
* @private
|
|
17187
18836
|
*/
|
|
17188
|
-
var ERRORS = {
|
|
18837
|
+
var ERRORS$1 = {
|
|
17189
18838
|
"1": "Passed invalid arguments to hsl, please pass multiple numbers e.g. hsl(360, 0.75, 0.4) or an object e.g. rgb({ hue: 255, saturation: 0.4, lightness: 0.75 }).\n\n",
|
|
17190
18839
|
"2": "Passed invalid arguments to hsla, please pass multiple numbers e.g. hsla(360, 0.75, 0.4, 0.7) or an object e.g. rgb({ hue: 255, saturation: 0.4, lightness: 0.75, alpha: 0.7 }).\n\n",
|
|
17191
18840
|
"3": "Passed an incorrect argument to a color function, please pass a string representation of a color.\n\n",
|
|
@@ -17270,7 +18919,7 @@ var ERRORS = {
|
|
|
17270
18919
|
* @private
|
|
17271
18920
|
*/
|
|
17272
18921
|
|
|
17273
|
-
function format() {
|
|
18922
|
+
function format$1() {
|
|
17274
18923
|
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
17275
18924
|
args[_key] = arguments[_key];
|
|
17276
18925
|
}
|
|
@@ -17308,7 +18957,7 @@ var PolishedError = /*#__PURE__*/function (_Error) {
|
|
|
17308
18957
|
args[_key2 - 1] = arguments[_key2];
|
|
17309
18958
|
}
|
|
17310
18959
|
|
|
17311
|
-
_this = _Error.call(this, format.apply(void 0, [ERRORS[code]].concat(args))) || this;
|
|
18960
|
+
_this = _Error.call(this, format$1.apply(void 0, [ERRORS$1[code]].concat(args))) || this;
|
|
17312
18961
|
}
|
|
17313
18962
|
|
|
17314
18963
|
return _assertThisInitialized(_this);
|
|
@@ -17812,13 +19461,13 @@ function mix$1(weight, color, otherColor) {
|
|
|
17812
19461
|
if (weight === 0) return otherColor;
|
|
17813
19462
|
var parsedColor1 = parseToRgb(color);
|
|
17814
19463
|
|
|
17815
|
-
var color1 = _extends$
|
|
19464
|
+
var color1 = _extends$2({}, parsedColor1, {
|
|
17816
19465
|
alpha: typeof parsedColor1.alpha === 'number' ? parsedColor1.alpha : 1
|
|
17817
19466
|
});
|
|
17818
19467
|
|
|
17819
19468
|
var parsedColor2 = parseToRgb(otherColor);
|
|
17820
19469
|
|
|
17821
|
-
var color2 = _extends$
|
|
19470
|
+
var color2 = _extends$2({}, parsedColor2, {
|
|
17822
19471
|
alpha: typeof parsedColor2.alpha === 'number' ? parsedColor2.alpha : 1
|
|
17823
19472
|
}); // The formula is copied from the original Sass implementation:
|
|
17824
19473
|
// http://sass-lang.com/documentation/Sass/Script/Functions.html#mix-instance_method
|
|
@@ -17954,7 +19603,7 @@ var _excluded$k = ["hoverColor", "activeColor", "extrastyles"];
|
|
|
17954
19603
|
|
|
17955
19604
|
/* eslint-disable no-unused-vars */
|
|
17956
19605
|
|
|
17957
|
-
var StyledExternalLink =
|
|
19606
|
+
var StyledExternalLink = styled(function (_ref) {
|
|
17958
19607
|
var hoverColor = _ref.hoverColor,
|
|
17959
19608
|
activeColor = _ref.activeColor,
|
|
17960
19609
|
extrastyles = _ref.extrastyles,
|
|
@@ -18008,8 +19657,9 @@ var ExternalLink = function ExternalLink(_ref) {
|
|
|
18008
19657
|
variant = _ref$variant === void 0 ? "primary" : _ref$variant,
|
|
18009
19658
|
_ref$tabIndex = _ref.tabIndex,
|
|
18010
19659
|
tabIndex = _ref$tabIndex === void 0 ? "0" : _ref$tabIndex,
|
|
19660
|
+
dataQa = _ref.dataQa,
|
|
18011
19661
|
children = _ref.children;
|
|
18012
|
-
var themeContext = React.useContext(
|
|
19662
|
+
var themeContext = React.useContext(ThemeContext);
|
|
18013
19663
|
var themeValues = createThemeValues(themeContext, fallbackValues$9, "Link", variant);
|
|
18014
19664
|
return /*#__PURE__*/React__default.createElement(StyledExternalLink, {
|
|
18015
19665
|
href: href,
|
|
@@ -18023,7 +19673,8 @@ var ExternalLink = function ExternalLink(_ref) {
|
|
|
18023
19673
|
fontFamily: themeValues.fontFamily,
|
|
18024
19674
|
tabIndex: tabIndex,
|
|
18025
19675
|
extrastyles: extraStyles,
|
|
18026
|
-
rel: newTab ? "noopener" : ""
|
|
19676
|
+
rel: newTab ? "noopener" : "",
|
|
19677
|
+
"data-qa": dataQa
|
|
18027
19678
|
}, safeChildren(children, /*#__PURE__*/React__default.createElement("span", null)));
|
|
18028
19679
|
};
|
|
18029
19680
|
|
|
@@ -18035,7 +19686,7 @@ var _excluded$l = ["hoverColor", "activeColor", "active", "color", "extrastyles"
|
|
|
18035
19686
|
|
|
18036
19687
|
/* eslint-disable no-unused-vars */
|
|
18037
19688
|
|
|
18038
|
-
var StyledInternalLink =
|
|
19689
|
+
var StyledInternalLink = styled(function (_ref) {
|
|
18039
19690
|
var hoverColor = _ref.hoverColor,
|
|
18040
19691
|
activeColor = _ref.activeColor,
|
|
18041
19692
|
active = _ref.active,
|
|
@@ -18093,9 +19744,10 @@ var InternalLink = function InternalLink(_ref) {
|
|
|
18093
19744
|
margin = _ref.margin,
|
|
18094
19745
|
_ref$tabIndex = _ref.tabIndex,
|
|
18095
19746
|
tabIndex = _ref$tabIndex === void 0 ? "0" : _ref$tabIndex,
|
|
19747
|
+
dataQa = _ref.dataQa,
|
|
18096
19748
|
_ref$extraStyles = _ref.extraStyles,
|
|
18097
19749
|
extraStyles = _ref$extraStyles === void 0 ? "" : _ref$extraStyles;
|
|
18098
|
-
var themeContext = React.useContext(
|
|
19750
|
+
var themeContext = React.useContext(ThemeContext);
|
|
18099
19751
|
var themeValues = createThemeValues(themeContext, fallbackValues$9, "Link", variant);
|
|
18100
19752
|
return /*#__PURE__*/React__default.createElement(StyledInternalLink, {
|
|
18101
19753
|
to: to,
|
|
@@ -18109,14 +19761,15 @@ var InternalLink = function InternalLink(_ref) {
|
|
|
18109
19761
|
hoverColor: themeValues.hoverColor,
|
|
18110
19762
|
activeColor: themeValues.activeColor,
|
|
18111
19763
|
tabIndex: tabIndex,
|
|
18112
|
-
extrastyles: extraStyles
|
|
19764
|
+
extrastyles: extraStyles,
|
|
19765
|
+
"data-qa": dataQa
|
|
18113
19766
|
}, safeChildren(children, /*#__PURE__*/React__default.createElement("span", null)));
|
|
18114
19767
|
};
|
|
18115
19768
|
|
|
18116
19769
|
var Breadcrumbs = function Breadcrumbs(_ref) {
|
|
18117
19770
|
var _ref$breadcrumbsList = _ref.breadcrumbsList,
|
|
18118
19771
|
breadcrumbsList = _ref$breadcrumbsList === void 0 ? [] : _ref$breadcrumbsList;
|
|
18119
|
-
var themeContext = React.useContext(
|
|
19772
|
+
var themeContext = React.useContext(ThemeContext);
|
|
18120
19773
|
var themeValues = createThemeValues(themeContext, fallbackValues$8, "Breadcrumb");
|
|
18121
19774
|
return /*#__PURE__*/React__default.createElement(Box, {
|
|
18122
19775
|
padding: "0",
|
|
@@ -19722,7 +21375,7 @@ _curry2(function test(pattern, str) {
|
|
|
19722
21375
|
|
|
19723
21376
|
var URL_TEST = /(([a-z]{3,6}:\/\/)|(^|\s))([a-zA-Z0-9\-]+\.)+[a-z]{2,13}[\.\?\=\&\%\/\w\-]*\b([^@]|$)/;
|
|
19724
21377
|
|
|
19725
|
-
var _excluded$m = ["url", "disabled", "fileLink", "extraStyles", "linkExtraStyles", "newTab"];
|
|
21378
|
+
var _excluded$m = ["url", "disabled", "fileLink", "extraStyles", "linkExtraStyles", "newTab", "dataQa"];
|
|
19726
21379
|
|
|
19727
21380
|
var ButtonWithLink = function ButtonWithLink(_ref) {
|
|
19728
21381
|
var _ref$url = _ref.url,
|
|
@@ -19735,6 +21388,7 @@ var ButtonWithLink = function ButtonWithLink(_ref) {
|
|
|
19735
21388
|
linkExtraStyles = _ref.linkExtraStyles,
|
|
19736
21389
|
_ref$newTab = _ref.newTab,
|
|
19737
21390
|
newTab = _ref$newTab === void 0 ? false : _ref$newTab,
|
|
21391
|
+
dataQa = _ref.dataQa,
|
|
19738
21392
|
otherProps = _objectWithoutProperties(_ref, _excluded$m);
|
|
19739
21393
|
|
|
19740
21394
|
var ButtonWithLinkWrapper = function ButtonWithLinkWrapper(_ref2) {
|
|
@@ -19742,6 +21396,7 @@ var ButtonWithLink = function ButtonWithLink(_ref) {
|
|
|
19742
21396
|
url = _ref2.url,
|
|
19743
21397
|
disabled = _ref2.disabled,
|
|
19744
21398
|
newTab = _ref2.newTab,
|
|
21399
|
+
dataQa = _ref2.dataQa,
|
|
19745
21400
|
extraStyles = _ref2.extraStyles;
|
|
19746
21401
|
|
|
19747
21402
|
if (disabled) {
|
|
@@ -19752,10 +21407,12 @@ var ButtonWithLink = function ButtonWithLink(_ref) {
|
|
|
19752
21407
|
href: url,
|
|
19753
21408
|
tabIndex: "-1",
|
|
19754
21409
|
newTab: newTab,
|
|
19755
|
-
extraStyles: extraStyles
|
|
21410
|
+
extraStyles: extraStyles,
|
|
21411
|
+
dataQa: dataQa
|
|
19756
21412
|
}, safeChildren(children, /*#__PURE__*/React__default.createElement("span", null))) : /*#__PURE__*/React__default.createElement(InternalLink, {
|
|
19757
21413
|
to: url,
|
|
19758
21414
|
tabIndex: "-1",
|
|
21415
|
+
dataQa: dataQa,
|
|
19759
21416
|
extraStyles: extraStyles
|
|
19760
21417
|
}, safeChildren(children, /*#__PURE__*/React__default.createElement("span", null)));
|
|
19761
21418
|
};
|
|
@@ -19764,7 +21421,8 @@ var ButtonWithLink = function ButtonWithLink(_ref) {
|
|
|
19764
21421
|
url: url,
|
|
19765
21422
|
disabled: disabled,
|
|
19766
21423
|
newTab: newTab,
|
|
19767
|
-
extraStyles: "".concat(linkExtraStyles, " text-decoration: none; &:hover {\n text-decoration: none; }")
|
|
21424
|
+
extraStyles: "".concat(linkExtraStyles, " text-decoration: none; &:hover {\n text-decoration: none; }"),
|
|
21425
|
+
dataQa: dataQa
|
|
19768
21426
|
}, /*#__PURE__*/React__default.createElement(ButtonWithAction, _extends({}, otherProps, {
|
|
19769
21427
|
extraStyles: extraStyles
|
|
19770
21428
|
})));
|
|
@@ -19798,7 +21456,7 @@ var fallbackValues$a = {
|
|
|
19798
21456
|
fontSize: fontSize$3
|
|
19799
21457
|
};
|
|
19800
21458
|
|
|
19801
|
-
var ParagraphText =
|
|
21459
|
+
var ParagraphText = styled.p.withConfig({
|
|
19802
21460
|
displayName: "Paragraphstyled__ParagraphText",
|
|
19803
21461
|
componentId: "sc-17g98kx-0"
|
|
19804
21462
|
})(["--font-size:", ";font-size:var(--font-size);line-height:calc(1.5 * var(--font-size));font-weight:", ";font-family:", ";color:", ";margin:", ";", ""], function (_ref) {
|
|
@@ -19908,7 +21566,7 @@ var withWindowSize = function withWindowSize(Child) {
|
|
|
19908
21566
|
window.removeEventListener("resize", onResize);
|
|
19909
21567
|
};
|
|
19910
21568
|
}, []);
|
|
19911
|
-
return /*#__PURE__*/React__default.createElement(
|
|
21569
|
+
return /*#__PURE__*/React__default.createElement(ThemeProvider, {
|
|
19912
21570
|
theme: state
|
|
19913
21571
|
}, /*#__PURE__*/React__default.createElement(Child, props));
|
|
19914
21572
|
};
|
|
@@ -19938,7 +21596,7 @@ var Card = function Card(_ref2) {
|
|
|
19938
21596
|
_ref2$variant = _ref2.variant,
|
|
19939
21597
|
variant = _ref2$variant === void 0 ? "vertical" : _ref2$variant;
|
|
19940
21598
|
|
|
19941
|
-
var _useContext = React.useContext(
|
|
21599
|
+
var _useContext = React.useContext(ThemeContext),
|
|
19942
21600
|
isMobile = _useContext.isMobile;
|
|
19943
21601
|
|
|
19944
21602
|
var navigate = reactRouterDom.useNavigate();
|
|
@@ -20100,30 +21758,30 @@ var fallbackValues$c = {
|
|
|
20100
21758
|
disabledCheckedStyles: disabledCheckedStyles
|
|
20101
21759
|
};
|
|
20102
21760
|
|
|
20103
|
-
var CheckboxContainer =
|
|
21761
|
+
var CheckboxContainer = styled.div.withConfig({
|
|
20104
21762
|
displayName: "Checkbox__CheckboxContainer",
|
|
20105
21763
|
componentId: "sc-36kqbv-0"
|
|
20106
21764
|
})(["display:inline-block;vertical-align:middle;"]);
|
|
20107
|
-
var CheckboxLabelContainer =
|
|
21765
|
+
var CheckboxLabelContainer = styled.label.withConfig({
|
|
20108
21766
|
displayName: "Checkbox__CheckboxLabelContainer",
|
|
20109
21767
|
componentId: "sc-36kqbv-1"
|
|
20110
21768
|
})(["display:flex;align-items:center;"]);
|
|
20111
|
-
var CheckboxIcon =
|
|
21769
|
+
var CheckboxIcon = styled.svg.withConfig({
|
|
20112
21770
|
displayName: "Checkbox__CheckboxIcon",
|
|
20113
21771
|
componentId: "sc-36kqbv-2"
|
|
20114
21772
|
})(["fill:none;stroke-width:2px;stroke:", ";"], function (_ref) {
|
|
20115
21773
|
var disabled = _ref.disabled,
|
|
20116
21774
|
disabledCheckColor = _ref.disabledCheckColor,
|
|
20117
21775
|
checkColor = _ref.checkColor;
|
|
20118
|
-
return disabled ?
|
|
21776
|
+
return disabled ? css(["", ""], disabledCheckColor) : css(["", ""], checkColor);
|
|
20119
21777
|
});
|
|
20120
|
-
var HiddenCheckbox =
|
|
21778
|
+
var HiddenCheckbox = styled.input.attrs({
|
|
20121
21779
|
type: "checkbox"
|
|
20122
21780
|
}).withConfig({
|
|
20123
21781
|
displayName: "Checkbox__HiddenCheckbox",
|
|
20124
21782
|
componentId: "sc-36kqbv-3"
|
|
20125
21783
|
})(["border:0;clip:rect(0 0 0 0);clippath:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:1px;"]);
|
|
20126
|
-
var StyledCheckbox =
|
|
21784
|
+
var StyledCheckbox = styled.div.withConfig({
|
|
20127
21785
|
displayName: "Checkbox__StyledCheckbox",
|
|
20128
21786
|
componentId: "sc-36kqbv-4"
|
|
20129
21787
|
})(["display:inline-block;margin-right:16px;width:24px;height:24px;border-radius:2px;transition:all 150ms;", "{visibility:", ";}", ";"], CheckboxIcon, function (_ref2) {
|
|
@@ -20140,7 +21798,7 @@ var StyledCheckbox = qe.div.withConfig({
|
|
|
20140
21798
|
errorStyles = _ref3.errorStyles,
|
|
20141
21799
|
disabledStyles = _ref3.disabledStyles,
|
|
20142
21800
|
disabledCheckedStyles = _ref3.disabledCheckedStyles;
|
|
20143
|
-
return error ?
|
|
21801
|
+
return error ? css(["", " ", ""], errorStyles, focused && focusedStyles) : disabled ? css(["", ""], checked ? disabledCheckedStyles : disabledStyles) : checked ? css(["", " ", ""], checkedStyles, focused && focusedStyles) : css(["", " ", ""], defaultStyles, focused && focusedStyles);
|
|
20144
21802
|
});
|
|
20145
21803
|
|
|
20146
21804
|
var Checkbox = function Checkbox(_ref4) {
|
|
@@ -20271,7 +21929,7 @@ var defaultTheme = {
|
|
|
20271
21929
|
inactiveColor: PEWTER_GREY$1
|
|
20272
21930
|
}
|
|
20273
21931
|
};
|
|
20274
|
-
var RadioButtonBorder =
|
|
21932
|
+
var RadioButtonBorder = styled.div.withConfig({
|
|
20275
21933
|
displayName: "radio-button__RadioButtonBorder",
|
|
20276
21934
|
componentId: "sc-8odgi0-0"
|
|
20277
21935
|
})(["height:24px;width:24px;border:1px solid ", ";border-radius:12px;display:flex;justify-content:center;align-items:center;margin:10px;min-width:24px;min-height:24px;"], function (_ref) {
|
|
@@ -20280,7 +21938,7 @@ var RadioButtonBorder = qe.div.withConfig({
|
|
|
20280
21938
|
return isSelected ? theme.accentColor : theme.inactiveColor;
|
|
20281
21939
|
});
|
|
20282
21940
|
RadioButtonBorder.defaultProps = defaultTheme;
|
|
20283
|
-
var RadioButtonCenter =
|
|
21941
|
+
var RadioButtonCenter = styled.div.withConfig({
|
|
20284
21942
|
displayName: "radio-button__RadioButtonCenter",
|
|
20285
21943
|
componentId: "sc-8odgi0-1"
|
|
20286
21944
|
})(["height:16px;width:16px;background-color:", ";border-radius:8px;"], function (_ref2) {
|
|
@@ -20299,15 +21957,15 @@ var RadioButton = function RadioButton(_ref3) {
|
|
|
20299
21957
|
}, isSelected && /*#__PURE__*/React__default.createElement(RadioButtonCenter, null));
|
|
20300
21958
|
};
|
|
20301
21959
|
|
|
20302
|
-
var CheckboxItemIcon =
|
|
21960
|
+
var CheckboxItemIcon = styled.img.withConfig({
|
|
20303
21961
|
displayName: "CheckboxList__CheckboxItemIcon",
|
|
20304
21962
|
componentId: "sc-1yakme1-0"
|
|
20305
21963
|
})(["width:2rem;"]);
|
|
20306
|
-
var HiddenCheckboxInput =
|
|
21964
|
+
var HiddenCheckboxInput = styled.input.withConfig({
|
|
20307
21965
|
displayName: "CheckboxList__HiddenCheckboxInput",
|
|
20308
21966
|
componentId: "sc-1yakme1-1"
|
|
20309
21967
|
})(["opacity:0;position:absolute;z-index:-2;cursor:pointer;"]);
|
|
20310
|
-
var CheckboxLabel =
|
|
21968
|
+
var CheckboxLabel = styled.label.withConfig({
|
|
20311
21969
|
displayName: "CheckboxList__CheckboxLabel",
|
|
20312
21970
|
componentId: "sc-1yakme1-2"
|
|
20313
21971
|
})(["position:relative;z-index:5;&:focus{outline:none;}"]);
|
|
@@ -20351,7 +22009,7 @@ var CheckboxListItem = function CheckboxListItem(_ref) {
|
|
|
20351
22009
|
onClick: disabled ? noop : onSelect,
|
|
20352
22010
|
onKeyDown: disabled ? noop : onSelect,
|
|
20353
22011
|
tabIndex: 0
|
|
20354
|
-
}, /*#__PURE__*/React__default.createElement(
|
|
22012
|
+
}, /*#__PURE__*/React__default.createElement(ThemeProvider, {
|
|
20355
22013
|
theme: {
|
|
20356
22014
|
accentColor: radioButtonActive,
|
|
20357
22015
|
inactiveColor: radioButtonInactive
|
|
@@ -20450,14 +22108,14 @@ var fallbackValues$e = {
|
|
|
20450
22108
|
hoverColor: hoverColor$3
|
|
20451
22109
|
};
|
|
20452
22110
|
|
|
20453
|
-
var IconWrapper =
|
|
22111
|
+
var IconWrapper = styled.div.withConfig({
|
|
20454
22112
|
displayName: "Dropdown__IconWrapper",
|
|
20455
22113
|
componentId: "sc-pn6m0h-0"
|
|
20456
22114
|
})(["display:flex;flex-direction:column;justify-content:center;transition:transform 0.3s ease;", ""], function (_ref) {
|
|
20457
22115
|
var open = _ref.open;
|
|
20458
22116
|
return open ? "transform: rotate(-180deg)" : "";
|
|
20459
22117
|
});
|
|
20460
|
-
var DropdownContentWrapper =
|
|
22118
|
+
var DropdownContentWrapper = styled.div.withConfig({
|
|
20461
22119
|
displayName: "Dropdown__DropdownContentWrapper",
|
|
20462
22120
|
componentId: "sc-pn6m0h-1"
|
|
20463
22121
|
})(["transform-origin:0 0;border:1px solid ", ";border-radius:2px;background-color:", ";padding:8px 0 8px;position:absolute;width:", ";min-width:100%;max-height:", ";overflow-y:scroll;z-index:1;box-sizing:border-box;&:focus{outline:none;}"], GREY_CHATEAU, WHITE, function (_ref2) {
|
|
@@ -20467,7 +22125,7 @@ var DropdownContentWrapper = qe.div.withConfig({
|
|
|
20467
22125
|
var maxHeight = _ref3.maxHeight;
|
|
20468
22126
|
return maxHeight || "400px";
|
|
20469
22127
|
});
|
|
20470
|
-
var DropdownItemWrapper =
|
|
22128
|
+
var DropdownItemWrapper = styled.div.withConfig({
|
|
20471
22129
|
displayName: "Dropdown__DropdownItemWrapper",
|
|
20472
22130
|
componentId: "sc-pn6m0h-2"
|
|
20473
22131
|
})(["background-color:", ";text-align:start;border-width:0px;border-color:transparent;box-shadow:none;padding:1rem;box-sizing:border-box;width:100%;cursor:", ";&:hover{background-color:", ";}&:focus{background-color:", ";outline:none;}"], function (_ref4) {
|
|
@@ -20488,7 +22146,7 @@ var DropdownItemWrapper = qe.div.withConfig({
|
|
|
20488
22146
|
themeValues = _ref7.themeValues;
|
|
20489
22147
|
return selected ? themeValues.selectedColor : disabled ? WHITE : themeValues.hoverColor;
|
|
20490
22148
|
});
|
|
20491
|
-
var SearchInput =
|
|
22149
|
+
var SearchInput = styled.input.withConfig({
|
|
20492
22150
|
displayName: "Dropdown__SearchInput",
|
|
20493
22151
|
componentId: "sc-pn6m0h-3"
|
|
20494
22152
|
})(["border:none;background-color:", ";font-size:16px;height:24px;"], function (_ref8) {
|
|
@@ -20719,11 +22377,11 @@ var Dropdown = function Dropdown(_ref9) {
|
|
|
20719
22377
|
|
|
20720
22378
|
var Dropdown$1 = themeComponent(Dropdown, "Dropdown", fallbackValues$e);
|
|
20721
22379
|
|
|
20722
|
-
var SelectContainer =
|
|
22380
|
+
var SelectContainer = styled.div.withConfig({
|
|
20723
22381
|
displayName: "FormSelectstyled__SelectContainer",
|
|
20724
22382
|
componentId: "sc-hkrqrv-0"
|
|
20725
22383
|
})(["width:100%;display:flex;flex-direction:column;justify-content:space-between;align-items:flex-start;> * + *{margin-top:0.25rem;}"]);
|
|
20726
|
-
var SelectField =
|
|
22384
|
+
var SelectField = styled.select.withConfig({
|
|
20727
22385
|
displayName: "FormSelectstyled__SelectField",
|
|
20728
22386
|
componentId: "sc-hkrqrv-1"
|
|
20729
22387
|
})(["border:1px solid ", ";border-radius:2px;height:48px;width:100%;padding:0.75rem 1rem;min-width:100px;margin:0;box-sizing:border-box;position:relative;font-size:1.1rem;font-family:Public Sans;line-height:2rem;font-weight:", ";background-color:", ";color:", ";box-shadow:none;&:focus{border:1px solid ", ";}"], function (_ref) {
|
|
@@ -20737,7 +22395,7 @@ var SelectField = qe.select.withConfig({
|
|
|
20737
22395
|
var themeValues = _ref3.themeValues;
|
|
20738
22396
|
return themeValues.color && themeValues.color;
|
|
20739
22397
|
}, MATISSE_BLUE);
|
|
20740
|
-
var SelectOption =
|
|
22398
|
+
var SelectOption = styled.option.withConfig({
|
|
20741
22399
|
displayName: "FormSelectstyled__SelectOption",
|
|
20742
22400
|
componentId: "sc-hkrqrv-2"
|
|
20743
22401
|
})([""]);
|
|
@@ -21647,7 +23305,7 @@ var CountryDropdown = function CountryDropdown(_ref) {
|
|
|
21647
23305
|
});
|
|
21648
23306
|
};
|
|
21649
23307
|
|
|
21650
|
-
var DetailText =
|
|
23308
|
+
var DetailText = styled.p.withConfig({
|
|
21651
23309
|
displayName: "Detailstyled__DetailText",
|
|
21652
23310
|
componentId: "sc-vn1h4n-0"
|
|
21653
23311
|
})(["font-size:", ";line-height:1.5;color:", ";font-weight:", ";margin:", ";text-align:", ";font-family:", ";", ";"], function (_ref) {
|
|
@@ -21851,8 +23509,8 @@ var DisplayCard = function DisplayCard(_ref) {
|
|
|
21851
23509
|
}) : /*#__PURE__*/React__default.createElement(React.Fragment, null))))));
|
|
21852
23510
|
};
|
|
21853
23511
|
|
|
21854
|
-
function _extends$
|
|
21855
|
-
_extends$
|
|
23512
|
+
function _extends$3() {
|
|
23513
|
+
_extends$3 = Object.assign || function (target) {
|
|
21856
23514
|
for (var i = 1; i < arguments.length; i++) {
|
|
21857
23515
|
var source = arguments[i];
|
|
21858
23516
|
|
|
@@ -21866,10 +23524,10 @@ function _extends$2() {
|
|
|
21866
23524
|
return target;
|
|
21867
23525
|
};
|
|
21868
23526
|
|
|
21869
|
-
return _extends$
|
|
23527
|
+
return _extends$3.apply(this, arguments);
|
|
21870
23528
|
}
|
|
21871
23529
|
|
|
21872
|
-
function _objectWithoutPropertiesLoose$
|
|
23530
|
+
function _objectWithoutPropertiesLoose$2(source, excluded) {
|
|
21873
23531
|
if (source == null) return {};
|
|
21874
23532
|
var target = {};
|
|
21875
23533
|
var sourceKeys = Object.keys(source);
|
|
@@ -21887,7 +23545,7 @@ function _objectWithoutPropertiesLoose$1(source, excluded) {
|
|
|
21887
23545
|
function _objectWithoutProperties$1(source, excluded) {
|
|
21888
23546
|
if (source == null) return {};
|
|
21889
23547
|
|
|
21890
|
-
var target = _objectWithoutPropertiesLoose$
|
|
23548
|
+
var target = _objectWithoutPropertiesLoose$2(source, excluded);
|
|
21891
23549
|
|
|
21892
23550
|
var key, i;
|
|
21893
23551
|
|
|
@@ -21970,7 +23628,7 @@ function _nonIterableRest$1() {
|
|
|
21970
23628
|
var getUniqueFormatDelimiters = function getUniqueFormatDelimiters(formats, formatChar) {
|
|
21971
23629
|
return _toConsumableArray$1(new Set(formats.join("").split(formatChar).join("").split("")));
|
|
21972
23630
|
};
|
|
21973
|
-
var format$
|
|
23631
|
+
var format$2 = function format(formatter) {
|
|
21974
23632
|
return function (value) {
|
|
21975
23633
|
var usedFormat = formatter.formats[value.length];
|
|
21976
23634
|
|
|
@@ -22063,7 +23721,7 @@ var FormattedInput = function FormattedInput(_ref) {
|
|
|
22063
23721
|
selectionEnd: 0,
|
|
22064
23722
|
rawValue: value,
|
|
22065
23723
|
"delete": false,
|
|
22066
|
-
formattedValue: format$
|
|
23724
|
+
formattedValue: format$2(formatter)(value)
|
|
22067
23725
|
}),
|
|
22068
23726
|
_useState2 = _slicedToArray$1(_useState, 2),
|
|
22069
23727
|
state = _useState2[0],
|
|
@@ -22075,9 +23733,9 @@ var FormattedInput = function FormattedInput(_ref) {
|
|
|
22075
23733
|
inputEl.current.setSelectionRange(state.selectionStart, state.selectionEnd);
|
|
22076
23734
|
}
|
|
22077
23735
|
});
|
|
22078
|
-
return React__default.createElement("input", _extends$
|
|
23736
|
+
return React__default.createElement("input", _extends$3({}, props, {
|
|
22079
23737
|
ref: inputEl,
|
|
22080
|
-
value: format$
|
|
23738
|
+
value: format$2(formatter)(value),
|
|
22081
23739
|
onKeyDown: function onKeyDown(event) {
|
|
22082
23740
|
// Keep track of the state of the input before onChange, including if user is hitting delete
|
|
22083
23741
|
setState({
|
|
@@ -22195,7 +23853,7 @@ var fallbackValues$i = {
|
|
|
22195
23853
|
|
|
22196
23854
|
var _excluded$p = ["showErrors", "themeValues"],
|
|
22197
23855
|
_excluded2 = ["type", "labelTextWhenNoError", "errorMessages", "isNum", "isEmail", "helperModal", "field", "fieldActions", "showErrors", "formatter", "decorator", "themeValues", "background", "customHeight", "extraStyles"];
|
|
22198
|
-
var InputField =
|
|
23856
|
+
var InputField = styled.input.withConfig({
|
|
22199
23857
|
displayName: "FormInput__InputField",
|
|
22200
23858
|
componentId: "sc-l094r1-0"
|
|
22201
23859
|
})(["border:1px solid ", ";border-radius:2px;height:", ";width:100%;padding:1rem;min-width:100px;margin:0;box-sizing:border-box;position:relative;font-size:1.1rem;font-family:Public Sans;line-height:2rem;font-weight:", ";background-color:", ";color:", ";box-shadow:none;", " transition:background 0.3s ease;&:focus{outline:3px solid ", ";outline-offset:2px;}", " ", ""], function (_ref) {
|
|
@@ -22218,13 +23876,13 @@ var InputField = qe.input.withConfig({
|
|
|
22218
23876
|
return background && "background: ".concat(themeValues.inputBackgroundColor, " url(").concat(background, ") no-repeat right 0.5rem center;");
|
|
22219
23877
|
}, ROYAL_BLUE, function (_ref6) {
|
|
22220
23878
|
var disabled = _ref6.disabled;
|
|
22221
|
-
return disabled &&
|
|
23879
|
+
return disabled && css(["color:#6e727e;background-color:#f7f7f7;"]);
|
|
22222
23880
|
}, function (_ref7) {
|
|
22223
23881
|
var $extraStyles = _ref7.$extraStyles;
|
|
22224
|
-
return
|
|
23882
|
+
return css(["", ""], $extraStyles);
|
|
22225
23883
|
}); // eslint-disable-next-line no-unused-vars
|
|
22226
23884
|
|
|
22227
|
-
var FormattedInputField =
|
|
23885
|
+
var FormattedInputField = styled(function (_ref8) {
|
|
22228
23886
|
var showErrors = _ref8.showErrors,
|
|
22229
23887
|
themeValues = _ref8.themeValues,
|
|
22230
23888
|
props = _objectWithoutProperties(_ref8, _excluded$p);
|
|
@@ -22249,10 +23907,10 @@ var FormattedInputField = qe(function (_ref8) {
|
|
|
22249
23907
|
return themeValues.color && themeValues.color;
|
|
22250
23908
|
}, ROYAL_BLUE, function (_ref13) {
|
|
22251
23909
|
var disabled = _ref13.disabled;
|
|
22252
|
-
return disabled &&
|
|
23910
|
+
return disabled && css(["color:#6e727e;background-color:#f7f7f7;"]);
|
|
22253
23911
|
}, function (_ref14) {
|
|
22254
23912
|
var extraStyles = _ref14.extraStyles;
|
|
22255
|
-
return
|
|
23913
|
+
return css(["", ""], extraStyles);
|
|
22256
23914
|
});
|
|
22257
23915
|
|
|
22258
23916
|
var FormInput = function FormInput(_ref15) {
|
|
@@ -22284,7 +23942,7 @@ var FormInput = function FormInput(_ref15) {
|
|
|
22284
23942
|
showPassword = _useState2[0],
|
|
22285
23943
|
setShowPassword = _useState2[1];
|
|
22286
23944
|
|
|
22287
|
-
var _useContext = React.useContext(
|
|
23945
|
+
var _useContext = React.useContext(ThemeContext),
|
|
22288
23946
|
isMobile = _useContext.isMobile;
|
|
22289
23947
|
|
|
22290
23948
|
return /*#__PURE__*/React__default.createElement(Stack, {
|
|
@@ -22429,7 +24087,7 @@ var FormContainer = function FormContainer(_ref) {
|
|
|
22429
24087
|
children = _ref.children,
|
|
22430
24088
|
rest = _objectWithoutProperties(_ref, _excluded$s);
|
|
22431
24089
|
|
|
22432
|
-
var _useContext = React.useContext(
|
|
24090
|
+
var _useContext = React.useContext(ThemeContext),
|
|
22433
24091
|
isMobile = _useContext.isMobile;
|
|
22434
24092
|
|
|
22435
24093
|
return /*#__PURE__*/React__default.createElement(Box, _extends({
|
|
@@ -22446,7 +24104,7 @@ var FormFooterPanel = function FormFooterPanel(_ref) {
|
|
|
22446
24104
|
link = _ref.link,
|
|
22447
24105
|
linkText = _ref.linkText;
|
|
22448
24106
|
|
|
22449
|
-
var _useContext = React.useContext(
|
|
24107
|
+
var _useContext = React.useContext(ThemeContext),
|
|
22450
24108
|
isMobile = _useContext.isMobile;
|
|
22451
24109
|
|
|
22452
24110
|
return /*#__PURE__*/React__default.createElement(Box, {
|
|
@@ -22532,11 +24190,11 @@ var fallbackValues$k = {
|
|
|
22532
24190
|
var ACTIVE = "ACTIVE";
|
|
22533
24191
|
var EXPIRING_SOON = "EXPIRING_SOON";
|
|
22534
24192
|
var EXPIRED = "EXPIRED";
|
|
22535
|
-
var CreditCardWrapper =
|
|
24193
|
+
var CreditCardWrapper = styled.div.withConfig({
|
|
22536
24194
|
displayName: "FormattedCreditCard__CreditCardWrapper",
|
|
22537
24195
|
componentId: "sc-s0ta5l-0"
|
|
22538
24196
|
})(["display:flex;justify-content:flex-start;align-items:center;"]);
|
|
22539
|
-
var CCIconWrapper =
|
|
24197
|
+
var CCIconWrapper = styled.div.withConfig({
|
|
22540
24198
|
displayName: "FormattedCreditCard__CCIconWrapper",
|
|
22541
24199
|
componentId: "sc-s0ta5l-1"
|
|
22542
24200
|
})(["margin-right:16px;width:30px;height:auto;display:flex;"]);
|
|
@@ -22592,15 +24250,15 @@ var FormattedCreditCard = function FormattedCreditCard(_ref) {
|
|
|
22592
24250
|
|
|
22593
24251
|
var FormattedCreditCard$1 = themeComponent(FormattedCreditCard, "FormattedCreditCard", fallbackValues$k);
|
|
22594
24252
|
|
|
22595
|
-
var Hamburger =
|
|
24253
|
+
var Hamburger = styled.button.withConfig({
|
|
22596
24254
|
displayName: "HamburgerButton__Hamburger",
|
|
22597
24255
|
componentId: "sc-4wlnwv-0"
|
|
22598
24256
|
})(["padding:8px;display:inline-block;cursor:pointer;transition-property:opacity;transition-duration:0.15s;transition-timing-function:linear;font:inherit;color:inherit;text-transform:none;background-color:transparent;border:0;margin:0;overflow:visible;&:focus{outline:none;}"]);
|
|
22599
|
-
var HamburgerBox =
|
|
24257
|
+
var HamburgerBox = styled.span.withConfig({
|
|
22600
24258
|
displayName: "HamburgerButton__HamburgerBox",
|
|
22601
24259
|
componentId: "sc-4wlnwv-1"
|
|
22602
24260
|
})(["width:34px;height:34px;display:inline-block;position:relative;"]);
|
|
22603
|
-
var HamburgerInner =
|
|
24261
|
+
var HamburgerInner = styled.span.withConfig({
|
|
22604
24262
|
displayName: "HamburgerButton__HamburgerInner",
|
|
22605
24263
|
componentId: "sc-4wlnwv-2"
|
|
22606
24264
|
})(["display:block;top:auto;bottom:6px;left:2px;transition-duration:0.13s;transition-delay:0.13s;transition-timing-function:cubic-bezier(0.55,0.055,0.675,0.19);margin-top:12px;background-color:", ";&,&::before,&::after{background-color:", ";width:30px;height:3px;position:absolute;transition-property:transform;transition-duration:0.15s;transition-timing-function:ease;}&::before,&::after{content:\"\";display:block;}&::before{top:-10px;transition:top 0.12s 0.2s cubic-bezier(0.33333,0.66667,0.66667,1),transform 0.13s cubic-bezier(0.55,0.055,0.675,0.19);}&::after{bottom:-10px;top:-20px;transition:top 0.2s 0.2s cubic-bezier(0.33333,0.66667,0.66667,1),opacity 0.1s linear;}&.active,&.active::before,&.active::after{background-color:", ";}&.active{transform:translate3d(0,-10px,0) rotate(-45deg);transition-delay:0.22s;transition-timing-function:cubic-bezier(0.215,0.61,0.355,1);}&.active::after{top:0;opacity:0;transition:top 0.2s cubic-bezier(0.33333,0,0.66667,0.33333),opacity:0.1s 0.22s linear;}&.active::before{top:0;transform:rotate(-90deg);transition:top 0.1s 0.16s cubic-bezier(0.33333,0,0.66667,0.33333),transform 0.13s 0.25s cubic-bezier(0.215,0.61,0.355,1);}"], function (_ref) {
|
|
@@ -22634,7 +24292,7 @@ var HamburgerButton = function HamburgerButton(_ref4) {
|
|
|
22634
24292
|
})));
|
|
22635
24293
|
};
|
|
22636
24294
|
|
|
22637
|
-
var HeadingText =
|
|
24295
|
+
var HeadingText = styled.h1.withConfig({
|
|
22638
24296
|
displayName: "Headingstyled__HeadingText",
|
|
22639
24297
|
componentId: "sc-1a3jd28-0"
|
|
22640
24298
|
})(["--font-size:", ";font-size:var(--font-size);line-height:calc(1.5 * var(--font-size));color:", ";font-weight:", ";margin:", ";text-align:", ";font-family:", ";", ";"], function (_ref) {
|
|
@@ -22734,7 +24392,7 @@ var Jumbo = function Jumbo(_ref) {
|
|
|
22734
24392
|
showCartStatus = _ref$showCartStatus === void 0 ? false : _ref$showCartStatus,
|
|
22735
24393
|
openCartSlider = _ref.openCartSlider;
|
|
22736
24394
|
|
|
22737
|
-
var _useContext = React.useContext(
|
|
24395
|
+
var _useContext = React.useContext(ThemeContext),
|
|
22738
24396
|
isMobile = _useContext.isMobile;
|
|
22739
24397
|
|
|
22740
24398
|
return /*#__PURE__*/React__default.createElement(Box, {
|
|
@@ -22862,7 +24520,7 @@ var fallbackValues$o = {
|
|
|
22862
24520
|
color: color$8
|
|
22863
24521
|
};
|
|
22864
24522
|
|
|
22865
|
-
var SpinnerSvgAnimation =
|
|
24523
|
+
var SpinnerSvgAnimation = styled.svg.withConfig({
|
|
22866
24524
|
displayName: "Spinner__SpinnerSvgAnimation",
|
|
22867
24525
|
componentId: "sc-vhupl9-0"
|
|
22868
24526
|
})(["animation:rotate 2s linear infinite;margin:-25px 0 0 -25px;width:", "px;height:", "px;& .path{stroke:", ";stroke-linecap:round;animation:dash 1.5s ease-in-out infinite;}@keyframes rotate{100%{transform:rotate(360deg);}}@keyframes dash{0%{stroke-dasharray:1,150;stroke-dashoffset:0;}50%{stroke-dasharray:90,150;stroke-dashoffset:-35;}100%{stroke-dasharray:90,150;stroke-dashoffset:-124;}}"], function (_ref) {
|
|
@@ -22875,7 +24533,7 @@ var SpinnerSvgAnimation = qe.svg.withConfig({
|
|
|
22875
24533
|
var color = _ref3.color;
|
|
22876
24534
|
return color;
|
|
22877
24535
|
});
|
|
22878
|
-
var SpinnerContainer$2 =
|
|
24536
|
+
var SpinnerContainer$2 = styled.div.withConfig({
|
|
22879
24537
|
displayName: "Spinner__SpinnerContainer",
|
|
22880
24538
|
componentId: "sc-vhupl9-1"
|
|
22881
24539
|
})(["width:100%;display:flex;flex-direction:row;align-items:center;justify-content:center;line-height:1;"]);
|
|
@@ -23176,7 +24834,7 @@ var PlaceholderContentWrapper = function PlaceholderContentWrapper(_ref) {
|
|
|
23176
24834
|
dataQa = _ref.dataQa;
|
|
23177
24835
|
return isLink ? /*#__PURE__*/React__default.createElement(reactRouterDom.Link, {
|
|
23178
24836
|
to: destination,
|
|
23179
|
-
|
|
24837
|
+
"data-qa": dataQa
|
|
23180
24838
|
}, /*#__PURE__*/React__default.createElement(Box, {
|
|
23181
24839
|
padding: "0",
|
|
23182
24840
|
minHeight: "100%",
|
|
@@ -23298,7 +24956,7 @@ var fallbackValues$r = {
|
|
|
23298
24956
|
inactiveColor: inactiveColor
|
|
23299
24957
|
};
|
|
23300
24958
|
|
|
23301
|
-
var HiddenRadioButton =
|
|
24959
|
+
var HiddenRadioButton = styled.input.withConfig({
|
|
23302
24960
|
displayName: "RadioButton__HiddenRadioButton",
|
|
23303
24961
|
componentId: "sc-v6hie9-0"
|
|
23304
24962
|
})(["opacity:0;position:absolute;cursor:", ";"], function (_ref) {
|
|
@@ -34079,7 +35737,7 @@ var fallbackValues$u = {
|
|
|
34079
35737
|
leftLabelStyles: leftLabelStyles
|
|
34080
35738
|
};
|
|
34081
35739
|
|
|
34082
|
-
var HiddenToggleSwitchBox =
|
|
35740
|
+
var HiddenToggleSwitchBox = styled.input.withConfig({
|
|
34083
35741
|
displayName: "ToggleSwitch__HiddenToggleSwitchBox",
|
|
34084
35742
|
componentId: "sc-1t51u6v-0"
|
|
34085
35743
|
})(["opacity:0;position:absolute;cursor:", ";height:24px;width:50px;", ""], function (_ref) {
|
|
@@ -34089,7 +35747,7 @@ var HiddenToggleSwitchBox = qe.input.withConfig({
|
|
|
34089
35747
|
var isMobile = _ref2.isMobile;
|
|
34090
35748
|
return isMobile ? "transform: scale(0.75)" : "";
|
|
34091
35749
|
});
|
|
34092
|
-
var VisibleSwitchComponent =
|
|
35750
|
+
var VisibleSwitchComponent = styled.label.withConfig({
|
|
34093
35751
|
displayName: "ToggleSwitch__VisibleSwitchComponent",
|
|
34094
35752
|
componentId: "sc-1t51u6v-1"
|
|
34095
35753
|
})(["width:48px;height:24px;border-radius:48px;border:none;position:relative;box-sizing:border-box;cursor:", ";display:inline-block;&:hover{box-shadow:", ";}&:focus{box-shadow:0px 2px 5px 0px rgba(0,0,0,0.5);}", ""], function (_ref3) {
|
|
@@ -34102,11 +35760,11 @@ var VisibleSwitchComponent = qe.label.withConfig({
|
|
|
34102
35760
|
var isMobile = _ref5.isMobile;
|
|
34103
35761
|
return isMobile ? "transform: scale(0.75)" : "";
|
|
34104
35762
|
});
|
|
34105
|
-
var ToggleSwitchMiddleRingComponent =
|
|
35763
|
+
var ToggleSwitchMiddleRingComponent = styled.div.withConfig({
|
|
34106
35764
|
displayName: "ToggleSwitch__ToggleSwitchMiddleRingComponent",
|
|
34107
35765
|
componentId: "sc-1t51u6v-2"
|
|
34108
35766
|
})(["position:absolute;width:20px;height:20px;border:none;border-radius:50%;box-sizing:border-box;"]);
|
|
34109
|
-
var ToggleSwitchInnerRingComponent =
|
|
35767
|
+
var ToggleSwitchInnerRingComponent = styled.div.withConfig({
|
|
34110
35768
|
displayName: "ToggleSwitch__ToggleSwitchInnerRingComponent",
|
|
34111
35769
|
componentId: "sc-1t51u6v-3"
|
|
34112
35770
|
})(["position:absolute;width:14px;height:14px;top:3px;left:3px;right:3px;bottom:3px;border-radius:50%;box-sizing:border-box;"]);
|
|
@@ -34258,7 +35916,7 @@ var themeValues = {
|
|
|
34258
35916
|
focusBorder: focusBorder
|
|
34259
35917
|
};
|
|
34260
35918
|
|
|
34261
|
-
var TypeaheadInputWrapper =
|
|
35919
|
+
var TypeaheadInputWrapper = styled.div.withConfig({
|
|
34262
35920
|
displayName: "TypeaheadInput__TypeaheadInputWrapper",
|
|
34263
35921
|
componentId: "sc-cumjdb-0"
|
|
34264
35922
|
})(["display:flex;align-content:center;align-items:center;background:", ";input{border:0;height:72px;width:100%;padding:1.5rem;padding-left:1rem;min-width:100px;margin:0;box-sizing:border-box;position:relative;font-size:1.1rem;line-height:2rem;font-weight:400;background-color:", ";color:", ";box-shadow:none;border:1px solid transparent;&:focus{border:1px solid ", ";}}"], themeValues.background, themeValues.background, themeValues.black, themeValues.focusBorder);
|
|
@@ -34780,9 +36438,9 @@ function isDraft(value) {
|
|
|
34780
36438
|
}
|
|
34781
36439
|
function isDraftable(value) {
|
|
34782
36440
|
if (!value) { return false; }
|
|
34783
|
-
return isPlainObject(value) || !!value[DRAFTABLE] || !!value.constructor[DRAFTABLE];
|
|
36441
|
+
return isPlainObject$1(value) || !!value[DRAFTABLE] || !!value.constructor[DRAFTABLE];
|
|
34784
36442
|
}
|
|
34785
|
-
function isPlainObject(value) {
|
|
36443
|
+
function isPlainObject$1(value) {
|
|
34786
36444
|
if (!value || typeof value !== "object") { return false; }
|
|
34787
36445
|
if (Array.isArray(value)) { return true; }
|
|
34788
36446
|
var proto = Object.getPrototypeOf(value);
|
|
@@ -36522,7 +38180,7 @@ EditNameForm.reducer = reducer$2;
|
|
|
36522
38180
|
EditNameForm.mapStateToProps = mapStateToProps$3;
|
|
36523
38181
|
EditNameForm.mapDispatchToProps = mapDispatchToProps$2;
|
|
36524
38182
|
|
|
36525
|
-
var EditableListItem =
|
|
38183
|
+
var EditableListItem = styled.div.withConfig({
|
|
36526
38184
|
displayName: "EditableListstyled__EditableListItem",
|
|
36527
38185
|
componentId: "sc-10ehkz7-0"
|
|
36528
38186
|
})(["box-sizing:border-box;background:", ";border-color:", ";height:", ";display:flex;justify-content:space-between;align-items:center;padding:1.5rem;:not(:last-child),:not(:first-child){box-shadow:inset 0px -1px 0px 0px rgb(202,206,216);}:first-child{border-top-left-radius:3px;border-top-right-radius:3px;}:last-child{border-bottom-left-radius:3px;border-bottom-right-radius:3px;box-shadow:none;}"], function (_ref) {
|
|
@@ -36532,7 +38190,7 @@ var EditableListItem = qe.div.withConfig({
|
|
|
36532
38190
|
var listItemSize = _ref2.listItemSize;
|
|
36533
38191
|
return listItemSize === "big" ? "120px" : "72px";
|
|
36534
38192
|
});
|
|
36535
|
-
var EditableListItemControls =
|
|
38193
|
+
var EditableListItemControls = styled.div.withConfig({
|
|
36536
38194
|
displayName: "EditableListstyled__EditableListItemControls",
|
|
36537
38195
|
componentId: "sc-10ehkz7-1"
|
|
36538
38196
|
})(["display:flex;justify-content:space-evenly;align-items:center;"]);
|
|
@@ -36653,14 +38311,14 @@ var EditableList = function EditableList(_ref) {
|
|
|
36653
38311
|
}))));
|
|
36654
38312
|
};
|
|
36655
38313
|
|
|
36656
|
-
var EditableTableContainer =
|
|
38314
|
+
var EditableTableContainer = styled.div.withConfig({
|
|
36657
38315
|
displayName: "EditableTablestyled__EditableTableContainer",
|
|
36658
38316
|
componentId: "sc-fd3i2a-0"
|
|
36659
38317
|
})(["display:", ";flex-direction:column;flex:1;"], function (_ref) {
|
|
36660
38318
|
var hide = _ref.hide;
|
|
36661
38319
|
return hide ? "none" : "flex";
|
|
36662
38320
|
});
|
|
36663
|
-
var EditableTableListItem =
|
|
38321
|
+
var EditableTableListItem = styled.div.withConfig({
|
|
36664
38322
|
displayName: "EditableTablestyled__EditableTableListItem",
|
|
36665
38323
|
componentId: "sc-fd3i2a-1"
|
|
36666
38324
|
})(["width:100%;display:flex;", ";align-items:", ";flex-direction:", ";flex:1;", ";"], function (_ref2) {
|
|
@@ -36676,29 +38334,29 @@ var EditableTableListItem = qe.div.withConfig({
|
|
|
36676
38334
|
var isMobile = _ref5.isMobile;
|
|
36677
38335
|
return isMobile ? "padding: 1rem 0.5rem" : "padding: 0 0.5rem";
|
|
36678
38336
|
});
|
|
36679
|
-
var EditableListItemControls$1 =
|
|
38337
|
+
var EditableListItemControls$1 = styled.div.withConfig({
|
|
36680
38338
|
displayName: "EditableTablestyled__EditableListItemControls",
|
|
36681
38339
|
componentId: "sc-fd3i2a-2"
|
|
36682
38340
|
})(["display:flex;justify-content:space-evenly;align-items:center;"]);
|
|
36683
|
-
var EditableListAction =
|
|
38341
|
+
var EditableListAction = styled.div.withConfig({
|
|
36684
38342
|
displayName: "EditableTablestyled__EditableListAction",
|
|
36685
38343
|
componentId: "sc-fd3i2a-3"
|
|
36686
38344
|
})(["color:", ";align-items:center;font-size:1rem;padding-right:1rem;cursor:pointer;display:", ";"], MATISSE_BLUE, function (_ref6) {
|
|
36687
38345
|
var hide = _ref6.hide;
|
|
36688
38346
|
return hide ? "none" : "flex";
|
|
36689
38347
|
});
|
|
36690
|
-
var ItemWrapper =
|
|
38348
|
+
var ItemWrapper = styled.div.withConfig({
|
|
36691
38349
|
displayName: "EditableTablestyled__ItemWrapper",
|
|
36692
38350
|
componentId: "sc-fd3i2a-4"
|
|
36693
38351
|
})(["display:flex;flex-direction:row;flex:1;width:100%;border-bottom:1px solid ", ";"], GHOST_GREY);
|
|
36694
|
-
var ActionWrapper =
|
|
38352
|
+
var ActionWrapper = styled.div.withConfig({
|
|
36695
38353
|
displayName: "EditableTablestyled__ActionWrapper",
|
|
36696
38354
|
componentId: "sc-fd3i2a-5"
|
|
36697
38355
|
})(["display:flex;align-self:center;justify-content:flex-end;", ";flex:1;"], function (_ref7) {
|
|
36698
38356
|
var isMobile = _ref7.isMobile;
|
|
36699
38357
|
return isMobile && "display: none";
|
|
36700
38358
|
});
|
|
36701
|
-
var TableItemKey =
|
|
38359
|
+
var TableItemKey = styled.div.withConfig({
|
|
36702
38360
|
displayName: "EditableTablestyled__TableItemKey",
|
|
36703
38361
|
componentId: "sc-fd3i2a-6"
|
|
36704
38362
|
})(["display:flex;", ";", ";", ";font-size:", ";color:", ";"], function (_ref8) {
|
|
@@ -36714,7 +38372,7 @@ var TableItemKey = qe.div.withConfig({
|
|
|
36714
38372
|
var isMobile = _ref11.isMobile;
|
|
36715
38373
|
return isMobile ? "1rem" : "1.125rem";
|
|
36716
38374
|
}, STORM_GREY);
|
|
36717
|
-
var TableItemValue =
|
|
38375
|
+
var TableItemValue = styled.div.withConfig({
|
|
36718
38376
|
displayName: "EditableTablestyled__TableItemValue",
|
|
36719
38377
|
componentId: "sc-fd3i2a-7"
|
|
36720
38378
|
})(["display:flex;", ";", ";", ";font-size:", ";color:", ";"], function (_ref12) {
|
|
@@ -36730,7 +38388,7 @@ var TableItemValue = qe.div.withConfig({
|
|
|
36730
38388
|
var isMobile = _ref15.isMobile;
|
|
36731
38389
|
return isMobile ? "1.125rem" : "1.0625rem";
|
|
36732
38390
|
}, BRIGHT_GREY);
|
|
36733
|
-
var TableWrapper =
|
|
38391
|
+
var TableWrapper = styled.div.withConfig({
|
|
36734
38392
|
displayName: "EditableTablestyled__TableWrapper",
|
|
36735
38393
|
componentId: "sc-fd3i2a-8"
|
|
36736
38394
|
})(["display:flex;flex-direction:row;flex:1;width:100%;"]);
|
|
@@ -39934,7 +41592,7 @@ var Modal$1 = function Modal(_ref) {
|
|
|
39934
41592
|
buttonExtraStyles = _ref.buttonExtraStyles,
|
|
39935
41593
|
children = _ref.children;
|
|
39936
41594
|
|
|
39937
|
-
var _useContext = React.useContext(
|
|
41595
|
+
var _useContext = React.useContext(ThemeContext),
|
|
39938
41596
|
isMobile = _useContext.isMobile;
|
|
39939
41597
|
|
|
39940
41598
|
return /*#__PURE__*/React__default.createElement(React.Fragment, null, modalOpen && /*#__PURE__*/React__default.createElement(reactAriaModal, {
|
|
@@ -40232,7 +41890,7 @@ var menu = posed.div({
|
|
|
40232
41890
|
}
|
|
40233
41891
|
}
|
|
40234
41892
|
});
|
|
40235
|
-
var ImposterMenu =
|
|
41893
|
+
var ImposterMenu = styled(menu).withConfig({
|
|
40236
41894
|
displayName: "NavMenuMobile__ImposterMenu",
|
|
40237
41895
|
componentId: "sc-1pf0qp7-0"
|
|
40238
41896
|
})(["position:fixed;top:72px;"]);
|
|
@@ -40330,15 +41988,19 @@ var AutopayModal = function AutopayModal(_ref) {
|
|
|
40330
41988
|
modalOpen = _ref.modalOpen,
|
|
40331
41989
|
deactivatePaymentSchedule = _ref.deactivatePaymentSchedule,
|
|
40332
41990
|
navigateToSettings = _ref.navigateToSettings,
|
|
40333
|
-
|
|
41991
|
+
_ref$controlType = _ref.controlType,
|
|
41992
|
+
controlType = _ref$controlType === void 0 ? "tertiary" : _ref$controlType,
|
|
40334
41993
|
isMobile = _ref.isMobile,
|
|
40335
41994
|
themeValues = _ref.themeValues,
|
|
40336
41995
|
isPaymentPlan = _ref.isPaymentPlan,
|
|
40337
|
-
nextAutopayDate = _ref.nextAutopayDate
|
|
41996
|
+
nextAutopayDate = _ref.nextAutopayDate,
|
|
41997
|
+
dueDate = _ref.dueDate,
|
|
41998
|
+
inactive = _ref.inactive;
|
|
40338
41999
|
var planType = isPaymentPlan ? "Payment Plan" : "Autopay";
|
|
42000
|
+
var nextDate = dueDate || nextAutopayDate;
|
|
40339
42001
|
var modalExtraProps = {
|
|
40340
42002
|
modalHeaderText: autoPayActive ? "Deactivate ".concat(planType) : "Set Up ".concat(planType),
|
|
40341
|
-
modalBodyText: autoPayActive ? "Are you sure you want to deactivate ".concat(isPaymentPlan ? "your payment plan" : "autopay", "?
|
|
42003
|
+
modalBodyText: autoPayActive ? "Are you sure you want to deactivate ".concat(isPaymentPlan ? "your payment plan" : "autopay", "? ").concat(!inactive && nextDate ? "Your next payment will be due on ".concat(nextDate, ".") : "") : "To set up ".concat(isPaymentPlan ? "a payment plan" : "autopay", " you must save a payment method and address in your profile. Do you want to save these now?"),
|
|
40342
42004
|
continueButtonText: autoPayActive ? "Disable ".concat(planType) : "Add to Profile",
|
|
40343
42005
|
useDangerButton: autoPayActive,
|
|
40344
42006
|
continueAction: autoPayActive ? function () {
|
|
@@ -40349,6 +42011,67 @@ var AutopayModal = function AutopayModal(_ref) {
|
|
|
40349
42011
|
var hoverStyles = "\n &:hover {\n .autopayIcon { fill: ".concat(themeValues.hoverColor, "; text-decoration: underline; cursor: pointer; }\n }");
|
|
40350
42012
|
var activeStyles = "\n &:active {\n .autopayIcon { fill: ".concat(themeValues.activeColor, "; text-decoration: underline; }\n }");
|
|
40351
42013
|
var defaultStyles = "\n .autopayIcon { fill: ".concat(themeValues.color, "; text-decoration: underline; }\n ");
|
|
42014
|
+
|
|
42015
|
+
var renderAutoPayControl = function renderAutoPayControl() {
|
|
42016
|
+
switch (controlType) {
|
|
42017
|
+
case "secondary":
|
|
42018
|
+
{
|
|
42019
|
+
return /*#__PURE__*/React__default.createElement(ButtonWithAction, {
|
|
42020
|
+
text: autoPayActive ? "Turn off ".concat(planType) : "Set Up ".concat(planType),
|
|
42021
|
+
variant: "secondary",
|
|
42022
|
+
action: function action() {
|
|
42023
|
+
toggleModal(true);
|
|
42024
|
+
},
|
|
42025
|
+
dataQa: "Turn off Autopay",
|
|
42026
|
+
extraStyles: isMobile ? "flex-grow: 1; width: 100%; margin: 0;" : "flex-grow: 1; min-width: 165px;"
|
|
42027
|
+
});
|
|
42028
|
+
}
|
|
42029
|
+
|
|
42030
|
+
case "tertiary":
|
|
42031
|
+
{
|
|
42032
|
+
return /*#__PURE__*/React__default.createElement(ButtonWithAction, {
|
|
42033
|
+
text: autoPayActive ? "Manage ".concat(planType) : "Set Up ".concat(planType),
|
|
42034
|
+
variant: "tertiary",
|
|
42035
|
+
action: function action() {
|
|
42036
|
+
toggleModal(true);
|
|
42037
|
+
},
|
|
42038
|
+
dataQa: "Manage Autopay",
|
|
42039
|
+
extraStyles: isMobile && "flex-grow: 1; width: 100%;"
|
|
42040
|
+
});
|
|
42041
|
+
}
|
|
42042
|
+
|
|
42043
|
+
case "link":
|
|
42044
|
+
{
|
|
42045
|
+
return /*#__PURE__*/React__default.createElement(Box, {
|
|
42046
|
+
padding: "0",
|
|
42047
|
+
onClick: function onClick() {
|
|
42048
|
+
toggleModal(true);
|
|
42049
|
+
},
|
|
42050
|
+
hoverStyles: hoverStyles,
|
|
42051
|
+
activeStyles: activeStyles,
|
|
42052
|
+
extraStyles: defaultStyles
|
|
42053
|
+
}, /*#__PURE__*/React__default.createElement(Cluster, {
|
|
42054
|
+
justify: isMobile ? "flex-start" : "flex-end",
|
|
42055
|
+
align: "center"
|
|
42056
|
+
}, /*#__PURE__*/React__default.createElement(AutopayOnIcon, null), /*#__PURE__*/React__default.createElement(Text$1, {
|
|
42057
|
+
variant: "pS",
|
|
42058
|
+
onClick: function onClick() {
|
|
42059
|
+
return toggleModal(true);
|
|
42060
|
+
},
|
|
42061
|
+
onKeyPress: function onKeyPress(e) {
|
|
42062
|
+
e.key === "Enter" && toggleModal(true);
|
|
42063
|
+
},
|
|
42064
|
+
tabIndex: "0",
|
|
42065
|
+
dataQa: "".concat(planType, " On"),
|
|
42066
|
+
color: SEA_GREEN,
|
|
42067
|
+
weight: themeValues.fontWeight,
|
|
42068
|
+
hoverStyles: themeValues.modalLinkHoverFocus,
|
|
42069
|
+
extraStyles: "padding-left: 0.25rem;"
|
|
42070
|
+
}, "".concat(planType, " ").concat(nextAutopayDate))));
|
|
42071
|
+
}
|
|
42072
|
+
}
|
|
42073
|
+
};
|
|
42074
|
+
|
|
40352
42075
|
return /*#__PURE__*/React__default.createElement(Modal$1, _extends({
|
|
40353
42076
|
showModal: function showModal() {
|
|
40354
42077
|
return toggleModal(true);
|
|
@@ -40357,43 +42080,7 @@ var AutopayModal = function AutopayModal(_ref) {
|
|
|
40357
42080
|
return toggleModal(false);
|
|
40358
42081
|
},
|
|
40359
42082
|
modalOpen: modalOpen
|
|
40360
|
-
}, modalExtraProps),
|
|
40361
|
-
text: autoPayActive ? "Manage ".concat(planType) : "Set Up ".concat(planType),
|
|
40362
|
-
variant: "tertiary",
|
|
40363
|
-
action: function action() {
|
|
40364
|
-
toggleModal(true);
|
|
40365
|
-
},
|
|
40366
|
-
dataQa: "Manage Autopay",
|
|
40367
|
-
extraStyles: isMobile && "flex-grow: 1; width: 100%;"
|
|
40368
|
-
}) : /*#__PURE__*/React__default.createElement(Box, {
|
|
40369
|
-
padding: "0",
|
|
40370
|
-
onClick: function onClick() {
|
|
40371
|
-
toggleModal(true);
|
|
40372
|
-
},
|
|
40373
|
-
hoverStyles: hoverStyles,
|
|
40374
|
-
activeStyles: activeStyles,
|
|
40375
|
-
extraStyles: defaultStyles
|
|
40376
|
-
}, /*#__PURE__*/React__default.createElement(Cluster, {
|
|
40377
|
-
justify: isMobile ? "flex-start" : "flex-end",
|
|
40378
|
-
align: "center"
|
|
40379
|
-
}, /*#__PURE__*/React__default.createElement(AutopayOnIcon$1, null), /*#__PURE__*/React__default.createElement(Text$1, {
|
|
40380
|
-
variant: "pS",
|
|
40381
|
-
onClick: function onClick() {
|
|
40382
|
-
return toggleModal(true);
|
|
40383
|
-
},
|
|
40384
|
-
onKeyPress: function onKeyPress(e) {
|
|
40385
|
-
console.log({
|
|
40386
|
-
e: e
|
|
40387
|
-
});
|
|
40388
|
-
e.key === "Enter" && toggleModal(true);
|
|
40389
|
-
},
|
|
40390
|
-
tabIndex: "0",
|
|
40391
|
-
dataQa: "".concat(planType, " On"),
|
|
40392
|
-
color: SEA_GREEN,
|
|
40393
|
-
weight: themeValues.fontWeight,
|
|
40394
|
-
hoverStyles: themeValues.modalLinkHoverFocus,
|
|
40395
|
-
extraStyles: "padding-left: 0.25rem;"
|
|
40396
|
-
}, "".concat(planType, " ").concat(nextAutopayDate)))));
|
|
42083
|
+
}, modalExtraProps), renderAutoPayControl());
|
|
40397
42084
|
};
|
|
40398
42085
|
|
|
40399
42086
|
var AutopayModalModule = themeComponent(AutopayModal, "AutopayModal", fallbackValues$z);
|
|
@@ -40435,7 +42122,8 @@ var AmountModule = function AmountModule(_ref) {
|
|
|
40435
42122
|
isMobile: isMobile,
|
|
40436
42123
|
paymentPlanSchedule: paymentPlanSchedule,
|
|
40437
42124
|
isPaymentPlan: isPaymentPlan,
|
|
40438
|
-
nextAutopayDate: nextAutopayDate
|
|
42125
|
+
nextAutopayDate: nextAutopayDate,
|
|
42126
|
+
controlType: "link"
|
|
40439
42127
|
})));
|
|
40440
42128
|
};
|
|
40441
42129
|
|
|
@@ -40452,7 +42140,9 @@ var PaymentDetailsActions = function PaymentDetailsActions(_ref) {
|
|
|
40452
42140
|
autoPaySchedule = _ref.autoPaySchedule,
|
|
40453
42141
|
paymentPlanSchedule = _ref.paymentPlanSchedule,
|
|
40454
42142
|
isPaymentPlan = _ref.isPaymentPlan,
|
|
40455
|
-
nextAutopayDate = _ref.nextAutopayDate
|
|
42143
|
+
nextAutopayDate = _ref.nextAutopayDate,
|
|
42144
|
+
obligationAssocID = _ref.obligationAssocID,
|
|
42145
|
+
dueDate = _ref.dueDate;
|
|
40456
42146
|
var planType = isPaymentPlan ? "Payment Plan" : "Autopay";
|
|
40457
42147
|
|
|
40458
42148
|
var _useState = React.useState(false),
|
|
@@ -40477,7 +42167,7 @@ var PaymentDetailsActions = function PaymentDetailsActions(_ref) {
|
|
|
40477
42167
|
};
|
|
40478
42168
|
|
|
40479
42169
|
var handleDetailsClick = function handleDetailsClick() {
|
|
40480
|
-
setDetailedObligation(obligations, config);
|
|
42170
|
+
setDetailedObligation(obligations, config, obligationAssocID);
|
|
40481
42171
|
navigateToDetailedObligation(detailsSlug);
|
|
40482
42172
|
};
|
|
40483
42173
|
|
|
@@ -40543,14 +42233,14 @@ var PaymentDetailsActions = function PaymentDetailsActions(_ref) {
|
|
|
40543
42233
|
modalOpen: modalOpen,
|
|
40544
42234
|
navigateToSettings: navigateToSettings,
|
|
40545
42235
|
deactivatePaymentSchedule: deactivatePaymentSchedule,
|
|
40546
|
-
|
|
42236
|
+
controlType: "tertiary",
|
|
40547
42237
|
isMobile: isMobile,
|
|
40548
42238
|
paymentPlanSchedule: paymentPlanSchedule,
|
|
40549
42239
|
isPaymentPlan: isPaymentPlan,
|
|
40550
|
-
nextAutopayDate: nextAutopayDate
|
|
42240
|
+
nextAutopayDate: nextAutopayDate,
|
|
42241
|
+
dueDate: dueDate
|
|
40551
42242
|
})), !isMobile && /*#__PURE__*/React__default.createElement(Box, {
|
|
40552
|
-
padding:
|
|
40553
|
-
extraStyles: isMobile && "flex-grow: 1;"
|
|
42243
|
+
padding: "0"
|
|
40554
42244
|
}, /*#__PURE__*/React__default.createElement(ButtonWithAction, {
|
|
40555
42245
|
isLoading: isLoading,
|
|
40556
42246
|
action: function action() {
|
|
@@ -40558,8 +42248,7 @@ var PaymentDetailsActions = function PaymentDetailsActions(_ref) {
|
|
|
40558
42248
|
},
|
|
40559
42249
|
text: "Pay Now",
|
|
40560
42250
|
variant: isMobile ? "smallSecondary" : "secondary",
|
|
40561
|
-
dataQa: "Pay Now"
|
|
40562
|
-
extraStyles: isMobile && "flex-grow: 1; width: 100%;"
|
|
42251
|
+
dataQa: "Pay Now"
|
|
40563
42252
|
}))), isMobile && /*#__PURE__*/React__default.createElement(Box, {
|
|
40564
42253
|
padding: "8px 0 0",
|
|
40565
42254
|
width: "100%"
|
|
@@ -40571,10 +42260,61 @@ var PaymentDetailsActions = function PaymentDetailsActions(_ref) {
|
|
|
40571
42260
|
text: "Pay Now",
|
|
40572
42261
|
variant: isMobile ? "smallSecondary" : "secondary",
|
|
40573
42262
|
dataQa: "Pay Now",
|
|
40574
|
-
extraStyles: isMobile && "flex-grow: 1; width: 100%;"
|
|
42263
|
+
extraStyles: isMobile && "flex-grow: 1; width: 100%; margin: 0;"
|
|
40575
42264
|
}))));
|
|
40576
42265
|
};
|
|
40577
42266
|
|
|
42267
|
+
var RemoveAccountModalModule = function RemoveAccountModalModule(_ref) {
|
|
42268
|
+
var agencyName = _ref.agencyName,
|
|
42269
|
+
_ref$obligations = _ref.obligations,
|
|
42270
|
+
obligations = _ref$obligations === void 0 ? [] : _ref$obligations,
|
|
42271
|
+
removeAccount = _ref.removeAccount,
|
|
42272
|
+
accountType = _ref.accountType,
|
|
42273
|
+
isMobile = _ref.isMobile;
|
|
42274
|
+
|
|
42275
|
+
var _useState = React.useState(false),
|
|
42276
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
42277
|
+
modalIsOpen = _useState2[0],
|
|
42278
|
+
setModalIsOpen = _useState2[1];
|
|
42279
|
+
|
|
42280
|
+
var lastItem = _toConsumableArray(obligations).pop();
|
|
42281
|
+
|
|
42282
|
+
var accounts = obligations.length ? obligations.reduce(function (acc, curr) {
|
|
42283
|
+
var account = curr.details.description;
|
|
42284
|
+
var formattedAccount = curr !== lastItem ? "".concat(account, " and ") : "".concat(account);
|
|
42285
|
+
return formattedAccount === agencyName ? agencyName : acc + formattedAccount;
|
|
42286
|
+
}, "".concat(agencyName, " - ")) : "";
|
|
42287
|
+
var identifier = accountType === "Account" && obligations.length > 1 ? "accounts" : accountType === "Property" && obligations.length > 1 ? "properties" : accountType.toLowerCase();
|
|
42288
|
+
return /*#__PURE__*/React__default.createElement(Modal$1, {
|
|
42289
|
+
showModal: function showModal() {
|
|
42290
|
+
return setModalIsOpen(true);
|
|
42291
|
+
},
|
|
42292
|
+
hideModal: function hideModal() {
|
|
42293
|
+
return setModalIsOpen(false);
|
|
42294
|
+
},
|
|
42295
|
+
modalOpen: modalIsOpen,
|
|
42296
|
+
modalHeaderText: "Remove ".concat(accountType),
|
|
42297
|
+
modalBodyText: "Are you sure you want to remove the ".concat(identifier, " ").concat(accounts, " from your profile? Any autopay scheduled against ").concat(obligations.length > 1 ? "them" : "it", " will be deactivated."),
|
|
42298
|
+
continueButtonText: "Remove",
|
|
42299
|
+
continueAction: function continueAction() {
|
|
42300
|
+
removeAccount();
|
|
42301
|
+
setModalIsOpen(false);
|
|
42302
|
+
},
|
|
42303
|
+
useDangerButton: true
|
|
42304
|
+
}, /*#__PURE__*/React__default.createElement(Box, {
|
|
42305
|
+
padding: "0",
|
|
42306
|
+
extraStyles: "flex-grow: 1;"
|
|
42307
|
+
}, /*#__PURE__*/React__default.createElement(ButtonWithAction, {
|
|
42308
|
+
text: "Remove",
|
|
42309
|
+
variant: "secondary",
|
|
42310
|
+
action: function action() {
|
|
42311
|
+
return setModalIsOpen(true);
|
|
42312
|
+
},
|
|
42313
|
+
dataQa: "Remove Account",
|
|
42314
|
+
extraStyles: isMobile ? "flex-grow: 1; width: 100%; margin: 0;" : "flex-grow: 1;"
|
|
42315
|
+
})));
|
|
42316
|
+
};
|
|
42317
|
+
|
|
40578
42318
|
var InactiveControlsModule = function InactiveControlsModule(_ref) {
|
|
40579
42319
|
var autoPayEnabled = _ref.autoPayEnabled,
|
|
40580
42320
|
autoPaySchedule = _ref.autoPaySchedule,
|
|
@@ -40585,6 +42325,9 @@ var InactiveControlsModule = function InactiveControlsModule(_ref) {
|
|
|
40585
42325
|
isPaymentPlan = _ref.isPaymentPlan,
|
|
40586
42326
|
nextAutopayDate = _ref.nextAutopayDate,
|
|
40587
42327
|
obligationAssocID = _ref.obligationAssocID,
|
|
42328
|
+
dueDate = _ref.dueDate,
|
|
42329
|
+
agencyName = _ref.agencyName,
|
|
42330
|
+
configType = _ref.configType,
|
|
40588
42331
|
actions = _ref.actions;
|
|
40589
42332
|
|
|
40590
42333
|
var _useState = React.useState(false),
|
|
@@ -40592,10 +42335,10 @@ var InactiveControlsModule = function InactiveControlsModule(_ref) {
|
|
|
40592
42335
|
modalOpen = _useState2[0],
|
|
40593
42336
|
toggleModal = _useState2[1];
|
|
40594
42337
|
|
|
40595
|
-
var
|
|
42338
|
+
var deleteObligationAssoc = actions.deleteObligationAssoc;
|
|
40596
42339
|
|
|
40597
42340
|
var handleRemoveAccount = function handleRemoveAccount() {
|
|
40598
|
-
return
|
|
42341
|
+
return deleteObligationAssoc(obligationAssocID);
|
|
40599
42342
|
};
|
|
40600
42343
|
|
|
40601
42344
|
return /*#__PURE__*/React__default.createElement(Box, {
|
|
@@ -40603,7 +42346,10 @@ var InactiveControlsModule = function InactiveControlsModule(_ref) {
|
|
|
40603
42346
|
border: isMobile ? "1px solid ".concat(GHOST_GREY) : "0px",
|
|
40604
42347
|
borderWidthOverride: isMobile ? "1px 0 0 0" : "0px"
|
|
40605
42348
|
}, /*#__PURE__*/React__default.createElement(Cluster, {
|
|
40606
|
-
childGap:
|
|
42349
|
+
childGap: autoPayEnabled ? "8px" : "0",
|
|
42350
|
+
nowrap: true,
|
|
42351
|
+
justify: isMobile && autoPayEnabled && "center",
|
|
42352
|
+
align: isMobile && autoPayEnabled && "center"
|
|
40607
42353
|
}, autoPayEnabled && /*#__PURE__*/React__default.createElement(Box, {
|
|
40608
42354
|
padding: "0",
|
|
40609
42355
|
extraStyles: "flex-grow: 1;"
|
|
@@ -40614,21 +42360,22 @@ var InactiveControlsModule = function InactiveControlsModule(_ref) {
|
|
|
40614
42360
|
modalOpen: modalOpen,
|
|
40615
42361
|
navigateToSettings: navigateToSettings,
|
|
40616
42362
|
deactivatePaymentSchedule: deactivatePaymentSchedule,
|
|
40617
|
-
buttonLinkType: true,
|
|
40618
42363
|
isMobile: isMobile,
|
|
40619
42364
|
paymentPlanSchedule: paymentPlanSchedule,
|
|
40620
42365
|
isPaymentPlan: isPaymentPlan,
|
|
40621
42366
|
nextAutopayDate: nextAutopayDate,
|
|
40622
|
-
obligationAssocID: obligationAssocID
|
|
42367
|
+
obligationAssocID: obligationAssocID,
|
|
42368
|
+
dueDate: dueDate,
|
|
42369
|
+
controlType: "secondary",
|
|
42370
|
+
inactive: true
|
|
40623
42371
|
})), /*#__PURE__*/React__default.createElement(Box, {
|
|
40624
42372
|
padding: "0",
|
|
40625
42373
|
extraStyles: "flex-grow: 1;"
|
|
40626
|
-
}, /*#__PURE__*/React__default.createElement(
|
|
40627
|
-
|
|
40628
|
-
|
|
40629
|
-
|
|
40630
|
-
|
|
40631
|
-
extraStyles: isMobile && "flex-grow: 1; width: 100%;"
|
|
42374
|
+
}, /*#__PURE__*/React__default.createElement(RemoveAccountModalModule, {
|
|
42375
|
+
agencyName: agencyName,
|
|
42376
|
+
removeAccount: handleRemoveAccount,
|
|
42377
|
+
accountType: configType === "ACCOUNT" ? "Account" : "Property",
|
|
42378
|
+
isMobile: isMobile
|
|
40632
42379
|
}))));
|
|
40633
42380
|
};
|
|
40634
42381
|
|
|
@@ -40658,10 +42405,12 @@ var InactiveTitleModule = function InactiveTitleModule(_ref) {
|
|
|
40658
42405
|
variant: "extraSmall",
|
|
40659
42406
|
as: "p",
|
|
40660
42407
|
color: BLACK
|
|
40661
|
-
}, "This may mean that the
|
|
42408
|
+
}, "This may mean that the balance has been paid, or there was an error loading it.".concat(autoPayEnabled ? " You may disable autopay for this account by pressing the 'Turn off Autopay' button." : ""))));
|
|
40662
42409
|
};
|
|
40663
42410
|
|
|
40664
42411
|
var Obligation = function Obligation(_ref) {
|
|
42412
|
+
var _firstObligation$cust, _firstObligation$desc, _firstObligation$subD;
|
|
42413
|
+
|
|
40665
42414
|
var config = _ref.config,
|
|
40666
42415
|
obligations = _ref.obligations,
|
|
40667
42416
|
actions = _ref.actions,
|
|
@@ -40676,29 +42425,43 @@ var Obligation = function Obligation(_ref) {
|
|
|
40676
42425
|
isPaymentPlan = _ref.isPaymentPlan,
|
|
40677
42426
|
nextAutopayDate = _ref.nextAutopayDate,
|
|
40678
42427
|
obligationAssocID = _ref.obligationAssocID,
|
|
40679
|
-
|
|
40680
|
-
|
|
42428
|
+
dueDate = _ref.dueDate,
|
|
42429
|
+
agencyName = _ref.agencyName,
|
|
42430
|
+
_ref$inactive = _ref.inactive,
|
|
42431
|
+
inactive = _ref$inactive === void 0 ? false : _ref$inactive,
|
|
40681
42432
|
_ref$inactiveLookupTi = _ref.inactiveLookupTitle,
|
|
40682
42433
|
inactiveLookupTitle = _ref$inactiveLookupTi === void 0 ? "" : _ref$inactiveLookupTi,
|
|
40683
42434
|
_ref$inactiveLookupIn = _ref.inactiveLookupInput,
|
|
40684
42435
|
inactiveLookupInput = _ref$inactiveLookupIn === void 0 ? "Account" : _ref$inactiveLookupIn,
|
|
40685
42436
|
_ref$inactiveLookupVa = _ref.inactiveLookupValue,
|
|
40686
42437
|
inactiveLookupValue = _ref$inactiveLookupVa === void 0 ? "" : _ref$inactiveLookupVa;
|
|
40687
|
-
|
|
40688
|
-
|
|
40689
|
-
|
|
42438
|
+
|
|
42439
|
+
/*
|
|
42440
|
+
The value of obligations is always an array. It can contain:
|
|
42441
|
+
- A single obligation
|
|
42442
|
+
- A group of obligations (a "collection")
|
|
42443
|
+
|
|
42444
|
+
The top level desc/subdesc for all obligations in a collection is the same
|
|
42445
|
+
(Collection accounts look different in the Account Details page)
|
|
42446
|
+
*/
|
|
42447
|
+
var firstObligation = obligations[0];
|
|
42448
|
+
var customAttributes = (_firstObligation$cust = firstObligation === null || firstObligation === void 0 ? void 0 : firstObligation.customAttributes) !== null && _firstObligation$cust !== void 0 ? _firstObligation$cust : {};
|
|
42449
|
+
var boxShadowValue = "0px 2px 4px rgba(41, 42, 51, 0.1), 0px 1px 1px 2px rgba(41, 42, 51, 0.1);";
|
|
40690
42450
|
var activeObligation = /*#__PURE__*/React__default.createElement(Box, {
|
|
40691
42451
|
padding: "0",
|
|
40692
42452
|
borderRadius: "4px",
|
|
40693
42453
|
boxShadow: boxShadowValue,
|
|
40694
42454
|
as: "section",
|
|
40695
|
-
"aria-label": "".concat(
|
|
42455
|
+
"aria-label": "".concat((_firstObligation$desc = firstObligation === null || firstObligation === void 0 ? void 0 : firstObligation.description) !== null && _firstObligation$desc !== void 0 ? _firstObligation$desc : "account", " ").concat((_firstObligation$subD = firstObligation === null || firstObligation === void 0 ? void 0 : firstObligation.subDescription) !== null && _firstObligation$subD !== void 0 ? _firstObligation$subD : obligationAssocID),
|
|
42456
|
+
border: "1px solid ".concat(GRECIAN_GREY),
|
|
42457
|
+
borderWidthOverride: "1px 0 0 0"
|
|
40696
42458
|
}, /*#__PURE__*/React__default.createElement(Box, {
|
|
40697
|
-
background: WHITE
|
|
42459
|
+
background: WHITE,
|
|
42460
|
+
padding: isMobile ? "16px" : "24px 16px"
|
|
40698
42461
|
}, /*#__PURE__*/React__default.createElement(Stack, {
|
|
40699
42462
|
childGap: "14px"
|
|
40700
42463
|
}, /*#__PURE__*/React__default.createElement(Box, {
|
|
40701
|
-
key: "".concat(
|
|
42464
|
+
key: "".concat(firstObligation === null || firstObligation === void 0 ? void 0 : firstObligation.id, "-top"),
|
|
40702
42465
|
padding: "0 8px",
|
|
40703
42466
|
minWidth: "100%"
|
|
40704
42467
|
}, /*#__PURE__*/React__default.createElement(Cluster, {
|
|
@@ -40718,12 +42481,12 @@ var Obligation = function Obligation(_ref) {
|
|
|
40718
42481
|
iconValue: config.iconValue,
|
|
40719
42482
|
customAttributes: customAttributes
|
|
40720
42483
|
}), /*#__PURE__*/React__default.createElement(TitleModule, {
|
|
40721
|
-
title:
|
|
40722
|
-
subtitle:
|
|
42484
|
+
title: firstObligation === null || firstObligation === void 0 ? void 0 : firstObligation.description,
|
|
42485
|
+
subtitle: firstObligation === null || firstObligation === void 0 ? void 0 : firstObligation.subDescription,
|
|
40723
42486
|
titleColor: BRIGHT_GREY,
|
|
40724
42487
|
isMobile: isMobile
|
|
40725
42488
|
}))), !isMobile && /*#__PURE__*/React__default.createElement(AmountModule, {
|
|
40726
|
-
totalAmountDue: obligations.reduce(function (acc, curr) {
|
|
42489
|
+
totalAmountDue: obligations === null || obligations === void 0 ? void 0 : obligations.reduce(function (acc, curr) {
|
|
40727
42490
|
return acc + curr.amountDue;
|
|
40728
42491
|
}, 0),
|
|
40729
42492
|
autoPayEnabled: autoPayEnabled,
|
|
@@ -40747,7 +42510,8 @@ var Obligation = function Obligation(_ref) {
|
|
|
40747
42510
|
actions: actions,
|
|
40748
42511
|
isMobile: isMobile,
|
|
40749
42512
|
isPaymentPlan: isPaymentPlan,
|
|
40750
|
-
nextAutopayDate: nextAutopayDate
|
|
42513
|
+
nextAutopayDate: nextAutopayDate,
|
|
42514
|
+
obligationAssocID: obligationAssocID
|
|
40751
42515
|
}))), isMobile && /*#__PURE__*/React__default.createElement(PaymentDetailsActions, {
|
|
40752
42516
|
obligations: obligations,
|
|
40753
42517
|
autoPayEnabled: autoPayEnabled,
|
|
@@ -40761,7 +42525,8 @@ var Obligation = function Obligation(_ref) {
|
|
|
40761
42525
|
actions: actions,
|
|
40762
42526
|
isMobile: isMobile,
|
|
40763
42527
|
isPaymentPlan: isPaymentPlan,
|
|
40764
|
-
nextAutopayDate: nextAutopayDate
|
|
42528
|
+
nextAutopayDate: nextAutopayDate,
|
|
42529
|
+
obligationAssocID: obligationAssocID
|
|
40765
42530
|
}));
|
|
40766
42531
|
var inactiveObligation = /*#__PURE__*/React__default.createElement(Box, {
|
|
40767
42532
|
padding: "0",
|
|
@@ -40770,23 +42535,25 @@ var Obligation = function Obligation(_ref) {
|
|
|
40770
42535
|
as: "section",
|
|
40771
42536
|
"aria-label": "".concat(inactiveLookupTitle, " ").concat(inactiveLookupInput, ": ").concat(inactiveLookupValue)
|
|
40772
42537
|
}, /*#__PURE__*/React__default.createElement(Box, {
|
|
40773
|
-
background: ATHENS_GREY
|
|
42538
|
+
background: ATHENS_GREY,
|
|
42539
|
+
padding: isMobile ? "16px" : "24px"
|
|
40774
42540
|
}, /*#__PURE__*/React__default.createElement(Stack, {
|
|
40775
42541
|
childGap: "14px"
|
|
40776
42542
|
}, /*#__PURE__*/React__default.createElement(Box, {
|
|
40777
|
-
key: "".concat(
|
|
40778
|
-
padding: "0
|
|
42543
|
+
key: "".concat(obligationAssocID, "-top"),
|
|
42544
|
+
padding: "0",
|
|
40779
42545
|
minWidth: "100%"
|
|
40780
42546
|
}, /*#__PURE__*/React__default.createElement(Cluster, {
|
|
40781
42547
|
justify: "space-between",
|
|
40782
42548
|
align: "center",
|
|
40783
|
-
childGap: "
|
|
42549
|
+
childGap: "40px",
|
|
40784
42550
|
nowrap: true
|
|
40785
42551
|
}, /*#__PURE__*/React__default.createElement(Box, {
|
|
40786
42552
|
padding: "0"
|
|
40787
42553
|
}, /*#__PURE__*/React__default.createElement(Cluster, {
|
|
40788
42554
|
justify: "flex-start",
|
|
40789
|
-
align: "center"
|
|
42555
|
+
align: "center",
|
|
42556
|
+
nowrap: true
|
|
40790
42557
|
}, /*#__PURE__*/React__default.createElement(IconsModule, {
|
|
40791
42558
|
icon: config.icon,
|
|
40792
42559
|
iconDefault: config.iconDefault,
|
|
@@ -40809,7 +42576,10 @@ var Obligation = function Obligation(_ref) {
|
|
|
40809
42576
|
actions: actions,
|
|
40810
42577
|
isMobile: isMobile,
|
|
40811
42578
|
nextAutopayDate: nextAutopayDate,
|
|
40812
|
-
obligationAssocID: obligationAssocID
|
|
42579
|
+
obligationAssocID: obligationAssocID,
|
|
42580
|
+
dueDate: dueDate,
|
|
42581
|
+
agencyName: agencyName,
|
|
42582
|
+
configType: config.type
|
|
40813
42583
|
}))), isMobile && /*#__PURE__*/React__default.createElement(InactiveControlsModule, {
|
|
40814
42584
|
obligations: obligations,
|
|
40815
42585
|
autoPayEnabled: autoPayEnabled,
|
|
@@ -40820,9 +42590,12 @@ var Obligation = function Obligation(_ref) {
|
|
|
40820
42590
|
actions: actions,
|
|
40821
42591
|
isMobile: isMobile,
|
|
40822
42592
|
nextAutopayDate: nextAutopayDate,
|
|
40823
|
-
obligationAssocID: obligationAssocID
|
|
42593
|
+
obligationAssocID: obligationAssocID,
|
|
42594
|
+
dueDate: dueDate,
|
|
42595
|
+
agencyName: agencyName,
|
|
42596
|
+
configType: config.type
|
|
40824
42597
|
}))));
|
|
40825
|
-
return
|
|
42598
|
+
return inactive ? inactiveObligation : activeObligation;
|
|
40826
42599
|
};
|
|
40827
42600
|
|
|
40828
42601
|
var PartialAmountForm = function PartialAmountForm(_ref) {
|
|
@@ -41066,7 +42839,7 @@ var PaymentButtonBar = function PaymentButtonBar(_ref) {
|
|
|
41066
42839
|
_ref$hideForwardButto = _ref.hideForwardButton,
|
|
41067
42840
|
hideForwardButton = _ref$hideForwardButto === void 0 ? false : _ref$hideForwardButto;
|
|
41068
42841
|
|
|
41069
|
-
var _useContext = React.useContext(
|
|
42842
|
+
var _useContext = React.useContext(ThemeContext),
|
|
41070
42843
|
isMobile = _useContext.isMobile;
|
|
41071
42844
|
|
|
41072
42845
|
var backButton = !!cancelURL && !!cancelText ? /*#__PURE__*/React__default.createElement(ButtonWithLink, {
|
|
@@ -41594,7 +43367,7 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
41594
43367
|
walletCheckboxMarked = _ref.walletCheckboxMarked,
|
|
41595
43368
|
deniedCards = _ref.deniedCards;
|
|
41596
43369
|
|
|
41597
|
-
var _useContext = React.useContext(
|
|
43370
|
+
var _useContext = React.useContext(ThemeContext),
|
|
41598
43371
|
isMobile = _useContext.isMobile;
|
|
41599
43372
|
|
|
41600
43373
|
React.useEffect(function () {
|
|
@@ -41917,7 +43690,7 @@ var RadioSection = function RadioSection(_ref) {
|
|
|
41917
43690
|
}
|
|
41918
43691
|
};
|
|
41919
43692
|
var borderStyles = "\n border-width: 0 0 1px 0;\n border-color: ".concat(themeValues.borderColor, ";\n border-style: solid;\n border-radius: 0px;\n transform-origin: 100% 0;\n\n &:last-child {\n border-width: 0;\n }\n ");
|
|
41920
|
-
var RightIcon =
|
|
43693
|
+
var RightIcon = styled.img.withConfig({
|
|
41921
43694
|
displayName: "RadioSection__RightIcon",
|
|
41922
43695
|
componentId: "sc-uema02-0"
|
|
41923
43696
|
})(["height:", ";width:", ";", " transition:opacity 0.3s ease;"], function (_ref2) {
|
|
@@ -42148,7 +43921,7 @@ RegistrationForm.mapStateToProps = mapStateToProps$b;
|
|
|
42148
43921
|
RegistrationForm.mapDispatchToProps = mapDispatchToProps$a;
|
|
42149
43922
|
|
|
42150
43923
|
var ResetConfirmationForm = function ResetConfirmationForm() {
|
|
42151
|
-
var _useContext = React.useContext(
|
|
43924
|
+
var _useContext = React.useContext(ThemeContext),
|
|
42152
43925
|
isMobile = _useContext.isMobile;
|
|
42153
43926
|
|
|
42154
43927
|
return /*#__PURE__*/React__default.createElement(Box, {
|
|
@@ -42269,7 +44042,7 @@ ResetPasswordForm.mapStateToProps = mapStateToProps$c;
|
|
|
42269
44042
|
ResetPasswordForm.mapDispatchToProps = mapDispatchToProps$b;
|
|
42270
44043
|
|
|
42271
44044
|
var ResetConfirmationForm$2 = function ResetConfirmationForm() {
|
|
42272
|
-
var _useContext = React.useContext(
|
|
44045
|
+
var _useContext = React.useContext(ThemeContext),
|
|
42273
44046
|
isMobile = _useContext.isMobile;
|
|
42274
44047
|
|
|
42275
44048
|
return /*#__PURE__*/React__default.createElement(Box, {
|
|
@@ -42416,7 +44189,7 @@ var TabSidebar = function TabSidebar(_ref) {
|
|
|
42416
44189
|
themeValues = _ref.themeValues;
|
|
42417
44190
|
return /*#__PURE__*/React__default.createElement(Box, {
|
|
42418
44191
|
padding: "0",
|
|
42419
|
-
background:
|
|
44192
|
+
background: COOL_GREY_05,
|
|
42420
44193
|
minHeight: "100%",
|
|
42421
44194
|
role: "region",
|
|
42422
44195
|
"aria-label": "Profile tabs",
|
|
@@ -42588,7 +44361,7 @@ var TermsAndConditions = function TermsAndConditions(_ref) {
|
|
|
42588
44361
|
var Timeout = function Timeout(_ref) {
|
|
42589
44362
|
var onLogout = _ref.onLogout;
|
|
42590
44363
|
|
|
42591
|
-
var _useContext = React.useContext(
|
|
44364
|
+
var _useContext = React.useContext(ThemeContext),
|
|
42592
44365
|
isMobile = _useContext.isMobile;
|
|
42593
44366
|
|
|
42594
44367
|
return /*#__PURE__*/React__default.createElement(Cover, null, /*#__PURE__*/React__default.createElement(Center, {
|
|
@@ -42635,7 +44408,7 @@ var fallbackValues$G = {
|
|
|
42635
44408
|
imageBackgroundColor: imageBackgroundColor
|
|
42636
44409
|
};
|
|
42637
44410
|
|
|
42638
|
-
var WelcomeImage =
|
|
44411
|
+
var WelcomeImage = styled.img.withConfig({
|
|
42639
44412
|
displayName: "WelcomeModule__WelcomeImage",
|
|
42640
44413
|
componentId: "sc-1d9znh4-0"
|
|
42641
44414
|
})(["width:auto;height:215px;"]);
|
|
@@ -42718,11 +44491,12 @@ var WorkflowTile = function WorkflowTile(_ref) {
|
|
|
42718
44491
|
minWidth: "100%",
|
|
42719
44492
|
url: "/service/".concat(slug),
|
|
42720
44493
|
extraStyles: "width: 100%;",
|
|
42721
|
-
linkExtraStyles: "justify-content: center;"
|
|
44494
|
+
linkExtraStyles: "justify-content: center;",
|
|
44495
|
+
dataQa: slug
|
|
42722
44496
|
}))));
|
|
42723
44497
|
};
|
|
42724
44498
|
|
|
42725
|
-
var DashboardIframe =
|
|
44499
|
+
var DashboardIframe = styled.iframe.withConfig({
|
|
42726
44500
|
displayName: "PeriscopeDashboardIframestyled__DashboardIframe",
|
|
42727
44501
|
componentId: "sc-j0cucj-0"
|
|
42728
44502
|
})(["border:none;box-shadow:0 0 5px 0 ", ";display:none;"], ALTO_GREY);
|
|
@@ -42835,7 +44609,7 @@ var PeriscopeDashboardIframe = function PeriscopeDashboardIframe(_ref) {
|
|
|
42835
44609
|
}, "Your organization may not have a dashboard configured."))), !periscopeDataFailure && url && Dashboard(height)(url)));
|
|
42836
44610
|
};
|
|
42837
44611
|
|
|
42838
|
-
var pageBackground = "#
|
|
44612
|
+
var pageBackground = "#FBFCFD";
|
|
42839
44613
|
var fallbackValues$H = {
|
|
42840
44614
|
pageBackground: pageBackground
|
|
42841
44615
|
};
|
|
@@ -42854,12 +44628,12 @@ var CenterSingle = function CenterSingle(_ref) {
|
|
|
42854
44628
|
centeredMobileContent = _ref$centeredMobileCo === void 0 ? false : _ref$centeredMobileCo,
|
|
42855
44629
|
content = _ref.content,
|
|
42856
44630
|
themeValues = _ref.themeValues;
|
|
42857
|
-
var themeContext = React.useContext(
|
|
44631
|
+
var themeContext = React.useContext(ThemeContext);
|
|
42858
44632
|
var isMobile = themeContext.isMobile;
|
|
42859
44633
|
return /*#__PURE__*/React__default.createElement(Box, {
|
|
42860
44634
|
padding: "0",
|
|
42861
44635
|
minWidth: "100%",
|
|
42862
|
-
background:
|
|
44636
|
+
background: COOL_GREY_05,
|
|
42863
44637
|
extraStyles: "flex-grow: 1;"
|
|
42864
44638
|
}, /*#__PURE__*/React__default.createElement(Cover, {
|
|
42865
44639
|
centerOverride: isMobile && !centeredMobileContent
|
|
@@ -42899,12 +44673,12 @@ var CenterStack = function CenterStack(_ref) {
|
|
|
42899
44673
|
fullWidthMobile = _ref$fullWidthMobile === void 0 ? true : _ref$fullWidthMobile,
|
|
42900
44674
|
content = _ref.content,
|
|
42901
44675
|
themeValues = _ref.themeValues;
|
|
42902
|
-
var themeContext = React.useContext(
|
|
44676
|
+
var themeContext = React.useContext(ThemeContext);
|
|
42903
44677
|
var isMobile = themeContext.isMobile;
|
|
42904
44678
|
return /*#__PURE__*/React__default.createElement(Box, {
|
|
42905
44679
|
padding: "0",
|
|
42906
44680
|
minWidth: "100%",
|
|
42907
|
-
background:
|
|
44681
|
+
background: COOL_GREY_05,
|
|
42908
44682
|
extraStyles: "flex-grow: 1;"
|
|
42909
44683
|
}, /*#__PURE__*/React__default.createElement(Cover, null, header ? header : /*#__PURE__*/React__default.createElement(Box, {
|
|
42910
44684
|
padding: "0"
|
|
@@ -42939,12 +44713,12 @@ var CenterSingle$2 = function CenterSingle(_ref) {
|
|
|
42939
44713
|
maxWidth = _ref$maxWidth === void 0 ? "75rem" : _ref$maxWidth,
|
|
42940
44714
|
_ref$gutters = _ref.gutters,
|
|
42941
44715
|
gutters = _ref$gutters === void 0 ? "2rem" : _ref$gutters;
|
|
42942
|
-
var themeContext = React.useContext(
|
|
44716
|
+
var themeContext = React.useContext(ThemeContext);
|
|
42943
44717
|
var isMobile = themeContext.isMobile;
|
|
42944
44718
|
return /*#__PURE__*/React__default.createElement(Box, {
|
|
42945
44719
|
padding: "0",
|
|
42946
44720
|
minWidth: "100%",
|
|
42947
|
-
background:
|
|
44721
|
+
background: COOL_GREY_05,
|
|
42948
44722
|
extraStyles: "flex-grow: 1;"
|
|
42949
44723
|
}, /*#__PURE__*/React__default.createElement(Cover, {
|
|
42950
44724
|
childGap: "0",
|
|
@@ -42990,12 +44764,12 @@ var SidebarSingleContent = function SidebarSingleContent(_ref) {
|
|
|
42990
44764
|
_ref$sidebarVerticalC = _ref.sidebarVerticalCenter,
|
|
42991
44765
|
sidebarVerticalCenter = _ref$sidebarVerticalC === void 0 ? false : _ref$sidebarVerticalC,
|
|
42992
44766
|
themeValues = _ref.themeValues;
|
|
42993
|
-
var themeContext = React.useContext(
|
|
44767
|
+
var themeContext = React.useContext(ThemeContext);
|
|
42994
44768
|
var isMobile = themeContext.isMobile;
|
|
42995
44769
|
return /*#__PURE__*/React__default.createElement(Box, {
|
|
42996
44770
|
padding: "0",
|
|
42997
44771
|
minWidth: "100%",
|
|
42998
|
-
background:
|
|
44772
|
+
background: COOL_GREY_05,
|
|
42999
44773
|
extraStyles: "flex-grow: 1;"
|
|
43000
44774
|
}, /*#__PURE__*/React__default.createElement(Cover, {
|
|
43001
44775
|
centerOverride: !sidebarVerticalCenter
|
|
@@ -43046,12 +44820,12 @@ var SidebarStackContent = function SidebarStackContent(_ref) {
|
|
|
43046
44820
|
_ref$sidebarVerticalC = _ref.sidebarVerticalCenter,
|
|
43047
44821
|
sidebarVerticalCenter = _ref$sidebarVerticalC === void 0 ? false : _ref$sidebarVerticalC,
|
|
43048
44822
|
themeValues = _ref.themeValues;
|
|
43049
|
-
var themeContext = React.useContext(
|
|
44823
|
+
var themeContext = React.useContext(ThemeContext);
|
|
43050
44824
|
var isMobile = themeContext.isMobile;
|
|
43051
44825
|
return /*#__PURE__*/React__default.createElement(Box, {
|
|
43052
44826
|
padding: "0",
|
|
43053
44827
|
minWidth: "100%",
|
|
43054
|
-
background:
|
|
44828
|
+
background: COOL_GREY_05,
|
|
43055
44829
|
key: "page-bg",
|
|
43056
44830
|
extraStyles: "flex-grow: 1;"
|
|
43057
44831
|
}, /*#__PURE__*/React__default.createElement(Cover, {
|
|
@@ -43119,7 +44893,7 @@ exports.AddressForm = AddressForm;
|
|
|
43119
44893
|
exports.Alert = Alert$1;
|
|
43120
44894
|
exports.AllocatedIcon = AllocatedIcon;
|
|
43121
44895
|
exports.AmountCallout = AmountCallout$1;
|
|
43122
|
-
exports.AutopayOnIcon = AutopayOnIcon
|
|
44896
|
+
exports.AutopayOnIcon = AutopayOnIcon;
|
|
43123
44897
|
exports.BankIcon = BankIcon;
|
|
43124
44898
|
exports.Box = Box;
|
|
43125
44899
|
exports.BoxWithShadow = BoxWithShadow$1;
|