Refactors page styles into separate CSS files

Extracts inline styles from Razor pages into modular CSS files
Adds new CSS files for components and specific page styles
Improves code organization and maintainability by separating styling concerns

Updates layout to include new CSS files and optional style sections
This commit is contained in:
Janus C. H. Knudsen 2026-02-03 15:55:44 +01:00
parent 77d35ff965
commit 08f8150064
12 changed files with 577 additions and 555 deletions

View file

@ -0,0 +1,152 @@
/* Forgejo Pages Styles */
/* Stat Bars (Repository Types) */
.stat-bars {
display: flex;
flex-direction: column;
gap: 8px;
}
.stat-bar-item {
display: flex;
align-items: center;
gap: 8px;
}
.stat-bar-label {
width: 70px;
font-size: 11px;
}
.stat-bar {
flex: 1;
height: 8px;
background: var(--border-color);
border-radius: 4px;
overflow: hidden;
}
.stat-bar-fill {
height: 100%;
border-radius: 4px;
}
.stat-bar-value {
width: 30px;
text-align: right;
font-size: 11px;
font-weight: bold;
}
/* CI Stats */
.ci-stats {
display: flex;
justify-content: space-around;
text-align: center;
}
.ci-stat-value {
font-size: 24px;
font-weight: bold;
}
.ci-stat-value.success { color: var(--success-color); }
.ci-stat-value.danger { color: var(--danger-color); }
.ci-stat-label {
font-size: 10px;
color: var(--muted-color);
text-transform: uppercase;
}
.ci-rate-bar {
height: 8px;
background: var(--danger-color);
border-radius: 4px;
overflow: hidden;
}
.ci-rate-success {
height: 100%;
background: var(--success-color);
}
.ci-rate-label {
text-align: center;
font-size: 10px;
color: var(--muted-color);
margin-top: 4px;
}
/* Failed Row */
.failed-row {
background: rgba(220, 53, 69, 0.05);
}
/* Filter Tabs */
.filter-tabs {
display: flex;
gap: 8px;
flex-wrap: wrap;
}
.filter-tab {
padding: 6px 12px;
border: 1px solid var(--border-color);
background: transparent;
font-family: inherit;
font-size: 11px;
cursor: pointer;
border-radius: var(--radius-sm);
transition: all 0.15s;
}
.filter-tab:hover {
background: var(--hover-bg);
}
.filter-tab.active {
background: var(--text-color);
color: var(--bg-color);
border-color: var(--text-color);
}
/* Repo Description */
.repo-desc {
font-size: 10px;
color: var(--muted-color);
margin-top: 2px;
}
/* Backup Detail */
.backup-detail {
font-size: 10px;
color: var(--muted-color);
margin-top: 2px;
}
/* Missing List */
.missing-list {
display: flex;
flex-wrap: wrap;
gap: 8px;
}
.missing-repo {
background: rgba(240, 165, 0, 0.1);
border: 1px solid var(--warning-color);
padding: 4px 8px;
border-radius: var(--radius-sm);
}
/* Repo Row */
.repo-row.hidden {
display: none;
}
/* Actions page - smaller rate bar */
@media (max-width: 1400px) {
.forgejo-actions .dashboard-grid {
grid-template-columns: 1fr;
}
}