ROX-33539: Hide Attempted tab in Node violations by sachaudh · Pull Request #19444 · stackrox/stackrox
sachaudh
changed the title
ROX-33539: hide Attempted tab in Node violations
ROX-33539: Hide Attempted tab in Node violations
sachaudh
marked this pull request as ready for review
Node policies have no admission controller evaluation, so attempted alerts are never generated for nodes. The Attempted tab is now hidden when the Node workflow view is selected, and automatically resets to the Active tab if navigated to via URL. Fixes: ROX-33539 Signed-off-by: Saif Chaudhry <schaudhr@redhat.com>
Replace imported nodeWorkflowView constant with inline string literal to simplify the Node violations Attempted tab filtering logic. Signed-off-by: Saif Chaudhry <schaudhr@redhat.com>
Instead of using a useEffect to reactively reset the tab when switching to Node view, constrain the valid values passed to useURLStringUnion so the hook's built-in validation handles the fallback. This avoids an extra render cycle and expresses the constraint at initialization. Signed-off-by: Saif Chaudhry <schaudhr@redhat.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters