1"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[67579],{7579(s,e,t){t.r(e),t.d(e,{default:()=>i});let l=window.PluginManager;class i extends window.PluginBaseClass{static #s=this.options={selector:".form-label",toggleClass:"has-placeholder-hidden",handleByClass:[{class:"StripeElement",showClasses:["StripeElement--focus"],hideClasses:["StripeElement--empty"]}],handleFromEvent:[{plugin:"AjaxModal",event:"ajaxModalOpen",property:"modal"}]};init(){this.labels=this.el.querySelectorAll(this.options.selector),this._registerEvents(this.labels),this._registerModals()}_registerModals(){this.options.handleFromEvent.forEach(s=>{l.getPlugin(s.plugin,!1)&&(l.getPluginInstances(s.plugin)||[]).forEach(e=>{e.$emitter.subscribe(s.event,e=>{let{detail:t}=e,l=t[s.property];l&&l._modal&&this._registerEvents(l._modal.querySelectorAll(this.options.selector))})})})}_registerEvents(s){s.forEach(s=>{let e=s.nextElementSibling;e&&(["INPUT","TEXTAREA"].includes(e.tagName)&&(e.addEventListener("focus",this.handleFocus.bind(this,s)),e.addEventListener("blur",this.handleBlur.bind(this,e,s)),e.addEventListener("change",this.handleBlur.bind(this,e,s)),this.handleBlur(e,s)),this.options.handleByClass.forEach(t=>{e.classList.contains(t.class)&&(new MutationObserver(e=>{e.forEach(e=>{"attributes"===e.type&&"class"===e.attributeName&&this.handleMutation(t,e.target,s)})}).observe(e,{attributes:!0}),this.handleMutation(t,e,s))}))})}handleFocus(s){s.classList.add(this.options.toggleClass)}handleBlur(s,e){s.value?e.classList.add(this.options.toggleClass):e.classList.remove(this.options.toggleClass)}handleMutation(s,e,t){s.showClasses.find(s=>e.classList.contains(s))?t.classList.add(this.options.toggleClass):s.hideClasses.find(s=>e.classList.contains(s))&&t.classList.remove(this.options.toggleClass)}}}}]);
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.