Skip to content

feat: add option to set uncategorized items as group#103

Merged
ngocjohn merged 7 commits intodevfrom
sort-ungrouped-items
Mar 25, 2026
Merged

feat: add option to set uncategorized items as group#103
ngocjohn merged 7 commits intodevfrom
sort-ungrouped-items

Conversation

@ngocjohn
Copy link
Copy Markdown
Owner

Refactor sidebar components for improved organization and handling of uncategorized items. Update styles for better layout and responsiveness, and introduce new selectors and elements for managing the bottom list in the sidebar. Implement a SidebarDialogPreview component for enhanced theme and notification management.

- Implemented `SidebarDialogPreview` component for rendering sidebar panels with customizable themes and notifications.
- Introduced `SidebarOrganizerTab` component for tab navigation within the sidebar.
- Created `config-area.ts` to define enums and types for dialog tags, configuration sections, and panel areas.
- Enhanced notification handling and theme application logic in the sidebar preview.
…items handling

- Refactored SidebarDialogPreview to streamline panel rendering and remove unused methods.
- Enhanced SidebarConfigDialog to manage uncategorized items more effectively, including state management and configuration updates.
- Renamed GROUPS to PANELS in DIALOG_TAG for consistency.
- Updated constants and types to reflect changes in panel handling.
- Improved SidebarOrganizer to handle new item parsing and logging.
- Added utility function to parse item values for better readability and maintainability.
- Adjusted styles for better layout and responsiveness in sidebar components.
@ngocjohn ngocjohn self-assigned this Mar 25, 2026
@ngocjohn ngocjohn marked this pull request as ready for review March 25, 2026 13:52
Copilot AI review requested due to automatic review settings March 25, 2026 13:52
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR refactors the sidebar organizer/editor architecture to better support panel organization (including treating remaining β€œuncategorized” items as a group), and introduces a new editor/menu structure plus shared utilities/components.

Changes:

  • Consolidate scattered utility modules into a single UTILITIES object and add new DOM helpers.
  • Refactor sidebar processing into clearer β€œorder/setup sections” phases and introduce bottom-list container handling.
  • Rework the config dialog into a section-based editor (menu + panels/new-items/preview), adding support for an β€œuncategorized items” grouping option.

Reviewed changes

Copilot reviewed 26 out of 31 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
src/utilities/model/store.ts Switches Store utility access to centralized UTILITIES.
src/utilities/index.ts Adds UTILITIES aggregate and exports fire_event.
src/utilities/dom-utils.ts Extends expansion panel helper and adds parseItemValues + mobile flags.
src/utilities/configs/validators.ts Updates config pick keys to new PANEL_TYPE names.
src/utilities/configs/clean-items.ts Updates config pick keys to new PANEL_TYPE names.
src/types/index.ts Adds new PANEL_TYPE values and uncategorized_items config option.
src/types/elements.ts Introduces ElementsStore type for sidebar DOM references.
src/sidebar-organizer.ts Major refactor of config processing and bottom-list handling.
src/constants/index.ts Re-exports config-area constants.
src/constants/dom.ts Adds selectors/classes for bottom list containers and a default-panel attribute.
src/constants/config-area.ts Adds config/editor sections, labels, and dialog tag enums.
src/components/so-profile-section.ts Updates logging + list styling.
src/components/sidebar-organizer-dialog_wa.ts Tweaks fullscreen behavior and header content.
src/components/sidebar-dialog.ts Refactors config dialog to use new menu/section approach and uncategorized support.
src/components/editor/sidebar-organizer-tab.ts Adds tab component (keyboard accessible).
src/components/editor/sidebar-dialog-preview.ts Refactors preview to BaseEditor and updates group rendering behavior.
src/components/editor/sidebar-dialog-panels.ts Replaces β€œgroups” editor with a broader β€œpanels” editor + all-items view.
src/components/editor/sidebar-dialog-new-items.ts Refactors new-items editor to BaseEditor.
src/components/editor/sidebar-dialog-menu.ts Adds new section navigation menu for editor.
src/components/editor/sidebar-dialog-colors.ts Refactors colors editor to BaseEditor.
src/components/editor/sidebar-dialog-code-editor.ts Refactors code editor to BaseEditor.
src/components/editor/shared/so-panel-all.ts Adds β€œAll Items” panel overview with expansion panels and uncategorized handling.
src/components/editor/shared/so-item-row.ts Adds a row component for panel display in the new β€œall items” view.
src/components/editor/index.ts Updates editor exports to new components.
src/components/editor/forms/theme-color-schema.ts Adds custom theme + force mode schema.
src/components/editor/forms/index.ts Barrel export for new form schemas.
src/components/editor/forms/header-schema.ts Adds appearance/header schema building blocks.
src/components/editor/forms/action-schema.ts Adds reusable action schema builders/constants.
src/components/editor-store.ts Introduces store object shared across editor components.
src/components/dialog-css.ts Extends shared dialog styles for new layouts/rows.
src/components/base-editor.ts Adds shared base class for editor components and centralized utilities/panel info lookup.
Comments suppressed due to low confidence (5)

src/components/editor/sidebar-dialog-preview.ts:10

  • These imports won't resolve with the current tsconfig.json path mappings (components/* and constants/* are not configured). Use the existing aliases (@constants, relative paths) or add path mappings consistently.
    src/components/editor/sidebar-dialog-panels.ts:26
  • BaseEditor is imported from components/base-editor, but tsconfig.json only defines @types, @constants, and @utilities/* path aliases. This will fail to compile unless you switch to a relative import (e.g. ../base-editor) or add a matching path mapping.
    src/components/editor/sidebar-dialog-panels.ts:1207
  • The HTMLElementTagNameMap entry is still keyed as 'sidebar-dialog-groups', but this file now defines <sidebar-dialog-panels>. Update the tag name in the type map so TS users get correct element typings.
    src/components/editor/sidebar-dialog-new-items.ts:8
  • These imports won't resolve as-is: components/base-editor and constants/config-area are not part of the configured TS path aliases, so this will break compilation. Use ../base-editor and @constants (or extend tsconfig paths) consistently.
    src/components/editor/sidebar-dialog-code-editor.ts:9
  • BaseEditor is imported from components/base-editor, but that path alias isn't configured in tsconfig.json (only @types, @constants, @utilities/*). This will fail TypeScript compilation unless changed to a relative import or a proper alias.

πŸ’‘ Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/sidebar-organizer.ts
Comment thread src/utilities/dom-utils.ts Outdated
Comment thread src/components/editor/sidebar-dialog-menu.ts
Comment thread src/components/editor/shared/so-panel-all.ts
Comment thread src/components/sidebar-dialog.ts
Comment thread src/components/base-editor.ts
@ngocjohn ngocjohn merged commit f8e27a9 into dev Mar 25, 2026
@ngocjohn ngocjohn deleted the sort-ungrouped-items branch March 25, 2026 14:07
github-actions Bot pushed a commit that referenced this pull request Mar 25, 2026
## [3.3.0-beta.1](v3.2.1-beta.1...v3.3.0-beta.1) (2026-03-25)

### Features

* add option to set uncategorized items as group ([#103](#103)) ([f8e27a9](f8e27a9))
@github-actions
Copy link
Copy Markdown

πŸŽ‰ This PR is included in version 3.3.0-beta.1 πŸŽ‰

The release is available on GitHub release

Your semantic-release bot πŸ“¦πŸš€

github-actions Bot pushed a commit that referenced this pull request Mar 29, 2026
## [3.3.0](v3.2.0...v3.3.0) (2026-03-29)

### Features

* add option to set uncategorized items as group ([#103](#103)) ([f8e27a9](f8e27a9))
* Add visibility templates for sidebar items and groups ([#104](#104)) ([ab3a8ae](ab3a8ae)), closes [#69](#69)

### Bug Fixes

* Improve tooltip styles for bottom grid item ([#101](#101)) ([6bc09a7](6bc09a7)), closes [#100](#100)
@github-actions
Copy link
Copy Markdown

πŸŽ‰ This PR is included in version 3.3.0 πŸŽ‰

The release is available on GitHub release

Your semantic-release bot πŸ“¦πŸš€

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants