mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-24 23:46:52 +08:00
### What problem does this PR solve? Feat: Add a form with data operations operators #10427 ### Type of change - [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
@ -17,6 +17,7 @@ type RAGFlowFormItemProps = {
|
||||
horizontal?: boolean;
|
||||
required?: boolean;
|
||||
labelClassName?: string;
|
||||
className?: string;
|
||||
};
|
||||
|
||||
export function RAGFlowFormItem({
|
||||
@ -27,6 +28,7 @@ export function RAGFlowFormItem({
|
||||
horizontal = false,
|
||||
required = false,
|
||||
labelClassName,
|
||||
className,
|
||||
}: RAGFlowFormItemProps) {
|
||||
const form = useFormContext();
|
||||
return (
|
||||
@ -35,9 +37,12 @@ export function RAGFlowFormItem({
|
||||
name={name}
|
||||
render={({ field }) => (
|
||||
<FormItem
|
||||
className={cn({
|
||||
'flex items-center': horizontal,
|
||||
})}
|
||||
className={cn(
|
||||
{
|
||||
'flex items-center': horizontal,
|
||||
},
|
||||
className,
|
||||
)}
|
||||
>
|
||||
{label && (
|
||||
<FormLabel
|
||||
|
||||
Reference in New Issue
Block a user