|
|
@@ -1163,8 +1163,10 @@ export default {
|
|
|
},
|
|
|
},
|
|
|
mounted() {
|
|
|
- let totalWidth = document.querySelector('.newWord-preview').offsetWidth;
|
|
|
- this.width = `${totalWidth - (this.data.property.sn_display_mode === 'true' ? 15 : 0)}px`;
|
|
|
+ this.$nextTick(() => {
|
|
|
+ let totalWidth = document.querySelector('.newWord-preview').offsetWidth;
|
|
|
+ this.width = `${totalWidth - (this.data.property.sn_display_mode === 'true' ? 15 : 0)}px`;
|
|
|
+ });
|
|
|
|
|
|
this.dataHeight = this.$refs.previewContainer.style.height;
|
|
|
},
|