SeasonalThemePreferencesDataSource

Persisted seasonal theme state: the easter egg unlock, the weather effect, and holiday bookkeeping.

Inheritors

Properties

Link copied to clipboard

Emits the appearance saved before a holiday theme was applied, or null if none is in use.

Link copied to clipboard
abstract val lastHolidayGreeting: Flow<String?>

Emits the occurrence key of the last holiday greeting answered, or null if none was.

Link copied to clipboard
abstract val seasonalThemesUnlocked: Flow<Boolean>

Emits whether the About screen easter egg has been found.

Link copied to clipboard
abstract val weatherEffect: Flow<WeatherEffect>

Emits what falls over the app; WeatherEffect.Automatic until another is chosen.

Functions

Link copied to clipboard
abstract suspend fun saveHolidayThemeSnapshot(snapshot: HolidayThemeSnapshot?)

Persists the appearance to restore after the holiday, or clears it when snapshot is null.

Link copied to clipboard
abstract suspend fun saveLastHolidayGreeting(occurrenceKey: String)
Link copied to clipboard
abstract suspend fun saveSeasonalThemesUnlocked(unlocked: Boolean)
Link copied to clipboard
abstract suspend fun saveWeatherEffect(effect: WeatherEffect)
Link copied to clipboard
abstract suspend fun unlockSeasonalThemes(): Boolean

Atomically unlocks the controls and returns true only for the first successful writer.

Link copied to clipboard

Reads and conditionally replaces the palette and snapshot in one serialized transaction.