Signup shell tweaks
parent
6e1541f203
commit
aa239451af
|
@ -1,6 +1,7 @@
|
||||||
import {Platform} from 'react-native'
|
import {Platform} from 'react-native'
|
||||||
import {web, native} from '#/alf/util/platform'
|
|
||||||
import * as tokens from '#/alf/tokens'
|
import * as tokens from '#/alf/tokens'
|
||||||
|
import {native, web} from '#/alf/util/platform'
|
||||||
|
|
||||||
export const atoms = {
|
export const atoms = {
|
||||||
/*
|
/*
|
||||||
|
@ -253,10 +254,10 @@ export const atoms = {
|
||||||
fontWeight: tokens.fontWeight.normal,
|
fontWeight: tokens.fontWeight.normal,
|
||||||
},
|
},
|
||||||
font_semibold: {
|
font_semibold: {
|
||||||
fontWeight: '500',
|
fontWeight: tokens.fontWeight.semibold,
|
||||||
},
|
},
|
||||||
font_bold: {
|
font_bold: {
|
||||||
fontWeight: tokens.fontWeight.semibold,
|
fontWeight: tokens.fontWeight.bold,
|
||||||
},
|
},
|
||||||
italic: {
|
italic: {
|
||||||
fontStyle: 'italic',
|
fontStyle: 'italic',
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import {
|
import {
|
||||||
BLUE_HUE,
|
BLUE_HUE,
|
||||||
RED_HUE,
|
|
||||||
GREEN_HUE,
|
|
||||||
generateScale,
|
generateScale,
|
||||||
|
GREEN_HUE,
|
||||||
|
RED_HUE,
|
||||||
} from '#/alf/util/colorGeneration'
|
} from '#/alf/util/colorGeneration'
|
||||||
|
|
||||||
export const scale = generateScale(6, 100)
|
export const scale = generateScale(6, 100)
|
||||||
|
@ -116,8 +116,8 @@ export const borderRadius = {
|
||||||
|
|
||||||
export const fontWeight = {
|
export const fontWeight = {
|
||||||
normal: '400',
|
normal: '400',
|
||||||
semibold: '600',
|
semibold: '500',
|
||||||
bold: '900',
|
bold: '600',
|
||||||
} as const
|
} as const
|
||||||
|
|
||||||
export const gradients = {
|
export const gradients = {
|
||||||
|
|
|
@ -21,6 +21,7 @@ import {StepHandle} from '#/screens/Signup/StepHandle'
|
||||||
import {StepInfo} from '#/screens/Signup/StepInfo'
|
import {StepInfo} from '#/screens/Signup/StepInfo'
|
||||||
import {atoms as a, useTheme} from '#/alf'
|
import {atoms as a, useTheme} from '#/alf'
|
||||||
import {Button, ButtonText} from '#/components/Button'
|
import {Button, ButtonText} from '#/components/Button'
|
||||||
|
import {Divider} from '#/components/Divider'
|
||||||
import {InlineLink} from '#/components/Link'
|
import {InlineLink} from '#/components/Link'
|
||||||
import {Text} from '#/components/Typography'
|
import {Text} from '#/components/Typography'
|
||||||
|
|
||||||
|
@ -126,16 +127,9 @@ export function Signup({onPressBack}: {onPressBack: () => void}) {
|
||||||
keyboardShouldPersistTaps="handled"
|
keyboardShouldPersistTaps="handled"
|
||||||
style={a.h_full}
|
style={a.h_full}
|
||||||
keyboardDismissMode="on-drag">
|
keyboardDismissMode="on-drag">
|
||||||
<View
|
<View style={[a.flex_1, a.px_xl, a.pt_2xl, {paddingBottom: 100}]}>
|
||||||
style={[
|
<View style={[a.gap_sm, a.pb_3xl]}>
|
||||||
a.flex_1,
|
<Text style={[a.font_semibold, t.atoms.text_contrast_medium]}>
|
||||||
a.px_xl,
|
|
||||||
a.gap_3xl,
|
|
||||||
a.pt_2xl,
|
|
||||||
{paddingBottom: 100},
|
|
||||||
]}>
|
|
||||||
<View style={[a.gap_sm]}>
|
|
||||||
<Text style={[a.text_lg, t.atoms.text_contrast_medium]}>
|
|
||||||
<Trans>Step</Trans> {state.activeStep + 1} <Trans>of</Trans>{' '}
|
<Trans>Step</Trans> {state.activeStep + 1} <Trans>of</Trans>{' '}
|
||||||
{state.serviceDescription &&
|
{state.serviceDescription &&
|
||||||
!state.serviceDescription.phoneVerificationRequired
|
!state.serviceDescription.phoneVerificationRequired
|
||||||
|
@ -152,7 +146,8 @@ export function Signup({onPressBack}: {onPressBack: () => void}) {
|
||||||
)}
|
)}
|
||||||
</Text>
|
</Text>
|
||||||
</View>
|
</View>
|
||||||
<View>
|
|
||||||
|
<View style={[a.pb_3xl]}>
|
||||||
{state.activeStep === SignupStep.INFO ? (
|
{state.activeStep === SignupStep.INFO ? (
|
||||||
<StepInfo />
|
<StepInfo />
|
||||||
) : state.activeStep === SignupStep.HANDLE ? (
|
) : state.activeStep === SignupStep.HANDLE ? (
|
||||||
|
@ -162,12 +157,12 @@ export function Signup({onPressBack}: {onPressBack: () => void}) {
|
||||||
)}
|
)}
|
||||||
</View>
|
</View>
|
||||||
|
|
||||||
<View style={[a.flex_row, a.justify_between]}>
|
<View style={[a.flex_row, a.justify_between, a.pb_lg]}>
|
||||||
<Button
|
<Button
|
||||||
label="Back"
|
label="Back"
|
||||||
variant="solid"
|
variant="solid"
|
||||||
color="secondary"
|
color="secondary"
|
||||||
size="small"
|
size="medium"
|
||||||
onPress={onBackPress}>
|
onPress={onBackPress}>
|
||||||
Back
|
Back
|
||||||
</Button>
|
</Button>
|
||||||
|
@ -178,7 +173,7 @@ export function Signup({onPressBack}: {onPressBack: () => void}) {
|
||||||
label="Retry"
|
label="Retry"
|
||||||
variant="solid"
|
variant="solid"
|
||||||
color="primary"
|
color="primary"
|
||||||
size="small"
|
size="medium"
|
||||||
disabled={state.isLoading}
|
disabled={state.isLoading}
|
||||||
onPress={() => refetch()}>
|
onPress={() => refetch()}>
|
||||||
Retry
|
Retry
|
||||||
|
@ -187,12 +182,8 @@ export function Signup({onPressBack}: {onPressBack: () => void}) {
|
||||||
<Button
|
<Button
|
||||||
label="Next"
|
label="Next"
|
||||||
variant="solid"
|
variant="solid"
|
||||||
color={
|
color="primary"
|
||||||
!state.canNext || state.isLoading
|
size="medium"
|
||||||
? 'secondary'
|
|
||||||
: 'primary'
|
|
||||||
}
|
|
||||||
size="small"
|
|
||||||
disabled={!state.canNext || state.isLoading}
|
disabled={!state.canNext || state.isLoading}
|
||||||
onPress={onNextPress}>
|
onPress={onNextPress}>
|
||||||
<ButtonText>Next</ButtonText>
|
<ButtonText>Next</ButtonText>
|
||||||
|
@ -201,19 +192,13 @@ export function Signup({onPressBack}: {onPressBack: () => void}) {
|
||||||
</>
|
</>
|
||||||
)}
|
)}
|
||||||
</View>
|
</View>
|
||||||
<View
|
|
||||||
style={[
|
<Divider />
|
||||||
a.w_full,
|
|
||||||
a.py_lg,
|
<View style={[a.w_full, a.py_lg]}>
|
||||||
a.px_md,
|
<Text style={[t.atoms.text_contrast_medium]}>
|
||||||
a.rounded_sm,
|
|
||||||
t.atoms.bg_contrast_25,
|
|
||||||
]}>
|
|
||||||
<Text style={[a.text_md, t.atoms.text_contrast_medium]}>
|
|
||||||
<Trans>Having trouble?</Trans>{' '}
|
<Trans>Having trouble?</Trans>{' '}
|
||||||
<InlineLink
|
<InlineLink to={FEEDBACK_FORM_URL({email: state.email})}>
|
||||||
style={[a.text_md]}
|
|
||||||
to={FEEDBACK_FORM_URL({email: state.email})}>
|
|
||||||
<Trans>Contact support</Trans>
|
<Trans>Contact support</Trans>
|
||||||
</InlineLink>
|
</InlineLink>
|
||||||
</Text>
|
</Text>
|
||||||
|
|
Loading…
Reference in New Issue