Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(settings): sync auto-settle and other shared preferences across environments #9147

Mergedt3dotgg(GitHub profile, opens in a new tab)merged 3 commits intomain fromrefs/pull/9147/headmerged by t3dotgg(GitHub profile, opens in a new tab) View on GitHub

Showing 10 changed files with 162 additions and 33 deletions (loading 7).

x
0 of 10 viewed, 10 left
128 additions and 33 deletionsapps/mobile/src/features/settings/SettingsRouteScreen.tsxModified
View file
@@ -19,7 +19,7 @@
squashAtomCommandFailure,
} from "@t3tools/client-runtime/state/runtime";
import { AndroidScreenHeader } from "../../components/AndroidScreenHeader";
-import { AppText as Text } from "../../components/AppText";
+import { AppText as Text, AppTextInput as TextInput } from "../../components/AppText";
import { supportsAgentAwarenessPush } from "../agent-awareness/capabilities";
import { setLiveActivityUpdatesEnabled } from "../agent-awareness/liveActivityPreferences";
import { requestAgentNotificationPermission } from "../agent-awareness/notificationPermissions";
@@ -36,7 +36,17 @@
import { mobilePreferencesAtom, updateMobilePreferencesAtom } from "../../state/preferences";
import { serverEnvironment } from "../../state/server";
import { useAtomCommand } from "../../state/use-atom-command";
-import type { EnvironmentId } from "@t3tools/contracts";
+import { useEnvironments } from "../../state/environments";
+import {
+ DEFAULT_SERVER_SETTINGS,
+ MAX_SIDEBAR_AUTO_SETTLE_AFTER_DAYS,
+ MIN_SIDEBAR_AUTO_SETTLE_AFTER_DAYS,
+ type ServerSettingsPatch,
+} from "@t3tools/contracts";
+import {
+ findSharedSettingsMismatches,
+ pickSharedServerSettings,
+} from "@t3tools/client-runtime/state/shared-settings";
import { useThreadListV2Enabled } from "../threads/use-thread-list-v2-enabled";
import {
type AppUpdateCheckState,