halilozercan / compose-richtext

A collection of Compose libraries for advanced text formatting and alternative display types.
https://halilibo.com/compose-richtext
Apache License 2.0
787 stars 65 forks source link

BugFix: Image goes over the text #117

Closed vitorpamplona closed 1 year ago

vitorpamplona commented 1 year ago

When users set a lineHeight via ProvideTextStyle(TextStyle(lineHeight = 1.3.em)) { ... }, the Markdown renderer forces that height to be true in all cases, even for inline Images. This PR resets the style to a regular markdown Paragraph just for the Image portion of the text.

halilozercan commented 1 year ago

Thanks!

dimitriz09 commented 8 months ago

@vitorpamplona I know this PR is now closed, but browsing your fork i saw your great work to manage onMediaCompose, do you mind opening a PR so that the main repo benefits from this ? I personally use it to add a custom http header on AsyncImage it is very helpful. Thank you both for your work.

vitorpamplona commented 8 months ago

I am happy to open a PR (I thought I was the only one in need for that type of flexibility).

@halilozercan is exposing an interface to customize the way to render images welcome? Details: https://github.com/halilozercan/compose-richtext/compare/main...vitorpamplona:compose-richtext:main