API Reference
@univerjs
@univerjs/sheets-ui
interfaces
Iformatpainterhook

@univerjs/sheets-ui v0.4.2Docs


Interface: IFormatPainterHook

Properties

PropertyTypeDefined in
idstringpackages/sheets-ui/src/services/format-painter/format-painter.service.ts:43 (opens in a new tab)
isDefaultHook?booleanpackages/sheets-ui/src/services/format-painter/format-painter.service.ts:44 (opens in a new tab)
priority?numberpackages/sheets-ui/src/services/format-painter/format-painter.service.ts:45 (opens in a new tab)

Methods

onApply()?

optional onApply(
   unitId, 
   subUnitId, 
   range, 
   format): {
  redos: IMutationInfo<object>[];
  undos: IMutationInfo<object>[];
}

Parameters

ParameterType
unitIdstring
subUnitIdstring
rangeIRange
formatISelectionFormatInfo

Returns

{
  redos: IMutationInfo<object>[];
  undos: IMutationInfo<object>[];
}
NameTypeDefined in
redosIMutationInfo<object>[]packages/sheets-ui/src/services/format-painter/format-painter.service.ts:53 (opens in a new tab)
undosIMutationInfo<object>[]packages/sheets-ui/src/services/format-painter/format-painter.service.ts:52 (opens in a new tab)

Defined in

packages/sheets-ui/src/services/format-painter/format-painter.service.ts:47 (opens in a new tab)


onBeforeApply()?

optional onBeforeApply(ctx): boolean

Parameters

ParameterType
ctxIFormatPainterBeforeApplyHookParams

Returns

boolean

Defined in

packages/sheets-ui/src/services/format-painter/format-painter.service.ts:55 (opens in a new tab)


onStatusChange()?

optional onStatusChange(status): void

Parameters

ParameterType
statusFormatPainterStatus

Returns

void

Defined in

packages/sheets-ui/src/services/format-painter/format-painter.service.ts:46 (opens in a new tab)


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