pub enum Placement {
Show 22 variants
Bottom,
BottomStart,
BottomLeft,
BottomEnd,
BottomRight,
Top,
TopStart,
TopLeft,
TopEnd,
TopRight,
Left,
LeftTop,
LeftBottom,
Right,
RightTop,
RightBottom,
Start,
StartTop,
StartBottom,
End,
EndTop,
EndBottom,
}Expand description
placement — where a floating panel sits relative to its trigger.
The full React Aria union v3 forwards: both physical spellings
("bottom left", "bottom right") and logical aliases ("start",
"end top", …) for every side. This port has no RTL mode, so the logical
start/end aliases resolve to the same pixels as their left/right
spellings; the spellings stay distinct values so ALL enumerates the
whole 22-value vocabulary a caller can name.
Variants§
Bottom
"bottom" — below the trigger, centred.
BottomStart
"bottom start" — below the trigger, flush with its start edge.
BottomLeft
"bottom left" — below the trigger, flush with its left edge; the
physical spelling of Placement::BottomStart in this LTR-only port.
BottomEnd
"bottom end" — below the trigger, flush with its end edge.
BottomRight
"bottom right" — below the trigger, flush with its right edge; the
physical spelling of Placement::BottomEnd here.
Top
"top" — above the trigger, centred.
TopStart
"top start" — above the trigger, flush with its start edge.
TopLeft
"top left" — above the trigger, flush with its left edge; the
physical spelling of Placement::TopStart here.
TopEnd
"top end" — above the trigger, flush with its end edge.
TopRight
"top right" — above the trigger, flush with its right edge; the
physical spelling of Placement::TopEnd here.
Left
"left" — beside the trigger’s left edge, vertically centred.
LeftTop
"left top" — beside the left edge, flush with the trigger’s top.
LeftBottom
"left bottom" — beside the left edge, flush with the trigger’s
bottom.
Right
"right" — beside the trigger’s right edge, vertically centred.
RightTop
"right top" — beside the right edge, flush with the trigger’s top.
RightBottom
"right bottom" — beside the right edge, flush with the trigger’s
bottom.
Start
"start" — the logical spelling of Placement::Left in an
LTR-only port.
StartTop
"start top" — the logical spelling of Placement::LeftTop here.
StartBottom
"start bottom" — the logical spelling of Placement::LeftBottom
here.
End
"end" — the logical spelling of Placement::Right in an
LTR-only port.
EndTop
"end top" — the logical spelling of Placement::RightTop here.
EndBottom
"end bottom" — the logical spelling of Placement::RightBottom
here.
Implementations§
Source§impl Placement
impl Placement
Sourcepub fn is_side(self) -> bool
pub fn is_side(self) -> bool
Whether the panel sits beside the trigger rather than above or below.
Sourcepub fn is_start_side(self) -> bool
pub fn is_start_side(self) -> bool
Whether the panel opens on the trigger’s start side — the left edge, because this port has no RTL mode.
Sourcepub fn align(self) -> PlacementAlign
pub fn align(self) -> PlacementAlign
The alignment along the trigger’s cross axis: horizontal for the top and bottom placements, vertical for the side ones.
Trait Implementations§
impl Copy for Placement
impl Eq for Placement
impl StructuralPartialEq for Placement
Auto Trait Implementations§
impl Freeze for Placement
impl RefUnwindSafe for Placement
impl Send for Placement
impl Sync for Placement
impl Unpin for Placement
impl UnsafeUnpin for Placement
impl UnwindSafe for Placement
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
ReadEndian::read_from_little_endian().