Skip to content

text: Fix images inside tags not showing#2119

Merged
huacnlee merged 1 commit intolongbridge:mainfrom
Moulberry:fix/images_inside_tags
Mar 6, 2026
Merged

text: Fix images inside tags not showing#2119
huacnlee merged 1 commit intolongbridge:mainfrom
Moulberry:fix/images_inside_tags

Conversation

@Moulberry
Copy link
Contributor

@Moulberry Moulberry commented Mar 4, 2026

Description

Fix images inside <a> tags not showing.
Previously, the code for <a> used merge_child_text. merge_child_text did not merge images, so images were lost. The new code merges without losing the images, while ensuring the images are placed in the correct location within the text.

How to Test

Edit README.md to contain

<a href="https://longbridge.com/desktop">
<img width="1763" alt="Image" src="https://github.com/user-attachments/assets/e1ecb9c3-2dd3-431e-bd97-5a819c30e551" />
</a>

And then open the "Introduction" story.

Before this change, the image is not visible.
After this change, the image correctly shows.

Checklist

  • I have read the CONTRIBUTING document and followed the guidelines.
  • Reviewed the changes in this PR and confirmed AI generated code (If any) is accurate.
  • Passed cargo run for story tests related to the changes.
  • Tested macOS, Windows and Linux platforms performance (if the change is platform-specific)

@huacnlee huacnlee changed the title text: fix images inside tags not showing text: Fix images inside tags not showing Mar 6, 2026
@huacnlee huacnlee merged commit 89b3025 into longbridge:main Mar 6, 2026
3 checks passed
@huacnlee
Copy link
Member

huacnlee commented Mar 6, 2026

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants