-
Notifications
You must be signed in to change notification settings - Fork 4
sync: port upstream project grouping and sidebar polish (#4313–#4396) #186
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
Changes from all commits
a4de534
ed345fd
c89cc42
b675aaa
f2ece7b
79516cd
b185aa3
3070ebf
67e6e3e
eda7d63
54edffa
c13f805
0513b4e
0ba2135
2819489
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -11,9 +11,12 @@ import { createStaticNavigation, DarkTheme, DefaultTheme } from "@react-navigati | |
| import { RegistryContext } from "@effect/atom-react"; | ||
| import { ConfirmDialogHost } from "./components/ConfirmDialogHost"; | ||
| import { CloudAuthProvider } from "./features/cloud/CloudAuthProvider"; | ||
| import { IncomingShareProvider } from "./features/sharing/IncomingShareProvider"; | ||
| import { prepareNativeShowcaseCapture } from "./features/showcase/nativeShowcaseScene"; | ||
| import { AppearancePreferencesProvider } from "./features/settings/appearance/AppearancePreferencesProvider"; | ||
| import { IncomingShareProvider } from "./features/sharing/IncomingShareProvider"; | ||
| import { | ||
| AppearancePreferencesProvider, | ||
| useAppearancePreferences, | ||
| } from "./features/settings/appearance/AppearancePreferencesProvider"; | ||
| import { RootStack } from "./Stack"; | ||
| import { appAtomRegistry } from "./state/atom-registry"; | ||
| import { OverlayPortalHost } from "./components/OverlayPortal"; | ||
|
|
@@ -26,6 +29,10 @@ if (process.env.EXPO_PUBLIC_SHOWCASE === "1") { | |
| prepareNativeShowcaseCapture(); | ||
| } | ||
|
|
||
| void SplashScreen.preventAutoHideAsync().catch(() => { | ||
| // The native module can be unavailable in non-native test environments. | ||
| }); | ||
|
|
||
| const appLinking = { | ||
| prefixes: [Linking.createURL("/"), "t3code://", "t3code-dev://", "t3code-preview://"], | ||
| // The Expo dev client launches the app via | ||
|
|
@@ -40,18 +47,25 @@ const appLinking = { | |
|
|
||
| const Navigation = createStaticNavigation(RootStack); | ||
|
|
||
| function SplashScreenCoordinator() { | ||
| const { isReady } = useAppearancePreferences(); | ||
|
|
||
| useEffect(() => { | ||
| if (isReady) void SplashScreen.hide(); | ||
| }, [isReady]); | ||
|
Comment on lines
+50
to
+55
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🩺 Stability & Availability | 🟠 Major | ⚡ Quick win Handle preference-load failures before gating splash dismissal.
🤖 Prompt for AI Agents |
||
|
|
||
| return null; | ||
| } | ||
|
|
||
| export default function App() { | ||
| const colorScheme = useColorScheme(); | ||
| const statusBarBg = useThemeColor("--color-status-bar"); | ||
|
|
||
| useEffect(() => { | ||
| SplashScreen.hide(); | ||
| }, []); | ||
|
|
||
| return ( | ||
| <RegistryContext.Provider value={appAtomRegistry}> | ||
| <CloudAuthProvider> | ||
| <AppearancePreferencesProvider> | ||
| <SplashScreenCoordinator /> | ||
| <GestureHandlerRootView className="flex-1"> | ||
| <KeyboardProvider statusBarTranslucent> | ||
| <SafeAreaProvider> | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After a user switches from Light or Dark to System, sending a
prefers-color-schemefeature with an empty value does not remove that feature override; it emulates an invalid/no-preference value, so the page may match neither its light nor dark query instead of following the OS. Clear the override by sending an emptyfeaturesarray for System.Useful? React with 👍 / 👎.