Skip to content

Commit 10a6ebb

Browse files
Fix the overflow style for "Hide all checks" (#27932)
Fix #27928 --------- Co-authored-by: silverwind <[email protected]>
1 parent e80f446 commit 10a6ebb

File tree

3 files changed

+13
-6
lines changed

3 files changed

+13
-6
lines changed

web_src/css/modules/tippy.css

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@
6060

6161
.tippy-box[data-theme="box-with-header"] .tippy-content {
6262
background: var(--color-box-body);
63+
border-radius: var(--border-radius);
6364
padding: 0;
6465
}
6566

web_src/css/repo.css

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

30773077
.commit-status-header {
3078-
border: none !important; /* reset the default ".ui.attached.header" styles, to use the outer border */
3079-
margin: 0 !important;
3078+
/* reset the default ".ui.attached.header" styles, to use the outer border */
3079+
border: none !important;
3080+
/* add a bottom border to make sure the there is always a divider between the header and list when the list is scrolling */
3081+
border-bottom: 1px solid var(--color-secondary) !important;
3082+
/* use negative margin to avoid the newly added border conflict with the list's top border */
3083+
margin: 0 0 -1px !important;
30803084
}
30813085

30823086
.commit-status-list {
3083-
max-height: 195px; /* fit exactly 4 items */
3087+
max-height: 240px; /* fit exactly 6 items, commit-status-item.height * 6 */
30843088
overflow-x: hidden;
30853089
transition: max-height .2s;
30863090
}
30873091

30883092
.commit-status-item {
3089-
padding: 14px 10px !important;
3093+
height: 40px;
3094+
padding: 0 10px;
30903095
display: flex;
30913096
gap: 8px;
30923097
align-items: center;
3098+
}
3099+
3100+
.commit-status-item + .commit-status-item {
30933101
border-top: 1px solid var(--color-secondary);
30943102
}
30953103

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

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,7 @@ export function initRepoPullRequestCommitStatus() {
44
const list = panel.querySelector('.commit-status-list');
55
btn.addEventListener('click', () => {
66
list.style.maxHeight = list.style.maxHeight ? '' : '0px'; // toggle
7-
list.style.overflow = 'hidden'; // hide scrollbar when hiding
87
btn.textContent = btn.getAttribute(list.style.maxHeight ? 'data-show-all' : 'data-hide-all');
98
});
10-
list.addEventListener('animationend', () => list.style.overflow = '');
119
}
1210
}

0 commit comments

Comments
 (0)