summaryrefslogtreecommitdiff
path: root/ext
diff options
context:
space:
mode:
authortoasted-nutbread <toasted-nutbread@users.noreply.github.com>2021-07-22 18:11:46 -0400
committerGitHub <noreply@github.com>2021-07-22 18:11:46 -0400
commit73f06a3fa087af164c54b57b2d92466d689d107e (patch)
treed3105b40848cf3465ebf4e15732872bbc1748487 /ext
parent2d367140938f6501430c6fcb96faef797e75789c (diff)
Fix definition image aspect ratio issue (#1847)
* Fix incorrect aspect ratio * Update test data
Diffstat (limited to 'ext')
-rw-r--r--ext/js/display/sandbox/structured-content-generator.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/js/display/sandbox/structured-content-generator.js b/ext/js/display/sandbox/structured-content-generator.js
index 833df6f6..f0e70c4d 100644
--- a/ext/js/display/sandbox/structured-content-generator.js
+++ b/ext/js/display/sandbox/structured-content-generator.js
@@ -91,7 +91,7 @@ class StructuredContentGenerator {
const usedWidth = (
hasPreferredWidth ?
preferredWidth :
- (hasPreferredHeight ? preferredHeight * invAspectRatio : width)
+ (hasPreferredHeight ? preferredHeight / invAspectRatio : width)
);
const node = this._createElement('a', 'gloss-image-link');