video-thumbnail
Fungsinya
Skill ini menambahkan gambar thumbnail poster ke pemutar video di halaman web. Skill ini ditujukan untuk pemilik situs dan pengembang yang ingin video terlihat rapi dan tidak menggeser tata letak saat dimuat.
Kapan dipakai
- βSaat sebuah video tampil sebagai kotak hitam kosong sebelum diputar.
- βSaat elemen video tidak memiliki atribut poster.
- βSaat tata letak halaman bergeser saat video dimuat.
Link skill
https://github.com/thedaviddias/Front-End-Checklist/blob/main/skills/video-thumbnail/SKILL.mdSalin 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
Untuk Claude Code, Codex, atau Cursor: jalankan di folder proyek, lalu skill langsung terpasang.
Unduh SKILL.md lalu taruh di folder skill agen Anda.
Contoh permintaan ke AI
βVideo saya tampil sebagai kotak hitam sampai seseorang menekan putar. Bisakah Anda menambahkan thumbnail yang menunjukkan isi setiap video?β
5 skill baru setiap minggu. 1 menit baca.
Cara kerjanya
Agent menambahkan atribut poster dengan gambar thumbnail yang sesuai dengan proporsi video. Agent juga mengatur ukuran video agar tata letak tidak melompat saat gambar dimuat.
Konten teknis (SKILL.md asli)
Teks asli dari pembuat, dalam bahasa Inggris, langsung dari GitHub.
Add thumbnail images to videos
Without a poster image, a <video> element displays as a blank black rectangle until the first frame is loaded. This is visually jarring, provides no context about the video content, and can cause layout shift (CLS) if the video dimensions are not specified separately. A good thumbnail image communicates the video topic at a glance, allows users to decide whether to play, and improves the page's visual quality β especially on slow connections where video preloading is delayed.
Quick Reference
- Add a
posterattribute to<video>elements with a URL to a representative thumbnail image - The poster image displays before the video loads and while the user decides whether to play
- Poster images improve perceived performance by showing meaningful content before video data arrives
- The poster should accurately represent the video content β deceptive thumbnails violate user trust
- Use an image ratio matching the video's aspect ratio (typically 16:9) and a resolution of at least 1280Γ720
Check
Find all <video> elements. For each, check that: (1) a poster attribute is present with a non-empty URL; (2) the URL resolves to a valid image (no 404s); (3) the width and height attributes or CSS dimensions are set to prevent layout shift while the poster loads; (4) the poster image accurately represents the video content (not a clickbait or unrelated image).
Fix
(1) Add a poster attribute to each <video> element: <video poster='thumbnail.jpg' controls>. (2) Use an image that represents the video content β typically a frame from the video, a title card, or a branded thumbnail. (3) Ensure the poster image has the same aspect ratio as the video (usually 16:9). (4) Recommended poster dimensions: 1280Γ720px minimum for HD video; 640Γ360px is acceptable for smaller embeds. (5) Host the poster image at a CDN-cached URL to ensure fast loading. (6) Also set width and height on the <video> element to prevent CLS.
Explain
The HTML poster attribute on <video> specifies a URL for an image to display before video playback begins. When preload='none' or preload='metadata' is set (recommended for performance β avoids downloading video data on page load), no video frame is available for display, making the poster image the only visual content visible to the user before play. Without a poster, users see either a black rectangle or a browser-rendered blank video frame, which provides no context. The poster also plays a role in perceived performance β users on slow connections see meaningful content immediately rather than waiting for even the first video frame to load.
Code Review
Review templates, server-rendered HTML, and shared components that output markup related to Add thumbnail images to videos. Flag exact elements, attributes, and routes where the rendered HTML violates the rule.
For full implementation details, code examples, and framework-specific guidance,
see references/rule.md.
Rule page: https://frontendchecklist.io/rules/html/video-thumbnail
Pertanyaan umum
Seberapa besar ukuran thumbnail?
Skill menyarankan gambar 16:9 dengan ukuran minimal 1280 x 720 piksel, agar sesuai dengan bentuk video.
Bisakah thumbnail menyesatkan?
Skill menyatakan poster harus menampilkan isi video dengan akurat, karena thumbnail yang menyesatkan merusak kepercayaan.
Apakah poster menggantikan keterangan?
Tidak. Skill menyatakan poster adalah bantuan desain dan performa, terpisah dari keterangan atau deskripsi audio.
Detail
Deskripsi asli dari pembuat
Use when applies to all `<video>` elements in HTML. The `poster` attribute specifies the URL of an image to show as a placeholder before the video is loaded or played. This is distinct from captions or audio descriptions, which are accessibility requirements. The poster is primarily a UX and performance enhancement, though the lack of a poster can indirectly create a CLS (Cumulative Layout Shift) issue if video dimensions are not declared.
Popularitas
- Bintang GitHub
- 75k
- Peringkat
- #3075
- Lisensi
- MIT
- Diperbarui
- 31/10/2026
Komentar
- β¦
Skill lain dari repositori ini
frontendchecklist
75kMemeriksa kode frontend dan halaman langsung terhadap lebih dari 380 aturan untuk aksesibilitas, kecepatan, SEO, dan keamanan, dengan alat baris perintah.
frontend-checklist-global
75kMengaudit proyek frontend terhadap seluruh 386 aturan Front-End Checklist, dan memberikan perbaikan spesifik untuk setiap masalah yang ditemukan.
404-page
75kMemeriksa bahwa halaman tidak ditemukan Anda menawarkan tautan yang membantu dan mengembalikan status 404 yang sebenarnya, untuk membantu pengunjung yang tersesat.
about-page
75kMeninjau apakah situs Anda memiliki halaman Tentang yang jelas yang menjelaskan siapa yang mengelolanya, untuk membangun kepercayaan pengunjung dan mesin pencari.
Skill serupa
angular-developer
280kMembantu agent Anda membuat kode Angular dan memberi saran struktur proyek. Berguna saat memulai proyek baru, membuat komponen, atau meningkatkan performa.
frontend-a11y
280kMembantu agent Anda membuat antarmuka web dapat diakses semua orang. Memastikan website dan aplikasi berfungsi baik dengan screen reader dan navigasi keyboard.
frontend-patterns
280kMembuat agent Anda menerapkan pola modern dalam frontend. Mengoptimalkan performa, mengelola state, dan mengikuti praktik terbaik React dan Next.js.