Skip to main content

Theming

Usage

Wrap your composable component with AppKitTheme

import com.reown.appkit.ui.AppKitTheme

AppKitTheme(
mode = AppKitTheme.Mode.AUTO || AppKitTheme.Mode.LIGHT || AppKitTheme.Mode.DARK,
lightColors = AppKitTheme.provideLightAppKitColors(
// Override colors
),
darkColors = AppKitTheme.provideDarkAppKitColors(
// Override colors
)
) {
/* any AppKit component or graph */
}

Mode

    enum class Mode {
LIGHT, DARK, AUTO
}

Colors

Customizable colors in AppKitTheme. To override colors you need to use methods AppKitTheme.provideLightAppKitColors or AppKitTheme.provideDarkAppKitColors To override foreground or background ColorPalette you can define new palette or use one of the AppKitTheme methods to provide Palette and override selected colors

    interface Colors {
val accent100: Color
val accent90: Color
val accent80: Color
val foreground: ColorPalette
val background: ColorPalette
val grayGlass: Color
val success: Color
val error: Color
}

ColorPalette

    data class ColorPalette(
val color100: Color,
val color125: Color,
val color150: Color,
val color175: Color,
val color200: Color,
val color225: Color,
val color250: Color,
val color275: Color,
val color300: Color,
)