1import{d as k}from"./chunk-Z6FYYWWI.js";import"./chunk-5D7U5BG4.js";import{Bd as B,Cd as T,Da as M,i as _,o as x,oc as S,rc as R,u as I}from"./chunk-CYIHQ5K2.js";import{Ca as p,Cc as b,Dc as h,Dd as s,Ec as v,Ed as u,Ga as n,Mb as m,Mc as y,Pa as a,Qa as d,Qc as q,Sc as C,a as c,dc as l,ec as f,fd as D,hd as Q,ic as g,va as r}from"./chunk-BMLVPP3A.js";import"./chunk-2GKL4NPU.js";function w(t,j){if(t&1){let o=y();h(0,"button",2,0),q("click",function(){a(o);let i=C();return d(i.goToQuoteDetails())}),D(2),s(3,"cxTranslate"),v()}t&2&&(m(2),Q(" ",u(3,1,"quote.commons.requestQuote"),` 2`))}var F=(()=>{class t{constructor(){this.quoteFacade=n(k),this.routingService=n(S),this.authService=n(R),this.subscription=new c,this.isLoggedIn$=this.authService.isUserLoggedIn()}goToQuoteDetails(){this.subscription.add(this.quoteFacade.createQuote({}).pipe(r(o=>{this.routingService.go({cxRoute:"quoteDetails",params:{quoteId:o.code}})})).subscribe())}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(e){return new(e||t)}}static{this.\u0275cmp=l({type:t,selectors:[["cx-quote-request-button"]],decls:2,vars:3,consts:[["element",""],["type","button","class","btn btn-block btn-secondary",3,"click",4,"ngIf"],["type","button",1,"btn","btn-block","btn-secondary",3,"click"]],template:function(e,i){e&1&&(g(0,w,4,3,"button",1),s(1,"async")),e&2&&b("ngIf",u(1,1,i.isLoggedIn$))},dependencies:[_,x,B],encapsulation:2,changeDetection:0})}}return t})(),G=(()=>{class t{static{this.\u0275fac=function(e){return new(e||t)}}static{this.\u0275mod=f({type:t})}static{this.\u0275inj=p({providers:[M({cmsComponents:{QuoteRequestComponent:{component:F}}})],imports:[I,T]})}}return t})();export{F as QuoteRequestButtonComponent,G as QuoteRequestButtonModule};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.