Release 0.0.11
This commit is contained in:
@@ -442,7 +442,7 @@ function groupByTarget(findings) {
|
||||
current.count += 1;
|
||||
if (finding.severity === "high") current.severity = "high";
|
||||
if (finding.source?.sourceLabel) {
|
||||
const key = finding.source.sourceUuid ?? finding.source.sourceLabel;
|
||||
const key = buildSourceKey(finding.source);
|
||||
current.sources.set(key, {
|
||||
sourceLabel: finding.source.sourceLabel,
|
||||
sourceName: finding.source.sourceName ?? null,
|
||||
@@ -553,7 +553,7 @@ function renderLocalizedCodeText(key, data, codeValues) {
|
||||
function renderSourceLink(source) {
|
||||
const trail = Array.isArray(source.sourceTrail) && source.sourceTrail.length ? source.sourceTrail : null;
|
||||
if (trail) {
|
||||
return trail.map(renderTrailNode).join(' <span class="storage-audit__trail-separator">-></span> ');
|
||||
return `<span class="storage-audit__trail">${trail.map(renderTrailNode).join('<span class="storage-audit__trail-separator">-></span>')}</span>`;
|
||||
}
|
||||
|
||||
const label = source.sourceName ? `${source.sourceLabel} (${source.sourceName})` : source.sourceLabel;
|
||||
@@ -583,3 +583,10 @@ function renderTrailNode(node) {
|
||||
function renderUuidLink(uuid, label) {
|
||||
return `<a class="content-link" draggable="true" data-link data-uuid="${escapeHtml(uuid)}" data-tooltip="${escapeHtml(label)}"><i class="fa-solid fa-file-lines"></i><span>${escapeHtml(label)}</span></a>`;
|
||||
}
|
||||
|
||||
function buildSourceKey(source) {
|
||||
const trailKey = Array.isArray(source.sourceTrail) && source.sourceTrail.length
|
||||
? source.sourceTrail.map(node => node.uuid ?? node.label ?? "").join(">")
|
||||
: "";
|
||||
return `${source.sourceUuid ?? ""}|${trailKey}|${source.sourceLabel ?? ""}`;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user