@univerjs/sheets-ui v0.4.2 • Docs
Class: SheetClipboardService
Extends
Implements
Constructors
new SheetClipboardService()
new SheetClipboardService(
_logService,
_univerInstanceService,
_selectionManagerService,
_clipboardInterfaceService,
_undoRedoService,
_commandService,
_markSelectionService,
_notificationService,
_platformService,
_renderManagerService,
_themeService,
_localeService,
_errorService,
_injector): SheetClipboardService
Parameters
Parameter | Type |
---|---|
_logService | ILogService |
_univerInstanceService | IUniverInstanceService |
_selectionManagerService | SheetsSelectionsService |
_clipboardInterfaceService | IClipboardInterfaceService |
_undoRedoService | IUndoRedoService |
_commandService | ICommandService |
_markSelectionService | IMarkSelectionService |
_notificationService | INotificationService |
_platformService | IPlatformService |
_renderManagerService | IRenderManagerService |
_themeService | ThemeService |
_localeService | LocaleService |
_errorService | ErrorService |
_injector | Injector |
Returns
Overrides
Defined in
packages/sheets-ui/src/services/clipboard/clipboard.service.ts:124 (opens in a new tab)
Properties
Property | Modifier | Type | Default value | Inherited from | Defined in |
---|---|---|---|---|---|
_disposed | protected | boolean | false | Disposable ._disposed | packages/core/src/shared/lifecycle.ts:93 (opens in a new tab) |
clipboardHooks$ | readonly | Observable <ISheetClipboardHook []> | undefined | - | packages/sheets-ui/src/services/clipboard/clipboard.service.ts:116 (opens in a new tab) |
Methods
addClipboardHook()
addClipboardHook(hook): IDisposable
Parameters
Parameter | Type |
---|---|
hook | ISheetClipboardHook |
Returns
Implementation of
ISheetClipboardService
.addClipboardHook
Defined in
packages/sheets-ui/src/services/clipboard/clipboard.service.ts:257 (opens in a new tab)
copy()
copy(copyType): Promise<boolean>
Parameters
Parameter | Type | Default value |
---|---|---|
copyType | COPY_TYPE | COPY_TYPE.COPY |
Returns
Promise
<boolean
>
Implementation of
Defined in
packages/sheets-ui/src/services/clipboard/clipboard.service.ts:163 (opens in a new tab)
copyContentCache()
copyContentCache(): CopyContentCache
Returns
CopyContentCache
Implementation of
ISheetClipboardService
.copyContentCache
Defined in
packages/sheets-ui/src/services/clipboard/clipboard.service.ts:151 (opens in a new tab)
cut()
cut(): Promise<boolean>
Returns
Promise
<boolean
>
Implementation of
Defined in
packages/sheets-ui/src/services/clipboard/clipboard.service.ts:204 (opens in a new tab)
dispose()
dispose(): void
Returns
void
Inherited from
Defined in
packages/core/src/shared/lifecycle.ts:106 (opens in a new tab)
disposeWithMe()
disposeWithMe(disposable): IDisposable
Parameters
Parameter | Type |
---|---|
disposable | DisposableLike |
Returns
Inherited from
Defined in
packages/core/src/shared/lifecycle.ts:96 (opens in a new tab)
ensureNotDisposed()
protected ensureNotDisposed(): void
Returns
void
Inherited from
Defined in
packages/core/src/shared/lifecycle.ts:100 (opens in a new tab)
generateCopyContent()
generateCopyContent(
workbookId,
worksheetId,
range): Nullable<ICopyContent>
Parameters
Parameter | Type |
---|---|
workbookId | string |
worksheetId | string |
range | IRange |
Returns
Nullable
<ICopyContent
>
Implementation of
ISheetClipboardService
.generateCopyContent
Defined in
packages/sheets-ui/src/services/clipboard/clipboard.service.ts:155 (opens in a new tab)
getClipboardHooks()
getClipboardHooks(): ISheetClipboardHook[]
Returns
Implementation of
ISheetClipboardService
.getClipboardHooks
Defined in
packages/sheets-ui/src/services/clipboard/clipboard.service.ts:282 (opens in a new tab)
legacyPaste()
legacyPaste(html?, text?): Promise<boolean>
Parameters
Parameter | Type |
---|---|
html ? | string |
text ? | string |
Returns
Promise
<boolean
>
Implementation of
ISheetClipboardService
.legacyPaste
Defined in
packages/sheets-ui/src/services/clipboard/clipboard.service.ts:242 (opens in a new tab)
paste()
paste(item, pasteType): Promise<boolean>
Parameters
Parameter | Type | Default value |
---|---|---|
item | ClipboardItem | undefined |
pasteType | string | PREDEFINED_HOOK_NAME.DEFAULT_PASTE |
Returns
Promise
<boolean
>
Implementation of
Defined in
packages/sheets-ui/src/services/clipboard/clipboard.service.ts:208 (opens in a new tab)
removeMarkSelection()
removeMarkSelection(): void
Returns
void
Implementation of
ISheetClipboardService
.removeMarkSelection
Defined in
packages/sheets-ui/src/services/clipboard/clipboard.service.ts:1072 (opens in a new tab)