Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

137
Views
how align rows using Grid?

As you con see in the follow img, I'm trying to align "Nª de ticket" and "Email", using Grid:

My Result IMG

<Grid
        container
        direction="row"
        justifyContent="flex-start"
        alignItems="stretch"
        style={{ padding: "1.5em" }}
      >
        <div>
          <span>ID</span>
          <p style={{ color: "gray" }}>{props._id}</p>
        </div>
        <div>
          <span>N° de ticket</span>
          <p style={{ color: "gray" }}>{props._id}</p>
        </div>
      </Grid>

      <Grid
        container
        direction="row"
        justifyContent="space-between"
        alignItems="center"
        style={{ padding: "1.5em" }}
      >
        <div>
          <span>Fecha de nacimiento</span>
          <p style={{ color: "gray" }}>{props.birthdate}</p>
        </div>
        <div>
          <span>Email</span>
          <p style={{ color: "gray" }}>{props.email}</p>
        </div>
        <div>
          <span>Teléfono</span>
          <p style={{ color: "gray" }}>{props.phone}</p>
        </div>
      </Grid>

How can I align the both rows ?

about 4 years ago · Juan Pablo Isaza
2 answers
Answer question

0

Try to go for Syntax;

<!DOCTYPE html>
<html>

<head>
  <style>
    .grid-container {
      display: grid;
      grid-template-columns: auto auto auto;
      background-color: #2196F3;
      padding: 10px;
    }
    
    .grid-item {
      background-color: rgba(255, 255, 255, 0.8);
      padding: 20px;
      font-size: 30px;
      text-align: center;
    }
  </style>
</head>

<body>

  <h1>Grid</h1>
  <div class="grid-container">
    <div class="grid-item">1</div>
    <div class="grid-item">2</div>
    <div class="grid-item">3</div>
    <div class="grid-item">4</div>
    <div class="grid-item">5</div>
    <div class="grid-item">6</div>
    <div class="grid-item">7</div>
    <div class="grid-item">8</div>
    <div class="grid-item">9</div>
  </div>

</body>

</html>

about 4 years ago · Juan Pablo Isaza Report

0

The grid layout is a way of styling your html content with CSS similar to flexbox.
So, to achieve your desired goal, you should add a container (e.g. a <div>-element) and add the needed styling to the CSS.
DYNAMICMORTAL provided you with a complimentary example that might be of help as well!

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!