1"use strict";(self.webpackChunk_aqx_member_web=self.webpackChunk_aqx_member_web||[]).push([["3669"],{85388:function(e,t,r){r.r(t),r.d(t,{default:()=>H}),r(92222);var n=r(74512),i=r(32735),o=r(10281),l=r(81182);r(68233),r(15296),r(92274),r(803),r(80153);var a=r(6807),c=r(1403),d=r(75440),s=r(28931),u=r(73036),f=(0,i.createContext)(void 0),h=function(){var e=(0,i.useContext)(f);if(!e)throw Error("useDOMTableContext must be used within a DOMTableProvider");return e},p=function(e,t){var r=e.ask,n=e.bid;if(!r&&!n)return"empty-bid-ask-".concat(t);var i=[null==r?void 0:r.price,null==r?void 0:r.size,null==n?void 0:n.price,null==n?void 0:n.size].filter(Boolean);return"".concat(i.join("-"),"-").concat(t)},v=function(e,t){var r=d.cI.calculateAdjustedLotSize(null==e?void 0:e.size,t);return null!=r?r:"--"},b=function(e,t){return(0,u.Ng)(null==e?void 0:e.price,t)},g=function(e){var t=e.children,r=e.domTableContextSymbolDetail,o=e.priceLevels,d=(0,l.$G)().t,u=(0,c.YR)(),h=null!=r?r:{},g=h.decimal,m=void 0===g?0:g,O=h.lotSizeStep,y=void 0===O?.01:O,C=d("BUY LMT"),x=d("SELL LMT"),I=(0,i.useMemo)(function(){return{left:{qtyCell:u?a.Of.QUOTEBOARD_QUANTITY_BID:a.Of.QUOTEBOARD_QUANTITY_ASK,priceCell:u?a.Of.QUOTEBOARD_BID:a.Of.QUOTEBOARD_ASK},right:{qtyCell:u?a.Of.QUOTEBOARD_QUANTITY_ASK:a.Of.QUOTEBOARD_QUANTITY_BID,priceCell:u?a.Of.QUOTEBOARD_ASK:a.Of.QUOTEBOARD_BID}}},[u]),j=(0,i.useMemo)(function(){var e=d("Bid"),t=d("Ask"),r=(0,s.GL)(),n=u?e:t,i=u?t:e;return[{key:"".concat(I.left.qtyCell,"-left"),testId:I.left.qtyCell,label:r},{key:I.left.priceCell,testId:I.left.priceCell,label:n},{key:I.right.priceCell,testId:I.right.priceCell,label:i},{key:"".concat(I.right.qtyCell,"-right"),testId:I.right.qtyCell,label:r}]},[I,d,u]),L=(0,i.useMemo)(function(){return o.map(function(e,t){var r=e.ask,n=e.bid,i=e.askPriceAdjusted,o=e.bidPriceAdjusted,l=b(n,m),a=l.prefix,c=l.suffix,d=b(r,m),s=d.prefix,f=d.suffix,h=u?a:s,g=u?c:f,O=u?s:a,I=u?f:c,j=p(e,t),L=v(n,y),P=v(r,y);return{left:{pricePrefix:h,priceSuffix:g,level:u?n:r,adjustedPrice:u?o:i,isBid:u,hoverLabel:u?x:C,volume:u?L:P},right:{pricePrefix:O,priceSuffix:I,level:u?r:n,adjustedPrice:u?i:o,isBid:!u,hoverLabel:u?C:x,volume:u?P:L},key:j}})},[o,m,u,y,C,x]);return(0,n.jsx)(f.Provider,{value:{headerCells:j,priceLevelRows:L,testIds:I},children:t})},m=function(e){var t=e.inputSize,r=e.priceLevels,n=e.headerHeight,o=e.rowHeight,l=(0,c.YR)(),d=(0,i.useMemo)(function(){return{leftIndicatorTestId:l?a.Of.QUOTEBOARD_BID_INDICATOR_LINE:a.Of.QUOTEBOARD_ASK_INDICATOR_LINE,rightIndicatorTestId:l?a.Of.QUOTEBOARD_ASK_INDICATOR_LINE:a.Of.QUOTEBOARD_BID_INDICATOR_LINE}},[l]),s=d.leftIndicatorTestId,u=d.rightIndicatorTestId,f=(0,i.useMemo)(function(){if(!t||0===r.length)return{};for(var e=0,i=0,a=t,c=t,d=0;d<r.length;d++){var s=r[d],u=s.ask,f=s.bid;f&&a>0&&(a-=f.size)>=0&&(e+=1),u&&c>0&&(c-=u.size)>=0&&(i+=1)}var h=i*o+n-1,p=e*o+n-1,v=l?p:h,b=l?h:p,g=r.length*o+n-2;return{rightIndicatorPosition:Math.min(g,b),leftIndicatorPosition:Math.min(g,v)}},[r,t,l,n,o]),h=f.rightIndicatorPosition;return{leftIndicator:{position:f.leftIndicatorPosition,testId:s},rightIndicator:{position:h,testId:u}}},O=r(479),y=r(25932),C=r(55979);r(21249);var x=r(82863),I=r(29712),j=r(62715),L=r(37918),P=r(38074);let T=function(e){var t,r,i=e.children,o=e.typography,l=void 0===o?j.wZ.TEXT_XS_REGULAR:o,a=function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r,n,i={},o=Object.keys(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)>=0||(i[r]=e[r]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(e,["children","typography"]);return(0,n.jsx)(P.ZP,(t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({typography:l},a),r=r={children:i},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);r.push.apply(r,n)}return r}
1)(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))};var A=function(e){var t=e.buySellLabel,r=e.isHovered,i=e.size,o=e.inputSize;return r?(0,n.jsxs)(R,{children:[(0,n.jsx)(T,{children:t}),(0,n.jsx)(T,{children:null!=o?o:0})]}):(0,n.jsx)(T,{children:null!=i?i:"--"})},w=o.ZP.tr.withConfig({componentId:"sc-20dca49a-0"})(["height:","px;"],C.Q),S=o.ZP.td.withConfig({componentId:"sc-20dca49a-1"})(["cursor:auto;text-align:center;background-color:",";border-bottom:1px solid ",";"," width:25%;"],function(e){return e.theme.themeColors.background.default},function(e){return e.theme.themeColors.background.subtle},function(e){var t=e.$isLastCell,r=e.theme;return t?"":"border-right: 1px solid ".concat(r.themeColors.background.default,";")}),k=(0,o.ZP)(S).withConfig({componentId:"sc-20dca49a-2"})(["background-color:",";cursor:",";border-bottom:1px solid ",";"],function(e){var t=e.$hovered,r=e.$isBuy,n=e.theme,i=r?n.themeColors.pnl.positive.default:n.themeColors.pnl.negative.default;return t?(0,L.Wf)(i,n.themeMode):(0,L.lC)(i,n.themeMode)},function(e){var t=e.$disabled,r=e.$hoverDisabled;return t||r?"not-allowed":"pointer"},function(e){return e.theme.themeColors.background.default}),D=(0,o.ZP)(S).withConfig({componentId:"sc-20dca49a-3"})(["background-color:",";cursor:",";& div{color:",";}"],function(e){var t=e.$isBuy,r=e.$hovered,n=e.theme;return r&&t?n.themeColors.pnl.positive.default:r&&!t?n.themeColors.pnl.negative.default:n.themeColors.background.default},function(e){var t=e.$disabled,r=e.$hoverDisabled;return t||r?"not-allowed":"pointer"},function(e){var t=e.$hovered,r=e.theme;return t?r.themeColors.white:r.themeColors.text.default}),_=o.ZP.div.withConfig({componentId:"sc-20dca49a-4"})(["display:flex;align-items:center;justify-content:center;gap:1px;"]),R=o.ZP.div.withConfig({componentId:"sc-20dca49a-5"})(["display:flex;flex-direction:column;justify-content:center;"]),$=(0,o.ZP)(T).withConfig({componentId:"sc-20dca49a-6"})(["padding-top:2px;"]),B=(0,o.ZP)(T).withConfig({componentId:"sc-20dca49a-7"})(["line-height:20px;"]);let E=(0,i.memo)(function(e){var t=e.disablePlaceOrder,r=e.handleHoverCell,o=e.handleLeaveCell,l=e.hoveredCell,c=e.inputSize,d=e.onClickCell,s=e.priceLevel,u=e.rowIndex,f=e.shouldReverseOrderBtns,p=s.left,v=s.right,b=p.level,g=p.adjustedPrice,m=p.isBid,O=p.pricePrefix,y=p.priceSuffix,C=p.volume,x=p.hoverLabel,I=v.level,L=v.adjustedPrice,P=v.isBid,T=v.pricePrefix,S=v.priceSuffix,R=v.volume,E=v.hoverLabel,M=h().testIds,U=(0,i.useMemo)(function(){if(!l)return{hoverOnLeft:!1,hoverOnRight:!1};var e=l.index,t=l.isBid,r=!t&&e===u,n=t&&e===u;return{hoverOnRight:f?r:n,hoverOnLeft:f?n:r}},[l,u,f]),z=U.hoverOnLeft,Q=U.hoverOnRight,Z=(0,i.useCallback)(function(){I&&r(u,P)},[I,u,r,P]),N=(0,i.useCallback)(function(){b&&r(u,m)},[u,b,r,m]);return(0,n.jsxs)(w,{"data-testid":a.Of.QUOTEBOARD_EXPAND_CARD_ITEM,children:[(0,n.jsx)(D,{$disabled:t,$hovered:z,$hoverDisabled:!b,$isBuy:!f,"data-testid":M.left.qtyCell,onMouseEnter:N,onMouseLeave:o,onClick:function(){return d(g,m)},children:(0,n.jsx)(A,{buySellLabel:x,isHovered:z,size:C,inputSize:c})}),(0,n.jsx)(k,{$disabled:t,$hovered:z,$hoverDisabled:!b,$isBuy:!f,onMouseEnter:N,onMouseLeave:o,onClick:function(){return d(g,m)},"data-testid":M.left.priceCell,children:(0,n.jsxs)(_,{dir:"ltr",children:[(0,n.jsx)($,{children:O}),(0,n.jsx)(B,{typography:j.wZ.TEXT_L_REGULAR,children:y})]})}),(0,n.jsx)(k,{$disabled:t,$hovered:Q,$hoverDisabled:!I,$isBuy:f,"data-testid":M.right.priceCell,onMouseEnter:Z,onMouseLeave:o,onClick:function(){return d(L,P)},children:(0,n.jsxs)(_,{dir:"ltr",children:[(0,n.jsx)($,{children:T}),(0,n.jsx)(B,{typography:j.wZ.TEXT_L_REGULAR,children:S})]})}),(0,n.jsx)(D,{$disabled:t,$hovered:Q,$hoverDisabled:!I,$isLastCell:!0,$isBuy:f,onMouseEnter:Z,onMouseLeave:o,onClick:function(){return d(L,P)},"data-testid":M.right.qtyCell,children:(0,n.jsx)(A,{buySellLabel:E,isHovered:Q,size:R,inputSize:c})})]})});function M(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}let U=function(e){var t,r=e.inputSize,o=(0,c.YR)(),l=(0,x.X)().disablePlaceOrder,a=(0,I.o)().onLimitPlaceOrder,d=h().priceLevelRows,s=(t=(0,i.useState)(void 0),function(e){if(Array.isArray(e))return e}(t)||function(e,t){var r,n,i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var o=[],l=!0,a=!1;try{for(i=i.call(e);!(l=(r=i.next()).done)&&(o.push(r.value),o.length!==t);l=!0);}catch(e){a=!0,n=e}finally{try{l||null==i.return||i.return()}finally{if(a)throw n}}return o}}(t,2)||function(e,t){if(e){if("string"==typeof e)return M(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);
1if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return M(e,t)}}(t,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),u=s[0],f=s[1],p=(0,i.useCallback)(function(e,t){f({index:e,isBid:t})},[]),v=(0,i.useCallback)(function(){f(void 0)},[]),b=(0,i.useCallback)(function(e,t){!l&&e&&a(e,!t)},[a,l]);return(0,n.jsx)("tbody",{children:d.map(function(e,t){return(0,n.jsx)(E,{disablePlaceOrder:l,handleHoverCell:p,handleLeaveCell:v,onClickCell:b,hoveredCell:u,inputSize:r,priceLevel:e,rowIndex:t,shouldReverseOrderBtns:o},e.key)})})};var z=o.ZP.th.withConfig({componentId:"sc-8342635e-0"})(["text-align:center;background-color:",";border-bottom:1px solid ",";"," padding:6px 0px;width:25%;"],function(e){return e.theme.themeColors.background.active},function(e){return e.theme.themeColors.background.default},function(e){var t=e.$isLastCell,r=e.theme;return t?"":"border-right: 1px solid ".concat(r.themeColors.background.default,";")});let Q=function(){var e=h().headerCells;return(0,n.jsx)("thead",{children:(0,n.jsx)("tr",{children:e.map(function(t,r){var i=t.key,o=t.label,l=t.testId;return(0,n.jsx)(z,{"data-testid":l,$isLastCell:r===e.length-1,children:(0,n.jsx)(T,{children:o})},i)})})})};var Z=o.ZP.div.withConfig({componentId:"sc-aaf688e3-0"})(["flex:1;height:calc(100% - 34px);position:relative;"]),N=o.ZP.table.withConfig({componentId:"sc-aaf688e3-1"})(["width:100%;border-collapse:collapse;border-spacing:0px;> thead > tr > th{cursor:auto;}"]),q=o.ZP.div.withConfig({componentId:"sc-aaf688e3-2"})(["position:absolute;top:","px;"," width:50%;height:2px;background-color:",";"],function(e){return e.$topPosition},function(e){var t=e.$isRight;return e.$isRTL?"left: ".concat(t?"0":"50%",";"):"right: ".concat(t?"0":"50%",";")},function(e){return e.theme.themeColors.background.contrast});let H=(0,i.memo)(function(e){var t=e.inputSize,r=e.priceLevels,i=e.symbolDetail,o=(0,l.$G)().t,c=(0,O.dZ)(),d=m({inputSize:t,priceLevels:r,headerHeight:C.A,rowHeight:C.Q}),s=d.leftIndicator,u=d.rightIndicator,f=i.decimal,h=i.lotSizeStep;return 0===r.length?(0,n.jsx)(y.Z,{variant:y.R.NO_DATA_TO_DISPLAY,label:o("There are no price levels found.")}):(0,n.jsxs)(Z,{children:[u.position&&(0,n.jsx)(q,{$isRight:!0,$isRTL:c,$topPosition:u.position,"data-testid":u.testId}),s.position&&(0,n.jsx)(q,{$isRTL:c,$topPosition:s.position,"data-testid":s.testId}),(0,n.jsx)(g,{priceLevels:r,domTableContextSymbolDetail:{decimal:void 0===f?0:f,lotSizeStep:void 0===h?.01:h},children:(0,n.jsxs)(N,{"data-testid":a.Of.QUOTEBOARD_TABLE,children:[(0,n.jsx)(Q,{}),(0,n.jsx)(U,{inputSize:t,priceLevels:r})]})})]})})}}]);
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.