Expand description
§Grid Layout Core
The spatial engine for a cross-framework grid layout system. This crate contains the deterministic math for grid compaction, collision detection, and interaction sessions. It is designed to be headless and framework-agnostic.
Re-exports§
pub use collision::CollisionResolver;pub use collision::CollisionStrategy;pub use collision::NoopCollisionResolver;pub use collision::PushDownResolver;pub use events::InteractionPhase;pub use events::LayoutEvent;pub use responsive::BreakpointSpec;pub use responsive::scale_layout_cols;pub use responsive::select_breakpoint;pub use validate::LayoutIssue;pub use validate::repair_layout;pub use validate::validate_layout;
Modules§
- collision
- Pluggable collision resolution when an item overlaps others after move/resize.
- events
- Structured layout lifecycle events (RGL-style callbacks).
- interaction
- responsive
- Breakpoint selection and proportional layout scaling (RGL-style).
- validate
- Layout validation and automatic repair for persisted or imported grids.
Structs§
- Free
Placement Compactor - Layout
Engine - The main orchestration point for grid operations.
- Layout
Item - A single item within the grid layout.
- Rising
Tide Compactor - O(N * Cols) implementation using the “waterline” approach
Enums§
- Compaction
Type - Supported compaction strategies.
- Resize
Handle - Represents a handle for resizing a grid item.
Traits§
- Compactor
- Trait for grid compaction strategies. Compaction is the process of resolving overlaps and settling items into a stable layout.
Functions§
- apply_
aspect_ and_ clamp - Applies
aspect_ratio(w/h) plus min/max; re-clampsx/wtocols. - collides
- Checks if two layout items overlap.
- layout_
engine - Build an engine from compaction + collision strategy (common in interaction code).
- resize_
handle_ aria_ label - Human-readable label for assistive tech (e.g.
aria-labelon resize controls).