feat: first approach advisory-tab#792
Open
juliankepka wants to merge 13 commits into
Open
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds an initial “Security Advisory” tab for assets, including UI for listing advisories, creating/editing draft advisories, and displaying advisory details. It also introduces a CVSS utility module (v3.1 + v4.0) used to parse/build vectors and compute scores/severities for advisories.
Changes:
- Added a new asset menu entry and pages for advisory list + advisory detail routes.
- Implemented an
AdvisoryDialog(multi-step) for creating/editing advisories, including a CVSS vector builder. - Introduced
src/utils/cvss.tswith CVSS 3.1 formula scoring and CVSS 4.0 lookup/interpolation scoring plus helpers.
Reviewed changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated 9 comments.
Show a summary per file
| File | Description |
|---|---|
| src/utils/cvss.ts | Adds CVSS metric definitions, vector parsing/building, and scoring utilities for v3.1/v4.0. |
| src/types/api/api.ts | Introduces SecurityAdvisory and AdvisoryAffectedPackage API types. |
| src/hooks/useAssetMenu.ts | Adds a “Security Advisory” navigation entry for asset pages. |
| src/components/ui/tooltip.tsx | Exports TooltipPortal for use in the new advisory UI. |
| src/components/AdvisoryDialog.tsx | Adds advisory create/edit dialog including CVSS vector builder and affected packages flow. |
| src/app/(loading-group)/.../advisory/page.tsx | Implements advisory list page with severity display and creation entry point. |
| src/app/(loading-group)/.../advisory/[advisoryId]/page.tsx | Implements advisory detail page with publish/withdraw/delete actions and CVSS metric display. |
| src/app/(loading-group)/.../advisory/[advisoryId]/loading.tsx | Adds loading skeleton page for advisory detail route. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes l3montree-dev/devguard#2168 together with l3montree-dev/devguard#2183