@univerjs/sheets 0.2.6 → 0.2.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.
- package/lib/cjs/index.js +2 -2
- package/lib/es/index.js +208 -81
- package/lib/types/basics/cell-style.d.ts +0 -1
- package/lib/types/basics/cell-type.d.ts +0 -1
- package/lib/types/basics/cell-value.d.ts +0 -1
- package/lib/types/basics/const/default-spreadsheet-plugin-data.d.ts +0 -1
- package/lib/types/basics/interfaces/i-ruler-manager.d.ts +0 -1
- package/lib/types/basics/interfaces/mutation-interface.d.ts +0 -1
- package/lib/types/basics/interfaces/selection-config.d.ts +0 -1
- package/lib/types/basics/interfaces/spreadsheet-config.d.ts +0 -1
- package/lib/types/basics/rangeMerge.d.ts +0 -1
- package/lib/types/basics/selection.d.ts +0 -1
- package/lib/types/basics/sheet-header.d.ts +0 -1
- package/lib/types/basics/utils.d.ts +0 -1
- package/lib/types/commands/commands/__tests__/create-command-test-bed.d.ts +0 -1
- package/lib/types/commands/commands/add-range-protection.command.d.ts +0 -1
- package/lib/types/commands/commands/add-worksheet-merge.command.d.ts +0 -1
- package/lib/types/commands/commands/clear-selection-all.command.d.ts +0 -1
- package/lib/types/commands/commands/clear-selection-content.command.d.ts +0 -1
- package/lib/types/commands/commands/clear-selection-format.command.d.ts +0 -1
- package/lib/types/commands/commands/copy-worksheet.command.d.ts +0 -1
- package/lib/types/commands/commands/delete-range-move-left.command.d.ts +0 -1
- package/lib/types/commands/commands/delete-range-move-up.command.d.ts +0 -1
- package/lib/types/commands/commands/delete-range-protection.command.d.ts +0 -1
- package/lib/types/commands/commands/insert-defined-name.command.d.ts +0 -1
- package/lib/types/commands/commands/insert-range-move-down.command.d.ts +0 -1
- package/lib/types/commands/commands/insert-range-move-right.command.d.ts +0 -1
- package/lib/types/commands/commands/insert-row-col.command.d.ts +0 -1
- package/lib/types/commands/commands/insert-sheet.command.d.ts +0 -1
- package/lib/types/commands/commands/move-range.command.d.ts +0 -1
- package/lib/types/commands/commands/move-rows-cols.command.d.ts +0 -1
- package/lib/types/commands/commands/remove-defined-name.command.d.ts +0 -1
- package/lib/types/commands/commands/remove-row-col.command.d.ts +0 -1
- package/lib/types/commands/commands/remove-sheet.command.d.ts +0 -1
- package/lib/types/commands/commands/remove-worksheet-merge.command.d.ts +0 -1
- package/lib/types/commands/commands/reorder-range.command.d.ts +0 -1
- package/lib/types/commands/commands/set-border-command.d.ts +0 -1
- package/lib/types/commands/commands/set-col-visible.command.d.ts +0 -1
- package/lib/types/commands/commands/set-defined-name.command.d.ts +0 -1
- package/lib/types/commands/commands/set-frozen-cancel.command.d.ts +0 -1
- package/lib/types/commands/commands/set-frozen.command.d.ts +0 -1
- package/lib/types/commands/commands/set-hide-gridlines.command.d.ts +0 -1
- package/lib/types/commands/commands/set-range-protection.command.d.ts +0 -1
- package/lib/types/commands/commands/set-range-values.command.d.ts +0 -1
- package/lib/types/commands/commands/set-row-visible.command.d.ts +0 -1
- package/lib/types/commands/commands/set-style.command.d.ts +0 -1
- package/lib/types/commands/commands/set-tab-color.command.d.ts +0 -1
- package/lib/types/commands/commands/set-workbook-name.command.d.ts +0 -1
- package/lib/types/commands/commands/set-worksheet-activate.command.d.ts +0 -1
- package/lib/types/commands/commands/set-worksheet-col-width.command.d.ts +0 -1
- package/lib/types/commands/commands/set-worksheet-hide.command.d.ts +0 -1
- package/lib/types/commands/commands/set-worksheet-name.command.d.ts +0 -1
- package/lib/types/commands/commands/set-worksheet-order.command.d.ts +0 -1
- package/lib/types/commands/commands/set-worksheet-permission-points.command.d.ts +0 -1
- package/lib/types/commands/commands/set-worksheet-right-to-left.command.d.ts +0 -1
- package/lib/types/commands/commands/set-worksheet-row-height.command.d.ts +0 -1
- package/lib/types/commands/commands/set-worksheet-show.command.d.ts +0 -1
- package/lib/types/commands/commands/utils/merged-cell-util.d.ts +0 -1
- package/lib/types/commands/commands/utils/selection-utils.d.ts +0 -1
- package/lib/types/commands/commands/utils/target-util.d.ts +0 -1
- package/lib/types/commands/mutations/__tests__/create-command-test-bed.d.ts +0 -1
- package/lib/types/commands/mutations/add-range-protection.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/add-worksheet-merge.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/add-worksheet-protection.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/delete-range-protection.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/delete-worksheet-protection.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/empty.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/insert-row-col.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/insert-sheet.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/move-range.mutation.d.ts +3 -2
- package/lib/types/commands/mutations/move-rows-cols.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/numfmt-mutation.d.ts +0 -1
- package/lib/types/commands/mutations/remove-row-col.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/remove-sheet.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/remove-worksheet-merge.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/reorder-range.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/set-col-visible.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/set-frozen.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/set-hide-gridlines.mutatiom.d.ts +0 -1
- package/lib/types/commands/mutations/set-range-protection.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/set-range-values.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/set-row-visible.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/set-tab-color.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/set-workbook-name.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/set-worksheet-col-width.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/set-worksheet-hide.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/set-worksheet-name.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/set-worksheet-order.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/set-worksheet-permission-points.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/set-worksheet-protection.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/set-worksheet-right-to-left.mutation.d.ts +0 -1
- package/lib/types/commands/mutations/set-worksheet-row-height.mutation.d.ts +0 -1
- package/lib/types/commands/operations/scroll-to-cell.operation.d.ts +0 -1
- package/lib/types/commands/operations/selection.operation.d.ts +0 -1
- package/lib/types/commands/operations/set-worksheet-active.operation.d.ts +0 -1
- package/lib/types/commands/utils/handle-merge-operation.d.ts +0 -1
- package/lib/types/commands/utils/handle-range-mutation.d.ts +0 -1
- package/lib/types/commands/utils/selection-command-util.d.ts +0 -1
- package/lib/types/controllers/__tests__/util.d.ts +0 -1
- package/lib/types/controllers/basic-worksheet.controller.d.ts +0 -1
- package/lib/types/controllers/calculate-result-apply.controller.d.ts +0 -1
- package/lib/types/controllers/defined-name-data.controller.d.ts +0 -1
- package/lib/types/controllers/merge-cell.controller.d.ts +5 -2
- package/lib/types/controllers/number-cell.controller.d.ts +0 -1
- package/lib/types/index.d.ts +3 -2
- package/lib/types/locale/en-US.d.ts +0 -1
- package/lib/types/locale/ru-RU.d.ts +0 -1
- package/lib/types/locale/vi-VN.d.ts +0 -1
- package/lib/types/locale/zh-TW.d.ts +0 -1
- package/lib/types/model/range-protection-render.model.d.ts +0 -1
- package/lib/types/model/range-protection-rule.model.d.ts +1 -2
- package/lib/types/services/__tests__/util.d.ts +0 -1
- package/lib/types/services/border-style-manager.service.d.ts +0 -1
- package/lib/types/services/numfmt/numfmt.service.d.ts +0 -1
- package/lib/types/services/numfmt/type.d.ts +0 -1
- package/lib/types/services/permission/permission-point/range/edit.d.ts +0 -1
- package/lib/types/services/permission/permission-point/range/view.d.ts +0 -1
- package/lib/types/services/permission/permission-point/workbook/comment.d.ts +0 -1
- package/lib/types/services/permission/permission-point/workbook/copy-sheet.d.ts +0 -1
- package/lib/types/services/permission/permission-point/workbook/copy.d.ts +0 -1
- package/lib/types/services/permission/permission-point/workbook/create-sheet.d.ts +0 -1
- package/lib/types/services/permission/permission-point/workbook/delete-sheet.d.ts +0 -1
- package/lib/types/services/permission/permission-point/workbook/duplicate.d.ts +0 -1
- package/lib/types/services/permission/permission-point/workbook/editable.d.ts +0 -1
- package/lib/types/services/permission/permission-point/workbook/export.d.ts +0 -1
- package/lib/types/services/permission/permission-point/workbook/hide-sheet.d.ts +0 -1
- package/lib/types/services/permission/permission-point/workbook/history.d.ts +0 -1
- package/lib/types/services/permission/permission-point/workbook/manage-collaborator.d.ts +0 -1
- package/lib/types/services/permission/permission-point/workbook/move-sheet.d.ts +0 -1
- package/lib/types/services/permission/permission-point/workbook/print.d.ts +0 -1
- package/lib/types/services/permission/permission-point/workbook/recover-history.d.ts +0 -1
- package/lib/types/services/permission/permission-point/workbook/rename-sheet.d.ts +0 -1
- package/lib/types/services/permission/permission-point/workbook/share.d.ts +0 -1
- package/lib/types/services/permission/permission-point/workbook/view-history.d.ts +0 -1
- package/lib/types/services/permission/permission-point/workbook/view.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/copy.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/delete-column.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/delete-row.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/edit-extra-object.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/edit.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/filter.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/insert-column.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/insert-hyperlink.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/insert-row.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/manage-collaborator.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/pivot-table.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/select-protected-cells.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/select-un-protected-cells.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/set-cell-style.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/set-cell-value.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/set-column-style.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/set-row-style.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/sort.d.ts +0 -1
- package/lib/types/services/permission/permission-point/worksheet/view.d.ts +0 -1
- package/lib/types/services/permission/range-permission/range-protection.ref-range.d.ts +0 -1
- package/lib/types/services/permission/range-permission/range-protection.service.d.ts +0 -1
- package/lib/types/services/permission/range-permission/util.d.ts +0 -1
- package/lib/types/services/permission/type.d.ts +0 -1
- package/lib/types/services/permission/util.d.ts +2 -0
- package/lib/types/services/permission/workbook-permission/util.d.ts +0 -1
- package/lib/types/services/permission/workbook-permission/workbook-permission.service.d.ts +0 -1
- package/lib/types/services/permission/worksheet-permission/type.d.ts +0 -1
- package/lib/types/services/permission/worksheet-permission/utils.d.ts +0 -1
- package/lib/types/services/permission/worksheet-permission/worksheet-permission-point.model.d.ts +1 -2
- package/lib/types/services/permission/worksheet-permission/worksheet-permission-rule.model.d.ts +1 -2
- package/lib/types/services/permission/worksheet-permission/worksheet-permission.service.d.ts +0 -1
- package/lib/types/services/ref-range/__tests__/__testing__.d.ts +0 -1
- package/lib/types/services/ref-range/__tests__/ref-range.service.spec.d.ts +0 -1
- package/lib/types/services/ref-range/ref-range.service.d.ts +0 -1
- package/lib/types/services/ref-range/type.d.ts +0 -1
- package/lib/types/services/ref-range/util.d.ts +0 -1
- package/lib/types/services/selections/ref-selections.service.d.ts +0 -1
- package/lib/types/services/selections/selection-manager.service.d.ts +0 -1
- package/lib/types/services/sheet-interceptor/__tests__/create-core-test-bed.d.ts +0 -1
- package/lib/types/services/sheet-interceptor/interceptor-const.d.ts +0 -1
- package/lib/types/services/sheet-interceptor/sheet-interceptor.service.d.ts +31 -3
- package/lib/types/services/sheet-interceptor/utils/interceptor.d.ts +0 -1
- package/lib/types/sheets-plugin.d.ts +0 -1
- package/lib/umd/index.js +2 -2
- package/package.json +14 -13
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { CellValue, ICellData, Nullable, Styles, CellValueType } from '@univerjs/core';
|
|
2
|
-
|
|
3
2
|
/**
|
|
4
3
|
* Get cell value type by style, new value and old value.
|
|
5
4
|
* If the new value contains t, then take t directly. In other cases, we need to dynamically determine based on actual data and styles
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { Dimension, ICellData, IColumnData, IObjectArrayPrimitiveType, IObjectMatrixPrimitiveType, IRange, IRowData, IWorksheetData, Nullable } from '@univerjs/core';
|
|
2
|
-
|
|
3
2
|
/** Params of `RemoveSheetMutation` */
|
|
4
3
|
export interface IRemoveSheetMutationParams {
|
|
5
4
|
subUnitId: string;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { IRange, ObjectMatrix } from '@univerjs/core';
|
|
2
|
-
|
|
3
2
|
export declare const createTopMatrixFromRanges: (ranges: IRange[]) => ObjectMatrix<number>;
|
|
4
3
|
export declare const createTopMatrixFromMatrix: (matrix: ObjectMatrix<1>) => ObjectMatrix<number>;
|
|
5
4
|
export declare const findAllRectangle: (topMatrix: ObjectMatrix<number>) => IRange[];
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { IRange, ISelection, ISelectionCellWithMergeInfo, ISelectionWithCoord, Nullable, ThemeService } from '@univerjs/core';
|
|
2
|
-
|
|
3
2
|
export declare const SELECTION_CONTROL_BORDER_BUFFER_WIDTH = 1.5;
|
|
4
3
|
export declare const SELECTION_CONTROL_BORDER_BUFFER_COLOR = "rgba(255, 255, 255, 0.01)";
|
|
5
4
|
/**
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { ICellData, IObjectMatrixPrimitiveType, IRange, Nullable, UniverInstanceService, Workbook, Worksheet } from '@univerjs/core';
|
|
2
2
|
import { IExpandParams } from '../commands/commands/utils/selection-utils';
|
|
3
|
-
|
|
4
3
|
export declare const groupByKey: <T = Record<string, unknown>>(arr: T[], key: string, blankKey?: string) => Record<string, T[]>;
|
|
5
4
|
export declare const createUniqueKey: (initValue?: number) => () => number;
|
|
6
5
|
export declare function expandToContinuousRange(startRange: IRange, directions: IExpandParams, worksheet: Worksheet): IRange;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { ICellData, ICommand, IObjectMatrixPrimitiveType, IRange } from '@univerjs/core';
|
|
2
2
|
import { ISheetCommandSharedParams } from '../utils/interface';
|
|
3
|
-
|
|
4
3
|
export interface ISetRangeValuesCommandParams extends Partial<ISheetCommandSharedParams> {
|
|
5
4
|
range?: IRange;
|
|
6
5
|
/**
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { IRange, ISelectionCell, Nullable, Workbook, Worksheet } from '@univerjs/core';
|
|
2
2
|
import { ISetSelectionsOperationParams } from '../../operations/selection.operation';
|
|
3
3
|
import { ISelectionWithStyle } from '../../../basics/selection';
|
|
4
|
-
|
|
5
4
|
export interface IExpandParams {
|
|
6
5
|
left?: boolean;
|
|
7
6
|
right?: boolean;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { IMutation, IMutationInfo } from '@univerjs/core';
|
|
2
2
|
import { IRangeProtectionRule } from '../../model/range-protection-rule.model';
|
|
3
3
|
import { IDeleteSelectionProtectionMutationParams } from './delete-range-protection.mutation';
|
|
4
|
-
|
|
5
4
|
export interface IAddRangeProtectionMutationParams {
|
|
6
5
|
rules: IRangeProtectionRule[];
|
|
7
6
|
unitId: string;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { IAccessor, IMutation } from '@univerjs/core';
|
|
2
2
|
import { IAddWorksheetMergeMutationParams, IRemoveWorksheetMergeMutationParams } from '../../basics/interfaces/mutation-interface';
|
|
3
|
-
|
|
4
3
|
export declare const AddMergeUndoMutationFactory: (accessor: IAccessor, params: IAddWorksheetMergeMutationParams) => IRemoveWorksheetMergeMutationParams;
|
|
5
4
|
export declare const AddWorksheetMergeMutation: IMutation<IAddWorksheetMergeMutationParams>;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { IAccessor, IMutation } from '@univerjs/core';
|
|
2
2
|
import { IInsertColMutationParams, IInsertRowMutationParams, IRemoveColMutationParams, IRemoveRowsMutationParams } from '../../basics/interfaces/mutation-interface';
|
|
3
|
-
|
|
4
3
|
export declare const InsertRowMutationUndoFactory: (accessor: IAccessor, params: IInsertRowMutationParams) => IRemoveRowsMutationParams;
|
|
5
4
|
export declare const InsertRowMutation: IMutation<IInsertRowMutationParams>;
|
|
6
5
|
export declare const InsertColMutationUndoFactory: (accessor: IAccessor, params: IInsertColMutationParams) => IRemoveColMutationParams;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import { ICellData, IMutation, IObjectMatrixPrimitiveType, Nullable } from '@univerjs/core';
|
|
2
|
-
|
|
1
|
+
import { ICellData, IMutation, IObjectMatrixPrimitiveType, IRange, Nullable } from '@univerjs/core';
|
|
3
2
|
export interface IMoveRangeMutationParams {
|
|
4
3
|
unitId: string;
|
|
4
|
+
fromRange: IRange;
|
|
5
|
+
toRange: IRange;
|
|
5
6
|
from: {
|
|
6
7
|
subUnitId: string;
|
|
7
8
|
value: IObjectMatrixPrimitiveType<Nullable<ICellData>>;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { IAccessor, ICommand, IMutationInfo, IRange } from '@univerjs/core';
|
|
2
|
-
|
|
3
2
|
export declare const factorySetNumfmtUndoMutation: (accessor: IAccessor, option: ISetNumfmtMutationParams) => IMutationInfo<ISetNumfmtMutationParams | IRemoveNumfmtMutationParams>[];
|
|
4
3
|
export interface ISetNumfmtMutationParams {
|
|
5
4
|
values: {
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { IAccessor, IMutation, Worksheet } from '@univerjs/core';
|
|
2
2
|
import { IInsertColMutationParams, IInsertRowMutationParams, IRemoveColMutationParams, IRemoveRowsMutationParams } from '../../basics/interfaces/mutation-interface';
|
|
3
|
-
|
|
4
3
|
export declare const RemoveRowsUndoMutationFactory: (params: IRemoveRowsMutationParams, worksheet: Worksheet) => IInsertRowMutationParams;
|
|
5
4
|
export declare const RemoveRowMutation: IMutation<IRemoveRowsMutationParams>;
|
|
6
5
|
export declare const RemoveColMutationFactory: (accessor: IAccessor, params: IRemoveColMutationParams) => IInsertColMutationParams;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { IAccessor, IMutation } from '@univerjs/core';
|
|
2
2
|
import { IAddWorksheetMergeMutationParams, IRemoveWorksheetMergeMutationParams } from '../../basics/interfaces/mutation-interface';
|
|
3
|
-
|
|
4
3
|
export declare const RemoveMergeUndoMutationFactory: (accessor: IAccessor, params: IRemoveWorksheetMergeMutationParams) => IAddWorksheetMergeMutationParams;
|
|
5
4
|
export declare const RemoveWorksheetMergeMutation: IMutation<IRemoveWorksheetMergeMutationParams>;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { IAccessor, ICellData, ICopyToOptionsData, IMutation, IMutationCommonParams, IObjectMatrixPrimitiveType, IRange, Nullable } from '@univerjs/core';
|
|
2
|
-
|
|
3
2
|
/** Params of `SetRangeValuesMutation` */
|
|
4
3
|
export interface ISetRangeValuesMutationParams extends IMutationCommonParams {
|
|
5
4
|
subUnitId: string;
|