Skip to main content

🎨 Theme

Match SDK colors to your brand at initialize, then adjust at runtime after connect. Theme applies to both Nutrition and Training UI; runtime changes do not require re-connect.

Platform code & examples

Use the platform selector at the top of the sidebar (Android, iOS, Flutter, or React Native) β†’ Theme on your platform.

Architecture​

MomentWhat you set
InitializeFull palette β€” primary, secondary, backgrounds, semantic colors
RuntimeMode (light/dark/system), primary accent, reset

Configuration (at initialize)​

Pass theme when you call initialize β€” before connect.

Properties​

PropertyPurpose
primaryLight / primaryDarkMain brand color per mode
secondaryLight / secondaryDarkSecondary accents
backgroundLight / backgroundDarkScreen backgrounds
success, error, warningSemantic feedback
customLightTheme / customDarkThemeFull ThemeData override (Flutter only)

Pigeon: AzeooThemeConfig / AzeooThemeConfigMessage in pigeons/azeoo_api.dart.

Example​

await AzeooSDK.initialize(apiKey, options: AzeooSDKInitOptions(
theme: ThemeConfig(
primaryLight: Color(0xFF0066CC),
primaryDark: Color(0xFF4DA3FF),
success: Colors.green,
error: Colors.red,
warning: Colors.amber,
),
));

Native hosts pass AzeooThemeConfig on AzeooSDK.initialize(...).


Runtime (after connect)​

MethodDescription
getThemeMode / setThemeModeLight, dark, or system
setPrimaryColorUpdate accent without full reconfig
setTheme / setCustomThemesReplace light/dark palettes
resetToDefaultRestore initialize-time theme
getCurrentThemeRead active config (debug / sync host UI)
HostAccess
FlutterAzeooSDK.changePrimaryColor, setCustomThemes, getCurrentThemeMode
Android / iOS / RNsdk.theme.*
// Flutter β€” after connect
AzeooSDK.changePrimaryColor(Colors.purple);

Pigeon: AzeooThemeApi.


See also​