From 680320ba761228905556375c6561c35651d69344 Mon Sep 17 00:00:00 2001 From: wanglin2 <1013335014@qq.com> Date: Sat, 12 Aug 2023 15:10:46 +0800 Subject: [PATCH] =?UTF-8?q?Demo:=E4=BF=AE=E5=A4=8D=E5=9F=BA=E7=A1=80?= =?UTF-8?q?=E6=A0=B7=E5=BC=8F=E4=BE=A7=E8=BE=B9=E6=A0=8F=E6=89=93=E5=BC=80?= =?UTF-8?q?=E7=8A=B6=E6=80=81=E4=B8=8B,=E5=AF=BC=E5=85=A5=E6=80=9D?= =?UTF-8?q?=E7=BB=B4=E5=AF=BC=E5=9B=BE=E6=95=B0=E6=8D=AE=E5=90=8E=E4=BE=A7?= =?UTF-8?q?=E8=BE=B9=E6=A0=8F=E6=95=B0=E6=8D=AE=E6=9C=AA=E6=9B=B4=E6=96=B0?= =?UTF-8?q?=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- web/src/pages/Edit/components/BaseStyle.vue | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/web/src/pages/Edit/components/BaseStyle.vue b/web/src/pages/Edit/components/BaseStyle.vue index d068ca7d..ef1e89dc 100644 --- a/web/src/pages/Edit/components/BaseStyle.vue +++ b/web/src/pages/Edit/components/BaseStyle.vue @@ -863,10 +863,21 @@ export default { this.enableNodeRichText = this.localConfig.openNodeRichText this.mousewheelAction = this.localConfig.mousewheelAction this.mousewheelZoomActionReverse = this.localConfig.mousewheelZoomActionReverse + this.$bus.$on('setData', this.onSetData) + }, + beforeDestroy() { + this.$bus.$off('setData', this.onSetData) }, methods: { ...mapMutations(['setLocalConfig']), + onSetData() { + if (this.activeSidebar !== 'baseStyle') return + setTimeout(() => { + this.initStyle() + }, 0) + }, + /** * @Author: 王林 * @Date: 2021-05-05 14:02:12