var StylitFormInput=class extends StylitBaseElement{connectedCallback(){this.isTextarea=stylitTheme.hasClass(this,"stylit-is_textarea"),this.$input=this.querySelector("[stylit-input]"),this.focusClass="stylit-focus",this.bindChange(),this.init()}init(){var t=this.getCurInputVal();this.troggleFocus(t)}bindChange(){var t=()=>{var t=this.getCurInputVal();this.troggleFocus(t)};this.$input.addEventListener("input",t),this.$input.addEventListener("propertychange",t)}troggleFocus(t){t.length?stylitTheme.hasClass(this,this.focusClass)||stylitTheme.addClass(this.$input,this.focusClass):stylitTheme.removeClass(this.$input,this.focusClass)}getCurInputVal(){return void 0===this.$input.value?"":this.$input.value}},StylitFormSelect=(window.customElements.get("stylit-form-input")||window.customElements.define("stylit-form-input",StylitFormInput),class extends StylitBaseElement{connectedCallback(){this.$select=this.querySelector("[stylit-select]"),this.focusClass="stylit-focus",this.bindChange(),this.resetSelected()}resetSelected(){var t=this.$select.value;console.log("value",t),t.length?stylitTheme.hasClass(this,this.focusClass)||stylitTheme.addClass(this.$select,this.focusClass):stylitTheme.removeClass(this.$select,this.focusClass)}bindChange(){this.$select.addEventListener("change",()=>this.resetSelected())}});window.customElements.get("stylit-form-select")||window.customElements.define("stylit-form-select",StylitFormSelect);