1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
use crate::events::{DomEvent, FreyaEvent};
use dioxus_native_core::NodeId;

pub use accesskit::NodeId as AccessibilityId;
use rustc_hash::FxHashMap;
use smallvec::SmallVec;
use tokio::sync::mpsc::{UnboundedReceiver, UnboundedSender};
use tokio::sync::watch;

pub type FocusSender = watch::Sender<AccessibilityId>;
pub type FocusReceiver = watch::Receiver<AccessibilityId>;
pub type EventEmitter = UnboundedSender<DomEvent>;
pub type EventReceiver = UnboundedReceiver<DomEvent>;
pub type EventsQueue = SmallVec<[FreyaEvent; 2]>;
pub type NodesEvents = FxHashMap<String, Vec<(NodeId, FreyaEvent)>>;