|
@@ -489,8 +489,19 @@ export default {
|
|
|
'data.unified_attrib': {
|
|
'data.unified_attrib': {
|
|
|
handler(val) {
|
|
handler(val) {
|
|
|
if (val) {
|
|
if (val) {
|
|
|
|
|
+ let oldAttrib = this.data.other_attrib;
|
|
|
this.articleAttrib = JSON.parse(JSON.stringify(val));
|
|
this.articleAttrib = JSON.parse(JSON.stringify(val));
|
|
|
- this.handleChangeStyles();
|
|
|
|
|
|
|
+ if (oldAttrib.oldFont && oldAttrib.oldFont !== val.font) {
|
|
|
|
|
+ this.$set(this.articleAttrib, 'font', oldAttrib.oldFont);
|
|
|
|
|
+ }
|
|
|
|
|
+ if (oldAttrib.oldColor && oldAttrib.oldColor !== val.text_color) {
|
|
|
|
|
+ this.$set(this.articleAttrib, 'text_color', oldAttrib.oldColor);
|
|
|
|
|
+ }
|
|
|
|
|
+ if (oldAttrib.align && oldAttrib.align !== val.align) {
|
|
|
|
|
+ this.$set(this.articleAttrib, 'align', oldAttrib.align);
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ // this.handleChangeStyles();
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
deep: true,
|
|
deep: true,
|
|
@@ -537,7 +548,8 @@ export default {
|
|
|
});
|
|
});
|
|
|
});
|
|
});
|
|
|
});
|
|
});
|
|
|
- } else if (this.articleAttrib.text_color !== this.data.other_attrib.oldColor) {
|
|
|
|
|
|
|
+ }
|
|
|
|
|
+ if (this.articleAttrib.text_color !== this.data.other_attrib.oldColor) {
|
|
|
this.data.other_attrib.oldColor = this.articleAttrib.text_color;
|
|
this.data.other_attrib.oldColor = this.articleAttrib.text_color;
|
|
|
this.data.detail.forEach((item) => {
|
|
this.data.detail.forEach((item) => {
|
|
|
item.wordsList.forEach((items) => {
|
|
item.wordsList.forEach((items) => {
|
|
@@ -546,7 +558,8 @@ export default {
|
|
|
});
|
|
});
|
|
|
});
|
|
});
|
|
|
});
|
|
});
|
|
|
- } else if (this.articleAttrib.align !== this.data.other_attrib.oldAlign) {
|
|
|
|
|
|
|
+ }
|
|
|
|
|
+ if (this.articleAttrib.align !== this.data.other_attrib.oldAlign) {
|
|
|
this.data.other_attrib.oldAlign = this.articleAttrib.align;
|
|
this.data.other_attrib.oldAlign = this.articleAttrib.align;
|
|
|
this.data.detail.forEach((item) => {
|
|
this.data.detail.forEach((item) => {
|
|
|
item.paraAlign =
|
|
item.paraAlign =
|