-
-
Notifications
You must be signed in to change notification settings - Fork 67
Image rendering is not using the provided component #498
Description
Bug Description
Image link is always parsed as a paragraph with a text containing an inline image. (If you suspect it might be a JB markdown parser bug please tell me, I will take a look)
And this library code seems to not use the provided image component for the inline image rendering (see MarkdownText).
I couldn't make any markdown text to render the provided image component (which as I understand used for standalone images within markdown, which is never actually parsed) and there is no way to provide a component for an inline image.
So the end bug is that it's impossible to configure image rendering.
Steps to Reproduce
Steps to reproduce the behavior:
- Add this code
Markdown(
content = "",
imageTransformer = Coil3ImageTransformerImpl,
components = markdownComponents(
image = {
Text(it.content)
},
)
)- Run web JS (probably reproducible on any target)
- See the image rendered
Expected Behavior
Expected to see the content as text instead of the image as per provided image component.
Screenshots
Environment
- Library Version: 0.39.0
- Platform: Web JS
- Device: PC, Pixel 9A
- OS Version: Ubuntu 24.04.3, Android 16
- Kotlin Version: 2.3.0
- Compose Version: 1.9.3
- Coil Version: 3.2.0
Additional Context
If you're too busy I can help and contribute, but I need guidance on the proper solution here. Is it to add another component for inline images, fix JB markdown parser, both, neither but something else?
Checklist
- I have searched for similar issues (this seems different, but maybe related)
- I have checked the sample application
- I have read the README
- I have checked the CHANGELOG
- I have read the MIGRATION GUIDE