@fileverse-dev/dsheet 1.3.8-input-3 → 1.3.8

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,7 +7,7 @@ type SyncContext = {
7
7
  dsheetId: string;
8
8
  handleOnChangePortalUpdate: () => void;
9
9
  };
10
- export declare const syncCurrentSheetField: (context: SyncContext, field: "images" | "iframes" | "frozen" | "name" | "config" | "showGridLines") => void;
10
+ export declare const syncCurrentSheetField: (context: SyncContext, field: "images" | "iframes" | "frozen" | "name" | "config" | "showGridLines" | "color" | "hide") => void;
11
11
  export declare const createSheetLengthChangeHandler: ({ sheetEditorRef, ydocRef, dsheetId, currentDataRef, handleOnChangePortalUpdate, }: {
12
12
  sheetEditorRef: React.MutableRefObject<WorkbookInstance | null>;
13
13
  ydocRef: React.MutableRefObject<Y.Doc | null>;
@@ -16,5 +16,8 @@ export declare const createSheetLengthChangeHandler: ({ sheetEditorRef, ydocRef,
16
16
  handleOnChangePortalUpdate: () => void;
17
17
  }) => () => void;
18
18
  export declare const createAfterOrderChangesHandler: ({ sheetEditorRef, ydocRef, dsheetId, handleOnChangePortalUpdate, }: SyncContext) => () => void;
19
+ export declare const createAfterColorChangesHandler: ({ sheetEditorRef, ydocRef, dsheetId, handleOnChangePortalUpdate, }: SyncContext) => () => void;
20
+ export declare const createAfterHideChangesHandler: ({ sheetEditorRef, ydocRef, dsheetId, handleOnChangePortalUpdate, }: SyncContext) => () => void;
19
21
  export declare const createAfterColRowChangesHandler: ({ sheetEditorRef, ydocRef, dsheetId, handleOnChangePortalUpdate, }: SyncContext) => () => void;
22
+ export declare const updateAllCell: ({ sheetEditorRef, ydocRef, dsheetId, handleOnChangePortalUpdate, }: SyncContext, subSheetId: string) => void;
20
23
  export {};
@@ -2,8 +2,8 @@ import { ChangeEventHandler } from 'react';
2
2
 
3
3
  export declare const CustomButton: ({ setExportDropdownOpen, handleCSVUpload, handleXLSXUpload, handleExportToXLSX, handleExportToCSV, handleExportToJSON, }: {
4
4
  setExportDropdownOpen: React.Dispatch<React.SetStateAction<boolean>>;
5
- handleCSVUpload: (event: ChangeEventHandler<HTMLInputElement> | undefined, file: any, importType: string) => void | Promise<void>;
6
- handleXLSXUpload: (event: ChangeEventHandler<HTMLInputElement> | undefined, file: any, importType: string) => void | Promise<void>;
5
+ handleCSVUpload: (event: ChangeEventHandler<HTMLInputElement> | undefined, file: any, importType: string) => void;
6
+ handleXLSXUpload: (event: ChangeEventHandler<HTMLInputElement> | undefined, file: any, importType: string) => void;
7
7
  handleExportToXLSX: () => void;
8
8
  handleExportToCSV: () => void;
9
9
  handleExportToJSON: () => void;
@@ -5,7 +5,6 @@ import { DataBlockApiKeyHandlerType, SheetUpdateData } from '../types';
5
5
 
6
6
  import * as Y from 'yjs';
7
7
  export interface EditorContextType {
8
- setIsDataLoaded: React.Dispatch<React.SetStateAction<boolean>>;
9
8
  handleOnChangePortalUpdate: () => void;
10
9
  setSelectedTemplate?: React.Dispatch<React.SetStateAction<string>>;
11
10
  setShowSmartContractModal?: React.Dispatch<React.SetStateAction<boolean>>;
@@ -20,7 +20,6 @@ export declare const useEditorData: (ydocRef: React.MutableRefObject<Y.Doc | nul
20
20
  currentDataRef: import('react').MutableRefObject<Sheet[]>;
21
21
  remoteUpdateRef: import('react').MutableRefObject<boolean>;
22
22
  isDataLoaded: boolean;
23
- setIsDataLoaded: import('react').Dispatch<import('react').SetStateAction<boolean>>;
24
23
  handleChange: (_data: Sheet[]) => void;
25
24
  handleLiveQuery: (subsheetIndex: number, queryData: import('@fileverse-dev/fortune-core').LiveQueryData) => void;
26
25
  initialiseLiveQueryData: (sheets: Sheet[]) => void;
@@ -1,8 +1,7 @@
1
1
  import { WorkbookInstance } from '@fileverse-dev/fortune-react';
2
2
 
3
3
  import * as Y from 'yjs';
4
- export declare const usehandleHomepageRedirect: ({ setIsDataLoaded, setSelectedTemplate, handleXLSXUpload, handleCSVUpload, ydocRef, dsheetId, currentDataRef, setForceSheetRender, sheetEditorRef, updateDocumentTitle, }: {
5
- setIsDataLoaded: React.Dispatch<React.SetStateAction<boolean>>;
4
+ export declare const usehandleHomepageRedirect: ({ setSelectedTemplate, handleXLSXUpload, handleCSVUpload, ydocRef, dsheetId, currentDataRef, setForceSheetRender, sheetEditorRef, updateDocumentTitle }: {
6
5
  setSelectedTemplate?: React.Dispatch<React.SetStateAction<string>>;
7
6
  handleXLSXUpload: any;
8
7
  handleCSVUpload: any;
@@ -1,4 +1,4 @@
1
1
  import { WorkbookInstance } from '@fileverse-dev/fortune-react';
2
2
  import { MutableRefObject } from 'react';
3
3
  import * as Y from 'yjs';
4
- export declare const handleExportToCSV: (workbookRef: MutableRefObject<WorkbookInstance | null>, ydocRef: MutableRefObject<Y.Doc | null>, _dsheetId?: string, getDocumentTitle?: () => string) => void;
4
+ export declare const handleExportToCSV: (workbookRef: MutableRefObject<WorkbookInstance | null>, ydocRef: MutableRefObject<Y.Doc | null>) => void;
@@ -2,4 +2,4 @@ import { default as React } from 'react';
2
2
  import { WorkbookInstance } from '@fileverse-dev/fortune-react';
3
3
 
4
4
  import * as Y from 'yjs';
5
- export declare const handleCSVUpload: (event: React.ChangeEventHandler<HTMLInputElement> | undefined, ydoc: Y.Doc | null, setForceSheetRender: React.Dispatch<React.SetStateAction<number>>, dsheetId: string, currentDataRef: React.MutableRefObject<object | null>, sheetEditorRef: React.RefObject<WorkbookInstance | null>, updateDocumentTitle?: (title: string) => void, fileArg?: File, importType?: string, handleContentPortal?: any) => Promise<void>;
5
+ export declare const handleCSVUpload: (event: React.ChangeEventHandler<HTMLInputElement> | undefined, ydoc: Y.Doc | null, setForceSheetRender: React.Dispatch<React.SetStateAction<number>>, dsheetId: string, currentDataRef: React.MutableRefObject<object | null>, sheetEditorRef: React.RefObject<WorkbookInstance | null>, updateDocumentTitle?: (title: string) => void, fileArg?: File, importType?: string, handleContentPortal?: any) => void;
@@ -8,10 +8,10 @@ export declare const getCustomToolbarItems: ({ handleContentPortal, setShowSmart
8
8
  getDocumentTitle?: () => string;
9
9
  updateDocumentTitle?: (title: string) => void;
10
10
  setExportDropdownOpen: React.Dispatch<React.SetStateAction<boolean>>;
11
- handleCSVUpload: (event: ChangeEventHandler<HTMLInputElement> | undefined, ydocRef: Y.Doc | null, setForceSheetRender: React.Dispatch<React.SetStateAction<number>>, dsheetId: string, currentDataRef: React.MutableRefObject<object | null>, sheetEditorRef: React.RefObject<WorkbookInstance | null>, updateDocumentTitle?: (title: string) => void, file?: File, importType?: string, handleContentPortal?: any) => void | Promise<void>;
12
- handleXLSXUpload: (event: ChangeEventHandler<HTMLInputElement> | undefined, file?: File, importType?: string) => void | Promise<void>;
11
+ handleCSVUpload: (event: ChangeEventHandler<HTMLInputElement> | undefined, ydocRef: Y.Doc | null, setForceSheetRender: React.Dispatch<React.SetStateAction<number>>, dsheetId: string, currentDataRef: React.MutableRefObject<object | null>, sheetEditorRef: React.RefObject<WorkbookInstance | null>, updateDocumentTitle?: (title: string) => void, file?: File, importType?: string, handleContentPortal?: any) => void;
12
+ handleXLSXUpload: (event: ChangeEventHandler<HTMLInputElement> | undefined, file?: File, importType?: string) => void;
13
13
  handleExportToXLSX: (sheetEditorRef: React.RefObject<WorkbookInstance | null>, ydocRef: React.RefObject<Y.Doc | null>, dsheetId: string, getDocumentTitle?: () => string) => void;
14
- handleExportToCSV: (sheetEditorRef: React.RefObject<WorkbookInstance | null>, ydocRef: React.RefObject<Y.Doc | null>, dsheetId: string, getDocumentTitle?: () => string) => void;
14
+ handleExportToCSV: (sheetEditorRef: React.RefObject<WorkbookInstance | null>, ydocRef: React.RefObject<Y.Doc | null>, dsheetId: string) => void;
15
15
  handleExportToJSON: (sheetEditorRef: React.RefObject<WorkbookInstance | null>, ydocRef: React.RefObject<Y.Doc | null>, dsheetId: string) => void;
16
16
  sheetEditorRef: React.RefObject<WorkbookInstance | null>;
17
17
  ydocRef: React.RefObject<Y.Doc | null>;
@@ -0,0 +1,13 @@
1
+ import { WorkbookInstance } from '@fileverse-dev/fortune-react';
2
+
3
+ import * as Y from 'yjs';
4
+ /**
5
+ * Sync `filter_select` for active sheet.
6
+ * Stored as a Y.Map for granular updates (keys: "row", "column").
7
+ */
8
+ export declare const filterSelectYdocUpdate: ({ sheetEditorRef, ydocRef, dsheetId, handleContentPortal, }: {
9
+ sheetEditorRef: React.RefObject<WorkbookInstance | null>;
10
+ ydocRef: React.RefObject<Y.Doc | null>;
11
+ dsheetId: string;
12
+ handleContentPortal?: any;
13
+ }) => void;
@@ -0,0 +1,13 @@
1
+ import { WorkbookInstance } from '@fileverse-dev/fortune-react';
2
+
3
+ import * as Y from 'yjs';
4
+ /**
5
+ * Sync `filter` for active sheet.
6
+ * Stored as one object payload in Yjs (keys like "0", "1", "all" map to objects).
7
+ */
8
+ export declare const filterYdocUpdate: ({ sheetEditorRef, ydocRef, dsheetId, handleContentPortal, }: {
9
+ sheetEditorRef: React.RefObject<WorkbookInstance | null>;
10
+ ydocRef: React.RefObject<Y.Doc | null>;
11
+ dsheetId: string;
12
+ handleContentPortal?: any;
13
+ }) => void;