1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
//! Lazy layout system for Cranpose.
//!
//! This module provides virtualized layout components that only compose
//! and render currently visible items, enabling efficient handling of
//! large datasets.
//!
//! # Architecture
//!
//! Based on Jetpack Compose's lazy layout system:
//! - [`LazyListState`] - State holder for scroll position (JC: `LazyListState`)
//! - [`LazyLayoutItemProvider`] - Item factory trait (JC: `LazyLayoutItemProvider`)
//! - [`LazyListScope`] - DSL builder (JC: `LazyListScope`)
//! - [`measure_lazy_list`] - Virtualized measurement (JC: `measureLazyList`)
//!
//! # Example
//!
//! ```rust,ignore
//! use cranpose_ui::widgets::{LazyColumn, LazyColumnSpec};
//! use cranpose_foundation::lazy::{remember_lazy_list_state, LazyListScope};
//!
//! let state = remember_lazy_list_state();
//! LazyColumn(Modifier::empty(), state, LazyColumnSpec::default(), |scope| {
//! scope.items(100, None::<fn(usize)->u64>, None::<fn(usize)->u64>, |i| {
//! Text(format!("Item {}", i), Modifier::empty());
//! });
//! });
//! ```
//!
//! For convenience with slices, use the [`LazyListScopeExt`] extension methods:
//!
//! ```rust,ignore
//! use cranpose_ui::widgets::{LazyColumn, LazyColumnSpec};
//! use cranpose_foundation::lazy::{remember_lazy_list_state, LazyListScopeExt};
//!
//! let state = remember_lazy_list_state();
//! LazyColumn(Modifier::empty(), state, LazyColumnSpec::default(), |scope| {
//! scope.items_slice(&my_data, |item| {
//! Text(item.name.clone(), Modifier::empty());
//! });
//! });
//! ```
pub use *;
pub use *;
pub use *;
pub use *;
pub use *;
pub use *;
pub use *;