mirror of https://github.com/buster-so/buster.git
rename prop
This commit is contained in:
parent
55751b0468
commit
6818c46578
|
@ -30,7 +30,7 @@ interface ReportEditorProps {
|
|||
onReady?: (editor: IReportEditor) => void;
|
||||
id?: string;
|
||||
mode?: 'export' | 'default';
|
||||
children?: React.ReactNode;
|
||||
preEditorChildren?: React.ReactNode;
|
||||
postEditorChildren?: React.ReactNode;
|
||||
}
|
||||
|
||||
|
@ -60,7 +60,7 @@ export const ReportEditor = React.memo(
|
|||
useFixedToolbarKit = false,
|
||||
readOnly = false,
|
||||
isStreaming = false,
|
||||
children,
|
||||
preEditorChildren,
|
||||
postEditorChildren
|
||||
},
|
||||
ref
|
||||
|
@ -135,7 +135,7 @@ export const ReportEditor = React.memo(
|
|||
variant={variant}
|
||||
readOnly={readOnly}
|
||||
className={cn('editor-container relative overflow-auto', containerClassName)}>
|
||||
{children}
|
||||
{preEditorChildren}
|
||||
<ThemeWrapper id={id}>
|
||||
<Editor
|
||||
style={style}
|
||||
|
|
|
@ -73,11 +73,7 @@ export const ReportPageController: React.FC<{
|
|||
mode={mode}
|
||||
onReady={onReadyProp}
|
||||
isStreaming={isStreamingMessage}
|
||||
postEditorChildren={
|
||||
showGeneratingContent ? (
|
||||
<GeneratingContent messageId={messageId} className={commonClassName} />
|
||||
) : null
|
||||
}>
|
||||
preEditorChildren={
|
||||
<ReportPageHeader
|
||||
name={report?.name}
|
||||
updatedAt={report?.updated_at}
|
||||
|
@ -85,7 +81,12 @@ export const ReportPageController: React.FC<{
|
|||
className={commonClassName}
|
||||
isStreaming={isStreamingMessage}
|
||||
/>
|
||||
</DynamicReportEditor>
|
||||
}
|
||||
postEditorChildren={
|
||||
showGeneratingContent ? (
|
||||
<GeneratingContent messageId={messageId} className={commonClassName} />
|
||||
) : null
|
||||
}></DynamicReportEditor>
|
||||
) : (
|
||||
<ReportEditorSkeleton />
|
||||
)}
|
||||
|
|
Loading…
Reference in New Issue