-
Notifications
You must be signed in to change notification settings - Fork 36
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
refactor: badge color and referrals validations #452
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- Updated `AvatarProfile` to use a local variable `imageSrc` for clearer and safer source URL handling. - Ensured generated avatar fallback works correctly for invalid or missing URLs.
- `finance-invite-friends.tsx`: - Added validation for inviting users: prevent inviting self, malformed emails, or already invited users. - Integrated `checkIfEmailAlreadyInvited` from Supabase actions. - Disabled invite button when email is invalid or loading. - `supabase-actions.ts`: - Created `checkIfEmailAlreadyInvited` to validate if an email has been previously invited. - `errors.ts`: - Introduced new error messages for duplicate invitations and self-invitations.
- Updated the badge color in `BadgeVerified.tsx` from white (`#FFF`) to gold (`#cca421`) for better visibility and distinction.
- **src/sections/user/profile-header.tsx**: Added `fontSize: '3em'` to style for profile header avatar. - **src/components/avatar/avatar.tsx**: - Integrated `COLORS.GRAY_DARK` as the default background color for avatars. - Modified `alt` to render as uppercase. - Merged additional styling properties for consistency. - **src/layouts/_common/account-popover.tsx**: Added `fontSize: '1.25rem'` to avatar style for popover.
- **src/config-global.ts**: Correct typo from `SENTRY_DNS` to `SENTRY_DSN`. - **src/index.tsx**: Update Sentry configuration to reflect the corrected `dsn` key and add `tracePropagationTargets`. - **src/sections/user/profile-header.tsx**: Fix typo in share text, changing "in Watchit" to "on Watchit". These changes ensure proper functionality and correct phrasing across the application.
- Updated `profile-header.tsx` to include additional hashtags, "Crypto" and "Blockchain," in the share URL for X (formerly Twitter). - Helps improve post visibility and align with platform focus.
geolffreym
approved these changes
Jan 21, 2025
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request includes several changes to improve the user experience, enhance code readability, and fix some issues. The most important changes are related to updating the avatar component, improving the invitation system, and fixing some configuration and styling issues.
Avatar Component Updates:
alt
attribute to be uppercase.Invitation System Improvements:
Invitation
interface to a separate types file for better code organization. [1] [2]useReferrals
hook with additional checks and updated local state management. [1] [2] [3] [4]FinanceInviteFriends
component to include additional validation and error handling for invitations. [1] [2] [3]Configuration and Styling Fixes:
GLOBAL_CONSTANTS
configuration.AccountPopover
andProfileHeader
components. [1] [2]Code Refactoring:
supabase-actions
utility functions by adding comments and restructuring the code. [1] [2] [3] [4] [5]