Merge branch 'fix/biome-lint-debt' into chore/consolidate-v2.0.0

This commit is contained in:
SnapOtter
2026-06-21 02:31:28 +08:00
23 changed files with 36 additions and 45 deletions
@@ -1,9 +1,7 @@
import { Check, Copy, Download, Search } from "lucide-react";
import { useRef, useState } from "react";
import { ProgressCard } from "@/components/common/progress-card";
import { useTranslation } from "@/contexts/i18n-context";
import { formatHeaders } from "@/lib/api";
import { format } from "@/lib/format";
import { copyToClipboard } from "@/lib/utils";
import { useFileStore } from "@/stores/file-store";
@@ -108,7 +106,6 @@ function scanOneFile(
}
export function BarcodeReadSettings() {
const { t } = useTranslation();
const { files, processing, error, setProcessing, setError } = useFileStore();
const [tryHarder, setTryHarder] = useState(false);
@@ -2,9 +2,7 @@ import { Download } from "lucide-react";
import type React from "react";
import { useCallback, useEffect, useRef, useState } from "react";
import { ProgressCard } from "@/components/common/progress-card";
import { useTranslation } from "@/contexts/i18n-context";
import { useToolProcessor } from "@/hooks/use-tool-processor";
import { format } from "@/lib/format";
import { useFileStore } from "@/stores/file-store";
// ── Presets ──────────────────────────────────────────────────────────
@@ -227,7 +225,6 @@ export function BorderControls({
onChange,
onImageStyle,
}: BorderControlsProps) {
const { t } = useTranslation();
const [selectedPreset, setSelectedPreset] = useState<string | null>(null);
const [borderWidth, setBorderWidth] = useState(10);
const [borderColor, setBorderColor] = useState("#000000");
@@ -51,7 +51,6 @@ function displayUrl(img: CollageImage): string {
}
export function CollagePreview() {
const { t } = useTranslation();
const images = useCollageStore((s) => s.images);
const templateId = useCollageStore((s) => s.templateId);
const phase = useCollageStore((s) => s.phase);
@@ -1,7 +1,6 @@
import { Download, Loader2 } from "lucide-react";
import { useCallback } from "react";
import { CollapsibleSection } from "@/components/common/collapsible-section";
import { useTranslation } from "@/contexts/i18n-context";
import { formatHeaders } from "@/lib/api";
import {
COLLAGE_TEMPLATES,
@@ -38,7 +37,6 @@ const BG_PRESETS = [
];
export function CollageSettings() {
const { t } = useTranslation();
const store = useCollageStore();
const {
images,
@@ -1,10 +1,8 @@
import { Download, Loader2, Upload } from "lucide-react";
import { useRef, useState } from "react";
import { useTranslation } from "@/contexts/i18n-context";
import { formatHeaders } from "@/lib/api";
import { useFileStore } from "@/stores/file-store";
export function CompareSettings() {
const { t } = useTranslation();
const { files, processing, error, setProcessing, setError, setProcessedUrl } = useFileStore();
const [secondFile, setSecondFile] = useState<File | null>(null);
const [similarity, setSimilarity] = useState<number | null>(null);