TogetherCrew / frontend

MIT License
0 stars 2 forks source link

Add Private Message Feature to Announcements (V2) #261

Closed mehdi-torabiv closed 6 months ago

mehdi-torabiv commented 6 months ago

Description We're looking to enhance the Announcements feature in our application by introducing the capability to send private messages. This addition is aimed at providing a more personalized communication channel within our platform. The V2 update will allow users to select specific recipients for announcements based on roles, users, and engagement categories, further including a safety message channel option for verification purposes.

Objectives Private Message Integration: Enable the sending of announcements as private messages to specific users, roles, or engagement categories. User Selection: Implement UI components for selecting users and roles as recipients of the private message. Engagement Category Selection: Add the ability to target announcements based on engagement categories. Safety Message Channel: Incorporate a feature to select a public channel for sending instructions on verifying the legitimacy of the bot and announcement. UI Feedback for Validation: Provide immediate visual feedback for validation (e.g., ensuring a message is entered before sending). Requirements Front-end Implementation: This task focuses on the front-end repository, requiring updates to UI components, state management, and possibly new API calls to fetch necessary data. React Components: Update or create new React components for user and role selection, engagement category tagging, and safety message channel configuration. State Management: Ensure robust state management to handle the selection of users, roles, engagement categories, and the safety message channel. Validation: Implement front-end validation for form fields to ensure data integrity before submission. Error Handling: Provide clear error messages for any invalid inputs or failed API requests. Potential Challenges API Integration: Ensuring the front-end components correctly interact with the backend for fetching user, role, and category data. User Experience: Maintaining a seamless and intuitive user experience as new components and selections are introduced. Data Syncing: Keeping the state in sync across multiple components and handling asynchronous updates effectively. Implementation Notes Utilize existing design patterns and component libraries to maintain consistency with the rest of the application. Consider using context or Redux for managing the state related to announcements, especially for complex interactions between components. Accessibility and responsiveness should be kept in mind during development to ensure the feature is usable across all devices and assistive technologies.

Acceptance Criteria Users can send private messages as part of the Announcements feature. The UI supports selecting individual users, roles, or engagement categories as message recipients. A safety message channel can be selected and configured through the UI. Front-end validation provides immediate feedback for required fields and incorrect inputs. The feature is fully responsive and accessible. Please provide input on the proposed changes, any potential backend dependencies, and considerations we might need to account for during implementation.