Merge pull request #10925 from overleaf/jel-vertical-align-css

[web] Better vertically align content in CMS pages

GitOrigin-RevId: 276cd3f4566bfbbc5a79b91d5f1567ae4d618280
This commit is contained in:
Jessica Lawshe 2022-12-19 09:36:35 -06:00 committed by Copybot
parent 18cfeaf030
commit 77c0802035

View file

@ -140,6 +140,9 @@
.quote-by-position { .quote-by-position {
color: @content-secondary; color: @content-secondary;
} }
.quote-picture-and-person {
display: flex;
}
} }
/* /*
@ -343,6 +346,31 @@
} }
.vertically-center-col { .vertically-center-col {
// remove margin to better vertically align
// some elements need to be nested within a container, and others are directly within .no-card/.card
.card:first-child,
.no-card:first-child {
.cms-element-container {
> *:first-child {
margin-top: 0;
}
}
> *:first-child:not(.cms-element-container) {
margin-top: 0;
}
}
.card:last-child,
.no-card:last-child {
.cms-element-container {
> *:last-child {
margin-bottom: 0;
}
}
> *:last-child:not(.cms-element-container) {
margin-bottom: 0;
}
}
@media (min-width: @screen-sm-min) { @media (min-width: @screen-sm-min) {
display: flex; display: flex;