🔥 Remove template usage in base components

This commit is contained in:
Manuel Cillero 2023-11-25 11:38:51 +01:00
parent 7cd056d7a9
commit 6ec9287113
4 changed files with 0 additions and 44 deletions

View file

@ -17,7 +17,6 @@ pub struct Date {
readonly : OptionString, readonly : OptionString,
required : OptionString, required : OptionString,
help_text : OptionString, help_text : OptionString,
template : String,
} }
impl ComponentTrait for Date { impl ComponentTrait for Date {
@ -157,12 +156,6 @@ impl Date {
self self
} }
#[fn_with]
pub fn alter_template(&mut self, template: &str) -> &mut Self {
self.template = template.to_owned();
self
}
// Date GETTERS. // Date GETTERS.
pub fn name(&self) -> &OptionString { pub fn name(&self) -> &OptionString {
@ -204,8 +197,4 @@ impl Date {
pub fn help_text(&self) -> &OptionString { pub fn help_text(&self) -> &OptionString {
&self.help_text &self.help_text
} }
pub fn template(&self) -> &str {
self.template.as_str()
}
} }

View file

@ -19,7 +19,6 @@ pub struct Form {
charset : OptionString, charset : OptionString,
method : FormMethod, method : FormMethod,
stuff : AnyComponents, stuff : AnyComponents,
template : String,
} }
impl ComponentTrait for Form { impl ComponentTrait for Form {
@ -111,12 +110,6 @@ impl Form {
self self
} }
#[fn_with]
pub fn alter_template(&mut self, template: &str) -> &mut Self {
self.template = template.to_owned();
self
}
// Form GETTERS. // Form GETTERS.
pub fn action(&self) -> &OptionString { pub fn action(&self) -> &OptionString {
@ -134,8 +127,4 @@ impl Form {
pub fn elements(&self) -> &AnyComponents { pub fn elements(&self) -> &AnyComponents {
&self.stuff &self.stuff
} }
pub fn template(&self) -> &str {
self.template.as_str()
}
} }

View file

@ -32,7 +32,6 @@ pub struct Input {
readonly : OptionString, readonly : OptionString,
required : OptionString, required : OptionString,
help_text : OptionTranslated, help_text : OptionTranslated,
template : String,
} }
impl ComponentTrait for Input { impl ComponentTrait for Input {
@ -258,12 +257,6 @@ impl Input {
self self
} }
#[fn_with]
pub fn alter_template(&mut self, template: &str) -> &mut Self {
self.template = template.to_owned();
self
}
// Input GETTERS. // Input GETTERS.
pub fn input_type(&self) -> &InputType { pub fn input_type(&self) -> &InputType {
@ -321,8 +314,4 @@ impl Input {
pub fn help_text(&self) -> &OptionTranslated { pub fn help_text(&self) -> &OptionTranslated {
&self.help_text &self.help_text
} }
pub fn template(&self) -> &str {
self.template.as_str()
}
} }

View file

@ -21,7 +21,6 @@ pub struct Wrapper {
inner_classes: OptionClasses, inner_classes: OptionClasses,
wrapper_type : WrapperType, wrapper_type : WrapperType,
stuff : AnyComponents, stuff : AnyComponents,
template : String,
} }
impl ComponentTrait for Wrapper { impl ComponentTrait for Wrapper {
@ -153,12 +152,6 @@ impl Wrapper {
self self
} }
#[fn_with]
pub fn alter_template(&mut self, template: &str) -> &mut Self {
self.template = template.to_owned();
self
}
// Wrapper GETTERS. // Wrapper GETTERS.
pub fn inner_classes(&self) -> &OptionClasses { pub fn inner_classes(&self) -> &OptionClasses {
@ -172,8 +165,4 @@ impl Wrapper {
pub fn components(&self) -> &AnyComponents { pub fn components(&self) -> &AnyComponents {
&self.stuff &self.stuff
} }
pub fn template(&self) -> &str {
self.template.as_str()
}
} }