Change how modal keys display

This commit is contained in:
Ian Keane 2026-06-11 14:28:58 -04:00
parent e85a4ca987
commit 3810d1c05c
2 changed files with 4 additions and 6 deletions

9
app.js
View file

@ -260,7 +260,7 @@ const popover = $('filter-popover');
const popoverInner = $('filter-popover-inner'); const popoverInner = $('filter-popover-inner');
let activeFilterKey = null; let activeFilterKey = null;
const BOOL_FILTERS = new Set(['modal']); const BOOL_FILTERS = new Set([]); // modal merged into key display; filter still works programmatically
const DROPDOWN_FILTERS = new Set(['source', 'instrument', 'tuning', 'difficulty', 'status']); const DROPDOWN_FILTERS = new Set(['source', 'instrument', 'tuning', 'difficulty', 'status']);
function openFilterPopover(key, thEl) { function openFilterPopover(key, thEl) {
@ -425,8 +425,8 @@ function renderTable() {
const tuningRaw = entry?.tuning ?? ''; const tuningRaw = entry?.tuning ?? '';
const instStr = instRaw ? (tuningRaw ? `${instRaw} (${tuningRaw})` : instRaw) : ''; const instStr = instRaw ? (tuningRaw ? `${instRaw} (${tuningRaw})` : instRaw) : '';
const keyStr = tune.key const keyStr = tune.key
? (tune.modal ? `${tune.key} modal` : tune.key) ? (tune.modal ? `${tune.key} Modal` : tune.key)
: (tune.modal ? 'modal' : ''); : (tune.modal ? 'Modal' : '');
const metaRaw = [instStr, keyStr].filter(Boolean).join(' · '); const metaRaw = [instStr, keyStr].filter(Boolean).join(' · ');
const mobPills = entry ? pillStatus(entry.status, 'mob-pill') : ''; const mobPills = entry ? pillStatus(entry.status, 'mob-pill') : '';
const mobActions = [ const mobActions = [
@ -439,8 +439,7 @@ function renderTable() {
tr.innerHTML = ` tr.innerHTML = `
<td><span class="cell-trunc cell-name-content mob-truncatable" data-full="${esc(nameRaw)}" title="${esc(nameRaw)}">${esc(nameRaw)}</span></td> <td><span class="cell-trunc cell-name-content mob-truncatable" data-full="${esc(nameRaw)}" title="${esc(nameRaw)}">${esc(nameRaw)}</span></td>
<td><span class="cell-trunc cell-source-content mob-truncatable" data-full="${esc(sourceRaw)}" title="${esc(sourceRaw)}">${esc(sourceRaw)}</span></td> <td><span class="cell-trunc cell-source-content mob-truncatable" data-full="${esc(sourceRaw)}" title="${esc(sourceRaw)}">${esc(sourceRaw)}</span></td>
<td>${esc(tune.key ?? '')}</td> <td>${esc(keyStr)}</td>
<td>${tune.modal ? '<span class="pill pill-yes">Yes</span>' : '<span class="pill" style="background:#222">—</span>'}</td>
<td>${esc(entry?.instrument_name ?? '')}</td> <td>${esc(entry?.instrument_name ?? '')}</td>
<td>${esc(entry?.tuning ?? '')}</td> <td>${esc(entry?.tuning ?? '')}</td>
<td>${pillStatus(entry?.status)}</td> <td>${pillStatus(entry?.status)}</td>

View file

@ -29,7 +29,6 @@
<th data-col="name">Name <span class="sort-indicator"></span></th> <th data-col="name">Name <span class="sort-indicator"></span></th>
<th data-filter="source">Source</th> <th data-filter="source">Source</th>
<th data-filter="key">Key</th> <th data-filter="key">Key</th>
<th data-filter="modal"><span class="col-full">Modal</span><span class="col-short">Mod.</span></th>
<th data-filter="instrument">Instrument</th> <th data-filter="instrument">Instrument</th>
<th data-filter="tuning">Tuning</th> <th data-filter="tuning">Tuning</th>
<th data-filter="status">Status</th> <th data-filter="status">Status</th>