Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/teatalkinternal/favorite_button
Favorite Button is a flutter library that allows you to create heart and star shaped favorite featured buttons with animation effects too
https://github.com/teatalkinternal/favorite_button
dart flutter flutter-examples flutter-library hacktoberfest hacktoberfest-accepted heart open-source pub-package
Last synced: 6 days ago
JSON representation
Favorite Button is a flutter library that allows you to create heart and star shaped favorite featured buttons with animation effects too
- Host: GitHub
- URL: https://github.com/teatalkinternal/favorite_button
- Owner: TeaTalkInternal
- License: mit
- Created: 2020-09-03T15:41:45.000Z (about 4 years ago)
- Default Branch: master
- Last Pushed: 2021-05-04T12:51:36.000Z (over 3 years ago)
- Last Synced: 2023-09-13T17:53:16.674Z (about 1 year ago)
- Topics: dart, flutter, flutter-examples, flutter-library, hacktoberfest, hacktoberfest-accepted, heart, open-source, pub-package
- Language: Dart
- Homepage: https://pub.dev/packages/favorite_button
- Size: 73.2 KB
- Stars: 12
- Watchers: 2
- Forks: 5
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# favorite_button
Language: [English](README.md)
Favorite Button is a flutter library that allows you to create heart and star shaped favorite featured buttons with animation effects too.
![](https://github.com/TeaTalkInternal/github_assets/blob/master/gifs/video-to-gif-converter.gif)
- [favorite_button](#favoritebutton)
- [How to use it.](#how-to-use-it)
- [parameters](#parameters)## How to use it.
the default effects is Icons.favorite
```dart
FavoriteButton(
valueChanged: (_) {
},
),
```and you can also define custom effects.
```dart
FavoriteButton(
valueChanged: (_isFavorite) {
print('Is Favorite $_isFavorite)');
},
)
```## parameters
| parameter | description | default |
| -------------------------- | ------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| iconSize | size of button widget | 60.0 |
| iconColor | color of button widget | red for heart and yellow for star button respectively |
| valueChanged | Function that returns boolean value for current state of button | This is a required parameter |
| isFavorite or isStarred | Default state of button | This is a optional parameter |
|[more detail](https://github.com/TeaTalkInternal/favorite_button/tree/master/example/lib)