Skip to content
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

feat: added draft functionality for comment and responses #727

Merged
merged 13 commits into from
Jul 24, 2024

Conversation

sundasnoreen12
Copy link
Contributor

@sundasnoreen12 sundasnoreen12 commented Jul 4, 2024

INF-1444

Description

Learners using the discussion board have faced a frustrating issue: losing their work when switching tabs and returning to the post. This can be especially disheartening for those writing lengthy comments or responses. The issue occurs specifically while writing comments or responses on posts.

Solution

Draft Feature: Offering a draft functionality where users can save unfinished posts and return to them later. The draft only be saved on the frontend and are lost on page reload.

Screenshots/sandbox (optional):

https://www.loom.com/share/fa0007a967ea406f89835409009dd3b1?sid=72cdf8c3-2e9f-4816-ba62-d7b991b5872b

Merge Checklist

  • If your update includes visual changes, have they been reviewed by a designer? Send them a link to the Sandbox, if applicable.
  • Is there adequate test coverage for your changes?

Post-merge Checklist

  • Deploy the changes to prod after verifying on stage or ask @openedx/edx-infinity to do it.
  • 🎉 🙌 Celebrate! Thanks for your contribution.

@sundasnoreen12 sundasnoreen12 changed the title Sundas/inf 1444 feat: added draft functionality for comment and responses Jul 4, 2024
Copy link

codecov bot commented Jul 4, 2024

Codecov Report

Attention: Patch coverage is 97.01493% with 2 lines in your changes missing coverage. Please review.

Project coverage is 93.16%. Comparing base (422fbf6) to head (13a8a17).

Files Patch % Lines
src/discussions/post-comments/data/hooks.js 97.29% 1 Missing ⚠️
src/discussions/utils.js 75.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #727      +/-   ##
==========================================
+ Coverage   92.88%   93.16%   +0.28%     
==========================================
  Files         160      160              
  Lines        3329     3396      +67     
  Branches      888      917      +29     
==========================================
+ Hits         3092     3164      +72     
+ Misses        219      214       -5     
  Partials       18       18              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

src/discussions/post-comments/data/slices.js Outdated Show resolved Hide resolved
src/discussions/data/selectors.js Outdated Show resolved Hide resolved
@sundasnoreen12 sundasnoreen12 force-pushed the sundas/INF-1444 branch 2 times, most recently from 42a2c94 to 6ebb89b Compare July 15, 2024 07:45
Copy link
Contributor

@awais-ansari awais-ansari left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please do some refactoring in test cases.

src/discussions/post-comments/PostCommentsView.test.jsx Outdated Show resolved Hide resolved
@sundasnoreen12 sundasnoreen12 merged commit db883ca into master Jul 24, 2024
7 checks passed
@sundasnoreen12 sundasnoreen12 deleted the sundas/INF-1444 branch July 24, 2024 12:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants