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(UI): Add possibility to choose exercise display order #554

Closed
wants to merge 1 commit into from

Conversation

hernoufM
Copy link
Contributor

@hernoufM hernoufM commented Jun 15, 2023

  • Kind: enhancement

Description

This PR provides users with the ability to sort exercises in the exercises index based on various criteria derived from metadata. The initial version relies solely on groups structured according to the exercise provider's preference, which we refer to as "By legacy". The list of newly added sorting options includes:

  • By deps: This sorting does not divide exercises into specific subgroups. It uses an algorithm to determine dependencies between exercises based on the skills they train and require, as well as any connections between two exercises.
  • By stars: This groups exercises based on their star ratings, from easiest to most difficult.

This PR is closely related to the upgrade of the public corpus, which adds a logical progression to follow and fresh new exercises for practicing OCaml programming language.

Regarding the specific code base changes, all callbacks triggered by clicking on one of the buttons (Exercises, Playground, Lessons, etc.) now have a common type called tab_handler. Previously, each of these callbacks generated the content of the main page without allowing the main page to be divided into multiple modes (in our case, these modes are exercise sorting modes). To address this, an optional argument ?clear_cache was added to prevent the page from always rendering in its initial state.

Co-authored-by: Dario Pinto (@RadioPotin)

Co-authored-by: Dario Pinto <dario.pinto@ocamlpro.com>
@AltGr
Copy link
Collaborator

AltGr commented Oct 19, 2023

Closing as superseded by #564
@hernoufM I invite you to check out the improvements ;)

@AltGr AltGr closed this Oct 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind: feature New user-facing feature.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants