webpackJsonp([25],{2528:function(e,t,a){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var s=a(259),l=r(s),d=a(258),n=r(d),u=a(262),o=r(u),i=a(260),f=r(i),m=a(261),c=r(m),p=a(761),h=r(p),v=a(22),E=r(v),_=a(14),b=r(_),M=a(266),g=r(M),w=a(749),y=a(769),k=a(750),N=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(k),S=a(840),x=r(S),P=function(e){function t(e){(0,n.default)(this,t);var a=(0,f.default)(this,(t.__proto__||(0,l.default)(t)).call(this,e));return a.handleSendLink=a.handleSendLink.bind(a),a.state={error:"",updateText:""},a}return(0,c.default)(t,e),(0,o.default)(t,[{key:"handleSendLink",value:function(e){var t=this;e.preventDefault();var a=g.default.findDOMNode(this.refs.email).value.trim().toLowerCase();if(!a||!N.isEmail(a))return void this.setState({error:b.default.createElement(w.FormattedMessage,{id:"password_send.error",defaultMessage:"Please enter a valid email address."})});this.setState({error:""}),(0,y.sendPasswordResetEmail)(a,function(){t.setState({error:null,updateText:b.default.createElement("div",{className:"reset-form alert alert-success"},b.default.createElement(w.FormattedHTMLMessage,{id:"password_send.link",defaultMessage:"If the account exists, a password reset email will be sent to: <br/><b>{email}</b><br/><br/>",values:{email:a}}),b.default.createElement(w.FormattedMessage,{id:"password_send.checkInbox",defaultMessage:"Please check your inbox."}))}),(0,h.default)(g.default.findDOMNode(t.refs.reset_form)).hide()},function(e){t.setState({error:e.message,update_text:null})})}},{key:"render",value:function(){var e=null;this.state.error&&(e=b.default.createElement("div",{className:"form-group has-error"},b.default.createElement("label",{className:"control-label"},this.state.error)));var t="form-group";return e&&(t+=" has-error"),b.default.createElement("div",null,b.default.createElement(x.default,null),b.default.createElement("div",{className:"col-sm-12"},b.default.createElement("div",{className:"signup-team__container"},b.default.createElement("h3",null,b.default.createElement(w.FormattedMessage,{id:"password_send.title",defaultMessage:"Password Reset"})),this.state.updateText,b.default.createElement("form",{onSubmit:this.handleSendLink,ref:"reset_form"},b.default.createElement("p",null,b.default.createElement(w.FormattedMessage,{id:"password_send.description",defaultMessage:"To reset your password, enter the email address you used to sign up"})),b.default.createElement("div",{className:t},b.default.createElement("input",{type:"email",className:"form-control",name:"email",ref:"email",placeholder:N.localizeMessage("password_send.email","Email"),spellCheck:"false"})),e,b.default.createElement("button",{type:"submit",className:"btn btn-primary"},b.default.createElement(w.FormattedMessage,{id:"password_send.reset",defaultMessage:"Reset my password"}))))))}}]),t}(b.default.Component);P.defaultProps={},P.propTypes={params:E.default.object.isRequired},t.default=P}});
//# sourceMappingURL=25.78fc88c05be5d02a7b2c.js.map