Improve app page with sorting, recommendations and more#520
Conversation
There was a problem hiding this comment.
Pull request overview
This PR enhances Win11Debloat’s GUI “App Removal” experience by adding sorting, recommendation indicators, quick-select presets sourced from Apps.json, and a contextual hint bubble, while also refactoring several previously inlined functions into dedicated script files.
Changes:
- Added sortable app table columns, recommendation indicators, and a “Quick Select” presets popup (including JSON-defined presets and “last used” selection).
- Refactored helper/threading/app-removal/feature execution logic into separate
Scripts/*files and updated imports. - Extended
Apps.jsonschema (v1.1) withRecommendationmetadata and a newPresetssection; added a reusable BubbleHint UI.
Reviewed changes
Copilot reviewed 21 out of 21 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| Win11Debloat.ps1 | Adds new schema/script paths and reorganizes imports to support new GUI/preset/threading features. |
| Scripts/Threading/DoEvents.ps1 | Extracts WPF message-pump helper used to keep UI responsive. |
| Scripts/Threading/Invoke-NonBlocking.ps1 | Adds runspace-based “non-blocking” execution helper for GUI responsiveness. |
| Scripts/Helpers/AddParameter.ps1 | Extracts parameter mutation helper. |
| Scripts/Helpers/CheckIfUserExists.ps1 | Extracts username validation helper. |
| Scripts/Helpers/CheckModernStandbySupport.ps1 | Extracts Modern Standby detection logic. |
| Scripts/Helpers/GenerateAppsList.ps1 | Extracts CLI app-list generation logic. |
| Scripts/Helpers/GetTargetUserForAppRemoval.ps1 | Extracts app-removal targeting logic. |
| Scripts/Helpers/GetFriendlyTargetUserName.ps1 | Extracts user-friendly target label helper. |
| Scripts/Helpers/GetUserDirectory.ps1 | Extracts user directory resolution helper. |
| Scripts/Helpers/GetUserName.ps1 | Extracts user name resolution helper. |
| Scripts/AppRemoval/GetInstalledAppsViaWinget.ps1 | Adds a reusable winget list wrapper with optional GUI-friendly execution. |
| Scripts/Features/ExecuteChanges.ps1 | Moves ExecuteParameter/ExecuteAllChanges out of the monolithic script. |
| Scripts/Features/CreateSystemRestorePoint.ps1 | Uses Invoke-NonBlocking to keep GUI responsive during restore-point operations. |
| Scripts/FileIO/LoadAppsDetailsFromJson.ps1 | Adds Recommendation field to returned app objects. |
| Scripts/FileIO/LoadAppPresetsFromJson.ps1 | Adds JSON preset reader for GUI quick-select presets. |
| Scripts/GUI/Show-MainWindow.ps1 | Implements sorting, preset handling, recommendation dot, loading changes, and hint bubble integration. |
| Scripts/GUI/Show-Bubble.ps1 | Adds contextual hint bubble popup (show/hide + animations). |
| Scripts/GUI/SetWindowThemeResources.ps1 | Adds titlebar hover/pressed theme resources. |
| Scripts/Get.ps1 | Adjusts cleanup exclusions to preserve an additional run log. |
| Schemas/MainWindow.xaml | Adds UI for sortable headers, quick-select presets popup, and loading spinner visuals. |
| Schemas/BubbleHint.xaml | Adds XAML for the hint bubble popup. |
| Schemas/MessageBoxWindow.xaml | Minor layout adjustment (MaxHeight). |
| Config/Apps.json | Bumps schema version to 1.1; adds Recommendation metadata and Presets. |
| .github/CONTRIBUTING.md | Updates guidance to avoid policies where possible. |
Comments suppressed due to low confidence (1)
Win11Debloat.ps1:173
- The required-file guard was updated for BubbleHint.xaml, but the PR also introduces new required script paths (e.g., $script:LoadAppsDetailsScriptPath / Scripts/GUI/Show-Bubble.ps1 / Scripts/Threading/*). If any of these are missing, dot-sourcing will fail later with a less actionable error. Consider expanding this startup check to include the new required script files so failures are caught early with a clear message.
# Check if script has all required files
if (-not ((Test-Path $script:DefaultSettingsFilePath) -and (Test-Path $script:AppsListFilePath) -and (Test-Path $script:RegfilesPath) -and (Test-Path $script:AssetsPath) -and (Test-Path $script:AppSelectionSchema) -and (Test-Path $script:ApplyChangesWindowSchema) -and (Test-Path $script:SharedStylesSchema) -and (Test-Path $script:BubbleHintSchema) -and (Test-Path $script:FeaturesFilePath))) {
Write-Error "Win11Debloat is unable to find required files, please ensure all script files are present"
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
This PR enhances the Win11Debloat GUI App Removal experience by adding richer app metadata (recommendations), sortable columns, and preset-based selection, while also introducing non-blocking loading patterns and some modularization into Scripts/*.
Changes:
- Add app table sorting, recommendation indicator, and “Quick Select” presets to the main window App Removal tab.
- Load app details/presets from
Config/Apps.json(v1.1) and extend app metadata with aRecommendationfield. - Introduce non-blocking/background execution helpers and a WinGet-installed-apps loader to keep the UI responsive.
Reviewed changes
Copilot reviewed 24 out of 24 changed files in this pull request and generated 8 comments.
Show a summary per file
| File | Description |
|---|---|
| Win11Debloat.ps1 | Adds additional script imports and timeout support in Invoke-NonBlocking; however, introduces conflicting function definitions/imports. |
| Scripts/Threading/Invoke-NonBlocking.ps1 | Adds a standalone non-blocking runner (currently not wired in). |
| Scripts/Threading/DoEvents.ps1 | Adds a standalone WPF message pump helper (currently not wired in). |
| Scripts/Helpers/GetUserName.ps1 | Adds helper for resolving target username (currently not wired in). |
| Scripts/Helpers/GetUserDirectory.ps1 | Adds helper for locating a user profile path. |
| Scripts/Helpers/GetTargetUserForAppRemoval.ps1 | Adds helper for app-removal targeting mode. |
| Scripts/Helpers/GetFriendlyTargetUserName.ps1 | Adds helper for friendly target user name formatting. |
| Scripts/Helpers/GenerateAppsList.ps1 | Adds helper to build app list from CLI params. |
| Scripts/Helpers/CheckModernStandbySupport.ps1 | Adds helper to detect Modern Standby support. |
| Scripts/Helpers/CheckIfUserExists.ps1 | Adds helper for basic username/path existence validation. |
| Scripts/Helpers/AddParameter.ps1 | Adds helper for mutating $script:Params. |
| Scripts/Get.ps1 | Adjusts temp cleanup exclusions to preserve Win11Debloat-Run.log. |
| Scripts/GUI/Show-MainWindow.ps1 | Major UI changes: presets popup, dynamic preset checkboxes, sorting, recommendation dot, and non-blocking app loading. |
| Scripts/GUI/Show-ApplyModal.ps1 | Suppresses extraneous output from event handler wiring. |
| Scripts/GUI/Show-AppSelectionWindow.ps1 | Suppresses extraneous output from dispatcher invocation. |
| Scripts/GUI/SetWindowThemeResources.ps1 | Adds titlebar hover/pressed brush resources. |
| Scripts/FileIO/LoadAppsDetailsFromJson.ps1 | Extends loaded app model with Recommendation. |
| Scripts/FileIO/LoadAppPresetsFromJson.ps1 | Adds JSON preset loader for “Quick Select”. |
| Scripts/Features/ExecuteChanges.ps1 | Adds modularized change execution logic. |
| Scripts/Features/CreateSystemRestorePoint.ps1 | Switches restore point operations to Invoke-NonBlocking with timeouts. |
| Scripts/AppRemoval/GetInstalledAppsViaWinget.ps1 | Adds WinGet installed-app list retrieval with optional non-blocking mode. |
| Schemas/MainWindow.xaml | Updates App Removal UI layout for sorting headers, presets popup, recommendation dot, and improved loading indicator. |
| Config/Apps.json | Bumps version to 1.1, adds Recommendation per app, and introduces Presets. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
This PR upgrades the Win11Debloat GUI “App Removal” experience by adding sortable columns, recommendation indicators, and JSON-defined “Quick Select” presets, while also refactoring a large set of inline functions into dedicated script modules (threading/helpers/features/app-removal).
Changes:
- Add app-list sorting, recommendation dots, and preset-based bulk selection in the main GUI window.
- Introduce non-blocking/background execution helpers (with optional timeouts) and refactor several previously-inline functions into separate script files.
- Extend
Config/Apps.jsonwith per-appRecommendationmetadata and a newPresetssection consumed by the GUI.
Reviewed changes
Copilot reviewed 24 out of 24 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| Win11Debloat.ps1 | Reorganizes dot-sourced imports and adds script path vars to support refactor/new GUI behaviors. |
| Scripts/Threading/Invoke-NonBlocking.ps1 | Adds reusable non-blocking runspace execution helper with optional timeout. |
| Scripts/Threading/DoEvents.ps1 | Extracts WPF message-pump helper for UI responsiveness during long operations. |
| Scripts/Helpers/AddParameter.ps1 | Extracts parameter mutation helper from the main script. |
| Scripts/Helpers/CheckIfUserExists.ps1 | Extracts user existence validation helper. |
| Scripts/Helpers/CheckModernStandbySupport.ps1 | Extracts modern standby detection helper. |
| Scripts/Helpers/GenerateAppsList.ps1 | Extracts app removal list generation helper. |
| Scripts/Helpers/GetFriendlyTargetUserName.ps1 | Extracts app-removal target display helper. |
| Scripts/Helpers/GetTargetUserForAppRemoval.ps1 | Extracts app-removal target resolution helper. |
| Scripts/Helpers/GetUserDirectory.ps1 | Extracts user profile path resolution helper. |
| Scripts/Helpers/GetUserName.ps1 | Extracts effective username helper. |
| Scripts/AppRemoval/GetInstalledAppsViaWinget.ps1 | Adds a winget “installed apps” loader with a non-blocking option for GUI usage. |
| Scripts/Features/ExecuteChanges.ps1 | Moves ExecuteParameter/ExecuteAllChanges into a dedicated module. |
| Scripts/Features/CreateSystemRestorePoint.ps1 | Refactors restore point creation to use Invoke-NonBlocking with timeouts. |
| Scripts/GUI/Show-MainWindow.ps1 | Implements sorting, presets popup, recommendation dots, and revamped app loading flow. |
| Scripts/GUI/Show-ApplyModal.ps1 | Minor adjustment to suppress dispatcher call output (Out-Null). |
| Scripts/GUI/Show-AppSelectionWindow.ps1 | Minor adjustment to suppress dispatcher call output (Out-Null). |
| Scripts/GUI/SetWindowThemeResources.ps1 | Adds theme resources for titlebar button hover/pressed backgrounds. |
| Scripts/FileIO/LoadAppsDetailsFromJson.ps1 | Extends app metadata objects to include Recommendation. |
| Scripts/FileIO/LoadAppPresetsFromJson.ps1 | New loader for JSON-defined app presets from Apps.json. |
| Scripts/Get.ps1 | Preserves the new run log during temp directory cleanup. |
| Schemas/MainWindow.xaml | Adds UI for sortable headers, presets popup, loading spinner, and new resource keys. |
| README.md | Updates feature list text (removing Windows-version qualifiers). |
| Config/Apps.json | Bumps schema version, adds Recommendation fields, and introduces Presets. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
This PR enhances the Win11Debloat GUI “App Removal” experience by adding sorting, recommendation indicators, and preset-based selection, while also refactoring large inline helper logic into dedicated script files.
Changes:
- Added sortable app table headers, recommendation “dot” indicators, and a “Quick Select” presets popup (including JSON-defined presets and “last used” selection).
- Refactored a number of previously-inline functions into
Scripts/Helpers/andScripts/Threading/, and introducedInvoke-NonBlockingto keep the GUI responsive during longer operations. - Extended
Config/Apps.jsonschema (v1.1) withRecommendationmetadata and a newPresetssection; updated file cleanup and minor UI/theme resource tweaks.
Reviewed changes
Copilot reviewed 25 out of 25 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| Win11Debloat.ps1 | Reorganized dot-sourced imports; introduces new helper/threading/app-removal modules. |
| Scripts/Threading/Invoke-NonBlocking.ps1 | New non-blocking execution helper with optional timeout handling. |
| Scripts/Threading/DoEvents.ps1 | New UI message pump helper used by non-blocking work in GUI mode. |
| Scripts/Helpers/*.ps1 | Extracted helper functions (user targeting, parameter handling, etc.). |
| Scripts/AppRemoval/GetInstalledAppsViaWinget.ps1 | Centralized WinGet “list installed” logic with non-blocking option. |
| Scripts/Features/ExecuteChanges.ps1 | Moved execution orchestration (ExecuteParameter/ExecuteAllChanges) out of the root script. |
| Scripts/Features/CreateSystemRestorePoint.ps1 | Switched restore-point operations to the new non-blocking helper. |
| Scripts/FileIO/LoadAppsDetailsFromJson.ps1 | Adds Recommendation field to returned app objects. |
| Scripts/FileIO/LoadAppPresetsFromJson.ps1 | New loader for JSON-defined app selection presets. |
| Scripts/GUI/Show-MainWindow.ps1 | Implements sorting UI, presets UI/logic, non-blocking app loading, and recommendations display. |
| Scripts/GUI/ApplySettingsToUiControls.ps1 | Optimizes settings application using a featureId reverse index. |
| Schemas/MainWindow.xaml | Adds sortable headers, preset popup, recommendation column styles, and various UI polish. |
| Scripts/Get.ps1 | Preserves an additional log file during temp cleanup. |
| Scripts/GUI/Show-ApplyModal.ps1 | Suppresses event-handler return output (Out-Null). |
| Scripts/GUI/Show-AppSelectionWindow.ps1 | Suppresses dispatcher invoke output (Out-Null). |
| Scripts/GUI/SetWindowThemeResources.ps1 | Adds titlebar hover/pressed resource brushes. |
| README.md | Updates feature list formatting/content (removes repeated “W11 only” notes). |
| Config/Apps.json | Bumps schema version; adds per-app recommendation + preset definitions. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
No description provided.