Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 | import NfcIcon from "@mui/icons-material/Nfc"; import PhonelinkSetupIcon from "@mui/icons-material/PhonelinkSetup"; import TipsAndUpdatesIcon from "@mui/icons-material/TipsAndUpdates"; import { Box, Container, Divider, List, ListItem, Typography, } from "@mui/material"; import { useMutation } from "@tanstack/react-query"; import Alert from "components/Alert"; import Button from "components/Button"; import HtmlMeta from "components/HtmlMeta"; import { OpenInNewIcon } from "components/Icons"; import PageTitle from "components/PageTitle"; import StyledLink from "components/StyledLink"; import { RpcError } from "grpc-web"; import { Trans, useTranslation } from "i18n"; import { AUTH, GLOBAL } from "i18n/namespaces"; import { InitiateStrongVerificationRes } from "proto/account_pb"; import { service } from "service"; import { theme } from "theme"; import { useIsNativeEmbed } from "utils/nativeLink"; export default function StrongVerificationInstructions() { const { t, i18n: { language: locale }, } = useTranslation([GLOBAL, AUTH]); const isNativeEmbed = useIsNativeEmbed(); const { error, isPending, mutate: startStrongVerification, } = useMutation<InitiateStrongVerificationRes.AsObject, RpcError>({ mutationFn: () => service.account.initiateStrongVerification(), onSuccess: async (data) => { if (isNativeEmbed) { // In the WebView, window.open() is unreliable. Using location.href // triggers handleShouldStartLoad which opens the URL in the system // browser via Linking.openURL() while keeping the WebView in place. window.location.href = data.redirectUrl; } else { // Open Iris ID in a new tab so user can keep these instructions open window.open(data.redirectUrl, "_blank"); } }, }); return ( <> <HtmlMeta title={t("auth:strong_verification.title")} /> <Container maxWidth="md" sx={{ marginTop: theme.spacing(3) }}> <PageTitle>{t("auth:strong_verification.title")}</PageTitle> <Alert severity="warning" sx={{ marginBottom: theme.spacing(3) }}> {t("auth:strong_verification.instructions.warning")} </Alert> <Box sx={{ backgroundColor: "var(--mui-palette-grey-50)", borderRadius: theme.shape.borderRadius, padding: theme.spacing(3), marginBottom: theme.spacing(3), marginTop: theme.spacing(3), }} > <Box sx={{ display: "flex", alignItems: "center", gap: theme.spacing(1), marginBottom: theme.spacing(1), }} > <PhonelinkSetupIcon sx={{ fontSize: 28, color: "var(--mui-palette-primary-main)" }} /> <Typography variant="h3"> {t( "auth:strong_verification.instructions.before_you_start.heading", )} </Typography> </Box> <Box component="ul" sx={{ marginTop: theme.spacing(1), marginBottom: 0, paddingLeft: theme.spacing(3), "& li": { marginBottom: theme.spacing(1) }, }} > <li> <Trans i18nKey="auth:strong_verification.instructions.before_you_start.nfc_check"> Your phone must have <strong>NFC capability</strong> — most phones do. Check your phone settings to make sure NFC is turned on. </Trans> </li> <li> <Trans i18nKey="auth:strong_verification.instructions.before_you_start.passport_check"> Your passport must be a <strong>biometric passport</strong> — look for the gold chip symbol on the cover. Older passports without this symbol won't work. </Trans> </li> <li> <Trans i18nKey="auth:strong_verification.instructions.before_you_start.remove_case"> <strong>Remove your phone case before starting</strong> — even thin cases can block the NFC signal and cause the scan to fail. </Trans> </li> </Box> </Box> <Typography variant="h2" sx={{ marginBottom: theme.spacing(2), marginTop: theme.spacing(3) }} > {t("auth:strong_verification.instructions.title")} </Typography> <List sx={{ listStyleType: "decimal", paddingLeft: theme.spacing(3), marginBottom: theme.spacing(4), }} > <ListItem sx={{ display: "list-item", paddingY: 0.5 }}> <Typography variant="body1" sx={{ marginBottom: 1 }}> <Trans i18nKey="auth:strong_verification.instructions.step1"> Download the <strong>IRIS ID</strong> app </Trans> </Typography> <Typography variant="body2" color="text.secondary" sx={{ marginTop: 1, marginBottom: 1 }} > <Trans i18nKey="auth:strong_verification.instructions.step1_apple_note"> <strong>Apple users:</strong> You can skip the download and use your browser instead. Just click "Open" when prompted. </Trans> </Typography> <Box sx={{ display: "flex", gap: 0, marginTop: 1, flexWrap: "wrap", alignItems: "center", }} > <a href="https://apps.apple.com/app/id1575142357" target="_blank" rel="noopener noreferrer" > <img src={`/img/app-store-badge/${locale}.svg`} alt={t( "auth:strong_verification.instructions.download_app_store", )} style={{ height: "30px", width: "auto" }} /> </a> <a href="https://play.google.com/store/apps/details?id=seismic.rarity" target="_blank" rel="noopener noreferrer" > <img src={`/img/google-play-badge/${locale}.svg`} alt={t( "auth:strong_verification.instructions.download_google_play", )} style={{ height: "30px", width: "auto" }} /> </a> </Box> </ListItem> <ListItem sx={{ display: "list-item", paddingY: 0.5 }}> <Typography variant="body1"> <Trans i18nKey="auth:strong_verification.instructions.step2"> Click <strong>"Start Strong Verification"</strong> below (opens in new tab) </Trans> </Typography> </ListItem> <ListItem sx={{ display: "list-item", paddingY: 0.5 }}> <Typography variant="body1"> {t("auth:strong_verification.instructions.step3")} </Typography> </ListItem> <ListItem sx={{ display: "list-item", paddingY: 0.5 }}> <Typography variant="body1"> {t("auth:strong_verification.instructions.step4")} </Typography> </ListItem> <ListItem sx={{ display: "list-item", paddingY: 0.5 }}> <Typography variant="body1"> <Trans i18nKey="auth:strong_verification.instructions.step5"> Select <strong>Passport</strong> (ID cards not supported) </Trans> </Typography> </ListItem> <ListItem sx={{ display: "list-item", paddingY: 0.5 }}> <Typography variant="body1"> {t("auth:strong_verification.instructions.step6")} </Typography> </ListItem> <ListItem sx={{ display: "list-item", paddingY: 0.5 }}> <Typography variant="body1"> <Trans i18nKey="auth:strong_verification.instructions.step7"> Hold your phone against the passport page with the NFC chip and <strong>keep completely still for at least 5 seconds</strong> — moving too early is the most common cause of failure </Trans> </Typography> </ListItem> <ListItem sx={{ display: "list-item", paddingY: 0.5 }}> <Typography variant="body1"> {t("auth:strong_verification.instructions.step8")} </Typography> </ListItem> </List> <Box sx={{ backgroundColor: "var(--mui-palette-grey-50)", borderRadius: theme.shape.borderRadius, padding: theme.spacing(3), marginBottom: theme.spacing(4), marginTop: theme.spacing(4), }} > <Box sx={{ display: "flex", alignItems: "center", gap: theme.spacing(1), marginBottom: theme.spacing(1), }} > <NfcIcon sx={{ fontSize: 28, color: "var(--mui-palette-primary-main)" }} /> <Typography variant="h3"> {t("auth:strong_verification.instructions.chip_location.heading")} </Typography> </Box> <Typography variant="body1" sx={{ marginBottom: theme.spacing(1) }}> {t( "auth:strong_verification.instructions.chip_location.description", )} </Typography> <Box component="ul" sx={{ marginTop: theme.spacing(1), marginBottom: 0, paddingLeft: theme.spacing(3), }} > <li> <Trans i18nKey="auth:strong_verification.instructions.chip_location.us_germany_mexico"> <strong>US, Germany (2016), Mexico:</strong> Back page </Trans> </li> <li> <Trans i18nKey="auth:strong_verification.instructions.chip_location.finland_germany_new"> <strong>Finland, Germany (2017+):</strong> Picture page </Trans> </li> <li> <Trans i18nKey="auth:strong_verification.instructions.chip_location.australia"> <strong>Australia:</strong> Middle page (marked with symbol + "chip name") </Trans> </li> </Box> </Box> <Box sx={{ backgroundColor: "var(--mui-palette-grey-50)", borderRadius: theme.shape.borderRadius, padding: theme.spacing(3), marginBottom: theme.spacing(4), }} > <Box sx={{ display: "flex", alignItems: "center", gap: theme.spacing(1), marginBottom: theme.spacing(1), }} > <TipsAndUpdatesIcon sx={{ fontSize: 28, color: "var(--mui-palette-primary-main)" }} /> <Typography variant="h3"> {t("auth:strong_verification.instructions.scanning_tips.heading")} </Typography> </Box> <Typography variant="body1" sx={{ marginBottom: theme.spacing(1) }}> {t( "auth:strong_verification.instructions.scanning_tips.description", )} </Typography> <Box component="ul" sx={{ marginTop: theme.spacing(1), marginBottom: 0, paddingLeft: theme.spacing(3), "& li": { marginBottom: theme.spacing(1) }, }} > <li> <Trans i18nKey="auth:strong_verification.instructions.scanning_tips.remove_case"> <strong>Remove your phone case</strong> — even thin cases can block the NFC signal </Trans> </li> <li> <Trans i18nKey="auth:strong_verification.instructions.scanning_tips.hold_still"> <strong>Hold your phone completely still</strong> for at least 5 seconds — moving too early is the most common cause of failure </Trans> </li> <li> <Trans i18nKey="auth:strong_verification.instructions.scanning_tips.flat_surface"> <strong>Place your passport on a flat surface</strong> — don't hold it in your hand </Trans> </li> <li> <Trans i18nKey="auth:strong_verification.instructions.scanning_tips.nfc_location"> <strong>Find your phone's NFC antenna</strong> — it's usually near the top-center on the back of the phone. Try different positions if it doesn't connect </Trans> </li> <li> <Trans i18nKey="auth:strong_verification.instructions.scanning_tips.no_metal"> <strong>Avoid metal surfaces</strong> — don't place your passport on a metal table or laptop </Trans> </li> <li> {t("auth:strong_verification.instructions.scanning_tips.retry")} </li> </Box> </Box> <Divider sx={{ marginBottom: theme.spacing(3) }} /> <Box sx={{ marginBottom: theme.spacing(4) }}> <Typography variant="h2" sx={{ marginBottom: theme.spacing(2) }}> {t("auth:strong_verification.instructions.didnt_work.heading")} </Typography> <Box component="ul" sx={{ paddingLeft: theme.spacing(3), "& li": { marginBottom: theme.spacing(1) }, }} > <li> {t("auth:strong_verification.instructions.didnt_work.tip1")} </li> <li> {t("auth:strong_verification.instructions.didnt_work.tip2")} </li> <li> {t("auth:strong_verification.instructions.didnt_work.tip3")} </li> <li> {t("auth:strong_verification.instructions.didnt_work.tip4")} </li> </Box> <Typography variant="body1"> <Trans i18nKey="auth:strong_verification.instructions.didnt_work.contact"> If you're still having trouble, <StyledLink href="mailto:support@couchers.org?subject=Strong%20Verification%20Help"> let us know </StyledLink> and we'll help. </Trans> </Typography> </Box> {error && ( <Alert severity="error" sx={{ marginBottom: theme.spacing(2) }}> {error.message} </Alert> )} <Box sx={{ display: "flex", justifyContent: "center", marginBottom: theme.spacing(4), }} > <Button onClick={startStrongVerification} loading={isPending} size="large" endIcon={<OpenInNewIcon />} > {t("auth:strong_verification.start_button")} </Button> </Box> </Container> </> ); } |