Created
April 17, 2020 07:04
-
-
Save mikehibm/937556128f076b00670fb4af18ffc95a to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Amplify from 'aws-amplify'; | |
import { AmplifyAuthenticator, AmplifySignUp } from '@aws-amplify/ui-react'; | |
import awsconfig from '../aws-exports'; | |
import { MyLayout } from '../components/MyLayout'; | |
import { TodoApp } from '../components/TodoApp'; | |
Amplify.configure(awsconfig); | |
const contentStyle = { | |
paddingLeft: '0', | |
paddingRight: '0', | |
textAlign: 'center', | |
}; | |
export default () => { | |
return ( | |
<MyLayout contentStyle={contentStyle}> | |
<AmplifyAuthenticator> | |
<AmplifySignUp | |
headerText="ユーザー登録" | |
slot="sign-up" | |
formFields={[ | |
{ type: 'username', required: true }, | |
{ type: 'password', required: true }, | |
{ type: 'email', required: true }, | |
{ | |
type: 'phone_number', | |
required: false, | |
disabled: true, | |
}, | |
]} | |
submitButtonText="登録する" | |
/> | |
<TodoApp /> | |
</AmplifyAuthenticator> | |
</MyLayout> | |
); | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment