Flutter_html: Bug: Leading space in text after inline image, should be left untouched

Created on 16 Jan 2020  路  6Comments  路  Source: Sub6Resources/flutter_html

Html(data: "<p>Text <img src=""/> Text2</p>
The space just before Text2 is not rendered.

All 6 comments

You are correct. Are you on version 1.0.0?

Yes I am on 1.0.0

The solution is to add the following code around line 408

if (tree is ImageContentElement || tree is SvgContentElement) {
wpc.data = false;
}

Any update on this?

1.0.0 pre seems to fix this. But now there is no space. There should be least a single space between the end of image and text.

Hi @Sub6Resources I have created a merge request to address the issue.
@Nijinsha let me know if it works for your use-case.

Merged the pull request. This will be released with 1.0.0-pre.2

Was this page helpful?
0 / 5 - 0 ratings

Related issues

a-href picture a-href  路  4Comments

munnadroid picture munnadroid  路  6Comments

Larpoux picture Larpoux  路  3Comments

assurancetourix picture assurancetourix  路  3Comments

zs-dima picture zs-dima  路  4Comments