Struct ymc::menu::MenuProps[][src]

pub struct MenuProps {
    pub open: bool,
    pub anchor: Option<HtmlElement>,
    pub quick: bool,
    pub absolute: bool,
    pub fixed: bool,
    pub x: Option<isize>,
    pub y: Option<isize>,
    pub force_group_selection: bool,
    pub fullwidth: bool,
    pub wrap_focus: bool,
    pub inner_role: String,
    pub multi: bool,
    pub activatable: bool,
    pub onopened: Callback<()>,
    pub onclosed: Callback<()>,
    pub onaction: Callback<ListIndex>,
    pub onselected: Callback<SelectedDetail>,
    pub link: WeakComponentLink<Menu>,
    pub children: Children,
}

Props for Menu

Documentation properties and events

Fields

open: bool

Changing this prop re-renders the component. For general usage, consider using show method provided by WeakComponentLink<Menu> via menu_link

anchor: Option<HtmlElement>quick: boolabsolute: boolfixed: boolx: Option<isize>y: Option<isize>force_group_selection: boolfullwidth: boolwrap_focus: boolinner_role: Stringmulti: boolactivatable: boolonopened: Callback<()>

Binds to opened event on menu-surface

See events docs to learn more.

onclosed: Callback<()>

Binds to closed event on menu-surface

See events docs to learn more.

onaction: Callback<ListIndex>

Binds to action event on list

See events docs to learn more.

onselected: Callback<SelectedDetail>

Binds to selected event on list

See events docs to learn more.

link: WeakComponentLink<Menu>

WeakComponentLink for Menu which provides the following methods

  • get_focused_item_index(&self) -> usize
  • focus_item_at_index(&self, index: usize)
  • select(&self, index: &JsValue)
  • show(&self)
  • close(&self)

See WeakComponentLink documentation for more information

children: Children

Trait Implementations

impl Clone for MenuProps[src]

impl PartialEq<MenuProps> for MenuProps[src]

impl Properties for MenuProps[src]

type Builder = MenuPropsBuilder<MenuPropsBuilderStep_build>

Builder that will be used to construct properties

impl StructuralPartialEq for MenuProps[src]

Auto Trait Implementations

impl !RefUnwindSafe for MenuProps

impl !Send for MenuProps

impl !Sync for MenuProps

impl Unpin for MenuProps

impl !UnwindSafe for MenuProps

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Any for T where
    T: Any

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> CloneAny for T where
    T: Clone + Any

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.