enforce max image height

This commit is contained in:
Alina Beck 2019-12-02 16:14:18 +03:00
parent d97973ab79
commit bf7042c423

View File

@ -143,7 +143,7 @@ export default {
},
mounted() {
const width = this.$el.offsetWidth
const height = width / this.post.imageAspectRatio
const height = Math.min((width / this.post.imageAspectRatio), 2000)
const imageElement = this.$el.querySelector('.ds-card-image')
if (imageElement) {