initialize static method
初始化方法,允许用户添加自定义色系
customColors
- 自定义颜色映射
例如: {
'brand': {
'50': Color(0xFFF0F9FF),
'100': Color(0xFFE0F2FE),
'500': Color(0xFF0EA5E9),
'900': Color(0xFF0C4A6E),
}
}
Implementation
static void initialize({Map<String, Map<String, Color>>? customColors}) {
if (customColors != null) {
_customColors.clear();
_customColors.addAll(customColors);
}
}