pub struct DialogProps {Show 14 fields
pub children: Element,
pub title: Option<String>,
pub visible: bool,
pub width: String,
pub modal: bool,
pub close_on_click_modal: bool,
pub close_on_press_escape: bool,
pub align_center: bool,
pub draggable: bool,
pub show_close: bool,
pub top: String,
pub class: Option<String>,
pub style: Option<String>,
pub on_close: Option<EventHandler<()>>,
}Expand description
Dialog props
Fields§
§children: ElementDialog content
title: Option<String>Dialog title
visible: boolWhether the dialog is visible
width: StringDialog width (e.g., “50%”, “500px”)
modal: boolWhether to show a modal overlay
close_on_click_modal: boolWhether the dialog can be closed by clicking the mask
close_on_press_escape: boolWhether the dialog can be closed by pressing ESC
align_center: boolWhether to center the dialog
draggable: boolWhether the dialog is draggable
show_close: boolWhether to show close button
top: StringTop margin (e.g., “15vh”)
class: Option<String>Additional CSS classes
style: Option<String>Inline styles
on_close: Option<EventHandler<()>>Close event handler
Implementations§
Source§impl DialogProps
impl DialogProps
Sourcepub fn builder() -> DialogPropsBuilder<((), (), (), (), (), (), (), (), (), (), (), (), (), ())>
pub fn builder() -> DialogPropsBuilder<((), (), (), (), (), (), (), (), (), (), (), (), (), ())>
Create a builder for building DialogProps.
On the builder, call .children(...)(optional), .title(...)(optional), .visible(...)(optional), .width(...)(optional), .modal(...)(optional), .close_on_click_modal(...)(optional), .close_on_press_escape(...)(optional), .align_center(...)(optional), .draggable(...)(optional), .show_close(...)(optional), .top(...)(optional), .class(...)(optional), .style(...)(optional), .on_close(...)(optional) to set the values of the fields.
Finally, call .build() to create the instance of DialogProps.
Trait Implementations§
Source§impl Clone for DialogProps
impl Clone for DialogProps
Source§fn clone(&self) -> DialogProps
fn clone(&self) -> DialogProps
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl PartialEq for DialogProps
impl PartialEq for DialogProps
Source§fn eq(&self, other: &DialogProps) -> bool
fn eq(&self, other: &DialogProps) -> bool
self and other values to be equal, and is used by ==.