pub trait ModalPluginInterface<T>where
    T: Debug + Clone + RespoAction,{
    // Required methods
    fn render(&self) -> Result<RespoNode<T>, String>
       where T: Clone + Debug;
    fn show(&self, dispatch: DispatchFn<T>) -> Result<(), String>;
    fn close(&self, dispatch: DispatchFn<T>) -> Result<(), String>;
    fn new(states: StatesTree, options: ModalOptions<T>) -> Result<Self, String>
       where Self: Sized;
    fn share_with_ref(&self) -> Rc<Self>;
}
Expand description

provides the interfaces to component of custom modal dialog

Required Methods§

source

fn render(&self) -> Result<RespoNode<T>, String>where T: Clone + Debug,

renders UI

source

fn show(&self, dispatch: DispatchFn<T>) -> Result<(), String>

to show modal

source

fn close(&self, dispatch: DispatchFn<T>) -> Result<(), String>

to close modal

source

fn new(states: StatesTree, options: ModalOptions<T>) -> Result<Self, String>where Self: Sized,

source

fn share_with_ref(&self) -> Rc<Self>

share it with Rc

Implementors§