forgejo/web_src/css/repo/commit-list.css

84 lines
1.6 KiB
CSS

/* Copyright 2025 The Forgejo Authors. All rights reserved.
* SPDX-License-Identifier: GPL-3.0-or-later */
/* Modern layout for templates/repo/pulls/commits_list.tmpl using responsive grid */
.commit-group {
margin-bottom: 1rem;
h4 {
font-weight: var(--font-weight-semibold);
}
.commits {
background: var(--color-box-body);
}
.commits .commit {
display: grid;
padding: 0.5rem;
gap: 0.5rem;
grid-template-columns: minmax(8ch, 15%) 1fr minmax(20ch, 1%) minmax(12ch, 10%) auto;
align-items: center;
}
.commits .commit .sha.label {
/* Unwanted property of .sha.label, needs fix upstream in hashbox.css */
margin-inline: 0 !important;
}
}
@media (max-width: 440px) {
.commit-group .commits .commit .mobile-shabox .badge {
/* Hide signature badge (lock icon) on narrow layout */
display: none;
}
}
@media (min-width: 640px) {
.commit-group .commits .commit .mobile-shabox {
/* Hide the button in desktop view, only accessible in mobile view */
display: none;
}
}
@media (max-width: 639.9px) {
.commit-group .commits .commit {
grid-template-columns: 1fr 1fr;
.author {
grid-row: 1;
grid-column: 1;
}
.date {
grid-row: 1;
grid-column: 2;
}
.message {
grid-row: 2;
grid-column: 1 / span 2;
}
.mobile-shabox {
grid-column: 1 / -1;
display: flex;
justify-content: space-between;
}
.shabox {
display: none;
}
details.dropdown {
grid-row: 3;
grid-column: 2;
justify-self: right;
}
.commit-buttons {
display: none;
}
}
}