[WIKI-632] chore: add extended document editor props (#7783)

This commit is contained in:
Lakhan Baheti 2025-09-18 20:11:13 +05:30 committed by GitHub
parent f2057cd8fe
commit d5c3c0cbe1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 9 additions and 2 deletions

View file

@ -44,6 +44,7 @@ const CollaborativeDocumentEditor: React.FC<ICollaborativeDocumentEditorProps> =
serverHandler, serverHandler,
tabIndex, tabIndex,
user, user,
extendedDocumentEditorProps,
} = props; } = props;
// use document editor // use document editor
@ -71,6 +72,7 @@ const CollaborativeDocumentEditor: React.FC<ICollaborativeDocumentEditorProps> =
serverHandler, serverHandler,
tabIndex, tabIndex,
user, user,
extendedDocumentEditorProps,
}); });
const editorContainerClassNames = getEditorClassNames({ const editorContainerClassNames = getEditorClassNames({
@ -97,6 +99,7 @@ const CollaborativeDocumentEditor: React.FC<ICollaborativeDocumentEditorProps> =
tabIndex={tabIndex} tabIndex={tabIndex}
flaggedExtensions={flaggedExtensions} flaggedExtensions={flaggedExtensions}
disabledExtensions={disabledExtensions} disabledExtensions={disabledExtensions}
extendedDocumentEditorProps={extendedDocumentEditorProps}
/> />
</> </>
); );

View file

@ -5,7 +5,7 @@ import { cn } from "@plane/utils";
import { DocumentContentLoader, EditorContainer, EditorContentWrapper } from "@/components/editors"; import { DocumentContentLoader, EditorContainer, EditorContentWrapper } from "@/components/editors";
import { AIFeaturesMenu, BlockMenu, EditorBubbleMenu } from "@/components/menus"; import { AIFeaturesMenu, BlockMenu, EditorBubbleMenu } from "@/components/menus";
// types // types
import { IEditorProps, TAIHandler, TDisplayConfig } from "@/types"; import type { ICollaborativeDocumentEditorPropsExtended, IEditorProps, TAIHandler, TDisplayConfig } from "@/types";
type Props = { type Props = {
aiHandler?: TAIHandler; aiHandler?: TAIHandler;
@ -14,6 +14,7 @@ type Props = {
documentLoaderClassName?: string; documentLoaderClassName?: string;
editor: Editor; editor: Editor;
editorContainerClassName: string; editorContainerClassName: string;
extendedDocumentEditorProps?: ICollaborativeDocumentEditorPropsExtended;
id: string; id: string;
isLoading?: boolean; isLoading?: boolean;
isTouchDevice: boolean; isTouchDevice: boolean;

View file

@ -51,4 +51,7 @@ export type TCollaborativeEditorHookProps = TCoreHookProps &
| "placeholder" | "placeholder"
| "tabIndex" | "tabIndex"
> & > &
Pick<ICollaborativeDocumentEditorProps, "dragDropEnabled" | "realtimeConfig" | "serverHandler" | "user">; Pick<
ICollaborativeDocumentEditorProps,
"dragDropEnabled" | "extendedDocumentEditorProps" | "realtimeConfig" | "serverHandler" | "user"
>;