pub struct ContainerBuilder { /* private fields */ }Expand description
<Container>: a frame around other components, like an embed, with an optional accent bar
Implementations§
Source§impl ContainerBuilder
impl ContainerBuilder
Sourcepub fn id(self, value: impl IntoAttr<Option<i32>>) -> Self
pub fn id(self, value: impl IntoAttr<Option<i32>>) -> Self
i32: identifier unique within the message; Discord numbers components without one
Sourcepub fn accent_color(self, value: impl IntoAttr<Option<u32>>) -> Self
pub fn accent_color(self, value: impl IntoAttr<Option<u32>>) -> Self
u32 (0xRRGGBB): color of the bar on the left; none when unset
Sourcepub fn spoiler(self, value: impl IntoAttr<Option<bool>>) -> Self
pub fn spoiler(self, value: impl IntoAttr<Option<bool>>) -> Self
bool: blurs the content until clicked
Sourcepub fn child(self, child: impl ContainerChild) -> Self
pub fn child(self, child: impl ContainerChild) -> Self
Adds a child: text, <Text>, <Section>, <Gallery>, <File>, <Separator>, <Row>,
a component, a View or Props
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ContainerBuilder
impl RefUnwindSafe for ContainerBuilder
impl Send for ContainerBuilder
impl Sync for ContainerBuilder
impl Unpin for ContainerBuilder
impl UnsafeUnpin for ContainerBuilder
impl UnwindSafe for ContainerBuilder
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
Mutably borrows from an owned value. Read more