Skip to content

Commit

Permalink
remove table-layout: fixed from repo files table
Browse files Browse the repository at this point in the history
  • Loading branch information
silverwind committed Apr 9, 2024
1 parent d3c71ae commit 9f47323
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 23 deletions.
14 changes: 14 additions & 0 deletions web_src/css/base.css
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,22 @@
--tab-size: 4;
--checkbox-size: 15px; /* height and width of checkbox and radio inputs */
--page-spacing: 16px; /* space between page elements */
--page-margin-x: 32px; /* minimum space on left and right side of page */
}

@media (min-width: 768px) and (max-width: 1200px) {
:root {
--page-margin-x: 16px;
}
}

@media (max-width: 767.98px) {
:root {
--page-margin-x: 8px;
}
}


:root * {
--fonts-regular: var(--fonts-override, var(--fonts-proportional)), "Noto Sans", "Liberation Sans", sans-serif, var(--fonts-emoji);
}
Expand Down
23 changes: 2 additions & 21 deletions web_src/css/modules/container.css
Original file line number Diff line number Diff line change
Expand Up @@ -49,30 +49,11 @@
/* overwrite width of containers inside the main page content div (div with class "page-content") */
.page-content .ui.ui.ui.container:not(.fluid) {
width: 1280px;
max-width: calc(100% - 64px);
max-width: calc(100% - calc(2 * var(--page-margin-x)));
margin-left: auto;
margin-right: auto;
}

.ui.container.fluid.padded {
padding: 0 32px;
}

/* enable fluid page widths for medium size viewports */
@media (min-width: 768px) and (max-width: 1200px) {
.page-content .ui.ui.ui.container:not(.fluid) {
max-width: calc(100% - 32px);
}
.ui.container.fluid.padded {
padding: 0 16px;
}
}

@media (max-width: 767.98px) {
.page-content .ui.ui.ui.container:not(.fluid) {
max-width: calc(100% - 16px);
}
.ui.container.fluid.padded {
padding: 0 8px;
}
padding: 0 var(--page-margin-x);
}
5 changes: 3 additions & 2 deletions web_src/css/repo.css
Original file line number Diff line number Diff line change
Expand Up @@ -212,8 +212,9 @@ td .commit-summary {
overflow-wrap: anywhere;
}

.repository.file.list #repo-files-table {
table-layout: fixed;
/* this is what limits the commit table width to a value that works on all viewport sizes */
#repo-files-table th:first-of-type {
max-width: calc(calc(min(100vw, 1280px)) - 145px - calc(2 * var(--page-margin-x)));
}

.repository.file.list #repo-files-table thead th {
Expand Down

0 comments on commit 9f47323

Please sign in to comment.