mirror of
https://github.com/mgeeky/decode-spam-headers.git
synced 2026-02-22 05:23:31 +01:00
MAESTRO: run prettier for phase 03 checklist
This commit is contained in:
@@ -44,7 +44,7 @@ Note: `npx vitest run src/__tests__/AnalyseButton.test.tsx` passes; Vitest emits
|
||||
- [x] Ctrl+Enter keyboard shortcut triggers the analyse action
|
||||
- [x] Dark hacker theme is visible with correct colour palette
|
||||
- [x] Validation shows user-friendly errors for empty and oversized input
|
||||
- [ ] `npx eslint src/` and `npx prettier --check src/` pass with zero errors
|
||||
- [x] `npx eslint src/` and `npx prettier --check src/` pass with zero errors
|
||||
- [ ] Run `/speckit.analyze` to verify consistency
|
||||
|
||||
Note: Wired `FileDropZone` into the main page to populate the header input state on drop.
|
||||
|
||||
@@ -39,7 +39,7 @@ const getTextarea = (container: HTMLElement): HTMLTextAreaElement => {
|
||||
};
|
||||
|
||||
const getAlert = (container: HTMLElement): HTMLElement | null =>
|
||||
container.querySelector("[role=\"alert\"]");
|
||||
container.querySelector('[role="alert"]');
|
||||
|
||||
afterEach(() => {
|
||||
while (cleanups.length > 0) {
|
||||
|
||||
@@ -46,12 +46,10 @@ export default function Home() {
|
||||
Decode Suite
|
||||
</p>
|
||||
<div className="flex flex-col gap-3">
|
||||
<h1 className="text-3xl font-semibold sm:text-4xl">
|
||||
Decode Spam Headers
|
||||
</h1>
|
||||
<h1 className="text-3xl font-semibold sm:text-4xl">Decode Spam Headers</h1>
|
||||
<p className="max-w-2xl text-sm text-text/70 sm:text-base">
|
||||
Paste SMTP headers or drop an EML/TXT file to reveal the
|
||||
anti-spam signals baked into your message path.
|
||||
Paste SMTP headers or drop an EML/TXT file to reveal the anti-spam signals baked
|
||||
into your message path.
|
||||
</p>
|
||||
</div>
|
||||
</header>
|
||||
@@ -63,12 +61,10 @@ export default function Home() {
|
||||
<FileDropZone onFileContent={setHeaderInput} />
|
||||
|
||||
<div className="rounded-2xl border border-info/10 bg-surface p-6">
|
||||
<p className="text-xs uppercase tracking-[0.2em] text-info/80">
|
||||
Ready To Analyse
|
||||
</p>
|
||||
<p className="text-xs uppercase tracking-[0.2em] text-info/80">Ready To Analyse</p>
|
||||
<p className="mt-2 text-sm text-text/70">
|
||||
Once input is provided, run the analysis to reveal scoring,
|
||||
heuristics, and delivery path insights.
|
||||
Once input is provided, run the analysis to reveal scoring, heuristics, and
|
||||
delivery path insights.
|
||||
</p>
|
||||
<div className="mt-4 flex flex-col gap-3 sm:flex-row sm:items-center">
|
||||
<AnalyseButton
|
||||
|
||||
@@ -104,11 +104,7 @@ export default function FileDropZone({ onFileContent }: FileDropZoneProps) {
|
||||
reader.readAsText(file);
|
||||
};
|
||||
|
||||
const borderClass = error
|
||||
? "border-spam/70"
|
||||
: isDragging
|
||||
? "border-info"
|
||||
: "border-info/40";
|
||||
const borderClass = error ? "border-spam/70" : isDragging ? "border-info" : "border-info/40";
|
||||
const surfaceClass = isDragging ? "bg-surface" : "bg-surface/70";
|
||||
|
||||
return (
|
||||
|
||||
@@ -4,10 +4,7 @@ import { type FormEvent, useEffect, useId, useRef, useState } from "react";
|
||||
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
|
||||
import { faXmark } from "@fortawesome/free-solid-svg-icons";
|
||||
|
||||
import {
|
||||
MAX_HEADER_INPUT_BYTES,
|
||||
validateHeaderInput,
|
||||
} from "../lib/header-validation";
|
||||
import { MAX_HEADER_INPUT_BYTES, validateHeaderInput } from "../lib/header-validation";
|
||||
|
||||
type HeaderInputProps = {
|
||||
value: string;
|
||||
|
||||
Reference in New Issue
Block a user