Fix regressions found by cypress tests

This commit is contained in:
SleepWalker
2019-12-07 23:53:22 +02:00
parent 8734956c79
commit c82468333f
9 changed files with 36 additions and 23 deletions

View File

@@ -53,7 +53,9 @@ export default class BaseAuthBody extends React.Component<
renderErrors: false,
});
bindField = this.form.bindField.bind(this.form);
bindField(name: string) {
return this.form.bindField(name);
}
serialize() {
return this.form.serialize();

View File

@@ -1,6 +1,5 @@
import React from 'react';
import { AccountsState } from 'app/components/accounts';
import { AuthState } from 'app/components/auth';
import { User } from 'app/components/user';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
@@ -11,18 +10,18 @@ import {
PanelFooter,
PanelHeader,
} from 'app/components/ui/Panel';
import { getLogin } from 'app/components/auth/reducer';
import { Form } from 'app/components/ui/form';
import MeasureHeight from 'app/components/MeasureHeight';
import defaultHelpLinksStyles from 'app/components/auth/helpLinks.scss';
import panelStyles from 'app/components/ui/panel.scss';
import icons from 'app/components/ui/icons.scss';
import authFlow from 'app/services/authFlow';
import { userShape } from 'app/components/user/User';
import * as actions from './actions';
import { RootState } from 'app/reducers';
import { getLogin, State as AuthState } from './reducer';
import * as actions from './actions';
import helpLinks from './helpLinks.scss';
const opacitySpringConfig = { stiffness: 300, damping: 20 };
const transformSpringConfig = { stiffness: 500, damping: 50, precision: 0.5 };
const changeContextSpringConfig = {
@@ -31,7 +30,7 @@ const changeContextSpringConfig = {
precision: 0.5,
};
const { helpLinksStyles } = defaultHelpLinksStyles;
const { helpLinks: helpLinksStyles } = helpLinks;
type PanelId = string;

View File

@@ -11,7 +11,6 @@ import messages from './Register.intl.json';
// TODO: password and username can be validate for length and sameness
export default class RegisterBody extends BaseAuthBody {
static displayName = 'RegisterBody';
static panelId = 'register';
autoFocusField = 'username';