Web application experience
The RomM web application is the browser workspace for setting up a server, finding games, playing them, and managing library data. It uses one Vue experience with route-based workspaces, shared server data, and account-aware actions so a user can move from setup to browsing, playback, media, device delivery, and administration. For internal boundaries, see Frontend application architecture. For browsing behavior, see Library browsing experience. For operator tasks, see Administration workflows.
Application composition
The application separates the browser-wide shell from the active route surface. This keeps identity, navigation, live work, and account feedback available while the main workspace changes.
Browser bootstrap
The browser starts by loading server health, configuration, the current user, and locale data before it mounts the application. This first state decides whether the user sees setup, authentication, or the signed-in product. frontend/…/main.ts and frontend/…/RomM.vue.
The root also owns concerns that must cover every route. Theme and language apply at the document level, while the connection banner can remain visible during setup, sign-in, or normal use. A stale lazy-loaded asset can trigger one guarded reload after a deployment so an old tab can recover its route.
References: frontend/…/main.ts• L20-35 frontend/…/main.ts• L57-105 frontend/…/RomM.vue• L21-65
Application shell
The main shell surrounds route content with background art, desktop and mobile navigation, global dialogs, the soundtrack mini-player, optional debug tools, and visual overlays. It also installs cross-route services for permissions, scans, notifications, save-sync conflicts, pending player assets, native launch feedback, input, and URL-backed route behavior. It hydrates shared platforms, collections, streaming settings, and permission state so a direct link has the same context as a link reached from Home. frontend/…/AppLayout.vue.
The shell also installs cross-route lifecycles. Scan progress, notification counts, save-sync conflicts, pending player assets, native launch feedback, and input support can therefore reach the user from any active route. When a player owns the screen, the shell removes normal navigation without losing the global services. The primary destinations share one route-to-tab model, while small screens move those destinations to a bottom bar. frontend/…/AppNav.vue, frontend/…/BottomNav.vue, and frontend/…/index.ts.
This diagram shows how server data and live events become shared browser context and then reach route workspaces.
flowchart TD
Server[RomM server] --> Requests[HTTP requests]
Server --> Events[Live events]
Requests --> State[Shared client state]
Events --> State
State --> Shell[Application shell]
State --> Routes[Route workspace]
Shell --> Navigation[Navigation and global feedback]
Routes --> Browse[Library browsing]
Routes --> Play[Playback and media]
Routes --> Deliver[Device delivery]
Routes --> Admin[Library and server administration]
References: frontend/…/AppLayout.vue• L48-82 frontend/…/AppLayout.vue• L153-200 frontend/…/AppLayout.vue• L216-236 frontend/…/AppNav.vue• L32-99 frontend/…/BottomNav.vue• L15-84 frontend/…/index.ts• L15-84
Route surfaces
The route map gives each product task a stable destination. Public routes cover setup, sign-in, password reset, registration, and device pairing. Signed-in routes cover Home, search, platforms, collections, game details, players, media tools, notifications, account settings, and server controls. frontend/…/routes.ts.
The route tree assigns a shared layout to each kind of surface. Authentication uses its own full-page layout. The signed-in product uses the application shell, and settings and library tools use a shared settings frame. Lazy route views keep direct links and normal navigation on the same named destinations.
Route guards apply setup state, authentication, permission scopes, and server feature flags to direct URLs as well as menu links. They preserve a requested destination through sign-in, allow cached navigation while the server is unreachable, keep same-path query changes in place, and provide a not-found view for unknown or unavailable routes. frontend/…/router.ts.
References: frontend/…/routes.ts• L1-75 frontend/…/router.ts• L41-215 frontend/…/router.ts• L202-385 frontend/…/router.ts• L433-500
Connection recovery
Connection feedback distinguishes server reachability from cached browser data. Cached pages can remain readable while the server is unavailable, but writes and fresh account checks wait for a working connection. The request layer treats successful responses and client errors as evidence that the backend is alive. It treats a missing response as offline and a non-heartbeat server error as a condition for heartbeat confirmation. Canceled reads do not change reachability. frontend/…/index.ts, frontend/…/heartbeat.ts, and frontend/…/BackendStatusBanner.vue.
After a real reconnect, the connection layer can refresh the page so setup, session, permissions, and route state start from confirmed server data. If a game is active, recovery waits until the player has left and cleanup work has settled.
References: frontend/…/index.ts• L53-113 frontend/…/heartbeat.ts• L96-137 frontend/…/router.ts• L433-447 frontend/…/index.ts• L47-121
Client data layer
The client data layer gives every route a shared view of the RomM server. It separates server records from view choices, user preferences, and active work so one surface can refresh without owning the whole application state.
Shared client state
Pinia stores hold server records and browser state for users, platforms, collections, games, filters, playback, notifications, devices, uploads, scans, conversions, and preferences. The server remains the authority for saved records and protected actions. Shared stores make changes reactive across Home, galleries, details, players, and settings. frontend/…/pinia.ts and the stores under frontend/src/stores/.
The main state groups have different jobs:
| State group | Role in the experience |
|---|---|
| Server data | Users, platforms, collections, games, media, devices, settings, and notifications. |
| View state | Search terms, filters, sort order, tabs, selections, and route context. |
| Work state | Upload, scan, conversion, delivery, task, notification, and play progress. |
| User preference | Language, theme, Home sections, gallery mode, playback choices, and display options. |
The heartbeat store reports confirmed server health and feature readiness. This includes the server's available emulation, device, conversion, metadata, and ROM patch support. The permissions store reports the signed-in user's effective grants after it loads them from the server. UI checks use these grants to shape visible actions, but the server still decides every protected read or write. frontend/…/heartbeat.ts, frontend/…/HeartbeatResponse.ts, and frontend/…/permissions.ts.
The notification inbox keeps the signed-in user's notices ordered while initial data loads and live changes arrive. Read and dismiss actions update the view at once and restore the prior state if the server rejects them. Changes that occur during a fetch are replayed onto that fetch's result, and a user reset prevents data from the prior account from being applied. frontend/…/notificationInbox.ts.
References: frontend/…/heartbeat.ts• L15-90 frontend/…/heartbeat.ts• L96-137 frontend/…/HeartbeatResponse.ts• L16-28 frontend/…/permissions.ts• L1-75 frontend/…/notificationInbox.ts• L21-89 frontend/…/notificationInbox.ts• L114-155 frontend/…/AppLayout.vue• L169-200
Server request flow
Feature API services turn user intent into requests to the RomM server. The shared request path handles session and CSRF needs, reports reachability, distinguishes permission failures from network failures, and returns expired sessions to sign-in with the intended destination. frontend/…/index.ts.
The request layer supports both short reads and continuing work. Uploads send game files and then start a scan. Downloads can wait for server-side format conversion. Save, state, and snapshot services can hand progress to the server during page exit when the browser can carry the request, while normal requests remain available for larger transfers. Live events and shared work state keep those operations visible after the initiating view changes. frontend/…/rom.ts, frontend/…/save.ts, frontend/…/state.ts, frontend/…/snapshot.ts, frontend/…/index.ts, and frontend/…/formatConversions.ts.
An optional read cache can show the last successful result while a new request runs and can combine equal requests. Gallery reads use one result context for counts, filter choices, and visible games so the view does not describe different result sets.
References: frontend/…/index.ts• L6-163 frontend/…/save.ts• L105-186 frontend/…/state.ts• L37-87 frontend/…/snapshot.ts• L141-189 frontend/…/rom.ts• L43-173 frontend/…/index.ts• L1-180 frontend/…/formatConversions.ts• L1-24
Gallery data model
The gallery store represents a large filtered result as a result context plus loaded windows. It keeps the total, filter data, ordering, and result identity available while it loads only the rows needed by the current view. This lets Home, platform galleries, collection galleries, and Search use the same browsing model without loading every game at once. frontend/…/galleryRoms.ts.
When the context changes, the store discards old windows and cancels work for the old result. Visible rows request the windows they need, while bounded retries recover transient failures. The URL carries search, filter, sort, view, tab, and selection intent so refresh, browser history, and shared links return to a useful state. Smart collections use the same filter language for creation and display, so a saved view keeps its route context and filter logic. frontend/…/smartCollectionCriteria.ts.
References: frontend/…/galleryRoms.ts• L1-15 frontend/…/galleryRoms.ts• L211-274 frontend/…/galleryRoms.ts• L345-385 frontend/…/galleryRoms.ts• L566-705 frontend/…/index.ts• L1-90 frontend/…/smartCollectionCriteria.ts• L120-239 frontend/…/smartCollectionCriteria.ts• L552-651
Live operation state
Live events connect server work to the shared client state. Scan completion, notification changes, permission updates, device delivery, save sync, conversion work, tasks, and active play can update their global indicators without requiring the user to stay on the initiating page. frontend/…/AppLayout.vue and frontend/…/index.ts.
Saves and states that cannot reach the server can wait in account-scoped browser storage. Reconnect and player exit retry the handoff, report conflicts, and refresh an open game when new data arrives. This keeps a temporary connection loss from silently discarding player progress. frontend/…/pending-asset.ts and frontend/…/index.ts.
References: frontend/…/AppLayout.vue• L48-68 frontend/…/AppLayout.vue• L153-200 frontend/…/pending-asset.ts• L21-29 frontend/…/pending-asset.ts• L132-180 frontend/…/pending-asset.ts• L326-443 frontend/…/index.ts• L66-155
Navigation surfaces
Navigation maps the main product tasks to stable destinations. Browsing stays in the primary navigation, while account, library maintenance, device delivery, and server controls stay in the user menu and settings frame.
Primary navigation
The primary destinations are Home, Platforms, Collections, and Search. Larger screens show them in the top navigation. Phones and small tablets use a bottom tab bar with the same destinations. The active tab follows route paths, so platform and collection detail routes keep their parent destination selected. On small screens, a tapped tab is highlighted during lazy navigation and returns to route state when the latest navigation succeeds or fails. Modified clicks that open a new tab do not change the current highlight. A tap received through a running view transition still reaches the selected destination, while a tap covered by an open overlay remains with that overlay. Scan and conversion indicators, soundtrack controls, and the account menu remain close to the current workspace. frontend/…/AppNav.vue, frontend/…/BottomNav.vue, and frontend/…/index.ts.
Home is a configurable starting point. It can show continue-playing and recently added games, recommendations, live sessions, platforms, regular collections, smart collections, virtual collections, and widgets. If the library is empty, Home waits for its initial loads and then offers a clear choice between upload and scan. frontend/…/Home.vue.
On narrow screens, a page heading can move into the top bar when the original heading has scrolled away. This keeps the current surface clear while the bottom bar remains the route navigation. frontend/…/index.ts, frontend/…/PageHeader.vue, and frontend/…/InfoPanel.vue.
References: frontend/…/AppNav.vue• L28-99 frontend/…/BottomNav.vue• L15-84 frontend/…/BottomNav.test.ts• L78-269 frontend/…/index.ts• L15-84 frontend/…/Home.vue• L81-188 frontend/…/Home.vue• L278-364 frontend/…/index.ts• L17-57 frontend/…/PageHeader.vue• L20-47
Library indexes
The Platforms surface lets a user choose a library system before opening its games. It hides platforms with no games by default, while an explicit all-platforms view keeps those records reachable for cleanup. Search can use the visible name and related platform identity such as the folder name, family, category, or alternate name. Category, generation, family, and play-mode facets narrow the same index without changing the library context. frontend/…/PlatformsIndex.vue.
The Collections surface joins regular, smart, and virtual collections and keeps their kind clear as the user moves from an index to a gallery. Both indexes support search, sorting, grouping, and tile or list views. Platform grouping can use letters, family, category, generation, or playability, where playability includes browser, streaming, and native desktop paths. frontend/…/PlatformsIndex.vue and frontend/…/CollectionsIndex.vue.
Platform and collection pages add their own context before the gallery. A platform can expose its library, firmware, memory cards, and settings. A regular or smart collection can expose its library and settings, while a virtual collection remains read-only. These tabs stay part of the same URL-backed workspace. frontend/…/Platform.vue and frontend/…/Collection.vue.
References: frontend/…/PlatformsIndex.vue• L76-137 frontend/…/PlatformsIndex.vue• L295-337 frontend/…/PlatformsIndex.vue• L448-475 frontend/…/PlatformsIndex.vue• L612-627 frontend/…/PlatformsIndex.test.ts• L166-228 frontend/…/PlatformsIndex.test.ts• L230-521 frontend/…/CollectionsIndex.vue• L1-205 frontend/…/Platform.vue• L74-115 frontend/…/Collection.vue• L70-123 frontend/…/smartCollectionCriteria.ts• L141-239
Settings navigation
The account menu is the quick path to personal, library, system, and tool surfaces. It includes profile, interface choices, notifications, scan and upload actions, library settings, metadata sources, devices, administration, activity, statistics, logs, and optional tools such as the jukebox and controller inspector. frontend/…/UserMenu.vue.
Settings uses the same groups in a shared side navigation on larger screens. On small screens, the account menu replaces that sidebar. Visible links reflect current grants and server features, while route guards and the server protect direct links and writes. frontend/…/SettingsLayout.vue and frontend/…/SettingsSidebar.vue.
Interface settings shape the user's language, theme, Home sections and widgets, gallery display, artwork style on each page, jukebox behavior, gameplay prompts, and virtual collection view. A desktop-shell settings action opens local shell settings outside RomM, while the other choices belong to the browser experience. frontend/…/UserInterface.vue.
References: frontend/…/UserMenu.vue• L1-16 frontend/…/UserMenu.vue• L180-367 frontend/…/SettingsLayout.vue• L27-65 frontend/…/SettingsSidebar.vue• L1-170 frontend/…/UserInterface.vue• L39-199
Notification center
The notification center joins in-app notices, notification-channel management, and administrator messages in one account surface. Users can follow safe links to related RomM pages. Selected notices can also reach email, webhooks, or supported Apprise services. frontend/…/Notifications.vue and frontend/…/NotificationInbox.vue.
The account menu shows the unread count on every route. The inbox keeps live additions and fetch results in one ordered view. It applies read and dismiss actions immediately, then restores the affected notice when a server write fails. Channel setup keeps service fields, secret retention, confirmation, test sends, and enablement in one flow, while transient notices remain visible when a player owns the screen. frontend/…/notificationInbox.ts, frontend/…/NotificationChannelDialog.vue, and frontend/…/UserMenu.vue.
References: frontend/…/Notifications.vue• L1-71 frontend/…/NotificationInbox.vue• L33-107 frontend/…/NotificationChannelDialog.vue• L138-207 frontend/…/notificationInbox.ts• L57-155 frontend/…/UserMenu.vue• L192-211
User workflows
The application moves users from server readiness to a useful library, then supports repeated browse, play, media, device, account, and maintenance tasks. Each workflow joins a route surface with shared client state and server operations.
Setup and sign-in
The setup flow is a three-step first-run wizard. It checks the library structure, creates selected platform records, creates the first administrator, optionally saves an avatar, and presents metadata guidance before the account enters normal sign-in. A failed library check stays in the wizard with a retry path. The heartbeat tells the browser when this first-run path is required. frontend/…/Setup.vue.
After setup, users sign in with a local account or the configured identity provider. The flow restores the session and returns the user to the requested destination. Password reset can restore a session. Registration requires an invite, while device pairing remains a public entry point. Later actions still depend on server state and effective grants. frontend/…/Login.vue, frontend/…/Register.vue, frontend/…/ResetPassword.vue, and frontend/…/DevicePair.vue.
References: frontend/…/heartbeat.ts• L15-84 frontend/…/Setup.vue• L31-202 frontend/…/Login.vue• L1-100 frontend/…/router.ts• L450-480
Library browsing
Users can start at Home, a platform, a collection, or Search. A gallery combines that context with search, sort, and filters for metadata, status, ownership, playability, media, and file state. It keeps result metadata while loading visible rows on demand. For this browsing model, see Library browsing experience. frontend/…/GalleryShell.vue.
Selecting a game opens a detail workspace. That workspace joins identity, play choices, files, media, notes, saves, states, metadata, related titles, patching, device delivery, and permitted actions. Save and state views separate the user's own assets from other users' public community assets. When achievement data exists, it adds an achievement view with earned-versus-total progress. Users can change collection membership or save a reviewed filter as a smart collection without losing the wider library context. frontend/…/GameDetails.vue and frontend/…/SaveDataTab.vue.
This diagram shows the normal path from a library context to a game action.
sequenceDiagram
participant User
participant Navigation
participant Gallery
participant Details as Game details
participant Server
User->>Navigation: Choose Home, platform, collection, or Search
Navigation->>Gallery: Open the library context
Gallery->>Server: Request result context and visible games
Server-->>Gallery: Return rows and filter data
User->>Gallery: Select a game
Gallery->>Details: Open game details
Details->>Server: Request the full game record
Server-->>Details: Return game and user data
User->>Details: Play, download, edit, or manage the game
Details->>Server: Apply the permitted action
References: frontend/…/GalleryShell.vue• L137-292 frontend/…/GameDetails.vue• L243-341 frontend/…/GameDetails.vue• L355-408 frontend/…/GameDetails.test.ts• L137-237 frontend/…/SaveDataTab.vue• L67-160 frontend/…/index.ts• L58-123
Game playback
The game action surface selects a player that matches the title's platform, files, permissions, and available runtime. A supported title can use the EmulatorJS browser player, a server stream, or a desktop-shell launch. When more than one path works, the user can choose the path. Browser playback can also offer a disc, core, firmware, resume asset, fullscreen, or bezel choice when the title supports it. Playability labels use the same browser and streaming capability rules as the play actions, while native desktop support remains a separate machine capability. frontend/…/index.ts, frontend/…/index.ts, frontend/…/index.ts, and frontend/…/EmulatorJS.vue.
The launch screen chooses the newest compatible progress by default and warns when another save or state is newer than the selected one. It validates remembered disc choices against the current ROM files before boot. Browser playback sends saves and states to the server and can hold captures in account-scoped browser storage for a later retry when the connection is down. frontend/…/resumeSelection.ts, frontend/…/playerDisc.ts, frontend/…/EmulatorJS.vue, and frontend/…/EmulatorJSPlayer.vue.
Streaming uses a server-managed session that a user can claim or join. Before claiming, the streaming player can offer a compatible resume state or save, a memory card, and a starting disc. While playing, the claim holder can save or load state, swap discs where supported, save and exit, or release the session. A joiner leaves without ending the host's game. frontend/…/Stream.vue, frontend/…/streaming.ts, and frontend/…/streaming.ts.
This diagram shows how a playback request becomes a local or server-backed session and returns the user to the library.
flowchart TD
Action[Game action] --> Choice{Available runtime}
Choice --> Local[Browser or desktop player]
Choice --> Stream[Streaming player]
Stream --> Session[Claim or join session]
Local --> Running[Running game]
Session --> Running
Running --> Exit[Save, release, or leave]
Exit --> Details[Game details or gallery]
References: frontend/…/PlayerShell.vue• L38-121 frontend/…/index.ts• L34-110 frontend/…/index.ts• L74-110 frontend/…/resumeSelection.ts• L15-93 frontend/…/playerDisc.ts• L80-177 frontend/…/streaming.ts• L96-245 frontend/…/streaming.ts• L165-205 frontend/…/Stream.vue• L622-843 frontend/…/Stream.vue• L934-1013
Media and asset workflows
Game details treats manuals, walkthroughs, screenshots, artwork, soundtracks, saves, states, and game files as related media around one game record. Each asset surface keeps its own viewing or management task near the game that owns it. frontend/…/MediaTab.vue, frontend/…/SaveDataTab.vue, and frontend/…/FilesTab.vue.
Personal saves and states can be uploaded, selected, labeled, shared, downloaded, and removed. The user manages their own items, while public items from other users are available as read-only community downloads. The jukebox provides a library-wide soundtrack view with queues, favorites, radio, and a persistent mini-player. frontend/…/SaveDataTab.vue, frontend/…/state.ts, and frontend/…/index.vue.
References: frontend/…/MediaTab.vue• L1-180 frontend/…/SaveDataTab.vue• L87-160 frontend/…/SaveDataTab.vue• L259-477 frontend/…/state.ts• L12-143 frontend/…/UploadAssetDialog.vue• L24-118 frontend/…/index.vue• L24-155
Save synchronization
Save synchronization preserves progress across players and devices. A save channel groups related progress, while snapshots record named versions that can be reviewed, pinned, shared through a branch, or reconciled after a conflict. This gives automatic progress a history instead of treating each upload as an isolated file. frontend/…/save.ts and frontend/…/snapshot.ts.
The browser can send a final save or snapshot during page exit when the payload fits the browser's unload request limit. Larger or normal transfers use the regular request path, and device identity and session information keep the progress tied to the correct sync operation. frontend/…/save.ts, frontend/…/snapshot.ts, and frontend/…/index.ts.
References: frontend/…/save.ts• L12-19 frontend/…/save.ts• L62-95 frontend/…/save.ts• L152-186 frontend/…/snapshot.ts• L13-38 frontend/…/snapshot.ts• L141-189
ROM patching
Game details can combine a game file with a patch and produce a new ROM. A user can choose a patch already attached to the game or provide one from the local device, then download the result or upload it into a selected platform when the account has library write access. frontend/…/PatcherTab.vue.
The patch flow also handles archive members, supported patch formats, output naming, source validation warnings, and a follow-up scan when the result is added back to RomM. This keeps a patched file useful in the same searchable library workflow as an uploaded ROM.
References: frontend/…/PatcherTab.vue• L46-65 frontend/…/PatcherTab.vue• L178-310 frontend/…/RomPatcherDict.ts• L5-7 frontend/…/PatcherTab.test.ts• L134-180
Device delivery
The game action surface can send a supported game to a registered device. The delivery flow joins device capability, online presence, and request state so the user can follow pending, active, delivered, failed, or canceled work without leaving the game workspace. frontend/…/InstallOnDeviceDialog.vue.
The server and live events confirm delivery. Account settings provide the wider view of registered devices and save-sync choices. Completed requests stay visible without being submitted again, and active requests can be canceled. frontend/…/device-install.ts and frontend/…/Devices.vue.
References: frontend/…/InstallOnDeviceDialog.vue• L30-40 frontend/…/InstallOnDeviceDialog.vue• L63-231 frontend/…/device-install.ts• L7-30 frontend/…/Devices.vue• L83-145
Achievement account linking
The account settings surface can link a RomM user to a RetroAchievements profile and start a profile sync. A changed username requests a full sync, while an unchanged linked username requests an incremental refresh. The final result arrives as a background event so the account view can refresh its connection status without blocking on the full sync. frontend/…/RetroAchievementsSection.vue.
References: frontend/…/RetroAchievementsSection.vue• L23-88 frontend/…/RetroAchievementsSection.test.ts• L41-56
Library administration
Library administration turns files and owned physical media into searchable game records. Upload adds files to a platform and starts a scan. Scanning can discover platforms, match games, update metadata, calculate hashes, or rescan selected folders. A physical-game flow can add an owned title without a file. frontend/…/Upload.vue, frontend/…/Scan.vue, and frontend/…/AddPhysicalGameDialog.vue.
Operators can then manage collections, artwork, firmware, missing games, missing firmware, metadata IDs, file checks, folder mappings, age limits, and conversion settings. For the operator view of these flows, see Administration workflows. frontend/…/LibraryManagement.vue and frontend/…/ConversionSettings.vue.
References: frontend/…/Upload.vue• L49-203 frontend/…/Scan.vue• L59-232 frontend/…/AddPhysicalGameDialog.vue• L55-117 frontend/…/LibraryManagement.vue• L1-160
Server administration
Administrators use settings to manage users, groups, permissions, server configuration, metadata sources, scan priorities, exports, tasks, activity, statistics, logs, notifications, devices, and streaming containers. Personal interface settings stay separate from changes that affect the whole server. The interface hides unavailable actions, while route and server checks protect direct links and writes. frontend/…/Administration.vue and frontend/…/SettingsSidebar.vue.
Activity joins active play presence with streaming sessions. Event and server log views help operators inspect user and system work. Metadata source settings group catalog, specialized, and proxy providers. Scan, conversion, and user-interface settings then define how the server enriches games, builds the library, prepares downloads, and shapes each user's view. frontend/…/Activity.vue, frontend/…/Logs.vue, frontend/…/MetadataSources.vue, frontend/…/MetadataSources.test.ts, frontend/…/ScanSettings.vue, and frontend/…/UserInterface.vue.
References: frontend/…/Administration.vue• L1-130 frontend/…/Activity.vue• L50-237 frontend/…/Logs.vue• L1-180 frontend/…/MetadataSources.vue• L41-149 frontend/…/MetadataSources.test.ts• L49-91 frontend/…/ScanSettings.vue• L180-595 frontend/…/UserInterface.vue• L39-199
Change checklist
When these files or sections are changed, remember to consider these:
- Keep route names, route components, layout assignments, access guards, and not-found fallback behavior aligned. Direct links must produce the same result as menu entries.
- Keep the shared primary destination list, route-path matching, desktop top navigation, mobile bottom navigation, pending tap highlight, navigation error cleanup, view-transition handling, and compact page title behavior aligned.
- Keep setup state, heartbeat state, session expiry, CSRF refresh, permission hydration, feature flags, and visible menu actions aligned.
- Keep API reachability signals, heartbeat authority, canceled-request handling, cached navigation, and reconnect UI aligned. A failed request must not turn a canceled read into an offline state.
- Keep server permission actions, UI grants, route scopes, and backend checks aligned. A visible control must not promise an action the server rejects.
- Keep shell lifecycle installers aligned with live event names and shared stores. A changed terminal event can leave scan, notification, save-sync, delivery, conversion, or play state visible after work ends.
- Keep HTTP health, live transport health, cached navigation, reconnect refresh, and player protection aligned. A live-channel problem must not look like a dead session or interrupt active play.
- Keep gallery context, URL values, result counts, filter values, sort order, selection state, and window loading aligned. A mismatch can make a saved link or smart collection describe different games than the visible list.
- Keep smart collection serialization, route context, filter logic, and criteria summaries aligned. A new filter must not be saved without the rule that explains how it matches.
- Keep playability labels, browser and streaming modes, runtime choices, file checks, desktop-shell support, and action routing aligned.
- Keep browser launch intent, available save/state and firmware choices, selected core or disc, and post-reload launch behavior aligned. A stale choice must be dropped rather than resumed against a different asset.
- Keep EmulatorJS launch configuration, runtime callbacks, save/state uploads, local pending assets, and exit cleanup aligned. A runtime change can otherwise boot with the wrong media or lose progress.
- Keep resume selection, compatible cores, device ownership, save slots, and newer-progress warnings aligned. A launch must not overwrite newer progress without a clear user choice.
- Keep streaming claim identity, owner/joiner controls, launch events, heartbeat checks, force-release handling, save/state and disc controls, and save-and-exit behavior aligned.
- Keep collection kind and identity aligned across Home, indexes, galleries, details, dialogs, and settings. Regular, smart, and virtual collections must not cross routes.
- Keep interface preference scope aligned across Home, gallery, details, player, virtual collections, and the local desktop shell. A browser preference must not silently change shell settings or another page's artwork choice.
- Keep pending browser assets account-scoped and separate from active play. Sync timing, conflict reporting, retry behavior, and save APIs must agree.
- Keep save, state, and snapshot ownership, device identity, labels, visibility, favorites, channels, history, branches, conflict results, and refresh behavior aligned with the generated asset models.
- Keep unload-safe save and snapshot limits aligned with the player exit path. A payload that cannot leave with the page must remain available to the normal sync path.
- Keep notification fetch generation, live additions, optimistic read and dismiss changes, unread counts, and account reset behavior aligned. A late response must not restore notices from another user or erase newer changes.
- Keep ROM patcher capability flags, accepted patch formats, archive-member selection, source validation, download naming, upload permissions, and the follow-up scan aligned.
- Keep device capability, online presence, request status, cancellation, live updates, and notification links aligned. A completed request must not remain selectable.
- Keep RetroAchievements account updates, full versus incremental sync choice, socket completion events, and displayed connection status aligned.
- Keep upload completion, platform identity, scan start, scan type, provider choice, and metadata requirements aligned.
- Keep conversion settings, saved form state, task permissions, and conversion task inputs aligned. Unsaved values must not look active.
- Keep the current
src/paths and imports aligned after the completed move from the formersrc/v2/area. The old console and v1-only surfaces are no longer alternate application entry points.
Important failure modes
| Trigger | Consequence | Guard |
|---|---|---|
| The server is unreachable during navigation | Cached records look usable but sign-in and writes cannot work | Keep reachability separate from cached records and show the connection notice. |
| A request is canceled during gallery or search changes | The browser reports a false offline state | Ignore canceled requests when updating reachability. |
| HTTP works but the live channel is degraded | Scan, delivery, save-sync, conversion, or play updates arrive late | Show live transport health separately and allow live-channel recovery without forcing sign-in. |
| The server reconnects while a game is running | A refresh can kill the player and lose unsynced progress | Delay refresh until play ends and cleanup requests settle. |
| A route scope or feature flag differs from its menu gate | A user sees a link that ends in a not-found or forbidden result | Apply the same server state and grant to menus, guards, and requests. |
| Desktop and mobile navigation use different destination or active-route rules | A user sees different tabs or loses the active context after opening a child route | Derive both surfaces from the shared destination model and path matcher. |
| A newer mobile tab tap settles after an older navigation | The bottom bar returns to an old highlight while the latest route is still loading | Track the latest destination and clear the pending highlight only for its success or error. |
| A tab tap is covered by an open overlay | A page navigation closes or acts through the overlay by mistake | Leave taps under an active overlay to the overlay. |
| A gallery context changes during a window request | Old games replace the new result or visible rows stay skeletons | Cancel stale work, compare request ownership, and reset the result context. |
| Home checks for an empty library before initial loads settle | A populated library briefly shows upload and scan choices | Gate the empty state on completed initial loads. |
| A playability label uses a different rule from the action surface | A platform appears playable but no player can open its games | Derive labels and actions from the same capability and permission rules. |
| A remembered disc points to a file removed by a rescan | Playback requests a missing file and reports a generic network failure | Validate stored choices against current files and fall back to the current default. |
| A pending save or state is restored to the wrong account or runtime | A player exposes another user's progress or offers an unsupported restore | Namespace browser assets by account and filter them by active runtime. |
| A launch reloads after a selected save, state, firmware, or core is removed | The player can resume a choice that is no longer valid or boot with mismatched data | Store launch intent by identity and resolve it against the options available after reload. |
| A newer save or state is hidden by an older default selection | The player rolls progress back when it starts | Compare the selected asset with newer compatible progress and offer the newer choice. |
| A save or snapshot is too large for an unload request | Page exit leaves the newest progress unsent | Reject the unload handoff and keep the progress on the normal sync path. |
| A snapshot conflict or branch result is not reflected in shared state | The player or settings surface shows progress as current when the server kept another version | Surface the server result and refresh the channel or snapshot history. |
| A notification fetch finishes after live changes or an account reset | New notices disappear or notices from a prior account reappear | Replay in-flight changes and discard responses from an older account generation. |
| An optimistic notification write fails | A notice stays read or dismissed even though the server kept it | Restore only the affected notice or read state after the failed write. |
| A stream claim finds a pre-existing memory card with no import decision | The claim pauses instead of starting and the container remains unresolved | Ask whether to adopt or discard the card, then retry the claim with that choice. |
| A player exits without saving or releasing its session | Newer progress can be lost or a streaming container stays occupied | Use one exit path for save handoff, presence cleanup, and release. |
| A streaming claim is force-released or its owner heartbeat expires | The screen can show a dead stream while the container becomes available to another session | Track the claim identity and handle live termination with a clear exit path. |
| An unsupported patch or a mismatched patch source is applied | The result can fail, warn about validation, or produce a file that should not enter the library silently | Use server-supported extensions, surface validation warnings, and require an explicit download or upload action. |
| An upload completes without its follow-up scan | Files exist on disk but do not appear in the searchable library | Keep upload completion, platform identity, and scan start as one workflow. |
| A scan starts without an effective metadata source | The scan runs without producing expected game data | Disable scan types that require a provider until one is available. |
| A conversion finishes but its shared work entry remains | Navigation reports a download as active after the file is ready | Remove shared work on success, refusal, cancellation, and timeout. |
Key files
| File | Why to read it |
|---|---|
| frontend/…/main.ts | Shows browser bootstrap, initial data gating, and stale asset recovery. |
| frontend/…/RomM.vue | Shows the root application host, theme handling, and connection banner. |
| frontend/…/routes.ts | Shows the current route-to-view and route-to-layout map. |
| frontend/…/router.ts | Shows authentication, setup, permission, URL, title, and recovery behavior. |
| frontend/…/AppLayout.vue | Shows the cross-route shell, shared data hydration, global services, and player-stage behavior. |
| frontend/…/AuthLayout.vue | Shows the setup and identity surface outside the signed-in shell. |
| frontend/…/SettingsLayout.vue | Shows the shared settings navigation frame and mobile behavior. |
| frontend/…/AppNav.vue | Shows the desktop primary destinations and global status controls. |
| frontend/…/BottomNav.vue | Shows the small-screen primary navigation surface, including pending route highlights, view-transition taps, and navigation recovery. |
| frontend/…/BottomNav.test.ts | Shows the guarantees for filled tab icons, active-page state, modified clicks, overlays, and overlapping or failed navigation. |
| frontend/…/index.ts | Shows the shared destination list and active-route rules. |
| frontend/…/UserMenu.vue | Shows account, library, system, tool, and logout navigation. |
| frontend/…/heartbeat.ts | Shows server health and feature readiness. |
| frontend/…/permissions.ts | Shows effective grants and the UI/server permission boundary. |
| frontend/…/notificationInbox.ts | Shows ordered notification state, live reconciliation, optimistic actions, and account reset behavior. |
| frontend/…/galleryRoms.ts | Shows the shared large-library result model and visible-window loading. |
| frontend/…/smartCollectionCriteria.ts | Shows how gallery filters become saved smart collection criteria and summaries. |
| frontend/…/index.ts | Shows shared request, session, CSRF, connection, and unload-header behavior. |
| frontend/…/save.ts | Shows save uploads, device-aware versions, and unload-safe progress handoff. |
| frontend/…/state.ts | Shows state upload and asset management requests. |
| frontend/…/snapshot.ts | Shows save-sync channels, snapshot history, conflict-aware pushes, and unload-safe snapshot handoff. |
| frontend/…/pending-asset.ts | Shows account-scoped retry handling for unsynced player assets. |
| frontend/…/Home.vue | Shows the library landing surface and empty-library choices. |
| frontend/…/PlatformsIndex.vue | Shows platform search, filters, grouping, playability, and empty-platform reachability. |
| frontend/…/GalleryShell.vue | Shows the shared gallery workspace. |
| frontend/…/GameDetails.vue | Shows the game workspace, conditional achievement view, and asset and action tabs. |
| frontend/…/SaveDataTab.vue | Shows personal and community save/state management. |
| frontend/…/PatcherTab.vue | Shows the ROM patch and optional re-upload workflow. |
| frontend/…/index.ts | Shows how play, download, delivery, conversion, and protected game actions are chosen. |
| frontend/…/index.ts | Shows how browser, streaming, and native playability are presented. |
| frontend/…/Setup.vue | Shows the first-run library, platform, administrator, and metadata wizard. |
| frontend/…/EmulatorJS.vue | Shows browser and desktop playback choices, resume selection, and player lifecycle. |
| frontend/…/emulatorJSConfig.ts | Shows the boundary between RomM launch choices and the browser runtime. |
| frontend/…/emulatorJSRuntime.ts | Shows browser save/state handoff and pending progress behavior. |
| frontend/…/resumeSelection.ts | Shows default progress selection and newer-progress protection. |
| frontend/…/playerDisc.ts | Shows multi-file boot choices and stale remembered-disc recovery. |
| frontend/…/streaming.ts | Shows the server contract for streaming claims, joins, session controls, and unload cleanup. |
| frontend/…/streaming.ts | Shows shared streaming configuration, capabilities, claims, joins, and session lifecycle. |
| frontend/…/Stream.vue | Shows streaming session ownership, resume choices, live controls, save-and-exit, and release behavior. |
| frontend/…/Upload.vue | Shows file upload and the post-upload library path. |
| frontend/…/Scan.vue | Shows scan choices, provider needs, and live progress. |
| frontend/…/RetroAchievementsSection.vue | Shows profile linking and background achievement sync. |
| frontend/…/Administration.vue | Shows the main server administration surface. |
| frontend/…/UserInterface.vue | Shows personal display, Home, gallery, gameplay, jukebox, and virtual collection choices. |