getCustomStyleOrDefault method
获取自定义文本样式,如果不存在则返回默认样式
final titleStyle = typography.getCustomStyleOrDefault('appBarTitle', bodyLarge);
Implementation
TextStyle getCustomStyleOrDefault(String key, TextStyle defaultStyle) {
return customStyles[key] ?? defaultStyle;
}