From 496d1aa8e655891d2f597c5e4d7e92057801d815 Mon Sep 17 00:00:00 2001 From: Nicolas Werner <89468146+nico-famedly@users.noreply.github.com> Date: Tue, 23 May 2023 15:31:29 +0200 Subject: [PATCH] fix: start list items on a new line (#1281) --- lib/src/builtins/styled_element_builtin.dart | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/src/builtins/styled_element_builtin.dart b/lib/src/builtins/styled_element_builtin.dart index 08a9f49db1..349486c595 100644 --- a/lib/src/builtins/styled_element_builtin.dart +++ b/lib/src/builtins/styled_element_builtin.dart @@ -434,7 +434,8 @@ class StyledElementBuiltIn extends HtmlExtension { child.value, if (context.parser.shrinkWrap && i != context.styledElement!.children.length - 1 && - child.key.style.display == Display.block && + (child.key.style.display == Display.block || + child.key.style.display == Display.listItem) && child.key.element?.localName != "html" && child.key.element?.localName != "body") const TextSpan(text: "\n", style: TextStyle(fontSize: 0)),