Remove severity column from grouped tables
This commit is contained in:
@@ -357,7 +357,6 @@ function renderOrphanFilterToggle(key, label, checked) {
|
||||
|
||||
function renderGroupedTable(groups, { includeOwner=false, includeReason=false, includeSources=false }={}) {
|
||||
const headers = [
|
||||
`<th>${localize("KSA.Table.Severity")}</th>`,
|
||||
`<th>${localize("KSA.Field.Target")}</th>`,
|
||||
`<th>${localize("KSA.Table.References")}</th>`
|
||||
];
|
||||
@@ -369,8 +368,7 @@ function renderGroupedTable(groups, { includeOwner=false, includeReason=false, i
|
||||
? buildGroupedTooltip(group)
|
||||
: "";
|
||||
const cells = [
|
||||
`<td><span class="storage-audit__severity storage-audit__severity--inline storage-audit__severity--hint severity-${group.severity}" ${note ? `title="${escapeHtml(note)}"` : ""}>${severityLabel(group.severity)}</span></td>`,
|
||||
`<td><code>${escapeHtml(group.target)}</code></td>`,
|
||||
`<td><div class="storage-audit__target-cell"><code>${escapeHtml(group.target)}</code>${note ? `<span class="storage-audit__hint-anchor" title="${escapeHtml(note)}" aria-label="${escapeHtml(note)}">?</span>` : ""}</div></td>`,
|
||||
`<td>${group.count ?? ""}</td>`
|
||||
];
|
||||
if (includeOwner) cells.push(`<td><code>${escapeHtml(group.ownerLabel ?? "")}</code></td>`);
|
||||
@@ -528,12 +526,6 @@ function format(key, data) {
|
||||
return game.i18n?.format(key, data) ?? key;
|
||||
}
|
||||
|
||||
function severityLabel(severity) {
|
||||
const key = `KSA.Severity.${severity}`;
|
||||
const localized = localize(key);
|
||||
return localized === key ? severity : localized;
|
||||
}
|
||||
|
||||
function formatCount(count, nounKey) {
|
||||
return `${count} ${localize(nounKey)}`;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user