LunaGao / flag_flutter

flag icons

Home Page:https://pub.dev/packages/flag

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Logo

flag

Pub Version Bless

A flag Flutter package for Android / iOS / Web. Based by https://github.com/dnfield/flutter_svg .

Screenshot

Screenshot

Svg sources

Thanks the great project flag-icons.

Flag list

ISO 3166-1-alpha-2 Flags

Note:

Organisations

  • eu European Union.

Disputed territories

  • hk Hong Kong. Special Administrative Region of China.
  • mo Macau. Special Administrative Region of China.
  • eh Western Sahara. Claimed by Morocco.
  • tw Taiwan. Claimed by China.

Undisputed territories which are non-UN state

  • va Vatican City. Govern by the Holy See.

How to use

Flag.fromCode(
    FlagsCode.COUNTRY_CODE, 
    height: HEIGHT, 
    width: WIDTH,
)
Flag.fromString(
    COUNTRY_CODE, 
    height: HEIGHT, 
    width: WIDTH,
)
Flags.fromCode(
    [
        FlagsCode.GB, 
        FlagsCode.US
    ], 
    height: 100, 
    width: 100 * 4 / 3,
)

Such as

  • Flag.fromCode(FlagsCode.AD, height: 100, width: null)
  • Flag.fromString('AD', height: null, width: null)
  • Flag.fromString('AD', height: 10, width: 100, fit: BoxFit.fill)

About

flag icons

https://pub.dev/packages/flag

License:BSD 2-Clause "Simplified" License


Languages

Language:Dart 88.3%Language:HTML 5.1%Language:Objective-C 3.6%Language:Swift 1.8%Language:Java 0.6%Language:Kotlin 0.6%