Langsung ke konten
Skillpedia
Website & UI (frontend)75k · #2850

focus-not-obscured

Fungsinya

Skill ini memeriksa apakah elemen halaman yang tetap di posisinya menutupi item yang sedang memiliki fokus keyboard. Skill ini cocok untuk developer yang membangun menu lengket, banner cookie, dan widget chat.

Kapan dipakai

  • ✓Saat header lengket menutupi tautan ketika Anda menekan Tab di halaman.
  • ✓Saat banner cookie menutupi kolom formulir yang sedang diisi pengguna keyboard.
  • ✓Saat Anda menambahkan tombol chat atau bilah promo yang tetap di layar.

Link skill

https://github.com/thedaviddias/Front-End-Checklist/blob/main/skills/focus-not-obscured/SKILL.md

Salin lalu tempelkan ke AI Anda (Claude, ChatGPT, atau Cursor) dan minta AI mengikuti instruksinya.

Cara pakai

Cara paling mudah: salin pesan ini dan tempelkan ke AI Anda. AI akan membaca skill dan mengikuti instruksinya.

Pesan siap tempel

Gunakan skill ini untuk membantu saya: https://github.com/thedaviddias/Front-End-Checklist/blob/main/skills/focus-not-obscured/SKILL.md Baca file SKILL.md di link tersebut dan ikuti instruksinya untuk tugas saya.
Mau AI Anda menemukan skill seperti ini sendiri?Pasang MCP Skillpedia gratis: cukup satu baris, dan AI mencari di antara 15.000+ skill sebelum tiap tugas.Pasang dalam 1 menit →

Contoh permintaan ke AI

“Bisakah Anda memeriksa bahwa header lengket saya tidak menutupi tautan yang difokuskan saat saya memakai tombol Tab?”

5 skill baru setiap minggu. 1 menit baca.

Cara kerjanya

Agent menguji fokus keyboard saat elemen lengket ditampilkan dan mencari kasus di mana item yang difokuskan bergulir di bawahnya. Agent menyarankan scroll-padding atau perubahan ukuran overlay.

Konten teknis (SKILL.md asli)

Teks asli dari pembuat, dalam bahasa Inggris, langsung dari GitHub.

Keep focused elements unobscured

A visible focus ring is not enough if the focused element sits behind a sticky header or footer. Keyboard users need to see the actual focused control and the focus indicator at the same time in order to continue the task.

Quick Reference

  • Sticky UI must not cover the focused control while keyboard users tab through the page
  • Use scroll-padding or equivalent spacing when fixed headers or footers are present
  • Test with cookie banners, chat widgets, and consent bars open
  • Re-test at zoomed and mobile layouts where overlap problems usually appear

Check

Audit keyboard focus with all sticky UI active. Check headers, footers, cookie banners, promo bars, and chat launchers for cases where the focused element scrolls underneath them.

Fix

Add layout spacing such as scroll-padding, reduce overlay height, or change focus/scroll behavior so the focused element remains visible when tabbing.

Explain

Explain WCAG Focus Not Obscured, why fixed-position UI commonly breaks it, and how scroll-padding and overlay layout choices prevent the issue.

Code Review

Review sticky layout, focus styles, overlays, and keyboard navigation related to Keep focused elements unobscured. Flag exact selectors, breakpoints, or UI states where focused controls can be covered.


For full implementation details, code examples, and framework-specific guidance, see references/rule.md.

Rule page: https://frontendchecklist.io/rules/accessibility/focus-not-obscured

Pertanyaan umum

Apa itu scroll-padding?

Itu adalah pengaturan CSS yang menyisakan ruang di bagian atas atau bawah saat browser menggulir ke item yang difokuskan, sehingga item tetap terlihat.

Elemen apa saja yang diperiksa?

Header, footer, banner cookie, bilah promo, dan tombol chat.

Kapan masalah ini biasanya muncul?

Skill menyatakan masalah tumpang tindih sering muncul pada tata letak yang diperbesar dan di ponsel, sehingga disarankan untuk menguji ulang di sana.

Detail

Deskripsi asli dari pembuat

Use when reviewing sticky navigation, consent banners, chat widgets, skip links, or any fixed-position UI. Validate the actual tab order and viewport behavior at realistic zoom levels.

repo: thedaviddias/Front-End-Checklist

Popularitas

Bintang GitHub
75k
Peringkat
#2850
Lisensi
MIT
Diperbarui
31/10/2026

Apakah skill ini berguna?

0

Masuk untuk memberi suara.

Komentar

  • …

Skill lain dari repositori ini

Skill serupa