Build your own AI office with Univer Office SDK. Bring editing, calculation, collaboration, and file processing into your product for people and AI agents. Built on an extensible open-source core.
TypeScript boardcollaborationdocdocxexceloffce365officepdfpptpptxpresentationsdksheetslidesspreadsheetuniverwordwordprocessorworkspacexlsx
revert(protocol): remove custom sheet template dimensions (#7825)
wpxp123456f7c5710df076
diff --git a/packages/protocol/src/index.ts b/packages/protocol/src/index.tsindex 83275e1f23..d585c5ba60 100644--- a/packages/protocol/src/index.ts+++ b/packages/protocol/src/index.ts@@ -61,7 +61,6 @@ export type {ISnapshot,ITableInfo,} from './ts/univer/snapshot';-export type { ICustomSheetTemplate } from './ts/univer/unit-template';export type { IUnit } from './ts/univer/univer-file';export { CellValueType } from './ts/univer/workbook';export type { ICellData, ISheetBlock, ISheetBlockMeta, IWorkbookMeta, IWorksheetMeta } from './ts/univer/workbook';diff --git a/packages/protocol/src/ts/univer/unit-template.ts b/packages/protocol/src/ts/univer/unit-template.tsindex 6f37123a02..57521574ff 100644--- a/packages/protocol/src/ts/univer/unit-template.ts+++ b/packages/protocol/src/ts/univer/unit-template.ts@@ -22,22 +22,3 @@ export interface ICustomCellTemplate {colWidth: number;showGridlines: number;}--/**- * Initial worksheet dimensions for the `custom-sheet` template.- * Each omitted field uses its built-in default independently.- */-export interface ICustomSheetTemplate {- /** Initial number of rows. Defaults to 1000. */- rowCount?: number;- /** Initial number of columns. Defaults to 20 (A–T); use 26 for A–Z. */- columnCount?: number;- /** Default row height in pixels. Defaults to 24. */- defaultRowHeight?: number;- /** Default column width in pixels. Defaults to 88. */- defaultColumnWidth?: number;- /** Width of the row-number header in pixels. Defaults to 46; an explicit 0 is preserved. */- rowHeaderWidth?: number;- /** Height of the column-letter header in pixels. Defaults to 20; an explicit 0 is preserved. */- columnHeaderHeight?: number;-}diff --git a/packages/protocol/src/ts/univerpro/v1/apply.ts b/packages/protocol/src/ts/univerpro/v1/apply.tsindex 92757b281e..7d1829a71a 100644--- a/packages/protocol/src/ts/univerpro/v1/apply.ts+++ b/packages/protocol/src/ts/univerpro/v1/apply.ts@@ -19,7 +19,7 @@ import type { IError } from '../../univer/constants/errors';import type { UniverType } from '../../univer/constants/univer';import type { IInitialSheet } from '../../univer/initial-sheet';import type { ISnapshot } from '../../univer/snapshot';-import type { ICustomCellTemplate, ICustomSheetTemplate } from '../../univer/unit-template';+import type { ICustomCellTemplate } from '../../univer/unit-template';export interface IForkUnitRequest {sourceUnitId: string;@@ -60,7 +60,6 @@ export interface IWorkbookCreateMeta {customCell?:| ICustomCellTemplate| undefined;- customSheet?: ICustomSheetTemplate | undefined;/** Other meta in the future. */docContent: string;}diff --git a/packages/protocol/src/ts/universer/v1/snapshot.ts b/packages/protocol/src/ts/universer/v1/snapshot.tsindex f81ccc18df..f0b5c60d9a 100644--- a/packages/protocol/src/ts/universer/v1/snapshot.ts+++ b/packages/protocol/src/ts/universer/v1/snapshot.ts@@ -22,7 +22,7 @@ import type { UniverType } from '../../univer/constants/univer';import type { IInitialSheet } from '../../univer/initial-sheet';import type { IResource } from '../../univer/resource';import type { ISnapshot, ITableInfo } from '../../univer/snapshot';-import type { ICustomCellTemplate, ICustomSheetTemplate } from '../../univer/unit-template';+import type { ICustomCellTemplate } from '../../univer/unit-template';import type { IUnit } from '../../univer/univer-file';import type { ISheetBlock, ISheetBlockMeta } from '../../univer/workbook';@@ -161,7 +161,6 @@ export interface ICreateUnitRequest {snapshot: ISnapshot | undefined;templateID: string;customCell?: ICustomCellTemplate | undefined;- customSheet?: ICustomSheetTemplate | undefined;initialSheets: IInitialSheet[];docContent: string;preCreateUnitId: string;