PageSourceSearch

https://www.linaresdelasierra.es/es/.content/AV/extremadura-trigger.component-U75OY7QF.js

js linaresdelasierra.es collected 2026-10-02 17:01:47 UTC 9,341 bytes, 1 lines download raw bytes

1import{e as G,f as K}from"./chunk-4HNAA3QD.js";import{h as q,j as b,k as J}from"./chunk-WQW72BYF.js";import{Ab as U,Cb as u,Db as _,Hc as W,Mb as f,Nb as E,O as L,Ob as M,Ra as w,Sa as y,Sb as j,Tb as C,U as z,Va as r,Y as o,Yb as x,Zb as D,_b as $,ba as S,eb as m,ib as h,j as v,ma as I,mb as l,na as k,nc as N,pc as V,qb as g,rb as B,sb as H,tb as F,ua as P,ub as a,vb as s,wb as c,xc as R,za as A}from"./chunk-6ER5EEDF.js";var d=class t{_storageService=o(G);triggerState=m(this._chatOptionsStateFromStorage);openChat$=new v;constructor(){V(()=>{let e=this.triggerState();this._chatOptionsStateFromStorage=e})}changeState(e){this.triggerState.set(e)}get _chatOptionsStateFromStorage(){return this._storageService.getItemOnStorage("chatOptionsState","closed")}set _chatOptionsStateFromStorage(e){this._storageService.setItemOnStorage(e,"chatOptionsState","closed")}static \u0275fac=function(i){return new(i||t)};static \u0275prov=z({token:t,factory:t.\u0275fac})};function ne(t,e){if(t&1&&(c(0,"img",2),x(1,"fixAssetsDirectory")),t&2){let i=_();l("src",D(1,1,i.chatOptions.buttonIconUrl),y)}}function re(t,e){t&1&&c(0,"div",3)}function ae(t,e){if(t&1&&(c(0,"img",2),x(1,"fixAssetsDirectory")),t&2){let i=_().$implicit;l("src",D(1,1,i.buttonIconUrl),y)}}function oe(t,e){t&1&&c(0,"div",3)}function se(t,e){if(t&1){let i=U();a(0,"li",1),u("click",function(){let p=I(i).$implicit,T=_();return k(T.doAction(p.action))}),h(1,ae,2,3,"img",2)(2,oe,1,0,"div",3),a(3,"a",6),f(4),s()()}if(t&2){let i=e.$implicit;r(),g(i.buttonIconUrl?1:2),r(2),l("href",i.action,y),r(),E(i.buttonText)}}var O=class t{_configLoaderService=o(b);_extremaduraTriggerService=o(d);_config=this._configLoaderService.config;_theme=this._config.triggerVariant;_listOptions=this._theme.listOptions;chatOptions={buttonText:this._listOptions?.chatText||"chat en l\xEDnea",buttonIconUrl:this._listOptions?.chatIconUrl};options=m(this._theme.listOptions?.options||[]);openChat(){this._extremaduraTriggerService.openChat$.next()}doAction(e){location.href=e}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=S({type:t,selectors:[["extremadura-theme-list"]],standalone:!0,features:[C],decls:8,vars:2,consts:[["role","menu",1,"list"],[1,"list__item",3,"click"],[1,"list__item-icon",3,"src"],[1,"list__item-icon"],[1,"list__item-text"],[1,"list__item"],[1,"list__item-text",3,"href"]],template:function(i,n){i&1&&(a(0,"ul",0)(1,"li",1),u("click",function(){return n.openChat()}),h(2,ne,2,3,"img",2)(3,re,1,0,"div",3),a(4,"span",4),f(5),s()(),H(6,se,5,3,"li",5,B),s()),i&2&&(r(2),g(n.chatOptions.buttonIconUrl?2:3),r(3),E(n.chatOptions.buttonText),r(),F(n.options()))},dependencies:[J],styles:[".list[_ngcontent-%COMP%]{background-color:var(--backgroundOptionList, white);--padding-block: .5em;height:calc(100% + var(--padding-block) * 2);list-style-type:none;--logo-size: 2em;margin:0;padding-inline:.5em;padding-block:var(--padding-block);display:flex;flex-direction:column;gap:.5em}.list__item[_ngcontent-%COMP%]{text-decoration:none;padding-inline:1em;padding-block:.5em;border-radius:5px;cursor:pointer;border:1px solid #979797;display:grid;place-content:center;grid-template-columns:var(--logo-size) 1fr;gap:.5em}.list__item-icon[_ngcontent-%COMP%]{width:var(--logo-size);height:var(--logo-size);object-fit:contain;place-self:center}.list__item-text[_ngcontent-%COMP%]{color:var(--headerTextColor);align-self:center;max-width:200px;font-size:var(--step-0)}"]})};var X='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 448 512" fill="var(--fillColor)"><path d="M0 96c0-17.7 14.3-32 32-32h384c17.7 0 32 14.3 32 32s-14.3 32-32 32H32c-17.7 0-32-14.3-32-32zm0 160c0-17.7 14.3-32 32-32h384c17.7 0 32 14.3 32 32s-14.3 32-32 32H32c-17.7 0-32-14.3-32-32zm448 160c0 17.7-14.3 32-32 32H32c-17.7 0-32-14.3-32-32s14.3-32 32-32h384c17.7 0 32 14.3 32 32z"/></svg>',Y='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 448 512" fill="var(--fillColor)"><path d="M201.4 137.4c12.5-12.5 32.8-12.5 45.3 0l160 160c12.5 12.5 12.5 32.8 0 45.3s-32.8 12.5-45.3 0L224 205.3 86.6 342.6c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3l160-160z"/></svg>',Z='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 448 512" fill="var(--fillColor)"><path d="M201.4 374.6c12.5 12.5 32.8 12.5 45.3 0l160-160c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L224 306.7 86.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l160 160z"/></svg>',ee='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 320 512" fill="var(--fillColor)"><path d="M41.4 233.4c-12.5 12.5-12.5 32.8 0 45.3l160 160c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L109.3 256 246.6 118.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-160 160z"/></svg>';function le(t,e){if(t&1&&(a(0,"div",6),f(1),s()),t&2){let i=_();r(),M(" ",i.texts.optionsExpandedText," ")}}function ce(t,e){t&1&&c(0,"extremadura-theme-list")}var te=class t{_elementRef=o(A);_domSanitizer=o(q);triggerInput=m(void 0);_onDestroy=new v;set trigger(e){this._createTrigger(e)}
1dispatch=new P;_extremaduraTriggerService=o(d);_faBars=this._domSanitizer.bypassSecurityTrustHtml(X);_faAngleDown=this._domSanitizer.bypassSecurityTrustHtml(Z);_faAngleLeft=this._domSanitizer.bypassSecurityTrustHtml(ee);_faAngleUp=this._domSanitizer.bypassSecurityTrustHtml(Y);_configLoaderService=o(b);_config=this._configLoaderService.config;_trigger=this._config.triggerVariant;options=this._trigger.listOptions;chatOptionsState=this._extremaduraTriggerService.triggerState;texts=this._trigger.texts;menuIcon=this._computedSwitch({byDefault:this._faBars,onExpanded:this._faBars,onOpen:this._faAngleLeft});expandedIcon=this._computedSwitch({byDefault:this._faAngleUp,onExpanded:this._faAngleDown,onOpen:this._faAngleDown});contentState=this._computedSwitch({byDefault:"visible",onClosed:"hidden"});secondaryTextState=this._computedSwitch({byDefault:!1,onExpanded:!0});themeListState=this._computedSwitch({byDefault:!1,onOpen:!0});changeStateByMenu(){if(!this.options){this._extremaduraTriggerService.openChat$.next();return}let e=this._chatOptionsStateSwitch({byDefault:"open",onOpen:"closed"});this._extremaduraTriggerService.changeState(e)}changeStateByExpanded(){let e=this._chatOptionsStateSwitch({byDefault:"closed",onClosed:"expanded"});this._extremaduraTriggerService.changeState(e)}ngOnDestroy(){this._onDestroy.next()}ngOnInit(){this._extremaduraTriggerService.openChat$.pipe(L(this._onDestroy)).subscribe(()=>{this.dispatch.emit()})}_computedSwitch(e){return N(()=>this._chatOptionsStateSwitch(e))}_chatOptionsStateSwitch(e){let{onOpen:i=e.byDefault,onExpanded:n=e.byDefault,onClosed:p=e.byDefault,byDefault:T}=e;switch(this.chatOptionsState()){case"open":return i;case"expanded":return n;case"closed":return p;default:return T}}_createTrigger(e){this.triggerInput.set(e)}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=S({type:t,selectors:[["ng-component"]],inputs:{trigger:"trigger"},outputs:{dispatch:"dispatch"},standalone:!0,features:[j([d]),C],decls:10,vars:10,consts:[["aria-label","Widget de opciones",1,"chat-widget__extremadura","extremadura-trigger",3,"ngClass"],[1,"extremadura-trigger__header"],["type","menu","aria-label","Abrir men\xFA",1,"icon","icon--primary",3,"click","innerHTML"],[1,"extremadura-trigger__title"],["type","button",1,"icon","icon--primary",3,"click","innerHTML"],[1,"extremadura-trigger__content",3,"ngClass"],[1,"extremadura-trigger__subtitle"]],template:function(i,n){i&1&&(a(0,"section",0),x(1,"addModifier"),a(2,"div",1)(3,"button",2),u("click",function(){return n.changeStateByMenu()}),s(),a(4,"header",3),f(5),s(),a(6,"button",4),u("click",function(){return n.changeStateByExpanded()}),s()(),a(7,"div",5),h(8,le,2,1,"div",6)(9,ce,1,0,"extremadura-theme-list"),s()()),i&2&&(l("ngClass",$(1,7,"extremadura-trigger",n.chatOptionsState())),r(3),l("innerHTML",n.menuIcon(),w),r(2),M(" ",n.texts.optionsHeaderText," "),r(),l("innerHTML",n.expandedIcon(),w),r(),l("ngClass",n.contentState()),r(),g(n.secondaryTextState()?8:-1),r(),g(n.themeListState()?9:-1))},dependencies:[O,K,W,R],styles:[".extremadura-trigger[_ngcontent-%COMP%]{display:grid;grid-template-rows:min-content 1fr;position:fixed;--width: 250px;--padding-inline: 1em;bottom:0;right:0;box-shadow:0 4px 7px #00000080;background-color:var(--mainColor);border-radius:5px 5px 0}.extremadura-trigger[_ngcontent-%COMP%]   .extremadura-trigger__header[_ngcontent-%COMP%]{display:grid;grid-template-columns:min-content 1fr min-content;align-items:center;height:41px;min-width:var(--width);font-size:var(--step-1);padding-inline:var(--padding-inline);gap:1em}.extremadura-trigger[_ngcontent-%COMP%]   .extremadura-trigger__title[_ngcontent-%COMP%]{color:var(--headerTextColor)}.extremadura-trigger[_ngcontent-%COMP%]   .extremadura-trigger__subtitle[_ngcontent-%COMP%]{font-size:21px;color:#fff;font-weight:700;height:119px;text-align:center;display:grid;place-content:center}.extremadura-trigger[_ngcontent-%COMP%]   .extremadura-trigger__content[_ngcontent-%COMP%]{height:max-content}.icon[_ngcontent-%COMP%]{--size: 18px;--fillColor: var(--headerTextColor);width:var(--size);height:var(--size);padding:0;margin:0;border:none;cursor:pointer;outline:none}.icon--primary[_ngcontent-%COMP%]{color:var(--buttonText);background-color:var(--mainColor)}.hidden[_ngcontent-%COMP%]{visibility:hidden!important;display:none!important}"]})};export{te as ExtremaduraTriggerComponent};

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.