PageSourceSearch

https://rockflow.tech/_next/static/chunks/7720-f59f0dcdea8ba474.js

js rockflow.tech collected 2026-10-02 15:46:37 UTC 20,711 bytes, 1 lines download raw bytes

1!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="67e84e79-ebbb-4198-bb3f-94bb705e3eec",e._sentryDebugIdIdentifier="sentry-dbid-67e84e79-ebbb-4198-bb3f-94bb705e3eec")}catch(e){}}();"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7720],{4602:(e,t,r)=>{r.d(t,{$:()=>d,A:()=>u});var i=r(44489),a=r(57129),o=r(32528),n=r.n(o),l=r(40053),s=r(74301),c=r(58935);let d=e=>{let{variant:t="normal",loading:r,href:o,target:d,className:u,children:h,...m}=e,p="w-full h-12 flex items-center justify-center text-base rounded-full border border-transparent transition-all ease-in-out disabled:cursor-not-allowed md:px-6",f={normal:(0,a.cn)("bg-white text-black","hover:bg-gray-200","active:bg-gray-300","disabled:text-[#514B74] disabled:bg-[#232036] disabled:hover:bg-[#232036]"),primary:(0,a.cn)("bg-primary text-white dark:text-black","hover:bg-[#5A00C8] dark:hover:bg-[#9578FF)]","active:bg-[#4C00AF] dark:active:bg-[#785AF0)]","disabled:text-[#514B74] disabled:bg-[#232036] disabled:hover:bg-[#232036]"),outline:(0,a.cn)("bg-transparent text-white border-white","hover:bg-white/5","active:bg-white/10","disabled:border-[#232036] disabled:text-[#514B74] disabled:bg-transparent disabled:hover:border-[#232036]"),plain:(0,a.cn)("bg-transparent text-[#949494]","hover:text-white hover:bg-white/5","active:bg-white/10","disabled:opacity-40 disabled:hover:text-[#949494] disabled:hover:bg-transparent")};return o?(0,i.jsxs)(n(),{href:o,target:d,className:(0,a.cn)(p,f[t],u,r?"pointer-events-none":""),...m,children:[(0,i.jsx)(l.N,{mode:"wait",children:r&&(0,i.jsx)(s.P.div,{initial:{width:0,opacity:0,marginRight:0},animate:{width:"auto",opacity:1,marginRight:8},exit:{width:0,opacity:0,marginRight:0},transition:{type:"spring",bounce:0,duration:.3},className:"flex items-center justify-center overflow-hidden whitespace-nowrap",children:(0,i.jsx)(c.R,{className:"h-5 w-5"})},"loading")}),h]}):(0,i.jsxs)("button",{className:(0,a.cn)(p,f[t],u,r?"pointer-events-none":""),...m,children:[(0,i.jsx)(l.N,{mode:"wait",children:r&&(0,i.jsx)(s.P.div,{initial:{width:0,opacity:0,marginRight:0},animate:{width:"auto",opacity:1,marginRight:8},exit:{width:0,opacity:0,marginRight:0},transition:{type:"spring",bounce:0,duration:.3},className:"flex items-center justify-center overflow-hidden whitespace-nowrap",children:(0,i.jsx)(c.R,{className:"h-5 w-5"})},"loading")}),h]})},u=d},58935:(e,t,r)=>{r.d(t,{R:()=>o});var i=r(44489),a=r(57129);let o=e=>{let{className:t}=e;return(0,i.jsx)("div",{className:(0,a.cn)("h-8 w-8 animate-spin rounded-full border-b-2 border-color-primary",t)})}},35568:(e,t,r)=>{r.d(t,{A:()=>o});var i=r(44489),a=r(44349);let o=e=>{let{src:t,alt:r,fallbackSrc:o="https://web-cdn.rockflow.tech/components/placeholder.png",className:n="",...l}=e,s=t&&""!==t.trim()&&"undefined"!==t,c=s?t:o,[d,u]=(0,a.useState)(c),[h,m]=(0,a.useState)(!s);return(0,a.useEffect)(()=>{t&&""!==t.trim()&&"undefined"!==t?(u(t),m(!1)):(u(o),m(!0))},[t,o]),(0,i.jsx)("img",{src:d,alt:r,className:"rounded-full ".concat(n),onError:()=>{d!==o&&(m(!0),u(o))},...l})}},5093:(e,t,r)=>{r.d(t,{A:()=>o});var i=r(44349);let a=i.useLayoutEffect,o=function(e,t,r){let o=(0,i.useRef)(t);a(()=>{o.current=t},[t]),(0,i.useEffect)(()=>{let t=(null==r?void 0:r.current)||window;if(!(t&&t.addEventListener))return;let i=e=>o.current(e);return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}},[e,r])}},38996:(e,t,r)=>{r.d(t,{F:()=>l,y:()=>s});var i=r(44349),a=r(33793),o=r(44451);let n=(0,a.v)()((0,o.eh)((e,t)=>({notifications:[],sendOrderSuccess:t=>{let r={id:"".concat(Date.now(),"-").concat(Math.random()),type:"onOrderSuccess",data:{orderId:t},timestamp:Date.now()};e(e=>({notifications:[...e.notifications,r]})),setTimeout(()=>{e(e=>({notifications:e.notifications.filter(e=>e.id!==r.id)}))},3e3)},sendNotification:(t,r)=>{let i={id:"".concat(Date.now(),"-").concat(Math.random()),type:t,data:r,timestamp:Date.now()};e(e=>({notifications:[...e.notifications,i]}))},removeNotification:t=>e(e=>({notifications:e.notifications.filter(e=>e.id!==t)})),clearNotifications:()=>e({notifications:[]})}))),l=e=>{(0,i.useEffect)(()=>n.subscribe(e=>e.notifications,(t,r)=>{t.filter(e=>"onOrderSuccess"===e.type&&!r.some(t=>
1t.id===e.id)).forEach(t=>{e(t.data.orderId)})}),[e])},s=()=>{let e=n(e=>e.sendOrderSuccess);return(0,i.useCallback)(t=>{e(t)},[e])}},43388:(e,t,r)=>{r.d(t,{Ab:()=>l,Ay:()=>h,XE:()=>d,qQ:()=>u});var i=r(28848),a=r(86650),o=r(77427);class n{static getInstance(){return n.instance||(n.instance=new n),n.instance}setUICallbacks(e){this.uiCallbacks=e}setTranslate(e){this.t=e}async init(e,t,r){if(!this.uiCallbacks)throw Error("UI callbacks not set. Please call setUICallbacks first.");if(!this.t)throw Error("Translate function not set. Please call setTranslate first.");this.log("init order: ".concat(JSON.stringify(e),", orderType: ").concat(t)),this.order=e,this.reOrderType=t,this.onSuccessCallback=(null==r?void 0:r.onSuccess)||null,this.onErrorCallback=(null==r?void 0:r.onError)||null,this.onCancelSuccessCallback=(null==r?void 0:r.onCancelSuccess)||null;let i=e.orderQuantity-e.filledQuantity;try{switch(t){case"RE_ORDER":e.oco?await this.showOcoCancelConfirmDialog(i):await this.showCRCancelOrderConfirmDialog(i);break;case"FAST_EXECUTION":await this.tickLatest()}}catch(e){this.handleError(e)}}async showOcoCancelConfirmDialog(e){var t;let r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";if(!(null===(t=this.uiCallbacks)||void 0===t?void 0:t.showDialog)||!this.t)throw Error("Callbacks not set");return new Promise((t,a)=>{this.uiCallbacks.showDialog({type:"alert",title:this.t("order:dialog_cancel_backet_oco_order_title"),content:this.t("order:dialog_cancel_backet_oco_order_content"),confirmText:this.t("order:dialog_cancel_order_positive"),onConfirm:async()=>{try{"RE_ORDER"===this.reOrderType?await this.showCRCancelOrderConfirmDialog(e):await this.showFastExeCancelOrderConfirmDialog(e,r,i),t()}catch(e){a(e)}},onCancel:()=>{t()}})})}async showCRCancelOrderConfirmDialog(e){var t;if(!(null===(t=this.uiCallbacks)||void 0===t?void 0:t.showDialog)||!this.t)throw Error("Callbacks not set");return new Promise((t,r)=>{this.uiCallbacks.showDialog({type:"confirm",title:this.t("order:re_order_title"),content:this.t("order:re_order_subtitle"),shares:e,confirmText:this.t("common:confirm"),cancelText:this.t("common:cancel"),onConfirm:async()=>{try{await this.cancelOrder(),t()}catch(e){r(e)}},onCancel:()=>{t()}})})}async showFastExeCancelOrderConfirmDialog(e,t,r){var i;if(!(null===(i=this.uiCallbacks)||void 0===i?void 0:i.showDialog)||!this.t)throw Error("Callbacks not set");return new Promise((i,a)=>{this.uiCallbacks.showDialog({type:"confirm",title:this.t("order:fast_execution_title"),content:"".concat(this.t("order:cancel_order_replace_new_market_order")).concat(t," ").concat(r),shares:e,confirmText:this.t("common:confirm"),cancelText:this.t("common:cancel"),onConfirm:async()=>{try{await this.cancelOrder(),i()}catch(e){a(e)}},onCancel:()=>{i()}})})}async cancelOrder(){var e,t;if(!this.order||!this.t)throw Error((null===(e=this.t)||void 0===e?void 0:e.call(this,"reorder.error.order_not_found"))||"订单信息不存在");this.verifyPasswordScene="CANCEL_ORDER",this.log("start cancelOrder");let r=await (0,i.N4)(this.order.orderId);200===r.code?await this.waitingCancelStatus():1039999===r.code?(null===(t=this.uiCallbacks)||void 0===t?void 0:t.showPasswordDialog)&&await this.uiCallbacks.showPasswordDialog()&&200===(await (0,i.N4)(this.order.orderId)).code&&await this.waitingCancelStatus():2000001===r.code&&this.showToast(this.t("order:canceling"),"info")}async waitingCancelStatus(){return new Promise((e,t)=>{this.waitingCancelTimer&&clearTimeout(this.waitingCancelTimer),this.waitingCancelTimer=window.setTimeout(async()=>{try{if(!this.order)return;let t=await (0,i.KU)(this.order.orderId);(null==t?void 0:t.orderStatus)===o.YrO.ORDER_CANCELLED?(await this.onOrderCancelSuccess(),e()):await this.onOrderCancelFail()}catch(e){await this.onOrderCancelFail(),t(e)}},c)})}async onOrderCancelSuccess(){if(!this.order)return;if(this.log("onOrderCancelSuccess"),this.onCancelSuccessCallback){await this.onCancelSuccessCallback();return}let e=this.order.orderQuantity-this.order.filledQuantity;try{switch(this.reOrderType){case"RE_ORDER":this.order.oco?await this.doOcoOrderPlaceOrder(this.order):await this.placeReOrder(this.order,e);break;case"FAST_EXECUTION":await this.placeFastExecutionOrder(this.order,e)}}catch(e){this.handleError(e)}}async onOrderCancelFail(){var e;(null===(e=this.uiCallbacks)||void 0===e?void 0:e.showDialog)&&this.t&&this.uiCallbacks.showDialog({type:"alert",title:this.t("order:cancellation_timed_out"),content:"RE_ORDER"===this.reOrderType?this.t("order:cancel_reorder_content"):this.t("order:cancel_fast_execution_content"),confirmText:this.t("order:ok"),onConfirm:()=>{}})}async placeReOrder(e,t){var r;
1let i={symbol:e.symbol,side:e.side,market:e.market,quantity:t,limitType:e.orderType,price:e.orderPrice,stopPrice:e.stopPrice,orderType:"LIMIT"};null===(r=this.uiCallbacks)||void 0===r||r.locateOrderPage(i,!1)}async placeFastExecutionOrder(e,t){e.symbol,e.side,e.market}async doOcoOrderPlaceOrder(e){try{this.showLoading(!0);let r=await this.getOcoOrderPlaceOrderParams(e);if(this.showLoading(!1),r){var t;let i={symbol:e.symbol,side:e.side,market:e.market,quantity:e.orderQuantity-e.filledQuantity,limitType:"BRACKET_OCO",price:r.price,stopTriggerPrice:r.stopTriggerPrice,stopProfitPrice:r.stopProfitPrice};null===(t=this.uiCallbacks)||void 0===t||t.locateOrderPage(i,!0)}}catch(e){throw this.showLoading(!1),e}}async getOcoOrderPlaceOrderParams(e){let t=await (0,i.nx)(e.orderId);if(2!==t.length)return null;let r=t.find(t=>t.orderId.toString()!==e.orderId);return r?e.orderType===o.i5n.LIMIT_IF_TOUCHED_ORDER?{quantity:e.orderQuantity,stopProfitPrice:e.orderPrice,price:r.price,stopTriggerPrice:r.stop}:{quantity:e.orderQuantity,stopProfitPrice:r.price,price:e.orderPrice,stopTriggerPrice:e.stopPrice}:null}async calculateOcoOrderParams(e){let t=await fetch("/api/orders/calculate-oco-params",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({orderId:e.orderId})});return t.ok?(await t.json()).data:null}async tickLatest(){if(this.order&&this.t)try{let e=await (0,a.zB)(this.order.symbol,this.order.market);if(null==e)throw Error(this.t("reorder.error.fetch_market_failed"));let t=this.order.orderQuantity-this.order.filledQuantity,r=e.tradePrice;0!==e.askPrice&&0!==e.bidPrice&&(r=this.order.side===o.Mf8.BUY?e.askPrice:e.bidPrice);let i=t*r,n=this.t("order:est_cost_currency",{amount:this.formatPrice(i),currency:this.order.currency}),l=this.t("order:confirm_trading_other",{market:this.getMarketDesc(this.order.market)});this.order.oco?await this.showOcoCancelConfirmDialog(t,n,l):await this.showFastExeCancelOrderConfirmDialog(t,n,l)}catch(e){this.handleError(e)}}formatPrice(e){return e.toFixed(2)}getMarketDesc(e){if(!this.t)return"";let t=e.toLowerCase();return this.t("order:market_".concat(t))}showToast(e,t){var r;(null===(r=this.uiCallbacks)||void 0===r?void 0:r.showToast)&&this.uiCallbacks.showToast(e,t)}showLoading(e){var t;(null===(t=this.uiCallbacks)||void 0===t?void 0:t.showLoading)&&this.uiCallbacks.showLoading(e)}handleError(e){this.log("Error: ".concat(e.message)),this.onErrorCallback&&this.onErrorCallback(e),this.showToast(e.message,"error")}log(e){}reset(){this.order=null,this.reOrderType=null,this.onSuccessCallback=null,this.onErrorCallback=null,this.onCancelSuccessCallback=null,this.uiCallbacks=null,this.t=null,this.waitingCancelTimer&&(clearTimeout(this.waitingCancelTimer),this.waitingCancelTimer=null)}destroy(){this.reset()}constructor(){this.order=null,this.reOrderType=null,this.waitingCancelTimer=null,this.verifyPasswordScene=null,this.onSuccessCallback=null,this.onErrorCallback=null,this.onCancelSuccessCallback=null,this.uiCallbacks=null,this.t=null}}var l=function(e){return e.RE_ORDER="RE_ORDER",e.FAST_EXECUTION="FAST_EXECUTION",e}({}),s=function(e){return e.CANCEL_ORDER="CANCEL_ORDER",e.ORDER="ORDER",e}(s||{});let c=5e3;function d(e){var t,r;let i=e.originOrder;return{itemType:"normal_order_detail",orderId:e.orderId,icon:e.logo,name:e.name,symbol:e.symbol,displaySymbol:e.displaySymbol,orderDesc:"",currency:i.currency,attachOrderStatus:null!==(t=e.attachedOrderStatus)&&void 0!==t?t:0,isClosePosition:!1,orderRealizedPl:0,orderRealizedPlRate:0,isFraction:!1,orderedAmount:0,filledAmount:0,orderQuantity:e.quantity,filledQuantity:e.filledQuantity,filledPrice:0,filledPriceValue:"",orderAmount:0,updateTime:0,updateTimeLabel:"",createTime:0,orderTypeStr:"",showTwapStarTime:!1,twapStarTime:0,showTwapEndTime:!1,twapEndTime:0,showStop:!1,stopLabel:"",stopPrice:null!==(r=i.stop)&&void 0!==r?r:0,showStopLimit:!1,stopLimitPrice:0,showLimitPrice:!1,limitPrice:i.price,showTradingSession:!1,tradingSession:0,tradingSessionDesc:"",tradingSessionRange:"",tradingValidity:0,tradingValidityDesc:"",commission:"",showBobbyCommission:!1,bobb
1yCommission:0,showPlatformFee:!1,platformFee:"",isSubAccountOrder:!1,orderStatus:e.orderStatus,side:e.side,market:i.market,oco:e.ocoOrder,orderType:e.orderType,orderPrice:i.price,instrument:e.instrument,originOrder:i}}function u(e){return e}let h=n},1444:(e,t,r)=>{r.d(t,{R:()=>l,S:()=>s});var i=r(88338),a=r(70465);let o=new Map,n=new Map,l=e=>o.get(e),s=async(e,t)=>{let r=o.get(t);if(void 0!==r)return r;let l=n.get(t);if(l)return l;let s=a.c.fetchQuote(e,t).then(e=>{let r=(0,i.pPN)(null==e?void 0:e.exchange);return o.set(t,r),r}).catch(r=>(console.warn("[pinkSheetService] failed to resolve exchange",{market:e,symbol:t,error:r}),!1)).finally(()=>{n.delete(t)});return n.set(t,s),s}},24487:(e,t,r)=>{r.d(t,{B:()=>u});var i=r(28848),a=r(63274),o=r(87157),n=r(86650),l=r(39640),s=r(88338),c=r(74560);let d={GREY_MARKET_QUOTE_ONLY:1,GREY_MARKET_TRADING_ONLY:2,ALL_SUPPORT:4};async function u(e){var t,r,u,h,m,p,f,g,w,b,y,C,v,T,P,_,k,O,E,S;let{order:R,reOrderType:x,t:D,locale:L}=e,I=await (0,i.KU)(R.orderId);if(!I)return console.error("[prepareResubmitData] Failed to get order detail",{orderId:R.orderId}),null;let F=I.side===l.Mf.BUY?s.w_$.BUY:s.w_$.SELL,A=x===o.D0.RE_ORDER?new c.A(null!==(r=I.quantity)&&void 0!==r?r:0):new c.A(null!==(u=I.quantity)&&void 0!==u?u:0).minus(null!==(h=I.filledQuantity)&&void 0!==h?h:0);if(A.lte(0))return null;let N="symbol_order"===R.itemType||"betterbuy_order"===R.itemType?R.symbol:"currency_exchange_order"===R.itemType?"".concat(R.fromCurrency,"/").concat(R.toCurrency):R.symbol||"";if(!N)return null;let M=await (0,n.E$)(N,"en-US");if(!M)return null;let U=await (0,n.zB)(N,M.market),q={symbol:M.symbol,market:M.market,currency:M.currency,exchange:M.exchange,lotSize:M.lotSize,tickSize:M.tickSize,tradePrice:null!==(g=null!==(f=null!==(p=null!==(m=null==U?void 0:U.tradePrice)&&void 0!==m?m:null==U?void 0:U.price)&&void 0!==p?p:null==U?void 0:U.lastPrice)&&void 0!==f?f:null==U?void 0:U.close)&&void 0!==g?g:0,bidPrice:null!==(y=null!==(b=null!==(w=null==U?void 0:U.bidPrice)&&void 0!==w?w:null==U?void 0:U.bid)&&void 0!==b?b:null==U?void 0:U.bid1)&&void 0!==y?y:void 0,askPrice:null!==(T=null!==(v=null!==(C=null==U?void 0:U.askPrice)&&void 0!==C?C:null==U?void 0:U.ask)&&void 0!==v?v:null==U?void 0:U.ask1)&&void 0!==T?T:void 0,currentPrice:null!==(k=null!==(_=null!==(P=null==U?void 0:U.price)&&void 0!==P?P:null==U?void 0:U.tradePrice)&&void 0!==_?_:null==U?void 0:U.lastPrice)&&void 0!==k?k:void 0,close:null==U?void 0:U.close},Q=(0,s.pPN)(M.exchange);if(x===o.D0.FAST_EXECUTION)return Q&&F===s.w_$.BUY?{error:"pink_market_order_unavailable"}:{data:{kind:"directMarket",starter:{resubmitType:"fast",initialShareAmount:A.toNumber()},profile:M,prefetchedTick:null!=U?U:null,prefetchedStockPlain:q,tradeDirection:F}};let j=(0,o.K5)(I,D,L),K={initialShareAmount:A.toNumber(),resubmitType:"advanced"},Y=function(e){var t;let r=!0===e.attached,i=e.orderType,a=(null===(t=e.extras)||void 0===t?void 0:t.oco)===!0,o=a&&6===i,n=a&&3===i;if(o||n)return s.C0q.TAKE_PROFIT_AND_STOP_LOSS;if(3===i&&r&&!n)return s.C0q.STOP_LOSS;if(1===i&&r&&!o)return s.C0q.TAKE_PROFIT;switch(i){case 1:default:return s.C0q.LIMIT;case 10:return s.C0q.TWAP;case 6:return s.C0q.TAKE_PROFIT;case 3:return s.C0q.STOP_LOSS}}(I);if(Q&&(Y===s.C0q.STOP_LOSS||Y===s.C0q.TAKE_PROFIT_AND_STOP_LOSS))return{error:"pink_stop_loss_unavailable"};let B=(null===(t=I.extras)||void 0===t?void 0:t.oco)===!0,z=B&&6===I.orderType,G=B&&3===I.orderType;K.orderType=Y;let V=null;if((z||G)&&I.parentOrderId)try{let e=String(I.parentOrderId),t=await (0,i.nx)(e);if(t&&t.length>0){let e=String(I.orderId||R.orderId);(V=t.find(t=>String(t.orderId)!==e))||!(t.length>0)||(V=t[0])}}catch(e){console.warn("[order] Failed to get order attachments:",e)}switch(Y){case s.C0q.TAKE_PROFIT_AND_STOP_LOSS:if(z){let e=null!==(O=I.price)&&void 0!==O?O:j.limitPrice;e&&e>0?K.initialTakeProfitPrice=e:console.warn("[order] Take profit price is empty:",{detailPrice:I.price,mappedLimitPrice:j.limitPrice}),V&&(V.price&&(K.initialStopLossPrice=V.price),V.stop&&(K.initialTriggerPrice=V.stop))}else if(G){let e=null!==(E=I.stop)&&void 0!==E?E:j.stopPrice;e&&e>0?K.initialTriggerPrice=e:console.warn("[order] Trigger price is empty:",{detailStop:I.stop,mappedStopPrice:j.stopPrice});let t=null!==(S=I.price)&&void 0!==S?S:j.stopLimitPrice;t&&t>0?K.initialStopLossPrice=t:console.warn("[order] Stop loss price is empty:",{detailPrice:I.price,mappedStopLimitPrice:j.stopLimitPrice}
1),V&&V.price&&(K.initialTakeProfitPrice=V.price)}else j.limitPrice&&(K.initialTakeProfitPrice=j.limitPrice),j.stopLimitPrice&&(K.initialStopLossPrice=j.stopLimitPrice),j.stopPrice&&(K.initialTriggerPrice=j.stopPrice);break;case s.C0q.TAKE_PROFIT:K.initialPrice=I.price,I.stop&&(K.initialTriggerPrice=I.stop);break;case s.C0q.STOP_LOSS:K.initialPrice=I.price,K.initialTriggerPrice=I.stop;break;case s.C0q.TWAP:I.extras&&(K.initialTwapStartTime=I.extras.executionStartTime,K.initialTwapEndTime=I.extras.executionEndTime);break;case s.C0q.LIMIT:default:let X=I.price&&I.price>0?I.price:j.limitPrice&&j.limitPrice>0?j.limitPrice:void 0;void 0!==X&&(K.initialPrice=X)}let $={kind:"uiModal",starter:K,profile:M,prefetchedTick:null!=U?U:null,prefetchedStockPlain:q,tradeDirection:F};if(2===I.session&&"HK"===M.market){let e=await (0,a.Te)(N);if(!(e&&function(e){let t=Date.now(),r=t>=e.greyMarketTradingStartTime&&t<e.greyMarketTradingEndTime;if(void 0!==e.ipoPermission&&null!==e.ipoPermission){var i;return((i=e.ipoPermission)===d.GREY_MARKET_QUOTE_ONLY||i===d.GREY_MARKET_TRADING_ONLY||i===d.ALL_SUPPORT)&&r}return e.greyMarketTrading&&r}(e)))return{error:"grey_market_unavailable"};$.greyMarketInfo=e}return{data:$}}},59387:(e,t,r)=>{r.d(t,{x:()=>l});var i=r(33793),a=r(44451);let o="14 248 192",n="255 56 163",l=(0,i.v)()((0,a.Zr)((e,t)=>({riseFallColor:"green-up",setRiseFallColor:r=>{e({riseFallColor:r}),t().setRiseFallColorVar()},setRiseFallColorVar:()=>{let{riseFallColor:e}=t();"green-up"===e?(document.documentElement.style.setProperty("--trend-up",o),document.documentElement.style.setProperty("--trend-down",n)):(document.documentElement.style.setProperty("--trend-up",n),document.documentElement.style.setProperty("--trend-down",o))},getRiseFallColor:e=>{if(!e||0===e)return"#FFFFFF";let r=t().riseFallColor,i=e>0,a="#0EF8C0",o="#FF38A3";return"green-up"===r?i?a:o:i?o:a},getRiseFallColorClassName:e=>e&&0!==e?e>0?"text-trend-up":"text-trend-down":"text-white",assetMasking:!1,setAssetMasking:t=>e({assetMasking:t})}),{name:"rf-preferences",version:1,migrate:(e,t)=>
1e,partialize:e=>({riseFallColor:e.riseFallColor,assetMasking:e.assetMasking})}))},47155:(e,t,r)=>{r.d(t,{j:()=>o});var i=r(77427),a=r(23423);let o=(e,t)=>{(0,a.Vt)(e)?(0,i.pUb)(e)&&t.push("/option/".concat(e)):t.push("/stock/".concat(e))}},6913:(e,t,r)=>{r.d(t,{H:()=>i});function i(e){let t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=arguments.length>2?arguments[2]:void 0;arguments.length>3&&void 0!==arguments[3]&&arguments[3];let a=e;for(let e of("OSUS"===a&&(a="US"),i))if(e.market===a){t=e;break}let o=null==t?void 0:t.today;if(!o||!o.is_open)return[0,0];let n=0===r?Date.now():r;if(o.lunch){if(n<o.pre_hours_start)return[0,0];if(n<o.start)return[2,-1];if(n<o.lunch_start)return[1,-1];if(n<o.lunch_end)return[0,-1];else if(n<o.end)return[1,-1];else if(n<o.post_hours_end)return[3,-1];else return[0,1]}return n<o.pre_hours_start?[0,0]:n<o.pre_hours_end?[2,-1]:n<o.end?[1,-1]:n<o.post_hours_end?[3,-1]:[0,1]}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.