WhiteLabelTheme

class WhiteLabelTheme(val identifier: String? = null, whiteLabelFontFamily: WhiteLabelFontFamily = WhiteLabelFontFamily.Default, colorScheme: WhiteLabelColorScheme = WhiteLabelColorScheme(), materialColorScheme: WhiteLabelMaterialColorScheme = WhiteLabelMaterialColorScheme(), borders: WhiteLabelBorders = WhiteLabelBorders()) : WireframeTheme

The White Label theme.

This theme extends WireframeTheme to provide a customizable foundation for white-labeling applications. Unlike the Wireframe theme which uses the Shantell Sans font, the White Label theme uses the default font family, making it ideal for applications that need a neutral starting point with custom branding.

The White Label theme can be customized in several ways:

  • Identifier: Provide a unique identifier to distinguish between multiple White Label theme instances.

  • Font family: Provide a custom WhiteLabelFontFamily implementation.

  • Color scheme: Pass a custom WhiteLabelColorScheme to override semantic color values.

  • Material color scheme: Pass a custom WhiteLabelMaterialColorScheme to override Material 3 color mappings.

  • Borders: Pass a custom WhiteLabelBorders to override border properties like radius.

Default Usage

By default, the White Label theme uses WireframeTheme appearance with the default font family:

OudsTheme(theme = WhiteLabelTheme()) {
// Your composables here
}

Customization Example

val customColorScheme = WhiteLabelColorScheme(
action = WhiteLabelColorScheme.Action(
enabled = OudsLightDarkColor(Color(0xFF1B5E20), Color(0xFF81C784))
),
content = WhiteLabelColorScheme.Content(
brandPrimary = OudsLightDarkColor(Color(0xFF1B5E20), Color(0xFF81C784))
)
)

val customMaterialColors = WhiteLabelMaterialColorScheme(
primary = OudsLightDarkColor(Color(0xFF1B5E20), Color(0xFF81C784)),
onPrimary = OudsLightDarkColor(Color.White, Color.Black)
)

val customBorders = WhiteLabelBorders(
radius = WhiteLabelBorders.Radius(default = 12.0.dp)
)

val customFont = WhiteLabelFontFamily { locale ->
FontFamily(
Font(R.font.brand_regular, FontWeight.Normal),
Font(R.font.brand_bold, FontWeight.Bold)
)
}

OudsTheme(
theme = WhiteLabelTheme(
identifier = "MyBrand",
colorScheme = customColorScheme,
materialColorScheme = customMaterialColors,
borders = customBorders,
whiteLabelFontFamily = customFont
)
) {
// Your fully branded app
}

Parameters

identifier

An optional identifier to distinguish between multiple White Label theme instances. Useful for logging, analytics, and conditional logic. Defaults to null.

whiteLabelFontFamily

The font family to use. Defaults to WhiteLabelFontFamily.Default which uses the default font family.

colorScheme

The color scheme to use. Defaults to WhiteLabelColorScheme which inherits from Wireframe colors.

materialColorScheme

The Material 3 color scheme. Defaults to WhiteLabelMaterialColorScheme which inherits from Wireframe Material colors.

borders

The border properties. Defaults to WhiteLabelBorders which inherits from Wireframe border properties.

Constructors

Link copied to clipboard
constructor(identifier: String? = null, whiteLabelFontFamily: WhiteLabelFontFamily = WhiteLabelFontFamily.Default, colorScheme: WhiteLabelColorScheme = WhiteLabelColorScheme(), materialColorScheme: WhiteLabelMaterialColorScheme = WhiteLabelMaterialColorScheme(), borders: WhiteLabelBorders = WhiteLabelBorders())

Properties

Link copied to clipboard
open override val borderTokens: OudsBorderSemanticTokens
Link copied to clipboard
open override val colorTokens: OudsColorSemanticTokens
Link copied to clipboard
open override val componentsTokens: OudsComponentsTokens
Link copied to clipboard
open override val deprecatedTokens: OudsDeprecatedTokens
Link copied to clipboard
Link copied to clipboard
open override val effectTokens: OudsEffectSemanticTokens
Link copied to clipboard
open override val elevationTokens: OudsElevationSemanticTokens
Link copied to clipboard
Link copied to clipboard
open override val fontTokens: OudsFontSemanticTokens
Link copied to clipboard
open override val gridTokens: OudsGridSemanticTokens
Link copied to clipboard
Link copied to clipboard
open override val materialColorTokens: OudsMaterialColorTokens
Link copied to clipboard
open override val name: String
Link copied to clipboard
open override val opacityTokens: OudsOpacitySemanticTokens
Link copied to clipboard
open override val settings: OudsThemeSettings
Link copied to clipboard
open override val sizeTokens: OudsSizeSemanticTokens
Link copied to clipboard
open override val spaceTokens: OudsSpaceSemanticTokens

Functions

Link copied to clipboard
open override fun getFontFamily(locale: Locale): FontFamily