惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Vercel News
Vercel News
博客园 - 司徒正美
大猫的无限游戏
大猫的无限游戏
Last Week in AI
Last Week in AI
V
Visual Studio Blog
阮一峰的网络日志
阮一峰的网络日志
小众软件
小众软件
宝玉的分享
宝玉的分享
Apple Machine Learning Research
Apple Machine Learning Research
美团技术团队
WordPress大学
WordPress大学
博客园 - 聂微东
人人都是产品经理
人人都是产品经理
罗磊的独立博客
The Cloudflare Blog
V
V2EX
月光博客
月光博客
有赞技术团队
有赞技术团队
Y
Y Combinator Blog
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
GbyAI
GbyAI
博客园 - 【当耐特】
T
Tailwind CSS Blog

DEV Community

Authentication Security Deep Dive: From Brute Force to Salted Hashing (With Java Examples) Why AI Systems Don’t Fail — They Drift Spilling beans for how i learn for exam😁"Reinforcement Learning Cheat Sheet" I Replaced Chrome with Safari for AI Browser Automation. Here's What Broke (and What Finally Worked) How Python Borrows Other People's Work The $40 Architecture: Processing 1 Billion API Requests with 99.99% Uptime Vibe Coding: A Workflow Guide (From Zero to SaaS) Most webhook security guides protect the wrong side. The scary part is delivery. Headless CMS for TanStack Start: Build a Blog with Cosmic EU Age Verification App "Hacked in 2 Minutes" — What Actually Happened Comfy Cloud’s delete function does not actually remove files Running AI Models on GPU Cloud Servers: A Beginner Guide Event-driven media intelligence with AWS Step Functions and Bedrock I scored 500 AI prompts across 8 quality dimensions — here's what broke How to Call Google Gemini API from Next.js (Free Tier, No Backend Needed) The Portal Protocol: Reclaiming Human Connection in the Age of AI How to Fix Your Team's Scattered Knowledge Problem With a Self-Hosted Forum Intro to tc Cloud Functors: A Graph-First Mental Model for the Modern Cloud Designing Multi-Tenant Backends With Both Ownership and Team Access I Built a Neumorphic CSS Library with 77+ Components — Here's What I Learned PostgreSQL Performance Optimization: Why Connection Pooling Is Critical at Scale Cómo construí un SaaS multi-rubro para gestionar expensas en Argentina con FastAPI + Vue 3 🚀 I Built an Ethical Hacking Scanner Tool – Open Source Project I Replaced /usage and /context in Claude Code With a Single Statusline A Pythonic Way to Handle Emails (IMAP/SMTP) with Auto-Discovery and AI-Ready Design I Collected 8.9 Million Polymarket Price Points — Here's What I Found About How Markets Really Move EcoTrack AI — Carbon Footprint Tracker & Dashboard Everyone's Using AI. No One Agrees How. 5 self-hosted ebook managers worth trying in 2026 Building Your First AI Agent with LangChain: From Chatbot to Autonomous Assistant
Rating and Feedback Collector
Codexlancers · 2026-04-27 · via DEV Community

Codexlancers

``

Introduction
User feedback collection cannot be overemphasized, therefore, if an app is to grow in both quality and satisfaction, The package offers a developer versatile solutions into making bars rated with icons, emojis, and even custom images. Further, this allows dynamic feedback alerts, hence allowing the user to include as much detail in their feedback as possible and rate your app. This will walk you through the setup and usage of this package, hence you can make full use of its features.

Key Features
Custom Icon Rating: Use any icon to represent rating units.
Smiley Emojis Rating: Default emoji images to express ratings.
Custom Image Rating: Use your custom images for ratings.
Feedback Alert Box for Low Ratings: Prompt users to provide feedback if they rate low.
Redirect to Store for High Ratings: Redirect users to the app store for a review if they rate high.
Customizable UI & Contents: Fully customizable to fit your app’s theme.
Submission Callback: Get feedback data with a callback function.
Installation
First, add the rating_and_feedback_collector package to your pubspec.yaml file:

`yaml
dependencies:
rating_and_feedback_collector: ^0.0.2
`

Then, run pub get to fetch the package.
Importing the Package
Next, import the package into your Dart file:

`dart
import 'package:rating_and_feedback_collector/rating_and_feedback_collector.dart';

`
Usage
Here are examples of how to use the package’s main features:

Rating Bar with Icons
The RatingBar widget allows you to use icons to represent ratings. You can customize the icons, their size, colors, and whether half ratings are allowed.

`dart
double _rating = 0.0;
RatingBar(
iconSize: 40, // Size of the rating icons
allowHalfRating: true, // Allows selection of half ratings
filledIcon: Icons.star, // Icon for a filled rating unit
halfFilledIcon: Icons.star_half, // Icon for a half-filled rating unit
emptyIcon: Icons.star_border, // Icon for an empty rating unit
filledColor: Colors.amber, // Color of filled rating units
emptyColor: Colors.grey, // Color of empty rating units
currentRating: _rating, // Set initial rating value
onRatingChanged: (rating) { // Callback triggered when the rating is changed
setState(() { _rating = rating; });
},
),
`

Rating Bar with Emoji Images
The RatingBarEmoji widget uses default emoji images to represent ratings.

`dart
double _rating = 0.0;
RatingBarEmoji(
imageSize: 45, // Size of image in the rating bar
currentRating: _rating, // Set initial rating value
onRatingChanged: (rating) { // Callback triggered when the rating is changed
setState(() { _rating = rating; });
},
),
`

Rating Bar with Custom Images
The RatingBarCustomImage widget allows you to use custom images for different rating levels.

`dart
double _rating = 0.0;
RatingBarCustomImage(
imageSize: 45, // Size of image in the rating bar
currentRating: _rating, // Set initial rating value
activeImages: const [
AssetImage('assets/Images/ic_angry.png'),
AssetImage('assets/Images/ic_sad.png'),
AssetImage('assets/Images/ic_neutral.png'),
AssetImage('assets/Images/ic_happy.png'),
AssetImage('assets/Images/ic_excellent.png'),
],
deActiveImages: const [
AssetImage('assets/Images/ic_angryDisable.png'),
AssetImage('assets/Images/ic_sadDisable.png'),
AssetImage('assets/Images/ic_neutralDisable.png'),
AssetImage('assets/Images/ic_happyDisable.png'),
AssetImage('assets/Images/ic_excellentDisable.png'),
],
onRatingChanged: (rating) { // Callback triggered when the rating is changed
setState(() { _rating = rating; });
},
),
`

Customization Properties
The package offers various properties to customize the rating bar and feedback dialog:

currentRating (double): Set initial rating value
filledIcon (only for RatingBar) (IconData?): Icon for a filled rating unit
halfFilledIcon (only for RatingBar) (IconData?): Icon for a half-filled rating unit
emptyIcon (only for RatingBar) (IconData?): Icon for an empty rating unit
filledColor (only for RatingBar) (Color?): Color of filled rating units
emptyColor (only for RatingBar) (Color?): Color of empty rating units
iconSize (double?): Size of the rating icons
onRatingChanged (Function(double)): Callback triggered when the rating is changed
allowHalfRating (only for RatingBar) (bool?): Allows selection of half ratings
isGoogleFont (bool?): Set to true for using Google fonts
fontFamilyName (String?): Custom font family name or Google font family name
showFeedbackForRatingsLessThan (double?): Threshold rating value below which feedback box is shown
feedbackBoxTitle (String?): Title for the feedback box
lowRatingFeedbackTitle (String?): Title for feedback options in the low rating feedback box
lowRatingFeedback (List?): List of feedback strings for low ratings
showDescriptionInput (bool?): Option to show input box for user descriptions in the feedback dialog
descriptionTitle (String?): Title for the description input box in the feedback dialog
descriptionPlaceHolder (String?): Placeholder text for the description input box
descriptionCharacterLimit (int?): Character limit for the description input
submitButtonTitle (String?): Title for the submit button in the feedback dialog
onSubmitTap (Function(selectedFeedback, description)): Callback function triggered on submission of feedback
showRedirectToStoreForRatingsGreaterThan (double?): Threshold rating value above which the app redirects to the store for a review
androidPackageName (String?): Android package name for the app, used in the store redirect
iosBundleId (String?): iOS bundle ID for the app, used in the store redirect
innerWidgetsBorderRadius (double?): **Border radius for the feedback dialog widgets
**alertDialogBorderRadius (double?): **Border radius for the feedback dialog
**Conclusion

Rating_and_feedback_collector Package is the optimal solution for adding highly flexible rating bars and in-app feedback alerts into your Flutter app.
By incorporating this package you can raise user’s interest, collect useful feedback and eventually boost your app’s ratings in the store. Include this package into your app and enjoy its flexible and user-friendly elements.


more information, check out the
https://pub.dev/packages/rating_and_feedback_collector



Thanks for reading! If you found this post useful, please share it with others in your network and follow me for more Flutter insights and tutorials. Keep coding and stay awesome!