Skip to content

Latest commit

 

History

History
39 lines (26 loc) · 814 Bytes

File metadata and controls

39 lines (26 loc) · 814 Bytes

Usage

Overview

Component package: app.presentation.theme.change

Example

As a separate screen

Invoke the ChangeThemeDestination destination from your ViewModel or View utilizing the pre-configured NavigationStore.

class TemplateViewModel(
    private val navigationStore: NavigationStore
) : BaseViewModel() {

    fun onChangeTheme() {
        navigationStore.onNext(ChangeThemeDestination)
    }

}

As a dialog

Invoke the ChangeThemeDialogDestination destination from your ViewModel or View utilizing the pre-configured NavigationStore.

class TemplateViewModel(
    private val navigationStore: NavigationStore
) : BaseViewModel() {

    fun onChangeTheme() {
        navigationStore.onNext(ChangeThemeDialogDestination)
    }

}