fis-component 0.0.25 → 0.0.26
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/cjs/index.js +2144 -114
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/index.js +2143 -113
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +2 -1
- package/package.json +1 -1
package/dist/cjs/index.js
CHANGED
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
var jsxRuntime = require('react/jsx-runtime');
|
|
4
4
|
var React = require('react');
|
|
5
5
|
var ReactDOM = require('react-dom');
|
|
6
|
-
var reactPopper = require('react-popper');
|
|
7
6
|
|
|
8
7
|
function _interopNamespaceDefault(e) {
|
|
9
8
|
var n = Object.create(null);
|
|
@@ -128,7 +127,7 @@ var assign = Object.assign;
|
|
|
128
127
|
* @param {number} length
|
|
129
128
|
* @return {number}
|
|
130
129
|
*/
|
|
131
|
-
function hash (value, length) {
|
|
130
|
+
function hash$2 (value, length) {
|
|
132
131
|
return charat$1(value, 0) ^ 45 ? (((((((length << 2) ^ charat$1(value, 0)) << 2) ^ charat$1(value, 1)) << 2) ^ charat$1(value, 2)) << 2) ^ charat$1(value, 3) : 0
|
|
133
132
|
}
|
|
134
133
|
|
|
@@ -660,7 +659,7 @@ function declaration$1 (value, root, parent, length, siblings) {
|
|
|
660
659
|
* @return {string}
|
|
661
660
|
*/
|
|
662
661
|
function prefix (value, length, children) {
|
|
663
|
-
switch (hash(value, length)) {
|
|
662
|
+
switch (hash$2(value, length)) {
|
|
664
663
|
// color-adjust
|
|
665
664
|
case 5103:
|
|
666
665
|
return WEBKIT + 'print-' + value + value
|
|
@@ -947,7 +946,7 @@ var unitlessKeys$1 = {
|
|
|
947
946
|
strokeWidth: 1
|
|
948
947
|
};
|
|
949
948
|
|
|
950
|
-
var f="undefined"!=typeof process&&void 0!==process.env&&(process.env.REACT_APP_SC_ATTR||process.env.SC_ATTR)||"data-styled",m="active",y="data-styled-version",v="6.1.15",g="/*!sc*/\n",S="undefined"!=typeof window&&"HTMLElement"in window,w=Boolean("boolean"==typeof SC_DISABLE_SPEEDY?SC_DISABLE_SPEEDY:"undefined"!=typeof process&&void 0!==process.env&&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&&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),E=/invalid hook call/i,N=new Set,P=function(t,n){if("production"!==process.env.NODE_ENV){var r=n?' with the id of "'.concat(n,'"'):"",s="The component ".concat(t).concat(r," has been created dynamically.\n")+"You 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.",i=console.error;try{var a=!0;console.error=function(t){for(var n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];E.test(t)?(a=!1,N.delete(s)):i.apply(void 0,__spreadArray([t],n,!1));},React.useRef(),a&&!N.has(s)&&(console.warn(s),N.add(s));}catch(e){E.test(e.message)&&N.delete(s);}finally{console.error=i;}}},_=Object.freeze([]),C=Object.freeze({});function I(e,t,n){return void 0===n&&(n=C),e.theme!==n.theme&&e.theme||t||n.theme}var A=new Set(["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","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","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","tr","track","u","ul","use","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"]),O=/[!"#$%&'()*+,./:;<=>?@[\\\]^`{|}~-]+/g,D=/(^-|-$)/g;function R(e){return e.replace(O,"-").replace(D,"")}var T=/(a)(d)/gi,k=52,j=function(e){return String.fromCharCode(e+(e>25?39:97))};function x(e){var t,n="";for(t=Math.abs(e);t>k;t=t/k|0)n=j(t%k)+n;return (j(t%k)+n).replace(T,"$1-$2")}var V,F=5381,M=function(e,t){for(var n=t.length;n;)e=33*e^t.charCodeAt(--n);return e},z=function(e){return M(F,e)};function $(e){return x(z(e)>>>0)}function B(e){return "production"!==process.env.NODE_ENV&&"string"==typeof e&&e||e.displayName||e.name||"Component"}function L(e){return "string"==typeof e&&("production"===process.env.NODE_ENV||e.charAt(0)===e.charAt(0).toLowerCase())}var G="function"==typeof Symbol&&Symbol.for,Y=G?Symbol.for("react.memo"):60115,q=G?Symbol.for("react.forward_ref"):60112,W={childContextTypes:true,contextType:true,contextTypes:true,defaultProps:true,displayName:true,getDefaultProps:true,getDerivedStateFromError:true,getDerivedStateFromProps:true,mixins:true,propTypes:true,type:true},H={name:true,length:true,prototype:true,caller:true,callee:true,arguments:true,arity:true},U={$$typeof:true,compare:true,defaultProps:true,displayName:true,propTypes:true,type:true},J=((V={})[q]={$$typeof:true,render:true,defaultProps:true,displayName:true,propTypes:true},V[Y]=U,V);function X(e){return ("type"in(t=e)&&t.type.$$typeof)===Y?U:"$$typeof"in e?J[e.$$typeof]:W;var t;}var Z=Object.defineProperty,K=Object.getOwnPropertyNames,Q=Object.getOwnPropertySymbols,ee=Object.getOwnPropertyDescriptor,te=Object.getPrototypeOf,ne=Object.prototype;function re(e,t,n){if("string"!=typeof t){if(ne){var r=te(t);r&&r!==ne&&re(e,r,n);}var o=K(t);Q&&(o=o.concat(Q(t)));for(var s=X(e),i=X(t),a=0;a<o.length;++a){var c=o[a];if(!(c in H||n&&n[c]||i&&c in i||s&&c in s)){var l=ee(t,c);try{Z(e,c,l);}catch(e){}}}}return e}function oe(e){return "function"==typeof e}function se(e){return "object"==typeof e&&"styledComponentId"in e}function ie(e,t){return e&&t?"".concat(e," ").concat(t):e||t||""}function ae(e,t){if(0===e.length)return "";for(var n=e[0],r=1;r<e.length;r++)n+=e[r];return n}function ce(e){return null!==e&&"object"==typeof e&&e.constructor.name===Object.name&&!("props"in e&&e.$$typeof)}function le(e,t,n){if(void 0===n&&(n=false),!n&&!ce(e)&&!Array.isArray(e))return t;if(Array.isArray(t))for(var r=0;r<t.length;r++)e[r]=le(e[r],t[r]);else if(ce(t))for(var r in t)e[r]=le(e[r],t[r]);return e}function ue(e,t){Object.defineProperty(e,"toString",{value:t});}var pe="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",18:"ThemeProvider: Please make sure your useTheme hook is within a `<ThemeProvider>`"}:{};function de(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n=e[0],r=[],o=1,s=e.length;o<s;o+=1)r.push(e[o]);return r.forEach(function(e){n=n.replace(/%[a-z]/,e);}),n}function he(t){for(var n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];return "production"===process.env.NODE_ENV?new Error("An error occurred. See https://github.com/styled-components/styled-components/blob/main/packages/styled-components/src/utils/errors.md#".concat(t," for more information.").concat(n.length>0?" Args: ".concat(n.join(", ")):"")):new Error(de.apply(void 0,__spreadArray([pe[t]],n,false)).trim())}var fe=function(){function e(e){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=e;}return e.prototype.indexOfGroup=function(e){for(var t=0,n=0;n<e;n++)t+=this.groupSizes[n];return t},e.prototype.insertRules=function(e,t){if(e>=this.groupSizes.length){for(var n=this.groupSizes,r=n.length,o=r;e>=o;)if((o<<=1)<0)throw he(16,"".concat(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=(s=0,t.length);s<a;s++)this.tag.insertRule(i,t[s])&&(this.groupSizes[e]++,i++);},e.prototype.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);}},e.prototype.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+="".concat(this.tag.getRule(s)).concat(g);return t},e}(),me=1<<30,ye=new Map,ve=new Map,ge=1,Se=function(e){if(ye.has(e))return ye.get(e);for(;ve.has(ge);)ge++;var t=ge++;if("production"!==process.env.NODE_ENV&&((0|t)<0||t>me))throw he(16,"".concat(t));return ye.set(e,t),ve.set(t,e),t},we=function(e,t){ge=t+1,ye.set(e,t),ve.set(t,e);},be="style[".concat(f,"][").concat(y,'="').concat(v,'"]'),Ee=new RegExp("^".concat(f,'\\.g(\\d+)\\[id="([\\w\\d-]+)"\\].*?"([^"]*)')),Ne=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);},Pe=function(e,t){for(var n,r=(null!==(n=t.textContent)&&void 0!==n?n:"").split(g),o=[],s=0,i=r.length;s<i;s++){var a=r[s].trim();if(a){var c=a.match(Ee);if(c){var l=0|parseInt(c[1],10),u=c[2];0!==l&&(we(u,l),Ne(e,u,c[3]),e.getTag().insertRules(l,o)),o.length=0;}else o.push(a);}}},_e=function(e){for(var t=document.querySelectorAll(be),n=0,r=t.length;n<r;n++){var o=t[n];o&&o.getAttribute(f)!==m&&(Pe(e,o),o.parentNode&&o.parentNode.removeChild(o));}};function Ce(){return "undefined"!=typeof __webpack_nonce__?__webpack_nonce__:null}var Ie=function(e){var t=document.head,n=e||t,r=document.createElement("style"),o=function(e){var t=Array.from(e.querySelectorAll("style[".concat(f,"]")));return t[t.length-1]}(n),s=void 0!==o?o.nextSibling:null;r.setAttribute(f,m),r.setAttribute(y,v);var i=Ce();return i&&r.setAttribute("nonce",i),n.insertBefore(r,s),r},Ae=function(){function e(e){this.element=Ie(e),this.element.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}throw he(17)}(this.element),this.length=0;}return e.prototype.insertRule=function(e,t){try{return this.sheet.insertRule(t,e),this.length++,!0}catch(e){return false}},e.prototype.deleteRule=function(e){this.sheet.deleteRule(e),this.length--;},e.prototype.getRule=function(e){var t=this.sheet.cssRules[e];return t&&t.cssText?t.cssText:""},e}(),Oe=function(){function e(e){this.element=Ie(e),this.nodes=this.element.childNodes,this.length=0;}return e.prototype.insertRule=function(e,t){if(e<=this.length&&e>=0){var n=document.createTextNode(t);return this.element.insertBefore(n,this.nodes[e]||null),this.length++,true}return false},e.prototype.deleteRule=function(e){this.element.removeChild(this.nodes[e]),this.length--;},e.prototype.getRule=function(e){return e<this.length?this.nodes[e].textContent:""},e}(),De=function(){function e(e){this.rules=[],this.length=0;}return e.prototype.insertRule=function(e,t){return e<=this.length&&(this.rules.splice(e,0,t),this.length++,true)},e.prototype.deleteRule=function(e){this.rules.splice(e,1),this.length--;},e.prototype.getRule=function(e){return e<this.length?this.rules[e]:""},e}(),Re=S,Te={isServer:!S,useCSSOMInjection:!w},ke=function(){function e(e,n,r){ void 0===e&&(e=C),void 0===n&&(n={});var o=this;this.options=__assign(__assign({},Te),e),this.gs=n,this.names=new Map(r),this.server=!!e.isServer,!this.server&&S&&Re&&(Re=false,_e(this)),ue(this,function(){return function(e){for(var t=e.getTag(),n=t.length,r="",o=function(n){var o=function(e){return ve.get(e)}(n);if(void 0===o)return "continue";var s=e.names.get(o),i=t.getGroup(n);if(void 0===s||!s.size||0===i.length)return "continue";var a="".concat(f,".g").concat(n,'[id="').concat(o,'"]'),c="";void 0!==s&&s.forEach(function(e){e.length>0&&(c+="".concat(e,","));}),r+="".concat(i).concat(a,'{content:"').concat(c,'"}').concat(g);},s=0;s<n;s++)o(s);return r}(o)});}return e.registerId=function(e){return Se(e)},e.prototype.rehydrate=function(){!this.server&&S&&_e(this);},e.prototype.reconstructWithOptions=function(n,r){return void 0===r&&(r=true),new e(__assign(__assign({},this.options),n),this.gs,r&&this.names||void 0)},e.prototype.allocateGSInstance=function(e){return this.gs[e]=(this.gs[e]||0)+1},e.prototype.getTag=function(){return this.tag||(this.tag=(e=function(e){var t=e.useCSSOMInjection,n=e.target;return e.isServer?new De(n):t?new Ae(n):new Oe(n)}(this.options),new fe(e)));var e;},e.prototype.hasNameForId=function(e,t){return this.names.has(e)&&this.names.get(e).has(t)},e.prototype.registerName=function(e,t){if(Se(e),this.names.has(e))this.names.get(e).add(t);else {var n=new Set;n.add(t),this.names.set(e,n);}},e.prototype.insertRules=function(e,t,n){this.registerName(e,t),this.getTag().insertRules(Se(e),n);},e.prototype.clearNames=function(e){this.names.has(e)&&this.names.get(e).clear();},e.prototype.clearRules=function(e){this.getTag().clearGroup(Se(e)),this.clearNames(e);},e.prototype.clearTag=function(){this.tag=void 0;},e}(),je=/&/g,xe=/^\s*\/\/.*$/gm;function Ve(e,t){return e.map(function(e){return "rule"===e.type&&(e.value="".concat(t," ").concat(e.value),e.value=e.value.replaceAll(",",",".concat(t," ")),e.props=e.props.map(function(e){return "".concat(t," ").concat(e)})),Array.isArray(e.children)&&"@keyframes"!==e.type&&(e.children=Ve(e.children,t)),e})}function Fe(e){var t,n,r,o=C,s=o.options,i=void 0===s?C:s,a=o.plugins,c=void 0===a?_:a,l=function(e,r,o){return o.startsWith(n)&&o.endsWith(n)&&o.replaceAll(n,"").length>0?".".concat(t):e},u=c.slice();u.push(function(e){e.type===RULESET$1&&e.value.includes("&")&&(e.props[0]=e.props[0].replace(je,n).replace(r,l));}),i.prefix&&u.push(prefixer),u.push(stringify$2);var p=function(e,o,s,a){ void 0===o&&(o=""),void 0===s&&(s=""),void 0===a&&(a="&"),t=a,n=o,r=new RegExp("\\".concat(n,"\\b"),"g");var c=e.replace(xe,""),l=compile$1(s||o?"".concat(s," ").concat(o," { ").concat(c," }"):c);i.namespace&&(l=Ve(l,i.namespace));var p=[];return serialize$1(l,middleware(u.concat(rulesheet(function(e){return p.push(e)})))),p};return p.hash=c.length?c.reduce(function(e,t){return t.name||he(15),M(e,t.name)},F).toString():"",p}var Me=new ke,ze=Fe(),$e=React.createContext({shouldForwardProp:void 0,styleSheet:Me,stylis:ze});$e.Consumer;React.createContext(void 0);function Ge(){return React.useContext($e)}var qe=function(){function e(e,t){var n=this;this.inject=function(e,t){ void 0===t&&(t=ze);var r=n.name+t.hash;e.hasNameForId(n.id,r)||e.insertRules(n.id,r,t(n.rules,r,"@keyframes"));},this.name=e,this.id="sc-keyframes-".concat(e),this.rules=t,ue(this,function(){throw he(12,String(n.name))});}return e.prototype.getName=function(e){return void 0===e&&(e=ze),this.name+e.hash},e}(),We=function(e){return e>="A"&&e<="Z"};function He(e){for(var t="",n=0;n<e.length;n++){var r=e[n];if(1===n&&"-"===r&&"-"===e[0])return e;We(r)?t+="-"+r.toLowerCase():t+=r;}return t.startsWith("ms-")?"-"+t:t}var Ue=function(e){return null==e||false===e||""===e},Je=function(t){var n,r,o=[];for(var s in t){var i=t[s];t.hasOwnProperty(s)&&!Ue(i)&&(Array.isArray(i)&&i.isCss||oe(i)?o.push("".concat(He(s),":"),i,";"):ce(i)?o.push.apply(o,__spreadArray(__spreadArray(["".concat(s," {")],Je(i),false),["}"],false)):o.push("".concat(He(s),": ").concat((n=s,null==(r=i)||"boolean"==typeof r||""===r?"":"number"!=typeof r||0===r||n in unitlessKeys$1||n.startsWith("--")?String(r).trim():"".concat(r,"px")),";")));}return o};function Xe(e,t,n,r){if(Ue(e))return [];if(se(e))return [".".concat(e.styledComponentId)];if(oe(e)){if(!oe(s=e)||s.prototype&&s.prototype.isReactComponent||!t)return [e];var o=e(t);return "production"===process.env.NODE_ENV||"object"!=typeof o||Array.isArray(o)||o instanceof qe||ce(o)||null===o||console.error("".concat(B(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.")),Xe(o,t,n,r)}var s;return e instanceof qe?n?(e.inject(n,r),[e.getName(r)]):[e]:ce(e)?Je(e):Array.isArray(e)?Array.prototype.concat.apply(_,e.map(function(e){return Xe(e,t,n,r)})):[e.toString()]}function Ze(e){for(var t=0;t<e.length;t+=1){var n=e[t];if(oe(n)&&!se(n))return false}return true}var Ke=z(v),Qe=function(){function e(e,t,n){this.rules=e,this.staticRulesId="",this.isStatic="production"===process.env.NODE_ENV&&(void 0===n||n.isStatic)&&Ze(e),this.componentId=t,this.baseHash=M(Ke,t),this.baseStyle=n,ke.registerId(t);}return e.prototype.generateAndInjectStyles=function(e,t,n){var r=this.baseStyle?this.baseStyle.generateAndInjectStyles(e,t,n):"";if(this.isStatic&&!n.hash)if(this.staticRulesId&&t.hasNameForId(this.componentId,this.staticRulesId))r=ie(r,this.staticRulesId);else {var o=ae(Xe(this.rules,e,t,n)),s=x(M(this.baseHash,o)>>>0);if(!t.hasNameForId(this.componentId,s)){var i=n(o,".".concat(s),void 0,this.componentId);t.insertRules(this.componentId,s,i);}r=ie(r,s),this.staticRulesId=s;}else {for(var a=M(this.baseHash,n.hash),c="",l=0;l<this.rules.length;l++){var u=this.rules[l];if("string"==typeof u)c+=u,"production"!==process.env.NODE_ENV&&(a=M(a,u));else if(u){var p=ae(Xe(u,e,t,n));a=M(a,p+l),c+=p;}}if(c){var d=x(a>>>0);t.hasNameForId(this.componentId,d)||t.insertRules(this.componentId,d,n(c,".".concat(d),void 0,this.componentId)),r=ie(r,d);}}return r},e}(),et=React.createContext(void 0);et.Consumer;function nt(){var e=React.useContext(et);if(!e)throw he(18);return e}function rt(e){var n=React.useContext(et),o=React.useMemo(function(){return function(e,n){if(!e)throw he(14);if(oe(e)){var r=e(n);if("production"!==process.env.NODE_ENV&&(null===r||Array.isArray(r)||"object"!=typeof r))throw he(7);return r}if(Array.isArray(e)||"object"!=typeof e)throw he(8);return n?__assign(__assign({},n),e):e}(e.theme,n)},[e.theme,n]);return e.children?React.createElement(et.Provider,{value:o},e.children):null}var ot={},st=new Set;function it(e,o,s){var i=se(e),a=e,c=!L(e),p=o.attrs,d=void 0===p?_:p,h=o.componentId,f=void 0===h?function(e,t){var n="string"!=typeof e?"sc":R(e);ot[n]=(ot[n]||0)+1;var r="".concat(n,"-").concat($(v+n+ot[n]));return t?"".concat(t,"-").concat(r):r}(o.displayName,o.parentComponentId):h,m=o.displayName,y=void 0===m?function(e){return L(e)?"styled.".concat(e):"Styled(".concat(B(e),")")}(e):m,g=o.displayName&&o.componentId?"".concat(R(o.displayName),"-").concat(o.componentId):o.componentId||f,S=i&&a.attrs?a.attrs.concat(d).filter(Boolean):d,w=o.shouldForwardProp;if(i&&a.shouldForwardProp){var b=a.shouldForwardProp;if(o.shouldForwardProp){var E=o.shouldForwardProp;w=function(e,t){return b(e,t)&&E(e,t)};}else w=b;}var N=new Qe(s,g,i?a.componentStyle:void 0);function O(e,o){return function(e,o,s){var i=e.attrs,a=e.componentStyle,c=e.defaultProps,p=e.foldedComponentIds,d=e.styledComponentId,h=e.target,f=React.useContext(et),m=Ge(),y=e.shouldForwardProp||m.shouldForwardProp;"production"!==process.env.NODE_ENV&&React.useDebugValue(d);var v=I(o,f,c)||C,g=function(e,n,r){for(var o,s=__assign(__assign({},n),{className:void 0,theme:r}),i=0;i<e.length;i+=1){var a=oe(o=e[i])?o(s):o;for(var c in a)s[c]="className"===c?ie(s[c],a[c]):"style"===c?__assign(__assign({},s[c]),a[c]):a[c];}return n.className&&(s.className=ie(s.className,n.className)),s}(i,o,v),S=g.as||h,w={};for(var b in g) void 0===g[b]||"$"===b[0]||"as"===b||"theme"===b&&g.theme===v||("forwardedAs"===b?w.as=g.forwardedAs:y&&!y(b,S)||(w[b]=g[b],y||"development"!==process.env.NODE_ENV||isPropValid(b)||st.has(b)||!A.has(S)||(st.add(b),console.warn('styled-components: it looks like an unknown prop "'.concat(b,'" is being sent through to the DOM, which will likely trigger a React console error. If you would like automatic filtering of unknown props, you can opt-into that behavior via `<StyleSheetManager shouldForwardProp={...}>` (connect an API like `@emotion/is-prop-valid`) or consider using transient props (`$` prefix for automatic filtering.)')))));var E=function(e,t){var n=Ge(),r=e.generateAndInjectStyles(t,n.styleSheet,n.stylis);return "production"!==process.env.NODE_ENV&&React.useDebugValue(r),r}(a,g);"production"!==process.env.NODE_ENV&&e.warnTooManyClasses&&e.warnTooManyClasses(E);var N=ie(p,d);return E&&(N+=" "+E),g.className&&(N+=" "+g.className),w[L(S)&&!A.has(S)?"class":"className"]=N,s&&(w.ref=s),React.createElement(S,w)}(D,e,o)}O.displayName=y;var D=React.forwardRef(O);return D.attrs=S,D.componentStyle=N,D.displayName=y,D.shouldForwardProp=w,D.foldedComponentIds=i?ie(a.foldedComponentIds,a.styledComponentId):"",D.styledComponentId=g,D.target=i?a.target:e,Object.defineProperty(D,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(e){this._foldedDefaultProps=i?function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];for(var r=0,o=t;r<o.length;r++)le(e,o[r],true);return e}({},a.defaultProps,e):e;}}),"production"!==process.env.NODE_ENV&&(P(y,g),D.warnTooManyClasses=function(e,t){var n={},r=false;return function(o){if(!r&&(n[o]=true,Object.keys(n).length>=200)){var s=t?' with the id of "'.concat(t,'"'):"";console.warn("Over ".concat(200," classes were generated for component ").concat(e).concat(s,".\n")+"Consider 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=true,n={};}}}(y,g)),ue(D,function(){return ".".concat(D.styledComponentId)}),c&&re(D,e,{attrs:true,componentStyle:true,displayName:true,foldedComponentIds:true,shouldForwardProp:true,styledComponentId:true,target:true}),D}function at(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}var ct=function(e){return Object.assign(e,{isCss:true})};function lt(t){for(var n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];if(oe(t)||ce(t))return ct(Xe(at(_,__spreadArray([t],n,true))));var o=t;return 0===n.length&&1===o.length&&"string"==typeof o[0]?Xe(o):ct(Xe(at(o,n)))}function ut(n,r,o){if(void 0===o&&(o=C),!r)throw he(1,r);var s=function(t){for(var s=[],i=1;i<arguments.length;i++)s[i-1]=arguments[i];return n(r,o,lt.apply(void 0,__spreadArray([t],s,false)))};return s.attrs=function(e){return ut(n,r,__assign(__assign({},o),{attrs:Array.prototype.concat(o.attrs,e).filter(Boolean)}))},s.withConfig=function(e){return ut(n,r,__assign(__assign({},o),e))},s}var pt=function(e){return ut(it,e)},dt=pt;A.forEach(function(e){dt[e]=pt(e);});function mt(t){for(var n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];"production"!==process.env.NODE_ENV&&"undefined"!=typeof navigator&&"ReactNative"===navigator.product&&console.warn("`keyframes` cannot be used on ReactNative, only on the web. To do animation in ReactNative please use Animated.");var o=ae(lt.apply(void 0,__spreadArray([t],n,false))),s=$(o);return new qe(s,o)}"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");var wt="__sc-".concat(f,"__");"production"!==process.env.NODE_ENV&&"test"!==process.env.NODE_ENV&&"undefined"!=typeof window&&(window[wt]||(window[wt]=0),1===window[wt]&&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[wt]+=1);
|
|
949
|
+
var f="undefined"!=typeof process&&void 0!==process.env&&(process.env.REACT_APP_SC_ATTR||process.env.SC_ATTR)||"data-styled",m="active",y="data-styled-version",v="6.1.17",g="/*!sc*/\n",S="undefined"!=typeof window&&"HTMLElement"in window,w=Boolean("boolean"==typeof SC_DISABLE_SPEEDY?SC_DISABLE_SPEEDY:"undefined"!=typeof process&&void 0!==process.env&&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&&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),E=/invalid hook call/i,N=new Set,P=function(t,n){if("production"!==process.env.NODE_ENV){var o=n?' with the id of "'.concat(n,'"'):"",s="The component ".concat(t).concat(o," has been created dynamically.\n")+"You 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.\nSee https://styled-components.com/docs/basics#define-styled-components-outside-of-the-render-method for more info.\n",i=console.error;try{var a=!0;console.error=function(t){for(var n=[],o=1;o<arguments.length;o++)n[o-1]=arguments[o];E.test(t)?(a=!1,N.delete(s)):i.apply(void 0,__spreadArray([t],n,!1));},React.useRef(),a&&!N.has(s)&&(console.warn(s),N.add(s));}catch(e){E.test(e.message)&&N.delete(s);}finally{console.error=i;}}},_=Object.freeze([]),C=Object.freeze({});function I(e,t,n){return void 0===n&&(n=C),e.theme!==n.theme&&e.theme||t||n.theme}var A=new Set(["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","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","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","tr","track","u","ul","use","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"]),O=/[!"#$%&'()*+,./:;<=>?@[\\\]^`{|}~-]+/g,D=/(^-|-$)/g;function R(e){return e.replace(O,"-").replace(D,"")}var T=/(a)(d)/gi,k=52,j=function(e){return String.fromCharCode(e+(e>25?39:97))};function x(e){var t,n="";for(t=Math.abs(e);t>k;t=t/k|0)n=j(t%k)+n;return (j(t%k)+n).replace(T,"$1-$2")}var V,F=5381,M=function(e,t){for(var n=t.length;n;)e=33*e^t.charCodeAt(--n);return e},z=function(e){return M(F,e)};function $(e){return x(z(e)>>>0)}function B(e){return "production"!==process.env.NODE_ENV&&"string"==typeof e&&e||e.displayName||e.name||"Component"}function L(e){return "string"==typeof e&&("production"===process.env.NODE_ENV||e.charAt(0)===e.charAt(0).toLowerCase())}var G="function"==typeof Symbol&&Symbol.for,Y=G?Symbol.for("react.memo"):60115,q=G?Symbol.for("react.forward_ref"):60112,W={childContextTypes:true,contextType:true,contextTypes:true,defaultProps:true,displayName:true,getDefaultProps:true,getDerivedStateFromError:true,getDerivedStateFromProps:true,mixins:true,propTypes:true,type:true},H={name:true,length:true,prototype:true,caller:true,callee:true,arguments:true,arity:true},U={$$typeof:true,compare:true,defaultProps:true,displayName:true,propTypes:true,type:true},J=((V={})[q]={$$typeof:true,render:true,defaultProps:true,displayName:true,propTypes:true},V[Y]=U,V);function X(e){return ("type"in(t=e)&&t.type.$$typeof)===Y?U:"$$typeof"in e?J[e.$$typeof]:W;var t;}var Z=Object.defineProperty,K=Object.getOwnPropertyNames,Q=Object.getOwnPropertySymbols,ee=Object.getOwnPropertyDescriptor,te=Object.getPrototypeOf,ne=Object.prototype;function oe(e,t,n){if("string"!=typeof t){if(ne){var o=te(t);o&&o!==ne&&oe(e,o,n);}var r=K(t);Q&&(r=r.concat(Q(t)));for(var s=X(e),i=X(t),a=0;a<r.length;++a){var c=r[a];if(!(c in H||n&&n[c]||i&&c in i||s&&c in s)){var l=ee(t,c);try{Z(e,c,l);}catch(e){}}}}return e}function re(e){return "function"==typeof e}function se(e){return "object"==typeof e&&"styledComponentId"in e}function ie(e,t){return e&&t?"".concat(e," ").concat(t):e||t||""}function ae(e,t){if(0===e.length)return "";for(var n=e[0],o=1;o<e.length;o++)n+=e[o];return n}function ce(e){return null!==e&&"object"==typeof e&&e.constructor.name===Object.name&&!("props"in e&&e.$$typeof)}function le(e,t,n){if(void 0===n&&(n=false),!n&&!ce(e)&&!Array.isArray(e))return t;if(Array.isArray(t))for(var o=0;o<t.length;o++)e[o]=le(e[o],t[o]);else if(ce(t))for(var o in t)e[o]=le(e[o],t[o]);return e}function ue(e,t){Object.defineProperty(e,"toString",{value:t});}var pe="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",18:"ThemeProvider: Please make sure your useTheme hook is within a `<ThemeProvider>`"}:{};function de(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n=e[0],o=[],r=1,s=e.length;r<s;r+=1)o.push(e[r]);return o.forEach(function(e){n=n.replace(/%[a-z]/,e);}),n}function he(t){for(var n=[],o=1;o<arguments.length;o++)n[o-1]=arguments[o];return "production"===process.env.NODE_ENV?new Error("An error occurred. See https://github.com/styled-components/styled-components/blob/main/packages/styled-components/src/utils/errors.md#".concat(t," for more information.").concat(n.length>0?" Args: ".concat(n.join(", ")):"")):new Error(de.apply(void 0,__spreadArray([pe[t]],n,false)).trim())}var fe=function(){function e(e){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=e;}return e.prototype.indexOfGroup=function(e){for(var t=0,n=0;n<e;n++)t+=this.groupSizes[n];return t},e.prototype.insertRules=function(e,t){if(e>=this.groupSizes.length){for(var n=this.groupSizes,o=n.length,r=o;e>=r;)if((r<<=1)<0)throw he(16,"".concat(e));this.groupSizes=new Uint32Array(r),this.groupSizes.set(n),this.length=r;for(var s=o;s<r;s++)this.groupSizes[s]=0;}for(var i=this.indexOfGroup(e+1),a=(s=0,t.length);s<a;s++)this.tag.insertRule(i,t[s])&&(this.groupSizes[e]++,i++);},e.prototype.clearGroup=function(e){if(e<this.length){var t=this.groupSizes[e],n=this.indexOfGroup(e),o=n+t;this.groupSizes[e]=0;for(var r=n;r<o;r++)this.tag.deleteRule(n);}},e.prototype.getGroup=function(e){var t="";if(e>=this.length||0===this.groupSizes[e])return t;for(var n=this.groupSizes[e],o=this.indexOfGroup(e),r=o+n,s=o;s<r;s++)t+="".concat(this.tag.getRule(s)).concat(g);return t},e}(),me=1<<30,ye=new Map,ve=new Map,ge=1,Se=function(e){if(ye.has(e))return ye.get(e);for(;ve.has(ge);)ge++;var t=ge++;if("production"!==process.env.NODE_ENV&&((0|t)<0||t>me))throw he(16,"".concat(t));return ye.set(e,t),ve.set(t,e),t},we=function(e,t){ge=t+1,ye.set(e,t),ve.set(t,e);},be="style[".concat(f,"][").concat(y,'="').concat(v,'"]'),Ee=new RegExp("^".concat(f,'\\.g(\\d+)\\[id="([\\w\\d-]+)"\\].*?"([^"]*)')),Ne=function(e,t,n){for(var o,r=n.split(","),s=0,i=r.length;s<i;s++)(o=r[s])&&e.registerName(t,o);},Pe=function(e,t){for(var n,o=(null!==(n=t.textContent)&&void 0!==n?n:"").split(g),r=[],s=0,i=o.length;s<i;s++){var a=o[s].trim();if(a){var c=a.match(Ee);if(c){var l=0|parseInt(c[1],10),u=c[2];0!==l&&(we(u,l),Ne(e,u,c[3]),e.getTag().insertRules(l,r)),r.length=0;}else r.push(a);}}},_e=function(e){for(var t=document.querySelectorAll(be),n=0,o=t.length;n<o;n++){var r=t[n];r&&r.getAttribute(f)!==m&&(Pe(e,r),r.parentNode&&r.parentNode.removeChild(r));}};function Ce(){return "undefined"!=typeof __webpack_nonce__?__webpack_nonce__:null}var Ie=function(e){var t=document.head,n=e||t,o=document.createElement("style"),r=function(e){var t=Array.from(e.querySelectorAll("style[".concat(f,"]")));return t[t.length-1]}(n),s=void 0!==r?r.nextSibling:null;o.setAttribute(f,m),o.setAttribute(y,v);var i=Ce();return i&&o.setAttribute("nonce",i),n.insertBefore(o,s),o},Ae=function(){function e(e){this.element=Ie(e),this.element.appendChild(document.createTextNode("")),this.sheet=function(e){if(e.sheet)return e.sheet;for(var t=document.styleSheets,n=0,o=t.length;n<o;n++){var r=t[n];if(r.ownerNode===e)return r}throw he(17)}(this.element),this.length=0;}return e.prototype.insertRule=function(e,t){try{return this.sheet.insertRule(t,e),this.length++,!0}catch(e){return false}},e.prototype.deleteRule=function(e){this.sheet.deleteRule(e),this.length--;},e.prototype.getRule=function(e){var t=this.sheet.cssRules[e];return t&&t.cssText?t.cssText:""},e}(),Oe=function(){function e(e){this.element=Ie(e),this.nodes=this.element.childNodes,this.length=0;}return e.prototype.insertRule=function(e,t){if(e<=this.length&&e>=0){var n=document.createTextNode(t);return this.element.insertBefore(n,this.nodes[e]||null),this.length++,true}return false},e.prototype.deleteRule=function(e){this.element.removeChild(this.nodes[e]),this.length--;},e.prototype.getRule=function(e){return e<this.length?this.nodes[e].textContent:""},e}(),De=function(){function e(e){this.rules=[],this.length=0;}return e.prototype.insertRule=function(e,t){return e<=this.length&&(this.rules.splice(e,0,t),this.length++,true)},e.prototype.deleteRule=function(e){this.rules.splice(e,1),this.length--;},e.prototype.getRule=function(e){return e<this.length?this.rules[e]:""},e}(),Re=S,Te={isServer:!S,useCSSOMInjection:!w},ke=function(){function e(e,n,o){ void 0===e&&(e=C),void 0===n&&(n={});var r=this;this.options=__assign(__assign({},Te),e),this.gs=n,this.names=new Map(o),this.server=!!e.isServer,!this.server&&S&&Re&&(Re=false,_e(this)),ue(this,function(){return function(e){for(var t=e.getTag(),n=t.length,o="",r=function(n){var r=function(e){return ve.get(e)}(n);if(void 0===r)return "continue";var s=e.names.get(r),i=t.getGroup(n);if(void 0===s||!s.size||0===i.length)return "continue";var a="".concat(f,".g").concat(n,'[id="').concat(r,'"]'),c="";void 0!==s&&s.forEach(function(e){e.length>0&&(c+="".concat(e,","));}),o+="".concat(i).concat(a,'{content:"').concat(c,'"}').concat(g);},s=0;s<n;s++)r(s);return o}(r)});}return e.registerId=function(e){return Se(e)},e.prototype.rehydrate=function(){!this.server&&S&&_e(this);},e.prototype.reconstructWithOptions=function(n,o){return void 0===o&&(o=true),new e(__assign(__assign({},this.options),n),this.gs,o&&this.names||void 0)},e.prototype.allocateGSInstance=function(e){return this.gs[e]=(this.gs[e]||0)+1},e.prototype.getTag=function(){return this.tag||(this.tag=(e=function(e){var t=e.useCSSOMInjection,n=e.target;return e.isServer?new De(n):t?new Ae(n):new Oe(n)}(this.options),new fe(e)));var e;},e.prototype.hasNameForId=function(e,t){return this.names.has(e)&&this.names.get(e).has(t)},e.prototype.registerName=function(e,t){if(Se(e),this.names.has(e))this.names.get(e).add(t);else {var n=new Set;n.add(t),this.names.set(e,n);}},e.prototype.insertRules=function(e,t,n){this.registerName(e,t),this.getTag().insertRules(Se(e),n);},e.prototype.clearNames=function(e){this.names.has(e)&&this.names.get(e).clear();},e.prototype.clearRules=function(e){this.getTag().clearGroup(Se(e)),this.clearNames(e);},e.prototype.clearTag=function(){this.tag=void 0;},e}(),je=/&/g,xe=/^\s*\/\/.*$/gm;function Ve(e,t){return e.map(function(e){return "rule"===e.type&&(e.value="".concat(t," ").concat(e.value),e.value=e.value.replaceAll(",",",".concat(t," ")),e.props=e.props.map(function(e){return "".concat(t," ").concat(e)})),Array.isArray(e.children)&&"@keyframes"!==e.type&&(e.children=Ve(e.children,t)),e})}function Fe(e){var t,n,o,r=C,s=r.options,i=void 0===s?C:s,a=r.plugins,c=void 0===a?_:a,l=function(e,o,r){return r.startsWith(n)&&r.endsWith(n)&&r.replaceAll(n,"").length>0?".".concat(t):e},u=c.slice();u.push(function(e){e.type===RULESET$1&&e.value.includes("&")&&(e.props[0]=e.props[0].replace(je,n).replace(o,l));}),i.prefix&&u.push(prefixer),u.push(stringify$2);var p=function(e,r,s,a){ void 0===r&&(r=""),void 0===s&&(s=""),void 0===a&&(a="&"),t=a,n=r,o=new RegExp("\\".concat(n,"\\b"),"g");var c=e.replace(xe,""),l=compile$1(s||r?"".concat(s," ").concat(r," { ").concat(c," }"):c);i.namespace&&(l=Ve(l,i.namespace));var p=[];return serialize$1(l,middleware(u.concat(rulesheet(function(e){return p.push(e)})))),p};return p.hash=c.length?c.reduce(function(e,t){return t.name||he(15),M(e,t.name)},F).toString():"",p}var Me=new ke,ze=Fe(),$e=React.createContext({shouldForwardProp:void 0,styleSheet:Me,stylis:ze});$e.Consumer;React.createContext(void 0);function Ge(){return React.useContext($e)}var qe=function(){function e(e,t){var n=this;this.inject=function(e,t){ void 0===t&&(t=ze);var o=n.name+t.hash;e.hasNameForId(n.id,o)||e.insertRules(n.id,o,t(n.rules,o,"@keyframes"));},this.name=e,this.id="sc-keyframes-".concat(e),this.rules=t,ue(this,function(){throw he(12,String(n.name))});}return e.prototype.getName=function(e){return void 0===e&&(e=ze),this.name+e.hash},e}(),We=function(e){return e>="A"&&e<="Z"};function He(e){for(var t="",n=0;n<e.length;n++){var o=e[n];if(1===n&&"-"===o&&"-"===e[0])return e;We(o)?t+="-"+o.toLowerCase():t+=o;}return t.startsWith("ms-")?"-"+t:t}var Ue=function(e){return null==e||false===e||""===e},Je=function(t){var n,o,r=[];for(var s in t){var i=t[s];t.hasOwnProperty(s)&&!Ue(i)&&(Array.isArray(i)&&i.isCss||re(i)?r.push("".concat(He(s),":"),i,";"):ce(i)?r.push.apply(r,__spreadArray(__spreadArray(["".concat(s," {")],Je(i),false),["}"],false)):r.push("".concat(He(s),": ").concat((n=s,null==(o=i)||"boolean"==typeof o||""===o?"":"number"!=typeof o||0===o||n in unitlessKeys$1||n.startsWith("--")?String(o).trim():"".concat(o,"px")),";")));}return r};function Xe(e,t,n,o){if(Ue(e))return [];if(se(e))return [".".concat(e.styledComponentId)];if(re(e)){if(!re(s=e)||s.prototype&&s.prototype.isReactComponent||!t)return [e];var r=e(t);return "production"===process.env.NODE_ENV||"object"!=typeof r||Array.isArray(r)||r instanceof qe||ce(r)||null===r||console.error("".concat(B(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.")),Xe(r,t,n,o)}var s;return e instanceof qe?n?(e.inject(n,o),[e.getName(o)]):[e]:ce(e)?Je(e):Array.isArray(e)?Array.prototype.concat.apply(_,e.map(function(e){return Xe(e,t,n,o)})):[e.toString()]}function Ze(e){for(var t=0;t<e.length;t+=1){var n=e[t];if(re(n)&&!se(n))return false}return true}var Ke=z(v),Qe=function(){function e(e,t,n){this.rules=e,this.staticRulesId="",this.isStatic="production"===process.env.NODE_ENV&&(void 0===n||n.isStatic)&&Ze(e),this.componentId=t,this.baseHash=M(Ke,t),this.baseStyle=n,ke.registerId(t);}return e.prototype.generateAndInjectStyles=function(e,t,n){var o=this.baseStyle?this.baseStyle.generateAndInjectStyles(e,t,n):"";if(this.isStatic&&!n.hash)if(this.staticRulesId&&t.hasNameForId(this.componentId,this.staticRulesId))o=ie(o,this.staticRulesId);else {var r=ae(Xe(this.rules,e,t,n)),s=x(M(this.baseHash,r)>>>0);if(!t.hasNameForId(this.componentId,s)){var i=n(r,".".concat(s),void 0,this.componentId);t.insertRules(this.componentId,s,i);}o=ie(o,s),this.staticRulesId=s;}else {for(var a=M(this.baseHash,n.hash),c="",l=0;l<this.rules.length;l++){var u=this.rules[l];if("string"==typeof u)c+=u,"production"!==process.env.NODE_ENV&&(a=M(a,u));else if(u){var p=ae(Xe(u,e,t,n));a=M(a,p+l),c+=p;}}if(c){var d=x(a>>>0);t.hasNameForId(this.componentId,d)||t.insertRules(this.componentId,d,n(c,".".concat(d),void 0,this.componentId)),o=ie(o,d);}}return o},e}(),et=React.createContext(void 0);et.Consumer;function nt(){var e=React.useContext(et);if(!e)throw he(18);return e}function ot(e){var n=React.useContext(et),r=React.useMemo(function(){return function(e,n){if(!e)throw he(14);if(re(e)){var o=e(n);if("production"!==process.env.NODE_ENV&&(null===o||Array.isArray(o)||"object"!=typeof o))throw he(7);return o}if(Array.isArray(e)||"object"!=typeof e)throw he(8);return n?__assign(__assign({},n),e):e}(e.theme,n)},[e.theme,n]);return e.children?React.createElement(et.Provider,{value:r},e.children):null}var rt={},st=new Set;function it(e,r,s){var i=se(e),a=e,c=!L(e),p=r.attrs,d=void 0===p?_:p,h=r.componentId,f=void 0===h?function(e,t){var n="string"!=typeof e?"sc":R(e);rt[n]=(rt[n]||0)+1;var o="".concat(n,"-").concat($(v+n+rt[n]));return t?"".concat(t,"-").concat(o):o}(r.displayName,r.parentComponentId):h,m=r.displayName,y=void 0===m?function(e){return L(e)?"styled.".concat(e):"Styled(".concat(B(e),")")}(e):m,g=r.displayName&&r.componentId?"".concat(R(r.displayName),"-").concat(r.componentId):r.componentId||f,S=i&&a.attrs?a.attrs.concat(d).filter(Boolean):d,w=r.shouldForwardProp;if(i&&a.shouldForwardProp){var b=a.shouldForwardProp;if(r.shouldForwardProp){var E=r.shouldForwardProp;w=function(e,t){return b(e,t)&&E(e,t)};}else w=b;}var N=new Qe(s,g,i?a.componentStyle:void 0);function O(e,r){return function(e,r,s){var i=e.attrs,a=e.componentStyle,c=e.defaultProps,p=e.foldedComponentIds,d=e.styledComponentId,h=e.target,f=React.useContext(et),m=Ge(),y=e.shouldForwardProp||m.shouldForwardProp;"production"!==process.env.NODE_ENV&&React.useDebugValue(d);var v=I(r,f,c)||C,g=function(e,n,o){for(var r,s=__assign(__assign({},n),{className:void 0,theme:o}),i=0;i<e.length;i+=1){var a=re(r=e[i])?r(s):r;for(var c in a)s[c]="className"===c?ie(s[c],a[c]):"style"===c?__assign(__assign({},s[c]),a[c]):a[c];}return n.className&&(s.className=ie(s.className,n.className)),s}(i,r,v),S=g.as||h,w={};for(var b in g) void 0===g[b]||"$"===b[0]||"as"===b||"theme"===b&&g.theme===v||("forwardedAs"===b?w.as=g.forwardedAs:y&&!y(b,S)||(w[b]=g[b],y||"development"!==process.env.NODE_ENV||isPropValid(b)||st.has(b)||!A.has(S)||(st.add(b),console.warn('styled-components: it looks like an unknown prop "'.concat(b,'" is being sent through to the DOM, which will likely trigger a React console error. If you would like automatic filtering of unknown props, you can opt-into that behavior via `<StyleSheetManager shouldForwardProp={...}>` (connect an API like `@emotion/is-prop-valid`) or consider using transient props (`$` prefix for automatic filtering.)')))));var E=function(e,t){var n=Ge(),o=e.generateAndInjectStyles(t,n.styleSheet,n.stylis);return "production"!==process.env.NODE_ENV&&React.useDebugValue(o),o}(a,g);"production"!==process.env.NODE_ENV&&e.warnTooManyClasses&&e.warnTooManyClasses(E);var N=ie(p,d);return E&&(N+=" "+E),g.className&&(N+=" "+g.className),w[L(S)&&!A.has(S)?"class":"className"]=N,s&&(w.ref=s),React.createElement(S,w)}(D,e,r)}O.displayName=y;var D=React.forwardRef(O);return D.attrs=S,D.componentStyle=N,D.displayName=y,D.shouldForwardProp=w,D.foldedComponentIds=i?ie(a.foldedComponentIds,a.styledComponentId):"",D.styledComponentId=g,D.target=i?a.target:e,Object.defineProperty(D,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(e){this._foldedDefaultProps=i?function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];for(var o=0,r=t;o<r.length;o++)le(e,r[o],true);return e}({},a.defaultProps,e):e;}}),"production"!==process.env.NODE_ENV&&(P(y,g),D.warnTooManyClasses=function(e,t){var n={},o=false;return function(r){if(!o&&(n[r]=true,Object.keys(n).length>=200)){var s=t?' with the id of "'.concat(t,'"'):"";console.warn("Over ".concat(200," classes were generated for component ").concat(e).concat(s,".\n")+"Consider 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 />"),o=true,n={};}}}(y,g)),ue(D,function(){return ".".concat(D.styledComponentId)}),c&&oe(D,e,{attrs:true,componentStyle:true,displayName:true,foldedComponentIds:true,shouldForwardProp:true,styledComponentId:true,target:true}),D}function at(e,t){for(var n=[e[0]],o=0,r=t.length;o<r;o+=1)n.push(t[o],e[o+1]);return n}var ct=function(e){return Object.assign(e,{isCss:true})};function lt(t){for(var n=[],o=1;o<arguments.length;o++)n[o-1]=arguments[o];if(re(t)||ce(t))return ct(Xe(at(_,__spreadArray([t],n,true))));var r=t;return 0===n.length&&1===r.length&&"string"==typeof r[0]?Xe(r):ct(Xe(at(r,n)))}function ut(n,o,r){if(void 0===r&&(r=C),!o)throw he(1,o);var s=function(t){for(var s=[],i=1;i<arguments.length;i++)s[i-1]=arguments[i];return n(o,r,lt.apply(void 0,__spreadArray([t],s,false)))};return s.attrs=function(e){return ut(n,o,__assign(__assign({},r),{attrs:Array.prototype.concat(r.attrs,e).filter(Boolean)}))},s.withConfig=function(e){return ut(n,o,__assign(__assign({},r),e))},s}var pt=function(e){return ut(it,e)},dt=pt;A.forEach(function(e){dt[e]=pt(e);});function mt(t){for(var n=[],o=1;o<arguments.length;o++)n[o-1]=arguments[o];"production"!==process.env.NODE_ENV&&"undefined"!=typeof navigator&&"ReactNative"===navigator.product&&console.warn("`keyframes` cannot be used on ReactNative, only on the web. To do animation in ReactNative please use Animated.");var r=ae(lt.apply(void 0,__spreadArray([t],n,false))),s=$(r);return new qe(s,r)}"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");var wt="__sc-".concat(f,"__");"production"!==process.env.NODE_ENV&&"test"!==process.env.NODE_ENV&&"undefined"!=typeof window&&(window[wt]||(window[wt]=0),1===window[wt]&&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[wt]+=1);
|
|
951
950
|
|
|
952
951
|
var theme = {
|
|
953
952
|
"com/accordion/head/size-md/icon-wrap/height": "24px",
|
|
@@ -5685,7 +5684,7 @@ const ToastProvider = ({ children, }) => {
|
|
|
5685
5684
|
return (jsxRuntime.jsxs(ToastContext.Provider, { value: { showToast }, children: [children, toasts.length > 0 && (jsxRuntime.jsx(ToastWrapper, { children: toasts.map((toast, index) => (jsxRuntime.jsx(FISToast, { ...toast }, index))) }))] }));
|
|
5686
5685
|
};
|
|
5687
5686
|
|
|
5688
|
-
const FISThemeProvider = ({ theme: theme$1 = theme, children, }) => (jsxRuntime.jsx(
|
|
5687
|
+
const FISThemeProvider = ({ theme: theme$1 = theme, children, }) => (jsxRuntime.jsx(ot, { theme: theme$1, children: jsxRuntime.jsx(ToastProvider, { children: children }) }));
|
|
5689
5688
|
|
|
5690
5689
|
const LinkButtonStyled = dt.button `
|
|
5691
5690
|
display: flex;
|
|
@@ -11345,7 +11344,7 @@ function canUseDom() {
|
|
|
11345
11344
|
return !!(typeof window !== 'undefined' && window.document && window.document.createElement);
|
|
11346
11345
|
}
|
|
11347
11346
|
|
|
11348
|
-
function contains(root, n) {
|
|
11347
|
+
function contains$1(root, n) {
|
|
11349
11348
|
if (!root) {
|
|
11350
11349
|
return false;
|
|
11351
11350
|
}
|
|
@@ -11471,7 +11470,7 @@ function syncRealContainer(container, option) {
|
|
|
11471
11470
|
var cachedRealContainer = containerCache.get(container);
|
|
11472
11471
|
|
|
11473
11472
|
// Find real container when not cached or cached container removed
|
|
11474
|
-
if (!cachedRealContainer || !contains(document, cachedRealContainer)) {
|
|
11473
|
+
if (!cachedRealContainer || !contains$1(document, cachedRealContainer)) {
|
|
11475
11474
|
var placeholderStyle = injectCSS('', option);
|
|
11476
11475
|
var parentNode = placeholderStyle.parentNode;
|
|
11477
11476
|
containerCache.set(container, parentNode);
|
|
@@ -11534,7 +11533,7 @@ function _objectWithoutProperties(e, t) {
|
|
|
11534
11533
|
* @param shallow shallow compare
|
|
11535
11534
|
* @returns
|
|
11536
11535
|
*/
|
|
11537
|
-
function isEqual(obj1, obj2) {
|
|
11536
|
+
function isEqual$1(obj1, obj2) {
|
|
11538
11537
|
var shallow = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
|
|
11539
11538
|
// https://github.com/mapbox/mapbox-gl-js/pull/5979/files#diff-fde7145050c47cc3a306856efd5f9c3016e86e859de9afbd02c879be5067e58f
|
|
11540
11539
|
var refSet = new Set();
|
|
@@ -14039,7 +14038,7 @@ const seedToken = Object.assign(Object.assign({}, defaultPresetColors), {
|
|
|
14039
14038
|
motion: true
|
|
14040
14039
|
});
|
|
14041
14040
|
|
|
14042
|
-
const round = Math.round;
|
|
14041
|
+
const round$1 = Math.round;
|
|
14043
14042
|
|
|
14044
14043
|
/**
|
|
14045
14044
|
* Support format, alpha unit will check the % mark:
|
|
@@ -14201,7 +14200,7 @@ class FastColor {
|
|
|
14201
14200
|
if (delta === 0) {
|
|
14202
14201
|
this._h = 0;
|
|
14203
14202
|
} else {
|
|
14204
|
-
this._h = round(60 * (this.r === this.getMax() ? (this.g - this.b) / delta + (this.g < this.b ? 6 : 0) : this.g === this.getMax() ? (this.b - this.r) / delta + 2 : (this.r - this.g) / delta + 4));
|
|
14203
|
+
this._h = round$1(60 * (this.r === this.getMax() ? (this.g - this.b) / delta + (this.g < this.b ? 6 : 0) : this.g === this.getMax() ? (this.b - this.r) / delta + 2 : (this.r - this.g) / delta + 4));
|
|
14205
14204
|
}
|
|
14206
14205
|
}
|
|
14207
14206
|
return this._h;
|
|
@@ -14282,10 +14281,10 @@ class FastColor {
|
|
|
14282
14281
|
const p = amount / 100;
|
|
14283
14282
|
const calc = key => (color[key] - this[key]) * p + this[key];
|
|
14284
14283
|
const rgba = {
|
|
14285
|
-
r: round(calc('r')),
|
|
14286
|
-
g: round(calc('g')),
|
|
14287
|
-
b: round(calc('b')),
|
|
14288
|
-
a: round(calc('a') * 100) / 100
|
|
14284
|
+
r: round$1(calc('r')),
|
|
14285
|
+
g: round$1(calc('g')),
|
|
14286
|
+
b: round$1(calc('b')),
|
|
14287
|
+
a: round$1(calc('a') * 100) / 100
|
|
14289
14288
|
};
|
|
14290
14289
|
return this._c(rgba);
|
|
14291
14290
|
}
|
|
@@ -14319,7 +14318,7 @@ class FastColor {
|
|
|
14319
14318
|
const bg = this._c(background);
|
|
14320
14319
|
const alpha = this.a + bg.a * (1 - this.a);
|
|
14321
14320
|
const calc = key => {
|
|
14322
|
-
return round((this[key] * this.a + bg[key] * bg.a * (1 - this.a)) / alpha);
|
|
14321
|
+
return round$1((this[key] * this.a + bg[key] * bg.a * (1 - this.a)) / alpha);
|
|
14323
14322
|
};
|
|
14324
14323
|
return this._c({
|
|
14325
14324
|
r: calc('r'),
|
|
@@ -14355,7 +14354,7 @@ class FastColor {
|
|
|
14355
14354
|
const bHex = (this.b || 0).toString(16);
|
|
14356
14355
|
hex += bHex.length === 2 ? bHex : '0' + bHex;
|
|
14357
14356
|
if (typeof this.a === 'number' && this.a >= 0 && this.a < 1) {
|
|
14358
|
-
const aHex = round(this.a * 255).toString(16);
|
|
14357
|
+
const aHex = round$1(this.a * 255).toString(16);
|
|
14359
14358
|
hex += aHex.length === 2 ? aHex : '0' + aHex;
|
|
14360
14359
|
}
|
|
14361
14360
|
return hex;
|
|
@@ -14374,8 +14373,8 @@ class FastColor {
|
|
|
14374
14373
|
/** CSS support color pattern */
|
|
14375
14374
|
toHslString() {
|
|
14376
14375
|
const h = this.getHue();
|
|
14377
|
-
const s = round(this.getSaturation() * 100);
|
|
14378
|
-
const l = round(this.getLightness() * 100);
|
|
14376
|
+
const s = round$1(this.getSaturation() * 100);
|
|
14377
|
+
const l = round$1(this.getLightness() * 100);
|
|
14379
14378
|
return this.a !== 1 ? `hsla(${h},${s}%,${l}%,${this.a})` : `hsl(${h},${s}%,${l}%)`;
|
|
14380
14379
|
}
|
|
14381
14380
|
|
|
@@ -14455,7 +14454,7 @@ class FastColor {
|
|
|
14455
14454
|
this._l = l;
|
|
14456
14455
|
this.a = typeof a === 'number' ? a : 1;
|
|
14457
14456
|
if (s <= 0) {
|
|
14458
|
-
const rgb = round(l * 255);
|
|
14457
|
+
const rgb = round$1(l * 255);
|
|
14459
14458
|
this.r = rgb;
|
|
14460
14459
|
this.g = rgb;
|
|
14461
14460
|
this.b = rgb;
|
|
@@ -14486,9 +14485,9 @@ class FastColor {
|
|
|
14486
14485
|
b = secondComponent;
|
|
14487
14486
|
}
|
|
14488
14487
|
const lightnessModification = l - chroma / 2;
|
|
14489
|
-
this.r = round((r + lightnessModification) * 255);
|
|
14490
|
-
this.g = round((g + lightnessModification) * 255);
|
|
14491
|
-
this.b = round((b + lightnessModification) * 255);
|
|
14488
|
+
this.r = round$1((r + lightnessModification) * 255);
|
|
14489
|
+
this.g = round$1((g + lightnessModification) * 255);
|
|
14490
|
+
this.b = round$1((b + lightnessModification) * 255);
|
|
14492
14491
|
}
|
|
14493
14492
|
fromHsv({
|
|
14494
14493
|
h,
|
|
@@ -14500,7 +14499,7 @@ class FastColor {
|
|
|
14500
14499
|
this._s = s;
|
|
14501
14500
|
this._v = v;
|
|
14502
14501
|
this.a = typeof a === 'number' ? a : 1;
|
|
14503
|
-
const vv = round(v * 255);
|
|
14502
|
+
const vv = round$1(v * 255);
|
|
14504
14503
|
this.r = vv;
|
|
14505
14504
|
this.g = vv;
|
|
14506
14505
|
this.b = vv;
|
|
@@ -14510,9 +14509,9 @@ class FastColor {
|
|
|
14510
14509
|
const hh = h / 60;
|
|
14511
14510
|
const i = Math.floor(hh);
|
|
14512
14511
|
const ff = hh - i;
|
|
14513
|
-
const p = round(v * (1.0 - s) * 255);
|
|
14514
|
-
const q = round(v * (1.0 - s * ff) * 255);
|
|
14515
|
-
const t = round(v * (1.0 - s * (1.0 - ff)) * 255);
|
|
14512
|
+
const p = round$1(v * (1.0 - s) * 255);
|
|
14513
|
+
const q = round$1(v * (1.0 - s * ff) * 255);
|
|
14514
|
+
const t = round$1(v * (1.0 - s * (1.0 - ff)) * 255);
|
|
14516
14515
|
switch (i) {
|
|
14517
14516
|
case 0:
|
|
14518
14517
|
this.g = t;
|
|
@@ -14562,7 +14561,7 @@ class FastColor {
|
|
|
14562
14561
|
fromRgbString(trimStr) {
|
|
14563
14562
|
const cells = splitColorStr(trimStr, (num, txt) =>
|
|
14564
14563
|
// Convert percentage to number. e.g. 50% -> 128
|
|
14565
|
-
txt.includes('%') ? round(num / 100 * 255) : num);
|
|
14564
|
+
txt.includes('%') ? round$1(num / 100 * 255) : num);
|
|
14566
14565
|
this.r = cells[0];
|
|
14567
14566
|
this.g = cells[1];
|
|
14568
14567
|
this.b = cells[2];
|
|
@@ -15993,7 +15992,7 @@ function genStyleUtils(config) {
|
|
|
15993
15992
|
|
|
15994
15993
|
const PresetColors = ['blue', 'purple', 'cyan', 'green', 'magenta', 'pink', 'red', 'orange', 'yellow', 'volcano', 'geekblue', 'lime', 'gold'];
|
|
15995
15994
|
|
|
15996
|
-
var version$1 = '5.24.
|
|
15995
|
+
var version$1 = '5.24.6';
|
|
15997
15996
|
|
|
15998
15997
|
function isStableColor(color) {
|
|
15999
15998
|
return color >= 0 && color <= 255;
|
|
@@ -16586,7 +16585,7 @@ function useTheme(theme, parentTheme, config) {
|
|
|
16586
16585
|
});
|
|
16587
16586
|
}, [themeConfig, parentThemeConfig], (prev, next) => prev.some((prevTheme, index) => {
|
|
16588
16587
|
const nextTheme = next[index];
|
|
16589
|
-
return !isEqual(prevTheme, nextTheme, true);
|
|
16588
|
+
return !isEqual$1(prevTheme, nextTheme, true);
|
|
16590
16589
|
}));
|
|
16591
16590
|
}
|
|
16592
16591
|
|
|
@@ -16755,7 +16754,7 @@ var useDomMotionEvents = (function (onInternalMotionEnd) {
|
|
|
16755
16754
|
});
|
|
16756
16755
|
|
|
16757
16756
|
// It's safe to use `useLayoutEffect` but the warning is annoying
|
|
16758
|
-
var useIsomorphicLayoutEffect = canUseDom() ? React.useLayoutEffect : React.useEffect;
|
|
16757
|
+
var useIsomorphicLayoutEffect$1 = canUseDom() ? React.useLayoutEffect : React.useEffect;
|
|
16759
16758
|
|
|
16760
16759
|
var useNextFrame = (function () {
|
|
16761
16760
|
var nextFrameRef = React__namespace.useRef(null);
|
|
@@ -16809,7 +16808,7 @@ var useStepQueue = (function (status, prepareOnly, callback) {
|
|
|
16809
16808
|
setStep(STEP_PREPARE, true);
|
|
16810
16809
|
}
|
|
16811
16810
|
var STEP_QUEUE = prepareOnly ? SIMPLE_STEP_QUEUE : FULL_STEP_QUEUE;
|
|
16812
|
-
useIsomorphicLayoutEffect(function () {
|
|
16811
|
+
useIsomorphicLayoutEffect$1(function () {
|
|
16813
16812
|
if (step !== STEP_NONE && step !== STEP_ACTIVATED) {
|
|
16814
16813
|
var index = STEP_QUEUE.indexOf(step);
|
|
16815
16814
|
var nextStep = STEP_QUEUE[index + 1];
|
|
@@ -16988,7 +16987,7 @@ function useStatus(supportMotion, visible, getElement, _ref) {
|
|
|
16988
16987
|
var visibleRef = React.useRef(null);
|
|
16989
16988
|
|
|
16990
16989
|
// Update with new status
|
|
16991
|
-
useIsomorphicLayoutEffect(function () {
|
|
16990
|
+
useIsomorphicLayoutEffect$1(function () {
|
|
16992
16991
|
// When use Suspense, the `visible` will repeat trigger,
|
|
16993
16992
|
// But not real change of the `visible`, we need to skip it.
|
|
16994
16993
|
// https://github.com/ant-design/ant-design/issues/44379
|
|
@@ -19260,7 +19259,7 @@ const useSize = customSize => {
|
|
|
19260
19259
|
if (typeof customSize === 'string') {
|
|
19261
19260
|
return customSize !== null && customSize !== void 0 ? customSize : size;
|
|
19262
19261
|
}
|
|
19263
|
-
if (customSize
|
|
19262
|
+
if (typeof customSize === 'function') {
|
|
19264
19263
|
return customSize(size);
|
|
19265
19264
|
}
|
|
19266
19265
|
return size;
|
|
@@ -23948,7 +23947,7 @@ var Field = /*#__PURE__*/function (_React$Component) {
|
|
|
23948
23947
|
var _meta = _objectSpread2(_objectSpread2({}, _this.getMeta()), {}, {
|
|
23949
23948
|
destroy: destroy
|
|
23950
23949
|
});
|
|
23951
|
-
if (!isEqual(_this.metaCache, _meta)) {
|
|
23950
|
+
if (!isEqual$1(_this.metaCache, _meta)) {
|
|
23952
23951
|
onMetaChange(_meta);
|
|
23953
23952
|
}
|
|
23954
23953
|
_this.metaCache = _meta;
|
|
@@ -23971,7 +23970,7 @@ var Field = /*#__PURE__*/function (_React$Component) {
|
|
|
23971
23970
|
var namePathMatch = namePathList && containsNamePath(namePathList, namePath);
|
|
23972
23971
|
|
|
23973
23972
|
// `setFieldsValue` is a quick access to update related status
|
|
23974
|
-
if (info.type === 'valueUpdate' && info.source === 'external' && !isEqual(prevValue, curValue)) {
|
|
23973
|
+
if (info.type === 'valueUpdate' && info.source === 'external' && !isEqual$1(prevValue, curValue)) {
|
|
23975
23974
|
_this.touched = true;
|
|
23976
23975
|
_this.dirty = true;
|
|
23977
23976
|
_this.validatePromise = null;
|
|
@@ -30388,7 +30387,7 @@ function useScrollDrag(inVirtual, componentRef, onScrollOffset) {
|
|
|
30388
30387
|
};
|
|
30389
30388
|
var onMouseDown = function onMouseDown(e) {
|
|
30390
30389
|
// Skip if element set draggable
|
|
30391
|
-
if (e.target.draggable) {
|
|
30390
|
+
if (e.target.draggable || e.button !== 0) {
|
|
30392
30391
|
return;
|
|
30393
30392
|
}
|
|
30394
30393
|
// Skip if nest List has handled this event
|
|
@@ -33827,7 +33826,7 @@ const getSearchInputWithoutBorderStyle = token => {
|
|
|
33827
33826
|
fontFamily: 'inherit',
|
|
33828
33827
|
'&::-webkit-search-cancel-button': {
|
|
33829
33828
|
display: 'none',
|
|
33830
|
-
|
|
33829
|
+
appearance: 'none'
|
|
33831
33830
|
}
|
|
33832
33831
|
}
|
|
33833
33832
|
};
|
|
@@ -34388,7 +34387,7 @@ const validateBreakpoints = token => {
|
|
|
34388
34387
|
});
|
|
34389
34388
|
return token;
|
|
34390
34389
|
};
|
|
34391
|
-
|
|
34390
|
+
const useResponsiveObserver = () => {
|
|
34392
34391
|
const [, token] = useToken();
|
|
34393
34392
|
const responsiveMap = getResponsiveMap(validateBreakpoints(token));
|
|
34394
34393
|
// To avoid repeat create instance, we add `useMemo` here.
|
|
@@ -34397,6 +34396,7 @@ function useResponsiveObserver() {
|
|
|
34397
34396
|
let subUid = -1;
|
|
34398
34397
|
let screens = {};
|
|
34399
34398
|
return {
|
|
34399
|
+
responsiveMap,
|
|
34400
34400
|
matchHandlers: {},
|
|
34401
34401
|
dispatch(pointMap) {
|
|
34402
34402
|
screens = pointMap;
|
|
@@ -34418,14 +34418,6 @@ function useResponsiveObserver() {
|
|
|
34418
34418
|
this.unregister();
|
|
34419
34419
|
}
|
|
34420
34420
|
},
|
|
34421
|
-
unregister() {
|
|
34422
|
-
Object.keys(responsiveMap).forEach(screen => {
|
|
34423
|
-
const matchMediaQuery = responsiveMap[screen];
|
|
34424
|
-
const handler = this.matchHandlers[matchMediaQuery];
|
|
34425
|
-
handler === null || handler === void 0 ? void 0 : handler.mql.removeListener(handler === null || handler === void 0 ? void 0 : handler.listener);
|
|
34426
|
-
});
|
|
34427
|
-
subscribers.clear();
|
|
34428
|
-
},
|
|
34429
34421
|
register() {
|
|
34430
34422
|
Object.keys(responsiveMap).forEach(screen => {
|
|
34431
34423
|
const matchMediaQuery = responsiveMap[screen];
|
|
@@ -34446,10 +34438,17 @@ function useResponsiveObserver() {
|
|
|
34446
34438
|
listener(mql);
|
|
34447
34439
|
});
|
|
34448
34440
|
},
|
|
34449
|
-
|
|
34441
|
+
unregister() {
|
|
34442
|
+
Object.keys(responsiveMap).forEach(screen => {
|
|
34443
|
+
const matchMediaQuery = responsiveMap[screen];
|
|
34444
|
+
const handler = this.matchHandlers[matchMediaQuery];
|
|
34445
|
+
handler === null || handler === void 0 ? void 0 : handler.mql.removeListener(handler === null || handler === void 0 ? void 0 : handler.listener);
|
|
34446
|
+
});
|
|
34447
|
+
subscribers.clear();
|
|
34448
|
+
}
|
|
34450
34449
|
};
|
|
34451
34450
|
}, [token]);
|
|
34452
|
-
}
|
|
34451
|
+
};
|
|
34453
34452
|
|
|
34454
34453
|
function useForceUpdate() {
|
|
34455
34454
|
const [, forceUpdate] = React__namespace.useReducer(x => x + 1, 0);
|
|
@@ -34502,7 +34501,7 @@ var autoAdjustOverflowLeftRight = {
|
|
|
34502
34501
|
shiftY: true
|
|
34503
34502
|
};
|
|
34504
34503
|
var targetOffset$1 = [0, 0];
|
|
34505
|
-
var placements$
|
|
34504
|
+
var placements$3 = {
|
|
34506
34505
|
left: {
|
|
34507
34506
|
points: ['cr', 'cl'],
|
|
34508
34507
|
overflow: autoAdjustOverflowLeftRight,
|
|
@@ -34643,7 +34642,7 @@ var Tooltip$1 = function Tooltip(props, ref) {
|
|
|
34643
34642
|
prefixCls: prefixCls,
|
|
34644
34643
|
popup: getPopupElement,
|
|
34645
34644
|
action: trigger,
|
|
34646
|
-
builtinPlacements: placements$
|
|
34645
|
+
builtinPlacements: placements$3,
|
|
34647
34646
|
popupPlacement: placement,
|
|
34648
34647
|
ref: triggerRef,
|
|
34649
34648
|
popupAlign: align,
|
|
@@ -35553,7 +35552,7 @@ var autoAdjustOverflow$1 = {
|
|
|
35553
35552
|
adjustY: 1
|
|
35554
35553
|
};
|
|
35555
35554
|
var targetOffset = [0, 0];
|
|
35556
|
-
var placements$
|
|
35555
|
+
var placements$2 = {
|
|
35557
35556
|
topLeft: {
|
|
35558
35557
|
points: ['bl', 'tl'],
|
|
35559
35558
|
overflow: autoAdjustOverflow$1,
|
|
@@ -35605,7 +35604,7 @@ function Dropdown$2(props, ref) {
|
|
|
35605
35604
|
_props$placement = props.placement,
|
|
35606
35605
|
placement = _props$placement === void 0 ? 'bottomLeft' : _props$placement,
|
|
35607
35606
|
_props$placements = props.placements,
|
|
35608
|
-
placements = _props$placements === void 0 ? placements$
|
|
35607
|
+
placements = _props$placements === void 0 ? placements$2 : _props$placements,
|
|
35609
35608
|
getPopupContainer = props.getPopupContainer,
|
|
35610
35609
|
showAction = props.showAction,
|
|
35611
35610
|
hideAction = props.hideAction,
|
|
@@ -35747,7 +35746,7 @@ function InheritableContextProvider(_ref) {
|
|
|
35747
35746
|
var inheritableContext = useMemo(function () {
|
|
35748
35747
|
return mergeProps(context, restProps);
|
|
35749
35748
|
}, [context, restProps], function (prev, next) {
|
|
35750
|
-
return !locked && (prev[0] !== next[0] || !isEqual(prev[1], next[1], true));
|
|
35749
|
+
return !locked && (prev[0] !== next[0] || !isEqual$1(prev[1], next[1], true));
|
|
35751
35750
|
});
|
|
35752
35751
|
return /*#__PURE__*/React__namespace.createElement(MenuContext$1.Provider, {
|
|
35753
35752
|
value: inheritableContext
|
|
@@ -36549,7 +36548,7 @@ var autoAdjustOverflow = {
|
|
|
36549
36548
|
adjustX: 1,
|
|
36550
36549
|
adjustY: 1
|
|
36551
36550
|
};
|
|
36552
|
-
var placements = {
|
|
36551
|
+
var placements$1 = {
|
|
36553
36552
|
topLeft: {
|
|
36554
36553
|
points: ['bl', 'tl'],
|
|
36555
36554
|
overflow: autoAdjustOverflow
|
|
@@ -36660,7 +36659,7 @@ function PopupTrigger(_ref) {
|
|
|
36660
36659
|
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
36661
36660
|
innerVisible = _React$useState2[0],
|
|
36662
36661
|
setInnerVisible = _React$useState2[1];
|
|
36663
|
-
var placement = rtl ? _objectSpread2(_objectSpread2({}, placementsRtl), builtinPlacements) : _objectSpread2(_objectSpread2({}, placements), builtinPlacements);
|
|
36662
|
+
var placement = rtl ? _objectSpread2(_objectSpread2({}, placementsRtl), builtinPlacements) : _objectSpread2(_objectSpread2({}, placements$1), builtinPlacements);
|
|
36664
36663
|
var popupPlacement = popupPlacementMap[mode];
|
|
36665
36664
|
var targetMotion = getMotion(mode, motion, defaultMotions);
|
|
36666
36665
|
var targetMotionRef = React__namespace.useRef(targetMotion);
|
|
@@ -37507,7 +37506,7 @@ var Menu$1 = /*#__PURE__*/React__namespace.forwardRef(function (props, ref) {
|
|
|
37507
37506
|
return !subPathKeys.has(k);
|
|
37508
37507
|
});
|
|
37509
37508
|
}
|
|
37510
|
-
if (!isEqual(mergedOpenKeys, newOpenKeys, true)) {
|
|
37509
|
+
if (!isEqual$1(mergedOpenKeys, newOpenKeys, true)) {
|
|
37511
37510
|
triggerOpenKeys(newOpenKeys, true);
|
|
37512
37511
|
}
|
|
37513
37512
|
});
|
|
@@ -47290,23 +47289,26 @@ const genBorderlessStyle = (token, extraStyles) => {
|
|
|
47290
47289
|
};
|
|
47291
47290
|
};
|
|
47292
47291
|
/* ============== Filled ============== */
|
|
47293
|
-
const genBaseFilledStyle = (token, options) =>
|
|
47294
|
-
|
|
47295
|
-
|
|
47296
|
-
|
|
47297
|
-
|
|
47298
|
-
|
|
47299
|
-
|
|
47300
|
-
|
|
47301
|
-
|
|
47302
|
-
|
|
47303
|
-
|
|
47304
|
-
|
|
47305
|
-
|
|
47306
|
-
|
|
47307
|
-
|
|
47308
|
-
|
|
47309
|
-
|
|
47292
|
+
const genBaseFilledStyle = (token, options) => {
|
|
47293
|
+
var _a;
|
|
47294
|
+
return {
|
|
47295
|
+
background: options.bg,
|
|
47296
|
+
borderWidth: token.lineWidth,
|
|
47297
|
+
borderStyle: token.lineType,
|
|
47298
|
+
borderColor: 'transparent',
|
|
47299
|
+
'input&, & input, textarea&, & textarea': {
|
|
47300
|
+
color: (_a = options === null || options === void 0 ? void 0 : options.inputColor) !== null && _a !== void 0 ? _a : 'unset'
|
|
47301
|
+
},
|
|
47302
|
+
'&:hover': {
|
|
47303
|
+
background: options.hoverBg
|
|
47304
|
+
},
|
|
47305
|
+
'&:focus, &:focus-within': {
|
|
47306
|
+
outline: 0,
|
|
47307
|
+
borderColor: options.activeBorderColor,
|
|
47308
|
+
backgroundColor: token.activeBg
|
|
47309
|
+
}
|
|
47310
|
+
};
|
|
47311
|
+
};
|
|
47310
47312
|
const genFilledStatusStyle = (token, options) => ({
|
|
47311
47313
|
[`&${token.componentCls}-status-${options.status}:not(${token.componentCls}-disabled)`]: Object.assign(Object.assign({}, genBaseFilledStyle(token, options)), {
|
|
47312
47314
|
[`${token.componentCls}-prefix, ${token.componentCls}-suffix`]: {
|
|
@@ -47497,17 +47499,6 @@ const genBasicInputStyle = token => Object.assign(Object.assign({
|
|
|
47497
47499
|
borderRadius: token.borderRadius,
|
|
47498
47500
|
transition: `all ${token.motionDurationMid}`
|
|
47499
47501
|
}, genPlaceholderStyle(token.colorTextPlaceholder)), {
|
|
47500
|
-
// Reset height for `textarea`s
|
|
47501
|
-
'textarea&': {
|
|
47502
|
-
maxWidth: '100%',
|
|
47503
|
-
// prevent textarea resize from coming out of its container
|
|
47504
|
-
height: 'auto',
|
|
47505
|
-
minHeight: token.controlHeight,
|
|
47506
|
-
lineHeight: token.lineHeight,
|
|
47507
|
-
verticalAlign: 'bottom',
|
|
47508
|
-
transition: `all ${token.motionDurationSlow}, height 0s`,
|
|
47509
|
-
resize: 'vertical'
|
|
47510
|
-
},
|
|
47511
47502
|
// Size
|
|
47512
47503
|
'&-lg': Object.assign({}, genInputLargeStyle(token)),
|
|
47513
47504
|
'&-sm': Object.assign({}, genInputSmallStyle(token)),
|
|
@@ -47771,7 +47762,7 @@ const genInputStyle = token => {
|
|
|
47771
47762
|
}
|
|
47772
47763
|
},
|
|
47773
47764
|
'&[type="search"]::-webkit-search-cancel-button, &[type="search"]::-webkit-search-decoration': {
|
|
47774
|
-
|
|
47765
|
+
appearance: 'none'
|
|
47775
47766
|
}
|
|
47776
47767
|
})
|
|
47777
47768
|
};
|
|
@@ -48482,8 +48473,8 @@ const genPanelStyle = token => {
|
|
|
48482
48473
|
width: pickerControlIconSize,
|
|
48483
48474
|
height: pickerControlIconSize,
|
|
48484
48475
|
border: `0 solid currentcolor`,
|
|
48485
|
-
|
|
48486
|
-
|
|
48476
|
+
borderBlockStartWidth: pickerControlIconBorderWidth,
|
|
48477
|
+
borderInlineStartWidth: pickerControlIconBorderWidth,
|
|
48487
48478
|
content: '""'
|
|
48488
48479
|
}
|
|
48489
48480
|
},
|
|
@@ -48497,8 +48488,8 @@ const genPanelStyle = token => {
|
|
|
48497
48488
|
width: pickerControlIconSize,
|
|
48498
48489
|
height: pickerControlIconSize,
|
|
48499
48490
|
border: '0 solid currentcolor',
|
|
48500
|
-
|
|
48501
|
-
|
|
48491
|
+
borderBlockStartWidth: pickerControlIconBorderWidth,
|
|
48492
|
+
borderInlineStartWidth: pickerControlIconBorderWidth,
|
|
48502
48493
|
content: '""'
|
|
48503
48494
|
}
|
|
48504
48495
|
},
|
|
@@ -49486,7 +49477,7 @@ function throttle (delay, callback, options) {
|
|
|
49486
49477
|
*
|
|
49487
49478
|
* @returns {Function} A new, debounced function.
|
|
49488
49479
|
*/
|
|
49489
|
-
function debounce (delay, callback, options) {
|
|
49480
|
+
function debounce$1 (delay, callback, options) {
|
|
49490
49481
|
var _ref = {},
|
|
49491
49482
|
_ref$atBegin = _ref.atBegin,
|
|
49492
49483
|
atBegin = _ref$atBegin === void 0 ? false : _ref$atBegin;
|
|
@@ -52576,6 +52567,7 @@ const genPaginationDisabledStyle = token => {
|
|
|
52576
52567
|
cursor: 'not-allowed',
|
|
52577
52568
|
[`${componentCls}-item`]: {
|
|
52578
52569
|
cursor: 'not-allowed',
|
|
52570
|
+
backgroundColor: 'transparent',
|
|
52579
52571
|
'&:hover, &:active': {
|
|
52580
52572
|
backgroundColor: 'transparent'
|
|
52581
52573
|
},
|
|
@@ -52647,16 +52639,6 @@ const genPaginationMiniStyle = token => {
|
|
|
52647
52639
|
margin: 0,
|
|
52648
52640
|
lineHeight: unit$1(token.calc(token.itemSizeSM).sub(2).equal())
|
|
52649
52641
|
},
|
|
52650
|
-
[`&${componentCls}-mini:not(${componentCls}-disabled) ${componentCls}-item:not(${componentCls}-item-active)`]: {
|
|
52651
|
-
backgroundColor: 'transparent',
|
|
52652
|
-
borderColor: 'transparent',
|
|
52653
|
-
'&:hover': {
|
|
52654
|
-
backgroundColor: token.colorBgTextHover
|
|
52655
|
-
},
|
|
52656
|
-
'&:active': {
|
|
52657
|
-
backgroundColor: token.colorBgTextActive
|
|
52658
|
-
}
|
|
52659
|
-
},
|
|
52660
52642
|
[`&${componentCls}-mini ${componentCls}-prev, &${componentCls}-mini ${componentCls}-next`]: {
|
|
52661
52643
|
minWidth: token.itemSizeSM,
|
|
52662
52644
|
height: token.itemSizeSM,
|
|
@@ -53792,7 +53774,7 @@ const Spin = props => {
|
|
|
53792
53774
|
const mergedPercent = usePercent(spinning, percent);
|
|
53793
53775
|
React__namespace.useEffect(() => {
|
|
53794
53776
|
if (customSpinning) {
|
|
53795
|
-
const showSpinning = debounce(delay, () => {
|
|
53777
|
+
const showSpinning = debounce$1(delay, () => {
|
|
53796
53778
|
setSpinning(true);
|
|
53797
53779
|
});
|
|
53798
53780
|
showSpinning();
|
|
@@ -54093,7 +54075,7 @@ function useContext(holder, selector) {
|
|
|
54093
54075
|
}
|
|
54094
54076
|
function trigger(nextValue) {
|
|
54095
54077
|
var nextSelectorValue = eventSelector(nextValue);
|
|
54096
|
-
if (!isEqual(valueRef.current, nextSelectorValue, true)) {
|
|
54078
|
+
if (!isEqual$1(valueRef.current, nextSelectorValue, true)) {
|
|
54097
54079
|
forceUpdate({});
|
|
54098
54080
|
}
|
|
54099
54081
|
}
|
|
@@ -54311,7 +54293,7 @@ function useCellRender(record, dataIndex, renderIndex, children, render, shouldC
|
|
|
54311
54293
|
if (perfRecord.renderWithProps) {
|
|
54312
54294
|
return true;
|
|
54313
54295
|
}
|
|
54314
|
-
return !isEqual(prev, next, true);
|
|
54296
|
+
return !isEqual$1(prev, next, true);
|
|
54315
54297
|
});
|
|
54316
54298
|
return retData;
|
|
54317
54299
|
}
|
|
@@ -55837,7 +55819,7 @@ function useFixedInfo(flattenColumns, stickyOffsets, direction) {
|
|
|
55837
55819
|
return useMemo(function () {
|
|
55838
55820
|
return fixedInfoList;
|
|
55839
55821
|
}, [fixedInfoList], function (prev, next) {
|
|
55840
|
-
return !isEqual(prev, next);
|
|
55822
|
+
return !isEqual$1(prev, next);
|
|
55841
55823
|
});
|
|
55842
55824
|
}
|
|
55843
55825
|
|
|
@@ -56118,7 +56100,7 @@ var StickyScrollBar = function StickyScrollBar(_ref, ref) {
|
|
|
56118
56100
|
React__namespace.useEffect(function () {
|
|
56119
56101
|
if (!scrollBodyRef.current) return;
|
|
56120
56102
|
var scrollParents = [];
|
|
56121
|
-
var parent = scrollBodyRef.current;
|
|
56103
|
+
var parent = getDOM(scrollBodyRef.current);
|
|
56122
56104
|
while (parent) {
|
|
56123
56105
|
scrollParents.push(parent);
|
|
56124
56106
|
parent = parent.parentElement;
|
|
@@ -60648,7 +60630,8 @@ const genBaseStyle$1 = (prefixCls, token) => {
|
|
|
60648
60630
|
};
|
|
60649
60631
|
};
|
|
60650
60632
|
// ============================== Merged ==============================
|
|
60651
|
-
const genTreeStyle = (prefixCls, token)
|
|
60633
|
+
const genTreeStyle = function (prefixCls, token) {
|
|
60634
|
+
let enableDirectory = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
|
|
60652
60635
|
const treeCls = `.${prefixCls}`;
|
|
60653
60636
|
const treeNodeCls = `${treeCls}-treenode`;
|
|
60654
60637
|
const treeNodePadding = token.calc(token.paddingXS).div(2).equal();
|
|
@@ -60661,7 +60644,7 @@ const genTreeStyle = (prefixCls, token) => {
|
|
|
60661
60644
|
// Basic
|
|
60662
60645
|
genBaseStyle$1(prefixCls, treeToken),
|
|
60663
60646
|
// Directory
|
|
60664
|
-
genDirectoryStyle(treeToken)];
|
|
60647
|
+
enableDirectory && genDirectoryStyle(treeToken)].filter(Boolean);
|
|
60665
60648
|
};
|
|
60666
60649
|
const initComponentToken = token => {
|
|
60667
60650
|
const {
|
|
@@ -60698,7 +60681,7 @@ var useStyle$2 = genStyleHooks('Tree', (token, _ref) => {
|
|
|
60698
60681
|
}, genTreeStyle(prefixCls, token), genCollapseMotion(token)];
|
|
60699
60682
|
}, prepareComponentToken$2);
|
|
60700
60683
|
|
|
60701
|
-
const offset = 4;
|
|
60684
|
+
const offset$2 = 4;
|
|
60702
60685
|
function dropIndicatorRender(props) {
|
|
60703
60686
|
const {
|
|
60704
60687
|
dropPosition,
|
|
@@ -60710,7 +60693,7 @@ function dropIndicatorRender(props) {
|
|
|
60710
60693
|
const startPosition = direction === 'ltr' ? 'left' : 'right';
|
|
60711
60694
|
const endPosition = direction === 'ltr' ? 'right' : 'left';
|
|
60712
60695
|
const style = {
|
|
60713
|
-
[startPosition]: -dropLevelOffset * indent + offset,
|
|
60696
|
+
[startPosition]: -dropLevelOffset * indent + offset$2,
|
|
60714
60697
|
[endPosition]: 0
|
|
60715
60698
|
};
|
|
60716
60699
|
switch (dropPosition) {
|
|
@@ -60723,7 +60706,7 @@ function dropIndicatorRender(props) {
|
|
|
60723
60706
|
default:
|
|
60724
60707
|
// dropPosition === 0
|
|
60725
60708
|
style.bottom = -3;
|
|
60726
|
-
style[startPosition] = indent + offset;
|
|
60709
|
+
style[startPosition] = indent + offset$2;
|
|
60727
60710
|
break;
|
|
60728
60711
|
}
|
|
60729
60712
|
return /*#__PURE__*/React.createElement("div", {
|
|
@@ -61350,7 +61333,7 @@ const FilterDropdown = props => {
|
|
|
61350
61333
|
if (mergedKeys === null && (!filterState || !filterState.filteredKeys)) {
|
|
61351
61334
|
return null;
|
|
61352
61335
|
}
|
|
61353
|
-
if (isEqual(mergedKeys, filterState === null || filterState === void 0 ? void 0 : filterState.filteredKeys, true)) {
|
|
61336
|
+
if (isEqual$1(mergedKeys, filterState === null || filterState === void 0 ? void 0 : filterState.filteredKeys, true)) {
|
|
61354
61337
|
return null;
|
|
61355
61338
|
}
|
|
61356
61339
|
triggerFilter({
|
|
@@ -61556,7 +61539,7 @@ const FilterDropdown = props => {
|
|
|
61556
61539
|
};
|
|
61557
61540
|
const getResetDisabled = () => {
|
|
61558
61541
|
if (filterResetToDefaultFilteredValue) {
|
|
61559
|
-
return isEqual((defaultFilteredValue || []).map(key => String(key)), selectedKeys, true);
|
|
61542
|
+
return isEqual$1((defaultFilteredValue || []).map(key => String(key)), selectedKeys, true);
|
|
61560
61543
|
}
|
|
61561
61544
|
return selectedKeys.length === 0;
|
|
61562
61545
|
};
|
|
@@ -63309,7 +63292,7 @@ const genStickyStyle = token => {
|
|
|
63309
63292
|
height: tableScrollThumbSize,
|
|
63310
63293
|
backgroundColor: tableScrollThumbBg,
|
|
63311
63294
|
borderRadius: stickyScrollBarBorderRadius,
|
|
63312
|
-
transition: `all ${token.motionDurationSlow}, transform
|
|
63295
|
+
transition: `all ${token.motionDurationSlow}, transform 0s`,
|
|
63313
63296
|
position: 'absolute',
|
|
63314
63297
|
bottom: 0,
|
|
63315
63298
|
'&:hover, &-active': {
|
|
@@ -65150,6 +65133,2053 @@ const FISBadge = ({ className, icon, label, size = "sm", color, status, type = "
|
|
|
65150
65133
|
};
|
|
65151
65134
|
FISBadge.displayName = "FISBadge";
|
|
65152
65135
|
|
|
65136
|
+
/**
|
|
65137
|
+
* Simple ponyfill for Object.fromEntries
|
|
65138
|
+
*/
|
|
65139
|
+
|
|
65140
|
+
var fromEntries = function fromEntries(entries) {
|
|
65141
|
+
return entries.reduce(function (acc, _ref) {
|
|
65142
|
+
var key = _ref[0],
|
|
65143
|
+
value = _ref[1];
|
|
65144
|
+
acc[key] = value;
|
|
65145
|
+
return acc;
|
|
65146
|
+
}, {});
|
|
65147
|
+
};
|
|
65148
|
+
/**
|
|
65149
|
+
* Small wrapper around `useLayoutEffect` to get rid of the warning on SSR envs
|
|
65150
|
+
*/
|
|
65151
|
+
|
|
65152
|
+
var useIsomorphicLayoutEffect = typeof window !== 'undefined' && window.document && window.document.createElement ? React__namespace.useLayoutEffect : React__namespace.useEffect;
|
|
65153
|
+
|
|
65154
|
+
var top = 'top';
|
|
65155
|
+
var bottom = 'bottom';
|
|
65156
|
+
var right = 'right';
|
|
65157
|
+
var left = 'left';
|
|
65158
|
+
var auto = 'auto';
|
|
65159
|
+
var basePlacements = [top, bottom, right, left];
|
|
65160
|
+
var start = 'start';
|
|
65161
|
+
var end = 'end';
|
|
65162
|
+
var clippingParents = 'clippingParents';
|
|
65163
|
+
var viewport = 'viewport';
|
|
65164
|
+
var popper = 'popper';
|
|
65165
|
+
var reference = 'reference';
|
|
65166
|
+
var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {
|
|
65167
|
+
return acc.concat([placement + "-" + start, placement + "-" + end]);
|
|
65168
|
+
}, []);
|
|
65169
|
+
var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {
|
|
65170
|
+
return acc.concat([placement, placement + "-" + start, placement + "-" + end]);
|
|
65171
|
+
}, []); // modifiers that need to read the DOM
|
|
65172
|
+
|
|
65173
|
+
var beforeRead = 'beforeRead';
|
|
65174
|
+
var read = 'read';
|
|
65175
|
+
var afterRead = 'afterRead'; // pure-logic modifiers
|
|
65176
|
+
|
|
65177
|
+
var beforeMain = 'beforeMain';
|
|
65178
|
+
var main = 'main';
|
|
65179
|
+
var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)
|
|
65180
|
+
|
|
65181
|
+
var beforeWrite = 'beforeWrite';
|
|
65182
|
+
var write = 'write';
|
|
65183
|
+
var afterWrite = 'afterWrite';
|
|
65184
|
+
var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];
|
|
65185
|
+
|
|
65186
|
+
function getNodeName(element) {
|
|
65187
|
+
return element ? (element.nodeName || '').toLowerCase() : null;
|
|
65188
|
+
}
|
|
65189
|
+
|
|
65190
|
+
function getWindow(node) {
|
|
65191
|
+
if (node == null) {
|
|
65192
|
+
return window;
|
|
65193
|
+
}
|
|
65194
|
+
|
|
65195
|
+
if (node.toString() !== '[object Window]') {
|
|
65196
|
+
var ownerDocument = node.ownerDocument;
|
|
65197
|
+
return ownerDocument ? ownerDocument.defaultView || window : window;
|
|
65198
|
+
}
|
|
65199
|
+
|
|
65200
|
+
return node;
|
|
65201
|
+
}
|
|
65202
|
+
|
|
65203
|
+
function isElement(node) {
|
|
65204
|
+
var OwnElement = getWindow(node).Element;
|
|
65205
|
+
return node instanceof OwnElement || node instanceof Element;
|
|
65206
|
+
}
|
|
65207
|
+
|
|
65208
|
+
function isHTMLElement(node) {
|
|
65209
|
+
var OwnElement = getWindow(node).HTMLElement;
|
|
65210
|
+
return node instanceof OwnElement || node instanceof HTMLElement;
|
|
65211
|
+
}
|
|
65212
|
+
|
|
65213
|
+
function isShadowRoot(node) {
|
|
65214
|
+
// IE 11 has no ShadowRoot
|
|
65215
|
+
if (typeof ShadowRoot === 'undefined') {
|
|
65216
|
+
return false;
|
|
65217
|
+
}
|
|
65218
|
+
|
|
65219
|
+
var OwnElement = getWindow(node).ShadowRoot;
|
|
65220
|
+
return node instanceof OwnElement || node instanceof ShadowRoot;
|
|
65221
|
+
}
|
|
65222
|
+
|
|
65223
|
+
// and applies them to the HTMLElements such as popper and arrow
|
|
65224
|
+
|
|
65225
|
+
function applyStyles(_ref) {
|
|
65226
|
+
var state = _ref.state;
|
|
65227
|
+
Object.keys(state.elements).forEach(function (name) {
|
|
65228
|
+
var style = state.styles[name] || {};
|
|
65229
|
+
var attributes = state.attributes[name] || {};
|
|
65230
|
+
var element = state.elements[name]; // arrow is optional + virtual elements
|
|
65231
|
+
|
|
65232
|
+
if (!isHTMLElement(element) || !getNodeName(element)) {
|
|
65233
|
+
return;
|
|
65234
|
+
} // Flow doesn't support to extend this property, but it's the most
|
|
65235
|
+
// effective way to apply styles to an HTMLElement
|
|
65236
|
+
// $FlowFixMe[cannot-write]
|
|
65237
|
+
|
|
65238
|
+
|
|
65239
|
+
Object.assign(element.style, style);
|
|
65240
|
+
Object.keys(attributes).forEach(function (name) {
|
|
65241
|
+
var value = attributes[name];
|
|
65242
|
+
|
|
65243
|
+
if (value === false) {
|
|
65244
|
+
element.removeAttribute(name);
|
|
65245
|
+
} else {
|
|
65246
|
+
element.setAttribute(name, value === true ? '' : value);
|
|
65247
|
+
}
|
|
65248
|
+
});
|
|
65249
|
+
});
|
|
65250
|
+
}
|
|
65251
|
+
|
|
65252
|
+
function effect$2(_ref2) {
|
|
65253
|
+
var state = _ref2.state;
|
|
65254
|
+
var initialStyles = {
|
|
65255
|
+
popper: {
|
|
65256
|
+
position: state.options.strategy,
|
|
65257
|
+
left: '0',
|
|
65258
|
+
top: '0',
|
|
65259
|
+
margin: '0'
|
|
65260
|
+
},
|
|
65261
|
+
arrow: {
|
|
65262
|
+
position: 'absolute'
|
|
65263
|
+
},
|
|
65264
|
+
reference: {}
|
|
65265
|
+
};
|
|
65266
|
+
Object.assign(state.elements.popper.style, initialStyles.popper);
|
|
65267
|
+
state.styles = initialStyles;
|
|
65268
|
+
|
|
65269
|
+
if (state.elements.arrow) {
|
|
65270
|
+
Object.assign(state.elements.arrow.style, initialStyles.arrow);
|
|
65271
|
+
}
|
|
65272
|
+
|
|
65273
|
+
return function () {
|
|
65274
|
+
Object.keys(state.elements).forEach(function (name) {
|
|
65275
|
+
var element = state.elements[name];
|
|
65276
|
+
var attributes = state.attributes[name] || {};
|
|
65277
|
+
var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them
|
|
65278
|
+
|
|
65279
|
+
var style = styleProperties.reduce(function (style, property) {
|
|
65280
|
+
style[property] = '';
|
|
65281
|
+
return style;
|
|
65282
|
+
}, {}); // arrow is optional + virtual elements
|
|
65283
|
+
|
|
65284
|
+
if (!isHTMLElement(element) || !getNodeName(element)) {
|
|
65285
|
+
return;
|
|
65286
|
+
}
|
|
65287
|
+
|
|
65288
|
+
Object.assign(element.style, style);
|
|
65289
|
+
Object.keys(attributes).forEach(function (attribute) {
|
|
65290
|
+
element.removeAttribute(attribute);
|
|
65291
|
+
});
|
|
65292
|
+
});
|
|
65293
|
+
};
|
|
65294
|
+
} // eslint-disable-next-line import/no-unused-modules
|
|
65295
|
+
|
|
65296
|
+
|
|
65297
|
+
var applyStyles$1 = {
|
|
65298
|
+
name: 'applyStyles',
|
|
65299
|
+
enabled: true,
|
|
65300
|
+
phase: 'write',
|
|
65301
|
+
fn: applyStyles,
|
|
65302
|
+
effect: effect$2,
|
|
65303
|
+
requires: ['computeStyles']
|
|
65304
|
+
};
|
|
65305
|
+
|
|
65306
|
+
function getBasePlacement(placement) {
|
|
65307
|
+
return placement.split('-')[0];
|
|
65308
|
+
}
|
|
65309
|
+
|
|
65310
|
+
var max = Math.max;
|
|
65311
|
+
var min = Math.min;
|
|
65312
|
+
var round = Math.round;
|
|
65313
|
+
|
|
65314
|
+
function getUAString() {
|
|
65315
|
+
var uaData = navigator.userAgentData;
|
|
65316
|
+
|
|
65317
|
+
if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {
|
|
65318
|
+
return uaData.brands.map(function (item) {
|
|
65319
|
+
return item.brand + "/" + item.version;
|
|
65320
|
+
}).join(' ');
|
|
65321
|
+
}
|
|
65322
|
+
|
|
65323
|
+
return navigator.userAgent;
|
|
65324
|
+
}
|
|
65325
|
+
|
|
65326
|
+
function isLayoutViewport() {
|
|
65327
|
+
return !/^((?!chrome|android).)*safari/i.test(getUAString());
|
|
65328
|
+
}
|
|
65329
|
+
|
|
65330
|
+
function getBoundingClientRect(element, includeScale, isFixedStrategy) {
|
|
65331
|
+
if (includeScale === void 0) {
|
|
65332
|
+
includeScale = false;
|
|
65333
|
+
}
|
|
65334
|
+
|
|
65335
|
+
if (isFixedStrategy === void 0) {
|
|
65336
|
+
isFixedStrategy = false;
|
|
65337
|
+
}
|
|
65338
|
+
|
|
65339
|
+
var clientRect = element.getBoundingClientRect();
|
|
65340
|
+
var scaleX = 1;
|
|
65341
|
+
var scaleY = 1;
|
|
65342
|
+
|
|
65343
|
+
if (includeScale && isHTMLElement(element)) {
|
|
65344
|
+
scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;
|
|
65345
|
+
scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;
|
|
65346
|
+
}
|
|
65347
|
+
|
|
65348
|
+
var _ref = isElement(element) ? getWindow(element) : window,
|
|
65349
|
+
visualViewport = _ref.visualViewport;
|
|
65350
|
+
|
|
65351
|
+
var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;
|
|
65352
|
+
var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;
|
|
65353
|
+
var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;
|
|
65354
|
+
var width = clientRect.width / scaleX;
|
|
65355
|
+
var height = clientRect.height / scaleY;
|
|
65356
|
+
return {
|
|
65357
|
+
width: width,
|
|
65358
|
+
height: height,
|
|
65359
|
+
top: y,
|
|
65360
|
+
right: x + width,
|
|
65361
|
+
bottom: y + height,
|
|
65362
|
+
left: x,
|
|
65363
|
+
x: x,
|
|
65364
|
+
y: y
|
|
65365
|
+
};
|
|
65366
|
+
}
|
|
65367
|
+
|
|
65368
|
+
// means it doesn't take into account transforms.
|
|
65369
|
+
|
|
65370
|
+
function getLayoutRect(element) {
|
|
65371
|
+
var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.
|
|
65372
|
+
// Fixes https://github.com/popperjs/popper-core/issues/1223
|
|
65373
|
+
|
|
65374
|
+
var width = element.offsetWidth;
|
|
65375
|
+
var height = element.offsetHeight;
|
|
65376
|
+
|
|
65377
|
+
if (Math.abs(clientRect.width - width) <= 1) {
|
|
65378
|
+
width = clientRect.width;
|
|
65379
|
+
}
|
|
65380
|
+
|
|
65381
|
+
if (Math.abs(clientRect.height - height) <= 1) {
|
|
65382
|
+
height = clientRect.height;
|
|
65383
|
+
}
|
|
65384
|
+
|
|
65385
|
+
return {
|
|
65386
|
+
x: element.offsetLeft,
|
|
65387
|
+
y: element.offsetTop,
|
|
65388
|
+
width: width,
|
|
65389
|
+
height: height
|
|
65390
|
+
};
|
|
65391
|
+
}
|
|
65392
|
+
|
|
65393
|
+
function contains(parent, child) {
|
|
65394
|
+
var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method
|
|
65395
|
+
|
|
65396
|
+
if (parent.contains(child)) {
|
|
65397
|
+
return true;
|
|
65398
|
+
} // then fallback to custom implementation with Shadow DOM support
|
|
65399
|
+
else if (rootNode && isShadowRoot(rootNode)) {
|
|
65400
|
+
var next = child;
|
|
65401
|
+
|
|
65402
|
+
do {
|
|
65403
|
+
if (next && parent.isSameNode(next)) {
|
|
65404
|
+
return true;
|
|
65405
|
+
} // $FlowFixMe[prop-missing]: need a better way to handle this...
|
|
65406
|
+
|
|
65407
|
+
|
|
65408
|
+
next = next.parentNode || next.host;
|
|
65409
|
+
} while (next);
|
|
65410
|
+
} // Give up, the result is false
|
|
65411
|
+
|
|
65412
|
+
|
|
65413
|
+
return false;
|
|
65414
|
+
}
|
|
65415
|
+
|
|
65416
|
+
function getComputedStyle$1(element) {
|
|
65417
|
+
return getWindow(element).getComputedStyle(element);
|
|
65418
|
+
}
|
|
65419
|
+
|
|
65420
|
+
function isTableElement(element) {
|
|
65421
|
+
return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;
|
|
65422
|
+
}
|
|
65423
|
+
|
|
65424
|
+
function getDocumentElement(element) {
|
|
65425
|
+
// $FlowFixMe[incompatible-return]: assume body is always available
|
|
65426
|
+
return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]
|
|
65427
|
+
element.document) || window.document).documentElement;
|
|
65428
|
+
}
|
|
65429
|
+
|
|
65430
|
+
function getParentNode(element) {
|
|
65431
|
+
if (getNodeName(element) === 'html') {
|
|
65432
|
+
return element;
|
|
65433
|
+
}
|
|
65434
|
+
|
|
65435
|
+
return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle
|
|
65436
|
+
// $FlowFixMe[incompatible-return]
|
|
65437
|
+
// $FlowFixMe[prop-missing]
|
|
65438
|
+
element.assignedSlot || // step into the shadow DOM of the parent of a slotted node
|
|
65439
|
+
element.parentNode || ( // DOM Element detected
|
|
65440
|
+
isShadowRoot(element) ? element.host : null) || // ShadowRoot detected
|
|
65441
|
+
// $FlowFixMe[incompatible-call]: HTMLElement is a Node
|
|
65442
|
+
getDocumentElement(element) // fallback
|
|
65443
|
+
|
|
65444
|
+
);
|
|
65445
|
+
}
|
|
65446
|
+
|
|
65447
|
+
function getTrueOffsetParent(element) {
|
|
65448
|
+
if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837
|
|
65449
|
+
getComputedStyle$1(element).position === 'fixed') {
|
|
65450
|
+
return null;
|
|
65451
|
+
}
|
|
65452
|
+
|
|
65453
|
+
return element.offsetParent;
|
|
65454
|
+
} // `.offsetParent` reports `null` for fixed elements, while absolute elements
|
|
65455
|
+
// return the containing block
|
|
65456
|
+
|
|
65457
|
+
|
|
65458
|
+
function getContainingBlock(element) {
|
|
65459
|
+
var isFirefox = /firefox/i.test(getUAString());
|
|
65460
|
+
var isIE = /Trident/i.test(getUAString());
|
|
65461
|
+
|
|
65462
|
+
if (isIE && isHTMLElement(element)) {
|
|
65463
|
+
// In IE 9, 10 and 11 fixed elements containing block is always established by the viewport
|
|
65464
|
+
var elementCss = getComputedStyle$1(element);
|
|
65465
|
+
|
|
65466
|
+
if (elementCss.position === 'fixed') {
|
|
65467
|
+
return null;
|
|
65468
|
+
}
|
|
65469
|
+
}
|
|
65470
|
+
|
|
65471
|
+
var currentNode = getParentNode(element);
|
|
65472
|
+
|
|
65473
|
+
if (isShadowRoot(currentNode)) {
|
|
65474
|
+
currentNode = currentNode.host;
|
|
65475
|
+
}
|
|
65476
|
+
|
|
65477
|
+
while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {
|
|
65478
|
+
var css = getComputedStyle$1(currentNode); // This is non-exhaustive but covers the most common CSS properties that
|
|
65479
|
+
// create a containing block.
|
|
65480
|
+
// https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block
|
|
65481
|
+
|
|
65482
|
+
if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {
|
|
65483
|
+
return currentNode;
|
|
65484
|
+
} else {
|
|
65485
|
+
currentNode = currentNode.parentNode;
|
|
65486
|
+
}
|
|
65487
|
+
}
|
|
65488
|
+
|
|
65489
|
+
return null;
|
|
65490
|
+
} // Gets the closest ancestor positioned element. Handles some edge cases,
|
|
65491
|
+
// such as table ancestors and cross browser bugs.
|
|
65492
|
+
|
|
65493
|
+
|
|
65494
|
+
function getOffsetParent(element) {
|
|
65495
|
+
var window = getWindow(element);
|
|
65496
|
+
var offsetParent = getTrueOffsetParent(element);
|
|
65497
|
+
|
|
65498
|
+
while (offsetParent && isTableElement(offsetParent) && getComputedStyle$1(offsetParent).position === 'static') {
|
|
65499
|
+
offsetParent = getTrueOffsetParent(offsetParent);
|
|
65500
|
+
}
|
|
65501
|
+
|
|
65502
|
+
if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle$1(offsetParent).position === 'static')) {
|
|
65503
|
+
return window;
|
|
65504
|
+
}
|
|
65505
|
+
|
|
65506
|
+
return offsetParent || getContainingBlock(element) || window;
|
|
65507
|
+
}
|
|
65508
|
+
|
|
65509
|
+
function getMainAxisFromPlacement(placement) {
|
|
65510
|
+
return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';
|
|
65511
|
+
}
|
|
65512
|
+
|
|
65513
|
+
function within(min$1, value, max$1) {
|
|
65514
|
+
return max(min$1, min(value, max$1));
|
|
65515
|
+
}
|
|
65516
|
+
function withinMaxClamp(min, value, max) {
|
|
65517
|
+
var v = within(min, value, max);
|
|
65518
|
+
return v > max ? max : v;
|
|
65519
|
+
}
|
|
65520
|
+
|
|
65521
|
+
function getFreshSideObject() {
|
|
65522
|
+
return {
|
|
65523
|
+
top: 0,
|
|
65524
|
+
right: 0,
|
|
65525
|
+
bottom: 0,
|
|
65526
|
+
left: 0
|
|
65527
|
+
};
|
|
65528
|
+
}
|
|
65529
|
+
|
|
65530
|
+
function mergePaddingObject(paddingObject) {
|
|
65531
|
+
return Object.assign({}, getFreshSideObject(), paddingObject);
|
|
65532
|
+
}
|
|
65533
|
+
|
|
65534
|
+
function expandToHashMap(value, keys) {
|
|
65535
|
+
return keys.reduce(function (hashMap, key) {
|
|
65536
|
+
hashMap[key] = value;
|
|
65537
|
+
return hashMap;
|
|
65538
|
+
}, {});
|
|
65539
|
+
}
|
|
65540
|
+
|
|
65541
|
+
var toPaddingObject = function toPaddingObject(padding, state) {
|
|
65542
|
+
padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {
|
|
65543
|
+
placement: state.placement
|
|
65544
|
+
})) : padding;
|
|
65545
|
+
return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));
|
|
65546
|
+
};
|
|
65547
|
+
|
|
65548
|
+
function arrow(_ref) {
|
|
65549
|
+
var _state$modifiersData$;
|
|
65550
|
+
|
|
65551
|
+
var state = _ref.state,
|
|
65552
|
+
name = _ref.name,
|
|
65553
|
+
options = _ref.options;
|
|
65554
|
+
var arrowElement = state.elements.arrow;
|
|
65555
|
+
var popperOffsets = state.modifiersData.popperOffsets;
|
|
65556
|
+
var basePlacement = getBasePlacement(state.placement);
|
|
65557
|
+
var axis = getMainAxisFromPlacement(basePlacement);
|
|
65558
|
+
var isVertical = [left, right].indexOf(basePlacement) >= 0;
|
|
65559
|
+
var len = isVertical ? 'height' : 'width';
|
|
65560
|
+
|
|
65561
|
+
if (!arrowElement || !popperOffsets) {
|
|
65562
|
+
return;
|
|
65563
|
+
}
|
|
65564
|
+
|
|
65565
|
+
var paddingObject = toPaddingObject(options.padding, state);
|
|
65566
|
+
var arrowRect = getLayoutRect(arrowElement);
|
|
65567
|
+
var minProp = axis === 'y' ? top : left;
|
|
65568
|
+
var maxProp = axis === 'y' ? bottom : right;
|
|
65569
|
+
var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];
|
|
65570
|
+
var startDiff = popperOffsets[axis] - state.rects.reference[axis];
|
|
65571
|
+
var arrowOffsetParent = getOffsetParent(arrowElement);
|
|
65572
|
+
var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;
|
|
65573
|
+
var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is
|
|
65574
|
+
// outside of the popper bounds
|
|
65575
|
+
|
|
65576
|
+
var min = paddingObject[minProp];
|
|
65577
|
+
var max = clientSize - arrowRect[len] - paddingObject[maxProp];
|
|
65578
|
+
var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;
|
|
65579
|
+
var offset = within(min, center, max); // Prevents breaking syntax highlighting...
|
|
65580
|
+
|
|
65581
|
+
var axisProp = axis;
|
|
65582
|
+
state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);
|
|
65583
|
+
}
|
|
65584
|
+
|
|
65585
|
+
function effect$1(_ref2) {
|
|
65586
|
+
var state = _ref2.state,
|
|
65587
|
+
options = _ref2.options;
|
|
65588
|
+
var _options$element = options.element,
|
|
65589
|
+
arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;
|
|
65590
|
+
|
|
65591
|
+
if (arrowElement == null) {
|
|
65592
|
+
return;
|
|
65593
|
+
} // CSS selector
|
|
65594
|
+
|
|
65595
|
+
|
|
65596
|
+
if (typeof arrowElement === 'string') {
|
|
65597
|
+
arrowElement = state.elements.popper.querySelector(arrowElement);
|
|
65598
|
+
|
|
65599
|
+
if (!arrowElement) {
|
|
65600
|
+
return;
|
|
65601
|
+
}
|
|
65602
|
+
}
|
|
65603
|
+
|
|
65604
|
+
if (!contains(state.elements.popper, arrowElement)) {
|
|
65605
|
+
return;
|
|
65606
|
+
}
|
|
65607
|
+
|
|
65608
|
+
state.elements.arrow = arrowElement;
|
|
65609
|
+
} // eslint-disable-next-line import/no-unused-modules
|
|
65610
|
+
|
|
65611
|
+
|
|
65612
|
+
var arrow$1 = {
|
|
65613
|
+
name: 'arrow',
|
|
65614
|
+
enabled: true,
|
|
65615
|
+
phase: 'main',
|
|
65616
|
+
fn: arrow,
|
|
65617
|
+
effect: effect$1,
|
|
65618
|
+
requires: ['popperOffsets'],
|
|
65619
|
+
requiresIfExists: ['preventOverflow']
|
|
65620
|
+
};
|
|
65621
|
+
|
|
65622
|
+
function getVariation(placement) {
|
|
65623
|
+
return placement.split('-')[1];
|
|
65624
|
+
}
|
|
65625
|
+
|
|
65626
|
+
var unsetSides = {
|
|
65627
|
+
top: 'auto',
|
|
65628
|
+
right: 'auto',
|
|
65629
|
+
bottom: 'auto',
|
|
65630
|
+
left: 'auto'
|
|
65631
|
+
}; // Round the offsets to the nearest suitable subpixel based on the DPR.
|
|
65632
|
+
// Zooming can change the DPR, but it seems to report a value that will
|
|
65633
|
+
// cleanly divide the values into the appropriate subpixels.
|
|
65634
|
+
|
|
65635
|
+
function roundOffsetsByDPR(_ref, win) {
|
|
65636
|
+
var x = _ref.x,
|
|
65637
|
+
y = _ref.y;
|
|
65638
|
+
var dpr = win.devicePixelRatio || 1;
|
|
65639
|
+
return {
|
|
65640
|
+
x: round(x * dpr) / dpr || 0,
|
|
65641
|
+
y: round(y * dpr) / dpr || 0
|
|
65642
|
+
};
|
|
65643
|
+
}
|
|
65644
|
+
|
|
65645
|
+
function mapToStyles(_ref2) {
|
|
65646
|
+
var _Object$assign2;
|
|
65647
|
+
|
|
65648
|
+
var popper = _ref2.popper,
|
|
65649
|
+
popperRect = _ref2.popperRect,
|
|
65650
|
+
placement = _ref2.placement,
|
|
65651
|
+
variation = _ref2.variation,
|
|
65652
|
+
offsets = _ref2.offsets,
|
|
65653
|
+
position = _ref2.position,
|
|
65654
|
+
gpuAcceleration = _ref2.gpuAcceleration,
|
|
65655
|
+
adaptive = _ref2.adaptive,
|
|
65656
|
+
roundOffsets = _ref2.roundOffsets,
|
|
65657
|
+
isFixed = _ref2.isFixed;
|
|
65658
|
+
var _offsets$x = offsets.x,
|
|
65659
|
+
x = _offsets$x === void 0 ? 0 : _offsets$x,
|
|
65660
|
+
_offsets$y = offsets.y,
|
|
65661
|
+
y = _offsets$y === void 0 ? 0 : _offsets$y;
|
|
65662
|
+
|
|
65663
|
+
var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({
|
|
65664
|
+
x: x,
|
|
65665
|
+
y: y
|
|
65666
|
+
}) : {
|
|
65667
|
+
x: x,
|
|
65668
|
+
y: y
|
|
65669
|
+
};
|
|
65670
|
+
|
|
65671
|
+
x = _ref3.x;
|
|
65672
|
+
y = _ref3.y;
|
|
65673
|
+
var hasX = offsets.hasOwnProperty('x');
|
|
65674
|
+
var hasY = offsets.hasOwnProperty('y');
|
|
65675
|
+
var sideX = left;
|
|
65676
|
+
var sideY = top;
|
|
65677
|
+
var win = window;
|
|
65678
|
+
|
|
65679
|
+
if (adaptive) {
|
|
65680
|
+
var offsetParent = getOffsetParent(popper);
|
|
65681
|
+
var heightProp = 'clientHeight';
|
|
65682
|
+
var widthProp = 'clientWidth';
|
|
65683
|
+
|
|
65684
|
+
if (offsetParent === getWindow(popper)) {
|
|
65685
|
+
offsetParent = getDocumentElement(popper);
|
|
65686
|
+
|
|
65687
|
+
if (getComputedStyle$1(offsetParent).position !== 'static' && position === 'absolute') {
|
|
65688
|
+
heightProp = 'scrollHeight';
|
|
65689
|
+
widthProp = 'scrollWidth';
|
|
65690
|
+
}
|
|
65691
|
+
} // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it
|
|
65692
|
+
|
|
65693
|
+
|
|
65694
|
+
offsetParent = offsetParent;
|
|
65695
|
+
|
|
65696
|
+
if (placement === top || (placement === left || placement === right) && variation === end) {
|
|
65697
|
+
sideY = bottom;
|
|
65698
|
+
var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]
|
|
65699
|
+
offsetParent[heightProp];
|
|
65700
|
+
y -= offsetY - popperRect.height;
|
|
65701
|
+
y *= gpuAcceleration ? 1 : -1;
|
|
65702
|
+
}
|
|
65703
|
+
|
|
65704
|
+
if (placement === left || (placement === top || placement === bottom) && variation === end) {
|
|
65705
|
+
sideX = right;
|
|
65706
|
+
var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]
|
|
65707
|
+
offsetParent[widthProp];
|
|
65708
|
+
x -= offsetX - popperRect.width;
|
|
65709
|
+
x *= gpuAcceleration ? 1 : -1;
|
|
65710
|
+
}
|
|
65711
|
+
}
|
|
65712
|
+
|
|
65713
|
+
var commonStyles = Object.assign({
|
|
65714
|
+
position: position
|
|
65715
|
+
}, adaptive && unsetSides);
|
|
65716
|
+
|
|
65717
|
+
var _ref4 = roundOffsets === true ? roundOffsetsByDPR({
|
|
65718
|
+
x: x,
|
|
65719
|
+
y: y
|
|
65720
|
+
}, getWindow(popper)) : {
|
|
65721
|
+
x: x,
|
|
65722
|
+
y: y
|
|
65723
|
+
};
|
|
65724
|
+
|
|
65725
|
+
x = _ref4.x;
|
|
65726
|
+
y = _ref4.y;
|
|
65727
|
+
|
|
65728
|
+
if (gpuAcceleration) {
|
|
65729
|
+
var _Object$assign;
|
|
65730
|
+
|
|
65731
|
+
return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? "translate(" + x + "px, " + y + "px)" : "translate3d(" + x + "px, " + y + "px, 0)", _Object$assign));
|
|
65732
|
+
}
|
|
65733
|
+
|
|
65734
|
+
return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + "px" : '', _Object$assign2[sideX] = hasX ? x + "px" : '', _Object$assign2.transform = '', _Object$assign2));
|
|
65735
|
+
}
|
|
65736
|
+
|
|
65737
|
+
function computeStyles(_ref5) {
|
|
65738
|
+
var state = _ref5.state,
|
|
65739
|
+
options = _ref5.options;
|
|
65740
|
+
var _options$gpuAccelerat = options.gpuAcceleration,
|
|
65741
|
+
gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,
|
|
65742
|
+
_options$adaptive = options.adaptive,
|
|
65743
|
+
adaptive = _options$adaptive === void 0 ? true : _options$adaptive,
|
|
65744
|
+
_options$roundOffsets = options.roundOffsets,
|
|
65745
|
+
roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;
|
|
65746
|
+
var commonStyles = {
|
|
65747
|
+
placement: getBasePlacement(state.placement),
|
|
65748
|
+
variation: getVariation(state.placement),
|
|
65749
|
+
popper: state.elements.popper,
|
|
65750
|
+
popperRect: state.rects.popper,
|
|
65751
|
+
gpuAcceleration: gpuAcceleration,
|
|
65752
|
+
isFixed: state.options.strategy === 'fixed'
|
|
65753
|
+
};
|
|
65754
|
+
|
|
65755
|
+
if (state.modifiersData.popperOffsets != null) {
|
|
65756
|
+
state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {
|
|
65757
|
+
offsets: state.modifiersData.popperOffsets,
|
|
65758
|
+
position: state.options.strategy,
|
|
65759
|
+
adaptive: adaptive,
|
|
65760
|
+
roundOffsets: roundOffsets
|
|
65761
|
+
})));
|
|
65762
|
+
}
|
|
65763
|
+
|
|
65764
|
+
if (state.modifiersData.arrow != null) {
|
|
65765
|
+
state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {
|
|
65766
|
+
offsets: state.modifiersData.arrow,
|
|
65767
|
+
position: 'absolute',
|
|
65768
|
+
adaptive: false,
|
|
65769
|
+
roundOffsets: roundOffsets
|
|
65770
|
+
})));
|
|
65771
|
+
}
|
|
65772
|
+
|
|
65773
|
+
state.attributes.popper = Object.assign({}, state.attributes.popper, {
|
|
65774
|
+
'data-popper-placement': state.placement
|
|
65775
|
+
});
|
|
65776
|
+
} // eslint-disable-next-line import/no-unused-modules
|
|
65777
|
+
|
|
65778
|
+
|
|
65779
|
+
var computeStyles$1 = {
|
|
65780
|
+
name: 'computeStyles',
|
|
65781
|
+
enabled: true,
|
|
65782
|
+
phase: 'beforeWrite',
|
|
65783
|
+
fn: computeStyles,
|
|
65784
|
+
data: {}
|
|
65785
|
+
};
|
|
65786
|
+
|
|
65787
|
+
var passive = {
|
|
65788
|
+
passive: true
|
|
65789
|
+
};
|
|
65790
|
+
|
|
65791
|
+
function effect(_ref) {
|
|
65792
|
+
var state = _ref.state,
|
|
65793
|
+
instance = _ref.instance,
|
|
65794
|
+
options = _ref.options;
|
|
65795
|
+
var _options$scroll = options.scroll,
|
|
65796
|
+
scroll = _options$scroll === void 0 ? true : _options$scroll,
|
|
65797
|
+
_options$resize = options.resize,
|
|
65798
|
+
resize = _options$resize === void 0 ? true : _options$resize;
|
|
65799
|
+
var window = getWindow(state.elements.popper);
|
|
65800
|
+
var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);
|
|
65801
|
+
|
|
65802
|
+
if (scroll) {
|
|
65803
|
+
scrollParents.forEach(function (scrollParent) {
|
|
65804
|
+
scrollParent.addEventListener('scroll', instance.update, passive);
|
|
65805
|
+
});
|
|
65806
|
+
}
|
|
65807
|
+
|
|
65808
|
+
if (resize) {
|
|
65809
|
+
window.addEventListener('resize', instance.update, passive);
|
|
65810
|
+
}
|
|
65811
|
+
|
|
65812
|
+
return function () {
|
|
65813
|
+
if (scroll) {
|
|
65814
|
+
scrollParents.forEach(function (scrollParent) {
|
|
65815
|
+
scrollParent.removeEventListener('scroll', instance.update, passive);
|
|
65816
|
+
});
|
|
65817
|
+
}
|
|
65818
|
+
|
|
65819
|
+
if (resize) {
|
|
65820
|
+
window.removeEventListener('resize', instance.update, passive);
|
|
65821
|
+
}
|
|
65822
|
+
};
|
|
65823
|
+
} // eslint-disable-next-line import/no-unused-modules
|
|
65824
|
+
|
|
65825
|
+
|
|
65826
|
+
var eventListeners = {
|
|
65827
|
+
name: 'eventListeners',
|
|
65828
|
+
enabled: true,
|
|
65829
|
+
phase: 'write',
|
|
65830
|
+
fn: function fn() {},
|
|
65831
|
+
effect: effect,
|
|
65832
|
+
data: {}
|
|
65833
|
+
};
|
|
65834
|
+
|
|
65835
|
+
var hash$1 = {
|
|
65836
|
+
left: 'right',
|
|
65837
|
+
right: 'left',
|
|
65838
|
+
bottom: 'top',
|
|
65839
|
+
top: 'bottom'
|
|
65840
|
+
};
|
|
65841
|
+
function getOppositePlacement(placement) {
|
|
65842
|
+
return placement.replace(/left|right|bottom|top/g, function (matched) {
|
|
65843
|
+
return hash$1[matched];
|
|
65844
|
+
});
|
|
65845
|
+
}
|
|
65846
|
+
|
|
65847
|
+
var hash = {
|
|
65848
|
+
start: 'end',
|
|
65849
|
+
end: 'start'
|
|
65850
|
+
};
|
|
65851
|
+
function getOppositeVariationPlacement(placement) {
|
|
65852
|
+
return placement.replace(/start|end/g, function (matched) {
|
|
65853
|
+
return hash[matched];
|
|
65854
|
+
});
|
|
65855
|
+
}
|
|
65856
|
+
|
|
65857
|
+
function getWindowScroll(node) {
|
|
65858
|
+
var win = getWindow(node);
|
|
65859
|
+
var scrollLeft = win.pageXOffset;
|
|
65860
|
+
var scrollTop = win.pageYOffset;
|
|
65861
|
+
return {
|
|
65862
|
+
scrollLeft: scrollLeft,
|
|
65863
|
+
scrollTop: scrollTop
|
|
65864
|
+
};
|
|
65865
|
+
}
|
|
65866
|
+
|
|
65867
|
+
function getWindowScrollBarX(element) {
|
|
65868
|
+
// If <html> has a CSS width greater than the viewport, then this will be
|
|
65869
|
+
// incorrect for RTL.
|
|
65870
|
+
// Popper 1 is broken in this case and never had a bug report so let's assume
|
|
65871
|
+
// it's not an issue. I don't think anyone ever specifies width on <html>
|
|
65872
|
+
// anyway.
|
|
65873
|
+
// Browsers where the left scrollbar doesn't cause an issue report `0` for
|
|
65874
|
+
// this (e.g. Edge 2019, IE11, Safari)
|
|
65875
|
+
return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;
|
|
65876
|
+
}
|
|
65877
|
+
|
|
65878
|
+
function getViewportRect(element, strategy) {
|
|
65879
|
+
var win = getWindow(element);
|
|
65880
|
+
var html = getDocumentElement(element);
|
|
65881
|
+
var visualViewport = win.visualViewport;
|
|
65882
|
+
var width = html.clientWidth;
|
|
65883
|
+
var height = html.clientHeight;
|
|
65884
|
+
var x = 0;
|
|
65885
|
+
var y = 0;
|
|
65886
|
+
|
|
65887
|
+
if (visualViewport) {
|
|
65888
|
+
width = visualViewport.width;
|
|
65889
|
+
height = visualViewport.height;
|
|
65890
|
+
var layoutViewport = isLayoutViewport();
|
|
65891
|
+
|
|
65892
|
+
if (layoutViewport || !layoutViewport && strategy === 'fixed') {
|
|
65893
|
+
x = visualViewport.offsetLeft;
|
|
65894
|
+
y = visualViewport.offsetTop;
|
|
65895
|
+
}
|
|
65896
|
+
}
|
|
65897
|
+
|
|
65898
|
+
return {
|
|
65899
|
+
width: width,
|
|
65900
|
+
height: height,
|
|
65901
|
+
x: x + getWindowScrollBarX(element),
|
|
65902
|
+
y: y
|
|
65903
|
+
};
|
|
65904
|
+
}
|
|
65905
|
+
|
|
65906
|
+
// of the `<html>` and `<body>` rect bounds if horizontally scrollable
|
|
65907
|
+
|
|
65908
|
+
function getDocumentRect(element) {
|
|
65909
|
+
var _element$ownerDocumen;
|
|
65910
|
+
|
|
65911
|
+
var html = getDocumentElement(element);
|
|
65912
|
+
var winScroll = getWindowScroll(element);
|
|
65913
|
+
var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;
|
|
65914
|
+
var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);
|
|
65915
|
+
var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);
|
|
65916
|
+
var x = -winScroll.scrollLeft + getWindowScrollBarX(element);
|
|
65917
|
+
var y = -winScroll.scrollTop;
|
|
65918
|
+
|
|
65919
|
+
if (getComputedStyle$1(body || html).direction === 'rtl') {
|
|
65920
|
+
x += max(html.clientWidth, body ? body.clientWidth : 0) - width;
|
|
65921
|
+
}
|
|
65922
|
+
|
|
65923
|
+
return {
|
|
65924
|
+
width: width,
|
|
65925
|
+
height: height,
|
|
65926
|
+
x: x,
|
|
65927
|
+
y: y
|
|
65928
|
+
};
|
|
65929
|
+
}
|
|
65930
|
+
|
|
65931
|
+
function isScrollParent(element) {
|
|
65932
|
+
// Firefox wants us to check `-x` and `-y` variations as well
|
|
65933
|
+
var _getComputedStyle = getComputedStyle$1(element),
|
|
65934
|
+
overflow = _getComputedStyle.overflow,
|
|
65935
|
+
overflowX = _getComputedStyle.overflowX,
|
|
65936
|
+
overflowY = _getComputedStyle.overflowY;
|
|
65937
|
+
|
|
65938
|
+
return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);
|
|
65939
|
+
}
|
|
65940
|
+
|
|
65941
|
+
function getScrollParent(node) {
|
|
65942
|
+
if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {
|
|
65943
|
+
// $FlowFixMe[incompatible-return]: assume body is always available
|
|
65944
|
+
return node.ownerDocument.body;
|
|
65945
|
+
}
|
|
65946
|
+
|
|
65947
|
+
if (isHTMLElement(node) && isScrollParent(node)) {
|
|
65948
|
+
return node;
|
|
65949
|
+
}
|
|
65950
|
+
|
|
65951
|
+
return getScrollParent(getParentNode(node));
|
|
65952
|
+
}
|
|
65953
|
+
|
|
65954
|
+
/*
|
|
65955
|
+
given a DOM element, return the list of all scroll parents, up the list of ancesors
|
|
65956
|
+
until we get to the top window object. This list is what we attach scroll listeners
|
|
65957
|
+
to, because if any of these parent elements scroll, we'll need to re-calculate the
|
|
65958
|
+
reference element's position.
|
|
65959
|
+
*/
|
|
65960
|
+
|
|
65961
|
+
function listScrollParents(element, list) {
|
|
65962
|
+
var _element$ownerDocumen;
|
|
65963
|
+
|
|
65964
|
+
if (list === void 0) {
|
|
65965
|
+
list = [];
|
|
65966
|
+
}
|
|
65967
|
+
|
|
65968
|
+
var scrollParent = getScrollParent(element);
|
|
65969
|
+
var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);
|
|
65970
|
+
var win = getWindow(scrollParent);
|
|
65971
|
+
var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;
|
|
65972
|
+
var updatedList = list.concat(target);
|
|
65973
|
+
return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here
|
|
65974
|
+
updatedList.concat(listScrollParents(getParentNode(target)));
|
|
65975
|
+
}
|
|
65976
|
+
|
|
65977
|
+
function rectToClientRect(rect) {
|
|
65978
|
+
return Object.assign({}, rect, {
|
|
65979
|
+
left: rect.x,
|
|
65980
|
+
top: rect.y,
|
|
65981
|
+
right: rect.x + rect.width,
|
|
65982
|
+
bottom: rect.y + rect.height
|
|
65983
|
+
});
|
|
65984
|
+
}
|
|
65985
|
+
|
|
65986
|
+
function getInnerBoundingClientRect(element, strategy) {
|
|
65987
|
+
var rect = getBoundingClientRect(element, false, strategy === 'fixed');
|
|
65988
|
+
rect.top = rect.top + element.clientTop;
|
|
65989
|
+
rect.left = rect.left + element.clientLeft;
|
|
65990
|
+
rect.bottom = rect.top + element.clientHeight;
|
|
65991
|
+
rect.right = rect.left + element.clientWidth;
|
|
65992
|
+
rect.width = element.clientWidth;
|
|
65993
|
+
rect.height = element.clientHeight;
|
|
65994
|
+
rect.x = rect.left;
|
|
65995
|
+
rect.y = rect.top;
|
|
65996
|
+
return rect;
|
|
65997
|
+
}
|
|
65998
|
+
|
|
65999
|
+
function getClientRectFromMixedType(element, clippingParent, strategy) {
|
|
66000
|
+
return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));
|
|
66001
|
+
} // A "clipping parent" is an overflowable container with the characteristic of
|
|
66002
|
+
// clipping (or hiding) overflowing elements with a position different from
|
|
66003
|
+
// `initial`
|
|
66004
|
+
|
|
66005
|
+
|
|
66006
|
+
function getClippingParents(element) {
|
|
66007
|
+
var clippingParents = listScrollParents(getParentNode(element));
|
|
66008
|
+
var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle$1(element).position) >= 0;
|
|
66009
|
+
var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;
|
|
66010
|
+
|
|
66011
|
+
if (!isElement(clipperElement)) {
|
|
66012
|
+
return [];
|
|
66013
|
+
} // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414
|
|
66014
|
+
|
|
66015
|
+
|
|
66016
|
+
return clippingParents.filter(function (clippingParent) {
|
|
66017
|
+
return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';
|
|
66018
|
+
});
|
|
66019
|
+
} // Gets the maximum area that the element is visible in due to any number of
|
|
66020
|
+
// clipping parents
|
|
66021
|
+
|
|
66022
|
+
|
|
66023
|
+
function getClippingRect(element, boundary, rootBoundary, strategy) {
|
|
66024
|
+
var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);
|
|
66025
|
+
var clippingParents = [].concat(mainClippingParents, [rootBoundary]);
|
|
66026
|
+
var firstClippingParent = clippingParents[0];
|
|
66027
|
+
var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {
|
|
66028
|
+
var rect = getClientRectFromMixedType(element, clippingParent, strategy);
|
|
66029
|
+
accRect.top = max(rect.top, accRect.top);
|
|
66030
|
+
accRect.right = min(rect.right, accRect.right);
|
|
66031
|
+
accRect.bottom = min(rect.bottom, accRect.bottom);
|
|
66032
|
+
accRect.left = max(rect.left, accRect.left);
|
|
66033
|
+
return accRect;
|
|
66034
|
+
}, getClientRectFromMixedType(element, firstClippingParent, strategy));
|
|
66035
|
+
clippingRect.width = clippingRect.right - clippingRect.left;
|
|
66036
|
+
clippingRect.height = clippingRect.bottom - clippingRect.top;
|
|
66037
|
+
clippingRect.x = clippingRect.left;
|
|
66038
|
+
clippingRect.y = clippingRect.top;
|
|
66039
|
+
return clippingRect;
|
|
66040
|
+
}
|
|
66041
|
+
|
|
66042
|
+
function computeOffsets(_ref) {
|
|
66043
|
+
var reference = _ref.reference,
|
|
66044
|
+
element = _ref.element,
|
|
66045
|
+
placement = _ref.placement;
|
|
66046
|
+
var basePlacement = placement ? getBasePlacement(placement) : null;
|
|
66047
|
+
var variation = placement ? getVariation(placement) : null;
|
|
66048
|
+
var commonX = reference.x + reference.width / 2 - element.width / 2;
|
|
66049
|
+
var commonY = reference.y + reference.height / 2 - element.height / 2;
|
|
66050
|
+
var offsets;
|
|
66051
|
+
|
|
66052
|
+
switch (basePlacement) {
|
|
66053
|
+
case top:
|
|
66054
|
+
offsets = {
|
|
66055
|
+
x: commonX,
|
|
66056
|
+
y: reference.y - element.height
|
|
66057
|
+
};
|
|
66058
|
+
break;
|
|
66059
|
+
|
|
66060
|
+
case bottom:
|
|
66061
|
+
offsets = {
|
|
66062
|
+
x: commonX,
|
|
66063
|
+
y: reference.y + reference.height
|
|
66064
|
+
};
|
|
66065
|
+
break;
|
|
66066
|
+
|
|
66067
|
+
case right:
|
|
66068
|
+
offsets = {
|
|
66069
|
+
x: reference.x + reference.width,
|
|
66070
|
+
y: commonY
|
|
66071
|
+
};
|
|
66072
|
+
break;
|
|
66073
|
+
|
|
66074
|
+
case left:
|
|
66075
|
+
offsets = {
|
|
66076
|
+
x: reference.x - element.width,
|
|
66077
|
+
y: commonY
|
|
66078
|
+
};
|
|
66079
|
+
break;
|
|
66080
|
+
|
|
66081
|
+
default:
|
|
66082
|
+
offsets = {
|
|
66083
|
+
x: reference.x,
|
|
66084
|
+
y: reference.y
|
|
66085
|
+
};
|
|
66086
|
+
}
|
|
66087
|
+
|
|
66088
|
+
var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;
|
|
66089
|
+
|
|
66090
|
+
if (mainAxis != null) {
|
|
66091
|
+
var len = mainAxis === 'y' ? 'height' : 'width';
|
|
66092
|
+
|
|
66093
|
+
switch (variation) {
|
|
66094
|
+
case start:
|
|
66095
|
+
offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);
|
|
66096
|
+
break;
|
|
66097
|
+
|
|
66098
|
+
case end:
|
|
66099
|
+
offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);
|
|
66100
|
+
break;
|
|
66101
|
+
}
|
|
66102
|
+
}
|
|
66103
|
+
|
|
66104
|
+
return offsets;
|
|
66105
|
+
}
|
|
66106
|
+
|
|
66107
|
+
function detectOverflow(state, options) {
|
|
66108
|
+
if (options === void 0) {
|
|
66109
|
+
options = {};
|
|
66110
|
+
}
|
|
66111
|
+
|
|
66112
|
+
var _options = options,
|
|
66113
|
+
_options$placement = _options.placement,
|
|
66114
|
+
placement = _options$placement === void 0 ? state.placement : _options$placement,
|
|
66115
|
+
_options$strategy = _options.strategy,
|
|
66116
|
+
strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,
|
|
66117
|
+
_options$boundary = _options.boundary,
|
|
66118
|
+
boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,
|
|
66119
|
+
_options$rootBoundary = _options.rootBoundary,
|
|
66120
|
+
rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,
|
|
66121
|
+
_options$elementConte = _options.elementContext,
|
|
66122
|
+
elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,
|
|
66123
|
+
_options$altBoundary = _options.altBoundary,
|
|
66124
|
+
altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,
|
|
66125
|
+
_options$padding = _options.padding,
|
|
66126
|
+
padding = _options$padding === void 0 ? 0 : _options$padding;
|
|
66127
|
+
var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));
|
|
66128
|
+
var altContext = elementContext === popper ? reference : popper;
|
|
66129
|
+
var popperRect = state.rects.popper;
|
|
66130
|
+
var element = state.elements[altBoundary ? altContext : elementContext];
|
|
66131
|
+
var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);
|
|
66132
|
+
var referenceClientRect = getBoundingClientRect(state.elements.reference);
|
|
66133
|
+
var popperOffsets = computeOffsets({
|
|
66134
|
+
reference: referenceClientRect,
|
|
66135
|
+
element: popperRect,
|
|
66136
|
+
placement: placement
|
|
66137
|
+
});
|
|
66138
|
+
var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));
|
|
66139
|
+
var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect
|
|
66140
|
+
// 0 or negative = within the clipping rect
|
|
66141
|
+
|
|
66142
|
+
var overflowOffsets = {
|
|
66143
|
+
top: clippingClientRect.top - elementClientRect.top + paddingObject.top,
|
|
66144
|
+
bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,
|
|
66145
|
+
left: clippingClientRect.left - elementClientRect.left + paddingObject.left,
|
|
66146
|
+
right: elementClientRect.right - clippingClientRect.right + paddingObject.right
|
|
66147
|
+
};
|
|
66148
|
+
var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element
|
|
66149
|
+
|
|
66150
|
+
if (elementContext === popper && offsetData) {
|
|
66151
|
+
var offset = offsetData[placement];
|
|
66152
|
+
Object.keys(overflowOffsets).forEach(function (key) {
|
|
66153
|
+
var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;
|
|
66154
|
+
var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';
|
|
66155
|
+
overflowOffsets[key] += offset[axis] * multiply;
|
|
66156
|
+
});
|
|
66157
|
+
}
|
|
66158
|
+
|
|
66159
|
+
return overflowOffsets;
|
|
66160
|
+
}
|
|
66161
|
+
|
|
66162
|
+
function computeAutoPlacement(state, options) {
|
|
66163
|
+
if (options === void 0) {
|
|
66164
|
+
options = {};
|
|
66165
|
+
}
|
|
66166
|
+
|
|
66167
|
+
var _options = options,
|
|
66168
|
+
placement = _options.placement,
|
|
66169
|
+
boundary = _options.boundary,
|
|
66170
|
+
rootBoundary = _options.rootBoundary,
|
|
66171
|
+
padding = _options.padding,
|
|
66172
|
+
flipVariations = _options.flipVariations,
|
|
66173
|
+
_options$allowedAutoP = _options.allowedAutoPlacements,
|
|
66174
|
+
allowedAutoPlacements = _options$allowedAutoP === void 0 ? placements : _options$allowedAutoP;
|
|
66175
|
+
var variation = getVariation(placement);
|
|
66176
|
+
var placements$1 = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {
|
|
66177
|
+
return getVariation(placement) === variation;
|
|
66178
|
+
}) : basePlacements;
|
|
66179
|
+
var allowedPlacements = placements$1.filter(function (placement) {
|
|
66180
|
+
return allowedAutoPlacements.indexOf(placement) >= 0;
|
|
66181
|
+
});
|
|
66182
|
+
|
|
66183
|
+
if (allowedPlacements.length === 0) {
|
|
66184
|
+
allowedPlacements = placements$1;
|
|
66185
|
+
} // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...
|
|
66186
|
+
|
|
66187
|
+
|
|
66188
|
+
var overflows = allowedPlacements.reduce(function (acc, placement) {
|
|
66189
|
+
acc[placement] = detectOverflow(state, {
|
|
66190
|
+
placement: placement,
|
|
66191
|
+
boundary: boundary,
|
|
66192
|
+
rootBoundary: rootBoundary,
|
|
66193
|
+
padding: padding
|
|
66194
|
+
})[getBasePlacement(placement)];
|
|
66195
|
+
return acc;
|
|
66196
|
+
}, {});
|
|
66197
|
+
return Object.keys(overflows).sort(function (a, b) {
|
|
66198
|
+
return overflows[a] - overflows[b];
|
|
66199
|
+
});
|
|
66200
|
+
}
|
|
66201
|
+
|
|
66202
|
+
function getExpandedFallbackPlacements(placement) {
|
|
66203
|
+
if (getBasePlacement(placement) === auto) {
|
|
66204
|
+
return [];
|
|
66205
|
+
}
|
|
66206
|
+
|
|
66207
|
+
var oppositePlacement = getOppositePlacement(placement);
|
|
66208
|
+
return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];
|
|
66209
|
+
}
|
|
66210
|
+
|
|
66211
|
+
function flip(_ref) {
|
|
66212
|
+
var state = _ref.state,
|
|
66213
|
+
options = _ref.options,
|
|
66214
|
+
name = _ref.name;
|
|
66215
|
+
|
|
66216
|
+
if (state.modifiersData[name]._skip) {
|
|
66217
|
+
return;
|
|
66218
|
+
}
|
|
66219
|
+
|
|
66220
|
+
var _options$mainAxis = options.mainAxis,
|
|
66221
|
+
checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,
|
|
66222
|
+
_options$altAxis = options.altAxis,
|
|
66223
|
+
checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,
|
|
66224
|
+
specifiedFallbackPlacements = options.fallbackPlacements,
|
|
66225
|
+
padding = options.padding,
|
|
66226
|
+
boundary = options.boundary,
|
|
66227
|
+
rootBoundary = options.rootBoundary,
|
|
66228
|
+
altBoundary = options.altBoundary,
|
|
66229
|
+
_options$flipVariatio = options.flipVariations,
|
|
66230
|
+
flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,
|
|
66231
|
+
allowedAutoPlacements = options.allowedAutoPlacements;
|
|
66232
|
+
var preferredPlacement = state.options.placement;
|
|
66233
|
+
var basePlacement = getBasePlacement(preferredPlacement);
|
|
66234
|
+
var isBasePlacement = basePlacement === preferredPlacement;
|
|
66235
|
+
var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));
|
|
66236
|
+
var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {
|
|
66237
|
+
return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {
|
|
66238
|
+
placement: placement,
|
|
66239
|
+
boundary: boundary,
|
|
66240
|
+
rootBoundary: rootBoundary,
|
|
66241
|
+
padding: padding,
|
|
66242
|
+
flipVariations: flipVariations,
|
|
66243
|
+
allowedAutoPlacements: allowedAutoPlacements
|
|
66244
|
+
}) : placement);
|
|
66245
|
+
}, []);
|
|
66246
|
+
var referenceRect = state.rects.reference;
|
|
66247
|
+
var popperRect = state.rects.popper;
|
|
66248
|
+
var checksMap = new Map();
|
|
66249
|
+
var makeFallbackChecks = true;
|
|
66250
|
+
var firstFittingPlacement = placements[0];
|
|
66251
|
+
|
|
66252
|
+
for (var i = 0; i < placements.length; i++) {
|
|
66253
|
+
var placement = placements[i];
|
|
66254
|
+
|
|
66255
|
+
var _basePlacement = getBasePlacement(placement);
|
|
66256
|
+
|
|
66257
|
+
var isStartVariation = getVariation(placement) === start;
|
|
66258
|
+
var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;
|
|
66259
|
+
var len = isVertical ? 'width' : 'height';
|
|
66260
|
+
var overflow = detectOverflow(state, {
|
|
66261
|
+
placement: placement,
|
|
66262
|
+
boundary: boundary,
|
|
66263
|
+
rootBoundary: rootBoundary,
|
|
66264
|
+
altBoundary: altBoundary,
|
|
66265
|
+
padding: padding
|
|
66266
|
+
});
|
|
66267
|
+
var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;
|
|
66268
|
+
|
|
66269
|
+
if (referenceRect[len] > popperRect[len]) {
|
|
66270
|
+
mainVariationSide = getOppositePlacement(mainVariationSide);
|
|
66271
|
+
}
|
|
66272
|
+
|
|
66273
|
+
var altVariationSide = getOppositePlacement(mainVariationSide);
|
|
66274
|
+
var checks = [];
|
|
66275
|
+
|
|
66276
|
+
if (checkMainAxis) {
|
|
66277
|
+
checks.push(overflow[_basePlacement] <= 0);
|
|
66278
|
+
}
|
|
66279
|
+
|
|
66280
|
+
if (checkAltAxis) {
|
|
66281
|
+
checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);
|
|
66282
|
+
}
|
|
66283
|
+
|
|
66284
|
+
if (checks.every(function (check) {
|
|
66285
|
+
return check;
|
|
66286
|
+
})) {
|
|
66287
|
+
firstFittingPlacement = placement;
|
|
66288
|
+
makeFallbackChecks = false;
|
|
66289
|
+
break;
|
|
66290
|
+
}
|
|
66291
|
+
|
|
66292
|
+
checksMap.set(placement, checks);
|
|
66293
|
+
}
|
|
66294
|
+
|
|
66295
|
+
if (makeFallbackChecks) {
|
|
66296
|
+
// `2` may be desired in some cases – research later
|
|
66297
|
+
var numberOfChecks = flipVariations ? 3 : 1;
|
|
66298
|
+
|
|
66299
|
+
var _loop = function _loop(_i) {
|
|
66300
|
+
var fittingPlacement = placements.find(function (placement) {
|
|
66301
|
+
var checks = checksMap.get(placement);
|
|
66302
|
+
|
|
66303
|
+
if (checks) {
|
|
66304
|
+
return checks.slice(0, _i).every(function (check) {
|
|
66305
|
+
return check;
|
|
66306
|
+
});
|
|
66307
|
+
}
|
|
66308
|
+
});
|
|
66309
|
+
|
|
66310
|
+
if (fittingPlacement) {
|
|
66311
|
+
firstFittingPlacement = fittingPlacement;
|
|
66312
|
+
return "break";
|
|
66313
|
+
}
|
|
66314
|
+
};
|
|
66315
|
+
|
|
66316
|
+
for (var _i = numberOfChecks; _i > 0; _i--) {
|
|
66317
|
+
var _ret = _loop(_i);
|
|
66318
|
+
|
|
66319
|
+
if (_ret === "break") break;
|
|
66320
|
+
}
|
|
66321
|
+
}
|
|
66322
|
+
|
|
66323
|
+
if (state.placement !== firstFittingPlacement) {
|
|
66324
|
+
state.modifiersData[name]._skip = true;
|
|
66325
|
+
state.placement = firstFittingPlacement;
|
|
66326
|
+
state.reset = true;
|
|
66327
|
+
}
|
|
66328
|
+
} // eslint-disable-next-line import/no-unused-modules
|
|
66329
|
+
|
|
66330
|
+
|
|
66331
|
+
var flip$1 = {
|
|
66332
|
+
name: 'flip',
|
|
66333
|
+
enabled: true,
|
|
66334
|
+
phase: 'main',
|
|
66335
|
+
fn: flip,
|
|
66336
|
+
requiresIfExists: ['offset'],
|
|
66337
|
+
data: {
|
|
66338
|
+
_skip: false
|
|
66339
|
+
}
|
|
66340
|
+
};
|
|
66341
|
+
|
|
66342
|
+
function getSideOffsets(overflow, rect, preventedOffsets) {
|
|
66343
|
+
if (preventedOffsets === void 0) {
|
|
66344
|
+
preventedOffsets = {
|
|
66345
|
+
x: 0,
|
|
66346
|
+
y: 0
|
|
66347
|
+
};
|
|
66348
|
+
}
|
|
66349
|
+
|
|
66350
|
+
return {
|
|
66351
|
+
top: overflow.top - rect.height - preventedOffsets.y,
|
|
66352
|
+
right: overflow.right - rect.width + preventedOffsets.x,
|
|
66353
|
+
bottom: overflow.bottom - rect.height + preventedOffsets.y,
|
|
66354
|
+
left: overflow.left - rect.width - preventedOffsets.x
|
|
66355
|
+
};
|
|
66356
|
+
}
|
|
66357
|
+
|
|
66358
|
+
function isAnySideFullyClipped(overflow) {
|
|
66359
|
+
return [top, right, bottom, left].some(function (side) {
|
|
66360
|
+
return overflow[side] >= 0;
|
|
66361
|
+
});
|
|
66362
|
+
}
|
|
66363
|
+
|
|
66364
|
+
function hide(_ref) {
|
|
66365
|
+
var state = _ref.state,
|
|
66366
|
+
name = _ref.name;
|
|
66367
|
+
var referenceRect = state.rects.reference;
|
|
66368
|
+
var popperRect = state.rects.popper;
|
|
66369
|
+
var preventedOffsets = state.modifiersData.preventOverflow;
|
|
66370
|
+
var referenceOverflow = detectOverflow(state, {
|
|
66371
|
+
elementContext: 'reference'
|
|
66372
|
+
});
|
|
66373
|
+
var popperAltOverflow = detectOverflow(state, {
|
|
66374
|
+
altBoundary: true
|
|
66375
|
+
});
|
|
66376
|
+
var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);
|
|
66377
|
+
var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);
|
|
66378
|
+
var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);
|
|
66379
|
+
var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);
|
|
66380
|
+
state.modifiersData[name] = {
|
|
66381
|
+
referenceClippingOffsets: referenceClippingOffsets,
|
|
66382
|
+
popperEscapeOffsets: popperEscapeOffsets,
|
|
66383
|
+
isReferenceHidden: isReferenceHidden,
|
|
66384
|
+
hasPopperEscaped: hasPopperEscaped
|
|
66385
|
+
};
|
|
66386
|
+
state.attributes.popper = Object.assign({}, state.attributes.popper, {
|
|
66387
|
+
'data-popper-reference-hidden': isReferenceHidden,
|
|
66388
|
+
'data-popper-escaped': hasPopperEscaped
|
|
66389
|
+
});
|
|
66390
|
+
} // eslint-disable-next-line import/no-unused-modules
|
|
66391
|
+
|
|
66392
|
+
|
|
66393
|
+
var hide$1 = {
|
|
66394
|
+
name: 'hide',
|
|
66395
|
+
enabled: true,
|
|
66396
|
+
phase: 'main',
|
|
66397
|
+
requiresIfExists: ['preventOverflow'],
|
|
66398
|
+
fn: hide
|
|
66399
|
+
};
|
|
66400
|
+
|
|
66401
|
+
function distanceAndSkiddingToXY(placement, rects, offset) {
|
|
66402
|
+
var basePlacement = getBasePlacement(placement);
|
|
66403
|
+
var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;
|
|
66404
|
+
|
|
66405
|
+
var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {
|
|
66406
|
+
placement: placement
|
|
66407
|
+
})) : offset,
|
|
66408
|
+
skidding = _ref[0],
|
|
66409
|
+
distance = _ref[1];
|
|
66410
|
+
|
|
66411
|
+
skidding = skidding || 0;
|
|
66412
|
+
distance = (distance || 0) * invertDistance;
|
|
66413
|
+
return [left, right].indexOf(basePlacement) >= 0 ? {
|
|
66414
|
+
x: distance,
|
|
66415
|
+
y: skidding
|
|
66416
|
+
} : {
|
|
66417
|
+
x: skidding,
|
|
66418
|
+
y: distance
|
|
66419
|
+
};
|
|
66420
|
+
}
|
|
66421
|
+
|
|
66422
|
+
function offset(_ref2) {
|
|
66423
|
+
var state = _ref2.state,
|
|
66424
|
+
options = _ref2.options,
|
|
66425
|
+
name = _ref2.name;
|
|
66426
|
+
var _options$offset = options.offset,
|
|
66427
|
+
offset = _options$offset === void 0 ? [0, 0] : _options$offset;
|
|
66428
|
+
var data = placements.reduce(function (acc, placement) {
|
|
66429
|
+
acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);
|
|
66430
|
+
return acc;
|
|
66431
|
+
}, {});
|
|
66432
|
+
var _data$state$placement = data[state.placement],
|
|
66433
|
+
x = _data$state$placement.x,
|
|
66434
|
+
y = _data$state$placement.y;
|
|
66435
|
+
|
|
66436
|
+
if (state.modifiersData.popperOffsets != null) {
|
|
66437
|
+
state.modifiersData.popperOffsets.x += x;
|
|
66438
|
+
state.modifiersData.popperOffsets.y += y;
|
|
66439
|
+
}
|
|
66440
|
+
|
|
66441
|
+
state.modifiersData[name] = data;
|
|
66442
|
+
} // eslint-disable-next-line import/no-unused-modules
|
|
66443
|
+
|
|
66444
|
+
|
|
66445
|
+
var offset$1 = {
|
|
66446
|
+
name: 'offset',
|
|
66447
|
+
enabled: true,
|
|
66448
|
+
phase: 'main',
|
|
66449
|
+
requires: ['popperOffsets'],
|
|
66450
|
+
fn: offset
|
|
66451
|
+
};
|
|
66452
|
+
|
|
66453
|
+
function popperOffsets(_ref) {
|
|
66454
|
+
var state = _ref.state,
|
|
66455
|
+
name = _ref.name;
|
|
66456
|
+
// Offsets are the actual position the popper needs to have to be
|
|
66457
|
+
// properly positioned near its reference element
|
|
66458
|
+
// This is the most basic placement, and will be adjusted by
|
|
66459
|
+
// the modifiers in the next step
|
|
66460
|
+
state.modifiersData[name] = computeOffsets({
|
|
66461
|
+
reference: state.rects.reference,
|
|
66462
|
+
element: state.rects.popper,
|
|
66463
|
+
placement: state.placement
|
|
66464
|
+
});
|
|
66465
|
+
} // eslint-disable-next-line import/no-unused-modules
|
|
66466
|
+
|
|
66467
|
+
|
|
66468
|
+
var popperOffsets$1 = {
|
|
66469
|
+
name: 'popperOffsets',
|
|
66470
|
+
enabled: true,
|
|
66471
|
+
phase: 'read',
|
|
66472
|
+
fn: popperOffsets,
|
|
66473
|
+
data: {}
|
|
66474
|
+
};
|
|
66475
|
+
|
|
66476
|
+
function getAltAxis(axis) {
|
|
66477
|
+
return axis === 'x' ? 'y' : 'x';
|
|
66478
|
+
}
|
|
66479
|
+
|
|
66480
|
+
function preventOverflow(_ref) {
|
|
66481
|
+
var state = _ref.state,
|
|
66482
|
+
options = _ref.options,
|
|
66483
|
+
name = _ref.name;
|
|
66484
|
+
var _options$mainAxis = options.mainAxis,
|
|
66485
|
+
checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,
|
|
66486
|
+
_options$altAxis = options.altAxis,
|
|
66487
|
+
checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,
|
|
66488
|
+
boundary = options.boundary,
|
|
66489
|
+
rootBoundary = options.rootBoundary,
|
|
66490
|
+
altBoundary = options.altBoundary,
|
|
66491
|
+
padding = options.padding,
|
|
66492
|
+
_options$tether = options.tether,
|
|
66493
|
+
tether = _options$tether === void 0 ? true : _options$tether,
|
|
66494
|
+
_options$tetherOffset = options.tetherOffset,
|
|
66495
|
+
tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;
|
|
66496
|
+
var overflow = detectOverflow(state, {
|
|
66497
|
+
boundary: boundary,
|
|
66498
|
+
rootBoundary: rootBoundary,
|
|
66499
|
+
padding: padding,
|
|
66500
|
+
altBoundary: altBoundary
|
|
66501
|
+
});
|
|
66502
|
+
var basePlacement = getBasePlacement(state.placement);
|
|
66503
|
+
var variation = getVariation(state.placement);
|
|
66504
|
+
var isBasePlacement = !variation;
|
|
66505
|
+
var mainAxis = getMainAxisFromPlacement(basePlacement);
|
|
66506
|
+
var altAxis = getAltAxis(mainAxis);
|
|
66507
|
+
var popperOffsets = state.modifiersData.popperOffsets;
|
|
66508
|
+
var referenceRect = state.rects.reference;
|
|
66509
|
+
var popperRect = state.rects.popper;
|
|
66510
|
+
var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {
|
|
66511
|
+
placement: state.placement
|
|
66512
|
+
})) : tetherOffset;
|
|
66513
|
+
var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {
|
|
66514
|
+
mainAxis: tetherOffsetValue,
|
|
66515
|
+
altAxis: tetherOffsetValue
|
|
66516
|
+
} : Object.assign({
|
|
66517
|
+
mainAxis: 0,
|
|
66518
|
+
altAxis: 0
|
|
66519
|
+
}, tetherOffsetValue);
|
|
66520
|
+
var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;
|
|
66521
|
+
var data = {
|
|
66522
|
+
x: 0,
|
|
66523
|
+
y: 0
|
|
66524
|
+
};
|
|
66525
|
+
|
|
66526
|
+
if (!popperOffsets) {
|
|
66527
|
+
return;
|
|
66528
|
+
}
|
|
66529
|
+
|
|
66530
|
+
if (checkMainAxis) {
|
|
66531
|
+
var _offsetModifierState$;
|
|
66532
|
+
|
|
66533
|
+
var mainSide = mainAxis === 'y' ? top : left;
|
|
66534
|
+
var altSide = mainAxis === 'y' ? bottom : right;
|
|
66535
|
+
var len = mainAxis === 'y' ? 'height' : 'width';
|
|
66536
|
+
var offset = popperOffsets[mainAxis];
|
|
66537
|
+
var min$1 = offset + overflow[mainSide];
|
|
66538
|
+
var max$1 = offset - overflow[altSide];
|
|
66539
|
+
var additive = tether ? -popperRect[len] / 2 : 0;
|
|
66540
|
+
var minLen = variation === start ? referenceRect[len] : popperRect[len];
|
|
66541
|
+
var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go
|
|
66542
|
+
// outside the reference bounds
|
|
66543
|
+
|
|
66544
|
+
var arrowElement = state.elements.arrow;
|
|
66545
|
+
var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {
|
|
66546
|
+
width: 0,
|
|
66547
|
+
height: 0
|
|
66548
|
+
};
|
|
66549
|
+
var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();
|
|
66550
|
+
var arrowPaddingMin = arrowPaddingObject[mainSide];
|
|
66551
|
+
var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want
|
|
66552
|
+
// to include its full size in the calculation. If the reference is small
|
|
66553
|
+
// and near the edge of a boundary, the popper can overflow even if the
|
|
66554
|
+
// reference is not overflowing as well (e.g. virtual elements with no
|
|
66555
|
+
// width or height)
|
|
66556
|
+
|
|
66557
|
+
var arrowLen = within(0, referenceRect[len], arrowRect[len]);
|
|
66558
|
+
var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;
|
|
66559
|
+
var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;
|
|
66560
|
+
var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);
|
|
66561
|
+
var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;
|
|
66562
|
+
var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;
|
|
66563
|
+
var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;
|
|
66564
|
+
var tetherMax = offset + maxOffset - offsetModifierValue;
|
|
66565
|
+
var preventedOffset = within(tether ? min(min$1, tetherMin) : min$1, offset, tether ? max(max$1, tetherMax) : max$1);
|
|
66566
|
+
popperOffsets[mainAxis] = preventedOffset;
|
|
66567
|
+
data[mainAxis] = preventedOffset - offset;
|
|
66568
|
+
}
|
|
66569
|
+
|
|
66570
|
+
if (checkAltAxis) {
|
|
66571
|
+
var _offsetModifierState$2;
|
|
66572
|
+
|
|
66573
|
+
var _mainSide = mainAxis === 'x' ? top : left;
|
|
66574
|
+
|
|
66575
|
+
var _altSide = mainAxis === 'x' ? bottom : right;
|
|
66576
|
+
|
|
66577
|
+
var _offset = popperOffsets[altAxis];
|
|
66578
|
+
|
|
66579
|
+
var _len = altAxis === 'y' ? 'height' : 'width';
|
|
66580
|
+
|
|
66581
|
+
var _min = _offset + overflow[_mainSide];
|
|
66582
|
+
|
|
66583
|
+
var _max = _offset - overflow[_altSide];
|
|
66584
|
+
|
|
66585
|
+
var isOriginSide = [top, left].indexOf(basePlacement) !== -1;
|
|
66586
|
+
|
|
66587
|
+
var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;
|
|
66588
|
+
|
|
66589
|
+
var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;
|
|
66590
|
+
|
|
66591
|
+
var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;
|
|
66592
|
+
|
|
66593
|
+
var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);
|
|
66594
|
+
|
|
66595
|
+
popperOffsets[altAxis] = _preventedOffset;
|
|
66596
|
+
data[altAxis] = _preventedOffset - _offset;
|
|
66597
|
+
}
|
|
66598
|
+
|
|
66599
|
+
state.modifiersData[name] = data;
|
|
66600
|
+
} // eslint-disable-next-line import/no-unused-modules
|
|
66601
|
+
|
|
66602
|
+
|
|
66603
|
+
var preventOverflow$1 = {
|
|
66604
|
+
name: 'preventOverflow',
|
|
66605
|
+
enabled: true,
|
|
66606
|
+
phase: 'main',
|
|
66607
|
+
fn: preventOverflow,
|
|
66608
|
+
requiresIfExists: ['offset']
|
|
66609
|
+
};
|
|
66610
|
+
|
|
66611
|
+
function getHTMLElementScroll(element) {
|
|
66612
|
+
return {
|
|
66613
|
+
scrollLeft: element.scrollLeft,
|
|
66614
|
+
scrollTop: element.scrollTop
|
|
66615
|
+
};
|
|
66616
|
+
}
|
|
66617
|
+
|
|
66618
|
+
function getNodeScroll(node) {
|
|
66619
|
+
if (node === getWindow(node) || !isHTMLElement(node)) {
|
|
66620
|
+
return getWindowScroll(node);
|
|
66621
|
+
} else {
|
|
66622
|
+
return getHTMLElementScroll(node);
|
|
66623
|
+
}
|
|
66624
|
+
}
|
|
66625
|
+
|
|
66626
|
+
function isElementScaled(element) {
|
|
66627
|
+
var rect = element.getBoundingClientRect();
|
|
66628
|
+
var scaleX = round(rect.width) / element.offsetWidth || 1;
|
|
66629
|
+
var scaleY = round(rect.height) / element.offsetHeight || 1;
|
|
66630
|
+
return scaleX !== 1 || scaleY !== 1;
|
|
66631
|
+
} // Returns the composite rect of an element relative to its offsetParent.
|
|
66632
|
+
// Composite means it takes into account transforms as well as layout.
|
|
66633
|
+
|
|
66634
|
+
|
|
66635
|
+
function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {
|
|
66636
|
+
if (isFixed === void 0) {
|
|
66637
|
+
isFixed = false;
|
|
66638
|
+
}
|
|
66639
|
+
|
|
66640
|
+
var isOffsetParentAnElement = isHTMLElement(offsetParent);
|
|
66641
|
+
var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);
|
|
66642
|
+
var documentElement = getDocumentElement(offsetParent);
|
|
66643
|
+
var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);
|
|
66644
|
+
var scroll = {
|
|
66645
|
+
scrollLeft: 0,
|
|
66646
|
+
scrollTop: 0
|
|
66647
|
+
};
|
|
66648
|
+
var offsets = {
|
|
66649
|
+
x: 0,
|
|
66650
|
+
y: 0
|
|
66651
|
+
};
|
|
66652
|
+
|
|
66653
|
+
if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {
|
|
66654
|
+
if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078
|
|
66655
|
+
isScrollParent(documentElement)) {
|
|
66656
|
+
scroll = getNodeScroll(offsetParent);
|
|
66657
|
+
}
|
|
66658
|
+
|
|
66659
|
+
if (isHTMLElement(offsetParent)) {
|
|
66660
|
+
offsets = getBoundingClientRect(offsetParent, true);
|
|
66661
|
+
offsets.x += offsetParent.clientLeft;
|
|
66662
|
+
offsets.y += offsetParent.clientTop;
|
|
66663
|
+
} else if (documentElement) {
|
|
66664
|
+
offsets.x = getWindowScrollBarX(documentElement);
|
|
66665
|
+
}
|
|
66666
|
+
}
|
|
66667
|
+
|
|
66668
|
+
return {
|
|
66669
|
+
x: rect.left + scroll.scrollLeft - offsets.x,
|
|
66670
|
+
y: rect.top + scroll.scrollTop - offsets.y,
|
|
66671
|
+
width: rect.width,
|
|
66672
|
+
height: rect.height
|
|
66673
|
+
};
|
|
66674
|
+
}
|
|
66675
|
+
|
|
66676
|
+
function order(modifiers) {
|
|
66677
|
+
var map = new Map();
|
|
66678
|
+
var visited = new Set();
|
|
66679
|
+
var result = [];
|
|
66680
|
+
modifiers.forEach(function (modifier) {
|
|
66681
|
+
map.set(modifier.name, modifier);
|
|
66682
|
+
}); // On visiting object, check for its dependencies and visit them recursively
|
|
66683
|
+
|
|
66684
|
+
function sort(modifier) {
|
|
66685
|
+
visited.add(modifier.name);
|
|
66686
|
+
var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);
|
|
66687
|
+
requires.forEach(function (dep) {
|
|
66688
|
+
if (!visited.has(dep)) {
|
|
66689
|
+
var depModifier = map.get(dep);
|
|
66690
|
+
|
|
66691
|
+
if (depModifier) {
|
|
66692
|
+
sort(depModifier);
|
|
66693
|
+
}
|
|
66694
|
+
}
|
|
66695
|
+
});
|
|
66696
|
+
result.push(modifier);
|
|
66697
|
+
}
|
|
66698
|
+
|
|
66699
|
+
modifiers.forEach(function (modifier) {
|
|
66700
|
+
if (!visited.has(modifier.name)) {
|
|
66701
|
+
// check for visited object
|
|
66702
|
+
sort(modifier);
|
|
66703
|
+
}
|
|
66704
|
+
});
|
|
66705
|
+
return result;
|
|
66706
|
+
}
|
|
66707
|
+
|
|
66708
|
+
function orderModifiers(modifiers) {
|
|
66709
|
+
// order based on dependencies
|
|
66710
|
+
var orderedModifiers = order(modifiers); // order based on phase
|
|
66711
|
+
|
|
66712
|
+
return modifierPhases.reduce(function (acc, phase) {
|
|
66713
|
+
return acc.concat(orderedModifiers.filter(function (modifier) {
|
|
66714
|
+
return modifier.phase === phase;
|
|
66715
|
+
}));
|
|
66716
|
+
}, []);
|
|
66717
|
+
}
|
|
66718
|
+
|
|
66719
|
+
function debounce(fn) {
|
|
66720
|
+
var pending;
|
|
66721
|
+
return function () {
|
|
66722
|
+
if (!pending) {
|
|
66723
|
+
pending = new Promise(function (resolve) {
|
|
66724
|
+
Promise.resolve().then(function () {
|
|
66725
|
+
pending = undefined;
|
|
66726
|
+
resolve(fn());
|
|
66727
|
+
});
|
|
66728
|
+
});
|
|
66729
|
+
}
|
|
66730
|
+
|
|
66731
|
+
return pending;
|
|
66732
|
+
};
|
|
66733
|
+
}
|
|
66734
|
+
|
|
66735
|
+
function mergeByName(modifiers) {
|
|
66736
|
+
var merged = modifiers.reduce(function (merged, current) {
|
|
66737
|
+
var existing = merged[current.name];
|
|
66738
|
+
merged[current.name] = existing ? Object.assign({}, existing, current, {
|
|
66739
|
+
options: Object.assign({}, existing.options, current.options),
|
|
66740
|
+
data: Object.assign({}, existing.data, current.data)
|
|
66741
|
+
}) : current;
|
|
66742
|
+
return merged;
|
|
66743
|
+
}, {}); // IE11 does not support Object.values
|
|
66744
|
+
|
|
66745
|
+
return Object.keys(merged).map(function (key) {
|
|
66746
|
+
return merged[key];
|
|
66747
|
+
});
|
|
66748
|
+
}
|
|
66749
|
+
|
|
66750
|
+
var DEFAULT_OPTIONS = {
|
|
66751
|
+
placement: 'bottom',
|
|
66752
|
+
modifiers: [],
|
|
66753
|
+
strategy: 'absolute'
|
|
66754
|
+
};
|
|
66755
|
+
|
|
66756
|
+
function areValidElements() {
|
|
66757
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
66758
|
+
args[_key] = arguments[_key];
|
|
66759
|
+
}
|
|
66760
|
+
|
|
66761
|
+
return !args.some(function (element) {
|
|
66762
|
+
return !(element && typeof element.getBoundingClientRect === 'function');
|
|
66763
|
+
});
|
|
66764
|
+
}
|
|
66765
|
+
|
|
66766
|
+
function popperGenerator(generatorOptions) {
|
|
66767
|
+
if (generatorOptions === void 0) {
|
|
66768
|
+
generatorOptions = {};
|
|
66769
|
+
}
|
|
66770
|
+
|
|
66771
|
+
var _generatorOptions = generatorOptions,
|
|
66772
|
+
_generatorOptions$def = _generatorOptions.defaultModifiers,
|
|
66773
|
+
defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,
|
|
66774
|
+
_generatorOptions$def2 = _generatorOptions.defaultOptions,
|
|
66775
|
+
defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;
|
|
66776
|
+
return function createPopper(reference, popper, options) {
|
|
66777
|
+
if (options === void 0) {
|
|
66778
|
+
options = defaultOptions;
|
|
66779
|
+
}
|
|
66780
|
+
|
|
66781
|
+
var state = {
|
|
66782
|
+
placement: 'bottom',
|
|
66783
|
+
orderedModifiers: [],
|
|
66784
|
+
options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),
|
|
66785
|
+
modifiersData: {},
|
|
66786
|
+
elements: {
|
|
66787
|
+
reference: reference,
|
|
66788
|
+
popper: popper
|
|
66789
|
+
},
|
|
66790
|
+
attributes: {},
|
|
66791
|
+
styles: {}
|
|
66792
|
+
};
|
|
66793
|
+
var effectCleanupFns = [];
|
|
66794
|
+
var isDestroyed = false;
|
|
66795
|
+
var instance = {
|
|
66796
|
+
state: state,
|
|
66797
|
+
setOptions: function setOptions(setOptionsAction) {
|
|
66798
|
+
var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;
|
|
66799
|
+
cleanupModifierEffects();
|
|
66800
|
+
state.options = Object.assign({}, defaultOptions, state.options, options);
|
|
66801
|
+
state.scrollParents = {
|
|
66802
|
+
reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],
|
|
66803
|
+
popper: listScrollParents(popper)
|
|
66804
|
+
}; // Orders the modifiers based on their dependencies and `phase`
|
|
66805
|
+
// properties
|
|
66806
|
+
|
|
66807
|
+
var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers
|
|
66808
|
+
|
|
66809
|
+
state.orderedModifiers = orderedModifiers.filter(function (m) {
|
|
66810
|
+
return m.enabled;
|
|
66811
|
+
});
|
|
66812
|
+
runModifierEffects();
|
|
66813
|
+
return instance.update();
|
|
66814
|
+
},
|
|
66815
|
+
// Sync update – it will always be executed, even if not necessary. This
|
|
66816
|
+
// is useful for low frequency updates where sync behavior simplifies the
|
|
66817
|
+
// logic.
|
|
66818
|
+
// For high frequency updates (e.g. `resize` and `scroll` events), always
|
|
66819
|
+
// prefer the async Popper#update method
|
|
66820
|
+
forceUpdate: function forceUpdate() {
|
|
66821
|
+
if (isDestroyed) {
|
|
66822
|
+
return;
|
|
66823
|
+
}
|
|
66824
|
+
|
|
66825
|
+
var _state$elements = state.elements,
|
|
66826
|
+
reference = _state$elements.reference,
|
|
66827
|
+
popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements
|
|
66828
|
+
// anymore
|
|
66829
|
+
|
|
66830
|
+
if (!areValidElements(reference, popper)) {
|
|
66831
|
+
return;
|
|
66832
|
+
} // Store the reference and popper rects to be read by modifiers
|
|
66833
|
+
|
|
66834
|
+
|
|
66835
|
+
state.rects = {
|
|
66836
|
+
reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),
|
|
66837
|
+
popper: getLayoutRect(popper)
|
|
66838
|
+
}; // Modifiers have the ability to reset the current update cycle. The
|
|
66839
|
+
// most common use case for this is the `flip` modifier changing the
|
|
66840
|
+
// placement, which then needs to re-run all the modifiers, because the
|
|
66841
|
+
// logic was previously ran for the previous placement and is therefore
|
|
66842
|
+
// stale/incorrect
|
|
66843
|
+
|
|
66844
|
+
state.reset = false;
|
|
66845
|
+
state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier
|
|
66846
|
+
// is filled with the initial data specified by the modifier. This means
|
|
66847
|
+
// it doesn't persist and is fresh on each update.
|
|
66848
|
+
// To ensure persistent data, use `${name}#persistent`
|
|
66849
|
+
|
|
66850
|
+
state.orderedModifiers.forEach(function (modifier) {
|
|
66851
|
+
return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);
|
|
66852
|
+
});
|
|
66853
|
+
|
|
66854
|
+
for (var index = 0; index < state.orderedModifiers.length; index++) {
|
|
66855
|
+
if (state.reset === true) {
|
|
66856
|
+
state.reset = false;
|
|
66857
|
+
index = -1;
|
|
66858
|
+
continue;
|
|
66859
|
+
}
|
|
66860
|
+
|
|
66861
|
+
var _state$orderedModifie = state.orderedModifiers[index],
|
|
66862
|
+
fn = _state$orderedModifie.fn,
|
|
66863
|
+
_state$orderedModifie2 = _state$orderedModifie.options,
|
|
66864
|
+
_options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,
|
|
66865
|
+
name = _state$orderedModifie.name;
|
|
66866
|
+
|
|
66867
|
+
if (typeof fn === 'function') {
|
|
66868
|
+
state = fn({
|
|
66869
|
+
state: state,
|
|
66870
|
+
options: _options,
|
|
66871
|
+
name: name,
|
|
66872
|
+
instance: instance
|
|
66873
|
+
}) || state;
|
|
66874
|
+
}
|
|
66875
|
+
}
|
|
66876
|
+
},
|
|
66877
|
+
// Async and optimistically optimized update – it will not be executed if
|
|
66878
|
+
// not necessary (debounced to run at most once-per-tick)
|
|
66879
|
+
update: debounce(function () {
|
|
66880
|
+
return new Promise(function (resolve) {
|
|
66881
|
+
instance.forceUpdate();
|
|
66882
|
+
resolve(state);
|
|
66883
|
+
});
|
|
66884
|
+
}),
|
|
66885
|
+
destroy: function destroy() {
|
|
66886
|
+
cleanupModifierEffects();
|
|
66887
|
+
isDestroyed = true;
|
|
66888
|
+
}
|
|
66889
|
+
};
|
|
66890
|
+
|
|
66891
|
+
if (!areValidElements(reference, popper)) {
|
|
66892
|
+
return instance;
|
|
66893
|
+
}
|
|
66894
|
+
|
|
66895
|
+
instance.setOptions(options).then(function (state) {
|
|
66896
|
+
if (!isDestroyed && options.onFirstUpdate) {
|
|
66897
|
+
options.onFirstUpdate(state);
|
|
66898
|
+
}
|
|
66899
|
+
}); // Modifiers have the ability to execute arbitrary code before the first
|
|
66900
|
+
// update cycle runs. They will be executed in the same order as the update
|
|
66901
|
+
// cycle. This is useful when a modifier adds some persistent data that
|
|
66902
|
+
// other modifiers need to use, but the modifier is run after the dependent
|
|
66903
|
+
// one.
|
|
66904
|
+
|
|
66905
|
+
function runModifierEffects() {
|
|
66906
|
+
state.orderedModifiers.forEach(function (_ref) {
|
|
66907
|
+
var name = _ref.name,
|
|
66908
|
+
_ref$options = _ref.options,
|
|
66909
|
+
options = _ref$options === void 0 ? {} : _ref$options,
|
|
66910
|
+
effect = _ref.effect;
|
|
66911
|
+
|
|
66912
|
+
if (typeof effect === 'function') {
|
|
66913
|
+
var cleanupFn = effect({
|
|
66914
|
+
state: state,
|
|
66915
|
+
name: name,
|
|
66916
|
+
instance: instance,
|
|
66917
|
+
options: options
|
|
66918
|
+
});
|
|
66919
|
+
|
|
66920
|
+
var noopFn = function noopFn() {};
|
|
66921
|
+
|
|
66922
|
+
effectCleanupFns.push(cleanupFn || noopFn);
|
|
66923
|
+
}
|
|
66924
|
+
});
|
|
66925
|
+
}
|
|
66926
|
+
|
|
66927
|
+
function cleanupModifierEffects() {
|
|
66928
|
+
effectCleanupFns.forEach(function (fn) {
|
|
66929
|
+
return fn();
|
|
66930
|
+
});
|
|
66931
|
+
effectCleanupFns = [];
|
|
66932
|
+
}
|
|
66933
|
+
|
|
66934
|
+
return instance;
|
|
66935
|
+
};
|
|
66936
|
+
}
|
|
66937
|
+
|
|
66938
|
+
var defaultModifiers = [eventListeners, popperOffsets$1, computeStyles$1, applyStyles$1, offset$1, flip$1, preventOverflow$1, arrow$1, hide$1];
|
|
66939
|
+
var createPopper = /*#__PURE__*/popperGenerator({
|
|
66940
|
+
defaultModifiers: defaultModifiers
|
|
66941
|
+
}); // eslint-disable-next-line import/no-unused-modules
|
|
66942
|
+
|
|
66943
|
+
/* global Map:readonly, Set:readonly, ArrayBuffer:readonly */
|
|
66944
|
+
|
|
66945
|
+
var hasElementType = typeof Element !== 'undefined';
|
|
66946
|
+
var hasMap = typeof Map === 'function';
|
|
66947
|
+
var hasSet = typeof Set === 'function';
|
|
66948
|
+
var hasArrayBuffer = typeof ArrayBuffer === 'function' && !!ArrayBuffer.isView;
|
|
66949
|
+
|
|
66950
|
+
// Note: We **don't** need `envHasBigInt64Array` in fde es6/index.js
|
|
66951
|
+
|
|
66952
|
+
function equal(a, b) {
|
|
66953
|
+
// START: fast-deep-equal es6/index.js 3.1.3
|
|
66954
|
+
if (a === b) return true;
|
|
66955
|
+
|
|
66956
|
+
if (a && b && typeof a == 'object' && typeof b == 'object') {
|
|
66957
|
+
if (a.constructor !== b.constructor) return false;
|
|
66958
|
+
|
|
66959
|
+
var length, i, keys;
|
|
66960
|
+
if (Array.isArray(a)) {
|
|
66961
|
+
length = a.length;
|
|
66962
|
+
if (length != b.length) return false;
|
|
66963
|
+
for (i = length; i-- !== 0;)
|
|
66964
|
+
if (!equal(a[i], b[i])) return false;
|
|
66965
|
+
return true;
|
|
66966
|
+
}
|
|
66967
|
+
|
|
66968
|
+
// START: Modifications:
|
|
66969
|
+
// 1. Extra `has<Type> &&` helpers in initial condition allow es6 code
|
|
66970
|
+
// to co-exist with es5.
|
|
66971
|
+
// 2. Replace `for of` with es5 compliant iteration using `for`.
|
|
66972
|
+
// Basically, take:
|
|
66973
|
+
//
|
|
66974
|
+
// ```js
|
|
66975
|
+
// for (i of a.entries())
|
|
66976
|
+
// if (!b.has(i[0])) return false;
|
|
66977
|
+
// ```
|
|
66978
|
+
//
|
|
66979
|
+
// ... and convert to:
|
|
66980
|
+
//
|
|
66981
|
+
// ```js
|
|
66982
|
+
// it = a.entries();
|
|
66983
|
+
// while (!(i = it.next()).done)
|
|
66984
|
+
// if (!b.has(i.value[0])) return false;
|
|
66985
|
+
// ```
|
|
66986
|
+
//
|
|
66987
|
+
// **Note**: `i` access switches to `i.value`.
|
|
66988
|
+
var it;
|
|
66989
|
+
if (hasMap && (a instanceof Map) && (b instanceof Map)) {
|
|
66990
|
+
if (a.size !== b.size) return false;
|
|
66991
|
+
it = a.entries();
|
|
66992
|
+
while (!(i = it.next()).done)
|
|
66993
|
+
if (!b.has(i.value[0])) return false;
|
|
66994
|
+
it = a.entries();
|
|
66995
|
+
while (!(i = it.next()).done)
|
|
66996
|
+
if (!equal(i.value[1], b.get(i.value[0]))) return false;
|
|
66997
|
+
return true;
|
|
66998
|
+
}
|
|
66999
|
+
|
|
67000
|
+
if (hasSet && (a instanceof Set) && (b instanceof Set)) {
|
|
67001
|
+
if (a.size !== b.size) return false;
|
|
67002
|
+
it = a.entries();
|
|
67003
|
+
while (!(i = it.next()).done)
|
|
67004
|
+
if (!b.has(i.value[0])) return false;
|
|
67005
|
+
return true;
|
|
67006
|
+
}
|
|
67007
|
+
// END: Modifications
|
|
67008
|
+
|
|
67009
|
+
if (hasArrayBuffer && ArrayBuffer.isView(a) && ArrayBuffer.isView(b)) {
|
|
67010
|
+
length = a.length;
|
|
67011
|
+
if (length != b.length) return false;
|
|
67012
|
+
for (i = length; i-- !== 0;)
|
|
67013
|
+
if (a[i] !== b[i]) return false;
|
|
67014
|
+
return true;
|
|
67015
|
+
}
|
|
67016
|
+
|
|
67017
|
+
if (a.constructor === RegExp) return a.source === b.source && a.flags === b.flags;
|
|
67018
|
+
// START: Modifications:
|
|
67019
|
+
// Apply guards for `Object.create(null)` handling. See:
|
|
67020
|
+
// - https://github.com/FormidableLabs/react-fast-compare/issues/64
|
|
67021
|
+
// - https://github.com/epoberezkin/fast-deep-equal/issues/49
|
|
67022
|
+
if (a.valueOf !== Object.prototype.valueOf && typeof a.valueOf === 'function' && typeof b.valueOf === 'function') return a.valueOf() === b.valueOf();
|
|
67023
|
+
if (a.toString !== Object.prototype.toString && typeof a.toString === 'function' && typeof b.toString === 'function') return a.toString() === b.toString();
|
|
67024
|
+
// END: Modifications
|
|
67025
|
+
|
|
67026
|
+
keys = Object.keys(a);
|
|
67027
|
+
length = keys.length;
|
|
67028
|
+
if (length !== Object.keys(b).length) return false;
|
|
67029
|
+
|
|
67030
|
+
for (i = length; i-- !== 0;)
|
|
67031
|
+
if (!Object.prototype.hasOwnProperty.call(b, keys[i])) return false;
|
|
67032
|
+
// END: fast-deep-equal
|
|
67033
|
+
|
|
67034
|
+
// START: react-fast-compare
|
|
67035
|
+
// custom handling for DOM elements
|
|
67036
|
+
if (hasElementType && a instanceof Element) return false;
|
|
67037
|
+
|
|
67038
|
+
// custom handling for React/Preact
|
|
67039
|
+
for (i = length; i-- !== 0;) {
|
|
67040
|
+
if ((keys[i] === '_owner' || keys[i] === '__v' || keys[i] === '__o') && a.$$typeof) {
|
|
67041
|
+
// React-specific: avoid traversing React elements' _owner
|
|
67042
|
+
// Preact-specific: avoid traversing Preact elements' __v and __o
|
|
67043
|
+
// __v = $_original / $_vnode
|
|
67044
|
+
// __o = $_owner
|
|
67045
|
+
// These properties contain circular references and are not needed when
|
|
67046
|
+
// comparing the actual elements (and not their owners)
|
|
67047
|
+
// .$$typeof and ._store on just reasonable markers of elements
|
|
67048
|
+
|
|
67049
|
+
continue;
|
|
67050
|
+
}
|
|
67051
|
+
|
|
67052
|
+
// all other properties should be traversed as usual
|
|
67053
|
+
if (!equal(a[keys[i]], b[keys[i]])) return false;
|
|
67054
|
+
}
|
|
67055
|
+
// END: react-fast-compare
|
|
67056
|
+
|
|
67057
|
+
// START: fast-deep-equal
|
|
67058
|
+
return true;
|
|
67059
|
+
}
|
|
67060
|
+
|
|
67061
|
+
return a !== a && b !== b;
|
|
67062
|
+
}
|
|
67063
|
+
// end fast-deep-equal
|
|
67064
|
+
|
|
67065
|
+
var reactFastCompare = function isEqual(a, b) {
|
|
67066
|
+
try {
|
|
67067
|
+
return equal(a, b);
|
|
67068
|
+
} catch (error) {
|
|
67069
|
+
if (((error.message || '').match(/stack|recursion/i))) {
|
|
67070
|
+
// warn on circular references, don't crash
|
|
67071
|
+
// browsers give this different errors name and messages:
|
|
67072
|
+
// chrome/safari: "RangeError", "Maximum call stack size exceeded"
|
|
67073
|
+
// firefox: "InternalError", too much recursion"
|
|
67074
|
+
// edge: "Error", "Out of stack space"
|
|
67075
|
+
console.warn('react-fast-compare cannot handle circular refs');
|
|
67076
|
+
return false;
|
|
67077
|
+
}
|
|
67078
|
+
// some other error. we should definitely know about these
|
|
67079
|
+
throw error;
|
|
67080
|
+
}
|
|
67081
|
+
};
|
|
67082
|
+
|
|
67083
|
+
var isEqual = /*@__PURE__*/getDefaultExportFromCjs(reactFastCompare);
|
|
67084
|
+
|
|
67085
|
+
var EMPTY_MODIFIERS = [];
|
|
67086
|
+
var usePopper = function usePopper(referenceElement, popperElement, options) {
|
|
67087
|
+
if (options === void 0) {
|
|
67088
|
+
options = {};
|
|
67089
|
+
}
|
|
67090
|
+
|
|
67091
|
+
var prevOptions = React__namespace.useRef(null);
|
|
67092
|
+
var optionsWithDefaults = {
|
|
67093
|
+
onFirstUpdate: options.onFirstUpdate,
|
|
67094
|
+
placement: options.placement || 'bottom',
|
|
67095
|
+
strategy: options.strategy || 'absolute',
|
|
67096
|
+
modifiers: options.modifiers || EMPTY_MODIFIERS
|
|
67097
|
+
};
|
|
67098
|
+
|
|
67099
|
+
var _React$useState = React__namespace.useState({
|
|
67100
|
+
styles: {
|
|
67101
|
+
popper: {
|
|
67102
|
+
position: optionsWithDefaults.strategy,
|
|
67103
|
+
left: '0',
|
|
67104
|
+
top: '0'
|
|
67105
|
+
},
|
|
67106
|
+
arrow: {
|
|
67107
|
+
position: 'absolute'
|
|
67108
|
+
}
|
|
67109
|
+
},
|
|
67110
|
+
attributes: {}
|
|
67111
|
+
}),
|
|
67112
|
+
state = _React$useState[0],
|
|
67113
|
+
setState = _React$useState[1];
|
|
67114
|
+
|
|
67115
|
+
var updateStateModifier = React__namespace.useMemo(function () {
|
|
67116
|
+
return {
|
|
67117
|
+
name: 'updateState',
|
|
67118
|
+
enabled: true,
|
|
67119
|
+
phase: 'write',
|
|
67120
|
+
fn: function fn(_ref) {
|
|
67121
|
+
var state = _ref.state;
|
|
67122
|
+
var elements = Object.keys(state.elements);
|
|
67123
|
+
ReactDOM__namespace.flushSync(function () {
|
|
67124
|
+
setState({
|
|
67125
|
+
styles: fromEntries(elements.map(function (element) {
|
|
67126
|
+
return [element, state.styles[element] || {}];
|
|
67127
|
+
})),
|
|
67128
|
+
attributes: fromEntries(elements.map(function (element) {
|
|
67129
|
+
return [element, state.attributes[element]];
|
|
67130
|
+
}))
|
|
67131
|
+
});
|
|
67132
|
+
});
|
|
67133
|
+
},
|
|
67134
|
+
requires: ['computeStyles']
|
|
67135
|
+
};
|
|
67136
|
+
}, []);
|
|
67137
|
+
var popperOptions = React__namespace.useMemo(function () {
|
|
67138
|
+
var newOptions = {
|
|
67139
|
+
onFirstUpdate: optionsWithDefaults.onFirstUpdate,
|
|
67140
|
+
placement: optionsWithDefaults.placement,
|
|
67141
|
+
strategy: optionsWithDefaults.strategy,
|
|
67142
|
+
modifiers: [].concat(optionsWithDefaults.modifiers, [updateStateModifier, {
|
|
67143
|
+
name: 'applyStyles',
|
|
67144
|
+
enabled: false
|
|
67145
|
+
}])
|
|
67146
|
+
};
|
|
67147
|
+
|
|
67148
|
+
if (isEqual(prevOptions.current, newOptions)) {
|
|
67149
|
+
return prevOptions.current || newOptions;
|
|
67150
|
+
} else {
|
|
67151
|
+
prevOptions.current = newOptions;
|
|
67152
|
+
return newOptions;
|
|
67153
|
+
}
|
|
67154
|
+
}, [optionsWithDefaults.onFirstUpdate, optionsWithDefaults.placement, optionsWithDefaults.strategy, optionsWithDefaults.modifiers, updateStateModifier]);
|
|
67155
|
+
var popperInstanceRef = React__namespace.useRef();
|
|
67156
|
+
useIsomorphicLayoutEffect(function () {
|
|
67157
|
+
if (popperInstanceRef.current) {
|
|
67158
|
+
popperInstanceRef.current.setOptions(popperOptions);
|
|
67159
|
+
}
|
|
67160
|
+
}, [popperOptions]);
|
|
67161
|
+
useIsomorphicLayoutEffect(function () {
|
|
67162
|
+
if (referenceElement == null || popperElement == null) {
|
|
67163
|
+
return;
|
|
67164
|
+
}
|
|
67165
|
+
|
|
67166
|
+
var createPopper$1 = options.createPopper || createPopper;
|
|
67167
|
+
var popperInstance = createPopper$1(referenceElement, popperElement, popperOptions);
|
|
67168
|
+
popperInstanceRef.current = popperInstance;
|
|
67169
|
+
return function () {
|
|
67170
|
+
popperInstance.destroy();
|
|
67171
|
+
popperInstanceRef.current = null;
|
|
67172
|
+
};
|
|
67173
|
+
}, [referenceElement, popperElement, options.createPopper]);
|
|
67174
|
+
return {
|
|
67175
|
+
state: popperInstanceRef.current ? popperInstanceRef.current.state : null,
|
|
67176
|
+
styles: state.styles,
|
|
67177
|
+
attributes: state.attributes,
|
|
67178
|
+
update: popperInstanceRef.current ? popperInstanceRef.current.update : null,
|
|
67179
|
+
forceUpdate: popperInstanceRef.current ? popperInstanceRef.current.forceUpdate : null
|
|
67180
|
+
};
|
|
67181
|
+
};
|
|
67182
|
+
|
|
65153
67183
|
const rootId = "portal-fis-component";
|
|
65154
67184
|
function getDefaultContainer() {
|
|
65155
67185
|
let rootPortal = document.getElementById(rootId);
|
|
@@ -65338,7 +67368,7 @@ const FISCombobox = React.forwardRef(({ options, value, disabled = false, textLa
|
|
|
65338
67368
|
const [isOpen, setIsOpen] = React.useState(false);
|
|
65339
67369
|
const [referenceElement, setReferenceElement] = React.useState(null);
|
|
65340
67370
|
const [popperElement, setPopperElement] = React.useState(null);
|
|
65341
|
-
const { styles, attributes } =
|
|
67371
|
+
const { styles, attributes } = usePopper(referenceElement, popperElement, {
|
|
65342
67372
|
modifiers: [
|
|
65343
67373
|
{
|
|
65344
67374
|
name: "preventOverflow",
|