PageSourceSearch

https://app.finimpulse.com/chunk-LQMO5UHH.js

js finimpulse.com collected 2026-10-04 21:47:23 UTC 163,214 bytes, 16 lines download raw bytes

1import{a as vi}from"./chunk-7YXOMMR7.js";import{a as Et}from"./chunk-6UJ3DJVR.js";import{a as fi}from"./chunk-6WUWMHGU.js";import{a as Ae}from"./chunk-X6ZUSJFS.js";import{a as Mt}from"./chunk-TAXM4PAP.js";import{a as di}from"./chunk-7ZNFUFGN.js";import{a as _i}from"./chunk-SK552GEO.js";import{a as gi}from"./chunk-AABD2VLV.js";import{a as ui}from"./chunk-JDBYZFCK.js";import"./chunk-OLDWUJ6P.js";import{a as xt}from"./chunk-RDC7NJ6H.js";import{a as mi,b as Je}from"./chunk-Z34SGCNF.js";import{a as wt}from"./chunk-7Y3O2OHA.js";import"./chunk-VK5POWDE.js";import{a as ci,b as pi}from"./chunk-JKP4Y562.js";import{a as Ie}from"./chunk-EYN7FZRO.js";import"./chunk-E7SZH7ZZ.js";import"./chunk-BYXBJQAS.js";import{a as et}from"./chunk-AKWZHQYK.js";import{a as hi}from"./chunk-LRGYGEJ4.js";import{a as ni,b as ai,c as oi,d as ri,e as li,f as si}from"./chunk-2IB2FXUW.js";import{a as kt}from"./chunk-6EG7DDZY.js";import{a as De}from"./chunk-QVJMECYA.js";import{a as G,b as U}from"./chunk-BTQ3ZHAS.js";import{o as pe,q as Xe,r as Re}from"./chunk-GKSPSK4P.js";import"./chunk-JNQSDDTU.js";import"./chunk-FHQM4MHL.js";import"./chunk-ZAGWB2MP.js";import{b as Me,f as Oe,h as Le}from"./chunk-JR5EHZFX.js";import"./chunk-GNYAB7RK.js";import"./chunk-REBXJJBR.js";import"./chunk-KZ6O4UFR.js";import{a as he,b as Ce}from"./chunk-XUYO53AY.js";import"./chunk-Y4Y4T2FQ.js";import"./chunk-A4RVGZDH.js";import{e as Ke,o as Jt}from"./chunk-ZKHDG5YV.js";import"./chunk-XAFI32DX.js";import{a as tt,b as fe,c as Ci,d as $}from"./chunk-MOMLZEU5.js";import"./chunk-BLZDG6IT.js";import"./chunk-6LKGL5QS.js";import"./chunk-ATAZ4H7C.js";import"./chunk-BIPOZ6EY.js";import"./chunk-PDKS7CIV.js";import"./chunk-LDTPAQ22.js";import"./chunk-U5FD7KPQ.js";import{a as D,b as B}from"./chunk-TCNTYI5F.js";import"./chunk-6ZM2H7CV.js";import{c as Ze}from"./chunk-TXM2VSDT.js";import"./chunk-37744Z2U.js";import"./chunk-HIQRTLXM.js";import"./chunk-UJGCWS6W.js";import{d as ei,e as ti,g as Qe}from"./chunk-G6DIKDAE.js";import"./chunk-VM4DEIJH.js";import"./chunk-UQW65RVG.js";import"./chunk-YJ5HFDYJ.js";import"./chunk-LAI4YBR4.js";import"./chunk-EVVOOTIQ.js";import"./chunk-5Q5VD6VX.js";import"./chunk-5EMEP2FE.js";import{a as Ee,c as Tt,e as ii,k as Ne}from"./chunk-FUQW4URC.js";import{a as Pe}from"./chunk-BX2XGGIJ.js";import{a as Ye,b as bt}from"./chunk-JDKKAUKQ.js";import"./chunk-4ZB57WCE.js";import"./chunk-AFMFXK4D.js";import"./chunk-MIG2UEUK.js";import"./chunk-4HBQP6NS.js";import{b as ne}from"./chunk-I4HG3S2M.js";import"./chunk-QQIMN2JX.js";import"./chunk-F6ETDIXC.js";import"./chunk-A7RBIIUZ.js";import"./chunk-KWOQ4HMT.js";import"./chunk-YJ5DYO5F.js";import"./chunk-RSQPNHZE.js";import"./chunk-XPT67DC2.js";import"./chunk-RDBFOA3X.js";import"./chunk-DOPWH2QC.js";import"./chunk-WBS2ZB34.js";import"./chunk-DKOULGK6.js";import"./chunk-OKFUWLWE.js";import"./chunk-G2RPGXWK.js";import"./chunk-BSMR5HIN.js";import{i as St,j as yt}from"./chunk-7D5TBQRE.js";import"./chunk-MUYF7UN3.js";import"./chunk-O2UZBAYN.js";import"./chunk-4HGNWMUF.js";import"./chunk-M45BUSZV.js";import{N as Zt,ba as Xt,e as X,j as J,ja as ce,t as ee,v as Qt,z as vt}from"./chunk-OQWTGWQI.js";import{D as ke}from"./chunk-JRIYDRTX.js";import"./chunk-FCLK5JCQ.js";import"./chunk-AQGP2UH6.js";import{b as re,c as M}from"./chunk-5VDETJGG.js";import{$a as O,Ab as ie,Bb as Q,Db as ae,Eb as m,Ec as Te,Fb as f,Ga as zt,Gb as j,Hb as je,Hc as qe,Ja as x,La as Wt,Lc as ft,Nb as _t,Ob as ut,Pa as A,Pb as ht,Sb as Ut,Tb as oe,Ua as K,Ub as Z,Vb as jt,Wb as Se,Xa as w,Ya as k,Za as me,_a as te,aa as b,ab as L,ac as C,bb as c,bc as y,bd as Yt,cb as o,cc as q,db as r,dd as Kt,eb as _,fa as u,fb as dt,fc as z,ga as h,gb as mt,hd as xe,ic as Vt,id as we,jc as T,kb as gt,kc as de,la as pt,lb as E,lc as qt,mc as F,na as H,nb as S,nc as v,oc as _e,p as ct,pb as d,qa as ve,qb as Ue,rb as He,va as We,xb as ge,yb as be,yc as ue,z as Ht,za as a,zc as Ct}from"./chunk-Q47N5KYY.js";import{a as se,b as $t}from"./chunk-DE4CES4T.js";var on=2,rn=16,Ve=(()=>{class t{el=b(ve);scrollService=b(et);renderer=b(zt);destroyRef=b(pt);isStuck=!1;lastScrollTop=0;constructor(){this.scrollService.scrollPosition$.pipe(Qt(this.destroyRef)).subscribe(e=>this.updateStuckState(e))}updateStuckState(e){let n=this.scrollService.mainContentNativeElement;if(!n)return;let i=this.el.nativeElement,l=n.getBoundingClientRect(),p=getComputedStyle(n),g=parseFloat(p.paddingTop)||0,N=parseFloat(getComputedStyle(i).top)||0,P=l.top+g+N,W=i.getBoundingClientRect().top-P,V=e>this.lastScrollTop;this.lastScrollTop=e,!this.isStuck&&V&&W<=on?this.setStuck(i,!0):this.isStuck&&!V&&W>rn&&this.setStuck(i,!1)}setStuck(e,n){this.isStuck!==n&&(this.isStuck=n,n?this.renderer.addClass(e,"is-stuck"):this.renderer.removeClass(e,"is-stuck"))}static \u0275fac=function(n){return new(n||t)};static \u0275dir=Wt({type:t,selectors:[["","appStickyStuck",""]]})}return t})();var ln=["*"];function sn(t,s){t&1&&_(0,"app-chevron-right-icon")}function cn(t,s){t&1&&_(0,"app-chevron-down-icon")}var Fe=(()=>{class t{screen=b(Ze);scrollService=b(et);el=b(ve);collapsedValue=v(void 0);collapsedChange=F();isStuck=vt(this.scrollService.scrollPosition$.pipe(ct(()=>!!this.el.nativeElement.closest(".sticky-filter-card")?.classList.contains("is-stuck"))),{initialValue:!1});collapsed=qt(()=>this.collapsedValue()??this.screen.isMobile768());panelCollapsed=T(()=>this.isStuck()&&this.collapsed());toggleCollapsed(){let e=!this.collapsed();this.collapsed.set(e),this.collapsedChange.emit(e)}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-collapsible-filter-card"]],hostVars:2,hostBindings:function(n,i){n&2&&Q("is-collapsed-sticky",i.panelCollapsed())},inputs:{collapsedValue:[1,"collapsedValue"]},outputs:{collapsedChange:"collapsedChange"},ngContentSelectors:ln,decls:10,vars:7,consts:[[1,"filter-card"],["tabindex","0","role","button",1,"filter-card__header",3,"click","keydown.enter","keydown.space"],[1,"filter-card__title"],["type","button","tabindex","-1","aria-hidden","true",1,"filter-card__toggle"],[1,"filter-card__content"]],template:function(n,i){n&1&&(Ue(),o(0,"div",0)(1,"div",1),S("click",function(){return i.toggleCollapsed()})("keydown.enter",function(){return i.toggleCollapsed()})("keydown.space",function(){return i.toggleCollapsed()}),o(2,"span",2),m(3),C(4,"translate"),r(),o(5,"button",3),w(6,sn,1,0,"app-chevron-right-icon")(7,cn,1,0,"app-chevron-down-icon"),r()(),o(8,"div",4),He(9),r()()),n&2&&(a(),Q("filter-card__header--visible",i.isStuck()),K("aria-expanded",!i.panelCollapsed()),a(2),f(y(4,5,"SHARE.FILTERS")),a(3),k(i.panelCollapsed()?6:7))},dependencies:[Qe,Tt,M],styles:["[_nghost-%COMP%]{display:block;width:100%;max-height:25rem;overflow:hidden;border-radius:var(--border-radius-md);transition:width var(--transition-base),max-height var(--transition-base)}.is-collapsed-sticky[_nghost-%COMP%]{width:8rem;max-height:3rem}.filter-card[_ngcontent-%COMP%]{background:var(--bg-secondary);border-radius:var(--border-radius-md);box-shadow:var(--card-shadow)}.filter-card__header[_ngcontent-%COMP%]{display:none;align-items:center;justify-content:space-between;padding:.75rem 1.25rem 0}.filter-card__header--visible[_ngcontent-%COMP%]{display:flex;cursor:pointer;pointer-events:none;animation:_ngcontent-%COMP%_filter-card-interactive .4s step-end forwards}@keyframes _ngcontent-%COMP%_filter-card-interactive{to{pointer-events:auto}}.filter-card__title[_ngcontent-%COMP%]{font-size:var(--text-sm);font-weight:var(--font-semibold);color:var(--main-text-color);white-space:nowrap}.filter-card__toggle[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;width:1.5rem;height:1.5rem;padding:0;background:none;border:none;border-radius:var(--border-radius-sm);color:var(--text-secondary);pointer-events:none}.filter-card__content[_ngcontent-%COMP%]{padding:.75rem var(--p-card-body-
1padding, 1.25rem) var(--p-card-body-padding, 1.25rem)}"]})}return t})();function pn(t,s){if(t&1&&(m(0),C(1,"translate")),t&2){let e=s.$implicit;f(y(1,1,e.label))}}function Si(t){let s=t.getFullYear(),e=String(t.getMonth()+1).padStart(2,"0"),n=String(t.getDate()).padStart(2,"0");return`${s}-${e}-${n}`}function yi(t){let s=new Date,e=new Date;return t==="month"?e.setMonth(e.getMonth()-1):t==="quarter"?e.setMonth(e.getMonth()-3):e.setFullYear(e.getFullYear()-1),{startDate:Si(e),endDate:Si(s)}}var bi=(()=>{class t{store=b($);activePeriod=T(()=>{let e=this.store.filters(),n=["month","quarter","year"];for(let i of n){let l=yi(i);if(e.startDate===l.startDate&&e.endDate===l.endDate)return i}return"custom"});periodModes=[{label:"SELECT.MONTH",value:"month"},{label:"SELECT.QUARTER",value:"quarter"},{label:"SELECT.YEAR",value:"year"},{label:"SELECT.CUSTOM",value:"custom"}];onPeriodChange(e){if(e==="custom")return;let n=yi(e);this.store.setDateRange(n.startDate,n.endDate)}onDateRangeChange(e){this.store.setDateRange(e.startDate,e.endDate)}onFiltersCollapsedChange(e){this.store.setFiltersCardCollapsed(e)}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-overview-filters-card"]],decls:6,vars:7,consts:[["item",""],[3,"collapsedChange","collapsedValue"],[1,"overview-filters"],["optionLabel","label","optionValue","value",1,"all-grey","text-base",3,"ngModelChange","allowEmpty","options","ngModel"],[3,"dateRangeChange","startDate","endDate","advancedPresets"]],template:function(n,i){if(n&1){let l=E();o(0,"app-collapsible-filter-card",1),S("collapsedChange",function(g){return u(l),h(i.onFiltersCollapsedChange(g))}),o(1,"div",2)(2,"p-selectButton",3),S("ngModelChange",function(g){return u(l),h(i.onPeriodChange(g))}),A(3,pn,2,3,"ng-template",null,0,z),r(),o(5,"app-date-range-filter",4),S("dateRangeChange",function(g){return u(l),h(i.onDateRangeChange(g))}),r()()()}n&2&&(c("collapsedValue",i.store.isFiltersCardCollapsed()),a(2),c("allowEmpty",!1)("options",i.periodModes)("ngModel",i.activePeriod()),a(3),c("startDate",i.store.filters.startDate())("endDate",i.store.filters.endDate())("advancedPresets",!0))},dependencies:[Fe,ee,X,J,ne,pe,M],styles:["[_nghost-%COMP%]{display:block}.overview-filters[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:var(--spacing-4);flex-wrap:wrap}p-selectbutton[_ngcontent-%COMP%]{width:fit-content}"]})}return t})();function dn(t,s){if(t&1&&(o(0,"div",9),gt(1,10),r()),t&2){let e=d();Q("ct-summary-stat-card__icon--success",e.tone()==="success")("ct-summary-stat-card__icon--danger",e.tone()==="danger"),a(),c("ngComponentOutlet",s)}}function mn(t,s){if(t&1&&(_(0,"app-info-icon",5),C(1,"translate")),t&2){let e=d();c("pTooltip",y(1,1,e.tooltip()))}}function gn(t,s){t&1&&_(0,"p-skeleton",6)}function _n(t,s){if(t&1&&(o(0,"div",11),m(1),r()),t&2){let e=d();Q("ct-summary-stat-card__value--success",e.tone()==="success")("ct-summary-stat-card__value--danger",e.tone()==="danger"),a(),j(" ",e.value()," ")}}function un(t,s){if(t&1&&(o(0,"span",13),m(1),C(2,"translate"),r()),t&2){let e=d(2);Q("ct-summary-stat-card__subtitle-highlight--success",e.tone()==="success")("ct-summary-stat-card__subtitle-highlight--danger",e.tone()==="danger"),a(),f(y(2,5,s))}}function hn(t,s){if(t&1&&(o(0,"div",8)(1,"span"),m(2),C(3,"translate"),r(),w(4,un,3,7,"span",12),r()),t&2){let e,n=d();a(2),f(y(3,2,s)),a(2),k((e=n.subtitleHighlight())?4:-1,e)}}var Ti=(()=>{class t{title=v.required();value=v.required();icon=v(void 0);tone=v("default");subtitle=v(void 0);subtitleHighlight=v(void 0);isLoading=v(!1);tooltip=v(void 0);static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-congressional-trades-summary-stat-card"]],inputs:{title:[1,"title"],value:[1,"value"],icon:[1,"icon"],tone:[1,"tone"],subtitle:[1,"subtitle"],subtitleHighlight:[1,"subtitleHighlight"],isLoading:[1,"isLoading"],tooltip:[1,"tooltip"]},decls:11,vars:7,consts:[[1,"ct-summary-stat-card","h-full","without-padding"],[1,"ct-summary-stat-card__inner"],[1,"ct-summary-stat-card__head"],[1,"ct-summary-stat-card__icon",3,"ct-summary-stat-card__icon--success","ct-summary-stat-card__icon--danger"],[1,"ct-summary-stat-card__title"],["tooltipPosition","top",1,"ct-summary-stat-card__tooltip-icon",3,"pTooltip"],["width","6rem","height","1.5rem",1,"ct-summary-stat-card__skeleton-value"],[1,"ct-summary-stat-card__value",3,"ct-summary-stat-card__value--success","ct-summary-stat-card__value--danger"],[1,"ct-summary-stat-card__subtitle"],[1,"ct-summary-stat-card__icon"],[3,"ngComponentOutlet"],[1,"ct-summary-stat-card__value"],[1,"ct-summary-stat-card__subtitle-highlight",3,"ct-summary-stat-card__subtitle-highlight--success","ct-summary-stat-card__subtitle-highlight--danger"],[1,"ct-summary-stat-card__subtitle-highlight"]],template:function(n,i){if
1(n&1&&(o(0,"p-card",0)(1,"div",1)(2,"div",2),w(3,dn,2,5,"div",3),o(4,"span",4),m(5),C(6,"translate"),r(),w(7,mn,2,3,"app-info-icon",5),r(),w(8,gn,1,0,"p-skeleton",6)(9,_n,2,5,"div",7),w(10,hn,5,4,"div",8),r()()),n&2){let l,p;a(3),k((l=i.icon())?3:-1,l),a(2),f(y(6,5,i.title())),a(2),k(i.tooltip()?7:-1),a(),k(i.isLoading()?8:9),a(2),k((p=i.subtitle())?10:-1,p)}},dependencies:[B,D,U,G,Ct,Ye,Pe,M],styles:['@charset "UTF-8";[_nghost-%COMP%]{display:contents}.ct-summary-stat-card[_ngcontent-%COMP%]{min-width:0}.ct-summary-stat-card__inner[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:var(--spacing-1);padding:var(--spacing-4) var(--spacing-8);box-sizing:border-box}.ct-summary-stat-card__skeleton-value[_ngcontent-%COMP%]{height:1.5625rem!important}.ct-summary-stat-card__head[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:var(--spacing-1)}.ct-summary-stat-card__icon[_ngcontent-%COMP%]{display:flex;flex-shrink:0;color:var(--text-secondary)}.ct-summary-stat-card__icon--success[_ngcontent-%COMP%]{color:var(--chart-activity-bar)}.ct-summary-stat-card__icon--danger[_ngcontent-%COMP%]{color:var(--additional-danger)}.ct-summary-stat-card__title[_ngcontent-%COMP%]{font-size:var(--text-sm);font-weight:var(--font-semibold);line-height:1.25;color:var(--text-secondary)}.ct-summary-stat-card__tooltip-icon[_ngcontent-%COMP%]{width:.75rem;height:.75rem;color:var(--text-tertiary);cursor:default;flex-shrink:0}.ct-summary-stat-card__tooltip-icon[_ngcontent-%COMP%]   svg[_ngcontent-%COMP%]{min-width:.75rem;min-height:.75rem;width:.75rem;height:.75rem}.ct-summary-stat-card__value[_ngcontent-%COMP%]{font-size:var(--text-xl);font-weight:var(--font-bold);line-height:1.25;color:var(--main-text-color)}.ct-summary-stat-card__value--success[_ngcontent-%COMP%]{color:var(--chart-activity-bar)}.ct-summary-stat-card__value--danger[_ngcontent-%COMP%]{color:var(--additional-danger)}.ct-summary-stat-card__subtitle[_ngcontent-%COMP%]{display:flex;align-items:center;flex-wrap:wrap;gap:var(--spacing-1);font-size:var(--text-sm);font-weight:var(--font-semibold);color:var(--text-secondary)}.ct-summary-stat-card__subtitle-highlight[_ngcontent-%COMP%]{color:var(--text-secondary)}.ct-summary-stat-card__subtitle-highlight--success[_ngcontent-%COMP%]{color:var(--chart-activity-bar)}.ct-summary-stat-card__subtitle-highlight--danger[_ngcontent-%COMP%]{color:var(--additional-danger)}'],changeDetection:0})}return t})();var fn=[[["","heatmapSubControls",""]]],vn=["[heatmapSubControls]"],Sn=(t,s)=>s.label;function yn(t,s){if(t&1&&(m(0),C(1,"translate")),t&2){let e=s.$implicit;f(y(1,1,e.label))}}function bn(t,s){if(t&1){let e=E();o(0,"p-selectButton",20),S("ngModelChange",function(i){u(e);let l=d();return h(l.onResolutionChange(i))}),A(1,yn,2,3,"ng-template",null,0,z),r()}if(t&2){let e=d();c("options",e.resolutionOptions)("ngModel",e.sectorsLimit())("allowEmpty",!1)}}function Tn(t,s){if(t&1&&(o(0,"div",21),m(1),C(2,"translate"),r()),t&2){let e=s.$implicit,n=d();Q("heatmap__col-header--etf",e===n.etfColumnLabel),a(),f(e===n.etfColumnLabel?y(2,3,"CONGRESSIONAL.ETF_FUNDS"):e)}}function xn(t,s){t&1&&_(0,"p-skeleton",23)}function wn(t,s){if(t&1&&(o(0,"div",11),_(1,"p-skeleton",22),r(),O(2,xn,1,0,"p-skeleton",23,te)),t&2){let e=d(2);a(2),L(e.activeColumns())}}function kn(t,s){if(t&1&&O(0,wn,4,0,null,null,te),t&2){let e=d();L(e.skeletonRows)}}function En(t,s){if(t&1){let e=E();o(0,"div",25),S("mouseenter",function(){let i=u(e).$index,l=d().$index,p=d(2);return h(p.onCellHover(l,i))})("mouseleave",function(){u(e);let i=d(3);return h(i.onCellLeave())})("click",function(){let i=u(e),l=i.$implicit,p=i.$index,g=d().$implicit,N=d(2);return h(N.onCellClick(g,l,p))}),m(1),r()}if(t&2){let e=s.$implicit,n=s.$index,i=d(),l=i.$implicit,p=i.$index,g=ht(0),N=d(2);Q("heatmap__cell--etf",N.showEtf()&&n===g.length-1),c("ngClass",N.getCellClasses(e,l,p,n))("pTooltip",N.getCellTooltip(l,e,n)),a(),j(" ",N.formatValue(e,l)," ")}}function Mn(t,s){if(t&1&&(_t(0),o(1,"div",11),m(2),r(),O(3,En,2,5,"div",24,me)),t&2){let e=s.$implicit,n=d(2),i=ut(n.showEtf()?e.allValues:e.values);a(),Q("heatmap__row-label--empty",n.isRowEmpty(e)),a(),f(e.label),a(),L(i)}}function On(t,s){if(t&1&&O(0,Mn,5,4,null,null,Sn),t&2){let e=d();L(e.rows())}}function Ln(t,s){if(t&1){let e=E();o(0,"div",26),S("mouseenter",function(){let i=u(e).$implicit,l=d();return h(l.onLegendHover(i))})("mouseleave",function(){u(e);let i=d();
1return h(i.onLegendLeave())}),r()}if(t&2){let e=s.$implicit,n=d();c("ngClass",n.getLegendSwatchClasses(e))("pTooltip",n.getLegendTooltip(e))}}function Pn(t,s){t&1&&(o(0,"p",17),_(1,"app-info-icon")(2,"span",19),C(3,"translate"),r()),t&2&&(a(2),c("innerHTML",y(3,1,"CONGRESSIONAL.EMPTY_ROWS_NOTE"),We))}function Nn(t,s){t&1&&(_(0,"span",19),C(1,"translate")),t&2&&c("innerHTML",y(1,1,"CONGRESSIONAL.ETF_INCLUDED_NOTE"),We)}function Rn(t,s){t&1&&(_(0,"span",19),C(1,"translate")),t&2&&c("innerHTML",y(1,1,"CONGRESSIONAL.SECTOR_ONLY_NOTE"),We)}var Dn=["Technology","Financial Svcs","Healthcare","Energy","Industrials","Consumer Cyclical","Consumer Defensive","Comm. Services","Utilities","Real Estate"],xi="ETF / Funds",In={1:"CONGRESSIONAL.LEGEND_LOW",2:"CONGRESSIONAL.LEGEND_LOW_MEDIUM",3:"CONGRESSIONAL.LEGEND_MEDIUM",4:"CONGRESSIONAL.LEGEND_HIGH",5:"CONGRESSIONAL.LEGEND_PEAK"},An=[{label:"SELECT.TOP_50",value:50},{label:"SELECT.TOP_200",value:200},{label:"SELECT.TOP_500",value:500}],Ot=(()=>{class t{translateService=b(re);columns=v(Dn);rows=v([]);isLoading=v(!1);valueSuffix=v("%");showResolutionSelector=v(!1);sectorsLimit=v(500);sectorsLimitChange=F();etfColumnLabel=xi;resolutionOptions=An;skeletonRows=[0,1,2,3];showEtf=H(!1);activeColumns=T(()=>this.showEtf()?[...this.columns(),xi]:this.columns());maxValue=T(()=>{let e=this.rows().flatMap(i=>this.showEtf()?i.allValues:i.values),n=e.length?Math.max(...e):0;return n>0?n:1});emptyRowLabels=T(()=>{let e=this.rows().filter(n=>n.values.every(i=>i===0)&&n.allValues.every(i=>i===0)).map(n=>n.label);return new Set(e)});hasEmptyRows=T(()=>this.emptyRowLabels().size>0);legendLevels=[1,2,3,4,5];hoveredLevel=H(null);hoveredCell=H(null);getCellLevel(e){let n=e/this.maxValue();return n<=.17?1:n<=.37?2:n<=.57?3:n<=.87?4:5}getCellClasses(e,n,i,l){let p=this.isRowEmpty(n),g=this.getCellLevel(e),N=this.hoveredLevel(),P=this.hoveredCell(),R=!p&&(N!==null&&g!==N||P!==null&&N===null&&!(P.rowIdx===i&&P.colIdx===l));return{[`heatmap__cell--level-${g}`]:!p,"heatmap__cell--empty":p,"heatmap__cell--dimmed":R}}getLegendSwatchClasses(e){let n=this.hoveredLevel();return{[`heatmap__cell--level-${e}`]:!0,"heatmap__legend-swatch--active":n===e}}isRowEmpty(e){return this.emptyRowLabels().has(e.label)}formatValue(e,n){return this.isRowEmpty(n)?"\u2014":`${e}${this.valueSuffix()}`}getCellTooltip(e,n,i){if(this.isRowEmpty(e))return this.translateService.instant("CONGRESSIONAL.NO_SECTOR_DATA_TOOLTIP",{row:e.label});let l=this.activeColumns()[i];return`${e.label} \u2014 ${l}: ${this.formatValue(n,e)}`}getLegendTooltip(e){return this.translateService.instant(In[e])}onCellHover(e,n){this.hoveredCell.set({rowIdx:e,colIdx:n})}onCellLeave(){this.hoveredCell.set(null)}onLegendHover(e){this.hoveredLevel.set(e)}onLegendLeave(){this.hoveredLevel.set(null)}onCellClick(e,n,i){console.log("Heatmap cell clicked:",e.label,this.activeColumns()[i],n)}onResolutionChange(e){this.sectorsLimitChange.emit(e)}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-sector-allocation-heatmap"]],inputs:{columns:[1,"columns"],rows:[1,"rows"],isLoading:[1,"isLoading"],valueSuffix:[1,"valueSuffix"],showResolutionSelector:[1,"showResolutionSelector"],sectorsLimit:[1,"sectorsLimit"]},outputs:{sectorsLimitChange:"sectorsLimitChange"},ngContentSelectors:vn,decls:36,vars:19,consts:[["item",""],[1,"heatmap"],[1,"heatmap__header"],[1,"card-title"],[1,"heatmap__header-controls"],["optionLabel","label","optionValue","value",1,"all-grey","text-base",3,"options","ngModel","allowEmpty"],[1,"heatmap__toggle-label"],[1,"text-sm","secondary-text"],[3,"ngModelChange","ngModel"],[1,"heatmap__grid-wrapper"],[1,"heatmap__grid"],[1,"heatmap__row-label"],[1,"heatmap__col-header",3,"heatmap__col-header--etf"],[1,"heatmap__legend"],[1,"heatmap__legend-label"],[1,"heatmap__legend-track"],["tooltipPosition","top",1,"heatmap__legend-swatch",3,"ngClass","pTooltip"],[1,"chart-note"],[1,"chart-note","chart-note--separated"],[3,"innerHTML"],["optionLabel","label","optionValue","value",1,"all-grey","text-base",3,"ngModelChange","options","ngModel","allowEmpty"],[1,"heatmap__col-header"],["width","8.5rem","height","0.875rem","borderRadius","var(--border-radius-sm)"],["height","2rem","borderRadius","var(--border-radius-md)",1,"heatmap__cell-skeleton"],["tooltipStyleClass","heatmap-cell-tooltip","tooltipPosition","top",1,"heatmap__cell",3,"heatmap__cell--etf","ngClass","pTooltip"],["tooltipStyleClass","heatmap-cell-tooltip","tooltipPosition","top",1,"heatmap__cell",3,"mouseenter","mouseleave","click","ngClass","pTooltip"],["tooltipPosition","top",1,"heatmap__legend-swatch",3,"mouseenter","mouseleave","ngClass","pTooltip"]],template:function(n,i){n&1&&(Ue(fn),o(0,"p-card")(1,"div",1)(2,"div",2)(3,"h3",3),m(4),C(5,"translate"),r(),o(6,"div",4),w(7,bn,3,3,"p-selectButton",5),o(8,"label",6)(9,"span",7),m(10),C(11,"translate"),r(),o(12,"p-toggleswitch",8),S("ngModelChange",function(p){return i.showEtf.set(p)}),r()()()(),He(13),o(14,"div",9)(15,"div",10),_(16,"div",11),O(17,Tn,3,5,"div",12,te),w(19,kn,2,0)(20,On,2,0),r()(),o(21,"div",13)(22,"span",14),m(23),C(24,"translate"),r(),o(25,"div",15),O(26,Ln,1,2,"div",16,te),r(),o(28,"span",14),m(29),C(30,"translate"),r()(),w(31,Pn,4,3,"p",17),o(32,"p",18),_(33,"app-info-icon"),w(34,Nn,2,3,"span",19)(35,Rn,2,3,"span",19),r()()()),n&2&&(a(4),f(y(5,11,"CONGRESSIONAL.HEATMAP_TITLE")),a(3),k(i.showResolutionSelector()?7:-1),a(3),f(y(11,13,"CONGRESSIONAL.INCLUDE_ETF")),a(2),c("ngModel",i.showEtf()),a(3),ie("--grid-col-count",i.activeColumns().length),a(2),L(i.activeColumns()),a(2),k(i.isLoading()?19:20),a(4),f(y(24,15,"CONGRESSIONAL.LOW")),a(3),L(i.legendLevels),a(3),f(y(30,17,"CONGRESSIONAL.HIGH")),a(2),k(i.hasEmptyRows()?31:-1),a(3),k(i.showEtf()?34:35))},dependencies:[B,D,ue,bt,Ye,G,kt,ee,X,J,ne,Pe,M],styles:["[_nghost-%COMP%]{display:block}.heatmap[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:var(--spacing-4)}.heatmap__header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:var(--spacing-3);flex-wrap:wrap}
1.heatmap__header-controls[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--spacing-3);flex-wrap:wrap}.heatmap__toggle-label[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;gap:var(--spacing-2);cursor:pointer;flex-shrink:0}.heatmap__grid-wrapper[_ngcontent-%COMP%]{overflow-x:auto;overflow-y:hidden}.heatmap__grid[_ngcontent-%COMP%]{display:grid;width:100%;min-width:min-content;grid-template-columns:max-content repeat(var(--grid-col-count, 10),minmax(5.5rem,1fr));gap:.375rem;overflow:hidden}.heatmap__row-label[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:flex-end;padding-right:var(--spacing-3);font-size:var(--text-sm);color:var(--main-text-color);min-height:2rem;text-align:right;white-space:nowrap}.heatmap__row-label--empty[_ngcontent-%COMP%]{color:var(--muted-text-color);opacity:.6}.heatmap__cell-skeleton[_ngcontent-%COMP%]{display:block}.heatmap__col-header[_ngcontent-%COMP%]{display:flex;align-items:flex-end;justify-content:center;text-align:center;font-size:var(--text-sm);color:var(--main-text-color);padding-bottom:var(--spacing-1);line-height:1.3;min-height:2.5rem}.heatmap__col-header--etf[_ngcontent-%COMP%]{color:var(--muted-text-color);border-left:1px solid var(--border-light);padding-left:var(--spacing-2)}.heatmap__cell[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;height:2rem;border-radius:var(--border-radius-md);font-size:var(--text-sm);cursor:pointer;transition:opacity .2s ease,transform .15s ease}.heatmap__cell[_ngcontent-%COMP%]:hover{transform:scale(1.06)}.heatmap__cell--dimmed[_ngcontent-%COMP%]{opacity:.25}.heatmap__cell--empty[_ngcontent-%COMP%]{background:var(--surface-secondary, var(--border-light));color:var(--muted-text-color);cursor:default;font-size:var(--text-xs)}.heatmap__cell--empty[_ngcontent-%COMP%]:hover{transform:none}.heatmap__cell--etf[_ngcontent-%COMP%]{border-left:1px solid var(--border-light)}.heatmap__cell--level-1[_ngcontent-%COMP%]{background:var(--heatmap-level-1);color:var(--main-text-color)}.heatmap__cell--level-2[_ngcontent-%COMP%]{background:var(--heatmap-level-2);color:var(--main-text-color)}.heatmap__cell--level-3[_ngcontent-%COMP%]{background:var(--heatmap-level-3);color:var(--main-text-color)}.heatmap__cell--level-4[_ngcontent-%COMP%]{background:var(--heatmap-level-4);color:var(--always-white)}.heatmap__cell--level-5[_ngcontent-%COMP%]{background:var(--heatmap-level-5);color:var(--always-white)}.heatmap__legend[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--spacing-2)}.heatmap__legend-label[_ngcontent-%COMP%]{font-size:var(--text-sm);color:var(--muted-text-color);white-space:nowrap}.heatmap__legend-track[_ngcontent-%COMP%]{display:flex;gap:.1875rem;padding-block:.2rem;overflow:hidden}.heatmap__legend-swatch[_ngcontent-%COMP%]{width:2rem;height:.75rem;border-radius:3px;cursor:pointer;transition:transform .15s ease,opacity .2s ease}.heatmap__legend-swatch[_ngcontent-%COMP%]:hover, .heatmap__legend-swatch--active[_ngcontent-%COMP%]{transform:scaleY(1.4);opacity:1}"]})}return t})();function Vn(t,s){if(t&1){let e=E();o(0,"div",2),S("chartInit",function(i){u(e);let l=d();return h(l.onChartInit(i))})("chartClick",function(i){u(e);let l=d();return h(l.onChartClick(i))}),r()}if(t&2){let e=d();ie("height",e.height()),c("options",e.chartOptions())}}function Fn(t,s){if(t&1&&(o(0,"div",3)(1,"p",4),m(2),C(3,"translate"),r()()),t&2){let e=d();ie("height",e.height()),a(2),f(y(3,3,e.placeholderText()))}}var Lt=(()=>{class t{data=v.required();height=v("280px");itemClick=F();labelFontSize=v(16);showValues=v(!1);labelColor=v("#ffffff");placeholderText=v("SHARE.NO_DATA_AVAILABLE");mainState=b(ce);chartInstance=null;chartOptions=T(()=>{let e=this.data();this.mainState.isDark();let n=this.labelFontSize(),i=this.labelColor(),l=this.showValues(),p=this.getCssVariable("--bg-secondary"),g=this.getCssVariable("--additional"),N=P=>se(se({name:P.name,value:P.value,sector:P.sector,fullName:P.fullName,logoUrl:P.logoUrl,valueLabel:P.valueLabel,itemStyle:{color:P.color||g,borderColor:p,borderWidth:2,gapWidth:2}},P.fontSize?{label:{fontSize:P.fontSize}}:{}),P.children?{children:P.children.map(N)}:{});return{backgroundColor:"transparent",tooltip:{trigger:"item",backgroundColor:this.getCssVariable("--chart-tooltip-bg"),borderColor:"transparent",textStyle:{color:this.getCssVariable("--chart-tooltip-text"),fontSize:13},formatter:P=>{let R=P,W=R.data?.sector,V=R.data?.fullName,Y=R.data?.logoUrl,Ge=Y?`<img src="${Y}" style="width:1.6875rem;height:1.6875rem;border-radius:50%;flex-shrink:0;object-fit:cover" />`:"",at=V?`<strong>${R.name}</strong> <span style="opacity:0.7">${V}</span>`:`<strong>${R.name}</strong>`,ot=`<div style="display:flex;align-items:center;gap:0.5rem">${Ge}<span>${at}</span></div>`,$e=`<div><strong>
1${R.value.toLocaleString()}</strong></div>`,rt=W?`<div style="font-size:0.6875rem;opacity:0.7">${W}</div>`:"";return`<div style="display:flex;flex-direction:column;gap:0.125rem">${ot}${$e}${rt}</div>`}},series:[{type:"treemap",data:e.map(N),width:"100%",height:"100%",top:0,left:0,right:0,bottom:0,roam:!1,nodeClick:!1,breadcrumb:{show:!1},visibleMin:300,label:{show:!0,position:"inside",align:"center",verticalAlign:"middle",color:i,fontWeight:"bold",fontSize:n,fontFamily:'"Nunito Sans", sans-serif',formatter:l?P=>{let R=P,W=R.data?.valueLabel;return W?`${R.name}
2${W}`:R.name}:"{b}"},upperLabel:{show:!1},itemStyle:{borderColor:p,borderWidth:2,gapWidth:2},emphasis:{itemStyle:{shadowBlur:10,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"rgba(0, 0, 0, 0.25)"}},blur:{itemStyle:{opacity:.3}},levels:[{itemStyle:{borderColor:p,borderWidth:2,gapWidth:2},upperLabel:{show:!1}},{itemStyle:{borderColor:p,borderWidth:1,gapWidth:1}}]}]}});constructor(){de(()=>{this.mainState.isDark(),this.chartInstance&&this.chartInstance.setOption(this.chartOptions())})}onChartInit(e){this.chartInstance=e}onChartClick(e){e?.name&&this.itemClick.emit(e.name)}highlightSector(e){if(this.chartInstance){if(e===null){this.chartInstance.dispatchAction({type:"downplay",seriesIndex:0});return}this.data().filter(n=>n.sector===e).forEach(n=>{this.chartInstance.dispatchAction({type:"highlight",seriesIndex:0,name:n.name})})}}getCssVariable(e){return getComputedStyle(document.documentElement).getPropertyValue(e).trim()}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-treemap-chart"]],inputs:{data:[1,"data"],height:[1,"height"],labelFontSize:[1,"labelFontSize"],showValues:[1,"showValues"],labelColor:[1,"labelColor"],placeholderText:[1,"placeholderText"]},outputs:{itemClick:"itemClick"},features:[Ut([pi({echarts:()=>import("./chunk-FBHPDQAJ.js")})])],decls:2,vars:1,consts:[["echarts","",1,"treemap-container","treemap-container--clickable",3,"options","height"],[1,"treemap-placeholder",3,"height"],["echarts","",1,"treemap-container","treemap-container--clickable",3,"chartInit","chartClick","options"],[1,"treemap-placeholder"],[1,"text-muted"]],template:function(n,i){n&1&&w(0,Vn,1,3,"div",0)(1,Fn,4,5,"div",1),n&2&&k(i.data().length?0:1)},dependencies:[ci,M],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;width:100%;flex:1}.treemap-container[_ngcontent-%COMP%]{width:100%}.treemap-container--clickable[_ngcontent-%COMP%]{cursor:pointer}.treemap-placeholder[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;width:100%}.treemap-placeholder[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{font-size:var(--text-sm)}"]})}return t})();var Bn=(t,s)=>s.sector;function Gn(t,s){if(t&1&&(m(0),C(1,"translate")),t&2){let e=s.$implicit;f(y(1,1,e.label))}}function $n(t,s){if(t&1&&(m(0),C(1,"translate")),t&2){let e=s.$implicit;f(y(1,1,e.label))}}function Hn(t,s){if(t&1){let e=E();o(0,"p-selectButton",12),S("ngModelChange",function(i){u(e);let l=d();return h(l.onTransferChange(i))}),A(1,Gn,2,3,"ng-template",null,0,z),r(),o(3,"p-selectButton",12),S("ngModelChange",function(i){u(e);let l=d();return h(l.onChamberChange(i))}),A(4,$n,2,3,"ng-template",null,0,z),r()}if(t&2){let e=d();c("options",e.transferOptions)("ngModel",e.transferType())("allowEmpty",!1),a(3),c("options",e.chamberOptions)("ngModel",e.chamber())("allowEmpty",!1)}}function zn(t,s){if(t&1&&(m(0),C(1,"translate")),t&2){let e=s.$implicit;f(y(1,1,e.label))}}function Wn(t,s){if(t&1&&(o(0,"div",13),_(1,"p-skeleton",14)(2,"p-skeleton",15),r()),t&2){let e=s.$implicit;a(2),c("width",e%2===0?"72px":"56px")}}function Un(t,s){if(t&1&&(o(0,"div",6),O(1,Wn,3,1,"div",13,te),r()),t&2){let e=d();a(),L(e.skeletonLegend)}}function jn(t,s){if(t&1){let e=E();o(0,"button",17),S("click",function(){let i=u(e).$implicit,l=d(2);return h(l.toggleSector(i.sector))})("mouseenter",function(){let i=u(e).$implicit,l=d(2);return h(l.onLegendHover(i.sector))})("mouseleave",function(){u(e);let i=d(2);return h(i.onLegendLeave())}),_(1,"span",18),o(2,"span",19),m(3),C(4,"translate"),r()()}if(t&2){let e=s.$implicit,n=d(2).hiddenSectors().has(e.sector);Q("heatmap-card__legend-item--hidden",n),c("pTooltip",e.tooltip),a(),ie("background-color",e.color),a(2),f(y(4,6,e.label))}}function qn(t,s){if(t&1&&(o(0,"div",6),O(1,jn,5,8,"button",16,Bn),r()),t&2){let e=d();a(),L(e.legendItems())}}function Yn(t,s){t&1&&(o(0,"div",24),_(1,"p-skeleton",22),r())}function Kn(t,s){t&1&&(o(0,"div",24),_(1,"p-skeleton",22),r())}function Qn(t,s){if(t&1&&(o(0,"div",24),_(1,"p-skeleton",22),r()),t&2){let e=s.$implicit;Q("heatmap-skeleton__cell--tall",e===1)}}function Zn(t,s){t&1&&(o(0,"div",24),_(1,"p-skeleton",22),r())}function Xn(t,s){t&1&&(o(0,"div",24),_(1,"p-skeleton",22),r())}function Jn(t,s){if(t&1&&(o(0,"div",20)(1,"div",21),_(2,"p-skeleton",22),r(),o(3,"div",23),O(4,Yn,2,0,"div",24,te),r(),o(6,"div",25),O(7,Kn,2,0,"div",24,te),r(),o(9,"div",25),O(10,Qn,2,2,"div",26,te),r(),o(12,"div",27),O(13,Zn,2,0,"div",24,te),r(),o(15,"div",28),O(16,Xn,2,0,"div",24,te),r()()),t&2){let e=d();ie("height",e.chartHeight()),a(4),L(e.skeletonColA),a(3),L(e.skeletonColB),a(3),L(e.skeletonColC),a(3),L(e.skeletonGrid),a(3),L(e.skeletonTiny)}}function ea(t,s){if(t&1){let e=E();o(0,"app-treemap-chart",29),S("itemClick",function(i){u(e);let l=d();return h(l.onTickerClick(i))}),r()}if(t&2){let e=d();c("data",e.chartData())("height",e.chartHeight())("labelFontSize",16)("showValues",!0)}}function ta(t,s){t&1&&(o(0,"span"),m(1),C(2,"translate"),r()),t&2&&(a(),f(y(2,1,"CONGRESSIONAL.BUY_SELL_FILTER_NOTE")))}var wi=["#45a2ff","#289e8f","#6466fa","#007fff","#f99000","#289e8f","#e07b54","#a78bfa","#289e8f","#fb7185","#fbbf24","#60a5fa","#f472b6","#289e8f","#c084fc"],ia={Technology:"#45a2ff","Information Technology":"#45a2ff",Energy:"#289e8f",Finance:"#6466fa","Financial Services":"#6466fa","Financial Svcs":"#6466fa",Healthcare:"#007fff","Health Care":"#007fff",Defense:"#f99000",Industrials:"#f99000","Communication Services":"#289e8f","Comm. Services":"#289e8f","Consumer Cyclical":"#e07b54","Consumer Defensive":"#a78bfa",Utilities:"#289e8f","Real Estate":"#fb7185"},ki="CONGRESSIONAL.OTHER_SECTOR",na="#9ca3af",it=(()=>{class t{items=v.required();isLoading=v(!1);title=v("CONGRESSIONAL.AMOUNT_BY_TICKER_SECTOR");chartHeight=v("560px");showFlowControls=v(!1);transferType=v("all");chamber=v("all");transferTypeChange=F();chamberChange=F();treemapChart=_e(Lt);router=b(xe);screenSize=b(Ze);translateService=b(re);hiddenSectors=H(new Set);visibleLimit=H(50);limitOptions=[{label:"SELECT.TOP_20",value:20},{label:"SELECT.TOP_50",value:50},{label:"SELECT.ALL",value:0}];transferOptions=[{label:"SELECT.ALL",value:"all"},{label:"SELECT.SELLS",value:"sell"},{label:"SELECT.BUYS",value:"buy"}];chamberOptions=[{label:"SELECT.ALL",value:"all"},{label:"SELECT.HOUSE",value:"house"},{label:"SELECT.SENATE",value:"senate"}];cardTitle=T(()=>this.title());skeletonColA=[0,1,2];skeletonColB=[0,1,2,3];skeletonColC=[0,1,2];skeletonGrid=Array.from({length:12},(e,n)=>n);skeletonTiny=[0,1,2,3,4,5];skeletonLegend=[0,1,2,3,4];sectorColorMap=T(()=>
2{let e=[...new Set(this.items().map(l=>l.sector))],n=new Map,i=0;return e.forEach(l=>{l?n.set(l,ia[l]??wi[i++%wi.length]):n.set(l,na)}),n});chartData=T(()=>{let e=this.sectorColorMap(),n=this.hiddenSectors(),i=this.visibleLimit(),l=this.items().filter(V=>!n.has(V.sector)).map(V=>({name:V.ticker,fullName:V.name,value:V.volume,color:e.get(V.sector)??"#888",sector:V.sector,logoUrl:V.logo})).sort((V,Y)=>Y.value-V.value),p=i>0?l.slice(0,i):l,N=p.reduce((V,Y)=>V+Y.value,0)*.02,P=p[0]?.value??0,R=11,W=26;return p.map(V=>$t(se({},V),{valueLabel:V.value>=N?fe(V.value):void 0,fontSize:P>0?Math.round(R+(W-R)*Math.sqrt(V.value/P)):R}))});legendItems=T(()=>{let e=this.sectorColorMap(),n=this.items(),i=new Map;for(let p of n)i.set(p.sector,(i.get(p.sector)??0)+p.volume);let l=[...i.values()].reduce((p,g)=>p+g,0);return[...new Set(n.map(p=>p.sector))].map(p=>{let g=i.get(p)??0,N=l>0?g/l*100:0,P=p||ki;return{sector:p,color:e.get(p)??"#888",label:P,tooltip:`${p||this.translateService.instant(ki)}: ${Zt(g)} (${Xt(N,1,!1,!1)})`}}).sort((p,g)=>(i.get(g.sector)??0)-(i.get(p.sector)??0))});onTransferChange(e){this.transferTypeChange.emit(e)}onChamberChange(e){this.chamberChange.emit(e)}onTickerClick(e){if(this.screenSize.isTouchDevice())return;let n=this.router.serializeUrl(this.router.createUrlTree(["/user/asset",e,"summary"]));window.open(n,"_blank")}setLimit(e){this.visibleLimit.set(e)}onLegendHover(e){this.treemapChart()?.highlightSector(e)}onLegendLeave(){this.treemapChart()?.highlightSector(null)}toggleSector(e){let n=new Set(this.items().map(p=>p.sector)),i=this.hiddenSectors();if(i.size===n.size-1&&!i.has(e))this.hiddenSectors.set(new Set);else{let p=new Set(n);p.delete(e),this.hiddenSectors.set(p)}}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-volume-by-ticker-sector-card"]],viewQuery:function(n,i){n&1&&ge(i.treemapChart,Lt,5),n&2&&be()},inputs:{items:[1,"items"],isLoading:[1,"isLoading"],title:[1,"title"],chartHeight:[1,"chartHeight"],showFlowControls:[1,"showFlowControls"],transferType:[1,"transferType"],chamber:[1,"chamber"]},outputs:{transferTypeChange:"transferTypeChange",chamberChange:"chamberChange"},decls:21,vars:13,consts:[["item",""],[1,"heatmap-card"],[1,"heatmap-card__header"],[1,"card-title"],[1,"heatmap-card__controls"],["optionLabel","label","optionValue","value",3,"ngModelChange","options","ngModel","allowEmpty"],[1,"heatmap-card__legend"],[1,"heatmap-card__chart-scroll"],[1,"heatmap-skeleton",3,"height"],[3,"data","height","labelFontSize","showValues"],[1,"chart-note","chart-note--separated"],[3,"innerHTML"],["optionLabel","label","optionValue","value",1,"all-grey",3,"ngModelChange","options","ngModel","allowEmpty"],[1,"heatmap-card__legend-item","heatmap-card__legend-item--skeleton"],["width","0.625rem","height","0.625rem","borderRadius","9999px"],["height","0.75rem","borderRadius","4px",3,"width"],["type","button","tooltipPosition","top",1,"heatmap-card__legend-item",3,"heatmap-card__legend-item--hidden","pTooltip"],["type","button","tooltipPosition","top",1,"heatmap-card__legend-item",3,"click","mouseenter","mouseleave","pTooltip"],[1,"heatmap-card__legend-dot"],[1,"heatmap-card__legend-label"],[1,"heatmap-skeleton"],[1,"heatmap-skeleton__xl"],["width","100%","height","100%"],[1,"heatmap-skeleton__col"],[1,"heatmap-skeleton__cell"],[1,"heatmap-skeleton__col","heatmap-skeleton__col--narrow"],[1,"heatmap-skeleton__cell",3,"heatmap-skeleton__cell--tall"],[1,"heatmap-skeleton__grid"],[1,"heatmap-skeleton__col","heatmap-skeleton__col--tiny"],[3,"itemClick","data","height","labelFontSize","showValues"]],template:function(n,i){if(n&1){let l=E();o(0,"p-card")(1,"div",1)(2,"div",2)(3,"h3",3),m(4),C(5,"translate"),r(),o(6,"div",4),w(7,Hn,6,6),o(8,"p-selectButton",5),S("ngModelChange",function(g){return u(l),h(i.setLimit(g))}),A(9,zn,2,3,"ng-template",null,0,z),r()()(),w(11,Un,3,0,"div",6)(12,qn,3,0,"div",6),o(13,"div",7),w(14,Jn,18,2,"div",8)(15,ea,1,4,"app-treemap-chart",9),r(),o(16,"p",10),_(17,"app-info-icon")(18,"span",11),C(19,"translate"),w(20,ta,3,3,"span"),r()()()}
2n&2&&(a(4),f(y(5,9,i.cardTitle())),a(3),k(i.showFlowControls()?7:-1),a(),c("options",i.limitOptions)("ngModel",i.visibleLimit())("allowEmpty",!1),a(3),k(i.isLoading()?11:12),a(3),k(i.isLoading()?14:15),a(4),c("innerHTML",y(19,11,"CONGRESSIONAL.TILE_SIZE_NOTE"),We),a(2),k(i.showFlowControls()?20:-1))},dependencies:[B,D,G,ne,ee,X,J,Lt,bt,Ye,Pe,M],styles:["[_nghost-%COMP%]{display:block;min-width:0}.heatmap-card[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:var(--spacing-4);min-width:0}.heatmap-card__chart-scroll[_ngcontent-%COMP%]{min-width:0;overflow-x:auto}.heatmap-card__chart-scroll[_ngcontent-%COMP%]   .heatmap-skeleton[_ngcontent-%COMP%], .heatmap-card__chart-scroll[_ngcontent-%COMP%]   app-treemap-chart[_ngcontent-%COMP%]{display:block;min-width:45.625rem}.heatmap-card__header[_ngcontent-%COMP%]{display:flex;align-items:flex-start;justify-content:space-between;flex-wrap:wrap;gap:var(--spacing-3)}.heatmap-card__controls[_ngcontent-%COMP%]{display:flex;align-items:center;flex-wrap:wrap;gap:var(--spacing-3)}.heatmap-card__legend[_ngcontent-%COMP%]{display:flex;align-items:center;flex-wrap:wrap;gap:var(--spacing-2) var(--spacing-4)}.heatmap-card__legend-item[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--spacing-2);background:none;border:none;padding:0;cursor:pointer;transition:opacity .2s ease}.heatmap-card__legend-item--hidden[_ngcontent-%COMP%]{opacity:.35}.heatmap-card__legend-item--hidden[_ngcontent-%COMP%]   .heatmap-card__legend-label[_ngcontent-%COMP%]{text-decoration:line-through}.heatmap-card__legend-item--skeleton[_ngcontent-%COMP%]{cursor:default;gap:var(--spacing-2)}.heatmap-card__legend-item--skeleton[_ngcontent-%COMP%]   p-skeleton[_ngcontent-%COMP%]{display:block;flex-shrink:0}.heatmap-skeleton[_ngcontent-%COMP%]{display:flex;gap:.1875rem;overflow:hidden;border-radius:var(--border-radius-md)}.heatmap-skeleton__xl[_ngcontent-%COMP%]{flex:0 0 22%;height:100%}.heatmap-skeleton__xl[_ngcontent-%COMP%]   p-skeleton[_ngcontent-%COMP%]{display:block;width:100%;height:100%}.heatmap-skeleton__col[_ngcontent-%COMP%]{flex:0 0 13%;display:flex;flex-direction:column;gap:.1875rem;height:100%}.heatmap-skeleton__col--narrow[_ngcontent-%COMP%]{flex-basis:10%}.heatmap-skeleton__col--tiny[_ngcontent-%COMP%]{flex-basis:9%}.heatmap-skeleton__grid[_ngcontent-%COMP%]{flex:1;display:grid;grid-template-columns:repeat(3,1fr);grid-template-rows:repeat(4,1fr);gap:.1875rem;height:100%}.heatmap-skeleton__cell[_ngcontent-%COMP%]{flex:1;min-height:0;border-radius:var(--border-radius-sm);overflow:hidden}.heatmap-skeleton__cell--tall[_ngcontent-%COMP%]{flex:2}.heatmap-skeleton__cell[_ngcontent-%COMP%]   p-skeleton[_ngcontent-%COMP%]{display:block;width:100%;height:100%}.heatmap-card__legend-dot[_ngcontent-%COMP%]{display:inline-block;width:.625rem;height:.625rem;border-radius:var(--border-radius-full);flex-shrink:0}.heatmap-card__legend-label[_ngcontent-%COMP%]{font-size:var(--text-sm);color:var(--muted-text-color);white-space:nowrap}"],changeDetection:0})}return t})();var aa=()=>({hasZoom:!1,hasTooltip:!0});function oa(t,s){if(t&1){let e=E();o(0,"button",9),S("click",function(){let i=u(e).$implicit,l=d(2);return h(l.toggleParty(i))})("mouseenter",function(){let i=u(e).$implicit,l=d(2);return h(l.onLegendHover(i))})("mouseleave",function(){u(e);let i=d(2);return h(i.onLegendLeave())}),_(1,"span",10),o(2,"span",11),m(3),C(4,"translate"),r()()}if(t&2){let e=s.$implicit,n=d(2);Q("volume-chart__legend-item--inactive",!n.selectedParties().has(e)),a(),ie("background-color",n.partyColors()[e]),a(2),f(y(4,5,n.partyLabels[e]))}}function ra(t,s){if(t&1&&(o(0,"div",4),O(1,oa,5,7,"button",8,te),r()),t&2){let e=d();a(),L(e.parties)}}function la(t,s){if(t&1&&(o(0,"div",13)(1,"div",14),_(2,"p-skeleton",15),r(),o(3,"div",16),_(4,"p-skeleton",17),r()()),t&2){let e=s.$implicit,n=d(2);a(),ie("width",n.skeletonLabelWidth()),a(),c("width",e.nameWidth),a(2),c("width",e.barWidth)}}function sa(t,s){if(t&1&&(o(0,"div",12),O(1,la,5,4,"div",13,me),r()),t&2){let e=d();ie("padding-left",e.skeletonPaddingLeft()),a(),L(e.skeletonRows)}}function ca(t,s){if(t&1){let e=E();o(0,"app-bar-chart",18),S("chartInitialized",function(i){u(e);let l=d();
2return h(l.onChartInitialized(i))}),r()}if(t&2){let e=d();c("series",e.chartSeries())("options",oe(5,aa))("autoRoundCorners",!1)("customConfig",e.chartCustomConfig())("height",e.displayedHeightPx()+"px")}}function pa(t,s){if(t&1&&(o(0,"div",7),_(1,"p-button",19),C(2,"translate"),r()),t&2){let e=d();a(),c("label",y(2,2,"CONGRESSIONAL.VIEW_MORE"))("routerLink",e.viewMoreLink())}}var Ft=["democrat","republican","other"],Ei={democrat:"SELECT.DEMOCRAT",republican:"SELECT.REPUBLICAN",other:"CONGRESSIONAL.NOT_SPECIFIED"},ze=20,Pt=26,da=4,ma=[{nameWidth:"9rem",barWidth:"88%"},{nameWidth:"7.5rem",barWidth:"76%"},{nameWidth:"8rem",barWidth:"71%"},{nameWidth:"6.5rem",barWidth:"65%"},{nameWidth:"8.5rem",barWidth:"60%"},{nameWidth:"7rem",barWidth:"54%"},{nameWidth:"9rem",barWidth:"49%"},{nameWidth:"6rem",barWidth:"43%"},{nameWidth:"7.5rem",barWidth:"38%"},{nameWidth:"8rem",barWidth:"32%"},{nameWidth:"6.5rem",barWidth:"27%"},{nameWidth:"7rem",barWidth:"22%"}],Nt=(()=>{class t{items=v.required();isLoading=v(!1);title=v("CONGRESSIONAL.TOP_50_POLITICIANS_VOLUME");valueMode=v("volume");maxItems=v(0);scrollable=v(!0);viewMoreLink=v(null);fixedHeight=v(!1);skeletonRows=ma;parties=Ft;partyLabels=Ei;selectedParties=H(new Set(Ft));mainStore=b(ce);screenSize=b(Ze);translateService=b(re);wheelScrollableChart=null;chartWheelListener=null;currentStartValue=0;chartInstance=null;windowWidth=H(window.innerWidth);windowResizeListener=()=>this.windowWidth.set(window.innerWidth);skeletonPaddingLeft=T(()=>this.windowWidth()>=1200?"3rem":"1.5rem");skeletonLabelWidth=T(()=>this.windowWidth()>=1200?"10rem":"8rem");heightTweenRafId=null;snappedItemsRef=null;targetHeightPx=T(()=>{let e=this.visibleItems().length,n=this.scrollable()?Math.min(e,ze):e;return n>0?n*Pt+40:320});lockedHeightPx=T(()=>{let e=this.maxItems(),n=e>0?Math.min(this.items().length,e):this.items().length,i=this.scrollable()?Math.min(n,ze):n;return i>0?i*Pt+40:320});displayedHeightPx=H(0);constructor(){window.addEventListener("resize",this.windowResizeListener),de(()=>{if(this.fixedHeight()){this.displayedHeightPx.set(this.lockedHeightPx());return}let e=this.targetHeightPx();this.animateHeightTo(e)})}ngOnDestroy(){this.cancelHeightTween(),this.detachWheelScroll(),window.removeEventListener("resize",this.windowResizeListener)}getCssVar(e){return getComputedStyle(document.documentElement).getPropertyValue(e).trim()}partyColors=T(()=>(this.mainStore.isDark(),{democrat:this.getCssVar("--additional"),republican:this.getCssVar("--additional-danger"),other:this.getCssVar("--border-light")}));otherEmphasisColor=T(()=>(this.mainStore.isDark(),this.getCssVar("--muted-text-color")));toggleParty(e){let n=this.selectedParties(),i=n.size===1&&n.has(e);this.selectedParties.set(i?new Set(Ft):new Set([e]))}visibleItems=T(()=>{let e=this.items().filter(i=>this.selectedParties().has(i.party)),n=this.maxItems();return n>0?e.slice(0,n):e});chartSeries=T(()=>{let e=this.visibleItems(),n=this.partyColors(),i=this.otherEmphasisColor();return[{type:"bar",name:this.valueMode()==="trades"?this.translateService.instant("CONGRESSIONAL.TRADES_SERIES"):this.translateService.instant("CONGRESSIONAL.VOLUME_SERIES"),barMaxWidth:Pt-8,cursor:"default",emphasis:{focus:"self"},blur:{itemStyle:{opacity:.12}},data:e.map(p=>se({value:p.value,itemStyle:{color:n[p.party],borderRadius:[0,4,4,0]}},p.party==="other"&&{emphasis:{itemStyle:{color:i,opacity:1}}}))}]});chartCustomConfig=T(()=>{let e=this.visibleItems().map(W=>W.name);this.mainStore.isDark(),this.valueMode();let n=this.windowWidth()>=1200,i=n?190:120,l=n?"205px":"135px",p=this.scrollable()&&e.length>ze,g=Math.min(e.length-1,ze-1),N=this.getCssVar("--border-light"),P=this.getCssVar("--basic-primary"),R=p?[{type:"inside",orient:"vertical",yAxisIndex:0,startValue:0,endValue:g,zoomLock:!0,zoomOnMouseWheel:!1,moveOnMouseWheel:!0},{type:"slider",orient:"vertical",yAxisIndex:0,startValue:0,endValue:g,width:5,right:2,zoomLock:!0,showDetail:!1,showDataShadow:!1,brushSelect:!1,fillerColor:P+"60",backgroundColor:N,borderColor:"transparent",handleSize:8,handleStyle:{color:P,borderColor:"transparent"},moveHandleSize:0}]:[];return{animationDurationUpdate:400,animationEasingUpdate:"cubicOut",xAxis:{type:"value",show:!1},yAxis:{type:"category",data:e,inverse:!0,axisLabel:{width:i,overflow:"truncate",fontSize:12,color:this.getCssVar("--main-text-color")},splitLine:{show:!1},axisTick:{show:!1}
2,axisLine:{show:!1}},grid:se({left:l,right:p?"18px":"20px",top:"10px",bottom:"10px",containLabel:!1},this.fixedHeight()&&{height:`${e.length*Pt}px`}),tooltip:{trigger:"axis",triggerOn:this.screenSize.isTouchDevice()?"click":"mousemove|click",axisPointer:{type:"shadow"},formatter:W=>{let Y=W.find(At=>At.value>0);if(!Y)return"";let at=this.valueMode()==="volume"?`$${(Y.value/1e6).toFixed(1)}M`:`${Y.value}`,ot=this.partyColors(),$e=this.visibleItems().find(At=>At.name===Y.name),rt=$e?ot[$e.party]:Y.color;return`<div style="margin-bottom:4px;font-weight:bold">${Y.name}</div>
3            <div style="display:flex;align-items:center;gap:8px">
4              <span style="display:inline-block;width:10px;height:10px;border-radius:50%;background:${rt}"></span>
5              <span>${this.translateService.instant(Ei[$e?.party??"other"])}: <strong>${at}</strong></span>
6            </div>`}},dataZoom:R}});cancelHeightTween(){this.heightTweenRafId!==null&&(cancelAnimationFrame(this.heightTweenRafId),this.heightTweenRafId=null)}animateHeightTo(e){let n=this.items();if(this.snappedItemsRef!==n){this.snappedItemsRef=n,this.cancelHeightTween(),this.displayedHeightPx.set(e),this.chartInstance?.resize({height:e});return}this.cancelHeightTween();let l=this.displayedHeightPx(),p=e-l;if(p===0)return;let g=400,N=performance.now(),P=R=>{let W=R-N,V=Math.min(W/g,1),Y=1-Math.pow(1-V,3),Ge=Math.round(l+p*Y);this.displayedHeightPx.set(Ge),V<1?this.heightTweenRafId=requestAnimationFrame(P):this.heightTweenRafId=null};this.heightTweenRafId=requestAnimationFrame(P)}onChartInitialized(e){if(this.detachWheelScroll(),this.chartInstance=e,!this.scrollable())return;let n=e,i=n.getDom();i&&(this.wheelScrollableChart=n,this.currentStartValue=0,this.chartWheelListener=l=>{this.handleChartWheel(n,l)},i.addEventListener("wheel",this.chartWheelListener,{passive:!1}))}onLegendHover(e){if(!this.chartInstance)return;this.visibleItems().map((i,l)=>({item:i,idx:l})).filter(({item:i})=>i.party===e).map(({idx:i})=>i).forEach(i=>{this.chartInstance.dispatchAction({type:"highlight",seriesIndex:0,dataIndex:i})})}onLegendLeave(){this.chartInstance?.dispatchAction({type:"downplay",seriesIndex:0})}detachWheelScroll(){if(!this.wheelScrollableChart)return;let e=this.wheelScrollableChart.getDom();e&&this.chartWheelListener&&e.removeEventListener("wheel",this.chartWheelListener),this.wheelScrollableChart=null,this.chartWheelListener=null}handleChartWheel(e,n){let i=this.visibleItems().length;if(i<=ze)return;let l=Math.max(0,i-ze),p=n.deltaY>0?1:-1,g=Math.max(1,Math.ceil(Math.abs(n.deltaY)/120))*da,N=Math.min(l,Math.max(0,this.currentStartValue+p*g)),P=Math.min(i-1,N+ze-1);N!==this.currentStartValue&&(n.preventDefault(),this.currentStartValue=N,e.dispatchAction({type:"dataZoom",dataZoomIndex:0,startValue:N,endValue:P}),e.dispatchAction({type:"dataZoom",dataZoomIndex:1,startValue:N,endValue:P}))}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-top-politicians-volume-chart"]],inputs:{items:[1,"items"],isLoading:[1,"isLoading"],title:[1,"title"],valueMode:[1,"valueMode"],maxItems:[1,"maxItems"],scrollable:[1,"scrollable"],viewMoreLink:[1,"viewMoreLink"],fixedHeight:[1,"fixedHeight"]},decls:10,vars:4,consts:[[1,"volume-chart"],[1,"volume-chart__header"],[1,"card-title"],[1,"volume-chart__header-actions"],[1,"volume-chart__legend"],[1,"flex","flex-col","gap-2","pt-1",2,"padding-right","1.25rem",3,"padding-left"],[3,"series","options","autoRoundCorners","customConfig","height"],[1,"volume-chart__footer"],["type","button",1,"volume-chart__legend-item",3,"volume-chart__legend-item--inactive"],["type","button",1,"volume-chart__legend-item",3,"click","mouseenter","mouseleave"],[1,"volume-chart__legend-swatch"],[1,"volume-chart__legend-label"],[1,"flex","flex-col","gap-2","pt-1",2,"padding-right","1.25rem"],[1,"flex","items-center",2,"height","1.625rem"],[2,"flex-shrink","0","padding-right","0.75rem"],["height","0.75rem",3,"width"],[1,"flex-1"],["height","1.125rem",3,"width"],[3,"chartInitialized","series","options","autoRoundCorners","customConfig","height"],["severity","secondary",3,"label","routerLink"]],template:function(n,i){n&1&&(o(0,"p-card")(1,"div",0)(2,"div",1)(3,"h3",2),m(4),r(),o(5,"div",3),w(6,ra,3,0,"div",4),r()(),w(7,sa,3,2,"div",5)(8,ca,1,6,"app-bar-chart",6),w(9,pa,3,4,"div",7),r()()),n&2&&(a(4),f(i.title()),a(2),k(i.isLoading()?-1:6),a(),k(i.isLoading()?7:8),a(2),k(i.viewMoreLink()&&
6!i.isLoading()?9:-1))},dependencies:[St,B,D,Je,U,G,we,M],styles:[".volume-chart[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:var(--spacing-4)}.volume-chart__header[_ngcontent-%COMP%]{display:flex;align-items:flex-start;justify-content:space-between;flex-wrap:wrap;gap:var(--spacing-3)}.volume-chart__header-actions[_ngcontent-%COMP%]{display:flex;align-items:center;flex-wrap:wrap;gap:var(--spacing-4)}.volume-chart__footer[_ngcontent-%COMP%]{display:flex;justify-content:center}.volume-chart__legend[_ngcontent-%COMP%]{display:flex;align-items:center;flex-wrap:wrap;gap:var(--spacing-2) var(--spacing-8)}.volume-chart__legend-item[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--spacing-2);background:none;border:none;padding:0;cursor:pointer;opacity:1;transition:opacity .2s ease}.volume-chart__legend-item--inactive[_ngcontent-%COMP%]{opacity:.35}.volume-chart__legend-item[_ngcontent-%COMP%]:hover{opacity:.75}.volume-chart__legend-item[_ngcontent-%COMP%]:hover.volume-chart__legend-item--inactive{opacity:.55}.volume-chart__legend-swatch[_ngcontent-%COMP%]{display:inline-block;width:1rem;height:1rem;border-radius:var(--border-radius-sm);flex-shrink:0}.volume-chart__legend-label[_ngcontent-%COMP%]{font-size:var(--text-xs);font-weight:var(--font-semibold);color:var(--text-secondary);white-space:nowrap}"]})}return t})();var ga=()=>["/user","congressional-trades","politicians"],_a=(t,s)=>s.title;function ua(t,s){if(t&1&&_(0,"app-congressional-trades-summary-stat-card",2),t&2){let e=s.$implicit,n=d();c("title",e.title)("value",e.value)("icon",e.icon)("tone",e.tone)("subtitle",e.subtitle)("subtitleHighlight",e.subtitleHighlight)("tooltip",e.tooltip)("isLoading",n.store.overviewTab.isLoading())}}var Mi=(()=>{class t{store=b($);statCards=T(()=>{let e=this.store.overviewMeta();return[{title:"CONGRESSIONAL.STAT_ACTIVITY",value:e?String(e.total_count):"\u2014",subtitle:"CONGRESSIONAL.STAT_TOTAL_TRADES",icon:Et,tone:"default",tooltip:"CONGRESSIONAL.STAT_ACTIVITY_TOOLTIP"},{title:"CONGRESSIONAL.STAT_BUY_SIDE",value:e?fe(e.total_buy_amount):"\u2014",subtitle:"CONGRESSIONAL.STAT_TOTAL_BUY_AMOUNT",icon:gi,tone:"success"},{title:"CONGRESSIONAL.STAT_SELL_SIDE",value:e?fe(e.total_sell_amount):"\u2014",subtitle:"CONGRESSIONAL.STAT_TOTAL_SELL_AMOUNT",icon:_i,tone:"danger"}]});onTreemapTransferChange(e){this.store.setTickerTreemapTransferType(e)}onTreemapChamberChange(e){this.store.setTickerTreemapChamber(e)}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-congressional-trades-overview"]],decls:8,vars:16,consts:[["appStickyStuck","",1,"sticky-filter-card"],[1,"overview-stats"],[3,"title","value","icon","tone","subtitle","subtitleHighlight","tooltip","isLoading"],[3,"rows","isLoading"],[3,"transferTypeChange","chamberChange","items","isLoading","showFlowControls","transferType","chamber"],[3,"items","isLoading","title","maxItems","fixedHeight","viewMoreLink"]],template:function(n,i){n&1&&(_(0,"app-overview-filters-card",0),o(1,"div",1),O(2,ua,1,8,"app-congressional-trades-summary-stat-card",2,_a),r(),_(4,"app-sector-allocation-heatmap",3),o(5,"app-volume-by-ticker-sector-card",4),S("transferTypeChange",function(p){return i.onTreemapTransferChange(p)})("chamberChange",function(p){return i.onTreemapChamberChange(p)}),r(),_(6,"app-top-politicians-volume-chart",5),C(7,"translate")),n&2&&(a(2),L(i.statCards()),a(2),c("rows",i.store.overviewHeatmapRows())("isLoading",i.store.overviewHeatmapTab.isLoading()),a(),c("items",i.store.tickerTreemapHeatmapData())("isLoading",i.store.tickerTreemapLoading())("showFlowControls",!0)("transferType",i.store.tickerTreemapTransferType())("chamber",i.store.tickerTreemapChamber()),a(),c("items",i.store.overviewTopPoliticiansVm())("isLoading",i.store.overviewTab.isLoading())("title",y(7,13,"CONGRESSIONAL.TOP_20_POLITICIANS_VOLUME"))("maxItems",20)("fixedHeight",!0)("viewMoreLink",oe(15,ga)))},dependencies:[bi,Ti,Ot,it,Nt,Ve,M],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:var(--spacing-4);flex:1}.overview-stats[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:var(--spacing-4)}@media(max-width:560px){.overview-stats[_ngcontent-%COMP%]{grid-template-columns:1fr}}"],changeDetection:0})}return t})();var ha=(t,s)=>s.symbol;function Ca(t,s){t&1&&(o(0,"div",4),_(1,"p-skeleton",5)(2,"p-skeleton",6)(3,"p-skeleton",7)(4,"p-skeleton",8),r())}function fa(t,s){if(t&1&&O(0,Ca,5,0,"div",4,me),t&2){let e=d();L(e.skeletonRows)}}function va(t,s){if(t&1&&(o(0,"div",4)(1,"span",9),m(2),r(),o(3,"span",10),m(4),r(),o(5,"span",11),m(6),r(),_(7,"p-tag",12),r()),t&2){let e=s.$implicit,n=d(2);a(2),f(e.symbol),a(2),f(e.owner),a(2),f(e.valueRange),a(),ae(n.getTypeClass(e.type)),c("value",e.type)}}function Sa(t,s){if(t&1&&O(0,va,8,6,"div",4,ha),t&2){let e=d();L(e.trades())}}var Oi=(()=>{class t{trades=v([]);isLoading=v(!1);skeletonRows=Array(4);getTypeClass(e){return e==="Buy"?"p-muted-green":"red-muted"}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-largest-trades-card"]],inputs:{trades:[1,"trades"],isLoading:[1,"isLoading"]},decls:9,vars:8,consts:[[1,"largest-trades-p-card","h-full","body-
6h-full"],[1,"largest-trades-card"],["id","largest-trades-title",1,"largest-trades-card__title"],["role","table",1,"largest-trades-card__rows"],["role","row",1,"largest-trades-card__row"],["width","3rem","height","0.875rem"],["height","0.875rem"],["width","5.5rem","height","0.875rem"],["width","2.5rem","height","1.25rem"],["role","cell",1,"largest-trades-card__symbol"],["role","cell",1,"largest-trades-card__owner"],["role","cell",1,"largest-trades-card__value"],["role","cell",3,"value"]],template:function(n,i){n&1&&(o(0,"p-card",0)(1,"section",1)(2,"h3",2),m(3),C(4,"translate"),r(),o(5,"div",3),C(6,"translate"),w(7,fa,2,0)(8,Sa,2,0),r()()()),n&2&&(a(),K("aria-labelledby","largest-trades-title"),a(2),f(y(4,4,"CONGRESSIONAL.LARGEST_TRADES")),a(2),K("aria-label",y(6,6,"CONGRESSIONAL.LARGEST_TRADES")),a(2),k(i.isLoading()?7:8))},dependencies:[B,D,U,G,Ce,he,M],styles:["[_nghost-%COMP%]{display:contents}.largest-trades-p-card[_ngcontent-%COMP%]{min-width:0}.largest-trades-card[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:var(--spacing-3)}.largest-trades-card__title[_ngcontent-%COMP%]{font-size:var(--text-base);font-weight:var(--font-bold);color:var(--main-text-color)}.largest-trades-card__rows[_ngcontent-%COMP%]{display:flex;flex-direction:column}.largest-trades-card__row[_ngcontent-%COMP%]{display:grid;grid-template-columns:minmax(3.75rem,.3fr) minmax(0,1fr) minmax(min-content,.5fr) max-content;align-items:center;gap:var(--spacing-3);min-height:1.875rem;border-bottom:1px solid var(--p-datatable-body-cell-border-color);font-size:var(--text-sm)}.largest-trades-card__symbol[_ngcontent-%COMP%]{color:var(--chart-activity-bar);font-weight:var(--font-semibold)}.largest-trades-card__owner[_ngcontent-%COMP%]{min-width:0;color:var(--text-secondary);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.largest-trades-card__value[_ngcontent-%COMP%]{color:var(--main-text-color);text-align:right;white-space:nowrap;overflow:hidden}"]})}return t})();var ya=(t,s)=>s.range;function ba(t,s){t&1&&(o(0,"div",4),_(1,"p-skeleton",5)(2,"p-skeleton",6)(3,"p-skeleton",7),r())}function Ta(t,s){if(t&1&&O(0,ba,4,0,"div",4,me),t&2){let e=d();L(e.skeletonRows)}}function xa(t,s){if(t&1&&(o(0,"div",4)(1,"span",8),m(2),r(),_(3,"app-progress-bar",9),o(4,"span",10),m(5),r()()),t&2){let e=s.$implicit;a(2),f(e.range),a(),c("height","0.375rem")("staticColor","chart-activity-bar")("value",e.percentage),a(2),j("",e.percentage,"%")}}function wa(t,s){if(t&1&&O(0,xa,6,5,"div",4,ya),t&2){let e=d();L(e.items())}}var Li=(()=>{class t{items=v([]);isLoading=v(!1);skeletonRows=Array(4);static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-delay-distribution-card"]],inputs:{items:[1,"items"],isLoading:[1,"isLoading"]},decls:9,vars:8,consts:[[1,"delay-distribution-p-card","h-full","body-h-full"],[1,"delay-distribution-card"],["id","delay-distribution-title",1,"delay-distribution-card__title"],[1,"delay-distribution-card__rows"],[1,"delay-distribution-card__row"],["width","5rem","height","0.875rem"],["height","0.375rem",1,"delay-distribution-card__progress"],["width","2rem","height","0.875rem"],[1,"delay-distribution-card__range"],[1,"delay-distribution-card__progress",3,"height","staticColor","value"],[1,"delay-distribution-card__value"]],template:function(n,i){n&1&&(o(0,"p-card",0)(1,"section",1)(2,"h3",2),m(3),C(4,"translate"),r(),o(5,"div",3),C(6,"translate"),w(7,Ta,2,0)(8,wa,2,0),r()()()),n&2&&(a(),K("aria-labelledby","delay-distribution-title"),a(2),f(y(4,4,"CONGRESSIONAL.DELAY_DISTRIBUTION")),a(2),K("aria-label",y(6,6,"CONGRESSIONAL.DELAY_DISTRIBUTION")),a(2),k(i.isLoading()?7:8))},dependencies:[B,D,U,G,di,M],styles:["[_nghost-%COMP%]{display:contents}.delay-distribution-p-card[_ngcontent-%COMP%]{min-width:0}.delay-distribution-card[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:var(--spacing-3)}.delay-distribution-card__title[_ngcontent-%COMP%]{font-size:var(--text-base);font-weight:var(--font-bold);color:var(--main-text-color)}.delay-distribution-card__rows[_ngcontent-%COMP%]{display:flex;flex-direction:column}.delay-distribution-card__row[_ngcontent-%COMP%]{display:grid;grid-template-columns:minmax(5.5rem,.9fr) minmax(6rem,1.4fr) 2.5rem;align-items:center;gap:var(--spacing-3);min-height:1.875rem;border-bottom:1px solid var(--p-datatable-body-cell-border-color);font-size:var(--text-sm)}.delay-distribution-card__range[_ngcontent-%COMP%]{color:var(--text-secondary);white-space:nowrap}.delay-distribution-card__progress[_ngcontent-%COMP%]{min-width:0}.delay-distribution-card__value[_ngcontent-%COMP%]{color:var(--main-text-color);text-align:right;white-space:nowrap}"]})}return t})();var ka=()=>["48%","90%"],Pi=(()=>{class t{data=v([]);isLoading=v(!1);static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-trades-by-owner-card"]],inputs:{data:[1,"data"],isLoading:[1,"isLoading"]},decls:7,vars:14,consts:[[1,"trades-by-owner-p-card","h-full","body-
6h-full"],["aria-labelledby","trades-by-owner-title",1,"trades-by-owner-card"],[1,"trades-by-owner-card__header"],["id","trades-by-owner-title",1,"trades-by-owner-card__title"],[1,"trades-by-owner-card__chart",3,"data","decimalPlaces","height","legendPlacement","legendLabelFormat","showLegendDividers","segmentBorderWidth","donutRadius","noLegendMargin","isLoading"]],template:function(n,i){n&1&&(o(0,"p-card",0)(1,"section",1)(2,"header",2)(3,"h3",3),m(4),C(5,"translate"),r()(),_(6,"app-pie-chart-with-legend",4),r()()),n&2&&(a(4),f(y(5,11,"CONGRESSIONAL.TRADES_BY_OWNER")),a(2),c("data",i.data())("decimalPlaces",0)("height","100%")("legendPlacement","right")("legendLabelFormat","parentheses")("showLegendDividers",!1)("segmentBorderWidth",3)("donutRadius",oe(13,ka))("noLegendMargin",!0)("isLoading",i.isLoading()))},dependencies:[B,D,mi,M],styles:["[_nghost-%COMP%]{display:contents}.trades-by-owner-p-card[_ngcontent-%COMP%]{min-height:20rem;min-width:0}.trades-by-owner-card[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:stretch;height:100%}.trades-by-owner-card__header[_ngcontent-%COMP%]{flex-shrink:0}.trades-by-owner-card__title[_ngcontent-%COMP%]{font-size:var(--text-base);font-weight:var(--font-bold);color:var(--main-text-color)}.trades-by-owner-card__chart[_ngcontent-%COMP%]{display:block;flex:1;min-height:0;width:100%}"]})}return t})();var Dt=(()=>{class t{label=v("SHARE.CLEAR_FILTER");cleared=F();onClear(){this.cleared.emit()}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-clear-filter-button"]],inputs:{label:[1,"label"]},outputs:{cleared:"cleared"},decls:5,vars:3,consts:[["type","button",1,"clear-filter-btn",3,"click"],[1,"clear-filter-btn__icon"]],template:function(n,i){n&1&&(o(0,"button",0),S("click",function(){return i.onClear()}),_(1,"app-refresh-icon",1),o(2,"span"),m(3),C(4,"translate"),r()()),n&2&&(a(3),f(y(4,1,i.label())))},dependencies:[Ne,M],styles:["[_nghost-%COMP%]{display:inline-flex}.clear-filter-btn[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:var(--spacing-2);height:2.25rem;padding:0 var(--spacing-3);background:transparent;border:none;border-radius:var(--border-radius-md);color:var(--muted-text-color);font-size:var(--text-sm);font-weight:var(--font-medium);cursor:pointer;white-space:nowrap;transition:color .15s ease}.clear-filter-btn[_ngcontent-%COMP%]:hover{color:var(--main-text-color)}.clear-filter-btn__icon[_ngcontent-%COMP%]{font-size:var(--text-sm)}"]})}return t})();var Ma=["table"],Oa=["politicianAutocomplete"],La=["tickerAutocomplete"],Pa=(t,s,e)=>({"mr-auto":t,"mx-auto":s,"ml-auto":e}),Na=t=>["/user/asset",t,"summary"],Ni=(t,s)=>s.field;function Ra(t,s){if(t&1){let e=E();o(0,"th",16)(1,"app-table-header-cell-content",17),S("columnSort",function(i){u(e);let l=d(2);return h(l.onColumnSort(i.field,i.event))}),r()()}if(t&2){let e=s.$implicit,n=d(2);c("ngStyle",e.headStyle),a(),c("col",e)("sortStates",n.sortStates)}}
6function Da(t,s){if(t&1&&(o(0,"tr"),O(1,Ra,2,3,"th",16,Ni),r()),t&2){let e=d();a(),L(e.columns)}}function Ia(t,s){if(t&1&&(o(0,"td",16),_(1,"p-skeleton",19),r()),t&2){let e=s.$implicit,n=s.$index;c("ngStyle",e.cellStyle),a(),c("ngClass",Se(3,Pa,e.align==="left"||!e.align,e.align==="center",e.align==="right"))("width",n%2===0?"40%":"60%")}}function Aa(t,s){if(t&1&&(o(0,"tr"),O(1,Ia,2,7,"td",16,Ni),r()),t&2){let e=d(2);a(),L(e.columns)}}function Va(t,s){if(t&1){let e=E();o(0,"tr",18)(1,"td",16)(2,"span",20),m(3),r()(),o(4,"td",16),_(5,"p-tag",21),r(),o(6,"td",16)(7,"span",22),m(8),r()(),o(9,"td",16)(10,"a",23),S("click",function(i){return u(e),h(i.stopPropagation())}),m(11),r()(),o(12,"td",16)(13,"span"),m(14),r()(),o(15,"td",16)(16,"span"),m(17),r()(),o(18,"td",16)(19,"span"),m(20),C(21,"date"),r()(),o(22,"td",16)(23,"span"),m(24),C(25,"date"),r()(),o(26,"td",16)(27,"span"),m(28),r()(),o(29,"td",16)(30,"span"),m(31),r()(),o(32,"td",16),_(33,"p-tag",21),r()()}if(t&2){let e=d().$implicit,n=d();a(),c("ngStyle",n.columns[0].cellStyle),a(2),f(e.politician),a(),c("ngStyle",n.columns[1].cellStyle),a(),ae(n.getPartyClass(e.party)),c("value",e.party),a(),c("ngStyle",n.columns[2].cellStyle),a(2),f(e.chamber),a(),c("ngStyle",n.columns[3].cellStyle),a(),c("routerLink",Z(35,Na,e.ticker)),a(),f(e.ticker),a(),c("ngStyle",n.columns[4].cellStyle),a(2),f(e.assetName),a(),c("ngStyle",n.columns[5].cellStyle),a(2),f(e.owner),a(),c("ngStyle",n.columns[6].cellStyle),a(2),f(q(21,29,e.transactionDate,"MMM d, y")),a(2),c("ngStyle",n.columns[7].cellStyle),a(2),f(q(25,32,e.reportDate,"MMM d, y")),a(2),c("ngStyle",n.columns[8].cellStyle),a(),ae(n.getDelayClass(e.delay)),a(),j("",e.delay,"d"),a(),c("ngStyle",n.columns[9].cellStyle),a(2),f(e.amount),a(),c("ngStyle",n.columns[10].cellStyle),a(),ae(n.getTypeClass(e.type)),c("value",e.type)}}function Fa(t,s){if(t&1&&w(0,Aa,3,0,"tr")(1,Va,34,37,"tr",18),t&2){let e=d();k(e.isLoading()?0:1)}}function Ba(t,s){if(t&1&&(o(0,"tr",24)(1,"td",25)(2,"div",26),_(3,"app-search-icon",27),o(4,"span",22),m(5),C(6,"translate"),r()()()()),t&2){let e=d();a(),K("colspan",e.columns.length),a(4),f(y(6,2,"CONGRESSIONAL.NO_TRANSACTIONS_FOUND"))}}function Ga(t,s){if(t&1){let e=E();o(0,"app-table-paginator",28),S("rowsChange",function(i){u(e);let l=d();return h(l.onRowsChange(i))}),r()}if(t&2){let e=s.$implicit;c("currentRows",e.rows)("state",e)("useLocalPagination",!1)}}var Ri=(()=>{class t{table=_e("table");politicianAutocomplete=_e("politicianAutocomplete");tickerAutocomplete=_e("tickerAutocomplete");trades=v.required();isLoading=v(!1);startDate=v(null);endDate=v(null);maxDate=v(null);tickerSuggestions=v(null);politicianSuggestions=v(null);isTickerSearching=v(!1);isPoliticianSearching=v(!1);politicianFilterValue=v("");totalCount=v(0);limit=v(10);offset=v(0);dateRangeChange=F();filtersCleared=F();paginationChange=F();tickerSearch=F();politicianSearch=F();tickerSelect=F();politicianSelect=F();clearTickerSuggestions=F();clearPoliticianSuggestions=F();sortChange=F();tableData=T(()=>this.isLoading()&&this.trades().length===0?Array(10).fill({}):this.trades());columns=[{field:"politician",header:"CONGRESSIONAL.POLITICIAN",sortable:!0,sortField:"last_name",align:"left",headStyle:{"min-width":"10rem"},cellStyle:{"text-align":"left"},defaultVisible:!0,type:"text"},{field:"party",header:"CONGRESSIONAL.PARTY",sortable:!0,align:"center",headStyle:{"min-width":"5rem"},cellStyle:{"text-align":"center"},defaultVisible:!0,type:"status"},{field:"chamber",header:"CONGRESSIONAL.CHAMBER",sortable:!0,align:"center",headStyle:{"min-width":"6rem"},cellStyle:{"text-align":"center"},defaultVisible:!0,type:"text"},{field:"ticker",header:"CONGRESSIONAL.TICKER",sortable:!0,align:"left",headStyle:{"min-width":"5rem"},cellStyle:{"text-align":"left"},defaultVisible:!0,type:"custom"},{field:"assetName",header:"CONGRESSIONAL.ASSET_NAME",sortable:!0,sortField:"name",align:"left",headStyle:{"min-width":"7rem"},cellStyle:{"text-align":"left"},defaultVisible:!0,type:"text"},{field:"owner",header:"CONGRESSIONAL.OWNER",sortable:!0,align:"center",headStyle:{"min-width":"5.5rem"},cellStyle:{"text-align":"center"},defaultVisible:!0,type:"text"},{field:"transactionDate",header:"CONGRESSIONAL.TRANSACTION_DATE",sortable:!0,sortField:"transaction_date",align:"right",headStyle:{"min-width":"7rem"},cellStyle:{"text-align":"right"},defaultVisible:!0,type:"date"},{field:"reportDate",header:"CONGRESSIONAL.REPORT_DATE",sortable:!0,sortField:"report_date",align:"right",headStyle:{"min-width":"6.5rem"},cellStyle:{"text-align":"right"},defaultVisible:!0,type:"date"},{field:"delay",header:"CONGRESSIONAL.DELAY",sortable:!0,sortField:"delay_in_days",align:"right",headStyle:{"min-width":"4.5rem"},cellStyle:{"text-align":"right"},defaultVisible:!0,type:"custom"},{field:"amount",header:"CONGRESSIONAL.AMOUNT",sortable:!0,sortField:"mid_point",align:"right",headStyle:{"min-width":"7rem"},cellStyle:{"text-align":"right"},defaultVisible:!0,type:"text"},{field:"type",header:"CONGRESSIONAL.TYPE",sortable:!0,sortField:"transfer_type",align:"center",headStyle:{"min-width":"4.5rem"},cellStyle:{"text-align":"center"},defaultVisible:!0,type:"status"}];tableSortService=b(Ie);sortStates=this.tableSortService.createSortStates();onClearFilters(){this.politicianAutocomplete()?.clear(),this.tickerAutocomplete()?.clear(),this.clearTickerSuggestions.emit(),this.clearPoliticianSuggestions.emit(),this.filtersCleared.emit()}onDateRangeChange(e){this.dateRangeChange.emit(e)}
6onPoliticianValueChange(e){this.politicianSearch.emit(e)}onPoliticianClear(){this.clearPoliticianSuggestions.emit()}onPoliticianSelect(e){this.politicianSelect.emit(e)}onTickerValueChange(e){this.tickerSearch.emit(e)}onTickerClear(){this.clearTickerSuggestions.emit()}onTickerSelect(e){this.tickerSelect.emit(e)}onRowsChange(e){this.paginationChange.emit({limit:e,offset:0})}pageChange(e){let n=e.first??0,i=e.rows??this.limit();this.paginationChange.emit({limit:i,offset:n})}onColumnSort(e,n){this.tableSortService.onColumnSort(e,n,this.table(),this.sortStates);let i=this.sortStates().get(e);if(!i||i==="none"){this.sortStates.set(new Map),this.sortChange.emit([]);return}this.sortStates.set(new Map([[e,i]]));let l=this.columns.find(p=>p.field===e);if(!l){this.sortChange.emit([]);return}this.sortChange.emit([{selector:l.sortField||e,desc:i==="desc"}])}getPartyClass(e){switch(e){case"DEM":return"p-tag-outlined-blue";case"REP":return"p-tag-outlined-red";case"IND":return"p-tag-outlined-muted"}}getDelayClass(e){return e>21?"delay--danger":e>=15?"delay--warning":""}getTypeClass(e){return e==="Buy"?"p-muted-green":"red-muted"}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-trades-table"]],viewQuery:function(n,i){n&1&&(ge(i.table,Ma,5),ge(i.politicianAutocomplete,Oa,5),ge(i.tickerAutocomplete,La,5)),n&2&&be(3)},inputs:{trades:[1,"trades"],isLoading:[1,"isLoading"],startDate:[1,"startDate"],endDate:[1,"endDate"],maxDate:[1,"maxDate"],tickerSuggestions:[1,"tickerSuggestions"],politicianSuggestions:[1,"politicianSuggestions"],isTickerSearching:[1,"isTickerSearching"],isPoliticianSearching:[1,"isPoliticianSearching"],politicianFilterValue:[1,"politicianFilterValue"],totalCount:[1,"totalCount"],limit:[1,"limit"],offset:[1,"offset"]},outputs:{dateRangeChange:"dateRangeChange",filtersCleared:"filtersCleared",paginationChange:"paginationChange",tickerSearch:"tickerSearch",politicianSearch:"politicianSearch",tickerSelect:"tickerSelect",politicianSelect:"politicianSelect",clearTickerSuggestions:"clearTickerSuggestions",clearPoliticianSuggestions:"clearPoliticianSuggestions",sortChange:"sortChange"},decls:20,vars:29,consts:[["politicianAutocomplete",""],["tickerAutocomplete",""],["table",""],[1,"h-full","body-h-full"],[1,"card-with-sub-cards","flex-1"],[1,"card-title"],[1,"trades-filters"],[1,"trades-filters__search",3,"valueChange","clearRequested","suggestionSelect","placeholder","value","suggestions","isSearching","clearOnSelect"],[1,"trades-filters__search",3,"valueChange","clearRequested","suggestionSelect","placeholder","suggestions","isSearching"],[3,"cleared"],[1,"trades-filters__dates",3,"dateRangeChange","startDate","endDate","maxDate","advancedPresets"],["sortMode","multiple",1,"trades-table","h-full","h-content-full",3,"onPage","alwaysShowPaginator","first","lazy","loading","paginator","rows","scrollable","showCurrentPageReport","totalRecords","value"],["pTemplate","header"],["pTemplate","body"],["pTemplate","emptymessage"],["pTemplate","paginatorright"],[3,"ngStyle"],[3,"columnSort","col","sortStates"],[1,"table-row"],[3,"ngClass","width"],[1,"trades-table__politician"],[3,"value"],[1,"secondary-text"],[1,"trades-table__ticker",3,"click","routerLink"],[2,"height","12rem"],[1,"text-center"],["appTableStickyEmpty","",1,"table-empty-message"],[1,"text-4xl"],[3,"rowsChange","currentRows","state","useLocalPagination"]],template:function(n,i){if(n&1){let l=E();o(0,"p-card",3)(1,"div",4)(2,"h3",5),m(3),C(4,"translate"),r(),o(5,"div",6)(6,"app-politician-autocomplete",7,0),C(8,"translate"),S("valueChange",function(g){return u(l),h(i.onPoliticianValueChange(g))})("clearRequested",function(){return u(l),h(i.onPoliticianClear())})("suggestionSelect",function(g){return u(l),h(i.onPoliticianSelect(g))}),r(),o(9,"app-ticker-autocomplete",8,1),C(11,"translate"),S("valueChange",function(g){return u(l),h(i.onTickerValueChange(g))})("clearRequested",function(){return u(l),h(i.onTickerClear())})("suggestionSelect",function(g){return u(l),h(i.onTickerSelect(g))}),r(),o(12,"app-clear-filter-button",9),S("cleared",function(){return u(l),h(i.onClearFilters())}
6),r(),o(13,"app-date-range-filter",10),S("dateRangeChange",function(g){return u(l),h(i.onDateRangeChange(g))}),r()(),o(14,"p-table",11,2),S("onPage",function(g){return u(l),h(i.pageChange(g))}),A(16,Da,3,0,"ng-template",12)(17,Fa,2,1,"ng-template",13)(18,Ba,7,4,"ng-template",14)(19,Ga,1,3,"ng-template",15),r()()()}n&2&&(a(3),f(y(4,23,"CONGRESSIONAL.TRANSACTIONS")),a(3),c("placeholder",y(8,25,"CONGRESSIONAL.POLITICIAN_NAME"))("value",i.politicianFilterValue())("suggestions",i.politicianSuggestions())("isSearching",i.isPoliticianSearching())("clearOnSelect",!1),a(3),c("placeholder",y(11,27,"CONGRESSIONAL.TICKER"))("suggestions",i.tickerSuggestions())("isSearching",i.isTickerSearching()),a(4),c("startDate",i.startDate())("endDate",i.endDate())("maxDate",i.maxDate())("advancedPresets",!0),a(),c("alwaysShowPaginator",!0)("first",i.offset())("lazy",!0)("loading",i.isLoading())("paginator",!0)("rows",i.limit())("scrollable",!0)("showCurrentPageReport",!1)("totalRecords",i.totalCount())("value",i.tableData()))},dependencies:[ft,ue,Te,Oe,Me,ke,B,D,U,G,Ce,he,Le,De,Ae,Dt,Mt,pe,Re,we,Ee,qe,M],styles:["[_nghost-%COMP%]{display:block}.trades-filters[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--spacing-2);flex-wrap:wrap}.trades-filters__search[_ngcontent-%COMP%]{min-width:11rem;flex:1 1 10rem;max-width:14rem}.trades-filters__politician-name[_ngcontent-%COMP%]{flex:1;font-size:var(--text-sm);color:var(--main-text-color);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.trades-filters__ticker-symbol[_ngcontent-%COMP%]{font-weight:var(--font-semibold);font-size:var(--text-sm);color:var(--main-text-color)}.trades-filters__ticker-name[_ngcontent-%COMP%]{color:var(--secondary-text-color);font-size:var(--text-xs);flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.trades-filters__dates[_ngcontent-%COMP%]{flex-shrink:0;margin-left:auto}.trades-filters__date-input[_ngcontent-%COMP%]{flex:1 1 0;min-width:0}.trades-table__politician[_ngcontent-%COMP%]{font-size:var(--text-sm);font-weight:var(--font-bold);color:var(--text-secondary);white-space:nowrap}.trades-table__ticker[_ngcontent-%COMP%]{font-size:var(--text-xs);font-weight:var(--font-semibold);color:var(--basic-primary-focus, var(--basic-primary));white-space:nowrap;text-decoration:none;transition:var(--transition-base)}.trades-table__ticker[_ngcontent-%COMP%]:hover{text-decoration:underline}.delay--warning[_ngcontent-%COMP%]{color:var(--additional-warning);font-weight:var(--font-semibold)}.delay--danger[_ngcontent-%COMP%]{color:var(--additional-danger);font-weight:var(--font-semibold)}"]})}return t})();var $a=()=>({hasZoom:!1});function Ha(t,s){if(t&1&&(o(0,"span",5),m(1),r()),t&2){let e=d();a(),f(e.windowLabel())}}function za(t,s){t&1&&_(0,"app-chevron-left-icon")}function Wa(t,s){t&1&&_(0,"app-chevron-right-icon")}function Ua(t,s){t&1&&_(0,"p-skeleton",8)}function ja(t,s){if(t&1){let e=E();o(0,"app-bar-chart",10),S("chartClick",function(i){u(e);let l=d();return h(l.onBarClick(i))}),r()}if(t&2){let e=d();c("series",e.chartSeries())("xAxis",e.xAxisData())("options",oe(5,$a))("autoRoundCorners",!0)("customConfig",e.customConfig())}}var Di=(()=>{class t{data=v.required();isLoading=v(!1);windowStartDate=v.required();windowEndDate=v.required();canGoNext=v(!1);canGoPrev=v(!1);prev=F();next=F();barClick=F();mainStore=b(ce);translateService=b(re);getCssVar(e){return getComputedStyle(document.documentElement).getPropertyValue(e).trim()}windowLabel=T(()=>{let e=this.windowStartDate(),n=this.windowEndDate();if(!e||!n)return"";let i=l=>{let p=new Date(l);return isNaN(p.getTime())?l:p.toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})};return`${i(e)} \u2014 ${i(n)}`});xAxisData=T(()=>this.data().map(e=>e.date));chartSeries=T(()=>{this.mainStore.isDark();let e=this.getCssVar("--chart-activity-bar");return[{type:"bar",name:this.translateService.instant("CONGRESSIONAL.TRADES_SERIES"),color:e,data:this.data().map(n=>n.count),cursor:"pointer"}]});customConfig=T(()=>(this.mainStore.isDark(),{grid:{left:"40px",right:"16px",top:"16px",bottom:"24px",containLabel:!1},xAxis:{axisLabel:{fontSize:11,color:this.getCssVar("--chart-axis-label"),rotate:45,interval:"auto"}},yAxis:{axisLabel:{fontSize:11,color:this.getCssVar("--chart-axis-label"),formatter:e=>Number.isInteger(e)?String(e):""},minInterval:1},tooltip:{trigger:"axis",axisPointer:{type:"shadow"},formatter:e=>{let i=e[0];return i?`<strong>${i.axisValue}</strong><br/>
7            <div style="display:flex;align-items:center;gap:8px;margin-top:4px">
8              <span style="display:inline-block;width:10px;height:10px;border-radius:50%;background:${i.color}"></span>
9              <span>${this.translateService.instant("CONGRESSIONAL.TRADES_SERIES")}: <strong>${i.value}</strong></span>
10            </div>`:""}},dataZoom:[]}));onBarClick(e){let n=this.data()[e.dataIndex];n?.isoDate&&this.barClick.emit(n.isoDate)}onPrev(){this.prev.emit()}onNext(){this.next.emit()}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-trades-activity-chart"]],inputs:{data:[1,"data"],isLoading:[1,"isLoading"],windowStartDate:[1,"windowStartDate"],windowEndDate:[1,"windowEndDate"],canGoNext:[1,"canGoNext"],canGoPrev:[1,"canGoPrev"]},outputs:{prev:"prev",next:"next",barClick:"barClick"},decls:17,vars:11,consts:[["icon",""],[1,"card-with-sub-cards"],[1,"chart-header"],[1,"card-title"],[1,"chart-nav"],[1,"chart-nav__range"],[1,"chart-nav__buttons"],["size","small",3,"onClick","rounded","text","disabled"],["height","13.75rem"],["height","13.75rem",3,"series","xAxis","options","autoRoundCorners","customConfig"],["height","13.75rem",3,"chartClick","series","xAxis","options","autoRoundCorners","customConfig"]],template:function(n,i){if(n&1){let l=E();o(0,"p-card")(1,"div",1)(2,"div",2)(3,"h3",3),m(4),C(5,"translate"),r(),o(6,"div",4),w(7,Ha,2,1,"span",5),o(8,"div",6)(9,"p-button",7),S("onClick",function(){return u(l),h(i.onPrev())}),A(10,za,1,0,"ng-template",null,0,z),r(),o(12,"p-button",7),S("onClick",function(){return u(l),h(i.onNext())}),A(13,Wa,1,0,"ng-template",null,0,z),r()()()(),w(15,Ua,1,0,"p-skeleton",8)(16,ja,1,6,"app-bar-chart",9),r()()}n&2&&(a(4),f(y(5,9,"CONGRESSIONAL.ACTIVITY_TIMELINE_30_DAYS")),a(3),k(i.windowLabel()?7:-1),a(2),c("rounded",!0)("text",!0)("disabled",i.isLoading()||!i.canGoPrev()),a(3),c("rounded",!0)("text",!0)("disabled",i.isLoading()||!i.canGoNext()),a(3),k(i.isLoading()?15:16))},dependencies:[B,D,U,G,yt,St,Je,ii,Qe,M],styles:["[_nghost-%COMP%]{display:block}.chart-header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:var(--spacing-3);margin-bottom:var(--spacing-3)}@media(max-width:576px){.chart-header[_ngcontent-%COMP%]{flex-wrap:wrap}}.chart-nav[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--spacing-3);flex-shrink:0}.chart-nav__range[_ngcontent-%COMP%]{font-size:var(--text-sm);color:var(--text-secondary);white-space:nowrap}.chart-nav__buttons[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--spacing-1)}"]})}return t})();var qa=[[["","sectionControls",""]],"*"],Ya=["[sectionControls]","*"],Ii=(()=>{class t{label=v.required();static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-filtered-section"]],inputs:{label:[1,"label"]},ngContentSelectors:Ya,decls:9,vars:3,consts:[[1,"filtered-section"],[1,"filtered-section__header"],[1,"filtered-section__label"],[1,"filtered-section__controls"],[1,"filtered-section__body"]],template:function(n,i){n&1&&(Ue(qa),dt(0,"section",0)(1,"header",1)(2,"span",2),m(3),C(4,"translate"),mt(),dt(5,"div",3),He(6),mt()(),dt(7,"div",4),He(8,1),mt()()),n&2&&(a(3),f(y(4,1,i.label())))},dependencies:[M],styles:["[_nghost-%COMP%]{display:block;min-width:0}.filtered-section[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:var(--spacing-3);padding:var(--spacing-4);background:var(--bg-secondary);border:1px solid var(--border-light);border-radius:var(--border-radius-lg)}.filtered-section__header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:var(--spacing-3);flex-wrap:wrap}.filtered-section__label[_ngcontent-%COMP%]{font-size:var(--text-sm);color:var(--text-secondary)}.filtered-section__controls[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;align-items:center;gap:var(--spacing-2);margin-left:auto}.filtered-section__body[_ngcontent-%COMP%]{min-width:0}"]})}return t})();var Ka=["tradesTableRef"];function Qa(t,s){if(t&1&&(m(0),C(1,"translate")),t&2){let e=s.$implicit;f(y(1,1,e.label))}}function Ai(t,s){let e=new Date(t);return e.setUTCDate(e.getUTCDate()+s),e.toISOString().slice(0,10)}var Vi=(()=>{class t{store=b($);route=b(Kt);scrollService=b(et);tradesTableRef=_e("tradesTableRef",{read:ve});topCardsRangeOptions=[{label:"CONGRESSIONAL.RANGE_90D",value:"90d"},{label:"CONGRESSIONAL.RANGE_6M",value:"6m"},{label:"CONGRESSIONAL.RANGE_1Y",value:"1y"},{label:"CONGRESSIONAL.RANGE_5Y",value:"5y"}];topCardsRangeLabel=T(()=>{switch(this.store.tradesTab.rangePreset()){case"6m":return"CONGRESSIONAL.LAST_6_MONTHS";case"90d":return"CONGRESSIONAL.LAST_90_DAYS";case"1y":return"CONGRESSIONAL.LAST_12_MONTHS";case"5y":return"CONGRESSIONAL.LAST_5_YEARS"}});isChartLoading=T(()=>{let{isLoading:e,isLoadingMore:n}=this.store.tradesActivityChartTab();return e||n});windowStartDate=T(()=>{let e=this.store.tradesActivityChartTab.windowEndDate();return e?Ai(e,-30):""});canGoNext=T(()=>{let{windowEndDate:e,latestAvailableDate:n}=this.store.tradesActivityChartTab();return!e||!n?!1:e<n});canGoPrev=T(()=>{let{windowEndDate:e,earliestAvailableDate:n,hasMoreHistory:i}=this.store.tradesActivityChartTab();if(!e)return!1;let l=Ai(e,-30);return i||!!n&&l>n});tableMaxDate=T(()=>this.store.tradesActivityChartTab().latestAvailableDate||new Date().toISOString().slice(0,10));
10constructor(){let e=this.route.snapshot.queryParamMap.get("senatorId");if(!e)return;let n=this.route.snapshot.queryParamMap.get("senatorName");this.store.setTradesTableSenatorFilter(e,n),setTimeout(()=>{let i=this.tradesTableRef()?.nativeElement;i&&this.scrollService.scrollMainContentToElement(i)},300)}onTopCardsRangeChange(e){this.store.setTradesTopCardsRange(e)}onDateRangeChange(e){this.store.setTradesTableDateRange(e.startDate,e.endDate)}onBarClick(e){this.store.setTradesTableDateRange(e,e)}onClearTableFilters(){}onPaginationChange(e){this.store.setTradesTablePagination(e.limit,e.offset)}onPrev(){this.store.shiftActivityChartWindow("prev")}onNext(){this.store.shiftActivityChartWindow("next")}onTickerSearch(e){e.trim()?this.store.searchTickersAutocomplete(e.trim()):this.store.clearTickerAutocomplete()}onPoliticianSearch(e){if(e.trim()){let{startDate:n,endDate:i}=this.store.tradesTableTab().dateRange;this.store.searchPoliticiansAutocomplete({search_text:e.trim(),start_date:n,end_date:i,limit:10})}else this.store.clearPoliticianAutocomplete()}onTickerSelect(e){this.store.clearTickerAutocomplete(),this.store.setTradesTableTickerFilter(e.ticker)}onPoliticianSelect(e){this.store.clearPoliticianAutocomplete(),this.store.setTradesTableSenatorFilter(e.senator_id,`${e.first_name} ${e.last_name}`)}onClearPoliticianFilter(){this.store.clearPoliticianAutocomplete(),this.store.setTradesTableSenatorFilter(null,null)}onClearTickerFilter(){this.store.clearTickerAutocomplete(),this.store.setTradesTableTickerFilter(null)}onSortChange(e){this.store.setTradesTableSortBy(e)}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-congressional-trades-trades"]],viewQuery:function(n,i){n&1&&ge(i.tradesTableRef,Ka,5,ve),n&2&&be()},decls:12,vars:28,consts:[["item",""],["tradesTableRef",""],[3,"label"],["sectionControls","","optionLabel","label","optionValue","value",3,"ngModelChange","options","ngModel"],[1,"congressional-trades__top-cards"],[1,"congressional-trades__top-cards-column"],[3,"trades","isLoading"],[3,"items","isLoading"],[3,"data","isLoading"],[3,"prev","next","barClick","data","isLoading","windowStartDate","windowEndDate","canGoNext","canGoPrev"],[3,"dateRangeChange","filtersCleared","paginationChange","tickerSearch","politicianSearch","tickerSelect","politicianSelect","clearTickerSuggestions","clearPoliticianSuggestions","sortChange","trades","isLoading","totalCount","limit","offset","startDate","endDate","maxDate","tickerSuggestions","politicianSuggestions","isTickerSearching","isPoliticianSearching","politicianFilterValue"]],template:function(n,i){if(n&1){let l=E();o(0,"app-filtered-section",2)(1,"p-selectButton",3),S("ngModelChange",function(g){return u(l),h(i.onTopCardsRangeChange(g))}),A(2,Qa,2,3,"ng-template",null,0,z),r(),o(4,"div",4)(5,"div",5),_(6,"app-largest-trades-card",6)(7,"app-delay-distribution-card",7),r(),_(8,"app-trades-by-owner-card",8),r()(),o(9,"app-trades-activity-chart",9),S("prev",function(){return u(l),h(i.onPrev())})("next",function(){return u(l),h(i.onNext())})("barClick",function(g){return u(l),h(i.onBarClick(g))}),r(),o(10,"app-trades-table",10,1),S("dateRangeChange",function(g){return u(l),h(i.onDateRangeChange(g))})("filtersCleared",function(){return u(l),h(i.onClearTableFilters())})("paginationChange",function(g){return u(l),h(i.onPaginationChange(g))})("tickerSearch",function(g){return u(l),h(i.onTickerSearch(g))})("politicianSearch",function(g){return u(l),h(i.onPoliticianSearch(g))})("tickerSelect",function(g){return u(l),h(i.onTickerSelect(g))})("politicianSelect",function(g){return u(l),h(i.onPoliticianSelect(g))})("clearTickerSuggestions",function(){return u(l),h(i.onClearTickerFilter())})("clearPoliticianSuggestions",function(){return u(l),h(i.onClearPoliticianFilter())})("sortChange",function(g){return u(l),h(i.onSortChange(g))}),r()}n&2&&(c("label",i.topCardsRangeLabel()),a(),c("options",i.topCardsRangeOptions)("ngModel",i.store.tradesTab.rangePreset()),a(5),c("trades",i.store.largestTrades())("isLoading",i.store.isLargestTradesLoading()),a(),c("items",i.store.delayDistributionVm())("isLoading",i.store.isDelayDistributionLoading()),a(),c("data",i.store.tradesByOwnerPie())("isLoading",i.store.tradesTab.data.isLoading()),a(),c("data",i.store.tradesDailyActivityData())("isLoading",i.isChartLoading())("windowStartDate",i.windowStartDate())("windowEndDate",i.store.tradesActivityChartTab.windowEndDate())("c
10anGoNext",i.canGoNext())("canGoPrev",i.canGoPrev()),a(),c("trades",i.store.tradesTableRows())("isLoading",i.store.isTradesTableLoading())("totalCount",i.store.tradesTableTotalCount())("limit",i.store.tradesTableTab.limit())("offset",i.store.tradesTableTab.offset())("startDate",i.store.tradesTableTab.dateRange.startDate())("endDate",i.store.tradesTableTab.dateRange.endDate())("maxDate",i.tableMaxDate())("tickerSuggestions",i.store.tickerAutocomplete.data())("politicianSuggestions",i.store.politicianAutocomplete.data())("isTickerSearching",i.store.tickerAutocomplete.isLoading())("isPoliticianSearching",i.store.politicianAutocomplete.isLoading())("politicianFilterValue",i.store.tradesTableTab.senatorName()??""))},dependencies:[ee,X,J,ne,Ii,Oi,Li,Pi,Di,Ri,M],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;flex:1;gap:var(--spacing-4)}.congressional-trades__top-cards[_ngcontent-%COMP%]{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:var(--spacing-4);align-items:stretch}@media(max-width:768px){.congressional-trades__top-cards[_ngcontent-%COMP%]{grid-template-columns:1fr}}.congressional-trades__top-cards-column[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:var(--spacing-4);min-width:0}"]})}return t})();var Za=t=>({name:t}),Xa=t=>({ticker:t});function Ja(t,s){if(t&1){let e=E();o(0,"app-filter-chip",14),C(1,"translate"),S("removed",function(){u(e);let i=d(2);return h(i.onPoliticianClear())}),m(2),r()}if(t&2){let e=s;c("ariaLabel",q(1,3,"CONGRESSIONAL.REMOVE",Z(6,Za,e.first_name+" "+e.last_name))),a(2),je(" ",e.first_name," ",e.last_name," ")}}function eo(t,s){if(t&1){let e=E();o(0,"app-filter-chip",14),C(1,"translate"),S("removed",function(){u(e);let i=d(2);return h(i.onTickerClear())}),_(2,"app-asset-logo",15),m(3),r()}if(t&2){let e=s;c("ariaLabel",q(1,5,"CONGRESSIONAL.REMOVE_TICKER",Z(8,Xa,e.ticker))),a(2),c("src",e.logo??null)("name",e.ticker)("shortName",e.short_name),a(),j(" ",e.ticker," ")}}function to(t,s){if(t&1){let e=E();o(0,"div",2)(1,"div",11),w(2,Ja,3,8,"app-filter-chip",12),w(3,eo,4,10,"app-filter-chip",12),r(),o(4,"button",13),S("click",function(){u(e);let i=d();return h(i.onClearFilters())}),_(5,"app-refresh-icon"),m(6),C(7,"translate"),r()()}if(t&2){let e,n,i=d();a(2),k((e=i.store.tickersTab.selectedSenator())?2:-1,e),a(),k((n=i.store.tickersTab.selectedTicker())?3:-1,n),a(3),j(" ",y(7,3,"CONGRESSIONAL.CLEAR_ALL")," ")}}function io(t,s){if(t&1&&(m(0),C(1,"translate")),t&2){let e=s.$implicit;f(y(1,1,e.label))}}var Fi=(()=>{class t{store=b($);activeViewMode=T(()=>{let e=this.store.tickersTab().sortBy[0]?.selector;return e==="mid_point"?"volume":e==="trades_count"?"trades":e==="entities_count"?"politicians":null});viewModes=[{label:"SELECT.VOLUME",value:"volume",disabled:!1},{label:"SELECT.TRADES",value:"trades",disabled:!1},{label:"SELECT.POLITICIANS",value:"politicians",disabled:!1}];onViewModeChange(e){e&&this.store.setTickersSortMode(e)}onDateRangeChange(e){this.store.setDateRange(e.startDate,e.endDate)}onPoliticianSearch(e){if(e.trim()){let{startDate:n,endDate:i}=this.store.filters();this.store.searchPoliticiansAutocomplete({search_text:e.trim(),start_date:n,end_date:i,limit:10})}else this.store.clearPoliticianAutocomplete()}onPoliticianSelect(e){this.store.setTickersSenator(e),this.store.clearPoliticianAutocomplete()}onPoliticianClear(){this.store.clearTickersSenator(),this.store.clearPoliticianAutocomplete()}onTickerSearch(e){e.trim()?this.store.searchTickersAutocomplete(e.trim()):this.store.clearTickerAutocomplete()}onTickerSelect(e){this.store.setTickersTicker(e),this.store.clearTickerAutocomplete()}onTickerClear(){this.store.clearTickersTicker(),this.store.clearTickerAutocomplete()}onClearFilters(){this.store.clearTickersSenator(),this.store.clearTickersTicker(),this.store.clearPoliticianAutocomplete(),this.store.clearTickerAutocomplete()}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-tickers-filters-card"]],decls:16,vars:25,consts:[["item",""],[1,"ct-filters-card"],[1,"ct-filters-card__chips"],[1,"ct-filters-card__row"],[1,"ct-filters-card__left"],[1,"ct-filters-card__search",3,"valueChange","clearRequested","suggestionSelect","placeholder","suggestions","isSearching","disabled"],[3,"cleared"],[1,"ct-filters-card__right"],["o
10ptionLabel","label","optionValue","value","optionDisabled","disabled",1,"all-grey","text-base","ct-view-mode-btn",3,"ngModelChange","ngModel","options","allowEmpty"],["optionLabel","label","optionValue","value","optionDisabled","disabled",1,"ct-view-mode-dropdown",3,"ngModelChange","options","ngModel","showClear","placeholder"],[3,"dateRangeChange","startDate","endDate","advancedPresets"],[1,"filter-chips"],[3,"ariaLabel"],["type","button",1,"clear-all-btn",3,"click"],[3,"removed","ariaLabel"],[1,"ct-filters-card__chip-logo",3,"src","name","shortName"]],template:function(n,i){if(n&1){let l=E();o(0,"div",1),w(1,to,8,5,"div",2),o(2,"div",3)(3,"div",4)(4,"app-politician-autocomplete",5),C(5,"translate"),S("valueChange",function(g){return u(l),h(i.onPoliticianSearch(g))})("clearRequested",function(){return u(l),h(i.onPoliticianClear())})("suggestionSelect",function(g){return u(l),h(i.onPoliticianSelect(g))}),r(),o(6,"app-ticker-autocomplete",5),C(7,"translate"),S("valueChange",function(g){return u(l),h(i.onTickerSearch(g))})("clearRequested",function(){return u(l),h(i.onTickerClear())})("suggestionSelect",function(g){return u(l),h(i.onTickerSelect(g))}),r(),o(8,"app-clear-filter-button",6),S("cleared",function(){return u(l),h(i.onClearFilters())}),r()(),o(9,"div",7)(10,"p-selectButton",8),S("ngModelChange",function(g){return u(l),h(i.onViewModeChange(g))}),A(11,io,2,3,"ng-template",null,0,z),r(),o(13,"p-select",9),C(14,"translate"),S("ngModelChange",function(g){return u(l),h(i.onViewModeChange(g))}),r(),o(15,"app-date-range-filter",10),S("dateRangeChange",function(g){return u(l),h(i.onDateRangeChange(g))}),r()()()()}n&2&&(a(),k(i.store.tickersTab.selectedSenator()||i.store.tickersTab.selectedTicker()?1:-1),a(3),c("placeholder",y(5,19,"CONGRESSIONAL.POLITICIAN_NAME"))("suggestions",i.store.politicianAutocomplete.data())("isSearching",i.store.politicianAutocomplete.isLoading())("disabled",i.store.tickersTab.selectedSenator()!==null),a(2),c("placeholder",y(7,21,"CONGRESSIONAL.TICKER"))("suggestions",i.store.tickerAutocomplete.data())("isSearching",i.store.tickerAutocomplete.isLoading())("disabled",i.store.tickersTab.selectedTicker()!==null),a(4),c("ngModel",i.activeViewMode())("options",i.viewModes)("allowEmpty",!0),a(3),c("options",i.viewModes)("ngModel",i.activeViewMode())("showClear",!1)("placeholder",y(14,23,"CONGRESSIONAL.SORT")),a(2),c("startDate",i.store.filters.startDate())("endDate",i.store.filters.endDate())("advancedPresets",!0))},dependencies:[ee,X,J,ne,Jt,pe,Re,Mt,Dt,Xe,xt,Ne,M],styles:["[_nghost-%COMP%]{display:block}.ct-filters-card[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:var(--spacing-3)}.ct-filters-card__chips[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:var(--spacing-3)}.ct-filters-card__chip-logo[_ngcontent-%COMP%]{width:1.25rem;height:1.25rem}.ct-filters-card__row[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--spacing-4);flex-wrap:wrap}.ct-filters-card__left[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--spacing-3);flex:1 0 min(26rem,100%);flex-wrap:wrap}@media(max-width:490px){.ct-filters-card__left[_ngcontent-%COMP%]{flex-direction:column;align-items:stretch}}.ct-filters-card__search[_ngcontent-%COMP%]{flex:1;min-width:11rem;max-width:37rem}.ct-filters-card__right[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--spacing-4);flex-shrink:1;flex-wrap:wrap}.ct-view-mode-dropdown[_ngcontent-%COMP%]{display:none}@media(max-width:560px){.ct-view-mode-dropdown[_ngcontent-%COMP%]{display:flex;flex:1}}@media(max-width:560px){.ct-view-mode-btn[_ngcontent-%COMP%]{display:none}}"]})}return t})();var no=["table"],Bi=(t,s,e)=>({"mr-auto":t,"mx-auto":s,"ml-auto":e}),ao=t=>["/user/asset",t,"summary"],It=(t,s)=>s.field;function oo(t,s){if(t&1){let e=E();o(0,"th",10)(1,"app-table-header-cell-content",11),S("columnSort",function(i){u(e);let l=d(2);return h(l.onColumnSort(i.field,i.event))}),r()()}if(t&2){let e=s.$implicit,n=d(2);c("ngStyle",e.headStyle),a(),c("col",e)("sortStates",n.sortStates)}}function ro(t,s){if(t&1&&(o(0,"tr"),_(1,"th",9),O(2,oo,2,3,"th",10,It),r()),t&2){let e=d();a(2),L(e.columns)}}function lo(t,s){t&1&&(o(0,"div",15),_(1,"p-skeleton",17)(2,"p-skeleton",18),r())}function so(t,s){if(t&1&&_(0,"p-skeleton",16),t&2){let e=d(),n=e.$implicit,i=e.$index;c("ngClass",Se(2,Bi,n.align==="left"||!n.align,n.align==="center",n.align==="right"))("width",i%2===0?"40%":"60%")}}function co(t,s){if(t&1&&(o(0,"td",10),w(1,lo,3,0,"div",15)(2,so,1,6,"p-skeleton",16),r()),t&2){let e=s.$implicit,n=s.$index;c("ngStyle",e.cellStyle),a(),k(n===0?1:2)}}function po(t,s){if(t&1&&(o(0,"tr")(1,"td",12)(2,"button",13),_(3,"app-chevron-right-icon",14),r()(),O(4,co,3,2,"td",10,It),r()),t&2){let e=d(2);a(4),L(e.columns)}}function mo(t,s){t&1&&_(0,"app-chevron-down-icon",21)}function go(t,s){t&1&&_(0,"app-chevron-right-icon",21)}function _o(t,s){if(t&1&&(o(0,"span"),m(1),r()),t&2){let e=d(2).$implicit;a(),f(e.assetName)}
10}function uo(t,s){t&1&&(o(0,"span",25),m(1,"\u2014"),r())}function ho(t,s){if(t&1&&(o(0,"th",10)(1,"span"),m(2),r()()),t&2){let e=s.$implicit;ie("text-align",e.align||"left"),c("ngStyle",e.headStyle),a(2),f(e.header)}}function Co(t,s){if(t&1&&(o(0,"tr"),O(1,ho,3,4,"th",30,It),r()),t&2){let e=d(4);a(),L(e.subColumns)}}function fo(t,s){if(t&1&&(o(0,"td",10),_(1,"p-skeleton",16),r()),t&2){let e=s.$implicit,n=s.$index;c("ngStyle",e.cellStyle),a(),c("ngClass",Se(3,Bi,e.align==="left"||!e.align,e.align==="center",e.align==="right"))("width",n%2===0?"50%":"70%")}}function vo(t,s){if(t&1&&(o(0,"tr"),O(1,fo,2,7,"td",10,It),r()),t&2){let e=d(5);a(),L(e.subColumns)}}function So(t,s){if(t&1&&(o(0,"tr")(1,"td",10)(2,"span"),m(3),r()(),o(4,"td",10),_(5,"p-tag",26),r(),o(6,"td",10)(7,"span",25),m(8),r()(),o(9,"td",10)(10,"span"),m(11),r()(),o(12,"td",10)(13,"span"),m(14),r()(),o(15,"td",10),_(16,"p-tag",26),r()()),t&2){let e=d().$implicit,n=d(4);a(),c("ngStyle",n.subColumns[0].cellStyle),a(2),f(e.politician),a(),c("ngStyle",n.subColumns[1].cellStyle),a(),ae(n.getPartyClass(e.party)),c("value",e.party),a(),c("ngStyle",n.subColumns[2].cellStyle),a(2),f(e.chamber),a(),c("ngStyle",n.subColumns[3].cellStyle),a(2),f(e.owner),a(),c("ngStyle",n.subColumns[4].cellStyle),a(2),f(e.amount),a(),c("ngStyle",n.subColumns[5].cellStyle),a(),ae(n.getTradeTypeClass(e.type)),c("value",e.type)}}function yo(t,s){if(t&1&&w(0,vo,3,0,"tr")(1,So,17,16,"tr"),t&2){d();let e=ht(0);k(!e||e.isLoading?0:1)}}function bo(t,s){if(t&1&&(o(0,"tr",31)(1,"td")(2,"div",32),_(3,"app-search-icon",33),o(4,"span",25),m(5),C(6,"translate"),r()()()()),t&2){let e=d(4);a(),K("colspan",e.subColumns.length),a(4),f(y(6,2,"CONGRESSIONAL.NO_TRANSACTIONS_FOUND"))}}function To(t,s){if(t&1&&(_t(0),o(1,"tr",27)(2,"td")(3,"div",28)(4,"p-table",29),A(5,Co,3,0,"ng-template",5)(6,yo,2,1,"ng-template",6)(7,bo,7,4,"ng-template",7),r()()()()),t&2){let e=d(2).$implicit,n=d(),i=ut(n.transactionsByTicker()[e.ticker]);a(2),K("colspan",n.columns.length+1),a(2),c("scrollable",!0)("value",n.getSubTableRows(i))}}function xo(t,s){if(t&1){let e=E();o(0,"tr",19),S("click",function(){u(e);let i=d().$implicit,l=d();return h(l.toggleExpand(i.ticker))}),o(1,"td",12)(2,"button",20),w(3,mo,1,0,"app-chevron-down-icon",21)(4,go,1,0,"app-chevron-right-icon",21),r()(),o(5,"td",22),S("click",function(i){return u(e),h(i.stopPropagation())}),o(6,"div",15),_(7,"app-asset-logo",23),o(8,"a",24),m(9),r()()(),o(10,"td",10),w(11,_o,2,1,"span")(12,uo,2,0,"span",25),r(),o(13,"td",10),_(14,"p-tag",26),r(),o(15,"td",10)(16,"span"),m(17),r()(),o(18,"td",10)(19,"span"),m(20),r()(),o(21,"td",10)(22,"span"),m(23),r()(),o(24,"td",10)(25,"span"),m(26),C(27,"date"),r()()(),w(28,To,8,4,"tr",27)}if(t&2){let e=d().$implicit,n=d();a(3),k(n.isExpanded(e.ticker)?3:4),a(2),c("ngStyle",n.columns[0].cellStyle),a(2),c("src",e.logo)("name",e.ticker)("shortName",e.assetName),a(),c("routerLink",Z(25,ao,e.ticker)),a(),f(e.ticker),a(),c("ngStyle",n.columns[1].cellStyle),a(),k(e.assetName?11:12),a(2),c("ngStyle",n.columns[2].cellStyle),a(),ae(n.getTypeClass(e.type)),c("value",e.type),a(),c("ngStyle",n.columns[3].cellStyle),a(2),f(e.trades),a(),c("ngStyle",n.columns[4].cellStyle),a(2),f(e.politicians),a(),c("ngStyle",n.columns[5].cellStyle),a(2),f(e.volume),a(),c("ngStyle",n.columns[6].cellStyle),a(2),f(q(27,22,e.lastTrade,"MMM d, y")),a(2),k(n.isExpanded(e.ticker)?28:-1)}}function wo(t,s){if(t&1&&w(0,po,6,0,"tr")(1,xo,29,27),t&2){let e=d();k(e.isLoading()?0:1)}}function ko(t,s){if(t&1&&(o(0,"tr",34)(1,"td",35)(2,"div",32),_(3,"app-search-icon",36),o(4,"span",25),m(5),C(6,"translate"),r()()()()),t&2){let e=d();a(),K("colspan",e.columns.length+1),a(4),f(y(6,2,"CONGRESSIONAL.NO_TICKERS_FOUND"))}}function Eo(t,s){if(t&1){let e=E();o(0,"app-table-paginator",37),S("rowsChange",function(i){u(e);let l=d();return h(l.onRowsChange(i))}),r()}if(t&2){let e=s.$implicit;c("currentRows",e.rows)("state",e)("useLocalPagination",!1)}}var Gi=(()=>{class t{table=_e("table");tickers=v.required();isLoading=v(!1);transactionsByTicker=v({});totalCount=v(0);limit=v(10);offset=v(0);sortBy=v([]);tickerExpand=F();paginationChange=F();sortChange=F();expandedTickers=H(new Set);tableData=T(()=>this.isLoading()&&this.tickers().length===0?Array(this.limit()).fill({}):this.tickers());columns=[{field:"ticker",header:"CONGRESSIONAL.TICKER",sortable:!0,sortField:"ticker",align:"left",headStyle:{"min-width":"8rem"},cellStyle:{"text-align":"left"},defaultVisible:!0,type:"custom"},{field:"assetName",header:"CONGRESSIONAL.ASSET_NAME",sortable:!0,sortField:"name",align:"left",headStyle:{"min-width":"10rem"},cellStyle:{"text-align":"left"},defaultVisible:!0,type:"text"},{field:"type",header:"CONGRESSIONAL.TYPE",sortable:!0,sortField:"quote_type",align:"center",headStyle:{"min-width":"6rem"},cellStyle:{"text-align":"center"},defaultVisible:!0,type:"custom"},{field:"trades",header:"CONGRESSIONAL.RECORDS",sortable:!0,sortField:"trades_count",align:"right",headStyle:{"min-width":"5rem"},cellStyle:{"text-align":"right"},defaultVisible:!0,type:"number"},{field:"politicians",header:"CONGRESSIONAL.POLITICIANS",sortable:!0,sortField:"entities_count",align:"right",headStyle:{"min-width":"6.5rem"},cellStyle:{"text-align":"right"},defaultVisible:!0,type:"number"},{field:"volume",header:"CONGRESSIONAL.VOLUME",sortable:!0,sortField:"mid_point",align:"right",headStyle:{"min-width":"6rem"},cellStyle:{"text-align":"right"},defaultVisible:!0,type:"text"},{field:"lastTrade",header:"CONGRESSIONAL.LATEST_RECORD",sortable:!0,sortField:"transaction_date",align:"right",headStyle:{"min-width":"7rem"},cellStyle:{"text-align":"right"},defaultVisible:!0,type:"date"}];subColumns=[{field:"politician",header:"CONGRESSIONAL.POLITICIAN",sortable:!1,align:"left",headStyle:{"min-width":"10rem"},cellStyle:{"text-align":"left"},defaultVisible:!0,type:"text"},{field:"party",header:"CONGRESSIONAL.PARTY",sortable:!1,align:"center",headStyle:{"min-width":"5rem"},cellStyle:{"text-align":"center"},defaultVisible:!0,type:"custom"},{field:"chamber",header:"CONGRESSIONAL.CHAMBER",sortable:!1,align:"center",headStyle:{"min-width":"6rem"},cellStyle:{"text-align":"center"},defaultVisible:!0,type:"text"},{field:"owner",header:"CONGRESSIONAL.OWNER",sortable:!1,align:"center",headStyle:{"min-width":"5.5rem"},cellStyle:{"text-align":"center"},defaultVisible:!0,type:"text"},{field:"amount",header:"CONGRESSIONAL.AMOUNT",sortable:!1,align:"right",headStyle:{"min-width":"7rem"},cellStyle:{"text-align":"right"},defaultVisible:!0,type:"text"},{field:"type",header:"CONGRESSIONAL.TYPE",sortable:!1,align:"center",headStyle:{"min-width":"4.5rem"},cellStyle:{"text-align":"center"},defaultVisible:!0,type:"custom"}];tableSortService=b(Ie);router=b(xe);sortStates=this.tableSortService.createSortStates();constructor(){de(()=>{this.tickers(),Vt(()=>this.expandedTickers.set(new Set))}),de(()=>{let e=this.sortBy(),n=new Map;for(let i of e){let l=this.columns.find(p=>(p.sortField??p.field)===i.selector);l&&n.set(l.field,i.desc?"desc":"asc")}Vt(()=>this.sortStates.set(n))})}toggleExpand(e){let n=new Set(this.expandedTickers());n.has(e)?n.delete(e):(n.add(e),this.tickerExpand.emit(e)),this.expandedTickers.set(n)}isExpanded(e){return this.expandedTickers().has(e)}navigateToTicker(e){this.router.navigate(["/user/asset",e,"summary"])}onRowsChange(e){this.paginationChange.emit({limit:e,offset:0})}pageChange(e){let n=e.first??0,i=e.rows??this.limit();this.paginationChange.emit({limit:i,offset:n})}onColumnSort(e,n){this.tableSortService.onColumnSort(e,n,this.table(),this.sortStates);let i=this.sortStates().get(e);if(!i||i==="none"){this.sortStates.set(new Map),this.sortChange.emit([]);return}this.sortStates.set(new Map([[e,i]]));let l=this.columns.find(p=>p.field===e);if(!l){this.sortChange.emit([]);return}this.sortChange.emit([{selector:l.sortField||e,desc:i==="desc"}])}getTypeClass(e){switch(e){case"Stock":return"violet";case"ETF":return"additional-light";case"Bond":return"basic-primary";case"Option":return"red-muted"}}getPartyClass(e){switch(e){case"DEM":return"p-tag-outlined-blue";case"REP":return"p-tag-outlined-red";case"IND":return"p-tag-outlined-muted"}}getTradeTypeClass(e){return e==="Buy"?"p-muted-green":"red-muted"}getSubTableRows(e){return!e||e.isLoading?Array(5).fill({}):e.rows}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-tickers-table"]],viewQuery:function(n,i){n&1&&ge(i.table,no,5),n&2&&be()},inputs:{tickers:[1,"tickers"],isLoading:[1,"isLoading"],transactionsByTicker:[1,"transactionsByTicker"],totalCount:[1,"totalCount"],limit:[1,"limit"],offset:[1,"offset"],sortBy:[1,"sortBy"]},outputs:{tickerExpand:"tickerExpand",paginationChange:"paginationChange",sortChange:"sortChange"}
10,decls:12,vars:12,consts:[["table",""],[1,"h-full","body-h-full"],[1,"card-with-sub-cards","flex-1"],[1,"card-title"],["sortMode","multiple",1,"tickers-table","h-full","h-content-full","clickable-rows",3,"onPage","alwaysShowPaginator","first","lazy","paginator","rows","scrollable","showCurrentPageReport","totalRecords","value"],["pTemplate","header"],["pTemplate","body"],["pTemplate","emptymessage"],["pTemplate","paginatorright"],[2,"width","2.5rem","min-width","2.5rem"],[3,"ngStyle"],[3,"columnSort","col","sortStates"],[2,"width","2.5rem","text-align","center"],["type","button","disabled","",1,"table-action-btn"],[1,"text-xs",2,"visibility","hidden"],[1,"tickers-table__ticker-cell"],[3,"ngClass","width"],["shape","circle","size","1.5rem"],["width","40%"],[1,"table-row",3,"click"],["type","button",1,"table-action-btn"],[1,"text-xs"],[3,"click","ngStyle"],[1,"tickers-table__logo",3,"src","name","shortName"],[1,"tickers-table__ticker",3,"routerLink"],[1,"secondary-text"],[3,"value"],[1,"tickers-table__subrow"],[1,"tickers-table__subtable-wrapper"],[1,"tickers-table__subtable",3,"scrollable","value"],[3,"ngStyle","text-align"],[2,"height","6rem"],["appTableStickyEmpty","",1,"table-empty-message"],[1,"text-2xl","text-gray-400"],[2,"height","12rem"],[1,"text-center"],[1,"text-4xl"],[3,"rowsChange","currentRows","state","useLocalPagination"]],template:function(n,i){if(n&1){let l=E();o(0,"p-card",1)(1,"div",2)(2,"h3",3),m(3),C(4,"translate"),r(),_(5,"app-tickers-filters-card"),o(6,"p-table",4,0),S("onPage",function(g){return u(l),h(i.pageChange(g))}),A(8,ro,4,0,"ng-template",5)(9,wo,2,1,"ng-template",6)(10,ko,7,4,"ng-template",7)(11,Eo,1,3,"ng-template",8),r()()()}n&2&&(a(3),f(y(4,10,"CONGRESSIONAL.AGGREGATED_TICKERS")),a(3),c("alwaysShowPaginator",!0)("first",i.offset())("lazy",!0)("paginator",!0)("rows",i.limit())("scrollable",!0)("showCurrentPageReport",!1)("totalRecords",i.totalCount())("value",i.tableData()))},dependencies:[ue,Te,we,Oe,Me,ke,B,D,U,G,Ce,he,Le,De,Ae,Fi,xt,Qe,Tt,Ee,qe,M],styles:["[_nghost-%COMP%]{display:block}.tickers-table__ticker-cell[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--spacing-2)}.tickers-table__logo[_ngcontent-%COMP%]{width:1.5rem;height:1.5rem}.tickers-table__ticker[_ngcontent-%COMP%]{font-size:var(--text-xs);font-weight:var(--font-semibold);color:var(--basic-primary-focus, var(--basic-primary));white-space:nowrap;text-decoration:none}.tickers-table__ticker[_ngcontent-%COMP%]:hover{text-decoration:underline}.tickers-table__subrow[_ngcontent-%COMP%] > td[_ngcontent-%COMP%]{padding:0!important;background-color:var(--surface-ground, var(--bg-secondary))}.tickers-table__subtable-wrapper[_ngcontent-%COMP%]{padding:var(--spacing-3) var(--spacing-4) var(--spacing-3) var(--spacing-8);border-top:1px solid var(--border-light);border-bottom:1px solid var(--border-light)}.tickers-table__subtable[_ngcontent-%COMP%]{border-radius:var(--border-radius-md);overflow:hidden}"]})}return t})();var $i=(()=>{class t{store=b($);onTreemapTransferChange(e){this.store.setTickerTreemapTransferType(e)}onTreemapChamberChange(e){this.store.setTickerTreemapChamber(e)}onTickerExpand(e){this.store.loadTickerTransactions(e)}onPaginationChange(e){this.store.setTickersPagination(e.limit,e.offset)}onSortChange(e){this.store.setTickersSortBy(e)}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-congressional-trades-tickers"]],decls:3,vars:12,consts:[[1,"tickers-layout"],[3,"transferTypeChange","chamberChange","items","isLoading","showFlowControls","transferType","chamber"],[3,"tickerExpand","paginationChange","sortChange","tickers","isLoading","transactionsByTicker","totalCount","limit","offset","sortBy"]],template:function(n,i){n&1&&(o(0,"div",0)(1,"app-volume-by-ticker-sector-card",1),S("transferTypeChange",function(p){return i.onTreemapTransferChange(p)})("chamberChange",function(p){return i.onTreemapChamberChange(p)}),r(),o(2,"app-tickers-table",2),S("tickerExpand",function(p){return i.onTickerExpand(p)})("paginationChange",function(p){return i.onPaginationChange(p)})("sortChange",function(p){return i.onSortChange(p)}),r()()),n&2&&(a(),c("items",i.store.tickerTreemapHeatmapData())("isLoading",i.store.tickerTreemapLoading())("showFlowControls",!0)("transferType",i.store.tickerTreemapTransferType())("chamber",i.store.tickerTreemapChamber()),a(),c("tickers",i.store.tickersRows())("isLoading",i.store.tickersTab.isLoading())("transactionsByTicker",i.store.tickerTransactionsVmMap())("totalCount",i.store.tickersTotalCount())("limit",i.store.tickersTab.limit())("offset",i.store.tickersTab.offset())("sortBy",i.store.tickersTab.sortBy()))},dependencies:[it,Gi],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column}.tickers-layout[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:var(--spacing-4)}"]})}return t})();var Mo=()=>({hasZoom:!1,smooth:!0,showSymbol:!1}),lt={houseDem:"CONGRESSIONAL.HOUSE_DEM",houseRep:"CONGRESSIONAL.HOUSE_REP",senateDem:"CONGRESSIONAL.SENATE_DEM",senateRep:"CONGRESSIONAL.SENATE_REP"},Hi=(()=>{class t{data=v.required();isLoading=v(!1);title=v("CONGRESSIONAL.ACTIVITY_OVER_TIME_VOLUME");valueMode=v("volume");mainStore=b(ce);translateService=b(re);getCssVar(e){return getComputedStyle(document.documentElement).getPropertyValue(e).trim()}groupColors=T(()=>(this.mainStore.isDark(),{houseDem:this.getCssVar("--additional"),houseRep:this.getCssVar("--additional-danger"),senateDem:this.getCssVar("--chart-senate-dem"),senateRep:this.getCssVar("--chart-senate-rep")}));xAxisData=T(()=>[]);chartSeries=T(()=>
10{let e=this.data(),n=this.groupColors(),i={focus:"series"};return[{type:"line",name:this.translateService.instant(lt.houseDem),smooth:!0,color:n.houseDem,emphasis:i,data:e.map(l=>[l.month,l.houseDem])},{type:"line",name:this.translateService.instant(lt.houseRep),smooth:!0,color:n.houseRep,emphasis:i,data:e.map(l=>[l.month,l.houseRep])},{type:"line",name:this.translateService.instant(lt.senateDem),smooth:!0,color:n.senateDem,emphasis:i,data:e.map(l=>[l.month,l.senateDem])},{type:"line",name:this.translateService.instant(lt.senateRep),smooth:!0,color:n.senateRep,emphasis:i,data:e.map(l=>[l.month,l.senateRep])}]});chartCustomConfig=T(()=>{let e=this.groupColors();return this.mainStore.isDark(),{legend:{type:"scroll",show:!0,top:0,left:"center",orient:"horizontal",icon:"circle",itemWidth:12,itemHeight:12,itemGap:20,pageIconSize:12,pageIconColor:this.getCssVar("--main-text-color"),pageIconInactiveColor:this.getCssVar("--border-light"),pageTextStyle:{color:this.getCssVar("--text-secondary"),fontSize:12},textStyle:{color:this.getCssVar("--main-text-color"),fontSize:14,fontWeight:400},data:["houseDem","houseRep","senateDem","senateRep"].map(n=>({name:this.translateService.instant(lt[n]),itemStyle:{color:e[n]}}))},xAxis:{axisLabel:{hideOverlap:!0,fontSize:12,color:this.getCssVar("--main-text-color")}},yAxis:{axisLabel:{fontSize:12,color:this.getCssVar("--main-text-color"),formatter:n=>n===0?"":this.valueMode()==="trades"?n>=1e3?`${(n/1e3).toFixed(0)}K`:`${Math.round(n)}`:`$${(n/1e6).toFixed(1)}M`}},grid:{left:"65px",right:"20px",top:"30px",bottom:"30px",containLabel:!1},tooltip:{trigger:"axis",formatter:n=>{let i=n,p=`<div style="margin-bottom:6px;font-weight:bold">${i[0]?.value?.[0]?new Date(i[0].value[0]).toLocaleDateString("en-US",{month:"long",year:"numeric"}):""}</div>`;for(let g of i){let N=g.value[1],R=this.valueMode()==="volume"?`$${(N/1e6).toFixed(1)}M`:N>=1e3?`${(N/1e3).toFixed(0)}K`:`${Math.round(N)}`;p+=`<div style="display:flex;align-items:center;gap:8px;margin-top:3px">
11              <span style="display:inline-block;width:10px;height:10px;border-radius:50%;background:${g.color}"></span>
12              <span>${g.seriesName}: <strong>${R}</strong></span>
13            </div>`}return p}},dataZoom:[]}});static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-politicians-activity-chart"]],inputs:{data:[1,"data"],isLoading:[1,"isLoading"],title:[1,"title"],valueMode:[1,"valueMode"]},decls:6,vars:7,consts:[[1,"activity-chart"],[1,"activity-chart__header"],[1,"card-title"],["height","220px",3,"series","xAxis","isLoading","options","customConfig"]],template:function(n,i){n&1&&(o(0,"p-card")(1,"div",0)(2,"div",1)(3,"h3",2),m(4),r()(),_(5,"app-line-chart",3),r()()),n&2&&(a(4),f(i.title()),a(),c("series",i.isLoading()?null:i.chartSeries())("xAxis",i.xAxisData())("isLoading",i.isLoading())("options",oe(6,Mo))("customConfig",i.chartCustomConfig()))},dependencies:[B,D,wt],styles:[".activity-chart[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:var(--spacing-4)}.activity-chart__header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between}"]})}return t})();var Oo=t=>({count:t}),Lo=(t,s,e)=>({"mr-auto":t,"mx-auto":s,"ml-auto":e}),Po=(t,s)=>({kind:"politician",senatorId:t,senatorName:s}),zi=(t,s)=>s.field;function No(t,s){if(t&1){let e=E();o(0,"th",8)(1,"app-table-header-cell-content",9),S("columnSort",function(i){u(e);let l=d(2);return h(l.onColumnSort(i.field,i.event))}),r()()}if(t&2){let e=s.$implicit,n=d(2);c("ngStyle",e.headStyle),a(),c("col",e)("sortStates",n.sortStates)}}function Ro(t,s){if(t&1&&(o(0,"tr"),O(1,No,2,3,"th",8,zi),r()),t&2){let e=d();a(),L(e.columns)}}function Do(t,s){if(t&1&&(o(0,"td",8),_(1,"p-skeleton",11),r()),t&2){let e=s.$implicit,n=s.$index;c("ngStyle",e.cellStyle),a(),c("ngClass",Se(3,Lo,e.align==="left"||!e.align,e.align==="center",e.align==="right"))("width",n%2===0?"40%":"60%")}}function Io(t,s){if(t&1&&(o(0,"tr"),O(1,Do,2,7,"td",8,zi),r()),t&2){let e=d(2);a(),L(e.columns)}}function Ao(t,s){if(t&1&&(o(0,"tr",10)(1,"td",8)(2,"span",12),m(3),r()(),o(4,"td",8),_(5,"p-tag",13),r(),o(6,"td",8)(7,"span"),m(8),r()(),o(9,"td",8)(10,"span"),m(11),r()(),o(12,"td",8)(13,"span"),m(14),r()(),o(15,"td",8)(16,"span"),m(17),r()(),o(18,"td",8)(19,"span"),m(20),r()(),o(21,"td",8)(22,"span"),m(23),C(24,"date"),r()(),o(25,"td",8),_(26,"app-alert-bell-button",14),r()()),t&2){let e=d().$implicit,n=d();a(),c("ngStyle",n.columns[0].cellStyle),a(2),f(e.name),a(),c("ngStyle",n.columns[1].cellStyle),a(),ae(n.getPartyClass(e.party)),c("value",e.party),a(),c("ngStyle",n.columns[2].cellStyle),a(2),f(e.chamber),a(),c("ngStyle",n.columns[3].cellStyle),a(2),f(e.state),a(),c("ngStyle",n.columns[4].cellStyle),a(2),f(e.trades),a(),c("ngStyle",n.columns[5].cellStyle),a(2),f(e.volume),a(),c("ngStyle",n.columns[6].cellStyle),a(2),f(e.tickers),a(),c("ngStyle",n.columns[7].cellStyle),a(2),f(q(24,21,e.lastTrade,"MMM d, y")),a(2),c("ngStyle",n.columns[8].cellStyle),a(),c("entity",jt(24,Po,e.id,e.name))("alertIds",e.alertIds)}}function Vo(t,s){if(t&1&&w(0,Io,3,0,"tr")(1,Ao,27,27,"tr",10),t&2){let e=d();k(e.isLoading()?0:1)}}function Fo(t,s){if(t&1&&(o(0,"tr",15)(1,"td")(2,"div",16),_(3,"app-search-icon",17),o(4,"span",18),m(5),C(6,"translate"),r()()()()),t&2){let e=d();a(),K("colspan",e.columns.length),a(4),f(y(6,2,"CONGRESSIONAL.NO_POLITICIANS_FOUND"))}}function Bo(t,s){if(t&1){let e=E();o(0,"app-table-paginator",19),S("rowsChange",function(i){u(e);let l=d();return h(l.onRowsChange(i))}),r()}if(t&2){let e=s.$implicit;c("currentRows",e.rows)("state",e)("useLocalPagination",!0)}}var Wi=(()=>{class t{politicians=v.required();isLoading=v(!1);currentRows=H(10);skeletonRows=Array(10).fill({});columns=[{field:"name",header:"CONGRESSIONAL.POLITICIAN",sortable:!0,align:"left",headStyle:{"min-width":"10rem"},cellStyle:{"text-align":"left"},defaultVisible:!0,type:"text"},{field:"party",header:"CONGRESSIONAL.PARTY",sortable:!0,align:"center",headStyle:{"min-width":"5rem"},cellStyle:{"text-align":"center"},defaultVisible:!0,type:"custom"},{field:"chamber",header:"CONGRESSIONAL.CHAMBER",sortable:!0,align:"center",headStyle:{"min-width":"6rem"},cellStyle:{"text-align":"center"},defaultVisible:!0,type:"text"},{field:"state",header:"CONGRESSIONAL.STATE",sortable:!0,align:"center",headStyle:{"min-width":"3.5rem"},cellStyle:{"text-align":"center"},defaultVisible:!0,type:"text"},{field:"trades",header:"CONGRESSIONAL.RECORDS",sortable:!0,align:"right",headStyle:{"min-width":"5rem"},cellStyle:{"text-align":"right"},defaultVisible:!0,type:"number"},{field:"volume",header:"CONGRESSIONAL.VOLUME",sortable:!0,align:"right",headStyle:{"min-width":"6rem"},cellStyle:{"text-align":"right"},defaultVisible:!0,type:"text",localSortField:"volumeValue"},{field:"tickers",header:"CONGRESSIONAL.TICKERS",sortable:!0,align:"right",headStyle:{"min-width":"5rem"},cellStyle:{"text-align":"right"},defaultVisible:!0,type:"number"},{field:"lastTrade",header:"CONGRESSIONAL.LATEST_RECORD",sortable:!0,align:"right",headStyle:{"min-width":"7rem"},cellStyle:{"text-align":"right"},defaultVisible:!0,type:"date"},{field:"actions",header:"CONGRESSIONAL.ACTIONS",sortable:!1,align:"center",headStyle:{"min-width":"5rem"},cellStyle:{"text-align":"center"},defaultVisible:!0,type:"actions",isSpecial:!0}];tableSortService=b(Ie);localSort=this.tableSortService.createLocalSort(this.politicians,this.columns);sortStates=this.localSort.sortStates;
13sortedRows=this.localSort.sortedRows;onRowsChange(e){this.currentRows.set(e)}onColumnSort(e,n){this.localSort.onColumnSort(e,n)}getPartyClass(e){switch(e){case"DEM":return"p-tag-outlined-blue";case"REP":return"p-tag-outlined-red";case"IND":return"p-tag-outlined-muted"}}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-politicians-table"]],inputs:{politicians:[1,"politicians"],isLoading:[1,"isLoading"]},decls:10,vars:17,consts:[[1,"h-full","body-h-full"],[1,"card-with-sub-cards","flex-1"],[3,"title","subtitle","isActionEnabled"],["sortMode","multiple",1,"politicians-table","h-full","h-content-full",3,"alwaysShowPaginator","paginator","rows","scrollable","showCurrentPageReport","totalRecords","value"],["pTemplate","header"],["pTemplate","body"],["pTemplate","emptymessage"],["pTemplate","paginatorright"],[3,"ngStyle"],[3,"columnSort","col","sortStates"],[1,"table-row"],[3,"ngClass","width"],[1,"politicians-table__name"],[3,"value"],[3,"entity","alertIds"],[2,"height","12rem"],["appTableStickyEmpty","",1,"table-empty-message"],[1,"text-4xl"],[1,"secondary-text"],[3,"rowsChange","currentRows","state","useLocalPagination"]],template:function(n,i){n&1&&(o(0,"p-card",0)(1,"div",1),_(2,"app-card-header",2),C(3,"translate"),C(4,"translate"),o(5,"p-table",3),A(6,Ro,3,0,"ng-template",4)(7,Vo,2,1,"ng-template",5)(8,Fo,7,4,"ng-template",6)(9,Bo,1,3,"ng-template",7),r()()()),n&2&&(a(2),c("title",y(3,10,"CONGRESSIONAL.POLITICIAN"))("subtitle",q(4,12,"CONGRESSIONAL.RESULTS",Z(15,Oo,i.politicians().length)))("isActionEnabled",!1),a(3),c("alwaysShowPaginator",!0)("paginator",!0)("rows",i.currentRows())("scrollable",!0)("showCurrentPageReport",!1)("totalRecords",i.isLoading()?0:i.politicians().length)("value",i.isLoading()?i.skeletonRows:i.sortedRows()))},dependencies:[ue,Te,Oe,Me,ke,B,D,U,G,Ce,he,ui,Le,De,Ae,Ke,Ee,qe,M],styles:["[_nghost-%COMP%]{display:block}.politicians-table__name[_ngcontent-%COMP%]{font-weight:var(--font-bold)}"]})}return t})();var Go=t=>({max:t}),$o=t=>({name:t}),Ho=(t,s)=>s.senator_id;function zo(t,s){if(t&1){let e=E();o(0,"app-filter-chip",12),C(1,"translate"),S("removed",function(){let i=u(e).$implicit,l=d(2);return h(l.onRemoveSenator(i.senator_id))}),m(2),r()}if(t&2){let e=s.$implicit;c("ariaLabel",q(1,3,"CONGRESSIONAL.REMOVE",Z(6,$o,e.first_name+" "+e.last_name))),a(2),je(" ",e.first_name," ",e.last_name," ")}}function Wo(t,s){if(t&1){let e=E();o(0,"div",3)(1,"div",9),O(2,zo,3,8,"app-filter-chip",10,Ho),r(),o(4,"button",11),S("click",function(){u(e);let i=d();return h(i.onClearAllSenators())}),_(5,"app-refresh-icon"),m(6),C(7,"translate"),r()()}if(t&2){let e=d();a(2),L(e.store.politiciansTab.selectedSenators()),a(4),j(" ",y(7,1,"CONGRESSIONAL.CLEAR_ALL")," ")}}function Uo(t,s){if(t&1&&(m(0),C(1,"translate")),t&2){let e=s.$implicit;f(y(1,1,e.label))}}var Ui=(()=>{class t{store=b($);maxFilters=tt;isLimitReached=T(()=>this.store.politiciansTab.selectedSenators().length>=tt);viewModes=[{label:"SELECT.VOLUME",value:"volume"},{label:"SELECT.TRADES",value:"trades"}];onViewModeChange(e){this.store.setPoliticiansSortMode(e)}onDateRangeChange(e){this.store.setDateRange(e.startDate,e.endDate)}onPoliticianSearch(e){if(e.trim()){let{startDate:n,endDate:i}=this.store.filters();this.store.searchPoliticiansAutocomplete({search_text:e.trim(),start_date:n,end_date:i,limit:10})}else this.store.clearPoliticianAutocomplete()}onPoliticianSelect(e){this.store.addPoliticiansSenator(e),this.store.clearPoliticianAutocomplete()}onRemoveSenator(e){this.store.removePoliticiansSenator(e)}onClearAllSenators(){this.store.clearPoliticiansSenators()}onFiltersCollapsedChange(e){this.store.setFiltersCardCollapsed(e)}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-politicians-filters-card"]],decls:12,vars:19,consts:[["item",""],[3,"collapsedChange","collapsedValue"],[1,"ct-filters-card"],[1,"ct-filters-card__chips"],[1,"ct-filters-card__row"],[1,"ct-filters-card__left"],[1,"ct-filters-card__search",3,"valueChange","suggestionSelect","placeholder","suggestions","isSearching","disabled"],["optionLabel","label","optionValue","value",1,"all-grey","text-base","flex-shrink-0",3,"ngModelChange","ngModel","options","allowEmpty"],[3,"dateRangeChange","startDate","endDate","advancedPresets"],[1,"filter-chips"],[3,"ariaLabel"],["type","button",1,"clear-all-btn",3,"click"],[3,"removed","ariaLabel"]],template:function(n,i){if
13(n&1){let l=E();o(0,"app-collapsible-filter-card",1),S("collapsedChange",function(g){return u(l),h(i.onFiltersCollapsedChange(g))}),o(1,"div",2),w(2,Wo,8,3,"div",3),o(3,"div",4)(4,"div",5)(5,"app-politician-autocomplete",6),C(6,"translate"),C(7,"translate"),S("valueChange",function(g){return u(l),h(i.onPoliticianSearch(g))})("suggestionSelect",function(g){return u(l),h(i.onPoliticianSelect(g))}),r()(),o(8,"p-selectButton",7),S("ngModelChange",function(g){return u(l),h(i.onViewModeChange(g))}),A(9,Uo,2,3,"ng-template",null,0,z),r(),o(11,"app-date-range-filter",8),S("dateRangeChange",function(g){return u(l),h(i.onDateRangeChange(g))}),r()()()()}n&2&&(c("collapsedValue",i.store.isFiltersCardCollapsed()),a(2),k(i.store.politiciansTab.selectedSenators().length>0?2:-1),a(3),c("placeholder",i.isLimitReached()?q(6,12,"CONGRESSIONAL.MAX_POLITICIANS_SELECTED",Z(17,Go,i.maxFilters)):y(7,15,"CONGRESSIONAL.SEARCH_POLITICIAN"))("suggestions",i.store.politicianAutocomplete.data())("isSearching",i.store.politicianAutocomplete.isLoading())("disabled",i.isLimitReached()),a(3),c("ngModel",i.store.politiciansTab.sortMode())("options",i.viewModes)("allowEmpty",!1),a(3),c("startDate",i.store.filters.startDate())("endDate",i.store.filters.endDate())("advancedPresets",!0))},dependencies:[Fe,yt,ee,X,J,ne,pe,Xe,Re,Ne,M],styles:["[_nghost-%COMP%]{display:block}.ct-filters-card[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:var(--spacing-3)}.ct-filters-card__chips[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:var(--spacing-3)}.ct-filters-card__row[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--spacing-4);flex-wrap:wrap}.ct-filters-card__left[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--spacing-3);flex:1;min-width:0}.ct-filters-card__search[_ngcontent-%COMP%]{flex:1;min-width:0;max-width:37rem}"]})}return t})();var ji=(()=>{class t{store=b($);barChartTitle=T(()=>this.store.politiciansTab.sortMode()==="trades"?"CONGRESSIONAL.TOP_50_POLITICIANS_TRADES":"CONGRESSIONAL.TOP_50_POLITICIANS_VOLUME");activityChartTitle=T(()=>this.store.politiciansTab.sortMode()==="trades"?"CONGRESSIONAL.ACTIVITY_OVER_TIME_TRADES":"CONGRESSIONAL.ACTIVITY_OVER_TIME_VOLUME");static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-congressional-trades-politicians"]],decls:6,vars:16,consts:[["appStickyStuck","",1,"sticky-filter-card"],[3,"data","isLoading","title","valueMode"],[3,"politicians","isLoading"],[3,"items","isLoading","title","valueMode","scrollable","fixedHeight"]],template:function(n,i){n&1&&(_(0,"app-politicians-filters-card",0)(1,"app-politicians-activity-chart",1),C(2,"translate"),_(3,"app-politicians-table",2)(4,"app-top-politicians-volume-chart",3),C(5,"translate")),n&2&&(a(),c("data",i.store.politiciansActivityData())("isLoading",i.store.politiciansTab.isLoading())("title",y(2,12,i.activityChartTitle()))("valueMode",i.store.politiciansTab.sortMode()),a(2),c("politicians",i.store.politicianRows())("isLoading",i.store.politiciansTab.isLoading()),a(),c("items",i.store.politiciansTopVm())("isLoading",i.store.politiciansTab.isLoading())("title",y(5,14,i.barChartTitle()))("valueMode",i.store.politiciansTab.sortMode())("scrollable",!1)("fixedHeight",!0))},dependencies:[Nt,Hi,Wi,Ui,Ve,M],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;flex:1;gap:var(--spacing-4)}"]})}return t})();var jo=()=>({hasZoom:!1});function qo(t,s){if(t&1&&(o(0,"span",13),_(1,"span",14),o(2,"span",15),m(3),C(4,"translate"),r()()),t&2){let e=s.$implicit,n=d(3);a(),ie("background-color",n.quoteColors()[e]),a(2),f(y(4,3,n.quoteTypeLabels[e]))}}function Yo(t,s){if(t&1&&(o(0,"div",9),O(1,qo,5,5,"span",13,te),r()),t&2){let e=d(2);a(),L(e.quoteTypes)}}function Ko(t,s){if(t&1){let e=E();o(0,"div",4),w(1,Yo,3,0,"div",9),o(2,"label",10)(3,"span",11),m(4),C(5,"translate"),r(),o(6,"p-toggleswitch",12),S("ngModelChange",function(i){u(e);let l=d();return h(l.onColorByTypeChange(i))}),r()()()}if(t&2){let e=d();a(),k(e.colorByType()?1:-1),a(3),f(y(5,3,"CONGRESSIONAL.COLOR_BY_ASSET_TYPE")),a(2),c("ngModel",e.colorByType())}}function Qo(t,s){if(t&1&&(_(0,"span",20),o(1,"div",21),_(2,"p-skeleton",22),r()),t&2){let e=d().$implicit;a(2),c("width",e+"%")}}function Zo(t,s){if(t&1&&(o(0,"div",23),_(1,"p-skeleton",22),r(),_(2,"span",24)),t&2){let e=d().$implicit;a(),c("width",-e+"%")}}function Xo(t,s){if(t&1&&(o(0,"div",16),_(1,"p-skeleton",17)(2,"p-skeleton",18),o(3,"div",19),w(4,Qo,3,1)(5,Zo,3,1),r()()),t&2){let e=s.$implicit;a(4),k(e>=0?4:5)}}function Jo(t,s){if(t&1&&(o(0,"div",7),O(1,Xo,6,1,"div",16,me),r()),t&2){let e=d();a(),L(e.skeletonRows)}}function er(t,s){if(t&1){let e=E();o(0,"app-bar-chart",25),S("chartClick",function(i){u(e);let l=d();return h(l.onBarClick(i))}),r()}if(t&2){let e=d();c("series",e.chartSeries())("options",oe(6,jo))("autoRoundCorners",!1)("customConfig",e.chartCustomConfig())("height",e.chartHeight())("minHeight","100%")}}var tr=30,nt=16,qi=100,ir=.6;function nr(){let t=Math.round(qi*ir),s=qi-t,e=[];for(let n=0;n<t;n++){let i=n/(t-1);e.push(Math.round(90*(1-i)**1.5+2))}for(let n=0;n<s;n++){let i=n/(s-1);e.push(-Math.round(5+65*i**1.3))}return e}var ar=nr(),or={stock:"CONGRESSIONAL.STOCK",etf:"CONGRESSIONAL.ETF",mutualfund:"CONGRESSIONAL.MUTUAL_FUND"},rr=["stock","etf","mutualfund"],Yi=(()=>{class t{items=v.required();isLoading=v(!1);skeletonRows=ar;quoteTypes=rr;quoteTypeLabels=or;store=b($);mainStore=b(ce);router=b(xe);translateService=b(re);destroyRef=b(pt);logoImages=H(new Map);inFlightLogos=new Set;pendingLogos=new Map;flushFrame=null;colorByType=this.store.performanceTab.colorByType;constructor(){de(()=>{let e=this.items(),n=this.logoImages();for(let i of e){if(!i.logo||n.has(i.ticker)||this.inFlightLogos.has(i.ticker))continue;let l=i.logo;if(!l)continue;this.inFlightLogos.add(i.ticker);let p=new Image;p.onload=()=>{this.inFlightLogos.delete(i.ticker),this.pendingLogos.set(i.ticker,l),this.scheduleLogoFlush()},p.onerror=()=>{this.inFlightLogos.delete(i.ticker)},p.src=l}}),this.destroyRef.onDestroy(()=>{this.flushFrame!==null&&cancelAnimationFrame(this.flushFrame)})}scheduleLogoFlush(){this.flushFrame===null&&(this.flushFrame=requestAnimationFrame(()=>{if(this.flushFrame=null,this.pendingLogos.size===0)return;let e=new Map(this.logoImages());for(let[n,i]of this.pendingLogos)e.set(n,i);this.pendingLogos.clear(),this.logoImages.set(e)}))}onColorByTypeChange(e){this.store.setPerformanceColorByType(e)}getCssVar(e){return getComputedStyle(document.documentElement).getPropertyValue(e).trim()}quoteColors=T(()=>(this.mainStore.isDark(),{stock:this.getCssVar("--chart-quote-stock"),etf:this.getCssVar("--chart-quote-etf"),mutualfund:this.getCssVar("--chart-quote-mutualfund")}));chartSeries=T(()=>{this.mainStore.isDark();let e=this.items(),n=this.colorByType(),i=this.quoteColors(),l=this.getCssVar("--chart-activity-bar"),p=this.getCssVar("--additional-danger"),g=this.getCssVar("--border-light");return[{type:"bar",name:this.translateService.instant("CONGRESSIONAL.RETURN_LABEL"),cursor:"pointer",data:e.map(N=>({value:N.returnPercent,itemStyle:{color:n?i[N.quoteType]:N.returnPercent>=0?l:p,borderRadius:N.returnPercent>=0?[0,4,4,0]:[4,0,0,4]}})),markLine:{silent:!0,symbol:"none",data:[{xAxis:0}],lineStyle:{color:g,type:"solid",width:1},label:{show:!1}}}]});chartCustomConfig=T(()=>{this.mainStore.isDark();let e=this.items(),n=e.map(P=>P.ticker),i=this.logoImages(),l=this.getCssVar("--border-light"),p=this.getCssVar("--main-text-color"),g={};e.forEach((P,R)=>{let W=i.get(P.ticker);W&&(g[`logo_${R}`]={width:nt,height:nt,borderRadius:nt/2,verticalAlign:"middle",backgroundColor:{image:W}})});let N={width:nt,height:nt,borderRadius:nt/2,verticalAlign:"middle",backgroundColor:this.getCssVar("--bg-alt"),borderColor:this.getCssVar("--border-dark"),borderWidth:1};return{xAxis:{type:"value",position:"bottom",axisLabel:{formatter:P=>`${P}%`,color:p,fontSize:12}
13,axisLine:{show:!1},axisTick:{show:!1},splitLine:{lineStyle:{color:l}}},yAxis:{type:"category",data:n,inverse:!0,axisLabel:{fontSize:12,color:p,align:"left",margin:78,formatter:(P,R)=>i.has(P)?`{logo_${R}|}{name|${P}}`:`{ph|}{name|${P}}`,rich:se({ph:N,name:{fontSize:12,color:p,verticalAlign:"middle",padding:[0,0,0,4]}},g)},axisLine:{show:!0,lineStyle:{color:l}},axisTick:{show:!1},splitLine:{show:!1}},grid:{left:"86px",right:"20px",top:"10px",bottom:"28px",containLabel:!1},tooltip:{trigger:"item",formatter:P=>{let R=P,W=R.value>=0?"+":"",V=this.items()[R.dataIndex],Y=V?.name,Ge=V?.logo??null,at=Ge?`<img src="${Ge}" style="width:1.6875rem;height:1.6875rem;border-radius:50%;flex-shrink:0;object-fit:cover" />`:"",ot=Y?`<strong>${R.name}</strong> <span style="opacity:0.7">${Y}</span>`:`<strong>${R.name}</strong>`,$e=`<div style="display:flex;align-items:center;gap:0.5rem">${at}<span>${ot}</span></div>`,rt=`${this.translateService.instant("CONGRESSIONAL.RETURN_LABEL")}: <strong>${W}${R.value.toFixed(2)}%</strong>`;return`<div style="display:flex;flex-direction:column;gap:0.125rem">${$e}<div>${rt}</div></div>`}},dataZoom:[]}});chartHeight=T(()=>`${this.items().length*tr+40}px`);onBarClick(e){let n=this.items()[e.dataIndex]?.ticker;n&&this.router.navigate(["/user/asset",n,"summary"])}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-performance-return-chart"]],inputs:{items:[1,"items"],isLoading:[1,"isLoading"]},decls:13,vars:8,consts:[[1,"h-full","body-h-full"],[1,"card-with-sub-cards","flex-1"],[1,"return-chart__header"],[1,"card-title"],[1,"return-chart__header-actions"],[1,"return-chart__note"],[1,"return-chart__note-icon"],[1,"return-chart-skeleton"],[3,"series","options","autoRoundCorners","customConfig","height","minHeight"],[1,"return-chart__legend"],["for","colorByTypeToggle",1,"return-chart__toggle-label"],[1,"text-sm","secondary-text"],["inputId","colorByTypeToggle",3,"ngModelChange","ngModel"],[1,"return-chart__legend-item"],[1,"return-chart__legend-swatch"],[1,"return-chart__legend-label"],[1,"return-chart-skeleton__row"],["shape","circle","size","1rem"],["width","45px","height","20px","borderRadius","4px"],[1,"return-chart-skeleton__bar-track"],[1,"return-chart-skeleton__bar-offset"],[1,"return-chart-skeleton__bar-value"],["height","20px","borderRadius","3px",3,"width"],[1,"return-chart-skeleton__bar-negative"],[1,"return-chart-skeleton__bar-empty"],[3,"chartClick","series","options","autoRoundCorners","customConfig","height","minHeight"]],template:function(n,i){n&1&&(o(0,"p-card",0)(1,"div",1)(2,"div",2)(3,"h3",3),m(4),C(5,"translate"),r(),w(6,Ko,7,5,"div",4),r(),o(7,"p",5),_(8,"app-info-icon",6),m(9),C(10,"translate"),r(),w(11,Jo,3,0,"div",7)(12,er,1,7,"app-bar-chart",8),r()()),n&2&&(a(4),f(y(5,4,"CONGRESSIONAL.TOP_HOLDINGS_PERFORMANCE")),a(2),k(i.isLoading()?-1:6),a(3),j(" ",y(10,6,"CONGRESSIONAL.TOP_100_TICKERS_NOTE")," "),a(2),k(i.isLoading()?11:12))},dependencies:[B,D,Je,G,kt,ee,X,J,Pe,M],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;flex:1}.return-chart__header[_ngcontent-%COMP%]{display:flex;align-items:flex-start;justify-content:space-between;flex-wrap:wrap;gap:var(--spacing-3);margin-bottom:var(--spacing-2)}.return-chart__header-actions[_ngcontent-%COMP%]{display:flex;align-items:center;flex-wrap:wrap;gap:var(--spacing-4)}.return-chart__toggle-label[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;gap:var(--spacing-2);cursor:pointer;flex-shrink:0}.return-chart__legend[_ngcontent-%COMP%]{display:flex;align-items:center;flex-wrap:wrap;gap:var(--spacing-2) var(--spacing-6)}.return-chart__legend-item[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--spacing-2)}.return-chart__legend-swatch[_ngcontent-%COMP%]{display:inline-block;width:1rem;height:1rem;border-radius:var(--border-radius-sm);flex-shrink:0}.return-chart__legend-label[_ngcontent-%COMP%]{font-size:var(--text-xs);font-weight:var(--font-semibold);color:var(--text-secondary);white-space:nowrap}.return-chart__note[_ngcontent-%COMP%]{display:flex;align-items:flex-start;gap:var(--spacing-2);font-size:var(--text-sm);color:var(--muted-text-color);line-height:1.5;margin:0 0 var(--spacing-3)}.return-chart__note-icon[_ngcontent-%COMP%]{--app-icon-size: var(--text-sm);flex-shrink:0;margin-top:.125rem}.return-chart-skeleton[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:var(--spacing-2);padding:var(--spacing-1) 0}.return-chart-skeleton__row[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--spacing-3);height:1.875rem}.return-chart-skeleton__row[_ngcontent-%COMP%]   p-skeleton[_ngcontent-%COMP%]:nth-child(1){flex-shrink:0}.return-chart-skeleton__row[_ngcontent-%COMP%]   p-skeleton[_ngcontent-%COMP%]:nth-child(2){flex-shrink:0;width:2.8125rem}.return-chart-skeleton__bar-track[_ngcontent-%COMP%]{display:flex;align-items:center;flex:1;min-width:0}.return-chart-skeleton__bar-offset[_ngcontent-%COMP%]{flex:0 0 20%}.return-chart-skeleton__bar-value[_ngcontent-%COMP%]{flex:1 1 0%;min-width:0}.return-chart-skeleton__bar-negative[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;flex:0 0 20%;min-width:0}.return-chart-skeleton__bar-empty[_ngcontent-%COMP%]{flex:1 1 0%}"]})}return t})();var lr=t=>({max:t}),sr=t=>({name:t}),cr=(t,s)=>s.senator_id;function pr(t,s){if(t&1){let e=E();o(0,"app-filter-chip",12),C(1,"translate"),S("removed",function(){let i=u(e).$implicit,l=d(2);return h(l.onRemoveSenator(i.senator_id))}),m(2),r()}if(t&2){let e=s.$implicit;c("ariaLabel",q(1,3,"CONGRESSIONAL.REMOVE",Z(6,sr,e.first_name+" "+e.last_name))),a(2),je(" ",e.first_name," ",e.last_name," ")}}function dr(t,s){if(t&1){let e=E();o(0,"div",3)(1,"div",9),O(2,pr,3,8,"app-filter-chip",10,cr),r(),o(4,"button",11),S("click",function(){u(e);let i=d();return h(i.onClearAllSenators())}),_(5,"app-refresh-icon"),m(6),C(7,"translate"),r()()}if(t&2){let e=d();a(2),L(e.store.performanceTab.selectedSenators()),a(4),j(" ",y(7,1,"CONGRESSIONAL.CLEAR_ALL")," ")}}function mr(t,s){if(t&1&&(m(0),C(1,"translate")),t&2){let e=s.$implicit;f(y(1,1,e.label))}}var Ki=(()=>{class t{store=b($);maxFilters=tt;activeParty=T(()=>this.store.performanceTab().partyFilter);isLimitReached=T(()=>this.store.performanceTab.selectedSenators().length>=tt);partyOptions=[{label:"SELECT.ALL",value:"all"},{label:"SELECT.DEMOCRAT",value:"democrat"},{label:"SELECT.REPUBLICAN",value:"republican"}];currentPoliticianQuery=H("");onPartyChange(e){this.store.setPerformancePartyFilter(e);let n=this.currentPoliticianQuery();n&&this.searchPoliticiansWithPartyFilter(n,e)}
13onDateRangeChange(e){this.store.setDateRange(e.startDate,e.endDate)}onPoliticianSearch(e){let n=e.trim();this.currentPoliticianQuery.set(n),n?this.searchPoliticiansWithPartyFilter(n,this.activeParty()):this.store.clearPoliticianAutocomplete()}onPoliticianSelect(e){this.currentPoliticianQuery.set(""),this.store.addPerformanceSenator(e),this.store.clearPoliticianAutocomplete()}onRemoveSenator(e){this.store.removePerformanceSenator(e)}onClearAllSenators(){this.store.clearPerformanceSenators()}onFiltersCollapsedChange(e){this.store.setFiltersCardCollapsed(e)}searchPoliticiansWithPartyFilter(e,n){let{startDate:i,endDate:l}=this.store.filters(),p=this.toPartyTypes(n);this.store.searchPoliticiansAutocomplete(se({search_text:e,start_date:i,end_date:l,limit:10},p?{party_types:p}:{}))}toPartyTypes(e){if(e!=="all")return[e]}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-performance-filters-card"]],decls:12,vars:19,consts:[["item",""],[3,"collapsedChange","collapsedValue"],[1,"ct-filters-card"],[1,"ct-filters-card__chips"],[1,"ct-filters-card__row"],[1,"ct-filters-card__left"],[1,"ct-filters-card__search",3,"valueChange","suggestionSelect","placeholder","suggestions","isSearching","disabled"],["optionLabel","label","optionValue","value",1,"all-grey","text-base","flex-shrink-0",3,"ngModelChange","ngModel","options","allowEmpty"],[3,"dateRangeChange","startDate","endDate","advancedPresets"],[1,"filter-chips"],[3,"ariaLabel"],["type","button",1,"clear-all-btn",3,"click"],[3,"removed","ariaLabel"]],template:function(n,i){if(n&1){let l=E();o(0,"app-collapsible-filter-card",1),S("collapsedChange",function(g){return u(l),h(i.onFiltersCollapsedChange(g))}),o(1,"div",2),w(2,dr,8,3,"div",3),o(3,"div",4)(4,"div",5)(5,"app-politician-autocomplete",6),C(6,"translate"),C(7,"translate"),S("valueChange",function(g){return u(l),h(i.onPoliticianSearch(g))})("suggestionSelect",function(g){return u(l),h(i.onPoliticianSelect(g))}),r()(),o(8,"p-selectButton",7),S("ngModelChange",function(g){return u(l),h(i.onPartyChange(g))}),A(9,mr,2,3,"ng-template",null,0,z),r(),o(11,"app-date-range-filter",8),S("dateRangeChange",function(g){return u(l),h(i.onDateRangeChange(g))}),r()()()()}n&2&&(c("collapsedValue",i.store.isFiltersCardCollapsed()),a(2),k(i.store.performanceTab.selectedSenators().length>0?2:-1),a(3),c("placeholder",i.isLimitReached()?q(6,12,"CONGRESSIONAL.MAX_POLITICIANS_SELECTED",Z(17,lr,i.maxFilters)):y(7,15,"CONGRESSIONAL.SEARCH_POLITICIAN"))("suggestions",i.store.politicianAutocomplete.data())("isSearching",i.store.politicianAutocomplete.isLoading())("disabled",i.isLimitReached()),a(3),c("ngModel",i.activeParty())("options",i.partyOptions)("allowEmpty",!1),a(3),c("startDate",i.store.filters.startDate())("endDate",i.store.filters.endDate())("advancedPresets",!0))},dependencies:[Fe,ee,X,J,ne,pe,Xe,Re,Ne,M],styles:["[_nghost-%COMP%]{display:block}.ct-filters-card[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:var(--spacing-3)}.ct-filters-card__chips[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr auto;align-items:start;gap:var(--spacing-3)}.ct-filters-card__row[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--spacing-4);flex-wrap:wrap}.ct-filters-card__left[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--spacing-3);flex:1;min-width:0}.ct-filters-card__search[_ngcontent-%COMP%]{flex:1;min-width:0;max-width:37rem}"]})}return t})();var Qi=(()=>{class t{store=b($);static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-congressional-trades-performance"]],decls:2,vars:2,consts:[["appStickyStuck","",1,"sticky-filter-card"],[3,"items","isLoading"]],template:function(n,i){n&1&&_(0,"app-performance-filters-card",0)(1,"app-performance-return-chart",1),n&2&&(a(),c("items",i.store.performanceReturnItems())("isLoading",i.store.performanceTab.isLoading()))},dependencies:[Ve,Yi,Ki],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;flex:1;gap:var(--spacing-4)}"]})}return t})();var Zi=(()=>{class t{store=b($);
13onDateRangeChange(e){this.store.setDateRange(e.startDate,e.endDate)}onFiltersCollapsedChange(e){this.store.setFiltersCardCollapsed(e)}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-party-breakdown-filters-card"]],decls:4,vars:4,consts:[[3,"collapsedChange","collapsedValue"],[1,"pb-filters-card"],[1,"pb-filters-card__row"],[1,"pb-filters-card__date",3,"dateRangeChange","startDate","endDate","advancedPresets"]],template:function(n,i){n&1&&(o(0,"app-collapsible-filter-card",0),S("collapsedChange",function(p){return i.onFiltersCollapsedChange(p)}),o(1,"div",1)(2,"div",2)(3,"app-date-range-filter",3),S("dateRangeChange",function(p){return i.onDateRangeChange(p)}),r()()()()),n&2&&(c("collapsedValue",i.store.isFiltersCardCollapsed()),a(3),c("startDate",i.store.filters.startDate())("endDate",i.store.filters.endDate())("advancedPresets",!0))},dependencies:[Fe,pe],styles:["[_nghost-%COMP%]{display:block}.pb-filters-card__row[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--spacing-8);flex-wrap:wrap}.pb-filters-card__date[_ngcontent-%COMP%]{margin-left:auto}"]})}return t})();function gr(t,s){if(t&1&&(m(0),C(1,"translate")),t&2){let e=s.$implicit;f(y(1,1,e.label))}}function _r(t,s){if(t&1&&(m(0),C(1,"translate")),t&2){let e=s.$implicit;f(y(1,1,e.label))}}var Xi=(()=>{class t{store=b($);groupByModes=[{label:"SELECT.PARTY",value:"party"},{label:"SELECT.CHAMBER",value:"chamber"},{label:"SELECT.PARTY_CHAMBER",value:"party-chamber"}];metricModes=[{label:"SELECT.VOLUME_PERCENT",value:"volume-pct"},{label:"SELECT.ABSOLUTE",value:"absolute"},{label:"SELECT.TRADES",value:"trades"}];onGroupByChange(e){this.store.setPartyBreakdownGroupBy(e)}onMetricChange(e){this.store.setPartyBreakdownMetric(e)}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-party-breakdown-view-controls"]],decls:7,vars:6,consts:[["item",""],[1,"pb-view-controls"],["optionLabel","label","optionValue","value",1,"all-grey","compact","flex-shrink-0",3,"ngModelChange","allowEmpty","ngModel","options"]],template:function(n,i){if(n&1){let l=E();o(0,"div",1)(1,"p-selectButton",2),S("ngModelChange",function(g){return u(l),h(i.onGroupByChange(g))}),A(2,gr,2,3,"ng-template",null,0,z),r(),o(4,"p-selectButton",2),S("ngModelChange",function(g){return u(l),h(i.onMetricChange(g))}),A(5,_r,2,3,"ng-template",null,0,z),r()()}n&2&&(a(),c("allowEmpty",!1)("ngModel",i.store.partyBreakdownGroupBy())("options",i.groupByModes),a(3),c("allowEmpty",!1)("ngModel",i.store.partyBreakdownMetric())("options",i.metricModes))},dependencies:[ee,X,J,ne,M],styles:["[_nghost-%COMP%]{display:block;padding-top:var(--spacing-3);border-top:1px solid var(--border-light)}.pb-view-controls[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:.75rem;
13align-items:center}"]})}return t})();var ur=()=>({hasZoom:!1,hasTooltip:!0,smooth:!0,showSymbol:!1});function hr(t,s){t&1&&_(0,"p-skeleton",3)}function Cr(t,s){if(t&1&&_(0,"app-line-chart",4),t&2){let e=d();c("series",e.chartSeries())("xAxis",e.xAxisData())("options",oe(4,ur))("customConfig",e.chartCustomConfig())}}var st={houseDem:"CONGRESSIONAL.HOUSE_DEM",houseRep:"CONGRESSIONAL.HOUSE_REP",senateDem:"CONGRESSIONAL.SENATE_DEM",senateRep:"CONGRESSIONAL.SENATE_REP"},Ji=(()=>{class t{data=v.required();isLoading=v(!1);mainStore=b(ce);translateService=b(re);getCssVar(e){return getComputedStyle(document.documentElement).getPropertyValue(e).trim()}groupColors=T(()=>(this.mainStore.isDark(),{houseDem:this.getCssVar("--additional"),houseRep:this.getCssVar("--additional-danger"),senateDem:this.getCssVar("--chart-senate-dem"),senateRep:this.getCssVar("--chart-senate-rep")}));xAxisData=T(()=>[]);chartSeries=T(()=>{let e=this.data(),n=this.groupColors(),i={focus:"series"};return[{type:"line",name:this.translateService.instant(st.houseDem),smooth:!0,color:n.houseDem,emphasis:i,data:e.map(l=>[l.month,l.houseDem])},{type:"line",name:this.translateService.instant(st.houseRep),smooth:!0,color:n.houseRep,emphasis:i,data:e.map(l=>[l.month,l.houseRep])},{type:"line",name:this.translateService.instant(st.senateDem),smooth:!0,color:n.senateDem,emphasis:i,data:e.map(l=>[l.month,l.senateDem])},{type:"line",name:this.translateService.instant(st.senateRep),smooth:!0,color:n.senateRep,emphasis:i,data:e.map(l=>[l.month,l.senateRep])}]});chartCustomConfig=T(()=>{let e=this.groupColors();return this.mainStore.isDark(),{legend:{show:!0,top:8,left:"center",icon:"circle",itemWidth:12,itemHeight:12,itemGap:24,textStyle:{color:this.getCssVar("--main-text-color"),fontSize:14,fontWeight:400},data:["houseDem","houseRep","senateDem","senateRep"].map(n=>({name:this.translateService.instant(st[n]),itemStyle:{color:e[n]}}))},xAxis:{axisLabel:{hideOverlap:!0,fontSize:12,color:this.getCssVar("--main-text-color")}},yAxis:{axisLabel:{fontSize:12,color:this.getCssVar("--main-text-color"),formatter:n=>fe(n)}},grid:{left:"65px",right:"20px",top:"52px",bottom:"32px",containLabel:!1},tooltip:{trigger:"axis",formatter:n=>{let i=n,p=`<div style="margin-bottom:6px;font-weight:bold">${i[0]?.value?.[0]?new Date(i[0].value[0]).toLocaleDateString("en-US",{month:"long",year:"numeric"}):""}</div>`;for(let g of i){let N=fe(g.value[1]);p+=`<div style="display:flex;align-items:center;gap:8px;margin-top:3px">
14              <span style="display:inline-block;width:10px;height:10px;border-radius:50%;background:${g.color}"></span>
15              <span>${g.seriesName}: <strong>${N}</strong></span>
16            </div>`}return p}},dataZoom:[]}});static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-activity-over-time-chart"]],inputs:{data:[1,"data"],isLoading:[1,"isLoading"]},decls:8,vars:4,consts:[[1,"activity-chart"],[1,"activity-chart__header"],[1,"card-title"],["width","100%","height","320px","styleClass","activity-chart__skeleton"],["height","320px",3,"series","xAxis","options","customConfig"]],template:function(n,i){n&1&&(o(0,"p-card")(1,"div",0)(2,"div",1)(3,"h3",2),m(4),C(5,"translate"),r()(),w(6,hr,1,0,"p-skeleton",3)(7,Cr,1,5,"app-line-chart",4),r()()),n&2&&(a(4),f(y(5,2,"CONGRESSIONAL.ACTIVITY_OVER_TIME_VOLUME")),a(2),k(i.isLoading()?6:7))},dependencies:[B,D,U,G,wt,M],styles:["[_nghost-%COMP%]{display:block}.activity-chart[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:var(--spacing-4)}.activity-chart__header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between}"]})}return t})();var fr=t=>({count:t}),vr=(t,s,e)=>({"mr-auto":t,"mx-auto":s,"ml-auto":e}),Sr=t=>["/user/asset",t,"summary"],en=(t,s)=>s.field;function yr(t,s){if(t&1){let e=E();o(0,"th",8)(1,"app-table-header-cell-content",9),S("columnSort",function(i){u(e);let l=d(2);return h(l.onColumnSort(i.field,i.event))}),r()()}if(t&2){let e=s.$implicit,n=d(2);c("ngStyle",e.headStyle),a(),c("col",e)("sortStates",n.sortStates)}}function br(t,s){if(t&1&&(o(0,"tr"),O(1,yr,2,3,"th",8,en),r()),t&2){let e=d();a(),L(e.columns)}}function Tr(t,s){if(t&1&&(o(0,"td",8),_(1,"p-skeleton",11),r()),t&2){let e=s.$implicit,n=s.$index;c("ngStyle",e.cellStyle),a(),c("ngClass",Se(3,vr,e.align==="left"||!e.align,e.align==="center",e.align==="right"))("width",n%2===0?"40%":"60%")}}function xr(t,s){if(t&1&&(o(0,"tr"),O(1,Tr,2,7,"td",8,en),r()),t&2){let e=d(2);a(),L(e.columns)}}function wr(t,s){if(t&1){let e=E();o(0,"tr",12),S("click",function(){u(e);let i=d().$implicit,l=d();return h(l.onRowClick(i))}),o(1,"td",8)(2,"span",13),m(3),r()(),o(4,"td",8),_(5,"p-tag",14),r(),o(6,"td",8)(7,"span"),m(8),r()(),o(9,"td",8)(10,"span"),m(11),r()(),o(12,"td",8)(13,"span"),m(14),r()(),o(15,"td",15),S("click",function(i){return u(e),h(i.stopPropagation())}
16),o(16,"a",16),m(17),r()(),o(18,"td",8)(19,"span"),m(20),r()()()}if(t&2){let e=d().$implicit,n=d();a(),c("ngStyle",n.columns[0].cellStyle),a(),Q("party-breakdown-table__sector--unassigned",e.sector===n.unassignedSectorLabel),a(),f(e.sector),a(),c("ngStyle",n.columns[1].cellStyle),a(),ae(n.getPartyClass(e.party)),c("value",e.party),a(),c("ngStyle",n.columns[2].cellStyle),a(2),f(e.chamber),a(),c("ngStyle",n.columns[3].cellStyle),a(2),f(e.totalVolume),a(),c("ngStyle",n.columns[4].cellStyle),a(2),f(e.tradesCount),a(),c("ngStyle",n.columns[5].cellStyle),a(),c("routerLink",Z(19,Sr,e.topTicker)),a(),f(e.topTicker),a(),c("ngStyle",n.columns[6].cellStyle),a(2),f(e.topPolitician)}}function kr(t,s){if(t&1&&w(0,xr,3,0,"tr")(1,wr,21,21,"tr",10),t&2){let e=d();k(e.isLoading()?0:1)}}function Er(t,s){if(t&1&&(o(0,"tr")(1,"td",17)(2,"div",18),_(3,"app-search-icon",19),o(4,"span",20),m(5),C(6,"translate"),r()()()()),t&2){let e=d();a(),K("colspan",e.columns.length),a(4),f(y(6,2,"CONGRESSIONAL.NO_DATA"))}}function Mr(t,s){if(t&1){let e=E();o(0,"app-table-paginator",21),S("rowsChange",function(i){u(e);let l=d();return h(l.onRowsChange(i))}),r()}if(t&2){let e=s.$implicit;c("currentRows",e.rows)("state",e)("useLocalPagination",!0)}}var tn=(()=>{class t{unassignedSectorLabel=Ci;rows=v.required();isLoading=v(!1);currentRows=H(10);columns=[{field:"sector",header:"CONGRESSIONAL.SECTOR",sortable:!0,align:"left",headStyle:{"min-width":"10rem"},cellStyle:{"text-align":"left"},defaultVisible:!0,type:"text"},{field:"party",header:"CONGRESSIONAL.PARTY",sortable:!0,align:"center",headStyle:{"min-width":"5rem"},cellStyle:{"text-align":"center"},defaultVisible:!0,type:"custom"},{field:"chamber",header:"CONGRESSIONAL.CHAMBER",sortable:!0,align:"center",headStyle:{"min-width":"6rem"},cellStyle:{"text-align":"center"},defaultVisible:!0,type:"text"},{field:"totalVolume",header:"CONGRESSIONAL.TOTAL_VOLUME",sortable:!0,align:"right",headStyle:{"min-width":"7rem"},cellStyle:{"text-align":"right"},defaultVisible:!0,type:"text",localSortField:"totalVolumeValue"},{field:"tradesCount",header:"CONGRESSIONAL.TRADES_COUNT",sortable:!0,align:"right",headStyle:{"min-width":"7rem"},cellStyle:{"text-align":"right"},defaultVisible:!0,type:"number"},{field:"topTicker",header:"CONGRESSIONAL.TOP_TICKER",sortable:!0,align:"left",headStyle:{"min-width":"6rem"},cellStyle:{"text-align":"left"},defaultVisible:!0,type:"text"},{field:"topPolitician",header:"CONGRESSIONAL.TOP_POLITICIAN",sortable:!0,align:"left",headStyle:{"min-width":"10rem"},cellStyle:{"text-align":"left"},defaultVisible:!0,type:"text"}];tableSortService=b(Ie);localSort=this.tableSortService.createLocalSort(this.rows,this.columns);sortStates=this.localSort.sortStates;sortedRows=this.localSort.sortedRows;onRowsChange(e){this.currentRows.set(e)}onColumnSort(e,n){this.localSort.onColumnSort(e,n)}getPartyClass(e){switch(e){case"DEM":return"p-tag-outlined-blue";case"REP":return"p-tag-outlined-red";case"All":return""}}onRowClick(e){console.log("Sector ranking row clicked:",e)}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-party-breakdown-table"]],inputs:{rows:[1,"rows"],isLoading:[1,"isLoading"]},decls:10,vars:18,consts:[[1,"h-full","body-h-full"],[1,"card-with-sub-cards","flex-1"],[3,"title","subtitle","isActionEnabled"],["sortMode","multiple",1,"party-breakdown-table","h-full","h-content-full","clickable-rows",3,"alwaysShowPaginator","loading","paginator","rows","scrollable","showCurrentPageReport","totalRecords","value"],["pTemplate","header"],["pTemplate","body"],["pTemplate","emptymessage"],["pTemplate","paginatorright"],[3,"ngStyle"],[3,"columnSort","col","sortStates"],[1,"table-row"],[3,"ngClass","width"],[1,"table-row",3,"click"],[1,"party-breakdown-table__sector"],[3,"value"],[3,"click","ngStyle"],[1,"party-breakdown-table__ticker",3,"routerLink"],[1,"text-center","py-8"],["appTableStickyEmpty","",1,"table-empty-message"],[1,"text-4xl"],[1,"secondary-text"],[3,"rowsChange","currentRows","state","useLocalPagination"]],template:function(n,i){n&1&&(o(0,"p-card",0)(1,"div",1),_(2,"app-card-header",2),C(3,"translate"),C(4,"translate"),o(5,"p-table",3),A(6,br,3,0,"ng-template",4)(7,kr,2,1,"ng-template",5)(8,Er,7,4,"ng-template",6)(9,Mr,1,3,"ng-template",7),r()()()),n&2&&(a(2),c("title",y(3,11,"CONGRESSIONAL.SECTOR_RANKINGS"))("subtitle",q(4,13,"CONGRESSIONAL.RESULTS",Z(16,fr,i.rows().length)))("isActionEnabled",!1),a(3),c("alwaysShowPaginator",!0)("loading",i.isLoading())("paginator",!0)("rows",i.currentRows())("scrollable",!0)("showCurrentPageReport",!1)("totalRecords",i.rows().length)("value",i.sortedRows()))},dependencies:[ue,Te,we,Oe,Me,ke,B,D,U,G,Ce,he,Le,De,Ae,Ke,Ee,M],styles:["[_nghost-%COMP%]{display:block;height:100%}.party-breakdown-table__sector[_ngcontent-%COMP%]{font-weight:var(--font-bold)}.party-breakdown-table__sector--unassigned[_ngcontent-%COMP%]{font-weight:var(--font-regular);color:var(--muted-text-color)}.party-breakdown-table__ticker[_ngcontent-%COMP%]{font-weight:var(--font-semibold);color:var(--additional);text-decoration:none}.party-breakdown-table__ticker[_ngcontent-%COMP%]:hover{text-decoration:underline}"]})}return t})();var Or=(t,s)=>s.title;function Lr(t,s){if(t&1&&_(0,"app-congressional-trades-simple-card",2),t&2){let e=s.$implicit,n=d();c("title",e.title)("value",e.value)("iconCmp",e.iconCmp)("tooltip",e.tooltip)("isLoading",n.store.partyBreakdownTab.isLoading())}}var nn=(()=>{class t{store=b($);summaryStatCards=T(()=>{let e=this.store.partyBreakdownMeta(),n=this.store.partyBreakdownTopSector();return[{title:"CONGRESSIONAL.STAT_TOTAL_TRADES",value:String(this.store.partyBreakdownTotalTrades()),iconCmp:Et,tooltip:"
16CONGRESSIONAL.STAT_PARTY_BREAKDOWN_TOOLTIP"},{title:"CONGRESSIONAL.STAT_TOTAL_VOLUME",value:e?fe(e.total_buy_amount+e.total_sell_amount):"\u2014",iconCmp:vi},{title:"CONGRESSIONAL.STAT_ACTIVE_POLITICIANS",value:e?String(this.store.partyBreakdownActivePoliticians()):"\u2014",iconCmp:ei},{title:"CONGRESSIONAL.STAT_TOP_SECTOR",value:n,iconCmp:ti}]});onTreemapTransferChange(e){this.store.setTickerTreemapTransferType(e)}onTreemapChamberChange(e){this.store.setTickerTreemapChamber(e)}heatmapValueSuffix=T(()=>this.store.partyBreakdownMetric()==="absolute"?"$M":"%");onSectorsLimitChange(e){this.store.setPartyBreakdownSectorsLimit(e)}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-congressional-trades-party-breakdown"]],decls:9,vars:13,consts:[["appStickyStuck","",1,"sticky-filter-card"],[1,"congressional-trades-stat-cards"],[3,"title","value","iconCmp","tooltip","isLoading"],[3,"sectorsLimitChange","rows","isLoading","valueSuffix","showResolutionSelector","sectorsLimit"],["heatmapSubControls",""],[3,"transferTypeChange","chamberChange","items","isLoading","showFlowControls","transferType","chamber"],[3,"data","isLoading"],[3,"rows"]],template:function(n,i){n&1&&(_(0,"app-party-breakdown-filters-card",0),o(1,"div",1),O(2,Lr,1,5,"app-congressional-trades-simple-card",2,Or),r(),o(4,"app-sector-allocation-heatmap",3),S("sectorsLimitChange",function(p){return i.onSectorsLimitChange(p)}),_(5,"app-party-breakdown-view-controls",4),r(),o(6,"app-volume-by-ticker-sector-card",5),S("transferTypeChange",function(p){return i.onTreemapTransferChange(p)})("chamberChange",function(p){return i.onTreemapChamberChange(p)}),r(),_(7,"app-activity-over-time-chart",6)(8,"app-party-breakdown-table",7)),n&2&&(a(2),L(i.summaryStatCards()),a(2),c("rows",i.store.partyBreakdownHeatmapRows())("isLoading",i.store.partyBreakdownTab.isLoading())("valueSuffix",i.heatmapValueSuffix())("showResolutionSelector",!0)("sectorsLimit",i.store.partyBreakdownSectorsLimit()),a(2),c("items",i.store.tickerTreemapHeatmapData())("isLoading",i.store.tickerTreemapLoading())("showFlowControls",!0)("transferType",i.store.tickerTreemapTransferType())("chamber",i.store.tickerTreemapChamber()),a(),c("data",i.store.partyBreakdownActivityData())("isLoading",i.store.partyBreakdownTab.isLoading()),a(),c("rows",i.store.partyBreakdownTableRows()))},dependencies:[Ve,fi,Zi,Xi,Ot,it,Ji,tn],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:var(--spacing-4);flex:1}.congressional-trades-stat-cards[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:var(--spacing-4)}@media(max-width:1200px){.congressional-trades-stat-cards[_ngcontent-%COMP%]{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(max-width:768px){.congressional-trades-stat-cards[_ngcontent-%COMP%]{grid-template-columns:1fr}}"],changeDetection:0})}return t})();var an=(t,s)=>s.value;function Pr(t,s){if(t&1){let e=E();o(0,"p-tab",8),S("mousedown",function(){let i=u(e).$implicit,l=d();return h(l.onTabMouseDown(i.value))}),m(1),C(2,"translate"),r()}if(t&2){let e=s.$implicit;c("value",e.value),a(),j(" ",y(2,2,e.title)," ")}}function Nr(t,s){if(t&1&&(o(0,"p-tabpanel",6),gt(1,9),r()),t&2){let e=s.$implicit;c("value",e.value),a(),c("ngComponentOutlet",e.component)}}var yg=(()=>{class t{elementRef=b(ve);router=b(xe);savedTablistScrollLeft=0;tabs=[{value:"overview",title:"TABS.OVERVIEW",component:Mi},{value:"trades",title:"TABS.TRADES",component:Vi},{value:"tickers",title:"TABS.TICKERS",component:$i},{value:"politicians",title:"TABS.POLITICIANS",component:ji},{value:"performance",title:"TABS.PERFORMANCE",component:Qi},{value:"party-breakdown",title:"TABS.PARTY_BREAKDOWN",component:nn}];chipTabs=this.tabs.map(e=>({value:e.value,label:e.title}));activeTab=vt(this.router.events.pipe(Ht(e=>e instanceof Yt),ct(()=>this.getTabFromRouterUrl())),{initialValue:this.getTabFromRouterUrl()});currentTab=H(this.getTabFromRouterUrl());constructor(){de(()=>{let e=this.activeTab();e&&(this.currentTab.set(e),setTimeout(()=>{let n=this.elementRef.nativeElement.querySelector(".p-tablist-viewport");n&&(n.scrollLeft=this.savedTablistScrollLeft)},0),setTimeout(()=>{window.scrollTo({top:0,behavior:"instant"})},100))})}onTabMouseDown(e){let n=this.elementRef.nativeElement.querySelector(".p-tablist-viewport");n&&(this.savedTablistScrollLeft=n.scrollLeft),this.router.navigate(["/user","congressional-trades",e])}getTabFromRouterUrl(){let n=this.router.url.split("?")[0].split("/").filter(p=>p.length>0),i=n[n.length-1]??"overview";return new Set(this.tabs.map(p=>p.value)).has(i)?i:"overview"}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=x({type:t,selectors:[["app-congressional-trades"]],decls:13,vars:11,consts:[["data-cy","congressional-trades-page",1,"h-full","body-
16h-full","flex-0"],[1,"mb-0!",3,"subtitle","title","isActionEnabled","showBetaBadge"],[1,"tabs-container"],[1,"tabs-container__chips",3,"itemSelect","items","activeValue"],["scrollable","",1,"main-tabs","h-full",3,"value"],[1,"card-shadow","tabs-container__desktop-list"],[3,"value"],[1,"mt-4","h-full","!bg-inherit","!p-0"],[3,"mousedown","value"],[3,"ngComponentOutlet"]],template:function(n,i){n&1&&(o(0,"p-card",0),_(1,"app-card-header",1),C(2,"translate"),C(3,"translate"),r(),o(4,"div",2)(5,"app-chip-tab-switcher",3),S("itemSelect",function(p){return i.onTabMouseDown(p)}),r(),o(6,"p-tabs",4)(7,"p-tablist",5),O(8,Pr,3,4,"p-tab",6,an),r(),o(10,"p-tabpanels",7),O(11,Nr,2,2,"p-tabpanel",6,an),r()()()),n&2&&(a(),c("subtitle",y(2,7,"CONGRESSIONAL.SUBTITLE"))("title",y(3,9,"CONGRESSIONAL.TITLE"))("isActionEnabled",!1)("showBetaBadge",!0),a(4),c("items",i.chipTabs)("activeValue",i.currentTab()),a(),c("value",i.currentTab()),a(2),L(i.tabs),a(3),L(i.tabs))},dependencies:[ft,Ct,D,Ke,hi,si,li,ri,oi,ni,ai,M],styles:["[_nghost-%COMP%]{display:flex;width:100%;flex:1;flex-direction:column;gap:var(--spacing-4)}p-tabpanel.p-tabpanel-active[_ngcontent-%COMP%]{display:flex;flex-direction:column;flex:1}.tabs-container[_ngcontent-%COMP%]{display:flex;flex-direction:column;flex:1;min-width:0}.tabs-container__chips[_ngcontent-%COMP%]{display:none}@media(max-width:1024px){.tabs-container__chips[_ngcontent-%COMP%]{display:block}}@media(max-width:1024px){.tabs-container__desktop-list[_ngcontent-%COMP%]{display:none}}"]})}return t})();export{yg as CongressionalTradesComponent};

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.