Search packages, repositories and app categories

Package detailsv7.0.7296

material_design_icons_flutter

The Material Design Icons designed by the community for Flutter

AndroidiOSWebmacOSWindowsLinux
30-day downloads
65K
Likes
693
Pub points
50

Install package

flutter pub add material_design_icons_flutter

Package Overview

Package selection guidance compiled from public package information, community data, and project usage.

A Flutter package that provides Material Design Icons, crafted by the community for use in Flutter applications. It offers a comprehensive set of icons aligned with Google's Material Design guidelines, ensuring consistency and visual appeal across platforms. The icons are optimized for performance and support all major Flutter platforms, including Android, iOS, Web, macOS, Windows, and Linux. Developers can easily integrate and customize icons within their UIs using simple widget syntax.

Use cases

  • Integrating Material Design-compliant icons into mobile and web apps
  • Enhancing UI with consistent, scalable vector icons
  • Building cross-platform applications with unified iconography
  • Customizing icon colors and sizes in Flutter widgets
  • Using icons in buttons, navigation bars, and app toolbars

Key features

  • Extensive library of Material Design icons
  • Support for all major Flutter platforms
  • Easy integration via pub.dev
  • Scalable vector icons with high resolution
  • Built-in icon themes and customization options

Suitable for

  • Flutter developers building Material Design-based apps
  • Teams requiring consistent icon sets across platforms
  • Projects needing lightweight, performant icon solutions
  • Developers focused on UI/UX consistency
  • Apps targeting multiple operating systems

Considerations

  • Requires manual updates for new icon additions
  • Limited to community-maintained icon set
  • May need additional configuration for custom icon themes
  • Not officially maintained by Google
  • Depends on external GitHub repository for updates

Original README

Original README snapshot from the linked source repository. Visit the repository for the latest content.

material_design_icons_flutter

The Material Design Icons Icon pack available as set of Flutter Icons.

Based on Material Design Icons 7.4.47. See a web demo build with this package.

👍 Like us on pub.dev!

Installation

In the dependencies: section of your pubspec.yaml, add the following line:

  material_design_icons_flutter: 7.0.7447

WARNING: MDI's version is based on their icons quantity, which does not strictly respect semver guide. They do try their best to keep icons in same name between minor releases but name changing may still appear. To not break your application, using a fix version in your pubspec.yaml is highly recommended.

Usage

import 'package:material_design_icons_flutter/material_design_icons_flutter.dart';

class MyWidget extends StatelessWidget {
  Widget build(BuildContext context) {
    return new IconButton(
      // Use the MdiIcons class for the IconData
      icon: new Icon(MdiIcons.sword),
      onPressed: () { print('Using the sword'); }
     );
  }
}

Or, if you want to access the icon by a string name, you can use fromString method to create one.

import 'package:material_design_icons_flutter/material_design_icons_flutter.dart';

class MyWidget extends StatelessWidget {
  Widget build(BuildContext context) {
    return new IconButton(
      // Use the string name to access icons.
      icon: new Icon(MdiIcons.fromString('sword')),
      onPressed: () { print('Using the sword'); }
     );
  }
}

Note: This is not recomended because to make fromString work we need a map for all icon names. Using this method will not get the benefits of tree-shaking.

On flutter 1.22 and above, using fromString method will also cause a compile error This application cannot tree shake icons fonts, which can be bypass by building with --no-tree-shake-icons.

Name Conversion

Some icons' names are reserved keywords in Dart (and most other languages), so they have been changed.

  • null -> nullIcon
  • switch -> switchIcon
  • sync -> syncIcon
  • factory -> factoryIcon

Categories

Source repository

Projects using this package