diff --git a/demo/src/pages/layout/mod.rs b/demo/src/pages/layout/mod.rs
index b0bb3ba..198f9c4 100644
--- a/demo/src/pages/layout/mod.rs
+++ b/demo/src/pages/layout/mod.rs
@@ -74,27 +74,51 @@ pub fn LayoutPage() -> impl IntoView {
"style" |
- "MaybeSignal" |
- "Default::default()" |
+
+ "MaybeSignal"
+ |
+
+ "Default::default()"
+ |
"Layout's style." |
"position" |
- "LayoutPosition" |
- "LayoutPosition::Static" |
+
+ "LayoutPosition"
+ |
+
+ "LayoutPosition::Static"
+ |
"static position will make it css position set to static. absolute position will make it css position set to absolute and left, right, top, bottom to 0. absolute position is very useful when you want to make content scroll in a fixed container or make the whole page's layout in a fixed position. You may need to change the style of the component to make it display as you expect."
|
"has_sider" |
- "MaybeSignal" |
- "false" |
+
+ "MaybeSignal"
+ |
+
+ "false"
+ |
"Whether the component has sider inside. If so it must be true." |
+
+ "class" |
+
+ "MaybeSignal"
+ |
+
+ "Default::default()"
+ |
+ "Addtional classes for the layout element." |
+
"children" |
- "Children" |
+
+ "Children"
+ |
|
"Layout's content." |
@@ -113,13 +137,29 @@ pub fn LayoutPage() -> impl IntoView {
"style" |
- "MaybeSignal" |
- "Default::default()" |
+
+ "MaybeSignal"
+ |
+
+ "Default::default()"
+ |
"LayoutHeader's style." |
+
+ "class" |
+
+ "MaybeSignal"
+ |
+
+ "Default::default()"
+ |
+ "Addtional classes for the layout header element." |
+
"children" |
- "Children" |
+
+ "Children"
+ |
|
"LayoutHeader's content." |
diff --git a/src/layout/layout_header.rs b/src/layout/layout_header.rs
index 3815abc..04ff82e 100644
--- a/src/layout/layout_header.rs
+++ b/src/layout/layout_header.rs
@@ -1,12 +1,14 @@
+use crate::utils::class_list::class_list;
use leptos::*;
#[component]
pub fn LayoutHeader(
+ #[prop(optional, into)] class: MaybeSignal,
#[prop(optional, into)] style: MaybeSignal,
children: Children,
) -> impl IntoView {
view! {
-