Browse Source

Fixed a small bug when toggling items in toolbar

Hugo Häggmark 7 năm trước cách đây
mục cha
commit
67e8958aec
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      public/app/features/dashboard/dashgrid/EditorTabBody.tsx

+ 1 - 1
public/app/features/dashboard/dashgrid/EditorTabBody.tsx

@@ -52,7 +52,7 @@ export class EditorTabBody extends PureComponent<Props, State> {
   onToggleToolBarView = (item: EditorToolbarView) => {
     this.setState({
       openView: item,
-      isOpen: !this.state.isOpen,
+      isOpen: this.state.openView !== item ? true : !this.state.isOpen,
     });
   };