import React from 'react';
import { connect } from 'umi';
import LoginCssComponent from '../../../mobile/logincss/LoginCss';

function LoginCss({
  dispatch, app, content, loginMobile,
}) {
  const LoginProps = {
    app,
    content,
    onLogin: userlogin,
    dispatch,
    loginMobile,
  };

  function userlogin(param) {
    dispatch({
      type: 'login/login',
      payload: { ...param, dispatch },
    });
  }

  return (
    <div>
      <LoginCssComponent {...LoginProps} />
    </div>
  );
}

export default connect(({ app, content }) => ({ app, content }))(LoginCss);
