fancy_rating_bar 0.0.6
fancy_rating_bar: ^0.0.6 copied to clipboard
A beautiful, highly customizable Flutter rating widget with stunning gradients, animations, and glassmorphic effects.
Fancy Rating Dialog #
A beautiful, highly customizable Flutter rating dialog with stunning gradients, animations, and glassmorphic effects.
Features #
✨ Stunning Themes
- 6 gorgeous pre-built gradient themes
- Aurora
- Sunset
- Ocean
- Forest
- Midnight
- Neon
- Glassmorphic background effects
- Smooth animations and transitions
🎨 Rich Customization
- Multiple rating modes (stars/emojis)
- Combined rating & review workflow
- Custom titles and messages
- Configurable max review length
Installation #
Add this to your package's pubspec.yaml
file:
dependencies:
fancy_rating_dialog: ^1.0.0
Usage #
void showRatingDialog() {
showDialog(
context: context,
barrierDismissible: true,
builder: (context) => FancyRatingBar(
theme: RatingThemes.aurora, // Choose from 6 beautiful themes
ratingIconType: RatingIconType.stars, // stars or hearts
useEmojiRating: false, // true for emoji rating
mode: DialogMode.both, // rating, review, or both
onSubmit: (data) async {
print('Rating: ${data['rating']}');
print('Review: ${data['review']}');
},
),
);
}
Customization #
FancyRatingBar(
theme: RatingThemes.aurora,
ratingIconType: RatingIconType.stars,
useEmojiRating: false,
mode: DialogMode.both,
title: 'Custom Title',
subtitle: 'Custom Subtitle',
reviewTitle: 'Custom Review Title',
reviewSubtitle: 'Custom Review Subtitle',
maxLength: 500,
onSubmit: (data) async {
// Handle the rating and review
},
)
Available Themes #
RatingThemes.aurora
- Purple and pink gradientsRatingThemes.sunset
- Orange and red gradientsRatingThemes.ocean
- Blue and cyan gradientsRatingThemes.forest
- Green and emerald gradientsRatingThemes.midnight
- Dark and elegant gradientsRatingThemes.neon
- Vibrant neon gradients
Configuration Options #
Rating Icon Types #
Available options for ratingIconType
:
RatingIconType.stars // ★ Default star icons
RatingIconType.hearts // ♥ Heart icons
Dialog Modes #
Available options for mode
:
DialogMode.rating // Shows only the rating step
DialogMode.review // Shows only the review step
DialogMode.both // Shows both rating and review steps (default)
Example Usage #
FancyRatingBar(
theme: RatingThemes.aurora,
// Configure rating type
ratingIconType: RatingIconType.hearts, // Use hearts instead of stars
// Configure dialog mode
mode: DialogMode.both, // Show both rating and review steps
// Optional: Use emoji rating instead of icons
useEmojiRating: true, // Enable emoji rating mode
onSubmit: (data) async {
print('Rating: ${data['rating']}');
print('Review: ${data['review']}');
},
)
Mode Behaviors #
-
Rating Mode (
DialogMode.rating
):- Shows only star/heart/emoji rating
- Single step dialog
- Quick rating submission
-
Review Mode (
DialogMode.review
):- Shows only review text field
- Single step dialog
- Focused on written feedback
-
Both Mode (
DialogMode.both
):- Two-step process
- Rate first, then optional review
- Progress bar shows completion
- Can go back to change rating
Screenshots #
Aurora Theme #
[Aurora Rating View] | [Aurora Review View] | [Aurora Success View] |
Sunset Theme #
[Sunset Rating View] | [Sunset Review View] | [Sunset Success View] |
Ocean Theme #
[Ocean Rating View] | [Ocean Review View] | [Ocean Success View] |
Forest Theme #
[Forest Rating View] | [Forest Review View] | [Forest Success View] |
Midnight Theme #
[Midnight Rating View] | [Midnight Review View] | [Midnight Success View] |
Neon Theme #
[Neon Rating View] | [Neon Review View] | [Neon Success View] |
Additional Features #
- Smooth animations and transitions
- Progress bar for multi-step flows
- Hover effects and scaling animations
- Success state animations
- Beautiful gradient buttons
- Backdrop blur effects
Contributing #
Contributions are welcome! If you find a bug or want to add a feature, please raise an issue or submit a PR.
License #
MIT License
Copyright (c) 2024 Subhadip Rudra
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.