Commit 29493285 authored by Paul Slaughter's avatar Paul Slaughter

Replace minmax with setting min-width

- This addresses [this issue][1].
- `minmax` is set at the parent level which we were
only applying sometimes and is easy to overlook. It
seemed that we were coupling the parents to knowing
about certain children contents. What if we just set
the problematic child's `min-width`?

[1]: https://gitlab.com/gitlab-org/gitlab/-/issues/296222
parent d1c29ca5
...@@ -588,6 +588,12 @@ table.code { ...@@ -588,6 +588,12 @@ table.code {
// Merge request diff grid layout // Merge request diff grid layout
.diff-grid { .diff-grid {
.diff-td {
// By default min-width is auto with 1fr which causes some overflow problems
// https://gitlab.com/gitlab-org/gitlab/-/issues/296222
min-width: 0;
}
.diff-grid-row { .diff-grid-row {
display: grid; display: grid;
grid-template-columns: 1fr 1fr; grid-template-columns: 1fr 1fr;
...@@ -601,27 +607,27 @@ table.code { ...@@ -601,27 +607,27 @@ table.code {
.diff-grid-comments { .diff-grid-comments {
display: grid; display: grid;
grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); grid-template-columns: 1fr 1fr;
} }
.diff-grid-drafts { .diff-grid-drafts {
display: grid; display: grid;
grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); grid-template-columns: 1fr 1fr;
} }
&.inline { &.inline {
.diff-grid-comments { .diff-grid-comments {
display: grid; display: grid;
grid-template-columns: minmax(0, 1fr); grid-template-columns: 1fr;
} }
.diff-grid-drafts { .diff-grid-drafts {
display: grid; display: grid;
grid-template-columns: minmax(0, 1fr); grid-template-columns: 1fr;
} }
.diff-grid-row { .diff-grid-row {
grid-template-columns: minmax(0, 1fr); grid-template-columns: 1fr;
} }
.diff-grid-left, .diff-grid-left,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment