exports.ids=[5],exports.modules={352:function(t,e,n){"use strict";n.r(e);var s=n(34),i=n(32),a=n(16),o=n(36),c=n(35),r=n(15),l=n(0),d=n(18),p=n(8),u=n(328),m=n(299),O=n(338),h=n(111),b=n(174),f=n(10),g=n(58),j=n(4),E=n(66),v=n(3),T=n(60),x=n(55),N=l.lazy((function(){return n.e(0).then(n.t.bind(null,350,7))})),S=n(127),k=function(t){Object(o.a)(n,t);var e=Object(c.a)(n);function n(t){var i;return Object(s.a)(this,n),i=e.call(this,t),Object(r.a)(Object(a.a)(i),"onUpdateSettingsDebounced",S(i.props.onUpdateSettings,300)),Object(r.a)(Object(a.a)(i),"changeUser",(function(t,e){i.onUpdateSettingsDebounced({user:e})})),Object(r.a)(Object(a.a)(i),"changeToken",(function(t,e){i.onUpdateSettingsDebounced({token:e})})),Object(r.a)(Object(a.a)(i),"changeTitle",(function(t,e){i.onUpdateSettingsDebounced({title:e})})),Object(r.a)(Object(a.a)(i),"showEditor",(function(){return i.setState({showMessageEditor:!0})})),Object(r.a)(Object(a.a)(i),"saveTextFromEditor",(function(t){i.props.onUpdateSettings({message:t}),i.setState({showMessageEditor:!1})})),Object(r.a)(Object(a.a)(i),"closeTextEditor",(function(){return i.setState({showMessageEditor:!1})})),i.state={showMessageEditor:!1},i.props.setValidationStatus(i.isValid(),t.nodeId),i}return Object(i.a)(n,[{key:"isValid",value:function(){return this.props.settings.token&&this.props.settings.title&&this.props.settings.user?{result:!0,reason:""}:{result:!1,reason:"No key, token on title provided"}}},{key:"componentDidUpdate",value:function(){this.props.isValid&&this.props.isValid.result==this.isValid().result||this.props.setValidationStatus(this.isValid(),this.props.nodeId)}},{key:"render",value:function(){var t=this,e=Object(x.a)(Object(p.D)()),n=[];return this.props.inputData&&(n=Object(u.c)(Object.keys(this.props.inputData).map((function(e){return t.props.inputData[e]}))).map((function(t){return{label:t.label,detail:Object(v.a)().editorDescriptions[t.label]}}))),l.createElement("div",Object.assign({className:e.notificationOptionsWindow},Object(j.g)("/pushover/")),l.createElement("span",{className:e.notificationOptionsHelpIcon},l.createElement(E.a,{calloutText:l.createElement("span",null,Object(v.a)().pushoverHelpCallout,l.createElement(T.a,{url:"/pushover/"}))})),l.createElement("div",{className:e.notificationOptions},l.createElement(m.a,{label:Object(v.a)().userKey,type:"password",required:!0,className:e.notificationOptionsTextField,inputClassName:e.notificationOptionsTextFieldInput,defaultValue:this.props.settings.user,onChange:this.changeUser})),l.createElement("div",{className:e.notificationOptions},l.createElement(m.a,{label:Object(v.a)().appToken,type:"password",required:!0,className:e.notificationOptionsTextField,inputClassName:e.notificationOptionsTextFieldInput,defaultValue:this.props.settings.token,onChange:this.changeToken})),l.createElement("div",{className:e.notificationOptions},l.createElement(m.a,{label:Object(v.a)().title,className:e.notificationOptionsTextField,inputClassName:e.notificationOptionsTextFieldInput,defaultValue:this.props.settings.title,onChange:this.changeTitle})),l.createElement("div",{className:e.notificationOptions,style:{marginTop:"10px"}},l.createElement("span",{className:e.notificationOptionsTextLabel},Object(v.a)().messageContent)),l.createElement("div",{className:e.notificationOptions+" "+e.notificationOptionsDocumentCard},l.createElement("div",{className:e.notificationOptionsDocumentCardInsides},l.createElement(O.a,{type:h.a.compact,onClick:this.showEditor},l.createElement("div",{className:e.notificationOptionsDocumentCardText},this.props.settings.message||Object(v.a)().defaultActionText)),l.createElement(l.Suspense,{fallback:l.createElement("div",null,Object(v.a)().editorLoading)},l.createElement(N,{textOnMount:this.props.settings.message||Object(v.a)().defaultActionText,keywords:n,showMessageEditor:this.state.showMessageEditor,onSave:this.saveTextFromEditor,onDismiss:this.closeTextEditor})))),l.createElement("div",{className:e.notificationOptions},l.createElement(b.a,{disabled:!this.props.isValid||!this.props.isValid.result,"data-automation-id":"test",allowDisabledFocus:!0,checked:!1,text:Object(v.a)().testPushover,onClick:this.props.sendTestPush})))}}]),n}(l.Component);e.default=Object(d.connect)((function(t,e){return{inputData:t.postRenderActionsState.actions[e.nodeId].inputData,settings:t.postRenderActionsState.actions[e.nodeId].settings,isValid:t.postRenderActionsState.actions[e.nodeId].isValid}}),(function(t,e){return{onUpdateSettings:function(n){return t(Object(f.m)({settings:n,actionId:e.nodeId}))},sendTestPush:function(){return t(Object(g.a)({nodeId:e.nodeId}))},setValidationStatus:function(e,n){return t(Object(f.u)({status:e,actionId:n}))}}}))(k)}};
//# sourceMappingURL=5.8d94356b1d33ff5e7a79.chunk.js.map