(function(global,factory){typeof exports==="object"&&typeof module!=="undefined"?module.exports=factory():typeof define==="function"&&define.amd?define(factory):(global=typeof globalThis!=="undefined"?globalThis:global||self,global.FormValidation=global.FormValidation||{},global.FormValidation.plugins=global.FormValidation.plugins||{},global.FormValidation.plugins.AutoFocus=factory())})(this,(function(){"use strict";function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}}function _defineProperties(target,props){for(var i=0;i0){var _t2=_s[0];var _i=this.core.getElements(_t2);if(_i.length>0){var _s3=_i[0];var e={firstElement:_s3,field:_t2};this.core.emit("plugins.autofocus.prefocus",e);this.opts.onPrefocus(e);_s3.focus()}}}}]);return s}(t$1);return s}));