(window.multistep_editor_jsonpFunction=window.multistep_editor_jsonpFunction||[]).push([[26],{921:function(t,e,i){"use strict";i.r(e),i.d(e,"AuWidgetFinishButton",function(){return c}),i.d(e,"widget",function(){return c});var s=i(0),n=i(2),d=i(14),o=i(1),b=i(160);let c=class extends b.a{constructor(){super(...arguments),this.selector="#finishButton",this.widgetIsInited=!1,this._subscribed=!1}updateParams(t){void 0!==t.visible&&(this.visible=t.visible),void 0!==t.enabled&&(this.enabled=t.enabled),this._onClick=o.a.functionWrapperConstructor(t.onClick),this.auWizard._showDefaultTopBar&&this._changeDisable(),this.widgetIsInited||(console.warn("'finish-button' widget is deprecated, use 'steps' widget instead."),this.widgetIsInited=!0)}_changeDisable(){this.publishData({selector:this.selector},d.a.GET_ELEMENT_FROM_AU_WIZARD).then(t=>{t&&(void 0!==this.visible&&(t.hidden=!this.visible,t.setAttribute&&t.setAttribute("data-hidden",t.hidden)),void 0!==this.enabled&&(t.enabled=this.enabled),this._subscribed||(t.onFinish.subscribe(async()=>{await this._onClick()}),this._subscribed=!0))})}};Object(s.a)([Object(n.c)(),Object(s.b)("design:type",Object)],c.prototype,"params",void 0),Object(s.a)([Object(n.c)(),Object(s.b)("design:type",String)],c.prototype,"selector",void 0),Object(s.a)([Object(n.c)(),Object(s.b)("design:type",Boolean)],c.prototype,"enabled",void 0),Object(s.a)([Object(n.c)(),Object(s.b)("design:type",Boolean)],c.prototype,"visible",void 0),c=Object(s.a)([Object(n.a)("au-widget-finish-button")],c)}}]);