style(frontend): enforce color-function-notation in scss

- Stylelint:
  - re-enable `color-function-notation` in the frontend Stylelint config while keeping the agreed Angular and legacy Sass exceptions unchanged
- SCSS:
  - normalize comma-based `rgb(...)` color syntax to modern space-and-slash notation across frontend stylesheets without changing color values
- Validation:
  - `just ui stylelint`
This commit is contained in:
James Cox
2026-04-22 17:26:43 -04:00
committed by Zach Yale
parent 130463bc4b
commit ddcbb5b666
121 changed files with 790 additions and 791 deletions
@@ -56,8 +56,8 @@
left: 0;
display: none;
border-radius: 50%;
border: 3px solid rgb(255, 255, 255, 80%);
box-shadow: 0 0 0 1px rgb(0, 0, 0, 30%), 0 8px 32px rgb(0, 0, 0, 50%);
border: 3px solid rgb(255 255 255 / 80%);
box-shadow: 0 0 0 1px rgb(0 0 0 / 30%), 0 8px 32px rgb(0 0 0 / 50%);
pointer-events: none;
z-index: 1000;
background-repeat: no-repeat;
@@ -69,7 +69,7 @@
right: 24px;
z-index: 10;
pointer-events: none;
filter: drop-shadow(0 2px 4px rgb(0, 0, 0, 30%));
filter: drop-shadow(0 2px 4px rgb(0 0 0 / 30%));
svg {
display: block;
@@ -168,7 +168,7 @@
.page-image {
object-fit: contain;
box-shadow: 0 8px 32px rgb(0, 0, 0, 60%);
box-shadow: 0 8px 32px rgb(0 0 0 / 60%);
border-radius: 4px;
transition: transform 0.2s ease;
@@ -327,7 +327,7 @@
}
.page-image {
box-shadow: 0 8px 32px rgb(0, 0, 0, 60%);
box-shadow: 0 8px 32px rgb(0 0 0 / 60%);
border-radius: 4px;
transition: none;
@@ -516,12 +516,12 @@
color: #ffffff;
cursor: pointer;
transition: all 0.3s ease;
box-shadow: 0 4px 20px rgb(74, 144, 226, 30%);
box-shadow: 0 4px 20px rgb(74 144 226 / 30%);
min-width: 280px;
&:hover {
transform: translateY(-2px);
box-shadow: 0 8px 30px rgb(74, 144, 226, 50%);
box-shadow: 0 8px 30px rgb(74 144 226 / 50%);
background: linear-gradient(135deg, #357abd 0%, #2a6399 100%);
}
@@ -582,7 +582,7 @@
.loader-overlay {
position: fixed;
inset: 0 0 0 0;
background-color: rgb(0, 0, 0, 80%);
background-color: rgb(0 0 0 / 80%);
display: flex;
align-items: center;
justify-content: center;
@@ -599,7 +599,7 @@
.spinner {
width: 48px;
height: 48px;
border: 4px solid rgb(255, 255, 255, 20%);
border: 4px solid rgb(255 255 255 / 20%);
border-top-color: #fff;
border-radius: 50%;
animation: spin 0.8s linear infinite;
@@ -1,19 +1,19 @@
// Variables matching reader styling
$dialog-bg: #1a1a1a;
$text-primary: rgb(255, 255, 255, 95%);
$text-secondary: rgb(255, 255, 255, 60%);
$text-muted: rgb(255, 255, 255, 40%);
$border-color: rgb(255, 255, 255, 8%);
$hover-bg: rgb(255, 255, 255, 8%);
$text-primary: rgb(255 255 255 / 95%);
$text-secondary: rgb(255 255 255 / 60%);
$text-muted: rgb(255 255 255 / 40%);
$border-color: rgb(255 255 255 / 8%);
$hover-bg: rgb(255 255 255 / 8%);
$active-color: #4a90e2;
$active-bg: rgb(74, 144, 226, 15%);
$active-bg: rgb(74 144 226 / 15%);
$transition-fast: 150ms ease;
$transition-normal: 200ms ease;
.dialog-overlay {
position: fixed;
inset: 0;
background: rgb(0, 0, 0, 50%);
background: rgb(0 0 0 / 50%);
backdrop-filter: blur(4px);
z-index: 13000;
display: flex;
@@ -37,7 +37,7 @@ $transition-normal: 200ms ease;
display: flex;
flex-direction: column;
overflow: hidden;
box-shadow: 0 20px 60px rgb(0, 0, 0, 50%);
box-shadow: 0 20px 60px rgb(0 0 0 / 50%);
animation: slideUp 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
@@ -58,7 +58,7 @@ $transition-normal: 200ms ease;
display: flex;
align-items: center;
justify-content: space-between;
background: linear-gradient(180deg, rgb(255, 255, 255, 2%) 0%, transparent 100%);
background: linear-gradient(180deg, rgb(255 255 255 / 2%) 0%, transparent 100%);
h2 {
margin: 0;
@@ -107,11 +107,11 @@ $transition-normal: 200ms ease;
}
&::-webkit-scrollbar-thumb {
background: rgb(255, 255, 255, 15%);
background: rgb(255 255 255 / 15%);
border-radius: 3px;
&:hover {
background: rgb(255, 255, 255, 25%);
background: rgb(255 255 255 / 25%);
}
}
}
@@ -130,7 +130,7 @@ $transition-normal: 200ms ease;
.page-info {
margin: 0;
padding: 12px 16px;
background: rgb(255, 255, 255, 3%);
background: rgb(255 255 255 / 3%);
border-left: 3px solid $active-color;
border-radius: 0 8px 8px 0;
color: $text-secondary;
@@ -149,7 +149,7 @@ $transition-normal: 200ms ease;
flex: 1;
min-height: 120px;
padding: 12px 16px;
background: rgb(255, 255, 255, 3%);
background: rgb(255 255 255 / 3%);
border: 1px solid $border-color;
border-radius: 8px;
color: $text-primary;
@@ -166,7 +166,7 @@ $transition-normal: 200ms ease;
&:focus {
outline: none;
border-color: $active-color;
box-shadow: 0 0 0 3px rgb(74, 144, 226, 15%);
box-shadow: 0 0 0 3px rgb(74 144 226 / 15%);
}
}
@@ -193,7 +193,7 @@ $transition-normal: 200ms ease;
&.selected {
border-color: $text-primary;
box-shadow: 0 0 0 3px rgb(255, 255, 255, 20%);
box-shadow: 0 0 0 3px rgb(255 255 255 / 20%);
&::after {
content: '\2713';
@@ -205,7 +205,7 @@ $transition-normal: 200ms ease;
color: white;
font-size: 14px;
font-weight: bold;
text-shadow: 0 1px 2px rgb(0, 0, 0, 50%);
text-shadow: 0 1px 2px rgb(0 0 0 / 50%);
}
}
}
@@ -216,7 +216,7 @@ $transition-normal: 200ms ease;
display: flex;
justify-content: flex-end;
gap: 12px;
background: linear-gradient(0deg, rgb(255, 255, 255, 2%) 0%, transparent 100%);
background: linear-gradient(0deg, rgb(255 255 255 / 2%) 0%, transparent 100%);
}
.btn {
@@ -244,7 +244,7 @@ $transition-normal: 200ms ease;
color: $text-primary;
&:hover:not(:disabled) {
background: rgb(255, 255, 255, 12%);
background: rgb(255 255 255 / 12%);
}
}
@@ -1,9 +1,9 @@
$dialog-bg: #1a1a1a;
$text-primary: rgb(255, 255, 255, 95%);
$text-secondary: rgb(255, 255, 255, 60%);
$text-muted: rgb(255, 255, 255, 40%);
$border-color: rgb(255, 255, 255, 8%);
$hover-bg: rgb(255, 255, 255, 8%);
$text-primary: rgb(255 255 255 / 95%);
$text-secondary: rgb(255 255 255 / 60%);
$text-muted: rgb(255 255 255 / 40%);
$border-color: rgb(255 255 255 / 8%);
$hover-bg: rgb(255 255 255 / 8%);
$active-color: #4a90e2;
$transition-fast: 150ms ease;
$transition-normal: 200ms ease;
@@ -11,7 +11,7 @@ $transition-normal: 200ms ease;
.dialog-overlay {
position: fixed;
inset: 0;
background: rgb(0, 0, 0, 50%);
background: rgb(0 0 0 / 50%);
backdrop-filter: blur(4px);
z-index: 13000;
display: flex;
@@ -35,7 +35,7 @@ $transition-normal: 200ms ease;
display: flex;
flex-direction: column;
overflow: hidden;
box-shadow: 0 20px 60px rgb(0, 0, 0, 50%);
box-shadow: 0 20px 60px rgb(0 0 0 / 50%);
animation: slideUp 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
@@ -56,7 +56,7 @@ $transition-normal: 200ms ease;
display: flex;
align-items: center;
justify-content: space-between;
background: linear-gradient(180deg, rgb(255, 255, 255, 2%) 0%, transparent 100%);
background: linear-gradient(180deg, rgb(255 255 255 / 2%) 0%, transparent 100%);
h2 {
margin: 0;
@@ -105,11 +105,11 @@ $transition-normal: 200ms ease;
}
&::-webkit-scrollbar-thumb {
background: rgb(255, 255, 255, 15%);
background: rgb(255 255 255 / 15%);
border-radius: 3px;
&:hover {
background: rgb(255, 255, 255, 25%);
background: rgb(255 255 255 / 25%);
}
}
}
@@ -137,12 +137,12 @@ $transition-normal: 200ms ease;
justify-content: space-between;
gap: 16px;
padding: 8px 12px;
background: rgb(255, 255, 255, 3%);
background: rgb(255 255 255 / 3%);
border-radius: 8px;
transition: background $transition-fast;
&:hover {
background: rgb(255, 255, 255, 5%);
background: rgb(255 255 255 / 5%);
}
}
@@ -160,14 +160,14 @@ $transition-normal: 200ms ease;
min-width: 28px;
height: 26px;
padding: 0 8px;
background: rgb(255, 255, 255, 10%);
border: 1px solid rgb(255, 255, 255, 15%);
background: rgb(255 255 255 / 10%);
border: 1px solid rgb(255 255 255 / 15%);
border-radius: 5px;
font-family: inherit;
font-size: 12px;
font-weight: 500;
color: $text-primary;
box-shadow: 0 2px 0 rgb(0, 0, 0, 20%);
box-shadow: 0 2px 0 rgb(0 0 0 / 20%);
}
.key-separator {
@@ -200,7 +200,7 @@ $transition-normal: 200ms ease;
border-top: 1px solid $border-color;
display: flex;
justify-content: flex-end;
background: linear-gradient(0deg, rgb(255, 255, 255, 2%) 0%, transparent 100%);
background: linear-gradient(0deg, rgb(255 255 255 / 2%) 0%, transparent 100%);
}
.btn {
@@ -2,11 +2,11 @@
// Variables
$footer-bg: #1a1a1a;
$text-primary: rgb(255, 255, 255, 95%);
$text-secondary: rgb(255, 255, 255, 60%);
$text-muted: rgb(255, 255, 255, 40%);
$border-color: rgb(255, 255, 255, 8%);
$hover-bg: rgb(255, 255, 255, 8%);
$text-primary: rgb(255 255 255 / 95%);
$text-secondary: rgb(255 255 255 / 60%);
$text-muted: rgb(255 255 255 / 40%);
$border-color: rgb(255 255 255 / 8%);
$hover-bg: rgb(255 255 255 / 8%);
$active-color: #4a90e2;
$transition-fast: 150ms ease;
@@ -24,7 +24,7 @@ $transition-fast: 150ms ease;
z-index: 1000;
background: linear-gradient(135deg, #2d2d2d 0%, #1f1f1f 100%);
border-top: 1px solid #404040;
box-shadow: 0 -2px 8px rgb(0, 0, 0, 30%);
box-shadow: 0 -2px 8px rgb(0 0 0 / 30%);
color: $text-primary;
transform: translateY(100%);
opacity: 0;
@@ -59,7 +59,7 @@ $transition-fast: 150ms ease;
}
.nav-btn {
background: rgb(51, 51, 51, 90%);
background: rgb(51 51 51 / 90%);
border: 1px solid #555;
color: $text-primary;
padding: 6px 10px;
@@ -110,7 +110,7 @@ $transition-fast: 150ms ease;
.page-info {
padding: 4px 12px;
background: rgb(255, 255, 255, 10%);
background: rgb(255 255 255 / 10%);
border-radius: 4px;
font-size: 13px;
font-weight: 500;
@@ -160,7 +160,7 @@ $transition-fast: 150ms ease;
&::-webkit-slider-runnable-track {
width: 100%;
height: 6px;
background: rgb(255, 255, 255, 12%);
background: rgb(255 255 255 / 12%);
border-radius: 3px;
cursor: pointer;
}
@@ -168,14 +168,14 @@ $transition-fast: 150ms ease;
&::-moz-range-track {
width: 100%;
height: 6px;
background: rgb(255, 255, 255, 12%);
background: rgb(255 255 255 / 12%);
border-radius: 3px;
cursor: pointer;
}
&::-ms-fill-lower,
&::-ms-fill-upper {
background: rgb(255, 255, 255, 12%);
background: rgb(255 255 255 / 12%);
border-radius: 3px;
}
@@ -188,7 +188,7 @@ $transition-fast: 150ms ease;
border-radius: 50%;
background: $active-color;
cursor: pointer;
box-shadow: 0 2px 6px rgb(0, 0, 0, 30%);
box-shadow: 0 2px 6px rgb(0 0 0 / 30%);
transition: transform $transition-fast, box-shadow $transition-fast;
margin-top: calc((6px - 18px) / 2); /* center thumb on track */
}
@@ -200,7 +200,7 @@ $transition-fast: 150ms ease;
background: $active-color;
cursor: pointer;
border: none;
box-shadow: 0 2px 6px rgb(0, 0, 0, 30%);
box-shadow: 0 2px 6px rgb(0 0 0 / 30%);
transition: transform $transition-fast, box-shadow $transition-fast;
margin-top: calc((6px - 18px) / 2);
}
@@ -212,7 +212,7 @@ $transition-fast: 150ms ease;
background: $active-color;
cursor: pointer;
border: none;
box-shadow: 0 2px 6px rgb(0, 0, 0, 30%);
box-shadow: 0 2px 6px rgb(0 0 0 / 30%);
}
}
@@ -241,7 +241,7 @@ $transition-fast: 150ms ease;
transform: translateX(-50%);
width: 2px;
height: 10px;
background: rgb(255, 255, 255, 50%);
background: rgb(255 255 255 / 50%);
top: 0;
}
}
@@ -252,7 +252,7 @@ $transition-fast: 150ms ease;
display: flex;
align-items: center;
gap: 4px;
background: rgb(51, 51, 51, 90%);
background: rgb(51 51 51 / 90%);
border-radius: 4px;
padding: 2px;
border: 1px solid #555;
@@ -271,7 +271,7 @@ $transition-fast: 150ms ease;
&:focus {
outline: none;
background: #4a4a4a;
box-shadow: 0 0 0 1px rgb(74, 144, 226, 50%);
box-shadow: 0 0 0 1px rgb(74 144 226 / 50%);
}
&::placeholder {
@@ -12,7 +12,7 @@
z-index: 1000;
background: linear-gradient(135deg, #2d2d2d 0%, #1f1f1f 100%);
border-bottom: 1px solid #404040;
box-shadow: 0 2px 8px rgb(0, 0, 0, 30%);
box-shadow: 0 2px 8px rgb(0 0 0 / 30%);
color: #ffffff;
opacity: 1;
pointer-events: auto;
@@ -51,7 +51,7 @@
}
&:hover {
background: rgb(255, 255, 255, 12%);
background: rgb(255 255 255 / 12%);
}
&:last-child {
@@ -65,13 +65,13 @@
}
&:hover {
background: rgb(239, 68, 68, 20%);
background: rgb(239 68 68 / 20%);
}
}
&.active {
color: #ef4444;
background: rgb(239, 68, 68, 15%);
background: rgb(239 68 68 / 15%);
}
&.has-notes {
@@ -128,7 +128,7 @@
background: #2d2d2d;
border: 1px solid #404040;
border-radius: 8px;
box-shadow: 0 4px 12px rgb(0, 0, 0, 40%);
box-shadow: 0 4px 12px rgb(0 0 0 / 40%);
z-index: 1000;
min-width: 180px;
padding: 4px;
@@ -149,12 +149,12 @@
white-space: nowrap;
&:hover {
background: rgb(255, 255, 255, 12%);
background: rgb(255 255 255 / 12%);
}
&.active {
color: #ef4444;
background: rgb(239, 68, 68, 15%);
background: rgb(239 68 68 / 15%);
}
}
}
@@ -2,13 +2,13 @@
// Variables
$panel-bg: #1a1a1a;
$text-primary: rgb(255, 255, 255, 95%);
$text-secondary: rgb(255, 255, 255, 60%);
$text-muted: rgb(255, 255, 255, 40%);
$border-color: rgb(255, 255, 255, 8%);
$hover-bg: rgb(255, 255, 255, 8%);
$text-primary: rgb(255 255 255 / 95%);
$text-secondary: rgb(255 255 255 / 60%);
$text-muted: rgb(255 255 255 / 40%);
$border-color: rgb(255 255 255 / 8%);
$hover-bg: rgb(255 255 255 / 8%);
$active-color: #4a90e2;
$active-bg: rgb(74, 144, 226, 15%);
$active-bg: rgb(74 144 226 / 15%);
$transition-fast: 150ms ease;
$transition-normal: 200ms ease;
@@ -16,7 +16,7 @@ $transition-normal: 200ms ease;
position: fixed;
inset: 0;
z-index: 12000;
background: rgb(0, 0, 0, 30%);
background: rgb(0 0 0 / 30%);
animation: fadeIn $transition-normal;
cursor: pointer;
}
@@ -34,7 +34,7 @@ $transition-normal: 200ms ease;
background: $panel-bg;
border: 1px solid $border-color;
border-radius: 12px;
box-shadow: 0 12px 40px rgb(0, 0, 0, 50%);
box-shadow: 0 12px 40px rgb(0 0 0 / 50%);
animation: slideDown 200ms cubic-bezier(0.4, 0, 0.2, 1);
overflow: visible;
cursor: default;
@@ -105,7 +105,7 @@ $transition-normal: 200ms ease;
position: relative;
width: 40px;
height: 22px;
background: rgb(255, 255, 255, 15%);
background: rgb(255 255 255 / 15%);
border: none;
border-radius: 11px;
cursor: pointer;
@@ -129,11 +129,11 @@ $transition-normal: 200ms ease;
background: #ffffff;
border-radius: 50%;
transition: transform 300ms ease;
box-shadow: 0 2px 4px rgb(0, 0, 0, 20%);
box-shadow: 0 2px 4px rgb(0 0 0 / 20%);
}
&:hover {
background: rgb(255, 255, 255, 20%);
background: rgb(255 255 255 / 20%);
&.active {
background: color.adjust($active-color, $lightness: 5%);
@@ -145,7 +145,7 @@ $transition-normal: 200ms ease;
.button-group {
display: flex;
gap: 4px;
background: rgb(255, 255, 255, 3%);
background: rgb(255 255 255 / 3%);
padding: 3px;
border-radius: 6px;
border: 1px solid $border-color;
@@ -200,7 +200,7 @@ $transition-normal: 200ms ease;
width: 20px;
height: 20px;
border-radius: 50%;
border: 1px solid rgb(255, 255, 255, 30%);
border: 1px solid rgb(255 255 255 / 30%);
}
}
@@ -1,12 +1,12 @@
// Variables
$sidebar-width: 300px;
$sidebar-bg: #1a1a1a;
$text-primary: rgb(255, 255, 255, 95%);
$text-secondary: rgb(255, 255, 255, 60%);
$text-muted: rgb(255, 255, 255, 40%);
$border-color: rgb(255, 255, 255, 8%);
$hover-bg: rgb(255, 255, 255, 6%);
$active-bg: rgb(74, 144, 226, 15%);
$text-primary: rgb(255 255 255 / 95%);
$text-secondary: rgb(255 255 255 / 60%);
$text-muted: rgb(255 255 255 / 40%);
$border-color: rgb(255 255 255 / 8%);
$hover-bg: rgb(255 255 255 / 6%);
$active-bg: rgb(74 144 226 / 15%);
$active-color: #4a90e2;
$transition-fast: 150ms ease;
$transition-normal: 200ms ease;
@@ -15,7 +15,7 @@ $transition-normal: 200ms ease;
.sidebar-overlay {
position: fixed;
inset: 0;
background: rgb(0, 0, 0, 40%);
background: rgb(0 0 0 / 40%);
backdrop-filter: blur(2px);
z-index: 12000;
animation: fadeIn $transition-normal;
@@ -36,7 +36,7 @@ $transition-normal: 200ms ease;
display: flex;
flex-direction: column;
color: $text-primary;
box-shadow: 4px 0 24px rgb(0, 0, 0, 30%);
box-shadow: 4px 0 24px rgb(0 0 0 / 30%);
animation: slideIn 250ms cubic-bezier(0.4, 0, 0.2, 1);
z-index: 12001;
@@ -51,7 +51,7 @@ $transition-normal: 200ms ease;
gap: 14px;
padding: 20px 16px;
border-bottom: 1px solid $border-color;
background: linear-gradient(180deg, rgb(255, 255, 255, 3%) 0%, transparent 100%);
background: linear-gradient(180deg, rgb(255 255 255 / 3%) 0%, transparent 100%);
}
.book-cover {
@@ -59,7 +59,7 @@ $transition-normal: 200ms ease;
height: 90px;
object-fit: cover;
border-radius: 4px;
box-shadow: 0 4px 12px rgb(0, 0, 0, 30%);
box-shadow: 0 4px 12px rgb(0 0 0 / 30%);
flex-shrink: 0;
}
@@ -96,7 +96,7 @@ $transition-normal: 200ms ease;
.tabs {
display: flex;
border-bottom: 1px solid $border-color;
background: rgb(0, 0, 0, 20%);
background: rgb(0 0 0 / 20%);
}
.tab {
@@ -173,11 +173,11 @@ $transition-normal: 200ms ease;
}
&::-webkit-scrollbar-thumb {
background: rgb(255, 255, 255, 15%);
background: rgb(255 255 255 / 15%);
border-radius: 3px;
&:hover {
background: rgb(255, 255, 255, 25%);
background: rgb(255 255 255 / 25%);
}
}
}
@@ -288,7 +288,7 @@ $transition-normal: 200ms ease;
border-radius: 4px;
&:hover {
background: rgb(255, 255, 255, 10%);
background: rgb(255 255 255 / 10%);
color: $text-primary;
}
@@ -426,12 +426,12 @@ $transition-normal: 200ms ease;
}
.edit-btn:hover {
background: rgb(74, 144, 226, 15%);
background: rgb(74 144 226 / 15%);
color: $active-color;
}
.delete-btn:hover {
background: rgb(239, 68, 68, 15%);
background: rgb(239 68 68 / 15%);
color: #ef4444;
}
@@ -447,7 +447,7 @@ $transition-normal: 200ms ease;
align-items: center;
gap: 10px;
padding: 12px 16px;
background: rgb(0, 0, 0, 20%);
background: rgb(0 0 0 / 20%);
border-bottom: 1px solid $border-color;
.search-icon {
@@ -475,7 +475,7 @@ $transition-normal: 200ms ease;
display: flex;
align-items: center;
justify-content: center;
background: rgb(255, 255, 255, 10%);
background: rgb(255 255 255 / 10%);
border: none;
border-radius: 50%;
color: $text-secondary;
@@ -484,7 +484,7 @@ $transition-normal: 200ms ease;
flex-shrink: 0;
&:hover {
background: rgb(255, 255, 255, 15%);
background: rgb(255 255 255 / 15%);
color: $text-primary;
}
}