7 stable releases

3.0.0 Dec 20, 2024
2.0.0 Jul 29, 2024
1.2.0 Feb 5, 2024
1.1.0 Mar 16, 2023
1.0.2 Jan 24, 2023

#213 in GUI

Download history 6/week @ 2024-09-11 16/week @ 2024-09-18 30/week @ 2024-09-25 2/week @ 2024-10-02 2/week @ 2024-10-30 1/week @ 2024-11-06 5/week @ 2024-12-04 3/week @ 2024-12-11 116/week @ 2024-12-18 22/week @ 2024-12-25

146 downloads per month

MIT license

165KB
96 lines

Contains (WOFF font, 130KB) MaterialIcons-Regular.woff2

🧬 Dioxus Material Icons

Crates.io version

This project provides a simple but configurable component to render Google's Material Icons in Dioxus.

🚀 How to get started

cargo add dioxus-material-icons

This project introduces two components:

  1. MaterialIconStylesheet
  2. MaterialIcon

To be able to use the MaterialIcon component anywhere in your code, you first have to include a MaterialIconStylesheet component. When you want to use the default settings, just add it to your app's root component like this:

MaterialIconStylesheet { }

Have a look at the docs for more options like self-hosting the icon font file.

After that you can use the MaterialIcon component like you would expect it:

MaterialIcon { name: "settings" }

You can additionally specify the color and size.

MaterialIcon {
    name: "settings",
    size: 24,
    color: MaterialIconColor::Light,
}

💡 Examples

Alternatives

📜 License

This software is licensed under the terms of the MIT License.

Note: All Material Icons are licensed under the Apache License 2.0.

© 2024 Lennart Kloock

Dependencies

~2.9–8MB
~74K SLoC