beca-ui 2.1.1-beta.4 → 2.1.1-beta.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -7,5 +7,5 @@ interface TableToolsProps {
7
7
  editor?: Editor | null;
8
8
  tablePosition?: TablePosition;
9
9
  }
10
- export declare const TableTools: ({ editor, tablePosition }: TableToolsProps) => import("react/jsx-runtime").JSX.Element;
10
+ export declare const TableTools: ({ editor, tablePosition }: TableToolsProps) => import("react/jsx-runtime").JSX.Element | null;
11
11
  export {};
@@ -1,6 +1,12 @@
1
1
  import React from "react";
2
2
  import { EditorContentProps } from "@tiptap/react";
3
3
  import { DataNode as AntDataNode } from "antd/lib/tree";
4
+ export interface TextEditorToolkitConfig {
5
+ visible?: boolean;
6
+ position?: "top" | "bottom";
7
+ upper?: React.ReactNode;
8
+ lower?: React.ReactNode;
9
+ }
4
10
  export interface TextEditorProps {
5
11
  value?: any;
6
12
  readingMode?: boolean;
@@ -11,9 +17,7 @@ export interface TextEditorProps {
11
17
  extraMenus?: GroupMenu[];
12
18
  isMobile?: boolean;
13
19
  placeholder?: string;
14
- toolkitPosition?: "top" | "bottom";
15
- toolkitUpper?: React.ReactNode;
16
- toolkitLower?: React.ReactNode;
20
+ toolkit?: TextEditorToolkitConfig;
17
21
  suggestionGroups?: SuggesstionGroupModel[];
18
22
  onUploadImage?: (file: File | null, base64?: string) => string;
19
23
  onEnter?: () => void;
@@ -46,8 +50,7 @@ export interface TextEditorMenuProps extends EditorContentProps {
46
50
  isMobile?: boolean;
47
51
  preMenus?: GroupMenu[];
48
52
  extraMenus?: GroupMenu[];
49
- toolkitUpper?: React.ReactNode;
50
- toolkitLower?: React.ReactNode;
53
+ toolkit?: TextEditorToolkitConfig;
51
54
  addImage: (imageUrl: string) => void;
52
55
  fontSizeUnit?: "pt" | "px";
53
56
  mode?: "advanced" | "compact";