Allow Explorer Icon to Toggle Sidebar Visibility (like VSCode)

Please make the Explorer icon (and other Activity Bar icons) toggle the sidebar’s visibility.

Current Behavior:
Clicking the Explorer icon only opens the sidebar. It does not close it if it’s already open.

Desired Behavior (like VSCode):
Clicking the active Explorer icon should close the sidebar. This provides a fast, intuitive way for mouse users to toggle the sidebar without needing the keyboard shortcut (Cmd/Ctrl + B).

This change would improve workflow efficiency and align Cursor with the user experience many expect from a VSCode-based editor.

1 Like

Hey, which version of Cursor are you using? I just checked, and clicking the icon opens and closes the sidebar for me.

I’m using 1.1.7 on macOSon macOS. I’ve switched the activity bar orientation to vertical like the VS code default and the behaviour is as expected, but the horizontal orientation does not behave the same.

+1 for the suggestion

I am using ver. 1.4.3. and horizontal layout.

Currently, clicking on the active Bar Icon will make this message pop up

This is truly anti-intuitive for mouse users. I believe most users will expect the sidebar being collapsed when active Bar Icon is clicked (and actually, you even put a message + “Hide Sidebar” button for this). Also, when I want to collapse the side bar at the “left”, I have to click the button at the “top-right”, this is also anti-intuitive.

So, here are my suggestions:

  1. Just collapse the side bar when active Bar Icon is clicked, and make the hint message pop up only for first time.

  2. A “X” (close) button for closing the left sidebar, just like the one you already have for AI chat sidebar

  3. Maybe introduce a new button at the top-left to expand the left sidebar (for horizontal layout). You know, we look left when we want to find a thing on the left

Hope these suggestions can help.

So I was also frustrated with this, and came to know we need to set this setting in order to get the desired behaviour.

“workbench.activityBar.orientation”: “vertical”

This will then close the sidebar after clicking on the active explorer icon.