style: improve pill layout for mobile

- Wrap lesson label in span for mobile hiding
- Truncate module name with ellipsis if too long
- Hide "Lesson/Lektion" label on mobile, show only "1 / 3"
- Add lessonLabel i18n keys for EN/DE
This commit is contained in:
2025-12-30 20:03:33 +01:00
parent 5940fb2e72
commit cfce603980
4 changed files with 18 additions and 3 deletions

View File

@@ -163,7 +163,8 @@ export function renderLesson(titleEl, descriptionEl, taskEl, previewEl, prefixEl
* @param {number} total - The total number of levels
*/
export function renderLevelIndicator(element, current, total) {
element.textContent = t("levelIndicator", { current, total });
const label = t("lessonLabel");
element.innerHTML = `<span class="level-label">${label}</span> ${current} / ${total}`;
}
/**