-
Notifications
You must be signed in to change notification settings - Fork 348
feat: Implemented Friends and Request screen to show proper empty state #724
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the 📝 WalkthroughWalkthroughThis PR adds an empty-state UI component for the Friends and Friend Requests screens, which display when users have no friends or pending requests. It introduces localization entries across multiple languages, a new FriendsEmptyState widget with navigation and sharing actions, and minimal updates to existing friend-related screens. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Suggested labels
Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
🎉 Welcome @Mayank4352!
We appreciate your contribution! 🚀 |
| @override | ||
| Widget build(BuildContext context) { | ||
| final friendsController = Get.find<FriendsController>(); | ||
| final authStateController = Get.find<AuthStateController>(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please refrain from making changes unrelated to the direct subject of the PR in the future. As it is a small change which is arguably improving the code, we can leave it as is this time.
|
@coderabbitai review |
✅ Actions performedReview triggered.
|
|
Please fix merge conflicts |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 5
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
lib/l10n/app_en.arb (1)
1793-1836: Remove duplicatefailedToDeleteMessagekey to keep ARB valid.The key appears twice, which can break
gen-l10nor cause last-one-wins ambiguity. Keep the version with the@failedToDeleteMessagedescription and remove the earlier duplicate.🧹 Suggested fix
-"failedToDeleteMessage": "Failed to delete message", - "noFriendsYet": "No Friends Yet",
🤖 Fix all issues with AI agents
In `@lib/l10n/app_localizations_bn.dart`:
- Around line 1387-1419: The new Bengali locale strings are still in
English—update the getters and the inviteToResonate(String url) return to
Bengali (translate noFriendsYet, noFriendsDescription, findFriends,
inviteFriend, noFriendRequestsYet, noFriendRequestsDescription,
inviteToResonate, usernameInvalidFormat, usernameAlreadyTaken) following the
existing translation style in app_localizations_bn.dart; if you cannot provide
proper Bengali translations now, wire these keys to fall back to the English
locale instead (i.e., return the English values from the English localization or
call the fallback helper) so the app behavior is correct until native
translations are added.
In `@lib/l10n/app_localizations_gu.dart`:
- Around line 1377-1400: The new Gujarati localization entries are still in
English; update the getters noFriendsYet, noFriendsDescription, findFriends,
inviteFriend, noFriendRequestsYet, noFriendRequestsDescription and the
inviteToResonate(String url) method to provide proper Gujarati translations
(keeping the $url interpolation unchanged in inviteToResonate), ensuring string
escaping and punctuation follow existing file conventions.
In `@lib/l10n/app_localizations_hi.dart`:
- Around line 1381-1412: Translate the two English validation strings in
app_localizations_hi.dart into Hindi: replace the values returned by the getters
usernameInvalidFormat and usernameAlreadyTaken with appropriate Hindi
translations that match style of surrounding strings (e.g., explain allowed
characters for username and indicate the username is already taken); update the
String getters usernameInvalidFormat and usernameAlreadyTaken so they return the
Hindi text.
In `@lib/l10n/app_localizations_kn.dart`:
- Around line 1384-1416: The Kannada localization currently returns English for
several new keys (noFriendsYet, noFriendsDescription, findFriends, inviteFriend,
noFriendRequestsYet, noFriendRequestsDescription, inviteToResonate,
usernameInvalidFormat, usernameAlreadyTaken); replace the English strings with
accurate Kannada translations for each getter and the inviteToResonate(String
url) method, or implement a clear fallback to another locale if Kannada
translations aren’t available (e.g., call a shared fallback function or
reference an existing en localization), ensuring each symbol returns the
appropriate localized Kannada text.
In `@lib/l10n/app_localizations_mr.dart`:
- Around line 1377-1400: The new empty-state getters (noFriendsYet,
noFriendsDescription, findFriends, inviteFriend, noFriendRequestsYet,
noFriendRequestsDescription) and the inviteToResonate(String url) method are
still in English; replace their English string values with proper Marathi
translations for the mr locale, keeping the inviteToResonate interpolation
($url) intact and escaping any apostrophes as in the file; update the
implementations of those specific symbols so the Marathi texts read naturally
and grammatically correct.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Better to move this file to screens, as it is an entire screen, not a widget. Also, rename accordingly.
|
✅ PR Closed - Thank You, @Mayank4352!
We appreciate your effort and look forward to more contributions from you! 🤝 |
|
🔔 Translation Check Notice The following untranslated language codes were found in 📣 Notifying maintainers per language: Automated post-merge notice by Translation Notifier |
|
Good work, thank you for the contribution |
Description
Added Empty State screens for friends screen and Friend request screen
Fixes #627
Type of change
Please delete options that are not relevant.
How Has This Been Tested?
Tested Locally
Checklist:
Maintainer Checklist
Summary by CodeRabbit
Release Notes
✏️ Tip: You can customize this high-level summary in your review settings.