Closed
Description
Describe the bug:
<br>
s are not handled correctly while in shrinkWrap: true
- only if you have a block element, then <br>
, then another block element. It seems as though 3 "/n"
s are added in shrinkWrap mode, when there should only be one.
HTML to reproduce the issue:
<p>Curabitur sollicitudin enim et malesuada porttitor. Sed erat velit, <a href="https://www.google.com">tempor vitae tristique</a> quis, dapibus vel erat.</p>
<br>
<p>Sed ut perspiciatis unde omnis iste natus </p>
Html
widget configuration:
Html(
data: """
<p>Curabitur sollicitudin enim et malesuada porttitor. Sed erat velit, <a href="https://www.google.com">tempor vitae tristique</a> quis, dapibus vel erat.</p>
<br>
<p>Sed ut perspiciatis unde omnis iste natus </p>
""",
style: {
"body": Style(margin: EdgeInsets.zero, padding: EdgeInsets.zero,
backgroundColor: Colors.purpleAccent),
"h1": Style(backgroundColor: Colors.amber[200]),
"h2": Style(backgroundColor: Colors.amber[500]),
"p": Style(backgroundColor: Colors.amber[800]),
},
shrinkWrap: true,
),
Expected behavior:
shrinkWrap: true
looks the same as shrinkWrap: false
Screenshots:
Actual | Expected |
---|---|
![]() |
![]() |
Device details and Flutter/Dart/flutter_html
versions:
SM-G975F, Flutter & Dart beta, flutter_html
master.