|
@@ -744,6 +744,19 @@ export default {
|
|
}
|
|
}
|
|
},
|
|
},
|
|
getPreviewTemp() {
|
|
getPreviewTemp() {
|
|
|
|
+ const elementDoms =
|
|
|
|
+ this.$refs.PaperTemplateView.$el.querySelectorAll(".elem-rich-text");
|
|
|
|
+ elementDoms.forEach((eDom) => {
|
|
|
|
+ const width = eDom.offsetWidth;
|
|
|
|
+ if (eDom.firstChild && eDom.firstChild.nodeName === "DIV") {
|
|
|
|
+ eDom.firstChild.style.width = width + "px";
|
|
|
|
+ if (
|
|
|
|
+ eDom.firstChild.firstChild &&
|
|
|
|
+ eDom.firstChild.firstChild.nodeName === "DIV"
|
|
|
|
+ )
|
|
|
|
+ eDom.firstChild.firstChild.style.width = width + "px";
|
|
|
|
+ }
|
|
|
|
+ });
|
|
return previewTemp(this.$refs.PaperTemplateView.$el.outerHTML);
|
|
return previewTemp(this.$refs.PaperTemplateView.$el.outerHTML);
|
|
},
|
|
},
|
|
async toDownload() {
|
|
async toDownload() {
|