@fileverse-dev/ddoc 3.0.53-patch-35 → 3.0.53-patch-37
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.
- package/dist/index.es.js +11813 -11678
- package/dist/package/components/tabs/document-tabs-sidebar.d.ts +3 -1
- package/dist/package/components/tabs/tab-item.d.ts +3 -1
- package/dist/package/components/tabs/utils/tab-utils.d.ts +1 -2
- package/dist/package/hooks/use-tab-metadata-history.d.ts +14 -0
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -33,7 +33,7 @@ export interface DocumentTabsSidebarProps {
|
|
|
33
33
|
}
|
|
34
34
|
export declare const DocumentTabsSidebar: ({ tabSectionContainer, ...rest }: DocumentTabsSidebarProps) => import("react/jsx-runtime").JSX.Element | null;
|
|
35
35
|
export declare const TabSidebar: ({ tabs, activeTabId, setActiveTabId, showTOC, setShowTOC, hasToC, isPreviewMode, editor, items, setItems, orientation, createTab, renameTab, duplicateTab, orderTab, ydoc, tabCommentCounts, isVersionHistoryMode, tabConfig, deleteTab, }: DocumentTabsSidebarProps) => import("react/jsx-runtime").JSX.Element;
|
|
36
|
-
export declare const DdocTab: ({ tab, tabIndex, tabCount, handleEmojiChange, handleNameChange, onClick, editor, tocItem, setTocItems, orientation, activeTabId, duplicateTab, activeDragId, ydoc, commentCount, moveTabUp, moveTabDown, isPreviewMode, isVersionHistoryMode, tabConfig, onDelete, }: {
|
|
36
|
+
export declare const DdocTab: ({ tab, tabIndex, tabCount, handleEmojiChange, handleNameChange, onClick, editor, tocItem, setTocItems, orientation, activeTabId, duplicateTab, activeDragId, ydoc, commentCount, moveTabUp, moveTabDown, isPreviewMode, isVersionHistoryMode, tabConfig, onDelete, showOutline, onShowOutlineChange, }: {
|
|
37
37
|
tab: Tab;
|
|
38
38
|
tabIndex: number;
|
|
39
39
|
tabCount: number;
|
|
@@ -55,4 +55,6 @@ export declare const DdocTab: ({ tab, tabIndex, tabCount, handleEmojiChange, han
|
|
|
55
55
|
isVersionHistoryMode?: boolean;
|
|
56
56
|
tabConfig?: DocumentOutlineProps["tabConfig"];
|
|
57
57
|
onDelete?: (tab: Tab) => void;
|
|
58
|
+
showOutline: boolean;
|
|
59
|
+
onShowOutlineChange: (value: boolean) => void;
|
|
58
60
|
}) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -39,6 +39,8 @@ interface TabContextMenuItem {
|
|
|
39
39
|
}
|
|
40
40
|
interface TabContextMenuProps {
|
|
41
41
|
sections: TabContextMenuItem[][];
|
|
42
|
+
popoverSide?: 'top' | 'bottom';
|
|
43
|
+
popoverClassName?: string;
|
|
42
44
|
}
|
|
43
45
|
export declare const SortableTabItem: (props: SortableTabItemProps) => import("react/jsx-runtime").JSX.Element;
|
|
44
46
|
export declare const TabItem: ({ tabId, name, emoji, commentCount, onNameChange, onEmojiChange, onClick, isActive, onDuplicate, dragHandleProps, hideContentMenu, showOutline, handleShowOutline, canMoveUp, canMoveDown, onMoveUp, onMoveDown, isPreviewMode, isVersionHistoryMode, onCopyLink, onDelete, }: TabItemProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -49,5 +51,5 @@ export declare const TabDragPreview: ({ name, emoji, }: {
|
|
|
49
51
|
export declare const TabContextMenuAction: ({ item, }: {
|
|
50
52
|
item: TabContextMenuItem;
|
|
51
53
|
}) => import("react/jsx-runtime").JSX.Element;
|
|
52
|
-
export declare const TabContextMenu: ({ sections }: TabContextMenuProps) => import("react/jsx-runtime").JSX.Element;
|
|
54
|
+
export declare const TabContextMenu: ({ sections, popoverSide, popoverClassName }: TabContextMenuProps) => import("react/jsx-runtime").JSX.Element;
|
|
53
55
|
export {};
|
|
@@ -2,7 +2,6 @@ import * as Y from 'yjs';
|
|
|
2
2
|
export interface Tab {
|
|
3
3
|
id: string;
|
|
4
4
|
name: string;
|
|
5
|
-
showOutline: boolean;
|
|
6
5
|
emoji: string | null;
|
|
7
6
|
}
|
|
8
7
|
export declare const DEFAULT_TAB_ID = "default";
|
|
@@ -16,7 +15,7 @@ export declare function deriveTabsFromEncodedState(yjsEncodedState: string, doc:
|
|
|
16
15
|
export declare function getTabsYdocNodes(doc: Y.Doc): {
|
|
17
16
|
root: Y.Map<unknown>;
|
|
18
17
|
order: Y.Array<string>;
|
|
19
|
-
tabs: Y.Map<Y.Map<string |
|
|
18
|
+
tabs: Y.Map<Y.Map<string | null>>;
|
|
20
19
|
activeTab: Y.Text;
|
|
21
20
|
};
|
|
22
21
|
export declare function cloneFragmentContent(fragment: Y.XmlFragment): (Y.XmlElement | Y.XmlText)[];
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import * as Y from 'yjs';
|
|
2
|
+
interface ApplyRenameArgs {
|
|
3
|
+
tabId: string;
|
|
4
|
+
newName?: string;
|
|
5
|
+
emoji?: string;
|
|
6
|
+
}
|
|
7
|
+
export declare const useTabMetadataHistory: (ydoc: Y.Doc) => {
|
|
8
|
+
applyRename: ({ tabId, newName, emoji }: ApplyRenameArgs) => {
|
|
9
|
+
tabNotFound: boolean;
|
|
10
|
+
};
|
|
11
|
+
undo: () => boolean;
|
|
12
|
+
redo: () => boolean;
|
|
13
|
+
};
|
|
14
|
+
export {};
|