@fileverse-dev/dsheet 2.1.3-rtc-debug-5 → 2.1.3-rtc-debug-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.
@@ -75,6 +75,7 @@ interface EditorProviderProps {
75
75
  enableLiveQuery?: boolean;
76
76
  liveQueryRefreshRate?: number;
77
77
  dataBlockApiKeyHandler?: DataBlockApiKeyHandlerType;
78
+ onContentSyncStatusChange?: (status: 'initializing' | 'syncing' | 'synced' | 'error') => void;
78
79
  }
79
80
  export declare const EditorProvider: React.FC<EditorProviderProps>;
80
81
  export declare const useEditor: () => EditorContextType;
@@ -7,5 +7,5 @@ import { DsheetProps } from './types';
7
7
  * @param props - Component properties
8
8
  * @returns The SpreadsheetEditor component
9
9
  */
10
- declare const SpreadsheetEditor: ({ isReadOnly, allowSheetDownload, allowComments, renderNavbar, enableIndexeddbSync, dsheetId, portalContent, onChange, username, selectedTemplate, toggleTemplateSidebar, isTemplateOpen, onboardingComplete, onboardingCompleteLocalStorageKey, onboardingHandler, commentData, getCommentCellUI, dataBlockApiKeyHandler, setFetchingURLData, setShowFetchURLModal, setInputFetchURLDataBlock, sheetEditorRef: externalSheetEditorRef, storeApiKey, onDuneChartEmbed, onSheetCountChange, onDataBlockApiResponse, isAuthorized, getDocumentTitle, updateDocumentTitle, setShowSmartContractModal, editorStateRef, handleSmartContractQuery, setSelectedTemplate, isNewSheet, liveQueryRefreshRate, enableLiveQuery, collaboration, }: DsheetProps) => JSX.Element;
10
+ declare const SpreadsheetEditor: ({ isReadOnly, allowSheetDownload, allowComments, renderNavbar, enableIndexeddbSync, dsheetId, portalContent, onChange, username, selectedTemplate, toggleTemplateSidebar, isTemplateOpen, onboardingComplete, onboardingCompleteLocalStorageKey, onboardingHandler, commentData, getCommentCellUI, dataBlockApiKeyHandler, setFetchingURLData, setShowFetchURLModal, setInputFetchURLDataBlock, sheetEditorRef: externalSheetEditorRef, storeApiKey, onDuneChartEmbed, onSheetCountChange, onDataBlockApiResponse, isAuthorized, getDocumentTitle, updateDocumentTitle, setShowSmartContractModal, editorStateRef, handleSmartContractQuery, setSelectedTemplate, isNewSheet, liveQueryRefreshRate, enableLiveQuery, collaboration, onContentSyncStatusChange, }: DsheetProps) => JSX.Element;
11
11
  export default SpreadsheetEditor;
@@ -80,6 +80,10 @@ export interface DsheetProps {
80
80
  onDataBlockApiResponse?: (dataBlockName: string) => void;
81
81
  onDuneChartEmbed?: () => void;
82
82
  onSheetCountChange?: (sheetCount: number) => void;
83
+ /** Fires whenever local content-sync status changes. Host apps should gate
84
+ * collab start/resume on 'synced' — starting before local content is fully
85
+ * synced is what let the RTC layer bind to a stale doc in the past. */
86
+ onContentSyncStatusChange?: (status: 'initializing' | 'syncing' | 'synced' | 'error') => void;
83
87
  editorStateRef?: React.MutableRefObject<{
84
88
  refreshIndexedDB: () => Promise<void>;
85
89
  } | null>;