কম্পিউটার টিউটোরিয়াল

CSS-এ ফ্লেক্স আইটেমের প্রাথমিক দৈর্ঘ্য সেট করা

ফ্লেক্স আইটেমের দৈর্ঘ্য সেট করতে CSS flex-basis প্রোপার্টি ব্যবহার করুন।

উদাহরণ

<!DOCTYPE html> <html>    <head>       <style>          .mycontainer {             display: flex;             background-color: orange;          }          .mycontainer > div {             background-color: white;             text-align: center;             line-height: 40px;             font-size: 25px;             width: 100px;             margin: 5px;          }       </style>    </head>    <body>       <h1>কুইজ</h1>       <div class = "mycontainer">          <div>Q1</div>          <div>Q2</div>          <div>Q3</div>          <div style = "flex-basis: 350px">Q4</div>          <div>Q5</div>          <div>Q6</div>          <div>Q7</div>          <div>Q8</div>          <div>Q9</div>       </div>    </body> </html>
  1. CSS-এ কন্টেইনারের শেষে ফ্লেক্স আইটেম অ্যালাইন করা

  2. CSS-এ কন্টেইনারের শুরুতে ফ্লেক্স আইটেম অ্যালাইন করা

  3. CSS flex-direction: row দিয়ে ফ্লেক্স আইটেম হরিজেন্টাল সেট করা

  4. CSS-এ ফ্লেক্স লাইনগুলোকে কন্টেইনারের শুরুতে প্রদর্শন করুন