Skip to content

Add dependency path in dependency list

Dheeraj Joshi requested to merge djadmin-dependency-path into master

What does this MR do?

Implementation for #229501 (closed) (& also #227326 (closed))

Implementation

This MR adds dependency path (if it's available) to the Dependency List.

Components Added

  1. Dependency Location Component - Componentize Location cell renderer in the existing Dependency List Table
  2. Dependency Path Viewer Component - It displays the complete path separated by /

More details

There are 4 cases covered based upon the following data structure

{  "path": "Package.json",
   "ancestors":[
      {
         "name":"swell",
         "version":"1.2"
      },
      {
         "name":"emmajsq",
         "version":"10.11"
      }
   ],
   "top_level": false
}
  1. No path available (ancestors is empty) - Package.json
  2. Top level dependency (top_level is true) - Package.json (top level)
  3. Short path - Package.json / swell 1.2 / emmajsq 10.11
  4. Long path - Package.json / swell 1.2 / emmajsq 10.11 / more (Adds a popover to show the complete path if there are more ancestors)

Note

backend issue for this task is scheduled for %13.4 and this implementation is based on the data structure decided at #229472 (closed).

This MR is intended to not cause any visual changes to the users, and keeps everything ready to adapt to the backend changes.

Screenshots

Before After
image image

Changelog

There isn't any changelog entry for this MR as there shouldn't be anything changed for the users.

Edited by Dheeraj Joshi

Merge request reports