joelniklaus HF Staff commited on
Commit
ee8663f
·
1 Parent(s): a6df89a

make view switch simpler

Browse files
app/src/content/embeds/d3-benchmark-comparison.html CHANGED
@@ -515,7 +515,7 @@
515
  const viewGroup = document.createElement('div'); viewGroup.className = 'control-group';
516
  const viewLabel = document.createElement('label'); viewLabel.setAttribute('for', 'view-' + uid); viewLabel.textContent = 'View';
517
  const viewSelect = document.createElement('select'); viewSelect.id = 'view-' + uid;
518
- [['bar', 'Final Score (Bar)'], ['line', 'Training Progression (Line)']].forEach(([val, text]) => {
519
  const opt = document.createElement('option'); opt.value = val; opt.textContent = text;
520
  if (val === currentView) opt.selected = true;
521
  viewSelect.appendChild(opt);
 
515
  const viewGroup = document.createElement('div'); viewGroup.className = 'control-group';
516
  const viewLabel = document.createElement('label'); viewLabel.setAttribute('for', 'view-' + uid); viewLabel.textContent = 'View';
517
  const viewSelect = document.createElement('select'); viewSelect.id = 'view-' + uid;
518
+ [['bar', 'Final Score'], ['line', 'Training Progression']].forEach(([val, text]) => {
519
  const opt = document.createElement('option'); opt.value = val; opt.textContent = text;
520
  if (val === currentView) opt.selected = true;
521
  viewSelect.appendChild(opt);