You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Anchored popups: report which side a placement flipped to #362
An anchored popup flips to the other side when there's no room. A nested submenu should open on the side its parent opened (a parent that flipped left opens its child to the left too), but the app can't learn the side Rune actually used.
Wanted: the resolved Side/Align of an anchored element, readable like Cx::layout (or passed to a callback).
Context: found while porting a chat client's desktop UI to Rune (pinned at 565de6b).
You can now read an anchored overlay's resolved (Side, Align) after RTL mirroring, zoom, and flip clamping with Cx::anchor_placement(key) (or rune::memo::anchor_placement(key) inside components without Cx). It participates in the existing layout-read settle loop and memo invalidation, re-running views and memos only when the resolved placement changes (never on non-flipping scrolls or resizes):
This follows Floating UI's resolved placement after flip middleware, paired with Rune's Cx::layout_with / memo::layout read conventions. In right-to-left subtrees it returns the physical resolved (Side, Align); if you need a logical or callback form instead, feel free to say so.
Verified with headless Runtime tests on Windows and macOS (unflipped, side flips, align flips, RTL mirroring, chained submenus, scroll/memo invalidation, resize settling), Linux cargo check --tests, and wasm32 WebGPU/WebGL checks. You can also see it in examples/kit-gallery (rune-popover--bounded). Not checked in a live desktop window.
Activity
Hona commentedon Nov 24, 2026
Implemented on
devin #1939 (fa636374e).You can now read an anchored overlay's resolved
(Side, Align)after RTL mirroring, zoom, and flip clamping withCx::anchor_placement(key)(orrune::memo::anchor_placement(key)inside components withoutCx). It participates in the existing layout-read settle loop andmemoinvalidation, re-running views and memos only when the resolved placement changes (never on non-flipping scrolls or resizes):This follows Floating UI's resolved
placementafterflipmiddleware, paired with Rune'sCx::layout_with/memo::layoutread conventions. In right-to-left subtrees it returns the physical resolved(Side, Align); if you need a logical or callback form instead, feel free to say so.Verified with headless
Runtimetests on Windows and macOS (unflipped, side flips, align flips, RTL mirroring, chained submenus, scroll/memo invalidation, resize settling), Linuxcargo check --tests, andwasm32WebGPU/WebGL checks. You can also see it inexamples/kit-gallery(rune-popover--bounded). Not checked in a live desktop window.