From e5f168cb59b2699d878a9974f65b4192f479264a Mon Sep 17 00:00:00 2001 From: monsieurtanuki Date: Mon, 8 Apr 2024 19:47:40 +0200 Subject: [PATCH] fix: 900 - for KnowledgePanelActionElement html is now optional --- lib/src/model/knowledge_panel_element.dart | 4 ++-- lib/src/model/knowledge_panel_element.g.dart | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/src/model/knowledge_panel_element.dart b/lib/src/model/knowledge_panel_element.dart index a387cfc1d7..ed9dc68151 100644 --- a/lib/src/model/knowledge_panel_element.dart +++ b/lib/src/model/knowledge_panel_element.dart @@ -299,13 +299,13 @@ class KnowledgePanelTableElement extends JsonObject { @JsonSerializable() class KnowledgePanelActionElement extends JsonObject { /// HTML description. - final String html; + final String? html; /// Needed contribute actions, as [KnowledgePanelAction.addCategories.offTag]. final List actions; const KnowledgePanelActionElement({ - required this.html, + this.html, required this.actions, }); diff --git a/lib/src/model/knowledge_panel_element.g.dart b/lib/src/model/knowledge_panel_element.g.dart index c27254bf98..4fba5251fd 100644 --- a/lib/src/model/knowledge_panel_element.g.dart +++ b/lib/src/model/knowledge_panel_element.g.dart @@ -222,7 +222,7 @@ Map _$KnowledgePanelTableElementToJson( KnowledgePanelActionElement _$KnowledgePanelActionElementFromJson( Map json) => KnowledgePanelActionElement( - html: json['html'] as String, + html: json['html'] as String?, actions: (json['actions'] as List).map((e) => e as String).toList(), );