mirror of
https://github.com/langflow-ai/langflow.git
synced 2026-07-23 17:31:33 +08:00
fix: resolve biome errors on HITL-touched frontend files
This commit is contained in:
@ -1,6 +1,6 @@
|
||||
import { render, screen } from "@testing-library/react";
|
||||
import type { InteractiveContent } from "@/types/chat";
|
||||
import { useHitlStore } from "@/stores/hitlStore";
|
||||
import type { InteractiveContent } from "@/types/chat";
|
||||
import HumanInputNodeBadge from "../index";
|
||||
|
||||
jest.mock("@/components/core/chatComponents/HumanInputCard", () => ({
|
||||
|
||||
@ -29,9 +29,9 @@ import { scapedJSONStringfy } from "../../utils/reactflowUtils";
|
||||
import { classNames, cn } from "../../utils/utils";
|
||||
import { processNodeAdvancedFields } from "../helpers/process-node-advanced-fields";
|
||||
import useUpdateNodeCode from "../hooks/use-update-node-code";
|
||||
import HumanInputNodeBadge from "./components/HumanInputNodeBadge";
|
||||
import NodeDescription from "./components/NodeDescription";
|
||||
import NodeLegacyComponent from "./components/NodeLegacyComponent";
|
||||
import HumanInputNodeBadge from "./components/HumanInputNodeBadge";
|
||||
import NodeName from "./components/NodeName";
|
||||
import NodeOutputs from "./components/NodeOutputParameter/NodeOutputs";
|
||||
import NodeUpdateComponent from "./components/NodeUpdateComponent";
|
||||
|
||||
@ -4,7 +4,6 @@ import rehypeMathjax from "rehype-mathjax/browser";
|
||||
import remarkGfm from "remark-gfm";
|
||||
import type { ContentType, InteractiveContent, JSONValue } from "@/types/chat";
|
||||
import { extractLanguage, isCodeBlock } from "@/utils/codeBlockUtils";
|
||||
import ForwardedIconComponent from "../../common/genericIconComponent";
|
||||
import SimplifiedCodeTabComponent from "../codeTabsComponent";
|
||||
import DurationDisplay from "./DurationDisplay";
|
||||
import HumanInputCard, { type HumanInputDecision } from "./HumanInputCard";
|
||||
|
||||
@ -50,11 +50,13 @@ jest.mock("react-markdown", () => ({
|
||||
jest.mock("remark-gfm", () => ({ __esModule: true, default: () => {} }));
|
||||
|
||||
jest.mock("@/components/ui/button", () => ({
|
||||
// biome-ignore lint/suspicious/noExplicitAny: jest mock forwards arbitrary props
|
||||
Button: ({ children, ...props }: any) => (
|
||||
<button {...props}>{children}</button>
|
||||
),
|
||||
}));
|
||||
jest.mock("@/components/ui/input", () => ({
|
||||
// biome-ignore lint/suspicious/noExplicitAny: jest mock forwards arbitrary props
|
||||
Input: (props: any) => <input {...props} />,
|
||||
}));
|
||||
|
||||
|
||||
@ -9,6 +9,7 @@ import {
|
||||
SimpleSidebar,
|
||||
SimpleSidebarProvider,
|
||||
} from "@/components/ui/simple-sidebar";
|
||||
import { useRestoreCanvasHitl } from "@/controllers/API/agui/use-restore-canvas-hitl";
|
||||
import { useGetFlow } from "@/controllers/API/queries/flows/use-get-flow";
|
||||
import { useGetTypes } from "@/controllers/API/queries/flows/use-get-types";
|
||||
import { ENABLE_NEW_SIDEBAR } from "@/customization/feature-flags";
|
||||
@ -20,9 +21,9 @@ import { useWebhookEvents } from "@/hooks/use-webhook-events";
|
||||
import { SaveChangesModal } from "@/modals/saveChangesModal";
|
||||
import useAlertStore from "@/stores/alertStore";
|
||||
import useAssistantManagerStore from "@/stores/assistantManagerStore";
|
||||
import useFlowBuilderWelcomeStore from "@/stores/flowBuilderWelcomeStore";
|
||||
import { usePlaygroundStore } from "@/stores/playgroundStore";
|
||||
import { useShortcutsStore } from "@/stores/shortcuts";
|
||||
import useFlowBuilderWelcomeStore from "@/stores/flowBuilderWelcomeStore";
|
||||
import { useTypesStore } from "@/stores/typesStore";
|
||||
import { customStringify } from "@/utils/reactflowUtils";
|
||||
import { cn } from "@/utils/utils";
|
||||
@ -33,7 +34,6 @@ import {
|
||||
FlowSidebarComponent,
|
||||
} from "./components/flowSidebarComponent";
|
||||
import MemoriesMainContent from "./components/MemoriesMainContent";
|
||||
import { useRestoreCanvasHitl } from "@/controllers/API/agui/use-restore-canvas-hitl";
|
||||
import Page from "./components/PageComponent";
|
||||
import { FlowInsightsContent } from "./components/TraceComponent/FlowInsightsContent";
|
||||
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
// biome-ignore-all lint/suspicious/noExplicitAny: pre-existing legacy flow-store types predate this rule; the HITL change only added typed fields
|
||||
import type {
|
||||
Connection,
|
||||
Node,
|
||||
|
||||
Reference in New Issue
Block a user