feat(desktop): Add Hide/Show Desktop Icons Feature #48
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Adds a context menu option to toggle visibility of all desktop icons (including Trash). The menu text dynamically switches between "Hide Desktop Icons" and "Show Desktop Icons" based on current state. Preference persists across sessions and syncs in real-time across browser tabs.
Close Features
Closes Issue #5 - Implement dynamic top toolbar #9
Workflow
Key Changes
hide_desktop_iconspreference with cloud storage persistencetoggle_desktop_icons_visibility()helper functionImplementation Details
Approach: Uses CSS
.item-hiddenclass to toggle visibility without destroying DOM elements, preserving icon positions and event handlers.Critical Fix: Visibility is applied inside
refresh_item_container.jsafter items are loaded (not before), fixing async timing issue where icons would reappear after page refresh.Scope: Desktop only - does not affect file explorer windows.
Files Modified:
src/gui/src/globals.js- Default preferencesrc/gui/src/helpers.js- Toggle functionsrc/gui/src/UI/UIDesktop.js- Context menu + preference loadingsrc/gui/src/helpers/refresh_item_container.js- Apply visibility after item loadsrc/gui/src/i18n/translations/*.js- 37 language translations