gonzalezreal / swift-markdown-ui

Display and customize Markdown text in SwiftUI
MIT License
2.26k stars 267 forks source link

open image when tap on it #58

Closed oblank closed 2 years ago

oblank commented 2 years ago

is there some way to open image when tap on it, like LightBox's style?

gonzalezreal commented 2 years ago

Hello, This requirement is out of the scope of this package. You can achieve something close to it by creating an image link in markdown:

[![Image of Yaktocat](https://octodex.github.com/images/yaktocat.png)](https://octodex.github.com/images/yaktocat.png)

Furthermore, you could use your own URL scheme for the links and open the images in a native way. You can find more info about handling deep links in SwiftUI in this post.