Flutter UI Designs

使用 Flutter 构建的用户界面设计集。可在任何手机、网页和桌面上运行。「Just collection of UI designs build with flutter. Can run on any mobile, web & desktop.」

Github星跟踪图

Flutter UI Designs

True cross platform app runs on web, mobile & desktop

Download

Requirements to run locally

  • Flutter stable v2.0.0+
  • Dart VM version: 2.12.0+
  • To enable desktop & web builds run the relevant command
    • Run flutter --enable-web
    • Run flutter --enable-macos-desktop
    • Run flutter --enable-linux-desktop
    • Run flutter --enable-windows-desktop
  • Run flutter doctor this command will show you what dependencies you need to install.

Getting started with code

Please note that this project's code is not meant for beginners! If you're just getting started with flutter I recommend you to explore some ToDo and basic setState apps and get yourself familiar with flutter and dart eco-system because in this project intermediate and advance implementations are use which will confuse you and won't help much in terms of learning.

  • There are 2 entry files for this project main.dart & main.mobile.dart. It was necessary because I'm using Firebase analytics and crashlytics and there isn't desktop support for Firebase yet.
  • Navigator.dart is responsible for managing routes, handles custom transition, pass parameter in screens and control navigation with keyboard shortcuts.
  • configs/AppDimensions.dart this is the magical file. It provides the app with:
  • UI.dart provides constant for building responsive UI.
    • My custom size unit based on device's width, height & pixel density.
    • Responsive containers.
    • Padding multiplier unit (I learned it with experience instead of using 1,2,3px should use multiplier. it helps maintain constancy around the app).
  • Widgets/Screen.dart This widget is necessary when building a new screen.
    • configure theme & font style.
    • It also receive a belowBuilders parameter which builds custom background (This enables us to build Parallax, Animated background & Any thing you could imagine in background). you can find an example in Screens/Download/Download.dart
  • Code structure is pretty much simple.
    • Don't import anything form ScreenA in ScreenB.
    • Don't import anything from Screen/Widget in universal files.
    • Don't import anything from ScreenA specific Widget in universal files.
    • Each Screen will have Dimensions.dart where you can write Screen's responsive logic.
    • I didn't use snake_case in naming convention just because I don't prefer it.
    • I use this for class's properties & methods I helps keep track of variables & class properties.

Scripts

  • vslaunch.dart
    • dart sciprts/vslaunch.dart
    • This script will make vscode configuration file with all of your connected devices.
    • You can live debug app on multiple devices at once from vs code.
    • Each device's debug logs on separate DEBUG CONSOLE.
    • Very useful for testing UI for multiple devices simultaneously.

Show support

If you like the project and want to appreciate my effort. Then you can perform any of these steps

  • Star this repository.
  • Rate the app on Play Store.
  • Endorse my skills on my Linkedin Profile.

License

This project is licensed under the MIT license, Copyright (c) 2020 Hamza Iqbal. For more information see LICENSE.md.

主要指标

概览
名称与所有者hmziqrs/flutter-ui-designs
主编程语言Dart
编程语言Kotlin (语言数: 11)
平台
许可证MIT License
所有者活动
创建于2020-02-27 06:09:43
推送于2024-11-20 05:30:09
最后一次提交2024-11-20 10:29:37
发布数19
最新版本名称v3.6.0 (发布于 )
第一版名称v1.0.7 (发布于 )
用户参与
星数317
关注者数11
派生数54
提交数414
已启用问题?
问题数3
打开的问题数0
拉请求数16
打开的拉请求数0
关闭的拉请求数1
项目设置
已启用Wiki?
已存档?
是复刻?
已锁定?
是镜像?
是私有?