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

Only sync bookmarks & control settings between tabs. #184

Merged
merged 2 commits into from
Sep 22, 2023
Merged
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
14 changes: 9 additions & 5 deletions src/stores/user-store.ts
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ export const useUserStore = defineStore("user", {
activeModel: defaultActiveAvatarId()
},
persistentStorageMedium,
{ mergeDefaults: true }
{ mergeDefaults: true, listenToStorageChanges: false }
),
// Graphics configuration.
graphics: useStorage(
Expand All @@ -103,7 +103,7 @@ export const useUserStore = defineStore("user", {
cameraBobbing: true
},
persistentStorageMedium,
{ mergeDefaults: true }
{ mergeDefaults: true, listenToStorageChanges: false }
),
// Information about the logged in account. Refer to Account module.
account: useStorage(
Expand All @@ -124,7 +124,7 @@ export const useUserStore = defineStore("user", {
}
},
persistentStorageMedium,
{ mergeDefaults: true }
{ mergeDefaults: true, listenToStorageChanges: false }
),
// Saved bookmarks.
bookmarks: useStorage(
Expand All @@ -133,10 +133,14 @@ export const useUserStore = defineStore("user", {
locations: [] as Array<LocationBookmark>
},
persistentStorageMedium,
{ mergeDefaults: true }
{ mergeDefaults: true, listenToStorageChanges: true }
),
// Controls.
controls: useStorage("userControlSettings", defaultControls, persistentStorageMedium, { mergeDefaults: true })
controls: useStorage("userControlSettings",
defaultControls,
persistentStorageMedium,
{ mergeDefaults: true, listenToStorageChanges: true }
)
}),

actions: {
Expand Down
Loading