fix: resolve all lint errors — exclude generated dirs, auto-fix source
Some checks failed
CI / ci (push) Failing after 20s
Some checks failed
CI / ci (push) Failing after 20s
Exclude drizzle/ and .planning/ from Biome (generated files with incompatible formatting). Auto-fix import ordering and formatting in existing source files. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -7,7 +7,7 @@
|
|||||||
},
|
},
|
||||||
"files": {
|
"files": {
|
||||||
"ignoreUnknown": false,
|
"ignoreUnknown": false,
|
||||||
"includes": ["**", "!src/client/routeTree.gen.ts"]
|
"includes": ["**", "!src/client/routeTree.gen.ts", "!drizzle", "!.planning"]
|
||||||
},
|
},
|
||||||
"formatter": {
|
"formatter": {
|
||||||
"enabled": true,
|
"enabled": true,
|
||||||
|
|||||||
@@ -264,12 +264,20 @@ export function WeightSummaryCard({ items }: WeightSummaryCardProps) {
|
|||||||
label="Consumable"
|
label="Consumable"
|
||||||
weight={consumableWeight}
|
weight={consumableWeight}
|
||||||
unit={unit}
|
unit={unit}
|
||||||
percent={totalWeight > 0 ? consumableWeight / totalWeight : undefined}
|
percent={
|
||||||
|
totalWeight > 0 ? consumableWeight / totalWeight : undefined
|
||||||
|
}
|
||||||
/>
|
/>
|
||||||
<div className="border-t border-gray-200 mt-1.5 pt-1.5">
|
<div className="border-t border-gray-200 mt-1.5 pt-1.5">
|
||||||
<div className="flex items-center gap-3 py-1.5">
|
<div className="flex items-center gap-3 py-1.5">
|
||||||
<LucideIcon name="sigma" size={10} className="text-gray-400 shrink-0 ml-0.5" />
|
<LucideIcon
|
||||||
<span className="text-sm font-medium text-gray-700 flex-1">Total</span>
|
name="sigma"
|
||||||
|
size={10}
|
||||||
|
className="text-gray-400 shrink-0 ml-0.5"
|
||||||
|
/>
|
||||||
|
<span className="text-sm font-medium text-gray-700 flex-1">
|
||||||
|
Total
|
||||||
|
</span>
|
||||||
<span className="text-sm font-bold text-gray-900 tabular-nums">
|
<span className="text-sm font-bold text-gray-900 tabular-nums">
|
||||||
{formatWeight(totalWeight, unit)}
|
{formatWeight(totalWeight, unit)}
|
||||||
</span>
|
</span>
|
||||||
|
|||||||
@@ -113,7 +113,10 @@ export function useUpdateItemClassification(setupId: number) {
|
|||||||
mutationFn: ({
|
mutationFn: ({
|
||||||
itemId,
|
itemId,
|
||||||
classification,
|
classification,
|
||||||
}: { itemId: number; classification: string }) =>
|
}: {
|
||||||
|
itemId: number;
|
||||||
|
classification: string;
|
||||||
|
}) =>
|
||||||
apiPatch<{ success: boolean }>(
|
apiPatch<{ success: boolean }>(
|
||||||
`/api/setups/${setupId}/items/${itemId}/classification`,
|
`/api/setups/${setupId}/items/${itemId}/classification`,
|
||||||
{ classification },
|
{ classification },
|
||||||
|
|||||||
@@ -59,7 +59,10 @@ function RootLayout() {
|
|||||||
|
|
||||||
// Don't show onboarding wizard until user has created an account
|
// Don't show onboarding wizard until user has created an account
|
||||||
const showWizard =
|
const showWizard =
|
||||||
!onboardingLoading && onboardingComplete !== "true" && !wizardDismissed && isAuthenticated;
|
!onboardingLoading &&
|
||||||
|
onboardingComplete !== "true" &&
|
||||||
|
!wizardDismissed &&
|
||||||
|
isAuthenticated;
|
||||||
|
|
||||||
const isItemPanelOpen = panelMode !== "closed";
|
const isItemPanelOpen = panelMode !== "closed";
|
||||||
const isCandidatePanelOpen = candidatePanelMode !== "closed";
|
const isCandidatePanelOpen = candidatePanelMode !== "closed";
|
||||||
|
|||||||
@@ -9,11 +9,11 @@ import { ItemCard } from "../../components/ItemCard";
|
|||||||
import { SetupCard } from "../../components/SetupCard";
|
import { SetupCard } from "../../components/SetupCard";
|
||||||
import { ThreadCard } from "../../components/ThreadCard";
|
import { ThreadCard } from "../../components/ThreadCard";
|
||||||
import { useCategories } from "../../hooks/useCategories";
|
import { useCategories } from "../../hooks/useCategories";
|
||||||
|
import { useCurrency } from "../../hooks/useCurrency";
|
||||||
import { useItems } from "../../hooks/useItems";
|
import { useItems } from "../../hooks/useItems";
|
||||||
import { useCreateSetup, useSetups } from "../../hooks/useSetups";
|
import { useCreateSetup, useSetups } from "../../hooks/useSetups";
|
||||||
import { useThreads } from "../../hooks/useThreads";
|
import { useThreads } from "../../hooks/useThreads";
|
||||||
import { useTotals } from "../../hooks/useTotals";
|
import { useTotals } from "../../hooks/useTotals";
|
||||||
import { useCurrency } from "../../hooks/useCurrency";
|
|
||||||
import { useWeightUnit } from "../../hooks/useWeightUnit";
|
import { useWeightUnit } from "../../hooks/useWeightUnit";
|
||||||
import { formatPrice, formatWeight } from "../../lib/formatters";
|
import { formatPrice, formatWeight } from "../../lib/formatters";
|
||||||
import { LucideIcon } from "../../lib/iconData";
|
import { LucideIcon } from "../../lib/iconData";
|
||||||
|
|||||||
@@ -1,10 +1,10 @@
|
|||||||
import { createFileRoute } from "@tanstack/react-router";
|
import { createFileRoute } from "@tanstack/react-router";
|
||||||
import { DashboardCard } from "../components/DashboardCard";
|
import { DashboardCard } from "../components/DashboardCard";
|
||||||
|
import { useCurrency } from "../hooks/useCurrency";
|
||||||
import { useSetups } from "../hooks/useSetups";
|
import { useSetups } from "../hooks/useSetups";
|
||||||
import { useThreads } from "../hooks/useThreads";
|
import { useThreads } from "../hooks/useThreads";
|
||||||
import { useTotals } from "../hooks/useTotals";
|
import { useTotals } from "../hooks/useTotals";
|
||||||
import { useWeightUnit } from "../hooks/useWeightUnit";
|
import { useWeightUnit } from "../hooks/useWeightUnit";
|
||||||
import { useCurrency } from "../hooks/useCurrency";
|
|
||||||
import { formatPrice, formatWeight } from "../lib/formatters";
|
import { formatPrice, formatWeight } from "../lib/formatters";
|
||||||
|
|
||||||
export const Route = createFileRoute("/")({
|
export const Route = createFileRoute("/")({
|
||||||
@@ -35,7 +35,10 @@ function DashboardPage() {
|
|||||||
label: "Weight",
|
label: "Weight",
|
||||||
value: formatWeight(global?.totalWeight ?? null, unit),
|
value: formatWeight(global?.totalWeight ?? null, unit),
|
||||||
},
|
},
|
||||||
{ label: "Cost", value: formatPrice(global?.totalCost ?? null, currency) },
|
{
|
||||||
|
label: "Cost",
|
||||||
|
value: formatPrice(global?.totalCost ?? null, currency),
|
||||||
|
},
|
||||||
]}
|
]}
|
||||||
emptyText="Get started"
|
emptyText="Get started"
|
||||||
/>
|
/>
|
||||||
|
|||||||
@@ -4,13 +4,13 @@ import { CategoryHeader } from "../../components/CategoryHeader";
|
|||||||
import { ItemCard } from "../../components/ItemCard";
|
import { ItemCard } from "../../components/ItemCard";
|
||||||
import { ItemPicker } from "../../components/ItemPicker";
|
import { ItemPicker } from "../../components/ItemPicker";
|
||||||
import { WeightSummaryCard } from "../../components/WeightSummaryCard";
|
import { WeightSummaryCard } from "../../components/WeightSummaryCard";
|
||||||
|
import { useCurrency } from "../../hooks/useCurrency";
|
||||||
import {
|
import {
|
||||||
useDeleteSetup,
|
useDeleteSetup,
|
||||||
useRemoveSetupItem,
|
useRemoveSetupItem,
|
||||||
useSetup,
|
useSetup,
|
||||||
useUpdateItemClassification,
|
useUpdateItemClassification,
|
||||||
} from "../../hooks/useSetups";
|
} from "../../hooks/useSetups";
|
||||||
import { useCurrency } from "../../hooks/useCurrency";
|
|
||||||
import { useWeightUnit } from "../../hooks/useWeightUnit";
|
import { useWeightUnit } from "../../hooks/useWeightUnit";
|
||||||
import { formatPrice, formatWeight } from "../../lib/formatters";
|
import { formatPrice, formatWeight } from "../../lib/formatters";
|
||||||
import { LucideIcon } from "../../lib/iconData";
|
import { LucideIcon } from "../../lib/iconData";
|
||||||
|
|||||||
@@ -434,7 +434,10 @@ describe("Thread Service", () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
it("returns { success: false, error } when thread status is 'resolved'", () => {
|
it("returns { success: false, error } when thread status is 'resolved'", () => {
|
||||||
const thread = createThread(db, { name: "Resolved Thread", categoryId: 1 });
|
const thread = createThread(db, {
|
||||||
|
name: "Resolved Thread",
|
||||||
|
categoryId: 1,
|
||||||
|
});
|
||||||
const candidate = createCandidate(db, thread.id, {
|
const candidate = createCandidate(db, thread.id, {
|
||||||
name: "Winner",
|
name: "Winner",
|
||||||
categoryId: 1,
|
categoryId: 1,
|
||||||
|
|||||||
Reference in New Issue
Block a user