Resolve remaining biome lint and formatting errors
This commit is contained in:
1 parent
1df1ffc3e9
commit
6ea0ec7d99
7 files changed
+25
-14
No files matched your search
+12
@@ -28,6 +28,18 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"overrides": [
|
||||
{
|
||||
"includes": ["**/*.test.ts", "**/*.test.tsx"],
|
||||
"linter": {
|
||||
"rules": {
|
||||
"suspicious": {
|
||||
"noExplicitAny": "off"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"css": {
|
||||
"parser": {
|
||||
"tailwindDirectives": true
|
||||
|
||||
@@ -4,7 +4,6 @@ import { beforeEach, describe, expect, it, vi } from "vitest";
|
||||
const mockRedirect = vi.hoisted(() =>
|
||||
vi.fn((url: string) => {
|
||||
const err = new Error(`NEXT_REDIRECT: ${url}`);
|
||||
// biome-ignore lint/suspicious/noExplicitAny: Next.js redirect signature
|
||||
(err as any).digest = `NEXT_REDIRECT;replace;${url};307;;`;
|
||||
throw err;
|
||||
}),
|
||||
|
||||
@@ -139,9 +139,13 @@ html {
|
||||
*,
|
||||
*::before,
|
||||
*::after {
|
||||
/* biome-ignore lint/complexity/noImportantStyles: must override any animation/transition for prefers-reduced-motion */
|
||||
animation-duration: 0.01ms !important;
|
||||
/* biome-ignore lint/complexity/noImportantStyles: must override any animation/transition for prefers-reduced-motion */
|
||||
animation-iteration-count: 1 !important;
|
||||
/* biome-ignore lint/complexity/noImportantStyles: must override any animation/transition for prefers-reduced-motion */
|
||||
transition-duration: 0.01ms !important;
|
||||
/* biome-ignore lint/complexity/noImportantStyles: must override any behavior for prefers-reduced-motion */
|
||||
scroll-behavior: auto !important;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,11 +2,7 @@
|
||||
|
||||
import { Loader2, Package, Pencil, Plus, Trash2 } from "lucide-react";
|
||||
import { useCallback, useEffect, useState } from "react";
|
||||
import {
|
||||
createBcItem,
|
||||
deleteBcItem,
|
||||
updateBcItem,
|
||||
} from "@/actions/catalog-bc";
|
||||
import { createBcItem, deleteBcItem, updateBcItem } from "@/actions/catalog-bc";
|
||||
import { useConfirmDialog } from "@/components/admin/confirm-dialog";
|
||||
import { Button } from "@/components/ui/button";
|
||||
import {
|
||||
@@ -124,7 +120,9 @@ export function BcItemsEditor({ pageId, canEdit }: BcItemsEditorProps) {
|
||||
<TableHead className="text-xs">Item IDs</TableHead>
|
||||
<TableHead className="text-xs w-20">Order</TableHead>
|
||||
<TableHead className="text-xs">Extra Data</TableHead>
|
||||
{canEdit && <TableHead className="text-xs w-20">Actions</TableHead>}
|
||||
{canEdit && (
|
||||
<TableHead className="text-xs w-20">Actions</TableHead>
|
||||
)}
|
||||
</TableRow>
|
||||
</TableHeader>
|
||||
<TableBody>
|
||||
@@ -137,9 +135,7 @@ export function BcItemsEditor({ pageId, canEdit }: BcItemsEditorProps) {
|
||||
<TableCell className="text-xs font-mono text-muted-foreground">
|
||||
{item.itemIds}
|
||||
</TableCell>
|
||||
<TableCell className="text-xs">
|
||||
{item.orderNumber}
|
||||
</TableCell>
|
||||
<TableCell className="text-xs">{item.orderNumber}</TableCell>
|
||||
<TableCell className="text-xs text-muted-foreground max-w-32 truncate">
|
||||
{item.extradata || "\u2014"}
|
||||
</TableCell>
|
||||
|
||||
@@ -16,13 +16,13 @@ import { useCallback, useEffect, useMemo, useState } from "react";
|
||||
import { toast } from "sonner";
|
||||
import { updateCatalogPage } from "@/actions/catalog";
|
||||
import { updateBcPage } from "@/actions/catalog-bc";
|
||||
import { BulkImportItems } from "@/components/admin/catalog/bulk-import-items";
|
||||
import { CatalogImagePicker } from "@/components/admin/catalog/catalog-image-picker";
|
||||
import {
|
||||
type CatalogItemData,
|
||||
CatalogItemsTable,
|
||||
} from "@/components/admin/catalog/catalog-items-table";
|
||||
import { CatalogTranslateTab } from "@/components/admin/catalog/catalog-translate-tab";
|
||||
import { BulkImportItems } from "@/components/admin/catalog/bulk-import-items";
|
||||
import { CatalogImagePicker } from "@/components/admin/catalog/catalog-image-picker";
|
||||
import { IconPicker } from "@/components/admin/catalog/icon-picker";
|
||||
import { QuickAddFurni } from "@/components/admin/catalog/quick-add-furni";
|
||||
import { AutoOrganize } from "@/components/admin/catalog-manager/auto-organize";
|
||||
|
||||
@@ -809,8 +809,9 @@ export function SortableTree({
|
||||
};
|
||||
|
||||
const activeNode = activeId ? flatItems.find((n) => n.id === activeId) : null;
|
||||
const noop = () => {};
|
||||
const noop = () => {};
|
||||
|
||||
// biome-ignore lint/correctness/useExhaustiveDependencies: intentionally partial deps (matching the eslint-disable-line below)
|
||||
const getItemProps = useCallback(
|
||||
(node: FlatTreeNode): Omit<TreeItemProps, "sortMode" | "isOverlay"> => ({
|
||||
node,
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
// @vitest-environment node
|
||||
import { beforeEach, describe, expect, it, vi } from "vitest";
|
||||
|
||||
// biome-ignore lint/suspicious/noExplicitAny: test helper for mocking with arbitrary signatures
|
||||
type AnyFn = (...args: any[]) => any;
|
||||
|
||||
const {
|
||||
|
||||
Reference in new issue
Block a user