feat: preferences syncing frontend (#7192)

* feat: prefs frontend

* fix: DI issue

* fix: lint

* feat: appearance settings cleanup + fix settings, remove pinia

* fix: sync btn when logged out

* fix: prepr

* fix: sidebar issue

* feat: language coverage + cleanup

* feat: cleanup lang settings

* fix: fmt

* fix: CI

* fix: ci

* fix: storybook

* feat: bring back loader/game version sort

---------

Co-authored-by: tdgao <mr.trumgao@gmail.com>
This commit is contained in:
Calum H.
2026-08-20 07:23:01 +00:00
committed by GitHub
co-authored by tdgao
parent 79fcf41316
commit 3e07267e10
191 changed files with 3356 additions and 4372 deletions
@@ -36,6 +36,8 @@ export const librarySortOptions = [
'Hours played',
'Date created',
'Date modified',
'Loader',
'Game version',
] as const
export const libraryGroupOptions = [
@@ -328,6 +330,18 @@ function createLibraryState(instances: Ref<GameInstance[]>) {
case 'Name':
visibleInstances.sort((a, b) => a.name.localeCompare(b.name))
break
case 'Loader':
visibleInstances.sort((a, b) =>
formatLoader(formatMessage, a.loader).localeCompare(
formatLoader(formatMessage, b.loader),
),
)
break
case 'Game version':
visibleInstances.sort((a, b) =>
a.game_version.localeCompare(b.game_version, undefined, { numeric: true }),
)
break
case 'Last played':
visibleInstances.sort((a, b) => dayjs(b.last_played ?? 0).diff(dayjs(a.last_played ?? 0)))
break