A self-hostable bookmark-everything app (links, notes and images) with AI-based automatic tagging and full text search
fix(mobile): fix layout issues when Android bold text accessibility option is enabled (#2554)
Chris Engleffba00d9da77
diff --git a/apps/mobile/app/dashboard/(tabs)/(home)/index.tsx b/apps/mobile/app/dashboard/(tabs)/(home)/index.tsxindex ab9ae5ee..f8c0dca3 100644--- a/apps/mobile/app/dashboard/(tabs)/(home)/index.tsx+++ b/apps/mobile/app/dashboard/(tabs)/(home)/index.tsx@@ -121,7 +121,9 @@ export default function Home() {<Search size={16} color={styles?.color?.toString()} />)}/>- <Text className="text-muted">Search</Text>+ <Text className="flex-1 text-muted" numberOfLines={1}>+ Search+ </Text></Pressable>}/>diff --git a/apps/mobile/app/dashboard/(tabs)/(lists)/index.tsx b/apps/mobile/app/dashboard/(tabs)/(lists)/index.tsxindex 4c98ef2c..9ffc5a2f 100644--- a/apps/mobile/app/dashboard/(tabs)/(lists)/index.tsx+++ b/apps/mobile/app/dashboard/(tabs)/(lists)/index.tsx@@ -247,7 +247,7 @@ export default function Lists() {}));}}>- <Text>+ <Text className="mr-2 flex-1" numberOfLines={1}>{l.item.logo} {l.item.name}</Text></Pressable>@@ -259,7 +259,7 @@ export default function Lists() {className="flex-1"><Pressable className="flex flex-row items-center justify-between">- <Text className="shrink">+ <Text className="mr-2 flex-1" numberOfLines={1}>{l.item.logo} {l.item.name}</Text><View className="flex flex-row items-center">diff --git a/apps/mobile/app/dashboard/(tabs)/(settings)/index.tsx b/apps/mobile/app/dashboard/(tabs)/(settings)/index.tsxindex 2e76d7e3..53b0e604 100644--- a/apps/mobile/app/dashboard/(tabs)/(settings)/index.tsx+++ b/apps/mobile/app/dashboard/(tabs)/(settings)/index.tsx@@ -125,18 +125,18 @@ export default function Settings() {><View className="flex flex-row items-center justify-between gap-8 px-4 py-1"><Link asChild href="/dashboard/settings/theme" className="flex-1">- <Pressable className="flex flex-row justify-between">- <Text>Theme</Text>- <View className="flex flex-row items-center gap-2">- <Text className="text-muted-foreground">- {- { light: "Light", dark: "Dark", system: "System" }[- settings.theme- ]- }- </Text>- <ChevronRight />- </View>+ <Pressable className="flex flex-row items-center">+ <Text className="mr-2 flex-1" numberOfLines={1}>+ Theme+ </Text>+ <Text className="mr-1 text-muted-foreground" numberOfLines={1}>+ {+ { light: "Light", dark: "Dark", system: "System" }[+ settings.theme+ ]+ }+ </Text>+ <ChevronRight /></Pressable></Link></View>@@ -147,20 +147,20 @@ export default function Settings() {href="/dashboard/settings/bookmark-default-view"className="flex-1">- <Pressable className="flex flex-row justify-between">- <Text>Default Bookmark View</Text>- <View className="flex flex-row items-center gap-2">- {isSettingsLoading ? (- <ActivityIndicator size="small" />- ) : (- <Text className="text-muted-foreground">- {settings.defaultBookmarkView === "reader"- ? "Reader"- : "Browser"}- </Text>- )}- <ChevronRight />- </View>+ <Pressable className="flex flex-row items-center">+ <Text className="mr-2 flex-1" numberOfLines={1}>+ Default Bookmark View+ </Text>+ {isSettingsLoading ? (+ <ActivityIndicator size="small" />+ ) : (+ <Text className="mr-1 text-muted-foreground" numberOfLines={1}>+ {settings.defaultBookmarkView === "reader"+ ? "Reader"+ : "Browser"}+ </Text>+ )}+ <ChevronRight /></Pressable></Link></View>@@ -177,8 +177,10 @@ export default function Settings() {href="/dashboard/settings/reader-settings"className="flex-1">- <Pressable className="flex flex-row justify-between">- <Text>Reader Text Settings</Text>+ <Pressable className="flex flex-row items-center">+ <Text className="mr-2 flex-1" numberOfLines={1}>+ Reader Text Settings+ </Text><ChevronRight /></Pressable></Link>@@ -236,7 +238,7 @@ export default function Settings() {className="flex flex-row items-center px-4 py-1"onPress={logout}>- <Text className="text-destructive">Log Out</Text>+ <Text className="flex-1 text-destructive">Log Out</Text></Pressable><Divider orientation="horizontal" className="mx-6 my-1" /><Pressable@@ -247,7 +249,7 @@ export default function Settings() {{isDeleting ? (<ActivityIndicator size="small" />) : (- <Text className="text-destructive">Delete Account</Text>+ <Text className="flex-1 text-destructive">Delete Account</Text>)}</Pressable></View>@@ -315,22 +317,37 @@ export default function Settings() {style={{ borderCurve: "continuous" }}><View className="flex flex-row items-center justify-between px-4 py-1">- <Text className="text-muted-foreground">Server</Text>- <Text className="text-sm text-muted-foreground">+ <Text className="text-muted-foreground" numberOfLines={1}>+ Server+ </Text>+ <Text+ className="flex-1 text-right text-sm text-muted-foreground"+ numberOfLines={1}+ >{isSettingsLoading ? "Loading..." : settings.address}</Text></View><Divider orientation="horizontal" className="mx-6 my-1" /><View className="flex flex-row items-center justify-between px-4 py-1">- <Text className="text-muted-foreground">App Version</Text>- <Text className="text-sm text-muted-foreground">+ <Text className="w-fit text-muted-foreground" numberOfLines={1}>+ App Version+ </Text>+ <Text+ className="flex-1 text-right text-sm text-muted-foreground"+ numberOfLines={1}+ >{Constants.expoConfig?.version ?? "unknown"}</Text></View><Divider orientation="horizontal" className="mx-6 my-1" /><View className="flex flex-row items-center justify-between px-4 py-1">- <Text className="text-muted-foreground">Server Version</Text>- <Text className="text-sm text-muted-foreground">+ <Text className="text-muted-foreground" numberOfLines={1}>+ Server Version+ </Text>+ <Text+ className="flex-1 text-right text-sm text-muted-foreground"+ numberOfLines={1}+ >{isServerVersionLoading? "Loading...": serverVersionErrordiff --git a/apps/mobile/app/dashboard/bookmarks/[slug]/info.tsx b/apps/mobile/app/dashboard/bookmarks/[slug]/info.tsxindex 19b49021..6a6a4498 100644--- a/apps/mobile/app/dashboard/bookmarks/[slug]/info.tsx+++ b/apps/mobile/app/dashboard/bookmarks/[slug]/info.tsx@@ -446,7 +446,7 @@ const ViewBookmarkPage = () => {disabled={isDeletionPending}className="items-center px-4 py-3 active:opacity-70">- <Text className="text-destructive">+ <Text className="text-destructive" numberOfLines={1}>{isDeletionPending ? "Deleting..." : "Delete Bookmark"}</Text></Pressable>diff --git a/apps/mobile/app/dashboard/settings/bookmark-default-view.tsx b/apps/mobile/app/dashboard/settings/bookmark-default-view.tsxindex c791493b..ae2576cf 100644--- a/apps/mobile/app/dashboard/settings/bookmark-default-view.tsx+++ b/apps/mobile/app/dashboard/settings/bookmark-default-view.tsx@@ -38,10 +38,12 @@ export default function BookmarkDefaultViewSettings() {return [<PressableonPress={() => handleUpdate(mode)}- className="flex flex-row justify-between"+ className="flex flex-row items-center justify-between"key={mode}>- <Text>{{ browser: "Browser", reader: "Reader" }[mode]}</Text>+ <Text className="mr-2 flex-1" numberOfLines={1}>+ {{ browser: "Browser", reader: "Reader" }[mode]}+ </Text>{isChecked && <Check color="rgb(0, 122, 255)" />}</Pressable>,<Dividerdiff --git a/apps/mobile/app/dashboard/settings/theme.tsx b/apps/mobile/app/dashboard/settings/theme.tsxindex b1599bc3..a98ca4a9 100644--- a/apps/mobile/app/dashboard/settings/theme.tsx+++ b/apps/mobile/app/dashboard/settings/theme.tsx@@ -13,10 +13,10 @@ export default function ThemePage() {return [<PressableonPress={() => setSettings({ ...settings, theme })}- className="flex flex-row justify-between"+ className="flex flex-row items-center justify-between"key={theme}>- <Text>+ <Text className="mr-2 flex-1" numberOfLines={1}>{{ light: "Light Mode", dark: "Dark Mode", system: "System" }[themediff --git a/apps/mobile/components/bookmarks/TagPill.tsx b/apps/mobile/components/bookmarks/TagPill.tsxindex 2097daab..deda55c8 100644--- a/apps/mobile/components/bookmarks/TagPill.tsx+++ b/apps/mobile/components/bookmarks/TagPill.tsx@@ -16,11 +16,17 @@ export default function TagPill({className="rounded-full border border-input px-2.5 py-0.5 text-xs font-semibold">{clickable ? (- <Link className="text-foreground" href={`dashboard/tags/${tag.id}`}>+ <Link+ className="text-foreground"+ numberOfLines={1}+ href={`dashboard/tags/${tag.id}`}+ >{tag.name}</Link>) : (- <Text className="text-foreground">{tag.name}</Text>+ <Text className="text-foreground" numberOfLines={1}>+ {tag.name}+ </Text>)}</View>);diff --git a/apps/mobile/components/ui/EmptyState.tsx b/apps/mobile/components/ui/EmptyState.tsxindex 44eb376a..326f5027 100644--- a/apps/mobile/components/ui/EmptyState.tsx+++ b/apps/mobile/components/ui/EmptyState.tsx@@ -18,13 +18,26 @@ export default function EmptyState({return (<Animated.Viewentering={FadeIn.duration(400)}- className="items-center justify-center py-12"+ style={{+ width: "100%",+ paddingHorizontal: 16,+ paddingVertical: 48,+ alignItems: "center",+ justifyContent: "center",+ }}><View className="mb-4 h-20 w-20 items-center justify-center rounded-full bg-primary/10"><Icon size={36} color={colors.primary} /></View>- <Text variant="title3">{title}</Text>- <Text className="mt-1 text-center text-muted-foreground">{subtitle}</Text>+ <Text variant="title3" style={{ textAlign: "center", width: "100%" }}>+ {title}+ </Text>+ <Text+ style={{ textAlign: "center", width: "100%", marginTop: 4 }}+ className="text-muted-foreground"+ >+ {subtitle}+ </Text></Animated.View>);}diff --git a/apps/mobile/components/ui/GroupedList.tsx b/apps/mobile/components/ui/GroupedList.tsxindex c36b7cba..037f9f3c 100644--- a/apps/mobile/components/ui/GroupedList.tsx+++ b/apps/mobile/components/ui/GroupedList.tsx@@ -59,7 +59,9 @@ function NavigationRow({onPress={onPress}className="flex-row items-center justify-between px-4 py-3 active:opacity-70">- <Text>{label}</Text>+ <Text className="flex-1" numberOfLines={1}>+ {label}+ </Text><ChevronRight size={16} /></Pressable>);