XSmall | Small | Medium | Large | Extra Large | XXL | |
---|---|---|---|---|---|---|
Class prefix | .col- |
.col-sm- |
.col-md- |
.col-lg- |
.col-xl- |
.col-xxl- |
Screen width | <576px | >=576px | >=768px | >=992px | >=1200px | >=1400px |
:ﻢﯾﺩﺍﺩ ﺎﻬﻧﺁ ﻪﺑ ﺪﺻﺭﺩ 33/66 ﻢﯿﺴﻘﺗ ﮒﺭﺰﺑ ﯼﺎﻫﻩﺎﮕﺘﺳﺩ ﺭﺩ ﻭ ﺪﺻﺭﺩ 50/50 ﻢﯿﺴﻘﺗ ﻂﺳﻮﺘ
<div class="col-sm-3 col-md-6 col-lg-4">....</div>
<div class="col-sm-9 col-md-6 col-lg-8">....</div>
.ﺪﺷﺎﺑ ﺮﺘﻬﺑ ﺪﺻﺭﺩ 20/80 ﻢﯿﺴﻘﺗ ﺕﺭﻮﺻ ﻪﺑ ﺖﺳﺍ ﻦﮑﻤﻣ ﯽﺣﺍﺮﻃ ،xlarge ﯼﺎﻫﻩﺎﮕﺘﺳﺩ ﺭﺩ ﺎ
.ﺪﻧﻮﺷﯽﻣ ﻒﯾﺮﻌﺗ ﺮﺗﻻﺎﺑ ﻭ ﻞﺴﮑﯿﭘ1200> ﺯﺍ ﺶﯾﺎﻤﻧ ﻪﺤﻔﺻ ﺽﺮﻋ ﯼﺍﺭﺍﺩ
:ﻢﯿﻨﮐﯽﻣ ﻩﺩﺎﻔﺘﺳﺍ .col-xl-*
ﯼﺎﻫﺱﻼﮐ ﺯﺍ
<div class="col-sm-3 col-md-6 col-lg-4 col-xl-2">....</div>
<div class="col-sm-9 col-md-6 col-lg-8 col-xl-10">....</div>
:ﺩﺮﯿﮔ ﯽﻣ ﺭﺍﺮﻗ ﻢﻫ ﯼﻭﺭ (٪100) ﺭﺎﮐﺩﻮﺧ ﺭﻮﻃ ﻪﺑ ،ﮏﭼﻮﮐ ﺭﺎﯿﺴﺑ ﯼﺎﻫ ﻩﺎﮕﺘﺳﺩ ﺭﺩ ﺎﻫ ﻩﺎﮕﺘﺳﺩ
<div class="container-fluid">
<div class="row">
<div class="col-sm-3 col-md-6 col-lg-4 col-xl-2">
<p>Lorem ipsum...</p>
</div>
<div class="col-sm-9 col-md-6 col-lg-8 col-xl-10">
<p>Sed ut perspiciatis...</p>
</div>
</div>
</div>
→ ﺪﯿﻨﮐ ﻥﺎﺤﺘﻣﺍ ﺍﺭ ﻥﺁ ﻥﺎﺗﺩﻮﺧ
<!DOCTYPE html>
<html lang="en">
<head>
<title>Bootstrap Example</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/css/bootstrap.min.css" rel="stylesheet">
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/js/bootstrap.bundle.min.js"></script>
</head>
<body>
<div class="container-fluid mt-3">
<h1>XLarge Grid</h1>
<p>The following example will result in a 25%/75% split on small devices, a 50%/50% split on medium devices, a 33%/66% split on large devices and a 20%/80% on xlarge and xxlarge devices. On extra small devices, it will automatically stack (100%).</p>
<p>Resize the browser window to see the effect.</p>
<div class="container-fluid">
<div class="row">
<div class="col-sm-3 col-md-6 col-lg-4 col-xl-2 bg-primary text-white">
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
</div>
<div class="col-sm-9 col-md-6 col-lg-8 col-xl-10 bg-dark text-white">
Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo.
</div>
</div>
</div>
</div>
</body>
</html>
ﻪﺟﻮﺗ: ﺪﺳﺭ ﯽﻣ 12 ﻪﺑ ﻪﺸﯿﻤﻫ ﻉﻮﻤﺠﻣ ﻪﮐ ﺪﯾﻮﺷ ﻦﺌﻤﻄﻣ.
:ﺩﺮﯿﮔ ﯽﻣ ﺭﺍﺮﻗ (٪100 ﺽﺮﻋ) ﯼﺩﻮﻤﻋ ﺕﺭﻮﺻ ﻪﺑ ،ﮏﭼﻮﮐ ﺭﺎﯿﺴﺑ ﻭ ﮏﭼﻮﮐ ،ﻂﺳﻮﺘﻣ ،ﮒﺭﺰﺑ ﯼﺎﻫ ﻩﺎﮕ
<div class="container-fluid">
<div class="row">
<div class="col-xl-6">
<p>Lorem ipsum...</p>
</div>
<div class="col-xl-6">
<p>Sed ut perspiciatis...</p>
</div>
</div>
</div>
→ ﺪﯿﻨﮐ ﻥﺎﺤﺘﻣﺍ ﺍﺭ ﻥﺁ ﻥﺎﺗﺩﻮﺧ
<!DOCTYPE html>
<html lang="en">
<head>
<title>Bootstrap Example</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/css/bootstrap.min.css" rel="stylesheet">
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/js/bootstrap.bundle.min.js"></script>
</head>
<body>
<div class="container-fluid mt-3">
<h1>XLarge Grid</h1>
<p>The following example will result in a 50%/50% split on xlarge devices (<strong>1200px and above</strong>). On large, medium, small and extra small devices, it will automatically stack (100%).</p>
<p>Resize the browser window to see the effect.</p>
<div class="container-fluid">
<div class="row">
<div class="col-xl-6 bg-primary text-white">
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.<br>
Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
</div>
<div class="col-xl-6 bg-dark text-white">
Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo.
</div>
</div>
</div>
</div>
</body>
</html>
.ﺖﺷﺍﺩ ﺪﻫﺍﻮﺧ ﺍﺭ ﺽﺮﻋ ﻥﺎﻤﻫ ﻥﻮﺘﺳ ﺮﻫ ﻭ ﺪﻫﺩ ﯽﻣ ﺺﯿﺨﺸﺗ ﺍﺭ ﺩﻮﺟﻮﻣ ﯼﺎﻫ ﻥﻮﺘﺳ ﺩﺍﺪﻌﺗ ﭖﺮﺘﺳﺍ ﺕ
:ﺪﻧﺮﯿﮔ ﯽﻣ ﺭﺍﺮﻗ ﻢﻫ ﯼﻭﺭ ﯽﻘﻓﺍ ﺕﺭﻮﺻ ﻪﺑ ﺎﻫ ﻥﻮﺘﺳ ،ﺪﺷﺎﺑ ﻞﺴﮑﯿﭘ 1200 ﺯﺍ ﺮﺘﻤﮐ → ﺪﯿﻨﮐ ﻥﺎﺤﺘﻣﺍ ﺍﺭ ﻥﺁ ﻥﺎﺗﺩﻮﺧ
<!-- Two columns: 50% width on xlarge and up-->
<div class="row">
<div class="col-xl">1 of 2</div>
<div class="col-xl">2 of 2</div>
</div>
<!-- Four columns: 25% width on xlarge and up -->
<div class="row">
<div class="col-xl">1 of 4</div>
<div class="col-xl">2 of 4</div>
<div class="col-xl">3 of 4</div>
<div class="col-xl">4 of 4</div>
</div>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Bootstrap Example</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/css/bootstrap.min.css" rel="stylesheet">
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/js/bootstrap.bundle.min.js"></script>
</head>
<body>
<div class="container-fluid mt-3">
<h1>Responsive Auto Layout Columns</h1>
<p>In Bootstrap 5, there is an easy way to create equal width columns: just use the <code>.col-xl</code> class on a specified number of col elements. Bootstrap will recognize how many columns there are, and each column will get the same width.</p>
<p>If the screen size is <strong>less than 1200px</strong>, the columns will stack horizontally.</p>
<div class="container-fluid">
<div class="row">
<div class="col-xl bg-primary text-white">1 of 2</div>
<div class="col-xl bg-dark text-white">2 of 2</div>
</div>
</div>
<br>
<div class="container-fluid">
<div class="row">
<div class="col-xl bg-primary text-white">1 of 4</div>
<div class="col-xl bg-dark text-white">2 of 4</div>
<div class="col-xl bg-primary text-white">3 of 4</div>
<div class="col-xl bg-dark text-white">4 of 4</div>
</div>
</div>
</div>
</body>
</html>