🚧 Avoid semicolons for empty html elements
This commit is contained in:
parent
25cb46e712
commit
5f02ef7f2c
4 changed files with 6 additions and 6 deletions
|
|
@ -50,7 +50,7 @@ impl ComponentTrait for Date {
|
|||
@if self.required().get().is_some() {
|
||||
span
|
||||
class="form-required"
|
||||
title="Este campo es obligatorio." { "*" } " ";
|
||||
title="Este campo es obligatorio." { "*" } " "
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -65,7 +65,7 @@ impl ComponentTrait for Date {
|
|||
autocomplete=[self.autocomplete().get()]
|
||||
readonly=[self.readonly().get()]
|
||||
required=[self.required().get()]
|
||||
disabled=[self.disabled().get()];
|
||||
disabled=[self.disabled().get()] {}
|
||||
@if let Some(help_text) = self.help_text().get() {
|
||||
div class="form-text" { (help_text) }
|
||||
}
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ impl ComponentTrait for Hidden {
|
|||
fn prepare_component(&self, _: &mut Context) -> PrepareMarkup {
|
||||
let id = self.name().get().map(|name| concat_string!("value-", name));
|
||||
PrepareMarkup::With(html! {
|
||||
input type="hidden" id=[id] name=[self.name().get()] value=[self.value().get()];
|
||||
input type="hidden" id=[id] name=[self.name().get()] value=[self.value().get()] {}
|
||||
})
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -81,7 +81,7 @@ impl ComponentTrait for Input {
|
|||
@if self.required().get().is_some() {
|
||||
span
|
||||
class="form-required"
|
||||
title="Este campo es obligatorio." { "*" } " ";
|
||||
title="Este campo es obligatorio." { "*" } " "
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -99,7 +99,7 @@ impl ComponentTrait for Input {
|
|||
autocomplete=[self.autocomplete().get()]
|
||||
readonly=[self.readonly().get()]
|
||||
required=[self.required().get()]
|
||||
disabled=[self.disabled().get()];
|
||||
disabled=[self.disabled().get()] {}
|
||||
@if !description.is_empty() {
|
||||
div class="form-text" { (description) }
|
||||
}
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ impl ComponentTrait for Icon {
|
|||
}
|
||||
|
||||
fn prepare_component(&self, _: &mut Context) -> PrepareMarkup {
|
||||
PrepareMarkup::With(html! { i class=[self.classes().get()] {}; })
|
||||
PrepareMarkup::With(html! { i class=[self.classes().get()] {} })
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue