zuicon_mdl2/
incoming_call.rs

1// Copyright (c) 2024 Xu Shaohua <shaohua@biofan.org>. All rights reserved.
2// Use of this source is governed by Lesser General Public License
3// that can be found in the LICENSE file.
4
5// Auto Generated! DO NOT EDIT!
6
7use yew::prelude::{html, Component, Context, Html, Properties};
8
9pub struct IncomingCall {}
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 IncomingCall {
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        // TODO(Shaohua): Do not generate style attribute if it is empty.
46        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={ "IncomingCall" }
58                viewBox={ "0 0 16 16" }
59                fill={ props.fill.unwrap_or("currentColor") }
60                style={ style }
61            >
62            <path d="M1530 1307q39 0 76 15t65 43q21 21 47 44t55 49 54 54 47 57 33 62 13 66q0 39-15 76t-43 65q-51 51-92 90t-85 66-99 40-129 14q-109 0-224-34t-229-94-223-143-206-181-180-207-141-222-92-227-34-220q0-76 13-130t40-98 66-85 91-93q28-28 65-43t76-15q50 0 96 27t89 66 79 82 68 74q28 28 43 65t15 76q0 39-13 70t-32 55-42 45-42 40-33 37-13 40q0 12 18 38t50 62 71 77 84 85 87 85 81 78 66 63 42 40q21 21 50 21 21 0 39-13t37-32 39-42 46-42 55-33 71-13zm-73 613q61 0 102-11t75-34 64-54 73-73q21-21 21-50 0-13-16-37t-40-54-55-60-60-55-53-41-38-16q-21 0-40 13t-37 32-39 42-46 42-55 33-70 13q-40 0-76-15t-65-44l-477-477q-28-28-43-64t-16-77q0-39 13-69t32-56 42-45 42-40 33-37 13-40q0-13-16-37t-40-53-55-60-60-55-54-41-37-16q-30 0-51 21-41 41-73 72t-54 64-33 75-12 101q0 96 31 198t86 206 132 202 165 187 188 164 202 130 203 85 194 31zm335-896h-640V384h128v421l595-594 90 90-594 595h421v128z" />
63            </svg>
64        }
65    }
66}