ProfileAccentColor.fromJson constructor

ProfileAccentColor.fromJson(
  1. Map<String, dynamic> json
)

Parses a ProfileAccentColor from TDLib JSON.

Implementation

factory ProfileAccentColor.fromJson(Map<String, dynamic> json) =>
    ProfileAccentColor(
      id: _readInt(json['id']),
      lightThemeColors: _readObject(
          json['light_theme_colors'], ProfileAccentColors.fromJson),
      darkThemeColors: _readObject(
          json['dark_theme_colors'], ProfileAccentColors.fromJson),
      minSupergroupChatBoostLevel:
          _readInt(json['min_supergroup_chat_boost_level']),
      minChannelChatBoostLevel:
          _readInt(json['min_channel_chat_boost_level']),
    );