chore: finish frontend ESLint migration #18
Enable every plugin recommended preset and replace Biome with ESLint formatting. Preserve API contracts and JSX whitespace; verify source, tests, builds and tooling.
This commit is contained in:
@@ -1,24 +1,11 @@
|
||||
import { apiQueryClient, type paths, useResourceQuery } from "@/shared/api";
|
||||
|
||||
type IncomeSummary = NonNullable<
|
||||
paths["/api/v1/brokerage-accounts/{accountId}/income-summary"]["get"]["responses"][200]["content"]["application/json"]["data"]
|
||||
>;
|
||||
type IncomeAnalytics = NonNullable<
|
||||
paths["/api/v1/brokerage-accounts/{accountId}/income-analytics"]["get"]["responses"][200]["content"]["application/json"]["data"]
|
||||
>;
|
||||
|
||||
function useIncomeSummary(accountId: string | undefined) {
|
||||
return useResourceQuery({
|
||||
meta: { accessGroup: "brokerage" },
|
||||
...apiQueryClient.queryOptions(
|
||||
"get",
|
||||
"/api/v1/brokerage-accounts/{accountId}/income-summary",
|
||||
{ params: { path: { accountId: accountId ?? "" } } },
|
||||
),
|
||||
enabled: Boolean(accountId),
|
||||
staleTime: 30_000,
|
||||
});
|
||||
}
|
||||
type IncomeSummary = NonNullable<
|
||||
paths["/api/v1/brokerage-accounts/{accountId}/income-summary"]["get"]["responses"][200]["content"]["application/json"]["data"]
|
||||
>;
|
||||
|
||||
function useIncomeAnalytics(
|
||||
accountId: string | undefined,
|
||||
@@ -41,6 +28,19 @@ function useIncomeAnalytics(
|
||||
});
|
||||
}
|
||||
|
||||
function useIncomeSummary(accountId: string | undefined) {
|
||||
return useResourceQuery({
|
||||
meta: { accessGroup: "brokerage" },
|
||||
...apiQueryClient.queryOptions(
|
||||
"get",
|
||||
"/api/v1/brokerage-accounts/{accountId}/income-summary",
|
||||
{ params: { path: { accountId: accountId ?? "" } } },
|
||||
),
|
||||
enabled: Boolean(accountId),
|
||||
staleTime: 30_000,
|
||||
});
|
||||
}
|
||||
|
||||
export {
|
||||
type IncomeAnalytics,
|
||||
type IncomeSummary,
|
||||
|
||||
Reference in New Issue
Block a user