0

I'm trying to align vertically a div inside another div using flex boxes. This code is working on Chrome, IE Edge, Opera and Firefox:

.editing-viewport {
  display: flex;
  display: -webkit-flex;
  flex-direction: column;
  -ms-flex-direction: column;
  align-items: center;
  justify-content: center;
  -webkit-justify-content: center;
  -webkit-box-align: center;
  -webkit-flex-align: center;
  -webkit-align-items: center;
  -webkit-box-sizing: border-box;
}

But on Safari, the div inside the editing-viewport div does not look completely centred on the Y axis. Looks like there are some extra pixels above the div.

enter image description here enter image description here

Michael Benjamin
  • 307,417
  • 93
  • 525
  • 644
andresscode
  • 1,145
  • 1
  • 9
  • 21

0 Answers0