♻️ Rename types for Mixed and Typed components
This commit is contained in:
parent
57e71a9399
commit
c65ac74a6f
20 changed files with 151 additions and 154 deletions
|
|
@ -4,7 +4,7 @@ pub use error::ErrorPage;
|
|||
pub use actix_web::Result as ResultPage;
|
||||
|
||||
use crate::base::action;
|
||||
use crate::core::component::{ComponentTrait, MixedComponents, OneComponent};
|
||||
use crate::core::component::{AnyComponent, ComponentTrait, MixedComponents};
|
||||
use crate::core::component::{Context, ContextOp};
|
||||
use crate::core::theme::ComponentsInRegions;
|
||||
use crate::fn_builder;
|
||||
|
|
@ -106,8 +106,7 @@ impl Page {
|
|||
|
||||
#[fn_builder]
|
||||
pub fn alter_component(&mut self, component: impl ComponentTrait) -> &mut Self {
|
||||
self.regions
|
||||
.add_in("content", OneComponent::with(component));
|
||||
self.regions.add(AnyComponent::with(component));
|
||||
self
|
||||
}
|
||||
|
||||
|
|
@ -117,7 +116,7 @@ impl Page {
|
|||
region: &'static str,
|
||||
component: impl ComponentTrait,
|
||||
) -> &mut Self {
|
||||
self.regions.add_in(region, OneComponent::with(component));
|
||||
self.regions.add_in(region, AnyComponent::with(component));
|
||||
self
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue