figure-figcaption
O que ela faz
Esta skill verifica se as legendas de imagens de uma página estão marcadas corretamente. É para desenvolvedores e editores que publicam conteúdo com imagens.
Quando usar
- ✓Quando uma imagem da sua página tem uma legenda escrita em um parágrafo comum.
- ✓Quando você publica artigos com fotos, gráficos ou diagramas.
- ✓Quando suas legendas de imagem precisam ser lidas corretamente por ferramentas assistivas.
Link da skill
https://github.com/thedaviddias/Front-End-Checklist/blob/main/skills/figure-figcaption/SKILL.mdCopie e cole na sua IA (Claude, ChatGPT ou Cursor) pedindo para seguir as instruções.
Como usar
O jeito mais fácil: copie a mensagem e cole na sua IA. Ela lê a skill e segue as instruções.
Mensagem pronta para colar
Para Claude Code, Codex ou Cursor: rode na pasta do projeto e a skill fica instalada.
Baixe o SKILL.md e coloque na pasta de skills do seu agente.
Exemplo do que pedir para a IA
“Você pode estruturar corretamente as fotos e legendas do meu artigo?”
5 skills novas por semana. 1 minuto de leitura.
Como funciona
O agente encontra imagens com texto colocado logo ao lado e envolve cada par em um elemento figure com um figcaption. Ele também verifica se o texto alternativo não é uma cópia exata da legenda.
Conteúdo técnico (SKILL.md original)
Texto original do autor, em inglês, direto do GitHub.
Use <figure> and <figcaption> for image captions
Using a <p> tag as a caption is invisible to assistive technology as an image description. The <figure>/<figcaption> pattern creates a machine-readable relationship between an image and its caption, which screen readers surface to users. It also communicates to search engines that the caption describes the image, supporting image SEO.
Quick Reference
- Wrap image + visible caption pairs in
<figure>with<figcaption>as a direct child <figcaption>must be the first or last child of<figure>- Do not duplicate alt text in figcaption—alt is the fallback, figcaption is the visible description
<figure>is appropriate for images, code blocks, diagrams, and charts—not every image
Check
Scan the codebase for images with adjacent visible text that acts as a caption (e.g., a <p> or <span> immediately below an <img> describing it). Verify: 1) Such image-caption pairs are wrapped in <figure>. 2) The caption text is inside a <figcaption> element. 3) <figcaption> is a direct child of <figure>. 4) The alt text on the <img> is not identical to the <figcaption> text—they serve different purposes. Flag any <img> followed by descriptive text that is not structured as figure/figcaption.
Fix
For each image with an adjacent caption: 1) Wrap the <img> and its caption text in a <figure> element. 2) Move the caption text into a <figcaption> element inside <figure>. 3) Review the <img> alt attribute—if the figcaption already fully describes the image for sighted users, the alt can be shorter or empty (alt="") only if the figcaption alone is sufficient for screen readers too; otherwise keep a concise alt. 4) Position <figcaption> as the first or last child of <figure>. Show the corrected HTML.
Explain
Explain the semantic meaning of <figure> and <figcaption>. The <figure> element represents self-contained content (an image, code sample, diagram) that is referenced from the main content but could be moved without affecting the document flow. <figcaption> provides a caption or legend for the figure. Screen readers announce the figcaption in association with the figure, giving users context. Without this markup, sighted users see a caption but screen reader users hear only the alt text with no indication that a visible caption exists.
Code Review
Review image assets, markup, and delivery configuration related to Use <figure> and <figcaption> for image captions. Flag exact files or components where format choice, sizing, or loading behavior violates the rule, and describe how to confirm the fix in DevTools.
For full implementation details, code examples, and framework-specific guidance,
see references/rule.md.
Rule page: https://frontendchecklist.io/rules/images/figure-figcaption
Perguntas frequentes
O que é um figcaption?
É o elemento HTML para uma legenda, colocado dentro de um elemento figure junto com a sua imagem.
O texto alternativo deve ser igual à legenda?
Não. A skill diz que o texto alternativo é uma descrição de reserva e a legenda é o texto visível, então eles devem ser diferentes.
Toda imagem precisa de um figure?
Não. A skill diz que figure serve para conteúdos como imagens, blocos de código, diagramas e gráficos, e não para toda foto.
Detalhes
Descrição original do autor
Use when reviewing image assets, markup, and CDN or build transforms related to Use <figure> and <figcaption> for image captions. Check encoded size, rendered size, loading strategy, and above-the-fold impact together.
Popularidade
- Estrelas no GitHub
- 75 mil
- Posição no ranking
- #2843
- Licença
- MIT
- Atualizada em
- 31/10/2026
Comentários
- …
Mais skills deste repositório
frontendchecklist
75 milVerifica código front-end e páginas no ar contra mais de 380 regras de acessibilidade, velocidade, SEO e segurança, usando uma ferramenta de linha de comando.
frontend-checklist-global
75 milAudita um projeto front-end contra todas as 386 regras do Front-End Checklist e dá uma correção específica para cada problema encontrado.
404-page
75 milVerifica se a sua página de conteúdo não encontrado oferece links úteis e retorna um status 404 real, para ajudar visitantes perdidos a encontrar o caminho.
about-page
75 milRevisa se o seu site tem uma página Sobre clara que explica quem está por trás dele, para criar confiança em visitantes e buscadores.
Skills parecidas
angular-developer
280 milAjuda seu agente a criar código Angular e a dar conselhos sobre a estrutura do projeto. É útil para iniciar novos projetos, criar partes do código ou melhorar a performance e acessibilidade.
frontend-a11y
280 milAjuda seu agente a tornar interfaces web acessíveis para todos. Ele garante que sites e apps funcionem bem com leitores de tela e navegação por teclado.
frontend-patterns
280 milFaz seu agente aplicar padrões modernos no desenvolvimento frontend. Ele otimiza performance, gerencia estado e segue boas práticas em React e Next.js.