MacBook Pro 16"
€2,499
Haz que el contenido visual sea comprensible para todos los usuarios
€2,499
<!-- ❌ Malo: textos alt no descriptivos -->
<img src="laptop.jpg" alt="image" />
<img src="star-icon.svg" alt="star.png" />
<img src="success-icon.svg" alt="success.svg" />€2,499
<!-- ✅ Bueno: textos alt descriptivos -->
<img src="laptop.jpg"
alt="MacBook Pro 16 pouces, vue de face,
écran ouvert montrant l'interface macOS" />
<!-- Icono decorativo: alt vacío, .sr-only para contexto -->
<img src="star-icon.svg" alt="" />
<span>
<span class="sr-only">Note de </span>4.8/5
<span class="sr-only"> étoiles</span> (127 avis)
</span>
<!-- Icono decorativo en notificación -->
<img src="success-icon.svg" alt="" />
<span>Commande confirmée !</span>Explicación: El texto alternativo permite a los lectores de pantalla describir imágenes. Deben ser descriptivos para imágenes informativas, vacíos para imágenes decorativas.
<!-- ❌ Malo: video con reproducción automática -->
<video width="100%" height="200" autoplay loop muted>
<source src="demo.mp4" type="video/mp4">
Votre navigateur ne supporte pas la vidéo.
</video><!-- ✅ Bueno: video accesible con subtítulos y controles -->
<video width="100%" height="200"
controls
preload="metadata"
aria-describedby="video-description">
<source src="demo.mp4" type="video/mp4">
<!-- Subtítulos para personas con problemas de audición -->
<track kind="captions"
src="captions.vtt"
srclang="fr"
label="Français"
default>
<!-- Descripciones de audio para personas con discapacidad visual -->
<track kind="descriptions"
src="descriptions.vtt"
srclang="fr"
label="Description audio">
<!-- Alternativa con enlace a transcripción -->
Votre navigateur ne supporte pas la vidéo.
<a href="transcript.html">Consulter la transcription</a>
</video>
<div id="video-description">
Vidéo de 2 minutes présentant les fonctionnalités du MacBook Pro.
Sous-titres en français disponibles.
</div>Explicación: Los videos deben tener subtítulos, controles accesibles con teclado y no reproducirse automáticamente.
<!-- ❌ Malo: gráfico sin descripción o datos alternativos -->
<svg width="300" height="150" viewBox="0 0 300 150">
<rect
x="50"
y="100"
width="40"
height="40"
fill="#3b82f6"
/>
<rect
x="110"
y="80"
width="40"
height="60"
fill="#3b82f6"
/>
<rect
x="170"
y="60"
width="40"
height="80"
fill="#3b82f6"
/>
<rect
x="230"
y="40"
width="40"
height="100"
fill="#3b82f6"
/>
</svg>| Trimestre | Ventas (k€) | Evolución |
|---|---|---|
| T1 2025 | 40 | - |
| T2 2025 | 60 | +50% |
| T3 2025 | 80 | +33% |
| T4 2025 | 100 | +25% |
<!-- ✅ Bueno: gráfico accesible con datos alternativos -->
<svg width="300" height="150"
role="img"
aria-labelledby="chart-title"
aria-describedby="chart-desc">
<title id="chart-title">Graphique en barres des ventes trimestrielles</title>
<desc id="chart-desc">
Évolution croissante des ventes sur 4 trimestres :
Q1: 40k€, Q2: 60k€, Q3: 80k€, Q4: 100k€
</desc>
<!-- Barras del gráfico -->
<rect
x="50"
y="100"
width="40"
height="40"
fill="#3b82f6"
/>
<rect
x="110"
y="80"
width="40"
height="60"
fill="#3b82f6"
/>
<rect
x="170"
y="60"
width="40"
height="80"
fill="#3b82f6"
/>
<rect
x="230"
y="40"
width="40"
height="100"
fill="#3b82f6"
/>
<!-- Etiquetas accesibles -->
<text x="70" y="130">Q1</text>
<text x="130" y="130">Q2</text>
<text x="190" y="130">Q3</text>
<text x="250" y="130">Q4</text>
</svg>
<!-- Tabla alternativa con todos los datos -->
<table>
<caption>Données détaillées des ventes trimestrielles</caption>
<thead>
<tr>
<th scope="col">Trimestre</th>
<th scope="col">Ventes (k€)</th>
<th scope="col">Évolution</th>
</tr>
</thead>
<tbody>
<tr>
<th scope="row">Q1 2025</th>
<td>40</td>
<td>-</td>
</tr>
<!-- ... otras filas -->
</tbody>
</table>Explicación: Los gráficos deben estar acompañados de descripciones textuales y datos alternativos para usuarios que no pueden verlos.