Skip to content

Commit

Permalink
Merge pull request #15 from NiftyTreeStudios/resizable-images
Browse files Browse the repository at this point in the history
Resizable images
  • Loading branch information
Iikeli authored May 6, 2022
2 parents 5ca3491 + 0a1d1bd commit 13b9655
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Sources/NiftyMarkdownFormatter/Images.swift
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,9 @@ internal func formatImageComponents(_ string: String) -> (String, URL?) {
@available(iOS 15, macOS 12, *)
internal func formatImage(altText: String?, url: URL?) -> some View {
let image = AsyncImage(url: url) { image in
image.accessibilityLabel(altText ?? "")
image
.resizable()
.accessibilityLabel(altText ?? "")
} placeholder: {
ProgressView()
}
Expand Down

0 comments on commit 13b9655

Please sign in to comment.