Tags: acristescu/OnlineGo
Tags
Feat: Add in-app review prompt This commit integrates the Google Play In-App Review API, prompting users to rate the app after winning a game. - **`ReviewPromptManager`** and **`ReviewPromptRepository`** are introduced to handle the review flow logic, timing, and state persistence using DataStore. - The prompt is triggered from the `GameViewModel` after a player wins a game, subject to configurable timing and cooldown periods. - Includes a fallback to redirect to the Play Store if the in-app review flow isn't available. - New dependencies for Google Play Review (`com.google.android.play:review`) are added. - A detailed documentation file, `REVIEW_PROMPT_INTEGRATION.md`, is included.
Fix: Refresh UI config periodically and update icon URL regex This commit introduces a periodic refresh for the `UIConfig` and updates the regex for user avatar URLs. - The `UIConfig` will now be considered stale and refreshed after one hour to ensure data, such as the user JWT, is up-to-date. - A timestamp is now stored in `PersistenceManager` whenever the `UIConfig` is saved. - The `UserSessionRepository` uses this timestamp to determine if a refresh is needed. - The regex in `Globals.kt` for processing user avatar icons has been updated from `rackcdn.com` to the new `user-uploads.online-go.com` domain.
Fix: Remove splash screen This commit removes the splash screen logic entirely. - The `core-splashscreen` dependency is removed. - All related code in `MainActivity`, `MyGamesUI`, and `MainActivityViewModel` has been deleted, including the `installSplashScreen` call, `setKeepOnScreenCondition`, and the logic that waited for initial data to load before hiding the splash screen. - Splash screen-related styles have also been removed from `styles.xml`.
Refactor: Simplify screen readiness logic in MyGamesUI This commit removes the `hasReceivedHistoricGames` check from the `screenReady` condition in `MyGamesUI`. It also removes an unnecessary `withContext(Dispatchers.Default)` block from the `LaunchedEffect` that calls `onScreenReady`.
Feat: Re-enable splash screen logic This commit re-enables the splash screen logic in `MainActivity` and `MyGamesUI`. - The `setKeepOnScreenCondition` in `MainActivity` is now active, keeping the splash screen visible until the app has window focus and the initial data is loaded. - The corresponding logic in `MyGamesUI` that determines when the screen is ready for display (i.e., when all initial game data is received or the user is logged out) has also been uncommented. - A 2-second timeout is included to dismiss the splash screen even if data loading is delayed.
PreviousNext