@univerjs/docs 1.0.0-alpha.1 → 1.0.0-alpha.2
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/facade.js +458 -978
- package/lib/cjs/index.js +158 -9
- package/lib/es/facade.js +460 -977
- package/lib/es/index.js +156 -11
- package/lib/facade.js +460 -977
- package/lib/index.js +156 -11
- package/lib/types/commands/commands/create-header-footer.command.d.ts +41 -0
- package/lib/types/facade/f-document-paragraph.d.ts +73 -100
- package/lib/types/facade/f-document.d.ts +197 -26
- package/lib/types/facade/index.d.ts +4 -6
- package/lib/types/facade/utils.d.ts +15 -1
- package/lib/types/index.d.ts +3 -0
- package/lib/types/utils/util.d.ts +19 -0
- package/lib/umd/facade.js +3 -1
- package/lib/umd/index.js +2 -1
- package/package.json +4 -4
- package/lib/types/facade/f-document-block-range.d.ts +0 -132
- package/lib/types/facade/f-document-body.d.ts +0 -276
- package/lib/types/facade/f-document-custom-block.d.ts +0 -57
- package/lib/types/facade/f-document-element.d.ts +0 -193
- package/lib/types/facade/f-document-table.d.ts +0 -57
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright 2023-present DreamNum Co., Ltd.
|
|
3
|
-
*
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
import type { ICustomTable, Injector } from '@univerjs/core';
|
|
17
|
-
import type { FDocumentBody, IFDocumentBodyEdit } from './f-document-body';
|
|
18
|
-
import type { IFDocumentElementInfo } from './f-document-element';
|
|
19
|
-
import { FDocumentElement } from './f-document-element';
|
|
20
|
-
interface IFDocumentTableMixin {
|
|
21
|
-
asTable(): FDocumentTable;
|
|
22
|
-
}
|
|
23
|
-
/**
|
|
24
|
-
* A facade wrapper for document top-level tables.
|
|
25
|
-
* @hideconstructor
|
|
26
|
-
*/
|
|
27
|
-
export declare class FDocumentTable extends FDocumentElement {
|
|
28
|
-
protected readonly body: FDocumentBody;
|
|
29
|
-
protected readonly bodyEdit: IFDocumentBodyEdit;
|
|
30
|
-
protected readonly info: IFDocumentElementInfo;
|
|
31
|
-
protected readonly injector: Injector;
|
|
32
|
-
constructor(body: FDocumentBody, bodyEdit: IFDocumentBodyEdit, info: IFDocumentElementInfo, injector: Injector);
|
|
33
|
-
/**
|
|
34
|
-
* Get the table marker.
|
|
35
|
-
* @returns {ICustomTable} The table marker.
|
|
36
|
-
* @example
|
|
37
|
-
* ```ts
|
|
38
|
-
* const fDocument = univerAPI.getActiveDocument();
|
|
39
|
-
* const fDocumentBody = fDocument.getBody();
|
|
40
|
-
* const element = fDocumentBody.getElement(0);
|
|
41
|
-
*
|
|
42
|
-
* if (element?.isTable()) {
|
|
43
|
-
* const table = element.asTable();
|
|
44
|
-
* console.log(table.getTable());
|
|
45
|
-
* }
|
|
46
|
-
* ```
|
|
47
|
-
*/
|
|
48
|
-
getTable(): ICustomTable;
|
|
49
|
-
}
|
|
50
|
-
export declare class FDocumentTableMixin extends FDocumentElement {
|
|
51
|
-
asTable(): FDocumentTable;
|
|
52
|
-
}
|
|
53
|
-
declare module '@univerjs/docs/facade' {
|
|
54
|
-
interface FDocumentElement extends IFDocumentTableMixin {
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
export {};
|