Page MenuHomePhabricator

When picking a default menu item to render, don't pick disabled items
ClosedPublic

Authored by epriestley on Mar 31 2019, 9:13 PM.
Tags
None
Referenced Files
F18754638: D20359.id48578.diff
Sun, Oct 5, 12:09 AM
F18596621: D20359.diff
Sat, Sep 13, 1:07 AM
F18518611: D20359.diff
Sep 5 2025, 3:26 PM
F18468340: D20359.id48578.diff
Sep 2 2025, 3:02 PM
F18467407: D20359.id48578.diff
Sep 2 2025, 12:40 PM
F18467007: D20359.id48579.diff
Sep 2 2025, 11:27 AM
F18245430: D20359.diff
Aug 21 2025, 9:46 AM
F18245385: D20359.diff
Aug 21 2025, 9:40 AM
Subscribers
None

Details

Summary

Depends on D20358. Fixes T12871. After refactoring, we can now tell when a "storage" menu item generated only disabled "display" menu items, and not pick any of them as the default rendering.

This means that if you're looking at a portal/menu with several dashboards, but can't see some at the top, you'll get the first one you can see.

Also clean up a lot of minor issues with less-common states.

Test Plan
  • Created a portal with two private dashboards and a public dashboard.
  • Viewed it as another user, saw the default view show the dashboard I can actually see.
  • Minor fix: Disabled and enabled the hard-coded "Home" item, now worked cleanly with the right menu state.
  • Minor fix: added a motivator panel.

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

src/applications/search/engine/PhabricatorProfileMenuItemViewList.php
96–101

This is the actual fix to T12871 after shuffling a thousand lines of code around.

This revision is now accepted and ready to land.Apr 2 2019, 9:01 PM
This revision was automatically updated to reflect the committed changes.