linting
This commit is contained in:
@@ -99,12 +99,7 @@ function Inner({style}: ViewStyleProp & {}) {
|
|||||||
|
|
||||||
<View style={style}>
|
<View style={style}>
|
||||||
<View
|
<View
|
||||||
style={[
|
style={[a.p_lg, a.rounded_md, a.border, t.atoms.border_contrast_low]}>
|
||||||
a.p_lg,
|
|
||||||
a.rounded_md,
|
|
||||||
a.border,
|
|
||||||
t.atoms.border_contrast_low,
|
|
||||||
]}>
|
|
||||||
<View
|
<View
|
||||||
style={[
|
style={[
|
||||||
a.flex_row,
|
a.flex_row,
|
||||||
@@ -120,17 +115,14 @@ function Inner({style}: ViewStyleProp & {}) {
|
|||||||
</View>
|
</View>
|
||||||
|
|
||||||
<View style={[a.pb_md, a.gap_sm]}>
|
<View style={[a.pb_md, a.gap_sm]}>
|
||||||
<Text style={[a.text_sm, a.leading_snug]}>
|
<Text style={[a.text_sm, a.leading_snug]}>{copy.notice}</Text>
|
||||||
{copy.notice}
|
|
||||||
</Text>
|
|
||||||
{hasCompletedFlow && (
|
{hasCompletedFlow && (
|
||||||
<Text style={[a.text_sm, a.leading_snug]}>
|
<Text style={[a.text_sm, a.leading_snug]}>
|
||||||
<Trans>
|
<Trans>
|
||||||
If you are 18 years of age or older and want
|
If you are 18 years of age or older and want to try again,
|
||||||
to try again, click the button below and use
|
click the button below and use a different verification method
|
||||||
a different verification method if one is
|
if one is available in your region. If you have questions or
|
||||||
available in your region. If you have
|
concerns,{' '}
|
||||||
questions or concerns,{' '}
|
|
||||||
<InlineLinkText
|
<InlineLinkText
|
||||||
label={l`Contact our support team`}
|
label={l`Contact our support team`}
|
||||||
{...createStaticClick(() => {
|
{...createStaticClick(() => {
|
||||||
@@ -148,16 +140,13 @@ function Inner({style}: ViewStyleProp & {}) {
|
|||||||
{isBlocked ? (
|
{isBlocked ? (
|
||||||
<Admonition type="warning">
|
<Admonition type="warning">
|
||||||
<Trans>
|
<Trans>
|
||||||
You are currently unable to access Bluesky's Age
|
You are currently unable to access Bluesky's Age Assurance flow.
|
||||||
Assurance flow. Please{' '}
|
Please{' '}
|
||||||
<InlineLinkText
|
<InlineLinkText
|
||||||
label={l`Contact our moderation team`}
|
label={l`Contact our moderation team`}
|
||||||
{...createStaticClick(() => {
|
{...createStaticClick(() => {
|
||||||
appealControl.open()
|
appealControl.open()
|
||||||
ax.metric(
|
ax.metric('ageAssurance:appealDialogOpen', {})
|
||||||
'ageAssurance:appealDialogOpen',
|
|
||||||
{},
|
|
||||||
)
|
|
||||||
})}>
|
})}>
|
||||||
contact our moderation team
|
contact our moderation team
|
||||||
</InlineLinkText>{' '}
|
</InlineLinkText>{' '}
|
||||||
@@ -183,18 +172,12 @@ function Inner({style}: ViewStyleProp & {}) {
|
|||||||
label={l`Verify now`}
|
label={l`Verify now`}
|
||||||
size="small"
|
size="small"
|
||||||
variant="solid"
|
variant="solid"
|
||||||
color={
|
color={hasInitiated ? 'secondary' : 'primary'}
|
||||||
hasInitiated ? 'secondary' : 'primary'
|
|
||||||
}
|
|
||||||
onPress={() => {
|
onPress={() => {
|
||||||
control.open()
|
control.open()
|
||||||
ax.metric(
|
ax.metric('ageAssurance:initDialogOpen', {
|
||||||
'ageAssurance:initDialogOpen',
|
hasInitiatedPreviously: hasInitiated,
|
||||||
{
|
})
|
||||||
hasInitiatedPreviously:
|
|
||||||
hasInitiated,
|
|
||||||
},
|
|
||||||
)
|
|
||||||
}}>
|
}}>
|
||||||
<ButtonText>
|
<ButtonText>
|
||||||
{hasInitiated ? (
|
{hasInitiated ? (
|
||||||
@@ -207,36 +190,21 @@ function Inner({style}: ViewStyleProp & {}) {
|
|||||||
|
|
||||||
{lastInitiatedAt && timeAgo && diff ? (
|
{lastInitiatedAt && timeAgo && diff ? (
|
||||||
<Text
|
<Text
|
||||||
style={[
|
style={[a.text_sm, a.italic, t.atoms.text_contrast_medium]}
|
||||||
a.text_sm,
|
|
||||||
a.italic,
|
|
||||||
t.atoms.text_contrast_medium,
|
|
||||||
]}
|
|
||||||
title={i18n.date(lastInitiatedAt, {
|
title={i18n.date(lastInitiatedAt, {
|
||||||
dateStyle: 'medium',
|
dateStyle: 'medium',
|
||||||
timeStyle: 'medium',
|
timeStyle: 'medium',
|
||||||
})}>
|
})}>
|
||||||
{diff.value === 0 ? (
|
{diff.value === 0 ? (
|
||||||
<Trans>
|
<Trans>Last initiated just now</Trans>
|
||||||
Last initiated just now
|
|
||||||
</Trans>
|
|
||||||
) : (
|
) : (
|
||||||
<Trans>
|
<Trans>Last initiated {timeAgo} ago</Trans>
|
||||||
Last initiated {timeAgo} ago
|
|
||||||
</Trans>
|
|
||||||
)}
|
)}
|
||||||
</Text>
|
</Text>
|
||||||
) : (
|
) : (
|
||||||
<Text
|
<Text
|
||||||
style={[
|
style={[a.text_sm, a.italic, t.atoms.text_contrast_medium]}>
|
||||||
a.text_sm,
|
<Trans>Age assurance only takes a few minutes</Trans>
|
||||||
a.italic,
|
|
||||||
t.atoms.text_contrast_medium,
|
|
||||||
]}>
|
|
||||||
<Trans>
|
|
||||||
Age assurance only takes a few
|
|
||||||
minutes
|
|
||||||
</Trans>
|
|
||||||
</Text>
|
</Text>
|
||||||
)}
|
)}
|
||||||
</View>
|
</View>
|
||||||
@@ -266,9 +234,7 @@ function RegionNotice() {
|
|||||||
<DeviceLocationRequestDialog
|
<DeviceLocationRequestDialog
|
||||||
control={locationControl}
|
control={locationControl}
|
||||||
onLocationAcquired={props => {
|
onLocationAcquired={props => {
|
||||||
const access = computeAgeAssuranceRegionAccess(
|
const access = computeAgeAssuranceRegionAccess(props.geolocation)
|
||||||
props.geolocation,
|
|
||||||
)
|
|
||||||
if (access !== aa.Access.Full) {
|
if (access !== aa.Access.Full) {
|
||||||
props.disableDialogAction()
|
props.disableDialogAction()
|
||||||
props.setDialogError(
|
props.setDialogError(
|
||||||
@@ -292,20 +258,14 @@ function RegionNotice() {
|
|||||||
{isGPS ? (
|
{isGPS ? (
|
||||||
<Trans>
|
<Trans>
|
||||||
Based on your device's location, we think you're in{' '}
|
Based on your device's location, we think you're in{' '}
|
||||||
<Text style={[a.text_sm, a.font_bold]}>
|
<Text style={[a.text_sm, a.font_bold]}>{region}</Text>. This
|
||||||
{region}
|
estimate may be inaccurate if you're using a VPN.
|
||||||
</Text>
|
|
||||||
. This estimate may be inaccurate if you're using a
|
|
||||||
VPN.
|
|
||||||
</Trans>
|
</Trans>
|
||||||
) : (
|
) : (
|
||||||
<Trans>
|
<Trans>
|
||||||
Based on your network, we think you're in{' '}
|
Based on your network, we think you're in{' '}
|
||||||
<Text style={[a.text_sm, a.font_bold]}>
|
<Text style={[a.text_sm, a.font_bold]}>{region}</Text>. This
|
||||||
{region}
|
estimate may be inaccurate if you're using a VPN.
|
||||||
</Text>
|
|
||||||
. This estimate may be inaccurate if you're using a
|
|
||||||
VPN.
|
|
||||||
</Trans>
|
</Trans>
|
||||||
)}
|
)}
|
||||||
</Text>
|
</Text>
|
||||||
|
|||||||
Reference in New Issue
Block a user