PageSourceSearch

https://client.bnc.ca/chunk-X2AAJ5Q3.js

js bnc.ca collected 2026-10-01 11:51:15 UTC 213,570 bytes, 9 lines download raw bytes

1import{c as Wn}from"./chunk-RNWNXOGQ.js";import{a as ct,b as Yn,c as Ct,d as Zn,e as Xn,f as Jn,g as io}from"./chunk-VF5WFYGJ.js";import{b as gn,c as Fn}from"./chunk-HA2FALH4.js";import{a as bi}from"./chunk-WT56AKQX.js";import{a as eo}from"./chunk-D75HXZKT.js";import{a as ii}from"./chunk-LXH4DE6U.js";import{e as ti,f as $n,g as qn}from"./chunk-7MVUZEPT.js";import{c as We,h as Qn}from"./chunk-KAA2HIB2.js";import{a as zn,b as Kn}from"./chunk-7PTTX73C.js";import{a as pt}from"./chunk-CG4WYAHB.js";import"./chunk-GJOPGJTC.js";import{r as to}from"./chunk-AH7JD5XQ.js";import"./chunk-KBRJXPHX.js";import"./chunk-ORN4WQFS.js";import"./chunk-NMLKT6IY.js";import"./chunk-S5GXKYX5.js";import"./chunk-25LAZVWZ.js";import{e as Ci,g as no}from"./chunk-VNLDWJSA.js";import"./chunk-QOKP7NBH.js";import"./chunk-7KD3UQHO.js";import"./chunk-H4QG57TJ.js";import"./chunk-KQDLMJZK.js";import"./chunk-3H6NZA6Q.js";import"./chunk-KZMW7UME.js";import"./chunk-5FGXMDP7.js";import"./chunk-X3GWJDFX.js";import"./chunk-HSVNW533.js";import{a as Jo}from"./chunk-HFGHHH3U.js";import"./chunk-7GZG4GDV.js";import{a as Gn}from"./chunk-EEXULECG.js";import{a as jt}from"./chunk-7QPZBM2T.js";import"./chunk-JOSBU4MI.js";import"./chunk-5NOXJXJB.js";import{d as jn}from"./chunk-3XGEEXFV.js";import"./chunk-4ULI4AF7.js";import"./chunk-NGGNOJQP.js";import"./chunk-KZ5EOAEI.js";import"./chunk-S3H2QQCI.js";import"./chunk-X5ORTLLR.js";import{$a as l,$c as Ki,$d as O,$k as xn,Aa as i,Ab as g,Ac as Lt,Al as Ne,Am as Pn,An as at,Bb as Et,Bm as Dn,Cg as Se,Df as Be,Dm as Ve,Em as wn,En as lt,Fa as tt,Fh as de,Fk as Qt,Fl as $,Fm as te,Fn as Xt,G as Vi,Ga as f,Gh as an,Gk as $t,Gl as _e,Gm as Zt,Hh as ln,Ib as be,Ih as sn,J as Ui,Jc as it,Jd as j,Jh as ft,Ji as Z,Jn as Ee,Ka as x,Kd as R,Kn as Vn,La as Tt,Lb as xe,Lj as fn,Lk as Cn,Lm as ge,Ln as fe,Md as Zi,Nb as Ke,Ni as Gt,Nm as Ln,O as gi,Oa as q,Ob as ce,Om as On,Pa as v,Pb as se,Pc as zi,Pj as yn,Pm as Bn,Qj as hn,Qk as bn,R as Ye,Rd as re,S as W,Ta as me,Td as kt,Tk as qt,Tn as st,U as Fi,Ua as y,Ub as p,Ui as mn,Vb as m,Vd as yi,Vk as k,Vl as Kt,Wb as D,Wc as Ot,We as Xi,Xb as Le,Xe as Ji,Yb as ji,Yc as pe,Yd as Q,Ye as en,Yg as Ae,Z as ve,Zc as Bt,Zi as un,Zk as Yt,_ as It,_a as o,_b as P,_c as Mt,_d as Oe,_k as rt,aa as B,ab as a,ah as J,ai as yt,bb as c,bc as Qi,bg as Rt,bi as cn,bl as Sn,ch as nn,ci as pn,e as St,ea as N,el as An,fa as H,fb as A,fi as ht,fl as ke,gb as I,gf as tn,gi as Ht,h as ki,hb as ze,hc as X,hi,hl as In,ib as V,ic as F,jc as T,jh as on,jj as vn,kb as U,kc as $i,l as Ri,lc as qi,m as $e,mb as d,mc as Yi,mh as nt,mi as Vt,ml as Te,nd as Wi,nh as w,nl as Tn,oa as Je,oi as Ut,ol as En,p as ne,ph as Nt,q as qe,qa as et,qc as Pt,qh as rn,qi as Ft,r as At,rc as G,rm as Pe,sc as Dt,se as ae,sh as ot,sn as Mn,so as Jt,tb as E,ti as Ie,tn as kn,to as Un,ub as fi,uc as wt,uj as _n,ul as Re,um as Wt,un as Rn,va as S,vb as z,vm as He,wa as Gi,wl as zt,x as Ni,xb as oe,xn as Nn,yb as u,yi as Me,yn as Hn,yo as Ue,z as Hi,zb as h,zi as dn,zo as ei}from"./chunk-5FIO62PX.js";import"./chunk-CCWZEKOQ.js";import"./chunk-UXQYALUZ.js";import{a as Ce,h as Xo}from"./chunk-CJZK3ASG.js";var er=t=>t.holdings,ni=Zi(er,t=>t.selectedBusinessDay);var ro=Xo(Jo());var xi=class{constructor(){this.accountAssetDetailList=[],this.exchangeRates={},this.positionEvalSummaryList={CAD:{marketValueAmt:0,dayChangeMarketAmt:0,dayChangeInd:!0,costAmt:0,pnlAmt:0,pnlPerc:0,posMarginAmt:0}}}},Si=class{constructor(){this.accountAssetsInfos=[],this.exchangeRates={},this.grandTotalByCurrencyList={}}},K=(()=>{class t{constructor(e,n,r,_,C,b,M,ue){this.http=e,this.dict=n,this.currency=r,this.userProfileService=_,this.progressiveLoader=C,this.accountsApiService=b,this.store=M,this.refreshService=ue,this.RefreshedPage=Z}init(){this.defaultPrefix$=this.store.pipe(R(Me),ne(e=>An(e))),this.isMultiRoot$=this.store.pipe(R(Ie),ne(e=>e.length>2)),this.refresh()}hasTradeAccess(e){switch(e.finInstrumentTypeCd){case"STOCK":case"ETF":return this.userProfileService.hasAccess(Oe.FUNC_TRANSMIT_ORDER_STOCKS_ETF);case"OPTION":return this.userProfileService.hasAccess(Oe.FUNC_TRANSMIT_ORDER_OPTIONS);case"MUTUAL_FUND":return this.userProfileService.hasAccess(Oe.FUNC_TRANSMIT_ORDER_MUTUAL_FUNDS);default:return!1}}showPortfolioNameHeader(e,n,r){let _=!1;if(r)if(n===0)_=!0;else{let C=e.accountAssetDetailList[n-1],b=e.accountAssetDetailList[n];C.portfolioName!==b.portfolioName&&(_=!0)}return _}showPortfolioNameHeaderLastBusinessDay(e,n,r){let _=!1;if(r)if(n===0)_=!0;else{let C=e.accountAssetsInfos[n-1],b=e.accountAssetsInfos[n];C.portfolioName!==b.portfolioName&&(_=!0)}return _}getExchangeRate(e,n){let r;if(n){let _=this.getSelectedCurrency(n.account.acctNo);r=this.getCurrencyPair(_,n)}return e.exchangeRates[r]}getSelectedCurrency(e){return this.currency.getSelectedCurrency(e)}getAssetsDetail(e){let n=this.currency.getSelectedCurrency(e.account.acctNo);return e.assetsDetailByCurrencyList[n]}getAssetDetailListByCurrency(e){let n=this.currency.getSelectedCurrency(e.account.acctNo);return e.assetDetailListByCurrencyList[n]}isInDisplayedCurrency(e,n,r){return r||(r=this.currency.getSelectedCurrency(e)),n.finInstrument.marketSymbol.symbolCurrCd!=null&&n.finInstrument.marketSymbol.symbolCurrCd===r}getPositionInSymbolCurrency(e,n){return this.findPositionSymbolCurrency(e,n.finInstrument)}findPositionSymbolCurrency(e,n){let r=n.marketSymbol.symbolCurrCd,_=e.assetsDetailByCurrencyList[r];if(_!=null){for(let C of _.positionList)if(C.finInstrument.finInstrumentId===n.finInstrumentId)return C}return null}getCurrencyPair(e,n){let r,_;if(n&&n.assetsDetailByCurrencyList){let b=Object.keys(n.assetsDetailByCurrencyList);r=b[0],_=b[1]}else if(n&&n.assetDetailListByCurrencyList){let b=Object.keys(n.assetDetailListByCurrencyList);r=b[0],_=b[1]}let C=e===r?_:r;return e+"/"+C}export(e){let n=Ht(this.selectedAccounts);this.accountsApiService.exportAssetsDetail(n,e).subscribe(r=>(0,ro.saveAs)(r,e.filename))}refresh(){this.refreshService.initTime(Z.ACCOUNTS_HOLDINGS),this.accountAssetsDetailGroup$=qe([this.store.pipe(R(Pe,Z.ACCOUNTS_HOLDINGS)),this.store.pipe(R(Ie)),this.store.pipe(R(Me))]).pipe(Ye(([,e,n])=>{this.selectedAccounts=ht(n);let r=new xi,_=[];return e&&e.forEach(C=>{C.accountList.forEach(b=>{n.indexOf(b.acctNo)>=0&&_.push(b)})}),this.progressiveLoader.load(r,_,(C,b)=>this.getOneAccountGroup(b,C.map(M=>M.acctNo)),(C,b)=>this.nextAssetDetails(C,b))})),this.accountAssetsDetailGroupOnLastBusinessDay$=qe([this.store.pipe(R(Pe,Z.ACCOUNTS_HOLDINGS)),this.store.pipe(R(Ie)),this.store.pipe(R(Me))]).pipe(Ye(([,e,n])=>{this.selectedAccounts=ht(n);let r=new Si,_=[];return e&&e.forEach(C=>{C.accountList.forEach(b=>{n.indexOf(b.acctNo)>=0&&_.push(b)})}),this.progressiveLoader.load(r,_,(C,b)=>this.getOneLastBusinessDayAccountGroup(b,C.map(M=>M.acctNo)),(C,b)=>this.nextLastBusinessDayAssetDetails(C,b))}))}getOneAccountGroup(e,n){return this.http.get(this.buildApiURI(n),yi({spinner:kt.NONE})).pipe(ne(({data:r})=>(this.applyFinInstrumentCatLabel(r),r)))}getOneLastBusinessDayAccountGroup(e,n){return this.http.get(this.buildLastBusinessDayApiURI(n),yi({spinner:e===0?kt.HARD:kt.NONE})).pipe(ne(({data:r})=>(r.accountAssetsInfos.forEach(_=>{_.portfolioName=_.account.cltName,_.portfolioAlias=_.account.aliasVal}),r)))}nextAssetDetails(e,n){n.accountAssetDetailList.forEach(r=>{if(!this.currency.hasCurrencyList(r.account.acctNo)){let _=r.account.acctCurrCd;this.currency.createCurrencyList(r.account.acctNo,r.assetsDetailByCurrencyList),this.currency.setSelectedCurrency(r.account.acctNo,_)}}),e.exchangeRates=Ce(Ce({},e.exchangeRates),n.exchangeRates),e.accountAssetDetailList=e.accountAssetDetailList.concat(n.accountAssetDetailList),this.sumGrandTotal(e.positionEvalSummaryList.CAD,n.positionEvalSummaryList.CAD)}nextLastBusinessDayAssetDetails(e,n){n.accountAssetsInfos.forEach(r=>{if(!this.currency.hasCurrencyList(r.account.acctNo)){let _=r.account.acctCurrCd;this.currency.createCurrencyList(r.account.acctNo,r.assetDetailListByCurrencyList),this.currency.setSelectedCurrency(r.account.acctNo,_)}}),e.exchangeRates=Ce(Ce({},e.exchangeRates),n.exchangeRates),e.accountAssetsInfos=e.accountAssetsInfos.concat(n.accountAssetsInfos),e.grandTotalByCurrencyList=Ce(Ce({},e.grandTotalByCurrencyList),n.grandTotalByCurrencyList)}sumGrandTotal(e,n){let r=n;if(e.costAmt+=r.costAmt||0,e.marketValueAmt+=r.marketValueAmt||0,e.dayChangeMarketAmt+=r.dayChangeMarketAmt||0,e.pnlAmt+=r.pnlAmt||0,e.costAmt&&e.costAmt!==0){let _=Math.abs((e.marketValueAmt/e.costAmt-1)*100);e.pnlPerc=_*(e.pnlAmt<0?-1:1)}}buildApiURI(e){let n=hi(e);return this.userProfileService.hasAccessQuoteRealTime&&(n!==""&&(n+="&"),n+="realtimePrice=true"),`/accounts/assetsDetail?${n}`}buildLastBusinessDayApiURI(e){return`/accounts/assetsDetail/lastBusinessDay?${hi(e)}`}applyFinInstrumentCatLabel(e){let n={AC:"STK",OP:"OPT",DT:"FI",FI:"FND"};e.accountAssetDetailList.forEach(_=>{Object.keys(_.assetsDetailByCurrencyList).filter(M=>M.match(/[A-Z]{3}
1/)).forEach(M=>{_.assetsDetailByCurrencyList[M].positionList.forEach(je=>{let Qe=n[je.finInstrument.finInstrumentCatCd];Qe||(Qe="OTH"),Qe==="STK"&&je.securityType==="ETF"&&(Qe="ETF"),je.finInstrument.finInstrumentCatLabel=this.dict.entry(`orion.holdings.${Qe}`)})})})}static{this.\u0275fac=function(n){return new(n||t)(B(it),B(J),B(ge),B(O),B(Hn),B(Pn),B(j),B(Re))}}static{this.\u0275prov=ve({token:t,factory:t.\u0275fac})}}return t})();function tr(t,s){if(t&1){let e=V();l(0,"app-select",2),p(1,"dict"),U("ngModelChange",function(r){N(e);let _=d(2);return H(_.updateState(r))}),a()}if(t&2){let e=d().ngIf,n=d();o("ngModel",e)("options",n.businessDayOptions)("showShortLabel",!1)("emitEventWhenAutoSetDefaultValue",!1)("setInitialValue",!1),me("aria-label",m(1,6,"orion.holdings.BUSINESS_DAY_SELECTIONS"))}}function ir(t,s){if(t&1&&(A(0),v(1,tr,2,8,"app-select",1),I()),t&2){let e=d();i(),o("ngIf",!e.mobile&&(e.businessDayOptions==null?null:e.businessDayOptions.length)>0)}}var ao=(()=>{class t extends Q{constructor(e){super(),this.store=e,this.mobile=!1}ngOnInit(){this.businessDayOptions=this.getBusinessDayLabel(),this.selectedBusinessDay$=this.store.pipe(R(ni))}getBusinessDayLabel(){return[{label:"orion.holdings.AS_OF_TODAY",value:Ct.AS_OF_TODAY},{label:"orion.holdings.AS_OF_LAST_BUSINESS_DAY",value:Ct.AS_OF_LAST_BUSINESS_DAY}]}updateState(e){e&&this.store.dispatch(Zn({selectedBusinessDay:e}))}static{this.\u0275fac=function(n){return new(n||t)(f(j))}}static{this.\u0275cmp=x({type:t,selectors:[["app-holdings-business-day-selector"]],inputs:{mobile:"mobile"},standalone:!1,features:[q],decls:2,vars:3,consts:[[4,"ngIf"],["styleClass","or-wide",3,"ngModel","options","showShortLabel","emitEventWhenAutoSetDefaultValue","setInitialValue","aria-label","ngModelChange",4,"ngIf"],["styleClass","or-wide",3,"ngModelChange","ngModel","options","showShortLabel","emitEventWhenAutoSetDefaultValue","setInitialValue","aria-label"]],template:function(n,r){n&1&&(v(0,ir,2,1,"ng-container",0),p(1,"async")),n&2&&o("ngIf",m(1,1,r.selectedBusinessDay$))},dependencies:[T,mn,_n,un,G,w],encapsulation:2,changeDetection:0})}}return t})();var lo=(()=>{class t{constructor(){}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=x({type:t,selectors:[["app-intra-day-change-summary"]],inputs:{intraDayChange:"intraDayChange"},standalone:!1,decls:60,vars:61,consts:[[1,"or-big-label"],[3,"innerHtml"],["id","summaryTable",1,"or-table"],[1,"or-table-body"],[1,"or-table-row","or-table-header"],[1,"or-table-cell","or-grow-summaryId"],["id","summaryTableHeaderCompareQty",1,"or-table-cell","or-right","or-grow-summaryCompareQty"],["id","summaryTableHeaderComparePrice",1,"or-table-cell","or-right","or-grow-summaryComparePrice"],["id","summaryTableHeaderCompareTot",1,"or-table-cell","or-right","or-grow-summaryCompareTot"],[1,"or-table-row"],["id","summaryTableMarketValueLabel",1,"or-table-cell","or-grow-summaryId"],["id","summaryTableMarketValueCompareQty",1,"or-table-cell","or-right","or-grow-summaryCompareQty"],["id","summaryTableMarketValueComparePrice",1,"or-table-cell","or-right","or-grow-summaryComparePrice"],["digits","1.2-5",3,"value"],["id","summaryTableMarketValueCompareTot",1,"or-table-cell","or-right","or-grow-summaryCompareTot"],["digits","1.2-3",3,"value"],["id","summaryTableAvgValueLastClosingLabel",1,"or-table-cell","or-grow-summaryId"],["id","summaryTableAvgValueLastClosingCompareQty",1,"or-table-cell","or-right","or-grow-summaryCompareQty"],["id","summaryTableAvgValueLastClosingComparePrice",1,"or-table-cell","or-right","or-grow-summaryComparePrice"],["id","summaryTableAvgValueLastClosingCompareTot",1,"or-table-cell","or-right","or-grow-summaryCompareTot"],[1,"or-table-row","or-table-row-no-bottom-border","align-items-start"],["id","summaryTableVariationLabel",1,"or-table-cell","or-bold","or-grow-summaryId"],["id","summaryTableVariationCompareQty",1,"or-table-cell","or-right","or-grow-summaryCompareQty"],["id","summaryTableVariationComparePrice",1,"or-table-cell","or-right","or-grow-summaryComparePrice"],["id","summaryTableVariationCompareTot",1,"or-table-cell","or-right","or-grow-summaryCompareTot","flex-column","align-items-end"],["digits","1.2-3",3,"value","colored","arrow"],[1,"pl-1"],["digits","1.2-3","decorator","(#%)",3,"value","colored"]],template:function(n,r){n&1&&(l(0,"div",0),c(1,"span",1),p(2,"dict"),a(),l(3,"div",2)(4,"div",3)(5,"div",4),c(6,"div",5),l(7,"div",6),c(8,"span",1),p(9,"dict"),a(),l(10,"div",7),c(11,"span",1),p(12,"dict"),a(),l(13,"div",8),c(14,"span",1),p(15,"dict"),a()(),l(16,"div",9)(17,"div",10),c(18,"span",1),p(19,"dict"),a(),l(20,"div",11),p(21,"dict"),l(22,"span"),u(23),a()(),l(24,"div",12),p(25,"dict"),c(26,"app-value-styler",13),a(),l(27,"div",14),p(28,"dict"),c(29,"app-value-styler",15),a()(),l(30,"div",9)(31,"div",16),c(32,"span",1),p(33,"dict"),a(),l(34,"div",17),p(35,"dict"),l(36,"span"),u(37),a()(),l(38,"div",18),p(39,"dict"),c(40,"app-value-styler",13),a(),l(41,"div",19),p(42,"dict"),c(43,"app-value-styler",13),a()(),l(44,"div",20)(45,"div",21),c(46,"span",1),p(47,"dict"),a(),l(48,"div",22),p(49,"dict"),l(50,"span"),u(51),a()(),l(52,"div",23),p(53,"dict"),c(54,"app-value-styler",13),a(),l(55,"div",24),p(56,"dict"),c(57,"app-value-styler",25),l(58,"div",26),c(59,"app-value-styler",27),a()()()()()),n&2&&(i(),o("innerHtml",m(2,29,"orion.intra-day-change-summary.SUMMARY_TABLE_TITLE"),S),i(7),o("innerHtml",m(9,31,"orion.intra-day-change-summary.SUMMARY_TABLE_HEADER_COMPARE_QTY"),S),i(3),o("innerHtml",m(12,33,"orion.intra-day-change-summary.SUMMARY_TABLE_HEADER_COMPARE_PRICE"),S),i(3),o("innerHtml",m(15,35,"orion.intra-day-change-summary.SUMMARY_TABLE_HEADER_COMPARE_TOT"),S),i(4),o("innerHtml",m(19,37,"orion.intra-day-change-summary.SUMMARY_TABLE_MARKET_VALUE"),S),i(2),y("data-header",m(21,39,"orion.intra-day-change-summary.SUMMARY_TABLE_HEADER_COMPARE_QTY")),i(3),h(r.intraDayChange.compareQtyTot),i(),y("data-header",m(25,41,"orion.intra-day-change-summary.SUMMARY_TABLE_HEADER_COMPARE_PRICE")),i(2),o("value",r.intraDayChange.lastMarketPrice),i(),y("data-header",m(28,43,"orion.intra-day-change-summary.SUMMARY_TABLE_HEADER_COMPARE_TOT")),i(2),o("value",r.intraDayChange.currentAmtTot),i(3),o("innerHtml",m(33,45,"orion.intra-day-change-summary.SUMMARY_TABLE_AVG_VALUE_LAST_CLOSING"),S),i(2),y("data-header",m(35,47,"orion.intra-day-change-summary.SUMMARY_TABLE_HEADER_COMPARE_QTY")),i(3),h(r.intraDayChange.compareQtyTot),i(),y("data-header",m(39,49,"orion.intra-day-change-summary.SUMMARY_TABLE_HEADER_COMPARE_PRICE")),i(2),o("value",r.intraDayChange.comparePriceAvg),i(),y("data-header",m(42,51,"orion.intra-day-change-summary.SUMMARY_TABLE_HEADER_COMPARE_TOT")),i(2),o("value",r.intraDayChange.compareAmtTot),i(3),o("innerHtml",m(47,53,"orion.intra-day-change-summary.SUMMARY_TABLE_VARIATION"),S),i(2),y("data-header",m(49,55,"orion.intra-day-change-summary.SUMMARY_TABLE_HEADER_COMPARE_QTY")),i(3),h(r.intraDayChange.compareQtyTot),i(),y("data-header",m(53,57,"orion.intra-day-change-summary.SUMMARY_TABLE_HEADER_COMPARE_PRICE")),i(2),o("value",r.intraDayChange.priceVariation),i(),y("data-header",m(56,59,"orion.intra-day-change-summary.SUMMARY_TABLE_HEADER_COMPARE_TOT")),i(2),o("value",r.intraDayChange.amtVariation)("colored",!0)("arrow",!0),i(2),o("value",r.intraDayChange.amtVariationPercent)("colored",!0))},dependencies:[k,w],styles:['@charset "UTF-8";.or-table-cell.or-grow-summaryId[_ngcontent-%COMP%]{flex-grow:3!important}.or-table-cell.or-grow-summaryCompareQty[_ngcontent-%COMP%], .or-table-cell.or-grow-summaryComparePrice[_ngcontent-%COMP%], .or-table-cell.or-grow-summaryCompareTot[_ngcontent-%COMP%]{flex-grow:1.5!important}.or-table[_ngcontent-%COMP%]{margin-right:15px}'],changeDetection:0})}}return t})();var dt=(function(t){return t.INVENTORY="INVENTORY",t.BUY="BUY",t.SELL="SELL",t})(dt||{});var rr=t=>({"scrollable-container":t}),ar=t=>({"scrollable-content":t});function lr(t,s){if(t&1&&(l(0,"div",18)(1,"div",5)(2,"span",15),u(3),p(4,"dict"),a()(),l(5,"div",6),p(6,"dict"),l(7,"span"),u(8),a()(),l(9,"div",7),p(10,"dict"),c(11,"app-value-styler",13),a(),l(12,"div",8),p(13,"dict"),c(14,"app-value-styler",13),a()()),t&2){let e=s.$implicit,n=s.index;i(),o("id","type-value-row-"+n),i(2),g(" ",m(4,11,"orion.intra-day-change-detail."+e.type+"_TYPE")," "),i(2),o("id","origQty-row-"+n),y("data-header",m(6,13,"orion.intra-day-change-detail.TABLE_HEADER_ORIG_QTY")),i(3),h(e.origQty),i(),o("id","origPrice-row-"+n),y("data-header",m(10,15,"orion.intra-day-change-detail.TABLE_HEADER_ORIG_PRICE")),i(2),o("value",e.origPrice),i(),o("id","origAmt-row-"+n),y("data-header",m(13,17,"orion.intra-day-change-detail.TABLE_HEADER_ORIG_AMT")),i(2),o("value",e.origAmt)}}function sr(t,s){if(t&1&&(l(0,"div",11)(1,"div",5)(2,"span",15),u(3),p(4,"dict"),a()(),l(5,"div",6),p(6,"dict"),l(7,"span"),u(8),a()(),c(9,"div",16)(10,"div",17),a()),t&2){let e=d();i(),o("id","type-value-qty-summary-footer"),i(2),g(" ",m(4,5,e.qtyToSubtractTot>0?"orion.intra-day-change-detail.QTY_SUMMARY_BUY_TYPE":"orion.intra-day-change-detail.QTY_SUMMARY_SOLD_TYPE")," "),i(2),o("id","origQty-qty-summary-footer"),y("data-header",e.qtyToSubtractTot>0?"orion.intra-day-change-detail.QTY_SUMMARY_BUY_TYPE":m(6,7,"orion.intra-day-change-detail.QTY_SUMMARY_SOLD_TYPE")),i(3),h(e.qtyToSubtractTot)}}var so=(()=>{class t{set intraDayChange(e){e&&(this.origQtyTot=e.origQtyTot,this.comparePriceAvg=e.comparePriceAvg,this.origAmtTot=e.origAmtTot,this.qtyToSubtractTot=e.qtyToSubtractTot,this.compareQtyTot=e.compareQtyTot,this.intraDayChangeDetailList=e.intraDayChangeDetailList)}constructor(){this.IntraDayChangeType=dt}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=x({type:t,selectors:[["app-intra-day-change-detail"]],inputs:{intraDayChange:"intraDayChange"},standalone:!1,decls:46,vars:52,consts:[[1,"or-big-label"],[3,"innerHtml"],["id","detailTable",1,"or-table"],[1,"or-table-body"],[1,"or-table-row","or-table-header"],[1,"or-table-cell","or-grow-type","align-content-end",3,"id"],[1,"or-table-cell","or-right","or-grow-origQty","align-content-end",3,"id"],[1,"or-table-cell","or-right","or-grow-origPrice","align-content-end",3,"id"],[1,"or-table-cell","or-right","or-grow-origAmt","align-content-end",3,"id"],[3,"ngClass"],["class","or-table-row",4,"ngFor","ngForOf"],[1,"or-table-row","or-table-footer"],[1,"or-bold"],["digits","1.2-5",3,"value"],["class","or-table-row or-table-footer",4,"ngIf"],[1,"or-regular"],[1,"or-table-cell","or-grow-origPrice"],[1,"or-table-cell","or-grow-origAmt"],[1,"or-table-row"]],template:function(n,r){n&1&&(l(0,"div",0),c(1,"span",1),p(2,"dict"),a(),l(3,"div",2)(4,"div",3)(5,"div",4),c(6,"div",5),l(7,"div",6),c(8,"span",1),p(9,"dict"),a(),l(10,"div",7),c(11,"span",1),p(12,"dict"),a(),l(13,"div",8),c(14,"span",1),p(15,"dict"),a()(),l(16,"div",9)(17,"div",9),v(18,lr,15,19,"div",10),a()(),l(19,"div",11)(20,"div",5)(21,"span",12),u(22),p(23,"dict"),a()(),l(24,"div",6),p(25,"dict"),l(26,"span"),u(27),a()(),l(28,"div",7),p(29,"dict"),c(30,"app-value-styler",13),a(),l(31,"div",8),p(32,"dict"),c(33,"app-value-styler",13),a()(),v(34,sr,11,9,"div",14),l(35,"div",11)(36,"div",5)(37,"span",15),u(38),p(39,"dict"),a()(),l(40,"div",6),p(41,"dict"),l(42,"span"),u(43),a()(),c(44,"div",16)(45,"div",17),a()()()),n&2&&(i(),o("innerHtml",m(2,28,"orion.intra-day-change-detail.TABLE_TITLE"),S),i(5),o("id","type-header"),i(),o("id","origQty-header"),i(),o("innerHtml",m(9,30,"orion.intra-day-change-detail.TABLE_HEADER_ORIG_QTY"),S),i(2),o("id","origPrice-header"),i(),o("innerHtml",m(12,32,"orion.intra-day-change-detail.TABLE_HEADER_ORIG_PRICE"),S),i(2),o("id","origAmt-header"),i(),o("innerHtml",m(15,34,"orion.intra-day-change-detail.TABLE_HEADER_ORIG_AMT"),S),i(2),o("ngClass",ce(48,rr,r.intraDayChangeDetailList.length>4)),i(),o("ngClass",ce(50,ar,r.intraDayChangeDetailList.length>4)),i(),o("ngForOf",r.intraDayChangeDetailList),i(2),o("id","type-value-total-footer"),i(2),g(" ",m(23,36,"orion.intra-day-change-detail.TOTAL_TYPE")," "),i(2),o("id","origQty-total-footer"),y("data-header",m(25,38,"orion.intra-day-change-detail.TABLE_HEADER_ORIG_QTY")),i(3),h(r.origQtyTot),i(),o("id","origPrice-total-footer"),y("data-header",m(29,40,"orion.intra-day-change-detail.TABLE_HEADER_ORIG_PRICE")),i(2),o("value",r.comparePriceAvg),i(),o("id","origAmt-total-footer"),y("data-header",m(32,42,"orion.intra-day-change-detail.TABLE_HEADER_ORIG_AMT")),i(2),o("value",r.origAmtTot),i(),o("ngIf",r.qtyToSubtractTot),i(2),o("id","type-value-actual-position-footer"),i(2),g(" ",m(39,44,"orion.intra-day-change-detail.ACTUAL_POSITION_TYPE")," "),i(2),o("id","origQty-actual-position-footer"),y("data-header",m(41,46,"orion.intra-day-change-detail.ACTUAL_POSITION_TYPE")),i(3),h(r.compareQtyTot))},dependencies:[X,F,T,k,w],styles:['@charset "UTF-8";.or-table-cell.or-grow-type[_ngcontent-%COMP%]{flex-grow:3!important}.or-table-cell.or-grow-origQty[_ngcontent-%COMP%], .or-table-cell.or-grow-origPrice[_ngcontent-%COMP%], .or-table-cell.or-grow-origAmt[_ngcontent-%COMP%]{flex-grow:1.5!important}.or-table[_ngcontent-%COMP%]{margin-right:15px}.scrollable-container[_ngcontent-%COMP%]{overflow-x:hidden;overflow-y:auto;max-height:104px;margin-right:-15px}.scrollable-container[_ngcontent-%COMP%]   .scrollable-content[_ngcontent-%COMP%]{display:inline-block;width:100%;overflow-y:visible}'],changeDetection:0})}}return t})();var dr=()=>({"margin-right":"15px"});function mr(t,s){if(t&1&&(l(0,"div",7),u(1),a()),t&2){let e=d().ngIf;i(),g(" (",e.position.finInstrument.exchangeId,") ")}}function ur(t,s){if(t&1&&(c(0,"img",26),p(1,"flagPath")),t&2){let e=s.ngIf;o("src",m(1,1,e),Gi)}}function vr(t,s){if(t&1&&(l(0,"div",23)(1,"span"),u(2),a(),c(3,"app-value-styler",16),a()),t&2){let e=d().ngIf;i(2),Et(" : ",e.exchangeRate.srcCurrencyCd," / ",e.exchangeRate.tgtCurrencyCd," =\xA0"),i(),o("value",e.exchangeRate.value)}}function _r(t,s){if(t&1&&(l(0,"div",2)(1,"app-modal",3),p(2,"dict"),l(3,"div",4)(4,"div",5)(5,"div",6)(6,"div",6)(7,"div",7),u(8),p(9,"lowercase"),a(),l(10,"div",8),v(11,mr,2,1,"div",9)(12,ur,2,3,"img",10),a()()(),l(13,"div",11)(14,"div",12)(15,"div",13)(16,"div",14),u(17),p(18,"dict"),a(),l(19,"div",15),c(20,"app-value-styler",16),a()()(),l(21,"div",17)(22,"div",14),u(23),p(24,"dict"),a(),l(25,"div",15),c(26,"span",18),a()(),l(27,"div",17)(28,"div",14),u(29),p(30,"dict"),a(),l(31,"div",15),c(32,"span",18),p(33,"dateFormatter"),a()()()()(),l(34,"div",19)(35,"div",20),c(36,"app-intra-day-change-summary",21),a(),l(37,"div",20),c(38,"app-intra-day-change-detail",21),a(),l(39,"div",22)(40,"div",23),u(41),p(42,"dict"),a(),v(43,vr,4,3,"div",24),a(),l(44,"div",25)(45,"div",23),u(46),p(47,"dict"),a()()()()()),t&2){let e=s.ngIf,n=d(2);i(),o("title",m(2,19,"orion.intra-day-change.TITLE")+" - "+e.position.finInstrument.marketSymbol.symbolCd)("contentFullWidth",!0)("boxShadow",!1)("defaultWidth","830px")("contentStyle",Ke(36,dr)),i(7),g(" ",m(9,21,e.position.finInstrument.displayDesc)," "),i(3),o("ngIf",e.position.finInstrument.exchangeId),i(),o("ngIf",e.position.finInstrument.marketSymbol.symbolCntryCd),i(5),g(" ",m(18,23,"orion.intra-day-change.LAST_PRICE")," "),i(3),o("value",e.position.positionEval.evalPrice),i(3),g(" ",m(24,25,"orion.intra-day-change.CURRENCY")," "),i(3),o("innerHtml",e.currency,S),i(3),g(" ",m(30,27,"orion.intra-day-change.LAST_REFRESH_DATE")," "),i(3),o("innerHtml",D(33,29,n.data.lastRefreshDate,"medium"),S),i(4),o("intraDayChange",e.position.positionEval.marketValueIntraDayChange),i(2),o("intraDayChange",e.position.positionEval.marketValueIntraDayChange),i(3),h(m(42,32,"orion.app.RATE")),i(2),o("ngIf",e.exchangeRate),i(3),h(m(47,34,"orion.intra-day-change.FOOTER_NOTE"))}}function gr(t,s){if(t&1&&(A(0),v(1,_r,48,37,"div",1),p(2,"async"),I()),t&2){let e=d();i(),o("ngIf",m(2,1,e.intraDayChangeModalData$))}}var co=(()=>{class t extends Q{constructor(e,n,r){if(super(),this.data=e,this.dialogRef=n,this.dictionaryService=r,!e||!e.position||!e.account||!e.currency)throw new Error("IntraDayChangeModalComponent: needs position, account and currency !")}ngOnInit(){this.dict$=this.dictionaryService.load(["intra-day-change","intra-day-change-summary","intra-day-change-detail"]),this.intraDayChangeModalData$=$e(this.data)}static{this.\u0275fac=function(n){return new(n||t)(f(Ji),f(Xi),f(J))}}static{this.\u0275cmp=x({type:t,selectors:[["app-intra-day-change"]],
1standalone:!1,features:[q],decls:2,vars:3,consts:[[4,"ngIf"],["id","intra-day-change-modal",4,"ngIf"],["id","intra-day-change-modal"],[3,"title","contentFullWidth","boxShadow","defaultWidth","contentStyle"],["metaHeader","",1,"pt-2"],[1,"d-flex","w-100"],[1,"d-lg-inline-flex","align-items-start"],[1,"or-h3","or-regular","or-black","or-capitalize","pr-2"],[1,"d-inline-flex","flex-wrap","align-self-start"],["class","or-h3 or-regular or-black or-capitalize pr-2",4,"ngIf"],["class","or-symbol-flag pt-1","alt","",3,"src",4,"ngIf"],[1,"d-flex","align-self-start","pl-lg-4"],[1,"d-lg-inline-flex","flex-wrap"],[1,"pr-4"],[1,"or-label_small","w-100"],[1,"or-h4","or-regular","or-black"],["digits","1.2-5",3,"value"],[1,"d-lg-inline-flex","flex-wrap","align-items-start"],[3,"innerHtml"],["dialogBody",""],[1,"pt-3"],[3,"intraDayChange"],[1,"d-flex","py-2"],[1,"d-inline","label-small-compact-theme"],["class","d-inline label-small-compact-theme",4,"ngIf"],[1,"d-flex","py-1"],["alt","",1,"or-symbol-flag","pt-1",3,"src"]],template:function(n,r){n&1&&(v(0,gr,3,3,"ng-container",0),p(1,"async")),n&2&&o("ngIf",m(1,1,r.dict$))},dependencies:[T,k,sn,lo,so,G,Dt,w,Tn,En],encapsulation:2,changeDetection:0})}}return t})();var hr=(t,s)=>({"or-label_small":t,"or-h4":s});function Cr(t,s){if(t&1&&(l(0,"div",9),c(1,"app-order-counts",10),a()),t&2){let e=d(3);i(),o("orderCounts",e.position)("clickable",!0)("acctNo",e.account.acctNo)("symbol",e.position.finInstrument.marketSymbol.symbolCd)("mini",!0)}}function br(t,s){if(t&1&&(l(0,"div",6),c(1,"app-symbol-link",7),v(2,Cr,2,5,"div",8),a()),t&2){let e=d(2);i(),o("finInstrument",e.positionOrQuote.finInstrument)("securityType",e.positionOrQuote.securityType)("acctNo",e.account.acctNo)("symbolStyle",e.symbolStyle),i(),o("ngIf",!e.isBasket&&e.position)}}function xr(t,s){if(t&1&&(l(0,"div",12),u(1),p(2,"uppercase"),a()),t&2){let e=d(3);i(),g(" ",m(2,1,e.position.finInstrument.displayDescFull)," ")}}function Sr(t,s){if(t&1&&(A(0),l(1,"div",11),u(2),p(3,"uppercase"),a(),v(4,xr,3,3,"ng-template",null,1,P),I()),t&2){let e=E(5),n=d(2);i(),o("ngClass",se(5,hr,!n.emptySymbolCd,n.emptySymbolCd))("bncPopover",e),i(),g(" ",m(3,3,n.position.finInstrument.displayDescFull)," ")}}function Ar(t,s){if(t&1&&(l(0,"div",13)(1,"app-tooltip",14),p(2,"uppercase"),l(3,"div",15),u(4),p(5,"uppercase"),a()()()),t&2){let e=d(2);i(),o("textTooltip",m(2,2,e.positionOrQuote.finInstrument.displayDesc)),i(3),g(" ",m(5,4,e.positionOrQuote.finInstrument.displayDesc)," ")}}function Ir(t,s){if(t&1&&(l(0,"div",16)(1,"div",17),c(2,"app-order-counts",10),a()()),t&2){let e=d(2);i(2),o("orderCounts",e.position)("clickable",!0)("acctNo",e.account.acctNo)("symbol",e.position.finInstrument.marketSymbol.symbolCd)("mini",!0)}}function Tr(t,s){if(t&1&&(l(0,"div"),v(1,br,3,5,"div",3)(2,Sr,6,8,"ng-container",4)(3,Ar,6,6,"ng-template",null,0,P)(5,Ir,3,5,"div",5),a()),t&2){let e=E(4),n=d();i(),o("ngIf",!n.emptySymbolCd),i(),o("ngIf",n.isBasket)("ngIfElse",e),i(3),o("ngIf",!n.isBasket&&n.position)}}var ut=(()=>{class t{constructor(e,n){this.userProfile=e,this.symbolLinkService=n,this.isBasket=!1}ngOnInit(){this.positionOrQuote=this.position?this.position:this.quote,this.emptySymbolCd=!this.positionOrQuote.finInstrument.marketSymbol.symbolCd}static{this.\u0275fac=function(n){return new(n||t)(f(O),f(ti))}}static{this.\u0275cmp=x({type:t,selectors:[["app-account-symbol-link"]],inputs:{position:"position",account:"account",isBasket:"isBasket",quote:"quote",symbolStyle:"symbolStyle"},standalone:!1,decls:1,vars:1,consts:[["notBasket",""],["DescFull",""],[4,"ngIf"],["class","d-flex",4,"ngIf"],[4,"ngIf","ngIfElse"],["class","or-box or-no-padding",4,"ngIf"],[1,"d-flex"],[3,"finInstrument","securityType","acctNo","symbolStyle"],["class","or-mobile-hide",4,"ngIf"],[1,"or-mobile-hide"],[3,"orderCounts","clickable","acctNo","symbol","mini"],["bncPopoverPosition","bottom","bncPopoverTrigger","hover",1,"or-capitalize","or-ellipsis","or-max-width-180",3,"ngClass","bncPopover"],["id","DescFull"],[1,"or-font-10","or-normal","or-black"],["position","right","classTooltip","or-ellipsis",3,"textTooltip"],[1,"d-block","text-truncate"],[1,"or-box","or-no-padding"],[1,"or-box-child","or-small-gap","or-desktop-hide"]],template:function(n,r){n&1&&v(0,Tr,6,4,"div",2),n&2&&o("ngIf",r.position||r.quote)},dependencies:[X,T,de,Ne,zt,$n,wt],styles:[".or-max-width-180[_ngcontent-%COMP%]{max-width:180px}"],changeDetection:0})}}return t})();var po=(()=>{class t{static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=x({type:t,selectors:[["app-single-quantity"]],inputs:{label:"label",quantity:"quantity",digits:"digits"},standalone:!1,decls:5,vars:3,consts:[[1,"d-flex","justify-content-between"],[1,"pr-5"],[3,"value","digits"]],template:function(n,r){n&1&&(l(0,"div",0)(1,"div",1),u(2),a(),l(3,"div"),c(4,"app-value-styler",2),a()()),n&2&&(i(2),h(r.label),i(2),o("value",r.quantity)("digits",r.digits))},dependencies:[k],encapsulation:2,changeDetection:0})}}return t})();function Pr(t,s){if(t&1&&c(0,"app-value-styler",6),t&2){let e=d(2);o("underlined",!0)("value",e.position.quantity)("digits",e.digits)}}function Dr(t,s){if(t&1&&c(0,"app-value-styler",7),t&2){let e=d(2);o("value",e.position.quantity)("digits",e.digits)}}function wr(t,s){if(t&1&&(c(0,"app-single-quantity",10),p(1,"dict")),t&2){let e=d(3);o("label",m(1,3,"orion.holdings.QUANTITY_OUT_ON_LOAN"))("quantity",e.position.lendingQty)("digits",e.digits)}}function Lr(t,s){if(t&1&&(A(0),c(1,"div",12),l(2,"div",13),c(3,"app-single-quantity",10),p(4,"dict"),a(),I()),t&2){let e=d(3);i(3),o("label",m(4,3,"orion.holdings.TOTAL_QUANTITY"))("quantity",e.position.quantity)("digits",e.digits)}}function Or(t,s){if(t&1&&(l(0,"div",8)(1,"div",9),u(2),p(3,"dict"),a(),c(4,"app-single-quantity",10),p(5,"dict"),c(6,"app-single-quantity",10),p(7,"dict"),c(8,"app-single-quantity",10),p(9,"dict"),c(10,"app-single-quantity",10),p(11,"dict"),v(12,wr,2,5,"app-single-quantity",11)(13,Lr,5,5,"ng-container",2),a()),t&2){let e=d(2);i(2),h(m(3,15,"orion.holdings.QUANTITY_DETAILS")),i(2),o("label",m(5,17,"orion.holdings.
1CURRENT_QUANTITY"))("quantity",e.position.currQty)("digits",e.digits),i(2),o("label",m(7,19,"orion.holdings.QUANTITY_ON_HOLD"))("quantity",e.position.safeKeepingQty)("digits",e.digits),i(2),o("label",m(9,21,"orion.holdings.QUANTITY_PENDING_SETTLEMENT"))("quantity",e.position.pendingQty)("digits",e.digits),i(2),o("label",m(11,23,"orion.holdings.QUANTITY_FILLED_TODAY"))("quantity",e.position.execQty)("digits",e.digits),i(2),o("ngIf",e.isShowLendingQty),i(),o("ngIf",!e.isActivateFPLOnAllAccounts)}}function Br(t,s){if(t&1&&(A(0),l(1,"a",3,0),v(3,Pr,1,3,"app-value-styler",4)(4,Dr,1,2,"app-value-styler",5),a(),v(5,Or,14,25,"ng-template",null,1,P),I()),t&2){let e=E(6),n=d();i(),o("bncPopover",e),i(2),o("ngIf",n.position.execQty),i(),o("ngIf",!n.position.execQty)}}var ri=(()=>{class t{constructor(e){this.featureFlagsService=e,this.isActivateFPLOnAllAccounts=this.featureFlagsService.isEnabled("fpl",Be)}ngOnInit(){this.digits=this.position?.finInstrument?.finInstrumentTypeCd===Sn.MUTUAL_FUND?"1.0-3":"1.0-1"}static{this.\u0275fac=function(n){return new(n||t)(f(Se))}}static{this.\u0275cmp=x({type:t,selectors:[["app-detailed-quantity"]],inputs:{position:"position",isShowLendingQty:"isShowLendingQty"},standalone:!1,decls:1,vars:1,consts:[["popover","bncPopover"],["detailedQuantity",""],[4,"ngIf"],["href","javascript:void(0)","bncPopoverPosition","bottom",3,"bncPopover"],[3,"underlined","value","digits",4,"ngIf"],[3,"value","digits",4,"ngIf"],[3,"underlined","value","digits"],[3,"value","digits"],["id","detailed-quantity-popover"],[1,"or-h4","pb-2"],[3,"label","quantity","digits"],[3,"label","quantity","digits",4,"ngIf"],[1,"pb-2"],[1,"border-top","py-2"]],template:function(n,r){n&1&&v(0,Br,7,3,"ng-container",2),n&2&&o("ngIf",r.position)},dependencies:[T,de,k,po,w],encapsulation:2,changeDetection:0})}}return t})();function kr(t,s){t&1&&(l(0,"div",19),c(1,"app-collapsible-toggle"),a())}function Rr(t,s){t&1&&c(0,"div",20)}function Nr(t,s){t&1&&c(0,"div",21)}function Hr(t,s){t&1&&c(0,"div",22)}function Vr(t,s){t&1&&c(0,"div",23)}function Ur(t,s){if(t&1&&(A(0),c(1,"app-account-symbol-link",58),I()),t&2){let e=d().$implicit,n=d(2);i(),o("account",n.account)("isBasket",!1)("quote",e.quote)}}function Fr(t,s){if(t&1&&u(0),t&2){let e=d().$implicit;g(" ",e.symbol," ")}}function Gr(t,s){if(t&1&&(l(0,"div",2)(1,"div",48),p(2,"dict"),l(3,"div",49)(4,"div",50)(5,"div",51),v(6,Ur,2,3,"ng-container",52)(7,Fr,1,1,"ng-template",null,0,P),a()()()(),l(9,"div",45),p(10,"dict"),l(11,"div",53),c(12,"div",54),p(13,"valueStyler"),a()(),l(14,"div",45),p(15,"dict"),l(16,"div",53),u(17),a()(),l(18,"div",55),p(19,"dict"),l(20,"div",53),c(21,"div",54),p(22,"valueStyler"),a()(),l(23,"div",56),p(24,"dict"),l(25,"div",53),u(26),a()(),l(27,"div",56),p(28,"dict"),l(29,"div",53),c(30,"div",54),p(31,"valueStyler"),a()(),l(32,"div",56),p(33,"dict"),l(34,"div",53),c(35,"div",54),p(36,"valueStyler"),a()(),l(37,"div",56),p(38,"dict"),l(39,"div",53),c(40,"div",54),p(41,"valueStyler"),a()(),l(42,"div",56),p(43,"dict"),l(44,"div",53),c(45,"app-value-styler",57),a()()()),t&2){let e=s.$implicit,n=E(8);i(),y("data-header",m(2,19,"orion.holdings.SYMBOL")),i(5),o("ngIf",e.quote)("ngIfElse",n),i(3),y("data-header",m(10,21,"orion.holdings.UNIT_COST")),i(3),o("innerHTML",D(13,23,e.unitCost,"1.2-5"),S),i(2),y("data-header",m(15,26,"orion.holdings.BASKET_QTY_HELD")),i(3),g(" ",e.basketQuantityHeld," "),i(),y("data-header",m(19,28,"orion.holdings.BASKET_MARKET_VALUE")),i(3),o("innerHTML",D(22,30,e.basketMarketValue,"1.2-2"),S),i(2),y("data-header",m(24,33,"orion.holdings.ACCOUNT_QTY_HELD")),i(3),g(" ",e.accountQuantityHeld," "),i(),y("data-header",m(28,35,"orion.holdings.ACCOUNT_MARKET_VALUE")),i(3),o("innerHTML",D(31,37,e.accountMarketValue,"1.2-2"),S),i(2),y("data-header",m(33,40,"orion.holdings.AVERAGE_UNIT_COST")),i(3),o("innerHTML",D(36,42,e.accountAverageUnitCost,"1.2-5"),S),i(2),y("data-header",m(38,45,"orion.holdings.TOTAL_COST")),i(3),o("innerHTML",D(41,47,e.accountTotalCost,"1.2-2"),S),i(2),y("data-header",m(43,50,"orion.holdings.BASKET_ACCOUNT_COST")),i(3),o("value",e.basketAccountPercent)}}function jr(t,s){if(t&1&&(l(0,"div",24)(1,"div",25)(2,"div",26)(3,"div",27)(4,"div",28)(5,"div",29),u(6),p(7,"dict"),l(8,"span",30),u(9),a(),u(10),p(11,"dict"),a()()(),l(12,"div",27),c(13,"div",31),l(14,"div",32),u(15),p(16,"dict"),a(),l(17,"div",33),u(18),p(19,"dict"),a()(),l(20,"div",27)(21,"div",34),u(22),p(23,"dict"),a(),l(24,"div",35),u(25),p(26,"dict"),a(),l(27,"div",36),u(28),p(29,"dict"),a(),l(30,"div",37),u(31),p(32,"dict"),a(),l(33,"div",38),u(34),p(35,"dict"),a(),l(36,"div",39),u(37),p(38,"dict"),a(),l(39,"div",40),u(40),p(41,"dict"),a(),l(42,"div",41),u(43),p(44,"dict"),a(),l(45,"div",42),u(46),p(47,"dict"),a()(),v(48,Gr,46,52,"div",43),p(49,"orderBy"),l(50,"div",2)(51,"div",31)(52,"div",44),u(53),p(54,"dict"),a()(),c(55,"div",45)(56,"div",45),l(57,"div",46),c(58,"app-value-styler",47),a(),c(59,"div",45),l(60,"div",46),c(61,"app-value-styler",47),a(),c(62,"div",45),l(63,"div",46),c(64,"app-value-styler",47),a(),c(65,"div",45),a()()()()),t&2){let e=d();i(6),g(" ",D(7,28,"orion.holdings.BASKET_MESSAGE_PART1",e.position.basketDetail.basketSummary.percentageAccount)," "),i(3),h(e.position.finInstrument.displayDesc),i(),g(" ",D(11,31,"orion.holdings.BASKET_MESSAGE_PART2",e.position.basketDetail.basketSummary.percentagePortfolio)," "),i(5),g(" ",m(16,34,"orion.holdings.HELD_IN_BASKET")," "),i(3),g(" ",m(19,36,"orion.holdings.HELD_IN_ACCOUNT")," "),i(3),o("appSortService",e.sort),i(),g(" ",m(23,38,"orion.holdings.SYMBOL")," "),i(2),o("appSortService",e.sort),i(),g(" ",m(26,40,"orion.holdings.UNIT_COST")," "),i(2),o("appSortService",e.sort),i(),g(" ",m(29,42,"orion.holdings.BASKET_QTY_HELD")," "),i(2),o("appSortService",e.sort),i(),g(" ",m(32,44,"orion.holdings.BASKET_MARKET_VALUE")," "),i(2),o("appSortService",e.sort),i(),g(" ",m(35,46,"orion.holdings.ACCOUNT_QTY_HELD")," "),i(2),o("appSortService",e.sort),i(),g(" ",m(38,48,"orion.holdings.ACCOUNT_MARKET_VALUE")," "),i(2),o("appSortService",e.sort),i(),g(" ",m(41,50,"orion.holdings.AVERAGE_
1UNIT_COST")," "),i(2),o("appSortService",e.sort),i(),g(" ",m(44,52,"orion.holdings.TOTAL_COST")," "),i(2),o("appSortService",e.sort),i(),g(" ",m(47,54,"orion.holdings.BASKET_ACCOUNT_COST")," "),i(2),o("ngForOf",D(49,56,e.position.basketDetail.basketDetailPositions,e.sort.orderBy())),i(5),g(" ",m(54,59,"orion.holdings.TOTAL_BASKET")),i(5),o("value",e.position.basketDetail.basketMarketValueTotal),i(3),o("value",e.position.basketDetail.accountMarketValueTotal),i(3),o("value",e.position.basketDetail.accountTotalCostTotal)}}var uo=(()=>{class t{constructor(e,n,r){this.userProfile=e,this.holdingsService=n,this.sort=r}static{this.\u0275fac=function(n){return new(n||t)(f(O),f(K),f($))}}static{this.\u0275cmp=x({type:t,selectors:[["app-basket"]],inputs:{position:"position",account:"account"},standalone:!1,decls:19,vars:15,consts:[["symbol",""],["appCollapsible","",3,"grouped","desktop"],[1,"or-table-row"],[1,"or-table-cell","or-position-1"],[1,"or-box","or-no-padding","or-stretch"],[1,"or-box-child","or-stretch","or-no-padding","or-box-no-wrap"],[1,"or-box-child"],[3,"position","account","isBasket"],["class","or-box-child or-box-end",4,"ngIf"],[1,"or-table-cell","or-numeric","or-position-4","or-collapsible","or-grow-quantity"],[3,"position"],[1,"or-table-cell","or-position-6","or-numeric","or-collapsible","or-grow-avg-cost","or-mobile-hide"],["class","or-table-cell or-numeric or-position-7 or-collapsible or-grow-book-value or-mobile-hide",4,"ngIf"],[1,"or-table-cell","or-numeric","or-position-2","or-grow-market-price","or-mobile-hide"],[1,"or-table-cell","or-numeric","or-position-5","or-collapsible","or-grow-market-value","or-mobile-hide"],["class","or-table-cell or-position-8 or-numeric or-collapsible or-grow-unrealized-gain or-mobile-hide",4,"ngIf"],["class","or-table-cell or-position-9 or-collapsible or-grow-type or-center or-mobile-hide",4,"ngIf"],["class","or-table-cell or-position-11 or-collapsible or-grow-trade-links or-right or-flex-full or-mobile-hide",4,"ngIf"],["class","or-basket or-group-collapsible or-mobile-hide",4,"ngIf"],[1,"or-box-child","or-box-end"],[1,"or-table-cell","or-numeric","or-position-7","or-collapsible","or-grow-book-value","or-mobile-hide"],[1,"or-table-cell","or-position-8","or-numeric","or-collapsible","or-grow-unrealized-gain","or-mobile-hide"],[1,"or-table-cell","or-position-9","or-collapsible","or-grow-type","or-center","or-mobile-hide"],[1,"or-table-cell","or-position-11","or-collapsible","or-grow-trade-links","or-right","or-flex-full","or-mobile-hide"],[1,"or-basket","or-group-collapsible","or-mobile-hide"],[1,"or-table","or-flex-full"],[1,"or-table-body"],[1,"or-table-row","or-table-header"],[1,"or-table-cell","or-center"],[1,"or-label"],[1,"or-label-bold"],[1,"or-table-cell","or-flex-fifth"],[1,"or-table-cell","or-flex-30","or-center","or-group-end"],[1,"or-table-cell","or-flex-half","or-center"],["key","symbol",1,"or-table-cell","or-flex-fifth",3,"appSortService"],["key","unitCost",1,"or-table-cell","or-flex-10","or-numeric",3,"appSortService"],["key","basketQuantityHeld",1,"or-table-cell","or-flex-10","or-numeric",3,"appSortService"],["key","basketMarketValue",1,"or-table-cell","or-flex-10","or-numeric",3,"appSortService"],["key","accountQuantityHeld",1,"or-table-cell","or-flex-10","or-numeric",3,"appSortService"],["key","accountMarketValue",1,"or-table-cell","or-flex-10","or-numeric",3,"appSortService"],["key","accountAverageUnitCost",1,"or-table-cell","or-flex-10","or-numeric",3,"appSortService"],["key","accountTotalCost",1,"or-table-cell","or-flex-10","or-numeric",3,"appSortService"],["key","basketAccountPercent",1,"or-table-cell","or-flex-10","or-numeric",3,"appSortService"],["class","or-table-row",4,"ngFor","ngForOf"],[1,"or-h4"],[1,"or-table-cell","or-flex-10","or-numeric"],[1,"or-table-cell","or-flex-10","or-numeric","or-h4"],["digits","1.2-2",3,"value"],[1,"or-table-cell","or-flex-fifth","text-truncate"],[1,"or-box","or-no-padding","or-min-width-0"],[1,"or-box-child","or-no-gap","or-box-no-wrap","or-h4","or-min-width-0"],[1,"or-box-child","or-min-width-0"],[4,"ngIf","ngIfElse"],[1,"or-box","or-no-padding"],[3,"innerHTML"],[1,"or-table-cell","or-flex-10","or-numeric","or-group-end"],[1,"or-table-cell","or-numeric","or-flex-10"],["digits","1.2-2","decorator","#%",3,"value"],[1,"or-min-width-0",3,"account","
1isBasket","quote"]],template:function(n,r){n&1&&(l(0,"div",1)(1,"div",2)(2,"div",3)(3,"div",4)(4,"div",5)(5,"div",6),c(6,"app-account-symbol-link",7),a(),v(7,kr,2,0,"div",8),a()()(),l(8,"div",9),p(9,"dict"),c(10,"app-detailed-quantity",10),a(),c(11,"div",11),v(12,Rr,1,0,"div",12),c(13,"div",13)(14,"div",14),v(15,Nr,1,0,"div",15)(16,Hr,1,0,"div",16)(17,Vr,1,0,"div",17),a(),v(18,jr,66,61,"div",18),a()),n&2&&(o("grouped",!0)("desktop",!0),i(6),o("position",r.position)("account",r.account)("isBasket",!0),i(),o("ngIf",r.position.basketDetail),i(),y("data-header",m(9,13,"orion.holdings.QUANTITY")),i(2),o("position",r.position),i(2),o("ngIf",r.userProfile.hasBookValueAccess),i(3),o("ngIf",r.userProfile.hasPNLAccess),i(),o("ngIf",r.userProfile.hasTypeAccess),i(),o("ngIf",r.userProfile.hasMinimalTradeAccess||r.holdingsService.hasTradeAccess(r.position.finInstrument)),i(),o("ngIf",r.position==null||r.position.basketDetail==null?null:r.position.basketDetail.basketDetailPositions))},dependencies:[F,T,Ee,Zt,te,k,ut,ri,Te,fe,w],styles:['@charset "UTF-8";.or-basket.or-group-collapsible[_ngcontent-%COMP%]   .or-table[_ngcontent-%COMP%]   .or-table-body[_ngcontent-%COMP%]{background-color:rgba(var(--bg_color_body_rgb),.5)}.or-table-row[_ngcontent-%COMP%]   .or-table-cell.or-grow-quantity[_ngcontent-%COMP%]{flex-grow:.5}.or-table-row[_ngcontent-%COMP%]   .or-table-cell.or-grow-avg-cost[_ngcontent-%COMP%]{flex-grow:.6}.or-table-row[_ngcontent-%COMP%]   .or-table-cell.or-grow-market-price[_ngcontent-%COMP%]{flex-grow:.7}.or-table-row[_ngcontent-%COMP%]   .or-table-cell.or-grow-market-value[_ngcontent-%COMP%]{flex-grow:.75}.or-table-row[_ngcontent-%COMP%]   .or-table-cell.or-grow-book-value[_ngcontent-%COMP%]{flex-grow:.5}.or-table-row[_ngcontent-%COMP%]   .or-table-cell.or-grow-unrealized-gain[_ngcontent-%COMP%]{flex-grow:.65}.or-table-row[_ngcontent-%COMP%]   .or-table-cell.or-grow-type[_ngcontent-%COMP%]{flex-grow:.2}.or-table-row[_ngcontent-%COMP%]   .or-table-cell.or-grow-trade-links[_ngcontent-%COMP%]{flex-grow:1}.or-min-width-0[_ngcontent-%COMP%]{min-width:0}'],changeDetection:0})}}return t})();function $r(t,s){if(t&1&&(l(0,"div",5)(1,"div",6),u(2),p(3,"dict"),a(),l(4,"div",7)(5,"div",8),u(6),p(7,"dict"),a(),c(8,"app-value-styler",9),a(),l(9,"div",7)(10,"div",8),u(11),p(12,"dict"),a(),c(13,"app-value-styler",4),a(),l(14,"div",7)(15,"div",8),u(16),p(17,"dict"),a(),c(18,"app-value-styler",10),a(),l(19,"div",7)(20,"div",11),u(21),p(22,"dict"),a(),c(23,"app-value-styler",12),a(),c(24,"br"),l(25,"div",13),u(26),p(27,"dict"),a()()),t&2){let e=d(2);i(2),h(m(3,10,"orion.holdings.LOAN_DETAILS")),i(4),h(m(7,12,"orion.holdings.LOAN_QUANTITY")),i(2),o("value",e.quantity),i(3),h(m(12,14,"orion.holdings.LOAN_PRICE")),i(2),o("value",e.price),i(3),h(m(17,16,"orion.holdings.LOAN_RATE_MAX")),i(2),o("value",e.loanRate),i(3),h(m(22,18,"orion.holdings.LOAN_VALUE")),i(2),o("value",e.loanValue),i(3),h(m(27,20,"orion.holdings.LOAN_CAUTION"))}}function qr(t,s){if(t&1&&(A(0),l(1,"a",3,0),c(3,"app-value-styler",4),a(),v(4,$r,28,22,"ng-template",null,1,P),I()),t&2){let e=E(5),n=d();i(),o("bncPopover",e),i(2),o("value",n.value)}}var ci=(()=>{class t{constructor(e){this.userInfoService=e}ngOnInit(){this.positionLastBusinessDay?this.initValueForLastBusinessDay():this.initValue()}initValueForLastBusinessDay(){this.quantity=this.positionLastBusinessDay.qty,this.price=this.positionLastBusinessDay.bidAskPrc,this.loanRate=this.convertToPercentage(this.positionLastBusinessDay.loanRate),this.loanValue=this.positionLastBusinessDay.loanVal}initValue(){this.quantity=this.position.prevQuantity,this.price=this.position.positionEval.bidAskPrc,this.loanRate=this.convertToPercentage(this.position.positionEval.loanRate),this.loanValue=this.position.positionEval.posMarginAmt}convertToPercentage(e){return Math.round(e*100)}static{this.\u0275fac=function(n){return new(n||t)(f(Ae))}}static{this.\u0275cmp=x({type:t,selectors:[["app-loan-value-detail"]],inputs:{position:"position",positionLastBusinessDay:"positionLastBusinessDay",value:"value"},standalone:!1,decls:1,vars:1,consts:[["popover","bncPopover"],["detailLoanValue",""],[4,"ngIf"],["href","javascript:void(0)","bncPopoverPosition","bottom","bncPopoverTrigger","click",1,"loan-link",3,"bncPopover"],["digits","1.2-2",3,"value"],["id","loan-value-detail-popover"],[1,"mc-fw-semi-bold","mc-fs-400","mc-lh-header","mc-pb-xsmall"],[1,"mc-d-flex","mc-justify-content-between"],[1,"mc-pr-large"],["digits","1.0-0",3,"value"],["decorator","#%",3,"value"],[1,"mc-fw-semi-bold"],["digits","1.2-2",1,"mc-fw-semi-bold",3,"value"],[1,"lg:mc-fs-300","mc-fs-200"]],template:function(n,r){n&1&&v(0,qr,6,2,"ng-container",2),n&2&&o("ngIf",r.position||r.positionLastBusinessDay)},dependencies:[T,de,k,w],styles:['@charset "UTF-8";.loan-link[_ngcontent-%COMP%]{color:#1677cb}.loan-link[_ngcontent-%COMP%]:hover, .loan-link[_ngcontent-%COMP%]   *[_ngcontent-%COMP%]:hover{text-decoration:none;color:#444}'],changeDetection:0})}}return t})();var zr=t=>({"or-opposite-currency-cursor":t}),Kr=(t,s)=>({canBuy:t,canSell:s});function Wr(t,s){t&1&&c(0,"div",25)}function Zr(t,s){if(t&1&&(l(0,"a",26)(1,"span",27),u(2),p(3,"dict"),a()()),t&2){let e=d(),n=E(34);o("appSortService",e.sort)("group",e.accountAssetsDetail.account.acctNo),i(),o("bncPopoverDisabled",!e.userProfile.isFbnOrGpUser)("bncPopover",n),i(),g(" ",m(3,5,"orion.holdings.BOOK_VALUE")," ")}}function Xr(t,s){if(t&1&&(l(0,"a",28),u(1),p(2,"dict"),a()),t&2){let e=d(),n=E(32);o("bncPopoverDisabled",!e.userProfile.isFbnOrGpUser)("bncPopover",n)("appSortService",e.sort)("group",e.accountAssetsDetail.account.acctNo),i(),g(" ",m(2,5,"orion.holdings.UNREALIZED_GAIN")," ")}}function Jr(t,s){if(t&1&&(l(0,"a",29),u(1),p(2,"dict"),a()),t&2){let e=d();o("appSortService",e.sort)("group",e.accountAssetsDetail.account.acctNo),i(),g(" ",m(2,3,"orion.holdings.LOAN_VALUE")," ")}}function ea(t,s){t&1&&c(0,"div",30)}function ta(t,s){if(t&1&&(l(0,"a",31),u(1," Type "),a()),t&2){let e=d();o("appSortService",e.sort)("group",e.accountAssetsDetail.account.acctNo)}}function ia(t,s){t&1&&c(0,"div",32)}
1function na(t,s){if(t&1){let e=V();l(0,"div")(1,"a",55),U("click",function(){N(e);let r=d(4);return H(r.onFplIconClicked())}),c(2,"app-bnc-icon",56),a()()}if(t&2){let e=d(4);i(2),o("key",e.BncIconKey.FinancialGrowthColor)("size",e.BncIconSize.MEDIUM_LEGACY)}}function oa(t,s){if(t&1&&(l(0,"div",53)(1,"app-tooltip",54),p(2,"dict"),v(3,na,3,2,"div",46),a()()),t&2){let e=d(2).$implicit;i(),o("textTooltip",m(2,2,"orion.holdings.FPL_TOOLTIP")),i(2),o("ngIf",e.lendingQty>0)}}function ra(t,s){if(t&1&&c(0,"app-detailed-quantity",57),t&2){let e=d(2).$implicit,n=d();o("position",e)("isShowLendingQty",n.isShowLendingQty)}}function aa(t,s){if(t&1&&(c(0,"div",43),p(1,"valueStyler")),t&2){let e=d(2).$implicit;o("innerHTML",D(1,1,e.quantity,"1.0-1"),S)}}function la(t,s){if(t&1&&(l(0,"div",58),p(1,"dict"),c(2,"div",43),p(3,"valueStyler"),a()),t&2){let e=d(2).$implicit,n=d();y("data-header",m(1,2,"orion.holdings.BOOK_VALUE")),i(2),o("innerHTML",n.securityLendingAccount?"-":D(3,4,e.positionEval.costAmt,"1.2-2"),S)}}function sa(t,s){t&1&&(l(0,"div"),u(1,"-"),a())}function ca(t,s){if(t&1&&(l(0,"div"),c(1,"app-value-styler",62),a()),t&2){let e=d(3).$implicit;i(),o("value",e.positionEval.dayChangeUnitPrice)("colored",!0)("small",!0)}}function pa(t,s){if(t&1&&(l(0,"div",63),c(1,"app-value-styler",64),a()),t&2){let e=d(3).$implicit;i(),o("value",e.positionEval.dayChangeUnitPricePerc)("colored",!0)("arrow",!0)("small",!0)}}function da(t,s){if(t&1&&(l(0,"div",59),c(1,"div",43),p(2,"valueStyler"),p(3,"priceFormatter"),l(4,"div",60),v(5,ca,2,3,"div",46)(6,pa,2,4,"div",61),a()()),t&2){d();let e=E(18),n=d().$implicit,r=d();o("bncPopover",e)("bncPopoverDisabled",!(!r.holdingsService.isInDisplayedCurrency(r.accountAssetsDetail.account.acctNo,n,r.currency)&&n.positionEval.evalPrice))("ngClass",ce(14,zr,!r.holdingsService.isInDisplayedCurrency(r.accountAssetsDetail.account.acctNo,n,r.currency)&&n.positionEval.evalPrice)),i(),o("innerHTML",r.holdingsService.isInDisplayedCurrency(r.accountAssetsDetail.account.acctNo,n,r.currency)?ji(3,9,n.positionEval.evalPrice,n.finInstrument.marketSymbol,void 0,n.finInstrument.finInstrumentTypeCd):D(2,6,n.positionEval.evalPrice,"1.5-5"),S),i(4),o("ngIf",n.positionEval.dayChangeInd&&n.positionEval.dayChangeUnitPrice),i(),o("ngIf",n.positionEval.dayChangeInd&&n.positionEval.dayChangeUnitPricePerc)}}function ma(t,s){if(t&1&&(l(0,"div",65),c(1,"app-value-styler",66),l(2,"div",67),u(3),a()()),t&2){let e,n=d(2).$implicit,r=d();i(),o("value",(e=r.holdingsService.getPositionInSymbolCurrency(r.accountAssetsDetail,n))==null?null:e.positionEval.evalPrice)("small",!0),i(2),h(n.finInstrument.marketSymbol.symbolCurrCd)}}function ua(t,s){t&1&&(l(0,"div"),u(1,"-"),a())}function va(t,s){if(t&1){let e=V();l(0,"div")(1,"a",70),U("click",function(){N(e);let r=d(4).$implicit,_=d();return H(_.openIntraDayChangeModal(r,_.accountAssetsDetail.account,_.holdingsService.getExchangeRate(_.accountAssetsDetailGroup,_.accountAssetsDetail)))}),c(2,"app-value-styler",71),a()()}if(t&2){let e=d(4).$implicit;i(2),o("value",e.positionEval.marketValueIntraDayChange.amtVariation)("colored",!0)("arrow",!0)("small",!0)("underlined",!0)}}function _a(t,s){if(t&1&&c(0,"app-value-styler",71),t&2){let e=d(4).$implicit;o("value",e.positionEval.marketValueIntraDayChange.amtVariation)("colored",!0)("arrow",!0)("small",!0)("underlined",!1)}}function ga(t,s){if(t&1&&(l(0,"div"),v(1,va,3,5,"div",69)(2,_a,1,5,"ng-template",null,3,P),a()),t&2){let e=E(3),n=d(3).$implicit,r=d();i(),o("ngIf",r.hasMinimumOneBuyOrSell(n.positionEval.marketValueIntraDayChange.intraDayChangeDetailList)&&r.userProfile.hasAccessToMarketValueDayChangeModal&&!r.mobile)("ngIfElse",e)}}function fa(t,s){if(t&1&&(l(0,"div",72)(1,"div",73)(2,"div",74),u(3),p(4,"dict"),a(),c(5,"app-value-styler",75),a()()),t&2){let e=d(3).$implicit;i(3),h(m(4,2,"orion.holdings.ACCRUED_INTEREST")),i(2),o("value",e.positionEval.accruedInterest)}}function ya(t,s){if(t&1&&(l(0,"div"),c(1,"div",43),p(2,"valueStyler"),v(3,ga,4,2,"div",46)(4,fa,6,4,"div",68),a()),t&2){let e=d(2).$implicit,n=d();i(),o("innerHTML",D(2,3,e.positionEval.marketValueAmt,"1.2-2"),S),i(2),o("ngIf",e.positionEval.dayChangeInd&&e.positionEval.marketValueIntraDayChange&&n.userProfile.hasAccessToHoldingsMarketValueDayChange),i(),o("ngIf",e.positionEval.accruedInterest)}}function ha(t,s){t&1&&(l(0,"div"),u(1,"-"),a())}function Ca(t,s){if(t&1&&(l(0,"div"),c(1,"app-value-styler",77),a()),t&2){let e=d(4).$implicit;i(),o("value",e.positionEval.pnlPerc)("colored",!0)("arrow",!0)("small",!0)}}function ba(t,s){if(t&1&&(l(0,"div"),c(1,"div",43),p(2,"valueStyler"),v(3,Ca,2,4,"div",46),a()),t&2){let e=d(3).$implicit;i(),o("innerHTML",Le(2,2,e.positionEval.pnlAmt,"1.2-2",!0),S),i(2),o("ngIf",e.positionEval.pnlPerc)}}function xa(t,s){if(t&1&&(l(0,"div",76),p(1,"dict"),v(2,ha,2,0,"div",46)(3,ba,4,6,"div",46),a()),t&2){let e=d(3);y("data-header",m(1,3,"orion.holdings.UNREALIZED_GAIN")),i(2),o("ngIf",e.securityLendingAccount),i(),o("ngIf",!e.securityLendingAccount)}}function Sa(t,s){t&1&&(l(0,"div"),u(1,"-"),a())}function Aa(t,s){if(t&1&&c(0,"app-loan-value-detail",80),t&2){let e=d(4).$implicit;o("position",e)("value",e.positionEval.posMarginAmt)}}function Ia(t,s){if(t&1&&c(0,"app-value-styler",81),t&2){let e=d(4).$implicit;o("value",e.positionEval.posMarginAmt)}}function Ta(t,s){if(t&1&&(A(0),v(1,Aa,1,2,"app-loan-value-detail",79)(2,Ia,1,1,"ng-template",null,4,P),I()),t&2){let e=E(3),n=d(4);i(),o("ngIf",n.userInfoService.isRep)("ngIfElse",e)}}function Ea(t,s){if(t&1&&(l(0,"div",78),p(1,"dict"),v(2,Sa,2,0,"div",46)(3,Ta,4,2,"ng-container",46),a()),t&2){let e=d(3);z("or-mobile-hide",!e.accountAssetsDetail.account.marginInd),y("data-header",m(1,5,"orion.holdings.LOAN_VALUE")),i(2),o("ngIf",e.accountAssetsDetail.account.marginInd&&e.securityLendingAccount),i(),o("ngIf",e.accountAssetsDetail.account.marginInd&&!e.securityLendingAccount)}}function Pa(t,s){if(t&1&&(l(0,"div",82),c(1,"span",43),a()),t&2){let e=d(2).$implicit,n=d();y("data-header","Type"),i(),o("innerHTML",n.securityLendingAccount?"-":e.finInstrument.finInstrumentCatLabel,S)}}function Da(t,s){if(t&1){let e=V();l(0,"div",83)(1,"div",84)(2,"app-trade-links",85),U("buttonPressed",function(r){N(e);let _=d(3);return H(_.onTradeButtonPressed(r))}),a()()()}if(t&2){let e=d(2).$implicit,n=d();i(2),o("finInstrument",e.finInstrument)("acctNo",n.accountAssetsDetail.account.acctNo)("quantity",e.quantity)("access",
1se(4,Kr,!n.isOfferingAccounts&&e.tradeAccess.buyAllowed,!n.isOfferingAccounts&&e.tradeAccess.sellAllowed))}}function wa(t,s){if(t&1&&(l(0,"div",35)(1,"div",36),c(2,"app-account-symbol-link",37),a(),v(3,oa,4,4,"div",38),l(4,"div",39),p(5,"dict"),v(6,ra,1,2,"app-detailed-quantity",40)(7,aa,2,4,"div",41),a(),l(8,"div",42),p(9,"dict"),c(10,"div",43),p(11,"valueStyler"),a(),v(12,la,4,7,"div",44),l(13,"div",45),p(14,"dict"),v(15,sa,2,0,"div",46)(16,da,7,16,"div",47)(17,ma,4,3,"ng-template",null,2,P),a(),l(19,"div",48),p(20,"dict"),v(21,ua,2,0,"div",46)(22,ya,5,6,"div",46),a(),v(23,xa,4,5,"div",49)(24,Ea,4,7,"div",50)(25,Pa,2,2,"div",51)(26,Da,3,7,"div",52),a()),t&2){let e=d().$implicit,n=d();i(2),o("position",e)("account",n.accountAssetsDetail.account)("symbolStyle",n.mobile?"or-font-12":null),i(),o("ngIf",n.isActivateFPLOnAllAccounts),i(),z("or-colored-link",!n.securityLendingAccount)("underlined",e.execQty&&e.execQty!==0),y("data-header",m(5,24,"orion.holdings.QUANTITY")),i(2),o("ngIf",!n.securityLendingAccount),i(),o("ngIf",n.securityLendingAccount),i(),y("data-header",m(9,26,"orion.holdings.AVERAGE_COST")),i(2),o("innerHTML",n.securityLendingAccount?"-":D(11,28,e.positionEval.avgCostPrice,"1.2-5"),S),i(2),o("ngIf",n.userProfile.hasBookValueAccess),i(),y("data-header",m(14,31,"orion.holdings.MARKET_PRICE")),i(2),o("ngIf",n.securityLendingAccount),i(),o("ngIf",!n.securityLendingAccount),i(3),y("data-header",m(20,33,"orion.holdings.MARKET_VALUE")),i(2),o("ngIf",n.securityLendingAccount),i(),o("ngIf",!n.securityLendingAccount),i(),o("ngIf",n.userProfile.hasPNLAccess),i(),o("ngIf",n.userProfile.hasAccessToPortfolioLoanValue),i(),o("ngIf",n.userProfile.hasTypeAccess),i(),o("ngIf",n.userProfile.hasMinimalTradeAccess||n.holdingsService.hasTradeAccess(e.finInstrument))}}function La(t,s){if(t&1&&c(0,"app-basket",86),t&2){let e=d().$implicit,n=d();o("position",e)("account",n.accountAssetsDetail.account)}}function Oa(t,s){if(t&1&&(l(0,"div"),v(1,wa,27,35,"div",33)(2,La,1,2,"app-basket",34),a()),t&2){let e=s.$implicit;i(),o("ngIf",!e.basket),i(),o("ngIf",e.basket)}}function Ba(t,s){t&1&&c(0,"div",25)}function Ma(t,s){if(t&1&&(l(0,"div",101),p(1,"dict"),c(2,"div",96),p(3,"valueStyler"),a()),t&2){let e=d(2);y("data-header",m(1,2,"orion.holdings.BOOK_VALUE")),i(2),o("innerHtml",D(3,4,e.assetsDetail.positionEvalSummary.costAmt,"1.2-2"),S)}}function ka(t,s){if(t&1&&(l(0,"div"),c(1,"app-value-styler",102),a()),t&2){let e=d(2);i(),o("value",e.assetsDetail.positionEvalSummary.dayChangeMarketAmt)("textAlign","right")("colored",!0)("arrow",!0)("small",!0)}}function Ra(t,s){if(t&1&&(l(0,"div"),c(1,"app-value-styler",77),a()),t&2){let e=d(3);i(),o("value",e.assetsDetail.positionEvalSummary.pnlPerc)("colored",!0)("arrow",!0)("small",!0)}}function Na(t,s){if(t&1&&(l(0,"div",103),p(1,"dict"),l(2,"div"),c(3,"div",96),p(4,"valueStyler"),v(5,Ra,2,4,"div",46),a()()),t&2){let e=d(2);y("data-header",m(1,3,"orion.holdings.UNREALIZED_GAIN")),i(3),o("innerHtml",Le(4,5,e.assetsDetail.positionEvalSummary.pnlAmt,"1.2-2",!0),S),i(2),o("ngIf",e.assetsDetail.positionEvalSummary.pnlPerc)}}function Ha(t,s){if(t&1&&c(0,"app-value-styler",81),t&2){let e=d(3);o("value",e.assetsDetail.positionEvalSummary.posMarginAmt)}}function Va(t,s){if(t&1&&(l(0,"div",104),v(1,Ha,1,1,"app-value-styler",105),a()),t&2){let e=d(2);z("or-mobile-hide",!e.accountAssetsDetail.account.marginInd),i(),o("ngIf",e.accountAssetsDetail.account.marginInd)}}function Ua(t,s){t&1&&c(0,"div",106)}function Fa(t,s){t&1&&c(0,"div",107)}function Ga(t,s){if(t&1&&(l(0,"div",87)(1,"div",88)(2,"div",89),u(3),p(4,"dict"),l(5,"app-tooltip",90),p(6,"dict"),u(7),a()()(),v(8,Ba,1,0,"div",9),c(9,"div",91),l(10,"div",92),u(11,"\xA0"),a(),v(12,Ma,4,7,"div",93),c(13,"div",94),l(14,"div",95),p(15,"dict"),l(16,"div"),c(17,"div",96),p(18,"valueStyler"),v(19,ka,2,5,"div",46),a()(),v(20,Na,6,9,"div",97)(21,Va,2,3,"div",98)(22,Ua,1,0,"div",99)(23,Fa,1,0,"div",100),a()),t&2){let e=d();i(3),g(" ",m(4,12,"orion.holdings.TOTAL")," "),i(2),o("textTooltip",m(6,14,"orion.app."+e.currency)),i(2),g(" ",e.currency," "),i(),o("ngIf",e.isActivateFPLOnAllAccounts),i(4),o("ngIf",e.userProfile.hasBookValueAccess),i(2),y("data-header",m(15,16,"orion.holdings.MARKET_VALUE")),i(3),o("innerHtml",D(18,18,e.assetsDetail.positionEvalSummary.marketValueAmt,"1.2-2"),S),i(2),o("ngIf",e.assetsDetail.positionEvalSummary.dayChangeMarketAmt&&e.assetsDetail.positionEvalSummary.dayChangeInd&&e.userProfile.hasAccessToHoldingsMarketValueDayChange),i(),o("ngIf",e.userProfile.hasPNLAccess),i(),o("ngIf",e.userProfile.hasAccessToPortfolioLoanValue),i(),o("ngIf",e.userProfile.hasTypeAccess),i(),o("ngIf",e.userProfile.hasMinimalTradeAccess)}}
1function ja(t,s){t&1&&(u(0),p(1,"dict")),t&2&&g(" ",m(1,1,"orion.holdings.MESSAGE_UNREALIZED_GAIN_LOSS"),`
2`)}function Qa(t,s){t&1&&(u(0),p(1,"dict")),t&2&&g(" ",m(1,1,"orion.holdings.TEXT_TOOLTIP_BOOK_VALUE"),`
3`)}var fo=(()=>{class t extends Q{constructor(e,n,r,_,C,b,M,ue,je,Qe){super(),this.userProfile=e,this.sort=n,this.holdingsService=r,this.searchBarRepService=_,this.dialog=C,this.breakpointObserver=b,this.store$=M,this.userInfoService=ue,this.featureFlagsService=je,this.router=Qe,this.mobile=!1,this.BncIconSize=Nt,this.BncIconKey=ot,this.isActivateFPLOnAllAccounts=this.featureFlagsService.isEnabled("fpl",Be)}ngOnChanges(){this.assetsDetail=this.holdingsService.getAssetsDetail(this.accountAssetsDetail),this.isOfferingAccounts=this.accountAssetsDetail?.account?.acctType===cn,this.isShowLendingQty=this.isActivateFPLOnAllAccounts?this.accountAssetsDetail?.account?.acctClassCd===yt||pn.includes(this.accountAssetsDetail?.account?.acctNo?.slice(-1)):this.accountAssetsDetail?.account?.acctClassCd!==yt}ngOnInit(){this.sort.setOrderBy("finInstrument.displayDesc",this.accountAssetsDetail.account.acctNo,"orderBy"),this.store$.pipe(R(Pe,Z.ACCOUNTS_HOLDINGS),W(this.destroyed$)).subscribe(e=>this.lastRefreshDate=e),this.breakpointObserver.observe([re.MOBILE]).pipe(W(this.destroyed$)).subscribe(e=>{this.mobile=e.matches})}hasMinimumOneBuyOrSell(e){return e&&e.length&&e.some(n=>n.type===dt.BUY||n.type===dt.SELL)}openIntraDayChangeModal(e,n,r){let _={data:{position:e,account:n,currency:this.currency,lastRefreshDate:this.lastRefreshDate,exchangeRate:r},disableClose:!0,maxWidth:"100vw"};this.dialog.open(co,_)}trackByPosition(e,n){return n.finInstrument.finInstrumentId}onTradeButtonPressed(e){e==="BUY"?Ci.addAction(bi.PRESSED_ACCOUNT_HOLDING_BUY_BUTTON):e==="SELL"&&Ci.addAction(bi.PRESSED_ACCOUNT_HOLDING_SELL_BUTTON)}onFplIconClicked(){this.router.navigate(["/fpl"],{queryParamsHandling:"merge"})}static{this.\u0275fac=function(n){return new(n||t)(f(O),f($),f(K),f(pt),f(en),f(ae),f(j),f(Ae),f(Se),f(pe))}}static{this.\u0275cmp=x({type:t,selectors:[["app-holdings-assets-detail"]],inputs:{currency:"currency",accountAssetsDetail:"accountAssetsDetail",accountAssetsDetailGroup:"accountAssetsDetailGroup",securityLendingAccount:"securityLendingAccount"},standalone:!1,features:[q,Je],decls:35,vars:44,consts:[["UnrealizedGainLoss",""],["PopupOverBookValue",""],["oppositeCurrency",""],["displayNonClickableMktValueDayChange",""],["normalLoanValue",""],[1,"or-table"],[1,"or-table-body","or-group-collapsible"],["appSticky","",1,"or-table-row","or-table-header","top-0",3,"offsetTop"],["href","javascript:void(0)","key","finInstrument.marketSymbol.symbolCd",1,"or-table-cell","or-grow-symbol",3,"appSortService","group"],["class","fpl-cell",4,"ngIf"],["href","javascript:void(0)","key","quantity",1,"or-table-cell","or-numeric","or-grow-quantity",3,"appSortService","group"],["href","javascript:void(0)","key","positionEval.avgCostPrice",1,"or-table-cell","or-numeric","or-grow-avg-cost",3,"appSortService","group"],["href","javascript:void(0)","class","or-table-cell or-numeric or-grow-book-value","key","positionEval.costAmt",3,"appSortService","group",4,"ngIf"],["href","javascript:void(0)","key","positionEval.evalPrice",1,"or-table-cell","or-numeric","or-grow-market-price",3,"appSortService","group"],["href","javascript:void(0)","key","positionEval.marketValueAmt",1,"or-table-cell","or-numeric","or-grow-market-value",3,"appSortService","group"],[3,"textTooltip","disabledTooltip"],["class","or-table-cell or-numeric or-grow-unrealized-gain","bncPopoverTrigger","hover","href","javascript:void(0)","key","positionEval.pnlAmt",3,"bncPopoverDisabled","bncPopover","appSortService","group",4,"ngIf"],["href","javascript:void(0)","class","or-table-cell or-grow-loan or-numeric","key","positionEval.posMarginAmt",3,"appSortService","group",4,"ngIf"],["class","or-table-cell or-grow-loan or-numeric",4,"ngIf"],["href","javascript:void(0)","class","or-table-cell or-grow-type or-center","key","finInstrument.finInstrumentCatLabel",3,"appSortService","group",4,"ngIf"],["class","or-table-cell or-grow-trade-links",4,"ngIf"],[4,"ngFor","ngForOf"],["class","or-table-row or-table-footer","appCollapsible","",4,"ngIf"],["id","UnrealizedGainLoss"],["id","PopupOverBookValue"],[1,"fpl-cell"],["href","javascript:void(0)","key","positionEval.costAmt",1,"or-table-cell","or-numeric","or-grow-book-value",3,"appSortService","group"],["bncPopoverTrigger","hover",3,"bncPopoverDisabled","bncPopover"],["bncPopoverTrigger","hover","href","javascript:void(0)","key","positionEval.pnlAmt",1,"or-table-cell","or-numeric","or-grow-unrealized-gain",3,"bncPopoverDisabled","bncPopover","appSortService","group"],["href","javascript:void(0)","key","positionEval.posMarginAmt",1,"or-table-cell","or-grow-loan","or-numeric",3,"appSortService","group"],[1,"or-table-cell","or-grow-loan","or-numeric"],["href","javascript:void(0)","key","finInstrument.finInstrumentCatLabel",1,"or-table-cell","or-grow-type","or-center",3,"appSortService","group"],[1,"or-table-cell","or-grow-trade-links"],["class","or-table-row","appCollapsible","",4,"ngIf"],[3,"position","account",4,"ngIf"],["appCollapsible","",1,"or-table-row"],[1,"or-table-cell","or-grow-symbol","or-position-1","text-truncate"],[1,"text-truncate",3,"position","account","symbolStyle"],["class","fpl-cell or-table-cell mc-justify-content-center md:mc-justify-content-end or-position-9 or-collapsible",4,"ngIf"],[1,"or-table-cell","or-numeric","or-position-4","or-collapsible","or-grow-quantity"],[3,"position","isShowLendingQty",4,"ngIf"],[3,"innerHTML",4,"ngIf"],[1,"or-table-cell","or-position-6","or-numeric","or-collapsible","or-grow-avg-cost"],[3,"innerHTML"],["class","or-table-cell or-numeric or-position-7 or-collapsible or-grow-book-value",4,"ngIf"],[1,"or-table-cell","or-numeric","or-position-2","or-grow-market-price"],[4,"ngIf"],["bncPopoverTrigger","hover",3,"bncPopover","bncPopoverDisabled","ngClass",4,"ngIf"],[1,"or-table-cell","or-numeric","or-position-5","or-collapsible","or-grow-market-value"],["class","or-table-cell or-position-8 or-numeric or-collapsible or-grow-unrealized-gain",4,"ngIf"],["class","or-table-cell or-numeric or-position-9 or-collapsible or-grow-loan",3,"or-mobile-hide",4,"ngIf"],["class","or-table-cell or-position-10 or-collapsible or-grow-type or-center",4,"ngIf"],["class","or-table-cell or-position-11 or-collapsible or-grow-trade-links or-right or-flex-full",4,"ngIf"],[1,"fpl-cell","or-table-cell","mc-justify-content-center","md:mc-justify-content-end","or-position-9","or-collapsible"],[3,"textTooltip"],[1,"mc-d-flex","mc-align-items-center","mc-justify-content-center","mc-bc-electric-blue","fpl-icon","mc-b-solid","mc-bs-small",3,"click"],[3,"key","size"],[3,"position","isShowLendingQty"],[1,"or-table-cell","or-numeric","or-position-7","or-collapsible","or-grow-book-value"],["bncPopoverTrigger","hover",3,"bncPopover","bncPopoverDisabled","ngClass"],[1,"d-flex","flex-nowrap"],["class","pl-1",4,"ngIf"],["digits","1.3-5",3,"value","colored","small"],[1,"pl-1"],["digits","1.2-2","decorator","(#%)",3,"value","colored","arrow","small"],[1,"d-flex","flex-nowrap","align-items-center"],["digits","1.2-2","defaultVal","",3,"value","small"],[1,"or-small-text","pl-1"],["class","or-box or-no-padding",4,"ngIf"],[4,"ngIf","ngIfElse"],["href","javascript:void(0)",3,"click"],["digits","1.2-2",3,"value","colored","arrow","small","underlined"],[1,"or-box","or-no-padding"],[1,"or-box-child","or-no-padding","or-small-gap"],[1,"or-label_small"],["digits","1.2-2",1,"or-label_small",3,"value"],[1,"or-table-cell","or-position-8","or-numeric","or-collapsible","or-grow-unrealized-gain"],["digits","1.2-2","decorator","#%",3,"value","colored","arrow","small"],[1,"or-table-cell","or-numeric","or-position-9","or-collapsible","or-grow-loan"],[3,"position","value",4,"ngIf","ngIfElse"],[3,"position","value"],["digits","1.2-2",3,"value"],[1,"or-table-cell","or-position-10","or-collapsible","or-grow-type","or-center"],[1,"or-table-cell","or-position-11","or-collapsible","or-grow-trade-links","or-right","or-flex-full"],[1,"or-box","or-no-padding","or-box-content-center"],[3,"buttonPressed","finInstrument","acctNo","quantity","access"],[3,"position","account"],["appCollapsible","",1,"or-table-row","or-table-footer"],[1,"or-table-cell","or-grow-symbol","or-position-1"],[1,"or-h4"],[1,"d-inline-flex",3,"textTooltip"],[1,"or-table-cell","or-numeric","or-collapsible","or-grow-quantity","or-position-5"],[1,"or-table-cell","or-numeric","or-collapsible","or-grow-avg-cost","or-position-6"],["class","or-table-cell or-numeric or-collapsible or-grow-book-value or-position-3",4,"ngIf"],[1,"or-table-cell","or-numeric","or-collapsible","or-grow-market-price","or-position-7"],[1,"or-table-cell","or-numeric","or-grow-market-value","or-position-2"],[3,"innerHtml"],["class","or-table-cell or-numeric or-collapsible or-grow-unrealized-gain or-position-8",4,"ngIf"],["class","or-table-cell or-numeric or-collapsible or-grow-loan or-position-9",3,"or-mobile-hide",4,"ngIf"],["class","or-table-cell or-numeric or-collapsible or-grow-type or-center or-position-10",4,"ngIf"],["class","or-table-cell or-numeric or-collapsible or-position-10 or-grow-trade-links",4,"ngIf"],[1,"or-table-cell","or-numeric","or-collapsible","or-grow-book-value","or-position-3"],["digits","1.2-2",3,"value","textAlign","colored","arrow","small"],[1,"or-table-cell","or-numeric","or-collapsible","or-grow-unrealized-gain","or-position-8"],[1,"or-table-cell","or-numeric","or-collapsible","or-grow-loan","or-position-9"],["digits","1.2-2",3,"value",4,"ngIf"],[1,"or-table-cell","or-numeric","or-collapsible","or-grow-type","or-center","or-position-10"],[1,"or-table-cell","or-numeric","or-collapsible","or-position-10","or-grow-trade-links"]],template:function(n,r){n&1&&(l(0,"div",5)(1,"div",6)(2,"div",7),p(3,"async"),l(4,"a",8),u(5),p(6,"dict"),a(),v(7,Wr,1,0,"div",9),l(8,"a",10),u(9),p(10,"dict"),a(),l(11,"a",11),u(12),p(13,"dict"),a(),v(14,Zr,4,7,"a",12),l(15,"a",13),u(16),p(17,"dict"),a(),l(18,"a",14)(19,"app-tooltip",15),p(20,"dict"),u(21),p(22,"dict"),a()(),v(23,Xr,3,7,"a",16)(24,Jr,3,5,"a",17)(25,ea,1,0,"div",18)(26,ta,2,2,"a",19)(27,ia,1,0,"div",20),a(),v(28,Oa,3,2,"div",21),p(29,"orderBy"),v(30,Ga,24,21,"div",22),a()(),v(31,ja,2,3,"ng-template",23,0,P)(33,Qa,2,3,"ng-template",24,1,P)),n&2&&(i(2),o("offsetTop",m(3,27,r.searchBarRepService.searchBarHeight$)),i(2),o("appSortService",r.sort)("group",r.accountAssetsDetail.account.acctNo),i(),g(" ",m(6,29,"orion.holdings.SYMBOL")," "),i(2),o("ngIf",r.isActivateFPLOnAllAccounts),i(),o("appSortService",r.sort)("group",r.accountAssetsDetail.account.acctNo),i(),g(" ",m(10,31,"orion.holdings.QUANTITY")," "),i(2),o("appSortService",r.sort)("group",r.accountAssetsDetail.account.acctNo),i(),g(" ",m(13,33,"orion.holdings.AVERAGE_COST")," "),i(2),o("ngIf",r.userProfile.hasBookValueAccess),i(),o("appSortService",r.sort)("group",r.accountAssetsDetail.account.acctNo),i(),g(" ",m(17,35,"orion.holdings.MARKET_PRICE")," "),i(2),o("appSortService",r.sort)("group",r.accountAssetsDetail.account.acctNo),i(),o("textTooltip",m(20,37,"orion.holdings.TEXT_TOOLTIP_MARKET_VALUE"))("disabledTooltip",!r.userProfile.hasAccessToHoldingsMarketValueDayChange),i(2),g(" ",m(22,39,"orion.holdings.MARKET_VALUE")," "),i(2),o("ngIf",r.userProfile.hasPNLAccess),i(),o("ngIf",r.userProfile.hasAccessToPortfolioLoanValue&&r.accountAssetsDetail.account.marginInd),i(),o("ngIf",r.userProfile.hasAccessToPortfolioLoanValue&&!r.accountAssetsDetail.account.marginInd),i(),o("ngIf",r.userProfile.hasTypeAccess),i(),o("ngIf",r.userProfile.hasMinimalTradeAccess),i(),o("ngForOf",D(29,41,r.assetsDetail.positionList,r.sort.orderBy(r.accountAssetsDetail.account.acctNo))),i(2),o("ngIf",r.assetsDetail.positionEvalSummary&&!r.securityLendingAccount))},dependencies:[X,F,T,de,Ee,Jt,te,k,st,Ne,an,ut,uo,ri,ci,G,Te,fe,w,Nn],styles:['@charset "UTF-8";.or-table-cell.or-grow-symbol[_ngcontent-%COMP%]{flex-grow:1.1!important}.or-table-cell.or-grow-quantity[_ngcontent-%COMP%]{flex-grow:.5!important}.or-table-cell.or-grow-market-price[_ngcontent-%COMP%]{flex-grow:.7!important}.or-table-cell.or-grow-market-value[_ngcontent-%COMP%]{flex-grow:.75!important}.or-table-cell.or-grow-avg-cost[_ngcontent-%COMP%]{flex-grow:.6!important}.or-table-cell.or-grow-book-value[_ngcontent-%COMP%]{flex-grow:.5!important}.or-table-cell.or-grow-unrealized-gain[_ngcontent-%COMP%]{flex-grow:.65!important}.or-table-cell.or-grow-loan[_ngcontent-%COMP%]{flex-grow:.55!important}.or-grow-type[_ngcontent-%COMP%]{min-width:45px;flex-grow:0!important}.or-grow-trade-links[_ngcontent-%COMP%]{min-width:170px!important;flex-grow:1!important}@media(min-width:960px)and (max-width:1200px){.or-grow-trade-links[_ngcontent-%COMP%]{min-width:83px}}.or-opposite-currency-cursor[_ngcontent-%COMP%]{cursor:pointer}@media print{.top-0[_ngcontent-%COMP%]{top:0!important}}@media screen and (max-width:959px){.or-table[_ngcontent-%COMP%]   .or-table-body[_ngcontent-%COMP%]   .or-table-row[_ngcontent-%COMP%]   .or-table-cell[_ngcontent-%COMP%]:before{font-size:.875rem}.or-table[_ngcontent-%COMP%]   .or-table-body[_ngcontent-%COMP%]   .or-table-row[_ngcontent-%COMP%]   .or-table-cell[_ngcontent-%COMP%]{font-size:1rem}}',".fpl-cell[_ngcontent-%COMP%]{width:32px!important;flex-grow:.5!important}.fpl-icon[_ngcontent-%COMP%]{border-radius:50%;width:28px;height:28px}@media screen and (max-width:959px){.fpl-icon[_ngcontent-%COMP%]{width:32px;height:32px}}"],changeDetection:0})}}return t})();function qa(t,s){if(t&1&&(l(0,"div",31)(1,"span",32),u(2),p(3,"dict"),a()()),t&2){let e=d(2),n=E(5);i(),o("bncPopoverDisabled",!e.userProfile.isFbnOrGpUser)("bncPopover",n),i(),g(" ",m(3,3,"orion.holdings.BOOK_VALUE")," ")}}function Ya(t,s){if(t&1&&(l(0,"div",33)(1,"div",32)(2,"div"),u(3),p(4,"dict"),a()()()),t&2){let e=d(2),n=E(3);i(),o("bncPopoverDisabled",!e.userProfile.isFbnOrGpUser)("bncPopover",n),i(2),g(" ",m(4,3,"orion.holdings.UNREALIZED_GAIN")," ")}}function za(t,s){t&1&&c(0,"div",34)}function Ka(t,s){t&1&&c(0,"div",35)}function Wa(t,s){t&1&&c(0,"div",36)}function Za(t,s){if(t&1&&(l(0,"div"),c(1,"app-value-styler",37),a()),t&2){let e=d(2);i(),o("value",e.accountAssetsDetailGroup.positionEvalSummaryList.CAD.dayChangeMarketAmt)("colored",!0)("arrow",!0)("small",!0)}}function Xa(t,s){if(t&1&&(l(0,"div"),c(1,"app-value-styler",39),a()),t&2){let e=d(3);i(),o("value",e.accountAssetsDetailGroup.positionEvalSummaryList.CAD.pnlPerc)("colored",!0)("arrow",!0)("small",!0)}}function Ja(t,s){if(t&1&&(l(0,"div",38),p(1,"dict"),l(2,"div"),c(3,"div",24),p(4,"valueStyler"),v(5,Xa,2,4,"div",2),a()()),t&2){let e=d(2);y("data-header",m(1,3,"orion.holdings.UNREALIZED_GAIN")),i(3),o("innerHtml",Le(4,5,e.accountAssetsDetailGroup.positionEvalSummaryList.CAD.pnlAmt,"1.2-2",!0),S),i(2),o("ngIf",e.accountAssetsDetailGroup.positionEvalSummaryList.CAD.pnlPerc)}}function el(t,s){t&1&&c(0,"div",40)}function tl(t,s){t&1&&c(0,"div",41)}function il(t,s){t&1&&c(0,"div",42)}function nl(t,s){if(t&1&&(A(0),c(1,"app-bnc-block-separator",4),l(2,"div",5)(3,"div",6)(4,"div",7),c(5,"div",8)(6,"div",9)(7,"div",10),v(8,qa,4,5,"div",11),c(9,"div",12),l(10,"div",13)(11,"div")(12,"div"),u(13),p(14,"dict"),a()()(),v(15,Ya,5,5,"div",14)(16,za,1,0,"div",15)(17,Ka,1,0,"div",16)(18,Wa,1,0,"div",17),a(),l(19,"div",18)(20,"div",19)(21,"div",20),u(22),p(23,"dict"),a()(),c(24,"div",21)(25,"div",22),l(26,"div",23),p(27,"dict"),c(28,"div",24),p(29,"valueStyler"),a(),c(30,"div",25),l(31,"div",26),p(32,"dict"),l(33,"div"),c(34,"div",24),p(35,"valueStyler"),v(36,Za,2,4,"div",2),a()(),v(37,Ja,6,9,"div",27)(38,el,1,0,"div",28)(39,tl,1,0,"div",29)(40,il,1,0,"div",30),a()()(),I()),t&2){let e=d();i(),o("height",8),i(7),o("ngIf",e.userProfile.hasBookValueAccess),i(5),g(" ",m(14,17,"orion.holdings.MARKET_VALUE")," "),i(2),o("ngIf",e.userProfile.hasPNLAccess),i(),o("ngIf",e.userProfile.hasAccessToPortfolioTotalMargin),i(),o("ngIf",e.userProfile.hasTypeAccess),i(),o("ngIf",e.userProfile.hasMinimalTradeAccess),i(4),h(m(23,19,"orion.holdings.GRAND_TOTAL")),i(4),y("data-header",m(27,21,"orion.holdings.AVERAGE_COST")),i(2),o("innerHtml",D(29,23,e.accountAssetsDetailGroup.positionEvalSummaryList.CAD.costAmt,"1.2-2"),S),i(3),y("data-header",m(32,26,"orion.holdings.MARKET_VALUE")),i(3),o("innerHtml",D(35,28,e.accountAssetsDetailGroup.positionEvalSummar
3yList.CAD.marketValueAmt,"1.2-2"),S),i(2),o("ngIf",e.accountAssetsDetailGroup.positionEvalSummaryList.CAD.dayChangeInd&&e.userProfile.hasAccessToHoldingsMarketValueDayChange),i(),o("ngIf",e.userProfile.hasPNLAccess),i(),o("ngIf",e.userProfile.hasAccessToPortfolioTotalMargin),i(),o("ngIf",e.userProfile.hasTypeAccess),i(),o("ngIf",e.userProfile.hasMinimalTradeAccess)}}function ol(t,s){if(t&1){let e=V();l(0,"app-export-link",43),p(1,"async"),p(2,"dict"),p(3,"dict"),U("exportParams",function(r){N(e);let _=d();return H(_.holdingsService.export(r))}),a()}if(t&2){let e=d();o("filenamePrefix",m(2,5,m(1,3,e.holdingsService.defaultPrefix$)))("dateFormatChoice",!1)("warningText",m(3,7,"orion.export.CURRENCY_WARNING"))}}function rl(t,s){t&1&&(u(0),p(1,"dict")),t&2&&g(" ",m(1,1,"orion.holdings.MESSAGE_UNREALIZED_GAIN_LOSS"),`
4`)}function al(t,s){t&1&&(u(0),p(1,"dict")),t&2&&g(" ",m(1,1,"orion.holdings.TEXT_TOOLTIP_BOOK_VALUE"),`
5`)}var ho=(()=>{class t{constructor(e,n){this.userProfile=e,this.holdingsService=n}static{this.\u0275fac=function(n){return new(n||t)(f(O),f(K))}}static{this.\u0275cmp=x({type:t,selectors:[["app-holdings-assets-detail-group"]],inputs:{currency:"currency",accountAssetsDetailGroup:"accountAssetsDetailGroup"},standalone:!1,decls:6,vars:2,consts:[["UnrealizedGainLoss",""],["PopupOverBookValue",""],[4,"ngIf"],[3,"filenamePrefix","dateFormatChoice","warningText","exportParams",4,"ngIf"],[3,"height"],[1,"or-table"],[1,"or-table-body"],[1,"or-table-row","or-table-header"],[1,"or-table-cell","or-grow-symbol"],[1,"or-table-cell","or-numeric","or-grow-quantity"],[1,"or-table-cell","or-numeric","or-grow-avg-cost"],["class","or-table-cell or-numeric or-grow-book-value",4,"ngIf"],[1,"or-table-cell","or-numeric","or-grow-market-price"],[1,"or-table-cell","or-numeric","or-grow-market-value"],["class","or-table-cell or-numeric or-grow-unrealized-gain",4,"ngIf"],["class","or-table-cell or-numeric or-grow-loan",4,"ngIf"],["class","or-table-cell or-grow-type or-center",4,"ngIf"],["class","or-table-cell or-grow-trade-links",4,"ngIf"],["appCollapsible","",1,"or-table-row","or-table-footer"],[1,"or-table-cell","or-grow-symbol","or-position-1"],[1,"or-h4"],[1,"or-table-cell","or-grow-quantity","or-numeric","or-mobile-hide"],[1,"or-table-cell","or-numeric","or-grow-avg-cost","or-mobile-hide"],[1,"or-table-cell","or-numeric","or-collapsible","or-grow-book-value","or-position-2"],[3,"innerHtml"],[1,"or-table-cell","or-grow-market-price","or-numeric","or-mobile-hide"],[1,"or-table-cell","or-numeric","or-grow-market-value","or-position-3"],["class","or-table-cell or-numeric or-collapsible or-grow-unrealized-gain or-position-4",4,"ngIf"],["class","or-table-cell or-numeric or-grow-loan or-mobile-hide",4,"ngIf"],["class","or-table-cell or-numeric or-grow-type or-center or-mobile-hide",4,"ngIf"],["class","or-table-cell or-numeric or-grow-trade-links or-mobile-hide",4,"ngIf"],[1,"or-table-cell","or-numeric","or-grow-book-value"],["bncPopoverTrigger","hover",3,"bncPopoverDisabled","bncPopover"],[1,"or-table-cell","or-numeric","or-grow-unrealized-gain"],[1,"or-table-cell","or-numeric","or-grow-loan"],[1,"or-table-cell","or-grow-type","or-center"],[1,"or-table-cell","or-grow-trade-links"],["digits","1.2-2",3,"value","colored","arrow","small"],[1,"or-table-cell","or-numeric","or-collapsible","or-grow-unrealized-gain","or-position-4"],["digits","1.2-2","decorator","#%",3,"value","colored","arrow","small"],[1,"or-table-cell","or-numeric","or-grow-loan","or-mobile-hide"],[1,"or-table-cell","or-numeric","or-grow-type","or-center","or-mobile-hide"],[1,"or-table-cell","or-numeric","or-grow-trade-links","or-mobile-hide"],[3,"exportParams","filenamePrefix","dateFormatChoice","warningText"]],template:function(n,r){n&1&&v(0,nl,41,31,"ng-container",2)(1,ol,4,9,"app-export-link",3)(2,rl,2,3,"ng-template",null,0,P)(4,al,2,3,"ng-template",null,1,P),n&2&&(o("ngIf",r.accountAssetsDetailGroup.accountAssetDetailList.length>1&&r.accountAssetsDetailGroup.positionEvalSummaryList.CAD),i(),o("ngIf",r.accountAssetsDetailGroup.accountAssetDetailList.length&&r.userProfile.hasAccessToExportHolding))},dependencies:[T,de,te,k,Bn,ct,G,Te,w],styles:['@charset "UTF-8";.or-table-cell.or-grow-symbol[_ngcontent-%COMP%]{flex-grow:1.1!important}.or-table-cell.or-grow-quantity[_ngcontent-%COMP%]{flex-grow:.5!important}.or-table-cell.or-grow-market-price[_ngcontent-%COMP%]{flex-grow:.7!important}.or-table-cell.or-grow-market-value[_ngcontent-%COMP%]{flex-grow:.75!important}.or-table-cell.or-grow-avg-cost[_ngcontent-%COMP%]{flex-grow:.6!important}.or-table-cell.or-grow-book-value[_ngcontent-%COMP%]{flex-grow:.5!important}.or-table-cell.or-grow-unrealized-gain[_ngcontent-%COMP%]{flex-grow:.65!important}.or-table-cell.or-grow-loan[_ngcontent-%COMP%]{flex-grow:.55!important}.or-grow-type[_ngcontent-%COMP%]{min-width:45px;flex-grow:0!important}.or-grow-trade-links[_ngcontent-%COMP%]{min-width:170px!important;flex-grow:1!important}@media(min-width:960px)and (max-width:1200px){.or-grow-trade-links[_ngcontent-%COMP%]{min-width:83px}}.or-opposite-currency-cursor[_ngcontent-%COMP%]{cursor:pointer}@media print{.top-0[_ngcontent-%COMP%]{top:0!important}}@media screen and (max-width:959px){.or-table[_ngcontent-%COMP%]   .or-table-body[_ngcontent-%COMP%]   .or-table-row[_ngcontent-%COMP%]   .or-table-cell[_ngcontent-%COMP%]:before{font-size:.875rem}.or-table[_ngcontent-%COMP%]   .or-table-body[_ngcontent-%COMP%]   .or-table-row[_ngcontent-%COMP%]   .or-table-cell[_ngcontent-%COMP%]{font-size:1rem}}'],changeDetection:0})}}return t})();var bo=(()=>{class t extends Q{constructor(){super(),this.classNameHoldings=""}
5ngOnInit(){this.status==="success"?this.classNameHoldings="mc-bc-mint mc-text-mint":this.status==="warning"&&(this.classNameHoldings="mc-bc-cheddar mc-text-cheddar")}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=x({type:t,selectors:[["app-holdings-badge"]],inputs:{icon:"icon",content:"content",status:"status"},standalone:!1,features:[q],decls:4,vars:6,consts:[[3,"name","size"]],template:function(n,r){n&1&&(l(0,"div"),c(1,"app-icon",0),l(2,"div"),u(3),a()()),n&2&&(oe(be("mc-d-flex mc-pl-xxsmall mc-pr-xxsmall mc-pt-0 mc-pb-0 mc-br-small mc-align-items-center mc-py-xxsmall mc-fw-normal mc-lh-header mc-fs-200 mc-b-solid mc-bs-small ",r.classNameHoldings)),i(),o("name",r.icon)("size","medium"),i(2),g(" ",r.content," "))},dependencies:[nt],encapsulation:2,changeDetection:0})}}return t})();function cl(t,s){t&1&&(l(0,"div"),c(1,"app-holdings-badge",4),p(2,"dict"),a()),t&2&&(i(),o("content",m(2,3,"orion.holdings.FPL_BADGE"))("icon","ico-financial-growth-color")("status","success"))}function pl(t,s){t&1&&(l(0,"div"),c(1,"app-holdings-badge",4),p(2,"dict"),a()),t&2&&(i(),o("content",m(2,3,"orion.holdings.FPL_BADGE"))("icon","ico-financial-growth-color")("status","warning"))}function dl(t,s){if(t&1){let e=V();A(0),l(1,"button",5),p(2,"dict"),U("click",function(){N(e);let r=d(3);return H(r.openFplModal())}),u(3),p(4,"dict"),a(),I()}if(t&2){let e=d(3);i(),oe("or-ghost "+e.classNameHoldingsLendingStatus),y("aria-label",m(2,4,"orion.holdings.ENROLLED_BUTTON")),i(2),g(" ",m(4,6,"orion.holdings.ENROLLED_BUTTON")," ")}}function ml(t,s){if(t&1&&(l(0,"div"),v(1,dl,5,8,"ng-container",0),a()),t&2){let e=d(2);i(),o("ngIf",e.isCDBNClient)}}function ul(t,s){t&1&&c(0,"div")}function vl(t,s){if(t&1&&(A(0),l(1,"div",1),v(2,cl,3,5,"div",2)(3,pl,3,5,"div",2)(4,ml,2,1,"div",2)(5,ul,1,0,"div",3),a(),I()),t&2){let e=d();i(),o("ngSwitch",e.lendingPrgStatus),i(),o("ngSwitchCase",e.FplStatus.ENROLLED),i(),o("ngSwitchCase",e.FplStatus.PENDING),i(),o("ngSwitchCase",e.FplStatus.NOT_ENROLLED)}}var xo=(()=>{class t extends Q{constructor(e,n,r,_,C){super(),this.featureFlagsService=e,this.userProfile=n,this.userInfoService=r,this.eventManagerService=_,this.store=C,this.FplStatus=Jn,this.rootAccountList=[],this.listAccountStatus=[]}ngOnInit(){this.isCDBNClient=!this.userInfoService.isRep&&this.userProfile.isCDBNUser,this.activateFPLOnAllAccounts=this.featureFlagsService.isEnabled("fpl",Be),this.classNameHoldingsLendingStatus=this.mobile?"mc-fs-100":"mc-fs-200",qe([this.store.pipe(R(Cn)),this.store.pipe(R(bn))]).pipe(W(this.destroyed$),ne(([e,n])=>({rootAccountList:e,listAccountStatus:n}))).subscribe(({rootAccountList:e,listAccountStatus:n})=>{this.rootAccountList=e,this.listAccountStatus=n})}openFplModal(){this.eventManagerService.trigger("orion-mf-event","open-fpl-modal",{rootAccountList:this.rootAccountList,listAccountStatus:this.listAccountStatus})}static{this.\u0275fac=function(n){return new(n||t)(f(Se),f(O),f(Ae),f(no),f(j))}}static{this.\u0275cmp=x({type:t,selectors:[["app-holdings-lending-status"]],inputs:{lendingPrgStatus:"lendingPrgStatus",mobile:"mobile"},standalone:!1,features:[q],decls:1,vars:1,consts:[[4,"ngIf"],[1,"mc-mt-xxsmall","lg:mc-mt-0",3,"ngSwitch"],[4,"ngSwitchCase"],[4,"ngSwitchDefault"],[3,"content","icon","status"],["mat-button","",3,"click"]],template:function(n,r){n&1&&v(0,vl,6,4,"ng-container",0),n&2&&o("ngIf",r.activateFPLOnAllAccounts)},dependencies:[T,$i,qi,Yi,nn,bo,w],encapsulation:2,changeDetection:0})}}return t})();var fl=(t,s)=>({"col-6":t,"col-12":s});function yl(t,s){if(t&1&&(l(0,"div",14),u(1),p(2,"portfolioAlias"),a()),t&2){let e=d();i(),g(" ",D(2,1,e.accountAssetsDetail,!0),`
6`)}}function hl(t,s){if(t&1&&(A(0),c(1,"app-holdings-lending-status",15),I()),t&2){let e=d();i(),o("lendingPrgStatus",e.accountAssetsDetail.lendingPrgStatus)("mobile",e.mobile)}}function Cl(t,s){if(t&1&&(l(0,"div",16),u(1),a()),t&2){let e=d();i(),g(" (",e.accountAssetsDetail.portfolioName,") ")}}function bl(t,s){if(t&1&&(A(0),c(1,"app-holdings-lending-status",15),I()),t&2){let e=d();i(),o("lendingPrgStatus",e.accountAssetsDetail.lendingPrgStatus)("mobile",e.mobile)}}function xl(t,s){t&1&&(l(0,"div",17),u(1),p(2,"dict"),a()),t&2&&(i(),g(" ",m(2,1,"orion.holdings.LENDING_ACCOUNT_QTY_DETAIL")," "))}function Sl(t,s){if(t&1&&(l(0,"div",21)(1,"div",22),u(2),p(3,"dict"),a(),l(4,"div",23),c(5,"app-value-styler",24),a()()),t&2){let e=d(2);i(2),h(m(3,2,"orion.holdings.TOTAL_VALUE")),i(3),o("value",e.getTotalValue())}}function Al(t,s){if(t&1&&(l(0,"div",27),c(1,"app-available-margin",28),a()),t&2){let e=d(2);
6i(),o("account",e.accountAssetsDetail.account)("exchangeRates",e.exchangeRates)("isAllAccountsClosed",e.accountAssetsDetail.account.isClosedAccount)("displayByAccount",!0)("targetCurrency",e.getSelectedCurrency())}}function Il(t,s){if(t&1&&(l(0,"div",21)(1,"div",22),u(2),p(3,"dict"),a(),l(4,"div",23),c(5,"app-value-styler",24),a(),l(6,"div",29),u(7),p(8,"dict"),a()()),t&2){let e=d(2);i(2),h(m(3,5,"orion.holdings.TOTAL_MARGIN")),i(3),z("negative",e.marginCall),o("value",e.getTotalMargin()),i(2),h(m(8,7,"orion.holdings.LAST_BUSINESS_DAY"))}}function Tl(t,s){if(t&1&&(l(0,"div",18)(1,"div",19),v(2,Sl,6,4,"div",20),l(3,"div",21)(4,"div",22),u(5),p(6,"dict"),a(),l(7,"div",23),c(8,"app-value-styler",24),a()(),v(9,Al,2,5,"div",25)(10,Il,9,9,"div",20),l(11,"div",21),c(12,"app-order-counts",26),a()()()),t&2){let e=d();i(2),o("ngIf",e.showTotalValue),i(3),h(m(6,8,"orion.holdings.CASH")),i(3),o("value",e.getCashAmount()),i(),o("ngIf",e.showBuyingPower),i(),o("ngIf",e.showTotalMargin),i(2),o("orderCounts",e.accountAssetsDetail)("clickable",!0)("acctNo",e.accountAssetsDetail.account.acctNo)}}function El(t,s){if(t&1&&(l(0,"div",30)(1,"div",31),c(2,"app-dropdown",32),p(3,"dict"),a()()),t&2){let e=d();i(2),o("showLabelWhenClosed",!1)("showShortLabel",!0)("selectionHolder",e.currency.currencyMap[e.accountAssetsDetail.account.acctNo]),me("aria-label",m(3,4,"orion.account-summary.CURRENCY_SELECTION"))}}var pi=(()=>{class t extends Q{constructor(e,n,r,_){super(),this.currency=e,this.userProfile=n,this.imageService=r,this.store=_,this.showPortfolioNameHeader=!1,this.showCurrencyDropdown=!0,this.Access=Oe}ngOnInit(){this.store.pipe(R(Ie),W(this.destroyed$)).subscribe(e=>{this.accountRoot=Ft(e,this.accountAssetsDetail.cltId),this.account=Ut(e,this.accountAssetsDetail.account.acctNo)}),this.showBuyingPower=(this.userProfile.hasBuyingPowerAccess||this.userProfile.hasAccessToBuyingPower_NBIN_FBN_GP)&&!this.accountAssetsDetail.account.securityLendingAccount,this.showTotalValue=this.userProfile.hasAccessToPortfolioTotalValue,this.showTotalMargin=this.userProfile.hasAccessToPortfolioTotalMargin&&this.account.marginInd,this.showSecurityLendingBadge=this.showSecurityLending&&!this.accountAssetsDetail.account.isClosedAccount&&!this.securityLendingAccount,this.marginCall=this.getTotalMargin()<0,this.hasAtLeastOnePosition=this.accountAssetsDetail?.assetsDetailByCurrencyList[this.getSelectedCurrency()]?.positionList?.length>0}getCashAmount(){return this.getSelectedCurrencyAssetsDetail().cashAmt}getTotalValue(){return this.getSelectedCurrencyAssetsDetail().totalValue}getTotalMargin(){return this.getSelectedCurrencyAssetsDetail().totalMargin}getSelectedCurrency(){return this.currency.getSelectedCurrency(this.account.acctNo)}getSelectedCurrencyAssetsDetail(){let e=this.currency.getSelectedCurrency(this.account.acctNo);return this.accountAssetsDetail.assetsDetailByCurrencyList[e]}static{this.\u0275fac=function(n){return new(n||t)(f(ge),f(O),f(on),f(j))}}static{this.\u0275cmp=x({type:t,selectors:[["app-holdings-header"]],inputs:{accountAssetsDetail:"accountAssetsDetail",showPortfolioNameHeader:"showPortfolioNameHeader",showCurrencyDropdown:"showCurrencyDropdown",securityLendingAccount:"securityLendingAccount",exchangeRates:"exchangeRates",showSecurityLending:"showSecurityLending",mobile:"mobile"},standalone:!1,features:[q],decls:17,vars:14,consts:[["class","d-flex sub-title-compact-theme",4,"ngIf"],["styleClass","d-flex py-2",3,"accountRoot"],[1,"row","align-items-top","py-2-compact-theme"],[1,"col-lg-5","mr-auto",3,"ngClass"],[1,"d-flex","align-items-baseline","pb-2"],[1,"flex-column"],[1,"d-flex","align-items-center","lg:mc-d-flex","mc-align-items-center"],[1,"sub-title-compact-theme","mc-mr-xsmall"],[4,"ngIf"],[1,"label-med-compact-theme","or-normal","or-black"],["class","label-small-compact-theme or-normal or-black",4,"ngIf"],["class","col-12 pb-2 label-small-compact-theme",4,"ngIf"],["class","col-12 col-lg-auto order-1 order-lg-0",4,"ngIf"],["class","col-6 col-lg-1 pt-3 pt-lg-0 order-0 order-lg-3 align-self-center",4,"ngIf"],[1,"d-flex","sub-title-compact-theme"],[3,"lendingPrgStatus","mobile"],[1,"label-small-compact-theme","or-normal","or-black"],[1,"col-12","pb-2","label-small-compact-theme"],[1,"col-12","col-lg-auto","order-1","order-lg-0"],[1,"row","justify-content-lg-end"],["class","col-6 col-lg-auto flex-column pr-lg-3 pt-2 pt-lg-0 order-1 order-lg-0",4,"ngIf"],[1,"col-6","col-lg-auto","flex-column","pr-lg-3","pt-2","pt-lg-0","order-1","order-lg-0"],[1,"or-font-14","or-medium","or-color_grey-dark-blue"],[1,"label-big-compact-theme","or-bold","or-black"],["digits","1.2-2",3,"value"],["class","col-6 col-lg-auto pr-lg-3 pt-2 pt-lg-0 order-1 order-lg-0",4,"ngIf"],[3,"orderCounts","clickable","acctNo"],[1,"col-6","col-lg-auto","pr-lg-3","pt-2","pt-lg-0","order-1","order-lg-0"],["spinnerPrefix","acctHol",3,"account","exchangeRates","isAllAccountsClosed","displayByAccount","targetCurrency"],[1,"or-font-10","or-normal","or-black"],[1,"col-6","col-lg-1","pt-3","pt-lg-0","order-0","order-lg-3","align-self-center"],[1,"d-flex","justify-content-end"],["styleClass","or-narrow",3,"showLabelWhenClosed","showShortLabel","selectionHolder","aria-label"]],template:function(n,r){n&1&&(v(0,yl,3,4,"div",0),c(1,"app-investcube-logo",1),l(2,"div",2)(3,"div",3)(4,"div",4)(5,"div",5)(6,"div",6)(7,"h2",7),u(8),a(),v(9,hl,2,2,"ng-container",8),a(),l(10,"div",9),u(11),a(),v(12,Cl,2,1,"div",10)(13,bl,2,2,"ng-container",8),a()()(),v(14,xl,3,3,"div",11)(15,Tl,13,10,"div",12)(16,El,4,6,"div",13),a()),n&2&&(o("ngIf",r.showPortfolioNameHeader),i(),o("accountRoot",r.accountRoot),i(2),o("ngClass",se(11,fl,r.showCurrencyDropdown,!r.showCurrencyDropdown)),i(5),h(r.accountAssetsDetail.account.acctTypeDesc),i(),o("ngIf",!r.mobile&&r.showSecurityLendingBadge),i(2),h(r.accountAssetsDetail.account.acctNo),i(),o("ngIf",!r.showPortfolioNameHeader),i(),o("ngIf",r.mobile&&r.showSecurityLendingBadge),i(),o("ngIf",r.securityLendingAccount&&r.hasAtLeastOnePosition),i(),o("ngIf",!r.securityLendingAccount),i(),o("ngIf",r.showCurrencyDropdown&&!r.securityLendingAccount))},dependencies:[X,T,Dn,ke,k,He,zt,xo,w,qt],encapsulation:2,changeDetection:0})}}return t})();var Pl=()=>[];function Dl(t,s){if(t&1&&(l(0,"a",19)(1,"span",20),u(2),p(3,"dict"),a()()),t&2){let e=d(),n=E(31);o("appSortService",e.sort)("group",e.accountAssetsInfo.account.acctNo),i(),o("bncPopoverDisabled",!e.userProfile.isFbnOrGpUser)("bncPopover",n),i(),g(" ",m(3,5,"orion.holdings.BOOK_VALUE")," ")}}function wl(t,s){if(t&1&&(l(0,"a",21),u(1),p(2,"dict"),a()),t&2){let e=d(),n=E(29);o("bncPopoverDisabled",!e.userProfile.isFbnOrGpUser)("bncPopover",n)("appSortService",e.sort)("group",e.accountAssetsInfo.account.acctNo),i(),g(" ",m(2,5,"orion.holdings.UNREALIZED_GAIN")," ")}}function Ll(t,s){if(t&1&&(l(0,"a",22),u(1),p(2,"dict"),a()),t&2){let e=d();o("appSortService",e.sort)("group",e.accountAssetsInfo.account.acctNo),i(),g(" ",m(2,3,"orion.holdings.LOAN_VALUE")," ")}}function Ol(t,s){t&1&&c(0,"div",23)}function Bl(t,s){if(t&1&&(l(0,"div",42),p(1,"dict"),c(2,"div",33),p(3,"valueStyler"),a()),t&2){let e=d().$implicit,n=d();y("data-header",m(1,2,"orion.holdings.BOOK_VALUE")),i(2),o("innerHTML",n.securityLendingAccount?"-":D(3,4,e.bookVal,"1.2-2"),S)}}function Ml(t,s){t&1&&(l(0,"div"),u(1,"-"),a())}function kl(t,s){if(t&1&&(c(0,"div",33),p(1,"valueStyler")),t&2){let e=d().$implicit;o("innerHTML",D(1,1,e.marketPrc,"1.5-5"),S)}}function Rl(t,s){t&1&&(l(0,"div"),u(1,"-"),a())}function Nl(t,s){if(t&1&&(l(0,"div",44)(1,"div",45)(2,"div",46),u(3),p(4,"dict"),a(),c(5,"app-value-styler",47),a()()),t&2){let e=d(2).$implicit;i(3),h(m(4,2,"orion.holdings.ACCRUED_INTEREST")),i(2),o("value",e.acrIntAmt)}}function Hl(t,s){if(t&1&&(l(0,"div"),c(1,"div",33),p(2,"valueStyler"),v(3,Nl,6,4,"div",43),a()),t&2){let e=d().$implicit;i(),o("innerHTML",D(2,2,e.marketVal,"1.2-2"),S),i(2),o("ngIf",e.acrIntAmt)}}function Vl(t,s){t&1&&(l(0,"div"),u(1,"-"),a())}function Ul(t,s){if(t&1&&(l(0,"div"),c(1,"app-value-styler",49),a()),t&2){let e=d(3).$implicit;i(),o("value",e.pnlPercent)("colored",!0)("arrow",!0)("small",!0)}}function Fl(t,s){if(t&1&&(l(0,"div"),c(1,"div",33),p(2,"valueStyler"),v(3,Ul,2,4,"div",37),a()),t&2){let e=d(2).$implicit;i(),o("innerHTML",Le(2,2,e.pnl,"1.2-2",!0),S),i(2),o("ngIf",e.pnlPercent)}}function Gl(t,s){if(t&1&&(l(0,"div",48),p(1,"dict"),v(2,Vl,2,0,"div",37)(3,Fl,4,6,"div",37),a()),t&2){let e=d(2);y("data-header",m(1,3,"orion.holdings.UNREALIZED_GAIN")),i(2),o("ngIf",e.securityLendingAccount),i(),o("ngIf",!e.securityLendingAccount)}}function jl(t,s){t&1&&(l(0,"div"),u(1,"-"),a())}function Ql(t,s){if(t&1&&c(0,"app-loan-value-detail",52),t&2){let e=d(2).$implicit;o("positionLastBusinessDay",e)("value",e.loanVal)}}function $l(t,s){if(t&1&&(l(0,"div",50),p(1,"dict"),v(2,jl,2,0,"div",37)(3,Ql,1,2,"app-loan-value-detail",51),a()),t&2){let e=d().$implicit,n=d();z("or-mobile-hide",!e.loanVal),y("data-header",m(1,5,"orion.holdings.LOAN_VALUE")),i(2),o("ngIf",n.accountAssetsInfo.account.marginInd&&n.securityLendingAccount),i(),o("ngIf",n.accountAssetsInfo.account.marginInd&&!n.securityLendingAccount)}}function ql(t,s){if(t&1&&(l(0,"div")(1,"div",24)(2,"div",25)(3,"div",26)(4,"div",27)(5,"div",28)(6,"div",27)(7,"span",29),u(8),a()()()(),l(9,"div",30)(10,"app-tooltip",31),p(11,"uppercase"),u(12),p(13,"uppercase"),a()()()(),l(14,"div",32),p(15,"dict"),c(16,"div",33),p(17,"valueStyler"),a(),l(18,"div",34),p(19,"dict"),c(20,"div",33),p(21,"valueStyler"),a(),v(22,Bl,4,7,"div",35),l(23,"div",36),p(24,"dict"),v(25,Ml,2,0,"div",37)(26,kl,2,4,"div",38),a(),l(27,"div",39),p(28,"dict"),v(29,Rl,2,0,"div",37)(30,Hl,4,5,"div",37),a(),v(31,Gl,4,5,"div",40)(32,$l,4,7,"div",41),a()()),t&2){let e=s.$implicit,n=d();
6i(8),h(e.symbol),i(2),o("textTooltip",m(11,16,e.symbolDescription)),i(2),g(" ",m(13,18,e.symbolDescription)," "),i(2),y("data-header",m(15,20,"orion.holdings.QUANTITY")),i(2),o("innerHTML",D(17,22,e.qty,"1.0-1"),S),i(2),y("data-header",m(19,25,"orion.holdings.AVERAGE_COST")),i(2),o("innerHTML",n.securityLendingAccount?"-":D(21,27,e.avgCost,"1.2-5"),S),i(2),o("ngIf",n.userProfile.hasBookValueAccess),i(),y("data-header",m(24,30,"orion.holdings.MARKET_PRICE")),i(2),o("ngIf",n.securityLendingAccount),i(),o("ngIf",!n.securityLendingAccount),i(),y("data-header",m(28,32,"orion.holdings.MARKET_VALUE")),i(2),o("ngIf",n.securityLendingAccount),i(),o("ngIf",!n.securityLendingAccount),i(),o("ngIf",n.userProfile.hasPNLAccess),i(),o("ngIf",n.userProfile.hasAccessToPortfolioLoanValue)}}function Yl(t,s){if(t&1&&(l(0,"div",65),p(1,"dict"),c(2,"div",62),p(3,"valueStyler"),a()),t&2){let e=d(2);y("data-header",m(1,2,"orion.holdings.BOOK_VALUE")),i(2),o("innerHtml",D(3,4,e.assetsInfo.totalBookVal,"1.2-2"),S)}}function zl(t,s){if(t&1&&(l(0,"div"),c(1,"app-value-styler",49),a()),t&2){let e=d(3);i(),o("value",e.assetsInfo.totalPnlPercent)("colored",!0)("arrow",!0)("small",!0)}}function Kl(t,s){if(t&1&&(l(0,"div",66),p(1,"dict"),l(2,"div"),c(3,"div",62),p(4,"valueStyler"),v(5,zl,2,4,"div",37),a()()),t&2){let e=d(2);y("data-header",m(1,3,"orion.holdings.UNREALIZED_GAIN")),i(3),o("innerHtml",Le(4,5,e.assetsInfo.totalPnl,"1.2-2",!0),S),i(2),o("ngIf",e.assetsInfo.totalPnlPercent)}}function Wl(t,s){if(t&1&&c(0,"app-value-styler",69),t&2){let e=d(3);o("value",e.assetsInfo.totalLoanVal)}}function Zl(t,s){if(t&1&&(l(0,"div",67),v(1,Wl,1,1,"app-value-styler",68),a()),t&2){let e=d(2);z("or-mobile-hide",!e.accountAssetsInfo.account.marginInd),i(),o("ngIf",e.accountAssetsInfo.account.marginInd)}}function Xl(t,s){if(t&1&&(l(0,"div",53)(1,"div",54)(2,"div",55),u(3),p(4,"dict"),l(5,"app-tooltip",56),p(6,"dict"),u(7),a()()(),c(8,"div",57),l(9,"div",58),u(10,"\xA0"),a(),v(11,Yl,4,7,"div",59),c(12,"div",60),l(13,"div",61),p(14,"dict"),l(15,"div"),c(16,"div",62),p(17,"valueStyler"),a()(),v(18,Kl,6,9,"div",63)(19,Zl,2,3,"div",64),a()),t&2){let e=d();i(3),g(" ",m(4,8,"orion.holdings.TOTAL")," "),i(2),o("textTooltip",m(6,10,"orion.app."+e.currency)),i(2),g(" ",e.currency," "),i(4),o("ngIf",e.userProfile.hasBookValueAccess),i(2),y("data-header",m(14,12,"orion.holdings.MARKET_VALUE")),i(3),o("innerHtml",D(17,14,e.assetsInfo.totalMarketVal,"1.2-2"),S),i(2),o("ngIf",e.userProfile.hasPNLAccess),i(),o("ngIf",e.userProfile.hasAccessToPortfolioLoanValue)}}function Jl(t,s){t&1&&(u(0),p(1,"dict")),t&2&&g(" ",m(1,1,"orion.holdings.MESSAGE_UNREALIZED_GAIN_LOSS"),`
7`)}function es(t,s){t&1&&(u(0),p(1,"dict")),t&2&&g(" ",m(1,1,"orion.holdings.TEXT_TOOLTIP_BOOK_VALUE"),`
8`)}var Ao=(()=>{class t extends Q{constructor(e,n,r,_){super(),this.userProfile=e,this.sort=n,this.holdingsService=r,this.searchBarRepService=_}ngOnInit(){this.sort.setOrderBy("symbolDescription",this.accountAssetsInfo.account.acctNo,"orderBy")}ngOnChanges(){this.assetsInfo=this.holdingsService.getAssetDetailListByCurrency(this.accountAssetsInfo),this.nonRegisteredAccount=this.accountAssetsInfo.account?.acctClassCd!==yt}static{this.\u0275fac=function(n){return new(n||t)(f(O),f($),f(K),f(pt))}}static{this.\u0275cmp=x({type:t,selectors:[["app-holdings-last-business-day-table"]],inputs:{currency:"currency",accountAssetsInfo:"accountAssetsInfo",securityLendingAccount:"securityLendingAccount"},standalone:!1,features:[q,Je],decls:32,vars:42,consts:[["UnrealizedGainLoss",""],["PopupOverBookValue",""],[1,"or-table"],[1,"or-table-body","or-group-collapsible"],["appSticky","",1,"or-table-row","or-table-header","top-0",3,"offsetTop"],["href","javascript:void(0)","key","symbol",1,"or-table-cell","or-grow-symbol",3,"appSortService","group"],["href","javascript:void(0)","key","qty",1,"or-table-cell","or-numeric","or-grow-quantity",3,"appSortService","group"],["href","javascript:void(0)","key","avgCost",1,"or-table-cell","or-numeric","or-grow-avg-cost",3,"appSortService","group"],["href","javascript:void(0)","class","or-table-cell or-numeric or-grow-book-value","key","bookVal",3,"appSortService","group",4,"ngIf"],["href","javascript:void(0)","key","marketPrc",1,"or-table-cell","or-numeric","or-grow-market-price",3,"appSortService","group"],["href","javascript:void(0)","key","marketVal",1,"or-table-cell","or-numeric","or-grow-market-value",3,"appSortService","group"],[3,"textTooltip","disabledTooltip"],["class","or-table-cell or-numeric or-grow-unrealized-gain","b
8ncPopoverTrigger","hover","href","javascript:void(0)","key","pnl",3,"bncPopoverDisabled","bncPopover","appSortService","group",4,"ngIf"],["href","javascript:void(0)","class","or-table-cell or-grow-loan or-numeric","key","loanVal",3,"appSortService","group",4,"ngIf"],["class","or-table-cell or-grow-loan or-numeric",4,"ngIf"],[4,"ngFor","ngForOf"],["class","or-table-row or-table-footer","appCollapsible","",4,"ngIf"],["id","UnrealizedGainLoss"],["id","PopupOverBookValue"],["href","javascript:void(0)","key","bookVal",1,"or-table-cell","or-numeric","or-grow-book-value",3,"appSortService","group"],["bncPopoverTrigger","hover",3,"bncPopoverDisabled","bncPopover"],["bncPopoverTrigger","hover","href","javascript:void(0)","key","pnl",1,"or-table-cell","or-numeric","or-grow-unrealized-gain",3,"bncPopoverDisabled","bncPopover","appSortService","group"],["href","javascript:void(0)","key","loanVal",1,"or-table-cell","or-grow-loan","or-numeric",3,"appSortService","group"],[1,"or-table-cell","or-grow-loan","or-numeric"],["appCollapsible","",1,"or-table-row"],[1,"or-table-cell","or-grow-symbol","or-position-1","text-truncate"],[1,"w-100"],[1,"d-flex"],[1,"d-inline-flex","align-items-center","w-100","position-relative"],[1,"d-block","text-truncate","or-normal-label"],[1,"or-font-10","or-normal","or-black"],["classTooltip","or-ellipsis",3,"textTooltip"],[1,"or-table-cell","or-numeric","or-position-4","or-collapsible","or-grow-quantity"],[3,"innerHTML"],[1,"or-table-cell","or-position-6","or-numeric","or-collapsible","or-grow-avg-cost"],["class","or-table-cell or-numeric or-position-7 or-collapsible or-grow-book-value",4,"ngIf"],[1,"or-table-cell","or-numeric","or-position-2","or-grow-market-price"],[4,"ngIf"],[3,"innerHTML",4,"ngIf"],[1,"or-table-cell","or-numeric","or-position-5","or-collapsible","or-grow-market-value"],["class","or-table-cell or-position-8 or-numeric or-collapsible or-grow-unrealized-gain",4,"ngIf"],["class","or-table-cell or-numeric or-position-9 or-collapsible or-grow-loan",3,"or-mobile-hide",4,"ngIf"],[1,"or-table-cell","or-numeric","or-position-7","or-collapsible","or-grow-book-value"],["class","or-box or-no-padding",4,"ngIf"],[1,"or-box","or-no-padding"],[1,"or-box-child","or-no-padding","or-small-gap"],[1,"or-label_small"],["digits","1.2-2",1,"or-label_small",3,"value"],[1,"or-table-cell","or-position-8","or-numeric","or-collapsible","or-grow-unrealized-gain"],["digits","1.2-2","decorator","#%",3,"value","colored","arrow","small"],[1,"or-table-cell","or-numeric","or-position-9","or-collapsible","or-grow-loan"],[3,"positionLastBusinessDay","value",4,"ngIf"],[3,"positionLastBusinessDay","value"],["appCollapsible","",1,"or-table-row","or-table-footer"],[1,"or-table-cell","or-grow-symbol","or-position-1"],[1,"or-h4"],[1,"d-inline-flex",3,"textTooltip"],[1,"or-table-cell","or-numeric","or-collapsible","or-grow-quantity","or-position-5"],[1,"or-table-cell","or-numeric","or-collapsible","or-grow-avg-cost","or-position-6"],["class","or-table-cell or-numeric or-collapsible or-grow-book-value or-position-3",4,"ngIf"],[1,"or-table-cell","or-numeric","or-collapsible","or-grow-market-price","or-position-7"],[1,"or-table-cell","or-numeric","or-grow-market-value","or-position-2"],[3,"innerHtml"],["class","or-table-cell or-numeric or-collapsible or-grow-unrealized-gain or-position-8",4,"ngIf"],["class","or-table-cell or-numeric or-collapsible or-grow-loan or-position-9",3,"or-mobile-hide",4,"ngIf"],[1,"or-table-cell","or-numeric","or-collapsible","or-grow-book-value","or-position-3"],[1,"or-table-cell","or-numeric","or-collapsible","or-grow-unrealized-gain","or-position-8"],[1,"or-table-cell","or-numeric","or-collapsible","or-grow-loan","or-position-9"],["digits","1.2-2",3,"value",4,"ngIf"],["digits","1.2-2",3,"value"]],template:function(n,r){n&1&&(l(0,"div",2)(1,"div",3)(2,"div",4),p(3,"async"),l(4,"a",5),u(5),p(6,"dict"),a(),l(7,"a",6),u(8),p(9,"dict"),a(),l(10,"a",7),u(11),p(12,"dict"),a(),v(13,Dl,4,7,"a",8),l(14,"a",9),u(15),p(16,"dict"),a(),l(17,"a",10)(18,"app-tooltip",11),p(19,"dict"),u(20),p(21,"dict"),a()(),v(22,wl,3,7,"a",12)(23,Ll,3,5,"a",13)(24,Ol,1,0,"div",14),a(),v(25,ql,33,34,"div",15),p(26,"orderBy"),v(27,Xl,20,17,"div",16),a()(),v(28,Jl,2,3,"ng-template",17,0,P)(30,es,2,3,"ng-template",18,1,P)),n&2&&(i(2),o("offsetTop",m(3,24,r.searchBarRepService.searchBarHeight$)),i(2),o("appSortService",r.sort)("group",r.accountAssetsInfo.account.acctNo),i(),g(" ",m(6,26,"orion.holdings.SYMBOL")," "),i(2),o("appSortService",r.sort)("group",r.accountAssetsInfo.account.acctNo),i(),g(" ",m(9,28,"orion.holdings.QUANTITY")," "),i(2),o("appSortService",r.sort)("group",r.accountAssetsInfo.account.acctNo),i(),g(" ",m(12,30,"orion.holdings.AVERAGE_COST")," "),i(2),o("ngIf",r.userProfile.hasBookValueAccess),i(),o("appSortService",r.sort)("group",r.accountAssetsInfo.account.acctNo),i(),g(" ",m(16,32,"orion.holdings.MARKET_PRICE")," "),i(2),o("appSortService",r.sort)("group",r.accountAssetsInfo.account.acctNo),i(),o("textTooltip",m(19,34,"orion.holdings.TEXT_TOOLTIP_MARKET_VALUE"))("disabledTooltip",!r.userProfile.hasAccessToHoldingsMarketValueDayChange),i(2),g(" ",m(21,36,"orion.holdings.MARKET_VALUE")," "),i(2),o("ngIf",r.userProfile.hasPNLAccess),i(),o("ngIf",r.userProfile.hasAccessToPortfolioLoanValue&&r.accountAssetsInfo.account.marginInd),i(),o("ngIf",r.userProfile.hasAccessToPortfolioLoanValue&&!r.accountAssetsInfo.account.marginInd),i(),o("ngForOf",D(26,38,(r.assetsInfo==null?null:r.assetsInfo.assetDetailList)||Ke(41,Pl),r.sort.orderBy(r.accountAssetsInfo.account.acctNo))),i(2),o("ngIf",r.assetsInfo&&!r.securityLendingAccount))},dependencies:[F,T,de,Ee,te,k,st,Ne,ci,G,wt,Te,fe,w],styles:['@charset "UTF-8";.or-table-cell.or-grow-symbol[_ngcontent-%COMP%]{flex-grow:1.1!important}.or-table-cell.or-grow-quantity[_ngcontent-%COMP%]{flex-grow:.5!important}.or-table-cell.or-grow-market-price[_ngcontent-%COMP%]{flex-grow:.7!important}.or-table-cell.or-grow-market-value[_ngcontent-%COMP%]{flex-grow:.75!important}.or-table-cell.or-grow-avg-cost[_ngcontent-%COMP%]{flex-grow:.6!important}.or-table-cell.or-grow-book-value[_ngcontent-%COMP%]{flex-grow:.5!important}.or-table-cell.or-grow-unrealized-gain[_ngcontent-%COMP%]{flex-grow:.65!important}.or-table-cell.or-grow-loan[_ngcontent-%COMP%]{flex-grow:.55!important}[_nghost-%COMP%]{display:flex;flex-direction:column;flex:1;align-self:stretch}@media screen and (max-width:959px){.or-table[_ngcontent-%COMP%]   .or-table-body[_ngcontent-%COMP%]   .or-table-row[_ngcontent-%COMP%]   .or-table-cell[_ngcontent-%COMP%]:before{font-size:.875rem}.or-table[_ngcontent-%COMP%]   .or-table-body[_ngcontent-%COMP%]   .or-table-row[_ngcontent-%COMP%]   .or-table-cell[_ngcontent-%COMP%]{font-size:1rem}}'],changeDetection:0})}}return t})();var is=(t,s)=>({"col-6":t,"col-12":s});function ns(t,s){if(t&1&&(l(0,"div",12),u(1),p(2,"portfolioAlias"),a()),t&2){let e=d();i(),g(" ",D(2,1,e.accountAssetsInfo,!0),`
9`)}}function os(t,s){if(t&1&&(l(0,"div",13),u(1),a()),t&2){let e=d();i(),g(" (",e.accountAssetsInfo.account.cltName,") ")}}function rs(t,s){t&1&&(l(0,"div",14),u(1),p(2,"dict"),a()),t&2&&(i(),g(" ",m(2,1,"orion.holdings.LENDING_ACCOUNT_QTY_DETAIL")," "))}function as(t,s){if(t&1&&(l(0,"div",15)(1,"div",16)(2,"div",17)(3,"div",18),u(4),p(5,"dict"),a(),l(6,"div",19),c(7,"app-value-styler",20),a()(),l(8,"div",17)(9,"div",18),u(10),p(11,"dict"),a(),l(12,"div",19),c(13,"app-value-styler",20),a()(),l(14,"div",17)(15,"div",18),u(16),p(17,"dict"),a(),l(18,"div",19),c(19,"app-value-styler",20),a()(),l(20,"div",17)(21,"div",18),u(22),p(23,"dict"),a(),l(24,"div",19),c(25,"app-value-styler",20),a()(),l(26,"div",17)(27,"div",18),u(28),p(29,"dict"),a(),l(30,"div",19),c(31,"app-value-styler",20),a()(),l(32,"div",17)(33,"div",18),u(34),p(35,"dict"),a(),l(36,"div",19),c(37,"app-value-styler",20),a()()()()),t&2){let e=d();i(4),h(m(5,12,"orion.holdings.TRADE_DATE_BALANCE")),i(3),o("value",e.getTradeDateBalance()),i(3),h(m(11,14,"orion.holdings.SETTLEMENT_DATE_BALANCE")),i(3),o("value",e.getSettlementDateBalance()),i(3),h(m(17,16,"orion.holdings.INVESTMENTS")),i(3),o("value",e.getInvestments()),i(3),h(m(23,18,"orion.holdings.TOTAL_CASH_AND_INVESTMENTS")),i(3),o("value",e.getTotalCashAndInvestments()),i(3),h(m(29,20,"orion.holdings.LOAN_VALUE")),i(3),o("value",e.getLoanValue()),i(3),h(m(35,22,"orion.holdings.AVAILABLE_MARGIN_CAMEL")),i(3),o("value",e.getAvailableMargin())}}function ls(t,s){if(t&1&&(l(0,"div",21)(1,"div",22),c(2,"app-dropdown",23),p(3,"dict"),a()()),t&2){let e=d();i(2),o("showLabelWhenClosed",!1)("showShortLabel",!0)("selectionHolder",e.currency.currencyMap[e.accountAssetsInfo.account.acctNo]),me("aria-label",m(3,4,"orion.account-summary.CURRENCY_SELECTION"))}}var Io=(()=>{class t extends Q{constructor(e,n){super(),this.currency=e,this.store=n,this.showPortfolioNameHeader=!1,this.showCurrencyDropdown=!0}ngOnInit(){this.store.pipe(R(Ie),W(this.destroyed$)).subscribe(e=>{this.accountRoot=Ft(e,this.accountAssetsInfo.account.cltId),this.account=Ut(e,this.accountAssetsInfo.account.acctNo)}),this.hasAtLeastOnePosition=this.accountAssetsInfo?.assetDetailListByCurrencyList[this.get
9SelectedCurrency()]?.assetDetailList?.length>0}getTradeDateBalance(){return this.getSelectedCurrencyAssetsOverview().tradeDtBalance}getInvestments(){return this.getSelectedCurrencyAssetsOverview().investmentVal}getSettlementDateBalance(){return this.getSelectedCurrencyAssetsOverview().settlementDtBalance}getTotalCashAndInvestments(){return this.getSelectedCurrencyAssetsOverview().totalVal}getLoanValue(){return this.getSelectedCurrencyAssetsOverview().loanVal}getAvailableMargin(){return this.getSelectedCurrencyAssetsOverview().availMargin}getSelectedCurrency(){return this.currency.getSelectedCurrency(this.account.acctNo)}getSelectedCurrencyAssetsOverview(){let e=this.getSelectedCurrency();return this.accountAssetsInfo.assetOverviewByCurrencyList[e]}static{this.\u0275fac=function(n){return new(n||t)(f(ge),f(j))}}static{this.\u0275cmp=x({type:t,selectors:[["app-holdings-last-business-day-header"]],inputs:{accountAssetsInfo:"accountAssetsInfo",showPortfolioNameHeader:"showPortfolioNameHeader",showCurrencyDropdown:"showCurrencyDropdown",securityLendingAccount:"securityLendingAccount",exchangeRates:"exchangeRates"},standalone:!1,features:[q],decls:14,vars:12,consts:[["class","d-flex sub-title-compact-theme",4,"ngIf"],["styleClass","d-flex py-2",3,"accountRoot"],[1,"row","align-items-top","py-2-compact-theme","mb-2"],[1,"col-lg-2","mr-auto",3,"ngClass"],[1,"d-flex","align-items-baseline","pb-2"],[1,"flex-column"],[1,"sub-title-compact-theme"],[1,"label-med-compact-theme","or-normal","or-black"],["class","label-small-compact-theme or-normal or-black",4,"ngIf"],["class","col-12 pb-2 label-small-compact-theme",4,"ngIf"],["class","col-12 col-lg-9 order-1 order-lg-0",4,"ngIf"],["class","col-6 col-lg-1 pt-3 pt-lg-0 order-0 order-lg-3 align-self-center",4,"ngIf"],[1,"d-flex","sub-title-compact-theme"],[1,"label-small-compact-theme","or-normal","or-black"],[1,"col-12","pb-2","label-small-compact-theme"],[1,"col-12","col-lg-9","order-1","order-lg-0"],[1,"row","justify-content-lg-end"],[1,"col-6","col-lg-2","flex-column","pr-lg-3","pt-2","pt-lg-0","order-1","order-lg-0"],[1,"or-font-14","or-medium","or-color_grey-dark-blue"],[1,"label-big-compact-theme","or-bold","or-black"],["digits","1.2-2",3,"value"],[1,"col-6","col-lg-1","pt-3","pt-lg-0","order-0","order-lg-3","align-self-center"],[1,"d-flex","justify-content-end"],["styleClass","or-narrow",3,"showLabelWhenClosed","showShortLabel","selectionHolder","aria-label"]],template:function(n,r){n&1&&(v(0,ns,3,4,"div",0),c(1,"app-investcube-logo",1),l(2,"div",2)(3,"div",3)(4,"div",4)(5,"div",5)(6,"h2",6),u(7),a(),l(8,"div",7),u(9),a(),v(10,os,2,1,"div",8),a()()(),v(11,rs,3,3,"div",9)(12,as,38,24,"div",10)(13,ls,4,6,"div",11),a()),n&2&&(o("ngIf",r.showPortfolioNameHeader),i(),o("accountRoot",r.accountRoot),i(2),o("ngClass",se(9,is,r.showCurrencyDropdown,!r.showCurrencyDropdown)),i(4),h(r.accountAssetsInfo.account.acctTypeDesc),i(2),h(r.accountAssetsInfo.account.acctNo),i(),o("ngIf",!r.showPortfolioNameHeader),i(),o("ngIf",r.securityLendingAccount&&r.hasAtLeastOnePosition),i(),o("ngIf",!r.securityLendingAccount),i(),o("ngIf",r.showCurrencyDropdown&&!r.securityLendingAccount))},dependencies:[X,T,ke,k,He,w,qt],encapsulation:2,changeDetection:0})}}return t})();function cs(t,s){t&1&&(l(0,"div",26),u(1),p(2,"dict"),a()),t&2&&(i(),g(" ",m(2,1,"orion.holdings.BOOK_VALUE")," "))}function ps(t,s){t&1&&(l(0,"div",27),u(1),p(2,"dict"),a()),t&2&&(i(),g(" ",m(2,1,"orion.holdings.UNREALIZED_GAIN")," "))}function ds(t,s){t&1&&c(0,"div",28)}function ms(t,s){t&1&&c(0,"div",29)}function us(t,s){t&1&&c(0,"div",30)}function vs(t,s){if(t&1&&(l(0,"div",31),p(1,"dict"),c(2,"app-value-styler",21),a()),t&2){let e=d();y("data-header",m(1,2,"orion.holdings.BOOK_VALUE")),i(2),o("value",(e.grandTotalByCurrencyList.CAD==null?null:e.grandTotalByCurrencyList.CAD.bookVal)==null?0:e.grandTotalByCurrencyList.CAD==null?null:e.grandTotalByCurrencyList.CAD.bookVal)}}function _s(t,s){if(t&1&&(l(0,"div"),c(1,"app-value-styler",35),a()),t&2){let e=d(2);i(),o("value",e.grandTotalByCurrencyList.CAD==null?null:e.grandTotalByCurrencyList.CAD.pnlPercent)("colored",!0)("arrow",!0)("small",!0)}}function gs(t,s){if(t&1&&(l(0,"div",32),p(1,"dict"),l(2,"div"),c(3,"app-value-styler",33),v(4,_s,2,4,"div",34),a()()),t&2){let e=d();y("data-header",m(1,4,"orion.holdings.UNREALIZED_GAIN")),i(3),o("value",(e.grandTotalByCurrencyList.CAD==null?null:e.grandTotalByCurrencyList.CAD.pnl)==null?0:e.grandTotalByCurrencyList.CAD==null?null:e.grandTotalByCurrencyList.CAD.pnl)("colored",!0),i(),o("ngIf",e.grandTotalByCurrencyList.CAD==null?null:e.grandTotalByCurrencyList.CAD.pnlPercent)}}function fs(t,s){t&1&&c(0,"div",36)}function ys(t,s){t&1&&c(0,"div",37)}function hs(t,s){t&1&&c(0,"div",38)}var To=(()=>{class t{constructor(e){this.userProfile=e}static{this.\u0275fac=function(n){return new(n||t)(f(O))}}static{this.\u0275cmp=x({type:t,selectors:[["app-holdings-last-business-day-grand-total"]],inputs:{grandTotalByCurrencyList:"grandTotalByCurrencyList"},standalone:!1,decls:31,vars:20,consts:[[1,"or-table"],[1,"or-table-body"],[1,"or-table-row","or-table-header"],[1,"or-table-cell","or-grow-symbol"],[1,"or-table-cell","or-numeric","or-grow-quantity"],[1,"or-table-cell","or-numeric","or-grow-avg-cost"],["class","or-table-cell or-numeric or-grow-book-value",4,"ngIf"],[1,"or-table-cell","or-numeric","or-grow-market-price"],[1,"or-table-cell","or-numeric","or-grow-market-value"],["class","or-table-cell or-numeric or-grow-unrealized-gain",4,"ngIf"],["class","or-table-cell or-numeric or-grow-loan",4,"ngIf"],["class","or-table-cell or-grow-type or-center",4,"ngIf"],["class","or-table-cell or-grow-trade-links",4,"ngIf"],["appCollapsible","",1,"or-table-row","or-table-footer"],[1,"or-table-cell","or-grow-symbol","or-position-1"],[1,"or-h4"],[1,"or-table-cell","or-grow-quantity","or-numeric","or-mobile-hide"],[1,"or-table-cell","or-numeric","or-grow-avg-cost","or-mobile-hide"],["class","or-table-cell or-numeric or-collapsible or-grow-book-value or-position-2",4,"ngIf"],[1,"or-table-cell","or-grow-market-price","or-numeric","or-mobile-hide"],[1,"or-table-cell","or-numeric","or-grow-market-value","or-position-3"],["digits","1.2-2",3,"value"],["class","or-table-cell or-numeric or-collapsible or-grow-unrealized-gain or-position-4",4,"ngIf"],["class","or-table-cell or-numeric or-grow-loan or-mobile-hide",4,"ngIf"],["class","or-table-cell or-numeric or-grow-type or-center or-mobile-hide",4,"ngIf"],["class","or-table-cell or-numeric or-grow-trade-links or-mobile-hide",4,"ngIf"],[1,"or-table-cell","or-numeric","or-grow-book-value"],[1,"or-table-cell","or-numeric","or-grow-unrealized-gain"],[1,"or-table-cell","or-numeric","or-grow-loan"],[1,"or-table-cell","or-grow-type","or-center"],[1,"or-table-cell","or-grow-trade-links"],[1,"or-table-cell","or-numeric","or-collapsible","or-grow-book-value","or-position-2"],[1,"or-table-cell","or-numeric","or-collapsible","or-grow-unrealized-gain","or-position-4"],["digits","1.2-2",3,"value","colored"],[4,"ngIf"],["digits","1.2-2","decorator","#%",3,"value","colored","arrow","small"],[1,"or-table-cell","or-numeric","or-grow-loan","or-mobile-hide"],[1,"or-table-cell","or-numeric","or-grow-type","or-center","or-mobile-hide"],[1,"or-table-cell","or-numeric","or-grow-trade-links","or-mobile-hide"]],template:function(n,r){n&1&&(l(0,"div",0)(1,"div",1)(2,"div",2),c(3,"div",3)(4,"div",4)(5,"div",5),v(6,cs,3,3,"div",6),c(7,"div",7),l(8,"div",8),u(9),p(10,"dict"),a(),v(11,ps,3,3,"div",9)(12,ds,1,0,"div",10)(13,ms,1,0,"div",11)(14,us,1,0,"div",12),a(),l(15,"div",13)(16,"div",14)(17,"div",15),u(18),p(19,"dict"),a()(),c(20,"div",16)(21,"div",17),v(22,vs,3,4,"div",18),c(23,"div",19),l(24,"div",20),p(25,"dict"),c(26,"app-value-styler",21),a(),v(27,gs,5,6,"div",22)(28,fs,1,0,"div",23)(29,ys,1,0,"div",24)(30,hs,1,0,"div",25),a()()()),n&2&&(i(6),o("ngIf",r.userProfile.hasBookValueAccess),i(3),g(" ",m(10,14,"orion.holdings.MARKET_VALUE")," "),i(2),o("ngIf",r.userProfile.hasPNLAccess),i(),o("ngIf",r.userProfile.hasAccessToPortfolioTotalMargin),i(),o("ngIf",r.userProfile.hasTypeAccess),i(),o("ngIf",r.userProfile.hasMinimalTradeAccess),i(4),h(m(19,16,"orion.holdings.GRAND_TOTAL")),i(4),o("ngIf",r.userProfile.hasBookValueAccess),i(2),y("data-header",m(25,18,"orion.holdings.MARKET_VALUE")),i(2),o("value",(r.grandTotalByCurrencyList.CAD==null?null:r.grandTotalByCurrencyList.CAD.marketVal)==null?0:r.grandTotalByCurrencyList.CAD==null?null:r.grandTotalByCurrencyList.CAD.marketVal),i(),o("ngIf",r.userProfile.hasPNLAccess),i(),o("ngIf",r.userProfile.hasAccessToPortfolioTotalMargin),i(),o("ngIf",r.userProfile.hasTypeAccess),i(),o("ngIf",r.userProfile.hasMinimalTradeAccess))},dependencies:[T,te,k,w],encapsulation:2,changeDetection:0})}}return t})();var bs=t=>({value:t});function xs(t,s){if(t&1&&c(0,"app-holdings-last-business-day-header",8),t&2){let e=s.ngIf,n=d(),r=n.$implicit,_=n.index,C=d().ngIf,b=d();o("accountAssetsInfo",r)("showPortfolioNameHeader",b.holdingsService.showPortfolioNameHeaderLastBusinessDay(C,_,e.value))("securityLendingAccount",b.isSecurityLendingAccount(r))("exchangeRates",C.exch
9angeRates)}}function Ss(t,s){if(t&1&&(l(0,"div",9)(1,"div",10),c(2,"app-rate-link",11),a()()),t&2){let e=d().$implicit,n=d().ngIf,r=d();i(2),o("exchangeRate",r.holdingsService.getExchangeRate(n,e))}}function As(t,s){t&1&&c(0,"app-bnc-block-separator",12),t&2&&o("height",8)}function Is(t,s){if(t&1&&(l(0,"div"),v(1,xs,1,4,"app-holdings-last-business-day-header",4),p(2,"async"),c(3,"app-holdings-last-business-day-table",5),v(4,Ss,3,1,"div",6)(5,As,1,1,"app-bnc-block-separator",7),a()),t&2){let e=s.$implicit,n=s.last,r=d(2);i(),o("ngIf",ce(8,bs,m(2,6,r.holdingsService.isMultiRoot$))),i(2),o("currency",r.currency.getSelectedCurrency(e.account.acctNo))("accountAssetsInfo",e)("securityLendingAccount",r.isSecurityLendingAccount(e)),i(),o("ngIf",!r.isSecurityLendingAccount(e)),i(),o("ngIf",!n)}}function Ts(t,s){if(t&1&&c(0,"app-holdings-last-business-day-grand-total",13),t&2){let e=d().ngIf;o("grandTotalByCurrencyList",e==null?null:e.grandTotalByCurrencyList)}}function Es(t,s){if(t&1&&(l(0,"div",1),v(1,Is,6,10,"div",2)(2,Ts,1,1,"app-holdings-last-business-day-grand-total",3),a()),t&2){let e=s.ngIf,n=d();i(),o("ngForOf",e.accountAssetsInfos)("ngForTrackBy",n.trackByAccountAssetsInfos),i(),o("ngIf",(e==null||e.accountAssetsInfos==null?null:e.accountAssetsInfos.length)>1)}}var Po=(()=>{class t{constructor(e,n){this.currency=e,this.holdingsService=n}trackByAccountAssetsInfos(e,n){return n.account.acctNo}isSecurityLendingAccount(e){return Vt(e?.account?.acctNo)}static{this.\u0275fac=function(n){return new(n||t)(f(ge),f(K))}}static{this.\u0275cmp=x({type:t,selectors:[["app-holdings-last-business-day"]],standalone:!1,decls:2,vars:3,consts:[["class","or-content rounded pb-2",4,"ngIf"],[1,"or-content","rounded","pb-2"],[4,"ngFor","ngForOf","ngForTrackBy"],[3,"grandTotalByCurrencyList",4,"ngIf"],[3,"accountAssetsInfo","showPortfolioNameHeader","securityLendingAccount","exchangeRates",4,"ngIf"],[3,"currency","accountAssetsInfo","securityLendingAccount"],["class","or-box",4,"ngIf"],[3,"height",4,"ngIf"],[3,"accountAssetsInfo","showPortfolioNameHeader","securityLendingAccount","exchangeRates"],[1,"or-box"],[1,"or-box-child"],[3,"exchangeRate"],[3,"height"],[3,"grandTotalByCurrencyList"]],template:function(n,r){n&1&&(v(0,Es,3,3,"div",0),p(1,"async")),n&2&&o("ngIf",m(1,1,r.holdingsService.accountAssetsDetailGroupOnLastBusinessDay$))},dependencies:[F,T,at,ct,Ao,Io,To,G],encapsulation:2,changeDetection:0})}}return t})();var Os=(t,s)=>({"lg:mc-pl-xxsmall":t,"lg:mc-pl-medium":s}),Bs=t=>({value:t}),wo=()=>[1,2,3,4];function Ms(t,s){if(t&1&&c(0,"app-holdings-business-day-selector",12),t&2){let e=d();o("mobile",e.mobile)}}function ks(t,s){if(t&1&&(A(0),c(1,"app-account-manager-button"),I()),t&2){let e=d();i(),oe(e.mobile?"":"mc-mr-xsmall mc-ml-medium")}}function Rs(t,s){t&1&&(l(0,"div"),c(1,"app-spinner"),a())}function Ns(t,s){if(t&1&&c(0,"app-holdings-header",21),t&2){let e=s.ngIf,n=d(),r=n.$implicit,_=n.index,C=d(3).ngIf,b=d(2);o("accountAssetsDetail",r)("showPortfolioNameHeader",b.holdingsService.showPortfolioNameHeader(C,_,e.value))("securityLendingAccount",b.isSecurityLendingAccount(r))("exchangeRates",C.exchangeRates)("mobile",b.mobile)("showSecurityLending",!0)}}function Hs(t,s){if(t&1&&(l(0,"div",22)(1,"div",23),c(2,"app-rate-link",24),a()()),t&2){let e=d().$implicit,n=d(3).ngIf,r=d(2);i(2),o("exchangeRate",r.holdingsService.getExchangeRate(n,e))}}function Vs(t,s){t&1&&c(0,"app-bnc-block-separator",25),t&2&&o("height",8)}function Us(t,s){if(t&1&&c(0,"app-holdings-assets-detail-group",26),t&2){let e=d(4).ngIf;o("accountAssetsDetailGroup",e)}}function Fs(t,s){if(t&1&&(l(0,"div"),v(1,Rs,2,0,"div",9),p(2,"async"),v(3,Ns,1,6,"app-holdings-header",16),p(4,"async"),c(5,"app-holdings-assets-detail",17),v(6,Hs,3,1,"div",18)(7,Vs,1,1,"app-bnc-block-separator",19)(8,Us,1,1,"app-holdings-assets-detail-group",20),a()),t&2){let e=s.$implicit,n=s.index,r=s.last,_=d(3).ngIf,C=d(2);i(),o("ngIf",n==0&&m(2,9,C.selectionAccount$).length!=_.accountAssetDetailList.length),i(2),o("ngIf",ce(13,Bs,m(4,11,C.holdingsService.isMultiRoot$))),i(2),o("currency",C.currency.getSelectedCurrency(e.account.acctNo))("accountAssetsDetail",e)("accountAssetsDetailGroup",_)("securityLendingAccount",C.isSecurityLendingAccount(e)),i(),o("ngIf",!C.isSecurityLendingAccount(e)),i(),o("ngIf",!r),i(),o("ngIf",r)}}function Gs(t,s){if(t&1&&(A(0),l(1,"div",13),v(2,Fs,9,15,"div",14),c(3,"app-investcube-info",15),a(),I()),t&2){let e=d(2).ngIf,n=d(2);i(2),o("ngForOf",e.accountAssetDetailList)("ngForTrackBy",n.trackByAccountAssetsDetail)}}function js(t,s){t&1&&(A(0),c(1,"app-holdings-last-business-day"),I())}function Qs(t,s){if(t&1&&(A(0),v(1,Gs,4,2,"ng-container",9)(2,js,2,0,"ng-container",9),I()),t&2){let e=s.ngIf,n=d(3);i(),o("ngIf",e===n.holdingBusinessDayEnum.AS_OF_TODAY),i(),o("ngIf",e===n.holdingBusinessDayEnum.AS_OF_LAST_BUSINESS_DAY)}}function $s(t,s){t&1&&ze(0)}function qs(t,s){if(t&1&&(l(0,"div")(1,"div",27),v(2,$s,1,0,"ng-container",28),a()()),t&2){d(3);let e=E(15);i(2),o("ngTemplateOutlet",e)}}function Ys(t,s){if(t&1&&(A(0),v(1,Qs,3,2,"ng-container",9),p(2,"async"),v(3,qs,3,1,"div",9),I()),t&2){let e=s.ngIf,n=d().ngIf,r=d();i(),o("ngIf",m(2,2,r.selectedBusinessDay$)),i(2),o("ngIf",n!=e.accountAssetDetailList.length)}}function zs(t,s){if(t&1&&(A(0),c(1,"app-micro-frontend",29),I()),t&2){let e=d(2);i(),o("props",e.mfeProps)("isShowLoading",!1)}}function Ks(t,s){if(t&1&&(l(0,"div"),v(1,Ys,4,4,"ng-container",11),p(2,"async"),v(3,zs,2,2,"ng-container",9),a()),t&2){let e=d(),n=E(15);i(),o("ngIf",m(2,3,e.holdingsService.accountAssetsDetailGroup$))("ngIfElse",n),i(2),o("ngIf",e.activateFPLOnAllAccounts&&e.isCDBNClient)}}function Ws(t,s){t&1&&(l(0,"div",33),c(1,"app-skeleton"),a())}function Zs(t,s){t&1&&(l(0,"div",31)(1,"div",32),v(2,Ws,2,0,"div",36),a()()),t&2&&(i(2),o("ngForOf",
9Ke(1,wo)))}function Xs(t,s){t&1&&(l(0,"div",30)(1,"div",31)(2,"div",32)(3,"div",33),c(4,"app-skeleton",34),a()(),l(5,"div",32)(6,"div",33),c(7,"app-skeleton"),a()()(),v(8,Zs,3,2,"div",35),a()),t&2&&(i(8),o("ngForOf",Ke(1,wo)))}function Js(t,s){t&1&&c(0,"div")}var Lo=(()=>{class t extends Q{constructor(e,n,r,_,C,b,M){super(),this.userProfile=e,this.currency=n,this.holdingsService=r,this.breakpointObserver=_,this.store=C,this.userInfoService=b,this.featureFlagsService=M,this.RefreshedPage=Z,this.mobile=!1,this.BncIconColor=rn,this.BncIconKey=ot,this.BncIconSize=Nt}ngOnInit(){this.holdingsService.init(),this.breakpointObserver.observe([re.MOBILE]).pipe(W(this.destroyed$)).subscribe(e=>{this.mobile=e.matches}),this.selectedBusinessDay$=this.store.select(ni),this.selectionAccount$=this.store.pipe(R(dn)),this.activateFPLOnAllAccounts=this.featureFlagsService.isEnabled("fpl",Be),this.isCDBNClient=!this.userInfoService.isRep&&this.userProfile.isCDBNUser,this.mfeProps={subAppToRender:2,functionCodes:{hasLoanRevenueAccess:this.userProfile.hasLoanRevenueAccess,hasUpdateStatusAccess:this.userProfile.hasUpdateStatusAccess},userId:this.userInfoService.userInfo?.user.userId}}trackByAccountAssetsDetail(e,n){return n.account.acctNo}isSecurityLendingAccount(e){return Vt(e?.account?.acctNo)}get holdingBusinessDayEnum(){return Ct}static{this.\u0275fac=function(n){return new(n||t)(f(O),f(ge),f(K),f(ae),f(j),f(Ae),f(Se))}}static{this.\u0275cmp=x({type:t,selectors:[["app-holdings"]],standalone:!1,features:[xe([K,$]),q],decls:18,vars:20,consts:[["skeleton",""],["noData",""],["id","content","tabindex","-1"],[1,"or-heading"],[3,"ngClass"],["class","mc-pb-xxsmall lg:mc-pb-0 lg:mc-pl-xsmall",3,"mobile",4,"ngIf"],[1,"mc-pb-xxsmall","lg:mc-pb-0",3,"mobile","ngClass"],[1,"mc-d-flex",3,"panelClass","pageId","showDisclaimer"],[1,"lg:mc-ml-auto","mc-ml-0","lg:mc-pt-0","mc-pt-normal","mc-d-flex","mc-align-items-center","mc-justify-content-between"],[4,"ngIf"],[3,"mobile"],[4,"ngIf","ngIfElse"],[1,"mc-pb-xxsmall","lg:mc-pb-0","lg:mc-pl-xsmall",3,"mobile"],[1,"or-content","rounded","mc-pb-xsmall"],[4,"ngFor","ngForOf","ngForTrackBy"],["styleClass","mc-d-flex mc-pt-xsmall"],[3,"accountAssetsDetail","showPortfolioNameHeader","securityLendingAccount","exchangeRates","mobile","showSecurityLending",4,"ngIf"],[3,"currency","accountAssetsDetail","accountAssetsDetailGroup","securityLendingAccount"],["class","or-box",4,"ngIf"],[3,"height",4,"ngIf"],[3,"accountAssetsDetailGroup",4,"ngIf"],[3,"accountAssetsDetail","showPortfolioNameHeader","securityLendingAccount","exchangeRates","mobile","showSecurityLending"],[1,"or-box"],[1,"or-box-child"],[3,"exchangeRate"],[3,"height"],[3,"accountAssetsDetailGroup"],[1,"mc-mt-small"],[4,"ngTemplateOutlet"],["appName","fpl","withErrorHandling","true",3,"props","isShowLoading"],[1,"or-content","rounded"],[1,"mc-w-75"],[1,"mc-d-flex"],[1,"mc-w-25vw","mc-mr-small"],["size","medium"],["class","mc-w-75",4,"ngFor","ngForOf"],["class","mc-w-25vw mc-mr-small",4,"ngFor","ngForOf"]],template:function(n,r){if(n&1&&(l(0,"div",2)(1,"div",3)(2,"div",4)(3,"h1",4),u(4),p(5,"dict"),a(),v(6,Ms,1,1,"app-holdings-business-day-selector",5),c(7,"app-widget-bar",6)(8,"app-refresh",7),l(9,"div",8),v(10,ks,2,2,"ng-container",9),c(11,"app-compact-view-toggle",10),a()()(),v(12,Ks,4,5,"div",11),p(13,"async"),a(),v(14,Xs,9,2,"ng-template",null,0,P)(16,Js,1,0,"ng-template",null,1,P)),n&2){let _=E(17);i(2),o("ngClass",r.mobile?"d-flex flex-column pb-1":"d-inline-flex align-items-center py-3 w-100"),i(),o("ngClass",r.mobile?"or-font-24 my-0 pb-1":"h1-title-compact-theme m-0"),i(),h(m(5,13,"orion.menu.HOLDINGS")),i(2),o("ngIf",r.userInfoService.isRep&&r.userProfile.hasAccessAccountHoldingsLastBusinessDay),i(),o("mobile",r.userInfoService.isRep?!0:r.mobile)("ngClass",se(17,Os,r.userInfoService.isRep,!r.userInfoService.isRep)),i(),o("panelClass","lg:mc-pl-xsmall")("pageId",r.RefreshedPage.ACCOUNTS_HOLDINGS)("showDisclaimer",!0),i(2),o("ngIf",r.isCDBNClient),i(),o("mobile",r.mobile),i(),o("ngIf",m(13,15,r.selectionAccount$).length)("ngIfElse",_)}},dependencies:[X,F,T,Pt,lt,Gt,at,Wt,Ue,ct,gn,ao,jt,zn,Xn,fo,ho,pi,Po,G,w],encapsulation:2,changeDetection:0})}}return t})();var vt=(()=>
9{class t{constructor(){this.chartPeriodSelection=new Map,this.list=[{value:_e.TWO_DAYS,label:"orion.period-selector.TWO_DAYS"},{value:_e.FIVE_DAYS,label:"orion.period-selector.FIVE_DAYS"},{value:_e.ONE_MONTH,label:"orion.period-selector.ONE_MONTH"},{value:_e.ONE_YEAR,label:"orion.period-selector.FIFTY_TWO_WEEKS"}]}createChartPeriodList(e){this.chartPeriodSelection[e]={selected:_e.TWO_DAYS,list:this.list}}getSelectedPeriodChart(e){return this.chartPeriodSelection[e]}getPeriodSelection(e){let n=this.getSelectedPeriodChart(e);return n!=null?n.selected:null}isPeriodTwoDays(e){return this.getPeriodSelection(e)===_e.TWO_DAYS}getLabelFromValue(e){return this.list.filter(n=>n.value===e)[0].label}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275prov=ve({token:t,factory:t.\u0275fac})}}return t})();var ec=2,_t=(()=>{class t{constructor(e,n,r,_,C){this.historicalQuotesApiService=e,this.periodSelectionService=n,this.holdingsService=r,this.store=_,this.refreshService=C,this.RefreshedPage=Z}init(){this.holdingsService.init(),this.refreshService.initTime(Z.ACCOUNTS_QUOTE_GRAPH),this.accountAssetsDetailGroup$=this.store.pipe(R(Pe,Z.ACCOUNTS_QUOTE_GRAPH)).pipe(Ye(()=>this.holdingsService.accountAssetsDetailGroup$.pipe(Fi(e=>{if(e)return e.accountAssetDetailList.forEach(n=>{this.periodSelectionService.createChartPeriodList(n.account.acctNo),this.initChartObservables(n,!1)}),e}))))}initChartObservables(e,n=!0){Object.keys(e.assetsDetailByCurrencyList).forEach(_=>{let C=e.assetsDetailByCurrencyList[_];(n||!C.histoFetcher$)&&(this.createHistoFetcher(e.account,C),this.attachChartObservables(C))})}createHistoFetcher(e,n){let r=n.positionList;n.histoFetcher$=Ri(r).pipe(At(_=>this.fetchHistoricalQuotes$(_.finInstrument,e),ec),gi(1))}attachChartObservables(e){e.positionList.forEach(r=>{let _=r,C=this.getHistoricalQuotes$(r.finInstrument.quoteIdKey,e.histoFetcher$);_.quoteInformation$=C.pipe(ne(b=>b)),_.chartSparkData$=C.pipe(ne(b=>{let M=new eo;return b.ticksList?(M.points=b.ticksList.map(ue=>ue.lastPrice),M.plotLine=M.points[0]):(M.points=[],M.plotLine=b.previousClosedPrice),M}))})}getHistoricalQuotes$(e,n){return n.pipe(Ui(C=>C[0]===e),Ni(C=>C!=null),ne(C=>C[1]),gi(1))}fetchHistoricalQuotes$(e,n){let r=this.periodSelectionService.getPeriodSelection(n.acctNo);if(e.quoteIdKey!=null){let _={currencyCd:e.marketSymbol.symbolCurrCd,period:r,resolution:this.getResolution(e,r),omitTicks:!1,minInfos:!0};return this.historicalQuotesApiService.getHistoricalQuotes(e,_).pipe(ne(C=>[e.quoteIdKey,C]))}return ki}getResolution(e,n){let r;switch(n){case _e.TWO_DAYS:r=We.MINUTE_15;break;case _e.FIVE_DAYS:e.finInstrumentCatCd==="FI"?r=We.DAY:r=We.HOUR;break;case _e.ONE_MONTH:e.finInstrumentCatCd==="FI"?r=We.DAY:r=We.HOUR_4;break;case _e.ONE_YEAR:r=We.WEEK;break}return r}static{this.\u0275fac=function(n){return new(n||t)(B(jn),B(vt),B(K),B(j),B(Re))}}static{this.\u0275prov=ve({token:t,factory:t.\u0275fac})}}return t})();var tc=(t,s)=>({canBuy:t,canSell:s});function ic(t,s){if(t&1){let e=V();l(0,"app-dropdown",27),p(1,"dict"),U("selectionChange",function(){N(e);let r=d();return H(r.quoteGraphService.initChartObservables(r.accountAssetsDetail))}),a()}if(t&2){let e=d();me("aria-label",m(1,2,"orion.quote-graph.FREQUENCY")),o("selectionHolder",e.periodSelectionService.getSelectedPeriodChart(e.accountAssetsDetail.account.acctNo))}}function nc(t,s){if(t&1&&(l(0,"div",28),u(1,"Type"),a()),t&2){let e=d();o("appSortService",e.sort)("group",e.accountAssetsDetail.account.acctNo)}}function oc(t,s){t&1&&c(0,"div",29)}function rc(t,s){if(t&1&&c(0,"app-value-styler",51),t&2){let e,n=d(2).$implicit,r=d();o("value",(e=r.holdingsService.getPositionInSymbolCurrency(r.accountAssetsDetail,n))==null?null:e.positionEval.dayChangeUnitPrice)("colored",!0)("small",!0)}}function ac(t,s){if(t&1&&c(0,"app-value-styler",52),t&2){let e,n=d(2).$implicit,r=d();o("value",(e=r.holdingsService.getPositionInSymbolCurrency(r.accountAssetsDetail,n))==null?null:e.positionEval.dayChangeUnitPricePerc)("colored",!0)("arrow",!0)("small",!0)}}function lc(t,s){if(t&1&&(l(0,"div",48),v(1,rc,1,3,"app-value-styler",49)(2,ac,1,4,"app-value-styler",50),a()),t&2){let e=d().$implicit;i(),o("ngIf",e.positionEval.dayChangeUnitPrice),i(),o("ngIf",e.positionEval.dayChangeUnitPricePerc)}}function sc(t,s){if(t&1&&(l(0,"div"),c(1,"div",53),p(2,"valueShortener"),c(3,"div",38),p(4,"valueShortener"),a()),t&2){let e=d().$implicit;i(),o("innerHTML",m(2,2,e.volume),S),i(2),o("innerHTML",m(4,4,e.averageVolume30Days),S)}}function cc(t,s){if(t&1&&(A(0),c(1,"app-day-range",54),I()),t&2){let e=d().ngIf;i(),o("quoteInfo",e)}}function pc(t,s){t&1&&u(0,"-")}function dc(t,s){if(t&1&&(A(0),v(1,cc,2,1,"ng-container",45)(2,pc,1,0,"ng-template",null,1,P),I()),t&2){let e=s.ngIf,n=E(3);i(),o("ngIf",e.lowPrice&&e.highPrice)("ngIfElse",n)}}function mc(t,s){t&1&&u(0,"-")}function uc(t,s){t&1&&(A(0),v(1,mc,1,0,"ng-template"),I())}
9function vc(t,s){t&1&&c(0,"app-spinner")}function _c(t,s){if(t&1&&v(0,uc,2,0,"ng-container",45)(1,vc,1,0,"ng-template",null,2,P),t&2){let e=E(2),n=d().$implicit,r=d();o("ngIf",!r.symbolLinkService.isClickable(n.finInstrument,n.securityType))("ngIfElse",e)}}function gc(t,s){if(t&1&&(c(0,"div",55),p(1,"dict")),t&2){let e=d().$implicit;o("innerHTML",e.finInstrument.finInstrumentCatLabel,S),y("data-header",m(1,2,"orion.quote-graph.TYPE"))}}function fc(t,s){if(t&1&&(l(0,"div",56)(1,"div",57)(2,"div",58),c(3,"app-trade-links",59),a()()()),t&2){let e=d().$implicit,n=d();i(3),o("finInstrument",e.finInstrument)("acctNo",n.accountAssetsDetail.account.acctNo)("quantity",e.quantity)("access",se(4,tc,e.tradeAccess.buyAllowed,e.tradeAccess.sellAllowed))}}function yc(t,s){if(t&1&&(l(0,"div")(1,"div",30)(2,"div",31),p(3,"dict"),c(4,"app-account-symbol-link",32),a(),l(5,"div",33),p(6,"dict"),l(7,"div"),c(8,"app-value-styler",34),l(9,"div",35),v(10,lc,3,2,"div",36),a()()(),l(11,"div",37),p(12,"dict"),l(13,"div"),c(14,"app-value-styler",34)(15,"div",38),p(16,"valueShortener"),a()(),l(17,"div",39),p(18,"dict"),l(19,"div"),c(20,"app-value-styler",34)(21,"div",38),p(22,"valueShortener"),a()(),l(23,"div",40),p(24,"dict"),v(25,sc,5,6,"div",41),a(),l(26,"div",42),c(27,"app-chart-spark",43),a(),l(28,"div",44),v(29,dc,4,2,"ng-container",45),p(30,"async"),v(31,_c,3,2,"ng-template",null,0,P),a(),v(33,gc,2,4,"div",46)(34,fc,4,7,"div",47),a()()),t&2){let e,n,r,_=s.$implicit,C=E(32),b=d();i(2),y("data-header",m(3,23,"orion.quote-graph.SYMBOL")),i(2),o("position",_)("account",b.accountAssetsDetail.account),i(),y("data-header",m(6,25,"orion.quote-graph.MARKET_PRICE")),i(3),o("value",(e=b.holdingsService.getPositionInSymbolCurrency(b.accountAssetsDetail,_))==null?null:e.positionEval.evalPrice),i(2),o("ngIf",_.positionEval.dayChangeInd),i(),y("data-header",m(12,27,"orion.quote-graph.BID")),i(3),o("value",(n=b.holdingsService.getPositionInSymbolCurrency(b.accountAssetsDetail,_))==null?null:n.positionEval.bidPrice),i(),o("innerHTML",m(16,29,_.bidSize),S),i(2),y("data-header",m(18,31,"orion.quote-graph.ASK")),i(3),o("value",(r=b.holdingsService.getPositionInSymbolCurrency(b.accountAssetsDetail,_))==null?null:r.positionEval.askPrice),i(),o("innerHTML",m(22,33,_.askSize),S),i(2),y("data-header",m(24,35,"orion.quote-graph.VOLUME")),i(2),o("ngIf",_.finInstrument.quoteIdKey!=null),i(2),o("data$",_.chartSparkData$)("isQuoteAndGraph",!0)("previousDayFaded",b.periodSelectionService.isPeriodTwoDays(b.accountAssetsDetail.account.acctNo))("intraDay",!0)("chartId",b.accountAssetsDetail.account.acctNo+"-"+_.finInstrument.finInstrumentId),i(2),o("ngIf",m(30,37,_.quoteInformation$))("ngIfElse",C),i(4),o("ngIf",b.userProfile.hasTypeAccess),i(),o("ngIf",b.userProfile.hasMinimalTradeAccess||b.holdingsService.hasTradeAccess(_.finInstrument))}}var Mo=(()=>{class t{constructor(e,n,r,_,C,b,M){this.sort=e,this.holdingsService=n,this.periodSelectionService=r,this.quoteGraphService=_,this.userProfile=C,this.searchBarRepService=b,this.symbolLinkService=M}ngOnInit(){this.sort.setOrderBy("finInstrument.displayDesc",this.accountAssetsDetail.account.acctNo,"orderBy")}ngOnChanges(){this.assetsDetails=this.accountAssetsDetail.assetsDetailByCurrencyList[this.accountAssetsDetail.account.acctCurrCd]}trackByPosition(e,n){return n.finInstrument.finInstrumentId}static{this.\u0275fac=function(n){return new(n||t)(f($),f(K),f(vt),f(_t),f(O),f(pt),f(ti))}}static{this.\u0275cmp=x({type:t,selectors:[["app-quote-graph-assets-detail"]],inputs:{accountAssetsDetail:"accountAssetsDetail"},standalone:!1,features:[Je],decls:49,vars:67,consts:[["showSpinnerOrDash",""],["showMinus",""],["showSpinner",""],[1,"or-table"],[1,"or-table-body"],["appSticky","",1,"or-table-row","or-table-header",3,"offsetTop"],[1,"or-table-cell","or-grow-qg-symbol"],["href","javascript:void(0)","key","finInstrument.marketSymbol.symbolCd",3,"appSortService","group"],["href","javascript:void(0)","key","finInstrument.displayDesc",3,"appSortService","group"],[1,"or-table-cell","or-numeric"],["href","javascript:void(0)","key","positionEval.evalPrice",3,"appSortService","group"],["href","javascript:void(0)","key","positionEval.dayChangeUnitPrice",3,"appSortService","group"],[1,"or-table-cell","or-numeric","or-grow-qg-bid"],["href","javascript:void(0)","key","positionEval.bidPrice",3,"appSortService","group"],["href","javascript:void(0)","key","bidSize",3,"appSortService","group"],[1,"or-table-cell","or-numeric","or-grow-qg-ask"],["href","javascript:void(0)","key","positionEval.askPrice",3,"appSortService","group"],["href","javascript:void(0)","key","askSize",3,"appSortService","group"],[1,"or-table-cell","or-numeric","or-grow-qg-volume"],["href","javascript:void(0)","key","volume",3,"appSortService","group"],["href","javascript:void(0)","key","averageVolume30Days",3,"appSortService","group"],[1,"or-table-cell","or-grow-qg-chart-spark"],["styleClass","or-narrow",3,"aria-label","selectionHolder","selectionChange",4,"ngIf"],[1,"or-table-cell","or-grow-qg-day-range"],["class","or-table-cell or-grow-qg-type","key","finInstrument.finInstrumentCatLabel",3,"appSortService","group",4,"ngIf"],["class","or-table-cell or-right or-grow-qg-trade-links",4,"ngIf"],[4,"ngFor","ngForOf","ngForTrackBy"],["styleClass","or-narrow",3,"selectionChange","aria-label","selectionHolder"],["key","finInstrument.finInstrumentCatLabel",1,"or-table-cell","or-grow-qg-type",3,"appSortService","group"],[1,"or-table-cell","or-right","or-grow-qg-trade-links"],["appCollapsible","",1,"or-table-row","or-list-height"],[1,"or-table-cell","or-position-1","or-grow-qg-symbol","text-truncate"],[1,"text-truncate",3,"position","account"],[1,"or-table-cell","or-numeric","or-mobile-hide"],["digits","1.2-2",3,"value"],[1,"or-box","or-no-padding"],["class","or-box-child or-small-gap or-no-padding",4,"ngIf"],[1,"or-table-cell","or-numeric","or-collapsible","or-position-5","or-grow-qg-bid"],[1,"or-label_small",3,"innerHTML"],[1,"or-table-cell","or-numeric","or-collapsible","or-position-6","or-grow-qg-ask"],[1,"or-table-cell","or-numeric","or-position-8","or-collapsible","or-grow-qg-volume"],[4,"ngIf"],[1,"or-table-cell","or-collapsible","or-position-3","or-grow-qg-chart-spark"],[3,"data$","isQuoteAndGraph","previousDayFaded","intraDay","chartId"],[1,"or-table-cell","or-flex-full","or-center","or-position-4","or-grow-qg-day-range"],[4,"ngIf","ngIfElse"],["class","or-table-cell or-numeric or-position-7 or-collapsible or-grow-qg-type",3,"innerHTML",4,"ngIf"],["class","or-table-cell or-position-9 or-collapsible or-right or-flex-full or-grow-qg-trade-links",4,"ngIf"],[1,"or-box-child","or-small-gap","or-no-padding"],["digits","1.2-2",3,"value","colored","small",4,"ngIf"],["digits","1.2-2","decorator","(#%)",3,"value","colored","arrow","small",4,"ngIf"],["digits","1.2-2",3,"value","colored","small"],["digits","1.2-2","decorator","(#%)",3,"value","colored","arrow","small"],[3,"innerHTML"],[3,"quoteInfo"],[1,"or-table-cell","or-numeric","or-position-7","or-collapsible","or-grow-qg-type",3,"innerHTML"],[1,"or-table-cell","or-position-9","or-collapsible","or-right","or-flex-full","or-grow-qg-trade-links"],[1,"or-box","or-no-padding","or-box-content-center"],[1,"or-box-child"],[3,"finInstrument","acctNo","quantity","access"]],template:function(n,r){n&1&&(l(0,"div",3)(1,"div",4)(2,"div",5),p(3,"async"),l(4,"div",6)(5,"a",7),u(6),p(7,"dict"),a(),l(8,"a",8),u(9),p(10,"dict"),a()(),l(11,"div",9)(12,"a",10),u(13),p(14,"dict"),a(),l(15,"a",11),u(16),p(17,"dict"),a()(),l(18,"div",12)(19,"a",13),u(20),p(21,"dict"),a(),l(22,"a",14),u(23),p(24,"dict"),a()(),l(25,"div",15)(26,"a",16),u(27),p(28,"dict"),a(),l(29,"a",17),u(30),p(31,"dict"),a()(),l(32,"div",18)(33,"a",19),u(34),p(35,"dict"),a(),l(36,"a",20),u(37),p(38,"dict"),a()(),l(39,"div",21),v(40,ic,2,4,"app-dropdown",22),a(),l(41,"div",23),u(42),p(43,"dict"),p(44,"dict"),a(),v(45,nc,2,2,"div",24)(46,oc,1,0,"div",25),a(),v(47,yc,35,39,"div",26),p(48,"orderBy"),a()()),n&2&&(i(2),o("offsetTop",m(3,38,r.searchBarRepService.searchBarHeight$)),i(3),o("appSortService",r.sort)("group",r.accountAssetsDetail.account.acctNo),i(),h(m(7,40,"orion.quote-gra
9ph.SYMBOL")),i(2),o("appSortService",r.sort)("group",r.accountAssetsDetail.account.acctNo),i(),g("/ ",m(10,42,"orion.quote-graph.DESCRIPTION")),i(3),o("appSortService",r.sort)("group",r.accountAssetsDetail.account.acctNo),i(),h(m(14,44,"orion.quote-graph.MARKET_PRICE")),i(2),o("appSortService",r.sort)("group",r.accountAssetsDetail.account.acctNo),i(),g("/ ",m(17,46,"orion.quote-graph.DAY_CHANGE")," $ (%)"),i(3),o("appSortService",r.sort)("group",r.accountAssetsDetail.account.acctNo),i(),h(m(21,48,"orion.quote-graph.BID")),i(2),o("appSortService",r.sort)("group",r.accountAssetsDetail.account.acctNo),i(),g(" (",m(24,50,"orion.quote-graph.SIZE"),")"),i(3),o("appSortService",r.sort)("group",r.accountAssetsDetail.account.acctNo),i(),h(m(28,52,"orion.quote-graph.ASK")),i(2),o("appSortService",r.sort)("group",r.accountAssetsDetail.account.acctNo),i(),g(" (",m(31,54,"orion.quote-graph.SIZE"),")"),i(3),o("appSortService",r.sort)("group",r.accountAssetsDetail.account.acctNo),i(),h(m(35,56,"orion.quote-graph.VOLUME")),i(2),o("appSortService",r.sort)("group",r.accountAssetsDetail.account.acctNo),i(),g("/ ",m(38,58,"orion.quote-graph.AVG")),i(3),o("ngIf",r.periodSelectionService.getSelectedPeriodChart(r.accountAssetsDetail.account.acctNo)),i(2),Et(" ",m(43,60,"orion.quote-graph.LOW_HIGH")," (",m(44,62,r.periodSelectionService.getLabelFromValue(r.periodSelectionService.getSelectedPeriodChart(r.accountAssetsDetail.account.acctNo).selected)),") "),i(3),o("ngIf",r.userProfile.hasTypeAccess),i(),o("ngIf",r.userProfile.hasMinimalTradeAccess),i(),o("ngForOf",D(48,64,r.assetsDetails.positionList,r.sort.orderBy(r.accountAssetsDetail.account.acctNo)))("ngForTrackBy",r.trackByPosition))},dependencies:[F,T,ke,Ee,Jt,Gt,te,k,st,wn,Ln,ut,G,Vn,fe,w],styles:[".or-table-cell.or-grow-qg-symbol[_ngcontent-%COMP%]{flex-grow:1.2!important}.or-table-cell.or-grow-qg-opposite-currency[_ngcontent-%COMP%]{flex-grow:.2!important}.or-table-cell.or-grow-qg-market-value[_ngcontent-%COMP%]{flex-grow:.7!important}.or-table-cell.or-grow-qg-bid[_ngcontent-%COMP%], .or-table-cell.or-grow-qg-ask[_ngcontent-%COMP%]{flex-grow:.35!important}.or-table-cell.or-grow-qg-volume[_ngcontent-%COMP%], .or-table-cell.or-grow-qg-chart-spark[_ngcontent-%COMP%], .or-table-cell.or-grow-qg-day-range[_ngcontent-%COMP%]{flex-grow:.7!important}.or-table-cell.or-grow-qg-type[_ngcontent-%COMP%]{flex-grow:.2!important}.or-table-cell.or-grow-qg-trade-links[_ngcontent-%COMP%]{flex-grow:1!important}"],changeDetection:0})}}return t})();var Cc=t=>({value:t});function bc(t,s){if(t&1&&c(0,"app-holdings-header",13),t&2){let e=s.ngIf,n=d(),r=n.$implicit,_=n.index,C=d().ngIf,b=d();o("accountAssetsDetail",r)("showCurrencyDropdown",!1)("showPortfolioNameHeader",b.holdingsService.showPortfolioNameHeader(C,_,e.value))("exchangeRates",C.exchangeRates)("mobile",b.mobile)("showSecurityLending",!1)}}function xc(t,s){t&1&&c(0,"div",14)}function Sc(t,s){if(t&1&&(l(0,"div"),v(1,bc,1,6,"app-holdings-header",9),p(2,"async"),c(3,"app-quote-graph-assets-detail",10)(4,"app-rate-link",11),v(5,xc,1,0,"div",12),a()),t&2){let e=s.$implicit,n=s.last,r=d().ngIf,_=d();i(),o("ngIf",ce(6,Cc,m(2,4,_.holdingsService.isMultiRoot$))),i(2),o("accountAssetsDetail",e),i(),o("exchangeRate",_.holdingsService.getExchangeRate(r,e)),i(),o("ngIf",!n)}}function Ac(t,s){if(t&1&&(l(0,"div",6),v(1,Sc,6,8,"div",7),c(2,"app-investcube-info",8),a()),t&2){let e=s.ngIf,n=d();i(),o("ngForOf",e.accountAssetDetailList)("ngForTrackBy",n.trackByAccountAssetsDetail)}}var ko=(()=>{class t extends Q{constructor(e,n,r,_,C,b){super(),this.sort=e,this.holdingsService=n,this.quoteGraphService=r,this.currency=_,this.userProfile=C,this.breakpointObserver=b,this.RefreshedPage=Z,this.mobile=!1}ngOnInit(){this.quoteGraphService.init(),this.breakpointObserver.observe([re.MOBILE]).pipe(W(this.destroyed$)).subscribe(e=>{this.mobile=e.matches})}trackByAccountAssetsDetail(e,n){return n.account.acctNo}static{this.\u0275fac=function(n){return new(n||t)(f($),f(K),f(_t),f(ge),f(O),f(ae))}}static{this.\u0275cmp=x({type:t,selectors:[["app-quote-graph"]],standalone:!1,features:[xe([K,_t,$]),q],decls:10,vars:10,consts:[["id","content","tabindex","-1"],[1,"or-heading"],[3,"ngClass"],[1,"pb-1","pb-lg-0","pl-lg-4",3,"mobile"],[1,"d-flex",3,"pageId"],["class","or-content roun
9ded",4,"ngIf"],[1,"or-content","rounded"],[4,"ngFor","ngForOf","ngForTrackBy"],["styleClass","d-flex pt-2"],[3,"accountAssetsDetail","showCurrencyDropdown","showPortfolioNameHeader","exchangeRates","mobile","showSecurityLending",4,"ngIf"],[3,"accountAssetsDetail"],[3,"exchangeRate"],["class","or-separator",4,"ngIf"],[3,"accountAssetsDetail","showCurrencyDropdown","showPortfolioNameHeader","exchangeRates","mobile","showSecurityLending"],[1,"or-separator"]],template:function(n,r){n&1&&(l(0,"div",0)(1,"div",1)(2,"div",2)(3,"h1",2),u(4),p(5,"dict"),a(),c(6,"app-widget-bar",3)(7,"app-refresh",4),a()(),v(8,Ac,3,2,"div",5),p(9,"async"),a()),n&2&&(i(2),o("ngClass",r.mobile?"d-flex flex-column pb-1":"d-inline-flex align-items-center py-3"),i(),o("ngClass",r.mobile?"or-font-24 my-0 pb-1":"or-font-36 m-0"),i(),h(m(5,6,"orion.menu.QUOTE_GRAPH")),i(2),o("mobile",r.mobile),i(),o("pageId",r.RefreshedPage.ACCOUNTS_QUOTE_GRAPH),i(),o("ngIf",m(9,8,r.quoteGraphService.accountAssetsDetailGroup$)))},dependencies:[X,F,T,lt,at,Wt,Ue,Mo,pi,G,w],encapsulation:2,changeDetection:0})}}return t})();var di=(()=>{class t{constructor(e,n,r,_,C,b,M){this.featureFlagsService=e,this.dict=n,this.http=r,this.store=_,this.pieChartBreakdownService=C,this.refreshService=b,this.userProfileService=M,this.type="CLASS",this.RefreshedPage=Z,this.showErrorSubject=new St(!1),this.showError$=this.showErrorSubject.asObservable(),this.activateAssetAllocationPatch=this.featureFlagsService.isEnabled("portfolio",tn)}init(){this.showErrorSubject.next(!1),this.initAssetTypes(),this.refresh()}refresh(e){this.refreshService.initTime(Z.ACCOUNTS_ASSET_ALLOCATION),this.assetAllocations$=qe([this.store.pipe(R(Pe,Z.ACCOUNTS_ASSET_ALLOCATION)),this.store.pipe(R(Me))]).pipe(Ye(([,n])=>this.readAssetAllocation(n,e)))}color(e,n){let r="",_=e.pieChartData.find(C=>C.name===this.getAssetAllocationCatCd(n.assetAllocationCatCd));return _&&(r=_.color),r}getAssetAllocationCatCd(e){let n=e;return this.type==="CLASS"&&(n=this.dict.entry("orion.asset-allocation.ASSET_CLASS_"+e)),n}typeChange(e){this.type=e,this.refresh(e)}readAssetAllocation(e,n){let r=ht(e),_=Ce({},Ht(r));this.userProfileService.hasAccessQuoteRealTime&&(_.realtimePrice="true");let b=n&&n!=="CLASS"?"/assetsAlloc/sectors":"/assetsAlloc/classes";return this.showErrorSubject.next(!1),this.http.get(b,{params:Ce({},_)}).pipe(ne(({data:M})=>{let ue=this.toPieChartBreakdownData(M.assetsAllocation);return M.pieChartData=this.pieChartBreakdownService.updatePieChartData(ue,!1),M}),Hi(()=>(this.showErrorSubject.next(!0),$e(null))))}toPieChartBreakdownData(e){return(e||[]).map(n=>new Mn(this.getAssetAllocationCatCd(n.assetAllocationCatCd),this.activateAssetAllocationPatch?this.selectDataToGenerateChart(n):n.marketValPerc))}selectDataToGenerateChart(e){return this.isSector()?e.marketValPerc:e.marketValuePercentage}getAssetTypes(){return[{value:"CLASS",label:"orion.asset-allocation.ASSET_CLASS"},{value:"SECTOR",label:"orion.asset-allocation.ASSET_SECTOR"}]}initAssetTypes(){this.assetTypes={selected:null,list:this.getAssetTypes()}}getLabel(){let e="";return this.type==="SECTOR"?e="orion.asset-allocation.ASSET_SECTOR":this.type==="CLASS"&&(e="orion.asset-allocation.ASSET_CLASS"),e}isSector(){return this.type==="SECTOR"}static{this.\u0275fac=function(n){return new(n||t)(B(Se),B(J),B(it),B(j),B(kn),B(Re),B(O))}}static{this.\u0275prov=ve({token:t,factory:t.\u0275fac})}}return t})();function Tc(t,s){if(t&1&&(l(0,"a",11),u(1),a()),t&2){let e=d();o("appSortService",e.sort),i(),g(" ",e.dict.entry("orion.holdings.DESCRIPTION")," ")}}function Ec(t,s){if(t&1&&(l(0,"a",12),u(1),a()),t&2){let e=d();o("appSortService",e.sort),i(),g(" ",e.dict.entry("orion.holdings.BOOK_VALUE")," ")}}function Pc(t,s){if(t&1&&(l(0,"a",13),u(1),a()),t&2){let e=d();o("appSortService",e.sort),i(),g(" ",e.dict.entry("orion.holdings.MARKET_VALUE")," ")}}function Dc(t,s){if(t&1&&(l(0,"a",14),u(1),a()),t&2){let e=d();o("appSortService",e.sort),i(),g(" ",e.dict.entry("orion.asset-allocation.PERCENTAGE")," ")}}function wc(t,s){if(t&1&&(l(0,"a",15),u(1),a()),t&2){let e=d();o("appSortService",e.sort),i(),g(" ",e.dict.entry("orion.holdings.UNREALIZED_GAIN")," ")}}function Lc(t,s){if(t&1&&(A(0),l(1,"app-tooltip",22),u(2),p(3,"lowercase"),a(),I()),t&2){let e=d(2).$implicit;i(),o("textTooltip",e.symbol+" - "+e.description),i(),g(" ",m(3,2,e.description)," ")}}function Oc(t,s){if(t&1&&u(0),t&2){let e=d(2).$implicit;g(" ",e.symbol," ")}}function Bc(t,s){if(t&1&&(l(0,"div",19)(1,"div",20),v(2,Lc,4,4,"ng-container",21)(3,Oc,1,1,"ng-template",null,0,P),a()()),t&2){let e=E(4),n=d().$implicit,r=d();y("data-header",r.dict.entry("orion.holdings.SYMBOL")),i(2),o("ngIf",n.description)("ngIfElse",e)}}function Mc(t,s){if(t&1&&(l(0,"div",23),c(1,"app-value-styler",24),a()),t&2){let e=d().$implicit,n=d();y("data-header",n.dict.entry("orion.holdings.BOOK_VALUE")),i(),o("value",e.bookValAmt)}}function kc(t,s){if(t&1&&(l(0,"div",23),c(1,"app-value-styler",24),a()),t&2){let e=d().$implicit,n=d();y("data-header",n.dict.entry("orion.holdings.MARKET_VALUE")),i(),o("value",e.marketValAmt)}}function Rc(t,s){if(t&1&&(l(0,"div",23),c(1,"app-value-styler",25),a()),t&2){let e=d().$implicit,n=d();y("data-header",n.dict.entry("orion.asset-allocation.PERCENTAGE")),i(),o("value",e.marketValPerc)}}function Nc(t,s){if(t&1&&(l(0,"div",23),c(1,"app-value-styler",25),a()),t&2){let e=d().$implicit,n=d();y("data-header",n.dict.entry("orion.asset-allocation.PERCENTAGE")),i(),o("value",e.marketValuePercentage)}}function Hc(t,s){if(t&1&&(l(0,"div",23),c(1,"app-value-styler",24),a()),t&2){let e=d().$implicit,n=d();y("data-header",n.dict.entry("orion.holdings.UNREALIZED_GAIN_1")),i(),o("value",e.unrealizedGain)}}function Vc(t,s){if(t&1&&(A(0),l(1,"div",16),v(2,Bc,5,3,"div",17)(3,Mc,2,2,"div",18)(4,kc,2,2,"div",18)(5,Rc,2,2,"div",18)(6,Nc,2,2,"div",18)(7,Hc,2,2,"div",18),a(),I()),t&2){let e=d();i(2),o("ngIf",e.symbol),i(),o("ngIf",e.bookValAmt),i(),o("ngIf",e.marketValAmt),i(),o("ngIf",e.marketValPerc&&!e.activateAssetAllocationPatch),i(),o("ngIf",e.marketValPerc&&e.activateAssetAllocationPatch),i(),o("ngIf",e.unrealizedGain)}}var Ro=(()=>{class t{constructor(e,n){this.dict=e,this.sort=n,this.symbol=!0,this.bookValAmt=!1,this.marketValAmt=!0,this.marketValPerc=!0,this.unrealizedGain=!1,this.activateAssetAllocationPatch=!1}static{this.\u0275fac=function(n){return new(n||t)(f(J),f($))}}static{this.\u0275cmp=x({type:t,selectors:[["app-asset-allocation-positions"]],inputs:{positions:"positions",symbol:"symbol",bookValAmt:"bookValAmt",marketValAmt:"marketValAmt",marketValPerc:"marketValPerc",unrealizedGain:"unrealizedGain",activateAssetAllocationPatch:"activateAssetAllocationPatch"},standalone:!1,features:[xe([$])],decls:11,vars:9,consts:[["noDescription",""],[1,"or-table-row","or-table-no-hover","or-collapsible"],[1,"or-table-cell"],[1,"or-stretch"],[1,"or-table-row","or-table-header"],["href","javascript:void(0)","class","or-table-cell or-flex-grow-two or-desc-max-width","key","symbol",3,"appSortService",4,"ngIf"],["href","javascript:void(0)","class","or-table-cell or-numeric","key","bookValAmt",3,"appSortService",4,"ngIf"],["href","javascript:void(0)","class","or-table-cell or-numeric","key","marketValAmt",3,"appSortService",4,"ngIf"],["href","javascript:void(0)","class","or-table-cell or-numeric","key","marketValPerc",3,"appSortService",4,"ngIf"],["href","javascript:void(0)","class","or-table-cell or-numeric","key","unrealizedGain",3,"appSortService",4,"ngIf"],[4,"ngFor","ngForOf"],["href","javascript:void(0)","key","symbol",1,"or-table-cell","or-flex-grow-two","or-desc-max-width",3,"appSortService"],["href","javascript:void(0)","key","bookValAmt",1,"or-table-cell","or-numeric",3,"appSortService"],["href","javascript:void(0)","key","marketValAmt",1,"or-table-cell","or-numeric",3,"appSortService"],["href","javascript:void(0)","key","marketValPerc",1,"or-table-cell","or-numeric",3,"appSortService"],["href","javascript:void(0)","key","unrealizedGain",1,"or-table-cell","or-numeric",3,"appSortService"],[1,"or-table-row","or-table-no-hover","or-table-row-no-bottom-border"],["class","or-table-cell or-flex-grow-two or-desc-max-width",4,"ngIf"],["class","or-table-cell or-collapsible or-numeric",4,"ngIf"],[1,"or-table-cell","or-flex-grow-two","or-desc-max-width"],[1,"or-capitalize","or-label_small","or-stretch","or-uppercase","pt-1"],[4,"ngIf","ngIfElse"],["classTooltip","or-ellipsis",3,"textTooltip"],[1,"or-table-cell","or-collapsible","or-numeric"],["digits","1.2-2",3,"value"],["digits","1.2-2","decorator","#%",3,"value"]],template:function(n,r){n&1&&(l(0,"div",1)(1,"div",2)(2,"div",3)(3,"div",4),v(4,Tc,2,2,"a",5)(5,Ec,2,2,"a",6)(6,Pc,2,2,"a",7)(7,Dc,2,2,"a",8)(8,wc,2,2,"a",9),a(),v(9,Vc,8,6,"ng-container",10),p(10,"orderBy"),a()()()),n&2&&(i(4),o("ngIf",r.symbol),i(),o("ngIf",r.bookValAmt),i(),o("ngIf",r.marketValAmt),i(),o("ngIf",r.marketValPerc),i(),o("ngIf",r.unrealizedGain),i(),o("ngForOf",D(10,6,r.positions,r.sort.orderBy())))},dependencies:[F,T,Ee,k,Ne,Dt,fe],styles:["[_nghost-%COMP%] > .or-table-row[_ngcontent-%COMP%]{padding-left:15px;border-bottom:2px solid #eee}[_nghost-%COMP%]   .or-table-row.or-table-header[_ngcontent-%COMP%]{border-bottom:2px solid #eee}.or-desc-max-width[_ngcontent-%COMP%]{max-width:150px}"],changeDetection:0})}}return t})();function Fc(t,s){if(t&1){let e=V();l(0,"app-dropdown",34),p(1,"dict"),U("selectionChange",function(r){N(e);
9let _=d(5);return H(_.typeChange(r))}),a()}if(t&2){let e=d(5);me("aria-label",m(1,2,"orion.asset-allocation.INDICATOR")),o("selectionHolder",e.assetTypes)}}function Gc(t,s){t&1&&(l(0,"span"),u(1),p(2,"dict"),a()),t&2&&(i(),g(" ",m(2,1,"orion.asset-allocation.ASSET_CLASS")))}function jc(t,s){if(t&1){let e=V();l(0,"app-dropdown",34),p(1,"dict"),U("selectionChange",function(r){N(e);let _=d(5);return H(_.typeChange(r))}),a()}if(t&2){let e=d(5);me("aria-label",m(1,2,"orion.asset-allocation.INDICATOR")),o("selectionHolder",e.assetTypes)}}function Qc(t,s){if(t&1&&(l(0,"span"),u(1),p(2,"dict"),a()),t&2){let e=d(5);i(),g(" ",m(2,1,e.getLabel()))}}function $c(t,s){t&1&&c(0,"app-collapsible-toggle")}function qc(t,s){if(t&1&&(l(0,"div",51),c(1,"app-asset-allocation-positions",52),a()),t&2){let e=d().$implicit,n=d(7);i(),o("activateAssetAllocationPatch",n.assetAllocationService.activateAssetAllocationPatch)("positions",e.positions)("unrealizedGain",!0)("bookValAmt",!0)}}function Yc(t,s){if(t&1&&(A(0),l(1,"div",46)(2,"div",36)(3,"div",37),p(4,"dict"),l(5,"div",38)(6,"div",47)(7,"div",48),c(8,"div",49),a(),l(9,"div",50),u(10),p(11,"dict"),a()()()(),l(12,"div",22),p(13,"dict"),u(14),a(),l(15,"div",23),p(16,"dict"),c(17,"app-value-styler",41),a(),l(18,"div",24),p(19,"dict"),c(20,"app-value-styler",42),a(),l(21,"div",32),v(22,$c,1,0,"app-collapsible-toggle",5),a()(),v(23,qc,2,4,"div",44),a(),I()),t&2){let e=s.$implicit,n=d(7);i(),o("desktop",!0)("grouped",!0)("expanded",!1)("showSeparator",!1),i(2),y("data-header",m(4,14,n.getLabel())),i(7),g(" ",m(11,16,"orion.asset-allocation.ASSET_SUB_CLASS_"+e.assetAllocationSubCatCd)," "),i(2),y("data-header",m(13,18,"orion.asset-allocation.CURRENCY")),i(2),g(" ",n.currencyCd," "),i(),y("data-header",m(16,20,"orion.asset-allocation.ACTUAL")),i(2),o("value",e.marketValPerc),i(),y("data-header",m(19,22,"orion.asset-allocation.MARKET_VALUE")),i(2),o("value",e.marketValAmt),i(2),o("ngIf",e.positions&&e.positions.length>0),i(),o("ngIf",e.positions&&e.positions.length>0)}}function zc(t,s){if(t&1&&(l(0,"div",45),v(1,Yc,24,24,"ng-container",26),a()),t&2){let e=d().$implicit,n=d(5);z("or-colored-line-collapse",n.mobile),i(),o("ngForOf",e.assetAllocations)}}function Kc(t,s){if(t&1&&(l(0,"div",51),c(1,"app-asset-allocation-positions",53),a()),t&2){let e=d().$implicit;i(),o("positions",e.positions)}}function Wc(t,s){if(t&1&&(A(0),l(1,"div",35)(2,"div",36)(3,"div",37)(4,"div",38)(5,"div",39)(6,"div"),c(7,"div",40),a(),l(8,"div",29),u(9),a()()()(),c(10,"div",22),p(11,"dict"),l(12,"div",23),p(13,"dict"),c(14,"app-value-styler",41),a(),l(15,"div",24),p(16,"dict"),c(17,"app-value-styler",42),a(),l(18,"div",32),c(19,"app-collapsible-toggle"),a()(),v(20,zc,2,3,"div",43)(21,Kc,2,1,"div",44),a(),I()),t&2){let e=s.$implicit,n=d(3).ngIf,r=d(2);i(),o("grouped",!0)("desktop",!0)("mediaStrict",r.isSector())("showSeparator",r.mobile),i(2),y("data-header",r.dict.entry(r.getLabel())),i(4),fi("background-color",r.color(n,e)),i(2),g(" ",r.getAssetAllocationCatCd(e==null?null:e.assetAllocationCatCd)," "),i(),y("data-header",m(11,15,"orion.asset-allocation.CURRENCY")),i(2),y("data-header",m(13,17,"orion.asset-allocation.ACTUAL")),i(2),o("value",e.marketValPerc),i(),y("data-header",m(16,19,"orion.asset-allocation.MARKET_VALUE")),i(2),o("value",e.marketValAmt),i(3),o("ngIf",e==null?null:e.assetAllocations),i(),o("ngIf",e.positions&&e.positions.length>0)}}function Zc(t,s){if(t&1&&(A(0),l(1,"div",27)(2,"div",54)(3,"div",29),u(4),p(5,"dict"),a()(),l(6,"div",22),p(7,"dict"),u(8),a(),l(9,"div",23),p(10,"dict"),c(11,"app-value-styler",55),a(),l(12,"div",24),p(13,"dict"),c(14,"app-value-styler",31),a(),c(15,"div",32),a(),l(16,"div",27)(17,"div",54)(18,"div",29),u(19),p(20,"dict"),a()(),l(21,"div",56),p(22,"dict"),c(23,"app-value-styler",31),a(),c(24,"div",32),a(),I()),t&2){let e=d(3).ngIf,n=d(2);i(4),h(m(5,10,"orion.asset-allocation.SUB_TOTAL")),i(2),y("data-header",m(7,12,"orion.asset-allocation.CURRENCY")),i(2),g(" ",n.currencyCd," "),i(),y("data-header",m(10,14,"orion.asset-allocation.ACTUAL")),i(2),o("value",e==null?null:e.sectorsPercentTotal),i(),y("data-header",m(13,16,"orion.asset-allocation.MARKET_VALUE")),i(2),o("value",e==null?null:e.subTotalSectorsMarketValAmt),i(5),h(m(20,18,"orion.asset-allocation.TOTAL_NOT_EVALUATED")),i(2),y("data-header",m(22,20,"orion.asset-allocation.MARKET_VALUE")),i(2),o("value",e==null?null:e.totalNotEvaluatedMarketValAmt)}}function Xc(t,s){if(t&1&&c(0,"app-value-styler",55),t&2){let e=d(3).ngIf;o("value",e==null?null:e.percentTotal)}}
9function Jc(t,s){t&1&&ze(0)}function ep(t,s){if(t&1&&(A(0),v(1,Jc,1,0,"ng-container",57),I()),t&2){d(5);let e=E(7);i(),o("ngTemplateOutlet",e)}}function tp(t,s){if(t&1&&(l(0,"div",58),c(1,"app-pie-chart-breakdown",59),a()),t&2){let e=d(3).ngIf,n=d(2);i(),o("pieData",e.pieChartData)("chartId",n.idAssetAllocation)}}function ip(t,s){t&1&&ze(0)}function np(t,s){if(t&1&&(A(0),v(1,ip,1,0,"ng-container",57),I()),t&2){d(5);let e=E(7);i(),o("ngTemplateOutlet",e)}}function op(t,s){if(t&1&&(l(0,"div")(1,"div",13),c(2,"app-investcube-logo",14),l(3,"div",15),v(4,Fc,2,4,"app-dropdown",16)(5,Gc,3,3,"ng-template",null,3,P),a(),l(7,"div",17)(8,"div",18)(9,"div",19)(10,"div",20)(11,"div",21),v(12,jc,2,4,"app-dropdown",16)(13,Qc,3,3,"ng-template",null,3,P),a(),l(15,"div",22),u(16),p(17,"dict"),a(),l(18,"div",23),u(19),p(20,"dict"),a(),l(21,"div",24),u(22),p(23,"dict"),a(),c(24,"div",25),a(),v(25,Wc,22,21,"ng-container",26)(26,Zc,25,22,"ng-container",5),l(27,"div",27)(28,"div",28)(29,"div",29),u(30),p(31,"dict"),a()(),l(32,"div",22),u(33),a(),l(34,"div",23),v(35,Xc,1,1,"app-value-styler",30),a(),l(36,"div",24),c(37,"app-value-styler",31),a(),c(38,"div",32),a(),v(39,ep,2,1,"ng-container",5),a()(),v(40,tp,2,2,"div",33),a(),v(41,np,2,1,"ng-container",5),a()()),t&2){let e=E(6),n=d(2).ngIf,r=d(2);i(4),o("ngIf",r.userProfile.hasAccess(r.Access.ASSET_ALLOCATION_SECTOR_VIEW))("ngIfElse",e),i(8),o("ngIf",r.userProfile.hasAccess(r.Access.ASSET_ALLOCATION_SECTOR_VIEW))("ngIfElse",e),i(4),h(m(17,16,"orion.asset-allocation.CURRENCY")),i(3),h(m(20,18,"orion.asset-allocation.ACTUAL")),i(3),h(m(23,20,"orion.asset-allocation.MARKET_VALUE")),i(3),o("ngForOf",n==null?null:n.assetsAllocation),i(),o("ngIf",r.isSector()),i(4),h(m(31,22,"orion.asset-allocation.TOTAL")),i(3),g(" ",r.currencyCd," "),i(2),o("ngIf",!r.isSector()),i(2),o("value",n==null?null:n.totalMarketValAmt),i(2),o("ngIf",!r.mobile),i(),o("ngIf",n&&n.assetsAllocation),i(),o("ngIf",r.mobile)}}function rp(t,s){if(t&1){let e=V();l(0,"app-dropdown",34),p(1,"dict"),U("selectionChange",function(r){N(e);let _=d(5);return H(_.typeChange(r))}),a()}if(t&2){let e=d(5);me("aria-label",m(1,2,"orion.asset-allocation.INDICATOR")),o("selectionHolder",e.assetTypes)}}function ap(t,s){t&1&&(l(0,"span"),u(1),p(2,"dict"),a()),t&2&&(i(),g(" ",m(2,1,"orion.asset-allocation.ASSET_CLASS")))}function lp(t,s){if(t&1){let e=V();l(0,"app-dropdown",34),p(1,"dict"),U("selectionChange",function(r){N(e);let _=d(5);return H(_.typeChange(r))}),a()}if(t&2){let e=d(5);me("aria-label",m(1,2,"orion.asset-allocation.INDICATOR")),o("selectionHolder",e.assetTypes)}}function sp(t,s){if(t&1&&(l(0,"span"),u(1),p(2,"dict"),a()),t&2){let e=d(5);i(),g(" ",m(2,1,e.getLabel()))}}function cp(t,s){t&1&&(l(0,"div",24),u(1),p(2,"dict"),a()),t&2&&(i(),h(m(2,1,"orion.asset-allocation.DEBIT_BALANCE_AMOUNT")))}function pp(t,s){if(t&1&&(l(0,"div",24),p(1,"dict"),c(2,"app-value-styler",42),a()),t&2){let e=d().$implicit;y("data-header",m(1,2,"orion.asset-allocation.DEBIT_BALANCE_AMOUNT")),i(2),o("value",e.debitBalanceAmount)}}function dp(t,s){if(t&1&&(l(0,"div",24),p(1,"dict"),c(2,"app-value-styler",42),a()),t&2){let e=d().$implicit;y("data-header",m(1,2,"orion.asset-allocation.DEBIT_BALANCE_AMOUNT")),i(2),o("value",e.debitBalanceAmount)}}function mp(t,s){t&1&&c(0,"app-collapsible-toggle")}function up(t,s){if(t&1&&(l(0,"div",51),c(1,"app-asset-allocation-positions",52),a()),t&2){let e=d().$implicit,n=d(7);i(),o("activateAssetAllocationPatch",n.assetAllocationService.activateAssetAllocationPatch)("positions",e.positions)("unrealizedGain",!0)("bookValAmt",!0)}}function vp(t,s){if(t&1&&(A(0),l(1,"div",46)(2,"div",36)(3,"div",37),p(4,"dict"),l(5,"div",38)(6,"div",47)(7,"div",48),c(8,"div",49),a(),l(9,"div",50),u(10),p(11,"dict"),a()()()(),l(12,"div",22),p(13,"dict"),u(14),a(),l(15,"div",23),p(16,"dict"),c(17,"app-value-styler",61),a(),l(18,"div",24),p(19,"dict"),c(20,"app-value-styler",62),a(),v(21,dp,3,4,"div",60),l(22,"div",32),v(23,mp,1,0,"app-collapsible-toggle",5),a()(),v(24,up,2,4,"div",44),a(),I()),t&2){let e=s.$implicit,n=d(7);i(),o("desktop",!0)("grouped",!0)("expanded",!1)("showSeparator",!1),i(2),y("data-header",m(4,15,n.getLabel())),i(7),g(" ",m(11,17,"orion.asset-allocation.ASSET_SUB_CLASS_"+e.assetAllocationSubCatCd)," "),i(2),y("data-header",m(13,19,"orion.asset-allocation.CURRENCY")),i(2),g(" ",n.currencyCd," "),i(),y("data-header",m(16,21,"orion.asset-allocation.ACTUAL")),i(2),o("value",n.isSector()?e.marketValPerc:e.marketValuePercentage),i(),y("data-header",m(19,23,"orion.asset-allocation.MARKET_VALUE")),i(2),o("value",n.isSector()?e.marketValAmt:e.marketValueAmount),i(),o("ngIf",!n.isSector()),i(2),o("ngIf",e.positions&&e.positions.length>0),i(),o("ngIf",e.positions&&e.positions.length>0)}}function _p(t,s){if(t&1&&(l(0,"div",45),v(1,vp,25,25,"ng-container",26),a()),t&2){let e=d().$implicit,n=d(5);z("or-colored-line-collapse",n.mobile),i(),o("ngForOf",e.assetAllocations)}}function gp(t,s){if(t&1&&(l(0,"div",51),c(1,"app-asset-allocation-positions",53),a()),t&2){let e=d().$implicit;i(),o("positions",e.positions)}}function fp(t,s){if(t&1&&(A(0),l(1,"div",35)(2,"div",36)(3,"div",37)(4,"div",38)(5,"div",39)(6,"div"),c(7,"div",40),a(),l(8,"div",29),u(9),a()()()(),c(10,"div",22),p(11,"dict"),l(12,"div",23),p(13,"dict"),c(14,"app-value-styler",41),a(),l(15,"div",24),p(16,"dict"),c(17,"app-value-styler",42),a(),v(18,pp,3,4,"div",60),l(19,"div",32),c(20,"app-collapsible-toggle"),a()(),v(21,_p,2,3,"div",43)(22,gp,2,1,"div",44),a(),I()),t&2){let e=s.$implicit,n=d(3).ngIf,r=d(2);i(),o("grouped",!0)("desktop",!0)("mediaStrict",r.isSector())("showSeparator",r.mobile),i(2),y("data-header",r.dict.entry(r.getLabel())),i(4),fi("background-color",r.color(n,e)),i(2),g(" ",r.getAssetAllocationCatCd(e==null?null:e.assetAllocationCatCd)," "),i(),y("data-header",m(11,16,"orion.asset-allocation.CURRENCY")),i(2),y("data-header",m(13,18,"orion.asset-allocation.ACTUAL")),i(2),o("value",r.isSector()?e.marketValPerc:e.marketValuePercentage),i(),y("data-header",m(16,20,"orion.asset-allocation.MARKET_VALUE")),i(2),o("value",r.isSector()?e.marketValAmt:e.marketValueAmount),i(),o("ngIf",!r.isSector()),i(3),o("ngIf",e==null?null:e.assetAllocations),i(),o("ngIf",e.positions&&e.positions.length>0)}}function yp(t,s){if(t&1&&(A(0),l(1,"div",27)(2,"div",54)(3,"div",29),u(4),p(5,"dict"),a()(),l(6,"div",22),p(7,"dict"),u(8),a(),l(9,"div",23),p(10,"dict"),c(11,"app-value-styler",55),a(),l(12,"div",24),p(13,"dict"),c(14,"app-value-styler",31),a(),c(15,"div",32),a(),l(16,"div",27)(17,"div",54)(18,"div",29),u(19),p(20,"dict"),a()(),l(21,"div",56),p(22,"dict"),c(23,"app-value-styler",31),a(),c(24,"div",32),a(),I()),t&2){let e=d(3).ngIf,n=d(2);i(4),h(m(5,10,"orion.asset-allocation.SUB_TOTAL")),i(2),y("data-header",m(7,12,"orion.asset-allocation.CURRENCY")),i(2),g(" ",n.currencyCd," "),i(),y("data-header",m(10,14,"orion.asset-allocation.ACTUAL")),i(2),o("value",e==null?null:e.sectorsPercentTotal),i(),y("data-header",m(13,16,"orion.asset-allocation.MARKET_VALUE")),i(2),o("value",e==null?null:e.subTotalSectorsMarketValAmt),i(5),h(m(20,18,"orion.asset-allocation.TOTAL_NOT_EVALUATED")),i(2),y("data-header",m(22,20,"orion.asset-allocation.MARKET_VALUE")),i(2),o("value",e==null?null:e.totalNotEvaluatedMarketValAmt)}}function hp(t,s){if(t&1&&c(0,"app-value-styler",55),t&2){let e=d(4).ngIf;o("value",e==null?null:e.percentTotal)}}function Cp(t,s){if(t&1&&(A(0),l(1,"div",27)(2,"div",28)(3,"div",29),u(4),p(5,"dict"),a()(),l(6,"div",22),u(7),a(),l(8,"div",23),v(9,hp,1,1,"app-value-styler",30),a(),l(10,"div",24),c(11,"app-value-styler",31),a(),c(12,"div",32),a(),I()),t&2){let e=d(3).ngIf,n=d(2);i(4),h(m(5,4,"orion.asset-allocation.TOTAL")),i(3),g(" ",n.currencyCd," "),i(2),o("ngIf",!n.isSector()),i(2),o("value",e==null?null:e.totalMarketValAmt)}}function bp(t,s){t&1&&ze(0)}function xp(t,s){if(t&1&&(A(0),v(1,bp,1,0,"ng-container",57),I()),t&2){d(6);let e=E(7);i(),o("ngTemplateOutlet",e)}}function Sp(t,s){if(t&1&&(l(0,"div",63)(1,"div",28)(2,"div",29),u(3),p(4,"dict"),a()(),l(5,"div",24),c(6,"app-value-styler",31),a()(),l(7,"div",64)(8,"div",28)(9,"div",29),u(10),p(11,"dict"),a()(),l(12,"div",24),c(13,"app-value-styler",31),a()(),l(14,"div",64)(15,"div",28)(16,"div",29),u(17),p(18,"dict"),a()(),l(19,"div",24),c(20,"app-value-styler",31),a()(),l(21,"div",65)(22,"div",28)(23,"div",29),u(24),p(25,"dict"),a()(),l(26,"div",24),c(27,"app-value-styler",31),a()(),v(28,xp,2,1,"ng-container",5)),t&2){let e=d(3).ngIf,n=d(2);i(3),h(m(4,9,"orion.asset-allocation.SUB_TOTAL_MARKET_VALUE_AMOUNT")),i(3),o("value",e==null?null:e.subTotalMarketValueAmount),i(4),h(m(11,11,"orion.asset-allocation.TOTAL_MARKET_VALUE_PERCENTAGE")),i(3),o("value",e==null?null:e.totalMarketValuePercentage),i(4),h(m(18,13,"orion.asset-allocation.TOTAL_DEBIT_BALANCE_AMOUNT")),i(3),o("value",e==null?null:e.totalDebitBalanceAmount),i(4),h(m(25,15,"orion.asset-allocation.TOTAL_ASSETS")),i(3),o("value",e==null?null:e.totalMarketValueAmount),i(),o("ngIf",!n.mobile)}
9}function Ap(t,s){if(t&1&&(l(0,"div",58),c(1,"app-pie-chart-breakdown",59),a()),t&2){let e=d(3).ngIf,n=d(2);i(),o("pieData",e.pieChartData)("chartId",n.idAssetAllocation)}}function Ip(t,s){t&1&&ze(0)}function Tp(t,s){if(t&1&&(A(0),v(1,Ip,1,0,"ng-container",57),I()),t&2){d(5);let e=E(7);i(),o("ngTemplateOutlet",e)}}function Ep(t,s){if(t&1&&(l(0,"div")(1,"div",13),c(2,"app-investcube-logo",14),l(3,"div",15),v(4,rp,2,4,"app-dropdown",16)(5,ap,3,3,"ng-template",null,3,P),a(),l(7,"div",17)(8,"div",18)(9,"div",19)(10,"div",20)(11,"div",21),v(12,lp,2,4,"app-dropdown",16)(13,sp,3,3,"ng-template",null,3,P),a(),l(15,"div",22),u(16),p(17,"dict"),a(),l(18,"div",23),u(19),p(20,"dict"),a(),l(21,"div",24),u(22),p(23,"dict"),a(),v(24,cp,3,3,"div",60),c(25,"div",25),a(),v(26,fp,23,22,"ng-container",26)(27,yp,25,22,"ng-container",5)(28,Cp,13,6,"ng-container",12)(29,Sp,29,17,"ng-template",null,4,P),a()(),v(31,Ap,2,2,"div",33),a(),v(32,Tp,2,1,"ng-container",5),a()()),t&2){let e=E(6),n=E(30),r=d(2).ngIf,_=d(2);i(4),o("ngIf",_.userProfile.hasAccess(_.Access.ASSET_ALLOCATION_SECTOR_VIEW))("ngIfElse",e),i(8),o("ngIf",_.userProfile.hasAccess(_.Access.ASSET_ALLOCATION_SECTOR_VIEW))("ngIfElse",e),i(4),h(m(17,14,"orion.asset-allocation.CURRENCY")),i(3),h(m(20,16,"orion.asset-allocation.ACTUAL")),i(3),h(m(23,18,"orion.asset-allocation.MARKET_VALUE")),i(2),o("ngIf",!_.isSector()),i(2),o("ngForOf",r==null?null:r.assetsAllocation),i(),o("ngIf",_.isSector()),i(),o("ngIf",_.isSector())("ngIfElse",n),i(3),o("ngIf",r&&r.assetsAllocation),i(),o("ngIf",_.mobile)}}function Pp(t,s){if(t&1&&(A(0),v(1,op,42,24,"div",5)(2,Ep,33,20,"div",5),I()),t&2){let e=d(3);i(),o("ngIf",!e.assetAllocationService.activateAssetAllocationPatch),i(),o("ngIf",e.assetAllocationService.activateAssetAllocationPatch)}}function Dp(t,s){if(t&1&&(l(0,"div",7)(1,"div",8)(2,"div",9)(3,"h1",9),u(4),p(5,"dict"),a(),c(6,"app-widget-bar",10)(7,"app-refresh",11),a()(),v(8,Pp,3,2,"ng-container",12),a()),t&2){let e=d().ngIf,n=d(),r=E(5);i(2),o("ngClass",n.mobile?"mc-d-flex mc-flex-column pb-1":"mc-d-inline-flex mc-align-items-center py-3"),i(),o("ngClass",n.mobile?"mc-fs-700 my-0 pb-1":"or-font-36 m-0"),i(),h(m(5,7,"orion.menu.ASSET_ALLOCATION")),i(2),o("mobile",n.mobile),i(),o("pageId",n.RefreshedPage.ACCOUNTS_ASSET_ALLOCATION),i(),o("ngIf",e.length>0)("ngIfElse",r)}}function wp(t,s){if(t&1&&(A(0),v(1,Dp,9,9,"div",6),p(2,"async"),I()),t&2){let e=d(),n=E(3);i(),o("ngIf",m(2,2,e.assetAllocations$))("ngIfElse",n)}}function Lp(t,s){if(t&1){let e=V();l(0,"div",7)(1,"div",8)(2,"div",9)(3,"h1",9),u(4),p(5,"dict"),a(),c(6,"app-widget-bar",10)(7,"app-refresh",11),a()(),l(8,"div",13)(9,"app-unavailable-feature-alert",67),U("retry",function(){N(e);let r=d(2);return H(r.refreshButton())}),a()()()}if(t&2){let e=d(2);i(2),o("ngClass",e.mobile?"mc-d-flex mc-flex-column pb-1":"mc-d-inline-flex mc-align-items-center py-3"),i(),o("ngClass",e.mobile?"mc-fs-700 my-0 pb-1":"or-font-36 m-0"),i(),h(m(5,5,"orion.menu.ASSET_ALLOCATION")),i(2),o("mobile",e.mobile),i(),o("pageId",e.RefreshedPage.ACCOUNTS_ASSET_ALLOCATION)}}function Op(t,s){if(t&1&&(v(0,Lp,10,7,"div",66),p(1,"async")),t&2){let e=d();o("ngIf",m(1,1,e.showError$))}}function Bp(t,s){if(t&1&&(l(0,"div",13),c(1,"app-empty-messages",68),p(2,"dict"),p(3,"dict"),a()),t&2){let e=d();i(),o("iconKey",e.BncIconKey.Accounts)("headingText",m(2,3,"orion.app.NO-ACCOUNTS-SELECTED"))("descriptionText",m(3,5,"orion.app.NO-ACCOUNTS-SELECTED-DESCRIPTION"))}}function Mp(t,s){if(t&1&&(l(0,"div")(1,"div",69)(2,"app-info-tooltip",70),p(3,"dict"),u(4),p(5,"dict"),a(),l(6,"div",71),u(7),p(8,"dict"),a()()()),t&2){let e=d();oe("mc-py-small"+(e.mobile?" row":" ")),i(2),o("ariaLabel",m(3,5,"orion.asset-allocation.TOOLTIPS")),i(2),g(" ",m(5,7,"orion.asset-allocation.DISCLAIMER")," "),i(3),g(" ",m(8,9,"orion.asset-allocation.TOOLTIPS")," ")}}var No=(()=>{class t extends Q{constructor(e,n,r,_,C,b,M,ue){super(),this.assetAllocationService=e,this.breakpointObserver=n,this.cd=r,this.dict=_,this.sort=C,this.userProfile=b,this.store$=M,this.refreshService=ue,this.idAssetAllocation="idAssetAllocation",this.Access=Oe,this.RefreshedPage=Z,this.mobile=!1,this.currencyCd="
9CAD",this.selectedAccountsSubject=new St(null),this.selectedAccounts$=this.selectedAccountsSubject.asObservable(),this.BncIconKey=ot,n.observe([re.MOBILE]).pipe(Vi(),W(this.destroyed$)).subscribe(je=>{this.mobile=je.matches,this.cd.markForCheck()})}ngOnInit(){this.store$.pipe(R(Me),W(this.destroyed$)).subscribe(e=>{this.selectedAccountsSubject.next(e)}),this.assetAllocationService.init()}color(e,n){return this.assetAllocationService.color(e,n)}typeChange(e){this.assetAllocationService.typeChange(e)}getAssetAllocationCatCd(e){return this.assetAllocationService.getAssetAllocationCatCd(e)}getLabel(){return this.assetAllocationService.getLabel()}isSector(){return this.assetAllocationService.isSector()}get assetAllocations$(){return this.assetAllocationService.assetAllocations$}get showError$(){return this.assetAllocationService.showError$}get assetTypes(){return this.assetAllocationService.assetTypes}get type(){return this.assetAllocationService.type}refreshButton(){this.refreshService.doRefresh(this.RefreshedPage.ACCOUNTS_ASSET_ALLOCATION)}static{this.\u0275fac=function(n){return new(n||t)(f(di),f(ae),f(Qi),f(J),f($),f(O),f(j),f(Re))}}static{this.\u0275cmp=x({type:t,selectors:[["app-asset-allocation"]],standalone:!1,features:[xe([di,$]),q],decls:8,vars:3,consts:[["showError",""],["noSelectedAccounts",""],["disclaimer",""],["sectorAccess",""],["showTotal",""],[4,"ngIf"],["id","content","tabindex","-1",4,"ngIf","ngIfElse"],["id","content","tabindex","-1"],[1,"or-heading"],[3,"ngClass"],[1,"pb-1","pb-lg-0","pl-lg-4",3,"mobile"],[1,"d-flex",3,"pageId"],[4,"ngIf","ngIfElse"],[1,"or-content","rounded"],["styleClass","d-flex pb-3"],[1,"or-desktop-hide"],["styleClass","or-transparent or-small",3,"aria-label","selectionHolder","selectionChange",4,"ngIf","ngIfElse"],[1,"row"],[1,"or-table","or-flex-one","col-12","col-lg","or-table-assets"],[1,"or-table-body"],[1,"or-table-row","or-table-header"],[1,"or-table-cell","or-grow-asset-class"],[1,"or-table-cell","or-grow-currency"],[1,"or-table-cell","or-grow-actual","or-numeric"],[1,"or-table-cell","or-grow-market-value","or-numeric"],[1,"or-table-cell","or-grow-expand"],[4,"ngFor","ngForOf"],[1,"or-table-row"],[1,"or-table-cell","or-grow-total-class","or-flex-full"],[1,"or-h4"],["class","or-h4","digits","1.2-2","decorator","#%",3,"value",4,"ngIf"],["digits","1.2-2",1,"or-h4",3,"value"],[1,"or-table-cell","or-flex-full","or-grow-expand"],["class","col-12 col-lg or-chart-assets",4,"ngIf"],["styleClass","or-transparent or-small",3,"selectionChange","aria-label","selectionHolder"],["appCollapsible","",3,"grouped","desktop","mediaStrict","showSeparator"],[1,"or-table-row","or-table-no-hover"],[1,"or-table-cell","or-grow-asset-class","or-flex-full","or-flex-start"],[1,"or-box","or-no-padding"],[1,"or-box-child","or-box-no-wrap"],[1,"or-pie-chart-legend-color"],["digits","1.2-2","decorator","#%",3,"value"],["digits","1.2-2",3,"value"],["class","or-group-collapsible",3,"or-colored-line-collapse",4,"ngIf"],["class","or-group-collapsible or-mobile-hide",4,"ngIf"],[1,"or-group-collapsible"],["appCollapsible","",3,"desktop","grouped","expanded","showSeparator"],[1,"or-box-child","or-no-padding","or-box-no-wrap"],[1,"or-mobile-hide"],[1,"or-category-legend-placeholder"],[1,"or-label"],[1,"or-group-collapsible","or-mobile-hide"],[3,"activateAssetAllocationPatch","positions","unrealizedGain","bookValAmt"],[3,"positions"],[1,"or-table-cell","or-grow-asset-class","or-flex-full"],["digits","1.2-2","decorator","#%",1,"or-h4",3,"value"],[1,"or-table-cell","or-numeric"],[4,"ngTemplateOutlet"],[1,"col-12","col-lg","or-chart-assets"],[3,"pieData","chartId"],["class","or-table-cell or-grow-market-value or-numeric",4,"ngIf"],["digits","1.2-2","decorator","#%",1,"mc-pr-small",3,"value"],["digits","1.2-2",1,"mc-pr-xxsmall",3,"value"],[1,"or-table-row","border-bottom-0"],[1,"or-table-row","border-bottom-0","border-top-0"],[1,"or-table-row","border-top-0"],["id","content","tabindex","-1",4,"ngIf"],[3,"retry"],[3,"iconKey","headingText","descriptionText"],[1,"mc-d-flex","mc-flex-row"],["classInfoTooltip","mc-pr-xsmall",3,"ariaLabel"],[1,"mc-font-family-body","mc-fs-300"]],template:function(n,r){n&1&&(v(0,wp,3,4,"ng-container",5),p(1,"async"),v(2,Op,2,3,"ng-template",null,0,P)(4,Bp,4,7,"ng-template",null,1,P)(6,Mp,9,11,"ng-template",null,2,P)),n&2&&o("ngIf",m(1,1,r.selectedAccounts$))},dependencies:[X,F,T,Pt,ke,lt,Zt,te,k,Rn,He,Ue,On,Un,ln,Ro,G,w],styles:['@charset "UTF-8";[_nghost-%COMP%]   .or-table-cell.or-grow-asset-class[_ngcontent-%COMP%]{flex-grow:3!important}[_nghost-%COMP%]   .or-table-cell.or-grow-total-class[_ngcontent-%COMP%]{flex-grow:3.5!important}[_nghost-%COMP%]   .or-table-cell.or-grow-currency[_ngcontent-%COMP%]{flex-grow:1!important}[_nghost-%COMP%]   .or-table-cell.or-grow-actual[_ngcontent-%COMP%]{flex-grow:1!important}[_nghost-%COMP%]   .or-table-cell.or-grow-market-value[_ngcontent-%COMP%]{flex-grow:1.5!important}[_nghost-%COMP%]   .or-table-cell.or-grow-expand[_ngcontent-%COMP%]{flex-grow:0!important}[_nghost-%COMP%]   .or-group-collapsible[_ngcontent-%COMP%]{background-color:rgba(var(--bg_color_body_rgb),.5)}[_nghost-%COMP%]   .or-group-collapsible[_ngcontent-%COMP%]   .or-group-collapsible[_ngcontent-%COMP%]{background:transparent}@media screen and (min-width:960px),print{[_nghost-%COMP%]   .or-table-assets[_ngcontent-%COMP%]{min-width:475px}[_nghost-%COMP%]   .or-chart-assets[_ngcontent-%COMP%]{max-width:50%}[_nghost-%COMP%]   .or-table[_ngcontent-%COMP%]   .or-table-body[_ngcontent-%COMP%]   .or-table-row[_ngcontent-%COMP%]   .or-table-cell.or-grow-expand[_ngcontent-%COMP%]{flex-basis:auto;width:40px}[_nghost-%COMP%]   .or-table[_ngcontent-%COMP%]   .or-table-body[_ngcontent-%COMP%]   .or-table-row[_ngcontent-%COMP%]{border-bottom:2px solid #eee}[_nghost-%COMP%]   .or-table[_ngcontent-%COMP%]   .or-table-body[_ngcontent-%COMP%]   .or-expanded[_ngcontent-%COMP%] > .or-table-row[_ngcontent-%COMP%]{border-bottom:0}[_nghost-%COMP%]   .or-table[_ngcontent-%COMP%]   .or-table-body[_ngcontent-%COMP%]   .or-group-collapsible[_ngcontent-%COMP%] > .or-expanded[_ngcontent-%COMP%] > .or-table-row[_ngcontent-%COMP%]{border-bottom:2px solid #eee}[_nghost-%COMP%]   .or-expanded[_ngcontent-%COMP%]   .or-group-collapsible[_ngcontent-%COMP%]{border-top:2px solid #eee}[_nghost-%COMP%]   .or-expanded[_ngcontent-%COMP%]   .or-group-collapsible[_ngcontent-%COMP%]   .or-group-collapsible[_ngcontent-%COMP%]{border-top:0}[_nghost-%COMP%]   .or-group-collapsible[_ngcontent-%COMP%]{margin-left:35px}[_nghost-%COMP%]   .or-group-collapsible[_ngcontent-%COMP%]   .or-group-collapsible[_ngcontent-%COMP%]{margin-left:0}}'],changeDetection:0})}}return t})();var Ho=(()=>{class t{constructor(){}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=x({type:t,selectors:[["app-dividends-interest-header"]],inputs:{title:"title"},standalone:!1,decls:4,vars:1,consts:[[1,"or-box"],[1,"or-box-child"],[1,"or-h3"]],template:function(n,r){n&1&&(l(0,"div",0)(1,"div",1)(2,"div",2),u(3),a()()()),n&2&&(i(3),h(r.title))},encapsulation:2})}}return t})();function Rp(t,s){t&1&&c(0,"div",5)}var Vo=(()=>{class t{constructor(e,n,r){this.dict=e,this.sort=n,this.userProfile=r}ngOnInit(){this.dict.load(["dividends-interest"])}static{this.\u0275fac=function(n){return new(n||t)(f(J),f($),f(O))}}static{this.\u0275cmp=x({type:t,selectors:[["app-dividends-interest"]],standalone:!1,features:[xe([$])],decls:33,vars:13,consts:[["row",""],[3,"title"],[1,"or-table"],[1,"or-table-body"],[1,"or-table-row","or-table-header"],[1,"or-table-cell"],[1,"or-table-cell","or-numeric"],["class","or-table-cell",4,"ngIf"],["appCollapsible","",1,"or-table-row"]],template:function(n,r){n&1&&(l(0,"div")(1,"div"),c(2,"app-dividends-interest-header",1),l(3,"div",2)(4,"div",3)(5,"div",4)(6,"div",5)(7,"div")(8,"span"),u(9),a(),l(10,"span"),u(11),a()()(),l(12,"div",6),u(13),a(),l(14,"div",6),u(15),a(),l(16,"div",6),u(1
97),a(),l(18,"div",6),u(19),a(),l(20,"div",6),u(21),a(),l(22,"div",6),u(23),a(),l(24,"div",6),u(25),a(),l(26,"div",6),u(27),a(),l(28,"div",6),u(29),a(),v(30,Rp,1,0,"div",7),a()(),c(31,"div",8,0),a()()()),n&2&&(i(2),o("title",r.dict.entry("orion.dividends-interest.STOCK")),i(7),g(" ",r.dict.entry("orion.dividends-interest.SYMBOL")," "),i(2),g(" / ",r.dict.entry("orion.dividends-interest.DESCRIPTION")," "),i(2),g(" ",r.dict.entry("orion.dividends-interest.DIVIDEND_PER_SHARE")," "),i(2),g(" ",r.dict.entry("orion.dividends-interest.ANN_YIELD")," "),i(2),g(" ",r.dict.entry("orion.dividends-interest.GROWTH_5_YEARS")," "),i(2),g(" ",r.dict.entry("orion.dividends-interest.ANN_ROI")," "),i(2),g(" ",r.dict.entry("orion.dividends-interest.FREQUENCY")," "),i(2),g(" ",r.dict.entry("orion.dividends-interest.DIVIDEND")," "),i(2),g(" ",r.dict.entry("orion.dividends-interest.EX_DATE")," "),i(2),g(" ",r.dict.entry("orion.dividends-interest.PAY_DATE")," "),i(2),g(" ",r.dict.entry("orion.dividends-interest.DIVIDEND_YTD")," "),i(),o("ngIf",r.userProfile.hasMinimalTradeAccess))},dependencies:[T,te,Ho],encapsulation:2})}}return t})();function Uo(t){return t.map(s=>({portfolioName:s.portfolioName,cltId:s.cltId,cltAlias:s.cltAlias,investCube:s.investCube,accountList:s.accountList,showAccountList:s.showAccountList}))}var mi=class{constructor(){this.menu=[{id:"single-period",label:"orion.menu.PERFORMANCE_PERSONAL_RETURN_SINGLE_PERIOD",routerLink:"single-period"},{id:"compound-period",label:"orion.menu.PERFORMANCE_PERSONAL_RETURN_COMPOUND_PERIOD",routerLink:"compound-period"}]}};var ie=(()=>{class t extends Q{constructor(e,n,r){super(),this.userProfile=e,this.router=n,this.breakpointObserver=r,this.subMenuTitle="orion.menu.PERSONAL_RETURN_MENU_TITLE",this.perfomanceSubMenu=new mi,this.mobile=!1,this.subMenuOpened=!1,this.createSubMenu()}hasPerformanceAccess(){return this.userProfile.hasPerformanceAccess}hasNewPerformanceAccess(){return this.userProfile.hasNewPerformanceAccess}createSubMenu(){this.router.routerState.snapshot.url.indexOf("/compound-period")>=0?this.selectedPerformanceReturnSubMenu=this.perfomanceSubMenu.menu[1].label:this.router.routerState.snapshot.url.indexOf("/single-period")>=0&&(this.selectedPerformanceReturnSubMenu=this.perfomanceSubMenu.menu[0].label),this.breakpointObserver.observe([re.MOBILE]).pipe(W(this.destroyed$)).subscribe(e=>{this.mobile=e.matches}),this.mobile&&this.router.events.pipe(W(this.destroyed$)).subscribe(e=>{e instanceof zi&&(e.urlAfterRedirects.indexOf("/single-period")>=0?this.selectedPerformanceReturnSubMenu=this.perfomanceSubMenu.menu[0].label:e.urlAfterRedirects.indexOf("/compound-period")>=0&&(this.selectedPerformanceReturnSubMenu=this.perfomanceSubMenu.menu[1].label))})}static{this.\u0275fac=function(n){return new(n||t)(B(O),B(pe),B(ae))}}static{this.\u0275prov=ve({token:t,factory:t.\u0275fac})}}return t})();function Np(t,s){if(t&1&&(l(0,"div"),c(1,"app-micro-frontend",1),a()),t&2){let e=s.ngIf,n=d();i(),o("props",n.initProps(e))}}var Fo=(()=>{class t{constructor(e,n,r,_){this.performanceService=e,this.userProfileService=n,this.store=r,this.userInfo=_,this.accountList$=this.store.select(Ie)}initProps(e){return this.performanceProps={functionCodes:{hasAccessPerformanceTab:this.userProfileService.hasNewPerformanceAccess,hasAccessPortfolioHistoryTab:this.userProfileService.hasPortFolioHistoryAccess},accountList:this.userInfo.isRep?Uo(e):null,rep:this.userInfo.isRep},this.performanceProps}static{this.\u0275fac=function(n){return new(n||t)(f(ie),f(O),f(j),f(Ae))}}static{this.\u0275cmp=x({type:t,selectors:[["app-mfe-performance"]],standalone:!1,decls:2,vars:3,consts:[[4,"ngIf"],["appName","performance","withErrorHandling","true",3,"props"]],template:function(n,r){n&1&&(v(0,Np,2,1,"div",0),p(1,"async")),n&2&&o("ngIf",(r.performanceService.hasNewPerformanceAccess()||r.userProfileService.hasPortFolioHistoryAccess)&&m(1,1,r.accountList$))},dependencies:[T,jt,G],encapsulation:2,changeDetection:0})}}return t})();var ui=class{constructor(){this.menu=[{id:"time-weighted-return",label:"orion.menu.PERFORMANCE_TIME_WEIGHTED_RETURN",routerLink:"time-weighted-return"},{id:"personnal-return",label:"orion.menu.PERFORMANCE_PERSONAL_RETURN",routerLink:"personnal-return"}]}};var Go=t=>["/accounts/performance",t];function Fp(t,s){if(t&1&&(A(0),l(1,"a",15),u(2),p(3,"dict"),a(),I()),t&2){let e=s.$implicit;i(),o("routerLink",ce(4,Go,e.routerLink)),i(),g(" ",m(3,2,e.label)," ")}}function Gp(t,s){if(t&1&&(l(0,"div",13),v(1,Fp,4,6,"ng-container",14),a()),t&2){let e=d(4);i(),o("ngForOf",e.performanceMenu.menu)}}function jp(t,s){t&1&&c(0,"app-icon",22)}function Qp(t,s){t&1&&c(0,"app-icon",23)}function $p(t,s){if(t&1){let e=V();A(0),l(1,"a",25),U("click",function(){let r=N(e).$implicit,_=d(6);return _.selectedPerformanceSubMenu=r.label,H(_.subMenuOpened=!_.subMenuOpened)}),u(2),p(3,"dict"),a(),I()}if(t&2){let e=s.$implicit,n=d(6);i(),o("ngClass",n.mobile?"mc-w-100":null)("routerLink",ce(5,Go,e.routerLink)),i(),g(" ",m(3,3,e.label)," ")}}function qp(t,s){if(t&1&&(l(0,"div",24),v(1,$p,4,7,"ng-container",14),a()),t&2){let e=d(5
9);i(),o("ngForOf",e.performanceMenu.menu)}}function Yp(t,s){if(t&1){let e=V();l(0,"div")(1,"div",16)(2,"div",17)(3,"a",18),U("click",function(){N(e);let r=d(4);return H(r.subMenuOpened=!r.subMenuOpened)}),u(4),a(),v(5,jp,1,0,"app-icon",19)(6,Qp,1,0,"app-icon",20),a()(),v(7,qp,2,1,"div",21),a()}if(t&2){let e=d(4);i(4),h(e.dict.entry(e.selectedPerformanceSubMenu)),i(),o("ngIf",e.subMenuOpened),i(),o("ngIf",!e.subMenuOpened),i(),o("ngIf",e.subMenuOpened)}}function zp(t,s){if(t&1&&(l(0,"div",9),c(1,"app-investcube-logo",10),v(2,Gp,2,1,"div",11)(3,Yp,8,4,"div",12),c(4,"router-outlet"),a()),t&2){let e=d(3);i(2),o("ngIf",!e.mobile),i(),o("ngIf",e.mobile)}}function Kp(t,s){if(t&1&&(l(0,"div",26),c(1,"app-orion-message",27),a()),t&2){let e=d(3);i(),o("message",e.notAccountSelectedMessage)("boxSizeClass","or-message-big")}}function Wp(t,s){if(t&1&&(l(0,"div",7),v(1,zp,5,2,"div",8)(2,Kp,2,2,"ng-template",null,0,P),a()),t&2){let e=s.ngIf,n=E(3);i(),o("ngIf",e.length>0)("ngIfElse",n)}}function Zp(t,s){if(t&1&&(l(0,"div",2)(1,"div",3)(2,"div",4)(3,"h1",4),u(4),p(5,"dict"),a(),c(6,"app-widget-bar",5),a()(),v(7,Wp,4,2,"div",6),p(8,"async"),a()),t&2){let e=d();i(2),o("ngClass",e.mobile?"d-flex flex-column pb-1":"d-inline-flex align-items-center py-3"),i(),o("ngClass",e.mobile?"or-font-24 my-0 pb-1":"or-font-36 m-0"),i(),h(m(5,5,"orion.menu.PERFORMANCE")),i(2),o("mobile",e.mobile),i(),o("ngIf",m(8,7,e.performanceService.hasPerformanceAccess()&&e.accountSelection$))}}var jo=(()=>{class t extends Q{constructor(e,n,r,_,C){super(),this.dict=e,this.breakpointObserver=n,this.performanceService=r,this.userProfileService=_,this.store=C,this.performanceMenu=new ui,this.subMenuOpened=!1,this.mobile=!1,this.notAccountSelectedMessage={severity:Rt.NONE,message:"orion.performance.NOT_ACCOUNT_SELECTED_MESSAGE"}}ngOnInit(){this.accountSelection$=this.store.pipe(R(Kt)),this.selectedPerformanceSubMenu=this.performanceMenu.menu[0].label,this.breakpointObserver.observe([re.MOBILE]).pipe(W(this.destroyed$)).subscribe(e=>{this.mobile=e.matches})}static{this.\u0275fac=function(n){return new(n||t)(f(J),f(ae),f(ie),f(O),f(j))}}static{this.\u0275cmp=x({type:t,selectors:[["app-performance"]],standalone:!1,features:[q],decls:1,vars:1,consts:[["notAccountSelectedMsg",""],["id","content","tabindex","-1",4,"ngIf"],["id","content","tabindex","-1"],[1,"or-heading"],[3,"ngClass"],[1,"mc-pb-xxsmall","lg:mc-pb-0","lg:mc-pl-medium",3,"mobile"],["class","or-content rounded",4,"ngIf"],[1,"or-content","rounded"],["class","mc-py-normal",4,"ngIf","ngIfElse"],[1,"mc-py-normal"],["styleClass","mc-d-flex mc-pb-normal"],["class","or-tabset","mat-tab-nav-bar","",4,"ngIf"],[4,"ngIf"],["mat-tab-nav-bar","",1,"or-tabset"],[4,"ngFor","ngForOf"],["mat-tab-link","","routerLinkActive","or-tab-selected",1,"or-tab-primary","or-with-shadow","opacity-1","my-1","or-margin-tab-selected",3,"routerLink"],[1,"or-box"],[1,"or-box-child","or-box-end","or-submenu-selected","or-small-gap"],["href","javascript:void(0)",1,"or-colored-link",3,"click"],["id","ico_arrow-up","color","blue",4,"ngIf"],["id","ico_arrow-down","color","blue",4,"ngIf"],["class","or-menu or-submenu or-box or-no-padding",4,"ngIf"],["id","ico_arrow-up","color","blue"],["id","ico_arrow-down","color","blue"],[1,"or-menu","or-submenu","or-box","or-no-padding"],["routerLinkActive","or-selected",1,"or-menu-item","or-box-end",3,"click","ngClass","routerLink"],[1,"mc-py-medium"],[3,"message","boxSizeClass"]],template:function(n,r){n&1&&v(0,Zp,9,9,"div",1),n&2&&o("ngIf",!r.performanceService.hasNewPerformanceAccess()&&!r.userProfileService.hasPortFolioHistoryAccess)},dependencies:[Ot,Bt,Mt,X,F,T,Yt,nt,Xt,He,Ue,Qt,$t,G,w],encapsulation:2})}}return t})();var gt=(()=>{class t{constructor(e,n,r,_,C,b,M){this.http=e,this.userProfile=n,this.store=r,this.valueStylerPipe=_,this.dateFnsDateAdapter=C,this.dict=b,this.router=M,this.performanceServiceOption={type:null,value:null}}ngOnInit(){this.defineTab()}defineTab(){this.timeWeightedReturn=this.router.routerState.snapshot.url.indexOf("/time-weighted-return")>=0,this.personalReturn=this.router.routerState.snapshot.url.indexOf("/personnal-return")>=0}hasPerformanceAccess(){return this.userProfile.hasPerformanceAccess}init(){this.annualReturnCumulativePeriodPerformance$=this.refresh()}refresh(){return this.defineTab(),this.store.pipe(R(Kt),At(e=>{let n;if(e&&e.length){let r=e[0];r.length===6?this.performanceServiceOption.type="clients":this.performanceServiceOption.type="accounts",this.performanceServiceOption.value=r,n=this.getCumulativePeriodPerformance(this.buildApiUrl(this.performanceServiceOption))}else n=$e(!1);return n}))}getCumulativePeriodPerformance(e){return this.http.get(e).pipe(ne(({data:n,messageList:r})=>(this.errorMessages=r,this.errorMessages&&(this.errorMessages[0].message=this.dict.entry("orion.personnal-return.ERROR_MESSAGE"),this.errorMessages[0].severity=Rt.NONE),this.data=n,this.closedAccount=this.data.isClosedAccount,this.createGraphData(),this.lastLoadDt=this.data.lastLoadDt?this.dict.entry("orion.menu.PERSONAL_RETURN_MENU_TITLE_DATE")+" "+this.dateFnsDateAdapter.getISODateString(new Date(this.data.lastLoadDt),"/"):this.data.lastLoadDt,this.data.portfolioPerformancesSummaries)))}buildApiUrl(e){let n=null;return this.router.routerState.snapshot.url.indexOf("/single-period")>=0?n="SINGLE":this.router.routerState.snapshot.url.indexOf("/compound-period")>=0&&(n="COMPOUND"),`/portfolios/performances/${e.type}/${e.value}/${n}`}createGraphData(e){let n=this.data.portfolioPerformancesSummaries.map(r=>{let _={},C=this.getYear(r);return this.router.routerState.snapshot.url.indexOf("/single-period")>=0?this.router.routerState.snapshot.url.indexOf("/time-weighted-return")>=0?(_.y=e?r[e]:r.returnValue,_.category=this.concatGraphTitleValue(r.label,e?r[e]:r.returnValue,C)):(_.y=e?r[e]:r.changeMarketValue,_.category=this.concatGraphTitleValue(r.label,e?r[e]:r.changeMarketValue,C)):this.router.routerState.snapshot.url.indexOf("/compound-period")>=0&&(this.router.routerState.snapshot.url.indexOf("/time-weighted-return")>=0?(_.y=e?r[e]:r.returnValue,_.category=this.concatGraphTitleValue(r.label,e?r[e]:r.returnValue)):(_.y=e?r[e]:r.changeMarketValue,_.category=this.concatGraphTitleValue(r.label,e?r[e]:r.changeMarketValue))),_});this.graphData=$e({points:n})}
9concatGraphTitleValue(e,n,r){return'<span class="or-label-graph or-bold">'+(r||this.dict.entry("orion.personnal-return."+e))+'</span><br/><span class="or-p-x-small">'+this.valueStylerPipe.transform(n,"1.2-2",!1,!1,!1,"",!1)+"</span>"}getYear(e){return Number(e.label)===new Date().getFullYear()?this.dict.entry("orion.personnal-return.CURRENT_YEAR"):e.label}static{this.\u0275fac=function(n){return new(n||t)(B(it),B(O),B(j),B(Te),B(ii),B(J),B(pe))}}static{this.\u0275prov=ve({token:t,factory:t.\u0275fac})}}return t})();function Xp(t,s){if(t&1&&(l(0,"div"),c(1,"app-orion-message",3),a()),t&2){let e=d();i(),o("messages",e.personnalReturnService.errorMessages)}}function Jp(t,s){if(t&1&&(c(0,"app-chart-performance",6),p(1,"async")),t&2){let e=d(2);o("chartType",e.chartType)("chartId",e.chartId)("data",m(1,3,e.personnalReturnService.graphData))}}function ed(t,s){if(t&1&&(l(0,"div")(1,"div",10)(2,"div",11)(3,"div",12),u(4),a(),l(5,"div",13),c(6,"app-value-styler",14),a(),l(7,"div",15),c(8,"app-value-styler",14),a(),l(9,"div",16),c(10,"app-value-styler",14),a(),l(11,"div",17),c(12,"app-value-styler",14),a(),l(13,"div",18),c(14,"app-value-styler",14),a()()()()),t&2){let e=s.$implicit,n=d(3);i(4),g(" ",n.getLabelWithCorrectFormat(e.label)," "),i(),y("data-header",n.dict.entry("orion.personnal-return.INITIAL_VALUE")),i(),o("value",e.initialValue),i(),y("data-header",n.dict.entry("orion.personnal-return.INFLOWS")),i(),o("value",e.inflows),i(),y("data-header",n.dict.entry("orion.personnal-return.OUTFLOWS")),i(),o("value",e.outflows),i(),y("data-header",n.dict.entry("orion.personnal-return.CHANGE_IN_MARKET_VALUE")),i(),o("value",e.changeMarketValue),i(),y("data-header",n.dict.entry("orion.personnal-return.FINAL_VALUE")),i(),o("value",e.finalValue)}}function td(t,s){if(t&1&&(l(0,"div",7)(1,"div",8),v(2,ed,15,11,"div",9),a()()),t&2){let e=d().ngIf;i(2),o("ngForOf",e)}}function id(t,s){if(t&1&&(l(0,"div",32),c(1,"app-value-styler",14),a()),t&2){let e=s.$implicit;i(),o("value",e.initialValue)}}function nd(t,s){if(t&1){let e=V();l(0,"div",30),U("click",function(){N(e);let r=d(3);return H(r.updateGraphData("initialValue"))}),l(1,"div"),u(2),a(),v(3,id,2,1,"div",31),a()}if(t&2){let e=d(2).ngIf,n=d();z("or-bold",n.isSelected("initialValue")),i(),oe(be("or-table-cell ",n.cssClassofInitialValueColumn)),i(),g(" ",n.dict.entry("orion.personnal-return.INITIAL_VALUE")," "),i(),o("ngForOf",e)}}function od(t,s){if(t&1&&(l(0,"div",32),c(1,"app-value-styler",14),a()),t&2){let e=s.$implicit;i(),o("value",e.inflows)}}function rd(t,s){if(t&1){let e=V();l(0,"div",33),U("click",function(){N(e);let r=d(3);return H(r.updateGraphData("inflows"))}),l(1,"div"),u(2),a(),v(3,od,2,1,"div",31),a()}if(t&2){let e=d(2).ngIf,n=d();z("or-bold",n.isSelected("inflows")),i(),oe(be("or-table-cell ",n.cssClassofInitialValueColumn)),i(),h(n.dict.entry("orion.personnal-return.INFLOWS")),i(),o("ngForOf",e)}}function ad(t,s){if(t&1&&(l(0,"div",32),c(1,"app-value-styler",14),a()),t&2){let e=s.$implicit;i(),o("value",e.outflows)}}function ld(t,s){if(t&1){let e=V();l(0,"div",34),U("click",function(){N(e);let r=d(3);return H(r.updateGraphData("outflows"))}),l(1,"div"),u(2),a(),v(3,ad,2,1,"div",31),a()}if(t&2){let e=d(2).ngIf,n=d();z("or-bold",n.isSelected("outflows")),i(),oe(be("or-table-cell ",n.cssClassofInitialValueColumn)),i(),h(n.dict.entry("orion.personnal-return.OUTFLOWS")),i(),o("ngForOf",e)}}function sd(t,s){if(t&1&&(l(0,"div",32),c(1,"app-value-styler",14),a()),t&2){let e=s.$implicit;i(),o("value",e.changeMarketValue)}}function cd(t,s){if(t&1){let e=V();l(0,"div",35),U("click",function(){N(e);let r=d(3);return H(r.updateGraphData("changeMarketValue"))}),l(1,"div"),u(2),a(),v(3,sd,2,1,"div",31),a()}if(t&2){let e=d(2).ngIf,n=d();z("or-bold",n.isSelected("changeMarketValue")),i(),oe(be("or-table-cell ",n.cssClassofInitialValueColumn)),i(),h(n.dict.entry("orion.personnal-return.CHANGE_IN_MARKET_VALUE")),i(),o("ngForOf",e)}}function pd(t,s){if(t&1&&(l(0,"div",32),c(1,"app-value-styler",14),a()),t&2){let e=s.$implicit;i(),o("value",e.finalValue)}}function dd(t,s){if(t&1){let e=V();l(0,"div",36),U("click",function(){N(e);let r=d(3);return H(r.updateGraphData("finalValue"))}),l(1,"div"),u(2),a(),v(3,pd,2,1,"div",31),a()}if(t&2){let e=d(2).ngIf,n=d();z("or-bold",n.isSelected("finalValue")),i(),oe(be("or-table-cell ",n.cssClassofInitialValueColumn)),i(),h(n.dict.entry("orion.personnal-return.FINAL_VALUE")),i(),o("ngForOf",e)}}function md(t,s){if(t&1&&(l(0,"div",32),c(1,"app-value-styler",14),a()),t&2){let e=s.$implicit;i(),o("value",e.returnValue)}}function ud(t,s){if(t&1){let e=V();l(0,"div",37),U("click",function(){N(e);let r=d(3);return H(r.updateGraphData("returnValue"))}),l(1,"div"),u(2),a(),v(3,md,2,1,"div",31),a()}if(t&2){let e=d(2).ngIf,n=d();z("or-bold",n.isSelected("returnValue")),i(),oe(be("or-table-cell ",n.cssClassofInitialValueColumn)),i(),h(n.dict.entry("orion.personnal-return.RETURN_PERCENT")),i(),o("ngForOf",e)}}function vd(t,s){if(t&1&&(l(0,"div",32),c(1,"app-value-styler",14),a()),t&2){let e=s.$implicit;i(),o("value",e.sharpeRatioValue)}}function _d(t,s){if(t&1){let e=V();l(0,"div",38),U("click",function(){N(e);let r=d(3);return H(r.updateGraphData("sharpeRatioValue"))}),l(1,"div"),u(2),a(),v(3,vd,2,1,"div",31),a()}if(t&2){let e=d(2).ngIf,n=d();z("or-bold",n.isSelected("sharpeRatioValue")),i(),oe(be("or-table-cell ",n.cssClassofInitialValueColumn)),i(),h(n.dict.entry("orion.personnal-return.RATIO_SHARPE")),i(),o("ngForOf",e)}}function gd(t,s){if(t&1&&(l(0,"div",7)(1,"div",8)(2,"div",19),c(3,"div",20),l(4,"div",21),c(5,"app-ch
9art-performance",22),p(6,"async"),a()(),v(7,nd,4,7,"div",23)(8,rd,4,7,"div",24)(9,ld,4,7,"div",25)(10,cd,4,7,"div",26)(11,dd,4,7,"div",27)(12,ud,4,7,"div",28)(13,_d,4,7,"div",29),a()()),t&2){let e=d(2);i(5),o("chartType",e.chartType)("data",m(6,9,e.personnalReturnService.graphData)),i(2),o("ngIf",e.personnalReturnService.personalReturn),i(),o("ngIf",e.personnalReturnService.personalReturn),i(),o("ngIf",e.personnalReturnService.personalReturn),i(),o("ngIf",e.personnalReturnService.personalReturn),i(),o("ngIf",e.personnalReturnService.personalReturn),i(),o("ngIf",e.personnalReturnService.timeWeightedReturn),i(),o("ngIf",e.personnalReturnService.timeWeightedReturn)}}function fd(t,s){if(t&1&&(l(0,"div"),v(1,Jp,2,5,"app-chart-performance",4)(2,td,3,1,"div",5)(3,gd,14,11,"div",5),a()),t&2){let e=s.ngIf,n=d();z("hidden",n.personnalReturnService.errorMessages),i(),o("ngIf",n.mobile),i(),o("ngIf",n.mobile&&e),i(),o("ngIf",!n.mobile&&e)}}var vi=(()=>{class t{constructor(e,n,r,_,C,b,M){this.dict=e,this.renderer=n,this.el=r,this.breakpointObserver=_,this.performanceService=C,this.router=b,this.personnalReturnService=M,this.mobile=!1,this.breakpointSubscription=_.observe([re.MOBILE]).subscribe(ue=>{this.mobile=ue.matches})}ngOnInit(){this.personnalReturnService.init(),this.cssClassofInitialValueColumn=this.chartType===rt.SPLINE?"or-grow-spaceGraph":"or-grow-title",this.renderer.addClass(this.el.nativeElement,"or-stretch"),this.router.routerState.snapshot.url.indexOf("/time-weighted-return")>=0?this.idRowSelected="returnValue":this.idRowSelected="changeMarketValue"}ngOnDestroy(){this.breakpointSubscription&&this.breakpointSubscription.unsubscribe()}getLabelWithCorrectFormat(e){return Number(e)?Number(e)===new Date().getFullYear()?this.dict.entry("orion.personnal-return.CURRENT_YEAR"):e:this.dict.entry("orion.personnal-return."+e)}updateGraphData(e){let n={initialValue:"INITIAL_VALUE",inflows:"INFLOWS",outflows:"OUTFLOWS",changeMarketValue:"CHANGE_IN_MARKET_VALUE_DEVISE",finalValue:"FINAL_VALUE",returnValue:"RETURN_PERCENT",sharpeRatioValue:"RATIO_SHARPE"};this.idRowSelected=e,this.personnalReturnService.createGraphData(e),this.performanceService.subMenuTitle="orion.personnal-return."+n[e]}isSelected(e){return this.idRowSelected===e}static{this.\u0275fac=function(n){return new(n||t)(f(J),f(tt),f(et),f(ae),f(ie),f(pe),f(gt))}}static{this.\u0275cmp=x({type:t,selectors:[["app-accounts-perf-chart-and-tab"]],inputs:{chartType:"chartType",chartId:"chartId"},standalone:!1,decls:5,vars:6,consts:[[4,"ngIf"],[3,"closedAccount","message"],[3,"hidden",4,"ngIf"],[3,"messages"],[3,"chartType","chartId","data",4,"ngIf"],["class","or-table",4,"ngIf"],[3,"chartType","chartId","data"],[1,"or-table"],[1,"or-table-body"],[4,"ngFor","ngForOf"],["appCollapsible",""],[1,"or-table-row","or-table-no-hover","or-table-footer"],[1,"or-table-cell","or-new-label","or-new-black","or-grow-operation","or-position-1"],[1,"or-table-cell","or-numeric","or-grow-account","or-new-tab-label","or-position-5","or-collapsible"],["digits","1.2-2",3,"value"],[1,"or-table-cell","or-numeric","or-grow-account","or-new-tab-label","or-position-3","or-collapsible"],[1,"or-table-cell","or-numeric","or-grow-account","or-new-tab-label","or-position-4","or-collapsible"],[1,"or-table-cell","or-numeric","or-grow-account","or-new-tab-label","or-position-2"],[1,"or-table-cell","or-numeric","or-grow-account","or-new-tab-label","or-position-6","or-collapsible"],[1,"or-table-row","or-bold","or-table-no-hover"],[1,"or-table-cell","or-grow-spaceGraph"],[1,"or-table-cell","or-grow-graph"],["chartId","idCompoundPer",1,"or-stretch",3,"chartType","data"],["class","or-table-row or-click","id","initialValue",3,"or-bold","click",4,"ngIf"],["class","or-table-row or-click","id","inflows",3,"or-bold","click",4,"ngIf"],["class","or-table-row or-click","id","outflows",3,"or-bold","click",4,"ngIf"],["class","or-table-row or-click","id","changeMarketValue",3,"or-bold","click",4,"ngIf"],["class","or-table-row or-click","id","finalValue",3,"or-bold","click",4,"ngIf"],["class","or-table-row or-click","id","returnValue",3,"or-bold","click",4,"ngIf"],["class","or-table-row or-click","id","sharpeRatioValue",3,"or-bold","click",4,"ngIf"],["id","initialValue",1,"or-table-row","or-click",3,"click"],["class","or-table-cell or-center or-grow-value",4,"ngFor","ngForOf"],[1,"or-table-cell","or-center","or-grow-value"],["id","inflows",1,"or-table-row","or-click",3,"click"],["id","outflows",1,"or-table-row","or-click",3,"click"],["id","changeMarketValue",1,"or-table-row","or-click",3,"click"],["id","finalValue",1,"or-table-row","or-click",3,"click"],["id","returnValue",1,"or-table-row","or-click",3,"click"],["id","sharpeRatioValue",1,"or-table-row","or-click",3,"click"]],template:function(n,r){n&1&&(v(0,Xp,2,1,"div",0),A(1),c(2,"app-message-account-closed",1),I(),v(3,fd,4,5,"div",2),p(4,"async")),n&2&&(o("ngIf",r.personnalReturnService.errorMessages),i(2),o("closedAccount",r.personnalReturnService.closedAccount)("message","orion.registered-accounts.ACCOUNT_CLOSED"),i(),o("ngIf",m(4,4,r.personnalReturnService.annualReturnCumulativePeriodPerformance$)))},dependencies:[F,T,Yt,te,k,xn,In,G],styles:[".or-table-cell.or-grow-value[_ngcontent-%COMP%]{flex-grow:1!important}.or-table-cell.or-grow-graph[_ngcontent-%COMP%]{flex-grow:7!important}.or-table-cell.or-grow-title[_ngcontent-%COMP%]{flex-grow:2!important}.or-table-cell.or-grow-spaceGraph[_ngcontent-%COMP%]{flex-grow:1.5!important}"]})}}return t})();var Bi=(()=>{class t{constructor(e,n,r,_){this.renderer=e,this.el=n,this.router=r,this.performanceService=_,this.chartPerformanceType=rt}ngOnInit(){this.renderer.addClass(this.el.nativeElement,"or-stretch"),this.router.routerState.snapshot.url.indexOf("/time-weighted-return")>=0?this.performanceService.subMenuTitle="orion.personnal-return.RETURN_PERCENT":this.performanceService.subMenuTitle="orion.personnal-return.CHANGE_IN_MARKET_VALUE_DEVISE"}static{this.\u0275fac=function(n){return new(n||t)(f(tt),f(et),f(pe),f(ie))}}static{this.\u0275cmp=x({type:t,selectors:[["app-compound-period"]],standalone:!1,decls:1,vars:1,consts:[["chartId","idCompoundPerf",3,"chartType"]],template:function(n,r){n&1&&c(0,"app-accounts-perf-chart-and-tab",0),n&2&&o("chartType",r.chartPerformanceType.COLUMN)},dependencies:[vi],encapsulation:2})}}return t})();var qo=(t,s)=>[t,s];
9function yd(t,s){if(t&1&&(l(0,"div"),c(1,"span",15)(2,"br")(3,"br")(4,"span",16),a()),t&2){let e=d(3);i(),o("innerHtml",e.dict.entry("orion.sub-menu-performance.message1"),S),i(3),o("innerHTML",e.dict.entry("orion.sub-menu-performance.message2"),S)}}function hd(t,s){if(t&1&&c(0,"span",15)(1,"br")(2,"br")(3,"span",16),t&2){let e=d(3);o("innerHtml",e.dict.entry("orion.sub-menu-performance.message3"),S),i(3),o("innerHTML",e.dict.entry("orion.sub-menu-performance.message4"),S)}}function Cd(t,s){if(t&1&&(l(0,"div",13),v(1,yd,5,2,"div",14)(2,hd,4,2,"ng-template",null,1,P),a()),t&2){let e=E(3),n=d(2);i(),o("ngIf",n.displayLinkTimeWeighted)("ngIfElse",e)}}function bd(t,s){if(t&1&&(A(0),l(1,"a",19),u(2),p(3,"dict"),a(),I()),t&2){let e=s.$implicit,n=s.first,r=d(3);i(),z("ml-1",n),o("routerLink",se(6,qo,r.url,e.routerLink)),i(),g(" ",m(3,4,e.label)," ")}}function xd(t,s){if(t&1&&(l(0,"div",17),v(1,bd,4,9,"ng-container",18),a()),t&2){let e=d(2);i(),o("ngForOf",e.performanceService.perfomanceSubMenu.menu)}}function Sd(t,s){t&1&&c(0,"app-icon",27)}function Ad(t,s){t&1&&c(0,"app-icon",28)}function Id(t,s){if(t&1){let e=V();A(0),l(1,"a",30),U("click",function(){let r=N(e).$implicit,_=d(4);return _.performanceService.selectedPerformanceReturnSubMenu=r.label,H(_.performanceService.subMenuOpened=!_.performanceService.subMenuOpened)}),u(2),p(3,"dict"),a(),I()}if(t&2){let e=s.$implicit,n=d(4);i(),o("ngClass",n.mobile?"or-stretch":null)("routerLink",se(5,qo,n.url,e.routerLink)),i(),g(" ",m(3,3,e.label)," ")}}function Td(t,s){if(t&1&&(l(0,"div",29),v(1,Id,4,8,"ng-container",18),a()),t&2){let e=d(3);i(),o("ngForOf",e.performanceService.perfomanceSubMenu.menu)}}function Ed(t,s){if(t&1){let e=V();l(0,"div",20)(1,"div",21)(2,"div",22)(3,"a",23),U("click",function(){N(e);let r=d(2);return H(r.performanceService.subMenuOpened=!r.performanceService.subMenuOpened)}),u(4),a(),v(5,Sd,1,0,"app-icon",24)(6,Ad,1,0,"app-icon",25),a()(),v(7,Td,2,1,"div",26),a()}if(t&2){let e=d(2);i(4),h(e.dict.entry(e.performanceService.selectedPerformanceReturnSubMenu)),i(),o("ngIf",e.performanceService.subMenuOpened),i(),o("ngIf",!e.performanceService.subMenuOpened),i(),o("ngIf",e.performanceService.subMenuOpened)}}function Pd(t,s){if(t&1&&(l(0,"div",3)(1,"div",4)(2,"div",5)(3,"div",6)(4,"div")(5,"h2"),u(6),p(7,"dict"),a(),c(8,"div",7),a(),l(9,"div",8),c(10,"app-icon",9),p(11,"dict"),l(12,"a",10),u(13),p(14,"dict"),a()()()(),v(15,Cd,4,2,"ng-template",null,0,P)(17,xd,2,1,"div",11),a(),v(18,Ed,8,4,"div",12),l(19,"div",4),c(20,"router-outlet"),a()()),t&2){let e=E(16),n=d();i(6),g("",m(7,9,n.performanceService.subMenuTitle)," "),i(2),o("innerHTML",n.getlastLoadDt,S),i(2),y("aria-label",m(11,11,"orion.app.TOOLTIPS")),i(2),o("bncPopover",e)("bncPopoverPosition",n.mobile?"bottomLeft":"right")("bncClassToMovePosition","ml-9 ml-lg-0"),i(),g(" ",m(14,13,"orion.sub-menu-performance.DETAILS_RETURN_CALCULATION")," "),i(4),o("ngIf",!n.mobile),i(),o("ngIf",n.mobile)}
9}var _i=(()=>{class t{constructor(e,n,r,_,C){this.dict=e,this.personnalReturnService=n,this.breakpointObserver=r,this.router=_,this.performanceService=C,this.mobile=!1,this.displayLinkTimeWeighted=!1}ngOnInit(){this.dict.load(["sub-menu-performance"]),this.router.routerState.snapshot.url.indexOf("/time-weighted-return")>=0?(this.performanceService.subMenuTitle="orion.menu.RETURN",this.displayLinkTimeWeighted=!0):this.router.routerState.snapshot.url.indexOf("/personnal-return")>=0&&(this.performanceService.subMenuTitle="orion.menu.PERSONAL_RETURN_MENU_TITLE",this.displayLinkTimeWeighted=!1),this.breakpointSubscription=this.breakpointObserver.observe([re.MOBILE]).subscribe(e=>{this.mobile=e.matches})}ngOnDestroy(){this.breakpointSubscription&&this.breakpointSubscription.unsubscribe()}get getlastLoadDt(){return this.personnalReturnService.lastLoadDt}static{this.\u0275fac=function(n){return new(n||t)(f(J),f(gt),f(ae),f(pe),f(ie))}}static{this.\u0275cmp=x({type:t,selectors:[["app-sub-menu-performance"]],inputs:{url:"url"},standalone:!1,decls:1,vars:1,consts:[["howCalculateTimeWeighted",""],["displayLinkPersonalReturn",""],["class","or-box","id","subMenu-performance",4,"ngIf"],["id","subMenu-performance",1,"or-box"],[1,"or-box","or-stretch"],[1,"or-box-child"],[1,"or-box-child","or-box-align-items-top"],[1,"or-box-child","or-p-small",3,"innerHTML"],[1,"or-box-child","or-xsmall-gap"],["name","ico_info","color","blue"],["href","javascript:void(0)",1,"or-colored-link",3,"bncPopover","bncPopoverPosition","bncClassToMovePosition"],["mat-tab-nav-bar","","class","or-box-child or-tabset or-box-end-desktop or-no-gap",4,"ngIf"],["class","or-box or-mobile-stretch",4,"ngIf"],["id","Calculate-Time-Weighted"],[4,"ngIf","ngIfElse"],[3,"innerHtml"],[3,"innerHTML"],["mat-tab-nav-bar","",1,"or-box-child","or-tabset","or-box-end-desktop","or-no-gap"],[4,"ngFor","ngForOf"],["mat-tab-link","","routerLinkActive","or-tab-selected",1,"or-tab","opacity-1","my-1","mr-1",3,"routerLink"],[1,"or-box","or-mobile-stretch"],[1,"or-box-child","or-box-end"],[1,"or-box-child","or-box-end","or-submenu-selected","or-small-gap"],["href","javascript:void(0)",1,"or-colored-link",3,"click"],["name","ico_arrow-up","color","blue",4,"ngIf"],["name","ico_arrow-down","color","blue",4,"ngIf"],["class","or-menu or-submenu or-box or-no-padding or-stretch",4,"ngIf"],["name","ico_arrow-up","color","blue"],["name","ico_arrow-down","color","blue"],[1,"or-menu","or-submenu","or-box","or-no-padding","or-stretch"],["routerLinkActive","or-selected",1,"or-menu-item","or-box-end",3,"click","ngClass","routerLink"]],template:function(n,r){n&1&&v(0,Pd,21,15,"div",2),n&2&&o("ngIf",r.personnalReturnService.hasPerformanceAccess())},dependencies:[Ot,Bt,Mt,X,F,T,de,nt,Xt,Qt,$t,w],encapsulation:2})}}return t})();var zo=(()=>{class t{constructor(e){this.performanceService=e,this._URL_PERSONALRETURN="/accounts/performance/personnal-return",this.performanceService.subMenuTitle="orion.personnal-return.CHANGE_IN_MARKET_VALUE_DEVISE"}static{this.\u0275fac=function(n){return new(n||t)(f(ie))}}static{this.\u0275cmp=x({type:t,selectors:[["app-personnal-return"]],standalone:!1,decls:1,vars:1,consts:[[3,"url"]],template:function(n,r){n&1&&c(0,"app-sub-menu-performance",0),n&2&&o("url",r._URL_PERSONALRETURN)},dependencies:[_i],encapsulation:2})}}return t})();var Mi=(()=>{class t{constructor(e,n,r,_){this.renderer=e,this.el=n,this.router=r,this.performanceService=_,this.chartPerformanceType=rt}ngOnInit(){this.renderer.addClass(this.el.nativeElement,"or-stretch"),this.router.routerState.snapshot.url.indexOf("/time-weighted-return")>=0?this.performanceService.subMenuTitle="orion.personnal-return.RETURN_PERCENT":this.performanceService.subMenuTitle="orion.personnal-return.CHANGE_IN_MARKET_VALUE_DEVISE"}static{this.\u0275fac=function(n){return new(n||t)(f(tt),f(et),f(pe),f(ie))}}static{this.\u0275cmp=x({type:t,selectors:[["app-single-period"]],standalone:!1,decls:1,vars:1,consts:[["chartId","idSinglePerf",3,"chartType"]],template:function(n,r){n&1&&c(0,"app-accounts-perf-chart-and-tab",0),n&2&&o("chartType",r.chartPerformanceType.SPLINE)},dependencies:[vi],encapsulation:2})}}return t})();var Ko=(()=>{class t{constructor(e){this.performanceService=e,this._URL_TIMEWEIGHTED="/accounts/performance/time-weighted-return",this.performanceService.subMenuTitle="orion.personnal-return.RETURN_PERCENT"}static{this.\u0275fac=function(n){return new(n||t)(f(ie))}}static{this.\u0275cmp=x({type:t,selectors:[["app-time-weighted-return"]],standalone:!1,decls:1,vars:1,consts:[[3,"url"]],template:function(n,r){n&1&&c(0,"app-sub-menu-performance",0),n&2&&o("url",r._URL_TIMEWEIGHTED)},dependencies:[_i],encapsulation:2})}}return t})();var Wo=[{path:"",redirectTo:"holdings",pathMatch:"full"},{path:"holdings",component:Lo,data:{dict:["holdings","export","account-summary"],title:["orion.menu.HOLDINGS"]},resolve:{dict:ft,title:Ve}}
9,{path:"quote-graph",component:ko,data:{dict:["holdings","quote-graph","period-selector"],title:["orion.menu.QUOTE_GRAPH"]},resolve:{dict:ft,title:Ve}},{path:"dividend",component:Vo,data:{title:["orion.menu.DIVIDEND"]},resolve:{title:Ve}},{path:"asset-allocation",component:No,data:{dict:["holdings","asset-allocation"],title:["orion.menu.ASSET_ALLOCATION"]},resolve:{dict:ft,title:Ve}},{path:`${Wi.PERFO}`,children:[{path:"**",component:Fo}]},{path:"performance",component:jo,data:{dict:["personnal-return","registered-accounts","performance","sub-menu-performance"],title:["orion.menu.PERFORMANCE"]},resolve:{dict:ft,title:Ve},children:[{path:"",redirectTo:"time-weighted-return",pathMatch:"full"},{path:"time-weighted-return",component:Ko,data:{title:["orion.menu.PERFORMANCE","orion.menu.PERFORMANCE_TIME_WEIGHTED_RETURN"]},resolve:{title:Ve},children:[{path:"",redirectTo:"single-period",pathMatch:"full"},{path:"single-period",component:Mi},{path:"compound-period",component:Bi}]},{path:"personnal-return",component:zo,data:{title:["orion.menu.PERFORMANCE","orion.menu.PERFORMANCE_PERSONAL_RETURN"]},resolve:{title:Ve},children:[{path:"",redirectTo:"single-period",pathMatch:"full"},{path:"single-period",component:Mi},{path:"compound-period",component:Bi}]}]}];var Zo=(()=>{class t{static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275mod=Tt({type:t})}static{this.\u0275inj=It({imports:[Lt,ei,vn]})}}return t})();var Y_=(()=>{class t{static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275mod=Tt({type:t})}static{this.\u0275inj=It({providers:[vt,ie,gt,ii,fe],imports:[Ki.forChild(Wo),Lt,yn,ei,Qn,to,Wn,Yn,Fn,qn,Zo,Gn,fn,Kn,hn,io]})}}return t})();export{Y_ as AccountsModule};

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.