fix: some small css fixes

This commit is contained in:
2026-08-25 14:44:31 +05:00
parent f1f5bd4409
commit 5e512f0bdd
14 changed files with 35 additions and 26 deletions
+5
View File
@@ -10,4 +10,9 @@ declare global {
} }
} }
declare module '*.css?raw' {
const content: string;
export default content;
}
export {}; export {};
+1 -1
View File
@@ -89,7 +89,7 @@
background: color-mix(in srgb, var(--accent) 10%, var(--surface)); background: color-mix(in srgb, var(--accent) 10%, var(--surface));
border: 2px dashed var(--accent); border: 2px dashed var(--accent);
border-radius: var(--radius-m); border-radius: var(--radius-m);
color: var(--accent); color: var(--link);
font-weight: 600; font-weight: 600;
text-align: center; text-align: center;
pointer-events: none; pointer-events: none;
+1 -1
View File
@@ -105,7 +105,7 @@
.dropzone:hover, .dropzone:hover,
.dropzone:focus-visible, .dropzone:focus-visible,
.dragging { .dragging {
border-color: var(--accent); border-color: var(--link);
background: color-mix(in srgb, var(--accent) 6%, var(--surface)); background: color-mix(in srgb, var(--accent) 6%, var(--surface));
} }
@@ -133,7 +133,7 @@
height: 1.4rem; height: 1.4rem;
border-radius: var(--radius-s); border-radius: var(--radius-s);
background: color-mix(in srgb, var(--accent) 10%, var(--surface)); background: color-mix(in srgb, var(--accent) 10%, var(--surface));
color: var(--accent); color: var(--link);
} }
.remove { .remove {
@@ -173,7 +173,7 @@
padding: 2px var(--space-2); padding: 2px var(--space-2);
border-radius: var(--radius-s); border-radius: var(--radius-s);
background: color-mix(in srgb, var(--accent) 12%, var(--surface)); background: color-mix(in srgb, var(--accent) 12%, var(--surface));
color: var(--accent); color: var(--link);
font-size: var(--text-xs); font-size: var(--text-xs);
} }
</style> </style>
@@ -89,7 +89,7 @@
justify-content: center; justify-content: center;
border-radius: var(--radius-s); border-radius: var(--radius-s);
background: color-mix(in srgb, var(--accent) 10%, var(--surface)); background: color-mix(in srgb, var(--accent) 10%, var(--surface));
color: var(--accent); color: var(--link);
} }
.text { .text {
@@ -130,7 +130,7 @@
} }
input:focus { input:focus {
border-color: var(--accent); border-color: var(--link);
outline: none; outline: none;
} }
@@ -117,7 +117,7 @@
padding: 2px var(--space-2); padding: 2px var(--space-2);
border-radius: var(--radius-s); border-radius: var(--radius-s);
background: color-mix(in srgb, var(--accent) 12%, var(--surface)); background: color-mix(in srgb, var(--accent) 12%, var(--surface));
color: var(--accent); color: var(--link);
font-size: var(--text-xs); font-size: var(--text-xs);
} }
</style> </style>
@@ -89,7 +89,7 @@
} }
.actions .secondary:hover { .actions .secondary:hover {
border-color: var(--accent); border-color: var(--link);
color: var(--accent); color: var(--link);
} }
</style> </style>
+2 -2
View File
@@ -68,8 +68,8 @@
} }
button.secondary:hover:not(:disabled) { button.secondary:hover:not(:disabled) {
border-color: var(--accent); border-color: var(--link);
color: var(--accent); color: var(--link);
} }
button:disabled { button:disabled {
+4 -4
View File
@@ -69,13 +69,13 @@
} }
.pipette:hover { .pipette:hover {
border-color: var(--accent); border-color: var(--link);
color: var(--accent); color: var(--link);
} }
.pipette[aria-pressed='true'] { .pipette[aria-pressed='true'] {
border-color: var(--accent); border-color: var(--link);
color: var(--accent); color: var(--link);
background: color-mix(in srgb, var(--accent) 10%, var(--surface)); background: color-mix(in srgb, var(--accent) 10%, var(--surface));
} }
</style> </style>
+3 -3
View File
@@ -71,7 +71,7 @@
input[type='range'] { input[type='range'] {
flex: 1; flex: 1;
min-width: 3rem; min-width: 3rem;
accent-color: var(--accent); accent-color: var(--link);
margin: 0; margin: 0;
} }
@@ -96,8 +96,8 @@
} }
.step:hover:not(:disabled) { .step:hover:not(:disabled) {
border-color: var(--accent); border-color: var(--link);
color: var(--accent); color: var(--link);
} }
.step:disabled { .step:disabled {
+7 -3
View File
@@ -1,6 +1,10 @@
import { readFileSync } from 'node:fs';
import { join } from 'node:path';
import { describe, expect, it } from 'vitest'; import { describe, expect, it } from 'vitest';
// @ts-expect-error node types are not wired into svelte-check; vitest resolves fine
import { readFileSync } from 'node:fs';
declare const process: { cwd(): string };
const css = readFileSync('src/app.css', 'utf8');
type Tokens = Record<string, string>; type Tokens = Record<string, string>;
@@ -48,7 +52,7 @@ function mix(fgHex: string, alpha: number, bgHex: string): string {
return `#${out.map((v) => v.toString(16).padStart(2, '0')).join('')}`; return `#${out.map((v) => v.toString(16).padStart(2, '0')).join('')}`;
} }
const css = readFileSync(join(__dirname, '..', 'app.css'), 'utf8'); const cssText = css;
const light = parseBlock(css, ':root'); const light = parseBlock(css, ':root');
const darkRaw = parseBlock(css, "[data-theme='dark']"); const darkRaw = parseBlock(css, "[data-theme='dark']");
const dark: Tokens = { ...light, ...darkRaw }; const dark: Tokens = { ...light, ...darkRaw };
+4 -4
View File
@@ -103,7 +103,7 @@
.brand:hover { .brand:hover {
text-decoration: none; text-decoration: none;
color: var(--accent); color: var(--link);
} }
nav { nav {
@@ -120,7 +120,7 @@
} }
.nav-link:hover { .nav-link:hover {
color: var(--accent); color: var(--link);
background: var(--bg); background: var(--bg);
text-decoration: none; text-decoration: none;
} }
@@ -148,7 +148,7 @@
} }
.lang-btn:hover { .lang-btn:hover {
color: var(--accent); color: var(--link);
} }
.lang-btn.active { .lang-btn.active {
@@ -158,7 +158,7 @@
.workspace-link { .workspace-link {
font-weight: 600; font-weight: 600;
color: var(--accent); color: var(--link);
} }
main { main {
+1 -1
View File
@@ -102,6 +102,6 @@
} }
.back:hover { .back:hover {
color: var(--accent); color: var(--link);
} }
</style> </style>