@univerjs/sheets 0.1.0-alpha.2 → 0.1.0-beta.0
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/lib/cjs/index.js +1 -3
- package/lib/es/index.js +3403 -4183
- package/lib/types/basics/interfaces/mutation-interface.d.ts +29 -29
- package/lib/types/basics/interfaces/selection-config.d.ts +1 -1
- package/lib/types/commands/commands/add-worksheet-merge.command.d.ts +2 -2
- package/lib/types/commands/commands/clear-selection-format.command.d.ts +2 -2
- package/lib/types/commands/commands/copy-to-worksheet.command.d.ts +3 -3
- package/lib/types/commands/commands/copy-worksheet.command.d.ts +2 -2
- package/lib/types/commands/commands/delete-range-move-left.command.d.ts +1 -1
- package/lib/types/commands/commands/delete-range-move-up.command.d.ts +1 -1
- package/lib/types/commands/commands/insert-range-move-down.command.d.ts +1 -1
- package/lib/types/commands/commands/insert-range-move-right.command.d.ts +1 -1
- package/lib/types/commands/commands/insert-row-col.command.d.ts +7 -5
- package/lib/types/commands/commands/insert-sheet.command.d.ts +2 -2
- package/lib/types/commands/commands/remove-row-col.command.d.ts +1 -1
- package/lib/types/commands/commands/remove-sheet.command.d.ts +2 -2
- package/lib/types/commands/commands/set-col-visible.command.d.ts +2 -2
- package/lib/types/commands/commands/set-hide-gridlines.command.d.ts +2 -2
- package/lib/types/commands/commands/set-range-values.command.d.ts +5 -5
- package/lib/types/commands/commands/set-row-visible.command.d.ts +2 -2
- package/lib/types/commands/commands/set-style.command.d.ts +2 -2
- package/lib/types/commands/commands/set-worksheet-activate.command.d.ts +2 -2
- package/lib/types/commands/commands/set-worksheet-hide.command.d.ts +1 -1
- package/lib/types/commands/commands/set-worksheet-name.command.d.ts +2 -2
- package/lib/types/commands/commands/set-worksheet-order.command.d.ts +2 -2
- package/lib/types/commands/commands/set-worksheet-right-to-left.command.d.ts +2 -2
- package/lib/types/commands/commands/set-worksheet-row-height.command.d.ts +2 -1
- package/lib/types/commands/commands/utils/selection-utils.d.ts +42 -0
- package/lib/types/commands/mutations/delete-range.mutation.d.ts +1 -1
- package/lib/types/commands/mutations/insert-range.mutation.d.ts +2 -2
- package/lib/types/commands/mutations/move-range.mutation.d.ts +5 -5
- package/lib/types/commands/mutations/move-rows-cols.mutation.d.ts +4 -4
- package/lib/types/commands/mutations/numfmt-mutation.d.ts +5 -5
- package/lib/types/commands/mutations/set-col-visible.mutation.d.ts +8 -8
- package/lib/types/commands/mutations/set-frozen.mutation.d.ts +2 -2
- package/lib/types/commands/mutations/set-hide-gridlines.mutatiom.d.ts +2 -2
- package/lib/types/commands/mutations/set-range-values.mutation.d.ts +4 -4
- package/lib/types/commands/mutations/set-row-visible.mutation.d.ts +8 -8
- package/lib/types/commands/mutations/set-tab-color.mutation.d.ts +2 -2
- package/lib/types/commands/mutations/set-worksheet-col-width.mutation.d.ts +4 -5
- package/lib/types/commands/mutations/set-worksheet-config.mutation.d.ts +2 -2
- package/lib/types/commands/mutations/set-worksheet-hide.mutation.d.ts +2 -2
- package/lib/types/commands/mutations/set-worksheet-name.mutation.d.ts +2 -2
- package/lib/types/commands/mutations/set-worksheet-order.mutation.d.ts +2 -2
- package/lib/types/commands/mutations/set-worksheet-right-to-left.mutation.d.ts +2 -2
- package/lib/types/commands/mutations/set-worksheet-row-height.mutation.d.ts +9 -10
- package/lib/types/commands/operations/selection.operation.d.ts +2 -2
- package/lib/types/commands/operations/set-worksheet-active.operation.d.ts +2 -2
- package/lib/types/commands/utils/interface.d.ts +2 -2
- package/lib/types/index.d.ts +5 -5
- package/lib/types/locale/en-US.d.ts +5 -1
- package/lib/types/locale/zh-CN.d.ts +5 -1
- package/lib/types/services/numfmt/numfmt.service.d.ts +5 -5
- package/lib/types/services/numfmt/type.d.ts +7 -7
- package/lib/types/services/permission/permission-point.d.ts +3 -3
- package/lib/types/services/permission/sheet-permission.service.d.ts +3 -3
- package/lib/types/services/ref-range/ref-range.service.d.ts +3 -3
- package/lib/types/services/sheet-interceptor/utils/interceptor.d.ts +2 -2
- package/lib/umd/index.js +1 -3
- package/package.json +10 -12
- package/lib/types/commands/commands/utils/selection-util.d.ts +0 -66
|
@@ -16,24 +16,24 @@
|
|
|
16
16
|
import type { IMutation, IRange } from '@univerjs/core';
|
|
17
17
|
import type { IAccessor } from '@wendellhu/redi';
|
|
18
18
|
export interface ISetRowVisibleMutationParams {
|
|
19
|
-
|
|
20
|
-
|
|
19
|
+
unitId: string;
|
|
20
|
+
subUnitId: string;
|
|
21
21
|
ranges: IRange[];
|
|
22
22
|
}
|
|
23
23
|
export declare const SetRowVisibleUndoMutationFactory: (accessor: IAccessor, params: ISetRowVisibleMutationParams) => {
|
|
24
|
-
|
|
25
|
-
|
|
24
|
+
unitId: string;
|
|
25
|
+
subUnitId: string;
|
|
26
26
|
ranges: IRange[];
|
|
27
27
|
};
|
|
28
28
|
export declare const SetRowVisibleMutation: IMutation<ISetRowVisibleMutationParams>;
|
|
29
29
|
export interface ISetRowHiddenMutationParams {
|
|
30
|
-
|
|
31
|
-
|
|
30
|
+
unitId: string;
|
|
31
|
+
subUnitId: string;
|
|
32
32
|
ranges: IRange[];
|
|
33
33
|
}
|
|
34
34
|
export declare const SetRowHiddenUndoMutationFactory: (accessor: IAccessor, params: ISetRowHiddenMutationParams) => {
|
|
35
|
-
|
|
36
|
-
|
|
35
|
+
unitId: string;
|
|
36
|
+
subUnitId: string;
|
|
37
37
|
ranges: IRange[];
|
|
38
38
|
};
|
|
39
39
|
export declare const SetRowHiddenMutation: IMutation<ISetRowHiddenMutationParams>;
|
|
@@ -17,8 +17,8 @@ import type { IMutation } from '@univerjs/core';
|
|
|
17
17
|
import type { IAccessor } from '@wendellhu/redi';
|
|
18
18
|
export interface ISetTabColorMutationParams {
|
|
19
19
|
color: string;
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
unitId: string;
|
|
21
|
+
subUnitId: string;
|
|
22
22
|
}
|
|
23
23
|
export declare const SetTabColorUndoMutationFactory: (accessor: IAccessor, params: ISetTabColorMutationParams) => ISetTabColorMutationParams;
|
|
24
24
|
export declare const SetTabColorMutation: IMutation<ISetTabColorMutationParams>;
|
|
@@ -13,14 +13,13 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import type { IMutation, IRange } from '@univerjs/core';
|
|
17
|
-
import { ObjectArray } from '@univerjs/core';
|
|
16
|
+
import type { IMutation, IObjectArrayPrimitiveType, IRange, Nullable } from '@univerjs/core';
|
|
18
17
|
import type { IAccessor } from '@wendellhu/redi';
|
|
19
18
|
export interface ISetWorksheetColWidthMutationParams {
|
|
20
|
-
|
|
21
|
-
|
|
19
|
+
unitId: string;
|
|
20
|
+
subUnitId: string;
|
|
22
21
|
ranges: IRange[];
|
|
23
|
-
colWidth: number |
|
|
22
|
+
colWidth: number | IObjectArrayPrimitiveType<Nullable<number>>;
|
|
24
23
|
}
|
|
25
24
|
export declare const SetWorksheetColWidthMutationFactory: (accessor: IAccessor, params: ISetWorksheetColWidthMutationParams) => ISetWorksheetColWidthMutationParams;
|
|
26
25
|
export declare const SetWorksheetColWidthMutation: IMutation<ISetWorksheetColWidthMutationParams>;
|
|
@@ -17,8 +17,8 @@ import type { IMutation, IWorksheetData } from '@univerjs/core';
|
|
|
17
17
|
import type { IAccessor } from '@wendellhu/redi';
|
|
18
18
|
/** @deprecated */
|
|
19
19
|
export interface ISetWorksheetConfigMutationParams {
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
unitId: string;
|
|
21
|
+
subUnitId: string;
|
|
22
22
|
config: IWorksheetData;
|
|
23
23
|
}
|
|
24
24
|
/** @deprecated */
|
|
@@ -17,8 +17,8 @@ import type { BooleanNumber, IMutation } from '@univerjs/core';
|
|
|
17
17
|
import type { IAccessor } from '@wendellhu/redi';
|
|
18
18
|
export interface ISetWorksheetHideMutationParams {
|
|
19
19
|
hidden: BooleanNumber;
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
unitId: string;
|
|
21
|
+
subUnitId: string;
|
|
22
22
|
}
|
|
23
23
|
export declare const SetWorksheetHideMutationFactory: (accessor: IAccessor, params: ISetWorksheetHideMutationParams) => ISetWorksheetHideMutationParams;
|
|
24
24
|
export declare const SetWorksheetHideMutation: IMutation<ISetWorksheetHideMutationParams>;
|
|
@@ -17,8 +17,8 @@ import type { IMutation } from '@univerjs/core';
|
|
|
17
17
|
import type { IAccessor } from '@wendellhu/redi';
|
|
18
18
|
export interface ISetWorksheetNameMutationParams {
|
|
19
19
|
name: string;
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
unitId: string;
|
|
21
|
+
subUnitId: string;
|
|
22
22
|
}
|
|
23
23
|
export declare const SetWorksheetNameMutationFactory: (accessor: IAccessor, params: ISetWorksheetNameMutationParams) => ISetWorksheetNameMutationParams;
|
|
24
24
|
export declare const SetWorksheetNameMutation: IMutation<ISetWorksheetNameMutationParams>;
|
|
@@ -17,8 +17,8 @@ import type { IMutation } from '@univerjs/core';
|
|
|
17
17
|
import type { IAccessor } from '@wendellhu/redi';
|
|
18
18
|
export interface ISetWorksheetOrderMutationParams {
|
|
19
19
|
order: number;
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
unitId: string;
|
|
21
|
+
subUnitId: string;
|
|
22
22
|
}
|
|
23
23
|
export declare const SetWorksheetOrderUndoMutationFactory: (accessor: IAccessor, params: ISetWorksheetOrderMutationParams) => ISetWorksheetOrderMutationParams;
|
|
24
24
|
export declare const SetWorksheetOrderMutation: IMutation<ISetWorksheetOrderMutationParams>;
|
|
@@ -17,8 +17,8 @@ import type { BooleanNumber, IMutation } from '@univerjs/core';
|
|
|
17
17
|
import type { IAccessor } from '@wendellhu/redi';
|
|
18
18
|
export interface ISetWorksheetRightToLeftMutationParams {
|
|
19
19
|
rightToLeft: BooleanNumber;
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
unitId: string;
|
|
21
|
+
subUnitId: string;
|
|
22
22
|
}
|
|
23
23
|
export declare const SetWorksheetRightToLeftUndoMutationFactory: (accessor: IAccessor, params: ISetWorksheetRightToLeftMutationParams) => ISetWorksheetRightToLeftMutationParams;
|
|
24
24
|
export declare const SetWorksheetRightToLeftMutation: IMutation<ISetWorksheetRightToLeftMutationParams>;
|
|
@@ -13,25 +13,24 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import type { IMutation, IRange, Nullable } from '@univerjs/core';
|
|
17
|
-
import { ObjectArray } from '@univerjs/core';
|
|
16
|
+
import type { IMutation, IObjectArrayPrimitiveType, IRange, Nullable } from '@univerjs/core';
|
|
18
17
|
import type { IRowAutoHeightInfo } from '@univerjs/engine-render';
|
|
19
18
|
import type { IAccessor } from '@wendellhu/redi';
|
|
20
19
|
export interface ISetWorksheetRowHeightMutationParams {
|
|
21
|
-
|
|
22
|
-
|
|
20
|
+
unitId: string;
|
|
21
|
+
subUnitId: string;
|
|
23
22
|
ranges: IRange[];
|
|
24
|
-
rowHeight: number |
|
|
23
|
+
rowHeight: number | IObjectArrayPrimitiveType<Nullable<number>>;
|
|
25
24
|
}
|
|
26
25
|
export interface ISetWorksheetRowIsAutoHeightMutationParams {
|
|
27
|
-
|
|
28
|
-
|
|
26
|
+
unitId: string;
|
|
27
|
+
subUnitId: string;
|
|
29
28
|
ranges: IRange[];
|
|
30
|
-
autoHeightInfo: boolean |
|
|
29
|
+
autoHeightInfo: boolean | IObjectArrayPrimitiveType<Nullable<boolean>>;
|
|
31
30
|
}
|
|
32
31
|
export interface ISetWorksheetRowAutoHeightMutationParams {
|
|
33
|
-
|
|
34
|
-
|
|
32
|
+
unitId: string;
|
|
33
|
+
subUnitId: string;
|
|
35
34
|
rowsAutoHeightInfo: IRowAutoHeightInfo[];
|
|
36
35
|
}
|
|
37
36
|
export declare const SetWorksheetRowHeightMutationFactory: (accessor: IAccessor, params: ISetWorksheetRowHeightMutationParams) => ISetWorksheetRowHeightMutationParams;
|
|
@@ -17,8 +17,8 @@ import type { IOperation } from '@univerjs/core';
|
|
|
17
17
|
import type { ISelectionWithStyle } from '../../basics/selection';
|
|
18
18
|
import type { SelectionMoveType } from '../../services/selection-manager.service';
|
|
19
19
|
export interface ISetSelectionsOperationParams {
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
unitId: string;
|
|
21
|
+
subUnitId: string;
|
|
22
22
|
pluginName: string;
|
|
23
23
|
selections: ISelectionWithStyle[];
|
|
24
24
|
type?: SelectionMoveType;
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
*/
|
|
16
16
|
import type { IOperation } from '@univerjs/core';
|
|
17
17
|
export interface ISetWorksheetActiveOperationParams {
|
|
18
|
-
|
|
19
|
-
|
|
18
|
+
unitId: string;
|
|
19
|
+
subUnitId: string;
|
|
20
20
|
}
|
|
21
21
|
export declare const SetWorksheetActiveOperation: IOperation<ISetWorksheetActiveOperationParams>;
|
package/lib/types/index.d.ts
CHANGED
|
@@ -17,7 +17,7 @@ export { type IUniverSheetsConfig, UniverSheetsPlugin } from './sheets-plugin';
|
|
|
17
17
|
export { COMMAND_LISTENER_SKELETON_CHANGE, COMMAND_LISTENER_VALUE_CHANGE } from './basics/const/command-listener-const';
|
|
18
18
|
export { type IAddWorksheetMergeMutationParams, type IDeleteRangeMutationParams, type IInsertColMutationParams, type IInsertRangeMutationParams, type IInsertRowMutationParams, type IInsertSheetMutationParams, type IRemoveColMutationParams, type IRemoveRowsMutationParams, type IRemoveSheetMutationParams, type IRemoveWorksheetMergeMutationParams, } from './basics/interfaces/mutation-interface';
|
|
19
19
|
export { convertPrimaryWithCoordToPrimary, convertSelectionDataToRange, getNormalSelectionStyle, type ISelectionStyle, type ISelectionWidgetConfig, type ISelectionWithCoordAndStyle, type ISelectionWithStyle, SELECTION_CONTROL_BORDER_BUFFER_COLOR, SELECTION_CONTROL_BORDER_BUFFER_WIDTH, transformCellDataToSelectionData, } from './basics/selection';
|
|
20
|
-
export {
|
|
20
|
+
export { alignToMergedCellsBorders, getCellAtRowCol } from './commands/commands/utils/selection-utils';
|
|
21
21
|
export { MAX_CELL_PER_SHEET_KEY } from './controllers/config/config';
|
|
22
22
|
export { BorderStyleManagerService, type IBorderInfo } from './services/border-style-manager.service';
|
|
23
23
|
export { SheetEditablePermission, SheetPermissionService } from './services/permission';
|
|
@@ -37,6 +37,7 @@ export { InsertRangeMoveRightCommand } from './commands/commands/insert-range-mo
|
|
|
37
37
|
export { type InsertRangeMoveRightCommandParams } from './commands/commands/insert-range-move-right.command';
|
|
38
38
|
export type { IInsertColCommandParams, IInsertRowCommandParams } from './commands/commands/insert-row-col.command';
|
|
39
39
|
export { InsertColAfterCommand, InsertColBeforeCommand, InsertColCommand, InsertRowAfterCommand, InsertRowBeforeCommand, InsertRowCommand, } from './commands/commands/insert-row-col.command';
|
|
40
|
+
export type { IInsertSheetCommandParams } from './commands/commands/insert-sheet.command';
|
|
40
41
|
export { InsertSheetCommand } from './commands/commands/insert-sheet.command';
|
|
41
42
|
export { type IMoveRangeCommandParams, MoveRangeCommand } from './commands/commands/move-range.command';
|
|
42
43
|
export { type IMoveColsCommandParams, type IMoveRowsCommandParams, MoveColsCommand, MoveRowsCommand, } from './commands/commands/move-rows-cols.command';
|
|
@@ -53,15 +54,14 @@ export { type ISetRangeValuesCommandParams, SetRangeValuesCommand } from './comm
|
|
|
53
54
|
export { type ISetSpecificRowsVisibleCommandParams, SetRowHiddenCommand, SetSelectedRowsVisibleCommand, SetSpecificRowsVisibleCommand, } from './commands/commands/set-row-visible.command';
|
|
54
55
|
export { type ISetStyleCommandParams, ResetBackgroundColorCommand, ResetTextColorCommand, SetBackgroundColorCommand, SetBoldCommand, SetFontFamilyCommand, SetFontSizeCommand, SetHorizontalTextAlignCommand, SetItalicCommand, SetStrikeThroughCommand, SetStyleCommand, SetTextColorCommand, SetTextRotationCommand, SetTextWrapCommand, SetUnderlineCommand, SetVerticalTextAlignCommand, } from './commands/commands/set-style.command';
|
|
55
56
|
export { SetTabColorCommand } from './commands/commands/set-tab-color.command';
|
|
56
|
-
export { SetWorksheetActivateCommand } from './commands/commands/set-worksheet-activate.command';
|
|
57
|
+
export { type ISetWorksheetActivateCommandParams, SetWorksheetActivateCommand, } from './commands/commands/set-worksheet-activate.command';
|
|
57
58
|
export { DeltaColumnWidthCommand, type IDeltaColumnWidthCommandParams, SetColWidthCommand, } from './commands/commands/set-worksheet-col-width.command';
|
|
58
59
|
export { SetWorksheetHideCommand } from './commands/commands/set-worksheet-hide.command';
|
|
59
60
|
export { type ISetWorksheetNameCommandParams, SetWorksheetNameCommand, } from './commands/commands/set-worksheet-name.command';
|
|
60
61
|
export { SetWorksheetOrderCommand } from './commands/commands/set-worksheet-order.command';
|
|
61
|
-
export { DeltaRowHeightCommand, type IDeltaRowHeightCommand, SetRowHeightCommand, SetWorksheetRowIsAutoHeightCommand, } from './commands/commands/set-worksheet-row-height.command';
|
|
62
|
+
export { DeltaRowHeightCommand, type IDeltaRowHeightCommand, type ISetWorksheetRowIsAutoHeightCommandParams, SetRowHeightCommand, SetWorksheetRowIsAutoHeightCommand, } from './commands/commands/set-worksheet-row-height.command';
|
|
62
63
|
export { SetWorksheetShowCommand } from './commands/commands/set-worksheet-show.command';
|
|
63
|
-
export { getPrimaryForRange } from './commands/commands/utils/selection-
|
|
64
|
-
export { findNextGapRange, findNextRange, getCellAtRowCol, getStartRange, } from './commands/commands/utils/selection-util';
|
|
64
|
+
export { getPrimaryForRange } from './commands/commands/utils/selection-utils';
|
|
65
65
|
export { AddMergeUndoMutationFactory, AddWorksheetMergeMutation, } from './commands/mutations/add-worksheet-merge.mutation';
|
|
66
66
|
export { DeleteRangeMutation } from './commands/mutations/delete-range.mutation';
|
|
67
67
|
export { handleDeleteRangeMutation } from './commands/mutations/delete-range.mutation';
|
|
@@ -36,16 +36,16 @@ export declare class NumfmtService extends Disposable implements INumfmtService
|
|
|
36
36
|
private _parseJson;
|
|
37
37
|
private _setValue;
|
|
38
38
|
private _getUniqueRefId;
|
|
39
|
-
getValue(
|
|
39
|
+
getValue(unitId: string, subUnitId: string, row: number, col: number, model?: ObjectMatrix<INumfmtItem>): {
|
|
40
40
|
pattern: string;
|
|
41
41
|
type: FormatType;
|
|
42
42
|
} | null;
|
|
43
|
-
deleteValues(
|
|
44
|
-
setValues(
|
|
43
|
+
deleteValues(unitId: string, subUnitId: string, values: IRange[]): void;
|
|
44
|
+
setValues(unitId: string, subUnitId: string, values: Array<{
|
|
45
45
|
ranges: IRange[];
|
|
46
46
|
pattern: string;
|
|
47
47
|
type: FormatType;
|
|
48
48
|
}>): void;
|
|
49
|
-
getModel(
|
|
50
|
-
getRefModel(
|
|
49
|
+
getModel(unitId: string, subUnitId: string): ObjectMatrix<INumfmtItem> | undefined;
|
|
50
|
+
getRefModel(unitId: string): RefAlias<IRefItem, "i" | "pattern"> | undefined;
|
|
51
51
|
}
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import type { ICellData, IRange, Nullable, ObjectMatrix,
|
|
16
|
+
import type { ICellData, IObjectMatrixPrimitiveType, IRange, Nullable, ObjectMatrix, RefAlias } from '@univerjs/core';
|
|
17
17
|
import type { Observable } from 'rxjs';
|
|
18
18
|
export type INumfmtItem = {
|
|
19
19
|
i: string;
|
|
@@ -33,19 +33,19 @@ export type IRefItem = INumfmtItem & {
|
|
|
33
33
|
pattern: string;
|
|
34
34
|
};
|
|
35
35
|
export interface INumfmtService {
|
|
36
|
-
getValue(
|
|
37
|
-
getModel(
|
|
38
|
-
setValues(
|
|
36
|
+
getValue(unitId: string, subUnitId: string, row: number, col: number, model?: ObjectMatrix<INumfmtItem>): Nullable<INumfmtItemWithCache>;
|
|
37
|
+
getModel(unitId: string, subUnitId: string): Nullable<ObjectMatrix<INumfmtItem>>;
|
|
38
|
+
setValues(unitId: string, subUnitId: string, values: Array<{
|
|
39
39
|
ranges: IRange[];
|
|
40
40
|
pattern: string;
|
|
41
41
|
type: FormatType;
|
|
42
42
|
}>): void;
|
|
43
|
-
deleteValues(
|
|
44
|
-
getRefModel(
|
|
43
|
+
deleteValues(unitId: string, subUnitId: string, values: IRange[]): void;
|
|
44
|
+
getRefModel(unitId: string): Nullable<RefAlias<IRefItem, 'i' | 'pattern'>>;
|
|
45
45
|
modelReplace$: Observable<string>;
|
|
46
46
|
}
|
|
47
47
|
export interface ISnapshot {
|
|
48
|
-
model: Record<string,
|
|
48
|
+
model: Record<string, IObjectMatrixPrimitiveType<INumfmtItem>>;
|
|
49
49
|
refModel: IRefItem[];
|
|
50
50
|
}
|
|
51
51
|
export declare const INumfmtService: import("@wendellhu/redi").IdentifierDecorator<INumfmtService>;
|
|
@@ -15,10 +15,10 @@
|
|
|
15
15
|
*/
|
|
16
16
|
import { PermissionPoint } from '@univerjs/core';
|
|
17
17
|
export declare class SheetEditablePermission extends PermissionPoint<boolean> {
|
|
18
|
-
private
|
|
19
|
-
private
|
|
18
|
+
private _unitId;
|
|
19
|
+
private _subUnitId;
|
|
20
20
|
id: string;
|
|
21
21
|
value: boolean;
|
|
22
22
|
unitID: string;
|
|
23
|
-
constructor(
|
|
23
|
+
constructor(_unitId: string, _subUnitId: string);
|
|
24
24
|
}
|
|
@@ -23,10 +23,10 @@ export declare class SheetPermissionService extends Disposable {
|
|
|
23
23
|
constructor(_permissionService: PermissionService, _univerInstanceService: IUniverInstanceService, _sheetInterceptorService: SheetInterceptorService);
|
|
24
24
|
private _init;
|
|
25
25
|
private _interceptCommandPermission;
|
|
26
|
-
getEditable$(
|
|
26
|
+
getEditable$(unitId?: string, sheetId?: string): import("rxjs").Observable<{
|
|
27
27
|
value: any;
|
|
28
28
|
status: import("@univerjs/core").PermissionStatus;
|
|
29
29
|
}>;
|
|
30
|
-
getSheetEditable(
|
|
31
|
-
setSheetEditable(v: boolean,
|
|
30
|
+
getSheetEditable(unitId?: string, sheetId?: string): boolean;
|
|
31
|
+
setSheetEditable(v: boolean, unitId?: string, sheetId?: string): void;
|
|
32
32
|
}
|
|
@@ -43,10 +43,10 @@ export declare class RefRangeService extends Disposable {
|
|
|
43
43
|
* Listens to an area and triggers a fall back when movement occurs
|
|
44
44
|
* @param {IRange} range the area that needs to be monitored
|
|
45
45
|
* @param {RefRangCallback} callback the callback function that is executed when the range changes
|
|
46
|
-
* @param {string} [
|
|
47
|
-
* @param {string} [
|
|
46
|
+
* @param {string} [_unitId]
|
|
47
|
+
* @param {string} [_subUnitId]
|
|
48
48
|
* @memberof RefRangeService
|
|
49
49
|
*/
|
|
50
|
-
registerRefRange: (range: IRange, callback: RefRangCallback,
|
|
50
|
+
registerRefRange: (range: IRange, callback: RefRangCallback, _unitId?: string, _subUnitId?: string) => IDisposable;
|
|
51
51
|
}
|
|
52
52
|
export {};
|
|
@@ -17,8 +17,8 @@ import type { Workbook, Worksheet } from '@univerjs/core';
|
|
|
17
17
|
export interface ISheetLocation {
|
|
18
18
|
workbook: Workbook;
|
|
19
19
|
worksheet: Worksheet;
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
unitId: string;
|
|
21
|
+
subUnitId: string;
|
|
22
22
|
row: number;
|
|
23
23
|
col: number;
|
|
24
24
|
}
|