From a0e87f18f0b99e48040ad383413f7434656407c4 Mon Sep 17 00:00:00 2001 From: luoxiao Date: Sun, 3 Dec 2023 23:01:48 +0800 Subject: [PATCH] demo: buttom component add disabled demo --- demo/src/pages/button/mod.rs | 106 +++++++++++++++++++++++++++++------ 1 file changed, 89 insertions(+), 17 deletions(-) diff --git a/demo/src/pages/button/mod.rs b/demo/src/pages/button/mod.rs index 675c374..749892e 100644 --- a/demo/src/pages/button/mod.rs +++ b/demo/src/pages/button/mod.rs @@ -95,6 +95,44 @@ pub fn ButtonPage() -> impl IntoView { +

"disabled"

+ + + + + + + + + + {highlight_str!( + r#" + + + + + "#, + "rust" + )} + + +

"style"

@@ -126,55 +164,89 @@ pub fn ButtonPage() -> impl IntoView { "style" - "MaybeSignal" - "Default::default()" + + "MaybeSignal" + + + "Default::default()" + "Button's style." "variant" - "MaybeSignal" - "ButtonVariant::Primary" + + "MaybeSignal" + + + "ButtonVariant::Primary" + "Button's variant." "color" - "MaybeSignal" - "ButtonColor::Primary" + + "MaybeSignal" + + + "ButtonColor::Primary" + "Button's color." "round" - "MaybeSignal" - "false" + + "MaybeSignal" + + + "false" + "Whether the button shows rounded corners." "icon" - "Option" - "None" + + "Option" + + + "None" + "The icon of the button." "loading" - "MaybeSignal" - "false" + + "MaybeSignal" + + + "false" + "Whether the button shows the loading status." "disabled" - "MaybeSignal" - "false" + + "MaybeSignal" + + + "false" + "Whether the button is disabled." "on_click" - "Option>" - "None" + + "Option>" + + + "None" + "Listen for button click events." "children" - "Children" + + "Children" + "Button's content."