toJson method

  1. @override
Map<String, dynamic>? toJson(
  1. CupertinoTextThemeData? value
)
override

Implementation

@override
Map<String, dynamic>? toJson(CupertinoTextThemeData? value) {
  if (value == null) return null;

  return <String, dynamic>{
    'actionTextStyle':
        const NullableTextStyleConverter().toJson(value.actionTextStyle),
    'dateTimePickerTextStyle': const NullableTextStyleConverter().toJson(
      value.dateTimePickerTextStyle,
    ),
    'navActionTextStyle':
        const NullableTextStyleConverter().toJson(value.navActionTextStyle),
    'navLargeTitleTextStyle': const NullableTextStyleConverter()
        .toJson(value.navLargeTitleTextStyle),
    'navTitleTextStyle':
        const NullableTextStyleConverter().toJson(value.navTitleTextStyle),
    'pickerTextStyle':
        const NullableTextStyleConverter().toJson(value.pickerTextStyle),
    'tabLabelTextStyle':
        const NullableTextStyleConverter().toJson(value.tabLabelTextStyle),
    'textStyle': const NullableTextStyleConverter().toJson(value.textStyle),
  };

  throw 'Json_Unsuported_Value';
}