diff --git a/src/core/view/components/image/index.vue b/src/core/view/components/image/index.vue index f08c6b047806a355d2eea76751107af713097a9f..4d63ecc51ab88206e8e38edd6c7461d00fbf0bd1 100644 --- a/src/core/view/components/image/index.vue +++ b/src/core/view/components/image/index.vue @@ -172,8 +172,8 @@ export default { const img = this._img = this._img || new Image() img.onload = $event => { this._img = null - this.originalWidth = img.width - this.originalHeight = img.height + const width = this.originalWidth = img.width + const height = this.originalHeight = img.height this._fixSize() @@ -186,8 +186,8 @@ export default { this.$el.appendChild(img) this.$trigger('load', $event, { - width: img.width, - height: img.height + width, + height }) } img.onerror = $event => {