zuicon_mdl2/
file_sass.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 FileSass {}
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 FileSass {
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={ "FileSass" }
58                viewBox={ "0 0 16 16" }
59                fill={ props.fill.unwrap_or("currentColor") }
60                style={ style }
61            >
62            <path d="M256 2048H128V0h1115l549 549v859h-128V640h-512V128H256v1920zM1280 512h293l-293-293v293zM512 384H384V256h128v128zm0 256H384V512h128v128zM384 768h128v128H384V768zm102 807q0 21 8 36t25 28q21 17 47 27t49 23q29 15 57 32t51 40 37 51 14 65q0 50-20 82t-54 53-74 28-84 8q-16 0-38-2t-47-6-45-11-34-16v-106q13 13 33 23t42 17 45 12 40 4q21 0 44-3t41-12 31-25 13-44q0-30-21-50t-54-38-69-35-70-40-53-57-22-81q0-46 21-78t54-53 73-29 80-10q32 0 72 3t70 19v101q-30-21-65-29t-71-8q-19 0-41 3t-41 13-31 25-13 40zm558-7q86 0 130 42t44 129v298h-102v-71q-47 82-140 82-63 0-103-34t-41-100q0-36 11-62t30-45 48-28 61-16l136-20q0-47-22-72t-71-26q-42 0-79 15t-69 42v-91q38-23 80-33t87-10zm74 244l-97 13q-38 5-64 20t-26 58q0 34 23 50t54 16q25 0 45-9t34-25 23-37 8-46v-40zm330-112q0 22 16 35t41 23 54 21 53 27 41 41 17 64q0 38-19 64t-47 43-64 23-66 7q-33 0-66-5t-64-20v-96q29 21 61 32t68 12q14 0 30-2t31-8 23-17 10-29q0-22-16-35t-42-24-53-20-54-27-41-41-17-64q0-36 17-62t45-42 61-24 64-8q61 0 114 19v91q-50-33-111-33-13 0-28 2t-28 9-21 17-9 27zm378 0q0 22 16 35t41 23 54 21 53 27 41 41 17 64q0 39-18 65t-47 42-63 23-67 7q-33 0-66-5t-64-20v-96q28 21 60 32t68 12q14 0 30-2t31-8 23-17 10-29q0-22-16-35t-41-24-54-20-53-27-41-40-17-65q0-36 17-62t45-42 61-24 64-8q60 0 114 19v91q-50-33-111-33-12 0-27 2t-29 9-22 17-9 27z" />
63            </svg>
64        }
65    }
66}