تصاویر

استایل ها متفاوت تصاویر و متون

مشاهده در سایت بوت استرپ

اشکال تصویر

Square image
Rounded image
Circle image
<!-- Square image (default) -->
<img src="path-to-image" alt="Square image">

<!-- Rounded image -->
<img src="path-to-image" class="rounded-3" alt="Rounded image">

<!-- Circle image -->
<img src="path-to-image" class="rounded-circle" alt="Circle image">
// Square image (default)
img(src="path-to-image", alt="Square image")

// Rounded image
img(src="path-to-image", alt="Rounded image").rounded-3

// Circle image
img(src="path-to-image", alt="Circle image").rounded-circle

تصاویر کوچک (Thumbnails)

Square thumbnail
Rounded thumbnail
Circle thumbnail
<!-- Square thumbnail -->
<img src="path-to-image" class="img-thumbnail rounded-0" alt="Square image">

<!-- Rounded thumbnail -->
<img src="path-to-image" class="img-thumbnail" alt="Rounded image">

<!-- Circle thumbnail -->
<img src="path-to-image" class="img-thumbnail rounded-circle" alt="Circle image">
// Square tumbnail
img(src="path-to-image", alt="Square image").img-thumbnail.rounded-0

// Rounded tumbnail
img(src="path-to-image", alt="Rounded image").img-thumbnail

// Circle tumbnail
img(src="path-to-image", alt="Circle image").img-thumbnail.rounded-circle

تصاویر با عنوان

Figure with caption
عنوان سمت چپ
Figure with caption
عنوان وسط
Figure with caption
عنوان سمت راست
<!-- Caption on the left -->
<figure class="figure">
  <img src="path-to-image" class="figure-img" alt="...">
  <figcaption class="figure-caption">Caption on the left</figcaption>
</figure>

<!-- Caption in the center -->
<figure class="figure">
  <img src="path-to-image" class="figure-img" alt="...">
  <figcaption class="figure-caption text-center">Caption in the center</figcaption>
</figure>

<!-- Caption on the right -->
<figure class="figure">
  <img src="path-to-image" class="figure-img" alt="...">
  <figcaption class="figure-caption text-end">Caption on the right</figcaption>
</figure>
// Caption on the left
figure.figure
  img(src="path-to-image", alt="...").figure-img
  figcaption.figure-caption Caption on the left

// Caption in the center
figure.figure
  img(src="path-to-image", alt="...").figure-img
  figcaption.figure-caption.text-center Caption in the center

// Caption on the right
figure.figure
  img(src="path-to-image", alt="...").figure-img
  figcaption.figure-caption.text-end Caption on the right

تعویض تصویر با هاور کردن

LogoLogoLogoLogo
<!-- Image swap on hover -->
<a href="#" class="swap-image">
  <img src="path-to-image" class="swap-to" width="196" alt="Alt text">
  <img src="path-to-image" class="swap-from" width="196" alt="Alt text">
</a>
// Image swap on hover
a(href="#").swap-image
  img(src="path-to-image", alt="Alt text", width="196").swap-to
  img(src="path-to-image", alt="Alt text", width="196").swap-from
بالا