fix(explore): hide value input for unary filter operators#39924
Conversation
Code Review Agent Run #154654Actionable Suggestions - 0Additional Suggestions - 1
Review Details
Bito Usage GuideCommands Type the following command in the pull request comment and save the comment.
Refer to the documentation for additional commands. Configuration This repository uses Documentation & Help |
|
@massucattoj looks ready to go after a rebase. |
…hide-unary-operator-value # Conflicts: # superset-frontend/src/explore/components/controls/FilterControl/AdhocFilterEditPopoverSimpleTabContent/index.tsx
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #39924 +/- ##
=======================================
Coverage 64.20% 64.20%
=======================================
Files 2592 2592
Lines 139232 139232
Branches 32327 32327
=======================================
Hits 89389 89389
Misses 48308 48308
Partials 1535 1535
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
Bito Automatic Review Skipped – PR Already Merged |
SUMMARY
In the Explore filter popover (Simple tab), when a unary operator was selected
(
IS NULL,IS NOT NULL,IS TRUE,IS FALSE), the value input below theoperator dropdown was rendered in a disabled (grayed-out) state instead of
being hidden. Disabled inputs that can never be interacted with create visual
noise and confuse users about what is required to complete the filter.
This change hides the value control entirely whenever the selected operator
appears in
DISABLE_INPUT_OPERATORS, so only the column and operator fieldsare shown for unary operators.
BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
Before:

After:

TESTING INSTRUCTIONS
birth_namesor anydataset).
+ Add filter.Is null,Is not null,Is true, orIs false.all (previously it rendered as a disabled/grayed input).
Equal to,In) shouldrestore the value input.
Automated coverage: see four new tests in
AdhocFilterEditPopoverSimpleTabContent.test.tsxasserting that the valueinput is not in the document for each unary operator.
ADDITIONAL INFORMATION