Skip to content

Commit 5ce7b92

Browse files
authored
Simplify logic for startResizing width calculation (#269)
* Apply Red's suggestion and move width logic to getWidth * remove unnecessary * a little more * remove comment
1 parent 81a9e74 commit 5ce7b92

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/app/common/common.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -1301,7 +1301,7 @@ class ResizableSidebar extends React.Component<ResizableSidebarProps> {
13011301
const mainSidebarModel = GlobalModel.mainSidebarModel;
13021302
const collapsed = mainSidebarModel.getCollapsed();
13031303

1304-
this.resizeStartWidth = collapsed ? MagicLayout.MainSidebarMinWidth : mainSidebarModel.getWidth();
1304+
this.resizeStartWidth = mainSidebarModel.getWidth();
13051305
document.addEventListener("mousemove", this.onMouseMove);
13061306
document.addEventListener("mouseup", this.stopResizing);
13071307

0 commit comments

Comments
 (0)