How to get submit form to stretch across the screen

How to get submit form to stretch across the screen
0

#1

Here’s a link to my codepen: https://codepen.io/harry-dhillon/pen/KrJBNZ?editors=1100

I’m trying to get the submit button to stretch across the screen at 100% like the message element above it. When I go to add width to 100%, it’s not stretching across.

How can I make that happen?


#2
.contact form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-gap: 20px;
}

Okay so you have table (grid) of two columns. Your button is in once column. It can’t extend across two.

You need to: remove your button from the grid OR give it a new row that only has one column.


#3

Just add the .full class you already have to the parent p element of the button (you don’t need it on the button).

<p class="full">
  <button>Submit</button>
</p>

#4

awesome, thanks so much!