toMap static method
Converts a SplashConfig back to a Map<String, dynamic>.
Implementation
static Map<String, dynamic> toMap(SplashConfig config) {
return {
'duration': config.durationMs,
'animation': _animationToString(config.animation.type),
'type': _layoutTypeToString(config.layoutType),
'app_name': config.appName,
'tagline': config.tagline,
'show_loader': config.showLoader,
if (config.backgroundColor != null)
'background_color':
'#${config.backgroundColor!.toARGB32().toRadixString(16).padLeft(8, '0').substring(2).toUpperCase()}',
};
}