Skip to main content

dioxus_dnd/core/
mod.rs

1//! Shared primitives: the drag context, id/geometry types, hooks, and the
2//! `Draggable`/`DropZone`/`DragOverlay` components every other module builds on.
3
4pub mod components;
5pub mod hooks;
6pub mod machine;
7pub mod model;
8pub mod modifiers;
9pub(crate) mod platform;
10pub mod registry;
11pub mod state;
12pub mod types;
13pub mod viewport;
14
15pub use components::{DndProvider, DragOverlay, Draggable, DropZone, ParentZone};
16pub use hooks::{
17    client_point, element_point, use_dnd, use_dnd_provider, use_rect_refresh, use_zone_id,
18    use_zone_registry,
19};
20pub use machine::{transition, GestureEffect, GestureEvent, GesturePhase};
21pub use model::{apply_clone_or_move, apply_list_clone_or_move};
22pub use modifiers::{apply_modifiers, DragModifier, ModifierCtx};
23pub use registry::{RectRefresh, ZoneRecord, ZoneRegistry};
24pub use state::{DndContext, DragState};
25pub use types::{
26    effective_effect, Direction, DragId, DragMode, DropEffect, DropOutcome, Point, Rect, ZoneId,
27};
28pub use viewport::{
29    screen_delta_to_world, screen_to_world, world_delta_to_screen, world_to_screen, CanvasViewport,
30};