Skip to content
Snippets Groups Projects
Commit 9abb2b29 authored by Sascha Eggenberger's avatar Sascha Eggenberger
Browse files

Issue #3323501: Table sticky-header width causing overlap

parent 47dd6523
No related branches found
No related tags found
1 merge request!225Issue #3323501: Table sticky-header width causing overlap
Pipeline #9762 passed
......@@ -1382,16 +1382,6 @@ table.sticky-header::before, table.sticky-header::after {
background: var(--gin-bg-layer);
}
@media (min-width: 61em) {
.gin--vertical-toolbar table.sticky-header {
width: calc(100% - min(10vw, 96px) - var(--gin-spacing-xxl) - 2px - var(--gin-toolbar-width-collapsed)) !important;
}
.gin--vertical-toolbar[data-toolbar-menu=open] table.sticky-header {
width: calc(100% - min(10vw, 96px) - var(--gin-spacing-xxl) - 2px - var(--gin-toolbar-width)) !important;
}
}
table thead {
background: transparent;
border-radius: var(--gin-border-m);
......
......@@ -67,6 +67,7 @@
const header = table.querySelector(':scope > thead');
header.querySelectorAll('th').forEach((el, i) => {
table.querySelector(`table.sticky-header > thead th:nth-of-type(${i+1})`).style.width = `${el.offsetWidth}px`;
table.querySelector(`table.sticky-header`).style.width = `${el.parentNode.offsetWidth}px`;
});
},
};
......
......@@ -48,16 +48,6 @@ table.sticky-header {
background: var(--gin-bg-layer);
}
}
@include mq(medium) {
.gin--vertical-toolbar & {
width: calc(100% - min(10vw, 96px) - var(--gin-spacing-xxl) - 2px - var(--gin-toolbar-width-collapsed)) !important;
}
.gin--vertical-toolbar[data-toolbar-menu='open'] & {
width: calc(100% - min(10vw, 96px) - var(--gin-spacing-xxl) - 2px - var(--gin-toolbar-width)) !important;
}
}
}
table {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment