style(frontend): enforce declaration-block-single-line-max-declarations in scss

- Stylelint:
  - re-enable declaration-block-single-line-max-declarations in the frontend Stylelint config
  - keep the rule change isolated to a formatting-only commit for easier rollback if needed
- Chart styles:
  - expand compressed declaration blocks in the stats chart styles into multi-line blocks
  - reformat the book flow empty-state styles without changing selectors or declarations
- Layout styles:
  - expand the topbar animation keyframe blocks and bulk ISBN status styles to satisfy the single-line declaration limit
- Validation:
  - run just ui stylelint
This commit is contained in:
James Cox
2026-04-22 17:26:46 -04:00
committed by Zach Yale
parent df12acd7fb
commit 32765de84c
7 changed files with 399 additions and 83 deletions
@@ -489,9 +489,19 @@
white-space: nowrap; white-space: nowrap;
font-size: 0.8rem; font-size: 0.8rem;
.status-created & { color: var(--text-color); } .status-created & {
.status-created-no-metadata & { color: var(--p-yellow-500); font-style: italic; } color: var(--text-color);
.status-failed & { color: var(--p-red-500); font-style: italic; } }
.status-created-no-metadata & {
color: var(--p-yellow-500);
font-style: italic;
}
.status-failed & {
color: var(--p-red-500);
font-style: italic;
}
} }
.validation-message { .validation-message {
@@ -77,7 +77,10 @@
position: relative; position: relative;
width: 100%; width: 100%;
height: 500px; height: 500px;
canvas { display: block; }
canvas {
display: block;
}
} }
.no-data-message { .no-data-message {
@@ -88,9 +91,23 @@
padding: 3rem; padding: 3rem;
text-align: center; text-align: center;
color: var(--text-secondary-color); color: var(--text-secondary-color);
i { font-size: 2.5rem; margin-bottom: 1rem; opacity: 0.5; }
p { font-size: 1rem; margin: 0 0 0.5rem; color: var(--text-color, #fff); } i {
small { font-size: 0.85rem; opacity: 0.7; } font-size: 2.5rem;
margin-bottom: 1rem;
opacity: 0.5;
}
p {
font-size: 1rem;
margin: 0 0 0.5rem;
color: var(--text-color, #fff);
}
small {
font-size: 0.85rem;
opacity: 0.7;
}
} }
@media (width <= 768px) { @media (width <= 768px) {
@@ -1,39 +1,126 @@
.publication-era-container { width: 100%; } .publication-era-container {
width: 100%;
}
.chart-header { .chart-header {
display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 0.5rem; display: flex;
justify-content: space-between;
align-items: flex-start;
margin-bottom: 0.5rem;
.chart-title { .chart-title {
flex: 1; flex: 1;
h3 { color: var(--text-color, #fff); font-size: 1.25rem; font-weight: 500; margin: 0 0 0.5rem; display: flex; align-items: center; gap: 0.5rem; }
.chart-description { color: var(--text-secondary-color); font-size: 0.9rem; margin: 0; line-height: 1.4; } h3 {
display: flex;
gap: 0.5rem;
align-items: center;
margin: 0 0 0.5rem;
color: var(--text-color, #fff);
font-size: 1.25rem;
font-weight: 500;
}
.chart-description {
margin: 0;
color: var(--text-secondary-color);
font-size: 0.9rem;
line-height: 1.4;
}
} }
} }
.publication-era-icon { font-size: 1.5rem; color: #673ab7; }
.publication-era-icon {
color: #673ab7;
font-size: 1.5rem;
}
.stats-row { .stats-row {
display: flex; gap: 0.75rem; margin-bottom: 1rem; flex-wrap: wrap; display: flex;
gap: 0.75rem;
flex-wrap: wrap;
margin-bottom: 1rem;
.stat-card { .stat-card {
display: flex; flex-direction: column; align-items: center; display: flex;
background: rgb(255 255 255 / 5%); border: 1px solid rgb(255 255 255 / 10%); flex: 1;
border-radius: 8px; padding: 0.5rem 1rem; flex: 1; min-width: 80px; flex-direction: column;
.stat-value { font-size: 1.5rem; font-weight: 600; color: var(--text-color, #fff); } align-items: center;
.stat-label { font-size: 0.75rem; color: var(--text-secondary-color); text-transform: uppercase; letter-spacing: 0.5px; margin-top: 0.25rem; } min-width: 80px;
&.best .stat-value { color: #673ab7; } padding: 0.5rem 1rem;
&.avg .stat-value { color: #ffc107; } border: 1px solid rgb(255 255 255 / 10%);
&.total .stat-value { color: #42a5f5; } border-radius: 8px;
background: rgb(255 255 255 / 5%);
.stat-value {
color: var(--text-color, #fff);
font-size: 1.5rem;
font-weight: 600;
}
.stat-label {
margin-top: 0.25rem;
color: var(--text-secondary-color);
font-size: 0.75rem;
letter-spacing: 0.5px;
text-transform: uppercase;
}
&.best .stat-value {
color: #673ab7;
}
&.avg .stat-value {
color: #ffc107;
}
&.total .stat-value {
color: #42a5f5;
}
} }
} }
.chart-wrapper { position: relative; height: 350px; width: 100%; }
.no-data-message { .chart-wrapper {
display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 3rem; text-align: center; color: var(--text-secondary-color); position: relative;
i { font-size: 2.5rem; margin-bottom: 1rem; opacity: 0.5; } width: 100%;
p { font-size: 1rem; margin: 0 0 0.5rem; color: var(--text-color, #fff); } height: 350px;
small { font-size: 0.85rem; opacity: 0.7; }
} }
@media (width <= 768px) { .chart-wrapper { height: 280px; } } .no-data-message {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
padding: 3rem;
color: var(--text-secondary-color);
text-align: center;
@media (width <= 480px) { .chart-header .chart-title h3 { font-size: 1rem; } } i {
margin-bottom: 1rem;
opacity: 0.5;
font-size: 2.5rem;
}
p {
margin: 0 0 0.5rem;
color: var(--text-color, #fff);
font-size: 1rem;
}
small {
opacity: 0.7;
font-size: 0.85rem;
}
}
@media (width <= 768px) {
.chart-wrapper {
height: 280px;
}
}
@media (width <= 480px) {
.chart-header .chart-title h3 {
font-size: 1rem;
}
}
@@ -1,38 +1,122 @@
.reading-debt-container { width: 100%; } .reading-debt-container {
width: 100%;
}
.chart-header { .chart-header {
display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 0.5rem; display: flex;
justify-content: space-between;
align-items: flex-start;
margin-bottom: 0.5rem;
.chart-title { .chart-title {
flex: 1; flex: 1;
h3 { color: var(--text-color, #fff); font-size: 1.25rem; font-weight: 500; margin: 0 0 0.5rem; display: flex; align-items: center; gap: 0.5rem; }
.chart-description { color: var(--text-secondary-color); font-size: 0.9rem; margin: 0; line-height: 1.4; } h3 {
display: flex;
gap: 0.5rem;
align-items: center;
margin: 0 0 0.5rem;
color: var(--text-color, #fff);
font-size: 1.25rem;
font-weight: 500;
}
.chart-description {
margin: 0;
color: var(--text-secondary-color);
font-size: 0.9rem;
line-height: 1.4;
}
} }
} }
.reading-debt-icon { font-size: 1.5rem; color: #ef5350; }
.reading-debt-icon {
color: #ef5350;
font-size: 1.5rem;
}
.stats-row { .stats-row {
display: flex; gap: 0.75rem; margin-bottom: 1rem; flex-wrap: wrap; display: flex;
gap: 0.75rem;
flex-wrap: wrap;
margin-bottom: 1rem;
.stat-card { .stat-card {
display: flex; flex-direction: column; align-items: center; display: flex;
background: rgb(255 255 255 / 5%); border: 1px solid rgb(255 255 255 / 10%); flex: 1;
border-radius: 8px; padding: 0.5rem 1rem; flex: 1; min-width: 80px; flex-direction: column;
.stat-value { font-size: 1.5rem; font-weight: 600; color: var(--text-color, #fff); } align-items: center;
.stat-label { font-size: 0.75rem; color: var(--text-secondary-color); text-transform: uppercase; letter-spacing: 0.5px; margin-top: 0.25rem; } min-width: 80px;
&.backlog .stat-value { color: #ffc107; } padding: 0.5rem 1rem;
&.trend .stat-value { color: #42a5f5; } border: 1px solid rgb(255 255 255 / 10%);
border-radius: 8px;
background: rgb(255 255 255 / 5%);
.stat-value {
color: var(--text-color, #fff);
font-size: 1.5rem;
font-weight: 600;
}
.stat-label {
margin-top: 0.25rem;
color: var(--text-secondary-color);
font-size: 0.75rem;
letter-spacing: 0.5px;
text-transform: uppercase;
}
&.backlog .stat-value {
color: #ffc107;
}
&.trend .stat-value {
color: #42a5f5;
}
} }
} }
.chart-wrapper { position: relative; height: 350px; width: 100%; }
.no-data-message { .chart-wrapper {
display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 3rem; text-align: center; color: var(--text-secondary-color); position: relative;
i { font-size: 2.5rem; margin-bottom: 1rem; opacity: 0.5; } width: 100%;
p { font-size: 1rem; margin: 0 0 0.5rem; color: var(--text-color, #fff); } height: 350px;
small { font-size: 0.85rem; opacity: 0.7; }
} }
@media (width <= 768px) { .chart-wrapper { height: 280px; } } .no-data-message {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
padding: 3rem;
color: var(--text-secondary-color);
text-align: center;
@media (width <= 480px) { .chart-header .chart-title h3 { font-size: 1rem; } } i {
margin-bottom: 1rem;
opacity: 0.5;
font-size: 2.5rem;
}
p {
margin: 0 0 0.5rem;
color: var(--text-color, #fff);
font-size: 1rem;
}
small {
opacity: 0.7;
font-size: 0.85rem;
}
}
@media (width <= 768px) {
.chart-wrapper {
height: 280px;
}
}
@media (width <= 480px) {
.chart-header .chart-title h3 {
font-size: 1rem;
}
}
@@ -1,50 +1,151 @@
.session-archetypes-container { width: 100%; } .session-archetypes-container {
width: 100%;
}
.chart-header { .chart-header {
display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 0.5rem; display: flex;
justify-content: space-between;
align-items: flex-start;
margin-bottom: 0.5rem;
.chart-title { .chart-title {
flex: 1; flex: 1;
h3 { color: var(--text-color, #fff); font-size: 1.25rem; font-weight: 500; margin: 0 0 0.5rem; display: flex; align-items: center; gap: 0.5rem; }
.chart-description { color: var(--text-secondary-color); font-size: 0.9rem; margin: 0; line-height: 1.4; } h3 {
display: flex;
gap: 0.5rem;
align-items: center;
margin: 0 0 0.5rem;
color: var(--text-color, #fff);
font-size: 1.25rem;
font-weight: 500;
}
.chart-description {
margin: 0;
color: var(--text-secondary-color);
font-size: 0.9rem;
line-height: 1.4;
}
} }
.year-nav { .year-nav {
display: flex; align-items: center; gap: 0.5rem; display: flex;
gap: 0.5rem;
align-items: center;
.nav-btn { .nav-btn {
background: rgb(255 255 255 / 10%); border: 1px solid rgb(255 255 255 / 20%); padding: 0.3rem 0.5rem;
border-radius: 6px; color: var(--text-color, #fff); padding: 0.3rem 0.5rem; border: 1px solid rgb(255 255 255 / 20%);
cursor: pointer; transition: background 0.2s; border-radius: 6px;
&:hover { background: rgb(255 255 255 / 20%); } background: rgb(255 255 255 / 10%);
color: var(--text-color, #fff);
cursor: pointer;
transition: background 0.2s;
&:hover {
background: rgb(255 255 255 / 20%);
}
}
.year-label {
min-width: 50px;
color: var(--text-color, #fff);
font-size: 1.1rem;
font-weight: 600;
text-align: center;
} }
.year-label { color: var(--text-color, #fff); font-weight: 600; font-size: 1.1rem; min-width: 50px; text-align: center; }
} }
} }
.session-archetypes-icon { font-size: 1.5rem; color: #ff9800; }
.session-archetypes-icon {
color: #ff9800;
font-size: 1.5rem;
}
.stats-row { .stats-row {
display: flex; gap: 0.75rem; margin-bottom: 1rem; flex-wrap: wrap; display: flex;
gap: 0.75rem;
flex-wrap: wrap;
margin-bottom: 1rem;
.stat-card { .stat-card {
display: flex; flex-direction: column; align-items: center; display: flex;
background: rgb(255 255 255 / 5%); border: 1px solid rgb(255 255 255 / 10%); flex: 1;
border-radius: 8px; padding: 0.5rem 1rem; flex: 1; min-width: 80px; flex-direction: column;
.stat-value { font-size: 1.5rem; font-weight: 600; color: var(--text-color, #fff); } align-items: center;
.stat-label { font-size: 0.75rem; color: var(--text-secondary-color); text-transform: uppercase; letter-spacing: 0.5px; margin-top: 0.25rem; } min-width: 80px;
&.sessions .stat-value { color: #ff9800; } padding: 0.5rem 1rem;
&.archetype .stat-value { color: #42a5f5; font-size: 1.1rem; } border: 1px solid rgb(255 255 255 / 10%);
border-radius: 8px;
background: rgb(255 255 255 / 5%);
.stat-value {
color: var(--text-color, #fff);
font-size: 1.5rem;
font-weight: 600;
}
.stat-label {
margin-top: 0.25rem;
color: var(--text-secondary-color);
font-size: 0.75rem;
letter-spacing: 0.5px;
text-transform: uppercase;
}
&.sessions .stat-value {
color: #ff9800;
}
&.archetype .stat-value {
color: #42a5f5;
font-size: 1.1rem;
}
} }
} }
.chart-wrapper { position: relative; height: 350px; width: 100%; }
.no-data-message { .chart-wrapper {
display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 3rem; text-align: center; color: var(--text-secondary-color); position: relative;
i { font-size: 2.5rem; margin-bottom: 1rem; opacity: 0.5; } width: 100%;
p { font-size: 1rem; margin: 0 0 0.5rem; color: var(--text-color, #fff); } height: 350px;
small { font-size: 0.85rem; opacity: 0.7; }
} }
@media (width <= 768px) { .chart-wrapper { height: 280px; } } .no-data-message {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
padding: 3rem;
color: var(--text-secondary-color);
text-align: center;
@media (width <= 480px) { .chart-header .chart-title h3 { font-size: 1rem; } } i {
margin-bottom: 1rem;
opacity: 0.5;
font-size: 2.5rem;
}
p {
margin: 0 0 0.5rem;
color: var(--text-color, #fff);
font-size: 1rem;
}
small {
opacity: 0.7;
font-size: 0.85rem;
}
}
@media (width <= 768px) {
.chart-wrapper {
height: 280px;
}
}
@media (width <= 480px) {
.chart-header .chart-title h3 {
font-size: 1rem;
}
}
@@ -197,8 +197,15 @@
} }
@keyframes ripple-burst { @keyframes ripple-burst {
0% { transform: scale(0.8); opacity: 0.6; } 0% {
100% { transform: scale(2.2); opacity: 0; } transform: scale(0.8);
opacity: 0.6;
}
100% {
transform: scale(2.2);
opacity: 0;
}
} }
@keyframes heart-float { @keyframes heart-float {
@@ -215,9 +222,20 @@
} }
@keyframes pulsate { @keyframes pulsate {
0% { transform: scale(1); opacity: 1; } 0% {
50% { transform: scale(1.25); opacity: 0.8; } transform: scale(1);
100% { transform: scale(1); opacity: 1; } opacity: 1;
}
50% {
transform: scale(1.25);
opacity: 0.8;
}
100% {
transform: scale(1);
opacity: 1;
}
} }
.pulsating { .pulsating {
-1
View File
@@ -2,7 +2,6 @@ module.exports = {
extends: ["stylelint-config-standard-scss"], extends: ["stylelint-config-standard-scss"],
ignoreFiles: ["dist/**", "node_modules/**"], ignoreFiles: ["dist/**", "node_modules/**"],
rules: { rules: {
"declaration-block-single-line-max-declarations": null,
"keyframes-name-pattern": null, "keyframes-name-pattern": null,
"no-descending-specificity": null, "no-descending-specificity": null,
"no-invalid-position-declaration": null, "no-invalid-position-declaration": null,