Skip to content

Commit e6b36b8

Browse files
Connor Rogersonclaude
andcommitted
Fix JS syntax error: duplicate const modal in renderCheatsheet
The tag shorthand variable modal and the modal card template function were both declared const modal in the same block scope, causing a SyntaxError that prevented the entire script from running (hence the loading spinner hang). Renamed the tag variable to modalTag. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent e05d382 commit e6b36b8

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

index.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -463,7 +463,7 @@ <h1 class="app-title">Language<span>Lab</span></h1>
463463
<div class="passive-bar"><div class="passive-bar-label">Passiv</div><div class="passive-formula">${passiveHtml}</div></div>
464464
</div>`;
465465
const tag=(cls,label)=>`<span class="utag ${cls}">${label}</span>`;
466-
const spoken=tag('utag-spoken','spoken'), written=tag('utag-written','written'), formal=tag('utag-formal','formal/literary'), common=tag('utag-common','very common'), modal=tag('utag-modal','modals always');
466+
const spoken=tag('utag-spoken','spoken'), written=tag('utag-written','written'), formal=tag('utag-formal','formal/literary'), common=tag('utag-common','very common'), modalTag=tag('utag-modal','modals always');
467467
const kw=s=>`<span class="kw">${s}</span>`, ex=s=>`<span class="ex">${s}</span>`;
468468

469469
const tenseCards=[
@@ -477,7 +477,7 @@ <h1 class="app-title">Language<span>Lab</span></h1>
477477
`<em>Regular:</em> stem + ${kw('-te / -test / -te / -ten / -tet / -ten')}<br><em>Irregular:</em> strong verb stem change<br>${ex('gehen → <b>ging</b>, kommen → <b>kam</b>')}`,
478478
'Er arbeitete bis spät in die Nacht.','He worked until late into the night.',
479479
'Narrative and written past (novels, news). Modals and <em>sein/haben</em> always prefer Präteritum over Perfekt in speech too.',
480-
written+formal+modal,
480+
written+formal+modalTag,
481481
`${kw('wurde(n)')} + Partizip II &nbsp;→&nbsp; Das Buch ${kw('wurde')} geschrieben.`),
482482
tc('flag-perfekt','Perfekt','Present perfect / conversational past',
483483
`${kw('haben')} / ${kw('sein')} (Präsens) + Partizip II<br>${ex('ge- + stem + -(e)t &nbsp;or&nbsp; irregular ge-…-en')}<br>Motion/change verbs take ${kw('sein')}`,

0 commit comments

Comments
 (0)