@univerjs/engine-render 0.1.0-alpha.1
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/LICENSE +21 -0
- package/README.md +16 -0
- package/lib/cjs/index.js +23962 -0
- package/lib/esm/index.js +23259 -0
- package/lib/types/base-object.d.ts +155 -0
- package/lib/types/base-object.d.ts.map +1 -0
- package/lib/types/basics/cell-data.d.ts +6 -0
- package/lib/types/basics/cell-data.d.ts.map +1 -0
- package/lib/types/basics/const.d.ts +263 -0
- package/lib/types/basics/const.d.ts.map +1 -0
- package/lib/types/basics/document-node-tools.d.ts +10 -0
- package/lib/types/basics/document-node-tools.d.ts.map +1 -0
- package/lib/types/basics/draw.d.ts +39 -0
- package/lib/types/basics/draw.d.ts.map +1 -0
- package/lib/types/basics/font-cache.d.ts +37 -0
- package/lib/types/basics/font-cache.d.ts.map +1 -0
- package/lib/types/basics/i-document-skeleton-cached.d.ts +210 -0
- package/lib/types/basics/i-document-skeleton-cached.d.ts.map +1 -0
- package/lib/types/basics/i-events.d.ts +304 -0
- package/lib/types/basics/i-events.d.ts.map +1 -0
- package/lib/types/basics/index.d.ts +16 -0
- package/lib/types/basics/index.d.ts.map +1 -0
- package/lib/types/basics/interfaces.d.ts +102 -0
- package/lib/types/basics/interfaces.d.ts.map +1 -0
- package/lib/types/basics/path2.d.ts +10 -0
- package/lib/types/basics/path2.d.ts.map +1 -0
- package/lib/types/basics/performance-monitor.d.ts +111 -0
- package/lib/types/basics/performance-monitor.d.ts.map +1 -0
- package/lib/types/basics/position.d.ts +13 -0
- package/lib/types/basics/position.d.ts.map +1 -0
- package/lib/types/basics/quick-event.d.ts +4 -0
- package/lib/types/basics/quick-event.d.ts.map +1 -0
- package/lib/types/basics/range.d.ts +17 -0
- package/lib/types/basics/range.d.ts.map +1 -0
- package/lib/types/basics/scroll-xy.d.ts +5 -0
- package/lib/types/basics/scroll-xy.d.ts.map +1 -0
- package/lib/types/basics/tools.d.ts +109 -0
- package/lib/types/basics/tools.d.ts.map +1 -0
- package/lib/types/basics/transform.d.ts +143 -0
- package/lib/types/basics/transform.d.ts.map +1 -0
- package/lib/types/basics/unit-convert.d.ts +3 -0
- package/lib/types/basics/unit-convert.d.ts.map +1 -0
- package/lib/types/basics/vector2.d.ts +438 -0
- package/lib/types/basics/vector2.d.ts.map +1 -0
- package/lib/types/canvas.d.ts +55 -0
- package/lib/types/canvas.d.ts.map +1 -0
- package/lib/types/components/component.d.ts +13 -0
- package/lib/types/components/component.d.ts.map +1 -0
- package/lib/types/components/docs/block/block-error.d.ts +2 -0
- package/lib/types/components/docs/block/block-error.d.ts.map +1 -0
- package/lib/types/components/docs/block/index.d.ts +4 -0
- package/lib/types/components/docs/block/index.d.ts.map +1 -0
- package/lib/types/components/docs/block/paragraph/bullet-ruler.d.ts +3 -0
- package/lib/types/components/docs/block/paragraph/bullet-ruler.d.ts.map +1 -0
- package/lib/types/components/docs/block/paragraph/bullet.d.ts +5 -0
- package/lib/types/components/docs/block/paragraph/bullet.d.ts.map +1 -0
- package/lib/types/components/docs/block/paragraph/index.d.ts +7 -0
- package/lib/types/components/docs/block/paragraph/index.d.ts.map +1 -0
- package/lib/types/components/docs/block/paragraph/inline-drawing.d.ts +5 -0
- package/lib/types/components/docs/block/paragraph/inline-drawing.d.ts.map +1 -0
- package/lib/types/components/docs/block/paragraph/language-ruler.d.ts +12 -0
- package/lib/types/components/docs/block/paragraph/language-ruler.d.ts.map +1 -0
- package/lib/types/components/docs/block/paragraph/layout-ruler.d.ts +4 -0
- package/lib/types/components/docs/block/paragraph/layout-ruler.d.ts.map +1 -0
- package/lib/types/components/docs/block/paragraph/paragraph.d.ts +6 -0
- package/lib/types/components/docs/block/paragraph/paragraph.d.ts.map +1 -0
- package/lib/types/components/docs/block/section.d.ts +10 -0
- package/lib/types/components/docs/block/section.d.ts.map +1 -0
- package/lib/types/components/docs/block/table/table-cell.d.ts +1 -0
- package/lib/types/components/docs/block/table/table-cell.d.ts.map +1 -0
- package/lib/types/components/docs/block/table/table-row.d.ts +1 -0
- package/lib/types/components/docs/block/table/table-row.d.ts.map +1 -0
- package/lib/types/components/docs/block/table/table.d.ts +1 -0
- package/lib/types/components/docs/block/table/table.d.ts.map +1 -0
- package/lib/types/components/docs/common/column.d.ts +5 -0
- package/lib/types/components/docs/common/column.d.ts.map +1 -0
- package/lib/types/components/docs/common/convert-cursor.d.ts +60 -0
- package/lib/types/components/docs/common/convert-cursor.d.ts.map +1 -0
- package/lib/types/components/docs/common/index.d.ts +10 -0
- package/lib/types/components/docs/common/index.d.ts.map +1 -0
- package/lib/types/components/docs/common/line.d.ts +20 -0
- package/lib/types/components/docs/common/line.d.ts.map +1 -0
- package/lib/types/components/docs/common/liquid.d.ts +41 -0
- package/lib/types/components/docs/common/liquid.d.ts.map +1 -0
- package/lib/types/components/docs/common/page.d.ts +5 -0
- package/lib/types/components/docs/common/page.d.ts.map +1 -0
- package/lib/types/components/docs/common/range.d.ts +45 -0
- package/lib/types/components/docs/common/range.d.ts.map +1 -0
- package/lib/types/components/docs/common/section.d.ts +6 -0
- package/lib/types/components/docs/common/section.d.ts.map +1 -0
- package/lib/types/components/docs/common/span.d.ts +12 -0
- package/lib/types/components/docs/common/span.d.ts.map +1 -0
- package/lib/types/components/docs/common/tools.d.ts +73 -0
- package/lib/types/components/docs/common/tools.d.ts.map +1 -0
- package/lib/types/components/docs/doc-component.d.ts +34 -0
- package/lib/types/components/docs/doc-component.d.ts.map +1 -0
- package/lib/types/components/docs/doc-extension.d.ts +12 -0
- package/lib/types/components/docs/doc-extension.d.ts.map +1 -0
- package/lib/types/components/docs/doc-skeleton.d.ts +71 -0
- package/lib/types/components/docs/doc-skeleton.d.ts.map +1 -0
- package/lib/types/components/docs/document.d.ts +54 -0
- package/lib/types/components/docs/document.d.ts.map +1 -0
- package/lib/types/components/docs/extensions/background.d.ts +11 -0
- package/lib/types/components/docs/extensions/background.d.ts.map +1 -0
- package/lib/types/components/docs/extensions/border.d.ts +13 -0
- package/lib/types/components/docs/extensions/border.d.ts.map +1 -0
- package/lib/types/components/docs/extensions/font-and-base-line.d.ts +12 -0
- package/lib/types/components/docs/extensions/font-and-base-line.d.ts.map +1 -0
- package/lib/types/components/docs/extensions/index.d.ts +5 -0
- package/lib/types/components/docs/extensions/index.d.ts.map +1 -0
- package/lib/types/components/docs/extensions/line.d.ts +13 -0
- package/lib/types/components/docs/extensions/line.d.ts.map +1 -0
- package/lib/types/components/docs/horizon-bar.d.ts +3 -0
- package/lib/types/components/docs/horizon-bar.d.ts.map +1 -0
- package/lib/types/components/docs/index.d.ts +8 -0
- package/lib/types/components/docs/index.d.ts.map +1 -0
- package/lib/types/components/docs/text-selection-render-manager.d.ts +156 -0
- package/lib/types/components/docs/text-selection-render-manager.d.ts.map +1 -0
- package/lib/types/components/docs/vertical-bar.d.ts +3 -0
- package/lib/types/components/docs/vertical-bar.d.ts.map +1 -0
- package/lib/types/components/docs/view-model/data-stream-tree-node.d.ts +39 -0
- package/lib/types/components/docs/view-model/data-stream-tree-node.d.ts.map +1 -0
- package/lib/types/components/docs/view-model/document-view-model.d.ts +51 -0
- package/lib/types/components/docs/view-model/document-view-model.d.ts.map +1 -0
- package/lib/types/components/extension.d.ts +29 -0
- package/lib/types/components/extension.d.ts.map +1 -0
- package/lib/types/components/index.d.ts +7 -0
- package/lib/types/components/index.d.ts.map +1 -0
- package/lib/types/components/sheets/column-header.d.ts +13 -0
- package/lib/types/components/sheets/column-header.d.ts.map +1 -0
- package/lib/types/components/sheets/extensions/background.d.ts +9 -0
- package/lib/types/components/sheets/extensions/background.d.ts.map +1 -0
- package/lib/types/components/sheets/extensions/border-auxiliary.d.ts +13 -0
- package/lib/types/components/sheets/extensions/border-auxiliary.d.ts.map +1 -0
- package/lib/types/components/sheets/extensions/border.d.ts +10 -0
- package/lib/types/components/sheets/extensions/border.d.ts.map +1 -0
- package/lib/types/components/sheets/extensions/column-header-layout.d.ts +9 -0
- package/lib/types/components/sheets/extensions/column-header-layout.d.ts.map +1 -0
- package/lib/types/components/sheets/extensions/font.d.ts +15 -0
- package/lib/types/components/sheets/extensions/font.d.ts.map +1 -0
- package/lib/types/components/sheets/extensions/index.d.ts +8 -0
- package/lib/types/components/sheets/extensions/index.d.ts.map +1 -0
- package/lib/types/components/sheets/extensions/row-header-layout.d.ts +9 -0
- package/lib/types/components/sheets/extensions/row-header-layout.d.ts.map +1 -0
- package/lib/types/components/sheets/extensions/sheet-extension.d.ts +11 -0
- package/lib/types/components/sheets/extensions/sheet-extension.d.ts.map +1 -0
- package/lib/types/components/sheets/index.d.ts +8 -0
- package/lib/types/components/sheets/index.d.ts.map +1 -0
- package/lib/types/components/sheets/interfaces.d.ts +35 -0
- package/lib/types/components/sheets/interfaces.d.ts.map +1 -0
- package/lib/types/components/sheets/row-header.d.ts +13 -0
- package/lib/types/components/sheets/row-header.d.ts.map +1 -0
- package/lib/types/components/sheets/sheet-component.d.ts +38 -0
- package/lib/types/components/sheets/sheet-component.d.ts.map +1 -0
- package/lib/types/components/sheets/sheet-skeleton.d.ts +275 -0
- package/lib/types/components/sheets/sheet-skeleton.d.ts.map +1 -0
- package/lib/types/components/sheets/spreadsheet.d.ts +70 -0
- package/lib/types/components/sheets/spreadsheet.d.ts.map +1 -0
- package/lib/types/components/skeleton.d.ts +13 -0
- package/lib/types/components/skeleton.d.ts.map +1 -0
- package/lib/types/components/slides/index.d.ts +2 -0
- package/lib/types/components/slides/index.d.ts.map +1 -0
- package/lib/types/components/slides/slide.d.ts +27 -0
- package/lib/types/components/slides/slide.d.ts.map +1 -0
- package/lib/types/custom/custom-object.d.ts +13 -0
- package/lib/types/custom/custom-object.d.ts.map +1 -0
- package/lib/types/custom/index.d.ts +2 -0
- package/lib/types/custom/index.d.ts.map +1 -0
- package/lib/types/engine.d.ts +96 -0
- package/lib/types/engine.d.ts.map +1 -0
- package/lib/types/group.d.ts +25 -0
- package/lib/types/group.d.ts.map +1 -0
- package/lib/types/index.d.ts +17 -0
- package/lib/types/index.d.ts.map +1 -0
- package/lib/types/layer.d.ts +21 -0
- package/lib/types/layer.d.ts.map +1 -0
- package/lib/types/render-engine.d.ts +13 -0
- package/lib/types/render-engine.d.ts.map +1 -0
- package/lib/types/render-manager.service.d.ts +51 -0
- package/lib/types/render-manager.service.d.ts.map +1 -0
- package/lib/types/scene-viewer.d.ts +27 -0
- package/lib/types/scene-viewer.d.ts.map +1 -0
- package/lib/types/scene.-transformer.d.ts +129 -0
- package/lib/types/scene.-transformer.d.ts.map +1 -0
- package/lib/types/scene.d.ts +124 -0
- package/lib/types/scene.d.ts.map +1 -0
- package/lib/types/scene.input-manager.d.ts +46 -0
- package/lib/types/scene.input-manager.d.ts.map +1 -0
- package/lib/types/scroll-timer.d.ts +35 -0
- package/lib/types/scroll-timer.d.ts.map +1 -0
- package/lib/types/services/object-transform-manager.service.d.ts +41 -0
- package/lib/types/services/object-transform-manager.service.d.ts.map +1 -0
- package/lib/types/shape/base-scroll-bar.d.ts +47 -0
- package/lib/types/shape/base-scroll-bar.d.ts.map +1 -0
- package/lib/types/shape/circle.d.ts +18 -0
- package/lib/types/shape/circle.d.ts.map +1 -0
- package/lib/types/shape/control.d.ts +3 -0
- package/lib/types/shape/control.d.ts.map +1 -0
- package/lib/types/shape/drawing.d.ts +3 -0
- package/lib/types/shape/drawing.d.ts.map +1 -0
- package/lib/types/shape/index.d.ts +12 -0
- package/lib/types/shape/index.d.ts.map +1 -0
- package/lib/types/shape/path.d.ts +92 -0
- package/lib/types/shape/path.d.ts.map +1 -0
- package/lib/types/shape/picture.d.ts +24 -0
- package/lib/types/shape/picture.d.ts.map +1 -0
- package/lib/types/shape/rect.d.ts +17 -0
- package/lib/types/shape/rect.d.ts.map +1 -0
- package/lib/types/shape/regular-polygon.d.ts +42 -0
- package/lib/types/shape/regular-polygon.d.ts.map +1 -0
- package/lib/types/shape/rich-text.d.ts +45 -0
- package/lib/types/shape/rich-text.d.ts.map +1 -0
- package/lib/types/shape/scroll-bar.d.ts +45 -0
- package/lib/types/shape/scroll-bar.d.ts.map +1 -0
- package/lib/types/shape/selection.d.ts +3 -0
- package/lib/types/shape/selection.d.ts.map +1 -0
- package/lib/types/shape/shape.d.ts +120 -0
- package/lib/types/shape/shape.d.ts.map +1 -0
- package/lib/types/thin-engine.d.ts +33 -0
- package/lib/types/thin-engine.d.ts.map +1 -0
- package/lib/types/thin-scene.d.ts +76 -0
- package/lib/types/thin-scene.d.ts.map +1 -0
- package/lib/types/viewport.d.ts +193 -0
- package/lib/types/viewport.d.ts.map +1 -0
- package/package.json +52 -0
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import type { Nullable } from '@univerjs/core';
|
|
2
|
+
import type { IBoundRect, Vector2 } from '../../basics/vector2';
|
|
3
|
+
import { RenderComponent } from '../component';
|
|
4
|
+
import type { SHEET_EXTENSION_TYPE } from './extensions/sheet-extension';
|
|
5
|
+
import type { SpreadsheetSkeleton } from './sheet-skeleton';
|
|
6
|
+
export declare class SheetComponent extends RenderComponent<SpreadsheetSkeleton, SHEET_EXTENSION_TYPE> {
|
|
7
|
+
private _skeleton?;
|
|
8
|
+
constructor(oKey: string, _skeleton?: SpreadsheetSkeleton | undefined);
|
|
9
|
+
getSkeleton(): SpreadsheetSkeleton | undefined;
|
|
10
|
+
updateSkeleton(spreadsheetSkeleton: SpreadsheetSkeleton): void;
|
|
11
|
+
render(mainCtx: CanvasRenderingContext2D, bounds?: IBoundRect): this | undefined;
|
|
12
|
+
getParentScale(): {
|
|
13
|
+
scaleX: any;
|
|
14
|
+
scaleY: any;
|
|
15
|
+
};
|
|
16
|
+
getDocuments(): any;
|
|
17
|
+
getNoMergeCellPositionByIndex(rowIndex: number, columnIndex: number): Nullable<{
|
|
18
|
+
startY: number;
|
|
19
|
+
startX: number;
|
|
20
|
+
endX: number;
|
|
21
|
+
endY: number;
|
|
22
|
+
}>;
|
|
23
|
+
getScrollXYByRelativeCoords(coord: Vector2): {
|
|
24
|
+
x: number;
|
|
25
|
+
y: number;
|
|
26
|
+
};
|
|
27
|
+
getSelectionBounding(startRow: number, startColumn: number, endRow: number, endColumn: number): Nullable<{
|
|
28
|
+
startRow: number;
|
|
29
|
+
startColumn: number;
|
|
30
|
+
endRow: number;
|
|
31
|
+
endColumn: number;
|
|
32
|
+
}>;
|
|
33
|
+
protected _draw(ctx: CanvasRenderingContext2D, bounds?: IBoundRect): void;
|
|
34
|
+
}
|
|
35
|
+
export declare class SpreadsheetHeader extends SheetComponent {
|
|
36
|
+
protected _draw(ctx: CanvasRenderingContext2D, bounds?: IBoundRect): void;
|
|
37
|
+
}
|
|
38
|
+
//# sourceMappingURL=sheet-component.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sheet-component.d.ts","sourceRoot":"","sources":["../../../../src/components/sheets/sheet-component.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAG/C,OAAO,KAAK,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAChE,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAC/C,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;AACzE,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAE5D,qBAAa,cAAe,SAAQ,eAAe,CAAC,mBAAmB,EAAE,oBAAoB,CAAC;IAKtF,OAAO,CAAC,SAAS,CAAC;gBADlB,IAAI,EAAE,MAAM,EACJ,SAAS,CAAC,iCAAqB;IAK3C,WAAW;IAIX,cAAc,CAAC,mBAAmB,EAAE,mBAAmB;IAI9C,MAAM,CAAC,OAAO,EAAE,wBAAwB,EAAE,MAAM,CAAC,EAAE,UAAU;IAkBtE,cAAc;;;;IAcd,YAAY,IAAI,GAAG;IAEnB,6BAA6B,CACzB,QAAQ,EAAE,MAAM,EAChB,WAAW,EAAE,MAAM,GACpB,QAAQ,CAAC;QAAE,MAAM,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC;IAE3E,2BAA2B,CAAC,KAAK,EAAE,OAAO;;;;IAI1C,oBAAoB,CAChB,QAAQ,EAAE,MAAM,EAChB,WAAW,EAAE,MAAM,EACnB,MAAM,EAAE,MAAM,EACd,SAAS,EAAE,MAAM,GAClB,QAAQ,CAAC;QACR,QAAQ,EAAE,MAAM,CAAC;QACjB,WAAW,EAAE,MAAM,CAAC;QACpB,MAAM,EAAE,MAAM,CAAC;QACf,SAAS,EAAE,MAAM,CAAC;KACrB,CAAC;IAEF,SAAS,CAAC,KAAK,CAAC,GAAG,EAAE,wBAAwB,EAAE,MAAM,CAAC,EAAE,UAAU;CAGrE;AAED,qBAAa,iBAAkB,SAAQ,cAAc;cAC9B,KAAK,CAAC,GAAG,EAAE,wBAAwB,EAAE,MAAM,CAAC,EAAE,UAAU,GAAG,IAAI;CAGrF"}
|
|
@@ -0,0 +1,275 @@
|
|
|
1
|
+
import type { ICellData, IPaddingData, IRange, ISelectionCellWithCoord, ITextRotation, IWorksheetData, LocaleService, Nullable, Styles, Worksheet } from '@univerjs/core';
|
|
2
|
+
import { BooleanNumber, DocumentDataModel, HorizontalAlign, ObjectMatrix, VerticalAlign, WrapStrategy } from '@univerjs/core';
|
|
3
|
+
import type { IBoundRect } from '../../basics/vector2';
|
|
4
|
+
import { DocumentSkeleton } from '../docs/doc-skeleton';
|
|
5
|
+
import { Skeleton } from '../skeleton';
|
|
6
|
+
import type { IStylesCache } from './interfaces';
|
|
7
|
+
/**
|
|
8
|
+
* Obtain the height and width of a cell's text, taking into account scenarios with rotated text.
|
|
9
|
+
* @param documentSkeleton Data of the document's ViewModel
|
|
10
|
+
* @param angleInDegree The rotation angle of an Excel cell, it's **degree**
|
|
11
|
+
* @returns
|
|
12
|
+
*/
|
|
13
|
+
export declare function getDocsSkeletonPageSize(documentSkeleton: DocumentSkeleton, angleInDegree?: number): {
|
|
14
|
+
width: number;
|
|
15
|
+
height: number;
|
|
16
|
+
} | undefined;
|
|
17
|
+
export interface IRowAutoHeightInfo {
|
|
18
|
+
row: number;
|
|
19
|
+
autoHeight?: number;
|
|
20
|
+
}
|
|
21
|
+
interface IRowColumnSegment {
|
|
22
|
+
startRow: number;
|
|
23
|
+
endRow: number;
|
|
24
|
+
startColumn: number;
|
|
25
|
+
endColumn: number;
|
|
26
|
+
}
|
|
27
|
+
export interface IDocumentLayoutObject {
|
|
28
|
+
documentModel: Nullable<DocumentDataModel>;
|
|
29
|
+
fontString: string;
|
|
30
|
+
textRotation: ITextRotation;
|
|
31
|
+
wrapStrategy: WrapStrategy;
|
|
32
|
+
verticalAlign: VerticalAlign;
|
|
33
|
+
horizontalAlign: HorizontalAlign;
|
|
34
|
+
paddingData: IPaddingData;
|
|
35
|
+
fill?: Nullable<string>;
|
|
36
|
+
}
|
|
37
|
+
export declare class SpreadsheetSkeleton extends Skeleton {
|
|
38
|
+
private _worksheet;
|
|
39
|
+
private _config;
|
|
40
|
+
private _cellData;
|
|
41
|
+
private _styles;
|
|
42
|
+
private _rowHeightAccumulation;
|
|
43
|
+
private _rowTotalHeight;
|
|
44
|
+
private _columnWidthAccumulation;
|
|
45
|
+
private _columnTotalWidth;
|
|
46
|
+
private _rowHeaderWidth;
|
|
47
|
+
private _columnHeaderHeight;
|
|
48
|
+
private _rowColumnSegment;
|
|
49
|
+
private _dataMergeCache;
|
|
50
|
+
private _overflowCache;
|
|
51
|
+
private _stylesCache;
|
|
52
|
+
private _renderedCellCache;
|
|
53
|
+
private _showGridlines;
|
|
54
|
+
private _marginTop;
|
|
55
|
+
private _marginLeft;
|
|
56
|
+
constructor(_worksheet: Worksheet | undefined, _config: IWorksheetData, _cellData: ObjectMatrix<ICellData>, _styles: Styles, _localeService: LocaleService);
|
|
57
|
+
get rowHeightAccumulation(): number[];
|
|
58
|
+
get rowTotalHeight(): number;
|
|
59
|
+
get columnWidthAccumulation(): number[];
|
|
60
|
+
get columnTotalWidth(): number;
|
|
61
|
+
get rowHeaderWidth(): number;
|
|
62
|
+
get columnHeaderHeight(): number;
|
|
63
|
+
get rowColumnSegment(): IRowColumnSegment;
|
|
64
|
+
get dataMergeCache(): IRange[];
|
|
65
|
+
get stylesCache(): IStylesCache;
|
|
66
|
+
get overflowCache(): ObjectMatrix<IRange>;
|
|
67
|
+
get showGridlines(): BooleanNumber;
|
|
68
|
+
get mergeData(): IRange[];
|
|
69
|
+
get rowHeaderWidthAndMarginLeft(): number;
|
|
70
|
+
get columnHeaderHeightAndMarginTop(): number;
|
|
71
|
+
/**
|
|
72
|
+
* @deprecated
|
|
73
|
+
* @param config
|
|
74
|
+
* @param cellData
|
|
75
|
+
* @param styles
|
|
76
|
+
* @param LocaleService
|
|
77
|
+
* @returns
|
|
78
|
+
*/
|
|
79
|
+
static create(worksheet: Worksheet | undefined, config: IWorksheetData, cellData: ObjectMatrix<ICellData>, styles: Styles, LocaleService: LocaleService): SpreadsheetSkeleton;
|
|
80
|
+
/**
|
|
81
|
+
* @deprecated should never expose a property that is provided by another module!
|
|
82
|
+
* @returns
|
|
83
|
+
*/
|
|
84
|
+
getWorksheetConfig(): IWorksheetData;
|
|
85
|
+
/**
|
|
86
|
+
* @deprecated should never expose a property that is provided by another module!
|
|
87
|
+
* @returns
|
|
88
|
+
*/
|
|
89
|
+
getCellData(): ObjectMatrix<ICellData>;
|
|
90
|
+
/**
|
|
91
|
+
* @deprecated should never expose a property that is provided by another module!
|
|
92
|
+
* @returns
|
|
93
|
+
*/
|
|
94
|
+
getsStyles(): Styles;
|
|
95
|
+
setOverflowCache(value: ObjectMatrix<IRange>): void;
|
|
96
|
+
setMarginLeft(left: number): void;
|
|
97
|
+
setMarginTop(top: number): void;
|
|
98
|
+
calculateSegment(bounds?: IBoundRect): true | undefined;
|
|
99
|
+
calculateWithoutClearingCache(bounds?: IBoundRect): this | undefined;
|
|
100
|
+
calculate(bounds?: IBoundRect): this;
|
|
101
|
+
calculateAutoHeightInRange(ranges: Nullable<IRange[]>): IRowAutoHeightInfo[];
|
|
102
|
+
private _calculateRowAutoHeight;
|
|
103
|
+
updateLayout(): this | undefined;
|
|
104
|
+
getRowColumnSegment(bounds?: IBoundRect): {
|
|
105
|
+
startRow: number;
|
|
106
|
+
endRow: number;
|
|
107
|
+
startColumn: number;
|
|
108
|
+
endColumn: number;
|
|
109
|
+
};
|
|
110
|
+
getMergeBounding(startRow: number, startColumn: number, endRow: number, endColumn: number): {
|
|
111
|
+
startRow: number;
|
|
112
|
+
startColumn: number;
|
|
113
|
+
endRow: number;
|
|
114
|
+
endColumn: number;
|
|
115
|
+
};
|
|
116
|
+
appendToOverflowCache(row: number, column: number, startColumn: number, endColumn: number): void;
|
|
117
|
+
getColumnCount(): number;
|
|
118
|
+
getRowCount(): number;
|
|
119
|
+
getOverflowPosition(contentSize: {
|
|
120
|
+
width: number;
|
|
121
|
+
height: number;
|
|
122
|
+
}, horizontalAlign: HorizontalAlign, row: number, column: number, columnCount: number): {
|
|
123
|
+
startColumn: number;
|
|
124
|
+
endColumn: number;
|
|
125
|
+
};
|
|
126
|
+
getNoMergeCellPositionByIndex(rowIndex: number, columnIndex: number, scaleX: number, scaleY: number): {
|
|
127
|
+
startY: number;
|
|
128
|
+
endY: number;
|
|
129
|
+
startX: number;
|
|
130
|
+
endX: number;
|
|
131
|
+
};
|
|
132
|
+
getNoMergeCellPositionByIndexWithNoHeader(rowIndex: number, columnIndex: number, scaleX: number, scaleY: number): {
|
|
133
|
+
startY: number;
|
|
134
|
+
endY: number;
|
|
135
|
+
startX: number;
|
|
136
|
+
endX: number;
|
|
137
|
+
};
|
|
138
|
+
/**
|
|
139
|
+
*
|
|
140
|
+
* @param offsetX HTML coordinate system, mouse position x.
|
|
141
|
+
* @param offsetY HTML coordinate system, mouse position y.
|
|
142
|
+
* @param scaleX render scene scale x-axis, scene.getAncestorScale
|
|
143
|
+
* @param scaleY render scene scale y-axis, scene.getAncestorScale
|
|
144
|
+
* @param scrollXY render viewport scroll {x, y}, scene.getScrollXYByRelativeCoords, scene.getScrollXY
|
|
145
|
+
* @returns Selection data with coordinates
|
|
146
|
+
*/
|
|
147
|
+
calculateCellIndexByPosition(offsetX: number, offsetY: number, scaleX: number, scaleY: number, scrollXY: {
|
|
148
|
+
x: number;
|
|
149
|
+
y: number;
|
|
150
|
+
}): Nullable<ISelectionCellWithCoord>;
|
|
151
|
+
/**
|
|
152
|
+
*
|
|
153
|
+
* @param offsetX HTML coordinate system, mouse position x.
|
|
154
|
+
* @param offsetY HTML coordinate system, mouse position y.
|
|
155
|
+
* @param scaleX render scene scale x-axis, scene.getAncestorScale
|
|
156
|
+
* @param scaleY render scene scale y-axis, scene.getAncestorScale
|
|
157
|
+
* @param scrollXY render viewport scroll {x, y}, scene.getScrollXYByRelativeCoords, scene.getScrollXY
|
|
158
|
+
* @returns Hit cell coordinates
|
|
159
|
+
*/
|
|
160
|
+
getCellPositionByOffset(offsetX: number, offsetY: number, scaleX: number, scaleY: number, scrollXY: {
|
|
161
|
+
x: number;
|
|
162
|
+
y: number;
|
|
163
|
+
}): {
|
|
164
|
+
row: number;
|
|
165
|
+
column: number;
|
|
166
|
+
};
|
|
167
|
+
/**
|
|
168
|
+
*
|
|
169
|
+
* @param offsetX scaled offset x
|
|
170
|
+
* @param scaleX scale x
|
|
171
|
+
* @param scrollXY
|
|
172
|
+
* @returns
|
|
173
|
+
*/
|
|
174
|
+
getColumnPositionByOffsetX(offsetX: number, scaleX: number, scrollXY: {
|
|
175
|
+
x: number;
|
|
176
|
+
y: number;
|
|
177
|
+
}): number;
|
|
178
|
+
/**
|
|
179
|
+
*
|
|
180
|
+
* @param offsetY scaled offset y
|
|
181
|
+
* @param scaleY scale y
|
|
182
|
+
* @param scrollXY
|
|
183
|
+
* @returns
|
|
184
|
+
*/
|
|
185
|
+
getRowPositionByOffsetY(offsetY: number, scaleY: number, scrollXY: {
|
|
186
|
+
x: number;
|
|
187
|
+
y: number;
|
|
188
|
+
}): number;
|
|
189
|
+
getTransformOffsetX(offsetX: number, scaleX: number, scrollXY: {
|
|
190
|
+
x: number;
|
|
191
|
+
y: number;
|
|
192
|
+
}): number;
|
|
193
|
+
getTransformOffsetY(offsetY: number, scaleY: number, scrollXY: {
|
|
194
|
+
x: number;
|
|
195
|
+
y: number;
|
|
196
|
+
}): number;
|
|
197
|
+
getOffsetByPositionX(column: number): number;
|
|
198
|
+
getOffsetByPositionY(row: number): number;
|
|
199
|
+
/**
|
|
200
|
+
* Return cell information corresponding to the current coordinates, including the merged cell object.
|
|
201
|
+
* @param row Specified Row Coordinate
|
|
202
|
+
* @param column Specified Column Coordinate
|
|
203
|
+
* @param scaleX render scene scale x-axis, current Horizontal Scale, scene.getAncestorScale
|
|
204
|
+
* @param scaleY render scene scale y-axis, current Vertical Scale, scene.getAncestorScale
|
|
205
|
+
*/
|
|
206
|
+
getCellByIndex(row: number, column: number, scaleX: number, scaleY: number): ISelectionCellWithCoord;
|
|
207
|
+
getCellByIndexWithNoHeader(row: number, column: number, scaleX: number, scaleY: number): {
|
|
208
|
+
actualRow: number;
|
|
209
|
+
actualColumn: number;
|
|
210
|
+
startY: number;
|
|
211
|
+
endY: number;
|
|
212
|
+
startX: number;
|
|
213
|
+
endX: number;
|
|
214
|
+
isMerged: boolean;
|
|
215
|
+
isMergedMainCell: boolean;
|
|
216
|
+
mergeInfo: import("@univerjs/core").IRangeWithCoord;
|
|
217
|
+
};
|
|
218
|
+
convertTransformToOffsetX(offsetX: number, scaleX: number, scrollXY: {
|
|
219
|
+
x: number;
|
|
220
|
+
y: number;
|
|
221
|
+
}): number;
|
|
222
|
+
convertTransformToOffsetY(offsetY: number, scaleY: number, scrollXY: {
|
|
223
|
+
x: number;
|
|
224
|
+
y: number;
|
|
225
|
+
}): number;
|
|
226
|
+
getSelectionBounding(startRow: number, startColumn: number, endRow: number, endColumn: number): {
|
|
227
|
+
startRow: number;
|
|
228
|
+
startColumn: number;
|
|
229
|
+
endRow: number;
|
|
230
|
+
endColumn: number;
|
|
231
|
+
};
|
|
232
|
+
getBlankCellDocumentModel(cell: Nullable<ICellData>): IDocumentLayoutObject;
|
|
233
|
+
getCellDocumentModelWithFormula(cell: ICellData): Nullable<IDocumentLayoutObject>;
|
|
234
|
+
private _getCellDocumentModel;
|
|
235
|
+
getDecomposedOffset(offsetX: number, offsetY: number): {
|
|
236
|
+
row: number;
|
|
237
|
+
column: number;
|
|
238
|
+
columnOffset: number;
|
|
239
|
+
rowOffset: number;
|
|
240
|
+
};
|
|
241
|
+
/**
|
|
242
|
+
*
|
|
243
|
+
* @param rowHeightAccumulation Row layout information
|
|
244
|
+
* @param columnWidthAccumulation Column layout information
|
|
245
|
+
* @param bounds The range of the visible area of the canvas
|
|
246
|
+
* @returns The range cell index of the canvas visible area
|
|
247
|
+
*/
|
|
248
|
+
protected _getBounding(rowHeightAccumulation: number[], columnWidthAccumulation: number[], bounds?: IBoundRect): {
|
|
249
|
+
startRow: number;
|
|
250
|
+
endRow: number;
|
|
251
|
+
startColumn: number;
|
|
252
|
+
endColumn: number;
|
|
253
|
+
};
|
|
254
|
+
private _generateRowMatrixCache;
|
|
255
|
+
private _generateColumnMatrixCache;
|
|
256
|
+
private _getOverflowBound;
|
|
257
|
+
intersectMergeRange(row: number, column: number): boolean;
|
|
258
|
+
private _calculateStylesCache;
|
|
259
|
+
private _resetCache;
|
|
260
|
+
private _setCellCache;
|
|
261
|
+
private _updateConfigAndGetDocumentModel;
|
|
262
|
+
private _getDocumentDataByStyle;
|
|
263
|
+
private _setBorderProps;
|
|
264
|
+
private _getFontFormat;
|
|
265
|
+
private _getOtherStyle;
|
|
266
|
+
/**
|
|
267
|
+
* Cache the merged cells on the current screen to improve computational performance.
|
|
268
|
+
* @param mergeData all marge data
|
|
269
|
+
* @param rowColumnSegment current screen range, include row and column
|
|
270
|
+
* @returns
|
|
271
|
+
*/
|
|
272
|
+
private _getMergeCells;
|
|
273
|
+
}
|
|
274
|
+
export {};
|
|
275
|
+
//# sourceMappingURL=sheet-skeleton.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sheet-skeleton.d.ts","sourceRoot":"","sources":["../../../../src/components/sheets/sheet-skeleton.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAER,SAAS,EAIT,YAAY,EACZ,MAAM,EAEN,uBAAuB,EAGvB,aAAa,EAEb,cAAc,EACd,aAAa,EACb,QAAQ,EAER,MAAM,EAEN,SAAS,EACZ,MAAM,gBAAgB,CAAC;AACxB,OAAO,EACH,aAAa,EAEb,iBAAiB,EAEjB,eAAe,EAEf,YAAY,EAGZ,aAAa,EACb,YAAY,EACf,MAAM,gBAAgB,CAAC;AAgBxB,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAEvD,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAExD,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,KAAK,EAAe,YAAY,EAAE,MAAM,cAAc,CAAC;AAE9D;;;;;GAKG;AACH,wBAAgB,uBAAuB,CAAC,gBAAgB,EAAE,gBAAgB,EAAE,aAAa,GAAE,MAAU;;;cAuDpG;AAED,MAAM,WAAW,kBAAkB;IAC/B,GAAG,EAAE,MAAM,CAAC;IACZ,UAAU,CAAC,EAAE,MAAM,CAAC;CACvB;AA6BD,UAAU,iBAAiB;IACvB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,SAAS,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,qBAAqB;IAClC,aAAa,EAAE,QAAQ,CAAC,iBAAiB,CAAC,CAAC;IAC3C,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,aAAa,CAAC;IAC5B,YAAY,EAAE,YAAY,CAAC;IAC3B,aAAa,EAAE,aAAa,CAAC;IAC7B,eAAe,EAAE,eA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B,CAAC,GAAG,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM;IAyC/C,OAAO,CAAC,qBAAqB;IA0C7B,OAAO,CAAC,WAAW;IAUnB,OAAO,CAAC,aAAa;IA0FrB,OAAO,CAAC,gCAAgC;IA+BxC,OAAO,CAAC,uBAAuB;IAkE/B,OAAO,CAAC,eAAe;IAoBvB,OAAO,CAAC,cAAc;IAiBtB,OAAO,CAAC,cAAc;IA6BtB;;;;;OAKG;IACH,OAAO,CAAC,cAAc;CA4CzB"}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import type { IBoundRect } from '../../basics/vector2';
|
|
2
|
+
import { Vector2 } from '../../basics/vector2';
|
|
3
|
+
import { Documents } from '../docs/document';
|
|
4
|
+
import type { Background } from './extensions/background';
|
|
5
|
+
import type { Border } from './extensions/border';
|
|
6
|
+
import type { BorderAuxiliary } from './extensions/border-auxiliary';
|
|
7
|
+
import type { Font } from './extensions/font';
|
|
8
|
+
import { SheetComponent } from './sheet-component';
|
|
9
|
+
import type { SpreadsheetSkeleton } from './sheet-skeleton';
|
|
10
|
+
export declare class Spreadsheet extends SheetComponent {
|
|
11
|
+
private _allowCache;
|
|
12
|
+
private _borderAuxiliaryExtension;
|
|
13
|
+
private _backgroundExtension;
|
|
14
|
+
private _borderExtension;
|
|
15
|
+
private _fontExtension;
|
|
16
|
+
private _cacheCanvas;
|
|
17
|
+
private _boundsCache;
|
|
18
|
+
private _cacheOffsetX;
|
|
19
|
+
private _cacheOffsetY;
|
|
20
|
+
private _hasSelection;
|
|
21
|
+
private _documents;
|
|
22
|
+
constructor(oKey: string, spreadsheetSkeleton?: SpreadsheetSkeleton, _allowCache?: boolean);
|
|
23
|
+
get borderAuxiliaryExtension(): BorderAuxiliary;
|
|
24
|
+
get backgroundExtension(): Background;
|
|
25
|
+
get borderExtension(): Border;
|
|
26
|
+
get fontExtension(): Font;
|
|
27
|
+
getDocuments(): Documents;
|
|
28
|
+
draw(ctx: CanvasRenderingContext2D, bounds?: IBoundRect): void;
|
|
29
|
+
isHit(coord: Vector2): boolean;
|
|
30
|
+
getNoMergeCellPositionByIndex(rowIndex: number, columnIndex: number): {
|
|
31
|
+
startY: number;
|
|
32
|
+
endY: number;
|
|
33
|
+
startX: number;
|
|
34
|
+
endX: number;
|
|
35
|
+
} | undefined;
|
|
36
|
+
getScrollXYByRelativeCoords(coord: Vector2): {
|
|
37
|
+
x: number;
|
|
38
|
+
y: number;
|
|
39
|
+
};
|
|
40
|
+
getAncestorScrollXY(offsetX: number, offsetY: number): {
|
|
41
|
+
x: number;
|
|
42
|
+
y: number;
|
|
43
|
+
};
|
|
44
|
+
getSelectionBounding(startRow: number, startColumn: number, endRow: number, endColumn: number): {
|
|
45
|
+
startRow: number;
|
|
46
|
+
startColumn: number;
|
|
47
|
+
endRow: number;
|
|
48
|
+
endColumn: number;
|
|
49
|
+
} | undefined;
|
|
50
|
+
render(mainCtx: CanvasRenderingContext2D, bounds?: IBoundRect): this;
|
|
51
|
+
resizeCacheCanvas(): void;
|
|
52
|
+
private _checkNewBounds;
|
|
53
|
+
protected _applyCache(ctx?: CanvasRenderingContext2D): void;
|
|
54
|
+
protected _draw(ctx: CanvasRenderingContext2D, bounds?: IBoundRect): void;
|
|
55
|
+
private _getAncestorSize;
|
|
56
|
+
private _getAncestorParent;
|
|
57
|
+
private _initialDefaultExtension;
|
|
58
|
+
private _addMakeDirtyToScroll;
|
|
59
|
+
private _hasScrollViewportOperator;
|
|
60
|
+
private _getHasScrollViewports;
|
|
61
|
+
/**
|
|
62
|
+
* Calculate the overflow of cell text. If there is no value on either side of the cell,
|
|
63
|
+
* the text content of this cell can be drawn to both sides, not limited by the cell's width.
|
|
64
|
+
* Overflow on the left or right is aligned according to the text's horizontal alignment.
|
|
65
|
+
*/
|
|
66
|
+
private _calculateOverflow;
|
|
67
|
+
private _differentBounds;
|
|
68
|
+
private _checkSheetDifferentBounds;
|
|
69
|
+
}
|
|
70
|
+
//# sourceMappingURL=spreadsheet.d.ts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EAAE,wBAAwB,EAAE,MAAM,CAAC,EAAE,UAAU;IAyCvD,KAAK,CAAC,KAAK,EAAE,OAAO;IAapB,6BAA6B,CAAC,QAAQ,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM;;;;;;IA4BnE,2BAA2B,CAAC,KAAK,EAAE,OAAO;;;;IAiBnD,mBAAmB,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM;;;;IAyB3C,oBAAoB,CAAC,QAAQ,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM;;;;;;IAI7F,MAAM,CAAC,OAAO,EAAE,wBAAwB,EAAE,MAAM,CAAC,EAAE,UAAU;IA8C7D,iBAAiB;IAsC1B,OAAO,CAAC,eAAe;IAoBvB,SAAS,CAAC,WAAW,CAAC,GAAG,CAAC,EAAE,wBAAwB;cAwBjC,KAAK,CAAC,GAAG,EAAE,wBAAwB,EAAE,MAAM,CAAC,EAAE,UAAU;IAI3E,OAAO,CAAC,gBAAgB;IAqBxB,OAAO,CAAC,kBAAkB;IAU1B,OAAO,CAAC,wBAAwB;IAYhC,OAAO,CAAC,qBAAqB;IAQ7B,OAAO,CAAC,0BAA0B;IAgBlC,OAAO,CAAC,sBAAsB;IA2C9B;;;;OAIG;IACH,OAAO,CAAC,kBAAkB;IAsH1B,OAAO,CAAC,gBAAgB;IAgDxB,OAAO,CAAC,0BAA0B;CA8BrC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Disposable, LocaleService } from '@univerjs/core';
|
|
2
|
+
import type { IFontLocale } from '../basics/interfaces';
|
|
3
|
+
export declare class Skeleton extends Disposable {
|
|
4
|
+
protected readonly _localService: LocaleService;
|
|
5
|
+
private _fontLocale;
|
|
6
|
+
private _dirty;
|
|
7
|
+
constructor(_localService: LocaleService);
|
|
8
|
+
get dirty(): boolean;
|
|
9
|
+
getFontLocale(): IFontLocale;
|
|
10
|
+
makeDirty(state: boolean): void;
|
|
11
|
+
private _localeInitial;
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=skeleton.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"skeleton.d.ts","sourceRoot":"","sources":["../../../src/components/skeleton.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAG3D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAExD,qBAAa,QAAS,SAAQ,UAAU;IAKD,SAAS,CAAC,QAAQ,CAAC,aAAa,EAAE,aAAa;IAJlF,OAAO,CAAC,WAAW,CAAe;IAElC,OAAO,CAAC,MAAM,CAAQ;gBAEgC,aAAa,EAAE,aAAa;IAMlF,IAAI,KAAK,YAER;IAED,aAAa;IAIb,SAAS,CAAC,KAAK,EAAE,OAAO;IAIxB,OAAO,CAAC,cAAc;CAuBzB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/slides/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import type { Nullable } from '@univerjs/core';
|
|
2
|
+
import { Observable } from '@univerjs/core';
|
|
3
|
+
import type { Scene } from '../../scene';
|
|
4
|
+
import { SceneViewer } from '../../scene-viewer';
|
|
5
|
+
export declare enum SLIDE_NAVIGATION_KEY {
|
|
6
|
+
LEFT = "__slideNavigationLeft__",
|
|
7
|
+
RIGHT = "__slideNavigationRight__"
|
|
8
|
+
}
|
|
9
|
+
export declare class Slide extends SceneViewer {
|
|
10
|
+
onSlideChangePageByNavigationObservable: Observable<Nullable<string>>;
|
|
11
|
+
private _navigationEnabled;
|
|
12
|
+
activeFirstPage(): void;
|
|
13
|
+
addPage(scene: Scene): void;
|
|
14
|
+
changePage(id?: string): void;
|
|
15
|
+
hasPage(key: string): import("../../thin-scene").ThinScene | undefined;
|
|
16
|
+
addNavigation(): void;
|
|
17
|
+
removeNavigation(): void;
|
|
18
|
+
enableNav(): void;
|
|
19
|
+
disableNav(): void;
|
|
20
|
+
hiddenNav(): void;
|
|
21
|
+
showNav(): void;
|
|
22
|
+
renderToThumb(mainCtx: CanvasRenderingContext2D, pageId: string, scaleX?: number, scaleY?: number): void;
|
|
23
|
+
private _getSubScenesIndex;
|
|
24
|
+
private _addNavTrigger;
|
|
25
|
+
private _getArrowColor;
|
|
26
|
+
}
|
|
27
|
+
//# sourceMappingURL=slide.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"slide.d.ts","sourceRoot":"","sources":["../../../../src/components/slides/slide.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC/C,OAAO,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAM5C,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AACzC,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAGjD,oBAAY,oBAAoB;IAC5B,IAAI,4BAA4B;IAChC,KAAK,6BAA6B;CACrC;AAKD,qBAAa,KAAM,SAAQ,WAAW;IAClC,uCAAuC,+BAAsC;IAE7E,OAAO,CAAC,kBAAkB,CAAS;IAEnC,eAAe;IASf,OAAO,CAAC,KAAK,EAAE,KAAK;IASpB,UAAU,CAAC,EAAE,CAAC,EAAE,MAAM;IAStB,OAAO,CAAC,GAAG,EAAE,MAAM;IAInB,aAAa;IA+Cb,gBAAgB;IAUhB,SAAS;IAIT,UAAU;IAIV,SAAS;IAUT,OAAO;IAUP,aAAa,CAAC,OAAO,EAAE,wBAAwB,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAE,MAAU,EAAE,MAAM,GAAE,MAAU;IAWvG,OAAO,CAAC,kBAAkB;IA6B1B,OAAO,CAAC,cAAc;IAgBtB,OAAO,CAAC,cAAc;CAMzB"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { BaseObject } from '../base-object';
|
|
2
|
+
import type { IBoundRect, Vector2 } from '../basics/vector2';
|
|
3
|
+
export declare class CustomObject extends BaseObject {
|
|
4
|
+
private _render;
|
|
5
|
+
private _isHitCustom?;
|
|
6
|
+
constructor(key?: string, _render?: (mainCtx: CanvasRenderingContext2D) => void, _isHitCustom?: ((coord: Vector2) => boolean) | undefined);
|
|
7
|
+
toJson(): {
|
|
8
|
+
[x: string]: any;
|
|
9
|
+
};
|
|
10
|
+
render(mainCtx: CanvasRenderingContext2D, bounds?: IBoundRect): this;
|
|
11
|
+
isHit(coord: Vector2): boolean;
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=custom-object.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"custom-object.d.ts","sourceRoot":"","sources":["../../../src/custom/custom-object.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAE5C,OAAO,KAAK,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAE7D,qBAAa,YAAa,SAAQ,UAAU;IAGpC,OAAO,CAAC,OAAO;IACf,OAAO,CAAC,YAAY,CAAC;gBAFrB,GAAG,CAAC,EAAE,MAAM,EACJ,OAAO,aAAa,wBAAwB,SAAO,EACnD,YAAY,CAAC,WAAU,OAAO,KAAK,OAAO,aAAA;IAK7C,MAAM;;;IAMN,MAAM,CAAC,OAAO,EAAE,wBAAwB,EAAE,MAAM,CAAC,EAAE,UAAU;IAyB7D,KAAK,CAAC,KAAK,EAAE,OAAO;CAOhC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/custom/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC"}
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
import { Observable } from '@univerjs/core';
|
|
2
|
+
import type { CURSOR_TYPE } from './basics/const';
|
|
3
|
+
import { Canvas } from './canvas';
|
|
4
|
+
import type { Scene } from './scene';
|
|
5
|
+
import { ThinEngine } from './thin-engine';
|
|
6
|
+
export declare class Engine extends ThinEngine<Scene> {
|
|
7
|
+
renderEvenInBackground: boolean;
|
|
8
|
+
/**
|
|
9
|
+
* Observable raised when the engine begins a new frame
|
|
10
|
+
*/
|
|
11
|
+
onBeginFrameObservable: Observable<Engine>;
|
|
12
|
+
/**
|
|
13
|
+
* Observable raised when the engine ends the current frame
|
|
14
|
+
*/
|
|
15
|
+
onEndFrameObservable: Observable<Engine>;
|
|
16
|
+
private _container;
|
|
17
|
+
private _canvas;
|
|
18
|
+
private _canvasEle;
|
|
19
|
+
private _renderingQueueLaunched;
|
|
20
|
+
private _activeRenderLoops;
|
|
21
|
+
private _renderFunction;
|
|
22
|
+
private _requestNewFrameHandler;
|
|
23
|
+
private _frameId;
|
|
24
|
+
private _usingSafari;
|
|
25
|
+
private _fps;
|
|
26
|
+
private _deltaTime;
|
|
27
|
+
private _performanceMonitor;
|
|
28
|
+
private _pointerMoveEvent;
|
|
29
|
+
private _pointerDownEvent;
|
|
30
|
+
private _pointerUpEvent;
|
|
31
|
+
private _pointerBlurEvent;
|
|
32
|
+
private _pointerWheelEvent;
|
|
33
|
+
private _pointerEnterEvent;
|
|
34
|
+
private _pointerLeaveEvent;
|
|
35
|
+
/** previous pointer position */
|
|
36
|
+
private pointer;
|
|
37
|
+
private __mouseId;
|
|
38
|
+
private __isUsingFirefox;
|
|
39
|
+
constructor(elemWidth?: number, elemHeight?: number);
|
|
40
|
+
get width(): number;
|
|
41
|
+
get height(): number;
|
|
42
|
+
get requestNewFrameHandler(): number;
|
|
43
|
+
/**
|
|
44
|
+
* Gets the current frame id
|
|
45
|
+
*/
|
|
46
|
+
get frameId(): number;
|
|
47
|
+
setCanvasCursor(val: CURSOR_TYPE): void;
|
|
48
|
+
clearCanvas(): void;
|
|
49
|
+
getCanvas(): Canvas;
|
|
50
|
+
getCanvasElement(): HTMLCanvasElement;
|
|
51
|
+
getPixelRatio(): number;
|
|
52
|
+
setContainer(elem: HTMLElement): void;
|
|
53
|
+
resize(): void;
|
|
54
|
+
resizeBySize(width: number, height: number): void;
|
|
55
|
+
dispose(): void;
|
|
56
|
+
/**
|
|
57
|
+
* Register and execute a render loop. The engine can have more than one render function
|
|
58
|
+
* @param renderFunction defines the function to continuously execute
|
|
59
|
+
*/
|
|
60
|
+
runRenderLoop(renderFunction: () => void): void;
|
|
61
|
+
/**
|
|
62
|
+
* stop executing a render loop function and remove it from the execution array
|
|
63
|
+
* @param renderFunction defines the function to be removed. If not provided all functions will be removed.
|
|
64
|
+
*/
|
|
65
|
+
stopRenderLoop(renderFunction?: () => void): void;
|
|
66
|
+
/**
|
|
67
|
+
* Begin a new frame
|
|
68
|
+
*/
|
|
69
|
+
beginFrame(): void;
|
|
70
|
+
/**
|
|
71
|
+
* End the current frame
|
|
72
|
+
*/
|
|
73
|
+
endFrame(): void;
|
|
74
|
+
/**
|
|
75
|
+
* Gets the current framerate
|
|
76
|
+
* @returns a number representing the framerate
|
|
77
|
+
*/
|
|
78
|
+
getFps(): number;
|
|
79
|
+
/**
|
|
80
|
+
* Gets the time spent between current and previous frame
|
|
81
|
+
* @returns a number representing the delta time in ms
|
|
82
|
+
*/
|
|
83
|
+
getDeltaTime(): number;
|
|
84
|
+
_renderFrame(): void;
|
|
85
|
+
private _cancelFrame;
|
|
86
|
+
private _getHostWindow;
|
|
87
|
+
/** @hidden */
|
|
88
|
+
private _renderLoop;
|
|
89
|
+
private _measureFps;
|
|
90
|
+
private _handleKeyboardAction;
|
|
91
|
+
private _handlePointerAction;
|
|
92
|
+
private _getWheelEventName;
|
|
93
|
+
private _getPassive;
|
|
94
|
+
private __getPointerType;
|
|
95
|
+
}
|
|
96
|
+
//# sourceMappingURL=engine.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":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E,UAAU,GAAE,MAAY;IAQ7D,IAAa,KAAK,WAEjB;IAED,IAAa,MAAM,WAElB;IAED,IAAI,sBAAsB,WAEzB;IAED;;OAEG;IACH,IAAI,OAAO,IAAI,MAAM,CAEpB;IAEQ,eAAe,CAAC,GAAG,EAAE,WAAW;IAKhC,WAAW;IAIX,SAAS;IAIT,gBAAgB;IAIzB,aAAa;IAIb,YAAY,CAAC,IAAI,EAAE,WAAW;IAyB9B,MAAM;IAUN,YAAY,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM;IAiBjC,OAAO;IAkBhB;;;OAGG;IACH,aAAa,CAAC,cAAc,EAAE,MAAM,IAAI,GAAG,IAAI;IAc/C;;;OAGG;IACH,cAAc,CAAC,cAAc,CAAC,EAAE,MAAM,IAAI,GAAG,IAAI;IAiBjD;;OAEG;IACH,UAAU,IAAI,IAAI;IAKlB;;OAEG;IACH,QAAQ,IAAI,IAAI;IAOhB;;;OAGG;IACH,MAAM,IAAI,MAAM;IAIhB;;;OAGG;IACH,YAAY,IAAI,MAAM;IAItB,YAAY;IAQZ,OAAO,CAAC,YAAY;IAiBpB,OAAO,CAAC,cAAc;IAYtB,cAAc;IACd,OAAO,CAAC,WAAW;IAqBnB,OAAO,CAAC,WAAW;IAMnB,OAAO,CAAC,qBAAqB;IA0B7B,OAAO,CAAC,oBAAoB;IAwP5B,OAAO,CAAC,kBAAkB;IAU1B,OAAO,CAAC,WAAW;IA0BnB,OAAO,CAAC,gBAAgB;CAS3B"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { BaseObject } from './base-object';
|
|
2
|
+
import type { CURSOR_TYPE } from './basics/const';
|
|
3
|
+
import { RENDER_CLASS_TYPE } from './basics/const';
|
|
4
|
+
import type { IBoundRect, Vector2 } from './basics/vector2';
|
|
5
|
+
export declare class Group extends BaseObject {
|
|
6
|
+
private _objects;
|
|
7
|
+
constructor(key?: string, ...objects: BaseObject[]);
|
|
8
|
+
get classType(): RENDER_CLASS_TYPE;
|
|
9
|
+
set cursor(val: CURSOR_TYPE);
|
|
10
|
+
addObjects(...objects: BaseObject[]): void;
|
|
11
|
+
addObject(o: BaseObject | string): void;
|
|
12
|
+
removeObject(object: BaseObject | string): void;
|
|
13
|
+
getObjectsByOrder(): BaseObject[];
|
|
14
|
+
getObjects(): BaseObject[];
|
|
15
|
+
render(ctx: CanvasRenderingContext2D, bounds?: IBoundRect): void;
|
|
16
|
+
resize(width?: number | string, height?: number | string): this;
|
|
17
|
+
scale(scaleX?: number, scaleY?: number): this;
|
|
18
|
+
skew(skewX?: number, skewY?: number): this;
|
|
19
|
+
flip(flipX?: boolean, flipY?: boolean): this;
|
|
20
|
+
isHit(coord: Vector2): boolean;
|
|
21
|
+
pick(coord: Vector2): void;
|
|
22
|
+
dispose(): void;
|
|
23
|
+
private _transformBounds;
|
|
24
|
+
}
|
|
25
|
+
//# sourceMappingURL=group.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"group.d.ts","sourceRoot":"","sources":["../../src/group.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAClD,OAAO,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AAEnD,OAAO,KAAK,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAG5D,qBAAa,KAAM,SAAQ,UAAU;IACjC,OAAO,CAAC,QAAQ,CAAoB;gBAExB,GAAG,CAAC,EAAE,MAAM,EAAE,GAAG,OAAO,EAAE,UAAU,EAAE;IAKlD,IAAa,SAAS,sBAErB;IAED,IAAa,MAAM,CAAC,GAAG,EAAE,WAAW,EAEnC;IAED,UAAU,CAAC,GAAG,OAAO,EAAE,UAAU,EAAE;IAMnC,SAAS,CAAC,CAAC,EAAE,UAAU,GAAG,MAAM;IA4BhC,YAAY,CAAC,MAAM,EAAE,UAAU,GAAG,MAAM;IAyBxC,iBAAiB;IAWR,UAAU;IAIV,MAAM,CAAC,GAAG,EAAE,wBAAwB,EAAE,MAAM,CAAC,EAAE,UAAU;IAWzD,MAAM,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,MAAM;IAIxD,KAAK,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,MAAM;IAItC,IAAI,CAAC,KAAK,CAAC,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,MAAM;IAInC,IAAI,CAAC,KAAK,CAAC,EAAE,OAAO,EAAE,KAAK,CAAC,EAAE,OAAO;IAKrC,KAAK,CAAC,KAAK,EAAE,OAAO;IAK7B,IAAI,CAAC,KAAK,EAAE,OAAO;IAEV,OAAO;IAOhB,OAAO,CAAC,gBAAgB;CAG3B"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export * from './base-object';
|
|
2
|
+
export * from './basics';
|
|
3
|
+
export * from './canvas';
|
|
4
|
+
export * from './components';
|
|
5
|
+
export { DocumentViewModel } from './components/docs/view-model/document-view-model';
|
|
6
|
+
export * from './custom';
|
|
7
|
+
export * from './engine';
|
|
8
|
+
export * from './group';
|
|
9
|
+
export * from './layer';
|
|
10
|
+
export { IRenderingEngine, RenderEngine } from './render-engine';
|
|
11
|
+
export * from './render-manager.service';
|
|
12
|
+
export * from './scene';
|
|
13
|
+
export * from './scene-viewer';
|
|
14
|
+
export * from './scroll-timer';
|
|
15
|
+
export * from './shape';
|
|
16
|
+
export * from './viewport';
|
|
17
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,OAAO,EAAE,iBAAiB,EAAE,MAAM,kDAAkD,CAAC;AACrF,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,SAAS,CAAC;AACxB,cAAc,SAAS,CAAC;AACxB,OAAO,EAAE,gBAAgB,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AACjE,cAAc,0BAA0B,CAAC;AACzC,cAAc,SAAS,CAAC;AACxB,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,SAAS,CAAC;AACxB,cAAc,YAAY,CAAC"}
|