singlestage/components/kbd/
group.rs1use leptos::prelude::*;
2
3#[component]
5pub fn KbdGroup(
6 children: Children,
7
8 #[prop(optional, into)]
13 accesskey: MaybeProp<String>,
14 #[prop(optional, into)]
19 autocapitalize: MaybeProp<String>,
20 #[prop(optional, into)]
23 autofocus: MaybeProp<bool>,
24 #[prop(optional, into)]
26 class: MaybeProp<String>,
27 #[prop(optional, into)]
31 contenteditable: MaybeProp<String>,
32 #[prop(optional, into)]
36 dir: MaybeProp<String>,
37 #[prop(optional, into)]
39 draggable: MaybeProp<bool>,
40 #[prop(optional, into)]
42 enterkeyhint: MaybeProp<String>,
43 #[prop(optional, into)]
45 exportparts: MaybeProp<String>,
46 #[prop(optional, into)]
48 hidden: MaybeProp<String>,
49 #[prop(optional, into)]
51 id: MaybeProp<String>,
52 #[prop(optional, into)]
54 inert: MaybeProp<bool>,
55 #[prop(optional, into)]
58 inputmode: MaybeProp<String>,
59 #[prop(optional, into)]
61 is: MaybeProp<String>,
62 #[prop(optional, into)]
64 itemid: MaybeProp<String>,
65 #[prop(optional, into)]
67 itemprop: MaybeProp<String>,
68 #[prop(optional, into)]
70 itemref: MaybeProp<String>,
71 #[prop(optional, into)]
73 itemscope: MaybeProp<String>,
74 #[prop(optional, into)]
76 itemtype: MaybeProp<String>,
77 #[prop(optional, into)]
79 lang: MaybeProp<String>,
80 #[prop(optional, into)]
82 nonce: MaybeProp<String>,
83 #[prop(optional, into)]
85 part: MaybeProp<String>,
86 #[prop(optional, into)]
88 popover: MaybeProp<String>,
89 #[prop(optional, into)]
91 role: MaybeProp<String>,
92 #[prop(optional, into)]
94 slot: MaybeProp<String>,
95 #[prop(optional, into)]
99 spellcheck: MaybeProp<String>,
100 #[prop(optional, into)]
102 style: MaybeProp<String>,
103 #[prop(optional, into)]
105 tabindex: MaybeProp<usize>,
106 #[prop(optional, into)]
108 title: MaybeProp<String>,
109 #[prop(optional, into)]
111 translate: MaybeProp<String>,
112) -> impl IntoView {
113 let global_attrs_1 = view! {
114 <{..}
115 accesskey=move || accesskey.get()
116 autocapitalize=move || autocapitalize.get()
117 autofocus=move || autofocus.get()
118 contenteditable=move || contenteditable.get()
120 dir=move || dir.get()
121 draggable=move || draggable.get()
122 enterkeyhint=move || enterkeyhint.get()
123 exportparts=move || exportparts.get()
124 hidden=move || hidden.get()
125 id=move || id.get()
126 inert=move || inert.get()
127 inputmode=move || inputmode.get()
128 is=move || is.get()
129 itemid=move || itemid.get()
130 />
131 };
132
133 let global_attrs_2 = view! {
134 <{..}
135 itemprop=move || itemprop.get()
136 itemref=move || itemref.get()
137 itemscope=move || itemscope.get()
138 itemtype=move || itemtype.get()
139 lang=move || lang.get()
140 nonce=move || nonce.get()
141 part=move || part.get()
142 popover=move || popover.get()
143 role=move || role.get()
144 slot=move || slot.get()
145 spellcheck=move || spellcheck.get()
146 style=move || style.get()
147 tabindex=move || tabindex.get()
148 title=move || title.get()
149 translate=move || translate.get()
150 />
151 };
152
153 view! {
154 <kbd
155 class=move || { format!("singlestage-kbd-group {}", class.get().unwrap_or_default()) }
156
157 {..global_attrs_1}
158 {..global_attrs_2}
159 >
160 {children()}
161 </kbd>
162 }
163}