瀏覽代碼

fix(deps): 解决firefox下`正在切换主题`这个全局提示无法关闭的问题

free pan 5 年之前
父節點
當前提交
5f2d28d533
共有 1 個文件被更改,包括 3 次插入1 次删除
  1. 3 1
      src/components/SettingDrawer/settingConfig.js

+ 3 - 1
src/components/SettingDrawer/settingConfig.js

@@ -34,7 +34,9 @@ const colorList = [
 const updateTheme = newPrimaryColor => {
   const hideMessage = message.loading('正在切换主题!', 0)
   themeColor.changeColor(newPrimaryColor).finally(t => {
-    hideMessage()
+    setTimeout(() => {
+      hideMessage()
+    })
   })
 }