@visactor/vrender 0.10.0-alpha.1 → 0.10.0
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/cjs/color-string/interpolate.js +8 -1
- package/cjs/color-string/interpolate.js.map +1 -1
- package/cjs/core/contributions/env/browser-contribution.d.ts +2 -0
- package/cjs/core/contributions/env/browser-contribution.js +13 -0
- package/cjs/core/contributions/env/browser-contribution.js.map +1 -1
- package/cjs/core/global.d.ts +1 -1
- package/cjs/core/global.js +2 -2
- package/cjs/core/global.js.map +1 -1
- package/cjs/event/event-system.js +1 -1
- package/cjs/event/event-system.js.map +1 -1
- package/cjs/graphic/theme.d.ts +1 -1
- package/cjs/graphic/theme.js +14 -6
- package/cjs/graphic/theme.js.map +1 -1
- package/cjs/index.d.ts +1 -0
- package/cjs/index.js +19 -18
- package/cjs/index.js.map +1 -1
- package/cjs/interface/global.d.ts +3 -3
- package/cjs/interface/global.js.map +1 -1
- package/cjs/interface/graphic/theme.d.ts +1 -1
- package/cjs/interface/graphic/theme.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.min.js +1 -1
- package/es/color-string/interpolate.js +8 -1
- package/es/color-string/interpolate.js.map +1 -1
- package/es/core/contributions/env/browser-contribution.d.ts +2 -0
- package/es/core/contributions/env/browser-contribution.js +13 -0
- package/es/core/contributions/env/browser-contribution.js.map +1 -1
- package/es/core/global.d.ts +1 -1
- package/es/core/global.js +2 -2
- package/es/core/global.js.map +1 -1
- package/es/event/event-system.js +1 -1
- package/es/event/event-system.js.map +1 -1
- package/es/graphic/theme.d.ts +1 -1
- package/es/graphic/theme.js +15 -5
- package/es/graphic/theme.js.map +1 -1
- package/es/index.d.ts +1 -0
- package/es/index.js +2 -0
- package/es/index.js.map +1 -1
- package/es/interface/global.d.ts +3 -3
- package/es/interface/global.js.map +1 -1
- package/es/interface/graphic/theme.d.ts +1 -1
- package/es/interface/graphic/theme.js.map +1 -1
- package/es/tsconfig.tsbuildinfo +1 -1
- package/package.json +3 -3
package/cjs/index.js
CHANGED
|
@@ -17,22 +17,23 @@ var __createBinding = this && this.__createBinding || (Object.create ? function(
|
|
|
17
17
|
|
|
18
18
|
Object.defineProperty(exports, "__esModule", {
|
|
19
19
|
value: !0
|
|
20
|
-
}), require("reflect-metadata"), require("./modules"),
|
|
21
|
-
__exportStar(require("./
|
|
22
|
-
__exportStar(require("./
|
|
23
|
-
__exportStar(require("./
|
|
24
|
-
__exportStar(require("./
|
|
25
|
-
__exportStar(require("./
|
|
26
|
-
__exportStar(require("./
|
|
27
|
-
__exportStar(require("./
|
|
28
|
-
__exportStar(require("./common/
|
|
29
|
-
__exportStar(require("./common/
|
|
30
|
-
__exportStar(require("./common/
|
|
31
|
-
__exportStar(require("./common/
|
|
32
|
-
__exportStar(require("./common/
|
|
33
|
-
__exportStar(require("./common/shape/
|
|
34
|
-
__exportStar(require("./common/
|
|
35
|
-
__exportStar(require("./common/render-
|
|
36
|
-
__exportStar(require("./common/
|
|
37
|
-
__exportStar(require("./common/
|
|
20
|
+
}), exports.version = void 0, require("reflect-metadata"), require("./modules"),
|
|
21
|
+
exports.version = "0.10.0", __exportStar(require("./container"), exports), __exportStar(require("./core/global"), exports),
|
|
22
|
+
__exportStar(require("./graphic"), exports), __exportStar(require("./modules"), exports),
|
|
23
|
+
__exportStar(require("./create"), exports), __exportStar(require("./event"), exports),
|
|
24
|
+
__exportStar(require("./interface"), exports), __exportStar(require("./render"), exports),
|
|
25
|
+
__exportStar(require("./canvas"), exports), __exportStar(require("./core"), exports),
|
|
26
|
+
__exportStar(require("./picker"), exports), __exportStar(require("./kits"), exports),
|
|
27
|
+
__exportStar(require("./animate"), exports), __exportStar(require("./resource-loader/loader"), exports),
|
|
28
|
+
__exportStar(require("./common/text"), exports), __exportStar(require("./common/bezier-utils"), exports),
|
|
29
|
+
__exportStar(require("./common/bounds-context"), exports), __exportStar(require("./common/seg-context"), exports),
|
|
30
|
+
__exportStar(require("./common/custom-path2d"), exports), __exportStar(require("./common/segment"), exports),
|
|
31
|
+
__exportStar(require("./common/canvas-utils"), exports), __exportStar(require("./common/contribution-provider"), exports),
|
|
32
|
+
__exportStar(require("./common/generator"), exports), __exportStar(require("./common/utils"), exports),
|
|
33
|
+
__exportStar(require("./common/shape/arc"), exports), __exportStar(require("./common/shape/rect"), exports),
|
|
34
|
+
__exportStar(require("./common/path-svg"), exports), __exportStar(require("./common/render-curve"), exports),
|
|
35
|
+
__exportStar(require("./common/render-area"), exports), __exportStar(require("./common/render-command-list"), exports),
|
|
36
|
+
__exportStar(require("./common/sort"), exports), __exportStar(require("./common/morphing-utils"), exports),
|
|
37
|
+
__exportStar(require("./common/split-path"), exports), __exportStar(require("./common/enums"), exports),
|
|
38
|
+
__exportStar(require("./animate/default-ticker"), exports);
|
|
38
39
|
//# sourceMappingURL=index.js.map
|
package/cjs/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"sources":["../../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,4BAA0B;AAC1B,qBAAmB;AAGN,QAAA,OAAO,GAAG,QAAQ,CAAC;AAEhC,8CAA4B;AAC5B,gDAA8B;AAC9B,4CAA0B;AAC1B,4CAA0B;AAC1B,2CAAyB;AACzB,0CAAwB;AACxB,8CAA4B;AAC5B,2CAAyB;AACzB,2CAAyB;AACzB,yCAAuB;AACvB,2CAAyB;AACzB,yCAAuB;AACvB,4CAA0B;AAC1B,2DAAyC;AAGzC,gDAA8B;AAC9B,wDAAsC;AACtC,0DAAwC;AACxC,uDAAqC;AACrC,yDAAuC;AACvC,mDAAiC;AACjC,wDAAsC;AACtC,iEAA+C;AAC/C,qDAAmC;AACnC,iDAA+B;AAC/B,qDAAmC;AACnC,sDAAoC;AAEpC,oDAAkC;AAClC,wDAAsC;AACtC,uDAAqC;AACrC,+DAA6C;AAC7C,gDAA8B;AAC9B,0DAAwC;AACxC,sDAAoC;AACpC,iDAA+B;AAE/B,2DAAyC","file":"index.js","sourcesContent":["import 'reflect-metadata';\nimport './modules';\n\n// 导出版本号\nexport const version = \"0.10.0\";\n\nexport * from './container';\nexport * from './core/global';\nexport * from './graphic';\nexport * from './modules';\nexport * from './create';\nexport * from './event';\nexport * from './interface';\nexport * from './render';\nexport * from './canvas';\nexport * from './core';\nexport * from './picker';\nexport * from './kits';\nexport * from './animate';\nexport * from './resource-loader/loader';\n\n/* export common */\nexport * from './common/text';\nexport * from './common/bezier-utils';\nexport * from './common/bounds-context';\nexport * from './common/seg-context';\nexport * from './common/custom-path2d';\nexport * from './common/segment';\nexport * from './common/canvas-utils';\nexport * from './common/contribution-provider';\nexport * from './common/generator';\nexport * from './common/utils';\nexport * from './common/shape/arc';\nexport * from './common/shape/rect';\n\nexport * from './common/path-svg';\nexport * from './common/render-curve';\nexport * from './common/render-area';\nexport * from './common/render-command-list';\nexport * from './common/sort';\nexport * from './common/morphing-utils';\nexport * from './common/split-path';\nexport * from './common/enums';\n\nexport * from './animate/default-ticker';\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Dict,
|
|
1
|
+
import { Dict, IPointLike } from '@visactor/vutils';
|
|
2
2
|
import type { SyncHook } from '../tapable';
|
|
3
3
|
import { ICanvasLike } from './canvas';
|
|
4
4
|
import { IEventElement } from './common';
|
|
@@ -36,7 +36,7 @@ export interface IEnvContribution extends IContribution<IGlobal>, Omit<IEventEle
|
|
|
36
36
|
supportsPointerEvents: boolean;
|
|
37
37
|
supportsMouseEvents: boolean;
|
|
38
38
|
applyStyles?: boolean;
|
|
39
|
-
mapToCanvasPoint?: (event: any) =>
|
|
39
|
+
mapToCanvasPoint?: (event: any, domElement?: any) => IPointLike | null;
|
|
40
40
|
loadImage: (url: string) => Promise<{
|
|
41
41
|
loadState: 'success' | 'fail';
|
|
42
42
|
data: HTMLImageElement | ImageData | null;
|
|
@@ -100,7 +100,7 @@ export interface IGlobal extends Omit<IEventElement, 'on' | 'off' | 'once' | 'em
|
|
|
100
100
|
measureTextMethod: 'native' | 'simple' | 'quick';
|
|
101
101
|
getRequestAnimationFrame: () => null | ((callback: FrameRequestCallback) => number);
|
|
102
102
|
getCancelAnimationFrame: () => null | ((h: number) => void);
|
|
103
|
-
mapToCanvasPoint: (nativeEvent: any) =>
|
|
103
|
+
mapToCanvasPoint: (nativeEvent: any, domElement?: any) => IPointLike | null;
|
|
104
104
|
loadImage: (url: string) => Promise<{
|
|
105
105
|
loadState: 'success' | 'fail';
|
|
106
106
|
data: HTMLImageElement | ImageData | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/interface/global.ts"],"names":[],"mappings":";;;AAca,QAAA,eAAe,GAAG,MAAM,CAAC,GAAG,CAAC,iBAAiB,CAAC,CAAC;AA4HhD,QAAA,MAAM,GAAG,MAAM,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC","file":"global.js","sourcesContent":["import { Dict, IPoint } from '@visactor/vutils';\nimport type { SyncHook } from '../tapable';\nimport { ICanvasLike } from './canvas';\nimport { IEventElement } from './common';\nimport { IContribution } from './contribution';\n\nexport interface ILoader {\n loadImage: (url: string) => HTMLImageElement | ImageData;\n loadJson: (url: string) => JSON;\n}\n\n// 环境定义\nexport type EnvType = 'browser' | 'feishu' | 'tt' | 'taro' | 'node' | 'native' | 'lynx';\n\nexport const EnvContribution = Symbol.for('EnvContribution');\n\n// 创建canvas需要的参数\nexport interface ICreateCanvasParams {\n id?: string;\n // 像素宽\n width?: number;\n // 像素高\n height?: number;\n dpr?: number;\n}\n\nexport interface ILoader {\n loadImage: (url: string) => HTMLImageElement | ImageData;\n loadJson: (url: string) => JSON;\n}\n\nexport interface IEnvContribution\n extends IContribution<IGlobal>,\n Omit<IEventElement, 'on' | 'off' | 'once' | 'emit' | 'removeAllListeners'> {\n // 当前代码所运行的环境\n type: EnvType;\n\n // 是否支持事件\n // node环境不需要事件\n supportEvent: boolean;\n\n // 开始配置环境,相当于init\n configure: (global: IGlobal, ...p: any) => void;\n\n // 创建销毁\n createCanvas: (params: ICreateCanvasParams) => ICanvasLike | any;\n createOffscreenCanvas: (params: ICreateCanvasParams) => ICanvasLike | any;\n releaseCanvas: (canvas: ICanvasLike | string | any) => void;\n\n // 设备信息\n getDevicePixelRatio: () => number;\n\n // 通用接口\n getRequestAnimationFrame: () => (callback: FrameRequestCallback) => number;\n getCancelAnimationFrame: () => (h: number) => void;\n\n // DOM接口\n getElementById?: (str: string) => HTMLElement | null;\n getRootElement?: () => HTMLElement | null;\n /**\n * get document instance\n */\n getDocument?: () => Document | null;\n /**\n * whether supports TouchEvent.\n */\n supportsTouchEvents: boolean;\n /**\n * whether supports PointerEvent.\n */\n supportsPointerEvents: boolean;\n /**\n * whether supports MouseEvent.\n */\n supportsMouseEvents: boolean;\n /**\n * Whether to allow setting the cursor style\n */\n applyStyles?: boolean;\n\n /**\n * 将窗口坐标转换为画布坐标,小程序/小组件环境需要兼容\n */\n mapToCanvasPoint?: (event: any) =>
|
|
1
|
+
{"version":3,"sources":["../../src/interface/global.ts"],"names":[],"mappings":";;;AAca,QAAA,eAAe,GAAG,MAAM,CAAC,GAAG,CAAC,iBAAiB,CAAC,CAAC;AA4HhD,QAAA,MAAM,GAAG,MAAM,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC","file":"global.js","sourcesContent":["import { Dict, IPoint, IPointLike } from '@visactor/vutils';\nimport type { SyncHook } from '../tapable';\nimport { ICanvasLike } from './canvas';\nimport { IEventElement } from './common';\nimport { IContribution } from './contribution';\n\nexport interface ILoader {\n loadImage: (url: string) => HTMLImageElement | ImageData;\n loadJson: (url: string) => JSON;\n}\n\n// 环境定义\nexport type EnvType = 'browser' | 'feishu' | 'tt' | 'taro' | 'node' | 'native' | 'lynx';\n\nexport const EnvContribution = Symbol.for('EnvContribution');\n\n// 创建canvas需要的参数\nexport interface ICreateCanvasParams {\n id?: string;\n // 像素宽\n width?: number;\n // 像素高\n height?: number;\n dpr?: number;\n}\n\nexport interface ILoader {\n loadImage: (url: string) => HTMLImageElement | ImageData;\n loadJson: (url: string) => JSON;\n}\n\nexport interface IEnvContribution\n extends IContribution<IGlobal>,\n Omit<IEventElement, 'on' | 'off' | 'once' | 'emit' | 'removeAllListeners'> {\n // 当前代码所运行的环境\n type: EnvType;\n\n // 是否支持事件\n // node环境不需要事件\n supportEvent: boolean;\n\n // 开始配置环境,相当于init\n configure: (global: IGlobal, ...p: any) => void;\n\n // 创建销毁\n createCanvas: (params: ICreateCanvasParams) => ICanvasLike | any;\n createOffscreenCanvas: (params: ICreateCanvasParams) => ICanvasLike | any;\n releaseCanvas: (canvas: ICanvasLike | string | any) => void;\n\n // 设备信息\n getDevicePixelRatio: () => number;\n\n // 通用接口\n getRequestAnimationFrame: () => (callback: FrameRequestCallback) => number;\n getCancelAnimationFrame: () => (h: number) => void;\n\n // DOM接口\n getElementById?: (str: string) => HTMLElement | null;\n getRootElement?: () => HTMLElement | null;\n /**\n * get document instance\n */\n getDocument?: () => Document | null;\n /**\n * whether supports TouchEvent.\n */\n supportsTouchEvents: boolean;\n /**\n * whether supports PointerEvent.\n */\n supportsPointerEvents: boolean;\n /**\n * whether supports MouseEvent.\n */\n supportsMouseEvents: boolean;\n /**\n * Whether to allow setting the cursor style\n */\n applyStyles?: boolean;\n\n /**\n * 将窗口坐标转换为画布坐标,小程序/小组件环境需要兼容\n */\n mapToCanvasPoint?: (event: any, domElement?: any) => IPointLike | null;\n\n loadImage: (url: string) => Promise<{\n loadState: 'success' | 'fail';\n data: HTMLImageElement | ImageData | null;\n }>;\n loadSvg: (url: string) => Promise<{\n loadState: 'success' | 'fail';\n data: HTMLImageElement | ImageData | null;\n }>;\n loadJson: (url: string) => Promise<{\n loadState: 'success' | 'fail';\n data: Record<string, unknown> | null;\n }>;\n loadArrayBuffer: (url: string) => Promise<{\n loadState: 'success' | 'fail';\n data: ArrayBuffer | null;\n }>;\n loadBlob: (url: string) => Promise<{\n loadState: 'success' | 'fail';\n data: Blob | null;\n }>;\n}\n\nexport type IMiniAppEnvParams = {\n /** dom 容器对象 */\n domref?: Dict<any>;\n /**\n * 强行设置env,如果env重复设置也设置\n */\n force?: boolean;\n /**\n * 可用的canvas列表\n */\n canvasIdLists?: (string | number)[];\n /**\n * 表示可以自由使用的canvas索引\n */\n freeCanvasIdx?: string | number;\n /** taro 环境使用 */\n taro?: any;\n pixelRatio?: number;\n [key: string]: any;\n};\n\nexport interface IEnvParamsMap {\n readonly taro: IMiniAppEnvParams;\n readonly feishu: IMiniAppEnvParams;\n readonly tt: IMiniAppEnvParams;\n readonly browser: any;\n readonly node: any;\n readonly native: any;\n readonly lynx: any;\n}\n\nexport const Global = Symbol.for('Global');\nexport interface IGlobal extends Omit<IEventElement, 'on' | 'off' | 'once' | 'emit' | 'removeAllListeners'> {\n // 当前代码所运行的环境\n env: EnvType;\n\n // 设备的dpr\n devicePixelRatio: number;\n\n // 当设置env的时候被调用\n hooks: {\n onSetEnv: SyncHook<[EnvType | undefined, EnvType, IGlobal]>;\n };\n\n // 设置env的时候传入的参数\n // node环境需要传入整个node-canvas包\n // 小程序环境需要传入小程序要用到的参数\n envParams?: any;\n\n // 是否支持事件\n // node环境不需要事件\n supportEvent: boolean;\n\n setEnv: (env: EnvType, params?: IEnvParamsMap[EnvType]) => void;\n setActiveEnvContribution: (contribution: IEnvContribution) => void;\n createCanvas: (params: ICreateCanvasParams) => HTMLCanvasElement | any;\n createOffscreenCanvas: (params: ICreateCanvasParams) => HTMLCanvasElement | any;\n releaseCanvas: (canvas: HTMLCanvasElement | string | any) => void;\n\n /* 浏览器环境 - dom tree */\n getElementById: (str: string) => HTMLElement | null;\n getRootElement: () => HTMLElement | null;\n /**\n * get document instance\n */\n getDocument: () => Document | null;\n /**\n * whether supports TouchEvent.\n */\n supportsTouchEvents: boolean;\n /**\n * whether supports PointerEvent.\n */\n supportsPointerEvents: boolean;\n /**\n * whether supports MouseEvent.\n */\n supportsMouseEvents: boolean;\n /**\n * Whether to allow setting the cursor style\n */\n applyStyles?: boolean;\n /**\n * 测量文字的方法\n */\n measureTextMethod: 'native' | 'simple' | 'quick';\n\n getRequestAnimationFrame: () => null | ((callback: FrameRequestCallback) => number);\n getCancelAnimationFrame: () => null | ((h: number) => void);\n\n /**\n * 将窗口坐标转换为画布坐标,小程序/小组件环境需要兼容\n */\n mapToCanvasPoint: (nativeEvent: any, domElement?: any) => IPointLike | null;\n\n loadImage: (url: string) => Promise<{\n loadState: 'success' | 'fail';\n data: HTMLImageElement | ImageData | null;\n }>;\n loadSvg: (url: string) => Promise<{\n loadState: 'success' | 'fail';\n data: HTMLImageElement | ImageData | null;\n }>;\n loadJson: (url: string) => Promise<{\n loadState: 'success' | 'fail';\n data: Record<string, unknown> | null;\n }>;\n loadArrayBuffer: (url: string) => Promise<{\n loadState: 'success' | 'fail';\n data: ArrayBuffer | null;\n }>;\n loadBlob: (url: string) => Promise<{\n loadState: 'success' | 'fail';\n data: Blob | null;\n }>;\n}\n"]}
|
|
@@ -50,7 +50,7 @@ export interface ITheme {
|
|
|
50
50
|
combinedTheme?: IFullThemeSpec;
|
|
51
51
|
userTheme?: IThemeSpec;
|
|
52
52
|
nextTheme?: IThemeSpec;
|
|
53
|
-
applyTheme: (group: IGroup, pt: IThemeSpec) => IThemeSpec;
|
|
53
|
+
applyTheme: (group: IGroup, pt: IThemeSpec, force?: boolean) => IThemeSpec;
|
|
54
54
|
setTheme: (t: IThemeSpec, g: IGroup) => void;
|
|
55
55
|
dirty: boolean;
|
|
56
56
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/interface/graphic/theme.ts"],"names":[],"mappings":"","file":"theme.js","sourcesContent":["import type { IGraphicAttribute } from '../graphic';\nimport type { IArcGraphicAttribute } from './arc';\nimport type { IAreaGraphicAttribute } from './area';\nimport type { ICircleGraphicAttribute } from './circle';\nimport type { IGlyphGraphicAttribute } from './glyph';\nimport type { IGroup, IGroupGraphicAttribute } from './group';\nimport type { IImageGraphicAttribute } from './image';\nimport type { ILineGraphicAttribute } from './line';\nimport type { IPathGraphicAttribute } from './path';\nimport type { IPolygonGraphicAttribute } from './polygon';\nimport type { IRectGraphicAttribute } from './rect';\nimport type { IRect3dGraphicAttribute } from './rect3d';\nimport type { IRichTextGraphicAttribute, IRichTextIconGraphicAttribute } from './richText';\nimport type { ISymbolGraphicAttribute } from './symbol';\nimport type { ITextGraphicAttribute } from './text';\n\nexport interface IThemeSpec {\n text?: Partial<ITextGraphicAttribute>;\n rect?: Partial<IRectGraphicAttribute>;\n rect3d?: Partial<IRect3dGraphicAttribute>;\n arc?: Partial<IArcGraphicAttribute>;\n area?: Partial<IAreaGraphicAttribute>;\n circle?: Partial<ICircleGraphicAttribute>;\n line?: Partial<ILineGraphicAttribute>;\n path?: Partial<IPathGraphicAttribute>;\n symbol?: Partial<ISymbolGraphicAttribute>;\n group?: Partial<IGroupGraphicAttribute>;\n polygon?: Partial<IPolygonGraphicAttribute>;\n image?: Partial<IImageGraphicAttribute>;\n common?: Partial<IGraphicAttribute>;\n}\n\nexport interface IFullThemeSpec {\n arc: Required<IArcGraphicAttribute>;\n area: Required<IAreaGraphicAttribute>;\n circle: Required<ICircleGraphicAttribute>;\n line: Required<ILineGraphicAttribute>;\n path: Required<IPathGraphicAttribute>;\n symbol: Required<ISymbolGraphicAttribute>;\n text: Required<ITextGraphicAttribute>;\n rect: Required<IRectGraphicAttribute>;\n rect3d: Required<IRect3dGraphicAttribute>;\n glyph: Required<IGlyphGraphicAttribute>;\n group: Required<IGroupGraphicAttribute>;\n polygon: Required<IPolygonGraphicAttribute>;\n richtext: Required<IRichTextGraphicAttribute>;\n richtextIcon: Required<IRichTextIconGraphicAttribute>;\n image: Required<IImageGraphicAttribute>;\n}\n\nexport interface ITheme {\n getTheme: (g: IGroup) => IFullThemeSpec;\n combinedTheme?: IFullThemeSpec;\n userTheme?: IThemeSpec;\n nextTheme?: IThemeSpec;\n applyTheme: (group: IGroup, pt: IThemeSpec) => IThemeSpec;\n setTheme: (t: IThemeSpec, g: IGroup) => void;\n dirty: boolean;\n}\n"]}
|
|
1
|
+
{"version":3,"sources":["../../src/interface/graphic/theme.ts"],"names":[],"mappings":"","file":"theme.js","sourcesContent":["import type { IGraphicAttribute } from '../graphic';\nimport type { IArcGraphicAttribute } from './arc';\nimport type { IAreaGraphicAttribute } from './area';\nimport type { ICircleGraphicAttribute } from './circle';\nimport type { IGlyphGraphicAttribute } from './glyph';\nimport type { IGroup, IGroupGraphicAttribute } from './group';\nimport type { IImageGraphicAttribute } from './image';\nimport type { ILineGraphicAttribute } from './line';\nimport type { IPathGraphicAttribute } from './path';\nimport type { IPolygonGraphicAttribute } from './polygon';\nimport type { IRectGraphicAttribute } from './rect';\nimport type { IRect3dGraphicAttribute } from './rect3d';\nimport type { IRichTextGraphicAttribute, IRichTextIconGraphicAttribute } from './richText';\nimport type { ISymbolGraphicAttribute } from './symbol';\nimport type { ITextGraphicAttribute } from './text';\n\nexport interface IThemeSpec {\n text?: Partial<ITextGraphicAttribute>;\n rect?: Partial<IRectGraphicAttribute>;\n rect3d?: Partial<IRect3dGraphicAttribute>;\n arc?: Partial<IArcGraphicAttribute>;\n area?: Partial<IAreaGraphicAttribute>;\n circle?: Partial<ICircleGraphicAttribute>;\n line?: Partial<ILineGraphicAttribute>;\n path?: Partial<IPathGraphicAttribute>;\n symbol?: Partial<ISymbolGraphicAttribute>;\n group?: Partial<IGroupGraphicAttribute>;\n polygon?: Partial<IPolygonGraphicAttribute>;\n image?: Partial<IImageGraphicAttribute>;\n common?: Partial<IGraphicAttribute>;\n}\n\nexport interface IFullThemeSpec {\n arc: Required<IArcGraphicAttribute>;\n area: Required<IAreaGraphicAttribute>;\n circle: Required<ICircleGraphicAttribute>;\n line: Required<ILineGraphicAttribute>;\n path: Required<IPathGraphicAttribute>;\n symbol: Required<ISymbolGraphicAttribute>;\n text: Required<ITextGraphicAttribute>;\n rect: Required<IRectGraphicAttribute>;\n rect3d: Required<IRect3dGraphicAttribute>;\n glyph: Required<IGlyphGraphicAttribute>;\n group: Required<IGroupGraphicAttribute>;\n polygon: Required<IPolygonGraphicAttribute>;\n richtext: Required<IRichTextGraphicAttribute>;\n richtextIcon: Required<IRichTextIconGraphicAttribute>;\n image: Required<IImageGraphicAttribute>;\n}\n\nexport interface ITheme {\n getTheme: (g: IGroup) => IFullThemeSpec;\n combinedTheme?: IFullThemeSpec;\n userTheme?: IThemeSpec;\n nextTheme?: IThemeSpec;\n applyTheme: (group: IGroup, pt: IThemeSpec, force?: boolean) => IThemeSpec;\n setTheme: (t: IThemeSpec, g: IGroup) => void;\n dirty: boolean;\n}\n"]}
|