Commit f7eb6c6
feat(content-drive): merge base-type + content-type filters into one chip
Replaces the two separate Base Type and Content Type filters in the
content drive toolbar with a single merged chip-style filter built on
the new `dot-chip-filter` + `<p-popover>` + `<p-listbox>` pattern.
Layout:
- Two-column popover (Base Type / Content Type)
- Left listbox uses single-select for the focused base type plus an
inline checkbox per row for the actual filter selection. An
"All Content" row sits at the top to browse every type without
narrowing.
- Right listbox is multi-select with checkbox + filter input + virtual
scroll + lazy load. Filtered by the focused base type only — never
by all selected ones.
- Selected content types are pinned to the top of the right list so
they remain visible across focus changes.
- Panel content is mounted with @if while the popover is open so the
listbox's virtual scroll measures real dimensions on each open
(otherwise it computes 0 visible items behind the hidden overlay).
Selection cascade rules:
- Selecting a content type selects its parent base type.
- Unselecting the last content type of a base type drops the base type.
- Unselecting a base type drops all its content types.
- Selecting a base type alone never auto-selects content types.
Chip label rules (per ticket):
- `Name (All)` for a base type selected without narrowing.
- Specific content type names when narrowed.
- Mixed states combine both.
Other:
- Reverts the chip-filter `clicked` output back to `output<Event>()`
so consumers can pass it to `popover.toggle($event)` for positioning.
- Removes the old base-type-selector and content-type-field components
and updates the toolbar to render the merged filter.
- Adds i18n keys for the new filter (title, columns, all-content, all).
- Tests drive every interaction through events on rendered elements
rather than calling protected methods.
Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>1 parent 34f4626 commit f7eb6c6
14 files changed
Lines changed: 1205 additions & 1505 deletions
File tree
- core-web/libs/portlets/dot-content-drive
- portlet/src/lib/components/dot-content-drive-toolbar
- components
- dot-content-drive-base-type-selector
- dot-content-drive-content-type-field
- dot-content-drive-content-type-filter
- ui/src/lib/dot-chip-filter
- dotCMS/src/main/webapp/WEB-INF/messages
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
0 commit comments