diff --git a/eslint-suppressions.json b/eslint-suppressions.json index 3cdac1d101..2e323dd73e 100644 --- a/eslint-suppressions.json +++ b/eslint-suppressions.json @@ -1430,11 +1430,6 @@ "count": 1 } }, - "src/screens/Signup/StepHandle/index.tsx": { - "@typescript-eslint/no-misused-promises": { - "count": 1 - } - }, "src/screens/Signup/StepInfo/Policies.tsx": { "@typescript-eslint/no-explicit-any": { "count": 1 diff --git a/src/screens/Signup/StepHandle/HandleSuggestions.tsx b/src/screens/Signup/StepHandle/HandleSuggestions/index.native.tsx similarity index 74% rename from src/screens/Signup/StepHandle/HandleSuggestions.tsx rename to src/screens/Signup/StepHandle/HandleSuggestions/index.native.tsx index 0b7c0fb93e..1dfb15e955 100644 --- a/src/screens/Signup/StepHandle/HandleSuggestions.tsx +++ b/src/screens/Signup/StepHandle/HandleSuggestions/index.native.tsx @@ -1,25 +1,23 @@ import Animated, {Easing, FadeInDown, FadeOut} from 'react-native-reanimated' -import {type ComAtprotoTempCheckHandleAvailability} from '@atproto/api' -import {msg} from '@lingui/core/macro' -import {useLingui} from '@lingui/react' -import {Trans} from '@lingui/react/macro' +import {Trans, useLingui} from '@lingui/react/macro' import {atoms as a, native, useTheme} from '#/alf' import {borderRadius} from '#/alf/tokens' import {Button} from '#/components/Button' import {Text} from '#/components/Typography' +import {type HandleSuggestionsProps} from './shared' +/** + * Native: suggestions render inline beneath the availability error, animating + * in with the surrounding requirement stack. See index.tsx for the web variant, + * which floats them in a Sift dropdown anchored to the input. + */ export function HandleSuggestions({ suggestions, onSelect, -}: { - suggestions: ComAtprotoTempCheckHandleAvailability.Suggestion[] - onSelect: ( - suggestions: ComAtprotoTempCheckHandleAvailability.Suggestion, - ) => void -}) { +}: HandleSuggestionsProps) { const t = useTheme() - const {_} = useLingui() + const {t: l} = useLingui() return ( {suggestions.map((suggestion, index) => (