Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Various fixes #29

Merged
merged 4 commits into from
Dec 13, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 5 additions & 10 deletions src/components/ProgressExplainerModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import { WrapModal } from "./WrapModal";
import tw from "@src/utils/tailwind";
import { UiButton } from "@src/components/UiButton";

type Steps = 1 | 2 | 3 | 4;
type Steps = 1 | 2 | 3;

const stepsImages: Record<
Steps,
Expand All @@ -21,7 +21,7 @@ const stepsImages: Record<
1: {
image: require("@assets/onboading/favorite-domain.png"),
text: () =>
t`Click the star icon to select your favorite profile. Keep track of your main profile's completion progress with the profile completion bar.`,
t`Click the star icon to select your favorite profile. Keep track of your favorite profile's completion progress with the profile completion bar.`,
icon: <AntDesign name="star" size={24} color={tw.color("brand-primary")} />,
},
2: {
Expand All @@ -43,11 +43,6 @@ const stepsImages: Record<
t`Add a profile pic that represents you. It can be a photo of yourself, your favourite NFT or something that inspires you.`,
icon: <Ionicons name="camera-sharp" size={24} color="#F391BD" />,
},
4: {
image: require("@assets/onboading/connect-backpack.png"),
text: () => t`Connect your backpack username to your on-chain identity.`,
icon: <MaterialIcons name="backpack" size={24} color="#E20505" />,
},
};

export const ProgressExplainerModal = ({
Expand All @@ -72,14 +67,14 @@ export const ProgressExplainerModal = ({
<View style={tw`flex flex-row items-start gap-2 mt-2`}>
{stepsImages[currentStep].icon}

<Text style={tw`text-sm font-medium`}>
<Text style={tw`text-sm font-medium text-center`}>
{stepsImages[currentStep].text()}
</Text>
</View>
</View>

<View style={tw`flex flex-row justify-center mt-4`}>
{new Array(4).fill(0).map((_, i) => (
{new Array(3).fill(0).map((_, i) => (
<TouchableOpacity
key={i}
onPress={() => {
Expand All @@ -105,7 +100,7 @@ export const ProgressExplainerModal = ({
</TouchableOpacity>

<View style={tw`flex-initial`}>
{currentStep === 4 ? (
{currentStep === 3 ? (
<UiButton onPress={closeModal} content={t`Close`} />
) : (
<UiButton
Expand Down
3 changes: 2 additions & 1 deletion src/screens/HomeScreen.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,8 @@ function HomeRoot() {
</Text>
</View>
<CustomTextInput
onChangeText={(newText) => setSearch(newText)}
autoCapitalize="none"
onChangeText={(newText) => setSearch(newText.toLowerCase())}
value={search}
placeholder={t`Search for a domain`}
type="search"
Expand Down
3 changes: 2 additions & 1 deletion src/screens/SearchResult.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,8 @@ export const SearchResult = ({
<Screen>
<ScrollView showsHorizontalScrollIndicator={false}>
<CustomTextInput
onChangeText={(newText) => setInput(newText)}
autoCapitalize="none"
onChangeText={(newText) => setSearch(newText.toLowerCase())}
value={input}
placeholder={t`Search for a domain`}
type="search"
Expand Down
Loading