Commit Graph

62 Commits

Author SHA1 Message Date
Muhammad Adeel Tajamul
e791a06370 Merge pull request #86 from openedx/tnl-9648
fix: report indicator showing different on post summary
2022-03-10 06:29:03 +05:00
Mehak Nasir
3cbb7e0fc3 fix: card component update to handle paragon breaking changes 2022-03-09 19:02:15 +05:00
Keith Grootboom
c65230d5da feat: show empty state on posts pages [BD-38] [TNL-9484] [SE-5347] (#65)
When a user browses the discussion pages, show a page showing
that there is no data, rather than a blank page.

This PR implements the designs for this page while refactoring the
DiscussionHome component so that it doesn't get much larger.

- Created a hooks file and move some of the larger hooks in there.
- Added selectors for the state that would be needed for the
  components.
- Split the DiscussionHome into DiscussionContent and
  DiscussionSidebar to make it clearer where certain things get
  rendered.
- Adds a message to the sidebar to display No Results when
  appropriate.
- Added the NoResults component to show when filtering posts and there
  is nothing to show.
2022-03-09 12:15:32 +00:00
adeel.tajamul
5470a217ae fix: report indicator showing different on post summary 2022-03-09 10:43:02 +05:00
Mehak Nasir
f50334f434 fix: hover style added for card component 2022-03-08 20:31:17 +05:00
adeel.tajamul
bb73bdb9df fix: post summaries disappear upon scroll to the bottom 2022-03-04 16:52:59 +05:00
Mehak Nasir
f4f7c61c7a style: action bar and radio button fixes 2022-03-02 20:42:47 +05:00
Arunmozhi
ac54d25be8 feat: replace cohort text with icon & overlay in posts (#69)
This implements the new UI design of showing an icon for posts that are
specific to a cohort. The icon upon mouse-over shows the name of the
cohort as an overlay.

https://openedx.atlassian.net/browse/TNL-9483
2022-03-02 14:02:46 +00:00
Mehak Nasir
20cc3e9827 style: search bar and add post button fix 2022-03-02 16:12:33 +05:00
Kshitij Sobti
d31c438fc1 feat: add support for new provider and new topic api (#54)
Adds support for the new openedx provider and the new topics structure it introduces which ses the new topics v2 API.
2022-03-02 08:13:44 +00:00
Arunmozhi
04547ef96e feat: adds a badge to post links showing unread comments (#72)
This adds a badge in the PostFooter component if there are new comments
in a post that is unread by the user. For eg., "3 new".

https://openedx.atlassian.net/browse/TNL-9573
2022-03-01 13:11:22 +00:00
adeel.tajamul
ab601d3abb fix: removed legacy indicator of unread post 2022-02-24 16:54:46 +05:00
Muhammad Adeel Tajamul
b56c420a7e Merge pull request #67 from openedx/tnl-9570
[TNL-9570] Message icon showing in the absense of comments or responses on the post.
2022-02-24 16:05:10 +05:00
adeel.tajamul
d996914009 fix: added check to display message icon 2022-02-24 14:56:42 +05:00
Abdurrahman Asad
06c9d967dd fix: display non-breaking space entity properly in post summary 2022-02-24 13:05:24 +05:00
Keith Grootboom
789d468440 fix: Like count should not display is zero (#62)
When there are no likes just show the empty like icon.
2022-02-22 11:56:44 +00:00
Awais Ansari
bc610e579c Revert "feat: integrate feedback google form (#60)" (#61)
This reverts commit 54f02377f0.
2022-02-15 16:21:25 +05:00
Awais Ansari
54f02377f0 feat: integrate feedback google form (#60)
* feat: integrate google feedback form

* test: fix discussion home fail test cases
2022-02-11 12:40:37 +05:00
Awais Ansari
d02a5ef6a6 Revert "feat: integrate feeder package" 2022-02-07 15:06:11 +05:00
Awais Ansari
c0f2e305c2 test: add postActionsBar test cases 2022-02-04 18:23:47 +05:00
Awais Ansari
880c061e9f feat: integrate feeder package 2022-02-03 23:08:24 +05:00
Kshitij Sobti
9ba94966f1 feat: delete confirmation dialogs [BD-38] [TNL-9351] (#49)
Adds delete confirmation dialogs for posts, comments and replies.
2022-01-27 07:18:43 +00:00
Kshitij Sobti
55c37db023 fix: remove discussions from the base path [BD-38] [TNL-9347] (#47)
* fix: remove discussions from the base path

Remove the discussions prefix from the base path to avoid potential repeat of that
word the path when deployed.
2022-01-07 04:54:36 +00:00
Kshitij Sobti
2ed5aee9e7 fix: fixes issues with redirects
Currently redirecting doesn't preserve query parameters. This change fixes this and fixes all usages of history.push
2021-12-28 16:37:15 +05:30
Kshitij Sobti
ea1031e2bf Merge pull request #43 from edx/kshitij/fix-topic-search
fix: starting a search redirects you to the all posts page [BD-38] [TNL-9336]
2021-12-28 11:04:05 +00:00
Kshitij Sobti
a6f7187893 fix: starting a search redirects you to the all posts page 2021-12-10 00:23:10 +05:30
Kshitij Sobti
4763702bd3 fix: fix autosaving 2021-12-09 11:27:41 +05:30
Kshitij Sobti
b07b4043b0 test: tests 2021-12-06 15:45:14 +05:30
Kshitij Sobti
ceea220d62 feat: Fully implements support for cohorts
Uses the discussions settings API to fetch course division configuration and makes the cohort selection dynamic based on if a topic is divided.
2021-12-06 11:15:01 +05:30
Kshitij Sobti
e7a0eba5ef feat: Make UI more responsive to smaller screens and embeds
Updates the UX so that on a smaller screen eitherthe topic/post sidebar is displayed or the post view to give each more space.

Also adds support for an in-context view where the header and navigation is replaced with a sidebar-specific header.
2021-11-25 12:38:11 +05:30
Kshitij Sobti
c9cb8dd0e7 feat: Add new breadcrumb navigation
Adds the new breadcrumb dropdown-based navigation UI. This allows browsing the category and topic structure using dropdowns.
2021-11-23 14:43:53 +05:30
Kshitij Sobti
7f26f3a6ca feat: Add topic link to discussion post
Refactors the topics code and adds the topic relation box to posts.
2021-11-17 09:11:10 +05:30
Kshitij Sobti
18d19369a9 feat: add support for anonymous posting
Hooks up the configuration API to allow posting threads anonymously.
2021-11-16 10:54:48 +05:30
Kshitij Sobti
6bd7ce929d Merge pull request #33 from edx/kshitij/post-ui-updates
feat: Show cohort info in posts [BD-38] [TNL-8694]
2021-11-09 13:58:29 +00:00
Awais Jibran
681bc4de67 Merge pull request #27 from open-craft/felipetrz/bb-4961-tiny-mce-improvements
feat: TinyMCE improvements [BD-38] [TNL-8779] [BB-4961]
2021-11-04 09:47:10 +05:00
Felipe Trzaskowski
2138c12eb4 fix: remove the "powered by tiny" text
fix: skin loading with transparent background

For some reason, loading the skin from `skin.min.css` was resulting in
dialogs and menus appearing with a transparent background. Replacing the
import for the non-minified version, `skin.css`, solves the problem.

feat: enable native browser spellchecking

Disabling the TinyMCE context menu is required for the native
spellchecking right click suggestions to work.

feat: enable autosave plugin

Autosaves to local storage every second.
Restores draft when empty.

feat: add new toolbar buttons

Additional toolbar buttons requested: quoting, code formatting, HTML button with text
label, clear formatting, undo/redo

feat: add image button to the toolbar, and load the imagetools plugin

The imagetools only work on images loaded from the same domain.

feat: add image upload capability

Depends on an upload endpoint in the REST API.

feat: enable a11y_advanced_options

This will only affect the image plugin.
For full a11y checking functionality, a premium TinyMCE key is required.

fix: TinyMCE content styles not being properly loaded

Content CSS need to be loaded as raw text, to be included in the TinyMCE
initialization. For this, we need webpack's `raw-loader` as a dependency.

fix: refactor the upload API call into posts/data/api

feat: pass courseId and threadId to the upload API endpoint

fix: rename customized buttons with openedx prefix

fix: use exact version for dependencies

fix: improve jsdoc and update the upload endpoint

fix: simplify TinyMCE side of the upload call

fix: update the upload url
2021-10-29 17:15:27 -03:00
Kshitij Sobti
2f7771e9fc feat: add cohort information to post footer 2021-10-29 19:13:26 +05:30
Maxim Beder
5fafa44b56 feat: add cohort selection
Allow admins select a cohort when creating a new post.

If a user is not a discussions administrator, or if trying to edit
existing post, can't select a cohort (field is hidden).

fix: fix adding threads for topics that haven't been preloaded
2021-10-28 21:51:48 +02:00
Kshitij Sobti
c8c3bb925c feat: Improve UX to match new mockups
Uses new API features for preview, deleting, pinning, and closing. Refactors and improves styling to match new mockups.
Adds the new post filter bar element.
2021-10-28 16:43:28 +05:30
Felipe Trzaskowski
3a71253e34 fix: move the loading indicator and scroll threshold inside the posts list 2021-10-19 11:03:51 -03:00
Felipe Trzaskowski
b8e3b86264 fix: posts pagination is loaded by scrolling
Implemented a ScrollThreshold reusable component to detect scrolling
events, which can be used in the place of a Button.

Removed the i18n entry created for the Button, which is no longer
needed.
2021-10-19 11:01:05 -03:00
Felipe Trzaskowski
1d3827ed10 feat: add posts pagination [BD-38] [TNL-8810] [BB-4993] 2021-10-19 11:01:05 -03:00
Kshitij Sobti
d237be78b6 feat: add support for loading endorsed and un-endorsed comments separately for question type posts 2021-10-06 18:26:06 +05:30
Kshitij Sobti
16e5901a46 feat: Add a reply editor and hook to API
This change uses the TinyMCE editor for editing comments and making comments and replies to existing threads.
2021-09-22 19:35:31 +05:30
Kshitij Sobti
5db87f54bb feat: Add post actions dropdown menu
Adds a dropdown menu for comments and posts to perform actions like pinning, unpinning, reporting etc.
2021-09-20 14:52:19 +05:30
Kshitij Sobti
586cf3e581 Remove Object.assign
Use arrays for pages instead of a map
2021-09-14 21:51:09 +05:30
Kshitij Sobti
582a5fd3ae refactor: update normalisation code to work in thunks instead of reducers 2021-09-14 19:22:47 +05:30
Kshitij Sobti
a1148867ca feat: Update the post editor to include TinyMCE and connect to API
This change adds the TinyMCE editor for editing posts and connects the post editor to the API, allowing adding new posts and editing existing ones.
2021-09-14 19:16:28 +05:30
Kshitij Sobti
3395a1b381 refactor: update navigation paths for a more consistent experience
Navigation paths have now been structured such that you can move between tabs and topcis without losing the current page.
2021-09-07 21:18:18 +05:30
Kshitij Sobti
bd79e6b45b Merge pull request #11 from open-craft/kshitij/mark-as-read
feat: Mark posts as read after a delay of 2 seconds [BD-38] [TNL-8658] [BB-4734]
2021-09-07 15:38:30 +00:00