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

Add scoping tabs to activity list pages to improve usability #4203

Merged
merged 28 commits into from
Dec 12, 2022

Conversation

jorg-vr
Copy link
Contributor

@jorg-vr jorg-vr commented Nov 29, 2022

This pull request adds tabs when selecting activities. This should make it easier to find relevant exercises.
image

They all have a tooltip to explain their content
image

I created a generic filter-tabs component which also replaces the existing course tabs. I will also replace the course members tabs with this component in a future pr.

I also added a field featured to repositories, making it possible for us to put certain sets of decent activities in the spotlight. This field can only be edited by zeus.
image

Sorting of activities is also improved, with activities without a name in your language now being sorted last instead of first. This could be further improved in future work by allowing user to sort by every column (Eg to sort by how often an activity is used to find the most popular, see #4208 )

  • Tests were added

Closes #4175 .

@jorg-vr jorg-vr added the feature New feature or request label Nov 29, 2022
@jorg-vr jorg-vr self-assigned this Nov 29, 2022
@jorg-vr jorg-vr temporarily deployed to naos November 30, 2022 12:45 Inactive
@jorg-vr jorg-vr temporarily deployed to naos November 30, 2022 13:05 Inactive
@jorg-vr jorg-vr temporarily deployed to naos November 30, 2022 13:52 Inactive
@jorg-vr jorg-vr changed the title Improve scoping of activity repositories Add scoping tabs to activity list pages to improve usability Nov 30, 2022
@jorg-vr jorg-vr marked this pull request as ready for review November 30, 2022 13:58
@jorg-vr jorg-vr requested a review from a team as a code owner November 30, 2022 13:58
@jorg-vr jorg-vr requested review from niknetniko and chvp and removed request for a team November 30, 2022 13:58
Copy link
Member

@bmesuere bmesuere left a comment

Choose a reason for hiding this comment

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

Feedback from a quick functional test on naos:

My first reaction was a bit of confusion. Part of this might be because exercises/activities is not repeated in the tab name for all tabs (as we do on the courses page), part of this is because I wasn't expecting a tab with "Universiteit Gent" or "Scriptingtalen" as name.

Some suggestions:

  • Include "activities" in the name for all tabs
  • For the institution, use the short name (as with the courses page)
  • There should be a little help text explaining what is shown: or as a (bootstrap) tooltip on the tab name or as a small help text above the table
  • Even with a help text, the course specific exercises are hard to explain. Wouldn't it make more sense (and easier to explain) to add this category as a search filter private/public instead?
  • Suggestions for other names for "featured" are welcome. It's ok, but to me featured indicated a limited number but this section will contains hundreds of exercises. "curated" might be an alternative, but I'm also not sure about that. If we don't find a better name, featured is ok.
  • The active tab isn't stored in local storage (as is done with the filters) which causes reloading (with filters selected) to fail
  • Popularity of an exercise is definitely a strong indicator of interestingness of the exercise so if possible we should surface that information in the table. I don't think we want to list the exact number of courses where an exercises is used, but maybe we can use an icon with different states: low, medium, high, featured. We will then have to pick sensible threshold values. I don't know what the best strategy is for fetching this information: calculate it on demand, store it in the DB or store it in cache. In addition, we could add a filter for it. (Split of in its own issue Order activities by popularity #4208)

@jorg-vr jorg-vr requested a review from bmesuere December 1, 2022 13:28
@jorg-vr jorg-vr marked this pull request as draft December 2, 2022 08:47
@jorg-vr
Copy link
Contributor Author

jorg-vr commented Dec 2, 2022

Course activities and my activities have been merged

@jorg-vr jorg-vr marked this pull request as ready for review December 2, 2022 13:24
@bmesuere bmesuere temporarily deployed to naos December 5, 2022 14:43 Inactive
Copy link
Member

@bmesuere bmesuere left a comment

Choose a reason for hiding this comment

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

👍

  • Did you try a bootstrap popover instead of the title attribute for the info text? It's a bit hidden right now.
  • What's the workflow to "feature" a repository? I couldn't see a checkbox on the repo edit page on naos.
  • I'm not a fan of "recommended exercises", this gives the impression that the list is tailored towards this course/user/series. For the lack of a better name, I guess we can use featured?
  • I noticed that the list of labels always ends with a , (not strictly related to this PR) Moved to it's own issue Activity labels always end on a , #4220

@jorg-vr jorg-vr marked this pull request as draft December 6, 2022 08:38
@jorg-vr jorg-vr marked this pull request as ready for review December 6, 2022 09:47
@jorg-vr jorg-vr requested a review from bmesuere December 6, 2022 09:47
app/assets/javascripts/components/filter_tabs.ts Outdated Show resolved Hide resolved
app/models/activity.rb Outdated Show resolved Hide resolved
Co-authored-by: Charlotte Van Petegem <charlotte.vanpetegem@ugent.be>
Copy link
Member

@niknetniko niknetniko left a comment

Choose a reason for hiding this comment

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

Besides one minor formatting nitpick, I noticed some weird behaviour when using the back button:

  1. Go to the activities (or course) page
  2. Press the browser back button

All params are now removed from the URL, which results in a state where no tab is selected, although they are unchanged:
image
(this is also what happens after you have done a few searches)

app/assets/javascripts/components/filter_tabs.ts Outdated Show resolved Hide resolved
Copy link
Member

@bmesuere bmesuere left a comment

Choose a reason for hiding this comment

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

This is a good first step in solving our exercise discovery problem 👍

@jorg-vr jorg-vr merged commit 9e5235d into develop Dec 12, 2022
@jorg-vr jorg-vr deleted the feature/improve-scoping-of-repositories branch December 12, 2022 08:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Improve scoping of repositories
4 participants