1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6463],{2541:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/account/change-password/[hash]",function(){return t(4560)}])},4560:function(e,n,t){"use strict";t.r(n),t.d(n,{default:function(){return U}});var r=t(85893),a=t(67294),s=t(14416),o=t(11163),i=t(14890),c=t(41664),u=t.n(c),l=t(68156),d=t(55770),h=t(80967),f=t(75264),p=t(71321),m=t(58298),v=t(79161),b=t(44054);function y(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function w(e,n){for(var t=0;t<n.length;t++){var r=n[t];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function j(e){return(j=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function g(e,n){return!n||"object"!==O(n)&&"function"!==typeof n?y(e):n}function x(e,n){return(x=Object.setPrototypeOf||function(e,n){return e.__proto__=n,e})(e,n)}var O=function(e){return e&&"undefined"!==typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};function P(e){var n=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var t,r=j(e);if(n){var a=j(this).constructor;t=Reflect.construct(r,arguments,a)}else t=r.apply(this,arguments);return g(this,t)}}var N=function(e){!function(e,n){if("function"!==typeof n&&null!==n)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),n&&x(e,n)}(o,e);var n,t,a,s=P(o);function o(e){var n;return function(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}(this,o),(n=s.call(this,e)).handleInputChange=n.handleInputChange.bind(y(n)),n.handleValidSubmit=n.handleValidSubmit.bind(y(n)),n.state={password:"",passwordCheck:""},n}return n=o,(t=[{key:"handleInputChange",value:function(e){var n,t,r;this.setState((n={},t=e.currentTarget.id,r=e.target.value,t in n?Object.defineProperty(n,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[t]=r,n))}},{key:"handleFormSubmit",value:function(e){this.props.sendPasswordFunction(e.password)}},{key:"handleValidSubmit",value:function(){var e=this.state;(0,this.props.sendPasswordFunction)(e.password)}},{key:"render",value:function(){var e=this.props.handleSubmit;return!0===this.props.auth.isPasswordChanged&&!1===this.props.user.authenticated?(0,r.jsx)("div",{className:"main-body single",children:(0,r.jsx)(d.Z,{stackable:!0,columns:2,children:(0,r.jsxs)(d.Z.Column,{className:"auth-form-column",children:[(0,r.jsx)("h3",{className:"form-header",children:"YOU'RE ALL SET"}),(0,r.jsxs)("div",{className:"auth-form signin-on",children:["Your changes have been saved, and you can now ",(0,r.jsx)(u(),{href:"/account/signin",children:"sign in"})," with the new password."]}),(0,r.jsx)(u(),{href:"/account/signin",children:(0,r.jsx)(h.Z,{className:"light-button",children:"SIGN IN TO SPENDWELL"})})]})})}):this.props.auth.isPasswordChanged&&this.props.user.authenticated?(0,r.jsx)("div",{className:"main-body single",children:(0,r.jsx)(d.Z,{stackable:!0,columns:2,children:(0,r.jsxs)(d.Z.Column,{className:"auth-form-column",children:[(0,r.jsx)("div",{className:"regular-header",children:"YOU'RE ALL SET"}),(0,r.jsx)("div",{className:"auth-form signin-on",children:"Your new password has been saved."}),(0,r.jsx)(u(),{href:"/account/priorities",children:(0,r.jsx)(h.Z,{className:"light-button",children:"UPDATE YOUR PRIORITIES"})}),(0,r.jsx)(u(),{href:"/",children:(0,r.jsx)(h.Z,{className:"light-button",children:"GO TO SPENDWELL'S MAIN PAGE"})})]})})}):(0,r.jsx)("div",{className:"main-body single",children:(0,r.jsx)(d.Z,{stackable:!0,columns:2,children:(0,r.jsxs)(d.Z.Column,{className:"auth-form-column",children:[(0,r.jsx)("div",{className:"regular-header",children:"CHANGE YOUR PASSWORD"}),(0,r.jsx)("div",{className:"auth-form signin-on",children:(0,r.jsx)("p",{children:"Please enter and confirm a new password below to change the password for your Spendwell Member account."})}),(0,r.jsx)("div",{className:"password-message",children:"Passwords must be a minimum of 8 characters long and a combination of numbers, uppercase and lowercase letters. Special characters are allowed."}),(0,r.jsx)(f.Z,{className:"auth-form signin-on",onSubmit:e(this.handleFormSubmit.bind(this)),children:(0,r.jsxs)("div",{children:[(0,r.jsx)(p.Z,{name:"password",placeholder:"enter a good password",minLength:"8",component:b.qH,validate:[b.C1,b.Xc],type:"password"}),(0,r.jsx)("br",{}),(0,r.jsx)(p.Z,{name:"passwordConfirm",minLength:"8",placeholder:"confirm your password",component:b.qH,validate:[b.C1,b.qz],type:"password"}),(0,r.jsx)("br",{}),(0,r.jsx)(v.bZ,{error:this.props.auth.passwordSaveError,message:this.props.auth.message}),(0,r.jsx)(h.Z,{className:"dark-button",action:"submit",children:"Reset Password"})]})})]})})})}}])&&w(n.prototype,t),a&&w(n,a),o}(a.Component),S=N=(0,m.Z)({form:"changepassword"})(N),_=t(75589);function E(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Z(e,n){for(var t=0;t<n.length;t++){var r=n[t];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function k(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}
1function C(e){return(C=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function R(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{},r=Object.keys(t);"function"===typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(t).filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})))),r.forEach((function(n){k(e,n,t[n])}))}return e}function T(e,n){return!n||"object"!==q(n)&&"function"!==typeof n?E(e):n}function A(e,n){return(A=Object.setPrototypeOf||function(e,n){return e.__proto__=n,e})(e,n)}var q=function(e){return e&&"undefined"!==typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};function D(e){var n=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var t,r=C(e);if(n){var a=C(this).constructor;t=Reflect.construct(r,arguments,a)}else t=r.apply(this,arguments);return T(this,t)}}var I=function(e){!function(e,n){if("function"!==typeof n&&null!==n)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),n&&A(e,n)}(o,e);var n,t,a,s=D(o);function o(e){var n;return function(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}(this,o),(n=s.call(this,e)).sendPassword=n.sendPassword.bind(E(n)),n}return n=o,(t=[{key:"componentDidMount",value:function(){var e,n=(null===(e=this.props.router)||void 0===e?void 0:e.query).hash;this.props.validateHash(n)}},{key:"componentWillUnmount",value:function(){(0,this.props.passwordSaveClear)()}},{key:"sendPassword",value:function(e){var n,t=this.props.resetPassword,r=(null===(n=this.props.router)||void 0===n?void 0:n.query).hash,a=new Date;t({hash:r,password:e,expire:a.setDate(a.getDate()+1)})}},{key:"render",value:function(e){return!0===this.props.auth.hashValid?(0,r.jsx)("div",{className:"password-change",children:(0,r.jsx)(S,R({},this.props,{sendPasswordFunction:this.sendPassword}))}):(0,r.jsx)(l.Z,{children:(0,r.jsx)("div",{className:"invalid-delayed",children:"This password reset link doesn't appear to be valid."})})}}])&&Z(n.prototype,t),a&&Z(n,a),o}(a.Component);var L=(0,o.withRouter)((0,s.connect)((function(e){return{user:e.user,auth:e.auth,errors:e.errors}}),(function(e){return(0,i.DE)({validateHash:_.axg,passwordSaveClear:_.N7h,resetPassword:_.c0U},e)}))(I)),U=function(){return(0,r.jsx)("div",{children:(0,r.jsx)(L,{})})}},44054:function(e,n,t){"use strict";t.d(n,{$W:function(){return O},C1:function(){return w},Do:function(){return Z},Hc:function(){return g},JE:function(){return S},KY:function(){return P},Kw:function(){return E},Nb:function(){return _},Sl:function(){return C},Xc:function(){return k},aA:function(){return b},fo:function(){return R},qH:function(){return y},qz:function(){return j},xt:function(){return T}});var r=t(85893),a=(t(67294),t(9669)),s=t.n(a),o=(t(75589),t(45150)),i=t(40849),c=t(75264),u=t(20370),l=t(416);function d(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function h(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{},r=Object.keys(t);"function"===typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(t).filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})))),r.forEach((function(n){d(e,n,t[n])}))}return e}function f(){document.getElementById("signupPassword")}var p="https://back-355547835648.us-central1.run.app";var m,v,b=function(e){var n=e.username,t=e.email,r="/api/validateusername/",a="/api/validateemail/";return!0===e.authenticated&&(n=e.username+"/"+e.uid,t=e.email+"/"+e.uid,r="/api/validateusernameSettings/",a="/api/validateemailSettings/"),e.username?new Promise((function(e,t){s().get(p+r+n).then((function(n){"not"===n.data.message?t({username:"That username is already taken."}):e({username:"Valid username."})})).catch((function(e){return t(e)}))})):e.email?new Promise((function(e,n){s().get(p+a+t).then((function(t){"not"===t.data.message?n({email:"That email is already taken."}):e({email:"Valid email."})})).catch((function(e){return n(e)}))})):void 0},y=function(e){var n=e.input,t=e.type,a=e.placeholder,s=(e.change,e.reveal),d=e.id,p=e.className,m=e.label,v=e.options,b=e.meta,y=b.asyncValidating,w=b.touched,j=b.error,g="eye";"text"===t&&(g="eye slash");!0===s&&(o.Z,f());var x=(0,r.jsx)("div",{});return y&&(x=(0,r.jsx)("div",{className:"async-val",children:(0,r.jsx)(i.Z,{})})),"select"===t?(0,r.jsxs)("div",{children:[(0,r.jsx)(c.Z.Field,{children:(0,r.jsx)(u.Z,h({selection:!0,options:v},n,{value:n.value,placeholder:a,type:t,onChange:function(e,t){return n.onChange(t.value)}}))}),w&&j&&(0,r.jsx)("span",{className:"required",children:j})]}):"textarea"===t?(0,r.jsx)("div",{children:(0,r.jsxs)("div",{children:[(0,r.jsx)(l.Z,h({},n,{placeholder:a,type:t,rows:8})),w&&j&&(0,r.jsx)("span",{className:"required",children:j})]})}):"text"===t?(0,r.jsxs)("div",{children:[(0,r.jsxs)("div",{className:y?"async-validating":p,children:[(0,r.jsx)("input",h({},n,{id:d,type:t,placeholder:a,autoComplete:"fugoogle"})),m,x]}),w&&j&&(0,r.jsx)("span",{className:"required",children:j})]}):(0,r.jsxs)("div",{children:[(0,r.jsxs)("div",{className:y?"async-validating":p,children:[(0,r.jsx)("input",h({},n,{id:d,placeholder:a,type:t})),m,x]}),w&&j&&(0,r.jsx)("span",{className:"required",children:j})]})},w=function(e){return e?void 0:"Required"},j=function(e,n){return e!==n.password?"Passwords must match":void 0},g=function(e,n){return e!==n.username?"Usernames must match":void 0},x=function(e){return function(n){return n&&n.length>e?"Must be ".concat(e," characters or less"):void 0}}
1,O=(x(15),m=0,function(e){return e&&e.length>m?"That's just not right":void 0}),P=x(25),N=function(e){return function(n){return n&&n.length<e?"Must be at least ".concat(e," characters in length"):void 0}},S=N(2),_=N(8),E=N(3),Z=(v=13,function(e){return e&&!/^[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,4}$/i.test(e)?"Please enter a valid email address":void 0}),k=function(e){return e&&!/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)/.test(e)?"Your password must include at least one uppercase and one lowercase letter as well as at least one number":void 0},C=function(e){return e&&/(^[0-9_\-])/.test(e)?"Must begin with a letter of the alphabet":void 0},R=function(e){return e&&/[^a-zA-Z0-9 ]/i.test(e)?"Only alphanumeric characters are allowed":void 0},T=function(e){return e&&/[^a-zA-Z0-9_\-]/i.test(e)?"Only lowercase letters, numbers, dashes and underscores are allowed":void 0}}},function(e){e.O(0,[8298,1321,9774,2888,179],(function(){return n=2541,e(e.s=n);var n}));var n=e.O();_N_E=n}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.