A fully open source & end-to-end encrypted note taking alternative to Evernote.
TypeScript asp-net-coredotnet-coreelectronfosshacktoberfestnote-managmentnote-takingnote-taking-appnotebooknotesnotes-appopen-sourceopensourceprivacyproductivityreactreact-nativereactjsself-hosted
fix delay in header state update
ammarahm-eda3c9d3851ee5
diff --git a/apps/mobile/src/components/container/index.js b/apps/mobile/src/components/container/index.jsindex aa067527c..647ccb0c9 100644--- a/apps/mobile/src/components/container/index.js+++ b/apps/mobile/src/components/container/index.js@@ -1,6 +1,5 @@import React from 'react';import { KeyboardAvoidingView, Platform, SafeAreaView } from 'react-native';-import { useSafeAreaInsets } from 'react-native-safe-area-context';import useIsFloatingKeyboard from '../../utils/hooks/use-is-floating-keyboard';import { Header } from '../header';import SelectionHeader from '../selection-header';diff --git a/apps/mobile/src/navigation/navigationstack.js b/apps/mobile/src/navigation/navigationstack.jsindex cd8a01ba8..5b4afc32d 100644--- a/apps/mobile/src/navigation/navigationstack.js+++ b/apps/mobile/src/navigation/navigationstack.js@@ -72,7 +72,7 @@ export const NavigationStack = React.memo(});return (- <Container root={true}>+ <Container><NavigationContainer onStateChange={onStateChange} ref={rootNavigatorRef}><Tabs /></NavigationContainer>diff --git a/apps/mobile/src/screens/settings/appearance.js b/apps/mobile/src/screens/settings/appearance.jsindex b40615e22..ff23e02ab 100644--- a/apps/mobile/src/screens/settings/appearance.js+++ b/apps/mobile/src/screens/settings/appearance.js@@ -13,7 +13,6 @@ import { useSettingStore } from '../../stores/use-setting-store';import { useThemeStore } from '../../stores/use-theme-store';import { hexToRGBA, RGB_Linear_Shade, switchAccentColor } from '../../utils/color-scheme/utils';import { MenuItemsList } from '../../utils/constants';-import { tabBarRef } from '../../utils/global-refs';import { pv, SIZE } from '../../utils/size';export const HomagePageSelector = () => {diff --git a/apps/mobile/src/screens/settings/index.tsx b/apps/mobile/src/screens/settings/index.tsxindex 6d1024b9a..706424769 100644--- a/apps/mobile/src/screens/settings/index.tsx+++ b/apps/mobile/src/screens/settings/index.tsx@@ -1,16 +1,26 @@import { createNativeStackNavigator } from '@react-navigation/native-stack';import React from 'react';+import useNavigationStore from '../../stores/use-navigation-store';import { useThemeStore } from '../../stores/use-theme-store';import Group from './group';import Home from './home';const SettingsStack = createNativeStackNavigator();+const screenListeners = {+ //@ts-ignore+ beforeRemove: e => {+ if (e.target?.startsWith('SettingsGroup')) {+ useNavigationStore.getState().update({ name: 'Settings' }, false);+ }+ }+};export const Settings = () => {const colors = useThemeStore(state => state.colors);return (<SettingsStack.NavigatorinitialRouteName="SettingsHome"+ screenListeners={screenListeners}screenOptions={{animation: 'none',headerShown: false,@@ -20,13 +30,7 @@ export const Settings = () => {}}><SettingsStack.Screen name="SettingsHome" component={Home} />- <SettingsStack.Screen- options={{- animation: 'default'- }}- name="SettingsGroup"- component={Group}- />+ <SettingsStack.Screen name="SettingsGroup" component={Group} /></SettingsStack.Navigator>);};