From 56cf1b98d331c88eb6b0de8d03a85ce06f19f901 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期六, 22 一月 2022 00:23:01 +0800
Subject: [PATCH] 2022-01-22

---
 src/views/mobdesign/index.jsx |   19 ++++++++++++-------
 1 files changed, 12 insertions(+), 7 deletions(-)

diff --git a/src/views/mobdesign/index.jsx b/src/views/mobdesign/index.jsx
index c10b914..7145ac9 100644
--- a/src/views/mobdesign/index.jsx
+++ b/src/views/mobdesign/index.jsx
@@ -1464,13 +1464,18 @@
   insert = (item) => {
     let config = fromJS(this.state.config).toJS()
 
-    if (item.type === 'topbar' && config.components.findIndex(m => m.type === 'topbar') > -1) {
-      notification.warning({
-        top: 92,
-        message: '瀵艰埅鏍忎笉鍙噸澶嶆坊鍔狅紒',
-        duration: 5
-      })
-      return
+    if (item.type === 'topbar') {
+      if (config.components.findIndex(m => m.type === 'topbar') > -1) {
+        notification.warning({
+          top: 92,
+          message: '瀵艰埅鏍忎笉鍙噸澶嶆坊鍔狅紒',
+          duration: 5
+        })
+        return
+      }
+      if (!config.style.paddingTop) {
+        config.style.paddingTop = '50px'
+      }
     }
 
     config.components.push(item)

--
Gitblit v1.8.0