Jump to content

Connect SuperML | Leeroopedia MCP: Equip your AI agents with best practices, code verification, and debugging knowledge. Powered by Leeroo — building Organizational Superintelligence. Contact us at founders@leeroo.com.

Implementation:Infiniflow Ragflow LinkDataPipelineModal Component

From Leeroopedia
Revision as of 11:21, 16 February 2026 by Admin (talk | contribs) (Auto-imported from implementations/Infiniflow_Ragflow_LinkDataPipelineModal_Component.md)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Knowledge Sources
Domains Frontend, Knowledge_Base
Last Updated 2026-02-12 06:00 GMT

Overview

Modal dialog with Zod-validated form for selecting and linking a data pipeline to a knowledge base.

Description

LinkDataPipelineModal renders a modal that adapts its title for link vs edit modes (based on whether data is provided). It uses react-hook-form with zodResolver and the pipelineFormSchema for validation. The form embeds a DataFlowSelect component for pipeline selection, which populates a local list state. On submit, it finds the selected pipeline by ID from the list and passes it to onSubmit. The modal includes Cancel and OK buttons with proper form submission handling.

Usage

Opened by LinkDataPipeline when the user clicks the link button to select a pipeline from available data pipelines.

Code Reference

Source Location

Signature

const LinkDataPipelineModal = ({
  data, open, setOpen, onSubmit,
}: {
  data: IDataPipelineNodeProps | undefined;
  open: boolean;
  setOpen: (open: boolean) => void;
  onSubmit?: (pipeline: IDataPipelineSelectNode | undefined) => void;
}) => JSX.Element;

export default LinkDataPipelineModal;

Import

import LinkDataPipelineModal from './link-data-pipline-modal';

I/O Contract

Inputs

Name Type Required Description
data IDataPipelineNodeProps No Existing pipeline data for edit mode
open boolean Yes Controls modal visibility
setOpen function Yes Toggle modal open state
onSubmit function No Callback with selected pipeline

Outputs

Name Type Description
JSX.Element React element Modal with pipeline selection form

Usage Examples

<LinkDataPipelineModal
  data={undefined}
  open={showModal}
  setOpen={setShowModal}
  onSubmit={(pipeline) => handleLink(pipeline)}
/>

Related Pages

Page Connections

Double-click a node to navigate. Hold to expand connections.
Principle
Implementation
Heuristic
Environment