Flutter Diamond Floating Action Button Library

in #utopian-io6 years ago

Repository

https://github.com/tensor-programming/diamond_fab

New Projects

  • What is the project about?

Diamond FAB (Floating Action Button) is a drop-in Package/Library for the Flutter framework that allows a developer to replace the aesthetics of the default round Floating Action Button with a Diamond shaped one. This Diamond FAB follows the Material Design Specification as seen in this article. The button features a 68 logical pixel default size as per the specification and a mini mode to decrease the size to 52 logical pixels. Included in the library is a default notch in the bottom application bar or bottom navigation bar depending on where the Floating Action Button is located in relation to this bottom bar. The FAB can be docked with the button bar which produces this open triangle notch and the size of this notch can be specified by the developer through the marginWidth property. The FAB also includes all of the properties and configurations that are default to the original Floating Action Button which is bundled with the Flutter Framework with the exception of the expanded option (For more info: Flutter Floating Action Button Documentation).

Images:

end-docked.jpgcenter-docked.jpgcenter-float.jpg

Demonstration:

In this video, I highlight the main features of the Diamond FAB and also talk about how to install it. There are more features in the library as well such as the ability to change the size of the FAB, the ability to change the colors for both the foreground and background, the ability to change the icon on the button among other things.

  • Technology Stack

This library is built with the Dart programming language and it requires the Flutter SDK to work properly. The library requires Dart 2.0.0-dev.28.0 or higher and Flutter SDK 0.1.4 or higher to run properly. At the time of this writing the current version of this library is 0.1.1

  • Roadmap

My first consideration is to integrate this library into the official Flutter SDK as a default widget. The diamond shaped Floating Action Button is a part of the Material Design specification and so, it will need to be implemented into the Flutter Material Design SDK at some point.

My second consideration is to expand the library to allow the user to further customize the shape of the floating action button in ways that are not explicitly mentioned in the material design specification while still staying true to the specification. In this particular scenario, the library would become more of an API to allow the user to create their own FAB.

  • How to contribute?

To Contribute to this project I encourage you to create a pull request or issue on Github

GitHub Account

https://github.com/tensor-programming

Sort:  

Thanks for the contribution!

Seems like a useful bit of code. A few things to keep in mind for future contributions:

  • It would be great if you could improve the quality of your commit messages. There are a lot that are simply "Add files via upload" or ones with identical messages.

  • Improving your usage and install instructions in the README, which is currently just "Add this to your package's pubspec.yaml file". I know you have linked a video above (which didn't work at the time of reviewing), so it would also cool if you'd add that to the README as well.

  • The comments you added are very descriptive, but I'm not sure that much is needed to describe a single variable each time.

Looking forward to see if you can get this integrated into the official Flutter SDK!

Your contribution has been evaluated according to Utopian policies and guidelines, as well as a predefined set of questions pertaining to the category.

To view those questions and the relevant answers related to your post, click here.


Need help? Write a ticket on https://support.utopian.io/.
Chat with us on Discord.
[utopian-moderator]

Thank you for reviewing my contribution and thank you for the constructive criticism I will keep that in mind for the next time that I release a development contribution. Here are a few things to note;

I am not really sure how a YouTube video could be unavailable when it just an unlisted video on my channel. I checked it multiple times myself (logging out and all of that) and it seemed to work fine, even checked the listing to make sure that I had listed it as "unlisted" and not "private" and it was indeed posted as unlisted.

I agree about the commit comments and won't say much more on the topic.

The comments in the code are specifically verbose because when you hover over a widget inside of a IDE or editor, it actually shows you these comments. Generally, you want to also have comments for each little field/property of the widget because again, the user can hover over the property and get a small description of what it does etc. This is an idiom in the Dart community and I was just following it.

As far as the readme goes, the reason the installation instructions are so bare bones is because typically these are left completely out of a readme for a dart/flutter package. This is because the package is hosted on this platform here and the pub platform auto generates this kind of information for you.

Here is the page that is connected to this library. If you do take the time to look, you will see that they generate a lot of things from the comments, changelog and example. Now, that being said, I knew full well that you or whomever read this was most likely not a part of the dart community so you would be unlikely to look on pub.dartlang.org for my package's information. As such I should have made the readme much more verbose just for this post.

Anyhow, I will keep all of this in mind the next time I contribute to development. To be honest, I wasn't even sure I should post this library and your score more or less confirms what I believed.

Good projects. I will investigate this.
Congratulations @tensor

Hey @tensor
Thanks for contributing on Utopian.
We’re already looking forward to your next contribution!

Contributing on Utopian
Learn how to contribute on our website or by watching this tutorial on Youtube.

Want to chat? Join us on Discord https://discord.gg/h52nFrV.

Vote for Utopian Witness!

Coin Marketplace

STEEM 0.19
TRX 0.15
JST 0.029
BTC 62827.81
ETH 2583.62
USDT 1.00
SBD 2.73