0 purchases
buttons showcase
A Flutter plugin for quick use of some pre-developed buttons.
Especially social buttons, but they are totally customizable, so, in the end, for any use.
Installation #
Add to pubspec.yaml.
dependencies:
...
buttons_showcase: ^0.0.4
copied to clipboard
Usage Example #
import 'package:buttons_showcase/buttons_showcase.dart';
copied to clipboard
BaseButton class
class BaseButton extends StatelessWidget {
BaseButton(
{
this.textCaps = false,
this.showLogo = true,
this.customText,
this.size = "M",
this.iconType = 0,
this.customShape,
this.function,
required this.social,
) : super(key: key);
}
...
copied to clipboard
Various different implementations:
BaseButton(size: "S", social: listSocial[keyword]!),
BaseButton(size: "M", social: listSocial[keyword]!),
BaseButton(size: "L", social: listSocial[keyword]!),
// MANAGE THE LOGO SECTION
BaseButton(showLogo: false, social: listSocial[keyword]!),
// MANAGE THE TEXT SECTION
BaseButton(customText: "Your custom text", social: listSocial[keyword]!),
// MANAGE THE SHAPE SECTION
BaseButton(customShape: "circle", social: listSocial[keyword]!),
BaseButton(customShape: "square", iconType: 1, social: listSocial[keyword]!)
copied to clipboard
The Social class
class Social {
Social(this.name, this.color, this.textColor, this.logoPaths);
String name;
Color color, textColor;
List<String> logoPaths;
}
copied to clipboard
Social example
Color githubColor = const Color(0xFF333333);
Color whiteColor = Colors.white;
Social(
"GitHub",
githubColor,
whiteColor,
[
"assets/icons/github.png",
"assets/icons/github_full.png",
"assets/icons/github_outline.png"
]
)
copied to clipboard
The 'Example' contain the following buttons:
enum Socials {
Amazon,
Apple,
Discord,
Facebook,
GitHub,
Instagram,
LinkedIn,
Microsoft,
Pinterest,
Snapchat,
Spotify,
Telegram,
TikTok,
Twitch,
Twitter,
WhatsApp,
Yahoo
}
copied to clipboard
Additional information #
Github repository: https://github.com/Fhyrel/buttons_showcase
Feel free to ask, report issues and contribute in the development of my package.
For personal and professional use. You cannot resell or redistribute these repositories in their original state.
There are no reviews.