chore: Fix app
This commit is contained in:
@@ -0,0 +1,41 @@
|
||||
# Game Activity Domain
|
||||
|
||||
Foreground-window-first game detection, RAWG matching, and P2P now-playing sync.
|
||||
|
||||
**Cross-context contract:** [`agents-docs/features/game-activity.md`](../../../../../agents-docs/features/game-activity.md)
|
||||
|
||||
## Module map
|
||||
|
||||
```
|
||||
game-activity/
|
||||
├── domain/
|
||||
│ ├── game-activity.models.ts Shared-kernel types (re-exported)
|
||||
│ └── game-activity-time.ts formatGameActivityElapsed()
|
||||
├── application/
|
||||
│ ├── game-activity.service.ts Scan loop, match cache, P2P broadcast
|
||||
│ └── game-activity.service.spec.ts
|
||||
└── index.ts
|
||||
```
|
||||
|
||||
## Public entry points
|
||||
|
||||
| Export | Role |
|
||||
|--------|------|
|
||||
| `GameActivityService` | Started from `App` bootstrap; updates user store + broadcasts |
|
||||
| `formatGameActivityElapsed()` | Profile card / sidebar elapsed time label |
|
||||
|
||||
## Dependencies
|
||||
|
||||
- `ElectronBridgeService` — process names and foreground candidate (desktop only)
|
||||
- `ServerDirectoryFacade` — `POST /api/games/match` base URL
|
||||
- `RealtimeSessionFacade` — P2P `game-activity` send/receive
|
||||
|
||||
## UI consumers
|
||||
|
||||
- Profile card components (`formatGameActivityElapsed`, `user.gameActivity`)
|
||||
- Room side panel member list
|
||||
|
||||
## Boundaries
|
||||
|
||||
- Does not own RAWG API keys (server configuration).
|
||||
- Browser/mobile shells do not scan processes locally.
|
||||
Reference in New Issue
Block a user