[PP-1] Convert course navigation block to SDC

Created on 27 March 2025, 5 months ago

Problem/Motivation

Once 📌 Update legacy themes Active lands we'll have a functional navigation block with lesson and activity status available for themers.

This should be a good starting point to convert to an SDC for use with UI suite and etc.

The conversion should preserve (or improve) the caching/placeholder logic from that issue - e.g. we want to individually placeholder the activities list for each lesson so that they can be cached independently of each other and loaded ASAP both on cold and warm caches.

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

📌 Task
Status

Active

Version

1.0

Component

User interface

Created by

🇬🇧United Kingdom catch

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @catch
  • 🇨🇦Canada ob3ron Canada

    Removing "PP-1" as 📌 Update legacy themes Active has landed, and adding as a child issue of 📌 Improve general appearance Active

  • Merge request !87Course navigation improvements → (Open) created by Unnamed author
  • Pipeline finished with Success
    4 months ago
    Total: 270s
    #486830
  • 🇨🇦Canada ob3ron Canada

    WIP commit - includes a number of navigation improvements:

    • adds single-directory components (SDC) for layout and styling.
    • displays all but the current lesson as collapsed accordion lists, for compactness and better visual progress display.
    • removes the link url from activities that are not available to visit, based on the course-level Free Navigation setting, or if the user is revisiting a completed course.
    • improves the course navigation caching/placeholder logic, with appropriate cache lifetimes based on per-user and per-lesson display options.
    • adds styling to each activity to indicate current / answered / unanswered activities.
    • adds activity scores on course revisit.
  • 🇨🇦Canada ob3ron Canada

    Will do additional code cleanup and optimization, meanwhile any feedback on the looks and function is welcome.

  • 🇬🇧United Kingdom catch

    Haven't reviewed the MR or functionality yet, but just changing status to make it clear there's something to look at here.

  • Pipeline finished with Failed
    4 months ago
    #499352
  • Pipeline finished with Success
    4 months ago
    Total: 379s
    #499377
  • Pipeline finished with Success
    4 months ago
    #499387
  • 🇨🇦Canada ob3ron Canada

    Added additional caching improvements and testing. Should be ready for review.

  • Pipeline finished with Success
    4 months ago
    Total: 421s
    #499773
  • First commit to issue fork.
  • 🇨🇦Canada ob3ron Canada

    Sorry about the accidental test changes, not sure how that happened!

  • 🇵🇱Poland Graber

    No worries, just merged 📌 Improve / fix course navigation logic Active , let's use training manager API as much as possible here.

  • Pipeline finished with Failed
    3 months ago
    Total: 286s
    #506886
  • Pipeline finished with Success
    3 months ago
    Total: 233s
    #506887
  • Pipeline finished with Success
    3 months ago
    #506912
  • Merge request !100Updated nav block SDC → (Merged) created by Unnamed author
  • Assigned to ob3ron
  • Status changed to Needs review 3 months ago
  • Pipeline finished with Failed
    3 months ago
    Total: 1251s
    #512881
  • Pipeline finished with Failed
    3 months ago
    Total: 326s
    #512899
  • Pipeline finished with Failed
    3 months ago
    Total: 286s
    #512904
  • Pipeline finished with Failed
    3 months ago
    Total: 500s
    #512908
  • Pipeline finished with Failed
    3 months ago
    Total: 503s
    #512941
  • 🇨🇦Canada ob3ron Canada

    Updated BlockBuilder to depend on TrainingManager as the single source of truth for activity access.

    Also added a progress bar and a few other tweaks to the navigation block.

  • Pipeline finished with Failed
    3 months ago
    Total: 281s
    #512959
  • 🇵🇱Poland Graber

    graber changed the visibility of the branch 3515744-convert-course-navigation to hidden.

  • 🇬🇧United Kingdom catch

    Added some comments on the MR - I think the locking can be removed and the caching logic potentially simplified a bit.

  • Pipeline finished with Canceled
    3 months ago
    Total: 156s
    #520866
  • Pipeline finished with Success
    3 months ago
    Total: 441s
    #520868
  • 🇨🇦Canada ob3ron Canada

    Addressed all feedback; should be good to go!

  • Pipeline finished with Failed
    3 months ago
    Total: 5999s
    #520891
  • 🇵🇱Poland Graber

    Cache is enabled.
    All this will need extending automated tests coverage but I'll get to that in a separate issue.

  • Pipeline finished with Skipped
    3 months ago
    #523269
  • 🇵🇱Poland Graber

    Merged and created one follow-up to optimize this a bit ( 📌 Course nav - additional caching optimization Active ).

  • Automatically closed - issue fixed for 2 weeks with no activity.

Production build 0.71.5 2024