(c=t.charCodeAt(r))||c>57){w=(46===c?a+t.slice(r+1):t.slice(r))+w,t=t.slice(0,r);break}}b&&!f&&(t=i(t,1/0));var T=h.length+t.length+w.length,S=T>1)+h+t+w+S.slice(T);break;default:t=S+h+t+w}return s(t)}return g=void 0===g?6:/[gprs]/.test(v)?Math.max(1,Math.min(21,g)):Math.max(0,Math.min(20,g)),w.toString=function(){return t+""},w}return{format:d,formatPrefix:function(t,e){var n=d(((t=Bt(t)).type="f",t)),i=3*Math.max(-8,Math.min(8,Math.floor(Wt(e)/3))),r=Math.pow(10,-i),o=Xt[8+i/3];return function(t){return n(r*t)+o}}}}({thousands:",",grouping:[3],currency:["$",""]}),$t=qt.format,Qt=qt.formatPrefix;var ee,ne=n("kZht"),ie=((ee=function(){function t(){C(this,t),this.value=0,this.min=1,this.max=100,this.ARC_START_ANGLE=-Math.PI/2,this.ARC_END_ANGLE=Math.PI/2,this.ARC_INNER_RADIUS=.75,this.ARC_OUTER_RADIUS=1,this.ARC_CORNER_RADIUS=1,this.arc={innerRadius:this.ARC_INNER_RADIUS,outerRadius:this.ARC_OUTER_RADIUS,startAngle:this.ARC_START_ANGLE,endAngle:this.ARC_END_ANGLE,cornerRadius:this.ARC_CORNER_RADIUS},this.arcFn=function(){var t=k,e=T,n=u(0),i=null,r=S,o=E,a=x,s=null;function f(){var u,f,k=+t.apply(this,arguments),w=+e.apply(this,arguments),C=r.apply(this,arguments)-v,T=o.apply(this,arguments)-v,S=l(T-C),E=T>C;if(s||(s=u=c()),w1e-12)if(S>y-1e-12)s.moveTo(w*h(C),w*b(C)),s.arc(0,0,w,C,T,!E),k>1e-12&&(s.moveTo(k*h(T),k*b(T)),s.arc(0,0,k,T,C,E));else{var x,I,M=C,D=T,R=C,j=T,L=S,N=S,U=a.apply(this,arguments)/2,F=U>1e-12&&(i?+i.apply(this,arguments):g(k*k+w*w)),B=p(l(w-k)/2,+n.apply(this,arguments)),z=B,V=B;if(F>1e-12){var H=O(F/k*b(U)),q=O(F/w*b(U));(L-=2*H)>1e-12?(R+=H*=E?1:-1,j-=H):(L=0,R=j=(C+T)/2),(N-=2*q)>1e-12?(M+=q*=E?1:-1,D-=q):(N=0,M=D=(C+T)/2)}var $=w*h(M),Q=w*b(M),W=k*h(j),G=k*b(j);if(B>1e-12){var Y,K=w*h(D),Z=w*b(D),X=k*h(R),J=k*b(R);if(S1e-12?V>1e-12?(x=A(X,J,$,Q,w,V,E),I=A(K,Z,W,G,w,V,E),s.moveTo(x.cx+x.x01,x.cy+x.y01),V1e-12&&L>1e-12?z>1e-12?(x=A(W,G,K,Z,k,-z,E),I=A($,Q,X,J,k,-z,E),s.lineTo(x.cx+x.x01,x.cy+x.y01),z1&&void 0!==arguments[1]?arguments[1]:10;return[Math.cos(t-Math.PI/2)*e,Math.sin(t-Math.PI/2)*e]}}return w(t,[{key:"angleScale",get:function(){return te().domain([0,1]).range([-Math.PI/2,Math.PI/2]).clamp(!0)}},{key:"angle",get:function(){return this.angleScale(this.percent)}},{key:"percentScale",get:function(){return te().domain([this.min,this.max]).range([0,1])}},{key:"percent",get:function(){return this.percentScale(this.value)}},{key:"pointerAngleTransform",get:function(){return"rotate(".concat(this.angle*(180/Math.PI),") translate(-0.15, -1.25)")}},{key:"viewBox",get:function(){return[-1,-1,2,1].join(" ")}},{key:"backgroundArc",get:function(){return this.arcFn(this.arc)}}]),t}()).\u0275fac=function(t){return new(t||ee)},ee.\u0275cmp=ne.Ib({type:ee,selectors:[["gauge"]],inputs:{value:"value",min:"min",max:"max"},decls:10,vars:13,consts:[["id","testGradient"]],template:function(t,e){1&t&&(ne.ec(),ne.Ub(0,"svg"),ne.Ub(1,"defs"),ne.Ub(2,"linearGradient",0),ne.Pb(3,"stop"),ne.Pb(4,"stop"),ne.Pb(5,"stop"),ne.Tb(),ne.Tb(),ne.Pb(6,"path"),ne.Ub(7,"g"),ne.Pb(8,"path"),ne.Pb(9,"path"),ne.Tb(),ne.Tb()),2&t&&(ne.Db("viewBox",e.viewBox),ne.Cb(3),ne.Db("offset","0%")("stop-color","#6ec877"),ne.Cb(1),ne.Db("offset","50%")("stop-color","#d1a91c"),ne.Cb(1),ne.Db("offset","100%")("stop-color","#e2444d"),ne.Cb(1),ne.Db("d",e.backgroundArc)("fill","url(#testGradient)"),ne.Cb(1),ne.Db("transform",e.pointerAngleTransform)("fill","var(--text-colour)"),ne.Cb(1),ne.Db("d","M0.143123 0.3125L0.180213 1.2491C0.180213 1.2491 0.216505 1.2491 0.111797 1.2491C0.114232 1.17814 0.143123 0.3125 0.143123 0.3125Z"),ne.Cb(1),ne.Db("d","M0.234222 1.24911C0.234222 1.29574 0.196082 1.33354 0.149033 1.33354C0.101984 1.33354 0.0638428 1.29574 0.0638428 1.24911C0.0638428 1.20247 0.101984 1.16467 0.149033 1.16467C0.196082 1.16467 0.234222 1.20247 0.234222 1.24911Z"))},styles:["[_nghost-%COMP%], svg[_ngcontent-%COMP%]{width:100%}svg[_ngcontent-%COMP%]{overflow:visible}"],changeDetection:0}),ee)},"I1e+":function(t,e,n){"use strict";n.r(e),n.d(e,"RecertifyAlgoComponent",(function(){return v}));var i=n("3kIJ"),r=n("mcff"),o=n("0tVE"),a=n("kZht"),s=n("zqNl"),c=n("rfPA"),u=n("bBQR"),l=n("anSm"),d=n("1etq"),h=n("An66"),f=n("aDqW"),p=n("UDV5"),b=n("hCLc"),g=n("1o0v");function m(t,e){if(1&t&&(a.Ub(0,"p",13),a.Qc(1),a.Tb()),2&t){var n=a.fc();a.Cb(1),a.Rc(n.inputs.algo.label)}}var v=function(){var t=function(){function t(e,n,i){C(this,t),this.inputs=e,this.store=n,this.formBuilder=i,this.form=this.buildForm}return w(t,[{key:"submitForm",value:function(){var t=this;this.store.dispatch(Object(o.L)({id:this.inputs.algo.algoId})),this.form.reset(),Object.keys(this.form.controls).forEach((function(e){return t.form.get(e).setErrors(null)}))}},{key:"buildForm",get:function(){return this.formBuilder.group({conformanceTested:[!1,[i.x.requiredTrue]],pretradeRisk:[!1,[i.x.requiredTrue]],shutOff:[!1,[i.x.requiredTrue]],materialChange:[!1,[i.x.requiredTrue]]})}}]),t}();return t.\u0275fac=function(e){return new(e||t)(a.Ob(r.a),a.Ob(s.b),a.Ob(i.d))},t.\u0275cmp=a.Ib({type:t,selectors:[["recertify-algo"]],decls:25,vars:19,consts:[["heading","HEADING.RECERTIFY_ALGO"],["body","",3,"formGroup","ngSubmit"],[1,"algo"],["subheading",""],["subheading","","ghost","","body","",4,"ngIf"],[1,"terms"],["body","","translate",""],[1,"checkboxes"],["formControlName","conformanceTested","required","",1,"no-border"],["formControlName","pretradeRisk","required","",1,"no-border"],["formControlName","shutOff","required","",1,"no-border"],["formControlName","materialChange","required","",1,"no-border"],["mat-raised-button","","body","",3,"disabled"],["subheading","","ghost","","body",""]],template:function(t,e){1&t&&(a.Ub(0,"pro-dialog",0),a.Ub(1,"form",1),a.bc("ngSubmit",(function(){return e.submitForm()})),a.Ub(2,"div",2),a.Ub(3,"p",3),a.Qc(4),a.Tb(),a.Oc(5,m,2,1,"p",4),a.Tb(),a.Ub(6,"section",5),a.Ub(7,"p",6),a.Qc(8,"ALGOIDS.SELF_CERTIFICATION"),a.Tb(),a.Ub(9,"section",7),a.Ub(10,"mat-checkbox",8),a.Qc(11),a.gc(12,"translate"),a.Tb(),a.Ub(13,"mat-checkbox",9),a.Qc(14),a.gc(15,"translate"),a.Tb(),a.Ub(16,"mat-checkbox",10),a.Qc(17),a.gc(18,"translate"),a.Tb(),a.Ub(19,"mat-checkbox",11),a.Qc(20),a.gc(21,"translate"),a.Tb(),a.Tb(),a.Tb(),a.Ub(22,"button",12),a.Qc(23),a.gc(24,"translate"),a.Tb(),a.Tb(),a.Tb()),2&t&&(a.Cb(1),a.mc("formGroup",e.form),a.Cb(3),a.Rc(e.inputs.algo.algoId),a.Cb(1),a.mc("ngIf",e.inputs.algo.label),a.Cb(6),a.Sc(" ",a.hc(12,9,"ALGOIDS.CONFORMANCE_TESTED")," "),a.Cb(3),a.Sc(" ",a.hc(15,11,"ALGOIDS.PRETRADE_RISK")," "),a.Cb(3),a.Sc(" ",a.hc(18,13,"ALGOIDS.SHUT_OFF")," "),a.Cb(3),a.Sc(" ",a.hc(21,15,"ALGOIDS.MATERIAL_CHANGE")," "),a.Cb(2),a.mc("disabled",e.form.invalid),a.Cb(1),a.Sc(" ",a.hc(24,17,"BUTTON.RECERTIFY_ALGO")," "))},directives:[c.a,u.a,i.z,i.p,l.a,i.h,d.a,h.n,f.a,p.a,p.c,i.o,i.g,i.v,b.b,g.a],pipes:[f.d],styles:[".terms[_ngcontent-%COMP%]{margin:var(--spacing) 0}.terms[_ngcontent-%COMP%] .checkboxes[_ngcontent-%COMP%]{margin:var(--spacing) 0 var(--spacing) var(--spacing)}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;width:500px}@media (max-width:1024px){form[_ngcontent-%COMP%]{width:100%}}h2[_ngcontent-%COMP%]{margin-bottom:var(--spacing)}.algo[_ngcontent-%COMP%]{background:var(--border-colour);padding:var(--spacing);border-radius:var(--bdrs);align-self:center;margin-bottom:var(--spacing-l)}"],changeDetection:0}),t}()},I2Ru:function(t,e,n){"use strict";n.d(e,"a",(function(){return u}));var i=n("YtkY"),r=n("i67J"),o=n("rxqU"),a=n("kZht"),s=n("1VvW"),c=n("zqNl"),u=function(){var t=function(){function t(e,n){C(this,t),this.router=e,this.store=n,this.userDetails$=this.store.pipe(Object(r.n)(o.d))}return w(t,[{key:"canActivate",value:function(t,e){var n=this;return this.userDetails$.pipe(Object(i.a)((function(e){return e.platformName===t.data.platform||(n.router.navigate(["/futures"]),!1)})))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(a.Yb(s.d),a.Yb(c.b))},t.\u0275prov=a.Kb({token:t,factory:t.\u0275fac}),t}()},IJgj:function(t,e,n){"use strict";function i(t){return"function"==typeof t}n.d(e,"a",(function(){return i}))},IOEv:function(t,e,n){"use strict";n.d(e,"a",(function(){return Y})),n.d(e,"b",(function(){return K}));var i=n("5GZx"),r=n("An66"),o=n("kZht"),s=n("pTnX"),u=n("EmXI"),d=n("VbQ3"),h=n("jL3B"),f=n("vE5V"),p=n("5XID"),g=n("sBeF"),m=n("Hq54"),v=n("3kIJ"),y=n("ZTXN"),_=n("i9xl"),O=n("g6G6"),k=n("jIqt"),T=n("TLy2"),S=n("J+dc"),E=n("xVbo"),x=n("YtkY"),P=n("Ohay"),A=n("kuMc"),I=n("+6xv"),M=["trigger"],D=["panel"];function R(t,e){if(1&t&&(o.Ub(0,"span",8),o.Qc(1),o.Tb()),2&t){var n=o.fc();o.Cb(1),o.Rc(n.placeholder||"\xa0")}}function j(t,e){if(1&t&&(o.Ub(0,"span"),o.Qc(1),o.Tb()),2&t){var n=o.fc(2);o.Cb(1),o.Rc(n.triggerValue||"\xa0")}}function L(t,e){1&t&&o.kc(0,0,["*ngSwitchCase","true"])}function N(t,e){if(1&t&&(o.Ub(0,"span",9),o.Oc(1,j,2,1,"span",10),o.Oc(2,L,1,0,"ng-content",11),o.Tb()),2&t){var n=o.fc();o.mc("ngSwitch",!!n.customTrigger),o.Cb(2),o.mc("ngSwitchCase",!0)}}function U(t,e){if(1&t){var n=o.Vb();o.Ub(0,"div",12),o.Ub(1,"div",13,14),o.bc("@transformPanel.done",(function(t){return o.Ec(n),o.fc()._panelDoneAnimatingStream.next(t.toState)}))("keydown",(function(t){return o.Ec(n),o.fc()._handleKeydown(t)})),o.kc(3,1),o.Tb(),o.Tb()}if(2&t){var i=o.fc();o.mc("@transformPanelWrap",void 0),o.Cb(1),o.Fb("mat-select-panel ",i._getPanelTheme(),""),o.Lc("transform-origin",i._transformOrigin)("font-size",i._triggerFontSize,"px"),o.mc("ngClass",i.panelClass)("@transformPanel",i.multiple?"showing-multiple":"showing"),o.Db("id",i.id+"-panel")("aria-multiselectable",i.multiple)("aria-label",i.ariaLabel||null)("aria-labelledby",i._getPanelAriaLabelledby())}}var F=[[["mat-select-trigger"]],"*"],B=["mat-select-trigger","*"],z={transformPanelWrap:Object(I.n)("transformPanelWrap",[Object(I.m)("* => void",Object(I.i)("@transformPanel",[Object(I.f)()],{optional:!0}))]),transformPanel:Object(I.n)("transformPanel",[Object(I.k)("void",Object(I.l)({transform:"scaleY(0.8)",minWidth:"100%",opacity:0})),Object(I.k)("showing",Object(I.l)({opacity:1,minWidth:"calc(100% + 32px)",transform:"scaleY(1)"})),Object(I.k)("showing-multiple",Object(I.l)({opacity:1,minWidth:"calc(100% + 64px)",transform:"scaleY(1)"})),Object(I.m)("void => *",Object(I.e)("120ms cubic-bezier(0, 0, 0.2, 1)")),Object(I.m)("* => void",Object(I.e)("100ms 25ms linear",Object(I.l)({opacity:0})))])},V=0,H=new o.s("mat-select-scroll-strategy"),q=new o.s("MAT_SELECT_CONFIG"),$={provide:H,deps:[i.c],useFactory:function(t){return function(){return t.scrollStrategies.reposition()}}},Q=function t(e,n){C(this,t),this.source=e,this.value=n},W=Object(s.x)(Object(s.B)(Object(s.y)(Object(s.z)((function t(e,n,i,r,o){C(this,t),this._elementRef=e,this._defaultErrorStateMatcher=n,this._parentForm=i,this._parentFormGroup=r,this.ngControl=o}))))),G=new o.s("MatSelectTrigger"),Y=function(){var t=function(t){a(n,t);var e=c(n);function n(t,i,r,a,s,c,u,d,h,f,p,g,m,v){var w;return C(this,n),(w=e.call(this,s,a,u,d,f))._viewportRuler=t,w._changeDetectorRef=i,w._ngZone=r,w._dir=c,w._parentFormField=h,w.ngControl=f,w._liveAnnouncer=m,w._panelOpen=!1,w._required=!1,w._scrollTop=0,w._multiple=!1,w._compareWith=function(t,e){return t===e},w._uid="mat-select-"+V++,w._triggerAriaLabelledBy=null,w._destroy=new y.b,w._triggerFontSize=0,w._onChange=function(){},w._onTouched=function(){},w._valueId="mat-select-value-"+V++,w._transformOrigin="top",w._panelDoneAnimatingStream=new y.b,w._offsetY=0,w._positions=[{originX:"start",originY:"top",overlayX:"start",overlayY:"top"},{originX:"start",originY:"bottom",overlayX:"start",overlayY:"bottom"}],w._disableOptionCentering=!1,w._focused=!1,w.controlType="mat-select",w.ariaLabel="",w.optionSelectionChanges=Object(_.a)((function(){var t=w.options;return t?t.changes.pipe(Object(k.a)(t),Object(T.a)((function(){return Object(O.a).apply(void 0,b(t.map((function(t){return t.onSelectionChange}))))}))):w._ngZone.onStable.pipe(Object(S.a)(1),Object(T.a)((function(){return w.optionSelectionChanges})))})),w.openedChange=new o.o,w._openedStream=w.openedChange.pipe(Object(E.a)((function(t){return t})),Object(x.a)((function(){}))),w._closedStream=w.openedChange.pipe(Object(E.a)((function(t){return!t})),Object(x.a)((function(){}))),w.selectionChange=new o.o,w.valueChange=new o.o,w.ngControl&&(w.ngControl.valueAccessor=l(w)),w._scrollStrategyFactory=g,w._scrollStrategy=w._scrollStrategyFactory(),w.tabIndex=parseInt(p)||0,w.id=w.id,v&&(null!=v.disableOptionCentering&&(w.disableOptionCentering=v.disableOptionCentering),null!=v.typeaheadDebounceInterval&&(w.typeaheadDebounceInterval=v.typeaheadDebounceInterval)),w}return w(n,[{key:"ngOnInit",value:function(){var t=this;this._selectionModel=new g.c(this.multiple),this.stateChanges.next(),this._panelDoneAnimatingStream.pipe(Object(P.a)(),Object(A.a)(this._destroy)).subscribe((function(){t.panelOpen?(t._scrollTop=0,t.openedChange.emit(!0)):(t.openedChange.emit(!1),t.overlayDir.offsetX=0,t._changeDetectorRef.markForCheck())})),this._viewportRuler.change().pipe(Object(A.a)(this._destroy)).subscribe((function(){t._panelOpen&&(t._triggerRect=t.trigger.nativeElement.getBoundingClientRect(),t._changeDetectorRef.markForCheck())}))}},{key:"ngAfterContentInit",value:function(){var t=this;this._initKeyManager(),this._selectionModel.changed.pipe(Object(A.a)(this._destroy)).subscribe((function(t){t.added.forEach((function(t){return t.select()})),t.removed.forEach((function(t){return t.deselect()}))})),this.options.changes.pipe(Object(k.a)(null),Object(A.a)(this._destroy)).subscribe((function(){t._resetOptions(),t._initializeSelection()}))}},{key:"ngDoCheck",value:function(){var t=this._getTriggerAriaLabelledby();if(t!==this._triggerAriaLabelledBy){var e=this._elementRef.nativeElement;this._triggerAriaLabelledBy=t,t?e.setAttribute("aria-labelledby",t):e.removeAttribute("aria-labelledby")}this.ngControl&&this.updateErrorState()}},{key:"ngOnChanges",value:function(t){t.disabled&&this.stateChanges.next(),t.typeaheadDebounceInterval&&this._keyManager&&this._keyManager.withTypeAhead(this._typeaheadDebounceInterval)}},{key:"ngOnDestroy",value:function(){this._destroy.next(),this._destroy.complete(),this.stateChanges.complete()}},{key:"toggle",value:function(){this.panelOpen?this.close():this.open()}},{key:"open",value:function(){var t=this;!this.disabled&&this.options&&this.options.length&&!this._panelOpen&&(this._triggerRect=this.trigger.nativeElement.getBoundingClientRect(),this._triggerFontSize=parseInt(getComputedStyle(this.trigger.nativeElement).fontSize||"0"),this._panelOpen=!0,this._keyManager.withHorizontalOrientation(null),this._calculateOverlayPosition(),this._highlightCorrectOption(),this._changeDetectorRef.markForCheck(),this._ngZone.onStable.pipe(Object(S.a)(1)).subscribe((function(){t._triggerFontSize&&t.overlayDir.overlayRef&&t.overlayDir.overlayRef.overlayElement&&(t.overlayDir.overlayRef.overlayElement.style.fontSize=t._triggerFontSize+"px")})))}},{key:"close",value:function(){this._panelOpen&&(this._panelOpen=!1,this._keyManager.withHorizontalOrientation(this._isRtl()?"rtl":"ltr"),this._changeDetectorRef.markForCheck(),this._onTouched())}},{key:"writeValue",value:function(t){this.value=t}},{key:"registerOnChange",value:function(t){this._onChange=t}},{key:"registerOnTouched",value:function(t){this._onTouched=t}},{key:"setDisabledState",value:function(t){this.disabled=t,this._changeDetectorRef.markForCheck(),this.stateChanges.next()}},{key:"_isRtl",value:function(){return!!this._dir&&"rtl"===this._dir.value}},{key:"_handleKeydown",value:function(t){this.disabled||(this.panelOpen?this._handleOpenKeydown(t):this._handleClosedKeydown(t))}},{key:"_handleClosedKeydown",value:function(t){var e=t.keyCode,n=e===m.c||e===m.o||e===m.h||e===m.l,i=e===m.e||e===m.m,r=this._keyManager;if(!r.isTyping()&&i&&!Object(m.r)(t)||(this.multiple||t.altKey)&&n)t.preventDefault(),this.open();else if(!this.multiple){var o=this.selected;r.onKeydown(t);var a=this.selected;a&&o!==a&&this._liveAnnouncer.announce(a.viewValue,1e4)}}},{key:"_handleOpenKeydown",value:function(t){var e=this._keyManager,n=t.keyCode,i=n===m.c||n===m.o,r=e.isTyping();if(i&&t.altKey)t.preventDefault(),this.close();else if(r||n!==m.e&&n!==m.m||!e.activeItem||Object(m.r)(t))if(!r&&this._multiple&&n===m.a&&t.ctrlKey){t.preventDefault();var o=this.options.some((function(t){return!t.disabled&&!t.selected}));this.options.forEach((function(t){t.disabled||(o?t.select():t.deselect())}))}else{var a=e.activeItemIndex;e.onKeydown(t),this._multiple&&i&&t.shiftKey&&e.activeItem&&e.activeItemIndex!==a&&e.activeItem._selectViaInteraction()}else t.preventDefault(),e.activeItem._selectViaInteraction()}},{key:"_onFocus",value:function(){this.disabled||(this._focused=!0,this.stateChanges.next())}},{key:"_onBlur",value:function(){this._focused=!1,this.disabled||this.panelOpen||(this._onTouched(),this._changeDetectorRef.markForCheck(),this.stateChanges.next())}},{key:"_onAttached",value:function(){var t=this;this.overlayDir.positionChange.pipe(Object(S.a)(1)).subscribe((function(){t._changeDetectorRef.detectChanges(),t._calculateOverlayOffsetX(),t.panel.nativeElement.scrollTop=t._scrollTop}))}},{key:"_getPanelTheme",value:function(){return this._parentFormField?"mat-"+this._parentFormField.color:""}},{key:"_initializeSelection",value:function(){var t=this;Promise.resolve().then((function(){t._setSelectionByValue(t.ngControl?t.ngControl.value:t._value),t.stateChanges.next()}))}},{key:"_setSelectionByValue",value:function(t){var e=this;if(this.multiple&&t)Array.isArray(t),this._selectionModel.clear(),t.forEach((function(t){return e._selectValue(t)})),this._sortValues();else{this._selectionModel.clear();var n=this._selectValue(t);n?this._keyManager.updateActiveItem(n):this.panelOpen||this._keyManager.updateActiveItem(-1)}this._changeDetectorRef.markForCheck()}},{key:"_selectValue",value:function(t){var e=this,n=this.options.find((function(n){try{return null!=n.value&&e._compareWith(n.value,t)}catch(i){return!1}}));return n&&this._selectionModel.select(n),n}},{key:"_initKeyManager",value:function(){var t=this;this._keyManager=new h.b(this.options).withTypeAhead(this._typeaheadDebounceInterval).withVerticalOrientation().withHorizontalOrientation(this._isRtl()?"rtl":"ltr").withHomeAndEnd().withAllowedModifierKeys(["shiftKey"]),this._keyManager.tabOut.pipe(Object(A.a)(this._destroy)).subscribe((function(){t.panelOpen&&(!t.multiple&&t._keyManager.activeItem&&t._keyManager.activeItem._selectViaInteraction(),t.focus(),t.close())})),this._keyManager.change.pipe(Object(A.a)(this._destroy)).subscribe((function(){t._panelOpen&&t.panel?t._scrollActiveOptionIntoView():t._panelOpen||t.multiple||!t._keyManager.activeItem||t._keyManager.activeItem._selectViaInteraction()}))}},{key:"_resetOptions",value:function(){var t=this,e=Object(O.a)(this.options.changes,this._destroy);this.optionSelectionChanges.pipe(Object(A.a)(e)).subscribe((function(e){t._onSelect(e.source,e.isUserInput),e.isUserInput&&!t.multiple&&t._panelOpen&&(t.close(),t.focus())})),Object(O.a).apply(void 0,b(this.options.map((function(t){return t._stateChanges})))).pipe(Object(A.a)(e)).subscribe((function(){t._changeDetectorRef.markForCheck(),t.stateChanges.next()}))}},{key:"_onSelect",value:function(t,e){var n=this._selectionModel.isSelected(t);null!=t.value||this._multiple?(n!==t.selected&&(t.selected?this._selectionModel.select(t):this._selectionModel.deselect(t)),e&&this._keyManager.setActiveItem(t),this.multiple&&(this._sortValues(),e&&this.focus())):(t.deselect(),this._selectionModel.clear(),null!=this.value&&this._propagateChanges(t.value)),n!==this._selectionModel.isSelected(t)&&this._propagateChanges(),this.stateChanges.next()}},{key:"_sortValues",value:function(){var t=this;if(this.multiple){var e=this.options.toArray();this._selectionModel.sort((function(n,i){return t.sortComparator?t.sortComparator(n,i,e):e.indexOf(n)-e.indexOf(i)})),this.stateChanges.next()}}},{key:"_propagateChanges",value:function(t){var e;e=this.multiple?this.selected.map((function(t){return t.value})):this.selected?this.selected.value:t,this._value=e,this.valueChange.emit(e),this._onChange(e),this.selectionChange.emit(new Q(this,e)),this._changeDetectorRef.markForCheck()}},{key:"_highlightCorrectOption",value:function(){this._keyManager&&(this.empty?this._keyManager.setFirstItemActive():this._keyManager.setActiveItem(this._selectionModel.selected[0]))}},{key:"_scrollActiveOptionIntoView",value:function(){var t=this._keyManager.activeItemIndex||0,e=Object(s.u)(t,this.options,this.optionGroups),n=this._getItemHeight();this.panel.nativeElement.scrollTop=Object(s.v)((t+e)*n,n,this.panel.nativeElement.scrollTop,256)}},{key:"focus",value:function(t){this._elementRef.nativeElement.focus(t)}},{key:"_getOptionIndex",value:function(t){return this.options.reduce((function(e,n,i){return void 0!==e?e:t===n?i:void 0}),void 0)}},{key:"_calculateOverlayPosition",value:function(){var t=this._getItemHeight(),e=this._getItemCount(),n=Math.min(e*t,256),i=e*t-n,r=this.empty?0:this._getOptionIndex(this._selectionModel.selected[0]);r+=Object(s.u)(r,this.options,this.optionGroups);var o=n/2;this._scrollTop=this._calculateOverlayScroll(r,o,i),this._offsetY=this._calculateOverlayOffsetY(r,o,i),this._checkOverlayWithinViewport(i)}},{key:"_calculateOverlayScroll",value:function(t,e,n){var i=this._getItemHeight();return Math.min(Math.max(0,i*t-e+i/2),n)}},{key:"_getPanelAriaLabelledby",value:function(){if(this.ariaLabel)return null;var t=this._getLabelId();return this.ariaLabelledby?t+" "+this.ariaLabelledby:t}},{key:"_getAriaActiveDescendant",value:function(){return this.panelOpen&&this._keyManager&&this._keyManager.activeItem?this._keyManager.activeItem.id:null}},{key:"_getLabelId",value:function(){var t;return(null===(t=this._parentFormField)||void 0===t?void 0:t.getLabelId())||""}},{key:"_calculateOverlayOffsetX",value:function(){var t,e=this.overlayDir.overlayRef.overlayElement.getBoundingClientRect(),n=this._viewportRuler.getViewportSize(),i=this._isRtl(),r=this.multiple?56:32;if(this.multiple)t=40;else{var o=this._selectionModel.selected[0]||this.options.first;t=o&&o.group?32:16}i||(t*=-1);var a=0-(e.left+t-(i?r:0)),s=e.right+t-n.width+(i?0:r);a>0?t+=a+8:s>0&&(t-=s+8),this.overlayDir.offsetX=Math.round(t),this.overlayDir.overlayRef.updatePosition()}},{key:"_calculateOverlayOffsetY",value:function(t,e,n){var i,r=this._getItemHeight(),o=(r-this._triggerRect.height)/2,a=Math.floor(256/r);return this._disableOptionCentering?0:(i=0===this._scrollTop?t*r:this._scrollTop===n?(t-(this._getItemCount()-a))*r+(r-(this._getItemCount()*r-256)%r):e-r/2,Math.round(-1*i-o))}},{key:"_checkOverlayWithinViewport",value:function(t){var e=this._getItemHeight(),n=this._viewportRuler.getViewportSize(),i=this._triggerRect.top-8,r=n.height-this._triggerRect.bottom-8,o=Math.abs(this._offsetY),a=Math.min(this._getItemCount()*e,256)-o-this._triggerRect.height;a>r?this._adjustPanelUp(a,r):o>i?this._adjustPanelDown(o,i,t):this._transformOrigin=this._getOriginBasedOnOption()}},{key:"_adjustPanelUp",value:function(t,e){var n=Math.round(t-e);this._scrollTop-=n,this._offsetY-=n,this._transformOrigin=this._getOriginBasedOnOption(),this._scrollTop<=0&&(this._scrollTop=0,this._offsetY=0,this._transformOrigin="50% bottom 0px")}},{key:"_adjustPanelDown",value:function(t,e,n){var i=Math.round(t-e);if(this._scrollTop+=i,this._offsetY+=i,this._transformOrigin=this._getOriginBasedOnOption(),this._scrollTop>=n)return this._scrollTop=n,this._offsetY=0,void(this._transformOrigin="50% top 0px")}},{key:"_getOriginBasedOnOption",value:function(){var t=this._getItemHeight(),e=(t-this._triggerRect.height)/2;return"50% ".concat(Math.abs(this._offsetY)-e+t/2,"px 0px")}},{key:"_getItemCount",value:function(){return this.options.length+this.optionGroups.length}},{key:"_getItemHeight",value:function(){return 3*this._triggerFontSize}},{key:"_getTriggerAriaLabelledby",value:function(){if(this.ariaLabel)return null;var t=this._getLabelId()+" "+this._valueId;return this.ariaLabelledby&&(t+=" "+this.ariaLabelledby),t}},{key:"setDescribedByIds",value:function(t){this._ariaDescribedby=t.join(" ")}},{key:"onContainerClick",value:function(){this.focus(),this.open()}},{key:"focused",get:function(){return this._focused||this._panelOpen}},{key:"placeholder",get:function(){return this._placeholder},set:function(t){this._placeholder=t,this.stateChanges.next()}},{key:"required",get:function(){return this._required},set:function(t){this._required=Object(p.c)(t),this.stateChanges.next()}},{key:"multiple",get:function(){return this._multiple},set:function(t){this._multiple=Object(p.c)(t)}},{key:"disableOptionCentering",get:function(){return this._disableOptionCentering},set:function(t){this._disableOptionCentering=Object(p.c)(t)}},{key:"compareWith",get:function(){return this._compareWith},set:function(t){this._compareWith=t,this._selectionModel&&this._initializeSelection()}},{key:"value",get:function(){return this._value},set:function(t){t!==this._value&&(this.options&&this._setSelectionByValue(t),this._value=t)}},{key:"typeaheadDebounceInterval",get:function(){return this._typeaheadDebounceInterval},set:function(t){this._typeaheadDebounceInterval=Object(p.f)(t)}},{key:"id",get:function(){return this._id},set:function(t){this._id=t||this._uid,this.stateChanges.next()}},{key:"panelOpen",get:function(){return this._panelOpen}},{key:"selected",get:function(){return this.multiple?this._selectionModel.selected:this._selectionModel.selected[0]}},{key:"triggerValue",get:function(){if(this.empty)return"";if(this._multiple){var t=this._selectionModel.selected.map((function(t){return t.viewValue}));return this._isRtl()&&t.reverse(),t.join(", ")}return this._selectionModel.selected[0].viewValue}},{key:"empty",get:function(){return!this._selectionModel||this._selectionModel.isEmpty()}},{key:"shouldLabelFloat",get:function(){return this._panelOpen||!this.empty}}]),n}(W);return t.\u0275fac=function(e){return new(e||t)(o.Ob(d.h),o.Ob(o.h),o.Ob(o.B),o.Ob(s.d),o.Ob(o.l),o.Ob(f.b,8),o.Ob(v.q,8),o.Ob(v.h,8),o.Ob(u.a,8),o.Ob(v.n,10),o.Zb("tabindex"),o.Ob(H),o.Ob(h.k),o.Ob(q,8))},t.\u0275cmp=o.Ib({type:t,selectors:[["mat-select"]],contentQueries:function(t,e,n){var i;1&t&&(o.Hb(n,G,!0),o.Hb(n,s.n,!0),o.Hb(n,s.g,!0)),2&t&&(o.zc(i=o.cc())&&(e.customTrigger=i.first),o.zc(i=o.cc())&&(e.options=i),o.zc(i=o.cc())&&(e.optionGroups=i))},viewQuery:function(t,e){var n;1&t&&(o.Wc(M,!0),o.Wc(D,!0),o.Wc(i.a,!0)),2&t&&(o.zc(n=o.cc())&&(e.trigger=n.first),o.zc(n=o.cc())&&(e.panel=n.first),o.zc(n=o.cc())&&(e.overlayDir=n.first))},hostAttrs:["role","combobox","aria-autocomplete","none","aria-haspopup","true",1,"mat-select"],hostVars:20,hostBindings:function(t,e){1&t&&o.bc("keydown",(function(t){return e._handleKeydown(t)}))("focus",(function(){return e._onFocus()}))("blur",(function(){return e._onBlur()})),2&t&&(o.Db("id",e.id)("tabindex",e.tabIndex)("aria-controls",e.panelOpen?e.id+"-panel":null)("aria-expanded",e.panelOpen)("aria-label",e.ariaLabel||null)("aria-required",e.required.toString())("aria-disabled",e.disabled.toString())("aria-invalid",e.errorState)("aria-describedby",e._ariaDescribedby||null)("aria-activedescendant",e._getAriaActiveDescendant()),o.Gb("mat-select-disabled",e.disabled)("mat-select-invalid",e.errorState)("mat-select-required",e.required)("mat-select-empty",e.empty)("mat-select-multiple",e.multiple))},inputs:{disabled:"disabled",disableRipple:"disableRipple",tabIndex:"tabIndex",ariaLabel:["aria-label","ariaLabel"],id:"id",disableOptionCentering:"disableOptionCentering",typeaheadDebounceInterval:"typeaheadDebounceInterval",placeholder:"placeholder",required:"required",multiple:"multiple",compareWith:"compareWith",value:"value",panelClass:"panelClass",ariaLabelledby:["aria-labelledby","ariaLabelledby"],errorStateMatcher:"errorStateMatcher",sortComparator:"sortComparator"},outputs:{openedChange:"openedChange",_openedStream:"opened",_closedStream:"closed",selectionChange:"selectionChange",valueChange:"valueChange"},exportAs:["matSelect"],features:[o.Bb([{provide:u.d,useExisting:t},{provide:s.h,useExisting:t}]),o.zb,o.Ab],ngContentSelectors:B,decls:9,vars:10,consts:[["cdk-overlay-origin","",1,"mat-select-trigger",3,"click"],["origin","cdkOverlayOrigin","trigger",""],[1,"mat-select-value",3,"ngSwitch"],["class","mat-select-placeholder",4,"ngSwitchCase"],["class","mat-select-value-text",3,"ngSwitch",4,"ngSwitchCase"],[1,"mat-select-arrow-wrapper"],[1,"mat-select-arrow"],["cdk-connected-overlay","","cdkConnectedOverlayLockPosition","","cdkConnectedOverlayHasBackdrop","","cdkConnectedOverlayBackdropClass","cdk-overlay-transparent-backdrop",3,"cdkConnectedOverlayScrollStrategy","cdkConnectedOverlayOrigin","cdkConnectedOverlayOpen","cdkConnectedOverlayPositions","cdkConnectedOverlayMinWidth","cdkConnectedOverlayOffsetY","backdropClick","attach","detach"],[1,"mat-select-placeholder"],[1,"mat-select-value-text",3,"ngSwitch"],[4,"ngSwitchDefault"],[4,"ngSwitchCase"],[1,"mat-select-panel-wrap"],["role","listbox","tabindex","-1",3,"ngClass","keydown"],["panel",""]],template:function(t,e){if(1&t&&(o.lc(F),o.Ub(0,"div",0,1),o.bc("click",(function(){return e.toggle()})),o.Ub(3,"div",2),o.Oc(4,R,2,1,"span",3),o.Oc(5,N,3,2,"span",4),o.Tb(),o.Ub(6,"div",5),o.Pb(7,"div",6),o.Tb(),o.Tb(),o.Oc(8,U,4,14,"ng-template",7),o.bc("backdropClick",(function(){return e.close()}))("attach",(function(){return e._onAttached()}))("detach",(function(){return e.close()}))),2&t){var n=o.Ac(1);o.Cb(3),o.mc("ngSwitch",e.empty),o.Db("id",e._valueId),o.Cb(1),o.mc("ngSwitchCase",!0),o.Cb(1),o.mc("ngSwitchCase",!1),o.Cb(3),o.mc("cdkConnectedOverlayScrollStrategy",e._scrollStrategy)("cdkConnectedOverlayOrigin",n)("cdkConnectedOverlayOpen",e.panelOpen)("cdkConnectedOverlayPositions",e._positions)("cdkConnectedOverlayMinWidth",null==e._triggerRect?null:e._triggerRect.width)("cdkConnectedOverlayOffsetY",e._offsetY)}},directives:[i.b,r.p,r.q,i.a,r.r,r.l],styles:[".mat-select{display:inline-block;width:100%;outline:none}.mat-select-trigger{display:inline-table;cursor:pointer;position:relative;box-sizing:border-box}.mat-select-disabled .mat-select-trigger{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:default}.mat-select-value{display:table-cell;max-width:0;width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.mat-select-value-text{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.mat-select-arrow-wrapper{display:table-cell;vertical-align:middle}.mat-form-field-appearance-fill .mat-select-arrow-wrapper{transform:translateY(-50%)}.mat-form-field-appearance-outline .mat-select-arrow-wrapper{transform:translateY(-25%)}.mat-form-field-appearance-standard.mat-form-field-has-label .mat-select:not(.mat-select-empty) .mat-select-arrow-wrapper{transform:translateY(-50%)}.mat-form-field-appearance-standard .mat-select.mat-select-empty .mat-select-arrow-wrapper{transition:transform 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}._mat-animation-noopable.mat-form-field-appearance-standard .mat-select.mat-select-empty .mat-select-arrow-wrapper{transition:none}.mat-select-arrow{width:0;height:0;border-left:5px solid transparent;border-right:5px solid transparent;border-top:5px solid;margin:0 4px}.mat-select-panel-wrap{flex-basis:100%}.mat-select-panel{min-width:112px;max-width:280px;overflow:auto;-webkit-overflow-scrolling:touch;padding-top:0;padding-bottom:0;max-height:256px;min-width:100%;border-radius:4px}.cdk-high-contrast-active .mat-select-panel{outline:solid 1px}.mat-select-panel .mat-optgroup-label,.mat-select-panel .mat-option{font-size:inherit;line-height:3em;height:3em}.mat-form-field-type-mat-select:not(.mat-form-field-disabled) .mat-form-field-flex{cursor:pointer}.mat-form-field-type-mat-select .mat-form-field-label{width:calc(100% - 18px)}.mat-select-placeholder{transition:color 400ms 133.3333333333ms cubic-bezier(0.25, 0.8, 0.25, 1)}._mat-animation-noopable .mat-select-placeholder{transition:none}.mat-form-field-hide-placeholder .mat-select-placeholder{color:transparent;-webkit-text-fill-color:transparent;transition:none;display:block}\n"],encapsulation:2,data:{animation:[z.transformPanelWrap,z.transformPanel]},changeDetection:0}),t}(),K=function(){var t=function t(){C(this,t)};return t.\u0275mod=o.Mb({type:t}),t.\u0275inj=o.Lb({factory:function(e){return new(e||t)},providers:[$],imports:[[r.c,i.f,s.o,s.j],d.c,u.e,s.o,s.j]}),t}()},IdLP:function(t,e,n){"use strict";n.d(e,"a",(function(){return l}));var i,r=n("5uGe"),o=n("25CY"),a=n("rWo0"),s=n("qEfY"),c=n("Ti3e"),u=n("HgnN"),l=((i=function(){function t(e){C(this,t),this._isScalar=!1,e&&(this._subscribe=e)}return w(t,[{key:"lift",value:function(e){var n=new t;return n.source=this,n.operator=e,n}},{key:"subscribe",value:function(t,e,n){var i=this.operator,s=function(t,e,n){if(t){if(t instanceof r.a)return t;if(t[o.a])return t[o.a]()}return t||e||n?new r.a(t,e,n):new r.a(a.a)}(t,e,n);if(s.add(i?i.call(s,this.source):this.source||u.a.useDeprecatedSynchronousErrorHandling&&!s.syncErrorThrowable?this._subscribe(s):this._trySubscribe(s)),u.a.useDeprecatedSynchronousErrorHandling&&s.syncErrorThrowable&&(s.syncErrorThrowable=!1,s.syncErrorThrown))throw s.syncErrorValue;return s}},{key:"_trySubscribe",value:function(t){try{return this._subscribe(t)}catch(e){u.a.useDeprecatedSynchronousErrorHandling&&(t.syncErrorThrown=!0,t.syncErrorValue=e),function(t){for(;t;){var e=t,n=e.closed,i=e.destination,o=e.isStopped;if(n||o)return!1;t=i&&i instanceof r.a?i:null}return!0}(t)?t.error(e):console.warn(e)}}},{key:"forEach",value:function(t,e){var n=this;return new(e=d(e))((function(e,i){var r;r=n.subscribe((function(e){try{t(e)}catch(n){i(n),r&&r.unsubscribe()}}),i,e)}))}},{key:"_subscribe",value:function(t){var e=this.source;return e&&e.subscribe(t)}},{key:s.a,value:function(){return this}},{key:"pipe",value:function(){for(var t=arguments.length,e=new Array(t),n=0;n>\n"),t.toString()},t.prototype.setMode=function(t){this.mode=t},t.prototype.setECLevel=function(t){this.ecLevel=t},t.prototype.setVersion=function(t){this.version=t},t.prototype.setMaskPattern=function(t){this.maskPattern=t},t.prototype.setMatrix=function(t){this.matrix=t},t.isValidMaskPattern=function(e){return e>=0&&e=t.contracts)if(e===n.length-1)a+=o*t.maintenanceMargin;else{var i=n[e+1].contracts-t.contracts;o=0:this.liquidationPrice>e}},{key:"displayLiquidation",get:function(){var t=this.form.get("entryPrice").value,e=this.form.get("quantity").value;return 0!==this.form.get("margin").value&&0!==t&&0!==e}},{key:"pairBase",get:function(){var t=this.form.get("pair").value;return Object(r.k)(t)}},{key:"pairQuote",get:function(){var t=this.form.get("pair").value;return Object(r.l)(t)}},{key:"unitBase",get:function(){return this.isInverse?this.pairBase:this.pairQuote}}]),t}()).\u0275fac=function(t){return new(t||k)(c.Ob(i.d))},k.\u0275cmp=c.Ib({type:k,selectors:[["liquidation-calculator"]],inputs:{classification:"classification",mid:"mid",markets:"markets",selectedMarket:"selectedMarket",wallets:"wallets"},features:[c.Ab],decls:63,vars:49,consts:[[1,"disclaimer","global__text","global__text-body"],[1,"form"],["body","",3,"formGroup"],["color","accent","appearance","fill"],["matNativeControl","","formControlName","pair"],[3,"value",4,"ngFor","ngForOf"],["matNativeControl","","formControlName","direction"],["value","long","translate",""],["value","short","translate",""],["type","number","formControlName","entryPrice","matInput","","min","0"],["type","number","formControlName","quantity","matInput","","min","0"],["type","number","formControlName","margin","matInput","","min","0"],["body","",1,"form-results"],[1,"form-result"],["mono",""],["class","form-result",4,"ngIf"],[3,"value"],["mono","",1,"global__text--warn"],[1,"global__text--accent"]],template:function(t,e){1&t&&(c.Ub(0,"p",0),c.Qc(1),c.gc(2,"translate"),c.Tb(),c.Ub(3,"p",0),c.Qc(4," These calculators apply to Single-collateral contracts only.\n"),c.Tb(),c.Ub(5,"section",1),c.Ub(6,"form",2),c.Ub(7,"mat-form-field",3),c.Ub(8,"mat-label"),c.Qc(9),c.gc(10,"translate"),c.Tb(),c.Ub(11,"mat-select",4),c.Oc(12,y,3,4,"mat-option",5),c.Tb(),c.Tb(),c.Ub(13,"mat-form-field",3),c.Ub(14,"mat-label"),c.Qc(15),c.gc(16,"translate"),c.Tb(),c.Ub(17,"mat-select",6),c.Ub(18,"mat-option",7),c.Qc(19,"BUTTON.LONG"),c.Tb(),c.Ub(20,"mat-option",8),c.Qc(21,"BUTTON.SHORT"),c.Tb(),c.Tb(),c.Tb(),c.Ub(22,"mat-form-field",3),c.Ub(23,"mat-label"),c.Qc(24),c.gc(25,"translate"),c.Tb(),c.Pb(26,"input",9),c.Tb(),c.Ub(27,"mat-form-field",3),c.Ub(28,"mat-label"),c.Qc(29),c.gc(30,"translate"),c.Tb(),c.Pb(31,"input",10),c.Tb(),c.Ub(32,"mat-form-field",3),c.Ub(33,"mat-label"),c.Qc(34),c.gc(35,"translate"),c.Tb(),c.Pb(36,"input",11),c.Tb(),c.Tb(),c.Ub(37,"section",12),c.Ub(38,"section",13),c.Ub(39,"p"),c.Qc(40),c.gc(41,"translate"),c.Tb(),c.Ub(42,"strong",14),c.Qc(43),c.gc(44,"cryptoPrecise"),c.gc(45,"cryptoAbbreviation"),c.Tb(),c.Tb(),c.Ub(46,"section",13),c.Ub(47,"p"),c.Qc(48),c.gc(49,"translate"),c.Tb(),c.Ub(50,"strong",14),c.Qc(51),c.gc(52,"percent"),c.Tb(),c.Tb(),c.Ub(53,"section",13),c.Ub(54,"p"),c.Qc(55),c.gc(56,"translate"),c.Tb(),c.Ub(57,"strong",14),c.Qc(58),c.gc(59,"cryptoPrecise"),c.gc(60,"cryptoAbbreviation"),c.Tb(),c.Tb(),c.Oc(61,_,8,10,"section",15),c.Oc(62,O,4,3,"section",15),c.Tb(),c.Tb()),2&t&&(c.Cb(1),c.Sc(" ",c.hc(2,18,"DASHBOARD.LIQIDATION_CALCULATOR_DISCLAIMER"),"\n"),c.Cb(5),c.mc("formGroup",e.form),c.Cb(3),c.Rc(c.hc(10,20,"FORM.CONTRACT_TYPE")),c.Cb(3),c.mc("ngForOf",e.uniquePairs),c.Cb(3),c.Rc(c.hc(16,22,"COLUMN.DIRECTION")),c.Cb(9),c.Sc("",c.hc(25,24,"FORM.ENTRY_PRICE"),":"),c.Cb(5),c.Sc("",c.hc(30,26,"FORM.QUANTITY"),":"),c.Cb(5),c.Sc("",c.hc(35,28,"LABEL.MARGIN_HELD"),":"),c.Cb(6),c.Sc("",c.hc(41,30,"LABEL.CONTRACT_NOTIONAL_VALUE"),":"),c.Cb(3),c.Tc("",c.ic(44,32,e.notionalValue,e.unitBase)," ",c.hc(45,35,e.unitBase),""),c.Cb(5),c.Sc("",c.hc(49,37,"LABEL.MARGIN_PERC_OF_POS"),":"),c.Cb(3),c.Rc(c.ic(52,39,e.marginPercentage,"1.2-2")),c.Cb(4),c.Sc("",c.hc(56,42,"LABEL.MAINTENANCE_MARGIN_REQUIREMENT"),":"),c.Cb(3),c.Tc("",c.ic(59,44,e.marginRequirement,e.unitBase)," ",c.hc(60,47,e.unitBase),""),c.Cb(3),c.mc("ngIf",e.liquidationPossible&&e.displayLiquidation),c.Cb(1),c.mc("ngIf",!e.liquidationPossible))},directives:[i.z,i.p,u.a,i.h,l.c,l.f,d.a,i.o,i.g,h.m,f.n,p.a,i.s,i.c,b.b,g.a,h.n],pipes:[p.d,m.b,v.a,h.u,m.c],styles:["[_nghost-%COMP%]{display:block;padding:var(--spacing)}.disclaimer[_ngcontent-%COMP%]{border-bottom:2px solid var(--border-colour);padding-bottom:var(--spacing);margin-bottom:var(--spacing)}.form[_ngcontent-%COMP%]{display:flex}@media (max-width:599px){.form[_ngcontent-%COMP%]{flex-direction:column}}.form-results[_ngcontent-%COMP%], .form[_ngcontent-%COMP%] form[_ngcontent-%COMP%]{display:flex;flex-direction:column}.form[_ngcontent-%COMP%] form[_ngcontent-%COMP%]{flex:0.3;margin-right:var(--spacing)}.form[_ngcontent-%COMP%] mat-form-field[_ngcontent-%COMP%]{margin-bottom:var(--spacing)}.form-results[_ngcontent-%COMP%]{flex:0.7}.form-result[_ngcontent-%COMP%]{align-items:center;display:flex;justify-content:space-between}.form-result[_ngcontent-%COMP%]:not(:last-of-type){margin-bottom:6px}.form-result[_ngcontent-%COMP%] strong[_ngcontent-%COMP%]{white-space:nowrap}"],changeDetection:0}),k)},"J+dc":function(t,e,n){"use strict";n.d(e,"a",(function(){return s}));var i=n("5uGe"),r=n("PNff"),o=n("6Oco");function s(t){return function(e){return 0===t?Object(o.b)():e.lift(new u(t))}}var u=function(){function t(e){if(C(this,t),this.total=e,this.total<0)throw new r.a}return w(t,[{key:"call",value:function(t,e){return e.subscribe(new l(t,this.total))}}]),t}(),l=function(t){a(n,t);var e=c(n);function n(t,i){var r;return C(this,n),(r=e.call(this,t)).total=i,r.count=0,r}return w(n,[{key:"_next",value:function(t){var e=this.total,n=++this.count;n<=e&&(this.destination.next(t),n===e&&(this.destination.complete(),this.unsubscribe()))}}]),n}(i.a)},"J/3c":function(t,e,n){"use strict";n.d(e,"a",(function(){return v})),n.d(e,"r",(function(){return y})),n.d(e,"b",(function(){return _})),n.d(e,"f",(function(){return O})),n.d(e,"m",(function(){return C})),n.d(e,"l",(function(){return T})),n.d(e,"q",(function(){return S})),n.d(e,"c",(function(){return E})),n.d(e,"d",(function(){return x})),n.d(e,"k",(function(){return P})),n.d(e,"i",(function(){return A})),n.d(e,"g",(function(){return I})),n.d(e,"p",(function(){return M})),n.d(e,"j",(function(){return D})),n.d(e,"h",(function(){return R})),n.d(e,"s",(function(){return L})),n.d(e,"o",(function(){return U})),n.d(e,"n",(function(){return B})),n.d(e,"e",(function(){return z}));var i=n("zqNl"),r=n("og7C"),o=n("p5wL"),a=n("TYVA"),s=n("lE9u"),c=n("+Px6"),u=n("nXdR"),l=n("VmIW"),d=n("lx5p"),h=n("+axt"),f=n("rxqU"),p=n("5JSY"),b=n("vYTc"),g={margin:Object(r.b)(),futures:Object(r.b)(),holding:Object(r.b)(),flex:void 0,funding:{depositDetails:{},fiatDepositBankDetails:void 0,fiatWithdrawalBankDetails:void 0},authenticated:{marginWallets:[],tradeables:[],flexibleFutures:!1},availableTransferPreferences:[]},m=Object(i.i)(g,Object(i.k)(s.q,(function(){return g})),Object(i.k)(s.w,(function(t,e){var n,i,r,o,a=Object.assign(Object.assign({},t),{holding:t.holding.merge(e.holding),futures:t.futures.merge(e.futures),margin:t.margin.merge(e.margin),flex:e.flex});return(null===(n=e.flex)||void 0===n?void 0:n.flexAssets)&&(null===(i=t.flex)||void 0===i?void 0:i.flexAssets)&&(a.flex=Object.assign(Object.assign({},e.flex),{flexAssets:null===(o=null===(r=t.flex)||void 0===r?void 0:r.flexAssets)||void 0===o?void 0:o.merge(e.flex.flexAssets)})),a})),Object(i.k)(s.t,(function(t,e){return Object(o.b)(e,t,"funding","depositDetails")})),Object(i.k)(s.u,(function(t,e){return Object(o.b)(e,t,"funding","fiatDepositBankDetails")})),Object(i.k)(s.v,(function(t,e){var n=e.addresses;return Object(o.b)(n,t,"funding","fiatWithdrawalBankDetails")})),Object(i.k)(s.r,(function(t,e){var n=e.authenticatedWallets;return Object(o.b)(n,t,"authenticated")})),Object(i.k)(s.s,(function(t,e){var n=e.availableTransferPreferences;return Object(o.b)(n,t,"availableTransferPreferences")})));function v(t,e){return m(t,e)}var y=Object(i.h)("wallets"),_=Object(i.j)(y,(function(t){return t.availableTransferPreferences})),O=Object(i.j)(y,f.m,p.a,(function(t,e,n){return!e&&"kraken"===n||t.authenticated.flexibleFutures})),k=Object(i.j)(y,(function(t){return t.margin})),w=Object(i.j)(y,(function(t){return t.futures})),C=Object(i.j)(y,(function(t){return t.holding})),T=Object(i.j)(y,(function(t){return t.flex})),S=Object(i.j)(y,(function(t){return t.funding})),E=Object(i.j)(y,(function(t){return t.funding.fiatDepositBankDetails})),x=Object(i.j)(y,(function(t){return t.funding.fiatWithdrawalBankDetails})),P=Object(i.j)(h.a,C,(function(t,e){return e.map((function(e){return Object(u.g)(t,e)})).reduce((function(t,e){return t+e}),0)})),A=Object(i.j)(h.a,w,(function(t,e){return e.map((function(e){return Object(u.e)(t,e)})).reduce((function(t,e){return t+e}),0)})),I=Object(i.j)(T,(function(t){return(null==t?void 0:t.pv)||0})),M=Object(i.j)(P,A,I,(function(t,e,n){return t+e+n})),D=Object(i.j)(c.d,h.a,M,C,(function(t,e,n,i){return Object(u.b)(i,e,n,t)})),R=Object(i.j)(c.d,h.a,M,w,(function(t,e,n,i){return Object(u.b)(i,e,n,t)})),j=Object(i.j)(c.d,h.a,M,k,(function(t,e,n,i){return Object(u.b)(i,e,n,t)})),L=Object(i.j)(D,R,j,(function(t,e,n){return t.map((function(t){var i=e.filter((function(e){return e.asset===t.asset})).map((function(t){return t.notional})).reduce((function(t,e){return t+e}),0),r=n.filter((function(e){return e.asset===t.asset})).map((function(t){return t.notional})).reduce((function(t,e){return t+e}),0);return Object.assign(Object.assign({},t),{totalNotional:t.notional+i+r})})).sortBy((function(t){return t.totalNotional}),d.i).valueSeq()})),N=Object(i.j)(c.n,D,(function(t,e){return Object(u.c)(e,t)})),U=Object(i.j)(N,(function(t){return l.Maybe.fromUndefined(t.first())})),F=Object(i.j)(c.n,R,(function(t,e){return Object(u.c)(e,t)})),B=(Object(i.j)(h.a,N,(function(t,e){return e.map((function(e){return Object(u.g)(t,e)})).reduce((function(t,e){return t+e}),0)})),Object(i.j)(h.a,F,(function(t,e){return e.map((function(e){return Object(u.e)(t,e)})).reduce((function(t,e){return t+e}),0)})),Object(i.j)(c.r,R,T,(function(t,e,n){return Object(b.a)(t)?n:e.find((function(e){var n;return(null===(n=Object(u.f)(e.name).orUndefined())||void 0===n?void 0:n.replace("XBT","BTC"))===Object(a.j)(t).toUpperCase()}))}))),z=(Object(i.j)(k,w,C,(function(t,e,n){return n.merge(e).merge(t)})),Object(i.j)(T,f.c,(function(t,e){var n;return null===(n=null==t?void 0:t.flexAssets)||void 0===n?void 0:n.keySeq().toArray().map((function(e){var n,i;return(null===(i=null===(n=null==t?void 0:t.flexAssets)||void 0===n?void 0:n.get(e))||void 0===i?void 0:i.currency)||""})).filter((function(t){return"IE"!==e&&"BE"!==e||"WIF"!==t}))})))},J180:function(t,e,n){"use strict";var i=this&&this.__awaiter||function(t,e,n,i){return new(n||(n=Promise))((function(r,o){function a(t){try{c(i.next(t))}catch(e){o(e)}}function s(t){try{c(i.throw(t))}catch(e){o(e)}}function c(t){t.done?r(t.value):new n((function(e){e(t.value)})).then(a,s)}c((i=i.apply(t,e||[])).next())}))},r=this&&this.__generator||function(t,e){var n,i,r,o,a={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,i&&(r=2&o[0]?i.return:o[0]?i.throw||((r=i.return)&&r.call(i),0):i.next)&&!(r=r.call(i,o[1])).done)return r;switch(i=0,r&&(o=[2&o[0],r.value]),o[0]){case 0:case 1:r=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,i=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!((r=(r=a.trys).length>0&&r[r.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]0&&!t.paused&&!t.ended&&t.readyState>2},t.prototype.tryPlayVideo=function(t){return i(this,void 0,void 0,(function(){return r(this,(function(e){switch(e.label){case 0:if(this.isVideoPlaying(t))return console.warn("Trying to play video that is already playing."),[2];e.label=1;case 1:return e.trys.push([1,3,,4]),[4,t.play()];case 2:return e.sent(),[3,4];case 3:return e.sent(),console.warn("It was not possible to play the video."),[3,4];case 4:return[2]}}))}))},t.prototype.getMediaElement=function(t,e){var n=document.getElementById(t);if(!n)throw new o.default("element with id '"+t+"' not found");if(n.nodeName.toLowerCase()!==e.toLowerCase())throw new o.default("element with id '"+t+"' must be an "+e+" element");return n},t.prototype.decodeFromImage=function(t,e){if(!t&&!e)throw new o.default("either imageElement with a src set or an url must be provided");return e&&!t?this.decodeFromImageUrl(e):this.decodeFromImageElement(t)},t.prototype.decodeFromVideo=function(t,e){if(!t&&!e)throw new o.default("Either an element with a src set or an URL must be provided");return e&&!t?this.decodeFromVideoUrl(e):this.decodeFromVideoElement(t)},t.prototype.decodeFromVideoContinuously=function(t,e,n){if(void 0===t&&void 0===e)throw new o.default("Either an element with a src set or an URL must be provided");return e&&!t?this.decodeFromVideoUrlContinuously(e,n):this.decodeFromVideoElementContinuously(t,n)},t.prototype.decodeFromImageElement=function(t){if(!t)throw new o.default("An image element must be provided.");this.reset();var e=this.prepareImageElement(t);return this.imageElement=e,this.isImageLoaded(e)?this.decodeOnce(e,!1,!0):this._decodeOnLoadImage(e)},t.prototype.decodeFromVideoElement=function(t){var e=this._decodeFromVideoElementSetup(t);return this._decodeOnLoadVideo(e)},t.prototype.decodeFromVideoElementContinuously=function(t,e){var n=this._decodeFromVideoElementSetup(t);return this._decodeOnLoadVideoContinuously(n,e)},t.prototype._decodeFromVideoElementSetup=function(t){if(!t)throw new o.default("A video element must be provided.");this.reset();var e=this.prepareVideoElement(t);return this.videoElement=e,e},t.prototype.decodeFromImageUrl=function(t){if(!t)throw new o.default("An URL must be provided.");this.reset();var e=this.prepareImageElement();this.imageElement=e;var n=this._decodeOnLoadImage(e);return e.src=t,n},t.prototype.decodeFromVideoUrl=function(t){if(!t)throw new o.default("An URL must be provided.");this.reset();var e=this.prepareVideoElement(),n=this.decodeFromVideoElement(e);return e.src=t,n},t.prototype.decodeFromVideoUrlContinuously=function(t,e){if(!t)throw new o.default("An URL must be provided.");this.reset();var n=this.prepareVideoElement(),i=this.decodeFromVideoElementContinuously(n,e);return n.src=t,i},t.prototype._decodeOnLoadImage=function(t){var e=this;return new Promise((function(n,i){e.imageLoadedListener=function(){return e.decodeOnce(t,!1,!0).then(n,i)},t.addEventListener("load",e.imageLoadedListener)}))},t.prototype._decodeOnLoadVideo=function(t){return i(this,void 0,void 0,(function(){return r(this,(function(e){switch(e.label){case 0:return[4,this.playVideoOnLoadAsync(t)];case 1:return e.sent(),[4,this.decodeOnce(t)];case 2:return[2,e.sent()]}}))}))},t.prototype._decodeOnLoadVideoContinuously=function(t,e){return i(this,void 0,void 0,(function(){return r(this,(function(n){switch(n.label){case 0:return[4,this.playVideoOnLoadAsync(t)];case 1:return n.sent(),this.decodeContinuously(t,e),[2]}}))}))},t.prototype.isImageLoaded=function(t){return!!t.complete&&0!==t.naturalWidth},t.prototype.prepareImageElement=function(t){var e;return void 0===t&&((e=document.createElement("img")).width=200,e.height=200),"string"==typeof t&&(e=this.getMediaElement(t,"img")),t instanceof HTMLImageElement&&(e=t),e},t.prototype.prepareVideoElement=function(t){var e;return t||"undefined"==typeof document||((e=document.createElement("video")).width=200,e.height=200),"string"==typeof t&&(e=this.getMediaElement(t,"video")),t instanceof HTMLVideoElement&&(e=t),e.setAttribute("autoplay","true"),e.setAttribute("muted","true"),e.setAttribute("playsinline","true"),e},t.prototype.decodeOnce=function(t,e,n){var i=this;void 0===e&&(e=!0),void 0===n&&(n=!0),this._stopAsyncDecode=!1;return new Promise((function(r,o){return function r(o,a){if(i._stopAsyncDecode)return a(new l.default("Video stream has ended before any code could be detected.")),void(i._stopAsyncDecode=void 0);try{var c=i.decode(t);o(c)}catch(d){if(e&&d instanceof l.default||(d instanceof s.default||d instanceof u.default)&&n)return setTimeout((function(){return r(o,a)}),i._timeBetweenDecodingAttempts);a(d)}}(r,o)}))},t.prototype.decodeContinuously=function(t,e){var n=this;this._stopContinuousDecode=!1;!function i(){if(n._stopContinuousDecode)n._stopContinuousDecode=void 0;else try{var r=n.decode(t);e(r,null),setTimeout((function(){return i()}),n.timeBetweenScansMillis)}catch(o){e(null,o),(o instanceof s.default||o instanceof u.default||o instanceof l.default)&&setTimeout((function(){return i()}),n._timeBetweenDecodingAttempts)}}()},t.prototype.decode=function(t){var e=this.createBinaryBitmap(t);return this.decodeBitmap(e)},t.prototype.createBinaryBitmap=function(t){var e=this.getCaptureCanvasContext(t);this.drawImageOnCanvas(e,t);var n=this.getCaptureCanvas(t),i=new d.HTMLCanvasElementLuminanceSource(n),r=new c.default(i);return new a.default(r)},t.prototype.getCaptureCanvasContext=function(t){if(!this.captureCanvasContext){var e=this.getCaptureCanvas(t).getContext("2d");this.captureCanvasContext=e}return this.captureCanvasContext},t.prototype.getCaptureCanvas=function(t){if(!this.captureCanvas){var e=this.createCaptureCanvas(t);this.captureCanvas=e}return this.captureCanvas},t.prototype.drawImageOnCanvas=function(t,e){t.drawImage(e,0,0)},t.prototype.decodeBitmap=function(t){return this.reader.decode(t,this._hints)},t.prototype.createCaptureCanvas=function(t){if("undefined"==typeof document)return this._destroyCaptureCanvas(),null;var e,n,i=document.createElement("canvas");return void 0!==t&&(t instanceof HTMLVideoElement?(e=t.videoWidth,n=t.videoHeight):t instanceof HTMLImageElement&&(e=t.naturalWidth||t.width,n=t.naturalHeight||t.height)),i.style.width=e+"px",i.style.height=n+"px",i.width=e,i.height=n,i},t.prototype.stopStreams=function(){this.stream&&(this.stream.getVideoTracks().forEach((function(t){return t.stop()})),this.stream=void 0),!1===this._stopAsyncDecode&&this.stopAsyncDecode(),!1===this._stopContinuousDecode&&this.stopContinuousDecode()},t.prototype.reset=function(){this.stopStreams(),this._destroyVideoElement(),this._destroyImageElement(),this._destroyCaptureCanvas()},t.prototype._destroyVideoElement=function(){this.videoElement&&(void 0!==this.videoEndedListener&&this.videoElement.removeEventListener("ended",this.videoEndedListener),void 0!==this.videoPlayingEventListener&&this.videoElement.removeEventListener("playing",this.videoPlayingEventListener),void 0!==this.videoCanPlayListener&&this.videoElement.removeEventListener("loadedmetadata",this.videoCanPlayListener),this.cleanVideoSource(this.videoElement),this.videoElement=void 0)},t.prototype._destroyImageElement=function(){this.imageElement&&(void 0!==this.imageLoadedListener&&this.imageElement.removeEventListener("load",this.imageLoadedListener),this.imageElement.src=void 0,this.imageElement.removeAttribute("src"),this.imageElement=void 0)},t.prototype._destroyCaptureCanvas=function(){this.captureCanvasContext=void 0,this.captureCanvas=void 0},t.prototype.addVideoSource=function(t,e){try{t.srcObject=e}catch(n){t.src=URL.createObjectURL(e)}},t.prototype.cleanVideoSource=function(t){try{t.srcObject=null}catch(e){t.src=""}this.videoElement.removeAttribute("src")},t}()},J7L8:function(t,e,n){"use strict";var i,o,a;n.d(e,"a",(function(){return Ct}));var s=n("D57K"),c=n("kZht"),u=n("zqNl"),l=n("ZTXN"),d=n("gxtV"),h=n("VmIW"),g=n("KQpv"),m=n.n(g),v=n("lx5p"),y=n("YzTY"),_=n("uJYd"),O=n("YyhG"),k=n("O5EP"),T=n("wk3K"),S=n("WncL"),E=n("houi"),x=n("nVws"),P=n("v4C1"),A=n("O0qa"),I=n("hnst"),M=n("36Sp"),D=n("bxcy"),R=n("Ngp4"),j=n("UZ8P"),L=n("6neU"),N=n("zK/z"),U=(f(i={},y.a.MARKET_DETAILS,k.a),f(i,y.a.MARKET_CHART,T.a),f(i,y.a.MARKET_PREVIEWS,S.a),f(i,y.a.ORDERBOOK,E.a),f(i,y.a.ORDER_FORM,x.a),f(i,y.a.TRADE_HISTORY,P.a),f(i,y.a.OPEN_ORDERS,A.a),f(i,y.a.TRIGGER_ORDERS,I.a),f(i,y.a.OPEN_POSITIONS,M.a),f(i,y.a.FILLED_ORDERS,D.a),f(i,y.a.PAIR_WALLET,R.a),f(i,y.a.BRACKET_ORDER,L.a),f(i,y.a.DEPTH_CHART,j.a),f(i,y.a.ACCOUNT_ACTIVITY,N.a),i);var F=n("LaGA"),B=n("TLy2"),z=n("An66"),V=n("aaFr"),H=n("TADc"),q=n("ROO/"),$=n("icqo"),Q=n("NxuZ"),W=n("FUfi"),G=n("bBQR"),Y=n("anSm"),K=n("aDqW"),Z=n("MqcE"),X=["content"],J=["container"],tt=["tabsList"],et=["tabsContainer"];function nt(t,e){if(1&t){var n=c.Vb();c.Ub(0,"div",25),c.bc("dragstart",(function(t){c.Ec(n);var i=e.$implicit;return c.fc(2).startTabDrag(t,i)}))("dragover",(function(){c.Ec(n);var t=e.index;return c.fc(2).dragOverTab(t)}))("dragend",(function(t){c.Ec(n);var i=e.$implicit;return c.fc(2).dragEndTab(t,i)}))("drop",(function(t){c.Ec(n);var i=e.index;return c.fc(2).dropTab(t,i)}))("click",(function(){c.Ec(n);var t=e.$implicit;return c.fc(2).focusTab(t)})),c.Ub(1,"tab-label",26),c.bc("closeTab",(function(){c.Ec(n);var t=e.$implicit;return c.fc(2).removeTab(t)})),c.Tb(),c.Tb()}if(2&t){var i=e.$implicit,r=e.index,o=c.fc(2);c.Lc("margin-left",o.marginLeft(i,r)),c.Gb("active",o.focussedComponentId.contains(i.id)),c.mc("hidden",o.hiddenComponents.includes(i)),c.Cb(1),c.oc("heading","HEADING.",o.CID[i.id],""),c.mc("badgeSelector",o.tabBadge(i.id)),c.Db("active",o.focussedComponentId.contains(i.id))}}function it(t,e){if(1&t&&(c.Ub(0,"div",27),c.Ub(1,"p",28),c.Qc(2),c.Tb(),c.Pb(3,"fa-icon",29),c.Tb()),2&t){var n=c.fc(2),i=c.Ac(6);c.mc("sbMenuTriggerFor",i),c.Cb(2),c.Rc(n.hiddenComponents.length)}}function rt(t,e){if(1&t&&(c.Ub(0,"div",30),c.Pb(1,"fa-icon",31),c.Tb()),2&t){c.fc(2);var n=c.Ac(13);c.mc("sbMenuTriggerFor",n)}}function ot(t,e){if(1&t&&(c.Ub(0,"div",5,21),c.Oc(2,nt,2,8,"div",22),c.Oc(3,it,4,2,"div",23),c.Oc(4,rt,2,1,"div",24),c.Tb()),2&t){var n=c.fc();c.Cb(2),c.mc("ngForOf",n.tabs),c.Cb(1),c.mc("ngIf",n.hiddenComponents.length),c.Cb(1),c.mc("ngIf",(n.usableTabs.length||n.moveHereTabs.length)&&!n.hiddenComponents.length)}}function at(t,e){if(1&t&&(c.Sb(0),c.Ub(1,"div",32),c.Ub(2,"p",33),c.Qc(3,"TAB_WRAPPER.ADD_NEW"),c.Tb(),c.Pb(4,"fa-icon",34),c.Tb(),c.Rb()),2&t){c.fc();var n=c.Ac(13);c.Cb(1),c.mc("sbMenuTriggerFor",n)}}function st(t,e){if(1&t){var n=c.Vb();c.Ub(0,"div",35),c.Ub(1,"button",36),c.bc("click",(function(){c.Ec(n);var t=e.$implicit,i=e.index;return c.fc().menuTabClick(t,i)})),c.Qc(2),c.gc(3,"translate"),c.Tb(),c.Ub(4,"button",37),c.bc("click",(function(){c.Ec(n);var t=e.$implicit;return c.fc().removeTab(t)})),c.Pb(5,"fa-icon",38),c.Tb(),c.Tb()}if(2&t){var i=e.$implicit,r=c.fc();c.Cb(2),c.Sc(" ",c.hc(3,1,"HEADING."+r.CID[i.id])," ")}}function ct(t,e){if(1&t){var n=c.Vb();c.Ub(0,"button",39),c.bc("click",(function(){c.Ec(n);var t=e.$implicit;return c.fc().addTab(t)})),c.Qc(1),c.gc(2,"translate"),c.Tb()}if(2&t){var i=e.$implicit,r=c.fc();c.Cb(1),c.Sc(" ",c.hc(2,1,"HEADING."+r.CID[i.id])," ")}}function ut(t,e){1&t&&(c.Ub(0,"p",40),c.Qc(1,"TAB_WRAPPER.IN_USE"),c.Tb())}function lt(t,e){if(1&t){var n=c.Vb();c.Ub(0,"button",41),c.bc("click",(function(){c.Ec(n);var t=e.$implicit;return c.fc().addInUseTab(t)})),c.Qc(1),c.gc(2,"translate"),c.Tb()}if(2&t){var i=e.$implicit,r=c.fc();c.Cb(1),c.Sc(" ",c.hc(2,1,"HEADING."+r.CID[i.id])," ")}}function dt(t,e){1&t&&(c.Sb(0),c.Pb(1,"fa-icon",44),c.Ub(2,"p",33),c.Qc(3,"TAB_WRAPPER.COMPONENT_IN_USE"),c.Tb(),c.Rb())}function ht(t,e){1&t&&(c.Sb(0),c.Pb(1,"fa-icon",45),c.Ub(2,"p",33),c.Qc(3,"TAB_WRAPPER.VALID_CONTAINER"),c.Tb(),c.Rb())}function ft(t,e){1&t&&(c.Sb(0),c.Pb(1,"fa-icon",44),c.Ub(2,"p",33),c.Qc(3,"TAB_WRAPPER.INVALID_CONTAINER"),c.Tb(),c.Rb())}function pt(t,e){1&t&&(c.Sb(0),c.Pb(1,"fa-icon",46),c.Ub(2,"p",33),c.Qc(3,"TAB_WRAPPER.DROP_TAB"),c.Tb(),c.Rb())}function bt(t,e){if(1&t){var n=c.Vb();c.Ub(0,"div",42),c.bc("drop",(function(t){return c.Ec(n),c.fc().dropTab(t)})),c.Oc(1,dt,4,0,"ng-container",43),c.Oc(2,ht,4,0,"ng-container",43),c.Oc(3,ft,4,0,"ng-container",43),c.Oc(4,pt,4,0,"ng-container",43),c.Tb()}if(2&t){var i=c.fc();c.Eb(i.dropClass),c.mc("ngSwitch",i.state),c.Cb(1),c.mc("ngSwitchCase","in-use"),c.Cb(1),c.mc("ngSwitchCase","drop-valid"),c.Cb(1),c.mc("ngSwitchCase","drop-invalid"),c.Cb(1),c.mc("ngSwitchCase","drop-target")}}function gt(t,e){if(1&t&&(c.Ub(0,"div",47),c.Ub(1,"div",48),c.Pb(2,"fa-icon",49),c.Ub(3,"p",33),c.Qc(4,"TAB_WRAPPER.ADD_NEW_WIDGET"),c.Tb(),c.Ub(5,"p",33),c.Qc(6,"TAB_WRAPPER.SELECT_DATA"),c.Tb(),c.Tb(),c.Tb()),2&t){c.fc();var n=c.Ac(13);c.Cb(1),c.mc("sbMenuTriggerFor",n)}}var mt,vt=m()("app:tab-wrapper"),yt=m()("trace:app:tab-wrapper"),_t={empty:"1px solid var(--border-colour)",content:"1px solid var(--border-colour)","in-use":"1px solid var(--border-colour)","drop-valid":"2px dashed var(--g200)","drop-invalid":"2px dashed var(--r200)","drop-target":"2px dashed var(--brand)"},Ot={empty:"",content:"","in-use":"in-use-container","drop-valid":"valid-container","drop-invalid":"invalid-container","drop-target":"drop-target"},kt=(f(o={},y.a.OPEN_POSITIONS,"POSITIONS_ORDERS"),f(o,y.a.OPEN_ORDERS,"POSITIONS_ORDERS"),f(o,y.a.TRIGGER_ORDERS,"POSITIONS_ORDERS"),f(o,y.a.FILLED_ORDERS,"POSITIONS_ORDERS"),f(o,y.a.ORDERBOOK,"ORDERBOOK"),f(o,y.a.MARKET_CHART,"MARKET_CHART"),f(o,y.a.TRADE_HISTORY,"TRADE_HISTORY"),o),wt=(f(a={},y.a.OPEN_ORDERS,O.h),f(a,y.a.TRIGGER_ORDERS,O.j),f(a,y.a.OPEN_POSITIONS,O.i),a),Ct=((mt=function(){function t(e,n,i){var r=this;C(this,t),this.cfr=e,this.store=n,this.changeDetectorRef=i,this.CID=y.a,this.loadedComponent=Object(h.None)(),this.dragCounter=0,this.dropPositionPreview=Object(h.None)(),this.workspaceComponents=[],this.tabAdd=new c.o,this.tabMove=new c.o,this.tabDelete=new c.o,this.tabFocus=new c.o,this.tabDragging=new c.o,this.hiddenComponents=[],this.observed=!1,this.badgeSelector$=new l.b,this.badge$=this.badgeSelector$.pipe(Object(B.a)((function(t){return r.store.pipe(Object(u.m)(t))}))),this.debug=function(t){for(var e,n=arguments.length,i=new Array(n>1?n-1:0),o=1;o1?n-1:0),o=1;o0,c=t.hiddenComponents.map((function(t){return t.id}));if(s){var u=function(t,e){for(var n=t.length;n--;)if(e(t[n],n,t))return n;return-1}(t.validComponents,(function(e){return!c.includes(e)&&t.activeComponent!==e}));if(-1!==u)return{v:(t.hiddenComponents.push(t.tabs[u]),void t.changeDetectorRef.detectChanges())}}else a-i>200&&t.hiddenComponents.shift();t.removeOldHiddenComponents(),t.changeDetectorRef.detectChanges()};for(i.s();!(n=i.n()).done;){var a=o();if("object"==typeof a)return a.v}}catch(s){i.e(s)}finally{i.f()}})),this.observer.observe(this.tabsList.nativeElement),this.observer.observe(this.tabsContainer.nativeElement),this.observed=!0}},{key:"removeOldHiddenComponents",value:function(){var t=this;this.hiddenComponents.forEach((function(e,n){t.validComponents.includes(e.id)||t.hiddenComponents.splice(n,1)}))}},{key:"menuTabClick",value:function(t,e){this.focusTab(t),this.moveTab(t,0),this.hiddenComponents.splice(e,1)}},{key:"marginLeft",value:function(t,e){var n=this;if(this.dropPositionPreview.contains(e))return"60px";var i=this.tabs.find((function(t){return!n.hiddenComponents.map((function(t){return t.id})).includes(t.id)}));return i&&t.id===i.id?"0px":"10px"}},{key:"tabBadge",value:function(t){return wt[t]}},{key:"tabs",get:function(){return this.validComponents.map((function(t){return y.i[t]}))}},{key:"suitableTabs",get:function(){var t=this;return b(Object.values(y.i)).filter((function(e){return Object(y.h)(e,t.panelSize)&&!e.deprecated}))}},{key:"usableTabs",get:function(){var t=this;return this.suitableTabs.filter((function(e){return!t.workspaceComponents.includes(e.id)&&!e.deprecated}))}},{key:"moveHereTabs",get:function(){var t=this;return this.suitableTabs.filter((function(e){var n=t.workspaceComponents.includes(e.id),i=t.tabs.includes(e);return n&&!i}))}},{key:"isValidPanel",get:function(){return this.validPanelLocations.has(this.location)}},{key:"isDraggedOver",get:function(){return this.dragCounter>0}},{key:"state",get:function(){var t=this;return this.dragging.cata((function(){return t.validComponents.length>0?"content":"empty"}),(function(e){return t.validComponents.includes(e)?"in-use":t.isValidPanel&&t.isDraggedOver?"drop-target":t.isValidPanel&&!t.isDraggedOver?"drop-valid":"drop-invalid"}))}},{key:"isDragMode",get:function(){return!["content","empty"].includes(this.state)}},{key:"dropClass",get:function(){return Ot[this.state]}},{key:"panelBorder",get:function(){return _t[this.state]}},{key:"focussedComponentId",get:function(){if(this.validComponents.length>0){var t=this.activeComponent&&!y.i[this.activeComponent].deprecated?this.activeComponent:this.validComponents[0];return Object(h.Some)(t)}return Object(h.None)()}},{key:"isOverflow",get:function(){var t=this.tabsList.nativeElement;return t.offsetWidth p[_ngcontent-%COMP%], .in-use-container[_ngcontent-%COMP%] > p[_ngcontent-%COMP%], .invalid-container[_ngcontent-%COMP%] > p[_ngcontent-%COMP%], .valid-container[_ngcontent-%COMP%] > p[_ngcontent-%COMP%]{margin-top:5px}.in-use-container[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{color:var(--border-colour)}.valid-container[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{color:var(--accent-colour)}.invalid-container[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{color:var(--warn-colour)}.drop-target[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{color:var(--brand)}.content[_ngcontent-%COMP%]{flex:1;overflow:auto}.content[_ngcontent-%COMP%] .no-content[_ngcontent-%COMP%]{height:100%}.content[_ngcontent-%COMP%] .no-content[_ngcontent-%COMP%], .content[_ngcontent-%COMP%] .placeholder[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center}.content[_ngcontent-%COMP%] .placeholder[_ngcontent-%COMP%]{color:#888;cursor:pointer;height:-moz-max-content;height:max-content;flex-direction:column;width:-moz-max-content;width:max-content}.content[_ngcontent-%COMP%] .placeholder[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{color:var(--icon-colour)}.content[_ngcontent-%COMP%] .placeholder[_ngcontent-%COMP%] > p[_ngcontent-%COMP%]{margin-top:5px}.spacer[_ngcontent-%COMP%]{flex-grow:1}.tab-basic[_ngcontent-%COMP%]{align-items:center;background:var(--toolbar-colour);border:1px solid var(--border-colour);border-top-left-radius:5px;border-top-right-radius:5px;border-bottom:0;display:flex;z-index:2}.tab-basic.active[_ngcontent-%COMP%], .tab-basic[_ngcontent-%COMP%]:hover{border-color:var(--border-colour-bright);background:var(--card-colour)}.tab-basic.active[_ngcontent-%COMP%]{border-bottom:1px solid var(--card-colour);position:relative;margin-top:-1px;top:1px}.tab-dropdown[_ngcontent-%COMP%]{cursor:pointer;display:flex;margin-left:var(--spacing);padding:4px 2px 4px 6px}.tab-dropdown[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{color:var(--ghost-colour)}.tab-dropdown[_ngcontent-%COMP%] fa-icon.down[_ngcontent-%COMP%]{color:var(--icon-colour);top:-1px;position:relative}.tab-name[_ngcontent-%COMP%]{flex:1}.remove-tab[_ngcontent-%COMP%]{width:30px}.add-tab[_ngcontent-%COMP%]{cursor:pointer;padding:4px 6px;margin-left:var(--spacing)}.add-tab[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{color:var(--icon-colour)}.tab-list[_ngcontent-%COMP%]{display:flex;flex-wrap:nowrap}.tab-list-item[_ngcontent-%COMP%]{display:flex;flex-direction:row;justify-content:space-between}.tab-list[_ngcontent-%COMP%] > fa-icon[_ngcontent-%COMP%]{cursor:pointer;color:var(--icon-colour);position:relative;top:4px;margin-left:10px;z-index:2}[hidden][_ngcontent-%COMP%]{display:none!important}"],changeDetection:0}),mt=Object(s.d)([Object(d.a)()],mt))},JHA6:function(t,e,n){"use strict";n.d(e,"a",(function(){return b}));var i,r=n("ZTXN"),s=n("IdLP"),u=(n("5uGe"),n("bwdy")),l=n("i7Dj"),d=function(t){a(n,t);var e=c(n);function n(t,i){var r;return C(this,n),(r=e.call(this)).source=t,r.subjectFactory=i,r._refCount=0,r._isComplete=!1,r}return w(n,[{key:"_subscribe",value:function(t){return this.getSubject().subscribe(t)}},{key:"getSubject",value:function(){var t=this._subject;return t&&!t.isStopped||(this._subject=this.subjectFactory()),this._subject}},{key:"connect",value:function(){var t=this._connection;return t||(this._isComplete=!1,(t=this._connection=new u.a).add(this.source.subscribe(new p(this.getSubject(),this))),t.closed&&(this._connection=null,t=u.a.EMPTY)),t}},{key:"refCount",value:function(){return Object(l.a)()(this)}}]),n}(s.a),f={operator:{value:null},_refCount:{value:0,writable:!0},_subject:{value:null,writable:!0},_connection:{value:null,writable:!0},_subscribe:{value:(i=d.prototype)._subscribe},_isComplete:{value:i._isComplete,writable:!0},getSubject:{value:i.getSubject},connect:{value:i.connect},refCount:{value:i.refCount}},p=function(t){a(n,t);var e=c(n);function n(t,i){var r;return C(this,n),(r=e.call(this,t)).connectable=i,r}return w(n,[{key:"_error",value:function(t){this._unsubscribe(),o(h(n.prototype),"_error",this).call(this,t)}},{key:"_complete",value:function(){this.connectable._isComplete=!0,this._unsubscribe(),o(h(n.prototype),"_complete",this).call(this)}},{key:"_unsubscribe",value:function(){var t=this.connectable;if(t){this.connectable=null;var e=t._connection;t._refCount=0,t._subject=null,t._connection=null,e&&e.unsubscribe()}}}]),n}(r.c);function b(t,e){return function(n){var i;if(i="function"==typeof t?t:function(){return t},"function"==typeof e)return n.lift(new g(i,e));var r=Object.create(n,f);return r.source=n,r.subjectFactory=i,r}}var g=function(){function t(e,n){C(this,t),this.subjectFactory=e,this.selector=n}return w(t,[{key:"call",value:function(t,e){var n=this.selector,i=this.subjectFactory(),r=n(i).subscribe(t);return r.add(e.subscribe(i)),r}}]),t}()},JgBV:function(t,e,n){var i=n("p3rJ"),r=n("5OId");e.NUMERIC={id:"Numeric",bit:1,ccBits:[10,12,14]},e.ALPHANUMERIC={id:"Alphanumeric",bit:2,ccBits:[9,11,13]},e.BYTE={id:"Byte",bit:4,ccBits:[8,16,16]},e.KANJI={id:"Kanji",bit:8,ccBits:[8,10,12]},e.MIXED={bit:-1},e.getCharCountIndicator=function(t,e){if(!t.ccBits)throw new Error("Invalid mode: "+t);if(!i.isValid(e))throw new Error("Invalid version: "+e);return e>=1&&e<10?t.ccBits[0]:e<27?t.ccBits[1]:t.ccBits[2]},e.getBestModeForData=function(t){return r.testNumeric(t)?e.NUMERIC:r.testAlphanumeric(t)?e.ALPHANUMERIC:r.testKanji(t)?e.KANJI:e.BYTE},e.toString=function(t){if(t&&t.id)return t.id;throw new Error("Invalid mode")},e.isValid=function(t){return t&&t.bit&&t.ccBits},e.from=function(t,n){if(e.isValid(t))return t;try{return function(t){if("string"!=typeof t)throw new Error("Param is not a string");switch(t.toLowerCase()){case"numeric":return e.NUMERIC;case"alphanumeric":return e.ALPHANUMERIC;case"kanji":return e.KANJI;case"byte":return e.BYTE;default:throw new Error("Unknown mode: "+t)}}(t)}catch(i){return n}}},JpLq:function(t,e,n){"use strict";n.d(e,"a",(function(){return f})),n.d(e,"b",(function(){return g}));var i=n("D57K"),r=n("An66"),o=n("kZht"),s=n("3kIJ"),u=n("Nhx6"),l=n("C05f"),d=["preview"],h=function(t){a(n,t);var e=c(n);function n(){var t;return C(this,n),(t=e.apply(this,arguments))._isTorchAvailable=new l.a(void 0),t}return w(n,[{key:"continuousDecodeFromInputVideoDevice",value:function(t,e){var n=this;if(this.reset(),void 0!==t&&(this.deviceId=t),"undefined"!=typeof navigator){var i=new l.a({});try{this.getStreamForDevice({deviceId:t}).then((function(t){return n.attachStreamToVideoAndCheckTorch(t,e)})).then((function(t){return n.decodeOnSubject(i,t,n.timeBetweenScansMillis)}))}catch(r){i.error(r)}return this._setScanStream(i),i.asObservable()}}},{key:"getStreamForDevice",value:function(t){var e=t.deviceId;return Object(i.a)(this,void 0,void 0,regeneratorRuntime.mark((function t(){var n;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=this.getUserMediaConstraints(e),t.next=3,navigator.mediaDevices.getUserMedia(n);case 3:return t.abrupt("return",t.sent);case 4:case"end":return t.stop()}}),t,this)})))}},{key:"getUserMediaConstraints",value:function(t){return{video:void 0===t?{facingMode:{exact:"environment"}}:{deviceId:{exact:t}}}}},{key:"setTorch",value:function(t){if(this._isTorchAvailable.value){var e=this.getVideoTracks(this.stream);t?this.applyTorchOnTracks(e,!0):(this.applyTorchOnTracks(e,!1),this.restart())}}},{key:"attachStreamToVideoAndCheckTorch",value:function(t,e){return this.updateTorchCompatibility(t),this.attachStreamToVideo(t,e)}},{key:"updateTorchCompatibility",value:function(t){return Object(i.a)(this,void 0,void 0,regeneratorRuntime.mark((function e(){var n,i,r,o;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:n=this.getVideoTracks(t),i=p(n),e.prev=2,i.s();case 4:if((r=i.n()).done){e.next=13;break}return o=r.value,e.next=8,this.isTorchCompatible(o);case 8:if(!e.sent){e.next=11;break}return this._isTorchAvailable.next(!0),e.abrupt("break",13);case 11:e.next=4;break;case 13:e.next=18;break;case 15:e.prev=15,e.t0=e.catch(2),i.e(e.t0);case 18:return e.prev=18,i.f(),e.finish(18);case 21:case"end":return e.stop()}}),e,this,[[2,15,18,21]])})))}},{key:"getVideoTracks",value:function(t){var e=[];try{e=t.getVideoTracks()}finally{return e||[]}}},{key:"isTorchCompatible",value:function(t){return Object(i.a)(this,void 0,void 0,regeneratorRuntime.mark((function e(){var n,i,r;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=!1,e.prev=1,i=new ImageCapture(t),e.next=5,i.getPhotoCapabilities();case 5:r=e.sent,n=!!r.torch||"fillLightMode"in r&&0!==r.fillLightMode.length;case 7:return e.prev=7,e.abrupt("return",n);case 10:case"end":return e.stop()}}),e,null,[[1,,7,10]])})))}},{key:"applyTorchOnTracks",value:function(t,e){t.forEach((function(t){return t.applyConstraints({advanced:[{torch:e,fillLightMode:e?"torch":"none"}]})}))}},{key:"_setScanStream",value:function(t){this._cleanScanStream(),this.scanStream=t}},{key:"_cleanScanStream",value:function(){this.scanStream&&!this.scanStream.isStopped&&this.scanStream.complete(),this.scanStream=null}},{key:"decodeOnSubject",value:function(t,e,n){var i,r=this;if(!t.isStopped)try{i=this.decode(e),t.next({result:i})}catch(o){!o||o instanceof u.NotFoundException||o instanceof u.ChecksumException||o instanceof u.FormatException?t.next({error:o}):t.error(o)}finally{setTimeout((function(){return r.decodeOnSubject(t,e,n)}),i?n:0)}}},{key:"restart",value:function(){return this.continuousDecodeFromInputVideoDevice(this.deviceId,this.videoElement)}},{key:"isTorchAvailable",get:function(){return this._isTorchAvailable.asObservable()}}]),n}(u.BrowserMultiFormatReader),f=function(){var t=function(){function t(){C(this,t),this.timeBetweenScans=500,this.previewFitMode="cover",this.autostarted=new o.o,this.autostarting=new o.o,this.torchCompatible=new o.o,this.scanSuccess=new o.o,this.scanFailure=new o.o,this.scanError=new o.o,this.scanComplete=new o.o,this.camerasFound=new o.o,this.camerasNotFound=new o.o,this.permissionResponse=new o.o(!0),this.hasDevices=new o.o,this.deviceChange=new o.o,this._device=null,this._enabled=!0,this._hints=new Map,this.autofocusEnabled=!0,this.autostart=!0,this.formats=[u.BarcodeFormat.QR_CODE],this.hasNavigator="undefined"!=typeof navigator,this.isMediaDevicesSupported=this.hasNavigator&&!!navigator.mediaDevices}return w(t,[{key:"askForPermission",value:function(){return Object(i.a)(this,void 0,void 0,regeneratorRuntime.mark((function t(){var e,n;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(this.hasNavigator){t.next=2;break}return t.abrupt("return",(console.error("@zxing/ngx-scanner","Can't ask permission, navigator is not present."),this.setPermission(null),this.hasPermission));case 2:if(this.isMediaDevicesSupported){t.next=4;break}return t.abrupt("return",(console.error("@zxing/ngx-scanner","Can't get user media, this is not supported."),this.setPermission(null),this.hasPermission));case 4:return t.prev=4,t.next=7,this.getAnyVideoDevice();case 7:e=t.sent,n=!!e,t.next=14;break;case 11:return t.prev=11,t.t0=t.catch(4),t.abrupt("return",this.handlePermissionException(t.t0));case 14:return t.prev=14,this.terminateStream(e),t.finish(14);case 17:return t.abrupt("return",(this.setPermission(n),n));case 18:case"end":return t.stop()}}),t,this,[[4,11,14,17]])})))}},{key:"getAnyVideoDevice",value:function(){return navigator.mediaDevices.getUserMedia({video:!0})}},{key:"terminateStream",value:function(t){t&&t.getTracks().forEach((function(t){return t.stop()})),t=void 0}},{key:"initAutostartOff",value:function(){this.isAutostarting=null,this.updateVideoInputDevices()}},{key:"initAutostartOn",value:function(){return Object(i.a)(this,void 0,void 0,regeneratorRuntime.mark((function t(){var e,n;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return this.isAutostarting=!0,t.prev=1,t.next=4,this.askForPermission();case 4:e=t.sent,t.next=10;break;case 7:return t.prev=7,t.t0=t.catch(1),t.abrupt("return",void console.error("Exception occurred while asking for permission:",t.t0));case 10:if(!e){t.next=15;break}return t.next=13,this.updateVideoInputDevices();case 13:n=t.sent,this.autostartScanner(b(n));case 15:case"end":return t.stop()}}),t,this,[[1,7]])})))}},{key:"isCurrentDevice",value:function(t){return this.device&&t&&t.deviceId===this.device.deviceId}},{key:"ngAfterViewInit",value:function(){var t=this;if(this.getCodeReader().isTorchAvailable.subscribe((function(e){return t.torchCompatible.emit(e)})),!this.autostart)return console.warn("New feature 'autostart' disabled, be careful. Permissions and devices recovery has to be run manually."),void this.initAutostartOff();this.initAutostartOn()}},{key:"ngOnDestroy",value:function(){this.reset()}},{key:"restart",value:function(){var t=this._reset();t&&(this._codeReader=void 0,this.device=t)}},{key:"updateVideoInputDevices",value:function(){return Object(i.a)(this,void 0,void 0,regeneratorRuntime.mark((function t(){var e,n;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.getCodeReader().listVideoInputDevices();case 2:if(t.t0=t.sent,t.t0){t.next=5;break}t.t0=[];case 5:return e=t.t0,n=e&&e.length>0,t.abrupt("return",(this.hasDevices.next(n),this.camerasFound.next(b(e)),n||this.camerasNotFound.next(),e));case 8:case"end":return t.stop()}}),t,this)})))}},{key:"autostartScanner",value:function(t){var e=t.find((function(t){var e=t.label;return/back|tr\xe1s|rear|traseira|environment|ambiente/gi.test(e)}))||t.pop();if(!e)throw new Error("Impossible to autostart, no input devices available.");this.device=e,this.deviceChange.emit(e),this.isAutostarting=!1,this.autostarted.next()}},{key:"dispatchScanSuccess",value:function(t){this.scanSuccess.next(t.getText())}},{key:"dispatchScanFailure",value:function(t){this.scanFailure.next(t)}},{key:"dispatchScanError",value:function(t){this.scanError.next(t)}},{key:"dispatchScanComplete",value:function(t){this.scanComplete.next(t)}},{key:"handlePermissionException",value:function(t){var e;switch(console.error("@zxing/ngx-scanner","Error when asking for permission.",t),t.name){case"NotSupportedError":console.warn("@zxing/ngx-scanner",t.message),e=null,this.hasDevices.next(null);break;case"NotAllowedError":console.warn("@zxing/ngx-scanner",t.message),e=!1,this.hasDevices.next(!0);break;case"NotFoundError":console.warn("@zxing/ngx-scanner",t.message),e=null,this.hasDevices.next(!1),this.camerasNotFound.next(t);break;case"NotReadableError":console.warn("@zxing/ngx-scanner","Couldn't read the device(s)'s stream, it's probably in use by another app."),e=null,this.hasDevices.next(!1),this.camerasNotFound.next(t);break;default:console.warn("@zxing/ngx-scanner","I was not able to define if I have permissions for camera or not.",t),e=null}return this.setPermission(e),this.permissionResponse.error(t),e}},{key:"getBarcodeFormatOrFail",value:function(t){return"string"==typeof t?u.BarcodeFormat[t.trim().toUpperCase()]:t}},{key:"getCodeReader",value:function(){return this._codeReader||(this._codeReader=new h(this.hints,this.timeBetweenScans)),this._codeReader}},{key:"scanFromDevice",value:function(t){var e=this,n=this.previewElemRef.nativeElement,i=this.getCodeReader().continuousDecodeFromInputVideoDevice(t,n);if(!i)throw new Error("Undefined decoding stream, aborting.");i.subscribe((function(t){return e._onDecodeResult(t.result,t.error)}),(function(t){return e._onDecodeError(t)}),(function(){e.reset(),console.log("completed")}))}},{key:"_onDecodeError",value:function(t){this.dispatchScanError(t),this.reset()}},{key:"_onDecodeResult",value:function(t,e){t?this.dispatchScanSuccess(t):this.dispatchScanFailure(e),this.dispatchScanComplete(t)}},{key:"_reset",value:function(){if(this._codeReader){var t=this.device;return this._device=null,this._codeReader.reset(),t}}},{key:"reset",value:function(){this._reset(),this.deviceChange.emit(null)}},{key:"setPermission",value:function(t){this.hasPermission=t,this.permissionResponse.next(t)}},{key:"codeReader",get:function(){return this._codeReader}},{key:"device",set:function(t){if(!t&&null!==t)throw new u.ArgumentException("The `device` must be a valid MediaDeviceInfo or null.");this.isCurrentDevice(t)?console.warn("Setting the same device is not allowed."):this.isAutostarting?console.warn("Avoid setting a device during auto-start."):(this.hasPermission||console.warn("Permissions not set yet, waiting for them to be set to apply device change."),this._reset(),this._device=t,this._enabled&&null!==t&&this.scanFromDevice(t.deviceId))},get:function(){return this._device}},{key:"formats",get:function(){return this.hints.get(u.DecodeHintType.POSSIBLE_FORMATS)},set:function(t){var e=this;if("string"==typeof t)throw new Error("Invalid formats, make sure the [formats] input is a binding.");var n=t.map((function(t){return e.getBarcodeFormatOrFail(t)})),i=this.hints;i.set(u.DecodeHintType.POSSIBLE_FORMATS,n),this.hints=i}},{key:"hints",get:function(){return this._hints},set:function(t){this._hints=t,this.restart()}},{key:"isAutostarting",set:function(t){this._isAutostarting=t,this.autostarting.next(t)},get:function(){return this._isAutostarting}},{key:"torch",set:function(t){this.getCodeReader().setTorch(t)}},{key:"enable",set:function(t){this._enabled=Boolean(t),this._enabled?this.device&&this.scanFromDevice(this.device.deviceId):this.reset()}},{key:"enabled",get:function(){return this._enabled}},{key:"tryHarder",get:function(){return this.hints.get(u.DecodeHintType.TRY_HARDER)},set:function(t){var e=this.hints;t?e.set(u.DecodeHintType.TRY_HARDER,!0):e.delete(u.DecodeHintType.TRY_HARDER),this.hints=e}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=o.Ib({type:t,selectors:[["zxing-scanner"]],viewQuery:function(t,e){var n;1&t&&o.Jc(d,!0),2&t&&o.zc(n=o.cc())&&(e.previewElemRef=n.first)},inputs:{timeBetweenScans:"timeBetweenScans",previewFitMode:"previewFitMode",autofocusEnabled:"autofocusEnabled",autostart:"autostart",formats:"formats",device:"device",torch:"torch",enable:"enable",tryHarder:"tryHarder"},outputs:{autostarted:"autostarted",autostarting:"autostarting",torchCompatible:"torchCompatible",scanSuccess:"scanSuccess",scanFailure:"scanFailure",scanError:"scanError",scanComplete:"scanComplete",camerasFound:"camerasFound",camerasNotFound:"camerasNotFound",permissionResponse:"permissionResponse",hasDevices:"hasDevices",deviceChange:"deviceChange"},decls:6,vars:2,consts:[["preview",""]],template:function(t,e){1&t&&(o.Ub(0,"video",null,0),o.Ub(2,"p"),o.Qc(3," Your browser does not support this feature, please try to upgrade it. "),o.Tb(),o.Ub(4,"p"),o.Qc(5," Seu navegador n\xe3o suporta este recurso, por favor tente atualiz\xe1-lo. "),o.Tb(),o.Tb()),2&t&&o.Lc("object-fit",e.previewFitMode)},styles:["[_nghost-%COMP%]{display:block}video[_ngcontent-%COMP%]{width:100%;height:auto;-o-object-fit:contain;object-fit:contain}"],changeDetection:0}),t}(),g=function(){var t=function t(){C(this,t)};return t.\u0275mod=o.Mb({type:t}),t.\u0275inj=o.Lb({factory:function(e){return new(e||t)},imports:[[r.c,s.j]]}),t}()},JtL9:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("FEHI"),r=n("Nxx2");e.default=function(){function t(t){this.errorCorrectionLevel=i.default.forBits(t>>3&3),this.dataMask=7&t}return t.numBitsDiffering=function(t,e){return r.default.bitCount(t^e)},t.decodeFormatInformation=function(e,n){var i=t.doDecodeFormatInformation(e,n);return null!==i?i:t.doDecodeFormatInformation(e^t.FORMAT_INFO_MASK_QR,n^t.FORMAT_INFO_MASK_QR)},t.doDecodeFormatInformation=function(e,n){for(var i=Number.MAX_SAFE_INTEGER,r=0,o=0,a=t.FORMAT_INFO_DECODE_LOOKUP;o0){var n=new i.default[e.length+t.length];r.default.arraycopy(e,0,n,0,e.length),r.default.arraycopy(t,0,n,e.length,t.length),this.resultPoints=n}},t.prototype.getTimestamp=function(){return this.timestamp},t.prototype.toString=function(){return this.text},t}();e.default=o},KQpv:function(t,e,n){e.log=function(){var t;return"object"==typeof console&&console.log&&(t=console).log.apply(t,arguments)},e.formatArgs=function(e){if(e[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+e[0]+(this.useColors?"%c ":" ")+"+"+t.exports.humanize(this.diff),this.useColors){var n="color: "+this.color;e.splice(1,0,n,"color: inherit");var i=0,r=0;e[0].replace(/%[a-zA-Z%]/g,(function(t){"%%"!==t&&(i++,"%c"===t&&(r=i))})),e.splice(r,0,n)}},e.save=function(t){try{t?e.storage.setItem("debug",t):e.storage.removeItem("debug")}catch(n){}},e.load=function(){var t;try{t=e.storage.getItem("debug")}catch(n){}return!t&&"undefined"!=typeof process&&"env"in process&&(t=process.env.DEBUG),t},e.useColors=function(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type&&!window.process.__nwjs)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},e.storage=function(){try{return localStorage}catch(t){}}(),e.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.exports=n("SC2c")(e),t.exports.formatters.j=function(t){try{return JSON.stringify(t)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}},KRZI:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("FU6l");function r(t){return!Object(i.a)(t)&&t-parseFloat(t)+1>=0}},KTx3:function(t,e,n){"use strict";n.d(e,"a",(function(){return s}));var i=n("IdLP"),r=n("FU6l"),o=n("IJgj"),a=n("YtkY");function s(t,e,n,c){return Object(o.a)(n)&&(c=n,n=void 0),c?s(t,e,n).pipe(Object(a.a)((function(t){return Object(r.a)(t)?c.apply(void 0,b(t)):c(t)}))):new i.a((function(i){!function t(e,n,i,r,o){var a;if(function(t){return t&&"function"==typeof t.addEventListener&&"function"==typeof t.removeEventListener}(e)){var s=e;e.addEventListener(n,i,o),a=function(){return s.removeEventListener(n,i,o)}}else if(function(t){return t&&"function"==typeof t.on&&"function"==typeof t.off}(e)){var c=e;e.on(n,i),a=function(){return c.off(n,i)}}else if(function(t){return t&&"function"==typeof t.addListener&&"function"==typeof t.removeListener}(e)){var u=e;e.addListener(n,i),a=function(){return u.removeListener(n,i)}}else{if(!e||!e.length)throw new TypeError("Invalid event target");for(var l=0,d=e.length;l1?Array.prototype.slice.call(arguments):t)}),i,n)}))}},KZGf:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(){function t(t){void 0===t&&(t=""),this.value=t}return t.prototype.append=function(t){return this.value+="string"==typeof t?t.toString():String.fromCharCode(t),this},t.prototype.length=function(){return this.value.length},t.prototype.charAt=function(t){return this.value.charAt(t)},t.prototype.deleteCharAt=function(t){this.value=this.value.substr(0,t)+this.value.substring(t+1)},t.prototype.setCharAt=function(t,e){this.value=this.value.substr(0,t)+e+this.value.substr(t+1)},t.prototype.toString=function(){return this.value},t.prototype.insert=function(t,e){this.value=this.value.substr(0,t)+e+this.value.substr(t+e.length)},t}()},Knqz:function(t,e,n){"use strict";n.d(e,"b",(function(){return r})),n.d(e,"a",(function(){return s}));var i=["","K","M","B","T","Z"];function r(t){if(t<1)return t.toString();var e=Math.log10(t)/3|0;if(0===e)return t.toPrecision(3);var n=i[e];return(t/Math.pow(10,3*e)).toPrecision(3)+n}var o,a=n("kZht"),s=((o=function(){function t(){C(this,t)}return w(t,[{key:"transform",value:function(t){return null==t?null:r(t)}}]),t}()).\u0275fac=function(t){return new(t||o)},o.\u0275pipe=a.Nb({name:"humanNumber",type:o,pure:!0}),o)},KyJX:function(t,e,n){"use strict";n.d(e,"a",(function(){return l})),n.d(e,"b",(function(){return f})),n.d(e,"c",(function(){return p})),n.d(e,"d",(function(){return b}));var i=n("zqNl"),r=n("1u95"),o=n("p5wL"),a=n("rxqU"),s=n("B59i"),c=n("+Px6"),u=Object(i.i)({initial:{buy:0,sell:0},edited:{buy:0,sell:0},bracket:{buy:0,sell:0}},Object(i.k)(r.e,(function(t,e){return Object(o.b)(e,t,"initial")})),Object(i.k)(r.d,(function(t,e){return Object(o.b)(e,t,"edited")})),Object(i.k)(r.c,(function(t,e){return Object(o.b)(e,t,"bracket")})));function l(t,e){return u(t,e)}var d=Object(i.h)("margin"),h=Object(i.j)(d,(function(t){return t.initial})),f=Object(i.j)(d,(function(t){return t.bracket})),p=Object(i.j)(d,(function(t){return t.edited})),b=Object(i.j)(h,a.a,c.a,(function(t,e,n){return Object(s.c)(t,e,n)}))},L09h:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("oznm"),r=e.ModeValues=function(t){return t[t.TERMINATOR=0]="TERMINATOR",t[t.NUMERIC=1]="NUMERIC",t[t.ALPHANUMERIC=2]="ALPHANUMERIC",t[t.STRUCTURED_APPEND=3]="STRUCTURED_APPEND",t[t.BYTE=4]="BYTE",t[t.ECI=5]="ECI",t[t.KANJI=6]="KANJI",t[t.FNC1_FIRST_POSITION=7]="FNC1_FIRST_POSITION",t[t.FNC1_SECOND_POSITION=8]="FNC1_SECOND_POSITION",t[t.HANZI=9]="HANZI",t}(e.ModeValues||{});e.default=function(){function t(e,n,i,r){this.value=e,this.stringValue=n,this.characterCountBitsForVersions=i,this.bits=r,t.FOR_BITS.set(r,this),t.FOR_VALUE.set(e,this)}return t.forBits=function(e){var n=t.FOR_BITS.get(e);if(void 0===n)throw new i.default;return n},t.prototype.getCharacterCountBits=function(t){var e=t.getVersionNumber();return this.characterCountBitsForVersions[e<=9?0:e<=26?1:2]},t.prototype.getValue=function(){return this.value},t.prototype.getBits=function(){return this.bits},t.prototype.equals=function(e){return e instanceof t&&this.value===e.value},t.prototype.toString=function(){return this.stringValue},t.FOR_BITS=new Map,t.FOR_VALUE=new Map,t.TERMINATOR=new t(r.TERMINATOR,"TERMINATOR",Int32Array.from([0,0,0]),0),t.NUMERIC=new t(r.NUMERIC,"NUMERIC",Int32Array.from([10,12,14]),1),t.ALPHANUMERIC=new t(r.ALPHANUMERIC,"ALPHANUMERIC",Int32Array.from([9,11,13]),2),t.STRUCTURED_APPEND=new t(r.STRUCTURED_APPEND,"STRUCTURED_APPEND",Int32Array.from([0,0,0]),3),t.BYTE=new t(r.BYTE,"BYTE",Int32Array.from([8,16,16]),4),t.ECI=new t(r.ECI,"ECI",Int32Array.from([0,0,0]),7),t.KANJI=new t(r.KANJI,"KANJI",Int32Array.from([8,10,12]),8),t.FNC1_FIRST_POSITION=new t(r.FNC1_FIRST_POSITION,"FNC1_FIRST_POSITION",Int32Array.from([0,0,0]),5),t.FNC1_SECOND_POSITION=new t(r.FNC1_SECOND_POSITION,"FNC1_SECOND_POSITION",Int32Array.from([0,0,0]),9),t.HANZI=new t(r.HANZI,"HANZI",Int32Array.from([8,10,12]),13),t}()},L20P:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("ZCEf"),r=n("Qkwj"),o=n("qArU"),a=n("e9V9"),s=n("9GlW"),c=n("dyLe"),u=n("TIRN"),l=n("4f+B"),d=n("0SRF"),h=n("LqyJ");e.default=function(){function t(t){this.image=t}return t.prototype.getImage=function(){return this.image},t.prototype.getResultPointCallback=function(){return this.resultPointCallback},t.prototype.detect=function(t){this.resultPointCallback=null==t?null:t.get(i.default.NEED_RESULT_POINT_CALLBACK);var e=new l.default(this.image,this.resultPointCallback).find(t);return this.processFinderPatternInfo(e)},t.prototype.processFinderPatternInfo=function(e){var n=e.getTopLeft(),i=e.getTopRight(),r=e.getBottomLeft(),a=this.calculateModuleSize(n,i,r);if(a<1)throw new h.default("No pattern found in proccess finder.");var s=t.computeDimension(n,i,r,a),c=u.default.getProvisionalVersionForDimension(s),l=c.getDimensionForVersion()-7,d=null;if(c.getAlignmentPatternCenters().length>0)for(var f=i.getX()-n.getX()+r.getX(),p=i.getY()-n.getY()+r.getY(),b=1-3/l,g=Math.floor(n.getX()+b*(f-n.getX())),m=Math.floor(n.getY()+b*(p-n.getY())),v=4;v<=16;v<<=1)try{d=this.findAlignmentInRegion(a,g,m,v);break}catch(O){if(!(O instanceof h.default))throw O}var y=t.createTransform(n,i,r,d,s),_=t.sampleGrid(this.image,y,s);return new o.default(_,null===d?[r,n,i]:[r,n,i,d])},t.createTransform=function(t,e,n,i,r){var o,a,c,u,l=r-3.5;return null!==i?(o=i.getX(),a=i.getY(),u=c=l-3):(o=e.getX()-t.getX()+n.getX(),a=e.getY()-t.getY()+n.getY(),c=l,u=l),s.default.quadrilateralToQuadrilateral(3.5,3.5,l,3.5,c,u,3.5,l,t.getX(),t.getY(),e.getX(),e.getY(),o,a,n.getX(),n.getY())},t.sampleGrid=function(t,e,n){return a.default.getInstance().sampleGridWithTransform(t,n,n,e)},t.computeDimension=function(t,e,n,i){var o=c.default.round(r.default.distance(t,e)/i),a=c.default.round(r.default.distance(t,n)/i),s=Math.floor((o+a)/2)+7;switch(3&s){case 0:s++;break;case 2:s--;break;case 3:throw new h.default("Dimensions could be not found.")}return s},t.prototype.calculateModuleSize=function(t,e,n){return(this.calculateModuleSizeOneWay(t,e)+this.calculateModuleSizeOneWay(t,n))/2},t.prototype.calculateModuleSizeOneWay=function(t,e){var n=this.sizeOfBlackWhiteBlackRunBothWays(Math.floor(t.getX()),Math.floor(t.getY()),Math.floor(e.getX()),Math.floor(e.getY())),i=this.sizeOfBlackWhiteBlackRunBothWays(Math.floor(e.getX()),Math.floor(e.getY()),Math.floor(t.getX()),Math.floor(t.getY()));return isNaN(n)?i/7:isNaN(i)?n/7:(n+i)/14},t.prototype.sizeOfBlackWhiteBlackRunBothWays=function(t,e,n,i){var r=this.sizeOfBlackWhiteBlackRun(t,e,n,i),o=1,a=t-(n-t);a<0?(o=t/(t-a),a=0):a>=this.image.getWidth()&&(o=(this.image.getWidth()-1-t)/(a-t),a=this.image.getWidth()-1);var s=Math.floor(e-(i-e)*o);return o=1,s<0?(o=e/(e-s),s=0):s>=this.image.getHeight()&&(o=(this.image.getHeight()-1-e)/(s-e),s=this.image.getHeight()-1),a=Math.floor(t+(a-t)*o),(r+=this.sizeOfBlackWhiteBlackRun(t,e,a,s))-1},t.prototype.sizeOfBlackWhiteBlackRun=function(t,e,n,i){var r=Math.abs(i-e)>Math.abs(n-t);if(r){var o=t;t=e,e=o,o=n,n=i,i=o}for(var a=Math.abs(n-t),s=Math.abs(i-e),u=-a/2,l=t0){if(b===i)break;b+=d,u-=a}}return 2===h?c.default.distance(n+l,i,t,e):NaN},t.prototype.findAlignmentInRegion=function(t,e,n,i){var r=Math.floor(i*t),o=Math.max(0,e-r),a=Math.min(this.image.getWidth()-1,e+r);if(a-o<3*t)throw new h.default("Alignment top exceeds estimated module size.");var s=Math.max(0,n-r),c=Math.min(this.image.getHeight()-1,n+r);if(c-s<3*t)throw new h.default("Alignment bottom exceeds estimated module size.");return new d.default(this.image,o,s,a-o,c-s,t,this.resultPointCallback).find()},t}()},LBlH:function(t,e,n){"use strict";n.d(e,"a",(function(){return b}));var i=n("kZht"),r=n("KQpv"),o=n.n(r),a=n("ZtZA"),s=n("5OT+"),c=n("+6xv"),u=[Object(c.n)("slideInOut",[Object(c.k)("show",Object(c.l)({transform:"translateY(0)",opacity:1})),Object(c.m)(":enter",[Object(c.l)({transform:"translateY(-10px)",opacity:0}),Object(c.e)("300ms ease-out")]),Object(c.m)(":leave",[Object(c.e)("300ms ease-in"),Object(c.l)({transform:"translateY(10px)",opacity:0})])])],l=n("5GZx"),d=n("An66");function h(t,e){if(1&t&&(i.Ub(0,"div",0),i.Ub(1,"div",1),i.Qb(2,2),i.Tb(),i.Tb()),2&t){var n=i.fc();i.mc("@slideInOut","show"),i.Cb(2),i.mc("ngTemplateOutlet",n.content)}}var f,p=o()("sb:popper"),b=((f=function(){function t(e,n,i){C(this,t),this.overlay=e,this.vcr=n,this.placement=i,this.hasBackdrop=!0}return w(t,[{key:"componentTrigger",value:function(t,e){p("manual popper opening anchored to",t);var n=[s.e[e]],i=this.overlay.position().flexibleConnectedTo(t).withPositions(n).withPush(!1);this.trigger(i)}},{key:"centerTrigger",value:function(){var t=this.overlay.position().global().centerHorizontally().centerVertically();this.trigger(t)}},{key:"trigger",value:function(t){var e=this.overlay.create({positionStrategy:t,hasBackdrop:this.hasBackdrop,backdropClass:this.backdropClass,panelClass:this.panelClass});e.backdropClick().subscribe((function(t){return e.dispose()}));var n=new a.h(this.tmpl,this.vcr);e.attach(n),this.overlayRef=e}},{key:"onTrigger",value:function(t){var e,n,i=t.trigger,r=t.event;t.data,p("popper opening anchored to",i,r);var o=null!==(n=null===(e=this.placement)||void 0===e?void 0:e.connectedPositions())&&void 0!==n?n:[s.e.bottomStart],a=this.overlay.position().flexibleConnectedTo(i.vcr.element).withPositions(o).withPush(!1);this.trigger(a)}},{key:"dispose",value:function(){var t;null===(t=this.overlayRef)||void 0===t||t.dispose()}}]),t}()).\u0275fac=function(t){return new(t||f)(i.Ob(l.c),i.Ob(i.R),i.Ob(s.c,9))},f.\u0275cmp=i.Ib({type:f,selectors:[["sb-popper"]],contentQueries:function(t,e,n){var r;1&t&&i.Hb(n,i.N,!0),2&t&&i.zc(r=i.cc())&&(e.content=r.first)},viewQuery:function(t,e){var n;1&t&&i.Wc(i.N,!0),2&t&&i.zc(n=i.cc())&&(e.tmpl=n.first)},inputs:{panelClass:["sbPopperClass","panelClass"],hasBackdrop:["sbPopperBackdrop","hasBackdrop"],backdropClass:["sbPopperBackdropClass","backdropClass"]},exportAs:["sbPopper"],decls:1,vars:0,consts:[[1,"sb-popper"],[1,"sb-popper-content"],[3,"ngTemplateOutlet"]],template:function(t,e){1&t&&i.Oc(0,h,3,2,"ng-template")},directives:[d.s],styles:[".sb-popper[_ngcontent-%COMP%]{overflow:hidden;background-color:var(--card-colour);border:1px solid var(--border-colour);border-radius:var(--bdrs)}"],data:{animation:[u]},changeDetection:0}),f)},LBoB:function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0});var o=n("4Pxi"),a=n("ZCEf"),s=n("KFdt"),c=n("Qkwj"),u=n("iiuT"),l=n("LqyJ"),d=n("nB6u"),h=n("sPys");e.default=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.findStartPattern=function(t){for(var n=t.getSize(),i=t.getNextSet(0),r=0,o=[0,0,0,0,0,0],a=i,s=!1,c=i;c=0&&t.isRange(Math.max(0,a-(c-a)/2),a,!1))return[a,c,h];a+=o[0]+o[1],o.splice(0,2),o[r-1]=0,o[r]=0,r--}else r++;o[r]=1,s=!s}throw new l.default},e.decodeCode=function(t,n,i){u.default.recordPattern(t,i,n);for(var r=e.MAX_AVG_VARIANCE,o=-1,a=0;a=0)return o;throw new l.default},e.prototype.decodeRow=function(t,n,i){var r,u=i&&!0===i.get(a.default.ASSUME_GS1),f=e.findStartPattern(n),p=f[2],b=0,g=new Uint8Array(20);switch(g[b++]=p,p){case e.CODE_START_A:r=e.CODE_CODE_A;break;case e.CODE_START_B:r=e.CODE_CODE_B;break;case e.CODE_START_C:r=e.CODE_CODE_C;break;default:throw new d.default}for(var m=!1,v=!1,y="",_=f[0],O=f[1],k=[0,0,0,0,0,0],w=0,C=0,T=p,S=0,E=!0,x=!1,P=!1;!m;){var A=v;switch(v=!1,w=C,C=e.decodeCode(n,k,O),g[b++]=C,C!==e.CODE_STOP&&(E=!0),C!==e.CODE_STOP&&(T+=++S*C),_=O,O+=k.reduce((function(t,e){return t+e}),0),C){case e.CODE_START_A:case e.CODE_START_B:case e.CODE_START_C:throw new d.default}switch(r){case e.CODE_CODE_A:if(C<64)y+=String.fromCharCode(P===x?" ".charCodeAt(0)+C:" ".charCodeAt(0)+C+128),P=!1;else if(C<96)y+=String.fromCharCode(P===x?C-64:C+64),P=!1;else switch(C!==e.CODE_STOP&&(E=!1),C){case e.CODE_FNC_1:u&&(y+=0===y.length?"]C1":String.fromCharCode(29));break;case e.CODE_FNC_2:case e.CODE_FNC_3:break;case e.CODE_FNC_4_A:!x&&P?(x=!0,P=!1):x&&P?(x=!1,P=!1):P=!0;break;case e.CODE_SHIFT:v=!0,r=e.CODE_CODE_B;break;case e.CODE_CODE_B:r=e.CODE_CODE_B;break;case e.CODE_CODE_C:r=e.CODE_CODE_C;break;case e.CODE_STOP:m=!0}break;case e.CODE_CODE_B:if(C<96)y+=String.fromCharCode(P===x?" ".charCodeAt(0)+C:" ".charCodeAt(0)+C+128),P=!1;else switch(C!==e.CODE_STOP&&(E=!1),C){case e.CODE_FNC_1:u&&(y+=0===y.length?"]C1":String.fromCharCode(29));break;case e.CODE_FNC_2:case e.CODE_FNC_3:break;case e.CODE_FNC_4_B:!x&&P?(x=!0,P=!1):x&&P?(x=!1,P=!1):P=!0;break;case e.CODE_SHIFT:v=!0,r=e.CODE_CODE_A;break;case e.CODE_CODE_A:r=e.CODE_CODE_A;break;case e.CODE_CODE_C:r=e.CODE_CODE_C;break;case e.CODE_STOP:m=!0}break;case e.CODE_CODE_C:if(C<100)C<10&&(y+="0"),y+=C;else switch(C!==e.CODE_STOP&&(E=!1),C){case e.CODE_FNC_1:u&&(y+=0===y.length?"]C1":String.fromCharCode(29));break;case e.CODE_CODE_A:r=e.CODE_CODE_A;break;case e.CODE_CODE_B:r=e.CODE_CODE_B;break;case e.CODE_STOP:m=!0}}A&&(r=r===e.CODE_CODE_A?e.CODE_CODE_B:e.CODE_CODE_A)}var I=O-_;if(O=n.getNextUnset(O),!n.isRange(O,Math.min(n.getSize(),O+(O-_)/2),!1))throw new l.default;if((T-=S*w)%103!==w)throw new h.default;var M=y.length;if(0===M)throw new l.default;M>0&&E&&(y=y.substring(0,r===e.CODE_CODE_C?M-2:M-1));for(var D=(f[1]+f[0])/2,R=_+I/2,j=g.length,L=new Uint8Array(j),N=0;N0},t.prototype.connect_=function(){r&&!this.connected_&&(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),c?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},t.prototype.disconnect_=function(){r&&this.connected_&&(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},t.prototype.onTransitionEnd_=function(t){var e=t.propertyName,n=void 0===e?"":e;s.some((function(t){return!!~n.indexOf(t)}))&&this.refresh()},t.getInstance=function(){return this.instance_||(this.instance_=new t),this.instance_},t.instance_=null,t}(),l=function(t,e){for(var n=0,i=Object.keys(e);n0},t}(),_="undefined"!=typeof WeakMap?new WeakMap:new i,O=function t(e){if(!(this instanceof t))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var n=u.getInstance(),i=new y(e,n,this);_.set(this,i)};["observe","unobserve","disconnect"].forEach((function(t){O.prototype[t]=function(){var e;return(e=_.get(this))[t].apply(e,arguments)}})),e.a=void 0!==o.ResizeObserver?o.ResizeObserver:O},LbKT:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("kZht"),r=function(){var t=function(){function t(e,n){C(this,t),this.renderer=e,this.element=n,this.pnl=0,this.pnlZero=!1}return w(t,[{key:"ngOnChanges",value:function(){this.renderer.removeClass(this.element.nativeElement,"global__text--accent"),this.renderer.removeClass(this.element.nativeElement,"global__text--warn"),this.renderer.removeClass(this.element.nativeElement,"global__text--link"),this.pnl>0?this.renderer.addClass(this.element.nativeElement,"global__text--accent"):this.pnl<0?this.renderer.addClass(this.element.nativeElement,"global__text--warn"):(this.pnlZero||""===this.pnlZero)&&this.renderer.addClass(this.element.nativeElement,"global__text--link")}}]),t}();return t.\u0275fac=function(e){return new(e||t)(i.Ob(i.G),i.Ob(i.l))},t.\u0275dir=i.Jb({type:t,selectors:[["","pnl",""]],inputs:{pnl:"pnl",pnlZero:"pnlZero"},features:[i.Ab]}),t}()},LoUP:function(t,e,n){"use strict";n.d(e,"a",(function(){return v})),n.d(e,"b",(function(){return E})),n.d(e,"c",(function(){return x}));var i=n("kZht"),r=n("5XID"),o=n("pTnX"),s=n("jL3B"),u=n("Hq54"),l=n("ZTXN"),d=n("g6G6"),h=n("+6xv"),f=n("An66"),p=["mat-sort-header",""];function b(t,e){if(1&t){var n=i.Vb();i.Ub(0,"div",3),i.bc("@arrowPosition.start",(function(){return i.Ec(n),i.fc()._disableViewStateAnimation=!0}))("@arrowPosition.done",(function(){return i.Ec(n),i.fc()._disableViewStateAnimation=!1})),i.Pb(1,"div",4),i.Ub(2,"div",5),i.Pb(3,"div",6),i.Pb(4,"div",7),i.Pb(5,"div",8),i.Tb(),i.Tb()}if(2&t){var r=i.fc();i.mc("@arrowOpacity",r._getArrowViewState())("@arrowPosition",r._getArrowViewState())("@allowChildren",r._getArrowDirectionState()),i.Cb(2),i.mc("@indicator",r._getArrowDirectionState()),i.Cb(1),i.mc("@leftPointer",r._getArrowDirectionState()),i.Cb(1),i.mc("@rightPointer",r._getArrowDirectionState())}}var g=["*"],m=Object(o.A)(Object(o.y)((function t(){C(this,t)}))),v=function(){var t=function(t){a(n,t);var e=c(n);function n(){var t;return C(this,n),(t=e.apply(this,arguments)).sortables=new Map,t._stateChanges=new l.b,t.start="asc",t._direction="",t.sortChange=new i.o,t}return w(n,[{key:"register",value:function(t){this.sortables.set(t.id,t)}},{key:"deregister",value:function(t){this.sortables.delete(t.id)}},{key:"sort",value:function(t){this.active!=t.id?(this.active=t.id,this.direction=t.start?t.start:this.start):this.direction=this.getNextSortDirection(t),this.sortChange.emit({active:this.active,direction:this.direction})}},{key:"getNextSortDirection",value:function(t){if(!t)return"";var e,n,i,r=(e=t.start||this.start,n=null!=t.disableClear?t.disableClear:this.disableClear,i=["asc","desc"],"desc"==e&&i.reverse(),n||i.push(""),i),o=r.indexOf(this.direction)+1;return o>=r.length&&(o=0),r[o]}},{key:"ngOnInit",value:function(){this._markInitialized()}},{key:"ngOnChanges",value:function(){this._stateChanges.next()}},{key:"ngOnDestroy",value:function(){this._stateChanges.complete()}},{key:"direction",get:function(){return this._direction},set:function(t){this._direction=t}},{key:"disableClear",get:function(){return this._disableClear},set:function(t){this._disableClear=Object(r.c)(t)}}]),n}(m);return t.\u0275fac=function(e){return y(e||t)},t.\u0275dir=i.Jb({type:t,selectors:[["","matSort",""]],hostAttrs:[1,"mat-sort"],inputs:{disabled:["matSortDisabled","disabled"],start:["matSortStart","start"],direction:["matSortDirection","direction"],disableClear:["matSortDisableClear","disableClear"],active:["matSortActive","active"]},outputs:{sortChange:"matSortChange"},exportAs:["matSort"],features:[i.zb,i.Ab]}),t}(),y=i.Wb(v),_=o.b.ENTERING+" "+o.a.STANDARD_CURVE,O={indicator:Object(h.n)("indicator",[Object(h.k)("active-asc, asc",Object(h.l)({transform:"translateY(0px)"})),Object(h.k)("active-desc, desc",Object(h.l)({transform:"translateY(10px)"})),Object(h.m)("active-asc <=> active-desc",Object(h.e)(_))]),leftPointer:Object(h.n)("leftPointer",[Object(h.k)("active-asc, asc",Object(h.l)({transform:"rotate(-45deg)"})),Object(h.k)("active-desc, desc",Object(h.l)({transform:"rotate(45deg)"})),Object(h.m)("active-asc <=> active-desc",Object(h.e)(_))]),rightPointer:Object(h.n)("rightPointer",[Object(h.k)("active-asc, asc",Object(h.l)({transform:"rotate(45deg)"})),Object(h.k)("active-desc, desc",Object(h.l)({transform:"rotate(-45deg)"})),Object(h.m)("active-asc <=> active-desc",Object(h.e)(_))]),arrowOpacity:Object(h.n)("arrowOpacity",[Object(h.k)("desc-to-active, asc-to-active, active",Object(h.l)({opacity:1})),Object(h.k)("desc-to-hint, asc-to-hint, hint",Object(h.l)({opacity:.54})),Object(h.k)("hint-to-desc, active-to-desc, desc, hint-to-asc, active-to-asc, asc, void",Object(h.l)({opacity:0})),Object(h.m)("* => asc, * => desc, * => active, * => hint, * => void",Object(h.e)("0ms")),Object(h.m)("* <=> *",Object(h.e)(_))]),arrowPosition:Object(h.n)("arrowPosition",[Object(h.m)("* => desc-to-hint, * => desc-to-active",Object(h.e)(_,Object(h.h)([Object(h.l)({transform:"translateY(-25%)"}),Object(h.l)({transform:"translateY(0)"})]))),Object(h.m)("* => hint-to-desc, * => active-to-desc",Object(h.e)(_,Object(h.h)([Object(h.l)({transform:"translateY(0)"}),Object(h.l)({transform:"translateY(25%)"})]))),Object(h.m)("* => asc-to-hint, * => asc-to-active",Object(h.e)(_,Object(h.h)([Object(h.l)({transform:"translateY(25%)"}),Object(h.l)({transform:"translateY(0)"})]))),Object(h.m)("* => hint-to-asc, * => active-to-asc",Object(h.e)(_,Object(h.h)([Object(h.l)({transform:"translateY(0)"}),Object(h.l)({transform:"translateY(-25%)"})]))),Object(h.k)("desc-to-hint, asc-to-hint, hint, desc-to-active, asc-to-active, active",Object(h.l)({transform:"translateY(0)"})),Object(h.k)("hint-to-desc, active-to-desc, desc",Object(h.l)({transform:"translateY(-25%)"})),Object(h.k)("hint-to-asc, active-to-asc, asc",Object(h.l)({transform:"translateY(25%)"}))]),allowChildren:Object(h.n)("allowChildren",[Object(h.m)("* <=> *",[Object(h.i)("@*",Object(h.f)(),{optional:!0})])])},k=function(){var t=function t(){C(this,t),this.changes=new l.b,this.sortButtonLabel=function(t){return"Change sorting for "+t}};return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=Object(i.Kb)({factory:function(){return new t},token:t,providedIn:"root"}),t}(),T={provide:k,deps:[[new i.C,new i.L,k]],useFactory:function(t){return t||new k}},S=Object(o.y)((function t(){C(this,t)})),E=function(){var t=function(t){a(n,t);var e=c(n);function n(t,i,r,o,a,s){var c;return C(this,n),(c=e.call(this))._intl=t,c._sort=r,c._columnDef=o,c._focusMonitor=a,c._elementRef=s,c._showIndicatorHint=!1,c._arrowDirection="",c._disableViewStateAnimation=!1,c.arrowPosition="after",c._rerenderSubscription=Object(d.a)(r.sortChange,r._stateChanges,t.changes).subscribe((function(){c._isSorted()&&c._updateArrowDirection(),!c._isSorted()&&c._viewState&&"active"===c._viewState.toState&&(c._disableViewStateAnimation=!1,c._setAnimationTransitionState({fromState:"active",toState:c._arrowDirection})),i.markForCheck()})),c}return w(n,[{key:"ngOnInit",value:function(){!this.id&&this._columnDef&&(this.id=this._columnDef.name),this._updateArrowDirection(),this._setAnimationTransitionState({toState:this._isSorted()?"active":this._arrowDirection}),this._sort.register(this)}},{key:"ngAfterViewInit",value:function(){var t=this;this._focusMonitor.monitor(this._elementRef,!0).subscribe((function(e){return t._setIndicatorHintVisible(!!e)}))}},{key:"ngOnDestroy",value:function(){this._focusMonitor.stopMonitoring(this._elementRef),this._sort.deregister(this),this._rerenderSubscription.unsubscribe()}},{key:"_setIndicatorHintVisible",value:function(t){this._isDisabled()&&t||(this._showIndicatorHint=t,this._isSorted()||(this._updateArrowDirection(),this._setAnimationTransitionState(this._showIndicatorHint?{fromState:this._arrowDirection,toState:"hint"}:{fromState:"hint",toState:this._arrowDirection})))}},{key:"_setAnimationTransitionState",value:function(t){this._viewState=t,this._disableViewStateAnimation&&(this._viewState={toState:t.toState})}},{key:"_toggleOnInteraction",value:function(){this._sort.sort(this),"hint"!==this._viewState.toState&&"active"!==this._viewState.toState||(this._disableViewStateAnimation=!0);var t=this._isSorted()?{fromState:this._arrowDirection,toState:"active"}:{fromState:"active",toState:this._arrowDirection};this._setAnimationTransitionState(t),this._showIndicatorHint=!1}},{key:"_handleClick",value:function(){this._isDisabled()||this._toggleOnInteraction()}},{key:"_handleKeydown",value:function(t){this._isDisabled()||t.keyCode!==u.m&&t.keyCode!==u.e||(t.preventDefault(),this._toggleOnInteraction())}},{key:"_isSorted",value:function(){return this._sort.active==this.id&&("asc"===this._sort.direction||"desc"===this._sort.direction)}},{key:"_getArrowDirectionState",value:function(){return"".concat(this._isSorted()?"active-":"").concat(this._arrowDirection)}},{key:"_getArrowViewState",value:function(){var t=this._viewState.fromState;return(t?t+"-to-":"")+this._viewState.toState}},{key:"_updateArrowDirection",value:function(){this._arrowDirection=this._isSorted()?this._sort.direction:this.start||this._sort.start}},{key:"_isDisabled",value:function(){return this._sort.disabled||this.disabled}},{key:"_getAriaSortAttribute",value:function(){return this._isSorted()?"asc"==this._sort.direction?"ascending":"descending":"none"}},{key:"_renderArrow",value:function(){return!this._isDisabled()||this._isSorted()}},{key:"disableClear",get:function(){return this._disableClear},set:function(t){this._disableClear=Object(r.c)(t)}}]),n}(S);return t.\u0275fac=function(e){return new(e||t)(i.Ob(k),i.Ob(i.h),i.Ob(v,8),i.Ob("MAT_SORT_HEADER_COLUMN_DEF",8),i.Ob(s.h),i.Ob(i.l))},t.\u0275cmp=i.Ib({type:t,selectors:[["","mat-sort-header",""]],hostAttrs:[1,"mat-sort-header"],hostVars:3,hostBindings:function(t,e){1&t&&i.bc("click",(function(){return e._handleClick()}))("keydown",(function(t){return e._handleKeydown(t)}))("mouseenter",(function(){return e._setIndicatorHintVisible(!0)}))("mouseleave",(function(){return e._setIndicatorHintVisible(!1)})),2&t&&(i.Db("aria-sort",e._getAriaSortAttribute()),i.Gb("mat-sort-header-disabled",e._isDisabled()))},inputs:{disabled:"disabled",arrowPosition:"arrowPosition",disableClear:"disableClear",id:["mat-sort-header","id"],start:"start"},exportAs:["matSortHeader"],features:[i.zb],attrs:p,ngContentSelectors:g,decls:4,vars:6,consts:[["role","button",1,"mat-sort-header-container","mat-focus-indicator"],[1,"mat-sort-header-content"],["class","mat-sort-header-arrow",4,"ngIf"],[1,"mat-sort-header-arrow"],[1,"mat-sort-header-stem"],[1,"mat-sort-header-indicator"],[1,"mat-sort-header-pointer-left"],[1,"mat-sort-header-pointer-right"],[1,"mat-sort-header-pointer-middle"]],template:function(t,e){1&t&&(i.lc(),i.Ub(0,"div",0),i.Ub(1,"div",1),i.kc(2),i.Tb(),i.Oc(3,b,6,6,"div",2),i.Tb()),2&t&&(i.Gb("mat-sort-header-sorted",e._isSorted())("mat-sort-header-position-before","before"==e.arrowPosition),i.Db("tabindex",e._isDisabled()?null:0),i.Cb(3),i.mc("ngIf",e._renderArrow()))},directives:[f.n],styles:[".mat-sort-header-container{display:flex;cursor:pointer;align-items:center;letter-spacing:normal;outline:0}[mat-sort-header].cdk-keyboard-focused .mat-sort-header-container,[mat-sort-header].cdk-program-focused .mat-sort-header-container{border-bottom:solid 1px currentColor}.mat-sort-header-disabled .mat-sort-header-container{cursor:default}.mat-sort-header-content{text-align:center;display:flex;align-items:center}.mat-sort-header-position-before{flex-direction:row-reverse}.mat-sort-header-arrow{height:12px;width:12px;min-width:12px;position:relative;display:flex;opacity:0}.mat-sort-header-arrow,[dir=rtl] .mat-sort-header-position-before .mat-sort-header-arrow{margin:0 0 0 6px}.mat-sort-header-position-before .mat-sort-header-arrow,[dir=rtl] .mat-sort-header-arrow{margin:0 6px 0 0}.mat-sort-header-stem{background:currentColor;height:10px;width:2px;margin:auto;display:flex;align-items:center}.cdk-high-contrast-active .mat-sort-header-stem{width:0;border-left:solid 2px}.mat-sort-header-indicator{width:100%;height:2px;display:flex;align-items:center;position:absolute;top:0;left:0}.mat-sort-header-pointer-middle{margin:auto;height:2px;width:2px;background:currentColor;transform:rotate(45deg)}.cdk-high-contrast-active .mat-sort-header-pointer-middle{width:0;height:0;border-top:solid 2px;border-left:solid 2px}.mat-sort-header-pointer-left,.mat-sort-header-pointer-right{background:currentColor;width:6px;height:2px;position:absolute;top:0}.cdk-high-contrast-active .mat-sort-header-pointer-left,.cdk-high-contrast-active .mat-sort-header-pointer-right{width:0;height:0;border-left:solid 6px;border-top:solid 2px}.mat-sort-header-pointer-left{transform-origin:right;left:0}.mat-sort-header-pointer-right{transform-origin:left;right:0}\n"],encapsulation:2,data:{animation:[O.indicator,O.leftPointer,O.rightPointer,O.arrowOpacity,O.arrowPosition,O.allowChildren]},changeDetection:0}),t}(),x=function(){var t=function t(){C(this,t)};return t.\u0275mod=i.Mb({type:t}),t.\u0275inj=i.Lb({factory:function(e){return new(e||t)},providers:[T],imports:[[f.c]]}),t}()},LqyJ:function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0});var o=n("w6/c");e.default=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e}(o.default)},LxLQ:function(t,e){function n(){this.buffer=[],this.length=0}n.prototype={get:function(t){var e=Math.floor(t/8);return 1==(this.buffer[e]>>>7-t%8&1)},put:function(t,e){for(var n=0;n>>e-n-1&1))},getLengthInBits:function(){return this.length},putBit:function(t){var e=Math.floor(this.length/8);this.buffer.length<=e&&this.buffer.push(0),t&&(this.buffer[e]|=128>>>this.length%8),this.length++}},t.exports=n},"M/Eb":function(t,e,n){"use strict";n.d(e,"c",(function(){return s})),n.d(e,"b",(function(){return c})),n.d(e,"d",(function(){return u})),n.d(e,"e",(function(){return l})),n.d(e,"a",(function(){return d}));var i=n("og7C"),r=n("TYVA"),o=n("Gbfs"),a=n("pjhv");function s(t){return t.filter((function(t){return t.tradeable&&t.type.includes("futures")}))}function c(t){return t.filter((function(t){return"flexible_futures"!==t.type}))}function u(t){return function(e){return e.filter((function(e){return!t.includes(e.symbol)}))}}function l(t){return t.map((function(t){var e=Object(a.c)(t);return Object.assign(Object.assign({},t),{symbol:t.symbol.toUpperCase(),contractValueTradePrecision:t.contractValueTradePrecision||0,numericPrecision:{short:e,full:e},numericFormat:{short:Object(a.d)(e),full:Object(a.d)(e)}})}))}function d(t){return b(t.reduce((function(t,e){var n=Object(r.u)(e.symbol).parts.currencies,i=n.base,o=n.quote;return t.withMutations((function(t){t.add(i),t.add(o)})).asImmutable()}),Object(i.f)()).asImmutable().toMap().map(o.b).values())}},MRfT:function(t,e,n){"use strict";n.d(e,"a",(function(){return M})),n.d(e,"b",(function(){return P}));var i=n("kZht"),r=n("+6xv"),o=n("ZTXN"),s=n("ENSU"),u=n("An66"),l=["toast-component",""];function d(t,e){if(1&t){var n=i.Vb();i.Ub(0,"button",5),i.bc("click",(function(){return i.Ec(n),i.fc().remove()})),i.Ub(1,"span",6),i.Qc(2,"\xd7"),i.Tb(),i.Tb()}}function h(t,e){if(1&t&&(i.Sb(0),i.Qc(1),i.Rb()),2&t){var n=i.fc(2);i.Cb(1),i.Sc("[",n.duplicatesCount+1,"]")}}function f(t,e){if(1&t&&(i.Ub(0,"div"),i.Qc(1),i.Oc(2,h,2,1,"ng-container",4),i.Tb()),2&t){var n=i.fc();i.Eb(n.options.titleClass),i.Db("aria-label",n.title),i.Cb(1),i.Sc(" ",n.title," "),i.Cb(1),i.mc("ngIf",n.duplicatesCount)}}function b(t,e){if(1&t&&i.Pb(0,"div",7),2&t){var n=i.fc();i.Eb(n.options.messageClass),i.mc("innerHTML",n.message,i.Fc)}}function g(t,e){if(1&t&&(i.Ub(0,"div",8),i.Qc(1),i.Tb()),2&t){var n=i.fc();i.Eb(n.options.messageClass),i.Db("aria-label",n.message),i.Cb(1),i.Sc(" ",n.message," ")}}function m(t,e){if(1&t&&(i.Ub(0,"div"),i.Pb(1,"div",9),i.Tb()),2&t){var n=i.fc();i.Cb(1),i.Lc("width",n.width+"%")}}var v=function(){function t(e,n,i,r,a,s){var c=this;C(this,t),this.toastId=e,this.config=n,this.message=i,this.title=r,this.toastType=a,this.toastRef=s,this._onTap=new o.b,this._onAction=new o.b,this.toastRef.afterClosed().subscribe((function(){c._onAction.complete(),c._onTap.complete()}))}return w(t,[{key:"triggerTap",value:function(){this._onTap.next(),this.config.tapToDismiss&&this._onTap.complete()}},{key:"onTap",value:function(){return this._onTap.asObservable()}},{key:"triggerAction",value:function(t){this._onAction.next(t)}},{key:"onAction",value:function(){return this._onAction.asObservable()}}]),t}(),y=new i.s("ToastConfig"),_=function(){function t(e,n){C(this,t),this.component=e,this.injector=n}return w(t,[{key:"attach",value:function(t,e){return this._attachedHost=t,t.attach(this,e)}},{key:"detach",value:function(){var t=this._attachedHost;if(t)return this._attachedHost=void 0,t.detach()}},{key:"setAttachedHost",value:function(t){this._attachedHost=t}},{key:"isAttached",get:function(){return null!=this._attachedHost}}]),t}(),O=function(t){a(n,t);var e=c(n);function n(t,i,r){var o;return C(this,n),(o=e.call(this))._hostDomElement=t,o._componentFactoryResolver=i,o._appRef=r,o}return w(n,[{key:"attachComponentPortal",value:function(t,e){var n,i=this,r=this._componentFactoryResolver.resolveComponentFactory(t.component);return n=r.create(t.injector),this._appRef.attachView(n.hostView),this.setDisposeFn((function(){i._appRef.detachView(n.hostView),n.destroy()})),e?this._hostDomElement.insertBefore(this._getComponentRootNode(n),this._hostDomElement.firstChild):this._hostDomElement.appendChild(this._getComponentRootNode(n)),n}},{key:"_getComponentRootNode",value:function(t){return t.hostView.rootNodes[0]}}]),n}(function(){function t(){C(this,t)}return w(t,[{key:"attach",value:function(t,e){return this._attachedPortal=t,this.attachComponentPortal(t,e)}},{key:"detach",value:function(){this._attachedPortal&&this._attachedPortal.setAttachedHost(),this._attachedPortal=void 0,this._disposeFn&&(this._disposeFn(),this._disposeFn=void 0)}},{key:"setDisposeFn",value:function(t){this._disposeFn=t}}]),t}()),k=function(){var t=function(){function t(e){C(this,t),this._document=e}return w(t,[{key:"ngOnDestroy",value:function(){this._containerElement&&this._containerElement.parentNode&&this._containerElement.parentNode.removeChild(this._containerElement)}},{key:"getContainerElement",value:function(){return this._containerElement||this._createContainer(),this._containerElement}},{key:"_createContainer",value:function(){var t=this._document.createElement("div");t.classList.add("overlay-container"),this._document.body.appendChild(t),this._containerElement=t}}]),t}();return t.\u0275fac=function(e){return new(e||t)(i.Yb(u.d))},t.\u0275prov=Object(i.Kb)({factory:function(){return new t(Object(i.Yb)(u.d))},token:t,providedIn:"root"}),t}(),T=function(){function t(e){C(this,t),this._portalHost=e}return w(t,[{key:"attach",value:function(t){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return this._portalHost.attach(t,e)}},{key:"detach",value:function(){return this._portalHost.detach()}}]),t}(),S=function(){var t=function(){function t(e,n,i,r){C(this,t),this._overlayContainer=e,this._componentFactoryResolver=n,this._appRef=i,this._document=r,this._paneElements=new Map}return w(t,[{key:"create",value:function(t,e){return this._createOverlayRef(this.getPaneElement(t,e))}},{key:"getPaneElement",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=arguments.length>1?arguments[1]:void 0;return this._paneElements.get(e)||this._paneElements.set(e,{}),this._paneElements.get(e)[t]||(this._paneElements.get(e)[t]=this._createPaneElement(t,e)),this._paneElements.get(e)[t]}},{key:"_createPaneElement",value:function(t,e){var n=this._document.createElement("div");return n.id="toast-container",n.classList.add(t),n.classList.add("toast-container"),e?e.getContainerElement().appendChild(n):this._overlayContainer.getContainerElement().appendChild(n),n}},{key:"_createPortalHost",value:function(t){return new O(t,this._componentFactoryResolver,this._appRef)}},{key:"_createOverlayRef",value:function(t){return new T(this._createPortalHost(t))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(i.Yb(k),i.Yb(i.j),i.Yb(i.g),i.Yb(u.d))},t.\u0275prov=Object(i.Kb)({factory:function(){return new t(Object(i.Yb)(k),Object(i.Yb)(i.j),Object(i.Yb)(i.g),Object(i.Yb)(u.d))},token:t,providedIn:"root"}),t}(),E=function(){function t(e){C(this,t),this._overlayRef=e,this.duplicatesCount=0,this._afterClosed=new o.b,this._activate=new o.b,this._manualClose=new o.b,this._resetTimeout=new o.b,this._countDuplicate=new o.b}return w(t,[{key:"manualClose",value:function(){this._manualClose.next(),this._manualClose.complete()}},{key:"manualClosed",value:function(){return this._manualClose.asObservable()}},{key:"timeoutReset",value:function(){return this._resetTimeout.asObservable()}},{key:"countDuplicate",value:function(){return this._countDuplicate.asObservable()}},{key:"close",value:function(){this._overlayRef.detach(),this._afterClosed.next(),this._manualClose.next(),this._afterClosed.complete(),this._manualClose.complete(),this._activate.complete(),this._resetTimeout.complete(),this._countDuplicate.complete()}},{key:"afterClosed",value:function(){return this._afterClosed.asObservable()}},{key:"isInactive",value:function(){return this._activate.isStopped}},{key:"activate",value:function(){this._activate.next(),this._activate.complete()}},{key:"afterActivate",value:function(){return this._activate.asObservable()}},{key:"onDuplicate",value:function(t,e){t&&this._resetTimeout.next(),e&&this._countDuplicate.next(++this.duplicatesCount)}}]),t}(),x=function(){function t(e,n){C(this,t),this._toastPackage=e,this._parentInjector=n}return w(t,[{key:"get",value:function(t,e,n){return t===v?this._toastPackage:this._parentInjector.get(t,e,n)}}]),t}(),P=function(){var t=function(){function t(e,n,i,r,o){C(this,t),this.overlay=n,this._injector=i,this.sanitizer=r,this.ngZone=o,this.currentlyActive=0,this.toasts=[],this.index=0,this.toastrConfig=Object.assign(Object.assign({},e.default),e.config),e.config.iconClasses&&(this.toastrConfig.iconClasses=Object.assign(Object.assign({},e.default.iconClasses),e.config.iconClasses))}return w(t,[{key:"show",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"";return this._preBuildNotification(i,t,e,this.applyConfig(n))}},{key:"success",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this._preBuildNotification(this.toastrConfig.iconClasses.success||"",t,e,this.applyConfig(n))}},{key:"error",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this._preBuildNotification(this.toastrConfig.iconClasses.error||"",t,e,this.applyConfig(n))}},{key:"info",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this._preBuildNotification(this.toastrConfig.iconClasses.info||"",t,e,this.applyConfig(n))}},{key:"warning",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this._preBuildNotification(this.toastrConfig.iconClasses.warning||"",t,e,this.applyConfig(n))}},{key:"clear",value:function(t){var e,n=p(this.toasts);try{for(n.s();!(e=n.n()).done;){var i=e.value;if(void 0!==t){if(i.toastId===t)return void i.toastRef.manualClose()}else i.toastRef.manualClose()}}catch(r){n.e(r)}finally{n.f()}}},{key:"remove",value:function(t){var e=this._findToast(t);if(!e)return!1;if(e.activeToast.toastRef.close(),this.toasts.splice(e.index,1),this.currentlyActive=this.currentlyActive-1,!this.toastrConfig.maxOpened||!this.toasts.length)return!1;if(this.currentlyActive0&&void 0!==arguments[0]?arguments[0]:"",n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],i=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=p(this.toasts);try{for(r.s();!(t=r.n()).done;){var o=t.value;if(o.message===e)return o.toastRef.onDuplicate(n,i),o}}catch(a){r.e(a)}finally{r.f()}return null}},{key:"applyConfig",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return Object.assign(Object.assign({},this.toastrConfig),t)}},{key:"_findToast",value:function(t){for(var e=0;e0,this.toastrConfig.countDuplicates);if(e&&this.toastrConfig.preventDuplicates&&null!==o)return o;this.previousToastMessage=e;var a=!1;this.toastrConfig.maxOpened&&this.currentlyActive>=this.toastrConfig.maxOpened&&(a=!0,this.toastrConfig.autoDismiss&&this.clear(this.toasts[0].toastId));var s=this.overlay.create(r.positionClass,this.overlayContainer);this.index=this.index+1;var c=e;e&&r.enableHtml&&(c=this.sanitizer.sanitize(i.K.HTML,e));var u=new E(s),l=new v(this.index,r,c,n,t,u),d=new x(l,this._injector),h=new _(r.toastComponent,d),f=s.attach(h,this.toastrConfig.newestOnTop);u.componentInstance=f.instance;var p={toastId:this.index,message:e||"",toastRef:u,onShown:u.afterActivate(),onHidden:u.afterClosed(),onTap:l.onTap(),onAction:l.onAction(),portal:f};return a||(this.currentlyActive=this.currentlyActive+1,setTimeout((function(){p.toastRef.activate()}))),this.toasts.push(p),p}}]),t}();return t.\u0275fac=function(e){return new(e||t)(i.Yb(y),i.Yb(S),i.Yb(i.t),i.Yb(s.b),i.Yb(i.B))},t.\u0275prov=Object(i.Kb)({factory:function(){return new t(Object(i.Yb)(y),Object(i.Yb)(S),Object(i.Yb)(i.p),Object(i.Yb)(s.b),Object(i.Yb)(i.B))},token:t,providedIn:"root"}),t}(),A=function(){var t=function(){function t(e,n,i){var r=this;C(this,t),this.toastrService=e,this.toastPackage=n,this.ngZone=i,this.width=-1,this.toastClasses="",this.state={value:"inactive",params:{easeTime:this.toastPackage.config.easeTime,easing:"ease-in"}},this.message=n.message,this.title=n.title,this.options=n.config,this.originalTimeout=n.config.timeOut,this.toastClasses="".concat(n.toastType," ").concat(n.config.toastClass),this.sub=n.toastRef.afterActivate().subscribe((function(){r.activateToast()})),this.sub1=n.toastRef.manualClosed().subscribe((function(){r.remove()})),this.sub2=n.toastRef.timeoutReset().subscribe((function(){r.resetTimeout()})),this.sub3=n.toastRef.countDuplicate().subscribe((function(t){r.duplicatesCount=t}))}return w(t,[{key:"ngOnDestroy",value:function(){this.sub.unsubscribe(),this.sub1.unsubscribe(),this.sub2.unsubscribe(),this.sub3.unsubscribe(),clearInterval(this.intervalId),clearTimeout(this.timeout)}},{key:"activateToast",value:function(){var t=this;this.state=Object.assign(Object.assign({},this.state),{value:"active"}),!0!==this.options.disableTimeOut&&"timeOut"!==this.options.disableTimeOut&&this.options.timeOut&&(this.outsideTimeout((function(){return t.remove()}),this.options.timeOut),this.hideTime=(new Date).getTime()+this.options.timeOut,this.options.progressBar&&this.outsideInterval((function(){return t.updateProgress()}),10))}},{key:"updateProgress",value:function(){if(0!==this.width&&100!==this.width&&this.options.timeOut){var t=(new Date).getTime();this.width=(this.hideTime-t)/this.options.timeOut*100,"increasing"===this.options.progressAnimation&&(this.width=100-this.width),this.width<=0&&(this.width=0),this.width>=100&&(this.width=100)}}},{key:"resetTimeout",value:function(){var t=this;clearTimeout(this.timeout),clearInterval(this.intervalId),this.state=Object.assign(Object.assign({},this.state),{value:"active"}),this.outsideTimeout((function(){return t.remove()}),this.originalTimeout),this.options.timeOut=this.originalTimeout,this.hideTime=(new Date).getTime()+(this.options.timeOut||0),this.width=-1,this.options.progressBar&&this.outsideInterval((function(){return t.updateProgress()}),10)}},{key:"remove",value:function(){var t=this;"removed"!==this.state.value&&(clearTimeout(this.timeout),this.state=Object.assign(Object.assign({},this.state),{value:"removed"}),this.outsideTimeout((function(){return t.toastrService.remove(t.toastPackage.toastId)}),+this.toastPackage.config.easeTime))}},{key:"tapToast",value:function(){"removed"!==this.state.value&&(this.toastPackage.triggerTap(),this.options.tapToDismiss&&this.remove())}},{key:"stickAround",value:function(){"removed"!==this.state.value&&(clearTimeout(this.timeout),this.options.timeOut=0,this.hideTime=0,clearInterval(this.intervalId),this.width=0)}},{key:"delayedHideToast",value:function(){var t=this;!0!==this.options.disableTimeOut&&"extendedTimeOut"!==this.options.disableTimeOut&&0!==this.options.extendedTimeOut&&"removed"!==this.state.value&&(this.outsideTimeout((function(){return t.remove()}),this.options.extendedTimeOut),this.options.timeOut=this.options.extendedTimeOut,this.hideTime=(new Date).getTime()+(this.options.timeOut||0),this.width=-1,this.options.progressBar&&this.outsideInterval((function(){return t.updateProgress()}),10))}},{key:"outsideTimeout",value:function(t,e){var n=this;this.ngZone?this.ngZone.runOutsideAngular((function(){return n.timeout=setTimeout((function(){return n.runInsideAngular(t)}),e)})):this.timeout=setTimeout((function(){return t()}),e)}},{key:"outsideInterval",value:function(t,e){var n=this;this.ngZone?this.ngZone.runOutsideAngular((function(){return n.intervalId=setInterval((function(){return n.runInsideAngular(t)}),e)})):this.intervalId=setInterval((function(){return t()}),e)}},{key:"runInsideAngular",value:function(t){this.ngZone?this.ngZone.run((function(){return t()})):t()}},{key:"displayStyle",get:function(){if("inactive"===this.state.value)return"none"}}]),t}();return t.\u0275fac=function(e){return new(e||t)(i.Ob(P),i.Ob(v),i.Ob(i.B))},t.\u0275cmp=i.Ib({type:t,selectors:[["","toast-component",""]],hostVars:5,hostBindings:function(t,e){1&t&&i.bc("click",(function(){return e.tapToast()}))("mouseenter",(function(){return e.stickAround()}))("mouseleave",(function(){return e.delayedHideToast()})),2&t&&(i.Nc("@flyInOut",e.state),i.Eb(e.toastClasses),i.Lc("display",e.displayStyle))},attrs:l,decls:5,vars:5,consts:[["class","toast-close-button","aria-label","Close",3,"click",4,"ngIf"],[3,"class",4,"ngIf"],["role","alertdialog","aria-live","polite",3,"class","innerHTML",4,"ngIf"],["role","alertdialog","aria-live","polite",3,"class",4,"ngIf"],[4,"ngIf"],["aria-label","Close",1,"toast-close-button",3,"click"],["aria-hidden","true"],["role","alertdialog","aria-live","polite",3,"innerHTML"],["role","alertdialog","aria-live","polite"],[1,"toast-progress"]],template:function(t,e){1&t&&(i.Oc(0,d,3,0,"button",0),i.Oc(1,f,3,5,"div",1),i.Oc(2,b,1,3,"div",2),i.Oc(3,g,2,4,"div",3),i.Oc(4,m,2,2,"div",4)),2&t&&(i.mc("ngIf",e.options.closeButton),i.Cb(1),i.mc("ngIf",e.title),i.Cb(1),i.mc("ngIf",e.message&&e.options.enableHtml),i.Cb(1),i.mc("ngIf",e.message&&!e.options.enableHtml),i.Cb(1),i.mc("ngIf",e.options.progressBar))},directives:[u.n],encapsulation:2,data:{animation:[Object(r.n)("flyInOut",[Object(r.k)("inactive",Object(r.l)({opacity:0})),Object(r.k)("active",Object(r.l)({opacity:1})),Object(r.k)("removed",Object(r.l)({opacity:0})),Object(r.m)("inactive => active",Object(r.e)("{{ easeTime }}ms {{ easing }}")),Object(r.m)("active => removed",Object(r.e)("{{ easeTime }}ms {{ easing }}"))])]}}),t}(),I=Object.assign(Object.assign({},{maxOpened:0,autoDismiss:!1,newestOnTop:!0,preventDuplicates:!1,countDuplicates:!1,resetTimeoutOnDuplicate:!1,iconClasses:{error:"toast-error",info:"toast-info",success:"toast-success",warning:"toast-warning"},closeButton:!1,disableTimeOut:!1,timeOut:5e3,extendedTimeOut:1e3,enableHtml:!1,progressBar:!1,toastClass:"ngx-toastr",positionClass:"toast-top-right",titleClass:"toast-title",messageClass:"toast-message",easing:"ease-in",easeTime:300,tapToDismiss:!0,onActivateTick:!1,progressAnimation:"decreasing"}),{toastComponent:A}),M=function(){var t=function(){function t(){C(this,t)}return w(t,null,[{key:"forRoot",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return{ngModule:t,providers:[{provide:y,useValue:{default:I,config:e}}]}}}]),t}();return t.\u0275mod=i.Mb({type:t}),t.\u0275inj=i.Lb({factory:function(e){return new(e||t)},imports:[[u.c]]}),t}()},MT7k:function(t,e,n){"use strict";n.d(e,"a",(function(){return p})),n.d(e,"g",(function(){return _})),n.d(e,"e",(function(){return O})),n.d(e,"c",(function(){return C})),n.d(e,"d",(function(){return T})),n.d(e,"f",(function(){return S})),n.d(e,"h",(function(){return E})),n.d(e,"b",(function(){return x}));var i=n("zqNl"),r=n("og7C"),o=n("p5wL"),a=n("lx5p"),s=n("1OAy"),c=n("+Px6"),u=n("H0/1"),l=n("rxqU"),d=n("7KkP"),h={trades:[],user:{logs:Object(r.b)(),transfers:[],orders:[],fiatWithdrawals:[],fiatDeposits:[]}},f=Object(i.i)(h,Object(i.k)(s.j,(function(t){return Object(o.b)(h.user,t,"user")})),Object(i.k)(s.p,(function(t,e){var n=e.trades;return Object(o.b)(n,t,"trades")})),Object(i.k)(s.b,(function(t,e){var n=e.trade;return Object(o.b)([n].concat(b(t.trades)).slice(0,100),t,"trades")})),Object(i.k)(s.c,(function(t,e){var n=e.trades;return Object(o.b)([].concat(b(n),b(t.trades)).slice(0,100),t,"trades")})),Object(i.k)(s.m,(function(t,e){var n=e.logs;return Object(o.b)(Object(o.c)(n,"id"),t,"user","logs")})),Object(i.k)(s.a,(function(t,e){var n=e.logs;return Object(o.a)(Object(o.c)(n,"id"),t,"user","logs")})),Object(i.k)(s.o,(function(t,e){var n=e.transfers;return Object(o.b)(n,t,"user","transfers")})),Object(i.k)(s.n,(function(t,e){var n=e.activity;return Object(o.b)(b(n).reverse(),t,"user","orders")})),Object(i.k)(s.l,(function(t,e){var n=e.withdrawals;return Object(o.b)(n,t,"user","fiatWithdrawals")})),Object(i.k)(s.k,(function(t,e){var n=e.deposits;return Object(o.b)(n,t,"user","fiatDeposits")})),Object(i.k)(s.n,(function(t,e){var n=e.activity;return Object(o.b)(n,t,"user","orders")})));function p(t,e){return f(t,e)}var g=Object(i.h)("logs"),m=Object(i.j)(g,Object(a.F)("trades")),v=Object(i.j)(g,Object(a.F)("user")),y=Object(i.j)(v,Object(a.F)("logs")),_=Object(i.j)(v,Object(a.F)("transfers")),O=Object(i.j)(v,Object(a.F)("orders")),k=Object(i.j)(v,(function(t){return t.fiatWithdrawals})),w=Object(i.j)(v,(function(t){return t.fiatDeposits})),C=Object(i.j)(m,c.t,l.r,(function(t,e,n){return t.map(Object(d.g)(n,e.inverse))})),T=Object(i.j)(c.d,c.j,y,(function(t,e,n){return Object(u.b)(n.sortBy(Object(a.F)("id"),a.i)).map((function(n){return Object(u.a)(t,e,n)})).valueSeq().toArray()})),S=Object(i.j)(T,(function(t){return t.filter((function(t){return t.info.includes("trade")}))})),E=Object(i.j)(T,(function(t){return t.filter((function(t){return t.info.includes("cross-exchange transfer")}))})),x=Object(i.j)(k,w,(function(t,e){return e.concat(t).sort((function(t,e){return e.timestamp-t.timestamp}))}))},MUfl:function(t,e,n){"use strict";n.d(e,"a",(function(){return l}));var i=n("og7C"),r=n("KQpv"),o=n.n(r),a=n("sXtk"),s=n("kZht"),c=o()("trace:app:FeatureService"),u={wsHealth:[],fido2:[],flex:[],createSubAccount:[],transferDestination:[],fusionBanners:[],dltBanners:[]},l=function(){var t=function(){function t(e){C(this,t),this.env=e,this.inited=!1,this.features=Object(i.f)()}return w(t,[{key:"resolveDepsFor",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Object(i.f)();c("resolving feature",t,{excluding:n.toArray()});var r=Object(i.f)(u[t]).subtract(n),o=n.merge(r),a=r.reduce((function(t,n){var i=e.resolveDepsFor(n,o);return t.merge(i)}),r);return c("non-existing deps of",t,a.toArray()),a}},{key:"resolveEnvFeatures",value:function(){var t=this;c("resolving all env features:",this.env.featuresEnabled),this.features=this.env.featuresEnabled.reduce((function(e,n){var i=e.add(n),r=t.resolveDepsFor(n,i);return i.merge(r)}),Object(i.f)()),c("features enabled",this.features.toArray()),this.inited=!0}},{key:"isEnabled",value:function(t){return c("checking enabled for",t),this.inited||this.resolveEnvFeatures(),c("enabled?",this.features.has(t)),this.features.has(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(s.Yb(a.a))},t.\u0275prov=s.Kb({token:t,factory:t.\u0275fac,providedIn:"root"}),t}()},MiDb:function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var i=function(){function t(){return Error.call(this),this.message="object unsubscribed",this.name="ObjectUnsubscribedError",this}return t.prototype=Object.create(Error.prototype),t}()},MqcE:function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var i=n("kZht"),r=["sb-menu-heading",""],o=["*"],a=function(){var t=function t(){C(this,t),this._class=!0};return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=i.Ib({type:t,selectors:[["","sb-menu-heading",""]],hostVars:2,hostBindings:function(t,e){2&t&&i.Gb("sb-menu-heading",e._class)},inputs:{sbIcon:"sbIcon"},exportAs:["sbMenuHeading"],attrs:r,ngContentSelectors:o,decls:1,vars:0,template:function(t,e){1&t&&(i.lc(),i.kc(0))},styles:["[_nghost-%COMP%]{margin:calc(var(--spacing-s, $default-spacing) * -1) calc(var(--spacing-s, $default-spacing) * -1) var(--spacing-s,5px);padding:var(--spacing,5px);color:var(--ghost-colour,currentColor);font-weight:700;text-transform:uppercase;background:var(--toolbar-colour);-webkit-user-select:none;-moz-user-select:none;user-select:none}"],changeDetection:0}),t}()},"ND+C":function(t,e,n){"use strict";n.d(e,"a",(function(){return r})),n.d(e,"b",(function(){return o})),n.d(e,"c",(function(){return a})),n.d(e,"d",(function(){return s}));var i=n("zqNl"),r=Object(i.g)("Set Lite Ticker",Object(i.l)()),o=Object(i.g)("Set Lite Ticker Batch",Object(i.l)()),a=Object(i.g)("Set Ticker",Object(i.l)()),s=Object(i.g)("Set Ticker Batch",Object(i.l)())},NWTG:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("8vcT"),r=n("+luX"),o=n("y1Fj"),a=n("vI0g"),s=n("s/Os"),c=n("L09h"),u=n("TIRN"),l=n("sP54"),d=n("TDnQ"),h=n("IkhO"),f=n("YzW0"),p=n("3xzP"),b=n("a3or"),g=n("XveA"),m=function(){function t(){}return t.calculateMaskPenalty=function(t){return l.default.applyMaskPenaltyRule1(t)+l.default.applyMaskPenaltyRule2(t)+l.default.applyMaskPenaltyRule3(t)+l.default.applyMaskPenaltyRule4(t)},t.encode=function(e,n,a){void 0===a&&(a=null);var s=t.DEFAULT_BYTE_MODE_ENCODING,l=null!==a&&void 0!==a.get(i.default.CHARACTER_SET);l&&(s=a.get(i.default.CHARACTER_SET).toString());var p=this.chooseMode(e,s),b=new r.default;if(p===c.default.BYTE&&(l||t.DEFAULT_BYTE_MODE_ENCODING!==s)){var m=o.default.getCharacterSetECIByName(s);void 0!==m&&this.appendECI(m,b)}this.appendModeInfo(p,b);var v,y=new r.default;if(this.appendBytes(e,p,y,s),null!==a&&void 0!==a.get(i.default.QR_VERSION)){var _=Number.parseInt(a.get(i.default.QR_VERSION).toString(),10);v=u.default.getVersionForNumber(_);var O=this.calculateBitsNeeded(p,b,y,v);if(!this.willFit(O,v,n))throw new g.default("Data too big for requested version")}else v=this.recommendVersion(n,p,b,y);var k=new r.default;k.appendBitArray(b);var w=p===c.default.BYTE?y.getSizeInBytes():e.length;this.appendLengthInfo(w,v,p,k),k.appendBitArray(y);var C=v.getECBlocksForLevel(n),T=v.getTotalCodewords()-C.getTotalECCodewords();this.terminateBits(T,k);var S=this.interleaveWithECBytes(k,v.getTotalCodewords(),T,C.getNumBlocks()),E=new h.default;E.setECLevel(n),E.setMode(p),E.setVersion(v);var x=v.getDimensionForVersion(),P=new d.default(x,x),A=this.chooseMaskPattern(S,n,v,P);return E.setMaskPattern(A),f.default.buildMatrix(S,n,v,A,P),E.setMatrix(P),E},t.recommendVersion=function(t,e,n,i){var r=this.calculateBitsNeeded(e,n,i,u.default.getVersionForNumber(1)),o=this.chooseVersion(r,t),a=this.calculateBitsNeeded(e,n,i,o);return this.chooseVersion(a,t)},t.calculateBitsNeeded=function(t,e,n,i){return e.getSize()+t.getCharacterCountBits(i)+n.getSize()},t.getAlphanumericCode=function(e){return e159)&&(r<224||r>235))return!1}return!0},t.chooseMaskPattern=function(t,e,n,i){for(var r=Number.MAX_SAFE_INTEGER,o=-1,a=0;a=(t+7)/8},t.terminateBits=function(t,e){var n=8*t;if(e.getSize()>n)throw new g.default("data bits cannot fit in the QR Code"+e.getSize()+" > "+n);for(var i=0;i<4&&e.getSize()0)for(i=r;i<8;i++)e.appendBit(!1);var o=t-e.getSizeInBytes();for(i=0;i=n)throw new g.default("Block ID too large");var a=t%n,s=n-a,c=Math.floor(t/n),u=c+1,l=Math.floor(e/n),d=l+1,h=c-l,f=u-d;if(h!==f)throw new g.default("EC bytes mismatch");if(n!==s+a)throw new g.default("RS blocks mismatch");if(t!==(l+h)*s+(d+f)*a)throw new g.default("Total bytes mismatch");i=1<=0&&n<=9},t.appendNumericBytes=function(e,n){for(var i=e.length,r=0;r=33088&&a<=40956?s=a-33088:a>=57408&&a<=60351&&(s=a-49472),-1===s)throw new g.default("Invalid byte sequence");e.appendBits(192*(s>>8)+(255&s),13)}},t.appendECI=function(t,e){e.appendBits(c.default.ECI.getBits(),4),e.appendBits(t.getValue(),8)},t.ALPHANUMERIC_TABLE=Int32Array.from([-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,36,-1,-1,-1,37,38,-1,-1,-1,-1,39,40,-1,41,42,43,0,1,2,3,4,5,6,7,8,9,44,-1,-1,-1,-1,-1,-1,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,-1,-1,-1,-1,-1]),t.DEFAULT_BYTE_MODE_ENCODING=o.default.UTF8.getName(),t}();e.default=m},NgZA:function(t,e,n){"use strict";var i={single_source_shortest_paths:function(t,e,n){var r={},o={};o[e]=0;var a,s,c,u,l,d,h=i.PriorityQueue.make();for(h.push(e,0);!h.empty();)for(c in u=(a=h.pop()).cost,l=t[s=a.value]||{})l.hasOwnProperty(c)&&(d=u+l[c],(void 0===o[c]||o[c]>d)&&(o[c]=d,h.push(c,d),r[c]=s));if(void 0!==n&&void 0===o[n]){var f=["Could not find a path from ",e," to ",n,"."].join("");throw new Error(f)}return r},extract_shortest_path_from_predecessor_list:function(t,e){for(var n=[],i=e;i;)n.push(i),i=t[i];return n.reverse(),n},find_path:function(t,e,n){var r=i.single_source_shortest_paths(t,e,n);return i.extract_shortest_path_from_predecessor_list(r,n)},PriorityQueue:{make:function(t){var e,n=i.PriorityQueue,r={};for(e in t=t||{},n)n.hasOwnProperty(e)&&(r[e]=n[e]);return r.queue=[],r.sorter=t.sorter||n.default_sorter,r},default_sorter:function(t,e){return t.cost-e.cost},push:function(t,e){this.queue.push({value:t,cost:e}),this.queue.sort(this.sorter)},pop:function(){return this.queue.shift()},empty:function(){return 0===this.queue.length}}};t.exports=i},Ngp4:function(t,e,n){"use strict";n.d(e,"a",(function(){return J}));var i=n("zqNl"),r=n("YtkY"),o=n("HM3f"),a=n("lx5p"),s=n("uJYd"),c=n("lE9u"),u=n("rxqU"),l=n("+Px6"),d=n("J/3c"),h=n("sXtk"),f=n("kZht"),p=n("An66"),b=n("NxuZ"),g=n("1etq"),v=n("FQF6"),y=n("TMzY"),_=n("UVqw"),O=n("Eu46"),k=n("anSm"),T=n("oiza"),S=n("IkSM"),E=n("B6Vo"),x=n("Cc4E"),P=n("zho4"),A=n("yPvj"),I=n("1o0v"),M=n("LbKT"),D=n("+I9z"),R=n("/dWT"),j=n("7J2L"),L=n("aDqW"),N=n("fvDn"),U=n("DpwM"),F=n("rUBT");function B(t,e){1&t&&(f.Ub(0,"section",4),f.Pb(1,"fa-icon",5),f.Ub(2,"h2",6),f.Qc(3),f.gc(4,"translate"),f.Tb(),f.Tb()),2&t&&(f.Cb(3),f.Sc("",f.hc(4,1,"DASHBOARD.AUTHMASK"),"."))}function z(t,e){1&t&&(f.Sb(0),f.Pb(1,"flex-wallet"),f.Rb())}var V=function(){return[250,100]};function H(t,e){if(1&t){var n=f.Vb();f.Ub(0,"fa-icon",29),f.bc("click",(function(){f.Ec(n);var t=f.fc().$implicit;return f.fc(4).openWalletTransactionDialog("deposit",t)})),f.gc(1,"async"),f.Tb()}if(2&t){var i=f.fc(2).ngLet,r=f.fc(3);f.mc("sbDisabled",!i)("sbDelay",f.qc(5,V))("hidden",f.hc(1,3,r.isSubAccount$))}}var q=function(t){return{currency:t}};function $(t,e){if(1&t){var n=f.Vb();f.Ub(0,"section",14),f.Ub(1,"div",15),f.Ub(2,"p",16),f.Qc(3),f.gc(4,"translate"),f.gc(5,"cryptoName"),f.Tb(),f.Tb(),f.Ub(6,"div",17),f.Pb(7,"market-icon",18),f.Ub(8,"p",19),f.Qc(9),f.gc(10,"translate"),f.gc(11,"cryptoName"),f.Tb(),f.Ub(12,"p",20),f.Qc(13),f.gc(14,"translate"),f.Tb(),f.Tb(),f.Ub(15,"div",21),f.Pb(16,"market-icon",18),f.Tb(),f.Ub(17,"div",22),f.Ub(18,"span",23),f.Qc(19),f.gc(20,"cryptoPrecise"),f.Tb(),f.Tb(),f.Ub(21,"div",24),f.Ub(22,"span",25),f.Qc(23),f.gc(24,"crypto"),f.Tb(),f.Tb(),f.Ub(25,"div",26),f.Oc(26,H,2,6,"fa-icon",27),f.Ub(27,"fa-icon",28),f.bc("click",(function(){f.Ec(n);var t=e.$implicit;return f.fc(4).openWalletTransactionDialog("crypto-transfer",t)})),f.Tb(),f.Tb(),f.Tb()}if(2&t){var i=e.$implicit,r=f.fc().ngLet,o=f.fc(3);f.Cb(2),f.mc("sbDisabled",!r)("sbDelay",f.qc(32,V)),f.Cb(1),f.Sc(" ",f.ic(4,14,"LABEL.X_HOLDING_WALLET",f.rc(33,q,f.hc(5,17,i.name)))," "),f.Cb(4),f.mc("base",i.name),f.Cb(1),f.mc("sbDisabled",!r)("sbDelay",f.qc(35,V)),f.Cb(1),f.Sc(" ",f.ic(10,19,"LABEL.X_HOLDING_WALLET",f.rc(36,q,f.hc(11,22,i.name)))," "),f.Cb(4),f.Rc(f.hc(14,24,"WALLETS.HOLDING.SHORT_DESCRIPTION")),f.Cb(3),f.mc("base",i.name),f.Cb(3),f.Sc(" ",f.ic(20,26,i.balance||0,i.name)," "),f.Cb(4),f.Sc("\u2248 ",f.ic(24,29,i.notional,"usd")," USD"),f.Cb(3),f.mc("ngIf",!o.demo),f.Cb(1),f.mc("sbDisabled",!r)("sbDelay",f.qc(38,V))}}var Q=function(t){return{pair:t}};function W(t,e){if(1&t){var n=f.Vb();f.Ub(0,"section",30),f.Ub(1,"div",15),f.Ub(2,"p",31),f.Qc(3),f.gc(4,"translate"),f.gc(5,"pair"),f.Tb(),f.Tb(),f.Ub(6,"div",17),f.Pb(7,"market-icon",32),f.gc(8,"pair"),f.Ub(9,"p",33),f.Qc(10),f.gc(11,"translate"),f.gc(12,"pair"),f.Tb(),f.Ub(13,"p",20),f.Qc(14),f.gc(15,"translate"),f.gc(16,"pair"),f.Tb(),f.Tb(),f.Ub(17,"div",21),f.Pb(18,"market-icon",32),f.gc(19,"pair"),f.Tb(),f.Ub(20,"div",22),f.Ub(21,"span",34),f.Pb(22,"ghost-trail",35),f.gc(23,"cryptoPrecise"),f.Tb(),f.Tb(),f.Ub(24,"div",24),f.Ub(25,"span",25),f.Qc(26),f.gc(27,"crypto"),f.Tb(),f.Tb(),f.Ub(28,"div",26),f.Ub(29,"fa-icon",36),f.bc("click",(function(){f.Ec(n);var t=e.$implicit;return f.fc(4).openWalletDetailsDialog(t)})),f.Tb(),f.Ub(30,"fa-icon",37),f.bc("click",(function(){f.Ec(n);var t=e.$implicit;return f.fc(4).openWalletTransactionDialog("crypto-transfer",t)})),f.Tb(),f.Tb(),f.Tb()}if(2&t){var i=e.$implicit,r=f.fc().ngLet;f.Cb(2),f.mc("sbDisabled",!r)("sbDelay",f.qc(41,V)),f.Cb(1),f.Sc(" ",f.ic(4,16,"LABEL.X_FUTURES_WALLET",f.rc(42,Q,f.hc(5,19,i.pair)))," "),f.Cb(4),f.mc("pair",f.hc(8,21,i.pair)),f.Cb(2),f.mc("sbDisabled",!r)("sbDelay",f.qc(44,V)),f.Cb(1),f.Sc(" ",f.ic(11,23,"LABEL.X_FUTURES_WALLET",f.rc(45,Q,f.hc(12,26,i.pair)))," "),f.Cb(4),f.Sc(" ",f.ic(15,28,"WALLETS.FUTURES.SHORT_DESCRIPTION",f.rc(47,Q,f.hc(16,31,i.pair)))," "),f.Cb(4),f.mc("pair",f.hc(19,33,i.pair)),f.Cb(3),f.mc("pnl",i.am),f.Cb(1),f.mc("content",f.ic(23,35,i.am||0,i.currency)),f.Cb(4),f.Sc("\u2248 ",f.ic(27,38,i.amNotional,"usd")," USD"),f.Cb(3),f.mc("sbDisabled",!r)("sbDelay",f.qc(49,V)),f.Cb(1),f.mc("sbDisabled",!r)("sbDelay",f.qc(50,V))}}function G(t,e){if(1&t&&(f.Ub(0,"section",11),f.Oc(1,$,28,39,"section",12),f.gc(2,"async"),f.Oc(3,W,31,51,"section",13),f.gc(4,"async"),f.Tb()),2&t){var n=f.fc(3);f.Cb(1),f.mc("ngIf",f.hc(2,2,n.selectedHoldingWallet$)),f.Cb(2),f.mc("ngIf",f.hc(4,4,n.selectedFuturesWallet$))}}function Y(t,e){if(1&t&&(f.Ub(0,"section",38),f.Pb(1,"margin-details-list",39),f.gc(2,"async"),f.gc(3,"async"),f.Tb()),2&t){var n=f.fc(3);f.Cb(1),f.mc("displayTooltips",f.hc(2,2,n.displayTooltips$))("wallet",f.hc(3,4,n.selectedFuturesWallet$))}}function K(t,e){if(1&t&&(f.Ub(0,"section",8),f.Oc(1,G,5,6,"section",9),f.gc(2,"async"),f.Oc(3,Y,4,6,"section",10),f.gc(4,"async"),f.Tb()),2&t){var n=f.fc(2);f.Cb(1),f.mc("ngLet",f.hc(2,2,n.displayTooltips$)),f.Cb(2),f.mc("ngIf",f.hc(4,4,n.signedIn$))}}function Z(t,e){if(1&t&&(f.Oc(0,K,5,6,"section",7),f.gc(1,"async")),2&t){var n=f.fc(),i=f.Ac(8);f.mc("ngIf",f.hc(1,2,n.loaded$))("ngIfElse",i)}}function X(t,e){1&t&&f.Pb(0,"kraken-loading")}var J=function(){var t=function(){function t(e,n){C(this,t),this.store=e,this.env=n,this.signedIn$=this.store.pipe(Object(i.m)(u.m)),this.details$=this.store.pipe(Object(i.m)(u.d)),this.mSelectedHoldingWallet$=this.store.pipe(Object(i.m)(d.o)),this.selectedHoldingWallet$=this.mSelectedHoldingWallet$.pipe(Object(r.a)(a.O)),this.selectedFuturesWallet$=this.store.pipe(Object(i.m)(d.n)),this.walletFundingDetails$=this.store.pipe(Object(i.m)(d.q)),this.isSubAccount$=this.store.pipe(Object(i.m)(u.n)),this.displayTooltips$=this.store.pipe(Object(i.m)(u.y)),this.flexWallet$=this.store.pipe(Object(i.m)(d.l)),this.isFlexMarket$=this.store.pipe(Object(i.m)(l.a)),this.loaded$=Object(o.a)([this.signedIn$,this.mSelectedHoldingWallet$,this.selectedFuturesWallet$,this.flexWallet$,this.isFlexMarket$]).pipe(Object(r.a)((function(t){var e=m(t,5),n=e[0],i=e[1],r=e[2],o=e[3],a=e[4];return!n||(a?!!o:i.isSome()&&r)})))}return w(t,[{key:"openWalletDetailsDialog",value:function(t){this.store.dispatch(Object(c.j)({wallet:t}))}},{key:"openWalletTransactionDialog",value:function(t,e){this.store.dispatch(Object(s.g)({name:"wallet-transaction",inputs:{type:t,originWallet:e}}))}},{key:"demo",get:function(){return this.env.demo}}]),t}();return t.\u0275fac=function(e){return new(e||t)(f.Ob(i.b),f.Ob(h.a))},t.\u0275cmp=f.Ib({type:t,selectors:[["pair-wallet"]],decls:9,vars:9,consts:[["class","global__auth-mask",4,"ngIf"],[4,"ngIf","ngIfElse"],["futuresWallet",""],["loading",""],[1,"global__auth-mask"],["icon","stop","size","2x"],["subheading","",1,"global__text--warn"],["class","container","orientation","","breakpoint","",4,"ngIf","ngIfElse"],["orientation","","breakpoint","",1,"container"],["class","wallets",4,"ngLet"],["class","margin-details",4,"ngIf"],[1,"wallets"],["body","","class","wallet holding",4,"ngIf"],["body","","class","wallet",4,"ngIf"],["body","",1,"wallet","holding"],[1,"name"],["uppercase","","tooltip","","sbTooltip","TOOLTIP.HOLDING_WALLET",3,"sbDisabled","sbDelay"],[1,"grid-tri-left","gap-xs-m","large-name"],[3,"base"],["subheading","","tooltip","","sbTooltip","TOOLTIP.HOLDING_WALLET",3,"sbDisabled","sbDelay"],["ghost","",1,"description"],[1,"icon"],[1,"balance"],["subheading",""],[1,"estimate"],["body","","ghost",""],[1,"buttons"],["icon","deposit","size","2x","tooltip","","sbTooltip","TOOLTIP.HOLDING_DEPOSIT",3,"sbDisabled","sbDelay","hidden","click",4,"ngIf"],["icon","transfer","size","2x","tooltip","","sbTooltip","TOOLTIP.HOLDING_TRANSFER",3,"sbDisabled","sbDelay","click"],["icon","deposit","size","2x","tooltip","","sbTooltip","TOOLTIP.HOLDING_DEPOSIT",3,"sbDisabled","sbDelay","hidden","click"],["body","",1,"wallet"],["uppercase","","tooltip","","sbTooltip","TOOLTIP.FUTURES_WALLET",3,"sbDisabled","sbDelay"],[3,"pair"],["subheading","","tooltip","","sbTooltip","TOOLTIP.FUTURES_WALLET",3,"sbDisabled","sbDelay"],["subheading","","pnlZero","",3,"pnl"],[3,"content"],["icon","info","size","2x","tooltip","","sbTooltip","TOOLTIP.WALLET_DETAILS",3,"sbDisabled","sbDelay","click"],["icon","transfer","size","2x","tooltip","","sbTooltip","TOOLTIP.WALLET_TRANSFER",3,"sbDisabled","sbDelay","click"],[1,"margin-details"],[3,"displayTooltips","wallet"]],template:function(t,e){if(1&t&&(f.Oc(0,B,5,3,"section",0),f.gc(1,"async"),f.Oc(2,z,2,0,"ng-container",1),f.gc(3,"async"),f.gc(4,"async"),f.Oc(5,Z,2,4,"ng-template",null,2,f.Pc),f.Oc(7,X,1,0,"ng-template",null,3,f.Pc)),2&t){var n=f.Ac(6);f.mc("ngIf",!1===f.hc(1,3,e.signedIn$)),f.Cb(2),f.mc("ngIf",f.hc(3,5,e.signedIn$)&&f.hc(4,7,e.isFlexMarket$))("ngIfElse",n)}},directives:[p.n,b.b,g.a,v.a,y.a,_.a,O.a,k.a,T.a,S.a,E.a,x.a,P.a,A.a,I.a,M.a,D.a,R.a,j.a],pipes:[p.b,L.d,N.b,U.b,U.a,F.e],styles:['[_nghost-%COMP%]{position:relative}.container[_ngcontent-%COMP%], [_nghost-%COMP%]{display:flex;flex-direction:column;height:100%}.container[_ngcontent-%COMP%]{width:100%;padding:var(--spacing)}.container[orientation=horizontal][_ngcontent-%COMP%]{flex-direction:row}.container[orientation=horizontal][breakpoint=small][_ngcontent-%COMP%]{flex-direction:row;align-items:center}.container[orientation=horizontal][breakpoint=large][_ngcontent-%COMP%]{background-image:url(public/wallet-footer.a2924fe61c02e97dfd30.png);background-size:50%;background-repeat:no-repeat;background-position:115% 100%}.margin-details[_ngcontent-%COMP%]{flex:1;flex-direction:row;padding:var(--spacing) 0}[orientation=horizontal][_ngcontent-%COMP%] .margin-details[_ngcontent-%COMP%]{padding:var(--spacing) 0 0 var(--spacing);margin-left:var(--spacing);border-left:1px solid var(--border-colour)}[orientation=horizontal][breakpoint=small][_ngcontent-%COMP%] .margin-details[_ngcontent-%COMP%]{display:none!important}[orientation=vertical][_ngcontent-%COMP%] .margin-details[_ngcontent-%COMP%]{border-top:1px solid var(--border-colour);padding-top:var(--spacing-l)}.wallets[_ngcontent-%COMP%]{display:flex;flex-direction:column;margin-bottom:var(--spacing);min-width:250px}[orientation=horizontal][breakpoint=small][_ngcontent-%COMP%] .wallets[_ngcontent-%COMP%]{flex:1}[orientation=horizontal][breakpoint=large][_ngcontent-%COMP%] .wallets[_ngcontent-%COMP%], [orientation=horizontal][breakpoint=medium][_ngcontent-%COMP%] .wallets[_ngcontent-%COMP%]{flex:0.75}.wallet[_ngcontent-%COMP%]{display:grid;grid-template-areas:"name name name" "icon balance buttons" "icon estimate buttons";grid-template-columns:50px 1fr .75fr;grid-template-rows:25px 14px 16px;grid-gap:0 var(--spacing);padding:var(--spacing) 0}.wallet[_ngcontent-%COMP%]:first-child{border-bottom:1px solid var(--border-colour);padding-bottom:var(--spacing-l)!important}[orientation=horizontal][breakpoint=large][_ngcontent-%COMP%] .wallet[_ngcontent-%COMP%]{grid-template-areas:"name name" "balance buttons" "estimate buttons";grid-template-columns:1fr 1fr;grid-template-rows:auto 14px 16px;padding:var(--spacing-l) var(--spacing)}[orientation=horizontal][breakpoint=small][_ngcontent-%COMP%] .wallet[_ngcontent-%COMP%]{padding:var(--spacing-s)}[orientation=horizontal][breakpoint=small][_ngcontent-%COMP%] .wallet[_ngcontent-%COMP%]:not(:first-child){margin-top:var(--spacing)}.wallet[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]{grid-area:icon;align-self:center}[orientation=horizontal][breakpoint=large][_ngcontent-%COMP%] .wallet[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]{display:none}.wallet[_ngcontent-%COMP%] .name[_ngcontent-%COMP%]{grid-area:name}[orientation=horizontal][breakpoint=large][_ngcontent-%COMP%] .wallet[_ngcontent-%COMP%] .name[_ngcontent-%COMP%]{display:none}.wallet[_ngcontent-%COMP%] .description[_ngcontent-%COMP%]{line-height:1.2}.wallet[_ngcontent-%COMP%] .buttons[_ngcontent-%COMP%]{grid-area:buttons;align-self:center;text-align:right}.wallet[_ngcontent-%COMP%] .balance[_ngcontent-%COMP%]{grid-area:balance;align-self:flex-end}.wallet[_ngcontent-%COMP%] .estimate[_ngcontent-%COMP%]{grid-area:estimate;align-self:flex-end}.wallet.holding[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]{text-align:center}.wallet[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{font-size:14px;cursor:pointer}.wallet[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]:not(:last-child){padding-right:var(--spacing-l)}.wallet[_ngcontent-%COMP%] market-icon[_ngcontent-%COMP%]{font-size:28px}.wallet[_ngcontent-%COMP%] .large-name[_ngcontent-%COMP%]{padding-bottom:var(--spacing-l);grid-area:name}[orientation=horizontal][breakpoint=medium][_ngcontent-%COMP%] .wallet[_ngcontent-%COMP%] .large-name[_ngcontent-%COMP%], [orientation=horizontal][breakpoint=small][_ngcontent-%COMP%] .wallet[_ngcontent-%COMP%] .large-name[_ngcontent-%COMP%], [orientation=vertical][_ngcontent-%COMP%] .wallet[_ngcontent-%COMP%] .large-name[_ngcontent-%COMP%]{display:none}.caption[_ngcontent-%COMP%]{padding-bottom:var(--spacing)}.caption[_ngcontent-%COMP%], button[_ngcontent-%COMP%]{padding-top:var(--spacing-s)}button[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%] svg{vertical-align:-25%}'],changeDetection:0}),t}()},Nhx6:function(t,e,n){"use strict";function i(t){for(var n in t)e.hasOwnProperty(n)||(e[n]=t[n])}Object.defineProperty(e,"__esModule",{value:!0}),i(n("13Sj")),i(n("J180")),i(n("pRbe")),i(n("lFJA")),i(n("4x5s")),i(n("4S8q")),i(n("t+Fc")),i(n("bSqp"));var r=n("ekTi");e.ArgumentException=r.default;var o=n("hTBg");e.ArithmeticException=o.default;var a=n("sPys");e.ChecksumException=a.default;var s=n("w6/c");e.Exception=s.default;var c=n("nB6u");e.FormatException=c.default;var u=n("oznm");e.IllegalArgumentException=u.default;var l=n("FoZF");e.IllegalStateException=l.default;var d=n("LqyJ");e.NotFoundException=d.default;var h=n("35XV");e.ReaderException=h.default;var f=n("uQul");e.ReedSolomonException=f.default;var p=n("2gaf");e.UnsupportedOperationException=p.default;var b=n("XveA");e.WriterException=b.default;var g=n("4Pxi");e.BarcodeFormat=g.default;var m=n("XQH8");e.Binarizer=m.default;var v=n("s92m");e.BinaryBitmap=v.default;var y=n("ZCEf");e.DecodeHintType=y.default;var _=n("unaY");e.InvertedLuminanceSource=_.default;var O=n("qvG1");e.LuminanceSource=O.default;var k=n("6oIa");e.MultiFormatReader=k.default;var w=n("EnH0");e.MultiFormatWriter=w.default;var C=n("XrPM");e.PlanarYUVLuminanceSource=C.default;var T=n("KFdt");e.Result=T.default;var S=n("xSUO");e.ResultMetadataType=S.default;var E=n("vc4l");e.RGBLuminanceSource=E.default;var x=n("+luX");e.BitArray=x.default;var P=n("q+cW");e.BitMatrix=P.default;var A=n("lcP6");e.BitSource=A.default;var I=n("y1Fj");e.CharacterSetECI=I.default;var M=n("SnIc");e.DecoderResult=M.default;var D=n("2rk/");e.DefaultGridSampler=D.default;var R=n("qArU");e.DetectorResult=R.default;var j=n("8vcT");e.EncodeHintType=j.default;var L=n("neWc");e.GlobalHistogramBinarizer=L.default;var N=n("qAUu");e.GridSampler=N.default;var U=n("e9V9");e.GridSamplerInstance=U.default;var F=n("XOQS");e.HybridBinarizer=F.default;var B=n("9GlW");e.PerspectiveTransform=B.default;var z=n("PDjX");e.StringUtils=z.default;var V=n("dyLe");e.MathUtils=V.default;var H=n("va0y");e.WhiteRectangleDetector=H.default;var q=n("vI0g");e.GenericGF=q.default;var $=n("YwYi");e.GenericGFPoly=$.default;var Q=n("oCyE");e.ReedSolomonDecoder=Q.default;var W=n("s/Os");e.ReedSolomonEncoder=W.default;var G=n("ldwH");e.DataMatrixReader=G.default;var Y=n("4f9k");e.QRCodeReader=Y.default;var K=n("oggm");e.QRCodeWriter=K.default;var Z=n("FEHI");e.QRCodeDecoderErrorCorrectionLevel=Z.default;var X=n("NWTG");e.QRCodeEncoder=X.default;var J=n("IkhO");e.QRCodeEncoderQRCode=J.default;var tt=n("iiuT");e.OneDReader=tt.default;var et=n("aEDl");e.EAN13Reader=et.default;var nt=n("LBoB");e.Code128Reader=nt.default;var it=n("2Agw");e.ITFReader=it.default;var rt=n("YrFw");e.Code39Reader=rt.default;var ot=n("S21V");e.RSS14Reader=ot.default;var at=n("uepk");e.MultiformatReader=at.default},NloN:function(t,e,n){"use strict";function i(t,e){var n=URL.createObjectURL(t),i=document.createElement("a");i.setAttribute("download",e),i.href=n,document.body.appendChild(i),i.click(),document.body.removeChild(i),setTimeout((function(){return URL.revokeObjectURL(n)}),1e3)}function r(t){return new Promise((function(e){return t.toBlob((function(t){return e(t)}))}))}function o(t,e){performance.mark(t+"-start");var n=e();return performance.mark(t+"-end"),performance.measure(""+t,t+"-start",t+"-end"),n}function a(t){var e=new URL(window.location.href);e.searchParams.has(t)&&(e.searchParams.delete(t),window.history.replaceState(null,document.title,e.toString()))}function s(t,e){localStorage.setItem(t,JSON.stringify(e))}function c(t,e){if(!function(t){return null!==localStorage.getItem(t)}(t))return e;try{return JSON.parse(localStorage.getItem(t))}catch(n){return e}}n.d(e,"f",(function(){return i})),n.d(e,"a",(function(){return r})),n.d(e,"d",(function(){return o})),n.d(e,"e",(function(){return a})),n.d(e,"c",(function(){return s})),n.d(e,"b",(function(){return c})),Error},NxuZ:function(t,e,n){"use strict";n.d(e,"a",(function(){return Tt})),n.d(e,"b",(function(){return xt})),n.d(e,"c",(function(){return St})),n.d(e,"d",(function(){return Pt}));var i=n("kZht"),r=n("ENSU");function o(t){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function a(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function s(t){for(var e=1;e0;)e+="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"[62*Math.random()|0];return e}function G(t){return"".concat(t).replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(//g,">")}function Y(t){return Object.keys(t||{}).reduce((function(e,n){return e+"".concat(n,": ").concat(t[n],";")}),"")}function K(t){return t.size!==Q.size||t.x!==Q.x||t.y!==Q.y||t.rotate!==Q.rotate||t.flipX||t.flipY}function Z(t){var e=t.transform,n=t.iconWidth,i={transform:"translate(".concat(t.containerWidth/2," 256)")},r="translate(".concat(32*e.x,", ").concat(32*e.y,") "),o="scale(".concat(e.size/16*(e.flipX?-1:1),", ").concat(e.size/16*(e.flipY?-1:1),") "),a="rotate(".concat(e.rotate," 0 0)");return{outer:i,inner:{transform:"".concat(r," ").concat(o," ").concat(a)},path:{transform:"translate(".concat(n/2*-1," -256)")}}}var X={x:0,y:0,width:"100%",height:"100%"};function J(t){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return t.attributes&&(t.attributes.fill||e)&&(t.attributes.fill="black"),t}function tt(t){var e=t.icons,n=e.main,i=e.mask,r=t.prefix,o=t.iconName,a=t.transform,c=t.symbol,u=t.title,l=t.maskId,d=t.titleId,h=t.extra,f=t.watchable,p=void 0!==f&&f,b=i.found?i:n,g=b.width,m=b.height,v="fa-w-".concat(Math.ceil(g/m*16)),y=[T.replacementClass,o?"".concat(T.familyPrefix,"-").concat(o):"",v].filter((function(t){return-1===h.classes.indexOf(t)})).concat(h.classes).join(" "),_={children:[],attributes:s({},h.attributes,{"data-prefix":r,"data-icon":o,class:y,role:h.attributes.role||"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 ".concat(g," ").concat(m)})};p&&(_.attributes["data-fa-i2svg"]=""),u&&_.children.push({tag:"title",attributes:{id:_.attributes["aria-labelledby"]||"title-".concat(d||W())},children:[u]});var O=s({},_,{prefix:r,iconName:o,main:n,mask:i,maskId:l,transform:a,symbol:c,styles:h.styles}),k=i.found&&n.found?function(t){var e,n=t.children,i=t.attributes,r=t.main,o=t.mask,a=t.maskId,c=r.icon,u=o.icon,l=Z({transform:t.transform,containerWidth:o.width,iconWidth:r.width}),d={tag:"rect",attributes:s({},X,{fill:"white"})},h=c.children?{children:c.children.map(J)}:{},f={tag:"g",attributes:s({},l.inner),children:[J(s({tag:c.tag,attributes:s({},c.attributes,l.path)},h))]},p={tag:"g",attributes:s({},l.outer),children:[f]},b="mask-".concat(a||W()),g="clip-".concat(a||W()),m={tag:"mask",attributes:s({},X,{id:b,maskUnits:"userSpaceOnUse",maskContentUnits:"userSpaceOnUse"}),children:[d,p]},v={tag:"defs",children:[{tag:"clipPath",attributes:{id:g},children:(e=u,"g"===e.tag?e.children:[e])},m]};return n.push(v,{tag:"rect",attributes:s({fill:"currentColor","clip-path":"url(#".concat(g,")"),mask:"url(#".concat(b,")")},X)}),{children:n,attributes:i}}(O):function(t){var e=t.children,n=t.attributes,i=t.main,r=t.transform,o=Y(t.styles);if(o.length>0&&(n.style=o),K(r)){var a=Z({transform:r,containerWidth:i.width,iconWidth:i.width});e.push({tag:"g",attributes:s({},a.outer),children:[{tag:"g",attributes:s({},a.inner),children:[{tag:i.icon.tag,children:i.icon.children,attributes:s({},i.icon.attributes,a.path)}]}]})}else e.push(i.icon);return{children:e,attributes:n}}(O),w=k.attributes;return O.children=k.children,O.attributes=w,c?function(t){var e=t.iconName,n=t.children,i=t.symbol;return[{tag:"svg",attributes:{style:"display: none;"},children:[{tag:"symbol",attributes:s({},t.attributes,{id:!0===i?"".concat(t.prefix,"-").concat(T.familyPrefix,"-").concat(e):i}),children:n}]}]}(O):function(t){var e=t.children,n=t.main,i=t.mask,r=t.attributes,o=t.styles,a=t.transform;if(K(a)&&n.found&&!i.found){var c={x:n.width/n.height/2,y:.5};r.style=Y(s({},o,{"transform-origin":"".concat(c.x+a.x/16,"em ").concat(c.y+a.y/16,"em")}))}return[{tag:"svg",attributes:r,children:e}]}(O)}var et=function(t,e,n,i){var r,o,a,s=Object.keys(t),c=s.length,u=void 0!==i?function(t,e){return function(n,i,r,o){return t.call(e,n,i,r,o)}}(e,i):e;for(void 0===n?(r=1,a=t[s[0]]):(r=0,a=n);r2&&void 0!==arguments[2]?arguments[2]:{},i=n.skipHooks,r=void 0!==i&&i,o=Object.keys(e).reduce((function(t,n){var i=e[n];return i.icon?t[i.iconName]=i.icon:t[n]=i,t}),{});"function"!=typeof E.hooks.addPack||r?E.styles[t]=s({},E.styles[t]||{},o):E.hooks.addPack(t,o),"fas"===t&&nt("fa",e)}var it=E.styles,rt=E.shims,ot=function(){var t=function(t){return et(it,(function(e,n,i){return e[i]=et(n,t,{}),e}),{})};t((function(t,e,n){return e[3]&&(t[e[3]]=n),t})),t((function(t,e,n){var i=e[2];return t[n]=n,i.forEach((function(e){t[e]=n})),t}));var e="far"in it;et(rt,(function(t,n){var i=n[1];return"far"!==i||e||(i="fas"),t[n[0]]={prefix:i,iconName:n[2]},t}),{})};function at(t,e,n){if(t&&t[e]&&t[e][n])return{prefix:e,iconName:n,icon:t[e][n]}}function st(t){var e=t.tag,n=t.attributes,i=void 0===n?{}:n,r=t.children,o=void 0===r?[]:r;return"string"==typeof t?G(t):"<".concat(e," ").concat(function(t){return Object.keys(t||{}).reduce((function(e,n){return e+"".concat(n,'="').concat(G(t[n]),'" ')}),"").trim()}(i),">").concat(o.map(st).join(""),"").concat(e,">")}function ct(t){this.name="MissingIcon",this.message=t||"Icon unavailable",this.stack=(new Error).stack}ot(),(ct.prototype=Object.create(Error.prototype)).constructor=ct;var ut={fill:"currentColor"},lt={attributeType:"XML",repeatCount:"indefinite",dur:"2s"},dt=(s({},ut,{d:"M156.5,447.7l-12.6,29.5c-18.7-9.5-35.9-21.2-51.5-34.9l22.7-22.7C127.6,430.5,141.5,440,156.5,447.7z M40.6,272H8.5 c1.4,21.2,5.4,41.7,11.7,61.1L50,321.2C45.1,305.5,41.8,289,40.6,272z M40.6,240c1.4-18.8,5.2-37,11.1-54.1l-29.5-12.6 C14.7,194.3,10,216.7,8.5,240H40.6z M64.3,156.5c7.8-14.9,17.2-28.8,28.1-41.5L69.7,92.3c-13.7,15.6-25.5,32.8-34.9,51.5 L64.3,156.5z M397,419.6c-13.9,12-29.4,22.3-46.1,30.4l11.9,29.8c20.7-9.9,39.8-22.6,56.9-37.6L397,419.6z M115,92.4 c13.9-12,29.4-22.3,46.1-30.4l-11.9-29.8c-20.7,9.9-39.8,22.6-56.8,37.6L115,92.4z M447.7,355.5c-7.8,14.9-17.2,28.8-28.1,41.5 l22.7,22.7c13.7-15.6,25.5-32.9,34.9-51.5L447.7,355.5z M471.4,272c-1.4,18.8-5.2,37-11.1,54.1l29.5,12.6 c7.5-21.1,12.2-43.5,13.6-66.8H471.4z M321.2,462c-15.7,5-32.2,8.2-49.2,9.4v32.1c21.2-1.4,41.7-5.4,61.1-11.7L321.2,462z M240,471.4c-18.8-1.4-37-5.2-54.1-11.1l-12.6,29.5c21.1,7.5,43.5,12.2,66.8,13.6V471.4z M462,190.8c5,15.7,8.2,32.2,9.4,49.2h32.1 c-1.4-21.2-5.4-41.7-11.7-61.1L462,190.8z M92.4,397c-12-13.9-22.3-29.4-30.4-46.1l-29.8,11.9c9.9,20.7,22.6,39.8,37.6,56.9 L92.4,397z M272,40.6c18.8,1.4,36.9,5.2,54.1,11.1l12.6-29.5C317.7,14.7,295.3,10,272,8.5V40.6z M190.8,50 c15.7-5,32.2-8.2,49.2-9.4V8.5c-21.2,1.4-41.7,5.4-61.1,11.7L190.8,50z M442.3,92.3L419.6,115c12,13.9,22.3,29.4,30.5,46.1 l29.8-11.9C470,128.5,457.3,109.4,442.3,92.3z M397,92.4l22.7-22.7c-15.6-13.7-32.8-25.5-51.5-34.9l-12.6,29.5 C370.4,72.1,384.4,81.5,397,92.4z"}),s({},lt,{attributeName:"opacity"}));function ht(t){var e=t[0],n=t[1],i=c(t.slice(4),1)[0];return{found:!0,width:e,height:n,icon:Array.isArray(i)?{tag:"g",attributes:{class:"".concat(T.familyPrefix,"-").concat(_.GROUP)},children:[{tag:"path",attributes:{class:"".concat(T.familyPrefix,"-").concat(_.SECONDARY),fill:"currentColor",d:i[0]}},{tag:"path",attributes:{class:"".concat(T.familyPrefix,"-").concat(_.PRIMARY),fill:"currentColor",d:i[1]}}]}:{tag:"path",attributes:{fill:"currentColor",d:i}}}}function ft(){T.autoAddCss&&!wt&&(function(t){if(t&&m){var e=g.createElement("style");e.setAttribute("type","text/css"),e.innerHTML=t;for(var n=g.head.childNodes,i=null,r=n.length-1;r>-1;r--){var o=n[r],a=(o.tagName||"").toUpperCase();["STYLE","LINK"].indexOf(a)>-1&&(i=o)}g.head.insertBefore(e,i)}}(function(){var t="svg-inline--fa",e=T.familyPrefix,n=T.replacementClass,i='svg:not(:root).svg-inline--fa {\n overflow: visible;\n}\n\n.svg-inline--fa {\n display: inline-block;\n font-size: inherit;\n height: 1em;\n overflow: visible;\n vertical-align: -0.125em;\n}\n.svg-inline--fa.fa-lg {\n vertical-align: -0.225em;\n}\n.svg-inline--fa.fa-w-1 {\n width: 0.0625em;\n}\n.svg-inline--fa.fa-w-2 {\n width: 0.125em;\n}\n.svg-inline--fa.fa-w-3 {\n width: 0.1875em;\n}\n.svg-inline--fa.fa-w-4 {\n width: 0.25em;\n}\n.svg-inline--fa.fa-w-5 {\n width: 0.3125em;\n}\n.svg-inline--fa.fa-w-6 {\n width: 0.375em;\n}\n.svg-inline--fa.fa-w-7 {\n width: 0.4375em;\n}\n.svg-inline--fa.fa-w-8 {\n width: 0.5em;\n}\n.svg-inline--fa.fa-w-9 {\n width: 0.5625em;\n}\n.svg-inline--fa.fa-w-10 {\n width: 0.625em;\n}\n.svg-inline--fa.fa-w-11 {\n width: 0.6875em;\n}\n.svg-inline--fa.fa-w-12 {\n width: 0.75em;\n}\n.svg-inline--fa.fa-w-13 {\n width: 0.8125em;\n}\n.svg-inline--fa.fa-w-14 {\n width: 0.875em;\n}\n.svg-inline--fa.fa-w-15 {\n width: 0.9375em;\n}\n.svg-inline--fa.fa-w-16 {\n width: 1em;\n}\n.svg-inline--fa.fa-w-17 {\n width: 1.0625em;\n}\n.svg-inline--fa.fa-w-18 {\n width: 1.125em;\n}\n.svg-inline--fa.fa-w-19 {\n width: 1.1875em;\n}\n.svg-inline--fa.fa-w-20 {\n width: 1.25em;\n}\n.svg-inline--fa.fa-pull-left {\n margin-right: 0.3em;\n width: auto;\n}\n.svg-inline--fa.fa-pull-right {\n margin-left: 0.3em;\n width: auto;\n}\n.svg-inline--fa.fa-border {\n height: 1.5em;\n}\n.svg-inline--fa.fa-li {\n width: 2em;\n}\n.svg-inline--fa.fa-fw {\n width: 1.25em;\n}\n\n.fa-layers svg.svg-inline--fa {\n bottom: 0;\n left: 0;\n margin: auto;\n position: absolute;\n right: 0;\n top: 0;\n}\n\n.fa-layers {\n display: inline-block;\n height: 1em;\n position: relative;\n text-align: center;\n vertical-align: -0.125em;\n width: 1em;\n}\n.fa-layers svg.svg-inline--fa {\n -webkit-transform-origin: center center;\n transform-origin: center center;\n}\n\n.fa-layers-counter, .fa-layers-text {\n display: inline-block;\n position: absolute;\n text-align: center;\n}\n\n.fa-layers-text {\n left: 50%;\n top: 50%;\n -webkit-transform: translate(-50%, -50%);\n transform: translate(-50%, -50%);\n -webkit-transform-origin: center center;\n transform-origin: center center;\n}\n\n.fa-layers-counter {\n background-color: #ff253a;\n border-radius: 1em;\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n color: #fff;\n height: 1.5em;\n line-height: 1;\n max-width: 5em;\n min-width: 1.5em;\n overflow: hidden;\n padding: 0.25em;\n right: 0;\n text-overflow: ellipsis;\n top: 0;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: top right;\n transform-origin: top right;\n}\n\n.fa-layers-bottom-right {\n bottom: 0;\n right: 0;\n top: auto;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: bottom right;\n transform-origin: bottom right;\n}\n\n.fa-layers-bottom-left {\n bottom: 0;\n left: 0;\n right: auto;\n top: auto;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: bottom left;\n transform-origin: bottom left;\n}\n\n.fa-layers-top-right {\n right: 0;\n top: 0;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: top right;\n transform-origin: top right;\n}\n\n.fa-layers-top-left {\n left: 0;\n right: auto;\n top: 0;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: top left;\n transform-origin: top left;\n}\n\n.fa-lg {\n font-size: 1.3333333333em;\n line-height: 0.75em;\n vertical-align: -0.0667em;\n}\n\n.fa-xs {\n font-size: 0.75em;\n}\n\n.fa-sm {\n font-size: 0.875em;\n}\n\n.fa-1x {\n font-size: 1em;\n}\n\n.fa-2x {\n font-size: 2em;\n}\n\n.fa-3x {\n font-size: 3em;\n}\n\n.fa-4x {\n font-size: 4em;\n}\n\n.fa-5x {\n font-size: 5em;\n}\n\n.fa-6x {\n font-size: 6em;\n}\n\n.fa-7x {\n font-size: 7em;\n}\n\n.fa-8x {\n font-size: 8em;\n}\n\n.fa-9x {\n font-size: 9em;\n}\n\n.fa-10x {\n font-size: 10em;\n}\n\n.fa-fw {\n text-align: center;\n width: 1.25em;\n}\n\n.fa-ul {\n list-style-type: none;\n margin-left: 2.5em;\n padding-left: 0;\n}\n.fa-ul > li {\n position: relative;\n}\n\n.fa-li {\n left: -2em;\n position: absolute;\n text-align: center;\n width: 2em;\n line-height: inherit;\n}\n\n.fa-border {\n border: solid 0.08em #eee;\n border-radius: 0.1em;\n padding: 0.2em 0.25em 0.15em;\n}\n\n.fa-pull-left {\n float: left;\n}\n\n.fa-pull-right {\n float: right;\n}\n\n.fa.fa-pull-left,\n.fas.fa-pull-left,\n.far.fa-pull-left,\n.fal.fa-pull-left,\n.fab.fa-pull-left {\n margin-right: 0.3em;\n}\n.fa.fa-pull-right,\n.fas.fa-pull-right,\n.far.fa-pull-right,\n.fal.fa-pull-right,\n.fab.fa-pull-right {\n margin-left: 0.3em;\n}\n\n.fa-spin {\n -webkit-animation: fa-spin 2s infinite linear;\n animation: fa-spin 2s infinite linear;\n}\n\n.fa-pulse {\n -webkit-animation: fa-spin 1s infinite steps(8);\n animation: fa-spin 1s infinite steps(8);\n}\n\n@-webkit-keyframes fa-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n\n@keyframes fa-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n.fa-rotate-90 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";\n -webkit-transform: rotate(90deg);\n transform: rotate(90deg);\n}\n\n.fa-rotate-180 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2)";\n -webkit-transform: rotate(180deg);\n transform: rotate(180deg);\n}\n\n.fa-rotate-270 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";\n -webkit-transform: rotate(270deg);\n transform: rotate(270deg);\n}\n\n.fa-flip-horizontal {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1)";\n -webkit-transform: scale(-1, 1);\n transform: scale(-1, 1);\n}\n\n.fa-flip-vertical {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";\n -webkit-transform: scale(1, -1);\n transform: scale(1, -1);\n}\n\n.fa-flip-both, .fa-flip-horizontal.fa-flip-vertical {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";\n -webkit-transform: scale(-1, -1);\n transform: scale(-1, -1);\n}\n\n:root .fa-rotate-90,\n:root .fa-rotate-180,\n:root .fa-rotate-270,\n:root .fa-flip-horizontal,\n:root .fa-flip-vertical,\n:root .fa-flip-both {\n -webkit-filter: none;\n filter: none;\n}\n\n.fa-stack {\n display: inline-block;\n height: 2em;\n position: relative;\n width: 2.5em;\n}\n\n.fa-stack-1x,\n.fa-stack-2x {\n bottom: 0;\n left: 0;\n margin: auto;\n position: absolute;\n right: 0;\n top: 0;\n}\n\n.svg-inline--fa.fa-stack-1x {\n height: 1em;\n width: 1.25em;\n}\n.svg-inline--fa.fa-stack-2x {\n height: 2em;\n width: 2.5em;\n}\n\n.fa-inverse {\n color: #fff;\n}\n\n.sr-only {\n border: 0;\n clip: rect(0, 0, 0, 0);\n height: 1px;\n margin: -1px;\n overflow: hidden;\n padding: 0;\n position: absolute;\n width: 1px;\n}\n\n.sr-only-focusable:active, .sr-only-focusable:focus {\n clip: auto;\n height: auto;\n margin: 0;\n overflow: visible;\n position: static;\n width: auto;\n}\n\n.svg-inline--fa .fa-primary {\n fill: var(--fa-primary-color, currentColor);\n opacity: 1;\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa .fa-secondary {\n fill: var(--fa-secondary-color, currentColor);\n opacity: 0.4;\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-primary {\n opacity: 0.4;\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-secondary {\n opacity: 1;\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa mask .fa-primary,\n.svg-inline--fa mask .fa-secondary {\n fill: black;\n}\n\n.fad.fa-inverse {\n color: #fff;\n}';if("fa"!==e||n!==t){var r=new RegExp("\\.".concat("fa","\\-"),"g"),o=new RegExp("\\--".concat("fa","\\-"),"g"),a=new RegExp("\\.".concat(t),"g");i=i.replace(r,".".concat(e,"-")).replace(o,"--".concat(e,"-")).replace(a,".".concat(n))}return i}()),wt=!0)}function pt(t,e){return Object.defineProperty(t,"abstract",{get:e}),Object.defineProperty(t,"html",{get:function(){return t.abstract.map((function(t){return st(t)}))}}),Object.defineProperty(t,"node",{get:function(){if(m){var e=g.createElement("div");return e.innerHTML=t.html,e.children}}}),t}function bt(t){var e=t.prefix,n=void 0===e?"fa":e,i=t.iconName;if(i)return at(kt.definitions,n,i)||at(E.styles,n,i)}s({},ut,{cx:"256",cy:"364",r:"28"}),s({},lt,{attributeName:"r",values:"28;14;28;28;14;28;"}),s({},dt,{values:"1;0;1;1;0;1;"}),s({},ut,{opacity:"1",d:"M263.7,312h-16c-6.6,0-12-5.4-12-12c0-71,77.4-63.9,77.4-107.8c0-20-17.8-40.2-57.4-40.2c-29.1,0-44.3,9.6-59.2,28.7 c-3.9,5-11.1,6-16.2,2.4l-13.1-9.2c-5.6-3.9-6.9-11.8-2.6-17.2c21.2-27.2,46.4-44.7,91.2-44.7c52.3,0,97.4,29.8,97.4,80.2 c0,67.6-77.4,63.5-77.4,107.8C275.7,306.6,270.3,312,263.7,312z"}),s({},dt,{values:"1;0;0;0;0;1;"}),s({},ut,{opacity:"0",d:"M232.5,134.5l7,168c0.3,6.4,5.6,11.5,12,11.5h9c6.4,0,11.7-5.1,12-11.5l7-168c0.3-6.8-5.2-12.5-12-12.5h-23 C237.7,122,232.2,127.7,232.5,134.5z"}),s({},dt,{values:"0;0;1;1;0;0;"});var gt,mt,vt,yt,_t,Ot,kt=new(function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.definitions={}}var e;return(e=[{key:"add",value:function(){for(var t=this,e=arguments.length,n=new Array(e),i=0;i1&&void 0!==arguments[1]?arguments[1]:{},n=e.transform,i=void 0===n?Q:n,r=e.symbol,o=void 0!==r&&r,a=e.mask,c=void 0===a?null:a,u=e.maskId,l=void 0===u?null:u,d=e.title,h=void 0===d?null:d,f=e.titleId,p=void 0===f?null:f,b=e.classes,g=void 0===b?[]:b,m=e.attributes,v=void 0===m?{}:m,y=e.styles,_=void 0===y?{}:y;if(t){var O=t.prefix,k=t.iconName,w=t.icon;return pt(s({type:"icon"},t),(function(){return ft(),T.autoA11y&&(h?v["aria-labelledby"]="".concat(T.replacementClass,"-title-").concat(p||W()):(v["aria-hidden"]="true",v.focusable="false")),tt({icons:{main:ht(w),mask:c?ht(c.icon):{found:!1,width:null,height:null,icon:{}}},prefix:O,iconName:k,transform:s({},Q,i),symbol:o,title:h,maskId:l,titleId:p,extra:{attributes:v,styles:_,classes:g}})}))}},function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=(t||{}).icon?t:bt(t||{}),i=e.mask;return i&&(i=(i||{}).icon?i:bt(i||{})),gt(n,s({},e,{mask:i}))}),Tt=((vt=function t(){C(this,t),this.defaultPrefix="fas",this.fallbackIcon=null,this.globalLibrary=!1}).\u0275fac=function(t){return new(t||vt)},vt.\u0275prov=Object(i.Kb)({factory:function(){return new vt},token:vt,providedIn:"root"}),vt),St=((mt=function(){function t(){C(this,t),this.definitions={}}return w(t,[{key:"addIcons",value:function(){for(var t=arguments.length,e=new Array(t),n=0;n....')}}]),t}()).\u0275fac=function(t){return new(t||Ot)},Ot.\u0275dir=i.Jb({type:Ot,selectors:[["fa-icon","stackItemSize",""],["fa-duotone-icon","stackItemSize",""]],inputs:{stackItemSize:"stackItemSize",size:"size"},features:[i.Ab]}),Ot),xt=((_t=function(){function t(e,n,i,r){C(this,t),this.sanitizer=e,this.config=n,this.iconLibrary=i,this.stackItem=r,this.classes=[]}return w(t,[{key:"ngOnChanges",value:function(t){if(null==this.icon&&null==this.config.fallbackIcon)return function(){throw new Error("Property `icon` is required for `fa-icon`/`fa-duotone-icon` components.")}();var e;if(e=null==this.icon?this.config.fallbackIcon:this.icon,t){var n=this.findIconDefinition(e);if(null!=n){var i=this.buildParams();this.renderIcon(n,i)}}}},{key:"render",value:function(){this.ngOnChanges({})}},{key:"findIconDefinition",value:function(t){var e=function(t,e){return void 0!==(n=t).prefix&&void 0!==n.iconName?t:Array.isArray(t)&&2===t.length?{prefix:t[0],iconName:t[1]}:"string"==typeof t?{prefix:e,iconName:t}:void 0;var n}(t,this.config.defaultPrefix);if("icon"in e)return e;var n=this.iconLibrary.getIconDefinition(e.prefix,e.iconName);if(null!=n)return n;var i=bt(e);if(null!=i){var r="Global icon library is deprecated. Consult https://github.com/FortAwesome/angular-fontawesome/blob/master/UPGRADING.md for the migration instructions.";if("unset"===this.config.globalLibrary)console.error("FontAwesome: "+r);else if(!this.config.globalLibrary)throw new Error(r);return i}return function(t){throw new Error("Could not find icon with iconName=".concat(t.iconName," and prefix=").concat(t.prefix," in the icon library."))}(e),null}},{key:"buildParams",value:function(){var t,e,n,i,r,o={flip:this.flip,spin:this.spin,pulse:this.pulse,border:this.border,inverse:this.inverse,size:this.size||null,pull:this.pull||null,rotate:this.rotate||null,fixedWidth:"boolean"==typeof this.fixedWidth?this.fixedWidth:this.config.fixedWidth,stackItemSize:null!=this.stackItem?this.stackItem.stackItemSize:null},a="string"==typeof this.transform?(t=this.transform,e={size:16,x:0,y:0,flipX:!1,flipY:!1,rotate:0},t?t.toLowerCase().split(" ").reduce((function(t,e){var n=e.toLowerCase().split("-"),i=n[0],r=n.slice(1).join("-");if(i&&"h"===r)return t.flipX=!0,t;if(i&&"v"===r)return t.flipY=!0,t;if(r=parseFloat(r),isNaN(r))return t;switch(i){case"grow":t.size=t.size+r;break;case"shrink":t.size=t.size-r;break;case"left":t.x=t.x-r;break;case"right":t.x=t.x+r;break;case"up":t.y=t.y-r;break;case"down":t.y=t.y+r;break;case"rotate":t.rotate=t.rotate+r}return t}),e):e):this.transform;return{title:this.title,transform:a,classes:[].concat(b((n=o,f(i={"fa-spin":n.spin,"fa-pulse":n.pulse,"fa-fw":n.fixedWidth,"fa-border":n.border,"fa-inverse":n.inverse,"fa-layers-counter":n.counter,"fa-flip-horizontal":"horizontal"===n.flip||"both"===n.flip,"fa-flip-vertical":"vertical"===n.flip||"both"===n.flip},"fa-"+n.size,null!==n.size),f(i,"fa-rotate-"+n.rotate,null!==n.rotate),f(i,"fa-pull-"+n.pull,null!==n.pull),f(i,"fa-stack-"+n.stackItemSize,null!=n.stackItemSize),r=i,Object.keys(r).map((function(t){return r[t]?t:null})).filter((function(t){return t})))),b(this.classes)),mask:null!=this.mask?this.findIconDefinition(this.mask):null,styles:null!=this.styles?this.styles:{},symbol:this.symbol,attributes:{role:this.a11yRole}}}},{key:"renderIcon",value:function(t,e){var n=Ct(t,e);this.renderedIconHTML=this.sanitizer.bypassSecurityTrustHtml(n.html.join("\n"))}}]),t}()).\u0275fac=function(t){return new(t||_t)(i.Ob(r.b),i.Ob(Tt),i.Ob(St),i.Ob(Et,8))},_t.\u0275cmp=i.Ib({type:_t,selectors:[["fa-icon"]],hostAttrs:[1,"ng-fa-icon"],hostVars:2,hostBindings:function(t,e){2&t&&(i.Xb("innerHTML",e.renderedIconHTML,i.Fc),i.Db("title",e.title))},inputs:{classes:"classes",icon:"icon",title:"title",spin:"spin",pulse:"pulse",mask:"mask",styles:"styles",flip:"flip",size:"size",pull:"pull",border:"border",inverse:"inverse",symbol:"symbol",rotate:"rotate",fixedWidth:"fixedWidth",transform:"transform",a11yRole:"a11yRole"},features:[i.Ab],decls:0,vars:0,template:function(t,e){},encapsulation:2}),_t),Pt=((yt=function t(){C(this,t)}).\u0275mod=i.Mb({type:yt}),yt.\u0275inj=i.Lb({factory:function(t){return new(t||yt)}}),yt)},Nxx2:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(){function t(){}return t.numberOfTrailingZeros=function(t){var e;if(0===t)return 32;var n=31;return 0!=(e=t<<16)&&(n-=16,t=e),0!=(e=t<<8)&&(n-=8,t=e),0!=(e=t<<4)&&(n-=4,t=e),0!=(e=t<<2)&&(n-=2,t=e),n-(t<<1>>>31)},t.numberOfLeadingZeros=function(t){if(0===t)return 32;var e=1;return t>>>16==0&&(e+=16,t<<=16),t>>>24==0&&(e+=8,t<<=8),t>>>28==0&&(e+=4,t<<=4),t>>>30==0&&(e+=2,t<<=2),e-(t>>>31)},t.toHexString=function(t){return t.toString(16)},t.bitCount=function(t){return t=(t=(858993459&(t-=t>>>1&1431655765))+(t>>>2&858993459))+(t>>>4)&252645135,63&(t+=t>>>8)+(t>>>16)},t.MIN_VALUE_32_BITS=-2147483648,t}()},O0qa:function(t,e,n){"use strict";n.d(e,"a",(function(){return U}));var i=n("zqNl"),r=n("HM3f"),o=n("jOdJ"),a=n("i67J"),s=n("uJYd"),c=n("h3eB"),u=n("+Px6"),l=n("YyhG"),d=n("J/3c"),h=n("sxqi"),f=n("rxqU"),p=n("kZht"),b=n("aDqW"),g=n("Eu46"),v=n("UVqw"),y=n("An66"),_=n("v4/B"),O=n("VbQ3"),k=n("s96x"),T=n("anSm"),S=n("1o0v"),E=n("NxuZ"),x=n("7J2L");function P(t,e){if(1&t){var n=p.Vb();p.Ub(0,"open-orders-mobile",8),p.bc("selectTicker",(function(t){return p.Ec(n),p.fc(3).selectTicker(t)}))("editOrder",(function(t){return p.Ec(n),p.fc(3).editOrder(t)}))("cancelOrder",(function(t){return p.Ec(n),p.fc(3).cancelOrder(t)}))("viewDetailed",(function(t){return p.Ec(n),p.fc(3).viewDetailed(t)})),p.Tb()}2&t&&p.mc("order",e.$implicit)}function A(t,e){if(1&t){var n=p.Vb();p.Sb(0),p.Ub(1,"open-orders-desktop",5),p.bc("selectTicker",(function(t){return p.Ec(n),p.fc(2).selectTicker(t)}))("editOrder",(function(t){return p.Ec(n),p.fc(2).editOrder(t)}))("cancelOrder",(function(t){return p.Ec(n),p.fc(2).cancelOrder(t)}))("cancelAllOrders",(function(){return p.Ec(n),p.fc(2).cancelAllOrders()}))("viewDetailed",(function(t){return p.Ec(n),p.fc(2).viewDetailed(t)})),p.gc(2,"async"),p.Tb(),p.Ub(3,"cdk-virtual-scroll-viewport",6),p.Oc(4,P,1,1,"open-orders-mobile",7),p.Tb(),p.Rb()}if(2&t){var i=p.fc().ngLet,r=p.fc();p.Cb(1),p.mc("orders",i)("displayTooltips",p.hc(2,4,r.displayTooltips$)),p.Cb(2),p.mc("itemSize",90),p.Cb(1),p.mc("cdkVirtualForOf",i.valueSeq().toArray())}}var I=function(){return{small:100,medium:400,large:800}};function M(t,e){if(1&t&&(p.Ub(0,"div",3),p.Oc(1,A,5,6,"ng-container",4),p.Tb()),2&t){var n=e.ngLet;p.fc();var i=p.Ac(3);p.mc("breakpoints",p.qc(3,I)),p.Cb(1),p.mc("ngIf",n&&n.size>0)("ngIfElse",i)}}var D=function(t){return{pair:t}};function R(t,e){if(1&t&&(p.Ub(0,"p"),p.Qc(1),p.gc(2,"translate"),p.Tb()),2&t){var n=e.ngIf;p.Cb(1),p.Sc(" ",p.ic(2,1,"NO_CONTENT.PAIR_OPEN_ORDERS",p.rc(4,D,n))," ")}}function j(t,e){1&t&&(p.Ub(0,"p",12),p.Qc(1,"NO_CONTENT.OPEN_ORDERS"),p.Tb())}function L(t,e){if(1&t&&(p.Ub(0,"section",9),p.Pb(1,"fa-icon",10),p.Oc(2,R,3,6,"p",4),p.gc(3,"async"),p.Oc(4,j,2,0,"ng-template",null,11,p.Pc),p.Tb()),2&t){var n=p.Ac(5),i=p.fc(),r=null;p.Cb(2),p.mc("ngIf",null==(r=p.hc(3,2,i.filterPair$))?null:r.orUndefined())("ngIfElse",n)}}function N(t,e){1&t&&p.Pb(0,"kraken-loading")}var U=function(){var t=function(){function t(e,n,r){C(this,t),this.store=e,this.translate=n,this.market=r,this.displayTooltips$=this.store.pipe(Object(i.m)(f.y)),this.orders$=this.store.pipe(Object(i.m)(l.l),Object(a.p)()),this.instruments$=this.store.pipe(Object(i.m)(u.f)),this.filterPair$=this.store.pipe(Object(i.m)(f.q)),this.userSelectedFuturesWallet$=this.store.pipe(Object(i.m)(d.n))}return w(t,[{key:"selectTicker",value:function(t){var e=t.symbol,n=t.replaceUrl;this.market.navigateToMarket(e,n)}},{key:"editOrder",value:function(t){var e=this,n=t.order;this.selectTicker({symbol:n.instrument,replaceUrl:!1}),Object(r.a)([this.instruments$,this.userSelectedFuturesWallet$]).pipe(Object(o.a)()).subscribe((function(t){var i=m(t,2),r=i[0],o=i[1],a=r.get(n.instrument),c=null==o?void 0:o.am;e.store.dispatch(Object(s.g)({name:"edit-order",inputs:{order:n,instrument:a,availableMargin:c}}))}))}},{key:"cancelOrder",value:function(t){var e=t.id;this.store.dispatch(Object(c.d)({id:e}))}},{key:"cancelAllOrders",value:function(){this.store.dispatch(Object(s.g)({name:"confirmation",inputs:{title:"DIALOG.CONFIRM_ORDER_CANCEL.TITLE",subtitle:"DIALOG.CONFIRM_ORDER_CANCEL.SUBTITLE",body:this.translate.instant("DIALOG.CONFIRM_ORDER_CANCEL.BODY"),buttons:[{label:"BUTTON.YES",colour:"accent",actions:[Object(c.c)(),Object(s.c)()]},{label:"BUTTON.NO",colour:"warn",actions:[Object(s.c)()]}]}}))}},{key:"viewDetailed",value:function(t){var e=this,n=t.order;this.instruments$.pipe(Object(a.h)()).subscribe((function(t){var i=t.get(n.instrument);e.store.dispatch(Object(s.g)({name:"order-details",inputs:{order:n,instrument:i}}))}))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(p.Ob(i.b),p.Ob(b.e),p.Ob(h.a))},t.\u0275cmp=p.Ib({type:t,selectors:[["open-orders"]],decls:6,vars:3,consts:[["class","table-wrapper","breakpoint","",3,"breakpoints",4,"ngLet"],["noEntries",""],["loader",""],["breakpoint","",1,"table-wrapper",3,"breakpoints"],[4,"ngIf","ngIfElse"],[3,"orders","displayTooltips","selectTicker","editOrder","cancelOrder","cancelAllOrders","viewDetailed"],[3,"itemSize"],[3,"order","selectTicker","editOrder","cancelOrder","viewDetailed",4,"cdkVirtualFor","cdkVirtualForOf"],[3,"order","selectTicker","editOrder","cancelOrder","viewDetailed"],["body","","ghost","",1,"no-activity"],["icon","list","size","3x"],["unfiltered",""],["translate",""]],template:function(t,e){1&t&&(p.Oc(0,M,2,4,"div",0),p.gc(1,"async"),p.Oc(2,L,6,4,"ng-template",null,1,p.Pc),p.Oc(4,N,1,0,"ng-template",null,2,p.Pc)),2&t&&p.mc("ngLet",p.hc(1,1,e.orders$))},directives:[g.a,v.a,y.n,_.a,O.e,O.a,O.d,k.a,T.a,S.a,E.b,b.a,x.a],pipes:[y.b,b.d],styles:["market-icon[_ngcontent-%COMP%]{font-size:20px}[_nghost-%COMP%]{display:flex;flex-direction:column;padding:var(--spacing)}.table-wrapper[_ngcontent-%COMP%], [_nghost-%COMP%]{height:100%}.no-activity[_ngcontent-%COMP%]{text-align:center;padding:var(--spacing-l)}cdk-virtual-scroll-viewport[_ngcontent-%COMP%]{height:100%}@media (max-width:1024px){.table-wrapper[_ngcontent-%COMP%] open-orders-desktop[_ngcontent-%COMP%]{display:none}.table-wrapper[_ngcontent-%COMP%] cdk-virtual-scroll-viewport[_ngcontent-%COMP%]{display:block!important}}.table-wrapper[breakpoint=large][_ngcontent-%COMP%] cdk-virtual-scroll-viewport[_ngcontent-%COMP%], .table-wrapper[breakpoint=medium][_ngcontent-%COMP%] cdk-virtual-scroll-viewport[_ngcontent-%COMP%], .table-wrapper[breakpoint=small][_ngcontent-%COMP%] open-orders-desktop[_ngcontent-%COMP%]{display:none}"],changeDetection:0}),t}()},O1jd:function(t,e,n){"use strict";n.d(e,"a",(function(){return d})),n.d(e,"b",(function(){return h})),n.d(e,"c",(function(){return v})),n.d(e,"d",(function(){return m})),n.d(e,"e",(function(){return p})),n.d(e,"f",(function(){return b})),n.d(e,"g",(function(){return g}));var i,r=n("kZht"),o=n("An66");try{i="undefined"!=typeof Intl&&Intl.v8BreakIterator}catch(y){i=!1}var a,s,c,u,l,d=function(){var t=function t(e){C(this,t),this._platformId=e,this.isBrowser=this._platformId?Object(o.z)(this._platformId):"object"==typeof document&&!!document,this.EDGE=this.isBrowser&&/(edge)/i.test(navigator.userAgent),this.TRIDENT=this.isBrowser&&/(msie|trident)/i.test(navigator.userAgent),this.BLINK=this.isBrowser&&!(!window.chrome&&!i)&&"undefined"!=typeof CSS&&!this.EDGE&&!this.TRIDENT,this.WEBKIT=this.isBrowser&&/AppleWebKit/i.test(navigator.userAgent)&&!this.BLINK&&!this.EDGE&&!this.TRIDENT,this.IOS=this.isBrowser&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!("MSStream"in window),this.FIREFOX=this.isBrowser&&/(firefox|minefield)/i.test(navigator.userAgent),this.ANDROID=this.isBrowser&&/android/i.test(navigator.userAgent)&&!this.TRIDENT,this.SAFARI=this.isBrowser&&/safari/i.test(navigator.userAgent)&&this.WEBKIT};return t.\u0275fac=function(e){return new(e||t)(r.Yb(r.D))},t.\u0275prov=Object(r.Kb)({factory:function(){return new t(Object(r.Yb)(r.D))},token:t,providedIn:"root"}),t}(),h=function(){var t=function t(){C(this,t)};return t.\u0275mod=r.Mb({type:t}),t.\u0275inj=r.Lb({factory:function(e){return new(e||t)}}),t}(),f=["color","button","checkbox","date","datetime-local","email","file","hidden","image","month","number","password","radio","range","reset","search","submit","tel","text","time","url","week"];function p(){if(a)return a;if("object"!=typeof document||!document)return a=new Set(f);var t=document.createElement("input");return a=new Set(f.filter((function(e){return t.setAttribute("type",e),t.type===e})))}function b(t){return function(){if(null==s&&"undefined"!=typeof window)try{window.addEventListener("test",null,Object.defineProperty({},"passive",{get:function(){return s=!0}}))}finally{s=s||!1}return s}()?t:!!t.capture}function g(){if(null==u)if("object"==typeof document&&document||(u=!1),"scrollBehavior"in document.documentElement.style)u=!0;else{var t=Element.prototype.scrollTo;u=!!t&&!/\{\s*\[native code\]\s*\}/.test(t.toString())}return u}function m(){if("object"!=typeof document||!document)return 0;if(null==c){var t=document.createElement("div"),e=t.style;t.dir="rtl",e.width="1px",e.overflow="auto",e.visibility="hidden",e.pointerEvents="none",e.position="absolute";var n=document.createElement("div"),i=n.style;i.width="2px",i.height="1px",t.appendChild(n),document.body.appendChild(t),c=0,0===t.scrollLeft&&(t.scrollLeft=1,c=0===t.scrollLeft?1:2),t.parentNode.removeChild(t)}return c}function v(t){if(function(){if(null==l){var t="undefined"!=typeof document?document.head:null;l=!(!t||!t.createShadowRoot&&!t.attachShadow)}return l}()){var e=t.getRootNode?t.getRootNode():null;if("undefined"!=typeof ShadowRoot&&ShadowRoot&&e instanceof ShadowRoot)return e}return null}},O30t:function(t,e,n){"use strict";n.d(e,"a",(function(){return te})),n.d(e,"b",(function(){return Qt})),n.d(e,"c",(function(){return Kt})),n.d(e,"d",(function(){return Xt})),n.d(e,"e",(function(){return Gt})),n.d(e,"f",(function(){return ae})),n.d(e,"g",(function(){return ne})),n.d(e,"h",(function(){return ce})),n.d(e,"i",(function(){return re})),n.d(e,"j",(function(){return qt})),n.d(e,"k",(function(){return de})),n.d(e,"l",(function(){return le}));var i=n("vE5V"),r=n("5XID"),s=n("sBeF"),u=n("kZht"),l=n("O1jd"),d=n("An66"),f=n("ZTXN"),g=n("GoAz"),v=n("C05f"),y=n("9bRT"),_=n("ROBh"),O=n("kuMc"),k=n("J+dc"),T=n("VbQ3"),S=[[["caption"]],[["colgroup"],["col"]]],E=["caption","colgroup, col"];function x(t){return function(t){a(n,t);var e=c(n);function n(){var t;C(this,n);for(var i=arguments.length,r=new Array(i),o=0;o4&&void 0!==arguments[4])||arguments[4],a=!(arguments.length>5&&void 0!==arguments[5])||arguments[5];C(this,t),this._isNativeHtmlTable=e,this._stickCellCss=n,this.direction=i,this._coalescedStyleScheduler=r,this._isBrowser=o,this._needsPositionStickyOnElement=a}return w(t,[{key:"clearStickyPositioning",value:function(t,e){var n,i=this,r=[],o=p(t);try{for(o.s();!(n=o.n()).done;){var a=n.value;if(a.nodeType===a.ELEMENT_NODE){r.push(a);for(var s=0;s0;r--)e[r]&&(n[r]=i,i+=t[r]);return n}}]),t}(),vt=((G=function t(e,n){C(this,t),this.viewContainer=e,this.elementRef=n}).\u0275fac=function(t){return new(t||G)(u.Ob(u.R),u.Ob(u.l))},G.\u0275dir=u.Jb({type:G,selectors:[["","rowOutlet",""]]}),G),yt=((W=function t(e,n){C(this,t),this.viewContainer=e,this.elementRef=n}).\u0275fac=function(t){return new(t||W)(u.Ob(u.R),u.Ob(u.l))},W.\u0275dir=u.Jb({type:W,selectors:[["","headerRowOutlet",""]]}),W),_t=((Q=function t(e,n){C(this,t),this.viewContainer=e,this.elementRef=n}).\u0275fac=function(t){return new(t||Q)(u.Ob(u.R),u.Ob(u.l))},Q.\u0275dir=u.Jb({type:Q,selectors:[["","footerRowOutlet",""]]}),Q),Ot=(($=function t(e,n){C(this,t),this.viewContainer=e,this.elementRef=n}).\u0275fac=function(t){return new(t||$)(u.Ob(u.R),u.Ob(u.l))},$.\u0275dir=u.Jb({type:$,selectors:[["","noDataRowOutlet",""]]}),$),kt=((q=function(){function t(e,n,i,r,o,a,s,c,u){C(this,t),this._differs=e,this._changeDetectorRef=n,this._coalescedStyleScheduler=i,this._elementRef=r,this._dir=a,this._platform=c,this._viewRepeater=u,this._onDestroy=new f.b,this._columnDefsByName=new Map,this._customColumnDefs=new Set,this._customRowDefs=new Set,this._customHeaderRowDefs=new Set,this._customFooterRowDefs=new Set,this._headerRowDefChanged=!0,this._footerRowDefChanged=!0,this._cachedRenderRowsMap=new Map,this.stickyCssClass="cdk-table-sticky",this.needsPositionStickyOnElement=!0,this._isShowingNoDataRow=!1,this._multiTemplateDataRows=!1,this.viewChange=new v.a({start:0,end:Number.MAX_VALUE}),o||this._elementRef.nativeElement.setAttribute("role","grid"),this._document=s,this._isNativeHtmlTable="TABLE"===this._elementRef.nativeElement.nodeName}return w(t,[{key:"ngOnInit",value:function(){var t=this;this._setupStickyStyler(),this._isNativeHtmlTable&&this._applyNativeTableSections(),this._dataDiffer=this._differs.find([]).create((function(e,n){return t.trackBy?t.trackBy(n.dataIndex,n.data):n}))}},{key:"ngAfterContentChecked",value:function(){this._cacheRowDefs(),this._cacheColumnDefs();var t=this._renderUpdatedColumns()||this._headerRowDefChanged||this._footerRowDefChanged;this._headerRowDefChanged&&(this._forceRenderHeaderRows(),this._headerRowDefChanged=!1),this._footerRowDefChanged&&(this._forceRenderFooterRows(),this._footerRowDefChanged=!1),this.dataSource&&this._rowDefs.length>0&&!this._renderChangeSubscription?this._observeRenderChanges():t&&this.updateStickyColumnStyles(),this._checkStickyStates()}},{key:"ngOnDestroy",value:function(){this._rowOutlet.viewContainer.clear(),this._noDataRowOutlet.viewContainer.clear(),this._headerRowOutlet.viewContainer.clear(),this._footerRowOutlet.viewContainer.clear(),this._cachedRenderRowsMap.clear(),this._onDestroy.next(),this._onDestroy.complete(),Object(s.h)(this.dataSource)&&this.dataSource.disconnect(this)}},{key:"renderRows",value:function(){var t=this;this._renderRows=this._getAllRenderRows();var e=this._dataDiffer.diff(this._renderRows);if(e){var n=this._rowOutlet.viewContainer;this._viewRepeater.applyChanges(e,n,(function(e,n,i){return t._getEmbeddedViewArgs(e.item,i)}),(function(t){return t.item.data}),(function(e){1===e.operation&&e.context&&t._renderCellTemplateForItem(e.record.item.rowDef,e.context)})),this._updateRowIndexContext(),e.forEachIdentityChange((function(t){n.get(t.currentIndex).context.$implicit=t.item.data})),this._updateNoDataRow(),this.updateStickyColumnStyles()}else this._updateNoDataRow()}},{key:"addColumnDef",value:function(t){this._customColumnDefs.add(t)}},{key:"removeColumnDef",value:function(t){this._customColumnDefs.delete(t)}},{key:"addRowDef",value:function(t){this._customRowDefs.add(t)}},{key:"removeRowDef",value:function(t){this._customRowDefs.delete(t)}},{key:"addHeaderRowDef",value:function(t){this._customHeaderRowDefs.add(t),this._headerRowDefChanged=!0}},{key:"removeHeaderRowDef",value:function(t){this._customHeaderRowDefs.delete(t),this._headerRowDefChanged=!0}},{key:"addFooterRowDef",value:function(t){this._customFooterRowDefs.add(t),this._footerRowDefChanged=!0}},{key:"removeFooterRowDef",value:function(t){this._customFooterRowDefs.delete(t),this._footerRowDefChanged=!0}},{key:"updateStickyHeaderRowStyles",value:function(){var t=this._getRenderedRows(this._headerRowOutlet),e=this._elementRef.nativeElement.querySelector("thead");e&&(e.style.display=t.length?"":"none");var n=this._headerRowDefs.map((function(t){return t.sticky}));this._stickyStyler.clearStickyPositioning(t,["top"]),this._stickyStyler.stickRows(t,n,"top"),this._headerRowDefs.forEach((function(t){return t.resetStickyChanged()}))}},{key:"updateStickyFooterRowStyles",value:function(){var t=this._getRenderedRows(this._footerRowOutlet),e=this._elementRef.nativeElement.querySelector("tfoot");e&&(e.style.display=t.length?"":"none");var n=this._footerRowDefs.map((function(t){return t.sticky}));this._stickyStyler.clearStickyPositioning(t,["bottom"]),this._stickyStyler.stickRows(t,n,"bottom"),this._stickyStyler.updateStickyFooterContainer(this._elementRef.nativeElement,n),this._footerRowDefs.forEach((function(t){return t.resetStickyChanged()}))}},{key:"updateStickyColumnStyles",value:function(){var t=this,e=this._getRenderedRows(this._headerRowOutlet),n=this._getRenderedRows(this._rowOutlet),i=this._getRenderedRows(this._footerRowOutlet);this._stickyStyler.clearStickyPositioning([].concat(b(e),b(n),b(i)),["left","right"]),e.forEach((function(e,n){t._addStickyColumnStyles([e],t._headerRowDefs[n])})),this._rowDefs.forEach((function(e){for(var i=[],r=0;r0&&this._headerRowOutlet.viewContainer.clear(),this._headerRowDefs.forEach((function(e,n){return t._renderRow(t._headerRowOutlet,e,n)})),this.updateStickyHeaderRowStyles()}},{key:"_forceRenderFooterRows",value:function(){var t=this;this._footerRowOutlet.viewContainer.length>0&&this._footerRowOutlet.viewContainer.clear(),this._footerRowDefs.forEach((function(e,n){return t._renderRow(t._footerRowOutlet,e,n)})),this.updateStickyFooterRowStyles()}},{key:"_addStickyColumnStyles",value:function(t,e){var n=this,i=Array.from(e.columns||[]).map((function(t){return n._columnDefsByName.get(t)})),r=i.map((function(t){return t.sticky})),o=i.map((function(t){return t.stickyEnd}));this._stickyStyler.updateStickyColumns(t,r,o)}},{key:"_getRenderedRows",value:function(t){for(var e=[],n=0;n3&&void 0!==arguments[3]?arguments[3]:{},r=t.viewContainer.createEmbeddedView(e.template,i,n);return this._renderCellTemplateForItem(e,i),r}},{key:"_renderCellTemplateForItem",value:function(t,e){var n,i=p(this._getCellTemplates(t));try{for(i.s();!(n=i.n()).done;){var r=n.value;ht.mostRecentCellOutlet&&ht.mostRecentCellOutlet._viewContainer.createEmbeddedView(r,e)}}catch(o){i.e(o)}finally{i.f()}this._changeDetectorRef.markForCheck()}},{key:"_updateRowIndexContext",value:function(){for(var t=this._rowOutlet.viewContainer,e=0,n=t.length;e0&&void 0!==arguments[0]?arguments[0]:[];return C(this,n),(t=e.call(this))._renderData=new v.a([]),t._filter=new v.a(""),t._internalPageChanges=new f.b,t._renderChangesSubscription=Ut.a.EMPTY,t.sortingDataAccessor=function(t,e){var n=t[e];if(Object(r.a)(n)){var i=Number(n);return i<9007199254740991?i:n}return n},t.sortData=function(e,n){var i=n.active,r=n.direction;return i&&""!=r?e.sort((function(e,n){var o=t.sortingDataAccessor(e,i),a=t.sortingDataAccessor(n,i),s=typeof o,c=typeof a;s!==c&&("number"===s&&(o+=""),"number"===c&&(a+=""));var u=0;return null!=o&&null!=a?o>a?u=1:o0)){var i=Math.ceil(n.length/n.pageSize)-1||0,r=Math.min(n.pageIndex,i);r!==n.pageIndex&&(n.pageIndex=r,e._internalPageChanges.next())}}))}},{key:"connect",value:function(){return this._renderData}},{key:"disconnect",value:function(){}},{key:"data",get:function(){return this._data.value},set:function(t){this._data.next(t)}},{key:"filter",get:function(){return this._filter.value},set:function(t){this._filter.next(t)}},{key:"sort",get:function(){return this._sort},set:function(t){this._sort=t,this._updateChangeSubscription()}},{key:"paginator",get:function(){return this._paginator},set:function(t){this._paginator=t,this._updateChangeSubscription()}}]),n}(s.b)},O5EP:function(t,e,n){"use strict";n.d(e,"a",(function(){return et}));var i=n("zqNl"),r=n("TYVA"),o=n("i67J"),a=n("vYTc"),s=n("uJYd"),c=n("wMit"),u=n("qAYy"),l=n("YyhG"),d=n("rxqU");function h(t){switch(t){case"XBT/USD":return"BRTI";case"ETH/USD":return"ETHUSD_RTI";case"XRP/USD":return"XRPUSD_RTI";case"XRP/XBT":return"XRPXBT_RTI";case"BCH/USD":return"BCHUSD_RTI";case"LTC/USD":return"LTCUSD_RTI";case"XBT/EUR":return"XBTEUR_RTI";case"ETH/EUR":return"ETHEUR_RTI"}}var f=n("kZht"),p=n("An66"),b=n("Eu46"),g=n("anSm"),m=n("IkSM"),v=n("B6Vo"),y=n("Cc4E"),_=n("zho4"),O=n("chaP"),k=n("LbKT"),T=n("6BNo"),S=n("1o0v"),E=n("Oj3S"),x=n("7J2L"),P=n("aDqW"),A=n("fvDn"),I=n("e7kw"),M=n("FUqb"),D=n("DpwM"),R=n("rqGg"),j=function(){return[250,100]};function L(t,e){if(1&t&&(f.Ub(0,"section",4),f.Ub(1,"p",21),f.Qc(2),f.gc(3,"translate"),f.Tb(),f.Ub(4,"a",22),f.gc(5,"supportArticle"),f.Qc(6),f.gc(7,"date"),f.Tb(),f.Tb()),2&t){var n=f.fc().ngLet,i=f.fc().$implicit;f.Cb(1),f.mc("sbDisabled",!n)("sbDelay",f.qc(12,j)),f.Cb(1),f.Sc(" ",f.hc(3,5,"LABEL.MATURITY_DATE"),": "),f.Cb(2),f.mc("href",f.hc(5,7,360022632172),f.Gc),f.Cb(2),f.Sc(" ",f.ic(7,9,i.maturityTime,"dd/MMM/yyyy")," ")}}function N(t,e){if(1&t&&(f.Ub(0,"section",4),f.Ub(1,"p",23),f.Qc(2),f.gc(3,"translate"),f.Tb(),f.Ub(4,"a",22),f.gc(5,"supportArticle"),f.Qc(6),f.gc(7,"date"),f.Tb(),f.Tb()),2&t){var n=f.fc().ngLet,i=f.fc().$implicit;f.Cb(1),f.mc("sbDisabled",!n)("sbDelay",f.qc(12,j)),f.Cb(1),f.Sc(" ",f.hc(3,5,"LABEL.MATURITY_TIME"),": "),f.Cb(2),f.mc("href",f.hc(5,7,360022632172),f.Gc),f.Cb(2),f.Sc(" ",f.ic(7,9,i.maturityTime,"HH:mm")," ")}}function U(t,e){if(1&t&&(f.Ub(0,"section",4),f.Ub(1,"p",24),f.Qc(2),f.gc(3,"translate"),f.Tb(),f.Ub(4,"strong",9),f.Qc(5),f.Tb(),f.Tb()),2&t){var n=f.fc().ngLet,i=f.fc().$implicit,r=f.fc();f.Cb(1),f.mc("sbDisabled",!n)("sbDelay",f.qc(6,j)),f.Cb(1),f.Sc(" ",f.hc(3,4,"LABEL.SETTLEMENT"),": "),f.Cb(3),f.Sc(" ",r.getSettlementTime(i.maturityTime)," ")}}function F(t,e){if(1&t){var n=f.Vb();f.Ub(0,"section",4),f.Ub(1,"p",25),f.Qc(2),f.gc(3,"translate"),f.Tb(),f.Ub(4,"a",26),f.bc("click",(function(t){f.Ec(n);var e=f.fc(2).$implicit;return f.fc().getFundingRates(e.product_id),t.stopPropagation()})),f.Qc(5),f.gc(6,"percent"),f.gc(7,"translate"),f.Tb(),f.Tb()}if(2&t){var i=f.fc().ngLet,r=f.fc().$implicit;f.Cb(1),f.mc("sbDisabled",!i)("sbDelay",f.qc(12,j)),f.Cb(1),f.Sc(" ",f.hc(3,5,"LABEL.FUNDING_RATE"),": "),f.Cb(3),f.Tc(" ",f.ic(6,7,r.relative_funding_rate,"1.4-4")," / ",f.hc(7,10,"UNIT.HOUR_SHORT")," ")}}function B(t,e){if(1&t&&(f.Ub(0,"section",4),f.Ub(1,"p",27),f.Qc(2),f.gc(3,"translate"),f.Tb(),f.Ub(4,"strong",9),f.Qc(5),f.gc(6,"percent"),f.gc(7,"translate"),f.Tb(),f.Tb()),2&t){var n=f.fc().ngLet,i=f.fc().$implicit;f.Cb(1),f.mc("sbDisabled",!n)("sbDelay",f.qc(12,j)),f.Cb(1),f.Sc(" ",f.hc(3,5,"LABEL.EST_NEXT_RATE"),": "),f.Cb(3),f.Tc(" ",f.ic(6,7,i.relative_funding_rate_prediction,"1.4-4")," / ",f.hc(7,10,"UNIT.HOUR_SHORT")," ")}}function z(t,e){if(1&t&&(f.Ub(0,"section",4),f.Ub(1,"p",28),f.Qc(2),f.gc(3,"translate"),f.Tb(),f.Ub(4,"strong",9),f.Qc(5),f.Tb(),f.Tb()),2&t){var n=f.fc().ngLet,i=f.fc().$implicit,r=f.fc();f.Cb(1),f.mc("sbDisabled",!n)("sbDelay",f.qc(6,j)),f.Cb(1),f.Sc(" ",f.hc(3,4,"LABEL.NEXT_RATE"),": "),f.Cb(3),f.Sc(" ",r.getSettlementTime(i.next_funding_rate_time)," ")}}function V(t,e){if(1&t&&(f.Ub(0,"a",7),f.Pb(1,"img",29),f.Qc(2),f.Ub(3,"span",9),f.Qc(4),f.gc(5,"sato"),f.Tb(),f.Tb()),2&t){var n=f.fc(2).$implicit,i=f.fc();f.mc("href",n&&i.getRTILink(n.pair),f.Gc),f.Cb(2),f.Sc(" ",n&&i.getRTIName(n.pair)," - "),f.Cb(2),f.Sc(" ",f.ic(5,3,n.index,n)," ")}}function H(t,e){if(1&t&&(f.Ub(0,"span",9),f.Qc(1),f.gc(2,"sato"),f.Tb()),2&t){var n=f.fc(2).$implicit;f.Cb(1),f.Sc(" ",f.ic(2,1,n.index,n)," ")}}function q(t,e){if(1&t&&(f.Ub(0,"section",4),f.Ub(1,"p",30),f.Qc(2),f.gc(3,"translate"),f.Tb(),f.Ub(4,"strong",31),f.Ub(5,"span"),f.Qc(6),f.gc(7,"sato"),f.Tb(),f.Qc(8),f.Ub(9,"span",32),f.Qc(10),f.gc(11,"asset"),f.Tb(),f.Tb(),f.Tb()),2&t){var n=e.ngIf,i=f.fc().ngLet;f.Cb(1),f.mc("sbDisabled",!i)("sbDelay",f.qc(14,j)),f.Cb(1),f.Sc(" ",f.hc(3,6,"LABEL.UNREALIZED_FUNDING"),": "),f.Cb(4),f.Sc(" ",f.jc(7,8,n.displayUnrealizedFunding,n.walletDisplayAsset,"full")," "),f.Cb(2),f.Sc(" "," "," "),f.Cb(2),f.Rc(f.hc(11,12,n.walletDisplayAsset))}}function $(t,e){if(1&t&&(f.Ub(0,"strong",31),f.Qc(1),f.gc(2,"crypto"),f.Tb()),2&t){var n=e.ngIfSome;f.Cb(1),f.Sc(" ",f.ic(2,1,n,"usd")," USD ")}}function Q(t,e){if(1&t&&(f.Ub(0,"section",4),f.Ub(1,"p"),f.Qc(2),f.gc(3,"translate"),f.Tb(),f.Oc(4,$,3,4,"strong",33),f.gc(5,"async"),f.Tb()),2&t){var n=f.fc(3);f.Cb(2),f.Sc("",f.hc(3,2,"LABEL.30_DAY_USER_VOLUME"),":"),f.Cb(2),f.mc("ngIfSome",f.hc(5,4,n.userFeeVolume$))}}function W(t,e){if(1&t){var n=f.Vb();f.Ub(0,"strong",36),f.bc("click",(function(){return f.Ec(n),f.fc(4).openFeeSchedule()})),f.Qc(1),f.gc(2,"percent"),f.Tb()}if(2&t){var i=e.ngIfSome;f.Cb(1),f.Sc(" ",f.ic(2,1,i.maker,"1.4-4")," ")}}function G(t,e){if(1&t&&(f.Ub(0,"section",4),f.Ub(1,"p"),f.Qc(2),f.gc(3,"translate"),f.Tb(),f.Pb(4,"a",34),f.Oc(5,W,3,4,"strong",35),f.gc(6,"async"),f.Tb()),2&t){var n=f.fc(3);f.Cb(2),f.Sc("",f.hc(3,2,"LABEL.USER_MAKER_FEE"),":"),f.Cb(3),f.mc("ngIfSome",f.hc(6,4,n.userFeeTier$))}}function Y(t,e){if(1&t){var n=f.Vb();f.Ub(0,"strong",36),f.bc("click",(function(){return f.Ec(n),f.fc(4).openFeeSchedule()})),f.Qc(1),f.gc(2,"percent"),f.Tb()}if(2&t){var i=e.ngIfSome;f.Cb(1),f.Sc(" ",f.ic(2,1,i.taker,"1.4-4")," ")}}function K(t,e){if(1&t&&(f.Ub(0,"section",4),f.Ub(1,"p"),f.Qc(2),f.gc(3,"translate"),f.Tb(),f.Oc(4,Y,3,4,"strong",35),f.gc(5,"async"),f.Tb()),2&t){var n=f.fc(3);f.Cb(2),f.Sc("",f.hc(3,2,"LABEL.USER_TAKER_FEE"),":"),f.Cb(2),f.mc("ngIfSome",f.hc(5,4,n.userFeeTier$))}}function Z(t,e){if(1&t&&(f.Ub(0,"section",3),f.Ub(1,"section",4),f.Ub(2,"p",5),f.Qc(3),f.gc(4,"translate"),f.Tb(),f.Ub(5,"strong"),f.Qc(6),f.gc(7,"cryptoAbbreviation"),f.Tb(),f.Tb(),f.Ub(8,"section",4),f.Ub(9,"p",6),f.Qc(10),f.gc(11,"translate"),f.Tb(),f.Ub(12,"a",7),f.gc(13,"supportArticle"),f.Qc(14),f.Tb(),f.Tb(),f.Ub(15,"section",4),f.Ub(16,"p",8),f.Qc(17),f.gc(18,"translate"),f.Tb(),f.Ub(19,"strong",9),f.Qc(20),f.gc(21,"number"),f.Tb(),f.Tb(),f.Ub(22,"section",4),f.Ub(23,"p",10),f.Qc(24),f.gc(25,"translate"),f.Tb(),f.Ub(26,"strong",9),f.Qc(27),f.gc(28,"number"),f.Tb(),f.Tb(),f.Oc(29,L,8,13,"section",11),f.Oc(30,N,8,13,"section",11),f.Oc(31,U,6,7,"section",11),f.Oc(32,F,8,13,"section",11),f.Oc(33,B,8,13,"section",11),f.Oc(34,z,6,7,"section",11),f.Ub(35,"section",4),f.Ub(36,"p",12),f.Qc(37),f.gc(38,"translate"),f.Tb(),f.Ub(39,"strong",13),f.Qc(40),f.gc(41,"change"),f.gc(42,"number"),f.Tb(),f.Tb(),f.Ub(43,"section",4),f.Ub(44,"p",14),f.Qc(45),f.gc(46,"translate"),f.Tb(),f.Oc(47,V,6,6,"a",15),f.Oc(48,H,3,4,"span",16),f.Tb(),f.Ub(49,"section",4),f.Ub(50,"p",17),f.Qc(51),f.gc(52,"translate"),f.Tb(),f.Ub(53,"strong",9),f.Qc(54),f.gc(55,"sato"),f.Tb(),f.Tb(),f.Ub(56,"section",4),f.Ub(57,"p",18),f.Qc(58),f.gc(59,"translate"),f.Tb(),f.Ub(60,"strong",9),f.Qc(61),f.gc(62,"sato"),f.Tb(),f.Tb(),f.Ub(63,"section",19),f.Ub(64,"p",20),f.Qc(65),f.gc(66,"translate"),f.Tb(),f.Ub(67,"strong",13),f.Qc(68),f.gc(69,"number"),f.Tb(),f.Tb(),f.Oc(70,q,12,15,"section",11),f.gc(71,"async"),f.Oc(72,Q,6,6,"section",11),f.gc(73,"async"),f.Oc(74,G,7,6,"section",11),f.gc(75,"async"),f.Oc(76,K,6,6,"section",11),f.gc(77,"async"),f.Tb()),2&t){var n=e.ngLet,i=f.fc().$implicit,r=f.fc();f.Cb(2),f.mc("sbDisabled",!n)("sbDelay",f.qc(99,j)),f.Cb(1),f.Sc(" ",f.hc(4,51,"LABEL.SYMBOL"),": "),f.Cb(3),f.Sc(" ",f.hc(7,53,i.product_id)," "),f.Cb(3),f.mc("sbDisabled",!n)("sbDelay",f.qc(100,j)),f.Cb(1),f.Sc(" ",f.hc(11,55,"LABEL.TYPE"),": "),f.Cb(2),f.mc("href",f.hc(13,57,r.instrumentSupport(i)),f.Gc),f.Cb(2),f.Tc(" ",r.instrumentGroup(i)," ",r.isPerpetual(i)?"Perpetuals":"Futures"," "),f.Cb(2),f.mc("sbDisabled",!n)("sbDelay",f.qc(101,j)),f.Cb(1),f.Sc(" ",f.hc(18,59,"LABEL.VOLUME"),": "),f.Cb(3),f.Sc(" ",f.hc(21,61,i.volume)," "),f.Cb(3),f.mc("sbDisabled",!n)("sbDelay",f.qc(102,j)),f.Cb(1),f.Sc(" ",f.hc(25,63,"LABEL.OPEN_INTEREST"),": "),f.Cb(3),f.Sc(" ",f.hc(28,65,i.openInterest)," "),f.Cb(2),f.mc("ngIf",!r.isPerpetual(i)),f.Cb(1),f.mc("ngIf",!r.isPerpetual(i)),f.Cb(1),f.mc("ngIf",!r.isPerpetual(i)),f.Cb(1),f.mc("ngIf",r.isPerpetual(i)),f.Cb(1),f.mc("ngIf",r.isPerpetual(i)),f.Cb(1),f.mc("ngIf",r.isPerpetual(i)),f.Cb(2),f.mc("sbDisabled",!n)("sbDelay",f.qc(103,j)),f.Cb(1),f.Sc(" ",f.hc(38,67,"COLUMN.24H_CHANGE"),": "),f.Cb(2),f.mc("pnl",i.change),f.Cb(1),f.Sc("",f.hc(41,69,f.ic(42,71,i.change,"1.1-1")),"%"),f.Cb(4),f.mc("sbDisabled",!n)("sbDelay",f.qc(104,j)),f.Cb(1),f.Sc(" ",f.hc(46,74,"LABEL.MARK_INDEX"),": "),f.Cb(2),f.mc("ngIf",r.isRegulatedIndex(i)),f.Cb(1),f.mc("ngIf",!r.isRegulatedIndex(i)),f.Cb(2),f.mc("sbDisabled",!n)("sbDelay",f.qc(105,j)),f.Cb(1),f.Sc(" ",f.hc(52,76,"LABEL.MID_PRICE"),": "),f.Cb(3),f.Sc(" ",f.ic(55,78,r.getMid(i),i)," "),f.Cb(3),f.mc("sbDisabled",!n)("sbDelay",f.qc(106,j)),f.Cb(1),f.Sc(" ",f.hc(59,81,"LABEL.MARK_PRICE"),": "),f.Cb(3),f.Sc(" ",f.ic(62,83,i.markPrice,i)," "),f.Cb(3),f.mc("sbDisabled",!n)("sbDelay",f.qc(107,j)),f.Cb(1),f.Sc(" ",f.hc(66,86,"LABEL.PREMIUM"),": "),f.Cb(2),f.mc("pnl",i.premium),f.Cb(1),f.Sc("",f.ic(69,88,i.premium,"1.1-1"),"%"),f.Cb(2),f.mc("ngIf","perpetual"===i.tag&&f.hc(71,91,r.position$)),f.Cb(2),f.mc("ngIf",f.hc(73,93,r.userSignedIn$)),f.Cb(2),f.mc("ngIf",f.hc(75,95,r.userSignedIn$)),f.Cb(2),f.mc("ngIf",f.hc(77,97,r.userSignedIn$))}}function X(t,e){if(1&t&&(f.Sb(0),f.Oc(1,Z,78,108,"section",2),f.gc(2,"async"),f.Rb()),2&t){var n=f.fc();f.Cb(1),f.mc("ngLet",f.hc(2,1,n.displayTooltips$))}}function J(t,e){1&t&&f.Pb(0,"kraken-loading")}var tt,et=((tt=function(){function t(e){C(this,t),this.store=e,this.userSignedIn$=this.store.pipe(Object(i.m)(d.m)),this.selectedTicker$=this.store.pipe(Object(i.m)(u.p)),this.position$=this.store.pipe(Object(i.m)(l.g)),this.displayTooltips$=this.store.pipe(Object(i.m)(d.y)),this.userFeeVolume$=this.store.pipe(Object(i.m)(d.x)),this.userFeeTier$=this.store.pipe(Object(i.m)(d.v),Object(o.j)((function(t){return{maker:t[0].makerFee/100,taker:t[0].takerFee/100}})))}return w(t,[{key:"getFundingRates",value:function(t){this.store.dispatch(Object(c.j)({symbol:t}))}},{key:"openAllMarketsDialog",value:function(){this.store.dispatch(Object(s.g)({name:"markets-overview"}))}},{key:"openFeeSchedule",value:function(){this.store.dispatch(Object(s.g)({name:"fee-schedule"}))}},{key:"isRegulatedIndex",value:function(t){return"F"!==t.product_id[1]}},{key:"instrumentGroup",value:function(t){if(!t)return"-";var e=t.product_id;return Object(a.a)(e)?"linear":e.startsWith("FI")||e.startsWith("PI")?"inverse":"vanilla"}},{key:"instrumentSupport",value:function(t){var e=t.product_id;return Object(a.a)(e)?"4844359082772":"360022835911"}},{key:"isPerpetual",value:function(t){return!!t&&"perpetual"===t.tag}},{key:"getSettlementTime",value:function(t){if(t)return Object(r.h)(t,!0)}},{key:"getRTIName",value:function(t){return h(t)}},{key:"getRTILink",value:function(t){return"http://www.cfbenchmarks.com/indices/".concat(h(t),"/")}},{key:"contractMid",value:function(t){return Object(a.j)(t)}},{key:"getMid",value:function(t){return Object(a.j)(t)}}]),t}()).\u0275fac=function(t){return new(t||tt)(f.Ob(i.b))},tt.\u0275cmp=f.Ib({type:tt,selectors:[["market-details"]],decls:4,vars:4,consts:[[4,"ngIf","ngIfElse"],["loading",""],["body","","class","details",4,"ngLet"],["body","",1,"details"],[1,"detail"],["tooltip","","sbTooltip","TOOLTIP.INSTRUMENT_SYMBOL",3,"sbDisabled","sbDelay"],["tooltip","","sbTooltip","TOOLTIP.INSTRUMENT_TYPE",3,"sbDisabled","sbDelay"],["target","_blank",1,"global__text--link",3,"href"],["tooltip","","sbTooltip","TOOLTIP.24H_VOLUME",3,"sbDisabled","sbDelay"],["mono",""],["tooltip","","sbTooltip","TOOLTIP.OPEN_INTEREST",3,"sbDisabled","sbDelay"],["class","detail",4,"ngIf"],["tooltip","","sbTooltip","TOOLTIP.24H_CHANGE",3,"sbDisabled","sbDelay"],[3,"pnl"],["tooltip","","sbTooltip","TOOLTIP.MARK_INDEX",3,"sbDisabled","sbDelay"],["target","_blank","class","global__text--link",3,"href",4,"ngIf"],["mono","",4,"ngIf"],["tooltip","","sbTooltip","TOOLTIP.MID_PRICE",3,"sbDisabled","sbDelay"],["tooltip","","sbTooltip","TOOLTIP.MARK_PRICE",3,"sbDisabled","sbDelay"],[1,"detail","detail--premium"],["tooltip","","sbTooltip","TOOLTIP.PREMIUM",3,"sbDisabled","sbDelay"],["tooltip","","sbTooltip","TOOLTIP.MATURITY_DATE",3,"sbDisabled","sbDelay"],["mono","","target","_blank",1,"global__text--link",3,"href"],["tooltip","","sbTooltip","TOOLTIP.MATURITY_TIME",3,"sbDisabled","sbDelay"],["tooltip","","sbTooltip","TOOLTIP.SETTLEMENT",3,"sbDisabled","sbDelay"],["tooltip","","sbTooltip","TOOLTIP.FUNDING_RATE",3,"sbDisabled","sbDelay"],["mono","",1,"global__text--link",3,"click"],["tooltip","","sbTooltip","TOOLTIP.NEXT_RATE",3,"sbDisabled","sbDelay"],["tooltip","","sbTooltip","TOOLTIP.NEXT_RATE_TIME",3,"sbDisabled","sbDelay"],["src","assets/images/cfb.png","alt","cfb",1,"cfb"],["tooltip","","sbTooltip","TOOLTIP.UNREALIZED_FUNDING",3,"sbDisabled","sbDelay"],["mono","","nobr",""],["ghost",""],["mono","","nobr","",4,"ngIfSome"],["href",""],["mono","","nobr","","class","global__text--link",3,"click",4,"ngIfSome"],["mono","","nobr","",1,"global__text--link",3,"click"]],template:function(t,e){if(1&t&&(f.Oc(0,X,3,3,"ng-container",0),f.gc(1,"async"),f.Oc(2,J,1,0,"ng-template",null,1,f.Pc)),2&t){var n=f.Ac(3);f.mc("ngIf",f.hc(1,2,e.selectedTicker$))("ngIfElse",n)}},directives:[p.n,b.a,g.a,m.a,v.a,y.a,_.a,O.a,k.a,T.a,S.a,E.a,x.a],pipes:[p.b,P.d,A.a,I.a,p.f,M.b,D.c,p.e,p.u,R.a,D.a],styles:["[_nghost-%COMP%]{display:block;padding:var(--spacing);overflow:auto}.details[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(auto-fill,minmax(40ch,1fr));gap:var(--spacing-s) var(--spacing-l)}.detail[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:var(--spacing-s) 0}.detail[_ngcontent-%COMP%]:not(:last-of-type){border-bottom:1px dashed var(--border-colour-dark)}.detail[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{text-transform:capitalize}.cfb[_ngcontent-%COMP%]{width:20px;margin-right:var(--spacing-s)}"],changeDetection:0}),tt)},OHEV:function(t,e,n){var i=n("u9MN"),r=n("Wzsi"),o=n("1aiz"),a=n("TuP6");function s(t,e,n,o,a){var s=[].slice.call(arguments,1),c=s.length,u="function"==typeof s[c-1];if(!u&&!i())throw new Error("Callback required as last argument");if(!u){if(c<1)throw new Error("Too few arguments provided");return 1===c?(n=e,e=o=void 0):2!==c||e.getContext||(o=n,n=e,e=void 0),new Promise((function(i,a){try{var s=r.create(n,o);i(t(s,e,o))}catch(c){a(c)}}))}if(c<2)throw new Error("Too few arguments provided");2===c?(a=n,n=e,e=o=void 0):3===c&&(e.getContext&&void 0===a?(a=o,o=void 0):(a=o,o=n,n=e,e=void 0));try{var l=r.create(n,o);a(null,t(l,e,o))}catch(d){a(d)}}e.create=r.create,e.toCanvas=s.bind(null,o.render),e.toDataURL=s.bind(null,o.renderToDataURL),e.toString=s.bind(null,(function(t,e,n){return a.render(t,n)}))},OX2b:function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0});var o=n("4Pxi"),a=n("ZCEf"),s=n("iiuT"),c=n("aEDl"),u=n("VYrj"),l=n("LqyJ");e.default=function(t){function e(e){var n=t.call(this)||this,i=null==e?null:e.get(a.default.POSSIBLE_FORMATS),r=[];return null!=i&&(i.indexOf(o.default.EAN_13)>-1&&r.push(new c.default),i.indexOf(o.default.EAN_8)>-1&&r.push(new u.default)),0===r.length&&(r.push(new c.default),r.push(new u.default)),n.readers=r,n}return r(e,t),e.prototype.decodeRow=function(t,e,n){for(var i=0,r=this.readers;i=0&&t<=7},e.from=function(t){return e.isValid(t)?parseInt(t,10):void 0},e.getPenaltyN1=function(t){for(var e=t.size,n=0,i=0,r=0,o=null,a=null,s=0;s=5&&(n+=i-5+3),o=u,i=1),(u=t.get(c,s))===a?r++:(r>=5&&(n+=r-5+3),a=u,r=1)}i>=5&&(n+=i-5+3),r>=5&&(n+=r-5+3)}return n},e.getPenaltyN2=function(t){for(var e=t.size,n=0,i=0;i=10&&(1488===i||93===i)&&n++,r=r<<1&2047|t.get(a,o),a>=10&&(1488===r||93===r)&&n++}return 40*n},e.getPenaltyN4=function(t){for(var e=0,n=t.data.length,i=0;i open-instant",Object(E.e)("0ms")),Object(E.m)("void <=> open, open-instant => void",Object(E.e)("400ms cubic-bezier(0.25, 0.8, 0.25, 1)"))])},B=new s.s("MAT_DRAWER_DEFAULT_AUTOSIZE",{providedIn:"root",factory:function(){return!1}}),z=new s.s("MAT_DRAWER_CONTAINER"),V=function(){var t=function(t){a(n,t);var e=c(n);function n(t,i,r,o,a){var s;return C(this,n),(s=e.call(this,r,o,a))._changeDetectorRef=t,s._container=i,s}return w(n,[{key:"ngAfterContentInit",value:function(){var t=this;this._container._contentMarginChanges.subscribe((function(){t._changeDetectorRef.markForCheck()}))}}]),n}(r.b);return t.\u0275fac=function(e){return new(e||t)(s.Ob(s.h),s.Ob(Object(s.V)((function(){return q}))),s.Ob(s.l),s.Ob(r.f),s.Ob(s.B))},t.\u0275cmp=s.Ib({type:t,selectors:[["mat-drawer-content"]],hostAttrs:[1,"mat-drawer-content"],hostVars:4,hostBindings:function(t,e){2&t&&s.Lc("margin-left",e._container._contentMargins.left,"px")("margin-right",e._container._contentMargins.right,"px")},features:[s.zb],ngContentSelectors:P,decls:1,vars:0,template:function(t,e){1&t&&(s.lc(),s.kc(0))},encapsulation:2,changeDetection:0}),t}(),H=function(){var t=function(){function t(e,n,i,r,o,a,c){var u=this;C(this,t),this._elementRef=e,this._focusTrapFactory=n,this._focusMonitor=i,this._platform=r,this._ngZone=o,this._doc=a,this._container=c,this._elementFocusedBeforeDrawerWasOpened=null,this._enableAnimations=!1,this._position="start",this._mode="over",this._disableClose=!1,this._opened=!1,this._animationStarted=new p.b,this._animationEnd=new p.b,this._animationState="void",this.openedChange=new s.o(!0),this._openedStream=this.openedChange.pipe(Object(m.a)((function(t){return t})),Object(v.a)((function(){}))),this.openedStart=this._animationStarted.pipe(Object(m.a)((function(t){return t.fromState!==t.toState&&0===t.toState.indexOf("open")})),Object(y.a)(void 0)),this._closedStream=this.openedChange.pipe(Object(m.a)((function(t){return!t})),Object(v.a)((function(){}))),this.closedStart=this._animationStarted.pipe(Object(m.a)((function(t){return t.fromState!==t.toState&&"void"===t.toState})),Object(y.a)(void 0)),this._destroyed=new p.b,this.onPositionChanged=new s.o,this._modeChanged=new p.b,this.openedChange.subscribe((function(t){t?(u._doc&&(u._elementFocusedBeforeDrawerWasOpened=u._doc.activeElement),u._takeFocus()):u._isFocusWithinDrawer()&&u._restoreFocus()})),this._ngZone.runOutsideAngular((function(){Object(b.a)(u._elementRef.nativeElement,"keydown").pipe(Object(m.a)((function(t){return t.keyCode===f.f&&!u.disableClose&&!Object(f.r)(t)})),Object(_.a)(u._destroyed)).subscribe((function(t){return u._ngZone.run((function(){u.close(),t.stopPropagation(),t.preventDefault()}))}))})),this._animationEnd.pipe(Object(O.a)((function(t,e){return t.fromState===e.fromState&&t.toState===e.toState}))).subscribe((function(t){var e=t.fromState,n=t.toState;(0===n.indexOf("open")&&"void"===e||"void"===n&&0===e.indexOf("open"))&&u.openedChange.emit(u._opened)}))}return w(t,[{key:"_takeFocus",value:function(){var t=this;this.autoFocus&&this._focusTrap&&this._focusTrap.focusInitialElementWhenReady().then((function(e){e||"function"!=typeof t._elementRef.nativeElement.focus||t._elementRef.nativeElement.focus()}))}},{key:"_restoreFocus",value:function(){this.autoFocus&&(this._elementFocusedBeforeDrawerWasOpened?this._focusMonitor.focusVia(this._elementFocusedBeforeDrawerWasOpened,this._openedVia):this._elementRef.nativeElement.blur(),this._elementFocusedBeforeDrawerWasOpened=null,this._openedVia=null)}},{key:"_isFocusWithinDrawer",value:function(){var t,e=null===(t=this._doc)||void 0===t?void 0:t.activeElement;return!!e&&this._elementRef.nativeElement.contains(e)}},{key:"ngAfterContentInit",value:function(){this._focusTrap=this._focusTrapFactory.create(this._elementRef.nativeElement),this._updateFocusTrapState()}},{key:"ngAfterContentChecked",value:function(){this._platform.isBrowser&&(this._enableAnimations=!0)}},{key:"ngOnDestroy",value:function(){this._focusTrap&&this._focusTrap.destroy(),this._animationStarted.complete(),this._animationEnd.complete(),this._modeChanged.complete(),this._destroyed.next(),this._destroyed.complete()}},{key:"open",value:function(t){return this.toggle(!0,t)}},{key:"close",value:function(){return this.toggle(!1)}},{key:"_closeViaBackdropClick",value:function(){return this._setOpen(!1,!0)}},{key:"toggle",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:!this.opened,e=arguments.length>1?arguments[1]:void 0;return this._setOpen(t,!t&&this._isFocusWithinDrawer(),e)}},{key:"_setOpen",value:function(t,e){var n=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"program";return this._opened=t,t?(this._animationState=this._enableAnimations?"open":"open-instant",this._openedVia=i):(this._animationState="void",e&&this._restoreFocus()),this._updateFocusTrapState(),new Promise((function(t){n.openedChange.pipe(Object(k.a)(1)).subscribe((function(e){return t(e?"open":"close")}))}))}},{key:"_getWidth",value:function(){return this._elementRef.nativeElement&&this._elementRef.nativeElement.offsetWidth||0}},{key:"_updateFocusTrapState",value:function(){this._focusTrap&&(this._focusTrap.enabled=this.opened&&"side"!==this.mode)}},{key:"_animationStartListener",value:function(t){this._animationStarted.next(t)}},{key:"_animationDoneListener",value:function(t){this._animationEnd.next(t)}},{key:"position",get:function(){return this._position},set:function(t){(t="end"===t?"end":"start")!=this._position&&(this._position=t,this.onPositionChanged.emit())}},{key:"mode",get:function(){return this._mode},set:function(t){this._mode=t,this._updateFocusTrapState(),this._modeChanged.next()}},{key:"disableClose",get:function(){return this._disableClose},set:function(t){this._disableClose=Object(h.c)(t)}},{key:"autoFocus",get:function(){var t=this._autoFocus;return null==t?"side"!==this.mode:t},set:function(t){this._autoFocus=Object(h.c)(t)}},{key:"opened",get:function(){return this._opened},set:function(t){this.toggle(Object(h.c)(t))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(s.Ob(s.l),s.Ob(l.i),s.Ob(l.h),s.Ob(i.a),s.Ob(s.B),s.Ob(o.d,8),s.Ob(z,8))},t.\u0275cmp=s.Ib({type:t,selectors:[["mat-drawer"]],hostAttrs:["tabIndex","-1",1,"mat-drawer"],hostVars:12,hostBindings:function(t,e){1&t&&s.Mc("@transform.start",(function(t){return e._animationStartListener(t)}))("@transform.done",(function(t){return e._animationDoneListener(t)})),2&t&&(s.Db("align",null),s.Nc("@transform",e._animationState),s.Gb("mat-drawer-end","end"===e.position)("mat-drawer-over","over"===e.mode)("mat-drawer-push","push"===e.mode)("mat-drawer-side","side"===e.mode)("mat-drawer-opened",e.opened))},inputs:{position:"position",mode:"mode",disableClose:"disableClose",autoFocus:"autoFocus",opened:"opened"},outputs:{openedChange:"openedChange",_openedStream:"opened",openedStart:"openedStart",_closedStream:"closed",closedStart:"closedStart",onPositionChanged:"positionChanged"},exportAs:["matDrawer"],ngContentSelectors:P,decls:2,vars:0,consts:[[1,"mat-drawer-inner-container"]],template:function(t,e){1&t&&(s.lc(),s.Ub(0,"div",0),s.kc(1),s.Tb())},encapsulation:2,data:{animation:[F.transformDrawer]},changeDetection:0}),t}(),q=function(){var t=function(){function t(e,n,i,r,o){var a=this,c=arguments.length>5&&void 0!==arguments[5]&&arguments[5],u=arguments.length>6?arguments[6]:void 0;C(this,t),this._dir=e,this._element=n,this._ngZone=i,this._changeDetectorRef=r,this._animationMode=u,this._drawers=new s.F,this.backdropClick=new s.o,this._destroyed=new p.b,this._doCheckSubject=new p.b,this._contentMargins={left:null,right:null},this._contentMarginChanges=new p.b,e&&e.change.pipe(Object(_.a)(this._destroyed)).subscribe((function(){a._validateDrawers(),a.updateContentMargins()})),o.change().pipe(Object(_.a)(this._destroyed)).subscribe((function(){return a.updateContentMargins()})),this._autosize=c}return w(t,[{key:"ngAfterContentInit",value:function(){var t=this;this._allDrawers.changes.pipe(Object(T.a)(this._allDrawers),Object(_.a)(this._destroyed)).subscribe((function(e){t._drawers.reset(e.filter((function(e){return!e._container||e._container===t}))),t._drawers.notifyOnChanges()})),this._drawers.changes.pipe(Object(T.a)(null)).subscribe((function(){t._validateDrawers(),t._drawers.forEach((function(e){t._watchDrawerToggle(e),t._watchDrawerPosition(e),t._watchDrawerMode(e)})),(!t._drawers.length||t._isDrawerOpen(t._start)||t._isDrawerOpen(t._end))&&t.updateContentMargins(),t._changeDetectorRef.markForCheck()})),this._ngZone.runOutsideAngular((function(){t._doCheckSubject.pipe(Object(S.a)(10),Object(_.a)(t._destroyed)).subscribe((function(){return t.updateContentMargins()}))}))}},{key:"ngOnDestroy",value:function(){this._contentMarginChanges.complete(),this._doCheckSubject.complete(),this._drawers.destroy(),this._destroyed.next(),this._destroyed.complete()}},{key:"open",value:function(){this._drawers.forEach((function(t){return t.open()}))}},{key:"close",value:function(){this._drawers.forEach((function(t){return t.close()}))}},{key:"updateContentMargins",value:function(){var t=this,e=0,n=0;if(this._left&&this._left.opened)if("side"==this._left.mode)e+=this._left._getWidth();else if("push"==this._left.mode){var i=this._left._getWidth();e+=i,n-=i}if(this._right&&this._right.opened)if("side"==this._right.mode)n+=this._right._getWidth();else if("push"==this._right.mode){var r=this._right._getWidth();n+=r,e-=r}n=n||null,(e=e||null)===this._contentMargins.left&&n===this._contentMargins.right||(this._contentMargins={left:e,right:n},this._ngZone.run((function(){return t._contentMarginChanges.next(t._contentMargins)})))}},{key:"ngDoCheck",value:function(){var t=this;this._autosize&&this._isPushed()&&this._ngZone.runOutsideAngular((function(){return t._doCheckSubject.next()}))}},{key:"_watchDrawerToggle",value:function(t){var e=this;t._animationStarted.pipe(Object(m.a)((function(t){return t.fromState!==t.toState})),Object(_.a)(this._drawers.changes)).subscribe((function(t){"open-instant"!==t.toState&&"NoopAnimations"!==e._animationMode&&e._element.nativeElement.classList.add("mat-drawer-transition"),e.updateContentMargins(),e._changeDetectorRef.markForCheck()})),"side"!==t.mode&&t.openedChange.pipe(Object(_.a)(this._drawers.changes)).subscribe((function(){return e._setContainerClass(t.opened)}))}},{key:"_watchDrawerPosition",value:function(t){var e=this;t&&t.onPositionChanged.pipe(Object(_.a)(this._drawers.changes)).subscribe((function(){e._ngZone.onMicrotaskEmpty.pipe(Object(k.a)(1)).subscribe((function(){e._validateDrawers()}))}))}},{key:"_watchDrawerMode",value:function(t){var e=this;t&&t._modeChanged.pipe(Object(_.a)(Object(g.a)(this._drawers.changes,this._destroyed))).subscribe((function(){e.updateContentMargins(),e._changeDetectorRef.markForCheck()}))}},{key:"_setContainerClass",value:function(t){var e=this._element.nativeElement.classList,n="mat-drawer-container-has-open";t?e.add(n):e.remove(n)}},{key:"_validateDrawers",value:function(){var t=this;this._start=this._end=null,this._drawers.forEach((function(e){"end"==e.position?t._end=e:t._start=e})),this._right=this._left=null,this._dir&&"rtl"===this._dir.value?(this._left=this._end,this._right=this._start):(this._left=this._start,this._right=this._end)}},{key:"_isPushed",value:function(){return this._isDrawerOpen(this._start)&&"over"!=this._start.mode||this._isDrawerOpen(this._end)&&"over"!=this._end.mode}},{key:"_onBackdropClicked",value:function(){this.backdropClick.emit(),this._closeModalDrawersViaBackdrop()}},{key:"_closeModalDrawersViaBackdrop",value:function(){var t=this;[this._start,this._end].filter((function(e){return e&&!e.disableClose&&t._canHaveBackdrop(e)})).forEach((function(t){return t._closeViaBackdropClick()}))}},{key:"_isShowingBackdrop",value:function(){return this._isDrawerOpen(this._start)&&this._canHaveBackdrop(this._start)||this._isDrawerOpen(this._end)&&this._canHaveBackdrop(this._end)}},{key:"_canHaveBackdrop",value:function(t){return"side"!==t.mode||!!this._backdropOverride}},{key:"_isDrawerOpen",value:function(t){return null!=t&&t.opened}},{key:"start",get:function(){return this._start}},{key:"end",get:function(){return this._end}},{key:"autosize",get:function(){return this._autosize},set:function(t){this._autosize=Object(h.c)(t)}},{key:"hasBackdrop",get:function(){return null==this._backdropOverride?!this._start||"side"!==this._start.mode||!this._end||"side"!==this._end.mode:this._backdropOverride},set:function(t){this._backdropOverride=null==t?null:Object(h.c)(t)}},{key:"scrollable",get:function(){return this._userContent||this._content}}]),t}();return t.\u0275fac=function(e){return new(e||t)(s.Ob(d.b,8),s.Ob(s.l),s.Ob(s.B),s.Ob(s.h),s.Ob(r.h),s.Ob(B),s.Ob(x.a,8))},t.\u0275cmp=s.Ib({type:t,selectors:[["mat-drawer-container"]],contentQueries:function(t,e,n){var i;1&t&&(s.Hb(n,V,!0),s.Hb(n,H,!0)),2&t&&(s.zc(i=s.cc())&&(e._content=i.first),s.zc(i=s.cc())&&(e._allDrawers=i))},viewQuery:function(t,e){var n;1&t&&s.Wc(V,!0),2&t&&s.zc(n=s.cc())&&(e._userContent=n.first)},hostAttrs:[1,"mat-drawer-container"],hostVars:2,hostBindings:function(t,e){2&t&&s.Gb("mat-drawer-container-explicit-backdrop",e._backdropOverride)},inputs:{autosize:"autosize",hasBackdrop:"hasBackdrop"},outputs:{backdropClick:"backdropClick"},exportAs:["matDrawerContainer"],features:[s.Bb([{provide:z,useExisting:t}])],ngContentSelectors:D,decls:4,vars:2,consts:[["class","mat-drawer-backdrop",3,"mat-drawer-shown","click",4,"ngIf"],[4,"ngIf"],[1,"mat-drawer-backdrop",3,"click"]],template:function(t,e){1&t&&(s.lc(M),s.Oc(0,A,1,2,"div",0),s.kc(1),s.kc(2,1),s.Oc(3,I,2,0,"mat-drawer-content",1)),2&t&&(s.mc("ngIf",e.hasBackdrop),s.Cb(3),s.mc("ngIf",!e._content))},directives:[o.n,V],styles:[U],encapsulation:2,changeDetection:0}),t}(),$=function(){var t=function(t){a(n,t);var e=c(n);function n(t,i,r,o,a){return C(this,n),e.call(this,t,i,r,o,a)}return n}(V);return t.\u0275fac=function(e){return new(e||t)(s.Ob(s.h),s.Ob(Object(s.V)((function(){return G}))),s.Ob(s.l),s.Ob(r.f),s.Ob(s.B))},t.\u0275cmp=s.Ib({type:t,selectors:[["mat-sidenav-content"]],hostAttrs:[1,"mat-drawer-content","mat-sidenav-content"],hostVars:4,hostBindings:function(t,e){2&t&&s.Lc("margin-left",e._container._contentMargins.left,"px")("margin-right",e._container._contentMargins.right,"px")},features:[s.zb],ngContentSelectors:P,decls:1,vars:0,template:function(t,e){1&t&&(s.lc(),s.kc(0))},encapsulation:2,changeDetection:0}),t}(),Q=function(){var t=function(t){a(n,t);var e=c(n);function n(){var t;return C(this,n),(t=e.apply(this,arguments))._fixedInViewport=!1,t._fixedTopGap=0,t._fixedBottomGap=0,t}return w(n,[{key:"fixedInViewport",get:function(){return this._fixedInViewport},set:function(t){this._fixedInViewport=Object(h.c)(t)}},{key:"fixedTopGap",get:function(){return this._fixedTopGap},set:function(t){this._fixedTopGap=Object(h.f)(t)}},{key:"fixedBottomGap",get:function(){return this._fixedBottomGap},set:function(t){this._fixedBottomGap=Object(h.f)(t)}}]),n}(H);return t.\u0275fac=function(e){return W(e||t)},t.\u0275cmp=s.Ib({type:t,selectors:[["mat-sidenav"]],hostAttrs:["tabIndex","-1",1,"mat-drawer","mat-sidenav"],hostVars:17,hostBindings:function(t,e){2&t&&(s.Db("align",null),s.Lc("top",e.fixedInViewport?e.fixedTopGap:null,"px")("bottom",e.fixedInViewport?e.fixedBottomGap:null,"px"),s.Gb("mat-drawer-end","end"===e.position)("mat-drawer-over","over"===e.mode)("mat-drawer-push","push"===e.mode)("mat-drawer-side","side"===e.mode)("mat-drawer-opened",e.opened)("mat-sidenav-fixed",e.fixedInViewport))},inputs:{fixedInViewport:"fixedInViewport",fixedTopGap:"fixedTopGap",fixedBottomGap:"fixedBottomGap"},exportAs:["matSidenav"],features:[s.zb],ngContentSelectors:P,decls:2,vars:0,consts:[[1,"mat-drawer-inner-container"]],template:function(t,e){1&t&&(s.lc(),s.Ub(0,"div",0),s.kc(1),s.Tb())},encapsulation:2,data:{animation:[F.transformDrawer]},changeDetection:0}),t}(),W=s.Wb(Q),G=function(){var t=function(t){a(n,t);var e=c(n);function n(){return C(this,n),e.apply(this,arguments)}return n}(q);return t.\u0275fac=function(e){return Y(e||t)},t.\u0275cmp=s.Ib({type:t,selectors:[["mat-sidenav-container"]],contentQueries:function(t,e,n){var i;1&t&&(s.Hb(n,$,!0),s.Hb(n,Q,!0)),2&t&&(s.zc(i=s.cc())&&(e._content=i.first),s.zc(i=s.cc())&&(e._allDrawers=i))},hostAttrs:[1,"mat-drawer-container","mat-sidenav-container"],hostVars:2,hostBindings:function(t,e){2&t&&s.Gb("mat-drawer-container-explicit-backdrop",e._backdropOverride)},exportAs:["matSidenavContainer"],features:[s.Bb([{provide:z,useExisting:t}]),s.zb],ngContentSelectors:N,decls:4,vars:2,consts:[["class","mat-drawer-backdrop",3,"mat-drawer-shown","click",4,"ngIf"],["cdkScrollable","",4,"ngIf"],[1,"mat-drawer-backdrop",3,"click"],["cdkScrollable",""]],template:function(t,e){1&t&&(s.lc(L),s.Oc(0,R,1,2,"div",0),s.kc(1),s.kc(2,1),s.Oc(3,j,2,0,"mat-sidenav-content",1)),2&t&&(s.mc("ngIf",e.hasBackdrop),s.Cb(3),s.mc("ngIf",!e._content))},directives:[o.n,$,r.b],styles:[U],encapsulation:2,changeDetection:0}),t}(),Y=s.Wb(G),K=function(){var t=function t(){C(this,t)};return t.\u0275mod=s.Mb({type:t}),t.\u0275inj=s.Lb({factory:function(e){return new(e||t)},imports:[[o.c,u.j,i.b,r.c],r.c,u.j]}),t}()},P4Xx:function(t,e,n){"use strict";n.d(e,"a",(function(){return c}));var i=n("IdLP"),r=n("FU6l"),o=n("YtkY"),a=n("X0qr"),s=n("GoAz");function c(){for(var t=arguments.length,e=new Array(t),n=0;n3&&239===e[0]&&187===e[1]&&191===e[2],_=0;_0?0==(128&O)?s=!1:c--:0!=(128&O)&&(0==(64&O)?s=!1:(c++,0==(32&O)?u++:(c++,0==(16&O)?l++:(c++,0==(8&O)?d++:s=!1))))),o&&(O>127&&O<160?o=!1:O>159&&(O<192||215===O||247===O)&&v++),a&&(h>0?O<64||127===O||O>252?a=!1:h--:128===O||160===O||O>239?a=!1:O>160&&O<224?(f++,b=0,++p>g&&(g=p)):O>127?(h++,p=0,++b>m&&(m=b)):(p=0,b=0))}return s&&c>0&&(s=!1),a&&h>0&&(a=!1),s&&(y||u+l+d>0)?t.UTF8:a&&(t.ASSUME_SHIFT_JIS||g>=3||m>=3)?t.SHIFT_JIS:o&&a?2===g&&2===f||10*v>=r?t.SHIFT_JIS:t.ISO88591:o?t.ISO88591:a?t.SHIFT_JIS:s?t.UTF8:t.PLATFORM_DEFAULT_ENCODING},t.SHIFT_JIS=r.default.SJIS.getName(),t.GB2312="GB2312",t.ISO88591=r.default.ISO8859_1.getName(),t.EUC_JP="EUC_JP",t.UTF8=r.default.UTF8.getName(),t.PLATFORM_DEFAULT_ENCODING=t.UTF8,t.ASSUME_SHIFT_JIS=!1,t}()},PNff:function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var i=function(){function t(){return Error.call(this),this.message="argument out of range",this.name="ArgumentOutOfRangeError",this}return t.prototype=Object.create(Error.prototype),t}()},PSEG:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("Qkwj"),r=n("qArU"),o=n("e9V9"),a=n("dyLe"),s=n("va0y"),c=n("LqyJ");e.default=function(){function t(t){this.image=t,this.rectangleDetector=new s.default(t)}return t.prototype.detect=function(){var e=this.rectangleDetector.detect(),n=e[0],o=e[1],a=e[2],s=e[3],l=[];l.push(this.transitionsBetween(n,o)),l.push(this.transitionsBetween(n,a)),l.push(this.transitionsBetween(o,s)),l.push(this.transitionsBetween(a,s)),l.sort(u.resultPointsAndTransitionsComparator);var d=l[0],h=l[1],f=new Map;t.increment(f,d.getFrom()),t.increment(f,d.getTo()),t.increment(f,h.getFrom()),t.increment(f,h.getTo());for(var p=null,b=null,g=null,m=0,v=Array.from(f.entries());m=7*(x+=2)||4*x>=7*E)null==(S=this.correctTopRightRectangular(b,k,C,w,E,x))&&(S=w),1==(1&(E=this.transitionsBetween(C,S).getTransitions()))&&E++,1==(1&(x=this.transitionsBetween(k,S).getTransitions()))&&x++,T=t.sampleGrid(this.image,C,b,k,S,E,x);else{var P=Math.min(x,E);null==(S=this.correctTopRight(b,k,C,w,P))&&(S=w);var A=Math.max(this.transitionsBetween(C,S).getTransitions(),this.transitionsBetween(k,S).getTransitions());1==(1&++A)&&A++,T=t.sampleGrid(this.image,C,b,k,S,A,A)}return new r.default(T,[C,b,k,S])},t.prototype.correctTopRightRectangular=function(e,n,r,o,a,s){var c=t.distance(e,n)/a,u=t.distance(r,o),l=(o.getX()-r.getX())/u,d=(o.getY()-r.getY())/u,h=new i.default(o.getX()+c*l,o.getY()+c*d);c=t.distance(e,r)/s,u=t.distance(n,o),l=(o.getX()-n.getX())/u,d=(o.getY()-n.getY())/u;var f=new i.default(o.getX()+c*l,o.getY()+c*d);return this.isValid(h)?this.isValid(f)?Math.abs(a-this.transitionsBetween(r,h).getTransitions())+Math.abs(s-this.transitionsBetween(n,h).getTransitions())<=Math.abs(a-this.transitionsBetween(r,f).getTransitions())+Math.abs(s-this.transitionsBetween(n,f).getTransitions())?h:f:h:this.isValid(f)?f:null},t.prototype.correctTopRight=function(e,n,r,o,a){var s=t.distance(e,n)/a,c=t.distance(r,o),u=(o.getX()-r.getX())/c,l=(o.getY()-r.getY())/c,d=new i.default(o.getX()+s*u,o.getY()+s*l);s=t.distance(e,r)/a,c=t.distance(n,o),u=(o.getX()-n.getX())/c,l=(o.getY()-n.getY())/c;var h=new i.default(o.getX()+s*u,o.getY()+s*l);return this.isValid(d)?this.isValid(h)?Math.abs(this.transitionsBetween(r,d).getTransitions()-this.transitionsBetween(n,d).getTransitions())<=Math.abs(this.transitionsBetween(r,h).getTransitions()-this.transitionsBetween(n,h).getTransitions())?d:h:d:this.isValid(h)?h:null},t.prototype.isValid=function(t){return t.getX()>=0&&t.getX()0&&t.getY()Math.abs(r-n);if(a){var s=n;n=i,i=s,s=r,r=o,o=s}for(var c=Math.abs(r-n),l=Math.abs(o-i),d=-c/2,h=i0){if(m===o)break;m+=h,d-=c}}return new u(t,e,p)},t}();var u=function(){function t(t,e,n){this.from=t,this.to=e,this.transitions=n}return t.prototype.getFrom=function(){return this.from},t.prototype.getTo=function(){return this.to},t.prototype.getTransitions=function(){return this.transitions},t.prototype.toString=function(){return this.from+"/"+this.to+"/"+this.transitions},t.resultPointsAndTransitionsComparator=function(t,e){return t.getTransitions()-e.getTransitions()},t}()},PdLq:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("n5WT"),r=n("ooS/"),o=n("686E");e.default=function(){function t(){}return t.decodeRow=function(t,e,n){var a=i.default.findGuardPattern(e,n,!1,this.EXTENSION_START_PATTERN,new Array(this.EXTENSION_START_PATTERN.length).fill(0));try{return(new r.default).decodeRow(t,e,a)}catch(s){return(new o.default).decodeRow(t,e,a)}},t.EXTENSION_START_PATTERN=[1,1,2],t}()},PqQh:function(t,e,n){var i=n("yBEi").getSymbolSize;e.getRowColCoords=function(t){if(1===t)return[];for(var e=Math.floor(t/7)+2,n=i(t),r=145===n?26:2*Math.ceil((n-13)/(2*e-2)),o=[n-7],a=1;a0),o.Cb(1),o.mc("ngTemplateOutlet",r)("ngTemplateOutletContext",o.rc(3,b,n))}}function v(t,e){if(1&t&&(o.Ub(0,"div",7),o.Ub(1,"div"),o.Qc(2),o.gc(3,"translate"),o.Tb(),o.Ub(4,"div",8),o.Oc(5,g,3,5,"ng-container",9),o.Tb(),o.Tb()),2&t){var n=e.$implicit;o.Cb(2),o.Rc(o.hc(3,2,n[0])),o.Cb(3),o.mc("ngForOf",n[1])}}function y(t,e){if(1&t&&(o.Ub(0,"section",4),o.Ub(1,"h2",5),o.Qc(2),o.gc(3,"translate"),o.Tb(),o.Oc(4,v,6,4,"div",6),o.Tb()),2&t){var n=e.$implicit;o.Cb(2),o.Rc(o.hc(3,2,n[0])),o.Cb(2),o.mc("ngForOf",n[1].entrySeq())}}function _(t,e){if(1&t&&(o.Ub(0,"span"),o.Qc(1),o.Tb()),2&t){var n=o.fc(2).$implicit;o.Cb(1),o.Rc("then"===n.type?" ":"+")}}function O(t,e){if(1&t&&(o.Sb(0),o.Oc(1,_,2,1,"span",14),o.Ub(2,"span",15),o.Qc(3),o.Tb(),o.Rb()),2&t){var n=e.$implicit,i=e.index;o.Cb(1),o.mc("ngIf",i>0),o.Cb(2),o.Rc(n)}}function k(t,e){if(1&t&&(o.Ub(0,"div",13),o.Oc(1,O,4,2,"ng-container",9),o.Tb()),2&t){var n=e.$implicit;o.Cb(1),o.mc("ngForOf",n.keys)}}var T=function(){var t=function(){function t(){C(this,t),this.rawKeybinds={global:{"DIALOG.SHORTCUTS.SHORTCUT_DIALOG":["?","shift+/"],"DIALOG.SHORTCUTS.GO_TO_FUTURES_TRADING":["g f"],"DIALOG.SHORTCUTS.GO_TO_WALLETS":["g w"],"DIALOG.SHORTCUTS.GO_TO_HISTORY":["g l"],"DIALOG.SHORTCUTS.GO_TO_ASSIGNMENT":["g a"],"DIALOG.SHORTCUTS.GO_TO_SUPPORT":["g h"],"DIALOG.SHORTCUTS.GO_TO_SETTINGS":["g s"],"DIALOG.SHORTCUTS.ALT":["alt/option"]},trading:{"DIALOG.SHORTCUTS.MARKET_PICKER":["m"],"DIALOG.SHORTCUTS.SWITCH_LAYOUT":["1...6"]},orderbook:{"TOOLTIP.INCREASE_ORDER_GROUPING":["\ufe62","="],"TOOLTIP.DECREASE_ORDER_GROUPING":["\uff0d","_"]},order_form:{"DIALOG.SHORTCUTS.START_LIMIT_ORDER":["shift+l"],"DIALOG.SHORTCUTS.START_MARKET_ORDER":["shift+m"],"DIALOG.SHORTCUTS.TOGGLE_MAKER_ONLY":["shift+a"],"DIALOG.SHORTCUTS.TOGGLE_REDUCE_ONLY":["shift+r"]}}}return w(t,[{key:"keybinds",get:function(){return Object(i.c)(this.rawKeybinds).mapEntries((function(t){var e=m(t,2),n=e[0],o=e[1],a=Object(i.c)(o).map(S);return[Object(r.Q)("HEADING."+n),a]}))}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=o.Ib({type:t,selectors:[["shortcuts-cheatsheet"]],decls:5,vars:1,consts:[["heading","HEADING.KEYBOARD_SHORTCUTS"],[1,"nutrition","keybinds"],["class","combo-concern",4,"ngFor","ngForOf"],["comboTmpl",""],[1,"combo-concern"],["ghost","","uppercase",""],["class","nutrition__detail grid-0-1 gap-m",4,"ngFor","ngForOf"],[1,"nutrition__detail","grid-0-1","gap-m"],[1,"comboset"],[4,"ngFor","ngForOf"],["translate","",4,"ngIf"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],["translate",""],[1,"combo"],[4,"ngIf"],["mono","",1,"key"]],template:function(t,e){1&t&&(o.Ub(0,"pro-dialog",0),o.Ub(1,"div",1),o.Oc(2,y,5,4,"section",2),o.Tb(),o.Tb(),o.Oc(3,k,2,1,"ng-template",null,3,o.Pc)),2&t&&(o.Cb(2),o.mc("ngForOf",e.keybinds.entrySeq()))},directives:[a.a,s.a,c.m,u.a,l.a,c.n,c.s,d.a,h.a],pipes:[d.d],styles:[".scroll-wrapper[_ngcontent-%COMP%]{overflow-y:auto;max-height:100%}.keybinds[_ngcontent-%COMP%]{-moz-columns:2 50ch;columns:50ch 2;-moz-column-gap:var(--spacing-xl);column-gap:var(--spacing-xl);-moz-column-rule:1px dashed var(--ghost-colour);column-rule:1px dashed var(--ghost-colour);color:var(--text-colour);font-family:var(--typeface);font-size:.95rem}.keybinds[_ngcontent-%COMP%] section[_ngcontent-%COMP%]:not(:last-of-type){margin-bottom:var(--spacing-l)}.keybinds[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{font-size:1.15rem}.combo-concern[_ngcontent-%COMP%]{-moz-column-break-inside:avoid;break-inside:avoid}.comboset[_ngcontent-%COMP%]{display:inline-block;margin-left:var(--spacing-l)}.combo[_ngcontent-%COMP%]{white-space:nowrap}.combo[_ngcontent-%COMP%], .key[_ngcontent-%COMP%]{display:inline-block;margin:0 var(--spacing-s)}.key[_ngcontent-%COMP%]{padding:var(--spacing-s) var(--spacing);background-color:var(--tooltip-bg);border:solid var(--n400);border-width:1px 1px 3px;border-radius:var(--bdrs)}"],changeDetection:0}),t}();function S(t){return t.map(r.M).map(E)}function E(t){return t.includes(" ")?{type:"then",keys:t.split(" ")}:{type:"and",keys:t.split("+")}}},Q7YU:function(t,e,n){"use strict";n.d(e,"b",(function(){return i})),n.d(e,"a",(function(){return r}));var i={allowed:["Afghanistan","Aland Islands","Albania","Algeria","American Samoa","Andorra","Angola","Anguilla","Antarctica","Antigua and Barbuda","Argentina","Armenia","Aruba","Australia","Austria","Azerbaijan","Bahamas","Bahrain","Bangladesh","Barbados","Belarus","Belgium","Belize","Benin","Bermuda","Bhutan","Bolivia","Bonaire","Bosnia and Herzegovina","Botswana","Bouvet Island","Brazil","British Indian Ocean Territory","British Virgin Islands","Brunei Darussalam","Bulgaria","Burkina Faso","Burundi","Cambodia","Cameroon","Canada","Cape Verde","Cayman Islands","Central African Republic","Chad","Chile","China","Christmas Island","Cocos (Keeling) Islands","Colombia","Comoros","Congo","Cook Islands","Costa Rica","Croatia","Cuba","Curacao","Cyprus","Czech Republic","Denmark","Djibouti","Dominica","Dominican Republic","Ecuador","Egypt","El Salvador","Equatorial Guinea","Eritrea","Estonia","Ethiopia","Falkland Islands (Malvinas)","Faroe Islands","Fiji","Finland","France","French Guiana","French Polynesia","French Southern Territories","Gabon","Gambia","Georgia","Germany","Ghana","Gibraltar","Greece","Greenland","Grenada","Guadeloupe","Guam","Guatemala","Guernsey","Guinea","Guinea-Bissau","Guyana","Haiti","Heard Island and McDonald Islands","Vatican City State","Honduras","Hong Kong","Hungary","Iceland","India","Indonesia","Iran","Iraq","Ireland","Isle of Man","Israel","Italy","Ivory Coast","Jamaica","Jersey","Jordan","Kazakhstan","Kenya","Kiribati","Kuwait","Kyrgyzstan","Lao","Latvia","Lebanon","Lesotho","Liberia","Libya","Liechtenstein","Lithuania","Luxembourg","Macao","Macedonia","Madagascar","Malawi","Malaysia","Maldives","Mali","Malta","Marshall Islands","Martinique","Mauritania","Mauritius","Mayotte","Mexico","Micronesia","Moldova","Monaco","Mongolia","Montenegro","Montserrat","Morocco","Mozambique","Myanmar","Namibia","Nauru","Nepal","Netherlands","New Caledonia","New Zealand","Nicaragua","Niger","Nigeria","Niue","Norfolk Island","North Korea","Northern Mariana Islands","Norway","Oman","Pakistan","Palau","Panama","Papua New Guinea","Paraguay","Peru","Philippines","Pitcairn","Poland","Portugal","Puerto Rico","Qatar","Reunion","Romania","Russia","Rwanda","Saint Barthelemy","Saint Helena","Saint Kitts and Nevis","Saint Lucia","Saint Martin","Saint Pierre and Miquelon","Saint Vincent and the Grenadines","Samoa","San Marino","Sao Tome and Principe","Saudi Arabia","Senegal","Serbia","Seychelles","Sierra Leone","Singapore","Sint Maarten","Slovakia","Slovenia","Solomon Islands","Somalia","South Africa","South Georgia","South Korea","South Sudan","Spain","Sri Lanka","Sudan","Suriname","Svalbard and Jan Mayen","Swaziland","Sweden","Switzerland","Syria","Taiwan","Tajikistan","Tanzania","Thailand","Timor-Leste","Togo","Tokelau","Tonga","Trinidad and Tobago","Tunisia","Turkey","Turkmenistan","Turks and Caicos Islands","Tuvalu","Uganda","Ukraine","United Arab Emirates","United Kingdom","United States","United States Virgin Islands","Uruguay","Uzbekistan","Vanuatu","Venezuela","Vietnam","Wallis and Futuna","Western Sahara","Yemen","Zambia","Zimbabwe"],disallowed:["Algeria","Bangladesh","Bolivia","Cambodia","Ecuador","Iran","Japan","Lebanon","Nepal","North Korea","Vietnam","Syria","United States"]},r=[].concat(b(i.allowed),b(i.disallowed))},QHMR:function(t,e,n){"use strict";n.d(e,"a",(function(){return v}));var i=n("kZht"),r=n("yPvj"),o=n("anSm"),a=n("1o0v"),s=n("An66"),c=n("chaP"),u=n("+e22"),l=n("rqGg"),d=n("aDqW"),h=n("rUBT"),f=n("DpwM"),p=n("09eR");function b(t,e){if(1&t&&(i.Sb(0),i.Qc(1),i.gc(2,"pair"),i.Pb(3,"market-icon",1),i.gc(4,"quote"),i.Rb()),2&t){var n=i.fc();i.Cb(1),i.Sc(" ",i.hc(2,2,n.primaryTicker)," "),i.Cb(2),i.mc("base",i.hc(4,4,n.primaryTicker.product_id))}}function g(t,e){if(1&t&&(i.Sb(0),i.Qc(1),i.gc(2,"sato"),i.gc(3,"mid"),i.Pb(4,"change",7),i.Rb()),2&t){var n=i.fc();i.Cb(1),i.Sc(" ",i.ic(2,2,i.hc(3,5,n.primaryTicker),n.primaryTicker)," "),i.Cb(3),i.mc("value",n.primaryTicker.change)}}var m=function(t){return{num:t}},v=function(){var t=function t(){C(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=i.Ib({type:t,selectors:[["market-picker-asset"]],inputs:{asset:"asset",primaryTicker:"primaryTicker",tickers:"tickers",count:"count"},decls:13,vars:14,consts:[[1,"icon"],[3,"base"],["body","",1,"asset"],["body","","ghost","",1,"count"],["body","",1,"price"],[4,"ngIf"],["body","","mono","",1,"change"],[3,"value"]],template:function(t,e){1&t&&(i.Ub(0,"div",0),i.Pb(1,"market-icon",1),i.gc(2,"asset"),i.Tb(),i.Ub(3,"div",2),i.Qc(4),i.gc(5,"asset"),i.Tb(),i.Ub(6,"div",3),i.Qc(7),i.gc(8,"translate"),i.Tb(),i.Ub(9,"div",4),i.Oc(10,b,5,6,"ng-container",5),i.Tb(),i.Ub(11,"div",6),i.Oc(12,g,5,7,"ng-container",5),i.Tb()),2&t&&(i.Cb(1),i.mc("base",i.hc(2,5,e.asset)),i.Cb(3),i.Rc(i.hc(5,7,e.asset)),i.Cb(3),i.Sc(" ",i.ic(8,9,"LABEL.N_MARKETS",i.rc(12,m,e.count)),"\n"),i.Cb(3),i.mc("ngIf",e.primaryTicker),i.Cb(2),i.mc("ngIf",e.primaryTicker))},directives:[r.a,o.a,a.a,s.n,c.a,u.a],pipes:[l.a,d.d,h.e,h.f,f.c,p.a],styles:['[_nghost-%COMP%]{display:block;padding:var(--spacing-s) var(--spacing);height:48px;display:grid;grid-template:"icon pair price" auto "icon count change" auto/min-content 1fr min-content;gap:var(--spacing-s) var(--spacing-ml);align-items:center;border-radius:var(--bdrs)}.icon[_ngcontent-%COMP%]{grid-area:icon;font-size:20px}.icon[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{cursor:pointer}.asset[_ngcontent-%COMP%]{grid-area:pair;align-self:end;font-size:14px;color:var(--pair-color,var(--text-colour))}.count[_ngcontent-%COMP%]{grid-area:count;align-self:start}.change[_ngcontent-%COMP%], .price[_ngcontent-%COMP%]{text-align:right}.price[_ngcontent-%COMP%]{grid-area:price;align-self:end}.change[_ngcontent-%COMP%]{grid-area:change;align-self:start;white-space:nowrap}'],changeDetection:0}),t}()},QQZH:function(t,e,n){"use strict";n.d(e,"a",(function(){return f}));var i=n("ZTXN"),r=n("kSHZ"),s=n("bwdy"),u=n("A2S1"),l=n("MiDb"),d=n("yTkW"),f=function(t){a(n,t);var e=c(n);function n(){var t,i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Number.POSITIVE_INFINITY,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Number.POSITIVE_INFINITY,o=arguments.length>2?arguments[2]:void 0;return C(this,n),(t=e.call(this)).scheduler=o,t._events=[],t._infiniteTimeWindow=!1,t._bufferSize=i<1?1:i,t._windowTime=r<1?1:r,r===Number.POSITIVE_INFINITY?(t._infiniteTimeWindow=!0,t.next=t.nextInfiniteTimeWindow):t.next=t.nextTimeWindow,t}return w(n,[{key:"nextInfiniteTimeWindow",value:function(t){if(!this.isStopped){var e=this._events;e.push(t),e.length>this._bufferSize&&e.shift()}o(h(n.prototype),"next",this).call(this,t)}},{key:"nextTimeWindow",value:function(t){this.isStopped||(this._events.push(new p(this._getNow(),t)),this._trimBufferThenGetEvents()),o(h(n.prototype),"next",this).call(this,t)}},{key:"_subscribe",value:function(t){var e,n=this._infiniteTimeWindow,i=n?this._events:this._trimBufferThenGetEvents(),r=this.scheduler,o=i.length;if(this.closed)throw new l.a;if(this.isStopped||this.hasError?e=s.a.EMPTY:(this.observers.push(t),e=new d.a(this,t)),r&&t.add(t=new u.a(t,r)),n)for(var a=0;ae&&(o=Math.max(o,r-e)),o>0&&i.splice(0,o),i}}]),n}(i.b),p=function t(e,n){C(this,t),this.time=e,this.value=n}},Qbn9:function(t,e,n){"use strict";n.d(e,"e",(function(){return i})),n.d(e,"f",(function(){return r})),n.d(e,"c",(function(){return o})),n.d(e,"d",(function(){return a})),n.d(e,"b",(function(){return s})),n.d(e,"a",(function(){return c}));var i=1e3,r=60,o=r*i,a=60,s=a*o,c=r*a*24},QdGC:function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var i=function(t){"Escape"===t.key&&t.target&&"blur"in t.target&&(t.preventDefault(),t.target.blur())}},Qkwj:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("dyLe"),r=n("BfNR");e.default=function(){function t(t,e){this.x=t,this.y=e}return t.prototype.getX=function(){return this.x},t.prototype.getY=function(){return this.y},t.prototype.equals=function(e){return e instanceof t&&this.x===e.x&&this.y===e.y},t.prototype.hashCode=function(){return 31*r.default.floatToIntBits(this.x)+r.default.floatToIntBits(this.y)},t.prototype.toString=function(){return"("+this.x+","+this.y+")"},t.orderBestPatterns=function(t){var e,n,i,r=this.distance(t[0],t[1]),o=this.distance(t[1],t[2]),a=this.distance(t[0],t[2]);if(o>=r&&o>=a?(n=t[0],e=t[1],i=t[2]):a>=o&&a>=r?(n=t[1],e=t[0],i=t[2]):(n=t[2],e=t[0],i=t[1]),this.crossProductZ(e,n,i)<0){var s=e;e=i,i=s}t[0]=e,t[1]=n,t[2]=i},t.distance=function(t,e){return i.default.distance(t.x,t.y,e.x,e.y)},t.crossProductZ=function(t,e,n){var i=e.x,r=e.y;return(n.x-i)*(t.y-r)-(n.y-r)*(t.x-i)},t}()},QmxK:function(t,e,n){"use strict";n.d(e,"b",(function(){return I})),n.d(e,"a",(function(){return M}));var i=n("P4Xx"),r=n("i9xl"),s=n("ROBh"),u=n("YtkY"),l=n("iT4G"),d=n("xVbo"),f=n("5uGe");function p(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-1;return function(e){return e.lift(new g(t,e))}}var b,g=function(){function t(e,n){C(this,t),this.count=e,this.source=n}return w(t,[{key:"call",value:function(t,e){return e.subscribe(new v(t,this.count,this.source))}}]),t}(),v=function(t){a(n,t);var e=c(n);function n(t,i,r){var o;return C(this,n),(o=e.call(this,t)).count=i,o.source=r,o}return w(n,[{key:"error",value:function(t){if(!this.isStopped){var e=this.source,i=this.count;if(0===i)return o(h(n.prototype),"error",this).call(this,t);i>-1&&(this.count=i-1),e.subscribe(this._unsubscribeAndRecycle())}}}]),n}(f.a),y=n("4e/d"),_=n("J+dc"),O=n("7SLS"),k=n("i67J"),T=n("sXtk"),S=n("7UDb"),E=n("yBos"),x=n("Qbn9"),P=n("kZht"),A=n("6uGs"),I={"trading-rest":!0,"trading-ws":!0,auth:!0,charts:!1},M=((b=function(){function t(e,n){C(this,t),this.http=e,this.env=n}return w(t,[{key:"checkSystemHealth",value:function(){return Object(i.a)([this.checkTradingRestHealth(),this.checkTradingWsHealth(),this.checkAuthHealth(),this.checkChartsHealth()]).pipe(Object(u.a)((function(t){var e=m(t,4);return{"trading-rest":e[0],"trading-ws":e[1],auth:e[2],charts:e[3]}})))}},{key:"healthWebsocket",value:function(){var t=this;return Object(r.a)((function(){return Object(E.a)({url:t.env.urls.healthWs}).pipe(Object(l.a)(11*x.e))})).pipe(Object(k.l)(200),Object(d.a)((function(t){return"status"===t.event})),Object(u.a)((function(t){var e=t.data;return{"trading-rest":e.trade,"trading-ws":e.tradeWebsocket,auth:e.auth,charts:e.chart}})))}},{key:"checkTradingRestHealth",value:function(){return this.http.get(this.env.urls.rest+"/readiness?health-check",S.a).pipe(p(2),Object(l.a)(2*x.e),Object(u.a)((function(t){return t.ready?"operational":"degraded"})),Object(y.a)((function(t){var e,n,i;return 503===t.status&&14===(null===(i=null===(n=null===(e=null==t?void 0:t.error)||void 0===e?void 0:e.errors)||void 0===n?void 0:n[0])||void 0===i?void 0:i.code)?Object(s.a)("maintenance"):Object(s.a)("offline")})))}},{key:"checkTradingWsHealth",value:function(){var t=this.env.urls.websocket+"?health-check";return Object(E.a)(t).pipe(p(2),Object(_.a)(1),Object(l.a)(2*x.e),Object(O.a)("operational"),Object(y.a)((function(){return Object(s.a)("offline")})))}},{key:"checkAuthHealth",value:function(){return this.http.get(this.env.urls.auth+"/test?health-check",S.a).pipe(p(2),Object(l.a)(2*x.e),Object(O.a)("operational"),Object(y.a)((function(){return Object(s.a)("offline")})))}},{key:"checkChartsHealth",value:function(){return this.http.get(this.env.urls.rest+"/charts/?health-check",S.a).pipe(p(2),Object(l.a)(2*x.e),Object(O.a)("operational"),Object(y.a)((function(){return Object(s.a)("offline")})))}}]),t}()).\u0275fac=function(t){return new(t||b)(P.Yb(A.a),P.Yb(T.a))},b.\u0275prov=P.Kb({token:b,factory:b.\u0275fac,providedIn:"root"}),b)},Qohw:function(t,e,n){"use strict";n.r(e),n.d(e,"TabSettingsComponent",(function(){return K}));var i=n("D57K"),o=n("mcff"),a=n("zqNl"),s=n("YtkY"),c=n("xVbo"),u=n("uJYd"),l=n("0tVE"),d=n("bjK4"),h=n("+Px6"),f=n("qAYy"),p=n("rxqU"),b=n("gxtV"),g=n("kZht"),m=n("rfPA"),v=n("bBQR"),y=n("gx5s"),_=n("1etq"),O=n("An66"),k=n("LBlH"),T=n("y1fC"),S=n("pPqe"),E=n("aDqW"),x=n("anSm"),P=n("NxuZ"),A=n("WYJo"),I=n("UDV5"),M=n("8spT"),D=n("w2Kr"),R=n("DpwM"),j=n("fvDn"),L=["tabSettingsPopper"],N=["tourPositionRef"];function U(t,e){if(1&t){var n=g.Vb();g.Ub(0,"li",4),g.bc("click",(function(){g.Ec(n);var t=e.$implicit;return g.fc().filterComponents(t)})),g.Qc(1),g.gc(2,"translate"),g.Tb()}if(2&t){var i=e.$implicit,r=g.fc();g.Gb("component--active",i===r.filterSettings),g.Cb(1),g.Sc(" ",g.hc(2,3,"HEADING."+i)," ")}}function F(t,e){if(1&t){var n=g.Vb();g.Ub(0,"section"),g.Ub(1,"h2",11),g.Qc(2,"HEADING.ORDERBOOK"),g.Tb(),g.Ub(3,"section",12),g.Ub(4,"p",13),g.Qc(5,"SUBTITLE.ORDERBOOK_GROUPING"),g.Tb(),g.Ub(6,"div"),g.Ub(7,"small",14),g.Qc(8),g.gc(9,"translate"),g.gc(10,"sato"),g.Tb(),g.Ub(11,"fa-icon",15),g.bc("click",(function(){return g.Ec(n),g.fc().decreaseGrouping()})),g.gc(12,"translate"),g.Tb(),g.Ub(13,"fa-icon",16),g.bc("click",(function(){return g.Ec(n),g.fc().increaseGrouping()})),g.gc(14,"translate"),g.Tb(),g.Tb(),g.Ub(15,"mat-checkbox",17),g.bc("change",(function(t){return g.Ec(n),g.fc().setUpdateFormQuantityFromBook(t.checked)})),g.gc(16,"async"),g.Qc(17),g.gc(18,"translate"),g.Tb(),g.Ub(19,"mat-checkbox",17),g.bc("change",(function(t){return g.Ec(n),g.fc().setFullOrderbook(t.checked)})),g.gc(20,"async"),g.Qc(21),g.gc(22,"translate"),g.Tb(),g.Tb(),g.Tb()}if(2&t){var i=e.$implicit,r=g.fc();g.Cb(8),g.Tc(" ",g.hc(9,12,"LABEL.GROUP"),": ",g.ic(10,14,r.groupingTickSize(i.instrument,i.grouping),i.instrument)," "),g.Cb(3),g.Gb("group--disabled",1===i.grouping),g.mc("matTooltip",g.hc(12,17,"TOOLTIP.DECREASE_ORDER_GROUPING")),g.Cb(2),g.Gb("group--disabled",5e3===i.grouping),g.mc("matTooltip",g.hc(14,19,"TOOLTIP.INCREASE_ORDER_GROUPING")),g.Cb(2),g.mc("checked",g.hc(16,21,r.alsoUpdateQuantity$)),g.Cb(2),g.Sc(" ",g.hc(18,23,"LABEL.UPDATE_FORM_QUANTITY_FROM_BOOK")," "),g.Cb(2),g.mc("checked",g.hc(20,25,r.fullOrderbook$)),g.Cb(2),g.Sc(" ",g.hc(22,27,"LABEL.SCROLLABLE_ORDERBOOK_DEPTH")," ")}}function B(t,e){if(1&t){var n=g.Vb();g.Ub(0,"section"),g.Ub(1,"h2",11),g.Qc(2,"HEADING.MARKET_CHART"),g.Tb(),g.Ub(3,"p",13),g.Qc(4,"LABEL.CANDLE_PRICE_TYPES"),g.Tb(),g.Ub(5,"mat-radio-group",18),g.Ub(6,"mat-radio-button",19),g.bc("change",(function(){return g.Ec(n),g.fc().changeChartType("trade")})),g.Ub(7,"p",14),g.Qc(8),g.gc(9,"translate"),g.Tb(),g.Tb(),g.Ub(10,"mat-radio-button",20),g.bc("change",(function(){return g.Ec(n),g.fc().changeChartType("mark")})),g.Ub(11,"p",14),g.Qc(12),g.gc(13,"translate"),g.Tb(),g.Tb(),g.Tb(),g.Ub(14,"mat-checkbox",17),g.bc("change",(function(t){return g.Ec(n),g.fc().setOrdersVisible(t.checked)})),g.Qc(15),g.gc(16,"translate"),g.Tb(),g.Ub(17,"mat-checkbox",17),g.bc("change",(function(t){return g.Ec(n),g.fc().setPositionsVisible(t.checked)})),g.Qc(18),g.gc(19,"translate"),g.Tb(),g.Ub(20,"mat-checkbox",17),g.bc("change",(function(t){return g.Ec(n),g.fc().setLiquidationLineVisible(t.checked)})),g.Qc(21),g.gc(22,"translate"),g.Tb(),g.Tb()}if(2&t){var i=e.$implicit;g.Cb(5),g.mc("value",i.chartType||"trade"),g.Cb(3),g.Rc(g.hc(9,9,"LABEL.TRADE")),g.Cb(4),g.Rc(g.hc(13,11,"LABEL.MARK")),g.Cb(2),g.mc("checked",!i.hideMarketChartOrders),g.Cb(1),g.Sc(" ",g.hc(16,13,"LABEL.SHOW_ORDERS")," "),g.Cb(2),g.mc("checked",!i.hideMarketChartPositions),g.Cb(1),g.Sc(" ",g.hc(19,15,"LABEL.SHOW_POSITIONS")," "),g.Cb(2),g.mc("checked",!i.hideMarketChartLiquidationPrice),g.Cb(1),g.Sc(" ",g.hc(22,17,"LABEL.SHOW_LIQUIDATION_PRICE")," ")}}var z=function(t){return{pair:t}};function V(t,e){if(1&t){var n=g.Vb();g.Ub(0,"section"),g.Ub(1,"p",11),g.Qc(2,"HEADING.POSITION_ORDER_FILTERING"),g.Tb(),g.Ub(3,"mat-checkbox",17),g.bc("change",(function(t){return g.Ec(n),g.fc().setActivityPairFilter(t.checked)})),g.gc(4,"async"),g.Qc(5),g.gc(6,"translate"),g.gc(7,"cryptoAbbreviation"),g.gc(8,"async"),g.Tb(),g.Tb()}if(2&t){var i=g.fc();g.Cb(3),g.mc("checked",g.hc(4,2,i.isFilteredByPair$)),g.Cb(2),g.Sc(" ",g.ic(6,4,"LABEL.POSITION_ORDER_FILTERING",g.rc(11,z,g.hc(7,7,g.hc(8,9,i.selectedMarketPair$))))," ")}}function H(t,e){if(1&t){var n=g.Vb();g.Ub(0,"section"),g.Ub(1,"p",11),g.Qc(2,"HEADING.TRADE_HISTORY"),g.Tb(),g.Ub(3,"mat-checkbox",17),g.bc("change",(function(t){return g.Ec(n),g.fc().setSizeRelativeTradeHistory(t.checked)})),g.gc(4,"async"),g.Qc(5),g.gc(6,"translate"),g.Tb(),g.Tb()}if(2&t){var i=g.fc();g.Cb(3),g.mc("checked",g.hc(4,2,i.sizeRelativeTradeHistory$)),g.Cb(2),g.Sc(" ",g.hc(6,4,"LABEL.SIZE_RELATIVE_COLOR")," ")}}function q(t,e){if(1&t){var n=g.Vb();g.Ub(0,"tour-step",21),g.bc("nextEvent",(function(){return g.Ec(n),g.fc().closeDialog()}))("previousEvent",(function(){return g.Ec(n),g.fc().closeDialog()}))("dispose",(function(){return g.Ec(n),g.fc(),g.Ac(17).dispose()})),g.Ub(1,"p",11),g.Qc(2,"TOUR.WORKSPACES.5"),g.Tb(),g.Tb()}2&t&&g.mc("title","HEADING.COMPONENT_SETTINGS")("nextRouteTo","/futures")}var $=function(){return[!1,"ORDERBOOK"]},Q=function(t,e){return{instrument:t,grouping:e}},W=function(){return[!1,"MARKET_CHART"]},G=function(){return[!1,"POSITIONS_ORDERS"]},Y=function(){return[!1,"TRADE_HISTORY"]},K=function(){var t=function(){function t(e,n,i){C(this,t),this.inputs=e,this.store=n,this.dialogRef=i,this.componentsWithSettings=["ORDERBOOK","MARKET_CHART","POSITIONS_ORDERS","TRADE_HISTORY"],this.filterSettings=!1,this.userData$=this.store.pipe(Object(a.m)(p.a)),this.alsoUpdateQuantity$=this.userData$.pipe(Object(s.a)((function(t){return t.updateFormQuantityFromBook}))),this.isFilteredByPair$=this.userData$.pipe(Object(s.a)((function(t){return t.activityPairFilterOn}))),this.sizeRelativeTradeHistory$=this.userData$.pipe(Object(s.a)((function(t){var e;return null===(e=t.sizeRelativeTradeHistory)||void 0===e||e}))),this.requireOrderConfirmation$=this.userData$.pipe(Object(s.a)((function(t){return t.requireOrderConfirmation}))),this.fullOrderbook$=this.userData$.pipe(Object(s.a)((function(t){return t.fullOrderbook}))),this.selectedMarketPair$=this.store.pipe(Object(a.m)(h.p)),this.selectedInstrument$=this.store.pipe(Object(a.m)(h.n)),this.orderbookGroup$=this.store.pipe(Object(a.m)(d.p)),this.selectedTicker$=this.store.pipe(Object(a.m)(f.p)),this.tour$=this.store.pipe(Object(a.m)(d.k))}return w(t,[{key:"ngOnInit",value:function(){var t;this.filterSettings=null!==(t=this.inputs.title)&&void 0!==t&&t}},{key:"ngAfterViewInit",value:function(){var t=this;this.tour$.pipe(Object(b.b)(this),Object(c.a)((function(t){return t.inProgress})),Object(c.a)((function(t){return"workspaces"===t.type})),Object(c.a)((function(t){return 5===t.step}))).subscribe((function(e){r(e),t.tabSettingsPopper.componentTrigger(t.tourPositionRef,"centerEnd")}))}},{key:"closeDialog",value:function(){this.dialogRef.close()}},{key:"filterComponents",value:function(t){this.filterSettings=t}},{key:"setUpdateFormQuantityFromBook",value:function(t){this.store.dispatch(Object(l.e)({updateFormQuantityFromBook:t}))}},{key:"setActivityPairFilter",value:function(t){this.store.dispatch(Object(l.e)({activityPairFilterOn:t}))}},{key:"decreaseGrouping",value:function(){this.store.dispatch(Object(u.w)({direction:"minus"}))}},{key:"increaseGrouping",value:function(){this.store.dispatch(Object(u.w)({direction:"plus"}))}},{key:"groupingTickSize",value:function(t,e){return t?e*t.tickSize:1}},{key:"setMarkPriceVisible",value:function(t){this.store.dispatch(Object(l.e)({hideMarketChartMarkPrice:!t}))}},{key:"setOrdersVisible",value:function(t){this.store.dispatch(Object(l.e)({hideMarketChartOrders:!t}))}},{key:"setPositionsVisible",value:function(t){this.store.dispatch(Object(l.e)({hideMarketChartPositions:!t}))}},{key:"setLiquidationLineVisible",value:function(t){this.store.dispatch(Object(l.e)({hideMarketChartLiquidationPrice:!t}))}},{key:"setSizeRelativeTradeHistory",value:function(t){this.store.dispatch(Object(l.e)({sizeRelativeTradeHistory:t}))}},{key:"setRequireOrderConfirmation",value:function(t){this.store.dispatch(Object(l.e)({requireOrderConfirmation:t}))}},{key:"changeChartType",value:function(t){this.store.dispatch(Object(l.e)({chartType:t}))}},{key:"setFullOrderbook",value:function(t){this.store.dispatch(Object(l.e)({fullOrderbook:t}))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(g.Ob(o.a),g.Ob(a.b),g.Ob(o.d))},t.\u0275cmp=g.Ib({type:t,selectors:[["tab-settings"]],viewQuery:function(t,e){var n;1&t&&(g.Jc(L,!0),g.Jc(N,!0)),2&t&&(g.zc(n=g.cc())&&(e.tabSettingsPopper=n.first),g.zc(n=g.cc())&&(e.tourPositionRef=n.first))},decls:19,vars:23,consts:[["heading","HEADING.COMPONENT_SETTINGS"],[1,"tab-settings"],["tourPositionRef",""],[1,"components"],["selectable","","subheading","",1,"component",3,"click"],["selectable","","subheading","","class","component",3,"component--active","click",4,"ngFor","ngForOf"],[1,"settings"],[4,"ngIf"],["sbPlacement","topStart"],["tabSettingsPopper",""],[3,"title","nextRouteTo","nextEvent","previousEvent","dispose",4,"sbContent"],["subheading","","translate",""],[1,"grouping"],["body","","translate",""],["body",""],["icon","minus","size","2x",3,"matTooltip","click"],["icon","plus","size","2x",3,"matTooltip","click"],["body","",1,"no-border",3,"checked","change"],[3,"value"],["value","trade",3,"change"],["value","mark",3,"change"],[3,"title","nextRouteTo","nextEvent","previousEvent","dispose"]],template:function(t,e){1&t&&(g.Ub(0,"pro-dialog",0),g.Ub(1,"section",1,2),g.Ub(3,"ul",3),g.Ub(4,"li",4),g.bc("click",(function(){return e.filterComponents(!1)})),g.Qc(5),g.gc(6,"translate"),g.Tb(),g.Oc(7,U,3,5,"li",5),g.Tb(),g.Ub(8,"section",6),g.Oc(9,F,23,29,"section",7),g.gc(10,"async"),g.gc(11,"async"),g.Oc(12,B,23,19,"section",7),g.gc(13,"async"),g.Oc(14,V,9,13,"section",7),g.Oc(15,H,7,6,"section",7),g.Tb(),g.Tb(),g.Tb(),g.Ub(16,"sb-popper",8,9),g.Oc(18,q,3,2,"tour-step",10),g.Tb()),2&t&&(g.Cb(4),g.Gb("component--active",!1===e.filterSettings),g.Cb(1),g.Sc(" ",g.hc(6,8,"HEADING.ALL_COMPONENTS")," "),g.Cb(2),g.mc("ngForOf",e.componentsWithSettings),g.Cb(2),g.mc("ngIf",g.qc(16,$).includes(e.filterSettings)&&g.sc(17,Q,g.hc(10,10,e.selectedInstrument$),g.hc(11,12,e.orderbookGroup$))),g.Cb(3),g.mc("ngIf",g.qc(20,W).includes(e.filterSettings)&&g.hc(13,14,e.userData$)),g.Cb(2),g.mc("ngIf",g.qc(21,G).includes(e.filterSettings)),g.Cb(1),g.mc("ngIf",g.qc(22,Y).includes(e.filterSettings)))},directives:[m.a,v.a,y.a,_.a,O.m,O.n,k.a,T.a,S.a,E.a,x.a,P.b,A.a,I.a,M.b,M.a,D.a],pipes:[E.d,O.b,R.c,j.a],styles:[".tab-settings[_ngcontent-%COMP%]{display:flex;width:550px}.components[_ngcontent-%COMP%]{align-self:flex-start;background-color:var(--card-colour);border:1px solid var(--border-colour);border-left:0;margin-right:var(--spacing-l)}.components[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{align-items:center;border-left:solid var(--border-colour) var(--spacing-s);cursor:pointer;display:flex;padding:var(--spacing);width:250px}.components[_ngcontent-%COMP%] li[_ngcontent-%COMP%]:not(:last-of-type){border-bottom:1px solid var(--border-colour)}.settings[_ngcontent-%COMP%]{width:100%}.settings[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{display:flex;flex-direction:column;margin-bottom:var(--spacing);padding-bottom:var(--spacing);width:100%}.settings[_ngcontent-%COMP%] > [_ngcontent-%COMP%]:not(:last-of-type){border-bottom:1px solid var(--border-colour)}.settings[_ngcontent-%COMP%] > *[_ngcontent-%COMP%] > h2[_ngcontent-%COMP%], .settings[_ngcontent-%COMP%] > *[_ngcontent-%COMP%] > p[_ngcontent-%COMP%]{margin-bottom:var(--spacing)}.component--active[_ngcontent-%COMP%]{border-left:solid var(--icon-colour) var(--spacing-s)!important;color:var(--icon-colour)}.grouping[_ngcontent-%COMP%]{display:flex;flex-direction:column}.grouping[_ngcontent-%COMP%] div[_ngcontent-%COMP%]{display:flex;align-items:center}.grouping[_ngcontent-%COMP%] div[_ngcontent-%COMP%] small[_ngcontent-%COMP%], .grouping[_ngcontent-%COMP%] small[_ngcontent-%COMP%]{margin-right:var(--spacing-s)}.grouping[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{cursor:pointer;color:var(--text-colour)}.group--disabled[_ngcontent-%COMP%]{opacity:.3;pointer-events:none}.mat-radio-group[_ngcontent-%COMP%]{display:flex;flex-direction:column;margin-bottom:var(--spacing)}"],changeDetection:0}),t=Object(i.d)([Object(b.a)()],t)}()},R1aX:function(t,e,n){"use strict";n.d(e,"a",(function(){return u})),n.d(e,"f",(function(){return d})),n.d(e,"c",(function(){return h})),n.d(e,"b",(function(){return f})),n.d(e,"e",(function(){return p})),n.d(e,"d",(function(){return b}));var i=n("zqNl"),r={NONE:"NONE",UNKNOWN:"NONE",FAILED:"FAILED",RETAIL_INVESTOR:"RETAIL",ACCEPTED_DISCLAIMER:"RETAIL",PER_SE_INVESTOR:"PROFESSIONAL",ELECTIVE_PROFESSIONAL_INVESTOR:"PROFESSIONAL",INVESTOR_TYPES_DISABLED:"NONE"},o=n("Wxxs"),a=n("p5wL"),s={accountType:"individual",classification:"NONE",tier:"NONE",tempT1:"NONE"},c=Object(i.i)(s,Object(i.k)(o.c,(function(){return s})),Object(i.k)(o.d,(function(t,e){var n=e.accountType;return Object(a.b)(n,t,"accountType")})),Object(i.k)(o.e,(function(t,e){var n=e.classification;return Object(a.b)(n,t,"classification")})),Object(i.k)(o.g,(function(t,e){var n=e.status;return Object(a.b)(n,t,"tier")})),Object(i.k)(o.f,(function(t,e){var n=e.status;return Object(a.b)(n,t,"tempT1")})));function u(t,e){return c(t,e)}var l=Object(i.h)("verification"),d=Object(i.j)(l,(function(t){return t})),h=Object(i.j)(l,(function(t){return t.classification})),f=Object(i.j)(l,(function(t){return t.accountType})),p=Object(i.j)(l,(function(t){return t.tier})),b=(Object(i.j)(l,(function(t){return t.tempT1})),Object(i.j)(h,(function(t){return r[t]})))},RCeD:function(t,e,n){"use strict";n.d(e,"a",(function(){return Ot}));var i=n("D57K"),r=n("gxtV"),o=n("zqNl"),a=n("KQpv"),s=n.n(a),c=n("VmIW"),u=n("C05f"),l=n("HM3f"),d=n("YtkY"),h=n("TLy2"),f=n("jIqt"),p=n("0Woy"),b=n("w0kG"),g=n("jOdJ"),v=n("lx5p"),y=n("TYVA"),_=n("NloN"),O=n("vYTc"),k=n("0tVE"),T=n("bjK4"),S=n("+Px6"),E=n("qAYy"),x=n("rxqU"),P=n("Rjzq"),A=n("sxqi"),I=n("aeRQ"),M=n("J/3c"),D=n("mlVJ"),R=n("kZht"),j=n("3kIJ"),L=n("Eu46"),N=n("aaFr"),U=n("ROO/"),F=n("An66"),B=n("yvKM"),z=n("scAs"),V=n("anSm"),H=n("EmXI"),q=n("NxuZ"),$=n("Tcl6"),Q=n("F+Yz"),W=n("SAoO"),G=n("rEzU"),Y=n("rgaJ"),K=n("1o0v"),Z=n("bo+2"),X=n("QHMR"),J=n("icqo"),tt=n("za3o"),et=n("VbQ3"),nt=n("BgTU"),it=n("aDqW"),rt=["filter"],ot=["menuAimer"];function at(t,e){if(1&t){var n=R.Vb();R.Ub(0,"mat-button-toggle",20),R.bc("click",(function(){return R.Ec(n),R.fc(2).filterContractFamily("multi-collateral")})),R.Ub(1,"p",8),R.Qc(2,"Multi-Collateral "),R.Pb(3,"pill",21),R.Tb(),R.Tb()}2&t&&(R.Cb(3),R.mc("label","New"))}function st(t,e){if(1&t){var n=R.Vb();R.Ub(0,"market-picker-asset",31),R.bc("click",(function(){R.Ec(n);var t=e.$implicit;return R.fc(4).selectMarket(t.primaryTicker)})),R.Tb()}if(2&t){var i=e.$implicit,r=R.fc().ngLet;R.mc("asset",i.asset)("primaryTicker",i.primaryTicker)("tickers",i.tickers)("count",i.count),R.Db("data-asset",i.asset.name)("focus",r===i.asset.name)("has-primary",!!i.primaryTicker)}}var ct=function(t){return{num:t}};function ut(t,e){if(1&t&&(R.Sb(0),R.Ub(1,"div",25),R.Ub(2,"div",26),R.Pb(3,"fa-icon",27),R.Tb(),R.Ub(4,"div",28),R.Qc(5),R.gc(6,"translate"),R.Tb(),R.Ub(7,"div",29),R.Qc(8),R.gc(9,"translate"),R.gc(10,"async"),R.Tb(),R.Tb(),R.Oc(11,st,1,7,"market-picker-asset",30),R.gc(12,"async"),R.Rb()),2&t){var n,i=e.ngLet,r=R.fc(3);R.Cb(1),R.Db("data-asset","FAVORITES")("focus","FAVORITES"===i),R.Cb(4),R.Rc(R.hc(6,6,"HEADING.FAVORITES")),R.Cb(3),R.Sc(" ",R.ic(9,8,"LABEL.N_MARKETS",R.rc(15,ct,(null==(n=R.hc(10,11,r.favorites$))?null:n.size)||0))," "),R.Cb(3),R.mc("ngForOf",R.hc(12,13,r.assetItems$))("ngForTrackField","name")}}function lt(t,e){if(1&t){var n=R.Vb();R.Ub(0,"div",22,23),R.bc("menuAimActivate",(function(t){return R.Ec(n),R.fc(2).handleRowActivate(t)})),R.Oc(2,ut,13,17,"ng-container",24),R.gc(3,"async"),R.Tb()}if(2&t){var i=R.fc(2);R.mc("menuAimExitMenu",!0),R.Cb(2),R.mc("ngLet",R.hc(3,2,i.focusAsset$))}}var dt=function(t){return{inactive:t}};function ht(t,e){if(1&t){var n=R.Vb();R.Ub(0,"div",33),R.Ub(1,"section",34),R.Ub(2,"div",35),R.bc("click",(function(){R.Ec(n);var t=e.ngIf;return R.fc(3).changeFlexSort("volume",t.sortDirection)})),R.Ub(3,"p",36),R.Qc(4),R.gc(5,"translate"),R.Tb(),R.Pb(6,"fa-icon",37),R.Tb(),R.Ub(7,"div",35),R.bc("click",(function(){R.Ec(n);var t=e.ngIf;return R.fc(3).changeFlexSort("change",t.sortDirection)})),R.Ub(8,"p",36),R.Qc(9),R.gc(10,"translate"),R.Tb(),R.Pb(11,"fa-icon",37),R.Tb(),R.Tb(),R.Ub(12,"p",38),R.Ub(13,"span",39),R.Qc(14),R.gc(15,"async"),R.Tb(),R.Pb(16,"fa-icon",40),R.Tb(),R.Tb()}if(2&t){var i=e.ngIf,r=R.fc(3),o=R.Ac(3);R.Cb(2),R.mc("ngClass",R.rc(14,dt,"volume"!==i.sort)),R.Cb(2),R.Rc(R.hc(5,8,"LABEL.VOLUME")),R.Cb(2),R.mc("icon","caret-"+i.sortDirection),R.Cb(1),R.mc("ngClass",R.rc(16,dt,"change"!==i.sort)),R.Cb(2),R.Rc(R.hc(10,10,"COLUMN.24H_CHANGE")),R.Cb(2),R.mc("icon","caret-"+i.sortDirection),R.Cb(1),R.mc("sbMenuTriggerFor",o),R.Cb(2),R.Rc(R.hc(15,12,r.flexCategory$))}}var ft=function(t,e){return{sort:t,sortDirection:e}};function pt(t,e){if(1&t&&(R.Sb(0),R.Oc(1,ht,17,18,"div",32),R.gc(2,"async"),R.gc(3,"async"),R.Rb()),2&t){var n=R.fc(2);R.Cb(1),R.mc("ngIf",R.sc(5,ft,R.hc(2,1,n.flexSort$),R.hc(3,3,n.flexSortDirection$)))}}function bt(t,e){if(1&t){var n=R.Vb();R.Ub(0,"market-picker-ticker",43),R.bc("updateFavorite",(function(t){return R.Ec(n),R.fc(3).updateFavorite(t)}))("mouseenter",(function(){R.Ec(n);var t=e.$implicit;return R.fc(3).hoverMarket(t.product_id)}))("click",(function(){R.Ec(n);var t=e.$implicit;return R.fc(3).selectMarket(t)})),R.gc(1,"async"),R.gc(2,"async"),R.gc(3,"async"),R.Tb()}if(2&t){var i=e.$implicit,r=R.fc().ngLet,o=R.fc().ngLet,a=R.fc();R.mc("isFlex","multi-collateral"===o)("ticker",i)("favorites",R.hc(1,7,a.favorites$))("isAlt",R.hc(2,9,a.isAlt$))("focussed",r===i.product_id),R.Db("active",R.hc(3,11,a.activeSymbol$)===i.product_id)("focus",r===i.product_id)}}function gt(t,e){if(1&t&&(R.Ub(0,"cdk-virtual-scroll-viewport",41),R.Oc(1,bt,4,13,"market-picker-ticker",42),R.gc(2,"async"),R.Tb()),2&t){var n=R.fc(2);R.mc("itemSize",48),R.Cb(1),R.mc("cdkVirtualForOf",R.hc(2,3,n.assetTickers$))("cdkVirtualForTrackField","product_id")}}var mt=function(t){return{flex:t}};function vt(t,e){if(1&t){var n=R.Vb();R.Ub(0,"section",4),R.Ub(1,"div",5),R.Ub(2,"mat-button-toggle-group",6),R.Ub(3,"mat-button-toggle",7),R.bc("click",(function(){return R.Ec(n),R.fc().filterContractFamily("single-collateral")})),R.Ub(4,"p",8),R.Qc(5,"Single Collateral"),R.Tb(),R.Tb(),R.Oc(6,at,4,1,"mat-button-toggle",9),R.gc(7,"async"),R.Tb(),R.Tb(),R.Ub(8,"div",10),R.Ub(9,"mat-form-field",11),R.Pb(10,"fa-icon",12),R.Ub(11,"mat-label"),R.Qc(12),R.gc(13,"translate"),R.Tb(),R.Ub(14,"input",13,14),R.bc("keydown",(function(t){return R.Ec(n),R.fc().handleKeybinds(t)})),R.Tb(),R.Ub(16,"fa-icon",15),R.bc("click",(function(t){R.Ec(n);var e=R.fc();return t.stopPropagation(),e.filterControl.setValue("")})),R.Tb(),R.Tb(),R.Tb(),R.Oc(17,lt,4,4,"div",16),R.Oc(18,pt,4,8,"ng-container",17),R.Oc(19,gt,3,5,"cdk-virtual-scroll-viewport",18),R.gc(20,"async"),R.Pb(21,"market-picker-preview",19),R.gc(22,"async"),R.gc(23,"async"),R.Tb()}if(2&t){var i=e.ngLet,r=R.Ac(15),o=R.fc();R.mc("ngClass",R.rc(22,mt,"multi-collateral"===i)),R.Cb(2),R.mc("value",i),R.Cb(4),R.mc("ngIf",R.hc(7,12,o.flexEnabled$)),R.Cb(6),R.Rc(R.hc(13,14,"FORM.SEARCH")),R.Cb(2),R.mc("formControl",o.filterControl),R.Cb(2),R.mc("hidden",0===r.value.length),R.Cb(1),R.mc("ngIf","single-collateral"===i),R.Cb(1),R.mc("ngIf","multi-collateral"===i),R.Cb(1),R.mc("ngLet",R.hc(20,16,o.focusMarket$)),R.Cb(2),R.mc("ticker",R.hc(22,18,o.detailedTicker$))("isAlt",R.hc(23,20,o.isAlt$))("isFlex","multi-collateral"===i)}}function yt(t,e){if(1&t){var n=R.Vb();R.Ub(0,"button",2),R.bc("click",(function(){R.Ec(n);var t=e.$implicit;return R.fc().changeFlexCategory(t)})),R.Ub(1,"span",39),R.Qc(2),R.Tb(),R.Tb()}if(2&t){var i=e.$implicit;R.Cb(2),R.Rc(i)}}var _t=s()("trace:app:market-picker"),Ot=function(){var t=function(){function t(e,n,i,r,a){var s=this;C(this,t),this.store=e,this.fb=n,this.market=i,this.ws=r,this.keybinds=a,this.contractFamily$=new u.a("single-collateral"),this.hoverAsset$=new u.a(Object(c.None)()),this.hoverMarket$=new u.a(Object(c.None)()),this.pairFilter$=new u.a(Object(c.None)()),this.flexSort$=new u.a("volume"),this.flexSortDirection$=new u.a("up"),this.flexCategory$=new u.a("all"),this.filterControl=this.fb.control(""),this.assets$=this.store.pipe(Object(o.m)(S.d)),this.tickers$=this.store.pipe(Object(o.m)(E.o)),this.pairs$=this.store.pipe(Object(o.m)(E.m)),this.favorites$=this.store.pipe(Object(o.m)(x.p)),this.activeSymbol$=this.store.pipe(Object(o.m)(S.r)),this.isAlt$=this.store.pipe(Object(o.m)(T.l)),this.selectedMarket$=this.store.pipe(Object(o.m)(S.n)),this.flexCategories$=this.store.pipe(Object(o.m)(E.e)),this.flexEnabled$=this.store.pipe(Object(o.m)(M.f)),this.userData$=this.store.pipe(Object(o.m)(x.a)),this.focusAsset$=Object(l.a)([this.hoverAsset$,this.activeSymbol$.pipe(Object(d.a)(y.m))]).pipe(Object(d.a)((function(t){var e=m(t,2),n=e[0],i=e[1];return n.orSome(i)}))),this.focusMarket$=Object(l.a)([this.hoverMarket$,this.activeSymbol$]).pipe(Object(d.a)((function(t){var e=m(t,2),n=e[0],i=e[1];return n.orSome(i)}))),this.assetItems$=Object(l.a)([this.tickers$,this.assets$,this.pairFilter$,this.contractFamily$]).pipe(Object(d.a)((function(t){var e=m(t,4),n=e[0],i=e[1],r=e[2],o=e[3];return Object(_.d)("asset-transform",(function(){return i.valueSeq().filter((function(t){var e=t.name;return r.map(v.Q).map((function(t){return[e,Object(y.g)(e)].map(v.Q).some((function(e){return e.includes(t)}))})).orSome(!0)})).map((function(t){var e=n.filter(Tt("XBT"===t.name?"BTC":t.name)).filter(St(o)),i=e.get("".concat("multi-collateral"===o?"PF":"PI","_").concat(t.name,"USD").replace(D.a,"XBT"));return{asset:t,name:t.name,primaryTicker:i,tickers:e,count:e.size}})).filter((function(t){return t.tickers.size>0})).sortBy((function(t){var e,n=t.primaryTicker;return null!==(e=null==n?void 0:n.volume)&&void 0!==e?e:0}),v.i).toArray()}))}))),this.assetTickers$=Object(l.a)([this.tickers$,this.favorites$,this.focusAsset$,this.contractFamily$,this.pairFilter$,Object(l.a)([this.flexSort$,this.flexCategory$,this.flexSortDirection$])]).pipe(Object(d.a)((function(t){var e=m(t,6),n=e[0],i=e[1],r=e[2],o=e[3],a=e[4],s=m(e[5],3),c=s[0],u=s[1],l=s[2];return Object(_.d)("ticker-transform",(function(){var t="up"===l?v.i:v.d;if("FAVORITES"===r&&"multi-collateral"!==o)return n.valueSeq().filter((function(t){return i.has(Object(O.i)(t))})).sortBy(kt,t).toArray();var e=n.filter((function(t){var e=t.pair;return a.map(v.Q).map((function(t){return[e,Object(y.g)(e)].map(v.Q).some((function(e){return e.includes(t)}))})).orSome(!0)})),s="change"===c?xt:Et,d="XBT"===r?"BTC":r;return e.valueSeq().filter("multi-collateral"===o?function(t){return!0}:Tt(d)).filter(St(o)).filter(function(t){return function(e){return"all"===t||!t||e.category===t}}(u)).groupBy(Ct).sortBy(s,t).map(Pt).valueSeq().flatMap(v.j).toArray().sort((function(t,e){return i.has(Object(O.i)(t))?-1:1}))}))}))),this.detailedTicker$=this.focusMarket$.pipe(Object(h.a)((function(t){return s.store.pipe(Object(o.m)(E.d,{symbol:t}))})))}return w(t,[{key:"ngOnInit",value:function(){var t=this;this.focusMarket$.pipe(Object(f.a)(void 0),Object(p.a)(),Object(b.a)(this.store.pipe(Object(o.m)(S.r))),Object(r.b)(this)).subscribe((function(e){var n=m(e,2),i=m(n[0],2),r=i[0],o=i[1],a=n[1];r&&r!==a&&t.ws.closeFeed({feed:"ticker",product_ids:[r]}),o&&o!==a&&t.ws.openFeed({feed:"ticker",product_ids:[o]})})),this.selectedMarket$.pipe(Object(g.a)()).subscribe((function(e){return t.contractFamily$.next("flexible_futures"===(null==e?void 0:e.type)?"multi-collateral":"single-collateral")})),this.filterControl.valueChanges.pipe(Object(d.a)(v.M),Object(r.b)(this)).subscribe((function(e){t.pairFilter$.next(c.Maybe.fromFalsy(e))})),this.keybinds.addBind("escape",(function(){return t.popper.dispose()})),this.keybinds.register()}},{key:"ngAfterViewInit",value:function(){var t=this;setTimeout((function(){return t.filterInput.focus()}))}},{key:"ngOnDestroy",value:function(){var t=this;this.keybinds.dispose(),this.focusMarket$.pipe(Object(b.a)(this.store.pipe(Object(o.m)(S.r))),Object(g.a)()).subscribe((function(e){var n=m(e,2),i=n[0],r=n[1];i&&i!==r&&t.ws.closeFeed({feed:"ticker",product_ids:[i]})}))}},{key:"hoverAsset",value:function(t){this.hoverAsset$.next(Object(c.Some)(t))}},{key:"hoverMarket",value:function(t){this.hoverMarket$.next(Object(c.Some)(t))}},{key:"unHoverPair",value:function(){this.menuAimer.commitExit(),this.hoverAsset$.next(Object(c.None)()),this.hoverMarket$.next(Object(c.None)())}},{key:"selectMarket",value:function(t){t&&(this.market.navigateToMarket(t.product_id),this.popper.dispose())}},{key:"handleKeybinds",value:function(t){"Escape"===t.code&&(t.stopPropagation(),t.target.blur(),this.filterControl.setValue(""))}},{key:"updateFavorite",value:function(t){var e=m(t,2),n=e[0],i=e[1];this.store.dispatch(i?Object(k.d)({marketDescriptor:n}):Object(k.v)({marketDescriptor:n}))}},{key:"handleRowActivate",value:function(t){_t("row activate",t.dataset.asset),"asset"in t.dataset&&this.hoverAsset(t.dataset.asset)}},{key:"filterContractFamily",value:function(t){this.contractFamily$.next(t)}},{key:"changeFlexSort",value:function(t,e){t===this.flexSort$.value&&this.flexSortDirection$.next("up"===e?"down":"up"),this.flexSort$.next(t)}},{key:"changeFlexCategory",value:function(t){this.flexCategory$.next(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(R.Ob(o.b),R.Ob(j.d),R.Ob(A.a),R.Ob(I.a),R.Ob(P.a,2))},t.\u0275cmp=R.Ib({type:t,selectors:[["market-picker"]],viewQuery:function(t,e){var n;1&t&&(R.Jc(rt,!0),R.Jc(ot,!0)),2&t&&(R.zc(n=R.cc())&&(e.filterInput=n.first),R.zc(n=R.cc())&&(e.menuAimer=n.first))},hostBindings:function(t,e){1&t&&R.bc("mouseleave",(function(){return e.unHoverPair()}))},inputs:{popper:"popper"},features:[R.Bb([P.a])],decls:9,vars:6,consts:[["class","market-picker",3,"ngClass",4,"ngLet"],["flexCategories",""],["sb-menu-item","",3,"click"],["sb-menu-item","",3,"click",4,"ngFor","ngForOf"],[1,"market-picker",3,"ngClass"],[1,"futures"],[3,"value"],["value","single-collateral",3,"click"],["bold",""],["value","multi-collateral",3,"click",4,"ngIf"],["body","",1,"search"],["color","accent","appearance","fill"],["icon","search","size","2x","matPrefix","",1,"icon"],["matInput","","autocomplete","off",3,"formControl","keydown"],["filter","matInput"],["icon","close","size","2x","matSuffix","",1,"clear",3,"hidden","click"],["class","assets","menuAim",".asset",3,"menuAimExitMenu","menuAimActivate",4,"ngIf"],[4,"ngIf"],["class","tickers",3,"itemSize",4,"ngLet"],[1,"preview",3,"ticker","isAlt","isFlex"],["value","multi-collateral",3,"click"],[3,"label"],["menuAim",".asset",1,"assets",3,"menuAimExitMenu","menuAimActivate"],["menuAimer","menuAim"],[4,"ngLet"],[1,"asset","favorite-assets"],[1,"icon"],["icon","star-filled"],["body","",1,"asset"],["body","","ghost","",1,"count"],["class","asset",3,"asset","primaryTicker","tickers","count","click",4,"ngFor","ngForOf","ngForTrackField"],[1,"asset",3,"asset","primaryTicker","tickers","count","click"],["class","controls",4,"ngIf"],[1,"controls"],[1,"sort-controls"],[1,"sort-control",3,"ngClass","click"],["body",""],[3,"icon"],["body","",1,"category",3,"sbMenuTriggerFor"],["capitalize",""],["icon","chevron-down","size","lg"],[1,"tickers",3,"itemSize"],[3,"isFlex","ticker","favorites","isAlt","focussed","updateFavorite","mouseenter","click",4,"cdkVirtualFor","cdkVirtualForOf","cdkVirtualForTrackField"],[3,"isFlex","ticker","favorites","isAlt","focussed","updateFavorite","mouseenter","click"]],template:function(t,e){1&t&&(R.Oc(0,vt,24,24,"section",0),R.gc(1,"async"),R.Ub(2,"sb-menu",null,1),R.Ub(4,"button",2),R.bc("click",(function(){return e.changeFlexCategory("all")})),R.Ub(5,"span"),R.Qc(6,"All"),R.Tb(),R.Tb(),R.Oc(7,yt,3,1,"button",3),R.gc(8,"async"),R.Tb()),2&t&&(R.mc("ngLet",R.hc(1,2,e.contractFamily$)),R.Cb(7),R.mc("ngForOf",R.hc(8,4,e.flexCategories$)))},directives:[L.a,N.a,U.a,F.m,F.l,B.b,B.a,z.a,F.n,V.a,H.c,q.b,H.g,H.f,$.b,j.c,j.o,j.f,H.h,Q.a,W.a,G.a,Y.a,K.a,Z.b,X.a,J.b,tt.a,et.e,et.a,et.d,Z.a,nt.a],pipes:[F.b,it.d],styles:['.market-picker[_ngcontent-%COMP%]{padding:var(--spacing) var(--spacing) 0;width:625px;height:525px;display:grid;grid-template:"futures futures" auto "search search" auto "assets tickers" 1fr "assets preview" 200px/280px 1fr;-webkit-user-select:none;-moz-user-select:none;user-select:none}@media (max-width:1024px){.market-picker[_ngcontent-%COMP%]{height:100%;width:100%}}.market-picker.flex[_ngcontent-%COMP%]{grid-template:"futures futures" auto "search search" auto "controls controls" auto "tickers preview" 1fr "tickers preview" 200px/1.5fr 1fr!important}.market-picker.flex[_ngcontent-%COMP%] .tickers[_ngcontent-%COMP%]{margin-right:var(--spacing)!important;padding-bottom:0!important;border-bottom:none!important;border-right:1px solid var(--border-colour)}fa-icon[_ngcontent-%COMP%]{color:var(--icon-colour)}.futures[_ngcontent-%COMP%]{grid-area:futures}.search[_ngcontent-%COMP%]{grid-area:search}.search[_ngcontent-%COMP%] mat-form-field[_ngcontent-%COMP%]{width:100%}.search[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]{margin-right:var(--spacing)}.search[_ngcontent-%COMP%] .clear[_ngcontent-%COMP%]{cursor:pointer}.assets[_ngcontent-%COMP%]{grid-area:assets;margin-right:var(--spacing);padding-right:var(--spacing);padding-bottom:var(--spacing);overflow:hidden auto;border-right:1px solid var(--border-colour)}.assets[_ngcontent-%COMP%] [active=true][_ngcontent-%COMP%]{--pair-color:var(--link-colour)}.assets[_ngcontent-%COMP%] [focus=true][_ngcontent-%COMP%]{background-color:var(--toolbar-colour)}.assets[_ngcontent-%COMP%] market-picker-asset[has-primary=true][_ngcontent-%COMP%]{cursor:pointer}.assets[_ngcontent-%COMP%] .favorite-assets[_ngcontent-%COMP%]{display:block;padding:var(--spacing-s) var(--spacing);height:48px;display:grid;grid-template:"icon asset" auto "icon count" auto/min-content 1fr;gap:var(--spacing-s) var(--spacing-ml);align-items:center;border-radius:var(--bdrs)}.assets[_ngcontent-%COMP%] .favorite-assets[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]{grid-area:icon;font-size:24px}.assets[_ngcontent-%COMP%] .favorite-assets[_ngcontent-%COMP%] .asset[_ngcontent-%COMP%]{grid-area:asset;align-self:end;font-size:14px;color:var(--pair-color,var(--text-colour))}.assets[_ngcontent-%COMP%] .favorite-assets[_ngcontent-%COMP%] .count[_ngcontent-%COMP%]{grid-area:count;align-self:start}.tickers[_ngcontent-%COMP%]{grid-area:tickers;padding-bottom:var(--spacing);margin-bottom:var(--spacing);overflow:hidden auto;border-bottom:1px solid var(--border-colour)}.tickers[_ngcontent-%COMP%] [active=true][_ngcontent-%COMP%]{--market-color:var(--link-colour)}.tickers[_ngcontent-%COMP%] [focus=true][_ngcontent-%COMP%]{background-color:var(--toolbar-colour)}.tickers[_ngcontent-%COMP%] market-picker-ticker[_ngcontent-%COMP%]{cursor:pointer}.preview[_ngcontent-%COMP%]{grid-area:preview;align-self:stretch}.controls[_ngcontent-%COMP%]{display:flex;justify-content:space-between;margin-right:var(--spacing-l);margin-bottom:var(--spacing)}.controls[_ngcontent-%COMP%] .category[_ngcontent-%COMP%]{cursor:pointer}.controls[_ngcontent-%COMP%] .category[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{padding-left:var(--spacing)}.sort-controls[_ngcontent-%COMP%]{display:flex}.sort-control[_ngcontent-%COMP%]{cursor:pointer;margin-right:var(--spacing);display:flex}.sort-control.inactive[_ngcontent-%COMP%]{opacity:.5}'],changeDetection:0}),t=Object(i.d)([Object(r.a)()],t)}(),kt=Object(v.F)("notionalVolume"),wt=Object(v.F)("change"),Ct=Object(v.F)("pair");function Tt(t){return function(e){return e.pair.includes(t)}}function St(t){return function(e){return"multi-collateral"===t?Object(O.a)(e.product_id):e.product_id.startsWith("PI")||e.product_id.startsWith("PV")||e.product_id.startsWith("FI")||e.product_id.startsWith("FV")}}function Et(t){return t.reduce(Object(v.L)(kt),0)}function xt(t){return t.reduce(Object(v.L)(wt),0)}function Pt(t){return t.valueSeq().sortBy(y.y)}},RN2F:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i={update:function(){if("undefined"!=typeof window&&"function"==typeof window.addEventListener){var t=!1,e=Object.defineProperty({},"passive",{get:function(){t=!0}}),n=function(){};window.addEventListener("testPassiveEventSupport",n,e),window.removeEventListener("testPassiveEventSupport",n,e),i.hasSupport=t}}};i.update(),e.default=i},ROBh:function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var i=n("gBlb"),r=n("ckkg"),o=n("czMQ");function a(){for(var t=arguments.length,e=new Array(t),n=0;n0&&void 0!==arguments[0]?arguments[0]:"program",e=arguments.length>1?arguments[1]:void 0;this.focusMonitor.focusVia(this._getHostElement(),t,e),this.focused.next(this)}},{key:"ngOnDestroy",value:function(){this.focusMonitor.stopMonitoring(this.el),this.hovered.complete(),this.focused.complete()}},{key:"_getTabIndex",value:function(){return this.disabled?"-1":"0"}},{key:"_getHostElement",value:function(){return this.el.nativeElement}},{key:"_checkDisabled",value:function(t){this.disabled&&(t.preventDefault(),t.stopPropagation())}},{key:"_handleMouseEnter",value:function(){this.hovered.next(this)}},{key:"getLabel",value:function(){var t=this.el.nativeElement,e=this.document.TEXT_NODE,n="";if(t.childNodes)for(var i=t.childNodes.length,r=0;r1)for(var l=0,d=this.possibleRightPairs;l1&&e.checkChecksum(c,h))return e.constructResult(c,h)}}throw new u.default},e.addOrTally=function(t,e){if(null!=e){for(var n=!1,i=0,r=t;i0;o--)r.append("0");r.append(i);var a=0;for(o=0;o<13;o++){var c=r.charAt(o).charCodeAt(0)-"0".charCodeAt(0);a+=0==(1&o)?3*c:c}10==(a=10-a%10)&&(a=0),r.append(a.toString());var u=t.getFinderPattern().getResultPoints(),h=e.getFinderPattern().getResultPoints();return new s.default(r.toString(),null,0,[u[0],u[1],h[0],h[1]],d.default.RSS_14,(new Date).getTime())},e.checkChecksum=function(t,e){var n=(t.getChecksumPortion()+16*e.getChecksumPortion())%79,i=9*t.getFinderPattern().getValue()+e.getFinderPattern().getValue();return i>72&&i--,i>8&&i--,n===i},e.prototype.decodePair=function(t,e,n,i){try{var r=this.findFinderPattern(t,e),o=this.parseFoundFinderPattern(t,n,e,r),s=null==i?null:i.get(c.default.NEED_RESULT_POINT_CALLBACK);if(null!=s){var u=(r[0]+r[1])/2;e&&(u=t.getSize()-1-u),s.foundPossibleResultPoint(new h.default(u,n))}var l=this.decodeDataCharacter(t,o,!0),d=this.decodeDataCharacter(t,o,!1);return new a.default(1597*l.getValue()+d.getValue(),l.getChecksumPortion()+4*d.getChecksumPortion(),o)}catch(f){return null}},e.prototype.decodeDataCharacter=function(t,n,i){for(var r=this.getDataCharacterCounters(),o=0;o8&&(O=8);var k=Math.floor(a/2);0==(1&a)?(h[k]=O,m[k]=_-O):(f[k]=O,y[k]=_-O)}this.adjustOddEvenCounts(i,l);var w=0,C=0;for(a=h.length-1;a>=0;a--)C*=9,C+=h[a],w+=h[a];var T=0,S=0;for(a=f.length-1;a>=0;a--)T*=9,T+=f[a],S+=f[a];var E,x,P=C+3*T;if(i){if(0!=(1&w)||w>12||w<4)throw new u.default;var A=9-(x=e.OUTSIDE_ODD_WIDEST[E=(12-w)/2]),I=g.default.getRSSvalue(h,x,!1),M=g.default.getRSSvalue(f,A,!0);return new p.default(I*e.OUTSIDE_EVEN_TOTAL_SUBSET[E]+M+e.OUTSIDE_GSUM[E],P)}if(0!=(1&S)||S>10||S<4)throw new u.default;return A=9-(x=e.INSIDE_ODD_WIDEST[E=(10-S)/2]),I=g.default.getRSSvalue(h,x,!0),M=g.default.getRSSvalue(f,A,!1),new p.default(M*e.INSIDE_ODD_TOTAL_SUBSET[E]+I+e.INSIDE_GSUM[E],P)},e.prototype.findFinderPattern=function(t,e){var n=this.getDecodeFinderCounters();n[0]=0,n[1]=0,n[2]=0,n[3]=0;for(var i=t.getSize(),r=!1,a=0;a=0&&o!==t.get(a);)a--;a++;var s=r[0]-a,c=this.getDecodeFinderCounters(),u=new Array(c.length);m.default.arraycopy(c,0,u,1,c.length-1),u[0]=s;var l=this.parseFinderValue(u,e.FINDER_PATTERNS),d=a,h=r[1];return i&&(d=t.getSize()-1-d,h=t.getSize()-1-h),new f.default(l,[a,r[1]],d,h,n)},e.prototype.adjustOddEvenCounts=function(t,e){var n=b.default.sum(new Int32Array(this.getOddCounts())),i=b.default.sum(new Int32Array(this.getEvenCounts())),r=!1,a=!1,s=!1,c=!1;t?(n>12?a=!0:n<4&&(r=!0),i>12?c=!0:i<4&&(s=!0)):(n>11?a=!0:n<5&&(r=!0),i>10?c=!0:i<4&&(s=!0));var l=n+i-e,d=(1&n)==(t?1:0),h=1==(1&i);if(1===l)if(d){if(h)throw new u.default;a=!0}else{if(!h)throw new u.default;c=!0}else if(-1===l)if(d){if(h)throw new u.default;r=!0}else{if(!h)throw new u.default;s=!0}else{if(0!==l)throw new u.default;if(d){if(!h)throw new u.default;n=0&&this.structuredAppendSequenceNumber>=0},t.prototype.getStructuredAppendParity=function(){return this.structuredAppendParity},t.prototype.getStructuredAppendSequenceNumber=function(){return this.structuredAppendSequenceNumber},t}();e.default=i},SrNW:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("5uGe");function r(t,e){var n=!1;return arguments.length>=2&&(n=!0),function(i){return i.lift(new o(t,e,n))}}var o=function(){function t(e,n){var i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];C(this,t),this.accumulator=e,this.seed=n,this.hasSeed=i}return w(t,[{key:"call",value:function(t,e){return e.subscribe(new s(t,this.accumulator,this.seed,this.hasSeed))}}]),t}(),s=function(t){a(n,t);var e=c(n);function n(t,i,r,o){var a;return C(this,n),(a=e.call(this,t)).accumulator=i,a._seed=r,a.hasSeed=o,a.index=0,a}return w(n,[{key:"_next",value:function(t){if(this.hasSeed)return this._tryNext(t);this.seed=t,this.destination.next(t)}},{key:"_tryNext",value:function(t){var e,n=this.index++;try{e=this.accumulator(this.seed,t,n)}catch(i){this.destination.error(i)}this.seed=e,this.destination.next(e)}},{key:"seed",get:function(){return this._seed},set:function(t){this.hasSeed=!0,this._seed=t}}]),n}(i.a)},SxAO:function(t,e,n){"use strict";n("gCmX")},T5QL:function(t,e,n){"use strict";n.d(e,"a",(function(){return l}));var i=n("6uGs"),r=n("P0Wc"),o=n.n(r),a=n("sXtk"),s=n("kZht");function c(t){if(t instanceof Array){var e,n=[],i=p(t);try{for(i.s();!(e=i.n()).done;){var r=e.value;n.push(c(r))}}catch(d){i.e(d)}finally{i.f()}return n}if(t instanceof ArrayBuffer)return o.a.encode(t);if(t instanceof Object){var a,s={},u=p(t);try{for(u.s();!(a=u.n()).done;){var l=a.value;s[l]=c(t[l])}}catch(d){u.e(d)}finally{u.f()}return s}return t}var u={headers:new i.c({"Content-Type":"application/json"}),withCredentials:!0},l=function(){var t=function(){function t(e,n){C(this,t),this.env=e,this.http=n}return w(t,[{key:"fetchRegisterChallenge",value:function(){return this.http.post(this.env.urls.auth+"/fido2/registerchallenge",void 0,u)}},{key:"createPublicKey",value:function(t){var e,n=((e=t).publicKey.challenge=o.a.toBuffer(e.publicKey.challenge),e.publicKey.user.id=o.a.toBuffer(e.publicKey.user.id),e.publicKey.excludeCredentials=e.publicKey.excludeCredentials.map((function(t){var e=t.id;return{type:t.type,id:o.a.toBuffer(e)}})),e);return navigator.credentials.create(n)}},{key:"registerCred",value:function(t,e){var n=c(t);return this.http.post(this.env.urls.auth+"/fido2/register",{cred:n,name:e},u)}},{key:"fetchAuthChallenge",value:function(){return this.http.post(this.env.urls.auth+"/fido2/authenticatechallenge",void 0,u)}},{key:"getAssertion",value:function(t){var e=function(t){t.publicKey.challenge=o.a.toBuffer(t.publicKey.challenge);var e,n=p(t.publicKey.allowCredentials);try{for(n.s();!(e=n.n()).done;){var i=e.value;i.id=o.a.toBuffer(i.id)}}catch(r){n.e(r)}finally{n.f()}return t}(t);return navigator.credentials.get(e)}},{key:"sendAssertion",value:function(t){var e,n=((e=c(t)).response.clientDataJSON=o.a.toBase64(e.response.clientDataJSON),e.response.authenticatorData=o.a.toBase64(e.response.authenticatorData),e.response.signature=o.a.toBase64(e.response.signature),e);return this.http.post(this.env.urls.auth+"/fido2/authenticate",{cred:n},u)}},{key:"fetchCredentials",value:function(){return this.http.get(this.env.urls.auth+"/account/hwcreds",u)}},{key:"deleteCred",value:function(t){return this.http.delete("".concat(this.env.urls.auth,"/account/hwcreds/").concat(t),u)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(s.Yb(a.a),s.Yb(i.a))},t.\u0275prov=s.Kb({token:t,factory:t.\u0275fac}),t}()},TADc:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("kZht"),r=function(){var t=function(){function t(){C(this,t),this.orientation="horizontal"}return w(t,[{key:"vertical",set:function(t){this.orientation=void 0!==t?"vertical":"horizontal"}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=i.Ib({type:t,selectors:[["sb-divider"]],hostVars:1,hostBindings:function(t,e){2&t&&i.Db("orientation",e.orientation)},inputs:{vertical:"vertical"},decls:0,vars:0,template:function(t,e){},styles:["[_nghost-%COMP%]{background-color:var(--divider-color,rgba(var(--ghost-colour-rgb),.5))}[orientation=horizontal][_nghost-%COMP%]{display:block;height:var(--divider-thickness,1px);width:var(--divider-size,calc(100% - var(--spacing-l)));margin:var(--divider-margin,0 auto)}[orientation=vertical][_nghost-%COMP%]{display:inline-block;width:var(--divider-thickness,1px);height:var(--divider-size,calc(100% - var(--spacing-l)))}"],changeDetection:0}),t}()},TDnQ:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("1XZd"),r=n("KZGf");e.default=function(){function t(t,e){this.width=t,this.height=e;for(var n=new Array(e),i=0;i!==e;i++)n[i]=new Uint8Array(t);this.bytes=n}return t.prototype.getHeight=function(){return this.height},t.prototype.getWidth=function(){return this.width},t.prototype.get=function(t,e){return this.bytes[e][t]},t.prototype.getArray=function(){return this.bytes},t.prototype.setNumber=function(t,e,n){this.bytes[e][t]=n},t.prototype.setBoolean=function(t,e,n){this.bytes[e][t]=n?1:0},t.prototype.clear=function(t){for(var e=0,n=this.bytes;e40)throw new c.default;return t.VERSIONS[e-1]},t.decodeVersionInformation=function(e){for(var n=Number.MAX_SAFE_INTEGER,i=0,o=0;o6&&(e.setRegion(t-11,0,3,6),e.setRegion(0,t-11,6,3)),e},t.prototype.toString=function(){return""+this.versionNumber},t.VERSION_DECODE_INFO=Int32Array.from([31892,34236,39577,42195,48118,51042,55367,58893,63784,68472,70749,76311,79154,84390,87683,92361,96236,102084,102881,110507,110734,117786,119615,126325,127568,133589,136944,141498,145311,150283,152622,158308,161089,167017]),t.VERSIONS=[new t(1,new Int32Array(0),new o.default(7,new a.default(1,19)),new o.default(10,new a.default(1,16)),new o.default(13,new a.default(1,13)),new o.default(17,new a.default(1,9))),new t(2,Int32Array.from([6,18]),new o.default(10,new a.default(1,34)),new o.default(16,new a.default(1,28)),new o.default(22,new a.default(1,22)),new o.default(28,new a.default(1,16))),new t(3,Int32Array.from([6,22]),new o.default(15,new a.default(1,55)),new o.default(26,new a.default(1,44)),new o.default(18,new a.default(2,17)),new o.default(22,new a.default(2,13))),new t(4,Int32Array.from([6,26]),new o.default(20,new a.default(1,80)),new o.default(18,new a.default(2,32)),new o.default(26,new a.default(2,24)),new o.default(16,new a.default(4,9))),new t(5,Int32Array.from([6,30]),new o.default(26,new a.default(1,108)),new o.default(24,new a.default(2,43)),new o.default(18,new a.default(2,15),new a.default(2,16)),new o.default(22,new a.default(2,11),new a.default(2,12))),new t(6,Int32Array.from([6,34]),new o.default(18,new a.default(2,68)),new o.default(16,new a.default(4,27)),new o.default(24,new a.default(4,19)),new o.default(28,new a.default(4,15))),new t(7,Int32Array.from([6,22,38]),new o.default(20,new a.default(2,78)),new o.default(18,new a.default(4,31)),new o.default(18,new a.default(2,14),new a.default(4,15)),new o.default(26,new a.default(4,13),new a.default(1,14))),new t(8,Int32Array.from([6,24,42]),new o.default(24,new a.default(2,97)),new o.default(22,new a.default(2,38),new a.default(2,39)),new o.default(22,new a.default(4,18),new a.default(2,19)),new o.default(26,new a.default(4,14),new a.default(2,15))),new t(9,Int32Array.from([6,26,46]),new o.default(30,new a.default(2,116)),new o.default(22,new a.default(3,36),new a.default(2,37)),new o.default(20,new a.default(4,16),new a.default(4,17)),new o.default(24,new a.default(4,12),new a.default(4,13))),new t(10,Int32Array.from([6,28,50]),new o.default(18,new a.default(2,68),new a.default(2,69)),new o.default(26,new a.default(4,43),new a.default(1,44)),new o.default(24,new a.default(6,19),new a.default(2,20)),new o.default(28,new a.default(6,15),new a.default(2,16))),new t(11,Int32Array.from([6,30,54]),new o.default(20,new a.default(4,81)),new o.default(30,new a.default(1,50),new a.default(4,51)),new o.default(28,new a.default(4,22),new a.default(4,23)),new o.default(24,new a.default(3,12),new a.default(8,13))),new t(12,Int32Array.from([6,32,58]),new o.default(24,new a.default(2,92),new a.default(2,93)),new o.default(22,new a.default(6,36),new a.default(2,37)),new o.default(26,new a.default(4,20),new a.default(6,21)),new o.default(28,new a.default(7,14),new a.default(4,15))),new t(13,Int32Array.from([6,34,62]),new o.default(26,new a.default(4,107)),new o.default(22,new a.default(8,37),new a.default(1,38)),new o.default(24,new a.default(8,20),new a.default(4,21)),new o.default(22,new a.default(12,11),new a.default(4,12))),new t(14,Int32Array.from([6,26,46,66]),new o.default(30,new a.default(3,115),new a.default(1,116)),new o.default(24,new a.default(4,40),new a.default(5,41)),new o.default(20,new a.default(11,16),new a.default(5,17)),new o.default(24,new a.default(11,12),new a.default(5,13))),new t(15,Int32Array.from([6,26,48,70]),new o.default(22,new a.default(5,87),new a.default(1,88)),new o.default(24,new a.default(5,41),new a.default(5,42)),new o.default(30,new a.default(5,24),new a.default(7,25)),new o.default(24,new a.default(11,12),new a.default(7,13))),new t(16,Int32Array.from([6,26,50,74]),new o.default(24,new a.default(5,98),new a.default(1,99)),new o.default(28,new a.default(7,45),new a.default(3,46)),new o.default(24,new a.default(15,19),new a.default(2,20)),new o.default(30,new a.default(3,15),new a.default(13,16))),new t(17,Int32Array.from([6,30,54,78]),new o.default(28,new a.default(1,107),new a.default(5,108)),new o.default(28,new a.default(10,46),new a.default(1,47)),new o.default(28,new a.default(1,22),new a.default(15,23)),new o.default(28,new a.default(2,14),new a.default(17,15))),new t(18,Int32Array.from([6,30,56,82]),new o.default(30,new a.default(5,120),new a.default(1,121)),new o.default(26,new a.default(9,43),new a.default(4,44)),new o.default(28,new a.default(17,22),new a.default(1,23)),new o.default(28,new a.default(2,14),new a.default(19,15))),new t(19,Int32Array.from([6,30,58,86]),new o.default(28,new a.default(3,113),new a.default(4,114)),new o.default(26,new a.default(3,44),new a.default(11,45)),new o.default(26,new a.default(17,21),new a.default(4,22)),new o.default(26,new a.default(9,13),new a.default(16,14))),new t(20,Int32Array.from([6,34,62,90]),new o.default(28,new a.default(3,107),new a.default(5,108)),new o.default(26,new a.default(3,41),new a.default(13,42)),new o.default(30,new a.default(15,24),new a.default(5,25)),new o.default(28,new a.default(15,15),new a.default(10,16))),new t(21,Int32Array.from([6,28,50,72,94]),new o.default(28,new a.default(4,116),new a.default(4,117)),new o.default(26,new a.default(17,42)),new o.default(28,new a.default(17,22),new a.default(6,23)),new o.default(30,new a.default(19,16),new a.default(6,17))),new t(22,Int32Array.from([6,26,50,74,98]),new o.default(28,new a.default(2,111),new a.default(7,112)),new o.default(28,new a.default(17,46)),new o.default(30,new a.default(7,24),new a.default(16,25)),new o.default(24,new a.default(34,13))),new t(23,Int32Array.from([6,30,54,78,102]),new o.default(30,new a.default(4,121),new a.default(5,122)),new o.default(28,new a.default(4,47),new a.default(14,48)),new o.default(30,new a.default(11,24),new a.default(14,25)),new o.default(30,new a.default(16,15),new a.default(14,16))),new t(24,Int32Array.from([6,28,54,80,106]),new o.default(30,new a.default(6,117),new a.default(4,118)),new o.default(28,new a.default(6,45),new a.default(14,46)),new o.default(30,new a.default(11,24),new a.default(16,25)),new o.default(30,new a.default(30,16),new a.default(2,17))),new t(25,Int32Array.from([6,32,58,84,110]),new o.default(26,new a.default(8,106),new a.default(4,107)),new o.default(28,new a.default(8,47),new a.default(13,48)),new o.default(30,new a.default(7,24),new a.default(22,25)),new o.default(30,new a.default(22,15),new a.default(13,16))),new t(26,Int32Array.from([6,30,58,86,114]),new o.default(28,new a.default(10,114),new a.default(2,115)),new o.default(28,new a.default(19,46),new a.default(4,47)),new o.default(28,new a.default(28,22),new a.default(6,23)),new o.default(30,new a.default(33,16),new a.default(4,17))),new t(27,Int32Array.from([6,34,62,90,118]),new o.default(30,new a.default(8,122),new a.default(4,123)),new o.default(28,new a.default(22,45),new a.default(3,46)),new o.default(30,new a.default(8,23),new a.default(26,24)),new o.default(30,new a.default(12,15),new a.default(28,16))),new t(28,Int32Array.from([6,26,50,74,98,122]),new o.default(30,new a.default(3,117),new a.default(10,118)),new o.default(28,new a.default(3,45),new a.default(23,46)),new o.default(30,new a.default(4,24),new a.default(31,25)),new o.default(30,new a.default(11,15),new a.default(31,16))),new t(29,Int32Array.from([6,30,54,78,102,126]),new o.default(30,new a.default(7,116),new a.default(7,117)),new o.default(28,new a.default(21,45),new a.default(7,46)),new o.default(30,new a.default(1,23),new a.default(37,24)),new o.default(30,new a.default(19,15),new a.default(26,16))),new t(30,Int32Array.from([6,26,52,78,104,130]),new o.default(30,new a.default(5,115),new a.default(10,116)),new o.default(28,new a.default(19,47),new a.default(10,48)),new o.default(30,new a.default(15,24),new a.default(25,25)),new o.default(30,new a.default(23,15),new a.default(25,16))),new t(31,Int32Array.from([6,30,56,82,108,134]),new o.default(30,new a.default(13,115),new a.default(3,116)),new o.default(28,new a.default(2,46),new a.default(29,47)),new o.default(30,new a.default(42,24),new a.default(1,25)),new o.default(30,new a.default(23,15),new a.default(28,16))),new t(32,Int32Array.from([6,34,60,86,112,138]),new o.default(30,new a.default(17,115)),new o.default(28,new a.default(10,46),new a.default(23,47)),new o.default(30,new a.default(10,24),new a.default(35,25)),new o.default(30,new a.default(19,15),new a.default(35,16))),new t(33,Int32Array.from([6,30,58,86,114,142]),new o.default(30,new a.default(17,115),new a.default(1,116)),new o.default(28,new a.default(14,46),new a.default(21,47)),new o.default(30,new a.default(29,24),new a.default(19,25)),new o.default(30,new a.default(11,15),new a.default(46,16))),new t(34,Int32Array.from([6,34,62,90,118,146]),new o.default(30,new a.default(13,115),new a.default(6,116)),new o.default(28,new a.default(14,46),new a.default(23,47)),new o.default(30,new a.default(44,24),new a.default(7,25)),new o.default(30,new a.default(59,16),new a.default(1,17))),new t(35,Int32Array.from([6,30,54,78,102,126,150]),new o.default(30,new a.default(12,121),new a.default(7,122)),new o.default(28,new a.default(12,47),new a.default(26,48)),new o.default(30,new a.default(39,24),new a.default(14,25)),new o.default(30,new a.default(22,15),new a.default(41,16))),new t(36,Int32Array.from([6,24,50,76,102,128,154]),new o.default(30,new a.default(6,121),new a.default(14,122)),new o.default(28,new a.default(6,47),new a.default(34,48)),new o.default(30,new a.default(46,24),new a.default(10,25)),new o.default(30,new a.default(2,15),new a.default(64,16))),new t(37,Int32Array.from([6,28,54,80,106,132,158]),new o.default(30,new a.default(17,122),new a.default(4,123)),new o.default(28,new a.default(29,46),new a.default(14,47)),new o.default(30,new a.default(49,24),new a.default(10,25)),new o.default(30,new a.default(24,15),new a.default(46,16))),new t(38,Int32Array.from([6,32,58,84,110,136,162]),new o.default(30,new a.default(4,122),new a.default(18,123)),new o.default(28,new a.default(13,46),new a.default(32,47)),new o.default(30,new a.default(48,24),new a.default(14,25)),new o.default(30,new a.default(42,15),new a.default(32,16))),new t(39,Int32Array.from([6,26,54,82,110,138,166]),new o.default(30,new a.default(20,117),new a.default(4,118)),new o.default(28,new a.default(40,47),new a.default(7,48)),new o.default(30,new a.default(43,24),new a.default(22,25)),new o.default(30,new a.default(10,15),new a.default(67,16))),new t(40,Int32Array.from([6,30,58,86,114,142,170]),new o.default(30,new a.default(19,118),new a.default(6,119)),new o.default(28,new a.default(18,47),new a.default(31,48)),new o.default(30,new a.default(34,24),new a.default(34,25)),new o.default(30,new a.default(20,15),new a.default(61,16)))],t}()},TLy2:function(t,e,n){"use strict";n.d(e,"a",(function(){return u}));var i=n("YtkY"),r=n("GoAz"),s=n("uCWR");function u(t,e){return"function"==typeof e?function(n){return n.pipe(u((function(n,o){return Object(r.a)(t(n,o)).pipe(Object(i.a)((function(t,i){return e(n,t,o,i)})))})))}:function(e){return e.lift(new l(t))}}var l=function(){function t(e){C(this,t),this.project=e}return w(t,[{key:"call",value:function(t,e){return e.subscribe(new d(t,this.project))}}]),t}(),d=function(t){a(n,t);var e=c(n);function n(t,i){var r;return C(this,n),(r=e.call(this,t)).project=i,r.index=0,r}return w(n,[{key:"_next",value:function(t){var e,n=this.index++;try{e=this.project(t,n)}catch(i){return void this.destination.error(i)}this._innerSub(e)}},{key:"_innerSub",value:function(t){var e=this.innerSubscription;e&&e.unsubscribe();var n=new s.a(this),i=this.destination;i.add(n),this.innerSubscription=Object(s.c)(t,n),this.innerSubscription!==n&&i.add(this.innerSubscription)}},{key:"_complete",value:function(){var t=this.innerSubscription;t&&!t.closed||o(h(n.prototype),"_complete",this).call(this),this.unsubscribe()}},{key:"_unsubscribe",value:function(){this.innerSubscription=void 0}},{key:"notifyComplete",value:function(){this.innerSubscription=void 0,this.isStopped&&o(h(n.prototype),"_complete",this).call(this)}},{key:"notifyNext",value:function(t){this.destination.next(t)}}]),n}(s.b)},TMzY:function(t,e,n){"use strict";n.d(e,"a",(function(){return o}));var i=n("kZht"),r=n("LaGA"),o=function(){var t=function(){function t(e,n){var o=this;C(this,t),this.element=e,this.renderer=n,this.orientationChange=new i.o,this.observer=new r.a((function(){return o.determineOrientation()}))}return w(t,[{key:"ngOnInit",value:function(){this.observer.observe(this.element.nativeElement)}},{key:"ngOnDestroy",value:function(){this.observer.disconnect()}},{key:"determineOrientation",value:function(){var t,e=this.element.nativeElement,n=e.offsetHeight,i=e.offsetWidth;this.renderer.removeAttribute(e,"orientation"),this.breakpoints?n>this.breakpoints.vertical?(t="vertical",this.renderer.setAttribute(e,"orientation",t)):i>this.breakpoints.horizontal&&(t="horizontal",this.renderer.setAttribute(e,"orientation",t)):(t=this.minVertical?n>i&&n>this.minVertical?"vertical":"horizontal":this.minHorizontal?i>n&&i>this.minHorizontal?"horizontal":"vertical":i>n?"horizontal":"vertical",this.renderer.setAttribute(e,"orientation",t)),this.orientationChange.emit(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(i.Ob(i.l),i.Ob(i.G))},t.\u0275dir=i.Jb({type:t,selectors:[["","orientation",""]],inputs:{breakpoints:"breakpoints",minVertical:"minVertical",minHorizontal:"minHorizontal"},outputs:{orientationChange:"orientationChange"}}),t}()},TNp2:function(t,e,n){"use strict";n.d(e,"a",(function(){return b}));var i=n("KQpv"),r=n.n(i),o=n("ZTXN"),a=n("+6xv"),s=[Object(a.n)("scaleFade",[Object(a.k)("void, initial, hidden",Object(a.l)({opacity:0,transform:"scale(0)"})),Object(a.k)("visible",Object(a.l)({transform:"scale(1)"})),Object(a.m)("* => visible",Object(a.e)("200ms cubic-bezier(0.215, 0.610, 0.355, 1.000)",Object(a.h)([Object(a.l)({opacity:0,transform:"scale(0)",offset:0}),Object(a.l)({opacity:.5,transform:"scale(0.99)",offset:.5}),Object(a.l)({opacity:1,transform:"scale(1)",offset:1})]))),Object(a.m)("* => hidden",Object(a.e)("100ms cubic-bezier(0.215, 0.610, 0.355, 1.000)",Object(a.l)({opacity:0})))])],c=n("kZht"),u=n("An66"),l=n("aDqW");function d(t,e){if(1&t&&(c.Sb(0),c.Qc(1),c.gc(2,"translate"),c.Rb()),2&t){var n=c.fc();c.Cb(1),c.Sc(" ",c.hc(2,1,n.stringContent)," ")}}function h(t,e){if(1&t&&c.Qb(0,3),2&t){var n=c.fc();c.mc("ngTemplateOutlet",n.content)}}var f,p=r()("trace:sb:tooltip-wrapper"),b=((f=function(){function t(e){C(this,t),this.cdr=e,this.closeInInteraction=!1,this.onHide$=new o.b,this.visibility="initial"}return w(t,[{key:"ngOnDestroy",value:function(){this.onHide$.complete()}},{key:"show",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;p("showing in",e,"ms"),this.hideDelayId&&(clearTimeout(this.hideDelayId),this.hideDelayId=void 0),this.closeInInteraction=!0,this.showDelayId=window.setTimeout((function(){t.visibility="visible",t.showDelayId=void 0,t.markForCheck()}),e)}},{key:"hide",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;p("hiding in",e,"ms"),this.showDelayId&&(clearTimeout(this.showDelayId),this.showDelayId=void 0),this.hideDelayId=window.setTimeout((function(){t.visibility="hidden",t.hideDelayId=void 0,t.markForCheck()}),e)}},{key:"animationStart",value:function(t){p("animation start",t),this.closeInInteraction=!1}},{key:"animationDone",value:function(t){p("animation done",t);var e=t.toState;"hidden"===e&&this.onHide$.next(),"visible"!==e&&"hidden"!==e||(this.closeInInteraction=!0)}},{key:"markForCheck",value:function(){p("marking for check"),this.cdr.markForCheck()}},{key:"handleOutsideInteraction",value:function(t){this.closeInInteraction&&this.hide(0)}},{key:"isStringContent",get:function(){return"object"!=typeof this.content}},{key:"stringContent",get:function(){return(""+this.content).trim()}},{key:"isVisible",get:function(){return"visible"===this.visibility}},{key:"afterHidden",get:function(){return this.onHide$.asObservable()}}]),t}()).\u0275fac=function(t){return new(t||f)(c.Ob(c.h))},f.\u0275cmp=c.Ib({type:f,selectors:[["sb-tooltip-wrapper"]],hostAttrs:["aria-hidden","true"],hostBindings:function(t,e){1&t&&c.bc("click",(function(t){return e.handleOutsideInteraction(t)}),!1,c.Bc)},inputs:{content:"content"},decls:4,vars:3,consts:[[1,"sb-tooltip"],[4,"ngIf","ngIfElse"],["templateContent",""],[3,"ngTemplateOutlet"]],template:function(t,e){if(1&t&&(c.Ub(0,"div",0),c.bc("@scaleFade.start",(function(t){return e.animationStart(t)}))("@scaleFade.done",(function(t){return e.animationDone(t)})),c.Oc(1,d,3,3,"ng-container",1),c.Oc(2,h,1,1,"ng-template",null,2,c.Pc),c.Tb()),2&t){var n=c.Ac(3);c.mc("@scaleFade",e.visibility),c.Cb(1),c.mc("ngIf",e.isStringContent)("ngIfElse",n)}},directives:[u.n,u.s],pipes:[l.d],styles:[".sb-tooltip[_ngcontent-%COMP%]{z-index:101;padding:var(--spacing);max-width:var(--mw,350px);font-family:var(--typeface);color:var(--text-colour);font-size:.9rem;background-color:rgba(var(--tooltip-bg-rgb),.9);border:1px solid var(--border-colour);border-radius:var(--bdrs);box-shadow:var(--shadow100)}@supports ((-webkit-backdrop-filter:blur(0)) or (backdrop-filter:blur(0))){.sb-tooltip[_ngcontent-%COMP%]{background-color:rgba(var(--tooltip-bg-rgb),.75);-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px)}}"],data:{animation:[s]},changeDetection:0}),f)},TYVA:function(t,n,i){"use strict";i.d(n,"q",(function(){return u})),i.d(n,"c",(function(){return b})),i.d(n,"b",(function(){return g})),i.d(n,"u",(function(){return _})),i.d(n,"t",(function(){return O})),i.d(n,"x",(function(){return k})),i.d(n,"d",(function(){return w})),i.d(n,"v",(function(){return C})),i.d(n,"j",(function(){return T})),i.d(n,"o",(function(){return S})),i.d(n,"m",(function(){return E})),i.d(n,"p",(function(){return x})),i.d(n,"n",(function(){return P})),i.d(n,"z",(function(){return A})),i.d(n,"k",(function(){return I})),i.d(n,"l",(function(){return M})),i.d(n,"s",(function(){return D})),i.d(n,"g",(function(){return R})),i.d(n,"i",(function(){return j})),i.d(n,"f",(function(){return L})),i.d(n,"e",(function(){return N})),i.d(n,"w",(function(){return U})),i.d(n,"r",(function(){return F})),i.d(n,"y",(function(){return B})),i.d(n,"B",(function(){return z})),i.d(n,"h",(function(){return V})),i.d(n,"a",(function(){return H})),i.d(n,"A",(function(){return q}));var r=i("KQpv"),o=i.n(r),a=i("VmIW"),s=i("lx5p"),c=o()("lib:futures:utils:fees");function u(t,e){var n=Object(s.g)(Object(s.F)("usdVolume"),s.i);return t.map((function(i,r){var o=e.get(r),s=i.tiers.slice().sort(n),u=s.findIndex((function(t){return t.usdVolume<=o}));return-1===u&&c("no fee tier found for ".concat(r.slice(0,4),"..."),{feeSchedules:t,volumes:e}),[s[u],a.Maybe.fromNull(s[u-1])]}))}var l=i("Yu3e"),d=i.n(l),h=i("orIj"),f=i("9hG1"),p=o()("lib:market"),b=":",g="/",v=e(/^[\t-\r \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000\uFEFF]*([FOP])([FILV]?)_(10+)?(([0-9A-Z]+)(USD|USDC|EUR|BTC|XBT))(?:_(([0-9]{2})([0-9]{2})([0-9]{2})))?(?:_([0-9]+(\.[0-9]+)?)_(P|C))?[\t-\r \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000\uFEFF]*$/i,{group:1,type:2,multiplier:3,pair:4,base:5,quote:6,date:7,year:8,month:9,day:10,optionstrike:11,optiontype:13}),y=/^\s*P([IVF])_(([A-Z0-9]{1,7})([A-Z0-9]{3,4}))(?:_(\w+))\s*$/i,_=d()((function(t){var e=t.toUpperCase(),n=function(t){return Object(s.y)(v,t).flatMap((function(e){if(null==(null==e?void 0:e.groups))return a.Maybe.None();var n=e.groups,i=n.group,r=n.type,o=n.multiplier,s=n.pair,c=n.base,u=n.quote,l=n.date,d=n.year,h=n.month,f=n.day,p=c.replace("XBT","BTC"),b=u.replace("XBT","BTC"),m="P"===i,v="I"===r,y={original:t,perpetual:m,inverse:v,collateral:v?p:b,traded:v?b:p,pair:"".concat(p).concat(g).concat(b),customTag:void 0,parts:{family:"F"===r?"flex":"cryp",group:i,type:r,multiplier:o,currencies:{raw:s,base:p,quote:b},maturity:m?void 0:{raw:l,day:f,month:h,year:d,date:new Date("20".concat(d,"-").concat(h,"-").concat(f))}}};return a.Maybe.Just(y)}))}(e);if(n.isSome())return n.some();var i=O(e);if(i.isSome())return i.some();var r=new Error(t+" is not a parsable symbol");throw p(r),r}));function O(t){return Object(s.y)(y,t).map((function(e){var n=m(e.slice(1),5),i=n[0],r=n[1],o=n[2],a=n[3],s=n[4],c=o.replace("XBT","BTC"),u=a.replace("XBT","BTC"),l="I"===i;return{original:t,perpetual:!0,inverse:l,collateral:l?c:u,traded:l?u:c,pair:"".concat(c,"/").concat(u),customTag:s,parts:{family:"F"===i?"flex":"cryp",group:"P",type:i,multiplier:void 0,currencies:{raw:r,base:c,quote:u},maturity:void 0}}}))}function k(t){try{return _(t)}catch(e){return null}}var w=function(t){return t.parts.currencies.base},C=function(t){return t.parts.currencies.quote};function T(t){return _(t).pair}function S(t){return _(t).pair}function E(t){return _(t).parts.currencies.base}function x(t){return _(t).parts.currencies.quote}function P(t){return _(t).collateral}function A(t){return _(t).traded}function I(t){return t.split("/")[0]}function M(t){return t.split("/")[1]}function D(t,e){return(t+e)/2}function R(t){if(!t)return t;var e=t.toUpperCase();return e in h.a?h.a[e]:e}function j(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"long",n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=_(t);if(i.perpetual)return n?"long"===e?"TAG.PERPETUAL":"TAG.PERP":"long"===e?"Perpetual":"Perp";var r=f.DateTime.fromJSDate(i.parts.maturity.date);return"long"===e?r.monthLong:r.monthShort}function L(t){return"F"===_(t).parts.type?"mc":"sc"}var N=["XBT","BTC","ETH","LTC","BCH","XRP","EUR"],U=["USD","EUR","XBT","BTC"],F=["perpetual","week","month","quarter","semiannual"],B=Object(s.E)(Object(s.F)("tag"),(function(t){return F.indexOf(t)})),z=["holding","flex","futures"];function V(){var t,e,n,i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,r=arguments.length>1&&void 0!==arguments[1]&&arguments[1],o=f.DateTime.local(),a=f.DateTime.fromMillis(i),s=f.Interval.fromDateTimes(o,a).toDuration(["months","days","hours","minutes","seconds"]);return o>a?"0d:00h:00m":s.months>0?"".concat((t=s.months,e=s.days,n=f.DateTime.local().plus(f.Duration.fromObject({months:t,days:e,conversionAccuracy:"longterm"})).diffNow().as("days"),Math.round(n)),"d:").concat(s.hours,"h:").concat(Math.floor(s.minutes),"m"):r?"".concat(s.days,"d:").concat(s.hours,"h:").concat(Math.floor(s.minutes),"m:").concat(Math.floor(s.seconds),"s"):"".concat(s.days,"d:").concat(s.hours,"h:").concat(Math.floor(s.minutes),"m")}var H={trading:"order",wallet:"face"};function q(){var t=window.innerWidth;return t>=1920?"desktop-max":t>=1441?"desktop-large":t>=1367?"desktop-medium":"desktop-small"}},Tcl6:function(t,e,n){"use strict";n.d(e,"a",(function(){return _})),n.d(e,"b",(function(){return S})),n.d(e,"c",(function(){return E}));var i=n("O1jd"),r=n("kZht"),o=n("5XID"),s=n("6Oco"),u=n("ZTXN");n("KTx3"),n("prE9"),n("kuMc"),n("An66");var l,d,h,f,p=Object(i.f)({passive:!0}),b=((d=function(){function t(e,n){C(this,t),this._platform=e,this._ngZone=n,this._monitoredElements=new Map}return w(t,[{key:"monitor",value:function(t){var e=this;if(!this._platform.isBrowser)return s.a;var n=Object(o.e)(t),i=this._monitoredElements.get(n);if(i)return i.subject;var r=new u.b,a="cdk-text-field-autofilled",c=function(t){"cdk-text-field-autofill-start"!==t.animationName||n.classList.contains(a)?"cdk-text-field-autofill-end"===t.animationName&&n.classList.contains(a)&&(n.classList.remove(a),e._ngZone.run((function(){return r.next({target:t.target,isAutofilled:!1})}))):(n.classList.add(a),e._ngZone.run((function(){return r.next({target:t.target,isAutofilled:!0})})))};return this._ngZone.runOutsideAngular((function(){n.addEventListener("animationstart",c,p),n.classList.add("cdk-text-field-autofill-monitored")})),this._monitoredElements.set(n,{subject:r,unlisten:function(){n.removeEventListener("animationstart",c,p)}}),r}},{key:"stopMonitoring",value:function(t){var e=Object(o.e)(t),n=this._monitoredElements.get(e);n&&(n.unlisten(),n.subject.complete(),e.classList.remove("cdk-text-field-autofill-monitored"),e.classList.remove("cdk-text-field-autofilled"),this._monitoredElements.delete(e))}},{key:"ngOnDestroy",value:function(){var t=this;this._monitoredElements.forEach((function(e,n){return t.stopMonitoring(n)}))}}]),t}()).\u0275fac=function(t){return new(t||d)(r.Yb(i.a),r.Yb(r.B))},d.\u0275prov=Object(r.Kb)({factory:function(){return new d(Object(r.Yb)(i.a),Object(r.Yb)(r.B))},token:d,providedIn:"root"}),d),g=((l=function t(){C(this,t)}).\u0275mod=r.Mb({type:l}),l.\u0275inj=r.Lb({factory:function(t){return new(t||l)},imports:[[i.b]]}),l),m=n("3kIJ"),v=n("pTnX"),y=n("EmXI"),_=new r.s("MAT_INPUT_VALUE_ACCESSOR"),O=["button","checkbox","file","hidden","image","radio","range","reset","submit"],k=0,T=Object(v.z)((function t(e,n,i,r){C(this,t),this._defaultErrorStateMatcher=e,this._parentForm=n,this._parentFormGroup=i,this.ngControl=r})),S=((f=function(t){a(n,t);var e=c(n);function n(t,r,o,a,s,c,l,d,h,f){var p;C(this,n),(p=e.call(this,c,a,s,o))._elementRef=t,p._platform=r,p.ngControl=o,p._autofillMonitor=d,p._formField=f,p._uid="mat-input-"+k++,p.focused=!1,p.stateChanges=new u.b,p.controlType="mat-input",p.autofilled=!1,p._disabled=!1,p._required=!1,p._type="text",p._readonly=!1,p._neverEmptyInputTypes=["date","datetime","datetime-local","month","time","week"].filter((function(t){return Object(i.e)().has(t)}));var b=p._elementRef.nativeElement,g=b.nodeName.toLowerCase();return p._inputValueAccessor=l||b,p._previousNativeValue=p.value,p.id=p.id,r.IOS&&h.runOutsideAngular((function(){t.nativeElement.addEventListener("keyup",(function(t){var e=t.target;e.value||e.selectionStart||e.selectionEnd||(e.setSelectionRange(1,1),e.setSelectionRange(0,0))}))})),p._isServer=!p._platform.isBrowser,p._isNativeSelect="select"===g,p._isTextarea="textarea"===g,p._isNativeSelect&&(p.controlType=b.multiple?"mat-native-select-multiple":"mat-native-select"),p}return w(n,[{key:"ngAfterViewInit",value:function(){var t=this;this._platform.isBrowser&&this._autofillMonitor.monitor(this._elementRef.nativeElement).subscribe((function(e){t.autofilled=e.isAutofilled,t.stateChanges.next()}))}},{key:"ngOnChanges",value:function(){this.stateChanges.next()}},{key:"ngOnDestroy",value:function(){this.stateChanges.complete(),this._platform.isBrowser&&this._autofillMonitor.stopMonitoring(this._elementRef.nativeElement)}},{key:"ngDoCheck",value:function(){this.ngControl&&this.updateErrorState(),this._dirtyCheckNativeValue(),this._dirtyCheckPlaceholder()}},{key:"focus",value:function(t){this._elementRef.nativeElement.focus(t)}},{key:"_focusChanged",value:function(t){t===this.focused||this.readonly&&t||(this.focused=t,this.stateChanges.next())}},{key:"_onInput",value:function(){}},{key:"_dirtyCheckPlaceholder",value:function(){var t,e,n=(null===(e=null===(t=this._formField)||void 0===t?void 0:t._hideControlPlaceholder)||void 0===e?void 0:e.call(t))?null:this.placeholder;if(n!==this._previousPlaceholder){var i=this._elementRef.nativeElement;this._previousPlaceholder=n,n?i.setAttribute("placeholder",n):i.removeAttribute("placeholder")}}},{key:"_dirtyCheckNativeValue",value:function(){var t=this._elementRef.nativeElement.value;this._previousNativeValue!==t&&(this._previousNativeValue=t,this.stateChanges.next())}},{key:"_validateType",value:function(){O.indexOf(this._type)}},{key:"_isNeverEmpty",value:function(){return this._neverEmptyInputTypes.indexOf(this._type)>-1}},{key:"_isBadInput",value:function(){var t=this._elementRef.nativeElement.validity;return t&&t.badInput}},{key:"setDescribedByIds",value:function(t){t.length?this._elementRef.nativeElement.setAttribute("aria-describedby",t.join(" ")):this._elementRef.nativeElement.removeAttribute("aria-describedby")}},{key:"onContainerClick",value:function(){this.focused||this.focus()}},{key:"disabled",get:function(){return this.ngControl&&null!==this.ngControl.disabled?this.ngControl.disabled:this._disabled},set:function(t){this._disabled=Object(o.c)(t),this.focused&&(this.focused=!1,this.stateChanges.next())}},{key:"id",get:function(){return this._id},set:function(t){this._id=t||this._uid}},{key:"required",get:function(){return this._required},set:function(t){this._required=Object(o.c)(t)}},{key:"type",get:function(){return this._type},set:function(t){this._type=t||"text",this._validateType(),!this._isTextarea&&Object(i.e)().has(this._type)&&(this._elementRef.nativeElement.type=this._type)}},{key:"value",get:function(){return this._inputValueAccessor.value},set:function(t){t!==this.value&&(this._inputValueAccessor.value=t,this.stateChanges.next())}},{key:"readonly",get:function(){return this._readonly},set:function(t){this._readonly=Object(o.c)(t)}},{key:"empty",get:function(){return!(this._isNeverEmpty()||this._elementRef.nativeElement.value||this._isBadInput()||this.autofilled)}},{key:"shouldLabelFloat",get:function(){if(this._isNativeSelect){var t=this._elementRef.nativeElement,e=t.options[0];return this.focused||t.multiple||!this.empty||!!(t.selectedIndex>-1&&e&&e.label)}return this.focused||!this.empty}}]),n}(T)).\u0275fac=function(t){return new(t||f)(r.Ob(r.l),r.Ob(i.a),r.Ob(m.n,10),r.Ob(m.q,8),r.Ob(m.h,8),r.Ob(v.d),r.Ob(_,10),r.Ob(b),r.Ob(r.B),r.Ob(y.a,8))},f.\u0275dir=r.Jb({type:f,selectors:[["input","matInput",""],["textarea","matInput",""],["select","matNativeControl",""],["input","matNativeControl",""],["textarea","matNativeControl",""]],hostAttrs:[1,"mat-input-element","mat-form-field-autofill-control"],hostVars:9,hostBindings:function(t,e){1&t&&r.bc("focus",(function(){return e._focusChanged(!0)}))("blur",(function(){return e._focusChanged(!1)}))("input",(function(){return e._onInput()})),2&t&&(r.Xb("disabled",e.disabled)("required",e.required),r.Db("id",e.id)("data-placeholder",e.placeholder)("readonly",e.readonly&&!e._isNativeSelect||null)("aria-invalid",e.errorState)("aria-required",e.required.toString()),r.Gb("mat-input-server",e._isServer))},inputs:{id:"id",disabled:"disabled",required:"required",type:"type",value:"value",readonly:"readonly",placeholder:"placeholder",errorStateMatcher:"errorStateMatcher",userAriaDescribedBy:["aria-describedby","userAriaDescribedBy"]},exportAs:["matInput"],features:[r.Bb([{provide:y.d,useExisting:f}]),r.zb,r.Ab]}),f),E=((h=function t(){C(this,t)}).\u0275mod=r.Mb({type:h}),h.\u0275inj=r.Lb({factory:function(t){return new(t||h)},providers:[v.d],imports:[[g,y.e],g,y.e]}),h)},Ti3e:function(t,e,n){"use strict";n.d(e,"a",(function(){return r})),n.d(e,"b",(function(){return o}));var i=n("5E2i");function r(){for(var t=arguments.length,e=new Array(t),n=0;n').concat(n,"")}function r(t){return''.concat(t,"
")}function o(t){return''.concat(t,"")}n.d(e,"a",(function(){return i})),n.d(e,"c",(function(){return r})),n.d(e,"b",(function(){return o}))},TuP6:function(t,e,n){var i=n("VTjg");function r(t,e){var n=t.a/255,i=e+'="'+t.hex+'"';return n<1?i+" "+e+'-opacity="'+n.toFixed(2).slice(1)+'"':i}function o(t,e,n){var i=t+e;return void 0!==n&&(i+=" "+n),i}e.render=function(t,e,n){var a=i.getOptions(e),s=t.modules.size,c=t.modules.data,u=s+2*a.margin,l=a.color.light.a?"':"",d="0&&u>0&&t[c-1]||(i+=a?o("M",u+n,.5+l+n):o("m",r,0),r=0,a=!1),u+1',h='\n";return"function"==typeof n&&n(null,h),h}},TzY9:function(t,e,n){"use strict";n.d(e,"a",(function(){return c}));var i=n("Tcl6"),r=n("kZht"),o=n("EmXI"),a=n("3kIJ"),s=n("aDqW"),c=function(){var t=function(){function t(){C(this,t),this.controlName="otp"}return w(t,[{key:"ngOnInit",value:function(){this.input.focus()}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=r.Ib({type:t,selectors:[["input-otp-entry"]],viewQuery:function(t,e){var n;1&t&&r.Jc(i.b,!0),2&t&&r.zc(n=r.cc())&&(e.input=n.first)},inputs:{form:"form",controlName:"controlName"},decls:5,vars:5,consts:[["color","accent","appearance","fill",3,"formGroup"],["matInput","","maxlength","6","autocomplete","off",3,"formControlName"]],template:function(t,e){1&t&&(r.Ub(0,"mat-form-field",0),r.Ub(1,"mat-label"),r.Qc(2),r.gc(3,"translate"),r.Tb(),r.Pb(4,"input",1),r.Tb()),2&t&&(r.mc("formGroup",e.form),r.Cb(2),r.Rc(r.hc(3,3,"FORM.GOOGLE_AUTH_CODE")),r.Cb(2),r.mc("formControlName",e.controlName))},directives:[o.c,a.p,a.h,o.f,i.b,a.c,a.k,a.o,a.g],pipes:[s.d],styles:["[_nghost-%COMP%]{display:block}mat-form-field[_ngcontent-%COMP%]{margin-top:var(--margin-top,0);width:100%}"],changeDetection:0}),t}()},UDV5:function(t,e,n){"use strict";n.d(e,"a",(function(){return O})),n.d(e,"b",(function(){return x})),n.d(e,"c",(function(){return T}));var i=n("jL3B"),r=n("5XID"),o=n("kZht"),s=n("3kIJ"),u=n("pTnX"),l=n("FxgA"),d=n("s2U3"),h=["input"],f=function(){return{enterDuration:150}},p=["*"],b=new o.s("mat-checkbox-default-options",{providedIn:"root",factory:function(){return{color:"accent",clickAction:"check-indeterminate"}}}),g=new o.s("mat-checkbox-click-action"),m=0,v={provide:s.m,useExisting:Object(o.V)((function(){return O})),multi:!0},y=function t(){C(this,t)},_=Object(u.B)(Object(u.w)(Object(u.x)(Object(u.y)((function t(e){C(this,t),this._elementRef=e}))))),O=function(){var t=function(t){a(n,t);var e=c(n);function n(t,i,r,a,s,c,u,l){var d;return C(this,n),(d=e.call(this,t))._changeDetectorRef=i,d._focusMonitor=r,d._ngZone=a,d._clickAction=c,d._animationMode=u,d._options=l,d.ariaLabel="",d.ariaLabelledby=null,d._uniqueId="mat-checkbox-"+ ++m,d.id=d._uniqueId,d.labelPosition="after",d.name=null,d.change=new o.o,d.indeterminateChange=new o.o,d._onTouched=function(){},d._currentAnimationClass="",d._currentCheckState=0,d._controlValueAccessorChangeFn=function(){},d._checked=!1,d._disabled=!1,d._indeterminate=!1,d._options=d._options||{},d._options.color&&(d.color=d.defaultColor=d._options.color),d.tabIndex=parseInt(s)||0,d._clickAction=d._clickAction||d._options.clickAction,d}return w(n,[{key:"ngAfterViewInit",value:function(){var t=this;this._focusMonitor.monitor(this._elementRef,!0).subscribe((function(e){e||Promise.resolve().then((function(){t._onTouched(),t._changeDetectorRef.markForCheck()}))})),this._syncIndeterminate(this._indeterminate)}},{key:"ngAfterViewChecked",value:function(){}},{key:"ngOnDestroy",value:function(){this._focusMonitor.stopMonitoring(this._elementRef)}},{key:"_isRippleDisabled",value:function(){return this.disableRipple||this.disabled}},{key:"_onLabelTextChange",value:function(){this._changeDetectorRef.detectChanges()}},{key:"writeValue",value:function(t){this.checked=!!t}},{key:"registerOnChange",value:function(t){this._controlValueAccessorChangeFn=t}},{key:"registerOnTouched",value:function(t){this._onTouched=t}},{key:"setDisabledState",value:function(t){this.disabled=t}},{key:"_getAriaChecked",value:function(){return this.checked?"true":this.indeterminate?"mixed":"false"}},{key:"_transitionCheckState",value:function(t){var e=this._currentCheckState,n=this._elementRef.nativeElement;if(e!==t&&(this._currentAnimationClass.length>0&&n.classList.remove(this._currentAnimationClass),this._currentAnimationClass=this._getAnimationClassForCheckStateTransition(e,t),this._currentCheckState=t,this._currentAnimationClass.length>0)){n.classList.add(this._currentAnimationClass);var i=this._currentAnimationClass;this._ngZone.runOutsideAngular((function(){setTimeout((function(){n.classList.remove(i)}),1e3)}))}}},{key:"_emitChangeEvent",value:function(){var t=new y;t.source=this,t.checked=this.checked,this._controlValueAccessorChangeFn(this.checked),this.change.emit(t)}},{key:"toggle",value:function(){this.checked=!this.checked}},{key:"_onInputClick",value:function(t){var e=this;t.stopPropagation(),this.disabled||"noop"===this._clickAction?this.disabled||"noop"!==this._clickAction||(this._inputElement.nativeElement.checked=this.checked,this._inputElement.nativeElement.indeterminate=this.indeterminate):(this.indeterminate&&"check"!==this._clickAction&&Promise.resolve().then((function(){e._indeterminate=!1,e.indeterminateChange.emit(e._indeterminate)})),this.toggle(),this._transitionCheckState(this._checked?1:2),this._emitChangeEvent())}},{key:"focus",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"keyboard",e=arguments.length>1?arguments[1]:void 0;this._focusMonitor.focusVia(this._inputElement,t,e)}},{key:"_onInteractionEvent",value:function(t){t.stopPropagation()}},{key:"_getAnimationClassForCheckStateTransition",value:function(t,e){if("NoopAnimations"===this._animationMode)return"";var n="";switch(t){case 0:if(1===e)n="unchecked-checked";else{if(3!=e)return"";n="unchecked-indeterminate"}break;case 2:n=1===e?"unchecked-checked":"unchecked-indeterminate";break;case 1:n=2===e?"checked-unchecked":"checked-indeterminate";break;case 3:n=1===e?"indeterminate-checked":"indeterminate-unchecked"}return"mat-checkbox-anim-"+n}},{key:"_syncIndeterminate",value:function(t){var e=this._inputElement;e&&(e.nativeElement.indeterminate=t)}},{key:"inputId",get:function(){return(this.id||this._uniqueId)+"-input"}},{key:"required",get:function(){return this._required},set:function(t){this._required=Object(r.c)(t)}},{key:"checked",get:function(){return this._checked},set:function(t){t!=this.checked&&(this._checked=t,this._changeDetectorRef.markForCheck())}},{key:"disabled",get:function(){return this._disabled},set:function(t){var e=Object(r.c)(t);e!==this.disabled&&(this._disabled=e,this._changeDetectorRef.markForCheck())}},{key:"indeterminate",get:function(){return this._indeterminate},set:function(t){var e=t!=this._indeterminate;this._indeterminate=Object(r.c)(t),e&&(this._transitionCheckState(this._indeterminate?3:this.checked?1:2),this.indeterminateChange.emit(this._indeterminate)),this._syncIndeterminate(this._indeterminate)}}]),n}(_);return t.\u0275fac=function(e){return new(e||t)(o.Ob(o.l),o.Ob(o.h),o.Ob(i.h),o.Ob(o.B),o.Zb("tabindex"),o.Ob(g,8),o.Ob(l.a,8),o.Ob(b,8))},t.\u0275cmp=o.Ib({type:t,selectors:[["mat-checkbox"]],viewQuery:function(t,e){var n;1&t&&(o.Wc(h,!0),o.Wc(u.r,!0)),2&t&&(o.zc(n=o.cc())&&(e._inputElement=n.first),o.zc(n=o.cc())&&(e.ripple=n.first))},hostAttrs:[1,"mat-checkbox"],hostVars:12,hostBindings:function(t,e){2&t&&(o.Xb("id",e.id),o.Db("tabindex",null),o.Gb("mat-checkbox-indeterminate",e.indeterminate)("mat-checkbox-checked",e.checked)("mat-checkbox-disabled",e.disabled)("mat-checkbox-label-before","before"==e.labelPosition)("_mat-animation-noopable","NoopAnimations"===e._animationMode))},inputs:{disableRipple:"disableRipple",color:"color",tabIndex:"tabIndex",ariaLabel:["aria-label","ariaLabel"],ariaLabelledby:["aria-labelledby","ariaLabelledby"],id:"id",labelPosition:"labelPosition",name:"name",required:"required",checked:"checked",disabled:"disabled",indeterminate:"indeterminate",ariaDescribedby:["aria-describedby","ariaDescribedby"],value:"value"},outputs:{change:"change",indeterminateChange:"indeterminateChange"},exportAs:["matCheckbox"],features:[o.Bb([v]),o.zb],ngContentSelectors:p,decls:17,vars:20,consts:[[1,"mat-checkbox-layout"],["label",""],[1,"mat-checkbox-inner-container"],["type","checkbox",1,"mat-checkbox-input","cdk-visually-hidden",3,"id","required","checked","disabled","tabIndex","change","click"],["input",""],["matRipple","",1,"mat-checkbox-ripple","mat-focus-indicator",3,"matRippleTrigger","matRippleDisabled","matRippleRadius","matRippleCentered","matRippleAnimation"],[1,"mat-ripple-element","mat-checkbox-persistent-ripple"],[1,"mat-checkbox-frame"],[1,"mat-checkbox-background"],["version","1.1","focusable","false","viewBox","0 0 24 24",0,"xml","space","preserve",1,"mat-checkbox-checkmark"],["fill","none","stroke","white","d","M4.1,12.7 9,17.6 20.3,6.3",1,"mat-checkbox-checkmark-path"],[1,"mat-checkbox-mixedmark"],[1,"mat-checkbox-label",3,"cdkObserveContent"],["checkboxLabel",""],[2,"display","none"]],template:function(t,e){if(1&t&&(o.lc(),o.Ub(0,"label",0,1),o.Ub(2,"div",2),o.Ub(3,"input",3,4),o.bc("change",(function(t){return e._onInteractionEvent(t)}))("click",(function(t){return e._onInputClick(t)})),o.Tb(),o.Ub(5,"div",5),o.Pb(6,"div",6),o.Tb(),o.Pb(7,"div",7),o.Ub(8,"div",8),o.ec(),o.Ub(9,"svg",9),o.Pb(10,"path",10),o.Tb(),o.dc(),o.Pb(11,"div",11),o.Tb(),o.Tb(),o.Ub(12,"span",12,13),o.bc("cdkObserveContent",(function(){return e._onLabelTextChange()})),o.Ub(14,"span",14),o.Qc(15,"\xa0"),o.Tb(),o.kc(16),o.Tb(),o.Tb()),2&t){var n=o.Ac(1),i=o.Ac(13);o.Db("for",e.inputId),o.Cb(2),o.Gb("mat-checkbox-inner-container-no-side-margin",!i.textContent||!i.textContent.trim()),o.Cb(1),o.mc("id",e.inputId)("required",e.required)("checked",e.checked)("disabled",e.disabled)("tabIndex",e.tabIndex),o.Db("value",e.value)("name",e.name)("aria-label",e.ariaLabel||null)("aria-labelledby",e.ariaLabelledby)("aria-checked",e._getAriaChecked())("aria-describedby",e.ariaDescribedby),o.Cb(2),o.mc("matRippleTrigger",n)("matRippleDisabled",e._isRippleDisabled())("matRippleRadius",20)("matRippleCentered",!0)("matRippleAnimation",o.qc(19,f))}},directives:[u.r,d.a],styles:["@keyframes mat-checkbox-fade-in-background{0%{opacity:0}50%{opacity:1}}@keyframes mat-checkbox-fade-out-background{0%,50%{opacity:1}100%{opacity:0}}@keyframes mat-checkbox-unchecked-checked-checkmark-path{0%,50%{stroke-dashoffset:22.910259}50%{animation-timing-function:cubic-bezier(0, 0, 0.2, 0.1)}100%{stroke-dashoffset:0}}@keyframes mat-checkbox-unchecked-indeterminate-mixedmark{0%,68.2%{transform:scaleX(0)}68.2%{animation-timing-function:cubic-bezier(0, 0, 0, 1)}100%{transform:scaleX(1)}}@keyframes mat-checkbox-checked-unchecked-checkmark-path{from{animation-timing-function:cubic-bezier(0.4, 0, 1, 1);stroke-dashoffset:0}to{stroke-dashoffset:-22.910259}}@keyframes mat-checkbox-checked-indeterminate-checkmark{from{animation-timing-function:cubic-bezier(0, 0, 0.2, 0.1);opacity:1;transform:rotate(0deg)}to{opacity:0;transform:rotate(45deg)}}@keyframes mat-checkbox-indeterminate-checked-checkmark{from{animation-timing-function:cubic-bezier(0.14, 0, 0, 1);opacity:0;transform:rotate(45deg)}to{opacity:1;transform:rotate(360deg)}}@keyframes mat-checkbox-checked-indeterminate-mixedmark{from{animation-timing-function:cubic-bezier(0, 0, 0.2, 0.1);opacity:0;transform:rotate(-45deg)}to{opacity:1;transform:rotate(0deg)}}@keyframes mat-checkbox-indeterminate-checked-mixedmark{from{animation-timing-function:cubic-bezier(0.14, 0, 0, 1);opacity:1;transform:rotate(0deg)}to{opacity:0;transform:rotate(315deg)}}@keyframes mat-checkbox-indeterminate-unchecked-mixedmark{0%{animation-timing-function:linear;opacity:1;transform:scaleX(1)}32.8%,100%{opacity:0;transform:scaleX(0)}}.mat-checkbox-background,.mat-checkbox-frame{top:0;left:0;right:0;bottom:0;position:absolute;border-radius:2px;box-sizing:border-box;pointer-events:none}.mat-checkbox{transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);cursor:pointer;-webkit-tap-highlight-color:transparent}._mat-animation-noopable.mat-checkbox{transition:none;animation:none}.mat-checkbox .mat-ripple-element:not(.mat-checkbox-persistent-ripple){opacity:.16}.mat-checkbox-layout{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:inherit;align-items:baseline;vertical-align:middle;display:inline-flex;white-space:nowrap}.mat-checkbox-label{-webkit-user-select:auto;-moz-user-select:auto;-ms-user-select:auto;user-select:auto}.mat-checkbox-inner-container{display:inline-block;height:16px;line-height:0;margin:auto;margin-right:8px;order:0;position:relative;vertical-align:middle;white-space:nowrap;width:16px;flex-shrink:0}[dir=rtl] .mat-checkbox-inner-container{margin-left:8px;margin-right:auto}.mat-checkbox-inner-container-no-side-margin{margin-left:0;margin-right:0}.mat-checkbox-frame{background-color:transparent;transition:border-color 90ms cubic-bezier(0, 0, 0.2, 0.1);border-width:2px;border-style:solid}._mat-animation-noopable .mat-checkbox-frame{transition:none}.cdk-high-contrast-active .mat-checkbox.cdk-keyboard-focused .mat-checkbox-frame{border-style:dotted}.mat-checkbox-background{align-items:center;display:inline-flex;justify-content:center;transition:background-color 90ms cubic-bezier(0, 0, 0.2, 0.1),opacity 90ms cubic-bezier(0, 0, 0.2, 0.1)}._mat-animation-noopable .mat-checkbox-background{transition:none}.cdk-high-contrast-active .mat-checkbox .mat-checkbox-background{background:none}.mat-checkbox-persistent-ripple{width:100%;height:100%;transform:none}.mat-checkbox-inner-container:hover .mat-checkbox-persistent-ripple{opacity:.04}.mat-checkbox.cdk-keyboard-focused .mat-checkbox-persistent-ripple{opacity:.12}.mat-checkbox-persistent-ripple,.mat-checkbox.mat-checkbox-disabled .mat-checkbox-inner-container:hover .mat-checkbox-persistent-ripple{opacity:0}@media(hover: none){.mat-checkbox-inner-container:hover .mat-checkbox-persistent-ripple{display:none}}.mat-checkbox-checkmark{top:0;left:0;right:0;bottom:0;position:absolute;width:100%}.mat-checkbox-checkmark-path{stroke-dashoffset:22.910259;stroke-dasharray:22.910259;stroke-width:2.1333333333px}.cdk-high-contrast-black-on-white .mat-checkbox-checkmark-path{stroke:#000 !important}.mat-checkbox-mixedmark{width:calc(100% - 6px);height:2px;opacity:0;transform:scaleX(0) rotate(0deg);border-radius:2px}.cdk-high-contrast-active .mat-checkbox-mixedmark{height:0;border-top:solid 2px;margin-top:2px}.mat-checkbox-label-before .mat-checkbox-inner-container{order:1;margin-left:8px;margin-right:auto}[dir=rtl] .mat-checkbox-label-before .mat-checkbox-inner-container{margin-left:auto;margin-right:8px}.mat-checkbox-checked .mat-checkbox-checkmark{opacity:1}.mat-checkbox-checked .mat-checkbox-checkmark-path{stroke-dashoffset:0}.mat-checkbox-checked .mat-checkbox-mixedmark{transform:scaleX(1) rotate(-45deg)}.mat-checkbox-indeterminate .mat-checkbox-checkmark{opacity:0;transform:rotate(45deg)}.mat-checkbox-indeterminate .mat-checkbox-checkmark-path{stroke-dashoffset:0}.mat-checkbox-indeterminate .mat-checkbox-mixedmark{opacity:1;transform:scaleX(1) rotate(0deg)}.mat-checkbox-unchecked .mat-checkbox-background{background-color:transparent}.mat-checkbox-disabled{cursor:default}.cdk-high-contrast-active .mat-checkbox-disabled{opacity:.5}.mat-checkbox-anim-unchecked-checked .mat-checkbox-background{animation:180ms linear 0ms mat-checkbox-fade-in-background}.mat-checkbox-anim-unchecked-checked .mat-checkbox-checkmark-path{animation:180ms linear 0ms mat-checkbox-unchecked-checked-checkmark-path}.mat-checkbox-anim-unchecked-indeterminate .mat-checkbox-background{animation:180ms linear 0ms mat-checkbox-fade-in-background}.mat-checkbox-anim-unchecked-indeterminate .mat-checkbox-mixedmark{animation:90ms linear 0ms mat-checkbox-unchecked-indeterminate-mixedmark}.mat-checkbox-anim-checked-unchecked .mat-checkbox-background{animation:180ms linear 0ms mat-checkbox-fade-out-background}.mat-checkbox-anim-checked-unchecked .mat-checkbox-checkmark-path{animation:90ms linear 0ms mat-checkbox-checked-unchecked-checkmark-path}.mat-checkbox-anim-checked-indeterminate .mat-checkbox-checkmark{animation:90ms linear 0ms mat-checkbox-checked-indeterminate-checkmark}.mat-checkbox-anim-checked-indeterminate .mat-checkbox-mixedmark{animation:90ms linear 0ms mat-checkbox-checked-indeterminate-mixedmark}.mat-checkbox-anim-indeterminate-checked .mat-checkbox-checkmark{animation:500ms linear 0ms mat-checkbox-indeterminate-checked-checkmark}.mat-checkbox-anim-indeterminate-checked .mat-checkbox-mixedmark{animation:500ms linear 0ms mat-checkbox-indeterminate-checked-mixedmark}.mat-checkbox-anim-indeterminate-unchecked .mat-checkbox-background{animation:180ms linear 0ms mat-checkbox-fade-out-background}.mat-checkbox-anim-indeterminate-unchecked .mat-checkbox-mixedmark{animation:300ms linear 0ms mat-checkbox-indeterminate-unchecked-mixedmark}.mat-checkbox-input{bottom:0;left:50%}.mat-checkbox .mat-checkbox-ripple{position:absolute;left:calc(50% - 20px);top:calc(50% - 20px);height:40px;width:40px;z-index:1;pointer-events:none}\n"],encapsulation:2,changeDetection:0}),t}(),k={provide:s.l,useExisting:Object(o.V)((function(){return T})),multi:!0},T=function(){var t=function(t){a(n,t);var e=c(n);function n(){return C(this,n),e.apply(this,arguments)}return n}(s.a);return t.\u0275fac=function(e){return S(e||t)},t.\u0275dir=o.Jb({type:t,selectors:[["mat-checkbox","required","","formControlName",""],["mat-checkbox","required","","formControl",""],["mat-checkbox","required","","ngModel",""]],features:[o.Bb([k]),o.zb]}),t}(),S=o.Wb(T),E=function(){var t=function t(){C(this,t)};return t.\u0275mod=o.Mb({type:t}),t.\u0275inj=o.Lb({factory:function(e){return new(e||t)}}),t}(),x=function(){var t=function t(){C(this,t)};return t.\u0275mod=o.Mb({type:t}),t.\u0275inj=o.Lb({factory:function(e){return new(e||t)},imports:[[u.s,u.j,d.c,E],u.j,E]}),t}()},UVER:function(t,e,n){"use strict";n.d(e,"a",(function(){return nt}));var i=n("D57K"),r=n("kZht"),o=n("O30t"),a=n("LoUP"),s=n("EZWv"),c=n("gxtV"),u=n("jIqt"),l=n("+vck"),d=n("UVqw"),h=n("IkSM"),f=n("B6Vo"),p=n("Cc4E"),b=n("zho4"),g=n("anSm"),m=n("1o0v"),v=n("yPvj"),y=n("rBBj"),_=n("chaP"),O=n("+I9z"),k=n("LbKT"),T=n("NxuZ"),S=n("WYJo"),E=n("aDqW"),x=n("An66"),P=n("rUBT"),A=n("DpwM"),I=n("rqGg");function M(t,e){1&t&&r.Pb(0,"tr",26)}function D(t,e){if(1&t){var n=r.Vb();r.Ub(0,"tr",27),r.bc("click",(function(){r.Ec(n);var t=e.$implicit;return r.fc().selectTicker.emit({symbol:t.instrument,replaceUrl:!1})})),r.Tb()}}var R=function(){return[250,100]};function j(t,e){if(1&t&&(r.Ub(0,"th",28),r.Qc(1),r.gc(2,"translate"),r.Tb()),2&t){var n=r.fc();r.mc("sbDisabled",!n.displayTooltips)("sbDelay",r.qc(5,R)),r.Cb(1),r.Sc(" ",r.hc(2,3,"COLUMN.DATE_TIME")," ")}}function L(t,e){if(1&t&&(r.Ub(0,"td",29),r.Ub(1,"span"),r.Qc(2),r.gc(3,"date"),r.Tb(),r.Ub(4,"span",30),r.Qc(5),r.gc(6,"date"),r.Tb(),r.Tb()),2&t){var n=e.$implicit;r.Cb(2),r.Rc(r.ic(3,2,n.time,"HH:mm:ss")),r.Cb(3),r.Rc(r.ic(6,5,n.time,"dd/MMM/yyyy"))}}function N(t,e){if(1&t&&(r.Ub(0,"th",31),r.Qc(1),r.gc(2,"translate"),r.Tb()),2&t){var n=r.fc();r.mc("sbDisabled",!n.displayTooltips)("sbDelay",r.qc(5,R)),r.Cb(1),r.Sc(" ",r.hc(2,3,"COLUMN.MARKET")," ")}}function U(t,e){if(1&t&&(r.Ub(0,"td",29),r.Ub(1,"span"),r.Pb(2,"market-icon",32),r.gc(3,"base"),r.Qc(4),r.gc(5,"pair"),r.Tb(),r.Ub(6,"span"),r.Qc(7),r.gc(8,"uppercase"),r.gc(9,"contractFamily"),r.gc(10,"translate"),r.gc(11,"maturityMonth"),r.Tb(),r.Tb()),2&t){var n=e.$implicit;r.Cb(2),r.mc("base",r.hc(3,4,n.instrument)),r.Cb(2),r.Sc(" ",r.hc(5,6,n.instrument)," "),r.Cb(3),r.Tc(" ",r.hc(8,8,r.hc(9,10,n.instrument))," ",r.hc(10,12,r.ic(11,14,n.instrument,"short"))," ")}}function F(t,e){if(1&t&&(r.Ub(0,"th",33),r.Qc(1),r.gc(2,"translate"),r.Tb()),2&t){var n=r.fc();r.mc("sbDisabled",!n.displayTooltips)("sbDelay",r.qc(5,R)),r.Cb(1),r.Sc(" ",r.hc(2,3,"COLUMN.TRIGGER")," ")}}function B(t,e){if(1&t&&(r.Ub(0,"td",34),r.Qc(1),r.gc(2,"titlecase"),r.Ub(3,"span",35),r.Qc(4),r.gc(5,"sato"),r.Tb(),r.Tb()),2&t){var n=e.$implicit,i=r.fc();r.Cb(1),r.Tc(" ",r.hc(2,3,n.triggerSignal)," ",i.getTriggerSign(n)," "),r.Cb(3),r.Sc(" ",r.ic(5,5,n.stop_price,n)," ")}}function z(t,e){if(1&t&&(r.Ub(0,"th",36),r.Qc(1),r.gc(2,"translate"),r.Tb()),2&t){var n=r.fc();r.mc("sbDisabled",!n.displayTooltips)("sbDelay",r.qc(5,R)),r.Cb(1),r.Sc(" ",r.hc(2,3,"COLUMN.TYPE")," ")}}function V(t,e){if(1&t&&(r.Ub(0,"td",34),r.Qc(1),r.gc(2,"titlecase"),r.Tb()),2&t){var n=e.$implicit;r.Cb(1),r.Sc(" ",r.hc(2,1,n.type.replace("_"," "))," ")}}function H(t,e){if(1&t&&(r.Ub(0,"th",37),r.Qc(1),r.gc(2,"translate"),r.Tb()),2&t){var n=r.fc();r.mc("sbDisabled",!n.displayTooltips)("sbDelay",r.qc(5,R)),r.Cb(1),r.Sc(" ",r.hc(2,3,"COLUMN.SIDE")," ")}}function q(t,e){if(1&t&&(r.Ub(0,"td",34),r.Ub(1,"strong",38),r.Qc(2),r.gc(3,"translate"),r.Tb(),r.Tb()),2&t){var n=e.$implicit,i=r.fc();r.Cb(1),r.mc("pnlBool",0===n.direction),r.Cb(1),r.Sc(" ",r.hc(3,2,i.getDirection(n))," ")}}function $(t,e){if(1&t&&(r.Ub(0,"th",39),r.Qc(1),r.gc(2,"translate"),r.Tb()),2&t){var n=r.fc();r.mc("sbDisabled",!n.displayTooltips)("sbDelay",r.qc(5,R)),r.Cb(1),r.Sc(" ",r.hc(2,3,"COLUMN.PRICE")," ")}}function Q(t,e){if(1&t&&(r.Ub(0,"td",29),r.Ub(1,"span",40),r.Qc(2),r.gc(3,"sato"),r.gc(4,"translate"),r.Tb(),r.Ub(5,"span",30),r.Qc(6),r.gc(7,"quote"),r.Tb(),r.Tb()),2&t){var n=e.$implicit;r.Cb(2),r.Sc(" ",n.limit_price?r.ic(3,2,n.limit_price,n):r.hc(4,5,"LABEL.MARKET")," "),r.Cb(4),r.Rc(n.limit_price?r.hc(7,7,n.instrument):null)}}function W(t,e){if(1&t&&(r.Ub(0,"th",41),r.Qc(1),r.gc(2,"translate"),r.Tb()),2&t){var n=r.fc();r.mc("sbDisabled",!n.displayTooltips)("sbDelay",r.qc(5,R)),r.Cb(1),r.Sc(" ",r.hc(2,3,"COLUMN.SIZE")," ")}}function G(t,e){if(1&t&&(r.Ub(0,"td",42),r.Pb(1,"ghost-trail",43),r.Ub(2,"span",30),r.Qc(3),r.gc(4,"asset"),r.Tb(),r.Tb()),2&t){var n=e.$implicit;r.Cb(1),r.nc("content",n.displayQty),r.mc("showZeros",!1),r.Cb(2),r.Rc(r.hc(4,3,n.tradingDisplayAsset))}}function Y(t,e){if(1&t&&(r.Ub(0,"th",44),r.Qc(1),r.gc(2,"translate"),r.Tb()),2&t){var n=r.fc();r.mc("sbDisabled",!n.displayTooltips)("sbDelay",r.qc(5,R)),r.Cb(1),r.Sc(" ",r.hc(2,3,"BUTTON.REDUCE_ONLY")," ")}}function K(t,e){if(1&t&&(r.Ub(0,"td",45),r.Qc(1),r.Tb()),2&t){var n=e.$implicit;r.mc("pnl",n.reduce_only),r.Cb(1),r.Sc(" ",n.reduce_only," ")}}function Z(t,e){if(1&t){var n=r.Vb();r.Ub(0,"th",46),r.bc("click",(function(){return r.Ec(n),r.fc().cancelAllOrders.emit()})),r.Pb(1,"fa-icon",47),r.Ub(2,"p"),r.Qc(3),r.gc(4,"translate"),r.Tb(),r.Tb()}2&t&&(r.Cb(3),r.Rc(r.hc(4,1,"BUTTON.CANCEL_ALL_ORDERS")))}function X(t,e){if(1&t){var n=r.Vb();r.Ub(0,"td",34),r.Ub(1,"div",48),r.bc("click",(function(t){r.Ec(n);var i=e.$implicit;return r.fc().viewDetailed.emit({order:i}),t.stopPropagation()})),r.Pb(2,"fa-icon",49),r.Tb(),r.Ub(3,"div",50),r.bc("click",(function(t){r.Ec(n);var i=e.$implicit;return r.fc().editOrder.emit({order:i}),t.stopPropagation()})),r.Pb(4,"fa-icon",51),r.gc(5,"translate"),r.Ub(6,"p"),r.Qc(7),r.gc(8,"translate"),r.Tb(),r.Tb(),r.Ub(9,"div",52),r.bc("click",(function(t){r.Ec(n);var i=e.$implicit;return r.fc().cancelOrder.emit({id:i.order_id}),t.stopPropagation()})),r.Pb(10,"fa-icon",53),r.gc(11,"translate"),r.Ub(12,"p"),r.Qc(13),r.gc(14,"translate"),r.Tb(),r.Tb(),r.Tb()}2&t&&(r.Cb(4),r.mc("matTooltip",r.hc(5,4,"BUTTON.EDIT")),r.Cb(3),r.Rc(r.hc(8,6,"BUTTON.EDIT")),r.Cb(3),r.mc("matTooltip",r.hc(11,8,"BUTTON.CANCEL")),r.Cb(3),r.Rc(r.hc(14,10,"BUTTON.CANCEL")))}var J=function(){return{small:100,medium:400,large:800}},tt=function(){return[10,20,50]},et=function(t,e){var n,i={symbol:t.instrument,price:null!==(n=t.limit_price)&&void 0!==n?n:0,trigger_when:t.stop_price,filled:t.qty,side:t.direction};return e in i?i[e]:t[e]},nt=function(){var t=function(){function t(){C(this,t),this.tableData=new o.k([]),this.tableColumns=["time","symbol","trigger_when","type","side","qty","price","reduce_only","order_actions"],this.selectTicker=new r.o,this.editOrder=new r.o,this.cancelOrder=new r.o,this.cancelAllOrders=new r.o,this.viewDetailed=new r.o}return w(t,[{key:"ngOnInit",value:function(){this.tableData.sortingDataAccessor=et,this.tableData.paginator=this.paginator}},{key:"ngAfterViewInit",value:function(){var t=this;this.tableSort.changes.pipe(Object(u.a)(this.tableSort),Object(c.b)(this)).subscribe((function(e){e.first&&(t.tableData.sort=e.first)}))}},{key:"trackByOrderId",value:function(t,e){return e.order_id}},{key:"getTriggerSign",value:function(t){return"stop"===t.type==(t.direction===l.a.Buy)?"\u2265":"\u2264"}},{key:"getDirection",value:function(t){return t.direction===l.a.Sell?"SIDE.SELL":"SIDE.BUY"}},{key:"orders",set:function(t){this.tableData.data=t.valueSeq().toArray()}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=r.Ib({type:t,selectors:[["trigger-orders-desktop"]],viewQuery:function(t,e){var n;1&t&&(r.Jc(s.a,!0),r.Wc(a.a,!0)),2&t&&(r.zc(n=r.cc())&&(e.paginator=n.first),r.zc(n=r.cc())&&(e.tableSort=n))},inputs:{orders:"orders",displayTooltips:"displayTooltips"},outputs:{selectTicker:"selectTicker",editOrder:"editOrder",cancelOrder:"cancelOrder",cancelAllOrders:"cancelAllOrders",viewDetailed:"viewDetailed"},decls:31,vars:10,consts:[["breakpoint","","mat-table","","matSort","",3,"breakpoints","dataSource","trackBy"],["mat-header-row","",4,"matHeaderRowDef","matHeaderRowDefSticky"],["mat-row","",3,"click",4,"matRowDef","matRowDefColumns"],["matColumnDef","time"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.TRIGGER_ORDERS.DATE",3,"sbDisabled","sbDelay",4,"matHeaderCellDef"],["class","block-cell","mat-cell","","body","",4,"matCellDef"],["matColumnDef","symbol"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.TRIGGER_ORDERS.MARKET",3,"sbDisabled","sbDelay",4,"matHeaderCellDef"],["matColumnDef","trigger_when"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.TRIGGER_ORDERS.SIGNAL",3,"sbDisabled","sbDelay",4,"matHeaderCellDef"],["mat-cell","","body","",4,"matCellDef"],["matColumnDef","type"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.TRIGGER_ORDERS.TYPE",3,"sbDisabled","sbDelay",4,"matHeaderCellDef"],["matColumnDef","side"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.TRIGGER_ORDERS.SIDE",3,"sbDisabled","sbDelay",4,"matHeaderCellDef"],["matColumnDef","price"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.TRIGGER_ORDERS.PRICE",3,"sbDisabled","sbDelay",4,"matHeaderCellDef"],["matColumnDef","qty"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.TRIGGER_ORDERS.SIZE",3,"sbDisabled","sbDelay",4,"matHeaderCellDef"],["mat-cell","","body","","mono","",4,"matCellDef"],["matColumnDef","reduce_only"],["mat-header-cell","","tooltip","","sbTooltip","TOOLTIP.TRIGGER_ORDERS.REDUCE_ONLY",3,"sbDisabled","sbDelay",4,"matHeaderCellDef"],["mat-cell","","body","",3,"pnl",4,"matCellDef"],["matColumnDef","order_actions"],["class","cancel-all-button","body","","mat-header-cell","",3,"click",4,"matHeaderCellDef"],[3,"pageSize","pageSizeOptions"],["mat-header-row",""],["mat-row","",3,"click"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.TRIGGER_ORDERS.DATE",3,"sbDisabled","sbDelay"],["mat-cell","","body","",1,"block-cell"],["ghost",""],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.TRIGGER_ORDERS.MARKET",3,"sbDisabled","sbDelay"],[3,"base"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.TRIGGER_ORDERS.SIGNAL",3,"sbDisabled","sbDelay"],["mat-cell","","body",""],[1,"global__text--mono"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.TRIGGER_ORDERS.TYPE",3,"sbDisabled","sbDelay"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.TRIGGER_ORDERS.SIDE",3,"sbDisabled","sbDelay"],[3,"pnlBool"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.TRIGGER_ORDERS.PRICE",3,"sbDisabled","sbDelay"],["mono",""],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.TRIGGER_ORDERS.SIZE",3,"sbDisabled","sbDelay"],["mat-cell","","body","","mono",""],[3,"content","showZeros"],["mat-header-cell","","tooltip","","sbTooltip","TOOLTIP.TRIGGER_ORDERS.REDUCE_ONLY",3,"sbDisabled","sbDelay"],["mat-cell","","body","",3,"pnl"],["body","","mat-header-cell","",1,"cancel-all-button",3,"click"],["icon","close","size","lg"],[1,"copy-button",3,"click"],["icon","file","size","lg"],[1,"edit-button",3,"click"],["primary","","icon","edit","size","lg",3,"matTooltip"],[1,"cancel-button",3,"click"],["icon","close","size","lg",3,"matTooltip"]],template:function(t,e){1&t&&(r.Ub(0,"table",0),r.Oc(1,M,1,0,"tr",1),r.Oc(2,D,1,0,"tr",2),r.Sb(3,3),r.Oc(4,j,3,6,"th",4),r.Oc(5,L,7,8,"td",5),r.Rb(),r.Sb(6,6),r.Oc(7,N,3,6,"th",7),r.Oc(8,U,12,17,"td",5),r.Rb(),r.Sb(9,8),r.Oc(10,F,3,6,"th",9),r.Oc(11,B,6,8,"td",10),r.Rb(),r.Sb(12,11),r.Oc(13,z,3,6,"th",12),r.Oc(14,V,3,3,"td",10),r.Rb(),r.Sb(15,13),r.Oc(16,H,3,6,"th",14),r.Oc(17,q,4,4,"td",10),r.Rb(),r.Sb(18,15),r.Oc(19,$,3,6,"th",16),r.Oc(20,Q,8,9,"td",5),r.Rb(),r.Sb(21,17),r.Oc(22,W,3,6,"th",18),r.Oc(23,G,5,5,"td",19),r.Rb(),r.Sb(24,20),r.Oc(25,Y,3,6,"th",21),r.Oc(26,K,2,2,"td",22),r.Rb(),r.Sb(27,23),r.Oc(28,Z,5,3,"th",24),r.Oc(29,X,15,12,"td",10),r.Rb(),r.Tb(),r.Pb(30,"mat-paginator",25)),2&t&&(r.mc("breakpoints",r.qc(8,J))("dataSource",e.tableData)("trackBy",e.trackByOrderId),r.Cb(1),r.mc("matHeaderRowDef",e.tableColumns)("matHeaderRowDefSticky",!0),r.Cb(1),r.mc("matRowDefColumns",e.tableColumns),r.Cb(28),r.mc("pageSize",20)("pageSizeOptions",r.qc(9,tt)))},directives:[o.j,d.a,a.a,o.g,o.i,o.c,o.e,o.b,s.a,o.f,o.h,o.d,a.b,h.a,f.a,p.a,b.a,o.a,g.a,m.a,v.a,y.a,_.a,O.a,k.a,T.b,S.a],pipes:[E.d,x.e,P.a,P.e,x.x,P.c,P.d,x.w,A.c,P.f,I.a],styles:["market-icon[_ngcontent-%COMP%]{font-size:20px}table[_ngcontent-%COMP%] .mat-row[_ngcontent-%COMP%]{height:calc(var(--table-row-height) + var(--spacing))!important}table[_ngcontent-%COMP%] .mat-cell[_ngcontent-%COMP%]:last-of-type, table[_ngcontent-%COMP%] .mat-header-cell[_ngcontent-%COMP%]:last-of-type{text-align:right}.block-cell[_ngcontent-%COMP%] > span[_ngcontent-%COMP%]{display:block;line-height:1.25em}.actions-header[_ngcontent-%COMP%]{cursor:pointer}.actions-header[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{display:inline}.actions-header[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{color:var(--warn-colour);margin-right:var(--spacing-s)}.actions-header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{color:var(--warn-colour);text-transform:capitalize!important}.cancel-button[_ngcontent-%COMP%], .copy-button[_ngcontent-%COMP%], .edit-button[_ngcontent-%COMP%], .info-button[_ngcontent-%COMP%], .limit-button[_ngcontent-%COMP%], .market-button[_ngcontent-%COMP%]{cursor:pointer;display:inline-block}.cancel-button[_ngcontent-%COMP%] > *[_ngcontent-%COMP%], .copy-button[_ngcontent-%COMP%] > *[_ngcontent-%COMP%], .edit-button[_ngcontent-%COMP%] > *[_ngcontent-%COMP%], .info-button[_ngcontent-%COMP%] > *[_ngcontent-%COMP%], .limit-button[_ngcontent-%COMP%] > *[_ngcontent-%COMP%], .market-button[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{display:inline}.cancel-button[_ngcontent-%COMP%] p[_ngcontent-%COMP%], .copy-button[_ngcontent-%COMP%] p[_ngcontent-%COMP%], .edit-button[_ngcontent-%COMP%] p[_ngcontent-%COMP%], .info-button[_ngcontent-%COMP%] p[_ngcontent-%COMP%], .limit-button[_ngcontent-%COMP%] p[_ngcontent-%COMP%], .market-button[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{padding-left:var(--spacing-s)}.copy-button[_ngcontent-%COMP%], .edit-button[_ngcontent-%COMP%], .info-button[_ngcontent-%COMP%], .limit-button[_ngcontent-%COMP%], .market-button[_ngcontent-%COMP%]{margin-right:var(--spacing)}.copy-button[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%], .edit-button[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%], .info-button[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%], .limit-button[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%], .market-button[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{color:var(--brand)}.cancel-button[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{color:var(--warn-colour)}.cancel-all-button[_ngcontent-%COMP%]{cursor:pointer}.cancel-all-button[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{display:inline}.cancel-all-button[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{color:var(--warn-colour);margin-right:var(--spacing-s)}.cancel-all-button[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{color:var(--warn-colour);text-transform:capitalize!important}table[breakpoint=medium][_ngcontent-%COMP%] .mat-column-reduce_only[_ngcontent-%COMP%]{display:none}table[breakpoint=medium][_ngcontent-%COMP%] .mat-column-trigger_when[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{display:block}table[breakpoint=medium][_ngcontent-%COMP%] .cancel-button[_ngcontent-%COMP%] p[_ngcontent-%COMP%], table[breakpoint=medium][_ngcontent-%COMP%] .copy-button[_ngcontent-%COMP%] p[_ngcontent-%COMP%], table[breakpoint=medium][_ngcontent-%COMP%] .edit-button[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{display:none}.mat-column-reduce_only[_ngcontent-%COMP%]{text-align:right;text-transform:capitalize;padding-right:var(--spacing)}"],changeDetection:0}),t=Object(i.d)([Object(c.a)()],t)}()},UVqw:function(t,e,n){"use strict";n.d(e,"a",(function(){return o}));var i=n("LaGA"),r=n("kZht"),o=function(){var t=function(){function t(e,n){var r=this;C(this,t),this.element=e,this.renderer=n,this.breakpoints={small:100,medium:400,large:500},this.observer=new i.a((function(){return r.determineBreakpoint()}))}return w(t,[{key:"ngOnInit",value:function(){this.observer.observe(this.element.nativeElement)}},{key:"ngOnDestroy",value:function(){this.observer.disconnect()}},{key:"determineBreakpoint",value:function(){var t=this.element.nativeElement,e=t.offsetWidth;this.renderer.removeAttribute(t,"breakpoint");var n,i=p(Object.entries(this.breakpoints).reverse());try{for(i.s();!(n=i.n()).done;){var r=m(n.value,2),o=r[0];if(e>=r[1]){this.renderer.setAttribute(t,"breakpoint",o);break}}}catch(a){i.e(a)}finally{i.f()}}}]),t}();return t.\u0275fac=function(e){return new(e||t)(r.Ob(r.l),r.Ob(r.G))},t.\u0275dir=r.Jb({type:t,selectors:[["","breakpoint",""]],inputs:{breakpoints:"breakpoints"}}),t}()},UZ8P:function(t,e,n){"use strict";(function(t){n.d(e,"a",(function(){return V}));var i=n("D57K"),r=n("An66"),o=n("zqNl"),a=n("C05f"),s=n("KTx3"),c=n("VvXq"),u=n("gxtV"),l=n("YtkY"),d=n("prE9"),h=n("8j5Y"),f=n("Wg7D"),p=n("mWib"),b=n("LaGA"),g=n("KQpv"),m=n.n(g),v=n("bCr7"),y=n("/sr6"),_=n("IncQ"),O=n("sXtk"),k=n("NloN"),T=n("ylpo"),S=n("bjK4"),E=n("rxqU"),x=n("i67J"),P=n("lx5p"),A=n("qAYy"),I=n("YyhG"),M=n("kZht"),D=n("1etq"),R=n("B6Vo"),j=n("zho4"),L=n("Cc4E"),N=n("NxuZ"),U=n("aDqW"),F=["canvas"],B=function(){return[1e3,0]},z=m()("app:depth-chart"),V=function(){var e=function(){function e(n,i,r,s){C(this,e),this.el=n,this.store=i,this.env=r,this.document=s,this.workerInner=new Worker(t,{type:void 0,name:"depth-chart"}),this.worker=new _.a(this.workerInner),this.span$=new a.a(Object(k.b)(T.f,.01)),this.ticker$=this.store.pipe(Object(o.m)(A.p)),this.theme$=this.store.pipe(Object(o.m)(S.q)),this.noobtips$=this.store.pipe(Object(o.m)(E.y)),this.userPairOrders$=this.store.pipe(Object(o.m)(I.f),Object(l.a)((function(t){return t.valueSeq().map(Object(P.F)("limit_price")).filter(P.m).toArray()}))),this.tradingUnits$=this.store.pipe(Object(o.m)(E.r),Object(l.a)(Object(P.F)("trading"))),this.observer=new b.a(this.tryCanvasResize.bind(this))}return w(e,[{key:"ngOnInit",value:function(){var t=this;this.observer.observe(this.el.nativeElement);var e=this.canvas.nativeElement;e.width=this.el.nativeElement.offsetWidth,e.height=this.el.nativeElement.offsetHeight,this.span$.pipe(Object(u.b)(this)).subscribe((function(e){return t.worker.dispatch("span",e)})),this.worker.on("ready",(function(){z("worker ready");var n={wsUrl:t.env.urls.websocket,dimensions:Object(v.b)(e.width,e.height),span:t.span$.value,debug:m.a.enabled("app:worker:depth-chart")};if(e.transferControlToOffscreen){var i=e.transferControlToOffscreen();t.worker.dispatch("init",Object.assign(Object.assign({},n),{canvas:i}),[i])}else{var r=new y.a,o=e.getContext("2d");t.worker.dispatch("init",Object.assign(Object.assign({},n),{canvas:void 0})),t.worker.on("paint",(function(t){var e=t.drawCalls;r.replaceDrawCalls(e),r.flushTo(o)}))}t.ticker$.pipe(Object(x.g)(),Object(u.b)(t)).subscribe((function(e){var n,i,r=e.product_id,o=null!==(i=null===(n=e.numericPrecision)||void 0===n?void 0:n.short)&&void 0!==i?i:2;t.worker.dispatch("market-change",{symbol:r,precision:o,exchangeRate:e.markPrice})})),setTimeout(t.tryCanvasResize.bind(t),10)})),Object(s.a)(this.canvas.nativeElement,"mousemove").pipe(Object(u.b)(this),Object(d.a)(0,c.a)).subscribe((function(e){return t.worker.dispatch("mouse-move",[e.timeStamp,Object(v.c)(e.offsetX||e.layerX||0,e.offsetY||e.layerY||0)])})),Object(s.a)(this.canvas.nativeElement,"mouseleave").pipe(Object(u.b)(this)).subscribe((function(e){return t.worker.dispatch("mouse-leave",e.timeStamp)}));var n=function(){t.worker.dispatch("visibility-change",t.document.visibilityState)};n(),Object(s.a)(this.document,"visibilitychange").pipe(Object(u.b)(this)).subscribe(n),Object(s.a)(this.el.nativeElement,"wheel").pipe(Object(h.a)((function(t){return t.preventDefault()})),Object(f.a)(0,c.a),Object(u.b)(this)).subscribe((function(e){t.alterSpan(e.deltaY)})),this.span$.pipe(Object(p.a)(500),Object(u.b)(this)).subscribe((function(t){return Object(k.c)(T.f,t)})),this.theme$.pipe(Object(u.b)(this)).subscribe((function(e){return t.worker.dispatch("theme",e)})),this.tradingUnits$.pipe(Object(u.b)(this)).subscribe((function(e){return t.worker.dispatch("trading-units-change",e)})),this.userPairOrders$.pipe(Object(u.b)(this)).subscribe((function(e){return t.worker.dispatch("pair-orders",e)}))}},{key:"ngOnDestroy",value:function(){this.worker.dispatch("stop",void 0),this.observer.disconnect()}},{key:"alterSpan",value:function(t){var e=Math.pow(t>0?.99:1/.99,Math.abs(t)),n=Object(y.b)(this.span$.value*e),i=Number(n.toPrecision(4));this.span$.next(i)}},{key:"tryCanvasResize",value:function(){var t=this.el.nativeElement,e=t.offsetWidth,n=t.offsetHeight,i=this.canvas.nativeElement;i.transferControlToOffscreen||(i.width=e,i.height=n),this.worker.dispatch("resize",Object(v.b)(e,n))}}]),e}();return e.\u0275fac=function(t){return new(t||e)(M.Ob(M.l),M.Ob(o.b),M.Ob(O.a),M.Ob(r.d))},e.\u0275cmp=M.Ib({type:e,selectors:[["depth-chart"]],viewQuery:function(t,e){var n;1&t&&M.Jc(F,!0),2&t&&M.zc(n=M.cc())&&(e.canvas=n.first)},decls:11,vars:18,consts:[["canvas",""],["subheading","","sbTooltip","TOOLTIP.DEPTH_CHART_SCROLL",1,"span",3,"sbDelay","sbDisabled"],["icon","plus","size","lg",3,"click"],["icon","minus","size","lg",3,"click"]],template:function(t,e){1&t&&(M.Pb(0,"canvas",null,0),M.Ub(2,"div",1),M.gc(3,"async"),M.Qc(4),M.gc(5,"translate"),M.Ub(6,"fa-icon",2),M.bc("click",(function(){return e.alterSpan(5)})),M.Tb(),M.Ub(7,"fa-icon",3),M.bc("click",(function(){return e.alterSpan(-5)})),M.Tb(),M.Qc(8),M.gc(9,"percent"),M.gc(10,"async"),M.Tb()),2&t&&(M.Lc("width",100,"%")("height",100,"%"),M.Cb(2),M.mc("sbDelay",M.qc(17,B))("sbDisabled",!1===M.hc(3,8,e.noobtips$)),M.Cb(2),M.Sc(" ",M.hc(5,10,"LABEL.SPAN")," "),M.Cb(4),M.Sc(" ",M.ic(9,12,M.hc(10,15,e.span$),"1.3-3"),"\n"))},directives:[D.a,R.a,j.a,L.a,N.b],pipes:[r.b,U.d,r.u],styles:["[_nghost-%COMP%]{display:grid;overflow:hidden;height:100%}.span[_ngcontent-%COMP%]{margin:1em;position:absolute;z-index:2;-webkit-user-select:none;-moz-user-select:none;user-select:none}.span[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{cursor:pointer}"],changeDetection:0}),e=Object(i.d)([Object(u.a)()],e)}()}).call(this,n("71O4"))},UbJG:function(t,e,n){"use strict";n.d(e,"g",(function(){return _})),n.d(e,"f",(function(){return k})),n.d(e,"b",(function(){return w})),n.d(e,"d",(function(){return C})),n.d(e,"a",(function(){return T})),n.d(e,"c",(function(){return S})),n.d(e,"h",(function(){return E})),n.d(e,"e",(function(){return x}));var i=n("zqNl"),r=n("og7C"),o=n("VmIW"),a=n("p5wL"),s=n("lx5p"),c=n("YzTY"),u=n("yN5A"),l=n("NloN"),d=n("ylpo");function h(t,e,n){var i=Object(a.b)(e,t,"workspaces");return Object(a.b)(n,i,"activeWorkspace")}var f,p,g,v,y=Object(i.i)((f=Object(c.e)(),p=Object(l.b)(d.v,[f]),g=Object(l.b)(d.a,f.id),v=p.map(Object(s.F)("id")).includes(g)?g:p[0].id,{workspaces:p,activeWorkspace:v,draggedComponent:Object(o.None)()}),Object(i.k)(u.l,(function(t,e){var n=e.workspaces;return Object(a.b)(n,t,"workspaces")})),Object(i.k)(u.i,(function(t){var e=Object(c.e)();return h(t,[e],e.id)})),Object(i.k)(u.b,(function(t,e){var n=e.workspace;return h(t,[].concat(b(t.workspaces),[n]),n.id)})),Object(i.k)(u.c,(function(t,e){var n=e.config,i=Object(c.c)(n);return h(t,[].concat(b(t.workspaces),[i]),i.id)})),Object(i.k)(u.h,(function(t,e){var n=e.id,i=e.name,r=Object(c.n)(n,i)(t.workspaces);return Object(a.b)(r,t,"workspaces")})),Object(i.k)(u.e,(function(t,e){var n=e.id;if(t.workspaces.length<=1)return t;var i=Object(c.l)(n)(t.workspaces),r=i.map(Object(s.F)("id")).includes(t.activeWorkspace)?t.activeWorkspace:i[0].id;return h(t,i,r)})),Object(i.k)(u.j,(function(t,e){var n=e.id;return Object(a.b)(n,t,"activeWorkspace")})),Object(i.k)(u.a,(function(t,e){var n=e.component,i=e.location,r=t.workspaces,o=t.activeWorkspace,s=Object(c.j)(n,i,o)(r);return Object(a.b)(s,t,"workspaces")})),Object(i.k)(u.g,(function(t,e){var n=e.component,i=e.location,r=e.position,o=t.workspaces,u=t.activeWorkspace,l=Object(s.E)(Object(c.k)(n,u),Object(c.j)(n,i,u,r))(o);return Object(a.b)(l,t,"workspaces")})),Object(i.k)(u.d,(function(t,e){var n=e.component,i=t.workspaces,r=t.activeWorkspace,o=Object(c.k)(n,r)(i);return Object(a.b)(o,t,"workspaces")})),Object(i.k)(u.f,(function(t,e){var n=e.component,i=e.location,r=t.workspaces,o=t.activeWorkspace,s=Object(c.m)(n,i,o)(r);return Object(a.b)(s,t,"workspaces")})),Object(i.k)(u.k,(function(t,e){var n=e.tab;return Object(a.b)(n,t,"draggedComponent")})));function _(t,e){return y(t,e)}var O=Object(i.h)("workspace"),k=Object(i.j)(O,(function(t){return t.workspaces})),w=Object(i.j)(O,(function(t){return t.activeWorkspace})),C=Object(i.j)(O,(function(t){return t.draggedComponent})),T=Object(i.j)(O,(function(t){var e=t.workspaces,n=t.activeWorkspace;return Object(s.u)(e,(function(t){return t.id===n}))})),S=Object(i.j)(T,(function(t){return t.map(Object(s.F)("name")).orSome("")})),E=Object(i.j)(C,T,(function(t,e){return Object(s.w)(t,e).map((function(t){var e=m(t,2),n=e[0],i=e[1],o=c.i[n],a=Object.keys(i.panels),s=Object(c.b)(o);return Object(r.f)(a).filter((function(t){return s(i.panels[t].size)}))})).orSome(Object(r.f)())})),x=Object(i.j)(T,(function(t){return t.map((function(t){return Object(r.f)(Object.values(t.panels).filter(s.m).flatMap((function(t){return t.components})))})).orSome(Object(r.f)())}))},UdWo:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("oCyE"),r=n("vI0g"),o=n("nmFE"),a=n("Zg5S"),s=n("o7Rf"),c=n("sPys");e.default=function(){function t(){this.rsDecoder=new i.default(r.default.DATA_MATRIX_FIELD_256)}return t.prototype.decode=function(t){for(var e=new o.default(t),n=e.getVersion(),i=e.readCodewords(),r=a.default.getDataBlocks(i,n),c=0,u=0,l=r;u8)throw new Error("Invalid hex color: "+t);3!==e.length&&4!==e.length||(e=Array.prototype.concat.apply([],e.map((function(t){return[t,t]})))),6===e.length&&e.push("F","F");var n=parseInt(e.join(""),16);return{r:n>>24&255,g:n>>16&255,b:n>>8&255,a:255&n,hex:"#"+e.slice(0,6).join("")}}e.getOptions=function(t){t||(t={}),t.color||(t.color={});var e=t.width&&t.width>=21?t.width:void 0;return{width:e,scale:e?4:t.scale||4,margin:null==t.margin||t.margin<0?4:t.margin,color:{dark:n(t.color.dark||"#000000ff"),light:n(t.color.light||"#ffffffff")},type:t.type,rendererOpts:t.rendererOpts||{}}},e.getScale=function(t,e){return e.width&&e.width>=t+2*e.margin?e.width/(t+2*e.margin):e.scale},e.getImageWidth=function(t,n){var i=e.getScale(t,n);return Math.floor((t+2*n.margin)*i)},e.qrToImageData=function(t,n,i){for(var r=n.modules.size,o=n.modules.data,a=e.getScale(r,i),s=Math.floor((r+2*i.margin)*a),c=i.margin*a,u=[i.color.light,i.color.dark],l=0;l=c&&d>=c&&l div[_ngcontent-%COMP%]{display:grid;background-color:var(--background-colour);border-radius:4px;box-sizing:border-box;border:1px solid var(--border-colour);padding:var(--spacing);margin-bottom:var(--spacing);height:106px}@media (min-width:1367px) and (max-width:1440px){.layout-container[_ngcontent-%COMP%] > div[_ngcontent-%COMP%]{height:calc(106px - 20px)}}@media (min-width:1025px) and (max-width:1366px){.layout-container[_ngcontent-%COMP%] > div[_ngcontent-%COMP%]{height:calc(106px - 20px)}}.layout-container[_ngcontent-%COMP%] > div[_ngcontent-%COMP%] *[_ngcontent-%COMP%]{background-color:var(--form-input-colour);border:1px solid var(--border-colour);border-radius:2px}.layout-container[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{text-align:center;padding:var(--spacing) 0}.layout-container.selected[_ngcontent-%COMP%], .layout-container[_ngcontent-%COMP%]:hover{background:var(--brand)}.layout-container.selected[_ngcontent-%COMP%] p[_ngcontent-%COMP%], .layout-container[_ngcontent-%COMP%]:hover p[_ngcontent-%COMP%]{color:var(--white)}.buttons[_ngcontent-%COMP%]{justify-content:flex-end}.buttons[_ngcontent-%COMP%] *[_ngcontent-%COMP%]{margin-left:var(--spacing)}.default[_ngcontent-%COMP%]{grid-gap:var(--spacing);grid-template:"left topCenter topRight" .6fr "left bottomCenter bottomRight" .4fr/.2fr .6fr .2fr}.default[_ngcontent-%COMP%] .left[_ngcontent-%COMP%]{grid-area:left}.default[_ngcontent-%COMP%] .topCenter[_ngcontent-%COMP%]{grid-area:topCenter}.default[_ngcontent-%COMP%] .bottomCenter[_ngcontent-%COMP%]{grid-area:bottomCenter}.default[_ngcontent-%COMP%] .topRight[_ngcontent-%COMP%]{grid-area:topRight}.default[_ngcontent-%COMP%] .bottomRight[_ngcontent-%COMP%]{grid-area:bottomRight}.single[_ngcontent-%COMP%]{grid-template-columns:1fr;grid-template-rows:1fr}.double[_ngcontent-%COMP%]{grid-template-columns:1fr 1fr}.double[_ngcontent-%COMP%], .triple[_ngcontent-%COMP%]{grid-gap:var(--spacing)}.triple[_ngcontent-%COMP%]{grid-template:"topLeft right" 1fr "bottomLeft right" 1fr/1fr 1fr}.triple[_ngcontent-%COMP%] .topLeft[_ngcontent-%COMP%]{grid-area:topLeft}.triple[_ngcontent-%COMP%] .bottomLeft[_ngcontent-%COMP%]{grid-area:bottomLeft}.triple[_ngcontent-%COMP%] .right[_ngcontent-%COMP%]{grid-area:right}.quad[_ngcontent-%COMP%]{grid-template-columns:1fr 1fr;grid-template-rows:1fr 1fr}.layout1[_ngcontent-%COMP%], .quad[_ngcontent-%COMP%]{grid-gap:var(--spacing)}.layout1[_ngcontent-%COMP%]{grid-template:"left topRight" 1fr "left bottomRight" 1fr/.6fr .4fr}.layout1[_ngcontent-%COMP%] .left[_ngcontent-%COMP%]{grid-area:left}.layout1[_ngcontent-%COMP%] .topRight[_ngcontent-%COMP%]{grid-area:topRight}.layout1[_ngcontent-%COMP%] .bottomRight[_ngcontent-%COMP%]{grid-area:bottomRight}.layout2[_ngcontent-%COMP%]{grid-template:"topLeft center right" 1fr "bottomLeft center right" 1fr/1fr .5fr .5fr;grid-gap:var(--spacing)}.layout2[_ngcontent-%COMP%] .left[_ngcontent-%COMP%]{grid-area:left}.layout2[_ngcontent-%COMP%] .bottomLeft[_ngcontent-%COMP%]{grid-area:bottomLeft}.layout2[_ngcontent-%COMP%] .center[_ngcontent-%COMP%]{grid-area:center}.layout2[_ngcontent-%COMP%] .right[_ngcontent-%COMP%]{grid-area:right}.layout3[_ngcontent-%COMP%]{grid-template:"topLeft topRight" 1fr "bottomLeft bottomRight" 1fr/.6fr .4fr;grid-gap:var(--spacing)}.layout3[_ngcontent-%COMP%] .topLeft[_ngcontent-%COMP%]{grid-area:topLeft}.layout3[_ngcontent-%COMP%] .bottomLeft[_ngcontent-%COMP%]{grid-area:bottomLeft}.layout3[_ngcontent-%COMP%] .topRight[_ngcontent-%COMP%]{grid-area:topRight}.layout3[_ngcontent-%COMP%] .bottomRight[_ngcontent-%COMP%]{grid-area:bottomRight}.layout4[_ngcontent-%COMP%]{grid-template:"left center right" 1fr/.25fr .5fr .25fr;grid-gap:var(--spacing)}.layout4[_ngcontent-%COMP%] .left[_ngcontent-%COMP%]{grid-area:left}.layout4[_ngcontent-%COMP%] .center[_ngcontent-%COMP%]{grid-area:center}.layout4[_ngcontent-%COMP%] .right[_ngcontent-%COMP%]{grid-area:right}.layout5[_ngcontent-%COMP%]{grid-template:"top" .6fr "bottom" .4fr/1fr;grid-gap:var(--spacing)}.layout5[_ngcontent-%COMP%] .top[_ngcontent-%COMP%]{grid-area:top}.layout5[_ngcontent-%COMP%] .bottom[_ngcontent-%COMP%]{grid-area:bottom}.layout6[_ngcontent-%COMP%]{grid-template:"topLeft topRight" .6fr "bottom bottom" .4fr/1fr 1fr;grid-gap:var(--spacing)}.layout6[_ngcontent-%COMP%] .topLeft[_ngcontent-%COMP%]{grid-area:topLeft}.layout6[_ngcontent-%COMP%] .topRight[_ngcontent-%COMP%]{grid-area:topRight}.layout6[_ngcontent-%COMP%] .bottom[_ngcontent-%COMP%]{grid-area:bottom}.layout7[_ngcontent-%COMP%]{grid-template:"top top" .6fr "bottomLeft bottomRight" .4fr/1fr 1fr;grid-gap:var(--spacing)}.layout7[_ngcontent-%COMP%] .top[_ngcontent-%COMP%]{grid-area:top}.layout7[_ngcontent-%COMP%] .bottomRight[_ngcontent-%COMP%]{grid-area:bottomRight}.layout7[_ngcontent-%COMP%] .bottomLeft[_ngcontent-%COMP%]{grid-area:bottomLeft}'],changeDetection:0}),t=Object(i.d)([Object(c.a)()],t)}()},VbQ3:function(t,e,n){"use strict";n.d(e,"a",(function(){return U})),n.d(e,"b",(function(){return B})),n.d(e,"c",(function(){return Q})),n.d(e,"d",(function(){return $})),n.d(e,"e",(function(){return H})),n.d(e,"f",(function(){return F})),n.d(e,"g",(function(){return W})),n.d(e,"h",(function(){return z}));var i=n("5XID"),r=n("kZht"),s=n("ZTXN"),u=n("ROBh"),l=n("IdLP"),d=n("KTx3"),f=n("VvXq"),b=n("vT4p"),g=n("bwdy"),v=n("9bRT"),y=n("Ohay"),_=n("prE9"),O=n("xVbo"),k=n("kuMc"),T=n("jIqt"),S=n("0Woy"),E=n("TLy2"),x=n("wqq/"),P=n("O1jd"),A=n("An66"),I=n("vE5V"),M=n("sBeF"),D=["contentWrapper"],R=["*"],j=new r.s("VIRTUAL_SCROLL_STRATEGY"),L=function(){function t(e,n,i){C(this,t),this._scrolledIndexChange=new s.b,this.scrolledIndexChange=this._scrolledIndexChange.pipe(Object(y.a)()),this._viewport=null,this._itemSize=e,this._minBufferPx=n,this._maxBufferPx=i}return w(t,[{key:"attach",value:function(t){this._viewport=t,this._updateTotalContentSize(),this._updateRenderedRange()}},{key:"detach",value:function(){this._scrolledIndexChange.complete(),this._viewport=null}},{key:"updateItemAndBufferSize",value:function(t,e,n){this._itemSize=t,this._minBufferPx=e,this._maxBufferPx=n,this._updateTotalContentSize(),this._updateRenderedRange()}},{key:"onContentScrolled",value:function(){this._updateRenderedRange()}},{key:"onDataLengthChanged",value:function(){this._updateTotalContentSize(),this._updateRenderedRange()}},{key:"onContentRendered",value:function(){}},{key:"onRenderedOffsetChanged",value:function(){}},{key:"scrollToIndex",value:function(t,e){this._viewport&&this._viewport.scrollToOffset(t*this._itemSize,e)}},{key:"_updateTotalContentSize",value:function(){this._viewport&&this._viewport.setTotalContentSize(this._viewport.getDataLength()*this._itemSize)}},{key:"_updateRenderedRange",value:function(){if(this._viewport){var t=this._viewport.getRenderedRange(),e={start:t.start,end:t.end},n=this._viewport.getViewportSize(),i=this._viewport.getDataLength(),r=this._viewport.measureScrollOffset(),o=r/this._itemSize;if(e.end>i){var a=Math.ceil(n/this._itemSize),s=Math.max(0,Math.min(o,i-a));o!=s&&(o=s,r=s*this._itemSize,e.start=Math.floor(o)),e.end=Math.max(0,Math.min(i,e.start+a))}var c=r-e.start*this._itemSize;if(c0&&(e.end=Math.min(i,e.end+d),e.start=Math.max(0,Math.floor(o-this._minBufferPx/this._itemSize)))}}this._viewport.setRenderedRange(e),this._viewport.setRenderedContentOffset(this._itemSize*e.start),this._scrolledIndexChange.next(Math.floor(o))}}}]),t}();function N(t){return t._scrollStrategy}var U=function(){var t=function(){function t(){C(this,t),this._itemSize=20,this._minBufferPx=100,this._maxBufferPx=200,this._scrollStrategy=new L(this.itemSize,this.minBufferPx,this.maxBufferPx)}return w(t,[{key:"ngOnChanges",value:function(){this._scrollStrategy.updateItemAndBufferSize(this.itemSize,this.minBufferPx,this.maxBufferPx)}},{key:"itemSize",get:function(){return this._itemSize},set:function(t){this._itemSize=Object(i.f)(t)}},{key:"minBufferPx",get:function(){return this._minBufferPx},set:function(t){this._minBufferPx=Object(i.f)(t)}},{key:"maxBufferPx",get:function(){return this._maxBufferPx},set:function(t){this._maxBufferPx=Object(i.f)(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275dir=r.Jb({type:t,selectors:[["cdk-virtual-scroll-viewport","itemSize",""]],inputs:{itemSize:"itemSize",minBufferPx:"minBufferPx",maxBufferPx:"maxBufferPx"},features:[r.Bb([{provide:j,useFactory:N,deps:[Object(r.V)((function(){return t}))]}]),r.Ab]}),t}(),F=function(){var t=function(){function t(e,n,i){C(this,t),this._ngZone=e,this._platform=n,this._scrolled=new s.b,this._globalSubscription=null,this._scrolledCount=0,this.scrollContainers=new Map,this._document=i}return w(t,[{key:"register",value:function(t){var e=this;this.scrollContainers.has(t)||this.scrollContainers.set(t,t.elementScrolled().subscribe((function(){return e._scrolled.next(t)})))}},{key:"deregister",value:function(t){var e=this.scrollContainers.get(t);e&&(e.unsubscribe(),this.scrollContainers.delete(t))}},{key:"scrolled",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:20;return this._platform.isBrowser?new l.a((function(n){t._globalSubscription||t._addGlobalListener();var i=e>0?t._scrolled.pipe(Object(_.a)(e)).subscribe(n):t._scrolled.subscribe(n);return t._scrolledCount++,function(){i.unsubscribe(),t._scrolledCount--,t._scrolledCount||t._removeGlobalListener()}})):Object(u.a)()}},{key:"ngOnDestroy",value:function(){var t=this;this._removeGlobalListener(),this.scrollContainers.forEach((function(e,n){return t.deregister(n)})),this._scrolled.complete()}},{key:"ancestorScrolled",value:function(t,e){var n=this.getAncestorScrollContainers(t);return this.scrolled(e).pipe(Object(O.a)((function(t){return!t||n.indexOf(t)>-1})))}},{key:"getAncestorScrollContainers",value:function(t){var e=this,n=[];return this.scrollContainers.forEach((function(i,r){e._scrollableContainsElement(r,t)&&n.push(r)})),n}},{key:"_getDocument",value:function(){return this._document||document}},{key:"_getWindow",value:function(){return this._getDocument().defaultView||window}},{key:"_scrollableContainsElement",value:function(t,e){var n=e.nativeElement,i=t.getElementRef().nativeElement;do{if(n==i)return!0}while(n=n.parentElement);return!1}},{key:"_addGlobalListener",value:function(){var t=this;this._globalSubscription=this._ngZone.runOutsideAngular((function(){var e=t._getWindow();return Object(d.a)(e.document,"scroll").subscribe((function(){return t._scrolled.next()}))}))}},{key:"_removeGlobalListener",value:function(){this._globalSubscription&&(this._globalSubscription.unsubscribe(),this._globalSubscription=null)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(r.Yb(r.B),r.Yb(P.a),r.Yb(A.d,8))},t.\u0275prov=Object(r.Kb)({factory:function(){return new t(Object(r.Yb)(r.B),Object(r.Yb)(P.a),Object(r.Yb)(A.d,8))},token:t,providedIn:"root"}),t}(),B=function(){var t=function(){function t(e,n,i,r){var o=this;C(this,t),this.elementRef=e,this.scrollDispatcher=n,this.ngZone=i,this.dir=r,this._destroyed=new s.b,this._elementScrolled=new l.a((function(t){return o.ngZone.runOutsideAngular((function(){return Object(d.a)(o.elementRef.nativeElement,"scroll").pipe(Object(k.a)(o._destroyed)).subscribe(t)}))}))}return w(t,[{key:"ngOnInit",value:function(){this.scrollDispatcher.register(this)}},{key:"ngOnDestroy",value:function(){this.scrollDispatcher.deregister(this),this._destroyed.next(),this._destroyed.complete()}},{key:"elementScrolled",value:function(){return this._elementScrolled}},{key:"getElementRef",value:function(){return this.elementRef}},{key:"scrollTo",value:function(t){var e=this.elementRef.nativeElement,n=this.dir&&"rtl"==this.dir.value;null==t.left&&(t.left=n?t.end:t.start),null==t.right&&(t.right=n?t.start:t.end),null!=t.bottom&&(t.top=e.scrollHeight-e.clientHeight-t.bottom),n&&0!=Object(P.d)()?(null!=t.left&&(t.right=e.scrollWidth-e.clientWidth-t.left),2==Object(P.d)()?t.left=t.right:1==Object(P.d)()&&(t.left=t.right?-t.right:t.right)):null!=t.right&&(t.left=e.scrollWidth-e.clientWidth-t.right),this._applyScrollToOptions(t)}},{key:"_applyScrollToOptions",value:function(t){var e=this.elementRef.nativeElement;Object(P.g)()?e.scrollTo(t):(null!=t.top&&(e.scrollTop=t.top),null!=t.left&&(e.scrollLeft=t.left))}},{key:"measureScrollOffset",value:function(t){var e=this.elementRef.nativeElement;if("top"==t)return e.scrollTop;if("bottom"==t)return e.scrollHeight-e.clientHeight-e.scrollTop;var n=this.dir&&"rtl"==this.dir.value;return"start"==t?t=n?"right":"left":"end"==t&&(t=n?"left":"right"),n&&2==Object(P.d)()?"left"==t?e.scrollWidth-e.clientWidth-e.scrollLeft:e.scrollLeft:n&&1==Object(P.d)()?"left"==t?e.scrollLeft+e.scrollWidth-e.clientWidth:-e.scrollLeft:"left"==t?e.scrollLeft:e.scrollWidth-e.clientWidth-e.scrollLeft}}]),t}();return t.\u0275fac=function(e){return new(e||t)(r.Ob(r.l),r.Ob(F),r.Ob(r.B),r.Ob(I.b,8))},t.\u0275dir=r.Jb({type:t,selectors:[["","cdk-scrollable",""],["","cdkScrollable",""]]}),t}(),z=function(){var t=function(){function t(e,n,i){var r=this;C(this,t),this._platform=e,this._change=new s.b,this._changeListener=function(t){r._change.next(t)},this._document=i,n.runOutsideAngular((function(){if(e.isBrowser){var t=r._getWindow();t.addEventListener("resize",r._changeListener),t.addEventListener("orientationchange",r._changeListener)}r.change().subscribe((function(){return r._updateViewportSize()}))}))}return w(t,[{key:"ngOnDestroy",value:function(){if(this._platform.isBrowser){var t=this._getWindow();t.removeEventListener("resize",this._changeListener),t.removeEventListener("orientationchange",this._changeListener)}this._change.complete()}},{key:"getViewportSize",value:function(){this._viewportSize||this._updateViewportSize();var t={width:this._viewportSize.width,height:this._viewportSize.height};return this._platform.isBrowser||(this._viewportSize=null),t}},{key:"getViewportRect",value:function(){var t=this.getViewportScrollPosition(),e=this.getViewportSize(),n=e.width,i=e.height;return{top:t.top,left:t.left,bottom:t.top+i,right:t.left+n,height:i,width:n}}},{key:"getViewportScrollPosition",value:function(){if(!this._platform.isBrowser)return{top:0,left:0};var t=this._getDocument(),e=this._getWindow(),n=t.documentElement,i=n.getBoundingClientRect();return{top:-i.top||t.body.scrollTop||e.scrollY||n.scrollTop||0,left:-i.left||t.body.scrollLeft||e.scrollX||n.scrollLeft||0}}},{key:"change",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:20;return t>0?this._change.pipe(Object(_.a)(t)):this._change}},{key:"_getDocument",value:function(){return this._document||document}},{key:"_getWindow",value:function(){return this._getDocument().defaultView||window}},{key:"_updateViewportSize",value:function(){var t=this._getWindow();this._viewportSize=this._platform.isBrowser?{width:t.innerWidth,height:t.innerHeight}:{width:0,height:0}}}]),t}();return t.\u0275fac=function(e){return new(e||t)(r.Yb(P.a),r.Yb(r.B),r.Yb(A.d,8))},t.\u0275prov=Object(r.Kb)({factory:function(){return new t(Object(r.Yb)(P.a),Object(r.Yb)(r.B),Object(r.Yb)(A.d,8))},token:t,providedIn:"root"}),t}(),V="undefined"!=typeof requestAnimationFrame?f.a:b.a,H=function(){var t=function(t){a(n,t);var e=c(n);function n(t,i,r,o,a,c,u){var d;return C(this,n),(d=e.call(this,t,c,r,a)).elementRef=t,d._changeDetectorRef=i,d._scrollStrategy=o,d._detachedSubject=new s.b,d._renderedRangeSubject=new s.b,d._orientation="vertical",d.scrolledIndexChange=new l.a((function(t){return d._scrollStrategy.scrolledIndexChange.subscribe((function(e){return Promise.resolve().then((function(){return d.ngZone.run((function(){return t.next(e)}))}))}))})),d.renderedRangeStream=d._renderedRangeSubject,d._totalContentSize=0,d._totalContentWidth="",d._totalContentHeight="",d._renderedRange={start:0,end:0},d._dataLength=0,d._viewportSize=0,d._renderedContentOffset=0,d._renderedContentOffsetNeedsRewrite=!1,d._isChangeDetectionPending=!1,d._runAfterChangeDetection=[],d._viewportChanges=g.a.EMPTY,u&&(d._viewportChanges=u.change().subscribe((function(){d.checkViewportSize()}))),d}return w(n,[{key:"ngOnInit",value:function(){var t=this;o(h(n.prototype),"ngOnInit",this).call(this),this.ngZone.runOutsideAngular((function(){return Promise.resolve().then((function(){t._measureViewportSize(),t._scrollStrategy.attach(t),t.elementScrolled().pipe(Object(T.a)(null),Object(_.a)(0,V)).subscribe((function(){return t._scrollStrategy.onContentScrolled()})),t._markChangeDetectionNeeded()}))}))}},{key:"ngOnDestroy",value:function(){this.detach(),this._scrollStrategy.detach(),this._renderedRangeSubject.complete(),this._detachedSubject.complete(),this._viewportChanges.unsubscribe(),o(h(n.prototype),"ngOnDestroy",this).call(this)}},{key:"attach",value:function(t){var e=this;this.ngZone.runOutsideAngular((function(){e._forOf=t,e._forOf.dataStream.pipe(Object(k.a)(e._detachedSubject)).subscribe((function(t){var n=t.length;n!==e._dataLength&&(e._dataLength=n,e._scrollStrategy.onDataLengthChanged()),e._doChangeDetection()}))}))}},{key:"detach",value:function(){this._forOf=null,this._detachedSubject.next()}},{key:"getDataLength",value:function(){return this._dataLength}},{key:"getViewportSize",value:function(){return this._viewportSize}},{key:"getRenderedRange",value:function(){return this._renderedRange}},{key:"setTotalContentSize",value:function(t){this._totalContentSize!==t&&(this._totalContentSize=t,this._calculateSpacerSize(),this._markChangeDetectionNeeded())}},{key:"setRenderedRange",value:function(t){var e,n,i=this;((e=this._renderedRange).start!=(n=t).start||e.end!=n.end)&&(this._renderedRangeSubject.next(this._renderedRange=t),this._markChangeDetectionNeeded((function(){return i._scrollStrategy.onContentRendered()})))}},{key:"getOffsetToRenderedContentStart",value:function(){return this._renderedContentOffsetNeedsRewrite?null:this._renderedContentOffset}},{key:"setRenderedContentOffset",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"to-start",i="horizontal"==this.orientation,r=i?"X":"Y",o="translate".concat(r,"(").concat(Number((i&&this.dir&&"rtl"==this.dir.value?-1:1)*t),"px)");this._renderedContentOffset=t,"to-end"===n&&(o+=" translate".concat(r,"(-100%)"),this._renderedContentOffsetNeedsRewrite=!0),this._renderedContentTransform!=o&&(this._renderedContentTransform=o,this._markChangeDetectionNeeded((function(){e._renderedContentOffsetNeedsRewrite?(e._renderedContentOffset-=e.measureRenderedContentSize(),e._renderedContentOffsetNeedsRewrite=!1,e.setRenderedContentOffset(e._renderedContentOffset)):e._scrollStrategy.onRenderedOffsetChanged()})))}},{key:"scrollToOffset",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"auto",n={behavior:e};"horizontal"===this.orientation?n.start=t:n.top=t,this.scrollTo(n)}},{key:"scrollToIndex",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"auto";this._scrollStrategy.scrollToIndex(t,e)}},{key:"measureScrollOffset",value:function(t){return o(h(n.prototype),"measureScrollOffset",this).call(this,t||("horizontal"===this.orientation?"start":"top"))}},{key:"measureRenderedContentSize",value:function(){var t=this._contentWrapper.nativeElement;return"horizontal"===this.orientation?t.offsetWidth:t.offsetHeight}},{key:"measureRangeSize",value:function(t){return this._forOf?this._forOf.measureRangeSize(t,this.orientation):0}},{key:"checkViewportSize",value:function(){this._measureViewportSize(),this._scrollStrategy.onDataLengthChanged()}},{key:"_measureViewportSize",value:function(){var t=this.elementRef.nativeElement;this._viewportSize="horizontal"===this.orientation?t.clientWidth:t.clientHeight}},{key:"_markChangeDetectionNeeded",value:function(t){var e=this;t&&this._runAfterChangeDetection.push(t),this._isChangeDetectionPending||(this._isChangeDetectionPending=!0,this.ngZone.runOutsideAngular((function(){return Promise.resolve().then((function(){e._doChangeDetection()}))})))}},{key:"_doChangeDetection",value:function(){var t=this;this._isChangeDetectionPending=!1,this._contentWrapper.nativeElement.style.transform=this._renderedContentTransform,this.ngZone.run((function(){return t._changeDetectorRef.markForCheck()}));var e=this._runAfterChangeDetection;this._runAfterChangeDetection=[];var n,i=p(e);try{for(i.s();!(n=i.n()).done;){(0,n.value)()}}catch(r){i.e(r)}finally{i.f()}}},{key:"_calculateSpacerSize",value:function(){this._totalContentHeight="horizontal"===this.orientation?"":this._totalContentSize+"px",this._totalContentWidth="horizontal"===this.orientation?this._totalContentSize+"px":""}},{key:"orientation",get:function(){return this._orientation},set:function(t){this._orientation!==t&&(this._orientation=t,this._calculateSpacerSize())}}]),n}(B);return t.\u0275fac=function(e){return new(e||t)(r.Ob(r.l),r.Ob(r.h),r.Ob(r.B),r.Ob(j,8),r.Ob(I.b,8),r.Ob(F),r.Ob(z))},t.\u0275cmp=r.Ib({type:t,selectors:[["cdk-virtual-scroll-viewport"]],viewQuery:function(t,e){var n;1&t&&r.Jc(D,!0),2&t&&r.zc(n=r.cc())&&(e._contentWrapper=n.first)},hostAttrs:[1,"cdk-virtual-scroll-viewport"],hostVars:4,hostBindings:function(t,e){2&t&&r.Gb("cdk-virtual-scroll-orientation-horizontal","horizontal"===e.orientation)("cdk-virtual-scroll-orientation-vertical","horizontal"!==e.orientation)},inputs:{orientation:"orientation"},outputs:{scrolledIndexChange:"scrolledIndexChange"},features:[r.Bb([{provide:B,useExisting:t}]),r.zb],ngContentSelectors:R,decls:4,vars:4,consts:[[1,"cdk-virtual-scroll-content-wrapper"],["contentWrapper",""],[1,"cdk-virtual-scroll-spacer"]],template:function(t,e){1&t&&(r.lc(),r.Ub(0,"div",0,1),r.kc(2),r.Tb(),r.Pb(3,"div",2)),2&t&&(r.Cb(3),r.Lc("width",e._totalContentWidth)("height",e._totalContentHeight))},styles:["cdk-virtual-scroll-viewport{display:block;position:relative;overflow:auto;contain:strict;transform:translateZ(0);will-change:scroll-position;-webkit-overflow-scrolling:touch}.cdk-virtual-scroll-content-wrapper{position:absolute;top:0;left:0;contain:content}[dir=rtl] .cdk-virtual-scroll-content-wrapper{right:0;left:auto}.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper{min-height:100%}.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>dl:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>ol:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>table:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>ul:not([cdkVirtualFor]){padding-left:0;padding-right:0;margin-left:0;margin-right:0;border-left-width:0;border-right-width:0;outline:none}.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper{min-width:100%}.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>dl:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>ol:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>table:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>ul:not([cdkVirtualFor]){padding-top:0;padding-bottom:0;margin-top:0;margin-bottom:0;border-top-width:0;border-bottom-width:0;outline:none}.cdk-virtual-scroll-spacer{position:absolute;top:0;left:0;height:1px;width:1px;transform-origin:0 0}[dir=rtl] .cdk-virtual-scroll-spacer{right:0;left:auto;transform-origin:100% 0}\n"],encapsulation:2,changeDetection:0}),t}();function q(t,e,n){if(!n.getBoundingClientRect)return 0;var i=n.getBoundingClientRect();return"horizontal"===t?"start"===e?i.left:i.right:"start"===e?i.top:i.bottom}var $=function(){var t=function(){function t(e,n,i,r,o,a){var c=this;C(this,t),this._viewContainerRef=e,this._template=n,this._differs=i,this._viewRepeater=r,this._viewport=o,this.viewChange=new s.b,this._dataSourceChanges=new s.b,this.dataStream=this._dataSourceChanges.pipe(Object(T.a)(null),Object(S.a)(),Object(E.a)((function(t){var e=m(t,2),n=e[0],i=e[1];return c._changeDataSource(n,i)})),Object(x.a)(1)),this._differ=null,this._needsUpdate=!1,this._destroyed=new s.b,this.dataStream.subscribe((function(t){c._data=t,c._onRenderedDataChange()})),this._viewport.renderedRangeStream.pipe(Object(k.a)(this._destroyed)).subscribe((function(t){c._renderedRange=t,a.run((function(){return c.viewChange.next(c._renderedRange)})),c._onRenderedDataChange()})),this._viewport.attach(this)}return w(t,[{key:"measureRangeSize",value:function(t,e){if(t.start>=t.end)return 0;for(var n,i,r=t.start-this._renderedRange.start,o=t.end-t.start,a=0;a-1;c--){var u=this._viewContainerRef.get(c+r);if(u&&u.rootNodes.length){i=u.rootNodes[u.rootNodes.length-1];break}}return n&&i?q(e,"end",i)-q(e,"start",n):0}},{key:"ngDoCheck",value:function(){if(this._differ&&this._needsUpdate){var t=this._differ.diff(this._renderedItems);t?this._applyChanges(t):this._updateContext(),this._needsUpdate=!1}}},{key:"ngOnDestroy",value:function(){this._viewport.detach(),this._dataSourceChanges.next(void 0),this._dataSourceChanges.complete(),this.viewChange.complete(),this._destroyed.next(),this._destroyed.complete(),this._viewRepeater.detach()}},{key:"_onRenderedDataChange",value:function(){this._renderedRange&&(this._renderedItems=this._data.slice(this._renderedRange.start,this._renderedRange.end),this._differ||(this._differ=this._differs.find(this._renderedItems).create(this.cdkVirtualForTrackBy)),this._needsUpdate=!0)}},{key:"_changeDataSource",value:function(t,e){return t&&t.disconnect(this),this._needsUpdate=!0,e?e.connect(this):Object(u.a)()}},{key:"_updateContext",value:function(){for(var t=this._data.length,e=this._viewContainerRef.length;e--;){var n=this._viewContainerRef.get(e);n.context.index=this._renderedRange.start+e,n.context.count=t,this._updateComputedContextProperties(n.context),n.detectChanges()}}},{key:"_applyChanges",value:function(t){var e=this;this._viewRepeater.applyChanges(t,this._viewContainerRef,(function(t,n,i){return e._getEmbeddedViewArgs(t,i)}),(function(t){return t.item})),t.forEachIdentityChange((function(t){e._viewContainerRef.get(t.currentIndex).context.$implicit=t.item}));for(var n=this._data.length,i=this._viewContainerRef.length;i--;){var r=this._viewContainerRef.get(i);r.context.index=this._renderedRange.start+i,r.context.count=n,this._updateComputedContextProperties(r.context)}}},{key:"_updateComputedContextProperties",value:function(t){t.first=0===t.index,t.last=t.index===t.count-1,t.even=t.index%2==0,t.odd=!t.even}},{key:"_getEmbeddedViewArgs",value:function(t,e){return{templateRef:this._template,context:{$implicit:t.item,cdkVirtualForOf:this._cdkVirtualForOf,index:-1,count:-1,first:!1,last:!1,odd:!1,even:!1},index:e}}},{key:"cdkVirtualForOf",get:function(){return this._cdkVirtualForOf},set:function(t){this._cdkVirtualForOf=t,Object(M.h)(t)?this._dataSourceChanges.next(t):this._dataSourceChanges.next(new M.a(Object(v.a)(t)?t:Array.prototype.slice.call(t||[])))}},{key:"cdkVirtualForTrackBy",get:function(){return this._cdkVirtualForTrackBy},set:function(t){var e=this;this._needsUpdate=!0,this._cdkVirtualForTrackBy=t?function(n,i){return t(n+(e._renderedRange?e._renderedRange.start:0),i)}:void 0}},{key:"cdkVirtualForTemplate",set:function(t){t&&(this._needsUpdate=!0,this._template=t)}},{key:"cdkVirtualForTemplateCacheSize",get:function(){return this._viewRepeater.viewCacheSize},set:function(t){this._viewRepeater.viewCacheSize=Object(i.f)(t)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(r.Ob(r.R),r.Ob(r.N),r.Ob(r.u),r.Ob(M.g),r.Ob(H,4),r.Ob(r.B))},t.\u0275dir=r.Jb({type:t,selectors:[["","cdkVirtualFor","","cdkVirtualForOf",""]],inputs:{cdkVirtualForOf:"cdkVirtualForOf",cdkVirtualForTrackBy:"cdkVirtualForTrackBy",cdkVirtualForTemplate:"cdkVirtualForTemplate",cdkVirtualForTemplateCacheSize:"cdkVirtualForTemplateCacheSize"},features:[r.Bb([{provide:M.g,useClass:M.f}])]}),t}(),Q=function(){var t=function t(){C(this,t)};return t.\u0275mod=r.Mb({type:t}),t.\u0275inj=r.Lb({factory:function(e){return new(e||t)}}),t}(),W=function(){var t=function t(){C(this,t)};return t.\u0275mod=r.Mb({type:t}),t.\u0275inj=r.Lb({factory:function(e){return new(e||t)},imports:[[I.a,P.b,Q],I.a,Q]}),t}()},VmIW:function(t,e,n){var i,r;"undefined"!=typeof self&&self,void 0===(r="function"==typeof(i=function(){"use strict";var t={apply2:b,assign:u(Object.assign)?Object.assign:function(t,e){for(var n in e)e.hasOwnProperty(n)&&void 0!==e[n]&&(t[n]=e[n]);return t},compose:c,curry:s(p(s),[])([]),idFunction:l,isFunction:u,noop:o,swap:p};function e(t,e){t["@@type"]="monet.js/"+e}function n(t){return function(e){return(e["@@type"]||e.constructor["@@type"])==="monet.js/"+t}}function i(t){return function(e){var n=e["@@type"]||e.constructor&&e.constructor["@@type"];return Boolean(n)&&n.length>=t.length&&n.indexOf(t)===n.length-t.length}}function r(t){return null==t}function o(){}function a(t){return Array.prototype.slice.call(t)}function s(t,e){return function(){var n=e.concat(a(arguments));return n.length>=t.length?t.apply(null,n.slice(0,n.length)):s(t,n)}}function c(t,e){return function(n){return t(e(n))}}function u(t){return Boolean(t&&t.constructor&&t.call&&t.apply)}function l(t){return t}function d(t,e){return t===e||t!=t&&e!=e||!(!t||!e)&&!(!u(t.equals)||!u(e.equals))&&t.equals(e)}function h(t){return function(e){return d(t,e)}}function f(){return!1}function p(t){return function(e,n){return t(n,e)}}function b(t,e,n){return e.ap(t.map(s(n,[])))}function g(t,e){for(var n=t,i=e;!n.isNil&&!i.isNil;){if(!h(n.head())(i.head()))return!1;n=n.tail(),i=i.tail()}return n.isNil&&i.isNil}function m(t,e){return function t(e,n){return n.isNil?Q(n):$((function(){return t(e,n.tail())})).map(s(O,[])(e(n.head())))}(t,e).run()}function v(t,e){return t.foldRight(w)((function(t,n){return e(t)?O(t,n):n}))}function y(t,e){return function t(e,n){if(e.isNil)return Q(D());var i=e.head();return n(i)?Q(M(i)):$((function(){return t(e.tail(),n)}))}(t,e).run()}function _(t,e){return function t(e,n){return e.isNil?Q(!1):d(e.head(),n)?Q(!0):$((function(){return t(e.tail(),n)}))}(t,e).run()}function O(t,e){return e.cons(t)}function k(){switch(arguments.length){case 0:return new k.fn.init;case 1:return new k.fn.init(arguments[0]);default:return new k.fn.init(arguments[0],arguments[1])}}t.List=k;var w,C=function(t,e,n){return function e(n,i){return i.isNil?Q(n):$((function(){return e(t(n,i.head()),i.tail())}))}(e,n).run()},T=function(t,e,n){return function e(n,i){return n.isNil?Q(i):$((function(){return e(n.tail(),i)})).map((function(e){return t(n.head(),e)}))}(e,n).run()},S=function(t,e){return function t(e,n){return e.isNil?Q(n):$((function(){return t(e.tail(),n).map((function(t){return t.cons(e.head())}))}))}(t,e).run()},E=function(t,e){return t.foldRight(e.of(w))(e.map2(O))},x=function(t){return t.foldLeft(w)(p(O))};function P(t){return new Error("Cannot create an empty Non-Empty List. Passed head is "+t+".")}function A(t,e){if(r(t))throw P(t);return new A.fn.init(t,e)}(k.fn=k.prototype={init:function(){var t=arguments[0],n=arguments[1];0===arguments.length?(this.isNil=!0,this.size_=0):(this.isNil=!1,this.head_=t,this.tail_=n||w,this.size_=this.tail_.size()+1),e(this,"List")},of:function(t){return new k(t)},size:function(){return this.size_},equals:function(t){return(k.isOfType(t)||A.isOfType(t))&&g(this,t)},cons:function(t){return k(t,this)},snoc:function(t){return this.concat(k(t))},map:function(t){return m(t,this)},toArray:function(){return C((function(t,e){return t.push(e),t}),[],this)},toSet:function(){return new Set(this)},foldLeft:function(t){var e=this;return function(n){return C(n,t,e)}},foldRight:function(t){var e=this;return function(n){return T(n,e,t)}},append:function(t){return S(this,t)},filter:function(t){return v(this,t)},find:function(t){return y(this,t)},flatten:function(){return T(S,this,w)},flattenMaybe:function(){return this.flatMap(I.toList)},reverse:function(){return x(this)},bind:function(t){return this.map(t).flatten()},forEach:function(t){!function t(e,n){n.isNil||(e(n.head()),t(e,n.tail()))}(t,this)},contains:function(t){return _(this,t)},sequenceMaybe:function(){return E(this,I)},sequenceValidation:function(){return this.foldLeft(j(w))((function(t,e){return t.ap(e.map((function(t){return function(e){return O(t,e)}})))})).map(x)},sequenceEither:function(){return E(this,B)},sequenceIO:function(){return E(this,F)},sequenceReader:function(){return E(this,H)},sequence:function(t){return E(this,t)},head:function(){return this.head_},headMaybe:function(){return this.isNil?D():M(this.head_)},tail:function(){return this.isNil?w:this.tail_},tails:function(){return this.isNil?k(w,w):this.tail().tails().cons(this)},ap:function(t){return e=t,this.bind((function(t){return e.map((function(e){return e(t)}))}));var e},isNEL:f,toString:function(){return this.isNil?"Nil":"List("+this.toArray().join(", ")+")"},inspect:function(){return this.toString()}}).init.prototype=k.fn,e(k,"List"),e(k.fn.init,"List"),k.isInstance=n("List"),k.isOfType=i("List"),k.prototype.empty=function(){return w},k.fromArray=function(t){return t.reduceRight((function(t,e){return t.cons(e)}),w)},k.from=function(t){return k.fromArray(Array.from(t))},k.of=function(t){return new k(t,w)},k.prototype.each=k.prototype.forEach,w=t.Nil=new k.fn.init,t.NEL=t.NonEmptyList=A,A.of=function(t){return A(t,w)},A.fn=A.prototype={init:function(t,n){if(r(t))throw P(t);this.isNil=!1,this.head_=t,this.tail_=r(n)?w:n,this.size_=this.tail_.size()+1,e(this,"NEL")},equals:function(t){return k.isOfType(t)||A.isOfType(t)&&g(this,t)},cons:function(t){return A(t,this.toList())},snoc:function(t){return this.concat(A(t))},map:function(t){return A(t(this.head_),m(t,this.tail_))},bind:function(t){var e=t(this.head_);if(!e.isNEL())throw new Error("NEL.fn.bind: Passed function must return a NonEmptyList.");var n=this.tail().foldLeft(w.snoc(e.head()).append(e.tail()))((function(e,n){var i=t(n).toList();return e.snoc(i.head()).append(i.tail())}));return new A(n.head(),n.tail())},head:function(){return this.head_},tail:function(){return this.tail_},tails:function(){var t=this.toList().tails().map(A.fromList).flattenMaybe();return A(t.head(),t.tail())},toList:function(){return k(this.head_,this.tail_)},reverse:function(){if(this.tail().isNil)return this;var t=this.tail().reverse();return A(t.head(),t.tail().append(k(this.head())))},foldLeft:function(t){return this.toList().foldLeft(t)},foldRight:function(t){return this.toList().foldRight(t)},reduceLeft:function(t){return this.tail().foldLeft(this.head())(t)},filter:function(t){return v(this.toList(),t)},find:function(t){return y(this.toList(),t)},flatten:function(){return T(S,this.toList().map((function(t){return t.isNEL()?t.toList():t})),w)},flattenMaybe:function(){return this.toList().flatMap(I.toList)},contains:function(t){return _(this.toList(),t)},append:function(t){return A.fromList(this.toList().append(t.toList())).some()},cobind:function(t){return this.cojoin().map(t)},size:function(){return this.size_},forEach:function(t){return this.toList().forEach(t)},isNEL:function(){return!0},toString:function(){return"NEL("+this.toArray().join(", ")+")"},inspect:function(){return this.toString()}},A.fromList=function(t){return t.isNil?D():M(A(t.head(),t.tail()))},A.fromArray=function(t){return A.fromList(k.fromArray(t))},A.from=function(t){return A.fromList(k.from(t))},A.fn.init.prototype=A.fn,e(A,"NEL"),e(A.fn.init,"NEL"),A.isInstance=n("NEL"),A.isOfType=i("NEL"),A.prototype.toArray=k.prototype.toArray,A.prototype.toSet=k.prototype.toSet,A.prototype.extract=A.prototype.copure=A.prototype.head,A.prototype.cojoin=A.prototype.tails,A.prototype.coflatMap=A.prototype.mapTails=A.prototype.cobind,A.prototype.ap=k.prototype.ap;var I=t.Maybe={};I.fromFalsy=function(t){return t?I.Some(t):I.None()},I.fromNull=function(t){return r(t)?I.None():I.Some(t)},I.fromUndefined=function(t){return void 0===t?I.None():I.Some(t)},I.fromEmpty=function(t){return r(e=t)||""===e||Array.isArray(e)&&0===e.length||"object"==typeof e&&0===Object.keys(e).length?I.None():I.Some(t);var e},I.of=function(t){return M(t)};var M=I.Just=I.Some=I.some=t.Some=t.Just=function(t){return new I.fn.init(!0,t)},D=I.Nothing=I.None=I.none=t.None=t.Nothing=function(){return new I.fn.init(!1,null)};I.toList=function(t){return t.toList()},I.fn=I.prototype={init:function(t,n){if(this.isValue=t,t&&r(n))throw new Error("Can not create Some with illegal value: "+n+".");this.val=n,e(this,"Maybe")},isSome:function(){return this.isValue},isNone:function(){return!this.isSome()},bind:function(t){return this.isValue?t(this.val):this},some:function(){if(this.isValue)return this.val;throw new Error("Cannot call .some() on a None.")},orSome:function(t){return this.isValue?this.val:t},orLazy:function(t){return this.cata(t,l)},orNull:function(){return this.orSome(null)},orUndefined:function(){return this.orSome(void 0)},orElse:function(t){return this.catchMap((function(){return t}))},ap:function(t){var e=this.val;return this.isValue?t.map((function(t){return t(e)})):this},equals:function(t){return I.isOfType(t)&&this.cata((function(){return t.isNone()}),(function(e){return t.fold(!1)(h(e))}))},toArray:function(){return this.map((function(t){return[t]})).orLazy((function(){return[]}))},toSet:function(){return new Set(this)},toList:function(){return this.map(k).orLazy((function(){return w}))},toEither:function(t){return this.isSome()?z(this.val):V(t)},toValidation:function(t){return this.isSome()?j(this.val):L(t)},fold:function(t){var e=this;return function(n){return e.isSome()?n(e.val):t}},foldLeft:function(t){return this.toList().foldLeft(t)},foldRight:function(t){return this.toList().foldRight(t)},cata:function(t,e){return this.isSome()?e(this.val):t()},catchMap:function(t){return this.isSome()?this:t()},filter:function(t){var e=this;return e.flatMap((function(n){return t(n)?e:D()}))},orNoneIf:function(t){return t?D():this},contains:function(t){return!!this.isSome()&&d(this.val,t)},forEach:function(t){this.cata(o,t)},orElseRun:function(t){this.cata(t,o)},toString:function(){return this.isSome()?"Just("+this.val+")":"Nothing"},inspect:function(){return this.toString()}},I.prototype.orJust=I.prototype.getOrElse=I.prototype.orSome,I.prototype.just=I.prototype.some,I.prototype.isJust=I.prototype.isSome,I.prototype.isNothing=I.prototype.isNone,I.prototype.orNothingIf=I.prototype.orNoneIf,I.fn.init.prototype=I.fn,e(I,"Maybe"),e(I.fn.init,"Maybe"),I.isInstance=n("Maybe"),I.isOfType=i("Maybe");var R=t.Validation={},j=R.Success=R.success=t.Success=function(t){return new R.fn.init(t,!0)},L=R.Fail=R.fail=t.Fail=function(t){return new R.fn.init(t,!1)};R.of=function(t){return j(t)},R.fn=R.prototype={init:function(t,n){this.val=t,this.isSuccessValue=n,e(this,"Validation")},success:function(){if(this.isSuccess())return this.val;throw new Error("Cannot call success() on a Fail.")},isSuccess:function(){return this.isSuccessValue},isFail:function(){return!this.isSuccessValue},fail:function(){if(this.isSuccess())throw new Error("Cannot call fail() on a Success.");return this.val},bind:function(t){return this.isSuccess()?t(this.val):this},ap:function(t){var e=this.val;return this.isSuccess()?t.map((function(t){return t(e)})):t.isFail()?R.Fail(N.append(e,t.fail())):this},acc:function(){return this.isSuccessValue?R.success((function t(){return t})):this},foldLeft:function(t){return this.toMaybe().toList().foldLeft(t)},foldRight:function(t){return this.toMaybe().toList().foldRight(t)},cata:function(t,e){return this.isSuccessValue?e(this.val):t(this.val)},catchMap:function(t){return this.isSuccess()?this:t(this.val)},swap:function(){return this.isSuccess()?L(this.val):j(this.val)},failMap:function(t){return this.isFail()?L(t(this.val)):this},bimap:function(t,e){return this.isSuccessValue?this.map(e):this.failMap(t)},forEach:function(t){this.cata(o,t)},forEachFail:function(t){this.cata(t,o)},equals:function(t){return R.isOfType(t)&&this.cata((function(e){return t.cata(h(e),f)}),(function(e){return t.cata(f,h(e))}))},toMaybe:function(){return this.isSuccess()?M(this.val):D()},toEither:function(){return(this.isSuccess()?z:V)(this.val)},toString:function(){return(this.isSuccess()?"Success(":"Fail(")+this.val+")"},inspect:function(){return this.toString()}},R.prototype.fold=R.prototype.cata,R.fn.init.prototype=R.fn,e(R,"Validation"),e(R.fn.init,"Validation"),R.isInstance=n("Validation"),R.isOfType=i("Validation");var N=t.Semigroup={append:function(t,e){if(u(t.concat))return t.concat(e);throw new Error("Couldn't find a semigroup appender in the environment, please specify your own append function")}},U=t.monadTransformer=t.MonadT=t.monadT=function(t){return new U.fn.init(t)};U.of=function(t){return U(t)},U.fn=U.prototype={init:function(t){this.monad=t,e(R,"MonadT")},map:function(t){return U(this.monad.map((function(e){return e.map(t)})))},bind:function(t){return U(this.monad.map((function(e){return e.flatMap(t)})))},ap:function(t){return U(this.monad.flatMap((function(e){return t.perform().map((function(t){return e.ap(t)}))})))},perform:function(){return this.monad}},U.fn.init.prototype=U.fn;var F=t.IO=t.io=function(t){return new F.fn.init(t)};F.of=function(t){return F((function(){return t}))},F.fn=F.prototype={init:function(t){if(!u(t))throw new Error("IO requires a function.");this.effectFn=t,e(this,"IO")},map:function(t){var e=this;return F((function(){return t(e.effectFn())}))},bind:function(t){var e=this;return F((function(){return t(e.effectFn()).run()}))},ap:function(t){var e=this;return t.map((function(t){return t(e.effectFn())}))},run:function(){return this.effectFn()}},F.fn.init.prototype=F.fn,e(F,"IO"),e(F.fn.init,"IO"),F.isInstance=n("IO"),F.isOfType=i("IO"),F.prototype.perform=F.prototype.performUnsafeIO=F.prototype.run;var B=t.Either={};B.of=function(t){return z(t)},B.fromTry=function(t){try{return B.right(t())}catch(e){return B.left(e)}},B.fromPromise=function(t){return t.then(B.Right,B.Left)};var z=B.Right=B.right=t.Right=function(t){return new B.fn.init(t,!0)},V=B.Left=B.left=t.Left=function(t){return new B.fn.init(t,!1)};B.fn=B.prototype={init:function(t,n){this.isRightValue=n,this.value=t,e(this,"Either")},bind:function(t){return this.isRightValue?t(this.value):this},ap:function(t){var e=this;return this.isRightValue?t.map((function(t){return t(e.value)})):this},leftMap:function(t){return this.isLeft()?V(t(this.value)):this},isRight:function(){return this.isRightValue},isLeft:function(){return!this.isRight()},right:function(){if(this.isRightValue)return this.value;throw new Error("Cannot call right() on a Left.")},left:function(){if(this.isRightValue)throw new Error("Cannot call left() on a Right.");return this.value},foldLeft:function(t){return this.toMaybe().toList().foldLeft(t)},foldRight:function(t){return this.toMaybe().toList().foldRight(t)},cata:function(t,e){return this.isRightValue?e(this.value):t(this.value)},catchMap:function(t){return this.isRight()?this:t(this.value)},swap:function(){return this.isRight()?V(this.value):z(this.value)},forEach:function(t){this.cata(o,t)},forEachLeft:function(t){this.cata(t,o)},equals:function(t){return B.isOfType(t)&&this.cata((function(e){return t.cata(h(e),f)}),(function(e){return t.cata(f,h(e))}))},bimap:function(t,e){return this.isRightValue?this.map(e):this.leftMap(t)},toMaybe:function(){return this.isRight()?M(this.value):D()},toValidation:function(){return this.isRight()?j(this.value):L(this.value)},toString:function(){return this.cata((function(t){return"Left("+t+")"}),(function(t){return"Right("+t+")"}))},toPromise:function(){return this.cata((function(t){return Promise.reject(t)}),(function(t){return Promise.resolve(t)}))},inspect:function(){return this.toString()}},B.prototype.fold=B.prototype.cata,B.fn.init.prototype=B.fn,e(B,"Either"),e(B.fn.init,"Either"),B.isInstance=n("Either"),B.isOfType=i("Either");var H=t.Reader=function(t){return new H.fn.init(t)};H.of=function(t){return H((function(e){return t}))},H.ask=function(){return H(l)},H.fn=H.prototype={init:function(t){this.f=t,e(this,"Reader")},run:function(t){return this.f(t)},bind:function(t){var e=this;return H((function(n){return t(e.run(n)).run(n)}))},ap:function(t){var e=this;return t.bind((function(t){return H((function(n){return t(e.run(n))}))}))},map:function(t){var e=this;return H((function(n){return t(e.run(n))}))},local:function(t){var e=this;return H((function(n){return e.run(t(n))}))}},H.fn.init.prototype=H.fn,e(H,"Reader"),e(H.fn.init,"Reader"),H.isInstance=n("Reader"),H.isOfType=i("Reader");var q=t.Free={},$=q.Suspend=t.Suspend=function(t){return new q.fn.init(t,!0)},Q=q.Return=t.Return=function(t){return new q.fn.init(t,!1)};function W(t){return new W.fn.init(t)}function G(t){(function(t){t.prototype.flatMap=t.prototype.chain=t.prototype.bind,t.pure=t.unit=t.of,t.prototype.of=t.of,u(t.prototype.append)&&(t.prototype.concat=t.prototype.append),t.prototype.point=t.prototype.pure=t.prototype.unit=t.prototype.of})(t),function(t){u(t.prototype.filter)&&(t.prototype.filterNot=function(t){return this.filter((function(e){return!t(e)}))})}(t),function(t){t.prototype.join=function(){return this.flatMap(l)},t.map2=function(t){return function(e,n){return e.flatMap((function(e){return n.map((function(n){return t(e,n)}))}))}}}(t),function(t){u(t.prototype.map)||(t.prototype.map=function(t){return this.bind(c(this.of,t))})}(t),function(t){t.prototype.takeLeft=function(t){return b(this,t,(function(t,e){return t}))},t.prototype.takeRight=function(t){return b(this,t,(function(t,e){return e}))}}(t),function(t){u(t.prototype.toArray)&&(t.prototype.every=t.prototype.forall=function(t){return this.toArray().every(t)},t.prototype.exists=function(t){return this.toArray().some(t)})}(t),function(t){["equals","map","ap","chain"].filter((function(e){return u(t.prototype[e])})).forEach((function(e){t.prototype["fantasy-land/"+e]=t.prototype[e]}))}(t),function(t){u(t.prototype.toArray)&&(t.prototype[Symbol.iterator]=function(){return this.toArray()[Symbol.iterator]()})}(t),function(t){u(t.prototype.toArray)&&(t.prototype.to=function(t){return t(this)})}(t)}return q.of=function(t){return Q(t)},q.liftF=function(t){return u(t)?$(c(Q,t)):$(t.map(Q))},q.fn=q.prototype={init:function(t,n){this.isSuspend=n,n?this.functor=t:this.val=t,e(this,"Free")},run:function(){return this.go((function(t){return t()}))},bind:function(t){return this.isSuspend?u(this.functor)?$(c((function(e){return e.bind(t)}),this.functor)):$(this.functor.map((function(e){return e.bind(t)}))):t(this.val)},ap:function(t){return this.bind((function(e){return t.map((function(t){return t(e)}))}))},resume:function(){return this.isSuspend?V(this.functor):z(this.val)},go1:function(t){return function e(n){return n.resume().cata((function(n){return e(t(n))}),l)}(this)},go:function(t){for(var e=this.resume();e.isLeft();){var n=t(e.left());e=n.resume()}return e.right()}},q.fn.init.prototype=q.fn,e(q,"Free"),e(q.fn.init,"Free"),q.isInstance=n("Free"),q.isOfType=i("Free"),t.Identity=W,W.of=function(t){return new W(t)},(W.fn=W.prototype={init:function(t){this.val=t,e(this,"Identity")},bind:function(t){return t(this.val)},get:function(){return this.val},forEach:function(t){t(this.val)},equals:function(t){return W.isOfType(t)&&h(this.get())(t.get())},contains:function(t){return d(this.val,t)},toString:function(){return"Identity("+this.val+")"},inspect:function(){return this.toString()},ap:function(t){var e=this.val;return t.map((function(t){return t(e)}))},toArray:function(){return[this.get()]},toList:function(){return k(this.get(),w)},toSet:function(){return new Set(this)}}).init.prototype=W.fn,e(W,"Identity"),e(W.fn.init,"Identity"),W.isInstance=n("Identity"),W.isOfType=i("Identity"),G(U),G(B),G(I),G(F),G(A),G(k),G(R),G(H),G(q),G(W),t})?i.call(e,n,e,t):i)||(t.exports=r)},VvXq:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=function(t){a(n,t);var e=c(n);function n(t,i){var r;return C(this,n),(r=e.call(this,t,i)).scheduler=t,r.work=i,r}return w(n,[{key:"requestAsyncId",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return null!==i&&i>0?o(h(n.prototype),"requestAsyncId",this).call(this,t,e,i):(t.actions.push(this),t.scheduled||(t.scheduled=requestAnimationFrame((function(){return t.flush(null)}))))}},{key:"recycleAsyncId",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;if(null!==i&&i>0||null===i&&this.delay>0)return o(h(n.prototype),"recycleAsyncId",this).call(this,t,e,i);0===t.actions.length&&(cancelAnimationFrame(e),t.scheduled=void 0)}}]),n}(n("EWqr").a),r=new(function(t){a(n,t);var e=c(n);function n(){return C(this,n),e.apply(this,arguments)}return w(n,[{key:"flush",value:function(t){this.active=!0,this.scheduled=void 0;var e,n=this.actions,i=-1,r=n.length;t=t||n.shift();do{if(e=t.execute(t.state,t.delay))break}while(++i visible",Object(y.e)("200ms cubic-bezier(0, 0, 0.2, 1)",Object(y.h)([Object(y.l)({opacity:0,transform:"scale(0)",offset:0}),Object(y.l)({opacity:.5,transform:"scale(0.99)",offset:.5}),Object(y.l)({opacity:1,transform:"scale(1)",offset:1})]))),Object(y.m)("* => hidden",Object(y.e)("100ms cubic-bezier(0, 0, 0.2, 1)",Object(y.l)({opacity:0})))])},O=Object(f.f)({passive:!0}),k=new a.s("mat-tooltip-scroll-strategy"),T={provide:k,deps:[i.c],useFactory:function(t){return function(){return t.scrollStrategies.reposition({scrollThrottle:20})}}},S=new a.s("mat-tooltip-default-options",{providedIn:"root",factory:function(){return{showDelay:0,hideDelay:0,touchendHideDelay:1500}}}),E=function(){var t=function(){function t(e,n,i,r,o,a,s,c,u,l,h){var f=this;C(this,t),this._overlay=e,this._elementRef=n,this._scrollDispatcher=i,this._viewContainerRef=r,this._ngZone=o,this._platform=a,this._ariaDescriber=s,this._focusMonitor=c,this._dir=l,this._defaultOptions=h,this._position="below",this._disabled=!1,this._viewInitialized=!1,this._pointerExitEventsInitialized=!1,this.showDelay=this._defaultOptions.showDelay,this.hideDelay=this._defaultOptions.hideDelay,this.touchGestures="auto",this._message="",this._passiveListeners=[],this._destroyed=new b.b,this._handleKeydown=function(t){f._isTooltipVisible()&&t.keyCode===d.f&&!Object(d.r)(t)&&(t.preventDefault(),t.stopPropagation(),f._ngZone.run((function(){return f.hide(0)})))},this._scrollStrategy=u,h&&(h.position&&(this.position=h.position),h.touchGestures&&(this.touchGestures=h.touchGestures)),o.runOutsideAngular((function(){n.nativeElement.addEventListener("keydown",f._handleKeydown)}))}return w(t,[{key:"ngAfterViewInit",value:function(){var t=this;this._viewInitialized=!0,this._setupPointerEnterEventsIfNeeded(),this._focusMonitor.monitor(this._elementRef).pipe(Object(g.a)(this._destroyed)).subscribe((function(e){e?"keyboard"===e&&t._ngZone.run((function(){return t.show()})):t._ngZone.run((function(){return t.hide(0)}))}))}},{key:"ngOnDestroy",value:function(){var t=this._elementRef.nativeElement;clearTimeout(this._touchstartTimeout),this._overlayRef&&(this._overlayRef.dispose(),this._tooltipInstance=null),t.removeEventListener("keydown",this._handleKeydown),this._passiveListeners.forEach((function(e){var n=m(e,2),i=n[0],r=n[1];t.removeEventListener(i,r,O)})),this._passiveListeners.length=0,this._destroyed.next(),this._destroyed.complete(),this._ariaDescriber.removeDescription(t,this.message),this._focusMonitor.stopMonitoring(t)}},{key:"show",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.showDelay;if(!this.disabled&&this.message&&(!this._isTooltipVisible()||this._tooltipInstance._showTimeoutId||this._tooltipInstance._hideTimeoutId)){var n=this._createOverlay();this._detach(),this._portal=this._portal||new p.d(x,this._viewContainerRef),this._tooltipInstance=n.attach(this._portal).instance,this._tooltipInstance.afterHidden().pipe(Object(g.a)(this._destroyed)).subscribe((function(){return t._detach()})),this._setTooltipClass(this._tooltipClass),this._updateTooltipMessage(),this._tooltipInstance.show(e)}}},{key:"hide",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.hideDelay;this._tooltipInstance&&this._tooltipInstance.hide(t)}},{key:"toggle",value:function(){this._isTooltipVisible()?this.hide():this.show()}},{key:"_isTooltipVisible",value:function(){return!!this._tooltipInstance&&this._tooltipInstance.isVisible()}},{key:"_createOverlay",value:function(){var t=this;if(this._overlayRef)return this._overlayRef;var e=this._scrollDispatcher.getAncestorScrollContainers(this._elementRef),n=this._overlay.position().flexibleConnectedTo(this._elementRef).withTransformOriginOn(".mat-tooltip").withFlexibleDimensions(!1).withViewportMargin(8).withScrollableContainers(e);return n.positionChanges.pipe(Object(g.a)(this._destroyed)).subscribe((function(e){t._tooltipInstance&&e.scrollableViewProperties.isOverlayClipped&&t._tooltipInstance.isVisible()&&t._ngZone.run((function(){return t.hide(0)}))})),this._overlayRef=this._overlay.create({direction:this._dir,positionStrategy:n,panelClass:"mat-tooltip-panel",scrollStrategy:this._scrollStrategy()}),this._updatePosition(),this._overlayRef.detachments().pipe(Object(g.a)(this._destroyed)).subscribe((function(){return t._detach()})),this._overlayRef}},{key:"_detach",value:function(){this._overlayRef&&this._overlayRef.hasAttached()&&this._overlayRef.detach(),this._tooltipInstance=null}},{key:"_updatePosition",value:function(){var t=this._overlayRef.getConfig().positionStrategy,e=this._getOrigin(),n=this._getOverlayPosition();t.withPositions([Object.assign(Object.assign({},e.main),n.main),Object.assign(Object.assign({},e.fallback),n.fallback)])}},{key:"_getOrigin",value:function(){var t,e=!this._dir||"ltr"==this._dir.value,n=this.position;"above"==n||"below"==n?t={originX:"center",originY:"above"==n?"top":"bottom"}:"before"==n||"left"==n&&e||"right"==n&&!e?t={originX:"start",originY:"center"}:("after"==n||"right"==n&&e||"left"==n&&!e)&&(t={originX:"end",originY:"center"});var i=this._invertPosition(t.originX,t.originY);return{main:t,fallback:{originX:i.x,originY:i.y}}}},{key:"_getOverlayPosition",value:function(){var t,e=!this._dir||"ltr"==this._dir.value,n=this.position;"above"==n?t={overlayX:"center",overlayY:"bottom"}:"below"==n?t={overlayX:"center",overlayY:"top"}:"before"==n||"left"==n&&e||"right"==n&&!e?t={overlayX:"end",overlayY:"center"}:("after"==n||"right"==n&&e||"left"==n&&!e)&&(t={overlayX:"start",overlayY:"center"});var i=this._invertPosition(t.overlayX,t.overlayY);return{main:t,fallback:{overlayX:i.x,overlayY:i.y}}}},{key:"_updateTooltipMessage",value:function(){var t=this;this._tooltipInstance&&(this._tooltipInstance.message=this.message,this._tooltipInstance._markForCheck(),this._ngZone.onMicrotaskEmpty.pipe(Object(v.a)(1),Object(g.a)(this._destroyed)).subscribe((function(){t._tooltipInstance&&t._overlayRef.updatePosition()})))}},{key:"_setTooltipClass",value:function(t){this._tooltipInstance&&(this._tooltipInstance.tooltipClass=t,this._tooltipInstance._markForCheck())}},{key:"_invertPosition",value:function(t,e){return"above"===this.position||"below"===this.position?"top"===e?e="bottom":"bottom"===e&&(e="top"):"end"===t?t="start":"start"===t&&(t="end"),{x:t,y:e}}},{key:"_setupPointerEnterEventsIfNeeded",value:function(){var t=this;!this._disabled&&this.message&&this._viewInitialized&&!this._passiveListeners.length&&(this._platformSupportsMouseEvents()?this._passiveListeners.push(["mouseenter",function(){t._setupPointerExitEventsIfNeeded(),t.show()}]):"off"!==this.touchGestures&&(this._disableNativeGesturesIfNecessary(),this._passiveListeners.push(["touchstart",function(){t._setupPointerExitEventsIfNeeded(),clearTimeout(t._touchstartTimeout),t._touchstartTimeout=setTimeout((function(){return t.show()}),500)}])),this._addListeners(this._passiveListeners))}},{key:"_setupPointerExitEventsIfNeeded",value:function(){var t,e=this;if(!this._pointerExitEventsInitialized){this._pointerExitEventsInitialized=!0;var n=[];if(this._platformSupportsMouseEvents())n.push(["mouseleave",function(){return e.hide()}]);else if("off"!==this.touchGestures){this._disableNativeGesturesIfNecessary();var i=function(){clearTimeout(e._touchstartTimeout),e.hide(e._defaultOptions.touchendHideDelay)};n.push(["touchend",i],["touchcancel",i])}this._addListeners(n),(t=this._passiveListeners).push.apply(t,n)}}},{key:"_addListeners",value:function(t){var e=this;t.forEach((function(t){var n=m(t,2),i=n[0],r=n[1];e._elementRef.nativeElement.addEventListener(i,r,O)}))}},{key:"_platformSupportsMouseEvents",value:function(){return!this._platform.IOS&&!this._platform.ANDROID}},{key:"_disableNativeGesturesIfNecessary",value:function(){var t=this.touchGestures;if("off"!==t){var e=this._elementRef.nativeElement,n=e.style;("on"===t||"INPUT"!==e.nodeName&&"TEXTAREA"!==e.nodeName)&&(n.userSelect=n.msUserSelect=n.webkitUserSelect=n.MozUserSelect="none"),"on"!==t&&e.draggable||(n.webkitUserDrag="none"),n.touchAction="none",n.webkitTapHighlightColor="transparent"}}},{key:"position",get:function(){return this._position},set:function(t){t!==this._position&&(this._position=t,this._overlayRef&&(this._updatePosition(),this._tooltipInstance&&this._tooltipInstance.show(0),this._overlayRef.updatePosition()))}},{key:"disabled",get:function(){return this._disabled},set:function(t){this._disabled=Object(l.c)(t),this._disabled?this.hide(0):this._setupPointerEnterEventsIfNeeded()}},{key:"message",get:function(){return this._message},set:function(t){var e=this;this._ariaDescriber.removeDescription(this._elementRef.nativeElement,this._message),this._message=null!=t?(""+t).trim():"",!this._message&&this._isTooltipVisible()?this.hide(0):(this._setupPointerEnterEventsIfNeeded(),this._updateTooltipMessage(),this._ngZone.runOutsideAngular((function(){Promise.resolve().then((function(){e._ariaDescriber.describe(e._elementRef.nativeElement,e.message)}))})))}},{key:"tooltipClass",get:function(){return this._tooltipClass},set:function(t){this._tooltipClass=t,this._tooltipInstance&&this._setTooltipClass(this._tooltipClass)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(a.Ob(i.c),a.Ob(a.l),a.Ob(c.f),a.Ob(a.R),a.Ob(a.B),a.Ob(f.a),a.Ob(r.c),a.Ob(r.h),a.Ob(k),a.Ob(u.b,8),a.Ob(S,8))},t.\u0275dir=a.Jb({type:t,selectors:[["","matTooltip",""]],hostAttrs:[1,"mat-tooltip-trigger"],inputs:{showDelay:["matTooltipShowDelay","showDelay"],hideDelay:["matTooltipHideDelay","hideDelay"],touchGestures:["matTooltipTouchGestures","touchGestures"],position:["matTooltipPosition","position"],disabled:["matTooltipDisabled","disabled"],message:["matTooltip","message"],tooltipClass:["matTooltipClass","tooltipClass"]},exportAs:["matTooltip"]}),t}(),x=function(){var t=function(){function t(e,n){C(this,t),this._changeDetectorRef=e,this._breakpointObserver=n,this._visibility="initial",this._closeOnInteraction=!1,this._onHide=new b.b,this._isHandset=this._breakpointObserver.observe(h.b.Handset)}return w(t,[{key:"show",value:function(t){var e=this;this._hideTimeoutId&&(clearTimeout(this._hideTimeoutId),this._hideTimeoutId=null),this._closeOnInteraction=!0,this._showTimeoutId=setTimeout((function(){e._visibility="visible",e._showTimeoutId=null,e._markForCheck()}),t)}},{key:"hide",value:function(t){var e=this;this._showTimeoutId&&(clearTimeout(this._showTimeoutId),this._showTimeoutId=null),this._hideTimeoutId=setTimeout((function(){e._visibility="hidden",e._hideTimeoutId=null,e._markForCheck()}),t)}},{key:"afterHidden",value:function(){return this._onHide}},{key:"isVisible",value:function(){return"visible"===this._visibility}},{key:"ngOnDestroy",value:function(){this._onHide.complete()}},{key:"_animationStart",value:function(){this._closeOnInteraction=!1}},{key:"_animationDone",value:function(t){var e=t.toState;"hidden"!==e||this.isVisible()||this._onHide.next(),"visible"!==e&&"hidden"!==e||(this._closeOnInteraction=!0)}},{key:"_handleBodyInteraction",value:function(){this._closeOnInteraction&&this.hide(0)}},{key:"_markForCheck",value:function(){this._changeDetectorRef.markForCheck()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(a.Ob(a.h),a.Ob(h.a))},t.\u0275cmp=a.Ib({type:t,selectors:[["mat-tooltip-component"]],hostAttrs:["aria-hidden","true"],hostVars:2,hostBindings:function(t,e){1&t&&a.bc("click",(function(){return e._handleBodyInteraction()}),!1,a.Bc),2&t&&a.Lc("zoom","visible"===e._visibility?1:null)},decls:3,vars:7,consts:[[1,"mat-tooltip",3,"ngClass"]],template:function(t,e){var n;1&t&&(a.Ub(0,"div",0),a.bc("@state.start",(function(){return e._animationStart()}))("@state.done",(function(t){return e._animationDone(t)})),a.gc(1,"async"),a.Qc(2),a.Tb()),2&t&&(a.Gb("mat-tooltip-handset",null==(n=a.hc(1,5,e._isHandset))?null:n.matches),a.mc("ngClass",e.tooltipClass)("@state",e._visibility),a.Cb(2),a.Rc(e.message))},directives:[o.l],pipes:[o.b],styles:[".mat-tooltip-panel{pointer-events:none !important}.mat-tooltip{color:#fff;border-radius:4px;margin:14px;max-width:250px;padding-left:8px;padding-right:8px;overflow:hidden;text-overflow:ellipsis}.cdk-high-contrast-active .mat-tooltip{outline:solid 1px}.mat-tooltip-handset{margin:24px;padding-left:16px;padding-right:16px}\n"],encapsulation:2,data:{animation:[_.tooltipState]},changeDetection:0}),t}(),P=function(){var t=function t(){C(this,t)};return t.\u0275mod=a.Mb({type:t}),t.\u0275inj=a.Lb({factory:function(e){return new(e||t)},providers:[T],imports:[[r.a,o.c,i.f,s.j],s.j,c.c]}),t}()},Wg7D:function(t,e,n){"use strict";n.d(e,"a",(function(){return s}));var i=n("5uGe"),r=n("Efrr");n("uCWR");var o={leading:!0,trailing:!1};function s(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:r.a,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:o;return function(i){return i.lift(new u(t,e,n.leading,n.trailing))}}var u=function(){function t(e,n,i,r){C(this,t),this.duration=e,this.scheduler=n,this.leading=i,this.trailing=r}return w(t,[{key:"call",value:function(t,e){return e.subscribe(new l(t,this.duration,this.scheduler,this.leading,this.trailing))}}]),t}(),l=function(t){a(n,t);var e=c(n);function n(t,i,r,o,a){var s;return C(this,n),(s=e.call(this,t)).duration=i,s.scheduler=r,s.leading=o,s.trailing=a,s._hasTrailingValue=!1,s._trailingValue=null,s}return w(n,[{key:"_next",value:function(t){this.throttled?this.trailing&&(this._trailingValue=t,this._hasTrailingValue=!0):(this.add(this.throttled=this.scheduler.schedule(d,this.duration,{subscriber:this})),this.leading?this.destination.next(t):this.trailing&&(this._trailingValue=t,this._hasTrailingValue=!0))}},{key:"_complete",value:function(){this._hasTrailingValue?(this.destination.next(this._trailingValue),this.destination.complete()):this.destination.complete()}},{key:"clearThrottle",value:function(){var t=this.throttled;t&&(this.trailing&&this._hasTrailingValue&&(this.destination.next(this._trailingValue),this._trailingValue=null,this._hasTrailingValue=!1),t.unsubscribe(),this.remove(t),this.throttled=null)}}]),n}(i.a);function d(t){t.subscriber.clearThrottle()}},WncL:function(t,e,n){"use strict";n.d(e,"a",(function(){return P}));var i=n("D57K"),r=n("gxtV"),o=n("zqNl"),a=n("HM3f"),s=n("YtkY"),c=n("wqq/"),u=n("+Px6"),l=n("qAYy"),d=n("rxqU"),h=n("sxqi"),f=n("vYTc"),p=n("kZht"),b=n("An66"),g=n("1etq"),v=n("NxuZ"),y=n("ZEHW"),_=n("9BXW"),O=n("aDqW");function k(t,e){1&t&&(p.Ub(0,"h2",1),p.Qc(1),p.gc(2,"translate"),p.Pb(3,"fa-icon",7),p.Tb()),2&t&&(p.Cb(1),p.Sc(" ",p.hc(2,1,"HEADING.FAVORITES")," "))}function T(t,e){if(1&t){var n=p.Vb();p.Ub(0,"market-preview-favorite",10),p.bc("click",(function(){p.Ec(n);var t=e.$implicit;return p.fc(3).selectMarket(t)})),p.gc(1,"async"),p.Tb()}if(2&t){var i,r=e.$implicit,o=p.fc(3);p.mc("ticker",r),p.Db("active",(null==(i=p.hc(1,2,o.selected$))?null:i.symbol)===r.product_id)}}function S(t,e){if(1&t&&(p.Ub(0,"div",8),p.Oc(1,T,2,4,"market-preview-favorite",9),p.Tb()),2&t){var n=p.fc().ngIf,i=p.fc();p.Cb(1),p.mc("ngForOf",n.values())("ngForTrackBy",i.trackByProductId)}}function E(t,e){if(1&t&&(p.Sb(0),p.Oc(1,k,4,3,"h2",5),p.Oc(2,S,2,2,"div",6),p.Rb()),2&t){var n=e.ngIf;p.Cb(1),p.mc("ngIf",n.size>0),p.Cb(1),p.mc("ngIf",n.size>0)}}function x(t,e){if(1&t){var n=p.Vb();p.Ub(0,"market-preview-compact",11),p.bc("click",(function(){p.Ec(n);var t=e.$implicit;return p.fc().selectMarket(t)})),p.gc(1,"async"),p.gc(2,"async"),p.Tb()}if(2&t){var i,r=e.$implicit,o=p.fc();p.mc("ticker",r)("maxVol",p.hc(1,3,o.maxVol$)),p.Db("active",(null==(i=p.hc(2,5,o.selected$))?null:i.symbol)===r.product_id)}}var P=function(){var t=function(){function t(e,n){C(this,t),this.store=e,this.market=n,this.selected$=this.store.pipe(Object(o.m)(u.n)),this.futures$=this.store.pipe(Object(o.m)(l.g)),this.favorites$=this.store.pipe(Object(o.m)(d.p)),this.tickers$=this.futures$.pipe(Object(s.a)((function(t){return t.valueSeq().sortBy((function(t){return t.volumeQuote})).reverse()})),Object(c.a)(1)),this.maxVol$=this.tickers$.pipe(Object(s.a)((function(t){var e;return null!==(e=t.map((function(t){return t.volumeQuote})).max())&&void 0!==e?e:1}))),this.favoriteTickers$=Object(a.a)([this.favorites$,this.tickers$]).pipe(Object(s.a)((function(t){var e=m(t,2),n=e[0];return e[1].filter((function(t){return n.has(Object(f.i)(t))})).toList()})))}return w(t,[{key:"trackByProductId",value:function(t,e){return e.product_id}},{key:"selectMarket",value:function(t){this.market.navigateToMarket(t.product_id)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(p.Ob(o.b),p.Ob(h.a))},t.\u0275cmp=p.Ib({type:t,selectors:[["market-preview-panel"]],decls:9,vars:10,consts:[[4,"ngIf"],["subheading",""],["icon","chart-candlestick","size","lg"],[1,"open"],[3,"ticker","maxVol","click",4,"ngFor","ngForOf","ngForTrackBy"],["subheading","",4,"ngIf"],["subheading","","class","favorites",4,"ngIf"],["icon","star-filled","size","lg"],["subheading","",1,"favorites"],[3,"ticker","click",4,"ngFor","ngForOf","ngForTrackBy"],[3,"ticker","click"],[3,"ticker","maxVol","click"]],template:function(t,e){if(1&t&&(p.Oc(0,E,3,2,"ng-container",0),p.gc(1,"async"),p.Ub(2,"h2",1),p.Pb(3,"fa-icon",2),p.Qc(4),p.gc(5,"translate"),p.Tb(),p.Ub(6,"div",3),p.Oc(7,x,3,7,"market-preview-compact",4),p.gc(8,"async"),p.Tb()),2&t){var n=null;p.mc("ngIf",p.hc(1,4,e.favoriteTickers$)),p.Cb(4),p.Sc(" ",p.hc(5,6,"HEADING.OPEN_MARKETS"),"\n"),p.Cb(3),p.mc("ngForOf",null==(n=p.hc(8,8,e.tickers$))?null:n.values())("ngForTrackBy",e.trackByProductId)}},directives:[b.n,g.a,v.b,b.m,y.a,_.a],pipes:[b.b,O.d],styles:["[_nghost-%COMP%]{display:block;overflow-x:hidden;padding:var(--spacing)}h2[_ngcontent-%COMP%]{font-weight:700;margin-bottom:var(--spacing)}h2[_ngcontent-%COMP%]:not(:first-of-type){margin-top:var(--spacing-l)}h2[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{color:var(--icon-colour)}.favorites[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(auto-fill,minmax(220px,1fr));gap:var(--spacing)}@media (min-width:1441px){.favorites[_ngcontent-%COMP%]{grid-template-columns:repeat(auto-fill,minmax(280px,1fr))}}.open[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(auto-fill,minmax(220px,1fr));gap:var(--spacing)}market-preview-favorite[active=true][_ngcontent-%COMP%]{border-color:var(--brand)}market-preview-compact[active=true][_ngcontent-%COMP%]{--symbol-color:var(--link-colour)}"],changeDetection:0}),t=Object(i.d)([Object(r.a)()],t)}()},Wxxs:function(t,e,n){"use strict";n.d(e,"c",(function(){return r})),n.d(e,"b",(function(){return o})),n.d(e,"d",(function(){return a})),n.d(e,"g",(function(){return s})),n.d(e,"f",(function(){return c})),n.d(e,"e",(function(){return u})),n.d(e,"a",(function(){return l}));var i=n("zqNl"),r=Object(i.g)("Reset Verification State"),o=Object(i.g)("Check Tier"),a=Object(i.g)("Set Account Type",Object(i.l)()),s=Object(i.g)("Set Tier Status",Object(i.l)()),c=Object(i.g)("Set Temp Tier Status",Object(i.l)()),u=Object(i.g)("Set Classification",Object(i.l)()),l=Object(i.g)("Affirm UK Classification",Object(i.l)())},Wzsi:function(t,e,n){var i=n("67SP"),r=n("yBEi"),o=n("ECQc"),a=n("LxLQ"),s=n("188V"),c=n("PqQh"),u=n("HnIH"),l=n("OpOv"),d=n("nwte"),h=n("wCIf"),f=n("ZR2N"),p=n("Amke"),b=n("JgBV"),g=n("iRqU"),m=n("B9MG");function v(t,e,n){var i,r,o=t.size,a=p.getEncodedBits(e,n);for(i=0;i<15;i++)t.set(i<6?i:i<8?i+1:o-15+i,8,r=1==(a>>i&1),!0),t.set(8,i<8?o-i-1:i<9?15-i-1+1:15-i-1,r,!0);t.set(o-8,8,1,!0)}e.create=function(t,e){if(void 0===t||""===t)throw new Error("No input text");var n,p,y=o.M;return void 0!==e&&(y=o.from(e.errorCorrectionLevel,o.M),n=f.from(e.version),p=l.from(e.maskPattern),e.toSJISFunc&&r.setToSJISFunction(e.toSJISFunc)),function(t,e,n,o){var p;if(m(t))p=g.fromArray(t);else{if("string"!=typeof t)throw new Error("Invalid data");var y=e;if(!y){var _=g.rawSplit(t);y=f.getBestVersionForData(_,n)}p=g.fromString(t,y||40)}var O=f.getBestVersionForData(p,n);if(!O)throw new Error("The amount of data is too big to be stored in a QR Code");if(e){if(e=0&&s<=6&&(0===c||6===c)||c>=0&&c<=6&&(0===s||6===s)||s>=2&&s<=4&&c>=2&&c<=4,!0)}(C,e),function(t){for(var e=t.size,n=8;n=7&&function(t,e){for(var n,i,r,o=t.size,a=f.getEncodedBits(e),s=0;s<18;s++)n=Math.floor(s/3),t.set(n,i=s%3+o-8-3,r=1==(a>>s&1),!0),t.set(i,n,r,!0)}(C,e),function(t,e){for(var n=t.size,i=-1,r=n-1,o=7,a=0,s=n-1;s>0;s-=2)for(6===s&&s--;;){for(var c=0;c<2;c++)if(!t.isReserved(r,s-c)){var u=!1;a>>o&1)),t.set(r,s-c,u),-1==--o&&(a++,o=7)}if((r+=i)<0||n<=r){r-=i,i=-i;break}}}(C,k),isNaN(o)&&(o=l.getBestMask(C,v.bind(null,C,n))),l.applyMask(o,C),v(C,n,o),{modules:C,version:e,errorCorrectionLevel:n,maskPattern:o,segments:p}}(t,n,y,p)}},X0qr:function(t,e,n){"use strict";function i(t){return null!==t&&"object"==typeof t}n.d(e,"a",(function(){return i}))},XOQS:function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0});var o=n("neWc"),a=n("q+cW");e.default=function(t){function e(e){var n=t.call(this,e)||this;return n.matrix=null,n}return r(e,t),e.prototype.getBlackMatrix=function(){if(null!==this.matrix)return this.matrix;var n=this.getLuminanceSource(),i=n.getWidth(),r=n.getHeight();if(i>=e.MINIMUM_DIMENSION&&r>=e.MINIMUM_DIMENSION){var o=n.getMatrix(),s=i>>e.BLOCK_SIZE_POWER;0!=(i&e.BLOCK_SIZE_MASK)&&s++;var c=r>>e.BLOCK_SIZE_POWER;0!=(r&e.BLOCK_SIZE_MASK)&&c++;var u=e.calculateBlackPoints(o,s,c,i,r),l=new a.default(i,r);e.calculateThresholdForBlock(o,s,c,i,r,u,l),this.matrix=l}else this.matrix=t.prototype.getBlackMatrix.call(this);return this.matrix},e.prototype.createBinarizer=function(t){return new e(t)},e.calculateThresholdForBlock=function(t,n,i,r,o,a,s){for(var c=o-e.BLOCK_SIZE,u=r-e.BLOCK_SIZE,l=0;lc&&(d=c);for(var h=e.cap(l,2,i-3),f=0;fu&&(p=u);for(var b=e.cap(f,2,n-3),g=0,m=-2;m<=2;m++){var v=a[h+m];g+=v[b-2]+v[b-1]+v[b]+v[b+1]+v[b+2]}e.thresholdBlock(t,p,d,g/25,r,s)}}},e.cap=function(t,e,n){return tn?n:t},e.thresholdBlock=function(t,n,i,r,o,a){for(var s=0,c=i*o+n;sa&&(l=a);for(var d=0;ds&&(h=s);for(var f=0,p=255,b=0,g=0,m=l*r+h;gb&&(b=y)}if(b-p>e.MIN_DYNAMIC_RANGE)for(g++,m+=r;g>2*e.BLOCK_SIZE_POWER;if(b-p<=e.MIN_DYNAMIC_RANGE&&(_=p/2,u>0&&d>0)){var O=(c[u-1][d]+2*c[u][d-1]+c[u-1][d-1])/4;p
Remaining: ".concat(i,"/").concat(c+i):"")}return""}(t):t.orderPriorExecution?function(t){if(t.orderPriorExecution){var e=t.orderPriorExecution,n=e.side,i=e.symbol,r=t.amount,s=t.takerReducedQuantity,c=t.price,u="buy"===n?"Long":"Short";return"".concat(Object(a.j)(i).replace(o.b,"BTC")," ").concat(Object(a.i)(i,"short",!1)," - ").concat(u," ").concat(r," @ ").concat(c," ").concat(s?"- Reduced by: "+s:""," ").concat(t.orderPriorEdit?"(Edit caused execution)":"")}return""}(t):t.old&&t.new?function(t){var e,n;if(t.old&&t.new){var i=t.old.quantity,r=t.new.quantity,s=i!==r,c=null!==(e=t.old.limitPrice)&&void 0!==e?e:"MKT",u=null!==(n=t.new.limitPrice)&&void 0!==n?n:"MKT",l=c!==u,d=t.old.triggerPrice,h=t.new.triggerPrice,f=d!==h,p=!!t.new.triggerSignal,b=t.new.triggerSignal,g=t.new,m=g.side,v=g.symbol,y="buy"===m?"Long":"Short",_=f?", Trigger: ".concat(d," => ").concat(h):", Trigger: "+h;return"".concat(Object(a.j)(v).replace(o.b,"BTC")," ").concat(Object(a.i)(v,"short",!1)," - ").concat(y," ").concat(s?"".concat(i," => ").concat(r):r," @ ").concat(l?"".concat(c," => ").concat(u):u," ").concat(p?_:""," ").concat(b?"(".concat(b.toUpperCase(),")"):"")}return""}(t):t.orderTrigger?function(t){if(t.orderTrigger){var e=t.orderTrigger,n=e.side,i=e.quantity,r=e.symbol,s=e.limitPrice,c=e.triggerPrice,u=e.triggerSignal,l="buy"===n?"Long":"Short";return"".concat(Object(a.j)(r).replace(o.b,"BTC")," ").concat(Object(a.i)(r,"short",!1)," - ").concat(l," ").concat(i," @ ").concat(null!=s?s:"MKT"," , Trigger: ").concat(c," (").concat(null==u?void 0:u.toUpperCase(),")")}return""}(t):""}},XrPM:function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0});var o=n("ssKD"),a=n("qvG1"),s=n("unaY"),c=n("oznm");e.default=function(t){function e(e,n,i,r,o,a,s,u){var l=t.call(this,a,s)||this;if(l.yuvData=e,l.dataWidth=n,l.dataHeight=i,l.left=r,l.top=o,r+a>n||o+s>i)throw new c.default("Crop rectangle does not fit within image data.");return u&&l.reverseHorizontal(a,s),l}return r(e,t),e.prototype.getRow=function(t,e){if(t<0||t>=this.getHeight())throw new c.default("Requested row is outside the image: "+t);var n=this.getWidth();return(null==e||e.lengthi&&(r=l);i=r,e=0;for(var s=0,c=0,u=0;ui&&(c|=1<0;u++){var l;if((l=t[u])>i&&(e--,2*l>=s))return-1}return c}}while(e>3);return-1},e.patternToChar=function(t){for(var n=0;n="A"&&o<="Z"))throw new s.default;a=String.fromCharCode(o.charCodeAt(0)+32);break;case"$":if(!(o>="A"&&o<="Z"))throw new s.default;a=String.fromCharCode(o.charCodeAt(0)-64);break;case"%":if(o>="A"&&o<="E")a=String.fromCharCode(o.charCodeAt(0)-38);else if(o>="F"&&o<="J")a=String.fromCharCode(o.charCodeAt(0)-11);else if(o>="K"&&o<="O")a=String.fromCharCode(o.charCodeAt(0)+16);else if(o>="P"&&o<="T")a=String.fromCharCode(o.charCodeAt(0)+43);else if("U"===o)a="\0";else if("V"===o)a="@";else if("W"===o)a="`";else{if("X"!==o&&"Y"!==o&&"Z"!==o)throw new s.default;a="\x7f"}break;case"/":if(o>="A"&&o<="O")a=String.fromCharCode(o.charCodeAt(0)-32);else{if("Z"!==o)throw new s.default;a=":"}}n+=a,i++}else n+=r}return n},e.ALPHABET_STRING="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ-. $/+%",e.CHARACTER_ENCODINGS=[52,289,97,352,49,304,112,37,292,100,265,73,328,25,280,88,13,268,76,28,259,67,322,19,274,82,7,262,70,22,385,193,448,145,400,208,133,388,196,168,162,138,42],e.ASTERISK_ENCODING=148,e}(u.default)},YtkY:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("5uGe");function r(t,e){return function(n){if("function"!=typeof t)throw new TypeError("argument is not a function. Are you looking for `mapTo()`?");return n.lift(new o(t,e))}}var o=function(){function t(e,n){C(this,t),this.project=e,this.thisArg=n}return w(t,[{key:"call",value:function(t,e){return e.subscribe(new s(t,this.project,this.thisArg))}}]),t}(),s=function(t){a(n,t);var e=c(n);function n(t,i,r){var o;return C(this,n),(o=e.call(this,t)).project=i,o.count=0,o.thisArg=r||l(o),o}return w(n,[{key:"_next",value:function(t){var e;try{e=this.project.call(this.thisArg,t,this.count++)}catch(n){return void this.destination.error(n)}this.destination.next(e)}}]),n}(i.a)},Yu3e:function(t,e){function n(t,e,n,i){var r,o=null==(r=i)||"number"==typeof r||"boolean"==typeof r?i:n(i),a=e.get(o);return void 0===a&&(a=t.call(this,i),e.set(o,a)),a}function i(t,e,n){var i=Array.prototype.slice.call(arguments,3),r=n(i),o=e.get(r);return void 0===o&&(o=t.apply(this,i),e.set(r,o)),o}function r(t,e,n,i,r){return n.bind(e,t,i,r)}function o(t,e){return r(t,this,1===t.length?n:i,e.cache.create(),e.serializer)}function a(){return JSON.stringify(arguments)}function s(){this.cache=Object.create(null)}s.prototype.has=function(t){return t in this.cache},s.prototype.get=function(t){return this.cache[t]},s.prototype.set=function(t,e){this.cache[t]=e};var c={create:function(){return new s}};t.exports=function(t,e){return(e&&e.strategy?e.strategy:o)(t,{cache:e&&e.cache?e.cache:c,serializer:e&&e.serializer?e.serializer:a})},t.exports.strategies={variadic:function(t,e){return r(t,this,i,e.cache.create(),e.serializer)},monadic:function(t,e){return r(t,this,n,e.cache.create(),e.serializer)}}},YwYi:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("vI0g"),r=n("ssKD"),o=n("oznm");e.default=function(){function t(t,e){if(0===e.length)throw new o.default;this.field=t;var n=e.length;if(n>1&&0===e[0]){for(var i=1;ia.length){var s=n;n=a,a=s}var c=new Int32Array(a.length),u=a.length-n.length;r.default.arraycopy(a,0,c,0,u);for(var l=u;l=t.getDegree()&&!i.isZero();){var s=i.getDegree()-t.getDegree(),c=e.multiply(i.getCoefficient(i.getDegree()),a),u=t.multiplyByMonomial(s,c),l=e.buildMonomial(s,c);n=n.addOrSubtract(l),i=i.addOrSubtract(u)}return[n,i]},t.prototype.toString=function(){for(var t="",e=this.getDegree();e>=0;e--){var n=this.getCoefficient(e);if(0!==n){if(n<0?(t+=" - ",n=-n):t.length>0&&(t+=" + "),0===e||1!==n){var i=this.field.log(n);0===i?t+="1":1===i?t+="a":(t+="a^",t+=i)}0!==e&&(1===e?t+="x":(t+="x^",t+=e))}}return t},t}()},YyhG:function(t,e,n){"use strict";n.d(e,"b",(function(){return m})),n.d(e,"k",(function(){return k})),n.d(e,"c",(function(){return w})),n.d(e,"l",(function(){return T})),n.d(e,"o",(function(){return S})),n.d(e,"d",(function(){return E})),n.d(e,"n",(function(){return x})),n.d(e,"m",(function(){return P})),n.d(e,"f",(function(){return A})),n.d(e,"g",(function(){return I})),n.d(e,"h",(function(){return M})),n.d(e,"j",(function(){return D})),n.d(e,"i",(function(){return R})),n.d(e,"e",(function(){return j})),n.d(e,"p",(function(){return L})),n.d(e,"a",(function(){return U})),n.d(e,"q",(function(){return B}));var i=n("zqNl"),r=n("og7C"),o=n("p5wL"),a=n("lx5p"),s=n("a1kK"),c=n("h3eB"),u=n("+Px6"),l=n("rxqU"),d=n("Gbfs"),h=n("7KkP"),f=n("TYVA"),p=n("J/3c"),b={positions:[],orders:Object(r.b)(),fills:Object(r.b)()},g=Object(i.i)(b,Object(i.k)(c.j,(function(){return b})),Object(i.k)(c.m,(function(t,e){var n=e.positions;return Object(o.b)(n,t,"positions")})),Object(i.k)(c.l,(function(t,e){var n=e.orders;return Object(o.b)(Object(o.c)(n,"order_id"),t,"orders")})),Object(i.k)(c.b,(function(t,e){var n=e.order;return Object(o.a)(Object(r.b)([[n.order_id,n]]),t,"orders")})),Object(i.k)(c.i,(function(t,e){var n=e.orderId;return Object(o.b)(t.orders.remove(n),t,"orders")})),Object(i.k)(c.k,(function(t,e){var n=e.fills;return Object(o.b)(Object(o.c)(n,"fill_id"),t,"fills")})),Object(i.k)(c.a,(function(t,e){var n=e.fills;return Object(o.a)(Object(o.c)(n,"fill_id"),t,"fills")})));function m(t,e){return g(t,e)}var v=Object(i.h)("trades"),y=Object(i.j)(v,(function(t){return t.positions})),_=Object(i.j)(v,(function(t){return t.orders})),O=Object(i.j)(v,(function(t){return t.fills})),k=Object(i.j)(y,u.d,u.j,u.r,l.a,l.r,u.g,u.k,(function(t,e,n,i,r,o,a,c,u){var l,d=Object(s.f)(n,t,"instrument").map(Object(h.c)(e,o)).map(Object(h.d)(a,c,i));return(null==u?void 0:u.ignorePairFilter)?d:null!==(l=null==r?void 0:r.activityPairFilterOn)&&void 0!==l&&l?d.filter(Object(s.h)(i)):d})),w=Object(i.j)(_,u.r,(function(t,e){return t.filter((function(t){return"limit"===t.type})).filter((function(t){return t.instrument===e})).map((function(t){return t.limit_price})).toSet()})),C=Object(i.j)(_,u.d,u.j,u.r,l.a,l.r,(function(t,e,n,i,r,o,c){var u,l=Object(s.d)(n,t,"instrument").map(Object(h.b)(e,o)).toOrderedMap().sortBy(Object(a.F)("time"),a.i);return(null==c?void 0:c.ignorePairFilter)?l:null!==(u=null==r?void 0:r.activityPairFilterOn)&&void 0!==u&&u?l.filter(Object(s.h)(i)):l})),T=Object(i.j)(C,(function(t){return t.filter((function(t){return"limit"===t.type}))})),S=Object(i.j)(C,(function(t){return t.filter((function(t){return"limit"!==t.type}))})),E=Object(i.j)(O,u.d,u.j,u.r,l.a,l.r,(function(t,e,n,i,r,o,c){var u,l=Object(s.d)(n,t,"instrument").map(Object(h.a)(e,o)).toOrderedMap().sortBy(Object(a.F)("time"),a.i);return(null==c?void 0:c.ignorePairFilter)?l:null!==(u=null==r?void 0:r.activityPairFilterOn)&&void 0!==u&&u?l.filter(Object(s.h)(i)):l})),x=Object(i.j)(l.r,u.t,u.n,(function(t,e,n){return"futures_inverse"===(null==n?void 0:n.type)?""+e.parts.currencies.quote:""+e.parts.currencies.base})),P=Object(i.j)(l.r,u.t,u.d,(function(t,e,n){var i="order"===t.trading,r="flex"===e.parts.family,o=n.get(r?e.parts.currencies.base:e.collateral);return i&&!r?d.a:o})),A=Object(i.j)(u.r,C,(function(t,e){return e.filter((function(e){return e.instrument===t}))})),I=Object(i.j)(u.r,k,(function(t,e){return e.find((function(e){return e.instrument===t}))})),M=Object(i.j)(T,(function(t){return t.size})),D=Object(i.j)(S,(function(t){return t.size})),R=Object(i.j)(y,(function(t){return t.length})),j=Object(i.j)(k,(function(t){return t.filter((function(t){return"mc"===Object(f.f)(t.instrument)}))})),L=Object(i.j)(I,j,p.l,u.o,(function(t,e,n,i){return n&&function(t,e,n,i){var r=n.margin_equity&&n.mm/n.margin_equity;if(i.cross){var o=n.cv||0,a=e.filter((function(t){var e;return!(null===(e=t.leveragePref)||void 0===e?void 0:e.cross)})).map((function(t){return t.initial_margin||0})).reduce((function(t,e){return t+e}),0),s=e.filter((function(t){var e;return null===(e=t.leveragePref)||void 0===e?void 0:e.cross})).map((function(t){return t.maintenance_margin||0})).reduce((function(t,e){return t+e}),0),c=e.filter((function(t){var e;return null===(e=t.leveragePref)||void 0===e?void 0:e.cross})).map((function(t){return t.pnl})).reduce((function(t,e){return t+e}),0);return 1-Math.max(r,1/((o-a)/(s-c)))}return t&&t.initial_margin&&t.maintenance_margin&&r?1-Math.max(r,t.maintenance_margin/(t.initial_margin+t.pnl)):1}(t,e,n,i)})),N=Object(i.j)(j,u.o,(function(t,e){return t.filter((function(t){var e;return null===(e=t.leveragePref)||void 0===e?void 0:e.cross}))})),U=Object(i.j)(N,(function(t){return t.length>0})),F=(Object(i.j)(N,(function(t){return t.reduce((function(t,e){return t+e.pnl}),0)})),Object(i.j)(N,(function(t){var e,n;return null!==(n=null===(e=t[0])||void 0===e?void 0:e.effective_leverage)&&void 0!==n?n:0}))),B=Object(i.j)(u.o,F,(function(t,e){return t.cross?e:t.maxLeverage}))},YzTY:function(t,e,n){"use strict";var i;function r(t){return function(e){return!(t.lowerBounds&&(e[0]t.upperBounds[0]||e[1]>t.upperBounds[1]))}}function o(t,e){return r(t)(e)}n.d(e,"b",(function(){return r})),n.d(e,"h",(function(){return o})),n.d(e,"f",(function(){return l})),n.d(e,"d",(function(){return h})),n.d(e,"g",(function(){return p})),n.d(e,"e",(function(){return y})),n.d(e,"c",(function(){return _})),n.d(e,"i",(function(){return C})),n.d(e,"a",(function(){return c})),n.d(e,"n",(function(){return E})),n.d(e,"l",(function(){return x})),n.d(e,"m",(function(){return P})),n.d(e,"j",(function(){return A})),n.d(e,"k",(function(){return I}));var a=n("u7r1"),s=n("lx5p"),c=function(t){return t[t.ORDER_FORM=1]="ORDER_FORM",t[t.MARKET_PREVIEWS=2]="MARKET_PREVIEWS",t[t.MARKET_CHART=3]="MARKET_CHART",t[t.OPEN_POSITIONS=4]="OPEN_POSITIONS",t[t.OPEN_ORDERS=5]="OPEN_ORDERS",t[t.TRIGGER_ORDERS=6]="TRIGGER_ORDERS",t[t.FILLED_ORDERS=7]="FILLED_ORDERS",t[t.ORDERBOOK=8]="ORDERBOOK",t[t.MARKET_DETAILS=9]="MARKET_DETAILS",t[t.PAIR_WALLET=10]="PAIR_WALLET",t[t.TRADE_HISTORY=11]="TRADE_HISTORY",t[t.BRACKET_ORDER=12]="BRACKET_ORDER",t[t.DEPTH_CHART=13]="DEPTH_CHART",t[t.ACCOUNT_ACTIVITY=14]="ACCOUNT_ACTIVITY",t}({}),u=function(t){return t[t.center="c"]="center",t[t.top="t"]="top",t[t.bottom="b"]="bottom",t[t.left="l"]="left",t[t.right="r"]="right",t[t.topCenter="tc"]="topCenter",t[t.topLeft="tl"]="topLeft",t[t.topRight="tr"]="topRight",t[t.bottomCenter="bc"]="bottomCenter",t[t.bottomLeft="bl"]="bottomLeft",t[t.bottomRight="br"]="bottomRight",t[t.c00="c00"]="c00",t[t.c01="c01"]="c01",t[t.c02="c02"]="c02",t[t.c03="c03"]="c03",t[t.c04="c04"]="c04",t[t.c10="c10"]="c10",t[t.c11="c11"]="c11",t[t.c12="c12"]="c12",t[t.c13="c13"]="c13",t[t.c14="c14"]="c14",t[t.c20="c20"]="c20",t[t.c21="c21"]="c21",t[t.c22="c22"]="c22",t[t.c23="c23"]="c23",t[t.c24="c24"]="c24",t[t.c30="c30"]="c30",t[t.c31="c31"]="c31",t[t.c32="c32"]="c32",t[t.c33="c33"]="c33",t[t.c34="c34"]="c34",t[t.c40="c40"]="c40",t[t.c41="c41"]="c41",t[t.c42="c42"]="c42",t[t.c43="c43"]="c43",t[t.c44="c44"]="c44",t}({});function l(t){var e=t.name,n=t.type,i=t.panels,r=n;r+="$";var o=Object.entries(i).map((function(t){var e=m(t,2);return function(t,e){var n="";return n+=u[t],n+="!",e.size&&(n+=e.size.map((function(t){return t.toString(16)})).join(",")),n+="!",n+=e.components.map((function(t){var n=t.toString(16);return e.activeComponent===t?"@"+n:n})).join(",")}(e[0],e[1])})).join("_");return r+=o,r+="$",r+=escape(e)}function d(t){var e={},n=t.split("!");if(3!==n.length)throw new Error("Encoded panel has wrong number of parts.");var i=m(n,3),r=i[0],o=i[1],a=i[2];if(!(r in u))throw new Error("Encoded panel location does not exist.");var l=u[r],d=o.split(",");if(2!==d.length)throw new Error("Encoded tab size has wrong number of parts.");var h=m(d.map((function(t){return parseInt(t,16)})),2),f=h[0],p=h[1];if([f,p].some(Number.isNaN))throw new Error("Encoded panel size is not hexadecimal.");if([f,p].some(s.o))throw new Error("Encoded panel size is negative.");return e.size=[f,p],e.components=a.split(",").filter((function(t){return t.length>0})).map((function(t){if("@"===t[0]){var n=parseInt(t.substring(1),16);return e.activeComponent=n,n}return parseInt(t,16)})).filter((function(t){return t in c})),[l,e]}function h(t){var e={},n=Object(s.K)("$",3)(t);if(3!==n.length)throw new Error("Encoded workspace has wrong number of parts.");var i=m(n,3),r=i[0],o=i[1],c=i[2];return e.type=r,e.name=unescape(c),e.id=Object(a.a)(11),e.panels={},o.split("_").map(d).forEach((function(t){var n=m(t,2),i=n[0],r=n[1];e.panels[i]=r})),e}function p(t,e){var n=t.slice(1).split("").slice(0,2).map(Number);return"".concat(n[0]+1," / ").concat(n[1]+1," / span ").concat(e.size[1]/2," / span ").concat(e.size[0]/2)}var g=n("TYVA"),v={name:"WORKSPACE.__DEFAULT__",type:"default"};function y(){return _(v)}function _(t){var e;return Object.assign(Object.assign({},t),{id:Object(a.a)(10),panels:null!==(e=t.panels)&&void 0!==e?e:w[t.type]})}var O={left:{size:[2,10],components:[c.ORDER_FORM,c.MARKET_PREVIEWS]},topCenter:{size:[6,6],components:[c.MARKET_CHART,c.DEPTH_CHART]},bottomCenter:{size:[6,4],components:[c.OPEN_POSITIONS,c.OPEN_ORDERS,c.TRIGGER_ORDERS,c.FILLED_ORDERS]},topRight:{size:[2,6],components:[c.ORDERBOOK,c.MARKET_DETAILS]},bottomRight:{size:[2,4],components:[c.TRADE_HISTORY,c.PAIR_WALLET]}},k={left:{size:[2,10],components:[c.ORDER_FORM,c.MARKET_PREVIEWS]},topCenter:{size:[6,6],components:[c.MARKET_CHART,c.DEPTH_CHART,c.MARKET_DETAILS]},bottomCenter:{size:[8,4],components:[c.OPEN_POSITIONS,c.OPEN_ORDERS,c.TRIGGER_ORDERS,c.FILLED_ORDERS]},topRight:{size:[2,6],components:[c.ORDERBOOK,c.TRADE_HISTORY]}},w={default:"desktop-max"===Object(g.A)()||"desktop-large"===Object(g.A)()?O:k,single:{center:{size:[10,10],components:[c.MARKET_CHART]}},double:{left:{size:[5,10],components:[c.ORDER_FORM]},right:{size:[5,10],components:[c.MARKET_CHART,c.ORDERBOOK]}},triple:{topLeft:{size:[5,5],components:[c.OPEN_POSITIONS]},bottomLeft:{size:[5,5],components:[c.OPEN_ORDERS,c.TRIGGER_ORDERS,c.FILLED_ORDERS]},right:{size:[5,10],components:[c.MARKET_CHART,c.ORDERBOOK]}},quad:{topLeft:{size:[5,5],components:[c.MARKET_CHART]},topRight:{size:[5,5],components:[c.ORDERBOOK,c.TRADE_HISTORY]},bottomLeft:{size:[5,5],components:[c.ORDER_FORM,c.PAIR_WALLET]},bottomRight:{size:[5,5],components:[c.OPEN_POSITIONS,c.OPEN_ORDERS,c.TRIGGER_ORDERS,c.FILLED_ORDERS]}},layout1:{left:{size:[6,10],components:[c.MARKET_CHART]},topRight:{size:[4,5],components:[c.ORDERBOOK,c.MARKET_PREVIEWS]},bottomRight:{size:[4,5],components:[c.OPEN_POSITIONS,c.OPEN_ORDERS,c.TRIGGER_ORDERS,c.FILLED_ORDERS]}},layout2:{topLeft:{size:[5,5],components:[c.MARKET_PREVIEWS]},bottomLeft:{size:[5,5],components:[c.OPEN_POSITIONS,c.OPEN_ORDERS,c.TRIGGER_ORDERS,c.FILLED_ORDERS]},center:{size:[2.5,10],components:[c.ORDERBOOK]},right:{size:[2.5,10],components:[c.ORDER_FORM,c.TRADE_HISTORY]}},layout3:{topLeft:{size:[6,5],components:[c.ORDER_FORM,c.MARKET_PREVIEWS]},bottomLeft:{size:[6,5],components:[c.OPEN_POSITIONS,c.OPEN_ORDERS,c.TRIGGER_ORDERS,c.FILLED_ORDERS]},topRight:{size:[4,5],components:[c.ORDERBOOK]},bottomRight:{size:[4,5],components:[c.PAIR_WALLET]}},layout4:{left:{size:[2.5,10],components:[c.ORDER_FORM]},center:{size:[5,10],components:[c.MARKET_CHART]},right:{size:[2.5,10],components:[c.ORDERBOOK,c.MARKET_PREVIEWS]}},layout5:{top:{size:[10,6],components:[c.MARKET_CHART]},bottom:{size:[10,4],components:[c.OPEN_POSITIONS,c.OPEN_ORDERS,c.TRIGGER_ORDERS,c.FILLED_ORDERS]}},layout6:{topLeft:{size:[5,6],components:[c.MARKET_CHART]},topRight:{size:[5,6],components:[c.ORDERBOOK]},bottom:{size:[10,4],components:[c.OPEN_POSITIONS,c.OPEN_ORDERS,c.TRIGGER_ORDERS,c.FILLED_ORDERS]}},layout7:{top:{size:[10,6],components:[c.MARKET_CHART]},bottomLeft:{size:[5,4],components:[c.OPEN_POSITIONS,c.PAIR_WALLET]},bottomRight:{size:[5,4],components:[c.OPEN_ORDERS,c.TRIGGER_ORDERS,c.FILLED_ORDERS]}},custom:{}},C=(f(i={},c.MARKET_DETAILS,{id:c.MARKET_DETAILS,upperBounds:[6,10]}),f(i,c.MARKET_CHART,{id:c.MARKET_CHART,lowerBounds:[2,1]}),f(i,c.MARKET_PREVIEWS,{id:c.MARKET_PREVIEWS}),f(i,c.ORDERBOOK,{id:c.ORDERBOOK}),f(i,c.ORDER_FORM,{id:c.ORDER_FORM}),f(i,c.TRADE_HISTORY,{id:c.TRADE_HISTORY}),f(i,c.OPEN_ORDERS,{id:c.OPEN_ORDERS}),f(i,c.TRIGGER_ORDERS,{id:c.TRIGGER_ORDERS}),f(i,c.OPEN_POSITIONS,{id:c.OPEN_POSITIONS}),f(i,c.FILLED_ORDERS,{id:c.FILLED_ORDERS}),f(i,c.PAIR_WALLET,{id:c.PAIR_WALLET}),f(i,c.BRACKET_ORDER,{id:c.BRACKET_ORDER,deprecated:!0}),f(i,c.ACCOUNT_ACTIVITY,{id:c.ACCOUNT_ACTIVITY,deprecated:!0}),f(i,c.DEPTH_CHART,{id:c.DEPTH_CHART,lowerBounds:[2,2]}),i),T=n("p5wL");function S(t,e){return function(n){return n.map((function(n){return n.id===e?t(n):n}))}}function E(t,e){return S((function(t){return t.name!==e?Object(T.b)(e,t,"name"):t}),t)}function x(t){return function(e){return e.map(Object(s.F)("id")).includes(t)?e.filter((function(e){return e.id!==t})):e}}function P(t,e,n){return S((function(n){return Object(T.b)(t,n,"panels",e,"activeComponent")}),n)}function A(t,e,n,i){return S((function(n){if(b(Object.values(n.panels)).flatMap((function(t){var e;return null!==(e=null==t?void 0:t.components)&&void 0!==e?e:[]})).includes(t))return n;var r,o,a,c=n,u=(a=null!==(o=null===(r=c.panels[e])||void 0===r?void 0:r.components)&&void 0!==o?o:[],Object(s.m)(i)?[].concat(b(a.slice(0,i)),[t],b(a.slice(i))):[].concat(b(a),[t])),l=Object(T.b)(u,c,"panels",e,"components");return Object(T.b)(t,l,"panels",e,"activeComponent")}),n)}function I(t,e){return S((function(e){if(b(Object.values(e.panels)).flatMap((function(t){var e;return null!==(e=null==t?void 0:t.components)&&void 0!==e?e:[]})).includes(t)){var n=Object(s.A)((function(e){if(!e)return e;if(e.components.includes(t)){var n=e.activeComponent?e.components.indexOf(e.activeComponent):void 0,i=e.components.filter(Object(s.p)(t)),r=Object(T.b)(i,e,"components");if(void 0===n)return r;if(0===i.length)return Object(T.b)(void 0,r,"activeComponent");var o=i[Math.min(n,i.length-1)];return Object(T.b)(o,r,"activeComponent")}return e}),e.panels);return Object(T.b)(n,e,"panels")}return e}),e)}},YzW0:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("+luX"),r=n("Nxx2"),o=n("IkhO"),a=n("sP54"),s=n("XveA"),c=n("oznm");e.default=function(){function t(){}return t.clearMatrix=function(t){t.clear(255)},t.buildMatrix=function(e,n,i,r,o){t.clearMatrix(o),t.embedBasicPatterns(i,o),t.embedTypeInfo(n,r,o),t.maybeEmbedVersionInfo(i,o),t.embedDataBits(e,r,o)},t.embedBasicPatterns=function(e,n){t.embedPositionDetectionPatternsAndSeparators(n),t.embedDarkDotAtLeftBottomCorner(n),t.maybeEmbedPositionAdjustmentPatterns(e,n),t.embedTimingPatterns(n)},t.embedTypeInfo=function(e,n,r){var o=new i.default;t.makeTypeInfoBits(e,n,o);for(var a=0,s=o.getSize();a0;){for(6===c&&(c-=1);u>=0&&u=i;)e^=n<=0)for(var c=0;c!==a;c++){var u=r[c];u>=0&&t.isEmpty(n.get(u,s))&&t.embedPositionAdjustmentPattern(u-2,s-2,n)}}},t.POSITION_DETECTION_PATTERN=Array.from([Int32Array.from([1,1,1,1,1,1,1]),Int32Array.from([1,0,0,0,0,0,1]),Int32Array.from([1,0,1,1,1,0,1]),Int32Array.from([1,0,1,1,1,0,1]),Int32Array.from([1,0,1,1,1,0,1]),Int32Array.from([1,0,0,0,0,0,1]),Int32Array.from([1,1,1,1,1,1,1])]),t.POSITION_ADJUSTMENT_PATTERN=Array.from([Int32Array.from([1,1,1,1,1]),Int32Array.from([1,0,0,0,1]),Int32Array.from([1,0,1,0,1]),Int32Array.from([1,0,0,0,1]),Int32Array.from([1,1,1,1,1])]),t.POSITION_ADJUSTMENT_PATTERN_COORDINATE_TABLE=Array.from([Int32Array.from([-1,-1,-1,-1,-1,-1,-1]),Int32Array.from([6,18,-1,-1,-1,-1,-1]),Int32Array.from([6,22,-1,-1,-1,-1,-1]),Int32Array.from([6,26,-1,-1,-1,-1,-1]),Int32Array.from([6,30,-1,-1,-1,-1,-1]),Int32Array.from([6,34,-1,-1,-1,-1,-1]),Int32Array.from([6,22,38,-1,-1,-1,-1]),Int32Array.from([6,24,42,-1,-1,-1,-1]),Int32Array.from([6,26,46,-1,-1,-1,-1]),Int32Array.from([6,28,50,-1,-1,-1,-1]),Int32Array.from([6,30,54,-1,-1,-1,-1]),Int32Array.from([6,32,58,-1,-1,-1,-1]),Int32Array.from([6,34,62,-1,-1,-1,-1]),Int32Array.from([6,26,46,66,-1,-1,-1]),Int32Array.from([6,26,48,70,-1,-1,-1]),Int32Array.from([6,26,50,74,-1,-1,-1]),Int32Array.from([6,30,54,78,-1,-1,-1]),Int32Array.from([6,30,56,82,-1,-1,-1]),Int32Array.from([6,30,58,86,-1,-1,-1]),Int32Array.from([6,34,62,90,-1,-1,-1]),Int32Array.from([6,28,50,72,94,-1,-1]),Int32Array.from([6,26,50,74,98,-1,-1]),Int32Array.from([6,30,54,78,102,-1,-1]),Int32Array.from([6,28,54,80,106,-1,-1]),Int32Array.from([6,32,58,84,110,-1,-1]),Int32Array.from([6,30,58,86,114,-1,-1]),Int32Array.from([6,34,62,90,118,-1,-1]),Int32Array.from([6,26,50,74,98,122,-1]),Int32Array.from([6,30,54,78,102,126,-1]),Int32Array.from([6,26,52,78,104,130,-1]),Int32Array.from([6,30,56,82,108,134,-1]),Int32Array.from([6,34,60,86,112,138,-1]),Int32Array.from([6,30,58,86,114,142,-1]),Int32Array.from([6,34,62,90,118,146,-1]),Int32Array.from([6,30,54,78,102,126,150]),Int32Array.from([6,24,50,76,102,128,154]),Int32Array.from([6,28,54,80,106,132,158]),Int32Array.from([6,32,58,84,110,136,162]),Int32Array.from([6,26,54,82,110,138,166]),Int32Array.from([6,30,58,86,114,142,170])]),t.TYPE_INFO_COORDINATES=Array.from([Int32Array.from([8,0]),Int32Array.from([8,1]),Int32Array.from([8,2]),Int32Array.from([8,3]),Int32Array.from([8,4]),Int32Array.from([8,5]),Int32Array.from([8,7]),Int32Array.from([8,8]),Int32Array.from([7,8]),Int32Array.from([5,8]),Int32Array.from([4,8]),Int32Array.from([3,8]),Int32Array.from([2,8]),Int32Array.from([1,8]),Int32Array.from([0,8])]),t.VERSION_INFO_POLY=7973,t.TYPE_INFO_POLY=1335,t.TYPE_INFO_MASK_PATTERN=21522,t}()},ZCEf:function(t,e,n){"use strict";var i;Object.defineProperty(e,"__esModule",{value:!0}),e.default=((i={})[i.OTHER=0]="OTHER",i[i.PURE_BARCODE=1]="PURE_BARCODE",i[i.POSSIBLE_FORMATS=2]="POSSIBLE_FORMATS",i[i.TRY_HARDER=3]="TRY_HARDER",i[i.CHARACTER_SET=4]="CHARACTER_SET",i[i.ALLOWED_LENGTHS=5]="ALLOWED_LENGTHS",i[i.ASSUME_CODE_39_CHECK_DIGIT=6]="ASSUME_CODE_39_CHECK_DIGIT",i[i.ASSUME_GS1=7]="ASSUME_GS1",i[i.RETURN_CODABAR_START_END=8]="RETURN_CODABAR_START_END",i[i.NEED_RESULT_POINT_CALLBACK=9]="NEED_RESULT_POINT_CALLBACK",i[i.ALLOWED_EAN_EXTENSIONS=10]="ALLOWED_EAN_EXTENSIONS",i)},ZEHW:function(t,e,n){"use strict";n.d(e,"a",(function(){return v}));var i=n("vYTc"),r=n("kZht"),o=n("1etq"),a=n("yPvj"),s=n("1o0v"),c=n("za3o"),u=n("anSm"),l=n("LbKT"),d=n("aDqW"),h=n("BeMo"),f=n("rUBT"),p=n("DpwM"),b=n("FUqb"),g=n("An66"),m=n("Knqz"),v=function(){var t=function t(){C(this,t),this.mid=i.j};return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=r.Ib({type:t,selectors:[["market-preview-favorite"]],inputs:{ticker:"ticker"},decls:34,vars:32,consts:[["subheading","",1,"grid-min-1","gap-m","vcenter","symbol"],[3,"pair"],[1,"pair"],["ghost","","capitalize","",1,"maturity"],["body","",1,"price"],[1,"mid"],[1,"amount"],[1,"unit"],["pnlZero","",1,"change",3,"pnl"],["body","",1,"volume"],["translate","","ghost","",1,"label"],[1,"shade"],[3,"market","filled"]],template:function(t,e){1&t&&(r.Ub(0,"h2",0),r.Pb(1,"market-icon",1),r.Ub(2,"div"),r.Ub(3,"div",2),r.Qc(4),r.gc(5,"pair"),r.Tb(),r.Ub(6,"div",3),r.Qc(7),r.gc(8,"translate"),r.gc(9,"maturityMonth"),r.Tb(),r.Tb(),r.Tb(),r.Ub(10,"div",4),r.Ub(11,"div",5),r.Ub(12,"span",6),r.Qc(13),r.gc(14,"sato"),r.Tb(),r.Ub(15,"span",7),r.Qc(16),r.gc(17,"quote"),r.Tb(),r.Tb(),r.Ub(18,"div",8),r.Qc(19),r.gc(20,"change"),r.gc(21,"percent"),r.Tb(),r.Tb(),r.Ub(22,"div",9),r.Ub(23,"div",10),r.Qc(24,"LABEL.24H_VOLUME"),r.Tb(),r.Ub(25,"div"),r.Ub(26,"span",6),r.Qc(27),r.gc(28,"humanNumber"),r.Tb(),r.Ub(29,"span"),r.Qc(30),r.gc(31,"base"),r.Tb(),r.Tb(),r.Tb(),r.Pb(32,"div",11),r.Pb(33,"sparkline",12)),2&t&&(r.Cb(1),r.mc("pair",e.ticker.pair),r.Cb(3),r.Rc(r.hc(5,11,e.ticker.product_id)),r.Cb(3),r.Sc(" ",r.hc(8,13,r.ic(9,15,e.ticker.product_id,"short")||"")," "),r.Cb(6),r.Rc(r.ic(14,18,e.mid(e.ticker),e.ticker)),r.Cb(3),r.Sc(" ",r.hc(17,21,e.ticker.product_id),""),r.Cb(2),r.mc("pnl",e.ticker.change),r.Cb(1),r.Sc(" ",r.hc(20,23,r.ic(21,25,e.ticker.change/100,"1.2-2"))," "),r.Cb(8),r.Rc(r.hc(28,28,e.ticker.volume)),r.Cb(3),r.Sc(" ",r.hc(31,30,e.ticker.product_id),""),r.Cb(3),r.mc("market",e.ticker.product_id)("filled",!0))},directives:[o.a,a.a,s.a,c.a,u.a,l.a,d.a,h.a],pipes:[f.e,d.d,f.d,p.c,f.f,b.b,g.u,m.a,f.a],styles:['[_nghost-%COMP%]{display:grid;grid-template:"symbol symbol" auto "volume price" auto/auto auto;gap:var(--spacing);padding:var(--spacing);border:1px solid var(--border-colour);border-radius:var(--bdrs);background-color:var(--background-colour)}[_nghost-%COMP%]:hover{background:rgba(var(--text-colour-rgb),.1);cursor:pointer}[active=true][_nghost-%COMP%]{border:1px solid var(--brand)}.price[_ngcontent-%COMP%], .symbol[_ngcontent-%COMP%], .volprop[_ngcontent-%COMP%], .volume[_ngcontent-%COMP%]{z-index:2}.symbol[_ngcontent-%COMP%]{grid-area:symbol;font-size:1.1em}.symbol[_ngcontent-%COMP%] .pair[_ngcontent-%COMP%]{color:var(--symbol-color,var(--text-colour))}.symbol[_ngcontent-%COMP%] market-icon[_ngcontent-%COMP%]{font-size:1.5em}.symbol[_ngcontent-%COMP%] .maturity[_ngcontent-%COMP%]{margin-top:var(--spacing-s);font-size:.8em}.price[_ngcontent-%COMP%]{grid-area:price;align-self:end;text-align:right}.price[_ngcontent-%COMP%] .mid[_ngcontent-%COMP%]{margin-bottom:var(--spacing-s)}.price[_ngcontent-%COMP%] .mid[_ngcontent-%COMP%] .amount[_ngcontent-%COMP%]{font-size:1.4em}.volume[_ngcontent-%COMP%]{grid-area:volume;align-self:end}.volume[_ngcontent-%COMP%] .amount[_ngcontent-%COMP%]{font-size:1.25em}.volume[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{margin-bottom:var(--spacing-s)}.shade[_ngcontent-%COMP%]{width:auto;height:calc(100% + var(--spacing) * 2);z-index:1;background-image:linear-gradient(0deg,rgba(0,0,0,.4),transparent);background-size:100% 40%;background-position:bottom;background-repeat:repeat-x;pointer-events:none}.shade[_ngcontent-%COMP%], sparkline[_ngcontent-%COMP%]{grid-area:1/1/-1/-1;margin:calc(var(--spacing) * -1)}sparkline[_ngcontent-%COMP%]{align-self:center;z-index:0;opacity:.6}'],changeDetection:0}),t}()},ZR2N:function(t,e,n){var i=n("yBEi"),r=n("nwte"),o=n("ECQc"),a=n("JgBV"),s=n("p3rJ"),c=n("B9MG"),u=i.getBCHDigit(7973);function l(t,e){return a.getCharCountIndicator(t,e)+4}function d(t,e){var n=0;return t.forEach((function(t){var i=l(t.mode,e);n+=i+t.getBitsLength()})),n}e.from=function(t,e){return s.isValid(t)?parseInt(t,10):e},e.getCapacity=function(t,e,n){if(!s.isValid(t))throw new Error("Invalid QR Code version");void 0===n&&(n=a.BYTE);var o=8*(i.getSymbolTotalCodewords(t)-r.getTotalCodewordsCount(t,e));if(n===a.MIXED)return o;var c=o-l(n,t);switch(n){case a.NUMERIC:return Math.floor(c/10*3);case a.ALPHANUMERIC:return Math.floor(c/11*2);case a.KANJI:return Math.floor(c/13);case a.BYTE:default:return Math.floor(c/8)}},e.getBestVersionForData=function(t,n){var i,r=o.from(n,o.M);if(c(t)){if(t.length>1)return function(t,n){for(var i=1;i<=40;i++)if(d(t,i)<=e.getCapacity(i,n,a.MIXED))return i}(t,r);if(0===t.length)return 1;i=t[0]}else i=t;return function(t,n,i){for(var r=1;r<=40;r++)if(n<=e.getCapacity(r,i,t))return r}(i.mode,i.getLength(),r)},e.getEncodedBits=function(t){if(!s.isValid(t)||t<7)throw new Error("Invalid QR Code version");for(var e=t<<12;i.getBCHDigit(e)-u>=0;)e^=7973<7?p-1:p]=e[y++]}if(y!==e.length)throw new i.default;return u},t.prototype.getNumDataCodewords=function(){return this.numDataCodewords},t.prototype.getCodewords=function(){return this.codewords},t}()},ZtZA:function(t,e,n){"use strict";n.d(e,"a",(function(){return p})),n.d(e,"b",(function(){return g})),n.d(e,"c",(function(){return m})),n.d(e,"d",(function(){return u})),n.d(e,"e",(function(){return b})),n.d(e,"f",(function(){return v})),n.d(e,"g",(function(){return _})),n.d(e,"h",(function(){return d}));var i=n("kZht"),r=n("An66"),s=function(){function t(){C(this,t)}return w(t,[{key:"attach",value:function(t){return this._attachedHost=t,t.attach(this)}},{key:"detach",value:function(){var t=this._attachedHost;null!=t&&(this._attachedHost=null,t.detach())}},{key:"setAttachedHost",value:function(t){this._attachedHost=t}},{key:"isAttached",get:function(){return null!=this._attachedHost}}]),t}(),u=function(t){a(n,t);var e=c(n);function n(t,i,r,o){var a;return C(this,n),(a=e.call(this)).component=t,a.viewContainerRef=i,a.injector=r,a.componentFactoryResolver=o,a}return n}(s),d=function(t){a(n,t);var e=c(n);function n(t,i,r){var o;return C(this,n),(o=e.call(this)).templateRef=t,o.viewContainerRef=i,o.context=r,o}return w(n,[{key:"attach",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.context;return this.context=e,o(h(n.prototype),"attach",this).call(this,t)}},{key:"detach",value:function(){return this.context=void 0,o(h(n.prototype),"detach",this).call(this)}},{key:"origin",get:function(){return this.templateRef.elementRef}}]),n}(s),f=function(t){a(n,t);var e=c(n);function n(t){var r;return C(this,n),(r=e.call(this)).element=t instanceof i.l?t.nativeElement:t,r}return n}(s),p=function(){function t(){C(this,t),this._isDisposed=!1,this.attachDomPortal=null}return w(t,[{key:"hasAttached",value:function(){return!!this._attachedPortal}},{key:"attach",value:function(t){return t instanceof u?(this._attachedPortal=t,this.attachComponentPortal(t)):t instanceof d?(this._attachedPortal=t,this.attachTemplatePortal(t)):this.attachDomPortal&&t instanceof f?(this._attachedPortal=t,this.attachDomPortal(t)):void 0}},{key:"detach",value:function(){this._attachedPortal&&(this._attachedPortal.setAttachedHost(null),this._attachedPortal=null),this._invokeDisposeFn()}},{key:"dispose",value:function(){this.hasAttached()&&this.detach(),this._invokeDisposeFn(),this._isDisposed=!0}},{key:"setDisposeFn",value:function(t){this._disposeFn=t}},{key:"_invokeDisposeFn",value:function(){this._disposeFn&&(this._disposeFn(),this._disposeFn=null)}}]),t}(),b=function(t){a(n,t);var e=c(n);function n(t,i,r,a,s){var c,u;return C(this,n),(u=e.call(this)).outletElement=t,u._componentFactoryResolver=i,u._appRef=r,u._defaultInjector=a,u.attachDomPortal=function(t){var e=t.element,i=u._document.createComment("dom-portal");e.parentNode.insertBefore(i,e),u.outletElement.appendChild(e),o((c=l(u),h(n.prototype)),"setDisposeFn",c).call(c,(function(){i.parentNode&&i.parentNode.replaceChild(e,i)}))},u._document=s,u}return w(n,[{key:"attachComponentPortal",value:function(t){var e,n=this,i=(t.componentFactoryResolver||this._componentFactoryResolver).resolveComponentFactory(t.component);return t.viewContainerRef?(e=t.viewContainerRef.createComponent(i,t.viewContainerRef.length,t.injector||t.viewContainerRef.injector),this.setDisposeFn((function(){return e.destroy()}))):(e=i.create(t.injector||this._defaultInjector),this._appRef.attachView(e.hostView),this.setDisposeFn((function(){n._appRef.detachView(e.hostView),e.destroy()}))),this.outletElement.appendChild(this._getComponentRootNode(e)),e}},{key:"attachTemplatePortal",value:function(t){var e=this,n=t.viewContainerRef,i=n.createEmbeddedView(t.templateRef,t.context);return i.rootNodes.forEach((function(t){return e.outletElement.appendChild(t)})),i.detectChanges(),this.setDisposeFn((function(){var t=n.indexOf(i);-1!==t&&n.remove(t)})),i}},{key:"dispose",value:function(){o(h(n.prototype),"dispose",this).call(this),null!=this.outletElement.parentNode&&this.outletElement.parentNode.removeChild(this.outletElement)}},{key:"_getComponentRootNode",value:function(t){return t.hostView.rootNodes[0]}}]),n}(p),g=function(){var t=function(t){a(n,t);var e=c(n);function n(t,i){return C(this,n),e.call(this,t,i)}return n}(d);return t.\u0275fac=function(e){return new(e||t)(i.Ob(i.N),i.Ob(i.R))},t.\u0275dir=i.Jb({type:t,selectors:[["","cdkPortal",""]],exportAs:["cdkPortal"],features:[i.zb]}),t}(),m=function(){var t=function(t){a(n,t);var e=c(n);function n(t,r,a){var s,c;return C(this,n),(c=e.call(this))._componentFactoryResolver=t,c._viewContainerRef=r,c._isInitialized=!1,c.attached=new i.o,c.attachDomPortal=function(t){var e=t.element,i=c._document.createComment("dom-portal");t.setAttachedHost(l(c)),e.parentNode.insertBefore(i,e),c._getRootNode().appendChild(e),o((s=l(c),h(n.prototype)),"setDisposeFn",s).call(s,(function(){i.parentNode&&i.parentNode.replaceChild(e,i)}))},c._document=a,c}return w(n,[{key:"ngOnInit",value:function(){this._isInitialized=!0}},{key:"ngOnDestroy",value:function(){o(h(n.prototype),"dispose",this).call(this),this._attachedPortal=null,this._attachedRef=null}},{key:"attachComponentPortal",value:function(t){t.setAttachedHost(this);var e=null!=t.viewContainerRef?t.viewContainerRef:this._viewContainerRef,i=(t.componentFactoryResolver||this._componentFactoryResolver).resolveComponentFactory(t.component),r=e.createComponent(i,e.length,t.injector||e.injector);return e!==this._viewContainerRef&&this._getRootNode().appendChild(r.hostView.rootNodes[0]),o(h(n.prototype),"setDisposeFn",this).call(this,(function(){return r.destroy()})),this._attachedPortal=t,this._attachedRef=r,this.attached.emit(r),r}},{key:"attachTemplatePortal",value:function(t){var e=this;t.setAttachedHost(this);var i=this._viewContainerRef.createEmbeddedView(t.templateRef,t.context);return o(h(n.prototype),"setDisposeFn",this).call(this,(function(){return e._viewContainerRef.clear()})),this._attachedPortal=t,this._attachedRef=i,this.attached.emit(i),i}},{key:"_getRootNode",value:function(){var t=this._viewContainerRef.element.nativeElement;return t.nodeType===t.ELEMENT_NODE?t:t.parentNode}},{key:"portal",get:function(){return this._attachedPortal},set:function(t){(!this.hasAttached()||t||this._isInitialized)&&(this.hasAttached()&&o(h(n.prototype),"detach",this).call(this),t&&o(h(n.prototype),"attach",this).call(this,t),this._attachedPortal=t)}},{key:"attachedRef",get:function(){return this._attachedRef}}]),n}(p);return t.\u0275fac=function(e){return new(e||t)(i.Ob(i.j),i.Ob(i.R),i.Ob(r.d))},t.\u0275dir=i.Jb({type:t,selectors:[["","cdkPortalOutlet",""]],inputs:{portal:["cdkPortalOutlet","portal"]},outputs:{attached:"attached"},exportAs:["cdkPortalOutlet"],features:[i.zb]}),t}(),v=function(){var t=function(t){a(n,t);var e=c(n);function n(){return C(this,n),e.apply(this,arguments)}return n}(m);return t.\u0275fac=function(e){return y(e||t)},t.\u0275dir=i.Jb({type:t,selectors:[["","cdkPortalHost",""],["","portalHost",""]],inputs:{portal:["cdkPortalHost","portal"]},exportAs:["cdkPortalHost"],features:[i.Bb([{provide:m,useExisting:t}]),i.zb]}),t}(),y=i.Wb(v),_=function(){var t=function t(){C(this,t)};return t.\u0275mod=i.Mb({type:t}),t.\u0275inj=i.Lb({factory:function(e){return new(e||t)}}),t}()},"a+Rm":function(t,e){var n=1e3,i=60*n,r=60*i,o=24*r;function a(t,e,n,i){var r=e>=1.5*n;return Math.round(t/n)+" "+i+(r?"s":"")}t.exports=function(t,e){e=e||{};var s,c,u=typeof t;if("string"===u&&t.length>0)return function(t){if(!((t=String(t)).length>100)){var e=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(t);if(e){var a=parseFloat(e[1]);switch((e[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*a;case"weeks":case"week":case"w":return 6048e5*a;case"days":case"day":case"d":return a*o;case"hours":case"hour":case"hrs":case"hr":case"h":return a*r;case"minutes":case"minute":case"mins":case"min":case"m":return a*i;case"seconds":case"second":case"secs":case"sec":case"s":return a*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return a;default:return}}}}(t);if("number"===u&&isFinite(t))return e.long?(s=t,(c=Math.abs(s))>=o?a(s,c,o,"day"):c>=r?a(s,c,r,"hour"):c>=i?a(s,c,i,"minute"):c>=n?a(s,c,n,"second"):s+" ms"):function(t){var e=Math.abs(t);return e>=o?Math.round(t/o)+"d":e>=r?Math.round(t/r)+"h":e>=i?Math.round(t/i)+"m":e>=n?Math.round(t/n)+"s":t+"ms"}(t);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(t))}},a1kK:function(t,e,n){"use strict";n.d(e,"f",(function(){return a})),n.d(e,"d",(function(){return s})),n.d(e,"e",(function(){return c})),n.d(e,"h",(function(){return u})),n.d(e,"g",(function(){return l})),n.d(e,"b",(function(){return d})),n.d(e,"a",(function(){return h})),n.d(e,"c",(function(){return f}));var i=n("VmIW"),r=n("lx5p"),o=n("TYVA");function a(t,e,n){return e.map((function(e){return c(t,e,n)}))}function s(t,e,n){return e.map((function(e){return c(t,e,n)}))}function c(t,e,n){var r=i.Maybe.fromUndefined(t.get(e[n])).map((function(t){return{numericPrecision:t.numericPrecision,numericFormat:t.numericFormat,category:t.category}}));return Object.assign(Object.assign({},e),r.orUndefined())}var u=function(t){return Object(r.E)(Object(r.F)("instrument"),o.o,Object(r.n)(Object(o.o)(t)))};function l(t,e){if(0!==t.length&&0!==e.length){var n=t[0].price,i=n-e[0].price;return{percent:i/n,value:i}}}var d="PI_XBTUSD",h="PF_XBTUSD",f="futures"},a3or:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(){function t(t,e){this.dataBytes=t,this.errorCorrectionBytes=e}return t.prototype.getDataBytes=function(){return this.dataBytes},t.prototype.getErrorCorrectionBytes=function(){return this.errorCorrectionBytes},t}()},aDqW:function(t,e,n){"use strict";n.d(e,"a",(function(){return B})),n.d(e,"b",(function(){return v})),n.d(e,"c",(function(){return V})),n.d(e,"d",(function(){return z})),n.d(e,"e",(function(){return F}));var i=n("kZht"),r=n("ROBh"),o=n("9bRT"),s=n("P4Xx"),u=n("qZtG"),l=n("i9xl"),d=n("J+dc"),h=n("wqq/"),b=n("YtkY"),g=n("5uDM"),m=n("TLy2"),v=function t(){C(this,t)},y=function(){var t=function(t){a(n,t);var e=c(n);function n(){return C(this,n),e.apply(this,arguments)}return w(n,[{key:"getTranslation",value:function(t){return Object(r.a)({})}}]),n}(v);return t.\u0275fac=function(e){return _(e||t)},t.\u0275prov=i.Kb({token:t,factory:t.\u0275fac}),t}(),_=i.Wb(y),O=function t(){C(this,t)},k=function(){var t=function(){function t(){C(this,t)}return w(t,[{key:"handle",value:function(t){return t.key}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=i.Kb({token:t,factory:t.\u0275fac}),t}();function T(t,e){if(t===e)return!0;if(null===t||null===e)return!1;if(t!=t&&e!=e)return!0;var n,i,r,o=typeof t;if(o==typeof e&&"object"==o){if(!Array.isArray(t)){if(Array.isArray(e))return!1;for(i in r=Object.create(null),t){if(!T(t[i],e[i]))return!1;r[i]=!0}for(i in e)if(!(i in r)&&void 0!==e[i])return!1;return!0}if(!Array.isArray(e))return!1;if((n=t.length)==e.length){for(i=0;i5&&void 0!==arguments[5])||arguments[5],c=arguments.length>6&&void 0!==arguments[6]&&arguments[6],u=arguments.length>7&&void 0!==arguments[7]&&arguments[7],l=arguments.length>8?arguments[8]:void 0;C(this,t),this.store=e,this.currentLoader=n,this.compiler=r,this.parser=o,this.missingTranslationHandler=a,this.useDefaultLang=s,this.isolate=c,this.extend=u,this.pending=!1,this._onTranslationChange=new i.o,this._onLangChange=new i.o,this._onDefaultLangChange=new i.o,this._langs=[],this._translations={},this._translationRequests={},l&&this.setDefaultLang(l)}return w(t,[{key:"setDefaultLang",value:function(t){var e=this;if(t!==this.defaultLang){var n=this.retrieveTranslations(t);void 0!==n?(null==this.defaultLang&&(this.defaultLang=t),n.pipe(Object(d.a)(1)).subscribe((function(n){e.changeDefaultLang(t)}))):this.changeDefaultLang(t)}}},{key:"getDefaultLang",value:function(){return this.defaultLang}},{key:"use",value:function(t){var e=this;if(t===this.currentLang)return Object(r.a)(this.translations[t]);var n=this.retrieveTranslations(t);return void 0!==n?(this.currentLang||(this.currentLang=t),n.pipe(Object(d.a)(1)).subscribe((function(n){e.changeLang(t)})),n):(this.changeLang(t),Object(r.a)(this.translations[t]))}},{key:"retrieveTranslations",value:function(t){var e;return(void 0===this.translations[t]||this.extend)&&(this._translationRequests[t]=this._translationRequests[t]||this.getTranslation(t),e=this._translationRequests[t]),e}},{key:"getTranslation",value:function(t){var e=this;this.pending=!0;var n=this.currentLoader.getTranslation(t).pipe(Object(h.a)(1),Object(d.a)(1));return this.loadingTranslations=n.pipe(Object(b.a)((function(n){return e.compiler.compileTranslations(n,t)})),Object(h.a)(1),Object(d.a)(1)),this.loadingTranslations.subscribe({next:function(n){e.translations[t]=e.extend&&e.translations[t]?Object.assign(Object.assign({},n),e.translations[t]):n,e.updateLangs(),e.pending=!1},error:function(t){e.pending=!1}}),n}},{key:"setTranslation",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];e=this.compiler.compileTranslations(e,t),this.translations[t]=(n||this.extend)&&this.translations[t]?function t(e,n){var i=Object.assign({},e);return E(e)&&E(n)&&Object.keys(n).forEach((function(r){E(n[r])&&r in e?i[r]=t(e[r],n[r]):Object.assign(i,f({},r,n[r]))})),i}(this.translations[t],e):e,this.updateLangs(),this.onTranslationChange.emit({lang:t,translations:this.translations[t]})}},{key:"getLangs",value:function(){return this.langs}},{key:"addLangs",value:function(t){var e=this;t.forEach((function(t){-1===e.langs.indexOf(t)&&e.langs.push(t)}))}},{key:"updateLangs",value:function(){this.addLangs(Object.keys(this.translations))}},{key:"getParsedResult",value:function(t,e,n){var i;if(e instanceof Array){var a,c={},u=!1,l=p(e);try{for(l.s();!(a=l.n()).done;){var d=a.value;c[d]=this.getParsedResult(t,d,n),Object(o.a)(c[d])&&(u=!0)}}catch(g){l.e(g)}finally{l.f()}if(u){var h=e.map((function(t){return Object(o.a)(c[t])?c[t]:Object(r.a)(c[t])}));return Object(s.a)(h).pipe(Object(b.a)((function(t){var n={};return t.forEach((function(t,i){n[e[i]]=t})),n})))}return c}if(t&&(i=this.parser.interpolate(this.parser.getValue(t,e),n)),void 0===i&&null!=this.defaultLang&&this.defaultLang!==this.currentLang&&this.useDefaultLang&&(i=this.parser.interpolate(this.parser.getValue(this.translations[this.defaultLang],e),n)),void 0===i){var f={key:e,translateService:this};void 0!==n&&(f.interpolateParams=n),i=this.missingTranslationHandler.handle(f)}return void 0!==i?i:e}},{key:"get",value:function(t,e){var n=this;if(!S(t)||!t.length)throw new Error('Parameter "key" required');if(this.pending)return this.loadingTranslations.pipe(Object(g.a)((function(i){return i=n.getParsedResult(i,t,e),Object(o.a)(i)?i:Object(r.a)(i)})));var i=this.getParsedResult(this.translations[this.currentLang],t,e);return Object(o.a)(i)?i:Object(r.a)(i)}},{key:"getStreamOnTranslationChange",value:function(t,e){var n=this;if(!S(t)||!t.length)throw new Error('Parameter "key" required');return Object(u.a)(Object(l.a)((function(){return n.get(t,e)})),this.onTranslationChange.pipe(Object(m.a)((function(i){var o=n.getParsedResult(i.translations,t,e);return"function"==typeof o.subscribe?o:Object(r.a)(o)}))))}},{key:"stream",value:function(t,e){var n=this;if(!S(t)||!t.length)throw new Error('Parameter "key" required');return Object(u.a)(Object(l.a)((function(){return n.get(t,e)})),this.onLangChange.pipe(Object(m.a)((function(i){var a=n.getParsedResult(i.translations,t,e);return Object(o.a)(a)?a:Object(r.a)(a)}))))}},{key:"instant",value:function(t,e){if(!S(t)||!t.length)throw new Error('Parameter "key" required');var n=this.getParsedResult(this.translations[this.currentLang],t,e);if(Object(o.a)(n)){if(t instanceof Array){var i={};return t.forEach((function(e,n){i[t[n]]=t[n]})),i}return t}return n}},{key:"set",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.currentLang;this.translations[n][t]=this.compiler.compile(e,n),this.updateLangs(),this.onTranslationChange.emit({lang:n,translations:this.translations[n]})}},{key:"changeLang",value:function(t){this.currentLang=t,this.onLangChange.emit({lang:t,translations:this.translations[t]}),null==this.defaultLang&&this.changeDefaultLang(t)}},{key:"changeDefaultLang",value:function(t){this.defaultLang=t,this.onDefaultLangChange.emit({lang:t,translations:this.translations[t]})}},{key:"reloadLang",value:function(t){return this.resetLang(t),this.getTranslation(t)}},{key:"resetLang",value:function(t){this._translationRequests[t]=void 0,this.translations[t]=void 0}},{key:"getBrowserLang",value:function(){if("undefined"!=typeof window&&void 0!==window.navigator){var t=window.navigator.languages?window.navigator.languages[0]:null;return void 0!==(t=t||window.navigator.language||window.navigator.browserLanguage||window.navigator.userLanguage)?(-1!==t.indexOf("-")&&(t=t.split("-")[0]),-1!==t.indexOf("_")&&(t=t.split("_")[0]),t):void 0}}},{key:"getBrowserCultureLang",value:function(){if("undefined"!=typeof window&&void 0!==window.navigator){var t=window.navigator.languages?window.navigator.languages[0]:null;return t=t||window.navigator.language||window.navigator.browserLanguage||window.navigator.userLanguage}}},{key:"onTranslationChange",get:function(){return this.isolate?this._onTranslationChange:this.store.onTranslationChange}},{key:"onLangChange",get:function(){return this.isolate?this._onLangChange:this.store.onLangChange}},{key:"onDefaultLangChange",get:function(){return this.isolate?this._onDefaultLangChange:this.store.onDefaultLangChange}},{key:"defaultLang",get:function(){return this.isolate?this._defaultLang:this.store.defaultLang},set:function(t){this.isolate?this._defaultLang=t:this.store.defaultLang=t}},{key:"currentLang",get:function(){return this.isolate?this._currentLang:this.store.currentLang},set:function(t){this.isolate?this._currentLang=t:this.store.currentLang=t}},{key:"langs",get:function(){return this.isolate?this._langs:this.store.langs},set:function(t){this.isolate?this._langs=t:this.store.langs=t}},{key:"translations",get:function(){return this.isolate?this._translations:this.store.translations},set:function(t){this.isolate?this._translations=t:this.store.translations=t}}]),t}();return t.\u0275fac=function(e){return new(e||t)(i.Yb(R),i.Yb(v),i.Yb(I),i.Yb(x),i.Yb(O),i.Yb(L),i.Yb(j),i.Yb(U),i.Yb(N))},t.\u0275prov=i.Kb({token:t,factory:t.\u0275fac}),t}(),B=function(){var t=function(){function t(e,n,i){var r=this;C(this,t),this.translateService=e,this.element=n,this._ref=i,this.onTranslationChangeSub||(this.onTranslationChangeSub=this.translateService.onTranslationChange.subscribe((function(t){t.lang===r.translateService.currentLang&&r.checkNodes(!0,t.translations)}))),this.onLangChangeSub||(this.onLangChangeSub=this.translateService.onLangChange.subscribe((function(t){r.checkNodes(!0,t.translations)}))),this.onDefaultLangChangeSub||(this.onDefaultLangChangeSub=this.translateService.onDefaultLangChange.subscribe((function(t){r.checkNodes(!0)})))}return w(t,[{key:"ngAfterViewChecked",value:function(){this.checkNodes()}},{key:"checkNodes",value:function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],e=arguments.length>1?arguments[1]:void 0,n=this.element.nativeElement.childNodes;n.length||(this.setContent(this.element.nativeElement,this.key),n=this.element.nativeElement.childNodes);for(var i=0;i1?i-1:0),o=1;o0&&void 0!==arguments[0]?arguments[0]:{};return{ngModule:t,providers:[e.loader||{provide:v,useClass:y},e.compiler||{provide:I,useClass:M},e.parser||{provide:x,useClass:P},e.missingTranslationHandler||{provide:O,useClass:k},R,{provide:j,useValue:e.isolate},{provide:L,useValue:e.useDefaultLang},{provide:U,useValue:e.extend},{provide:N,useValue:e.defaultLanguage},F]}}},{key:"forChild",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return{ngModule:t,providers:[e.loader||{provide:v,useClass:y},e.compiler||{provide:I,useClass:M},e.parser||{provide:x,useClass:P},e.missingTranslationHandler||{provide:O,useClass:k},{provide:j,useValue:e.isolate},{provide:L,useValue:e.useDefaultLang},{provide:U,useValue:e.extend},{provide:N,useValue:e.defaultLanguage},F]}}}]),t}();return t.\u0275mod=i.Mb({type:t}),t.\u0275inj=i.Lb({factory:function(e){return new(e||t)}}),t}()},aEDl:function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0});var o=n("4Pxi"),a=n("n5WT"),s=n("LqyJ");e.default=function(t){function e(){var e=t.call(this)||this;return e.decodeMiddleCounters=[0,0,0,0],e}return r(e,t),e.prototype.decodeMiddle=function(t,n,i){var r=this.decodeMiddleCounters;r[0]=0,r[1]=0,r[2]=0,r[3]=0;for(var o=t.getSize(),s=n[1],c=0,u=0;u<6&&s=10&&(c|=1<<5-u)}for(i=e.determineFirstDigit(i,c),s=a.default.findGuardPattern(t,s,!0,a.default.MIDDLE_PATTERN,new Array(a.default.MIDDLE_PATTERN.length).fill(0))[1],u=0;u<6&&s0)("mat-toolbar-single-row",0===e._toolbarRows.length)},inputs:{color:"color"},exportAs:["matToolbar"],features:[i.zb],ngContentSelectors:l,decls:2,vars:0,template:function(t,e){1&t&&(i.lc(u),i.kc(0),i.kc(1,1))},styles:[".cdk-high-contrast-active .mat-toolbar{outline:solid 1px}.mat-toolbar-row,.mat-toolbar-single-row{display:flex;box-sizing:border-box;padding:0 16px;width:100%;flex-direction:row;align-items:center;white-space:nowrap}.mat-toolbar-multiple-rows{display:flex;box-sizing:border-box;flex-direction:column;width:100%}\n"],encapsulation:2,changeDetection:0}),t}(),p=function(){var t=function t(){C(this,t)};return t.\u0275mod=i.Mb({type:t}),t.\u0275inj=i.Lb({factory:function(e){return new(e||t)},imports:[[r.j],r.j]}),t}()},aaFr:function(t,e,n){"use strict";n.d(e,"a",(function(){return S}));var i=n("jL3B"),r=n("5XID"),o=n("Hq54"),a=n("kZht"),s=n("bwdy"),c=n("ZTXN"),u=n("g6G6"),l=n("jIqt"),d=n("TLy2"),h=n("J+dc"),f=n("hvMX"),p=n("bW1x"),g=n("njz0"),m=n("ROO/"),v=n("2yS1"),y=n("An66");function _(t,e){if(1&t){var n=a.Vb();a.Ub(0,"div",0),a.bc("keydown",(function(t){return a.Ec(n),a.fc()._handleKeydown(t)}))("click",(function(){return a.Ec(n),a.fc().closed.emit("click")}))("@transformMenu.start",(function(t){return a.Ec(n),a.fc()._onAnimationStart(t)}))("@transformMenu.done",(function(t){return a.Ec(n),a.fc()._onAnimationDone(t)})),a.kc(1),a.Tb()}if(2&t){var i=a.fc();a.mc("id",i.panelId)("ngClass",i._classList)("@transformMenu",i._panelAnimationState),a.Db("aria-label",i.ariaLabel||null)("aria-labelledby",i.ariaLabelledby||null)("aria-describedby",i.ariaDescribedby||null)}}var O=["*"],k=new a.s("sb-menu-default-options",{providedIn:"root",factory:function(){return{overlapTrigger:!1,xPosition:"center",yPosition:"below",backdropClass:"cdk-overlay-transparent-backdrop"}}}),T=0,S=function(){var t=function(){function t(e,n,i){C(this,t),this._elementRef=e,this._ngZone=n,this._defaultOptions=i,this._directDescendantItems=new a.F,this._tabSubscription=s.a.EMPTY,this._classList={},this._panelAnimationState="void",this._animationDone=new c.b,this.backdropClass=this._defaultOptions.backdropClass,this._xPosition=this._defaultOptions.xPosition,this._yPosition=this._defaultOptions.yPosition,this._overlapTrigger=this._defaultOptions.overlapTrigger,this._hasBackdrop=this._defaultOptions.hasBackdrop,this.closed=new a.o,this.panelId="sb-menu-panel-"+T++}return w(t,[{key:"ngOnInit",value:function(){this.setPositionClasses()}},{key:"ngAfterContentInit",value:function(){var t=this;this._updateDirectDescendants(),this._keyManager=new i.g(this._directDescendantItems).withWrap().withTypeAhead(),this._tabSubscription=this._keyManager.tabOut.subscribe((function(){return t.closed.emit("tab")})),this._directDescendantItems.changes.pipe(Object(l.a)(this._directDescendantItems),Object(d.a)((function(t){return Object(u.a).apply(void 0,b(t.map((function(t){return t.focused}))))}))).subscribe((function(e){return t._keyManager.updateActiveItem(e)}))}},{key:"ngOnDestroy",value:function(){this._directDescendantItems.destroy(),this._tabSubscription.unsubscribe(),this.closed.complete()}},{key:"_hovered",value:function(){return this._directDescendantItems.changes.pipe(Object(l.a)(this._directDescendantItems),Object(d.a)((function(t){return Object(u.a).apply(void 0,b(t.map((function(t){return t.hovered}))))})))}},{key:"_handleKeydown",value:function(t){var e=t.key,n=this._keyManager;switch(e){case"Escape":Object(o.r)(t)||(t.preventDefault(),this.closed.emit("keydown"));break;case"ArrowLeft":this.parentMenu&&"ltr"===this.direction&&this.closed.emit("keydown");break;case"ArrowRight":this.parentMenu&&"rtl"===this.direction&&this.closed.emit("keydown");break;case"Home":case"End":Object(o.r)(t)||("Home"===e?n.setFirstItemActive():n.setLastItemActive(),t.preventDefault());break;default:"ArrowUp"!==e&&"ArrowDown"!==e||n.setFocusOrigin("keyboard"),n.onKeydown(t)}}},{key:"focusFirstItem",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"program";this.lazyContent?this._ngZone.onStable.asObservable().pipe(Object(h.a)(1)).subscribe((function(){return t._focusFirstItem(e)})):this._focusFirstItem(e)}},{key:"_focusFirstItem",value:function(t){var e=this._keyManager;if(e.setFocusOrigin(t).setFirstItemActive(),!e.activeItem&&this._directDescendantItems.length)for(var n=this._directDescendantItems.first._getHostElement().parentElement;n;){if("menu"===n.getAttribute("role")){n.focus();break}n=n.parentElement}}},{key:"resetActiveItem",value:function(){this._keyManager.setActiveItem(-1)}},{key:"setPositionClasses",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.xPosition,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.yPosition,n=this._classList;n["sb-menu-center"]="center"===t,n["sb-menu-before"]="before"===t,n["sb-menu-after"]="after"===t,n["sb-menu-above"]="above"===e,n["sb-menu-below"]="below"===e}},{key:"_startAnimation",value:function(){this._panelAnimationState="enter"}},{key:"_resetAnimation",value:function(){this._panelAnimationState="void"}},{key:"_onAnimationDone",value:function(t){this._animationDone.next(t),this._isAnimating=!1}},{key:"_onAnimationStart",value:function(t){this._isAnimating=!0,"enter"===t.toState&&0===this._keyManager.activeItemIndex&&(t.element.scrollTop=0)}},{key:"_updateDirectDescendants",value:function(){var t=this;this._allItems.changes.pipe(Object(l.a)(this._allItems)).subscribe((function(e){t._directDescendantItems.reset(e.filter((function(e){return e.parentMenu===t}))),t._directDescendantItems.notifyOnChanges()}))}},{key:"xPosition",get:function(){return this._xPosition},set:function(t){["center","before","after"].includes(t)||Object(g.a)(),this._xPosition=t,this.setPositionClasses()}},{key:"yPosition",get:function(){return this._yPosition},set:function(t){"above"!==t&&"below"!==t&&Object(g.b)(),this._yPosition=t,this.setPositionClasses()}},{key:"overlapTrigger",set:function(t){this._overlapTrigger=Object(r.c)(t)},get:function(){return this._overlapTrigger}},{key:"hasBackdrop",set:function(t){this._hasBackdrop=Object(r.c)(t)},get:function(){return this._hasBackdrop}},{key:"panelClass",set:function(t){var e=this,n=this._previousPanelClass;n&&n.length&&n.split(" ").forEach((function(t){e._classList[t]=!1})),this._previousPanelClass=t,t&&t.length&&(t.split(" ").forEach((function(t){e._classList[t]=!0})),this._elementRef.nativeElement.className="")}}]),t}();return t.\u0275fac=function(e){return new(e||t)(a.Ob(a.l),a.Ob(a.B),a.Ob(k))},t.\u0275cmp=a.Ib({type:t,selectors:[["sb-menu"]],contentQueries:function(t,e,n){var i;1&t&&(a.Hb(n,p.a,!0),a.Hb(n,m.a,!0)),2&t&&(a.zc(i=a.cc())&&(e.lazyContent=i.first),a.zc(i=a.cc())&&(e._allItems=i))},viewQuery:function(t,e){var n;1&t&&a.Wc(a.N,!0),2&t&&a.zc(n=a.cc())&&(e.templateRef=n.first)},inputs:{backdropClass:"backdropClass",ariaLabel:["aria-label","ariaLabel"],ariaLabelledby:["aria-labelledby","ariaLabelledby"],ariaDescribedby:["aria-describedby","ariaDescribedby"],xPosition:"xPosition",yPosition:"yPosition",overlapTrigger:"overlapTrigger",hasBackdrop:"hasBackdrop",panelClass:["class","panelClass"]},outputs:{closed:"closed"},exportAs:["sbMenu"],features:[a.Bb([{provide:v.a,useExisting:t}])],ngContentSelectors:O,decls:1,vars:0,consts:[["tabindex","-1","role","menu",1,"sb-menu",3,"id","ngClass","keydown","click"]],template:function(t,e){1&t&&(a.lc(),a.Oc(0,_,2,6,"ng-template"))},directives:[y.l],styles:[".sb-menu[_ngcontent-%COMP%]{display:flex;flex-flow:column nowrap;padding:var(--spacing-s,5px);min-width:112px;color:var(--c,var(--text-colour,#fff));font-family:var(--typeface,Arial);background-color:var(--menu-bg,#000);border-radius:var(--bdrs,5px);border:1px solid var(--border-colour);box-shadow:0 4px 20px 0 rgba(0,0,0,.3)}.sb-menu[_ngcontent-%COMP%]:focus{outline:0}.sb-menu[_ngcontent-%COMP%]{--divider-size:calc(100% + var(--spacing-s) * 2);--divider-margin:var(--spacing-s) calc(var(--spacing-s) * -1);--divider-color:var(--border-colour)}"],data:{animation:[f.a]},changeDetection:0}),t}()},aeRQ:function(t,e,n){"use strict";n.d(e,"a",(function(){return N}));var i=n("ZTXN"),r=n("HM3f"),o=n("yBos"),a=n("xVbo"),s=n("Wg7D"),c=n("iT4G"),u=n("KQpv"),l=n.n(u),d=n("p5wL"),h=n("i67J"),f=n("TYVA"),p=n("nXdR"),g=n("sXtk"),v=n("uJYd"),y=n("GGXD"),_=n("+Px6"),O=n("ND+C"),k=n("1OAy"),T=n("h3eB"),S=n("lE9u"),E=n("vYTc"),x=n("H0/1"),P=n("wMit"),A=n("7KkP"),I=n("MUfl"),M=n("dWHr"),D=n("kZht"),R=n("zqNl"),j=n("aDqW"),L=l()("app:websocket"),N=function(){var t=function(){function t(e,n,o,c){var u=this;C(this,t),this.store=e,this.translateService=n,this.env=o,this.feature=c,this.liteTickers=new i.b,this.detailedTickers=new i.b,this.trades=new i.b,this.userWallets=new i.b,this.holdingWallets=new i.b,this.crypWallets=new i.b,this.flexWallet=new i.b,this.prices=new i.b,this.feeds=[],this.retryDelay=100,document.addEventListener("visibilitychange",(function(){document.hidden&&u.socket?(L("document hidden; closing all feeds except selected ticker"),u.socket.complete(),u.store.pipe(Object(h.n)(_.n)).subscribe((function(t){u.startSocket(),u.socket.next({event:"subscribe",feed:"ticker",product_ids:[t.symbol]})}))):u.restartSocket()})),this.prices.pipe(Object(h.c)(1e3,"base"),Object(a.a)((function(t){return t.size>0}))).subscribe((function(t){u.store.dispatch(Object(M.b)({prices:t}))})),this.liteTickers.pipe(Object(h.c)(1e3,"product_id"),Object(a.a)((function(t){return t.size>0}))).subscribe((function(t){u.store.dispatch(Object(O.b)({tickers:t}))})),this.trades.pipe(Object(h.d)(100),Object(a.a)((function(t){return t.length>0}))).subscribe((function(t){u.store.dispatch(Object(k.c)({trades:t}))})),this.detailedTickers.pipe(Object(h.c)(250,"product_id"),Object(a.a)((function(t){return t.size>0}))).subscribe((function(t){u.store.dispatch(Object(O.d)({tickers:t}))})),this.feature.isEnabled("flex")?Object(r.a)([this.holdingWallets,this.crypWallets,this.flexWallet]).pipe(Object(s.a)(1e3)).subscribe((function(t){var e=m(t,3),n=e[0],i=e[1],r=e[2],o=Object(p.k)(n),a=Object(p.i)(i),s=Object(p.j)(r);u.store.dispatch(Object(S.w)({margin:Object(d.c)([],"name"),futures:Object(d.c)(a,"name"),holding:Object(d.c)(o,"name"),flex:s}))})):this.userWallets.pipe(Object(s.a)(1e3)).subscribe((function(t){var e=t.filter((function(t){return t.name.startsWith("m-")})).map((function(t){return Object.assign(Object.assign({},t),{type:"margin",currency:Object(p.d)(t.name).toUpperCase(),pair:t.name.substring(2).replace(p.a,f.b)})})).map(p.l),n=t.filter((function(t){return t.name.startsWith("f-")})).map((function(t){return Object.assign(Object.assign({},t),{type:"futures",currency:Object(p.d)(t.name).toUpperCase(),pair:t.name.substring(2).replace(p.a,f.b)})})).map(p.l),i=t.filter((function(t){return!t.name.includes("-")})).map((function(t){return Object.assign(Object.assign({},t),{type:"holding",currency:t.name.toUpperCase()})})).map(p.l);u.store.dispatch(Object(S.w)({margin:Object(d.c)(e,"name"),futures:Object(d.c)(n,"name"),holding:Object(d.c)(i,"name")}))}))}return w(t,[{key:"openFeed",value:function(t){L("opening feed",t),this.socket||this.startSocket(),this.socket.next(Object.assign({event:"subscribe"},t)),this.feeds=[].concat(b(this.feeds),[t])}},{key:"closeFeed",value:function(t){L("closing feed",t),this.socket.next(Object.assign({event:"unsubscribe"},t)),this.feeds=this.feeds.filter((function(e){return e.feed!==t.feed}))}},{key:"closeAllFeeds",value:function(){var t=this;L("closing all feeds",b(this.feeds)),this.feeds.forEach((function(e){return t.socket.next(Object.assign({event:"unsubscribe"},e))}))}},{key:"restartSocket",value:function(){var t=this;this.socket&&this.socket.complete(),L("restarting socket",this.feeds),setTimeout((function(){t.startSocket(),t.feeds.forEach((function(e){return t.socket.next(Object.assign({event:"subscribe"},e))}))}),this.retryDelay)}},{key:"startSocket",value:function(){var t=this;L("starting socket"),this.socket=Object(o.a)(this.env.urls.websocket+"?general"),this.socket.next({event:"subscribe",feed:"heartbeat"}),this.socket.pipe(Object(c.a)(11e3)).subscribe((function(e){"event"in e?"error"===e.event&&t.handleError(e):t.handleResponse(e)}),(function(e){return t.handleError(e)}),(function(){return L("WS complete")}))}},{key:"handleResponse",value:function(t){if("prices_snapshot"===t.feed){var e=t.prices,n=Object(d.c)(e.map((function(t){return Object(E.b)(t)})),"base");this.store.dispatch(Object(M.b)({prices:n}))}if("prices"!==t.feed)if("ticker"!==t.feed)if("ticker_lite"!==t.feed)if("trade_snapshot"!==t.feed)if("trade"!==t.feed)if("account_balances_and_margins"!==t.feed){if("balances_snapshot"===t.feed||"balances"===t.feed){var i=t.holding,r=t.futures,o=t.flex_futures;i&&Object.keys(i).length>0&&this.holdingWallets.next(i),r&&Object.keys(r).length>0&&this.crypWallets.next(r),o&&Object.keys(o).length>0&&this.flexWallet.next(o)}if("open_positions"!==t.feed)if("open_orders_snapshot"!==t.feed)if("open_orders"!==t.feed)if("fills_snapshot"!==t.feed)if("fills"!==t.feed)if("account_log_snapshot"!==t.feed){if("account_log"===t.feed){var a=t.new_entry;return"cross-exchange transfer"===a.info&&a.new_balance>a.old_balance&&this.store.dispatch(Object(v.j)({message:"SNACKBAR.CROSS_EXCHANGE_TRANSFER_SUCCESS"})),void("cross-exchange transfer failed"===a.info&&this.store.dispatch(Object(v.j)({message:"SNACKBAR.CROSS_EXCHANGE_TRANSFER_FAILED",class:"warn"})))}if("deposits_withdrawals"!==t.feed)if("notifications"!==t.feed)if("notifications_auth"!==t.feed)this.retryDelay=100;else{var s=t.notifications;this.store.dispatch(Object(y.d)({notifications:s}))}else{var c=t.notifications;this.store.dispatch(Object(y.e)({notifications:c}))}else{var u=t.elements;this.store.dispatch(Object(k.o)({transfers:u}))}}else this.store.dispatch(Object(k.m)({logs:Object(x.c)(t.logs)}));else this.store.dispatch(Object(T.a)({fills:Object(A.h)(t.fills)}));else this.store.dispatch(Object(T.k)({fills:Object(A.h)(t.fills)}));else{var l=t.is_cancel,h=t.order_id,f=t.order,p=t.reason;if(l){var b=h||f.order_id;this.store.dispatch(Object(T.i)({orderId:b}))}else this.store.dispatch(Object(T.b)({order:Object(A.i)(f)})),"full_fill"===p?this.store.dispatch(Object(v.j)({message:"SNACKBAR.ORDER_EXECUTED_FULL"})):"partial_fill"===p&&this.store.dispatch(Object(v.j)({message:this.translateService.instant("SNACKBAR.ORDER_PARTIALLY_FILLED_VARS",{filled:f.filled,total:f.filled+f.qty,qty:f.qty})}))}else this.store.dispatch(Object(T.l)({orders:Object(A.j)(t.orders)}));else this.store.dispatch(Object(T.m)({positions:Object(A.k)(t.positions)}))}else{var g=t.margin_accounts;this.userWallets.next(g)}else this.trades.next(t);else{var m=t.trades;this.store.dispatch(Object(k.p)({trades:m}))}else{var _=t;this.liteTickers.next(Object(E.c)(_))}else{var O=t;this.detailedTickers.next(Object(E.c)(O))}else{var w=t;this.prices.next(Object(E.b)(w))}}},{key:"handleError",value:function(t){console.error("websocket error",t);try{"invalid product id"===(null==t?void 0:t.message)&&this.store.dispatch(Object(P.c)())}catch(t){console.error(t)}this.retryDelay=Object(h.b)(this.retryDelay),L("General WS Error; Restarting in ".concat(this.retryDelay,"ms"),t),this.restartSocket()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(D.Yb(R.b),D.Yb(j.e),D.Yb(g.a),D.Yb(I.a))},t.\u0275prov=D.Kb({token:t,factory:t.\u0275fac}),t}()},afE0:function(t,e,n){"use strict";n.d(e,"a",(function(){return o}));var i=n("kZht"),r=n("NxuZ"),o=function(){var t=function t(){C(this,t)};return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=i.Ib({type:t,selectors:[["dialog-badge"]],inputs:{icon:"icon"},decls:1,vars:1,consts:[[3,"icon"]],template:function(t,e){1&t&&i.Pb(0,"fa-icon",0),2&t&&i.mc("icon",e.icon)},directives:[r.b],styles:["[_nghost-%COMP%]{display:block;text-align:center}fa-icon[_ngcontent-%COMP%]{display:inline-block;padding:var(--spacing);color:var(--accent-colour);font-size:34px;border:2px solid;border-radius:25%}"],changeDetection:0}),t}()},anA8:function(t,e,n){"use strict";n.d(e,"a",(function(){return Y}));var i=n("D57K"),r=n("kZht"),o=n("O30t"),a=n("LoUP"),s=n("EZWv"),c=n("gxtV"),u=n("jIqt"),l=n("UVqw"),d=n("IkSM"),h=n("B6Vo"),f=n("Cc4E"),p=n("zho4"),b=n("anSm"),g=n("1o0v"),m=n("yPvj"),v=n("rBBj"),y=n("chaP"),_=n("+I9z"),O=n("NxuZ"),k=n("aDqW"),T=n("An66"),S=n("rUBT"),E=n("rqGg"),x=n("DpwM");function P(t,e){1&t&&r.Pb(0,"tr",22)}function A(t,e){1&t&&r.Pb(0,"tr",23)}var I=function(){return[250,100]};function M(t,e){if(1&t&&(r.Ub(0,"th",24),r.Qc(1),r.gc(2,"translate"),r.Tb()),2&t){var n=r.fc();r.mc("sbDisabled",!n.displayTooltips)("sbDelay",r.qc(5,I)),r.Cb(1),r.Sc(" ",r.hc(2,3,"COLUMN.DATE_TIME")," ")}}function D(t,e){if(1&t&&(r.Ub(0,"td",25),r.Ub(1,"span"),r.Qc(2),r.gc(3,"date"),r.Tb(),r.Ub(4,"span",26),r.Qc(5),r.gc(6,"date"),r.Tb(),r.Tb()),2&t){var n=e.$implicit;r.Cb(2),r.Rc(r.ic(3,2,n.time,"HH:mm:ss")),r.Cb(3),r.Rc(r.ic(6,5,n.time,"dd/MMM/yyyy"))}}function R(t,e){if(1&t&&(r.Ub(0,"th",27),r.Qc(1),r.gc(2,"translate"),r.Tb()),2&t){var n=r.fc();r.mc("sbDisabled",!n.displayTooltips)("sbDelay",r.qc(5,I)),r.Cb(1),r.Sc(" ",r.hc(2,3,"COLUMN.MARKET")," ")}}function j(t,e){if(1&t&&(r.Ub(0,"td",28),r.Pb(1,"market-icon",29),r.gc(2,"base"),r.Qc(3),r.gc(4,"uppercase"),r.gc(5,"contractFamily"),r.gc(6,"pair"),r.gc(7,"translate"),r.gc(8,"maturityMonth"),r.Tb()),2&t){var n=e.$implicit;r.Cb(1),r.mc("base",r.hc(2,4,n.instrument)),r.Cb(2),r.Uc(" ",r.hc(4,6,r.hc(5,8,n.instrument))," ",r.hc(6,10,n.instrument)," ",r.hc(7,12,r.ic(8,14,n.instrument,"short"))," ")}}function L(t,e){if(1&t&&(r.Ub(0,"th",30),r.Qc(1),r.gc(2,"translate"),r.Tb()),2&t){var n=r.fc();r.mc("sbDisabled",!n.displayTooltips)("sbDelay",r.qc(5,I)),r.Cb(1),r.Sc(" ",r.hc(2,3,"COLUMN.TYPE")," ")}}function N(t,e){if(1&t&&(r.Ub(0,"td",28),r.Qc(1),r.gc(2,"titlecase"),r.Tb()),2&t){var n=e.$implicit;r.Cb(1),r.Sc(" ",r.hc(2,1,n.fill_type)," ")}}function U(t,e){if(1&t&&(r.Ub(0,"th",31),r.Qc(1),r.gc(2,"translate"),r.Tb()),2&t){var n=r.fc();r.mc("sbDisabled",!n.displayTooltips)("sbDelay",r.qc(5,I)),r.Cb(1),r.Sc(" ",r.hc(2,3,"COLUMN.SIDE")," ")}}function F(t,e){if(1&t&&(r.Ub(0,"td",32),r.Ub(1,"strong",33),r.Qc(2),r.gc(3,"translate"),r.Tb(),r.Tb()),2&t){var n=e.$implicit;r.Cb(1),r.mc("pnlBool",n.buy),r.Cb(1),r.Sc(" ",r.hc(3,2,n.buy?"SIDE.BUY":"SIDE.SELL")," ")}}function B(t,e){if(1&t&&(r.Ub(0,"th",34),r.Qc(1),r.gc(2,"translate"),r.Tb()),2&t){var n=r.fc();r.mc("sbDisabled",!n.displayTooltips)("sbDelay",r.qc(5,I)),r.Cb(1),r.Sc(" ",r.hc(2,3,"COLUMN.SIZE")," ")}}function z(t,e){if(1&t&&(r.Ub(0,"td",35),r.Pb(1,"ghost-trail",36),r.Qc(2),r.Ub(3,"span",26),r.Qc(4),r.gc(5,"asset"),r.Tb(),r.Tb()),2&t){var n=e.$implicit;r.Cb(1),r.nc("content",n.displayQty),r.mc("showZeros",!1),r.Cb(1),r.Sc(" "," "," "),r.Cb(2),r.Rc(r.hc(5,4,n.tradingDisplayAsset))}}function V(t,e){if(1&t&&(r.Ub(0,"th",37),r.Qc(1),r.gc(2,"translate"),r.Tb()),2&t){var n=r.fc();r.mc("sbDisabled",!n.displayTooltips)("sbDelay",r.qc(5,I)),r.Cb(1),r.Sc(" ",r.hc(2,3,"COLUMN.FILL_PRICE")," ")}}function H(t,e){if(1&t&&(r.Ub(0,"td",25),r.Ub(1,"span",38),r.Qc(2),r.gc(3,"sato"),r.Tb(),r.Ub(4,"span",26),r.Qc(5),r.gc(6,"quote"),r.Tb(),r.Tb()),2&t){var n=e.$implicit;r.Cb(2),r.Rc(r.ic(3,2,n.price,n)),r.Cb(3),r.Rc(r.hc(6,5,n.instrument))}}function q(t,e){1&t&&r.Pb(0,"th",39)}function $(t,e){if(1&t){var n=r.Vb();r.Ub(0,"td",28),r.Ub(1,"div",40),r.bc("click",(function(t){r.Ec(n);var i=e.$implicit;return r.fc().viewDetailed.emit(i),t.stopPropagation()})),r.Pb(2,"fa-icon",41),r.Ub(3,"p"),r.Qc(4),r.gc(5,"translate"),r.Tb(),r.Tb(),r.Tb()}2&t&&(r.Cb(4),r.Rc(r.hc(5,1,"BUTTON.DETAILS")))}var Q=function(){return{small:100,medium:400,large:800}},W=function(){return[10,20,50]},G=function(t,e){var n={symbol:t.instrument,fill_price:t.price,size:t.qty};return e in n?n[e]:t[e]},Y=function(){var t=function(){function t(){C(this,t),this.tableColumns=["time","symbol","type","side","size","fill_price","order_actions"],this.tableData=new o.k([]),this.viewDetailed=new r.o}return w(t,[{key:"ngOnInit",value:function(){this.tableData.sortingDataAccessor=G,this.tableData.paginator=this.tablePaginator}},{key:"ngAfterViewInit",value:function(){var t=this;this.tableSort.changes.pipe(Object(u.a)(this.tableSort),Object(c.b)(this)).subscribe((function(e){e.first&&(t.tableData.sort=e.first)}))}},{key:"trackByFillId",value:function(t,e){return e.fill_id}},{key:"fills",set:function(t){this.tableData.data=t.valueSeq().toArray()}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=r.Ib({type:t,selectors:[["filled-orders-desktop"]],viewQuery:function(t,e){var n;1&t&&(r.Jc(s.a,!0),r.Wc(a.a,!0)),2&t&&(r.zc(n=r.cc())&&(e.tablePaginator=n.first),r.zc(n=r.cc())&&(e.tableSort=n))},inputs:{fills:"fills",displayTooltips:"displayTooltips"},outputs:{viewDetailed:"viewDetailed"},decls:25,vars:10,consts:[["breakpoint","","mat-table","","matSort","",3,"breakpoints","dataSource","trackBy"],["mat-header-row","",4,"matHeaderRowDef","matHeaderRowDefSticky"],["mat-row","",4,"matRowDef","matRowDefColumns"],["matColumnDef","time"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.FILLED_ORDERS.DATE",3,"sbDisabled","sbDelay",4,"matHeaderCellDef"],["class","block-cell","mat-cell","","body","",4,"matCellDef"],["matColumnDef","symbol"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.FILLED_ORDERS.SYMBOL",3,"sbDisabled","sbDelay",4,"matHeaderCellDef"],["mat-cell","","body","",4,"matCellDef"],["matColumnDef","type"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.FILLED_ORDERS.TYPE",3,"sbDisabled","sbDelay",4,"matHeaderCellDef"],["matColumnDef","side"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.FILLED_ORDERS.SIDE",3,"sbDisabled","sbDelay",4,"matHeaderCellDef"],["body","","mat-cell","",4,"matCellDef"],["matColumnDef","size"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.FILLED_ORDERS.SIZE",3,"sbDisabled","sbDelay",4,"matHeaderCellDef"],["mat-cell","","body","","mono","",4,"matCellDef"],["matColumnDef","fill_price"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.FILLED_ORDERS.FILL_PRICE",3,"sbDisabled","sbDelay",4,"matHeaderCellDef"],["matColumnDef","order_actions"],["body","","mat-header-cell","",4,"matHeaderCellDef"],[3,"pageSize","pageSizeOptions"],["mat-header-row",""],["mat-row",""],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.FILLED_ORDERS.DATE",3,"sbDisabled","sbDelay"],["mat-cell","","body","",1,"block-cell"],["ghost",""],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.FILLED_ORDERS.SYMBOL",3,"sbDisabled","sbDelay"],["mat-cell","","body",""],[3,"base"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.FILLED_ORDERS.TYPE",3,"sbDisabled","sbDelay"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.FILLED_ORDERS.SIDE",3,"sbDisabled","sbDelay"],["body","","mat-cell",""],[3,"pnlBool"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.FILLED_ORDERS.SIZE",3,"sbDisabled","sbDelay"],["mat-cell","","body","","mono",""],[3,"content","showZeros"],["mat-header-cell","","mat-sort-header","","tooltip","","sbTooltip","TOOLTIP.FILLED_ORDERS.FILL_PRICE",3,"sbDisabled","sbDelay"],["mono",""],["body","","mat-header-cell",""],["body","",1,"copy-button",3,"click"],["icon","file","size","lg"]],template:function(t,e){1&t&&(r.Ub(0,"table",0),r.Oc(1,P,1,0,"tr",1),r.Oc(2,A,1,0,"tr",2),r.Sb(3,3),r.Oc(4,M,3,6,"th",4),r.Oc(5,D,7,8,"td",5),r.Rb(),r.Sb(6,6),r.Oc(7,R,3,6,"th",7),r.Oc(8,j,9,17,"td",8),r.Rb(),r.Sb(9,9),r.Oc(10,L,3,6,"th",10),r.Oc(11,N,3,3,"td",8),r.Rb(),r.Sb(12,11),r.Oc(13,U,3,6,"th",12),r.Oc(14,F,4,4,"td",13),r.Rb(),r.Sb(15,14),r.Oc(16,B,3,6,"th",15),r.Oc(17,z,6,6,"td",16),r.Rb(),r.Sb(18,17),r.Oc(19,V,3,6,"th",18),r.Oc(20,H,7,7,"td",5),r.Rb(),r.Sb(21,19),r.Oc(22,q,1,0,"th",20),r.Oc(23,$,6,3,"td",8),r.Rb(),r.Tb(),r.Pb(24,"mat-paginator",21)),2&t&&(r.mc("breakpoints",r.qc(8,Q))("dataSource",e.tableData)("trackBy",e.trackByFillId),r.Cb(1),r.mc("matHeaderRowDef",e.tableColumns)("matHeaderRowDefSticky",!0),r.Cb(1),r.mc("matRowDefColumns",e.tableColumns),r.Cb(22),r.mc("pageSize",20)("pageSizeOptions",r.qc(9,W)))},directives:[o.j,l.a,a.a,o.g,o.i,o.c,o.e,o.b,s.a,o.f,o.h,o.d,a.b,d.a,h.a,f.a,p.a,o.a,b.a,g.a,m.a,v.a,y.a,_.a,O.b],pipes:[k.d,T.e,S.a,T.x,S.c,S.e,S.d,T.w,E.a,x.c,S.f],styles:["market-icon[_ngcontent-%COMP%]{font-size:20px}table[_ngcontent-%COMP%] .mat-row[_ngcontent-%COMP%]{height:calc(var(--table-row-height) + var(--spacing))!important}table[_ngcontent-%COMP%] .mat-cell[_ngcontent-%COMP%]:last-of-type, table[_ngcontent-%COMP%] .mat-header-cell[_ngcontent-%COMP%]:last-of-type{text-align:right}.block-cell[_ngcontent-%COMP%] > span[_ngcontent-%COMP%]{display:block;line-height:1.25em}.actions-header[_ngcontent-%COMP%]{cursor:pointer}.actions-header[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{display:inline}.actions-header[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{color:var(--warn-colour);margin-right:var(--spacing-s)}.actions-header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{color:var(--warn-colour);text-transform:capitalize!important}.cancel-button[_ngcontent-%COMP%], .copy-button[_ngcontent-%COMP%], .edit-button[_ngcontent-%COMP%], .info-button[_ngcontent-%COMP%], .limit-button[_ngcontent-%COMP%], .market-button[_ngcontent-%COMP%]{cursor:pointer;display:inline-block}.cancel-button[_ngcontent-%COMP%] > *[_ngcontent-%COMP%], .copy-button[_ngcontent-%COMP%] > *[_ngcontent-%COMP%], .edit-button[_ngcontent-%COMP%] > *[_ngcontent-%COMP%], .info-button[_ngcontent-%COMP%] > *[_ngcontent-%COMP%], .limit-button[_ngcontent-%COMP%] > *[_ngcontent-%COMP%], .market-button[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{display:inline}.cancel-button[_ngcontent-%COMP%] p[_ngcontent-%COMP%], .copy-button[_ngcontent-%COMP%] p[_ngcontent-%COMP%], .edit-button[_ngcontent-%COMP%] p[_ngcontent-%COMP%], .info-button[_ngcontent-%COMP%] p[_ngcontent-%COMP%], .limit-button[_ngcontent-%COMP%] p[_ngcontent-%COMP%], .market-button[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{padding-left:var(--spacing-s)}.copy-button[_ngcontent-%COMP%], .edit-button[_ngcontent-%COMP%], .info-button[_ngcontent-%COMP%], .limit-button[_ngcontent-%COMP%], .market-button[_ngcontent-%COMP%]{margin-right:var(--spacing)}.copy-button[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%], .edit-button[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%], .info-button[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%], .limit-button[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%], .market-button[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{color:var(--brand)}.cancel-button[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{color:var(--warn-colour)}.cancel-all-button[_ngcontent-%COMP%]{cursor:pointer}.cancel-all-button[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{display:inline}.cancel-all-button[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{color:var(--warn-colour);margin-right:var(--spacing-s)}.cancel-all-button[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{color:var(--warn-colour);text-transform:capitalize!important}table[breakpoint=medium][_ngcontent-%COMP%] .copy-button[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{display:none}"],changeDetection:0}),t=Object(i.d)([Object(c.a)()],t)}()},anSm:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("kZht"),r=function(){var t=function(){function t(e,n){C(this,t),this.renderer=e,this.element=n}return w(t,[{key:"ngOnInit",value:function(){this.renderer.addClass(this.element.nativeElement,"global__text"),this.renderer.addClass(this.element.nativeElement,"global__text-body")}}]),t}();return t.\u0275fac=function(e){return new(e||t)(i.Ob(i.G),i.Ob(i.l))},t.\u0275dir=i.Jb({type:t,selectors:[["","body",""]]}),t}()},aygZ:function(t,e,n){"use strict";n.d(e,"a",(function(){return s}));var i=n("kZht"),r=n("hCLc"),o=n("NxuZ"),a=["*"],s=function(){var t=function(){function t(){C(this,t),this.dismissed=null,this.dismissEvent=new i.o}return w(t,[{key:"dismiss",value:function(){this.dismissed=!0,this.dismissEvent.emit()}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=i.Ib({type:t,selectors:[["popup-banner"]],hostVars:1,hostBindings:function(t,e){2&t&&i.Db("dismissed",e.dismissed)},outputs:{dismissEvent:"dismiss"},ngContentSelectors:a,decls:4,vars:0,consts:[["mat-button","","color","positive",3,"click"],["icon","close-large","size","2x"]],template:function(t,e){1&t&&(i.lc(),i.Ub(0,"section"),i.kc(1),i.Tb(),i.Ub(2,"button",0),i.bc("click",(function(){return e.dismiss()})),i.Pb(3,"fa-icon",1),i.Tb())},directives:[r.b,o.b],styles:["[_nghost-%COMP%]{position:fixed;bottom:0;width:100%;z-index:10;display:grid;grid-template-columns:1fr auto;padding:var(--spacing);color:var(--text-colour);text-align:center;background:rgba(var(--accent-colour-rgb),.8);box-shadow:0 0 10px rgba(0,0,0,.5)}@supports ((-webkit-backdrop-filter:blur(0)) or (backdrop-filter:blur(0))){[_nghost-%COMP%]{-webkit-backdrop-filter:blur(5px);backdrop-filter:blur(5px);background:rgba(var(--accent-colour-rgb),.6)}}@media (max-width:1024px){[_nghost-%COMP%]{bottom:46px}}[dismissed][_nghost-%COMP%]{display:none}section[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center}"],changeDetection:0}),t}()},bBQR:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("kZht"),r=function(){var t=function(){function t(e,n){C(this,t),this.renderer=e,this.element=n}return w(t,[{key:"ngOnInit",value:function(){this.renderer.addClass(this.element.nativeElement,"global__text"),this.renderer.addClass(this.element.nativeElement,"global__text-heading")}}]),t}();return t.\u0275fac=function(e){return new(e||t)(i.Ob(i.G),i.Ob(i.l))},t.\u0275dir=i.Jb({type:t,selectors:[["","heading",""]]}),t}()},bCr7:function(t,e,n){"use strict";n.d(e,"a",(function(){return i})),n.d(e,"b",(function(){return r})),n.d(e,"c",(function(){return a})),n.d(e,"f",(function(){return s})),n.d(e,"e",(function(){return c})),n.d(e,"d",(function(){return u}));var i=function(){function t(e){C(this,t),this.components=e}return w(t,[{key:"withOpacity",value:function(t){return"rgba(".concat(this.rgbPartial,", ").concat(t,")")}},{key:"toString",value:function(){return"rgba(".concat(this.rgbaPartial,")")}},{key:"rgba",get:function(){return this.components}},{key:"rgbaPartial",get:function(){return this.components.join(", ")}},{key:"rgb",get:function(){return this.components.slice(0,3)}},{key:"rgbPartial",get:function(){return this.rgb.join(", ")}}],[{key:"fromRgba",value:function(e,n,i,r){return new t([e,n,i,r])}},{key:"fromRgb",value:function(e,n,i){return t.fromRgba(e,n,i,1)}},{key:"fromGrey",value:function(e){return t.fromRgb(e,e,e)}},{key:"fromHex",value:function(e){return t.fromRgb(e>>16&255,e>>8&255,255&e)}}]),t}();function r(t,e){return{width:t,height:e}}var o=n("lx5p");function a(t,e){return{x:t,y:e}}function s(t){var e=Object(o.H)(t);return function(t){var n=t.x,i=t.y;return a(e(n),e(i))}}function c(t){return function(e){return a(e.x+t.x,e.y+t.y)}}function u(t){var e=t.orientation,n=t.center;return function(t){var i=t.x,r=t.y;return"horizontal"===e?a(n.x+(n.x-i),r):a(i,n.y+(n.y-r))}}},bSqp:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.VideoInputDevice=function(){function t(t,e,n){this.deviceId=t,this.label=e,this.kind="videoinput",this.groupId=n||void 0}return t.prototype.toJSON=function(){return{kind:this.kind,groupId:this.groupId,deviceId:this.deviceId,label:this.label}},t}()},bT3u:function(t,e,n){var i=n("67SP"),r=n("r9nU");e.mul=function(t,e){var n=new i(t.length+e.length-1);n.fill(0);for(var o=0;o=0;){for(var o=n[0],a=0;a0&&void 0!==arguments[0]?arguments[0]:{};this.portal||(this.portal=new o.h(this.template,this.vcr)),this.detach(),this.outlet||(this.outlet=new o.e(this.document.createElement("div"),this.componentFactoryResolver,this.appRef,this.injector));var e=this.template.elementRef.nativeElement;e.parentNode.insertBefore(this.outlet.outletElement,e),this.cdr.markForCheck(),this.portal.attach(this.outlet,t),this.attached.next()}},{key:"detach",value:function(){this.portal.isAttached&&this.portal.detach()}},{key:"ngOnDestroy",value:function(){var t;null===(t=this.outlet)||void 0===t||t.dispose()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(i.Ob(i.N),i.Ob(i.j),i.Ob(i.g),i.Ob(i.t),i.Ob(i.R),i.Ob(i.h),i.Ob(r.d))},t.\u0275dir=i.Jb({type:t,selectors:[["ng-template","sbMenuContent",""]]}),t}()},bZCB:function(t,e,n){"use strict";n.d(e,"a",(function(){return y}));var i=n("zqNl"),r=n("+Px6"),o=n("qAYy"),a=n("sxqi"),s=n("xVbo"),c=n("Wg7D"),u=n("kZht"),l=n("An66"),d=n("3W1Y"),h=n("yPvj"),f=n("+e22"),p=n("rUBT");function b(t,e){if(1&t){var n=u.Vb();u.Ub(0,"div",4),u.bc("click",(function(){u.Ec(n);var t=e.$implicit;return u.fc(2).navTicker(t)})),u.Ub(1,"p",5),u.Pb(2,"market-icon",6),u.gc(3,"base"),u.Qc(4),u.Pb(5,"change",7),u.Tb(),u.Tb()}if(2&t){var i=e.$implicit;u.Cb(2),u.mc("base",u.hc(3,3,i.product_id)),u.Cb(2),u.Sc(" ",i.pair," "),u.Cb(1),u.mc("value",i.change)}}function g(t,e){if(1&t&&(u.Sb(0),u.Oc(1,b,6,5,"div",3),u.gc(2,"async"),u.Rb()),2&t){var n=u.fc();u.Cb(1),u.mc("ngForOf",u.hc(2,1,n.flexTickers$))}}function m(t,e){if(1&t){var n=u.Vb();u.Ub(0,"div",4),u.bc("click",(function(){u.Ec(n);var t=e.$implicit;return u.fc(2).navTicker(t)})),u.Ub(1,"p",5),u.Pb(2,"market-icon",6),u.gc(3,"base"),u.Qc(4),u.Pb(5,"change",7),u.Tb(),u.Tb()}if(2&t){var i=e.$implicit;u.Cb(2),u.mc("base",u.hc(3,3,i.product_id)),u.Cb(2),u.Sc(" ",i.pair," "),u.Cb(1),u.mc("value",i.change)}}function v(t,e){if(1&t&&(u.Oc(0,m,6,5,"div",3),u.gc(1,"async")),2&t){var n=u.fc();u.mc("ngForOf",u.hc(1,1,n.legacyTickers$))}}var y=function(){var t=function(){function t(e,n){C(this,t),this.store=e,this.market=n,this.isFlexMarket$=this.store.pipe(Object(i.m)(r.a)),this.legacyTickers$=this.store.pipe(Object(i.m)(o.j),Object(s.a)((function(t){return t.length>0})),Object(c.a)(6e4)),this.flexTickers$=this.store.pipe(Object(i.m)(o.f),Object(s.a)((function(t){return t.length>0})),Object(c.a)(6e4))}return w(t,[{key:"navTicker",value:function(t){this.market.navigateToMarket(t.product_id,!0)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(u.Ob(i.b),u.Ob(a.a))},t.\u0275cmp=u.Ib({type:t,selectors:[["ticker-bar"]],decls:5,vars:4,consts:[[1,"ticker-bar"],[4,"ngIf","ngIfElse"],["legacyTickers",""],["class","ticker",3,"click",4,"ngFor","ngForOf"],[1,"ticker",3,"click"],["caption",""],[3,"base"],[3,"value"]],template:function(t,e){if(1&t&&(u.Ub(0,"section",0),u.Oc(1,g,3,3,"ng-container",1),u.gc(2,"async"),u.Tb(),u.Oc(3,v,2,3,"ng-template",null,2,u.Pc)),2&t){var n=u.Ac(4);u.Cb(1),u.mc("ngIf",u.hc(2,2,e.isFlexMarket$))("ngIfElse",n)}},directives:[l.n,l.m,d.a,h.a,f.a],pipes:[l.b,p.a],styles:[".ticker-bar[_ngcontent-%COMP%]{display:flex;flex-direction:row;width:100%;flex-wrap:wrap;overflow-y:hidden;background:var(--toolbar-colour);border:1px solid var(--border-colour);border-radius:var(--bdrs);padding-left:var(--spacing);height:20px}.ticker-bar[_ngcontent-%COMP%] .ticker[_ngcontent-%COMP%]{white-space:nowrap;display:inline-flex;box-sizing:border-box;cursor:pointer;padding:3px var(--spacing-l) 3px var(--spacing-l);border-radius:var(--bdrs)}.ticker-bar[_ngcontent-%COMP%] .ticker[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{vertical-align:middle}.ticker-bar[_ngcontent-%COMP%] .ticker[_ngcontent-%COMP%]:hover{background-color:var(--table-row-alt)}"],changeDetection:0}),t}()},bjK4:function(t,e,n){"use strict";n.d(e,"a",(function(){return g})),n.d(e,"n",(function(){return _})),n.d(e,"e",(function(){return k})),n.d(e,"h",(function(){return w})),n.d(e,"d",(function(){return T})),n.d(e,"c",(function(){return S})),n.d(e,"o",(function(){return x})),n.d(e,"p",(function(){return P})),n.d(e,"j",(function(){return I})),n.d(e,"l",(function(){return M})),n.d(e,"b",(function(){return D})),n.d(e,"i",(function(){return R})),n.d(e,"k",(function(){return j})),n.d(e,"g",(function(){return U})),n.d(e,"m",(function(){return F})),n.d(e,"q",(function(){return B})),n.d(e,"f",(function(){return z}));var i=n("zqNl"),r=n("og7C"),o=n("VmIW"),a=n("p5wL"),s=n("lx5p"),c=n("rTkt"),u=n("uJYd"),l=n("NloN"),d=n("ylpo"),h=n("QmxK"),f=n("5JSY"),p=[1,2,5,10,20,50,100,200,500,1e3,2e3,5e3],b=p.length-1,g={"trading-dashboard":8,wallets:5,workspaces:6,flex:5},v={pageTitle:"",navigation:{internal:[{name:"NAV.PLATFORM",route:"/futures",icon:"trade",alwaysDisplay:!1},{name:"NAV.WALLETS",route:"/wallets",icon:"wallet",alwaysDisplay:!1},{name:"NAV.LOGS",route:"/history",icon:"list",alwaysDisplay:!1},{name:"NAV.SETTINGS",route:"/settings",icon:"cog",alwaysDisplay:!0},{name:"NAV.VERIFICATION",route:"/verification",icon:"check",alwaysDisplay:!0},{name:"NAV.ASSIGNMENT",route:"/assignment",icon:"thunder",alwaysDisplay:!0},{name:"NAV.SUPPORT",route:"/support",icon:"support",alwaysDisplay:!1}],external:[{name:"NAV.EXTERNAL_INDICES",url:"https://www.cfbenchmarks.com/"},{name:"NAV.EXTERNAL_RESOURCES",supportCategory:360001977131},{name:"NAV.EXTERNAL_API",url:"https://support.kraken.com/hc/en-us/sections/360012894412-Futures-API"},{name:"NAV.EXTERNAL_TESTING",supportArticle:360024809011},{name:"NAV.EXTERNAL_HISTORY",supportArticle:360022835871},{name:"NAV.EXTERNAL_RISK",supportArticle:360022629052},{name:"NAV.EXTERNAL_BOT_PARTNERS",supportArticle:360041402071}]},loadingActions:Object(r.f)(),orderbook:{depth:1,grouping:Object(l.b)(d.k,1)},theme:"dark",alt:!1,systemHealth:{"trading-rest":Object(o.None)(),"trading-ws":Object(o.None)(),auth:Object(o.None)(),charts:Object(o.None)()},tour:{type:"trading-dashboard",inProgress:!1,step:1,total:g["trading-dashboard"]},layoutType:Object(l.b)(d.m,"draggable"),enableChartPointer:!0},y=Object(i.i)(v,Object(i.k)(u.y,(function(t,e){var n=e.title;return Object(a.b)(n,t,"pageTitle")})),Object(i.k)(u.b,(function(t,e){var n=e.action;return Object(a.b)(t.loadingActions.add(n),t,"loadingActions")})),Object(i.k)(u.o,(function(t,e){var n=e.action;return Object(a.b)(t.loadingActions.remove(n),t,"loadingActions")})),Object(i.k)(u.v,(function(t,e){var n=e.depth;return Object(a.b)(n,t,"orderbook","depth")})),Object(i.k)(u.w,(function(t,e){var n=e.direction,i=p.indexOf(t.orderbook.grouping);return"plus"===n&&i0?(Object(l.c)(d.k,p[i-1]),Object(a.b)(p[i-1],t,"orderbook","grouping")):t})),Object(i.k)(u.q,(function(t,e){var n=e.theme;return Object(a.b)(n,t,"theme")})),Object(i.k)(u.s,(function(t,e){var n=e.alt;return Object(a.b)(n,t,"alt")})),Object(i.k)(u.t,(function(t,e){var n=e.enable;return Object(a.b)(n,t,"enableChartPointer")})),Object(i.k)(u.z,(function(t,e){var n=e.health,i=Object.entries(n).map((function(t){var e=m(t,2),n=e[0],i=e[1];return[n,o.Maybe.fromNull(i)]}));return Object(a.a)(Object.fromEntries(i),t,"systemHealth")})),Object(i.k)(u.A,(function(t,e){var n=e.tour;return Object(a.b)({type:n,inProgress:!0,step:1,total:g[n]},t,"tour")})),Object(i.k)(u.d,(function(t,e){return Object(a.b)(Object.assign(Object.assign({},t.tour),{inProgress:!1,step:1}),t,"tour")})),Object(i.k)(u.f,(function(t,e){return Object(a.b)(t.tour.step+1,t,"tour","step")})),Object(i.k)(u.m,(function(t,e){return Object(a.b)(Math.max(t.tour.step-1,1),t,"tour","step")})),Object(i.k)(u.u,(function(t,e){var n=e.layout;return Object(l.c)(d.m,n),Object(a.b)(n,t,"layoutType")})));function _(t,e){return y(t,e)}var O=Object(i.h)("layout"),k=Object(i.j)(O,(function(t){return t.layoutType})),w=Object(i.j)(O,(function(t){return t.pageTitle})),C=Object(i.j)(O,(function(t){return t.navigation})),T=Object(i.j)(C,(function(t){return t.internal})),S=Object(i.j)(C,(function(t){return t.external})),E=Object(i.j)(O,(function(t){return t.orderbook})),x=Object(i.j)(E,(function(t){return t.depth})),P=Object(i.j)(E,(function(t){return t.grouping})),A=Object(i.j)(O,(function(t){return t.loadingActions})),I=Object(i.j)(O,(function(t){return t.theme})),M=Object(i.j)(O,(function(t){return t.alt})),D=Object(i.j)(O,(function(t){return t.enableChartPointer})),R=Object(i.j)(O,(function(t){return t.systemHealth})),j=Object(i.j)(O,(function(t){return t.tour})),L=Object(i.j)(R,(function(t){return Object(r.b)(t).filter((function(t,e){return h.b[e]})).toObject()})),N=Object(i.j)(R,(function(t){return Object(r.b)(t).filter((function(t,e){return!h.b[e]})).toObject()})),U=Object(i.j)(R,L,N,(function(t,e,n){return Object.values(t).some(s.q)?Object(o.None)():t["trading-rest"].contains("maintenance")?Object(o.Some)("maintenance"):Object(r.b)(e).some((function(t){return t.contains("offline")}))?Object(o.Some)("offline"):Object(r.b)(e).some((function(t){return t.contains("degraded")}))||Object(r.b)(n).some((function(t){return t.contains("offline")||t.contains("degraded")}))?Object(o.Some)("degraded"):Object(o.Some)("operational")})),F=Object(i.j)(A,(function(t,e){var n=Array.isArray(e.filter)?Object(r.f)(e.filter):r.f.of(e.filter);return!t.intersect(n).isEmpty()})),B=Object(i.j)(I,c.b),z=Object(i.j)(B,f.a,(function(t,e,n){var i="assets/images/".concat(e,"/logo"),r=[];return"dark"===t&&r.push("white"),n&&(n.badge&&r.push("badge"),n.demo&&r.push("demo")),i+(r.length>0?"_"+r.join("-"):"")+".svg"}))},"bo+2":function(t,e,n){"use strict";n.d(e,"b",(function(){return a})),n.d(e,"a",(function(){return s}));var i=n("kZht"),r=n("An66"),o=n("VbQ3"),a=function(){var t=function t(e){var n=this;C(this,t),this.ngFor=e,this.ngFor.ngForTrackBy=function(t,e){return n.field?e[n.field]:e}};return t.\u0275fac=function(e){return new(e||t)(i.Ob(r.m,1))},t.\u0275dir=i.Jb({type:t,selectors:[["","ngForTrackField",""]],inputs:{field:["ngForTrackField","field"]}}),t}(),s=function(){var t=function t(e){var n=this;C(this,t),this.cdkVirtualFor=e,this.cdkVirtualFor.cdkVirtualForTrackBy=function(t,e){return n.field?e[n.field]:e}};return t.\u0275fac=function(e){return new(e||t)(i.Ob(o.d,1))},t.\u0275dir=i.Jb({type:t,selectors:[["","cdkVirtualForTrackField",""]],inputs:{field:["cdkVirtualForTrackField","field"]}}),t}()},bv5E:function(t,e,n){"use strict";n.d(e,"a",(function(){return b}));var i=n("kZht"),r=n("3kIJ"),o=function(t){return t.MultiCollateral="MULTI_COLLATERAL",t.SingleCollateral="SINGLE_COLLATERAL",t}({}),a=n("EmXI"),s=n("IOEv"),c=n("An66"),u=n("hCLc"),l=n("pTnX"),d=n("aDqW");function h(t,e){if(1&t&&(i.Ub(0,"mat-option",5),i.Qc(1),i.Tb()),2&t){var n=e.$implicit,r=i.fc();i.mc("value",n),i.Cb(1),i.Sc(" ",r.getWalletLabel(n)," ")}}var p,b=((p=function(){function t(e){var n;C(this,t),this.formBuilder=e,this.form=this.buildForm(),this.walletLabels=(f(n={},o.MultiCollateral,"Multi-Collateral Wallet"),f(n,o.SingleCollateral,"Single Collateral Wallets"),n),this.changeTransferPreference$=new i.o}return w(t,[{key:"ngOnChanges",value:function(t){t.defaultTransferPreference&&t.defaultTransferPreference.currentValue&&(this.form=this.buildForm())}},{key:"buildForm",value:function(){return this.formBuilder.group({transferPreference:[this.defaultTransferPreference,r.x.required]})}},{key:"submitForm",value:function(){var t=this.form.value.transferPreference;this.changeTransferPreference$.emit(t)}},{key:"getWalletLabel",value:function(t){return this.walletLabels[t]}}]),t}()).\u0275fac=function(t){return new(t||p)(i.Ob(r.d))},p.\u0275cmp=i.Ib({type:p,selectors:[["inbound-transfer-dropdown"]],inputs:{availablePreferences:"availablePreferences",defaultTransferPreference:"defaultTransferPreference"},outputs:{changeTransferPreference$:"changeTransferPreference"},features:[i.Ab],decls:10,vars:9,consts:[[1,"form",3,"formGroup","ngSubmit"],["color","accent","appearance","fill"],["matNativeControl","","formControlName","transferPreference"],[3,"value",4,"ngFor","ngForOf"],["mat-raised-button","",3,"disabled"],[3,"value"]],template:function(t,e){1&t&&(i.Ub(0,"form",0),i.bc("ngSubmit",(function(){return e.submitForm()})),i.Ub(1,"mat-form-field",1),i.Ub(2,"mat-label"),i.Qc(3),i.gc(4,"translate"),i.Tb(),i.Ub(5,"mat-select",2),i.Oc(6,h,2,2,"mat-option",3),i.Tb(),i.Tb(),i.Ub(7,"button",4),i.Qc(8),i.gc(9,"translate"),i.Tb(),i.Tb()),2&t&&(i.mc("formGroup",e.form),i.Cb(3),i.Rc(i.hc(4,5,"Wallet")),i.Cb(3),i.mc("ngForOf",e.availablePreferences),i.Cb(1),i.mc("disabled",e.form.invalid),i.Cb(1),i.Sc(" ",i.hc(9,7,"BUTTON.SAVE")," "))},directives:[r.z,r.p,r.h,a.c,a.f,s.a,r.o,r.g,c.m,u.b,l.n],pipes:[d.d],styles:[".form[_ngcontent-%COMP%]{padding-top:var(--spacing)}.form[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{padding-bottom:var(--spacing)}.form[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin-bottom:var(--spacing)}.form[_ngcontent-%COMP%] .mat-form-field[_ngcontent-%COMP%]{width:100%}"],changeDetection:0}),p)},bvVZ:function(t,e,n){"use strict";n.d(e,"a",(function(){return c}));var i=n("kZht"),r=n("An66"),o=["sbBadge",""];function a(t,e){if(1&t&&(i.Ub(0,"span",1),i.Qc(1),i.Tb()),2&t){var n=i.fc();i.Cb(1),i.Rc(n.content)}}var s=["*"],c=function(){var t=function(){function t(){C(this,t),this.show=!0,this._permClass=!0}return w(t,[{key:"content",get:function(){return this.rawContent.toString().trim()}}]),t}();return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=i.Ib({type:t,selectors:[["","sbBadge",""]],hostVars:2,hostBindings:function(t,e){2&t&&i.Gb("sb-badge",e._permClass)},inputs:{rawContent:["sbBadge","rawContent"],show:["sbBadgeShow","show"]},exportAs:["sbBadge"],attrs:o,ngContentSelectors:s,decls:2,vars:1,consts:[["class","sb-badge-content",4,"ngIf"],[1,"sb-badge-content"]],template:function(t,e){1&t&&(i.lc(),i.kc(0),i.Oc(1,a,2,1,"span",0)),2&t&&(i.Cb(1),i.mc("ngIf",e.show))},directives:[r.n],styles:[".sb-badge[_nghost-%COMP%]{position:relative}.sb-badge-content[_ngcontent-%COMP%]{--private__height:22px;--private__font-size:12px;--private__bg-color:var(--badge-bg,#3b9b4a);--private__text-color:var(--badge-text,#fff);--private__text-weight:var(--badge-weight,normal);height:var(--private-height);position:absolute;padding:.2em .4em;max-width:5ch;overflow:hidden;top:calc(var(--private__height) / 2 * -1);transform:translateX(calc(var(--private__height) / 5 * -1));font-size:var(--private__font-size);font-family:inherit;font-weight:var(--private__text-weight);line-height:var(--private__font-size);color:var(--private__text-color);white-space:nowrap;text-overflow:ellipsis;border-radius:calc(var(--private__height) / 2);background-color:var(--private__bg-color);pointer-events:none}"]}),t}()},bwdy:function(t,e,n){"use strict";n.d(e,"a",(function(){return u}));var i,r,o=n("FU6l"),a=n("X0qr"),s=n("IJgj"),c=function(){function t(t){return Error.call(this),this.message=t?"".concat(t.length," errors occurred during unsubscription:\n").concat(t.map((function(t,e){return"".concat(e+1,") ").concat(t.toString())})).join("\n ")):"",this.name="UnsubscriptionError",this.errors=t,this}return t.prototype=Object.create(Error.prototype),t}(),u=((r=function(){function t(e){C(this,t),this.closed=!1,this._parentOrParents=null,this._subscriptions=null,e&&(this._ctorUnsubscribe=!0,this._unsubscribe=e)}return w(t,[{key:"unsubscribe",value:function(){var e;if(!this.closed){var n=this._parentOrParents,i=this._ctorUnsubscribe,r=this._unsubscribe,u=this._subscriptions;if(this.closed=!0,this._parentOrParents=null,this._subscriptions=null,n instanceof t)n.remove(this);else if(null!==n)for(var d=0;d0)("ngIfElse",i)}}var E=function(t){return{pair:t}};function x(t,e){if(1&t&&(u.Ub(0,"p"),u.Qc(1),u.gc(2,"translate"),u.Tb()),2&t){var n=e.ngIf;u.Cb(1),u.Sc(" ",u.ic(2,1,"NO_CONTENT.PAIR_FILLS",u.rc(4,E,n))," ")}}function P(t,e){1&t&&(u.Ub(0,"p",12),u.Qc(1,"NO_CONTENT.FILLED_ORDERS"),u.Tb())}function A(t,e){if(1&t&&(u.Ub(0,"section",9),u.Pb(1,"fa-icon",10),u.Oc(2,x,3,6,"p",4),u.gc(3,"async"),u.Oc(4,P,2,0,"ng-template",null,11,u.Pc),u.Tb()),2&t){var n=u.Ac(5),i=u.fc(),r=null;u.Cb(2),u.mc("ngIf",null==(r=u.hc(3,2,i.filterPair$))?null:r.orUndefined())("ngIfElse",n)}}function I(t,e){1&t&&u.Pb(0,"kraken-loading")}var M=function(){var t=function(){function t(e){C(this,t),this.store=e,this.displayTooltips$=this.store.pipe(Object(i.m)(c.y)),this.fills$=this.store.pipe(Object(i.m)(o.d),Object(r.p)()),this.instruments$=this.store.pipe(Object(i.m)(s.f)),this.filterPair$=this.store.pipe(Object(i.m)(c.q))}return w(t,[{key:"viewDetailed",value:function(t){var e=this;this.instruments$.pipe(Object(r.h)()).subscribe((function(n){var i,r=null!==(i=n.get(t.instrument))&&void 0!==i?i:"expired";e.store.dispatch(Object(a.g)({name:"fill-details",inputs:{fill:t,market:r}}))}))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(u.Ob(i.b))},t.\u0275cmp=u.Ib({type:t,selectors:[["filled-orders"]],decls:6,vars:3,consts:[["class","table-wrapper","breakpoint","",3,"breakpoints",4,"ngLet"],["noEntries",""],["loader",""],["breakpoint","",1,"table-wrapper",3,"breakpoints"],[4,"ngIf","ngIfElse"],[3,"fills","displayTooltips","viewDetailed"],[3,"itemSize"],[3,"fill","viewDetailed",4,"cdkVirtualFor","cdkVirtualForOf"],[3,"fill","viewDetailed"],["body","","ghost","",1,"no-activity"],["icon","list","size","3x"],["unfiltered",""],["translate",""]],template:function(t,e){1&t&&(u.Oc(0,S,2,4,"div",0),u.gc(1,"async"),u.Oc(2,A,6,4,"ng-template",null,1,u.Pc),u.Oc(4,I,1,0,"ng-template",null,2,u.Pc)),2&t&&u.mc("ngLet",u.hc(1,1,e.fills$))},directives:[l.a,d.a,h.n,f.a,p.e,p.a,p.d,b.a,g.a,m.a,v.b,y.a,_.a],pipes:[h.b,y.d],styles:["market-icon[_ngcontent-%COMP%]{font-size:20px}[_nghost-%COMP%]{display:flex;flex-direction:column;padding:var(--spacing)}.table-wrapper[_ngcontent-%COMP%], [_nghost-%COMP%]{height:100%}.no-activity[_ngcontent-%COMP%]{text-align:center;padding:var(--spacing-l)}cdk-virtual-scroll-viewport[_ngcontent-%COMP%]{height:100%}@media (max-width:1024px){.table-wrapper[_ngcontent-%COMP%] filled-orders-desktop[_ngcontent-%COMP%]{display:none}.table-wrapper[_ngcontent-%COMP%] cdk-virtual-scroll-viewport[_ngcontent-%COMP%]{display:block!important}}.table-wrapper[breakpoint=large][_ngcontent-%COMP%] cdk-virtual-scroll-viewport[_ngcontent-%COMP%], .table-wrapper[breakpoint=medium][_ngcontent-%COMP%] cdk-virtual-scroll-viewport[_ngcontent-%COMP%], .table-wrapper[breakpoint=small][_ngcontent-%COMP%] filled-orders-desktop[_ngcontent-%COMP%]{display:none}"],changeDetection:0}),t}()},c6U1:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(){function t(t){for(var e=[],n=1;n2&&void 0!==arguments[2]?arguments[2]:Number.POSITIVE_INFINITY;return"function"==typeof e?function(o){return o.pipe(s((function(n,o){return Object(r.a)(t(n,o)).pipe(Object(i.a)((function(t,i){return e(n,t,o,i)})))}),n))}:("number"==typeof e&&(n=e),function(e){return e.lift(new u(t,n))})}var u=function(){function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Number.POSITIVE_INFINITY;C(this,t),this.project=e,this.concurrent=n}return w(t,[{key:"call",value:function(t,e){return e.subscribe(new l(t,this.project,this.concurrent))}}]),t}(),l=function(t){a(n,t);var e=c(n);function n(t,i){var r,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Number.POSITIVE_INFINITY;return C(this,n),(r=e.call(this,t)).project=i,r.concurrent=o,r.hasCompleted=!1,r.buffer=[],r.active=0,r.index=0,r}return w(n,[{key:"_next",value:function(t){this.active0?this._next(t.shift()):0===this.active&&this.hasCompleted&&this.destination.complete()}}]),n}(o.b)},cMxr:function(t,e,n){"use strict";n.d(e,"a",(function(){return h}));var i=n("D57K"),r=n("kZht"),o=n("gxtV"),a=n("uJYd"),s=n("zqNl"),c=n("An66"),u=n("4g2U");function l(t,e){if(1&t){var n=r.Vb();r.Ub(0,"ngx-slider",3),r.bc("valueChange",(function(t){return r.Ec(n),r.fc().currentValue=t}))("userChange",(function(t){return r.Ec(n),r.fc().change(t)}))("userChangeStart",(function(){return r.Ec(n),r.fc().startSliding()}))("userChangeEnd",(function(){return r.Ec(n),r.fc().stopSliding()})),r.Tb()}if(2&t){var i=r.fc();r.mc("value",i.currentValue)("options",i.options)}}function d(t,e){if(1&t){var n=r.Vb();r.Ub(0,"ngx-slider",4),r.bc("valueChange",(function(t){return r.Ec(n),r.fc().currentValue=t}))("userChangeStart",(function(){return r.Ec(n),r.fc().startSliding()}))("userChangeEnd",(function(t){r.Ec(n);var e=r.fc();return e.change(t),e.stopSliding()})),r.Tb()}if(2&t){var i=r.fc();r.mc("value",i.currentValue)("options",i.options)}}var h=function(){var t=function(){function t(e){var n=this;C(this,t),this.store=e,this.isOverMax=!1,this.fastUpdateMode=!1,this.logSteps=!1,this.min=0,this.stepBetween=1,this.suffix="",this.decimals=0,this.showLegend=!1,this.stepChange=new r.o,this.isSliding=new r.o,this.legend=function(t){return"".concat(t).concat(n.suffix)},this.translate=function(t){return"".concat(n.isOverMax?">":"").concat(t.toFixed(n.decimals)).concat(n.suffix)}}return w(t,[{key:"ngOnInit",value:function(){this.currentValue=this.step,this.setOptions()}},{key:"ngOnChanges",value:function(t){var e;"adjustedStep"in t&&(this.isOverMax=this.adjustedStep>this.max,this.currentValue=this.adjustedStep),(null===(e=t.min)||void 0===e?void 0:e.currentValue)&&this.setOptions()}},{key:"setOptions",value:function(){var t;this.options=this.max?Object.assign(Object.assign(Object.assign({step:this.stepBetween,floor:this.min,ceil:this.max,showTicks:!1,ticksArray:null!==(t=this.ticks)&&void 0!==t?t:[1,.25*this.max,.5*this.max,.75*this.max,this.max],hidePointerLabels:!1,hideLimitLabels:!0,showSelectionBar:!0,animate:!1,translate:this.translate.bind(this)},this.showLegend&&{getLegend:this.legend.bind(this)}),this.logSteps&&{customValueToPosition:function(t,e,n){return((t=Math.cbrt(t))-(e=Math.cbrt(e)))/((n=Math.cbrt(n))-e)}}),this.logSteps&&{customPositionToValue:function(t,e,n){return e=Math.cbrt(e),n=Math.cbrt(n),Math.pow(t*(n-e)+e,3)}}):{step:this.stepBetween,floor:this.min,ceil:this.steps.length-1,showTicks:!0,hidePointerLabels:!1,hideLimitLabels:!0,showSelectionBar:!0,animate:!1,showTicksValues:!0,translate:this.getStepLegend.bind(this)}}},{key:"change",value:function(t){var e=t.value;this.stepChange.emit(e)}},{key:"startSliding",value:function(){this.isSliding.emit(!0),this.store.dispatch(Object(a.t)({enable:!1}))}},{key:"stopSliding",value:function(){this.isSliding.emit(!1),this.store.dispatch(Object(a.t)({enable:!0}))}},{key:"getStepLegend",value:function(t){return""+this.steps[t].legend}}]),t}();return t.\u0275fac=function(e){return new(e||t)(r.Ob(s.b))},t.\u0275cmp=r.Ib({type:t,selectors:[["slider"]],inputs:{fastUpdateMode:"fastUpdateMode",adjustedStep:"adjustedStep",logSteps:"logSteps",step:"step",max:"max",min:"min",stepBetween:"stepBetween",steps:"steps",ticks:"ticks",suffix:"suffix",decimals:"decimals",showLegend:"showLegend"},outputs:{stepChange:"stepChange",isSliding:"isSliding"},features:[r.Ab],decls:4,vars:2,consts:[[1,"slider"],[3,"value","options","valueChange","userChange","userChangeStart","userChangeEnd",4,"ngIf"],[3,"value","options","valueChange","userChangeStart","userChangeEnd",4,"ngIf"],[3,"value","options","valueChange","userChange","userChangeStart","userChangeEnd"],[3,"value","options","valueChange","userChangeStart","userChangeEnd"]],template:function(t,e){1&t&&(r.Sb(0),r.Ub(1,"div",0),r.Oc(2,l,1,2,"ngx-slider",1),r.Oc(3,d,1,2,"ngx-slider",2),r.Tb(),r.Rb()),2&t&&(r.Cb(2),r.mc("ngIf",e.fastUpdateMode),r.Cb(1),r.mc("ngIf",!e.fastUpdateMode))},directives:[c.n,u.b],styles:[".slider{margin-bottom:var(--spacing)} .slider .ngx-slider .ngx-slider-selection-bar .ngx-slider-selection, .slider .ngx-slider .ngx-slider-selection-bar .ngx-slider-tick{background:var(--brand)} .slider .ngx-slider .ngx-slider-bubble{color:var(--input-colour)!important;font-size:12px!important} .slider .ngx-slider .ngx-slider-full-bar .ngx-slider-bar{background:var(--form-input-colour)} .slider .ngx-slider .ngx-slider-pointer{background:var(--brand);outline:none;height:18px;width:18px;top:-8px} .slider .ngx-slider .ngx-slider-pointer:after{display:none} .slider .ngx-slider .ngx-slider-tick{cursor:not-allowed;color:var(--ghost-colour);background:var(--form-input-colour);margin-right:2px;margin-left:4px} .slider .ngx-slider .ngx-slider-tick.ngx-slider-selected{background:var(--brand);color:var(--input-colour)!important} .slider .ngx-slider .ngx-slider-tick-legend{color:var(--ghost-colour);font-size:11px;position:inherit!important;margin-top:var(--spacing-s)!important} .slider .ngx-slider .ngx-slider-tick-legend p{color:var(--input-colour)!important;font-weight:700} .slider .ngx-slider .ngx-slider-bar, .slider .ngx-slider .ngx-slider-selection{background:var(--brand)} .slider .ngx-slider .ngx-slider-active:after{background-color:var(--brand)!important}"],changeDetection:0}),t=Object(i.d)([Object(o.a)()],t)}()},cedy:function(t,e,n){"use strict";n.r(e),n.d(e,"PrivateKeyComponent",(function(){return m}));var i=n("3kIJ"),r=n("mcff"),o=n("uJYd"),a=n("kZht"),s=n("zqNl"),c=n("rfPA"),u=n("bBQR"),l=n("EmXI"),d=n("Tcl6"),h=n("hCLc"),f=n("YC1o"),p=n("NxuZ"),b=n("B6Vo"),g=n("aDqW"),m=function(){var t=function(){function t(e,n,i,r){C(this,t),this.inputs=e,this.dialogRef=n,this.store=i,this.formBuilder=r}return w(t,[{key:"ngOnInit",value:function(){this.form=this.buildForm}},{key:"copyKey",value:function(){this.store.dispatch(Object(o.j)({message:"SNACKBAR.PRIVATE_KEY_COPIED"}))}},{key:"closeDialog",value:function(){this.dialogRef.close()}},{key:"buildForm",get:function(){return this.formBuilder.group({publicKey:[this.inputs.publicKey,[i.x.required]],privateKey:[this.inputs.privateKey,[i.x.required]]})}}]),t}();return t.\u0275fac=function(e){return new(e||t)(a.Ob(r.a),a.Ob(r.d),a.Ob(s.b),a.Ob(i.d))},t.\u0275cmp=a.Ib({type:t,selectors:[["private-key"]],decls:22,vars:18,consts:[["heading","DIALOG.PRIVATE_API_KEY.TITLE"],[1,"private-key__form","global__text","global__text-body",3,"formGroup"],[1,"global__text","global__text-subheading"],["color","accent","appearance","fill"],["formControlName","publicKey","matInput","","readonly","",3,"value"],["mat-button","","matSuffix","","mat-icon-button","",1,"private-key__key",3,"clipboard"],["icon","copy","size","2x","sbTooltip","TOOLTIP.COPY_TO_CLIPBOARD"],["formControlName","privateKey","matInput","","readonly","",3,"value"],["mat-button","","matSuffix","","mat-icon-button","",1,"private-key__key",3,"clipboard","clipboardSuccessMsg"],["mat-raised-button","",1,"global__text","global__text-body",3,"click"]],template:function(t,e){1&t&&(a.Ub(0,"pro-dialog",0),a.Ub(1,"form",1),a.Ub(2,"p",2),a.Qc(3),a.gc(4,"translate"),a.Tb(),a.Ub(5,"mat-form-field",3),a.Ub(6,"mat-label"),a.Qc(7),a.gc(8,"translate"),a.Tb(),a.Pb(9,"input",4),a.Ub(10,"button",5),a.Pb(11,"fa-icon",6),a.Tb(),a.Tb(),a.Ub(12,"mat-form-field",3),a.Ub(13,"mat-label"),a.Qc(14),a.gc(15,"translate"),a.Tb(),a.Pb(16,"input",7),a.Ub(17,"button",8),a.Pb(18,"fa-icon",6),a.Tb(),a.Tb(),a.Tb(),a.Ub(19,"button",9),a.bc("click",(function(){return e.closeDialog()})),a.Qc(20),a.gc(21,"translate"),a.Tb(),a.Tb()),2&t&&(a.Cb(1),a.mc("formGroup",e.form),a.Cb(2),a.Sc(" ",a.hc(4,10,"DIALOG.PRIVATE_API_KEY.CONTENT")," "),a.Cb(4),a.Rc(a.hc(8,12,"DIALOG.PRIVATE_API_KEY.KEYS.PUBLIC")),a.Cb(2),a.mc("value",e.inputs.publicKey),a.Cb(1),a.mc("clipboard",e.inputs.publicKey),a.Cb(4),a.Rc(a.hc(15,14,"DIALOG.PRIVATE_API_KEY.KEYS.PRIVATE")),a.Cb(2),a.mc("value",e.inputs.privateKey),a.Cb(1),a.mc("clipboard",e.inputs.privateKey)("clipboardSuccessMsg","SNACKBAR.PRIVATE_KEY_COPIED"),a.Cb(3),a.Sc(" ",a.hc(21,16,"BUTTON.CLOSE")," "))},directives:[c.a,u.a,i.z,i.p,i.h,l.c,l.f,i.c,d.b,i.o,i.g,h.b,l.h,f.a,p.b,b.a],pipes:[g.d],styles:[".mat-form-field[_ngcontent-%COMP%]{width:100%}.mat-form-field[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{color:var(--text-colour)!important}.private-key__form[_ngcontent-%COMP%]{margin-top:var(--spacing)!important}.private-key__form[_ngcontent-%COMP%] .mat-form-field[_ngcontent-%COMP%]{width:100%}.private-key__form[_ngcontent-%COMP%] > p[_ngcontent-%COMP%]:first-of-type{margin-bottom:var(--spacing)}.private-key__form[_ngcontent-%COMP%] > button[_ngcontent-%COMP%]{margin-top:var(--spacing);width:100%}"],changeDetection:0}),t}()},chaP:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("kZht"),r=function(){var t=function(){function t(e,n){C(this,t),this.renderer=e,this.element=n}return w(t,[{key:"ngOnInit",value:function(){this.renderer.addClass(this.element.nativeElement,"global__text--mono")}}]),t}();return t.\u0275fac=function(e){return new(e||t)(i.Ob(i.G),i.Ob(i.l))},t.\u0275dir=i.Jb({type:t,selectors:[["","mono",""]]}),t}()},cjU9:function(t,e,n){var i=n("JgBV"),r=n("yBEi");function o(t){this.mode=i.KANJI,this.data=t}o.getBitsLength=function(t){return 13*t},o.prototype.getLength=function(){return this.data.length},o.prototype.getBitsLength=function(){return o.getBitsLength(this.data.length)},o.prototype.write=function(t){var e;for(e=0;e=33088&&n<=40956)n-=33088;else{if(!(n>=57408&&n<=60351))throw new Error("Invalid SJIS character: "+this.data[e]+"\nMake sure your charset is UTF-8");n-=49472}t.put(n=192*(n>>>8&255)+(255&n),13)}},t.exports=o},ckkg:function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var i=n("IdLP"),r=n("dUuy"),o=n("czMQ");function a(t,e){return e?Object(o.a)(t,e):new i.a(Object(r.a)(t))}},cqWG:function(t,e,n){"use strict";n.d(e,"a",(function(){return Z}));var i=n("D57K"),r=n("3kIJ"),o=n("gxtV"),a=n("zqNl"),s=n("C05f"),c=n("47ST"),u=n("ROBh"),l=n("GoAz"),d=n("xVbo"),h=n("BwBJ"),f=n("4e/d"),p=n("TLy2"),b=n("NloN"),g=n("uJYd"),m=n("94ty"),v=n("sXtk"),y=n("bjK4"),_=n("r1OQ"),O=n("MUfl"),k=n("T5QL"),T=n("kZht"),S=n("aDqW"),E=n("Asjx"),x=n("anSm"),P=n("An66"),A=n("hCLc"),I=n("3W1Y"),M=n("EmXI"),D=n("Tcl6"),R=n("7J2L"),j=n("NxuZ"),L=n("TzY9");function N(t,e){1&t&&(T.Sb(0),T.Ub(1,"ul",9),T.Ub(2,"li"),T.Ub(3,"p",10),T.Qc(4,"Bitcoin futures trading with leverage"),T.Tb(),T.Tb(),T.Ub(5,"li"),T.Ub(6,"p",10),T.Qc(7,"Choose your own collateral"),T.Tb(),T.Tb(),T.Ub(8,"li"),T.Ub(9,"p",10),T.Qc(10,"Go long or short to suit your trading strategy"),T.Tb(),T.Tb(),T.Ub(11,"li"),T.Ub(12,"p",10),T.Qc(13,"Lowest fees in the market"),T.Tb(),T.Tb(),T.Tb(),T.Rb())}function U(t,e){1&t&&(T.Ub(0,"small",13),T.Qc(1),T.gc(2,"translate"),T.Tb()),2&t&&(T.Cb(1),T.Rc(T.hc(2,1,"FRAGMENT.OR")))}function F(t,e){if(1&t){var n=T.Vb();T.Sb(0),T.Ub(1,"button",11),T.bc("click",(function(){return T.Ec(n),T.fc(2).openKrakenLogin()})),T.Qc(2),T.gc(3,"translate"),T.Tb(),T.Oc(4,U,3,3,"small",12),T.Rb()}if(2&t){var i=T.fc(2);T.Cb(2),T.Sc(" ",T.hc(3,2,i.includeDirect?"DIALOG.SIGNIN.BUTTONS.SSO":"NAV.SIGN_IN")," "),T.Cb(2),T.mc("ngIf",i.includeDirect)}}function B(t,e){1&t&&(T.Ub(0,"mat-error"),T.Qc(1),T.gc(2,"translate"),T.Tb()),2&t&&(T.Cb(1),T.Sc(" ",T.hc(2,1,"FORM.EMAIL_ERROR")," "))}function z(t,e){if(1&t&&(T.Sb(0),T.Ub(1,"mat-form-field",14),T.Ub(2,"mat-label"),T.Qc(3),T.gc(4,"translate"),T.Tb(),T.Pb(5,"input",15),T.Oc(6,B,3,3,"mat-error",7),T.Tb(),T.Ub(7,"mat-form-field",14),T.Ub(8,"mat-label"),T.Qc(9),T.gc(10,"translate"),T.Tb(),T.Pb(11,"input",16),T.Tb(),T.Ub(12,"button",17),T.gc(13,"async"),T.Qc(14),T.gc(15,"translate"),T.Tb(),T.Rb()),2&t){var n=T.fc(2);T.Cb(3),T.Rc(T.hc(4,5,"FORM.EMAIL")),T.Cb(3),T.mc("ngIf",n.form.get("email").invalid),T.Cb(3),T.Rc(T.hc(10,7,"FORM.PASSWORD")),T.Cb(3),T.mc("disabled",n.form.invalid||T.hc(13,9,n.loading$)),T.Cb(2),T.Sc(" ",T.hc(15,11,"DIALOG.SIGNIN.BUTTONS.EMAIL")," ")}}function V(t,e){if(1&t&&(T.Sb(0),T.Oc(1,N,14,0,"ng-container",7),T.Oc(2,F,5,4,"ng-container",8),T.Oc(3,z,16,13,"ng-container",7),T.Rb()),2&t){var n=T.fc(),i=T.Ac(10);T.Cb(1),T.mc("ngIf",!n.includeDirect),T.Cb(1),T.mc("ngIf",!n.env.demo)("ngIfElse",i),T.Cb(1),T.mc("ngIf",n.includeDirect)}}function H(t,e){1&t&&(T.Ub(0,"div",20),T.Ub(1,"p",21),T.Qc(2,"DIALOG.SIGNIN.HWAUTH_VERIFY"),T.Tb(),T.Pb(3,"kraken-loading",22),T.Tb())}function q(t,e){if(1&t&&(T.Sb(0),T.Oc(1,H,4,0,"div",19),T.Rb()),2&t){var n=T.fc(2);T.Cb(1),T.mc("ngIf",n.mfaPriority.includes("fido2"))}}function $(t,e){if(1&t){var n=T.Vb();T.Sb(0),T.Ub(1,"div",23),T.Pb(2,"fa-icon",24),T.Ub(3,"div"),T.Ub(4,"p",21),T.Qc(5,"DIALOG.SIGNIN.HWAUTH_ERROR"),T.Tb(),T.Ub(6,"button",25),T.bc("click",(function(){return T.Ec(n),T.fc(2).resetFido()})),T.Qc(7),T.gc(8,"translate"),T.Tb(),T.Tb(),T.Tb(),T.Rb()}2&t&&(T.Cb(7),T.Sc(" ",T.hc(8,1,"BUTTON.TRY_AGAIN")," "))}function Q(t,e){1&t&&(T.Ub(0,"small",13),T.Qc(1),T.gc(2,"translate"),T.Tb()),2&t&&(T.Cb(1),T.Sc(" ",T.hc(2,1,"FRAGMENT.OR")," "))}function W(t,e){if(1&t&&(T.Ub(0,"div",26),T.Ub(1,"p",21),T.Qc(2,"DIALOG.SIGNIN.TOTP_VERIFY"),T.Tb(),T.Pb(3,"input-otp-entry",27),T.Tb()),2&t){var n=T.fc(2);T.Cb(3),T.mc("form",n.form)}}function G(t,e){if(1&t&&(T.Sb(0),T.Sb(1,3),T.gc(2,"async"),T.Oc(3,q,2,1,"ng-container",4),T.Oc(4,$,9,3,"ng-container",4),T.Rb(),T.Oc(5,Q,3,3,"small",12),T.Oc(6,W,4,1,"div",18),T.Rb()),2&t){var n=T.fc();T.Cb(1),T.mc("ngSwitch",T.hc(2,5,n.fidoState$)),T.Cb(2),T.mc("ngSwitchCase","waiting"),T.Cb(1),T.mc("ngSwitchCase","error"),T.Cb(1),T.mc("ngIf",n.mfaPriority.includes("fido2")&&n.mfaPriority.includes("totp")),T.Cb(1),T.mc("ngIf",n.mfaPriority.includes("totp"))}}function Y(t,e){if(1&t){var n=T.Vb();T.Ub(0,"div",28),T.Ub(1,"a",29),T.bc("click",(function(){return T.Ec(n),T.fc().closeDialog({name:"password-reset-request"})})),T.Qc(2),T.gc(3,"translate"),T.Tb(),T.Ub(4,"a",29),T.bc("click",(function(){return T.Ec(n),T.fc().signUp()})),T.Qc(5),T.gc(6,"translate"),T.Tb(),T.Tb()}2&t&&(T.Cb(2),T.Sc(" ",T.hc(3,2,"DIALOG.SIGNIN.PASSWORD_RESET_LINK")," "),T.Cb(3),T.Sc(" ",T.hc(6,4,"DIALOG.SIGNIN.SIGNUP_LINK")," "))}function K(t,e){1&t&&(T.Ub(0,"p",30),T.Qc(1),T.gc(2,"translate"),T.Tb()),2&t&&(T.Cb(1),T.Sc(" ",T.hc(2,1,"LABEL.PROD_INVALID_ON_DEMO")," "))}var Z=function(){var t=function(){function t(e,n,i,r,o,c,u,l){C(this,t),this.env=e,this.feature=n,this.store=i,this.fb=r,this.auth=o,this.fido2=c,this.translate=u,this.breakpointObserver=l,this.form=this.buildForm(),this.loading$=this.store.pipe(Object(a.m)(y.m,{filter:m.a})),this.mfaPriority=[],this.fidoState$=new s.a("waiting"),this.step$=new s.a("password"),this.logo$=this.store.pipe(Object(a.m)(y.f,{demo:this.env.demo})),this.includeDirect=!0}return w(t,[{key:"ngOnInit",value:function(){this.watchTotpInput()}},{key:"ngOnDestroy",value:function(){Object(b.e)("dialog")}},{key:"openKrakenLogin",value:function(){window.open(this.env.urls.externalSignIn,"_blank","noopener")}},{key:"watchTotpInput",value:function(){var t=this;this.form.get("otp").valueChanges.pipe(Object(d.a)((function(t){return 6===t.length})),Object(h.a)(100),Object(o.b)(this)).subscribe((function(){return t.submitForm()}))}},{key:"buildForm",value:function(){return this.fb.group({email:["",[r.x.required,r.x.email]],password:["",[r.x.required]],otp:[""],cred:[void 0]})}},{key:"submitForm",value:function(){this.signin(this.form.value)}},{key:"signin",value:function(t){var e=this;this.store.dispatch(Object(g.a)(m.a)),this.auth.signIn(Object.assign(Object.assign({},t),{otp:t.otp||void 0})).pipe(Object(f.a)((function(t){return Object(c.a)(t.error.error)})),Object(p.a)((function(n){return"token"in n?Object(u.a)(n):"mfaRequired"in n?(e.mfaPriority=n.mfaRequired,e.step$.next("mfa"),e.fidoState$.next("waiting"),"challenge"in n&&n.challenge?Object(l.a)(e.fido2.getAssertion(n.challenge)).pipe(Object(f.a)((function(t){return console.error("error in authenticator verify",t),e.fidoState$.next("error"),Object(c.a)("HWAUTH_VERIFY_FAIL")})),Object(p.a)((function(n){return e.auth.signIn(Object.assign(Object.assign({},t),{cred:n})).pipe(Object(f.a)((function(t){return Object(c.a)(t.error.error)})))}))):Object(u.a)(null)):Object(c.a)(0)})),Object(d.a)((function(t){return null!==t||(e.store.dispatch(Object(g.n)(m.a)),!1)}))).subscribe((function(t){e.store.dispatch(Object(g.n)(m.a)),e.store.dispatch(Object(m.D)()),e.store.dispatch(Object(g.c)()),e.store.dispatch(Object(g.j)({message:"SNACKBAR.SIGNIN_SUCCESS"}))}),(function(t){console.warn({errCode:t}),e.store.dispatch(Object(g.n)(m.a)),"invalid_mfa"===t&&(e.form.get("otp").setValue(""),e.form.get("cred").setValue(void 0));var n=e.translate.instant("ERROR.SIGNIN_ERR"),i=e.translate.instant("ERROR_CODE."+t.toUpperCase());e.store.dispatch(Object(g.j)({message:"".concat(n," - ").concat(i),class:"warn"}))}))}},{key:"resetFido",value:function(){this.form.get("otp").setValue(""),this.form.get("cred").setValue(void 0),this.submitForm(),this.fidoState$.next("waiting")}},{key:"signUp",value:function(){this.env.demo?this.store.dispatch(Object(g.g)({name:"sign-up-demo"})):window.open("https://www.kraken.com/sign-up","_blank","noopener")}},{key:"closeDialog",value:function(t){this.store.dispatch(Object(g.n)(m.a)),t&&this.store.dispatch(Object(g.g)(t))}},{key:"isMobile",get:function(){return this.breakpointObserver.isMatched("(max-width: 599px)")}}]),t}();return t.\u0275fac=function(e){return new(e||t)(T.Ob(v.a),T.Ob(O.a),T.Ob(a.b),T.Ob(r.d),T.Ob(_.a),T.Ob(k.a),T.Ob(S.e),T.Ob(E.a))},t.\u0275cmp=T.Ib({type:t,selectors:[["sign-in-form"]],inputs:{includeDirect:"includeDirect"},decls:11,vars:10,consts:[["body","",3,"formGroup","ngSubmit"],[1,"unauth__logo"],["alt","Logo",3,"src"],[3,"ngSwitch"],[4,"ngSwitchCase"],["body","","class","reset vstack gap-s",4,"ngIf"],["demoWarning",""],[4,"ngIf"],[4,"ngIf","ngIfElse"],[1,"marketing-list"],["body",""],["mat-raised-button","","type","button",3,"click"],["caption","",4,"ngIf"],["caption",""],["color","accent","appearance","fill"],["formControlName","email","required","","matInput","","type","email"],["formControlName","password","required","","matInput","","type","password"],["body","","mat-raised-button","",3,"disabled"],["class","totp-verify",4,"ngIf"],["class","hwauth-verify",4,"ngIf"],[1,"hwauth-verify"],["body","","translate",""],["color","accent"],[1,"hwauth-error"],["icon","circle-exclamationmark","size","lg"],["mat-raised-button","",1,"mat-small-button",3,"click"],[1,"totp-verify"],[3,"form"],["body","",1,"reset","vstack","gap-s"],[1,"global__text--link",3,"click"],["body","",1,"global__text--warn","demo-warning"]],template:function(t,e){1&t&&(T.Ub(0,"form",0),T.bc("ngSubmit",(function(){return e.submitForm()})),T.Ub(1,"div",1),T.Pb(2,"img",2),T.gc(3,"async"),T.Tb(),T.Sb(4,3),T.gc(5,"async"),T.Oc(6,V,4,4,"ng-container",4),T.Oc(7,G,7,7,"ng-container",4),T.Rb(),T.Oc(8,Y,7,6,"div",5),T.Tb(),T.Oc(9,K,3,3,"ng-template",null,6,T.Pc)),2&t&&(T.mc("formGroup",e.form),T.Cb(2),T.mc("src",T.hc(3,6,e.logo$),T.Gc),T.Cb(2),T.mc("ngSwitch",T.hc(5,8,e.step$)),T.Cb(2),T.mc("ngSwitchCase","password"),T.Cb(1),T.mc("ngSwitchCase","mfa"),T.Cb(1),T.mc("ngIf",e.includeDirect))},directives:[r.z,r.p,x.a,r.h,P.p,P.q,P.n,A.b,I.a,M.c,M.f,r.c,D.b,r.o,r.g,r.v,M.b,S.a,R.a,j.b,L.a],pipes:[P.b,S.d],styles:["[_nghost-%COMP%], form[_ngcontent-%COMP%]{width:100%}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;text-align:center}form[_ngcontent-%COMP%] > small[_ngcontent-%COMP%]{margin:var(--spacing) 0}.hwauth-error[_ngcontent-%COMP%], .hwauth-verify[_ngcontent-%COMP%], .hwauth-verify[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin-bottom:var(--spacing)}.hwauth-error[_ngcontent-%COMP%]{display:grid;justify-content:center;align-items:center;gap:var(--spacing);grid-auto-flow:column}.hwauth-error[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{color:var(--warn-colour);transform:scale(1.5)}.hwauth-error[_ngcontent-%COMP%] p[_ngcontent-%COMP%], .totp-verify[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin-bottom:var(--spacing)}.demo-warning[_ngcontent-%COMP%]{max-width:45ch;margin:var(--spacing);line-height:1.3}.unauth[_ngcontent-%COMP%]{text-align:center;padding:var(--spacing)}.unauth__logo[_ngcontent-%COMP%]{border-bottom:2px solid var(--border-colour-dark);padding:var(--spacing-xl) 0}.unauth__logo[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{width:90%;max-width:250px}.marketing-list[_ngcontent-%COMP%], .reset[_ngcontent-%COMP%]{margin:var(--spacing-l) 0}"],changeDetection:0}),t=Object(i.d)([Object(o.a)()],t)}()},czMQ:function(t,e,n){"use strict";n.d(e,"a",(function(){return o}));var i=n("IdLP"),r=n("bwdy");function o(t,e){return new i.a((function(n){var i=new r.a,o=0;return i.add(e.schedule((function(){o!==t.length?(n.next(t[o++]),n.closed||i.add(this.schedule())):n.complete()}))),i}))}},dUuy:function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var i=function(t){return function(e){for(var n=0,i=t.length;n=Number.MAX_SAFE_INTEGER?Number.MAX_SAFE_INTEGER:t+(t<0?-.5:.5)|0},t.distance=function(t,e,n,i){var r=t-n,o=e-i;return Math.sqrt(r*r+o*o)},t.sum=function(t){for(var e=0,n=0,i=t.length;n!==i;n++)e+=t[n];return e},t}()},e7kw:function(t,e,n){"use strict";n.d(e,"a",(function(){return o})),n.d(e,"b",(function(){return a}));var i=n("sXtk"),r=n("kZht"),o=function(){var t=function(){function t(e){C(this,t),this.env=e}return w(t,[{key:"transform",value:function(t){var e=escape(t.toString());return"".concat(this.env.urls.support,"/hc/en-us/articles/").concat(e)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(r.Ob(i.a))},t.\u0275pipe=r.Nb({name:"supportArticle",type:t,pure:!0}),t}(),a=function(){var t=function(){function t(e){C(this,t),this.env=e}return w(t,[{key:"transform",value:function(t){var e=escape(t.toString());return"".concat(this.env.urls.support,"/hc/en-us/categories/").concat(e)}}]),t}();return t.\u0275fac=function(e){return new(e||t)(r.Ob(i.a))},t.\u0275pipe=r.Nb({name:"supportCategory",type:t,pure:!0}),t}()},e9V9:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n("2rk/");e.default=function(){function t(){}return t.setGridSampler=function(e){t.gridSampler=e},t.getInstance=function(){return t.gridSampler},t.gridSampler=new i.default,t}()},eGwX:function(t,e,n){"use strict";n.d(e,"a",(function(){return O}));var i=n("D57K"),r=n("kZht"),o=n("3kIJ"),a=n("ZTXN"),s=n("C05f"),c=n("mWib"),u=n("kuMc"),l=n("wny4"),d=n.n(l),h=n("EmXI"),f=n("Tcl6"),p=n("hCLc"),b=n("NxuZ"),g=n("+Tmv"),m=n("An66"),v=n("aDqW");function y(t,e){1&t&&(r.Ub(0,"mat-error"),r.Qc(1),r.gc(2,"translate"),r.Tb()),2&t&&(r.Cb(1),r.Rc(r.hc(2,1,"FORM.NO_MATCH_ERROR")))}var _=function(t){var e=t.get("password"),n=t.get("confirmPassword");return e&&n?e.value===n.value?null:(n.setErrors({noMatch:!0}),{noMatch:!0}):null},O=function(){var t=function(){function t(e){C(this,t),this.formBuilder=e,this.destroy$=new a.b,this.inputVisibility={password:!1,confirmPassword:!1},this.passwordStrength$=new s.a(0),this.passwordUpdate$=new r.o}return w(t,[{key:"ngOnInit",value:function(){this.form=this.buildForm(),this.watchPasswordStrength()}},{key:"ngOnChanges",value:function(t){var e=this;t.resetToggle&&this.form&&(this.form.reset(),Object.keys(this.form.controls).forEach((function(t){return e.form.get(t).setErrors(null)})))}},{key:"watchPasswordStrength",value:function(){return Object(i.a)(this,void 0,void 0,regeneratorRuntime.mark((function t(){var e,n=this;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,d.a.load({});case 2:e=t.sent,this.form.get("password").valueChanges.pipe(Object(c.a)(100),Object(u.a)(this.destroy$)).subscribe((function(t){n.passwordStrength$.next(t?e(t).score:0)}));case 4:case"end":return t.stop()}}),t,this)})))}},{key:"updatePassword",value:function(){this.passwordUpdate$.emit(this.form.valid?this.form.get("password").value:"")}},{key:"buildForm",value:function(){return this.formBuilder.group({password:["",[o.x.required]],confirmPassword:["",[o.x.required]]},{validator:_})}}]),t}();return t.\u0275fac=function(e){return new(e||t)(r.Ob(o.d))},t.\u0275cmp=r.Ib({type:t,selectors:[["input-password-confirm"]],inputs:{resetToggle:"resetToggle"},outputs:{passwordUpdate$:"passwordUpdate"},features:[r.Ab],decls:18,vars:15,consts:[[1,"input-password-confirm__form","global__text","global__text-body",3,"formGroup"],["color","accent","appearance","fill"],["formControlName","password","required","","matInput","","autocomplete","new-password",3,"type","change","input"],["mat-button","","mat-icon-button","","matSuffix","","tabindex","-1","type","button",3,"click"],["size","2x",3,"icon"],[3,"strength"],["formControlName","confirmPassword","required","","matInput","","autocomplete","new-password",3,"type","change","input"],[4,"ngIf"]],template:function(t,e){1&t&&(r.Ub(0,"form",0),r.Ub(1,"mat-form-field",1),r.Ub(2,"mat-label"),r.Qc(3),r.gc(4,"translate"),r.Tb(),r.Ub(5,"input",2),r.bc("change",(function(){return e.updatePassword()}))("input",(function(){return e.updatePassword()})),r.Tb(),r.Ub(6,"button",3),r.bc("click",(function(){return e.inputVisibility.password=!e.inputVisibility.password})),r.Pb(7,"fa-icon",4),r.Tb(),r.Tb(),r.Pb(8,"strength-meter",5),r.gc(9,"async"),r.Ub(10,"mat-form-field",1),r.Ub(11,"mat-label"),r.Qc(12),r.gc(13,"translate"),r.Tb(),r.Ub(14,"input",6),r.bc("change",(function(){return e.updatePassword()}))("input",(function(){return e.updatePassword()})),r.Tb(),r.Ub(15,"button",3),r.bc("click",(function(){return e.inputVisibility.confirmPassword=!e.inputVisibility.confirmPassword})),r.Pb(16,"fa-icon",4),r.Tb(),r.Oc(17,y,3,3,"mat-error",7),r.Tb(),r.Tb()),2&t&&(r.mc("formGroup",e.form),r.Cb(3),r.Rc(r.hc(4,9,"FORM.PASSWORD")),r.Cb(2),r.mc("type",e.inputVisibility.password?"text":"password"),r.Cb(2),r.mc("icon",e.inputVisibility.password?"privacy-on":"privacy-off"),r.Cb(1),r.mc("strength",r.hc(9,11,e.passwordStrength$)),r.Cb(4),r.Rc(r.hc(13,13,"FORM.CONFIRM_PASSWORD")),r.Cb(2),r.mc("type",e.inputVisibility.confirmPassword?"text":"password"),r.Cb(2),r.mc("icon",e.inputVisibility.confirmPassword?"privacy-on":"privacy-off"),r.Cb(1),r.mc("ngIf",e.form.hasError("noMatch")))},directives:[o.z,o.p,o.h,h.c,h.f,o.c,f.b,o.o,o.g,o.v,p.b,h.h,b.b,g.a,m.n,h.b],pipes:[v.d,m.b],styles:[".input-password-confirm__form[_ngcontent-%COMP%] .mat-form-field[_ngcontent-%COMP%]{width:100%}.input-password-confirm__form[_ngcontent-%COMP%] > button[_ngcontent-%COMP%]{margin-top:var(--spacing);width:100%}"],changeDetection:0}),t}()},eI8f:function(t,e,n){"use strict";n.r(e),n.d(e,"DemoCredentialsComponent",(function(){return T}));var i=n("3kIJ"),r=n("zqNl"),o=n("u7r1"),a=n("94ty"),s=n("bjK4"),c=n("kZht"),u=n("rfPA"),l=n("bBQR"),d=n("afE0"),h=n("anSm"),f=n("EmXI"),p=n("Tcl6"),b=n("hCLc"),g=n("YC1o"),m=n("NxuZ"),v=n("B6Vo"),y=n("UDV5"),_=n("i9Na"),O=n("An66"),k=n("aDqW"),T=function(){var t=function(){function t(e,n){C(this,t),this.store=e,this.fb=n,this.email=Object(o.a)(8)+"@futures-demo.com",this.password=Object(o.a)(20),this.form=this.buildForm(),this.loading$=this.store.pipe(Object(r.m)(s.m,{filter:a.C.type}))}return w(t,[{key:"buildForm",value:function(){return this.fb.group({email:[this.email,[i.x.required,i.x.email]],password:[this.password,[i.x.required]],termsConditions:[!1,[i.x.requiredTrue]],privacyPolicy:[!1,[i.x.requiredTrue]]})}},{key:"submitForm",value:function(){this.store.dispatch(Object(a.C)({email:this.form.get("email").value,password:this.form.get("password").value,accountType:"individual",marketing:!1,acknowledgement:!0}))}}]),t}();return t.\u0275fac=function(e){return new(e||t)(c.Ob(r.b),c.Ob(i.d))},t.\u0275cmp=c.Ib({type:t,selectors:[["demo-credentials"]],decls:31,vars:25,consts:[["heading","DIALOG.DEMO_CREDENTIALS.TITLE",3,"loading"],[1,"dialog-content","vstack","hcenter","gap-l"],["icon","user-full"],["body",""],["body","",1,"vstack","hcenter",3,"formGroup","ngSubmit"],["color","accent","appearance","fill"],["matInput","","readonly","","formControlName","email"],["type","button","mat-button","","matSuffix","","mat-icon-button","",3,"clipboard"],["icon","copy","size","2x","sbTooltip","TOOLTIP.COPY_EMAIL"],["matInput","","readonly","","formControlName","password"],["icon","copy","size","2x","sbTooltip","TOOLTIP.COPY_PASSWORD"],["formControlName","termsConditions",1,"no-border"],[3,"data"],["formControlName","privacyPolicy",1,"no-border"],["body","","mat-raised-button","",1,"signup",3,"disabled"]],template:function(t,e){1&t&&(c.Ub(0,"pro-dialog",0),c.gc(1,"async"),c.Ub(2,"div",1),c.Pb(3,"dialog-badge",2),c.Ub(4,"p",3),c.Qc(5),c.gc(6,"translate"),c.Tb(),c.Ub(7,"form",4),c.bc("ngSubmit",(function(){return e.submitForm()})),c.Ub(8,"mat-form-field",5),c.Ub(9,"mat-label"),c.Qc(10),c.gc(11,"translate"),c.Tb(),c.Pb(12,"input",6),c.Ub(13,"button",7),c.Pb(14,"fa-icon",8),c.Tb(),c.Tb(),c.Ub(15,"mat-form-field",5),c.Ub(16,"mat-label"),c.Qc(17),c.gc(18,"translate"),c.Tb(),c.Pb(19,"input",9),c.Ub(20,"button",7),c.Pb(21,"fa-icon",10),c.Tb(),c.Tb(),c.Ub(22,"mat-checkbox",11),c.Pb(23,"markdown",12),c.gc(24,"translate"),c.Tb(),c.Ub(25,"mat-checkbox",13),c.Pb(26,"markdown",12),c.gc(27,"translate"),c.Tb(),c.Ub(28,"button",14),c.Qc(29),c.gc(30,"translate"),c.Tb(),c.Tb(),c.Tb(),c.Tb()),2&t&&(c.mc("loading",c.hc(1,11,e.loading$)),c.Cb(5),c.Rc(c.hc(6,13,"DIALOG.DEMO_CREDENTIALS.BODY")),c.Cb(2),c.mc("formGroup",e.form),c.Cb(3),c.Rc(c.hc(11,15,"DIALOG.DEMO_CREDENTIALS.EMAIL")),c.Cb(3),c.mc("clipboard",e.email),c.Cb(4),c.Rc(c.hc(18,17,"DIALOG.DEMO_CREDENTIALS.PASSWORD")),c.Cb(3),c.mc("clipboard",e.password),c.Cb(3),c.mc("data",c.hc(24,19,"DIALOG.DEMO_CREDENTIALS.TCS")),c.Cb(3),c.mc("data",c.hc(27,21,"DIALOG.DEMO_CREDENTIALS.PRIVACY")),c.Cb(2),c.mc("disabled",e.form.invalid),c.Cb(1),c.Sc(" ",c.hc(30,23,"BUTTON.COMPLETE_SIGNUP")," "))},directives:[u.a,l.a,d.a,h.a,i.z,i.p,i.h,f.c,f.f,p.b,i.c,i.o,i.g,b.b,f.h,g.a,m.b,v.a,y.a,_.a],pipes:[O.b,k.d],styles:[".dialog-content[_ngcontent-%COMP%]{text-align:center}markdown[_ngcontent-%COMP%] a{color:var(--link-colour)}.signup[_ngcontent-%COMP%]{margin-top:var(--spacing)}"],changeDetection:0}),t}()},eL2r:function(t,e,n){"use strict";n.r(e),n.d(e,"PositionAssignmentComponent",(function(){return P}));var i=n("3kIJ"),r=n("mcff"),o=n("1ONQ"),a=n("kZht"),s=n("zqNl"),c=n("rfPA"),u=n("bBQR"),l=n("An66"),d=n("UDV5"),h=n("EmXI"),f=n("Tcl6"),p=n("IOEv"),b=n("hCLc"),g=n("pTnX"),m=n("1etq"),v=n("scAs"),y=n("1o0v"),_=n("anSm"),O=n("aDqW"),k=n("fvDn");function T(t,e){if(1&t&&(a.Ub(0,"mat-option",14),a.Qc(1),a.gc(2,"cryptoAbbreviation"),a.Tb()),2&t){var n=e.$implicit;a.mc("value",n),a.Cb(1),a.Sc(" ",a.hc(2,2,n)," ")}}function S(t,e){if(1&t&&(a.Ub(0,"mat-form-field",7),a.Ub(1,"mat-label"),a.Qc(2),a.gc(3,"translate"),a.Tb(),a.Ub(4,"mat-select",13),a.Oc(5,T,3,4,"mat-option",11),a.Tb(),a.Tb()),2&t){var n=a.fc();a.Cb(2),a.Rc(a.hc(3,2,"FORM.CONTRACT_TYPE")),a.Cb(3),a.mc("ngForOf",n.inputs.contractTypes)}}function E(t,e){if(1&t&&(a.Ub(0,"section"),a.Ub(1,"p",15),a.Qc(2,"Contracts:"),a.Tb(),a.Ub(3,"p",16),a.Qc(4),a.Tb(),a.Tb()),2&t){var n=a.fc();a.Lc("margin-bottom","var(--spacing)"),a.Cb(4),a.Rc(n.prefLables)}}function x(t,e){if(1&t&&(a.Ub(0,"mat-option",14),a.Qc(1),a.Tb()),2&t){var n=e.$implicit;a.mc("value",n),a.Cb(1),a.Sc(" ",n," ")}}var P=function(){var t=function(){function t(e,n,i){C(this,t),this.inputs=e,this.store=n,this.formBuilder=i,this.timeframes=["All","Weekdays","Weekend"]}return w(t,[{key:"ngOnInit",value:function(){this.form=this.buildForm}},{key:"onSubmitForm",value:function(){var t,e=this;if("new"===this.inputs.action)this.store.dispatch(Object(o.b)(this.form.value));else if("update"===this.inputs.action&&this.inputs.prefs){var n=null===(t=this.inputs.prefs)||void 0===t?void 0:t.map((function(t){return Object.assign(Object.assign({},e.form.value),{contractType:"flex",contract:t.participant.contract})}));this.store.dispatch(Object(o.i)({participants:n}))}}},{key:"buildForm",get:function(){return this.formBuilder.group("new"===this.inputs.action&&this.inputs.contractTypes?{contractType:[this.inputs.contractTypes[0],[i.x.required]],maxSize:[0,[i.x.required]],maxPosition:[0,[i.x.required]],acceptLong:[!1,[i.x.required]],acceptShort:[!1,[i.x.required]],timeFrame:["Weekdays",[i.x.required]]}:{maxSize:[0,[i.x.required]],maxPosition:[0,[i.x.required]],acceptLong:[!1,[i.x.required]],acceptShort:[!1,[i.x.required]],timeFrame:["Weekdays",[i.x.required]]})}},{key:"prefLables",get:function(){var t;return null===(t=this.inputs.prefs)||void 0===t?void 0:t.map((function(t){return t.participant.contract})).join(", ")}},{key:"quoteLabel",get:function(){return"multi-collateral"===this.inputs.family?"(USD)":"(Contracts)"}}]),t}();return t.\u0275fac=function(e){return new(e||t)(a.Ob(r.a),a.Ob(s.b),a.Ob(i.d))},t.\u0275cmp=a.Ib({type:t,selectors:[["position-assignment"]],decls:30,vars:26,consts:[[1,"position-assignment",3,"heading"],[1,"position-assignment__form","global__text","global__text-body",3,"formGroup","ngSubmit"],["color","accent","appearance","fill","class","global__text global__text-body",4,"ngIf"],[3,"marginBottom",4,"ngIf"],[1,"position-assignment__checkboxes"],["formControlName","acceptLong"],["formControlName","acceptShort"],["color","accent","appearance","fill",1,"global__text","global__text-body"],["formControlName","maxSize","required","","matInput","","type","number"],["formControlName","maxPosition","required","","matInput","","type","number"],["matNativeControl","","formControlName","timeFrame"],[3,"value",4,"ngFor","ngForOf"],["mat-raised-button","",1,"global__text","global__text-body",3,"disabled"],["matNativeControl","","formControlName","contractType"],[3,"value"],["subheading","","bold","","ghost",""],["body",""]],template:function(t,e){1&t&&(a.Ub(0,"pro-dialog",0),a.Ub(1,"form",1),a.bc("ngSubmit",(function(){return e.onSubmitForm()})),a.Oc(2,S,6,4,"mat-form-field",2),a.Oc(3,E,5,3,"section",3),a.Ub(4,"section",4),a.Ub(5,"mat-checkbox",5),a.Qc(6),a.gc(7,"translate"),a.Tb(),a.Ub(8,"mat-checkbox",6),a.Qc(9),a.gc(10,"translate"),a.Tb(),a.Tb(),a.Ub(11,"mat-form-field",7),a.Ub(12,"mat-label"),a.Qc(13),a.gc(14,"translate"),a.Tb(),a.Pb(15,"input",8),a.Tb(),a.Ub(16,"mat-form-field",7),a.Ub(17,"mat-label"),a.Qc(18),a.gc(19,"translate"),a.Tb(),a.Pb(20,"input",9),a.Tb(),a.Ub(21,"mat-form-field",7),a.Ub(22,"mat-label"),a.Qc(23),a.gc(24,"translate"),a.Tb(),a.Ub(25,"mat-select",10),a.Oc(26,x,2,2,"mat-option",11),a.Tb(),a.Tb(),a.Ub(27,"button",12),a.Qc(28),a.gc(29,"translate"),a.Tb(),a.Tb(),a.Tb()),2&t&&(a.mc("heading","new"===e.inputs.action?"New Assignment Preferences":"Update Assignment Preferences"),a.Cb(1),a.mc("formGroup",e.form),a.Cb(1),a.mc("ngIf","new"===e.inputs.action),a.Cb(1),a.mc("ngIf","update"===e.inputs.action&&(null==e.inputs.prefs?null:e.inputs.prefs.length)),a.Cb(3),a.Sc(" ",a.hc(7,14,"FORM.ACCEPT_LONG")," "),a.Cb(3),a.Sc(" ",a.hc(10,16,"FORM.ACCEPT_SHORT")," "),a.Cb(4),a.Tc("",a.hc(14,18,"FORM.MAX_SIZE")," ",e.quoteLabel,""),a.Cb(5),a.Tc("",a.hc(19,20,"FORM.MAX_POSITION")," ",e.quoteLabel,""),a.Cb(5),a.Rc(a.hc(24,22,"FORM.TIMEFRAME")),a.Cb(3),a.mc("ngForOf",e.timeframes),a.Cb(1),a.mc("disabled",e.form.invalid),a.Cb(1),a.Sc(" ",a.hc(29,24,"BUTTON.SUBMIT")," "))},directives:[c.a,u.a,i.z,i.p,i.h,l.n,d.a,i.o,i.g,h.c,h.f,i.c,f.b,i.s,i.v,p.a,l.m,b.b,g.n,m.a,v.a,y.a,_.a],pipes:[O.d,k.a],styles:["form[_ngcontent-%COMP%] .mat-form-field[_ngcontent-%COMP%]{width:100%}form[_ngcontent-%COMP%] > button[_ngcontent-%COMP%]{margin-top:var(--spacing);width:100%}.position-assignment[_ngcontent-%COMP%]{width:400px}@media (max-width:599px){.position-assignment[_ngcontent-%COMP%]{width:100%}}.position-assignment__checkboxes[_ngcontent-%COMP%]{margin-bottom:var(--spacing)}"],changeDetection:0}),t}()},"eMi/":function(t,e,n){"use strict";n.d(e,"c",(function(){return r})),n.d(e,"b",(function(){return o})),n.d(e,"a",(function(){return a})),n.d(e,"e",(function(){return s})),n.d(e,"d",(function(){return c}));var i=n("zqNl"),r=Object(i.g)("Reset Affiliate State"),o=Object(i.g)("Get Affiliate Details"),a=Object(i.g)("Create Affiliate Details"),s=Object(i.g)("Set Affiliate Details",Object(i.l)()),c=Object(i.g)("Set Affiliate Code",Object(i.l)())},"eY+9":function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var i=function(t){return t&&"number"==typeof t.length&&"function"!=typeof t}},ebJJ:function(t,e,n){"use strict";n.d(e,"a",(function(){return Dt}));var i=n("D57K"),r=n("kZht"),o=n("3kIJ"),a=n("zqNl"),s=n("+Px6"),c=n("rxqU"),u=n("qAYy"),l=n("J/3c"),d=n("KyJX"),h=n("YyhG"),f=n("l5Az"),p=n("YtkY"),b=n("3mST"),g=n("w0kG"),v=n("xVbo"),y=n("TLy2"),_=n("jOdJ"),O=n("gxtV"),k=n("lx5p"),T=n("i67J"),S=n("HM3f"),E=n("C05f"),x=n("8lHc"),P=n("1u95"),A=n("h3eB"),I=n("uJYd"),M=n("VmIW"),D=n("KQpv"),R=n.n(D),j=n("NloN"),L=n("ylpo"),N=n("QdGC"),U=n("CW1w"),F=n("bjK4"),B=n("1VvW"),z=n("An66"),V=n("anSm"),H=n("TMzY"),q=n("EmXI"),$=n("B6Vo"),Q=n("Cc4E"),W=n("zho4"),G=n("Tcl6"),Y=n("aaFr"),K=n("ROO/"),Z=n("aDqW"),X=n("UDV5"),J=n("IkSM"),tt=n("bW1a"),et=n("hCLc"),nt=n("NxuZ"),it=n("tOKo"),rt=n("8spT"),ot=n("icqo"),at=n("za3o"),st=n("LbKT"),ct=n("FUqb"),ut=function(){return[500,100]};function lt(t,e){if(1&t){var n=r.Vb();r.Ub(0,"mat-form-field",32),r.Ub(1,"mat-label"),r.Qc(2),r.gc(3,"translate"),r.Tb(),r.Ub(4,"input",33),r.bc("input",(function(){return r.Ec(n),r.fc(3).setUSDAmount()})),r.Tb(),r.Ub(5,"span",9),r.Qc(6),r.Tb(),r.Tb()}if(2&t){var i=r.fc(2).ngIf,o=r.fc();r.mc("sbDisabled",!i.displayTooltips)("sbDelay",r.qc(7,ut)),r.Cb(2),r.Sc("",r.hc(3,5,"FORM.LIMIT_PRICE"),":"),r.Cb(2),r.mc("step",o.tickSize(i.selectedMarket)),r.Cb(2),r.Rc(i.quoteCurrency)}}function dt(t,e){if(1&t&&(r.Ub(0,"span",9),r.Qc(1),r.Tb()),2&t){var n=r.fc(3).ngIf;r.Cb(1),r.Sc(" ",n.quoteCurrency," ")}}function ht(t,e){if(1&t){var n=r.Vb();r.Ub(0,"mat-form-field",6),r.Ub(1,"mat-label"),r.Qc(2),r.gc(3,"translate"),r.Tb(),r.Ub(4,"input",34,8),r.bc("focus",(function(){return r.Ec(n),r.fc(3).onSizeFocus()}))("input",(function(){r.Ec(n);var t=r.fc(2).ngIf;return r.fc().setAmount(t.selectedMarket)})),r.Tb(),r.Oc(6,dt,2,1,"span",35),r.Tb()}if(2&t){var i=r.fc(2).ngIf;r.mc("sbDisabled",!i.displayTooltips)("sbDelay",r.qc(7,ut)),r.Cb(2),r.Sc("\u2248 ",r.hc(3,5,"Notional"),":"),r.Cb(2),r.mc("step",1),r.Cb(2),r.mc("ngIf",i.isFlexMarket)}}function ft(t,e){if(1&t){var n=r.Vb();r.Sb(0),r.Ub(1,"div",38),r.Ub(2,"button",39),r.bc("click",(function(){r.Ec(n);var t=r.fc(3).ngIf;return r.fc().setBalancePercentage(.25,t.selectedMarket,t.selectedMarketPosition)})),r.Qc(3," 25% "),r.Tb(),r.Ub(4,"button",39),r.bc("click",(function(){r.Ec(n);var t=r.fc(3).ngIf;return r.fc().setBalancePercentage(.5,t.selectedMarket,t.selectedMarketPosition)})),r.Qc(5," 50% "),r.Tb(),r.Ub(6,"button",39),r.bc("click",(function(){r.Ec(n);var t=r.fc(3).ngIf;return r.fc().setBalancePercentage(.75,t.selectedMarket,t.selectedMarketPosition)})),r.Qc(7," 75% "),r.Tb(),r.Ub(8,"button",39),r.bc("click",(function(){r.Ec(n);var t=r.fc(3).ngIf;return r.fc().setBalancePercentage(.98,t.selectedMarket,t.selectedMarketPosition)})),r.Qc(9," 100% "),r.Tb(),r.Tb(),r.Rb()}}function pt(t,e){if(1&t){var n=r.Vb();r.Ub(0,"button",40),r.bc("click",(function(){return r.Ec(n),r.fc(4).viewWallets()})),r.Pb(1,"fa-icon",41),r.Qc(2),r.gc(3,"translate"),r.Tb()}2&t&&(r.Lc("margin-bottom","var(--spacing)"),r.Cb(2),r.Sc(" ",r.hc(3,3,"Transfer Funds")," "))}function bt(t,e){if(1&t&&(r.Sb(0),r.Oc(1,ft,10,0,"ng-container",36),r.Oc(2,pt,4,5,"ng-template",null,37,r.Pc),r.Rb()),2&t){var n=r.Ac(3),i=r.fc(2).ngIf;r.Cb(1),r.mc("ngIf",null==i.wallet?null:i.wallet.am)("ngIfElse",n)}}var gt=function(){return[250,100]};function mt(t,e){if(1&t&&(r.Ub(0,"mat-checkbox",42),r.Ub(1,"span",43),r.Qc(2),r.gc(3,"translate"),r.Tb(),r.Tb()),2&t){var n=r.fc(2).ngIf;r.Cb(1),r.mc("sbDisabled",!n.displayTooltips)("sbDelay",r.qc(5,gt)),r.Cb(1),r.Sc(" ",r.hc(3,3,"BUTTON.MAKER_ONLY")," ")}}function vt(t,e){1&t&&(r.Sb(0),r.Pb(1,"leverage-limiter"),r.Rb())}function yt(t,e){1&t&&(r.Ub(0,"section",44),r.Ub(1,"mat-radio-group",45),r.Ub(2,"mat-radio-button",46),r.Qc(3),r.gc(4,"translate"),r.Tb(),r.Ub(5,"mat-radio-button",47),r.Qc(6),r.gc(7,"translate"),r.Tb(),r.Tb(),r.Tb()),2&t&&(r.Cb(3),r.Sc(" ",r.hc(4,2,"BUTTON.IOC")," "),r.Cb(3),r.Sc(" ",r.hc(7,4,"BUTTON.GOOD_TILL_CANCEL")," "))}function _t(t,e){if(1&t&&(r.Ub(0,"div",48),r.Ub(1,"p",49),r.Qc(2),r.Pb(3,"fa-icon",50),r.Tb(),r.Tb()),2&t){r.fc();var n=r.Ac(15),i=r.fc(2);r.mc("sbMenuTriggerFor",n),r.Cb(2),r.Sc(" ",i.triggerSignal," ")}}function Ot(t,e){if(1&t&&(r.Ub(0,"mat-form-field",51),r.Ub(1,"mat-label"),r.Qc(2),r.gc(3,"translate"),r.Tb(),r.Pb(4,"input",52),r.Ub(5,"span",9),r.Qc(6),r.Tb(),r.Tb()),2&t){var n=r.fc(2).ngIf;r.Cb(2),r.Sc("",r.hc(3,2,"SL Price"),":"),r.Cb(4),r.Rc(n.quoteCurrency)}}function kt(t,e){if(1&t&&(r.Ub(0,"mat-form-field",51),r.Ub(1,"mat-label"),r.Qc(2),r.gc(3,"translate"),r.Tb(),r.Pb(4,"input",53),r.Ub(5,"span",9),r.Qc(6),r.Tb(),r.Tb()),2&t){var n=r.fc(2).ngIf;r.Cb(2),r.Sc("",r.hc(3,2,"TP Price"),":"),r.Cb(4),r.Rc(n.quoteCurrency)}}function wt(t,e){if(1&t&&(r.Ub(0,"p",56),r.Ub(1,"span"),r.Qc(2," Stop PnL: "),r.Tb(),r.Ub(3,"span",57),r.Qc(4),r.gc(5,"change"),r.gc(6,"number"),r.Tb(),r.Tb()),2&t){var n=r.fc(3).ngIf,i=r.fc();r.Cb(3),r.mc("pnl",i.stopLoss.some()),r.Cb(1),r.Tc(" ",r.hc(5,3,r.ic(6,5,i.stopLoss.some(),"1.2-2"))," ",n.quoteCurrency," ")}}function Ct(t,e){if(1&t&&(r.Ub(0,"p",56),r.Ub(1,"span"),r.Qc(2," Exit PnL: "),r.Tb(),r.Ub(3,"span",57),r.Qc(4),r.gc(5,"change"),r.gc(6,"number"),r.Tb(),r.Tb()),2&t){var n=r.fc(3).ngIf,i=r.fc();r.Cb(3),r.mc("pnl",i.exitProfit.some()),r.Cb(1),r.Tc(" ",r.hc(5,3,r.ic(6,5,i.exitProfit.some(),"1.2-2"))," ",n.quoteCurrency," ")}}function Tt(t,e){if(1&t&&(r.Ub(0,"section",54),r.Oc(1,wt,7,8,"p",55),r.Oc(2,Ct,7,8,"p",55),r.Tb()),2&t){var n=r.fc(3);r.Cb(1),r.mc("ngIf",n.stopLoss.isSome()&&n.slEnabled),r.Cb(1),r.mc("ngIf",n.exitProfit.isSome()&&n.tpEnabled)}}function St(t,e){1&t&&(r.Ub(0,"section",58),r.Pb(1,"fa-icon",59),r.Ub(2,"p",56),r.Qc(3,"This market is currently in post-only mode."),r.Tb(),r.Tb())}var Et=function(){return{horizontal:675,vertical:600}},xt=function(t){return{side:t}};function Pt(t,e){if(1&t){var n=r.Vb();r.Ub(0,"form",2),r.Ub(1,"section",3),r.Oc(2,lt,7,8,"mat-form-field",4),r.Ub(3,"section",5),r.Ub(4,"mat-form-field",6),r.Ub(5,"mat-label"),r.Qc(6),r.gc(7,"translate"),r.Tb(),r.Ub(8,"input",7,8),r.bc("focus",(function(){return r.Ec(n),r.fc(2).onSizeFocus()}))("input",(function(){return r.Ec(n),r.fc(2).setUSDAmount()})),r.Tb(),r.Ub(10,"span",9),r.Qc(11),r.Tb(),r.Tb(),r.Oc(12,ht,7,8,"mat-form-field",10),r.Tb(),r.Oc(13,bt,4,2,"ng-container",0),r.Ub(14,"sb-menu",null,11),r.Ub(16,"button",12),r.bc("click",(function(){return r.Ec(n),r.fc(2).setTriggerSignal("mark")})),r.Ub(17,"span",13),r.Qc(18,"BUTTON.MARK"),r.Tb(),r.Tb(),r.Ub(19,"button",12),r.bc("click",(function(){return r.Ec(n),r.fc(2).setTriggerSignal("last")})),r.Ub(20,"span",13),r.Qc(21,"BUTTON.LAST"),r.Tb(),r.Tb(),r.Ub(22,"button",12),r.bc("click",(function(){return r.Ec(n),r.fc(2).setTriggerSignal("spot")})),r.Ub(23,"span",13),r.Qc(24,"BUTTON.INDEX"),r.Tb(),r.Tb(),r.Tb(),r.Ub(25,"section",14),r.Ub(26,"section",15),r.Oc(27,mt,4,6,"mat-checkbox",16),r.Ub(28,"mat-checkbox",17),r.Ub(29,"span",18),r.Qc(30),r.gc(31,"translate"),r.Tb(),r.Tb(),r.Tb(),r.Oc(32,vt,2,0,"ng-container",0),r.Oc(33,yt,8,6,"section",19),r.Ub(34,"section",20),r.Ub(35,"div",21),r.Ub(36,"mat-checkbox",22),r.Qc(37),r.gc(38,"translate"),r.Tb(),r.Ub(39,"mat-checkbox",23),r.Qc(40),r.gc(41,"translate"),r.Tb(),r.Tb(),r.Oc(42,_t,4,2,"div",24),r.Tb(),r.Ub(43,"section",5),r.Oc(44,Ot,7,4,"mat-form-field",25),r.Oc(45,kt,7,4,"mat-form-field",25),r.Tb(),r.Oc(46,Tt,3,2,"section",26),r.Tb(),r.Tb(),r.Pb(47,"order-form-details",27),r.Ub(48,"section",28),r.Oc(49,St,4,0,"section",29),r.Ub(50,"section",30),r.Ub(51,"button",31),r.bc("click",(function(){r.Ec(n);var t=r.fc().ngIf;return r.fc().submitOrder(t.selectedMarket,t.initialMargin,t.wallet)})),r.Qc(52),r.gc(53,"titlecase"),r.gc(54,"translate"),r.Tb(),r.Tb(),r.Tb(),r.Tb()}if(2&t){var i=r.fc().ngIf,o=r.fc();r.mc("formGroup",o.form)("breakpoints",r.qc(46,Et)),r.Cb(2),r.mc("ngIf","limit"===o.basicOrderType),r.Cb(2),r.mc("sbDisabled",!i.displayTooltips)("sbDelay",r.qc(47,ut)),r.Cb(2),r.Sc("",r.hc(7,33,"FORM.QUANTITY"),":"),r.Cb(2),r.mc("step",o.stepSize(i.selectedMarket)),r.Cb(3),r.Sc(" ",i.sizeUnit," "),r.Cb(1),r.mc("ngIf",i.isFlexMarket),r.Cb(1),r.mc("ngIf",i.isFlexMarket),r.Cb(14),r.mc("ngIf","limit"===o.basicOrderType),r.Cb(2),r.mc("sbDisabled",!i.displayTooltips)("sbDelay",r.qc(48,gt)),r.Cb(1),r.Sc(" ",r.hc(31,35,"BUTTON.REDUCE_ONLY")," "),r.Cb(2),r.mc("ngIf",!i.isFlexMarket),r.Cb(1),r.mc("ngIf","limit"===o.basicOrderType),r.Cb(4),r.Sc(" ",r.hc(38,37,"LABEL.STOP_LOSS")," "),r.Cb(3),r.Sc(" ",r.hc(41,39,"LABEL.TAKE_PROFIT")," "),r.Cb(2),r.mc("ngIf",o.slEnabled||o.tpEnabled),r.Cb(2),r.mc("ngIf",o.slEnabled),r.Cb(1),r.mc("ngIf",o.tpEnabled),r.Cb(1),r.mc("ngIf",i.isFlexMarket),r.Cb(1),r.mc("side",o.side)("selectedMarket",i.selectedMarket)("selectedTicker",i.selectedTicker)("initialMargin",o.hasPriceAndSize?i.initialMargin:0)("wallet",i.wallet)("isTrigger",!1)("form",o.form)("imOverBalance",i.imOverBalance),r.Cb(2),r.mc("ngIf",i.selectedMarket.postOnly),r.Cb(2),r.mc("disabled",o.form.invalid||0===i.wallet.am||i.loading||i.imOverBalance),r.Cb(1),r.Sc(" ",r.hc(53,41,r.ic(54,43,"LABEL.PLACE_ORDER",r.rc(49,xt,o.side)))," ")}}function At(t,e){if(1&t&&(r.Sb(0),r.Oc(1,Pt,55,51,"form",1),r.Rb()),2&t){var n=r.fc();r.Cb(1),r.mc("ngIf",n.form)}}var It=function(t,e,n,i,r,o,a,s,c,u,l,d,h,f,p,b){return{selectedMarket:t,selectedTicker:e,displayTooltips:n,baseCurrency:i,quoteCurrency:r,wallet:o,initialMargin:a,isFlexMarket:s,userData:c,sizeFormatter:u,maxOrderSize:l,position:d,loading:h,imOverBalance:f,sizeUnit:p,selectedMarketPosition:b}},Mt=R()("trace:app:basic-order-form"),Dt=function(){var t=function(){function t(e,n,i,o,f){var b=this;C(this,t),this.formBuilder=e,this.store=n,this.trade=i,this.el=o,this.router=f,this.selectedMarket$=this.store.pipe(Object(a.m)(s.n)),this.selectedTicker$=this.store.pipe(Object(a.m)(u.p)),this.displayTooltips$=this.store.pipe(Object(a.m)(c.y)),this.baseCurrency$=this.store.pipe(Object(a.m)(s.s)),this.quoteCurrency$=this.store.pipe(Object(a.m)(s.u)),this.userSelectedFuturesWallet$=this.store.pipe(Object(a.m)(l.n)),this.initialMargin$=this.store.pipe(Object(a.m)(d.d)),this.userSignedIn$=this.store.pipe(Object(a.m)(c.m)),this.isFlexMarket$=this.store.pipe(Object(a.m)(s.a)),this.userData$=this.store.pipe(Object(a.m)(c.a)),this.sizeFormatter$=this.store.pipe(Object(a.m)(h.m)),this.selectedMarketPosition$=this.store.pipe(Object(a.m)(h.g)),this.loading$=this.store.pipe(Object(a.m)(F.m,{filter:[A.o.type,A.n.type]})),this.imOverBalance$=Object(S.a)([this.initialMargin$,this.userSelectedFuturesWallet$]).pipe(Object(p.a)((function(t){var e=m(t,2),n=e[0],i=e[1];return i&&n[b.side]>i.am&&n[b.side]>0}))),this.isSliding=!1,this.maxOrderSize$=new E.a(null),this.sizeUnit$=this.store.pipe(Object(a.m)(h.n)),this.refreshOptions=new r.o,this.blurFieldEsc=function(t){return Object(N.a)(t)}}return w(t,[{key:"ngOnInit",value:function(){var t=this;this.buildForm(),this.getInitialMargin(),this.getMaxOrderSize(),this.selectedMarket$.pipe(Object(b.a)(1),Object(O.b)(this)).subscribe((function(e){var n,i,r,o;null===(n=t.form.get("size"))||void 0===n||n.setValue(0),null===(i=t.form.get("usdSize"))||void 0===i||i.setValue(0),null===(r=t.form.get("slEnabled"))||void 0===r||r.setValue(!1),null===(o=t.form.get("tpEnabled"))||void 0===o||o.setValue(!1)})),this.trade.orderFormPriceUpdated$.pipe(Object(g.a)(this.selectedMarket$),Object(v.a)((function(t){var e=m(t,2),n=e[0],i=e[1];return!!n&&!!i})),Object(O.b)(this)).subscribe((function(e){var n,i=m(e,2),r=i[0],o=i[1],a=Object(k.I)(o.tickSize)(r);null===(n=t.form.get("limitPrice"))||void 0===n||n.setValue(a)})),this.trade.orderFormQuantityUpdated$.pipe(Object(T.g)(),Object(O.b)(this)).subscribe((function(e){var n;null===(n=t.form.get("size"))||void 0===n||n.setValue(e),t.setUSDAmount()})),this.selectedMarketPosition$.pipe(Object(O.b)(this)).subscribe((function(e){var n;e||null===(n=t.form.get("reduceOnly"))||void 0===n||n.setValue(!1)}))}},{key:"ngOnChanges",value:function(t){var e,n,i,r,o,a,s=this;if(null===(e=t.basicOrderType)||void 0===e?void 0:e.currentValue){var c=null===(i=null===(n=this.form)||void 0===n?void 0:n.get("size"))||void 0===i?void 0:i.value;this.buildForm(c),setTimeout((function(){s.setUSDAmount()}),1500)}(null===(r=t.side)||void 0===r?void 0:r.currentValue)&&(null===(o=this.form.get("slPrice"))||void 0===o||o.updateValueAndValidity(),null===(a=this.form.get("tpPrice"))||void 0===a||a.updateValueAndValidity())}},{key:"ngAfterViewInit",value:function(){this.setupLocalKeybinds()}},{key:"ngOnDestroy",value:function(){var t;this.clearInitialMargin(),null===(t=this.locallyFocussedKeybinds)||void 0===t||t.reset(),this.locallyFocussedKeybinds=void 0}},{key:"stopPriceValidatorFn",value:function(){var t=this;return function(e){return t.selectedTicker$.pipe(Object(T.h)(),Object(p.a)((function(n){var i,r="buy"===t.side?null==n?void 0:n.bid:null==n?void 0:n.ask,o="limit"===t.basicOrderType?null===(i=t.form.get("limitPrice"))||void 0===i?void 0:i.value:r;return"buy"===t.side?e.valueo&&e.value>=r?null:{stopInvalidWithEntry:!0}})))}}},{key:"exitPriceValidatorFn",value:function(){var t=this;return function(e){return t.selectedTicker$.pipe(Object(T.h)(),Object(p.a)((function(n){var i,r="buy"===t.side?null==n?void 0:n.bid:null==n?void 0:n.ask,o="limit"===t.basicOrderType?null===(i=t.form.get("limitPrice"))||void 0===i?void 0:i.value:r;return"buy"===t.side?e.value>o&&e.value>=r?null:{stopInvalidWithEntry:!0}:e.value0&&void 0!==arguments[0]?arguments[0]:0,s=(null===(t=this.options)||void 0===t?void 0:t.reduceOnly)||!1,c=(null===(e=this.options)||void 0===e?void 0:e.makerOnly)||!1,u="limit"===this.basicOrderType,l=new o.e(a||0,[o.x.required,o.x.min(1e-9)]),d=new o.e(0),h=new o.e(s,[o.x.required]),f=new o.e(c,[o.x.required]),p=new o.e(0,[o.x.required,o.x.min(1e-9)]),b=new o.e(!1,[o.x.required]),v=new o.e(!1,[o.x.required]);this.form=this.formBuilder.group(Object.assign(Object.assign(Object.assign({size:l,usdSize:d,reduceOnly:h},u&&{limitPrice:p}),u&&{makerOnly:f}),{orderTypeOverride:[this.basicOrderType,[o.x.required]],slEnabled:b,tpEnabled:v})),this.watchFormOptions(),null===(n=this.form.get("slEnabled"))||void 0===n||n.valueChanges.subscribe((function(t){if(t){var e=new o.e(r.form.value.limitPrice||"",[o.x.required,o.x.min(1e-9)],r.stopPriceValidatorFn()),n=new o.e("mark",[o.x.required]);r.form.addControl("slPrice",e),r.form.value.triggerSignal||r.form.addControl("triggerSignal",n)}else r.form.removeControl("slPrice")})),null===(i=this.form.get("tpEnabled"))||void 0===i||i.valueChanges.subscribe((function(t){if(t){var e=new o.e(r.form.value.limitPrice||"",[o.x.required,o.x.min(1e-9)],r.exitPriceValidatorFn()),n=new o.e("mark",[o.x.required]);r.form.addControl("tpPrice",e),r.form.value.triggerSignal||r.form.addControl("triggerSignal",n)}else r.form.removeControl("tpPrice")})),this.selectedMarket$.pipe(Object(T.h)(),Object(g.a)(this.selectedTicker$)).subscribe((function(t){var e,n=m(t,2),i=n[0],o=n[1],a=("buy"===r.side?null==o?void 0:o.bid:null==o?void 0:o.ask)||0,s=Object(k.I)(i.tickSize)(a);null===(e=r.form.get("limitPrice"))||void 0===e||e.setValue(s),r.setUSDAmount()}))}},{key:"getInitialMargin",value:function(){var t=this;this.clearInitialMargin(),Object(x.a)(100,1e3).pipe(Object(g.a)(this.userSignedIn$),Object(g.a)(this.selectedMarket$),Object(v.a)((function(t){var e=m(t,2),n=m(e[0],2)[1];e[1];return n})),Object(v.a)((function(){return t.form&&t.form.get("size").value>0&&(!t.form.get("limitPrice")||t.form.get("limitPrice").value>0)})),Object(v.a)((function(t){var e=m(t,2),n=(m(e[0],2)[1],e[1]);return!!n&&!n.symbol.startsWith("S")})),Object(O.b)(this)).subscribe((function(e){var n=m(e,2),i=(m(n[0],2)[1],n[1]),r=i.contractValueTradePrecision,o=Object.assign(Object.assign({},t.form.value),{symbol:i.symbol.toUpperCase(),orderType:t.basicOrderType,size:Object(k.H)(r)(t.form.value.size)});t.store.dispatch(Object(P.b)({order:o,editMargin:!1}))}))}},{key:"getMaxOrderSize",value:function(){var t=this;Object(x.a)(100,1e3).pipe(Object(g.a)(this.userSignedIn$),Object(g.a)(this.selectedMarket$),Object(v.a)((function(t){var e=m(t,1);return m(e[0],2)[1]})),Object(v.a)((function(){return!t.form.get("limitPrice")||t.form.get("limitPrice").value>0})),Object(v.a)((function(t){var e=m(t,2)[1];return!!e&&!e.symbol.startsWith("S")})),Object(O.b)(this),Object(y.a)((function(e){var n=m(e,2)[1];return t.trade.calculateMaxOrderSize({symbol:n.symbol.toUpperCase(),orderType:t.basicOrderType,limitPrice:t.form.value.limitPrice})}))).subscribe((function(e){t.maxOrderSize$.next(e)}))}},{key:"submitOrder",value:function(t,e,n){var i,r,o,a,s=null===(i=this.form.get("limitPrice"))||void 0===i?void 0:i.value,c=null===(r=this.form.get("makerOnly"))||void 0===r?void 0:r.value,u=null===(o=this.form.get("tpEnabled"))||void 0===o?void 0:o.value,l=null===(a=this.form.get("slEnabled"))||void 0===a?void 0:a.value,d=e[this.side],h={side:this.side,symbol:t.symbol.toUpperCase(),orderType:this.basicOrderType,size:this.form.value.size,quantityType:this.form.value.reference,limitPrice:s,reduceOnly:this.form.value.reduceOnly,margin:this.form.value.margin,triggerSignal:this.form.value.triggerSignal},f=u?{side:"buy"===this.side?"sell":"buy",symbol:t.symbol.toUpperCase(),orderType:"take_profit",size:this.form.value.size,stopPrice:this.form.value.tpPrice,reduceOnly:!0,triggerSignal:this.form.value.triggerSignal}:void 0,p=l?{side:"buy"===this.side?"sell":"buy",symbol:t.symbol.toUpperCase(),orderType:"stop",size:this.form.value.size,stopPrice:this.form.value.slPrice,reduceOnly:!0,triggerSignal:this.form.value.triggerSignal}:void 0;c?h.orderType="post":this.form.get("orderTypeOverride")&&(h.orderType=this.form.get("orderTypeOverride").value),this.store.dispatch("flexible_futures"!==t.type&&d>n.am&&d>0?Object(I.j)({message:"SNACKBAR.ORDER_EXCEED_MAX_LVG",class:"warn"}):f||p?Object(A.n)({mainOrder:h,stopLoss:p,takeProfit:f}):Object(A.o)(h))}},{key:"clearInitialMargin",value:function(){this.store.dispatch(Object(P.e)({buy:0,sell:0}))}},{key:"setupLocalKeybinds",value:function(){var t=this;this.locallyFocussedKeybinds=new Mousetrap(this.el.nativeElement),this.locallyFocussedKeybinds.bind("shift+r",(function(){var e=t.form.get("reduceOnly");null==e||e.setValue(!e.value)})),this.locallyFocussedKeybinds.bind("shift+a",(function(){var e=t.form.get("makerOnly");null==e||e.setValue(!e.value)}))}},{key:"watchFormOptions",value:function(){var t=this;this.form.valueChanges.subscribe((function(e){var n=Object.assign({},t.options);M.Maybe.fromNull(e.makerOnly).forEach((function(t){return n.makerOnly=t})),M.Maybe.fromNull(e.reduceOnly).forEach((function(t){return n.reduceOnly=t})),M.Maybe.fromNull(e.orderTypeOverride).forEach((function(t){return n.orderTypeOverride=t})),Mt("saving form options",n),Object(j.c)(L.j,n),t.refreshOptions.emit()}))}},{key:"setTriggerSignal",value:function(t){var e;null===(e=this.form.get("triggerSignal"))||void 0===e||e.setValue(t)}},{key:"onSizeFocus",value:function(){var t=this.form.get("size");0===t.value&&t.setValue("")}},{key:"setUSDAmount",value:function(){var t,e,n,i=null===(t=this.form.get("size"))||void 0===t?void 0:t.value,r=this.maxOrderSize$.getValue(),o="buy"===this.side?null==r?void 0:r.buyPrice:null==r?void 0:r.sellPrice,a="limit"===this.basicOrderType?null===(e=this.form.get("limitPrice"))||void 0===e?void 0:e.value:o,s="limit"===this.basicOrderType?a:o;null===(n=this.form.get("usdSize"))||void 0===n||n.setValue(Object(k.I)(.01)(i*s))}},{key:"setAmount",value:function(t){var e,n,i,r=null===(e=this.form.get("usdSize"))||void 0===e?void 0:e.value,o=this.maxOrderSize$.getValue(),a="buy"===this.side?null==o?void 0:o.buyPrice:null==o?void 0:o.sellPrice,s=(null===(n=this.form.get("limitPrice"))||void 0===n?void 0:n.value)||a,c="limit"===this.basicOrderType?s:a;null===(i=this.form.get("size"))||void 0===i||i.setValue(Object(k.H)(t.contractValueTradePrecision)(r/c))}},{key:"changeSize",value:function(t,e){var n,i=this.maxOrderSize$.getValue();if(i){var r=("buy"===this.side?i.maxBuySize:i.maxSellSize)/100*t;null===(n=this.form.get("size"))||void 0===n||n.setValue(Object(k.H)(e.contractValueTradePrecision)(r)),this.setUSDAmount()}}},{key:"setSliding",value:function(t){this.isSliding=t}},{key:"closePosition",value:function(){var t=this;this.selectedMarketPosition$.pipe(Object(_.a)(),Object(g.a)(this.selectedMarket$)).subscribe((function(e){var n,i,r=m(e,2),o=r[0],a=r[1],s=Math.abs((null==o?void 0:o.balance)||0),c=a.contractValueTradePrecision;null===(n=t.form.get("size"))||void 0===n||n.setValue(Object(k.H)(c)(s)),null===(i=t.form.get("reduceOnly"))||void 0===i||i.setValue(!0),t.setUSDAmount()}))}},{key:"setBalancePercentage",value:function(t,e,n){var i,r=this.maxOrderSize$.value,o="buy"===this.side?null==r?void 0:r.maxBuySize:null==r?void 0:r.maxSellSize,a=n&&(n.balance>0&&"sell"===this.side||n.balance<0&&"buy"===this.side),s=a?Math.abs(n.balance):o;if(s){var c=s*(.98===t&&a?1:t);null===(i=this.form.get("size"))||void 0===i||i.setValue(Object(k.H)(e.contractValueTradePrecision)(c)),this.setUSDAmount()}}},{key:"tickSize",value:function(t){return"flexible_futures"===t.type?1/Math.pow(10,t.contractValueTradePrecision):t?t.tickSize:1}},{key:"stepSize",value:function(t){return t?1/Math.pow(10,t.contractValueTradePrecision):1}},{key:"hasClosablePosition",value:function(t){return t.balance>0&&"sell"===this.side||t.balance<0&&"buy"===this.side}},{key:"viewWallets",value:function(){this.router.navigate(["wallets"])}},{key:"hasPriceAndSize",get:function(){return this.form.get("limitPrice")?this.form.value.limitPrice&&this.form.value.size:!!this.form.value.size}},{key:"slEnabled",get:function(){var t;return null===(t=this.form.get("slEnabled"))||void 0===t?void 0:t.value}},{key:"tpEnabled",get:function(){var t;return null===(t=this.form.get("tpEnabled"))||void 0===t?void 0:t.value}},{key:"triggerSignal",get:function(){var t;return null===(t=this.form.get("triggerSignal"))||void 0===t?void 0:t.value}},{key:"stopLoss",get:function(){var t,e,n,i=null===(t=this.form.get("slPrice"))||void 0===t?void 0:t.value,r=null===(e=this.form.get("limitPrice"))||void 0===e?void 0:e.value,o=null===(n=this.form.get("size"))||void 0===n?void 0:n.value,a=this.maxOrderSize$.value,s="limit"===this.basicOrderType?r:"buy"===this.side?null==a?void 0:a.buyPrice:null==a?void 0:a.sellPrice,c="buy"===this.side?"long":"short";return i?Object(M.Some)(Object(U.f)({entry:s,exit:i,isInverse:!1,quantity:o,side:c})):Object(M.None)()}},{key:"exitProfit",get:function(){var t,e,n,i=null===(t=this.form.get("tpPrice"))||void 0===t?void 0:t.value,r=null===(e=this.form.get("limitPrice"))||void 0===e?void 0:e.value,o=null===(n=this.form.get("size"))||void 0===n?void 0:n.value,a=this.maxOrderSize$.value,s="limit"===this.basicOrderType?r:"buy"===this.side?null==a?void 0:a.buyPrice:null==a?void 0:a.sellPrice,c="buy"===this.side?"long":"short";return i?Object(M.Some)(Object(U.f)({entry:s,exit:i,isInverse:!1,quantity:o,side:c})):Object(M.None)()}}]),t}();return t.\u0275fac=function(e){return new(e||t)(r.Ob(o.d),r.Ob(a.b),r.Ob(f.a),r.Ob(r.l),r.Ob(B.d))},t.\u0275cmp=r.Ib({type:t,selectors:[["basic-order-form"]],hostBindings:function(t,e){1&t&&r.bc("keydown",(function(t){return e.blurFieldEsc(t)}))},inputs:{side:"side",options:"options",indexPrice:"indexPrice",basicOrderType:"basicOrderType"},outputs:{refreshOptions:"refreshOptions"},features:[r.Ab],decls:17,vars:50,consts:[[4,"ngIf"],["class","basic-order","body","","orientation","",3,"formGroup","breakpoints",4,"ngIf"],["body","","orientation","",1,"basic-order",3,"formGroup","breakpoints"],[1,"inputs"],["color","accent","appearance","fill","sbTooltip","TOOLTIP.LIMIT_PRICE",3,"sbDisabled","sbDelay",4,"ngIf"],[1,"input-row"],["color","accent","appearance","fill","sbTooltip","TOOLTIP.QUANTITY",3,"sbDisabled","sbDelay"],["autocomplete","off","type","number","pattern","\\d*.?\\d*","formControlName","size","matInput","","min","0",3,"step","focus","input"],["quantityField",""],["matSuffix",""],["color","accent","appearance","fill","sbTooltip","TOOLTIP.QUANTITY",3,"sbDisabled","sbDelay",4,"ngIf"],["triggerSignalMenu","sbMenu"],["sb-menu-item","","type","button",3,"click"],["translate",""],[1,"options"],[1,"maker-reduce"],["formControlName","makerOnly",4,"ngIf"],["formControlName","reduceOnly"],["tooltip","","sbTooltip","TOOLTIP.REDUCE_ONLY",3,"sbDisabled","sbDelay"],["class","radio-options radio-options--inline",4,"ngIf"],[1,"trigger"],[1,"trigger-checkboxes"],["formControlName","slEnabled",1,"no-border"],["formControlName","tpEnabled",1,"no-border"],["class","trigger-menu",3,"sbMenuTriggerFor",4,"ngIf"],["color","accent","appearance","fill",4,"ngIf"],["class","trigger-details",4,"ngIf"],[3,"side","selectedMarket","selectedTicker","initialMargin","wallet","isTrigger","form","imOverBalance"],[1,"footer"],["class","post-only-notice",4,"ngIf"],["theme","dark",1,"submit"],["mat-raised-button","","body","",3,"disabled","click"],["color","accent","appearance","fill","sbTooltip","TOOLTIP.LIMIT_PRICE",3,"sbDisabled","sbDelay"],["autocomplete","off","type","number","pattern","^\\d*\\.?\\d*$","formControlName","limitPrice","matInput","",3,"step","input"],["autocomplete","off","type","number","pattern","\\d*.?\\d*","formControlName","usdSize","matInput","","min","0",3,"step","focus","input"],["matSuffix","",4,"ngIf"],[4,"ngIf","ngIfElse"],["noFlexFunds",""],[1,"balance-btns"],["matSuffix","","mat-raised-button","","body","","type","button",1,"balance-btn","mat-small-button",3,"click"],["type","button","body","","mat-raised-button","",1,"mat-small-button",3,"click"],["icon","wallet"],["formControlName","makerOnly"],["tooltip","","sbTooltip","TOOLTIP.MAKER_ONLY",3,"sbDisabled","sbDelay"],[1,"radio-options","radio-options--inline"],["formControlName","orderTypeOverride"],["value","ioc"],["value","limit"],[1,"trigger-menu",3,"sbMenuTriggerFor"],["body","","capitalize",""],["icon","chevron-down","size","lg"],["color","accent","appearance","fill"],["autocomplete","off","type","number","pattern","^\\d*\\.?\\d*$","formControlName","slPrice","matInput","","placeholder","0"],["autocomplete","off","type","number","pattern","^\\d*\\.?\\d*$","formControlName","tpPrice","matInput","","placeholder","0"],[1,"trigger-details"],["body","",4,"ngIf"],["body",""],["pnlZero","",3,"pnl"],[1,"post-only-notice"],["icon","info","size","lg"]],template:function(t,e){1&t&&(r.Oc(0,At,2,1,"ng-container",0),r.gc(1,"async"),r.gc(2,"async"),r.gc(3,"async"),r.gc(4,"async"),r.gc(5,"async"),r.gc(6,"async"),r.gc(7,"async"),r.gc(8,"async"),r.gc(9,"async"),r.gc(10,"async"),r.gc(11,"async"),r.gc(12,"async"),r.gc(13,"async"),r.gc(14,"async"),r.gc(15,"async"),r.gc(16,"async")),2&t&&r.mc("ngIf",r.yc(33,It,[r.hc(1,1,e.selectedMarket$),r.hc(2,3,e.selectedTicker$),r.hc(3,5,e.displayTooltips$),r.hc(4,7,e.baseCurrency$),r.hc(5,9,e.quoteCurrency$),r.hc(6,11,e.userSelectedFuturesWallet$),r.hc(7,13,e.initialMargin$),r.hc(8,15,e.isFlexMarket$),r.hc(9,17,e.userData$),r.hc(10,19,e.sizeFormatter$),r.hc(11,21,e.maxOrderSize$),r.hc(12,23,e.selectedMarketPosition$),r.hc(13,25,e.loading$),r.hc(14,27,e.imOverBalance$),r.hc(15,29,e.sizeUnit$),r.hc(16,31,e.selectedMarketPosition$)]))},directives:[z.n,o.z,o.p,V.a,H.a,o.h,q.c,$.a,Q.a,W.a,q.f,o.s,o.c,G.b,o.t,o.o,o.g,q.h,Y.a,K.a,Z.a,X.a,J.a,tt.a,et.b,nt.b,it.a,rt.b,rt.a,ot.b,at.a,st.a],pipes:[z.b,Z.d,z.w,ct.b,z.f],styles:["[noauth][_nghost-%COMP%]{pointer-events:none}mat-card[_ngcontent-%COMP%]{box-shadow:none!important;overflow:hidden}form[_ngcontent-%COMP%]{overflow-x:hidden}form[_ngcontent-%COMP%] .mat-form-field[_ngcontent-%COMP%]{width:100%}.submit[_ngcontent-%COMP%]{display:flex}.submit[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{flex:1}.submit[_ngcontent-%COMP%] button[_ngcontent-%COMP%]:not(:first-of-type){margin-left:var(--spacing)}.footer[_ngcontent-%COMP%]{margin-top:var(--spacing);background:var(--card-colour);text-align:right;width:100%}.options[_ngcontent-%COMP%]{display:block}.inputs[_ngcontent-%COMP%], .options[_ngcontent-%COMP%]{flex-direction:column}.inputs[_ngcontent-%COMP%]{display:flex}.inputs[_ngcontent-%COMP%] mat-form-field[_ngcontent-%COMP%]{flex:1}.order-form[_ngcontent-%COMP%] mat-card-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;height:100%;padding-left:var(--spacing);padding-top:var(--spacing);padding-bottom:var(--spacing)}.radio-options[_ngcontent-%COMP%] mat-radio-group[_ngcontent-%COMP%]{display:flex;flex-flow:column nowrap;padding-top:var(--spacing)}.radio-options--inline[_ngcontent-%COMP%] mat-radio-group[_ngcontent-%COMP%]{flex-flow:row nowrap;justify-content:space-between}.slider-info[_ngcontent-%COMP%]{cursor:pointer}.slider-info[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{color:var(--icon-colour)}.side-buttons[_ngcontent-%COMP%]{padding-right:var(--spacing)}.side[_ngcontent-%COMP%] .buy[_ngcontent-%COMP%]{color:var(--accent-colour)!important}.side[_ngcontent-%COMP%] .buy.mat-button-toggle-checked[_ngcontent-%COMP%]{color:var(--text-colour)!important;background-color:var(--button-accent-colour)!important}.side[_ngcontent-%COMP%] .sell[_ngcontent-%COMP%]{color:var(--warn-colour)!important}.side[_ngcontent-%COMP%] .sell.mat-button-toggle-checked[_ngcontent-%COMP%]{color:var(--text-colour)!important;background-color:var(--button-warn-colour)!important}.input-row[_ngcontent-%COMP%]{display:flex;flex-direction:row;flex:1}.input-row[_ngcontent-%COMP%] .mat-form-field[_ngcontent-%COMP%]{min-width:0}.input-row[_ngcontent-%COMP%] .mat-form-field[_ngcontent-%COMP%]:not(:first-child){padding-left:var(--spacing)}@media (max-width:599px){.input-row[_ngcontent-%COMP%]{width:91vw}}.maker-reduce[_ngcontent-%COMP%]{display:flex;flex-direction:row;justify-content:space-between}.maker-reduce[_ngcontent-%COMP%] .mat-checkbox-layout{border-bottom:none!important}.unauth[_ngcontent-%COMP%]{padding:var(--spacing)}.estimate[_ngcontent-%COMP%]{font-size:2em;margin-right:var(--spacing)}.mat-button-toggle-checked.long[_ngcontent-%COMP%]{background:var(--g300)}.mat-button-toggle-checked.short[_ngcontent-%COMP%]{background:var(--warn-colour)}.close-position[_ngcontent-%COMP%]{align-self:flex-end}.trigger-details[_ngcontent-%COMP%]{display:flex;justify-content:space-evenly}.trigger-details[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{display:flex;flex-direction:column;text-align:center}.trigger[_ngcontent-%COMP%]{display:flex;border-bottom:1px solid var(--border-colour);margin:var(--spacing-s) 0;justify-content:space-between;align-items:center}.trigger-menu[_ngcontent-%COMP%]{cursor:pointer}.trigger-checkboxes[_ngcontent-%COMP%]{display:flex}.trigger-checkboxes[_ngcontent-%COMP%] mat-checkbox[_ngcontent-%COMP%]:first-child{margin-right:var(--spacing-l)}[_nghost-%COMP%]{height:100%;position:relative;overflow-y:auto;padding-right:var(--spacing)}.close-position[_ngcontent-%COMP%]{margin-bottom:var(--spacing)}.balanace-btn[_ngcontent-%COMP%] [_ngcontent-%COMP%]:not(:first-child){margin-left:var(--spacing-s)}.balance-btns[_ngcontent-%COMP%]{justify-content:space-between;flex-wrap:wrap}.balance-btns[_ngcontent-%COMP%], .post-only-notice[_ngcontent-%COMP%]{display:flex;margin-bottom:var(--spacing)}.post-only-notice[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%], .post-only-notice[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{color:var(--y200)!important}.post-only-notice[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{margin-right:var(--spacing-s)}"],changeDetection:0}),t=Object(i.d)([Object(O.a)()],t)}()},ekTi:function(t,e,n){"use strict";var i,r=this&&this.__extends||(i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0});var o=n("w6/c");e.default=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e}(o.default)},fLha:function(t,e,n){"use strict";n.r(e),n.d(e,"WaitingListComponent",(function(){return S}));var i=n("3kIJ"),r=n("Q7YU"),o=n("hsG4"),a=n("zqNl"),s=n("bjK4"),c=n("kZht"),u=n("mcff"),l=n("rfPA"),d=n("bBQR"),h=n("anSm"),f=n("NxuZ"),p=n("1etq"),b=n("EmXI"),g=n("Tcl6"),m=n("An66"),v=n("UDV5"),y=n("hCLc"),_=n("aDqW");function O(t,e){if(1&t&&(c.Ub(0,"option",18),c.Qc(1),c.Tb()),2&t){var n=e.$implicit;c.mc("value",n),c.Cb(1),c.Rc(n)}}function k(t,e){1&t&&(c.Ub(0,"div",19),c.Pb(1,"fa-icon",20),c.Ub(2,"p",21),c.Qc(3),c.gc(4,"translate"),c.Tb(),c.Tb()),2&t&&(c.Cb(3),c.Rc(c.hc(4,1,"Thank you for subscribing!")))}function T(t,e){1&t&&(c.Ub(0,"div",22),c.Pb(1,"fa-icon",23),c.Ub(2,"p",21),c.Qc(3),c.gc(4,"translate"),c.Tb(),c.Tb()),2&t&&(c.Cb(3),c.Rc(c.hc(4,1,"We couldn't validate your request, please try again!")))}var S=function(){var t=function(){function t(e,n,i,r){C(this,t),this.store=e,this.dialogRef=n,this.fb=i,this.userService=r,this.form=this.buildForm(),this.logoUrl$=this.store.pipe(Object(a.m)(s.f,{badge:!0})),this.isSuccess=!1,this.hasErrors=!1}return w(t,[{key:"buildForm",value:function(){return this.fb.group({fullName:["",[i.x.required]],email:["",[i.x.required,i.x.email]],country:["",[i.x.required]],aum:[""],estTradingVol:[""],companyName:[""],optIn:[!1,[i.x.requiredTrue]]})}},{key:"submitForm",value:function(){var t=this;this.isSuccess=!1,this.hasErrors=!1,this.userService.signWaitingList(this.form.value).subscribe((function(){t.isSuccess=!0}),(function(){t.hasErrors=!1}))}},{key:"closeDialog",value:function(){this.dialogRef.close()}},{key:"countries",get:function(){return r.a}}]),t}();return t.\u0275fac=function(e){return new(e||t)(c.Ob(a.b),c.Ob(u.d),c.Ob(i.d),c.Ob(o.a))},t.\u0275cmp=c.Ib({type:t,selectors:[["waiting-list"]],decls:46,vars:32,consts:[[3,"heading"],["body","",1,"dialog-content","vstack","hcenter","gap-l"],[1,"kraken-logo"],["icon","kraken","size","lg"],["subheading",""],["body","",1,"vstack","hcenter",3,"formGroup","ngSubmit"],["color","accent","appearance","fill"],["matInput","","formControlName","fullName","required",""],["matInput","","formControlName","email","required",""],["matNativeControl","","required","","formControlName","country","tabindex","10"],[3,"value",4,"ngFor","ngForOf"],["matInput","","formControlName","aum"],["matInput","","formControlName","estTradingVol"],["matInput","","formControlName","companyName"],["formControlName","optIn",1,"no-border"],["class","success",4,"ngIf"],["class","error",4,"ngIf"],["body","","mat-raised-button","",3,"disabled"],[3,"value"],[1,"success"],["icon","check","size","lg"],["body",""],[1,"error"],["icon","circle-exclamationmark","size","lg"]],template:function(t,e){1&t&&(c.Ub(0,"pro-dialog",0),c.Ub(1,"div",1),c.Ub(2,"div",2),c.Pb(3,"fa-icon",3),c.Tb(),c.Ub(4,"p",4),c.Qc(5," Input your contact information below to be among the first to be notified at launch "),c.Tb(),c.Ub(6,"form",5),c.bc("ngSubmit",(function(){return e.submitForm()})),c.Ub(7,"mat-form-field",6),c.Ub(8,"mat-label"),c.Qc(9),c.gc(10,"translate"),c.Tb(),c.Pb(11,"input",7),c.Tb(),c.Ub(12,"mat-form-field",6),c.Ub(13,"mat-label"),c.Qc(14),c.gc(15,"translate"),c.Tb(),c.Pb(16,"input",8),c.Tb(),c.Ub(17,"mat-form-field",6),c.Ub(18,"mat-label"),c.Qc(19),c.gc(20,"translate"),c.Tb(),c.Ub(21,"select",9),c.Oc(22,O,2,2,"option",10),c.Tb(),c.Tb(),c.Ub(23,"mat-form-field",6),c.Ub(24,"mat-label"),c.Qc(25),c.gc(26,"translate"),c.Tb(),c.Pb(27,"input",11),c.Tb(),c.Ub(28,"mat-form-field",6),c.Ub(29,"mat-label"),c.Qc(30),c.gc(31,"translate"),c.Tb(),c.Pb(32,"input",12),c.Tb(),c.Ub(33,"mat-form-field",6),c.Ub(34,"mat-label"),c.Qc(35),c.gc(36,"translate"),c.Tb(),c.Pb(37,"input",13),c.Tb(),c.Ub(38,"mat-checkbox",14),c.Qc(39),c.gc(40,"translate"),c.Tb(),c.Oc(41,k,5,3,"div",15),c.Oc(42,T,5,3,"div",16),c.Ub(43,"button",17),c.Qc(44),c.gc(45,"translate"),c.Tb(),c.Tb(),c.Tb(),c.Tb()),2&t&&(c.mc("heading","Coming this April - Multi-Collateral Futures"),c.Cb(6),c.mc("formGroup",e.form),c.Cb(3),c.Rc(c.hc(10,16,"Full name")),c.Cb(5),c.Rc(c.hc(15,18,"Email")),c.Cb(5),c.Rc(c.hc(20,20,"FORM.COUNTRY")),c.Cb(3),c.mc("ngForOf",e.countries),c.Cb(3),c.Rc(c.hc(26,22,"Assets under management")),c.Cb(5),c.Rc(c.hc(31,24,"Est. trading volume")),c.Cb(5),c.Rc(c.hc(36,26,"Company name")),c.Cb(4),c.Sc(" ",c.hc(40,28,"I consent to being contacted by Kraken when Multi-Collateral Futures launches. Corporate clients acknowledge they may be contacted before launch by Kraken\u2019s account management team for white glove onboarding support.")," "),c.Cb(2),c.mc("ngIf",e.isSuccess),c.Cb(1),c.mc("ngIf",e.hasErrors),c.Cb(1),c.Lc("margin-top","var(--spacing)"),c.mc("disabled",e.form.invalid||e.isSuccess),c.Cb(1),c.Sc(" ",c.hc(45,30,"Join launch list")," "))},directives:[l.a,d.a,h.a,f.b,p.a,i.z,i.p,i.h,b.c,b.f,g.b,i.c,i.o,i.g,i.v,i.w,m.m,v.a,m.n,y.b,i.r,i.y],pipes:[_.d],styles:["[_nghost-%COMP%]{display:block;width:520px}.kraken-logo[_ngcontent-%COMP%]{display:flex;justify-content:center}.kraken-logo[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{font-size:28px}.success[_ngcontent-%COMP%]{display:grid;justify-content:center;align-items:center;gap:var(--spacing);grid-auto-flow:column;margin:1rem 0}.success[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{color:var(--accent-colour);transform:scale(1.5)}.success[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0;font-size:1rem}.error[_ngcontent-%COMP%]{display:grid;justify-content:center;align-items:center;gap:var(--spacing);grid-auto-flow:column;margin:1rem 0}.error[_ngcontent-%COMP%] fa-icon[_ngcontent-%COMP%]{color:var(--warn-colour);transform:scale(1.5)}.error[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin-bottom:var(--spacing-s)}"],changeDetection:0}),t}()},fa4l:function(t,e,n){"use strict";n.d(e,"a",(function(){return it}));var i=n("D57K"),r=n("kZht"),o=n("3kIJ"),a=n("zqNl"),s=n("+Px6"),c=n("rxqU"),u=n("qAYy"),l=n("J/3c"),d=n("KyJX"),h=n("l5Az"),f=n("3mST"),p=n("w0kG"),b=n("xVbo"),g=n("gxtV"),v=n("lx5p"),y=n("i67J"),_=n("h3eB"),O=n("uJYd"),k=n("VmIW"),T=n("NloN"),S=n("ylpo"),E=n("KQpv"),x=n.n(E),P=n("vYTc"),A=n("QdGC"),I=n("YyhG"),M=n("An66"),D=n("anSm"),R=n("TMzY"),j=n("EmXI"),L=n("IOEv"),N=n("pTnX"),U=n("B6Vo"),F=n("Cc4E"),B=n("zho4"),z=n("Tcl6"),V=n("UDV5"),H=n("IkSM"),q=n("8spT"),$=n("WYJo"),Q=n("bW1a"),W=n("hCLc"),G=n("aDqW"),Y=function(){return[500,100]};function K(t,e){if(1&t&&(r.Ub(0,"mat-form-field",29),r.Ub(1,"mat-label"),r.Qc(2),r.gc(3,"translate"),r.Tb(),r.Pb(4,"input",30),r.Ub(5,"span",11),r.Qc(6),r.Tb(),r.Tb()),2&t){var n=r.fc().ngIf,i=r.fc();r.mc("sbDisabled",!n.displayTooltips)("sbDelay",r.qc(7,Y)),r.Cb(2),r.Sc("",r.hc(3,5,"FORM.LIMIT_PRICE"),":"),r.Cb(2),r.mc("step",i.tickSize(n.selectedMarket)),r.Cb(2),r.Rc(n.quoteCurrency)}}var Z=function(){return{horizontal:675,vertical:600}},X=function(){return[250,100]},J=function(t){return{side:t}};function tt(t,e){if(1&t){var n=r.Vb();r.Sb(0),r.Ub(1,"form",1),r.Ub(2,"section",2),r.Ub(3,"section",3),r.Ub(4,"mat-form-field",4),r.Ub(5,"mat-label"),r.Qc(6),r.gc(7,"translate"),r.Tb(),r.Ub(8,"mat-select",5),r.bc("selectionChange",(function(){return r.Ec(n),r.fc().toggleLimitControl()})),r.Ub(9,"mat-option",6),r.Qc(10),r.gc(11,"translate"),r.Tb(),r.Ub(12,"mat-option",7),r.Qc(13),r.gc(14,"translate"),r.Tb(),r.Tb(),r.Tb(),r.Ub(15,"mat-form-field",8),r.Ub(16,"mat-label"),r.Qc(17),r.gc(18,"translate"),r.Tb(),r.Ub(19,"input",9,10),r.bc("focus",(function(){return r.Ec(n),r.fc().onSizeFocus()})),r.Tb(),r.Ub(21,"span",11),r.Qc(22),r.Tb(),r.Tb(),r.Tb(),r.Ub(23,"section",3),r.Oc(24,K,7,8,"mat-form-field",12),r.Ub(25,"mat-form-field",4),r.Ub(26,"mat-label"),r.Qc(27),r.gc(28,"translate"),r.Tb(),r.Pb(29,"input",13),r.Ub(30,"span",11),r.Qc(31),r.Tb(),r.Tb(),r.Tb(),r.Ub(32,"section",14),r.Ub(33,"section",15),r.Ub(34,"mat-checkbox",16),r.Ub(35,"span",17),r.Qc(36),r.gc(37,"translate"),r.Tb(),r.Tb(),r.Tb(),r.Ub(38,"section",18),r.Ub(39,"mat-label",19),r.Qc(40),r.gc(41,"uppercase"),r.gc(42,"translate"),r.Tb(),r.Ub(43,"mat-radio-group",20),r.Ub(44,"mat-radio-button",21),r.Ub(45,"p",22),r.gc(46,"translate"),r.Qc(47),r.gc(48,"translate"),r.Tb(),r.Tb(),r.Ub(49,"mat-radio-button",23),r.Ub(50,"p",22),r.gc(51,"translate"),r.Qc(52),r.gc(53,"translate"),r.Tb(),r.Tb(),r.Ub(54,"mat-radio-button",24),r.Ub(55,"p",22),r.gc(56,"translate"),r.Qc(57),r.gc(58,"translate"),r.Tb(),r.Tb(),r.Tb(),r.Tb(),r.Tb(),r.Pb(59,"order-form-details",25),r.Ub(60,"section",26),r.Ub(61,"section",27),r.Ub(62,"button",28),r.bc("click",(function(){r.Ec(n);var t=e.ngIf;return r.fc().submitOrder(t.selectedMarket,t.userData)})),r.Qc(63),r.gc(64,"titlecase"),r.gc(65,"translate"),r.Tb(),r.Tb(),r.Tb(),r.Tb(),r.Tb(),r.Rb()}if(2&t){var i=e.ngIf,o=r.fc();r.Cb(1),r.mc("formGroup",o.form)("breakpoints",r.qc(66,Z)),r.Cb(5),r.Rc(r.hc(7,33,"LABEL.TRIGGER_ORDER_TYPE")),r.Cb(4),r.Sc(" ",r.hc(11,35,"BUTTON.LIMIT_ORDER")," "),r.Cb(3),r.Sc(" ",r.hc(14,37,"BUTTON.MARKET_ORDER")," "),r.Cb(2),r.mc("sbDisabled",!i.displayTooltips)("sbDelay",r.qc(67,Y)),r.Cb(2),r.Sc("",r.hc(18,39,"FORM.QUANTITY"),":"),r.Cb(2),r.mc("step",o.stepSize(i.selectedMarket)),r.Cb(3),r.Sc(" ",i.sizeUnit," "),r.Cb(2),r.mc("ngIf",o.isLimit),r.Cb(3),r.Sc("",r.hc(28,41,"FORM.TRIGGER_PRICE"),":"),r.Cb(2),r.mc("step",o.tickSize(i.selectedMarket)),r.Cb(2),r.Rc(i.quoteCurrency),r.Cb(3),r.mc("disabled",o.reduceOnlyDisabled),r.Cb(1),r.mc("sbDisabled",!i.displayTooltips)("sbDelay",r.qc(68,X)),r.Cb(1),r.Sc(" ",r.hc(37,43,"BUTTON.REDUCE_ONLY")," "),r.Cb(4),r.Sc(" ",r.hc(41,45,r.hc(42,47,"FORM.TRIGGER_SIGNAL")),": "),r.Cb(5),r.mc("matTooltip",r.hc(46,49,o.triggerTooltipText.last)),r.Cb(2),r.Sc(" ",r.hc(48,51,"BUTTON.LAST")," "),r.Cb(3),r.mc("matTooltip",r.hc(51,53,o.triggerTooltipText.mark)),r.Cb(2),r.Sc(" ",r.hc(53,55,"BUTTON.MARK")," "),r.Cb(3),r.mc("matTooltip",r.hc(56,57,o.triggerTooltipText.spot)),r.Cb(2),r.Sc(" ",r.hc(58,59,"BUTTON.INDEX")," "),r.Cb(2),r.mc("selectedMarket",i.selectedMarket)("selectedTicker",i.selectedTicker)("initialMargin",i.initialMargin)("wallet",i.wallet)("isTrigger",!0)("form",o.form),r.Cb(3),r.mc("disabled",o.form.invalid||o.buttonDisabled(o.side,i.selectedTicker)),r.Cb(1),r.Sc(" ",r.hc(64,61,r.ic(65,63,"LABEL.PLACE_ORDER",r.rc(69,J,o.side)))," ")}}var et=function(t,e,n,i,r,o,a,s,c){return{selectedMarket:t,selectedTicker:e,displayTooltips:n,baseCurrency:i,quoteCurrency:r,wallet:o,initialMargin:a,userData:s,sizeUnit:c}},nt=x()("trace:app:trigger-order-form"),it=function(){var t=function(){function t(e,n,i){C(this,t),this.formBuilder=e,this.store=n,this.trade=i,this.selectedMarket$=this.store.pipe(Object(a.m)(s.n)),this.selectedTicker$=this.store.pipe(Object(a.m)(u.p)),this.displayTooltips$=this.store.pipe(Object(a.m)(c.y)),this.baseCurrency$=this.store.pipe(Object(a.m)(s.s)),this.quoteCurrency$=this.store.pipe(Object(a.m)(s.u)),this.userSelectedFuturesWallet$=this.store.pipe(Object(a.m)(l.n)),this.initialMargin$=this.store.pipe(Object(a.m)(d.d)),this.userSignedIn$=this.store.pipe(Object(a.m)(c.m)),this.userData$=this.store.pipe(Object(a.m)(c.a)),this.sizeUnit$=this.store.pipe(Object(a.m)(I.n)),this.refreshOptions=new r.o,this.blurFieldEsc=function(t){return Object(A.a)(t)}}return w(t,[{key:"ngOnInit",value:function(){var t=this;this.buildForm(),this.selectedMarket$.pipe(Object(f.a)(1),Object(g.b)(this)).subscribe((function(e){var n,i;null===(n=t.form.get("stopPrice"))||void 0===n||n.setValue(0),null===(i=t.form.get("limitPrice"))||void 0===i||i.setValue(0)})),this.trade.orderFormPriceUpdated$.pipe(Object(p.a)(this.selectedMarket$),Object(b.a)((function(t){var e=m(t,2),n=e[0],i=e[1];return!!n&&!!i})),Object(g.b)(this)).subscribe((function(e){var n,i=m(e,2),r=i[0],o=i[1],a=Object(v.I)(o.tickSize)(r);null===(n=t.form.get("limitPrice"))||void 0===n||n.setValue(a)})),this.trade.orderFormQuantityUpdated$.pipe(Object(y.g)(),Object(g.b)(this)).subscribe((function(e){var n;null===(n=t.form.get("size"))||void 0===n||n.setValue(e)}))}},{key:"buildForm",value:function(){var t,e,n="stop"===this.triggerType||"take_profit"===this.triggerType||(null===(t=this.options)||void 0===t?void 0:t.reduceOnly),i=(null===(e=this.options)||void 0===e?void 0:e.triggerSignal)||"mark",r=new o.e(this.side,[o.x.required]),a=new o.e(0,[o.x.required,o.x.min(1e-9)]),s=new o.e(n,[o.x.required]);this.form=this.formBuilder.group({type:["market",[o.x.required]],side:r,size:a,stopPrice:[0,[o.x.required,o.x.min(1e-9)]],reduceOnly:s,triggerSignal:[i,[o.x.required]]}),this.watchFormOptions()}},{key:"submitOrder",value:function(t,e){var n=this.isLimit?this.form.value.limitPrice:void 0,i={side:this.side,symbol:t.symbol.toUpperCase(),orderType:"trigger_entry"===this.triggerType?"stop":this.triggerType,size:this.form.value.size,reduceOnly:this.form.value.reduceOnly,triggerSignal:this.form.value.triggerSignal,limitPrice:n,stopPrice:this.form.value.stopPrice};this.store.dispatch(e.requireOrderConfirmation?Object(O.g)({name:"order-confirmation",inputs:{order:i,instrument:t}}):Object(_.o)(i))}},{key:"toggleLimitControl",value:function(){if(this.form.get("limitPrice"))this.form.removeControl("limitPrice");else{var t=this.form&&this.form.get("limitPrice")?this.form.get("limitPrice").value:0,e=new o.e(t,[o.x.required,o.x.min(1e-9)]);this.form.addControl("limitPrice",e)}}},{key:"watchFormOptions",value:function(){var t=this;this.form.valueChanges.subscribe((function(e){var n=Object.assign({},t.options);k.Maybe.fromNull(e.triggerSignal).forEach((function(t){return n.triggerSignal=t})),k.Maybe.fromNull(e.orderTypeOverride).forEach((function(t){return n.orderTypeOverride=t})),nt("saving form options",n),Object(T.c)(S.j,n),t.refreshOptions.emit()}))}},{key:"onSizeFocus",value:function(){var t=this.form.get("size");0===t.value&&t.setValue("")}},{key:"tickSize",value:function(t){return t?t.tickSize:1}},{key:"stepSize",value:function(t){return t?1/Math.pow(10,t.contractValueTradePrecision):1}},{key:"buttonDisabled",value:function(t,e){var n={last:Object(P.j)(e),mark:e.markPrice,spot:e.index},i=this.form.get("stopPrice").value,r=n[this.form.get("triggerSignal").value];return"stop"===this.triggerType||"trigger_entry"===this.triggerType?"buy"===t?ir:"take_profit"===this.triggerType&&("buy"===t?i>r:i0&&void 0!==arguments[0]?arguments[0]:l;return function(e){return e.lift(new s(t))}}var s=function(){function t(e){C(this,t),this.errorFactory=e}return w(t,[{key:"call",value:function(t,e){return e.subscribe(new u(t,this.errorFactory))}}]),t}(),u=function(t){a(n,t);var e=c(n);function n(t,i){var r;return C(this,n),(r=e.call(this,t)).errorFactory=i,r.hasValue=!1,r}return w(n,[{key:"_next",value:function(t){this.hasValue=!0,this.destination.next(t)}},{key:"_complete",value:function(){if(this.hasValue)return this.destination.complete();var t;try{t=this.errorFactory()}catch(e){t=e}this.destination.error(t)}}]),n}(r.a);function l(){return new i.a}},fhVT:function(t,e,n){var i=n("67SP"),r=n("JgBV");function o(t){this.mode=r.BYTE,this.data=new i(t)}o.getBitsLength=function(t){return 8*t},o.prototype.getLength=function(){return this.data.length},o.prototype.getBitsLength=function(){return o.getBitsLength(this.data.length)},o.prototype.write=function(t){for(var e=0,n=this.data.length;e1&&"number"==typeof e[e.length-1]&&(s=e.pop())):"number"==typeof u&&(s=e.pop()),null===c&&1===e.length&&e[0]instanceof i.a?e[0]:Object(o.a)(s)(Object(a.a)(e,c))}},gBlb:function(t,e,n){"use strict";function i(t){return t&&"function"==typeof t.schedule}n.d(e,"a",(function(){return i}))},gCmX:function(t,e,n){"use strict";n.d(e,"a",(function(){return h})),n.d(e,"b",(function(){return g})),n.d(e,"c",(function(){return v})),n.d(e,"d",(function(){return y}));var i=n("IdLP"),r=n("KTx3"),o={error:"cordova_not_available"},a={error:"plugin_not_installed"};function s(t){if("undefined"!=typeof window&&window.angular){var e=window.document,n=window.angular.element(e.querySelector("[ng-app]")||e.body).injector();if(n)return n.get("$q")((function(e,n){t(e,n)}));console.warn("Angular 1 was detected but $q couldn't be retrieved. This is usually when the app is not bootstrapped on the html or body tag. Falling back to native promises which won't trigger an automatic digest when promises resolve.")}return function(){if(Promise)return new Promise((function(e,n){t(e,n)}));console.error("No Promise support or polyfill found. To enable Ionic Native support, please add the es6-promise polyfill before this script, or run with a library like Angular or on a recent browser.")}()}function c(t,e,n,i){var r,o;void 0===i&&(i={});var a=s((function(a,s){r=i.destruct?p(t,e,n,i,(function(){for(var t=[],e=0;et.length?t[e.successIndex]=n:t.splice(e.successIndex,0,n)},a=function(){e.errorIndex>t.length?t[e.errorIndex]=i:t.splice(e.errorIndex,0,i)};e.successIndex>e.errorIndex?(a(),o()):(o(),a())}else t.push(n),t.push(i);return t}function p(t,e,n,i,r,o){void 0===i&&(i={}),n=f(n,i,r,o);var a=h(t,e);if(!0===a){var s=g(t.constructor.getPluginRef());return s[e].apply(s,n)}return a}function b(t,e,n,i,r,o){if(void 0===i&&(i={}),n=f(n,i,r,o),function(t,e){return t._objectInstance&&(!e||void 0!==t._objectInstance[e])}(t,e))return t._objectInstance[e].apply(t._objectInstance,n)}function g(t){return"undefined"!=typeof window?m(window,t):null}function m(t,e){for(var n=e.split("."),i=t,r=0;rt.length)&&(e=t.length);for(var n=0,i=new Array(e);n=t.length?{done:!0}:{done:!1,value:t[r++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(i=t[Symbol.iterator]()).next.bind(i)}var i=function(t){var e={exports:{}};return function(t){t.exports={defaults:{baseUrl:null,breaks:!1,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartLists:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1},getDefaults:function(){return{baseUrl:null,breaks:!1,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartLists:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1}},changeDefaults:function(e){t.exports.defaults=e}}}(e),e.exports}(),r=/[&<>"']/,o=/[&<>"']/g,a=/[<>"']|&(?!#?\w+;)/,s=/[<>"']|&(?!#?\w+;)/g,c={"&":"&","<":"<",">":">",'"':""","'":"'"},u=function(t){return c[t]},l=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi;function d(t){return t.replace(l,(function(t,e){return"colon"===(e=e.toLowerCase())?":":"#"===e.charAt(0)?"x"===e.charAt(1)?String.fromCharCode(parseInt(e.substring(2),16)):String.fromCharCode(+e.substring(1)):""}))}var h=/(^|[^\[])\^/g,f=/[^\w:]/g,p=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i,b={},g=/^[^:]+:\/*[^/]*$/,m=/^([^:]+:)[\s\S]*$/,v=/^([^:]+:\/*[^/]*)[\s\S]*$/;function y(t,e,n){var i=t.length;if(0===i)return"";for(var r=0;r=0&&"\\"===n[r];)i=!i;return i?"|":" |"})).split(/ \|/),i=0;if(n.length>e)n.splice(e);else for(;n.length1?{type:"space",raw:e[0]}:{raw:"\n"}},e.code=function(t,e){var n=this.rules.block.code.exec(t);if(n){var i=e[e.length-1];if(i&&"paragraph"===i.type)return{raw:n[0],text:n[0].trimRight()};var r=n[0].replace(/^ {1,4}/gm,"");return{type:"code",raw:n[0],codeBlockStyle:"indented",text:this.options.pedantic?r:C(r,"\n")}}},e.fences=function(t){var e=this.rules.block.fences.exec(t);if(e){var n=e[0],i=function(t,e){var n=t.match(/^(\s+)(?:```)/);if(null===n)return e;var i=n[1];return e.split("\n").map((function(t){var e=t.match(/^\s+/);return null===e?t:e[0].length>=i.length?t.slice(i.length):t})).join("\n")}(n,e[3]||"");return{type:"code",raw:n,lang:e[2]?e[2].trim():e[2],text:i}}},e.heading=function(t){var e=this.rules.block.heading.exec(t);if(e){var n=e[2].trim();if(/#$/.test(n)){var i=C(n,"#");this.options.pedantic?n=i.trim():i&&!/ $/.test(i)||(n=i.trim())}return{type:"heading",raw:e[0],depth:e[1].length,text:n}}},e.nptable=function(t){var e=this.rules.block.nptable.exec(t);if(e){var n={type:"table",header:T(e[1].replace(/^ *| *\| *$/g,"")),align:e[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:e[3]?e[3].replace(/\n$/,"").split("\n"):[],raw:e[0]};if(n.header.length===n.align.length){var i,r=n.align.length;for(i=0;i ?/gm,"");return{type:"blockquote",raw:e[0],text:n}}},e.list=function(t){var e=this.rules.block.list.exec(t);if(e){var n,i,r,o,a,s,c,u,l=e[0],d=e[2],h=d.length>1,f={type:"list",raw:l,ordered:h,start:h?+d.slice(0,-1):"",loose:!1,items:[]},p=e[0].match(this.rules.block.item),b=!1,g=p.length;r=this.rules.block.listItemStart.exec(p[0]);for(var m=0;mr[1].length:o[1].length>r[0].length||o[1].length>3){p.splice(m,2,p[m]+"\n"+p[m+1]),m--,g--;continue}(!this.options.pedantic||this.options.smartLists?o[2][o[2].length-1]!==d[d.length-1]:h===(1===o[2].length))&&(a=p.slice(m+1).join("\n"),f.raw=f.raw.substring(0,f.raw.length-a.length),m=g-1),r=o}i=n.length,~(n=n.replace(/^ *([*+-]|\d+[.)]) ?/,"")).indexOf("\n ")&&(i-=n.length,n=n.replace(this.options.pedantic?/^ {1,4}/gm:new RegExp("^ {1,"+i+"}","gm"),"")),s=b||/\n\n(?!\s*$)/.test(n),m!==g-1&&(b="\n"===n.charAt(n.length-1),s||(s=b)),s&&(f.loose=!0),this.options.gfm&&(u=void 0,(c=/^\[[ xX]\] /.test(n))&&(u=" "!==n[1],n=n.replace(/^\[[ xX]\] +/,""))),f.items.push({type:"list_item",raw:l,task:c,checked:u,loose:s,text:n})}return f}},e.html=function(t){var e=this.rules.block.html.exec(t);if(e)return{type:this.options.sanitize?"paragraph":"html",raw:e[0],pre:!this.options.sanitizer&&("pre"===e[1]||"script"===e[1]||"style"===e[1]),text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(e[0]):S(e[0]):e[0]}},e.def=function(t){var e=this.rules.block.def.exec(t);if(e)return e[3]&&(e[3]=e[3].substring(1,e[3].length-1)),{tag:e[1].toLowerCase().replace(/\s+/g," "),raw:e[0],href:e[2],title:e[3]}},e.table=function(t){var e=this.rules.block.table.exec(t);if(e){var n={type:"table",header:T(e[1].replace(/^ *| *\| *$/g,"")),align:e[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:e[3]?e[3].replace(/\n$/,"").split("\n"):[]};if(n.header.length===n.align.length){n.raw=e[0];var i,r=n.align.length;for(i=0;i/i.test(i[0])&&(e=!1),!n&&/^<(pre|code|kbd|script)(\s|>)/i.test(i[0])?n=!0:n&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(i[0])&&(n=!1),{type:this.options.sanitize?"text":"html",raw:i[0],inLink:e,inRawBlock:n,text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(i[0]):S(i[0]):i[0]}},e.link=function(t){var e=this.rules.inline.link.exec(t);if(e){var n=e[2].trim();if(!this.options.pedantic&&/^$/.test(n))return;var i=C(n.slice(0,-1),"\\");if((n.length-i.length)%2==0)return}else{var r=function(t,e){if(-1===t.indexOf(e[1]))return-1;for(var n=t.length,i=0,r=0;r-1){var o=(0===e[0].indexOf("!")?5:4)+e[1].length+r;e[2]=e[2].substring(0,r),e[0]=e[0].substring(0,o).trim(),e[3]=""}}var a=e[2],s="";if(this.options.pedantic){var c=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(a);c&&(a=c[1],s=c[3])}else s=e[3]?e[3].slice(1,-1):"";return a=a.trim(),/^$/.test(n)?a.slice(1):a.slice(1,-1)),E(e,{href:a?a.replace(this.rules.inline._escapes,"$1"):a,title:s?s.replace(this.rules.inline._escapes,"$1"):s},e[0])}},e.reflink=function(t,e){var n;if((n=this.rules.inline.reflink.exec(t))||(n=this.rules.inline.nolink.exec(t))){var i=(n[2]||n[1]).replace(/\s+/g," ");if(!(i=e[i.toLowerCase()])||!i.href){var r=n[0].charAt(0);return{type:"text",raw:r,text:r}}return E(n,i,n[0])}},e.strong=function(t,e,n){void 0===n&&(n="");var i=this.rules.inline.strong.start.exec(t);if(i&&(!i[1]||i[1]&&(""===n||this.rules.inline.punctuation.exec(n)))){e=e.slice(-1*t.length);var r,o="**"===i[0]?this.rules.inline.strong.endAst:this.rules.inline.strong.endUnd;for(o.lastIndex=0;null!=(i=o.exec(e));)if(r=this.rules.inline.strong.middle.exec(e.slice(0,i.index+3)))return{type:"strong",raw:t.slice(0,r[0].length),text:t.slice(2,r[0].length-2)}}},e.em=function(t,e,n){void 0===n&&(n="");var i=this.rules.inline.em.start.exec(t);if(i&&(!i[1]||i[1]&&(""===n||this.rules.inline.punctuation.exec(n)))){e=e.slice(-1*t.length);var r,o="*"===i[0]?this.rules.inline.em.endAst:this.rules.inline.em.endUnd;for(o.lastIndex=0;null!=(i=o.exec(e));)if(r=this.rules.inline.em.middle.exec(e.slice(0,i.index+2)))return{type:"em",raw:t.slice(0,r[0].length),text:t.slice(1,r[0].length-1)}}},e.codespan=function(t){var e=this.rules.inline.code.exec(t);if(e){var n=e[2].replace(/\n/g," "),i=/[^ ]/.test(n),r=/^ /.test(n)&&/ $/.test(n);return i&&r&&(n=n.substring(1,n.length-1)),n=S(n,!0),{type:"codespan",raw:e[0],text:n}}},e.br=function(t){var e=this.rules.inline.br.exec(t);if(e)return{type:"br",raw:e[0]}},e.del=function(t){var e=this.rules.inline.del.exec(t);if(e)return{type:"del",raw:e[0],text:e[2]}},e.autolink=function(t,e){var n,i,r=this.rules.inline.autolink.exec(t);if(r)return i="@"===r[2]?"mailto:"+(n=S(this.options.mangle?e(r[1]):r[1])):n=S(r[1]),{type:"link",raw:r[0],text:n,href:i,tokens:[{type:"text",raw:n,text:n}]}},e.url=function(t,e){var n;if(n=this.rules.inline.url.exec(t)){var i,r;if("@"===n[2])r="mailto:"+(i=S(this.options.mangle?e(n[0]):n[0]));else{var o;do{o=n[0],n[0]=this.rules.inline._backpedal.exec(n[0])[0]}while(o!==n[0]);i=S(n[0]),r="www."===n[1]?"http://"+i:i}return{type:"link",raw:n[0],text:i,href:r,tokens:[{type:"text",raw:i,text:i}]}}},e.inlineText=function(t,e,n){var i,r=this.rules.inline.text.exec(t);if(r)return i=e?this.options.sanitize?this.options.sanitizer?this.options.sanitizer(r[0]):S(r[0]):r[0]:S(this.options.smartypants?n(r[0]):r[0]),{type:"text",raw:r[0],text:i}},t}(),P={exec:function(){}},A=function(t,e){t=t.source||t,e=e||"";var n={replace:function(e,i){return i=(i=i.source||i).replace(h,"$1"),t=t.replace(e,i),n},getRegex:function(){return new RegExp(t,e)}};return n},I=k,M={newline:/^(?: *(?:\n|$))+/,code:/^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,fences:/^ {0,3}(`{3,}(?=[^`\n]*\n)|~{3,})([^\n]*)\n(?:|([\s\S]*?)\n)(?: {0,3}\1[~`]* *(?:\n+|$)|$)/,hr:/^ {0,3}((?:- *){3,}|(?:_ *){3,}|(?:\* *){3,})(?:\n+|$)/,heading:/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( {0,3})(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?! {0,3}bull )\n*|\s*$)/,html:"^ {0,3}(?:<(script|pre|style)[\\s>][\\s\\S]*?(?:\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|\\n*|$)|\\n*|$)|?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:\\n{2,}|$)|<(?!script|pre|style)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:\\n{2,}|$)|(?!script|pre|style)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:\\n{2,}|$))",def:/^ {0,3}\[(label)\]: *\n? *([^\s>]+)>?(?:(?: +\n? *| *\n *)(title))? *(?:\n+|$)/,nptable:P,table:P,lheading:/^([^\n]+)\n {0,3}(=+|-+) *(?:\n+|$)/,_paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html| +\n)[^\n]+)*)/,text:/^[^\n]+/,_label:/(?!\s*\])(?:\\[\[\]]|[^\[\]])+/,_title:/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/};M.def=A(M.def).replace("label",M._label).replace("title",M._title).getRegex(),M.bullet=/(?:[*+-]|\d{1,9}[.)])/,M.item=/^( *)(bull) ?[^\n]*(?:\n(?! *bull ?)[^\n]*)*/,M.item=A(M.item,"gm").replace(/bull/g,M.bullet).getRegex(),M.listItemStart=A(/^( *)(bull)/).replace("bull",M.bullet).getRegex(),M.list=A(M.list).replace(/bull/g,M.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+M.def.source+")").getRegex(),M._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",M._comment=/|$)/,M.html=A(M.html,"i").replace("comment",M._comment).replace("tag",M._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),M.paragraph=A(M._paragraph).replace("hr",M.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|!--)").replace("tag",M._tag).getRegex(),M.blockquote=A(M.blockquote).replace("paragraph",M.paragraph).getRegex(),M.normal=I({},M),M.gfm=I({},M.normal,{nptable:"^ *([^|\\n ].*\\|.*)\\n {0,3}([-:]+ *\\|[-| :]*)(?:\\n((?:(?!\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)",table:"^ *\\|(.+)\\n {0,3}\\|?( *[-:]+[-| :]*)(?:\\n *((?:(?!\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"}),M.gfm.nptable=A(M.gfm.nptable).replace("hr",M.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|!--)").replace("tag",M._tag).getRegex(),M.gfm.table=A(M.gfm.table).replace("hr",M.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|!--)").replace("tag",M._tag).getRegex(),M.pedantic=I({},M.normal,{html:A("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?\\1> *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment",M._comment).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:P,paragraph:A(M.normal._paragraph).replace("hr",M.hr).replace("heading"," *#{1,6} *[^\n]").replace("lheading",M.lheading).replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").getRegex()});var D={escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,autolink:/^<(scheme:[^\s\x00-\x1f<>]*|email)>/,url:P,tag:"^comment|^[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^",link:/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,reflink:/^!?\[(label)\]\[(?!\s*\])((?:\\[\[\]]?|[^\[\]\\])+)\]/,nolink:/^!?\[(?!\s*\])((?:\[[^\[\]]*\]|\\[\[\]]|[^\[\]])*)\](?:\[\])?/,reflinkSearch:"reflink|nolink(?!\\()",strong:{start:/^(?:(\*\*(?=[*punctuation]))|\*\*)(?![\s])|__/,middle:/^\*\*(?:(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)|\*(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)*?\*)+?\*\*$|^__(?![\s])((?:(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)|_(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)*?_)+?)__$/,endAst:/[^punctuation\s]\*\*(?!\*)|[punctuation]\*\*(?!\*)(?:(?=[punctuation_\s]|$))/,endUnd:/[^\s]__(?!_)(?:(?=[punctuation*\s])|$)/},em:{start:/^(?:(\*(?=[punctuation]))|\*)(?![*\s])|_/,middle:/^\*(?:(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)|\*(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)*?\*)+?\*$|^_(?![_\s])(?:(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)|_(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)*?_)+?_$/,endAst:/[^punctuation\s]\*(?!\*)|[punctuation]\*(?!\*)(?:(?=[punctuation_\s]|$))/,endUnd:/[^\s]_(?!_)(?:(?=[punctuation*\s])|$)/},code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,br:/^( {2,}|\\)\n(?!\s*$)/,del:P,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\?@\\[\\]`^{|}~"};D.punctuation=A(D.punctuation).replace(/punctuation/g,D._punctuation).getRegex(),D._blockSkip="\\[[^\\]]*?\\]\\([^\\)]*?\\)|`[^`]*?`|<[^>]*?>",D._overlapSkip="__[^_]*?__|\\*\\*\\[^\\*\\]*?\\*\\*",D._comment=A(M._comment).replace("(?:--\x3e|$)","--\x3e").getRegex(),D.em.start=A(D.em.start).replace(/punctuation/g,D._punctuation).getRegex(),D.em.middle=A(D.em.middle).replace(/punctuation/g,D._punctuation).replace(/overlapSkip/g,D._overlapSkip).getRegex(),D.em.endAst=A(D.em.endAst,"g").replace(/punctuation/g,D._punctuation).getRegex(),D.em.endUnd=A(D.em.endUnd,"g").replace(/punctuation/g,D._punctuation).getRegex(),D.strong.start=A(D.strong.start).replace(/punctuation/g,D._punctuation).getRegex(),D.strong.middle=A(D.strong.middle).replace(/punctuation/g,D._punctuation).replace(/overlapSkip/g,D._overlapSkip).getRegex(),D.strong.endAst=A(D.strong.endAst,"g").replace(/punctuation/g,D._punctuation).getRegex(),D.strong.endUnd=A(D.strong.endUnd,"g").replace(/punctuation/g,D._punctuation).getRegex(),D.blockSkip=A(D._blockSkip,"g").getRegex(),D.overlapSkip=A(D._overlapSkip,"g").getRegex(),D._escapes=/\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g,D._scheme=/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/,D._email=/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/,D.autolink=A(D.autolink).replace("scheme",D._scheme).replace("email",D._email).getRegex(),D._attribute=/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/,D.tag=A(D.tag).replace("comment",D._comment).replace("attribute",D._attribute).getRegex(),D._label=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,D._href=/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/,D._title=/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/,D.link=A(D.link).replace("label",D._label).replace("href",D._href).replace("title",D._title).getRegex(),D.reflink=A(D.reflink).replace("label",D._label).getRegex(),D.reflinkSearch=A(D.reflinkSearch,"g").replace("reflink",D.reflink).replace("nolink",D.nolink).getRegex(),D.normal=I({},D),D.pedantic=I({},D.normal,{strong:{start:/^__|\*\*/,middle:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,endAst:/\*\*(?!\*)/g,endUnd:/__(?!_)/g},em:{start:/^_|\*/,middle:/^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,endAst:/\*(?!\*)/g,endUnd:/_(?!_)/g},link:A(/^!?\[(label)\]\((.*?)\)/).replace("label",D._label).getRegex(),reflink:A(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",D._label).getRegex()}),D.gfm=I({},D.normal,{escape:A(D.escape).replace("])","~|])").getRegex(),_extended_email:/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,url:/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,_backpedal:/(?:[^?!.,:;*_~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\1;)1&e&&(n+=t),e>>=1,t+=t;return n+t};function F(t){return t.replace(/---/g,"\u2014").replace(/--/g,"\u2013").replace(/(^|[-\u2014/(\[{"\s])'/g,"$1\u2018").replace(/'/g,"\u2019").replace(/(^|[-\u2014/(\[{\u2018\s])"/g,"$1\u201c").replace(/"/g,"\u201d").replace(/\.{3}/g,"\u2026")}function B(t){var e,n,i="",r=t.length;for(e=0;e.5&&(n="x"+n.toString(16)),i+=""+n+";";return i}var z=function(){function e(t){this.tokens=[],this.tokens.links=Object.create(null),this.options=t||j,this.options.tokenizer=this.options.tokenizer||new x,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options;var e={block:L.normal,inline:N.normal};this.options.pedantic?(e.block=L.pedantic,e.inline=N.pedantic):this.options.gfm&&(e.block=L.gfm,e.inline=this.options.breaks?N.breaks:N.gfm),this.tokenizer.rules=e}e.lex=function(t,n){return new e(n).lex(t)},e.lexInline=function(t,n){return new e(n).inlineTokens(t)};var n,i,r=e.prototype;return r.lex=function(t){return t=t.replace(/\r\n|\r/g,"\n").replace(/\t/g," "),this.blockTokens(t,this.tokens,!0),this.inline(this.tokens),this.tokens},r.blockTokens=function(t,e,n){var i,r,o,a;for(void 0===e&&(e=[]),void 0===n&&(n=!0),this.options.pedantic&&(t=t.replace(/^ +$/gm,""));t;)if(i=this.tokenizer.space(t))t=t.substring(i.raw.length),i.type&&e.push(i);else if(i=this.tokenizer.code(t,e))t=t.substring(i.raw.length),i.type?e.push(i):((a=e[e.length-1]).raw+="\n"+i.raw,a.text+="\n"+i.text);else if(i=this.tokenizer.fences(t))t=t.substring(i.raw.length),e.push(i);else if(i=this.tokenizer.heading(t))t=t.substring(i.raw.length),e.push(i);else if(i=this.tokenizer.nptable(t))t=t.substring(i.raw.length),e.push(i);else if(i=this.tokenizer.hr(t))t=t.substring(i.raw.length),e.push(i);else if(i=this.tokenizer.blockquote(t))t=t.substring(i.raw.length),i.tokens=this.blockTokens(i.text,[],n),e.push(i);else if(i=this.tokenizer.list(t)){for(t=t.substring(i.raw.length),o=i.items.length,r=0;r0)for(;null!=(o=this.tokenizer.rules.inline.reflinkSearch.exec(c));)u.includes(o[0].slice(o[0].lastIndexOf("[")+1,-1))&&(c=c.slice(0,o.index)+"["+U("a",o[0].length-2)+"]"+c.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;null!=(o=this.tokenizer.rules.inline.blockSkip.exec(c));)c=c.slice(0,o.index)+"["+U("a",o[0].length-2)+"]"+c.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;t;)if(a||(s=""),a=!1,r=this.tokenizer.escape(t))t=t.substring(r.raw.length),e.push(r);else if(r=this.tokenizer.tag(t,n,i))t=t.substring(r.raw.length),n=r.inLink,i=r.inRawBlock,e.push(r);else if(r=this.tokenizer.link(t))t=t.substring(r.raw.length),"link"===r.type&&(r.tokens=this.inlineTokens(r.text,[],!0,i)),e.push(r);else if(r=this.tokenizer.reflink(t,this.tokens.links))t=t.substring(r.raw.length),"link"===r.type&&(r.tokens=this.inlineTokens(r.text,[],!0,i)),e.push(r);else if(r=this.tokenizer.strong(t,c,s))t=t.substring(r.raw.length),r.tokens=this.inlineTokens(r.text,[],n,i),e.push(r);else if(r=this.tokenizer.em(t,c,s))t=t.substring(r.raw.length),r.tokens=this.inlineTokens(r.text,[],n,i),e.push(r);else if(r=this.tokenizer.codespan(t))t=t.substring(r.raw.length),e.push(r);else if(r=this.tokenizer.br(t))t=t.substring(r.raw.length),e.push(r);else if(r=this.tokenizer.del(t))t=t.substring(r.raw.length),r.tokens=this.inlineTokens(r.text,[],n,i),e.push(r);else if(r=this.tokenizer.autolink(t,B))t=t.substring(r.raw.length),e.push(r);else if(n||!(r=this.tokenizer.url(t,B))){if(r=this.tokenizer.inlineText(t,i,F))t=t.substring(r.raw.length),s=r.raw.slice(-1),a=!0,e.push(r);else if(t){var l="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(l);break}throw new Error(l)}}else t=t.substring(r.raw.length),e.push(r);return e},n=e,(i=[{key:"rules",get:function(){return{block:L,inline:N}}}])&&t(n,i),e}(),V=i.defaults,H=function(t,e,n){if(t){var i;try{i=decodeURIComponent(d(n)).replace(f,"").toLowerCase()}catch(r){return null}if(0===i.indexOf("javascript:")||0===i.indexOf("vbscript:")||0===i.indexOf("data:"))return null}e&&!p.test(n)&&(n=function(t,e){b[" "+t]||(b[" "+t]=g.test(t)?t+"/":y(t,"/",!0));var n=-1===(t=b[" "+t]).indexOf(":");return"//"===e.substring(0,2)?n?e:t.replace(m,"$1")+e:"/"===e.charAt(0)?n?e:t.replace(v,"$1")+e:t+e}(e,n));try{n=encodeURI(n).replace(/%25/g,"%")}catch(r){return null}return n},q=_,$=function(){function t(t){this.options=t||V}var e=t.prototype;return e.code=function(t,e,n){var i=(e||"").match(/\S*/)[0];if(this.options.highlight){var r=this.options.highlight(t,i);null!=r&&r!==t&&(n=!0,t=r)}return t=t.replace(/\n$/,"")+"\n",i?''+(n?t:q(t,!0))+"
\n":""+(n?t:q(t,!0))+"
\n"},e.blockquote=function(t){return"\n"+t+"
\n"},e.html=function(t){return t},e.heading=function(t,e,n,i){return this.options.headerIds?"\n":""+t+"\n"},e.hr=function(){return this.options.xhtml?"
\n":"
\n"},e.list=function(t,e,n){var i=e?"ol":"ul";return"<"+i+(e&&1!==n?' start="'+n+'"':"")+">\n"+t+""+i+">\n"},e.listitem=function(t){return""+t+"\n"},e.checkbox=function(t){return" "},e.paragraph=function(t){return""+t+"
\n"},e.table=function(t,e){return e&&(e=""+e+""),"\n"},e.tablerow=function(t){return"\n"+t+"
\n"},e.tablecell=function(t,e){var n=e.header?"th":"td";return(e.align?"<"+n+' align="'+e.align+'">':"<"+n+">")+t+""+n+">\n"},e.strong=function(t){return""+t+""},e.em=function(t){return""+t+""},e.codespan=function(t){return""+t+"
"},e.br=function(){return this.options.xhtml?"
":"
"},e.del=function(t){return""+t+""},e.link=function(t,e,n){if(null===(t=H(this.options.sanitize,this.options.baseUrl,t)))return n;var i='"+n+""},e.image=function(t,e,n){if(null===(t=H(this.options.sanitize,this.options.baseUrl,t)))return n;var i='
":">")},e.text=function(t){return t},t}(),Q=function(){function t(){}var e=t.prototype;return e.strong=function(t){return t},e.em=function(t){return t},e.codespan=function(t){return t},e.del=function(t){return t},e.html=function(t){return t},e.text=function(t){return t},e.link=function(t,e,n){return""+n},e.image=function(t,e,n){return""+n},e.br=function(){return""},t}(),W=function(){function t(){this.seen={}}var e=t.prototype;return e.serialize=function(t){return t.toLowerCase().trim().replace(/<[!\/a-z].*?>/gi,"").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g,"").replace(/\s/g,"-")},e.getNextSafeSlug=function(t,e){var n=t,i=0;if(this.seen.hasOwnProperty(n)){i=this.seen[t];do{n=t+"-"+ ++i}while(this.seen.hasOwnProperty(n))}return e||(this.seen[t]=i,this.seen[n]=0),n},e.slug=function(t,e){void 0===e&&(e={});var n=this.serialize(t);return this.getNextSafeSlug(n,e.dryrun)},t}(),G=i.defaults,Y=O,K=function(){function t(t){this.options=t||G,this.options.renderer=this.options.renderer||new $,this.renderer=this.options.renderer,this.renderer.options=this.options,this.textRenderer=new Q,this.slugger=new W}t.parse=function(e,n){return new t(n).parse(e)},t.parseInline=function(e,n){return new t(n).parseInline(e)};var e=t.prototype;return e.parse=function(t,e){void 0===e&&(e=!0);var n,i,r,o,a,s,c,u,l,d,h,f,p,b,g,m,v,y,_="",O=t.length;for(n=0;n0&&"text"===g.tokens[0].type?(g.tokens[0].text=y+" "+g.tokens[0].text,g.tokens[0].tokens&&g.tokens[0].tokens.length>0&&"text"===g.tokens[0].tokens[0].type&&(g.tokens[0].tokens[0].text=y+" "+g.tokens[0].tokens[0].text)):g.tokens.unshift({type:"text",text:y}):b+=y),b+=this.parse(g.tokens,p),l+=this.renderer.listitem(b,v,m);_+=this.renderer.list(l,h,f);continue;case"html":_+=this.renderer.html(d.text);continue;case"paragraph":_+=this.renderer.paragraph(this.parseInline(d.tokens));continue;case"text":for(l=d.tokens?this.parseInline(d.tokens):d.text;n+1An error occurred:
"+J(c.message+"",!0)+"
";throw c}}return it.options=it.setOptions=function(t){return Z(it.defaults,t),et(it.defaults),it},it.getDefaults=tt,it.defaults=nt,it.use=function(t){var e=Z({},t);if(t.renderer&&function(){var n=it.defaults.renderer||new $,i=function(e){var i=n[e];n[e]=function(){for(var r=arguments.length,o=new Array(r),a=0;aAn error occurred: