From cd926d47af4fc81f31a102f566d0c643c2ef7dcd Mon Sep 17 00:00:00 2001 From: Minh-Danh Date: Thu, 25 Jul 2024 14:17:27 +0700 Subject: [PATCH] Fix empty boolean type cells (#361) --- lib/src/save/save_file.dart | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/src/save/save_file.dart b/lib/src/save/save_file.dart index ffb56710..8c7a2913 100644 --- a/lib/src/save/save_file.dart +++ b/lib/src/save/save_file.dart @@ -59,6 +59,7 @@ class Save { var attributes = [ XmlAttribute(XmlName('r'), rC), if (value is TextCellValue) XmlAttribute(XmlName('t'), 's'), + if (value is BoolCellValue) XmlAttribute(XmlName('t'), 'b'), ]; final cellStyle = @@ -149,7 +150,9 @@ class Save { ]), ]; case BoolCellValue(): - children = []; + children = [ + XmlElement(XmlName('v'), [], [XmlText(value.value ? '1' : '0')]), + ]; } return XmlElement(XmlName('c'), attributes, children);