pub enum Msg {
Show 19 variants
EditorMounted(MountEvent),
ChangeValue(String),
ChangeSyntax(String),
ChangeTheme(String),
CursorMounted(MountEvent),
Keydown(KeyboardEvent),
Mouseup(MouseEvent),
Click(MouseEvent),
Mousedown(MouseEvent),
Mousemove(MouseEvent),
Measurements(Measurements),
Focused(FocusEvent),
Blur(FocusEvent),
ContextMenu(MouseEvent),
ContextMenuMsg(Msg),
ScrollCursorIntoView,
MenuAction(MenuAction),
SetFocus,
NoOp,
}
Variants§
EditorMounted(MountEvent)
ChangeValue(String)
Discard current editor content if any, and use this new value This is triggered from the top-level DOM of this component
ChangeSyntax(String)
Syntax token is changed
ChangeTheme(String)
Change the theme of the editor
CursorMounted(MountEvent)
Keydown(KeyboardEvent)
Mouseup(MouseEvent)
Click(MouseEvent)
Mousedown(MouseEvent)
Mousemove(MouseEvent)
Measurements(Measurements)
Focused(FocusEvent)
Blur(FocusEvent)
ContextMenu(MouseEvent)
ContextMenuMsg(Msg)
ScrollCursorIntoView
MenuAction(MenuAction)
SetFocus
set focus to the editor
NoOp
Trait Implementations§
Source§impl<XMSG> Component<Msg, XMSG> for WebEditor<XMSG>
impl<XMSG> Component<Msg, XMSG> for WebEditor<XMSG>
Source§impl<XMSG> CustomElement<Msg> for WebEditor<XMSG>where
XMSG: 'static,
impl<XMSG> CustomElement<Msg> for WebEditor<XMSG>where
XMSG: 'static,
Source§fn attribute_changed<APP>(
program: &Program<APP, Msg>,
attr_name: &str,
_old_value: JsValue,
new_value: JsValue,
)where
APP: Application<Msg> + 'static,
fn attribute_changed<APP>(
program: &Program<APP, Msg>,
attr_name: &str,
_old_value: JsValue,
new_value: JsValue,
)where
APP: Application<Msg> + 'static,
this is called when the attributes in the mount is changed
Source§fn custom_tag() -> &'static str
fn custom_tag() -> &'static str
the custom tag that this custom element will be registerd to the browser
Source§fn observed_attributes() -> Vec<&'static str>
fn observed_attributes() -> Vec<&'static str>
returns the attributes that is observed by this component
These are the names of the attributes the component is interested in
Source§fn connected_callback(&mut self)
fn connected_callback(&mut self)
the component is attached to the dom
Source§fn disconnected_callback(&mut self)
fn disconnected_callback(&mut self)
the component is removed from the DOM
Source§fn adopted_callback(&mut self)
fn adopted_callback(&mut self)
the component is moved or attached to the dom
Auto Trait Implementations§
impl Freeze for Msg
impl RefUnwindSafe for Msg
impl !Send for Msg
impl !Sync for Msg
impl Unpin for Msg
impl UnwindSafe for Msg
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self
from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self
is actually part of its subset T
(and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset
but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self
to the equivalent element of its superset.