API Reference
@univerjs
@univerjs/sheets
Readme

@univerjs/sheets v0.1.17Docs


@univerjs/sheets

Enumerations

EnumerationDescription
OperatorType-
SelectionMoveType-

Classes

ClassDescription
BorderStyleManagerServiceThis service is for managing settings border style status.
DefinedNameDataController-
MergeCellController-
NumfmtService-
RangeMergeUtil-
RangeProtectionPermissionEditPoint-
RangeProtectionPermissionViewPoint-
RangeProtectionRefRangeService-
RangeProtectionRenderModel-
RangeProtectionRuleModel-
RangeProtectionService-
RefRangeServiceCollect side effects caused by ref range change
SelectionManagerServiceThis service is responsible for managing the selection data.
SheetInterceptorServiceThis class expose methods for sheet features to inject code to sheet underlying logic.
UniverSheetsPluginThe main sheet base, construct the sheet container and layout, mount the rendering engine
WorkbookCommentPermission-
WorkbookCopyPermission-
WorkbookCopySheetPermission-
WorkbookCreateSheetPermission-
WorkbookDeleteSheetPermission-
WorkbookDuplicatePermission-
WorkbookEditablePermission-
WorkbookExportPermission-
WorkbookHideSheetPermission-
WorkbookHistoryPermission-
WorkbookManageCollaboratorPermission-
WorkbookMoveSheetPermission-
WorkbookPermissionService-
WorkbookPrintPermission-
WorkbookRenameSheetPermission-
WorkbookSharePermission-
WorkbookViewPermission-
WorksheetCopyPermission-
WorksheetDeleteColumnPermission-
WorksheetDeleteRowPermission-
WorksheetEditExtraObjectPermission-
WorksheetEditPermission-
WorksheetFilterPermission-
WorksheetInsertColumnPermission-
WorksheetInsertHyperlinkPermission-
WorksheetInsertRowPermission-
WorksheetManageCollaboratorPermission-
WorksheetPermissionService-
WorksheetPivotTablePermission-
WorksheetProtectionPointModel-
WorksheetProtectionRuleModel-
WorksheetSelectProtectedCellsPermission-
WorksheetSelectUnProtectedCellsPermission-
WorksheetSetCellStylePermission-
WorksheetSetCellValuePermission-
WorksheetSetColumnStylePermission-
WorksheetSetRowStylePermission-
WorksheetSortPermission-
WorksheetViewPermission-

Interfaces

InterfaceDescription
IAddRangeProtectionCommandParams-
IAddRangeProtectionMutationParams-
IAddWorksheetMergeMutationParamsParams of AddWorksheetMergeMutation
IAddWorksheetProtectionParams-
IBorderInfo-
IDeleteRangeMoveLeftCommandParams-
IDeleteRangeMoveUpCommandParams-
IDeleteRangeMutationParamsParams of DeleteRange
IDeleteRangeProtectionCommandParams-
IDeleteSelectionProtectionMutationParams-
IDeltaColumnWidthCommandParams-
IDeltaRowHeightCommand-
IInsertColCommandParams-
IInsertColMutationParamsParams of InsertColMutation
IInsertRangeMutationParamsParams of InsertRange
IInsertRowCommandParams-
IInsertRowMutationParamsParams of InsertRowMutation
IInsertSheetCommandParams-
IInsertSheetMutationParamsParams of InsertSheetMutation
IMoveColsCommandParams-
IMoveColumnsMutationParams-
IMoveRangeCommandParams-
IMoveRangeMutationParams-
IMoveRowsCommandParams-
IMoveRowsMutationParams-
INumfmtItemWithCache-
INumfmtService-
IRangeProtectionRule-
IRemoveColMutationParamsParams of InsertColMutation
IRemoveNumfmtMutationParams-
IRemoveRowColCommandParams-
IRemoveRowsMutationParamsParams of InsertRowMutation
IRemoveSheetCommandParams-
IRemoveSheetMutationParamsParams of RemoveSheetMutation
IRemoveWorksheetMergeMutationParamsParams of RemoveWorksheetMergeMutation
IReorderRangeCommandParamsCopyright 2023-present DreamNum Inc.
IReorderRangeMutationParamsCopyright 2023-present DreamNum Inc.
ISelectionStylehttps://support.microsoft.com/en-us/office/select-cell-contents-in-excel-23f64223-2b6b-453a-8688-248355f10fa9 (opens in a new tab)
ISelectionWidgetConfigWhether to display the controller that modifies the selection, distributed in 8 locations tl top_left_corner tc top_center_corner tr top_right_corner ml middle_left_corner mr middle_right_corner bl bottom_left_corner bc bottom_center_corner br bottom_right_corner
ISelectionWithCoordAndStyle-
ISelectionWithStyle-
ISetBorderBasicCommandParams-
ISetBorderColorCommandParams-
ISetBorderCommandParams-
ISetBorderPositionCommandParams-
ISetBorderStyleCommandParams-
ISetColHiddenMutationParams-
ISetColVisibleMutationParams-
ISetColorCommandParams-
ISetDefinedNameCommandParams-
ISetFontFamilyCommandParams-
ISetFontSizeCommandParams-
ISetFrozenMutationParams-
ISetHorizontalTextAlignCommandParams-
ISetNumfmtMutationParams-
ISetRangeProtectionCommandParams-
ISetRangeProtectionMutationParams-
ISetRangeValuesCommandParams-
ISetRangeValuesMutationParamsParams of SetRangeValuesMutation
ISetRangeValuesRangeMutationParamsParams of SetRangeValuesMutation
ISetRowHiddenMutationParams-
ISetRowVisibleMutationParams-
ISetSelectionsOperationParams-
ISetSpecificColsVisibleCommandParams-
ISetSpecificRowsVisibleCommandParams-
ISetStyleCommandParams-
ISetTabColorMutationParams-
ISetTextRotationCommandParams-
ISetTextWrapCommandParams-
ISetVerticalTextAlignCommandParams-
ISetWorkbookNameCommandParams-
ISetWorkbookNameMutationParams-
ISetWorksheetActivateCommandParams-
ISetWorksheetActiveOperationParams-
ISetWorksheetColWidthMutationParams-
ISetWorksheetHideMutationParams-
ISetWorksheetNameCommandParams-
ISetWorksheetNameMutationParams-
ISetWorksheetOrderMutationParams-
ISetWorksheetRowAutoHeightMutationParams-
ISetWorksheetRowHeightMutationParams-
ISetWorksheetRowIsAutoHeightCommandParams-
ISetWorksheetRowIsAutoHeightMutationParams-
ISheetCommandSharedParamsCopyright 2023-present DreamNum Inc.
ISheetLocation-
ISheetLocationBase-
ISheetRangeLocation-
ISheetRowLocation-
IStyleTypeValue-
IUniverSheetsConfig-
IWorksheetProtectionRule-
InsertRangeMoveDownCommandParams-
InsertRangeMoveRightCommandParams-

Type Aliases

Type aliasDescription
EffectRefRangeParams-
FormatType-
ICellPermission-
IModel-
INumfmtItem-
IObjectModel-
IOperator-
IRangePermissionPoint-
ISetCellsNumfmt-
IWorksheetProtectionRenderCellData-

Variables

VariableDescription
AddRangeProtectionCommand-
AddRangeProtectionMutation-
AddWorksheetMergeMutation-
AddWorksheetProtectionMutation-
COMMAND_LISTENER_SKELETON_CHANGEMutations those will trigger the skeleton change.
COMMAND_LISTENER_VALUE_CHANGE-
ClearSelectionAllCommandThe command to clear all in current selected ranges.
ClearSelectionContentCommandThe command to clear content in current selected ranges.
ClearSelectionFormatCommandThe command to clear content in current selected ranges.
CopySheetCommand-
DeleteRangeMoveLeftCommandThe command to delete range.
DeleteRangeMoveUpCommandThe command to delete range.
DeleteRangeProtectionCommand-
DeleteRangeProtectionMutation-
DeleteWorksheetProtectionMutation-
DeltaColumnWidthCommand-
DeltaRowHeightCommand-
EffectRefRangId-
EmptyMutation-
INTERCEPTOR_POINT-
InsertColAfterCommand-
InsertColBeforeCommand-
InsertColCommand-
InsertColMutation-
InsertDefinedNameCommandThe command to insert new defined name
InsertRangeMoveDownCommandThe command to insert range.
InsertRangeMoveRightCommandThe command to insert range.
InsertRowAfterCommand-
InsertRowBeforeCommand-
InsertRowCommandthis command and its interface should not be exported from index.ts
InsertRowMutation-
InsertSheetCommandThe command to insert new worksheet
InsertSheetMutation-
MAX_CELL_PER_SHEET_KEYCopyright 2023-present DreamNum Inc.
MoveColsCommand-
MoveColsMutation-
MoveRangeCommand-
MoveRangeMutation-
MoveRowsCommandCommand to move the selected rows (must currently selected) to the specified row.
MoveRowsMutation-
NORMAL_SELECTION_PLUGIN_NAME-
RemoveColCommandThis command would remove the selected columns. These selected rows can be non-continuous.
RemoveColMutation-
RemoveDefinedNameCommandThe command to remove new defined name
RemoveNumfmtMutation-
RemoveRowCommandThis command would remove the selected rows. These selected rows can be non-continuous.
RemoveRowMutation-
RemoveSheetCommandThe command to insert new worksheet
RemoveSheetMutation-
RemoveWorksheetMergeCommand-
RemoveWorksheetMergeMutation-
ReorderRangeCommand-
ReorderRangeMutation-
ResetBackgroundColorCommand-
ResetTextColorCommand-
SELECTION_CONTROL_BORDER_BUFFER_COLOR-
SELECTION_CONTROL_BORDER_BUFFER_WIDTH-
ScrollToCellOperation-
SetBackgroundColorCommand-
SetBoldCommandSet bold font style to currently selected ranges. If the cell is already bold then it will cancel the bold style.
SetBorderBasicCommand-
SetBorderColorCommand-
SetBorderCommandThe command to clear content in current selected ranges.
SetBorderPositionCommand-
SetBorderStyleCommand-
SetColHiddenCommand-
SetColHiddenMutation-
SetColVisibleMutation-
SetColWidthCommand-
SetDefinedNameCommandThe command to update defined name
SetFontFamilyCommand-
SetFontSizeCommand-
SetFrozenCommand-
SetFrozenMutation-
SetHorizontalTextAlignCommand-
SetItalicCommandSet italic font style to currently selected ranges. If the cell is already italic then it will cancel the italic style.
SetNumfmtMutation-
SetRangeProtectionCommand-
SetRangeProtectionMutation-
SetRangeValuesCommandThe command to set values for ranges.
SetRangeValuesMutationTODO@Dushusir: Excel can display numbers with up to about 15 digits of precision. When the user inputs more than 15 digits, interception is required, but there are unknown performance risks.
SetRowHeightCommand-
SetRowHiddenCommand-
SetRowHiddenMutation-
SetRowVisibleMutation-
SetSelectedColsVisibleCommand-
SetSelectedRowsVisibleCommand-
SetSelectionsOperation-
SetSpecificColsVisibleCommand-
SetSpecificRowsVisibleCommand-
SetStrikeThroughCommandSet strike through font style to currently selected ranges. If the cell is already stroke then it will cancel the stroke style.
SetStyleCommandThe command to set cell style. Set style to a bunch of ranges.
SetTabColorCommand-
SetTabColorMutation-
SetTextColorCommand-
SetTextRotationCommand-
SetTextWrapCommand-
SetUnderlineCommandSet underline font style to currently selected ranges. If the cell is already underline then it will cancel the underline style.
SetVerticalTextAlignCommand-
SetWorkbookNameCommandThe command to set the workbook name. It does not support undo redo.
SetWorkbookNameMutation-
SetWorksheetActivateCommand-
SetWorksheetActiveOperation-
SetWorksheetColWidthMutation-
SetWorksheetHideCommand-
SetWorksheetHideMutation-
SetWorksheetNameCommandThe command to set the sheet name.
SetWorksheetNameMutation-
SetWorksheetOrderCommand-
SetWorksheetOrderMutation-
SetWorksheetPermissionPointsCommand-
SetWorksheetProtectionMutation-
SetWorksheetRowAutoHeightMutation-
SetWorksheetRowHeightMutation-
SetWorksheetRowIsAutoHeightCommand-
SetWorksheetRowIsAutoHeightMutation-
SetWorksheetShowCommand-
defaultWorkbookPermissionPoints-
defaultWorksheetPermissionPoint-

Functions

FunctionDescription
AddMergeRedoSelectionsOperationFactory-
AddMergeUndoMutationFactory-
AddMergeUndoSelectionsOperationFactory-
FactoryAddRangeProtectionMutation-
FactoryDeleteRangeProtectionMutation-
FactorySetRangeProtectionMutation-
INumfmtService-
InsertColMutationUndoFactory-
InsertRowMutationUndoFactory-
InsertSheetUndoMutationFactory-
MoveColsMutationUndoFactory-
MoveRowsMutationUndoFactoryGet an undo mutation for the move rows mutation.
RemoveMergeUndoMutationFactory-
RemoveSheetUndoMutationFactory-
SetFrozenMutationFactory-
SetRangeValuesUndoMutationFactory-
SetWorksheetColWidthMutationFactory-
SetWorksheetRowAutoHeightMutationFactory-
alignToMergedCellsBordersAdjust the range to align merged cell's borders.
convertPrimaryWithCoordToPrimary-
convertSelectionDataToRangeProcess a selection with coordinates and style, and extract the coordinate information, because the render needs coordinates when drawing. Since the selection.manager.service is unrelated to the coordinates, it only accepts data of type ISelectionWithStyle, so a conversion is necessary.
createTopMatrixFromMatrix-
createTopMatrixFromRanges-
expandToContinuousRange-
factoryRemoveNumfmtUndoMutation-
factorySetNumfmtUndoMutation-
findAllRectangle-
followSelectionOperation-
generateNullCellValueGenerate cellValue from range and set v/p/f/si/custom to null
getAddMergeMutationRangeByTypecalculates the selection based on the merged cell type
getAllRangePermissionPoint-
getAllWorkbookPermissionPoint-
getAllWorksheetPermissionPoint-
getAllWorksheetPermissionPointByPointPanel-
getCellAtRowCol-
getDefaultRangePermission-
getInsertRangeMutationsInsertRange is not a mutation but combination of SetRangeValuesMutation and MoveRangeMutation.
getMoveRangeUndoRedoMutations-
getNormalSelectionStyle-
getPrimaryForRangeGet the default primary cell (the most top-left cell) of a range.
getRemoveRangeMutations-
getSheetCommandTargetGet targeted Workbook & Worksheet of a command. If unitId and subUnitId are given, the function would try to get these instances. If not, it would try to get the current active instances.
getSheetCommandTargetWorkbook-
getSheetMutationTarget-
handleBaseInsertRange-
handleBaseMoveRowsCols-
handleBaseRemoveRange-
handleCommonDefaultRangeChangeWithEffectRefCommands-
handleDefaultRangeChangeWithEffectRefCommands-
handleDefaultRangeChangeWithEffectRefCommandsSkipNoInterests-
handleDeleteRangeMoveLeft-
handleDeleteRangeMoveUp-
handleDeleteRangeMutation-
handleIRemoveCol-
handleIRemoveRow-
handleInsertCol-
handleInsertRangeMoveDown-
handleInsertRangeMoveRight-
handleInsertRangeMutation-
handleInsertRow-
handleMoveCols-
handleMoveRange-
handleMoveRows-
isSingleCellSelectionExamine if a selection only contains a single cell (a merged cell is considered as a single cell in this case).
rangeMerge-
rotateRange-
runRefRangeMutations-
setEndForRange-
transformCellDataToSelectionDataConvert the coordinates of a single cell into a selection data.
transformCellsToRange-

Copyright © 2021-2024 DreamNum Co,Ltd. All Rights Reserved.