import{__awaiter,__generator}from"tslib";import{H as registerInstance,y as waitAfterIdleCallback,x as waitAfterFramePaint,M as h,N as Host,O as getElement}from"./index-DGWPFpP6.js";import{s as scrollToFirstInvalidField}from"./form-FCLKfv6B.js";var balFormCss=".bal-form{display:block;position:static}";var Form=function(){function t(t){registerInstance(this,t);this.native=false;this.novalidate=false;this.formClass=""}t.prototype.scrollToFirstInvalidField=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){switch(t.label){case 0:return[4,waitAfterIdleCallback()];case 1:t.sent();return[4,waitAfterFramePaint()];case 2:t.sent();scrollToFirstInvalidField({formEl:this.el});return[2]}}))}))};t.prototype.render=function(){var t=this.native?"form":"div";var e={};if(this.native){e={novalidate:this.novalidate}}return h(Host,{key:"1598e29d7763c06aeebe9ae70e4ad27695c9796d"},h(t,Object.assign({key:"140fa29ca7900623d52da99ffc5f9bd6db72cd97"},e,{class:this.formClass}),h("slot",{key:"1797bdbc8f4f70b50c5d193acea0569e977d8a81"})))};Object.defineProperty(t.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return t}();Form.style=balFormCss;export{Form as bal_form};