fix(iOS): rendering images from html with link#662
Merged
kacperzolkiewski merged 3 commits intoJun 26, 2026
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Fixes an iOS crash in the HTML parser when links appear after one or more <img/> tags by adjusting how link text is derived from plainText vs. NSTextStorage-coordinate ranges (issue #661).
Changes:
- Track image placeholder count during the “second pass” style processing.
- Adjust link text extraction range to account for preceding images when calling
substringWithRange:. - Update the example app’s
Podfile.lockchecksums.
Reviewed changes
Copilot reviewed 1 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| ios/htmlParser/HtmlParser.mm | Adjusts <a> link text extraction to compensate for image placeholder offsets. |
| apps/example/ios/Podfile.lock | Updates CocoaPods spec checksums in the example app lockfile. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
szydlovsky
reviewed
Jun 26, 2026
szydlovsky
approved these changes
Jun 26, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes: #661
Test Plan
Insert html by
Set input's valuebutton into example app:<html><p><img src="xxx" width="100" height="100"/><img src="xxx" width="100" height="100"/><img src="xxx" width="100" height="100"/></p><p>See <a href="https://example.com">a link</a></p></html>The html should be parsed properly.
Screenshots / Videos
before:
after:
Screen.Recording.2026-06-26.at.10.06.52.mov
Compatibility
Checklist