Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/theiskaa/insta-like-button
Instagram post style customizable card widget, with default liking functionality
https://github.com/theiskaa/insta-like-button
dart flutter flutter-package
Last synced: 3 months ago
JSON representation
Instagram post style customizable card widget, with default liking functionality
- Host: GitHub
- URL: https://github.com/theiskaa/insta-like-button
- Owner: theiskaa
- License: mit
- Created: 2021-04-09T10:46:33.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2021-08-19T15:16:54.000Z (about 3 years ago)
- Last Synced: 2024-06-19T22:16:03.674Z (5 months ago)
- Topics: dart, flutter, flutter-package
- Language: Dart
- Homepage: https://pub.dev/packages/insta_like_button
- Size: 3.43 MB
- Stars: 15
- Watchers: 2
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Insta Like Button
## Installing
### Depend on it
Add this to your package's `pubspec.yaml` file:
```yaml
dependencies:
insta_like_button: ^0.1.1
```### Install it
You can install packages from the command line:
```sh
$ flutter pub get
...
```
### Import itNow in your Dart code, you can use:
```dart
import 'package:insta_like_button/insta_like_button.dart';
```
---
## Usage & Overview### With required parameters.
```dart
InstaLikeButton(
image: AssetImage("example/overview/img.jpg"),
onChanged: () {
// Do something...
},
),
```### With all parameters (Customized InstaLikeButton).
```dart
InstaLikeButton(
image: NetworkImage("https://picsum.photos/200/300"),
onChanged: () {
// Do something...
},
icon: Icons.favorite_border,
iconSize: 80,
iconColor: Colors.red,
curve: Curves.fastLinearToSlowEaseIn,
height: 200,
width: MediaQuery.of(context).size.width - 20,
duration: const Duration(seconds: 1),
onImageError: (e, _) {
// Do something...
},
imageAlignment: Alignment.topLeft,
imageBoxfit: BoxFit.fill,
imageScale: 2.0,
imageColorFilter: ColorFilter.mode(
Colors.black.withOpacity(0.5),
BlendMode.dstATop,
),
),