Button.fromJson constructor

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

Implementation

factory Button.fromJson(Map<String, dynamic> json) {
  return Button(
    favoriteButton: PrimaryColor.fromJson(json['favorite_button'] ?? ''),
    bankButton: BankButton.fromJson(json['bank_button'] ?? ''),
    actionButton: PrimaryColor.fromJson(json['action_button'] ?? ''),
    textColor: json['text_color'] ?? '',
    backgroundColor: json['background_color'] ?? '',
  );
}