-
Notifications
You must be signed in to change notification settings - Fork 0
[CORRUPTED] Synthetic Benchmark PR #102792 - feat(dashboards): Use a single value selector for boolean filters #10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: base_pr_102792_20251204_5578
Are you sure you want to change the base?
Conversation
PR Compliance Guide 🔍Below is a summary of compliance checks for this PR:
Compliance status legend🟢 - Fully Compliant🟡 - Partial Compliant 🔴 - Not Compliant ⚪ - Requires Further Human Verification 🏷️ - Compliance label |
||||||||||||||||||||||||
PR Code Suggestions ✨Explore these optional code suggestions:
|
||||||||||||
User description
Benchmark PR getsentry#102792
Type: Corrupted (contains bugs)
Original PR Title: feat(dashboards): Use a single value selector for boolean filters
Original PR Description: Boolean filters previously used the multi select. If a list of booleans (e.g. [true,false]) is used in a widget query, an error is thrown by the backend because booleans are expected to be single values. To avoid this error completely, this PR uses a single value compact select for booleans (and any other filter token that doesn't support multi select).
Original PR URL: getsentry#102792
PR Type
Enhancement
Description
Use single value selector for boolean filters instead of multi-select
Export
tokenSupportsMultipleValuesfunction for reuse in filter selectorAdd logic to detect filters that don't support multiple values
Implement conditional rendering: CompactSelect for single-value filters, HybridFilter for multi-value
Extract menu header and trigger rendering into separate functions
Adjust menu width and improve filter UI consistency
Diagram Walkthrough
flowchart LR A["Filter Token"] --> B{"Supports Multiple Values?"} B -->|Yes| C["HybridFilter<br/>Multi-select"] B -->|No| D["CompactSelect<br/>Single-value"] C --> E["Dashboard Global Filter"] D --> EFile Walkthrough
valueCombobox.tsx
Export tokenSupportsMultipleValues functionstatic/app/components/searchQueryBuilder/tokens/filter/valueCombobox.tsx
tokenSupportsMultipleValuesfunction to make it available forexternal use
on field definition
addFilter.tsx
Add default value handling for boolean filtersstatic/app/views/dashboards/globalFilter/addFilter.tsx
APPLY_DEFAULT_VALUESconstant to specify which field value typesshould have default values applied
APPLY_DEFAULT_VALUES(STRING and BOOLEAN) instead of just checking if it's not STRING
filterSelector.tsx
Implement conditional single/multi-value filter selectorsstatic/app/views/dashboards/globalFilter/filterSelector.tsx
CompactSelectcomponent andtokenSupportsMultipleValuesfunction
canSelectMultipleValuesstate to determine which selectorcomponent to use
CompactSelectfor single-valuefilters,
HybridFilterfor multi-value filtersrenderMenuHeaderTrailingItemsandrenderFilterSelectorTriggerinto separate functions for code reuse
canSelectMultipleValuesto options dependency array