搜尋套件、儲存庫與 APP 分類

套件詳情v1.1.0

flutter_icons

適用於 Flutter 的可自訂圖示,您可在 Flutter 項目中使用超過 3,000 個圖示

近 30 天下載
2710
喜歡數
734
Pub 分數
35

安裝套件

flutter pub add flutter_icons

套件介紹

根據套件公開資料產生的選型評估,僅供參考。

Flutter Icons 是一個提供超過 3,000 個可自訂圖示的套件,適用於 Flutter 應用程式。它透過提供豐富的圖示集合來增強 UI 設計,可透過簡單的 pub 命令輕鬆整合。該套件支援動態縮放、顏色自訂,並能與現有的 Flutter 專案無縫整合。非常適合尋求大量圖示但不依賴外部資源的開發者。原始碼公開於 GitHub,以確保透明度並促進社群貢獻。

適用情境

  • 向應用 UI 添加自定義圖標
  • 透過視覺提示增強導航
  • 創建品牌圖示集
  • 透過直覺符號改善使用者體驗
  • 使用圖示指標建構儀表板

主要特色

  • 超過3,000個圖標
  • 可自定大小與顏色
  • 透過 pub 實現輕鬆整合
  • 開源於 GitHub
  • 支援多個圖示庫

適合對象

  • 行動應用程式開發人員
  • UI/UX 設計師
  • 跨平台專案
  • 需要豐富圖示語意的應用程式
  • 設計時程緊張的專案

使用建議

  • 初始設定需要互聯網
  • 可能會稍微增加應用程式封裝大小
  • 限於預定義的圖示集
  • 無內建圖示搜尋
  • 依賴外部倉庫的穩定性

原始 README

以下為關聯原始碼儲存庫的 README 原文快照,最新內容請造訪原始碼儲存庫。

English | 简体中文

flutter_icons

pub package

Customizable Icons for Flutter,Inspired by react-native-vector-icons

Notice

  1. v1.0.0 has major Api changes, please be careful to upgrade
  2. icon names that begin with a number are preceded by a $prefix
  3. icon named with the dart keyword have the _ suffix added

Bundled Icon Sets

Browse all.

Usage

To use this plugin, add flutter_icons as a dependency in your pubspec.yaml file.

Widget

IconToggle
Prop Description
selectedIconData Icon is displayed when value is true
unselectedIconData Icon is displayed when value is false
activeColor When value is true, the icon color is displayed
inactiveColor When value is false, the icon color is displayed
value Whether this IconToggle is selected.
onChanged Called when the value of the IconToggle should change.
duration The duration of the transition from selected Icon to unselected Icon
reverseDuration he duration of the transition from unselected Icon to selected Icon
transitionBuilder Transition animation function between the selected Icon and the unselected Icon

Example

// Import package
import 'package:flutter_icons/flutter_icons.dart';
import 'package:flutter/material.dart';

// 1.0.0 version used
Icon(AntDesign.stepforward),
Icon(Ionicons.ios_search),
Icon(FontAwesome.glass),
Icon(MaterialIcons.ac_unit),
Icon(FontAwesome5.address_book),
Icon(FontAwesome5Solid.address_book),
Icon(FontAwesome5Brands.$500px)

// After 1.1.0, the FlutterIcons class is provided to access all Icons
// Icon name in the original basis added icon set abbreviation name as suffix
// Hereinafter referred to as the following
//Ant Design Icons -> ant,
//Entypo Icons -> ent,
//Evil Icons -> evi,
//Feather Icons -> fea,
//Font Awesome Icons -> faw,
//Font Awesome 5 Regular -> faw5
//Font Awesome 5 Solid -> faw5s
//Font Awesome 5 Brands -> faw5b
//Foundation Icons -> fou,
//Ionicons Icons -> ion,
//Material Community Icons -> mco,
//Material Icons -> mdi,
//Octicons Icons -> oct,
//Simple Line Icons -> sli,
//Zocial Icons -> zoc,
//Weather Icons -> wea
Icon(FlutterIcons.stepforward_ant)
Icon(FlutterIcons.html5_faw)
...

// Previous versions of 1.0.0 are used
Icon(Ionicons.getIconData("ios-search"));
Icon(AntDesign.getIconData("stepforward"));
Icon(FontAwesome.getIconData("glass"));
Icon(MaterialIcons.getIconData("ac-unit"));
Icon(FontAwesome5.getIconData("address-book"));
Icon(FontAwesome5.getIconData("address-book",weight: IconWeight.Solid));
Icon(FontAwesome5.getIconData("500px", weight: IconWeight.Brand));
How to keep only the fonts used in the project.
step 1

Execute the command

pub global activate split_icon
step2

Add the font you want to leave in the project's pubspec file

//Ant Design Icons -> ant,
//Entypo Icons -> ent,
//Evil Icons -> evi,
//Feather Icons -> fea,
//Font Awesome Icons -> faw,
//Font Awesome 5 Regular -> faw5
//Font Awesome 5 Solid -> faw5s
//Font Awesome 5 Brands -> faw5b
//Foundation Icons -> fou,
//Ionicons Icons -> ion,
//Material Community Icons -> mco,
//Material Icons -> mdi,
//Octicons Icons -> oct,
//Simple Line Icons -> sli,
//Zocial Icons -> zoc,
//Weather Icons -> wea

...

flutter_icons:
  includes:
    -ant 
    -mco
 ...
step3

Execute the command in the project directory

split_icon

所屬分類

原始碼儲存庫

使用此套件的專案