(self.webpackChunktradingview=self.webpackChunktradingview||[]).push([[2477],{97754:(e,t)=>{var n;!function(){"use strict";var s={}.hasOwnProperty;function r(){for(var e=[],t=0;t<arguments.length;t++){var n=arguments[t];if(n){var i=typeof n;if("string"===i||"number"===i)e.push(n);else if(Array.isArray(n)&&n.length){var o=r.apply(null,n);o&&e.push(o)}else if("object"===i)for(var a in n)s.call(n,a)&&n[a]&&e.push(a)}}return e.join(" ")}e.exports?(r.default=r,e.exports=r):void 0===(n=function(){return r}.apply(t,[]))||(e.exports=n)}()},17946:(e,t,n)=>{"use strict";n.d(t,{CustomBehaviourContext:()=>s});const s=(0,n(50959).createContext)({enableActiveStateStyles:!0});s.displayName="CustomBehaviourContext"},43010:(e,t,n)=>{"use strict";n.d(t,{useIsomorphicLayoutEffect:()=>r});var s=n(50959);function r(e,t){("undefined"==typeof window?s.useEffect:s.useLayoutEffect)(e,t)}},27267:(e,t,n)=>{"use strict";function s(e,t,n,s,r){function i(r){if(e>r.timeStamp)return;const i=r.target;void 0!==n&&null!==t&&null!==i&&i.ownerDocument===s&&(t.contains(i)||n(r))}return r.click&&s.addEventListener("click",i,!1),r.mouseDown&&s.addEventListener("mousedown",i,!1),r.touchEnd&&s.addEventListener("touchend",i,!1),r.touchStart&&s.addEventListener("touchstart",i,!1),()=>{s.removeEventListener("click",i,!1),s.removeEventListener("mousedown",i,!1),s.removeEventListener("touchend",i,!1),s.removeEventListener("touchstart",i,!1)}}n.d(t,{addOutsideEventListener:()=>s})},9745:(e,t,n)=>{"use strict";n.d(t,{Icon:()=>r});var s=n(50959);const r=s.forwardRef(((e,t)=>{const{icon:n="",title:r,ariaLabel:i,ariaLabelledby:o,ariaHidden:a,...l}=e,u=!!(r||i||o);return s.createElement("span",{role:"img",...l,ref:t,"aria-label":i,"aria-labelledby":o,"aria-hidden":a||!u,title:r,dangerouslySetInnerHTML:{__html:n}})}))},19250:(e,t,n)=>{"use strict";n.d(t,{Portal:()=>u,PortalContext:()=>d});var s=n(50959),r=n(32227),i=n(25931),o=n(67961),a=n(34811),l=n(99663);class u extends s.PureComponent{constructor(){super(...arguments),this._uuid=(0,i.nanoid)()}componentWillUnmount(){this._manager().removeWindow(this._uuid)}render(){const e=this._manager().ensureWindow(this._uuid,this.props.layerOptions);e.style.top=this.props.top||"",e.style.bottom=this.props.bottom||"",e.style.left=this.props.left||"",e.style.right=this.props.right||"",e.style.pointerEvents=this.props.pointerEvents||"";const t=this.props.className;return t&&("string"==typeof t?e.classList.add(t):e.classList.add(...t)),this.props.shouldTrapFocus&&!e.hasAttribute(a.FOCUS_TRAP_DATA_ATTRIBUTE)&&e.setAttribute(a.FOCUS_TRAP_DATA_ATTRIBUTE,"true"),this.props["aria-hidden"]&&e.setAttribute("aria-hidden","true"),r.createPortal(s.createElement(d.Provider,{value:this},this.props.children),e)}moveToTop(){this._manager().moveToTop(this._uuid)}_manager(){return null===this.context?(0,o.getRootOverlapManager)():this.context}}u.contextType=l.SlotContext;const d=s.createContext(null)},99663:(e,t,n)=>{"use strict";n.d(t,{Slot:()=>r,SlotContext:()=>i});var s=n(50959);class r extends s.Component{shouldComponentUpdate(){return!1}
render(){return s.createElement("div",{style:{position:"fixed",zIndex:150,left:0,top:0},ref:this.props.reference})}}const i=s.createContext(null)},90186:(e,t,n)=>{"use strict";function s(e){return i(e,o)}function r(e){return i(e,a)}function i(e,t){const n=Object.entries(e).filter(t),s={};for(const[e,t]of n)s[e]=t;return s}function o(e){const[t,n]=e;return 0===t.indexOf("data-")&&"string"==typeof n}function a(e){return 0===e[0].indexOf("aria-")}n.d(t,{filterAriaProps:()=>r,filterDataProps:()=>s,filterProps:()=>i,isAriaAttribute:()=>a,isDataAttribute:()=>o})},67961:(e,t,n)=>{"use strict";n.d(t,{OverlapManager:()=>o,getRootOverlapManager:()=>l});var s=n(50151),r=n(34811);class i{constructor(){this._storage=[]}add(e){this._storage.push(e)}remove(e){this._storage=this._storage.filter((t=>e!==t))}has(e){return this._storage.includes(e)}getItems(){return this._storage}}class o{constructor(e=document){this._storage=new i,this._windows=new Map,this._index=0,this._document=e,this._container=e.createDocumentFragment()}setContainer(e){const t=this._container,n=null===e?this._document.createDocumentFragment():e;!function(e,t){Array.from(e.childNodes).forEach((e=>{e.nodeType===Node.ELEMENT_NODE&&t.appendChild(e)}))}(t,n),this._container=n}registerWindow(e){this._storage.has(e)||this._storage.add(e)}ensureWindow(e,t={position:"fixed",direction:"normal"}){const n=this._windows.get(e);if(void 0!==n)return n;this.registerWindow(e);const s=this._document.createElement("div");if(s.style.position=t.position,s.style.zIndex=this._index.toString(),s.dataset.id=e,void 0!==t.index){const e=this._container.childNodes.length;if(t.index>=e)this._container.appendChild(s);else if(t.index<=0)this._container.insertBefore(s,this._container.firstChild);else{const e=this._container.childNodes[t.index];this._container.insertBefore(s,e)}}else"reverse"===t.direction?this._container.insertBefore(s,this._container.firstChild):this._container.appendChild(s);return this._windows.set(e,s),++this._index,s}unregisterWindow(e){this._storage.remove(e);const t=this._windows.get(e);void 0!==t&&(null!==t.parentElement&&t.parentElement.removeChild(t),this._windows.delete(e))}getZindex(e){const t=this.ensureWindow(e);return parseInt(t.style.zIndex||"0")}moveLastWindowToTop(){const e=this._storage.getItems(),t=e[e.length-1];t&&this.moveToTop(t)}moveToTop(e){if(this.getZindex(e)!==this._index){const t=this.ensureWindow(e);this._windows.forEach(((e,n)=>{e.hasAttribute(r.FOCUS_TRAP_DATA_ATTRIBUTE)&&e.setAttribute(r.FOCUS_TRAP_DATA_ATTRIBUTE,e===t?"true":"false")})),t.style.zIndex=(++this._index).toString()}}removeWindow(e){this.unregisterWindow(e)}}const a=new WeakMap;function l(e=document){const t=e.getElementById("overlap-manager-root");if(null!==t)return(0,s.ensureDefined)(a.get(t));{const t=new o(e),n=function(e){const t=e.createElement("div");return t.style.position="absolute",t.style.zIndex=150..toString(),t.style.top="0px",t.style.left="0px",t.id="overlap-manager-root",t.dataset.qaId="overlap-manager-root",t}(e);return a.set(n,t),t.setContainer(n),
e.body.appendChild(n),t}}var u;!function(e){e[e.BaseZindex=150]="BaseZindex"}(u||(u={}))},36279:(e,t,n)=>{"use strict";var s;n.d(t,{LogoSize:()=>s,getLogoUrlResolver:()=>o}),function(e){e[e.Medium=0]="Medium",e[e.Large=1]="Large"}(s||(s={}));class r{getSymbolLogoUrl(e){return e}collectSymbolLogoUrls(e,t){return[]}getCountryFlagUrl(){return""}getCryptoLogoUrl(e){return e}getProviderLogoUrl(e){return e}getSourceLogoUrl(e){return e}getBlockchainContractLogoUrl(e){return e}}let i;function o(){return i||(i=new r),i}},77975:(e,t,n)=>{"use strict";n.d(t,{useWatchedValueReadonly:()=>r});var s=n(50959);const r=(e,t=!1,n=[])=>{const r="watchedValue"in e?e.watchedValue:void 0,i="defaultValue"in e?e.defaultValue:e.watchedValue.value(),[o,a]=(0,s.useState)(r?r.value():i);return(t?s.useLayoutEffect:s.useEffect)((()=>{if(r){a(r.value());const e=e=>a(e);return r.subscribe(e),()=>r.unsubscribe(e)}return()=>{}}),[r,...n]),o}},4237:(e,t,n)=>{"use strict";var s=n(32227);t.createRoot=s.createRoot,s.hydrateRoot},47596:e=>{e.exports={wrapper:"wrapper-hPiAkrn3",timezone:"timezone-hPiAkrn3",largePadding:"largePadding-hPiAkrn3",sessionDayWrapper:"sessionDayWrapper-hPiAkrn3",nowWrapper:"nowWrapper-hPiAkrn3",now:"now-hPiAkrn3",sessionDay:"sessionDay-hPiAkrn3",weekDay:"weekDay-hPiAkrn3",sessionDaySegments:"sessionDaySegments-hPiAkrn3",timeMarkWrapper:"timeMarkWrapper-hPiAkrn3",timeMarkSegment:"timeMarkSegment-hPiAkrn3",timeMark:"timeMark-hPiAkrn3",timeMarkSegmentAlignByEnds:"timeMarkSegmentAlignByEnds-hPiAkrn3",segment:"segment-hPiAkrn3",small:"small-hPiAkrn3",start:"start-hPiAkrn3",end:"end-hPiAkrn3",active:"active-hPiAkrn3",green:"green-hPiAkrn3",orange:"orange-hPiAkrn3",blue:"blue-hPiAkrn3",gray:"gray-hPiAkrn3",tooltip:"tooltip-hPiAkrn3",time:"time-hPiAkrn3"}},1445:(e,t,n)=>{"use strict";n.d(t,{FullSessionScheduleRenderer:()=>A});var s=n(50959),r=n(97754),i=n(50151),o=n(11542),a=n(77975),l=n(4226),u=n(47596);const d=new WeakMap;function c(e){return d.has(e)||d.set(e,(0,l.randomHash)()),(0,i.ensureDefined)(d.get(e))}const m=new Map([[0,u.green],[1,u.orange],[2,u.blue],[3,u.gray]]),h=new Map([[0,o.t(null,void 0,n(80086))],[1,o.t(null,void 0,n(36018))],[2,o.t(null,void 0,n(73897))],[3,o.t(null,void 0,n(62464))]]),v=o.t(null,void 0,n(63538));var p;function f(e){const{segment:t,forceStart:n,forceEnd:i}=e,o=t.end.value-t.start.value,a=o<.03,l={left:100*t.start.value+"%",width:`calc(${100*o}% + ${a?2:0}px)`},d=r(u.segment,m.get(t.type),(n||t.start.isFirstOrLastPoint)&&u.start,(i||t.end.isFirstOrLastPoint)&&u.end,a&&u.small,"common-tooltip-html","apply-common-tooltip"),c=function(e,t){return`<div class="${u.tooltip}">\n\t\t<span class="${m.get(t)}">${h.get(t)}</span>\n\t\t<span class="${u.time}">${e}</span>\n\t</div>`}(t.tooltip,t.type);return s.createElement("div",{className:d,style:l,"data-tooltip":c})}function y(e){const{sessionDay:t}=e,n=t.entries.map(((e,n)=>s.createElement(f,{key:`${c(e)}Segment`,segment:e,forceStart:0===n&&3===e.type,forceEnd:n===t.entries.length-1&&3===e.type}))),i=r(u.sessionDay,t.isActive&&u.active)
;return s.createElement("div",{className:i},s.createElement("div",{className:u.weekDay},t.title),s.createElement("div",{className:u.sessionDaySegments},n))}function g(e){const{sessionDays:t,currentTimeMark:n}=e,i=[],o=parseInt(Object.keys(t).filter((e=>t[parseInt(e)].isActive))[0]),a=t[o].entries.filter((e=>e.start.value<=n&&e.end.value>=n))[0];if((a.start.isFirstOrLastPoint||3===a.type)&&i.push(a.start),(a.end.isFirstOrLastPoint||3===a.type)&&i.push(a.end),0===i.length)return null;i.sort(((e,t)=>e.value-t.value));const l=i.map((e=>s.createElement("div",{key:c(e),className:u.timeMark},e.title))),d=100*(2===i.length?i[1].value-i[0].value:0),m=r(d>12&&u.timeMarkSegmentAlignByEnds,u.timeMarkSegment);return s.createElement("div",{className:u.sessionDay},s.createElement("div",{className:u.weekDay}),s.createElement("div",{className:u.timeMarkWrapper},s.createElement("div",{className:m,style:{left:100*i[0].value+"%",width:`${d}%`}},l)))}function A(e){const{className:t,timezone:n,showAllDays:i,timeZoneClassName:o}=e,l=(0,a.useWatchedValueReadonly)({watchedValue:e.sessionDays}),d=(0,a.useWatchedValueReadonly)({watchedValue:e.now}),c=Object.values(l).filter((e=>e.isActive))[0],m=r(t,u.wrapper);return s.createElement("div",{className:m},s.createElement("div",{className:u.sessionDayWrapper},i?s.createElement(s.Fragment,null,Object.values(l).map(((e,t)=>s.createElement(y,{key:t,sessionDay:e})))):s.createElement(y,{sessionDay:c}),s.createElement("div",{className:u.nowWrapper},s.createElement("div",{className:u.now,style:{left:100*d+"%"}}))),s.createElement(g,{sessionDays:l,currentTimeMark:d}),s.createElement("div",{className:r(u.timezone,o,i&&u.largePadding)},`${v}: ${n}`))}!function(e){e[e.MinSegmentWidth=12]="MinSegmentWidth",e[e.SmallWidth=.03]="SmallWidth"}(p||(p={}))},22166:(e,t,n)=>{"use strict";n.d(t,{FullSessionScheduleViewModel:()=>G});var s=n(10845),r=n(87465),i=n(37236),o=n(22613),a=n(95059);function l(e){return e/i.minutesPerDay}function u(e){return Math.round(e*i.minutesPerDay)}var d,c,m=n(50151),h=n(58043);!function(e){e[e.SUNDAY=1]="SUNDAY",e[e.MONDAY=2]="MONDAY",e[e.TUESDAY=3]="TUESDAY",e[e.WEDNESDAY=4]="WEDNESDAY",e[e.THURSDAY=5]="THURSDAY",e[e.FRIDAY=6]="FRIDAY",e[e.SATURDAY=7]="SATURDAY"}(d||(d={})),function(e){e[e.JANUARY=0]="JANUARY",e[e.FEBRUARY=1]="FEBRUARY",e[e.MARCH=2]="MARCH",e[e.APRIL=3]="APRIL",e[e.MAY=4]="MAY",e[e.JUNE=5]="JUNE",e[e.JULY=6]="JULY",e[e.AUGUST=7]="AUGUST",e[e.SEPTEMBER=8]="SEPTEMBER",e[e.OCTOBER=9]="OCTOBER",e[e.NOVEMBER=10]="NOVEMBER",e[e.DECEMBER=11]="DECEMBER"}(c||(c={}));const v=[d.SUNDAY,d.MONDAY,d.TUESDAY,d.WEDNESDAY,d.THURSDAY,d.FRIDAY,d.SATURDAY];function p(e){return t=>function(e,t){return(e+t+6)%7+1}(t,e)}const f=p(-1),y=p(1);const g=function(e){return e&&e.length?e[0]:void 0};var A=n(82593),E=n(11542);c.JANUARY,E.t(null,void 0,n(200)),c.FEBRUARY,E.t(null,void 0,n(81069)),c.MARCH,E.t(null,void 0,n(93878)),c.APRIL,E.t(null,void 0,n(28896)),c.MAY,E.t(null,void 0,n(25734)),c.JUNE,E.t(null,void 0,n(61487)),c.JULY,E.t(null,void 0,n(6608)),c.AUGUST,E.t(null,void 0,n(11081)),
c.SEPTEMBER,E.t(null,void 0,n(32179)),c.OCTOBER,E.t(null,void 0,n(37997)),c.NOVEMBER,E.t(null,void 0,n(4607)),c.DECEMBER,E.t(null,void 0,n(90082)),c.JANUARY,E.t(null,void 0,n(62310)),c.FEBRUARY,E.t(null,void 0,n(2507)),c.MARCH,E.t(null,void 0,n(92767)),c.APRIL,E.t(null,void 0,n(27072)),c.MAY,E.t(null,{context:"short"},n(13132)),c.JUNE,E.t(null,void 0,n(429)),c.JULY,E.t(null,void 0,n(53786)),c.AUGUST,E.t(null,void 0,n(46450)),c.SEPTEMBER,E.t(null,void 0,n(6816)),c.OCTOBER,E.t(null,void 0,n(12179)),c.NOVEMBER,E.t(null,void 0,n(26899)),c.DECEMBER,E.t(null,void 0,n(32084)),d.SUNDAY,E.t(null,void 0,n(61480)),d.MONDAY,E.t(null,void 0,n(19573)),d.TUESDAY,E.t(null,void 0,n(82160)),d.WEDNESDAY,E.t(null,void 0,n(94226)),d.THURSDAY,E.t(null,void 0,n(79137)),d.FRIDAY,E.t(null,void 0,n(3570)),d.SATURDAY,E.t(null,void 0,n(30348));const _={[d.SUNDAY]:E.t(null,void 0,n(77493)),[d.MONDAY]:E.t(null,void 0,n(50872)),[d.TUESDAY]:E.t(null,void 0,n(11916)),[d.WEDNESDAY]:E.t(null,void 0,n(11532)),[d.THURSDAY]:E.t(null,void 0,n(71388)),[d.FRIDAY]:E.t(null,void 0,n(22928)),[d.SATURDAY]:E.t(null,void 0,n(32273))};d.SUNDAY,E.t(null,{context:"day_of_week"},n(75005)),d.MONDAY,E.t(null,{context:"day_of_week"},n(30961)),d.TUESDAY,E.t(null,{context:"day_of_week"},n(9135)),d.WEDNESDAY,E.t(null,{context:"day_of_week"},n(92578)),d.THURSDAY,E.t(null,{context:"day_of_week"},n(8765)),d.FRIDAY,E.t(null,{context:"day_of_week"},n(23230)),d.SATURDAY,E.t(null,{context:"day_of_week"},n(94748));var D=n(95322);function w(e){for((0,m.assert)(Number.isInteger(e),"timeMinutes expected to be integer number");e>i.minutesPerDay;)e-=i.minutesPerDay;const t=e%60,n=(e-t)/60;return(0,D.numberToStringWithLeadingZero)(n,2)+":"+(0,D.numberToStringWithLeadingZero)(t,2)}function S(e,t){return`${e} — ${t}`}function T(e,t){return`${_[e]} ${w(t)}`}function x(e,t,n,s){(0,m.assert)(t!==i.minutesPerDay,"Start time expected to be normalized (24:00 as range start is not allowed)"),(0,m.assert)(0!==s,"End time expected to be normalized (00:00 as range end is not allowed)");const r=function(e,t,n,s){const r=e*i.minutesPerDay+t;let o=n*i.minutesPerDay+s;return o<r&&(o+=7*i.minutesPerDay),o-r}(e,t,n,s);return r<i.minutesPerDay||r===i.minutesPerDay&&0===t?function(e,t){return S(w(e),w(t))}(t,s):function(e,t,n,s){return S(T(e,t),T(n,s))}(e,t,n,s)}function R(e,t){return{value:e,title:w(u(e)),isFirstOrLastPoint:t}}function k(e){return 3!==e.type}function U(e,t){return{dayIndex:e,entries:t.filter(k)}}function P(e,t,n,s=t){const r=n(t),i=e[r];return r!==s&&0===i.entries.length?P(e,r,n,s):U(r,e[r].entries)}function M(e){return(t,n)=>P(t,n,e)}const b=M(f),I=M(y);function N(e,t,n,s){return(r,i,o)=>void 0===r?[s,o]:r===e?[t,n(i)]:[r,i]}const Y=N(1,0,y,0),C=N(0,1,f,1);function L(e,t,n,s,r){const[i,o]=Y(e,t,r),[a,l]=C(n,s,r);(0,m.assert)(t!==n||i<a,`Days are same (${t}) but prev entry time (${i}) >= next entry time (${a})`);const d=u(i),c=u(a);return h=R(o!==r?0:i,o===r),v=R(l!==r?1:a,l===r),p=3,f=x(o,d,l,c),{start:h,end:v,type:p,tooltip:f};var h,v,p,f}function W(e,t,n,s,r){
return L(e?.end?.value,t,n?.start?.value,s,r)}function O(e){const t=[...e.entries];for(let n=1;n<e.entries.length;n++){const s=e.entries[n-1],r=e.entries[n];if(r.start.value!==s.end.value){const n=W(s,e.dayIndex,r,e.dayIndex,e.dayIndex);t.push(n)}}return t.sort(((e,t)=>e.start.value-t.start.value)),t}function B(e,t){const n=(0,A.default)(t.entries),s=t.dayIndex,r=(0,m.ensureDefined)(g(e.entries));return 0===r.start.value?[]:[W(n,s,r,e.dayIndex,e.dayIndex)]}function F(e,t){const n=g(t.entries),s=t.dayIndex,r=(0,m.ensureDefined)((0,A.default)(e.entries));return 1===r.end.value?[]:[W(r,e.dayIndex,n,s,e.dayIndex)]}function V(e,t){const n={thisDay:U(e,t[e].entries),prevDay:b(t,e),nextDay:I(t,e)};return function({thisDay:e,prevDay:t,nextDay:n}){if(0===e.entries.length)return[W((0,A.default)(t.entries),t.dayIndex,g(n.entries),n.dayIndex,e.dayIndex)]}(n)??function({thisDay:e,prevDay:t,nextDay:n}){const s=e.dayIndex;if(t.dayIndex!==s||n.dayIndex!==s)return;const i=e.entries,o=(0,m.ensureDefined)(g(i)),a=(0,m.ensureDefined)((0,A.default)(i));return[0!==o.start.value?L(0,s,o.start.value,s,s):void 0,...O(e),1!==a.end.value?L(a.end.value,s,1,s,s):void 0].filter(r.isExistent)}(n)??function(e){return[...B(e.thisDay,e.prevDay),...O(e.thisDay),...F(e.thisDay,e.nextDay)]}(n)}var z=n(16329);const $=function(e){for(var t=-1,n=null==e?0:e.length,s={};++t<n;){var r=e[t];s[r[0]]=r[1]}return s}(v.map((e=>[e,{title:_[e],isActive:!1,entries:[]}])));function H(e,t,n){const s=e[n].entries;s.push(t),s.sort(((e,t)=>e.start.value-t.start.value))}function J(e,t){const n=function(e){if(null===e)return new Map;if(void 0===e.subsessions)return new Map([[0,new z.SessionsSpec(e.timezone,e.session_display??e.session,e.session_holidays,e.corrections)]]);const t="regular",n="premarket",s="postmarket",r=[t,n,s],i=new Map;for(const o of r){let r=null;switch(o){case t:r=0;break;case n:r=1;break;case s:r=2}if(null!==r){const t=e.subsessions.find((e=>e.id===o));void 0!==t&&i.set(r,new z.SessionsSpec(e.timezone,t["session-display"]||t.session,e.session_holidays,t["session-correction"]))}}return i}(e),s=t??(0,i.utc_to_cal)((0,i.get_timezone)(e?.timezone??"Etc/UTC"),Date.now()),r=(t?.getUTCDay()??(new Date).getDay())%7+1;const o=(0,h.deepCopy)($);o[r].isActive=!0;for(const e of Array.from(n.keys())){const t=(0,m.ensureDefined)(n.get(e)),r=(0,i.get_day_of_week)(s),a=(0,i.clone)(s);(0,i.add_date)(a,-r),(0,i.set_hms)(a,0,0,0,0);const u=(0,i.clone)(a);(0,i.add_date)(u,7);let d=t.alignToNearestSessionStart(a,t.inSession(a)?-1:1);for(;d.getTime()<u.getTime();){const n=t.alignToNearestSessionEnd(d,1),s=(0,i.get_day_of_week)(d),r=(0,i.get_day_of_week)(n),c=(0,i.get_minutes_from_midnight)(d),m=(0,i.get_minutes_from_midnight)(n)+1,h=l(c),v=l(m),p=x(s,c,r,m);s===r?H(o,{start:R(h,!0),end:R(v,!0),type:e,tooltip:p},s):(d.getTime()>a.getTime()&&H(o,{start:R(h,!0),end:R(1,!1),type:e,tooltip:p},s),n.getTime()<u.getTime()&&H(o,{start:R(0,!1),end:R(v,!0),type:e,tooltip:p},r)),(0,i.add_minutes)(n,1),d=t.alignToNearestSessionStart(n,1)}}return function(e){const t=new Map
;for(const n of v)t.set(n,V(n,e));for(const n of v)e[n].entries=(0,m.ensureDefined)(t.get(n))}(o),{newSessionsDays:o,newTodaySession:o[r]}}var Z;function j(e){return(0,i.get_cal_from_unix_timestamp_ms)((0,i.get_timezone)(e.timezone),window.ChartApiInstance.serverTime()-1e3*(0,a.getSymbolDelaySeconds)(e))}!function(e){e[e.Regular=0]="Regular",e[e.Pre=1]="Pre",e[e.Post=2]="Post",e[e.Close=3]="Close"}(Z||(Z={}));class G{constructor(e){this.sessionsDays=new o.WatchedValue((0,r.clone)($)),this.todaySession=new o.WatchedValue((0,r.clone)({entries:[]})),this._currentTime=new o.WatchedValue(-1),this._symbolInfo=e.symbolInfo().spawn(),this._symbolInfo.subscribe(this._updateEntriesBySubSessions.bind(this),{callWithLast:!0}),this._timeIntervalId=setInterval(this._updateTodayWithOffsets.bind(this),6e4)}destroy(){this._symbolInfo.destroy(),clearInterval(this._timeIntervalId)}currentTimeValue(){return this._currentTime.readonly()}timezone(){const e=this._symbolInfo.value();return null===e?"":(0,s.timezoneTitle)(e.timezone)}_updateEntriesBySubSessions(e){this._updateTodayWithOffsets();const{newSessionsDays:t,newTodaySession:n}=J(e,null===e?null:j(e));this.sessionsDays.setValue(t),this.todaySession.setValue(n)}_updateTodayWithOffsets(){const e=this._symbolInfo.value();if(null===e)return void this._currentTime.setValue(-1);const t=this._currentTime.value(),n=l((0,i.get_minutes_from_midnight)(j(e)));this._currentTime.setValue(n),n<t&&this._updateEntriesBySubSessions(e)}}},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>'},92315:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 18 18" width="18" height="18"><path fill="currentColor" d="M9 14A5 5 0 1 0 9 4a5 5 0 0 0 0 10Zm3-4H6V8h6v2Z"/></svg>'},25931:(e,t,n)=>{"use strict";n.d(t,{nanoid:()=>s});let s=(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?"-":"_"),"")}}]);