Skip to content

Commit e75b654

Browse files
committed
fix
1 parent 1e8a1e0 commit e75b654

File tree

2 files changed

+4
-21
lines changed

2 files changed

+4
-21
lines changed

web_src/css/repo.css

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3075,27 +3075,22 @@ tbody.commit-list {
30753075
}
30763076

30773077
.commit-status-header {
3078-
/* reset the default ".ui.attached.header" styles, to use the outer border */
3079-
border-top: none !important;
3080-
border-left: none !important;
3081-
border-right: none !important;
3078+
border: none !important; /* reset the default ".ui.attached.header" styles, to use the outer border */
30823079
margin: 0 !important;
30833080
}
30843081

30853082
.commit-status-list {
3086-
max-height: 233px; /* fit exactly 6 items */
3083+
max-height: 240px; /* fit exactly 6 items, commit-status-item.height * 6 */
30873084
overflow-x: hidden;
30883085
transition: max-height .2s;
30893086
}
30903087

30913088
.commit-status-item {
3092-
padding: 9px 10px !important;
3089+
height: 40px;
3090+
padding: 0 10px;
30933091
display: flex;
30943092
gap: 8px;
30953093
align-items: center;
3096-
}
3097-
3098-
.commit-status-item + .commit-status-item {
30993094
border-top: 1px solid var(--color-secondary);
31003095
}
31013096

web_src/js/features/repo-issue-pr-status.js

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2,21 +2,9 @@ export function initRepoPullRequestCommitStatus() {
22
for (const btn of document.querySelectorAll('.commit-status-hide-checks')) {
33
const panel = btn.closest('.commit-status-panel');
44
const list = panel.querySelector('.commit-status-list');
5-
const header = panel.querySelector('.commit-status-header');
6-
let hasScrollBar = false;
75
btn.addEventListener('click', () => {
8-
if (!hasScrollBar && !list.style.overflow) {
9-
hasScrollBar = list.scrollHeight > list.clientHeight;
10-
}
11-
// hide the flickering scrollbar during transition if there was no scrollbar
12-
list.style.overflow = hasScrollBar ? '' : 'hidden';
136
list.style.maxHeight = list.style.maxHeight ? '' : '0px'; // toggle
14-
if (!list.style.maxHeight) header.style.borderBottom = '';
157
btn.textContent = btn.getAttribute(list.style.maxHeight ? 'data-show-all' : 'data-hide-all');
168
});
17-
list.addEventListener('transitionend', () => {
18-
list.style.overflow = '';
19-
header.style.borderBottom = list.style.maxHeight ? 'none' : '';
20-
});
219
}
2210
}

0 commit comments

Comments
 (0)