1export const ThemeEditorEventHandlerMixin=Base=>class extends Base{connectedCallback(){Shopify.designMode&&(this.boundEventMap=this.createThemeEditorEventMap(),Object.entries(this.boundEventMap).forEach(([event,boundHandler])=>{(event.includes("section")?document:this).addEventListener(event,boundHandler)}),typeof this.onSectionLoad=="function"&&this.onSectionLoad())}disconnectedCallback(){if(Shopify.designMode){const eventMap=this.boundEventMap||{};Object.entries(eventMap).forEach(([event,boundHandler])=>{event.includes("section")&&document.removeEventListener(event,boundHandler)}),typeof this.onSectionUnload=="function"&&this.onSectionUnload()}}createThemeEditorEventMap(){return["shopify:section:select","shopify:section:deselect","shopify:section:reorder","shopify:block:select","shopify:block:deselect"].reduce((acc,eventName)=>{const methodName=this.convertEventToMethodName(eventName);return typeof this[methodName]=="function"&&(acc[eventName]=this.createEventBoundHandler(this[methodName])),acc},{})}convertEventToMethodName(eventName){const capitalize=str=>str.charAt(0).toUpperCase()+str.slice(1);return`on${eventName.split(":").slice(1).map(capitalize).join("")}`}createEventBoundHandler(handler){return event=>{event.detail&&event.detail.sectionId===this.sectionId&&handler.call(this,event)}}}; 2//# sourceMappingURL=/cdn/shop/t/88/assets/util.editor-events.js.map?v=99040249503335390211791382176
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.