8 lines
22 KiB
JavaScript
8 lines
22 KiB
JavaScript
(self.webpackChunktradingview=self.webpackChunktradingview||[]).push([[9039],{59142:function(e,t){var o,n,r;n=[t],o=function(e){"use strict";function t(e){if(Array.isArray(e)){for(var t=0,o=Array(e.length);t<e.length;t++)o[t]=e[t];return o}return Array.from(e)}Object.defineProperty(e,"__esModule",{value:!0});var o=!1;if("undefined"!=typeof window){var n={get passive(){o=!0}};window.addEventListener("testPassive",null,n),window.removeEventListener("testPassive",null,n)}var r="undefined"!=typeof window&&window.navigator&&window.navigator.platform&&/iP(ad|hone|od)/.test(window.navigator.platform),l=[],i=!1,a=-1,s=void 0,c=void 0,u=function(e){return l.some((function(t){return!(!t.options.allowTouchMove||!t.options.allowTouchMove(e))}))},p=function(e){var t=e||window.event;return!!u(t.target)||1<t.touches.length||(t.preventDefault&&t.preventDefault(),!1)},d=function(){setTimeout((function(){void 0!==c&&(document.body.style.paddingRight=c,c=void 0),void 0!==s&&(document.body.style.overflow=s,s=void 0)}))};e.disableBodyScroll=function(e,n){if(r){if(!e)return void console.error("disableBodyScroll unsuccessful - targetElement must be provided when calling disableBodyScroll on IOS devices.");if(e&&!l.some((function(t){return t.targetElement===e}))){var d={targetElement:e,options:n||{}};l=[].concat(t(l),[d]),e.ontouchstart=function(e){1===e.targetTouches.length&&(a=e.targetTouches[0].clientY)},e.ontouchmove=function(t){var o,n,r,l;1===t.targetTouches.length&&(n=e,l=(o=t).targetTouches[0].clientY-a,!u(o.target)&&(n&&0===n.scrollTop&&0<l||(r=n)&&r.scrollHeight-r.scrollTop<=r.clientHeight&&l<0?p(o):o.stopPropagation()))},i||(document.addEventListener("touchmove",p,o?{passive:!1}:void 0),i=!0)}}else{h=n,setTimeout((function(){if(void 0===c){var e=!!h&&!0===h.reserveScrollBarGap,t=window.innerWidth-document.documentElement.clientWidth;e&&0<t&&(c=document.body.style.paddingRight,document.body.style.paddingRight=t+"px")}void 0===s&&(s=document.body.style.overflow,document.body.style.overflow="hidden")}));var m={targetElement:e,options:n||{}};l=[].concat(t(l),[m])}var h},e.clearAllBodyScrollLocks=function(){r?(l.forEach((function(e){e.targetElement.ontouchstart=null,e.targetElement.ontouchmove=null})),i&&(document.removeEventListener("touchmove",p,o?{passive:!1}:void 0),i=!1),l=[],a=-1):(d(),l=[])},e.enableBodyScroll=function(e){if(r){if(!e)return void console.error("enableBodyScroll unsuccessful - targetElement must be provided when calling enableBodyScroll on IOS devices.");e.ontouchstart=null,e.ontouchmove=null,l=l.filter((function(t){return t.targetElement!==e})),i&&0===l.length&&(document.removeEventListener("touchmove",p,o?{passive:!1}:void 0),i=!1)}else 1===l.length&&l[0].targetElement===e?(d(),l=[]):l=l.filter((function(t){return t.targetElement!==e}))}},void 0===(r="function"==typeof o?o.apply(t,n):o)||(e.exports=r)},97754:(e,t)=>{var o;!function(){"use strict";var n={}.hasOwnProperty;function r(){for(var e=[],t=0;t<arguments.length;t++){var o=arguments[t];if(o){var l=typeof o
|
|
;if("string"===l||"number"===l)e.push(o);else if(Array.isArray(o)&&o.length){var i=r.apply(null,o);i&&e.push(i)}else if("object"===l)for(var a in o)n.call(o,a)&&o[a]&&e.push(a)}}return e.join(" ")}e.exports?(r.default=r,e.exports=r):void 0===(o=function(){return r}.apply(t,[]))||(e.exports=o)}()},11985:e=>{e.exports={pills:"pills-PVWoXu5j",primary:"primary-PVWoXu5j",gray:"gray-PVWoXu5j",selected:"selected-PVWoXu5j",grouped:"grouped-PVWoXu5j",active:"active-PVWoXu5j",disableActiveOnTouch:"disableActiveOnTouch-PVWoXu5j",disableActiveStateStyles:"disableActiveStateStyles-PVWoXu5j",withGrouped:"withGrouped-PVWoXu5j","quiet-primary":"quiet-primary-PVWoXu5j",green:"green-PVWoXu5j",red:"red-PVWoXu5j",blue:"blue-PVWoXu5j",secondary:"secondary-PVWoXu5j",ghost:"ghost-PVWoXu5j"}},78457:e=>{e.exports={lightButton:"lightButton-bYDQcOkp",link:"link-bYDQcOkp",ltr:"ltr-bYDQcOkp",rtl:"rtl-bYDQcOkp","typography-regular16px":"typography-regular16px-bYDQcOkp","typography-medium16px":"typography-medium16px-bYDQcOkp","typography-regular14px":"typography-regular14px-bYDQcOkp","typography-semibold14px":"typography-semibold14px-bYDQcOkp","typography-semibold16px":"typography-semibold16px-bYDQcOkp",content:"content-bYDQcOkp",visuallyHidden:"visuallyHidden-bYDQcOkp",nowrap:"nowrap-bYDQcOkp",ellipsisContainer:"ellipsisContainer-bYDQcOkp",textWrapContainer:"textWrapContainer-bYDQcOkp",textWrapWithEllipsis:"textWrapWithEllipsis-bYDQcOkp",slot:"slot-bYDQcOkp",caret:"caret-bYDQcOkp",activeCaret:"activeCaret-bYDQcOkp",xsmall:"xsmall-bYDQcOkp",withStartSlot:"withStartSlot-bYDQcOkp",withEndSlot:"withEndSlot-bYDQcOkp",noContent:"noContent-bYDQcOkp",wrap:"wrap-bYDQcOkp",small:"small-bYDQcOkp",medium:"medium-bYDQcOkp"}},76773:e=>{e.exports={"default-drawer-min-top-distance":"100px",wrap:"wrap-_HnK0UIN",positionBottom:"positionBottom-_HnK0UIN",backdrop:"backdrop-_HnK0UIN",drawer:"drawer-_HnK0UIN",positionLeft:"positionLeft-_HnK0UIN"}},27011:(e,t,o)=>{"use strict";function n(e,t){return t||null==e||("string"==typeof e||Array.isArray(e))&&0===e.length}o.d(t,{isIconOnly:()=>n})},8025:(e,t,o)=>{"use strict";o.d(t,{useLightButtonClasses:()=>u});var n=o(50959),r=o(97754),l=o.n(r),i=o(17946),a=o(27011),s=o(86332);const c=n.createContext({isInButtonGroup:!1,isGroupPrimary:!1}),u=(e,t,o)=>{const r=(0,n.useContext)(i.CustomBehaviourContext),{className:u,isSelected:p,children:d,showCaret:m,forceDirection:h,iconOnly:f,color:v="gray",variant:g="primary",size:y="medium",enableActiveStateStyles:b=r.enableActiveStateStyles,typography:C,isLink:w=!1,textWrap:E,isPills:x,isActive:S,startSlot:k,endSlot:T}=t,O=e[`typography-${((e,t,o)=>{if(o){const e=o.replace(/^\D+/g,"");return t?`semibold${e}`:o}switch(e){case"xsmall":return t?"semibold14px":"regular14px";case"small":case"medium":return t?"semibold16px":"regular16px";default:return""}})(y,p||x,C||void 0)}`],N=(0,n.useContext)(s.ControlGroupContext),{isInButtonGroup:D,isGroupPrimary:B}=(0,n.useContext)(c);return l()(u,e.lightButton,w&&e.link,S&&e.active,p&&e.selected,(0,
|
|
a.isIconOnly)(d,f)&&e.noContent,!!k&&e.withStartSlot,(m||!!T)&&e.withEndSlot,o&&e.withGrouped,h&&e[h],e[B?"primary":g],e[B?"gray":v],e[y],O,!b&&e.disableActiveStateStyles,N.isGrouped&&e.grouped,E&&e.wrap,D&&e.disableActiveOnTouch,x&&e.pills)}},66860:(e,t,o)=>{"use strict";o.d(t,{LightButtonContent:()=>h});var n=o(50959),r=o(97754),l=o.n(r),i=o(34094),a=o(27011),s=o(9745),c=o(2948),u=o.n(c),p=o(78457),d=o.n(p);const m=e=>n.createElement(s.Icon,{className:l()(d().caret,e&&d().activeCaret),icon:u()});function h(e){const{showCaret:t,iconOnly:o,ellipsis:r=!0,textWrap:s,tooltipText:c,children:u,endSlot:p,startSlot:h,isActiveCaret:f}=e;[p,t].filter((e=>!!e));return n.createElement(n.Fragment,null,h&&n.createElement("span",{className:l()(d().slot,d().startSlot)},h),!(0,a.isIconOnly)(u,o)&&n.createElement("span",{className:l()(d().content,!s&&d().nowrap,"apply-overflow-tooltip","apply-overflow-tooltip--check-children-recursively","apply-overflow-tooltip--allow-text"),"data-overflow-tooltip-text":c??(0,i.getTextForTooltip)(u)},s||r?n.createElement(n.Fragment,null,n.createElement("span",{className:l()(!s&&r&&d().ellipsisContainer,s&&d().textWrapContainer,s&&r&&d().textWrapWithEllipsis)},u),n.createElement("span",{className:d().visuallyHidden,"aria-hidden":!0},u)):n.createElement(n.Fragment,null,u,n.createElement("span",{className:d().visuallyHidden,"aria-hidden":!0},u))),p&&n.createElement("span",{className:l()(d().slot,d().endSlot)},p),t&&m(f))}},15893:(e,t,o)=>{"use strict";o.d(t,{LightButton:()=>p});var n=o(50959),r=o(86332),l=o(8025),i=o(66860),a=o(78457),s=o.n(a),c=o(11985),u=o.n(c);function p(e){const{isGrouped:t}=n.useContext(r.ControlGroupContext),{reference:o,className:a,isSelected:c,children:p,iconOnly:d,ellipsis:m,showCaret:h,forceDirection:f,endSlot:v,startSlot:g,color:y,variant:b,size:C,enableActiveStateStyles:w,typography:E,textWrap:x=!1,maxLines:S,style:k={},isPills:T,isActive:O,tooltipText:N,role:D,...B}=e,W=x?S??2:1,F=W>0?{...k,"--ui-lib-light-button-content-max-lines":W}:k;return n.createElement("button",{...B,className:(0,l.useLightButtonClasses)({...u(),...s()},{className:a,isSelected:c,children:p,iconOnly:d,showCaret:h,forceDirection:f,endSlot:v,startSlot:g,color:y,variant:b,size:C,enableActiveStateStyles:w,typography:E,textWrap:x,isPills:T,isActive:O},t),ref:o,style:F,role:D},n.createElement(i.LightButtonContent,{showCaret:h,isActiveCaret:h&&(T||O||c),iconOnly:d,ellipsis:m,textWrap:x,tooltipText:N,endSlot:v,startSlot:g},p))}},86332:(e,t,o)=>{"use strict";o.d(t,{ControlGroupContext:()=>n});const n=o(50959).createContext({isGrouped:!1,cellState:{isTop:!0,isRight:!0,isBottom:!0,isLeft:!0}})},17946:(e,t,o)=>{"use strict";o.d(t,{CustomBehaviourContext:()=>n});const n=(0,o(50959).createContext)({enableActiveStateStyles:!0});n.displayName="CustomBehaviourContext"},34094:(e,t,o)=>{"use strict";o.d(t,{getTextForTooltip:()=>i});var n=o(50959);const r=e=>(0,
|
|
n.isValidElement)(e)&&Boolean(e.props.children),l=(e,t=!0)=>null==e||"boolean"==typeof e||"{}"===JSON.stringify(e)?"":e.toString()+(t?" ":""),i=e=>Array.isArray(e)||(0,n.isValidElement)(e)?n.Children.toArray(e).reduce(((e,t)=>{let o="";return o=(0,n.isValidElement)(t)&&r(t)?i(t.props.children):(0,n.isValidElement)(t)&&!r(t)?"":l(t),e.concat(o)}),"").trim():l(e,!1)},37558:(e,t,o)=>{"use strict";o.d(t,{DrawerContext:()=>i,DrawerManager:()=>l});var n=o(50959),r=o(99054);class l extends n.PureComponent{constructor(e){super(e),this._isBodyFixed=!1,this._addDrawer=e=>{this.setState((t=>({stack:[...t.stack,e]})))},this._removeDrawer=e=>{this.setState((t=>({stack:t.stack.filter((t=>t!==e))})))},this.state={stack:[]}}componentDidUpdate(e,t){!t.stack.length&&this.state.stack.length&&((0,r.setFixedBodyState)(!0),this._isBodyFixed=!0),t.stack.length&&!this.state.stack.length&&this._isBodyFixed&&((0,r.setFixedBodyState)(!1),this._isBodyFixed=!1)}componentWillUnmount(){this.state.stack.length&&this._isBodyFixed&&(0,r.setFixedBodyState)(!1)}render(){return n.createElement(i.Provider,{value:{addDrawer:this._addDrawer,removeDrawer:this._removeDrawer,currentDrawer:this.state.stack.length?this.state.stack[this.state.stack.length-1]:null}},this.props.children)}}const i=n.createContext(null)},41590:(e,t,o)=>{"use strict";o.d(t,{Drawer:()=>m});var n=o(50959),r=o(50151),l=o(97754),i=o(4226),a=o(65718),s=o(37558),c=o(29197),u=o(86656),p=o(76773);var d;function m(e){const{position:t="Bottom",onClose:o,children:u,reference:d,className:m,theme:f=p}=e,v=(0,r.ensureNotNull)((0,n.useContext)(s.DrawerContext)),[g]=(0,n.useState)((()=>(0,i.randomHash)())),y=(0,n.useRef)(null),b=(0,n.useContext)(c.CloseDelegateContext);return(0,n.useLayoutEffect)((()=>((0,r.ensureNotNull)(y.current).focus({preventScroll:!0}),b.subscribe(v,o),v.addDrawer(g),()=>{v.removeDrawer(g),b.unsubscribe(v,o)})),[]),n.createElement(a.Portal,null,n.createElement("div",{ref:d,className:l(p.wrap,p[`position${t}`])},g===v.currentDrawer&&n.createElement("div",{className:p.backdrop,onClick:o}),n.createElement(h,{className:l(f.drawer,p[`position${t}`],m),ref:y,"data-name":e["data-name"],"data-qa-id":e["data-qa-id"]},u)))}!function(e){e.Left="Left",e.Bottom="Bottom"}(d||(d={}));const h=(0,n.forwardRef)(((e,t)=>{const{className:o,...r}=e;return n.createElement(u.TouchScrollContainer,{className:l(p.drawer,o),tabIndex:-1,ref:t,...r})}))},20520:(e,t,o)=>{"use strict";o.d(t,{PopupMenu:()=>d});var n=o(50959),r=o(32227),l=o(88987),i=o(65718),a=o(27317),s=o(29197);const c=n.createContext(void 0);var u=o(36383);const p=n.createContext({setMenuMaxWidth:!1});function d(e){const{controller:t,children:o,isOpened:d,closeOnClickOutside:m=!0,doNotCloseOn:h,onClickOutside:f,onClose:v,onKeyboardClose:g,"data-name":y="popup-menu-container",closeOnScrollOutsideOffset:b,...C}=e,w=(0,n.useContext)(s.CloseDelegateContext),E=n.useContext(p),x=(0,n.useContext)(c),S=(0,u.useOutsideEvent)({handler:function(e){f&&f(e);if(!m)return;const t=(0,l.default)(h)?h():null==h?[]:[h]
|
|
;if(t.length>0&&e.target instanceof Node)for(const o of t){const t=r.findDOMNode(o);if(t instanceof Node&&t.contains(e.target))return}v()},mouseDown:!0,touchStart:!0});return d?n.createElement(i.Portal,{top:"0",left:"0",right:"0",bottom:"0",pointerEvents:"none"},n.createElement("span",{ref:S,style:{pointerEvents:"auto"}},n.createElement(a.Menu,{...C,onClose:v,onKeyboardClose:g,onScroll:function(t){const{onScroll:o}=e;o&&o(t)},customCloseDelegate:w,customRemeasureDelegate:x,ref:t,"data-name":y,limitMaxWidth:E.setMenuMaxWidth,"data-tooltip-show-on-focus":"true",closeOnScrollOutsideOffset:b},o))):null}},86656:(e,t,o)=>{"use strict";o.d(t,{TouchScrollContainer:()=>c});var n=o(50959),r=o(59142),l=o(50151),i=o(49483);const a=CSS.supports("overscroll-behavior","none");let s=0;const c=(0,n.forwardRef)(((e,t)=>{const{children:o,...l}=e,c=(0,n.useRef)(null);return(0,n.useImperativeHandle)(t,(()=>c.current)),(0,n.useLayoutEffect)((()=>{if(i.CheckMobile.iOS())return s++,null!==c.current&&(a?1===s&&(document.body.style.overscrollBehavior="none"):(0,r.disableBodyScroll)(c.current,{allowTouchMove:u(c)})),()=>{s--,null!==c.current&&(a?0===s&&(document.body.style.overscrollBehavior=""):(0,r.enableBodyScroll)(c.current))}}),[]),n.createElement("div",{ref:c,...l},o)}));function u(e){return t=>{const o=(0,l.ensureNotNull)(e.current),n=document.activeElement;return!o.contains(t)||null!==n&&o.contains(n)&&n.contains(t)}}},40173:(e,t,o)=>{"use strict";function n(e,t,o={}){return Object.assign({},e,function(e,t,o={}){const n=Object.assign({},t);for(const r of Object.keys(t)){const l=o[r]||r;l in e&&(n[r]=[e[l],t[r]].join(" "))}return n}(e,t,o))}o.d(t,{mergeThemes:()=>n})},51544:e=>{e.exports={drawer:"drawer-KpYsc6dH",drawerItem:"drawerItem-KpYsc6dH",menuWrap:"menuWrap-KpYsc6dH",scrollWrap:"scrollWrap-KpYsc6dH",menuBox:"menuBox-KpYsc6dH",card:"card-KpYsc6dH",fadeTop:"fadeTop-KpYsc6dH",fadeBottom:"fadeBottom-KpYsc6dH"}},36614:e=>{e.exports={wrap:"wrap-GPY6iGF_",title:"title-GPY6iGF_",content:"content-GPY6iGF_",mob:"mob-GPY6iGF_",subtitle:"subtitle-GPY6iGF_",group:"group-GPY6iGF_",text:"text-GPY6iGF_",mini:"mini-GPY6iGF_",anchor:"anchor-GPY6iGF_"}},86288:e=>{e.exports={subtitle:"subtitle-cEWFvaCX",text:"text-cEWFvaCX",group:"group-cEWFvaCX",groupIcon:"groupIcon-cEWFvaCX",beforeMarketOpen:"beforeMarketOpen-cEWFvaCX",afterMarketClose:"afterMarketClose-cEWFvaCX",groupTitle:"groupTitle-cEWFvaCX",groupRow:"groupRow-cEWFvaCX",groupCell:"groupCell-cEWFvaCX"}},60734:e=>{e.exports={lollipopTooltipTitle:"lollipopTooltipTitle-jFagU3Qi",lollipopTooltipTitle_minimal:"lollipopTooltipTitle_minimal-jFagU3Qi",lollipopTooltipTitle__title:"lollipopTooltipTitle__title-jFagU3Qi",lollipopTooltipTitle_mobile:"lollipopTooltipTitle_mobile-jFagU3Qi",lollipopTooltipTitle__icon:"lollipopTooltipTitle__icon-jFagU3Qi"}},92892:(e,t,o)=>{"use strict";o.r(t),o.d(t,{showLollipopTooltip:()=>L});var n=o(50959),r=o(32227),l=o(50151),i=o(20057);function a(e,t,o){(0,n.useEffect)((()=>{const n=new IntersectionObserver((e=>{e[e.length-1].intersectionRatio<.25?o():t()}),{
|
|
threshold:[0,.25,.5,.75,1],root:null,rootMargin:"0px"});return e.current&&n.observe(e.current),()=>n.disconnect()}),[])}var s=o(90692),c=o(41590),u=o(37558),p=o(20520),d=o(87713),m=o(68335),h=o(87465);const f=(0,n.forwardRef)(((e,t)=>{const{onClose:o,onForceClose:r,onClickOutside:l,className:i,...a}=e,s=(0,n.useRef)(null);(0,n.useEffect)((()=>(d.globalCloseDelegate.subscribe(null,r),()=>{d.globalCloseDelegate.unsubscribe(null,r)})),[r]);const c=(0,n.useCallback)((t=>{e.onKeyDown?.(t),27===(0,m.hashFromEvent)(t)&&(t.preventDefault(),r())}),[r]),u=(0,n.useCallback)((()=>{s.current&&s.current.focus({preventScroll:!0})}),[]);return n.createElement(p.PopupMenu,{className:i,isOpened:!0,tabIndex:-1,reference:e=>{"function"==typeof t?t(e):(0,h.isObject)(t)&&(t.current=e),s.current=e},onClose:o,onClickOutside:l,onKeyDown:c,onOpen:u,...a},e.children)}));function v(e){(0,n.useEffect)((()=>{return e=g,window.addEventListener("scroll",e),()=>window.removeEventListener("scroll",e);var e}),[]),(0,n.useEffect)((()=>{if(e.length)return function(e,t){for(const o of e)o.subscribe(null,t);return()=>{for(const o of e)o.unsubscribe(null,t)}}(e,g)}),e)}function g(){(0,d.globalCloseMenu)()}f.displayName="TooltipPopup";var y=o(40173),b=o(27317),C=o(97754),w=o.n(C),E=o(9745),x=o(60734);function S(e){const{title:t,icon:o,iconStyle:r,className:l,cardType:i,informationButtonProps:a}=e;return n.createElement("div",{className:w()(x.lollipopTooltipTitle,["mob"===i&&x.lollipopTooltipTitle_mobile,"mini"===i&&x.lollipopTooltipTitle_minimal],l)},o&&n.createElement(E.Icon,{icon:o,className:x.lollipopTooltipTitle__icon,style:r}),n.createElement("span",{className:x.lollipopTooltipTitle__title},t),!1)}var k=o(15893);function T(e){const{text:t,onClick:o}=e;return n.createElement(k.LightButton,{onClick:o,size:"xsmall"}," ",t," ")}var O,N=o(86288);function D(e){const{name:t,value:o,style:r,valueStyle:l,onValueClick:i,valueRightIcon:a,className:s}=e;return n.createElement("div",{className:w()(N.groupRow,s),style:r},t&&n.createElement("div",{className:N.groupCell},n.createElement("span",{className:N.text},t)),n.createElement("div",{className:N.groupCell},n.createElement("span",{className:N.text,style:l,onClick:i},o),a&&n.createElement(E.Icon,{icon:a.iconContent,className:w()(N.groupIcon,a.iconClass,"apply-common-tooltip"),title:a.tooltipText})))}function B(e){const{content:t=[],title:o,cardRowClass:r}=e,l=t.map(((e,t)=>{const{title:o,content:r}=e;return n.createElement("div",{key:`group${t}`,className:N.group},o&&n.createElement("span",{className:N.groupTitle},o),r.map(((e,t)=>n.createElement(D,{key:`contentRow${t}`,...e}))))})),i="string"==typeof o?o:o.map(((e,t)=>n.createElement(D,{key:`subTitle${t}`,...e})));return n.createElement("div",{className:r},n.createElement("span",{className:N.subtitle},i),l.length>0&&n.createElement("div",null,l))}function W(e){return"common"===e.type?n.createElement(B,{...e}):n.createElement(n.Fragment,null)}!function(e){e[e.BeforeMarketOpen=N.beforeMarketOpen]="BeforeMarketOpen",
|
|
e[e.AfterMarketClose=N.afterMarketClose]="AfterMarketClose"}(O||(O={}));var F=o(36614);const _=F;var P;function Y(e){const{cardType:t,anchor:o,title:r,icon:l,informationButtonProps:i,style:a,theme:s=F,main:c}=e,u=w()(s.content,t&&s[t]),p=(0,n.useMemo)((()=>r&&l?{color:a?.color}:void 0),[!!r,!!l,a?.color]),d=a?{borderColor:a.color}:{borderStyle:"none"};return n.createElement("div",{className:s.wrap,style:d},n.createElement("div",{className:u},r&&n.createElement(S,{title:r,icon:l,informationButtonProps:i,iconStyle:p,cardType:t,className:s.title}),n.createElement(W,{...c}),o&&("mob"!==t||!o.hideInMobileMode)&&n.createElement("div",{className:s.anchor},n.createElement(T,{...o}))))}!function(e){e.Mobile="mob",e.Minimal="mini"}(P||(P={}));var M=o(51544);const A=(0,y.mergeThemes)(b.DEFAULT_MENU_THEME,{menuWrap:M.menuWrap,menuBox:M.menuBox}),G=(0,y.mergeThemes)(_,{wrap:M.drawerItem}),Q=(0,y.mergeThemes)(_,{wrap:M.card});function j(e){const{tooltips:t,onClose:o,onClickOutside:r,onSizeChanged:l,position:p,customCloseSubscriptions:d=[],showScrollFades:m,cardType:h,theme:g,reference:b}=e,C=(0,n.useRef)(null),w=(0,n.useRef)(null),E=(0,n.useRef)(null),x=(0,n.useRef)(null),S=(0,n.useRef)(null),[k,T]=(0,n.useState)("100%"),O=e=>{null!==e&&T(`${e.clientWidth}px`)},[N,D]=(0,n.useState)(!1);a(x,(()=>D(!1)),(()=>D(!0)));const B={display:N?"block":"none",width:k},[W,F]=(0,n.useState)(!1);a(S,(()=>F(!1)),(()=>F(!0)));const _={display:W?"block":"none",width:k};return v(d),(0,n.useEffect)((()=>o),[]),(0,n.useEffect)((()=>{C.current&&C.current.update()}),[p]),(0,n.useEffect)((()=>{if(l){const e={};return l.subscribe(e,(0,i.default)((()=>{C.current&&C.current.update()}),100)),()=>{l.unsubscribeAll(e)}}}),[]),n.createElement(u.DrawerManager,null,n.createElement(s.MatchMedia,{rule:"(max-width: 419px)"},(e=>e?n.createElement(c.Drawer,{className:M.drawer,onClose:o,position:"Bottom",reference:b},t.map(((e,t)=>n.createElement(Y,{key:`${t}`,theme:(0,y.mergeThemes)(G,g??{}),cardType:"mob",...e})))):n.createElement(f,{ref:b,position:p,theme:A,onClose:o,onForceClose:o,onClickOutside:r,closeOnClickOutside:!1,controller:C},m&&n.createElement(n.Fragment,null,n.createElement("div",{ref:w,className:M.fadeTop,style:B}),n.createElement("div",{ref:x})),n.createElement("div",{ref:O},t.map(((e,t)=>n.createElement(Y,{theme:(0,y.mergeThemes)(Q,g??{}),key:`${t}`,cardType:h,...e})))),m&&n.createElement(n.Fragment,null,n.createElement("div",{ref:S}),n.createElement("div",{ref:E,className:M.fadeBottom,style:_}))))))}let I=null;const R=n.createRef();function L(e){if(!e.items.length)return null;const{items:t,onClose:o,onClickOutside:l,onSizeChanged:i,position:a,customCloseSubscriptions:s,showScrollFades:c,cardType:u,theme:p}=e,d={tooltips:t,onClose:o,onClickOutside:e=>l(e),onSizeChanged:i,position:X.bind(null,a),customCloseSubscriptions:s,showScrollFades:c,cardType:u,theme:p,reference:R};return null===I&&(I=document.createElement("div"),document.body.appendChild(I)),r.render(n.createElement(j,{...d}),I),{hide:H,
|
|
isClickInside:e=>null!==R.current&&R.current.contains(e.target)}}function H(){null!==I&&(r.unmountComponentAtNode(I),I.remove(),I=null)}function X(e,t){const{contentWidth:o,contentHeight:n}=t,r=e.target,i=r.getBoundingClientRect(),a=i.width-e.targetSize.width,s=i.height-e.targetSize.height,c=(0,l.ensureNotNull)(r.closest(".chart-container")),u=c.getBoundingClientRect(),p=(0,l.ensureNotNull)(c.parentElement).getBoundingClientRect(),d=i.left+e.point.x+a,m=Math.round(d-o/2),h=Math.min(m+o,u.right,p.right);let f,v,g=Math.max(h-o,u.left,p.left);g+o>=p.right&&(g=p.right-o);const y=u.bottom-(i.top+e.point.y+s),b=u.height-y-e.marginTop;return b<n?(v=e.marginTop+u.top,f=Math.max(b,0)):v=u.height+u.top-y-n,{x:g,y:v,overrideHeight:f}}},2948:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 18 18" width="18" height="18"><path fill="currentColor" d="M3.92 7.83 9 12.29l5.08-4.46-1-1.13L9 10.29l-4.09-3.6-.99 1.14Z"/></svg>'},25931:(e,t,o)=>{"use strict";o.d(t,{nanoid:()=>n});let n=(e=21)=>crypto.getRandomValues(new Uint8Array(e)).reduce(((e,t)=>e+=(t&=63)<36?t.toString(36):t<62?(t-26).toString(36).toUpperCase():t>62?"-":"_"),"")}}]); |