zuicon_mdl2/
calories_add.rs1use yew::prelude::{html, Component, Context, Html, Properties};
8
9pub struct CaloriesAdd {}
10
11#[derive(Properties, Debug, Clone, PartialEq, Eq)]
12pub struct Props {
13 #[prop_or_default]
14 pub class: Option<&'static str>,
15
16 #[prop_or_default]
17 pub width: Option<&'static str>,
18
19 #[prop_or_default]
20 pub height: Option<&'static str>,
21
22 #[prop_or_default]
23 pub color: Option<&'static str>,
24
25 #[prop_or_default]
26 pub fill: Option<&'static str>,
27
28 #[prop_or_default]
29 pub spin: bool,
30
31 #[prop_or_default]
32 pub rotate: i16,
33}
34
35impl Component for CaloriesAdd {
36 type Properties = Props;
37 type Message = ();
38
39 fn create(_ctx: &Context<Self>) -> Self {
40 Self {}
41 }
42
43 fn view(&self, ctx: &Context<Self>) -> Html {
44 let props = ctx.props();
45 let mut style = String::new();
47 if props.rotate != 0 {
48 style += &format!("transform: rotate({}deg);", props.rotate);
49 }
50 html! {
51 <svg
52 xmlns={ "http://www.w3.org/2000/svg" }
53 class={ props.class.unwrap_or("") }
54 width={ props.width.unwrap_or("16") }
55 height={ props.height.unwrap_or("16") }
56 focusable={ "false" }
57 data-icon={ "CaloriesAdd" }
58 viewBox={ "0 0 16 16" }
59 fill={ props.fill.unwrap_or("currentColor") }
60 style={ style }
61 >
62 <path d="M384 1280q0 88 23 170t64 153 100 129 130 100 153 65 170 23q66 0 131-13t125-41v137q-123 45-256 45-106 0-204-27t-183-78-156-120-120-155-77-184-28-204q0-84 18-165t52-155 84-140 113-122q6 37 18 78t29 81 38 77 46 65q22 25 52 25 27 0 45-19t19-46q0-11-3-20t-10-18q-56-82-86-163t-31-182q0-119 45-224t124-183T992 46t224-46h64v64q0 177 66 330t190 278 190 278 66 330h-128q0-152-56-281t-162-236q-130-132-204-288t-88-343q-83 11-153 50t-123 99-81 135-29 160q0 79 23 141t68 126q19 28 29 54t11 62q0 40-15 75t-42 61-61 42-75 15q-46 0-81-17t-62-46-49-65-39-72q-45 75-68 158t-23 170zm1664 384v128h-256v256h-128v-256h-256v-128h256v-256h128v256h256z" />
63 </svg>
64 }
65 }
66}