UNPKG

@brightlayer-ui/react-native-auth-workflow

Version:

Re-usable workflow components for Authentication and Registration within Eaton applications.

24 lines (23 loc) 1.29 kB
import React from 'react'; import { ErrorManager, SetPassword, WorkflowCard, WorkflowCardActions, WorkflowCardBody, WorkflowCardHeader, } from '../../components'; /** * Component that displays text fields to create a new user's password. * * @param {CreatePasswordScreenProps} props - props for Create Password Screen Base component. * * @category Component */ export const CreatePasswordScreenBase = (props) => { const cardBaseProps = props.WorkflowCardBaseProps || {}; const headerProps = props.WorkflowCardHeaderProps || {}; const cardBodyProps = props.WorkflowCardBodyProps || {}; const actionsProps = props.WorkflowCardActionsProps || {}; const passwordProps = props.PasswordProps || { onPasswordChange: () => { } }; const { errorDisplayConfig } = props; return (React.createElement(WorkflowCard, Object.assign({}, cardBaseProps), React.createElement(WorkflowCardHeader, Object.assign({}, headerProps)), React.createElement(WorkflowCardBody, Object.assign({}, cardBodyProps), React.createElement(ErrorManager, Object.assign({}, errorDisplayConfig), React.createElement(SetPassword, Object.assign({}, passwordProps)))), React.createElement(WorkflowCardActions, Object.assign({}, actionsProps)))); };