←
TRCKR-618
Created: 2025-12-26
•
Updated: 2025-12-28
Relationships
Loading...
Attachments
Loading...
Comments (2)
agent
·
2025-12-28
## Implementation Complete
### Changes Made
**1. Updated `server/templates/macros/filters.html`:**
- Created new `merged_filter_badge` macro that renders a single badge for multiple values of the same filter property
- Format: `property: value1, value2, value3`
- Single 'x' button removes all values for that property by passing 'ALL' to the handler
- Updated `filter_badges` macro to use merged badges instead of individual badges
**2. Updated JavaScript handlers in all templates:**
- `server/templates/issues.html`: Updated `removeFilter()` to handle 'ALL' value
- `server/templates/projects.html`: Updated `removeFilterProjects()` to handle 'ALL' value
- `server/templates/base.html`: Updated `removeFilterMilestones()` and `removeFilterDocuments()` to handle 'ALL' value
When `filterValue === 'ALL'`, the handler unchecks ALL checkboxes for that filter type instead of just one.
**3. Updated tests in `tests/test_web_helpers.py`:**
- Modified `TestFilterBadgesMacro` tests to expect merged badge behavior
- Tests verify comma-separated display, 'ALL' handler, and correct data-testid attributes
### Testing
- All 50 web helper tests pass
- All filter badge-related functionality tested
### Example Behavior
Before: Selecting 'low' and 'medium' priority showed separate badges:
- `priority: low` (x)
- `priority: medium` (x)
After: Shows a single merged badge:
- `priority: low, medium` (x) - clicking x clears both values
triage-agent
·
2025-12-28
## Feature Triage Complete
**Status:** NOT IMPLEMENTED
**Summary:** The requested feature to merge multiple filter badges of the same property into a single badge does not currently exist. The current implementation in `server/templates/macros/filters.html` creates individual badges for each filter value.
**Implementation Location:**
- Primary: `server/templates/macros/filters.html` - Add `merged_filter_badge` macro
- Secondary: JavaScript handlers in issues.html, projects.html, base.html, comments.html need updates to handle clearing all values
**Complexity:** LOW - Straightforward template changes with no backend impact
**Key Changes:**
1. Create new `merged_filter_badge` macro for multi-value rendering
2. Update `filter_badges` macro to use merged badge when >1 value
3. Update all `removeFilter*()` JS handlers to support 'ALL' parameter
See attached document for full triage report.