1let newHeroClass=null;!function(){class t extends HTMLElement{static tagName="new-menufy-hero";static heroImageAltTextAttributeName="hero-alt";static locationIdAttributeName="location-id";static observedAttributes=[this.locationIdAttributeName,this.heroImageAltTextAttributeName];static elementId="hero-root";static heroContainerElementId="hero-container";constructor(){super(),this.locationId=null,this.locationData=null,this.heroUrl=null,this.settingsLoaded=null,this.element=null}createTemplates(){}connectedCallback(){const e=this.attachShadow({mode:"open"});this.createTemplates();const a=`<div id="${t.elementId}"></div>`,i=document.createElement("template");i.innerHTML=a;const o=i.content.cloneNode(!0);e.appendChild(o),this.element=e.querySelector(`#${t.elementId}`),PresentationService.prependStylesToNewComponent(e),this.tryUpdateLocationData(),this.tryUpdateSettingsData(),this.tryRender(),document.addEventListener(LocationService.locationLoadedEventName,this.onLocationData.bind(this)),document.addEventListener(SettingsService.settingsLoadedEventName,this.onSettingsData.bind(this))}disconnectedCallback(){}adoptedCallback(){}attributeChangedCallback(e,a,i){e==t.locationIdAttributeName&&(this.locationId=i)}onSettingsData(t){this.updateSettingsData(t.detail),this.tryRender()}onLocationData(t){this.updateLocationData(t.detail),this.tryRender()}updateLocationData(t){this.locationData=t}updateSettingsData(t){t&&(this.settingsLoaded=!0,this.heroUrl=t.heroImageUrl)}haveSettings(){return this.settingsLoaded}haveLocationData(){return null!=this.locationData}tryUpdateLocationData(){const t=LocationService.getLocation(this.locationId);t&&this.updateLocationData(t)}tryUpdateSettingsData(){if(this.element){const t=SettingsService.getSettingsByElement(this.element);t&&this.updateSettingsData(t)}}tryRender(){if(this.haveSettings()&&this.haveLocationData()){this.shadowRoot.querySelector(`#${t.elementId}`).innerHTML=this.getHeroImage()}}getHeroImage(){let t=this.locationData.name;"string"==typeof this.locationData.storeName&&""!==this.locationData.storeName&&(t=t+" ("+this.locationData.storeName+")");let e="";return this.heroUrl&&""!==this.heroUrl?e+=`<div class="row" style="margin-top:5rem"><div class="col-12"><img src="${this.heroUrl}" alt="Hero image for ${t} in ${this.locationData.address.city} aria-hidden="true" class="img-fluid w-100 hero-img" /></div></div>`:e+='<div class="row"><div class="col-12 mt-100"></div></div>',e+=`<div class="row px-6"><div class="col-12"><h1 class="hero-text">${t}</h1></div></div>`,e}}newHeroClass=t,customElements.get(t.tagName)?window.console&&console.error(`<${t.tagName}> already defined`):customElements.define(t.tagName,t)}();
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.