fix(site): resolve axe defects in showcase pages
This commit is contained in:
parent
c4aade92fc
commit
c86271286d
3 changed files with 202 additions and 17 deletions
|
|
@ -149,7 +149,7 @@
|
|||
<div class="statline" id="en-stats"></div>
|
||||
<div class="sheet">
|
||||
<p class="en-sum mono">합계 <strong id="en-credits">0</strong>학점 / 18</p>
|
||||
<div class="credit-gauge" role="img">
|
||||
<div class="credit-gauge" id="en-gauge-wrap" role="img" aria-label="신청 학점 진행률, 최대 18학점 중 0%">
|
||||
<i id="en-gauge" style="width: 0%"></i>
|
||||
</div>
|
||||
<p class="panel-note muted">정정 기간은 3/9–3/13입니다. 18학점 초과 신청은 학부 사무실 승인이 필요하고, 두 번 결석하면 탈강 처리됩니다 — 변경은 이 화면에서 할 수 있습니다.</p>
|
||||
|
|
@ -586,7 +586,9 @@
|
|||
const renderEnrollments = () => {
|
||||
{
|
||||
const list = COURSES.filter((c) => enrolled.has(c.id));
|
||||
$("en-gauge").style.width = Math.round((list.reduce((a, c) => a + c.credits, 0) / MAX_CREDITS) * 100) + "%";
|
||||
const gaugePct = Math.round((list.reduce((a, c) => a + c.credits, 0) / MAX_CREDITS) * 100);
|
||||
$("en-gauge").style.width = gaugePct + "%";
|
||||
$("en-gauge-wrap").setAttribute("aria-label", `신청 학점 진행률, 최대 ${MAX_CREDITS}학점 중 ${gaugePct}%`);
|
||||
const credits = list.reduce((a, c) => a + c.credits, 0);
|
||||
$("en-stats").innerHTML =
|
||||
`<div>신청 <strong>${list.length}과목</strong></div>` +
|
||||
|
|
@ -655,7 +657,7 @@
|
|||
`<td class="num mono">${r.done || "—"}</td><td class="num mono">${r.now ? "+ " + r.now : "—"}</td>` +
|
||||
`<td class="num mono">${r.need ? total : total || "—"}</td>` +
|
||||
`<td class="num mono">${r.need ? (left> 0 ? left : left === 0 ? "0" : "초과") : "—"}</td>` +
|
||||
`<td><div class="cr-bar" role="img"><i style="width: ${pct}%"></i></div></td>`;
|
||||
`<td><div class="cr-bar" role="img" aria-label="이수 진행률 ${pct}%"><i style="width: ${pct}%"></i></div></td>`;
|
||||
return tr;
|
||||
}),
|
||||
(() => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue