Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
4.8k views
in Technique[技术] by (71.8m points)

html - how to delete a empty second row for css grid

enter image description here

Hi guys, I'm trying to delete a row. I have attached a picture what I have right now. I only want 1 row and 3 column

display: grid;
grid - template - rows: auto;
grid - template - columns: 1 fr 1 fr 1 fr;
<div class="list-loan-info" ng-scrollbar rebuild-on="rebuild:me">
  <div automationid="FieldName" class="field-name" style="float:left;"> fieldName </div>
  <div automationid="OldValue" class="old-value">oldValue &nbsp;</div>
  <div automationid="NewValue" class="new-value-true">newValue</div>
  <div automationid="NewValue" class="new-value-false">newValue</div>
  <br />
</div>

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

add a grid template rows to your code


    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    grid-template-rows: 1fr;


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...