♻️ Refactoriza la API de Children e InRegion
- Patrón prototipo en `InRegion`: cada petición recibe clones profundos. - `ComponentClone` habilita clonar `dyn Component` de forma segura. - `ChildTyped<C>` renombrado a `Slot<C>`, elimina `ChildTypedOp`. - `Mutex` en lugar de `Arc<RwLock>` en `Child` y `Slot`. - `is_renderable` y `setup_before_prepare` reciben `&Context`. - Nuevos tests para `Children`, `ChildOp` y `Slot`.
This commit is contained in:
parent
f1d3218a68
commit
2626234163
33 changed files with 740 additions and 314 deletions
|
|
@ -19,9 +19,9 @@
|
|||
//! .add_item(nav::Item::dropdown(
|
||||
//! Dropdown::new()
|
||||
//! .with_title(L10n::n("Options"))
|
||||
//! .with_items(TypedOp::AddMany(vec![
|
||||
//! Typed::with(dropdown::Item::link(L10n::n("Action"), |_| "/action".into())),
|
||||
//! Typed::with(dropdown::Item::link(L10n::n("Another"), |_| "/another".into())),
|
||||
//! .with_items(ChildOp::AddMany(vec![
|
||||
//! Child::with(dropdown::Item::link(L10n::n("Action"), |_| "/action".into())),
|
||||
//! Child::with(dropdown::Item::link(L10n::n("Another"), |_| "/another".into())),
|
||||
//! ])),
|
||||
//! ))
|
||||
//! .add_item(nav::Item::link_disabled(L10n::n("Disabled"), |_| "#".into()));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue