1const{getElement}=window.BAO.Utils;class SiteNotifications extends window.BAO.CustomElement(){connectedCallback(){super.connectedCallback(),this.showUnreadNotificationPulse(),this.unreadNotificationCount>0&&(this.externalEls.count.elements.forEach(element=>{element.innerHTML=this.unreadNotificationCount,element.ariaHidden=!1}),this.externalEls.trigger.elements.forEach(element=>{element.dataset.ringing=!0}))}setupListeners(){super.setupListeners(),this.els.item.elements.forEach(element=>{this.listeners.add(element,"click",()=>{this.notificationsClicked=element.dataset.id,getElement(this.els.unread.selector,{context:element}).ariaHidden=!0})})}triggerEvent(){this.notificationsRead=this.dataset.ids,this.externalEls.trigger.elements.forEach(element=>{element.dataset.ringing=!1}),this.externalEls.count.elements.forEach(element=>{element.ariaHidden=!0})}showUnreadNotificationPulse(){this.els.unread.elements.forEach(element=>{element.ariaHidden=this.notificationsClicked?.includes(element.dataset.id)})}get unreadNotificationCount(){const current=this.dataset.ids.split(","),clicked=(this.notificationsClicked||"").split(",").filter(Boolean);return current.filter(id=>!clicked.includes(id)).length}get notificationsRead(){return window.localStorage.getItem("site-notification:ids")}set notificationsRead(ids){return window.localStorage.setItem("site-notification:ids",ids)}get notificationsClicked(){return window.localStorage.getItem("site-notification:clicked")}set notificationsClicked(id){const ids=`${this.notificationsClicked},${id}`;return window.localStorage.setItem("site-notification:clicked",ids)}}customElements.get("site-notifications")||customElements.define("site-notifications",SiteNotifications); 2//# sourceMappingURL=/cdn/shop/t/291/assets/site-notifications.js.map?v=155602037469624996181770733915
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.