Checkpoint 要做什麼
只驗證本主題責任,不偷渡其他答案。
本主題檔案:files/index.html
定位:先檢查兩個按鈕各自的 attribute,不以灰色外觀判斷。
Checkpoint · code-edit
只驗證本主題責任,不偷渡其他答案。
只驗證本主題責任,不偷渡其他答案。
本主題檔案:files/index.html
定位:先檢查兩個按鈕各自的 attribute,不以灰色外觀判斷。
頁面不會替你修改檔案;請在實作檔完成後重新整理確認。
原生 disabled 與 aria-disabled 按鈕並列;aria 按鈕事件守門計數從0開始。
現有 runtime 聚焦 aria-disabled button 成功;required facts disabledFocused=false、ariaDisabledFocused=true、blockedClicks=1。
button.setAttribute('aria-disabled','true');button.addEventListener('click',e=>{if(button.ariaDisabled==='true')e.preventDefault()})只在本階段資料夾內操作,避免改到其他章節。
index.htmlstyle.cssmain.js證據:activeId=aria-disabled-button、focused=true;required facts disabledFocused=false、ariaDisabledFocused=true、blockedClicks=1
前往 Solution →