সিএসএস
🌈সিএসএস কি?
📋সিএসএস হলো অবস্থান নির্দিষ্ট করার পদ্ধতি।
⚒️সিএসএস অবস্থান নির্দিষ্ট করতে ব্যবহৃত হয়।
সিএসএস সমূহ
সিএসএস এবং সেগুলোর ব্যবহারের তালিকা
- ➡️ place-content - বিষয়বস্তুর অবস্থানের বৈশিষ্ট্য নির্ধারণ করা
- ➡️ place-items - আইটেমগুলোর অবস্থানের বৈশিষ্ট্য নির্ধারণ করা
- ➡️ place-self - আইটেমের নিজস্ব অবস্থান নির্ধারণ করা
place-content - বিষয়বস্তুর অবস্থানের বৈশিষ্ট্য নির্ধারণ করার উদাহরণ।
css
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<style>
.container {
height: 180px;
width: 180px;
border: solid black 1px;
display: grid;
grid-template-columns: repeat(3, 40px);
grid-template-rows: repeat(2, 40px);
gap: 2px;
}
.container > div {
background-color: coral;
}
.start {
place-content: start;
}
.center {
place-content: center;
}
.end {
place-content: end;
}
</style>
</head>
<body>
<div class="container start">
<div></div>
<div></div>
<div></div>
<div></div>
</div>
<br>
<div class="container center">
<div></div>
<div></div>
<div></div>
<div></div>
</div>
<br>
<div class="container end">
<div></div>
<div></div>
<div></div>
<div></div>
</div>
</body>
</html>
place-items - আইটেমগুলোর অবস্থানের বৈশিষ্ট্য নির্ধারণ করার উদাহরণ।
css
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<style>
.container {
height: 180px;
width: 180px;
border: solid black 1px;
display: grid;
grid-template-columns: repeat(3, 50px);
grid-template-rows: repeat(2, 50px);
place-items: center;
}
.container > div {
height: 30px;
width: 30px;
background-color: coral;
}
</style>
</head>
<body>
<div class="container">
<div></div>
<div></div>
<div></div>
<div></div>
</div>
</body>
</html>
place-self - আইটেমের নিজস্ব অবস্থান নির্ধারণ করার উদাহরণ।
css
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<style>
.container {
height: 180px;
width: 180px;
border: solid black 1px;
display: grid;
grid-template-columns: repeat(3, 50px);
grid-template-rows: repeat(2, 50px);
place-items: start;
}
.container > div {
height: 30px;
width: 30px;
background-color: coral;
}
.special {
place-self: end;
}
</style>
</head>
<body>
<div class="container">
<div></div>
<div></div>
<div class="special"></div>
<div></div>
</div>
</body>
</html>
সিএসএস সম্পর্কিত বিস্তারিত তথ্য
কার্যকর কোডিং উদাহরণ এবং সেগুলোর রেফারেন্স লিংক
| নাম | বিবরণ |
|---|---|
| place-content | বিষয়বস্তুর অবস্থানের বৈশিষ্ট্য নির্ধারণ করতে ব্যবহৃত হয়। |
| place-items | আইটেমগুলোর অবস্থানের বৈশিষ্ট্য নির্ধারণ করতে ব্যবহৃত হয়। |
| place-self | আইটেমের নিজস্ব অবস্থান নির্ধারণ করতে ব্যবহৃত হয়। |