Figuras
Documentación y ejemplos para mostrar imágenes y texto relacionados con el componente figure en Bootstrap.
On this page
Siempre que necesites mostrar un fragmento de contenido—como una imagen con un pie de foto
opcional, considera usar un <figure>.
Usa las clases incluidas .figure, .figure-img y
.figure-caption para proporcionar algunos estilos base para los elementos
<figure> y <figcaption> de HTML5. Las imágenes en las figuras no tienen
un tamaño explícito, así que asegúrate de agregar la clase .img-fluid a tu
<img> para hacerla responsive.
<figure class="figure">
<img src="..." class="figure-img img-fluid rounded" alt="...">
<figcaption class="figure-caption">A caption for the above image.</figcaption>
</figure>
Alinear el pie de figura es fácil con nuestras utilidades de texto.
<figure class="figure">
<img src="..." class="figure-img img-fluid rounded" alt="...">
<figcaption class="figure-caption text-end">A caption for the above image.</figcaption>
</figure>
CSS
Variables Sass
$figure-caption-font-size: $small-font-size;
$figure-caption-color: var(--#{$prefix}secondary-color);