@@ -768,17 +768,26 @@ body.active_admin {
768768 }
769769 }
770770 div .dropdown_menu {
771+ // Containing block for the panel below, so `right: 0` means "the
772+ // trigger's right edge". AA leaves this element unpositioned, which
773+ // makes the panel resolve against #title_bar (sticky) and park at the
774+ // bar's far right no matter which action item was clicked. inline-block
775+ // over AA's `display: inline`: an inline box's containing block spans
776+ // its text fragments, so the markup's whitespace around the button
777+ // pushed the panel a few px past the button's edge.
778+ position : relative ;
779+ display : inline-block ;
771780 div .dropdown_menu_list_wrapper {
772- // Always right-align title-bar dropdowns, overriding AA's inline
773- // positioning. AA 3.x's _position() sets inline `left` OR `right`
774- // per open depending on a window-geometry branch and never clears
775- // the other, and the wrapper persists across opens — after a resize
776- // between opens both offsets accumulate and the width:auto wrapper
777- // stretches from the stale left coordinate to the right edge.
778- // Title-bar action items sit at the bar's right edge, so pinning
779- // right is also simply the correct alignment . Consumer apps used to
780- // carry exactly this pair as a local hotfix; the theme owns the bar
781- // now, so it owns the guard.
781+ // Always right-align title-bar dropdowns under their own button,
782+ // overriding AA's inline positioning. AA 3.x's _position() sets
783+ // inline `left` OR `right` per open depending on a window-geometry
784+ // branch and never clears the other, and the wrapper persists across
785+ // opens — after a resize between opens both offsets accumulate and
786+ // the width:auto wrapper stretches from the stale left coordinate to
787+ // the right edge. Its `right` branch is wrong here anyway: it offsets
788+ // from the window, not from the bar . Consumer apps used to carry
789+ // exactly this pair as a local hotfix; the theme owns the bar now, so
790+ // it owns the guard.
782791 left : auto !important ;
783792 right : 0 !important ;
784793 background-color : var (--aa-elevated );
@@ -791,6 +800,12 @@ body.active_admin {
791800 // that is invisible whenever the panel fill is close to the page —
792801 // which is exactly what a light surface is. Outline it like the panel.
793802 div .dropdown_menu_nipple {
803+ // The panel is pinned right (above) while AA still offsets the
804+ // arrow from the panel's LEFT edge by the button's centre, which
805+ // lands it on empty bar. Pin it right too, centred on the button's
806+ // own caret (AA draws that 6px wide at right: 12px).
807+ left : auto !important ;
808+ right : 9px !important ;
794809 border-color : var (--aa-border ) transparent ;
795810 & :before , & :after { border-color : var (--aa-elevated ) transparent ; }
796811 }
0 commit comments