-
-
Notifications
You must be signed in to change notification settings - Fork 916
Description
Hi, Thank you for such a great package.
Here I have a question about layout when using <li>
of ^1.0.0-pre.1.
I can't figure it out whether I went something wrong, I missed some option or it's just not supported yet. Details down below.
Environment
- flutter_html: ^1.0.0-pre.1
$ flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, v1.12.13+hotfix.5, on Mac OS X 10.14.5 18F132, locale en-JP)
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
[✓] Xcode - develop for iOS and macOS (Xcode 11.3.1)
[✓] Android Studio (version 3.5)
[✓] VS Code (version 1.43.2)
[✓] Connected device (1 available)
• No issues found!
Steps to reproduce
Here's the code to reproduce.
Html(
data: '''
<ul>
<li>qwertyuiopasdfghjklzxcvbnm</li>
<li>qwertyuiopasdfghjklzxcvbnm</li>
<li>qwertyuiopasdfghjklzxcvbnm</li>
<li>qwertyuiopasdfghjklzxcvbnm</li>
<li>qwertyuiopasdfghjklzxcvbnm</li>
<li>qwertyuiopasdfghjklzxcvbnm</li>
</ul>
''',
)
Expected Result
I think this left padding (margin) is a little bit too wide.
I wish to set the list items without left padding and margin.
Actual Result (Visual Proof)
You know, I don't need any space before list items. I tried to remove them, setting EdgeInsets.zero
to li
and ul
on style:
property like below.
Html(
data: '...'
style: {
'ul': Style(margin: EdgeInsets.zero, padding: EdgeInsets.zero),
'li': Style(margin: EdgeInsets.zero, padding: EdgeInsets.zero),
}
)
But this didn't work. The padding and margin were left there.
I think this spacing is just an intended specification, following a standard web layout.
Thus, this issue might be a feature request. I hope there would be some way to configure li
' s spacing. Or there might be a workaround.
Thank you.