fix(web): hide fullscreen button when workspace has no changes - #4393
fix(web): hide fullscreen button when workspace has no changes#4393terrytangyuan wants to merge 5 commits into
Conversation
The maximize/minimize toggle was shown even when the workspace panel displayed "No workspace changes yet," offering no useful action. Gate the button on having changed files, an open file tab, or an open terminal tab. Signed-off-by: Yuan Tang <terrytangyuan@gmail.com>
Signed-off-by: Yuan Tang <terrytangyuan@gmail.com>
Pass changedCount: 1 in tests that assert the fullscreen button is present, and add a test verifying the button is hidden when the workspace has no changes and no open tabs. Signed-off-by: Yuan Tang <terrytangyuan@gmail.com>
The fullscreen button is now hidden when changedCount is 0, so the maximize tests need at least one changed file to render the button. Signed-off-by: Yuan Tang <terrytangyuan@gmail.com>
Signed-off-by: Yuan Tang <terrytangyuan@gmail.com>
|
Hey @terrytangyuan, I think the full screen button applies to other tabs in the right sidebar too, such as the browser, shell, etc. It may be confusing to hide the full screen button in some tabs and show it in others. I think the uniform thing to do would be to keep it as is and always allow to full screen the right sidebar regardless of its state or which tab is active right? |
|
You are right. I figured out the problem I had: it was the background transparency issue which I am fixing in another PR. We can close this one. |
|
Closed. If you want to pick this back up, comment |
|
This is the PR I was referring to: #4376 |
Related issue
N/A
Summary
The workspace panel's fullscreen (maximize/minimize) button was always rendered, even when the panel showed "No workspace changes yet." This offered no useful action since there was nothing to maximize. The button is now conditionally rendered — it only appears when there are changed files, an open file tab, or an open terminal tab.
Test Plan
changedCount > 0— confirm the fullscreen button appears.Demo
Type of change
Test coverage
Coverage notes
Verified manually by inspecting the workspace panel in empty-state and with-changes-state scenarios.
Changelog
The fullscreen button in the workspace panel no longer appears when there are no workspace changes to display.