File tree Expand file tree Collapse file tree 1 file changed +4
-6
lines changed
Sources/MarkdownKit/AttributedString Expand file tree Collapse file tree 1 file changed +4
-6
lines changed Original file line number Diff line number Diff line change @@ -405,15 +405,13 @@ open class AttributedStringGenerator {
405
405
open var imgStyle : String {
406
406
if let maxWidth = self . maxImageWidth {
407
407
if let maxHeight = self . maxImageHeight {
408
- return " max-width: \( maxWidth) ;max-height: \( maxHeight) ; " +
409
- " !important; width: auto;height: auto;"
408
+ return " max-width: \( maxWidth) !important ;max-height: \( maxHeight) !important; " +
409
+ " width: auto;height: auto; "
410
410
} else {
411
- return " max-width: \( maxWidth) ;max-height: 100%; " +
412
- " !important;width: auto;height: auto; "
411
+ return " max-height: 100%;max-width: \( maxWidth) !important;width: auto;height: auto; "
413
412
}
414
413
} else if let maxHeight = self . maxImageHeight {
415
- return " max-width: 100%;max-height: \( maxHeight) ; " +
416
- " !important;width: auto;height: auto; "
414
+ return " max-width: 100%;max-height: \( maxHeight) !important;width: auto;height: auto; "
417
415
} else {
418
416
return " "
419
417
}
You can’t perform that action at this time.
0 commit comments